@fdm-monster/client-next 0.0.9 → 0.0.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,90 @@
1
+ var pD=Object.defineProperty;var RS=e=>{throw TypeError(e)};var mD=(e,t,n)=>t in e?pD(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var he=(e,t,n)=>mD(e,typeof t!="symbol"?t+"":t,n),Lm=(e,t,n)=>t.has(e)||RS("Cannot "+n);var z=(e,t,n)=>(Lm(e,t,"read from private field"),n?n.call(e):t.get(e)),He=(e,t,n)=>t.has(e)?RS("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),De=(e,t,n,r)=>(Lm(e,t,"write to private field"),r?r.call(e,n):t.set(e,n),n),rt=(e,t,n)=>(Lm(e,t,"access private method"),n);var Xd=(e,t,n,r)=>({set _(s){De(e,t,s,n)},get _(){return z(e,t,r)}});(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="fc78fad9-f392-414d-9529-ebffcf77d034",e._sentryDebugIdIdentifier="sentry-dbid-fc78fad9-f392-414d-9529-ebffcf77d034")}catch{}})();var gD=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};gD.SENTRY_RELEASE={id:"3381e19fa06fe7f2d4d8bb5b1e0b6db67023997f"};(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const s of document.querySelectorAll('link[rel="modulepreload"]'))r(s);new MutationObserver(s=>{for(const i of s)if(i.type==="childList")for(const o of i.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&r(o)}).observe(document,{childList:!0,subtree:!0});function n(s){const i={};return s.integrity&&(i.integrity=s.integrity),s.referrerPolicy&&(i.referrerPolicy=s.referrerPolicy),s.crossOrigin==="use-credentials"?i.credentials="include":s.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function r(s){if(s.ep)return;s.ep=!0;const i=n(s);fetch(s.href,i)}})();/**
2
+ * @vue/shared v3.5.13
3
+ * (c) 2018-present Yuxi (Evan) You and Vue contributors
4
+ * @license MIT
5
+ **//*! #__NO_SIDE_EFFECTS__ */function sb(e){const t=Object.create(null);for(const n of e.split(","))t[n]=1;return n=>n in t}const Ft={},$l=[],ai=()=>{},vD=()=>!1,wp=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),ib=e=>e.startsWith("onUpdate:"),gn=Object.assign,ob=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},yD=Object.prototype.hasOwnProperty,Et=(e,t)=>yD.call(e,t),je=Array.isArray,Fl=e=>Sp(e)==="[object Map]",$E=e=>Sp(e)==="[object Set]",Qe=e=>typeof e=="function",rn=e=>typeof e=="string",ji=e=>typeof e=="symbol",Yt=e=>e!==null&&typeof e=="object",FE=e=>(Yt(e)||Qe(e))&&Qe(e.then)&&Qe(e.catch),NE=Object.prototype.toString,Sp=e=>NE.call(e),bD=e=>Sp(e).slice(8,-1),BE=e=>Sp(e)==="[object Object]",ab=e=>rn(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,gc=sb(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),_p=e=>{const t=Object.create(null);return n=>t[n]||(t[n]=e(n))},wD=/-(\w)/g,Or=_p(e=>e.replace(wD,(t,n)=>n?n.toUpperCase():"")),SD=/\B([A-Z])/g,Uo=_p(e=>e.replace(SD,"-$1").toLowerCase()),hi=_p(e=>e.charAt(0).toUpperCase()+e.slice(1)),$m=_p(e=>e?`on${hi(e)}`:""),To=(e,t)=>!Object.is(e,t),qf=(e,...t)=>{for(let n=0;n<e.length;n++)e[n](...t)},VE=(e,t,n,r=!1)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:r,value:n})},Jg=e=>{const t=parseFloat(e);return isNaN(t)?e:t},_D=e=>{const t=rn(e)?Number(e):NaN;return isNaN(t)?e:t};let IS;const kp=()=>IS||(IS=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function ci(e){if(je(e)){const t={};for(let n=0;n<e.length;n++){const r=e[n],s=rn(r)?CD(r):ci(r);if(s)for(const i in s)t[i]=s[i]}return t}else if(rn(e)||Yt(e))return e}const kD=/;(?![^(]*\))/g,xD=/:([^]+)/,ED=/\/\*[^]*?\*\//g;function CD(e){const t={};return e.replace(ED,"").split(kD).forEach(n=>{if(n){const r=n.split(xD);r.length>1&&(t[r[0].trim()]=r[1].trim())}}),t}function Ja(e){let t="";if(rn(e))t=e;else if(je(e))for(let n=0;n<e.length;n++){const r=Ja(e[n]);r&&(t+=r+" ")}else if(Yt(e))for(const n in e)e[n]&&(t+=n+" ");return t.trim()}function Zg(e){if(!e)return null;let{class:t,style:n}=e;return t&&!rn(t)&&(e.class=Ja(t)),n&&(e.style=ci(n)),e}const PD="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",TD=sb(PD);function UE(e){return!!e||e===""}const HE=e=>!!(e&&e.__v_isRef===!0),ae=e=>rn(e)?e:e==null?"":je(e)||Yt(e)&&(e.toString===NE||!Qe(e.toString))?HE(e)?ae(e.value):JSON.stringify(e,zE,2):String(e),zE=(e,t)=>HE(t)?zE(e,t.value):Fl(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((n,[r,s],i)=>(n[Fm(r,i)+" =>"]=s,n),{})}:$E(t)?{[`Set(${t.size})`]:[...t.values()].map(n=>Fm(n))}:ji(t)?Fm(t):Yt(t)&&!je(t)&&!BE(t)?String(t):t,Fm=(e,t="")=>{var n;return ji(e)?`Symbol(${(n=e.description)!=null?n:t})`:e};/**
6
+ * @vue/reactivity v3.5.13
7
+ * (c) 2018-present Yuxi (Evan) You and Vue contributors
8
+ * @license MIT
9
+ **/let dr;class jE{constructor(t=!1){this.detached=t,this._active=!0,this.effects=[],this.cleanups=[],this._isPaused=!1,this.parent=dr,!t&&dr&&(this.index=(dr.scopes||(dr.scopes=[])).push(this)-1)}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let t,n;if(this.scopes)for(t=0,n=this.scopes.length;t<n;t++)this.scopes[t].pause();for(t=0,n=this.effects.length;t<n;t++)this.effects[t].pause()}}resume(){if(this._active&&this._isPaused){this._isPaused=!1;let t,n;if(this.scopes)for(t=0,n=this.scopes.length;t<n;t++)this.scopes[t].resume();for(t=0,n=this.effects.length;t<n;t++)this.effects[t].resume()}}run(t){if(this._active){const n=dr;try{return dr=this,t()}finally{dr=n}}}on(){dr=this}off(){dr=this.parent}stop(t){if(this._active){this._active=!1;let n,r;for(n=0,r=this.effects.length;n<r;n++)this.effects[n].stop();for(this.effects.length=0,n=0,r=this.cleanups.length;n<r;n++)this.cleanups[n]();if(this.cleanups.length=0,this.scopes){for(n=0,r=this.scopes.length;n<r;n++)this.scopes[n].stop(!0);this.scopes.length=0}if(!this.detached&&this.parent&&!t){const s=this.parent.scopes.pop();s&&s!==this&&(this.parent.scopes[this.index]=s,s.index=this.index)}this.parent=void 0}}}function wd(e){return new jE(e)}function xp(){return dr}function Sn(e,t=!1){dr&&dr.cleanups.push(e)}let Ht;const Nm=new WeakSet;class qE{constructor(t){this.fn=t,this.deps=void 0,this.depsTail=void 0,this.flags=5,this.next=void 0,this.cleanup=void 0,this.scheduler=void 0,dr&&dr.active&&dr.effects.push(this)}pause(){this.flags|=64}resume(){this.flags&64&&(this.flags&=-65,Nm.has(this)&&(Nm.delete(this),this.trigger()))}notify(){this.flags&2&&!(this.flags&32)||this.flags&8||GE(this)}run(){if(!(this.flags&1))return this.fn();this.flags|=2,AS(this),KE(this);const t=Ht,n=Ts;Ht=this,Ts=!0;try{return this.fn()}finally{YE(this),Ht=t,Ts=n,this.flags&=-3}}stop(){if(this.flags&1){for(let t=this.deps;t;t=t.nextDep)cb(t);this.deps=this.depsTail=void 0,AS(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){this.flags&64?Nm.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){ev(this)&&this.run()}get dirty(){return ev(this)}}let WE=0,vc,yc;function GE(e,t=!1){if(e.flags|=8,t){e.next=yc,yc=e;return}e.next=vc,vc=e}function lb(){WE++}function ub(){if(--WE>0)return;if(yc){let t=yc;for(yc=void 0;t;){const n=t.next;t.next=void 0,t.flags&=-9,t=n}}let e;for(;vc;){let t=vc;for(vc=void 0;t;){const n=t.next;if(t.next=void 0,t.flags&=-9,t.flags&1)try{t.trigger()}catch(r){e||(e=r)}t=n}}if(e)throw e}function KE(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function YE(e){let t,n=e.depsTail,r=n;for(;r;){const s=r.prevDep;r.version===-1?(r===n&&(n=s),cb(r),RD(r)):t=r,r.dep.activeLink=r.prevActiveLink,r.prevActiveLink=void 0,r=s}e.deps=t,e.depsTail=n}function ev(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(XE(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function XE(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===$c))return;e.globalVersion=$c;const t=e.dep;if(e.flags|=2,t.version>0&&!e.isSSR&&e.deps&&!ev(e)){e.flags&=-3;return}const n=Ht,r=Ts;Ht=e,Ts=!0;try{KE(e);const s=e.fn(e._value);(t.version===0||To(s,e._value))&&(e._value=s,t.version++)}catch(s){throw t.version++,s}finally{Ht=n,Ts=r,YE(e),e.flags&=-3}}function cb(e,t=!1){const{dep:n,prevSub:r,nextSub:s}=e;if(r&&(r.nextSub=s,e.prevSub=void 0),s&&(s.prevSub=r,e.nextSub=void 0),n.subs===e&&(n.subs=r,!r&&n.computed)){n.computed.flags&=-5;for(let i=n.computed.deps;i;i=i.nextDep)cb(i,!0)}!t&&!--n.sc&&n.map&&n.map.delete(n.key)}function RD(e){const{prevDep:t,nextDep:n}=e;t&&(t.nextDep=n,e.prevDep=void 0),n&&(n.prevDep=t,e.nextDep=void 0)}let Ts=!0;const QE=[];function Ho(){QE.push(Ts),Ts=!1}function zo(){const e=QE.pop();Ts=e===void 0?!0:e}function AS(e){const{cleanup:t}=e;if(e.cleanup=void 0,t){const n=Ht;Ht=void 0;try{t()}finally{Ht=n}}}let $c=0;class ID{constructor(t,n){this.sub=t,this.dep=n,this.version=n.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}}class db{constructor(t){this.computed=t,this.version=0,this.activeLink=void 0,this.subs=void 0,this.map=void 0,this.key=void 0,this.sc=0}track(t){if(!Ht||!Ts||Ht===this.computed)return;let n=this.activeLink;if(n===void 0||n.sub!==Ht)n=this.activeLink=new ID(Ht,this),Ht.deps?(n.prevDep=Ht.depsTail,Ht.depsTail.nextDep=n,Ht.depsTail=n):Ht.deps=Ht.depsTail=n,JE(n);else if(n.version===-1&&(n.version=this.version,n.nextDep)){const r=n.nextDep;r.prevDep=n.prevDep,n.prevDep&&(n.prevDep.nextDep=r),n.prevDep=Ht.depsTail,n.nextDep=void 0,Ht.depsTail.nextDep=n,Ht.depsTail=n,Ht.deps===n&&(Ht.deps=r)}return n}trigger(t){this.version++,$c++,this.notify(t)}notify(t){lb();try{for(let n=this.subs;n;n=n.prevSub)n.sub.notify()&&n.sub.dep.notify()}finally{ub()}}}function JE(e){if(e.dep.sc++,e.sub.flags&4){const t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let r=t.deps;r;r=r.nextDep)JE(r)}const n=e.dep.subs;n!==e&&(e.prevSub=n,n&&(n.nextSub=e)),e.dep.subs=e}}const bh=new WeakMap,Pa=Symbol(""),tv=Symbol(""),Fc=Symbol("");function Qn(e,t,n){if(Ts&&Ht){let r=bh.get(e);r||bh.set(e,r=new Map);let s=r.get(n);s||(r.set(n,s=new db),s.map=r,s.key=n),s.track()}}function Ai(e,t,n,r,s,i){const o=bh.get(e);if(!o){$c++;return}const a=l=>{l&&l.trigger()};if(lb(),t==="clear")o.forEach(a);else{const l=je(e),u=l&&ab(n);if(l&&n==="length"){const d=Number(r);o.forEach((c,f)=>{(f==="length"||f===Fc||!ji(f)&&f>=d)&&a(c)})}else switch((n!==void 0||o.has(void 0))&&a(o.get(n)),u&&a(o.get(Fc)),t){case"add":l?u&&a(o.get("length")):(a(o.get(Pa)),Fl(e)&&a(o.get(tv)));break;case"delete":l||(a(o.get(Pa)),Fl(e)&&a(o.get(tv)));break;case"set":Fl(e)&&a(o.get(Pa));break}}ub()}function AD(e,t){const n=bh.get(e);return n&&n.get(t)}function ul(e){const t=Be(e);return t===e?t:(Qn(t,"iterate",Fc),ds(e)?t:t.map(Jn))}function Ep(e){return Qn(e=Be(e),"iterate",Fc),e}const OD={__proto__:null,[Symbol.iterator](){return Bm(this,Symbol.iterator,Jn)},concat(...e){return ul(this).concat(...e.map(t=>je(t)?ul(t):t))},entries(){return Bm(this,"entries",e=>(e[1]=Jn(e[1]),e))},every(e,t){return vi(this,"every",e,t,void 0,arguments)},filter(e,t){return vi(this,"filter",e,t,n=>n.map(Jn),arguments)},find(e,t){return vi(this,"find",e,t,Jn,arguments)},findIndex(e,t){return vi(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return vi(this,"findLast",e,t,Jn,arguments)},findLastIndex(e,t){return vi(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return vi(this,"forEach",e,t,void 0,arguments)},includes(...e){return Vm(this,"includes",e)},indexOf(...e){return Vm(this,"indexOf",e)},join(e){return ul(this).join(e)},lastIndexOf(...e){return Vm(this,"lastIndexOf",e)},map(e,t){return vi(this,"map",e,t,void 0,arguments)},pop(){return Gu(this,"pop")},push(...e){return Gu(this,"push",e)},reduce(e,...t){return OS(this,"reduce",e,t)},reduceRight(e,...t){return OS(this,"reduceRight",e,t)},shift(){return Gu(this,"shift")},some(e,t){return vi(this,"some",e,t,void 0,arguments)},splice(...e){return Gu(this,"splice",e)},toReversed(){return ul(this).toReversed()},toSorted(e){return ul(this).toSorted(e)},toSpliced(...e){return ul(this).toSpliced(...e)},unshift(...e){return Gu(this,"unshift",e)},values(){return Bm(this,"values",Jn)}};function Bm(e,t,n){const r=Ep(e),s=r[t]();return r!==e&&!ds(e)&&(s._next=s.next,s.next=()=>{const i=s._next();return i.value&&(i.value=n(i.value)),i}),s}const MD=Array.prototype;function vi(e,t,n,r,s,i){const o=Ep(e),a=o!==e&&!ds(e),l=o[t];if(l!==MD[t]){const c=l.apply(e,i);return a?Jn(c):c}let u=n;o!==e&&(a?u=function(c,f){return n.call(this,Jn(c),f,e)}:n.length>2&&(u=function(c,f){return n.call(this,c,f,e)}));const d=l.call(o,u,r);return a&&s?s(d):d}function OS(e,t,n,r){const s=Ep(e);let i=n;return s!==e&&(ds(e)?n.length>3&&(i=function(o,a,l){return n.call(this,o,a,l,e)}):i=function(o,a,l){return n.call(this,o,Jn(a),l,e)}),s[t](i,...r)}function Vm(e,t,n){const r=Be(e);Qn(r,"iterate",Fc);const s=r[t](...n);return(s===-1||s===!1)&&_d(n[0])?(n[0]=Be(n[0]),r[t](...n)):s}function Gu(e,t,n=[]){Ho(),lb();const r=Be(e)[t].apply(e,n);return ub(),zo(),r}const DD=sb("__proto__,__v_isRef,__isVue"),ZE=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(ji));function LD(e){ji(e)||(e=String(e));const t=Be(this);return Qn(t,"has",e),t.hasOwnProperty(e)}class eC{constructor(t=!1,n=!1){this._isReadonly=t,this._isShallow=n}get(t,n,r){if(n==="__v_skip")return t.__v_skip;const s=this._isReadonly,i=this._isShallow;if(n==="__v_isReactive")return!s;if(n==="__v_isReadonly")return s;if(n==="__v_isShallow")return i;if(n==="__v_raw")return r===(s?i?qD:sC:i?rC:nC).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(r)?t:void 0;const o=je(t);if(!s){let l;if(o&&(l=OD[n]))return l;if(n==="hasOwnProperty")return LD}const a=Reflect.get(t,n,tt(t)?t:r);return(ji(n)?ZE.has(n):DD(n))||(s||Qn(t,"get",n),i)?a:tt(a)?o&&ab(n)?a:a.value:Yt(a)?s?Sd(a):vn(a):a}}class tC extends eC{constructor(t=!1){super(!1,t)}set(t,n,r,s){let i=t[n];if(!this._isShallow){const l=Na(i);if(!ds(r)&&!Na(r)&&(i=Be(i),r=Be(r)),!je(t)&&tt(i)&&!tt(r))return l?!1:(i.value=r,!0)}const o=je(t)&&ab(n)?Number(n)<t.length:Et(t,n),a=Reflect.set(t,n,r,tt(t)?t:s);return t===Be(s)&&(o?To(r,i)&&Ai(t,"set",n,r):Ai(t,"add",n,r)),a}deleteProperty(t,n){const r=Et(t,n);t[n];const s=Reflect.deleteProperty(t,n);return s&&r&&Ai(t,"delete",n,void 0),s}has(t,n){const r=Reflect.has(t,n);return(!ji(n)||!ZE.has(n))&&Qn(t,"has",n),r}ownKeys(t){return Qn(t,"iterate",je(t)?"length":Pa),Reflect.ownKeys(t)}}class $D extends eC{constructor(t=!1){super(!0,t)}set(t,n){return!0}deleteProperty(t,n){return!0}}const FD=new tC,ND=new $D,BD=new tC(!0);const nv=e=>e,Qd=e=>Reflect.getPrototypeOf(e);function VD(e,t,n){return function(...r){const s=this.__v_raw,i=Be(s),o=Fl(i),a=e==="entries"||e===Symbol.iterator&&o,l=e==="keys"&&o,u=s[e](...r),d=n?nv:t?rv:Jn;return!t&&Qn(i,"iterate",l?tv:Pa),{next(){const{value:c,done:f}=u.next();return f?{value:c,done:f}:{value:a?[d(c[0]),d(c[1])]:d(c),done:f}},[Symbol.iterator](){return this}}}}function Jd(e){return function(...t){return e==="delete"?!1:e==="clear"?void 0:this}}function UD(e,t){const n={get(s){const i=this.__v_raw,o=Be(i),a=Be(s);e||(To(s,a)&&Qn(o,"get",s),Qn(o,"get",a));const{has:l}=Qd(o),u=t?nv:e?rv:Jn;if(l.call(o,s))return u(i.get(s));if(l.call(o,a))return u(i.get(a));i!==o&&i.get(s)},get size(){const s=this.__v_raw;return!e&&Qn(Be(s),"iterate",Pa),Reflect.get(s,"size",s)},has(s){const i=this.__v_raw,o=Be(i),a=Be(s);return e||(To(s,a)&&Qn(o,"has",s),Qn(o,"has",a)),s===a?i.has(s):i.has(s)||i.has(a)},forEach(s,i){const o=this,a=o.__v_raw,l=Be(a),u=t?nv:e?rv:Jn;return!e&&Qn(l,"iterate",Pa),a.forEach((d,c)=>s.call(i,u(d),u(c),o))}};return gn(n,e?{add:Jd("add"),set:Jd("set"),delete:Jd("delete"),clear:Jd("clear")}:{add(s){!t&&!ds(s)&&!Na(s)&&(s=Be(s));const i=Be(this);return Qd(i).has.call(i,s)||(i.add(s),Ai(i,"add",s,s)),this},set(s,i){!t&&!ds(i)&&!Na(i)&&(i=Be(i));const o=Be(this),{has:a,get:l}=Qd(o);let u=a.call(o,s);u||(s=Be(s),u=a.call(o,s));const d=l.call(o,s);return o.set(s,i),u?To(i,d)&&Ai(o,"set",s,i):Ai(o,"add",s,i),this},delete(s){const i=Be(this),{has:o,get:a}=Qd(i);let l=o.call(i,s);l||(s=Be(s),l=o.call(i,s)),a&&a.call(i,s);const u=i.delete(s);return l&&Ai(i,"delete",s,void 0),u},clear(){const s=Be(this),i=s.size!==0,o=s.clear();return i&&Ai(s,"clear",void 0,void 0),o}}),["keys","values","entries",Symbol.iterator].forEach(s=>{n[s]=VD(s,e,t)}),n}function fb(e,t){const n=UD(e,t);return(r,s,i)=>s==="__v_isReactive"?!e:s==="__v_isReadonly"?e:s==="__v_raw"?r:Reflect.get(Et(n,s)&&s in r?n:r,s,i)}const HD={get:fb(!1,!1)},zD={get:fb(!1,!0)},jD={get:fb(!0,!1)};const nC=new WeakMap,rC=new WeakMap,sC=new WeakMap,qD=new WeakMap;function WD(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function GD(e){return e.__v_skip||!Object.isExtensible(e)?0:WD(bD(e))}function vn(e){return Na(e)?e:hb(e,!1,FD,HD,nC)}function Cp(e){return hb(e,!1,BD,zD,rC)}function Sd(e){return hb(e,!0,ND,jD,sC)}function hb(e,t,n,r,s){if(!Yt(e)||e.__v_raw&&!(t&&e.__v_isReactive))return e;const i=s.get(e);if(i)return i;const o=GD(e);if(o===0)return e;const a=new Proxy(e,o===2?r:n);return s.set(e,a),a}function Ro(e){return Na(e)?Ro(e.__v_raw):!!(e&&e.__v_isReactive)}function Na(e){return!!(e&&e.__v_isReadonly)}function ds(e){return!!(e&&e.__v_isShallow)}function _d(e){return e?!!e.__v_raw:!1}function Be(e){const t=e&&e.__v_raw;return t?Be(t):e}function Pp(e){return!Et(e,"__v_skip")&&Object.isExtensible(e)&&VE(e,"__v_skip",!0),e}const Jn=e=>Yt(e)?vn(e):e,rv=e=>Yt(e)?Sd(e):e;function tt(e){return e?e.__v_isRef===!0:!1}function U(e){return iC(e,!1)}function Me(e){return iC(e,!0)}function iC(e,t){return tt(e)?e:new KD(e,t)}class KD{constructor(t,n){this.dep=new db,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=n?t:Be(t),this._value=n?t:Jn(t),this.__v_isShallow=n}get value(){return this.dep.track(),this._value}set value(t){const n=this._rawValue,r=this.__v_isShallow||ds(t)||Na(t);t=r?t:Be(t),To(t,n)&&(this._rawValue=t,this._value=r?t:Jn(t),this.dep.trigger())}}function ie(e){return tt(e)?e.value:e}const YD={get:(e,t,n)=>t==="__v_raw"?e:ie(Reflect.get(e,t,n)),set:(e,t,n,r)=>{const s=e[t];return tt(s)&&!tt(n)?(s.value=n,!0):Reflect.set(e,t,n,r)}};function oC(e){return Ro(e)?e:new Proxy(e,YD)}function jo(e){const t=je(e)?new Array(e.length):{};for(const n in e)t[n]=aC(e,n);return t}class XD{constructor(t,n,r){this._object=t,this._key=n,this._defaultValue=r,this.__v_isRef=!0,this._value=void 0}get value(){const t=this._object[this._key];return this._value=t===void 0?this._defaultValue:t}set value(t){this._object[this._key]=t}get dep(){return AD(Be(this._object),this._key)}}class QD{constructor(t){this._getter=t,this.__v_isRef=!0,this.__v_isReadonly=!0,this._value=void 0}get value(){return this._value=this._getter()}}function Te(e,t,n){return tt(e)?e:Qe(e)?new QD(e):Yt(e)&&arguments.length>1?aC(e,t,n):U(e)}function aC(e,t,n){const r=e[t];return tt(r)?r:new XD(e,t,n)}class JD{constructor(t,n,r){this.fn=t,this.setter=n,this._value=void 0,this.dep=new db(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=$c-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!n,this.isSSR=r}notify(){if(this.flags|=16,!(this.flags&8)&&Ht!==this)return GE(this,!0),!0}get value(){const t=this.dep.track();return XE(this),t&&(t.version=this.dep.version),this._value}set value(t){this.setter&&this.setter(t)}}function ZD(e,t,n=!1){let r,s;return Qe(e)?r=e:(r=e.get,s=e.set),new JD(r,s,n)}const Zd={},wh=new WeakMap;let da;function eL(e,t=!1,n=da){if(n){let r=wh.get(n);r||wh.set(n,r=[]),r.push(e)}}function tL(e,t,n=Ft){const{immediate:r,deep:s,once:i,scheduler:o,augmentJob:a,call:l}=n,u=P=>s?P:ds(P)||s===!1||s===0?Oi(P,1):Oi(P);let d,c,f,p,g=!1,m=!1;if(tt(e)?(c=()=>e.value,g=ds(e)):Ro(e)?(c=()=>u(e),g=!0):je(e)?(m=!0,g=e.some(P=>Ro(P)||ds(P)),c=()=>e.map(P=>{if(tt(P))return P.value;if(Ro(P))return u(P);if(Qe(P))return l?l(P,2):P()})):Qe(e)?t?c=l?()=>l(e,2):e:c=()=>{if(f){Ho();try{f()}finally{zo()}}const P=da;da=d;try{return l?l(e,3,[p]):e(p)}finally{da=P}}:c=ai,t&&s){const P=c,E=s===!0?1/0:s;c=()=>Oi(P(),E)}const y=xp(),b=()=>{d.stop(),y&&y.active&&ob(y.effects,d)};if(i&&t){const P=t;t=(...E)=>{P(...E),b()}}let w=m?new Array(e.length).fill(Zd):Zd;const S=P=>{if(!(!(d.flags&1)||!d.dirty&&!P))if(t){const E=d.run();if(s||g||(m?E.some((T,C)=>To(T,w[C])):To(E,w))){f&&f();const T=da;da=d;try{const C=[E,w===Zd?void 0:m&&w[0]===Zd?[]:w,p];l?l(t,3,C):t(...C),w=E}finally{da=T}}}else d.run()};return a&&a(S),d=new qE(c),d.scheduler=o?()=>o(S,!1):S,p=P=>eL(P,!1,d),f=d.onStop=()=>{const P=wh.get(d);if(P){if(l)l(P,4);else for(const E of P)E();wh.delete(d)}},t?r?S(!0):w=d.run():o?o(S.bind(null,!0),!0):d.run(),b.pause=d.pause.bind(d),b.resume=d.resume.bind(d),b.stop=b,b}function Oi(e,t=1/0,n){if(t<=0||!Yt(e)||e.__v_skip||(n=n||new Set,n.has(e)))return e;if(n.add(e),t--,tt(e))Oi(e.value,t,n);else if(je(e))for(let r=0;r<e.length;r++)Oi(e[r],t,n);else if($E(e)||Fl(e))e.forEach(r=>{Oi(r,t,n)});else if(BE(e)){for(const r in e)Oi(e[r],t,n);for(const r of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,r)&&Oi(e[r],t,n)}return e}/**
10
+ * @vue/runtime-core v3.5.13
11
+ * (c) 2018-present Yuxi (Evan) You and Vue contributors
12
+ * @license MIT
13
+ **/function kd(e,t,n,r){try{return r?e(...r):e()}catch(s){Tp(s,t,n)}}function Rs(e,t,n,r){if(Qe(e)){const s=kd(e,t,n,r);return s&&FE(s)&&s.catch(i=>{Tp(i,t,n)}),s}if(je(e)){const s=[];for(let i=0;i<e.length;i++)s.push(Rs(e[i],t,n,r));return s}}function Tp(e,t,n,r=!0){const s=t?t.vnode:null,{errorHandler:i,throwUnhandledErrorInProduction:o}=t&&t.appContext.config||Ft;if(t){let a=t.parent;const l=t.proxy,u=`https://vuejs.org/error-reference/#runtime-${n}`;for(;a;){const d=a.ec;if(d){for(let c=0;c<d.length;c++)if(d[c](e,l,u)===!1)return}a=a.parent}if(i){Ho(),kd(i,null,10,[e,l,u]),zo();return}}nL(e,n,s,r,o)}function nL(e,t,n,r=!0,s=!1){if(s)throw e;console.error(e)}const fr=[];let Ks=-1;const Nl=[];let so=null,Sl=0;const lC=Promise.resolve();let Sh=null;function Ot(e){const t=Sh||lC;return e?t.then(this?e.bind(this):e):t}function rL(e){let t=Ks+1,n=fr.length;for(;t<n;){const r=t+n>>>1,s=fr[r],i=Nc(s);i<e||i===e&&s.flags&2?t=r+1:n=r}return t}function pb(e){if(!(e.flags&1)){const t=Nc(e),n=fr[fr.length-1];!n||!(e.flags&2)&&t>=Nc(n)?fr.push(e):fr.splice(rL(t),0,e),e.flags|=1,uC()}}function uC(){Sh||(Sh=lC.then(dC))}function sL(e){je(e)?Nl.push(...e):so&&e.id===-1?so.splice(Sl+1,0,e):e.flags&1||(Nl.push(e),e.flags|=1),uC()}function MS(e,t,n=Ks+1){for(;n<fr.length;n++){const r=fr[n];if(r&&r.flags&2){if(e&&r.id!==e.uid)continue;fr.splice(n,1),n--,r.flags&4&&(r.flags&=-2),r(),r.flags&4||(r.flags&=-2)}}}function cC(e){if(Nl.length){const t=[...new Set(Nl)].sort((n,r)=>Nc(n)-Nc(r));if(Nl.length=0,so){so.push(...t);return}for(so=t,Sl=0;Sl<so.length;Sl++){const n=so[Sl];n.flags&4&&(n.flags&=-2),n.flags&8||n(),n.flags&=-2}so=null,Sl=0}}const Nc=e=>e.id==null?e.flags&2?-1:1/0:e.id;function dC(e){try{for(Ks=0;Ks<fr.length;Ks++){const t=fr[Ks];t&&!(t.flags&8)&&(t.flags&4&&(t.flags&=-2),kd(t,t.i,t.i?15:14),t.flags&4||(t.flags&=-2))}}finally{for(;Ks<fr.length;Ks++){const t=fr[Ks];t&&(t.flags&=-2)}Ks=-1,fr.length=0,cC(),Sh=null,(fr.length||Nl.length)&&dC()}}let xn=null,fC=null;function _h(e){const t=xn;return xn=e,fC=e&&e.type.__scopeId||null,t}function v(e,t=xn,n){if(!t||e._n)return e;const r=(...s)=>{r._d&&WS(-1);const i=_h(t);let o;try{o=e(...s)}finally{_h(i),r._d&&WS(1)}return o};return r._n=!0,r._c=!0,r._d=!0,r}function en(e,t){if(xn===null)return e;const n=Lp(xn),r=e.dirs||(e.dirs=[]);for(let s=0;s<t.length;s++){let[i,o,a,l=Ft]=t[s];i&&(Qe(i)&&(i={mounted:i,updated:i}),i.deep&&Oi(o),r.push({dir:i,instance:n,value:o,oldValue:void 0,arg:a,modifiers:l}))}return e}function na(e,t,n,r){const s=e.dirs,i=t&&t.dirs;for(let o=0;o<s.length;o++){const a=s[o];i&&(a.oldValue=i[o].value);let l=a.dir[r];l&&(Ho(),Rs(l,n,8,[e.el,a,e,t]),zo())}}const hC=Symbol("_vte"),pC=e=>e.__isTeleport,bc=e=>e&&(e.disabled||e.disabled===""),DS=e=>e&&(e.defer||e.defer===""),LS=e=>typeof SVGElement<"u"&&e instanceof SVGElement,$S=e=>typeof MathMLElement=="function"&&e instanceof MathMLElement,sv=(e,t)=>{const n=e&&e.to;return rn(n)?t?t(n):null:n},mC={name:"Teleport",__isTeleport:!0,process(e,t,n,r,s,i,o,a,l,u){const{mc:d,pc:c,pbc:f,o:{insert:p,querySelector:g,createText:m,createComment:y}}=u,b=bc(t.props);let{shapeFlag:w,children:S,dynamicChildren:P}=t;if(e==null){const E=t.el=m(""),T=t.anchor=m("");p(E,n,r),p(T,n,r);const C=(x,I)=>{w&16&&(s&&s.isCE&&(s.ce._teleportTarget=x),d(S,x,I,s,i,o,a,l))},k=()=>{const x=t.target=sv(t.props,g),I=gC(x,t,m,p);x&&(o!=="svg"&&LS(x)?o="svg":o!=="mathml"&&$S(x)&&(o="mathml"),b||(C(x,I),Wf(t,!1)))};b&&(C(n,T),Wf(t,!0)),DS(t.props)?cr(()=>{k(),t.el.__isMounted=!0},i):k()}else{if(DS(t.props)&&!e.el.__isMounted){cr(()=>{mC.process(e,t,n,r,s,i,o,a,l,u),delete e.el.__isMounted},i);return}t.el=e.el,t.targetStart=e.targetStart;const E=t.anchor=e.anchor,T=t.target=e.target,C=t.targetAnchor=e.targetAnchor,k=bc(e.props),x=k?n:T,I=k?E:C;if(o==="svg"||LS(T)?o="svg":(o==="mathml"||$S(T))&&(o="mathml"),P?(f(e.dynamicChildren,P,x,s,i,o,a),_b(e,t,!0)):l||c(e,t,x,I,s,i,o,a,!1),b)k?t.props&&e.props&&t.props.to!==e.props.to&&(t.props.to=e.props.to):ef(t,n,E,u,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){const M=t.target=sv(t.props,g);M&&ef(t,M,null,u,0)}else k&&ef(t,T,C,u,1);Wf(t,b)}},remove(e,t,n,{um:r,o:{remove:s}},i){const{shapeFlag:o,children:a,anchor:l,targetStart:u,targetAnchor:d,target:c,props:f}=e;if(c&&(s(u),s(d)),i&&s(l),o&16){const p=i||!bc(f);for(let g=0;g<a.length;g++){const m=a[g];r(m,t,n,p,!!m.dynamicChildren)}}},move:ef,hydrate:iL};function ef(e,t,n,{o:{insert:r},m:s},i=2){i===0&&r(e.targetAnchor,t,n);const{el:o,anchor:a,shapeFlag:l,children:u,props:d}=e,c=i===2;if(c&&r(o,t,n),(!c||bc(d))&&l&16)for(let f=0;f<u.length;f++)s(u[f],t,n,2);c&&r(a,t,n)}function iL(e,t,n,r,s,i,{o:{nextSibling:o,parentNode:a,querySelector:l,insert:u,createText:d}},c){const f=t.target=sv(t.props,l);if(f){const p=bc(t.props),g=f._lpa||f.firstChild;if(t.shapeFlag&16)if(p)t.anchor=c(o(e),t,a(e),n,r,s,i),t.targetStart=g,t.targetAnchor=g&&o(g);else{t.anchor=o(e);let m=g;for(;m;){if(m&&m.nodeType===8){if(m.data==="teleport start anchor")t.targetStart=m;else if(m.data==="teleport anchor"){t.targetAnchor=m,f._lpa=t.targetAnchor&&o(t.targetAnchor);break}}m=o(m)}t.targetAnchor||gC(f,t,d,u),c(g&&o(g),t,f,n,r,s,i)}Wf(t,p)}return t.anchor&&o(t.anchor)}const oL=mC;function Wf(e,t){const n=e.ctx;if(n&&n.ut){let r,s;for(t?(r=e.el,s=e.anchor):(r=e.targetStart,s=e.targetAnchor);r&&r!==s;)r.nodeType===1&&r.setAttribute("data-v-owner",n.uid),r=r.nextSibling;n.ut()}}function gC(e,t,n,r){const s=t.targetStart=n(""),i=t.targetAnchor=n("");return s[hC]=i,e&&(r(s,e),r(i,e)),i}const io=Symbol("_leaveCb"),tf=Symbol("_enterCb");function vC(){const e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return St(()=>{e.isMounted=!0}),Tn(()=>{e.isUnmounting=!0}),e}const ns=[Function,Array],yC={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:ns,onEnter:ns,onAfterEnter:ns,onEnterCancelled:ns,onBeforeLeave:ns,onLeave:ns,onAfterLeave:ns,onLeaveCancelled:ns,onBeforeAppear:ns,onAppear:ns,onAfterAppear:ns,onAppearCancelled:ns},bC=e=>{const t=e.subTree;return t.component?bC(t.component):t},aL={name:"BaseTransition",props:yC,setup(e,{slots:t}){const n=Eb(),r=vC();return()=>{const s=t.default&&mb(t.default(),!0);if(!s||!s.length)return;const i=wC(s),o=Be(e),{mode:a}=o;if(r.isLeaving)return Um(i);const l=FS(i);if(!l)return Um(i);let u=Bc(l,o,r,n,c=>u=c);l.type!==Zn&&Ba(l,u);let d=n.subTree&&FS(n.subTree);if(d&&d.type!==Zn&&!ma(l,d)&&bC(n).type!==Zn){let c=Bc(d,o,r,n);if(Ba(d,c),a==="out-in"&&l.type!==Zn)return r.isLeaving=!0,c.afterLeave=()=>{r.isLeaving=!1,n.job.flags&8||n.update(),delete c.afterLeave,d=void 0},Um(i);a==="in-out"&&l.type!==Zn?c.delayLeave=(f,p,g)=>{const m=SC(r,d);m[String(d.key)]=d,f[io]=()=>{p(),f[io]=void 0,delete u.delayedLeave,d=void 0},u.delayedLeave=()=>{g(),delete u.delayedLeave,d=void 0}}:d=void 0}else d&&(d=void 0);return i}}};function wC(e){let t=e[0];if(e.length>1){for(const n of e)if(n.type!==Zn){t=n;break}}return t}const lL=aL;function SC(e,t){const{leavingVNodes:n}=e;let r=n.get(t.type);return r||(r=Object.create(null),n.set(t.type,r)),r}function Bc(e,t,n,r,s){const{appear:i,mode:o,persisted:a=!1,onBeforeEnter:l,onEnter:u,onAfterEnter:d,onEnterCancelled:c,onBeforeLeave:f,onLeave:p,onAfterLeave:g,onLeaveCancelled:m,onBeforeAppear:y,onAppear:b,onAfterAppear:w,onAppearCancelled:S}=t,P=String(e.key),E=SC(n,e),T=(x,I)=>{x&&Rs(x,r,9,I)},C=(x,I)=>{const M=I[1];T(x,I),je(x)?x.every(O=>O.length<=1)&&M():x.length<=1&&M()},k={mode:o,persisted:a,beforeEnter(x){let I=l;if(!n.isMounted)if(i)I=y||l;else return;x[io]&&x[io](!0);const M=E[P];M&&ma(e,M)&&M.el[io]&&M.el[io](),T(I,[x])},enter(x){let I=u,M=d,O=c;if(!n.isMounted)if(i)I=b||u,M=w||d,O=S||c;else return;let A=!1;const D=x[tf]=V=>{A||(A=!0,V?T(O,[x]):T(M,[x]),k.delayedLeave&&k.delayedLeave(),x[tf]=void 0)};I?C(I,[x,D]):D()},leave(x,I){const M=String(e.key);if(x[tf]&&x[tf](!0),n.isUnmounting)return I();T(f,[x]);let O=!1;const A=x[io]=D=>{O||(O=!0,I(),D?T(m,[x]):T(g,[x]),x[io]=void 0,E[M]===e&&delete E[M])};E[M]=e,p?C(p,[x,A]):A()},clone(x){const I=Bc(x,t,n,r,s);return s&&s(I),I}};return k}function Um(e){if(Rp(e))return e=Fi(e),e.children=null,e}function FS(e){if(!Rp(e))return pC(e.type)&&e.children?wC(e.children):e;const{shapeFlag:t,children:n}=e;if(n){if(t&16)return n[0];if(t&32&&Qe(n.default))return n.default()}}function Ba(e,t){e.shapeFlag&6&&e.component?(e.transition=t,Ba(e.component.subTree,t)):e.shapeFlag&128?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function mb(e,t=!1,n){let r=[],s=0;for(let i=0;i<e.length;i++){let o=e[i];const a=n==null?o.key:String(n)+String(o.key!=null?o.key:i);o.type===Re?(o.patchFlag&128&&s++,r=r.concat(mb(o.children,t,a))):(t||o.type!==Zn)&&r.push(a!=null?Fi(o,{key:a}):o)}if(s>1)for(let i=0;i<r.length;i++)r[i].patchFlag=-2;return r}/*! #__NO_SIDE_EFFECTS__ */function Le(e,t){return Qe(e)?gn({name:e.name},t,{setup:e}):e}function _C(e){e.ids=[e.ids[0]+e.ids[2]+++"-",0,0]}function kh(e,t,n,r,s=!1){if(je(e)){e.forEach((g,m)=>kh(g,t&&(je(t)?t[m]:t),n,r,s));return}if(Bl(r)&&!s){r.shapeFlag&512&&r.type.__asyncResolved&&r.component.subTree.component&&kh(e,t,n,r.component.subTree);return}const i=r.shapeFlag&4?Lp(r.component):r.el,o=s?null:i,{i:a,r:l}=e,u=t&&t.r,d=a.refs===Ft?a.refs={}:a.refs,c=a.setupState,f=Be(c),p=c===Ft?()=>!1:g=>Et(f,g);if(u!=null&&u!==l&&(rn(u)?(d[u]=null,p(u)&&(c[u]=null)):tt(u)&&(u.value=null)),Qe(l))kd(l,a,12,[o,d]);else{const g=rn(l),m=tt(l);if(g||m){const y=()=>{if(e.f){const b=g?p(l)?c[l]:d[l]:l.value;s?je(b)&&ob(b,i):je(b)?b.includes(i)||b.push(i):g?(d[l]=[i],p(l)&&(c[l]=d[l])):(l.value=[i],e.k&&(d[e.k]=l.value))}else g?(d[l]=o,p(l)&&(c[l]=o)):m&&(l.value=o,e.k&&(d[e.k]=o))};o?(y.id=-1,cr(y,n)):y()}}}kp().requestIdleCallback;kp().cancelIdleCallback;const Bl=e=>!!e.type.__asyncLoader,Rp=e=>e.type.__isKeepAlive;function kC(e,t){xC(e,"a",t)}function gb(e,t){xC(e,"da",t)}function xC(e,t,n=An){const r=e.__wdc||(e.__wdc=()=>{let s=n;for(;s;){if(s.isDeactivated)return;s=s.parent}return e()});if(Ip(t,r,n),n){let s=n.parent;for(;s&&s.parent;)Rp(s.parent.vnode)&&uL(r,t,n,s),s=s.parent}}function uL(e,t,n,r){const s=Ip(t,e,r,!0);Op(()=>{ob(r[t],s)},n)}function Ip(e,t,n=An,r=!1){if(n){const s=n[e]||(n[e]=[]),i=t.__weh||(t.__weh=(...o)=>{Ho();const a=Ed(n),l=Rs(t,n,e,o);return a(),zo(),l});return r?s.unshift(i):s.push(i),i}}const qi=e=>(t,n=An)=>{(!Uc||e==="sp")&&Ip(e,(...r)=>t(...r),n)},Ap=qi("bm"),St=qi("m"),EC=qi("bu"),vb=qi("u"),Tn=qi("bum"),Op=qi("um"),cL=qi("sp"),dL=qi("rtg"),fL=qi("rtc");function hL(e,t=An){Ip("ec",e,t)}const yb="components",pL="directives";function Pr(e,t){return bb(yb,e,!0,t)||e}const mL=Symbol.for("v-ndc");function gL(e){return rn(e)&&bb(yb,e,!1)||e}function mr(e){return bb(pL,e)}function bb(e,t,n=!0,r=!1){const s=xn||An;if(s){const i=s.type;if(e===yb){const a=e$(i,!1);if(a&&(a===t||a===Or(t)||a===hi(Or(t))))return i}const o=NS(s[e]||i[e],t)||NS(s.appContext[e],t);return!o&&r?i:o}}function NS(e,t){return e&&(e[t]||e[Or(t)]||e[hi(Or(t))])}function Zt(e,t,n,r){let s;const i=n,o=je(e);if(o||rn(e)){const a=o&&Ro(e);let l=!1;a&&(l=!ds(e),e=Ep(e)),s=new Array(e.length);for(let u=0,d=e.length;u<d;u++)s[u]=t(l?Jn(e[u]):e[u],u,void 0,i)}else if(typeof e=="number"){s=new Array(e);for(let a=0;a<e;a++)s[a]=t(a+1,a,void 0,i)}else if(Yt(e))if(e[Symbol.iterator])s=Array.from(e,(a,l)=>t(a,l,void 0,i));else{const a=Object.keys(e);s=new Array(a.length);for(let l=0,u=a.length;l<u;l++){const d=a[l];s[l]=t(e[d],d,l,i)}}else s=[];return s}function CC(e,t){for(let n=0;n<t.length;n++){const r=t[n];if(je(r))for(let s=0;s<r.length;s++)e[r[s].name]=r[s].fn;else r&&(e[r.name]=r.key?(...s)=>{const i=r.fn(...s);return i&&(i.key=r.key),i}:r.fn)}return e}function Mp(e,t,n={},r,s){if(xn.ce||xn.parent&&Bl(xn.parent)&&xn.parent.ce)return $(),Q(Re,null,[h("slot",n,r&&r())],64);let i=e[t];i&&i._c&&(i._d=!1),$();const o=i&&PC(i(n)),a=n.key||o&&o.key,l=Q(Re,{key:(a&&!ji(a)?a:`_${t}`)+(!o&&r?"_fb":"")},o||(r?r():[]),o&&e._===1?64:-2);return l.scopeId&&(l.slotScopeIds=[l.scopeId+"-s"]),i&&i._c&&(i._d=!0),l}function PC(e){return e.some(t=>su(t)?!(t.type===Zn||t.type===Re&&!PC(t.children)):!0)?e:null}const iv=e=>e?WC(e)?Lp(e):iv(e.parent):null,wc=gn(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>iv(e.parent),$root:e=>iv(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>wb(e),$forceUpdate:e=>e.f||(e.f=()=>{pb(e.update)}),$nextTick:e=>e.n||(e.n=Ot.bind(e.proxy)),$watch:e=>FL.bind(e)}),Hm=(e,t)=>e!==Ft&&!e.__isScriptSetup&&Et(e,t),vL={get({_:e},t){if(t==="__v_skip")return!0;const{ctx:n,setupState:r,data:s,props:i,accessCache:o,type:a,appContext:l}=e;let u;if(t[0]!=="$"){const p=o[t];if(p!==void 0)switch(p){case 1:return r[t];case 2:return s[t];case 4:return n[t];case 3:return i[t]}else{if(Hm(r,t))return o[t]=1,r[t];if(s!==Ft&&Et(s,t))return o[t]=2,s[t];if((u=e.propsOptions[0])&&Et(u,t))return o[t]=3,i[t];if(n!==Ft&&Et(n,t))return o[t]=4,n[t];ov&&(o[t]=0)}}const d=wc[t];let c,f;if(d)return t==="$attrs"&&Qn(e.attrs,"get",""),d(e);if((c=a.__cssModules)&&(c=c[t]))return c;if(n!==Ft&&Et(n,t))return o[t]=4,n[t];if(f=l.config.globalProperties,Et(f,t))return f[t]},set({_:e},t,n){const{data:r,setupState:s,ctx:i}=e;return Hm(s,t)?(s[t]=n,!0):r!==Ft&&Et(r,t)?(r[t]=n,!0):Et(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(i[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:r,appContext:s,propsOptions:i}},o){let a;return!!n[o]||e!==Ft&&Et(e,o)||Hm(t,o)||(a=i[0])&&Et(a,o)||Et(r,o)||Et(wc,o)||Et(s.config.globalProperties,o)},defineProperty(e,t,n){return n.get!=null?e._.accessCache[t]=0:Et(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}};function BS(e){return je(e)?e.reduce((t,n)=>(t[n]=null,t),{}):e}let ov=!0;function yL(e){const t=wb(e),n=e.proxy,r=e.ctx;ov=!1,t.beforeCreate&&VS(t.beforeCreate,e,"bc");const{data:s,computed:i,methods:o,watch:a,provide:l,inject:u,created:d,beforeMount:c,mounted:f,beforeUpdate:p,updated:g,activated:m,deactivated:y,beforeDestroy:b,beforeUnmount:w,destroyed:S,unmounted:P,render:E,renderTracked:T,renderTriggered:C,errorCaptured:k,serverPrefetch:x,expose:I,inheritAttrs:M,components:O,directives:A,filters:D}=t;if(u&&bL(u,r,null),o)for(const G in o){const j=o[G];Qe(j)&&(r[G]=j.bind(n))}if(s){const G=s.call(n,n);Yt(G)&&(e.data=vn(G))}if(ov=!0,i)for(const G in i){const j=i[G],B=Qe(j)?j.bind(n,n):Qe(j.get)?j.get.bind(n,n):ai,W=!Qe(j)&&Qe(j.set)?j.set.bind(n):ai,Z=R({get:B,set:W});Object.defineProperty(r,G,{enumerable:!0,configurable:!0,get:()=>Z.value,set:q=>Z.value=q})}if(a)for(const G in a)TC(a[G],r,n,G);if(l){const G=Qe(l)?l.call(n):l;Reflect.ownKeys(G).forEach(j=>{Gt(j,G[j])})}d&&VS(d,e,"c");function H(G,j){je(j)?j.forEach(B=>G(B.bind(n))):j&&G(j.bind(n))}if(H(Ap,c),H(St,f),H(EC,p),H(vb,g),H(kC,m),H(gb,y),H(hL,k),H(fL,T),H(dL,C),H(Tn,w),H(Op,P),H(cL,x),je(I))if(I.length){const G=e.exposed||(e.exposed={});I.forEach(j=>{Object.defineProperty(G,j,{get:()=>n[j],set:B=>n[j]=B})})}else e.exposed||(e.exposed={});E&&e.render===ai&&(e.render=E),M!=null&&(e.inheritAttrs=M),O&&(e.components=O),A&&(e.directives=A),x&&_C(e)}function bL(e,t,n=ai){je(e)&&(e=av(e));for(const r in e){const s=e[r];let i;Yt(s)?"default"in s?i=Ye(s.from||r,s.default,!0):i=Ye(s.from||r):i=Ye(s),tt(i)?Object.defineProperty(t,r,{enumerable:!0,configurable:!0,get:()=>i.value,set:o=>i.value=o}):t[r]=i}}function VS(e,t,n){Rs(je(e)?e.map(r=>r.bind(t.proxy)):e.bind(t.proxy),t,n)}function TC(e,t,n,r){let s=r.includes(".")?UC(n,r):()=>n[r];if(rn(e)){const i=t[e];Qe(i)&&Ce(s,i)}else if(Qe(e))Ce(s,e.bind(n));else if(Yt(e))if(je(e))e.forEach(i=>TC(i,t,n,r));else{const i=Qe(e.handler)?e.handler.bind(n):t[e.handler];Qe(i)&&Ce(s,i,e)}}function wb(e){const t=e.type,{mixins:n,extends:r}=t,{mixins:s,optionsCache:i,config:{optionMergeStrategies:o}}=e.appContext,a=i.get(t);let l;return a?l=a:!s.length&&!n&&!r?l=t:(l={},s.length&&s.forEach(u=>xh(l,u,o,!0)),xh(l,t,o)),Yt(t)&&i.set(t,l),l}function xh(e,t,n,r=!1){const{mixins:s,extends:i}=t;i&&xh(e,i,n,!0),s&&s.forEach(o=>xh(e,o,n,!0));for(const o in t)if(!(r&&o==="expose")){const a=wL[o]||n&&n[o];e[o]=a?a(e[o],t[o]):t[o]}return e}const wL={data:US,props:HS,emits:HS,methods:uc,computed:uc,beforeCreate:or,created:or,beforeMount:or,mounted:or,beforeUpdate:or,updated:or,beforeDestroy:or,beforeUnmount:or,destroyed:or,unmounted:or,activated:or,deactivated:or,errorCaptured:or,serverPrefetch:or,components:uc,directives:uc,watch:_L,provide:US,inject:SL};function US(e,t){return t?e?function(){return gn(Qe(e)?e.call(this,this):e,Qe(t)?t.call(this,this):t)}:t:e}function SL(e,t){return uc(av(e),av(t))}function av(e){if(je(e)){const t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function or(e,t){return e?[...new Set([].concat(e,t))]:t}function uc(e,t){return e?gn(Object.create(null),e,t):t}function HS(e,t){return e?je(e)&&je(t)?[...new Set([...e,...t])]:gn(Object.create(null),BS(e),BS(t??{})):t}function _L(e,t){if(!e)return t;if(!t)return e;const n=gn(Object.create(null),e);for(const r in t)n[r]=or(e[r],t[r]);return n}function RC(){return{app:null,config:{isNativeTag:vD,performance:!1,globalProperties:{},optionMergeStrategies:{},errorHandler:void 0,warnHandler:void 0,compilerOptions:{}},mixins:[],components:{},directives:{},provides:Object.create(null),optionsCache:new WeakMap,propsCache:new WeakMap,emitsCache:new WeakMap}}let kL=0;function xL(e,t){return function(r,s=null){Qe(r)||(r=gn({},r)),s!=null&&!Yt(s)&&(s=null);const i=RC(),o=new WeakSet,a=[];let l=!1;const u=i.app={_uid:kL++,_component:r,_props:s,_container:null,_context:i,_instance:null,version:KC,get config(){return i.config},set config(d){},use(d,...c){return o.has(d)||(d&&Qe(d.install)?(o.add(d),d.install(u,...c)):Qe(d)&&(o.add(d),d(u,...c))),u},mixin(d){return i.mixins.includes(d)||i.mixins.push(d),u},component(d,c){return c?(i.components[d]=c,u):i.components[d]},directive(d,c){return c?(i.directives[d]=c,u):i.directives[d]},mount(d,c,f){if(!l){const p=u._ceVNode||h(r,s);return p.appContext=i,f===!0?f="svg":f===!1&&(f=void 0),c&&t?t(p,d):e(p,d,f),l=!0,u._container=d,d.__vue_app__=u,Lp(p.component)}},onUnmount(d){a.push(d)},unmount(){l&&(Rs(a,u._instance,16),e(null,u._container),delete u._container.__vue_app__)},provide(d,c){return i.provides[d]=c,u},runWithContext(d){const c=Ta;Ta=u;try{return d()}finally{Ta=c}}};return u}}let Ta=null;function Gt(e,t){if(An){let n=An.provides;const r=An.parent&&An.parent.provides;r===n&&(n=An.provides=Object.create(r)),n[e]=t}}function Ye(e,t,n=!1){const r=An||xn;if(r||Ta){const s=Ta?Ta._context.provides:r?r.parent==null?r.vnode.appContext&&r.vnode.appContext.provides:r.parent.provides:void 0;if(s&&e in s)return s[e];if(arguments.length>1)return n&&Qe(t)?t.call(r&&r.proxy):t}}function IC(){return!!(An||xn||Ta)}const AC={},OC=()=>Object.create(AC),MC=e=>Object.getPrototypeOf(e)===AC;function EL(e,t,n,r=!1){const s={},i=OC();e.propsDefaults=Object.create(null),DC(e,t,s,i);for(const o in e.propsOptions[0])o in s||(s[o]=void 0);n?e.props=r?s:Cp(s):e.type.props?e.props=s:e.props=i,e.attrs=i}function CL(e,t,n,r){const{props:s,attrs:i,vnode:{patchFlag:o}}=e,a=Be(s),[l]=e.propsOptions;let u=!1;if((r||o>0)&&!(o&16)){if(o&8){const d=e.vnode.dynamicProps;for(let c=0;c<d.length;c++){let f=d[c];if(Dp(e.emitsOptions,f))continue;const p=t[f];if(l)if(Et(i,f))p!==i[f]&&(i[f]=p,u=!0);else{const g=Or(f);s[g]=lv(l,a,g,p,e,!1)}else p!==i[f]&&(i[f]=p,u=!0)}}}else{DC(e,t,s,i)&&(u=!0);let d;for(const c in a)(!t||!Et(t,c)&&((d=Uo(c))===c||!Et(t,d)))&&(l?n&&(n[c]!==void 0||n[d]!==void 0)&&(s[c]=lv(l,a,c,void 0,e,!0)):delete s[c]);if(i!==a)for(const c in i)(!t||!Et(t,c))&&(delete i[c],u=!0)}u&&Ai(e.attrs,"set","")}function DC(e,t,n,r){const[s,i]=e.propsOptions;let o=!1,a;if(t)for(let l in t){if(gc(l))continue;const u=t[l];let d;s&&Et(s,d=Or(l))?!i||!i.includes(d)?n[d]=u:(a||(a={}))[d]=u:Dp(e.emitsOptions,l)||(!(l in r)||u!==r[l])&&(r[l]=u,o=!0)}if(i){const l=Be(n),u=a||Ft;for(let d=0;d<i.length;d++){const c=i[d];n[c]=lv(s,l,c,u[c],e,!Et(u,c))}}return o}function lv(e,t,n,r,s,i){const o=e[n];if(o!=null){const a=Et(o,"default");if(a&&r===void 0){const l=o.default;if(o.type!==Function&&!o.skipFactory&&Qe(l)){const{propsDefaults:u}=s;if(n in u)r=u[n];else{const d=Ed(s);r=u[n]=l.call(null,t),d()}}else r=l;s.ce&&s.ce._setProp(n,r)}o[0]&&(i&&!a?r=!1:o[1]&&(r===""||r===Uo(n))&&(r=!0))}return r}const PL=new WeakMap;function LC(e,t,n=!1){const r=n?PL:t.propsCache,s=r.get(e);if(s)return s;const i=e.props,o={},a=[];let l=!1;if(!Qe(e)){const d=c=>{l=!0;const[f,p]=LC(c,t,!0);gn(o,f),p&&a.push(...p)};!n&&t.mixins.length&&t.mixins.forEach(d),e.extends&&d(e.extends),e.mixins&&e.mixins.forEach(d)}if(!i&&!l)return Yt(e)&&r.set(e,$l),$l;if(je(i))for(let d=0;d<i.length;d++){const c=Or(i[d]);zS(c)&&(o[c]=Ft)}else if(i)for(const d in i){const c=Or(d);if(zS(c)){const f=i[d],p=o[c]=je(f)||Qe(f)?{type:f}:gn({},f),g=p.type;let m=!1,y=!0;if(je(g))for(let b=0;b<g.length;++b){const w=g[b],S=Qe(w)&&w.name;if(S==="Boolean"){m=!0;break}else S==="String"&&(y=!1)}else m=Qe(g)&&g.name==="Boolean";p[0]=m,p[1]=y,(m||Et(p,"default"))&&a.push(c)}}const u=[o,a];return Yt(e)&&r.set(e,u),u}function zS(e){return e[0]!=="$"&&!gc(e)}const $C=e=>e[0]==="_"||e==="$stable",Sb=e=>je(e)?e.map(ti):[ti(e)],TL=(e,t,n)=>{if(t._n)return t;const r=v((...s)=>Sb(t(...s)),n);return r._c=!1,r},FC=(e,t,n)=>{const r=e._ctx;for(const s in e){if($C(s))continue;const i=e[s];if(Qe(i))t[s]=TL(s,i,r);else if(i!=null){const o=Sb(i);t[s]=()=>o}}},NC=(e,t)=>{const n=Sb(t);e.slots.default=()=>n},BC=(e,t,n)=>{for(const r in t)(n||r!=="_")&&(e[r]=t[r])},RL=(e,t,n)=>{const r=e.slots=OC();if(e.vnode.shapeFlag&32){const s=t._;s?(BC(r,t,n),n&&VE(r,"_",s,!0)):FC(t,r)}else t&&NC(e,t)},IL=(e,t,n)=>{const{vnode:r,slots:s}=e;let i=!0,o=Ft;if(r.shapeFlag&32){const a=t._;a?n&&a===1?i=!1:BC(s,t,n):(i=!t.$stable,FC(t,s)),o=t}else t&&(NC(e,t),o={default:1});if(i)for(const a in s)!$C(a)&&o[a]==null&&delete s[a]},cr=jL;function AL(e){return OL(e)}function OL(e,t){const n=kp();n.__VUE__=!0;const{insert:r,remove:s,patchProp:i,createElement:o,createText:a,createComment:l,setText:u,setElementText:d,parentNode:c,nextSibling:f,setScopeId:p=ai,insertStaticContent:g}=e,m=(F,N,ee,se=null,oe=null,ge=null,Ee=void 0,ye=null,ke=!!N.dynamicChildren)=>{if(F===N)return;F&&!ma(F,N)&&(se=J(F),q(F,oe,ge,!0),F=null),N.patchFlag===-2&&(ke=!1,N.dynamicChildren=null);const{type:fe,ref:Ae,shapeFlag:_e}=N;switch(fe){case xd:y(F,N,ee,se);break;case Zn:b(F,N,ee,se);break;case qm:F==null&&w(N,ee,se,Ee);break;case Re:O(F,N,ee,se,oe,ge,Ee,ye,ke);break;default:_e&1?E(F,N,ee,se,oe,ge,Ee,ye,ke):_e&6?A(F,N,ee,se,oe,ge,Ee,ye,ke):(_e&64||_e&128)&&fe.process(F,N,ee,se,oe,ge,Ee,ye,ke,te)}Ae!=null&&oe&&kh(Ae,F&&F.ref,ge,N||F,!N)},y=(F,N,ee,se)=>{if(F==null)r(N.el=a(N.children),ee,se);else{const oe=N.el=F.el;N.children!==F.children&&u(oe,N.children)}},b=(F,N,ee,se)=>{F==null?r(N.el=l(N.children||""),ee,se):N.el=F.el},w=(F,N,ee,se)=>{[F.el,F.anchor]=g(F.children,N,ee,se,F.el,F.anchor)},S=({el:F,anchor:N},ee,se)=>{let oe;for(;F&&F!==N;)oe=f(F),r(F,ee,se),F=oe;r(N,ee,se)},P=({el:F,anchor:N})=>{let ee;for(;F&&F!==N;)ee=f(F),s(F),F=ee;s(N)},E=(F,N,ee,se,oe,ge,Ee,ye,ke)=>{N.type==="svg"?Ee="svg":N.type==="math"&&(Ee="mathml"),F==null?T(N,ee,se,oe,ge,Ee,ye,ke):x(F,N,oe,ge,Ee,ye,ke)},T=(F,N,ee,se,oe,ge,Ee,ye)=>{let ke,fe;const{props:Ae,shapeFlag:_e,transition:$e,dirs:We}=F;if(ke=F.el=o(F.type,ge,Ae&&Ae.is,Ae),_e&8?d(ke,F.children):_e&16&&k(F.children,ke,null,se,oe,zm(F,ge),Ee,ye),We&&na(F,null,se,"created"),C(ke,F,F.scopeId,Ee,se),Ae){for(const Vt in Ae)Vt!=="value"&&!gc(Vt)&&i(ke,Vt,null,Ae[Vt],ge,se);"value"in Ae&&i(ke,"value",null,Ae.value,ge),(fe=Ae.onVnodeBeforeMount)&&zs(fe,se,F)}We&&na(F,null,se,"beforeMount");const gt=ML(oe,$e);gt&&$e.beforeEnter(ke),r(ke,N,ee),((fe=Ae&&Ae.onVnodeMounted)||gt||We)&&cr(()=>{fe&&zs(fe,se,F),gt&&$e.enter(ke),We&&na(F,null,se,"mounted")},oe)},C=(F,N,ee,se,oe)=>{if(ee&&p(F,ee),se)for(let ge=0;ge<se.length;ge++)p(F,se[ge]);if(oe){let ge=oe.subTree;if(N===ge||zC(ge.type)&&(ge.ssContent===N||ge.ssFallback===N)){const Ee=oe.vnode;C(F,Ee,Ee.scopeId,Ee.slotScopeIds,oe.parent)}}},k=(F,N,ee,se,oe,ge,Ee,ye,ke=0)=>{for(let fe=ke;fe<F.length;fe++){const Ae=F[fe]=ye?oo(F[fe]):ti(F[fe]);m(null,Ae,N,ee,se,oe,ge,Ee,ye)}},x=(F,N,ee,se,oe,ge,Ee)=>{const ye=N.el=F.el;let{patchFlag:ke,dynamicChildren:fe,dirs:Ae}=N;ke|=F.patchFlag&16;const _e=F.props||Ft,$e=N.props||Ft;let We;if(ee&&ra(ee,!1),(We=$e.onVnodeBeforeUpdate)&&zs(We,ee,N,F),Ae&&na(N,F,ee,"beforeUpdate"),ee&&ra(ee,!0),(_e.innerHTML&&$e.innerHTML==null||_e.textContent&&$e.textContent==null)&&d(ye,""),fe?I(F.dynamicChildren,fe,ye,ee,se,zm(N,oe),ge):Ee||j(F,N,ye,null,ee,se,zm(N,oe),ge,!1),ke>0){if(ke&16)M(ye,_e,$e,ee,oe);else if(ke&2&&_e.class!==$e.class&&i(ye,"class",null,$e.class,oe),ke&4&&i(ye,"style",_e.style,$e.style,oe),ke&8){const gt=N.dynamicProps;for(let Vt=0;Vt<gt.length;Vt++){const Tt=gt[Vt],Br=_e[Tt],Wn=$e[Tt];(Wn!==Br||Tt==="value")&&i(ye,Tt,Br,Wn,oe,ee)}}ke&1&&F.children!==N.children&&d(ye,N.children)}else!Ee&&fe==null&&M(ye,_e,$e,ee,oe);((We=$e.onVnodeUpdated)||Ae)&&cr(()=>{We&&zs(We,ee,N,F),Ae&&na(N,F,ee,"updated")},se)},I=(F,N,ee,se,oe,ge,Ee)=>{for(let ye=0;ye<N.length;ye++){const ke=F[ye],fe=N[ye],Ae=ke.el&&(ke.type===Re||!ma(ke,fe)||ke.shapeFlag&70)?c(ke.el):ee;m(ke,fe,Ae,null,se,oe,ge,Ee,!0)}},M=(F,N,ee,se,oe)=>{if(N!==ee){if(N!==Ft)for(const ge in N)!gc(ge)&&!(ge in ee)&&i(F,ge,N[ge],null,oe,se);for(const ge in ee){if(gc(ge))continue;const Ee=ee[ge],ye=N[ge];Ee!==ye&&ge!=="value"&&i(F,ge,ye,Ee,oe,se)}"value"in ee&&i(F,"value",N.value,ee.value,oe)}},O=(F,N,ee,se,oe,ge,Ee,ye,ke)=>{const fe=N.el=F?F.el:a(""),Ae=N.anchor=F?F.anchor:a("");let{patchFlag:_e,dynamicChildren:$e,slotScopeIds:We}=N;We&&(ye=ye?ye.concat(We):We),F==null?(r(fe,ee,se),r(Ae,ee,se),k(N.children||[],ee,Ae,oe,ge,Ee,ye,ke)):_e>0&&_e&64&&$e&&F.dynamicChildren?(I(F.dynamicChildren,$e,ee,oe,ge,Ee,ye),(N.key!=null||oe&&N===oe.subTree)&&_b(F,N,!0)):j(F,N,ee,Ae,oe,ge,Ee,ye,ke)},A=(F,N,ee,se,oe,ge,Ee,ye,ke)=>{N.slotScopeIds=ye,F==null?N.shapeFlag&512?oe.ctx.activate(N,ee,se,Ee,ke):D(N,ee,se,oe,ge,Ee,ke):V(F,N,ke)},D=(F,N,ee,se,oe,ge,Ee)=>{const ye=F.component=YL(F,se,oe);if(Rp(F)&&(ye.ctx.renderer=te),XL(ye,!1,Ee),ye.asyncDep){if(oe&&oe.registerDep(ye,H,Ee),!F.el){const ke=ye.subTree=h(Zn);b(null,ke,N,ee)}}else H(ye,F,N,ee,oe,ge,Ee)},V=(F,N,ee)=>{const se=N.component=F.component;if(HL(F,N,ee))if(se.asyncDep&&!se.asyncResolved){G(se,N,ee);return}else se.next=N,se.update();else N.el=F.el,se.vnode=N},H=(F,N,ee,se,oe,ge,Ee)=>{const ye=()=>{if(F.isMounted){let{next:_e,bu:$e,u:We,parent:gt,vnode:Vt}=F;{const Vr=VC(F);if(Vr){_e&&(_e.el=Vt.el,G(F,_e,Ee)),Vr.asyncDep.then(()=>{F.isUnmounted||ye()});return}}let Tt=_e,Br;ra(F,!1),_e?(_e.el=Vt.el,G(F,_e,Ee)):_e=Vt,$e&&qf($e),(Br=_e.props&&_e.props.onVnodeBeforeUpdate)&&zs(Br,gt,_e,Vt),ra(F,!0);const Wn=jm(F),Ss=F.subTree;F.subTree=Wn,m(Ss,Wn,c(Ss.el),J(Ss),F,oe,ge),_e.el=Wn.el,Tt===null&&zL(F,Wn.el),We&&cr(We,oe),(Br=_e.props&&_e.props.onVnodeUpdated)&&cr(()=>zs(Br,gt,_e,Vt),oe)}else{let _e;const{el:$e,props:We}=N,{bm:gt,m:Vt,parent:Tt,root:Br,type:Wn}=F,Ss=Bl(N);if(ra(F,!1),gt&&qf(gt),!Ss&&(_e=We&&We.onVnodeBeforeMount)&&zs(_e,Tt,N),ra(F,!0),$e&&ze){const Vr=()=>{F.subTree=jm(F),ze($e,F.subTree,F,oe,null)};Ss&&Wn.__asyncHydrate?Wn.__asyncHydrate($e,F,Vr):Vr()}else{Br.ce&&Br.ce._injectChildStyle(Wn);const Vr=F.subTree=jm(F);m(null,Vr,ee,se,F,oe,ge),N.el=Vr.el}if(Vt&&cr(Vt,oe),!Ss&&(_e=We&&We.onVnodeMounted)){const Vr=N;cr(()=>zs(_e,Tt,Vr),oe)}(N.shapeFlag&256||Tt&&Bl(Tt.vnode)&&Tt.vnode.shapeFlag&256)&&F.a&&cr(F.a,oe),F.isMounted=!0,N=ee=se=null}};F.scope.on();const ke=F.effect=new qE(ye);F.scope.off();const fe=F.update=ke.run.bind(ke),Ae=F.job=ke.runIfDirty.bind(ke);Ae.i=F,Ae.id=F.uid,ke.scheduler=()=>pb(Ae),ra(F,!0),fe()},G=(F,N,ee)=>{N.component=F;const se=F.vnode.props;F.vnode=N,F.next=null,CL(F,N.props,se,ee),IL(F,N.children,ee),Ho(),MS(F),zo()},j=(F,N,ee,se,oe,ge,Ee,ye,ke=!1)=>{const fe=F&&F.children,Ae=F?F.shapeFlag:0,_e=N.children,{patchFlag:$e,shapeFlag:We}=N;if($e>0){if($e&128){W(fe,_e,ee,se,oe,ge,Ee,ye,ke);return}else if($e&256){B(fe,_e,ee,se,oe,ge,Ee,ye,ke);return}}We&8?(Ae&16&&le(fe,oe,ge),_e!==fe&&d(ee,_e)):Ae&16?We&16?W(fe,_e,ee,se,oe,ge,Ee,ye,ke):le(fe,oe,ge,!0):(Ae&8&&d(ee,""),We&16&&k(_e,ee,se,oe,ge,Ee,ye,ke))},B=(F,N,ee,se,oe,ge,Ee,ye,ke)=>{F=F||$l,N=N||$l;const fe=F.length,Ae=N.length,_e=Math.min(fe,Ae);let $e;for($e=0;$e<_e;$e++){const We=N[$e]=ke?oo(N[$e]):ti(N[$e]);m(F[$e],We,ee,null,oe,ge,Ee,ye,ke)}fe>Ae?le(F,oe,ge,!0,!1,_e):k(N,ee,se,oe,ge,Ee,ye,ke,_e)},W=(F,N,ee,se,oe,ge,Ee,ye,ke)=>{let fe=0;const Ae=N.length;let _e=F.length-1,$e=Ae-1;for(;fe<=_e&&fe<=$e;){const We=F[fe],gt=N[fe]=ke?oo(N[fe]):ti(N[fe]);if(ma(We,gt))m(We,gt,ee,null,oe,ge,Ee,ye,ke);else break;fe++}for(;fe<=_e&&fe<=$e;){const We=F[_e],gt=N[$e]=ke?oo(N[$e]):ti(N[$e]);if(ma(We,gt))m(We,gt,ee,null,oe,ge,Ee,ye,ke);else break;_e--,$e--}if(fe>_e){if(fe<=$e){const We=$e+1,gt=We<Ae?N[We].el:se;for(;fe<=$e;)m(null,N[fe]=ke?oo(N[fe]):ti(N[fe]),ee,gt,oe,ge,Ee,ye,ke),fe++}}else if(fe>$e)for(;fe<=_e;)q(F[fe],oe,ge,!0),fe++;else{const We=fe,gt=fe,Vt=new Map;for(fe=gt;fe<=$e;fe++){const Ur=N[fe]=ke?oo(N[fe]):ti(N[fe]);Ur.key!=null&&Vt.set(Ur.key,fe)}let Tt,Br=0;const Wn=$e-gt+1;let Ss=!1,Vr=0;const Wu=new Array(Wn);for(fe=0;fe<Wn;fe++)Wu[fe]=0;for(fe=We;fe<=_e;fe++){const Ur=F[fe];if(Br>=Wn){q(Ur,oe,ge,!0);continue}let Hs;if(Ur.key!=null)Hs=Vt.get(Ur.key);else for(Tt=gt;Tt<=$e;Tt++)if(Wu[Tt-gt]===0&&ma(Ur,N[Tt])){Hs=Tt;break}Hs===void 0?q(Ur,oe,ge,!0):(Wu[Hs-gt]=fe+1,Hs>=Vr?Vr=Hs:Ss=!0,m(Ur,N[Hs],ee,null,oe,ge,Ee,ye,ke),Br++)}const PS=Ss?DL(Wu):$l;for(Tt=PS.length-1,fe=Wn-1;fe>=0;fe--){const Ur=gt+fe,Hs=N[Ur],TS=Ur+1<Ae?N[Ur+1].el:se;Wu[fe]===0?m(null,Hs,ee,TS,oe,ge,Ee,ye,ke):Ss&&(Tt<0||fe!==PS[Tt]?Z(Hs,ee,TS,2):Tt--)}}},Z=(F,N,ee,se,oe=null)=>{const{el:ge,type:Ee,transition:ye,children:ke,shapeFlag:fe}=F;if(fe&6){Z(F.component.subTree,N,ee,se);return}if(fe&128){F.suspense.move(N,ee,se);return}if(fe&64){Ee.move(F,N,ee,te);return}if(Ee===Re){r(ge,N,ee);for(let _e=0;_e<ke.length;_e++)Z(ke[_e],N,ee,se);r(F.anchor,N,ee);return}if(Ee===qm){S(F,N,ee);return}if(se!==2&&fe&1&&ye)if(se===0)ye.beforeEnter(ge),r(ge,N,ee),cr(()=>ye.enter(ge),oe);else{const{leave:_e,delayLeave:$e,afterLeave:We}=ye,gt=()=>r(ge,N,ee),Vt=()=>{_e(ge,()=>{gt(),We&&We()})};$e?$e(ge,gt,Vt):Vt()}else r(ge,N,ee)},q=(F,N,ee,se=!1,oe=!1)=>{const{type:ge,props:Ee,ref:ye,children:ke,dynamicChildren:fe,shapeFlag:Ae,patchFlag:_e,dirs:$e,cacheIndex:We}=F;if(_e===-2&&(oe=!1),ye!=null&&kh(ye,null,ee,F,!0),We!=null&&(N.renderCache[We]=void 0),Ae&256){N.ctx.deactivate(F);return}const gt=Ae&1&&$e,Vt=!Bl(F);let Tt;if(Vt&&(Tt=Ee&&Ee.onVnodeBeforeUnmount)&&zs(Tt,N,F),Ae&6)ue(F.component,ee,se);else{if(Ae&128){F.suspense.unmount(ee,se);return}gt&&na(F,null,N,"beforeUnmount"),Ae&64?F.type.remove(F,N,ee,te,se):fe&&!fe.hasOnce&&(ge!==Re||_e>0&&_e&64)?le(fe,N,ee,!1,!0):(ge===Re&&_e&384||!oe&&Ae&16)&&le(ke,N,ee),se&&K(F)}(Vt&&(Tt=Ee&&Ee.onVnodeUnmounted)||gt)&&cr(()=>{Tt&&zs(Tt,N,F),gt&&na(F,null,N,"unmounted")},ee)},K=F=>{const{type:N,el:ee,anchor:se,transition:oe}=F;if(N===Re){pe(ee,se);return}if(N===qm){P(F);return}const ge=()=>{s(ee),oe&&!oe.persisted&&oe.afterLeave&&oe.afterLeave()};if(F.shapeFlag&1&&oe&&!oe.persisted){const{leave:Ee,delayLeave:ye}=oe,ke=()=>Ee(ee,ge);ye?ye(F.el,ge,ke):ke()}else ge()},pe=(F,N)=>{let ee;for(;F!==N;)ee=f(F),s(F),F=ee;s(N)},ue=(F,N,ee)=>{const{bum:se,scope:oe,job:ge,subTree:Ee,um:ye,m:ke,a:fe}=F;jS(ke),jS(fe),se&&qf(se),oe.stop(),ge&&(ge.flags|=8,q(Ee,F,N,ee)),ye&&cr(ye,N),cr(()=>{F.isUnmounted=!0},N),N&&N.pendingBranch&&!N.isUnmounted&&F.asyncDep&&!F.asyncResolved&&F.suspenseId===N.pendingId&&(N.deps--,N.deps===0&&N.resolve())},le=(F,N,ee,se=!1,oe=!1,ge=0)=>{for(let Ee=ge;Ee<F.length;Ee++)q(F[Ee],N,ee,se,oe)},J=F=>{if(F.shapeFlag&6)return J(F.component.subTree);if(F.shapeFlag&128)return F.suspense.next();const N=f(F.anchor||F.el),ee=N&&N[hC];return ee?f(ee):N};let be=!1;const Se=(F,N,ee)=>{F==null?N._vnode&&q(N._vnode,null,null,!0):m(N._vnode||null,F,N,null,null,null,ee),N._vnode=F,be||(be=!0,MS(),cC(),be=!1)},te={p:m,um:q,m:Z,r:K,mt:D,mc:k,pc:j,pbc:I,n:J,o:e};let Y,ze;return{render:Se,hydrate:Y,createApp:xL(Se,Y)}}function zm({type:e,props:t},n){return n==="svg"&&e==="foreignObject"||n==="mathml"&&e==="annotation-xml"&&t&&t.encoding&&t.encoding.includes("html")?void 0:n}function ra({effect:e,job:t},n){n?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function ML(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function _b(e,t,n=!1){const r=e.children,s=t.children;if(je(r)&&je(s))for(let i=0;i<r.length;i++){const o=r[i];let a=s[i];a.shapeFlag&1&&!a.dynamicChildren&&((a.patchFlag<=0||a.patchFlag===32)&&(a=s[i]=oo(s[i]),a.el=o.el),!n&&a.patchFlag!==-2&&_b(o,a)),a.type===xd&&(a.el=o.el)}}function DL(e){const t=e.slice(),n=[0];let r,s,i,o,a;const l=e.length;for(r=0;r<l;r++){const u=e[r];if(u!==0){if(s=n[n.length-1],e[s]<u){t[r]=s,n.push(r);continue}for(i=0,o=n.length-1;i<o;)a=i+o>>1,e[n[a]]<u?i=a+1:o=a;u<e[n[i]]&&(i>0&&(t[r]=n[i-1]),n[i]=r)}}for(i=n.length,o=n[i-1];i-- >0;)n[i]=o,o=t[o];return n}function VC(e){const t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:VC(t)}function jS(e){if(e)for(let t=0;t<e.length;t++)e[t].flags|=8}const LL=Symbol.for("v-scx"),$L=()=>Ye(LL);function jn(e,t){return kb(e,null,t)}function Ce(e,t,n){return kb(e,t,n)}function kb(e,t,n=Ft){const{immediate:r,deep:s,flush:i,once:o}=n,a=gn({},n),l=t&&r||!t&&i!=="post";let u;if(Uc){if(i==="sync"){const p=$L();u=p.__watcherHandles||(p.__watcherHandles=[])}else if(!l){const p=()=>{};return p.stop=ai,p.resume=ai,p.pause=ai,p}}const d=An;a.call=(p,g,m)=>Rs(p,d,g,m);let c=!1;i==="post"?a.scheduler=p=>{cr(p,d&&d.suspense)}:i!=="sync"&&(c=!0,a.scheduler=(p,g)=>{g?p():pb(p)}),a.augmentJob=p=>{t&&(p.flags|=4),c&&(p.flags|=2,d&&(p.id=d.uid,p.i=d))};const f=tL(e,t,a);return Uc&&(u?u.push(f):l&&f()),f}function FL(e,t,n){const r=this.proxy,s=rn(e)?e.includes(".")?UC(r,e):()=>r[e]:e.bind(r,r);let i;Qe(t)?i=t:(i=t.handler,n=t);const o=Ed(this),a=kb(s,i.bind(r),n);return o(),a}function UC(e,t){const n=t.split(".");return()=>{let r=e;for(let s=0;s<n.length&&r;s++)r=r[n[s]];return r}}const NL=(e,t)=>t==="modelValue"||t==="model-value"?e.modelModifiers:e[`${t}Modifiers`]||e[`${Or(t)}Modifiers`]||e[`${Uo(t)}Modifiers`];function BL(e,t,...n){if(e.isUnmounted)return;const r=e.vnode.props||Ft;let s=n;const i=t.startsWith("update:"),o=i&&NL(r,t.slice(7));o&&(o.trim&&(s=n.map(d=>rn(d)?d.trim():d)),o.number&&(s=n.map(Jg)));let a,l=r[a=$m(t)]||r[a=$m(Or(t))];!l&&i&&(l=r[a=$m(Uo(t))]),l&&Rs(l,e,6,s);const u=r[a+"Once"];if(u){if(!e.emitted)e.emitted={};else if(e.emitted[a])return;e.emitted[a]=!0,Rs(u,e,6,s)}}function HC(e,t,n=!1){const r=t.emitsCache,s=r.get(e);if(s!==void 0)return s;const i=e.emits;let o={},a=!1;if(!Qe(e)){const l=u=>{const d=HC(u,t,!0);d&&(a=!0,gn(o,d))};!n&&t.mixins.length&&t.mixins.forEach(l),e.extends&&l(e.extends),e.mixins&&e.mixins.forEach(l)}return!i&&!a?(Yt(e)&&r.set(e,null),null):(je(i)?i.forEach(l=>o[l]=null):gn(o,i),Yt(e)&&r.set(e,o),o)}function Dp(e,t){return!e||!wp(t)?!1:(t=t.slice(2).replace(/Once$/,""),Et(e,t[0].toLowerCase()+t.slice(1))||Et(e,Uo(t))||Et(e,t))}function jm(e){const{type:t,vnode:n,proxy:r,withProxy:s,propsOptions:[i],slots:o,attrs:a,emit:l,render:u,renderCache:d,props:c,data:f,setupState:p,ctx:g,inheritAttrs:m}=e,y=_h(e);let b,w;try{if(n.shapeFlag&4){const P=s||r,E=P;b=ti(u.call(E,P,d,c,p,f,g)),w=a}else{const P=t;b=ti(P.length>1?P(c,{attrs:a,slots:o,emit:l}):P(c,null)),w=t.props?a:VL(a)}}catch(P){Sc.length=0,Tp(P,e,1),b=h(Zn)}let S=b;if(w&&m!==!1){const P=Object.keys(w),{shapeFlag:E}=S;P.length&&E&7&&(i&&P.some(ib)&&(w=UL(w,i)),S=Fi(S,w,!1,!0))}return n.dirs&&(S=Fi(S,null,!1,!0),S.dirs=S.dirs?S.dirs.concat(n.dirs):n.dirs),n.transition&&Ba(S,n.transition),b=S,_h(y),b}const VL=e=>{let t;for(const n in e)(n==="class"||n==="style"||wp(n))&&((t||(t={}))[n]=e[n]);return t},UL=(e,t)=>{const n={};for(const r in e)(!ib(r)||!(r.slice(9)in t))&&(n[r]=e[r]);return n};function HL(e,t,n){const{props:r,children:s,component:i}=e,{props:o,children:a,patchFlag:l}=t,u=i.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&l>=0){if(l&1024)return!0;if(l&16)return r?qS(r,o,u):!!o;if(l&8){const d=t.dynamicProps;for(let c=0;c<d.length;c++){const f=d[c];if(o[f]!==r[f]&&!Dp(u,f))return!0}}}else return(s||a)&&(!a||!a.$stable)?!0:r===o?!1:r?o?qS(r,o,u):!0:!!o;return!1}function qS(e,t,n){const r=Object.keys(t);if(r.length!==Object.keys(e).length)return!0;for(let s=0;s<r.length;s++){const i=r[s];if(t[i]!==e[i]&&!Dp(n,i))return!0}return!1}function zL({vnode:e,parent:t},n){for(;t;){const r=t.subTree;if(r.suspense&&r.suspense.activeBranch===e&&(r.el=e.el),r===e)(e=t.vnode).el=n,t=t.parent;else break}}const zC=e=>e.__isSuspense;function jL(e,t){t&&t.pendingBranch?je(e)?t.effects.push(...e):t.effects.push(e):sL(e)}const Re=Symbol.for("v-fgt"),xd=Symbol.for("v-txt"),Zn=Symbol.for("v-cmt"),qm=Symbol.for("v-stc"),Sc=[];let Kr=null;function $(e=!1){Sc.push(Kr=e?null:[])}function qL(){Sc.pop(),Kr=Sc[Sc.length-1]||null}let Vc=1;function WS(e,t=!1){Vc+=e,e<0&&Kr&&t&&(Kr.hasOnce=!0)}function jC(e){return e.dynamicChildren=Vc>0?Kr||$l:null,qL(),Vc>0&&Kr&&Kr.push(e),e}function we(e,t,n,r,s,i){return jC(L(e,t,n,r,s,i,!0))}function Q(e,t,n,r,s){return jC(h(e,t,n,r,s,!0))}function su(e){return e?e.__v_isVNode===!0:!1}function ma(e,t){return e.type===t.type&&e.key===t.key}const qC=({key:e})=>e??null,Gf=({ref:e,ref_key:t,ref_for:n})=>(typeof e=="number"&&(e=""+e),e!=null?rn(e)||tt(e)||Qe(e)?{i:xn,r:e,k:t,f:!!n}:e:null);function L(e,t=null,n=null,r=0,s=null,i=e===Re?0:1,o=!1,a=!1){const l={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&qC(t),ref:t&&Gf(t),scopeId:fC,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag:i,patchFlag:r,dynamicProps:s,dynamicChildren:null,appContext:null,ctx:xn};return a?(xb(l,n),i&128&&e.normalize(l)):n&&(l.shapeFlag|=rn(n)?8:16),Vc>0&&!o&&Kr&&(l.patchFlag>0||i&6)&&l.patchFlag!==32&&Kr.push(l),l}const h=WL;function WL(e,t=null,n=null,r=0,s=null,i=!1){if((!e||e===mL)&&(e=Zn),su(e)){const a=Fi(e,t,!0);return n&&xb(a,n),Vc>0&&!i&&Kr&&(a.shapeFlag&6?Kr[Kr.indexOf(e)]=a:Kr.push(a)),a.patchFlag=-2,a}if(t$(e)&&(e=e.__vccOpts),t){t=Eh(t);let{class:a,style:l}=t;a&&!rn(a)&&(t.class=Ja(a)),Yt(l)&&(_d(l)&&!je(l)&&(l=gn({},l)),t.style=ci(l))}const o=rn(e)?1:zC(e)?128:pC(e)?64:Yt(e)?4:Qe(e)?2:0;return L(e,t,n,r,s,o,i,!0)}function Eh(e){return e?_d(e)||MC(e)?gn({},e):e:null}function Fi(e,t,n=!1,r=!1){const{props:s,ref:i,patchFlag:o,children:a,transition:l}=e,u=t?me(s||{},t):s,d={__v_isVNode:!0,__v_skip:!0,type:e.type,props:u,key:u&&qC(u),ref:t&&t.ref?n&&i?je(i)?i.concat(Gf(t)):[i,Gf(t)]:Gf(t):i,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:a,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==Re?o===-1?16:o|16:o,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:l,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&Fi(e.ssContent),ssFallback:e.ssFallback&&Fi(e.ssFallback),el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return l&&r&&Ba(d,l.clone(d)),d}function _(e=" ",t=0){return h(xd,null,e,t)}function ve(e="",t=!1){return t?($(),Q(Zn,null,e)):h(Zn,null,e)}function ti(e){return e==null||typeof e=="boolean"?h(Zn):je(e)?h(Re,null,e.slice()):su(e)?oo(e):h(xd,null,String(e))}function oo(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:Fi(e)}function xb(e,t){let n=0;const{shapeFlag:r}=e;if(t==null)t=null;else if(je(t))n=16;else if(typeof t=="object")if(r&65){const s=t.default;s&&(s._c&&(s._d=!1),xb(e,s()),s._c&&(s._d=!0));return}else{n=32;const s=t._;!s&&!MC(t)?t._ctx=xn:s===3&&xn&&(xn.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else Qe(t)?(t={default:t,_ctx:xn},n=32):(t=String(t),r&64?(n=16,t=[_(t)]):n=8);e.children=t,e.shapeFlag|=n}function me(...e){const t={};for(let n=0;n<e.length;n++){const r=e[n];for(const s in r)if(s==="class")t.class!==r.class&&(t.class=Ja([t.class,r.class]));else if(s==="style")t.style=ci([t.style,r.style]);else if(wp(s)){const i=t[s],o=r[s];o&&i!==o&&!(je(i)&&i.includes(o))&&(t[s]=i?[].concat(i,o):o)}else s!==""&&(t[s]=r[s])}return t}function zs(e,t,n,r=null){Rs(e,t,7,[n,r])}const GL=RC();let KL=0;function YL(e,t,n){const r=e.type,s=(t?t.appContext:e.appContext)||GL,i={uid:KL++,vnode:e,type:r,parent:t,appContext:s,root:null,next:null,subTree:null,effect:null,update:null,job:null,scope:new jE(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(s.provides),ids:t?t.ids:["",0,0],accessCache:null,renderCache:[],components:null,directives:null,propsOptions:LC(r,s),emitsOptions:HC(r,s),emit:null,emitted:null,propsDefaults:Ft,inheritAttrs:r.inheritAttrs,ctx:Ft,data:Ft,props:Ft,attrs:Ft,slots:Ft,refs:Ft,setupState:Ft,setupContext:null,suspense:n,suspenseId:n?n.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};return i.ctx={_:i},i.root=t?t.root:i,i.emit=BL.bind(null,i),e.ce&&e.ce(i),i}let An=null;const Eb=()=>An||xn;let Ch,uv;{const e=kp(),t=(n,r)=>{let s;return(s=e[n])||(s=e[n]=[]),s.push(r),i=>{s.length>1?s.forEach(o=>o(i)):s[0](i)}};Ch=t("__VUE_INSTANCE_SETTERS__",n=>An=n),uv=t("__VUE_SSR_SETTERS__",n=>Uc=n)}const Ed=e=>{const t=An;return Ch(e),e.scope.on(),()=>{e.scope.off(),Ch(t)}},GS=()=>{An&&An.scope.off(),Ch(null)};function WC(e){return e.vnode.shapeFlag&4}let Uc=!1;function XL(e,t=!1,n=!1){t&&uv(t);const{props:r,children:s}=e.vnode,i=WC(e);EL(e,r,i,t),RL(e,s,n);const o=i?QL(e,t):void 0;return t&&uv(!1),o}function QL(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,vL);const{setup:r}=n;if(r){Ho();const s=e.setupContext=r.length>1?ZL(e):null,i=Ed(e),o=kd(r,e,0,[e.props,s]),a=FE(o);if(zo(),i(),(a||e.sp)&&!Bl(e)&&_C(e),a){if(o.then(GS,GS),t)return o.then(l=>{KS(e,l,t)}).catch(l=>{Tp(l,e,0)});e.asyncDep=o}else KS(e,o,t)}else GC(e,t)}function KS(e,t,n){Qe(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:Yt(t)&&(e.setupState=oC(t)),GC(e,n)}let YS;function GC(e,t,n){const r=e.type;if(!e.render){if(!t&&YS&&!r.render){const s=r.template||wb(e).template;if(s){const{isCustomElement:i,compilerOptions:o}=e.appContext.config,{delimiters:a,compilerOptions:l}=r,u=gn(gn({isCustomElement:i,delimiters:a},o),l);r.render=YS(s,u)}}e.render=r.render||ai}{const s=Ed(e);Ho();try{yL(e)}finally{zo(),s()}}}const JL={get(e,t){return Qn(e,"get",""),e[t]}};function ZL(e){const t=n=>{e.exposed=n||{}};return{attrs:new Proxy(e.attrs,JL),slots:e.slots,emit:e.emit,expose:t}}function Lp(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(oC(Pp(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in wc)return wc[n](e)},has(t,n){return n in t||n in wc}})):e.proxy}function e$(e,t=!0){return Qe(e)?e.displayName||e.name:e.name||t&&e.__name}function t$(e){return Qe(e)&&"__vccOpts"in e}const R=(e,t)=>ZD(e,t,Uc);function Mr(e,t,n){const r=arguments.length;return r===2?Yt(t)&&!je(t)?su(t)?h(e,null,[t]):h(e,t):h(e,null,t):(r>3?n=Array.prototype.slice.call(arguments,2):r===3&&su(n)&&(n=[n]),h(e,t,n))}const KC="3.5.13";/**
14
+ * @vue/runtime-dom v3.5.13
15
+ * (c) 2018-present Yuxi (Evan) You and Vue contributors
16
+ * @license MIT
17
+ **/let cv;const XS=typeof window<"u"&&window.trustedTypes;if(XS)try{cv=XS.createPolicy("vue",{createHTML:e=>e})}catch{}const YC=cv?e=>cv.createHTML(e):e=>e,n$="http://www.w3.org/2000/svg",r$="http://www.w3.org/1998/Math/MathML",Ci=typeof document<"u"?document:null,QS=Ci&&Ci.createElement("template"),s$={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,r)=>{const s=t==="svg"?Ci.createElementNS(n$,e):t==="mathml"?Ci.createElementNS(r$,e):n?Ci.createElement(e,{is:n}):Ci.createElement(e);return e==="select"&&r&&r.multiple!=null&&s.setAttribute("multiple",r.multiple),s},createText:e=>Ci.createTextNode(e),createComment:e=>Ci.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Ci.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,n,r,s,i){const o=n?n.previousSibling:t.lastChild;if(s&&(s===i||s.nextSibling))for(;t.insertBefore(s.cloneNode(!0),n),!(s===i||!(s=s.nextSibling)););else{QS.innerHTML=YC(r==="svg"?`<svg>${e}</svg>`:r==="mathml"?`<math>${e}</math>`:e);const a=QS.content;if(r==="svg"||r==="mathml"){const l=a.firstChild;for(;l.firstChild;)a.appendChild(l.firstChild);a.removeChild(l)}t.insertBefore(a,n)}return[o?o.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},Qi="transition",Ku="animation",iu=Symbol("_vtc"),XC={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},QC=gn({},yC,XC),i$=e=>(e.displayName="Transition",e.props=QC,e),$o=i$((e,{slots:t})=>Mr(lL,JC(e),t)),sa=(e,t=[])=>{je(e)?e.forEach(n=>n(...t)):e&&e(...t)},JS=e=>e?je(e)?e.some(t=>t.length>1):e.length>1:!1;function JC(e){const t={};for(const O in e)O in XC||(t[O]=e[O]);if(e.css===!1)return t;const{name:n="v",type:r,duration:s,enterFromClass:i=`${n}-enter-from`,enterActiveClass:o=`${n}-enter-active`,enterToClass:a=`${n}-enter-to`,appearFromClass:l=i,appearActiveClass:u=o,appearToClass:d=a,leaveFromClass:c=`${n}-leave-from`,leaveActiveClass:f=`${n}-leave-active`,leaveToClass:p=`${n}-leave-to`}=e,g=o$(s),m=g&&g[0],y=g&&g[1],{onBeforeEnter:b,onEnter:w,onEnterCancelled:S,onLeave:P,onLeaveCancelled:E,onBeforeAppear:T=b,onAppear:C=w,onAppearCancelled:k=S}=t,x=(O,A,D,V)=>{O._enterCancelled=V,to(O,A?d:a),to(O,A?u:o),D&&D()},I=(O,A)=>{O._isLeaving=!1,to(O,c),to(O,p),to(O,f),A&&A()},M=O=>(A,D)=>{const V=O?C:w,H=()=>x(A,O,D);sa(V,[A,H]),ZS(()=>{to(A,O?l:i),qs(A,O?d:a),JS(V)||e_(A,r,m,H)})};return gn(t,{onBeforeEnter(O){sa(b,[O]),qs(O,i),qs(O,o)},onBeforeAppear(O){sa(T,[O]),qs(O,l),qs(O,u)},onEnter:M(!1),onAppear:M(!0),onLeave(O,A){O._isLeaving=!0;const D=()=>I(O,A);qs(O,c),O._enterCancelled?(qs(O,f),dv()):(dv(),qs(O,f)),ZS(()=>{O._isLeaving&&(to(O,c),qs(O,p),JS(P)||e_(O,r,y,D))}),sa(P,[O,D])},onEnterCancelled(O){x(O,!1,void 0,!0),sa(S,[O])},onAppearCancelled(O){x(O,!0,void 0,!0),sa(k,[O])},onLeaveCancelled(O){I(O),sa(E,[O])}})}function o$(e){if(e==null)return null;if(Yt(e))return[Wm(e.enter),Wm(e.leave)];{const t=Wm(e);return[t,t]}}function Wm(e){return _D(e)}function qs(e,t){t.split(/\s+/).forEach(n=>n&&e.classList.add(n)),(e[iu]||(e[iu]=new Set)).add(t)}function to(e,t){t.split(/\s+/).forEach(r=>r&&e.classList.remove(r));const n=e[iu];n&&(n.delete(t),n.size||(e[iu]=void 0))}function ZS(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}let a$=0;function e_(e,t,n,r){const s=e._endId=++a$,i=()=>{s===e._endId&&r()};if(n!=null)return setTimeout(i,n);const{type:o,timeout:a,propCount:l}=ZC(e,t);if(!o)return r();const u=o+"end";let d=0;const c=()=>{e.removeEventListener(u,f),i()},f=p=>{p.target===e&&++d>=l&&c()};setTimeout(()=>{d<l&&c()},a+1),e.addEventListener(u,f)}function ZC(e,t){const n=window.getComputedStyle(e),r=g=>(n[g]||"").split(", "),s=r(`${Qi}Delay`),i=r(`${Qi}Duration`),o=t_(s,i),a=r(`${Ku}Delay`),l=r(`${Ku}Duration`),u=t_(a,l);let d=null,c=0,f=0;t===Qi?o>0&&(d=Qi,c=o,f=i.length):t===Ku?u>0&&(d=Ku,c=u,f=l.length):(c=Math.max(o,u),d=c>0?o>u?Qi:Ku:null,f=d?d===Qi?i.length:l.length:0);const p=d===Qi&&/\b(transform|all)(,|$)/.test(r(`${Qi}Property`).toString());return{type:d,timeout:c,propCount:f,hasTransform:p}}function t_(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max(...t.map((n,r)=>n_(n)+n_(e[r])))}function n_(e){return e==="auto"?0:Number(e.slice(0,-1).replace(",","."))*1e3}function dv(){return document.body.offsetHeight}function l$(e,t,n){const r=e[iu];r&&(t=(t?[t,...r]:[...r]).join(" ")),t==null?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}const Ph=Symbol("_vod"),eP=Symbol("_vsh"),qo={beforeMount(e,{value:t},{transition:n}){e[Ph]=e.style.display==="none"?"":e.style.display,n&&t?n.beforeEnter(e):Yu(e,t)},mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)},updated(e,{value:t,oldValue:n},{transition:r}){!t!=!n&&(r?t?(r.beforeEnter(e),Yu(e,!0),r.enter(e)):r.leave(e,()=>{Yu(e,!1)}):Yu(e,t))},beforeUnmount(e,{value:t}){Yu(e,t)}};function Yu(e,t){e.style.display=t?e[Ph]:"none",e[eP]=!t}const u$=Symbol(""),c$=/(^|;)\s*display\s*:/;function d$(e,t,n){const r=e.style,s=rn(n);let i=!1;if(n&&!s){if(t)if(rn(t))for(const o of t.split(";")){const a=o.slice(0,o.indexOf(":")).trim();n[a]==null&&Kf(r,a,"")}else for(const o in t)n[o]==null&&Kf(r,o,"");for(const o in n)o==="display"&&(i=!0),Kf(r,o,n[o])}else if(s){if(t!==n){const o=r[u$];o&&(n+=";"+o),r.cssText=n,i=c$.test(n)}}else t&&e.removeAttribute("style");Ph in e&&(e[Ph]=i?r.display:"",e[eP]&&(r.display="none"))}const r_=/\s*!important$/;function Kf(e,t,n){if(je(n))n.forEach(r=>Kf(e,t,r));else if(n==null&&(n=""),t.startsWith("--"))e.setProperty(t,n);else{const r=f$(e,t);r_.test(n)?e.setProperty(Uo(r),n.replace(r_,""),"important"):e[r]=n}}const s_=["Webkit","Moz","ms"],Gm={};function f$(e,t){const n=Gm[t];if(n)return n;let r=Or(t);if(r!=="filter"&&r in e)return Gm[t]=r;r=hi(r);for(let s=0;s<s_.length;s++){const i=s_[s]+r;if(i in e)return Gm[t]=i}return t}const i_="http://www.w3.org/1999/xlink";function o_(e,t,n,r,s,i=TD(t)){r&&t.startsWith("xlink:")?n==null?e.removeAttributeNS(i_,t.slice(6,t.length)):e.setAttributeNS(i_,t,n):n==null||i&&!UE(n)?e.removeAttribute(t):e.setAttribute(t,i?"":ji(n)?String(n):n)}function a_(e,t,n,r,s){if(t==="innerHTML"||t==="textContent"){n!=null&&(e[t]=t==="innerHTML"?YC(n):n);return}const i=e.tagName;if(t==="value"&&i!=="PROGRESS"&&!i.includes("-")){const a=i==="OPTION"?e.getAttribute("value")||"":e.value,l=n==null?e.type==="checkbox"?"on":"":String(n);(a!==l||!("_value"in e))&&(e.value=l),n==null&&e.removeAttribute(t),e._value=n;return}let o=!1;if(n===""||n==null){const a=typeof e[t];a==="boolean"?n=UE(n):n==null&&a==="string"?(n="",o=!0):a==="number"&&(n=0,o=!0)}try{e[t]=n}catch{}o&&e.removeAttribute(s||t)}function _l(e,t,n,r){e.addEventListener(t,n,r)}function h$(e,t,n,r){e.removeEventListener(t,n,r)}const l_=Symbol("_vei");function p$(e,t,n,r,s=null){const i=e[l_]||(e[l_]={}),o=i[t];if(r&&o)o.value=r;else{const[a,l]=m$(t);if(r){const u=i[t]=y$(r,s);_l(e,a,u,l)}else o&&(h$(e,a,o,l),i[t]=void 0)}}const u_=/(?:Once|Passive|Capture)$/;function m$(e){let t;if(u_.test(e)){t={};let r;for(;r=e.match(u_);)e=e.slice(0,e.length-r[0].length),t[r[0].toLowerCase()]=!0}return[e[2]===":"?e.slice(3):Uo(e.slice(2)),t]}let Km=0;const g$=Promise.resolve(),v$=()=>Km||(g$.then(()=>Km=0),Km=Date.now());function y$(e,t){const n=r=>{if(!r._vts)r._vts=Date.now();else if(r._vts<=n.attached)return;Rs(b$(r,n.value),t,5,[r])};return n.value=e,n.attached=v$(),n}function b$(e,t){if(je(t)){const n=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0},t.map(r=>s=>!s._stopped&&r&&r(s))}else return t}const c_=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,w$=(e,t,n,r,s,i)=>{const o=s==="svg";t==="class"?l$(e,r,o):t==="style"?d$(e,n,r):wp(t)?ib(t)||p$(e,t,n,r,i):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):S$(e,t,r,o))?(a_(e,t,r),!e.tagName.includes("-")&&(t==="value"||t==="checked"||t==="selected")&&o_(e,t,r,o,i,t!=="value")):e._isVueCE&&(/[A-Z]/.test(t)||!rn(r))?a_(e,Or(t),r,i,t):(t==="true-value"?e._trueValue=r:t==="false-value"&&(e._falseValue=r),o_(e,t,r,o))};function S$(e,t,n,r){if(r)return!!(t==="innerHTML"||t==="textContent"||t in e&&c_(t)&&Qe(n));if(t==="spellcheck"||t==="draggable"||t==="translate"||t==="form"||t==="list"&&e.tagName==="INPUT"||t==="type"&&e.tagName==="TEXTAREA")return!1;if(t==="width"||t==="height"){const s=e.tagName;if(s==="IMG"||s==="VIDEO"||s==="CANVAS"||s==="SOURCE")return!1}return c_(t)&&rn(n)?!1:t in e}const tP=new WeakMap,nP=new WeakMap,Th=Symbol("_moveCb"),d_=Symbol("_enterCb"),_$=e=>(delete e.props.mode,e),k$=_$({name:"TransitionGroup",props:gn({},QC,{tag:String,moveClass:String}),setup(e,{slots:t}){const n=Eb(),r=vC();let s,i;return vb(()=>{if(!s.length)return;const o=e.moveClass||`${e.name||"v"}-move`;if(!P$(s[0].el,n.vnode.el,o))return;s.forEach(x$),s.forEach(E$);const a=s.filter(C$);dv(),a.forEach(l=>{const u=l.el,d=u.style;qs(u,o),d.transform=d.webkitTransform=d.transitionDuration="";const c=u[Th]=f=>{f&&f.target!==u||(!f||/transform$/.test(f.propertyName))&&(u.removeEventListener("transitionend",c),u[Th]=null,to(u,o))};u.addEventListener("transitionend",c)})}),()=>{const o=Be(e),a=JC(o);let l=o.tag||Re;if(s=[],i)for(let u=0;u<i.length;u++){const d=i[u];d.el&&d.el instanceof Element&&(s.push(d),Ba(d,Bc(d,a,r,n)),tP.set(d,d.el.getBoundingClientRect()))}i=t.default?mb(t.default()):[];for(let u=0;u<i.length;u++){const d=i[u];d.key!=null&&Ba(d,Bc(d,a,r,n))}return h(l,null,i)}}}),Cb=k$;function x$(e){const t=e.el;t[Th]&&t[Th](),t[d_]&&t[d_]()}function E$(e){nP.set(e,e.el.getBoundingClientRect())}function C$(e){const t=tP.get(e),n=nP.get(e),r=t.left-n.left,s=t.top-n.top;if(r||s){const i=e.el.style;return i.transform=i.webkitTransform=`translate(${r}px,${s}px)`,i.transitionDuration="0s",e}}function P$(e,t,n){const r=e.cloneNode(),s=e[iu];s&&s.forEach(a=>{a.split(/\s+/).forEach(l=>l&&r.classList.remove(l))}),n.split(/\s+/).forEach(a=>a&&r.classList.add(a)),r.style.display="none";const i=t.nodeType===1?t:t.parentNode;i.appendChild(r);const{hasTransform:o}=ZC(r);return i.removeChild(r),o}const f_=e=>{const t=e.props["onUpdate:modelValue"]||!1;return je(t)?n=>qf(t,n):t};function T$(e){e.target.composing=!0}function h_(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const Ym=Symbol("_assign"),R$={created(e,{modifiers:{lazy:t,trim:n,number:r}},s){e[Ym]=f_(s);const i=r||s.props&&s.props.type==="number";_l(e,t?"change":"input",o=>{if(o.target.composing)return;let a=e.value;n&&(a=a.trim()),i&&(a=Jg(a)),e[Ym](a)}),n&&_l(e,"change",()=>{e.value=e.value.trim()}),t||(_l(e,"compositionstart",T$),_l(e,"compositionend",h_),_l(e,"change",h_))},mounted(e,{value:t}){e.value=t??""},beforeUpdate(e,{value:t,oldValue:n,modifiers:{lazy:r,trim:s,number:i}},o){if(e[Ym]=f_(o),e.composing)return;const a=(i||e.type==="number")&&!/^0\d/.test(e.value)?Jg(e.value):e.value,l=t??"";a!==l&&(document.activeElement===e&&e.type!=="range"&&(r&&t===n||s&&e.value.trim()===l)||(e.value=l))}},I$=["ctrl","shift","alt","meta"],A$={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>"button"in e&&e.button!==0,middle:e=>"button"in e&&e.button!==1,right:e=>"button"in e&&e.button!==2,exact:(e,t)=>I$.some(n=>e[`${n}Key`]&&!t.includes(n))},$t=(e,t)=>{const n=e._withMods||(e._withMods={}),r=t.join(".");return n[r]||(n[r]=(s,...i)=>{for(let o=0;o<t.length;o++){const a=A$[t[o]];if(a&&a(s,t))return}return e(s,...i)})},O$={esc:"escape",space:" ",up:"arrow-up",left:"arrow-left",right:"arrow-right",down:"arrow-down",delete:"backspace"},fv=(e,t)=>{const n=e._withKeys||(e._withKeys={}),r=t.join(".");return n[r]||(n[r]=s=>{if(!("key"in s))return;const i=Uo(s.key);if(t.some(o=>o===i||O$[o]===i))return e(s)})},M$=gn({patchProp:w$},s$);let p_;function D$(){return p_||(p_=AL(M$))}const L$=(...e)=>{const t=D$().createApp(...e),{mount:n}=t;return t.mount=r=>{const s=F$(r);if(!s)return;const i=t._component;!Qe(i)&&!i.render&&!i.template&&(i.template=s.innerHTML),s.nodeType===1&&(s.textContent="");const o=n(s,!1,$$(s));return s instanceof Element&&(s.removeAttribute("v-cloak"),s.setAttribute("data-v-app","")),o},t};function $$(e){if(e instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&e instanceof MathMLElement)return"mathml"}function F$(e){return rn(e)?document.querySelector(e):e}var N$=!1;/*!
18
+ * pinia v2.2.6
19
+ * (c) 2024 Eduardo San Martin Morote
20
+ * @license MIT
21
+ */let rP;const $p=e=>rP=e,sP=Symbol();function hv(e){return e&&typeof e=="object"&&Object.prototype.toString.call(e)==="[object Object]"&&typeof e.toJSON!="function"}var _c;(function(e){e.direct="direct",e.patchObject="patch object",e.patchFunction="patch function"})(_c||(_c={}));function B$(){const e=wd(!0),t=e.run(()=>U({}));let n=[],r=[];const s=Pp({install(i){$p(s),s._a=i,i.provide(sP,s),i.config.globalProperties.$pinia=s,r.forEach(o=>n.push(o)),r=[]},use(i){return!this._a&&!N$?r.push(i):n.push(i),this},_p:n,_a:null,_e:e,_s:new Map,state:t});return s}const iP=()=>{};function m_(e,t,n,r=iP){e.push(t);const s=()=>{const i=e.indexOf(t);i>-1&&(e.splice(i,1),r())};return!n&&xp()&&Sn(s),s}function cl(e,...t){e.slice().forEach(n=>{n(...t)})}const V$=e=>e(),g_=Symbol(),Xm=Symbol();function pv(e,t){e instanceof Map&&t instanceof Map?t.forEach((n,r)=>e.set(r,n)):e instanceof Set&&t instanceof Set&&t.forEach(e.add,e);for(const n in t){if(!t.hasOwnProperty(n))continue;const r=t[n],s=e[n];hv(s)&&hv(r)&&e.hasOwnProperty(n)&&!tt(r)&&!Ro(r)?e[n]=pv(s,r):e[n]=r}return e}const U$=Symbol();function H$(e){return!hv(e)||!e.hasOwnProperty(U$)}const{assign:no}=Object;function z$(e){return!!(tt(e)&&e.effect)}function j$(e,t,n,r){const{state:s,actions:i,getters:o}=t,a=n.state.value[e];let l;function u(){a||(n.state.value[e]=s?s():{});const d=jo(n.state.value[e]);return no(d,i,Object.keys(o||{}).reduce((c,f)=>(c[f]=Pp(R(()=>{$p(n);const p=n._s.get(e);return o[f].call(p,p)})),c),{}))}return l=oP(e,u,t,n,r,!0),l}function oP(e,t,n={},r,s,i){let o;const a=no({actions:{}},n),l={deep:!0};let u,d,c=[],f=[],p;const g=r.state.value[e];!i&&!g&&(r.state.value[e]={}),U({});let m;function y(k){let x;u=d=!1,typeof k=="function"?(k(r.state.value[e]),x={type:_c.patchFunction,storeId:e,events:p}):(pv(r.state.value[e],k),x={type:_c.patchObject,payload:k,storeId:e,events:p});const I=m=Symbol();Ot().then(()=>{m===I&&(u=!0)}),d=!0,cl(c,x,r.state.value[e])}const b=i?function(){const{state:x}=n,I=x?x():{};this.$patch(M=>{no(M,I)})}:iP;function w(){o.stop(),c=[],f=[],r._s.delete(e)}const S=(k,x="")=>{if(g_ in k)return k[Xm]=x,k;const I=function(){$p(r);const M=Array.from(arguments),O=[],A=[];function D(G){O.push(G)}function V(G){A.push(G)}cl(f,{args:M,name:I[Xm],store:E,after:D,onError:V});let H;try{H=k.apply(this&&this.$id===e?this:E,M)}catch(G){throw cl(A,G),G}return H instanceof Promise?H.then(G=>(cl(O,G),G)).catch(G=>(cl(A,G),Promise.reject(G))):(cl(O,H),H)};return I[g_]=!0,I[Xm]=x,I},P={_p:r,$id:e,$onAction:m_.bind(null,f),$patch:y,$reset:b,$subscribe(k,x={}){const I=m_(c,k,x.detached,()=>M()),M=o.run(()=>Ce(()=>r.state.value[e],O=>{(x.flush==="sync"?d:u)&&k({storeId:e,type:_c.direct,events:p},O)},no({},l,x)));return I},$dispose:w},E=vn(P);r._s.set(e,E);const C=(r._a&&r._a.runWithContext||V$)(()=>r._e.run(()=>(o=wd()).run(()=>t({action:S}))));for(const k in C){const x=C[k];if(tt(x)&&!z$(x)||Ro(x))i||(g&&H$(x)&&(tt(x)?x.value=g[k]:pv(x,g[k])),r.state.value[e][k]=x);else if(typeof x=="function"){const I=S(x,k);C[k]=I,a.actions[k]=x}}return no(E,C),no(Be(E),C),Object.defineProperty(E,"$state",{get:()=>r.state.value[e],set:k=>{y(x=>{no(x,k)})}}),r._p.forEach(k=>{no(E,o.run(()=>k({store:E,app:r._a,pinia:r,options:a})))}),g&&i&&n.hydrate&&n.hydrate(E.$state,g),u=!0,d=!0,E}/*! #__NO_SIDE_EFFECTS__ */function Ms(e,t,n){let r,s;const i=typeof t=="function";typeof e=="string"?(r=e,s=i?n:t):(s=e,r=e.id);function o(a,l){const u=IC();return a=a||(u?Ye(sP,null):null),a&&$p(a),a=rP,a._s.has(r)||(i?oP(r,t,s,a):j$(r,s,a)),a._s.get(r)}return o.$id=r,o}const ku=Ms("Dialog",{state:()=>({ids:[],dialogsById:{}}),getters:{dialogs(){return this.ids.map(e=>this.dialogsById[e])},getBeforeOpenedCallback(){return e=>{var t;return(t=this.dialogsById[e])==null?void 0:t.beforeOpenedCallback}},getOpenedCallback(){return e=>{var t;return(t=this.dialogsById[e])==null?void 0:t.openedCallback}},getContext(){return e=>{var t;return(t=this.dialogsById[e])==null?void 0:t.context}},getOutput(){return e=>{var t;return(t=this.dialogsById[e])==null?void 0:t.output}},isDialogOpened(){return e=>{var t;return(t=this.dialogsById[e])==null?void 0:t.opened}}},actions:{openDialogWithContext(e,t){let n=this.dialogsById[e];n||(n=this.registerDialogReference(e)),n.opened=!0,n.context=t,this.dialogsById={...this.dialogsById},console.debug(`[Pinia Dialog ${e}] Opened with context`,t)},closeDialog(e,t){let n=this.dialogsById[e];n||(n=this.registerDialogReference(e)),n.opened=!1,delete n.context,n.output=t,this.dialogsById={...this.dialogsById},console.debug(`[Pinia Dialog ${e}] Closed`)},unregisterDialogReference(e){delete this.dialogsById[e],this.ids=this.ids.filter(t=>t!==e)},registerDialogReference(e,t){if(!e)throw new Error("Cannot unregister undefined dialog reference");console.debug(`[Pinia Dialog ${e}] Registered`);const n=this.dialogsById[e];if(n)return console.debug(`[Pinia Dialog ${e}] Already registered dialog, not registering again`),n;const r={id:e,opened:!1,beforeOpenedCallback:t==null?void 0:t.beforeOpenedCallback,openedCallback:t==null?void 0:t.openedCallback};return this.dialogsById[e]=r,this.ids.push(e),r}}});function mv(e){return xp()?(Sn(e),!0):!1}function ou(e){return typeof e=="function"?e():ie(e)}const gv=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const q$=Object.prototype.toString,W$=e=>q$.call(e)==="[object Object]",G$=()=>{};function K$(e,t=1e3,n={}){const{immediate:r=!0,immediateCallback:s=!1}=n;let i=null;const o=U(!1);function a(){i&&(clearInterval(i),i=null)}function l(){o.value=!1,a()}function u(){const d=ou(t);d<=0||(o.value=!0,s&&e(),a(),o.value&&(i=setInterval(e,d)))}if(r&&gv&&u(),tt(t)||typeof t=="function"){const d=Ce(t,()=>{o.value&&gv&&u()});mv(d)}return mv(l),{isActive:o,pause:l,resume:u}}const aP=gv?window:void 0;function Y$(e){var t;const n=ou(e);return(t=n==null?void 0:n.$el)!=null?t:n}function X$(...e){let t,n,r,s;if(typeof e[0]=="string"||Array.isArray(e[0])?([n,r,s]=e,t=aP):[t,n,r,s]=e,!t)return G$;Array.isArray(n)||(n=[n]),Array.isArray(r)||(r=[r]);const i=[],o=()=>{i.forEach(d=>d()),i.length=0},a=(d,c,f,p)=>(d.addEventListener(c,f,p),()=>d.removeEventListener(c,f,p)),l=Ce(()=>[Y$(t),ou(s)],([d,c])=>{if(o(),!d)return;const f=W$(c)?{...c}:c;i.push(...n.flatMap(p=>r.map(g=>a(d,p,g,f))))},{immediate:!0,flush:"post"}),u=()=>{l(),o()};return mv(u),u}function Q$(e){return typeof e=="function"?e:typeof e=="string"?t=>t.key===e:Array.isArray(e)?t=>e.includes(t.key):()=>!0}function J$(...e){let t,n,r={};e.length===3?(t=e[0],n=e[1],r=e[2]):e.length===2?typeof e[1]=="object"?(t=!0,n=e[0],r=e[1]):(t=e[0],n=e[1]):(t=!0,n=e[0]);const{target:s=aP,eventName:i="keydown",passive:o=!1,dedupe:a=!1}=r,l=Q$(t);return X$(s,i,d=>{d.repeat&&ou(a)||l(d)&&n(d)},o)}const Xu=new Map;function qr(e){const t=xp();function n(a){var l;const u=Xu.get(e)||new Set;u.add(a),Xu.set(e,u);const d=()=>s(a);return(l=t==null?void 0:t.cleanups)==null||l.push(d),d}function r(a){function l(...u){s(l),a(...u)}return n(l)}function s(a){const l=Xu.get(e);l&&(l.delete(a),l.size||i())}function i(){Xu.delete(e)}function o(a,l){var u;(u=Xu.get(e))==null||u.forEach(d=>d(a,l))}return{on:n,once:r,off:s,emit:o,reset:i}}function Fn(e){const t=ku();async function n(r){const s=t.getBeforeOpenedCallback(e);s&&await s(r),t.openDialogWithContext(e,r);const i=t.getOpenedCallback(e);i&&await i(r)}return{dialogId:e,dialogStore:t,openDialog:n,context:()=>t.getContext(e),closeDialog:r=>t.closeDialog(e,r),isDialogOpened:()=>t.isDialogOpened(e),handleAsync:async r=>(await n(r),new Promise(s=>{jn(()=>{t.isDialogOpened(e)||s(t.getOutput(e))})}))}}const kt=typeof window<"u",Pb=kt&&"IntersectionObserver"in window,Z$=kt&&("ontouchstart"in window||window.navigator.maxTouchPoints>0);function v_(e,t,n){eF(e,t),t.set(e,n)}function eF(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function tF(e,t,n){return e.set(lP(e,t),n),n}function ia(e,t){return e.get(lP(e,t))}function lP(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 uP(e,t,n){const r=t.length-1;if(r<0)return e===void 0?n:e;for(let s=0;s<r;s++){if(e==null)return n;e=e[t[s]]}return e==null||e[t[r]]===void 0?n:e[t[r]]}function Wo(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(r=>Wo(e[r],t[r]))}function Va(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(/^\./,""),uP(e,t.split("."),n))}function er(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 s=t(e,n);return typeof s>"u"?n:s}if(typeof t=="string")return Va(e,t,n);if(Array.isArray(t))return uP(e,t,n);if(typeof t!="function")return n;const r=t(e,n);return typeof r>"u"?n:r}function Cl(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return Array.from({length:e},(n,r)=>t+r)}function Ne(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"px";if(!(e==null||e===""))return isNaN(+e)?String(e):isFinite(+e)?`${Number(e)}${t}`:void 0}function nF(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)}function y_(e){let t;return e!==null&&typeof e=="object"&&((t=Object.getPrototypeOf(e))===Object.prototype||t===null)}function Tb(e){if(e&&"$el"in e){const t=e.$el;return(t==null?void 0:t.nodeType)===Node.TEXT_NODE?t.nextElementSibling:t}return e}const b_=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}),w_=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 cP(e){return Object.keys(e)}function Qm(e,t){return t.every(n=>e.hasOwnProperty(n))}function dP(e,t){const n={},r=new Set(Object.keys(e));for(const s of t)r.has(s)&&(n[s]=e[s]);return n}function vv(e,t,n){const r=Object.create(null),s=Object.create(null);for(const i in e)t.some(o=>o instanceof RegExp?o.test(i):o===i)&&!(n!=null&&n.some(o=>o===i))?r[i]=e[i]:s[i]=e[i];return[r,s]}function Ds(e,t){const n={...e};return t.forEach(r=>delete n[r]),n}function fP(e,t){const n={};return t.forEach(r=>n[r]=e[r]),n}const hP=/^on[^a-z]/,Fp=e=>hP.test(e),rF=["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 Za(e){const[t,n]=vv(e,[hP]),r=Ds(t,rF),[s,i]=vv(n,["class","style","id",/^data-/]);return Object.assign(s,t),Object.assign(i,r),[s,i]}function Dn(e){return e==null?[]:Array.isArray(e)?e:[e]}function sF(e,t){let n=0;const r=function(){for(var s=arguments.length,i=new Array(s),o=0;o<s;o++)i[o]=arguments[o];clearTimeout(n),n=setTimeout(()=>e(...i),ie(t))};return r.clear=()=>{clearTimeout(n)},r.immediate=e,r}function Rr(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 S_(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 __(e,t){return(arguments.length>2&&arguments[2]!==void 0?arguments[2]:"0").repeat(Math.max(0,t-e.length))+e}function iF(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;const n=[];let r=0;for(;r<e.length;)n.push(e.substr(r,t)),r+=t;return n}function k_(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1e3;if(e<t)return`${e} B`;const n=t===1024?["Ki","Mi","Gi"]:["k","M","G"];let r=-1;for(;Math.abs(e)>=t&&r<n.length-1;)e/=t,++r;return`${e.toFixed(1)} ${n[r]}B`}function tr(){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 r={};for(const s in e)r[s]=e[s];for(const s in t){const i=e[s],o=t[s];if(y_(i)&&y_(o)){r[s]=tr(i,o,n);continue}if(n&&Array.isArray(i)&&Array.isArray(o)){r[s]=n(i,o);continue}r[s]=o}return r}function pP(e){return e.map(t=>t.type===Re?pP(t.children):t).flat()}function Ra(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";if(Ra.cache.has(e))return Ra.cache.get(e);const t=e.replace(/[^a-z]/gi,"-").replace(/\B([A-Z])/g,"-$1").toLowerCase();return Ra.cache.set(e,t),t}Ra.cache=new Map;function Pl(e,t){if(!t||typeof t!="object")return[];if(Array.isArray(t))return t.map(n=>Pl(e,n)).flat(1);if(t.suspense)return Pl(e,t.ssContent);if(Array.isArray(t.children))return t.children.map(n=>Pl(e,n)).flat(1);if(t.component){if(Object.getOwnPropertySymbols(t.component.provides).includes(e))return[t.component];if(t.component.subTree)return Pl(e,t.component.subTree).flat(1)}return[]}var nf=new WeakMap,dl=new WeakMap;class oF{constructor(t){v_(this,nf,[]),v_(this,dl,0),this.size=t}push(t){ia(nf,this)[ia(dl,this)]=t,tF(dl,this,(ia(dl,this)+1)%this.size)}values(){return ia(nf,this).slice(ia(dl,this)).concat(ia(nf,this).slice(0,ia(dl,this)))}}function Rb(e){const t=vn({}),n=R(e);return jn(()=>{for(const r in n.value)t[r]=n.value[r]},{flush:"sync"}),jo(t)}function Rh(e,t){return e.includes(t)}function mP(e){return e[2].toLowerCase()+e.slice(3)}const zn=()=>[Function,Array];function x_(e,t){return t="on"+hi(t),!!(e[t]||e[`${t}Once`]||e[`${t}Capture`]||e[`${t}OnceCapture`]||e[`${t}CaptureOnce`])}function Ib(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];if(Array.isArray(e))for(const s of e)s(...n);else typeof e=="function"&&e(...n)}function Hc(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(r=>`${r}${t?':not([tabindex="-1"])':""}:not([disabled])`).join(", ");return[...e.querySelectorAll(n)]}function gP(e,t,n){let r,s=e.indexOf(document.activeElement);const i=t==="next"?1:-1;do s+=i,r=e[s];while((!r||r.offsetParent==null||!((n==null?void 0:n(r))??!0))&&s<e.length&&s>=0);return r}function kc(e,t){var r,s,i,o;const n=Hc(e);if(!t)(e===document.activeElement||!e.contains(document.activeElement))&&((r=n[0])==null||r.focus());else if(t==="first")(s=n[0])==null||s.focus();else if(t==="last")(i=n.at(-1))==null||i.focus();else if(typeof t=="number")(o=n[t])==null||o.focus();else{const a=gP(n,t);a?a.focus():kc(e,t==="next"?"first":"last")}}function rf(e){return e==null||typeof e=="string"&&e.trim()===""}function Ih(e,t){if(!(kt&&typeof CSS<"u"&&typeof CSS.supports<"u"&&CSS.supports(`selector(${t})`)))return null;try{return!!e&&e.matches(t)}catch{return null}}function vP(e){return e.some(t=>su(t)?t.type===Zn?!1:t.type!==Re||vP(t.children):!0)?e:null}function aF(e,t){if(!kt||e===0)return t(),()=>{};const n=window.setTimeout(t,e);return()=>window.clearTimeout(n)}function lF(e,t){const n=e.clientX,r=e.clientY,s=t.getBoundingClientRect(),i=s.left,o=s.top,a=s.right,l=s.bottom;return n>=i&&n<=a&&r>=o&&r<=l}function yv(){const e=Me(),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:()=>Tb(e.value)}),t}function E_(e){const t=e.key.length===1,n=!e.ctrlKey&&!e.metaKey&&!e.altKey;return t&&n}const yP=["top","bottom"],uF=["start","end","left","right"];function bv(e,t){let[n,r]=e.split(" ");return r||(r=Rh(yP,n)?"start":Rh(uF,n)?"top":"center"),{side:wv(n,t),align:wv(r,t)}}function wv(e,t){return e==="start"?t?"right":"left":e==="end"?t?"left":"right":e}function Jm(e){return{side:{center:"center",top:"bottom",bottom:"top",left:"right",right:"left"}[e.side],align:e.align}}function Zm(e){return{side:e.side,align:{center:"center",top:"bottom",bottom:"top",left:"right",right:"left"}[e.align]}}function C_(e){return{side:e.align,align:e.side}}function P_(e){return Rh(yP,e.side)?"y":"x"}class Ia{constructor(t){let{x:n,y:r,width:s,height:i}=t;this.x=n,this.y=r,this.width=s,this.height=i}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 T_(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 bP(e){return Array.isArray(e)?new Ia({x:e[0],y:e[1],width:0,height:0}):e.getBoundingClientRect()}function Ab(e){const t=e.getBoundingClientRect(),n=getComputedStyle(e),r=n.transform;if(r){let s,i,o,a,l;if(r.startsWith("matrix3d("))s=r.slice(9,-1).split(/, /),i=+s[0],o=+s[5],a=+s[12],l=+s[13];else if(r.startsWith("matrix("))s=r.slice(7,-1).split(/, /),i=+s[0],o=+s[3],a=+s[4],l=+s[5];else return new Ia(t);const u=n.transformOrigin,d=t.x-a-(1-i)*parseFloat(u),c=t.y-l-(1-o)*parseFloat(u.slice(u.indexOf(" ")+1)),f=i?t.width/i:e.offsetWidth+1,p=o?t.height/o:e.offsetHeight+1;return new Ia({x:d,y:c,width:f,height:p})}else return new Ia(t)}function Tl(e,t,n){if(typeof e.animate>"u")return{finished:Promise.resolve()};let r;try{r=e.animate(t,n)}catch{return{finished:Promise.resolve()}}return typeof r.finished>"u"&&(r.finished=new Promise(s=>{r.onfinish=()=>{s(r)}})),r}const Yf=new WeakMap;function cF(e,t){Object.keys(t).forEach(n=>{if(Fp(n)){const r=mP(n),s=Yf.get(e);if(t[n]==null)s==null||s.forEach(i=>{const[o,a]=i;o===r&&(e.removeEventListener(r,a),s.delete(i))});else if(!s||![...s].some(i=>i[0]===r&&i[1]===t[n])){e.addEventListener(r,t[n]);const i=s||new Set;i.add([r,t[n]]),Yf.has(e)||Yf.set(e,i)}}else t[n]==null?e.removeAttribute(n):e.setAttribute(n,t[n])})}function dF(e,t){Object.keys(t).forEach(n=>{if(Fp(n)){const r=mP(n),s=Yf.get(e);s==null||s.forEach(i=>{const[o,a]=i;o===r&&(e.removeEventListener(r,a),s.delete(i))})}else e.removeAttribute(n)})}const fl=2.4,R_=.2126729,I_=.7151522,A_=.072175,fF=.55,hF=.58,pF=.57,mF=.62,sf=.03,O_=1.45,gF=5e-4,vF=1.25,yF=1.25,M_=.078,D_=12.82051282051282,of=.06,L_=.001;function $_(e,t){const n=(e.r/255)**fl,r=(e.g/255)**fl,s=(e.b/255)**fl,i=(t.r/255)**fl,o=(t.g/255)**fl,a=(t.b/255)**fl;let l=n*R_+r*I_+s*A_,u=i*R_+o*I_+a*A_;if(l<=sf&&(l+=(sf-l)**O_),u<=sf&&(u+=(sf-u)**O_),Math.abs(u-l)<gF)return 0;let d;if(u>l){const c=(u**fF-l**hF)*vF;d=c<L_?0:c<M_?c-c*D_*of:c-of}else{const c=(u**mF-l**pF)*yF;d=c>-L_?0:c>-M_?c-c*D_*of:c+of}return d*100}function bF(e,t){t=Array.isArray(t)?t.slice(0,-1).map(n=>`'${n}'`).join(", ")+` or '${t.at(-1)}'`:`'${t}'`}const Ah=.20689655172413793,wF=e=>e>Ah**3?Math.cbrt(e):e/(3*Ah**2)+4/29,SF=e=>e>Ah?e**3:3*Ah**2*(e-4/29);function wP(e){const t=wF,n=t(e[1]);return[116*n-16,500*(t(e[0]/.95047)-n),200*(n-t(e[2]/1.08883))]}function SP(e){const t=SF,n=(e[0]+16)/116;return[t(n+e[1]/500)*.95047,t(n),t(n-e[2]/200)*1.08883]}const _F=[[3.2406,-1.5372,-.4986],[-.9689,1.8758,.0415],[.0557,-.204,1.057]],kF=e=>e<=.0031308?e*12.92:1.055*e**(1/2.4)-.055,xF=[[.4124,.3576,.1805],[.2126,.7152,.0722],[.0193,.1192,.9505]],EF=e=>e<=.04045?e/12.92:((e+.055)/1.055)**2.4;function _P(e){const t=Array(3),n=kF,r=_F;for(let s=0;s<3;++s)t[s]=Math.round(Rr(n(r[s][0]*e[0]+r[s][1]*e[1]+r[s][2]*e[2]))*255);return{r:t[0],g:t[1],b:t[2]}}function Ob(e){let{r:t,g:n,b:r}=e;const s=[0,0,0],i=EF,o=xF;t=i(t/255),n=i(n/255),r=i(r/255);for(let a=0;a<3;++a)s[a]=o[a][0]*t+o[a][1]*n+o[a][2]*r;return s}function Sv(e){return!!e&&/^(#|var\(--|(rgb|hsl)a?\()/.test(e)}function CF(e){return Sv(e)&&!/^((rgb|hsl)a?\()?var\(--/.test(e)}const F_=/^(?<fn>(?:rgb|hsl)a?)\((?<values>.+)\)/,PF={rgb:(e,t,n,r)=>({r:e,g:t,b:n,a:r}),rgba:(e,t,n,r)=>({r:e,g:t,b:n,a:r}),hsl:(e,t,n,r)=>N_({h:e,s:t,l:n,a:r}),hsla:(e,t,n,r)=>N_({h:e,s:t,l:n,a:r}),hsv:(e,t,n,r)=>zc({h:e,s:t,v:n,a:r}),hsva:(e,t,n,r)=>zc({h:e,s:t,v:n,a:r})};function si(e){if(typeof e=="number")return{r:(e&16711680)>>16,g:(e&65280)>>8,b:e&255};if(typeof e=="string"&&F_.test(e)){const{groups:t}=e.match(F_),{fn:n,values:r}=t,s=r.split(/,\s*/).map(i=>i.endsWith("%")&&["hsl","hsla","hsv","hsva"].includes(n)?parseFloat(i)/100:parseFloat(i));return PF[n](...s)}else if(typeof e=="string"){let t=e.startsWith("#")?e.slice(1):e;return[3,4].includes(t.length)?t=t.split("").map(n=>n+n).join(""):[6,8].includes(t.length),RF(t)}else if(typeof e=="object"){if(Qm(e,["r","g","b"]))return e;if(Qm(e,["h","s","l"]))return zc(kP(e));if(Qm(e,["h","s","v"]))return zc(e)}throw new TypeError(`Invalid color: ${e==null?e:String(e)||e.constructor.name}
22
+ Expected #hex, #hexa, rgb(), rgba(), hsl(), hsla(), object or number`)}function zc(e){const{h:t,s:n,v:r,a:s}=e,i=a=>{const l=(a+t/60)%6;return r-r*n*Math.max(Math.min(l,4-l,1),0)},o=[i(5),i(3),i(1)].map(a=>Math.round(a*255));return{r:o[0],g:o[1],b:o[2],a:s}}function N_(e){return zc(kP(e))}function kP(e){const{h:t,s:n,l:r,a:s}=e,i=r+n*Math.min(r,1-r),o=i===0?0:2-2*r/i;return{h:t,s:o,v:i,a:s}}function af(e){const t=Math.round(e).toString(16);return("00".substr(0,2-t.length)+t).toUpperCase()}function TF(e){let{r:t,g:n,b:r,a:s}=e;return`#${[af(t),af(n),af(r),s!==void 0?af(Math.round(s*255)):""].join("")}`}function RF(e){e=IF(e);let[t,n,r,s]=iF(e,2).map(i=>parseInt(i,16));return s=s===void 0?s:s/255,{r:t,g:n,b:r,a:s}}function IF(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=S_(S_(e,6),8,"F")),e}function AF(e,t){const n=wP(Ob(e));return n[0]=n[0]+t*10,_P(SP(n))}function OF(e,t){const n=wP(Ob(e));return n[0]=n[0]-t*10,_P(SP(n))}function MF(e){const t=si(e);return Ob(t)[1]}function xP(e){const t=Math.abs($_(si(0),si(e)));return Math.abs($_(si(16777215),si(e)))>Math.min(t,50)?"#fff":"#000"}function de(e,t){return n=>Object.keys(e).reduce((r,s)=>{const o=typeof e[s]=="object"&&e[s]!=null&&!Array.isArray(e[s])?e[s]:{type:e[s]};return n&&s in n?r[s]={...o,default:n[s]}:r[s]=o,t&&!r[s].source&&(r[s].source=t),r},{})}const Ve=de({class:[String,Array,Object],style:{type:[String,Array,Object],default:null}},"component");function sn(e,t){const n=Eb();if(!n)throw new Error(`[Vuetify] ${e} must be called from inside a setup function`);return n}function pi(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"composables";const t=sn(e).type;return Ra((t==null?void 0:t.aliasName)||(t==null?void 0:t.name))}let EP=0,Xf=new WeakMap;function vr(){const e=sn("getUid");if(Xf.has(e))return Xf.get(e);{const t=EP++;return Xf.set(e,t),t}}vr.reset=()=>{EP=0,Xf=new WeakMap};function DF(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:sn("injectSelf");const{provides:n}=t;if(n&&e in n)return n[e]}const au=Symbol.for("vuetify:defaults");function LF(e){return U(e)}function Mb(){const e=Ye(au);if(!e)throw new Error("[Vuetify] Could not find defaults instance");return e}function Dr(e,t){const n=Mb(),r=U(e),s=R(()=>{if(ie(t==null?void 0:t.disabled))return n.value;const o=ie(t==null?void 0:t.scoped),a=ie(t==null?void 0:t.reset),l=ie(t==null?void 0:t.root);if(r.value==null&&!(o||a||l))return n.value;let u=tr(r.value,{prev:n.value});if(o)return u;if(a||l){const d=Number(a||1/0);for(let c=0;c<=d&&!(!u||!("prev"in u));c++)u=u.prev;return u&&typeof l=="string"&&l in u&&(u=tr(tr(u,{prev:u}),u[l])),u}return u.prev?tr(u.prev,u):u});return Gt(au,s),s}function $F(e,t){var n,r;return typeof((n=e.props)==null?void 0:n[t])<"u"||typeof((r=e.props)==null?void 0:r[Ra(t)])<"u"}function FF(){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]:Mb();const r=sn("useDefaults");if(t=t??r.type.name??r.type.__name,!t)throw new Error("[Vuetify] Could not determine component name");const s=R(()=>{var l;return(l=n.value)==null?void 0:l[e._as??t]}),i=new Proxy(e,{get(l,u){var c,f,p,g,m,y,b;const d=Reflect.get(l,u);return u==="class"||u==="style"?[(c=s.value)==null?void 0:c[u],d].filter(w=>w!=null):typeof u=="string"&&!$F(r.vnode,u)?((f=s.value)==null?void 0:f[u])!==void 0?(p=s.value)==null?void 0:p[u]:((m=(g=n.value)==null?void 0:g.global)==null?void 0:m[u])!==void 0?(b=(y=n.value)==null?void 0:y.global)==null?void 0:b[u]:d:d}}),o=Me();jn(()=>{if(s.value){const l=Object.entries(s.value).filter(u=>{let[d]=u;return d.startsWith(d[0].toUpperCase())});o.value=l.length?Object.fromEntries(l):void 0}else o.value=void 0});function a(){const l=DF(au,r);Gt(au,R(()=>o.value?tr((l==null?void 0:l.value)??{},o.value):l==null?void 0:l.value))}return{props:i,provideSubDefaults:a}}function xu(e){if(e._setup=e._setup??e.setup,!e.name)return e;if(e._setup){e.props=de(e.props??{},e.name)();const t=Object.keys(e.props).filter(n=>n!=="class"&&n!=="style");e.filterProps=function(r){return dP(r,t)},e.props._as=String,e.setup=function(r,s){const i=Mb();if(!i.value)return e._setup(r,s);const{props:o,provideSubDefaults:a}=FF(r,r._as??e.name,i),l=e._setup(o,s);return a(),l}}return e}function xe(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;return t=>(e?xu:Le)(t)}function NF(e,t){return t.props=e,t}function Eu(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"div",n=arguments.length>2?arguments[2]:void 0;return xe()({name:n??hi(Or(e.replace(/__/g,"-"))),props:{tag:{type:String,default:t},...Ve()},setup(r,s){let{slots:i}=s;return()=>{var o;return Mr(r.tag,{class:[e,r.class],style:r.style},(o=i.default)==null?void 0:o.call(i))}}})}function CP(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 Oh="cubic-bezier(0.4, 0, 0.2, 1)",BF="cubic-bezier(0.0, 0, 0.2, 1)",VF="cubic-bezier(0.4, 0, 1, 1)";function B_(e,t,n){return Object.keys(e).filter(r=>Fp(r)&&r.endsWith(t)).reduce((r,s)=>(r[s.slice(0,-t.length)]=i=>e[s](i,n(i)),r),{})}function PP(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;for(;e;){if(t?UF(e):Db(e))return e;e=e.parentElement}return document.scrollingElement}function Mh(e,t){const n=[];if(t&&e&&!t.contains(e))return n;for(;e&&(Db(e)&&n.push(e),e!==t);)e=e.parentElement;return n}function Db(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 UF(e){if(!e||e.nodeType!==Node.ELEMENT_NODE)return!1;const t=window.getComputedStyle(e);return["scroll","auto"].includes(t.overflowY)}function HF(e){for(;e;){if(window.getComputedStyle(e).position==="fixed")return!0;e=e.offsetParent}return!1}function Ie(e){const t=sn("useRender");t.render=e}const vs=de({border:[Boolean,Number,String]},"border");function Ls(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:pi();return{borderClasses:R(()=>{const r=tt(e)?e.value:e.border,s=[];if(r===!0||r==="")s.push(`${t}--border`);else if(typeof r=="string"||r===0)for(const i of String(r).split(" "))s.push(`border-${i}`);return s})}}const zF=[null,"default","comfortable","compact"],Lr=de({density:{type:String,default:"default",validator:e=>zF.includes(e)}},"density");function ys(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:pi();return{densityClasses:R(()=>`${t}--density-${e.density}`)}}const bs=de({elevation:{type:[Number,String],validator(e){const t=parseInt(e);return!isNaN(t)&&t>=0&&t<=24}}},"elevation");function $s(e){return{elevationClasses:R(()=>{const n=tt(e)?e.value:e.elevation,r=[];return n==null||r.push(`elevation-${n}`),r})}}const Bn=de({rounded:{type:[Boolean,Number,String],default:void 0},tile:Boolean},"rounded");function qn(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:pi();return{roundedClasses:R(()=>{const r=tt(e)?e.value:e.rounded,s=tt(e)?e.value:e.tile,i=[];if(r===!0||r==="")i.push(`${t}--rounded`);else if(typeof r=="string"||r===0)for(const o of String(r).split(" "))i.push(`rounded-${o}`);else(s||r===!1)&&i.push("rounded-0");return i})}}const bt=de({tag:{type:String,default:"div"}},"tag"),jc=Symbol.for("vuetify:theme"),Dt=de({theme:String},"theme");function V_(){return{defaultTheme:"light",variations:{colors:[],lighten:0,darken:0},themes:{light:{dark:!1,colors:{background:"#FFFFFF",surface:"#FFFFFF","surface-bright":"#FFFFFF","surface-light":"#EEEEEE","surface-variant":"#424242","on-surface-variant":"#EEEEEE",primary:"#1867C0","primary-darken-1":"#1F5592",secondary:"#48A9A6","secondary-darken-1":"#018786",error:"#B00020",info:"#2196F3",success:"#4CAF50",warning:"#FB8C00"},variables:{"border-color":"#000000","border-opacity":.12,"high-emphasis-opacity":.87,"medium-emphasis-opacity":.6,"disabled-opacity":.38,"idle-opacity":.04,"hover-opacity":.04,"focus-opacity":.12,"selected-opacity":.08,"activated-opacity":.12,"pressed-opacity":.12,"dragged-opacity":.08,"theme-kbd":"#212529","theme-on-kbd":"#FFFFFF","theme-code":"#F5F5F5","theme-on-code":"#000000"}},dark:{dark:!0,colors:{background:"#121212",surface:"#212121","surface-bright":"#ccbfd6","surface-light":"#424242","surface-variant":"#a3a3a3","on-surface-variant":"#424242",primary:"#2196F3","primary-darken-1":"#277CC1",secondary:"#54B6B2","secondary-darken-1":"#48A9A6",error:"#CF6679",info:"#2196F3",success:"#4CAF50",warning:"#FB8C00"},variables:{"border-color":"#FFFFFF","border-opacity":.12,"high-emphasis-opacity":1,"medium-emphasis-opacity":.7,"disabled-opacity":.5,"idle-opacity":.1,"hover-opacity":.04,"focus-opacity":.12,"selected-opacity":.08,"activated-opacity":.12,"pressed-opacity":.16,"dragged-opacity":.08,"theme-kbd":"#212529","theme-on-kbd":"#FFFFFF","theme-code":"#343434","theme-on-code":"#CCCCCC"}}}}}function jF(){var r,s;let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:V_();const t=V_();if(!e)return{...t,isDisabled:!0};const n={};for(const[i,o]of Object.entries(e.themes??{})){const a=o.dark||i==="dark"?(r=t.themes)==null?void 0:r.dark:(s=t.themes)==null?void 0:s.light;n[i]=tr(a,o)}return tr(t,{...e,themes:n})}function qF(e){const t=jF(e),n=U(t.defaultTheme),r=U(t.themes),s=R(()=>{const d={};for(const[c,f]of Object.entries(r.value)){const p=d[c]={...f,colors:{...f.colors}};if(t.variations)for(const g of t.variations.colors){const m=p.colors[g];if(m)for(const y of["lighten","darken"]){const b=y==="lighten"?AF:OF;for(const w of Cl(t.variations[y],1))p.colors[`${g}-${y}-${w}`]=TF(b(si(m),w))}}for(const g of Object.keys(p.colors)){if(/^on-[a-z]/.test(g)||p.colors[`on-${g}`])continue;const m=`on-${g}`,y=si(p.colors[g]);p.colors[m]=xP(y)}}return d}),i=R(()=>s.value[n.value]),o=R(()=>{var g;const d=[];(g=i.value)!=null&&g.dark&&oa(d,":root",["color-scheme: dark"]),oa(d,":root",U_(i.value));for(const[m,y]of Object.entries(s.value))oa(d,`.v-theme--${m}`,[`color-scheme: ${y.dark?"dark":"normal"}`,...U_(y)]);const c=[],f=[],p=new Set(Object.values(s.value).flatMap(m=>Object.keys(m.colors)));for(const m of p)/^on-[a-z]/.test(m)?oa(f,`.${m}`,[`color: rgb(var(--v-theme-${m})) !important`]):(oa(c,`.bg-${m}`,[`--v-theme-overlay-multiplier: var(--v-theme-${m}-overlay-multiplier)`,`background-color: rgb(var(--v-theme-${m})) !important`,`color: rgb(var(--v-theme-on-${m})) !important`]),oa(f,`.text-${m}`,[`color: rgb(var(--v-theme-${m})) !important`]),oa(f,`.border-${m}`,[`--v-border-color: var(--v-theme-${m})`]));return d.push(...c,...f),d.map((m,y)=>y===0?m:` ${m}`).join("")});function a(){return{style:[{children:o.value,id:"vuetify-theme-stylesheet",nonce:t.cspNonce||!1}]}}function l(d){if(t.isDisabled)return;const c=d._context.provides.usehead;if(c)if(c.push){const p=c.push(a);kt&&Ce(o,()=>{p.patch(a)})}else kt?(c.addHeadObjs(R(a)),jn(()=>c.updateDOM())):c.addHeadObjs(a());else{let g=function(){if(typeof document<"u"&&!p){const m=document.createElement("style");m.type="text/css",m.id="vuetify-theme-stylesheet",t.cspNonce&&m.setAttribute("nonce",t.cspNonce),p=m,document.head.appendChild(p)}p&&(p.innerHTML=o.value)};var f=g;let p=kt?document.getElementById("vuetify-theme-stylesheet"):null;kt?Ce(o,g,{immediate:!0}):g()}}const u=R(()=>t.isDisabled?void 0:`v-theme--${n.value}`);return{install:l,isDisabled:t.isDisabled,name:n,themes:r,current:i,computedThemes:s,themeClasses:u,styles:o,global:{name:n,current:i}}}function Xt(e){sn("provideTheme");const t=Ye(jc,null);if(!t)throw new Error("Could not find Vuetify theme injection");const n=R(()=>e.theme??t.name.value),r=R(()=>t.themes.value[n.value]),s=R(()=>t.isDisabled?void 0:`v-theme--${n.value}`),i={...t,name:n,current:r,themeClasses:s};return Gt(jc,i),i}function WF(){sn("useTheme");const e=Ye(jc,null);if(!e)throw new Error("Could not find Vuetify theme injection");return e}function oa(e,t,n){e.push(`${t} {
23
+ `,...n.map(r=>` ${r};
24
+ `),`}
25
+ `)}function U_(e){const t=e.dark?2:1,n=e.dark?1:2,r=[];for(const[s,i]of Object.entries(e.colors)){const o=si(i);r.push(`--v-theme-${s}: ${o.r},${o.g},${o.b}`),s.startsWith("on-")||r.push(`--v-theme-${s}-overlay-multiplier: ${MF(i)>.18?t:n}`)}for(const[s,i]of Object.entries(e.variables)){const o=typeof i=="string"&&i.startsWith("#")?si(i):void 0,a=o?`${o.r}, ${o.g}, ${o.b}`:void 0;r.push(`--v-${s}: ${a??i}`)}return r}function Lb(e){return Rb(()=>{const t=[],n={};if(e.value.background)if(Sv(e.value.background)){if(n.backgroundColor=e.value.background,!e.value.text&&CF(e.value.background)){const r=si(e.value.background);if(r.a==null||r.a===1){const s=xP(r);n.color=s,n.caretColor=s}}}else t.push(`bg-${e.value.background}`);return e.value.text&&(Sv(e.value.text)?(n.color=e.value.text,n.caretColor=e.value.text):t.push(`text-${e.value.text}`)),{colorClasses:t,colorStyles:n}})}function Is(e,t){const n=R(()=>({text:tt(e)?e.value:t?e[t]:null})),{colorClasses:r,colorStyles:s}=Lb(n);return{textColorClasses:r,textColorStyles:s}}function pr(e,t){const n=R(()=>({background:tt(e)?e.value:t?e[t]:null})),{colorClasses:r,colorStyles:s}=Lb(n);return{backgroundColorClasses:r,backgroundColorStyles:s}}const GF=["elevated","flat","tonal","outlined","text","plain"];function Go(e,t){return h(Re,null,[e&&h("span",{key:"overlay",class:`${t}__overlay`},null),h("span",{key:"underlay",class:`${t}__underlay`},null)])}const Fs=de({color:String,variant:{type:String,default:"elevated",validator:e=>GF.includes(e)}},"variant");function el(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:pi();const n=R(()=>{const{variant:i}=ie(e);return`${t}--variant-${i}`}),{colorClasses:r,colorStyles:s}=Lb(R(()=>{const{variant:i,color:o}=ie(e);return{[["elevated","flat"].includes(i)?"background":"text"]:o}}));return{colorClasses:r,colorStyles:s,variantClasses:n}}const TP=de({baseColor:String,divided:Boolean,...vs(),...Ve(),...Lr(),...bs(),...Bn(),...bt(),...Dt(),...Fs()},"VBtnGroup"),H_=xe()({name:"VBtnGroup",props:TP(),setup(e,t){let{slots:n}=t;const{themeClasses:r}=Xt(e),{densityClasses:s}=ys(e),{borderClasses:i}=Ls(e),{elevationClasses:o}=$s(e),{roundedClasses:a}=qn(e);Dr({VBtn:{height:"auto",baseColor:Te(e,"baseColor"),color:Te(e,"color"),density:Te(e,"density"),flat:!0,variant:Te(e,"variant")}}),Ie(()=>h(e.tag,{class:["v-btn-group",{"v-btn-group--divided":e.divided},r.value,i.value,s.value,o.value,a.value,e.class],style:e.style},n))}});function Qr(e,t){let n;function r(){n=wd(),n.run(()=>t.length?t(()=>{n==null||n.stop(),r()}):t())}Ce(e,s=>{s&&!n?r():s||(n==null||n.stop(),n=void 0)},{immediate:!0}),Sn(()=>{n==null||n.stop()})}function st(e,t,n){let r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:c=>c,s=arguments.length>4&&arguments[4]!==void 0?arguments[4]:c=>c;const i=sn("useProxiedModel"),o=U(e[t]!==void 0?e[t]:n),a=Ra(t),u=R(a!==t?()=>{var c,f,p,g;return e[t],!!(((c=i.vnode.props)!=null&&c.hasOwnProperty(t)||(f=i.vnode.props)!=null&&f.hasOwnProperty(a))&&((p=i.vnode.props)!=null&&p.hasOwnProperty(`onUpdate:${t}`)||(g=i.vnode.props)!=null&&g.hasOwnProperty(`onUpdate:${a}`)))}:()=>{var c,f;return e[t],!!((c=i.vnode.props)!=null&&c.hasOwnProperty(t)&&((f=i.vnode.props)!=null&&f.hasOwnProperty(`onUpdate:${t}`)))});Qr(()=>!u.value,()=>{Ce(()=>e[t],c=>{o.value=c})});const d=R({get(){const c=e[t];return r(u.value?c:o.value)},set(c){const f=s(c),p=Be(u.value?e[t]:o.value);p===f||r(p)===c||(o.value=f,i==null||i.emit(`update:${t}`,f))}});return Object.defineProperty(d,"externalValue",{get:()=>u.value?e[t]:o.value}),d}const Cd=de({modelValue:{type:null,default:void 0},multiple:Boolean,mandatory:[Boolean,String],max:Number,selectedClass:String,disabled:Boolean},"group"),Pd=de({value:null,disabled:Boolean,selectedClass:String},"group-item");function Td(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;const r=sn("useGroupItem");if(!r)throw new Error("[Vuetify] useGroupItem composable must be used inside a component setup function");const s=vr();Gt(Symbol.for(`${t.description}:id`),s);const i=Ye(t,null);if(!i){if(!n)return i;throw new Error(`[Vuetify] Could not find useGroup injection with symbol ${t.description}`)}const o=Te(e,"value"),a=R(()=>!!(i.disabled.value||e.disabled));i.register({id:s,value:o,disabled:a},r),Tn(()=>{i.unregister(s)});const l=R(()=>i.isSelected(s)),u=R(()=>i.items.value[0].id===s),d=R(()=>i.items.value[i.items.value.length-1].id===s),c=R(()=>l.value&&[i.selectedClass.value,e.selectedClass]);return Ce(l,f=>{r.emit("group:selected",{value:f})},{flush:"sync"}),{id:s,isSelected:l,isFirst:u,isLast:d,toggle:()=>i.select(s,!l.value),select:f=>i.select(s,f),selectedClass:c,value:o,disabled:a,group:i}}function Cu(e,t){let n=!1;const r=vn([]),s=st(e,"modelValue",[],f=>f==null?[]:RP(r,Dn(f)),f=>{const p=YF(r,f);return e.multiple?p:p[0]}),i=sn("useGroup");function o(f,p){const g=f,m=Symbol.for(`${t.description}:id`),b=Pl(m,i==null?void 0:i.vnode).indexOf(p);ie(g.value)==null&&(g.value=b,g.useIndexAsValue=!0),b>-1?r.splice(b,0,g):r.push(g)}function a(f){if(n)return;l();const p=r.findIndex(g=>g.id===f);r.splice(p,1)}function l(){const f=r.find(p=>!p.disabled);f&&e.mandatory==="force"&&!s.value.length&&(s.value=[f.id])}St(()=>{l()}),Tn(()=>{n=!0}),vb(()=>{for(let f=0;f<r.length;f++)r[f].useIndexAsValue&&(r[f].value=f)});function u(f,p){const g=r.find(m=>m.id===f);if(!(p&&(g!=null&&g.disabled)))if(e.multiple){const m=s.value.slice(),y=m.findIndex(w=>w===f),b=~y;if(p=p??!b,b&&e.mandatory&&m.length<=1||!b&&e.max!=null&&m.length+1>e.max)return;y<0&&p?m.push(f):y>=0&&!p&&m.splice(y,1),s.value=m}else{const m=s.value.includes(f);if(e.mandatory&&m)return;s.value=p??!m?[f]:[]}}function d(f){if(e.multiple,s.value.length){const p=s.value[0],g=r.findIndex(b=>b.id===p);let m=(g+f)%r.length,y=r[m];for(;y.disabled&&m!==g;)m=(m+f)%r.length,y=r[m];if(y.disabled)return;s.value=[r[m].id]}else{const p=r.find(g=>!g.disabled);p&&(s.value=[p.id])}}const c={register:o,unregister:a,selected:s,select:u,disabled:Te(e,"disabled"),prev:()=>d(r.length-1),next:()=>d(1),isSelected:f=>s.value.includes(f),selectedClass:R(()=>e.selectedClass),items:R(()=>r),getItemIndex:f=>KF(r,f)};return Gt(t,c),c}function KF(e,t){const n=RP(e,[t]);return n.length?e.findIndex(r=>r.id===n[0]):-1}function RP(e,t){const n=[];return t.forEach(r=>{const s=e.find(o=>Wo(r,o.value)),i=e[r];(s==null?void 0:s.value)!=null?n.push(s.id):i!=null&&n.push(i.id)}),n}function YF(e,t){const n=[];return t.forEach(r=>{const s=e.findIndex(i=>i.id===r);if(~s){const i=e[s];n.push(i.value!=null?i.value:s)}}),n}const IP=Symbol.for("vuetify:v-btn-toggle"),XF=de({...TP(),...Cd()},"VBtnToggle"),AP=xe()({name:"VBtnToggle",props:XF(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const{isSelected:r,next:s,prev:i,select:o,selected:a}=Cu(e,IP);return Ie(()=>{const l=H_.filterProps(e);return h(H_,me({class:["v-btn-toggle",e.class]},l,{style:e.style}),{default:()=>{var u;return[(u=n.default)==null?void 0:u.call(n,{isSelected:r,next:s,prev:i,select:o,selected:a})]}})}),{next:s,prev:i,select:o}}}),QF=de({defaults:Object,disabled:Boolean,reset:[Number,String],root:[Boolean,String],scoped:Boolean},"VDefaultsProvider"),At=xe(!1)({name:"VDefaultsProvider",props:QF(),setup(e,t){let{slots:n}=t;const{defaults:r,disabled:s,reset:i,root:o,scoped:a}=jo(e);return Dr(r,{reset:i,root:o,scoped:a,disabled:s}),()=>{var l;return(l=n.default)==null?void 0:l.call(n)}}}),JF={collapse:"mdi-chevron-up",complete:"mdi-check",cancel:"mdi-close-circle",close:"mdi-close",delete:"mdi-close-circle",clear:"mdi-close-circle",success:"mdi-check-circle",info:"mdi-information",warning:"mdi-alert-circle",error:"mdi-close-circle",prev:"mdi-chevron-left",next:"mdi-chevron-right",checkboxOn:"mdi-checkbox-marked",checkboxOff:"mdi-checkbox-blank-outline",checkboxIndeterminate:"mdi-minus-box",delimiter:"mdi-circle",sortAsc:"mdi-arrow-up",sortDesc:"mdi-arrow-down",expand:"mdi-chevron-down",menu:"mdi-menu",subgroup:"mdi-menu-down",dropdown:"mdi-menu-down",radioOn:"mdi-radiobox-marked",radioOff:"mdi-radiobox-blank",edit:"mdi-pencil",ratingEmpty:"mdi-star-outline",ratingFull:"mdi-star",ratingHalf:"mdi-star-half-full",loading:"mdi-cached",first:"mdi-page-first",last:"mdi-page-last",unfold:"mdi-unfold-more-horizontal",file:"mdi-paperclip",plus:"mdi-plus",minus:"mdi-minus",calendar:"mdi-calendar",treeviewCollapse:"mdi-menu-down",treeviewExpand:"mdi-menu-right",eyeDropper:"mdi-eyedropper"},ZF={component:e=>Mr(MP,{...e,class:"mdi"})},Je=[String,Function,Object,Array],_v=Symbol.for("vuetify:icons"),Np=de({icon:{type:Je},tag:{type:String,required:!0}},"icon"),z_=xe()({name:"VComponentIcon",props:Np(),setup(e,t){let{slots:n}=t;return()=>{const r=e.icon;return h(e.tag,null,{default:()=>{var s;return[e.icon?h(r,null,null):(s=n.default)==null?void 0:s.call(n)]}})}}}),OP=xu({name:"VSvgIcon",inheritAttrs:!1,props:Np(),setup(e,t){let{attrs:n}=t;return()=>h(e.tag,me(n,{style:null}),{default:()=>[h("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(r=>Array.isArray(r)?h("path",{d:r[0],"fill-opacity":r[1]},null):h("path",{d:r},null)):h("path",{d:e.icon},null)])]})}}),eN=xu({name:"VLigatureIcon",props:Np(),setup(e){return()=>h(e.tag,null,{default:()=>[e.icon]})}}),MP=xu({name:"VClassIcon",props:Np(),setup(e){return()=>h(e.tag,{class:e.icon},null)}});function tN(){return{svg:{component:OP},class:{component:MP}}}function nN(e){const t=tN(),n=(e==null?void 0:e.defaultSet)??"mdi";return n==="mdi"&&!t.mdi&&(t.mdi=ZF),tr({defaultSet:n,sets:t,aliases:{...JF,vuetify:["M8.2241 14.2009L12 21L22 3H14.4459L8.2241 14.2009Z",["M7.26303 12.4733L7.00113 12L2 3H12.5261C12.5261 3 12.5261 3 12.5261 3L7.26303 12.4733Z",.6]],"vuetify-outline":"svg:M7.26 12.47 12.53 3H2L7.26 12.47ZM14.45 3 8.22 14.2 12 21 22 3H14.45ZM18.6 5 12 16.88 10.51 14.2 15.62 5ZM7.26 8.35 5.4 5H9.13L7.26 8.35Z","vuetify-play":["m6.376 13.184-4.11-7.192C1.505 4.66 2.467 3 4.003 3h8.532l-.953 1.576-.006.01-.396.677c-.429.732-.214 1.507.194 2.015.404.503 1.092.878 1.869.806a3.72 3.72 0 0 1 1.005.022c.276.053.434.143.523.237.138.146.38.635-.25 2.09-.893 1.63-1.553 1.722-1.847 1.677-.213-.033-.468-.158-.756-.406a4.95 4.95 0 0 1-.8-.927c-.39-.564-1.04-.84-1.66-.846-.625-.006-1.316.27-1.693.921l-.478.826-.911 1.506Z",["M9.093 11.552c.046-.079.144-.15.32-.148a.53.53 0 0 1 .43.207c.285.414.636.847 1.046 1.2.405.35.914.662 1.516.754 1.334.205 2.502-.698 3.48-2.495l.014-.028.013-.03c.687-1.574.774-2.852-.005-3.675-.37-.391-.861-.586-1.333-.676a5.243 5.243 0 0 0-1.447-.044c-.173.016-.393-.073-.54-.257-.145-.18-.127-.316-.082-.392l.393-.672L14.287 3h5.71c1.536 0 2.499 1.659 1.737 2.992l-7.997 13.996c-.768 1.344-2.706 1.344-3.473 0l-3.037-5.314 1.377-2.278.004-.006.004-.007.481-.831Z",.6]]}},e)}const rN=e=>{const t=Ye(_v);if(!t)throw new Error("Missing Vuetify Icons provide!");return{iconData:R(()=>{var l;const r=ie(e);if(!r)return{component:z_};let s=r;if(typeof s=="string"&&(s=s.trim(),s.startsWith("$")&&(s=(l=t.aliases)==null?void 0:l[s.slice(1)])),Array.isArray(s))return{component:OP,icon:s};if(typeof s!="string")return{component:z_,icon:s};const i=Object.keys(t.sets).find(u=>typeof s=="string"&&s.startsWith(`${u}:`)),o=i?s.slice(i.length+1):s;return{component:t.sets[i??t.defaultSet].component,icon:o}})}},sN=["x-small","small","default","large","x-large"],Pu=de({size:{type:[String,Number],default:"default"}},"size");function Rd(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:pi();return Rb(()=>{let n,r;return Rh(sN,e.size)?n=`${t}--size-${e.size}`:e.size&&(r={width:Ne(e.size),height:Ne(e.size)}),{sizeClasses:n,sizeStyles:r}})}const iN=de({color:String,disabled:Boolean,start:Boolean,end:Boolean,icon:Je,...Ve(),...Pu(),...bt({tag:"i"}),...Dt()},"VIcon"),X=xe()({name:"VIcon",props:iN(),setup(e,t){let{attrs:n,slots:r}=t;const s=U(),{themeClasses:i}=Xt(e),{iconData:o}=rN(R(()=>s.value||e.icon)),{sizeClasses:a}=Rd(e),{textColorClasses:l,textColorStyles:u}=Is(Te(e,"color"));return Ie(()=>{var f,p;const d=(f=r.default)==null?void 0:f.call(r);d&&(s.value=(p=pP(d).filter(g=>g.type===xd&&g.children&&typeof g.children=="string")[0])==null?void 0:p.children);const c=!!(n.onClick||n.onClickOnce);return h(o.value.component,{tag:e.tag,icon:o.value.icon,class:["v-icon","notranslate",i.value,a.value,l.value,{"v-icon--clickable":c,"v-icon--disabled":e.disabled,"v-icon--start":e.start,"v-icon--end":e.end},e.class],style:[a.value?void 0:{fontSize:Ne(e.size),height:Ne(e.size),width:Ne(e.size)},u.value,e.style],role:c?"button":void 0,"aria-hidden":!c,tabindex:c?e.disabled?-1:0:void 0},{default:()=>[d]})}),{}}});function DP(e,t){const n=U(),r=Me(!1);if(Pb){const s=new IntersectionObserver(i=>{r.value=!!i.find(o=>o.isIntersecting)},t);Tn(()=>{s.disconnect()}),Ce(n,(i,o)=>{o&&(s.unobserve(o),r.value=!1),i&&s.observe(i)},{flush:"post"})}return{intersectionRef:n,isIntersecting:r}}function Ua(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"content";const n=yv(),r=U();if(kt){const s=new ResizeObserver(i=>{e==null||e(i,s),i.length&&(t==="content"?r.value=i[0].contentRect:r.value=i[0].target.getBoundingClientRect())});Tn(()=>{s.disconnect()}),Ce(()=>n.el,(i,o)=>{o&&(s.unobserve(o),r.value=void 0),i&&s.observe(i)},{flush:"post"})}return{resizeRef:n,contentRect:Sd(r)}}const oN=de({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},...Ve(),...Pu(),...bt({tag:"div"}),...Dt()},"VProgressCircular"),Id=xe()({name:"VProgressCircular",props:oN(),setup(e,t){let{slots:n}=t;const r=20,s=2*Math.PI*r,i=U(),{themeClasses:o}=Xt(e),{sizeClasses:a,sizeStyles:l}=Rd(e),{textColorClasses:u,textColorStyles:d}=Is(Te(e,"color")),{textColorClasses:c,textColorStyles:f}=Is(Te(e,"bgColor")),{intersectionRef:p,isIntersecting:g}=DP(),{resizeRef:m,contentRect:y}=Ua(),b=R(()=>Math.max(0,Math.min(100,parseFloat(e.modelValue)))),w=R(()=>Number(e.width)),S=R(()=>l.value?Number(e.size):y.value?y.value.width:Math.max(w.value,32)),P=R(()=>r/(1-w.value/S.value)*2),E=R(()=>w.value/S.value*P.value),T=R(()=>Ne((100-b.value)/100*s));return jn(()=>{p.value=i.value,m.value=i.value}),Ie(()=>h(e.tag,{ref:i,class:["v-progress-circular",{"v-progress-circular--indeterminate":!!e.indeterminate,"v-progress-circular--visible":g.value,"v-progress-circular--disable-shrink":e.indeterminate==="disable-shrink"},o.value,a.value,u.value,e.class],style:[l.value,d.value,e.style],role:"progressbar","aria-valuemin":"0","aria-valuemax":"100","aria-valuenow":e.indeterminate?void 0:b.value},{default:()=>[h("svg",{style:{transform:`rotate(calc(-90deg + ${Number(e.rotate)}deg))`},xmlns:"http://www.w3.org/2000/svg",viewBox:`0 0 ${P.value} ${P.value}`},[h("circle",{class:["v-progress-circular__underlay",c.value],style:f.value,fill:"transparent",cx:"50%",cy:"50%",r,"stroke-width":E.value,"stroke-dasharray":s,"stroke-dashoffset":0},null),h("circle",{class:"v-progress-circular__overlay",fill:"transparent",cx:"50%",cy:"50%",r,"stroke-width":E.value,"stroke-dasharray":s,"stroke-dashoffset":T.value},null)]),n.default&&h("div",{class:"v-progress-circular__content"},[n.default({value:b.value})])]})),{}}}),$r=de({height:[Number,String],maxHeight:[Number,String],maxWidth:[Number,String],minHeight:[Number,String],minWidth:[Number,String],width:[Number,String]},"dimension");function Fr(e){return{dimensionStyles:R(()=>{const n={},r=Ne(e.height),s=Ne(e.maxHeight),i=Ne(e.maxWidth),o=Ne(e.minHeight),a=Ne(e.minWidth),l=Ne(e.width);return r!=null&&(n.height=r),s!=null&&(n.maxHeight=s),i!=null&&(n.maxWidth=i),o!=null&&(n.minHeight=o),a!=null&&(n.minWidth=a),l!=null&&(n.width=l),n})}}const aN={badge:"Badge",open:"Open",close:"Close",dismiss:"Dismiss",confirmEdit:{ok:"OK",cancel:"Cancel"},dataIterator:{noResultsText:"No matching records found",loadingText:"Loading items..."},dataTable:{itemsPerPageText:"Rows per page:",ariaLabel:{sortDescending:"Sorted descending.",sortAscending:"Sorted ascending.",sortNone:"Not sorted.",activateNone:"Activate to remove sorting.",activateDescending:"Activate to sort descending.",activateAscending:"Activate to sort ascending."},sortBy:"Sort by"},dataFooter:{itemsPerPageText:"Items per page:",itemsPerPageAll:"All",nextPage:"Next page",prevPage:"Previous page",firstPage:"First page",lastPage:"Last page",pageText:"{0}-{1} of {2}"},dateRangeInput:{divider:"to"},datePicker:{itemsSelected:"{0} selected",range:{title:"Select dates",header:"Enter dates"},title:"Select date",header:"Enter date",input:{placeholder:"Enter date"}},noDataText:"No data available",carousel:{prev:"Previous visual",next:"Next visual",ariaLabel:{delimiter:"Carousel slide {0} of {1}"}},calendar:{moreEvents:"{0} more",today:"Today"},input:{clear:"Clear {0}",prependAction:"{0} prepended action",appendAction:"{0} appended action",otp:"Please enter OTP character {0}"},fileInput:{counter:"{0} files",counterSize:"{0} files ({1} in total)"},timePicker:{am:"AM",pm:"PM",title:"Select Time"},pagination:{ariaLabel:{root:"Pagination Navigation",next:"Next page",previous:"Previous page",page:"Go to page {0}",currentPage:"Page {0}, Current page",first:"First page",last:"Last page"}},stepper:{next:"Next",prev:"Previous"},rating:{ariaLabel:{item:"Rating {0} of {1}"}},loading:"Loading...",infiniteScroll:{loadMore:"Load more",empty:"No more"}},j_="$vuetify.",q_=(e,t)=>e.replace(/\{(\d+)\}/g,(n,r)=>String(t[+r])),LP=(e,t,n)=>function(r){for(var s=arguments.length,i=new Array(s>1?s-1:0),o=1;o<s;o++)i[o-1]=arguments[o];if(!r.startsWith(j_))return q_(r,i);const a=r.replace(j_,""),l=e.value&&n.value[e.value],u=t.value&&n.value[t.value];let d=Va(l,a,null);return d||(`${r}${e.value}`,d=Va(u,a,null)),d||(d=r),typeof d!="string"&&(d=r),q_(d,i)};function $P(e,t){return(n,r)=>new Intl.NumberFormat([e.value,t.value],r).format(n)}function eg(e,t,n){const r=st(e,t,e[t]??n.value);return r.value=e[t]??n.value,Ce(n,s=>{e[t]==null&&(r.value=n.value)}),r}function FP(e){return t=>{const n=eg(t,"locale",e.current),r=eg(t,"fallback",e.fallback),s=eg(t,"messages",e.messages);return{name:"vuetify",current:n,fallback:r,messages:s,t:LP(n,r,s),n:$P(n,r),provide:FP({current:n,fallback:r,messages:s})}}}function lN(e){const t=Me((e==null?void 0:e.locale)??"en"),n=Me((e==null?void 0:e.fallback)??"en"),r=U({en:aN,...e==null?void 0:e.messages});return{name:"vuetify",current:t,fallback:n,messages:r,t:LP(t,n,r),n:$P(t,n),provide:FP({current:t,fallback:n,messages:r})}}const Dh=Symbol.for("vuetify:locale");function uN(e){return e.name!=null}function cN(e){const t=e!=null&&e.adapter&&uN(e==null?void 0:e.adapter)?e==null?void 0:e.adapter:lN(e),n=fN(t,e);return{...t,...n}}function es(){const e=Ye(Dh);if(!e)throw new Error("[Vuetify] Could not find injected locale instance");return e}function dN(){return{af:!1,ar:!0,bg:!1,ca:!1,ckb:!1,cs:!1,de:!1,el:!1,en:!1,es:!1,et:!1,fa:!0,fi:!1,fr:!1,hr:!1,hu:!1,he:!0,id:!1,it:!1,ja:!1,km:!1,ko:!1,lv:!1,lt:!1,nl:!1,no:!1,pl:!1,pt:!1,ro:!1,ru:!1,sk:!1,sl:!1,srCyrl:!1,srLatn:!1,sv:!1,th:!1,tr:!1,az:!1,uk:!1,vi:!1,zhHans:!1,zhHant:!1}}function fN(e,t){const n=U((t==null?void 0:t.rtl)??dN()),r=R(()=>n.value[e.current.value]??!1);return{isRtl:r,rtl:n,rtlClasses:R(()=>`v-locale--is-${r.value?"rtl":"ltr"}`)}}function Nr(){const e=Ye(Dh);if(!e)throw new Error("[Vuetify] Could not find injected rtl instance");return{isRtl:e.isRtl,rtlClasses:e.rtlClasses}}const W_={center:"center",top:"bottom",bottom:"top",left:"right",right:"left"},Ko=de({location:String},"location");function tl(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,n=arguments.length>2?arguments[2]:void 0;const{isRtl:r}=Nr();return{locationStyles:R(()=>{if(!e.location)return{};const{side:i,align:o}=bv(e.location.split(" ").length>1?e.location:`${e.location} center`,r.value);function a(u){return n?n(u):0}const l={};return i!=="center"&&(t?l[W_[i]]=`calc(100% - ${a(i)}px)`:l[i]=0),o!=="center"?t?l[W_[o]]=`calc(100% - ${a(o)}px)`:l[o]=0:(i==="center"?l.top=l.left="50%":l[{top:"left",bottom:"left",left:"top",right:"top"}[i]]="50%",l.transform={top:"translateX(-50%)",bottom:"translateX(-50%)",left:"translateY(-50%)",right:"translateY(-50%)",center:"translate(-50%, -50%)"}[i]),l})}}const hN=de({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,...Ve(),...Ko({location:"top"}),...Bn(),...bt(),...Dt()},"VProgressLinear"),lu=xe()({name:"VProgressLinear",props:hN(),emits:{"update:modelValue":e=>!0},setup(e,t){var M;let{slots:n}=t;const r=st(e,"modelValue"),{isRtl:s,rtlClasses:i}=Nr(),{themeClasses:o}=Xt(e),{locationStyles:a}=tl(e),{textColorClasses:l,textColorStyles:u}=Is(e,"color"),{backgroundColorClasses:d,backgroundColorStyles:c}=pr(R(()=>e.bgColor||e.color)),{backgroundColorClasses:f,backgroundColorStyles:p}=pr(R(()=>e.bufferColor||e.bgColor||e.color)),{backgroundColorClasses:g,backgroundColorStyles:m}=pr(e,"color"),{roundedClasses:y}=qn(e),{intersectionRef:b,isIntersecting:w}=DP(),S=R(()=>parseFloat(e.max)),P=R(()=>parseFloat(e.height)),E=R(()=>Rr(parseFloat(e.bufferValue)/S.value*100,0,100)),T=R(()=>Rr(parseFloat(r.value)/S.value*100,0,100)),C=R(()=>s.value!==e.reverse),k=R(()=>e.indeterminate?"fade-transition":"slide-x-transition"),x=kt&&((M=window.matchMedia)==null?void 0:M.call(window,"(forced-colors: active)").matches);function I(O){if(!b.value)return;const{left:A,right:D,width:V}=b.value.getBoundingClientRect(),H=C.value?V-O.clientX+(D-V):O.clientX-A;r.value=Math.round(H/V*S.value)}return Ie(()=>h(e.tag,{ref:b,class:["v-progress-linear",{"v-progress-linear--absolute":e.absolute,"v-progress-linear--active":e.active&&w.value,"v-progress-linear--reverse":C.value,"v-progress-linear--rounded":e.rounded,"v-progress-linear--rounded-bar":e.roundedBar,"v-progress-linear--striped":e.striped},y.value,o.value,i.value,e.class],style:[{bottom:e.location==="bottom"?0:void 0,top:e.location==="top"?0:void 0,height:e.active?Ne(P.value):0,"--v-progress-linear-height":Ne(P.value),...e.absolute?a.value:{}},e.style],role:"progressbar","aria-hidden":e.active?"false":"true","aria-valuemin":"0","aria-valuemax":e.max,"aria-valuenow":e.indeterminate?void 0:T.value,onClick:e.clickable&&I},{default:()=>[e.stream&&h("div",{key:"stream",class:["v-progress-linear__stream",l.value],style:{...u.value,[C.value?"left":"right"]:Ne(-P.value),borderTop:`${Ne(P.value/2)} dotted`,opacity:parseFloat(e.bufferOpacity),top:`calc(50% - ${Ne(P.value/4)})`,width:Ne(100-E.value,"%"),"--v-progress-linear-stream-to":Ne(P.value*(C.value?1:-1))}},null),h("div",{class:["v-progress-linear__background",x?void 0:d.value],style:[c.value,{opacity:parseFloat(e.bgOpacity),width:e.stream?0:void 0}]},null),h("div",{class:["v-progress-linear__buffer",x?void 0:f.value],style:[p.value,{opacity:parseFloat(e.bufferOpacity),width:Ne(E.value,"%")}]},null),h($o,{name:k.value},{default:()=>[e.indeterminate?h("div",{class:"v-progress-linear__indeterminate"},[["long","short"].map(O=>h("div",{key:O,class:["v-progress-linear__indeterminate",O,x?void 0:g.value],style:m.value},null))]):h("div",{class:["v-progress-linear__determinate",x?void 0:g.value],style:[m.value,{width:Ne(T.value,"%")}]},null)]}),n.default&&h("div",{class:"v-progress-linear__content"},[n.default({value:T.value,buffer:E.value})])]})),{}}}),Bp=de({loading:[Boolean,String]},"loader");function Ad(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:pi();return{loaderClasses:R(()=>({[`${t}--loading`]:e.loading}))}}function Vp(e,t){var r;let{slots:n}=t;return h("div",{class:`${e.name}__loader`},[((r=n.default)==null?void 0:r.call(n,{color:e.color,isActive:e.active}))||h(lu,{absolute:e.absolute,active:e.active,color:e.color,height:"2",indeterminate:!0},null)])}const pN=["static","relative","fixed","absolute","sticky"],Tu=de({position:{type:String,validator:e=>pN.includes(e)}},"position");function Ru(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:pi();return{positionClasses:R(()=>e.position?`${t}--${e.position}`:void 0)}}function mN(){const e=sn("useRoute");return R(()=>{var t;return(t=e==null?void 0:e.proxy)==null?void 0:t.$route})}function NP(){var e,t;return(t=(e=sn("useRouter"))==null?void 0:e.proxy)==null?void 0:t.$router}function Up(e,t){var c,f;const n=gL("RouterLink"),r=R(()=>!!(e.href||e.to)),s=R(()=>(r==null?void 0:r.value)||x_(t,"click")||x_(e,"click"));if(typeof n=="string"||!("useLink"in n)){const p=Te(e,"href");return{isLink:r,isClickable:s,href:p,linkProps:vn({href:p})}}const i=R(()=>({...e,to:Te(()=>e.to||"")})),o=n.useLink(i.value),a=R(()=>e.to?o:void 0),l=mN(),u=R(()=>{var p,g,m;return a.value?e.exact?l.value?((m=a.value.isExactActive)==null?void 0:m.value)&&Wo(a.value.route.value.query,l.value.query):((g=a.value.isExactActive)==null?void 0:g.value)??!1:((p=a.value.isActive)==null?void 0:p.value)??!1:!1}),d=R(()=>{var p;return e.to?(p=a.value)==null?void 0:p.route.value.href:e.href});return{isLink:r,isClickable:s,isActive:u,route:(c=a.value)==null?void 0:c.route,navigate:(f=a.value)==null?void 0:f.navigate,href:d,linkProps:vn({href:d,"aria-current":R(()=>u.value?"page":void 0)})}}const Hp=de({href:String,replace:Boolean,to:[String,Object],exact:Boolean},"router");let tg=!1;function gN(e,t){let n=!1,r,s;kt&&(Ot(()=>{window.addEventListener("popstate",i),r=e==null?void 0:e.beforeEach((o,a,l)=>{tg?n?t(l):l():setTimeout(()=>n?t(l):l()),tg=!0}),s=e==null?void 0:e.afterEach(()=>{tg=!1})}),Sn(()=>{window.removeEventListener("popstate",i),r==null||r(),s==null||s()}));function i(o){var a;(a=o.state)!=null&&a.replaced||(n=!0,setTimeout(()=>n=!1))}}function vN(e,t){Ce(()=>{var n;return(n=e.isActive)==null?void 0:n.value},n=>{e.isLink.value&&n&&t&&Ot(()=>{t(!0)})},{immediate:!0})}const kv=Symbol("rippleStop"),yN=80;function G_(e,t){e.style.transform=t,e.style.webkitTransform=t}function xv(e){return e.constructor.name==="TouchEvent"}function BP(e){return e.constructor.name==="KeyboardEvent"}const bN=function(e,t){var c;let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=0,s=0;if(!BP(e)){const f=t.getBoundingClientRect(),p=xv(e)?e.touches[e.touches.length-1]:e;r=p.clientX-f.left,s=p.clientY-f.top}let i=0,o=.3;(c=t._ripple)!=null&&c.circle?(o=.15,i=t.clientWidth/2,i=n.center?i:i+Math.sqrt((r-i)**2+(s-i)**2)/4):i=Math.sqrt(t.clientWidth**2+t.clientHeight**2)/2;const a=`${(t.clientWidth-i*2)/2}px`,l=`${(t.clientHeight-i*2)/2}px`,u=n.center?a:`${r-i}px`,d=n.center?l:`${s-i}px`;return{radius:i,scale:o,x:u,y:d,centerX:a,centerY:l}},Lh={show(e,t){var p;let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};if(!((p=t==null?void 0:t._ripple)!=null&&p.enabled))return;const r=document.createElement("span"),s=document.createElement("span");r.appendChild(s),r.className="v-ripple__container",n.class&&(r.className+=` ${n.class}`);const{radius:i,scale:o,x:a,y:l,centerX:u,centerY:d}=bN(e,t,n),c=`${i*2}px`;s.className="v-ripple__animation",s.style.width=c,s.style.height=c,t.appendChild(r);const f=window.getComputedStyle(t);f&&f.position==="static"&&(t.style.position="relative",t.dataset.previousPosition="static"),s.classList.add("v-ripple__animation--enter"),s.classList.add("v-ripple__animation--visible"),G_(s,`translate(${a}, ${l}) scale3d(${o},${o},${o})`),s.dataset.activated=String(performance.now()),setTimeout(()=>{s.classList.remove("v-ripple__animation--enter"),s.classList.add("v-ripple__animation--in"),G_(s,`translate(${u}, ${d}) scale3d(1,1,1)`)},0)},hide(e){var i;if(!((i=e==null?void 0:e._ripple)!=null&&i.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 r=performance.now()-Number(n.dataset.activated),s=Math.max(250-r,0);setTimeout(()=>{n.classList.remove("v-ripple__animation--in"),n.classList.add("v-ripple__animation--out"),setTimeout(()=>{var a;e.getElementsByClassName("v-ripple__animation").length===1&&e.dataset.previousPosition&&(e.style.position=e.dataset.previousPosition,delete e.dataset.previousPosition),((a=n.parentNode)==null?void 0:a.parentNode)===e&&e.removeChild(n.parentNode)},300)},s)}};function VP(e){return typeof e>"u"||!!e}function qc(e){const t={},n=e.currentTarget;if(!(!(n!=null&&n._ripple)||n._ripple.touched||e[kv])){if(e[kv]=!0,xv(e))n._ripple.touched=!0,n._ripple.isTouch=!0;else if(n._ripple.isTouch)return;if(t.center=n._ripple.centered||BP(e),n._ripple.class&&(t.class=n._ripple.class),xv(e)){if(n._ripple.showTimerCommit)return;n._ripple.showTimerCommit=()=>{Lh.show(e,n,t)},n._ripple.showTimer=window.setTimeout(()=>{var r;(r=n==null?void 0:n._ripple)!=null&&r.showTimerCommit&&(n._ripple.showTimerCommit(),n._ripple.showTimerCommit=null)},yN)}else Lh.show(e,n,t)}}function K_(e){e[kv]=!0}function Wr(e){const t=e.currentTarget;if(t!=null&&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(()=>{Wr(e)});return}window.setTimeout(()=>{t._ripple&&(t._ripple.touched=!1)}),Lh.hide(t)}}function UP(e){const t=e.currentTarget;t!=null&&t._ripple&&(t._ripple.showTimerCommit&&(t._ripple.showTimerCommit=null),window.clearTimeout(t._ripple.showTimer))}let Wc=!1;function HP(e){!Wc&&(e.keyCode===b_.enter||e.keyCode===b_.space)&&(Wc=!0,qc(e))}function zP(e){Wc=!1,Wr(e)}function jP(e){Wc&&(Wc=!1,Wr(e))}function qP(e,t,n){const{value:r,modifiers:s}=t,i=VP(r);if(i||Lh.hide(e),e._ripple=e._ripple??{},e._ripple.enabled=i,e._ripple.centered=s.center,e._ripple.circle=s.circle,nF(r)&&r.class&&(e._ripple.class=r.class),i&&!n){if(s.stop){e.addEventListener("touchstart",K_,{passive:!0}),e.addEventListener("mousedown",K_);return}e.addEventListener("touchstart",qc,{passive:!0}),e.addEventListener("touchend",Wr,{passive:!0}),e.addEventListener("touchmove",UP,{passive:!0}),e.addEventListener("touchcancel",Wr),e.addEventListener("mousedown",qc),e.addEventListener("mouseup",Wr),e.addEventListener("mouseleave",Wr),e.addEventListener("keydown",HP),e.addEventListener("keyup",zP),e.addEventListener("blur",jP),e.addEventListener("dragstart",Wr,{passive:!0})}else!i&&n&&WP(e)}function WP(e){e.removeEventListener("mousedown",qc),e.removeEventListener("touchstart",qc),e.removeEventListener("touchend",Wr),e.removeEventListener("touchmove",UP),e.removeEventListener("touchcancel",Wr),e.removeEventListener("mouseup",Wr),e.removeEventListener("mouseleave",Wr),e.removeEventListener("keydown",HP),e.removeEventListener("keyup",zP),e.removeEventListener("dragstart",Wr),e.removeEventListener("blur",jP)}function wN(e,t){qP(e,t,!1)}function SN(e){delete e._ripple,WP(e)}function _N(e,t){if(t.value===t.oldValue)return;const n=VP(t.oldValue);qP(e,t,n)}const Iu={mounted:wN,unmounted:SN,updated:_N},GP=de({active:{type:Boolean,default:void 0},activeColor:String,baseColor:String,symbol:{type:null,default:IP},flat:Boolean,icon:[Boolean,String,Function,Object],prependIcon:Je,appendIcon:Je,block:Boolean,readonly:Boolean,slim:Boolean,stacked:Boolean,ripple:{type:[Boolean,Object],default:!0},text:String,...vs(),...Ve(),...Lr(),...$r(),...bs(),...Pd(),...Bp(),...Ko(),...Tu(),...Bn(),...Hp(),...Pu(),...bt({tag:"button"}),...Dt(),...Fs({variant:"elevated"})},"VBtn"),re=xe()({name:"VBtn",props:GP(),emits:{"group:selected":e=>!0},setup(e,t){let{attrs:n,slots:r}=t;const{themeClasses:s}=Xt(e),{borderClasses:i}=Ls(e),{densityClasses:o}=ys(e),{dimensionStyles:a}=Fr(e),{elevationClasses:l}=$s(e),{loaderClasses:u}=Ad(e),{locationStyles:d}=tl(e),{positionClasses:c}=Ru(e),{roundedClasses:f}=qn(e),{sizeClasses:p,sizeStyles:g}=Rd(e),m=Td(e,e.symbol,!1),y=Up(e,n),b=R(()=>{var M;return e.active!==void 0?e.active:y.isLink.value?(M=y.isActive)==null?void 0:M.value:m==null?void 0:m.isSelected.value}),w=R(()=>b.value?e.activeColor??e.color:e.color),S=R(()=>{var O,A;return{color:(m==null?void 0:m.isSelected.value)&&(!y.isLink.value||((O=y.isActive)==null?void 0:O.value))||!m||((A=y.isActive)==null?void 0:A.value)?w.value??e.baseColor:e.baseColor,variant:e.variant}}),{colorClasses:P,colorStyles:E,variantClasses:T}=el(S),C=R(()=>(m==null?void 0:m.disabled.value)||e.disabled),k=R(()=>e.variant==="elevated"&&!(e.disabled||e.flat||e.border)),x=R(()=>{if(!(e.value===void 0||typeof e.value=="symbol"))return Object(e.value)===e.value?JSON.stringify(e.value,null,0):e.value});function I(M){var O;C.value||y.isLink.value&&(M.metaKey||M.ctrlKey||M.shiftKey||M.button!==0||n.target==="_blank")||((O=y.navigate)==null||O.call(y,M),m==null||m.toggle())}return vN(y,m==null?void 0:m.select),Ie(()=>{const M=y.isLink.value?"a":e.tag,O=!!(e.prependIcon||r.prepend),A=!!(e.appendIcon||r.append),D=!!(e.icon&&e.icon!==!0);return en(h(M,me({type:M==="a"?void 0:"button",class:["v-btn",m==null?void 0:m.selectedClass.value,{"v-btn--active":b.value,"v-btn--block":e.block,"v-btn--disabled":C.value,"v-btn--elevated":k.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},s.value,i.value,P.value,o.value,l.value,u.value,c.value,f.value,p.value,T.value,e.class],style:[E.value,a.value,d.value,g.value,e.style],"aria-busy":e.loading?!0:void 0,disabled:C.value||void 0,tabindex:e.loading||e.readonly?-1:void 0,onClick:I,value:x.value},y.linkProps),{default:()=>{var V;return[Go(!0,"v-btn"),!e.icon&&O&&h("span",{key:"prepend",class:"v-btn__prepend"},[r.prepend?h(At,{key:"prepend-defaults",disabled:!e.prependIcon,defaults:{VIcon:{icon:e.prependIcon}}},r.prepend):h(X,{key:"prepend-icon",icon:e.prependIcon},null)]),h("span",{class:"v-btn__content","data-no-activator":""},[!r.default&&D?h(X,{key:"content-icon",icon:e.icon},null):h(At,{key:"content-defaults",disabled:!D,defaults:{VIcon:{icon:e.icon}}},{default:()=>{var H;return[((H=r.default)==null?void 0:H.call(r))??e.text]}})]),!e.icon&&A&&h("span",{key:"append",class:"v-btn__append"},[r.append?h(At,{key:"append-defaults",disabled:!e.appendIcon,defaults:{VIcon:{icon:e.appendIcon}}},r.append):h(X,{key:"append-icon",icon:e.appendIcon},null)]),!!e.loading&&h("span",{key:"loader",class:"v-btn__loader"},[((V=r.loader)==null?void 0:V.call(r))??h(Id,{color:typeof e.loading=="boolean"?void 0:e.loading,indeterminate:!0,width:"2"},null)])]}}),[[Iu,!C.value&&e.ripple,"",{center:!!e.icon}]])}),{group:m}}}),kN=de({disabled:Boolean,group:Boolean,hideOnLeave:Boolean,leaveAbsolute:Boolean,mode:String,origin:String},"transition");function ts(e,t,n){return xe()({name:e,props:kN({mode:n,origin:t}),setup(r,s){let{slots:i}=s;const o={onBeforeEnter(a){r.origin&&(a.style.transformOrigin=r.origin)},onLeave(a){if(r.leaveAbsolute){const{offsetTop:l,offsetLeft:u,offsetWidth:d,offsetHeight:c}=a;a._transitionInitialStyles={position:a.style.position,top:a.style.top,left:a.style.left,width:a.style.width,height:a.style.height},a.style.position="absolute",a.style.top=`${l}px`,a.style.left=`${u}px`,a.style.width=`${d}px`,a.style.height=`${c}px`}r.hideOnLeave&&a.style.setProperty("display","none","important")},onAfterLeave(a){if(r.leaveAbsolute&&(a!=null&&a._transitionInitialStyles)){const{position:l,top:u,left:d,width:c,height:f}=a._transitionInitialStyles;delete a._transitionInitialStyles,a.style.position=l||"",a.style.top=u||"",a.style.left=d||"",a.style.width=c||"",a.style.height=f||""}}};return()=>{const a=r.group?Cb:$o;return Mr(a,{name:r.disabled?"":e,css:!r.disabled,...r.group?void 0:{mode:r.mode},...r.disabled?{}:o},i.default)}}})}function KP(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"in-out";return xe()({name:e,props:{mode:{type:String,default:n},disabled:Boolean,group:Boolean},setup(r,s){let{slots:i}=s;const o=r.group?Cb:$o;return()=>Mr(o,{name:r.disabled?"":e,css:!r.disabled,...r.disabled?{}:t},i.default)}})}function YP(){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",r=Or(`offset-${n}`);return{onBeforeEnter(o){o._parent=o.parentNode,o._initialStyle={transition:o.style.transition,overflow:o.style.overflow,[n]:o.style[n]}},onEnter(o){const a=o._initialStyle;o.style.setProperty("transition","none","important"),o.style.overflow="hidden";const l=`${o[r]}px`;o.style[n]="0",o.offsetHeight,o.style.transition=a.transition,e&&o._parent&&o._parent.classList.add(e),requestAnimationFrame(()=>{o.style[n]=l})},onAfterEnter:i,onEnterCancelled:i,onLeave(o){o._initialStyle={transition:"",overflow:o.style.overflow,[n]:o.style[n]},o.style.overflow="hidden",o.style[n]=`${o[r]}px`,o.offsetHeight,requestAnimationFrame(()=>o.style[n]="0")},onAfterLeave:s,onLeaveCancelled:s};function s(o){e&&o._parent&&o._parent.classList.remove(e),i(o)}function i(o){const a=o._initialStyle[n];o.style.overflow=o._initialStyle.overflow,a!=null&&(o.style[n]=a),delete o._initialStyle}}const xN=de({target:[Object,Array]},"v-dialog-transition"),$b=xe()({name:"VDialogTransition",props:xN(),setup(e,t){let{slots:n}=t;const r={onBeforeEnter(s){s.style.pointerEvents="none",s.style.visibility="hidden"},async onEnter(s,i){var f;await new Promise(p=>requestAnimationFrame(p)),await new Promise(p=>requestAnimationFrame(p)),s.style.visibility="";const{x:o,y:a,sx:l,sy:u,speed:d}=X_(e.target,s),c=Tl(s,[{transform:`translate(${o}px, ${a}px) scale(${l}, ${u})`,opacity:0},{}],{duration:225*d,easing:BF});(f=Y_(s))==null||f.forEach(p=>{Tl(p,[{opacity:0},{opacity:0,offset:.33},{}],{duration:225*2*d,easing:Oh})}),c.finished.then(()=>i())},onAfterEnter(s){s.style.removeProperty("pointer-events")},onBeforeLeave(s){s.style.pointerEvents="none"},async onLeave(s,i){var f;await new Promise(p=>requestAnimationFrame(p));const{x:o,y:a,sx:l,sy:u,speed:d}=X_(e.target,s);Tl(s,[{},{transform:`translate(${o}px, ${a}px) scale(${l}, ${u})`,opacity:0}],{duration:125*d,easing:VF}).finished.then(()=>i()),(f=Y_(s))==null||f.forEach(p=>{Tl(p,[{},{opacity:0,offset:.2},{opacity:0}],{duration:125*2*d,easing:Oh})})},onAfterLeave(s){s.style.removeProperty("pointer-events")}};return()=>e.target?h($o,me({name:"dialog-transition"},r,{css:!1}),n):h($o,{name:"dialog-transition"},n)}});function Y_(e){var n;const t=(n=e.querySelector(":scope > .v-card, :scope > .v-sheet, :scope > .v-list"))==null?void 0:n.children;return t&&[...t]}function X_(e,t){const n=bP(e),r=Ab(t),[s,i]=getComputedStyle(t).transformOrigin.split(" ").map(b=>parseFloat(b)),[o,a]=getComputedStyle(t).getPropertyValue("--v-overlay-anchor-origin").split(" ");let l=n.left+n.width/2;o==="left"||a==="left"?l-=n.width/2:(o==="right"||a==="right")&&(l+=n.width/2);let u=n.top+n.height/2;o==="top"||a==="top"?u-=n.height/2:(o==="bottom"||a==="bottom")&&(u+=n.height/2);const d=n.width/r.width,c=n.height/r.height,f=Math.max(1,d,c),p=d/f||0,g=c/f||0,m=r.width*r.height/(window.innerWidth*window.innerHeight),y=m>.12?Math.min(1.5,(m-.12)*10+1):1;return{x:l-(s+r.left),y:u-(i+r.top),sx:p,sy:g,speed:y}}ts("fab-transition","center center","out-in");ts("dialog-bottom-transition");ts("dialog-top-transition");const Q_=ts("fade-transition"),EN=ts("scale-transition");ts("scroll-x-transition");ts("scroll-x-reverse-transition");const CN=ts("scroll-y-transition");ts("scroll-y-reverse-transition");ts("slide-x-transition");ts("slide-x-reverse-transition");const XP=ts("slide-y-transition");ts("slide-y-reverse-transition");const QP=KP("expand-transition",YP()),JP=KP("expand-x-transition",YP("",!0));function ng(e,t){return{x:e.x+t.x,y:e.y+t.y}}function PN(e,t){return{x:e.x-t.x,y:e.y-t.y}}function J_(e,t){if(e.side==="top"||e.side==="bottom"){const{side:n,align:r}=e,s=r==="left"?0:r==="center"?t.width/2:r==="right"?t.width:r,i=n==="top"?0:n==="bottom"?t.height:n;return ng({x:s,y:i},t)}else if(e.side==="left"||e.side==="right"){const{side:n,align:r}=e,s=n==="left"?0:n==="right"?t.width:n,i=r==="top"?0:r==="center"?t.height/2:r==="bottom"?t.height:r;return ng({x:s,y:i},t)}return ng({x:t.width/2,y:t.height/2},t)}const ZP={static:IN,connected:ON},TN=de({locationStrategy:{type:[String,Function],default:"static",validator:e=>typeof e=="function"||e in ZP},location:{type:String,default:"bottom"},origin:{type:String,default:"auto"},offset:[Number,String,Array]},"VOverlay-location-strategies");function RN(e,t){const n=U({}),r=U();kt&&Qr(()=>!!(t.isActive.value&&e.locationStrategy),i=>{var o,a;Ce(()=>e.locationStrategy,i),Sn(()=>{window.removeEventListener("resize",s),r.value=void 0}),window.addEventListener("resize",s,{passive:!0}),typeof e.locationStrategy=="function"?r.value=(o=e.locationStrategy(t,e,n))==null?void 0:o.updateLocation:r.value=(a=ZP[e.locationStrategy](t,e,n))==null?void 0:a.updateLocation});function s(i){var o;(o=r.value)==null||o.call(r,i)}return{contentStyles:n,updateLocation:r}}function IN(){}function AN(e,t){const n=Ab(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 ON(e,t,n){(Array.isArray(e.target.value)||HF(e.target.value))&&Object.assign(n.value,{position:"fixed",top:0,[e.isRtl.value?"right":"left"]:0});const{preferredAnchor:s,preferredOrigin:i}=Rb(()=>{const g=bv(t.location,e.isRtl.value),m=t.origin==="overlap"?g:t.origin==="auto"?Jm(g):bv(t.origin,e.isRtl.value);return g.side===m.side&&g.align===Zm(m).align?{preferredAnchor:C_(g),preferredOrigin:C_(m)}:{preferredAnchor:g,preferredOrigin:m}}),[o,a,l,u]=["minWidth","minHeight","maxWidth","maxHeight"].map(g=>R(()=>{const m=parseFloat(t[g]);return isNaN(m)?1/0:m})),d=R(()=>{if(Array.isArray(t.offset))return t.offset;if(typeof t.offset=="string"){const g=t.offset.split(" ").map(parseFloat);return g.length<2&&g.push(0),g}return typeof t.offset=="number"?[t.offset,0]:[0,0]});let c=!1;const f=new ResizeObserver(()=>{c&&p()});Ce([e.target,e.contentEl],(g,m)=>{let[y,b]=g,[w,S]=m;w&&!Array.isArray(w)&&f.unobserve(w),y&&!Array.isArray(y)&&f.observe(y),S&&f.unobserve(S),b&&f.observe(b)},{immediate:!0}),Sn(()=>{f.disconnect()});function p(){if(c=!1,requestAnimationFrame(()=>c=!0),!e.target.value||!e.contentEl.value)return;const g=bP(e.target.value),m=AN(e.contentEl.value,e.isRtl.value),y=Mh(e.contentEl.value),b=12;y.length||(y.push(document.documentElement),e.contentEl.value.style.top&&e.contentEl.value.style.left||(m.x-=parseFloat(document.documentElement.style.getPropertyValue("--v-body-scroll-x")||0),m.y-=parseFloat(document.documentElement.style.getPropertyValue("--v-body-scroll-y")||0)));const w=y.reduce((M,O)=>{const A=O.getBoundingClientRect(),D=new Ia({x:O===document.documentElement?0:A.x,y:O===document.documentElement?0:A.y,width:O.clientWidth,height:O.clientHeight});return M?new Ia({x:Math.max(M.left,D.left),y:Math.max(M.top,D.top),width:Math.min(M.right,D.right)-Math.max(M.left,D.left),height:Math.min(M.bottom,D.bottom)-Math.max(M.top,D.top)}):D},void 0);w.x+=b,w.y+=b,w.width-=b*2,w.height-=b*2;let S={anchor:s.value,origin:i.value};function P(M){const O=new Ia(m),A=J_(M.anchor,g),D=J_(M.origin,O);let{x:V,y:H}=PN(A,D);switch(M.anchor.side){case"top":H-=d.value[0];break;case"bottom":H+=d.value[0];break;case"left":V-=d.value[0];break;case"right":V+=d.value[0];break}switch(M.anchor.align){case"top":H-=d.value[1];break;case"bottom":H+=d.value[1];break;case"left":V-=d.value[1];break;case"right":V+=d.value[1];break}return O.x+=V,O.y+=H,O.width=Math.min(O.width,l.value),O.height=Math.min(O.height,u.value),{overflows:T_(O,w),x:V,y:H}}let E=0,T=0;const C={x:0,y:0},k={x:!1,y:!1};let x=-1;for(;!(x++>10);){const{x:M,y:O,overflows:A}=P(S);E+=M,T+=O,m.x+=M,m.y+=O;{const D=P_(S.anchor),V=A.x.before||A.x.after,H=A.y.before||A.y.after;let G=!1;if(["x","y"].forEach(j=>{if(j==="x"&&V&&!k.x||j==="y"&&H&&!k.y){const B={anchor:{...S.anchor},origin:{...S.origin}},W=j==="x"?D==="y"?Zm:Jm:D==="y"?Jm:Zm;B.anchor=W(B.anchor),B.origin=W(B.origin);const{overflows:Z}=P(B);(Z[j].before<=A[j].before&&Z[j].after<=A[j].after||Z[j].before+Z[j].after<(A[j].before+A[j].after)/2)&&(S=B,G=k[j]=!0)}}),G)continue}A.x.before&&(E+=A.x.before,m.x+=A.x.before),A.x.after&&(E-=A.x.after,m.x-=A.x.after),A.y.before&&(T+=A.y.before,m.y+=A.y.before),A.y.after&&(T-=A.y.after,m.y-=A.y.after);{const D=T_(m,w);C.x=w.width-D.x.before-D.x.after,C.y=w.height-D.y.before-D.y.after,E+=D.x.before,m.x+=D.x.before,T+=D.y.before,m.y+=D.y.before}break}const I=P_(S.anchor);return Object.assign(n.value,{"--v-overlay-anchor-origin":`${S.anchor.side} ${S.anchor.align}`,transformOrigin:`${S.origin.side} ${S.origin.align}`,top:Ne(rg(T)),left:e.isRtl.value?void 0:Ne(rg(E)),right:e.isRtl.value?Ne(rg(-E)):void 0,minWidth:Ne(I==="y"?Math.min(o.value,g.width):o.value),maxWidth:Ne(Z_(Rr(C.x,o.value===1/0?0:o.value,l.value))),maxHeight:Ne(Z_(Rr(C.y,a.value===1/0?0:a.value,u.value)))}),{available:C,contentBox:m}}return Ce(()=>[s.value,i.value,t.offset,t.minWidth,t.minHeight,t.maxWidth,t.maxHeight],()=>p()),Ot(()=>{const g=p();if(!g)return;const{available:m,contentBox:y}=g;y.height>m.y&&requestAnimationFrame(()=>{p(),requestAnimationFrame(()=>{p()})})}),{updateLocation:p}}function rg(e){return Math.round(e*devicePixelRatio)/devicePixelRatio}function Z_(e){return Math.ceil(e*devicePixelRatio)/devicePixelRatio}let Ev=!0;const $h=[];function MN(e){!Ev||$h.length?($h.push(e),Cv()):(Ev=!1,e(),Cv())}let e0=-1;function Cv(){cancelAnimationFrame(e0),e0=requestAnimationFrame(()=>{const e=$h.shift();e&&e(),$h.length?Cv():Ev=!0})}const Qf={none:null,close:$N,block:FN,reposition:NN},DN=de({scrollStrategy:{type:[String,Function],default:"block",validator:e=>typeof e=="function"||e in Qf}},"VOverlay-scroll-strategies");function LN(e,t){if(!kt)return;let n;jn(async()=>{n==null||n.stop(),t.isActive.value&&e.scrollStrategy&&(n=wd(),await new Promise(r=>setTimeout(r)),n.active&&n.run(()=>{var r;typeof e.scrollStrategy=="function"?e.scrollStrategy(t,e,n):(r=Qf[e.scrollStrategy])==null||r.call(Qf,t,e,n)}))}),Sn(()=>{n==null||n.stop()})}function $N(e){function t(n){e.isActive.value=!1}eT(e.targetEl.value??e.contentEl.value,t)}function FN(e,t){var o;const n=(o=e.root.value)==null?void 0:o.offsetParent,r=[...new Set([...Mh(e.targetEl.value,t.contained?n:void 0),...Mh(e.contentEl.value,t.contained?n:void 0)])].filter(a=>!a.classList.contains("v-overlay-scroll-blocked")),s=window.innerWidth-document.documentElement.offsetWidth,i=(a=>Db(a)&&a)(n||document.documentElement);i&&e.root.value.classList.add("v-overlay--scroll-blocked"),r.forEach((a,l)=>{a.style.setProperty("--v-body-scroll-x",Ne(-a.scrollLeft)),a.style.setProperty("--v-body-scroll-y",Ne(-a.scrollTop)),a!==document.documentElement&&a.style.setProperty("--v-scrollbar-offset",Ne(s)),a.classList.add("v-overlay-scroll-blocked")}),Sn(()=>{r.forEach((a,l)=>{const u=parseFloat(a.style.getPropertyValue("--v-body-scroll-x")),d=parseFloat(a.style.getPropertyValue("--v-body-scroll-y")),c=a.style.scrollBehavior;a.style.scrollBehavior="auto",a.style.removeProperty("--v-body-scroll-x"),a.style.removeProperty("--v-body-scroll-y"),a.style.removeProperty("--v-scrollbar-offset"),a.classList.remove("v-overlay-scroll-blocked"),a.scrollLeft=-u,a.scrollTop=-d,a.style.scrollBehavior=c}),i&&e.root.value.classList.remove("v-overlay--scroll-blocked")})}function NN(e,t,n){let r=!1,s=-1,i=-1;function o(a){MN(()=>{var d,c;const l=performance.now();(c=(d=e.updateLocation).value)==null||c.call(d,a),r=(performance.now()-l)/(1e3/60)>2})}i=(typeof requestIdleCallback>"u"?a=>a():requestIdleCallback)(()=>{n.run(()=>{eT(e.targetEl.value??e.contentEl.value,a=>{r?(cancelAnimationFrame(s),s=requestAnimationFrame(()=>{s=requestAnimationFrame(()=>{o(a)})})):o(a)})})}),Sn(()=>{typeof cancelIdleCallback<"u"&&cancelIdleCallback(i),cancelAnimationFrame(s)})}function eT(e,t){const n=[document,...Mh(e)];n.forEach(r=>{r.addEventListener("scroll",t,{passive:!0})}),Sn(()=>{n.forEach(r=>{r.removeEventListener("scroll",t)})})}const Pv=Symbol.for("vuetify:v-menu"),Fb=de({closeDelay:[Number,String],openDelay:[Number,String]},"delay");function Nb(e,t){let n=()=>{};function r(o){n==null||n();const a=Number(o?e.openDelay:e.closeDelay);return new Promise(l=>{n=aF(a,()=>{t==null||t(o),l(o)})})}function s(){return r(!0)}function i(){return r(!1)}return{clearDelay:n,runOpenDelay:s,runCloseDelay:i}}const BN=de({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,...Fb()},"VOverlay-activator");function VN(e,t){let{isActive:n,isTop:r,contentEl:s}=t;const i=sn("useActivator"),o=U();let a=!1,l=!1,u=!0;const d=R(()=>e.openOnFocus||e.openOnFocus==null&&e.openOnHover),c=R(()=>e.openOnClick||e.openOnClick==null&&!e.openOnHover&&!d.value),{runOpenDelay:f,runCloseDelay:p}=Nb(e,k=>{k===(e.openOnHover&&a||d.value&&l)&&!(e.openOnHover&&n.value&&!r.value)&&(n.value!==k&&(u=!0),n.value=k)}),g=U(),m={onClick:k=>{k.stopPropagation(),o.value=k.currentTarget||k.target,n.value||(g.value=[k.clientX,k.clientY]),n.value=!n.value},onMouseenter:k=>{var x;(x=k.sourceCapabilities)!=null&&x.firesTouchEvents||(a=!0,o.value=k.currentTarget||k.target,f())},onMouseleave:k=>{a=!1,p()},onFocus:k=>{Ih(k.target,":focus-visible")!==!1&&(l=!0,k.stopPropagation(),o.value=k.currentTarget||k.target,f())},onBlur:k=>{l=!1,k.stopPropagation(),p()}},y=R(()=>{const k={};return c.value&&(k.onClick=m.onClick),e.openOnHover&&(k.onMouseenter=m.onMouseenter,k.onMouseleave=m.onMouseleave),d.value&&(k.onFocus=m.onFocus,k.onBlur=m.onBlur),k}),b=R(()=>{const k={};if(e.openOnHover&&(k.onMouseenter=()=>{a=!0,f()},k.onMouseleave=()=>{a=!1,p()}),d.value&&(k.onFocusin=()=>{l=!0,f()},k.onFocusout=()=>{l=!1,p()}),e.closeOnContentClick){const x=Ye(Pv,null);k.onClick=()=>{n.value=!1,x==null||x.closeParents()}}return k}),w=R(()=>{const k={};return e.openOnHover&&(k.onMouseenter=()=>{u&&(a=!0,u=!1,f())},k.onMouseleave=()=>{a=!1,p()}),k});Ce(r,k=>{var x;k&&(e.openOnHover&&!a&&(!d.value||!l)||d.value&&!l&&(!e.openOnHover||!a))&&!((x=s.value)!=null&&x.contains(document.activeElement))&&(n.value=!1)}),Ce(n,k=>{k||setTimeout(()=>{g.value=void 0})},{flush:"post"});const S=yv();jn(()=>{S.value&&Ot(()=>{o.value=S.el})});const P=yv(),E=R(()=>e.target==="cursor"&&g.value?g.value:P.value?P.el:tT(e.target,i)||o.value),T=R(()=>Array.isArray(E.value)?void 0:E.value);let C;return Ce(()=>!!e.activator,k=>{k&&kt?(C=wd(),C.run(()=>{UN(e,i,{activatorEl:o,activatorEvents:y})})):C&&C.stop()},{flush:"post",immediate:!0}),Sn(()=>{C==null||C.stop()}),{activatorEl:o,activatorRef:S,target:E,targetEl:T,targetRef:P,activatorEvents:y,contentEvents:b,scrimEvents:w}}function UN(e,t,n){let{activatorEl:r,activatorEvents:s}=n;Ce(()=>e.activator,(l,u)=>{if(u&&l!==u){const d=a(u);d&&o(d)}l&&Ot(()=>i())},{immediate:!0}),Ce(()=>e.activatorProps,()=>{i()}),Sn(()=>{o()});function i(){let l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:a(),u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:e.activatorProps;l&&cF(l,me(s.value,u))}function o(){let l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:a(),u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:e.activatorProps;l&&dF(l,me(s.value,u))}function a(){let l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:e.activator;const u=tT(l,t);return r.value=(u==null?void 0:u.nodeType)===Node.ELEMENT_NODE?u:void 0,r.value}}function tT(e,t){var r,s;if(!e)return;let n;if(e==="parent"){let i=(s=(r=t==null?void 0:t.proxy)==null?void 0:r.$el)==null?void 0:s.parentNode;for(;i!=null&&i.hasAttribute("data-no-activator");)i=i.parentNode;n=i}else typeof e=="string"?n=document.querySelector(e):"$el"in e?n=e.$el:n=e;return n}const zp=["sm","md","lg","xl","xxl"],Tv=Symbol.for("vuetify:display"),t0={mobileBreakpoint:"lg",thresholds:{xs:0,sm:600,md:960,lg:1280,xl:1920,xxl:2560}},HN=function(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:t0;return tr(t0,e)};function n0(e){return kt&&!e?window.innerWidth:typeof e=="object"&&e.clientWidth||0}function r0(e){return kt&&!e?window.innerHeight:typeof e=="object"&&e.clientHeight||0}function s0(e){const t=kt&&!e?window.navigator.userAgent:"ssr";function n(g){return!!t.match(g)}const r=n(/android/i),s=n(/iphone|ipad|ipod/i),i=n(/cordova/i),o=n(/electron/i),a=n(/chrome/i),l=n(/edge/i),u=n(/firefox/i),d=n(/opera/i),c=n(/win/i),f=n(/mac/i),p=n(/linux/i);return{android:r,ios:s,cordova:i,electron:o,chrome:a,edge:l,firefox:u,opera:d,win:c,mac:f,linux:p,touch:Z$,ssr:t==="ssr"}}function zN(e,t){const{thresholds:n,mobileBreakpoint:r}=HN(e),s=Me(r0(t)),i=Me(s0(t)),o=vn({}),a=Me(n0(t));function l(){s.value=r0(),a.value=n0()}function u(){l(),i.value=s0()}return jn(()=>{const d=a.value<n.sm,c=a.value<n.md&&!d,f=a.value<n.lg&&!(c||d),p=a.value<n.xl&&!(f||c||d),g=a.value<n.xxl&&!(p||f||c||d),m=a.value>=n.xxl,y=d?"xs":c?"sm":f?"md":p?"lg":g?"xl":"xxl",b=typeof r=="number"?r:n[r],w=a.value<b;o.xs=d,o.sm=c,o.md=f,o.lg=p,o.xl=g,o.xxl=m,o.smAndUp=!d,o.mdAndUp=!(d||c),o.lgAndUp=!(d||c||f),o.xlAndUp=!(d||c||f||p),o.smAndDown=!(f||p||g||m),o.mdAndDown=!(p||g||m),o.lgAndDown=!(g||m),o.xlAndDown=!m,o.name=y,o.height=s.value,o.width=a.value,o.mobile=w,o.mobileBreakpoint=r,o.platform=i.value,o.thresholds=n}),kt&&window.addEventListener("resize",l,{passive:!0}),{...jo(o),update:u,ssr:!!t}}const nl=de({mobile:{type:Boolean,default:!1},mobileBreakpoint:[Number,String]},"display");function mi(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:pi();const n=Ye(Tv);if(!n)throw new Error("Could not find Vuetify display injection");const r=R(()=>{if(e.mobile!=null)return e.mobile;if(!e.mobileBreakpoint)return n.mobile.value;const i=typeof e.mobileBreakpoint=="number"?e.mobileBreakpoint:n.thresholds.value[e.mobileBreakpoint];return n.width.value<i}),s=R(()=>t?{[`${t}--mobile`]:r.value}:{});return{...n,displayClasses:s,mobile:r}}function jN(){if(!kt)return Me(!1);const{ssr:e}=mi();if(e){const t=Me(!1);return St(()=>{t.value=!0}),t}else return Me(!0)}const nT=de({eager:Boolean},"lazy");function rT(e,t){const n=Me(!1),r=R(()=>n.value||e.eager||t.value);Ce(t,()=>n.value=!0);function s(){e.eager||(n.value=!1)}return{isBooted:n,hasContent:r,onAfterLeave:s}}function Au(){const t=sn("useScopeId").vnode.scopeId;return{scopeId:t?{[t]:""}:void 0}}const i0=Symbol.for("vuetify:stack"),Qu=vn([]);function qN(e,t,n){const r=sn("useStack"),s=!n,i=Ye(i0,void 0),o=vn({activeChildren:new Set});Gt(i0,o);const a=Me(+t.value);Qr(e,()=>{var c;const d=(c=Qu.at(-1))==null?void 0:c[1];a.value=d?d+10:+t.value,s&&Qu.push([r.uid,a.value]),i==null||i.activeChildren.add(r.uid),Sn(()=>{if(s){const f=Be(Qu).findIndex(p=>p[0]===r.uid);Qu.splice(f,1)}i==null||i.activeChildren.delete(r.uid)})});const l=Me(!0);s&&jn(()=>{var c;const d=((c=Qu.at(-1))==null?void 0:c[0])===r.uid;setTimeout(()=>l.value=d)});const u=R(()=>!o.activeChildren.size);return{globalTop:Sd(l),localTop:u,stackStyles:R(()=>({zIndex:a.value}))}}function WN(e){return{teleportTarget:R(()=>{const n=e();if(n===!0||!kt)return;const r=n===!1?document.body:typeof n=="string"?document.querySelector(n):n;if(r==null)return;let s=[...r.children].find(i=>i.matches(".v-overlay-container"));return s||(s=document.createElement("div"),s.className="v-overlay-container",r.appendChild(s)),s})}}const Ou=de({transition:{type:[Boolean,String,Object],default:"fade-transition",validator:e=>e!==!0}},"transition"),ii=(e,t)=>{let{slots:n}=t;const{transition:r,disabled:s,group:i,...o}=e,{component:a=i?Cb:$o,...l}=typeof r=="object"?r:{};return Mr(a,me(typeof r=="string"?{name:s?"":r}:l,typeof r=="string"?{}:Object.fromEntries(Object.entries({disabled:s,group:i}).filter(u=>{let[d,c]=u;return c!==void 0})),o),n)};function GN(){return!0}function sT(e,t,n){if(!e||iT(e,n)===!1)return!1;const r=CP(t);if(typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&r.host===e.target)return!1;const s=(typeof n.value=="object"&&n.value.include||(()=>[]))();return s.push(t),!s.some(i=>i==null?void 0:i.contains(e.target))}function iT(e,t){return(typeof t.value=="object"&&t.value.closeConditional||GN)(e)}function KN(e,t,n){const r=typeof n.value=="function"?n.value:n.value.handler;e.shadowTarget=e.target,t._clickOutside.lastMousedownWasOutside&&sT(e,t,n)&&setTimeout(()=>{iT(e,n)&&r&&r(e)},0)}function o0(e,t){const n=CP(e);t(document),typeof ShadowRoot<"u"&&n instanceof ShadowRoot&&t(n)}const YN={mounted(e,t){const n=s=>KN(s,e,t),r=s=>{e._clickOutside.lastMousedownWasOutside=sT(s,e,t)};o0(e,s=>{s.addEventListener("click",n,!0),s.addEventListener("mousedown",r,!0)}),e._clickOutside||(e._clickOutside={lastMousedownWasOutside:!1}),e._clickOutside[t.instance.$.uid]={onClick:n,onMousedown:r}},beforeUnmount(e,t){e._clickOutside&&(o0(e,n=>{var i;if(!n||!((i=e._clickOutside)!=null&&i[t.instance.$.uid]))return;const{onClick:r,onMousedown:s}=e._clickOutside[t.instance.$.uid];n.removeEventListener("click",r,!0),n.removeEventListener("mousedown",s,!0)}),delete e._clickOutside[t.instance.$.uid])}};function XN(e){const{modelValue:t,color:n,...r}=e;return h($o,{name:"fade-transition",appear:!0},{default:()=>[e.modelValue&&h("div",me({class:["v-overlay__scrim",e.color.backgroundColorClasses.value],style:e.color.backgroundColorStyles.value},r),null)]})}const Od=de({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},...BN(),...Ve(),...$r(),...nT(),...TN(),...DN(),...Dt(),...Ou()},"VOverlay"),Ni=xe()({name:"VOverlay",directives:{ClickOutside:YN},inheritAttrs:!1,props:{_disableGlobalStack:Boolean,...Od()},emits:{"click:outside":e=>!0,"update:modelValue":e=>!0,afterEnter:()=>!0,afterLeave:()=>!0},setup(e,t){let{slots:n,attrs:r,emit:s}=t;const i=sn("VOverlay"),o=U(),a=U(),l=U(),u=st(e,"modelValue"),d=R({get:()=>u.value,set:le=>{le&&e.disabled||(u.value=le)}}),{themeClasses:c}=Xt(e),{rtlClasses:f,isRtl:p}=Nr(),{hasContent:g,onAfterLeave:m}=rT(e,d),y=pr(R(()=>typeof e.scrim=="string"?e.scrim:null)),{globalTop:b,localTop:w,stackStyles:S}=qN(d,Te(e,"zIndex"),e._disableGlobalStack),{activatorEl:P,activatorRef:E,target:T,targetEl:C,targetRef:k,activatorEvents:x,contentEvents:I,scrimEvents:M}=VN(e,{isActive:d,isTop:w,contentEl:l}),{teleportTarget:O}=WN(()=>{var be,Se,te;const le=e.attach||e.contained;if(le)return le;const J=((be=P==null?void 0:P.value)==null?void 0:be.getRootNode())||((te=(Se=i.proxy)==null?void 0:Se.$el)==null?void 0:te.getRootNode());return J instanceof ShadowRoot?J:!1}),{dimensionStyles:A}=Fr(e),D=jN(),{scopeId:V}=Au();Ce(()=>e.disabled,le=>{le&&(d.value=!1)});const{contentStyles:H,updateLocation:G}=RN(e,{isRtl:p,contentEl:l,target:T,isActive:d});LN(e,{root:o,contentEl:l,targetEl:C,isActive:d,updateLocation:G});function j(le){s("click:outside",le),e.persistent?K():d.value=!1}function B(le){return d.value&&b.value&&(!e.scrim||le.target===a.value||le instanceof MouseEvent&&le.shadowTarget===a.value)}kt&&Ce(d,le=>{le?window.addEventListener("keydown",W):window.removeEventListener("keydown",W)},{immediate:!0}),Tn(()=>{kt&&window.removeEventListener("keydown",W)});function W(le){var J,be;le.key==="Escape"&&b.value&&(e.persistent?K():(d.value=!1,(J=l.value)!=null&&J.contains(document.activeElement)&&((be=P.value)==null||be.focus())))}const Z=NP();Qr(()=>e.closeOnBack,()=>{gN(Z,le=>{b.value&&d.value?(le(!1),e.persistent?K():d.value=!1):le()})});const q=U();Ce(()=>d.value&&(e.absolute||e.contained)&&O.value==null,le=>{if(le){const J=PP(o.value);J&&J!==document.scrollingElement&&(q.value=J.scrollTop)}});function K(){e.noClickAnimation||l.value&&Tl(l.value,[{transformOrigin:"center"},{transform:"scale(1.03)"},{transformOrigin:"center"}],{duration:150,easing:Oh})}function pe(){s("afterEnter")}function ue(){m(),s("afterLeave")}return Ie(()=>{var le;return h(Re,null,[(le=n.activator)==null?void 0:le.call(n,{isActive:d.value,targetRef:k,props:me({ref:E},x.value,e.activatorProps)}),D.value&&g.value&&h(oL,{disabled:!O.value,to:O.value},{default:()=>[h("div",me({class:["v-overlay",{"v-overlay--absolute":e.absolute||e.contained,"v-overlay--active":d.value,"v-overlay--contained":e.contained},c.value,f.value,e.class],style:[S.value,{"--v-overlay-opacity":e.opacity,top:Ne(q.value)},e.style],ref:o},V,r),[h(XN,me({color:y,modelValue:d.value&&!!e.scrim,ref:a},M.value),null),h(ii,{appear:!0,persisted:!0,transition:e.transition,target:T.value,onAfterEnter:pe,onAfterLeave:ue},{default:()=>{var J;return[en(h("div",me({ref:l,class:["v-overlay__content",e.contentClass],style:[A.value,H.value]},I.value,e.contentProps),[(J=n.default)==null?void 0:J.call(n,{isActive:d})]),[[qo,d.value],[mr("click-outside"),{handler:j,closeConditional:B,include:()=>[P.value]}]])]}})])]})])}),{activatorEl:P,scrimEl:a,target:T,animateClick:K,contentEl:l,globalTop:b,localTop:w,updateLocation:G}}}),sg=Symbol("Forwarded refs");function ig(e,t){let n=e;for(;n;){const r=Reflect.getOwnPropertyDescriptor(n,t);if(r)return r;n=Object.getPrototypeOf(n)}}function Wi(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return e[sg]=n,new Proxy(e,{get(s,i){if(Reflect.has(s,i))return Reflect.get(s,i);if(!(typeof i=="symbol"||i.startsWith("$")||i.startsWith("__"))){for(const o of n)if(o.value&&Reflect.has(o.value,i)){const a=Reflect.get(o.value,i);return typeof a=="function"?a.bind(o.value):a}}},has(s,i){if(Reflect.has(s,i))return!0;if(typeof i=="symbol"||i.startsWith("$")||i.startsWith("__"))return!1;for(const o of n)if(o.value&&Reflect.has(o.value,i))return!0;return!1},set(s,i,o){if(Reflect.has(s,i))return Reflect.set(s,i,o);if(typeof i=="symbol"||i.startsWith("$")||i.startsWith("__"))return!1;for(const a of n)if(a.value&&Reflect.has(a.value,i))return Reflect.set(a.value,i,o);return!1},getOwnPropertyDescriptor(s,i){var a;const o=Reflect.getOwnPropertyDescriptor(s,i);if(o)return o;if(!(typeof i=="symbol"||i.startsWith("$")||i.startsWith("__"))){for(const l of n){if(!l.value)continue;const u=ig(l.value,i)??("_"in l.value?ig((a=l.value._)==null?void 0:a.setupState,i):void 0);if(u)return u}for(const l of n){const u=l.value&&l.value[sg];if(!u)continue;const d=u.slice();for(;d.length;){const c=d.shift(),f=ig(c.value,i);if(f)return f;const p=c.value&&c.value[sg];p&&d.push(...p)}}}}})}const QN=de({fullscreen:Boolean,retainFocus:{type:Boolean,default:!0},scrollable:Boolean,...Od({origin:"center center",scrollStrategy:"block",transition:{component:$b},zIndex:2400})},"VDialog"),oT=xe()({name:"VDialog",props:QN(),emits:{"update:modelValue":e=>!0,afterEnter:()=>!0,afterLeave:()=>!0},setup(e,t){let{emit:n,slots:r}=t;const s=st(e,"modelValue"),{scopeId:i}=Au(),o=U();function a(d){var p,g;const c=d.relatedTarget,f=d.target;if(c!==f&&((p=o.value)!=null&&p.contentEl)&&((g=o.value)!=null&&g.globalTop)&&![document,o.value.contentEl].includes(f)&&!o.value.contentEl.contains(f)){const m=Hc(o.value.contentEl);if(!m.length)return;const y=m[0],b=m[m.length-1];c===y?b.focus():y.focus()}}Tn(()=>{document.removeEventListener("focusin",a)}),kt&&Ce(()=>s.value&&e.retainFocus,d=>{d?document.addEventListener("focusin",a):document.removeEventListener("focusin",a)},{immediate:!0});function l(){var d;n("afterEnter"),(d=o.value)!=null&&d.contentEl&&!o.value.contentEl.contains(document.activeElement)&&o.value.contentEl.focus({preventScroll:!0})}function u(){n("afterLeave")}return Ce(s,async d=>{var c;d||(await Ot(),(c=o.value.activatorEl)==null||c.focus({preventScroll:!0}))}),Ie(()=>{const d=Ni.filterProps(e),c=me({"aria-haspopup":"dialog"},e.activatorProps),f=me({tabindex:-1},e.contentProps);return h(Ni,me({ref:o,class:["v-dialog",{"v-dialog--fullscreen":e.fullscreen,"v-dialog--scrollable":e.scrollable},e.class],style:e.style},d,{modelValue:s.value,"onUpdate:modelValue":p=>s.value=p,"aria-modal":"true",activatorProps:c,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:l,onAfterLeave:u},i),{activator:r.activator,default:function(){for(var p=arguments.length,g=new Array(p),m=0;m<p;m++)g[m]=arguments[m];return h(At,{root:"VDialog"},{default:()=>{var y;return[(y=r.default)==null?void 0:y.call(r,...g)]}})}})}),Wi({},o)}}),JN={class:"pa-3 text--primary"},gi=Le({__name:"BaseDialog",props:{id:{type:String,required:!0},maxWidth:{type:String,default:"400px"}},emits:["escape","opened","beforeOpened"],setup(e,{emit:t}){const n=e,r=ku(),s=t,i=Fn(n.id);function o(d){return s("opened",d)}function a(d){return s("beforeOpened",d)}St(async()=>{J$("Escape",d=>{l.value&&(d.preventDefault(),u())}),r.registerDialogReference(n.id,{beforeOpenedCallback:a,openedCallback:o})}),Tn(()=>{r.unregisterDialogReference(n.id)});const l=R(()=>{if(!n.id)return;const d=r.isDialogOpened(n.id);return d&&console.debug(`[BaseDialog ${n.id}] Showing dialog: ${i==null?void 0:i.isDialogOpened()}`),d});function u(){s("escape")}return(d,c)=>($(),Q(oT,{"max-width":e.maxWidth,"retain-focus":!1,"model-value":l.value,persistent:"",onClose:c[1]||(c[1]=f=>u())},{default:v(()=>[Mp(d.$slots,"default",{},()=>[L("div",JN,[c[4]||(c[4]=_(" No content defined in dialog. ")),h(re,{onClick:c[0]||(c[0]=f=>ie(i).closeDialog())},{default:v(()=>[h(X,{class:"mr-3"},{default:v(()=>c[2]||(c[2]=[_("close")])),_:1}),c[3]||(c[3]=_("Close "))]),_:1})])])]),_:3},8,["max-width","model-value"]))}});var Jt=(e=>(e.BatchJsonCreate="BatchJsonCreate",e.BatchReprintDialog="BatchReprintDialog",e.YamlImportExport="YamlImportExport",e.AddOrUpdatePrinterDialog="AddOrUpdatePrinterDialog",e.AddOrUpdateFloorDialog="AddOrUpdateFloorDialog",e.PrinterMaintenanceDialog="PrinterMaintenanceDialog",e.AddOrUpdateCameraDialog="AddOrUpdateCameraDialog",e.PrinterControlDialog="PrinterControlDialog",e.CreateUserDialog="CreateUserDialog",e.GridSettingsDialog="GridSettingsDialog",e))(Jt||{});function aT(e,t){return function(){return e.apply(t,arguments)}}const{toString:ZN}=Object.prototype,{getPrototypeOf:Bb}=Object,jp=(e=>t=>{const n=ZN.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),Ns=e=>(e=e.toLowerCase(),t=>jp(t)===e),qp=e=>t=>typeof t===e,{isArray:Mu}=Array,Gc=qp("undefined");function e2(e){return e!==null&&!Gc(e)&&e.constructor!==null&&!Gc(e.constructor)&&Jr(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const lT=Ns("ArrayBuffer");function t2(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&lT(e.buffer),t}const n2=qp("string"),Jr=qp("function"),uT=qp("number"),Wp=e=>e!==null&&typeof e=="object",r2=e=>e===!0||e===!1,Jf=e=>{if(jp(e)!=="object")return!1;const t=Bb(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},s2=Ns("Date"),i2=Ns("File"),o2=Ns("Blob"),a2=Ns("FileList"),l2=e=>Wp(e)&&Jr(e.pipe),u2=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||Jr(e.append)&&((t=jp(e))==="formdata"||t==="object"&&Jr(e.toString)&&e.toString()==="[object FormData]"))},c2=Ns("URLSearchParams"),[d2,f2,h2,p2]=["ReadableStream","Request","Response","Headers"].map(Ns),m2=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Md(e,t,{allOwnKeys:n=!1}={}){if(e===null||typeof e>"u")return;let r,s;if(typeof e!="object"&&(e=[e]),Mu(e))for(r=0,s=e.length;r<s;r++)t.call(null,e[r],r,e);else{const i=n?Object.getOwnPropertyNames(e):Object.keys(e),o=i.length;let a;for(r=0;r<o;r++)a=i[r],t.call(null,e[a],a,e)}}function cT(e,t){t=t.toLowerCase();const n=Object.keys(e);let r=n.length,s;for(;r-- >0;)if(s=n[r],t===s.toLowerCase())return s;return null}const ga=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,dT=e=>!Gc(e)&&e!==ga;function Rv(){const{caseless:e}=dT(this)&&this||{},t={},n=(r,s)=>{const i=e&&cT(t,s)||s;Jf(t[i])&&Jf(r)?t[i]=Rv(t[i],r):Jf(r)?t[i]=Rv({},r):Mu(r)?t[i]=r.slice():t[i]=r};for(let r=0,s=arguments.length;r<s;r++)arguments[r]&&Md(arguments[r],n);return t}const g2=(e,t,n,{allOwnKeys:r}={})=>(Md(t,(s,i)=>{n&&Jr(s)?e[i]=aT(s,n):e[i]=s},{allOwnKeys:r}),e),v2=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),y2=(e,t,n,r)=>{e.prototype=Object.create(t.prototype,r),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),n&&Object.assign(e.prototype,n)},b2=(e,t,n,r)=>{let s,i,o;const a={};if(t=t||{},e==null)return t;do{for(s=Object.getOwnPropertyNames(e),i=s.length;i-- >0;)o=s[i],(!r||r(o,e,t))&&!a[o]&&(t[o]=e[o],a[o]=!0);e=n!==!1&&Bb(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},w2=(e,t,n)=>{e=String(e),(n===void 0||n>e.length)&&(n=e.length),n-=t.length;const r=e.indexOf(t,n);return r!==-1&&r===n},S2=e=>{if(!e)return null;if(Mu(e))return e;let t=e.length;if(!uT(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},_2=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&Bb(Uint8Array)),k2=(e,t)=>{const r=(e&&e[Symbol.iterator]).call(e);let s;for(;(s=r.next())&&!s.done;){const i=s.value;t.call(e,i[0],i[1])}},x2=(e,t)=>{let n;const r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},E2=Ns("HTMLFormElement"),C2=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,s){return r.toUpperCase()+s}),a0=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),P2=Ns("RegExp"),fT=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};Md(n,(s,i)=>{let o;(o=t(s,i,e))!==!1&&(r[i]=o||s)}),Object.defineProperties(e,r)},T2=e=>{fT(e,(t,n)=>{if(Jr(e)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const r=e[n];if(Jr(r)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},R2=(e,t)=>{const n={},r=s=>{s.forEach(i=>{n[i]=!0})};return Mu(e)?r(e):r(String(e).split(t)),n},I2=()=>{},A2=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t,og="abcdefghijklmnopqrstuvwxyz",l0="0123456789",hT={DIGIT:l0,ALPHA:og,ALPHA_DIGIT:og+og.toUpperCase()+l0},O2=(e=16,t=hT.ALPHA_DIGIT)=>{let n="";const{length:r}=t;for(;e--;)n+=t[Math.random()*r|0];return n};function M2(e){return!!(e&&Jr(e.append)&&e[Symbol.toStringTag]==="FormData"&&e[Symbol.iterator])}const D2=e=>{const t=new Array(10),n=(r,s)=>{if(Wp(r)){if(t.indexOf(r)>=0)return;if(!("toJSON"in r)){t[s]=r;const i=Mu(r)?[]:{};return Md(r,(o,a)=>{const l=n(o,s+1);!Gc(l)&&(i[a]=l)}),t[s]=void 0,i}}return r};return n(e,0)},L2=Ns("AsyncFunction"),$2=e=>e&&(Wp(e)||Jr(e))&&Jr(e.then)&&Jr(e.catch),pT=((e,t)=>e?setImmediate:t?((n,r)=>(ga.addEventListener("message",({source:s,data:i})=>{s===ga&&i===n&&r.length&&r.shift()()},!1),s=>{r.push(s),ga.postMessage(n,"*")}))(`axios@${Math.random()}`,[]):n=>setTimeout(n))(typeof setImmediate=="function",Jr(ga.postMessage)),F2=typeof queueMicrotask<"u"?queueMicrotask.bind(ga):typeof process<"u"&&process.nextTick||pT,ce={isArray:Mu,isArrayBuffer:lT,isBuffer:e2,isFormData:u2,isArrayBufferView:t2,isString:n2,isNumber:uT,isBoolean:r2,isObject:Wp,isPlainObject:Jf,isReadableStream:d2,isRequest:f2,isResponse:h2,isHeaders:p2,isUndefined:Gc,isDate:s2,isFile:i2,isBlob:o2,isRegExp:P2,isFunction:Jr,isStream:l2,isURLSearchParams:c2,isTypedArray:_2,isFileList:a2,forEach:Md,merge:Rv,extend:g2,trim:m2,stripBOM:v2,inherits:y2,toFlatObject:b2,kindOf:jp,kindOfTest:Ns,endsWith:w2,toArray:S2,forEachEntry:k2,matchAll:x2,isHTMLForm:E2,hasOwnProperty:a0,hasOwnProp:a0,reduceDescriptors:fT,freezeMethods:T2,toObjectSet:R2,toCamelCase:C2,noop:I2,toFiniteNumber:A2,findKey:cT,global:ga,isContextDefined:dT,ALPHABET:hT,generateString:O2,isSpecCompliantForm:M2,toJSONObject:D2,isAsyncFn:L2,isThenable:$2,setImmediate:pT,asap:F2};function et(e,t,n,r,s){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=e,this.name="AxiosError",t&&(this.code=t),n&&(this.config=n),r&&(this.request=r),s&&(this.response=s,this.status=s.status?s.status:null)}ce.inherits(et,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:ce.toJSONObject(this.config),code:this.code,status:this.status}}});const mT=et.prototype,gT={};["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"].forEach(e=>{gT[e]={value:e}});Object.defineProperties(et,gT);Object.defineProperty(mT,"isAxiosError",{value:!0});et.from=(e,t,n,r,s,i)=>{const o=Object.create(mT);return ce.toFlatObject(e,o,function(l){return l!==Error.prototype},a=>a!=="isAxiosError"),et.call(o,e.message,t,n,r,s),o.cause=e,o.name=e.name,i&&Object.assign(o,i),o};const N2=null;function Iv(e){return ce.isPlainObject(e)||ce.isArray(e)}function vT(e){return ce.endsWith(e,"[]")?e.slice(0,-2):e}function u0(e,t,n){return e?e.concat(t).map(function(s,i){return s=vT(s),!n&&i?"["+s+"]":s}).join(n?".":""):t}function B2(e){return ce.isArray(e)&&!e.some(Iv)}const V2=ce.toFlatObject(ce,{},null,function(t){return/^is[A-Z]/.test(t)});function Gp(e,t,n){if(!ce.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=ce.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(m,y){return!ce.isUndefined(y[m])});const r=n.metaTokens,s=n.visitor||d,i=n.dots,o=n.indexes,l=(n.Blob||typeof Blob<"u"&&Blob)&&ce.isSpecCompliantForm(t);if(!ce.isFunction(s))throw new TypeError("visitor must be a function");function u(g){if(g===null)return"";if(ce.isDate(g))return g.toISOString();if(!l&&ce.isBlob(g))throw new et("Blob is not supported. Use a Buffer instead.");return ce.isArrayBuffer(g)||ce.isTypedArray(g)?l&&typeof Blob=="function"?new Blob([g]):Buffer.from(g):g}function d(g,m,y){let b=g;if(g&&!y&&typeof g=="object"){if(ce.endsWith(m,"{}"))m=r?m:m.slice(0,-2),g=JSON.stringify(g);else if(ce.isArray(g)&&B2(g)||(ce.isFileList(g)||ce.endsWith(m,"[]"))&&(b=ce.toArray(g)))return m=vT(m),b.forEach(function(S,P){!(ce.isUndefined(S)||S===null)&&t.append(o===!0?u0([m],P,i):o===null?m:m+"[]",u(S))}),!1}return Iv(g)?!0:(t.append(u0(y,m,i),u(g)),!1)}const c=[],f=Object.assign(V2,{defaultVisitor:d,convertValue:u,isVisitable:Iv});function p(g,m){if(!ce.isUndefined(g)){if(c.indexOf(g)!==-1)throw Error("Circular reference detected in "+m.join("."));c.push(g),ce.forEach(g,function(b,w){(!(ce.isUndefined(b)||b===null)&&s.call(t,b,ce.isString(w)?w.trim():w,m,f))===!0&&p(b,m?m.concat(w):[w])}),c.pop()}}if(!ce.isObject(e))throw new TypeError("data must be an object");return p(e),t}function c0(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(r){return t[r]})}function Vb(e,t){this._pairs=[],e&&Gp(e,this,t)}const yT=Vb.prototype;yT.append=function(t,n){this._pairs.push([t,n])};yT.toString=function(t){const n=t?function(r){return t.call(this,r,c0)}:c0;return this._pairs.map(function(s){return n(s[0])+"="+n(s[1])},"").join("&")};function U2(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function bT(e,t,n){if(!t)return e;const r=n&&n.encode||U2,s=n&&n.serialize;let i;if(s?i=s(t,n):i=ce.isURLSearchParams(t)?t.toString():new Vb(t,n).toString(r),i){const o=e.indexOf("#");o!==-1&&(e=e.slice(0,o)),e+=(e.indexOf("?")===-1?"?":"&")+i}return e}class d0{constructor(){this.handlers=[]}use(t,n,r){return this.handlers.push({fulfilled:t,rejected:n,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){ce.forEach(this.handlers,function(r){r!==null&&t(r)})}}const wT={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},H2=typeof URLSearchParams<"u"?URLSearchParams:Vb,z2=typeof FormData<"u"?FormData:null,j2=typeof Blob<"u"?Blob:null,q2={isBrowser:!0,classes:{URLSearchParams:H2,FormData:z2,Blob:j2},protocols:["http","https","file","blob","url","data"]},Ub=typeof window<"u"&&typeof document<"u",Av=typeof navigator=="object"&&navigator||void 0,W2=Ub&&(!Av||["ReactNative","NativeScript","NS"].indexOf(Av.product)<0),G2=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",K2=Ub&&window.location.href||"http://localhost",Y2=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:Ub,hasStandardBrowserEnv:W2,hasStandardBrowserWebWorkerEnv:G2,navigator:Av,origin:K2},Symbol.toStringTag,{value:"Module"})),Ir={...Y2,...q2};function X2(e,t){return Gp(e,new Ir.classes.URLSearchParams,Object.assign({visitor:function(n,r,s,i){return Ir.isNode&&ce.isBuffer(n)?(this.append(r,n.toString("base64")),!1):i.defaultVisitor.apply(this,arguments)}},t))}function Q2(e){return ce.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function J2(e){const t={},n=Object.keys(e);let r;const s=n.length;let i;for(r=0;r<s;r++)i=n[r],t[i]=e[i];return t}function ST(e){function t(n,r,s,i){let o=n[i++];if(o==="__proto__")return!0;const a=Number.isFinite(+o),l=i>=n.length;return o=!o&&ce.isArray(s)?s.length:o,l?(ce.hasOwnProp(s,o)?s[o]=[s[o],r]:s[o]=r,!a):((!s[o]||!ce.isObject(s[o]))&&(s[o]=[]),t(n,r,s[o],i)&&ce.isArray(s[o])&&(s[o]=J2(s[o])),!a)}if(ce.isFormData(e)&&ce.isFunction(e.entries)){const n={};return ce.forEachEntry(e,(r,s)=>{t(Q2(r),s,n,0)}),n}return null}function Z2(e,t,n){if(ce.isString(e))try{return(t||JSON.parse)(e),ce.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(n||JSON.stringify)(e)}const Dd={transitional:wT,adapter:["xhr","http","fetch"],transformRequest:[function(t,n){const r=n.getContentType()||"",s=r.indexOf("application/json")>-1,i=ce.isObject(t);if(i&&ce.isHTMLForm(t)&&(t=new FormData(t)),ce.isFormData(t))return s?JSON.stringify(ST(t)):t;if(ce.isArrayBuffer(t)||ce.isBuffer(t)||ce.isStream(t)||ce.isFile(t)||ce.isBlob(t)||ce.isReadableStream(t))return t;if(ce.isArrayBufferView(t))return t.buffer;if(ce.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let a;if(i){if(r.indexOf("application/x-www-form-urlencoded")>-1)return X2(t,this.formSerializer).toString();if((a=ce.isFileList(t))||r.indexOf("multipart/form-data")>-1){const l=this.env&&this.env.FormData;return Gp(a?{"files[]":t}:t,l&&new l,this.formSerializer)}}return i||s?(n.setContentType("application/json",!1),Z2(t)):t}],transformResponse:[function(t){const n=this.transitional||Dd.transitional,r=n&&n.forcedJSONParsing,s=this.responseType==="json";if(ce.isResponse(t)||ce.isReadableStream(t))return t;if(t&&ce.isString(t)&&(r&&!this.responseType||s)){const o=!(n&&n.silentJSONParsing)&&s;try{return JSON.parse(t)}catch(a){if(o)throw a.name==="SyntaxError"?et.from(a,et.ERR_BAD_RESPONSE,this,null,this.response):a}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Ir.classes.FormData,Blob:Ir.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};ce.forEach(["delete","get","head","post","put","patch"],e=>{Dd.headers[e]={}});const eB=ce.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"]),tB=e=>{const t={};let n,r,s;return e&&e.split(`
26
+ `).forEach(function(o){s=o.indexOf(":"),n=o.substring(0,s).trim().toLowerCase(),r=o.substring(s+1).trim(),!(!n||t[n]&&eB[n])&&(n==="set-cookie"?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)}),t},f0=Symbol("internals");function Ju(e){return e&&String(e).trim().toLowerCase()}function Zf(e){return e===!1||e==null?e:ce.isArray(e)?e.map(Zf):String(e)}function nB(e){const t=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=n.exec(e);)t[r[1]]=r[2];return t}const rB=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function ag(e,t,n,r,s){if(ce.isFunction(r))return r.call(this,t,n);if(s&&(t=n),!!ce.isString(t)){if(ce.isString(r))return t.indexOf(r)!==-1;if(ce.isRegExp(r))return r.test(t)}}function sB(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,n,r)=>n.toUpperCase()+r)}function iB(e,t){const n=ce.toCamelCase(" "+t);["get","set","has"].forEach(r=>{Object.defineProperty(e,r+n,{value:function(s,i,o){return this[r].call(this,t,s,i,o)},configurable:!0})})}let Ar=class{constructor(t){t&&this.set(t)}set(t,n,r){const s=this;function i(a,l,u){const d=Ju(l);if(!d)throw new Error("header name must be a non-empty string");const c=ce.findKey(s,d);(!c||s[c]===void 0||u===!0||u===void 0&&s[c]!==!1)&&(s[c||l]=Zf(a))}const o=(a,l)=>ce.forEach(a,(u,d)=>i(u,d,l));if(ce.isPlainObject(t)||t instanceof this.constructor)o(t,n);else if(ce.isString(t)&&(t=t.trim())&&!rB(t))o(tB(t),n);else if(ce.isHeaders(t))for(const[a,l]of t.entries())i(l,a,r);else t!=null&&i(n,t,r);return this}get(t,n){if(t=Ju(t),t){const r=ce.findKey(this,t);if(r){const s=this[r];if(!n)return s;if(n===!0)return nB(s);if(ce.isFunction(n))return n.call(this,s,r);if(ce.isRegExp(n))return n.exec(s);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,n){if(t=Ju(t),t){const r=ce.findKey(this,t);return!!(r&&this[r]!==void 0&&(!n||ag(this,this[r],r,n)))}return!1}delete(t,n){const r=this;let s=!1;function i(o){if(o=Ju(o),o){const a=ce.findKey(r,o);a&&(!n||ag(r,r[a],a,n))&&(delete r[a],s=!0)}}return ce.isArray(t)?t.forEach(i):i(t),s}clear(t){const n=Object.keys(this);let r=n.length,s=!1;for(;r--;){const i=n[r];(!t||ag(this,this[i],i,t,!0))&&(delete this[i],s=!0)}return s}normalize(t){const n=this,r={};return ce.forEach(this,(s,i)=>{const o=ce.findKey(r,i);if(o){n[o]=Zf(s),delete n[i];return}const a=t?sB(i):String(i).trim();a!==i&&delete n[i],n[a]=Zf(s),r[a]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const n=Object.create(null);return ce.forEach(this,(r,s)=>{r!=null&&r!==!1&&(n[s]=t&&ce.isArray(r)?r.join(", "):r)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,n])=>t+": "+n).join(`
27
+ `)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...n){const r=new this(t);return n.forEach(s=>r.set(s)),r}static accessor(t){const r=(this[f0]=this[f0]={accessors:{}}).accessors,s=this.prototype;function i(o){const a=Ju(o);r[a]||(iB(s,o),r[a]=!0)}return ce.isArray(t)?t.forEach(i):i(t),this}};Ar.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);ce.reduceDescriptors(Ar.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(r){this[n]=r}}});ce.freezeMethods(Ar);function lg(e,t){const n=this||Dd,r=t||n,s=Ar.from(r.headers);let i=r.data;return ce.forEach(e,function(a){i=a.call(n,i,s.normalize(),t?t.status:void 0)}),s.normalize(),i}function _T(e){return!!(e&&e.__CANCEL__)}function Du(e,t,n){et.call(this,e??"canceled",et.ERR_CANCELED,t,n),this.name="CanceledError"}ce.inherits(Du,et,{__CANCEL__:!0});function kT(e,t,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new et("Request failed with status code "+n.status,[et.ERR_BAD_REQUEST,et.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}function oB(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function aB(e,t){e=e||10;const n=new Array(e),r=new Array(e);let s=0,i=0,o;return t=t!==void 0?t:1e3,function(l){const u=Date.now(),d=r[i];o||(o=u),n[s]=l,r[s]=u;let c=i,f=0;for(;c!==s;)f+=n[c++],c=c%e;if(s=(s+1)%e,s===i&&(i=(i+1)%e),u-o<t)return;const p=d&&u-d;return p?Math.round(f*1e3/p):void 0}}function lB(e,t){let n=0,r=1e3/t,s,i;const o=(u,d=Date.now())=>{n=d,s=null,i&&(clearTimeout(i),i=null),e.apply(null,u)};return[(...u)=>{const d=Date.now(),c=d-n;c>=r?o(u,d):(s=u,i||(i=setTimeout(()=>{i=null,o(s)},r-c)))},()=>s&&o(s)]}const Fh=(e,t,n=3)=>{let r=0;const s=aB(50,250);return lB(i=>{const o=i.loaded,a=i.lengthComputable?i.total:void 0,l=o-r,u=s(l),d=o<=a;r=o;const c={loaded:o,total:a,progress:a?o/a:void 0,bytes:l,rate:u||void 0,estimated:u&&a&&d?(a-o)/u:void 0,event:i,lengthComputable:a!=null,[t?"download":"upload"]:!0};e(c)},n)},h0=(e,t)=>{const n=e!=null;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},p0=e=>(...t)=>ce.asap(()=>e(...t)),uB=Ir.hasStandardBrowserEnv?function(){const t=Ir.navigator&&/(msie|trident)/i.test(Ir.navigator.userAgent),n=document.createElement("a");let r;function s(i){let o=i;return t&&(n.setAttribute("href",o),o=n.href),n.setAttribute("href",o),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:n.pathname.charAt(0)==="/"?n.pathname:"/"+n.pathname}}return r=s(window.location.href),function(o){const a=ce.isString(o)?s(o):o;return a.protocol===r.protocol&&a.host===r.host}}():function(){return function(){return!0}}(),cB=Ir.hasStandardBrowserEnv?{write(e,t,n,r,s,i){const o=[e+"="+encodeURIComponent(t)];ce.isNumber(n)&&o.push("expires="+new Date(n).toGMTString()),ce.isString(r)&&o.push("path="+r),ce.isString(s)&&o.push("domain="+s),i===!0&&o.push("secure"),document.cookie=o.join("; ")},read(e){const t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove(e){this.write(e,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function dB(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function fB(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function xT(e,t){return e&&!dB(t)?fB(e,t):t}const m0=e=>e instanceof Ar?{...e}:e;function Ha(e,t){t=t||{};const n={};function r(u,d,c){return ce.isPlainObject(u)&&ce.isPlainObject(d)?ce.merge.call({caseless:c},u,d):ce.isPlainObject(d)?ce.merge({},d):ce.isArray(d)?d.slice():d}function s(u,d,c){if(ce.isUndefined(d)){if(!ce.isUndefined(u))return r(void 0,u,c)}else return r(u,d,c)}function i(u,d){if(!ce.isUndefined(d))return r(void 0,d)}function o(u,d){if(ce.isUndefined(d)){if(!ce.isUndefined(u))return r(void 0,u)}else return r(void 0,d)}function a(u,d,c){if(c in t)return r(u,d);if(c in e)return r(void 0,u)}const l={url:i,method:i,data:i,baseURL:o,transformRequest:o,transformResponse:o,paramsSerializer:o,timeout:o,timeoutMessage:o,withCredentials:o,withXSRFToken:o,adapter:o,responseType:o,xsrfCookieName:o,xsrfHeaderName:o,onUploadProgress:o,onDownloadProgress:o,decompress:o,maxContentLength:o,maxBodyLength:o,beforeRedirect:o,transport:o,httpAgent:o,httpsAgent:o,cancelToken:o,socketPath:o,responseEncoding:o,validateStatus:a,headers:(u,d)=>s(m0(u),m0(d),!0)};return ce.forEach(Object.keys(Object.assign({},e,t)),function(d){const c=l[d]||s,f=c(e[d],t[d],d);ce.isUndefined(f)&&c!==a||(n[d]=f)}),n}const ET=e=>{const t=Ha({},e);let{data:n,withXSRFToken:r,xsrfHeaderName:s,xsrfCookieName:i,headers:o,auth:a}=t;t.headers=o=Ar.from(o),t.url=bT(xT(t.baseURL,t.url),e.params,e.paramsSerializer),a&&o.set("Authorization","Basic "+btoa((a.username||"")+":"+(a.password?unescape(encodeURIComponent(a.password)):"")));let l;if(ce.isFormData(n)){if(Ir.hasStandardBrowserEnv||Ir.hasStandardBrowserWebWorkerEnv)o.setContentType(void 0);else if((l=o.getContentType())!==!1){const[u,...d]=l?l.split(";").map(c=>c.trim()).filter(Boolean):[];o.setContentType([u||"multipart/form-data",...d].join("; "))}}if(Ir.hasStandardBrowserEnv&&(r&&ce.isFunction(r)&&(r=r(t)),r||r!==!1&&uB(t.url))){const u=s&&i&&cB.read(i);u&&o.set(s,u)}return t},hB=typeof XMLHttpRequest<"u",pB=hB&&function(e){return new Promise(function(n,r){const s=ET(e);let i=s.data;const o=Ar.from(s.headers).normalize();let{responseType:a,onUploadProgress:l,onDownloadProgress:u}=s,d,c,f,p,g;function m(){p&&p(),g&&g(),s.cancelToken&&s.cancelToken.unsubscribe(d),s.signal&&s.signal.removeEventListener("abort",d)}let y=new XMLHttpRequest;y.open(s.method.toUpperCase(),s.url,!0),y.timeout=s.timeout;function b(){if(!y)return;const S=Ar.from("getAllResponseHeaders"in y&&y.getAllResponseHeaders()),E={data:!a||a==="text"||a==="json"?y.responseText:y.response,status:y.status,statusText:y.statusText,headers:S,config:e,request:y};kT(function(C){n(C),m()},function(C){r(C),m()},E),y=null}"onloadend"in y?y.onloadend=b:y.onreadystatechange=function(){!y||y.readyState!==4||y.status===0&&!(y.responseURL&&y.responseURL.indexOf("file:")===0)||setTimeout(b)},y.onabort=function(){y&&(r(new et("Request aborted",et.ECONNABORTED,e,y)),y=null)},y.onerror=function(){r(new et("Network Error",et.ERR_NETWORK,e,y)),y=null},y.ontimeout=function(){let P=s.timeout?"timeout of "+s.timeout+"ms exceeded":"timeout exceeded";const E=s.transitional||wT;s.timeoutErrorMessage&&(P=s.timeoutErrorMessage),r(new et(P,E.clarifyTimeoutError?et.ETIMEDOUT:et.ECONNABORTED,e,y)),y=null},i===void 0&&o.setContentType(null),"setRequestHeader"in y&&ce.forEach(o.toJSON(),function(P,E){y.setRequestHeader(E,P)}),ce.isUndefined(s.withCredentials)||(y.withCredentials=!!s.withCredentials),a&&a!=="json"&&(y.responseType=s.responseType),u&&([f,g]=Fh(u,!0),y.addEventListener("progress",f)),l&&y.upload&&([c,p]=Fh(l),y.upload.addEventListener("progress",c),y.upload.addEventListener("loadend",p)),(s.cancelToken||s.signal)&&(d=S=>{y&&(r(!S||S.type?new Du(null,e,y):S),y.abort(),y=null)},s.cancelToken&&s.cancelToken.subscribe(d),s.signal&&(s.signal.aborted?d():s.signal.addEventListener("abort",d)));const w=oB(s.url);if(w&&Ir.protocols.indexOf(w)===-1){r(new et("Unsupported protocol "+w+":",et.ERR_BAD_REQUEST,e));return}y.send(i||null)})},mB=(e,t)=>{const{length:n}=e=e?e.filter(Boolean):[];if(t||n){let r=new AbortController,s;const i=function(u){if(!s){s=!0,a();const d=u instanceof Error?u:this.reason;r.abort(d instanceof et?d:new Du(d instanceof Error?d.message:d))}};let o=t&&setTimeout(()=>{o=null,i(new et(`timeout ${t} of ms exceeded`,et.ETIMEDOUT))},t);const a=()=>{e&&(o&&clearTimeout(o),o=null,e.forEach(u=>{u.unsubscribe?u.unsubscribe(i):u.removeEventListener("abort",i)}),e=null)};e.forEach(u=>u.addEventListener("abort",i));const{signal:l}=r;return l.unsubscribe=()=>ce.asap(a),l}},gB=function*(e,t){let n=e.byteLength;if(!t||n<t){yield e;return}let r=0,s;for(;r<n;)s=r+t,yield e.slice(r,s),r=s},vB=async function*(e,t){for await(const n of yB(e))yield*gB(n,t)},yB=async function*(e){if(e[Symbol.asyncIterator]){yield*e;return}const t=e.getReader();try{for(;;){const{done:n,value:r}=await t.read();if(n)break;yield r}}finally{await t.cancel()}},g0=(e,t,n,r)=>{const s=vB(e,t);let i=0,o,a=l=>{o||(o=!0,r&&r(l))};return new ReadableStream({async pull(l){try{const{done:u,value:d}=await s.next();if(u){a(),l.close();return}let c=d.byteLength;if(n){let f=i+=c;n(f)}l.enqueue(new Uint8Array(d))}catch(u){throw a(u),u}},cancel(l){return a(l),s.return()}},{highWaterMark:2})},Kp=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",CT=Kp&&typeof ReadableStream=="function",bB=Kp&&(typeof TextEncoder=="function"?(e=>t=>e.encode(t))(new TextEncoder):async e=>new Uint8Array(await new Response(e).arrayBuffer())),PT=(e,...t)=>{try{return!!e(...t)}catch{return!1}},wB=CT&&PT(()=>{let e=!1;const t=new Request(Ir.origin,{body:new ReadableStream,method:"POST",get duplex(){return e=!0,"half"}}).headers.has("Content-Type");return e&&!t}),v0=64*1024,Ov=CT&&PT(()=>ce.isReadableStream(new Response("").body)),Nh={stream:Ov&&(e=>e.body)};Kp&&(e=>{["text","arrayBuffer","blob","formData","stream"].forEach(t=>{!Nh[t]&&(Nh[t]=ce.isFunction(e[t])?n=>n[t]():(n,r)=>{throw new et(`Response type '${t}' is not supported`,et.ERR_NOT_SUPPORT,r)})})})(new Response);const SB=async e=>{if(e==null)return 0;if(ce.isBlob(e))return e.size;if(ce.isSpecCompliantForm(e))return(await new Request(Ir.origin,{method:"POST",body:e}).arrayBuffer()).byteLength;if(ce.isArrayBufferView(e)||ce.isArrayBuffer(e))return e.byteLength;if(ce.isURLSearchParams(e)&&(e=e+""),ce.isString(e))return(await bB(e)).byteLength},_B=async(e,t)=>{const n=ce.toFiniteNumber(e.getContentLength());return n??SB(t)},kB=Kp&&(async e=>{let{url:t,method:n,data:r,signal:s,cancelToken:i,timeout:o,onDownloadProgress:a,onUploadProgress:l,responseType:u,headers:d,withCredentials:c="same-origin",fetchOptions:f}=ET(e);u=u?(u+"").toLowerCase():"text";let p=mB([s,i&&i.toAbortSignal()],o),g;const m=p&&p.unsubscribe&&(()=>{p.unsubscribe()});let y;try{if(l&&wB&&n!=="get"&&n!=="head"&&(y=await _B(d,r))!==0){let E=new Request(t,{method:"POST",body:r,duplex:"half"}),T;if(ce.isFormData(r)&&(T=E.headers.get("content-type"))&&d.setContentType(T),E.body){const[C,k]=h0(y,Fh(p0(l)));r=g0(E.body,v0,C,k)}}ce.isString(c)||(c=c?"include":"omit");const b="credentials"in Request.prototype;g=new Request(t,{...f,signal:p,method:n.toUpperCase(),headers:d.normalize().toJSON(),body:r,duplex:"half",credentials:b?c:void 0});let w=await fetch(g);const S=Ov&&(u==="stream"||u==="response");if(Ov&&(a||S&&m)){const E={};["status","statusText","headers"].forEach(x=>{E[x]=w[x]});const T=ce.toFiniteNumber(w.headers.get("content-length")),[C,k]=a&&h0(T,Fh(p0(a),!0))||[];w=new Response(g0(w.body,v0,C,()=>{k&&k(),m&&m()}),E)}u=u||"text";let P=await Nh[ce.findKey(Nh,u)||"text"](w,e);return!S&&m&&m(),await new Promise((E,T)=>{kT(E,T,{data:P,headers:Ar.from(w.headers),status:w.status,statusText:w.statusText,config:e,request:g})})}catch(b){throw m&&m(),b&&b.name==="TypeError"&&/fetch/i.test(b.message)?Object.assign(new et("Network Error",et.ERR_NETWORK,e,g),{cause:b.cause||b}):et.from(b,b&&b.code,e,g)}}),Mv={http:N2,xhr:pB,fetch:kB};ce.forEach(Mv,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const y0=e=>`- ${e}`,xB=e=>ce.isFunction(e)||e===null||e===!1,TT={getAdapter:e=>{e=ce.isArray(e)?e:[e];const{length:t}=e;let n,r;const s={};for(let i=0;i<t;i++){n=e[i];let o;if(r=n,!xB(n)&&(r=Mv[(o=String(n)).toLowerCase()],r===void 0))throw new et(`Unknown adapter '${o}'`);if(r)break;s[o||"#"+i]=r}if(!r){const i=Object.entries(s).map(([a,l])=>`adapter ${a} `+(l===!1?"is not supported by the environment":"is not available in the build"));let o=t?i.length>1?`since :
28
+ `+i.map(y0).join(`
29
+ `):" "+y0(i[0]):"as no adapter specified";throw new et("There is no suitable adapter to dispatch the request "+o,"ERR_NOT_SUPPORT")}return r},adapters:Mv};function ug(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Du(null,e)}function b0(e){return ug(e),e.headers=Ar.from(e.headers),e.data=lg.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),TT.getAdapter(e.adapter||Dd.adapter)(e).then(function(r){return ug(e),r.data=lg.call(e,e.transformResponse,r),r.headers=Ar.from(r.headers),r},function(r){return _T(r)||(ug(e),r&&r.response&&(r.response.data=lg.call(e,e.transformResponse,r.response),r.response.headers=Ar.from(r.response.headers))),Promise.reject(r)})}const RT="1.7.7",Hb={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{Hb[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});const w0={};Hb.transitional=function(t,n,r){function s(i,o){return"[Axios v"+RT+"] Transitional option '"+i+"'"+o+(r?". "+r:"")}return(i,o,a)=>{if(t===!1)throw new et(s(o," has been removed"+(n?" in "+n:"")),et.ERR_DEPRECATED);return n&&!w0[o]&&(w0[o]=!0,console.warn(s(o," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(i,o,a):!0}};function EB(e,t,n){if(typeof e!="object")throw new et("options must be an object",et.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let s=r.length;for(;s-- >0;){const i=r[s],o=t[i];if(o){const a=e[i],l=a===void 0||o(a,i,e);if(l!==!0)throw new et("option "+i+" must be "+l,et.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new et("Unknown option "+i,et.ERR_BAD_OPTION)}}const Dv={assertOptions:EB,validators:Hb},Ji=Dv.validators;let Aa=class{constructor(t){this.defaults=t,this.interceptors={request:new d0,response:new d0}}async request(t,n){try{return await this._request(t,n)}catch(r){if(r instanceof Error){let s;Error.captureStackTrace?Error.captureStackTrace(s={}):s=new Error;const i=s.stack?s.stack.replace(/^.+\n/,""):"";try{r.stack?i&&!String(r.stack).endsWith(i.replace(/^.+\n.+\n/,""))&&(r.stack+=`
30
+ `+i):r.stack=i}catch{}}throw r}}_request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=Ha(this.defaults,n);const{transitional:r,paramsSerializer:s,headers:i}=n;r!==void 0&&Dv.assertOptions(r,{silentJSONParsing:Ji.transitional(Ji.boolean),forcedJSONParsing:Ji.transitional(Ji.boolean),clarifyTimeoutError:Ji.transitional(Ji.boolean)},!1),s!=null&&(ce.isFunction(s)?n.paramsSerializer={serialize:s}:Dv.assertOptions(s,{encode:Ji.function,serialize:Ji.function},!0)),n.method=(n.method||this.defaults.method||"get").toLowerCase();let o=i&&ce.merge(i.common,i[n.method]);i&&ce.forEach(["delete","get","head","post","put","patch","common"],g=>{delete i[g]}),n.headers=Ar.concat(o,i);const a=[];let l=!0;this.interceptors.request.forEach(function(m){typeof m.runWhen=="function"&&m.runWhen(n)===!1||(l=l&&m.synchronous,a.unshift(m.fulfilled,m.rejected))});const u=[];this.interceptors.response.forEach(function(m){u.push(m.fulfilled,m.rejected)});let d,c=0,f;if(!l){const g=[b0.bind(this),void 0];for(g.unshift.apply(g,a),g.push.apply(g,u),f=g.length,d=Promise.resolve(n);c<f;)d=d.then(g[c++],g[c++]);return d}f=a.length;let p=n;for(c=0;c<f;){const g=a[c++],m=a[c++];try{p=g(p)}catch(y){m.call(this,y);break}}try{d=b0.call(this,p)}catch(g){return Promise.reject(g)}for(c=0,f=u.length;c<f;)d=d.then(u[c++],u[c++]);return d}getUri(t){t=Ha(this.defaults,t);const n=xT(t.baseURL,t.url);return bT(n,t.params,t.paramsSerializer)}};ce.forEach(["delete","get","head","options"],function(t){Aa.prototype[t]=function(n,r){return this.request(Ha(r||{},{method:t,url:n,data:(r||{}).data}))}});ce.forEach(["post","put","patch"],function(t){function n(r){return function(i,o,a){return this.request(Ha(a||{},{method:t,headers:r?{"Content-Type":"multipart/form-data"}:{},url:i,data:o}))}}Aa.prototype[t]=n(),Aa.prototype[t+"Form"]=n(!0)});let CB=class IT{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let n;this.promise=new Promise(function(i){n=i});const r=this;this.promise.then(s=>{if(!r._listeners)return;let i=r._listeners.length;for(;i-- >0;)r._listeners[i](s);r._listeners=null}),this.promise.then=s=>{let i;const o=new Promise(a=>{r.subscribe(a),i=a}).then(s);return o.cancel=function(){r.unsubscribe(i)},o},t(function(i,o,a){r.reason||(r.reason=new Du(i,o,a),n(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}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=r=>{t.abort(r)};return this.subscribe(n),t.signal.unsubscribe=()=>this.unsubscribe(n),t.signal}static source(){let t;return{token:new IT(function(s){t=s}),cancel:t}}};function PB(e){return function(n){return e.apply(null,n)}}function TB(e){return ce.isObject(e)&&e.isAxiosError===!0}const Lv={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(Lv).forEach(([e,t])=>{Lv[t]=e});function AT(e){const t=new Aa(e),n=aT(Aa.prototype.request,t);return ce.extend(n,Aa.prototype,t,{allOwnKeys:!0}),ce.extend(n,t,null,{allOwnKeys:!0}),n.create=function(s){return AT(Ha(e,s))},n}const hn=AT(Dd);hn.Axios=Aa;hn.CanceledError=Du;hn.CancelToken=CB;hn.isCancel=_T;hn.VERSION=RT;hn.toFormData=Gp;hn.AxiosError=et;hn.Cancel=hn.CanceledError;hn.all=function(t){return Promise.all(t)};hn.spread=PB;hn.isAxiosError=TB;hn.mergeConfig=Ha;hn.AxiosHeaders=Ar;hn.formToJSON=e=>ST(ce.isHTMLForm(e)?new FormData(e):e);hn.getAdapter=TT.getAdapter;hn.HttpStatusCode=Lv;hn.default=hn;const{Axios:toe,AxiosError:OT,CanceledError:noe,isCancel:roe,CancelToken:soe,VERSION:ioe,all:ooe,Cancel:aoe,isAxiosError:loe,spread:uoe,toFormData:coe,AxiosHeaders:doe,HttpStatusCode:va,formToJSON:foe,getAdapter:hoe,mergeConfig:poe}=hn;class cc extends Error{}cc.prototype.name="InvalidTokenError";function RB(e){return decodeURIComponent(atob(e).replace(/(.)/g,(t,n)=>{let r=n.charCodeAt(0).toString(16).toUpperCase();return r.length<2&&(r="0"+r),"%"+r}))}function IB(e){let t=e.replace(/-/g,"+").replace(/_/g,"/");switch(t.length%4){case 0:break;case 2:t+="==";break;case 3:t+="=";break;default:throw new Error("base64 string is not of the correct length")}try{return RB(t)}catch{return atob(t)}}function AB(e,t){if(typeof e!="string")throw new cc("Invalid token specified: must be a string");t||(t={});const n=t.header===!0?0:1,r=e.split(".")[n];if(typeof r!="string")throw new cc(`Invalid token specified: missing part #${n+1}`);let s;try{s=IB(r)}catch(i){throw new cc(`Invalid token specified: invalid base64 for part #${n+1} (${i.message})`)}try{return JSON.parse(s)}catch(i){throw new cc(`Invalid token specified: invalid json for part #${n+1} (${i.message})`)}}function OB(e,t={}){const{onError:n,fallbackValue:r=null}=t,s=(a,l)=>{try{return AB(a,l)}catch(u){return n==null||n(u),r}},i=R(()=>s(ou(e),{header:!0})),o=R(()=>s(ou(e)));return{header:i,payload:o}}class fa{static async getLoginRequired(){return await(await Xn(!1,!1)).get("/api/auth/login-required")}static async postLogin(t,n){return await(await Xn(!1,!1)).post("/api/auth/login",{username:t,password:n})}static async logout(){return await(await Xn(!0,!1)).post("/api/auth/logout")}static async refreshLogin(t){return await(await Xn(!1,!1)).post("/api/auth/refresh",{refreshToken:t})}static async verifyLogin(){return await(await Xn(!0,!1)).post("/api/auth/verify")}static async registerAccount(t,n){return await(await Xn(!0,!1)).post("/api/auth/register",{username:t,password:n})}}const Er={IncorrectCredentials:"IncorrectCredentials",InvalidOrExpiredRefreshToken:"InvalidOrExpiredRefreshToken",InvalidOrExpiredAuthToken:"InvalidOrExpiredAuthToken",PasswordChangeRequired:"PasswordChangeRequired",LoginRequired:"LoginRequired",AccountNotVerified:"AccountNotVerified"};function zb(e){switch(e){case Er.IncorrectCredentials:return"Incorrect credentials";case Er.InvalidOrExpiredRefreshToken:return"Invalid or expired refresh token";case Er.InvalidOrExpiredAuthToken:return"Invalid or expired auth token";case Er.PasswordChangeRequired:return"Password change required";case Er.LoginRequired:return"Login required";case Er.AccountNotVerified:return"Account not verified";default:return"Authentication error"}}const ps=Ms("auth",{state:()=>({isDemoMode:null,token:null,refreshToken:null,loginRequired:null,registration:null,wizardState:null,lastLogoutReason:null}),actions:{async checkAuthenticationRequirements(){return await fa.getLoginRequired().then(e=>(this.loginRequired=e.data.loginRequired,this.wizardState=e.data.wizardState,this.registration=e.data.registration,this.isDemoMode=e.data.isDemoMode,{loginRequired:this.loginRequired,wizardState:this.wizardState,registration:this.registration})).catch(e=>{var t;throw console.error("authRequired: failed to check login required",(t=e.response)==null?void 0:t.status),e})},async login(e,t){return this.lastLogoutReason=null,await fa.postLogin(e,t).then(n=>(this.setTokens(n.data.token,n.data.refreshToken),n.data)).catch(n=>{var r;throw console.error("login: failed to login",(r=n.response)==null?void 0:r.status),n})},async logout(e=!1,t){if(console.debug(`Logging out (calling server ${e})`),t&&(this.lastLogoutReason=t),e&&this.tokenClaims&&!this.isLoginExpired)try{await fa.logout()}catch(n){console.error("Server could not process logout, but local logout was successful",n)}this.setIdToken(void 0),this.setRefreshToken(void 0)},async verifyOrRefreshLoginOnceOrLogout(){var e,t;try{return await fa.verifyLogin(),{success:!0}}catch(n){console.error("[AuthStore.verifyOrRefreshLoginOnce]: failed to verify login",n);const r=n;if(!r.response||((e=r.response)==null?void 0:e.status)!==va.Unauthorized)throw console.error("[AuthStore.verifyOrRefreshLoginOnce]: unknown error",r.status),n;const{reasonCode:s,url:i}=this.extractSpecialReasonCode(n);if(s)return await this.logout(!1,zb(s)),console.error(`[AuthStore] 401 Unauthorized - emitting 'auth:${s}' with reason ${s}`),qr(`auth:${s}`).emit({url:i,error:r.message,reasonCode:s}),{success:!1,handled:!0};if(!this.hasRefreshToken)return{success:!1,handled:!1};try{await this.refreshLoginToken(),await fa.verifyLogin()}catch(o){const a=o;if(((t=a.response)==null?void 0:t.status)===va.Unauthorized)return await this.logout(!1),console.error("[AuthStore.verifyOrRefreshLoginOnce]: failed to refresh token",a.status),{success:!1,handled:!1};throw o}return{success:!0,handled:!1}}},extractSpecialReasonCode(e){var n,r,s;const t=(r=(n=e==null?void 0:e.response)==null?void 0:n.data)==null?void 0:r.reasonCode;return t&&console.error("[AuthStore] 401 Unauthorized - Checking received reason code",t),t&&(t===Er.AccountNotVerified||t===Er.PasswordChangeRequired)?{reasonCode:t,url:(s=e==null?void 0:e.config)==null?void 0:s.url}:{reasonCode:null,url:null}},loadTokens(){this.token=localStorage.getItem("token"),this.refreshToken=localStorage.getItem("refreshToken")},async refreshLoginToken(){if(!this.refreshToken)throw new Error("refreshLoginToken: no refresh token");return await fa.refreshLogin(this.refreshToken).then(e=>{var t;return(t=e==null?void 0:e.data)!=null&&t.token&&this.setIdToken(e.data.token),!0}).catch(e=>{var t,n,r;throw((t=e.response)==null?void 0:t.status)==va.Unauthorized?(this.setTokens(void 0,void 0),console.error("refreshLoginToken: authentication error, failed to refresh tokens",(n=e.response)==null?void 0:n.status)):console.error("refreshLoginToken: unknown error, failed to refresh tokens",(r=e.response)==null?void 0:r.status),e})},setTokens(e,t){this.setIdToken(e),this.setRefreshToken(t)},setIdToken(e){e!=null&&e.length?(localStorage.setItem("token",e),this.token=e):localStorage.removeItem("token")},setRefreshToken(e){e!=null&&e.length?(localStorage.setItem("refreshToken",e),this.refreshToken=e):localStorage.removeItem("refreshToken")}},getters:{hasRefreshToken(){return!!this.refreshToken},isLoginExpired(){const e=this.tokenClaims;return e!=null&&e.exp?e.exp<Date.now()/1e3:!1},hasAuthToken(){return!!this.tokenClaims},tokenClaims(){if(!this.token)return null;const e=OB(this.token,{fallbackValue:null});return e?e.payload.value:null}}}),nt=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,Mi="8.40.0",ft=globalThis;function Yp(e,t,n){const r=ft,s=r.__SENTRY__=r.__SENTRY__||{},i=s[Mi]=s[Mi]||{};return i[e]||(i[e]=t())}const Yo=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,MB="Sentry Logger ",$v=["debug","info","warn","error","log","assert","trace"],Bh={};function Gi(e){if(!("console"in ft))return e();const t=ft.console,n={},r=Object.keys(Bh);r.forEach(s=>{const i=Bh[s];n[s]=t[s],t[s]=i});try{return e()}finally{r.forEach(s=>{t[s]=n[s]})}}function DB(){let e=!1;const t={enable:()=>{e=!0},disable:()=>{e=!1},isEnabled:()=>e};return Yo?$v.forEach(n=>{t[n]=(...r)=>{e&&Gi(()=>{ft.console[n](`${MB}[${n}]:`,...r)})}}):$v.forEach(n=>{t[n]=()=>{}}),t}const Pe=Yp("logger",DB),MT=50,za="?",S0=/\(error: (.*)\)/,_0=/captureMessage|captureException/;function DT(...e){const t=e.sort((n,r)=>n[0]-r[0]).map(n=>n[1]);return(n,r=0,s=0)=>{const i=[],o=n.split(`
31
+ `);for(let a=r;a<o.length;a++){const l=o[a];if(l.length>1024)continue;const u=S0.test(l)?l.replace(S0,"$1"):l;if(!u.match(/\S*Error: /)){for(const d of t){const c=d(u);if(c){i.push(c);break}}if(i.length>=MT+s)break}}return $B(i.slice(s))}}function LB(e){return Array.isArray(e)?DT(...e):e}function $B(e){if(!e.length)return[];const t=Array.from(e);return/sentryWrapped/.test(lf(t).function||"")&&t.pop(),t.reverse(),_0.test(lf(t).function||"")&&(t.pop(),_0.test(lf(t).function||"")&&t.pop()),t.slice(0,MT).map(n=>({...n,filename:n.filename||lf(t).filename,function:n.function||za}))}function lf(e){return e[e.length-1]||{}}const cg="<anonymous>";function Bi(e){try{return!e||typeof e!="function"?cg:e.name||cg}catch{return cg}}function k0(e){const t=e.exception;if(t){const n=[];try{return t.values.forEach(r=>{r.stacktrace.frames&&n.push(...r.stacktrace.frames)}),n}catch{return}}}const eh={},x0={};function Xo(e,t){eh[e]=eh[e]||[],eh[e].push(t)}function Qo(e,t){if(!x0[e]){x0[e]=!0;try{t()}catch(n){Yo&&Pe.error(`Error while instrumenting ${e}`,n)}}}function fs(e,t){const n=e&&eh[e];if(n)for(const r of n)try{r(t)}catch(s){Yo&&Pe.error(`Error while triggering instrumentation handler.
32
+ Type: ${e}
33
+ Name: ${Bi(r)}
34
+ Error:`,s)}}let uf=null;function LT(e){const t="error";Xo(t,e),Qo(t,FB)}function FB(){uf=ft.onerror,ft.onerror=function(e,t,n,r,s){return fs("error",{column:r,error:s,line:n,msg:e,url:t}),uf&&!uf.__SENTRY_LOADER__?uf.apply(this,arguments):!1},ft.onerror.__SENTRY_INSTRUMENTED__=!0}let cf=null;function $T(e){const t="unhandledrejection";Xo(t,e),Qo(t,NB)}function NB(){cf=ft.onunhandledrejection,ft.onunhandledrejection=function(e){return fs("unhandledrejection",e),cf&&!cf.__SENTRY_LOADER__?cf.apply(this,arguments):!0},ft.onunhandledrejection.__SENTRY_INSTRUMENTED__=!0}function Lu(){return jb(ft),ft}function jb(e){const t=e.__SENTRY__=e.__SENTRY__||{};return t.version=t.version||Mi,t[Mi]=t[Mi]||{}}const FT=Object.prototype.toString;function qb(e){switch(FT.call(e)){case"[object Error]":case"[object Exception]":case"[object DOMException]":case"[object WebAssembly.Exception]":return!0;default:return Vi(e,Error)}}function $u(e,t){return FT.call(e)===`[object ${t}]`}function NT(e){return $u(e,"ErrorEvent")}function E0(e){return $u(e,"DOMError")}function BB(e){return $u(e,"DOMException")}function Di(e){return $u(e,"String")}function Wb(e){return typeof e=="object"&&e!==null&&"__sentry_template_string__"in e&&"__sentry_template_values__"in e}function Gb(e){return e===null||Wb(e)||typeof e!="object"&&typeof e!="function"}function uu(e){return $u(e,"Object")}function Xp(e){return typeof Event<"u"&&Vi(e,Event)}function VB(e){return typeof Element<"u"&&Vi(e,Element)}function UB(e){return $u(e,"RegExp")}function Qp(e){return!!(e&&e.then&&typeof e.then=="function")}function HB(e){return uu(e)&&"nativeEvent"in e&&"preventDefault"in e&&"stopPropagation"in e}function Vi(e,t){try{return e instanceof t}catch{return!1}}function BT(e){return!!(typeof e=="object"&&e!==null&&(e.__isVue||e._isVue))}const Vl=ft,zB=80;function Ui(e,t={}){if(!e)return"<unknown>";try{let n=e;const r=5,s=[];let i=0,o=0;const a=" > ",l=a.length;let u;const d=Array.isArray(t)?t:t.keyAttrs,c=!Array.isArray(t)&&t.maxStringLength||zB;for(;n&&i++<r&&(u=jB(n,d),!(u==="html"||i>1&&o+s.length*l+u.length>=c));)s.push(u),o+=u.length,n=n.parentNode;return s.reverse().join(a)}catch{return"<unknown>"}}function jB(e,t){const n=e,r=[];if(!n||!n.tagName)return"";if(Vl.HTMLElement&&n instanceof HTMLElement&&n.dataset){if(n.dataset.sentryComponent)return n.dataset.sentryComponent;if(n.dataset.sentryElement)return n.dataset.sentryElement}r.push(n.tagName.toLowerCase());const s=t&&t.length?t.filter(o=>n.getAttribute(o)).map(o=>[o,n.getAttribute(o)]):null;if(s&&s.length)s.forEach(o=>{r.push(`[${o[0]}="${o[1]}"]`)});else{n.id&&r.push(`#${n.id}`);const o=n.className;if(o&&Di(o)){const a=o.split(/\s+/);for(const l of a)r.push(`.${l}`)}}const i=["aria-label","type","name","title","alt"];for(const o of i){const a=n.getAttribute(o);a&&r.push(`[${o}="${a}"]`)}return r.join("")}function VT(){try{return Vl.document.location.href}catch{return""}}function qB(e){return Vl.document&&Vl.document.querySelector?Vl.document.querySelector(e):null}function UT(e){if(!Vl.HTMLElement)return null;let t=e;const n=5;for(let r=0;r<n;r++){if(!t)return null;if(t instanceof HTMLElement){if(t.dataset.sentryComponent)return t.dataset.sentryComponent;if(t.dataset.sentryElement)return t.dataset.sentryElement}t=t.parentNode}return null}function Ul(e,t=0){return typeof e!="string"||t===0||e.length<=t?e:`${e.slice(0,t)}...`}function C0(e,t){if(!Array.isArray(e))return"";const n=[];for(let r=0;r<e.length;r++){const s=e[r];try{BT(s)?n.push("[VueViewModel]"):n.push(String(s))}catch{n.push("[value cannot be serialized]")}}return n.join(t)}function WB(e,t,n=!1){return Di(e)?UB(t)?t.test(e):Di(t)?n?e===t:e.includes(t):!1:!1}function Io(e,t=[],n=!1){return t.some(r=>WB(e,r,n))}function Tr(e,t,n){if(!(t in e))return;const r=e[t],s=n(r);typeof s=="function"&&HT(s,r);try{e[t]=s}catch{Yo&&Pe.log(`Failed to replace method "${t}" in object`,e)}}function ms(e,t,n){try{Object.defineProperty(e,t,{value:n,writable:!0,configurable:!0})}catch{Yo&&Pe.log(`Failed to add non-enumerable property "${t}" to object`,e)}}function HT(e,t){try{const n=t.prototype||{};e.prototype=t.prototype=n,ms(e,"__sentry_original__",t)}catch{}}function Kb(e){return e.__sentry_original__}function GB(e){return Object.keys(e).map(t=>`${encodeURIComponent(t)}=${encodeURIComponent(e[t])}`).join("&")}function zT(e){if(qb(e))return{message:e.message,name:e.name,stack:e.stack,...T0(e)};if(Xp(e)){const t={type:e.type,target:P0(e.target),currentTarget:P0(e.currentTarget),...T0(e)};return typeof CustomEvent<"u"&&Vi(e,CustomEvent)&&(t.detail=e.detail),t}else return e}function P0(e){try{return VB(e)?Ui(e):Object.prototype.toString.call(e)}catch{return"<unknown>"}}function T0(e){if(typeof e=="object"&&e!==null){const t={};for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t}else return{}}function KB(e,t=40){const n=Object.keys(zT(e));n.sort();const r=n[0];if(!r)return"[object has no keys]";if(r.length>=t)return Ul(r,t);for(let s=n.length;s>0;s--){const i=n.slice(0,s).join(", ");if(!(i.length>t))return s===n.length?i:Ul(i,t)}return""}function En(e){return Fv(e,new Map)}function Fv(e,t){if(YB(e)){const n=t.get(e);if(n!==void 0)return n;const r={};t.set(e,r);for(const s of Object.getOwnPropertyNames(e))typeof e[s]<"u"&&(r[s]=Fv(e[s],t));return r}if(Array.isArray(e)){const n=t.get(e);if(n!==void 0)return n;const r=[];return t.set(e,r),e.forEach(s=>{r.push(Fv(s,t))}),r}return e}function YB(e){if(!uu(e))return!1;try{const t=Object.getPrototypeOf(e).constructor.name;return!t||t==="Object"}catch{return!0}}const jT=1e3;function Ld(){return Date.now()/jT}function XB(){const{performance:e}=ft;if(!e||!e.now)return Ld;const t=Date.now()-e.now(),n=e.timeOrigin==null?t:e.timeOrigin;return()=>(n+e.now())/jT}const nr=XB(),gr=(()=>{const{performance:e}=ft;if(!e||!e.now)return;const t=3600*1e3,n=e.now(),r=Date.now(),s=e.timeOrigin?Math.abs(e.timeOrigin+n-r):t,i=s<t,o=e.timing&&e.timing.navigationStart,l=typeof o=="number"?Math.abs(o+n-r):t,u=l<t;return i||u?s<=l?e.timeOrigin:o:r})();function tn(){const e=ft,t=e.crypto||e.msCrypto;let n=()=>Math.random()*16;try{if(t&&t.randomUUID)return t.randomUUID().replace(/-/g,"");t&&t.getRandomValues&&(n=()=>{const r=new Uint8Array(1);return t.getRandomValues(r),r[0]})}catch{}return("10000000100040008000"+1e11).replace(/[018]/g,r=>(r^(n()&15)>>r/4).toString(16))}function qT(e){return e.exception&&e.exception.values?e.exception.values[0]:void 0}function ao(e){const{message:t,event_id:n}=e;if(t)return t;const r=qT(e);return r?r.type&&r.value?`${r.type}: ${r.value}`:r.type||r.value||n||"<unknown>":n||"<unknown>"}function Nv(e,t,n){const r=e.exception=e.exception||{},s=r.values=r.values||[],i=s[0]=s[0]||{};i.value||(i.value=t||""),i.type||(i.type="Error")}function Kc(e,t){const n=qT(e);if(!n)return;const r={type:"generic",handled:!0},s=n.mechanism;if(n.mechanism={...r,...s,...t},t&&"data"in t){const i={...s&&s.data,...t.data};n.mechanism.data=i}}function R0(e){if(e&&e.__sentry_captured__)return!0;try{ms(e,"__sentry_captured__",!0)}catch{}return!1}function QB(e){return Array.isArray(e)?e:[e]}var Pi;(function(e){e[e.PENDING=0]="PENDING";const n=1;e[e.RESOLVED=n]="RESOLVED";const r=2;e[e.REJECTED=r]="REJECTED"})(Pi||(Pi={}));function Hi(e){return new ls(t=>{t(e)})}function Vh(e){return new ls((t,n)=>{n(e)})}class ls{constructor(t){ls.prototype.__init.call(this),ls.prototype.__init2.call(this),ls.prototype.__init3.call(this),ls.prototype.__init4.call(this),this._state=Pi.PENDING,this._handlers=[];try{t(this._resolve,this._reject)}catch(n){this._reject(n)}}then(t,n){return new ls((r,s)=>{this._handlers.push([!1,i=>{if(!t)r(i);else try{r(t(i))}catch(o){s(o)}},i=>{if(!n)s(i);else try{r(n(i))}catch(o){s(o)}}]),this._executeHandlers()})}catch(t){return this.then(n=>n,t)}finally(t){return new ls((n,r)=>{let s,i;return this.then(o=>{i=!1,s=o,t&&t()},o=>{i=!0,s=o,t&&t()}).then(()=>{if(i){r(s);return}n(s)})})}__init(){this._resolve=t=>{this._setResult(Pi.RESOLVED,t)}}__init2(){this._reject=t=>{this._setResult(Pi.REJECTED,t)}}__init3(){this._setResult=(t,n)=>{if(this._state===Pi.PENDING){if(Qp(n)){n.then(this._resolve,this._reject);return}this._state=t,this._value=n,this._executeHandlers()}}}__init4(){this._executeHandlers=()=>{if(this._state===Pi.PENDING)return;const t=this._handlers.slice();this._handlers=[],t.forEach(n=>{n[0]||(this._state===Pi.RESOLVED&&n[1](this._value),this._state===Pi.REJECTED&&n[2](this._value),n[0]=!0)})}}}function JB(e){const t=nr(),n={sid:tn(),init:!0,timestamp:t,started:t,duration:0,status:"ok",errors:0,ignoreDuration:!1,toJSON:()=>eV(n)};return e&&cu(n,e),n}function cu(e,t={}){if(t.user&&(!e.ipAddress&&t.user.ip_address&&(e.ipAddress=t.user.ip_address),!e.did&&!t.did&&(e.did=t.user.id||t.user.email||t.user.username)),e.timestamp=t.timestamp||nr(),t.abnormal_mechanism&&(e.abnormal_mechanism=t.abnormal_mechanism),t.ignoreDuration&&(e.ignoreDuration=t.ignoreDuration),t.sid&&(e.sid=t.sid.length===32?t.sid:tn()),t.init!==void 0&&(e.init=t.init),!e.did&&t.did&&(e.did=`${t.did}`),typeof t.started=="number"&&(e.started=t.started),e.ignoreDuration)e.duration=void 0;else if(typeof t.duration=="number")e.duration=t.duration;else{const n=e.timestamp-e.started;e.duration=n>=0?n:0}t.release&&(e.release=t.release),t.environment&&(e.environment=t.environment),!e.ipAddress&&t.ipAddress&&(e.ipAddress=t.ipAddress),!e.userAgent&&t.userAgent&&(e.userAgent=t.userAgent),typeof t.errors=="number"&&(e.errors=t.errors),t.status&&(e.status=t.status)}function ZB(e,t){let n={};e.status==="ok"&&(n={status:"exited"}),cu(e,n)}function eV(e){return En({sid:`${e.sid}`,init:e.init,started:new Date(e.started*1e3).toISOString(),timestamp:new Date(e.timestamp*1e3).toISOString(),status:e.status,errors:e.errors,did:typeof e.did=="number"||typeof e.did=="string"?`${e.did}`:void 0,duration:e.duration,abnormal_mechanism:e.abnormal_mechanism,attrs:{release:e.release,environment:e.environment,ip_address:e.ipAddress,user_agent:e.userAgent}})}function Uh(){return{traceId:tn(),spanId:tn().substring(16)}}function Jp(e,t,n=2){if(!t||typeof t!="object"||n<=0)return t;if(e&&t&&Object.keys(t).length===0)return e;const r={...e};for(const s in t)Object.prototype.hasOwnProperty.call(t,s)&&(r[s]=Jp(r[s],t[s],n-1));return r}const Bv="_sentrySpan";function Yc(e,t){t?ms(e,Bv,t):delete e[Bv]}function Hh(e){return e[Bv]}const tV=100;class Yb{constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext=Uh()}clone(){const t=new Yb;return t._breadcrumbs=[...this._breadcrumbs],t._tags={...this._tags},t._extra={...this._extra},t._contexts={...this._contexts},t._user=this._user,t._level=this._level,t._session=this._session,t._transactionName=this._transactionName,t._fingerprint=this._fingerprint,t._eventProcessors=[...this._eventProcessors],t._requestSession=this._requestSession,t._attachments=[...this._attachments],t._sdkProcessingMetadata={...this._sdkProcessingMetadata},t._propagationContext={...this._propagationContext},t._client=this._client,t._lastEventId=this._lastEventId,Yc(t,Hh(this)),t}setClient(t){this._client=t}setLastEventId(t){this._lastEventId=t}getClient(){return this._client}lastEventId(){return this._lastEventId}addScopeListener(t){this._scopeListeners.push(t)}addEventProcessor(t){return this._eventProcessors.push(t),this}setUser(t){return this._user=t||{email:void 0,id:void 0,ip_address:void 0,username:void 0},this._session&&cu(this._session,{user:t}),this._notifyScopeListeners(),this}getUser(){return this._user}getRequestSession(){return this._requestSession}setRequestSession(t){return this._requestSession=t,this}setTags(t){return this._tags={...this._tags,...t},this._notifyScopeListeners(),this}setTag(t,n){return this._tags={...this._tags,[t]:n},this._notifyScopeListeners(),this}setExtras(t){return this._extra={...this._extra,...t},this._notifyScopeListeners(),this}setExtra(t,n){return this._extra={...this._extra,[t]:n},this._notifyScopeListeners(),this}setFingerprint(t){return this._fingerprint=t,this._notifyScopeListeners(),this}setLevel(t){return this._level=t,this._notifyScopeListeners(),this}setTransactionName(t){return this._transactionName=t,this._notifyScopeListeners(),this}setContext(t,n){return n===null?delete this._contexts[t]:this._contexts[t]=n,this._notifyScopeListeners(),this}setSession(t){return t?this._session=t:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(t){if(!t)return this;const n=typeof t=="function"?t(this):t,[r,s]=n instanceof Fo?[n.getScopeData(),n.getRequestSession()]:uu(n)?[t,t.requestSession]:[],{tags:i,extra:o,user:a,contexts:l,level:u,fingerprint:d=[],propagationContext:c}=r||{};return this._tags={...this._tags,...i},this._extra={...this._extra,...o},this._contexts={...this._contexts,...l},a&&Object.keys(a).length&&(this._user=a),u&&(this._level=u),d.length&&(this._fingerprint=d),c&&(this._propagationContext=c),s&&(this._requestSession=s),this}clear(){return this._breadcrumbs=[],this._tags={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._requestSession=void 0,this._session=void 0,Yc(this,void 0),this._attachments=[],this._propagationContext=Uh(),this._notifyScopeListeners(),this}addBreadcrumb(t,n){const r=typeof n=="number"?n:tV;if(r<=0)return this;const s={timestamp:Ld(),...t},i=this._breadcrumbs;return i.push(s),this._breadcrumbs=i.length>r?i.slice(-r):i,this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(t){return this._attachments.push(t),this}clearAttachments(){return this._attachments=[],this}getScopeData(){return{breadcrumbs:this._breadcrumbs,attachments:this._attachments,contexts:this._contexts,tags:this._tags,extra:this._extra,user:this._user,level:this._level,fingerprint:this._fingerprint||[],eventProcessors:this._eventProcessors,propagationContext:this._propagationContext,sdkProcessingMetadata:this._sdkProcessingMetadata,transactionName:this._transactionName,span:Hh(this)}}setSDKProcessingMetadata(t){return this._sdkProcessingMetadata=Jp(this._sdkProcessingMetadata,t,2),this}setPropagationContext(t){return this._propagationContext=t,this}getPropagationContext(){return this._propagationContext}captureException(t,n){const r=n&&n.event_id?n.event_id:tn();if(!this._client)return Pe.warn("No client configured on scope - will not capture exception!"),r;const s=new Error("Sentry syntheticException");return this._client.captureException(t,{originalException:t,syntheticException:s,...n,event_id:r},this),r}captureMessage(t,n,r){const s=r&&r.event_id?r.event_id:tn();if(!this._client)return Pe.warn("No client configured on scope - will not capture message!"),s;const i=new Error(t);return this._client.captureMessage(t,n,{originalException:t,syntheticException:i,...r,event_id:s},this),s}captureEvent(t,n){const r=n&&n.event_id?n.event_id:tn();return this._client?(this._client.captureEvent(t,{...n,event_id:r},this),r):(Pe.warn("No client configured on scope - will not capture event!"),r)}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach(t=>{t(this)}),this._notifyingListeners=!1)}}const Fo=Yb;function nV(){return Yp("defaultCurrentScope",()=>new Fo)}function rV(){return Yp("defaultIsolationScope",()=>new Fo)}class sV{constructor(t,n){let r;t?r=t:r=new Fo;let s;n?s=n:s=new Fo,this._stack=[{scope:r}],this._isolationScope=s}withScope(t){const n=this._pushScope();let r;try{r=t(n)}catch(s){throw this._popScope(),s}return Qp(r)?r.then(s=>(this._popScope(),s),s=>{throw this._popScope(),s}):(this._popScope(),r)}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getIsolationScope(){return this._isolationScope}getStackTop(){return this._stack[this._stack.length-1]}_pushScope(){const t=this.getScope().clone();return this._stack.push({client:this.getClient(),scope:t}),t}_popScope(){return this._stack.length<=1?!1:!!this._stack.pop()}}function du(){const e=Lu(),t=jb(e);return t.stack=t.stack||new sV(nV(),rV())}function iV(e){return du().withScope(e)}function oV(e,t){const n=du();return n.withScope(()=>(n.getStackTop().scope=e,t(e)))}function I0(e){return du().withScope(()=>e(du().getIsolationScope()))}function aV(){return{withIsolationScope:I0,withScope:iV,withSetScope:oV,withSetIsolationScope:(e,t)=>I0(t),getCurrentScope:()=>du().getScope(),getIsolationScope:()=>du().getIsolationScope()}}function $d(e){const t=jb(e);return t.acs?t.acs:aV()}function Bt(){const e=Lu();return $d(e).getCurrentScope()}function ws(){const e=Lu();return $d(e).getIsolationScope()}function lV(){return Yp("globalScope",()=>new Fo)}function Xb(...e){const t=Lu(),n=$d(t);if(e.length===2){const[r,s]=e;return r?n.withSetScope(r,s):n.withScope(s)}return n.withScope(e[0])}function dt(){return Bt().getClient()}const uV="_sentryMetrics";function Vv(e){const t=e[uV];if(!t)return;const n={};for(const[,[r,s]]of t)(n[r]||(n[r]=[])).push(En(s));return n}const Yr="sentry.source",WT="sentry.sample_rate",ja="sentry.op",ln="sentry.origin",Uv="sentry.idle_span_finish_reason",Zp="sentry.measurement_unit",em="sentry.measurement_value",cV="sentry.profile_id",Qb="sentry.exclusive_time",dV=0,GT=1,In=2;function fV(e){if(e<400&&e>=100)return{code:GT};if(e>=400&&e<500)switch(e){case 401:return{code:In,message:"unauthenticated"};case 403:return{code:In,message:"permission_denied"};case 404:return{code:In,message:"not_found"};case 409:return{code:In,message:"already_exists"};case 413:return{code:In,message:"failed_precondition"};case 429:return{code:In,message:"resource_exhausted"};case 499:return{code:In,message:"cancelled"};default:return{code:In,message:"invalid_argument"}}if(e>=500&&e<600)switch(e){case 501:return{code:In,message:"unimplemented"};case 503:return{code:In,message:"unavailable"};case 504:return{code:In,message:"deadline_exceeded"};default:return{code:In,message:"internal_error"}}return{code:In,message:"unknown_error"}}function KT(e,t){e.setAttribute("http.response.status_code",t);const n=fV(t);n.message!=="unknown_error"&&e.setStatus(n)}const kl="baggage",Jb="sentry-",hV=/^sentry-/,pV=8192;function YT(e){const t=mV(e);if(!t)return;const n=Object.entries(t).reduce((r,[s,i])=>{if(s.match(hV)){const o=s.slice(Jb.length);r[o]=i}return r},{});if(Object.keys(n).length>0)return n}function XT(e){if(!e)return;const t=Object.entries(e).reduce((n,[r,s])=>(s&&(n[`${Jb}${r}`]=s),n),{});return gV(t)}function mV(e){if(!(!e||!Di(e)&&!Array.isArray(e)))return Array.isArray(e)?e.reduce((t,n)=>{const r=A0(n);return Object.entries(r).forEach(([s,i])=>{t[s]=i}),t},{}):A0(e)}function A0(e){return e.split(",").map(t=>t.split("=").map(n=>decodeURIComponent(n.trim()))).reduce((t,[n,r])=>(n&&r&&(t[n]=r),t),{})}function gV(e){if(Object.keys(e).length!==0)return Object.entries(e).reduce((t,[n,r],s)=>{const i=`${encodeURIComponent(n)}=${encodeURIComponent(r)}`,o=s===0?i:`${t},${i}`;return o.length>pV?(Yo&&Pe.warn(`Not adding key: ${n} with val: ${r} to baggage header due to exceeding baggage size limits.`),t):o},"")}const vV=new RegExp("^[ \\t]*([0-9a-f]{32})?-?([0-9a-f]{16})?-?([01])?[ \\t]*$");function yV(e){if(!e)return;const t=e.match(vV);if(!t)return;let n;return t[3]==="1"?n=!0:t[3]==="0"&&(n=!1),{traceId:t[1],parentSampled:n,parentSpanId:t[2]}}function bV(e,t){const n=yV(e),r=YT(t),{traceId:s,parentSpanId:i,parentSampled:o}=n||{};return n?{traceId:s||tn(),parentSpanId:i||tn().substring(16),spanId:tn().substring(16),sampled:o,dsc:r||{}}:{traceId:s||tn(),spanId:tn().substring(16)}}function Zb(e=tn(),t=tn().substring(16),n){let r="";return n!==void 0&&(r=n?"-1":"-0"),`${e}-${t}${r}`}const QT=0,JT=1;function wV(e){const{spanId:t,traceId:n}=e.spanContext(),{data:r,op:s,parent_span_id:i,status:o,origin:a}=ut(e);return En({parent_span_id:i,span_id:t,trace_id:n,data:r,op:s,status:o,origin:a})}function SV(e){const{spanId:t,traceId:n}=e.spanContext(),{parent_span_id:r}=ut(e);return En({parent_span_id:r,span_id:t,trace_id:n})}function ZT(e){const{traceId:t,spanId:n}=e.spanContext(),r=rl(e);return Zb(t,n,r)}function Oa(e){return typeof e=="number"?O0(e):Array.isArray(e)?e[0]+e[1]/1e9:e instanceof Date?O0(e.getTime()):nr()}function O0(e){return e>9999999999?e/1e3:e}function ut(e){if(kV(e))return e.getSpanJSON();try{const{spanId:t,traceId:n}=e.spanContext();if(_V(e)){const{attributes:r,startTime:s,name:i,endTime:o,parentSpanId:a,status:l}=e;return En({span_id:t,trace_id:n,data:r,description:i,parent_span_id:a,start_timestamp:Oa(s),timestamp:Oa(o)||void 0,status:eR(l),op:r[ja],origin:r[ln],_metrics_summary:Vv(e)})}return{span_id:t,trace_id:n}}catch{return{}}}function _V(e){const t=e;return!!t.attributes&&!!t.startTime&&!!t.name&&!!t.endTime&&!!t.status}function kV(e){return typeof e.getSpanJSON=="function"}function rl(e){const{traceFlags:t}=e.spanContext();return t===JT}function eR(e){if(!(!e||e.code===dV))return e.code===GT?"ok":e.message||"unknown_error"}const Ma="_sentryChildSpans",Hv="_sentryRootSpan";function tR(e,t){const n=e[Hv]||e;ms(t,Hv,n),e[Ma]?e[Ma].add(t):ms(e,Ma,new Set([t]))}function xV(e,t){e[Ma]&&e[Ma].delete(t)}function th(e){const t=new Set;function n(r){if(!t.has(r)&&rl(r)){t.add(r);const s=r[Ma]?Array.from(r[Ma]):[];for(const i of s)n(i)}}return n(e),Array.from(t)}function Ln(e){return e[Hv]||e}function Rn(){const e=Lu(),t=$d(e);return t.getActiveSpan?t.getActiveSpan():Hh(Bt())}let M0=!1;function EV(){M0||(M0=!0,LT(zv),$T(zv))}function zv(){const e=Rn(),t=e&&Ln(e);if(t){const n="internal_error";nt&&Pe.log(`[Tracing] Root span: ${n} -> Global error occurred`),t.setStatus({code:In,message:n})}}zv.tag="sentry_tracingErrorCallback";const nR="_sentryScope",rR="_sentryIsolationScope";function CV(e,t,n){e&&(ms(e,rR,n),ms(e,nR,t))}function D0(e){return{scope:e[nR],isolationScope:e[rR]}}function di(e){if(typeof __SENTRY_TRACING__=="boolean"&&!__SENTRY_TRACING__)return!1;const t=dt(),n=e||t&&t.getOptions();return!!n&&(n.enableTracing||"tracesSampleRate"in n||"tracesSampler"in n)}class Fu{constructor(t={}){this._traceId=t.traceId||tn(),this._spanId=t.spanId||tn().substring(16)}spanContext(){return{spanId:this._spanId,traceId:this._traceId,traceFlags:QT}}end(t){}setAttribute(t,n){return this}setAttributes(t){return this}setStatus(t){return this}updateName(t){return this}isRecording(){return!1}addEvent(t,n,r){return this}addLink(t){return this}addLinks(t){return this}recordException(t,n){}}const ew="production",sR="_frozenDsc";function L0(e,t){ms(e,sR,t)}function tm(e,t){const n=t.getOptions(),{publicKey:r}=t.getDsn()||{},s=En({environment:n.environment||ew,release:n.release,public_key:r,trace_id:e});return t.emit("createDsc",s),s}function Jo(e){const t=dt();if(!t)return{};const n=tm(ut(e).trace_id||"",t),r=Ln(e),s=r[sR];if(s)return s;const i=r.spanContext().traceState,o=i&&i.get("sentry.dsc"),a=o&&YT(o);if(a)return a;const l=ut(r),u=l.data||{},d=u[WT];d!=null&&(n.sample_rate=`${d}`);const c=u[Yr],f=l.description;return c!=="url"&&f&&(n.transaction=f),di()&&(n.sampled=String(rl(r))),t.emit("createDsc",n,r),n}function PV(e){if(!nt)return;const{description:t="< unknown name >",op:n="< unknown op >",parent_span_id:r}=ut(e),{spanId:s}=e.spanContext(),i=rl(e),o=Ln(e),a=o===e,l=`[Tracing] Starting ${i?"sampled":"unsampled"} ${a?"root ":""}span`,u=[`op: ${n}`,`name: ${t}`,`ID: ${s}`];if(r&&u.push(`parent ID: ${r}`),!a){const{op:d,description:c}=ut(o);u.push(`root ID: ${o.spanContext().spanId}`),d&&u.push(`root op: ${d}`),c&&u.push(`root description: ${c}`)}Pe.log(`${l}
35
+ ${u.join(`
36
+ `)}`)}function TV(e){if(!nt)return;const{description:t="< unknown name >",op:n="< unknown op >"}=ut(e),{spanId:r}=e.spanContext(),i=Ln(e)===e,o=`[Tracing] Finishing "${n}" ${i?"root ":""}span "${t}" with ID ${r}`;Pe.log(o)}function zh(e){if(typeof e=="boolean")return Number(e);const t=typeof e=="string"?parseFloat(e):e;if(typeof t!="number"||isNaN(t)||t<0||t>1){nt&&Pe.warn(`[Tracing] Given sample rate is invalid. Sample rate must be a boolean or a number between 0 and 1. Got ${JSON.stringify(e)} of type ${JSON.stringify(typeof e)}.`);return}return t}function RV(e,t){if(!di(e))return[!1];let n;typeof e.tracesSampler=="function"?n=e.tracesSampler(t):t.parentSampled!==void 0?n=t.parentSampled:typeof e.tracesSampleRate<"u"?n=e.tracesSampleRate:n=1;const r=zh(n);return r===void 0?(nt&&Pe.warn("[Tracing] Discarding transaction because of invalid sample rate."),[!1]):r?Math.random()<r?[!0,r]:(nt&&Pe.log(`[Tracing] Discarding transaction because it's not included in the random sample (sampling rate = ${Number(n)})`),[!1,r]):(nt&&Pe.log(`[Tracing] Discarding transaction because ${typeof e.tracesSampler=="function"?"tracesSampler returned 0 or false":"a negative sampling decision was inherited or tracesSampleRate is set to 0"}`),[!1,r])}const IV=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+)?)?@)([\w.-]+)(?::(\d+))?\/(.+)/;function AV(e){return e==="http"||e==="https"}function Fd(e,t=!1){const{host:n,path:r,pass:s,port:i,projectId:o,protocol:a,publicKey:l}=e;return`${a}://${l}${t&&s?`:${s}`:""}@${n}${i?`:${i}`:""}/${r&&`${r}/`}${o}`}function OV(e){const t=IV.exec(e);if(!t){Gi(()=>{console.error(`Invalid Sentry Dsn: ${e}`)});return}const[n,r,s="",i="",o="",a=""]=t.slice(1);let l="",u=a;const d=u.split("/");if(d.length>1&&(l=d.slice(0,-1).join("/"),u=d.pop()),u){const c=u.match(/^\d+/);c&&(u=c[0])}return iR({host:i,pass:s,path:l,projectId:u,port:o,protocol:n,publicKey:r})}function iR(e){return{protocol:e.protocol,publicKey:e.publicKey||"",pass:e.pass||"",host:e.host,port:e.port||"",path:e.path||"",projectId:e.projectId}}function MV(e){if(!Yo)return!0;const{port:t,projectId:n,protocol:r}=e;return["protocol","publicKey","host","projectId"].find(o=>e[o]?!1:(Pe.error(`Invalid Sentry Dsn: ${o} missing`),!0))?!1:n.match(/^\d+$/)?AV(r)?t&&isNaN(parseInt(t,10))?(Pe.error(`Invalid Sentry Dsn: Invalid port ${t}`),!1):!0:(Pe.error(`Invalid Sentry Dsn: Invalid protocol ${r}`),!1):(Pe.error(`Invalid Sentry Dsn: Invalid projectId ${n}`),!1)}function DV(e){const t=typeof e=="string"?OV(e):iR(e);if(!(!t||!MV(t)))return t}function LV(){const e=typeof WeakSet=="function",t=e?new WeakSet:[];function n(s){if(e)return t.has(s)?!0:(t.add(s),!1);for(let i=0;i<t.length;i++)if(t[i]===s)return!0;return t.push(s),!1}function r(s){if(e)t.delete(s);else for(let i=0;i<t.length;i++)if(t[i]===s){t.splice(i,1);break}}return[n,r]}function ni(e,t=100,n=1/0){try{return jv("",e,t,n)}catch(r){return{ERROR:`**non-serializable** (${r})`}}}function oR(e,t=3,n=100*1024){const r=ni(e,t);return BV(r)>n?oR(e,t-1,n):r}function jv(e,t,n=1/0,r=1/0,s=LV()){const[i,o]=s;if(t==null||["boolean","string"].includes(typeof t)||typeof t=="number"&&Number.isFinite(t))return t;const a=$V(e,t);if(!a.startsWith("[object "))return a;if(t.__sentry_skip_normalization__)return t;const l=typeof t.__sentry_override_normalization_depth__=="number"?t.__sentry_override_normalization_depth__:n;if(l===0)return a.replace("object ","");if(i(t))return"[Circular ~]";const u=t;if(u&&typeof u.toJSON=="function")try{const p=u.toJSON();return jv("",p,l-1,r,s)}catch{}const d=Array.isArray(t)?[]:{};let c=0;const f=zT(t);for(const p in f){if(!Object.prototype.hasOwnProperty.call(f,p))continue;if(c>=r){d[p]="[MaxProperties ~]";break}const g=f[p];d[p]=jv(p,g,l-1,r,s),c++}return o(t),d}function $V(e,t){try{if(e==="domain"&&t&&typeof t=="object"&&t._events)return"[Domain]";if(e==="domainEmitter")return"[DomainEmitter]";if(typeof global<"u"&&t===global)return"[Global]";if(typeof window<"u"&&t===window)return"[Window]";if(typeof document<"u"&&t===document)return"[Document]";if(BT(t))return"[VueViewModel]";if(HB(t))return"[SyntheticEvent]";if(typeof t=="number"&&!Number.isFinite(t))return`[${t}]`;if(typeof t=="function")return`[Function: ${Bi(t)}]`;if(typeof t=="symbol")return`[${String(t)}]`;if(typeof t=="bigint")return`[BigInt: ${String(t)}]`;const n=FV(t);return/^HTML(\w*)Element$/.test(n)?`[HTMLElement: ${n}]`:`[object ${n}]`}catch(n){return`**non-serializable** (${n})`}}function FV(e){const t=Object.getPrototypeOf(e);return t?t.constructor.name:"null prototype"}function NV(e){return~-encodeURI(e).split(/%..|./).length}function BV(e){return NV(JSON.stringify(e))}function sl(e,t=[]){return[e,t]}function VV(e,t){const[n,r]=e;return[n,[...r,t]]}function $0(e,t){const n=e[1];for(const r of n){const s=r[0].type;if(t(r,s))return!0}return!1}function qv(e){return ft.__SENTRY__&&ft.__SENTRY__.encodePolyfill?ft.__SENTRY__.encodePolyfill(e):new TextEncoder().encode(e)}function UV(e){const[t,n]=e;let r=JSON.stringify(t);function s(i){typeof r=="string"?r=typeof i=="string"?r+i:[qv(r),i]:r.push(typeof i=="string"?qv(i):i)}for(const i of n){const[o,a]=i;if(s(`
37
+ ${JSON.stringify(o)}
38
+ `),typeof a=="string"||a instanceof Uint8Array)s(a);else{let l;try{l=JSON.stringify(a)}catch{l=JSON.stringify(ni(a))}s(l)}}return typeof r=="string"?r:HV(r)}function HV(e){const t=e.reduce((s,i)=>s+i.length,0),n=new Uint8Array(t);let r=0;for(const s of e)n.set(s,r),r+=s.length;return n}function zV(e){return[{type:"span"},e]}function jV(e){const t=typeof e.data=="string"?qv(e.data):e.data;return[En({type:"attachment",length:t.length,filename:e.filename,content_type:e.contentType,attachment_type:e.attachmentType}),t]}const qV={session:"session",sessions:"session",attachment:"attachment",transaction:"transaction",event:"error",client_report:"internal",user_report:"default",profile:"profile",profile_chunk:"profile",replay_event:"replay",replay_recording:"replay",check_in:"monitor",feedback:"feedback",span:"span",statsd:"metric_bucket"};function F0(e){return qV[e]}function tw(e){if(!e||!e.sdk)return;const{name:t,version:n}=e.sdk;return{name:t,version:n}}function aR(e,t,n,r){const s=e.sdkProcessingMetadata&&e.sdkProcessingMetadata.dynamicSamplingContext;return{event_id:e.event_id,sent_at:new Date().toISOString(),...t&&{sdk:t},...!!n&&r&&{dsn:Fd(r)},...s&&{trace:En({...s})}}}function WV(e,t){return t&&(e.sdk=e.sdk||{},e.sdk.name=e.sdk.name||t.name,e.sdk.version=e.sdk.version||t.version,e.sdk.integrations=[...e.sdk.integrations||[],...t.integrations||[]],e.sdk.packages=[...e.sdk.packages||[],...t.packages||[]]),e}function GV(e,t,n,r){const s=tw(n),i={sent_at:new Date().toISOString(),...s&&{sdk:s},...!!r&&t&&{dsn:Fd(t)}},o="aggregates"in e?[{type:"sessions"},e]:[{type:"session"},e.toJSON()];return sl(i,[o])}function KV(e,t,n,r){const s=tw(n),i=e.type&&e.type!=="replay_event"?e.type:"event";WV(e,n&&n.sdk);const o=aR(e,s,r,t);return delete e.sdkProcessingMetadata,sl(o,[[{type:i},e]])}function YV(e,t){function n(d){return!!d.trace_id&&!!d.public_key}const r=Jo(e[0]),s=t&&t.getDsn(),i=t&&t.getOptions().tunnel,o={sent_at:new Date().toISOString(),...n(r)&&{trace:r},...!!i&&s&&{dsn:Fd(s)}},a=t&&t.getOptions().beforeSendSpan,l=a?d=>a(ut(d)):d=>ut(d),u=[];for(const d of e){const c=l(d);c&&u.push(zV(c))}return sl(o,u)}function XV(e,t,n,r=Rn()){const s=r&&Ln(r);s&&s.addEvent(e,{[em]:t,[Zp]:n})}function N0(e){if(!e||e.length===0)return;const t={};return e.forEach(n=>{const r=n.attributes||{},s=r[Zp],i=r[em];typeof s=="string"&&typeof i=="number"&&(t[n.name]={value:i,unit:s})}),t}const B0=1e3;class nw{constructor(t={}){this._traceId=t.traceId||tn(),this._spanId=t.spanId||tn().substring(16),this._startTime=t.startTimestamp||nr(),this._attributes={},this.setAttributes({[ln]:"manual",[ja]:t.op,...t.attributes}),this._name=t.name,t.parentSpanId&&(this._parentSpanId=t.parentSpanId),"sampled"in t&&(this._sampled=t.sampled),t.endTimestamp&&(this._endTime=t.endTimestamp),this._events=[],this._isStandaloneSpan=t.isStandalone,this._endTime&&this._onSpanEnded()}addLink(t){return this}addLinks(t){return this}recordException(t,n){}spanContext(){const{_spanId:t,_traceId:n,_sampled:r}=this;return{spanId:t,traceId:n,traceFlags:r?JT:QT}}setAttribute(t,n){return n===void 0?delete this._attributes[t]:this._attributes[t]=n,this}setAttributes(t){return Object.keys(t).forEach(n=>this.setAttribute(n,t[n])),this}updateStartTime(t){this._startTime=Oa(t)}setStatus(t){return this._status=t,this}updateName(t){return this._name=t,this.setAttribute(Yr,"custom"),this}end(t){this._endTime||(this._endTime=Oa(t),TV(this),this._onSpanEnded())}getSpanJSON(){return En({data:this._attributes,description:this._name,op:this._attributes[ja],parent_span_id:this._parentSpanId,span_id:this._spanId,start_timestamp:this._startTime,status:eR(this._status),timestamp:this._endTime,trace_id:this._traceId,origin:this._attributes[ln],_metrics_summary:Vv(this),profile_id:this._attributes[cV],exclusive_time:this._attributes[Qb],measurements:N0(this._events),is_segment:this._isStandaloneSpan&&Ln(this)===this||void 0,segment_id:this._isStandaloneSpan?Ln(this).spanContext().spanId:void 0})}isRecording(){return!this._endTime&&!!this._sampled}addEvent(t,n,r){nt&&Pe.log("[Tracing] Adding an event to span:",t);const s=V0(n)?n:r||nr(),i=V0(n)?{}:n||{},o={name:t,time:Oa(s),attributes:i};return this._events.push(o),this}isStandaloneSpan(){return!!this._isStandaloneSpan}_onSpanEnded(){const t=dt();if(t&&t.emit("spanEnd",this),!(this._isStandaloneSpan||this===Ln(this)))return;if(this._isStandaloneSpan){this._sampled?JV(YV([this],t)):(nt&&Pe.log("[Tracing] Discarding standalone span because its trace was not chosen to be sampled."),t&&t.recordDroppedEvent("sample_rate","span"));return}const r=this._convertSpanToTransaction();r&&(D0(this).scope||Bt()).captureEvent(r)}_convertSpanToTransaction(){if(!U0(ut(this)))return;this._name||(nt&&Pe.warn("Transaction has no name, falling back to `<unlabeled transaction>`."),this._name="<unlabeled transaction>");const{scope:t,isolationScope:n}=D0(this),s=(t||Bt()).getClient()||dt();if(this._sampled!==!0){nt&&Pe.log("[Tracing] Discarding transaction because its trace was not chosen to be sampled."),s&&s.recordDroppedEvent("sample_rate","transaction");return}const o=th(this).filter(c=>c!==this&&!QV(c)).map(c=>ut(c)).filter(U0),a=this._attributes[Yr],l={contexts:{trace:wV(this)},spans:o.length>B0?o.sort((c,f)=>c.start_timestamp-f.start_timestamp).slice(0,B0):o,start_timestamp:this._startTime,timestamp:this._endTime,transaction:this._name,type:"transaction",sdkProcessingMetadata:{capturedSpanScope:t,capturedSpanIsolationScope:n,...En({dynamicSamplingContext:Jo(this)})},_metrics_summary:Vv(this),...a&&{transaction_info:{source:a}}},u=N0(this._events);return u&&Object.keys(u).length&&(nt&&Pe.log("[Measurements] Adding measurements to transaction event",JSON.stringify(u,void 0,2)),l.measurements=u),l}}function V0(e){return e&&typeof e=="number"||e instanceof Date||Array.isArray(e)}function U0(e){return!!e.start_timestamp&&!!e.timestamp&&!!e.span_id&&!!e.trace_id}function QV(e){return e instanceof nw&&e.isStandaloneSpan()}function JV(e){const t=dt();if(!t)return;const n=e[1];if(!n||n.length===0){t.recordDroppedEvent("before_send","span");return}t.sendEnvelope(e)}const lR="__SENTRY_SUPPRESS_TRACING__";function qa(e){const t=cR();if(t.startInactiveSpan)return t.startInactiveSpan(e);const n=eU(e),{forceTransaction:r,parentSpan:s}=e;return(e.scope?o=>Xb(e.scope,o):s!==void 0?o=>uR(s,o):o=>o())(()=>{const o=Bt(),a=nU(o);return e.onlyIfParent&&!a?new Fu:ZV({parentSpan:a,spanArguments:n,forceTransaction:r,scope:o})})}function uR(e,t){const n=cR();return n.withActiveSpan?n.withActiveSpan(e,t):Xb(r=>(Yc(r,e||void 0),t(r)))}function ZV({parentSpan:e,spanArguments:t,forceTransaction:n,scope:r}){if(!di())return new Fu;const s=ws();let i;if(e&&!n)i=tU(e,r,t),tR(e,i);else if(e){const o=Jo(e),{traceId:a,spanId:l}=e.spanContext(),u=rl(e);i=H0({traceId:a,parentSpanId:l,...t},r,u),L0(i,o)}else{const{traceId:o,dsc:a,parentSpanId:l,sampled:u}={...s.getPropagationContext(),...r.getPropagationContext()};i=H0({traceId:o,parentSpanId:l,...t},r,u),a&&L0(i,a)}return PV(i),CV(i,r,s),i}function eU(e){const n={isStandalone:(e.experimental||{}).standalone,...e};if(e.startTime){const r={...n};return r.startTimestamp=Oa(e.startTime),delete r.startTime,r}return n}function cR(){const e=Lu();return $d(e)}function H0(e,t,n){const r=dt(),s=r&&r.getOptions()||{},{name:i="",attributes:o}=e,[a,l]=t.getScopeData().sdkProcessingMetadata[lR]?[!1]:RV(s,{name:i,parentSampled:n,attributes:o,transactionContext:{name:i,parentSampled:n}}),u=new nw({...e,attributes:{[Yr]:"custom",...e.attributes},sampled:a});return l!==void 0&&u.setAttribute(WT,l),r&&r.emit("spanStart",u),u}function tU(e,t,n){const{spanId:r,traceId:s}=e.spanContext(),i=t.getScopeData().sdkProcessingMetadata[lR]?!1:rl(e),o=i?new nw({...n,parentSpanId:r,traceId:s,sampled:i}):new Fu({traceId:s});tR(e,o);const a=dt();return a&&(a.emit("spanStart",o),n.endTimestamp&&a.emit("spanEnd",o)),o}function nU(e){const t=Hh(e);if(!t)return;const n=dt();return(n?n.getOptions():{}).parentSpanIsAlwaysRootSpan?Ln(t):t}const nh={idleTimeout:1e3,finalTimeout:3e4,childSpanTimeout:15e3},rU="heartbeatFailed",sU="idleTimeout",iU="finalTimeout",oU="externalFinish";function dR(e,t={}){const n=new Map;let r=!1,s,i=oU,o=!t.disableAutoFinish;const a=[],{idleTimeout:l=nh.idleTimeout,finalTimeout:u=nh.finalTimeout,childSpanTimeout:d=nh.childSpanTimeout,beforeSpanEnd:c}=t,f=dt();if(!f||!di())return new Fu;const p=Bt(),g=Rn(),m=aU(e);m.end=new Proxy(m.end,{apply(T,C,k){c&&c(m);const[x,...I]=k,M=x||nr(),O=Oa(M),A=th(m).filter(j=>j!==m);if(!A.length)return E(O),Reflect.apply(T,C,[O,...I]);const D=A.map(j=>ut(j).timestamp).filter(j=>!!j),V=D.length?Math.max(...D):void 0,H=ut(m).start_timestamp,G=Math.min(H?H+u/1e3:1/0,Math.max(H||-1/0,Math.min(O,V||1/0)));return E(G),Reflect.apply(T,C,[G,...I])}});function y(){s&&(clearTimeout(s),s=void 0)}function b(T){y(),s=setTimeout(()=>{!r&&n.size===0&&o&&(i=sU,m.end(T))},l)}function w(T){s=setTimeout(()=>{!r&&o&&(i=rU,m.end(T))},d)}function S(T){y(),n.set(T,!0);const C=nr();w(C+d/1e3)}function P(T){if(n.has(T)&&n.delete(T),n.size===0){const C=nr();b(C+l/1e3)}}function E(T){r=!0,n.clear(),a.forEach(O=>O()),Yc(p,g);const C=ut(m),{start_timestamp:k}=C;if(!k)return;(C.data||{})[Uv]||m.setAttribute(Uv,i),Pe.log(`[Tracing] Idle span "${C.op}" finished`);const I=th(m).filter(O=>O!==m);let M=0;I.forEach(O=>{O.isRecording()&&(O.setStatus({code:In,message:"cancelled"}),O.end(T),nt&&Pe.log("[Tracing] Cancelling span since span ended early",JSON.stringify(O,void 0,2)));const A=ut(O),{timestamp:D=0,start_timestamp:V=0}=A,H=V<=T,G=(u+l)/1e3,j=D-V<=G;if(nt){const B=JSON.stringify(O,void 0,2);H?j||Pe.log("[Tracing] Discarding span since it finished after idle span final timeout",B):Pe.log("[Tracing] Discarding span since it happened after idle span was finished",B)}(!j||!H)&&(xV(m,O),M++)}),M>0&&m.setAttribute("sentry.idle_span_discarded_spans",M)}return a.push(f.on("spanStart",T=>{if(r||T===m||ut(T).timestamp)return;th(m).includes(T)&&S(T.spanContext().spanId)})),a.push(f.on("spanEnd",T=>{r||P(T.spanContext().spanId)})),a.push(f.on("idleSpanEnableAutoFinish",T=>{T===m&&(o=!0,b(),n.size&&w())})),t.disableAutoFinish||b(),setTimeout(()=>{r||(m.setStatus({code:In,message:"deadline_exceeded"}),i=iU,m.end())},u),m}function aU(e){const t=qa(e);return Yc(Bt(),t),nt&&Pe.log("[Tracing] Started span is an idle span"),t}function Wv(e,t,n,r=0){return new ls((s,i)=>{const o=e[r];if(t===null||typeof o!="function")s(t);else{const a=o({...t},n);nt&&o.id&&a===null&&Pe.log(`Event processor "${o.id}" dropped event`),Qp(a)?a.then(l=>Wv(e,l,n,r+1).then(s)).then(null,i):Wv(e,a,n,r+1).then(s).then(null,i)}})}const z0=new WeakMap;function lU(e){const t=ft._sentryDebugIds;if(!t)return{};let n;const r=z0.get(e);return r?n=r:(n=new Map,z0.set(e,n)),Object.keys(t).reduce((s,i)=>{let o;const a=n.get(i);a?o=a:(o=e(i),n.set(i,o));for(let l=o.length-1;l>=0;l--){const u=o[l],d=u&&u.filename;if(u&&d){s[d]=t[i];break}}return s},{})}function uU(e,t){const{fingerprint:n,span:r,breadcrumbs:s,sdkProcessingMetadata:i}=t;cU(e,t),r&&hU(e,r),pU(e,n),dU(e,s),fU(e,i)}function j0(e,t){const{extra:n,tags:r,user:s,contexts:i,level:o,sdkProcessingMetadata:a,breadcrumbs:l,fingerprint:u,eventProcessors:d,attachments:c,propagationContext:f,transactionName:p,span:g}=t;df(e,"extra",n),df(e,"tags",r),df(e,"user",s),df(e,"contexts",i),e.sdkProcessingMetadata=Jp(e.sdkProcessingMetadata,a,2),o&&(e.level=o),p&&(e.transactionName=p),g&&(e.span=g),l.length&&(e.breadcrumbs=[...e.breadcrumbs,...l]),u.length&&(e.fingerprint=[...e.fingerprint,...u]),d.length&&(e.eventProcessors=[...e.eventProcessors,...d]),c.length&&(e.attachments=[...e.attachments,...c]),e.propagationContext={...e.propagationContext,...f}}function df(e,t,n){e[t]=Jp(e[t],n,1)}function cU(e,t){const{extra:n,tags:r,user:s,contexts:i,level:o,transactionName:a}=t,l=En(n);l&&Object.keys(l).length&&(e.extra={...l,...e.extra});const u=En(r);u&&Object.keys(u).length&&(e.tags={...u,...e.tags});const d=En(s);d&&Object.keys(d).length&&(e.user={...d,...e.user});const c=En(i);c&&Object.keys(c).length&&(e.contexts={...c,...e.contexts}),o&&(e.level=o),a&&e.type!=="transaction"&&(e.transaction=a)}function dU(e,t){const n=[...e.breadcrumbs||[],...t];e.breadcrumbs=n.length?n:void 0}function fU(e,t){e.sdkProcessingMetadata={...e.sdkProcessingMetadata,...t}}function hU(e,t){e.contexts={trace:SV(t),...e.contexts},e.sdkProcessingMetadata={dynamicSamplingContext:Jo(t),...e.sdkProcessingMetadata};const n=Ln(t),r=ut(n).description;r&&!e.transaction&&e.type==="transaction"&&(e.transaction=r)}function pU(e,t){e.fingerprint=e.fingerprint?Array.isArray(e.fingerprint)?e.fingerprint:[e.fingerprint]:[],t&&(e.fingerprint=e.fingerprint.concat(t)),e.fingerprint&&!e.fingerprint.length&&delete e.fingerprint}function fR(e,t,n,r,s,i){const{normalizeDepth:o=3,normalizeMaxBreadth:a=1e3}=e,l={...t,event_id:t.event_id||n.event_id||tn(),timestamp:t.timestamp||Ld()},u=n.integrations||e.integrations.map(y=>y.name);mU(l,e),yU(l,u),s&&s.emit("applyFrameMetadata",t),t.type===void 0&&gU(l,e.stackParser);const d=wU(r,n.captureContext);n.mechanism&&Kc(l,n.mechanism);const c=s?s.getEventProcessors():[],f=lV().getScopeData();if(i){const y=i.getScopeData();j0(f,y)}if(d){const y=d.getScopeData();j0(f,y)}const p=[...n.attachments||[],...f.attachments];p.length&&(n.attachments=p),uU(l,f);const g=[...c,...f.eventProcessors];return Wv(g,l,n).then(y=>(y&&vU(y),typeof o=="number"&&o>0?bU(y,o,a):y))}function mU(e,t){const{environment:n,release:r,dist:s,maxValueLength:i=250}=t;"environment"in e||(e.environment="environment"in t?n:ew),e.release===void 0&&r!==void 0&&(e.release=r),e.dist===void 0&&s!==void 0&&(e.dist=s),e.message&&(e.message=Ul(e.message,i));const o=e.exception&&e.exception.values&&e.exception.values[0];o&&o.value&&(o.value=Ul(o.value,i));const a=e.request;a&&a.url&&(a.url=Ul(a.url,i))}function gU(e,t){const n=lU(t);try{e.exception.values.forEach(r=>{r.stacktrace.frames.forEach(s=>{s.filename&&(s.debug_id=n[s.filename])})})}catch{}}function vU(e){const t={};try{e.exception.values.forEach(r=>{r.stacktrace.frames.forEach(s=>{s.debug_id&&(s.abs_path?t[s.abs_path]=s.debug_id:s.filename&&(t[s.filename]=s.debug_id),delete s.debug_id)})})}catch{}if(Object.keys(t).length===0)return;e.debug_meta=e.debug_meta||{},e.debug_meta.images=e.debug_meta.images||[];const n=e.debug_meta.images;Object.entries(t).forEach(([r,s])=>{n.push({type:"sourcemap",code_file:r,debug_id:s})})}function yU(e,t){t.length>0&&(e.sdk=e.sdk||{},e.sdk.integrations=[...e.sdk.integrations||[],...t])}function bU(e,t,n){if(!e)return null;const r={...e,...e.breadcrumbs&&{breadcrumbs:e.breadcrumbs.map(s=>({...s,...s.data&&{data:ni(s.data,t,n)}}))},...e.user&&{user:ni(e.user,t,n)},...e.contexts&&{contexts:ni(e.contexts,t,n)},...e.extra&&{extra:ni(e.extra,t,n)}};return e.contexts&&e.contexts.trace&&r.contexts&&(r.contexts.trace=e.contexts.trace,e.contexts.trace.data&&(r.contexts.trace.data=ni(e.contexts.trace.data,t,n))),e.spans&&(r.spans=e.spans.map(s=>({...s,...s.data&&{data:ni(s.data,t,n)}}))),r}function wU(e,t){if(!t)return e;const n=e?e.clone():new Fo;return n.update(t),n}function SU(e){if(e)return _U(e)?{captureContext:e}:xU(e)?{captureContext:e}:e}function _U(e){return e instanceof Fo||typeof e=="function"}const kU=["user","level","extra","contexts","tags","fingerprint","requestSession","propagationContext"];function xU(e){return Object.keys(e).some(t=>kU.includes(t))}function li(e,t){return Bt().captureException(e,SU(t))}function hR(e,t){return Bt().captureEvent(e,t)}function EU(e,t){ws().setContext(e,t)}function CU(e){ws().addEventProcessor(e)}function q0(e){const t=dt(),n=ws(),r=Bt(),{release:s,environment:i=ew}=t&&t.getOptions()||{},{userAgent:o}=ft.navigator||{},a=JB({release:s,environment:i,user:r.getUser()||n.getUser(),...o&&{userAgent:o},...e}),l=n.getSession();return l&&l.status==="ok"&&cu(l,{status:"exited"}),pR(),n.setSession(a),r.setSession(a),a}function pR(){const e=ws(),t=Bt(),n=t.getSession()||e.getSession();n&&ZB(n),mR(),e.setSession(),t.setSession()}function mR(){const e=ws(),t=Bt(),n=dt(),r=t.getSession()||e.getSession();r&&n&&n.captureSession(r)}function W0(e=!1){if(e){pR();return}mR()}const PU="7";function TU(e){const t=e.protocol?`${e.protocol}:`:"",n=e.port?`:${e.port}`:"";return`${t}//${e.host}${n}${e.path?`/${e.path}`:""}/api/`}function RU(e){return`${TU(e)}${e.projectId}/envelope/`}function IU(e,t){return GB({sentry_key:e.publicKey,sentry_version:PU,...t&&{sentry_client:`${t.name}/${t.version}`}})}function AU(e,t,n){return t||`${RU(e)}?${IU(e,n)}`}const G0=[];function OU(e){const t={};return e.forEach(n=>{const{name:r}=n,s=t[r];s&&!s.isDefaultInstance&&n.isDefaultInstance||(t[r]=n)}),Object.values(t)}function MU(e){const t=e.defaultIntegrations||[],n=e.integrations;t.forEach(o=>{o.isDefaultInstance=!0});let r;if(Array.isArray(n))r=[...t,...n];else if(typeof n=="function"){const o=n(t);r=Array.isArray(o)?o:[o]}else r=t;const s=OU(r),i=s.findIndex(o=>o.name==="Debug");if(i>-1){const[o]=s.splice(i,1);s.push(o)}return s}function DU(e,t){const n={};return t.forEach(r=>{r&&gR(e,r,n)}),n}function K0(e,t){for(const n of t)n&&n.afterAllSetup&&n.afterAllSetup(e)}function gR(e,t,n){if(n[t.name]){nt&&Pe.log(`Integration skipped because it was already installed: ${t.name}`);return}if(n[t.name]=t,G0.indexOf(t.name)===-1&&typeof t.setupOnce=="function"&&(t.setupOnce(),G0.push(t.name)),t.setup&&typeof t.setup=="function"&&t.setup(e),typeof t.preprocessEvent=="function"){const r=t.preprocessEvent.bind(t);e.on("preprocessEvent",(s,i)=>r(s,i,e))}if(typeof t.processEvent=="function"){const r=t.processEvent.bind(t),s=Object.assign((i,o)=>r(i,o,e),{id:t.name});e.addEventProcessor(s)}nt&&Pe.log(`Integration installed: ${t.name}`)}function LU(e,t,n){const r=[{type:"client_report"},{timestamp:Ld(),discarded_events:e}];return sl(t?{dsn:t}:{},[r])}class ri extends Error{constructor(t,n="warn"){super(t),this.message=t,this.name=new.target.prototype.constructor.name,Object.setPrototypeOf(this,new.target.prototype),this.logLevel=n}}const Y0="Not capturing exception because it's already been captured.";class $U{constructor(t){if(this._options=t,this._integrations={},this._numProcessing=0,this._outcomes={},this._hooks={},this._eventProcessors=[],t.dsn?this._dsn=DV(t.dsn):nt&&Pe.warn("No DSN provided, client will not send events."),this._dsn){const n=AU(this._dsn,t.tunnel,t._metadata?t._metadata.sdk:void 0);this._transport=t.transport({tunnel:this._options.tunnel,recordDroppedEvent:this.recordDroppedEvent.bind(this),...t.transportOptions,url:n})}}captureException(t,n,r){const s=tn();if(R0(t))return nt&&Pe.log(Y0),s;const i={event_id:s,...n};return this._process(this.eventFromException(t,i).then(o=>this._captureEvent(o,i,r))),i.event_id}captureMessage(t,n,r,s){const i={event_id:tn(),...r},o=Wb(t)?t:String(t),a=Gb(t)?this.eventFromMessage(o,n,i):this.eventFromException(t,i);return this._process(a.then(l=>this._captureEvent(l,i,s))),i.event_id}captureEvent(t,n,r){const s=tn();if(n&&n.originalException&&R0(n.originalException))return nt&&Pe.log(Y0),s;const i={event_id:s,...n},a=(t.sdkProcessingMetadata||{}).capturedSpanScope;return this._process(this._captureEvent(t,i,a||r)),i.event_id}captureSession(t){typeof t.release!="string"?nt&&Pe.warn("Discarded session because of missing or non-string release"):(this.sendSession(t),cu(t,{init:!1}))}getDsn(){return this._dsn}getOptions(){return this._options}getSdkMetadata(){return this._options._metadata}getTransport(){return this._transport}flush(t){const n=this._transport;return n?(this.emit("flush"),this._isClientDoneProcessing(t).then(r=>n.flush(t).then(s=>r&&s))):Hi(!0)}close(t){return this.flush(t).then(n=>(this.getOptions().enabled=!1,this.emit("close"),n))}getEventProcessors(){return this._eventProcessors}addEventProcessor(t){this._eventProcessors.push(t)}init(){(this._isEnabled()||this._options.integrations.some(({name:t})=>t.startsWith("Spotlight")))&&this._setupIntegrations()}getIntegrationByName(t){return this._integrations[t]}addIntegration(t){const n=this._integrations[t.name];gR(this,t,this._integrations),n||K0(this,[t])}sendEvent(t,n={}){this.emit("beforeSendEvent",t,n);let r=KV(t,this._dsn,this._options._metadata,this._options.tunnel);for(const i of n.attachments||[])r=VV(r,jV(i));const s=this.sendEnvelope(r);s&&s.then(i=>this.emit("afterSendEvent",t,i),null)}sendSession(t){const n=GV(t,this._dsn,this._options._metadata,this._options.tunnel);this.sendEnvelope(n)}recordDroppedEvent(t,n,r){if(this._options.sendClientReports){const s=typeof r=="number"?r:1,i=`${t}:${n}`;nt&&Pe.log(`Recording outcome: "${i}"${s>1?` (${s} times)`:""}`),this._outcomes[i]=(this._outcomes[i]||0)+s}}on(t,n){const r=this._hooks[t]=this._hooks[t]||[];return r.push(n),()=>{const s=r.indexOf(n);s>-1&&r.splice(s,1)}}emit(t,...n){const r=this._hooks[t];r&&r.forEach(s=>s(...n))}sendEnvelope(t){return this.emit("beforeEnvelope",t),this._isEnabled()&&this._transport?this._transport.send(t).then(null,n=>(nt&&Pe.error("Error while sending envelope:",n),n)):(nt&&Pe.error("Transport disabled"),Hi({}))}_setupIntegrations(){const{integrations:t}=this._options;this._integrations=DU(this,t),K0(this,t)}_updateSessionFromEvent(t,n){let r=!1,s=!1;const i=n.exception&&n.exception.values;if(i){s=!0;for(const l of i){const u=l.mechanism;if(u&&u.handled===!1){r=!0;break}}}const o=t.status==="ok";(o&&t.errors===0||o&&r)&&(cu(t,{...r&&{status:"crashed"},errors:t.errors||Number(s||r)}),this.captureSession(t))}_isClientDoneProcessing(t){return new ls(n=>{let r=0;const s=1,i=setInterval(()=>{this._numProcessing==0?(clearInterval(i),n(!0)):(r+=s,t&&r>=t&&(clearInterval(i),n(!1)))},s)})}_isEnabled(){return this.getOptions().enabled!==!1&&this._transport!==void 0}_prepareEvent(t,n,r,s=ws()){const i=this.getOptions(),o=Object.keys(this._integrations);return!n.integrations&&o.length>0&&(n.integrations=o),this.emit("preprocessEvent",t,n),t.type||s.setLastEventId(t.event_id||n.event_id),fR(i,t,n,r,this,s).then(a=>{if(a===null)return a;const l={...s.getPropagationContext(),...r?r.getPropagationContext():void 0};if(!(a.contexts&&a.contexts.trace)&&l){const{traceId:d,spanId:c,parentSpanId:f,dsc:p}=l;a.contexts={trace:En({trace_id:d,span_id:c,parent_span_id:f}),...a.contexts};const g=p||tm(d,this);a.sdkProcessingMetadata={dynamicSamplingContext:g,...a.sdkProcessingMetadata}}return a})}_captureEvent(t,n={},r){return this._processEvent(t,n,r).then(s=>s.event_id,s=>{if(nt){const i=s;i.logLevel==="log"?Pe.log(i.message):Pe.warn(i)}})}_processEvent(t,n,r){const s=this.getOptions(),{sampleRate:i}=s,o=yR(t),a=vR(t),l=t.type||"error",u=`before send for type \`${l}\``,d=typeof i>"u"?void 0:zh(i);if(a&&typeof d=="number"&&Math.random()>d)return this.recordDroppedEvent("sample_rate","error",t),Vh(new ri(`Discarding event because it's not included in the random sample (sampling rate = ${i})`,"log"));const c=l==="replay_event"?"replay":l,p=(t.sdkProcessingMetadata||{}).capturedSpanIsolationScope;return this._prepareEvent(t,n,r,p).then(g=>{if(g===null)throw this.recordDroppedEvent("event_processor",c,t),new ri("An event processor returned `null`, will not send event.","log");if(n.data&&n.data.__sentry__===!0)return g;const y=NU(this,s,g,n);return FU(y,u)}).then(g=>{if(g===null){if(this.recordDroppedEvent("before_send",c,t),o){const w=1+(t.spans||[]).length;this.recordDroppedEvent("before_send","span",w)}throw new ri(`${u} returned \`null\`, will not send event.`,"log")}const m=r&&r.getSession();if(!o&&m&&this._updateSessionFromEvent(m,g),o){const b=g.sdkProcessingMetadata&&g.sdkProcessingMetadata.spanCountBeforeProcessing||0,w=g.spans?g.spans.length:0,S=b-w;S>0&&this.recordDroppedEvent("before_send","span",S)}const y=g.transaction_info;if(o&&y&&g.transaction!==t.transaction){const b="custom";g.transaction_info={...y,source:b}}return this.sendEvent(g,n),g}).then(null,g=>{throw g instanceof ri?g:(this.captureException(g,{data:{__sentry__:!0},originalException:g}),new ri(`Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event.
39
+ Reason: ${g}`))})}_process(t){this._numProcessing++,t.then(n=>(this._numProcessing--,n),n=>(this._numProcessing--,n))}_clearOutcomes(){const t=this._outcomes;return this._outcomes={},Object.entries(t).map(([n,r])=>{const[s,i]=n.split(":");return{reason:s,category:i,quantity:r}})}_flushOutcomes(){nt&&Pe.log("Flushing outcomes...");const t=this._clearOutcomes();if(t.length===0){nt&&Pe.log("No outcomes to send");return}if(!this._dsn){nt&&Pe.log("No dsn provided, will not send outcomes");return}nt&&Pe.log("Sending outcomes:",t);const n=LU(t,this._options.tunnel&&Fd(this._dsn));this.sendEnvelope(n)}}function FU(e,t){const n=`${t} must return \`null\` or a valid event.`;if(Qp(e))return e.then(r=>{if(!uu(r)&&r!==null)throw new ri(n);return r},r=>{throw new ri(`${t} rejected with ${r}`)});if(!uu(e)&&e!==null)throw new ri(n);return e}function NU(e,t,n,r){const{beforeSend:s,beforeSendTransaction:i,beforeSendSpan:o}=t;if(vR(n)&&s)return s(n,r);if(yR(n)){if(n.spans&&o){const a=[];for(const l of n.spans){const u=o(l);u?a.push(u):e.recordDroppedEvent("before_send","span")}n.spans=a}if(i){if(n.spans){const a=n.spans.length;n.sdkProcessingMetadata={...n.sdkProcessingMetadata,spanCountBeforeProcessing:a}}return i(n,r)}}return n}function vR(e){return e.type===void 0}function yR(e){return e.type==="transaction"}function BU(e,t){t.debug===!0&&(nt?Pe.enable():Gi(()=>{console.warn("[Sentry] Cannot initialize SDK with `debug` option using a non-debug bundle.")})),Bt().update(t.initialScope);const r=new e(t);return VU(r),r.init(),r}function VU(e){Bt().setClient(e)}function UU(e){const t=[];function n(){return e===void 0||t.length<e}function r(o){return t.splice(t.indexOf(o),1)[0]||Promise.resolve(void 0)}function s(o){if(!n())return Vh(new ri("Not adding Promise because buffer limit was reached."));const a=o();return t.indexOf(a)===-1&&t.push(a),a.then(()=>r(a)).then(null,()=>r(a).then(null,()=>{})),a}function i(o){return new ls((a,l)=>{let u=t.length;if(!u)return a(!0);const d=setTimeout(()=>{o&&o>0&&a(!1)},o);t.forEach(c=>{Hi(c).then(()=>{--u||(clearTimeout(d),a(!0))},l)})})}return{$:t,add:s,drain:i}}const HU=60*1e3;function zU(e,t=Date.now()){const n=parseInt(`${e}`,10);if(!isNaN(n))return n*1e3;const r=Date.parse(`${e}`);return isNaN(r)?HU:r-t}function jU(e,t){return e[t]||e.all||0}function bR(e,t,n=Date.now()){return jU(e,t)>n}function wR(e,{statusCode:t,headers:n},r=Date.now()){const s={...e},i=n&&n["x-sentry-rate-limits"],o=n&&n["retry-after"];if(i)for(const a of i.trim().split(",")){const[l,u,,,d]=a.split(":",5),c=parseInt(l,10),f=(isNaN(c)?60:c)*1e3;if(!u)s.all=r+f;else for(const p of u.split(";"))p==="metric_bucket"?(!d||d.split(";").includes("custom"))&&(s[p]=r+f):s[p]=r+f}else o?s.all=r+zU(o,r):t===429&&(s.all=r+60*1e3);return s}const qU=64;function WU(e,t,n=UU(e.bufferSize||qU)){let r={};const s=o=>n.drain(o);function i(o){const a=[];if($0(o,(c,f)=>{const p=F0(f);if(bR(r,p)){const g=X0(c,f);e.recordDroppedEvent("ratelimit_backoff",p,g)}else a.push(c)}),a.length===0)return Hi({});const l=sl(o[0],a),u=c=>{$0(l,(f,p)=>{const g=X0(f,p);e.recordDroppedEvent(c,F0(p),g)})},d=()=>t({body:UV(l)}).then(c=>(c.statusCode!==void 0&&(c.statusCode<200||c.statusCode>=300)&&nt&&Pe.warn(`Sentry responded with status code ${c.statusCode} to sent event.`),r=wR(r,c),c),c=>{throw u("network_error"),c});return n.add(d).then(c=>c,c=>{if(c instanceof ri)return nt&&Pe.error("Skipped sending event because buffer is full."),u("queue_overflow"),Hi({});throw c})}return{send:i,flush:s}}function X0(e,t){if(!(t!=="event"&&t!=="transaction"))return Array.isArray(e)?e[1]:void 0}function GU(e,t){const n=t&&t.getDsn(),r=t&&t.getOptions().tunnel;return YU(e,n)||KU(e,r)}function KU(e,t){return t?Q0(e)===Q0(t):!1}function YU(e,t){return t?e.includes(t.host):!1}function Q0(e){return e[e.length-1]==="/"?e.slice(0,-1):e}function XU(e,t,n=[t],r="npm"){const s=e._metadata||{};s.sdk||(s.sdk={name:`sentry.javascript.${t}`,packages:n.map(i=>({name:`${r}:@sentry/${i}`,version:Mi})),version:Mi}),e._metadata=s}const QU=100;function No(e,t){const n=dt(),r=ws();if(!n)return;const{beforeBreadcrumb:s=null,maxBreadcrumbs:i=QU}=n.getOptions();if(i<=0)return;const a={timestamp:Ld(),...e},l=s?Gi(()=>s(a,t)):a;l!==null&&(n.emit&&n.emit("beforeAddBreadcrumb",l,t),r.addBreadcrumb(l,i))}let J0;const JU="FunctionToString",Z0=new WeakMap,ZU=()=>({name:JU,setupOnce(){J0=Function.prototype.toString;try{Function.prototype.toString=function(...e){const t=Kb(this),n=Z0.has(dt())&&t!==void 0?t:this;return J0.apply(n,e)}}catch{}},setup(e){Z0.set(e,!0)}}),eH=ZU,tH=[/^Script error\.?$/,/^Javascript error: Script error\.? on line 0$/,/^ResizeObserver loop completed with undelivered notifications.$/,/^Cannot redefine property: googletag$/,"undefined is not an object (evaluating 'a.L')",`can't redefine non-configurable property "solana"`,"vv().getRestrictions is not a function. (In 'vv().getRestrictions(1,a)', 'vv().getRestrictions' is undefined)","Can't find variable: _AutofillCallbackHandler"],nH="InboundFilters",rH=(e={})=>({name:nH,processEvent(t,n,r){const s=r.getOptions(),i=iH(e,s);return oH(t,i)?null:t}}),sH=rH;function iH(e={},t={}){return{allowUrls:[...e.allowUrls||[],...t.allowUrls||[]],denyUrls:[...e.denyUrls||[],...t.denyUrls||[]],ignoreErrors:[...e.ignoreErrors||[],...t.ignoreErrors||[],...e.disableErrorDefaults?[]:tH],ignoreTransactions:[...e.ignoreTransactions||[],...t.ignoreTransactions||[]],ignoreInternal:e.ignoreInternal!==void 0?e.ignoreInternal:!0}}function oH(e,t){return t.ignoreInternal&&fH(e)?(nt&&Pe.warn(`Event dropped due to being internal Sentry Error.
40
+ Event: ${ao(e)}`),!0):aH(e,t.ignoreErrors)?(nt&&Pe.warn(`Event dropped due to being matched by \`ignoreErrors\` option.
41
+ Event: ${ao(e)}`),!0):pH(e)?(nt&&Pe.warn(`Event dropped due to not having an error message, error type or stacktrace.
42
+ Event: ${ao(e)}`),!0):lH(e,t.ignoreTransactions)?(nt&&Pe.warn(`Event dropped due to being matched by \`ignoreTransactions\` option.
43
+ Event: ${ao(e)}`),!0):uH(e,t.denyUrls)?(nt&&Pe.warn(`Event dropped due to being matched by \`denyUrls\` option.
44
+ Event: ${ao(e)}.
45
+ Url: ${jh(e)}`),!0):cH(e,t.allowUrls)?!1:(nt&&Pe.warn(`Event dropped due to not being matched by \`allowUrls\` option.
46
+ Event: ${ao(e)}.
47
+ Url: ${jh(e)}`),!0)}function aH(e,t){return e.type||!t||!t.length?!1:dH(e).some(n=>Io(n,t))}function lH(e,t){if(e.type!=="transaction"||!t||!t.length)return!1;const n=e.transaction;return n?Io(n,t):!1}function uH(e,t){if(!t||!t.length)return!1;const n=jh(e);return n?Io(n,t):!1}function cH(e,t){if(!t||!t.length)return!0;const n=jh(e);return n?Io(n,t):!0}function dH(e){const t=[];e.message&&t.push(e.message);let n;try{n=e.exception.values[e.exception.values.length-1]}catch{}return n&&n.value&&(t.push(n.value),n.type&&t.push(`${n.type}: ${n.value}`)),t}function fH(e){try{return e.exception.values[0].type==="SentryError"}catch{}return!1}function hH(e=[]){for(let t=e.length-1;t>=0;t--){const n=e[t];if(n&&n.filename!=="<anonymous>"&&n.filename!=="[native code]")return n.filename||null}return null}function jh(e){try{let t;try{t=e.exception.values[0].stacktrace.frames}catch{}return t?hH(t):null}catch{return nt&&Pe.error(`Cannot extract url for event ${ao(e)}`),null}}function pH(e){return e.type||!e.exception||!e.exception.values||e.exception.values.length===0?!1:!e.message&&!e.exception.values.some(t=>t.stacktrace||t.type&&t.type!=="Error"||t.value)}function mH(e,t,n=250,r,s,i,o){if(!i.exception||!i.exception.values||!o||!Vi(o.originalException,Error))return;const a=i.exception.values.length>0?i.exception.values[i.exception.values.length-1]:void 0;a&&(i.exception.values=gH(Gv(e,t,s,o.originalException,r,i.exception.values,a,0),n))}function Gv(e,t,n,r,s,i,o,a){if(i.length>=n+1)return i;let l=[...i];if(Vi(r[s],Error)){e1(o,a);const u=e(t,r[s]),d=l.length;t1(u,s,d,a),l=Gv(e,t,n,r[s],s,[u,...l],u,d)}return Array.isArray(r.errors)&&r.errors.forEach((u,d)=>{if(Vi(u,Error)){e1(o,a);const c=e(t,u),f=l.length;t1(c,`errors[${d}]`,f,a),l=Gv(e,t,n,u,s,[c,...l],c,f)}}),l}function e1(e,t){e.mechanism=e.mechanism||{type:"generic",handled:!0},e.mechanism={...e.mechanism,...e.type==="AggregateError"&&{is_exception_group:!0},exception_id:t}}function t1(e,t,n,r){e.mechanism=e.mechanism||{type:"generic",handled:!0},e.mechanism={...e.mechanism,type:"chained",source:t,exception_id:n,parent_id:r}}function gH(e,t){return e.map(n=>(n.value&&(n.value=Ul(n.value,t)),n))}function Da(e){if(!e)return{};const t=e.match(/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!t)return{};const n=t[6]||"",r=t[8]||"";return{host:t[4],path:t[5],protocol:t[2],search:n,hash:r,relative:t[5]+n+r}}function vH(e){const t="console";Xo(t,e),Qo(t,yH)}function yH(){"console"in ft&&$v.forEach(function(e){e in ft.console&&Tr(ft.console,e,function(t){return Bh[e]=t,function(...n){fs("console",{args:n,level:e});const s=Bh[e];s&&s.apply(ft.console,n)}})})}const bH=["fatal","error","warning","log","info","debug"];function SR(e){return e==="warn"?"warning":bH.includes(e)?e:"log"}const wH="Dedupe",SH=()=>{let e;return{name:wH,processEvent(t){if(t.type)return t;try{if(kH(t,e))return nt&&Pe.warn("Event dropped due to being a duplicate of previously captured event."),null}catch{}return e=t}}},_H=SH;function kH(e,t){return t?!!(xH(e,t)||EH(e,t)):!1}function xH(e,t){const n=e.message,r=t.message;return!(!n&&!r||n&&!r||!n&&r||n!==r||!kR(e,t)||!_R(e,t))}function EH(e,t){const n=n1(t),r=n1(e);return!(!n||!r||n.type!==r.type||n.value!==r.value||!kR(e,t)||!_R(e,t))}function _R(e,t){let n=k0(e),r=k0(t);if(!n&&!r)return!0;if(n&&!r||!n&&r||(n=n,r=r,r.length!==n.length))return!1;for(let s=0;s<r.length;s++){const i=r[s],o=n[s];if(i.filename!==o.filename||i.lineno!==o.lineno||i.colno!==o.colno||i.function!==o.function)return!1}return!0}function kR(e,t){let n=e.fingerprint,r=t.fingerprint;if(!n&&!r)return!0;if(n&&!r||!n&&r)return!1;n=n,r=r;try{return n.join("")===r.join("")}catch{return!1}}function n1(e){return e.exception&&e.exception.values&&e.exception.values[0]}function CH(e,t,n,r,s="auto.http.browser"){if(!e.fetchData)return;const i=di()&&t(e.fetchData.url);if(e.endTimestamp&&i){const g=e.fetchData.__span;if(!g)return;const m=r[g];m&&(RH(m,e),delete r[g]);return}const o=Bt(),a=dt(),{method:l,url:u}=e.fetchData,d=TH(u),c=d?Da(d).host:void 0,f=!!Rn(),p=i&&f?qa({name:`${l} ${u}`,attributes:{url:u,type:"fetch","http.method":l,"http.url":d,"server.address":c,[ln]:s,[ja]:"http.client"}}):new Fu;if(e.fetchData.__span=p.spanContext().spanId,r[p.spanContext().spanId]=p,n(e.fetchData.url)&&a){const g=e.args[0];e.args[1]=e.args[1]||{};const m=e.args[1];m.headers=PH(g,a,o,m,di()&&f?p:void 0)}return p}function PH(e,t,n,r,s){const i=ws(),{traceId:o,spanId:a,sampled:l,dsc:u}={...i.getPropagationContext(),...n.getPropagationContext()},d=s?ZT(s):Zb(o,a,l),c=XT(u||(s?Jo(s):tm(o,t))),f=r.headers||(typeof Request<"u"&&Vi(e,Request)?e.headers:void 0);if(f)if(typeof Headers<"u"&&Vi(f,Headers)){const p=new Headers(f);if(p.set("sentry-trace",d),c){const g=p.get(kl);if(g){const m=ff(g);p.set(kl,m?`${m},${c}`:c)}else p.set(kl,c)}return p}else if(Array.isArray(f)){const p=[...f.filter(g=>!(Array.isArray(g)&&g[0]==="sentry-trace")).map(g=>{if(Array.isArray(g)&&g[0]===kl&&typeof g[1]=="string"){const[m,y,...b]=g;return[m,ff(y),...b]}else return g}),["sentry-trace",d]];return c&&p.push([kl,c]),p}else{const p="baggage"in f?f.baggage:void 0;let g=[];return Array.isArray(p)?g=p.map(m=>typeof m=="string"?ff(m):m).filter(m=>m===""):p&&g.push(ff(p)),c&&g.push(c),{...f,"sentry-trace":d,baggage:g.length>0?g.join(","):void 0}}else return{"sentry-trace":d,baggage:c}}function TH(e){try{return new URL(e).href}catch{return}}function RH(e,t){if(t.response){KT(e,t.response.status);const n=t.response&&t.response.headers&&t.response.headers.get("content-length");if(n){const r=parseInt(n);r>0&&e.setAttribute("http.response_content_length",r)}}else t.error&&e.setStatus({code:In,message:"internal_error"});e.end()}function ff(e){return e.split(",").filter(t=>!t.split("=")[0].startsWith(Jb)).join(",")}function xR(e){if(e!==void 0)return e>=400&&e<500?"warning":e>=500?"error":void 0}const Kv=ft;function ER(){if(!("fetch"in Kv))return!1;try{return new Headers,new Request("http://www.example.com"),new Response,!0}catch{return!1}}function Yv(e){return e&&/^function\s+\w+\(\)\s+\{\s+\[native code\]\s+\}$/.test(e.toString())}function IH(){if(typeof EdgeRuntime=="string")return!0;if(!ER())return!1;if(Yv(Kv.fetch))return!0;let e=!1;const t=Kv.document;if(t&&typeof t.createElement=="function")try{const n=t.createElement("iframe");n.hidden=!0,t.head.appendChild(n),n.contentWindow&&n.contentWindow.fetch&&(e=Yv(n.contentWindow.fetch)),t.head.removeChild(n)}catch(n){Yo&&Pe.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",n)}return e}function CR(e,t){const n="fetch";Xo(n,e),Qo(n,()=>PR(void 0,t))}function AH(e){const t="fetch-body-resolved";Xo(t,e),Qo(t,()=>PR(MH))}function PR(e,t=!1){t&&!IH()||Tr(ft,"fetch",function(n){return function(...r){const{method:s,url:i}=DH(r),o={args:r,fetchData:{method:s,url:i},startTimestamp:nr()*1e3};e||fs("fetch",{...o});const a=new Error().stack;return n.apply(ft,r).then(async l=>(e?e(l):fs("fetch",{...o,endTimestamp:nr()*1e3,response:l}),l),l=>{throw fs("fetch",{...o,endTimestamp:nr()*1e3,error:l}),qb(l)&&l.stack===void 0&&(l.stack=a,ms(l,"framesToPop",1)),l})}})}async function OH(e,t){if(e&&e.body){const n=e.body,r=n.getReader(),s=setTimeout(()=>{n.cancel().then(null,()=>{})},90*1e3);let i=!0;for(;i;){let o;try{o=setTimeout(()=>{n.cancel().then(null,()=>{})},5e3);const{done:a}=await r.read();clearTimeout(o),a&&(t(),i=!1)}catch{i=!1}finally{clearTimeout(o)}}clearTimeout(s),r.releaseLock(),n.cancel().then(null,()=>{})}}function MH(e){let t;try{t=e.clone()}catch{return}OH(t,()=>{fs("fetch-body-resolved",{endTimestamp:nr()*1e3,response:e})})}function Xv(e,t){return!!e&&typeof e=="object"&&!!e[t]}function r1(e){return typeof e=="string"?e:e?Xv(e,"url")?e.url:e.toString?e.toString():"":""}function DH(e){if(e.length===0)return{method:"GET",url:""};if(e.length===2){const[n,r]=e;return{url:r1(n),method:Xv(r,"method")?String(r.method).toUpperCase():"GET"}}const t=e[0];return{url:r1(t),method:Xv(t,"method")?String(t.method).toUpperCase():"GET"}}function LH(){return typeof __SENTRY_BROWSER_BUNDLE__<"u"&&!!__SENTRY_BROWSER_BUNDLE__}function $H(){return"npm"}function FH(){return!LH()&&Object.prototype.toString.call(typeof process<"u"?process:0)==="[object process]"}function s1(){return typeof window<"u"&&(!FH()||NH())}function NH(){return ft.process!==void 0&&ft.process.type==="renderer"}const hf=ft;function BH(){const e=hf.chrome,t=e&&e.app&&e.app.runtime,n="history"in hf&&!!hf.history.pushState&&!!hf.history.replaceState;return!t&&n}function VH(e,t){return e??t()}function Gr(e){let t,n=e[0],r=1;for(;r<e.length;){const s=e[r],i=e[r+1];if(r+=2,(s==="optionalAccess"||s==="optionalCall")&&n==null)return;s==="access"||s==="optionalAccess"?(t=n,n=i(n)):(s==="call"||s==="optionalCall")&&(n=i((...o)=>n.call(t,...o)),t=void 0)}return n}const Ze=ft;let Qv=0;function TR(){return Qv>0}function UH(){Qv++,setTimeout(()=>{Qv--})}function fu(e,t={},n){if(typeof e!="function")return e;try{const s=e.__sentry_wrapped__;if(s)return typeof s=="function"?s:e;if(Kb(e))return e}catch{return e}const r=function(){const s=Array.prototype.slice.call(arguments);try{const i=s.map(o=>fu(o,t));return e.apply(this,i)}catch(i){throw UH(),Xb(o=>{o.addEventProcessor(a=>(t.mechanism&&(Nv(a,void 0),Kc(a,t.mechanism)),a.extra={...a.extra,arguments:s},a)),li(i)}),i}};try{for(const s in e)Object.prototype.hasOwnProperty.call(e,s)&&(r[s]=e[s])}catch{}HT(r,e),ms(e,"__sentry_wrapped__",r);try{Object.getOwnPropertyDescriptor(r,"name").configurable&&Object.defineProperty(r,"name",{get(){return e.name}})}catch{}return r}const As=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__;function rw(e,t){const n=sw(e,t),r={type:WH(t),value:GH(t)};return n.length&&(r.stacktrace={frames:n}),r.type===void 0&&r.value===""&&(r.value="Unrecoverable error caught"),r}function HH(e,t,n,r){const s=dt(),i=s&&s.getOptions().normalizeDepth,o=JH(t),a={__serialized__:oR(t,i)};if(o)return{exception:{values:[rw(e,o)]},extra:a};const l={exception:{values:[{type:Xp(t)?t.constructor.name:r?"UnhandledRejection":"Error",value:XH(t,{isUnhandledRejection:r})}]},extra:a};if(n){const u=sw(e,n);u.length&&(l.exception.values[0].stacktrace={frames:u})}return l}function dg(e,t){return{exception:{values:[rw(e,t)]}}}function sw(e,t){const n=t.stacktrace||t.stack||"",r=jH(t),s=qH(t);try{return e(n,r,s)}catch{}return[]}const zH=/Minified React error #\d+;/i;function jH(e){return e&&zH.test(e.message)?1:0}function qH(e){return typeof e.framesToPop=="number"?e.framesToPop:0}function RR(e){return typeof WebAssembly<"u"&&typeof WebAssembly.Exception<"u"?e instanceof WebAssembly.Exception:!1}function WH(e){const t=e&&e.name;return!t&&RR(e)?e.message&&Array.isArray(e.message)&&e.message.length==2?e.message[0]:"WebAssembly.Exception":t}function GH(e){const t=e&&e.message;return t?t.error&&typeof t.error.message=="string"?t.error.message:RR(e)&&Array.isArray(e.message)&&e.message.length==2?e.message[1]:t:"No error message"}function KH(e,t,n,r){const s=n&&n.syntheticException||void 0,i=iw(e,t,s,r);return Kc(i),i.level="error",n&&n.event_id&&(i.event_id=n.event_id),Hi(i)}function YH(e,t,n="info",r,s){const i=r&&r.syntheticException||void 0,o=Jv(e,t,i,s);return o.level=n,r&&r.event_id&&(o.event_id=r.event_id),Hi(o)}function iw(e,t,n,r,s){let i;if(NT(t)&&t.error)return dg(e,t.error);if(E0(t)||BB(t)){const o=t;if("stack"in t)i=dg(e,t);else{const a=o.name||(E0(o)?"DOMError":"DOMException"),l=o.message?`${a}: ${o.message}`:a;i=Jv(e,l,n,r),Nv(i,l)}return"code"in o&&(i.tags={...i.tags,"DOMException.code":`${o.code}`}),i}return qb(t)?dg(e,t):uu(t)||Xp(t)?(i=HH(e,t,n,s),Kc(i,{synthetic:!0}),i):(i=Jv(e,t,n,r),Nv(i,`${t}`),Kc(i,{synthetic:!0}),i)}function Jv(e,t,n,r){const s={};if(r&&n){const i=sw(e,n);i.length&&(s.exception={values:[{value:t,stacktrace:{frames:i}}]})}if(Wb(t)){const{__sentry_template_string__:i,__sentry_template_values__:o}=t;return s.logentry={message:i,params:o},s}return s.message=t,s}function XH(e,{isUnhandledRejection:t}){const n=KB(e),r=t?"promise rejection":"exception";return NT(e)?`Event \`ErrorEvent\` captured as ${r} with message \`${e.message}\``:Xp(e)?`Event \`${QH(e)}\` (type=${e.type}) captured as ${r}`:`Object captured as ${r} with keys: ${n}`}function QH(e){try{const t=Object.getPrototypeOf(e);return t?t.constructor.name:void 0}catch{}}function JH(e){for(const t in e)if(Object.prototype.hasOwnProperty.call(e,t)){const n=e[t];if(n instanceof Error)return n}}function ZH(e,{metadata:t,tunnel:n,dsn:r}){const s={event_id:e.event_id,sent_at:new Date().toISOString(),...t&&t.sdk&&{sdk:{name:t.sdk.name,version:t.sdk.version}},...!!n&&!!r&&{dsn:Fd(r)}},i=ez(e);return sl(s,[i])}function ez(e){return[{type:"user_report"},e]}class tz extends $U{constructor(t){const n={parentSpanIsAlwaysRootSpan:!0,...t},r=Ze.SENTRY_SDK_SOURCE||$H();XU(n,"browser",["browser"],r),super(n),n.sendClientReports&&Ze.document&&Ze.document.addEventListener("visibilitychange",()=>{Ze.document.visibilityState==="hidden"&&this._flushOutcomes()})}eventFromException(t,n){return KH(this._options.stackParser,t,n,this._options.attachStacktrace)}eventFromMessage(t,n="info",r){return YH(this._options.stackParser,t,n,r,this._options.attachStacktrace)}captureUserFeedback(t){if(!this._isEnabled()){As&&Pe.warn("SDK not enabled, will not capture user feedback.");return}const n=ZH(t,{metadata:this.getSdkMetadata(),dsn:this.getDsn(),tunnel:this.getOptions().tunnel});this.sendEnvelope(n)}_prepareEvent(t,n,r){return t.platform=t.platform||"javascript",super._prepareEvent(t,n,r)}}const Zr=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,nz=(e,t)=>e>t[1]?"poor":e>t[0]?"needs-improvement":"good",Nu=(e,t,n,r)=>{let s,i;return o=>{t.value>=0&&(o||r)&&(i=t.value-(s||0),(i||s===void 0)&&(s=t.value,t.delta=i,t.rating=nz(t.value,n),e(t)))}},Ke=ft,rz=()=>`v3-${Date.now()}-${Math.floor(Math.random()*(9e12-1))+1e12}`,Nd=()=>Ke.performance&&performance.getEntriesByType&&performance.getEntriesByType("navigation")[0],Bd=()=>{const e=Nd();return e&&e.activationStart||0},Bu=(e,t)=>{const n=Nd();let r="navigate";return n&&(Ke.document&&Ke.document.prerendering||Bd()>0?r="prerender":Ke.document&&Ke.document.wasDiscarded?r="restore":n.type&&(r=n.type.replace(/_/g,"-"))),{name:e,value:typeof t>"u"?-1:t,rating:"good",delta:0,entries:[],id:rz(),navigationType:r}},il=(e,t,n)=>{try{if(PerformanceObserver.supportedEntryTypes.includes(e)){const r=new PerformanceObserver(s=>{Promise.resolve().then(()=>{t(s.getEntries())})});return r.observe(Object.assign({type:e,buffered:!0},n||{})),r}}catch{}},Vd=e=>{const t=n=>{(n.type==="pagehide"||Ke.document&&Ke.document.visibilityState==="hidden")&&e(n)};Ke.document&&(addEventListener("visibilitychange",t,!0),addEventListener("pagehide",t,!0))},ow=e=>{let t=!1;return n=>{t||(e(n),t=!0)}};let Xc=-1;const sz=()=>{Xc=Ke.document.visibilityState==="hidden"&&!Ke.document.prerendering?0:1/0},qh=e=>{Ke.document.visibilityState==="hidden"&&Xc>-1&&(Xc=e.type==="visibilitychange"?e.timeStamp:0,removeEventListener("visibilitychange",qh,!0),removeEventListener("prerenderingchange",qh,!0))},iz=()=>{addEventListener("visibilitychange",qh,!0),addEventListener("prerenderingchange",qh,!0)},nm=()=>(Ke.document&&Xc<0&&(sz(),iz()),{get firstHiddenTime(){return Xc}}),Ud=e=>{Ke.document&&Ke.document.prerendering?addEventListener("prerenderingchange",()=>e(),!0):e()},oz=[1800,3e3],az=(e,t={})=>{Ud(()=>{const n=nm(),r=Bu("FCP");let s;const o=il("paint",a=>{a.forEach(l=>{l.name==="first-contentful-paint"&&(o.disconnect(),l.startTime<n.firstHiddenTime&&(r.value=Math.max(l.startTime-Bd(),0),r.entries.push(l),s(!0)))})});o&&(s=Nu(e,r,oz,t.reportAllChanges))})},lz=[.1,.25],uz=(e,t={})=>{az(ow(()=>{const n=Bu("CLS",0);let r,s=0,i=[];const o=l=>{l.forEach(u=>{if(!u.hadRecentInput){const d=i[0],c=i[i.length-1];s&&d&&c&&u.startTime-c.startTime<1e3&&u.startTime-d.startTime<5e3?(s+=u.value,i.push(u)):(s=u.value,i=[u])}}),s>n.value&&(n.value=s,n.entries=i,r())},a=il("layout-shift",o);a&&(r=Nu(e,n,lz,t.reportAllChanges),Vd(()=>{o(a.takeRecords()),r(!0)}),setTimeout(r,0))}))},cz=[100,300],dz=(e,t={})=>{Ud(()=>{const n=nm(),r=Bu("FID");let s;const i=l=>{l.startTime<n.firstHiddenTime&&(r.value=l.processingStart-l.startTime,r.entries.push(l),s(!0))},o=l=>{l.forEach(i)},a=il("first-input",o);s=Nu(e,r,cz,t.reportAllChanges),a&&Vd(ow(()=>{o(a.takeRecords()),a.disconnect()}))})};let IR=0,fg=1/0,pf=0;const fz=e=>{e.forEach(t=>{t.interactionId&&(fg=Math.min(fg,t.interactionId),pf=Math.max(pf,t.interactionId),IR=pf?(pf-fg)/7+1:0)})};let Zv;const hz=()=>Zv?IR:performance.interactionCount||0,pz=()=>{"interactionCount"in performance||Zv||(Zv=il("event",fz,{type:"event",buffered:!0,durationThreshold:0}))},mz=[200,500],gz=0,AR=()=>hz()-gz,i1=10,Ti=[],hg={},o1=e=>{const t=Ti[Ti.length-1],n=hg[e.interactionId];if(n||Ti.length<i1||t&&e.duration>t.latency){if(n)n.entries.push(e),n.latency=Math.max(n.latency,e.duration);else{const r={id:e.interactionId,latency:e.duration,entries:[e]};hg[r.id]=r,Ti.push(r)}Ti.sort((r,s)=>s.latency-r.latency),Ti.splice(i1).forEach(r=>{delete hg[r.id]})}},vz=()=>{const e=Math.min(Ti.length-1,Math.floor(AR()/50));return Ti[e]},yz=(e,t={})=>{Ud(()=>{pz();const n=Bu("INP");let r;const s=o=>{o.forEach(l=>{l.interactionId&&o1(l),l.entryType==="first-input"&&!Ti.some(d=>d.entries.some(c=>l.duration===c.duration&&l.startTime===c.startTime))&&o1(l)});const a=vz();a&&a.latency!==n.value&&(n.value=a.latency,n.entries=a.entries,r())},i=il("event",s,{durationThreshold:t.durationThreshold!=null?t.durationThreshold:40});r=Nu(e,n,mz,t.reportAllChanges),i&&("PerformanceEventTiming"in Ke&&"interactionId"in PerformanceEventTiming.prototype&&i.observe({type:"first-input",buffered:!0}),Vd(()=>{s(i.takeRecords()),n.value<0&&AR()>0&&(n.value=0,n.entries=[]),r(!0)}))})},bz=[2500,4e3],a1={},wz=(e,t={})=>{Ud(()=>{const n=nm(),r=Bu("LCP");let s;const i=a=>{const l=a[a.length-1];l&&l.startTime<n.firstHiddenTime&&(r.value=Math.max(l.startTime-Bd(),0),r.entries=[l],s())},o=il("largest-contentful-paint",i);if(o){s=Nu(e,r,bz,t.reportAllChanges);const a=ow(()=>{a1[r.id]||(i(o.takeRecords()),o.disconnect(),a1[r.id]=!0,s(!0))});["keydown","click"].forEach(l=>{Ke.document&&addEventListener(l,()=>setTimeout(a,0),!0)}),Vd(a)}})},Sz=[800,1800],ey=e=>{Ke.document&&Ke.document.prerendering?Ud(()=>ey(e)):Ke.document&&Ke.document.readyState!=="complete"?addEventListener("load",()=>ey(e),!0):setTimeout(e,0)},_z=(e,t={})=>{const n=Bu("TTFB"),r=Nu(e,n,Sz,t.reportAllChanges);ey(()=>{const s=Nd();if(s){const i=s.responseStart;if(i<=0||i>performance.now())return;n.value=Math.max(i-Bd(),0),n.entries=[s],r(!0)}})},xc={},Wh={};let OR,MR,DR,LR,$R;function aw(e,t=!1){return Hd("cls",e,xz,OR,t)}function FR(e,t=!1){return Hd("lcp",e,Cz,DR,t)}function NR(e){return Hd("fid",e,Ez,MR)}function kz(e){return Hd("ttfb",e,Pz,LR)}function BR(e){return Hd("inp",e,Tz,$R)}function hu(e,t){return VR(e,t),Wh[e]||(Rz(e),Wh[e]=!0),UR(e,t)}function Vu(e,t){const n=xc[e];if(!(!n||!n.length))for(const r of n)try{r(t)}catch(s){Zr&&Pe.error(`Error while triggering instrumentation handler.
48
+ Type: ${e}
49
+ Name: ${Bi(r)}
50
+ Error:`,s)}}function xz(){return uz(e=>{Vu("cls",{metric:e}),OR=e},{reportAllChanges:!0})}function Ez(){return dz(e=>{Vu("fid",{metric:e}),MR=e})}function Cz(){return wz(e=>{Vu("lcp",{metric:e}),DR=e},{reportAllChanges:!0})}function Pz(){return _z(e=>{Vu("ttfb",{metric:e}),LR=e})}function Tz(){return yz(e=>{Vu("inp",{metric:e}),$R=e})}function Hd(e,t,n,r,s=!1){VR(e,t);let i;return Wh[e]||(i=n(),Wh[e]=!0),r&&t({metric:r}),UR(e,t,s?i:void 0)}function Rz(e){const t={};e==="event"&&(t.durationThreshold=0),il(e,n=>{Vu(e,{entries:n})},t)}function VR(e,t){xc[e]=xc[e]||[],xc[e].push(t)}function UR(e,t,n){return()=>{n&&n();const r=xc[e];if(!r)return;const s=r.indexOf(t);s!==-1&&r.splice(s,1)}}function Iz(e){return"duration"in e}function pg(e){return typeof e=="number"&&isFinite(e)}function zi(e,t,n,{...r}){const s=ut(e).start_timestamp;return s&&s>t&&typeof e.updateStartTime=="function"&&e.updateStartTime(t),uR(e,()=>{const i=qa({startTime:t,...r});return i&&i.end(n),i})}function HR(e){const t=dt();if(!t)return;const{name:n,transaction:r,attributes:s,startTime:i}=e,{release:o,environment:a}=t.getOptions(),l=t.getIntegrationByName("Replay"),u=l&&l.getReplayId(),d=Bt(),c=d.getUser(),f=c!==void 0?c.email||c.id||c.ip_address:void 0;let p;try{p=d.getScopeData().contexts.profile.profile_id}catch{}const g={release:o,environment:a,user:f||void 0,profile_id:p||void 0,replay_id:u||void 0,transaction:r,"user_agent.original":Ke.navigator&&Ke.navigator.userAgent,...s};return qa({name:n,attributes:g,startTime:i,experimental:{standalone:!0}})}function lw(){return Ke&&Ke.addEventListener&&Ke.performance}function pn(e){return e/1e3}function Az(){let e=0,t,n;if(!Mz())return;let r=!1;function s(){r||(r=!0,n&&Oz(e,t,n),i())}const i=aw(({metric:o})=>{const a=o.entries[o.entries.length-1];a&&(e=o.value,t=a)},!0);Vd(()=>{s()}),setTimeout(()=>{const o=dt(),a=Gr([o,"optionalAccess",c=>c.on,"call",c=>c("startNavigationSpan",()=>{s(),a&&a()})]),l=Rn(),u=l&&Ln(l),d=u&&ut(u);d&&d.op==="pageload"&&(n=u.spanContext().spanId)},0)}function Oz(e,t,n){Zr&&Pe.log(`Sending CLS span (${e})`);const r=pn((gr||0)+(Gr([t,"optionalAccess",l=>l.startTime])||0)),s=Bt().getScopeData().transactionName,i=t?Ui(Gr([t,"access",l=>l.sources,"access",l=>l[0],"optionalAccess",l=>l.node])):"Layout shift",o=En({[ln]:"auto.http.browser.cls",[ja]:"ui.webvital.cls",[Qb]:Gr([t,"optionalAccess",l=>l.duration])||0,"sentry.pageload.span_id":n}),a=HR({name:i,transaction:s,attributes:o,startTime:r});Gr([a,"optionalAccess",l=>l.addEvent,"call",l=>l("cls",{[Zp]:"",[em]:e})]),Gr([a,"optionalAccess",l=>l.end,"call",l=>l(r)])}function Mz(){try{return Gr([PerformanceObserver,"access",e=>e.supportedEntryTypes,"optionalAccess",e=>e.includes,"call",e=>e("layout-shift")])}catch{return!1}}const Dz=2147483647;let l1=0,Vn={},Sr,Ec;function Lz({recordClsStandaloneSpans:e}){const t=lw();if(t&&gr){t.mark&&Ke.performance.mark("sentry-tracing-init");const n=Uz(),r=Vz(),s=Hz(),i=e?Az():Bz();return()=>{n(),r(),s(),i&&i()}}return()=>{}}function $z(){hu("longtask",({entries:e})=>{const t=Rn();if(!t)return;const{op:n,start_timestamp:r}=ut(t);for(const s of e){const i=pn(gr+s.startTime),o=pn(s.duration);n==="navigation"&&r&&i<r||zi(t,i,i+o,{name:"Main UI thread blocked",op:"ui.long-task",attributes:{[ln]:"auto.ui.browser.metrics"}})}})}function Fz(){new PerformanceObserver(t=>{const n=Rn();if(n)for(const r of t.getEntries()){if(!r.scripts[0])continue;const s=pn(gr+r.startTime),{start_timestamp:i,op:o}=ut(n);if(o==="navigation"&&i&&s<i)continue;const a=pn(r.duration),l={[ln]:"auto.ui.browser.metrics"},u=r.scripts[0],{invoker:d,invokerType:c,sourceURL:f,sourceFunctionName:p,sourceCharPosition:g}=u;l["browser.script.invoker"]=d,l["browser.script.invoker_type"]=c,f&&(l["code.filepath"]=f),p&&(l["code.function"]=p),g!==-1&&(l["browser.script.source_char_position"]=g),zi(n,s,s+a,{name:"Main UI thread blocked",op:"ui.long-animation-frame",attributes:l})}}).observe({type:"long-animation-frame",buffered:!0})}function Nz(){hu("event",({entries:e})=>{const t=Rn();if(t){for(const n of e)if(n.name==="click"){const r=pn(gr+n.startTime),s=pn(n.duration),i={name:Ui(n.target),op:`ui.interaction.${n.name}`,startTime:r,attributes:{[ln]:"auto.ui.browser.metrics"}},o=UT(n.target);o&&(i.attributes["ui.component_name"]=o),zi(t,r,r+s,i)}}})}function Bz(){return aw(({metric:e})=>{const t=e.entries[e.entries.length-1];t&&(Zr&&Pe.log(`[Measurements] Adding CLS ${e.value}`),Vn.cls={value:e.value,unit:""},Ec=t)},!0)}function Vz(){return FR(({metric:e})=>{const t=e.entries[e.entries.length-1];t&&(Zr&&Pe.log("[Measurements] Adding LCP"),Vn.lcp={value:e.value,unit:"millisecond"},Sr=t)},!0)}function Uz(){return NR(({metric:e})=>{const t=e.entries[e.entries.length-1];if(!t)return;const n=pn(gr),r=pn(t.startTime);Zr&&Pe.log("[Measurements] Adding FID"),Vn.fid={value:e.value,unit:"millisecond"},Vn["mark.fid"]={value:n+r,unit:"second"}})}function Hz(){return kz(({metric:e})=>{e.entries[e.entries.length-1]&&(Zr&&Pe.log("[Measurements] Adding TTFB"),Vn.ttfb={value:e.value,unit:"millisecond"})})}function zz(e,t){const n=lw();if(!n||!Ke.performance.getEntries||!gr)return;Zr&&Pe.log("[Tracing] Adding & adjusting spans using Performance API");const r=pn(gr),s=n.getEntries(),{op:i,start_timestamp:o}=ut(e);if(s.slice(l1).forEach(a=>{const l=pn(a.startTime),u=pn(Math.max(0,a.duration));if(!(i==="navigation"&&o&&r+l<o))switch(a.entryType){case"navigation":{qz(e,a,r);break}case"mark":case"paint":case"measure":{jz(e,a,l,u,r);const d=nm(),c=a.startTime<d.firstHiddenTime;a.name==="first-paint"&&c&&(Zr&&Pe.log("[Measurements] Adding FP"),Vn.fp={value:a.startTime,unit:"millisecond"}),a.name==="first-contentful-paint"&&c&&(Zr&&Pe.log("[Measurements] Adding FCP"),Vn.fcp={value:a.startTime,unit:"millisecond"});break}case"resource":{Gz(e,a,a.name,l,u,r);break}}}),l1=Math.max(s.length-1,0),Kz(e),i==="pageload"){Xz(Vn);const a=Vn["mark.fid"];a&&Vn.fid&&(zi(e,a.value,a.value+pn(Vn.fid.value),{name:"first input delay",op:"ui.action",attributes:{[ln]:"auto.ui.browser.metrics"}}),delete Vn["mark.fid"]),(!("fcp"in Vn)||!t.recordClsOnPageloadSpan)&&delete Vn.cls,Object.entries(Vn).forEach(([l,u])=>{XV(l,u.value,u.unit)}),e.setAttribute("performance.timeOrigin",r),e.setAttribute("performance.activationStart",Bd()),Yz(e)}Sr=void 0,Ec=void 0,Vn={}}function jz(e,t,n,r,s){const i=Nd(),o=pn(i?i.requestStart:0),a=s+Math.max(n,o),l=s+n,u=l+r,d={[ln]:"auto.resource.browser.metrics"};return a!==l&&(d["sentry.browser.measure_happened_before_request"]=!0,d["sentry.browser.measure_start_time"]=a),zi(e,a,u,{name:t.name,op:t.entryType,attributes:d}),a}function qz(e,t,n){["unloadEvent","redirect","domContentLoadedEvent","loadEvent","connect"].forEach(r=>{mf(e,t,r,n)}),mf(e,t,"secureConnection",n,"TLS/SSL","connectEnd"),mf(e,t,"fetch",n,"cache","domainLookupStart"),mf(e,t,"domainLookup",n,"DNS"),Wz(e,t,n)}function mf(e,t,n,r,s,i){const o=i?t[i]:t[`${n}End`],a=t[`${n}Start`];!a||!o||zi(e,r+pn(a),r+pn(o),{op:`browser.${s||n}`,name:t.name,attributes:{[ln]:"auto.ui.browser.metrics"}})}function Wz(e,t,n){const r=n+pn(t.requestStart),s=n+pn(t.responseEnd),i=n+pn(t.responseStart);t.responseEnd&&(zi(e,r,s,{op:"browser.request",name:t.name,attributes:{[ln]:"auto.ui.browser.metrics"}}),zi(e,i,s,{op:"browser.response",name:t.name,attributes:{[ln]:"auto.ui.browser.metrics"}}))}function Gz(e,t,n,r,s,i){if(t.initiatorType==="xmlhttprequest"||t.initiatorType==="fetch")return;const o=Da(n),a={[ln]:"auto.resource.browser.metrics"};mg(a,t,"transferSize","http.response_transfer_size"),mg(a,t,"encodedBodySize","http.response_content_length"),mg(a,t,"decodedBodySize","http.decoded_response_content_length"),t.deliveryType!=null&&(a["http.response_delivery_type"]=t.deliveryType),"renderBlockingStatus"in t&&(a["resource.render_blocking_status"]=t.renderBlockingStatus),o.protocol&&(a["url.scheme"]=o.protocol.split(":").pop()),o.host&&(a["server.address"]=o.host),a["url.same_origin"]=n.includes(Ke.location.origin);const l=i+r,u=l+s;zi(e,l,u,{name:n.replace(Ke.location.origin,""),op:t.initiatorType?`resource.${t.initiatorType}`:"resource.other",attributes:a})}function Kz(e){const t=Ke.navigator;if(!t)return;const n=t.connection;n&&(n.effectiveType&&e.setAttribute("effectiveConnectionType",n.effectiveType),n.type&&e.setAttribute("connectionType",n.type),pg(n.rtt)&&(Vn["connection.rtt"]={value:n.rtt,unit:"millisecond"})),pg(t.deviceMemory)&&e.setAttribute("deviceMemory",`${t.deviceMemory} GB`),pg(t.hardwareConcurrency)&&e.setAttribute("hardwareConcurrency",String(t.hardwareConcurrency))}function Yz(e){Sr&&(Zr&&Pe.log("[Measurements] Adding LCP Data"),Sr.element&&e.setAttribute("lcp.element",Ui(Sr.element)),Sr.id&&e.setAttribute("lcp.id",Sr.id),Sr.url&&e.setAttribute("lcp.url",Sr.url.trim().slice(0,200)),Sr.loadTime!=null&&e.setAttribute("lcp.loadTime",Sr.loadTime),Sr.renderTime!=null&&e.setAttribute("lcp.renderTime",Sr.renderTime),e.setAttribute("lcp.size",Sr.size)),Ec&&Ec.sources&&(Zr&&Pe.log("[Measurements] Adding CLS Data"),Ec.sources.forEach((t,n)=>e.setAttribute(`cls.source.${n+1}`,Ui(t.node))))}function mg(e,t,n,r){const s=t[n];s!=null&&s<Dz&&(e[r]=s)}function Xz(e){const t=Nd();if(!t)return;const{responseStart:n,requestStart:r}=t;r<=n&&(Zr&&Pe.log("[Measurements] Adding TTFB Request Time"),e["ttfb.requestTime"]={value:n-r,unit:"millisecond"})}const Qz=1e3;let u1,ty,ny;function zR(e){const t="dom";Xo(t,e),Qo(t,Jz)}function Jz(){if(!Ke.document)return;const e=fs.bind(null,"dom"),t=c1(e,!0);Ke.document.addEventListener("click",t,!1),Ke.document.addEventListener("keypress",t,!1),["EventTarget","Node"].forEach(n=>{const r=Ke[n]&&Ke[n].prototype;!r||!r.hasOwnProperty||!r.hasOwnProperty("addEventListener")||(Tr(r,"addEventListener",function(s){return function(i,o,a){if(i==="click"||i=="keypress")try{const l=this,u=l.__sentry_instrumentation_handlers__=l.__sentry_instrumentation_handlers__||{},d=u[i]=u[i]||{refCount:0};if(!d.handler){const c=c1(e);d.handler=c,s.call(this,i,c,a)}d.refCount++}catch{}return s.call(this,i,o,a)}}),Tr(r,"removeEventListener",function(s){return function(i,o,a){if(i==="click"||i=="keypress")try{const l=this,u=l.__sentry_instrumentation_handlers__||{},d=u[i];d&&(d.refCount--,d.refCount<=0&&(s.call(this,i,d.handler,a),d.handler=void 0,delete u[i]),Object.keys(u).length===0&&delete l.__sentry_instrumentation_handlers__)}catch{}return s.call(this,i,o,a)}}))})}function Zz(e){if(e.type!==ty)return!1;try{if(!e.target||e.target._sentryId!==ny)return!1}catch{}return!0}function e3(e,t){return e!=="keypress"?!1:!t||!t.tagName?!0:!(t.tagName==="INPUT"||t.tagName==="TEXTAREA"||t.isContentEditable)}function c1(e,t=!1){return n=>{if(!n||n._sentryCaptured)return;const r=t3(n);if(e3(n.type,r))return;ms(n,"_sentryCaptured",!0),r&&!r._sentryId&&ms(r,"_sentryId",tn());const s=n.type==="keypress"?"input":n.type;Zz(n)||(e({event:n,name:s,global:t}),ty=n.type,ny=r?r._sentryId:void 0),clearTimeout(u1),u1=Ke.setTimeout(()=>{ny=void 0,ty=void 0},Qz)}}function t3(e){try{return e.target}catch{return null}}let gf;function rm(e){const t="history";Xo(t,e),Qo(t,n3)}function n3(){if(!BH())return;const e=Ke.onpopstate;Ke.onpopstate=function(...n){const r=Ke.location.href,s=gf;if(gf=r,fs("history",{from:s,to:r}),e)try{return e.apply(this,n)}catch{}};function t(n){return function(...r){const s=r.length>2?r[2]:void 0;if(s){const i=gf,o=String(s);gf=o,fs("history",{from:i,to:o})}return n.apply(this,r)}}Tr(Ke.history,"pushState",t),Tr(Ke.history,"replaceState",t)}const rh={};function jR(e){const t=rh[e];if(t)return t;let n=Ke[e];if(Yv(n))return rh[e]=n.bind(Ke);const r=Ke.document;if(r&&typeof r.createElement=="function")try{const s=r.createElement("iframe");s.hidden=!0,r.head.appendChild(s);const i=s.contentWindow;i&&i[e]&&(n=i[e]),r.head.removeChild(s)}catch(s){Zr&&Pe.warn(`Could not create sandbox iframe for ${e} check, bailing to window.${e}: `,s)}return n&&(rh[e]=n.bind(Ke))}function d1(e){rh[e]=void 0}function pu(...e){return jR("setTimeout")(...e)}const ya="__sentry_xhr_v3__";function qR(e){const t="xhr";Xo(t,e),Qo(t,r3)}function r3(){if(!Ke.XMLHttpRequest)return;const e=XMLHttpRequest.prototype;e.open=new Proxy(e.open,{apply(t,n,r){const s=nr()*1e3,i=Di(r[0])?r[0].toUpperCase():void 0,o=s3(r[1]);if(!i||!o)return t.apply(n,r);n[ya]={method:i,url:o,request_headers:{}},i==="POST"&&o.match(/sentry_key/)&&(n.__sentry_own_request__=!0);const a=()=>{const l=n[ya];if(l&&n.readyState===4){try{l.status_code=n.status}catch{}const u={endTimestamp:nr()*1e3,startTimestamp:s,xhr:n};fs("xhr",u)}};return"onreadystatechange"in n&&typeof n.onreadystatechange=="function"?n.onreadystatechange=new Proxy(n.onreadystatechange,{apply(l,u,d){return a(),l.apply(u,d)}}):n.addEventListener("readystatechange",a),n.setRequestHeader=new Proxy(n.setRequestHeader,{apply(l,u,d){const[c,f]=d,p=u[ya];return p&&Di(c)&&Di(f)&&(p.request_headers[c.toLowerCase()]=f),l.apply(u,d)}}),t.apply(n,r)}}),e.send=new Proxy(e.send,{apply(t,n,r){const s=n[ya];if(!s)return t.apply(n,r);r[0]!==void 0&&(s.body=r[0]);const i={startTimestamp:nr()*1e3,xhr:n};return fs("xhr",i),t.apply(n,r)}})}function s3(e){if(Di(e))return e;try{return e.toString()}catch{}}const gg=[],sh=new Map;function i3(){if(lw()&&gr){const t=o3();return()=>{t()}}return()=>{}}const f1={click:"click",pointerdown:"click",pointerup:"click",mousedown:"click",mouseup:"click",touchstart:"click",touchend:"click",mouseover:"hover",mouseout:"hover",mouseenter:"hover",mouseleave:"hover",pointerover:"hover",pointerout:"hover",pointerenter:"hover",pointerleave:"hover",dragstart:"drag",dragend:"drag",drag:"drag",dragenter:"drag",dragleave:"drag",dragover:"drag",drop:"drag",keydown:"press",keyup:"press",keypress:"press",input:"press"};function o3(){return BR(({metric:e})=>{if(e.value==null)return;const t=e.entries.find(g=>g.duration===e.value&&f1[g.name]);if(!t)return;const{interactionId:n}=t,r=f1[t.name],s=pn(gr+t.startTime),i=pn(e.value),o=Rn(),a=o?Ln(o):void 0,u=(n!=null?sh.get(n):void 0)||a,d=u?ut(u).description:Bt().getScopeData().transactionName,c=Ui(t.target),f=En({[ln]:"auto.http.browser.inp",[ja]:`ui.interaction.${r}`,[Qb]:t.duration}),p=HR({name:c,transaction:d,attributes:f,startTime:s});Gr([p,"optionalAccess",g=>g.addEvent,"call",g=>g("inp",{[Zp]:"millisecond",[em]:e.value})]),Gr([p,"optionalAccess",g=>g.end,"call",g=>g(s+i)])})}function a3(e){const t=({entries:n})=>{const r=Rn(),s=r&&Ln(r);n.forEach(i=>{if(!Iz(i)||!s)return;const o=i.interactionId;if(o!=null&&!sh.has(o)){if(gg.length>10){const a=gg.shift();sh.delete(a)}gg.push(o),sh.set(o,s)}})};hu("event",t),hu("first-input",t)}function l3(e,t=jR("fetch")){let n=0,r=0;function s(i){const o=i.body.length;n+=o,r++;const a={body:i.body,method:"POST",referrerPolicy:"origin",headers:e.headers,keepalive:n<=6e4&&r<15,...e.fetchOptions};if(!t)return d1("fetch"),Vh("No fetch implementation available");try{return t(e.url,a).then(l=>(n-=o,r--,{statusCode:l.status,headers:{"x-sentry-rate-limits":l.headers.get("X-Sentry-Rate-Limits"),"retry-after":l.headers.get("Retry-After")}}))}catch(l){return d1("fetch"),n-=o,r--,Vh(l)}}return WU(e,s)}const u3=30,c3=50;function ry(e,t,n,r){const s={filename:e,function:t==="<anonymous>"?za:t,in_app:!0};return n!==void 0&&(s.lineno=n),r!==void 0&&(s.colno=r),s}const d3=/^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i,f3=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,h3=/\((\S*)(?::(\d+))(?::(\d+))\)/,p3=e=>{const t=d3.exec(e);if(t){const[,r,s,i]=t;return ry(r,za,+s,+i)}const n=f3.exec(e);if(n){if(n[2]&&n[2].indexOf("eval")===0){const o=h3.exec(n[2]);o&&(n[2]=o[1],n[3]=o[2],n[4]=o[3])}const[s,i]=WR(n[1]||za,n[2]);return ry(i,s,n[3]?+n[3]:void 0,n[4]?+n[4]:void 0)}},m3=[u3,p3],g3=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,v3=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,y3=e=>{const t=g3.exec(e);if(t){if(t[3]&&t[3].indexOf(" > eval")>-1){const i=v3.exec(t[3]);i&&(t[1]=t[1]||"eval",t[3]=i[1],t[4]=i[2],t[5]="")}let r=t[3],s=t[1]||za;return[s,r]=WR(s,r),ry(r,s,t[4]?+t[4]:void 0,t[5]?+t[5]:void 0)}},b3=[c3,y3],w3=[m3,b3],S3=DT(...w3),WR=(e,t)=>{const n=e.indexOf("safari-extension")!==-1,r=e.indexOf("safari-web-extension")!==-1;return n||r?[e.indexOf("@")!==-1?e.split("@")[0]:za,n?`safari-extension:${t}`:`safari-web-extension:${t}`]:[e,t]},vf=1024,_3="Breadcrumbs",k3=(e={})=>{const t={console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0,...e};return{name:_3,setup(n){t.console&&vH(P3(n)),t.dom&&zR(C3(n,t.dom)),t.xhr&&qR(T3(n)),t.fetch&&CR(R3(n)),t.history&&rm(I3(n)),t.sentry&&n.on("beforeSendEvent",E3(n))}}},x3=k3;function E3(e){return function(n){dt()===e&&No({category:`sentry.${n.type==="transaction"?"transaction":"event"}`,event_id:n.event_id,level:n.level,message:ao(n)},{event:n})}}function C3(e,t){return function(r){if(dt()!==e)return;let s,i,o=typeof t=="object"?t.serializeAttribute:void 0,a=typeof t=="object"&&typeof t.maxStringLength=="number"?t.maxStringLength:void 0;a&&a>vf&&(As&&Pe.warn(`\`dom.maxStringLength\` cannot exceed ${vf}, but a value of ${a} was configured. Sentry will use ${vf} instead.`),a=vf),typeof o=="string"&&(o=[o]);try{const u=r.event,d=A3(u)?u.target:u;s=Ui(d,{keyAttrs:o,maxStringLength:a}),i=UT(d)}catch{s="<unknown>"}if(s.length===0)return;const l={category:`ui.${r.name}`,message:s};i&&(l.data={"ui.component_name":i}),No(l,{event:r.event,name:r.name,global:r.global})}}function P3(e){return function(n){if(dt()!==e)return;const r={category:"console",data:{arguments:n.args,logger:"console"},level:SR(n.level),message:C0(n.args," ")};if(n.level==="assert")if(n.args[0]===!1)r.message=`Assertion failed: ${C0(n.args.slice(1)," ")||"console.assert"}`,r.data.arguments=n.args.slice(1);else return;No(r,{input:n.args,level:n.level})}}function T3(e){return function(n){if(dt()!==e)return;const{startTimestamp:r,endTimestamp:s}=n,i=n.xhr[ya];if(!r||!s||!i)return;const{method:o,url:a,status_code:l,body:u}=i,d={method:o,url:a,status_code:l},c={xhr:n.xhr,input:u,startTimestamp:r,endTimestamp:s},f=xR(l);No({category:"xhr",data:d,type:"http",level:f},c)}}function R3(e){return function(n){if(dt()!==e)return;const{startTimestamp:r,endTimestamp:s}=n;if(s&&!(n.fetchData.url.match(/sentry_key/)&&n.fetchData.method==="POST"))if(n.error){const i=n.fetchData,o={data:n.error,input:n.args,startTimestamp:r,endTimestamp:s};No({category:"fetch",data:i,level:"error",type:"http"},o)}else{const i=n.response,o={...n.fetchData,status_code:i&&i.status},a={input:n.args,response:i,startTimestamp:r,endTimestamp:s},l=xR(o.status_code);No({category:"fetch",data:o,type:"http",level:l},a)}}}function I3(e){return function(n){if(dt()!==e)return;let r=n.from,s=n.to;const i=Da(Ze.location.href);let o=r?Da(r):void 0;const a=Da(s);(!o||!o.path)&&(o=i),i.protocol===a.protocol&&i.host===a.host&&(s=a.relative),i.protocol===o.protocol&&i.host===o.host&&(r=o.relative),No({category:"navigation",data:{from:r,to:s}})}}function A3(e){return!!e&&!!e.target}const O3=["EventTarget","Window","Node","ApplicationCache","AudioTrackList","BroadcastChannel","ChannelMergerNode","CryptoOperation","EventSource","FileReader","HTMLUnknownElement","IDBDatabase","IDBRequest","IDBTransaction","KeyOperation","MediaController","MessagePort","ModalWindow","Notification","SVGElementInstance","Screen","SharedWorker","TextTrack","TextTrackCue","TextTrackList","WebSocket","WebSocketWorker","Worker","XMLHttpRequest","XMLHttpRequestEventTarget","XMLHttpRequestUpload"],M3="BrowserApiErrors",D3=(e={})=>{const t={XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0,...e};return{name:M3,setupOnce(){t.setTimeout&&Tr(Ze,"setTimeout",h1),t.setInterval&&Tr(Ze,"setInterval",h1),t.requestAnimationFrame&&Tr(Ze,"requestAnimationFrame",$3),t.XMLHttpRequest&&"XMLHttpRequest"in Ze&&Tr(XMLHttpRequest.prototype,"send",F3);const n=t.eventTarget;n&&(Array.isArray(n)?n:O3).forEach(N3)}}},L3=D3;function h1(e){return function(...t){const n=t[0];return t[0]=fu(n,{mechanism:{data:{function:Bi(e)},handled:!1,type:"instrument"}}),e.apply(this,t)}}function $3(e){return function(t){return e.apply(this,[fu(t,{mechanism:{data:{function:"requestAnimationFrame",handler:Bi(e)},handled:!1,type:"instrument"}})])}}function F3(e){return function(...t){const n=this;return["onload","onerror","onprogress","onreadystatechange"].forEach(s=>{s in n&&typeof n[s]=="function"&&Tr(n,s,function(i){const o={mechanism:{data:{function:s,handler:Bi(i)},handled:!1,type:"instrument"}},a=Kb(i);return a&&(o.mechanism.data.handler=Bi(a)),fu(i,o)})}),e.apply(this,t)}}function N3(e){const t=Ze,n=t[e]&&t[e].prototype;!n||!n.hasOwnProperty||!n.hasOwnProperty("addEventListener")||(Tr(n,"addEventListener",function(r){return function(s,i,o){try{typeof i.handleEvent=="function"&&(i.handleEvent=fu(i.handleEvent,{mechanism:{data:{function:"handleEvent",handler:Bi(i),target:e},handled:!1,type:"instrument"}}))}catch{}return r.apply(this,[s,fu(i,{mechanism:{data:{function:"addEventListener",handler:Bi(i),target:e},handled:!1,type:"instrument"}}),o])}}),Tr(n,"removeEventListener",function(r){return function(s,i,o){const a=i;try{const l=a&&a.__sentry_wrapped__;l&&r.call(this,s,l,o)}catch{}return r.call(this,s,a,o)}}))}const B3="GlobalHandlers",V3=(e={})=>{const t={onerror:!0,onunhandledrejection:!0,...e};return{name:B3,setupOnce(){Error.stackTraceLimit=50},setup(n){t.onerror&&(H3(n),p1("onerror")),t.onunhandledrejection&&(z3(n),p1("onunhandledrejection"))}}},U3=V3;function H3(e){LT(t=>{const{stackParser:n,attachStacktrace:r}=GR();if(dt()!==e||TR())return;const{msg:s,url:i,line:o,column:a,error:l}=t,u=W3(iw(n,l||s,void 0,r,!1),i,o,a);u.level="error",hR(u,{originalException:l,mechanism:{handled:!1,type:"onerror"}})})}function z3(e){$T(t=>{const{stackParser:n,attachStacktrace:r}=GR();if(dt()!==e||TR())return;const s=j3(t),i=Gb(s)?q3(s):iw(n,s,void 0,r,!0);i.level="error",hR(i,{originalException:s,mechanism:{handled:!1,type:"onunhandledrejection"}})})}function j3(e){if(Gb(e))return e;try{if("reason"in e)return e.reason;if("detail"in e&&"reason"in e.detail)return e.detail.reason}catch{}return e}function q3(e){return{exception:{values:[{type:"UnhandledRejection",value:`Non-Error promise rejection captured with value: ${String(e)}`}]}}}function W3(e,t,n,r){const s=e.exception=e.exception||{},i=s.values=s.values||[],o=i[0]=i[0]||{},a=o.stacktrace=o.stacktrace||{},l=a.frames=a.frames||[],u=isNaN(parseInt(r,10))?void 0:r,d=isNaN(parseInt(n,10))?void 0:n,c=Di(t)&&t.length>0?t:VT();return l.length===0&&l.push({colno:u,filename:c,function:za,in_app:!0,lineno:d}),e}function p1(e){As&&Pe.log(`Global Handler attached: ${e}`)}function GR(){const e=dt();return e&&e.getOptions()||{stackParser:()=>[],attachStacktrace:!1}}const G3=()=>({name:"HttpContext",preprocessEvent(e){if(!Ze.navigator&&!Ze.location&&!Ze.document)return;const t=e.request&&e.request.url||Ze.location&&Ze.location.href,{referrer:n}=Ze.document||{},{userAgent:r}=Ze.navigator||{},s={...e.request&&e.request.headers,...n&&{Referer:n},...r&&{"User-Agent":r}},i={...e.request,...t&&{url:t},headers:s};e.request=i}}),K3="cause",Y3=5,X3="LinkedErrors",Q3=(e={})=>{const t=e.limit||Y3,n=e.key||K3;return{name:X3,preprocessEvent(r,s,i){const o=i.getOptions();mH(rw,o.stackParser,o.maxValueLength,n,t,r,s)}}},J3=Q3;function KR(e){return[sH(),eH(),L3(),x3(),U3(),J3(),_H(),G3()]}function Z3(e={}){const t={defaultIntegrations:KR(),release:typeof __SENTRY_RELEASE__=="string"?__SENTRY_RELEASE__:Ze.SENTRY_RELEASE&&Ze.SENTRY_RELEASE.id?Ze.SENTRY_RELEASE.id:void 0,autoSessionTracking:!0,sendClientReports:!0};return e.defaultIntegrations==null&&delete e.defaultIntegrations,{...t,...e}}function e4(){const e=typeof Ze.window<"u"&&Ze;if(!e)return!1;const t=e.chrome?"chrome":"browser",n=e[t],r=n&&n.runtime&&n.runtime.id,s=Ze.location&&Ze.location.href||"",i=["chrome-extension:","moz-extension:","ms-browser-extension:","safari-web-extension:"],o=!!r&&Ze===Ze.top&&i.some(l=>s.startsWith(`${l}//`)),a=typeof e.nw<"u";return!!r&&!o&&!a}function t4(e={}){const t=Z3(e);if(!t.skipBrowserExtensionCheck&&e4()){Gi(()=>{console.error("[Sentry] You cannot run Sentry this way in a browser extension, check: https://docs.sentry.io/platforms/javascript/best-practices/browser-extensions/")});return}As&&(ER()||Pe.warn("No Fetch API detected. The Sentry SDK requires a Fetch API compatible environment to send events. Please add a Fetch API polyfill."));const n={...t,stackParser:LB(t.stackParser||S3),integrations:MU(t),transport:t.transport||l3},r=BU(tz,n);return t.autoSessionTracking&&n4(),r}function n4(){if(typeof Ze.document>"u"){As&&Pe.warn("Session tracking in non-browser environment with @sentry/browser is not supported.");return}q0({ignoreDuration:!0}),W0(),rm(({from:e,to:t})=>{e!==void 0&&e!==t&&(q0({ignoreDuration:!0}),W0())})}const zt=ft,uw="sentryReplaySession",r4="replay_event",cw="Unable to send Replay",s4=3e5,i4=9e5,o4=5e3,a4=5500,l4=6e4,u4=5e3,c4=3,m1=15e4,yf=5e3,d4=3e3,f4=300,dw=2e7,h4=4999,p4=15e3,g1=36e5;function sy(e,t){return e??t()}function Qc(e){let t,n=e[0],r=1;for(;r<e.length;){const s=e[r],i=e[r+1];if(r+=2,(s==="optionalAccess"||s==="optionalCall")&&n==null)return;s==="access"||s==="optionalAccess"?(t=n,n=i(n)):(s==="call"||s==="optionalCall")&&(n=i((...o)=>n.call(t,...o)),t=void 0)}return n}var _n;(function(e){e[e.Document=0]="Document",e[e.DocumentType=1]="DocumentType",e[e.Element=2]="Element",e[e.Text=3]="Text",e[e.CDATA=4]="CDATA",e[e.Comment=5]="Comment"})(_n||(_n={}));function m4(e){return e.nodeType===e.ELEMENT_NODE}function Cc(e){const t=Qc([e,"optionalAccess",n=>n.host]);return Qc([t,"optionalAccess",n=>n.shadowRoot])===e}function Pc(e){return Object.prototype.toString.call(e)==="[object ShadowRoot]"}function g4(e){return e.includes(" background-clip: text;")&&!e.includes(" -webkit-background-clip: text;")&&(e=e.replace(/\sbackground-clip:\s*text;/g," -webkit-background-clip: text; background-clip: text;")),e}function v4(e){const{cssText:t}=e;if(t.split('"').length<3)return t;const n=["@import",`url(${JSON.stringify(e.href)})`];return e.layerName===""?n.push("layer"):e.layerName&&n.push(`layer(${e.layerName})`),e.supportsText&&n.push(`supports(${e.supportsText})`),e.media.length&&n.push(e.media.mediaText),n.join(" ")+";"}function Gh(e){try{const t=e.rules||e.cssRules;return t?g4(Array.from(t,YR).join("")):null}catch{return null}}function YR(e){let t;if(b4(e))try{t=Gh(e.styleSheet)||v4(e)}catch{}else if(w4(e)&&e.selectorText.includes(":"))return y4(e.cssText);return t||e.cssText}function y4(e){const t=/(\[(?:[\w-]+)[^\\])(:(?:[\w-]+)\])/gm;return e.replace(t,"$1\\$2")}function b4(e){return"styleSheet"in e}function w4(e){return"selectorText"in e}class XR{constructor(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}getId(t){if(!t)return-1;const n=Qc([this,"access",r=>r.getMeta,"call",r=>r(t),"optionalAccess",r=>r.id]);return sy(n,()=>-1)}getNode(t){return this.idNodeMap.get(t)||null}getIds(){return Array.from(this.idNodeMap.keys())}getMeta(t){return this.nodeMetaMap.get(t)||null}removeNodeFromMap(t){const n=this.getId(t);this.idNodeMap.delete(n),t.childNodes&&t.childNodes.forEach(r=>this.removeNodeFromMap(r))}has(t){return this.idNodeMap.has(t)}hasNode(t){return this.nodeMetaMap.has(t)}add(t,n){const r=n.id;this.idNodeMap.set(r,t),this.nodeMetaMap.set(t,n)}replace(t,n){const r=this.getNode(t);if(r){const s=this.nodeMetaMap.get(r);s&&this.nodeMetaMap.set(n,s)}this.idNodeMap.set(t,n)}reset(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}}function S4(){return new XR}function sm({maskInputOptions:e,tagName:t,type:n}){return t==="OPTION"&&(t="SELECT"),!!(e[t.toLowerCase()]||n&&e[n]||n==="password"||t==="INPUT"&&!n&&e.text)}function Jc({isMasked:e,element:t,value:n,maskInputFn:r}){let s=n||"";return e?(r&&(s=r(s,t)),"*".repeat(s.length)):s}function mu(e){return e.toLowerCase()}function iy(e){return e.toUpperCase()}const v1="__rrweb_original__";function _4(e){const t=e.getContext("2d");if(!t)return!0;const n=50;for(let r=0;r<e.width;r+=n)for(let s=0;s<e.height;s+=n){const i=t.getImageData,o=v1 in i?i[v1]:i;if(new Uint32Array(o.call(t,r,s,Math.min(n,e.width-r),Math.min(n,e.height-s)).data.buffer).some(l=>l!==0))return!1}return!0}function fw(e){const t=e.type;return e.hasAttribute("data-rr-is-password")?"password":t?mu(t):null}function Kh(e,t,n){return t==="INPUT"&&(n==="radio"||n==="checkbox")?e.getAttribute("value")||"":e.value}function QR(e,t){let n;try{n=new URL(e,sy(t,()=>window.location.href))}catch{return null}const r=/\.([0-9a-z]+)(?:$)/i,s=n.pathname.match(r);return sy(Qc([s,"optionalAccess",i=>i[1]]),()=>null)}const y1={};function JR(e){const t=y1[e];if(t)return t;const n=window.document;let r=window[e];if(n&&typeof n.createElement=="function")try{const s=n.createElement("iframe");s.hidden=!0,n.head.appendChild(s);const i=s.contentWindow;i&&i[e]&&(r=i[e]),n.head.removeChild(s)}catch{}return y1[e]=r.bind(window)}function oy(...e){return JR("setTimeout")(...e)}function ZR(...e){return JR("clearTimeout")(...e)}let k4=1;const x4=new RegExp("[^a-z0-9-_:]"),Zc=-2;function hw(){return k4++}function E4(e){if(e instanceof HTMLFormElement)return"form";const t=mu(e.tagName);return x4.test(t)?"div":t}function C4(e){let t="";return e.indexOf("//")>-1?t=e.split("/").slice(0,3).join("/"):t=e.split("/")[0],t=t.split("?")[0],t}let hl,b1;const P4=/url\((?:(')([^']*)'|(")(.*?)"|([^)]*))\)/gm,T4=/^(?:[a-z+]+:)?\/\//i,R4=/^www\..*/i,I4=/^(data:)([^,]*),(.*)/i;function Yh(e,t){return(e||"").replace(P4,(n,r,s,i,o,a)=>{const l=s||o||a,u=r||i||"";if(!l)return n;if(T4.test(l)||R4.test(l))return`url(${u}${l}${u})`;if(I4.test(l))return`url(${u}${l}${u})`;if(l[0]==="/")return`url(${u}${C4(t)+l}${u})`;const d=t.split("/"),c=l.split("/");d.pop();for(const f of c)f!=="."&&(f===".."?d.pop():d.push(f));return`url(${u}${d.join("/")}${u})`})}const A4=/^[^ \t\n\r\u000c]+/,O4=/^[, \t\n\r\u000c]+/;function M4(e,t){if(t.trim()==="")return t;let n=0;function r(i){let o;const a=i.exec(t.substring(n));return a?(o=a[0],n+=o.length,o):""}const s=[];for(;r(O4),!(n>=t.length);){let i=r(A4);if(i.slice(-1)===",")i=Rl(e,i.substring(0,i.length-1)),s.push(i);else{let o="";i=Rl(e,i);let a=!1;for(;;){const l=t.charAt(n);if(l===""){s.push((i+o).trim());break}else if(a)l===")"&&(a=!1);else if(l===","){n+=1,s.push((i+o).trim());break}else l==="("&&(a=!0);o+=l,n+=1}}}return s.join(", ")}const w1=new WeakMap;function Rl(e,t){return!t||t.trim()===""?t:im(e,t)}function D4(e){return!!(e.tagName==="svg"||e.ownerSVGElement)}function im(e,t){let n=w1.get(e);if(n||(n=e.createElement("a"),w1.set(e,n)),!t)t="";else if(t.startsWith("blob:")||t.startsWith("data:"))return t;return n.setAttribute("href",t),n.href}function eI(e,t,n,r,s,i){return r&&(n==="src"||n==="href"&&!(t==="use"&&r[0]==="#")||n==="xlink:href"&&r[0]!=="#"||n==="background"&&(t==="table"||t==="td"||t==="th")?Rl(e,r):n==="srcset"?M4(e,r):n==="style"?Yh(r,im(e)):t==="object"&&n==="data"?Rl(e,r):typeof i=="function"?i(n,r,s):r)}function tI(e,t,n){return(e==="video"||e==="audio")&&t==="autoplay"}function L4(e,t,n,r){try{if(r&&e.matches(r))return!1;if(typeof t=="string"){if(e.classList.contains(t))return!0}else for(let s=e.classList.length;s--;){const i=e.classList[s];if(t.test(i))return!0}if(n)return e.matches(n)}catch{}return!1}function $4(e,t){for(let n=e.classList.length;n--;){const r=e.classList[n];if(t.test(r))return!0}return!1}function ba(e,t,n=1/0,r=0){return!e||e.nodeType!==e.ELEMENT_NODE||r>n?-1:t(e)?r:ba(e.parentNode,t,n,r+1)}function Il(e,t){return n=>{const r=n;if(r===null)return!1;try{if(e){if(typeof e=="string"){if(r.matches(`.${e}`))return!0}else if($4(r,e))return!0}return!!(t&&r.matches(t))}catch{return!1}}}function gu(e,t,n,r,s,i){try{const o=e.nodeType===e.ELEMENT_NODE?e:e.parentElement;if(o===null)return!1;if(o.tagName==="INPUT"){const u=o.getAttribute("autocomplete");if(["current-password","new-password","cc-number","cc-exp","cc-exp-month","cc-exp-year","cc-csc"].includes(u))return!0}let a=-1,l=-1;if(i){if(l=ba(o,Il(r,s)),l<0)return!0;a=ba(o,Il(t,n),l>=0?l:1/0)}else{if(a=ba(o,Il(t,n)),a<0)return!1;l=ba(o,Il(r,s),a>=0?a:1/0)}return a>=0?l>=0?a<=l:!0:l>=0?!1:!!i}catch{}return!!i}function F4(e,t,n){const r=e.contentWindow;if(!r)return;let s=!1,i;try{i=r.document.readyState}catch{return}if(i!=="complete"){const a=oy(()=>{s||(t(),s=!0)},n);e.addEventListener("load",()=>{ZR(a),s=!0,t()});return}const o="about:blank";if(r.location.href!==o||e.src===o||e.src==="")return oy(t,0),e.addEventListener("load",t);e.addEventListener("load",t)}function N4(e,t,n){let r=!1,s;try{s=e.sheet}catch{return}if(s)return;const i=oy(()=>{r||(t(),r=!0)},n);e.addEventListener("load",()=>{ZR(i),r=!0,t()})}function B4(e,t){const{doc:n,mirror:r,blockClass:s,blockSelector:i,unblockSelector:o,maskAllText:a,maskAttributeFn:l,maskTextClass:u,unmaskTextClass:d,maskTextSelector:c,unmaskTextSelector:f,inlineStylesheet:p,maskInputOptions:g={},maskTextFn:m,maskInputFn:y,dataURLOptions:b={},inlineImages:w,recordCanvas:S,keepIframeSrcFn:P,newlyAddedElement:E=!1}=t,T=V4(n,r);switch(e.nodeType){case e.DOCUMENT_NODE:return e.compatMode!=="CSS1Compat"?{type:_n.Document,childNodes:[],compatMode:e.compatMode}:{type:_n.Document,childNodes:[]};case e.DOCUMENT_TYPE_NODE:return{type:_n.DocumentType,name:e.name,publicId:e.publicId,systemId:e.systemId,rootId:T};case e.ELEMENT_NODE:return H4(e,{doc:n,blockClass:s,blockSelector:i,unblockSelector:o,inlineStylesheet:p,maskAttributeFn:l,maskInputOptions:g,maskInputFn:y,dataURLOptions:b,inlineImages:w,recordCanvas:S,keepIframeSrcFn:P,newlyAddedElement:E,rootId:T,maskAllText:a,maskTextClass:u,unmaskTextClass:d,maskTextSelector:c,unmaskTextSelector:f});case e.TEXT_NODE:return U4(e,{doc:n,maskAllText:a,maskTextClass:u,unmaskTextClass:d,maskTextSelector:c,unmaskTextSelector:f,maskTextFn:m,maskInputOptions:g,maskInputFn:y,rootId:T});case e.CDATA_SECTION_NODE:return{type:_n.CDATA,textContent:"",rootId:T};case e.COMMENT_NODE:return{type:_n.Comment,textContent:e.textContent||"",rootId:T};default:return!1}}function V4(e,t){if(!t.hasNode(e))return;const n=t.getId(e);return n===1?void 0:n}function U4(e,t){const{maskAllText:n,maskTextClass:r,unmaskTextClass:s,maskTextSelector:i,unmaskTextSelector:o,maskTextFn:a,maskInputOptions:l,maskInputFn:u,rootId:d}=t,c=e.parentNode&&e.parentNode.tagName;let f=e.textContent;const p=c==="STYLE"?!0:void 0,g=c==="SCRIPT"?!0:void 0,m=c==="TEXTAREA"?!0:void 0;if(p&&f){try{e.nextSibling||e.previousSibling||Qc([e,"access",b=>b.parentNode,"access",b=>b.sheet,"optionalAccess",b=>b.cssRules])&&(f=Gh(e.parentNode.sheet))}catch(b){console.warn(`Cannot get CSS styles from text's parentNode. Error: ${b}`,e)}f=Yh(f,im(t.doc))}g&&(f="SCRIPT_PLACEHOLDER");const y=gu(e,r,i,s,o,n);if(!p&&!g&&!m&&f&&y&&(f=a?a(f,e.parentElement):f.replace(/[\S]/g,"*")),m&&f&&(l.textarea||y)&&(f=u?u(f,e.parentNode):f.replace(/[\S]/g,"*")),c==="OPTION"&&f){const b=sm({type:null,tagName:c,maskInputOptions:l});f=Jc({isMasked:gu(e,r,i,s,o,b),element:e,value:f,maskInputFn:u})}return{type:_n.Text,textContent:f||"",isStyle:p,rootId:d}}function H4(e,t){const{doc:n,blockClass:r,blockSelector:s,unblockSelector:i,inlineStylesheet:o,maskInputOptions:a={},maskAttributeFn:l,maskInputFn:u,dataURLOptions:d={},inlineImages:c,recordCanvas:f,keepIframeSrcFn:p,newlyAddedElement:g=!1,rootId:m,maskAllText:y,maskTextClass:b,unmaskTextClass:w,maskTextSelector:S,unmaskTextSelector:P}=t,E=L4(e,r,s,i),T=E4(e);let C={};const k=e.attributes.length;for(let I=0;I<k;I++){const M=e.attributes[I];M.name&&!tI(T,M.name,M.value)&&(C[M.name]=eI(n,T,mu(M.name),M.value,e,l))}if(T==="link"&&o){const I=Array.from(n.styleSheets).find(O=>O.href===e.href);let M=null;I&&(M=Gh(I)),M&&(delete C.rel,delete C.href,C._cssText=Yh(M,I.href))}if(T==="style"&&e.sheet&&!(e.innerText||e.textContent||"").trim().length){const I=Gh(e.sheet);I&&(C._cssText=Yh(I,im(n)))}if(T==="input"||T==="textarea"||T==="select"||T==="option"){const I=e,M=fw(I),O=Kh(I,iy(T),M),A=I.checked;if(M!=="submit"&&M!=="button"&&O){const D=gu(I,b,S,w,P,sm({type:M,tagName:iy(T),maskInputOptions:a}));C.value=Jc({isMasked:D,element:I,value:O,maskInputFn:u})}A&&(C.checked=A)}if(T==="option"&&(e.selected&&!a.select?C.selected=!0:delete C.selected),T==="canvas"&&f){if(e.__context==="2d")_4(e)||(C.rr_dataURL=e.toDataURL(d.type,d.quality));else if(!("__context"in e)){const I=e.toDataURL(d.type,d.quality),M=n.createElement("canvas");M.width=e.width,M.height=e.height;const O=M.toDataURL(d.type,d.quality);I!==O&&(C.rr_dataURL=I)}}if(T==="img"&&c){hl||(hl=n.createElement("canvas"),b1=hl.getContext("2d"));const I=e,M=I.currentSrc||I.getAttribute("src")||"<unknown-src>",O=I.crossOrigin,A=()=>{I.removeEventListener("load",A);try{hl.width=I.naturalWidth,hl.height=I.naturalHeight,b1.drawImage(I,0,0),C.rr_dataURL=hl.toDataURL(d.type,d.quality)}catch(D){if(I.crossOrigin!=="anonymous"){I.crossOrigin="anonymous",I.complete&&I.naturalWidth!==0?A():I.addEventListener("load",A);return}else console.warn(`Cannot inline img src=${M}! Error: ${D}`)}I.crossOrigin==="anonymous"&&(O?C.crossOrigin=O:I.removeAttribute("crossorigin"))};I.complete&&I.naturalWidth!==0?A():I.addEventListener("load",A)}if((T==="audio"||T==="video")&&(C.rr_mediaState=e.paused?"paused":"played",C.rr_mediaCurrentTime=e.currentTime),g||(e.scrollLeft&&(C.rr_scrollLeft=e.scrollLeft),e.scrollTop&&(C.rr_scrollTop=e.scrollTop)),E){const{width:I,height:M}=e.getBoundingClientRect();C={class:C.class,rr_width:`${I}px`,rr_height:`${M}px`}}T==="iframe"&&!p(C.src)&&(!E&&!e.contentDocument&&(C.rr_src=C.src),delete C.src);let x;try{customElements.get(T)&&(x=!0)}catch{}return{type:_n.Element,tagName:T,attributes:C,childNodes:[],isSVG:D4(e)||void 0,needBlock:E,rootId:m,isCustom:x}}function Ut(e){return e==null?"":e.toLowerCase()}function z4(e,t){if(t.comment&&e.type===_n.Comment)return!0;if(e.type===_n.Element){if(t.script&&(e.tagName==="script"||e.tagName==="link"&&(e.attributes.rel==="preload"||e.attributes.rel==="modulepreload")&&e.attributes.as==="script"||e.tagName==="link"&&e.attributes.rel==="prefetch"&&typeof e.attributes.href=="string"&&QR(e.attributes.href)==="js"))return!0;if(t.headFavicon&&(e.tagName==="link"&&e.attributes.rel==="shortcut icon"||e.tagName==="meta"&&(Ut(e.attributes.name).match(/^msapplication-tile(image|color)$/)||Ut(e.attributes.name)==="application-name"||Ut(e.attributes.rel)==="icon"||Ut(e.attributes.rel)==="apple-touch-icon"||Ut(e.attributes.rel)==="shortcut icon")))return!0;if(e.tagName==="meta"){if(t.headMetaDescKeywords&&Ut(e.attributes.name).match(/^description|keywords$/))return!0;if(t.headMetaSocial&&(Ut(e.attributes.property).match(/^(og|twitter|fb):/)||Ut(e.attributes.name).match(/^(og|twitter):/)||Ut(e.attributes.name)==="pinterest"))return!0;if(t.headMetaRobots&&(Ut(e.attributes.name)==="robots"||Ut(e.attributes.name)==="googlebot"||Ut(e.attributes.name)==="bingbot"))return!0;if(t.headMetaHttpEquiv&&e.attributes["http-equiv"]!==void 0)return!0;if(t.headMetaAuthorship&&(Ut(e.attributes.name)==="author"||Ut(e.attributes.name)==="generator"||Ut(e.attributes.name)==="framework"||Ut(e.attributes.name)==="publisher"||Ut(e.attributes.name)==="progid"||Ut(e.attributes.property).match(/^article:/)||Ut(e.attributes.property).match(/^product:/)))return!0;if(t.headMetaVerification&&(Ut(e.attributes.name)==="google-site-verification"||Ut(e.attributes.name)==="yandex-verification"||Ut(e.attributes.name)==="csrf-token"||Ut(e.attributes.name)==="p:domain_verify"||Ut(e.attributes.name)==="verify-v1"||Ut(e.attributes.name)==="verification"||Ut(e.attributes.name)==="shopify-checkout-api-token"))return!0}}return!1}function Al(e,t){const{doc:n,mirror:r,blockClass:s,blockSelector:i,unblockSelector:o,maskAllText:a,maskTextClass:l,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:c,skipChild:f=!1,inlineStylesheet:p=!0,maskInputOptions:g={},maskAttributeFn:m,maskTextFn:y,maskInputFn:b,slimDOMOptions:w,dataURLOptions:S={},inlineImages:P=!1,recordCanvas:E=!1,onSerialize:T,onIframeLoad:C,iframeLoadTimeout:k=5e3,onStylesheetLoad:x,stylesheetLoadTimeout:I=5e3,keepIframeSrcFn:M=()=>!1,newlyAddedElement:O=!1}=t;let{preserveWhiteSpace:A=!0}=t;const D=B4(e,{doc:n,mirror:r,blockClass:s,blockSelector:i,maskAllText:a,unblockSelector:o,maskTextClass:l,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:c,inlineStylesheet:p,maskInputOptions:g,maskAttributeFn:m,maskTextFn:y,maskInputFn:b,dataURLOptions:S,inlineImages:P,recordCanvas:E,keepIframeSrcFn:M,newlyAddedElement:O});if(!D)return console.warn(e,"not serialized"),null;let V;r.hasNode(e)?V=r.getId(e):z4(D,w)||!A&&D.type===_n.Text&&!D.isStyle&&!D.textContent.replace(/^\s+|\s+$/gm,"").length?V=Zc:V=hw();const H=Object.assign(D,{id:V});if(r.add(e,H),V===Zc)return null;T&&T(e);let G=!f;if(H.type===_n.Element){G=G&&!H.needBlock,delete H.needBlock;const j=e.shadowRoot;j&&Pc(j)&&(H.isShadowHost=!0)}if((H.type===_n.Document||H.type===_n.Element)&&G){w.headWhitespace&&H.type===_n.Element&&H.tagName==="head"&&(A=!1);const j={doc:n,mirror:r,blockClass:s,blockSelector:i,maskAllText:a,unblockSelector:o,maskTextClass:l,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:c,skipChild:f,inlineStylesheet:p,maskInputOptions:g,maskAttributeFn:m,maskTextFn:y,maskInputFn:b,slimDOMOptions:w,dataURLOptions:S,inlineImages:P,recordCanvas:E,preserveWhiteSpace:A,onSerialize:T,onIframeLoad:C,iframeLoadTimeout:k,onStylesheetLoad:x,stylesheetLoadTimeout:I,keepIframeSrcFn:M};for(const B of Array.from(e.childNodes)){const W=Al(B,j);W&&H.childNodes.push(W)}if(m4(e)&&e.shadowRoot)for(const B of Array.from(e.shadowRoot.childNodes)){const W=Al(B,j);W&&(Pc(e.shadowRoot)&&(W.isShadow=!0),H.childNodes.push(W))}}return e.parentNode&&Cc(e.parentNode)&&Pc(e.parentNode)&&(H.isShadow=!0),H.type===_n.Element&&H.tagName==="iframe"&&F4(e,()=>{const j=e.contentDocument;if(j&&C){const B=Al(j,{doc:j,mirror:r,blockClass:s,blockSelector:i,unblockSelector:o,maskAllText:a,maskTextClass:l,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:c,skipChild:!1,inlineStylesheet:p,maskInputOptions:g,maskAttributeFn:m,maskTextFn:y,maskInputFn:b,slimDOMOptions:w,dataURLOptions:S,inlineImages:P,recordCanvas:E,preserveWhiteSpace:A,onSerialize:T,onIframeLoad:C,iframeLoadTimeout:k,onStylesheetLoad:x,stylesheetLoadTimeout:I,keepIframeSrcFn:M});B&&C(e,B)}},k),H.type===_n.Element&&H.tagName==="link"&&typeof H.attributes.rel=="string"&&(H.attributes.rel==="stylesheet"||H.attributes.rel==="preload"&&typeof H.attributes.href=="string"&&QR(H.attributes.href)==="css")&&N4(e,()=>{if(x){const j=Al(e,{doc:n,mirror:r,blockClass:s,blockSelector:i,unblockSelector:o,maskAllText:a,maskTextClass:l,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:c,skipChild:!1,inlineStylesheet:p,maskInputOptions:g,maskAttributeFn:m,maskTextFn:y,maskInputFn:b,slimDOMOptions:w,dataURLOptions:S,inlineImages:P,recordCanvas:E,preserveWhiteSpace:A,onSerialize:T,onIframeLoad:C,iframeLoadTimeout:k,onStylesheetLoad:x,stylesheetLoadTimeout:I,keepIframeSrcFn:M});j&&x(e,j)}},I),H}function j4(e,t){const{mirror:n=new XR,blockClass:r="rr-block",blockSelector:s=null,unblockSelector:i=null,maskAllText:o=!1,maskTextClass:a="rr-mask",unmaskTextClass:l=null,maskTextSelector:u=null,unmaskTextSelector:d=null,inlineStylesheet:c=!0,inlineImages:f=!1,recordCanvas:p=!1,maskAllInputs:g=!1,maskAttributeFn:m,maskTextFn:y,maskInputFn:b,slimDOM:w=!1,dataURLOptions:S,preserveWhiteSpace:P,onSerialize:E,onIframeLoad:T,iframeLoadTimeout:C,onStylesheetLoad:k,stylesheetLoadTimeout:x,keepIframeSrcFn:I=()=>!1}=t||{};return Al(e,{doc:e,mirror:n,blockClass:r,blockSelector:s,unblockSelector:i,maskAllText:o,maskTextClass:a,unmaskTextClass:l,maskTextSelector:u,unmaskTextSelector:d,skipChild:!1,inlineStylesheet:c,maskInputOptions:g===!0?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0}:g===!1?{}:g,maskAttributeFn:m,maskTextFn:y,maskInputFn:b,slimDOMOptions:w===!0||w==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaDescKeywords:w==="all",headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaAuthorship:!0,headMetaVerification:!0}:w===!1?{}:w,dataURLOptions:S,inlineImages:f,recordCanvas:p,preserveWhiteSpace:P,onSerialize:E,onIframeLoad:T,iframeLoadTimeout:C,onStylesheetLoad:k,stylesheetLoadTimeout:x,keepIframeSrcFn:I,newlyAddedElement:!1})}function lo(e){let t,n=e[0],r=1;for(;r<e.length;){const s=e[r],i=e[r+1];if(r+=2,(s==="optionalAccess"||s==="optionalCall")&&n==null)return;s==="access"||s==="optionalAccess"?(t=n,n=i(n)):(s==="call"||s==="optionalCall")&&(n=i((...o)=>n.call(t,...o)),t=void 0)}return n}function hr(e,t,n=document){const r={capture:!0,passive:!0};return n.addEventListener(e,t,r),()=>n.removeEventListener(e,t,r)}const xl=`Please stop import mirror directly. Instead of that,\r
51
+ now you can use replayer.getMirror() to access the mirror instance of a replayer,\r
52
+ or you can use record.mirror to access the mirror instance during recording.`;let S1={map:{},getId(){return console.error(xl),-1},getNode(){return console.error(xl),null},removeNodeFromMap(){console.error(xl)},has(){return console.error(xl),!1},reset(){console.error(xl)}};typeof window<"u"&&window.Proxy&&window.Reflect&&(S1=new Proxy(S1,{get(e,t,n){return t==="map"&&console.error(xl),Reflect.get(e,t,n)}}));function ed(e,t,n={}){let r=null,s=0;return function(...i){const o=Date.now();!s&&n.leading===!1&&(s=o);const a=t-(o-s),l=this;a<=0||a>t?(r&&(Q4(r),r=null),s=o,e.apply(l,i)):!r&&n.trailing!==!1&&(r=om(()=>{s=n.leading===!1?0:Date.now(),r=null,e.apply(l,i)},a))}}function nI(e,t,n,r,s=window){const i=s.Object.getOwnPropertyDescriptor(e,t);return s.Object.defineProperty(e,t,r?n:{set(o){om(()=>{n.set.call(this,o)},0),i&&i.set&&i.set.call(this,o)}}),()=>nI(e,t,i||{},!0)}function pw(e,t,n){try{if(!(t in e))return()=>{};const r=e[t],s=n(r);return typeof s=="function"&&(s.prototype=s.prototype||{},Object.defineProperties(s,{__rrweb_original__:{enumerable:!1,value:r}})),e[t]=s,()=>{e[t]=r}}catch{return()=>{}}}let Xh=Date.now;/[1-9][0-9]{12}/.test(Date.now().toString())||(Xh=()=>new Date().getTime());function rI(e){const t=e.document;return{left:t.scrollingElement?t.scrollingElement.scrollLeft:e.pageXOffset!==void 0?e.pageXOffset:lo([t,"optionalAccess",n=>n.documentElement,"access",n=>n.scrollLeft])||lo([t,"optionalAccess",n=>n.body,"optionalAccess",n=>n.parentElement,"optionalAccess",n=>n.scrollLeft])||lo([t,"optionalAccess",n=>n.body,"optionalAccess",n=>n.scrollLeft])||0,top:t.scrollingElement?t.scrollingElement.scrollTop:e.pageYOffset!==void 0?e.pageYOffset:lo([t,"optionalAccess",n=>n.documentElement,"access",n=>n.scrollTop])||lo([t,"optionalAccess",n=>n.body,"optionalAccess",n=>n.parentElement,"optionalAccess",n=>n.scrollTop])||lo([t,"optionalAccess",n=>n.body,"optionalAccess",n=>n.scrollTop])||0}}function sI(){return window.innerHeight||document.documentElement&&document.documentElement.clientHeight||document.body&&document.body.clientHeight}function iI(){return window.innerWidth||document.documentElement&&document.documentElement.clientWidth||document.body&&document.body.clientWidth}function oI(e){return e?e.nodeType===e.ELEMENT_NODE?e:e.parentElement:null}function jr(e,t,n,r,s){if(!e)return!1;const i=oI(e);if(!i)return!1;const o=Il(t,n);if(!s){const u=r&&i.matches(r);return o(i)&&!u}const a=ba(i,o);let l=-1;return a<0?!1:(r&&(l=ba(i,Il(null,r))),a>-1&&l<0?!0:a<l)}function q4(e,t){return t.getId(e)!==-1}function vg(e,t){return t.getId(e)===Zc}function aI(e,t){if(Cc(e))return!1;const n=t.getId(e);return t.has(n)?e.parentNode&&e.parentNode.nodeType===e.DOCUMENT_NODE?!1:e.parentNode?aI(e.parentNode,t):!0:!0}function ay(e){return!!e.changedTouches}function W4(e=window){"NodeList"in e&&!e.NodeList.prototype.forEach&&(e.NodeList.prototype.forEach=Array.prototype.forEach),"DOMTokenList"in e&&!e.DOMTokenList.prototype.forEach&&(e.DOMTokenList.prototype.forEach=Array.prototype.forEach),Node.prototype.contains||(Node.prototype.contains=(...t)=>{let n=t[0];if(!(0 in t))throw new TypeError("1 argument is required");do if(this===n)return!0;while(n=n&&n.parentNode);return!1})}function lI(e,t){return!!(e.nodeName==="IFRAME"&&t.getMeta(e))}function uI(e,t){return!!(e.nodeName==="LINK"&&e.nodeType===e.ELEMENT_NODE&&e.getAttribute&&e.getAttribute("rel")==="stylesheet"&&t.getMeta(e))}function ly(e){return!!lo([e,"optionalAccess",t=>t.shadowRoot])}class G4{constructor(){this.id=1,this.styleIDMap=new WeakMap,this.idStyleMap=new Map}getId(t){return VH(this.styleIDMap.get(t),()=>-1)}has(t){return this.styleIDMap.has(t)}add(t,n){if(this.has(t))return this.getId(t);let r;return n===void 0?r=this.id++:r=n,this.styleIDMap.set(t,r),this.idStyleMap.set(r,t),r}getStyle(t){return this.idStyleMap.get(t)||null}reset(){this.styleIDMap=new WeakMap,this.idStyleMap=new Map,this.id=1}generateId(){return this.id++}}function cI(e){let t=null;return lo([e,"access",n=>n.getRootNode,"optionalCall",n=>n(),"optionalAccess",n=>n.nodeType])===Node.DOCUMENT_FRAGMENT_NODE&&e.getRootNode().host&&(t=e.getRootNode().host),t}function K4(e){let t=e,n;for(;n=cI(t);)t=n;return t}function Y4(e){const t=e.ownerDocument;if(!t)return!1;const n=K4(e);return t.contains(n)}function dI(e){const t=e.ownerDocument;return t?t.contains(e)||Y4(e):!1}const _1={};function mw(e){const t=_1[e];if(t)return t;const n=window.document;let r=window[e];if(n&&typeof n.createElement=="function")try{const s=n.createElement("iframe");s.hidden=!0,n.head.appendChild(s);const i=s.contentWindow;i&&i[e]&&(r=i[e]),n.head.removeChild(s)}catch{}return _1[e]=r.bind(window)}function X4(...e){return mw("requestAnimationFrame")(...e)}function om(...e){return mw("setTimeout")(...e)}function Q4(...e){return mw("clearTimeout")(...e)}var ot=(e=>(e[e.DomContentLoaded=0]="DomContentLoaded",e[e.Load=1]="Load",e[e.FullSnapshot=2]="FullSnapshot",e[e.IncrementalSnapshot=3]="IncrementalSnapshot",e[e.Meta=4]="Meta",e[e.Custom=5]="Custom",e[e.Plugin=6]="Plugin",e))(ot||{}),Xe=(e=>(e[e.Mutation=0]="Mutation",e[e.MouseMove=1]="MouseMove",e[e.MouseInteraction=2]="MouseInteraction",e[e.Scroll=3]="Scroll",e[e.ViewportResize=4]="ViewportResize",e[e.Input=5]="Input",e[e.TouchMove=6]="TouchMove",e[e.MediaInteraction=7]="MediaInteraction",e[e.StyleSheetRule=8]="StyleSheetRule",e[e.CanvasMutation=9]="CanvasMutation",e[e.Font=10]="Font",e[e.Log=11]="Log",e[e.Drag=12]="Drag",e[e.StyleDeclaration=13]="StyleDeclaration",e[e.Selection=14]="Selection",e[e.AdoptedStyleSheet=15]="AdoptedStyleSheet",e[e.CustomElement=16]="CustomElement",e))(Xe||{}),ar=(e=>(e[e.MouseUp=0]="MouseUp",e[e.MouseDown=1]="MouseDown",e[e.Click=2]="Click",e[e.ContextMenu=3]="ContextMenu",e[e.DblClick=4]="DblClick",e[e.Focus=5]="Focus",e[e.Blur=6]="Blur",e[e.TouchStart=7]="TouchStart",e[e.TouchMove_Departed=8]="TouchMove_Departed",e[e.TouchEnd=9]="TouchEnd",e[e.TouchCancel=10]="TouchCancel",e))(ar||{}),_i=(e=>(e[e.Mouse=0]="Mouse",e[e.Pen=1]="Pen",e[e.Touch=2]="Touch",e))(_i||{});function J4(e){let t,n=e[0],r=1;for(;r<e.length;){const s=e[r],i=e[r+1];if(r+=2,(s==="optionalAccess"||s==="optionalCall")&&n==null)return;s==="access"||s==="optionalAccess"?(t=n,n=i(n)):(s==="call"||s==="optionalCall")&&(n=i((...o)=>n.call(t,...o)),t=void 0)}return n}function k1(e){return"__ln"in e}class Z4{constructor(){this.length=0,this.head=null,this.tail=null}get(t){if(t>=this.length)throw new Error("Position outside of list range");let n=this.head;for(let r=0;r<t;r++)n=J4([n,"optionalAccess",s=>s.next])||null;return n}addNode(t){const n={value:t,previous:null,next:null};if(t.__ln=n,t.previousSibling&&k1(t.previousSibling)){const r=t.previousSibling.__ln.next;n.next=r,n.previous=t.previousSibling.__ln,t.previousSibling.__ln.next=n,r&&(r.previous=n)}else if(t.nextSibling&&k1(t.nextSibling)&&t.nextSibling.__ln.previous){const r=t.nextSibling.__ln.previous;n.previous=r,n.next=t.nextSibling.__ln,t.nextSibling.__ln.previous=n,r&&(r.next=n)}else this.head&&(this.head.previous=n),n.next=this.head,this.head=n;n.next===null&&(this.tail=n),this.length++}removeNode(t){const n=t.__ln;this.head&&(n.previous?(n.previous.next=n.next,n.next?n.next.previous=n.previous:this.tail=n.previous):(this.head=n.next,this.head?this.head.previous=null:this.tail=null),t.__ln&&delete t.__ln,this.length--)}}const x1=(e,t)=>`${e}@${t}`;class e5{constructor(){this.frozen=!1,this.locked=!1,this.texts=[],this.attributes=[],this.attributeMap=new WeakMap,this.removes=[],this.mapRemoves=[],this.movedMap={},this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.processMutations=t=>{t.forEach(this.processMutation),this.emit()},this.emit=()=>{if(this.frozen||this.locked)return;const t=[],n=new Set,r=new Z4,s=l=>{let u=l,d=Zc;for(;d===Zc;)u=u&&u.nextSibling,d=u&&this.mirror.getId(u);return d},i=l=>{if(!l.parentNode||!dI(l))return;const u=Cc(l.parentNode)?this.mirror.getId(cI(l)):this.mirror.getId(l.parentNode),d=s(l);if(u===-1||d===-1)return r.addNode(l);const c=Al(l,{doc:this.doc,mirror:this.mirror,blockClass:this.blockClass,blockSelector:this.blockSelector,maskAllText:this.maskAllText,unblockSelector:this.unblockSelector,maskTextClass:this.maskTextClass,unmaskTextClass:this.unmaskTextClass,maskTextSelector:this.maskTextSelector,unmaskTextSelector:this.unmaskTextSelector,skipChild:!0,newlyAddedElement:!0,inlineStylesheet:this.inlineStylesheet,maskInputOptions:this.maskInputOptions,maskAttributeFn:this.maskAttributeFn,maskTextFn:this.maskTextFn,maskInputFn:this.maskInputFn,slimDOMOptions:this.slimDOMOptions,dataURLOptions:this.dataURLOptions,recordCanvas:this.recordCanvas,inlineImages:this.inlineImages,onSerialize:f=>{lI(f,this.mirror)&&!jr(f,this.blockClass,this.blockSelector,this.unblockSelector,!1)&&this.iframeManager.addIframe(f),uI(f,this.mirror)&&this.stylesheetManager.trackLinkElement(f),ly(l)&&this.shadowDomManager.addShadowRoot(l.shadowRoot,this.doc)},onIframeLoad:(f,p)=>{jr(f,this.blockClass,this.blockSelector,this.unblockSelector,!1)||(this.iframeManager.attachIframe(f,p),f.contentWindow&&this.canvasManager.addWindow(f.contentWindow),this.shadowDomManager.observeAttachShadow(f))},onStylesheetLoad:(f,p)=>{this.stylesheetManager.attachLinkElement(f,p)}});c&&(t.push({parentId:u,nextId:d,node:c}),n.add(c.id))};for(;this.mapRemoves.length;)this.mirror.removeNodeFromMap(this.mapRemoves.shift());for(const l of this.movedSet)E1(this.removes,l,this.mirror)&&!this.movedSet.has(l.parentNode)||i(l);for(const l of this.addedSet)!C1(this.droppedSet,l)&&!E1(this.removes,l,this.mirror)||C1(this.movedSet,l)?i(l):this.droppedSet.add(l);let o=null;for(;r.length;){let l=null;if(o){const u=this.mirror.getId(o.value.parentNode),d=s(o.value);u!==-1&&d!==-1&&(l=o)}if(!l){let u=r.tail;for(;u;){const d=u;if(u=u.previous,d){const c=this.mirror.getId(d.value.parentNode);if(s(d.value)===-1)continue;if(c!==-1){l=d;break}else{const p=d.value;if(p.parentNode&&p.parentNode.nodeType===Node.DOCUMENT_FRAGMENT_NODE){const g=p.parentNode.host;if(this.mirror.getId(g)!==-1){l=d;break}}}}}}if(!l){for(;r.head;)r.removeNode(r.head.value);break}o=l.previous,r.removeNode(l.value),i(l.value)}const a={texts:this.texts.map(l=>({id:this.mirror.getId(l.node),value:l.value})).filter(l=>!n.has(l.id)).filter(l=>this.mirror.has(l.id)),attributes:this.attributes.map(l=>{const{attributes:u}=l;if(typeof u.style=="string"){const d=JSON.stringify(l.styleDiff),c=JSON.stringify(l._unchangedStyles);d.length<u.style.length&&(d+c).split("var(").length===u.style.split("var(").length&&(u.style=l.styleDiff)}return{id:this.mirror.getId(l.node),attributes:u}}).filter(l=>!n.has(l.id)).filter(l=>this.mirror.has(l.id)),removes:this.removes,adds:t};!a.texts.length&&!a.attributes.length&&!a.removes.length&&!a.adds.length||(this.texts=[],this.attributes=[],this.attributeMap=new WeakMap,this.removes=[],this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.movedMap={},this.mutationCb(a))},this.processMutation=t=>{if(!vg(t.target,this.mirror))switch(t.type){case"characterData":{const n=t.target.textContent;!jr(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)&&n!==t.oldValue&&this.texts.push({value:gu(t.target,this.maskTextClass,this.maskTextSelector,this.unmaskTextClass,this.unmaskTextSelector,this.maskAllText)&&n?this.maskTextFn?this.maskTextFn(n,oI(t.target)):n.replace(/[\S]/g,"*"):n,node:t.target});break}case"attributes":{const n=t.target;let r=t.attributeName,s=t.target.getAttribute(r);if(r==="value"){const o=fw(n),a=n.tagName;s=Kh(n,a,o);const l=sm({maskInputOptions:this.maskInputOptions,tagName:a,type:o}),u=gu(t.target,this.maskTextClass,this.maskTextSelector,this.unmaskTextClass,this.unmaskTextSelector,l);s=Jc({isMasked:u,element:n,value:s,maskInputFn:this.maskInputFn})}if(jr(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)||s===t.oldValue)return;let i=this.attributeMap.get(t.target);if(n.tagName==="IFRAME"&&r==="src"&&!this.keepIframeSrcFn(s))if(!n.contentDocument)r="rr_src";else return;if(i||(i={node:t.target,attributes:{},styleDiff:{},_unchangedStyles:{}},this.attributes.push(i),this.attributeMap.set(t.target,i)),r==="type"&&n.tagName==="INPUT"&&(t.oldValue||"").toLowerCase()==="password"&&n.setAttribute("data-rr-is-password","true"),!tI(n.tagName,r)&&(i.attributes[r]=eI(this.doc,mu(n.tagName),mu(r),s,n,this.maskAttributeFn),r==="style")){if(!this.unattachedDoc)try{this.unattachedDoc=document.implementation.createHTMLDocument()}catch{this.unattachedDoc=this.doc}const o=this.unattachedDoc.createElement("span");t.oldValue&&o.setAttribute("style",t.oldValue);for(const a of Array.from(n.style)){const l=n.style.getPropertyValue(a),u=n.style.getPropertyPriority(a);l!==o.style.getPropertyValue(a)||u!==o.style.getPropertyPriority(a)?u===""?i.styleDiff[a]=l:i.styleDiff[a]=[l,u]:i._unchangedStyles[a]=[l,u]}for(const a of Array.from(o.style))n.style.getPropertyValue(a)===""&&(i.styleDiff[a]=!1)}break}case"childList":{if(jr(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!0))return;t.addedNodes.forEach(n=>this.genAdds(n,t.target)),t.removedNodes.forEach(n=>{const r=this.mirror.getId(n),s=Cc(t.target)?this.mirror.getId(t.target.host):this.mirror.getId(t.target);jr(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)||vg(n,this.mirror)||!q4(n,this.mirror)||(this.addedSet.has(n)?(uy(this.addedSet,n),this.droppedSet.add(n)):this.addedSet.has(t.target)&&r===-1||aI(t.target,this.mirror)||(this.movedSet.has(n)&&this.movedMap[x1(r,s)]?uy(this.movedSet,n):this.removes.push({parentId:s,id:r,isShadow:Cc(t.target)&&Pc(t.target)?!0:void 0})),this.mapRemoves.push(n))});break}}},this.genAdds=(t,n)=>{if(!this.processedNodeManager.inOtherBuffer(t,this)&&!(this.addedSet.has(t)||this.movedSet.has(t))){if(this.mirror.hasNode(t)){if(vg(t,this.mirror))return;this.movedSet.add(t);let r=null;n&&this.mirror.hasNode(n)&&(r=this.mirror.getId(n)),r&&r!==-1&&(this.movedMap[x1(this.mirror.getId(t),r)]=!0)}else this.addedSet.add(t),this.droppedSet.delete(t);jr(t,this.blockClass,this.blockSelector,this.unblockSelector,!1)||(t.childNodes.forEach(r=>this.genAdds(r)),ly(t)&&t.shadowRoot.childNodes.forEach(r=>{this.processedNodeManager.add(r,this),this.genAdds(r,t)}))}}}init(t){["mutationCb","blockClass","blockSelector","unblockSelector","maskAllText","maskTextClass","unmaskTextClass","maskTextSelector","unmaskTextSelector","inlineStylesheet","maskInputOptions","maskAttributeFn","maskTextFn","maskInputFn","keepIframeSrcFn","recordCanvas","inlineImages","slimDOMOptions","dataURLOptions","doc","mirror","iframeManager","stylesheetManager","shadowDomManager","canvasManager","processedNodeManager"].forEach(n=>{this[n]=t[n]})}freeze(){this.frozen=!0,this.canvasManager.freeze()}unfreeze(){this.frozen=!1,this.canvasManager.unfreeze(),this.emit()}isFrozen(){return this.frozen}lock(){this.locked=!0,this.canvasManager.lock()}unlock(){this.locked=!1,this.canvasManager.unlock(),this.emit()}reset(){this.shadowDomManager.reset(),this.canvasManager.reset()}}function uy(e,t){e.delete(t),t.childNodes.forEach(n=>uy(e,n))}function E1(e,t,n){return e.length===0?!1:t5(e,t,n)}function t5(e,t,n){let r=t.parentNode;for(;r;){const s=n.getId(r);if(e.some(i=>i.id===s))return!0;r=r.parentNode}return!1}function C1(e,t){return e.size===0?!1:fI(e,t)}function fI(e,t){const{parentNode:n}=t;return n?e.has(n)?!0:fI(e,n):!1}let Tc;function n5(e){Tc=e}function r5(){Tc=void 0}const vt=e=>Tc?(...n)=>{try{return e(...n)}catch(r){if(Tc&&Tc(r)===!0)return()=>{};throw r}}:e;function Es(e){let t,n=e[0],r=1;for(;r<e.length;){const s=e[r],i=e[r+1];if(r+=2,(s==="optionalAccess"||s==="optionalCall")&&n==null)return;s==="access"||s==="optionalAccess"?(t=n,n=i(n)):(s==="call"||s==="optionalCall")&&(n=i((...o)=>n.call(t,...o)),t=void 0)}return n}const Ol=[];function zd(e){try{if("composedPath"in e){const t=e.composedPath();if(t.length)return t[0]}else if("path"in e&&e.path.length)return e.path[0]}catch{}return e&&e.target}function hI(e,t){const n=new e5;Ol.push(n),n.init(e);let r=window.MutationObserver||window.__rrMutationObserver;const s=Es([window,"optionalAccess",o=>o.Zone,"optionalAccess",o=>o.__symbol__,"optionalCall",o=>o("MutationObserver")]);s&&window[s]&&(r=window[s]);const i=new r(vt(o=>{e.onMutation&&e.onMutation(o)===!1||n.processMutations.bind(n)(o)}));return i.observe(t,{attributes:!0,attributeOldValue:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0}),i}function s5({mousemoveCb:e,sampling:t,doc:n,mirror:r}){if(t.mousemove===!1)return()=>{};const s=typeof t.mousemove=="number"?t.mousemove:50,i=typeof t.mousemoveCallback=="number"?t.mousemoveCallback:500;let o=[],a;const l=ed(vt(c=>{const f=Date.now()-a;e(o.map(p=>(p.timeOffset-=f,p)),c),o=[],a=null}),i),u=vt(ed(vt(c=>{const f=zd(c),{clientX:p,clientY:g}=ay(c)?c.changedTouches[0]:c;a||(a=Xh()),o.push({x:p,y:g,id:r.getId(f),timeOffset:Xh()-a}),l(typeof DragEvent<"u"&&c instanceof DragEvent?Xe.Drag:c instanceof MouseEvent?Xe.MouseMove:Xe.TouchMove)}),s,{trailing:!1})),d=[hr("mousemove",u,n),hr("touchmove",u,n),hr("drag",u,n)];return vt(()=>{d.forEach(c=>c())})}function i5({mouseInteractionCb:e,doc:t,mirror:n,blockClass:r,blockSelector:s,unblockSelector:i,sampling:o}){if(o.mouseInteraction===!1)return()=>{};const a=o.mouseInteraction===!0||o.mouseInteraction===void 0?{}:o.mouseInteraction,l=[];let u=null;const d=c=>f=>{const p=zd(f);if(jr(p,r,s,i,!0))return;let g=null,m=c;if("pointerType"in f){switch(f.pointerType){case"mouse":g=_i.Mouse;break;case"touch":g=_i.Touch;break;case"pen":g=_i.Pen;break}g===_i.Touch?ar[c]===ar.MouseDown?m="TouchStart":ar[c]===ar.MouseUp&&(m="TouchEnd"):_i.Pen}else ay(f)&&(g=_i.Touch);g!==null?(u=g,(m.startsWith("Touch")&&g===_i.Touch||m.startsWith("Mouse")&&g===_i.Mouse)&&(g=null)):ar[c]===ar.Click&&(g=u,u=null);const y=ay(f)?f.changedTouches[0]:f;if(!y)return;const b=n.getId(p),{clientX:w,clientY:S}=y;vt(e)({type:ar[m],id:b,x:w,y:S,...g!==null&&{pointerType:g}})};return Object.keys(ar).filter(c=>Number.isNaN(Number(c))&&!c.endsWith("_Departed")&&a[c]!==!1).forEach(c=>{let f=mu(c);const p=d(c);if(window.PointerEvent)switch(ar[c]){case ar.MouseDown:case ar.MouseUp:f=f.replace("mouse","pointer");break;case ar.TouchStart:case ar.TouchEnd:return}l.push(hr(f,p,t))}),vt(()=>{l.forEach(c=>c())})}function pI({scrollCb:e,doc:t,mirror:n,blockClass:r,blockSelector:s,unblockSelector:i,sampling:o}){const a=vt(ed(vt(l=>{const u=zd(l);if(!u||jr(u,r,s,i,!0))return;const d=n.getId(u);if(u===t&&t.defaultView){const c=rI(t.defaultView);e({id:d,x:c.left,y:c.top})}else e({id:d,x:u.scrollLeft,y:u.scrollTop})}),o.scroll||100));return hr("scroll",a,t)}function o5({viewportResizeCb:e},{win:t}){let n=-1,r=-1;const s=vt(ed(vt(()=>{const i=sI(),o=iI();(n!==i||r!==o)&&(e({width:Number(o),height:Number(i)}),n=i,r=o)}),200));return hr("resize",s,t)}const a5=["INPUT","TEXTAREA","SELECT"],P1=new WeakMap;function l5({inputCb:e,doc:t,mirror:n,blockClass:r,blockSelector:s,unblockSelector:i,ignoreClass:o,ignoreSelector:a,maskInputOptions:l,maskInputFn:u,sampling:d,userTriggeredOnInput:c,maskTextClass:f,unmaskTextClass:p,maskTextSelector:g,unmaskTextSelector:m}){function y(C){let k=zd(C);const x=C.isTrusted,I=k&&iy(k.tagName);if(I==="OPTION"&&(k=k.parentElement),!k||!I||a5.indexOf(I)<0||jr(k,r,s,i,!0))return;const M=k;if(M.classList.contains(o)||a&&M.matches(a))return;const O=fw(k);let A=Kh(M,I,O),D=!1;const V=sm({maskInputOptions:l,tagName:I,type:O}),H=gu(k,f,g,p,m,V);(O==="radio"||O==="checkbox")&&(D=k.checked),A=Jc({isMasked:H,element:k,value:A,maskInputFn:u}),b(k,c?{text:A,isChecked:D,userTriggered:x}:{text:A,isChecked:D});const G=k.name;O==="radio"&&G&&D&&t.querySelectorAll(`input[type="radio"][name="${G}"]`).forEach(j=>{if(j!==k){const B=Jc({isMasked:H,element:j,value:Kh(j,I,O),maskInputFn:u});b(j,c?{text:B,isChecked:!D,userTriggered:!1}:{text:B,isChecked:!D})}})}function b(C,k){const x=P1.get(C);if(!x||x.text!==k.text||x.isChecked!==k.isChecked){P1.set(C,k);const I=n.getId(C);vt(e)({...k,id:I})}}const S=(d.input==="last"?["change"]:["input","change"]).map(C=>hr(C,vt(y),t)),P=t.defaultView;if(!P)return()=>{S.forEach(C=>C())};const E=P.Object.getOwnPropertyDescriptor(P.HTMLInputElement.prototype,"value"),T=[[P.HTMLInputElement.prototype,"value"],[P.HTMLInputElement.prototype,"checked"],[P.HTMLSelectElement.prototype,"value"],[P.HTMLTextAreaElement.prototype,"value"],[P.HTMLSelectElement.prototype,"selectedIndex"],[P.HTMLOptionElement.prototype,"selected"]];return E&&E.set&&S.push(...T.map(C=>nI(C[0],C[1],{set(){vt(y)({target:this,isTrusted:!1})}},!1,P))),vt(()=>{S.forEach(C=>C())})}function Qh(e){const t=[];function n(r,s){if(bf("CSSGroupingRule")&&r.parentRule instanceof CSSGroupingRule||bf("CSSMediaRule")&&r.parentRule instanceof CSSMediaRule||bf("CSSSupportsRule")&&r.parentRule instanceof CSSSupportsRule||bf("CSSConditionRule")&&r.parentRule instanceof CSSConditionRule){const o=Array.from(r.parentRule.cssRules).indexOf(r);s.unshift(o)}else if(r.parentStyleSheet){const o=Array.from(r.parentStyleSheet.cssRules).indexOf(r);s.unshift(o)}return s}return n(e,t)}function uo(e,t,n){let r,s;return e?(e.ownerNode?r=t.getId(e.ownerNode):s=n.getId(e),{styleId:s,id:r}):{}}function u5({styleSheetRuleCb:e,mirror:t,stylesheetManager:n},{win:r}){if(!r.CSSStyleSheet||!r.CSSStyleSheet.prototype)return()=>{};const s=r.CSSStyleSheet.prototype.insertRule;r.CSSStyleSheet.prototype.insertRule=new Proxy(s,{apply:vt((d,c,f)=>{const[p,g]=f,{id:m,styleId:y}=uo(c,t,n.styleMirror);return(m&&m!==-1||y&&y!==-1)&&e({id:m,styleId:y,adds:[{rule:p,index:g}]}),d.apply(c,f)})});const i=r.CSSStyleSheet.prototype.deleteRule;r.CSSStyleSheet.prototype.deleteRule=new Proxy(i,{apply:vt((d,c,f)=>{const[p]=f,{id:g,styleId:m}=uo(c,t,n.styleMirror);return(g&&g!==-1||m&&m!==-1)&&e({id:g,styleId:m,removes:[{index:p}]}),d.apply(c,f)})});let o;r.CSSStyleSheet.prototype.replace&&(o=r.CSSStyleSheet.prototype.replace,r.CSSStyleSheet.prototype.replace=new Proxy(o,{apply:vt((d,c,f)=>{const[p]=f,{id:g,styleId:m}=uo(c,t,n.styleMirror);return(g&&g!==-1||m&&m!==-1)&&e({id:g,styleId:m,replace:p}),d.apply(c,f)})}));let a;r.CSSStyleSheet.prototype.replaceSync&&(a=r.CSSStyleSheet.prototype.replaceSync,r.CSSStyleSheet.prototype.replaceSync=new Proxy(a,{apply:vt((d,c,f)=>{const[p]=f,{id:g,styleId:m}=uo(c,t,n.styleMirror);return(g&&g!==-1||m&&m!==-1)&&e({id:g,styleId:m,replaceSync:p}),d.apply(c,f)})}));const l={};wf("CSSGroupingRule")?l.CSSGroupingRule=r.CSSGroupingRule:(wf("CSSMediaRule")&&(l.CSSMediaRule=r.CSSMediaRule),wf("CSSConditionRule")&&(l.CSSConditionRule=r.CSSConditionRule),wf("CSSSupportsRule")&&(l.CSSSupportsRule=r.CSSSupportsRule));const u={};return Object.entries(l).forEach(([d,c])=>{u[d]={insertRule:c.prototype.insertRule,deleteRule:c.prototype.deleteRule},c.prototype.insertRule=new Proxy(u[d].insertRule,{apply:vt((f,p,g)=>{const[m,y]=g,{id:b,styleId:w}=uo(p.parentStyleSheet,t,n.styleMirror);return(b&&b!==-1||w&&w!==-1)&&e({id:b,styleId:w,adds:[{rule:m,index:[...Qh(p),y||0]}]}),f.apply(p,g)})}),c.prototype.deleteRule=new Proxy(u[d].deleteRule,{apply:vt((f,p,g)=>{const[m]=g,{id:y,styleId:b}=uo(p.parentStyleSheet,t,n.styleMirror);return(y&&y!==-1||b&&b!==-1)&&e({id:y,styleId:b,removes:[{index:[...Qh(p),m]}]}),f.apply(p,g)})})}),vt(()=>{r.CSSStyleSheet.prototype.insertRule=s,r.CSSStyleSheet.prototype.deleteRule=i,o&&(r.CSSStyleSheet.prototype.replace=o),a&&(r.CSSStyleSheet.prototype.replaceSync=a),Object.entries(l).forEach(([d,c])=>{c.prototype.insertRule=u[d].insertRule,c.prototype.deleteRule=u[d].deleteRule})})}function mI({mirror:e,stylesheetManager:t},n){let r=null;n.nodeName==="#document"?r=e.getId(n):r=e.getId(n.host);const s=n.nodeName==="#document"?Es([n,"access",o=>o.defaultView,"optionalAccess",o=>o.Document]):Es([n,"access",o=>o.ownerDocument,"optionalAccess",o=>o.defaultView,"optionalAccess",o=>o.ShadowRoot]),i=Es([s,"optionalAccess",o=>o.prototype])?Object.getOwnPropertyDescriptor(Es([s,"optionalAccess",o=>o.prototype]),"adoptedStyleSheets"):void 0;return r===null||r===-1||!s||!i?()=>{}:(Object.defineProperty(n,"adoptedStyleSheets",{configurable:i.configurable,enumerable:i.enumerable,get(){return Es([i,"access",o=>o.get,"optionalAccess",o=>o.call,"call",o=>o(this)])},set(o){const a=Es([i,"access",l=>l.set,"optionalAccess",l=>l.call,"call",l=>l(this,o)]);if(r!==null&&r!==-1)try{t.adoptStyleSheets(o,r)}catch{}return a}}),vt(()=>{Object.defineProperty(n,"adoptedStyleSheets",{configurable:i.configurable,enumerable:i.enumerable,get:i.get,set:i.set})}))}function c5({styleDeclarationCb:e,mirror:t,ignoreCSSAttributes:n,stylesheetManager:r},{win:s}){const i=s.CSSStyleDeclaration.prototype.setProperty;s.CSSStyleDeclaration.prototype.setProperty=new Proxy(i,{apply:vt((a,l,u)=>{const[d,c,f]=u;if(n.has(d))return i.apply(l,[d,c,f]);const{id:p,styleId:g}=uo(Es([l,"access",m=>m.parentRule,"optionalAccess",m=>m.parentStyleSheet]),t,r.styleMirror);return(p&&p!==-1||g&&g!==-1)&&e({id:p,styleId:g,set:{property:d,value:c,priority:f},index:Qh(l.parentRule)}),a.apply(l,u)})});const o=s.CSSStyleDeclaration.prototype.removeProperty;return s.CSSStyleDeclaration.prototype.removeProperty=new Proxy(o,{apply:vt((a,l,u)=>{const[d]=u;if(n.has(d))return o.apply(l,[d]);const{id:c,styleId:f}=uo(Es([l,"access",p=>p.parentRule,"optionalAccess",p=>p.parentStyleSheet]),t,r.styleMirror);return(c&&c!==-1||f&&f!==-1)&&e({id:c,styleId:f,remove:{property:d},index:Qh(l.parentRule)}),a.apply(l,u)})}),vt(()=>{s.CSSStyleDeclaration.prototype.setProperty=i,s.CSSStyleDeclaration.prototype.removeProperty=o})}function d5({mediaInteractionCb:e,blockClass:t,blockSelector:n,unblockSelector:r,mirror:s,sampling:i,doc:o}){const a=vt(u=>ed(vt(d=>{const c=zd(d);if(!c||jr(c,t,n,r,!0))return;const{currentTime:f,volume:p,muted:g,playbackRate:m}=c;e({type:u,id:s.getId(c),currentTime:f,volume:p,muted:g,playbackRate:m})}),i.media||500)),l=[hr("play",a(0),o),hr("pause",a(1),o),hr("seeked",a(2),o),hr("volumechange",a(3),o),hr("ratechange",a(4),o)];return vt(()=>{l.forEach(u=>u())})}function f5({fontCb:e,doc:t}){const n=t.defaultView;if(!n)return()=>{};const r=[],s=new WeakMap,i=n.FontFace;n.FontFace=function(l,u,d){const c=new i(l,u,d);return s.set(c,{family:l,buffer:typeof u!="string",descriptors:d,fontSource:typeof u=="string"?u:JSON.stringify(Array.from(new Uint8Array(u)))}),c};const o=pw(t.fonts,"add",function(a){return function(l){return om(vt(()=>{const u=s.get(l);u&&(e(u),s.delete(l))}),0),a.apply(this,[l])}});return r.push(()=>{n.FontFace=i}),r.push(o),vt(()=>{r.forEach(a=>a())})}function h5(e){const{doc:t,mirror:n,blockClass:r,blockSelector:s,unblockSelector:i,selectionCb:o}=e;let a=!0;const l=vt(()=>{const u=t.getSelection();if(!u||a&&Es([u,"optionalAccess",f=>f.isCollapsed]))return;a=u.isCollapsed||!1;const d=[],c=u.rangeCount||0;for(let f=0;f<c;f++){const p=u.getRangeAt(f),{startContainer:g,startOffset:m,endContainer:y,endOffset:b}=p;jr(g,r,s,i,!0)||jr(y,r,s,i,!0)||d.push({start:n.getId(g),startOffset:m,end:n.getId(y),endOffset:b})}o({ranges:d})});return l(),hr("selectionchange",l)}function p5({doc:e,customElementCb:t}){const n=e.defaultView;return!n||!n.customElements?()=>{}:pw(n.customElements,"define",function(s){return function(i,o,a){try{t({define:{name:i}})}catch{}return s.apply(this,[i,o,a])}})}function m5(e,t={}){const n=e.doc.defaultView;if(!n)return()=>{};let r;e.recordDOM&&(r=hI(e,e.doc));const s=s5(e),i=i5(e),o=pI(e),a=o5(e,{win:n}),l=l5(e),u=d5(e);let d=()=>{},c=()=>{},f=()=>{},p=()=>{};e.recordDOM&&(d=u5(e,{win:n}),c=mI(e,e.doc),f=c5(e,{win:n}),e.collectFonts&&(p=f5(e)));const g=h5(e),m=p5(e),y=[];for(const b of e.plugins)y.push(b.observer(b.callback,n,b.options));return vt(()=>{Ol.forEach(b=>b.reset()),Es([r,"optionalAccess",b=>b.disconnect,"call",b=>b()]),s(),i(),o(),a(),l(),u(),d(),c(),f(),p(),g(),m(),y.forEach(b=>b())})}function bf(e){return typeof window[e]<"u"}function wf(e){return!!(typeof window[e]<"u"&&window[e].prototype&&"insertRule"in window[e].prototype&&"deleteRule"in window[e].prototype)}class cy{constructor(t){this.generateIdFn=t,this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap}getId(t,n,r,s){const i=r||this.getIdToRemoteIdMap(t),o=s||this.getRemoteIdToIdMap(t);let a=i.get(n);return a||(a=this.generateIdFn(),i.set(n,a),o.set(a,n)),a}getIds(t,n){const r=this.getIdToRemoteIdMap(t),s=this.getRemoteIdToIdMap(t);return n.map(i=>this.getId(t,i,r,s))}getRemoteId(t,n,r){const s=r||this.getRemoteIdToIdMap(t);if(typeof n!="number")return n;const i=s.get(n);return i||-1}getRemoteIds(t,n){const r=this.getRemoteIdToIdMap(t);return n.map(s=>this.getRemoteId(t,s,r))}reset(t){if(!t){this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap;return}this.iframeIdToRemoteIdMap.delete(t),this.iframeRemoteIdToIdMap.delete(t)}getIdToRemoteIdMap(t){let n=this.iframeIdToRemoteIdMap.get(t);return n||(n=new Map,this.iframeIdToRemoteIdMap.set(t,n)),n}getRemoteIdToIdMap(t){let n=this.iframeRemoteIdToIdMap.get(t);return n||(n=new Map,this.iframeRemoteIdToIdMap.set(t,n)),n}}function T1(e){let t,n=e[0],r=1;for(;r<e.length;){const s=e[r],i=e[r+1];if(r+=2,(s==="optionalAccess"||s==="optionalCall")&&n==null)return;s==="access"||s==="optionalAccess"?(t=n,n=i(n)):(s==="call"||s==="optionalCall")&&(n=i((...o)=>n.call(t,...o)),t=void 0)}return n}class g5{constructor(){this.crossOriginIframeMirror=new cy(hw),this.crossOriginIframeRootIdMap=new WeakMap}addIframe(){}addLoadListener(){}attachIframe(){}}class v5{constructor(t){this.iframes=new WeakMap,this.crossOriginIframeMap=new WeakMap,this.crossOriginIframeMirror=new cy(hw),this.crossOriginIframeRootIdMap=new WeakMap,this.mutationCb=t.mutationCb,this.wrappedEmit=t.wrappedEmit,this.stylesheetManager=t.stylesheetManager,this.recordCrossOriginIframes=t.recordCrossOriginIframes,this.crossOriginIframeStyleMirror=new cy(this.stylesheetManager.styleMirror.generateId.bind(this.stylesheetManager.styleMirror)),this.mirror=t.mirror,this.recordCrossOriginIframes&&window.addEventListener("message",this.handleMessage.bind(this))}addIframe(t){this.iframes.set(t,!0),t.contentWindow&&this.crossOriginIframeMap.set(t.contentWindow,t)}addLoadListener(t){this.loadListener=t}attachIframe(t,n){this.mutationCb({adds:[{parentId:this.mirror.getId(t),nextId:null,node:n}],removes:[],texts:[],attributes:[],isAttachIframe:!0}),T1([this,"access",r=>r.loadListener,"optionalCall",r=>r(t)]),t.contentDocument&&t.contentDocument.adoptedStyleSheets&&t.contentDocument.adoptedStyleSheets.length>0&&this.stylesheetManager.adoptStyleSheets(t.contentDocument.adoptedStyleSheets,this.mirror.getId(t.contentDocument))}handleMessage(t){const n=t;if(n.data.type!=="rrweb"||n.origin!==n.data.origin||!t.source)return;const s=this.crossOriginIframeMap.get(t.source);if(!s)return;const i=this.transformCrossOriginEvent(s,n.data.event);i&&this.wrappedEmit(i,n.data.isCheckout)}transformCrossOriginEvent(t,n){switch(n.type){case ot.FullSnapshot:{this.crossOriginIframeMirror.reset(t),this.crossOriginIframeStyleMirror.reset(t),this.replaceIdOnNode(n.data.node,t);const r=n.data.node.id;return this.crossOriginIframeRootIdMap.set(t,r),this.patchRootIdOnNode(n.data.node,r),{timestamp:n.timestamp,type:ot.IncrementalSnapshot,data:{source:Xe.Mutation,adds:[{parentId:this.mirror.getId(t),nextId:null,node:n.data.node}],removes:[],texts:[],attributes:[],isAttachIframe:!0}}}case ot.Meta:case ot.Load:case ot.DomContentLoaded:return!1;case ot.Plugin:return n;case ot.Custom:return this.replaceIds(n.data.payload,t,["id","parentId","previousId","nextId"]),n;case ot.IncrementalSnapshot:switch(n.data.source){case Xe.Mutation:return n.data.adds.forEach(r=>{this.replaceIds(r,t,["parentId","nextId","previousId"]),this.replaceIdOnNode(r.node,t);const s=this.crossOriginIframeRootIdMap.get(t);s&&this.patchRootIdOnNode(r.node,s)}),n.data.removes.forEach(r=>{this.replaceIds(r,t,["parentId","id"])}),n.data.attributes.forEach(r=>{this.replaceIds(r,t,["id"])}),n.data.texts.forEach(r=>{this.replaceIds(r,t,["id"])}),n;case Xe.Drag:case Xe.TouchMove:case Xe.MouseMove:return n.data.positions.forEach(r=>{this.replaceIds(r,t,["id"])}),n;case Xe.ViewportResize:return!1;case Xe.MediaInteraction:case Xe.MouseInteraction:case Xe.Scroll:case Xe.CanvasMutation:case Xe.Input:return this.replaceIds(n.data,t,["id"]),n;case Xe.StyleSheetRule:case Xe.StyleDeclaration:return this.replaceIds(n.data,t,["id"]),this.replaceStyleIds(n.data,t,["styleId"]),n;case Xe.Font:return n;case Xe.Selection:return n.data.ranges.forEach(r=>{this.replaceIds(r,t,["start","end"])}),n;case Xe.AdoptedStyleSheet:return this.replaceIds(n.data,t,["id"]),this.replaceStyleIds(n.data,t,["styleIds"]),T1([n,"access",r=>r.data,"access",r=>r.styles,"optionalAccess",r=>r.forEach,"call",r=>r(s=>{this.replaceStyleIds(s,t,["styleId"])})]),n}}return!1}replace(t,n,r,s){for(const i of s)!Array.isArray(n[i])&&typeof n[i]!="number"||(Array.isArray(n[i])?n[i]=t.getIds(r,n[i]):n[i]=t.getId(r,n[i]));return n}replaceIds(t,n,r){return this.replace(this.crossOriginIframeMirror,t,n,r)}replaceStyleIds(t,n,r){return this.replace(this.crossOriginIframeStyleMirror,t,n,r)}replaceIdOnNode(t,n){this.replaceIds(t,n,["id","rootId"]),"childNodes"in t&&t.childNodes.forEach(r=>{this.replaceIdOnNode(r,n)})}patchRootIdOnNode(t,n){t.type!==_n.Document&&!t.rootId&&(t.rootId=n),"childNodes"in t&&t.childNodes.forEach(r=>{this.patchRootIdOnNode(r,n)})}}class y5{init(){}addShadowRoot(){}observeAttachShadow(){}reset(){}}class b5{constructor(t){this.shadowDoms=new WeakSet,this.restoreHandlers=[],this.mutationCb=t.mutationCb,this.scrollCb=t.scrollCb,this.bypassOptions=t.bypassOptions,this.mirror=t.mirror,this.init()}init(){this.reset(),this.patchAttachShadow(Element,document)}addShadowRoot(t,n){if(!Pc(t)||this.shadowDoms.has(t))return;this.shadowDoms.add(t),this.bypassOptions.canvasManager.addShadowRoot(t);const r=hI({...this.bypassOptions,doc:n,mutationCb:this.mutationCb,mirror:this.mirror,shadowDomManager:this},t);this.restoreHandlers.push(()=>r.disconnect()),this.restoreHandlers.push(pI({...this.bypassOptions,scrollCb:this.scrollCb,doc:t,mirror:this.mirror})),om(()=>{t.adoptedStyleSheets&&t.adoptedStyleSheets.length>0&&this.bypassOptions.stylesheetManager.adoptStyleSheets(t.adoptedStyleSheets,this.mirror.getId(t.host)),this.restoreHandlers.push(mI({mirror:this.mirror,stylesheetManager:this.bypassOptions.stylesheetManager},t))},0)}observeAttachShadow(t){!t.contentWindow||!t.contentDocument||this.patchAttachShadow(t.contentWindow.Element,t.contentDocument)}patchAttachShadow(t,n){const r=this;this.restoreHandlers.push(pw(t.prototype,"attachShadow",function(s){return function(i){const o=s.call(this,i);return this.shadowRoot&&dI(this)&&r.addShadowRoot(this.shadowRoot,n),o}}))}reset(){this.restoreHandlers.forEach(t=>{try{t()}catch{}}),this.restoreHandlers=[],this.shadowDoms=new WeakSet,this.bypassOptions.canvasManager.resetShadowRoots()}}class R1{reset(){}freeze(){}unfreeze(){}lock(){}unlock(){}snapshot(){}addWindow(){}addShadowRoot(){}resetShadowRoots(){}}class w5{constructor(t){this.trackedLinkElements=new WeakSet,this.styleMirror=new G4,this.mutationCb=t.mutationCb,this.adoptedStyleSheetCb=t.adoptedStyleSheetCb}attachLinkElement(t,n){"_cssText"in n.attributes&&this.mutationCb({adds:[],removes:[],texts:[],attributes:[{id:n.id,attributes:n.attributes}]}),this.trackLinkElement(t)}trackLinkElement(t){this.trackedLinkElements.has(t)||(this.trackedLinkElements.add(t),this.trackStylesheetInLinkElement(t))}adoptStyleSheets(t,n){if(t.length===0)return;const r={id:n,styleIds:[]},s=[];for(const i of t){let o;this.styleMirror.has(i)?o=this.styleMirror.getId(i):(o=this.styleMirror.add(i),s.push({styleId:o,rules:Array.from(i.rules||CSSRule,(a,l)=>({rule:YR(a),index:l}))})),r.styleIds.push(o)}s.length>0&&(r.styles=s),this.adoptedStyleSheetCb(r)}reset(){this.styleMirror.reset(),this.trackedLinkElements=new WeakSet}trackStylesheetInLinkElement(t){}}class S5{constructor(){this.nodeMap=new WeakMap,this.active=!1}inOtherBuffer(t,n){const r=this.nodeMap.get(t);return r&&Array.from(r).some(s=>s!==n)}add(t,n){this.active||(this.active=!0,X4(()=>{this.nodeMap=new WeakMap,this.active=!1})),this.nodeMap.set(t,(this.nodeMap.get(t)||new Set).add(n))}destroy(){}}let cn,Jh;try{if(Array.from([1],e=>e*2)[0]!==2){const e=document.createElement("iframe");document.body.appendChild(e),Array.from=Gr([e,"access",t=>t.contentWindow,"optionalAccess",t=>t.Array,"access",t=>t.from])||Array.from,document.body.removeChild(e)}}catch(e){console.debug("Unable to override Array.from",e)}const _s=S4();function Li(e={}){const{emit:t,checkoutEveryNms:n,checkoutEveryNth:r,blockClass:s="rr-block",blockSelector:i=null,unblockSelector:o=null,ignoreClass:a="rr-ignore",ignoreSelector:l=null,maskAllText:u=!1,maskTextClass:d="rr-mask",unmaskTextClass:c=null,maskTextSelector:f=null,unmaskTextSelector:p=null,inlineStylesheet:g=!0,maskAllInputs:m,maskInputOptions:y,slimDOMOptions:b,maskAttributeFn:w,maskInputFn:S,maskTextFn:P,maxCanvasSize:E=null,packFn:T,sampling:C={},dataURLOptions:k={},mousemoveWait:x,recordDOM:I=!0,recordCanvas:M=!1,recordCrossOriginIframes:O=!1,recordAfter:A=e.recordAfter==="DOMContentLoaded"?e.recordAfter:"load",userTriggeredOnInput:D=!1,collectFonts:V=!1,inlineImages:H=!1,plugins:G,keepIframeSrcFn:j=()=>!1,ignoreCSSAttributes:B=new Set([]),errorHandler:W,onMutation:Z,getCanvasManager:q}=e;n5(W);const K=O?window.parent===window:!0;let pe=!1;if(!K)try{window.parent.document&&(pe=!1)}catch{pe=!0}if(K&&!t)throw new Error("emit function is required");if(!K&&!pe)return()=>{};x!==void 0&&C.mousemove===void 0&&(C.mousemove=x),_s.reset();const ue=m===!0?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0,radio:!0,checkbox:!0}:y!==void 0?y:{},le=b===!0||b==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaVerification:!0,headMetaAuthorship:b==="all",headMetaDescKeywords:b==="all"}:b||{};W4();let J,be=0;const Se=ye=>{for(const ke of G||[])ke.eventProcessor&&(ye=ke.eventProcessor(ye));return T&&!pe&&(ye=T(ye)),ye};cn=(ye,ke)=>{const fe=ye;if(fe.timestamp=Xh(),Gr([Ol,"access",Ae=>Ae[0],"optionalAccess",Ae=>Ae.isFrozen,"call",Ae=>Ae()])&&fe.type!==ot.FullSnapshot&&!(fe.type===ot.IncrementalSnapshot&&fe.data.source===Xe.Mutation)&&Ol.forEach(Ae=>Ae.unfreeze()),K)Gr([t,"optionalCall",Ae=>Ae(Se(fe),ke)]);else if(pe){const Ae={type:"rrweb",event:Se(fe),origin:window.location.origin,isCheckout:ke};window.parent.postMessage(Ae,"*")}if(fe.type===ot.FullSnapshot)J=fe,be=0;else if(fe.type===ot.IncrementalSnapshot){if(fe.data.source===Xe.Mutation&&fe.data.isAttachIframe)return;be++;const Ae=r&&be>=r,_e=n&&J&&fe.timestamp-J.timestamp>n;(Ae||_e)&&Ee(!0)}};const te=ye=>{cn({type:ot.IncrementalSnapshot,data:{source:Xe.Mutation,...ye}})},Y=ye=>cn({type:ot.IncrementalSnapshot,data:{source:Xe.Scroll,...ye}}),ze=ye=>cn({type:ot.IncrementalSnapshot,data:{source:Xe.CanvasMutation,...ye}}),F=ye=>cn({type:ot.IncrementalSnapshot,data:{source:Xe.AdoptedStyleSheet,...ye}}),N=new w5({mutationCb:te,adoptedStyleSheetCb:F}),ee=typeof __RRWEB_EXCLUDE_IFRAME__=="boolean"&&__RRWEB_EXCLUDE_IFRAME__?new g5:new v5({mirror:_s,mutationCb:te,stylesheetManager:N,recordCrossOriginIframes:O,wrappedEmit:cn});for(const ye of G||[])ye.getMirror&&ye.getMirror({nodeMirror:_s,crossOriginIframeMirror:ee.crossOriginIframeMirror,crossOriginIframeStyleMirror:ee.crossOriginIframeStyleMirror});const se=new S5,oe=k5(q,{mirror:_s,win:window,mutationCb:ye=>cn({type:ot.IncrementalSnapshot,data:{source:Xe.CanvasMutation,...ye}}),recordCanvas:M,blockClass:s,blockSelector:i,unblockSelector:o,maxCanvasSize:E,sampling:C.canvas,dataURLOptions:k,errorHandler:W}),ge=typeof __RRWEB_EXCLUDE_SHADOW_DOM__=="boolean"&&__RRWEB_EXCLUDE_SHADOW_DOM__?new y5:new b5({mutationCb:te,scrollCb:Y,bypassOptions:{onMutation:Z,blockClass:s,blockSelector:i,unblockSelector:o,maskAllText:u,maskTextClass:d,unmaskTextClass:c,maskTextSelector:f,unmaskTextSelector:p,inlineStylesheet:g,maskInputOptions:ue,dataURLOptions:k,maskAttributeFn:w,maskTextFn:P,maskInputFn:S,recordCanvas:M,inlineImages:H,sampling:C,slimDOMOptions:le,iframeManager:ee,stylesheetManager:N,canvasManager:oe,keepIframeSrcFn:j,processedNodeManager:se},mirror:_s}),Ee=(ye=!1)=>{if(!I)return;cn({type:ot.Meta,data:{href:window.location.href,width:iI(),height:sI()}},ye),N.reset(),ge.init(),Ol.forEach(fe=>fe.lock());const ke=j4(document,{mirror:_s,blockClass:s,blockSelector:i,unblockSelector:o,maskAllText:u,maskTextClass:d,unmaskTextClass:c,maskTextSelector:f,unmaskTextSelector:p,inlineStylesheet:g,maskAllInputs:ue,maskAttributeFn:w,maskInputFn:S,maskTextFn:P,slimDOM:le,dataURLOptions:k,recordCanvas:M,inlineImages:H,onSerialize:fe=>{lI(fe,_s)&&ee.addIframe(fe),uI(fe,_s)&&N.trackLinkElement(fe),ly(fe)&&ge.addShadowRoot(fe.shadowRoot,document)},onIframeLoad:(fe,Ae)=>{ee.attachIframe(fe,Ae),fe.contentWindow&&oe.addWindow(fe.contentWindow),ge.observeAttachShadow(fe)},onStylesheetLoad:(fe,Ae)=>{N.attachLinkElement(fe,Ae)},keepIframeSrcFn:j});if(!ke)return console.warn("Failed to snapshot the document");cn({type:ot.FullSnapshot,data:{node:ke,initialOffset:rI(window)}}),Ol.forEach(fe=>fe.unlock()),document.adoptedStyleSheets&&document.adoptedStyleSheets.length>0&&N.adoptStyleSheets(document.adoptedStyleSheets,_s.getId(document))};Jh=Ee;try{const ye=[],ke=Ae=>vt(m5)({onMutation:Z,mutationCb:te,mousemoveCb:(_e,$e)=>cn({type:ot.IncrementalSnapshot,data:{source:$e,positions:_e}}),mouseInteractionCb:_e=>cn({type:ot.IncrementalSnapshot,data:{source:Xe.MouseInteraction,..._e}}),scrollCb:Y,viewportResizeCb:_e=>cn({type:ot.IncrementalSnapshot,data:{source:Xe.ViewportResize,..._e}}),inputCb:_e=>cn({type:ot.IncrementalSnapshot,data:{source:Xe.Input,..._e}}),mediaInteractionCb:_e=>cn({type:ot.IncrementalSnapshot,data:{source:Xe.MediaInteraction,..._e}}),styleSheetRuleCb:_e=>cn({type:ot.IncrementalSnapshot,data:{source:Xe.StyleSheetRule,..._e}}),styleDeclarationCb:_e=>cn({type:ot.IncrementalSnapshot,data:{source:Xe.StyleDeclaration,..._e}}),canvasMutationCb:ze,fontCb:_e=>cn({type:ot.IncrementalSnapshot,data:{source:Xe.Font,..._e}}),selectionCb:_e=>{cn({type:ot.IncrementalSnapshot,data:{source:Xe.Selection,..._e}})},customElementCb:_e=>{cn({type:ot.IncrementalSnapshot,data:{source:Xe.CustomElement,..._e}})},blockClass:s,ignoreClass:a,ignoreSelector:l,maskAllText:u,maskTextClass:d,unmaskTextClass:c,maskTextSelector:f,unmaskTextSelector:p,maskInputOptions:ue,inlineStylesheet:g,sampling:C,recordDOM:I,recordCanvas:M,inlineImages:H,userTriggeredOnInput:D,collectFonts:V,doc:Ae,maskAttributeFn:w,maskInputFn:S,maskTextFn:P,keepIframeSrcFn:j,blockSelector:i,unblockSelector:o,slimDOMOptions:le,dataURLOptions:k,mirror:_s,iframeManager:ee,stylesheetManager:N,shadowDomManager:ge,processedNodeManager:se,canvasManager:oe,ignoreCSSAttributes:B,plugins:Gr([G,"optionalAccess",_e=>_e.filter,"call",_e=>_e($e=>$e.observer),"optionalAccess",_e=>_e.map,"call",_e=>_e($e=>({observer:$e.observer,options:$e.options,callback:We=>cn({type:ot.Plugin,data:{plugin:$e.name,payload:We}})}))])||[]},{});ee.addLoadListener(Ae=>{try{ye.push(ke(Ae.contentDocument))}catch(_e){console.warn(_e)}});const fe=()=>{Ee(),ye.push(ke(document))};return document.readyState==="interactive"||document.readyState==="complete"?fe():(ye.push(hr("DOMContentLoaded",()=>{cn({type:ot.DomContentLoaded,data:{}}),A==="DOMContentLoaded"&&fe()})),ye.push(hr("load",()=>{cn({type:ot.Load,data:{}}),A==="load"&&fe()},window))),()=>{ye.forEach(Ae=>Ae()),se.destroy(),Jh=void 0,r5()}}catch(ye){console.warn(ye)}}function _5(e){if(!Jh)throw new Error("please take full snapshot after start recording");Jh(e)}Li.mirror=_s;Li.takeFullSnapshot=_5;function k5(e,t){try{return e?e(t):new R1}catch{return console.warn("Unable to initialize CanvasManager"),new R1}}const qe=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,I1=["info","warn","error","log"],ih="[Replay] ";function yg(e,t="info"){No({category:"console",data:{logger:"replay"},level:t,message:`${ih}${e}`},{level:t})}function x5(){let e=!1,t=!1;const n={exception:()=>{},infoTick:()=>{},setConfig:r=>{e=r.captureExceptions,t=r.traceInternals}};return qe?(I1.forEach(r=>{n[r]=(...s)=>{Pe[r](ih,...s),t&&yg(s.join(""),SR(r))}}),n.exception=(r,...s)=>{s.length&&n.error&&n.error(...s),Pe.error(ih,r),e?li(r):t&&yg(r,"error")},n.infoTick=(...r)=>{Pe.info(ih,...r),t&&setTimeout(()=>yg(r[0]),0)}):I1.forEach(r=>{n[r]=()=>{}}),n}const Ge=x5(),E5=3,C5=5;function gw(e){return e>9999999999?e:e*1e3}function bg(e){return e>9999999999?e/1e3:e}function jd(e,t){t.category!=="sentry.transaction"&&(["ui.click","ui.input"].includes(t.category)?e.triggerUserActivity():e.checkAndHandleExpiredSession(),e.addUpdate(()=>(e.throttledAddEvent({type:ot.Custom,timestamp:(t.timestamp||0)*1e3,data:{tag:"breadcrumb",payload:ni(t,10,1e3)}}),t.category==="console")))}const P5="button,a";function gI(e){return e.closest(P5)||e}function vI(e){const t=yI(e);return!t||!(t instanceof Element)?t:gI(t)}function yI(e){return T5(e)?e.target:e}function T5(e){return typeof e=="object"&&!!e&&"target"in e}let co;function R5(e){return co||(co=[],I5()),co.push(e),()=>{const t=co?co.indexOf(e):-1;t>-1&&co.splice(t,1)}}function I5(){Tr(zt,"open",function(e){return function(...t){if(co)try{co.forEach(n=>n())}catch{}return e.apply(zt,t)}})}const A5=new Set([Xe.Mutation,Xe.StyleSheetRule,Xe.StyleDeclaration,Xe.AdoptedStyleSheet,Xe.CanvasMutation,Xe.Selection,Xe.MediaInteraction]);function O5(e,t,n){e.handleClick(t,n)}class M5{constructor(t,n,r=jd){this._lastMutation=0,this._lastScroll=0,this._clicks=[],this._timeout=n.timeout/1e3,this._threshold=n.threshold/1e3,this._scrollTimeout=n.scrollTimeout/1e3,this._replay=t,this._ignoreSelector=n.ignoreSelector,this._addBreadcrumbEvent=r}addListeners(){const t=R5(()=>{this._lastMutation=A1()});this._teardown=()=>{t(),this._clicks=[],this._lastMutation=0,this._lastScroll=0}}removeListeners(){this._teardown&&this._teardown(),this._checkClickTimeout&&clearTimeout(this._checkClickTimeout)}handleClick(t,n){if(L5(n,this._ignoreSelector)||!$5(t))return;const r={timestamp:bg(t.timestamp),clickBreadcrumb:t,clickCount:0,node:n};this._clicks.some(s=>s.node===r.node&&Math.abs(s.timestamp-r.timestamp)<1)||(this._clicks.push(r),this._clicks.length===1&&this._scheduleCheckClicks())}registerMutation(t=Date.now()){this._lastMutation=bg(t)}registerScroll(t=Date.now()){this._lastScroll=bg(t)}registerClick(t){const n=gI(t);this._handleMultiClick(n)}_handleMultiClick(t){this._getClicks(t).forEach(n=>{n.clickCount++})}_getClicks(t){return this._clicks.filter(n=>n.node===t)}_checkClicks(){const t=[],n=A1();this._clicks.forEach(r=>{!r.mutationAfter&&this._lastMutation&&(r.mutationAfter=r.timestamp<=this._lastMutation?this._lastMutation-r.timestamp:void 0),!r.scrollAfter&&this._lastScroll&&(r.scrollAfter=r.timestamp<=this._lastScroll?this._lastScroll-r.timestamp:void 0),r.timestamp+this._timeout<=n&&t.push(r)});for(const r of t){const s=this._clicks.indexOf(r);s>-1&&(this._generateBreadcrumbs(r),this._clicks.splice(s,1))}this._clicks.length&&this._scheduleCheckClicks()}_generateBreadcrumbs(t){const n=this._replay,r=t.scrollAfter&&t.scrollAfter<=this._scrollTimeout,s=t.mutationAfter&&t.mutationAfter<=this._threshold,i=!r&&!s,{clickCount:o,clickBreadcrumb:a}=t;if(i){const l=Math.min(t.mutationAfter||this._timeout,this._timeout)*1e3,u=l<this._timeout*1e3?"mutation":"timeout",d={type:"default",message:a.message,timestamp:a.timestamp,category:"ui.slowClickDetected",data:{...a.data,url:zt.location.href,route:n.getCurrentRoute(),timeAfterClickMs:l,endReason:u,clickCount:o||1}};this._addBreadcrumbEvent(n,d);return}if(o>1){const l={type:"default",message:a.message,timestamp:a.timestamp,category:"ui.multiClick",data:{...a.data,url:zt.location.href,route:n.getCurrentRoute(),clickCount:o,metric:!0}};this._addBreadcrumbEvent(n,l)}}_scheduleCheckClicks(){this._checkClickTimeout&&clearTimeout(this._checkClickTimeout),this._checkClickTimeout=pu(()=>this._checkClicks(),1e3)}}const D5=["A","BUTTON","INPUT"];function L5(e,t){return!!(!D5.includes(e.tagName)||e.tagName==="INPUT"&&!["submit","button"].includes(e.getAttribute("type")||"")||e.tagName==="A"&&(e.hasAttribute("download")||e.hasAttribute("target")&&e.getAttribute("target")!=="_self")||t&&e.matches(t))}function $5(e){return!!(e.data&&typeof e.data.nodeId=="number"&&e.timestamp)}function A1(){return Date.now()/1e3}function F5(e,t){try{if(!N5(t))return;const{source:n}=t.data;if(A5.has(n)&&e.registerMutation(t.timestamp),n===Xe.Scroll&&e.registerScroll(t.timestamp),B5(t)){const{type:r,id:s}=t.data,i=Li.mirror.getNode(s);i instanceof HTMLElement&&r===ar.Click&&e.registerClick(i)}}catch{}}function N5(e){return e.type===E5}function B5(e){return e.data.source===Xe.MouseInteraction}function oi(e){return{timestamp:Date.now()/1e3,type:"default",...e}}var Zh;(function(e){e[e.Document=0]="Document",e[e.DocumentType=1]="DocumentType",e[e.Element=2]="Element",e[e.Text=3]="Text",e[e.CDATA=4]="CDATA",e[e.Comment=5]="Comment"})(Zh||(Zh={}));const V5=new Set(["id","class","aria-label","role","name","alt","title","data-test-id","data-testid","disabled","aria-disabled","data-sentry-component"]);function U5(e){const t={};!e["data-sentry-component"]&&e["data-sentry-element"]&&(e["data-sentry-component"]=e["data-sentry-element"]);for(const n in e)if(V5.has(n)){let r=n;(n==="data-testid"||n==="data-test-id")&&(r="testId"),t[r]=e[n]}return t}const H5=e=>t=>{if(!e.isEnabled())return;const n=z5(t);if(!n)return;const r=t.name==="click",s=r?t.event:void 0;r&&e.clickDetector&&s&&s.target&&!s.altKey&&!s.metaKey&&!s.ctrlKey&&!s.shiftKey&&O5(e.clickDetector,n,vI(t.event)),jd(e,n)};function bI(e,t){const n=Li.mirror.getId(e),r=n&&Li.mirror.getNode(n),s=r&&Li.mirror.getMeta(r),i=s&&q5(s)?s:null;return{message:t,data:i?{nodeId:n,node:{id:n,tagName:i.tagName,textContent:Array.from(i.childNodes).map(o=>o.type===Zh.Text&&o.textContent).filter(Boolean).map(o=>o.trim()).join(""),attributes:U5(i.attributes)}}:{}}}function z5(e){const{target:t,message:n}=j5(e);return oi({category:`ui.${e.name}`,...bI(t,n)})}function j5(e){const t=e.name==="click";let n,r=null;try{r=t?vI(e.event):yI(e.event),n=Ui(r,{maxStringLength:200})||"<unknown>"}catch{n="<unknown>"}return{target:r,message:n}}function q5(e){return e.type===Zh.Element}function W5(e,t){if(!e.isEnabled())return;e.updateUserActivity();const n=G5(t);n&&jd(e,n)}function G5(e){const{metaKey:t,shiftKey:n,ctrlKey:r,altKey:s,key:i,target:o}=e;if(!o||K5(o)||!i)return null;const a=t||r||s,l=i.length===1;if(!a&&l)return null;const u=Ui(o,{maxStringLength:200})||"<unknown>",d=bI(o,u);return oi({category:"ui.keyDown",message:u,data:{...d.data,metaKey:t,shiftKey:n,ctrlKey:r,altKey:s,key:i}})}function K5(e){return e.tagName==="INPUT"||e.tagName==="TEXTAREA"||e.isContentEditable}const Y5={resource:ej,paint:J5,navigation:Z5};function Sf(e,t){return({metric:n})=>void t.replayPerformanceEntries.push(e(n))}function X5(e){return e.map(Q5).filter(Boolean)}function Q5(e){const t=Y5[e.entryType];return t?t(e):null}function vu(e){return((gr||zt.performance.timeOrigin)+e)/1e3}function J5(e){const{duration:t,entryType:n,name:r,startTime:s}=e,i=vu(s);return{type:n,name:r,start:i,end:i+t,data:void 0}}function Z5(e){const{entryType:t,name:n,decodedBodySize:r,duration:s,domComplete:i,encodedBodySize:o,domContentLoadedEventStart:a,domContentLoadedEventEnd:l,domInteractive:u,loadEventStart:d,loadEventEnd:c,redirectCount:f,startTime:p,transferSize:g,type:m}=e;return s===0?null:{type:`${t}.${m}`,start:vu(p),end:vu(i),name:n,data:{size:g,decodedBodySize:r,encodedBodySize:o,duration:s,domInteractive:u,domContentLoadedEventStart:a,domContentLoadedEventEnd:l,loadEventStart:d,loadEventEnd:c,domComplete:i,redirectCount:f}}}function ej(e){const{entryType:t,initiatorType:n,name:r,responseEnd:s,startTime:i,decodedBodySize:o,encodedBodySize:a,responseStatus:l,transferSize:u}=e;return["fetch","xmlhttprequest"].includes(n)?null:{type:`${t}.${n}`,start:vu(i),end:vu(s),name:r,data:{size:u,statusCode:l,decodedBodySize:o,encodedBodySize:a}}}function tj(e){const t=e.entries[e.entries.length-1],n=t&&t.element?[t.element]:void 0;return am(e,"largest-contentful-paint",n)}function nj(e){return e.sources!==void 0}function rj(e){const t=[],n=[];for(const r of e.entries)if(nj(r)){const s=[];for(const i of r.sources)if(i.node){n.push(i.node);const o=Li.mirror.getId(i.node);o&&s.push(o)}t.push({value:r.value,nodeIds:s.length?s:void 0})}return am(e,"cumulative-layout-shift",n,t)}function sj(e){const t=e.entries[e.entries.length-1],n=t&&t.target?[t.target]:void 0;return am(e,"first-input-delay",n)}function ij(e){const t=e.entries[e.entries.length-1],n=t&&t.target?[t.target]:void 0;return am(e,"interaction-to-next-paint",n)}function am(e,t,n,r){const s=e.value,i=e.rating,o=vu(s);return{type:"web-vital",name:t,start:o,end:o,data:{value:s,size:s,rating:i,nodeIds:n?n.map(a=>Li.mirror.getId(a)):void 0,attributions:r}}}function oj(e){function t(s){e.performanceEntries.includes(s)||e.performanceEntries.push(s)}function n({entries:s}){s.forEach(t)}const r=[];return["navigation","paint","resource"].forEach(s=>{r.push(hu(s,n))}),r.push(FR(Sf(tj,e)),aw(Sf(rj,e)),NR(Sf(sj,e)),BR(Sf(ij,e))),()=>{r.forEach(s=>s())}}const aj='var t=Uint8Array,n=Uint16Array,r=Int32Array,e=new t([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),i=new t([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),a=new t([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),s=function(t,e){for(var i=new n(31),a=0;a<31;++a)i[a]=e+=1<<t[a-1];var s=new r(i[30]);for(a=1;a<30;++a)for(var o=i[a];o<i[a+1];++o)s[o]=o-i[a]<<5|a;return{b:i,r:s}},o=s(e,2),f=o.b,h=o.r;f[28]=258,h[258]=28;for(var l=s(i,0).r,u=new n(32768),c=0;c<32768;++c){var v=(43690&c)>>1|(21845&c)<<1;v=(61680&(v=(52428&v)>>2|(13107&v)<<2))>>4|(3855&v)<<4,u[c]=((65280&v)>>8|(255&v)<<8)>>1}var d=function(t,r,e){for(var i=t.length,a=0,s=new n(r);a<i;++a)t[a]&&++s[t[a]-1];var o,f=new n(r);for(a=1;a<r;++a)f[a]=f[a-1]+s[a-1]<<1;if(e){o=new n(1<<r);var h=15-r;for(a=0;a<i;++a)if(t[a])for(var l=a<<4|t[a],c=r-t[a],v=f[t[a]-1]++<<c,d=v|(1<<c)-1;v<=d;++v)o[u[v]>>h]=l}else for(o=new n(i),a=0;a<i;++a)t[a]&&(o[a]=u[f[t[a]-1]++]>>15-t[a]);return o},g=new t(288);for(c=0;c<144;++c)g[c]=8;for(c=144;c<256;++c)g[c]=9;for(c=256;c<280;++c)g[c]=7;for(c=280;c<288;++c)g[c]=8;var w=new t(32);for(c=0;c<32;++c)w[c]=5;var p=d(g,9,0),y=d(w,5,0),m=function(t){return(t+7)/8|0},b=function(n,r,e){return(null==e||e>n.length)&&(e=n.length),new t(n.subarray(r,e))},M=["unexpected EOF","invalid block type","invalid length/literal","invalid distance","stream finished","no stream handler",,"no callback","invalid UTF-8 data","extra field too long","date not in range 1980-2099","filename too long","stream finishing","invalid zip data"],E=function(t,n,r){var e=new Error(n||M[t]);if(e.code=t,Error.captureStackTrace&&Error.captureStackTrace(e,E),!r)throw e;return e},z=function(t,n,r){r<<=7&n;var e=n/8|0;t[e]|=r,t[e+1]|=r>>8},_=function(t,n,r){r<<=7&n;var e=n/8|0;t[e]|=r,t[e+1]|=r>>8,t[e+2]|=r>>16},x=function(r,e){for(var i=[],a=0;a<r.length;++a)r[a]&&i.push({s:a,f:r[a]});var s=i.length,o=i.slice();if(!s)return{t:F,l:0};if(1==s){var f=new t(i[0].s+1);return f[i[0].s]=1,{t:f,l:1}}i.sort((function(t,n){return t.f-n.f})),i.push({s:-1,f:25001});var h=i[0],l=i[1],u=0,c=1,v=2;for(i[0]={s:-1,f:h.f+l.f,l:h,r:l};c!=s-1;)h=i[i[u].f<i[v].f?u++:v++],l=i[u!=c&&i[u].f<i[v].f?u++:v++],i[c++]={s:-1,f:h.f+l.f,l:h,r:l};var d=o[0].s;for(a=1;a<s;++a)o[a].s>d&&(d=o[a].s);var g=new n(d+1),w=A(i[c-1],g,0);if(w>e){a=0;var p=0,y=w-e,m=1<<y;for(o.sort((function(t,n){return g[n.s]-g[t.s]||t.f-n.f}));a<s;++a){var b=o[a].s;if(!(g[b]>e))break;p+=m-(1<<w-g[b]),g[b]=e}for(p>>=y;p>0;){var M=o[a].s;g[M]<e?p-=1<<e-g[M]++-1:++a}for(;a>=0&&p;--a){var E=o[a].s;g[E]==e&&(--g[E],++p)}w=e}return{t:new t(g),l:w}},A=function(t,n,r){return-1==t.s?Math.max(A(t.l,n,r+1),A(t.r,n,r+1)):n[t.s]=r},D=function(t){for(var r=t.length;r&&!t[--r];);for(var e=new n(++r),i=0,a=t[0],s=1,o=function(t){e[i++]=t},f=1;f<=r;++f)if(t[f]==a&&f!=r)++s;else{if(!a&&s>2){for(;s>138;s-=138)o(32754);s>2&&(o(s>10?s-11<<5|28690:s-3<<5|12305),s=0)}else if(s>3){for(o(a),--s;s>6;s-=6)o(8304);s>2&&(o(s-3<<5|8208),s=0)}for(;s--;)o(a);s=1,a=t[f]}return{c:e.subarray(0,i),n:r}},T=function(t,n){for(var r=0,e=0;e<n.length;++e)r+=t[e]*n[e];return r},k=function(t,n,r){var e=r.length,i=m(n+2);t[i]=255&e,t[i+1]=e>>8,t[i+2]=255^t[i],t[i+3]=255^t[i+1];for(var a=0;a<e;++a)t[i+a+4]=r[a];return 8*(i+4+e)},U=function(t,r,s,o,f,h,l,u,c,v,m){z(r,m++,s),++f[256];for(var b=x(f,15),M=b.t,E=b.l,A=x(h,15),U=A.t,C=A.l,F=D(M),I=F.c,S=F.n,L=D(U),O=L.c,j=L.n,q=new n(19),B=0;B<I.length;++B)++q[31&I[B]];for(B=0;B<O.length;++B)++q[31&O[B]];for(var G=x(q,7),H=G.t,J=G.l,K=19;K>4&&!H[a[K-1]];--K);var N,P,Q,R,V=v+5<<3,W=T(f,g)+T(h,w)+l,X=T(f,M)+T(h,U)+l+14+3*K+T(q,H)+2*q[16]+3*q[17]+7*q[18];if(c>=0&&V<=W&&V<=X)return k(r,m,t.subarray(c,c+v));if(z(r,m,1+(X<W)),m+=2,X<W){N=d(M,E,0),P=M,Q=d(U,C,0),R=U;var Y=d(H,J,0);z(r,m,S-257),z(r,m+5,j-1),z(r,m+10,K-4),m+=14;for(B=0;B<K;++B)z(r,m+3*B,H[a[B]]);m+=3*K;for(var Z=[I,O],$=0;$<2;++$){var tt=Z[$];for(B=0;B<tt.length;++B){var nt=31&tt[B];z(r,m,Y[nt]),m+=H[nt],nt>15&&(z(r,m,tt[B]>>5&127),m+=tt[B]>>12)}}}else N=p,P=g,Q=y,R=w;for(B=0;B<u;++B){var rt=o[B];if(rt>255){_(r,m,N[(nt=rt>>18&31)+257]),m+=P[nt+257],nt>7&&(z(r,m,rt>>23&31),m+=e[nt]);var et=31&rt;_(r,m,Q[et]),m+=R[et],et>3&&(_(r,m,rt>>5&8191),m+=i[et])}else _(r,m,N[rt]),m+=P[rt]}return _(r,m,N[256]),m+P[256]},C=new r([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),F=new t(0),I=function(){for(var t=new Int32Array(256),n=0;n<256;++n){for(var r=n,e=9;--e;)r=(1&r&&-306674912)^r>>>1;t[n]=r}return t}(),S=function(){var t=-1;return{p:function(n){for(var r=t,e=0;e<n.length;++e)r=I[255&r^n[e]]^r>>>8;t=r},d:function(){return~t}}},L=function(){var t=1,n=0;return{p:function(r){for(var e=t,i=n,a=0|r.length,s=0;s!=a;){for(var o=Math.min(s+2655,a);s<o;++s)i+=e+=r[s];e=(65535&e)+15*(e>>16),i=(65535&i)+15*(i>>16)}t=e,n=i},d:function(){return(255&(t%=65521))<<24|(65280&t)<<8|(255&(n%=65521))<<8|n>>8}}},O=function(a,s,o,f,u){if(!u&&(u={l:1},s.dictionary)){var c=s.dictionary.subarray(-32768),v=new t(c.length+a.length);v.set(c),v.set(a,c.length),a=v,u.w=c.length}return function(a,s,o,f,u,c){var v=c.z||a.length,d=new t(f+v+5*(1+Math.ceil(v/7e3))+u),g=d.subarray(f,d.length-u),w=c.l,p=7&(c.r||0);if(s){p&&(g[0]=c.r>>3);for(var y=C[s-1],M=y>>13,E=8191&y,z=(1<<o)-1,_=c.p||new n(32768),x=c.h||new n(z+1),A=Math.ceil(o/3),D=2*A,T=function(t){return(a[t]^a[t+1]<<A^a[t+2]<<D)&z},F=new r(25e3),I=new n(288),S=new n(32),L=0,O=0,j=c.i||0,q=0,B=c.w||0,G=0;j+2<v;++j){var H=T(j),J=32767&j,K=x[H];if(_[J]=K,x[H]=J,B<=j){var N=v-j;if((L>7e3||q>24576)&&(N>423||!w)){p=U(a,g,0,F,I,S,O,q,G,j-G,p),q=L=O=0,G=j;for(var P=0;P<286;++P)I[P]=0;for(P=0;P<30;++P)S[P]=0}var Q=2,R=0,V=E,W=J-K&32767;if(N>2&&H==T(j-W))for(var X=Math.min(M,N)-1,Y=Math.min(32767,j),Z=Math.min(258,N);W<=Y&&--V&&J!=K;){if(a[j+Q]==a[j+Q-W]){for(var $=0;$<Z&&a[j+$]==a[j+$-W];++$);if($>Q){if(Q=$,R=W,$>X)break;var tt=Math.min(W,$-2),nt=0;for(P=0;P<tt;++P){var rt=j-W+P&32767,et=rt-_[rt]&32767;et>nt&&(nt=et,K=rt)}}}W+=(J=K)-(K=_[J])&32767}if(R){F[q++]=268435456|h[Q]<<18|l[R];var it=31&h[Q],at=31&l[R];O+=e[it]+i[at],++I[257+it],++S[at],B=j+Q,++L}else F[q++]=a[j],++I[a[j]]}}for(j=Math.max(j,B);j<v;++j)F[q++]=a[j],++I[a[j]];p=U(a,g,w,F,I,S,O,q,G,j-G,p),w||(c.r=7&p|g[p/8|0]<<3,p-=7,c.h=x,c.p=_,c.i=j,c.w=B)}else{for(j=c.w||0;j<v+w;j+=65535){var st=j+65535;st>=v&&(g[p/8|0]=w,st=v),p=k(g,p+1,a.subarray(j,st))}c.i=v}return b(d,0,f+m(p)+u)}(a,null==s.level?6:s.level,null==s.mem?Math.ceil(1.5*Math.max(8,Math.min(13,Math.log(a.length)))):12+s.mem,o,f,u)},j=function(t,n,r){for(;r;++n)t[n]=r,r>>>=8},q=function(t,n){var r=n.filename;if(t[0]=31,t[1]=139,t[2]=8,t[8]=n.level<2?4:9==n.level?2:0,t[9]=3,0!=n.mtime&&j(t,4,Math.floor(new Date(n.mtime||Date.now())/1e3)),r){t[3]=8;for(var e=0;e<=r.length;++e)t[e+10]=r.charCodeAt(e)}},B=function(t){return 10+(t.filename?t.filename.length+1:0)},G=function(){function n(n,r){if("function"==typeof n&&(r=n,n={}),this.ondata=r,this.o=n||{},this.s={l:0,i:32768,w:32768,z:32768},this.b=new t(98304),this.o.dictionary){var e=this.o.dictionary.subarray(-32768);this.b.set(e,32768-e.length),this.s.i=32768-e.length}}return n.prototype.p=function(t,n){this.ondata(O(t,this.o,0,0,this.s),n)},n.prototype.push=function(n,r){this.ondata||E(5),this.s.l&&E(4);var e=n.length+this.s.z;if(e>this.b.length){if(e>2*this.b.length-32768){var i=new t(-32768&e);i.set(this.b.subarray(0,this.s.z)),this.b=i}var a=this.b.length-this.s.z;a&&(this.b.set(n.subarray(0,a),this.s.z),this.s.z=this.b.length,this.p(this.b,!1)),this.b.set(this.b.subarray(-32768)),this.b.set(n.subarray(a),32768),this.s.z=n.length-a+32768,this.s.i=32766,this.s.w=32768}else this.b.set(n,this.s.z),this.s.z+=n.length;this.s.l=1&r,(this.s.z>this.s.w+8191||r)&&(this.p(this.b,r||!1),this.s.w=this.s.i,this.s.i-=2)},n}();var H=function(){function t(t,n){this.c=L(),this.v=1,G.call(this,t,n)}return t.prototype.push=function(t,n){this.c.p(t),G.prototype.push.call(this,t,n)},t.prototype.p=function(t,n){var r=O(t,this.o,this.v&&(this.o.dictionary?6:2),n&&4,this.s);this.v&&(function(t,n){var r=n.level,e=0==r?0:r<6?1:9==r?3:2;if(t[0]=120,t[1]=e<<6|(n.dictionary&&32),t[1]|=31-(t[0]<<8|t[1])%31,n.dictionary){var i=L();i.p(n.dictionary),j(t,2,i.d())}}(r,this.o),this.v=0),n&&j(r,r.length-4,this.c.d()),this.ondata(r,n)},t}(),J="undefined"!=typeof TextEncoder&&new TextEncoder,K="undefined"!=typeof TextDecoder&&new TextDecoder;try{K.decode(F,{stream:!0})}catch(t){}var N=function(){function t(t){this.ondata=t}return t.prototype.push=function(t,n){this.ondata||E(5),this.d&&E(4),this.ondata(P(t),this.d=n||!1)},t}();function P(n,r){if(J)return J.encode(n);for(var e=n.length,i=new t(n.length+(n.length>>1)),a=0,s=function(t){i[a++]=t},o=0;o<e;++o){if(a+5>i.length){var f=new t(a+8+(e-o<<1));f.set(i),i=f}var h=n.charCodeAt(o);h<128||r?s(h):h<2048?(s(192|h>>6),s(128|63&h)):h>55295&&h<57344?(s(240|(h=65536+(1047552&h)|1023&n.charCodeAt(++o))>>18),s(128|h>>12&63),s(128|h>>6&63),s(128|63&h)):(s(224|h>>12),s(128|h>>6&63),s(128|63&h))}return b(i,0,a)}function Q(t){return function(t,n){n||(n={});var r=S(),e=t.length;r.p(t);var i=O(t,n,B(n),8),a=i.length;return q(i,n),j(i,a-8,r.d()),j(i,a-4,e),i}(P(t))}const R=new class{constructor(){this._init()}clear(){this._init()}addEvent(t){if(!t)throw new Error("Adding invalid event");const n=this._hasEvents?",":"";this.stream.push(n+t),this._hasEvents=!0}finish(){this.stream.push("]",!0);const t=function(t){let n=0;for(const r of t)n+=r.length;const r=new Uint8Array(n);for(let n=0,e=0,i=t.length;n<i;n++){const i=t[n];r.set(i,e),e+=i.length}return r}(this._deflatedData);return this._init(),t}_init(){this._hasEvents=!1,this._deflatedData=[],this.deflate=new H,this.deflate.ondata=(t,n)=>{this._deflatedData.push(t)},this.stream=new N(((t,n)=>{this.deflate.push(t,n)})),this.stream.push("[")}},V={clear:()=>{R.clear()},addEvent:t=>R.addEvent(t),finish:()=>R.finish(),compress:t=>Q(t)};addEventListener("message",(function(t){const n=t.data.method,r=t.data.id,e=t.data.arg;if(n in V&&"function"==typeof V[n])try{const t=V[n](e);postMessage({id:r,method:n,success:!0,response:t})}catch(t){postMessage({id:r,method:n,success:!1,response:t.message}),console.error(t)}})),postMessage({id:void 0,method:"init",success:!0,response:void 0});';function lj(){const e=new Blob([aj]);return URL.createObjectURL(e)}class vw extends Error{constructor(){super(`Event buffer exceeded maximum size of ${dw}.`)}}class wI{constructor(){this.events=[],this._totalSize=0,this.hasCheckout=!1,this.waitForCheckout=!1}get hasEvents(){return this.events.length>0}get type(){return"sync"}destroy(){this.events=[]}async addEvent(t){const n=JSON.stringify(t).length;if(this._totalSize+=n,this._totalSize>dw)throw new vw;this.events.push(t)}finish(){return new Promise(t=>{const n=this.events;this.clear(),t(JSON.stringify(n))})}clear(){this.events=[],this._totalSize=0,this.hasCheckout=!1}getEarliestTimestamp(){const t=this.events.map(n=>n.timestamp).sort()[0];return t?gw(t):null}}class uj{constructor(t){this._worker=t,this._id=0}ensureReady(){return this._ensureReadyPromise?this._ensureReadyPromise:(this._ensureReadyPromise=new Promise((t,n)=>{this._worker.addEventListener("message",({data:r})=>{r.success?t():n()},{once:!0}),this._worker.addEventListener("error",r=>{n(r)},{once:!0})}),this._ensureReadyPromise)}destroy(){qe&&Ge.info("Destroying compression worker"),this._worker.terminate()}postMessage(t,n){const r=this._getAndIncrementId();return new Promise((s,i)=>{const o=({data:a})=>{const l=a;if(l.method===t&&l.id===r){if(this._worker.removeEventListener("message",o),!l.success){qe&&Ge.error("Error in compression worker: ",l.response),i(new Error("Error in compression worker"));return}s(l.response)}};this._worker.addEventListener("message",o),this._worker.postMessage({id:r,method:t,arg:n})})}_getAndIncrementId(){return this._id++}}class cj{constructor(t){this._worker=new uj(t),this._earliestTimestamp=null,this._totalSize=0,this.hasCheckout=!1,this.waitForCheckout=!1}get hasEvents(){return!!this._earliestTimestamp}get type(){return"worker"}ensureReady(){return this._worker.ensureReady()}destroy(){this._worker.destroy()}addEvent(t){const n=gw(t.timestamp);(!this._earliestTimestamp||n<this._earliestTimestamp)&&(this._earliestTimestamp=n);const r=JSON.stringify(t);return this._totalSize+=r.length,this._totalSize>dw?Promise.reject(new vw):this._sendEventToWorker(r)}finish(){return this._finishRequest()}clear(){this._earliestTimestamp=null,this._totalSize=0,this.hasCheckout=!1,this._worker.postMessage("clear").then(null,t=>{qe&&Ge.exception(t,'Sending "clear" message to worker failed',t)})}getEarliestTimestamp(){return this._earliestTimestamp}_sendEventToWorker(t){return this._worker.postMessage("addEvent",t)}async _finishRequest(){const t=await this._worker.postMessage("finish");return this._earliestTimestamp=null,this._totalSize=0,t}}class dj{constructor(t){this._fallback=new wI,this._compression=new cj(t),this._used=this._fallback,this._ensureWorkerIsLoadedPromise=this._ensureWorkerIsLoaded()}get waitForCheckout(){return this._used.waitForCheckout}get type(){return this._used.type}get hasEvents(){return this._used.hasEvents}get hasCheckout(){return this._used.hasCheckout}set hasCheckout(t){this._used.hasCheckout=t}set waitForCheckout(t){this._used.waitForCheckout=t}destroy(){this._fallback.destroy(),this._compression.destroy()}clear(){return this._used.clear()}getEarliestTimestamp(){return this._used.getEarliestTimestamp()}addEvent(t){return this._used.addEvent(t)}async finish(){return await this.ensureWorkerIsLoaded(),this._used.finish()}ensureWorkerIsLoaded(){return this._ensureWorkerIsLoadedPromise}async _ensureWorkerIsLoaded(){try{await this._compression.ensureReady()}catch(t){qe&&Ge.exception(t,"Failed to load the compression worker, falling back to simple buffer");return}await this._switchToCompressionWorker()}async _switchToCompressionWorker(){const{events:t,hasCheckout:n,waitForCheckout:r}=this._fallback,s=[];for(const i of t)s.push(this._compression.addEvent(i));this._compression.hasCheckout=n,this._compression.waitForCheckout=r,this._used=this._compression;try{await Promise.all(s),this._fallback.clear()}catch(i){qe&&Ge.exception(i,"Failed to add events when switching buffers.")}}}function fj({useCompression:e,workerUrl:t}){if(e&&window.Worker){const n=hj(t);if(n)return n}return qe&&Ge.info("Using simple buffer"),new wI}function hj(e){try{const t=e||pj();if(!t)return;qe&&Ge.info(`Using compression worker${e?` from ${e}`:""}`);const n=new Worker(t);return new dj(n)}catch(t){qe&&Ge.exception(t,"Failed to create compression worker")}}function pj(){return typeof __SENTRY_EXCLUDE_REPLAY_WORKER__>"u"||!__SENTRY_EXCLUDE_REPLAY_WORKER__?lj():""}function yw(){try{return"sessionStorage"in zt&&!!zt.sessionStorage}catch{return!1}}function mj(e){gj(),e.session=void 0}function gj(){if(yw())try{zt.sessionStorage.removeItem(uw)}catch{}}function SI(e){return e===void 0?!1:Math.random()<e}function _I(e){const t=Date.now(),n=e.id||tn(),r=e.started||t,s=e.lastActivity||t,i=e.segmentId||0,o=e.sampled,a=e.previousSessionId;return{id:n,started:r,lastActivity:s,segmentId:i,sampled:o,previousSessionId:a}}function bw(e){if(yw())try{zt.sessionStorage.setItem(uw,JSON.stringify(e))}catch{}}function vj(e,t){return SI(e)?"session":t?"buffer":!1}function O1({sessionSampleRate:e,allowBuffering:t,stickySession:n=!1},{previousSessionId:r}={}){const s=vj(e,t),i=_I({sampled:s,previousSessionId:r});return n&&bw(i),i}function yj(){if(!yw())return null;try{const e=zt.sessionStorage.getItem(uw);if(!e)return null;const t=JSON.parse(e);return qe&&Ge.infoTick("Loading existing session"),_I(t)}catch{return null}}function dy(e,t,n=+new Date){return e===null||t===void 0||t<0?!0:t===0?!1:e+t<=n}function kI(e,{maxReplayDuration:t,sessionIdleExpire:n,targetTime:r=Date.now()}){return dy(e.started,t,r)||dy(e.lastActivity,n,r)}function xI(e,{sessionIdleExpire:t,maxReplayDuration:n}){return!(!kI(e,{sessionIdleExpire:t,maxReplayDuration:n})||e.sampled==="buffer"&&e.segmentId===0)}function wg({sessionIdleExpire:e,maxReplayDuration:t,previousSessionId:n},r){const s=r.stickySession&&yj();return s?xI(s,{sessionIdleExpire:e,maxReplayDuration:t})?(qe&&Ge.infoTick("Session in sessionStorage is expired, creating new one..."),O1(r,{previousSessionId:s.id})):s:(qe&&Ge.infoTick("Creating new session"),O1(r,{previousSessionId:n}))}function bj(e){return e.type===ot.Custom}function ww(e,t,n){return CI(e,t)?(EI(e,t,n),!0):!1}function wj(e,t,n){return CI(e,t)?EI(e,t,n):Promise.resolve(null)}async function EI(e,t,n){const{eventBuffer:r}=e;if(!r||r.waitForCheckout&&!n)return null;const s=e.recordingMode==="buffer";try{n&&s&&r.clear(),n&&(r.hasCheckout=!0,r.waitForCheckout=!1);const i=e.getOptions(),o=Sj(t,i.beforeAddRecordingEvent);return o?await r.addEvent(o):void 0}catch(i){const o=i&&i instanceof vw,a=o?"addEventSizeExceeded":"addEvent";if(o&&s)return r.clear(),r.waitForCheckout=!0,null;e.handleException(i),await e.stop({reason:a});const l=dt();l&&l.recordDroppedEvent("internal_sdk_error","replay")}}function CI(e,t){if(!e.eventBuffer||e.isPaused()||!e.isEnabled())return!1;const n=gw(t.timestamp);return n+e.timeouts.sessionIdlePause<Date.now()?!1:n>e.getContext().initialTimestamp+e.getOptions().maxReplayDuration?(qe&&Ge.infoTick(`Skipping event with timestamp ${n} because it is after maxReplayDuration`),!1):!0}function Sj(e,t){try{if(typeof t=="function"&&bj(e))return t(e)}catch(n){return qe&&Ge.exception(n,"An error occurred in the `beforeAddRecordingEvent` callback, skipping the event..."),null}return e}function Sw(e){return!e.type}function fy(e){return e.type==="transaction"}function _j(e){return e.type==="replay_event"}function M1(e){return e.type==="feedback"}function kj(e){return(t,n)=>{if(!e.isEnabled()||!Sw(t)&&!fy(t))return;const r=n&&n.statusCode;if(!(!r||r<200||r>=300)){if(fy(t)){xj(e,t);return}Ej(e,t)}}}function xj(e,t){const n=e.getContext();t.contexts&&t.contexts.trace&&t.contexts.trace.trace_id&&n.traceIds.size<100&&n.traceIds.add(t.contexts.trace.trace_id)}function Ej(e,t){const n=e.getContext();if(t.event_id&&n.errorIds.size<100&&n.errorIds.add(t.event_id),e.recordingMode!=="buffer"||!t.tags||!t.tags.replayId)return;const{beforeErrorSampling:r}=e.getOptions();typeof r=="function"&&!r(t)||pu(async()=>{try{await e.sendBufferedReplayOrFlush()}catch(s){e.handleException(s)}})}function Cj(e){return t=>{!e.isEnabled()||!Sw(t)||Pj(e,t)}}function Pj(e,t){const n=t.exception&&t.exception.values&&t.exception.values[0]&&t.exception.values[0].value;if(typeof n=="string"&&(n.match(/(reactjs\.org\/docs\/error-decoder\.html\?invariant=|react\.dev\/errors\/)(418|419|422|423|425)/)||n.match(/(does not match server-rendered HTML|Hydration failed because)/i))){const r=oi({category:"replay.hydrate-error",data:{url:VT()}});jd(e,r)}}function Tj(e){const t=dt();t&&t.on("beforeAddBreadcrumb",n=>Rj(e,n))}function Rj(e,t){if(!e.isEnabled()||!PI(t))return;const n=Ij(t);n&&jd(e,n)}function Ij(e){return!PI(e)||["fetch","xhr","sentry.event","sentry.transaction"].includes(e.category)||e.category.startsWith("ui.")?null:e.category==="console"?Aj(e):oi(e)}function Aj(e){const t=e.data&&e.data.arguments;if(!Array.isArray(t)||t.length===0)return oi(e);let n=!1;const r=t.map(s=>{if(!s)return s;if(typeof s=="string")return s.length>yf?(n=!0,`${s.slice(0,yf)}…`):s;if(typeof s=="object")try{const i=ni(s,7);return JSON.stringify(i).length>yf?(n=!0,`${JSON.stringify(i,null,2).slice(0,yf)}…`):i}catch{}return s});return oi({...e,data:{...e.data,arguments:r,...n?{_meta:{warnings:["CONSOLE_ARG_TRUNCATED"]}}:{}}})}function PI(e){return!!e.category}function Oj(e,t){return e.type||!e.exception||!e.exception.values||!e.exception.values.length?!1:!!(t.originalException&&t.originalException.__rrweb__)}function TI(){const e=Bt().getPropagationContext().dsc;e&&delete e.replay_id;const t=Rn();if(t){const n=Jo(t);delete n.replay_id}}function Mj(e,t){e.triggerUserActivity(),e.addUpdate(()=>t.timestamp?(e.throttledAddEvent({type:ot.Custom,timestamp:t.timestamp*1e3,data:{tag:"breadcrumb",payload:{timestamp:t.timestamp,type:"default",category:"sentry.feedback",data:{feedbackId:t.event_id}}}}),!1):!0)}function Dj(e,t){return e.recordingMode!=="buffer"||t.message===cw||!t.exception||t.type?!1:SI(e.getOptions().errorSampleRate)}function Lj(e){return Object.assign((t,n)=>!e.isEnabled()||e.isPaused()?t:_j(t)?(delete t.breadcrumbs,t):!Sw(t)&&!fy(t)&&!M1(t)?t:e.checkAndHandleExpiredSession()?M1(t)?(e.flush(),t.contexts.feedback.replay_id=e.getSessionId(),Mj(e,t),t):Oj(t,n)&&!e.getOptions()._experiments.captureExceptions?(qe&&Ge.log("Ignoring error from rrweb internals",t),null):((Dj(e,t)||e.recordingMode==="session")&&(t.tags={...t.tags,replayId:e.getSessionId()}),t):(TI(),t),{id:"Replay"})}function lm(e,t){return t.map(({type:n,start:r,end:s,name:i,data:o})=>{const a=e.throttledAddEvent({type:ot.Custom,timestamp:r,data:{tag:"performanceSpan",payload:{op:n,description:i,startTimestamp:r,endTimestamp:s,data:o}}});return typeof a=="string"?Promise.resolve(null):a})}function $j(e){const{from:t,to:n}=e,r=Date.now()/1e3;return{type:"navigation.push",start:r,end:r,name:n,data:{previous:t}}}function Fj(e){return t=>{if(!e.isEnabled())return;const n=$j(t);n!==null&&(e.getContext().urls.push(n.name),e.triggerUserActivity(),e.addUpdate(()=>(lm(e,[n]),!1)))}}function Nj(e,t){return qe&&e.getOptions()._experiments.traceInternals?!1:GU(t,dt())}function RI(e,t){e.isEnabled()&&t!==null&&(Nj(e,t.name)||e.addUpdate(()=>(lm(e,[t]),!0)))}function um(e){if(!e)return;const t=new TextEncoder;try{if(typeof e=="string")return t.encode(e).length;if(e instanceof URLSearchParams)return t.encode(e.toString()).length;if(e instanceof FormData){const n=MI(e);return t.encode(n).length}if(e instanceof Blob)return e.size;if(e instanceof ArrayBuffer)return e.byteLength}catch{}}function II(e){if(!e)return;const t=parseInt(e,10);return isNaN(t)?void 0:t}function AI(e){try{if(typeof e=="string")return[e];if(e instanceof URLSearchParams)return[e.toString()];if(e instanceof FormData)return[MI(e)];if(!e)return[void 0]}catch(t){return qe&&Ge.exception(t,"Failed to serialize body",e),[void 0,"BODY_PARSE_ERROR"]}return qe&&Ge.info("Skipping network body because of body type",e),[void 0,"UNPARSEABLE_BODY_TYPE"]}function ep(e,t){if(!e)return{headers:{},size:void 0,_meta:{warnings:[t]}};const n={...e._meta},r=n.warnings||[];return n.warnings=[...r,t],e._meta=n,e}function OI(e,t){if(!t)return null;const{startTimestamp:n,endTimestamp:r,url:s,method:i,statusCode:o,request:a,response:l}=t;return{type:e,start:n/1e3,end:r/1e3,name:s,data:En({method:i,statusCode:o,request:a,response:l})}}function td(e){return{headers:{},size:e,_meta:{warnings:["URL_SKIPPED"]}}}function Ao(e,t,n){if(!t&&Object.keys(e).length===0)return;if(!t)return{headers:e};if(!n)return{headers:e,size:t};const r={headers:e,size:t},{body:s,warnings:i}=Bj(n);return r.body=s,i&&i.length>0&&(r._meta={warnings:i}),r}function hy(e,t){return Object.entries(e).reduce((n,[r,s])=>{const i=r.toLowerCase();return t.includes(i)&&e[r]&&(n[i]=s),n},{})}function MI(e){return new URLSearchParams(e).toString()}function Bj(e){if(!e||typeof e!="string")return{body:e};const t=e.length>m1,n=Vj(e);if(t){const r=e.slice(0,m1);return n?{body:r,warnings:["MAYBE_JSON_TRUNCATED"]}:{body:`${r}…`,warnings:["TEXT_TRUNCATED"]}}if(n)try{return{body:JSON.parse(e)}}catch{}return{body:e}}function Vj(e){const t=e[0],n=e[e.length-1];return t==="["&&n==="]"||t==="{"&&n==="}"}function tp(e,t){const n=Uj(e);return Io(n,t)}function Uj(e,t=zt.document.baseURI){if(e.startsWith("http://")||e.startsWith("https://")||e.startsWith(zt.location.origin))return e;const n=new URL(e,t);if(n.origin!==new URL(t).origin)return e;const r=n.href;return!e.endsWith("/")&&r.endsWith("/")?r.slice(0,-1):r}async function Hj(e,t,n){try{const r=await jj(e,t,n),s=OI("resource.fetch",r);RI(n.replay,s)}catch(r){qe&&Ge.exception(r,"Failed to capture fetch breadcrumb")}}function zj(e,t){const{input:n,response:r}=t,s=n?DI(n):void 0,i=um(s),o=r?II(r.headers.get("content-length")):void 0;i!==void 0&&(e.data.request_body_size=i),o!==void 0&&(e.data.response_body_size=o)}async function jj(e,t,n){const r=Date.now(),{startTimestamp:s=r,endTimestamp:i=r}=t,{url:o,method:a,status_code:l=0,request_body_size:u,response_body_size:d}=e.data,c=tp(o,n.networkDetailAllowUrls)&&!tp(o,n.networkDetailDenyUrls),f=c?qj(n,t.input,u):td(u),p=await Wj(c,n,t.response,d);return{startTimestamp:s,endTimestamp:i,url:o,method:a,statusCode:l,request:f,response:p}}function qj({networkCaptureBodies:e,networkRequestHeaders:t},n,r){const s=n?Yj(n,t):{};if(!e)return Ao(s,r,void 0);const i=DI(n),[o,a]=AI(i),l=Ao(s,r,o);return a?ep(l,a):l}async function Wj(e,{networkCaptureBodies:t,networkResponseHeaders:n},r,s){if(!e&&s!==void 0)return td(s);const i=r?LI(r.headers,n):{};if(!r||!t&&s!==void 0)return Ao(i,s,void 0);const[o,a]=await Kj(r),l=Gj(o,{networkCaptureBodies:t,responseBodySize:s,captureDetails:e,headers:i});return a?ep(l,a):l}function Gj(e,{networkCaptureBodies:t,responseBodySize:n,captureDetails:r,headers:s}){try{const i=e&&e.length&&n===void 0?um(e):n;return r?t?Ao(s,i,e):Ao(s,i,void 0):td(i)}catch(i){return qe&&Ge.exception(i,"Failed to serialize response body"),Ao(s,n,void 0)}}async function Kj(e){const t=Xj(e);if(!t)return[void 0,"BODY_PARSE_ERROR"];try{return[await Qj(t)]}catch(n){return n instanceof Error&&n.message.indexOf("Timeout")>-1?(qe&&Ge.warn("Parsing text body from response timed out"),[void 0,"BODY_PARSE_TIMEOUT"]):(qe&&Ge.exception(n,"Failed to get text body from response"),[void 0,"BODY_PARSE_ERROR"])}}function DI(e=[]){if(!(e.length!==2||typeof e[1]!="object"))return e[1].body}function LI(e,t){const n={};return t.forEach(r=>{e.get(r)&&(n[r]=e.get(r))}),n}function Yj(e,t){return e.length===1&&typeof e[0]!="string"?D1(e[0],t):e.length===2?D1(e[1],t):{}}function D1(e,t){if(!e)return{};const n=e.headers;return n?n instanceof Headers?LI(n,t):Array.isArray(n)?{}:hy(n,t):{}}function Xj(e){try{return e.clone()}catch(t){qe&&Ge.exception(t,"Failed to clone response body")}}function Qj(e){return new Promise((t,n)=>{const r=pu(()=>n(new Error("Timeout while trying to read response body")),500);Jj(e).then(s=>t(s),s=>n(s)).finally(()=>clearTimeout(r))})}async function Jj(e){return await e.text()}async function Zj(e,t,n){try{const r=t8(e,t,n),s=OI("resource.xhr",r);RI(n.replay,s)}catch(r){qe&&Ge.exception(r,"Failed to capture xhr breadcrumb")}}function e8(e,t){const{xhr:n,input:r}=t;if(!n)return;const s=um(r),i=n.getResponseHeader("content-length")?II(n.getResponseHeader("content-length")):i8(n.response,n.responseType);s!==void 0&&(e.data.request_body_size=s),i!==void 0&&(e.data.response_body_size=i)}function t8(e,t,n){const r=Date.now(),{startTimestamp:s=r,endTimestamp:i=r,input:o,xhr:a}=t,{url:l,method:u,status_code:d=0,request_body_size:c,response_body_size:f}=e.data;if(!l)return null;if(!a||!tp(l,n.networkDetailAllowUrls)||tp(l,n.networkDetailDenyUrls)){const T=td(c),C=td(f);return{startTimestamp:s,endTimestamp:i,url:l,method:u,statusCode:d,request:T,response:C}}const p=a[ya],g=p?hy(p.request_headers,n.networkRequestHeaders):{},m=hy(n8(a),n.networkResponseHeaders),[y,b]=n.networkCaptureBodies?AI(o):[void 0],[w,S]=n.networkCaptureBodies?r8(a):[void 0],P=Ao(g,c,y),E=Ao(m,f,w);return{startTimestamp:s,endTimestamp:i,url:l,method:u,statusCode:d,request:b?ep(P,b):P,response:S?ep(E,S):E}}function n8(e){const t=e.getAllResponseHeaders();return t?t.split(`\r
53
+ `).reduce((n,r)=>{const[s,i]=r.split(": ");return i&&(n[s.toLowerCase()]=i),n},{}):{}}function r8(e){const t=[];try{return[e.responseText]}catch(n){t.push(n)}try{return s8(e.response,e.responseType)}catch(n){t.push(n)}return qe&&Ge.warn("Failed to get xhr response body",...t),[void 0]}function s8(e,t){try{if(typeof e=="string")return[e];if(e instanceof Document)return[e.body.outerHTML];if(t==="json"&&e&&typeof e=="object")return[JSON.stringify(e)];if(!e)return[void 0]}catch(n){return qe&&Ge.exception(n,"Failed to serialize body",e),[void 0,"BODY_PARSE_ERROR"]}return qe&&Ge.info("Skipping network body because of body type",e),[void 0,"UNPARSEABLE_BODY_TYPE"]}function i8(e,t){try{const n=t==="json"&&e&&typeof e=="object"?JSON.stringify(e):e;return um(n)}catch{return}}function o8(e){const t=dt();try{const{networkDetailAllowUrls:n,networkDetailDenyUrls:r,networkCaptureBodies:s,networkRequestHeaders:i,networkResponseHeaders:o}=e.getOptions(),a={replay:e,networkDetailAllowUrls:n,networkDetailDenyUrls:r,networkCaptureBodies:s,networkRequestHeaders:i,networkResponseHeaders:o};t&&t.on("beforeAddBreadcrumb",(l,u)=>a8(a,l,u))}catch{}}function a8(e,t,n){if(t.data)try{l8(t)&&c8(n)&&(e8(t,n),Zj(t,n,e)),u8(t)&&d8(n)&&(zj(t,n),Hj(t,n,e))}catch(r){qe&&Ge.exception(r,"Error when enriching network breadcrumb")}}function l8(e){return e.category==="xhr"}function u8(e){return e.category==="fetch"}function c8(e){return e&&e.xhr}function d8(e){return e&&e.response}function f8(e){const t=dt();zR(H5(e)),rm(Fj(e)),Tj(e),o8(e);const n=Lj(e);CU(n),t&&(t.on("beforeSendEvent",Cj(e)),t.on("afterSendEvent",kj(e)),t.on("createDsc",r=>{const s=e.getSessionId();s&&e.isEnabled()&&e.recordingMode==="session"&&e.checkAndHandleExpiredSession()&&(r.replay_id=s)}),t.on("spanStart",r=>{e.lastActiveSpan=r}),t.on("spanEnd",r=>{e.lastActiveSpan=r}),t.on("beforeSendFeedback",(r,s)=>{const i=e.getSessionId();s&&s.includeReplay&&e.isEnabled()&&i&&r.contexts&&r.contexts.feedback&&(r.contexts.feedback.replay_id=i)}))}async function h8(e){try{return Promise.all(lm(e,[p8(zt.performance.memory)]))}catch{return[]}}function p8(e){const{jsHeapSizeLimit:t,totalJSHeapSize:n,usedJSHeapSize:r}=e,s=Date.now()/1e3;return{type:"memory",name:"memory",start:s,end:s,data:{memory:{jsHeapSizeLimit:t,totalJSHeapSize:n,usedJSHeapSize:r}}}}function m8(e,t,n){let r,s,i;const o=n&&n.maxWait?Math.max(n.maxWait,t):0;function a(){return l(),r=e(),r}function l(){s!==void 0&&clearTimeout(s),i!==void 0&&clearTimeout(i),s=i=void 0}function u(){return s!==void 0||i!==void 0?a():r}function d(){return s&&clearTimeout(s),s=pu(a,t),o&&i===void 0&&(i=pu(a,o)),r}return d.cancel=l,d.flush=u,d}function g8(e){let t=!1;return(n,r)=>{if(!e.checkAndHandleExpiredSession()){qe&&Ge.warn("Received replay event after session expired.");return}const s=r||!t;t=!0,e.clickDetector&&F5(e.clickDetector,n),e.addUpdate(()=>{if(e.recordingMode==="buffer"&&s&&e.setInitialState(),!ww(e,n,s))return!0;if(!s)return!1;const i=e.session;if(y8(e,s),e.recordingMode==="buffer"&&i&&e.eventBuffer){const o=e.eventBuffer.getEarliestTimestamp();o&&(qe&&Ge.info(`Updating session start time to earliest event in buffer to ${new Date(o)}`),i.started=o,e.getOptions().stickySession&&bw(i))}return i&&i.previousSessionId||e.recordingMode==="session"&&e.flush(),!0})}}function v8(e){const t=e.getOptions();return{type:ot.Custom,timestamp:Date.now(),data:{tag:"options",payload:{shouldRecordCanvas:e.isRecordingCanvas(),sessionSampleRate:t.sessionSampleRate,errorSampleRate:t.errorSampleRate,useCompressionOption:t.useCompression,blockAllMedia:t.blockAllMedia,maskAllText:t.maskAllText,maskAllInputs:t.maskAllInputs,useCompression:e.eventBuffer?e.eventBuffer.type==="worker":!1,networkDetailHasUrls:t.networkDetailAllowUrls.length>0,networkCaptureBodies:t.networkCaptureBodies,networkRequestHasHeaders:t.networkRequestHeaders.length>0,networkResponseHasHeaders:t.networkResponseHeaders.length>0}}}}function y8(e,t){!t||!e.session||e.session.segmentId!==0||ww(e,v8(e),!1)}function b8(e,t,n,r){return sl(aR(e,tw(e),r,n),[[{type:"replay_event"},e],[{type:"replay_recording",length:typeof t=="string"?new TextEncoder().encode(t).length:t.length},t]])}function w8({recordingData:e,headers:t}){let n;const r=`${JSON.stringify(t)}
54
+ `;if(typeof e=="string")n=`${r}${e}`;else{const i=new TextEncoder().encode(r);n=new Uint8Array(i.length+e.length),n.set(i),n.set(e,i.length)}return n}async function S8({client:e,scope:t,replayId:n,event:r}){const s=typeof e._integrations=="object"&&e._integrations!==null&&!Array.isArray(e._integrations)?Object.keys(e._integrations):void 0,i={event_id:n,integrations:s};e.emit("preprocessEvent",r,i);const o=await fR(e.getOptions(),r,i,t,e,ws());if(!o)return null;o.platform=o.platform||"javascript";const a=e.getSdkMetadata(),{name:l,version:u}=a&&a.sdk||{};return o.sdk={...o.sdk,name:l||"sentry.javascript.unknown",version:u||"0.0.0"},o}async function _8({recordingData:e,replayId:t,segmentId:n,eventContext:r,timestamp:s,session:i}){const o=w8({recordingData:e,headers:{segment_id:n}}),{urls:a,errorIds:l,traceIds:u,initialTimestamp:d}=r,c=dt(),f=Bt(),p=c&&c.getTransport(),g=c&&c.getDsn();if(!c||!p||!g||!i.sampled)return Hi({});const m={type:r4,replay_start_timestamp:d/1e3,timestamp:s/1e3,error_ids:l,trace_ids:u,urls:a,replay_id:t,segment_id:n,replay_type:i.sampled},y=await S8({scope:f,client:c,replayId:t,event:m});if(!y)return c.recordDroppedEvent("event_processor","replay",m),qe&&Ge.info("An event processor returned `null`, will not send event."),Hi({});delete y.sdkProcessingMetadata;const b=b8(y,o,g,c.getOptions().tunnel);let w;try{w=await p.send(b)}catch(P){const E=new Error(cw);try{E.cause=P}catch{}throw E}if(typeof w.statusCode=="number"&&(w.statusCode<200||w.statusCode>=300))throw new $I(w.statusCode);const S=wR({},w);if(bR(S,"replay"))throw new _w(S);return w}class $I extends Error{constructor(t){super(`Transport returned status code ${t}`)}}class _w extends Error{constructor(t){super("Rate limit hit"),this.rateLimits=t}}async function FI(e,t={count:0,interval:u4}){const{recordingData:n,onError:r}=e;if(n.length)try{return await _8(e),!0}catch(s){if(s instanceof $I||s instanceof _w)throw s;if(EU("Replays",{_retryCount:t.count}),r&&r(s),t.count>=c4){const i=new Error(`${cw} - max retries exceeded`);try{i.cause=s}catch{}throw i}return t.interval*=++t.count,new Promise((i,o)=>{pu(async()=>{try{await FI(e,t),i(!0)}catch(a){o(a)}},t.interval)})}}const NI="__THROTTLED",k8="__SKIPPED";function x8(e,t,n){const r=new Map,s=a=>{const l=a-n;r.forEach((u,d)=>{d<l&&r.delete(d)})},i=()=>[...r.values()].reduce((a,l)=>a+l,0);let o=!1;return(...a)=>{const l=Math.floor(Date.now()/1e3);if(s(l),i()>=t){const d=o;return o=!0,d?k8:NI}o=!1;const u=r.get(l)||0;return r.set(l,u+1),e(...a)}}class fo{constructor({options:t,recordingOptions:n}){fo.prototype.__init.call(this),fo.prototype.__init2.call(this),fo.prototype.__init3.call(this),fo.prototype.__init4.call(this),fo.prototype.__init5.call(this),fo.prototype.__init6.call(this),this.eventBuffer=null,this.performanceEntries=[],this.replayPerformanceEntries=[],this.recordingMode="session",this.timeouts={sessionIdlePause:s4,sessionIdleExpire:i4},this._lastActivity=Date.now(),this._isEnabled=!1,this._isPaused=!1,this._requiresManualStart=!1,this._hasInitializedCoreListeners=!1,this._context={errorIds:new Set,traceIds:new Set,urls:[],initialTimestamp:Date.now(),initialUrl:""},this._recordingOptions=n,this._options=t,this._debouncedFlush=m8(()=>this._flush(),this._options.flushMinDelay,{maxWait:this._options.flushMaxDelay}),this._throttledAddEvent=x8((o,a)=>wj(this,o,a),300,5);const{slowClickTimeout:r,slowClickIgnoreSelectors:s}=this.getOptions(),i=r?{threshold:Math.min(d4,r),timeout:r,scrollTimeout:f4,ignoreSelector:s?s.join(","):""}:void 0;if(i&&(this.clickDetector=new M5(this,i)),qe){const o=t._experiments;Ge.setConfig({captureExceptions:!!o.captureExceptions,traceInternals:!!o.traceInternals})}}getContext(){return this._context}isEnabled(){return this._isEnabled}isPaused(){return this._isPaused}isRecordingCanvas(){return!!this._canvas}getOptions(){return this._options}handleException(t){qe&&Ge.exception(t),this._options.onError&&this._options.onError(t)}initializeSampling(t){const{errorSampleRate:n,sessionSampleRate:r}=this._options,s=n<=0&&r<=0;if(this._requiresManualStart=s,!s){if(this._initializeSessionForSampling(t),!this.session){qe&&Ge.exception(new Error("Unable to initialize and create session"));return}this.session.sampled!==!1&&(this.recordingMode=this.session.sampled==="buffer"&&this.session.segmentId===0?"buffer":"session",qe&&Ge.infoTick(`Starting replay in ${this.recordingMode} mode`),this._initializeRecording())}}start(){if(this._isEnabled&&this.recordingMode==="session"){qe&&Ge.info("Recording is already in progress");return}if(this._isEnabled&&this.recordingMode==="buffer"){qe&&Ge.info("Buffering is in progress, call `flush()` to save the replay");return}qe&&Ge.infoTick("Starting replay in session mode"),this._updateUserActivity();const t=wg({maxReplayDuration:this._options.maxReplayDuration,sessionIdleExpire:this.timeouts.sessionIdleExpire},{stickySession:this._options.stickySession,sessionSampleRate:1,allowBuffering:!1});this.session=t,this._initializeRecording()}startBuffering(){if(this._isEnabled){qe&&Ge.info("Buffering is in progress, call `flush()` to save the replay");return}qe&&Ge.infoTick("Starting replay in buffer mode");const t=wg({sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration},{stickySession:this._options.stickySession,sessionSampleRate:0,allowBuffering:!0});this.session=t,this.recordingMode="buffer",this._initializeRecording()}startRecording(){try{const t=this._canvas;this._stopRecording=Li({...this._recordingOptions,...this.recordingMode==="buffer"?{checkoutEveryNms:l4}:this._options._experiments.continuousCheckout&&{checkoutEveryNms:Math.max(36e4,this._options._experiments.continuousCheckout)},emit:g8(this),onMutation:this._onMutationHandler,...t?{recordCanvas:t.recordCanvas,getCanvasManager:t.getCanvasManager,sampling:t.sampling,dataURLOptions:t.dataURLOptions}:{}})}catch(t){this.handleException(t)}}stopRecording(){try{return this._stopRecording&&(this._stopRecording(),this._stopRecording=void 0),!0}catch(t){return this.handleException(t),!1}}async stop({forceFlush:t=!1,reason:n}={}){if(this._isEnabled){this._isEnabled=!1;try{qe&&Ge.info(`Stopping Replay${n?` triggered by ${n}`:""}`),TI(),this._removeListeners(),this.stopRecording(),this._debouncedFlush.cancel(),t&&await this._flush({force:!0}),this.eventBuffer&&this.eventBuffer.destroy(),this.eventBuffer=null,mj(this)}catch(r){this.handleException(r)}}}pause(){this._isPaused||(this._isPaused=!0,this.stopRecording(),qe&&Ge.info("Pausing replay"))}resume(){!this._isPaused||!this._checkSession()||(this._isPaused=!1,this.startRecording(),qe&&Ge.info("Resuming replay"))}async sendBufferedReplayOrFlush({continueRecording:t=!0}={}){if(this.recordingMode==="session")return this.flushImmediate();const n=Date.now();qe&&Ge.info("Converting buffer to session"),await this.flushImmediate();const r=this.stopRecording();!t||!r||this.recordingMode!=="session"&&(this.recordingMode="session",this.session&&(this._updateUserActivity(n),this._updateSessionActivity(n),this._maybeSaveSession()),this.startRecording())}addUpdate(t){const n=t();this.recordingMode!=="buffer"&&n!==!0&&this._debouncedFlush()}triggerUserActivity(){if(this._updateUserActivity(),!this._stopRecording){if(!this._checkSession())return;this.resume();return}this.checkAndHandleExpiredSession(),this._updateSessionActivity()}updateUserActivity(){this._updateUserActivity(),this._updateSessionActivity()}conditionalFlush(){return this.recordingMode==="buffer"?Promise.resolve():this.flushImmediate()}flush(){return this._debouncedFlush()}flushImmediate(){return this._debouncedFlush(),this._debouncedFlush.flush()}cancelFlush(){this._debouncedFlush.cancel()}getSessionId(){return this.session&&this.session.id}checkAndHandleExpiredSession(){if(this._lastActivity&&dy(this._lastActivity,this.timeouts.sessionIdlePause)&&this.session&&this.session.sampled==="session"){this.pause();return}return!!this._checkSession()}setInitialState(){const t=`${zt.location.pathname}${zt.location.hash}${zt.location.search}`,n=`${zt.location.origin}${t}`;this.performanceEntries=[],this.replayPerformanceEntries=[],this._clearContext(),this._context.initialUrl=n,this._context.initialTimestamp=Date.now(),this._context.urls.push(n)}throttledAddEvent(t,n){const r=this._throttledAddEvent(t,n);if(r===NI){const s=oi({category:"replay.throttled"});this.addUpdate(()=>!ww(this,{type:C5,timestamp:s.timestamp||0,data:{tag:"breadcrumb",payload:s,metric:!0}}))}return r}getCurrentRoute(){const t=this.lastActiveSpan||Rn(),n=t&&Ln(t),s=(n&&ut(n).data||{})[Yr];if(!(!n||!s||!["route","custom"].includes(s)))return ut(n).description}_initializeRecording(){this.setInitialState(),this._updateSessionActivity(),this.eventBuffer=fj({useCompression:this._options.useCompression,workerUrl:this._options.workerUrl}),this._removeListeners(),this._addListeners(),this._isEnabled=!0,this._isPaused=!1,this.startRecording()}_initializeSessionForSampling(t){const n=this._options.errorSampleRate>0,r=wg({sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration,previousSessionId:t},{stickySession:this._options.stickySession,sessionSampleRate:this._options.sessionSampleRate,allowBuffering:n});this.session=r}_checkSession(){if(!this.session)return!1;const t=this.session;return xI(t,{sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration})?(this._refreshSession(t),!1):!0}async _refreshSession(t){this._isEnabled&&(await this.stop({reason:"refresh session"}),this.initializeSampling(t.id))}_addListeners(){try{zt.document.addEventListener("visibilitychange",this._handleVisibilityChange),zt.addEventListener("blur",this._handleWindowBlur),zt.addEventListener("focus",this._handleWindowFocus),zt.addEventListener("keydown",this._handleKeyboardEvent),this.clickDetector&&this.clickDetector.addListeners(),this._hasInitializedCoreListeners||(f8(this),this._hasInitializedCoreListeners=!0)}catch(t){this.handleException(t)}this._performanceCleanupCallback=oj(this)}_removeListeners(){try{zt.document.removeEventListener("visibilitychange",this._handleVisibilityChange),zt.removeEventListener("blur",this._handleWindowBlur),zt.removeEventListener("focus",this._handleWindowFocus),zt.removeEventListener("keydown",this._handleKeyboardEvent),this.clickDetector&&this.clickDetector.removeListeners(),this._performanceCleanupCallback&&this._performanceCleanupCallback()}catch(t){this.handleException(t)}}__init(){this._handleVisibilityChange=()=>{zt.document.visibilityState==="visible"?this._doChangeToForegroundTasks():this._doChangeToBackgroundTasks()}}__init2(){this._handleWindowBlur=()=>{const t=oi({category:"ui.blur"});this._doChangeToBackgroundTasks(t)}}__init3(){this._handleWindowFocus=()=>{const t=oi({category:"ui.focus"});this._doChangeToForegroundTasks(t)}}__init4(){this._handleKeyboardEvent=t=>{W5(this,t)}}_doChangeToBackgroundTasks(t){!this.session||kI(this.session,{maxReplayDuration:this._options.maxReplayDuration,sessionIdleExpire:this.timeouts.sessionIdleExpire})||(t&&this._createCustomBreadcrumb(t),this.conditionalFlush())}_doChangeToForegroundTasks(t){if(!this.session)return;if(!this.checkAndHandleExpiredSession()){qe&&Ge.info("Document has become active, but session has expired");return}t&&this._createCustomBreadcrumb(t)}_updateUserActivity(t=Date.now()){this._lastActivity=t}_updateSessionActivity(t=Date.now()){this.session&&(this.session.lastActivity=t,this._maybeSaveSession())}_createCustomBreadcrumb(t){this.addUpdate(()=>{this.throttledAddEvent({type:ot.Custom,timestamp:t.timestamp||0,data:{tag:"breadcrumb",payload:t}})})}_addPerformanceEntries(){let t=X5(this.performanceEntries).concat(this.replayPerformanceEntries);if(this.performanceEntries=[],this.replayPerformanceEntries=[],this._requiresManualStart){const n=this._context.initialTimestamp/1e3;t=t.filter(r=>r.start>=n)}return Promise.all(lm(this,t))}_clearContext(){this._context.errorIds.clear(),this._context.traceIds.clear(),this._context.urls=[]}_updateInitialTimestampFromEventBuffer(){const{session:t,eventBuffer:n}=this;if(!t||!n||this._requiresManualStart||t.segmentId)return;const r=n.getEarliestTimestamp();r&&r<this._context.initialTimestamp&&(this._context.initialTimestamp=r)}_popEventContext(){const t={initialTimestamp:this._context.initialTimestamp,initialUrl:this._context.initialUrl,errorIds:Array.from(this._context.errorIds),traceIds:Array.from(this._context.traceIds),urls:this._context.urls};return this._clearContext(),t}async _runFlush(){const t=this.getSessionId();if(!this.session||!this.eventBuffer||!t){qe&&Ge.error("No session or eventBuffer found to flush.");return}if(await this._addPerformanceEntries(),!(!this.eventBuffer||!this.eventBuffer.hasEvents)&&(await h8(this),!!this.eventBuffer&&t===this.getSessionId()))try{this._updateInitialTimestampFromEventBuffer();const n=Date.now();if(n-this._context.initialTimestamp>this._options.maxReplayDuration+3e4)throw new Error("Session is too long, not sending replay");const r=this._popEventContext(),s=this.session.segmentId++;this._maybeSaveSession();const i=await this.eventBuffer.finish();await FI({replayId:t,recordingData:i,segmentId:s,eventContext:r,session:this.session,timestamp:n,onError:o=>this.handleException(o)})}catch(n){this.handleException(n),this.stop({reason:"sendReplay"});const r=dt();if(r){const s=n instanceof _w?"ratelimit_backoff":"send_error";r.recordDroppedEvent(s,"replay")}}}__init5(){this._flush=async({force:t=!1}={})=>{if(!this._isEnabled&&!t)return;if(!this.checkAndHandleExpiredSession()){qe&&Ge.error("Attempting to finish replay event after session expired.");return}if(!this.session)return;const n=this.session.started,s=Date.now()-n;this._debouncedFlush.cancel();const i=s<this._options.minReplayDuration,o=s>this._options.maxReplayDuration+5e3;if(i||o){qe&&Ge.info(`Session duration (${Math.floor(s/1e3)}s) is too ${i?"short":"long"}, not sending replay.`),i&&this._debouncedFlush();return}const a=this.eventBuffer;a&&this.session.segmentId===0&&!a.hasCheckout&&qe&&Ge.info("Flushing initial segment without checkout.");const l=!!this._flushLock;this._flushLock||(this._flushLock=this._runFlush());try{await this._flushLock}catch(u){this.handleException(u)}finally{this._flushLock=void 0,l&&this._debouncedFlush()}}}_maybeSaveSession(){this.session&&this._options.stickySession&&bw(this.session)}__init6(){this._onMutationHandler=t=>{const n=t.length,r=this._options.mutationLimit,s=this._options.mutationBreadcrumbLimit,i=r&&n>r;if(n>s||i){const o=oi({category:"replay.mutations",data:{count:n,limit:i}});this._createCustomBreadcrumb(o)}return i?(this.stop({reason:"mutationLimit",forceFlush:this.recordingMode==="session"}),!1):!0}}}function Zu(e,t){return[...e,...t].join(",")}function E8({mask:e,unmask:t,block:n,unblock:r,ignore:s}){const i=['base[href="/"]'],o=Zu(e,[".sentry-mask","[data-sentry-mask]"]),a=Zu(t,[]);return{maskTextSelector:o,unmaskTextSelector:a,blockSelector:Zu(n,[".sentry-block","[data-sentry-block]",...i]),unblockSelector:Zu(r,[]),ignoreSelector:Zu(s,[".sentry-ignore","[data-sentry-ignore]",'input[type="file"]'])}}function C8({el:e,key:t,maskAttributes:n,maskAllText:r,privacyOptions:s,value:i}){return!r||s.unmaskTextSelector&&e.matches(s.unmaskTextSelector)?i:n.includes(t)||t==="value"&&e.tagName==="INPUT"&&["submit","button"].includes(e.getAttribute("type")||"")?i.replace(/[\S]/g,"*"):i}const L1='img,image,svg,video,object,picture,embed,map,audio,link[rel="icon"],link[rel="apple-touch-icon"]',P8=["content-length","content-type","accept"];let $1=!1;const T8=e=>new cm(e);class cm{static __initStatic(){this.id="Replay"}constructor({flushMinDelay:t=o4,flushMaxDelay:n=a4,minReplayDuration:r=h4,maxReplayDuration:s=g1,stickySession:i=!0,useCompression:o=!0,workerUrl:a,_experiments:l={},maskAllText:u=!0,maskAllInputs:d=!0,blockAllMedia:c=!0,mutationBreadcrumbLimit:f=750,mutationLimit:p=1e4,slowClickTimeout:g=7e3,slowClickIgnoreSelectors:m=[],networkDetailAllowUrls:y=[],networkDetailDenyUrls:b=[],networkCaptureBodies:w=!0,networkRequestHeaders:S=[],networkResponseHeaders:P=[],mask:E=[],maskAttributes:T=["title","placeholder"],unmask:C=[],block:k=[],unblock:x=[],ignore:I=[],maskFn:M,beforeAddRecordingEvent:O,beforeErrorSampling:A,onError:D}={}){this.name=cm.id;const V=E8({mask:E,unmask:C,block:k,unblock:x,ignore:I});if(this._recordingOptions={maskAllInputs:d,maskAllText:u,maskInputOptions:{password:!0},maskTextFn:M,maskInputFn:M,maskAttributeFn:(H,G,j)=>C8({maskAttributes:T,maskAllText:u,privacyOptions:V,key:H,value:G,el:j}),...V,slimDOMOptions:"all",inlineStylesheet:!0,inlineImages:!1,collectFonts:!0,errorHandler:H=>{try{H.__rrweb__=!0}catch{}}},this._initialOptions={flushMinDelay:t,flushMaxDelay:n,minReplayDuration:Math.min(r,p4),maxReplayDuration:Math.min(s,g1),stickySession:i,useCompression:o,workerUrl:a,blockAllMedia:c,maskAllInputs:d,maskAllText:u,mutationBreadcrumbLimit:f,mutationLimit:p,slowClickTimeout:g,slowClickIgnoreSelectors:m,networkDetailAllowUrls:y,networkDetailDenyUrls:b,networkCaptureBodies:w,networkRequestHeaders:F1(S),networkResponseHeaders:F1(P),beforeAddRecordingEvent:O,beforeErrorSampling:A,onError:D,_experiments:l},this._initialOptions.blockAllMedia&&(this._recordingOptions.blockSelector=this._recordingOptions.blockSelector?`${this._recordingOptions.blockSelector},${L1}`:L1),this._isInitialized&&s1())throw new Error("Multiple Sentry Session Replay instances are not supported");this._isInitialized=!0}get _isInitialized(){return $1}set _isInitialized(t){$1=t}afterAllSetup(t){!s1()||this._replay||(this._setup(t),this._initialize(t))}start(){this._replay&&this._replay.start()}startBuffering(){this._replay&&this._replay.startBuffering()}stop(){return this._replay?this._replay.stop({forceFlush:this._replay.recordingMode==="session"}):Promise.resolve()}flush(t){return this._replay?this._replay.isEnabled()?this._replay.sendBufferedReplayOrFlush(t):(this._replay.start(),Promise.resolve()):Promise.resolve()}getReplayId(){if(!(!this._replay||!this._replay.isEnabled()))return this._replay.getSessionId()}getRecordingMode(){if(!(!this._replay||!this._replay.isEnabled()))return this._replay.recordingMode}_initialize(t){this._replay&&(this._maybeLoadFromReplayCanvasIntegration(t),this._replay.initializeSampling())}_setup(t){const n=R8(this._initialOptions,t);this._replay=new fo({options:n,recordingOptions:this._recordingOptions})}_maybeLoadFromReplayCanvasIntegration(t){try{const n=t.getIntegrationByName("ReplayCanvas");if(!n)return;this._replay._canvas=n.getOptions()}catch{}}}cm.__initStatic();function R8(e,t){const n=t.getOptions(),r={sessionSampleRate:0,errorSampleRate:0,...En(e)},s=zh(n.replaysSessionSampleRate),i=zh(n.replaysOnErrorSampleRate);return s==null&&i==null&&Gi(()=>{console.warn("Replay is disabled because neither `replaysSessionSampleRate` nor `replaysOnErrorSampleRate` are set.")}),s!=null&&(r.sessionSampleRate=s),i!=null&&(r.errorSampleRate=i),r}function F1(e){return[...P8,...e.map(t=>t.toLowerCase())]}const N1=new WeakMap,Sg=new Map,oh={traceFetch:!0,traceXHR:!0,enableHTTPTimings:!0,trackFetchStreamPerformance:!1};function I8(e,t){const{traceFetch:n,traceXHR:r,trackFetchStreamPerformance:s,shouldCreateSpanForRequest:i,enableHTTPTimings:o,tracePropagationTargets:a}={traceFetch:oh.traceFetch,traceXHR:oh.traceXHR,trackFetchStreamPerformance:oh.trackFetchStreamPerformance,...t},l=typeof i=="function"?i:c=>!0,u=c=>D8(c,a),d={};n&&(e.addEventProcessor(c=>(c.type==="transaction"&&c.spans&&c.spans.forEach(f=>{if(f.op==="http.client"){const p=Sg.get(f.span_id);p&&(f.timestamp=p/1e3,Sg.delete(f.span_id))}}),c)),s&&AH(c=>{if(c.response){const f=N1.get(c.response);f&&c.endTimestamp&&Sg.set(f,c.endTimestamp)}}),CR(c=>{const f=CH(c,l,u,d);if(c.response&&c.fetchData.__span&&N1.set(c.response,c.fetchData.__span),f){const p=BI(c.fetchData.url),g=p?Da(p).host:void 0;f.setAttributes({"http.url":p,"server.address":g})}o&&f&&B1(f)})),r&&qR(c=>{const f=L8(c,l,u,d);o&&f&&B1(f)})}function A8(e){return e.entryType==="resource"&&"initiatorType"in e&&typeof e.nextHopProtocol=="string"&&(e.initiatorType==="fetch"||e.initiatorType==="xmlhttprequest")}function B1(e){const{url:t}=ut(e).data||{};if(!t||typeof t!="string")return;const n=hu("resource",({entries:r})=>{r.forEach(s=>{A8(s)&&s.name.endsWith(t)&&(M8(s).forEach(o=>e.setAttribute(...o)),setTimeout(n))})})}function O8(e){let t="unknown",n="unknown",r="";for(const s of e){if(s==="/"){[t,n]=e.split("/");break}if(!isNaN(Number(s))){t=r==="h"?"http":r,n=e.split(r)[1];break}r+=s}return r===e&&(t=r),{name:t,version:n}}function js(e=0){return((gr||performance.timeOrigin)+e)/1e3}function M8(e){const{name:t,version:n}=O8(e.nextHopProtocol),r=[];return r.push(["network.protocol.version",n],["network.protocol.name",t]),gr?[...r,["http.request.redirect_start",js(e.redirectStart)],["http.request.fetch_start",js(e.fetchStart)],["http.request.domain_lookup_start",js(e.domainLookupStart)],["http.request.domain_lookup_end",js(e.domainLookupEnd)],["http.request.connect_start",js(e.connectStart)],["http.request.secure_connection_start",js(e.secureConnectionStart)],["http.request.connection_end",js(e.connectEnd)],["http.request.request_start",js(e.requestStart)],["http.request.response_start",js(e.responseStart)],["http.request.response_end",js(e.responseEnd)]]:r}function D8(e,t){const n=Ze.location&&Ze.location.href;if(n){let r,s;try{r=new URL(e,n),s=new URL(n).origin}catch{return!1}const i=r.origin===s;return t?Io(r.toString(),t)||i&&Io(r.pathname,t):i}else{const r=!!e.match(/^\/(?!\/)/);return t?Io(e,t):r}}function L8(e,t,n,r){const s=e.xhr,i=s&&s[ya];if(!s||s.__sentry_own_request__||!i)return;const o=di()&&t(i.url);if(e.endTimestamp&&o){const f=s.__sentry_xhr_span_id__;if(!f)return;const p=r[f];p&&i.status_code!==void 0&&(KT(p,i.status_code),p.end(),delete r[f]);return}const a=BI(i.url),l=a?Da(a).host:void 0,u=!!Rn(),d=o&&u?qa({name:`${i.method} ${i.url}`,attributes:{type:"xhr","http.method":i.method,"http.url":a,url:i.url,"server.address":l,[ln]:"auto.http.browser",[ja]:"http.client"}}):new Fu;s.__sentry_xhr_span_id__=d.spanContext().spanId,r[s.__sentry_xhr_span_id__]=d;const c=dt();return s.setRequestHeader&&n(i.url)&&c&&$8(s,c,di()&&u?d:void 0),d}function $8(e,t,n){const r=Bt(),s=ws(),{traceId:i,spanId:o,sampled:a,dsc:l}={...s.getPropagationContext(),...r.getPropagationContext()},u=n&&di()?ZT(n):Zb(i,o,a),d=XT(l||(n?Jo(n):tm(i,t)));F8(e,u,d)}function F8(e,t,n){try{e.setRequestHeader("sentry-trace",t),n&&e.setRequestHeader(kl,n)}catch{}}function BI(e){try{return new URL(e,Ze.location.origin).href}catch{return}}function N8(){Ze&&Ze.document?Ze.document.addEventListener("visibilitychange",()=>{const e=Rn();if(!e)return;const t=Ln(e);if(Ze.document.hidden&&t){const n="cancelled",{op:r,status:s}=ut(t);As&&Pe.log(`[Tracing] Transaction: ${n} -> since tab moved to the background, op: ${r}`),s||t.setStatus({code:In,message:n}),t.setAttribute("sentry.cancellation_reason","document.hidden"),t.end()}}):As&&Pe.warn("[Tracing] Could not set up background tab detection due to lack of global document")}const B8="BrowserTracing",V8={...nh,instrumentNavigation:!0,instrumentPageLoad:!0,markBackgroundSpan:!0,enableLongTask:!0,enableLongAnimationFrame:!0,enableInp:!0,_experiments:{},...oh},V1=(e={})=>{EV();const{enableInp:t,enableLongTask:n,enableLongAnimationFrame:r,_experiments:{enableInteractions:s,enableStandaloneClsSpans:i},beforeStartSpan:o,idleTimeout:a,finalTimeout:l,childSpanTimeout:u,markBackgroundSpan:d,traceFetch:c,traceXHR:f,trackFetchStreamPerformance:p,shouldCreateSpanForRequest:g,enableHTTPTimings:m,instrumentPageLoad:y,instrumentNavigation:b}={...V8,...e},w=Lz({recordClsStandaloneSpans:i||!1});t&&i3(),r&&ft.PerformanceObserver&&PerformanceObserver.supportedEntryTypes&&PerformanceObserver.supportedEntryTypes.includes("long-animation-frame")?Fz():n&&$z(),s&&Nz();const S={name:void 0,source:void 0};function P(E,T){const C=T.op==="pageload",k=o?o(T):T,x=k.attributes||{};T.name!==k.name&&(x[Yr]="custom",k.attributes=x),S.name=k.name,S.source=x[Yr];const I=dR(k,{idleTimeout:a,finalTimeout:l,childSpanTimeout:u,disableAutoFinish:C,beforeSpanEnd:O=>{w(),zz(O,{recordClsOnPageloadSpan:!i})}});function M(){["interactive","complete"].includes(Ze.document.readyState)&&E.emit("idleSpanEnableAutoFinish",I)}return C&&Ze.document&&(Ze.document.addEventListener("readystatechange",()=>{M()}),M()),I}return{name:B8,afterAllSetup(E){let T,C=Ze.location&&Ze.location.href;E.on("startNavigationSpan",k=>{dt()===E&&(T&&!ut(T).timestamp&&(As&&Pe.log(`[Tracing] Finishing current root span with op: ${ut(T).op}`),T.end()),T=P(E,{op:"navigation",...k}))}),E.on("startPageLoadSpan",(k,x={})=>{if(dt()!==E)return;T&&!ut(T).timestamp&&(As&&Pe.log(`[Tracing] Finishing current root span with op: ${ut(T).op}`),T.end());const I=x.sentryTrace||U1("sentry-trace"),M=x.baggage||U1("baggage"),O=bV(I,M);Bt().setPropagationContext(O),T=P(E,{op:"pageload",...k})}),E.on("spanEnd",k=>{const x=ut(k).op;if(k!==Ln(k)||x!=="navigation"&&x!=="pageload")return;const I=Bt(),M=I.getPropagationContext();I.setPropagationContext({...M,sampled:M.sampled!==void 0?M.sampled:rl(k),dsc:M.dsc||Jo(k)})}),Ze.location&&(y&&U8(E,{name:Ze.location.pathname,startTime:gr?gr/1e3:void 0,attributes:{[Yr]:"url",[ln]:"auto.pageload.browser"}}),b&&rm(({to:k,from:x})=>{if(x===void 0&&C&&C.indexOf(k)!==-1){C=void 0;return}x!==k&&(C=void 0,VI(E,{name:Ze.location.pathname,attributes:{[Yr]:"url",[ln]:"auto.navigation.browser"}}))})),d&&N8(),s&&H8(a,l,u,S),t&&a3(),I8(E,{traceFetch:c,traceXHR:f,trackFetchStreamPerformance:p,tracePropagationTargets:E.getOptions().tracePropagationTargets,shouldCreateSpanForRequest:g,enableHTTPTimings:m})}}};function U8(e,t,n){e.emit("startPageLoadSpan",t,n),Bt().setTransactionName(t.name);const r=Rn();return(r&&ut(r).op)==="pageload"?r:void 0}function VI(e,t){ws().setPropagationContext(Uh()),Bt().setPropagationContext(Uh()),e.emit("startNavigationSpan",t),Bt().setTransactionName(t.name);const n=Rn();return(n&&ut(n).op)==="navigation"?n:void 0}function U1(e){const t=qB(`meta[name=${e}]`);return t?t.getAttribute("content"):void 0}function H8(e,t,n,r){let s;const i=()=>{const o="ui.action.click",a=Rn(),l=a&&Ln(a);if(l){const u=ut(l).op;if(["navigation","pageload"].includes(u)){As&&Pe.warn(`[Tracing] Did not create ${o} span because a pageload or navigation span is in progress.`);return}}if(s&&(s.setAttribute(Uv,"interactionInterrupted"),s.end(),s=void 0),!r.name){As&&Pe.warn(`[Tracing] Did not create ${o} transaction because _latestRouteName is missing.`);return}s=dR({name:r.name,op:o,attributes:{[Yr]:r.source||"url"}},{idleTimeout:e,finalTimeout:t,childSpanTimeout:n})};Ze.document&&addEventListener("click",i,{once:!1,capture:!0})}const UI=["activate","mount","update"],HI=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,z8=/(?:^|[-_])(\w)/g,j8=e=>e.replace(z8,t=>t.toUpperCase()).replace(/[-_]/g,""),q8="<Root>",_g="<Anonymous>",W8=(e,t)=>e.repeat(t),Rc=(e,t)=>{if(!e)return _g;if(e.$root===e)return q8;if(!e.$options)return _g;const n=e.$options;let r=n.name||n._componentTag||n.__name;const s=n.__file;if(!r&&s){const i=s.match(/([^/\\]+)\.vue$/);i&&(r=i[1])}return(r?`<${j8(r)}>`:_g)+(s&&t!==!1?` at ${s}`:"")},G8=e=>{if(e&&(e._isVue||e.__isVue)&&e.$parent){const t=[];let n=0;for(;e;){if(t.length>0){const s=t[t.length-1];if(s.constructor===e.constructor){n++,e=e.$parent;continue}else n>0&&(t[t.length-1]=[s,n],n=0)}t.push(e),e=e.$parent}return`
55
+
56
+ found in
57
+
58
+ ${t.map((s,i)=>`${(i===0?"---> ":W8(" ",5+i*2))+(Array.isArray(s)?`${Rc(s[0])}... (${s[1]} recursive calls)`:Rc(s))}`).join(`
59
+ `)}`}return`
60
+
61
+ (found in ${Rc(e)})`},K8=(e,t)=>{const{errorHandler:n,warnHandler:r,silent:s}=e.config;e.config.errorHandler=(i,o,a)=>{const l=Rc(o,!1),u=o?G8(o):"",d={componentName:l,lifecycleHook:a,trace:u};if(t.attachProps&&o&&(o.$options&&o.$options.propsData?d.propsData=o.$options.propsData:o.$props&&(d.propsData=o.$props)),setTimeout(()=>{li(i,{captureContext:{contexts:{vue:d}},mechanism:{handled:!1}})}),typeof n=="function"&&e.config.errorHandler&&n.call(e,i,o,a),t.logErrors){const c=typeof console<"u",f=`Error in ${a}: "${i&&i.toString()}"`;r?r.call(null,f,o,u):c&&!s&&Gi(()=>{console.error(`[Vue warn]: ${f}${u}`)})}}},H1="ui.vue",Y8={activate:["activated","deactivated"],create:["beforeCreate","created"],unmount:["beforeUnmount","unmounted"],destroy:["beforeDestroy","destroyed"],mount:["beforeMount","mounted"],update:["beforeUpdate","updated"]};function X8(e,t,n){e.$_sentryRootSpanTimer&&clearTimeout(e.$_sentryRootSpanTimer),e.$_sentryRootSpanTimer=setTimeout(()=>{e.$root&&e.$root.$_sentryRootSpan&&(e.$root.$_sentryRootSpan.end(t),e.$root.$_sentryRootSpan=void 0)},n)}function Q8(e,t){function n(s){return s.replace(/^<([^\s]*)>(?: at [^\s]*)?$/,"$1")}return e.some(s=>n(t)===n(s))}const J8=e=>{const t=(e.hooks||[]).concat(UI).filter((r,s,i)=>i.indexOf(r)===s),n={};for(const r of t){const s=Y8[r];if(!s){HI&&Pe.warn(`Unknown hook: ${r}`);continue}for(const i of s)n[i]=function(){const o=this.$root===this;o&&(this.$_sentryRootSpan=this.$_sentryRootSpan||qa({name:"Application Render",op:`${H1}.render`,attributes:{[ln]:"auto.ui.vue"},onlyIfParent:!0}));const a=Rc(this,!1),l=Array.isArray(e.trackComponents)?Q8(e.trackComponents,a):e.trackComponents;if(!(!o&&!l))if(this.$_sentrySpans=this.$_sentrySpans||{},i==s[0]){if(this.$root&&this.$root.$_sentryRootSpan||Rn()){const d=this.$_sentrySpans[r];d&&d.end(),this.$_sentrySpans[r]=qa({name:`Vue ${a}`,op:`${H1}.${r}`,attributes:{[ln]:"auto.ui.vue"},onlyIfParent:!0})}}else{const u=this.$_sentrySpans[r];if(!u)return;u.end(),X8(this,nr(),e.timeout)}}}return n},Z8=ft,eq={Vue:Z8.Vue,attachProps:!0,logErrors:!0,attachErrorHandler:!0,hooks:UI,timeout:2e3,trackComponents:!1},tq="Vue",nq=(e={})=>({name:tq,setup(t){sq(t,e)}}),rq=nq;function sq(e,t){const n={...eq,...e.getOptions(),...t};if(!n.Vue&&!n.app){Gi(()=>{console.warn("[@sentry/vue]: Misconfigured SDK. Vue specific errors will not be captured.\nUpdate your `Sentry.init` call with an appropriate config option:\n`app` (Application Instance - Vue 3) or `Vue` (Vue Constructor - Vue 2).")});return}n.app?QB(n.app).forEach(s=>z1(s,n)):n.Vue&&z1(n.Vue,n)}const z1=(e,t)=>{if(HI){const n=e;(n._instance&&n._instance.isMounted)===!0&&Gi(()=>{console.warn("[@sentry/vue]: Misconfigured SDK. Vue app is already mounted. Make sure to call `app.mount()` after `Sentry.init()`.")})}t.attachErrorHandler&&K8(e,t),di(t)&&e.mixin(J8({...t,...t.tracingOptions}))};function iq(e={}){const t={_metadata:{sdk:{name:"sentry.javascript.vue",packages:[{name:"npm:@sentry/vue",version:Mi}],version:Mi}},defaultIntegrations:[...KR(),rq()],...e};return t4(t)}function oq(e,t,n){let r=!0;e.onError(s=>li(s,{mechanism:{handled:!1}})),e.beforeEach((s,i,o)=>{const a=i.name==null&&i.matched.length===0||i.name===void 0&&r;r&&(r=!1);const l={[ln]:"auto.navigation.vue"};for(const c of Object.keys(s.params))l[`params.${c}`]=s.params[c];for(const c of Object.keys(s.query)){const f=s.query[c];f&&(l[`query.${c}`]=f)}let u=s.path,d="url";if(s.name&&t.routeLabel!=="path")u=s.name.toString(),d="custom";else if(s.matched.length>0){const c=s.matched.length-1;u=s.matched[c].path,d="route"}if(Bt().setTransactionName(u),t.instrumentPageLoad&&a){const c=aq();c&&((ut(c).data||{})[Yr]!=="custom"&&(c.updateName(u),c.setAttribute(Yr,d)),c.setAttributes({...l,[ln]:"auto.pageload.vue"}))}t.instrumentNavigation&&!a&&(l[Yr]=d,l[ln]="auto.navigation.vue",n({name:u,op:"navigation",attributes:l})),o&&o()})}function aq(){const e=Rn(),t=e&&Ln(e);if(!t)return;const n=ut(t).op;return n==="navigation"||n==="pageload"?t:void 0}function lq(e={}){if(!e.router)return V1(e);const t=V1({...e,instrumentNavigation:!1}),{router:n,instrumentNavigation:r=!0,instrumentPageLoad:s=!0,routeLabel:i="name"}=e;return{...t,afterAllSetup(o){t.afterAllSetup(o),oq(n,{routeLabel:i,instrumentNavigation:r,instrumentPageLoad:s},l=>{VI(o,l)})}}}async function zI(){return"/"}async function Xn(e=!0,t=!0){const n=hn.create({baseURL:await zI()});return n.interceptors.request.use(r=>{var s,i;return console.debug(`${(s=r.method)==null?void 0:s.toUpperCase().padEnd(6)} ${(i=r.url)==null?void 0:i.padEnd(25)} WithAuth: ${e==null?void 0:e.toString().padEnd(7)} AutoHandle401: ${t==null?void 0:t.toString().padEnd(7)} BaseURL: ${r.baseURL}`),r}),e&&n.interceptors.request.use(async r=>{const s=ps();return s.loadTokens(),s.hasAuthToken&&(r.headers.Authorization=`Bearer ${s.token}`),r},r=>(console.error("Error in axios request interceptor",r),Promise.reject(r))),t&&n.interceptors.response.use(r=>r,async r=>{var c;const{response:s,config:i}=r;if(!s)return console.error("No response was returned by axios",r),Promise.reject({message:`No response was returned by axios - URL ${i==null?void 0:i.url}`,stack:r.stack});if(s.status===va.FailedDependency)return Promise.reject(r);if(![va.Unauthorized,va.Forbidden].includes(s.status))return console.error("Error in axios response interceptor which is not 401 or 403",r),li(r),Promise.reject({message:`${r.message} - URL ${i==null?void 0:i.url}`,stack:r.stack});if(s.status===va.Forbidden){const f=(c=r==null?void 0:r.response)==null?void 0:c.data;return console.error("[HttpClient] 403 Forbidden",f),qr("auth:permission-denied").emit({roles:f==null?void 0:f.roles,permissions:f==null?void 0:f.permissions,error:f==null?void 0:f.error,url:i==null?void 0:i.url}),Promise.reject(r)}const o=ps();o.loadTokens();const{reasonCode:a,url:l}=o.extractSpecialReasonCode(r);if(a)return await o.logout(!1,zb(a)),console.error(`[AuthStore] 401 Unauthorized - emitting 'auth:${a}' with reason ${a}`),qr(`auth:${a}`).emit({url:l,error:r.message,reasonCode:a}),Promise.reject(r);await o.checkAuthenticationRequirements();const{success:u,handled:d}=await o.verifyOrRefreshLoginOnceOrLogout();if(d)return Promise.reject(r);if(u){if(!(i!=null&&i.url))throw new Error("No URL in axios config, cannot retry");console.debug("Redoing request without interceptors",i==null?void 0:i.url);const f=i;return f.headers||(f.headers={}),f.headers.Authorization=`Bearer ${o.token}`,hn(f)}return console.error("[HttpClient] 401 Unauthorized - emitting 'auth:failure'"),qr("auth:failure").emit({url:i==null?void 0:i.url,error:r.message}),Promise.reject(r)}),n}class yr{static async get(t){return(await(await Xn(!0)).get(t)).data}static async put(t,n){return(await(await Xn(!0)).put(t,n)).data}static async post(t,n){return(await(await Xn(!0)).post(t,n)).data}static async postUpload(t,n,r){return await(await Xn(!0)).post(t,n,r)}static async getDownload(t,n){return await(await Xn(!0)).request({method:"GET",url:t,data:n,responseType:"arraybuffer"})}static async delete(t,n){return(await(await Xn(!0)).request({url:t,method:"delete",data:n})).data}static async patch(t,n){return(await(await Xn(!0)).patch(t,n)).data}}const ne=class ne{};he(ne,"base","/api"),he(ne,"firstTimeSetupRoute",`${ne.base}/first-time-setup`),he(ne,"completeFirstTimeSetupRoute",`${ne.firstTimeSetupRoute}/complete`),he(ne,"printerRoute",`${ne.base}/printer`),he(ne,"printerBatchRoute",`${ne.printerRoute}/batch`),he(ne,"printerTestConnectionRoute",`${ne.printerRoute}/test-connection`),he(ne,"printerSettingsRoute",`${ne.base}/printer-settings`),he(ne,"floorRoute",`${ne.base}/floor`),he(ne,"batchRoute",`${ne.base}/batch`),he(ne,"batchGetLastPrintedFilesRoute",`${ne.batchRoute}/reprint/list`),he(ne,"batchReprintFilesRoute",`${ne.batchRoute}/reprint/execute`),he(ne,"printCompletionRoute",`${ne.base}/print-completion`),he(ne,"printerFilesRoute",`${ne.base}/printer-files`),he(ne,"printerFilesPurgeRoute",`${ne.printerFilesRoute}/purge`),he(ne,"printerGroupRoute",`${ne.base}/printer-group`),he(ne,"createGroupRoute",`${ne.base}/printer-group`),he(ne,"deleteGroupRoute",t=>`${ne.base}/printer-group/${t}`),he(ne,"updateGroupNameRoute",t=>`${ne.base}/printer-group/${t}/name`),he(ne,"addPrinterToGroupRoute",t=>`${ne.base}/printer-group/${t}/printer`),he(ne,"deletePrinterFromGroupRoute",ne.addPrinterToGroupRoute),he(ne,"customGCodeRoute",`${ne.base}/custom-gcode`),he(ne,"userRoute",`${ne.base}/user`),he(ne,"rolesRoute",`${ne.base}/user/roles`),he(ne,"userProfileRoute",`${ne.userRoute}/profile`),he(ne,"settingsRoute",`${ne.base}/settings`),he(ne,"settingsSensitiveRoute",`${ne.settingsRoute}/sensitive`),he(ne,"updateLoginRequiredRoute",`${ne.settingsRoute}/login-required`),he(ne,"updateRegistrationEnabledRoute",`${ne.settingsRoute}/registration-enabled`),he(ne,"updateCredentialSettings",`${ne.settingsRoute}/credential`),he(ne,"serverSettingsRoute",`${ne.settingsRoute}/server`),he(ne,"fileCleanSettingsRoute",`${ne.settingsRoute}/file-clean`),he(ne,"updateFrontendSettingsRoute",`${ne.settingsRoute}/frontend`),he(ne,"updateTimeoutSettingRoute",`${ne.settingsRoute}/timeout`),he(ne,"serverSentryDiagnosticsSettingRoute",`${ne.settingsRoute}/sentry-diagnostics`),he(ne,"updateExperimentalMoonrakerSupportRoute",`${ne.settingsRoute}/experimental-moonraker-support`),he(ne,"updateExperimentalClientSupportRoute",`${ne.settingsRoute}/experimental-client-support`),he(ne,"serverPrivateRoute",`${ne.base}/server`),he(ne,"serverRestartCommandRoute",`${ne.serverPrivateRoute}/restart`),he(ne,"pluginRoute",`${ne.base}/plugin`),he(ne,"pluginFirmwareUpdateRoute",`${ne.pluginRoute}/firmware-update`),he(ne,"pluginFirmwareReleasesRoute",`${ne.pluginFirmwareUpdateRoute}/releases`),he(ne,"getPrinterRoute",t=>`${ne.printerRoute}/${t}`),he(ne,"postPrinterDisabledReasonRoute",t=>`${ne.printerRoute}/${t}/disabled-reason`),he(ne,"getPrinterLoginDetailsRoute",t=>`${ne.getPrinterRoute(t)}/login-details`),he(ne,"restartOctoPrintRoute",t=>`${ne.getPrinterRoute(t)}/restart-octoprint`),he(ne,"refreshSocketRoute",t=>`${ne.getPrinterRoute(t)}/refresh-socket`),he(ne,"getPrinterSettingsRoute",t=>`${ne.printerSettingsRoute}/${t}`),he(ne,"setPrinterSettingsGCodeAnalysisRoute",t=>`${ne.getPrinterSettingsRoute(t)}/gcode-analysis`),he(ne,"syncPrinterNameSettingRoute",t=>`${ne.getPrinterSettingsRoute(t)}/sync-printername`),he(ne,"getFloorRoute",t=>`${ne.floorRoute}/${t}`),he(ne,"setSelectedFloorRoute",t=>`${ne.floorRoute}/selected-floor/${t}`),he(ne,"addOrRemovePrinterFromFloorRoute",t=>`${ne.getFloorRoute(t)}/printer`),he(ne,"sendQuickStopM112Route",t=>`${ne.customGCodeRoute}/send-emergency-m112/${t}`),he(ne,"installFirmwareUpdatePluginRoute",t=>`${ne.pluginFirmwareUpdateRoute}/${t}/install-firmware-update-plugin`),he(ne,"configurePluginSettingsRoute",t=>`${ne.pluginFirmwareUpdateRoute}/${t}/configure-plugin-settings`),he(ne,"flashFirmwareRoute",t=>`${ne.pluginFirmwareUpdateRoute}/${t}/flash-firmware`),he(ne,"updatePrinterFloorNameRoute",t=>`${ne.getFloorRoute(t)}/name`),he(ne,"updatePrinterFloorNumberRoute",t=>`${ne.getFloorRoute(t)}/floor-number`),he(ne,"printerFilesClearRoute",t=>`${ne.printerFilesRoute}/${t}/clear`),he(ne,"printerFilesSelectAndPrintRoute",t=>`${ne.printerFilesRoute}/${t}/select`),he(ne,"printerFilesUploadRoute",t=>`${ne.printerFilesRoute}/${t}/upload`),he(ne,"printerFilesCacheRoute",t=>`${ne.printerFilesRoute}/${t}/cache`),he(ne,"printerEnabledRoute",t=>`${ne.getPrinterRoute(t)}/enabled`),he(ne,"printerSerialConnectRoute",t=>`${ne.getPrinterRoute(t)}/serial-connect`),he(ne,"printerJogCommandRoute",t=>`${ne.getPrinterRoute(t)}/jog`),he(ne,"printerHomeCommandRoute",t=>`${ne.getPrinterRoute(t)}/home`),he(ne,"printerSerialDisconnectRoute",t=>`${ne.getPrinterRoute(t)}/serial-disconnect`),he(ne,"printerJobRoute",t=>`${ne.getPrinterRoute(t)}/job`),he(ne,"printerStopJobRoute",t=>`${ne.printerJobRoute(t)}/stop`),he(ne,"printerPauseJobRoute",t=>`${ne.printerJobRoute(t)}/pause`),he(ne,"printerResumeJobRoute",t=>`${ne.printerJobRoute(t)}/resume`),he(ne,"userChangeUsernameRoute",t=>`${ne.userRoute}/${t}/change-username`),he(ne,"userChangePasswordRoute",t=>`${ne.userRoute}/${t}/change-password`),he(ne,"userDeleteRoute",t=>`${ne.userRoute}/${t}`),he(ne,"userSetVerifiedRoute",t=>`${ne.userRoute}/${t}/set-verified`),he(ne,"userSetRootUserRoute",t=>`${ne.userRoute}/${t}/set-root-user`),he(ne,"userSetUserRolesRoute",t=>`${ne.userRoute}/${t}/set-user-roles`);let Oe=ne;const uq=Symbol("Progress snackbar message event symbol"),cq=Symbol("Info snackbar message event symbol"),dq=Symbol("Error snackbar message event symbol");function Mt(){const{emit:e,on:t}=qr(uq),{emit:n,on:r}=qr(cq),{emit:s,on:i}=qr(dq);return{openProgressMessage:(o,a,l,u)=>e({key:o,title:a,value:l,completed:u}),openInfoMessage:o=>n(o),info:(o,a,l)=>n({title:o,subtitle:a,timeout:l}),openErrorMessage:o=>s(o),error:(o,a)=>s({title:o,subtitle:a}),onProgressMessage:t,onInfoMessage:r,onErrorMessage:i}}function py(e,t){if(!e)throw new Error("No data to download");const n=new Blob([e],{type:"text/plain"}),r=document.createElement("a");r.href=URL.createObjectURL(n),r.download=t,r.click(),URL.revokeObjectURL(r.href)}class Oo extends yr{static async getFiles(t){const n=`${Oe.printerFilesRoute}/${t}`;return await this.get(n)}static async getFileCache(t){const n=`${Oe.printerFilesCacheRoute(t)}`;return await this.get(n)}static async selectAndPrintFile(t,n,r=!0){const s=Oe.printerFilesSelectAndPrintRoute(t);return await this.post(s,{filePath:n,print:r})}static async uploadFile(t,n){const r=Oe.printerFilesUploadRoute(t.id),s=new FormData;return s.append("files[0]",n),this.postUpload(r,s,{onUploadProgress:i=>{Mt().openProgressMessage("single-file-upload",`Uploading file ${n.name}`,100*i.loaded/i.total,!1)}})}static async clearFiles(t){const n=`${Oe.printerFilesClearRoute(t)}`;return this.delete(n)}static async purgeFiles(){const t=`${Oe.printerFilesPurgeRoute}`;return this.post(t)}static async deleteFileOrFolder(t,n){const r=`${Oe.printerFilesRoute}/${t}?path=${n}`;return this.delete(r)}static async downloadFile(t,n){const r=`${Oe.printerFilesRoute}/${t}/download/${n}`,s=await this.getDownload(r);py(s.data,n)}}const fq=["able","above","absent","absolute","abstract","abundant","academic","acceptable","accepted","accessible","accurate","accused","active","actual","acute","added","additional","adequate","adjacent","administrative","adorable","advanced","adverse","advisory","aesthetic","afraid","afraid","african","aggregate","aggressive","agreeable","agreed","agricultural","alert","alive","alive","alleged","allied","alone","alright","alternative","amateur","amazing","ambitious","american","amused","ancient","ancient","angry","angry","annoyed","annual","anonymous","anxious","anxious","appalling","apparent","applicable","appropriate","arab","arbitrary","architectural","armed","arrogant","artificial","artistic","ashamed","ashamed","asian","asleep","assistant","associated","atomic","attractive","australian","automatic","autonomous","available","average","average","average","awake","aware","awful","awful","awkward","back","bad","bad","bad","balanced","bare","basic","beautiful","beautiful","beautiful","beneficial","better","bewildered","big","big","big","binding","biological","bitter","bitter","bizarre","black","black","blank","blind","blonde","bloody","bloody","blue","blue","blushing","boiling","bold","bored","bored","boring","bottom","brainy","brave","brave","breakable","breezy","brief","brief","bright","bright","bright","brilliant","british","broad","broad","broken","broken","brown","bumpy","burning","busy","busy","calm","calm","canadian","capable","capitalist","careful","careful","casual","catholic","causal","cautious","cautious","central","certain","changing","characteristic","charming","charming","cheap","cheerful","cheerful","chemical","chief","chilly","chinese","chosen","christian","chronic","chubby","circular","civic","civil","civilian","classic","classical","clean","clean","clear","clear","clever","clever","clinical","close","closed","cloudy","clumsy","coastal","cognitive","coherent","cold","cold","collective","colonial","colorful","colossal","coloured","colourful","combative","combined","comfortable","comfortable","coming","commercial","common","communist","compact","comparable","comparative","compatible","competent","competitive","complete","complex","complicated","comprehensive","compulsory","conceptual","concerned","concerned","concrete","condemned","confident","confidential","confused","confused","conscious","conservation","conservative","considerable","consistent","constant","constitutional","contemporary","content","continental","continued","continuing","continuous","controlled","controversial","convenient","conventional","convinced","convincing","cooing","cool","cool","cooperative","corporate","correct","corresponding","costly","courageous","crazy","crazy","crazy","creative","creepy","creepy","criminal","critical","crooked","crooked","crowded","crucial","crude","cruel","cruel","cuddly","cultural","curious","curious","curly","current","curved","cute","daily","damaged","damp","damp","dangerous","dangerous","dark","dark","dead","dead","deaf","deafening","dear","decent","decisive","deep","deep","defeated","defensive","defiant","definite","deliberate","delicate","delicious","delicious","delighted","delightful","delightful","democratic","dependent","depressed","depressed","desirable","desperate","detailed","determined","determined","developed","developing","devoted","different","different","difficult","difficult","digital","diplomatic","direct","dirty","dirty","disabled","disappointed","disastrous","disciplinary","disgusted","distant","distinct","distinct","distinctive","distinguished","disturbed","disturbing","diverse","divine","dizzy","domestic","dominant","double","doubtful","doubtful","drab","dramatic","dreadful","driving","drunk","dry","dry","dual","due","dull","dull","dull","dusty","dutch","dying","dynamic","eager","eager","early","early","eastern","easy","easy","economic","educational","eerie","effective","efficient","elaborate","elated","elderly","eldest","electoral","electric","electrical","electronic","elegant","elegant","eligible","embarrassed","embarrassed","embarrassing","emotional","empirical","empty","empty","enchanting","encouraging","encouraging","endless","energetic","english","enormous","enthusiastic","enthusiastic","entire","entitled","envious","environmental","equal","equivalent","essential","established","estimated","ethical","ethnic","european","eventual","everyday","evident","evil","evil","evolutionary","exact","excellent","exceptional","excess","excessive","excited","excited","exciting","exclusive","existing","exotic","expected","expensive","experienced","experimental","explicit","extended","extensive","external","extra","extraordinary","extreme","exuberant","faint","faint","fair","fair","faithful","faithful","familiar","famous","famous","fancy","fantastic","fantastic","far","fascinating","fashionable","fast","fast","fat","fat","fat","fatal","favourable","favourite","federal","fellow","female","feminist","few","fierce","fierce","filthy","filthy","final","financial","fine","fine","firm","fiscal","fit","fixed","flaky","flat","flat","flexible","fluffy","fluttering","flying","following","fond","foolish","foolish","foreign","formal","formidable","forthcoming","fortunate","forward","fragile","frail","frantic","free","french","frequent","fresh","fresh","friendly","friendly","friendly","frightened","frightened","front","frozen","fucking","full","full-time","fun","functional","fundamental","funny","funny","funny","furious","future","fuzzy","gastric","gay","general","generous","genetic","gentle","gentle","genuine","geographical","german","giant","giant","gigantic","gigantic","given","glad","glamorous","gleaming","global","glorious","glorious","golden","good","good","gorgeous","gothic","governing","graceful","gradual","grand","grateful","greasy","great","great","great","greek","green","green","grey","grieving","grim","gross","grotesque","growing","grubby","grumpy","guilty","handicapped","handsome","handsome","happy","happy","happy","hard","hard","harsh","harsh","head","healthy","healthy","heavy","heavy","helpful","helpful","helpful","helpless","helpless","hidden","high","high","high-pitched","hilarious","hissing","historic","historical","hollow","holy","homeless","homeless","homely","hon","honest","horizontal","horrible","horrible","hostile","hot","hot","huge","huge","human","hungry","hungry","hurt","hushed","husky","icy","ideal","identical","ideological","ill","ill","illegal","imaginative","immediate","immense","immense","imperial","implicit","important","important","impossible","impossible","impressed","impressive","improved","inadequate","inappropriate","inc","inclined","increased","increasing","incredible","independent","indian","indirect","individual","industrial","inevitable","influential","informal","inherent","initial","injured","inland","inner","innocent","innocent","innovative","inquisitive","instant","institutional","insufficient","intact","integral","integrated","intellectual","intelligent","intense","intensive","interested","interesting","interim","interior","intermediate","internal","international","intimate","invisible","involved","iraqi","irish","irrelevant","islamic","isolated","israeli","italian","itchy","japanese","jealous","jewish","jittery","joint","jolly","jolly","joyous","judicial","juicy","junior","just","keen","key","kind","kind","kind","known","korean","labour","large","large","large-scale","late","late","latin","lazy","leading","left","legal","legislative","legitimate","lengthy","lesser","level","lexical","liable","liberal","light","light","light","like","likely","limited","linear","linguistic","liquid","literary","little","little","live","lively","lively","living","local","logical","lonely","lonely","long","long","long","long","long-term","loose","loose","lost","loud","loud","lovely","lovely","low","low","loyal","ltd","lucky","lucky","mad","magenta","magic","magnetic","magnificent","magnificent","main","major","male","mammoth","managerial","managing","manual","many","many","marginal","marine","marked","married","marvellous","marxist","mass","massive","massive","mathematical","mature","maximum","mean","meaningful","mechanical","medical","medieval","melodic","melted","mental","mere","metropolitan","mid","middle","middle-class","mighty","mighty","mild","military","miniature","minimal","minimum","ministerial","minor","miserable","misleading","missing","misty","mixed","moaning","mobile","moderate","modern","modern","modern","modest","molecular","monetary","monthly","moral","motionless","muddy","multiple","mushy","musical","mute","mutual","mysterious","mysterious","naked","narrow","narrow","nasty","nasty","national","native","natural","naughty","naval","near","nearby","neat","necessary","negative","neighbouring","nervous","nervous","net","neutral","new","new","nice","nice","nineteenth-century","noble","noisy","noisy","normal","northern","nosy","notable","novel","nuclear","numerous","numerous","nursing","nutritious","nutty","obedient","objective","obliged","obnoxious","obvious","occasional","occupational","odd","odd","official","ok","okay","old","old","old-fashioned","old-fashioned","olympic","only","open","open","operational","opposite","optimistic","oral","orange","orange","ordinary","ordinary","organic","organisational","original","orthodox","other","outdoor","outer","outrageous","outside","outstanding","outstanding","overall","overseas","overwhelming","painful","pale","palestinian","panicky","parallel","parental","parliamentary","part-time","partial","particular","passing","passive","past","patient","payable","peaceful","peculiar","perfect","perfect","permanent","persistent","personal","petite","philosophical","physical","pink","plain","plain","planned","plastic","pleasant","pleasant","pleased","poised","polish","polite","political","poor","poor","popular","positive","possible","post-war","potential","powerful","powerful","practical","precious","precious","precise","preferred","pregnant","preliminary","premier","prepared","present","presidential","pretty","pretty","previous","prickly","prickly","primary","prime","primitive","principal","printed","prior","private","probable","productive","professional","profitable","profound","progressive","prominent","promising","proper","proposed","prospective","protective","protestant","proud","proud","provincial","psychiatric","psychological","public","puny","pure","purple","purple","purring","puzzled","puzzled","quaint","quaint","qualified","quick","quick","quick","quickest","quiet","quiet","quiet","racial","radical","rainy","rainy","random","rapid","rapid","rare","rare","raspy","rational","ratty","raw","ready","real","real","realistic","rear","reasonable","recent","red","red","reduced","redundant","regional","registered","regular","regulatory","related","relative","relaxed","relevant","reliable","relieved","relieved","religious","reluctant","remaining","remarkable","remote","renewed","representative","repulsive","required","resident","residential","resonant","respectable","respective","responsible","resulting","retail","retired","revolutionary","rich","rich","ridiculous","right","rigid","ripe","rising","rival","roasted","robust","rolling","roman","romantic","rotten","rough","rough","round","round","round","royal","rubber","rude","ruling","running","rural","russian","sacred","sad","sad","safe","salty","satisfactory","satisfied","scared","scary","scary","scattered","scientific","scornful","scottish","scrawny","screeching","secondary","secret","secure","select","selected","selective","selfish","semantic","senior","sensible","sensitive","separate","serious","severe","sexual","shaggy","shaky","shallow","shallow","shared","sharp","sharp","sheer","shiny","shivering","shocked","short","short","short","short","short-term","shrill","shy","shy","sick","significant","silent","silent","silky","silly","silly","silly","similar","simple","single","skilled","skinny","sleepy","slight","slim","slimy","slippery","slow","slow","small","small","smart","smiling","smoggy","smooth","smooth","so-called","social","socialist","soft","soft","soft","solar","sole","solid","solid","sophisticated","sore","sorry","sound","sound","sour","southern","soviet","spanish","spare","sparkling","spatial","special","specific","specified","spectacular","spicy","spiritual","splendid","splendid","spontaneous","sporting","spotless","spotty","square","square","squealing","stable","stale","standard","static","statistical","statutory","steady","steady","steep","steep","sticky","sticky","stiff","still","stingy","stormy","straight","straight","straightforward","strange","strange","strange","strategic","strict","striking","striped","strong","strong","structural","stuck","stupid","stupid","subjective","subsequent","substantial","subtle","successful","successful","successive","sudden","sufficient","suitable","sunny","super","super","superb","superior","supporting","supposed","supreme","sure","surprised","surprising","surrounding","surviving","suspicious","sweet","sweet","swift","swiss","symbolic","sympathetic","systematic","tall","tall","tall","tame","tame","tan","tart","tasteless","tasty","technical","technological","teenage","temporary","tender","tender","tender","tense","terrible","terrible","territorial","testy","then","theoretical","thick","thin","thirsty","thorough","thoughtful","thoughtless","thundering","tight","tight","tiny","tiny","tired","tired","top","tory","total","tough","tough","toxic","traditional","tragic","tremendous","tricky","tropical","troubled","turkish","typical","ugliest","ugly","ugly","ugly","ultimate","unable","unacceptable","unaware","uncertain","unchanged","uncomfortable","unconscious","underground","underlying","unemployed","uneven","unexpected","unfair","unfortunate","unhappy","uniform","uninterested","unique","united","universal","unknown","unlikely","unnecessary","unpleasant","unsightly","unusual","unusual","unwilling","upper","upset","upset","uptight","urban","urgent","used","useful","useless","usual","vague","valid","valuable","variable","varied","various","varying","vast","vast","verbal","vertical","very","victorian","victorious","video-taped","violent","visible","visiting","visual","vital","vivacious","vivid","vocational","voiceless","voluntary","vulnerable","wandering","warm","wasteful","watery","weak","weak","wealthy","weary","wee","weekly","weird","welcome","well","well-known","welsh","western","wet","wet","wet","whispering","white","whole","wicked","wicked","wide","wide","wide-eyed","widespread","wild","wild","willing","wise","witty","wonderful","wonderful","wonderful","wooden","wooden","working","working-class","worldwide","worried","worried","worrying","worthwhile","worthy","written","wrong","wrong","yellow","yellow","young","young","yummy","zany","zany","zealous"],hq=["aardvark","abacus","abbey","abdomen","abolishment","abroad","abyssinian","accelerant","accelerator","accompanist","accordion","account","accountant","achieve","achiever","acid","acknowledgment","acoustic","acoustics","acrylic","act","action","active","activity","actor","actress","acupuncture","adapter","addiction","addition","address","adjustment","administration","adrenalin","adult","advancement","advantage","advertisement","advertising","advice","affair","affect","afghanistan","africa","aftermath","afternoon","aftershave","aftershock","afterthought","age","agency","agenda","agent","aglet","agreement","air","airbag","airbus","airfare","airforce","airline","airmail","airplane","airport","airship","alarm","alb","albatross","alcohol","alcove","alder","algebra","algeria","alibi","allergist","alley","alligator","alloy","almanac","almond","alpaca","alpenglow","alpenhorn","alpha","alphabet","alternative","altitude","alto","aluminium","aluminum","ambassador","ambulance","amendment","america","amount","amusement","anagram","analgesia","analog","analysis","analyst","anatomy","anesthesiology","anethesiologist","anger","angiosperm","angle","angora","angstrom","anguish","animal","anime","ankle","anklet","annual","anorak","answer","ant","antarctica","anteater","antechamber","antelope","anthony","anthropology","antler","anybody","anything","anywhere","apartment","ape","aperitif","apology","apparatus","apparel","appeal","appendix","apple","applewood","appliance","approval","april","apron","apse","aquarius","aquifer","arch","archaeology","archeology","archer","architect","architecture","arch-rival","area","argentina","argument","aries","arithmetic","arm","armadillo","armament","armchair","armenian","armoire","armor","arm-rest","army","arrival","arrow","art","artichoke","artificer","ascot","ash","ashram","ashtray","asia","asparagus","asphalt","assignment","assistance","associate","association","asterisk","astrakhan","astrolabe","astrologer","astrology","astronomy","atelier","athelete","athlete","atm","atmosphere","atom","atrium","attachment","attack","attempt","attendant","attention","attenuation","attic","attitude","attorney","attraction","audience","auditorium","august","aunt","australia","australian","author","authorisation","authority","authorization","automaton","avalanche","avenue","average","azimuth","babe","babies","baboon","babushka","baby","back","backbone","backdrop","backpack","bacon","bad","badge","badger","bafflement","bag","bagel","bagpipe","bagpipes","bail","bait","bake","baker","bakery","bakeware","balaclava","balalaika","balance","balcony","balinese","ball","balloon","ballpark","bamboo","banana","band","bandana","bandolier","bangladesh","bangle","banjo","bank","bankbook","banker","banquette","baobab","bar","barbara","barbeque","barber","barbiturate","barge","baritone","barium","barn","barometer","barracks","barstool","base","baseball","basement","basin","basis","basket","basketball","bass","bassinet","bassoon","bat","bath","bather","bathhouse","bathrobe","bathroom","bathtub","batter","battery","batting","battle","battleship","bay","bayou","beach","bead","beak","beam","bean","beanie","beanstalk","bear","beard","beast","beat","beautician","beauty","beaver","bed","bedroom","bee","beech","beef","beer","beet","beetle","beggar","beginner","begonia","behavior","beheading","behest","belfry","belgian","belief","believe","bell","belligerency","bellows","belly","belt","bench","bend","beneficiary","benefit","bengal","beret","berry","bestseller","best-seller","betty","beverage","beyond","bibliography","bicycle","bid","bidet","bifocals","big","big-rig","bijou","bike","bikini","bill","billboard","bin","biology","biplane","birch","bird","birdbath","birdcage","birdhouse","bird-watcher","birth","birthday","bit","bite","black","blackberry","blackboard","blackfish","bladder","blade","blame","blank","blanket","blazer","blight","blinker","blister","blizzard","block","blocker","blood","bloodflow","bloom","bloomers","blossom","blouse","blow","blowgun","blowhole","blue","blueberry","boar","board","boat","boat-building","boatload","boatyard","bobcat","body","bog","bolero","bolt","bomb","bomber","bondsman","bone","bongo","bonnet","bonsai","bonus","boogeyman","book","bookcase","bookend","booklet","booster","boot","bootee","bootie","boots","booty","border","bore","bosom","botany","bottle","bottling","bottom","bottom-line","boudoir","bough","boundary","bow","bower","bowl","bowler","bowling","bowtie","box","boxer","boxspring","boy","bra","brace","bracelet","bracket","brain","brake","branch","brand","brandy","brass","brassiere","bratwurst","brazil","bread","breadcrumb","break","breakfast","breakpoint","breast","breastplate","breath","breeze","brian","bribery","brick","bricklaying","bridge","brief","briefs","brilliant","british","broccoli","brochure","broiler","broker","brome","bronchitis","bronco","bronze","brooch","brood","brook","broom","brother","brother-in-law","brow","brown","brush","brushfire","brushing","bubble","bucket","buckle","bud","budget","buffer","buffet","bug","buggy","bugle","building","bulb","bull","bulldozer","bullet","bull-fighter","bumper","bun","bunch","bungalow","bunghole","bunkhouse","burglar","burlesque","burma","burn","burn-out","burst","bus","bush","business","bust","bustle","butane","butcher","butter","button","buy","buyer","buzzard","cabana","cabbage","cabin","cabinet","cable","caboose","cacao","cactus","caddy","cadet","cafe","caftan","cake","calcification","calculation","calculator","calculus","calendar","calf","calico","call","calm","camel","cameo","camera","camp","campaign","campanile","can","canada","canadian","canal","cancel","cancer","candelabra","candidate","candle","candy","cane","cannon","canoe","canon","canopy","canteen","canvas","cap","cape","capital","capitulation","capon","cappelletti","cappuccino","capricorn","captain","caption","car","caravan","carbon","card","cardboard","cardigan","care","cargo","carload","carnation","carol","carotene","carp","carpenter","carpet","carport","carriage","carrier","carrot","carry","cart","cartilage","cartload","cartoon","cartridge","cascade","case","casement","cash","cashier","casino","casserole","cassock","cast","castanet","castanets","castle","cat","catacomb","catamaran","category","caterpillar","cathedral","catsup","cattle","cauliflower","cause","caution","cave","c-clamp","cd","ceiling","celebration","celeriac","celery","celeste","cell","cellar","cello","celsius","cement","cemetery","cenotaph","census","cent","centenarian","center","centimeter","centurion","century","cephalopod","ceramic","cereal","certification","cesspool","chador","chafe","chain","chainstay","chair","chairlift","chairman","chairperson","chairwoman","chaise","chalet","chalice","chalk","champion","chance","chandelier","change","channel","chap","chapel","character","chard","charge","charity","charlatan","charles","charm","chart","chastity","chasuble","chateau","chauffeur","chauvinist","check","checkroom","cheek","cheese","cheetah","chef","chemistry","cheque","cherries","cherry","chess","chest","chick","chicken","chicory","chief","chiffonier","child","childhood","children","chill","chime","chimpanzee","chin","china","chinese","chino","chipmunk","chit-chat","chivalry","chive","chocolate","choice","choker","chop","chopstick","chord","chowder","christmas","christopher","chrome","chromolithograph","chronograph","chronometer","chub","chug","church","churn","cicada","cinema","circle","circulation","circumference","cirrus","citizenship","city","civilisation","clam","clank","clapboard","clarinet","clasp","class","claus","clave","clavicle","clavier","cleaner","cleat","cleavage","clef","cleric","clerk","click","client","cliff","climb","clip","clipper","cloak","cloakroom","clock","clockwork","clogs","cloister","close","closet","cloth","clothes","clothing","cloud","cloudburst","cloudy","clove","clover","club","clutch","coach","coal","coast","coat","cob","cobweb","cockpit","cockroach","cocktail","cocoa","cod","codon","codpiece","coevolution","coffee","coffin","coil","coin","coinsurance","coke","cold","coliseum","collar","collection","college","collision","colloquia","colombia","colon","colonisation","colony","color","colt","column","columnist","comb","combat","combination","comfort","comfortable","comic","comma","command","commercial","commission","committee","communicant","communication","community","company","comparison","competition","competitor","complement","complex","component","comportment","composer","composition","compost","compulsion","computer","comradeship","concert","concrete","condition","condominium","condor","conductor","cone","confectionery","conference","confidence","confirmation","conflict","conga","congo","congressman","congressperson","congresswoman","conifer","connection","consent","consequence","console","consonant","conspirator","constant","constellation","construction","consul","consulate","contact lens","contagion","contest","context","continent","contract","contrail","contrary","contribution","control","convection","convert","convertible","cook","cookie","cooking","coonskin","cope","cop-out","copper","co-producer","copy","copyright","copywriter","cord","corduroy","cork","cormorant","corn","cornerstone","cornet","corral","correspondent","corridor","corsage","cost","costume","cot","cottage","cotton","couch","cougar","cough","council","councilman","councilor","councilperson","councilwoman","counter","counter-force","countess","country","couple","courage","course","court","cousin","covariate","cover","coverall","cow","cowbell","cowboy","crab","crack","cracker","crackers","cradle","craftsman","crash","crate","cravat","craw","crawdad","crayfish","crayon","cream","creative","creator","creature","creche","credenza","credit","creditor","creek","creme brulee","crest","crew","crib","cribbage","cricket","cricketer","crime","criminal","crinoline","criteria","criterion","criticism","crocodile","crocus","croissant","crook","crop","cross","cross-contamination","cross-stitch","crotch","croup","crow","crowd","crown","crude","crush","cry","crystallography","cub","cuban","cuckoo","cucumber","cuff-links","cultivar","cultivator","culture","culvert","cummerbund","cup","cupboard","cupcake","cupola","curio","curl","curler","currency","current","cursor","curtain","curve","cushion","custard","custodian","customer","cut","cuticle","cutlet","cutover","cutting","cyclamen","cycle","cyclone","cylinder","cymbal","cymbals","cynic","cyst","cytoplasm","dad","daffodil","dagger","dahlia","daisy","damage","dame","dance","dancer","danger","daniel","dark","dart","dash","dashboard","database","date","daughter","david","day","daybed","dead","deadline","deal","dealer","dear","death","deathwatch","deborah","debt","debtor","decade","december","decimal","decision","deck","declination","decongestant","decrease","decryption","dedication","deer","defense","deficit","deformation","degree","delete","delivery","demand","demur","den","denim","dentist","deodorant","department","dependent","deployment","deposit","depressive","depth","deputy","derby","derrick","description","desert","design","designer","desire","desk","dessert","destiny","destroyer","destruction","detail","detainment","detective","detention","determination","development","deviance","dew","dhow","diadem","diamond","diaphragm","diarist","dibble","dickey","dictaphone","diction","dictionary","diet","dietician","difference","differential","difficulty","digestion","digger","digital","dilapidation","dill","dime","dimension","dimple","diner","dinghy","dinner","dinosaur","diploma","dipstick","direction","director","dirndl","dirt","disadvantage","disarmament","disaster","disco","disconnection","discount","discovery","discrepancy","discussion","disease","disembodiment","disengagement","disguise","disgust","dish","dishes","dishwasher","disk","display","disposer","distance","distribution","distributor","district","divan","diver","divide","divider","diving","division","dock","doctor","document","doe","dog","dogsled","dogwood","doll","dollar","dolman","dolphin","domain","donald","donkey","donna","door","doorknob","doorpost","dorothy","dory","dot","double","doubling","doubt","doubter","downforce","downgrade","downtown","draft","dragon","dragonfly","dragster","drain","drake","drama","dramaturge","draw","drawbridge","drawer","drawing","dream","dredger","dress","dresser","dressing","drill","drink","drive","driver","driveway","driving","drizzle","dromedary","drop","drug","drum","drummer","drunk","dry","dryer","duck","duckling","dud","duffel","dugout","dulcimer","dumbwaiter","dump truck","dune buggy","dungarees","dungeon","duplexer","dust","dust storm","duster","duty","dwarf","dwelling","dynamo","eagle","ear","eardrum","earmuffs","earplug","earrings","earth","earthquake","earthworm","ease","easel","east","eave","eavesdropper","e-book","ecclesia","eclipse","ecliptic","economics","ecumenist","eddy","edge","edger","editor","editorial","education","edward","eel","effacement","effect","effective","efficacy","efficiency","effort","egg","egghead","eggnog","eggplant","egypt","eight","ejector","elbow","election","electrocardiogram","element","elephant","elevator","elixir","elizabeth","elk","ellipse","elm","elongation","embossing","emergence","emergent","emery","emotion","employ","employee","employer","employment","empowerment","emu","encirclement","encyclopedia","end","endothelium","enemy","energy","engine","engineer","engineering","english","enigma","enquiry","entertainment","entrance","entry","environment","epauliere","epee","ephemera","ephemeris","epoch","eponym","epoxy","equinox","equipment","era","e-reader","error","escape","espadrille","espalier","establishment","estate","estimate","estrogen","estuary","ethernet","ethiopia","euphonium","eurocentrism","europe","evaluator","evening","evening-wear","event","eviction","evidence","evocation","examination","examiner","example","exchange","exclamation","excuse","executor","exhaust","ex-husband","exile","existence","exit","expansion","expansionism","experience","expert","explanation","exposition","extension","extent","extreme","ex-wife","eye","eyeball","eyebrow","eyebrows","eyeglasses","eyelash","eyelashes","eyelid","eyelids","eyeliner","eyestrain","face","facelift","facet","facilities","facsimile","fact","factor","factory","faculty","fahrenheit","fairies","fairy","fall","falling-out","familiar","family","fan","fang","fanlight","fanny","fanny-pack","farm","farmer","fascia","fat","father","father-in-law","fatigues","faucet","fault","fawn","fax","fear","feast","feather","feature","february","fedelini","fedora","feed","feedback","feeling","feet","felony","female","fen","fence","fencing","fender","ferry","ferryboat","fertilizer","few","fiber","fiberglass","fibre","fiction","fiddle","field","fifth","fight","fighter","figurine","file","fill","filly","filth","final","finance","find","fine","finger","fingernail","finisher","fir","fire","fireman","fireplace","firewall","fish","fishbone","fisherman","fishery","fishmonger","fishnet","fisting","fix","fixture","flag","flame","flanker","flare","flash","flat","flatboat","flavor","flax","fleck","fleece","flesh","flight","flintlock","flip-flops","flock","flood","floor","floozie","flower","flu","flugelhorn","fluke","flute","fly","flytrap","foam","fob","focus","fog","fold","folder","fondue","font","food","foot","football","footnote","footrest","foot-rest","footstool","foray","force","forearm","forebear","forecast","forehead","forest","forestry","forgery","fork","form","formal","format","former","fort","fortnight","fortress","forum","foundation","fountain","fowl","fox","foxglove","fragrance","frame","france","fratricide","fraudster","frazzle","freckle","freeplay","freeze","freezer","freight","freighter","french","freon","fresco","friction","friday","fridge","friend","friendship","frigate","fringe","frock","frog","front","frost","frown","fruit","frustration","fuel","fulfillment","full","function","fundraising","funny","fur","furnace","furniture","fusarium","futon","future","gaffer","gaiters","gale","gall-bladder","galleon","gallery","galley","gallon","galoshes","game","gamebird","gamma-ray","gander","gap","garage","garb","garbage","garden","garlic","garment","garter","gas","gasoline","gastropod","gate","gateway","gather","gauge","gauntlet","gazebo","gazelle","gear","gearshift","geese","gelding","gem","gemini","gemsbok","gender","gene","general","genetics","geography","geology","geometry","george","geranium","gerbil","geriatrician","german","germany","geyser","ghana","gherkin","ghost","giant","gigantism","ginseng","giraffe","girdle","girl","git","glad","gladiolus","gland","glass","glasses","glen","glider","gliding","glockenspiel","glove","gloves","glue","glut","goal","goat","gobbler","godmother","goggles","go-kart","gold","goldfish","golf","gondola","gong","good","goodbye","good-bye","goodie","goose","gopher","gore-tex","gorilla","gosling","governance","government","governor","gown","grab-bag","grade","grain","gram","granddaughter","grandfather","grandmom","grandmother","grandson","granny","grape","grapefruit","graph","graphic","grass","grasshopper","grassland","gray","grease","great","great-grandfather","great-grandmother","greece","greek","green","greenhouse","grenade","grey","grief","grill","grip","grit","ground","group","grouper","grouse","growth","guarantee","guatemalan","guest","guestbook","guide","guilty","guitar","guitarist","gum","gumshoes","gun","gutter","guy","gym","gymnast","gynaecology","gyro","hacienda","hacksaw","hackwork","hail","hair","haircut","half","half-brother","half-sister","halibut","hall","hallway","hamaki","hamburger","hammer","hammock","hamster","hand","handball","hand-holding","handicap","handle","handlebar","handmaiden","handsaw","hang","harbor","harbour","hardboard","hardcover","hardening","hardhat","hard-hat","hardware","harm","harmonica","harmony","harp","harpooner","harpsichord","hassock","hat","hatbox","hatchet","hate","haunt","haversack","hawk","hay","head","headlight","headline","headrest","health","hearing","heart","heartache","hearth","hearthside","heart-throb","heartwood","heat","heater","heaven","heavy","hedge","hedgehog","heel","height","heirloom","helen","helicopter","helium","hell","hellcat","helmet","helo","help","hemp","hen","herb","heron","herring","hexagon","heyday","hide","high","highlight","high-rise","highway","hill","himalayan","hip","hippodrome","hippopotamus","historian","history","hit","hive","hobbies","hobbit","hobby","hockey","hoe","hog","hold","hole","holiday","home","homogenate","homonym","honey","honeybee","honoree","hood","hoof","hook","hope","hops","horn","hornet","horse","hose","hosiery","hospice","hospital","host","hostel","hostess","hot","hot-dog","hotel","hour","hourglass","house","houseboat","hovel","hovercraft","howitzer","hub","hubcap","hugger","human","humidity","humor","hunger","hurdler","hurricane","hurry","hurt","husband","hut","hutch","hyacinth","hybridisation","hydrant","hydraulics","hydrofoil","hydrogen","hyena","hygienic","hyphenation","hypochondria","hypothermia","ice","icebreaker","icecream","ice-cream","icicle","icon","idea","ideal","igloo","ikebana","illegal","image","imagination","impact","implement","importance","impress","imprisonment","improvement","impudence","impulse","inbox","incandescence","inch","income","increase","independent","index","india","indigence","indonesia","industry","infancy","inflammation","inflation","information","infusion","inglenook","ingrate","initial","initiative","in-joke","injury","ink","in-laws","inlay","inn","innervation","innocent","input","inquiry","inscription","insect","inside","insolence","inspector","instruction","instrument","instrumentalist","instrumentation","insulation","insurance","insurgence","intelligence","intention","interactive","interest","interferometer","interior","interloper","internal","internet","interpreter","intervenor","interview","interviewer","intestine","intestines","invention","inventor","inventory","invite","invoice","ipad","iran","iraq","iridescence","iris","iron","ironclad","island","israel","issue","italian","italy","jackal","jacket","jaguar","jail","jailhouse","jam","james","january","japan","japanese","jar","jasmine","jason","jaw","jeans","jeep","jeff","jelly","jellyfish","jennifer","jet","jewel","jewelry","jiffy","job","jockey","jodhpurs","joey","jogging","john","join","joke","joseph","jot","journey","judge","judo","juggernaut","juice","july","jumbo","jump","jumper","jumpsuit","june","junior","junk","junker","junket","jury","justice","jute","kale","kamikaze","kangaroo","karate","karen","kayak","kazoo","kendo","kenneth","kenya","ketch","ketchup","kettle","kettledrum","kevin","key","keyboard","keyboarding","keystone","kick","kick-off","kid","kidney","kidneys","kielbasa","kill","kilogram","kilometer","kilt","kimberly","kimono","kind","king","kingfish","kiosk","kiss","kitchen","kite","kitten","kitty","kleenex","klomps","knee","kneejerk","knickers","knife","knife-edge","knight","knitting","knot","knowledge","knuckle","koala","kohlrabi","korean","lab","laborer","lace","lacquerware","ladder","ladybug","lake","lamb","lamp","lan","lanai","land","landform","landmine","language","lantern","lap","laparoscope","lapdog","laptop","larch","larder","lark","laryngitis","lasagna","latency","latex","lathe","latte","laugh","laundry","laura","law","lawn","lawsuit","lawyer","layer","lead","leader","leaf","league","leaker","learning","leash","leather","leaver","lecture","leek","leg","legal","legging","legume","lei","lemon","lemonade","lemur","length","lentil","leo","leopard","leotard","leprosy","let","letter","lettuce","level","lever","leverage","libra","librarian","library","license","lier","life","lift","light","lighting","lightning","lilac","lily","limit","limo","line","linen","liner","link","linseed","lion","lip","lipstick","liquid","liquor","lisa","list","literature","litigation","litter","liver","living","lizard","llama","loaf","loafer","loan","lobotomy","lobster","lock","locker","locket","locomotive","locust","loft","log","loggia","loincloth","look","loss","lot","lotion","lounge","lout","love","low","loyalty","luck","luggage","lumber","lumberman","lunch","luncheonette","lunchroom","lung","lunge","lute","luttuce","lycra","lye","lymphocyte","lynx","lyocell","lyre","lyric","macadamia","macaroni","machine","macrame","macrofauna","maelstrom","maestro","magazine","magic","magician","maid","maiden","mail","mailbox","mailman","maintenance","major","major-league","makeup","malaysia","male","mall","mallet","mambo","mammoth","man","management","manager","mandarin","mandolin","mangrove","manhunt","maniac","manicure","manner","manor","mansard","manservant","mansion","mantel","mantle","mantua","manufacturer","manx","map","maple","maraca","maracas","marble","march","mare","margaret","margin","maria","mariachi","marimba","mark","market","marketing","marksman","marriage","marsh","marshland","marxism","mary","mascara","mask","mass","massage","master","mastication","mastoid","mat","match","material","math","mattock","mattress","maximum","may","maybe","mayonnaise","mayor","meal","meaning","measure","meat","mechanic","medicine","medium","meet","meeting","megalomaniac","melody","member","membership","memory","men","menorah","mention","menu","mercury","mess","message","metal","metallurgist","meteor","meteorology","meter","methane","method","methodology","metro","metronome","mexican","mexico","mezzanine","mice","michael","michelle","microlending","microwave","mid-course","middle","middleman","midi","midline","midnight","midwife","might","migrant","mile","milk","milkshake","millennium","millimeter","millisecond","mime","mimosa","mind","mine","mini","minibus","minion","mini-skirt","minister","minor","minor-league","mint","minute","mirror","miscarriage","miscommunication","misfit","misogyny","misplacement","misreading","missile","mission","mist","mistake","mister","miter","mitten","mix","mixer","mixture","moat","mobile","moccasins","mocha","mode","model","modem","mole","mom","moment","monastery","monasticism","monday","money","monger","monitor","monkey","monocle","monotheism","monsoon","monster","month","mood","moon","moonscape","moonshine","mop","Mormon","morning","morocco","morsel","mortise","mosque","mosquito","most","motel","moth","mother","mother-in-law","motion","motor","motorboat","motorcar","motorcycle","mound","mountain","mouse","mouser","mousse","moustache","mouth","mouton","move","mover","movie","mower","mug","mukluk","mule","multimedia","muscle","musculature","museum","music","music-box","musician","music-making","mustache","mustard","mutt","myanmar","mycoplasma","nail","name","naming","nancy","nanoparticle","napkin","narcissus","nation","naturalisation","nature","neat","neck","necklace","necktie","necromancer","need","needle","negligee","neologism","neon","nepal","nephew","nerve","nest","net","netball","netbook","netsuke","network","neurobiologist","neuropathologist","neuropsychiatry","news","newspaper","newsprint","newsstand","nexus","nic","nicety","niche","nickel","niece","nigeria","night","nightclub","nightgown","nightingale","nightlight","nitrogen","node","noise","nonbeliever","nonconformist","nondisclosure","noodle","normal","norse","north","north america","north korea","norwegian","nose","note","notebook","notice","notify","notoriety","nougat","novel","november","nudge","number","numeracy","numeric","numismatist","nurse","nursery","nurture","nut","nylon","oak","oar","oasis","oatmeal","obi","objective","obligation","oboe","observation","observatory","occasion","occupation","ocean","ocelot","octagon","octave","octavo","octet","october","octopus","odometer","oeuvre","offence","offer","office","official","off-ramp","oil","okra","oldie","olive","omega","omelet","oncology","one","onion","open","opening","opera","operation","ophthalmologist","opinion","opium","opossum","opportunist","opportunity","opposite","option","orange","orangutan","orator","orchard","orchestra","orchid","order","ordinary","ordination","organ","organisation","organization","original","ornament","osmosis","osprey","ostrich","others","otter","ottoman","ounce","outback","outcome","outfit","outhouse","outlay","output","outrigger","outset","outside","oval","ovary","oven","overcharge","overclocking","overcoat","overexertion","overflight","overnighter","overshoot","owl","owner","ox","oxen","oxford","oxygen","oyster","pacemaker","pack","package","packet","pad","paddle","paddock","page","pagoda","pail","pain","paint","painter","painting","paintwork","pair","pajama","pajamas","pakistan","paleontologist","paleontology","palm","pamphlet","pan","pancake","pancreas","panda","panic","pannier","panpipe","pansy","panther","panties","pantry","pants","pantsuit","panty","pantyhose","paper","paperback","parable","parachute","parade","parallelogram","paramedic","parcel","parchment","parent","parentheses","park","parka","parrot","parsnip","part","participant","particle","particular","partner","partridge","party","passage","passbook","passenger","passive","pasta","paste","pastor","pastoralist","pastry","patch","path","patient","patina","patio","patriarch","patricia","patrimony","patriot","patrol","pattern","paul","pavement","pavilion","paw","pawnshop","payee","payment","pea","peace","peach","peacoat","peacock","peak","peanut","pear","pearl","pedal","pedestrian","pediatrician","peen","peer","peer-to-peer","pegboard","pelican","pelt","pen","penalty","pencil","pendant","pendulum","penicillin","pension","pentagon","peony","people","pepper","percentage","perch","perfume","period","periodical","peripheral","permafrost","permission","permit","perp","persian","person","personality","peru","pest","pet","petal","petticoat","pew","pharmacist","pharmacopoeia","phase","pheasant","philippines","philosopher","philosophy","phone","photo","photographer","phrase","physical","physician","pianist","piano","piccolo","pick","pickax","picket","pickle","picture","pie","piece","pier","piety","pig","pigeon","pike","pile","pilgrimage","pillbox","pillow","pilot","pimp","pimple","pin","pinafore","pince-nez","pine","pineapple","pinecone","ping","pink","pinkie","pinstripe","pint","pinto","pinworm","pioneer","pipe","piracy","piranha","pisces","piss","pitch","pitching","pith","pizza","place","plain","plane","planet","plant","plantation","planter","plaster","plasterboard","plastic","plate","platform","platinum","platypus","play","player","playground","playroom","pleasure","pleated","plier","plot","plough","plover","plow","plowman","plume","plunger","plywood","pneumonia","pocket","pocketbook","pocket-watch","poet","poignance","point","poison","poisoning","poland","pole","polenta","police","policeman","policy","polish","politician","pollution","polo","polyester","pompom","poncho","pond","pony","poof","pool","popcorn","poppy","popsicle","population","populist","porch","porcupine","port","porter","portfolio","porthole","position","positive","possibility","postage","postbox","poster","pot","potato","potential","potty","pouch","poultry","pound","pounding","powder","power","precedent","precipitation","preface","prelude","premeditation","premier","preoccupation","preparation","presence","presentation","president","pressroom","pressure","pressurisation","price","pride","priest","priesthood","primary","primate","prince","princess","principal","print","printer","priority","prison","prize","prizefight","probation","problem","procedure","process","processing","produce","producer","product","production","professional","professor","profit","program","project","promotion","prompt","proof-reader","propane","property","prose","prosecution","protest","protocol","prow","pruner","pseudoscience","psychiatrist","psychoanalyst","psychologist","psychology","ptarmigan","publisher","pudding","puddle","puffin","pull","pulley","puma","pump","pumpkin","pumpkinseed","punch","punishment","pupa","pupil","puppy","purchase","puritan","purple","purpose","purse","push","pusher","put","pvc","pyjama","pyramid","quadrant","quail","quality","quart","quarter","quartz","queen","question","quicksand","quiet","quill","quilt","quince","quit","quiver","quotation","rabbi","rabbit","raccoon","race","racer","racing","racist","rack","radar","radiator","radio","radiosonde","radish","raffle","raft","rag","rage","rail","railway","raiment","rain","rainbow","raincoat","rainmaker","rainstorm","raise","rake","ram","rambler","ramie","ranch","random","randomisation","range","rank","raspberry","rat","rate","ratio","raven","ravioli","raw","rawhide","ray","rayon","reactant","reaction","read","reading","reamer","rear","reason","receipt","reception","recess","recliner","recognition","recommendation","record","recorder","recover","recruit","rectangle","red","redesign","rediscovery","reduction","reef","refectory","reflection","refrigerator","refund","refuse","region","register","regret","regular","regulation","reindeer","reinscription","reject","relation","relative","religion","relish","reminder","rent","repair","reparation","repeat","replace","replication","reply","report","representative","reprocessing","request","resale","research","resident","resist","resolution","respect","respite","responsibility","rest","restaurant","result","retailer","rethinking","retina","retouch","return","reveal","revenant","review","revolution","revolve","revolver","reward","rheumatism","rhinoceros","rhyme","rhythm","rice","richard","riddle","ride","rider","ridge","rifle","right","rim","ring","ringworm","ripple","rise","riser","risk","river","riverbed","rivulet","road","roadway","roast","robe","robert","robin","rock","rocker","rocket","rocket-ship","rod","role","roll","roller","romania","romanian","ronald","roof","room","rooster","root","rope","rose","rostrum","rotate","roundabout","route","router","routine","row","rowboat","royal","rub","rubber","rubric","ruckus","ruffle","rugby","rule","run","runaway","runner","russia","russian","rutabaga","ruth","sabre","sack","sad","saddle","safe","safety","sage","sagittarius","sail","sailboat","sailor","salad","salary","sale","salesman","salmon","salon","saloon","salt","samovar","sampan","sample","samurai","sand","sandals","sandbar","sandra","sandwich","santa","sarah","sardine","sari","sarong","sash","satellite","satin","satire","saturday","sauce","saudi arabia","sausage","save","saving","savior","saviour","saw","saxophone","scale","scallion","scanner","scarecrow","scarf","scarification","scene","scent","schedule","scheme","schizophrenic","schnitzel","school","schoolhouse","schooner","science","scimitar","scissors","scooter","score","scorn","scorpio","scorpion","scow","scraper","screamer","screen","screenwriting","screw","screwdriver","screw-up","scrim","scrip","sculpting","sculpture","sea","seagull","seal","seaplane","search","seashore","season","seat","second","secretariat","secretary","section","sectional","sector","secure","security","seed","seeder","segment","select","selection","self","sell","semicircle","semicolon","senator","sense","sentence","sepal","september","septicaemia","series","servant","server","service","session","set","setting","settler","sewer","sex","shack","shade","shadow","shadowbox","shake","shakedown","shaker","shallot","shame","shampoo","shanty","shape","share","shark","sharon","shawl","shearling","shears","sheath","shed","sheep","sheet","shelf","shell","sherry","shield","shift","shin","shine","shingle","ship","shirt","shirtdress","shoat","shock","shoe","shoehorn","shoe-horn","shoelace","shoemaker","shoes","shoestring","shofar","shoot","shootdown","shop","shopper","shopping","shore","shortage","shorts","shortwave","shot","shoulder","shovel","show","shower","show-stopper","shred","shrimp","shrine","siamese","siberian","sibling","sick","side","sideboard","sideburns","sidecar","sidestream","sidewalk","siding","sign","signature","signet","significance","signup","silica","silk","silkworm","sill","silo","silver","simple","sing","singer","single","sink","sister","sister-in-law","sit","sitar","size","skate","skiing","skill","skin","skirt","skulduggery","skull","skullcap","skullduggery","skunk","sky","skylight","skyscraper","skywalk","slapstick","slash","slave","sled","sledge","sleep","sleet","sleuth","slice","slider","slime","slip","slipper","slippers","slope","sloth","smash","smell","smelting","smile","smock","smog","smoke","smuggling","snail","snake","snakebite","sneakers","sneeze","snob","snorer","snow","snowboarding","snowflake","snowman","snowmobiling","snowplow","snowstorm","snowsuit","snuggle","soap","soccer","society","sociology","sock","socks","soda","sofa","softball","softdrink","softening","software","soil","soldier","solid","solitaire","sombrero","somersault","somewhere","son","song","songbird","sonnet","soot","soprano","sorbet","sort","soulmate","sound","soup","source","sourwood","sousaphone","south","south africa","south america","south korea","sow","soy","soybean","space","spacing","spade","spaghetti","spain","spandex","spank","spark","sparrow","spasm","speaker","speakerphone","spear","special","specialist","specific","spectacle","spectacles","spectrograph","speedboat","spend","sphere","sphynx","spider","spike","spinach","spine","spiral","spirit","spiritual","spite","spleen","split","sponge","spoon","sport","spot","spotlight","spray","spread","spring","sprinter","sprout","spruce","spume","spur","spy","square","squash","squatter","squeegee","squid","squirrel","stable","stack","stacking","stadium","staff","stag","stage","stain","stair","staircase","stallion","stamen","stamina","stamp","stance","standoff","star","start","starter","state","statement","station","station-wagon","statistic","statistician","steak","steal","steam","steamroller","steel","steeple","stem","stencil","step","step-aunt","step-brother","stepdaughter","step-daughter","step-father","step-grandfather","step-grandmother","stepmother","step-mother","stepping-stone","steps","step-sister","stepson","step-son","step-uncle","steven","stew","stick","stiletto","still","stinger","stitch","stock","stocking","stockings","stock-in-trade","stole","stomach","stone","stonework","stool","stop","stopsign","stopwatch","store","storey","storm","story","storyboard","story-telling","stove","strait","stranger","strap","straw","strawberry","stream","street","streetcar","stress","stretch","strike","string","strip","structure","struggle","stud","student","studio","study","stuff","stumbling","sturgeon","style","styling","stylus","subcomponent","subconscious","submarine","subroutine","subsidence","substance","suburb","subway","success","suck","sudan","suede","suffocation","sugar","suggestion","suit","suitcase","sultan","summer","sun","sunbeam","sunbonnet","sunday","sundial","sunflower","sunglasses","sunlamp","sunroom","sunshine","supermarket","supply","support","supporter","suppression","surface","surfboard","surgeon","surgery","surname","surprise","susan","sushi","suspect","suspenders","sustainment","SUV","swallow","swamp","swan","swath","sweat","sweater","sweats","sweatshirt","sweatshop","sweatsuit","swedish","sweets","swell","swim","swimming","swimsuit","swing","swiss","switch","switchboard","swivel","sword","swordfish","sycamore","syndicate","synergy","synod","syria","syrup","system","tabby","tabernacle","table","tablecloth","tabletop","tachometer","tackle","tadpole","tail","tailor","tailspin","taiwan","tale","talk","tam","tambour","tambourine","tam-o'-shanter","tandem","tangerine","tank","tanker","tankful","tank-top","tanzania","tap","target","tassel","taste","tatami","tattler","tattoo","taurus","tavern","tax","taxi","taxicab","tea","teacher","teaching","team","tear","technician","technologist","technology","teen","teeth","telephone","telescreen","teletype","television","teller","temp","temper","temperature","temple","tempo","temporariness","temptress","tendency","tenement","tennis","tenor","tent","tepee","term","terracotta","terrapin","territory","test","text","textbook","texture","thailand","thanks","thaw","theater","theism","theme","theoretician","theory","therapist","thermals","thermometer","thigh","thing","thinking","thistle","thomas","thong","thongs","thorn","thought","thread","thrill","throat","throne","thrush","thumb","thunder","thunderbolt","thunderhead","thunderstorm","thursday","tiara","tic","ticket","tie","tiger","tight","tights","tile","till","timbale","time","timeline","timeout","timer","timpani","tin","tinderbox","tinkle","tintype","tip","tire","tissue","titanium","title","toad","toast","toe","toenail","toga","togs","toilet","tom","tomato","tomography","tomorrow","tom-tom","ton","tongue","toot","tooth","toothbrush","toothpaste","toothpick","top","top-hat","topsail","toque","torchiere","toreador","tornado","torso","tortellini","tortoise","tosser","total","tote","touch","tough","tough-guy","tour","tourist","towel","tower","town","townhouse","tow-truck","toy","trachoma","track","tracksuit","tractor","trade","tradition","traditionalism","traffic","trail","trailer","train","trainer","training","tram","tramp","transaction","translation","transmission","transom","transport","trapdoor","trapezium","trapezoid","trash","travel","tray","treatment","tree","trellis","tremor","trench","trial","triangle","tribe","trick","trigonometry","trim","trinket","trip","tripod","trolley","trombone","trooper","trouble","trousers","trout","trove","trowel","truck","truckit","trumpet","trunk","trust","try","t-shirt","tsunami","tub","tuba","tube","tuesday","tugboat","tulip","tummy","tuna","tune","tune-up","tunic","tunnel","turban","turkey","turkish","turn","turnip","turnover","turnstile","turret","turtle","tussle","tutu","tuxedo","tv","twig","twilight","twine","twist","twister","two","typewriter","typhoon","tyvek","uganda","ukraine","ukrainian","ukulele","umbrella","unblinking","uncle","underclothes","underground","underneath","underpants","underpass","undershirt","underwear","underwire","unibody","uniform","union","unit","united kingdom","urn","use","usher","utensil","uzbekistan","vacation","vacuum","vagrant","valance","valley","valuable","value","van","vane","vanity","variation","variety","vase","vast","vault","vaulting","veal","vegetable","vegetarian","vehicle","veil","vein","veldt","vellum","velodrome","velvet","venezuela","venezuelan","venom","veranda","verdict","vermicelli","verse","version","vertigo","verve","vessel","vest","vestment","veterinarian","vibe","vibraphone","vibration","vietnam","view","villa","village","vineyard","vinyl","viola","violet","violin","virginal","virgo","virtue","viscose","vise","vision","visit","visitor","visor","vixen","voice","volcano","volleyball","voyage","vulture","wad","wafer","waffle","waist","waistband","waiter","waitress","walk","walker","walkway","wall","wallaby","wallet","walnut","walrus","wampum","wannabe","war","warden","warlock","warm-up","warning","wash","washbasin","washcloth","washer","washtub","wasp","waste","wastebasket","watch","watchmaker","water","waterbed","waterfall","waterskiing","waterspout","wave","wax","way","weakness","wealth","weapon","weasel","weather","web","wedge","wednesday","weed","weeder","weedkiller","week","weekend","weekender","weight","weird","well","west","western","wet-bar","wetsuit","whale","wharf","wheel","whip","whirlpool","whirlwind","whisker","whiskey","whistle","white","whole","wholesale","wholesaler","whorl","wife","wilderness","will","william","willow","wind","windage","wind-chime","window","windscreen","windshield","wine","wing","wingman","wingtip","winter","wire","wiseguy","wish","wisteria","witch","witch-hunt","withdrawal","witness","wolf","woman","wombat","women","wood","woodland","woodshed","woodwind","wool","woolen","word","work","workbench","worker","workhorse","worklife","workshop","world","worm","worthy","wound","wrap","wraparound","wrecker","wren","wrench","wrestler","wrinkle","wrist","writer","writing","wrong","xylophone","yacht","yak","yam","yard","yarmulke","yarn","yawl","year","yellow","yesterday","yew","yin","yogurt","yoke","young","youth","yugoslavian","yurt","zampone","zebra","zebrafish","zephyr","ziggurat","zinc","zipper","zither","zone","zoo","zoologist","zoology","zoot-suit","zucchini"];function j1(e){return e?e.charAt(0).toUpperCase()+e.slice(1):""}function Wa(){const e=Math.round(Math.random()*1124),t=Math.round(Math.random()*3260);return`${j1(fq[e])} ${j1(hq[t])}`}function dm(e){var n,r;if(!(e!=null&&e.trim().length))return"?";const t=(r=(n=e==null?void 0:e.trim())==null?void 0:n.replace(/[^a-zA-Z ]/g,""))==null?void 0:r.split(" ").map(s=>s.length?s:"").slice(0,3).reduce((s,i)=>s+i[0],"");return t==null?void 0:t.replace("undefined","")}const my=()=>({id:void 0,name:Wa(),apiKey:"",printerURL:"",printerType:0,enabled:!0});class Wt extends yr{static applyLoginDetailsPatchForm(t,n){n.name=t.name||Wa(),n.apiKey=t.apiKey}static convertPrinterToCreateForm(t){const n=my();return n.id=t.id,n.printerURL=t.printerURL,n.name=t.name||Wa(),n.apiKey=t.apiKey,n.enabled=t.enabled,n}static openPrinterURL(t){t&&window.open(t)}static async getPrinters(){const t=Oe.printerRoute;return await this.get(t)}static async getPrinterLoginDetails(t){const n=Oe.getPrinterLoginDetailsRoute(t);return await this.get(n)}static async restartOctoPrint(t){const n=`${Oe.restartOctoPrintRoute(t)}`;return await this.post(n)}static async refreshSocket(t){const n=`${Oe.refreshSocketRoute(t)}`;return await this.post(n)}static async sendPrinterConnectCommand(t){const n=Oe.printerSerialConnectRoute(t);return await this.post(n)}static async sendPrinterDisconnectCommand(t){const n=Oe.printerSerialDisconnectRoute(t);return await this.post(n)}static async sendPrinterJogCommand(t,n){const r=Oe.printerJogCommandRoute(t);return await this.post(r,n)}static async sendPrinterHomeCommand(t,n){const r=Oe.printerHomeCommandRoute(t);return await this.post(r,n)}static async createPrinter(t,n){const r=`${Oe.printerRoute}?forceSave=${n}`;return await this.post(r,t)}static async batchImportPrinters(t){const n=Oe.printerBatchRoute;return await this.post(n,t)}static async deletePrinter(t){const n=Oe.getPrinterRoute(t);return await this.delete(n)}static async updatePrinter(t,n,r){const i=`${Oe.getPrinterRoute(t)}?forceSave=${r}`;return await this.patch(i,n)}static async updatePrinterMaintenance(t,n=null){const r=Oe.postPrinterDisabledReasonRoute(t);return await this.patch(r,{disabledReason:n})}static async testConnection(t){const n=Oe.printerTestConnectionRoute;return await this.post(n,t)}static async toggleEnabled(t,n){const r=Oe.printerEnabledRoute(t);return await this.patch(r,{enabled:n})}}class Un extends yr{static async getSettings(){const t=Oe.settingsRoute;return await this.get(t)}static async getSettingsSensitive(){const t=Oe.settingsSensitiveRoute;return await this.get(t)}static async updateLoginRequiredSettings(t){const n=`${Oe.updateLoginRequiredRoute}`;return await this.put(n,{loginRequired:t})}static async updateRegistrationEnabledSettings(t){const n=`${Oe.updateRegistrationEnabledRoute}`;return await this.put(n,{registrationEnabled:t})}static async updateCredentialSettings(t,n,r){const s=`${Oe.updateCredentialSettings}`;return await this.put(s,{jwtExpiresIn:t,refreshTokenAttempts:n,refreshTokenExpiry:r})}static async updateFrontendSettings(t){const n=`${Oe.updateFrontendSettingsRoute}`;return await this.put(n,t)}static async setSentryDiagnosticsSettings(t){const n=`${Oe.serverSentryDiagnosticsSettingRoute}`;return await this.patch(n,{enabled:t})}static async updateTimeoutSettings(t){const n=`${Oe.updateTimeoutSettingRoute}`;return await this.put(n,t)}static async setFileCleanSettings(t){const n=`${Oe.fileCleanSettingsRoute}`;return await this.put(n,t)}static async updateExperimentalMoonrakerSupport(t){const n=Oe.updateExperimentalMoonrakerSupportRoute;return await this.put(n,{enabled:t})}static async updateExperimentalClientSupport(t){const n=Oe.updateExperimentalClientSupportRoute;return await this.put(n,{enabled:t})}}class ah extends yr{static async stopPrintJob(t){const n=Oe.printerStopJobRoute(t);return await this.post(n)}static async pausePrintJob(t){const n=Oe.printerPauseJobRoute(t);return await this.post(n)}static async resumePrintJob(t){const n=Oe.printerResumeJobRoute(t);return await this.post(n)}}const Bs=Ms({id:"Settings",state:()=>({settings:void 0,frontendDebugSettings:{showPrinterStateUpdateSideNav:!1,showInterpretedPrinterState:!1,showJobsRendered:!1}}),actions:{async loadSettings(){const e=await Un.getSettings();return this.settings=e,e},async updateFrontendSettings(e){const t=await Un.updateFrontendSettings(e);return this.settings=t,t},async updateTimeoutSettings(e){const t=await Un.updateTimeoutSettings(e);return this.settings=t,t}},getters:{serverSettings(){var e;return(e=this.settings)==null?void 0:e.server},largeTiles(){var e,t;return((t=(e=this.settings)==null?void 0:e.frontend)==null?void 0:t.largeTiles)||!1},gridCols(){var e,t;return((t=(e=this.settings)==null?void 0:e.frontend)==null?void 0:t.gridCols)||8},gridRows(){var e,t;return((t=(e=this.settings)==null?void 0:e.frontend)==null?void 0:t.gridRows)||8}}}),yi={danger:"danger",dark:"dark",secondary:"secondary",success:"success"},bi={DarkBlue:"#050c2e",Black:"#000000",DarkGray:"#262626",LightBrown:"#583c0e",Brown:"#580e47",Red:"#2e0905"},pl={Disabled:"Disabled",Maintenance:"Maintenance",Offline:"Offline",Finding:"Finding",Disconnected:"Disconnected",Error:"Error",Paused:"Paused",Operational:"Operational",Printing:"Printing"};function jI(e,t,n){var f,p,g,m;const s=Bs().frontendDebugSettings.showInterpretedPrinterState,i={};if(!e.enabled)return(f=e.disabledReason)!=null&&f.length?{...i,color:yi.danger,rgb:bi.Black,text:pl.Maintenance}:{...i,color:yi.secondary,rgb:bi.DarkBlue,text:pl.Disabled};const o=(t==null?void 0:t.api)==="responding",a=(t==null?void 0:t.api)==="authFail";if(!o||!t){const y=(t==null?void 0:t.api)==="noResponse";return{...i,color:yi.secondary,rgb:bi.Red,text:a?"API key wrong":y?"API unreachable":(t==null?void 0:t.api)||"-"}}if(!o)return{...i,color:yi.danger,rgb:bi.Red,text:a?"API key wrong":"No API connection"};const l=t.socket==="authenticated",u=t.socket==="authenticating",d=(g=(p=n==null?void 0:n.current)==null?void 0:p.payload)==null?void 0:g.state,c=d==null?void 0:d.flags;if(!l||!c)return s&&console.debug(`Socket opened ${l?1:0}, socketAuthing ${u?1:0} printerState ${n?1:0},
62
+ currentState: ${d}, FLAGS ${c}`),{...i,color:yi.danger,rgb:bi.Red,text:n?"Awaiting":"No USB"};if(!c){console.error("No flags",c);return}return c.error||c.closedOrError?{...i,color:yi.danger,rgb:bi.Red,text:((m=d.text)==null?void 0:m.replace("Offline","Disconnected"))||pl.Error,description:d.error}:c.paused||c.pausing?{...i,color:yi.success,rgb:bi.Brown,text:pl.Paused}:c.printing?{...i,color:yi.success,rgb:bi.LightBrown,text:pl.Printing}:{...i,color:yi.dark,rgb:bi.DarkGray,text:pl.Operational,description:d.error}}const La=e=>{var t,n;return(n=(t=e==null?void 0:e.current)==null?void 0:t.payload)==null?void 0:n.state},pq=e=>{var t;return(t=La(e))==null?void 0:t.flags.printing},mq=(e,t)=>{var n,r,s;return!fm(e)&&(e==null?void 0:e.enabled)&&!((n=La(t))!=null&&n.flags.operational)||((r=La(t))==null?void 0:r.flags.error)||((s=La(t))==null?void 0:s.flags.closedOrError)},qI=e=>!fm(e)&&!(e!=null&&e.enabled),fm=e=>{var t;return!(e!=null&&e.enabled)&&((t=e==null?void 0:e.disabledReason)==null?void 0:t.length)},gq=(e,t)=>{var n,r,s;return((n=La(t))==null?void 0:n.flags)&&!((r=La(t))!=null&&r.flags.printing)&&((s=La(t))==null?void 0:s.flags.operational)&&!qI(e)&&!fm(e)},rr=Ms("PrinterState",{state:()=>({printerIds:[],printerEventsById:{},socketStatesById:{}}),getters:{operationalPrintersById(){const e=Nt(),t={};return this.printerIds.forEach(n=>{var s,i,o,a;const r=this.printerEventsById[n];if((a=(o=(i=(s=r==null?void 0:r.current)==null?void 0:s.payload)==null?void 0:i.state)==null?void 0:o.flags)!=null&&a.operational){const l=e.printer(n);if(l)t[n]=l;else throw new Error(`PrinterStore contains no printer with id ${n} but events are known`)}}),t},isPrinterOperational(){return e=>!!this.operationalPrintersById[e]},printingPrintersById(){const e={};return this.printerIds.forEach(t=>{var r,s,i,o;const n=this.printerEventsById[t];(o=(i=(s=(r=n==null?void 0:n.current)==null?void 0:r.payload)==null?void 0:s.state)==null?void 0:i.flags)!=null&&o.printing&&(e[t]=n)}),e},isPrinterPrinting(){return e=>!!this.printingPrintersById[e]},isPrinterStoppable(){return e=>{var r,s,i;const t=this.printerEventsById[e];if(!t)return!1;const n=(i=(s=(r=t==null?void 0:t.current)==null?void 0:r.payload)==null?void 0:s.state)==null?void 0:i.flags;return(n==null?void 0:n.printing)||(n==null?void 0:n.paused)}},isPrinterPaused(){return e=>{var r,s,i;const t=this.printerEventsById[e];if(!t)return!1;const n=(i=(s=(r=t==null?void 0:t.current)==null?void 0:r.payload)==null?void 0:s.state)==null?void 0:i.flags;return n==null?void 0:n.paused}},printerCurrentEventReceivedAtById(){const e={};return this.printerIds.forEach(t=>{var r;const n=this.printerEventsById[t];(r=n==null?void 0:n.current)!=null&&r.receivedAt&&(e[t]=n.current.receivedAt)}),e},onlinePrinters(){const e=Nt(),t={};return this.printerIds.forEach(n=>{const r=this.socketStatesById[n];if((r==null?void 0:r.api)==="responding"){const s=e.printer(n);if(s)t[n]=s;else throw new Error(`PrinterStore contains no printer with id ${n} but socket state is opened`)}}),t},onlinePrintersWithStates(){return Object.values(this.onlinePrinters).map(e=>({printer:e,printerState:this.printerEventsById[e.id]}))},printingCount(){const e=rr();return Object.values(e.onlinePrintersWithStates).filter(t=>pq(t.printerState)).length},operationalNotPrintingCount(){return this.onlinePrintersWithStates.filter(e=>gq(e.printer,e.printerState)).length},isApiResponding(){return e=>Object.keys(this.onlinePrinters).includes(e.toString())},isPrinterNotOnline(){return e=>!this.isApiResponding(e)},printerJobsById(){const e=Nt(),t=Bs().frontendDebugSettings.showJobsRendered,n={};return this.printerIds.forEach(r=>{var o,a,l,u;const s=this.printerEventsById[r],i=(l=(a=(o=s==null?void 0:s.current)==null?void 0:o.payload)==null?void 0:a.state)==null?void 0:l.flags;if(i!=null&&i.printing||i!=null&&i.paused){const d=e.printer(r);if(d)n[d.id]=(u=s==null?void 0:s.current)==null?void 0:u.payload;else throw new Error(`PrinterStore contains no printer with id ${r} but events are known`)}}),t&&console.debug("[PrinterStateStore] rendered printerJobsById",n),n},printersWithJob(){const e=Nt(),t=[];return this.printerIds.forEach(n=>{var i,o,a,l;const r=this.printerEventsById[n],s=(a=(o=(i=r==null?void 0:r.current)==null?void 0:i.payload)==null?void 0:o.state)==null?void 0:a.flags;if(s!=null&&s.printing||s!=null&&s.paused){const u=e.printer(n);if(u)t.push({printer:u,job:(l=r==null?void 0:r.current)==null?void 0:l.payload});else throw new Error(`PrinterStore contains no printer with id ${n} but events are known`)}}),t},printingFilePathsByPrinterId(){const e={};return this.printerIds.forEach(t=>{var s,i,o,a,l,u,d;const n=this.printerEventsById[t],r=(o=(i=(s=n==null?void 0:n.current)==null?void 0:s.payload)==null?void 0:i.state)==null?void 0:o.flags;(r!=null&&r.printing||r!=null&&r.paused)&&(e[t]=(d=(u=(l=(a=n==null?void 0:n.current)==null?void 0:a.payload)==null?void 0:l.job)==null?void 0:u.file)==null?void 0:d.path)}),e}},actions:{setSocketStates(e){this.socketStatesById=e,this.printerIds=Object.keys(e)},setPrinterEvents(e){this.printerEventsById=e},deletePrinterEvents(e){delete this.printerEventsById[e],this.printerIds=Object.keys(this.printerEventsById)},async selectAndPrintFile({printerId:e,fullPath:t}){if(!(!e||!Nt().printer(e))){if(this.isPrinterPrinting(e)){alert("This printer is printing or not connected! Either way printing is not an option.");return}await Oo.selectAndPrintFile(e,t,!0)}}}}),Nt=Ms("Printers",{state:()=>({printers:[],printerFileCache:{},sideNavPrinter:void 0,updateDialogPrinter:void 0,selectedPrinters:[],maintenanceDialogPrinter:void 0}),getters:{printer(){return e=>this.printers.find(t=>t.id==e)},isSelectedPrinter(e){return t=>!!e.selectedPrinters.find(n=>n.id===t)},printerFiles(){return e=>this.printerFileCache[e]},disabledCount(){return this.printers.filter(qI).length},disconnectedCount(){const e=rr();return this.printers.filter(t=>mq(t,e.printerEventsById[t.id])).length},maintenanceCount(){return this.printers.filter(e=>fm(e)).length}},actions:{async createPrinter(e,t){const n=await Wt.createPrinter(e,t);return this.printers.push(n),this.printers.sort((r,s)=>{var i,o,a;return(a=(i=r.name)==null?void 0:i.toLowerCase())!=null&&a.localeCompare((o=s==null?void 0:s.name)==null?void 0:o.toLowerCase())?1:-1}),n},toggleSelectedPrinter(e){const t=rr(),n=this.selectedPrinters.findIndex(r=>r.id==e.id);n===-1?t.isApiResponding(e.id)&&this.selectedPrinters.push(e):this.selectedPrinters.splice(n,1)},clearSelectedPrinters(){this.selectedPrinters=[]},setSideNavPrinter(e){this.sideNavPrinter=e},setUpdateDialogPrinter(e){this.updateDialogPrinter=e},setMaintenanceDialogPrinter(e){this.maintenanceDialogPrinter=e},async updatePrinter({printerId:e,updatedPrinter:t},n){const r=await Wt.updatePrinter(e,t,n);return this._replacePrinter({printerId:e,printer:r}),r},async loadPrinters(){const e=await Wt.getPrinters();return this.setPrinters(e),e},async deletePrinter(e){const t=await Wt.deletePrinter(e);return this._popPrinter(e),t},setPrinters(e){var n;if(!(e!=null&&e.length)){this.printers=[];return}const t=(n=this.sideNavPrinter)==null?void 0:n.id;t&&(this.sideNavPrinter=e.find(r=>r.id===t)),this.printers=e.sort((r,s)=>{var i,o,a;return(a=(i=r.name)==null?void 0:i.toLowerCase())!=null&&a.localeCompare((o=s==null?void 0:s.name)==null?void 0:o.toLowerCase())?1:-1})},_popPrinter(e){const t=this.printers.findIndex(n=>n.id===e);t!==-1?this.printers.splice(t,1):console.warn("Printer was not popped as it did not occur in state",e)},_replacePrinter({printerId:e,printer:t}){const n=this.printers.findIndex(r=>r.id===e);n!==-1?this.printers[n]=t:console.warn("Printer was not purged as it did not occur in state",e)},async clearPrinterFiles(e){if(!e)throw new Error("No printerId was provided");const t=await Oo.clearFiles(e);if(!(t!=null&&t.failedFiles))throw new Error("No failed files were returned");this.printerFileCache[e]&&(this.printerFileCache[e]=t.failedFiles)},async loadPrinterFiles(e){const t=await Oo.getFiles(e);return t.sort((n,r)=>n.date<r.date?1:-1),this.printerFileCache[e]=t,t},async deletePrinterFile(e,t){await Oo.deleteFileOrFolder(e,t);const n=this.printerFileCache[e];if(!(n!=null&&n.length)){console.warn("Printer file list was nonexistent",e);return}const r=n.findIndex(s=>s.path===t);return r!==-1?n.splice(r,1):console.warn("File was not purged as it did not occur in state",t),this.printerFiles(e)},async sendStopJobCommand(e){const t=rr();if(!e)return;const n=this.printer(e);if(!n)return;const r=t.isPrinterPrinting(e)?"The printer seems idle - do you want to command it to stop anyway?":"The printer is still printing - are you sure to stop it?";confirm(r)&&await ah.stopPrintJob(n.id)}}}),Nn=xe()({name:"VCardActions",props:Ve(),setup(e,t){let{slots:n}=t;return Dr({VBtn:{slim:!0,variant:"text"}}),Ie(()=>{var r;return h("div",{class:["v-card-actions",e.class],style:e.style},[(r=n.default)==null?void 0:r.call(n)])}),{}}}),vq=de({opacity:[Number,String],...Ve(),...bt()},"VCardSubtitle"),hm=xe()({name:"VCardSubtitle",props:vq(),setup(e,t){let{slots:n}=t;return Ie(()=>h(e.tag,{class:["v-card-subtitle",e.class],style:[{"--v-card-subtitle-opacity":e.opacity},e.style]},n)),{}}}),an=Eu("v-card-title");function yq(e){return{aspectStyles:R(()=>{const t=Number(e.aspectRatio);return t?{paddingBottom:String(1/t*100)+"%"}:void 0})}}const WI=de({aspectRatio:[String,Number],contentClass:null,inline:Boolean,...Ve(),...$r()},"VResponsive"),q1=xe()({name:"VResponsive",props:WI(),setup(e,t){let{slots:n}=t;const{aspectStyles:r}=yq(e),{dimensionStyles:s}=Fr(e);return Ie(()=>{var i;return h("div",{class:["v-responsive",{"v-responsive--inline":e.inline},e.class],style:[s.value,e.style]},[h("div",{class:"v-responsive__sizer",style:r.value},null),(i=n.additional)==null?void 0:i.call(n),n.default&&h("div",{class:["v-responsive__content",e.contentClass]},[n.default()])])}),{}}});function bq(e,t){if(!Pb)return;const n=t.modifiers||{},r=t.value,{handler:s,options:i}=typeof r=="object"?r:{handler:r,options:{}},o=new IntersectionObserver(function(){var c;let a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],l=arguments.length>1?arguments[1]:void 0;const u=(c=e._observe)==null?void 0:c[t.instance.$.uid];if(!u)return;const d=a.some(f=>f.isIntersecting);s&&(!n.quiet||u.init)&&(!n.once||d||u.init)&&s(d,a,l),d&&n.once?GI(e,t):u.init=!0},i);e._observe=Object(e._observe),e._observe[t.instance.$.uid]={init:!1,observer:o},o.observe(e)}function GI(e,t){var r;const n=(r=e._observe)==null?void 0:r[t.instance.$.uid];n&&(n.observer.unobserve(e),delete e._observe[t.instance.$.uid])}const kw={mounted:bq,unmounted:GI},wq=de({absolute:Boolean,alt:String,cover:Boolean,color:String,draggable:{type:[Boolean,String],default:void 0},eager:Boolean,gradient:String,lazySrc:String,options:{type:Object,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,...WI(),...Ve(),...Bn(),...Ou()},"VImg"),Ki=xe()({name:"VImg",directives:{intersect:kw},props:wq(),emits:{loadstart:e=>!0,load:e=>!0,error:e=>!0},setup(e,t){let{emit:n,slots:r}=t;const{backgroundColorClasses:s,backgroundColorStyles:i}=pr(Te(e,"color")),{roundedClasses:o}=qn(e),a=sn("VImg"),l=Me(""),u=U(),d=Me(e.eager?"loading":"idle"),c=Me(),f=Me(),p=R(()=>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)}),g=R(()=>p.value.aspect||c.value/f.value||0);Ce(()=>e.src,()=>{m(d.value!=="idle")}),Ce(g,(O,A)=>{!O&&A&&u.value&&P(u.value)}),Ap(()=>m());function m(O){if(!(e.eager&&O)&&!(Pb&&!O&&!e.eager)){if(d.value="loading",p.value.lazySrc){const A=new Image;A.src=p.value.lazySrc,P(A,null)}p.value.src&&Ot(()=>{var A;n("loadstart",((A=u.value)==null?void 0:A.currentSrc)||p.value.src),setTimeout(()=>{var D;if(!a.isUnmounted)if((D=u.value)!=null&&D.complete){if(u.value.naturalWidth||b(),d.value==="error")return;g.value||P(u.value,null),d.value==="loading"&&y()}else g.value||P(u.value),w()})})}}function y(){var O;a.isUnmounted||(w(),P(u.value),d.value="loaded",n("load",((O=u.value)==null?void 0:O.currentSrc)||p.value.src))}function b(){var O;a.isUnmounted||(d.value="error",n("error",((O=u.value)==null?void 0:O.currentSrc)||p.value.src))}function w(){const O=u.value;O&&(l.value=O.currentSrc||O.src)}let S=-1;Tn(()=>{clearTimeout(S)});function P(O){let A=arguments.length>1&&arguments[1]!==void 0?arguments[1]:100;const D=()=>{if(clearTimeout(S),a.isUnmounted)return;const{naturalHeight:V,naturalWidth:H}=O;V||H?(c.value=H,f.value=V):!O.complete&&d.value==="loading"&&A!=null?S=window.setTimeout(D,A):(O.currentSrc.endsWith(".svg")||O.currentSrc.startsWith("data:image/svg+xml"))&&(c.value=1,f.value=1)};D()}const E=R(()=>({"v-img__img--cover":e.cover,"v-img__img--contain":!e.cover})),T=()=>{var D;if(!p.value.src||d.value==="idle")return null;const O=h("img",{class:["v-img__img",E.value],style:{objectPosition:e.position},src:p.value.src,srcset:p.value.srcset,alt:e.alt,crossorigin:e.crossorigin,referrerpolicy:e.referrerpolicy,draggable:e.draggable,sizes:e.sizes,ref:u,onLoad:y,onError:b},null),A=(D=r.sources)==null?void 0:D.call(r);return h(ii,{transition:e.transition,appear:!0},{default:()=>[en(A?h("picture",{class:"v-img__picture"},[A,O]):O,[[qo,d.value==="loaded"]])]})},C=()=>h(ii,{transition:e.transition},{default:()=>[p.value.lazySrc&&d.value!=="loaded"&&h("img",{class:["v-img__img","v-img__img--preload",E.value],style:{objectPosition:e.position},src:p.value.lazySrc,alt:e.alt,crossorigin:e.crossorigin,referrerpolicy:e.referrerpolicy,draggable:e.draggable},null)]}),k=()=>r.placeholder?h(ii,{transition:e.transition,appear:!0},{default:()=>[(d.value==="loading"||d.value==="error"&&!r.error)&&h("div",{class:"v-img__placeholder"},[r.placeholder()])]}):null,x=()=>r.error?h(ii,{transition:e.transition,appear:!0},{default:()=>[d.value==="error"&&h("div",{class:"v-img__error"},[r.error()])]}):null,I=()=>e.gradient?h("div",{class:"v-img__gradient",style:{backgroundImage:`linear-gradient(${e.gradient})`}},null):null,M=Me(!1);{const O=Ce(g,A=>{A&&(requestAnimationFrame(()=>{requestAnimationFrame(()=>{M.value=!0})}),O())})}return Ie(()=>{const O=q1.filterProps(e);return en(h(q1,me({class:["v-img",{"v-img--absolute":e.absolute,"v-img--booting":!M.value},s.value,o.value,e.class],style:[{width:Ne(e.width==="auto"?c.value:e.width)},i.value,e.style]},O,{aspectRatio:g.value,"aria-label":e.alt,role:e.alt?"img":void 0}),{additional:()=>h(Re,null,[h(T,null,null),h(C,null,null),h(I,null,null),h(k,null,null),h(x,null,null)]),default:r.default}),[[mr("intersect"),{handler:m,options:e.options},null,{once:!0}]])}),{currentSrc:l,image:u,state:d,naturalWidth:c,naturalHeight:f}}}),Sq=de({start:Boolean,end:Boolean,icon:Je,image:String,text:String,...vs(),...Ve(),...Lr(),...Bn(),...Pu(),...bt(),...Dt(),...Fs({variant:"flat"})},"VAvatar"),lt=xe()({name:"VAvatar",props:Sq(),setup(e,t){let{slots:n}=t;const{themeClasses:r}=Xt(e),{borderClasses:s}=Ls(e),{colorClasses:i,colorStyles:o,variantClasses:a}=el(e),{densityClasses:l}=ys(e),{roundedClasses:u}=qn(e),{sizeClasses:d,sizeStyles:c}=Rd(e);return Ie(()=>h(e.tag,{class:["v-avatar",{"v-avatar--start":e.start,"v-avatar--end":e.end},r.value,s.value,i.value,l.value,u.value,d.value,a.value,e.class],style:[o.value,c.value,e.style]},{default:()=>[n.default?h(At,{key:"content-defaults",defaults:{VImg:{cover:!0,src:e.image},VIcon:{icon:e.icon}}},{default:()=>[n.default()]}):e.image?h(Ki,{key:"image",src:e.image,alt:"",cover:!0},null):e.icon?h(X,{key:"icon",icon:e.icon},null):e.text,Go(!1,"v-avatar")]})),{}}}),_q=de({appendAvatar:String,appendIcon:Je,prependAvatar:String,prependIcon:Je,subtitle:[String,Number],title:[String,Number],...Ve(),...Lr()},"VCardItem"),kq=xe()({name:"VCardItem",props:_q(),setup(e,t){let{slots:n}=t;return Ie(()=>{var u;const r=!!(e.prependAvatar||e.prependIcon),s=!!(r||n.prepend),i=!!(e.appendAvatar||e.appendIcon),o=!!(i||n.append),a=!!(e.title!=null||n.title),l=!!(e.subtitle!=null||n.subtitle);return h("div",{class:["v-card-item",e.class],style:e.style},[s&&h("div",{key:"prepend",class:"v-card-item__prepend"},[n.prepend?h(At,{key:"prepend-defaults",disabled:!r,defaults:{VAvatar:{density:e.density,image:e.prependAvatar},VIcon:{density:e.density,icon:e.prependIcon}}},n.prepend):h(Re,null,[e.prependAvatar&&h(lt,{key:"prepend-avatar",density:e.density,image:e.prependAvatar},null),e.prependIcon&&h(X,{key:"prepend-icon",density:e.density,icon:e.prependIcon},null)])]),h("div",{class:"v-card-item__content"},[a&&h(an,{key:"title"},{default:()=>{var d;return[((d=n.title)==null?void 0:d.call(n))??e.title]}}),l&&h(hm,{key:"subtitle"},{default:()=>{var d;return[((d=n.subtitle)==null?void 0:d.call(n))??e.subtitle]}}),(u=n.default)==null?void 0:u.call(n)]),o&&h("div",{key:"append",class:"v-card-item__append"},[n.append?h(At,{key:"append-defaults",disabled:!i,defaults:{VAvatar:{density:e.density,image:e.appendAvatar},VIcon:{density:e.density,icon:e.appendIcon}}},n.append):h(Re,null,[e.appendIcon&&h(X,{key:"append-icon",density:e.density,icon:e.appendIcon},null),e.appendAvatar&&h(lt,{key:"append-avatar",density:e.density,image:e.appendAvatar},null)])])])}),{}}}),xq=de({opacity:[Number,String],...Ve(),...bt()},"VCardText"),nn=xe()({name:"VCardText",props:xq(),setup(e,t){let{slots:n}=t;return Ie(()=>h(e.tag,{class:["v-card-text",e.class],style:[{"--v-card-text-opacity":e.opacity},e.style]},n)),{}}}),Eq=de({appendAvatar:String,appendIcon:Je,disabled:Boolean,flat:Boolean,hover:Boolean,image:String,link:{type:Boolean,default:void 0},prependAvatar:String,prependIcon:Je,ripple:{type:[Boolean,Object],default:!0},subtitle:[String,Number],text:[String,Number],title:[String,Number],...vs(),...Ve(),...Lr(),...$r(),...bs(),...Bp(),...Ko(),...Tu(),...Bn(),...Hp(),...bt(),...Dt(),...Fs({variant:"elevated"})},"VCard"),yt=xe()({name:"VCard",directives:{Ripple:Iu},props:Eq(),setup(e,t){let{attrs:n,slots:r}=t;const{themeClasses:s}=Xt(e),{borderClasses:i}=Ls(e),{colorClasses:o,colorStyles:a,variantClasses:l}=el(e),{densityClasses:u}=ys(e),{dimensionStyles:d}=Fr(e),{elevationClasses:c}=$s(e),{loaderClasses:f}=Ad(e),{locationStyles:p}=tl(e),{positionClasses:g}=Ru(e),{roundedClasses:m}=qn(e),y=Up(e,n),b=R(()=>e.link!==!1&&y.isLink.value),w=R(()=>!e.disabled&&e.link!==!1&&(e.link||y.isClickable.value));return Ie(()=>{const S=b.value?"a":e.tag,P=!!(r.title||e.title!=null),E=!!(r.subtitle||e.subtitle!=null),T=P||E,C=!!(r.append||e.appendAvatar||e.appendIcon),k=!!(r.prepend||e.prependAvatar||e.prependIcon),x=!!(r.image||e.image),I=T||k||C,M=!!(r.text||e.text!=null);return en(h(S,me({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":w.value},s.value,i.value,o.value,u.value,c.value,f.value,g.value,m.value,l.value,e.class],style:[a.value,d.value,p.value,e.style],onClick:w.value&&y.navigate,tabindex:e.disabled?-1:void 0},y.linkProps),{default:()=>{var O;return[x&&h("div",{key:"image",class:"v-card__image"},[r.image?h(At,{key:"image-defaults",disabled:!e.image,defaults:{VImg:{cover:!0,src:e.image}}},r.image):h(Ki,{key:"image-img",cover:!0,src:e.image},null)]),h(Vp,{name:"v-card",active:!!e.loading,color:typeof e.loading=="boolean"?void 0:e.loading},{default:r.loader}),I&&h(kq,{key:"item",prependAvatar:e.prependAvatar,prependIcon:e.prependIcon,title:e.title,subtitle:e.subtitle,appendAvatar:e.appendAvatar,appendIcon:e.appendIcon},{default:r.item,prepend:r.prepend,title:r.title,subtitle:r.subtitle,append:r.append}),M&&h(nn,{key:"text"},{default:()=>{var A;return[((A=r.text)==null?void 0:A.call(r))??e.text]}}),(O=r.default)==null?void 0:O.call(r),r.actions&&h(Nn,null,{default:r.actions}),Go(w.value,"v-card")]}}),[[mr("ripple"),w.value&&e.ripple]])}),{}}}),KI=Symbol.for("vuetify:goto");function YI(){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<.5?2*e**2:-1+(4-2*e)*e,easeInCubic:e=>e**3,easeOutCubic:e=>--e**3+1,easeInOutCubic:e=>e<.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<.5?8*e**4:1-8*--e**4,easeInQuint:e=>e**5,easeOutQuint:e=>1+--e**5,easeInOutQuint:e=>e<.5?16*e**5:1+16*--e**5}}}function Cq(e){return xw(e)??(document.scrollingElement||document.body)}function xw(e){return typeof e=="string"?document.querySelector(e):Tb(e)}function kg(e,t,n){if(typeof e=="number")return t&&n?-e:e;let r=xw(e),s=0;for(;r;)s+=t?r.offsetLeft:r.offsetTop,r=r.offsetParent;return s}function Pq(e,t){return{rtl:t.isRtl,options:tr(YI(),e)}}async function W1(e,t,n,r){const s=n?"scrollLeft":"scrollTop",i=tr((r==null?void 0:r.options)??YI(),t),o=r==null?void 0:r.rtl.value,a=(typeof e=="number"?e:xw(e))??0,l=i.container==="parent"&&a instanceof HTMLElement?a.parentElement:Cq(i.container),u=typeof i.easing=="function"?i.easing:i.patterns[i.easing];if(!u)throw new TypeError(`Easing function "${i.easing}" not found.`);let d;if(typeof a=="number")d=kg(a,n,o);else if(d=kg(a,n,o)-kg(l,n,o),i.layout){const g=window.getComputedStyle(a).getPropertyValue("--v-layout-top");g&&(d-=parseInt(g,10))}d+=i.offset,d=Rq(l,d,!!o,!!n);const c=l[s]??0;if(d===c)return Promise.resolve(d);const f=performance.now();return new Promise(p=>requestAnimationFrame(function g(m){const b=(m-f)/i.duration,w=Math.floor(c+(d-c)*u(Rr(b,0,1)));if(l[s]=w,b>=1&&Math.abs(w-l[s])<10)return p(d);if(b>2)return p(l[s]);requestAnimationFrame(g)}))}function Tq(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const t=Ye(KI),{isRtl:n}=Nr();if(!t)throw new Error("[Vuetify] Could not find injected goto instance");const r={...t,rtl:R(()=>t.rtl.value||n.value)};async function s(i,o){return W1(i,tr(e,o),!1,r)}return s.horizontal=async(i,o)=>W1(i,tr(e,o),!0,r),s}function Rq(e,t,n,r){const{scrollWidth:s,scrollHeight:i}=e,[o,a]=e===document.scrollingElement?[window.innerWidth,window.innerHeight]:[e.offsetWidth,e.offsetHeight];let l,u;return r?n?(l=-(s-o),u=0):(l=0,u=s-o):(l=0,u=i+-a),Math.max(Math.min(t,u),l)}function Iq(e){let{selectedElement:t,containerElement:n,isRtl:r,isHorizontal:s}=e;const i=nd(s,n),o=XI(s,r,n),a=nd(s,t),l=QI(s,t),u=a*.4;return o>l?l-u:o+i<l+a?l-i+a+u:o}function Aq(e){let{selectedElement:t,containerElement:n,isHorizontal:r}=e;const s=nd(r,n),i=QI(r,t),o=nd(r,t);return i-s/2+o/2}function G1(e,t){const n=e?"scrollWidth":"scrollHeight";return(t==null?void 0:t[n])||0}function Oq(e,t){const n=e?"clientWidth":"clientHeight";return(t==null?void 0:t[n])||0}function XI(e,t,n){if(!n)return 0;const{scrollLeft:r,offsetWidth:s,scrollWidth:i}=n;return e?t?i-s+r:r:n.scrollTop}function nd(e,t){const n=e?"offsetWidth":"offsetHeight";return(t==null?void 0:t[n])||0}function QI(e,t){const n=e?"offsetLeft":"offsetTop";return(t==null?void 0:t[n])||0}const Mq=Symbol.for("vuetify:v-slide-group"),JI=de({centerActive:Boolean,direction:{type:String,default:"horizontal"},symbol:{type:null,default:Mq},nextIcon:{type:Je,default:"$next"},prevIcon:{type:Je,default:"$prev"},showArrows:{type:[Boolean,String],validator:e=>typeof e=="boolean"||["always","desktop","mobile"].includes(e)},...Ve(),...nl({mobile:null}),...bt(),...Cd({selectedClass:"v-slide-group-item--active"})},"VSlideGroup"),K1=xe()({name:"VSlideGroup",props:JI(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const{isRtl:r}=Nr(),{displayClasses:s,mobile:i}=mi(e),o=Cu(e,e.symbol),a=Me(!1),l=Me(0),u=Me(0),d=Me(0),c=R(()=>e.direction==="horizontal"),{resizeRef:f,contentRect:p}=Ua(),{resizeRef:g,contentRect:m}=Ua(),y=Tq(),b=R(()=>({container:f.el,duration:200,easing:"easeOutQuart"})),w=R(()=>o.selected.value.length?o.items.value.findIndex(W=>W.id===o.selected.value[0]):-1),S=R(()=>o.selected.value.length?o.items.value.findIndex(W=>W.id===o.selected.value[o.selected.value.length-1]):-1);if(kt){let W=-1;Ce(()=>[o.selected.value,p.value,m.value,c.value],()=>{cancelAnimationFrame(W),W=requestAnimationFrame(()=>{if(p.value&&m.value){const Z=c.value?"width":"height";u.value=p.value[Z],d.value=m.value[Z],a.value=u.value+1<d.value}if(w.value>=0&&g.el){const Z=g.el.children[S.value];E(Z,e.centerActive)}})})}const P=Me(!1);function E(W,Z){let q=0;Z?q=Aq({containerElement:f.el,isHorizontal:c.value,selectedElement:W}):q=Iq({containerElement:f.el,isHorizontal:c.value,isRtl:r.value,selectedElement:W}),T(q)}function T(W){if(!kt||!f.el)return;const Z=nd(c.value,f.el),q=XI(c.value,r.value,f.el);if(!(G1(c.value,f.el)<=Z||Math.abs(W-q)<16)){if(c.value&&r.value&&f.el){const{scrollWidth:pe,offsetWidth:ue}=f.el;W=pe-ue-W}c.value?y.horizontal(W,b.value):y(W,b.value)}}function C(W){const{scrollTop:Z,scrollLeft:q}=W.target;l.value=c.value?q:Z}function k(W){if(P.value=!0,!(!a.value||!g.el)){for(const Z of W.composedPath())for(const q of g.el.children)if(q===Z){E(q);return}}}function x(W){P.value=!1}let I=!1;function M(W){var Z;!I&&!P.value&&!(W.relatedTarget&&((Z=g.el)!=null&&Z.contains(W.relatedTarget)))&&D(),I=!1}function O(){I=!0}function A(W){if(!g.el)return;function Z(q){W.preventDefault(),D(q)}c.value?W.key==="ArrowRight"?Z(r.value?"prev":"next"):W.key==="ArrowLeft"&&Z(r.value?"next":"prev"):W.key==="ArrowDown"?Z("next"):W.key==="ArrowUp"&&Z("prev"),W.key==="Home"?Z("first"):W.key==="End"&&Z("last")}function D(W){var q,K;if(!g.el)return;let Z;if(!W)Z=Hc(g.el)[0];else if(W==="next"){if(Z=(q=g.el.querySelector(":focus"))==null?void 0:q.nextElementSibling,!Z)return D("first")}else if(W==="prev"){if(Z=(K=g.el.querySelector(":focus"))==null?void 0:K.previousElementSibling,!Z)return D("last")}else W==="first"?Z=g.el.firstElementChild:W==="last"&&(Z=g.el.lastElementChild);Z&&Z.focus({preventScroll:!0})}function V(W){const Z=c.value&&r.value?-1:1,q=(W==="prev"?-Z:Z)*u.value;let K=l.value+q;if(c.value&&r.value&&f.el){const{scrollWidth:pe,offsetWidth:ue}=f.el;K+=pe-ue}T(K)}const H=R(()=>({next:o.next,prev:o.prev,select:o.select,isSelected:o.isSelected})),G=R(()=>{switch(e.showArrows){case"always":return!0;case"desktop":return!i.value;case!0:return a.value||Math.abs(l.value)>0;case"mobile":return i.value||a.value||Math.abs(l.value)>0;default:return!i.value&&(a.value||Math.abs(l.value)>0)}}),j=R(()=>Math.abs(l.value)>1),B=R(()=>{if(!f.value)return!1;const W=G1(c.value,f.el),Z=Oq(c.value,f.el);return W-Z-Math.abs(l.value)>1});return Ie(()=>h(e.tag,{class:["v-slide-group",{"v-slide-group--vertical":!c.value,"v-slide-group--has-affixes":G.value,"v-slide-group--is-overflowing":a.value},s.value,e.class],style:e.style,tabindex:P.value||o.selected.value.length?-1:0,onFocus:M},{default:()=>{var W,Z,q;return[G.value&&h("div",{key:"prev",class:["v-slide-group__prev",{"v-slide-group__prev--disabled":!j.value}],onMousedown:O,onClick:()=>j.value&&V("prev")},[((W=n.prev)==null?void 0:W.call(n,H.value))??h(Q_,null,{default:()=>[h(X,{icon:r.value?e.nextIcon:e.prevIcon},null)]})]),h("div",{key:"container",ref:f,class:"v-slide-group__container",onScroll:C},[h("div",{ref:g,class:"v-slide-group__content",onFocusin:k,onFocusout:x,onKeydown:A},[(Z=n.default)==null?void 0:Z.call(n,H.value)])]),G.value&&h("div",{key:"next",class:["v-slide-group__next",{"v-slide-group__next--disabled":!B.value}],onMousedown:O,onClick:()=>B.value&&V("next")},[((q=n.next)==null?void 0:q.call(n,H.value))??h(Q_,null,{default:()=>[h(X,{icon:r.value?e.prevIcon:e.nextIcon},null)]})])]}})),{selected:o.selected,scrollTo:V,scrollOffset:l,focus:D,hasPrev:j,hasNext:B}}}),ZI=Symbol.for("vuetify:v-chip-group"),Dq=de({column:Boolean,filter:Boolean,valueComparator:{type:Function,default:Wo},...JI(),...Ve(),...Cd({selectedClass:"v-chip--selected"}),...bt(),...Dt(),...Fs({variant:"tonal"})},"VChipGroup"),np=xe()({name:"VChipGroup",props:Dq(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const{themeClasses:r}=Xt(e),{isSelected:s,select:i,next:o,prev:a,selected:l}=Cu(e,ZI);return Dr({VChip:{color:Te(e,"color"),disabled:Te(e,"disabled"),filter:Te(e,"filter"),variant:Te(e,"variant")}}),Ie(()=>{const u=K1.filterProps(e);return h(K1,me(u,{class:["v-chip-group",{"v-chip-group--column":e.column},r.value,e.class],style:e.style}),{default:()=>{var d;return[(d=n.default)==null?void 0:d.call(n,{isSelected:s,select:i,next:o,prev:a,selected:l.value})]}})}),{}}}),Lq=de({activeClass:String,appendAvatar:String,appendIcon:Je,closable:Boolean,closeIcon:{type:Je,default:"$delete"},closeLabel:{type:String,default:"$vuetify.close"},draggable:Boolean,filter:Boolean,filterIcon:{type:String,default:"$complete"},label:Boolean,link:{type:Boolean,default:void 0},pill:Boolean,prependAvatar:String,prependIcon:Je,ripple:{type:[Boolean,Object],default:!0},text:String,modelValue:{type:Boolean,default:!0},onClick:zn(),onClickOnce:zn(),...vs(),...Ve(),...Lr(),...bs(),...Pd(),...Bn(),...Hp(),...Pu(),...bt({tag:"span"}),...Dt(),...Fs({variant:"tonal"})},"VChip"),kn=xe()({name:"VChip",directives:{Ripple:Iu},props:Lq(),emits:{"click:close":e=>!0,"update:modelValue":e=>!0,"group:selected":e=>!0,click:e=>!0},setup(e,t){let{attrs:n,emit:r,slots:s}=t;const{t:i}=es(),{borderClasses:o}=Ls(e),{colorClasses:a,colorStyles:l,variantClasses:u}=el(e),{densityClasses:d}=ys(e),{elevationClasses:c}=$s(e),{roundedClasses:f}=qn(e),{sizeClasses:p}=Rd(e),{themeClasses:g}=Xt(e),m=st(e,"modelValue"),y=Td(e,ZI,!1),b=Up(e,n),w=R(()=>e.link!==!1&&b.isLink.value),S=R(()=>!e.disabled&&e.link!==!1&&(!!y||e.link||b.isClickable.value)),P=R(()=>({"aria-label":i(e.closeLabel),onClick(C){C.preventDefault(),C.stopPropagation(),m.value=!1,r("click:close",C)}}));function E(C){var k;r("click",C),S.value&&((k=b.navigate)==null||k.call(b,C),y==null||y.toggle())}function T(C){(C.key==="Enter"||C.key===" ")&&(C.preventDefault(),E(C))}return()=>{const C=b.isLink.value?"a":e.tag,k=!!(e.appendIcon||e.appendAvatar),x=!!(k||s.append),I=!!(s.close||e.closable),M=!!(s.filter||e.filter)&&y,O=!!(e.prependIcon||e.prependAvatar),A=!!(O||s.prepend),D=!y||y.isSelected.value;return m.value&&en(h(C,me({class:["v-chip",{"v-chip--disabled":e.disabled,"v-chip--label":e.label,"v-chip--link":S.value,"v-chip--filter":M,"v-chip--pill":e.pill},g.value,o.value,D?a.value:void 0,d.value,c.value,f.value,p.value,u.value,y==null?void 0:y.selectedClass.value,e.class],style:[D?l.value:void 0,e.style],disabled:e.disabled||void 0,draggable:e.draggable,tabindex:S.value?0:void 0,onClick:E,onKeydown:S.value&&!w.value&&T},b.linkProps),{default:()=>{var V;return[Go(S.value,"v-chip"),M&&h(JP,{key:"filter"},{default:()=>[en(h("div",{class:"v-chip__filter"},[s.filter?h(At,{key:"filter-defaults",disabled:!e.filterIcon,defaults:{VIcon:{icon:e.filterIcon}}},s.filter):h(X,{key:"filter-icon",icon:e.filterIcon},null)]),[[qo,y.isSelected.value]])]}),A&&h("div",{key:"prepend",class:"v-chip__prepend"},[s.prepend?h(At,{key:"prepend-defaults",disabled:!O,defaults:{VAvatar:{image:e.prependAvatar,start:!0},VIcon:{icon:e.prependIcon,start:!0}}},s.prepend):h(Re,null,[e.prependIcon&&h(X,{key:"prepend-icon",icon:e.prependIcon,start:!0},null),e.prependAvatar&&h(lt,{key:"prepend-avatar",image:e.prependAvatar,start:!0},null)])]),h("div",{class:"v-chip__content","data-no-activator":""},[((V=s.default)==null?void 0:V.call(s,{isSelected:y==null?void 0:y.isSelected.value,selectedClass:y==null?void 0:y.selectedClass.value,select:y==null?void 0:y.select,toggle:y==null?void 0:y.toggle,value:y==null?void 0:y.value.value,disabled:e.disabled}))??e.text]),x&&h("div",{key:"append",class:"v-chip__append"},[s.append?h(At,{key:"append-defaults",disabled:!k,defaults:{VAvatar:{end:!0,image:e.appendAvatar},VIcon:{end:!0,icon:e.appendIcon}}},s.append):h(Re,null,[e.appendIcon&&h(X,{key:"append-icon",end:!0,icon:e.appendIcon},null),e.appendAvatar&&h(lt,{key:"append-avatar",end:!0,image:e.appendAvatar},null)])]),I&&h("button",me({key:"close",class:"v-chip__close",type:"button","data-testid":"close-chip"},P.value),[s.close?h(At,{key:"close-defaults",defaults:{VIcon:{icon:e.closeIcon,size:"x-small"}}},s.close):h(X,{key:"close-icon",icon:e.closeIcon,size:"x-small"},null)])]}}),[[mr("ripple"),S.value&&e.ripple,null]])}}}),$q=de({fluid:{type:Boolean,default:!1},...Ve(),...$r(),...bt()},"VContainer"),Pn=xe()({name:"VContainer",props:$q(),setup(e,t){let{slots:n}=t;const{rtlClasses:r}=Nr(),{dimensionStyles:s}=Fr(e);return Ie(()=>h(e.tag,{class:["v-container",{"v-container--fluid":e.fluid},r.value,e.class],style:[s.value,e.style]},n)),{}}}),eA=zp.reduce((e,t)=>(e[t]={type:[Boolean,String,Number],default:!1},e),{}),tA=zp.reduce((e,t)=>{const n="offset"+hi(t);return e[n]={type:[String,Number],default:null},e},{}),nA=zp.reduce((e,t)=>{const n="order"+hi(t);return e[n]={type:[String,Number],default:null},e},{}),Y1={col:Object.keys(eA),offset:Object.keys(tA),order:Object.keys(nA)};function Fq(e,t,n){let r=e;if(!(n==null||n===!1)){if(t){const s=t.replace(e,"");r+=`-${s}`}return e==="col"&&(r="v-"+r),e==="col"&&(n===""||n===!0)||(r+=`-${n}`),r.toLowerCase()}}const Nq=["auto","start","end","center","baseline","stretch"],Bq=de({cols:{type:[Boolean,String,Number],default:!1},...eA,offset:{type:[String,Number],default:null},...tA,order:{type:[String,Number],default:null},...nA,alignSelf:{type:String,default:null,validator:e=>Nq.includes(e)},...Ve(),...bt()},"VCol"),Ue=xe()({name:"VCol",props:Bq(),setup(e,t){let{slots:n}=t;const r=R(()=>{const s=[];let i;for(i in Y1)Y1[i].forEach(a=>{const l=e[a],u=Fq(i,a,l);u&&s.push(u)});const o=s.some(a=>a.startsWith("v-col-"));return s.push({"v-col":!o||!e.cols,[`v-col-${e.cols}`]:e.cols,[`offset-${e.offset}`]:e.offset,[`order-${e.order}`]:e.order,[`align-self-${e.alignSelf}`]:e.alignSelf}),s});return()=>{var s;return Mr(e.tag,{class:[r.value,e.class],style:e.style},(s=n.default)==null?void 0:s.call(n))}}}),Ew=["start","end","center"],rA=["space-between","space-around","space-evenly"];function Cw(e,t){return zp.reduce((n,r)=>{const s=e+hi(r);return n[s]=t(),n},{})}const Vq=[...Ew,"baseline","stretch"],sA=e=>Vq.includes(e),iA=Cw("align",()=>({type:String,default:null,validator:sA})),Uq=[...Ew,...rA],oA=e=>Uq.includes(e),aA=Cw("justify",()=>({type:String,default:null,validator:oA})),Hq=[...Ew,...rA,"stretch"],lA=e=>Hq.includes(e),uA=Cw("alignContent",()=>({type:String,default:null,validator:lA})),X1={align:Object.keys(iA),justify:Object.keys(aA),alignContent:Object.keys(uA)},zq={align:"align",justify:"justify",alignContent:"align-content"};function jq(e,t,n){let r=zq[e];if(n!=null){if(t){const s=t.replace(e,"");r+=`-${s}`}return r+=`-${n}`,r.toLowerCase()}}const qq=de({dense:Boolean,noGutters:Boolean,align:{type:String,default:null,validator:sA},...iA,justify:{type:String,default:null,validator:oA},...aA,alignContent:{type:String,default:null,validator:lA},...uA,...Ve(),...bt()},"VRow"),at=xe()({name:"VRow",props:qq(),setup(e,t){let{slots:n}=t;const r=R(()=>{const s=[];let i;for(i in X1)X1[i].forEach(o=>{const a=e[o],l=jq(i,o,a);l&&s.push(l)});return s.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}),s});return()=>{var s;return Mr(e.tag,{class:["v-row",r.value,e.class],style:e.style},(s=n.default)==null?void 0:s.call(n))}}}),wn=Eu("v-spacer","div","VSpacer"),Wq=Le({__name:"PrinterControlDialog",setup(e){const t=Fn(Jt.PrinterControlDialog),n=Nt(),r=rr(),s=R(()=>{var c;return(c=t.context())==null?void 0:c.printerId}),i=R(()=>{if(s.value)return n.printer(s.value)}),o=U(10),a=R(()=>{var f,p,g,m,y,b,w,S,P,E;const c=r.printerEventsById[s.value];return(g=(p=(f=c==null?void 0:c.current)==null?void 0:f.payload)==null?void 0:p.temps)!=null&&g.length&&((w=(b=(y=(m=c==null?void 0:c.current)==null?void 0:m.payload)==null?void 0:y.temps[0])==null?void 0:b.tool0)!=null&&w.actual)?(E=(P=(S=c==null?void 0:c.current)==null?void 0:S.payload)==null?void 0:P.temps[0])==null?void 0:E.tool0:null}),l=async(c,f,p)=>{await Wt.sendPrinterJogCommand(s.value,{x:c*o.value,y:f*o.value,z:p*o.value})},u=async c=>{await Wt.sendPrinterHomeCommand(s.value,c)},d=()=>{t.closeDialog()};return(c,f)=>{const p=gi;return $(),Q(p,{id:ie(t).dialogId,"max-width":"700px",onEscape:f[14]||(f[14]=g=>d())},{default:v(()=>[h(yt,null,{default:v(()=>[h(an,null,{default:v(()=>f[15]||(f[15]=[_(" Printer Controls ")])),_:1}),h(nn,null,{default:v(()=>[i.value?($(),Q(Pn,{key:0},{default:v(()=>[h(at,null,{default:v(()=>[h(Ue,{cols:12},{default:v(()=>{var g;return[_(" Printer: "+ae((g=i.value)==null?void 0:g.name)+" ",1),f[16]||(f[16]=L("br",null,null,-1)),h(kn,{color:"primary"},{default:v(()=>{var m,y;return[_(ae((m=a.value)==null?void 0:m.actual)+"C / "+ae((y=a.value)==null?void 0:y.target)+"C ",1)]}),_:1})]}),_:1})]),_:1}),h(at,null,{default:v(()=>[h(Ue,{cols:8},{default:v(()=>[f[26]||(f[26]=_(" X/Y ")),f[27]||(f[27]=L("br",null,null,-1)),h(re,{class:"bg-primary",variant:"outlined",size:"x-large",onClick:f[0]||(f[0]=g=>l(-1,1,0))},{default:v(()=>[h(X,null,{default:v(()=>f[17]||(f[17]=[_("north_west")])),_:1})]),_:1}),h(re,{class:"bg-primary",variant:"outlined",size:"x-large",onClick:f[1]||(f[1]=g=>l(0,1,0))},{default:v(()=>[h(X,null,{default:v(()=>f[18]||(f[18]=[_("north")])),_:1})]),_:1}),h(re,{class:"bg-primary",variant:"outlined",size:"x-large",onClick:f[2]||(f[2]=g=>l(1,1,0))},{default:v(()=>[h(X,null,{default:v(()=>f[19]||(f[19]=[_("north_east")])),_:1})]),_:1}),f[28]||(f[28]=L("br",null,null,-1)),h(re,{class:"bg-primary",variant:"outlined",size:"x-large",onClick:f[3]||(f[3]=g=>l(-1,0,0))},{default:v(()=>[h(X,null,{default:v(()=>f[20]||(f[20]=[_("west")])),_:1})]),_:1}),h(re,{class:"bg-primary",variant:"outlined",size:"x-large",onClick:f[4]||(f[4]=g=>u(["x","y"]))},{default:v(()=>[h(X,null,{default:v(()=>f[21]||(f[21]=[_("home")])),_:1})]),_:1}),h(re,{class:"bg-primary",variant:"outlined",size:"x-large",onClick:f[5]||(f[5]=g=>l(1,0,0))},{default:v(()=>[h(X,null,{default:v(()=>f[22]||(f[22]=[_("east")])),_:1})]),_:1}),f[29]||(f[29]=L("br",null,null,-1)),h(re,{class:"bg-primary",variant:"outlined",size:"x-large",onClick:f[6]||(f[6]=g=>l(-1,-1,0))},{default:v(()=>[h(X,null,{default:v(()=>f[23]||(f[23]=[_("south_west")])),_:1})]),_:1}),h(re,{class:"bg-primary",variant:"outlined",size:"x-large",onClick:f[7]||(f[7]=g=>l(0,-1,0))},{default:v(()=>[h(X,null,{default:v(()=>f[24]||(f[24]=[_("south")])),_:1})]),_:1}),h(re,{class:"bg-primary",variant:"outlined",size:"x-large",onClick:f[8]||(f[8]=g=>l(1,-1,0))},{default:v(()=>[h(X,null,{default:v(()=>f[25]||(f[25]=[_("south_east")])),_:1})]),_:1})]),_:1}),h(Ue,{cols:"4"},{default:v(()=>[f[33]||(f[33]=_(" Z ")),f[34]||(f[34]=L("br",null,null,-1)),h(re,{class:"bg-primary",variant:"outlined",size:"x-large",onClick:f[9]||(f[9]=g=>l(0,0,1))},{default:v(()=>[h(X,null,{default:v(()=>f[30]||(f[30]=[_("north")])),_:1})]),_:1}),f[35]||(f[35]=L("br",null,null,-1)),h(re,{class:"bg-primary",variant:"outlined",size:"x-large",onClick:f[10]||(f[10]=g=>u(["z"]))},{default:v(()=>[h(X,null,{default:v(()=>f[31]||(f[31]=[_("home")])),_:1})]),_:1}),f[36]||(f[36]=L("br",null,null,-1)),h(re,{class:"bg-primary",variant:"outlined",size:"x-large",onClick:f[11]||(f[11]=g=>l(1,0,1))},{default:v(()=>[h(X,null,{default:v(()=>f[32]||(f[32]=[_("south")])),_:1})]),_:1})]),_:1})]),_:1}),h(at,null,{default:v(()=>[h(Ue,{cols:"12"},{default:v(()=>[h(AP,{modelValue:o.value,"onUpdate:modelValue":f[12]||(f[12]=g=>o.value=g)},{default:v(()=>[h(re,{value:.1},{default:v(()=>f[37]||(f[37]=[_(" 0.1 ")])),_:1}),h(re,{value:1},{default:v(()=>f[38]||(f[38]=[_(" 1 ")])),_:1}),h(re,{value:10},{default:v(()=>f[39]||(f[39]=[_(" 10 ")])),_:1}),h(re,{value:100},{default:v(()=>f[40]||(f[40]=[_(" 100 ")])),_:1})]),_:1},8,["modelValue"])]),_:1})]),_:1})]),_:1})):ve("",!0)]),_:1}),h(Nn,null,{default:v(()=>[h(wn),h(re,{variant:"text",onClick:f[13]||(f[13]=g=>d())},{default:v(()=>f[41]||(f[41]=[_(" Close ")])),_:1})]),_:1})]),_:1})]),_:1},8,["id"])}}});class Ml extends yr{static async batchSettingsGet(t){return await this.post("/api/batch/settings/get",{printerIds:t})}static async batchConnectUsb(t){return await this.post("/api/batch/connect/usb",{printerIds:t})}static async batchConnectSocket(t){return await this.post("/api/batch/connect/socket",{printerIds:t})}static async batchToggleEnabled(t,n){return await this.post("/api/batch/toggle-enabled",{printerIds:t,enabled:n})}static async batchGetLastPrintedFiles(t){const n=Oe.batchGetLastPrintedFilesRoute;return await this.post(n,{printerIds:t})}static async batchReprintFiles(t){const n=Oe.batchReprintFilesRoute;return await this.post(n,{prints:t})}}var ha=(e=>(e[e.PrinterNotAvailable=0]="PrinterNotAvailable",e[e.NoLastPrint=1]="NoLastPrint",e[e.LastPrintReady=2]="LastPrintReady",e))(ha||{});function Gq(e){return e.message?`${e.message}
63
+ ${e.stack}`:`'${e}'`}const Kq=Eu("v-alert-title"),Yq=["success","info","warning","error"],Xq=de({border:{type:[Boolean,String],validator:e=>typeof e=="boolean"||["top","end","bottom","start"].includes(e)},borderColor:String,closable:Boolean,closeIcon:{type:Je,default:"$close"},closeLabel:{type:String,default:"$vuetify.close"},icon:{type:[Boolean,String,Function,Object],default:null},modelValue:{type:Boolean,default:!0},prominent:Boolean,title:String,text:String,type:{type:String,validator:e=>Yq.includes(e)},...Ve(),...Lr(),...$r(),...bs(),...Ko(),...Tu(),...Bn(),...bt(),...Dt(),...Fs({variant:"flat"})},"VAlert"),un=xe()({name:"VAlert",props:Xq(),emits:{"click:close":e=>!0,"update:modelValue":e=>!0},setup(e,t){let{emit:n,slots:r}=t;const s=st(e,"modelValue"),i=R(()=>{if(e.icon!==!1)return e.type?e.icon??`$${e.type}`:e.icon}),o=R(()=>({color:e.color??e.type,variant:e.variant})),{themeClasses:a}=Xt(e),{colorClasses:l,colorStyles:u,variantClasses:d}=el(o),{densityClasses:c}=ys(e),{dimensionStyles:f}=Fr(e),{elevationClasses:p}=$s(e),{locationStyles:g}=tl(e),{positionClasses:m}=Ru(e),{roundedClasses:y}=qn(e),{textColorClasses:b,textColorStyles:w}=Is(Te(e,"borderColor")),{t:S}=es(),P=R(()=>({"aria-label":S(e.closeLabel),onClick(E){s.value=!1,n("click:close",E)}}));return()=>{const E=!!(r.prepend||i.value),T=!!(r.title||e.title),C=!!(r.close||e.closable);return s.value&&h(e.tag,{class:["v-alert",e.border&&{"v-alert--border":!!e.border,[`v-alert--border-${e.border===!0?"start":e.border}`]:!0},{"v-alert--prominent":e.prominent},a.value,l.value,c.value,p.value,m.value,y.value,d.value,e.class],style:[u.value,f.value,g.value,e.style],role:"alert"},{default:()=>{var k,x;return[Go(!1,"v-alert"),e.border&&h("div",{key:"border",class:["v-alert__border",b.value],style:w.value},null),E&&h("div",{key:"prepend",class:"v-alert__prepend"},[r.prepend?h(At,{key:"prepend-defaults",disabled:!i.value,defaults:{VIcon:{density:e.density,icon:i.value,size:e.prominent?44:28}}},r.prepend):h(X,{key:"prepend-icon",density:e.density,icon:i.value,size:e.prominent?44:28},null)]),h("div",{class:"v-alert__content"},[T&&h(Kq,{key:"title"},{default:()=>{var I;return[((I=r.title)==null?void 0:I.call(r))??e.title]}}),((k=r.text)==null?void 0:k.call(r))??e.text,(x=r.default)==null?void 0:x.call(r)]),r.append&&h("div",{key:"append",class:"v-alert__append"},[r.append()]),C&&h("div",{key:"close",class:"v-alert__close"},[r.close?h(At,{key:"close-defaults",defaults:{VBtn:{icon:e.closeIcon,size:"x-small",variant:"text"}}},{default:()=>{var I;return[(I=r.close)==null?void 0:I.call(r,{props:P.value})]}}):h(re,me({key:"close-btn",icon:e.closeIcon,size:"x-small",variant:"text"},P.value),null)])]}})}}}),gy=Symbol.for("vuetify:list");function cA(){const e=Ye(gy,{hasPrepend:Me(!1),updateHasPrepend:()=>null}),t={hasPrepend:Me(!1),updateHasPrepend:n=>{n&&(t.hasPrepend.value=n)}};return Gt(gy,t),e}function dA(){return Ye(gy,null)}const Pw=e=>{const t={activate:n=>{let{id:r,value:s,activated:i}=n;return r=Be(r),e&&!s&&i.size===1&&i.has(r)||(s?i.add(r):i.delete(r)),i},in:(n,r,s)=>{let i=new Set;if(n!=null)for(const o of Dn(n))i=t.activate({id:o,value:!0,activated:new Set(i),children:r,parents:s});return i},out:n=>Array.from(n)};return t},fA=e=>{const t=Pw(e);return{activate:r=>{let{activated:s,id:i,...o}=r;i=Be(i);const a=s.has(i)?new Set([i]):new Set;return t.activate({...o,id:i,activated:a})},in:(r,s,i)=>{let o=new Set;if(r!=null){const a=Dn(r);a.length&&(o=t.in(a.slice(0,1),s,i))}return o},out:(r,s,i)=>t.out(r,s,i)}},Qq=e=>{const t=Pw(e);return{activate:r=>{let{id:s,activated:i,children:o,...a}=r;return s=Be(s),o.has(s)?i:t.activate({id:s,activated:i,children:o,...a})},in:t.in,out:t.out}},Jq=e=>{const t=fA(e);return{activate:r=>{let{id:s,activated:i,children:o,...a}=r;return s=Be(s),o.has(s)?i:t.activate({id:s,activated:i,children:o,...a})},in:t.in,out:t.out}},Zq={open:e=>{let{id:t,value:n,opened:r,parents:s}=e;if(n){const i=new Set;i.add(t);let o=s.get(t);for(;o!=null;)i.add(o),o=s.get(o);return i}else return r.delete(t),r},select:()=>null},hA={open:e=>{let{id:t,value:n,opened:r,parents:s}=e;if(n){let i=s.get(t);for(r.add(t);i!=null&&i!==t;)r.add(i),i=s.get(i);return r}else r.delete(t);return r},select:()=>null},eW={open:hA.open,select:e=>{let{id:t,value:n,opened:r,parents:s}=e;if(!n)return r;const i=[];let o=s.get(t);for(;o!=null;)i.push(o),o=s.get(o);return new Set(i)}},Tw=e=>{const t={select:n=>{let{id:r,value:s,selected:i}=n;if(r=Be(r),e&&!s){const o=Array.from(i.entries()).reduce((a,l)=>{let[u,d]=l;return d==="on"&&a.push(u),a},[]);if(o.length===1&&o[0]===r)return i}return i.set(r,s?"on":"off"),i},in:(n,r,s)=>{let i=new Map;for(const o of n||[])i=t.select({id:o,value:!0,selected:new Map(i),children:r,parents:s});return i},out:n=>{const r=[];for(const[s,i]of n.entries())i==="on"&&r.push(s);return r}};return t},pA=e=>{const t=Tw(e);return{select:r=>{let{selected:s,id:i,...o}=r;i=Be(i);const a=s.has(i)?new Map([[i,s.get(i)]]):new Map;return t.select({...o,id:i,selected:a})},in:(r,s,i)=>{let o=new Map;return r!=null&&r.length&&(o=t.in(r.slice(0,1),s,i)),o},out:(r,s,i)=>t.out(r,s,i)}},tW=e=>{const t=Tw(e);return{select:r=>{let{id:s,selected:i,children:o,...a}=r;return s=Be(s),o.has(s)?i:t.select({id:s,selected:i,children:o,...a})},in:t.in,out:t.out}},nW=e=>{const t=pA(e);return{select:r=>{let{id:s,selected:i,children:o,...a}=r;return s=Be(s),o.has(s)?i:t.select({id:s,selected:i,children:o,...a})},in:t.in,out:t.out}},rW=e=>{const t={select:n=>{let{id:r,value:s,selected:i,children:o,parents:a}=n;r=Be(r);const l=new Map(i),u=[r];for(;u.length;){const c=u.shift();i.set(Be(c),s?"on":"off"),o.has(c)&&u.push(...o.get(c))}let d=Be(a.get(r));for(;d;){const c=o.get(d),f=c.every(g=>i.get(Be(g))==="on"),p=c.every(g=>!i.has(Be(g))||i.get(Be(g))==="off");i.set(d,f?"on":p?"off":"indeterminate"),d=Be(a.get(d))}return e&&!s&&Array.from(i.entries()).reduce((f,p)=>{let[g,m]=p;return m==="on"&&f.push(g),f},[]).length===0?l:i},in:(n,r,s)=>{let i=new Map;for(const o of n||[])i=t.select({id:o,value:!0,selected:new Map(i),children:r,parents:s});return i},out:(n,r)=>{const s=[];for(const[i,o]of n.entries())o==="on"&&!r.has(i)&&s.push(i);return s}};return t},rd=Symbol.for("vuetify:nested"),mA={id:Me(),root:{register:()=>null,unregister:()=>null,parents:U(new Map),children:U(new Map),open:()=>null,openOnSelect:()=>null,activate:()=>null,select:()=>null,activatable:U(!1),selectable:U(!1),opened:U(new Set),activated:U(new Set),selected:U(new Map),selectedValues:U([]),getPath:()=>[]}},sW=de({activatable:Boolean,selectable:Boolean,activeStrategy:[String,Function,Object],selectStrategy:[String,Function,Object],openStrategy:[String,Object],opened:null,activated:null,selected:null,mandatory:Boolean},"nested"),iW=e=>{let t=!1;const n=U(new Map),r=U(new Map),s=st(e,"opened",e.opened,g=>new Set(g),g=>[...g.values()]),i=R(()=>{if(typeof e.activeStrategy=="object")return e.activeStrategy;if(typeof e.activeStrategy=="function")return e.activeStrategy(e.mandatory);switch(e.activeStrategy){case"leaf":return Qq(e.mandatory);case"single-leaf":return Jq(e.mandatory);case"independent":return Pw(e.mandatory);case"single-independent":default:return fA(e.mandatory)}}),o=R(()=>{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 nW(e.mandatory);case"leaf":return tW(e.mandatory);case"independent":return Tw(e.mandatory);case"single-independent":return pA(e.mandatory);case"classic":default:return rW(e.mandatory)}}),a=R(()=>{if(typeof e.openStrategy=="object")return e.openStrategy;switch(e.openStrategy){case"list":return eW;case"single":return Zq;case"multiple":default:return hA}}),l=st(e,"activated",e.activated,g=>i.value.in(g,n.value,r.value),g=>i.value.out(g,n.value,r.value)),u=st(e,"selected",e.selected,g=>o.value.in(g,n.value,r.value),g=>o.value.out(g,n.value,r.value));Tn(()=>{t=!0});function d(g){const m=[];let y=g;for(;y!=null;)m.unshift(y),y=r.value.get(y);return m}const c=sn("nested"),f=new Set,p={id:Me(),root:{opened:s,activatable:Te(e,"activatable"),selectable:Te(e,"selectable"),activated:l,selected:u,selectedValues:R(()=>{const g=[];for(const[m,y]of u.value.entries())y==="on"&&g.push(m);return g}),register:(g,m,y)=>{if(f.has(g)){d(g).map(String).join(" -> "),d(m).concat(g).map(String).join(" -> ");return}else f.add(g);m&&g!==m&&r.value.set(g,m),y&&n.value.set(g,[]),m!=null&&n.value.set(m,[...n.value.get(m)||[],g])},unregister:g=>{if(t)return;f.delete(g),n.value.delete(g);const m=r.value.get(g);if(m){const y=n.value.get(m)??[];n.value.set(m,y.filter(b=>b!==g))}r.value.delete(g)},open:(g,m,y)=>{c.emit("click:open",{id:g,value:m,path:d(g),event:y});const b=a.value.open({id:g,value:m,opened:new Set(s.value),children:n.value,parents:r.value,event:y});b&&(s.value=b)},openOnSelect:(g,m,y)=>{const b=a.value.select({id:g,value:m,selected:new Map(u.value),opened:new Set(s.value),children:n.value,parents:r.value,event:y});b&&(s.value=b)},select:(g,m,y)=>{c.emit("click:select",{id:g,value:m,path:d(g),event:y});const b=o.value.select({id:g,value:m,selected:new Map(u.value),children:n.value,parents:r.value,event:y});b&&(u.value=b),p.root.openOnSelect(g,m,y)},activate:(g,m,y)=>{if(!e.activatable)return p.root.select(g,!0,y);c.emit("click:activate",{id:g,value:m,path:d(g),event:y});const b=i.value.activate({id:g,value:m,activated:new Set(l.value),children:n.value,parents:r.value,event:y});b&&(l.value=b)},children:n,parents:r,getPath:d}};return Gt(rd,p),p.root},gA=(e,t)=>{const n=Ye(rd,mA),r=Symbol(vr()),s=R(()=>e.value!==void 0?e.value:r),i={...n,id:s,open:(o,a)=>n.root.open(s.value,o,a),openOnSelect:(o,a)=>n.root.openOnSelect(s.value,o,a),isOpen:R(()=>n.root.opened.value.has(s.value)),parent:R(()=>n.root.parents.value.get(s.value)),activate:(o,a)=>n.root.activate(s.value,o,a),isActivated:R(()=>n.root.activated.value.has(Be(s.value))),select:(o,a)=>n.root.select(s.value,o,a),isSelected:R(()=>n.root.selected.value.get(Be(s.value))==="on"),isIndeterminate:R(()=>n.root.selected.value.get(s.value)==="indeterminate"),isLeaf:R(()=>!n.root.children.value.get(s.value)),isGroupActivator:n.isGroupActivator};return!n.isGroupActivator&&n.root.register(s.value,n.id.value,t),Tn(()=>{!n.isGroupActivator&&n.root.unregister(s.value)}),t&&Gt(rd,i),i},oW=()=>{const e=Ye(rd,mA);Gt(rd,{...e,isGroupActivator:!0})};function qd(){const e=Me(!1);return St(()=>{window.requestAnimationFrame(()=>{e.value=!0})}),{ssrBootStyles:R(()=>e.value?void 0:{transition:"none !important"}),isBooted:Sd(e)}}const aW=xu({name:"VListGroupActivator",setup(e,t){let{slots:n}=t;return oW(),()=>{var r;return(r=n.default)==null?void 0:r.call(n)}}}),lW=de({activeColor:String,baseColor:String,color:String,collapseIcon:{type:Je,default:"$collapse"},expandIcon:{type:Je,default:"$expand"},prependIcon:Je,appendIcon:Je,fluid:Boolean,subgroup:Boolean,title:String,value:null,...Ve(),...bt()},"VListGroup"),vy=xe()({name:"VListGroup",props:lW(),setup(e,t){let{slots:n}=t;const{isOpen:r,open:s,id:i}=gA(Te(e,"value"),!0),o=R(()=>`v-list-group--id-${String(i.value)}`),a=dA(),{isBooted:l}=qd();function u(p){p.stopPropagation(),s(!r.value,p)}const d=R(()=>({onClick:u,class:"v-list-group__header",id:o.value})),c=R(()=>r.value?e.collapseIcon:e.expandIcon),f=R(()=>({VListItem:{active:r.value,activeColor:e.activeColor,baseColor:e.baseColor,color:e.color,prependIcon:e.prependIcon||e.subgroup&&c.value,appendIcon:e.appendIcon||!e.subgroup&&c.value,title:e.title,value:e.value}}));return Ie(()=>h(e.tag,{class:["v-list-group",{"v-list-group--prepend":a==null?void 0:a.hasPrepend.value,"v-list-group--fluid":e.fluid,"v-list-group--subgroup":e.subgroup,"v-list-group--open":r.value},e.class],style:e.style},{default:()=>[n.activator&&h(At,{defaults:f.value},{default:()=>[h(aW,null,{default:()=>[n.activator({props:d.value,isOpen:r.value})]})]}),h(ii,{transition:{component:QP},disabled:!l.value},{default:()=>{var p;return[en(h("div",{class:"v-list-group__items",role:"group","aria-labelledby":o.value},[(p=n.default)==null?void 0:p.call(n)]),[[qo,r.value]])]}})]})),{isOpen:r}}}),uW=de({opacity:[Number,String],...Ve(),...bt()},"VListItemSubtitle"),wt=xe()({name:"VListItemSubtitle",props:uW(),setup(e,t){let{slots:n}=t;return Ie(()=>h(e.tag,{class:["v-list-item-subtitle",e.class],style:[{"--v-list-item-subtitle-opacity":e.opacity},e.style]},n)),{}}}),ht=Eu("v-list-item-title"),cW=de({active:{type:Boolean,default:void 0},activeClass:String,activeColor:String,appendAvatar:String,appendIcon:Je,baseColor:String,disabled:Boolean,lines:[Boolean,String],link:{type:Boolean,default:void 0},nav:Boolean,prependAvatar:String,prependIcon:Je,ripple:{type:[Boolean,Object],default:!0},slim:Boolean,subtitle:[String,Number],title:[String,Number],value:null,onClick:zn(),onClickOnce:zn(),...vs(),...Ve(),...Lr(),...$r(),...bs(),...Bn(),...Hp(),...bt(),...Dt(),...Fs({variant:"text"})},"VListItem"),Fe=xe()({name:"VListItem",directives:{Ripple:Iu},props:cW(),emits:{click:e=>!0},setup(e,t){let{attrs:n,slots:r,emit:s}=t;const i=Up(e,n),o=R(()=>e.value===void 0?i.href.value:e.value),{activate:a,isActivated:l,select:u,isOpen:d,isSelected:c,isIndeterminate:f,isGroupActivator:p,root:g,parent:m,openOnSelect:y,id:b}=gA(o,!1),w=dA(),S=R(()=>{var q;return e.active!==!1&&(e.active||((q=i.isActive)==null?void 0:q.value)||(g.activatable.value?l.value:c.value))}),P=R(()=>e.link!==!1&&i.isLink.value),E=R(()=>!e.disabled&&e.link!==!1&&(e.link||i.isClickable.value||!!w&&(g.selectable.value||g.activatable.value||e.value!=null))),T=R(()=>e.rounded||e.nav),C=R(()=>e.color??e.activeColor),k=R(()=>({color:S.value?C.value??e.baseColor:e.baseColor,variant:e.variant}));Ce(()=>{var q;return(q=i.isActive)==null?void 0:q.value},q=>{q&&m.value!=null&&g.open(m.value,!0),q&&y(q)},{immediate:!0});const{themeClasses:x}=Xt(e),{borderClasses:I}=Ls(e),{colorClasses:M,colorStyles:O,variantClasses:A}=el(k),{densityClasses:D}=ys(e),{dimensionStyles:V}=Fr(e),{elevationClasses:H}=$s(e),{roundedClasses:G}=qn(T),j=R(()=>e.lines?`v-list-item--${e.lines}-line`:void 0),B=R(()=>({isActive:S.value,select:u,isOpen:d.value,isSelected:c.value,isIndeterminate:f.value}));function W(q){var K;s("click",q),E.value&&((K=i.navigate)==null||K.call(i,q),!p&&(g.activatable.value?a(!l.value,q):(g.selectable.value||e.value!=null)&&u(!c.value,q)))}function Z(q){(q.key==="Enter"||q.key===" ")&&(q.preventDefault(),q.target.dispatchEvent(new MouseEvent("click",q)))}return Ie(()=>{const q=P.value?"a":e.tag,K=r.title||e.title!=null,pe=r.subtitle||e.subtitle!=null,ue=!!(e.appendAvatar||e.appendIcon),le=!!(ue||r.append),J=!!(e.prependAvatar||e.prependIcon),be=!!(J||r.prepend);return w==null||w.updateHasPrepend(be),e.activeColor&&bF("active-color",["color","base-color"]),en(h(q,me({class:["v-list-item",{"v-list-item--active":S.value,"v-list-item--disabled":e.disabled,"v-list-item--link":E.value,"v-list-item--nav":e.nav,"v-list-item--prepend":!be&&(w==null?void 0:w.hasPrepend.value),"v-list-item--slim":e.slim,[`${e.activeClass}`]:e.activeClass&&S.value},x.value,I.value,M.value,D.value,H.value,j.value,G.value,A.value,e.class],style:[O.value,V.value,e.style],tabindex:E.value?w?-2:0:void 0,"aria-selected":g.activatable.value?l.value:c.value,onClick:W,onKeydown:E.value&&!P.value&&Z},i.linkProps),{default:()=>{var Se;return[Go(E.value||S.value,"v-list-item"),be&&h("div",{key:"prepend",class:"v-list-item__prepend"},[r.prepend?h(At,{key:"prepend-defaults",disabled:!J,defaults:{VAvatar:{density:e.density,image:e.prependAvatar},VIcon:{density:e.density,icon:e.prependIcon},VListItemAction:{start:!0}}},{default:()=>{var te;return[(te=r.prepend)==null?void 0:te.call(r,B.value)]}}):h(Re,null,[e.prependAvatar&&h(lt,{key:"prepend-avatar",density:e.density,image:e.prependAvatar},null),e.prependIcon&&h(X,{key:"prepend-icon",density:e.density,icon:e.prependIcon},null)]),h("div",{class:"v-list-item__spacer"},null)]),h("div",{class:"v-list-item__content","data-no-activator":""},[K&&h(ht,{key:"title"},{default:()=>{var te;return[((te=r.title)==null?void 0:te.call(r,{title:e.title}))??e.title]}}),pe&&h(wt,{key:"subtitle"},{default:()=>{var te;return[((te=r.subtitle)==null?void 0:te.call(r,{subtitle:e.subtitle}))??e.subtitle]}}),(Se=r.default)==null?void 0:Se.call(r,B.value)]),le&&h("div",{key:"append",class:"v-list-item__append"},[r.append?h(At,{key:"append-defaults",disabled:!ue,defaults:{VAvatar:{density:e.density,image:e.appendAvatar},VIcon:{density:e.density,icon:e.appendIcon},VListItemAction:{end:!0}}},{default:()=>{var te;return[(te=r.append)==null?void 0:te.call(r,B.value)]}}):h(Re,null,[e.appendIcon&&h(X,{key:"append-icon",density:e.density,icon:e.appendIcon},null),e.appendAvatar&&h(lt,{key:"append-avatar",density:e.density,image:e.appendAvatar},null)]),h("div",{class:"v-list-item__spacer"},null)])]}}),[[mr("ripple"),E.value&&e.ripple]])}),{activate:a,isActivated:l,isGroupActivator:p,isSelected:c,list:w,select:u,root:g,id:b}}}),dW=de({color:String,inset:Boolean,sticky:Boolean,title:String,...Ve(),...bt()},"VListSubheader"),hs=xe()({name:"VListSubheader",props:dW(),setup(e,t){let{slots:n}=t;const{textColorClasses:r,textColorStyles:s}=Is(Te(e,"color"));return Ie(()=>{const i=!!(n.default||e.title);return h(e.tag,{class:["v-list-subheader",{"v-list-subheader--inset":e.inset,"v-list-subheader--sticky":e.sticky},r.value,e.class],style:[{textColorStyles:s},e.style]},{default:()=>{var o;return[i&&h("div",{class:"v-list-subheader__text"},[((o=n.default)==null?void 0:o.call(n))??e.title])]}})}),{}}}),fW=de({color:String,inset:Boolean,length:[Number,String],opacity:[Number,String],thickness:[Number,String],vertical:Boolean,...Ve(),...Dt()},"VDivider"),yn=xe()({name:"VDivider",props:fW(),setup(e,t){let{attrs:n,slots:r}=t;const{themeClasses:s}=Xt(e),{textColorClasses:i,textColorStyles:o}=Is(Te(e,"color")),a=R(()=>{const l={};return e.length&&(l[e.vertical?"height":"width"]=Ne(e.length)),e.thickness&&(l[e.vertical?"borderRightWidth":"borderTopWidth"]=Ne(e.thickness)),l});return Ie(()=>{const l=h("hr",{class:[{"v-divider":!0,"v-divider--inset":e.inset,"v-divider--vertical":e.vertical},s.value,i.value,e.class],style:[a.value,o.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 r.default?h("div",{class:["v-divider__wrapper",{"v-divider__wrapper--vertical":e.vertical,"v-divider__wrapper--inset":e.inset}]},[l,h("div",{class:"v-divider__content"},[r.default()]),l]):l}),{}}}),hW=de({items:Array,returnObject:Boolean},"VListChildren"),vA=xe()({name:"VListChildren",props:hW(),setup(e,t){let{slots:n}=t;return cA(),()=>{var r,s;return((r=n.default)==null?void 0:r.call(n))??((s=e.items)==null?void 0:s.map(i=>{var f,p;let{children:o,props:a,type:l,raw:u}=i;if(l==="divider")return((f=n.divider)==null?void 0:f.call(n,{props:a}))??h(yn,a,null);if(l==="subheader")return((p=n.subheader)==null?void 0:p.call(n,{props:a}))??h(hs,a,null);const d={subtitle:n.subtitle?g=>{var m;return(m=n.subtitle)==null?void 0:m.call(n,{...g,item:u})}:void 0,prepend:n.prepend?g=>{var m;return(m=n.prepend)==null?void 0:m.call(n,{...g,item:u})}:void 0,append:n.append?g=>{var m;return(m=n.append)==null?void 0:m.call(n,{...g,item:u})}:void 0,title:n.title?g=>{var m;return(m=n.title)==null?void 0:m.call(n,{...g,item:u})}:void 0},c=vy.filterProps(a);return o?h(vy,me({value:a==null?void 0:a.value},c),{activator:g=>{let{props:m}=g;const y={...a,...m,value:e.returnObject?u:a.value};return n.header?n.header({props:y}):h(Fe,y,d)},default:()=>h(vA,{items:o,returnObject:e.returnObject},n)}):n.item?n.item({props:a}):h(Fe,me(a,{value:e.returnObject?u:a.value}),d)}))}}}),yA=de({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:{type:Function,default:Wo}},"list-items");function yy(e,t){const n=er(t,e.itemTitle,t),r=er(t,e.itemValue,n),s=er(t,e.itemChildren),i=e.itemProps===!0?typeof t=="object"&&t!=null&&!Array.isArray(t)?"children"in t?Ds(t,["children"]):t:void 0:er(t,e.itemProps),o={title:n,value:r,...i};return{title:String(o.title??""),value:o.value,props:o,children:Array.isArray(s)?bA(e,s):void 0,raw:t}}function bA(e,t){const n=[];for(const r of t)n.push(yy(e,r));return n}function pW(e){const t=R(()=>bA(e,e.items)),n=R(()=>t.value.some(i=>i.value===null));function r(i){return n.value||(i=i.filter(o=>o!==null)),i.map(o=>e.returnObject&&typeof o=="string"?yy(e,o):t.value.find(a=>e.valueComparator(o,a.value))||yy(e,o))}function s(i){return e.returnObject?i.map(o=>{let{raw:a}=o;return a}):i.map(o=>{let{value:a}=o;return a})}return{items:t,transformIn:r,transformOut:s}}function mW(e){return typeof e=="string"||typeof e=="number"||typeof e=="boolean"}function gW(e,t){const n=er(t,e.itemType,"item"),r=mW(t)?t:er(t,e.itemTitle),s=er(t,e.itemValue,void 0),i=er(t,e.itemChildren),o=e.itemProps===!0?Ds(t,["children"]):er(t,e.itemProps),a={title:r,value:s,...o};return{type:n,title:a.title,value:a.value,props:a,children:n==="item"&&i?wA(e,i):void 0,raw:t}}function wA(e,t){const n=[];for(const r of t)n.push(gW(e,r));return n}function vW(e){return{items:R(()=>wA(e,e.items))}}const yW=de({baseColor:String,activeColor:String,activeClass:String,bgColor:String,disabled:Boolean,expandIcon:String,collapseIcon:String,lines:{type:[Boolean,String],default:"one"},slim:Boolean,nav:Boolean,"onClick:open":zn(),"onClick:select":zn(),"onUpdate:opened":zn(),...sW({selectStrategy:"single-leaf",openStrategy:"list"}),...vs(),...Ve(),...Lr(),...$r(),...bs(),itemType:{type:String,default:"type"},...yA(),...Bn(),...bt(),...Dt(),...Fs({variant:"text"})},"VList"),Kt=xe()({name:"VList",props:yW(),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:r}=vW(e),{themeClasses:s}=Xt(e),{backgroundColorClasses:i,backgroundColorStyles:o}=pr(Te(e,"bgColor")),{borderClasses:a}=Ls(e),{densityClasses:l}=ys(e),{dimensionStyles:u}=Fr(e),{elevationClasses:d}=$s(e),{roundedClasses:c}=qn(e),{children:f,open:p,parents:g,select:m,getPath:y}=iW(e),b=R(()=>e.lines?`v-list--${e.lines}-line`:void 0),w=Te(e,"activeColor"),S=Te(e,"baseColor"),P=Te(e,"color");cA(),Dr({VListGroup:{activeColor:w,baseColor:S,color:P,expandIcon:Te(e,"expandIcon"),collapseIcon:Te(e,"collapseIcon")},VListItem:{activeClass:Te(e,"activeClass"),activeColor:w,baseColor:S,color:P,density:Te(e,"density"),disabled:Te(e,"disabled"),lines:Te(e,"lines"),nav:Te(e,"nav"),slim:Te(e,"slim"),variant:Te(e,"variant")}});const E=Me(!1),T=U();function C(A){E.value=!0}function k(A){E.value=!1}function x(A){var D;!E.value&&!(A.relatedTarget&&((D=T.value)!=null&&D.contains(A.relatedTarget)))&&O()}function I(A){const D=A.target;if(!(!T.value||["INPUT","TEXTAREA"].includes(D.tagName))){if(A.key==="ArrowDown")O("next");else if(A.key==="ArrowUp")O("prev");else if(A.key==="Home")O("first");else if(A.key==="End")O("last");else return;A.preventDefault()}}function M(A){E.value=!0}function O(A){if(T.value)return kc(T.value,A)}return Ie(()=>h(e.tag,{ref:T,class:["v-list",{"v-list--disabled":e.disabled,"v-list--nav":e.nav,"v-list--slim":e.slim},s.value,i.value,a.value,l.value,d.value,b.value,c.value,e.class],style:[o.value,u.value,e.style],tabindex:e.disabled||E.value?-1:0,role:"listbox","aria-activedescendant":void 0,onFocusin:C,onFocusout:k,onFocus:x,onKeydown:I,onMousedown:M},{default:()=>[h(vA,{items:r.value,returnObject:e.returnObject},n)]})),{open:p,select:m,focus:O,children:f,parents:g,getPath:y}}}),bW=de({start:Boolean,end:Boolean,...Ve(),...bt()},"VListItemAction"),sd=xe()({name:"VListItemAction",props:bW(),setup(e,t){let{slots:n}=t;return Ie(()=>h(e.tag,{class:["v-list-item-action",{"v-list-item-action--start":e.start,"v-list-item-action--end":e.end},e.class],style:e.style},n)),{}}}),wW=de({start:Boolean,end:Boolean,...Ve(),...bt()},"VListItemMedia"),SW=xe()({name:"VListItemMedia",props:wW(),setup(e,t){let{slots:n}=t;return Ie(()=>h(e.tag,{class:["v-list-item-media",{"v-list-item-media--start":e.start,"v-list-item-media--end":e.end},e.class],style:e.style},n)),{}}}),_W={key:1},kW={key:2},xW={class:"mt-3"},EW={key:0},CW={key:1},PW={key:2},TW=Le({__name:"BatchReprintDialog",setup(e){const t=Nt(),n=U(),r=Fn(Jt.BatchReprintDialog),s=U(!1),i=U(!1),o=U([]),a=U([]),l=U(""),u=Mt();function d(g){s.value=!0}async function c(g){n.value=g;try{const m=await Ml.batchGetLastPrintedFiles(n.value);o.value=m,a.value=m.filter(y=>y.connectionState==="Operational"&&y.reprintState==ha.LastPrintReady)}catch(m){l.value=m.code.toString()??""}s.value=!1}async function f(){i.value=!0;try{await Ml.batchReprintFiles(a.value.filter(g=>{var m;return(m=g.file)==null?void 0:m.path}).map(g=>{var m;return{printerId:g.printerId,path:((m=g.file)==null?void 0:m.path)||""}})),t.clearSelectedPrinters(),u.info("Action completed","Your reprinted jobs are starting",5e3),p()}catch(g){l.value=Gq(g)}finally{i.value=!1}}function p(){r.closeDialog(r.context())}return(g,m)=>{const y=gi;return $(),Q(y,{id:ie(r).dialogId,"max-width":"1000px",onBeforeOpened:d,onEscape:m[3]||(m[3]=b=>p()),onOpened:c},{default:v(()=>[h(yt,{class:"pa-4"},{default:v(()=>[h(an,null,{default:v(()=>m[4]||(m[4]=[L("span",{class:"text-h5"}," Batch - Submit Reprint Jobs ",-1)])),_:1}),h(nn,null,{default:v(()=>{var b;return[(b=l.value)!=null&&b.length?($(),Q(un,{key:0,color:"error"},{default:v(()=>[_(ae(l.value),1)]),_:1})):ve("",!0),s.value?($(),we("span",_W," Loading... ")):($(),we("div",kW,[h(Kt,{density:"compact"},{default:v(()=>[h(hs,null,{default:v(()=>m[5]||(m[5]=[_(" Reprinted Files - Select from list ")])),_:1}),h(vy,{modelValue:a.value,"onUpdate:modelValue":m[0]||(m[0]=w=>a.value=w),multiple:""},{default:v(()=>[($(!0),we(Re,null,Zt(o.value,(w,S)=>($(),Q(Fe,{key:S,value:w,disabled:w.connectionState!=="Operational"||w.reprintState!==ie(ha).LastPrintReady},{prepend:v(()=>[w.reprintState==ie(ha).LastPrintReady?($(),Q(X,{key:0},{default:v(()=>m[6]||(m[6]=[_("checklist")])),_:1})):ve("",!0),w.reprintState==ie(ha).NoLastPrint?($(),Q(X,{key:1},{default:v(()=>m[7]||(m[7]=[_(" question_mark ")])),_:1})):ve("",!0),w.reprintState==ie(ha).PrinterNotAvailable?($(),Q(X,{key:2},{default:v(()=>m[8]||(m[8]=[_(" signal_disconnected ")])),_:1})):ve("",!0)]),default:v(()=>{var P,E;return[(E=(P=w.file)==null?void 0:P.path)!=null&&E.length?($(),Q(ht,{key:0},{default:v(()=>{var T;return[_(ae((T=w.file)==null?void 0:T.path)+" ",1),w.connectionState!=="Operational"?($(),Q(kn,{key:0},{default:v(()=>m[9]||(m[9]=[_(" Printer busy ")])),_:1})):ve("",!0)]}),_:2},1024)):w.reprintState==ie(ha).NoLastPrint?($(),Q(ht,{key:1},{default:v(()=>m[10]||(m[10]=[_(" No file is present to print again ")])),_:1})):($(),Q(ht,{key:2},{default:v(()=>m[11]||(m[11]=[_(" OctoPrint cant be reached ")])),_:1})),h(wt,null,{default:v(()=>{var T;return[_(" Printer '"+ae(((T=ie(t).printer(w.printerId))==null?void 0:T.name)??"Unknown printer")+"' ",1)]}),_:2},1024)]}),_:2},1032,["value","disabled"]))),128))]),_:1},8,["modelValue"])]),_:1})])),L("div",xW,[i.value?($(),we("div",EW,[h(Id,{class:"ma-3",indeterminate:"",color:"blue"}),m[12]||(m[12]=_(" Submitting "))])):a.value.length>0?($(),we("div",CW,ae(a.value.length)+" reprint selected ",1)):($(),we("div",PW,"Must select at least one file"))]),m[14]||(m[14]=L("br",null,null,-1)),h(re,{disabled:i.value||a.value.length===0,onClick:m[1]||(m[1]=w=>f())},{default:v(()=>m[13]||(m[13]=[_(" Submit Batch Reprint ")])),_:1},8,["disabled"])]}),_:1}),h(Nn,null,{default:v(()=>[h(wn),h(re,{variant:"text",onClick:m[2]||(m[2]=b=>ie(r).closeDialog())},{default:v(()=>m[15]||(m[15]=[_(" Close ")])),_:1})]),_:1})]),_:1})]),_:1},8,["id"])}}}),RW="/img/octoprint-tentacle.svg";function SA(e,t=2){if(e===0)return"0 Bytes";const n=1024,r=t<0?0:t,s=["Bytes","KB","MB","GB","TB","PB","EB","ZB","YB"],i=Math.floor(Math.log(e)/Math.log(n));return parseFloat((e/Math.pow(n,i)).toFixed(r))+" "+s[i]}class ko extends yr{static async updateClientDistGithub(t,n){return await this.post("/api/server/update-client-bundle-github",{downloadRelease:t,allowDowngrade:n})}static async getGithubRateLimit(){return await this.get("/api/server/github-rate-limit")}static async getClientReleases(){return await this.get("/api/server/client-releases")}static async getVersion(){return await this.get("/api/version")}static async getFeatures(){return await this.get("/api/features")}static async test(){return await(await Xn(!1,!1)).get("/api/test")}}const Yi=Ms("Feature",{state:()=>({features:void 0}),getters:{getFeatures(){return this.features},getFeature:e=>t=>{if(!e.features){console.debug("Feature store not loaded");return}return e.features[t]},hasFeature:e=>t=>{if(!e.features)return console.debug("Feature store not loaded"),!1;const n=e.features[t];return n?n==null?void 0:n.available:(console.debug(`Feature ${t} not defined. Options:`,Object.keys(e.features)),!1)}},actions:{async loadFeatures(){try{const e=await ko.getFeatures();this.setFeatures(e)}catch{this.features={}}},setFeatures(e){this.features=e}}});function _A(e){return e===0}function kA(e){return e===1}function IW(e){return _A(e)?"OctoPrint":kA(e)?"Moonraker":"Unknown"}function AW(e){let{rootEl:t,isSticky:n,layoutItemStyles:r}=e;const s=Me(!1),i=Me(0),o=R(()=>{const u=typeof s.value=="boolean"?"top":s.value;return[n.value?{top:"auto",bottom:"auto",height:void 0}:void 0,s.value?{[u]:Ne(i.value)}:{top:r.value.top}]});St(()=>{Ce(n,u=>{u?window.addEventListener("scroll",l,{passive:!0}):window.removeEventListener("scroll",l)},{immediate:!0})}),Tn(()=>{window.removeEventListener("scroll",l)});let a=0;function l(){const u=a>window.scrollY?"up":"down",d=t.value.getBoundingClientRect(),c=parseFloat(r.value.top??0),f=window.scrollY-Math.max(0,i.value-c),p=d.height+Math.max(i.value,c)-window.scrollY-window.innerHeight,g=parseFloat(getComputedStyle(t.value).getPropertyValue("--v-body-scroll-y"))||0;d.height<window.innerHeight-c?(s.value="top",i.value=c):u==="up"&&s.value==="bottom"||u==="down"&&s.value==="top"?(i.value=window.scrollY+d.top-g,s.value=!0):u==="down"&&p<=0?(i.value=0,s.value="bottom"):u==="up"&&f<=0&&(g?s.value!=="top"&&(i.value=-f+g+c,s.value="top"):(i.value=d.top+f,s.value="top")),a=window.scrollY}return{isStuck:s,stickyStyles:o}}const OW=100,MW=20;function Q1(e){return(e<0?-1:1)*Math.sqrt(Math.abs(e))*1.41421356237}function J1(e){if(e.length<2)return 0;if(e.length===2)return e[1].t===e[0].t?0:(e[1].d-e[0].d)/(e[1].t-e[0].t);let t=0;for(let n=e.length-1;n>0;n--){if(e[n].t===e[n-1].t)continue;const r=Q1(t),s=(e[n].d-e[n-1].d)/(e[n].t-e[n-1].t);t+=(s-r)*Math.abs(s),n===e.length-1&&(t*=.5)}return Q1(t)*1e3}function DW(){const e={};function t(s){Array.from(s.changedTouches).forEach(i=>{(e[i.identifier]??(e[i.identifier]=new oF(MW))).push([s.timeStamp,i])})}function n(s){Array.from(s.changedTouches).forEach(i=>{delete e[i.identifier]})}function r(s){var u;const i=(u=e[s])==null?void 0:u.values().reverse();if(!i)throw new Error(`No samples for touch id ${s}`);const o=i[0],a=[],l=[];for(const d of i){if(o[0]-d[0]>OW)break;a.push({t:d[0],d:d[1].clientX}),l.push({t:d[0],d:d[1].clientY})}return{x:J1(a),y:J1(l),get direction(){const{x:d,y:c}=this,[f,p]=[Math.abs(d),Math.abs(c)];return f>p&&d>=0?"right":f>p&&d<=0?"left":p>f&&c>=0?"down":p>f&&c<=0?"up":LW()}}}return{addMovement:t,endTouch:n,getVelocity:r}}function LW(){throw new Error}function $W(e){let{el:t,isActive:n,isTemporary:r,width:s,touchless:i,position:o}=e;St(()=>{window.addEventListener("touchstart",w,{passive:!0}),window.addEventListener("touchmove",S,{passive:!1}),window.addEventListener("touchend",P,{passive:!0})}),Tn(()=>{window.removeEventListener("touchstart",w),window.removeEventListener("touchmove",S),window.removeEventListener("touchend",P)});const a=R(()=>["left","right"].includes(o.value)),{addMovement:l,endTouch:u,getVelocity:d}=DW();let c=!1;const f=Me(!1),p=Me(0),g=Me(0);let m;function y(T,C){return(o.value==="left"?T:o.value==="right"?document.documentElement.clientWidth-T:o.value==="top"?T:o.value==="bottom"?document.documentElement.clientHeight-T:ml())-(C?s.value:0)}function b(T){let C=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;const k=o.value==="left"?(T-g.value)/s.value:o.value==="right"?(document.documentElement.clientWidth-T-g.value)/s.value:o.value==="top"?(T-g.value)/s.value:o.value==="bottom"?(document.documentElement.clientHeight-T-g.value)/s.value:ml();return C?Math.max(0,Math.min(1,k)):k}function w(T){if(i.value)return;const C=T.changedTouches[0].clientX,k=T.changedTouches[0].clientY,x=25,I=o.value==="left"?C<x:o.value==="right"?C>document.documentElement.clientWidth-x:o.value==="top"?k<x:o.value==="bottom"?k>document.documentElement.clientHeight-x:ml(),M=n.value&&(o.value==="left"?C<s.value:o.value==="right"?C>document.documentElement.clientWidth-s.value:o.value==="top"?k<s.value:o.value==="bottom"?k>document.documentElement.clientHeight-s.value:ml());(I||M||n.value&&r.value)&&(m=[C,k],g.value=y(a.value?C:k,n.value),p.value=b(a.value?C:k),c=g.value>-20&&g.value<80,u(T),l(T))}function S(T){const C=T.changedTouches[0].clientX,k=T.changedTouches[0].clientY;if(c){if(!T.cancelable){c=!1;return}const I=Math.abs(C-m[0]),M=Math.abs(k-m[1]);(a.value?I>M&&I>3:M>I&&M>3)?(f.value=!0,c=!1):(a.value?M:I)>3&&(c=!1)}if(!f.value)return;T.preventDefault(),l(T);const x=b(a.value?C:k,!1);p.value=Math.max(0,Math.min(1,x)),x>1?g.value=y(a.value?C:k,!0):x<0&&(g.value=y(a.value?C:k,!1))}function P(T){if(c=!1,!f.value)return;l(T),f.value=!1;const C=d(T.changedTouches[0].identifier),k=Math.abs(C.x),x=Math.abs(C.y);(a.value?k>x&&k>400:x>k&&x>3)?n.value=C.direction===({left:"right",right:"left",top:"down",bottom:"up"}[o.value]||ml()):n.value=p.value>.5}const E=R(()=>f.value?{transform:o.value==="left"?`translateX(calc(-100% + ${p.value*s.value}px))`:o.value==="right"?`translateX(calc(100% - ${p.value*s.value}px))`:o.value==="top"?`translateY(calc(-100% + ${p.value*s.value}px))`:o.value==="bottom"?`translateY(calc(100% - ${p.value*s.value}px))`:ml(),transition:"none"}:void 0);return Qr(f,()=>{var k,x;const T=((k=t.value)==null?void 0:k.style.transform)??null,C=((x=t.value)==null?void 0:x.style.transition)??null;jn(()=>{var I,M,O,A;(M=t.value)==null||M.style.setProperty("transform",((I=E.value)==null?void 0:I.transform)||"none"),(A=t.value)==null||A.style.setProperty("transition",((O=E.value)==null?void 0:O.transition)||null)}),Sn(()=>{var I,M;(I=t.value)==null||I.style.setProperty("transform",T),(M=t.value)==null||M.style.setProperty("transition",C)})}),{isDragging:f,dragProgress:p,dragStyles:E}}function ml(){throw new Error}const pm={"001":1,AD:1,AE:6,AF:6,AG:0,AI:1,AL:1,AM:1,AN:1,AR:1,AS:0,AT:1,AU:1,AX:1,AZ:1,BA:1,BD:0,BE:1,BG:1,BH:6,BM:1,BN:1,BR:0,BS:0,BT:0,BW:0,BY:1,BZ:0,CA:0,CH:1,CL:1,CM:1,CN:1,CO:0,CR:1,CY:1,CZ:1,DE:1,DJ:6,DK:1,DM:0,DO:0,DZ:6,EC:1,EE:1,EG:6,ES:1,ET:0,FI:1,FJ:1,FO:1,FR:1,GB:1,"GB-alt-variant":0,GE:1,GF:1,GP:1,GR:1,GT:0,GU:0,HK:0,HN:0,HR:1,HU:1,ID:0,IE:1,IL:0,IN:0,IQ:6,IR:6,IS:1,IT:1,JM:0,JO:6,JP:0,KE:0,KG:1,KH:0,KR:0,KW:6,KZ:1,LA:0,LB:1,LI:1,LK:1,LT:1,LU:1,LV:1,LY:6,MC:1,MD:1,ME:1,MH:0,MK:1,MM:0,MN:1,MO:0,MQ:1,MT:0,MV:5,MX:0,MY:1,MZ:0,NI:0,NL:1,NO:1,NP:0,NZ:1,OM:6,PA:0,PE:0,PH:0,PK:0,PL:1,PR:0,PT:0,PY:0,QA:6,RE:1,RO:1,RS:1,RU:1,SA:0,SD:6,SE:1,SG:0,SI:1,SK:1,SM:1,SV:0,SY:6,TH:0,TJ:1,TM:1,TR:1,TT:0,TW:0,UA:1,UM:0,US:0,UY:1,UZ:1,VA:1,VE:0,VI:0,VN:1,WS:0,XK:1,YE:0,ZA:0,ZW:0};function FW(e,t,n){const r=[];let s=[];const i=xA(e),o=EA(e),a=n??pm[t.slice(-2).toUpperCase()]??0,l=(i.getDay()-a+7)%7,u=(o.getDay()-a+7)%7;for(let d=0;d<l;d++){const c=new Date(i);c.setDate(c.getDate()-(l-d)),s.push(c)}for(let d=1;d<=o.getDate();d++){const c=new Date(e.getFullYear(),e.getMonth(),d);s.push(c),s.length===7&&(r.push(s),s=[])}for(let d=1;d<7-u;d++){const c=new Date(o);c.setDate(c.getDate()+d),s.push(c)}return s.length>0&&r.push(s),r}function NW(e,t,n){const r=n??pm[t.slice(-2).toUpperCase()]??0,s=new Date(e);for(;s.getDay()!==r;)s.setDate(s.getDate()-1);return s}function BW(e,t){const n=new Date(e),r=((pm[t.slice(-2).toUpperCase()]??0)+6)%7;for(;n.getDay()!==r;)n.setDate(n.getDate()+1);return n}function xA(e){return new Date(e.getFullYear(),e.getMonth(),1)}function EA(e){return new Date(e.getFullYear(),e.getMonth()+1,0)}function VW(e){const t=e.split("-").map(Number);return new Date(t[0],t[1]-1,t[2])}const UW=/^([12]\d{3}-([1-9]|0[1-9]|1[0-2])-([1-9]|0[1-9]|[12]\d|3[01]))$/;function CA(e){if(e==null)return new Date;if(e instanceof Date)return e;if(typeof e=="string"){let t;if(UW.test(e))return VW(e);if(t=Date.parse(e),!isNaN(t))return new Date(t)}return null}const Z1=new Date(2e3,0,2);function HW(e,t){const n=t??pm[e.slice(-2).toUpperCase()]??0;return Cl(7).map(r=>{const s=new Date(Z1);return s.setDate(Z1.getDate()+n+r),new Intl.DateTimeFormat(e,{weekday:"narrow"}).format(s)})}function zW(e,t,n,r){const s=CA(e)??new Date,i=r==null?void 0:r[t];if(typeof i=="function")return i(s,t,n);let o={};switch(t){case"fullDate":o={year:"numeric",month:"long",day:"numeric"};break;case"fullDateWithWeekday":o={weekday:"long",year:"numeric",month:"long",day:"numeric"};break;case"normalDate":const a=s.getDate(),l=new Intl.DateTimeFormat(n,{month:"long"}).format(s);return`${a} ${l}`;case"normalDateWithWeekday":o={weekday:"short",day:"numeric",month:"short"};break;case"shortDate":o={month:"short",day:"numeric"};break;case"year":o={year:"numeric"};break;case"month":o={month:"long"};break;case"monthShort":o={month:"short"};break;case"monthAndYear":o={month:"long",year:"numeric"};break;case"monthAndDate":o={month:"long",day:"numeric"};break;case"weekday":o={weekday:"long"};break;case"weekdayShort":o={weekday:"short"};break;case"dayOfMonth":return new Intl.NumberFormat(n).format(s.getDate());case"hours12h":o={hour:"numeric",hour12:!0};break;case"hours24h":o={hour:"numeric",hour12:!1};break;case"minutes":o={minute:"numeric"};break;case"seconds":o={second:"numeric"};break;case"fullTime":o={hour:"numeric",minute:"numeric",second:"numeric",hour12:!0};break;case"fullTime12h":o={hour:"numeric",minute:"numeric",second:"numeric",hour12:!0};break;case"fullTime24h":o={hour:"numeric",minute:"numeric",second:"numeric",hour12:!1};break;case"fullDateTime":o={year:"numeric",month:"long",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric",hour12:!0};break;case"fullDateTime12h":o={year:"numeric",month:"long",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric",hour12:!0};break;case"fullDateTime24h":o={year:"numeric",month:"long",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric",hour12:!1};break;case"keyboardDate":o={year:"numeric",month:"2-digit",day:"2-digit"};break;case"keyboardDateTime":o={year:"numeric",month:"2-digit",day:"2-digit",hour:"numeric",minute:"numeric",second:"numeric",hour12:!1};break;case"keyboardDateTime12h":o={year:"numeric",month:"2-digit",day:"2-digit",hour:"numeric",minute:"numeric",second:"numeric",hour12:!0};break;case"keyboardDateTime24h":o={year:"numeric",month:"2-digit",day:"2-digit",hour:"numeric",minute:"numeric",second:"numeric",hour12:!1};break;default:o=i??{timeZone:"UTC",timeZoneName:"short"}}return new Intl.DateTimeFormat(n,o).format(s)}function jW(e,t){const n=e.toJsDate(t),r=n.getFullYear(),s=__(String(n.getMonth()+1),2,"0"),i=__(String(n.getDate()),2,"0");return`${r}-${s}-${i}`}function qW(e){const[t,n,r]=e.split("-").map(Number);return new Date(t,n-1,r)}function WW(e,t){const n=new Date(e);return n.setMinutes(n.getMinutes()+t),n}function GW(e,t){const n=new Date(e);return n.setHours(n.getHours()+t),n}function KW(e,t){const n=new Date(e);return n.setDate(n.getDate()+t),n}function YW(e,t){const n=new Date(e);return n.setDate(n.getDate()+t*7),n}function XW(e,t){const n=new Date(e);return n.setDate(1),n.setMonth(n.getMonth()+t),n}function QW(e){return e.getFullYear()}function JW(e){return e.getMonth()}function ZW(e){return e.getDate()}function e6(e){return new Date(e.getFullYear(),e.getMonth()+1,1)}function t6(e){return new Date(e.getFullYear(),e.getMonth()-1,1)}function n6(e){return e.getHours()}function r6(e){return e.getMinutes()}function s6(e){return new Date(e.getFullYear(),0,1)}function i6(e){return new Date(e.getFullYear(),11,31)}function o6(e,t){return rp(e,t[0])&&u6(e,t[1])}function a6(e){const t=new Date(e);return t instanceof Date&&!isNaN(t.getTime())}function rp(e,t){return e.getTime()>t.getTime()}function l6(e,t){return rp(by(e),by(t))}function u6(e,t){return e.getTime()<t.getTime()}function ek(e,t){return e.getTime()===t.getTime()}function c6(e,t){return e.getDate()===t.getDate()&&e.getMonth()===t.getMonth()&&e.getFullYear()===t.getFullYear()}function d6(e,t){return e.getMonth()===t.getMonth()&&e.getFullYear()===t.getFullYear()}function f6(e,t){return e.getFullYear()===t.getFullYear()}function h6(e,t,n){const r=new Date(e),s=new Date(t);switch(n){case"years":return r.getFullYear()-s.getFullYear();case"quarters":return Math.floor((r.getMonth()-s.getMonth()+(r.getFullYear()-s.getFullYear())*12)/4);case"months":return r.getMonth()-s.getMonth()+(r.getFullYear()-s.getFullYear())*12;case"weeks":return Math.floor((r.getTime()-s.getTime())/(1e3*60*60*24*7));case"days":return Math.floor((r.getTime()-s.getTime())/(1e3*60*60*24));case"hours":return Math.floor((r.getTime()-s.getTime())/(1e3*60*60));case"minutes":return Math.floor((r.getTime()-s.getTime())/(1e3*60));case"seconds":return Math.floor((r.getTime()-s.getTime())/1e3);default:return r.getTime()-s.getTime()}}function p6(e,t){const n=new Date(e);return n.setHours(t),n}function m6(e,t){const n=new Date(e);return n.setMinutes(t),n}function g6(e,t){const n=new Date(e);return n.setMonth(t),n}function v6(e,t){const n=new Date(e);return n.setDate(t),n}function y6(e,t){const n=new Date(e);return n.setFullYear(t),n}function by(e){return new Date(e.getFullYear(),e.getMonth(),e.getDate(),0,0,0,0)}function b6(e){return new Date(e.getFullYear(),e.getMonth(),e.getDate(),23,59,59,999)}class w6{constructor(t){this.locale=t.locale,this.formats=t.formats}date(t){return CA(t)}toJsDate(t){return t}toISO(t){return jW(this,t)}parseISO(t){return qW(t)}addMinutes(t,n){return WW(t,n)}addHours(t,n){return GW(t,n)}addDays(t,n){return KW(t,n)}addWeeks(t,n){return YW(t,n)}addMonths(t,n){return XW(t,n)}getWeekArray(t,n){return FW(t,this.locale,n?Number(n):void 0)}startOfWeek(t,n){return NW(t,this.locale,n?Number(n):void 0)}endOfWeek(t){return BW(t,this.locale)}startOfMonth(t){return xA(t)}endOfMonth(t){return EA(t)}format(t,n){return zW(t,n,this.locale,this.formats)}isEqual(t,n){return ek(t,n)}isValid(t){return a6(t)}isWithinRange(t,n){return o6(t,n)}isAfter(t,n){return rp(t,n)}isAfterDay(t,n){return l6(t,n)}isBefore(t,n){return!rp(t,n)&&!ek(t,n)}isSameDay(t,n){return c6(t,n)}isSameMonth(t,n){return d6(t,n)}isSameYear(t,n){return f6(t,n)}setMinutes(t,n){return m6(t,n)}setHours(t,n){return p6(t,n)}setMonth(t,n){return g6(t,n)}setDate(t,n){return v6(t,n)}setYear(t,n){return y6(t,n)}getDiff(t,n,r){return h6(t,n,r)}getWeekdays(t){return HW(this.locale,t?Number(t):void 0)}getYear(t){return QW(t)}getMonth(t){return JW(t)}getDate(t){return ZW(t)}getNextMonth(t){return e6(t)}getPreviousMonth(t){return t6(t)}getHours(t){return n6(t)}getMinutes(t){return r6(t)}startOfDay(t){return by(t)}endOfDay(t){return b6(t)}startOfYear(t){return s6(t)}endOfYear(t){return i6(t)}}const S6=Symbol.for("vuetify:date-options"),tk=Symbol.for("vuetify:date-adapter");function _6(e,t){const n=tr({adapter:w6,locale:{af:"af-ZA",bg:"bg-BG",ca:"ca-ES",ckb:"",cs:"cs-CZ",de:"de-DE",el:"el-GR",en:"en-US",et:"et-EE",fa:"fa-IR",fi:"fi-FI",hr:"hr-HR",hu:"hu-HU",he:"he-IL",id:"id-ID",it:"it-IT",ja:"ja-JP",ko:"ko-KR",lv:"lv-LV",lt:"lt-LT",nl:"nl-NL",no:"no-NO",pl:"pl-PL",pt:"pt-PT",ro:"ro-RO",ru:"ru-RU",sk:"sk-SK",sl:"sl-SI",srCyrl:"sr-SP",srLatn:"sr-SP",sv:"sv-SE",th:"th-TH",tr:"tr-TR",az:"az-AZ",uk:"uk-UA",vi:"vi-VN",zhHans:"zh-CN",zhHant:"zh-TW"}},e);return{options:n,instance:k6(n,t)}}function k6(e,t){const n=vn(typeof e.adapter=="function"?new e.adapter({locale:e.locale[t.current.value]??t.current.value,formats:e.formats}):e.adapter);return Ce(t.current,r=>{n.locale=e.locale[r]??r??n.locale}),n}const id=Symbol.for("vuetify:layout"),PA=Symbol.for("vuetify:layout-item"),nk=1e3,TA=de({overlaps:{type:Array,default:()=>[]},fullHeight:Boolean},"layout"),RA=de({name:{type:String},order:{type:[Number,String],default:0},absolute:Boolean},"layout-item");function IA(){const e=Ye(id);if(!e)throw new Error("[Vuetify] Could not find injected layout");return{getLayoutItem:e.getLayoutItem,mainRect:e.mainRect,mainStyles:e.mainStyles}}function AA(e){const t=Ye(id);if(!t)throw new Error("[Vuetify] Could not find injected layout");const n=e.id??`layout-item-${vr()}`,r=sn("useLayoutItem");Gt(PA,{id:n});const s=Me(!1);gb(()=>s.value=!0),kC(()=>s.value=!1);const{layoutItemStyles:i,layoutItemScrimStyles:o}=t.register(r,{...e,active:R(()=>s.value?!1:e.active.value),id:n});return Tn(()=>t.unregister(n)),{layoutItemStyles:i,layoutRect:t.layoutRect,layoutItemScrimStyles:o}}const x6=(e,t,n,r)=>{let s={top:0,left:0,right:0,bottom:0};const i=[{id:"",layer:{...s}}];for(const o of e){const a=t.get(o),l=n.get(o),u=r.get(o);if(!a||!l||!u)continue;const d={...s,[a.value]:parseInt(s[a.value],10)+(u.value?parseInt(l.value,10):0)};i.push({id:o,layer:d}),s=d}return i};function OA(e){const t=Ye(id,null),n=R(()=>t?t.rootZIndex.value-100:nk),r=U([]),s=vn(new Map),i=vn(new Map),o=vn(new Map),a=vn(new Map),l=vn(new Map),{resizeRef:u,contentRect:d}=Ua(),c=R(()=>{const T=new Map,C=e.overlaps??[];for(const k of C.filter(x=>x.includes(":"))){const[x,I]=k.split(":");if(!r.value.includes(x)||!r.value.includes(I))continue;const M=s.get(x),O=s.get(I),A=i.get(x),D=i.get(I);!M||!O||!A||!D||(T.set(I,{position:M.value,amount:parseInt(A.value,10)}),T.set(x,{position:O.value,amount:-parseInt(D.value,10)}))}return T}),f=R(()=>{const T=[...new Set([...o.values()].map(k=>k.value))].sort((k,x)=>k-x),C=[];for(const k of T){const x=r.value.filter(I=>{var M;return((M=o.get(I))==null?void 0:M.value)===k});C.push(...x)}return x6(C,s,i,a)}),p=R(()=>!Array.from(l.values()).some(T=>T.value)),g=R(()=>f.value[f.value.length-1].layer),m=R(()=>({"--v-layout-left":Ne(g.value.left),"--v-layout-right":Ne(g.value.right),"--v-layout-top":Ne(g.value.top),"--v-layout-bottom":Ne(g.value.bottom),...p.value?void 0:{transition:"none"}})),y=R(()=>f.value.slice(1).map((T,C)=>{let{id:k}=T;const{layer:x}=f.value[C],I=i.get(k),M=s.get(k);return{id:k,...x,size:Number(I.value),position:M.value}})),b=T=>y.value.find(C=>C.id===T),w=sn("createLayout"),S=Me(!1);St(()=>{S.value=!0}),Gt(id,{register:(T,C)=>{let{id:k,order:x,position:I,layoutSize:M,elementSize:O,active:A,disableTransitions:D,absolute:V}=C;o.set(k,x),s.set(k,I),i.set(k,M),a.set(k,A),D&&l.set(k,D);const G=Pl(PA,w==null?void 0:w.vnode).indexOf(T);G>-1?r.value.splice(G,0,k):r.value.push(k);const j=R(()=>y.value.findIndex(q=>q.id===k)),B=R(()=>n.value+f.value.length*2-j.value*2),W=R(()=>{const q=I.value==="left"||I.value==="right",K=I.value==="right",pe=I.value==="bottom",ue=O.value??M.value,le=ue===0?"%":"px",J={[I.value]:0,zIndex:B.value,transform:`translate${q?"X":"Y"}(${(A.value?0:-(ue===0?100:ue))*(K||pe?-1:1)}${le})`,position:V.value||n.value!==nk?"absolute":"fixed",...p.value?void 0:{transition:"none"}};if(!S.value)return J;const be=y.value[j.value];if(!be)throw new Error(`[Vuetify] Could not find layout item "${k}"`);const Se=c.value.get(k);return Se&&(be[Se.position]+=Se.amount),{...J,height:q?`calc(100% - ${be.top}px - ${be.bottom}px)`:O.value?`${O.value}px`:void 0,left:K?void 0:`${be.left}px`,right:K?`${be.right}px`:void 0,top:I.value!=="bottom"?`${be.top}px`:void 0,bottom:I.value!=="top"?`${be.bottom}px`:void 0,width:q?O.value?`${O.value}px`:void 0:`calc(100% - ${be.left}px - ${be.right}px)`}}),Z=R(()=>({zIndex:B.value-1}));return{layoutItemStyles:W,layoutItemScrimStyles:Z,zIndex:B}},unregister:T=>{o.delete(T),s.delete(T),i.delete(T),a.delete(T),l.delete(T),r.value=r.value.filter(C=>C!==T)},mainRect:g,mainStyles:m,getLayoutItem:b,items:y,layoutRect:d,rootZIndex:n});const P=R(()=>["v-layout",{"v-layout--full-height":e.fullHeight}]),E=R(()=>({zIndex:t?n.value:void 0,position:t?"relative":void 0,overflow:t?"hidden":void 0}));return{layoutClasses:P,layoutStyles:E,getLayoutItem:b,items:y,layoutRect:d,layoutRef:u}}const E6=["start","end","left","right","top","bottom"],C6=de({color:String,disableResizeWatcher:Boolean,disableRouteWatcher:Boolean,expandOnHover:Boolean,floating:Boolean,modelValue:{type:Boolean,default:null},permanent:Boolean,rail:{type:Boolean,default:null},railWidth:{type:[Number,String],default:56},scrim:{type:[Boolean,String],default:!0},image:String,temporary:Boolean,persistent:Boolean,touchless:Boolean,width:{type:[Number,String],default:256},location:{type:String,default:"start",validator:e=>E6.includes(e)},sticky:Boolean,...vs(),...Ve(),...Fb(),...nl({mobile:null}),...bs(),...RA(),...Bn(),...bt({tag:"nav"}),...Dt()},"VNavigationDrawer"),Rw=xe()({name:"VNavigationDrawer",props:C6(),emits:{"update:modelValue":e=>!0,"update:rail":e=>!0},setup(e,t){let{attrs:n,emit:r,slots:s}=t;const{isRtl:i}=Nr(),{themeClasses:o}=Xt(e),{borderClasses:a}=Ls(e),{backgroundColorClasses:l,backgroundColorStyles:u}=pr(Te(e,"color")),{elevationClasses:d}=$s(e),{displayClasses:c,mobile:f}=mi(e),{roundedClasses:p}=qn(e),g=NP(),m=st(e,"modelValue",null,Z=>!!Z),{ssrBootStyles:y}=qd(),{scopeId:b}=Au(),w=U(),S=Me(!1),{runOpenDelay:P,runCloseDelay:E}=Nb(e,Z=>{S.value=Z}),T=R(()=>e.rail&&e.expandOnHover&&S.value?Number(e.width):Number(e.rail?e.railWidth:e.width)),C=R(()=>wv(e.location,i.value)),k=R(()=>e.persistent),x=R(()=>!e.permanent&&(f.value||e.temporary)),I=R(()=>e.sticky&&!x.value&&C.value!=="bottom");Qr(()=>e.expandOnHover&&e.rail!=null,()=>{Ce(S,Z=>r("update:rail",!Z))}),Qr(()=>!e.disableResizeWatcher,()=>{Ce(x,Z=>!e.permanent&&Ot(()=>m.value=!Z))}),Qr(()=>!e.disableRouteWatcher&&!!g,()=>{Ce(g.currentRoute,()=>x.value&&(m.value=!1))}),Ce(()=>e.permanent,Z=>{Z&&(m.value=!0)}),e.modelValue==null&&!x.value&&(m.value=e.permanent||!f.value);const{isDragging:M,dragProgress:O}=$W({el:w,isActive:m,isTemporary:x,width:T,touchless:Te(e,"touchless"),position:C}),A=R(()=>{const Z=x.value?0:e.rail&&e.expandOnHover?Number(e.railWidth):T.value;return M.value?Z*O.value:Z}),D=R(()=>["top","bottom"].includes(e.location)?0:T.value),{layoutItemStyles:V,layoutItemScrimStyles:H}=AA({id:e.name,order:R(()=>parseInt(e.order,10)),position:C,layoutSize:A,elementSize:D,active:R(()=>m.value||M.value),disableTransitions:R(()=>M.value),absolute:R(()=>e.absolute||I.value&&typeof G.value!="string")}),{isStuck:G,stickyStyles:j}=AW({rootEl:w,isSticky:I,layoutItemStyles:V}),B=pr(R(()=>typeof e.scrim=="string"?e.scrim:null)),W=R(()=>({...M.value?{opacity:O.value*.2,transition:"none"}:void 0,...H.value}));return Dr({VList:{bgColor:"transparent"}}),Ie(()=>{const Z=s.image||e.image;return h(Re,null,[h(e.tag,me({ref:w,onMouseenter:P,onMouseleave:E,class:["v-navigation-drawer",`v-navigation-drawer--${C.value}`,{"v-navigation-drawer--expand-on-hover":e.expandOnHover,"v-navigation-drawer--floating":e.floating,"v-navigation-drawer--is-hovering":S.value,"v-navigation-drawer--rail":e.rail,"v-navigation-drawer--temporary":x.value,"v-navigation-drawer--persistent":k.value,"v-navigation-drawer--active":m.value,"v-navigation-drawer--sticky":I.value},o.value,l.value,a.value,c.value,d.value,p.value,e.class],style:[u.value,V.value,y.value,j.value,e.style,["top","bottom"].includes(C.value)?{height:"auto"}:{}]},b,n),{default:()=>{var q,K,pe;return[Z&&h("div",{key:"image",class:"v-navigation-drawer__img"},[s.image?h(At,{key:"image-defaults",disabled:!e.image,defaults:{VImg:{alt:"",cover:!0,height:"inherit",src:e.image}}},s.image):h(Ki,{key:"image-img",alt:"",cover:!0,height:"inherit",src:e.image},null)]),s.prepend&&h("div",{class:"v-navigation-drawer__prepend"},[(q=s.prepend)==null?void 0:q.call(s)]),h("div",{class:"v-navigation-drawer__content"},[(K=s.default)==null?void 0:K.call(s)]),s.append&&h("div",{class:"v-navigation-drawer__append"},[(pe=s.append)==null?void 0:pe.call(s)])]}}),h($o,{name:"fade-transition"},{default:()=>[x.value&&(M.value||m.value)&&!!e.scrim&&h("div",me({class:["v-navigation-drawer__scrim",B.backgroundColorClasses.value],style:[W.value,B.backgroundColorStyles.value],onClick:()=>{k.value||(m.value=!1)}},b),null)]})])}),{isStuck:G}}}),P6=de({active:Boolean,disabled:Boolean,max:[Number,String],value:{type:[Number,String],default:0},...Ve(),...Ou({transition:{component:XP}})},"VCounter"),Iw=xe()({name:"VCounter",functional:!0,props:P6(),setup(e,t){let{slots:n}=t;const r=R(()=>e.max?`${e.value} / ${e.max}`:String(e.value));return Ie(()=>h(ii,{transition:e.transition},{default:()=>[en(h("div",{class:["v-counter",{"text-error":e.max&&!e.disabled&&parseFloat(e.value)>parseFloat(e.max)},e.class],style:e.style},[n.default?n.default({counter:r.value,max:e.max,value:e.value}):r.value]),[[qo,e.active]])]})),{}}}),T6=de({text:String,onClick:zn(),...Ve(),...Dt()},"VLabel"),Aw=xe()({name:"VLabel",props:T6(),setup(e,t){let{slots:n}=t;return Ie(()=>{var r;return h("label",{class:["v-label",{"v-label--clickable":!!e.onClick},e.class],style:e.style,onClick:e.onClick},[e.text,(r=n.default)==null?void 0:r.call(n)])}),{}}}),R6=de({floating:Boolean,...Ve()},"VFieldLabel"),_f=xe()({name:"VFieldLabel",props:R6(),setup(e,t){let{slots:n}=t;return Ie(()=>h(Aw,{class:["v-field-label",{"v-field-label--floating":e.floating},e.class],style:e.style,"aria-hidden":e.floating||void 0},n)),{}}});function MA(e){const{t}=es();function n(r){let{name:s}=r;const i={prepend:"prependAction",prependInner:"prependAction",append:"appendAction",appendInner:"appendAction",clear:"clear"}[s],o=e[`onClick:${s}`],a=o&&i?t(`$vuetify.input.${i}`,e.label??""):void 0;return h(X,{icon:e[`${s}Icon`],"aria-label":a,onClick:o},null)}return{InputIcon:n}}const DA=de({focused:Boolean,"onUpdate:focused":zn()},"focus");function Uu(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:pi();const n=st(e,"focused"),r=R(()=>({[`${t}--focused`]:n.value}));function s(){n.value=!0}function i(){n.value=!1}return{focusClasses:r,isFocused:n,focus:s,blur:i}}const I6=["underlined","outlined","filled","solo","solo-inverted","solo-filled","plain"],mm=de({appendInnerIcon:Je,bgColor:String,clearable:Boolean,clearIcon:{type:Je,default:"$clear"},active:Boolean,centerAffix:{type:Boolean,default:void 0},color:String,baseColor:String,dirty:Boolean,disabled:{type:Boolean,default:null},error:Boolean,flat:Boolean,label:String,persistentClear:Boolean,prependInnerIcon:Je,reverse:Boolean,singleLine:Boolean,variant:{type:String,default:"filled",validator:e=>I6.includes(e)},"onClick:clear":zn(),"onClick:appendInner":zn(),"onClick:prependInner":zn(),...Ve(),...Bp(),...Bn(),...Dt()},"VField"),gm=xe()({name:"VField",inheritAttrs:!1,props:{id:String,...DA(),...mm()},emits:{"update:focused":e=>!0,"update:modelValue":e=>!0},setup(e,t){let{attrs:n,emit:r,slots:s}=t;const{themeClasses:i}=Xt(e),{loaderClasses:o}=Ad(e),{focusClasses:a,isFocused:l,focus:u,blur:d}=Uu(e),{InputIcon:c}=MA(e),{roundedClasses:f}=qn(e),{rtlClasses:p}=Nr(),g=R(()=>e.dirty||e.active),m=R(()=>!e.singleLine&&!!(e.label||s.label)),y=vr(),b=R(()=>e.id||`input-${y}`),w=R(()=>`${b.value}-messages`),S=U(),P=U(),E=U(),T=R(()=>["plain","underlined"].includes(e.variant)),{backgroundColorClasses:C,backgroundColorStyles:k}=pr(Te(e,"bgColor")),{textColorClasses:x,textColorStyles:I}=Is(R(()=>e.error||e.disabled?void 0:g.value&&l.value?e.color:e.baseColor));Ce(g,D=>{if(m.value){const V=S.value.$el,H=P.value.$el;requestAnimationFrame(()=>{const G=Ab(V),j=H.getBoundingClientRect(),B=j.x-G.x,W=j.y-G.y-(G.height/2-j.height/2),Z=j.width/.75,q=Math.abs(Z-G.width)>1?{maxWidth:Ne(Z)}:void 0,K=getComputedStyle(V),pe=getComputedStyle(H),ue=parseFloat(K.transitionDuration)*1e3||150,le=parseFloat(pe.getPropertyValue("--v-field-label-scale")),J=pe.getPropertyValue("color");V.style.visibility="visible",H.style.visibility="hidden",Tl(V,{transform:`translate(${B}px, ${W}px) scale(${le})`,color:J,...q},{duration:ue,easing:Oh,direction:D?"normal":"reverse"}).finished.then(()=>{V.style.removeProperty("visibility"),H.style.removeProperty("visibility")})})}},{flush:"post"});const M=R(()=>({isActive:g,isFocused:l,controlRef:E,blur:d,focus:u}));function O(D){D.target!==document.activeElement&&D.preventDefault()}function A(D){var V;D.key!=="Enter"&&D.key!==" "||(D.preventDefault(),D.stopPropagation(),(V=e["onClick:clear"])==null||V.call(e,new MouseEvent("click")))}return Ie(()=>{var B,W,Z;const D=e.variant==="outlined",V=!!(s["prepend-inner"]||e.prependInnerIcon),H=!!(e.clearable||s.clear),G=!!(s["append-inner"]||e.appendInnerIcon||H),j=()=>s.label?s.label({...M.value,label:e.label,props:{for:b.value}}):e.label;return h("div",me({class:["v-field",{"v-field--active":g.value,"v-field--appended":G,"v-field--center-affix":e.centerAffix??!T.value,"v-field--disabled":e.disabled,"v-field--dirty":e.dirty,"v-field--error":e.error,"v-field--flat":e.flat,"v-field--has-background":!!e.bgColor,"v-field--persistent-clear":e.persistentClear,"v-field--prepended":V,"v-field--reverse":e.reverse,"v-field--single-line":e.singleLine,"v-field--no-label":!j(),[`v-field--variant-${e.variant}`]:!0},i.value,C.value,a.value,o.value,f.value,p.value,e.class],style:[k.value,e.style],onClick:O},n),[h("div",{class:"v-field__overlay"},null),h(Vp,{name:"v-field",active:!!e.loading,color:e.error?"error":typeof e.loading=="string"?e.loading:e.color},{default:s.loader}),V&&h("div",{key:"prepend",class:"v-field__prepend-inner"},[e.prependInnerIcon&&h(c,{key:"prepend-icon",name:"prependInner"},null),(B=s["prepend-inner"])==null?void 0:B.call(s,M.value)]),h("div",{class:"v-field__field","data-no-activator":""},[["filled","solo","solo-inverted","solo-filled"].includes(e.variant)&&m.value&&h(_f,{key:"floating-label",ref:P,class:[x.value],floating:!0,for:b.value,style:I.value},{default:()=>[j()]}),h(_f,{ref:S,for:b.value},{default:()=>[j()]}),(W=s.default)==null?void 0:W.call(s,{...M.value,props:{id:b.value,class:"v-field__input","aria-describedby":w.value},focus:u,blur:d})]),H&&h(JP,{key:"clear"},{default:()=>[en(h("div",{class:"v-field__clearable",onMousedown:q=>{q.preventDefault(),q.stopPropagation()}},[h(At,{defaults:{VIcon:{icon:e.clearIcon}}},{default:()=>[s.clear?s.clear({...M.value,props:{onKeydown:A,onFocus:u,onBlur:d,onClick:e["onClick:clear"]}}):h(c,{name:"clear",onKeydown:A,onFocus:u,onBlur:d},null)]})]),[[qo,e.dirty]])]}),G&&h("div",{key:"append",class:"v-field__append-inner"},[(Z=s["append-inner"])==null?void 0:Z.call(s,M.value),e.appendInnerIcon&&h(c,{key:"append-icon",name:"appendInner"},null)]),h("div",{class:["v-field__outline",x.value],style:I.value},[D&&h(Re,null,[h("div",{class:"v-field__outline__start"},null),m.value&&h("div",{class:"v-field__outline__notch"},[h(_f,{ref:P,floating:!0,for:b.value},{default:()=>[j()]})]),h("div",{class:"v-field__outline__end"},null)]),T.value&&m.value&&h(_f,{ref:P,floating:!0,for:b.value},{default:()=>[j()]})])])}),{controlRef:E}}});function Ow(e){const t=Object.keys(gm.props).filter(n=>!Fp(n)&&n!=="class"&&n!=="style");return dP(e,t)}const A6=de({active:Boolean,color:String,messages:{type:[Array,String],default:()=>[]},...Ve(),...Ou({transition:{component:XP,leaveAbsolute:!0,group:!0}})},"VMessages"),O6=xe()({name:"VMessages",props:A6(),setup(e,t){let{slots:n}=t;const r=R(()=>Dn(e.messages)),{textColorClasses:s,textColorStyles:i}=Is(R(()=>e.color));return Ie(()=>h(ii,{transition:e.transition,tag:"div",class:["v-messages",s.value,e.class],style:[i.value,e.style],role:"alert","aria-live":"polite"},{default:()=>[e.active&&r.value.map((o,a)=>h("div",{class:"v-messages__message",key:`${a}-${r.value}`},[n.message?n.message({message:o}):o]))]})),{}}}),LA=Symbol.for("vuetify:form"),M6=de({disabled:Boolean,fastFail:Boolean,readonly:Boolean,modelValue:{type:Boolean,default:null},validateOn:{type:String,default:"input"}},"form");function D6(e){const t=st(e,"modelValue"),n=R(()=>e.disabled),r=R(()=>e.readonly),s=Me(!1),i=U([]),o=U([]);async function a(){const d=[];let c=!0;o.value=[],s.value=!0;for(const f of i.value){const p=await f.validate();if(p.length>0&&(c=!1,d.push({id:f.id,errorMessages:p})),!c&&e.fastFail)break}return o.value=d,s.value=!1,{valid:c,errors:o.value}}function l(){i.value.forEach(d=>d.reset())}function u(){i.value.forEach(d=>d.resetValidation())}return Ce(i,()=>{let d=0,c=0;const f=[];for(const p of i.value)p.isValid===!1?(c++,f.push({id:p.id,errorMessages:p.errorMessages})):p.isValid===!0&&d++;o.value=f,t.value=c>0?!1:d===i.value.length?!0:null},{deep:!0,flush:"post"}),Gt(LA,{register:d=>{let{id:c,vm:f,validate:p,reset:g,resetValidation:m}=d;i.value.some(y=>y.id===c),i.value.push({id:c,validate:p,reset:g,resetValidation:m,vm:Pp(f),isValid:null,errorMessages:[]})},unregister:d=>{i.value=i.value.filter(c=>c.id!==d)},update:(d,c,f)=>{const p=i.value.find(g=>g.id===d);p&&(p.isValid=c,p.errorMessages=f)},isDisabled:n,isReadonly:r,isValidating:s,isValid:t,items:i,validateOn:Te(e,"validateOn")}),{errors:o,isDisabled:n,isReadonly:r,isValidating:s,isValid:t,items:i,validate:a,reset:l,resetValidation:u}}function $A(){return Ye(LA,null)}const L6=de({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,...DA()},"validation");function $6(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:pi(),n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:vr();const r=st(e,"modelValue"),s=R(()=>e.validationValue===void 0?r.value:e.validationValue),i=$A(),o=U([]),a=Me(!0),l=R(()=>!!(Dn(r.value===""?null:r.value).length||Dn(s.value===""?null:s.value).length)),u=R(()=>!!(e.disabled??(i==null?void 0:i.isDisabled.value))),d=R(()=>!!(e.readonly??(i==null?void 0:i.isReadonly.value))),c=R(()=>{var E;return(E=e.errorMessages)!=null&&E.length?Dn(e.errorMessages).concat(o.value).slice(0,Math.max(0,+e.maxErrors)):o.value}),f=R(()=>{let E=(e.validateOn??(i==null?void 0:i.validateOn.value))||"input";E==="lazy"&&(E="input lazy"),E==="eager"&&(E="input eager");const T=new Set((E==null?void 0:E.split(" "))??[]);return{input:T.has("input"),blur:T.has("blur")||T.has("input")||T.has("invalid-input"),invalidInput:T.has("invalid-input"),lazy:T.has("lazy"),eager:T.has("eager")}}),p=R(()=>{var E;return e.error||(E=e.errorMessages)!=null&&E.length?!1:e.rules.length?a.value?o.value.length||f.value.lazy?null:!0:!o.value.length:!0}),g=Me(!1),m=R(()=>({[`${t}--error`]:p.value===!1,[`${t}--dirty`]:l.value,[`${t}--disabled`]:u.value,[`${t}--readonly`]:d.value})),y=sn("validation"),b=R(()=>e.name??ie(n));Ap(()=>{i==null||i.register({id:b.value,vm:y,validate:P,reset:w,resetValidation:S})}),Tn(()=>{i==null||i.unregister(b.value)}),St(async()=>{f.value.lazy||await P(!f.value.eager),i==null||i.update(b.value,p.value,c.value)}),Qr(()=>f.value.input||f.value.invalidInput&&p.value===!1,()=>{Ce(s,()=>{if(s.value!=null)P();else if(e.focused){const E=Ce(()=>e.focused,T=>{T||P(),E()})}})}),Qr(()=>f.value.blur,()=>{Ce(()=>e.focused,E=>{E||P()})}),Ce([p,c],()=>{i==null||i.update(b.value,p.value,c.value)});async function w(){r.value=null,await Ot(),await S()}async function S(){a.value=!0,f.value.lazy?o.value=[]:await P(!f.value.eager)}async function P(){let E=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;const T=[];g.value=!0;for(const C of e.rules){if(T.length>=+(e.maxErrors??1))break;const x=await(typeof C=="function"?C:()=>C)(s.value);if(x!==!0){if(x!==!1&&typeof x!="string"){console.warn(`${x} is not a valid value. Rule functions must return boolean true or a string.`);continue}T.push(x||"")}}return o.value=T,g.value=!1,a.value=E,o.value}return{errorMessages:c,isDirty:l,isDisabled:u,isReadonly:d,isPristine:a,isValid:p,isValidating:g,reset:w,resetValidation:S,validate:P,validationClasses:m}}const ol=de({id:String,appendIcon:Je,centerAffix:{type:Boolean,default:!0},prependIcon:Je,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":zn(),"onClick:append":zn(),...Ve(),...Lr(),...fP($r(),["maxWidth","minWidth","width"]),...Dt(),...L6()},"VInput"),gs=xe()({name:"VInput",props:{...ol()},emits:{"update:modelValue":e=>!0},setup(e,t){let{attrs:n,slots:r,emit:s}=t;const{densityClasses:i}=ys(e),{dimensionStyles:o}=Fr(e),{themeClasses:a}=Xt(e),{rtlClasses:l}=Nr(),{InputIcon:u}=MA(e),d=vr(),c=R(()=>e.id||`input-${d}`),f=R(()=>`${c.value}-messages`),{errorMessages:p,isDirty:g,isDisabled:m,isReadonly:y,isPristine:b,isValid:w,isValidating:S,reset:P,resetValidation:E,validate:T,validationClasses:C}=$6(e,"v-input",c),k=R(()=>({id:c,messagesId:f,isDirty:g,isDisabled:m,isReadonly:y,isPristine:b,isValid:w,isValidating:S,reset:P,resetValidation:E,validate:T})),x=R(()=>{var I;return(I=e.errorMessages)!=null&&I.length||!b.value&&p.value.length?p.value:e.hint&&(e.persistentHint||e.focused)?e.hint:e.messages});return Ie(()=>{var D,V,H,G;const I=!!(r.prepend||e.prependIcon),M=!!(r.append||e.appendIcon),O=x.value.length>0,A=!e.hideDetails||e.hideDetails==="auto"&&(O||!!r.details);return h("div",{class:["v-input",`v-input--${e.direction}`,{"v-input--center-affix":e.centerAffix,"v-input--hide-spin-buttons":e.hideSpinButtons},i.value,a.value,l.value,C.value,e.class],style:[o.value,e.style]},[I&&h("div",{key:"prepend",class:"v-input__prepend"},[(D=r.prepend)==null?void 0:D.call(r,k.value),e.prependIcon&&h(u,{key:"prepend-icon",name:"prepend"},null)]),r.default&&h("div",{class:"v-input__control"},[(V=r.default)==null?void 0:V.call(r,k.value)]),M&&h("div",{key:"append",class:"v-input__append"},[e.appendIcon&&h(u,{key:"append-icon",name:"append"},null),(H=r.append)==null?void 0:H.call(r,k.value)]),A&&h("div",{class:"v-input__details"},[h(O6,{id:f.value,active:O,messages:x.value},{message:r.message}),(G=r.details)==null?void 0:G.call(r,k.value)])])}),{reset:P,resetValidation:E,validate:T,isValid:w,errorMessages:p}}}),F6=["color","file","time","date","datetime-local","week","month"],FA=de({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,...ol(),...mm()},"VTextField"),ct=xe()({name:"VTextField",directives:{Intersect:kw},inheritAttrs:!1,props:FA(),emits:{"click:control":e=>!0,"mousedown:control":e=>!0,"update:focused":e=>!0,"update:modelValue":e=>!0},setup(e,t){let{attrs:n,emit:r,slots:s}=t;const i=st(e,"modelValue"),{isFocused:o,focus:a,blur:l}=Uu(e),u=R(()=>typeof e.counterValue=="function"?e.counterValue(i.value):typeof e.counterValue=="number"?e.counterValue:(i.value??"").toString().length),d=R(()=>{if(n.maxlength)return n.maxlength;if(!(!e.counter||typeof e.counter!="number"&&typeof e.counter!="string"))return e.counter}),c=R(()=>["plain","underlined"].includes(e.variant));function f(T,C){var k,x;!e.autofocus||!T||(x=(k=C[0].target)==null?void 0:k.focus)==null||x.call(k)}const p=U(),g=U(),m=U(),y=R(()=>F6.includes(e.type)||e.persistentPlaceholder||o.value||e.active);function b(){var T;m.value!==document.activeElement&&((T=m.value)==null||T.focus()),o.value||a()}function w(T){r("mousedown:control",T),T.target!==m.value&&(b(),T.preventDefault())}function S(T){b(),r("click:control",T)}function P(T){T.stopPropagation(),b(),Ot(()=>{i.value=null,Ib(e["onClick:clear"],T)})}function E(T){var k;const C=T.target;if(i.value=C.value,(k=e.modelModifiers)!=null&&k.trim&&["text","search","password","tel","url"].includes(e.type)){const x=[C.selectionStart,C.selectionEnd];Ot(()=>{C.selectionStart=x[0],C.selectionEnd=x[1]})}}return Ie(()=>{const T=!!(s.counter||e.counter!==!1&&e.counter!=null),C=!!(T||s.details),[k,x]=Za(n),{modelValue:I,...M}=gs.filterProps(e),O=Ow(e);return h(gs,me({ref:p,modelValue:i.value,"onUpdate:modelValue":A=>i.value=A,class:["v-text-field",{"v-text-field--prefixed":e.prefix,"v-text-field--suffixed":e.suffix,"v-input--plain-underlined":c.value},e.class],style:e.style},k,M,{centerAffix:!c.value,focused:o.value}),{...s,default:A=>{let{id:D,isDisabled:V,isDirty:H,isReadonly:G,isValid:j}=A;return h(gm,me({ref:g,onMousedown:w,onClick:S,"onClick:clear":P,"onClick:prependInner":e["onClick:prependInner"],"onClick:appendInner":e["onClick:appendInner"],role:e.role},O,{id:D.value,active:y.value||H.value,dirty:H.value||e.dirty,disabled:V.value,focused:o.value,error:j.value===!1}),{...s,default:B=>{let{props:{class:W,...Z}}=B;const q=en(h("input",me({ref:m,value:i.value,onInput:E,autofocus:e.autofocus,readonly:G.value,disabled:V.value,name:e.name,placeholder:e.placeholder,size:1,type:e.type,onFocus:b,onBlur:l},Z,x),null),[[mr("intersect"),{handler:f},null,{once:!0}]]);return h(Re,null,[e.prefix&&h("span",{class:"v-text-field__prefix"},[h("span",{class:"v-text-field__prefix__text"},[e.prefix])]),s.default?h("div",{class:W,"data-no-activator":""},[s.default(),q]):Fi(q,{class:W}),e.suffix&&h("span",{class:"v-text-field__suffix"},[h("span",{class:"v-text-field__suffix__text"},[e.suffix])])])}})},details:C?A=>{var D;return h(Re,null,[(D=s.details)==null?void 0:D.call(s,A),T&&h(Re,null,[h("span",null,null),h(Iw,{active:e.persistentCounter||o.value,value:u.value,max:d.value,disabled:e.disabled},s.counter)])])}:void 0})}),Wi({},p,g,m)}}),N6=de({id:String,text:String,...Ds(Od({closeOnBack:!1,location:"end",locationStrategy:"connected",eager:!0,minWidth:0,offset:10,openOnClick:!1,openOnHover:!0,origin:"auto",scrim:!1,scrollStrategy:"reposition",transition:!1}),["absolute","persistent"])},"VTooltip"),xt=xe()({name:"VTooltip",props:N6(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const r=st(e,"modelValue"),{scopeId:s}=Au(),i=vr(),o=R(()=>e.id||`v-tooltip-${i}`),a=U(),l=R(()=>e.location.split(" ").length>1?e.location:e.location+" center"),u=R(()=>e.origin==="auto"||e.origin==="overlap"||e.origin.split(" ").length>1||e.location.split(" ").length>1?e.origin:e.origin+" center"),d=R(()=>e.transition?e.transition:r.value?"scale-transition":"fade-transition"),c=R(()=>me({"aria-describedby":o.value},e.activatorProps));return Ie(()=>{const f=Ni.filterProps(e);return h(Ni,me({ref:a,class:["v-tooltip",e.class],style:e.style,id:o.value},f,{modelValue:r.value,"onUpdate:modelValue":p=>r.value=p,transition:d.value,absolute:!0,location:l.value,origin:u.value,persistent:!0,role:"tooltip",activatorProps:c.value,_disableGlobalStack:!0},s),{activator:n.activator,default:function(){var y;for(var p=arguments.length,g=new Array(p),m=0;m<p;m++)g[m]=arguments[m];return((y=n.default)==null?void 0:y.call(n,...g))??e.text}})}),Wi({},a)}}),B6={key:0,class:"d-flex justify-center static-disabled"},V6={key:1,class:"pulsating-red d-flex justify-center"},U6={key:0,class:"d-flex justify-center"},H6={key:0},z6={key:1},j6={key:1},q6={key:0},W6={key:1},G6={key:0},K6={key:1},Y6={key:0},X6={key:1},Q6={key:2},J6=Le({__name:"FileExplorerSideNav",setup(e){const t=Nt(),n=rr(),r=ku(),s=Yi(),i=U(36),o=U(void 0),a=U(void 0),l=U(!1),u=U(!0),d=R(()=>t.sideNavPrinter),c=R(()=>{var te;return(te=d.value)==null?void 0:te.id}),f=R(()=>c.value?n.isApiResponding(c.value):!1),p=R(()=>{var te;return _A((te=d.value)==null?void 0:te.printerType)}),g=R(()=>{var te;return kA((te=d.value)==null?void 0:te.printerType)}),m=R(()=>{var te;return IW((te=d.value)==null?void 0:te.printerType)}),y=R(()=>c.value?n.isPrinterOperational(c.value):!1),b=R(()=>{var te;return(te=d.value)==null?void 0:te.enabled}),w=R(()=>{var te,Y;return!!((Y=(te=d.value)==null?void 0:te.disabledReason)!=null&&Y.length)}),S=R(()=>c.value?n.isPrinterPrinting(c.value):!1),P=R(()=>{var te;return(te=a.value)!=null&&te.length?a.value.filter(Y=>{var ze;return(ze=o.value)!=null&&ze.length?`${Y.path}`.toLowerCase().includes(o.value):!0})||[]:[]}),E=R(()=>!d.value||!c.value?!1:n.isPrinterStoppable(c.value)),T=R(()=>!d.value||!c.value?!1:n.isPrinterPaused(c.value)),C=R(()=>{var te;return c.value?((te=a.value)==null?void 0:te.length)&&n.isApiResponding(c.value):!1}),k=R(()=>{if(!c.value)throw new Error("Printer ID not set, cannot get current job");return n.printerJobsById[c.value]}),x=R(()=>{if(!c.value)throw new Error("Printer ID not set, cannot get current printing file name");return n.printingFilePathsByPrinterId[c.value]}),I=R(()=>{var N;if(!c.value||!d.value)return null;const te=n.printerEventsById[c.value],Y=n.socketStatesById[c.value],ze=jI(d.value,Y,te);return((N=Bs().frontendDebugSettings)==null?void 0:N.showInterpretedPrinterState)&&console.debug("[FileExplorerSideNav] rendered for printerId",c.value,ze==null?void 0:ze.text,ze==null?void 0:ze.color,ze==null?void 0:ze.rgb),ze}),M=async()=>{var Y;u.value=!0;const te=(Y=d.value)==null?void 0:Y.id;if(te)try{n.isApiResponding(te)?a.value=await t.loadPrinterFiles(te):a.value=await Oo.getFileCache(te)}finally{u.value=!1}},O=async te=>{c.value&&await t.deletePrinterFile(c.value,te.path)};Ce(d,async(te,Y)=>{l.value=!!te;const ze=te==null?void 0:te.id;!te||!ze||(!a.value||te.id!==(Y==null?void 0:Y.id)||!Y)&&await M()}),Ce(l,te=>{te||t.setSideNavPrinter(void 0)});function A(te){return te?te==null?void 0:te.toFixed(1):""}function D(te){return c.value?n.printingFilePathsByPrinterId[c.value]===te.path:!1}function V(){const te=d.value;if(te&&l.value)return dm(te.name)}function H(){d.value&&(Wt.openPrinterURL(d.value.printerURL),Se())}function G(){if(!d.value)return;const te=new URL(d.value.printerURL);te.port="8080",Wt.openPrinterURL(te.toString()),Se()}async function j(){if(c.value){if(n.isPrinterOperational(c.value))return await Wt.sendPrinterDisconnectCommand(c.value);await Wt.sendPrinterConnectCommand(c.value)}}async function B(){if(!c.value)throw new Error("Printer ID not set, cant toggle enabled");if(!d.value)throw new Error("Cant toggle enabled, sidenav printer unset");const te=!d.value.enabled;await Wt.toggleEnabled(c.value,te)}async function W(){if(!c.value)throw new Error("Printer ID not set, cant toggle maintenance");if(!d.value)throw new Error("Cant toggle enabled, sidenav printer unset");if(w.value){await Wt.updatePrinterMaintenance(c.value);return}t.setMaintenanceDialogPrinter(d.value),r.openDialogWithContext(Jt.PrinterMaintenanceDialog),Se()}async function Z(){c.value&&await Wt.refreshSocket(c.value)}async function q(){c.value&&confirm("Are you sure to cancel the current print job?")&&await ah.stopPrintJob(c.value)}async function K(){c.value&&await ah.pausePrintJob(c.value)}async function pe(){c.value&&await ah.resumePrintJob(c.value)}async function ue(){c.value&&(u.value=!0,await t.clearPrinterFiles(c.value),u.value=!1,a.value=t.printerFiles(c.value))}function le(){d.value&&(t.setUpdateDialogPrinter(d.value),r.openDialogWithContext(Jt.AddOrUpdatePrinterDialog),Se())}async function J(te){c.value&&await n.selectAndPrintFile({printerId:c.value,fullPath:te.path})}function be(te){c.value&&Oo.downloadFile(c.value,te)}function Se(){t.setSideNavPrinter(void 0)}return(te,Y)=>{const ze=mr("drop-upload");return $(),Q(Rw,{modelValue:l.value,"onUpdate:modelValue":Y[14]||(Y[14]=F=>l.value=F),loading:"true",absolute:"",location:"right",scrim:"white",temporary:"",width:"700",onClose:Y[15]||(Y[15]=F=>Se())},{default:v(()=>{var F,N,ee;return[d.value?($(),Q(Fe,{key:0,lines:"two"},{prepend:v(()=>[h(xt,{location:"left"},{activator:v(({props:se})=>[h(re,me({size:i.value},se,{icon:"",class:"mr-4 mt-1",color:"primary",onClick:Y[0]||(Y[0]=oe=>H()),onMouseup:Y[1]||(Y[1]=$t(oe=>H(),["middle"]))}),{default:v(()=>[h(lt,{size:i.value,class:"font-weight-bold",color:"primary"},{default:v(()=>[_(ae(V()),1)]),_:1},8,["size"])]),_:2},1040,["size"])]),default:v(()=>[L("span",null," Visit the "+ae(m.value)+" associated to this printer ",1)]),_:1})]),default:v(()=>[h(ht,{class:"font-weight-bold"},{default:v(()=>[_(ae(d.value.name),1)]),_:1}),h(wt),h(SW,null,{default:v(()=>{var se,oe,ge,Ee;return[!b.value||!f.value?($(),we("strong",B6,ae(b.value?"Enabled":"Disabled")+" - "+ae(f.value?(oe=(se=I.value)==null?void 0:se.text)==null?void 0:oe.toUpperCase():"Offline"),1)):ve("",!0),b.value&&((ge=I.value)!=null&&ge.text)&&y.value&&f.value?($(),we("strong",V6," Enabled - "+ae((Ee=I.value)==null?void 0:Ee.text),1)):ve("",!0)]}),_:1}),k.value?($(),Q(wt,{key:0},{default:v(()=>{var se,oe,ge,Ee;return[(se=k.value)!=null&&se.progress?($(),we("span",U6," Progress: "+ae(A((oe=k.value)==null?void 0:oe.progress.completion))+"% ",1)):ve("",!0),(ge=k.value)!=null&&ge.progress?($(),Q(lu,{key:1,"model-value":A((Ee=k.value.progress)==null?void 0:Ee.completion),class:"mt-1 mb-1",height:"8px"},null,8,["model-value"])):ve("",!0),h(xt,{location:"bottom"},{activator:v(({props:ye})=>[h(re,me({variant:"outlined",size:"small"},ye),{default:v(()=>[_(ae(x.value),1)]),_:2},1040)]),default:v(()=>[L("span",null,ae(x.value),1)]),_:1})]}),_:1})):ve("",!0)]),_:1})):ve("",!0),!b.value||!f.value?($(),Q(un,{key:1,color:"primary"},{default:v(()=>[b.value?($(),we("span",z6,[_(" This "+ae(m.value)+" seems unreachable... Will keep trying for you ",1),h(X,null,{default:v(()=>Y[16]||(Y[16]=[_("hourglass_top")])),_:1})])):($(),we("span",H6," Disabled "+ae(m.value)+", enable it first to get live updates ",1))]),_:1})):ve("",!0),!((F=d.value)!=null&&F.enabled)&&!((N=d.value)!=null&&N.disabledReason)?($(),Q(un,{key:2,color:"secondary"},{default:v(()=>[_(" This "+ae(m.value)+" was disabled without reason. ",1)]),_:1})):ve("",!0),(ee=d.value)!=null&&ee.disabledReason?($(),Q(un,{key:3,color:"black"},{default:v(()=>{var se;return[_(" This "+ae(m.value)+" was disabled for maintenance: ",1),Y[17]||(Y[17]=L("br",null,null,-1)),L("small",null,"   "+ae((se=d.value)==null?void 0:se.disabledReason),1)]}),_:1})):ve("",!0),h(yn),en(($(),Q(Kt,{density:"compact"},{default:v(()=>[h(hs,{inset:""},{default:v(()=>Y[18]||(Y[18]=[_(" Manage FDM Monster instance ")])),_:1}),h(xt,{location:"left"},{activator:v(({props:se})=>[h(Fe,me({class:"extra-dense-list-item",link:""},se,{onClick:Y[2]||(Y[2]=$t(oe=>H(),["prevent","stop"]))}),{prepend:v(()=>[h(lt,{class:"ml-3 mr-6 ma-5",size:i.value},{default:v(()=>[p.value?($(),Q(Ki,{key:0,src:RW})):($(),we("span",j6,"MO"))]),_:1},8,["size"])]),default:v(()=>[L("span",null," Open "+ae(m.value),1)]),_:2},1040)]),default:v(()=>[L("span",null," Visit the "+ae(m.value)+" associated to this printer ",1)]),_:1}),g.value?($(),Q(xt,{key:0,location:"left"},{activator:v(({props:se})=>[h(Fe,me({class:"extra-dense-list-item",link:""},se,{onClick:Y[3]||(Y[3]=$t(oe=>G(),["prevent","stop"]))}),{prepend:v(()=>[h(lt,{class:"ml-3 mr-6 ma-5",size:i.value},{default:v(()=>Y[19]||(Y[19]=[L("span",null,"MA",-1)])),_:1},8,["size"])]),default:v(()=>[Y[20]||(Y[20]=L("span",null," Open Mainsail ",-1))]),_:2},1040)]),default:v(()=>[Y[21]||(Y[21]=L("span",null," Visit the Mainsail for this printer ",-1))]),_:1})):ve("",!0),h(xt,{location:"left"},{activator:v(({props:se})=>[h(Fe,me({class:"extra-dense-list-item",link:""},se,{onClick:Y[4]||(Y[4]=$t(oe=>B(),["prevent","stop"]))}),{prepend:v(()=>[h(lt,{size:i.value,color:"grey-lighten-1"},{default:v(()=>[h(X,{color:b.value?"primary":"green"},{default:v(()=>Y[22]||(Y[22]=[_(" dns ")])),_:1},8,["color"])]),_:1},8,["size"])]),default:v(()=>[b.value?($(),we("span",q6," Disable Printer Location ")):b.value?ve("",!0):($(),we("span",W6," Enable Printer Location "))]),_:2},1040)]),default:v(()=>[Y[23]||(Y[23]=L("span",null," Deactivate connection, without impacting print ",-1))]),_:1}),h(xt,{location:"left"},{activator:v(({props:se})=>[h(Fe,me({class:"extra-dense-list-item",link:""},se,{onClick:Y[5]||(Y[5]=$t(oe=>W(),["prevent","stop"]))}),{default:v(()=>[h(lt,{size:i.value,color:"grey-lighten-1"},{default:v(()=>[h(X,{color:w.value?"green":"primary"},{default:v(()=>Y[24]||(Y[24]=[_(" construction ")])),_:1},8,["color"])]),_:1},8,["size"]),w.value?w.value?($(),we("span",K6," Complete Maintenance ")):ve("",!0):($(),we("span",G6," Enable Maintenance "))]),_:2},1040)]),default:v(()=>[Y[25]||(Y[25]=L("span",null," Deactivate, set under repair, without impacting print ",-1))]),_:1}),h(xt,{location:"left"},{activator:v(({props:se})=>[h(Fe,me({class:"extra-dense-list-item",link:""},se,{onClick:Y[6]||(Y[6]=$t(oe=>Z(),["prevent","stop"]))}),{default:v(()=>[h(lt,{size:i.value},{default:v(()=>[h(X,{color:w.value?"green":"primary",class:"grey-lighten-1"},{default:v(()=>Y[26]||(Y[26]=[_(" autorenew ")])),_:1},8,["color"])]),_:1},8,["size"]),Y[27]||(Y[27]=L("span",null,[_(" Refresh State "),L("small",null," - this does not affect the print! ")],-1))]),_:2},1040)]),default:v(()=>[Y[28]||(Y[28]=L("span",null," Let FDM Monster know you are experiencing inconsistencies, reset all volatile states ",-1))]),_:1}),h(yn),h(hs,{inset:""},{default:v(()=>Y[29]||(Y[29]=[_(" Commands ")])),_:1}),h(xt,{location:"left"},{activator:v(({props:se})=>{var oe;return[h(Fe,me({disabled:!((oe=d.value)!=null&&oe.enabled)||!f.value,class:"extra-dense-list-item",link:""},se,{onClick:Y[7]||(Y[7]=$t(ge=>j(),["prevent","stop"]))}),{default:v(()=>[h(lt,{size:i.value},{default:v(()=>[h(X,null,{default:v(()=>Y[30]||(Y[30]=[_(" usb ")])),_:1})]),_:1},8,["size"]),E.value?($(),we("span",Y6," Disconnect USB & Stop Print ")):y.value?($(),we("span",X6," Disconnect USB ")):($(),we("span",Q6," Connect USB "))]),_:2},1040,["disabled"])]}),default:v(()=>[Y[31]||(Y[31]=L("span",null," Disconnect USB, disrupting any print ",-1))]),_:1}),ie(s).hasFeature("pauseResumePrinterCommand")?($(),Q(xt,{key:1,location:"left"},{activator:v(({props:se})=>[h(Fe,me({disabled:!f.value||!S.value,class:"extra-dense-list-item",link:""},se,{onClick:Y[8]||(Y[8]=$t(oe=>T.value?pe():K(),["prevent","stop"]))}),{default:v(()=>[h(lt,{size:i.value},{default:v(()=>[T.value?ve("",!0):($(),Q(X,{key:0},{default:v(()=>Y[32]||(Y[32]=[_(" pause ")])),_:1})),T.value?($(),Q(X,{key:1},{default:v(()=>Y[33]||(Y[33]=[_(" play_circle_outline ")])),_:1})):ve("",!0)]),_:1},8,["size"]),_(" "+ae(T.value?"Resume print":"Pause print"),1)]),_:2},1040,["disabled"])]),default:v(()=>[Y[34]||(Y[34]=L("span",null," Send Pause or Resume command ",-1))]),_:1})):ve("",!0),h(xt,{location:"left"},{activator:v(({props:se})=>[h(Fe,me({disabled:!E.value,class:"extra-dense-list-item",link:""},se,{onClick:Y[9]||(Y[9]=$t(oe=>q(),["prevent","stop"]))}),{default:v(()=>[h(lt,{size:i.value},{default:v(()=>[h(X,null,{default:v(()=>Y[35]||(Y[35]=[_(" stop ")])),_:1})]),_:1},8,["size"]),Y[36]||(Y[36]=_(" Cancel print "))]),_:2},1040,["disabled"])]),default:v(()=>[Y[37]||(Y[37]=L("span",null," Cancel print gracefully ",-1))]),_:1}),h(xt,{location:"left"},{activator:v(({props:se})=>[h(Fe,me({disabled:!C.value,class:"extra-dense-list-item",link:""},se,{onClick:Y[10]||(Y[10]=$t(oe=>ue(),["prevent","stop"]))}),{default:v(()=>[h(lt,{size:i.value},{default:v(()=>[h(X,null,{default:v(()=>Y[38]||(Y[38]=[_(" delete ")])),_:1})]),_:1},8,["size"]),Y[39]||(Y[39]=_(" Delete files "))]),_:2},1040,["disabled"])]),default:v(()=>[Y[40]||(Y[40]=L("span",null," Clear all files present on OctoPrint (local) ",-1))]),_:1}),h(xt,{location:"left"},{activator:v(({props:se})=>[h(Fe,me({class:"extra-dense-list-item",link:""},se,{onClick:Y[11]||(Y[11]=$t(oe=>M(),["prevent","stop"]))}),{default:v(()=>[h(lt,{size:i.value},{default:v(()=>[h(X,null,{default:v(()=>Y[41]||(Y[41]=[_(" refresh ")])),_:1})]),_:1},8,["size"]),Y[42]||(Y[42]=_(" Refresh files "))]),_:2},1040)]),default:v(()=>[Y[43]||(Y[43]=L("span",null," Rebuild the file list on OctoPrint (local) ",-1))]),_:1}),h(xt,{location:"left"},{activator:v(({props:se})=>[h(Fe,me({class:"extra-dense-list-item",link:""},se,{onClick:Y[12]||(Y[12]=$t(oe=>le(),["prevent","stop"]))}),{default:v(()=>[h(lt,{size:i.value},{default:v(()=>[h(X,null,{default:v(()=>Y[44]||(Y[44]=[_(" settings ")])),_:1})]),_:1},8,["size"]),Y[45]||(Y[45]=_(" Settings "))]),_:2},1040)]),default:v(()=>[Y[46]||(Y[46]=L("span",null," Edit the printer settings ",-1))]),_:1})]),_:1})),[[ze,{printers:[d.value]}]]),h(yn),en(($(),Q(Kt,{density:"compact"},{default:v(()=>[h(hs,{inset:""},{default:v(()=>Y[47]||(Y[47]=[_(" Files - drag 'n drop! ")])),_:1}),h(ct,{modelValue:o.value,"onUpdate:modelValue":Y[13]||(Y[13]=se=>o.value=se),class:"ml-5 mr-5",clearable:"",label:"Search files...","prepend-icon":"search"},null,8,["modelValue"]),P.value.length?ve("",!0):($(),Q(Fe,{key:0},{default:v(()=>[h(lt,{size:i.value},{default:v(()=>[h(X,null,{default:v(()=>Y[48]||(Y[48]=[_(" clear ")])),_:1})]),_:1},8,["size"]),h(ht,null,{default:v(()=>Y[49]||(Y[49]=[_(" No files to show ")])),_:1})]),_:1})),u.value?($(),Q(lu,{key:1,indeterminate:""})):ve("",!0),($(!0),we(Re,null,Zt(P.value,(se,oe)=>($(),Q(Fe,{key:oe,density:"compact",link:"",style:{"padding-top":"0"}},{default:v(()=>[h(lt,{size:i.value},{default:v(()=>[h(xt,{location:"left"},{activator:v(({props:ge})=>[h(re,me({ref_for:!0},ge,{onClick:Ee=>be(se.path)}),{default:v(()=>[h(X,null,{default:v(()=>Y[50]||(Y[50]=[_(" download ")])),_:1})]),_:2},1040,["onClick"])]),default:v(()=>[Y[51]||(Y[51]=L("span",null," Download GCode ",-1))]),_:2},1024)]),_:2},1032,["size"]),h(sd,null,{default:v(()=>[h(xt,{location:"left"},{activator:v(({props:ge})=>[h(re,me({disabled:D(se),icon:"",ref_for:!0},ge,{onClick:Ee=>J(se)}),{default:v(()=>[h(X,null,{default:v(()=>Y[52]||(Y[52]=[_(" play_arrow ")])),_:1})]),_:2},1040,["disabled","onClick"])]),default:v(()=>[Y[53]||(Y[53]=L("span",null," Select & Print ",-1))]),_:2},1024)]),_:2},1024),h(xt,{location:"left"},{activator:v(({props:ge})=>[L("span",me({class:{"current-file-print":D(se)},ref_for:!0},ge),ae(se.path),17)]),default:v(()=>[L("span",null,[_(" File: "+ae(se.path)+" ",1),Y[54]||(Y[54]=L("br",null,null,-1)),_(" Size: "+ae(ie(SA)(se.size))+" ",1),Y[55]||(Y[55]=L("br",null,null,-1)),L("strong",null,ae(D(se)?"Printing":"Unused"),1)])]),_:2},1024),h(sd,null,{default:v(()=>[h(xt,{location:"left"},{activator:v(({props:ge})=>[h(re,me({disabled:D(se),ref_for:!0},ge,{onClick:Ee=>O(se)}),{default:v(()=>[h(X,{color:"grey-lighten-1"},{default:v(()=>Y[56]||(Y[56]=[_(" delete ")])),_:1})]),_:2},1040,["disabled","onClick"])]),default:v(()=>[Y[57]||(Y[57]=L("span",null," Delete file ",-1))]),_:2},1024)]),_:2},1024)]),_:2},1024))),128))]),_:1})),[[ze,{printers:[d.value]}]])]}),_:1},8,["modelValue"])}}});class od extends yr{static async restartServer(){const t=Oe.serverRestartCommandRoute;return await this.post(t)}static async downloadYamlExport(t){const r=await(await Xn()).request({method:"POST",url:"api/server/export-printers-floors-yaml",data:t,responseType:"arraybuffer"});py(r.data,"export-fdm-monster-"+Date.now()+".yaml")}static async uploadAndImportYaml(t){const n=new FormData;return n.append("file",t),await this.postUpload("api/server/import-printers-floors-yaml",n,{})}static async downloadLogDump(){const n=await(await Xn()).request({method:"POST",url:"api/server/dump-fdm-monster-logs",responseType:"arraybuffer"});py(n.data,"logs-fdm-monster-"+Date.now()+".zip")}static async clearLogFilesOlderThanWeek(){return await this.delete("api/server/clear-outdated-fdm-monster-logs")}}const NA=Symbol.for("vuetify:selection-control-group"),Mw=de({color:String,disabled:{type:Boolean,default:null},defaultsTarget:String,error:Boolean,id:String,inline:Boolean,falseIcon:Je,trueIcon:Je,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:Wo},...Ve(),...Lr(),...Dt()},"SelectionControlGroup"),Z6=de({...Mw({defaultsTarget:"VSelectionControl"})},"VSelectionControlGroup"),eG=xe()({name:"VSelectionControlGroup",props:Z6(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const r=st(e,"modelValue"),s=vr(),i=R(()=>e.id||`v-selection-control-group-${s}`),o=R(()=>e.name||i.value),a=new Set;return Gt(NA,{modelValue:r,forceUpdate:()=>{a.forEach(l=>l())},onForceUpdate:l=>{a.add(l),Sn(()=>{a.delete(l)})}}),Dr({[e.defaultsTarget]:{color:Te(e,"color"),disabled:Te(e,"disabled"),density:Te(e,"density"),error:Te(e,"error"),inline:Te(e,"inline"),modelValue:r,multiple:R(()=>!!e.multiple||e.multiple==null&&Array.isArray(r.value)),name:o,falseIcon:Te(e,"falseIcon"),trueIcon:Te(e,"trueIcon"),readonly:Te(e,"readonly"),ripple:Te(e,"ripple"),type:Te(e,"type"),valueComparator:Te(e,"valueComparator")}}),Ie(()=>{var l;return h("div",{class:["v-selection-control-group",{"v-selection-control-group--inline":e.inline},e.class],style:e.style,role:e.type==="radio"?"radiogroup":void 0},[(l=n.default)==null?void 0:l.call(n)])}),{}}}),vm=de({label:String,baseColor:String,trueValue:null,falseValue:null,value:null,...Ve(),...Mw()},"VSelectionControl");function tG(e){const t=Ye(NA,void 0),{densityClasses:n}=ys(e),r=st(e,"modelValue"),s=R(()=>e.trueValue!==void 0?e.trueValue:e.value!==void 0?e.value:!0),i=R(()=>e.falseValue!==void 0?e.falseValue:!1),o=R(()=>!!e.multiple||e.multiple==null&&Array.isArray(r.value)),a=R({get(){const p=t?t.modelValue.value:r.value;return o.value?Dn(p).some(g=>e.valueComparator(g,s.value)):e.valueComparator(p,s.value)},set(p){if(e.readonly)return;const g=p?s.value:i.value;let m=g;o.value&&(m=p?[...Dn(r.value),g]:Dn(r.value).filter(y=>!e.valueComparator(y,s.value))),t?t.modelValue.value=m:r.value=m}}),{textColorClasses:l,textColorStyles:u}=Is(R(()=>{if(!(e.error||e.disabled))return a.value?e.color:e.baseColor})),{backgroundColorClasses:d,backgroundColorStyles:c}=pr(R(()=>a.value&&!e.error&&!e.disabled?e.color:e.baseColor)),f=R(()=>a.value?e.trueIcon:e.falseIcon);return{group:t,densityClasses:n,trueValue:s,falseValue:i,model:a,textColorClasses:l,textColorStyles:u,backgroundColorClasses:d,backgroundColorStyles:c,icon:f}}const Ga=xe()({name:"VSelectionControl",directives:{Ripple:Iu},inheritAttrs:!1,props:vm(),emits:{"update:modelValue":e=>!0},setup(e,t){let{attrs:n,slots:r}=t;const{group:s,densityClasses:i,icon:o,model:a,textColorClasses:l,textColorStyles:u,backgroundColorClasses:d,backgroundColorStyles:c,trueValue:f}=tG(e),p=vr(),g=Me(!1),m=Me(!1),y=U(),b=R(()=>e.id||`input-${p}`),w=R(()=>!e.disabled&&!e.readonly);s==null||s.onForceUpdate(()=>{y.value&&(y.value.checked=a.value)});function S(C){w.value&&(g.value=!0,Ih(C.target,":focus-visible")!==!1&&(m.value=!0))}function P(){g.value=!1,m.value=!1}function E(C){C.stopPropagation()}function T(C){if(!w.value){y.value&&(y.value.checked=a.value);return}e.readonly&&s&&Ot(()=>s.forceUpdate()),a.value=C.target.checked}return Ie(()=>{var M,O;const C=r.label?r.label({label:e.label,props:{for:b.value}}):e.label,[k,x]=Za(n),I=h("input",me({ref:y,checked:a.value,disabled:!!e.disabled,id:b.value,onBlur:P,onFocus:S,onInput:T,"aria-disabled":!!e.disabled,"aria-label":e.label,type:e.type,value:f.value,name:e.name,"aria-checked":e.type==="checkbox"?a.value:void 0},x),null);return h("div",me({class:["v-selection-control",{"v-selection-control--dirty":a.value,"v-selection-control--disabled":e.disabled,"v-selection-control--error":e.error,"v-selection-control--focused":g.value,"v-selection-control--focus-visible":m.value,"v-selection-control--inline":e.inline},i.value,e.class]},k,{style:e.style}),[h("div",{class:["v-selection-control__wrapper",l.value],style:u.value},[(M=r.default)==null?void 0:M.call(r,{backgroundColorClasses:d,backgroundColorStyles:c}),en(h("div",{class:["v-selection-control__input"]},[((O=r.input)==null?void 0:O.call(r,{model:a,textColorClasses:l,textColorStyles:u,backgroundColorClasses:d,backgroundColorStyles:c,inputNode:I,icon:o.value,props:{onFocus:S,onBlur:P,id:b.value}}))??h(Re,null,[o.value&&h(X,{key:"icon",icon:o.value},null),I])]),[[mr("ripple"),e.ripple&&[!e.disabled&&!e.readonly,null,["center","circle"]]]])]),C&&h(Aw,{for:b.value,onClick:E},{default:()=>[C]})])}),{isFocused:g,input:y}}}),BA=de({indeterminate:Boolean,indeterminateIcon:{type:Je,default:"$checkboxIndeterminate"},...vm({falseIcon:"$checkboxOff",trueIcon:"$checkboxOn"})},"VCheckboxBtn"),yu=xe()({name:"VCheckboxBtn",props:BA(),emits:{"update:modelValue":e=>!0,"update:indeterminate":e=>!0},setup(e,t){let{slots:n}=t;const r=st(e,"indeterminate"),s=st(e,"modelValue");function i(l){r.value&&(r.value=!1)}const o=R(()=>r.value?e.indeterminateIcon:e.falseIcon),a=R(()=>r.value?e.indeterminateIcon:e.trueIcon);return Ie(()=>{const l=Ds(Ga.filterProps(e),["modelValue"]);return h(Ga,me(l,{modelValue:s.value,"onUpdate:modelValue":[u=>s.value=u,i],class:["v-checkbox-btn",e.class],style:e.style,type:"checkbox",falseIcon:o.value,trueIcon:a.value,"aria-checked":r.value?"mixed":void 0}),n)}),{}}}),nG=de({...ol(),...Ds(BA(),["inline"])},"VCheckbox"),On=xe()({name:"VCheckbox",inheritAttrs:!1,props:nG(),emits:{"update:modelValue":e=>!0,"update:focused":e=>!0},setup(e,t){let{attrs:n,slots:r}=t;const s=st(e,"modelValue"),{isFocused:i,focus:o,blur:a}=Uu(e),l=vr(),u=R(()=>e.id||`checkbox-${l}`);return Ie(()=>{const[d,c]=Za(n),f=gs.filterProps(e),p=yu.filterProps(e);return h(gs,me({class:["v-checkbox",e.class]},d,f,{modelValue:s.value,"onUpdate:modelValue":g=>s.value=g,id:u.value,focused:i.value,style:e.style}),{...r,default:g=>{let{id:m,messagesId:y,isDisabled:b,isReadonly:w,isValid:S}=g;return h(yu,me(p,{id:m.value,"aria-describedby":y.value,disabled:b.value,readonly:w.value},c,{error:S.value===!1,modelValue:s.value,"onUpdate:modelValue":P=>s.value=P,onFocus:o,onBlur:a}),r)}})}),{}}}),rG=de({chips:Boolean,counter:Boolean,counterSizeString:{type:String,default:"$vuetify.fileInput.counterSize"},counterString:{type:String,default:"$vuetify.fileInput.counter"},hideInput:Boolean,multiple:Boolean,showSize:{type:[Boolean,Number,String],default:!1,validator:e=>typeof e=="boolean"||[1e3,1024].includes(Number(e))},...ol({prependIcon:"$file"}),modelValue:{type:[Array,Object],default:e=>e.multiple?[]:null,validator:e=>Dn(e).every(t=>t!=null&&typeof t=="object")},...mm({clearable:!0})},"VFileInput"),sG=xe()({name:"VFileInput",inheritAttrs:!1,props:rG(),emits:{"click:control":e=>!0,"mousedown:control":e=>!0,"update:focused":e=>!0,"update:modelValue":e=>!0},setup(e,t){let{attrs:n,emit:r,slots:s}=t;const{t:i}=es(),o=st(e,"modelValue",e.modelValue,x=>Dn(x),x=>!e.multiple&&Array.isArray(x)?x[0]:x),{isFocused:a,focus:l,blur:u}=Uu(e),d=R(()=>typeof e.showSize!="boolean"?e.showSize:void 0),c=R(()=>(o.value??[]).reduce((x,I)=>{let{size:M=0}=I;return x+M},0)),f=R(()=>k_(c.value,d.value)),p=R(()=>(o.value??[]).map(x=>{const{name:I="",size:M=0}=x;return e.showSize?`${I} (${k_(M,d.value)})`:I})),g=R(()=>{var I;const x=((I=o.value)==null?void 0:I.length)??0;return e.showSize?i(e.counterSizeString,x,f.value):i(e.counterString,x)}),m=U(),y=U(),b=U(),w=R(()=>a.value||e.active),S=R(()=>["plain","underlined"].includes(e.variant));function P(){var x;b.value!==document.activeElement&&((x=b.value)==null||x.focus()),a.value||l()}function E(x){var I;(I=b.value)==null||I.click()}function T(x){r("mousedown:control",x)}function C(x){var I;(I=b.value)==null||I.click(),r("click:control",x)}function k(x){x.stopPropagation(),P(),Ot(()=>{o.value=[],Ib(e["onClick:clear"],x)})}return Ce(o,x=>{(!Array.isArray(x)||!x.length)&&b.value&&(b.value.value="")}),Ie(()=>{const x=!!(s.counter||e.counter),I=!!(x||s.details),[M,O]=Za(n),{modelValue:A,...D}=gs.filterProps(e),V=Ow(e);return h(gs,me({ref:m,modelValue:o.value,"onUpdate:modelValue":H=>o.value=H,class:["v-file-input",{"v-file-input--chips":!!e.chips,"v-file-input--hide":e.hideInput,"v-input--plain-underlined":S.value},e.class],style:e.style,"onClick:prepend":E},M,D,{centerAffix:!S.value,focused:a.value}),{...s,default:H=>{let{id:G,isDisabled:j,isDirty:B,isReadonly:W,isValid:Z}=H;return h(gm,me({ref:y,"prepend-icon":e.prependIcon,onMousedown:T,onClick:C,"onClick:clear":k,"onClick:prependInner":e["onClick:prependInner"],"onClick:appendInner":e["onClick:appendInner"]},V,{id:G.value,active:w.value||B.value,dirty:B.value||e.dirty,disabled:j.value,focused:a.value,error:Z.value===!1}),{...s,default:q=>{var ue;let{props:{class:K,...pe}}=q;return h(Re,null,[h("input",me({ref:b,type:"file",readonly:W.value,disabled:j.value,multiple:e.multiple,name:e.name,onClick:le=>{le.stopPropagation(),W.value&&le.preventDefault(),P()},onChange:le=>{if(!le.target)return;const J=le.target;o.value=[...J.files??[]]},onFocus:P,onBlur:u},pe,O),null),h("div",{class:K},[!!((ue=o.value)!=null&&ue.length)&&!e.hideInput&&(s.selection?s.selection({fileNames:p.value,totalBytes:c.value,totalBytesReadable:f.value}):e.chips?p.value.map(le=>h(kn,{key:le,size:"small",text:le},null)):p.value.join(", "))])])}})},details:I?H=>{var G,j;return h(Re,null,[(G=s.details)==null?void 0:G.call(s,H),x&&h(Re,null,[h("span",null,null),h(Iw,{active:!!((j=o.value)!=null&&j.length),value:g.value,disabled:e.disabled},s.counter)])])}:void 0})}),Wi({},m,y,b)}}),iG=de({...vm({falseIcon:"$radioOff",trueIcon:"$radioOn"})},"VRadio"),wy=xe()({name:"VRadio",props:iG(),setup(e,t){let{slots:n}=t;return Ie(()=>{const r=Ga.filterProps(e);return h(Ga,me(r,{class:["v-radio",e.class],style:e.style,type:"radio"}),n)}),{}}}),oG=de({height:{type:[Number,String],default:"auto"},...ol(),...Ds(Mw(),["multiple"]),trueIcon:{type:Je,default:"$radioOn"},falseIcon:{type:Je,default:"$radioOff"},type:{type:String,default:"radio"}},"VRadioGroup"),VA=xe()({name:"VRadioGroup",inheritAttrs:!1,props:oG(),emits:{"update:modelValue":e=>!0},setup(e,t){let{attrs:n,slots:r}=t;const s=vr(),i=R(()=>e.id||`radio-group-${s}`),o=st(e,"modelValue");return Ie(()=>{const[a,l]=Za(n),u=gs.filterProps(e),d=Ga.filterProps(e),c=r.label?r.label({label:e.label,props:{for:i.value}}):e.label;return h(gs,me({class:["v-radio-group",e.class],style:e.style},a,u,{modelValue:o.value,"onUpdate:modelValue":f=>o.value=f,id:i.value}),{...r,default:f=>{let{id:p,messagesId:g,isDisabled:m,isReadonly:y}=f;return h(Re,null,[c&&h(Aw,{id:p.value},{default:()=>[c]}),h(eG,me(d,{id:p.value,"aria-describedby":g.value,defaultsTarget:"VRadio",trueIcon:e.trueIcon,falseIcon:e.falseIcon,type:e.type,disabled:m.value,readonly:y.value,"aria-labelledby":c?p.value:void 0,multiple:!1},l,{modelValue:o.value,"onUpdate:modelValue":b=>o.value=b}),r)])}})}),{}}}),aG=de({autoGrow:Boolean,autofocus:Boolean,counter:[Boolean,Number,String],counterValue:Function,prefix:String,placeholder:String,persistentPlaceholder:Boolean,persistentCounter:Boolean,noResize:Boolean,rows:{type:[Number,String],default:5,validator:e=>!isNaN(parseFloat(e))},maxRows:{type:[Number,String],validator:e=>!isNaN(parseFloat(e))},suffix:String,modelModifiers:Object,...ol(),...mm()},"VTextarea"),Dw=xe()({name:"VTextarea",directives:{Intersect:kw},inheritAttrs:!1,props:aG(),emits:{"click:control":e=>!0,"mousedown:control":e=>!0,"update:focused":e=>!0,"update:modelValue":e=>!0},setup(e,t){let{attrs:n,emit:r,slots:s}=t;const i=st(e,"modelValue"),{isFocused:o,focus:a,blur:l}=Uu(e),u=R(()=>typeof e.counterValue=="function"?e.counterValue(i.value):(i.value||"").toString().length),d=R(()=>{if(n.maxlength)return n.maxlength;if(!(!e.counter||typeof e.counter!="number"&&typeof e.counter!="string"))return e.counter});function c(M,O){var A,D;!e.autofocus||!M||(D=(A=O[0].target)==null?void 0:A.focus)==null||D.call(A)}const f=U(),p=U(),g=Me(""),m=U(),y=R(()=>e.persistentPlaceholder||o.value||e.active);function b(){var M;m.value!==document.activeElement&&((M=m.value)==null||M.focus()),o.value||a()}function w(M){b(),r("click:control",M)}function S(M){r("mousedown:control",M)}function P(M){M.stopPropagation(),b(),Ot(()=>{i.value="",Ib(e["onClick:clear"],M)})}function E(M){var A;const O=M.target;if(i.value=O.value,(A=e.modelModifiers)!=null&&A.trim){const D=[O.selectionStart,O.selectionEnd];Ot(()=>{O.selectionStart=D[0],O.selectionEnd=D[1]})}}const T=U(),C=U(+e.rows),k=R(()=>["plain","underlined"].includes(e.variant));jn(()=>{e.autoGrow||(C.value=+e.rows)});function x(){e.autoGrow&&Ot(()=>{if(!T.value||!p.value)return;const M=getComputedStyle(T.value),O=getComputedStyle(p.value.$el),A=parseFloat(M.getPropertyValue("--v-field-padding-top"))+parseFloat(M.getPropertyValue("--v-input-padding-top"))+parseFloat(M.getPropertyValue("--v-field-padding-bottom")),D=T.value.scrollHeight,V=parseFloat(M.lineHeight),H=Math.max(parseFloat(e.rows)*V+A,parseFloat(O.getPropertyValue("--v-input-control-height"))),G=parseFloat(e.maxRows)*V+A||1/0,j=Rr(D??0,H,G);C.value=Math.floor((j-A)/V),g.value=Ne(j)})}St(x),Ce(i,x),Ce(()=>e.rows,x),Ce(()=>e.maxRows,x),Ce(()=>e.density,x);let I;return Ce(T,M=>{M?(I=new ResizeObserver(x),I.observe(T.value)):I==null||I.disconnect()}),Tn(()=>{I==null||I.disconnect()}),Ie(()=>{const M=!!(s.counter||e.counter||e.counterValue),O=!!(M||s.details),[A,D]=Za(n),{modelValue:V,...H}=gs.filterProps(e),G=Ow(e);return h(gs,me({ref:f,modelValue:i.value,"onUpdate:modelValue":j=>i.value=j,class:["v-textarea v-text-field",{"v-textarea--prefixed":e.prefix,"v-textarea--suffixed":e.suffix,"v-text-field--prefixed":e.prefix,"v-text-field--suffixed":e.suffix,"v-textarea--auto-grow":e.autoGrow,"v-textarea--no-resize":e.noResize||e.autoGrow,"v-input--plain-underlined":k.value},e.class],style:e.style},A,H,{centerAffix:C.value===1&&!k.value,focused:o.value}),{...s,default:j=>{let{id:B,isDisabled:W,isDirty:Z,isReadonly:q,isValid:K}=j;return h(gm,me({ref:p,style:{"--v-textarea-control-height":g.value},onClick:w,onMousedown:S,"onClick:clear":P,"onClick:prependInner":e["onClick:prependInner"],"onClick:appendInner":e["onClick:appendInner"]},G,{id:B.value,active:y.value||Z.value,centerAffix:C.value===1&&!k.value,dirty:Z.value||e.dirty,disabled:W.value,focused:o.value,error:K.value===!1}),{...s,default:pe=>{let{props:{class:ue,...le}}=pe;return h(Re,null,[e.prefix&&h("span",{class:"v-text-field__prefix"},[e.prefix]),en(h("textarea",me({ref:m,class:ue,value:i.value,onInput:E,autofocus:e.autofocus,readonly:q.value,disabled:W.value,placeholder:e.placeholder,rows:e.rows,name:e.name,onFocus:b,onBlur:l},le,D),null),[[mr("intersect"),{handler:c},null,{once:!0}]]),e.autoGrow&&en(h("textarea",{class:[ue,"v-textarea__sizer"],id:`${le.id}-sizer`,"onUpdate:modelValue":J=>i.value=J,ref:T,readonly:!0,"aria-hidden":"true"},null),[[R$,i.value]]),e.suffix&&h("span",{class:"v-text-field__suffix"},[e.suffix])])}})},details:O?j=>{var B;return h(Re,null,[(B=s.details)==null?void 0:B.call(s,j),M&&h(Re,null,[h("span",null,null),h(Iw,{active:e.persistentCounter||o.value,value:u.value,max:d.value,disabled:e.disabled},s.counter)])])}:void 0})}),Wi({},f,p,m)}}),lG={key:0,class:"pl-2"},uG={key:1},cG=Le({__name:"YamlImportExportDialog",setup(e){const t=Yi(),n=Fn(Jt.YamlImportExport),r=Mt(),s=U(""),i=U(""),o=U(0),a=U(!0),l=U(!0),u=U(!0),d=U(!0),c=U(void 0),f=U(""),p=R(()=>!t.hasFeature("printerGroupsApi")),g=R(()=>!!c.value),m=R(()=>o.value===0),y=async()=>{await t.loadFeatures(),u.value=t.hasFeature("printerGroupsApi")},b=async()=>{l.value&&(d.value=!0),await od.downloadYamlExport({exportPrinters:d.value,exportGroups:u.value,exportFloorGrid:l.value,printerComparisonStrategiesByPriority:["name","url"],exportFloors:a.value,floorComparisonStrategiesByPriority:"floor",notes:f.value}),r.openInfoMessage({title:"Downloaded the YAML file"}),f.value=""},w=async()=>{if(s.value="",i.value="",!c.value){s.value="The import file was not specified";return}try{await od.uploadAndImportYaml(c.value),c.value=void 0,r.openInfoMessage({title:"Imported the YAML file"}),S()}catch(P){s.value="An error occurred uring import",i.value=P.message.toString(),c.value=void 0}},S=()=>{c.value=void 0,n.closeDialog()};return(P,E)=>{const T=gi;return $(),Q(T,{id:ie(n).dialogId,"max-width":"700px",onBeforeOpened:y,onEscape:E[10]||(E[10]=C=>S())},{default:v(()=>[h(yt,{class:"pa-4"},{default:v(()=>[h(an,null,{default:v(()=>E[11]||(E[11]=[L("span",{class:"text-h5"}," YAML export and import ",-1)])),_:1}),h(nn,null,{default:v(()=>[E[18]||(E[18]=L("div",null,"Choose mode:",-1)),h(at,null,{default:v(()=>[E[12]||(E[12]=L("br",null,null,-1)),h(VA,{modelValue:ie(o),"onUpdate:modelValue":E[0]||(E[0]=C=>tt(o)?o.value=C:null),class:"ml-3",inline:""},{default:v(()=>[h(wy,{value:0,label:"Import YAML"}),h(wy,{value:1,label:"Export YAML"})]),_:1},8,["modelValue"])]),_:1}),L("div",null,[ie(m)?($(),we("div",lG,[h(sG,{modelValue:ie(c),"onUpdate:modelValue":E[1]||(E[1]=C=>tt(c)?c.value=C:null),accept:".yaml",label:"Select a YAML file for import *"},null,8,["modelValue"])])):($(),we("div",uG,[h(On,{modelValue:ie(a),"onUpdate:modelValue":E[2]||(E[2]=C=>tt(a)?a.value=C:null),class:"pa-0 ma-0 mt-2 ml-2",label:"Include floors"},null,8,["modelValue"]),h(On,{modelValue:ie(u),"onUpdate:modelValue":E[3]||(E[3]=C=>tt(u)?u.value=C:null),disabled:ie(p),class:"pa-0 ma-0 mt-2 ml-2",label:"Include groups"},null,8,["modelValue","disabled"]),h(On,{modelValue:ie(d),"onUpdate:modelValue":E[4]||(E[4]=C=>tt(d)?d.value=C:null),class:"pa-0 ma-0 ml-2",label:"Include printers"},null,8,["modelValue"]),h(On,{modelValue:ie(l),"onUpdate:modelValue":E[5]||(E[5]=C=>tt(l)?l.value=C:null),class:"pa-0 ma-0 ml-2",label:"Include grid positions (auto-includes printers)"},null,8,["modelValue"]),E[13]||(E[13]=_(" Include notes (for yourself): ")),h(Dw,{modelValue:ie(f),"onUpdate:modelValue":E[6]||(E[6]=C=>tt(f)?f.value=C:null),rows:"1"},null,8,["modelValue"])])),ie(m)?ve("",!0):($(),Q(re,{key:2,onClick:E[7]||(E[7]=C=>b())},{default:v(()=>[h(X,null,{default:v(()=>E[14]||(E[14]=[_("download")])),_:1}),E[15]||(E[15]=_(" Export YAML file "))]),_:1})),ie(m)?($(),Q(re,{key:3,disabled:!ie(g),onClick:E[8]||(E[8]=C=>w())},{default:v(()=>[h(X,null,{default:v(()=>E[16]||(E[16]=[_("upload")])),_:1}),E[17]||(E[17]=_(" Import YAML data "))]),_:1},8,["disabled"])):ve("",!0)])]),_:1}),h(Nn,null,{default:v(()=>[E[20]||(E[20]=L("em",{class:"text-red"}," * indicates required field ",-1)),h(wn),h(re,{variant:"text",onClick:E[9]||(E[9]=C=>S())},{default:v(()=>E[19]||(E[19]=[_(" Close ")])),_:1})]),_:1})]),_:1})]),_:1},8,["id"])}}}),dG=Le({__name:"BatchJsonCreateDialog",setup(e){const t=Fn(Jt.BatchJsonCreate),n={json:""};let r=0;const s=async()=>{const l=JSON.parse(n.json);return Array.isArray(l)?l:[]},i=async()=>{r=(await s()).length},o=async()=>{const l=await s(),u=l.length;confirm(`Are you sure to import ${u} printers?`)&&(l.forEach(c=>{c._id&&delete c._id,c.apikey&&(c.apiKey=c.apikey,delete c.apikey),c.settingsApperance&&(c.settingsAppearance=c.settingsApperance,delete c.settingsApperance),c.name&&(c.settingsAppearance||(c.settingsAppearance={}),c.settingsAppearance.name=c.name,delete c.name)}),await Wt.batchImportPrinters(l)),a()},a=()=>{t.closeDialog()};return(l,u)=>{const d=gi;return $(),Q(d,{id:ie(t).dialogId,"max-width":"700px",onEscape:u[4]||(u[4]=c=>a())},{default:v(()=>[h(yt,{class:"pa-4"},{default:v(()=>[h(an,null,{default:v(()=>u[5]||(u[5]=[L("span",{class:"text-h5"}," Batch Import JSON printers ",-1)])),_:1}),h(nn,null,{default:v(()=>[h(at,null,{default:v(()=>[h(Ue,{cols:"12"},{default:v(()=>[u[7]||(u[7]=_(' v-slot="{ errors }" name="JSON" rules="required|json"> ')),h(Dw,{modelValue:n.json,"onUpdate:modelValue":u[0]||(u[0]=c=>n.json=c),"data-vv-validate-on":"change|blur",rows:"10",onChange:u[1]||(u[1]=c=>i())},{label:v(()=>u[6]||(u[6]=[L("div",null,[_("JSON import "),L("small",null," (optional) ")],-1)])),_:1},8,["modelValue"]),_(" "+ae(ie(r))+" printers found ",1)]),_:1})]),_:1}),h(re,{class:"mt-2"},{default:v(()=>u[8]||(u[8]=[_(" Validate printers ")])),_:1})]),_:1}),h(Nn,null,{default:v(()=>[u[11]||(u[11]=L("em",{class:"text-red"}," * indicates required field ",-1)),h(wn),h(re,{variant:"text",onClick:u[2]||(u[2]=c=>a())},{default:v(()=>u[9]||(u[9]=[_(" Close ")])),_:1}),h(re,{color:"blue-darken-1",variant:"text",onClick:u[3]||(u[3]=c=>o())},{default:v(()=>u[10]||(u[10]=[_(" Create ")])),_:1})]),_:1})]),_:1})]),_:1},8,["id"])}}}),fG=de({id:String,submenu:Boolean,...Ds(Od({closeDelay:250,closeOnContentClick:!0,locationStrategy:"connected",location:void 0,openDelay:300,scrim:!1,scrollStrategy:"reposition",transition:{component:$b}}),["absolute"])},"VMenu"),Wd=xe()({name:"VMenu",props:fG(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const r=st(e,"modelValue"),{scopeId:s}=Au(),{isRtl:i}=Nr(),o=vr(),a=R(()=>e.id||`v-menu-${o}`),l=U(),u=Ye(Pv,null),d=Me(new Set);Gt(Pv,{register(){d.value.add(o)},unregister(){d.value.delete(o)},closeParents(y){setTimeout(()=>{var b;!d.value.size&&!e.persistent&&(y==null||(b=l.value)!=null&&b.contentEl&&!lF(y,l.value.contentEl))&&(r.value=!1,u==null||u.closeParents())},40)}}),Tn(()=>{u==null||u.unregister(),document.removeEventListener("focusin",c)}),gb(()=>r.value=!1);async function c(y){var S,P,E;const b=y.relatedTarget,w=y.target;await Ot(),r.value&&b!==w&&((S=l.value)!=null&&S.contentEl)&&((P=l.value)!=null&&P.globalTop)&&![document,l.value.contentEl].includes(w)&&!l.value.contentEl.contains(w)&&((E=Hc(l.value.contentEl)[0])==null||E.focus())}Ce(r,y=>{y?(u==null||u.register(),kt&&document.addEventListener("focusin",c,{once:!0})):(u==null||u.unregister(),kt&&document.removeEventListener("focusin",c))},{immediate:!0});function f(y){u==null||u.closeParents(y)}function p(y){var b,w,S,P,E;if(!e.disabled)if(y.key==="Tab"||y.key==="Enter"&&!e.closeOnContentClick){if(y.key==="Enter"&&(y.target instanceof HTMLTextAreaElement||y.target instanceof HTMLInputElement&&y.target.closest("form")))return;y.key==="Enter"&&y.preventDefault(),gP(Hc((b=l.value)==null?void 0:b.contentEl,!1),y.shiftKey?"prev":"next",C=>C.tabIndex>=0)||(r.value=!1,(S=(w=l.value)==null?void 0:w.activatorEl)==null||S.focus())}else e.submenu&&y.key===(i.value?"ArrowRight":"ArrowLeft")&&(r.value=!1,(E=(P=l.value)==null?void 0:P.activatorEl)==null||E.focus())}function g(y){var w;if(e.disabled)return;const b=(w=l.value)==null?void 0:w.contentEl;b&&r.value?y.key==="ArrowDown"?(y.preventDefault(),y.stopImmediatePropagation(),kc(b,"next")):y.key==="ArrowUp"?(y.preventDefault(),y.stopImmediatePropagation(),kc(b,"prev")):e.submenu&&(y.key===(i.value?"ArrowRight":"ArrowLeft")?r.value=!1:y.key===(i.value?"ArrowLeft":"ArrowRight")&&(y.preventDefault(),kc(b,"first"))):(e.submenu?y.key===(i.value?"ArrowLeft":"ArrowRight"):["ArrowDown","ArrowUp"].includes(y.key))&&(r.value=!0,y.preventDefault(),setTimeout(()=>setTimeout(()=>g(y))))}const m=R(()=>me({"aria-haspopup":"menu","aria-expanded":String(r.value),"aria-owns":a.value,onKeydown:g},e.activatorProps));return Ie(()=>{const y=Ni.filterProps(e);return h(Ni,me({ref:l,id:a.value,class:["v-menu",e.class],style:e.style},y,{modelValue:r.value,"onUpdate:modelValue":b=>r.value=b,absolute:!0,activatorProps:m.value,location:e.location??(e.submenu?"end":"bottom"),"onClick:outside":f,onKeydown:p},s),{activator:n.activator,default:function(){for(var b=arguments.length,w=new Array(b),S=0;S<b;S++)w[S]=arguments[S];return h(At,{root:"VMenu"},{default:()=>{var P;return[(P=n.default)==null?void 0:P.call(n,...w)]}})}})}),Wi({id:a,ΨopenChildren:d},l)}}),hG=de({renderless:Boolean,...Ve()},"VVirtualScrollItem"),pG=xe()({name:"VVirtualScrollItem",inheritAttrs:!1,props:hG(),emits:{"update:height":e=>!0},setup(e,t){let{attrs:n,emit:r,slots:s}=t;const{resizeRef:i,contentRect:o}=Ua(void 0,"border");Ce(()=>{var a;return(a=o.value)==null?void 0:a.height},a=>{a!=null&&r("update:height",a)}),Ie(()=>{var a,l;return e.renderless?h(Re,null,[(a=s.default)==null?void 0:a.call(s,{itemRef:i})]):h("div",me({ref:i,class:["v-virtual-scroll__item",e.class],style:e.style},n),[(l=s.default)==null?void 0:l.call(s)])})}}),mG=-1,gG=1,xg=100,vG=de({itemHeight:{type:[Number,String],default:null},height:[Number,String]},"virtual");function yG(e,t){const n=mi(),r=Me(0);jn(()=>{r.value=parseFloat(e.itemHeight||0)});const s=Me(0),i=Me(Math.ceil((parseInt(e.height)||n.height.value)/(r.value||16))||1),o=Me(0),a=Me(0),l=U(),u=U();let d=0;const{resizeRef:c,contentRect:f}=Ua();jn(()=>{c.value=l.value});const p=R(()=>{var B;return l.value===document.documentElement?n.height.value:((B=f.value)==null?void 0:B.height)||parseInt(e.height)||0}),g=R(()=>!!(l.value&&u.value&&p.value&&r.value));let m=Array.from({length:t.value.length}),y=Array.from({length:t.value.length});const b=Me(0);let w=-1;function S(B){return m[B]||r.value}const P=sF(()=>{const B=performance.now();y[0]=0;const W=t.value.length;for(let Z=1;Z<=W-1;Z++)y[Z]=(y[Z-1]||0)+S(Z-1);b.value=Math.max(b.value,performance.now()-B)},b),E=Ce(g,B=>{B&&(E(),d=u.value.offsetTop,P.immediate(),V(),~w&&Ot(()=>{kt&&window.requestAnimationFrame(()=>{G(w),w=-1})}))});Sn(()=>{P.clear()});function T(B,W){const Z=m[B],q=r.value;r.value=q?Math.min(r.value,W):W,(Z!==W||q!==r.value)&&(m[B]=W,P())}function C(B){return B=Rr(B,0,t.value.length-1),y[B]||0}function k(B){return bG(y,B)}let x=0,I=0,M=0;Ce(p,(B,W)=>{W&&(V(),B<W&&requestAnimationFrame(()=>{I=0,V()}))});function O(){if(!l.value||!u.value)return;const B=l.value.scrollTop,W=performance.now();W-M>500?(I=Math.sign(B-x),d=u.value.offsetTop):I=B-x,x=B,M=W,V()}function A(){!l.value||!u.value||(I=0,M=0,V())}let D=-1;function V(){cancelAnimationFrame(D),D=requestAnimationFrame(H)}function H(){if(!l.value||!p.value)return;const B=x-d,W=Math.sign(I),Z=Math.max(0,B-xg),q=Rr(k(Z),0,t.value.length),K=B+p.value+xg,pe=Rr(k(K)+1,q+1,t.value.length);if((W!==mG||q<s.value)&&(W!==gG||pe>i.value)){const ue=C(s.value)-C(q),le=C(pe)-C(i.value);Math.max(ue,le)>xg?(s.value=q,i.value=pe):(q<=0&&(s.value=q),pe>=t.value.length&&(i.value=pe))}o.value=C(s.value),a.value=C(t.value.length)-C(i.value)}function G(B){const W=C(B);!l.value||B&&!W?w=B:l.value.scrollTop=W}const j=R(()=>t.value.slice(s.value,i.value).map((B,W)=>({raw:B,index:W+s.value})));return Ce(t,()=>{m=Array.from({length:t.value.length}),y=Array.from({length:t.value.length}),P.immediate(),V()},{deep:!0}),{calculateVisibleItems:V,containerRef:l,markerRef:u,computedItems:j,paddingTop:o,paddingBottom:a,scrollToIndex:G,handleScroll:O,handleScrollend:A,handleItemResize:T}}function bG(e,t){let n=e.length-1,r=0,s=0,i=null,o=-1;if(e[n]<t)return n;for(;r<=n;)if(s=r+n>>1,i=e[s],i>t)n=s-1;else if(i<t)o=s,r=s+1;else return i===t?s:r;return o}const wG=de({items:{type:Array,default:()=>[]},renderless:Boolean,...vG(),...Ve(),...$r()},"VVirtualScroll"),SG=xe()({name:"VVirtualScroll",props:wG(),setup(e,t){let{slots:n}=t;const r=sn("VVirtualScroll"),{dimensionStyles:s}=Fr(e),{calculateVisibleItems:i,containerRef:o,markerRef:a,handleScroll:l,handleScrollend:u,handleItemResize:d,scrollToIndex:c,paddingTop:f,paddingBottom:p,computedItems:g}=yG(e,Te(e,"items"));return Qr(()=>e.renderless,()=>{function m(){var w,S;const b=(arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1)?"addEventListener":"removeEventListener";o.value===document.documentElement?(document[b]("scroll",l,{passive:!0}),document[b]("scrollend",u)):((w=o.value)==null||w[b]("scroll",l,{passive:!0}),(S=o.value)==null||S[b]("scrollend",u))}St(()=>{o.value=PP(r.vnode.el,!0),m(!0)}),Sn(m)}),Ie(()=>{const m=g.value.map(y=>h(pG,{key:y.index,renderless:e.renderless,"onUpdate:height":b=>d(y.index,b)},{default:b=>{var w;return(w=n.default)==null?void 0:w.call(n,{item:y.raw,index:y.index,...b})}}));return e.renderless?h(Re,null,[h("div",{ref:a,class:"v-virtual-scroll__spacer",style:{paddingTop:Ne(f.value)}},null),m,h("div",{class:"v-virtual-scroll__spacer",style:{paddingBottom:Ne(p.value)}},null)]):h("div",{ref:o,class:["v-virtual-scroll",e.class],onScrollPassive:l,onScrollend:u,style:[s.value,e.style]},[h("div",{ref:a,class:"v-virtual-scroll__container",style:{paddingTop:Ne(f.value),paddingBottom:Ne(p.value)}},[m])])}),{calculateVisibleItems:i,scrollToIndex:c}}});function _G(e,t){const n=Me(!1);let r;function s(a){cancelAnimationFrame(r),n.value=!0,r=requestAnimationFrame(()=>{r=requestAnimationFrame(()=>{n.value=!1})})}async function i(){await new Promise(a=>requestAnimationFrame(a)),await new Promise(a=>requestAnimationFrame(a)),await new Promise(a=>requestAnimationFrame(a)),await new Promise(a=>{if(n.value){const l=Ce(n,()=>{l(),a()})}else a()})}async function o(a){var d,c;if(a.key==="Tab"&&((d=t.value)==null||d.focus()),!["PageDown","PageUp","Home","End"].includes(a.key))return;const l=(c=e.value)==null?void 0:c.$el;if(!l)return;(a.key==="Home"||a.key==="End")&&l.scrollTo({top:a.key==="Home"?0:l.scrollHeight,behavior:"smooth"}),await i();const u=l.querySelectorAll(":scope > :not(.v-virtual-scroll__spacer)");if(a.key==="PageDown"||a.key==="Home"){const f=l.getBoundingClientRect().top;for(const p of u)if(p.getBoundingClientRect().top>=f){p.focus();break}}else{const f=l.getBoundingClientRect().bottom;for(const p of[...u].reverse())if(p.getBoundingClientRect().bottom<=f){p.focus();break}}}return{onScrollPassive:s,onKeydown:o}}const kG=de({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:Je,default:"$dropdown"},menuProps:{type:Object},multiple:Boolean,noDataText:{type:String,default:"$vuetify.noDataText"},openOnClear:Boolean,itemColor:String,...yA({itemChildren:!1})},"Select"),xG=de({...kG(),...Ds(FA({modelValue:null,role:"combobox"}),["validationValue","dirty","appendInnerIcon"]),...Ou({transition:{component:$b}})},"VSelect"),Bo=xe()({name:"VSelect",props:xG(),emits:{"update:focused":e=>!0,"update:modelValue":e=>!0,"update:menu":e=>!0},setup(e,t){let{slots:n}=t;const{t:r}=es(),s=U(),i=U(),o=U(),a=st(e,"menu"),l=R({get:()=>a.value,set:B=>{var W;a.value&&!B&&((W=i.value)!=null&&W.ΨopenChildren.size)||(a.value=B)}}),{items:u,transformIn:d,transformOut:c}=pW(e),f=st(e,"modelValue",[],B=>d(B===null?[null]:Dn(B)),B=>{const W=c(B);return e.multiple?W:W[0]??null}),p=R(()=>typeof e.counterValue=="function"?e.counterValue(f.value):typeof e.counterValue=="number"?e.counterValue:f.value.length),g=$A(),m=R(()=>f.value.map(B=>B.value)),y=Me(!1),b=R(()=>l.value?e.closeText:e.openText);let w="",S;const P=R(()=>e.hideSelected?u.value.filter(B=>!f.value.some(W=>e.valueComparator(W,B))):u.value),E=R(()=>e.hideNoData&&!P.value.length||e.readonly||(g==null?void 0:g.isReadonly.value)),T=R(()=>{var B;return{...e.menuProps,activatorProps:{...((B=e.menuProps)==null?void 0:B.activatorProps)||{},"aria-haspopup":"listbox"}}}),C=U(),k=_G(C,s);function x(B){e.openOnClear&&(l.value=!0)}function I(){E.value||(l.value=!l.value)}function M(B){E_(B)&&O(B)}function O(B){var K,pe;if(!B.key||e.readonly||g!=null&&g.isReadonly.value)return;["Enter"," ","ArrowDown","ArrowUp","Home","End"].includes(B.key)&&B.preventDefault(),["Enter","ArrowDown"," "].includes(B.key)&&(l.value=!0),["Escape","Tab"].includes(B.key)&&(l.value=!1),B.key==="Home"?(K=C.value)==null||K.focus("first"):B.key==="End"&&((pe=C.value)==null||pe.focus("last"));const W=1e3;if(e.multiple||!E_(B))return;const Z=performance.now();Z-S>W&&(w=""),w+=B.key.toLowerCase(),S=Z;const q=u.value.find(ue=>ue.title.toLowerCase().startsWith(w));if(q!==void 0){f.value=[q];const ue=P.value.indexOf(q);kt&&window.requestAnimationFrame(()=>{var le;ue>=0&&((le=o.value)==null||le.scrollToIndex(ue))})}}function A(B){let W=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;if(!B.props.disabled)if(e.multiple){const Z=f.value.findIndex(K=>e.valueComparator(K.value,B.value)),q=W??!~Z;if(~Z){const K=q?[...f.value,B]:[...f.value];K.splice(Z,1),f.value=K}else q&&(f.value=[...f.value,B])}else{const Z=W!==!1;f.value=Z?[B]:[],Ot(()=>{l.value=!1})}}function D(B){var W;(W=C.value)!=null&&W.$el.contains(B.relatedTarget)||(l.value=!1)}function V(){var B;e.eager&&((B=o.value)==null||B.calculateVisibleItems())}function H(){var B;y.value&&((B=s.value)==null||B.focus())}function G(B){y.value=!0}function j(B){if(B==null)f.value=[];else if(Ih(s.value,":autofill")||Ih(s.value,":-webkit-autofill")){const W=u.value.find(Z=>Z.title===B);W&&A(W)}else s.value&&(s.value.value="")}return Ce(l,()=>{if(!e.hideSelected&&l.value&&f.value.length){const B=P.value.findIndex(W=>f.value.some(Z=>e.valueComparator(Z.value,W.value)));kt&&window.requestAnimationFrame(()=>{var W;B>=0&&((W=o.value)==null||W.scrollToIndex(B))})}}),Ce(()=>e.items,(B,W)=>{l.value||y.value&&!W.length&&B.length&&(l.value=!0)}),Ie(()=>{const B=!!(e.chips||n.chip),W=!!(!e.hideNoData||P.value.length||n["prepend-item"]||n["append-item"]||n["no-data"]),Z=f.value.length>0,q=ct.filterProps(e),K=Z||!y.value&&e.label&&!e.persistentPlaceholder?void 0:e.placeholder;return h(ct,me({ref:s},q,{modelValue:f.value.map(pe=>pe.props.value).join(", "),"onUpdate:modelValue":j,focused:y.value,"onUpdate:focused":pe=>y.value=pe,validationValue:f.externalValue,counterValue:p.value,dirty:Z,class:["v-select",{"v-select--active-menu":l.value,"v-select--chips":!!e.chips,[`v-select--${e.multiple?"multiple":"single"}`]:!0,"v-select--selected":f.value.length,"v-select--selection-slot":!!n.selection},e.class],style:e.style,inputmode:"none",placeholder:K,"onClick:clear":x,"onMousedown:control":I,onBlur:D,onKeydown:O,"aria-label":r(b.value),title:r(b.value)}),{...n,default:()=>h(Re,null,[h(Wd,me({ref:i,modelValue:l.value,"onUpdate:modelValue":pe=>l.value=pe,activator:"parent",contentClass:"v-select__content",disabled:E.value,eager:e.eager,maxHeight:310,openOnClick:!1,closeOnContentClick:!1,transition:e.transition,onAfterEnter:V,onAfterLeave:H},T.value),{default:()=>[W&&h(Kt,me({ref:C,selected:m.value,selectStrategy:e.multiple?"independent":"single-independent",onMousedown:pe=>pe.preventDefault(),onKeydown:M,onFocusin:G,tabindex:"-1","aria-live":"polite",color:e.itemColor??e.color},k,e.listProps),{default:()=>{var pe,ue,le;return[(pe=n["prepend-item"])==null?void 0:pe.call(n),!P.value.length&&!e.hideNoData&&(((ue=n["no-data"])==null?void 0:ue.call(n))??h(Fe,{title:r(e.noDataText)},null)),h(SG,{ref:o,renderless:!0,items:P.value},{default:J=>{var ze;let{item:be,index:Se,itemRef:te}=J;const Y=me(be.props,{ref:te,key:Se,onClick:()=>A(be,null)});return((ze=n.item)==null?void 0:ze.call(n,{item:be,index:Se,props:Y}))??h(Fe,me(Y,{role:"option"}),{prepend:F=>{let{isSelected:N}=F;return h(Re,null,[e.multiple&&!e.hideSelected?h(yu,{key:be.value,modelValue:N,ripple:!1,tabindex:"-1"},null):void 0,be.props.prependAvatar&&h(lt,{image:be.props.prependAvatar},null),be.props.prependIcon&&h(X,{icon:be.props.prependIcon},null)])}})}}),(le=n["append-item"])==null?void 0:le.call(n)]}})]}),f.value.map((pe,ue)=>{function le(te){te.stopPropagation(),te.preventDefault(),A(pe,!1)}const J={"onClick:close":le,onKeydown(te){te.key!=="Enter"&&te.key!==" "||(te.preventDefault(),te.stopPropagation(),le(te))},onMousedown(te){te.preventDefault(),te.stopPropagation()},modelValue:!0,"onUpdate:modelValue":void 0},be=B?!!n.chip:!!n.selection,Se=be?vP(B?n.chip({item:pe,index:ue,props:J}):n.selection({item:pe,index:ue})):void 0;if(!(be&&!Se))return h("div",{key:pe.value,class:"v-select__selection"},[B?n.chip?h(At,{key:"chip-defaults",defaults:{VChip:{closable:e.closableChips,size:"small",text:pe.title}}},{default:()=>[Se]}):h(kn,me({key:"chip",closable:e.closableChips,size:"small",text:pe.title,disabled:pe.props.disabled},J),null):Se??h("span",{class:"v-select__selection-text"},[pe.title,e.multiple&&ue<f.value.length-1&&h("span",{class:"v-select__selection-comma"},[_(",")])])])})]),"append-inner":function(){var J;for(var pe=arguments.length,ue=new Array(pe),le=0;le<pe;le++)ue[le]=arguments[le];return h(Re,null,[(J=n["append-inner"])==null?void 0:J.call(n,...ue),e.menuIcon?h(X,{class:"v-select__menu-icon",icon:e.menuIcon},null):void 0])}})}),Wi({isFocused:y,menu:l,select:A},s)}}),EG={class:"text-h5"},CG=Le({__name:"PrinterMaintenanceDialog",setup(e){const t=U([]),n=["Broken part","Blob","Maxtemp","Preheat error","Cable USB ","Bed thermal runaway","Thermistor Heatbed","Thermistor Heatblock","Thermal Runaway","Mintemp Nozzle","Mintemp Heatbed","Nozzle","Nozzle Clog","Fan Hotend","Fan Part cooling","Extruder rattle","Extruder","Z Axis","X Axis","Y Axis","Rented","Motherboard","Other","Clean"],r=U({}),s=Nt(),i=Fn(Jt.PrinterMaintenanceDialog),o=R(()=>s.maintenanceDialogPrinter),a=()=>{r.value.disabledReason=t.value.join(", ")},l=async()=>{var f;const d=(f=o.value)==null?void 0:f.id;if(!d){r.value={},u();return}const c=r.value.disabledReason;await Wt.updatePrinterMaintenance(d,c),r.value={},u()},u=()=>{t.value=[],i.closeDialog(),s.setMaintenanceDialogPrinter()};return(d,c)=>{const f=gi;return $(),Q(f,{id:ie(i).dialogId,"max-width":"700px",onEscape:c[5]||(c[5]=p=>u())},{default:v(()=>[h(yt,{class:"pa-4"},{default:v(()=>[h(an,null,{default:v(()=>{var p;return[L("span",EG," Mark '"+ae((p=o.value)==null?void 0:p.name)+"' for maintenance ",1)]}),_:1}),h(un,{color:"secondary"},{default:v(()=>c[6]||(c[6]=[_(" Keep this info clear and stick to convention ")])),_:1}),h(nn,null,{default:v(()=>[h(at,null,{default:v(()=>[h(Ue,{cols:"12"},{default:v(()=>[h(Bo,{modelValue:t.value,"onUpdate:modelValue":[c[0]||(c[0]=p=>t.value=p),c[1]||(c[1]=p=>a())],chips:!0,items:n,"menu-props":{closeOnBack:!0,closeOnContentClick:!0},clearable:"",color:"primary",multiple:"",placeholder:"Quick select reason"},null,8,["modelValue"]),h(Dw,{modelValue:r.value.disabledReason,"onUpdate:modelValue":c[2]||(c[2]=p=>r.value.disabledReason=p),"data-vv-validate-on":"change|blur"},{label:v(()=>c[7]||(c[7]=[L("div",null,"Type the reason*",-1)])),_:1},8,["modelValue"])]),_:1})]),_:1})]),_:1}),h(Nn,null,{default:v(()=>[c[10]||(c[10]=L("em",{class:"text-red"}," * indicates required field ",-1)),h(wn),h(re,{variant:"text",onClick:c[3]||(c[3]=p=>u())},{default:v(()=>c[8]||(c[8]=[_(" Close ")])),_:1}),h(re,{color:"blue-darken-1",variant:"text",onClick:c[4]||(c[4]=p=>l())},{default:v(()=>c[9]||(c[9]=[_(" Save ")])),_:1})]),_:1})]),_:1})]),_:1},8,["id"])}}}),PG=[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16],TG=[1,2,3,4,5,6,7,8,9,10,11,12],UA=Le({__name:"GridSettingsList",setup(e){const t=Bs(),n=Mt(),r=R(()=>t.largeTiles);async function s(a){if(a)return o(t.gridRows,a)}async function i(a){if(a)return o(a,t.gridCols)}async function o(a,l){await t.updateFrontendSettings({gridRows:a,gridCols:l,largeTiles:r.value}),n.info("Grid settings updated")}return(a,l)=>($(),we("div",null,[h(nn,null,{default:v(()=>[h(Kt,{subheader:"",lines:"three"},{default:v(()=>{var u;return[h(hs,null,{default:v(()=>l[1]||(l[1]=[_(" Grid Rows and Columns ")])),_:1}),(u=ie(t).settings)!=null&&u.frontend?($(),Q(Fe,{key:0},{default:v(()=>[h(at,null,{default:v(()=>[h(Ue,{cols:"3"},{default:v(()=>[h(Bo,{type:"number","onUpdate:modelValue":i,value:ie(t).settings.frontend.gridRows,items:ie(PG),label:"Set the grid rows"},null,8,["value","items"])]),_:1}),h(Ue,{cols:"3"},{default:v(()=>[h(Bo,{type:"number","onUpdate:modelValue":s,value:ie(t).settings.frontend.gridCols,items:ie(TG),label:"Set the grid columns"},null,8,["value","items"])]),_:1})]),_:1})]),_:1})):ve("",!0)]}),_:1}),h(yn),h(Kt,{subheader:"",lines:"three"},{default:v(()=>[h(hs,null,{default:v(()=>l[2]||(l[2]=[_(" Large or Compact Tiles ")])),_:1}),h(Fe,null,{default:v(()=>{var u;return[(u=ie(t).settings)!=null&&u.frontend?($(),Q(at,{key:0},{default:v(()=>[h(Ue,{cols:"5"},{default:v(()=>[h(On,{onChange:o,modelValue:ie(t).settings.frontend.largeTiles,"onUpdate:modelValue":l[0]||(l[0]=d=>ie(t).settings.frontend.largeTiles=d),label:"Large tiles"},null,8,["modelValue"])]),_:1})]),_:1})):ve("",!0)]}),_:1})]),_:1})]),_:1})]))}}),RG={class:"text-h5"},IG=Le({__name:"GridSettingsDialog",setup(e){const t=Fn(Jt.GridSettingsDialog);function n(){t.closeDialog(t.context())}return(r,s)=>{const i=gi;return $(),Q(i,{id:ie(t).dialogId,"max-width":"1000px",onEscape:s[1]||(s[1]=o=>n())},{default:v(()=>[h(yt,{class:"pa-4"},{default:v(()=>[h(an,null,{default:v(()=>[L("span",RG,[s[4]||(s[4]=_(" Grid Settings ")),h(xt,{top:""},{activator:v(({props:o})=>[h(re,me(o,{class:"ma-2",fab:"","x-small":""}),{default:v(()=>[h(X,null,{default:v(()=>s[2]||(s[2]=[_("question_mark")])),_:1})]),_:2},1040)]),default:v(()=>s[3]||(s[3]=[_(" Change your grid rows, columns and tile settings. ")])),_:1})])]),_:1}),h(UA),h(Nn,null,{default:v(()=>[h(wn),h(re,{onClick:s[0]||(s[0]=o=>ie(t).closeDialog())},{default:v(()=>s[5]||(s[5]=[_("Close")])),_:1})]),_:1})]),_:1})]),_:1},8,["id"])}}});class os extends yr{static async createUser(t){const n=Oe.userRoute;return await this.post(n,t)}static async listUsers(){const t=Oe.userRoute;return await this.get(t)}static async listRoles(){const t=Oe.rolesRoute;return await this.get(t)}static async getProfile(){const t=Oe.userProfileRoute;return await this.get(t)}static async changePassword(t,n,r){const s=Oe.userChangePasswordRoute(t);return await this.post(s,{oldPassword:n,newPassword:r})}static async changeUsername(t,n){const r=Oe.userChangeUsernameRoute(t);return await this.post(r,{username:n})}static async deleteUser(t){const n=Oe.userDeleteRoute(t);return await this.delete(n)}static async setUserVerified(t,n){const r=Oe.userSetVerifiedRoute(t);return await this.post(r,{isVerified:n})}static async setRootUser(t,n){const r=Oe.userSetRootUserRoute(t);return await this.post(r,{isRootUser:n})}static async setUserRoles(t,n){const r=Oe.userSetUserRolesRoute(t);return await this.post(r,{roleIds:n})}}const AG={class:"text-h5"},OG={class:"pl-5"},MG=Le({__name:"CreateUserDialog",setup(e){const t=Fn(Jt.CreateUserDialog),n=Ye("appConstants"),r=Mt(),s=U({username:"",password:"",roleIds:[]}),i=U(""),o=U([]),a=R(()=>{var f,p;return(p=(f=s.value)==null?void 0:f.username)!=null&&p.length?dm(s.value.username):"??"}),l={required:f=>!!f||"Required field",minLength:f=>f.length>=n.minUsernameLength||`Minimum ${n.minUsernameLength} characters`,password:f=>f.length>=8?!0:"Password must be at least 8 characters",passwordMatch:f=>f===s.value.password||"Passwords must match"},u=()=>!s.value.username||s.value.username.length<n.minUsernameLength?(r.openErrorMessage({title:"Invalid username"}),!1):!s.value.password||l.password(s.value.password)!==!0?(r.openErrorMessage({title:"Invalid password"}),!1):s.value.password!==i.value?(r.openErrorMessage({title:"Passwords do not match"}),!1):s.value.roleIds.length?!0:(r.openErrorMessage({title:"Please select a role"}),!1),d=async()=>{if(u())try{await os.createUser(s.value),r.openInfoMessage({title:`User ${s.value.username} created successfully`}),c()}catch(f){r.openErrorMessage({title:"Failed to create user",subtitle:f instanceof Error?f.message:"Unknown error"})}},c=()=>{s.value={username:"",password:"",roleIds:[]},i.value="",t.closeDialog()};return St(async()=>{try{o.value=await os.listRoles()}catch(f){r.openErrorMessage({title:"Failed to load roles",subtitle:f instanceof Error?f.message:"Unknown error"})}}),(f,p)=>{const g=gi;return $(),Q(g,{id:ie(t).dialogId,"max-width":"700px",onEscape:c},{default:v(()=>[h(yt,{class:"pa-4"},{default:v(()=>[h(an,null,{default:v(()=>[L("span",AG,[h(lt,{color:"primary",size:"56"},{default:v(()=>[_(ae(a.value),1)]),_:1}),L("span",OG,[p[6]||(p[6]=_("New verified User ")),h(xt,{top:""},{activator:v(({props:m})=>[h(re,me({class:"ma-2",fab:""},m,{"x-small":""}),{default:v(()=>[h(X,null,{default:v(()=>p[4]||(p[4]=[_("question_mark")])),_:1})]),_:2},1040)]),default:v(()=>p[5]||(p[5]=[_(" The user will be set to verified and assigned roles. Please share the username and password with them manually. ")])),_:1})])])]),_:1}),h(nn,null,{default:v(()=>[h(at,null,{default:v(()=>[h(Ue,{cols:12},{default:v(()=>[h(Pn,null,{default:v(()=>[h(at,null,{default:v(()=>[h(Ue,{cols:"12",md:"6"},{default:v(()=>[h(ct,{modelValue:s.value.username,"onUpdate:modelValue":p[0]||(p[0]=m=>s.value.username=m),rules:[l.required,l.minLength],autofocus:"",label:"Username*","prepend-icon":"person",required:""},null,8,["modelValue","rules"]),h(ct,{modelValue:s.value.password,"onUpdate:modelValue":p[1]||(p[1]=m=>s.value.password=m),rules:[l.required,l.password],label:"Password*","prepend-icon":"lock",required:"",type:"password"},null,8,["modelValue","rules"]),h(ct,{modelValue:i.value,"onUpdate:modelValue":p[2]||(p[2]=m=>i.value=m),rules:[l.required,l.passwordMatch],label:"Confirm Password*","prepend-icon":"lock",required:"",type:"password"},null,8,["modelValue","rules"]),h(Bo,{modelValue:s.value.roleIds,"onUpdate:modelValue":p[3]||(p[3]=m=>s.value.roleIds=m),items:o.value.map(m=>({text:m.name,value:m.id})),rules:[l.required],label:"Roles*",multiple:"","prepend-icon":"shield",required:""},null,8,["modelValue","items","rules"])]),_:1})]),_:1})]),_:1})]),_:1})]),_:1})]),_:1}),h(Nn,null,{default:v(()=>[p[9]||(p[9]=L("em",{class:"text-red"}," * indicates required field ",-1)),h(wn),h(re,{variant:"text",onClick:c},{default:v(()=>p[7]||(p[7]=[_("Close")])),_:1}),h(re,{color:"blue-darken-1",variant:"text",onClick:d},{default:v(()=>p[8]||(p[8]=[_("Create")])),_:1})]),_:1})]),_:1})]),_:1},8,["id"])}}}),HA=()=>({id:void 0,name:Wa(),floor:"1",printers:[]});class as extends yr{static convertPrinterFloorToCreateForm(t){const n=HA();return n.id=t==null?void 0:t.id,n.name=(t==null?void 0:t.name)||Wa(),n.printers=[],n.floor=((t==null?void 0:t.floor)||1).toString(),n}static convertCreateFormToFloor(t){const n={...t};if(n.floor=parseInt(n.floor),Number.isNaN(n.floor))throw new Error("Floor number did not convert to number.");return n}static async getFloors(){const t=`${Oe.floorRoute}/`;return await this.get(t)}static async createFloor(t){const n=`${Oe.floorRoute}/`;return await this.post(n,t)}static async updateFloorName(t,n){const r=`${Oe.updatePrinterFloorNameRoute(t)}/`;return await this.patch(r,{name:n})}static async updateFloorNumber(t,n){const r=`${Oe.updatePrinterFloorNumberRoute(t)}/`;return await this.patch(r,{floor:n})}static async deleteFloor(t){const n=`${Oe.getFloorRoute(t)}/`;return await this.delete(n)}static async addPrinterToFloor(t,n){const r=`${Oe.addOrRemovePrinterFromFloorRoute(t)}/`;return await this.post(r,n)}static async deletePrinterFromFloor(t,n){const r=`${Oe.addOrRemovePrinterFromFloorRoute(t)}/`;return await this.delete(r,{printerId:n})}}const Xi=Ms("Floors",{state:()=>({floors:[],selectedFloor:null}),getters:{sortedFloors(e){return e.floors.sort((t,n)=>t.floor-n.floor)},floor(e){return t=>e.floors.find(n=>n.id===t)},floorNames(e){return e.floors.map(t=>t.name)},floorOfPrinter(){return e=>this.floors.find(t=>t.printers.map(n=>n.printerId).includes(e))},floorlessPrinters(e){return Nt().printers.filter(n=>!e.floors.find(r=>r.printers.find(s=>s.printerId===n.id)))},gridSortedPrinters(){const e=Bs(),t=e.gridCols,n=e.gridRows,s=Nt().printers;if(!s.length)return[];if(!this.selectedFloor)return[];const i=this.selectedFloor.printers,o=[];for(let a=0;a<t;a++){const l=[];o.push(l);for(let u=0;u<n;u++){const d=i.find(c=>c.x===a&&c.y===u);if(!d)l.push(void 0);else{const c=s.find(f=>f.id===d.printerId);l.push(c)}}}return o}},actions:{async loadFloors(){const e=await as.getFloors();return this.saveFloors(e),e},async createFloor(e){const t=await as.createFloor(e);return this.floors.push(t),t},saveFloors(e){var r;if(!(e!=null&&e.length))return;this.floors=e.sort((s,i)=>s.floor-i.floor);const t=(r=this.selectedFloor)==null?void 0:r.id,n=this.floors.find(s=>s.id===t);this.selectedFloor=n||this.floors[0]},async deleteFloor(e){await as.deleteFloor(e),this._popPrinterFloor(e)},async updateFloorName({floorId:e,name:t}){const n=await as.updateFloorName(e,t);return this._replaceFloor(n),n},async updateFloorNumber({floorId:e,floorNumber:t}){const n=await as.updateFloorNumber(e,t);return this._replaceFloor(n),n},async addPrinterToFloor({floorId:e,printerId:t,x:n,y:r}){const s=await as.addPrinterToFloor(e,{printerId:t,x:n,y:r});this._replaceFloor(s)},async changeSelectedFloorByIndex(e){var n;if(!((n=this.floors)!=null&&n.length)||this.floors.length<=e)return;const t=this.floors[e];if(t)return this.selectedFloor=t,t},async deletePrinterFromFloor({floorId:e,printerId:t}){const n=await as.deletePrinterFromFloor(e,t);this._replaceFloor(n)},_popPrinterFloor(e){const t=this.floors.findIndex(n=>n.id===e);t!==-1&&this.floors.splice(t,1)},_replaceFloor(e){const t=this.floors.findIndex(n=>n.id===e.id);t!==-1&&(this.floors[t]=e)}}}),DG={class:"text-h5"},LG=Le({__name:"AddOrUpdateFloorDialog",setup(e){const t=Fn(Jt.AddOrUpdateFloorDialog),n=Xi(),r=Ye("appConstants"),s=Mt(),i=U(HA()),o=R(()=>{var c;return(c=t.context())==null?void 0:c.printerFloorId}),a=R(()=>i.value?dm(i.value.name):""),l=()=>!i.value.name||i.value.name.length<r.minPrinterFloorNameLength?(s.openErrorMessage({title:"Invalid floor name"}),!1):Number.isInteger(Number(i.value.floor))?!0:(s.openErrorMessage({title:"Floor number must be an integer"}),!1),u=async()=>{if(!l())return;const c=as.convertCreateFormToFloor(i.value);await n.createFloor(c),s.openInfoMessage({title:`Floor ${c.name} created`}),i.value.name=Wa();const f=Math.max(...n.floors.map(p=>p.floor))+1;i.value.floor=f.toString(),d()},d=()=>{t.closeDialog()};return Ce(o,c=>{if(c){const f=n.floor(c);i.value=as.convertPrinterFloorToCreateForm(f)}}),St(()=>{var c;if(o.value){const f=n.floor(o.value);i.value=as.convertPrinterFloorToCreateForm(f)}else if((c=n.floors)!=null&&c.length){const f=Math.max(...n.floors.map(p=>p.floor))+1;i.value.floor=f.toString()}}),(c,f)=>{const p=gi;return $(),Q(p,{id:ie(t).dialogId,"max-width":"700px",onEscape:d},{default:v(()=>[h(yt,null,{default:v(()=>[h(an,null,{default:v(()=>[L("span",DG,[h(lt,{color:"primary",size:"56"},{default:v(()=>[_(ae(a.value),1)]),_:1}),f[2]||(f[2]=_(" New Floor "))])]),_:1}),h(nn,null,{default:v(()=>[h(at,null,{default:v(()=>[h(Ue,{cols:12},{default:v(()=>[h(Pn,null,{default:v(()=>[h(at,null,{default:v(()=>[i.value?($(),Q(Ue,{key:0,cols:"12",md:"6"},{default:v(()=>[h(ct,{modelValue:i.value.name,"onUpdate:modelValue":f[0]||(f[0]=g=>i.value.name=g),autofocus:"",label:"Floor name*",required:""},null,8,["modelValue"]),h(ct,{modelValue:i.value.floor,"onUpdate:modelValue":f[1]||(f[1]=g=>i.value.floor=g),label:"Floor number",required:"",type:"number"},null,8,["modelValue"])]),_:1})):ve("",!0)]),_:1})]),_:1})]),_:1})]),_:1})]),_:1}),h(Nn,null,{default:v(()=>[f[5]||(f[5]=L("em",{class:"text-red"}," * indicates required field ",-1)),h(wn),h(re,{variant:"text",onClick:d},{default:v(()=>f[3]||(f[3]=[_("Close")])),_:1}),h(re,{color:"blue-darken-1",variant:"text",onClick:u},{default:v(()=>f[4]||(f[4]=[_("Create")])),_:1})]),_:1})]),_:1})]),_:1},8,["id"])}}});class sp extends yr{static async listCameraStreams(){return await this.get("/api/camera-stream/")}static async createCameraStream(t){return await this.post("/api/camera-stream/",t)}static async getCameraStream(t){return await this.get(`/api/camera-stream/${t}`)}static async updateCameraStream(t,n){return await this.put(`/api/camera-stream/${t}`,n)}static async deleteCameraStream(t){return await this.delete(`/api/camera-stream/${t}`)}}var Hu=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},Ka=typeof window>"u"||"Deno"in globalThis;function is(){}function $G(e,t){return typeof e=="function"?e(t):e}function Sy(e){return typeof e=="number"&&e>=0&&e!==1/0}function zA(e,t){return Math.max(e+(t||0)-Date.now(),0)}function Hl(e,t){return typeof e=="function"?e(t):e}function Cs(e,t){return typeof e=="function"?e(t):e}function rk(e,t){const{type:n="all",exact:r,fetchStatus:s,predicate:i,queryKey:o,stale:a}=e;if(o){if(r){if(t.queryHash!==Lw(o,t.options))return!1}else if(!ad(t.queryKey,o))return!1}if(n!=="all"){const l=t.isActive();if(n==="active"&&!l||n==="inactive"&&l)return!1}return!(typeof a=="boolean"&&t.isStale()!==a||s&&s!==t.state.fetchStatus||i&&!i(t))}function sk(e,t){const{exact:n,status:r,predicate:s,mutationKey:i}=e;if(i){if(!t.options.mutationKey)return!1;if(n){if(Ya(t.options.mutationKey)!==Ya(i))return!1}else if(!ad(t.options.mutationKey,i))return!1}return!(r&&t.state.status!==r||s&&!s(t))}function Lw(e,t){return((t==null?void 0:t.queryKeyHashFn)||Ya)(e)}function Ya(e){return JSON.stringify(e,(t,n)=>_y(n)?Object.keys(n).sort().reduce((r,s)=>(r[s]=n[s],r),{}):n)}function ad(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?!Object.keys(t).some(n=>!ad(e[n],t[n])):!1}function jA(e,t){if(e===t)return e;const n=ik(e)&&ik(t);if(n||_y(e)&&_y(t)){const r=n?e:Object.keys(e),s=r.length,i=n?t:Object.keys(t),o=i.length,a=n?[]:{};let l=0;for(let u=0;u<o;u++){const d=n?u:i[u];(!n&&r.includes(d)||n)&&e[d]===void 0&&t[d]===void 0?(a[d]=void 0,l++):(a[d]=jA(e[d],t[d]),a[d]===e[d]&&e[d]!==void 0&&l++)}return s===o&&l===s?e:a}return t}function ip(e,t){if(!t||Object.keys(e).length!==Object.keys(t).length)return!1;for(const n in e)if(e[n]!==t[n])return!1;return!0}function ik(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function _y(e){if(!ok(e))return!1;const t=e.constructor;if(t===void 0)return!0;const n=t.prototype;return!(!ok(n)||!n.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function ok(e){return Object.prototype.toString.call(e)==="[object Object]"}function FG(e){return new Promise(t=>{setTimeout(t,e)})}function ky(e,t,n){return typeof n.structuralSharing=="function"?n.structuralSharing(e,t):n.structuralSharing!==!1?jA(e,t):t}function NG(e,t,n=0){const r=[...e,t];return n&&r.length>n?r.slice(1):r}function BG(e,t,n=0){const r=[t,...e];return n&&r.length>n?r.slice(0,-1):r}var $w=Symbol();function qA(e,t){return!e.queryFn&&(t!=null&&t.initialPromise)?()=>t.initialPromise:!e.queryFn||e.queryFn===$w?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}var wa,po,ql,CE,VG=(CE=class extends Hu{constructor(){super();He(this,wa);He(this,po);He(this,ql);De(this,ql,t=>{if(!Ka&&window.addEventListener){const n=()=>t();return window.addEventListener("visibilitychange",n,!1),()=>{window.removeEventListener("visibilitychange",n)}}})}onSubscribe(){z(this,po)||this.setEventListener(z(this,ql))}onUnsubscribe(){var t;this.hasListeners()||((t=z(this,po))==null||t.call(this),De(this,po,void 0))}setEventListener(t){var n;De(this,ql,t),(n=z(this,po))==null||n.call(this),De(this,po,t(r=>{typeof r=="boolean"?this.setFocused(r):this.onFocus()}))}setFocused(t){z(this,wa)!==t&&(De(this,wa,t),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach(n=>{n(t)})}isFocused(){var t;return typeof z(this,wa)=="boolean"?z(this,wa):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},wa=new WeakMap,po=new WeakMap,ql=new WeakMap,CE),Fw=new VG,Wl,mo,Gl,PE,UG=(PE=class extends Hu{constructor(){super();He(this,Wl,!0);He(this,mo);He(this,Gl);De(this,Gl,t=>{if(!Ka&&window.addEventListener){const n=()=>t(!0),r=()=>t(!1);return window.addEventListener("online",n,!1),window.addEventListener("offline",r,!1),()=>{window.removeEventListener("online",n),window.removeEventListener("offline",r)}}})}onSubscribe(){z(this,mo)||this.setEventListener(z(this,Gl))}onUnsubscribe(){var t;this.hasListeners()||((t=z(this,mo))==null||t.call(this),De(this,mo,void 0))}setEventListener(t){var n;De(this,Gl,t),(n=z(this,mo))==null||n.call(this),De(this,mo,t(this.setOnline.bind(this)))}setOnline(t){z(this,Wl)!==t&&(De(this,Wl,t),this.listeners.forEach(r=>{r(t)}))}isOnline(){return z(this,Wl)}},Wl=new WeakMap,mo=new WeakMap,Gl=new WeakMap,PE),op=new UG;function xy(){let e,t;const n=new Promise((s,i)=>{e=s,t=i});n.status="pending",n.catch(()=>{});function r(s){Object.assign(n,s),delete n.resolve,delete n.reject}return n.resolve=s=>{r({status:"fulfilled",value:s}),e(s)},n.reject=s=>{r({status:"rejected",reason:s}),t(s)},n}function HG(e){return Math.min(1e3*2**e,3e4)}function WA(e){return(e??"online")==="online"?op.isOnline():!0}var GA=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function Eg(e){return e instanceof GA}function KA(e){let t=!1,n=0,r=!1,s;const i=xy(),o=m=>{var y;r||(f(new GA(m)),(y=e.abort)==null||y.call(e))},a=()=>{t=!0},l=()=>{t=!1},u=()=>Fw.isFocused()&&(e.networkMode==="always"||op.isOnline())&&e.canRun(),d=()=>WA(e.networkMode)&&e.canRun(),c=m=>{var y;r||(r=!0,(y=e.onSuccess)==null||y.call(e,m),s==null||s(),i.resolve(m))},f=m=>{var y;r||(r=!0,(y=e.onError)==null||y.call(e,m),s==null||s(),i.reject(m))},p=()=>new Promise(m=>{var y;s=b=>{(r||u())&&m(b)},(y=e.onPause)==null||y.call(e)}).then(()=>{var m;s=void 0,r||(m=e.onContinue)==null||m.call(e)}),g=()=>{if(r)return;let m;const y=n===0?e.initialPromise:void 0;try{m=y??e.fn()}catch(b){m=Promise.reject(b)}Promise.resolve(m).then(c).catch(b=>{var T;if(r)return;const w=e.retry??(Ka?0:3),S=e.retryDelay??HG,P=typeof S=="function"?S(n,b):S,E=w===!0||typeof w=="number"&&n<w||typeof w=="function"&&w(n,b);if(t||!E){f(b);return}n++,(T=e.onFail)==null||T.call(e,n,b),FG(P).then(()=>u()?void 0:p()).then(()=>{t?f(b):g()})})};return{promise:i,cancel:o,continue:()=>(s==null||s(),i),cancelRetry:a,continueRetry:l,canStart:d,start:()=>(d()?g():p().then(g),i)}}function zG(){let e=[],t=0,n=a=>{a()},r=a=>{a()},s=a=>setTimeout(a,0);const i=a=>{t?e.push(a):s(()=>{n(a)})},o=()=>{const a=e;e=[],a.length&&s(()=>{r(()=>{a.forEach(l=>{n(l)})})})};return{batch:a=>{let l;t++;try{l=a()}finally{t--,t||o()}return l},batchCalls:a=>(...l)=>{i(()=>{a(...l)})},schedule:i,setNotifyFunction:a=>{n=a},setBatchNotifyFunction:a=>{r=a},setScheduler:a=>{s=a}}}var Hn=zG(),Sa,TE,YA=(TE=class{constructor(){He(this,Sa)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),Sy(this.gcTime)&&De(this,Sa,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(Ka?1/0:5*60*1e3))}clearGcTimeout(){z(this,Sa)&&(clearTimeout(z(this,Sa)),De(this,Sa,void 0))}},Sa=new WeakMap,TE),Kl,Yl,ss,Kn,gd,_a,ks,ki,RE,jG=(RE=class extends YA{constructor(t){super();He(this,ks);He(this,Kl);He(this,Yl);He(this,ss);He(this,Kn);He(this,gd);He(this,_a);De(this,_a,!1),De(this,gd,t.defaultOptions),this.setOptions(t.options),this.observers=[],De(this,ss,t.cache),this.queryKey=t.queryKey,this.queryHash=t.queryHash,De(this,Kl,qG(this.options)),this.state=t.state??z(this,Kl),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var t;return(t=z(this,Kn))==null?void 0:t.promise}setOptions(t){this.options={...z(this,gd),...t},this.updateGcTime(this.options.gcTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&z(this,ss).remove(this)}setData(t,n){const r=ky(this.state.data,t,this.options);return rt(this,ks,ki).call(this,{data:r,type:"success",dataUpdatedAt:n==null?void 0:n.updatedAt,manual:n==null?void 0:n.manual}),r}setState(t,n){rt(this,ks,ki).call(this,{type:"setState",state:t,setStateOptions:n})}cancel(t){var r,s;const n=(r=z(this,Kn))==null?void 0:r.promise;return(s=z(this,Kn))==null||s.cancel(t),n?n.then(is).catch(is):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(z(this,Kl))}isActive(){return this.observers.some(t=>Cs(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===$w||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStale(){return this.state.isInvalidated?!0:this.getObserversCount()>0?this.observers.some(t=>t.getCurrentResult().isStale):this.state.data===void 0}isStaleByTime(t=0){return this.state.isInvalidated||this.state.data===void 0||!zA(this.state.dataUpdatedAt,t)}onFocus(){var n;const t=this.observers.find(r=>r.shouldFetchOnWindowFocus());t==null||t.refetch({cancelRefetch:!1}),(n=z(this,Kn))==null||n.continue()}onOnline(){var n;const t=this.observers.find(r=>r.shouldFetchOnReconnect());t==null||t.refetch({cancelRefetch:!1}),(n=z(this,Kn))==null||n.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),z(this,ss).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(n=>n!==t),this.observers.length||(z(this,Kn)&&(z(this,_a)?z(this,Kn).cancel({revert:!0}):z(this,Kn).cancelRetry()),this.scheduleGc()),z(this,ss).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||rt(this,ks,ki).call(this,{type:"invalidate"})}fetch(t,n){var l,u,d;if(this.state.fetchStatus!=="idle"){if(this.state.data!==void 0&&(n!=null&&n.cancelRefetch))this.cancel({silent:!0});else if(z(this,Kn))return z(this,Kn).continueRetry(),z(this,Kn).promise}if(t&&this.setOptions(t),!this.options.queryFn){const c=this.observers.find(f=>f.options.queryFn);c&&this.setOptions(c.options)}const r=new AbortController,s=c=>{Object.defineProperty(c,"signal",{enumerable:!0,get:()=>(De(this,_a,!0),r.signal)})},i=()=>{const c=qA(this.options,n),f={queryKey:this.queryKey,meta:this.meta};return s(f),De(this,_a,!1),this.options.persister?this.options.persister(c,f,this):c(f)},o={fetchOptions:n,options:this.options,queryKey:this.queryKey,state:this.state,fetchFn:i};s(o),(l=this.options.behavior)==null||l.onFetch(o,this),De(this,Yl,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((u=o.fetchOptions)==null?void 0:u.meta))&&rt(this,ks,ki).call(this,{type:"fetch",meta:(d=o.fetchOptions)==null?void 0:d.meta});const a=c=>{var f,p,g,m;Eg(c)&&c.silent||rt(this,ks,ki).call(this,{type:"error",error:c}),Eg(c)||((p=(f=z(this,ss).config).onError)==null||p.call(f,c,this),(m=(g=z(this,ss).config).onSettled)==null||m.call(g,this.state.data,c,this)),this.scheduleGc()};return De(this,Kn,KA({initialPromise:n==null?void 0:n.initialPromise,fn:o.fetchFn,abort:r.abort.bind(r),onSuccess:c=>{var f,p,g,m;if(c===void 0){a(new Error(`${this.queryHash} data is undefined`));return}try{this.setData(c)}catch(y){a(y);return}(p=(f=z(this,ss).config).onSuccess)==null||p.call(f,c,this),(m=(g=z(this,ss).config).onSettled)==null||m.call(g,c,this.state.error,this),this.scheduleGc()},onError:a,onFail:(c,f)=>{rt(this,ks,ki).call(this,{type:"failed",failureCount:c,error:f})},onPause:()=>{rt(this,ks,ki).call(this,{type:"pause"})},onContinue:()=>{rt(this,ks,ki).call(this,{type:"continue"})},retry:o.options.retry,retryDelay:o.options.retryDelay,networkMode:o.options.networkMode,canRun:()=>!0})),z(this,Kn).start()}},Kl=new WeakMap,Yl=new WeakMap,ss=new WeakMap,Kn=new WeakMap,gd=new WeakMap,_a=new WeakMap,ks=new WeakSet,ki=function(t){const n=r=>{switch(t.type){case"failed":return{...r,fetchFailureCount:t.failureCount,fetchFailureReason:t.error};case"pause":return{...r,fetchStatus:"paused"};case"continue":return{...r,fetchStatus:"fetching"};case"fetch":return{...r,...XA(r.data,this.options),fetchMeta:t.meta??null};case"success":return{...r,data:t.data,dataUpdateCount:r.dataUpdateCount+1,dataUpdatedAt:t.dataUpdatedAt??Date.now(),error:null,isInvalidated:!1,status:"success",...!t.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":const s=t.error;return Eg(s)&&s.revert&&z(this,Yl)?{...z(this,Yl),fetchStatus:"idle"}:{...r,error:s,errorUpdateCount:r.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:r.fetchFailureCount+1,fetchFailureReason:s,fetchStatus:"idle",status:"error"};case"invalidate":return{...r,isInvalidated:!0};case"setState":return{...r,...t.state}}};this.state=n(this.state),Hn.batch(()=>{this.observers.forEach(r=>{r.onQueryUpdate()}),z(this,ss).notify({query:this,type:"updated",action:t})})},RE);function XA(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:WA(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function qG(e){const t=typeof e.initialData=="function"?e.initialData():e.initialData,n=t!==void 0,r=n?typeof e.initialDataUpdatedAt=="function"?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:n?r??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:n?"success":"pending",fetchStatus:"idle"}}var Qs,IE,QA=(IE=class extends Hu{constructor(n={}){super();He(this,Qs);this.config=n,De(this,Qs,new Map)}build(n,r,s){const i=r.queryKey,o=r.queryHash??Lw(i,r);let a=this.get(o);return a||(a=new jG({cache:this,queryKey:i,queryHash:o,options:n.defaultQueryOptions(r),state:s,defaultOptions:n.getQueryDefaults(i)}),this.add(a)),a}add(n){z(this,Qs).has(n.queryHash)||(z(this,Qs).set(n.queryHash,n),this.notify({type:"added",query:n}))}remove(n){const r=z(this,Qs).get(n.queryHash);r&&(n.destroy(),r===n&&z(this,Qs).delete(n.queryHash),this.notify({type:"removed",query:n}))}clear(){Hn.batch(()=>{this.getAll().forEach(n=>{this.remove(n)})})}get(n){return z(this,Qs).get(n)}getAll(){return[...z(this,Qs).values()]}find(n){const r={exact:!0,...n};return this.getAll().find(s=>rk(r,s))}findAll(n={}){const r=this.getAll();return Object.keys(n).length>0?r.filter(s=>rk(n,s)):r}notify(n){Hn.batch(()=>{this.listeners.forEach(r=>{r(n)})})}onFocus(){Hn.batch(()=>{this.getAll().forEach(n=>{n.onFocus()})})}onOnline(){Hn.batch(()=>{this.getAll().forEach(n=>{n.onOnline()})})}},Qs=new WeakMap,IE),Js,lr,ka,Zs,ro,AE,WG=(AE=class extends YA{constructor(t){super();He(this,Zs);He(this,Js);He(this,lr);He(this,ka);this.mutationId=t.mutationId,De(this,lr,t.mutationCache),De(this,Js,[]),this.state=t.state||JA(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){z(this,Js).includes(t)||(z(this,Js).push(t),this.clearGcTimeout(),z(this,lr).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){De(this,Js,z(this,Js).filter(n=>n!==t)),this.scheduleGc(),z(this,lr).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){z(this,Js).length||(this.state.status==="pending"?this.scheduleGc():z(this,lr).remove(this))}continue(){var t;return((t=z(this,ka))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var s,i,o,a,l,u,d,c,f,p,g,m,y,b,w,S,P,E,T,C;De(this,ka,KA({fn:()=>this.options.mutationFn?this.options.mutationFn(t):Promise.reject(new Error("No mutationFn found")),onFail:(k,x)=>{rt(this,Zs,ro).call(this,{type:"failed",failureCount:k,error:x})},onPause:()=>{rt(this,Zs,ro).call(this,{type:"pause"})},onContinue:()=>{rt(this,Zs,ro).call(this,{type:"continue"})},retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>z(this,lr).canRun(this)}));const n=this.state.status==="pending",r=!z(this,ka).canStart();try{if(!n){rt(this,Zs,ro).call(this,{type:"pending",variables:t,isPaused:r}),await((i=(s=z(this,lr).config).onMutate)==null?void 0:i.call(s,t,this));const x=await((a=(o=this.options).onMutate)==null?void 0:a.call(o,t));x!==this.state.context&&rt(this,Zs,ro).call(this,{type:"pending",context:x,variables:t,isPaused:r})}const k=await z(this,ka).start();return await((u=(l=z(this,lr).config).onSuccess)==null?void 0:u.call(l,k,t,this.state.context,this)),await((c=(d=this.options).onSuccess)==null?void 0:c.call(d,k,t,this.state.context)),await((p=(f=z(this,lr).config).onSettled)==null?void 0:p.call(f,k,null,this.state.variables,this.state.context,this)),await((m=(g=this.options).onSettled)==null?void 0:m.call(g,k,null,t,this.state.context)),rt(this,Zs,ro).call(this,{type:"success",data:k}),k}catch(k){try{throw await((b=(y=z(this,lr).config).onError)==null?void 0:b.call(y,k,t,this.state.context,this)),await((S=(w=this.options).onError)==null?void 0:S.call(w,k,t,this.state.context)),await((E=(P=z(this,lr).config).onSettled)==null?void 0:E.call(P,void 0,k,this.state.variables,this.state.context,this)),await((C=(T=this.options).onSettled)==null?void 0:C.call(T,void 0,k,t,this.state.context)),k}finally{rt(this,Zs,ro).call(this,{type:"error",error:k})}}finally{z(this,lr).runNext(this)}}},Js=new WeakMap,lr=new WeakMap,ka=new WeakMap,Zs=new WeakSet,ro=function(t){const n=r=>{switch(t.type){case"failed":return{...r,failureCount:t.failureCount,failureReason:t.error};case"pause":return{...r,isPaused:!0};case"continue":return{...r,isPaused:!1};case"pending":return{...r,context:t.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:t.isPaused,status:"pending",variables:t.variables,submittedAt:Date.now()};case"success":return{...r,data:t.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...r,data:void 0,error:t.error,failureCount:r.failureCount+1,failureReason:t.error,isPaused:!1,status:"error"}}};this.state=n(this.state),Hn.batch(()=>{z(this,Js).forEach(r=>{r.onMutationUpdate(t)}),z(this,lr).notify({mutation:this,type:"updated",action:t})})},AE);function JA(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var zr,vd,OE,ZA=(OE=class extends Hu{constructor(n={}){super();He(this,zr);He(this,vd);this.config=n,De(this,zr,new Map),De(this,vd,Date.now())}build(n,r,s){const i=new WG({mutationCache:this,mutationId:++Xd(this,vd)._,options:n.defaultMutationOptions(r),state:s});return this.add(i),i}add(n){const r=kf(n),s=z(this,zr).get(r)??[];s.push(n),z(this,zr).set(r,s),this.notify({type:"added",mutation:n})}remove(n){var s;const r=kf(n);if(z(this,zr).has(r)){const i=(s=z(this,zr).get(r))==null?void 0:s.filter(o=>o!==n);i&&(i.length===0?z(this,zr).delete(r):z(this,zr).set(r,i))}this.notify({type:"removed",mutation:n})}canRun(n){var s;const r=(s=z(this,zr).get(kf(n)))==null?void 0:s.find(i=>i.state.status==="pending");return!r||r===n}runNext(n){var s;const r=(s=z(this,zr).get(kf(n)))==null?void 0:s.find(i=>i!==n&&i.state.isPaused);return(r==null?void 0:r.continue())??Promise.resolve()}clear(){Hn.batch(()=>{this.getAll().forEach(n=>{this.remove(n)})})}getAll(){return[...z(this,zr).values()].flat()}find(n){const r={exact:!0,...n};return this.getAll().find(s=>sk(r,s))}findAll(n={}){return this.getAll().filter(r=>sk(n,r))}notify(n){Hn.batch(()=>{this.listeners.forEach(r=>{r(n)})})}resumePausedMutations(){const n=this.getAll().filter(r=>r.state.isPaused);return Hn.batch(()=>Promise.all(n.map(r=>r.continue().catch(is))))}},zr=new WeakMap,vd=new WeakMap,OE);function kf(e){var t;return((t=e.options.scope)==null?void 0:t.id)??String(e.mutationId)}function ak(e){return{onFetch:(t,n)=>{var d,c,f,p,g;const r=t.options,s=(f=(c=(d=t.fetchOptions)==null?void 0:d.meta)==null?void 0:c.fetchMore)==null?void 0:f.direction,i=((p=t.state.data)==null?void 0:p.pages)||[],o=((g=t.state.data)==null?void 0:g.pageParams)||[];let a={pages:[],pageParams:[]},l=0;const u=async()=>{let m=!1;const y=S=>{Object.defineProperty(S,"signal",{enumerable:!0,get:()=>(t.signal.aborted?m=!0:t.signal.addEventListener("abort",()=>{m=!0}),t.signal)})},b=qA(t.options,t.fetchOptions),w=async(S,P,E)=>{if(m)return Promise.reject();if(P==null&&S.pages.length)return Promise.resolve(S);const T={queryKey:t.queryKey,pageParam:P,direction:E?"backward":"forward",meta:t.options.meta};y(T);const C=await b(T),{maxPages:k}=t.options,x=E?BG:NG;return{pages:x(S.pages,C,k),pageParams:x(S.pageParams,P,k)}};if(s&&i.length){const S=s==="backward",P=S?GG:lk,E={pages:i,pageParams:o},T=P(r,E);a=await w(E,T,S)}else{const S=e??i.length;do{const P=l===0?o[0]??r.initialPageParam:lk(r,a);if(l>0&&P==null)break;a=await w(a,P),l++}while(l<S)}return a};t.options.persister?t.fetchFn=()=>{var m,y;return(y=(m=t.options).persister)==null?void 0:y.call(m,u,{queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},n)}:t.fetchFn=u}}}function lk(e,{pages:t,pageParams:n}){const r=t.length-1;return t.length>0?e.getNextPageParam(t[r],t,n[r],n):void 0}function GG(e,{pages:t,pageParams:n}){var r;return t.length>0?(r=e.getPreviousPageParam)==null?void 0:r.call(e,t[0],t,n[0],n):void 0}var dn,go,vo,Xl,Ql,yo,Jl,Zl,ME,KG=(ME=class{constructor(t={}){He(this,dn);He(this,go);He(this,vo);He(this,Xl);He(this,Ql);He(this,yo);He(this,Jl);He(this,Zl);De(this,dn,t.queryCache||new QA),De(this,go,t.mutationCache||new ZA),De(this,vo,t.defaultOptions||{}),De(this,Xl,new Map),De(this,Ql,new Map),De(this,yo,0)}mount(){Xd(this,yo)._++,z(this,yo)===1&&(De(this,Jl,Fw.subscribe(async t=>{t&&(await this.resumePausedMutations(),z(this,dn).onFocus())})),De(this,Zl,op.subscribe(async t=>{t&&(await this.resumePausedMutations(),z(this,dn).onOnline())})))}unmount(){var t,n;Xd(this,yo)._--,z(this,yo)===0&&((t=z(this,Jl))==null||t.call(this),De(this,Jl,void 0),(n=z(this,Zl))==null||n.call(this),De(this,Zl,void 0))}isFetching(t){return z(this,dn).findAll({...t,fetchStatus:"fetching"}).length}isMutating(t){return z(this,go).findAll({...t,status:"pending"}).length}getQueryData(t){var r;const n=this.defaultQueryOptions({queryKey:t});return(r=z(this,dn).get(n.queryHash))==null?void 0:r.state.data}ensureQueryData(t){const n=this.getQueryData(t.queryKey);if(n===void 0)return this.fetchQuery(t);{const r=this.defaultQueryOptions(t),s=z(this,dn).build(this,r);return t.revalidateIfStale&&s.isStaleByTime(Hl(r.staleTime,s))&&this.prefetchQuery(r),Promise.resolve(n)}}getQueriesData(t){return z(this,dn).findAll(t).map(({queryKey:n,state:r})=>{const s=r.data;return[n,s]})}setQueryData(t,n,r){const s=this.defaultQueryOptions({queryKey:t}),i=z(this,dn).get(s.queryHash),o=i==null?void 0:i.state.data,a=$G(n,o);if(a!==void 0)return z(this,dn).build(this,s).setData(a,{...r,manual:!0})}setQueriesData(t,n,r){return Hn.batch(()=>z(this,dn).findAll(t).map(({queryKey:s})=>[s,this.setQueryData(s,n,r)]))}getQueryState(t){var r;const n=this.defaultQueryOptions({queryKey:t});return(r=z(this,dn).get(n.queryHash))==null?void 0:r.state}removeQueries(t){const n=z(this,dn);Hn.batch(()=>{n.findAll(t).forEach(r=>{n.remove(r)})})}resetQueries(t,n){const r=z(this,dn),s={type:"active",...t};return Hn.batch(()=>(r.findAll(t).forEach(i=>{i.reset()}),this.refetchQueries(s,n)))}cancelQueries(t={},n={}){const r={revert:!0,...n},s=Hn.batch(()=>z(this,dn).findAll(t).map(i=>i.cancel(r)));return Promise.all(s).then(is).catch(is)}invalidateQueries(t={},n={}){return Hn.batch(()=>{if(z(this,dn).findAll(t).forEach(s=>{s.invalidate()}),t.refetchType==="none")return Promise.resolve();const r={...t,type:t.refetchType??t.type??"active"};return this.refetchQueries(r,n)})}refetchQueries(t={},n){const r={...n,cancelRefetch:(n==null?void 0:n.cancelRefetch)??!0},s=Hn.batch(()=>z(this,dn).findAll(t).filter(i=>!i.isDisabled()).map(i=>{let o=i.fetch(void 0,r);return r.throwOnError||(o=o.catch(is)),i.state.fetchStatus==="paused"?Promise.resolve():o}));return Promise.all(s).then(is)}fetchQuery(t){const n=this.defaultQueryOptions(t);n.retry===void 0&&(n.retry=!1);const r=z(this,dn).build(this,n);return r.isStaleByTime(Hl(n.staleTime,r))?r.fetch(n):Promise.resolve(r.state.data)}prefetchQuery(t){return this.fetchQuery(t).then(is).catch(is)}fetchInfiniteQuery(t){return t.behavior=ak(t.pages),this.fetchQuery(t)}prefetchInfiniteQuery(t){return this.fetchInfiniteQuery(t).then(is).catch(is)}ensureInfiniteQueryData(t){return t.behavior=ak(t.pages),this.ensureQueryData(t)}resumePausedMutations(){return op.isOnline()?z(this,go).resumePausedMutations():Promise.resolve()}getQueryCache(){return z(this,dn)}getMutationCache(){return z(this,go)}getDefaultOptions(){return z(this,vo)}setDefaultOptions(t){De(this,vo,t)}setQueryDefaults(t,n){z(this,Xl).set(Ya(t),{queryKey:t,defaultOptions:n})}getQueryDefaults(t){const n=[...z(this,Xl).values()];let r={};return n.forEach(s=>{ad(t,s.queryKey)&&(r={...r,...s.defaultOptions})}),r}setMutationDefaults(t,n){z(this,Ql).set(Ya(t),{mutationKey:t,defaultOptions:n})}getMutationDefaults(t){const n=[...z(this,Ql).values()];let r={};return n.forEach(s=>{ad(t,s.mutationKey)&&(r={...r,...s.defaultOptions})}),r}defaultQueryOptions(t){if(t._defaulted)return t;const n={...z(this,vo).queries,...this.getQueryDefaults(t.queryKey),...t,_defaulted:!0};return n.queryHash||(n.queryHash=Lw(n.queryKey,n)),n.refetchOnReconnect===void 0&&(n.refetchOnReconnect=n.networkMode!=="always"),n.throwOnError===void 0&&(n.throwOnError=!!n.suspense),!n.networkMode&&n.persister&&(n.networkMode="offlineFirst"),n.enabled!==!0&&n.queryFn===$w&&(n.enabled=!1),n}defaultMutationOptions(t){return t!=null&&t._defaulted?t:{...z(this,vo).mutations,...(t==null?void 0:t.mutationKey)&&this.getMutationDefaults(t.mutationKey),...t,_defaulted:!0}}clear(){z(this,dn).clear(),z(this,go).clear()}},dn=new WeakMap,go=new WeakMap,vo=new WeakMap,Xl=new WeakMap,Ql=new WeakMap,yo=new WeakMap,Jl=new WeakMap,Zl=new WeakMap,ME),_r,pt,yd,ur,xa,eu,bo,ei,bd,tu,nu,Ea,Ca,wo,ru,Pt,dc,Ey,Cy,Py,Ty,Ry,Iy,Ay,eO,DE,YG=(DE=class extends Hu{constructor(t,n){super();He(this,Pt);He(this,_r);He(this,pt);He(this,yd);He(this,ur);He(this,xa);He(this,eu);He(this,bo);He(this,ei);He(this,bd);He(this,tu);He(this,nu);He(this,Ea);He(this,Ca);He(this,wo);He(this,ru,new Set);this.options=n,De(this,_r,t),De(this,ei,null),De(this,bo,xy()),this.options.experimental_prefetchInRender||z(this,bo).reject(new Error("experimental_prefetchInRender feature flag is not enabled")),this.bindMethods(),this.setOptions(n)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(z(this,pt).addObserver(this),uk(z(this,pt),this.options)?rt(this,Pt,dc).call(this):this.updateResult(),rt(this,Pt,Ty).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return Oy(z(this,pt),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return Oy(z(this,pt),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,rt(this,Pt,Ry).call(this),rt(this,Pt,Iy).call(this),z(this,pt).removeObserver(this)}setOptions(t,n){const r=this.options,s=z(this,pt);if(this.options=z(this,_r).defaultQueryOptions(t),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof Cs(this.options.enabled,z(this,pt))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");rt(this,Pt,Ay).call(this),z(this,pt).setOptions(this.options),r._defaulted&&!ip(this.options,r)&&z(this,_r).getQueryCache().notify({type:"observerOptionsUpdated",query:z(this,pt),observer:this});const i=this.hasListeners();i&&ck(z(this,pt),s,this.options,r)&&rt(this,Pt,dc).call(this),this.updateResult(n),i&&(z(this,pt)!==s||Cs(this.options.enabled,z(this,pt))!==Cs(r.enabled,z(this,pt))||Hl(this.options.staleTime,z(this,pt))!==Hl(r.staleTime,z(this,pt)))&&rt(this,Pt,Ey).call(this);const o=rt(this,Pt,Cy).call(this);i&&(z(this,pt)!==s||Cs(this.options.enabled,z(this,pt))!==Cs(r.enabled,z(this,pt))||o!==z(this,wo))&&rt(this,Pt,Py).call(this,o)}getOptimisticResult(t){const n=z(this,_r).getQueryCache().build(z(this,_r),t),r=this.createResult(n,t);return QG(this,r)&&(De(this,ur,r),De(this,eu,this.options),De(this,xa,z(this,pt).state)),r}getCurrentResult(){return z(this,ur)}trackResult(t,n){const r={};return Object.keys(t).forEach(s=>{Object.defineProperty(r,s,{configurable:!1,enumerable:!0,get:()=>(this.trackProp(s),n==null||n(s),t[s])})}),r}trackProp(t){z(this,ru).add(t)}getCurrentQuery(){return z(this,pt)}refetch({...t}={}){return this.fetch({...t})}fetchOptimistic(t){const n=z(this,_r).defaultQueryOptions(t),r=z(this,_r).getQueryCache().build(z(this,_r),n);return r.fetch().then(()=>this.createResult(r,n))}fetch(t){return rt(this,Pt,dc).call(this,{...t,cancelRefetch:t.cancelRefetch??!0}).then(()=>(this.updateResult(),z(this,ur)))}createResult(t,n){var k;const r=z(this,pt),s=this.options,i=z(this,ur),o=z(this,xa),a=z(this,eu),u=t!==r?t.state:z(this,yd),{state:d}=t;let c={...d},f=!1,p;if(n._optimisticResults){const x=this.hasListeners(),I=!x&&uk(t,n),M=x&&ck(t,r,n,s);(I||M)&&(c={...c,...XA(d.data,t.options)}),n._optimisticResults==="isRestoring"&&(c.fetchStatus="idle")}let{error:g,errorUpdatedAt:m,status:y}=c;if(n.select&&c.data!==void 0)if(i&&c.data===(o==null?void 0:o.data)&&n.select===z(this,bd))p=z(this,tu);else try{De(this,bd,n.select),p=n.select(c.data),p=ky(i==null?void 0:i.data,p,n),De(this,tu,p),De(this,ei,null)}catch(x){De(this,ei,x)}else p=c.data;if(n.placeholderData!==void 0&&p===void 0&&y==="pending"){let x;if(i!=null&&i.isPlaceholderData&&n.placeholderData===(a==null?void 0:a.placeholderData))x=i.data;else if(x=typeof n.placeholderData=="function"?n.placeholderData((k=z(this,nu))==null?void 0:k.state.data,z(this,nu)):n.placeholderData,n.select&&x!==void 0)try{x=n.select(x),De(this,ei,null)}catch(I){De(this,ei,I)}x!==void 0&&(y="success",p=ky(i==null?void 0:i.data,x,n),f=!0)}z(this,ei)&&(g=z(this,ei),p=z(this,tu),m=Date.now(),y="error");const b=c.fetchStatus==="fetching",w=y==="pending",S=y==="error",P=w&&b,E=p!==void 0,C={status:y,fetchStatus:c.fetchStatus,isPending:w,isSuccess:y==="success",isError:S,isInitialLoading:P,isLoading:P,data:p,dataUpdatedAt:c.dataUpdatedAt,error:g,errorUpdatedAt:m,failureCount:c.fetchFailureCount,failureReason:c.fetchFailureReason,errorUpdateCount:c.errorUpdateCount,isFetched:c.dataUpdateCount>0||c.errorUpdateCount>0,isFetchedAfterMount:c.dataUpdateCount>u.dataUpdateCount||c.errorUpdateCount>u.errorUpdateCount,isFetching:b,isRefetching:b&&!w,isLoadingError:S&&!E,isPaused:c.fetchStatus==="paused",isPlaceholderData:f,isRefetchError:S&&E,isStale:Nw(t,n),refetch:this.refetch,promise:z(this,bo)};if(this.options.experimental_prefetchInRender){const x=O=>{C.status==="error"?O.reject(C.error):C.data!==void 0&&O.resolve(C.data)},I=()=>{const O=De(this,bo,C.promise=xy());x(O)},M=z(this,bo);switch(M.status){case"pending":t.queryHash===r.queryHash&&x(M);break;case"fulfilled":(C.status==="error"||C.data!==M.value)&&I();break;case"rejected":(C.status!=="error"||C.error!==M.reason)&&I();break}}return C}updateResult(t){const n=z(this,ur),r=this.createResult(z(this,pt),this.options);if(De(this,xa,z(this,pt).state),De(this,eu,this.options),z(this,xa).data!==void 0&&De(this,nu,z(this,pt)),ip(r,n))return;De(this,ur,r);const s={},i=()=>{if(!n)return!0;const{notifyOnChangeProps:o}=this.options,a=typeof o=="function"?o():o;if(a==="all"||!a&&!z(this,ru).size)return!0;const l=new Set(a??z(this,ru));return this.options.throwOnError&&l.add("error"),Object.keys(z(this,ur)).some(u=>{const d=u;return z(this,ur)[d]!==n[d]&&l.has(d)})};(t==null?void 0:t.listeners)!==!1&&i()&&(s.listeners=!0),rt(this,Pt,eO).call(this,{...s,...t})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&rt(this,Pt,Ty).call(this)}},_r=new WeakMap,pt=new WeakMap,yd=new WeakMap,ur=new WeakMap,xa=new WeakMap,eu=new WeakMap,bo=new WeakMap,ei=new WeakMap,bd=new WeakMap,tu=new WeakMap,nu=new WeakMap,Ea=new WeakMap,Ca=new WeakMap,wo=new WeakMap,ru=new WeakMap,Pt=new WeakSet,dc=function(t){rt(this,Pt,Ay).call(this);let n=z(this,pt).fetch(this.options,t);return t!=null&&t.throwOnError||(n=n.catch(is)),n},Ey=function(){rt(this,Pt,Ry).call(this);const t=Hl(this.options.staleTime,z(this,pt));if(Ka||z(this,ur).isStale||!Sy(t))return;const r=zA(z(this,ur).dataUpdatedAt,t)+1;De(this,Ea,setTimeout(()=>{z(this,ur).isStale||this.updateResult()},r))},Cy=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(z(this,pt)):this.options.refetchInterval)??!1},Py=function(t){rt(this,Pt,Iy).call(this),De(this,wo,t),!(Ka||Cs(this.options.enabled,z(this,pt))===!1||!Sy(z(this,wo))||z(this,wo)===0)&&De(this,Ca,setInterval(()=>{(this.options.refetchIntervalInBackground||Fw.isFocused())&&rt(this,Pt,dc).call(this)},z(this,wo)))},Ty=function(){rt(this,Pt,Ey).call(this),rt(this,Pt,Py).call(this,rt(this,Pt,Cy).call(this))},Ry=function(){z(this,Ea)&&(clearTimeout(z(this,Ea)),De(this,Ea,void 0))},Iy=function(){z(this,Ca)&&(clearInterval(z(this,Ca)),De(this,Ca,void 0))},Ay=function(){const t=z(this,_r).getQueryCache().build(z(this,_r),this.options);if(t===z(this,pt))return;const n=z(this,pt);De(this,pt,t),De(this,yd,t.state),this.hasListeners()&&(n==null||n.removeObserver(this),t.addObserver(this))},eO=function(t){Hn.batch(()=>{t.listeners&&this.listeners.forEach(n=>{n(z(this,ur))}),z(this,_r).getQueryCache().notify({query:z(this,pt),type:"observerResultsUpdated"})})},DE);function XG(e,t){return Cs(t.enabled,e)!==!1&&e.state.data===void 0&&!(e.state.status==="error"&&t.retryOnMount===!1)}function uk(e,t){return XG(e,t)||e.state.data!==void 0&&Oy(e,t,t.refetchOnMount)}function Oy(e,t,n){if(Cs(t.enabled,e)!==!1){const r=typeof n=="function"?n(e):n;return r==="always"||r!==!1&&Nw(e,t)}return!1}function ck(e,t,n,r){return(e!==t||Cs(r.enabled,e)===!1)&&(!n.suspense||e.state.status!=="error")&&Nw(e,n)}function Nw(e,t){return Cs(t.enabled,e)!==!1&&e.isStaleByTime(Hl(t.staleTime,e))}function QG(e,t){return!ip(e.getCurrentResult(),t)}var So,_o,kr,Ii,$i,lh,My,LE,JG=(LE=class extends Hu{constructor(n,r){super();He(this,$i);He(this,So);He(this,_o);He(this,kr);He(this,Ii);De(this,So,n),this.setOptions(r),this.bindMethods(),rt(this,$i,lh).call(this)}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(n){var s;const r=this.options;this.options=z(this,So).defaultMutationOptions(n),ip(this.options,r)||z(this,So).getMutationCache().notify({type:"observerOptionsUpdated",mutation:z(this,kr),observer:this}),r!=null&&r.mutationKey&&this.options.mutationKey&&Ya(r.mutationKey)!==Ya(this.options.mutationKey)?this.reset():((s=z(this,kr))==null?void 0:s.state.status)==="pending"&&z(this,kr).setOptions(this.options)}onUnsubscribe(){var n;this.hasListeners()||(n=z(this,kr))==null||n.removeObserver(this)}onMutationUpdate(n){rt(this,$i,lh).call(this),rt(this,$i,My).call(this,n)}getCurrentResult(){return z(this,_o)}reset(){var n;(n=z(this,kr))==null||n.removeObserver(this),De(this,kr,void 0),rt(this,$i,lh).call(this),rt(this,$i,My).call(this)}mutate(n,r){var s;return De(this,Ii,r),(s=z(this,kr))==null||s.removeObserver(this),De(this,kr,z(this,So).getMutationCache().build(z(this,So),this.options)),z(this,kr).addObserver(this),z(this,kr).execute(n)}},So=new WeakMap,_o=new WeakMap,kr=new WeakMap,Ii=new WeakMap,$i=new WeakSet,lh=function(){var r;const n=((r=z(this,kr))==null?void 0:r.state)??JA();De(this,_o,{...n,isPending:n.status==="pending",isSuccess:n.status==="success",isError:n.status==="error",isIdle:n.status==="idle",mutate:this.mutate,reset:this.reset})},My=function(n){Hn.batch(()=>{var r,s,i,o,a,l,u,d;if(z(this,Ii)&&this.hasListeners()){const c=z(this,_o).variables,f=z(this,_o).context;(n==null?void 0:n.type)==="success"?((s=(r=z(this,Ii)).onSuccess)==null||s.call(r,n.data,c,f),(o=(i=z(this,Ii)).onSettled)==null||o.call(i,n.data,null,c,f)):(n==null?void 0:n.type)==="error"&&((l=(a=z(this,Ii)).onError)==null||l.call(a,n.error,c,f),(d=(u=z(this,Ii)).onSettled)==null||d.call(u,void 0,n.error,c,f))}this.listeners.forEach(c=>{c(z(this,_o))})})},LE),ZG="VUE_QUERY_CLIENT";function tO(e){const t=e?`:${e}`:"";return`${ZG}${t}`}function Dy(e,t){Object.keys(e).forEach(n=>{e[n]=t[n]})}function Ly(e,t,n="",r=0){if(t){const s=t(e,n,r);if(s===void 0&&tt(e)||s!==void 0)return s}if(Array.isArray(e))return e.map((s,i)=>Ly(s,t,String(i),r+1));if(typeof e=="object"&&t7(e)){const s=Object.entries(e).map(([i,o])=>[i,Ly(o,t,i,r+1)]);return Object.fromEntries(s)}return e}function e7(e,t){return Ly(e,t)}function it(e,t=!1){return e7(e,(n,r,s)=>{if(s===1&&r==="queryKey")return it(n,!0);if(t&&n7(n))return it(n(),t);if(tt(n))return it(ie(n),t)})}function t7(e){if(Object.prototype.toString.call(e)!=="[object Object]")return!1;const t=Object.getPrototypeOf(e);return t===null||t===Object.prototype}function n7(e){return typeof e=="function"}function $y(e,t){return typeof e=="function"?e(...t):!!e}function Bw(e=""){if(!IC())throw new Error("vue-query hooks can only be used inside setup() function or functions that support injection context.");const t=tO(e),n=Ye(t);if(!n)throw new Error("No 'queryClient' found in Vue context, use 'VueQueryPlugin' to properly initialize the library.");return n}var r7=class extends QA{find(e){return super.find(it(e))}findAll(e={}){return super.findAll(it(e))}},s7=class extends ZA{find(e){return super.find(it(e))}findAll(e={}){return super.findAll(it(e))}},i7=class extends KG{constructor(e={}){const t={defaultOptions:e.defaultOptions,queryCache:e.queryCache||new r7,mutationCache:e.mutationCache||new s7};super(t),this.isRestoring=U(!1)}isFetching(e={}){return super.isFetching(it(e))}isMutating(e={}){return super.isMutating(it(e))}getQueryData(e){return super.getQueryData(it(e))}ensureQueryData(e){return super.ensureQueryData(it(e))}getQueriesData(e){return super.getQueriesData(it(e))}setQueryData(e,t,n={}){return super.setQueryData(it(e),t,it(n))}setQueriesData(e,t,n={}){return super.setQueriesData(it(e),t,it(n))}getQueryState(e){return super.getQueryState(it(e))}removeQueries(e={}){return super.removeQueries(it(e))}resetQueries(e={},t={}){return super.resetQueries(it(e),it(t))}cancelQueries(e={},t={}){return super.cancelQueries(it(e),it(t))}invalidateQueries(e={},t={}){const n=it(e),r=it(t);if(super.invalidateQueries({...n,refetchType:"none"},r),n.refetchType==="none")return Promise.resolve();const s={...n,type:n.refetchType??n.type??"active"};return Ot().then(()=>super.refetchQueries(s,r))}refetchQueries(e={},t={}){return super.refetchQueries(it(e),it(t))}fetchQuery(e){return super.fetchQuery(it(e))}prefetchQuery(e){return super.prefetchQuery(it(e))}fetchInfiniteQuery(e){return super.fetchInfiniteQuery(it(e))}prefetchInfiniteQuery(e){return super.prefetchInfiniteQuery(it(e))}setDefaultOptions(e){super.setDefaultOptions(it(e))}setQueryDefaults(e,t){super.setQueryDefaults(it(e),it(t))}getQueryDefaults(e){return super.getQueryDefaults(it(e))}setMutationDefaults(e,t){super.setMutationDefaults(it(e),it(t))}getMutationDefaults(e){return super.getMutationDefaults(it(e))}},o7={install:(e,t={})=>{const n=tO(t.queryClientKey);let r;if("queryClient"in t&&t.queryClient)r=t.queryClient;else{const o="queryClientConfig"in t?t.queryClientConfig:void 0;r=new i7(o)}Ka||r.mount();let s=()=>{};if(t.clientPersister){r.isRestoring.value=!0;const[o,a]=t.clientPersister(r);s=o,a.then(()=>{var l;r.isRestoring.value=!1,(l=t.clientPersisterOnSuccess)==null||l.call(t,r)})}const i=()=>{r.unmount(),s()};if(e.onUnmount)e.onUnmount(i);else{const o=e.unmount;e.unmount=function(){i(),o()}}e.provide(n,r)}};function a7(e,t,n){const r=Bw(),s=R(()=>{const p=it(t);typeof p.enabled=="function"&&(p.enabled=p.enabled());const g=r.defaultQueryOptions(p);return g._optimisticResults=r.isRestoring.value?"isRestoring":"optimistic",g}),i=new e(r,s.value),o=Cp(i.getCurrentResult());let a=()=>{};Ce(r.isRestoring,p=>{p||(a(),a=i.subscribe(g=>{Dy(o,g)}))},{immediate:!0});const l=()=>{i.setOptions(s.value),Dy(o,i.getCurrentResult())};Ce(s,l),Sn(()=>{a()});const u=(...p)=>(l(),o.refetch(...p)),d=()=>new Promise((p,g)=>{let m=()=>{};const y=()=>{if(s.value.enabled!==!1){i.setOptions(s.value);const b=i.getOptimisticResult(s.value);b.isStale?(m(),i.fetchOptimistic(s.value).then(p,w=>{$y(s.value.throwOnError,[w,i.getCurrentQuery()])?g(w):p(i.getCurrentResult())})):(m(),p(b))}};y(),m=Ce(s,y)});Ce(()=>o.error,p=>{if(o.isError&&!o.isFetching&&$y(s.value.throwOnError,[p,i.getCurrentQuery()]))throw p});const f=jo(o);for(const p in o)typeof o[p]=="function"&&(f[p]=o[p]);return f.suspense=d,f.refetch=u,f}function Vw(e,t){return a7(YG,e)}function l7(e,t){const n=Bw(),r=R(()=>n.defaultMutationOptions(it(e))),s=new JG(n,r.value),i=Cp(s.getCurrentResult()),o=s.subscribe(d=>{Dy(i,d)}),a=(d,c)=>{s.mutate(d,c).catch(()=>{})};Ce(r,()=>{s.setOptions(r.value)}),Sn(()=>{o()});const u=jo(i);return Ce(()=>i.error,d=>{if(d&&$y(r.value.throwOnError,[d]))throw d}),{...u,mutate:a,mutateAsync:i.mutate,reset:i.reset}}const u7=de({...Ve(),...$r(),...TA()},"VLayout"),ym=xe()({name:"VLayout",props:u7(),setup(e,t){let{slots:n}=t;const{layoutClasses:r,layoutStyles:s,getLayoutItem:i,items:o,layoutRef:a}=OA(e),{dimensionStyles:l}=Fr(e);return Ie(()=>{var u;return h("div",{ref:a,class:[r.value,e.class],style:[l.value,s.value,e.style]},[(u=n.default)==null?void 0:u.call(n)])}),{getLayoutItem:i,items:o}}}),c7={class:"text-h5"},d7={key:0},f7={key:1},h7=Le({__name:"AddOrUpdateCameraStreamDialog",setup(e){const t=Bw(),n=Fn(Jt.AddOrUpdateCameraDialog),r=R(()=>"C"),s=U({name:"",streamURL:""}),i=()=>{var c;return((c=n.context())==null?void 0:c.addOrUpdate)==="update"},o=R(()=>i());Ce(()=>n.context(),c=>{var p;if(!c||(c==null?void 0:c.addOrUpdate)!=="update"){s.value.streamURL="",s.value.name="";return}const f=(p=t.getQueryData(["cameraStream"]))==null?void 0:p.find(g=>g.cameraStream.id===c.cameraId);s.value.name=f==null?void 0:f.cameraStream.name,s.value.streamURL=(f==null?void 0:f.cameraStream.streamURL)||""});function a(){n.closeDialog()}async function l(){await sp.createCameraStream({streamURL:s.value.streamURL,name:s.value.name}),await t.refetchQueries({queryKey:["cameraStream"]}),n.closeDialog()}async function u(){var c;await sp.updateCameraStream((c=n.context())==null?void 0:c.cameraId,{streamURL:s.value.streamURL,name:s.value.name}),await t.refetchQueries({queryKey:["cameraStream"]}),n.closeDialog()}function d(){n.closeDialog()}return(c,f)=>{const p=gi;return $(),Q(p,{id:ie(n).dialogId,"max-width":"800px",onEscape:f[3]||(f[3]=g=>a())},{default:v(()=>[h(yt,null,{default:v(()=>[h(an,null,{default:v(()=>[L("span",c7,[h(lt,{class:"mr-2",color:"primary",size:"56"},{default:v(()=>[_(ae(r.value),1)]),_:1}),o.value?($(),we("span",d7," Updating Camera ")):($(),we("span",f7," New Camera "))])]),_:1}),h(nn,null,{default:v(()=>[h(Pn,{"grid-list-md":""},{default:v(()=>[h(ym,{wrap:""},{default:v(()=>[h(ct,{modelValue:s.value.name,"onUpdate:modelValue":f[0]||(f[0]=g=>s.value.name=g),label:"Name",required:""},null,8,["modelValue"]),h(ct,{modelValue:s.value.streamURL,"onUpdate:modelValue":f[1]||(f[1]=g=>s.value.streamURL=g),label:"Url (MJPEG)",required:""},null,8,["modelValue"])]),_:1})]),_:1})]),_:1}),h(Nn,null,{default:v(()=>[h(wn),h(re,{color:"primary-darken-2",onClick:d},{default:v(()=>f[4]||(f[4]=[_(" Cancel ")])),_:1}),h(re,{color:"primary",onClick:f[2]||(f[2]=g=>o.value?u():l())},{default:v(()=>[_(ae(o.value?"Update":"Create"),1)]),_:1})]),_:1})]),_:1})]),_:1},8,["id"])}}}),Uw=Ms("TestPrinter",{state:()=>({currentCorrelationToken:void 0,testPrinter:void 0,testPrinterEvents:[]}),getters:{getEvents(){return()=>{var e;return(((e=this.testPrinterEvents)==null?void 0:e.filter(t=>t.correlationToken===this.currentCorrelationToken))||[]).filter(t=>(t.event!=="API_STATE_UPDATED"||t.payload!=="unset")&&(t.event!=="WS_STATE_UPDATED"||t.payload!=="unopened")).map(t=>{var r,s,i;return{event:t.event.startsWith("WS_")?"Socket":"API",payload:(s=(r=t.payload)==null?void 0:r.toString())==null?void 0:s.replace("noResponse","unreachable").replace("authFail","authentication failure"),failure:["authFail","noResponse","aborted","globalKey","error","connection error","closed","connection closed"].includes((i=t.payload)==null?void 0:i.toString())}})}}},actions:{clearEvents(){this.testPrinterEvents=[]},async createTestPrinter(e){return this.testPrinter=e,await Wt.testConnection(e)},saveEvent(e){var t;(t=this.testPrinterEvents)==null||t.push(e)}}}),p7="error",m7="success",g7=Le({__name:"PrinterChecksPanel",setup(e){const t=Uw(),n=U(4);function r(){return t.getEvents().map(s=>({label:s.event,text:s.payload,color:s.failure?p7:m7}))}return(s,i)=>($(),Q(Ue,{cols:ie(n)},{default:v(()=>[i[0]||(i[0]=L("strong",null," Checks: ",-1)),($(!0),we(Re,null,Zt(r(),(o,a)=>($(),Q(un,{key:a,type:o.color,density:"compact"},{default:v(()=>[L("small",null,ae(o.label)+" "+ae(o.text),1)]),_:2},1032,["type"]))),128))]),_:1},8,["cols"]))}}),v7="/assets/klipper-logo-B1Hu-a1R.svg",dk="/assets/octoprint-tentacle-D_4slObB.svg",nO=Symbol.for("vuetify:v-item-group"),y7=de({...Ve(),...Cd({selectedClass:"v-item--selected"}),...bt(),...Dt()},"VItemGroup"),b7=xe()({name:"VItemGroup",props:y7(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const{themeClasses:r}=Xt(e),{isSelected:s,select:i,next:o,prev:a,selected:l}=Cu(e,nO);return()=>h(e.tag,{class:["v-item-group",r.value,e.class],style:e.style},{default:()=>{var u;return[(u=n.default)==null?void 0:u.call(n,{isSelected:s,select:i,next:o,prev:a,selected:l.value})]}})}}),w7=xe()({name:"VItem",props:Pd(),emits:{"group:selected":e=>!0},setup(e,t){let{slots:n}=t;const{isSelected:r,select:s,toggle:i,selectedClass:o,value:a,disabled:l}=Td(e,nO);return()=>{var u;return(u=n.default)==null?void 0:u.call(n,{isSelected:r.value,selectedClass:o.value,select:s,toggle:i,value:a.value,disabled:l.value})}}}),S7={class:"text-h5"},_7={key:0},k7={key:1},x7={class:"ml-3 align-center"},E7=Le({__name:"AddOrUpdatePrinterDialog",setup(e){const t=Fn(Jt.AddOrUpdatePrinterDialog),n=Nt(),r=Uw(),s=Yi(),i=Ye("appConstants"),o=Mt(),a=U(null),l=U(!1),u=U(!1),d=U(!1),c=U(""),f=U(my()),p=R(()=>{var A,D;if(s.hasFeature("multiplePrinterServices")){const V=s.getFeature("multiplePrinterServices");if((D=(A=V==null?void 0:V.subFeatures)==null?void 0:A.types)==null?void 0:D.includes("klipper"))return[{name:"OctoPrint",logo:dk,height:"75px"},{name:"Klipper",logo:v7,height:"75px"}]}return[{name:"OctoPrint",logo:dk,height:"75px"}]}),g=R(()=>{var A;return(A=n.updateDialogPrinter)==null?void 0:A.id});St(async()=>{if(g.value){const A=n.printer(g.value);f.value=Wt.convertPrinterToCreateForm(A)}}),Ce(g,A=>{if(!A)return;const D=n.printer(A);f.value=Wt.convertPrinterToCreateForm(D)});const m=R(()=>n.updateDialogPrinter),y=R(()=>!!m.value),b=R(()=>y?"Save":"Create"),w=R(()=>{var A;return f?dm((A=f.value)==null?void 0:A.name):"?"}),S=R(()=>({required:!0,max:i.maxPrinterNameLength})),P=R(()=>({required:!0,length:i.apiKeyLength,alpha_num:!0}));function E(){f.value=my()}function T(){d.value=!0}async function C(){if(!f)return;r.clearEvents(),T();const{correlationToken:A}=await r.createTestPrinter(f.value);r.currentCorrelationToken=A}async function k(A){await n.createPrinter(A,u.value),o.openInfoMessage({title:`Printer ${A.name} created`})}async function x(A){const D=A.id;await n.updatePrinter({printerId:D,updatedPrinter:A},u.value),o.openInfoMessage({title:`Printer ${A.name} updated`})}async function I(){var D,V,H,G,j;if(!f)return;a.value=null,l.value=!0,(D=f.value.printerURL)!=null&&D.length&&!((V=f.value.printerURL)!=null&&V.startsWith("http://"))&&!((H=f.value.printerURL)!=null&&H.startsWith("https://"))&&(f.value.printerURL+="https://");const A=f.value;try{y.value?await x(A):await k(A),O()}catch(B){B instanceof OT?(a.value=((j=(G=B.response)==null?void 0:G.data)==null?void 0:j.error)||B.message,o.error("Validation Failed",B.message)):(a.value=B.message,o.error("Error",B.message))}finally{l.value=!1,u.value=!1}}async function M(){f.value.name=Wa(),n.updateDialogPrinter=void 0,a.value=null,u.value=!1,a.value=null}function O(){t.closeDialog(),u.value=!1,a.value=null,d.value=!1,r.clearEvents(),E(),n.updateDialogPrinter=void 0,c.value=""}return(A,D)=>{const V=g7,H=gi;return $(),Q(H,{id:ie(t).dialogId,"max-width":ie(d)?"900px":"700px",onEscape:D[11]||(D[11]=G=>O())},{default:v(()=>[h(yt,{class:"pa-4"},{default:v(()=>[h(an,null,{default:v(()=>[L("span",S7,[h(lt,{color:"primary",size:"56"},{default:v(()=>[_(ae(ie(w)),1)]),_:1}),ie(y)?($(),we("span",_7," Updating Printer ")):($(),we("span",k7," New Printer "))])]),_:1}),h(nn,null,{default:v(()=>{var G;return[D[14]||(D[14]=L("h4",null,"Printer type",-1)),h(b7,{modelValue:ie(f).printerType,"onUpdate:modelValue":D[0]||(D[0]=j=>ie(f).printerType=j),mandatory:""},{default:v(()=>[h(Pn,null,{default:v(()=>[h(at,null,{default:v(()=>[($(!0),we(Re,null,Zt(ie(p),j=>($(),Q(Ue,{key:j.name,cols:"12",md:"6"},{default:v(()=>[h(w7,null,{default:v(({isSelected:B,toggle:W})=>[h(yt,{color:B?"primary":"blue-grey darken-4",class:"d-flex align-center justify-center elevation-8",height:"75px",width:"225px",onClick:W},{default:v(()=>[h(Ki,{src:j.logo,height:j.height,"max-width":"125px",width:"125px"},null,8,["src","height"]),h(CN,null,{default:v(()=>[L("h3",x7,ae(j.name),1)]),_:2},1024)]),_:2},1032,["color","onClick"])]),_:2},1024)]),_:2},1024))),128))]),_:1})]),_:1})]),_:1},8,["modelValue"]),h(at,null,{default:v(()=>[h(Ue,{cols:ie(d)?8:12},{default:v(()=>[ie(f)?($(),Q(at,{key:0},{default:v(()=>[h(Ue,null,{default:v(()=>[h(ct,{modelValue:ie(f).name,"onUpdate:modelValue":D[1]||(D[1]=j=>ie(f).name=j),counter:ie(S).max,autofocus:"",class:"ma-1",label:"Printer name*",required:""},null,8,["modelValue","counter"])]),_:1}),h(Ue,null,{default:v(()=>[h(On,{modelValue:ie(f).enabled,"onUpdate:modelValue":D[2]||(D[2]=j=>ie(f).enabled=j),hint:"Disabling makes the printer passive",label:"Enabled*","persistent-hint":"",required:""},null,8,["modelValue"])]),_:1})]),_:1})):ve("",!0),h(ct,{modelValue:ie(f).printerURL,"onUpdate:modelValue":D[3]||(D[3]=j=>ie(f).printerURL=j),class:"ma-1",hint:"F.e. 'octopi.local' or 'https://my.printer.com'",label:"Printer URL*"},null,8,["modelValue"]),h(ct,{modelValue:ie(f).apiKey,"onUpdate:modelValue":D[4]||(D[4]=j=>ie(f).apiKey=j),counter:ie(P).length,class:"ma-1",hint:"User or Application Key with 32 or 43 characters (Global API key will fail)",label:"API Key*","persistent-hint":"",required:""},null,8,["modelValue","counter"])]),_:1},8,["cols"]),ie(d)?($(),Q(V,{key:0,cols:4},{default:v(()=>[h(re,{onClick:D[5]||(D[5]=j=>d.value=!1)},{default:v(()=>D[12]||(D[12]=[_(" Hide checks ")])),_:1})]),_:1})):ve("",!0)]),_:1}),(G=ie(a))!=null&&G.length?($(),Q(un,{key:0,color:"primary",class:"my-3"},{default:v(()=>[_(ae(ie(a))+" ",1),h(On,{color:"warning",modelValue:ie(u),"onUpdate:modelValue":D[6]||(D[6]=j=>tt(u)?u.value=j:null),label:"Force save"},null,8,["modelValue"])]),_:1})):ve("",!0),ie(l)?($(),Q(un,{key:1,class:"my-3"},{default:v(()=>[D[13]||(D[13]=_(" Validating printer ")),h(Id,{indeterminate:""})]),_:1})):ve("",!0)]}),_:1}),h(Nn,null,{default:v(()=>[D[18]||(D[18]=L("em",{class:"text-red"}," * indicates required field ",-1)),h(wn),h(re,{variant:"text",onClick:D[7]||(D[7]=G=>O())},{default:v(()=>D[15]||(D[15]=[_(" Close ")])),_:1}),ie(y)?($(),Q(re,{key:0,color:"gray",variant:"text",onClick:D[8]||(D[8]=G=>M())},{default:v(()=>D[16]||(D[16]=[_(" Duplicate ")])),_:1})):ve("",!0),h(re,{color:"warning",variant:"text",onClick:D[9]||(D[9]=G=>C())},{default:v(()=>D[17]||(D[17]=[_(" Test connection ")])),_:1}),h(re,{color:"blue-darken-1",variant:"text",onClick:D[10]||(D[10]=G=>I())},{default:v(()=>[_(ae(ie(b)),1)]),_:1})]),_:1})]),_:1})]),_:1},8,["id","max-width"])}}}),C7=de({text:String,...Ve(),...bt()},"VToolbarTitle"),mn=xe()({name:"VToolbarTitle",props:C7(),setup(e,t){let{slots:n}=t;return Ie(()=>{const r=!!(n.default||n.text||e.text);return h(e.tag,{class:["v-toolbar-title",e.class],style:e.style},{default:()=>{var s;return[r&&h("div",{class:"v-toolbar-title__placeholder"},[n.text?n.text():e.text,(s=n.default)==null?void 0:s.call(n)])]}})}),{}}}),P7=[null,"prominent","default","comfortable","compact"],rO=de({absolute:Boolean,collapse:Boolean,color:String,density:{type:String,default:"default",validator:e=>P7.includes(e)},extended:Boolean,extensionHeight:{type:[Number,String],default:48},flat:Boolean,floating:Boolean,height:{type:[Number,String],default:64},image:String,title:String,...vs(),...Ve(),...bs(),...Bn(),...bt({tag:"header"}),...Dt()},"VToolbar"),sr=xe()({name:"VToolbar",props:rO(),setup(e,t){var p;let{slots:n}=t;const{backgroundColorClasses:r,backgroundColorStyles:s}=pr(Te(e,"color")),{borderClasses:i}=Ls(e),{elevationClasses:o}=$s(e),{roundedClasses:a}=qn(e),{themeClasses:l}=Xt(e),{rtlClasses:u}=Nr(),d=Me(!!(e.extended||(p=n.extension)!=null&&p.call(n))),c=R(()=>parseInt(Number(e.height)+(e.density==="prominent"?Number(e.height):0)-(e.density==="comfortable"?8:0)-(e.density==="compact"?16:0),10)),f=R(()=>d.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 Dr({VBtn:{variant:"text"}}),Ie(()=>{var b;const g=!!(e.title||n.title),m=!!(n.image||e.image),y=(b=n.extension)==null?void 0:b.call(n);return d.value=!!(e.extended||y),h(e.tag,{class:["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},r.value,i.value,o.value,a.value,l.value,u.value,e.class],style:[s.value,e.style]},{default:()=>[m&&h("div",{key:"image",class:"v-toolbar__image"},[n.image?h(At,{key:"image-defaults",disabled:!e.image,defaults:{VImg:{cover:!0,src:e.image}}},n.image):h(Ki,{key:"image-img",cover:!0,src:e.image},null)]),h(At,{defaults:{VTabs:{height:Ne(c.value)}}},{default:()=>{var w,S,P;return[h("div",{class:"v-toolbar__content",style:{height:Ne(c.value)}},[n.prepend&&h("div",{class:"v-toolbar__prepend"},[(w=n.prepend)==null?void 0:w.call(n)]),g&&h(mn,{key:"title",text:e.title},{text:n.title}),(S=n.default)==null?void 0:S.call(n),n.append&&h("div",{class:"v-toolbar__append"},[(P=n.append)==null?void 0:P.call(n)])])]}}),h(At,{defaults:{VTabs:{height:Ne(f.value)}}},{default:()=>[h(QP,null,{default:()=>[d.value&&h("div",{class:"v-toolbar__extension",style:{height:Ne(f.value)}},[y])]})]})]})}),{contentHeight:c,extensionHeight:f}}}),T7=Le({__name:"HelpOverlay",setup(e){const t=U(!1);return(n,r)=>($(),Q(oT,{modelValue:ie(t),"onUpdate:modelValue":r[0]||(r[0]=s=>tt(t)?t.value=s:null),fullscreen:"",eager:"",transition:"dialog-bottom-transition",width:"100%"},{activator:v(({props:s})=>[h(xt,{location:"top"},{activator:v(({props:i})=>[h(re,me({icon:"help"},{...s,...i}),{default:v(()=>[h(X,null,{default:v(()=>r[1]||(r[1]=[_("help")])),_:1})]),_:2},1040)]),default:v(()=>[r[2]||(r[2]=L("span",null," Load the online documentation webpage ",-1))]),_:2},1024)]),default:v(({isActive:s})=>[h(yt,{height:"100%",width:"100%"},{default:v(()=>[h(sr,{color:"primary"},{default:v(()=>[h(X,{class:"ml-5"},{default:v(()=>r[3]||(r[3]=[_("help")])),_:1}),r[6]||(r[6]=L("h2",{class:"ml-10"},"FDM Monster Documentation",-1)),h(wn),r[7]||(r[7]=L("span",{class:"mr-10"}," docs.fdm-monster.net ",-1)),h(re,{variant:"flat",onClick:i=>s.value=!1},{default:v(()=>[h(X,{class:"mr-2"},{default:v(()=>r[4]||(r[4]=[_("close")])),_:1}),r[5]||(r[5]=_(" Close help "))]),_:2},1032,["onClick"])]),_:2},1024),r[8]||(r[8]=L("iframe",{height:"100%",src:"https://docs.fdm-monster.net",style:{"background-color":"black","border-width":"0"},width:"100%"},null,-1))]),_:2},1024)]),_:1},8,["modelValue"]))}}),R7=Le({__name:"TooltipButton",props:{tooltip:{},color:{default:"white"},icon:{default:""},iconClass:{default:""},text:{default:""},location:{default:"bottom"}},emits:["click"],setup(e){const t=e;return(n,r)=>($(),Q(xt,{location:t.location},{activator:v(({props:s})=>[h(re,me(s,{variant:"outlined",class:"ml-2",color:n.color,onClick:r[0]||(r[0]=i=>n.$emit("click"))}),{default:v(()=>[Mp(n.$slots,"default",{},()=>{var i;return[(i=t.icon)!=null&&i.length?($(),Q(X,{key:0,class:Ja("mr-2 "+t.iconClass)},{default:v(()=>[_(ae(t.icon),1)]),_:1},8,["class"])):ve("",!0),_(" "+ae(t.text),1)]})]),_:2},1040,["color"])]),default:v(()=>[L("span",null,ae(t.tooltip),1)]),_:3},8,["location"]))}});/*!
64
+ * vue-router v4.4.5
65
+ * (c) 2024 Eduardo San Martin Morote
66
+ * @license MIT
67
+ */const El=typeof document<"u";function sO(e){return typeof e=="object"||"displayName"in e||"props"in e||"__vccOpts"in e}function I7(e){return e.__esModule||e[Symbol.toStringTag]==="Module"||e.default&&sO(e.default)}const Rt=Object.assign;function Cg(e,t){const n={};for(const r in t){const s=t[r];n[r]=Os(s)?s.map(e):e(s)}return n}const Ic=()=>{},Os=Array.isArray,iO=/#/g,A7=/&/g,O7=/\//g,M7=/=/g,D7=/\?/g,oO=/\+/g,L7=/%5B/g,$7=/%5D/g,aO=/%5E/g,F7=/%60/g,lO=/%7B/g,N7=/%7C/g,uO=/%7D/g,B7=/%20/g;function Hw(e){return encodeURI(""+e).replace(N7,"|").replace(L7,"[").replace($7,"]")}function V7(e){return Hw(e).replace(lO,"{").replace(uO,"}").replace(aO,"^")}function Fy(e){return Hw(e).replace(oO,"%2B").replace(B7,"+").replace(iO,"%23").replace(A7,"%26").replace(F7,"`").replace(lO,"{").replace(uO,"}").replace(aO,"^")}function U7(e){return Fy(e).replace(M7,"%3D")}function H7(e){return Hw(e).replace(iO,"%23").replace(D7,"%3F")}function z7(e){return e==null?"":H7(e).replace(O7,"%2F")}function ld(e){try{return decodeURIComponent(""+e)}catch{}return""+e}const j7=/\/$/,q7=e=>e.replace(j7,"");function Pg(e,t,n="/"){let r,s={},i="",o="";const a=t.indexOf("#");let l=t.indexOf("?");return a<l&&a>=0&&(l=-1),l>-1&&(r=t.slice(0,l),i=t.slice(l+1,a>-1?a:t.length),s=e(i)),a>-1&&(r=r||t.slice(0,a),o=t.slice(a,t.length)),r=Y7(r??t,n),{fullPath:r+(i&&"?")+i+o,path:r,query:s,hash:ld(o)}}function W7(e,t){const n=t.query?e(t.query):"";return t.path+(n&&"?")+n+(t.hash||"")}function fk(e,t){return!t||!e.toLowerCase().startsWith(t.toLowerCase())?e:e.slice(t.length)||"/"}function G7(e,t,n){const r=t.matched.length-1,s=n.matched.length-1;return r>-1&&r===s&&bu(t.matched[r],n.matched[s])&&cO(t.params,n.params)&&e(t.query)===e(n.query)&&t.hash===n.hash}function bu(e,t){return(e.aliasOf||e)===(t.aliasOf||t)}function cO(e,t){if(Object.keys(e).length!==Object.keys(t).length)return!1;for(const n in e)if(!K7(e[n],t[n]))return!1;return!0}function K7(e,t){return Os(e)?hk(e,t):Os(t)?hk(t,e):e===t}function hk(e,t){return Os(t)?e.length===t.length&&e.every((n,r)=>n===t[r]):e.length===1&&e[0]===t}function Y7(e,t){if(e.startsWith("/"))return e;if(!e)return t;const n=t.split("/"),r=e.split("/"),s=r[r.length-1];(s===".."||s===".")&&r.push("");let i=n.length-1,o,a;for(o=0;o<r.length;o++)if(a=r[o],a!==".")if(a==="..")i>1&&i--;else break;return n.slice(0,i).join("/")+"/"+r.slice(o).join("/")}const Zi={path:"/",name:void 0,params:{},query:{},hash:"",fullPath:"/",matched:[],meta:{},redirectedFrom:void 0};var ud;(function(e){e.pop="pop",e.push="push"})(ud||(ud={}));var Ac;(function(e){e.back="back",e.forward="forward",e.unknown=""})(Ac||(Ac={}));function X7(e){if(!e)if(El){const t=document.querySelector("base");e=t&&t.getAttribute("href")||"/",e=e.replace(/^\w+:\/\/[^\/]+/,"")}else e="/";return e[0]!=="/"&&e[0]!=="#"&&(e="/"+e),q7(e)}const Q7=/^[^#]+#/;function J7(e,t){return e.replace(Q7,"#")+t}function Z7(e,t){const n=document.documentElement.getBoundingClientRect(),r=e.getBoundingClientRect();return{behavior:t.behavior,left:r.left-n.left-(t.left||0),top:r.top-n.top-(t.top||0)}}const bm=()=>({left:window.scrollX,top:window.scrollY});function eK(e){let t;if("el"in e){const n=e.el,r=typeof n=="string"&&n.startsWith("#"),s=typeof n=="string"?r?document.getElementById(n.slice(1)):document.querySelector(n):n;if(!s)return;t=Z7(s,e)}else t=e;"scrollBehavior"in document.documentElement.style?window.scrollTo(t):window.scrollTo(t.left!=null?t.left:window.scrollX,t.top!=null?t.top:window.scrollY)}function pk(e,t){return(history.state?history.state.position-t:-1)+e}const Ny=new Map;function tK(e,t){Ny.set(e,t)}function nK(e){const t=Ny.get(e);return Ny.delete(e),t}let rK=()=>location.protocol+"//"+location.host;function dO(e,t){const{pathname:n,search:r,hash:s}=t,i=e.indexOf("#");if(i>-1){let a=s.includes(e.slice(i))?e.slice(i).length:1,l=s.slice(a);return l[0]!=="/"&&(l="/"+l),fk(l,"")}return fk(n,e)+r+s}function sK(e,t,n,r){let s=[],i=[],o=null;const a=({state:f})=>{const p=dO(e,location),g=n.value,m=t.value;let y=0;if(f){if(n.value=p,t.value=f,o&&o===g){o=null;return}y=m?f.position-m.position:0}else r(p);s.forEach(b=>{b(n.value,g,{delta:y,type:ud.pop,direction:y?y>0?Ac.forward:Ac.back:Ac.unknown})})};function l(){o=n.value}function u(f){s.push(f);const p=()=>{const g=s.indexOf(f);g>-1&&s.splice(g,1)};return i.push(p),p}function d(){const{history:f}=window;f.state&&f.replaceState(Rt({},f.state,{scroll:bm()}),"")}function c(){for(const f of i)f();i=[],window.removeEventListener("popstate",a),window.removeEventListener("beforeunload",d)}return window.addEventListener("popstate",a),window.addEventListener("beforeunload",d,{passive:!0}),{pauseListeners:l,listen:u,destroy:c}}function mk(e,t,n,r=!1,s=!1){return{back:e,current:t,forward:n,replaced:r,position:window.history.length,scroll:s?bm():null}}function iK(e){const{history:t,location:n}=window,r={value:dO(e,n)},s={value:t.state};s.value||i(r.value,{back:null,current:r.value,forward:null,position:t.length-1,replaced:!0,scroll:null},!0);function i(l,u,d){const c=e.indexOf("#"),f=c>-1?(n.host&&document.querySelector("base")?e:e.slice(c))+l:rK()+e+l;try{t[d?"replaceState":"pushState"](u,"",f),s.value=u}catch(p){console.error(p),n[d?"replace":"assign"](f)}}function o(l,u){const d=Rt({},t.state,mk(s.value.back,l,s.value.forward,!0),u,{position:s.value.position});i(l,d,!0),r.value=l}function a(l,u){const d=Rt({},s.value,t.state,{forward:l,scroll:bm()});i(d.current,d,!0);const c=Rt({},mk(r.value,l,null),{position:d.position+1},u);i(l,c,!1),r.value=l}return{location:r,state:s,push:a,replace:o}}function oK(e){e=X7(e);const t=iK(e),n=sK(e,t.state,t.location,t.replace);function r(i,o=!0){o||n.pauseListeners(),history.go(i)}const s=Rt({location:"",base:e,go:r,createHref:J7.bind(null,e)},t,n);return Object.defineProperty(s,"location",{enumerable:!0,get:()=>t.location.value}),Object.defineProperty(s,"state",{enumerable:!0,get:()=>t.state.value}),s}function aK(e){return typeof e=="string"||e&&typeof e=="object"}function fO(e){return typeof e=="string"||typeof e=="symbol"}const hO=Symbol("");var gk;(function(e){e[e.aborted=4]="aborted",e[e.cancelled=8]="cancelled",e[e.duplicated=16]="duplicated"})(gk||(gk={}));function wu(e,t){return Rt(new Error,{type:e,[hO]:!0},t)}function wi(e,t){return e instanceof Error&&hO in e&&(t==null||!!(e.type&t))}const vk="[^/]+?",lK={sensitive:!1,strict:!1,start:!0,end:!0},uK=/[.+*?^${}()[\]/\\]/g;function cK(e,t){const n=Rt({},lK,t),r=[];let s=n.start?"^":"";const i=[];for(const u of e){const d=u.length?[]:[90];n.strict&&!u.length&&(s+="/");for(let c=0;c<u.length;c++){const f=u[c];let p=40+(n.sensitive?.25:0);if(f.type===0)c||(s+="/"),s+=f.value.replace(uK,"\\$&"),p+=40;else if(f.type===1){const{value:g,repeatable:m,optional:y,regexp:b}=f;i.push({name:g,repeatable:m,optional:y});const w=b||vk;if(w!==vk){p+=10;try{new RegExp(`(${w})`)}catch(P){throw new Error(`Invalid custom RegExp for param "${g}" (${w}): `+P.message)}}let S=m?`((?:${w})(?:/(?:${w}))*)`:`(${w})`;c||(S=y&&u.length<2?`(?:/${S})`:"/"+S),y&&(S+="?"),s+=S,p+=20,y&&(p+=-8),m&&(p+=-20),w===".*"&&(p+=-50)}d.push(p)}r.push(d)}if(n.strict&&n.end){const u=r.length-1;r[u][r[u].length-1]+=.7000000000000001}n.strict||(s+="/?"),n.end?s+="$":n.strict&&(s+="(?:/|$)");const o=new RegExp(s,n.sensitive?"":"i");function a(u){const d=u.match(o),c={};if(!d)return null;for(let f=1;f<d.length;f++){const p=d[f]||"",g=i[f-1];c[g.name]=p&&g.repeatable?p.split("/"):p}return c}function l(u){let d="",c=!1;for(const f of e){(!c||!d.endsWith("/"))&&(d+="/"),c=!1;for(const p of f)if(p.type===0)d+=p.value;else if(p.type===1){const{value:g,repeatable:m,optional:y}=p,b=g in u?u[g]:"";if(Os(b)&&!m)throw new Error(`Provided param "${g}" is an array but it is not repeatable (* or + modifiers)`);const w=Os(b)?b.join("/"):b;if(!w)if(y)f.length<2&&(d.endsWith("/")?d=d.slice(0,-1):c=!0);else throw new Error(`Missing required param "${g}"`);d+=w}}return d||"/"}return{re:o,score:r,keys:i,parse:a,stringify:l}}function dK(e,t){let n=0;for(;n<e.length&&n<t.length;){const r=t[n]-e[n];if(r)return r;n++}return e.length<t.length?e.length===1&&e[0]===80?-1:1:e.length>t.length?t.length===1&&t[0]===80?1:-1:0}function pO(e,t){let n=0;const r=e.score,s=t.score;for(;n<r.length&&n<s.length;){const i=dK(r[n],s[n]);if(i)return i;n++}if(Math.abs(s.length-r.length)===1){if(yk(r))return 1;if(yk(s))return-1}return s.length-r.length}function yk(e){const t=e[e.length-1];return e.length>0&&t[t.length-1]<0}const fK={type:0,value:""},hK=/[a-zA-Z0-9_]/;function pK(e){if(!e)return[[]];if(e==="/")return[[fK]];if(!e.startsWith("/"))throw new Error(`Invalid path "${e}"`);function t(p){throw new Error(`ERR (${n})/"${u}": ${p}`)}let n=0,r=n;const s=[];let i;function o(){i&&s.push(i),i=[]}let a=0,l,u="",d="";function c(){u&&(n===0?i.push({type:0,value:u}):n===1||n===2||n===3?(i.length>1&&(l==="*"||l==="+")&&t(`A repeatable param (${u}) must be alone in its segment. eg: '/:ids+.`),i.push({type:1,value:u,regexp:d,repeatable:l==="*"||l==="+",optional:l==="*"||l==="?"})):t("Invalid state to consume buffer"),u="")}function f(){u+=l}for(;a<e.length;){if(l=e[a++],l==="\\"&&n!==2){r=n,n=4;continue}switch(n){case 0:l==="/"?(u&&c(),o()):l===":"?(c(),n=1):f();break;case 4:f(),n=r;break;case 1:l==="("?n=2:hK.test(l)?f():(c(),n=0,l!=="*"&&l!=="?"&&l!=="+"&&a--);break;case 2:l===")"?d[d.length-1]=="\\"?d=d.slice(0,-1)+l:n=3:d+=l;break;case 3:c(),n=0,l!=="*"&&l!=="?"&&l!=="+"&&a--,d="";break;default:t("Unknown state");break}}return n===2&&t(`Unfinished custom RegExp for param "${u}"`),c(),o(),s}function mK(e,t,n){const r=cK(pK(e.path),n),s=Rt(r,{record:e,parent:t,children:[],alias:[]});return t&&!s.record.aliasOf==!t.record.aliasOf&&t.children.push(s),s}function gK(e,t){const n=[],r=new Map;t=_k({strict:!1,end:!0,sensitive:!1},t);function s(c){return r.get(c)}function i(c,f,p){const g=!p,m=wk(c);m.aliasOf=p&&p.record;const y=_k(t,c),b=[m];if("alias"in c){const P=typeof c.alias=="string"?[c.alias]:c.alias;for(const E of P)b.push(wk(Rt({},m,{components:p?p.record.components:m.components,path:E,aliasOf:p?p.record:m})))}let w,S;for(const P of b){const{path:E}=P;if(f&&E[0]!=="/"){const T=f.record.path,C=T[T.length-1]==="/"?"":"/";P.path=f.record.path+(E&&C+E)}if(w=mK(P,f,y),p?p.alias.push(w):(S=S||w,S!==w&&S.alias.push(w),g&&c.name&&!Sk(w)&&o(c.name)),mO(w)&&l(w),m.children){const T=m.children;for(let C=0;C<T.length;C++)i(T[C],w,p&&p.children[C])}p=p||w}return S?()=>{o(S)}:Ic}function o(c){if(fO(c)){const f=r.get(c);f&&(r.delete(c),n.splice(n.indexOf(f),1),f.children.forEach(o),f.alias.forEach(o))}else{const f=n.indexOf(c);f>-1&&(n.splice(f,1),c.record.name&&r.delete(c.record.name),c.children.forEach(o),c.alias.forEach(o))}}function a(){return n}function l(c){const f=bK(c,n);n.splice(f,0,c),c.record.name&&!Sk(c)&&r.set(c.record.name,c)}function u(c,f){let p,g={},m,y;if("name"in c&&c.name){if(p=r.get(c.name),!p)throw wu(1,{location:c});y=p.record.name,g=Rt(bk(f.params,p.keys.filter(S=>!S.optional).concat(p.parent?p.parent.keys.filter(S=>S.optional):[]).map(S=>S.name)),c.params&&bk(c.params,p.keys.map(S=>S.name))),m=p.stringify(g)}else if(c.path!=null)m=c.path,p=n.find(S=>S.re.test(m)),p&&(g=p.parse(m),y=p.record.name);else{if(p=f.name?r.get(f.name):n.find(S=>S.re.test(f.path)),!p)throw wu(1,{location:c,currentLocation:f});y=p.record.name,g=Rt({},f.params,c.params),m=p.stringify(g)}const b=[];let w=p;for(;w;)b.unshift(w.record),w=w.parent;return{name:y,path:m,params:g,matched:b,meta:yK(b)}}e.forEach(c=>i(c));function d(){n.length=0,r.clear()}return{addRoute:i,resolve:u,removeRoute:o,clearRoutes:d,getRoutes:a,getRecordMatcher:s}}function bk(e,t){const n={};for(const r of t)r in e&&(n[r]=e[r]);return n}function wk(e){const t={path:e.path,redirect:e.redirect,name:e.name,meta:e.meta||{},aliasOf:e.aliasOf,beforeEnter:e.beforeEnter,props:vK(e),children:e.children||[],instances:{},leaveGuards:new Set,updateGuards:new Set,enterCallbacks:{},components:"components"in e?e.components||null:e.component&&{default:e.component}};return Object.defineProperty(t,"mods",{value:{}}),t}function vK(e){const t={},n=e.props||!1;if("component"in e)t.default=n;else for(const r in e.components)t[r]=typeof n=="object"?n[r]:n;return t}function Sk(e){for(;e;){if(e.record.aliasOf)return!0;e=e.parent}return!1}function yK(e){return e.reduce((t,n)=>Rt(t,n.meta),{})}function _k(e,t){const n={};for(const r in e)n[r]=r in t?t[r]:e[r];return n}function bK(e,t){let n=0,r=t.length;for(;n!==r;){const i=n+r>>1;pO(e,t[i])<0?r=i:n=i+1}const s=wK(e);return s&&(r=t.lastIndexOf(s,r-1)),r}function wK(e){let t=e;for(;t=t.parent;)if(mO(t)&&pO(e,t)===0)return t}function mO({record:e}){return!!(e.name||e.components&&Object.keys(e.components).length||e.redirect)}function SK(e){const t={};if(e===""||e==="?")return t;const r=(e[0]==="?"?e.slice(1):e).split("&");for(let s=0;s<r.length;++s){const i=r[s].replace(oO," "),o=i.indexOf("="),a=ld(o<0?i:i.slice(0,o)),l=o<0?null:ld(i.slice(o+1));if(a in t){let u=t[a];Os(u)||(u=t[a]=[u]),u.push(l)}else t[a]=l}return t}function kk(e){let t="";for(let n in e){const r=e[n];if(n=U7(n),r==null){r!==void 0&&(t+=(t.length?"&":"")+n);continue}(Os(r)?r.map(i=>i&&Fy(i)):[r&&Fy(r)]).forEach(i=>{i!==void 0&&(t+=(t.length?"&":"")+n,i!=null&&(t+="="+i))})}return t}function _K(e){const t={};for(const n in e){const r=e[n];r!==void 0&&(t[n]=Os(r)?r.map(s=>s==null?null:""+s):r==null?r:""+r)}return t}const kK=Symbol(""),xk=Symbol(""),wm=Symbol(""),zw=Symbol(""),By=Symbol("");function ec(){let e=[];function t(r){return e.push(r),()=>{const s=e.indexOf(r);s>-1&&e.splice(s,1)}}function n(){e=[]}return{add:t,list:()=>e.slice(),reset:n}}function ho(e,t,n,r,s,i=o=>o()){const o=r&&(r.enterCallbacks[s]=r.enterCallbacks[s]||[]);return()=>new Promise((a,l)=>{const u=f=>{f===!1?l(wu(4,{from:n,to:t})):f instanceof Error?l(f):aK(f)?l(wu(2,{from:t,to:f})):(o&&r.enterCallbacks[s]===o&&typeof f=="function"&&o.push(f),a())},d=i(()=>e.call(r&&r.instances[s],t,n,u));let c=Promise.resolve(d);e.length<3&&(c=c.then(u)),c.catch(f=>l(f))})}function Tg(e,t,n,r,s=i=>i()){const i=[];for(const o of e)for(const a in o.components){let l=o.components[a];if(!(t!=="beforeRouteEnter"&&!o.instances[a]))if(sO(l)){const d=(l.__vccOpts||l)[t];d&&i.push(ho(d,n,r,o,a,s))}else{let u=l();i.push(()=>u.then(d=>{if(!d)throw new Error(`Couldn't resolve component "${a}" at "${o.path}"`);const c=I7(d)?d.default:d;o.mods[a]=d,o.components[a]=c;const p=(c.__vccOpts||c)[t];return p&&ho(p,n,r,o,a,s)()}))}}return i}function Ek(e){const t=Ye(wm),n=Ye(zw),r=R(()=>{const l=ie(e.to);return t.resolve(l)}),s=R(()=>{const{matched:l}=r.value,{length:u}=l,d=l[u-1],c=n.matched;if(!d||!c.length)return-1;const f=c.findIndex(bu.bind(null,d));if(f>-1)return f;const p=Ck(l[u-2]);return u>1&&Ck(d)===p&&c[c.length-1].path!==p?c.findIndex(bu.bind(null,l[u-2])):f}),i=R(()=>s.value>-1&&PK(n.params,r.value.params)),o=R(()=>s.value>-1&&s.value===n.matched.length-1&&cO(n.params,r.value.params));function a(l={}){return CK(l)?t[ie(e.replace)?"replace":"push"](ie(e.to)).catch(Ic):Promise.resolve()}return{route:r,href:R(()=>r.value.href),isActive:i,isExactActive:o,navigate:a}}const xK=Le({name:"RouterLink",compatConfig:{MODE:3},props:{to:{type:[String,Object],required:!0},replace:Boolean,activeClass:String,exactActiveClass:String,custom:Boolean,ariaCurrentValue:{type:String,default:"page"}},useLink:Ek,setup(e,{slots:t}){const n=vn(Ek(e)),{options:r}=Ye(wm),s=R(()=>({[Pk(e.activeClass,r.linkActiveClass,"router-link-active")]:n.isActive,[Pk(e.exactActiveClass,r.linkExactActiveClass,"router-link-exact-active")]:n.isExactActive}));return()=>{const i=t.default&&t.default(n);return e.custom?i:Mr("a",{"aria-current":n.isExactActive?e.ariaCurrentValue:null,href:n.href,onClick:n.navigate,class:s.value},i)}}}),EK=xK;function CK(e){if(!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)&&!e.defaultPrevented&&!(e.button!==void 0&&e.button!==0)){if(e.currentTarget&&e.currentTarget.getAttribute){const t=e.currentTarget.getAttribute("target");if(/\b_blank\b/i.test(t))return}return e.preventDefault&&e.preventDefault(),!0}}function PK(e,t){for(const n in t){const r=t[n],s=e[n];if(typeof r=="string"){if(r!==s)return!1}else if(!Os(s)||s.length!==r.length||r.some((i,o)=>i!==s[o]))return!1}return!0}function Ck(e){return e?e.aliasOf?e.aliasOf.path:e.path:""}const Pk=(e,t,n)=>e??t??n,TK=Le({name:"RouterView",inheritAttrs:!1,props:{name:{type:String,default:"default"},route:Object},compatConfig:{MODE:3},setup(e,{attrs:t,slots:n}){const r=Ye(By),s=R(()=>e.route||r.value),i=Ye(xk,0),o=R(()=>{let u=ie(i);const{matched:d}=s.value;let c;for(;(c=d[u])&&!c.components;)u++;return u}),a=R(()=>s.value.matched[o.value]);Gt(xk,R(()=>o.value+1)),Gt(kK,a),Gt(By,s);const l=U();return Ce(()=>[l.value,a.value,e.name],([u,d,c],[f,p,g])=>{d&&(d.instances[c]=u,p&&p!==d&&u&&u===f&&(d.leaveGuards.size||(d.leaveGuards=p.leaveGuards),d.updateGuards.size||(d.updateGuards=p.updateGuards))),u&&d&&(!p||!bu(d,p)||!f)&&(d.enterCallbacks[c]||[]).forEach(m=>m(u))},{flush:"post"}),()=>{const u=s.value,d=e.name,c=a.value,f=c&&c.components[d];if(!f)return Tk(n.default,{Component:f,route:u});const p=c.props[d],g=p?p===!0?u.params:typeof p=="function"?p(u):p:null,y=Mr(f,Rt({},g,t,{onVnodeUnmounted:b=>{b.component.isUnmounted&&(c.instances[d]=null)},ref:l}));return Tk(n.default,{Component:y,route:u})||y}}});function Tk(e,t){if(!e)return null;const n=e(t);return n.length===1?n[0]:n}const RK=TK;function IK(e){const t=gK(e.routes,e),n=e.parseQuery||SK,r=e.stringifyQuery||kk,s=e.history,i=ec(),o=ec(),a=ec(),l=Me(Zi);let u=Zi;El&&e.scrollBehavior&&"scrollRestoration"in history&&(history.scrollRestoration="manual");const d=Cg.bind(null,J=>""+J),c=Cg.bind(null,z7),f=Cg.bind(null,ld);function p(J,be){let Se,te;return fO(J)?(Se=t.getRecordMatcher(J),te=be):te=J,t.addRoute(te,Se)}function g(J){const be=t.getRecordMatcher(J);be&&t.removeRoute(be)}function m(){return t.getRoutes().map(J=>J.record)}function y(J){return!!t.getRecordMatcher(J)}function b(J,be){if(be=Rt({},be||l.value),typeof J=="string"){const N=Pg(n,J,be.path),ee=t.resolve({path:N.path},be),se=s.createHref(N.fullPath);return Rt(N,ee,{params:f(ee.params),hash:ld(N.hash),redirectedFrom:void 0,href:se})}let Se;if(J.path!=null)Se=Rt({},J,{path:Pg(n,J.path,be.path).path});else{const N=Rt({},J.params);for(const ee in N)N[ee]==null&&delete N[ee];Se=Rt({},J,{params:c(N)}),be.params=c(be.params)}const te=t.resolve(Se,be),Y=J.hash||"";te.params=d(f(te.params));const ze=W7(r,Rt({},J,{hash:V7(Y),path:te.path})),F=s.createHref(ze);return Rt({fullPath:ze,hash:Y,query:r===kk?_K(J.query):J.query||{}},te,{redirectedFrom:void 0,href:F})}function w(J){return typeof J=="string"?Pg(n,J,l.value.path):Rt({},J)}function S(J,be){if(u!==J)return wu(8,{from:be,to:J})}function P(J){return C(J)}function E(J){return P(Rt(w(J),{replace:!0}))}function T(J){const be=J.matched[J.matched.length-1];if(be&&be.redirect){const{redirect:Se}=be;let te=typeof Se=="function"?Se(J):Se;return typeof te=="string"&&(te=te.includes("?")||te.includes("#")?te=w(te):{path:te},te.params={}),Rt({query:J.query,hash:J.hash,params:te.path!=null?{}:J.params},te)}}function C(J,be){const Se=u=b(J),te=l.value,Y=J.state,ze=J.force,F=J.replace===!0,N=T(Se);if(N)return C(Rt(w(N),{state:typeof N=="object"?Rt({},Y,N.state):Y,force:ze,replace:F}),be||Se);const ee=Se;ee.redirectedFrom=be;let se;return!ze&&G7(r,te,Se)&&(se=wu(16,{to:ee,from:te}),Z(te,te,!0,!1)),(se?Promise.resolve(se):I(ee,te)).catch(oe=>wi(oe)?wi(oe,2)?oe:W(oe):j(oe,ee,te)).then(oe=>{if(oe){if(wi(oe,2))return C(Rt({replace:F},w(oe.to),{state:typeof oe.to=="object"?Rt({},Y,oe.to.state):Y,force:ze}),be||ee)}else oe=O(ee,te,!0,F,Y);return M(ee,te,oe),oe})}function k(J,be){const Se=S(J,be);return Se?Promise.reject(Se):Promise.resolve()}function x(J){const be=pe.values().next().value;return be&&typeof be.runWithContext=="function"?be.runWithContext(J):J()}function I(J,be){let Se;const[te,Y,ze]=AK(J,be);Se=Tg(te.reverse(),"beforeRouteLeave",J,be);for(const N of te)N.leaveGuards.forEach(ee=>{Se.push(ho(ee,J,be))});const F=k.bind(null,J,be);return Se.push(F),le(Se).then(()=>{Se=[];for(const N of i.list())Se.push(ho(N,J,be));return Se.push(F),le(Se)}).then(()=>{Se=Tg(Y,"beforeRouteUpdate",J,be);for(const N of Y)N.updateGuards.forEach(ee=>{Se.push(ho(ee,J,be))});return Se.push(F),le(Se)}).then(()=>{Se=[];for(const N of ze)if(N.beforeEnter)if(Os(N.beforeEnter))for(const ee of N.beforeEnter)Se.push(ho(ee,J,be));else Se.push(ho(N.beforeEnter,J,be));return Se.push(F),le(Se)}).then(()=>(J.matched.forEach(N=>N.enterCallbacks={}),Se=Tg(ze,"beforeRouteEnter",J,be,x),Se.push(F),le(Se))).then(()=>{Se=[];for(const N of o.list())Se.push(ho(N,J,be));return Se.push(F),le(Se)}).catch(N=>wi(N,8)?N:Promise.reject(N))}function M(J,be,Se){a.list().forEach(te=>x(()=>te(J,be,Se)))}function O(J,be,Se,te,Y){const ze=S(J,be);if(ze)return ze;const F=be===Zi,N=El?history.state:{};Se&&(te||F?s.replace(J.fullPath,Rt({scroll:F&&N&&N.scroll},Y)):s.push(J.fullPath,Y)),l.value=J,Z(J,be,Se,F),W()}let A;function D(){A||(A=s.listen((J,be,Se)=>{if(!ue.listening)return;const te=b(J),Y=T(te);if(Y){C(Rt(Y,{replace:!0}),te).catch(Ic);return}u=te;const ze=l.value;El&&tK(pk(ze.fullPath,Se.delta),bm()),I(te,ze).catch(F=>wi(F,12)?F:wi(F,2)?(C(F.to,te).then(N=>{wi(N,20)&&!Se.delta&&Se.type===ud.pop&&s.go(-1,!1)}).catch(Ic),Promise.reject()):(Se.delta&&s.go(-Se.delta,!1),j(F,te,ze))).then(F=>{F=F||O(te,ze,!1),F&&(Se.delta&&!wi(F,8)?s.go(-Se.delta,!1):Se.type===ud.pop&&wi(F,20)&&s.go(-1,!1)),M(te,ze,F)}).catch(Ic)}))}let V=ec(),H=ec(),G;function j(J,be,Se){W(J);const te=H.list();return te.length?te.forEach(Y=>Y(J,be,Se)):console.error(J),Promise.reject(J)}function B(){return G&&l.value!==Zi?Promise.resolve():new Promise((J,be)=>{V.add([J,be])})}function W(J){return G||(G=!J,D(),V.list().forEach(([be,Se])=>J?Se(J):be()),V.reset()),J}function Z(J,be,Se,te){const{scrollBehavior:Y}=e;if(!El||!Y)return Promise.resolve();const ze=!Se&&nK(pk(J.fullPath,0))||(te||!Se)&&history.state&&history.state.scroll||null;return Ot().then(()=>Y(J,be,ze)).then(F=>F&&eK(F)).catch(F=>j(F,J,be))}const q=J=>s.go(J);let K;const pe=new Set,ue={currentRoute:l,listening:!0,addRoute:p,removeRoute:g,clearRoutes:t.clearRoutes,hasRoute:y,getRoutes:m,resolve:b,options:e,push:P,replace:E,go:q,back:()=>q(-1),forward:()=>q(1),beforeEach:i.add,beforeResolve:o.add,afterEach:a.add,onError:H.add,isReady:B,install(J){const be=this;J.component("RouterLink",EK),J.component("RouterView",RK),J.config.globalProperties.$router=be,Object.defineProperty(J.config.globalProperties,"$route",{enumerable:!0,get:()=>ie(l)}),El&&!K&&l.value===Zi&&(K=!0,P(s.location).catch(Y=>{}));const Se={};for(const Y in Zi)Object.defineProperty(Se,Y,{get:()=>l.value[Y],enumerable:!0});J.provide(wm,be),J.provide(zw,Cp(Se)),J.provide(By,l);const te=J.unmount;pe.add(J),J.unmount=function(){pe.delete(J),pe.size<1&&(u=Zi,A&&A(),A=null,l.value=Zi,K=!1,G=!1),te()}}};function le(J){return J.reduce((be,Se)=>be.then(()=>x(Se)),Promise.resolve())}return ue}function AK(e,t){const n=[],r=[],s=[],i=Math.max(t.matched.length,e.matched.length);for(let o=0;o<i;o++){const a=t.matched[o];a&&(e.matched.find(u=>bu(u,a))?r.push(a):n.push(a));const l=e.matched[o];l&&(t.matched.find(u=>bu(u,l))||s.push(l))}return[n,r,s]}function Zo(){return Ye(wm)}function gO(e){return Ye(zw)}const OK={class:"text-center"},MK={class:"float-end"},DK=Le({__name:"PrintJobsMenu",setup(e){const t=rr(),n=U(""),r=U(!1),s=R(()=>t.printersWithJob.filter(a=>{var p,g,m,y;const l=(g=(p=a.job)==null?void 0:p.job)==null?void 0:g.file.name,u=(l==null?void 0:l.toLowerCase())||"",d=((m=a.printer.printerURL)==null?void 0:m.toLowerCase())||"",c=((y=a.printer.name)==null?void 0:y.toLowerCase())||"",f=`${u} ${d} ${c}`;return!n.value||f.includes(n.value.toLowerCase())})),i=R(()=>s.value.length||0);function o(a){return a?a==null?void 0:a.toFixed(0):""}return Ce(r,()=>{n.value=""}),(a,l)=>($(),we("div",OK,[h(Wd,{modelValue:ie(r),"onUpdate:modelValue":l[3]||(l[3]=u=>tt(r)?r.value=u:null),"close-on-content-click":!1,"nudge-width":400,location:"bottom right","offset-x":"","offset-y":"",transition:"slide-x-transition"},{activator:v(({props:u})=>[h(re,me({color:ie(i)?"green":"secondary",dark:""},u),{default:v(()=>[L("span",null," Print jobs "+ae(ie(i)?`(${ie(i)})`:""),1),h(X,{end:""},{default:v(()=>l[4]||(l[4]=[_(" work ")])),_:1})]),_:2},1040,["color"])]),default:v(()=>[h(yt,{class:"d-flex flex-column","min-width":"300"},{default:v(()=>[h(Kt,{style:{"overflow-y":"hidden","flex-shrink":"0"}},{default:v(()=>[h(Fe,null,{prepend:v(()=>[h(lt,{class:"font-weight-bold",color:"primary",size:"44"},{default:v(()=>[_(ae(ie(i)),1)]),_:1})]),default:v(()=>[h(ht,null,{default:v(()=>[l[7]||(l[7]=_(" Print Jobs ")),L("span",MK,[h(re,{variant:"tonal",onClick:l[0]||(l[0]=u=>r.value=!1)},{default:v(()=>[h(X,null,{default:v(()=>l[5]||(l[5]=[_("close")])),_:1}),l[6]||(l[6]=_("Close "))]),_:1})])]),_:1}),h(sd,{class:"mt-2"},{default:v(()=>[h(ct,{modelValue:ie(n),"onUpdate:modelValue":l[1]||(l[1]=u=>tt(n)?n.value=u:null),autofocus:"",class:"p-2",clearable:"",label:"Search jobs or printers","persistent-placeholder":"",placeholder:"Type part of a filename or printer name to search","prepend-icon":"search",style:{"min-width":"900px"}},null,8,["modelValue"])]),_:1})]),_:1})]),_:1}),h(yn),h(Kt,{style:{"overflow-y":"auto","flex-shrink":"1"}},{default:v(()=>[ie(i)?ve("",!0):($(),Q(Fe,{key:0},{default:v(()=>l[8]||(l[8]=[_(" No active prints ")])),_:1})),($(!0),we(Re,null,Zt(ie(s),({printer:u,job:d})=>($(),Q(Fe,{key:u.id,lines:"two"},{prepend:v(()=>[h(lt,{size:"70"},{default:v(()=>{var c;return[h(Id,{"model-value":(c=d==null?void 0:d.progress)==null?void 0:c.completion,width:5,color:"green",size:"50"},{default:v(()=>{var f;return[_(ae(o((f=d.progress)==null?void 0:f.completion)+"%"||""),1)]}),_:2},1032,["model-value"])]}),_:2},1024)]),default:v(()=>[h(ht,null,{default:v(()=>{var c,f;return[_(ae((f=(c=d.job)==null?void 0:c.file)==null?void 0:f.name),1)]}),_:2},1024),h(wt,null,{default:v(()=>[_(" Elapsed: "+ae(Math.round((d==null?void 0:d.progress.printTime)??0/60))+" minutes ",1),l[9]||(l[9]=L("br",null,null,-1)),_(" Printer: "+ae(u.name),1)]),_:2},1024)]),_:2},1024))),128))]),_:1}),h(Nn,null,{default:v(()=>[h(wn),h(re,{onClick:l[2]||(l[2]=u=>r.value=!1)},{default:v(()=>l[10]||(l[10]=[_(" Close ")])),_:1})]),_:1})]),_:1})]),_:1},8,["modelValue"])]))}}),jw=Ms("profile",{state:()=>({username:null,isDemoUser:null,userId:null}),actions:{async getProfile(){return await os.getProfile().then(e=>{this.username=e.username,this.userId=e.id,this.isDemoUser=e.isDemoUser})}}}),qt={Home:"Home",Login:"Login",Registration:"Registration",PrintersView:"PrintersView",Settings:"Settings",CameraGridView:"CameraGridView",PrintStatistics:"Print Statistics",About:"About",PermissionDenied:"PermissionDenied",NotFound:"NotFound",FirstTimeSetup:"FirstTimeSetup",ServerProtection:"ServerProtection"};async function LK(e,t){return e.push({name:t})}async function vO(e){if(e.currentRoute.value.path==="/login"){console.log("routeToLogin: already at login page");return}return LK(e,qt.Login)}const Rk=!0,$K=()=>Object.freeze({apiKeyLength:43,maxPort:65535,maxPrinterNameLength:25,maxPrinterGroupNameLength:30,maxPrinterGroupLocationX:4,maxPrinterGroupLocationY:4,minPrinterFloorNameLength:3,minUsernameLength:3}),fi=Object.create(null);fi.open="0";fi.close="1";fi.ping="2";fi.pong="3";fi.message="4";fi.upgrade="5";fi.noop="6";const uh=Object.create(null);Object.keys(fi).forEach(e=>{uh[fi[e]]=e});const Vy={type:"error",data:"parser error"},yO=typeof Blob=="function"||typeof Blob<"u"&&Object.prototype.toString.call(Blob)==="[object BlobConstructor]",bO=typeof ArrayBuffer=="function",wO=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e&&e.buffer instanceof ArrayBuffer,qw=({type:e,data:t},n,r)=>yO&&t instanceof Blob?n?r(t):Ik(t,r):bO&&(t instanceof ArrayBuffer||wO(t))?n?r(t):Ik(new Blob([t]),r):r(fi[e]+(t||"")),Ik=(e,t)=>{const n=new FileReader;return n.onload=function(){const r=n.result.split(",")[1];t("b"+(r||""))},n.readAsDataURL(e)};function Ak(e){return e instanceof Uint8Array?e:e instanceof ArrayBuffer?new Uint8Array(e):new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}let Rg;function FK(e,t){if(yO&&e.data instanceof Blob)return e.data.arrayBuffer().then(Ak).then(t);if(bO&&(e.data instanceof ArrayBuffer||wO(e.data)))return t(Ak(e.data));qw(e,!1,n=>{Rg||(Rg=new TextEncoder),t(Rg.encode(n))})}const Ok="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",fc=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(let e=0;e<Ok.length;e++)fc[Ok.charCodeAt(e)]=e;const NK=e=>{let t=e.length*.75,n=e.length,r,s=0,i,o,a,l;e[e.length-1]==="="&&(t--,e[e.length-2]==="="&&t--);const u=new ArrayBuffer(t),d=new Uint8Array(u);for(r=0;r<n;r+=4)i=fc[e.charCodeAt(r)],o=fc[e.charCodeAt(r+1)],a=fc[e.charCodeAt(r+2)],l=fc[e.charCodeAt(r+3)],d[s++]=i<<2|o>>4,d[s++]=(o&15)<<4|a>>2,d[s++]=(a&3)<<6|l&63;return u},BK=typeof ArrayBuffer=="function",Ww=(e,t)=>{if(typeof e!="string")return{type:"message",data:SO(e,t)};const n=e.charAt(0);return n==="b"?{type:"message",data:VK(e.substring(1),t)}:uh[n]?e.length>1?{type:uh[n],data:e.substring(1)}:{type:uh[n]}:Vy},VK=(e,t)=>{if(BK){const n=NK(e);return SO(n,t)}else return{base64:!0,data:e}},SO=(e,t)=>{switch(t){case"blob":return e instanceof Blob?e:new Blob([e]);case"arraybuffer":default:return e instanceof ArrayBuffer?e:e.buffer}},_O="",UK=(e,t)=>{const n=e.length,r=new Array(n);let s=0;e.forEach((i,o)=>{qw(i,!1,a=>{r[o]=a,++s===n&&t(r.join(_O))})})},HK=(e,t)=>{const n=e.split(_O),r=[];for(let s=0;s<n.length;s++){const i=Ww(n[s],t);if(r.push(i),i.type==="error")break}return r};function zK(){return new TransformStream({transform(e,t){FK(e,n=>{const r=n.length;let s;if(r<126)s=new Uint8Array(1),new DataView(s.buffer).setUint8(0,r);else if(r<65536){s=new Uint8Array(3);const i=new DataView(s.buffer);i.setUint8(0,126),i.setUint16(1,r)}else{s=new Uint8Array(9);const i=new DataView(s.buffer);i.setUint8(0,127),i.setBigUint64(1,BigInt(r))}e.data&&typeof e.data!="string"&&(s[0]|=128),t.enqueue(s),t.enqueue(n)})}})}let Ig;function xf(e){return e.reduce((t,n)=>t+n.length,0)}function Ef(e,t){if(e[0].length===t)return e.shift();const n=new Uint8Array(t);let r=0;for(let s=0;s<t;s++)n[s]=e[0][r++],r===e[0].length&&(e.shift(),r=0);return e.length&&r<e[0].length&&(e[0]=e[0].slice(r)),n}function jK(e,t){Ig||(Ig=new TextDecoder);const n=[];let r=0,s=-1,i=!1;return new TransformStream({transform(o,a){for(n.push(o);;){if(r===0){if(xf(n)<1)break;const l=Ef(n,1);i=(l[0]&128)===128,s=l[0]&127,s<126?r=3:s===126?r=1:r=2}else if(r===1){if(xf(n)<2)break;const l=Ef(n,2);s=new DataView(l.buffer,l.byteOffset,l.length).getUint16(0),r=3}else if(r===2){if(xf(n)<8)break;const l=Ef(n,8),u=new DataView(l.buffer,l.byteOffset,l.length),d=u.getUint32(0);if(d>Math.pow(2,21)-1){a.enqueue(Vy);break}s=d*Math.pow(2,32)+u.getUint32(4),r=3}else{if(xf(n)<s)break;const l=Ef(n,s);a.enqueue(Ww(i?l:Ig.decode(l),t)),r=0}if(s===0||s>e){a.enqueue(Vy);break}}}})}const kO=4;function bn(e){if(e)return qK(e)}function qK(e){for(var t in bn.prototype)e[t]=bn.prototype[t];return e}bn.prototype.on=bn.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this};bn.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this};bn.prototype.off=bn.prototype.removeListener=bn.prototype.removeAllListeners=bn.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},arguments.length==0)return this._callbacks={},this;var n=this._callbacks["$"+e];if(!n)return this;if(arguments.length==1)return delete this._callbacks["$"+e],this;for(var r,s=0;s<n.length;s++)if(r=n[s],r===t||r.fn===t){n.splice(s,1);break}return n.length===0&&delete this._callbacks["$"+e],this};bn.prototype.emit=function(e){this._callbacks=this._callbacks||{};for(var t=new Array(arguments.length-1),n=this._callbacks["$"+e],r=1;r<arguments.length;r++)t[r-1]=arguments[r];if(n){n=n.slice(0);for(var r=0,s=n.length;r<s;++r)n[r].apply(this,t)}return this};bn.prototype.emitReserved=bn.prototype.emit;bn.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]};bn.prototype.hasListeners=function(e){return!!this.listeners(e).length};const Sm=typeof Promise=="function"&&typeof Promise.resolve=="function"?t=>Promise.resolve().then(t):(t,n)=>n(t,0),us=typeof self<"u"?self:typeof window<"u"?window:Function("return this")(),WK="arraybuffer";function xO(e,...t){return t.reduce((n,r)=>(e.hasOwnProperty(r)&&(n[r]=e[r]),n),{})}const GK=us.setTimeout,KK=us.clearTimeout;function _m(e,t){t.useNativeTimers?(e.setTimeoutFn=GK.bind(us),e.clearTimeoutFn=KK.bind(us)):(e.setTimeoutFn=us.setTimeout.bind(us),e.clearTimeoutFn=us.clearTimeout.bind(us))}const YK=1.33;function XK(e){return typeof e=="string"?QK(e):Math.ceil((e.byteLength||e.size)*YK)}function QK(e){let t=0,n=0;for(let r=0,s=e.length;r<s;r++)t=e.charCodeAt(r),t<128?n+=1:t<2048?n+=2:t<55296||t>=57344?n+=3:(r++,n+=4);return n}function EO(){return Date.now().toString(36).substring(3)+Math.random().toString(36).substring(2,5)}function JK(e){let t="";for(let n in e)e.hasOwnProperty(n)&&(t.length&&(t+="&"),t+=encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return t}function ZK(e){let t={},n=e.split("&");for(let r=0,s=n.length;r<s;r++){let i=n[r].split("=");t[decodeURIComponent(i[0])]=decodeURIComponent(i[1])}return t}class e9 extends Error{constructor(t,n,r){super(t),this.description=n,this.context=r,this.type="TransportError"}}class Gw extends bn{constructor(t){super(),this.writable=!1,_m(this,t),this.opts=t,this.query=t.query,this.socket=t.socket,this.supportsBinary=!t.forceBase64}onError(t,n,r){return super.emitReserved("error",new e9(t,n,r)),this}open(){return this.readyState="opening",this.doOpen(),this}close(){return(this.readyState==="opening"||this.readyState==="open")&&(this.doClose(),this.onClose()),this}send(t){this.readyState==="open"&&this.write(t)}onOpen(){this.readyState="open",this.writable=!0,super.emitReserved("open")}onData(t){const n=Ww(t,this.socket.binaryType);this.onPacket(n)}onPacket(t){super.emitReserved("packet",t)}onClose(t){this.readyState="closed",super.emitReserved("close",t)}pause(t){}createUri(t,n={}){return t+"://"+this._hostname()+this._port()+this.opts.path+this._query(n)}_hostname(){const t=this.opts.hostname;return t.indexOf(":")===-1?t:"["+t+"]"}_port(){return this.opts.port&&(this.opts.secure&&+(this.opts.port!==443)||!this.opts.secure&&Number(this.opts.port)!==80)?":"+this.opts.port:""}_query(t){const n=JK(t);return n.length?"?"+n:""}}class t9 extends Gw{constructor(){super(...arguments),this._polling=!1}get name(){return"polling"}doOpen(){this._poll()}pause(t){this.readyState="pausing";const n=()=>{this.readyState="paused",t()};if(this._polling||!this.writable){let r=0;this._polling&&(r++,this.once("pollComplete",function(){--r||n()})),this.writable||(r++,this.once("drain",function(){--r||n()}))}else n()}_poll(){this._polling=!0,this.doPoll(),this.emitReserved("poll")}onData(t){const n=r=>{if(this.readyState==="opening"&&r.type==="open"&&this.onOpen(),r.type==="close")return this.onClose({description:"transport closed by the server"}),!1;this.onPacket(r)};HK(t,this.socket.binaryType).forEach(n),this.readyState!=="closed"&&(this._polling=!1,this.emitReserved("pollComplete"),this.readyState==="open"&&this._poll())}doClose(){const t=()=>{this.write([{type:"close"}])};this.readyState==="open"?t():this.once("open",t)}write(t){this.writable=!1,UK(t,n=>{this.doWrite(n,()=>{this.writable=!0,this.emitReserved("drain")})})}uri(){const t=this.opts.secure?"https":"http",n=this.query||{};return this.opts.timestampRequests!==!1&&(n[this.opts.timestampParam]=EO()),!this.supportsBinary&&!n.sid&&(n.b64=1),this.createUri(t,n)}}let CO=!1;try{CO=typeof XMLHttpRequest<"u"&&"withCredentials"in new XMLHttpRequest}catch{}const n9=CO;function r9(){}class s9 extends t9{constructor(t){if(super(t),typeof location<"u"){const n=location.protocol==="https:";let r=location.port;r||(r=n?"443":"80"),this.xd=typeof location<"u"&&t.hostname!==location.hostname||r!==t.port}}doWrite(t,n){const r=this.request({method:"POST",data:t});r.on("success",n),r.on("error",(s,i)=>{this.onError("xhr post error",s,i)})}doPoll(){const t=this.request();t.on("data",this.onData.bind(this)),t.on("error",(n,r)=>{this.onError("xhr poll error",n,r)}),this.pollXhr=t}}let zl=class ch extends bn{constructor(t,n,r){super(),this.createRequest=t,_m(this,r),this._opts=r,this._method=r.method||"GET",this._uri=n,this._data=r.data!==void 0?r.data:null,this._create()}_create(){var t;const n=xO(this._opts,"agent","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","autoUnref");n.xdomain=!!this._opts.xd;const r=this._xhr=this.createRequest(n);try{r.open(this._method,this._uri,!0);try{if(this._opts.extraHeaders){r.setDisableHeaderCheck&&r.setDisableHeaderCheck(!0);for(let s in this._opts.extraHeaders)this._opts.extraHeaders.hasOwnProperty(s)&&r.setRequestHeader(s,this._opts.extraHeaders[s])}}catch{}if(this._method==="POST")try{r.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch{}try{r.setRequestHeader("Accept","*/*")}catch{}(t=this._opts.cookieJar)===null||t===void 0||t.addCookies(r),"withCredentials"in r&&(r.withCredentials=this._opts.withCredentials),this._opts.requestTimeout&&(r.timeout=this._opts.requestTimeout),r.onreadystatechange=()=>{var s;r.readyState===3&&((s=this._opts.cookieJar)===null||s===void 0||s.parseCookies(r.getResponseHeader("set-cookie"))),r.readyState===4&&(r.status===200||r.status===1223?this._onLoad():this.setTimeoutFn(()=>{this._onError(typeof r.status=="number"?r.status:0)},0))},r.send(this._data)}catch(s){this.setTimeoutFn(()=>{this._onError(s)},0);return}typeof document<"u"&&(this._index=ch.requestsCount++,ch.requests[this._index]=this)}_onError(t){this.emitReserved("error",t,this._xhr),this._cleanup(!0)}_cleanup(t){if(!(typeof this._xhr>"u"||this._xhr===null)){if(this._xhr.onreadystatechange=r9,t)try{this._xhr.abort()}catch{}typeof document<"u"&&delete ch.requests[this._index],this._xhr=null}}_onLoad(){const t=this._xhr.responseText;t!==null&&(this.emitReserved("data",t),this.emitReserved("success"),this._cleanup())}abort(){this._cleanup()}};zl.requestsCount=0;zl.requests={};if(typeof document<"u"){if(typeof attachEvent=="function")attachEvent("onunload",Mk);else if(typeof addEventListener=="function"){const e="onpagehide"in us?"pagehide":"unload";addEventListener(e,Mk,!1)}}function Mk(){for(let e in zl.requests)zl.requests.hasOwnProperty(e)&&zl.requests[e].abort()}const i9=function(){const e=PO({xdomain:!1});return e&&e.responseType!==null}();class o9 extends s9{constructor(t){super(t);const n=t&&t.forceBase64;this.supportsBinary=i9&&!n}request(t={}){return Object.assign(t,{xd:this.xd},this.opts),new zl(PO,this.uri(),t)}}function PO(e){const t=e.xdomain;try{if(typeof XMLHttpRequest<"u"&&(!t||n9))return new XMLHttpRequest}catch{}if(!t)try{return new us[["Active"].concat("Object").join("X")]("Microsoft.XMLHTTP")}catch{}}const TO=typeof navigator<"u"&&typeof navigator.product=="string"&&navigator.product.toLowerCase()==="reactnative";class a9 extends Gw{get name(){return"websocket"}doOpen(){const t=this.uri(),n=this.opts.protocols,r=TO?{}:xO(this.opts,"agent","perMessageDeflate","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","localAddress","protocolVersion","origin","maxPayload","family","checkServerIdentity");this.opts.extraHeaders&&(r.headers=this.opts.extraHeaders);try{this.ws=this.createSocket(t,n,r)}catch(s){return this.emitReserved("error",s)}this.ws.binaryType=this.socket.binaryType,this.addEventListeners()}addEventListeners(){this.ws.onopen=()=>{this.opts.autoUnref&&this.ws._socket.unref(),this.onOpen()},this.ws.onclose=t=>this.onClose({description:"websocket connection closed",context:t}),this.ws.onmessage=t=>this.onData(t.data),this.ws.onerror=t=>this.onError("websocket error",t)}write(t){this.writable=!1;for(let n=0;n<t.length;n++){const r=t[n],s=n===t.length-1;qw(r,this.supportsBinary,i=>{try{this.doWrite(r,i)}catch{}s&&Sm(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){typeof this.ws<"u"&&(this.ws.close(),this.ws=null)}uri(){const t=this.opts.secure?"wss":"ws",n=this.query||{};return this.opts.timestampRequests&&(n[this.opts.timestampParam]=EO()),this.supportsBinary||(n.b64=1),this.createUri(t,n)}}const Ag=us.WebSocket||us.MozWebSocket;class l9 extends a9{createSocket(t,n,r){return TO?new Ag(t,n,r):n?new Ag(t,n):new Ag(t)}doWrite(t,n){this.ws.send(n)}}class u9 extends Gw{get name(){return"webtransport"}doOpen(){try{this._transport=new WebTransport(this.createUri("https"),this.opts.transportOptions[this.name])}catch(t){return this.emitReserved("error",t)}this._transport.closed.then(()=>{this.onClose()}).catch(t=>{this.onError("webtransport error",t)}),this._transport.ready.then(()=>{this._transport.createBidirectionalStream().then(t=>{const n=jK(Number.MAX_SAFE_INTEGER,this.socket.binaryType),r=t.readable.pipeThrough(n).getReader(),s=zK();s.readable.pipeTo(t.writable),this._writer=s.writable.getWriter();const i=()=>{r.read().then(({done:a,value:l})=>{a||(this.onPacket(l),i())}).catch(a=>{})};i();const o={type:"open"};this.query.sid&&(o.data=`{"sid":"${this.query.sid}"}`),this._writer.write(o).then(()=>this.onOpen())})})}write(t){this.writable=!1;for(let n=0;n<t.length;n++){const r=t[n],s=n===t.length-1;this._writer.write(r).then(()=>{s&&Sm(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){var t;(t=this._transport)===null||t===void 0||t.close()}}const c9={websocket:l9,webtransport:u9,polling:o9},d9=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,f9=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function Uy(e){if(e.length>8e3)throw"URI too long";const t=e,n=e.indexOf("["),r=e.indexOf("]");n!=-1&&r!=-1&&(e=e.substring(0,n)+e.substring(n,r).replace(/:/g,";")+e.substring(r,e.length));let s=d9.exec(e||""),i={},o=14;for(;o--;)i[f9[o]]=s[o]||"";return n!=-1&&r!=-1&&(i.source=t,i.host=i.host.substring(1,i.host.length-1).replace(/;/g,":"),i.authority=i.authority.replace("[","").replace("]","").replace(/;/g,":"),i.ipv6uri=!0),i.pathNames=h9(i,i.path),i.queryKey=p9(i,i.query),i}function h9(e,t){const n=/\/{2,9}/g,r=t.replace(n,"/").split("/");return(t.slice(0,1)=="/"||t.length===0)&&r.splice(0,1),t.slice(-1)=="/"&&r.splice(r.length-1,1),r}function p9(e,t){const n={};return t.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(r,s,i){s&&(n[s]=i)}),n}const Hy=typeof addEventListener=="function"&&typeof removeEventListener=="function",dh=[];Hy&&addEventListener("offline",()=>{dh.forEach(e=>e())},!1);class Mo extends bn{constructor(t,n){if(super(),this.binaryType=WK,this.writeBuffer=[],this._prevBufferLen=0,this._pingInterval=-1,this._pingTimeout=-1,this._maxPayload=-1,this._pingTimeoutTime=1/0,t&&typeof t=="object"&&(n=t,t=null),t){const r=Uy(t);n.hostname=r.host,n.secure=r.protocol==="https"||r.protocol==="wss",n.port=r.port,r.query&&(n.query=r.query)}else n.host&&(n.hostname=Uy(n.host).host);_m(this,n),this.secure=n.secure!=null?n.secure:typeof location<"u"&&location.protocol==="https:",n.hostname&&!n.port&&(n.port=this.secure?"443":"80"),this.hostname=n.hostname||(typeof location<"u"?location.hostname:"localhost"),this.port=n.port||(typeof location<"u"&&location.port?location.port:this.secure?"443":"80"),this.transports=[],this._transportsByName={},n.transports.forEach(r=>{const s=r.prototype.name;this.transports.push(s),this._transportsByName[s]=r}),this.opts=Object.assign({path:"/engine.io",agent:!1,withCredentials:!1,upgrade:!0,timestampParam:"t",rememberUpgrade:!1,addTrailingSlash:!0,rejectUnauthorized:!0,perMessageDeflate:{threshold:1024},transportOptions:{},closeOnBeforeunload:!1},n),this.opts.path=this.opts.path.replace(/\/$/,"")+(this.opts.addTrailingSlash?"/":""),typeof this.opts.query=="string"&&(this.opts.query=ZK(this.opts.query)),Hy&&(this.opts.closeOnBeforeunload&&(this._beforeunloadEventListener=()=>{this.transport&&(this.transport.removeAllListeners(),this.transport.close())},addEventListener("beforeunload",this._beforeunloadEventListener,!1)),this.hostname!=="localhost"&&(this._offlineEventListener=()=>{this._onClose("transport close",{description:"network connection lost"})},dh.push(this._offlineEventListener))),this.opts.withCredentials&&(this._cookieJar=void 0),this._open()}createTransport(t){const n=Object.assign({},this.opts.query);n.EIO=kO,n.transport=t,this.id&&(n.sid=this.id);const r=Object.assign({},this.opts,{query:n,socket:this,hostname:this.hostname,secure:this.secure,port:this.port},this.opts.transportOptions[t]);return new this._transportsByName[t](r)}_open(){if(this.transports.length===0){this.setTimeoutFn(()=>{this.emitReserved("error","No transports available")},0);return}const t=this.opts.rememberUpgrade&&Mo.priorWebsocketSuccess&&this.transports.indexOf("websocket")!==-1?"websocket":this.transports[0];this.readyState="opening";const n=this.createTransport(t);n.open(),this.setTransport(n)}setTransport(t){this.transport&&this.transport.removeAllListeners(),this.transport=t,t.on("drain",this._onDrain.bind(this)).on("packet",this._onPacket.bind(this)).on("error",this._onError.bind(this)).on("close",n=>this._onClose("transport close",n))}onOpen(){this.readyState="open",Mo.priorWebsocketSuccess=this.transport.name==="websocket",this.emitReserved("open"),this.flush()}_onPacket(t){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing")switch(this.emitReserved("packet",t),this.emitReserved("heartbeat"),t.type){case"open":this.onHandshake(JSON.parse(t.data));break;case"ping":this._sendPacket("pong"),this.emitReserved("ping"),this.emitReserved("pong"),this._resetPingTimeout();break;case"error":const n=new Error("server error");n.code=t.data,this._onError(n);break;case"message":this.emitReserved("data",t.data),this.emitReserved("message",t.data);break}}onHandshake(t){this.emitReserved("handshake",t),this.id=t.sid,this.transport.query.sid=t.sid,this._pingInterval=t.pingInterval,this._pingTimeout=t.pingTimeout,this._maxPayload=t.maxPayload,this.onOpen(),this.readyState!=="closed"&&this._resetPingTimeout()}_resetPingTimeout(){this.clearTimeoutFn(this._pingTimeoutTimer);const t=this._pingInterval+this._pingTimeout;this._pingTimeoutTime=Date.now()+t,this._pingTimeoutTimer=this.setTimeoutFn(()=>{this._onClose("ping timeout")},t),this.opts.autoUnref&&this._pingTimeoutTimer.unref()}_onDrain(){this.writeBuffer.splice(0,this._prevBufferLen),this._prevBufferLen=0,this.writeBuffer.length===0?this.emitReserved("drain"):this.flush()}flush(){if(this.readyState!=="closed"&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length){const t=this._getWritablePackets();this.transport.send(t),this._prevBufferLen=t.length,this.emitReserved("flush")}}_getWritablePackets(){if(!(this._maxPayload&&this.transport.name==="polling"&&this.writeBuffer.length>1))return this.writeBuffer;let n=1;for(let r=0;r<this.writeBuffer.length;r++){const s=this.writeBuffer[r].data;if(s&&(n+=XK(s)),r>0&&n>this._maxPayload)return this.writeBuffer.slice(0,r);n+=2}return this.writeBuffer}_hasPingExpired(){if(!this._pingTimeoutTime)return!0;const t=Date.now()>this._pingTimeoutTime;return t&&(this._pingTimeoutTime=0,Sm(()=>{this._onClose("ping timeout")},this.setTimeoutFn)),t}write(t,n,r){return this._sendPacket("message",t,n,r),this}send(t,n,r){return this._sendPacket("message",t,n,r),this}_sendPacket(t,n,r,s){if(typeof n=="function"&&(s=n,n=void 0),typeof r=="function"&&(s=r,r=null),this.readyState==="closing"||this.readyState==="closed")return;r=r||{},r.compress=r.compress!==!1;const i={type:t,data:n,options:r};this.emitReserved("packetCreate",i),this.writeBuffer.push(i),s&&this.once("flush",s),this.flush()}close(){const t=()=>{this._onClose("forced close"),this.transport.close()},n=()=>{this.off("upgrade",n),this.off("upgradeError",n),t()},r=()=>{this.once("upgrade",n),this.once("upgradeError",n)};return(this.readyState==="opening"||this.readyState==="open")&&(this.readyState="closing",this.writeBuffer.length?this.once("drain",()=>{this.upgrading?r():t()}):this.upgrading?r():t()),this}_onError(t){if(Mo.priorWebsocketSuccess=!1,this.opts.tryAllTransports&&this.transports.length>1&&this.readyState==="opening")return this.transports.shift(),this._open();this.emitReserved("error",t),this._onClose("transport error",t)}_onClose(t,n){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing"){if(this.clearTimeoutFn(this._pingTimeoutTimer),this.transport.removeAllListeners("close"),this.transport.close(),this.transport.removeAllListeners(),Hy&&(this._beforeunloadEventListener&&removeEventListener("beforeunload",this._beforeunloadEventListener,!1),this._offlineEventListener)){const r=dh.indexOf(this._offlineEventListener);r!==-1&&dh.splice(r,1)}this.readyState="closed",this.id=null,this.emitReserved("close",t,n),this.writeBuffer=[],this._prevBufferLen=0}}}Mo.protocol=kO;class m9 extends Mo{constructor(){super(...arguments),this._upgrades=[]}onOpen(){if(super.onOpen(),this.readyState==="open"&&this.opts.upgrade)for(let t=0;t<this._upgrades.length;t++)this._probe(this._upgrades[t])}_probe(t){let n=this.createTransport(t),r=!1;Mo.priorWebsocketSuccess=!1;const s=()=>{r||(n.send([{type:"ping",data:"probe"}]),n.once("packet",c=>{if(!r)if(c.type==="pong"&&c.data==="probe"){if(this.upgrading=!0,this.emitReserved("upgrading",n),!n)return;Mo.priorWebsocketSuccess=n.name==="websocket",this.transport.pause(()=>{r||this.readyState!=="closed"&&(d(),this.setTransport(n),n.send([{type:"upgrade"}]),this.emitReserved("upgrade",n),n=null,this.upgrading=!1,this.flush())})}else{const f=new Error("probe error");f.transport=n.name,this.emitReserved("upgradeError",f)}}))};function i(){r||(r=!0,d(),n.close(),n=null)}const o=c=>{const f=new Error("probe error: "+c);f.transport=n.name,i(),this.emitReserved("upgradeError",f)};function a(){o("transport closed")}function l(){o("socket closed")}function u(c){n&&c.name!==n.name&&i()}const d=()=>{n.removeListener("open",s),n.removeListener("error",o),n.removeListener("close",a),this.off("close",l),this.off("upgrading",u)};n.once("open",s),n.once("error",o),n.once("close",a),this.once("close",l),this.once("upgrading",u),this._upgrades.indexOf("webtransport")!==-1&&t!=="webtransport"?this.setTimeoutFn(()=>{r||n.open()},200):n.open()}onHandshake(t){this._upgrades=this._filterUpgrades(t.upgrades),super.onHandshake(t)}_filterUpgrades(t){const n=[];for(let r=0;r<t.length;r++)~this.transports.indexOf(t[r])&&n.push(t[r]);return n}}let g9=class extends m9{constructor(t,n={}){const r=typeof t=="object"?t:n;(!r.transports||r.transports&&typeof r.transports[0]=="string")&&(r.transports=(r.transports||["polling","websocket","webtransport"]).map(s=>c9[s]).filter(s=>!!s)),super(t,r)}};function v9(e,t="",n){let r=e;n=n||typeof location<"u"&&location,e==null&&(e=n.protocol+"//"+n.host),typeof e=="string"&&(e.charAt(0)==="/"&&(e.charAt(1)==="/"?e=n.protocol+e:e=n.host+e),/^(https?|wss?):\/\//.test(e)||(typeof n<"u"?e=n.protocol+"//"+e:e="https://"+e),r=Uy(e)),r.port||(/^(http|ws)$/.test(r.protocol)?r.port="80":/^(http|ws)s$/.test(r.protocol)&&(r.port="443")),r.path=r.path||"/";const i=r.host.indexOf(":")!==-1?"["+r.host+"]":r.host;return r.id=r.protocol+"://"+i+":"+r.port+t,r.href=r.protocol+"://"+i+(n&&n.port===r.port?"":":"+r.port),r}const y9=typeof ArrayBuffer=="function",b9=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e.buffer instanceof ArrayBuffer,RO=Object.prototype.toString,w9=typeof Blob=="function"||typeof Blob<"u"&&RO.call(Blob)==="[object BlobConstructor]",S9=typeof File=="function"||typeof File<"u"&&RO.call(File)==="[object FileConstructor]";function Kw(e){return y9&&(e instanceof ArrayBuffer||b9(e))||w9&&e instanceof Blob||S9&&e instanceof File}function fh(e,t){if(!e||typeof e!="object")return!1;if(Array.isArray(e)){for(let n=0,r=e.length;n<r;n++)if(fh(e[n]))return!0;return!1}if(Kw(e))return!0;if(e.toJSON&&typeof e.toJSON=="function"&&arguments.length===1)return fh(e.toJSON(),!0);for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&fh(e[n]))return!0;return!1}function _9(e){const t=[],n=e.data,r=e;return r.data=zy(n,t),r.attachments=t.length,{packet:r,buffers:t}}function zy(e,t){if(!e)return e;if(Kw(e)){const n={_placeholder:!0,num:t.length};return t.push(e),n}else if(Array.isArray(e)){const n=new Array(e.length);for(let r=0;r<e.length;r++)n[r]=zy(e[r],t);return n}else if(typeof e=="object"&&!(e instanceof Date)){const n={};for(const r in e)Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=zy(e[r],t));return n}return e}function k9(e,t){return e.data=jy(e.data,t),delete e.attachments,e}function jy(e,t){if(!e)return e;if(e&&e._placeholder===!0){if(typeof e.num=="number"&&e.num>=0&&e.num<t.length)return t[e.num];throw new Error("illegal attachments")}else if(Array.isArray(e))for(let n=0;n<e.length;n++)e[n]=jy(e[n],t);else if(typeof e=="object")for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(e[n]=jy(e[n],t));return e}const x9=["connect","connect_error","disconnect","disconnecting","newListener","removeListener"],E9=5;var mt;(function(e){e[e.CONNECT=0]="CONNECT",e[e.DISCONNECT=1]="DISCONNECT",e[e.EVENT=2]="EVENT",e[e.ACK=3]="ACK",e[e.CONNECT_ERROR=4]="CONNECT_ERROR",e[e.BINARY_EVENT=5]="BINARY_EVENT",e[e.BINARY_ACK=6]="BINARY_ACK"})(mt||(mt={}));class C9{constructor(t){this.replacer=t}encode(t){return(t.type===mt.EVENT||t.type===mt.ACK)&&fh(t)?this.encodeAsBinary({type:t.type===mt.EVENT?mt.BINARY_EVENT:mt.BINARY_ACK,nsp:t.nsp,data:t.data,id:t.id}):[this.encodeAsString(t)]}encodeAsString(t){let n=""+t.type;return(t.type===mt.BINARY_EVENT||t.type===mt.BINARY_ACK)&&(n+=t.attachments+"-"),t.nsp&&t.nsp!=="/"&&(n+=t.nsp+","),t.id!=null&&(n+=t.id),t.data!=null&&(n+=JSON.stringify(t.data,this.replacer)),n}encodeAsBinary(t){const n=_9(t),r=this.encodeAsString(n.packet),s=n.buffers;return s.unshift(r),s}}function Dk(e){return Object.prototype.toString.call(e)==="[object Object]"}class Yw extends bn{constructor(t){super(),this.reviver=t}add(t){let n;if(typeof t=="string"){if(this.reconstructor)throw new Error("got plaintext data when reconstructing a packet");n=this.decodeString(t);const r=n.type===mt.BINARY_EVENT;r||n.type===mt.BINARY_ACK?(n.type=r?mt.EVENT:mt.ACK,this.reconstructor=new P9(n),n.attachments===0&&super.emitReserved("decoded",n)):super.emitReserved("decoded",n)}else if(Kw(t)||t.base64)if(this.reconstructor)n=this.reconstructor.takeBinaryData(t),n&&(this.reconstructor=null,super.emitReserved("decoded",n));else throw new Error("got binary data when not reconstructing a packet");else throw new Error("Unknown type: "+t)}decodeString(t){let n=0;const r={type:Number(t.charAt(0))};if(mt[r.type]===void 0)throw new Error("unknown packet type "+r.type);if(r.type===mt.BINARY_EVENT||r.type===mt.BINARY_ACK){const i=n+1;for(;t.charAt(++n)!=="-"&&n!=t.length;);const o=t.substring(i,n);if(o!=Number(o)||t.charAt(n)!=="-")throw new Error("Illegal attachments");r.attachments=Number(o)}if(t.charAt(n+1)==="/"){const i=n+1;for(;++n&&!(t.charAt(n)===","||n===t.length););r.nsp=t.substring(i,n)}else r.nsp="/";const s=t.charAt(n+1);if(s!==""&&Number(s)==s){const i=n+1;for(;++n;){const o=t.charAt(n);if(o==null||Number(o)!=o){--n;break}if(n===t.length)break}r.id=Number(t.substring(i,n+1))}if(t.charAt(++n)){const i=this.tryParse(t.substr(n));if(Yw.isPayloadValid(r.type,i))r.data=i;else throw new Error("invalid payload")}return r}tryParse(t){try{return JSON.parse(t,this.reviver)}catch{return!1}}static isPayloadValid(t,n){switch(t){case mt.CONNECT:return Dk(n);case mt.DISCONNECT:return n===void 0;case mt.CONNECT_ERROR:return typeof n=="string"||Dk(n);case mt.EVENT:case mt.BINARY_EVENT:return Array.isArray(n)&&(typeof n[0]=="number"||typeof n[0]=="string"&&x9.indexOf(n[0])===-1);case mt.ACK:case mt.BINARY_ACK:return Array.isArray(n)}}destroy(){this.reconstructor&&(this.reconstructor.finishedReconstruction(),this.reconstructor=null)}}class P9{constructor(t){this.packet=t,this.buffers=[],this.reconPack=t}takeBinaryData(t){if(this.buffers.push(t),this.buffers.length===this.reconPack.attachments){const n=k9(this.reconPack,this.buffers);return this.finishedReconstruction(),n}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}}const T9=Object.freeze(Object.defineProperty({__proto__:null,Decoder:Yw,Encoder:C9,get PacketType(){return mt},protocol:E9},Symbol.toStringTag,{value:"Module"}));function xs(e,t,n){return e.on(t,n),function(){e.off(t,n)}}const R9=Object.freeze({connect:1,connect_error:1,disconnect:1,disconnecting:1,newListener:1,removeListener:1});class IO extends bn{constructor(t,n,r){super(),this.connected=!1,this.recovered=!1,this.receiveBuffer=[],this.sendBuffer=[],this._queue=[],this._queueSeq=0,this.ids=0,this.acks={},this.flags={},this.io=t,this.nsp=n,r&&r.auth&&(this.auth=r.auth),this._opts=Object.assign({},r),this.io._autoConnect&&this.open()}get disconnected(){return!this.connected}subEvents(){if(this.subs)return;const t=this.io;this.subs=[xs(t,"open",this.onopen.bind(this)),xs(t,"packet",this.onpacket.bind(this)),xs(t,"error",this.onerror.bind(this)),xs(t,"close",this.onclose.bind(this))]}get active(){return!!this.subs}connect(){return this.connected?this:(this.subEvents(),this.io._reconnecting||this.io.open(),this.io._readyState==="open"&&this.onopen(),this)}open(){return this.connect()}send(...t){return t.unshift("message"),this.emit.apply(this,t),this}emit(t,...n){var r,s,i;if(R9.hasOwnProperty(t))throw new Error('"'+t.toString()+'" is a reserved event name');if(n.unshift(t),this._opts.retries&&!this.flags.fromQueue&&!this.flags.volatile)return this._addToQueue(n),this;const o={type:mt.EVENT,data:n};if(o.options={},o.options.compress=this.flags.compress!==!1,typeof n[n.length-1]=="function"){const d=this.ids++,c=n.pop();this._registerAckCallback(d,c),o.id=d}const a=(s=(r=this.io.engine)===null||r===void 0?void 0:r.transport)===null||s===void 0?void 0:s.writable,l=this.connected&&!(!((i=this.io.engine)===null||i===void 0)&&i._hasPingExpired());return this.flags.volatile&&!a||(l?(this.notifyOutgoingListeners(o),this.packet(o)):this.sendBuffer.push(o)),this.flags={},this}_registerAckCallback(t,n){var r;const s=(r=this.flags.timeout)!==null&&r!==void 0?r:this._opts.ackTimeout;if(s===void 0){this.acks[t]=n;return}const i=this.io.setTimeoutFn(()=>{delete this.acks[t];for(let a=0;a<this.sendBuffer.length;a++)this.sendBuffer[a].id===t&&this.sendBuffer.splice(a,1);n.call(this,new Error("operation has timed out"))},s),o=(...a)=>{this.io.clearTimeoutFn(i),n.apply(this,a)};o.withError=!0,this.acks[t]=o}emitWithAck(t,...n){return new Promise((r,s)=>{const i=(o,a)=>o?s(o):r(a);i.withError=!0,n.push(i),this.emit(t,...n)})}_addToQueue(t){let n;typeof t[t.length-1]=="function"&&(n=t.pop());const r={id:this._queueSeq++,tryCount:0,pending:!1,args:t,flags:Object.assign({fromQueue:!0},this.flags)};t.push((s,...i)=>r!==this._queue[0]?void 0:(s!==null?r.tryCount>this._opts.retries&&(this._queue.shift(),n&&n(s)):(this._queue.shift(),n&&n(null,...i)),r.pending=!1,this._drainQueue())),this._queue.push(r),this._drainQueue()}_drainQueue(t=!1){if(!this.connected||this._queue.length===0)return;const n=this._queue[0];n.pending&&!t||(n.pending=!0,n.tryCount++,this.flags=n.flags,this.emit.apply(this,n.args))}packet(t){t.nsp=this.nsp,this.io._packet(t)}onopen(){typeof this.auth=="function"?this.auth(t=>{this._sendConnectPacket(t)}):this._sendConnectPacket(this.auth)}_sendConnectPacket(t){this.packet({type:mt.CONNECT,data:this._pid?Object.assign({pid:this._pid,offset:this._lastOffset},t):t})}onerror(t){this.connected||this.emitReserved("connect_error",t)}onclose(t,n){this.connected=!1,delete this.id,this.emitReserved("disconnect",t,n),this._clearAcks()}_clearAcks(){Object.keys(this.acks).forEach(t=>{if(!this.sendBuffer.some(r=>String(r.id)===t)){const r=this.acks[t];delete this.acks[t],r.withError&&r.call(this,new Error("socket has been disconnected"))}})}onpacket(t){if(t.nsp===this.nsp)switch(t.type){case mt.CONNECT:t.data&&t.data.sid?this.onconnect(t.data.sid,t.data.pid):this.emitReserved("connect_error",new Error("It seems you are trying to reach a Socket.IO server in v2.x with a v3.x client, but they are not compatible (more information here: https://socket.io/docs/v3/migrating-from-2-x-to-3-0/)"));break;case mt.EVENT:case mt.BINARY_EVENT:this.onevent(t);break;case mt.ACK:case mt.BINARY_ACK:this.onack(t);break;case mt.DISCONNECT:this.ondisconnect();break;case mt.CONNECT_ERROR:this.destroy();const r=new Error(t.data.message);r.data=t.data.data,this.emitReserved("connect_error",r);break}}onevent(t){const n=t.data||[];t.id!=null&&n.push(this.ack(t.id)),this.connected?this.emitEvent(n):this.receiveBuffer.push(Object.freeze(n))}emitEvent(t){if(this._anyListeners&&this._anyListeners.length){const n=this._anyListeners.slice();for(const r of n)r.apply(this,t)}super.emit.apply(this,t),this._pid&&t.length&&typeof t[t.length-1]=="string"&&(this._lastOffset=t[t.length-1])}ack(t){const n=this;let r=!1;return function(...s){r||(r=!0,n.packet({type:mt.ACK,id:t,data:s}))}}onack(t){const n=this.acks[t.id];typeof n=="function"&&(delete this.acks[t.id],n.withError&&t.data.unshift(null),n.apply(this,t.data))}onconnect(t,n){this.id=t,this.recovered=n&&this._pid===n,this._pid=n,this.connected=!0,this.emitBuffered(),this.emitReserved("connect"),this._drainQueue(!0)}emitBuffered(){this.receiveBuffer.forEach(t=>this.emitEvent(t)),this.receiveBuffer=[],this.sendBuffer.forEach(t=>{this.notifyOutgoingListeners(t),this.packet(t)}),this.sendBuffer=[]}ondisconnect(){this.destroy(),this.onclose("io server disconnect")}destroy(){this.subs&&(this.subs.forEach(t=>t()),this.subs=void 0),this.io._destroy(this)}disconnect(){return this.connected&&this.packet({type:mt.DISCONNECT}),this.destroy(),this.connected&&this.onclose("io client disconnect"),this}close(){return this.disconnect()}compress(t){return this.flags.compress=t,this}get volatile(){return this.flags.volatile=!0,this}timeout(t){return this.flags.timeout=t,this}onAny(t){return this._anyListeners=this._anyListeners||[],this._anyListeners.push(t),this}prependAny(t){return this._anyListeners=this._anyListeners||[],this._anyListeners.unshift(t),this}offAny(t){if(!this._anyListeners)return this;if(t){const n=this._anyListeners;for(let r=0;r<n.length;r++)if(t===n[r])return n.splice(r,1),this}else this._anyListeners=[];return this}listenersAny(){return this._anyListeners||[]}onAnyOutgoing(t){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.push(t),this}prependAnyOutgoing(t){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.unshift(t),this}offAnyOutgoing(t){if(!this._anyOutgoingListeners)return this;if(t){const n=this._anyOutgoingListeners;for(let r=0;r<n.length;r++)if(t===n[r])return n.splice(r,1),this}else this._anyOutgoingListeners=[];return this}listenersAnyOutgoing(){return this._anyOutgoingListeners||[]}notifyOutgoingListeners(t){if(this._anyOutgoingListeners&&this._anyOutgoingListeners.length){const n=this._anyOutgoingListeners.slice();for(const r of n)r.apply(this,t.data)}}}function zu(e){e=e||{},this.ms=e.min||100,this.max=e.max||1e4,this.factor=e.factor||2,this.jitter=e.jitter>0&&e.jitter<=1?e.jitter:0,this.attempts=0}zu.prototype.duration=function(){var e=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var t=Math.random(),n=Math.floor(t*this.jitter*e);e=Math.floor(t*10)&1?e+n:e-n}return Math.min(e,this.max)|0};zu.prototype.reset=function(){this.attempts=0};zu.prototype.setMin=function(e){this.ms=e};zu.prototype.setMax=function(e){this.max=e};zu.prototype.setJitter=function(e){this.jitter=e};class qy extends bn{constructor(t,n){var r;super(),this.nsps={},this.subs=[],t&&typeof t=="object"&&(n=t,t=void 0),n=n||{},n.path=n.path||"/socket.io",this.opts=n,_m(this,n),this.reconnection(n.reconnection!==!1),this.reconnectionAttempts(n.reconnectionAttempts||1/0),this.reconnectionDelay(n.reconnectionDelay||1e3),this.reconnectionDelayMax(n.reconnectionDelayMax||5e3),this.randomizationFactor((r=n.randomizationFactor)!==null&&r!==void 0?r:.5),this.backoff=new zu({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(n.timeout==null?2e4:n.timeout),this._readyState="closed",this.uri=t;const s=n.parser||T9;this.encoder=new s.Encoder,this.decoder=new s.Decoder,this._autoConnect=n.autoConnect!==!1,this._autoConnect&&this.open()}reconnection(t){return arguments.length?(this._reconnection=!!t,t||(this.skipReconnect=!0),this):this._reconnection}reconnectionAttempts(t){return t===void 0?this._reconnectionAttempts:(this._reconnectionAttempts=t,this)}reconnectionDelay(t){var n;return t===void 0?this._reconnectionDelay:(this._reconnectionDelay=t,(n=this.backoff)===null||n===void 0||n.setMin(t),this)}randomizationFactor(t){var n;return t===void 0?this._randomizationFactor:(this._randomizationFactor=t,(n=this.backoff)===null||n===void 0||n.setJitter(t),this)}reconnectionDelayMax(t){var n;return t===void 0?this._reconnectionDelayMax:(this._reconnectionDelayMax=t,(n=this.backoff)===null||n===void 0||n.setMax(t),this)}timeout(t){return arguments.length?(this._timeout=t,this):this._timeout}maybeReconnectOnOpen(){!this._reconnecting&&this._reconnection&&this.backoff.attempts===0&&this.reconnect()}open(t){if(~this._readyState.indexOf("open"))return this;this.engine=new g9(this.uri,this.opts);const n=this.engine,r=this;this._readyState="opening",this.skipReconnect=!1;const s=xs(n,"open",function(){r.onopen(),t&&t()}),i=a=>{this.cleanup(),this._readyState="closed",this.emitReserved("error",a),t?t(a):this.maybeReconnectOnOpen()},o=xs(n,"error",i);if(this._timeout!==!1){const a=this._timeout,l=this.setTimeoutFn(()=>{s(),i(new Error("timeout")),n.close()},a);this.opts.autoUnref&&l.unref(),this.subs.push(()=>{this.clearTimeoutFn(l)})}return this.subs.push(s),this.subs.push(o),this}connect(t){return this.open(t)}onopen(){this.cleanup(),this._readyState="open",this.emitReserved("open");const t=this.engine;this.subs.push(xs(t,"ping",this.onping.bind(this)),xs(t,"data",this.ondata.bind(this)),xs(t,"error",this.onerror.bind(this)),xs(t,"close",this.onclose.bind(this)),xs(this.decoder,"decoded",this.ondecoded.bind(this)))}onping(){this.emitReserved("ping")}ondata(t){try{this.decoder.add(t)}catch(n){this.onclose("parse error",n)}}ondecoded(t){Sm(()=>{this.emitReserved("packet",t)},this.setTimeoutFn)}onerror(t){this.emitReserved("error",t)}socket(t,n){let r=this.nsps[t];return r?this._autoConnect&&!r.active&&r.connect():(r=new IO(this,t,n),this.nsps[t]=r),r}_destroy(t){const n=Object.keys(this.nsps);for(const r of n)if(this.nsps[r].active)return;this._close()}_packet(t){const n=this.encoder.encode(t);for(let r=0;r<n.length;r++)this.engine.write(n[r],t.options)}cleanup(){this.subs.forEach(t=>t()),this.subs.length=0,this.decoder.destroy()}_close(){this.skipReconnect=!0,this._reconnecting=!1,this.onclose("forced close")}disconnect(){return this._close()}onclose(t,n){var r;this.cleanup(),(r=this.engine)===null||r===void 0||r.close(),this.backoff.reset(),this._readyState="closed",this.emitReserved("close",t,n),this._reconnection&&!this.skipReconnect&&this.reconnect()}reconnect(){if(this._reconnecting||this.skipReconnect)return this;const t=this;if(this.backoff.attempts>=this._reconnectionAttempts)this.backoff.reset(),this.emitReserved("reconnect_failed"),this._reconnecting=!1;else{const n=this.backoff.duration();this._reconnecting=!0;const r=this.setTimeoutFn(()=>{t.skipReconnect||(this.emitReserved("reconnect_attempt",t.backoff.attempts),!t.skipReconnect&&t.open(s=>{s?(t._reconnecting=!1,t.reconnect(),this.emitReserved("reconnect_error",s)):t.onreconnect()}))},n);this.opts.autoUnref&&r.unref(),this.subs.push(()=>{this.clearTimeoutFn(r)})}}onreconnect(){const t=this.backoff.attempts;this._reconnecting=!1,this.backoff.reset(),this.emitReserved("reconnect",t)}}const tc={};function hh(e,t){typeof e=="object"&&(t=e,e=void 0),t=t||{};const n=v9(e,t.path||"/socket.io"),r=n.source,s=n.id,i=n.path,o=tc[s]&&i in tc[s].nsps,a=t.forceNew||t["force new connection"]||t.multiplex===!1||o;let l;return a?l=new qy(r,t):(tc[s]||(tc[s]=new qy(r,t)),l=tc[s]),n.query&&!t.query&&(t.query=n.queryKey),l.socket(n.path,t)}Object.assign(hh,{Manager:qy,Socket:IO,io:hh,connect:hh});let Qt=null;const xr=vn({connected:!1,setup:!1,id:""});function I9(e,t){if(xr.setup)throw new Error("Socket already set up");xr.setup=!1,Qt=hh(e,{auth:t!=null&&t.length?{token:t}:void 0}),xr.setup=!0,Qt.on("connect",()=>{xr.id=Qt.id||"",xr.connected=!0}),Qt.on("disconnect",()=>{xr.id="",xr.connected=!1})}function A9(){xr.connected=!1,Qt==null||Qt.close(),Qt==null||Qt.open()}function O9(){Qt&&Qt.close(),Qt=null,xr.setup=!1,xr.connected=!1,xr.id=""}function M9(){if(!Qt)return console.warn("Socket not set-up"),{setup:!1};const e={setup:!0,active:Qt.active,connected:Qt.connected,id:Qt.id,recovered:Qt.recovered};return console.warn(e),e}const D9=de({scrollTarget:{type:String},scrollThreshold:{type:[String,Number],default:300}},"scroll");function L9(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const{canScroll:n}=t;let r=0,s=0;const i=U(null),o=Me(0),a=Me(0),l=Me(0),u=Me(!1),d=Me(!1),c=R(()=>Number(e.scrollThreshold)),f=R(()=>Rr((c.value-o.value)/c.value||0)),p=()=>{const g=i.value;if(!g||n&&!n.value)return;r=o.value,o.value="window"in g?g.pageYOffset:g.scrollTop;const m=g instanceof Window?document.documentElement.scrollHeight:g.scrollHeight;if(s!==m){s=m;return}d.value=o.value<r,l.value=Math.abs(o.value-c.value)};return Ce(d,()=>{a.value=a.value||o.value}),Ce(u,()=>{a.value=0}),St(()=>{Ce(()=>e.scrollTarget,g=>{var y;const m=g?document.querySelector(g):window;m&&m!==i.value&&((y=i.value)==null||y.removeEventListener("scroll",p),i.value=m,i.value.addEventListener("scroll",p,{passive:!0}))},{immediate:!0})}),Tn(()=>{var g;(g=i.value)==null||g.removeEventListener("scroll",p)}),n&&Ce(n,p,{immediate:!0}),{scrollThreshold:c,currentScroll:o,currentThreshold:l,isScrollActive:u,scrollRatio:f,isScrollingUp:d,savedScroll:a}}const $9=de({scrollBehavior:String,modelValue:{type:Boolean,default:!0},location:{type:String,default:"top",validator:e=>["top","bottom"].includes(e)},...rO(),...RA(),...D9(),height:{type:[Number,String],default:64}},"VAppBar"),AO=xe()({name:"VAppBar",props:$9(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const r=U(),s=st(e,"modelValue"),i=R(()=>{var S;const w=new Set(((S=e.scrollBehavior)==null?void 0:S.split(" "))??[]);return{hide:w.has("hide"),fullyHide:w.has("fully-hide"),inverted:w.has("inverted"),collapse:w.has("collapse"),elevate:w.has("elevate"),fadeImage:w.has("fade-image")}}),o=R(()=>{const w=i.value;return w.hide||w.fullyHide||w.inverted||w.collapse||w.elevate||w.fadeImage||!s.value}),{currentScroll:a,scrollThreshold:l,isScrollingUp:u,scrollRatio:d}=L9(e,{canScroll:o}),c=R(()=>i.value.hide||i.value.fullyHide),f=R(()=>e.collapse||i.value.collapse&&(i.value.inverted?d.value>0:d.value===0)),p=R(()=>e.flat||i.value.fullyHide&&!s.value||i.value.elevate&&(i.value.inverted?a.value>0:a.value===0)),g=R(()=>i.value.fadeImage?i.value.inverted?1-d.value:d.value:void 0),m=R(()=>{var P,E;if(i.value.hide&&i.value.inverted)return 0;const w=((P=r.value)==null?void 0:P.contentHeight)??0,S=((E=r.value)==null?void 0:E.extensionHeight)??0;return c.value?a.value<l.value||i.value.fullyHide?w+S:w:w+S});Qr(R(()=>!!e.scrollBehavior),()=>{jn(()=>{c.value?i.value.inverted?s.value=a.value>l.value:s.value=u.value||a.value<l.value:s.value=!0})});const{ssrBootStyles:y}=qd(),{layoutItemStyles:b}=AA({id:e.name,order:R(()=>parseInt(e.order,10)),position:Te(e,"location"),layoutSize:m,elementSize:Me(void 0),active:s,absolute:Te(e,"absolute")});return Ie(()=>{const w=sr.filterProps(e);return h(sr,me({ref:r,class:["v-app-bar",{"v-app-bar--bottom":e.location==="bottom"},e.class],style:[{...b.value,"--v-toolbar-image-opacity":g.value,height:void 0,...y.value},e.style]},w,{collapse:f.value,flat:p.value}),n)}),{}}}),F9=de({...GP({icon:"$menu",variant:"text"})},"VAppBarNavIcon"),N9=xe()({name:"VAppBarNavIcon",props:F9(),setup(e,t){let{slots:n}=t;return Ie(()=>h(re,me(e,{class:["v-app-bar-nav-icon"]}),n)),{}}}),B9={key:1,class:"text-uppercase text--white"},V9={key:3,class:"ml-2"},U9={key:4,class:"ml-2"},H9=Le({__name:"TopBar",setup(e){const t=jw(),n=ps(),r=Zo(),s=[{title:"Open Profile",icon:"person",path:"/settings/account"}],i=U(Date.now());K$(()=>{i.value=Date.now()},1e3);const o=R(()=>{var c;if(!((c=n.tokenClaims)!=null&&c.exp))return"";const d=n.tokenClaims.exp-i.value/1e3;return`${Math.round(d)}s`}),a=R(()=>t.username),l=R(()=>n.isDemoMode);async function u(){await n.logout(!0),await vO(r)}return(d,c)=>{const f=R7,p=T7;return $(),Q(AO,{color:"primary"},{default:v(()=>[h(mn,{class:"text-uppercase text-white"},{default:v(()=>c[1]||(c[1]=[L("span",{class:"font-weight-light"}," FDM ",-1),L("strong",null," Monster ",-1)])),_:1}),l.value?($(),Q(wn,{key:0})):ve("",!0),l.value?($(),we("h2",B9," DEMO MODE ")):ve("",!0),h(wn),h(DK),ie(n).hasAuthToken&&!ie(n).isLoginExpired?($(),Q(Wd,{key:2,"close-on-content-click":!1,location:"bottom right","open-on-hover":"",transition:"slide-y-transition"},{activator:v(({props:g})=>[h(re,me({class:"ml-2",color:"secondary",theme:"dark"},g),{default:v(()=>[h(X,{class:"mr-2"},{default:v(()=>c[2]||(c[2]=[_("person")])),_:1}),_(" "+ae(a.value),1)]),_:2},1040)]),default:v(()=>[h(Kt,null,{default:v(()=>[($(),we(Re,null,Zt(s,(g,m)=>h(Fe,{key:m,to:g.path,title:g.title,"prepend-avatar":g.icon,link:""},null,8,["to","title","prepend-avatar"])),64))]),_:1})]),_:1})):ve("",!0),ie(Rk)&&o.value?($(),we("span",V9," AuthExp "+ae(o.value),1)):ve("",!0),ie(Rk)?($(),we("span",U9,[L("small",null," S"+ae(ie(xr).setup?1:0)+" C"+ae(ie(xr).connected?1:0)+" "+ae(ie(xr).id),1)])):ve("",!0),ie(n).loginRequired===!0?($(),Q(f,{key:5,tooltip:"Go back to login",text:"Logout",color:"secondary",icon:"logout",onClick:c[0]||(c[0]=g=>u())})):ve("",!0),ie(n).loginRequired===!0?($(),Q(re,{key:6,class:"ml-2"},{default:v(()=>[h(X,{class:"mr-2"},{default:v(()=>c[3]||(c[3]=[_("logout")])),_:1}),c[4]||(c[4]=_(" Logout "))]),_:1})):ve("",!0),h(p)]),_:1})}}}),OO="/assets/logo-CJVdjy51.png",z9=Le({__name:"NavigationDrawer",setup(e){const t=[["home","Devices","/"],["print","Printers","/printers"],["camera_alt","CameraGridView","/cameras"],["settings","Settings","/settings"],["timeline","PrintStatistics","/statistics"],["contact_support","About","/about"]];return(n,r)=>($(),Q(Rw,{permanent:"",rail:"",theme:"dark",class:"nav-side-background"},{default:v(()=>[h(N9,{class:"ml-1 mt-2"},{default:v(()=>[h(Ki,{alt:"FDM Monster Logo",src:ie(OO),class:"shrink mr-1 pt-3 ml-1",transition:"scale-transition",width:"40"},null,8,["src"])]),_:1}),h(yn),h(Kt,{density:"compact",nav:""},{default:v(()=>[($(),we(Re,null,Zt(t,([s,i,o],a)=>h(Fe,{key:a,to:o,"prepend-icon":s,title:i,density:"comfortable","router-link":""},null,8,["to","prepend-icon","title"])),64))]),_:1})]),_:1}))}});function j9(e){const t=Me(e());let n=-1;function r(){clearInterval(n)}function s(){r(),Ot(()=>t.value=e())}function i(o){const a=o?getComputedStyle(o):{transitionDuration:.2},l=parseFloat(a.transitionDuration)*1e3||200;if(r(),t.value<=0)return;const u=performance.now();n=window.setInterval(()=>{const d=performance.now()-u+l;t.value=Math.max(e()-d,0),t.value<=0&&r()},l)}return Sn(r),{clear:r,time:t,start:i,reset:s}}const q9=de({multiLine:Boolean,text:String,timer:[Boolean,String],timeout:{type:[Number,String],default:5e3},vertical:Boolean,...Ko({location:"bottom"}),...Tu(),...Bn(),...Fs(),...Dt(),...Ds(Od({transition:"v-snackbar-transition"}),["persistent","noClickAnimation","scrim","scrollStrategy"])},"VSnackbar"),Xw=xe()({name:"VSnackbar",props:q9(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const r=st(e,"modelValue"),{positionClasses:s}=Ru(e),{scopeId:i}=Au(),{themeClasses:o}=Xt(e),{colorClasses:a,colorStyles:l,variantClasses:u}=el(e),{roundedClasses:d}=qn(e),c=j9(()=>Number(e.timeout)),f=U(),p=U(),g=Me(!1),m=Me(0),y=U(),b=Ye(id,void 0);Qr(()=>!!b,()=>{const M=IA();jn(()=>{y.value=M.mainStyles.value})}),Ce(r,S),Ce(()=>e.timeout,S),St(()=>{r.value&&S()});let w=-1;function S(){c.reset(),window.clearTimeout(w);const M=Number(e.timeout);if(!r.value||M===-1)return;const O=Tb(p.value);c.start(O),w=window.setTimeout(()=>{r.value=!1},M)}function P(){c.reset(),window.clearTimeout(w)}function E(){g.value=!0,P()}function T(){g.value=!1,S()}function C(M){m.value=M.touches[0].clientY}function k(M){Math.abs(m.value-M.changedTouches[0].clientY)>50&&(r.value=!1)}function x(){g.value&&T()}const I=R(()=>e.location.split(" ").reduce((M,O)=>(M[`v-snackbar--${O}`]=!0,M),{}));return Ie(()=>{const M=Ni.filterProps(e),O=!!(n.default||n.text||e.text);return h(Ni,me({ref:f,class:["v-snackbar",{"v-snackbar--active":r.value,"v-snackbar--multi-line":e.multiLine&&!e.vertical,"v-snackbar--timer":!!e.timer,"v-snackbar--vertical":e.vertical},I.value,s.value,e.class],style:[y.value,e.style]},M,{modelValue:r.value,"onUpdate:modelValue":A=>r.value=A,contentProps:me({class:["v-snackbar__wrapper",o.value,a.value,d.value,u.value],style:[l.value],onPointerenter:E,onPointerleave:T},M.contentProps),persistent:!0,noClickAnimation:!0,scrim:!1,scrollStrategy:"none",_disableGlobalStack:!0,onTouchstartPassive:C,onTouchend:k,onAfterLeave:x},i),{default:()=>{var A,D;return[Go(!1,"v-snackbar"),e.timer&&!g.value&&h("div",{key:"timer",class:"v-snackbar__timer"},[h(lu,{ref:p,color:typeof e.timer=="string"?e.timer:"info",max:e.timeout,"model-value":c.time.value},null)]),O&&h("div",{key:"content",class:"v-snackbar__content",role:"status","aria-live":"polite"},[((A=n.text)==null?void 0:A.call(n))??e.text,(D=n.default)==null?void 0:D.call(n)]),n.actions&&h(At,{defaults:{VBtn:{variant:"text",ripple:!1,slim:!0}}},{default:()=>[h("div",{class:"v-snackbar__actions"},[n.actions({isActive:r})])]})]},activator:n.activator})}),Wi({},f)}}),W9={style:{width:"100%"}},G9={class:"font-weight-bold text-button"},K9=Le({__name:"AppProgressSnackbar",setup(e){const t=Mt(),n=U(!1),r=U(""),s=U([]),i=U(100);function o(u){return s.value.find(d=>d.key===u)}function a(u,d,c=0,f=!1,p=Date.now()+1500){console.log(`[AppProgressSnackbar] Adding ${u} tracker with progress ${c}`),s.value.push({key:u,title:d,value:c,completed:f,startedAt:Date.now(),expiresAt:p,timeoutAt:void 0})}function l(u){s.value=s.value.filter(d=>d.key!==u)}return St(()=>{setInterval(()=>{if(s.value.length){for(const u of s.value){const{value:d,completed:c,expiresAt:f,key:p}=u;(c||d>=100)&&f<Date.now()||u.timeoutAt&&u.timeoutAt<Date.now()?l(p):!u.timeoutAt&&f<Date.now()&&(u.timeoutAt=Date.now()+5e3)}s.value.length?(i.value=-1,n.value=!0):(i.value=2e3,r.value="Upload ended",console.debug(`[AppSnackbars] Setting timeout to ${i.value}`))}},1e3),t.onProgressMessage(u=>{const{key:d,value:c,title:f,completed:p}=u,g=o(d);if(g)Math.min(100,c)>=g.value&&(g.expiresAt=Date.now()+1500,g.value=c,g.completed=p);else{if(c>=100)return;a(d,f,c,!1,Date.now()+1500)}r.value="Uploading files"})}),(u,d)=>($(),Q(Xw,{modelValue:n.value,"onUpdate:modelValue":d[1]||(d[1]=c=>n.value=c),timeout:i.value,absolute:"",location:"bottom right",class:"ma-3 elevation-24","min-width":"450px","multi-line":"",rounded:"pill",style:{"z-index":"1000"}},{default:v(()=>[h(at,null,{default:v(()=>[h(Ue,{cols:"2"},{default:v(()=>[h(re,{icon:"file_upload",size:"large"})]),_:1}),h(Ue,{class:"d-flex align-center flex-row",cols:"8"},{default:v(()=>[L("div",W9,[L("span",G9,ae(r.value),1),($(!0),we(Re,null,Zt(s.value,(c,f)=>($(),we("div",{key:f,class:"mb-2"},[c.completed?($(),Q(X,{key:0},{default:v(()=>d[2]||(d[2]=[_("check")])),_:1})):c.timeoutAt?($(),Q(X,{key:1},{default:v(()=>d[3]||(d[3]=[_("pause")])),_:1})):($(),Q(X,{key:2},{default:v(()=>d[4]||(d[4]=[_("hourglass_bottom")])),_:1})),_(" "+ae(c.title)+" "+ae((c.completed?100:c.value).toFixed(1))+"% ",1),d[5]||(d[5]=L("br",null,null,-1)),($(),Q(lu,{key:c.key,"model-value":c.completed?100:c.value,color:c.timeoutAt?"red":"success"},null,8,["model-value","color"]))]))),128))])]),_:1}),h(Ue,{cols:"1"},{default:v(()=>[h(re,{icon:"close",size:"large",onClick:d[0]||(d[0]=c=>n.value=!1)})]),_:1})]),_:1})]),_:1},8,["modelValue","timeout"]))}}),Y9={class:"font-weight-bold text-button"},X9={key:0},Q9=Le({__name:"AppErrorSnackbar",setup(e){const t=Mt(),n=U(-1),r=U(!1),s=U(""),i=U("");return St(()=>{t.onErrorMessage(o=>{s.value=o.title,i.value=o.subtitle??"",r.value=!0,n.value=o.timeout??1e4})}),(o,a)=>($(),Q(Xw,{modelValue:r.value,"onUpdate:modelValue":a[1]||(a[1]=l=>r.value=l),timeout:n.value,absolute:"",location:"bottom",class:"ml-16 mb-16 ma-3 elevation-24",color:"error-darken-1",rounded:"pill","multi-line":"",style:{"z-index":"1000"},width:"450"},{default:v(()=>[h(at,null,{default:v(()=>[h(Ue,{cols:"2"},{default:v(()=>[h(re,{icon:"error"})]),_:1}),h(Ue,{class:"d-flex align-center flex-row",cols:"8"},{default:v(()=>{var l;return[L("div",null,[L("span",Y9,ae(s.value),1),(l=i.value)!=null&&l.length?($(),we("div",X9,ae(i.value),1)):ve("",!0)])]}),_:1}),h(Ue,{cols:"1"},{default:v(()=>[h(re,{icon:"close",onClick:a[0]||(a[0]=l=>r.value=!1)})]),_:1})]),_:1})]),_:1},8,["modelValue","timeout"]))}}),J9={class:"font-weight-bold text-button"},Z9={key:0},eY=Le({__name:"AppInfoSnackbar",setup(e){const t=Mt(),n=U(!1),r=U(""),s=U(""),i=U(2e3),o=U(!1);return St(()=>{t.onInfoMessage(a=>{r.value=a.title,s.value=a.subtitle??"",o.value=a.warning??!1,i.value=a.timeout??2e3,n.value=!0})}),(a,l)=>($(),Q(Xw,{modelValue:n.value,"onUpdate:modelValue":l[1]||(l[1]=u=>n.value=u),absolute:"",location:"bottom",color:o.value?"warning darken-2":"success",class:"ma-3 elevation-24",rounded:"pill",timeout:i.value,style:{"z-index":"1000"},"multi-line":""},{default:v(()=>[h(at,null,{default:v(()=>[h(Ue,{cols:"2"},{default:v(()=>[h(re,{icon:"info"})]),_:1}),h(Ue,{cols:"8",class:"d-flex align-center flex-row"},{default:v(()=>{var u;return[L("div",null,[L("span",J9,ae(r.value),1),(u=s.value)!=null&&u.length?($(),we("div",Z9,ae(s.value),1)):ve("",!0)])]}),_:1}),h(Ue,{cols:"2"},{default:v(()=>[h(re,{icon:"close",onClick:l[0]||(l[0]=u=>n.value=!1)})]),_:1})]),_:1})]),_:1},8,["modelValue","color","timeout"]))}}),Qw=Ms("Uploads",{state:()=>({queuedUploads:[],failedUploads:[],uploadingNow:!1}),getters:{hasPendingUploads(e){var t;return((t=e.queuedUploads)==null?void 0:t.length)>0},isUploadingNow(e){return e.uploadingNow},nextUpload(e){return e.queuedUploads[0]}},actions:{queueUploads(e){this.failedUploads=[],this.queuedUploads.push(...e)},cancelUploads(){this.queuedUploads=[],this.failedUploads=[]},async handleNextUpload(){var r;const e=Mt();if(!((r=this.queuedUploads)!=null&&r.length))return;this.uploadingNow=!0;const{file:t,printer:n}=this.nextUpload;this.queuedUploads.splice(0,1);try{await Oo.uploadFile(n,t)}catch(s){if(s.isAxiosError){const i={file:t,printer:n,error:s};this.failedUploads.push(i),e.openErrorMessage({title:"Upload failure",subtitle:`File ${t.name}Upload failed for to printer ${n.name}`})}else e.openErrorMessage({title:"Upload failure",subtitle:"Unknown upload error occurred"})}this.uploadingNow=!1}}}),tY="/img/OIG.JYDC2RaWdz7g9.jpg",ea=(e,t)=>{const n=e.__vccOpts||e;for(const[r,s]of t)n[r]=s;return n},nY=e=>Math.random()*e,rY={name:"GridLoader",props:{loading:{type:Boolean,default:!0},color:{type:String,default:"#000000"},size:{type:Number,default:15},margin:{type:String,default:"2px"},sizeUnit:{type:String,default:"px"}},methods:{random:nY,getWrapperStyle(){return{width:`${parseFloat(this.size)*3+parseFloat(this.margin)*6}${this.sizeUnit}`,fontSize:0}},getCircleStyle(e){const t=`grid ${e/100+.6}s ${e/100-.2}s infinite ease`;return{display:"inline-block",backgroundColor:this.color,width:`${this.size}${this.sizeUnit}`,height:`${this.size}${this.sizeUnit}`,margin:this.margin,borderRadius:"100%",animationFillMode:"both",animation:t}}}};function sY(e,t,n,r,s,i){return n.loading?($(),we("div",{key:0,style:ci(i.getWrapperStyle())},[($(),we(Re,null,Zt(9,o=>L("div",{key:o,style:ci(i.getCircleStyle(i.random(100)))},null,4)),64))],4)):ve("",!0)}const MO=ea(rY,[["render",sY]]);function DO(e){const t=dt();t.getOptions().enabled=e,console.warn("Sentry enabled:",e)}const LO=e=>new Promise(t=>setTimeout(t,e));class iY{constructor(){he(this,"printerStore",Nt());he(this,"floorStore",Xi());he(this,"printerStateStore",rr());he(this,"testPrinterStore",Uw());he(this,"snackbar",Mt())}socketState(){return M9()}async setupSocketConnection(){console.debug("Setting up socket.io client");const t=await zI(),n=ps();n.loadTokens(),I9(t,n.loginRequired?n.token:void 0),Qt==null||Qt.on("legacy-update",r=>this.onMessage(JSON.parse(r))),Qt==null||Qt.on("test-printer-state",r=>{this.testPrinterStore.saveEvent(r),console.log(r)})}disconnect(){O9()}reconnect(){Qt&&(console.debug("Resetting socket.io client connection"),A9())}onMessage(t){var n,r,s,i;((n=t.trackedUploads.current)!=null&&n.length||(r=t.trackedUploads.failed)!=null&&r.length)&&(console.debug("[SocketIO] trackedUploads message received"),t.trackedUploads.current.forEach(o=>{var a;this.snackbar.openProgressMessage(o.correlationToken,o.multerFile.originalname,(((a=o.progress)==null?void 0:a.percent)||0)*100,!1)})),(s=t.floors)!=null&&s.length&&this.floorStore.saveFloors(t.floors),(i=t.printers)!=null&&i.length&&this.printerStore.setPrinters(t.printers),t.socketStates&&this.printerStateStore.setSocketStates(t.socketStates),t.printerEvents&&this.printerStateStore.setPrinterEvents(t.printerEvents)}}const $O=de({color:String,...vs(),...Ve(),...$r(),...bs(),...Ko(),...Tu(),...Bn(),...bt(),...Dt()},"VSheet"),ap=xe()({name:"VSheet",props:$O(),setup(e,t){let{slots:n}=t;const{themeClasses:r}=Xt(e),{backgroundColorClasses:s,backgroundColorStyles:i}=pr(Te(e,"color")),{borderClasses:o}=Ls(e),{dimensionStyles:a}=Fr(e),{elevationClasses:l}=$s(e),{locationStyles:u}=tl(e),{positionClasses:d}=Ru(e),{roundedClasses:c}=qn(e);return Ie(()=>h(e.tag,{class:["v-sheet",r.value,s.value,o.value,l.value,d.value,c.value,e.class],style:[i.value,a.value,u.value,e.style]},n)),{}}}),oY={key:1,style:{margin:"50px"}},aY={class:"mt-2 mb-2"},lY={key:0,class:"mt-2 mb-2"},uY={key:1,class:"mt-2 mb-2"},cY={key:2,style:{animation:"fadeIn 0.75s"}},dY=Le({__name:"AppLoader",setup(e){const t=ps(),n=Bs(),r=Yi(),s=jw(),i=U(!1),o=Zo(),a=U(""),l=U(!0),u=U(),d=U(),c=U(),f=Mt(),p=new iY;function g(){window.location.reload()}function m(){navigator.clipboard.writeText(JSON.stringify(u.value)),f.openInfoMessage({title:"Copied",subtitle:"Error copied to clipboard"})}function y(C,k=""){C?(a.value=k,u.value=null,d.value=null,c.value=null):a.value="",i.value=C}async function b(){var C;try{await n.loadSettings(),await r.loadFeatures(),await s.getProfile();const k=(C=n.serverSettings)==null?void 0:C.sentryDiagnosticsEnabled;DO(!!k)}catch(k){console.log("Error when loading settings.",k),f.openErrorMessage({title:"Error",subtitle:"Error when loading settings, features and/or profile."}),li(k)}p.socketState().setup?p.reconnect():await p.setupSocketConnection(),y(!1)}return qr("auth:permission-denied").on(async C=>{console.log("[AppLoader] Permission denied, going to permission denied page"),y(!0,"Permission denied"),await o.push({name:qt.PermissionDenied,query:{roles:C==null?void 0:C.roles,page:String(o.currentRoute.value.name),permissions:C==null?void 0:C.permissions,error:C==null?void 0:C.error,url:C==null?void 0:C.url}}),y(!1)}),qr("auth:failure").on(async C=>{console.debug(`[AppLoader] Event received: 'auth:failure', going back to login, context: ${C}`),y(!0,"Authentication failed, going back to login"),o.currentRoute.value.name!==qt.Login&&await o.push({name:qt.Login}),y(!1)}),qr("auth:login").on(async()=>{console.debug("[AppLoader] Event received: 'auth:login', loading app"),y(!0,"Loading app"),await b()}),qr(`auth:${Er.AccountNotVerified}`).on(async()=>{console.debug(`[AppLoader] Event received: 'auth:${Er.AccountNotVerified}', going to login`),f.error("Account not verified, please ask an administrator to verify your account."),y(!0,"Account not verified, please ask an administrator to verify your account."),o.currentRoute.value.name!==qt.Login&&await o.push({name:qt.Login}),y(!1)}),qr(`auth:${Er.PasswordChangeRequired}`).on(async()=>{console.debug(`[AppLoader] Event received: 'auth:${Er.PasswordChangeRequired}', going to login`),f.error("Password change required, please change your password."),y(!0,"Password change required, please change your password."),o.currentRoute.value.name!==qt.Login&&await o.push({name:qt.Login}),y(!1)}),Op(()=>{p&&p.disconnect()}),Ap(async()=>{var M,O;l.value=!0;const C=["Loading FDM Monster","Loading it all","Loading features","Loading what needs to be loaded","Farming potatoes","Wiping the floor","Cleaning cobwebs","Loading filament.dll","Loading 3D_printer.exe","Loading spools"],k=C[Math.floor(Math.random()*C.length)];y(!0,k);try{await ko.test()}catch(A){l.value=!1,u.value=A,d.value="api/test",li(A);return}const{loginRequired:x,wizardState:I}=await t.checkAuthenticationRequirements();if(!I.wizardCompleted){console.debug("[AppLoader] Wizard not completed, going to wizard"),await t.logout(!1),o.currentRoute.value.name!==qt.FirstTimeSetup&&await o.replace({name:qt.FirstTimeSetup}),y(!1);return}if(!x)return console.debug("[AppLoader] Login not required, loading app"),await b();if(console.debug("[AppLoader] Checking if tokens are present"),!t.hasAuthToken&&!t.hasRefreshToken)return console.debug("[AppLoader] No tokens present, hiding overlay as router will have handled it"),y(!1);y(!0,"Refreshing login"),console.debug("[AppLoader] Verifying or refreshing login once");try{const{success:A,handled:D}=await t.verifyOrRefreshLoginOnceOrLogout();if(D){console.debug("[AppLoader] received handled event, hiding overlay");return}if(!A){console.debug("[AppLoader] No success refreshing"),y(!0,"Login expired, going back to login"),await LO(500),o.currentRoute.value.name!==qt.Login&&await o.push({name:qt.Login}),y(!1);return}}catch(A){console.log("[AppLoader] Error when refreshing login",A),l.value=!1,u.value=A.message,d.value=(M=A.config)==null?void 0:M.url,c.value=(O=A.response)==null?void 0:O.data,li(A);return}console.debug("[AppLoader] Loading app"),await b()}),(C,k)=>($(),we(Re,null,[h(Ni,{modelValue:i.value,"onUpdate:modelValue":k[2]||(k[2]=x=>i.value=x),opacity:"0.98",style:{"z-index":"7"}},{default:v(()=>[l.value?($(),Q(MO,{key:0,size:20,class:"ma-auto",color:"#a70015"})):ve("",!0),k[19]||(k[19]=L("br",null,null,-1)),u.value?($(),we("div",oY,[k[16]||(k[16]=L("h1",null,"FDM Monster Server Error",-1)),k[17]||(k[17]=L("p",null," Did not expect this answer from the server. Please check your configuration and logs. ",-1)),h(ap,{class:"pa-4 rounded",color:"grey-darken-2",width:"80%"},{default:v(()=>[k[11]||(k[11]=_(" Details: ")),L("div",aY,ae(JSON.stringify(u.value,null,4)),1),d.value?($(),we("div",lY," Original URL: "+ae(d.value),1)):ve("",!0),c.value?($(),we("div",uY," Response body: "+ae(c.value),1)):ve("",!0),k[12]||(k[12]=L("br",null,null,-1)),h(re,{class:"mb-2",color:"secondary",onClick:k[0]||(k[0]=x=>m())},{default:v(()=>[h(X,{class:"mr-2"},{default:v(()=>k[3]||(k[3]=[_("content_copy")])),_:1}),k[4]||(k[4]=_(" Copy error details "))]),_:1}),k[13]||(k[13]=L("br",null,null,-1)),h(re,{color:"primary mb-2",onClick:k[1]||(k[1]=x=>g())},{default:v(()=>[h(X,{class:"mr-2"},{default:v(()=>k[5]||(k[5]=[_("refresh")])),_:1}),k[6]||(k[6]=_(" reload the page "))]),_:1}),k[14]||(k[14]=L("br",null,null,-1)),h(re,{color:"darken-2 mb-2",href:"https://docs.fdm-monster.net",style:{color:"white"},target:"_blank"},{default:v(()=>[h(X,{class:"mr-2"},{default:v(()=>k[7]||(k[7]=[_("menu_book")])),_:1}),k[8]||(k[8]=_(" view documentation "))]),_:1}),k[15]||(k[15]=L("br",null,null,-1)),h(re,{color:"purple-darken-4",href:"https://discord.gg/mwA8uP8CMc",style:{color:"white"},target:"_blank"},{default:v(()=>[h(X,{class:"mr-2"},{default:v(()=>k[9]||(k[9]=[_("chat")])),_:1}),k[10]||(k[10]=_(" join our Discord "))]),_:1})]),_:1}),k[18]||(k[18]=L("img",{class:"justify-center align-center align-content-center rounded-pill mt-8 ma-4",src:tY,style:{opacity:"0.9"},width:"400"},null,-1))])):ve("",!0),l.value?($(),we("div",cY,ae(a.value),1)):ve("",!0)]),_:1},8,["modelValue"]),i.value?ve("",!0):Mp(C.$slots,"default",{key:0})],64))}});async function fY(){const e="vpss",t=document.getElementById(e),n=document.getElementById(`${e}-style`);if(!t||!n){console.error("Splash screen not found. Did you forget to add the `vite-plugin-splash-screen` plugin?");return}const r=window.__VPSS__||{};if(t.addEventListener("animationend",s=>{s.animationName==="vpss-hide"&&(t.remove(),n.remove())}),"minDurationMs"in r&&"renderedAt"in r){const s=new Date().getTime()-r.renderedAt,i=Math.max(r.minDurationMs-s,0);await new Promise(o=>setTimeout(o,i))}t.classList.add(`${e}-hidden`)}const hY=de({...Ve(),...TA({fullHeight:!0}),...Dt()},"VApp"),pY=xe()({name:"VApp",props:hY(),setup(e,t){let{slots:n}=t;const r=Xt(e),{layoutClasses:s,getLayoutItem:i,items:o,layoutRef:a}=OA(e),{rtlClasses:l}=Nr();return Ie(()=>{var u;return h("div",{ref:a,class:["v-application",r.themeClasses.value,s.value,l.value,e.class],style:[e.style]},[h("div",{class:"v-application__wrap"},[(u=n.default)==null?void 0:u.call(n)])])}),{getLayoutItem:i,items:o,theme:r}}}),mY=de({scrollable:Boolean,...Ve(),...$r(),...bt({tag:"main"})},"VMain"),gY=xe()({name:"VMain",props:mY(),setup(e,t){let{slots:n}=t;const{dimensionStyles:r}=Fr(e),{mainStyles:s}=IA(),{ssrBootStyles:i}=qd();return Ie(()=>h(e.tag,{class:["v-main",{"v-main--scrollable":e.scrollable},e.class],style:[s.value,i.value,r.value,e.style]},{default:()=>{var o,a;return[e.scrollable?h("div",{class:"v-main__scroller"},[(o=n.default)==null?void 0:o.call(n)]):(a=n.default)==null?void 0:a.call(n)]}})),{}}}),vY=Le({__name:"App",setup(e){const t=Qw(),n=ps(),r=t.queuedUploads;return Ce(r,async()=>{await t.handleNextUpload()}),St(()=>{fY(),console.debug(`App.vue mounted. Logged in: ${n.hasAuthToken}, Expired: ${n.isLoginExpired}`)}),(s,i)=>{const o=eY,a=Q9,l=K9,u=z9,d=H9,c=Pr("router-view"),f=E7,p=h7,g=LG,m=MG,y=IG,b=CG,w=dG,S=cG,P=J6,E=TW,T=Wq;return $(),Q(pY,null,{default:v(()=>[h(o),h(a),h(l),ie(n).hasAuthToken&&!ie(n).isLoginExpired||!ie(n).loginRequired?($(),Q(u,{key:0})):ve("",!0),ie(n).hasAuthToken&&!ie(n).isLoginExpired||!ie(n).loginRequired?($(),Q(d,{key:1})):ve("",!0),h(dY,null,{default:v(()=>[h(gY,null,{default:v(()=>[h(c)]),_:1})]),_:1}),h(f),h(p),h(g),h(m),h(y),h(b),h(w),h(S),h(P),h(E),h(T)]),_:1})}}}),Jw="/img/logo.svg";class FO extends yr{static async postQuickStopM112Command(t){const n=Oe.sendQuickStopM112Route(t);return await this.post(n)}}const km=Ms("GridStore",{state:()=>({gridEditMode:!1})}),yY={class:"small-resized-font"},bY={key:0,class:"float-right d-none d-xl-inline"},wY={key:1,class:"float-end"},SY={class:"pl-5 pr-5",color:"primary"},_Y={key:0},kY={key:1},xY={key:2},EY={class:"xsmall-resized-font"},Lk="rgba(100,100,100,0.1)",CY=Le({__name:"PrinterGridTile",props:{printer:{type:Object,required:!1},x:{type:Number,required:!0},y:{type:Number,required:!0}},setup(e){const t=e,n=Nt(),r=rr(),s=Xi(),i=Yi(),o=Bs(),a=km(),l=Fn(Jt.PrinterControlDialog),u=Fn(Jt.AddOrUpdatePrinterDialog),d=Mt(),c=R(()=>{var O;return(O=t.printer)==null?void 0:O.id}),f=R(()=>c.value?n.isSelectedPrinter(c.value):!1),p=R(()=>{var O;return((O=n.selectedPrinters)==null?void 0:O.length)&&!f.value}),g=R(()=>i.hasFeature("printerControlApi")),m=R(()=>o.largeTiles),y=R(()=>{if(!c.value)return;const O=n.printer(c.value);if(!O)return;const A=r.printerEventsById[c.value],D=r.socketStatesById[c.value];return jI(O,D,A)}),b=R(()=>{const O=y.value;return O&&O.rgb||Lk}),w=R(()=>{if(c.value)return r.printerJobsById[c.value]}),S=R(()=>{if(c.value)return r.printingFilePathsByPrinterId[c.value]}),P=()=>{n.setSideNavPrinter(t.printer)},E=async()=>{c.value&&(await Wt.refreshSocket(c.value),d.openInfoMessage({title:"Refreshing OctoPrint connection state"}))},T=()=>{t.printer&&Wt.openPrinterURL(t.printer.printerURL)},C=()=>{n.setUpdateDialogPrinter(t.printer),u.openDialog()},k=async()=>{if(!c.value)throw new Error("PrinterId not set, cant open dialog");await l.openDialog({printerId:c})},x=async()=>{c.value&&confirm("Are you sure to abort the print in Quick Stop mode? Please reconnect after.")&&await FO.postQuickStopM112Command(c.value)},I=async()=>{c.value&&await Wt.sendPrinterConnectCommand(c.value)},M=async()=>{var O;if(!(!t.printer||!c.value)){if(a.gridEditMode){const A=(O=s.selectedFloor)==null?void 0:O.id;if(!A)throw new Error("Cant clear printer, floor not selected");await as.deletePrinterFromFloor(A,c.value);return}n.toggleSelectedPrinter(t.printer)}};return(O,A)=>{const D=mr("drop-upload"),V=mr("drop-printer-position");return en(($(),we("div",null,[en(($(),Q(yt,{class:Ja([{"tile-large":m.value,"tile-selected":f.value,"tile-unselected":p.value,"tile-setup":e.printer},"tile"]),disabled:!e.printer,style:ci({"background-color":!ie(a).gridEditMode||!e.printer?b.value:"rgba(1,1,1,0)"}),variant:"outlined",tile:"",onClick:A[10]||(A[10]=H=>M())},{default:v(()=>{var H,G,j,B;return[(H=y.value)!=null&&H.text.includes("API")?($(),Q(X,{key:0,color:"primary",size:"70",style:{opacity:"0.2",position:"absolute",top:"5%",right:"10%"}},{default:v(()=>A[11]||(A[11]=[_(" wifi_off ")])),_:1})):ve("",!0),(G=y.value)!=null&&G.text.includes("USB")?($(),Q(X,{key:1,color:"primary",size:"70",style:{opacity:"0.2",position:"absolute",top:"5%",right:"10%"}},{default:v(()=>A[12]||(A[12]=[_(" usb_off ")])),_:1})):ve("",!0),(j=e.printer)!=null&&j.id?($(),Q(Pn,{key:2,class:"tile-inner fill-height"},{default:v(()=>{var W,Z,q,K,pe,ue;return[L("small",yY,ae((W=e.printer)==null?void 0:W.name),1),h(Wd,{"offset-y":""},{activator:v(({props:le})=>[h(re,me({class:"float-right d-inline d-xl-none"},le),{default:v(()=>[h(X,null,{default:v(()=>A[13]||(A[13]=[_("more_vert")])),_:1})]),_:2},1040)]),default:v(()=>[h(Kt,null,{default:v(()=>[h(Fe,{"close-on-click":!0,onClick:A[0]||(A[0]=le=>P())},{default:v(()=>[h(X,null,{default:v(()=>A[14]||(A[14]=[_("info")])),_:1}),A[15]||(A[15]=_("  Details "))]),_:1}),g.value?($(),Q(Fe,{key:0,"close-on-click":!0,onClick:A[1]||(A[1]=le=>k())},{default:v(()=>[h(X,null,{default:v(()=>A[16]||(A[16]=[_("open_with")])),_:1}),A[17]||(A[17]=_("  Control "))]),_:1})):ve("",!0),h(Fe,{"close-on-click":!0,onClick:A[2]||(A[2]=le=>T())},{default:v(()=>[h(X,null,{default:v(()=>A[18]||(A[18]=[_("directions")])),_:1}),A[19]||(A[19]=_("  Visit OctoPrint "))]),_:1}),h(Fe,{"close-on-click":!0,onClick:A[3]||(A[3]=le=>C())},{default:v(()=>[h(X,null,{default:v(()=>A[20]||(A[20]=[_("settings")])),_:1}),A[21]||(A[21]=_("  Edit Printer "))]),_:1}),h(Fe,{"close-on-click":!0,onClick:A[4]||(A[4]=le=>x())},{default:v(()=>[h(X,null,{default:v(()=>A[22]||(A[22]=[_("stop")])),_:1}),A[23]||(A[23]=_("  Quick stop "))]),_:1})]),_:1})]),_:1}),ie(a).gridEditMode?($(),we("div",wY,[L("strong",SY,[h(X,null,{default:v(()=>A[32]||(A[32]=[_("disabled_visible")])),_:1}),A[33]||(A[33]=_(" Click to clear "))])])):($(),we("div",bY,[!ie(r).isPrinterOperational((Z=e.printer)==null?void 0:Z.id)&&ie(r).isApiResponding((q=e.printer)==null?void 0:q.id)?($(),Q(re,{key:0,onClick:A[5]||(A[5]=$t(le=>I(),["prevent","stop"]))},{default:v(()=>[h(X,null,{default:v(()=>A[24]||(A[24]=[_("usb")])),_:1})]),_:1})):ve("",!0),g.value&&ie(r).isPrinterOperational((K=e.printer)==null?void 0:K.id)?($(),Q(xt,{key:1,location:"bottom"},{activator:v(({props:le})=>[h(re,me({elevation:"4",size:"36"},le,{onClick:A[6]||(A[6]=$t(J=>k(),["prevent","stop"]))}),{default:v(()=>[h(X,null,{default:v(()=>A[25]||(A[25]=[_("open_with")])),_:1})]),_:2},1040)]),default:v(()=>A[26]||(A[26]=[L("span",null," Control your printer head or extruder. ",-1)])),_:1})):ve("",!0),ie(r).isPrinterOperational((pe=e.printer)==null?void 0:pe.id)?($(),Q(xt,{key:2,location:"bottom"},{activator:v(({props:le})=>[h(re,me({elevation:"4",size:"36"},le,{onClick:A[7]||(A[7]=$t(J=>x(),["prevent","stop"]))}),{default:v(()=>[h(X,null,{default:v(()=>A[27]||(A[27]=[_("dangerous")])),_:1})]),_:2},1040)]),default:v(()=>A[28]||(A[28]=[L("span",null," Send a quick stop, causing USB to be disconnected. ",-1)])),_:1})):ve("",!0),e.printer.enabled&&ie(r).isPrinterNotOnline(e.printer.id)?($(),Q(xt,{key:3,location:"bottom"},{activator:v(({props:le})=>[h(re,me({elevation:"4",size:"36"},le,{onClick:A[8]||(A[8]=$t(J=>E(),["prevent","stop"]))}),{default:v(()=>[h(X,null,{default:v(()=>A[29]||(A[29]=[_("autorenew")])),_:1})]),_:2},1040)]),default:v(()=>A[30]||(A[30]=[L("span",null," Retry connecting to OctoPrint API ",-1)])),_:1})):ve("",!0),h(re,{elevation:"5",onClick:A[9]||(A[9]=$t(le=>P(),["prevent","stop"]))},{default:v(()=>[h(X,null,{default:v(()=>A[31]||(A[31]=[_("menu_open")])),_:1})]),_:1})])),A[39]||(A[39]=L("br",null,null,-1)),h(xt,{disabled:!((ue=e.printer)!=null&&ue.disabledReason),"close-delay":"100",color:"danger","open-delay":"0",location:"top"},{activator:v(({props:le})=>{var J,be,Se;return[L("small",me({class:"xsmall-resized-font text--secondary d-lg-inline d-none"},le),[(J=e.printer)!=null&&J.disabledReason?($(),we("span",_Y,[A[35]||(A[35]=L("small",null," MAINTENANCE ",-1)),h(X,{class:"d-none d-xl-inline",color:"primary",size:"small"},{default:v(()=>A[34]||(A[34]=[_(" info ")])),_:1})])):($(),we("span",kY,[L("small",null,ae((Se=(be=y.value)==null?void 0:be.text)==null?void 0:Se.toUpperCase()),1)]))],16)]}),default:v(()=>[A[36]||(A[36]=_(" Maintenance reason: ")),A[37]||(A[37]=L("br",null,null,-1)),_(" "+ae(e.printer.disabledReason),1)]),_:1},8,["disabled"]),m.value&&S.value?($(),we("small",xY,[A[38]||(A[38]=L("strong",null," File: ",-1)),_(" "+ae(S.value),1)])):ve("",!0)]}),_:1})):ie(a).gridEditMode?($(),Q(Pn,{key:3},{default:v(()=>[h(X,{size:"48"},{default:v(()=>A[40]||(A[40]=[_("add")])),_:1}),A[41]||(A[41]=_(" Place printer "))]),_:1})):ve("",!0),(B=w.value)!=null&&B.progress?($(),Q(lu,{key:4,"model-value":w.value.progress.completion,absolute:"",bottom:"",color:"green",height:"13"},{default:v(()=>{var W,Z,q,K,pe;return[L("span",EY,ae(m.value?(Z=(W=w.value)==null?void 0:W.progress)!=null&&Z.completion?((pe=(K=(q=w.value)==null?void 0:q.progress)==null?void 0:K.completion)==null?void 0:pe.toFixed(1))+"%":"-":S.value),1)]}),_:1},8,["model-value"])):ve("",!0)]}),_:1},8,["class","disabled","style"])),[[D,{printers:[e.printer]}]])])),[[V,{x:e.x,y:e.y,printerSet:e.printer}]])}}}),NO="FDM-Monster-Client-Vue2";var BO=(e=>(e.PRINTER_PLACE="PRINTER_PLACE",e))(BO||{});function PY(e){var t,n;return!((t=e==null?void 0:e.appId)!=null&&t.length)||!((n=e==null?void 0:e.intent)!=null&&n.length)?!1:e.appId===NO&&e.intent==="PRINTER_PLACE"}const TY=de({color:String,density:String,...Ve()},"VBannerActions"),RY=xe()({name:"VBannerActions",props:TY(),setup(e,t){let{slots:n}=t;return Dr({VBtn:{color:e.color,density:e.density,slim:!0,variant:"text"}}),Ie(()=>{var r;return h("div",{class:["v-banner-actions",e.class],style:e.style},[(r=n.default)==null?void 0:r.call(n)])}),{}}}),IY=Eu("v-banner-text"),AY=de({avatar:String,bgColor:String,color:String,icon:Je,lines:String,stacked:Boolean,sticky:Boolean,text:String,...vs(),...Ve(),...Lr(),...$r(),...nl({mobile:null}),...bs(),...Ko(),...Tu(),...Bn(),...bt(),...Dt()},"VBanner"),VO=xe()({name:"VBanner",props:AY(),setup(e,t){let{slots:n}=t;const{backgroundColorClasses:r,backgroundColorStyles:s}=pr(e,"bgColor"),{borderClasses:i}=Ls(e),{densityClasses:o}=ys(e),{displayClasses:a,mobile:l}=mi(e),{dimensionStyles:u}=Fr(e),{elevationClasses:d}=$s(e),{locationStyles:c}=tl(e),{positionClasses:f}=Ru(e),{roundedClasses:p}=qn(e),{themeClasses:g}=Xt(e),m=Te(e,"color"),y=Te(e,"density");Dr({VBannerActions:{color:m,density:y}}),Ie(()=>{const b=!!(e.text||n.text),w=!!(e.avatar||e.icon),S=!!(w||n.prepend);return h(e.tag,{class:["v-banner",{"v-banner--stacked":e.stacked||l.value,"v-banner--sticky":e.sticky,[`v-banner--${e.lines}-line`]:!!e.lines},g.value,r.value,i.value,o.value,a.value,d.value,f.value,p.value,e.class],style:[s.value,u.value,c.value,e.style],role:"banner"},{default:()=>{var P;return[S&&h("div",{key:"prepend",class:"v-banner__prepend"},[n.prepend?h(At,{key:"prepend-defaults",disabled:!w,defaults:{VAvatar:{color:m.value,density:y.value,icon:e.icon,image:e.avatar}}},n.prepend):h(lt,{key:"prepend-avatar",color:m.value,density:y.value,icon:e.icon,image:e.avatar},null)]),h("div",{class:"v-banner__content"},[b&&h(IY,{key:"text"},{default:()=>{var E;return[((E=n.text)==null?void 0:E.call(n))??e.text]}}),(P=n.default)==null?void 0:P.call(n)]),n.actions&&h(RY,{key:"actions"},n.actions)]}})})}}),OY={class:"printer-grid-container"},MY=Le({__name:"PrinterGrid",props:{gap:{type:String,default:"4px"}},setup(e){const t=Nt(),n=Xi(),r=Bs(),s=km();St(async()=>{await t.loadPrinters(),await n.loadFloors()});const i=e,o=R(()=>n.gridSortedPrinters),a=R(()=>r.gridCols),l=R(()=>r.gridRows),u=R(()=>l.value*a.value),d=R(()=>({display:"grid",gridTemplateColumns:`repeat(${a.value}, 1fr)`,gap:i.gap})),c=m=>m%a.value,f=m=>Math.floor(m/a.value);function p(m,y){y.dataTransfer&&m.id&&y.dataTransfer.setData("text",JSON.stringify({appId:NO,intent:BO.PRINTER_PLACE,printerId:m.id}))}function g(m,y){var S;const b=m,w=y;if(!(!((S=o.value)!=null&&S.length)||!o.value[b]))return o.value[b][w]}return(m,y)=>($(),we("div",null,[ie(s).gridEditMode?($(),Q(VO,{key:0},{default:v(()=>[h(at,{style:{"margin-bottom":"-5px"}},{default:v(()=>[h(Ue,null,{default:v(()=>[L("span",null," Drag "+ae(ie(n).floorlessPrinters.length)+" unplaced printer(s) from here to place it on the grid. ",1),h(np,null,{default:v(()=>[($(!0),we(Re,null,Zt(ie(n).floorlessPrinters,b=>($(),Q(kn,{key:b.id,draggable:"",size:"small",style:{cursor:"move"},onDragstart:w=>p(b,w)},{default:v(()=>[_(ae(b.name),1)]),_:2},1032,["onDragstart"]))),128))]),_:1})]),_:1}),h(Ue,null,{default:v(()=>[L("div",null,[y[2]||(y[2]=_(" Clear printers by clicking on ")),L("strong",null,[h(X,null,{default:v(()=>y[0]||(y[0]=[_("disabled_visible")])),_:1}),y[1]||(y[1]=_(" Click to clear "))])])]),_:1})]),_:1})]),_:1})):ve("",!0),L("div",OY,[L("div",{class:"printer-grid",style:ci(d.value)},[($(!0),we(Re,null,Zt(u.value,b=>($(),we("div",{key:`printer-${c(b-1)}-${f(b-1)}`,class:"printer-cell"},[h(CY,{printer:g(c(b-1),f(b-1)),x:c(b-1),y:f(b-1)},null,8,["printer","x","y"])]))),128))],4)]),y[3]||(y[3]=L("img",{alt:"FDM Monster Background",class:"grid-bg-img align-content-center",src:Jw,style:{opacity:"0.08","pointer-events":"none"}},null,-1))]))}}),DY=ea(MY,[["__scopeId","data-v-f4e959e4"]]);function LY(e,t){return e?t.map(n=>({file:n,printer:e})):[]}function UO(e,t){return!(e!=null&&e.length)||!t?[]:e.map(n=>({file:t,printer:n}))}const $Y=de({indeterminate:Boolean,inset:Boolean,flat:Boolean,loading:{type:[Boolean,String],default:!1},...ol(),...vm()},"VSwitch"),lp=xe()({name:"VSwitch",inheritAttrs:!1,props:$Y(),emits:{"update:focused":e=>!0,"update:modelValue":e=>!0,"update:indeterminate":e=>!0},setup(e,t){let{attrs:n,slots:r}=t;const s=st(e,"indeterminate"),i=st(e,"modelValue"),{loaderClasses:o}=Ad(e),{isFocused:a,focus:l,blur:u}=Uu(e),d=U(),c=kt&&window.matchMedia("(forced-colors: active)").matches,f=R(()=>typeof e.loading=="string"&&e.loading!==""?e.loading:e.color),p=vr(),g=R(()=>e.id||`switch-${p}`);function m(){s.value&&(s.value=!1)}function y(b){var w,S;b.stopPropagation(),b.preventDefault(),(S=(w=d.value)==null?void 0:w.input)==null||S.click()}return Ie(()=>{const[b,w]=Za(n),S=gs.filterProps(e),P=Ga.filterProps(e);return h(gs,me({class:["v-switch",{"v-switch--flat":e.flat},{"v-switch--inset":e.inset},{"v-switch--indeterminate":s.value},o.value,e.class]},b,S,{modelValue:i.value,"onUpdate:modelValue":E=>i.value=E,id:g.value,focused:a.value,style:e.style}),{...r,default:E=>{let{id:T,messagesId:C,isDisabled:k,isReadonly:x,isValid:I}=E;const M={model:i,isValid:I};return h(Ga,me({ref:d},P,{modelValue:i.value,"onUpdate:modelValue":[O=>i.value=O,m],id:T.value,"aria-describedby":C.value,type:"checkbox","aria-checked":s.value?"mixed":void 0,disabled:k.value,readonly:x.value,onFocus:l,onBlur:u},w),{...r,default:O=>{let{backgroundColorClasses:A,backgroundColorStyles:D}=O;return h("div",{class:["v-switch__track",c?void 0:A.value],style:D.value,onClick:y},[r["track-true"]&&h("div",{key:"prepend",class:"v-switch__track-true"},[r["track-true"](M)]),r["track-false"]&&h("div",{key:"append",class:"v-switch__track-false"},[r["track-false"](M)])])},input:O=>{let{inputNode:A,icon:D,backgroundColorClasses:V,backgroundColorStyles:H}=O;return h(Re,null,[A,h("div",{class:["v-switch__thumb",{"v-switch__thumb--filled":D||e.loading},e.inset||c?void 0:V.value],style:e.inset?void 0:H.value},[r.thumb?h(At,{defaults:{VIcon:{icon:D,size:"x-small"}}},{default:()=>[r.thumb({...M,icon:D})]}):h(EN,null,{default:()=>[e.loading?h(Vp,{name:"v-switch",active:!0,color:I.value===!1?void 0:f.value},{default:G=>r.loader?r.loader(G):h(Id,{active:G.isActive,color:G.color,indeterminate:!0,size:"16",width:"2"},null)}):D&&h(X,{key:String(D),icon:D,size:"x-small"},null)]})])])}})}})}),{}}}),FY={class:"d-flex flex-wrap gap-2"},NY={class:"pr-2"},BY={class:"pr-2"},VY={class:"pr-2"},UY={class:"pr-2"},HY={class:"pr-2"},zY={class:"ma-4 pt-6"},jY=Le({__name:"HomeToolbar",setup(e){const t=Nt(),n=rr(),r=Xi(),s=km(),i=U(0),o=R(()=>r.floors);function a(l){r.changeSelectedFloorByIndex(l),i.value=l}return(l,u)=>($(),Q(sr,{flat:""},{default:v(()=>{var d;return[h(mn,null,{default:v(()=>u[2]||(u[2]=[_(" Floors ")])),_:1}),h(AP,{"model-value":i.value,class:"ml-7",mandatory:"",rounded:"","onUpdate:modelValue":a},{default:v(()=>[($(!0),we(Re,null,Zt(o.value,c=>($(),Q(re,{key:c.id},{default:v(()=>[h(X,null,{default:v(()=>u[3]||(u[3]=[_("format_align_left")])),_:1}),_(" "+ae(c.name),1)]),_:2},1024))),128))]),_:1},8,["model-value"]),(d=ie(t).printers)!=null&&d.length?ve("",!0):($(),Q(re,{key:0,class:"mt-0 ml-6",color:"primary",to:"/printers"},{default:v(()=>u[4]||(u[4]=[_(" You have no printers. Click here to start! ")])),_:1})),ie(r).floorlessPrinters.length?($(),Q(un,{key:1,class:"mt-4 ml-12",color:"primary"},{default:v(()=>[h(X,null,{default:v(()=>u[5]||(u[5]=[_("warning")])),_:1}),_(" "+ae(ie(r).floorlessPrinters.length)+" unplaced printer(s)! ",1)]),_:1})):ve("",!0),h(wn),L("span",FY,[L("span",NY,[h(X,null,{default:v(()=>u[6]||(u[6]=[_("print")])),_:1}),_(" "+ae(ie(n).printingCount),1)]),L("span",BY,[h(X,null,{default:v(()=>u[7]||(u[7]=[_("ac_unit")])),_:1}),_(" "+ae(ie(n).operationalNotPrintingCount),1)]),L("span",VY,[h(X,null,{default:v(()=>u[8]||(u[8]=[_("handyman")])),_:1}),_(" "+ae(ie(t).maintenanceCount),1)]),L("span",UY,[h(X,null,{default:v(()=>u[9]||(u[9]=[_("usb_off")])),_:1}),_(" "+ae(ie(t).disconnectedCount),1)]),L("span",HY,[h(X,null,{default:v(()=>u[10]||(u[10]=[_("print_disabled")])),_:1}),_(" "+ae(ie(t).disabledCount),1)])]),h(re,{elevation:"2",color:"primary",small:"",class:"ml-6",icon:"",onClick:u[0]||(u[0]=c=>ie(Fn)(ie(Jt).GridSettingsDialog).openDialog())},{default:v(()=>[h(X,null,{default:v(()=>u[11]||(u[11]=[_("settings")])),_:1})]),_:1}),L("div",zY,[h(lp,{modelValue:ie(s).gridEditMode,"onUpdate:modelValue":u[1]||(u[1]=c=>ie(s).gridEditMode=c),label:"Printer Relocate Mode"},null,8,["modelValue"])])]}),_:1}))}}),qY={class:"pl-1"},WY=Le({__name:"PrinterGridView",setup(e){const t=km(),n=Nt(),r=rr(),s=Qw(),i=Yi(),o=Mt(),a=U(void 0),l=R(()=>i.hasFeature("batchReprintCalls")),u=R(()=>n.selectedPrinters.length>0),d=R(()=>n.selectedPrinters),c=U(null),f=()=>{c.value&&(c.value.value="",a.value=void 0)},p=()=>{n.clearSelectedPrinters()},g=async()=>{var P;const S=await Fn(Jt.BatchReprintDialog).handleAsync((P=n.selectedPrinters)==null?void 0:P.map(E=>E.id));console.log("[PrinterGridView] Dialog completed",S)},m=()=>{const S=d.value,P=S.filter(C=>r.isApiResponding(C.id));if(!a.value)return;const E=S.length-P.length;E>0&&o.openInfoMessage({title:`${E} printers inaccessible`,subtitle:"These were skipped from uploading."});const T=UO(P,a.value);s.queueUploads(T),c.value&&(c.value.value=""),p()},y=()=>{c.value&&c.value.files?a.value=c.value.files[0]:a.value=void 0},b=S=>{n.toggleSelectedPrinter(S)},w=S=>{Wt.openPrinterURL(S.printerURL)};return(S,P)=>{const E=mr("drop-upload");return $(),we("div",null,[h(jY),ie(t).gridEditMode?ve("",!0):en(($(),Q(VO,{key:0},{default:v(()=>[h(at,{style:{"margin-bottom":"-5px"}},{default:v(()=>[h(Ue,{style:{padding:"5px 0 0 15px"}},{default:v(()=>[h(np,{class:"d-inline-block"},{default:v(()=>[d.value.length===0?($(),Q(kn,{key:0,size:"small"},{default:v(()=>P[6]||(P[6]=[_(" No selected printers ")])),_:1})):ve("",!0),($(!0),we(Re,null,Zt(d.value,T=>($(),Q(kn,{key:T.id,closable:"",color:"primary",size:"small",onClick:C=>w(T),"onClick:close":C=>b(T)},{default:v(()=>[_(ae(T.name),1)]),_:2},1032,["onClick","onClick:close"]))),128))]),_:1})]),_:1}),h(Ue,{align:"right",style:{padding:"0"}},{default:v(()=>[a.value?($(),Q(np,{key:0,class:"float-end"},{default:v(()=>[h(kn,{closable:"","onClick:close":P[0]||(P[0]=T=>f())},{default:v(()=>[_(ae(a.value.name)+" ",1),L("strong",qY,ae(ie(SA)(a.value.size)),1)]),_:1})]),_:1})):ve("",!0),P[12]||(P[12]=L("br",null,null,-1)),l.value?($(),Q(re,{key:1,disabled:!u.value,color:"primary",size:"x-small",onClick:P[1]||(P[1]=T=>g())},{default:v(()=>[h(X,{class:"pr-2",size:"small"},{default:v(()=>P[7]||(P[7]=[_(" refresh ")])),_:1}),P[8]||(P[8]=_(" Batch reprint "))]),_:1},8,["disabled"])):ve("",!0),h(re,{color:u.value?"primary":"secondary",class:"ml-2",size:"x-small",onClick:P[2]||(P[2]=T=>p())},{default:v(()=>[h(X,{class:"pr-2",size:"small"},{default:v(()=>P[9]||(P[9]=[_(" delete ")])),_:1}),_(" Clear all ("+ae(d.value.length)+") ",1)]),_:1},8,["color"]),h(re,{class:"ml-2",color:"primary",size:"x-small",onClick:P[3]||(P[3]=T=>{var C;return(C=S.$refs.fileUpload)==null?void 0:C.click()})},{default:v(()=>P[10]||(P[10]=[_(" Select gcode file ")])),_:1}),h(re,{disabled:!a.value,class:"ml-2 mr-5",color:"green",size:"x-small",onClick:P[4]||(P[4]=T=>m())},{default:v(()=>P[11]||(P[11]=[_(" Upload gcode file ")])),_:1},8,["disabled"]),L("input",{ref_key:"fileUpload",ref:c,multiple:!1,accept:".gcode",style:{display:"none"},type:"file",onChange:P[5]||(P[5]=T=>y())},null,544)]),_:1})]),_:1})]),_:1})),[[E,{printers:d.value}]]),h(DY,{class:"ma-2"})])}}}),GY=Le({name:"RefreshFilesAction",components:{},props:{printer:Object},setup:()=>({printersStore:Nt()}),methods:{async getFiles(){this.printer&&await this.printersStore.loadPrinterFiles(this.printer.id)}}});function KY(e,t,n,r,s,i){return $(),Q(re,{color:"secondary",onClick:t[0]||(t[0]=o=>e.getFiles())},{default:v(()=>[h(X,null,{default:v(()=>t[1]||(t[1]=[_("refresh")])),_:1}),t[2]||(t[2]=L("span",{class:"d-none d-lg-inline"}," Refresh files ",-1))]),_:1})}const HO=ea(GY,[["render",KY]]),YY=Le({name:"PrinterDetails",components:{RefreshFilesAction:HO},props:{printer:Object},setup:()=>({printersStore:Nt(),printerStateStore:rr()}),data:()=>({dragging:!1}),computed:{printerId(){var e;return(e=this.printer)==null?void 0:e.id},socketState(){var e;if(this.printerId)return(e=this.printerStateStore.socketStatesById[this.printerId])==null?void 0:e.socket},apiState(){var e;if(this.printerId)return(e=this.printerStateStore.socketStatesById[this.printerId])==null?void 0:e.api},printerTextState(){var e,t,n;if(this.printerId)return(n=(t=(e=this.printerStateStore.printerEventsById[this.printerId])==null?void 0:e.current)==null?void 0:t.payload)==null?void 0:n.state.text}}});function XY(e,t,n,r,s,i){const o=HO,a=mr("drop-upload");return e.printer?en(($(),Q(Pn,{key:0,style:ci(e.dragging?"background-color:red":""),transition:"scale-transition"},{default:v(()=>[h(at,null,{default:v(()=>[h(Ue,null,{default:v(()=>[_(" Name: "+ae(e.printer.name)+" ",1),t[0]||(t[0]=L("br",null,null,-1)),_(" URL: "+ae(e.printer.printerURL)+" ",1),t[1]||(t[1]=L("br",null,null,-1)),t[2]||(t[2]=_(" Host: ")),h(kn,{size:"small"},{default:v(()=>[_(ae(e.apiState),1)]),_:1}),t[3]||(t[3]=L("br",null,null,-1)),t[4]||(t[4]=_(" WebSocket: ")),h(kn,{size:"small"},{default:v(()=>[_(ae(e.socketState),1)]),_:1}),t[5]||(t[5]=L("br",null,null,-1)),t[6]||(t[6]=_(" Printer: ")),h(kn,{size:"small"},{default:v(()=>[_(ae(e.printerTextState),1)]),_:1})]),_:1}),h(Ue,null,{default:v(()=>[h(o,{printer:e.printer,class:"d-flex justify-end"},null,8,["printer"])]),_:1})]),_:1})]),_:1},8,["style"])),[[a,{printers:[e.printer]}]]):ve("",!0)}const QY=ea(YY,[["render",XY]]),JY=Le({__name:"PrinterUrlAction",props:{printer:{}},setup(e){const t=e;async function n(){Wt.openPrinterURL(t.printer.printerURL)}return(r,s)=>($(),Q(re,{class:"ma-2",color:"primary",fab:"",size:"small",onClickCapture:s[0]||(s[0]=$t(i=>n(),["stop"]))},{default:v(()=>[h(X,null,{default:v(()=>s[1]||(s[1]=[_("directions")])),_:1})]),_:1}))}}),ZY=Le({name:"PrinterSettingsAction",props:{printer:Object},computed:{printerId(){return this.printer.id}},methods:{openSettings(){this.$emit("update:show",this.printer.id)}}});function eX(e,t,n,r,s,i){return $(),Q(re,{class:"ma-2",color:"primary",fab:"",size:"small",onClickCapture:t[0]||(t[0]=$t(o=>e.openSettings(),["stop"]))},{default:v(()=>[h(X,null,{default:v(()=>t[1]||(t[1]=[_("settings")])),_:1})]),_:1})}const tX=ea(ZY,[["render",eX]]),nX=de({bordered:Boolean,color:String,content:[Number,String],dot:Boolean,floating:Boolean,icon:Je,inline:Boolean,label:{type:String,default:"$vuetify.badge"},max:[Number,String],modelValue:{type:Boolean,default:!0},offsetX:[Number,String],offsetY:[Number,String],textColor:String,...Ve(),...Ko({location:"top end"}),...Bn(),...bt(),...Dt(),...Ou({transition:"scale-rotate-transition"})},"VBadge"),zO=xe()({name:"VBadge",inheritAttrs:!1,props:nX(),setup(e,t){const{backgroundColorClasses:n,backgroundColorStyles:r}=pr(Te(e,"color")),{roundedClasses:s}=qn(e),{t:i}=es(),{textColorClasses:o,textColorStyles:a}=Is(Te(e,"textColor")),{themeClasses:l}=WF(),{locationStyles:u}=tl(e,!0,d=>(e.floating?e.dot?2:4:e.dot?8:12)+(["top","bottom"].includes(d)?+(e.offsetY??0):["left","right"].includes(d)?+(e.offsetX??0):0));return Ie(()=>{const d=Number(e.content),c=!e.max||isNaN(d)?e.content:d<=+e.max?d:`${e.max}+`,[f,p]=vv(t.attrs,["aria-atomic","aria-label","aria-live","role","title"]);return h(e.tag,me({class:["v-badge",{"v-badge--bordered":e.bordered,"v-badge--dot":e.dot,"v-badge--floating":e.floating,"v-badge--inline":e.inline},e.class]},p,{style:e.style}),{default:()=>{var g,m;return[h("div",{class:"v-badge__wrapper"},[(m=(g=t.slots).default)==null?void 0:m.call(g),h(ii,{transition:e.transition},{default:()=>{var y,b;return[en(h("span",me({class:["v-badge__badge",l.value,n.value,s.value,o.value],style:[r.value,a.value,e.inline?{}:u.value],"aria-atomic":"true","aria-label":i(e.label,d),"aria-live":"polite",role:"status"},f),[e.dot?void 0:t.slots.badge?(b=(y=t.slots).badge)==null?void 0:b.call(y):e.icon?h(X,{icon:e.icon},null):c]),[[qo,e.modelValue]])]}})])]}})}),{}}}),rX=Le({__name:"PrinterConnectionAction",props:{printer:{}},setup(e){const t=e,n=rr();function r(){return t.printer.id?n.isPrinterOperational(t.printer.id):!1}function s(){return t.printer.id?n.isPrinterPrinting(t.printer.id):!1}async function i(){if(r())return Wt.sendPrinterDisconnectCommand(t.printer.id);await Wt.sendPrinterConnectCommand(t.printer.id)}return(o,a)=>o.printer.enabled?($(),Q(zO,{key:0,color:r()?"green":"red",bordered:"",class:"ma-2",overlap:""},{badge:v(()=>[r()?($(),Q(X,{key:0},{default:v(()=>a[0]||(a[0]=[_("check")])),_:1})):($(),Q(X,{key:1},{default:v(()=>a[1]||(a[1]=[_("close")])),_:1}))]),default:v(()=>[h(re,{disabled:s(),fab:"",size:"small",onClick:$t(i,["stop"])},{default:v(()=>[h(X,null,{default:v(()=>a[2]||(a[2]=[_("usb")])),_:1})]),_:1},8,["disabled"])]),_:1},8,["color"])):ve("",!0)}}),sX=Le({__name:"PrinterQuickStopAction",props:{printer:{}},setup(e){const t=e;async function n(){confirm("Are you sure to abort the print? Please reconnect after.")&&await FO.postQuickStopM112Command(t.printer.id)}return(r,s)=>r.printer.enabled?($(),Q(zO,{key:0,bordered:"",class:"ma-2",overlap:""},{badge:v(()=>[h(X,null,{default:v(()=>s[0]||(s[0]=[_("bolt")])),_:1})]),default:v(()=>[h(re,{fab:"",size:"small",onClick:$t(n,["stop"])},{default:v(()=>[h(X,null,{default:v(()=>s[1]||(s[1]=[_("stop")])),_:1})]),_:1})]),_:1})):ve("",!0)}});class jO extends yr{static async getSettings(t){const n=`${Oe.getPrinterSettingsRoute(t)}`;return await this.get(n)}static async setGCodeAnalysis(t,n=!1){const r=`${Oe.setPrinterSettingsGCodeAnalysisRoute(t)}`;return await this.post(r,{enabled:n})}static async syncPrinterName(t){const n=`${Oe.syncPrinterNameSettingRoute(t)}`;return await this.post(n)}}const iX=Le({__name:"SyncPrinterNameAction",props:{printer:{}},setup(e){const t=e,n=Mt();async function r(){await jO.syncPrinterName(t.printer.id),n.openInfoMessage({title:"Synced printer name to OctoPrint"})}return(s,i)=>($(),Q(xt,{location:"top"},{activator:v(({props:o})=>[h(re,me(o,{class:"ma-2",color:"primary",fab:"",size:"small",onClickCapture:i[0]||(i[0]=$t(a=>r(),["stop"]))}),{default:v(()=>[h(X,null,{default:v(()=>i[1]||(i[1]=[_("badge")])),_:1})]),_:2},1040)]),default:v(()=>i[2]||(i[2]=[_(" Set OctoPrints name to the FDM Monster Name ")])),_:1}))}}),oX=Le({__name:"PrinterCreateAction",setup(e){const t=ku();function n(){t.openDialogWithContext(Jt.AddOrUpdatePrinterDialog)}return(r,s)=>($(),Q(re,{class:"ma-2",color:"primary",fab:"",size:"small",onClickCapture:s[0]||(s[0]=$t(i=>n(),["stop"]))},{default:v(()=>[h(X,null,{default:v(()=>s[1]||(s[1]=[_("add")])),_:1})]),_:1}))}}),aX=Le({__name:"PrinterDeleteAction",props:{printer:{}},setup(e){const t=e,n=Nt(),r=rr();async function s(){confirm("Are you sure to delete this printer?")&&(await n.deletePrinter(t.printer.id),r.deletePrinterEvents(t.printer.id))}return(i,o)=>($(),Q(re,{class:"ma-2",color:"primary",fab:"",size:"small",onClick:$t(s,["prevent","stop"])},{default:v(()=>[h(X,null,{default:v(()=>o[0]||(o[0]=[_("delete")])),_:1})]),_:1}))}});class gl extends yr{static async createGroup(t){const n=`${Oe.createGroupRoute}`,r={name:t};return await this.post(n,r)}static async deleteGroup(t){const n=`${Oe.deleteGroupRoute(t)}`;return await this.delete(n)}static async getGroupsWithPrinters(){const t=`${Oe.printerGroupRoute}`;return await this.get(t)}static async addPrinterToGroup(t,n){const r=`${Oe.addPrinterToGroupRoute(t)}`,s={printerId:n};return await this.post(r,s)}static async deletePrinterFromGroup(t,n){const r=`${Oe.deletePrinterFromGroupRoute(t)}`,s={printerId:n};return await this.delete(r,s)}static async updateGroupName(t,n){const r=`${Oe.updateGroupNameRoute(t)}`,s={name:n};return await this.patch(r,s)}}const lX=(e,t,n)=>e==null||t==null?-1:e.toString().toLocaleLowerCase().indexOf(t.toString().toLocaleLowerCase()),uX=de({customFilter:Function,customKeyFilter:Object,filterKeys:[Array,String],filterMode:{type:String,default:"intersection"},noFilter:Boolean},"filter");function cX(e,t,n){var a;const r=[],s=(n==null?void 0:n.default)??lX,i=n!=null&&n.filterKeys?Dn(n.filterKeys):!1,o=Object.keys((n==null?void 0:n.customKeyFilter)??{}).length;if(!(e!=null&&e.length))return r;e:for(let l=0;l<e.length;l++){const[u,d=u]=Dn(e[l]),c={},f={};let p=-1;if((t||o>0)&&!(n!=null&&n.noFilter)){if(typeof u=="object"){const y=i||Object.keys(d);for(const b of y){const w=er(d,b),S=(a=n==null?void 0:n.customKeyFilter)==null?void 0:a[b];if(p=S?S(w,t,u):s(w,t,u),p!==-1&&p!==!1)S?c[b]=p:f[b]=p;else if((n==null?void 0:n.filterMode)==="every")continue e}}else p=s(u,t,u),p!==-1&&p!==!1&&(f.title=p);const g=Object.keys(f).length,m=Object.keys(c).length;if(!g&&!m||(n==null?void 0:n.filterMode)==="union"&&m!==o&&!g||(n==null?void 0:n.filterMode)==="intersection"&&(m!==o||!g))continue}r.push({index:l,matches:{...f,...c}})}return r}function dX(e,t,n,r){const s=U([]),i=U(new Map),o=R(()=>r!=null&&r.transform?ie(t).map(l=>[l,r.transform(l)]):ie(t));jn(()=>{const l=typeof n=="function"?n():ie(n),u=typeof l!="string"&&typeof l!="number"?"":String(l),d=cX(o.value,u,{customKeyFilter:{...e.customKeyFilter,...ie(r==null?void 0:r.customKeyFilter)},default:e.customFilter,filterKeys:e.filterKeys,filterMode:e.filterMode,noFilter:e.noFilter}),c=ie(t),f=[],p=new Map;d.forEach(g=>{let{index:m,matches:y}=g;const b=c[m];f.push(b),p.set(b.value,y)}),s.value=f,i.value=p});function a(l){return i.value.get(l.value)}return{filteredItems:s,filteredMatches:i,getMatches:a}}const fX=e=>{const{touchstartX:t,touchendX:n,touchstartY:r,touchendY:s}=e,i=.5,o=16;e.offsetX=n-t,e.offsetY=s-r,Math.abs(e.offsetY)<i*Math.abs(e.offsetX)&&(e.left&&n<t-o&&e.left(e),e.right&&n>t+o&&e.right(e)),Math.abs(e.offsetX)<i*Math.abs(e.offsetY)&&(e.up&&s<r-o&&e.up(e),e.down&&s>r+o&&e.down(e))};function hX(e,t){var r;const n=e.changedTouches[0];t.touchstartX=n.clientX,t.touchstartY=n.clientY,(r=t.start)==null||r.call(t,{originalEvent:e,...t})}function pX(e,t){var r;const n=e.changedTouches[0];t.touchendX=n.clientX,t.touchendY=n.clientY,(r=t.end)==null||r.call(t,{originalEvent:e,...t}),fX(t)}function mX(e,t){var r;const n=e.changedTouches[0];t.touchmoveX=n.clientX,t.touchmoveY=n.clientY,(r=t.move)==null||r.call(t,{originalEvent:e,...t})}function gX(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const t={touchstartX:0,touchstartY:0,touchendX:0,touchendY:0,touchmoveX:0,touchmoveY:0,offsetX:0,offsetY:0,left:e.left,right:e.right,up:e.up,down:e.down,start:e.start,move:e.move,end:e.end};return{touchstart:n=>hX(n,t),touchend:n=>pX(n,t),touchmove:n=>mX(n,t)}}function vX(e,t){var a;const n=t.value,r=n!=null&&n.parent?e.parentElement:e,s=(n==null?void 0:n.options)??{passive:!0},i=(a=t.instance)==null?void 0:a.$.uid;if(!r||!i)return;const o=gX(t.value);r._touchHandlers=r._touchHandlers??Object.create(null),r._touchHandlers[i]=o,cP(o).forEach(l=>{r.addEventListener(l,o[l],s)})}function yX(e,t){var i,o;const n=(i=t.value)!=null&&i.parent?e.parentElement:e,r=(o=t.instance)==null?void 0:o.$.uid;if(!(n!=null&&n._touchHandlers)||!r)return;const s=n._touchHandlers[r];cP(s).forEach(a=>{n.removeEventListener(a,s[a])}),delete n._touchHandlers[r]}const qO={mounted:vX,unmounted:yX},bX=qO,WO=Symbol.for("vuetify:v-window"),GO=Symbol.for("vuetify:v-window-group"),KO=de({continuous:Boolean,nextIcon:{type:[Boolean,String,Function,Object],default:"$next"},prevIcon:{type:[Boolean,String,Function,Object],default:"$prev"},reverse:Boolean,showArrows:{type:[Boolean,String],validator:e=>typeof e=="boolean"||e==="hover"},touch:{type:[Object,Boolean],default:void 0},direction:{type:String,default:"horizontal"},modelValue:null,disabled:Boolean,selectedClass:{type:String,default:"v-window-item--active"},mandatory:{type:[Boolean,String],default:"force"},...Ve(),...bt(),...Dt()},"VWindow"),$k=xe()({name:"VWindow",directives:{Touch:qO},props:KO(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const{themeClasses:r}=Xt(e),{isRtl:s}=Nr(),{t:i}=es(),o=Cu(e,GO),a=U(),l=R(()=>s.value?!e.reverse:e.reverse),u=Me(!1),d=R(()=>{const P=e.direction==="vertical"?"y":"x",T=(l.value?!u.value:u.value)?"-reverse":"";return`v-window-${P}${T}-transition`}),c=Me(0),f=U(void 0),p=R(()=>o.items.value.findIndex(P=>o.selected.value.includes(P.id)));Ce(p,(P,E)=>{const T=o.items.value.length,C=T-1;T<=2?u.value=P<E:P===C&&E===0?u.value=!0:P===0&&E===C?u.value=!1:u.value=P<E}),Gt(WO,{transition:d,isReversed:u,transitionCount:c,transitionHeight:f,rootRef:a});const g=R(()=>e.continuous||p.value!==0),m=R(()=>e.continuous||p.value!==o.items.value.length-1);function y(){g.value&&o.prev()}function b(){m.value&&o.next()}const w=R(()=>{const P=[],E={icon:s.value?e.nextIcon:e.prevIcon,class:`v-window__${l.value?"right":"left"}`,onClick:o.prev,"aria-label":i("$vuetify.carousel.prev")};P.push(g.value?n.prev?n.prev({props:E}):h(re,E,null):h("div",null,null));const T={icon:s.value?e.prevIcon:e.nextIcon,class:`v-window__${l.value?"left":"right"}`,onClick:o.next,"aria-label":i("$vuetify.carousel.next")};return P.push(m.value?n.next?n.next({props:T}):h(re,T,null):h("div",null,null)),P}),S=R(()=>e.touch===!1?e.touch:{...{left:()=>{l.value?y():b()},right:()=>{l.value?b():y()},start:E=>{let{originalEvent:T}=E;T.stopPropagation()}},...e.touch===!0?{}:e.touch});return Ie(()=>en(h(e.tag,{ref:a,class:["v-window",{"v-window--show-arrows-on-hover":e.showArrows==="hover"},r.value,e.class],style:e.style},{default:()=>{var P,E;return[h("div",{class:"v-window__container",style:{height:f.value}},[(P=n.default)==null?void 0:P.call(n,{group:o}),e.showArrows!==!1&&h("div",{class:"v-window__controls"},[w.value])]),(E=n.additional)==null?void 0:E.call(n,{group:o})]}}),[[mr("touch"),S.value]])),{group:o}}}),YO=de({reverseTransition:{type:[Boolean,String],default:void 0},transition:{type:[Boolean,String],default:void 0},...Ve(),...Pd(),...nT()},"VWindowItem"),Fk=xe()({name:"VWindowItem",directives:{Touch:bX},props:YO(),emits:{"group:selected":e=>!0},setup(e,t){let{slots:n}=t;const r=Ye(WO),s=Td(e,GO),{isBooted:i}=qd();if(!r||!s)throw new Error("[Vuetify] VWindowItem must be used inside VWindow");const o=Me(!1),a=R(()=>i.value&&(r.isReversed.value?e.reverseTransition!==!1:e.transition!==!1));function l(){!o.value||!r||(o.value=!1,r.transitionCount.value>0&&(r.transitionCount.value-=1,r.transitionCount.value===0&&(r.transitionHeight.value=void 0)))}function u(){var g;o.value||!r||(o.value=!0,r.transitionCount.value===0&&(r.transitionHeight.value=Ne((g=r.rootRef.value)==null?void 0:g.clientHeight)),r.transitionCount.value+=1)}function d(){l()}function c(g){o.value&&Ot(()=>{!a.value||!o.value||!r||(r.transitionHeight.value=Ne(g.clientHeight))})}const f=R(()=>{const g=r.isReversed.value?e.reverseTransition:e.transition;return a.value?{name:typeof g!="string"?r.transition.value:g,onBeforeEnter:u,onAfterEnter:l,onEnterCancelled:d,onBeforeLeave:u,onAfterLeave:l,onLeaveCancelled:d,onEnter:c}:!1}),{hasContent:p}=rT(e,s.isSelected);return Ie(()=>h(ii,{transition:f.value,disabled:!i.value},{default:()=>{var g;return[en(h("div",{class:["v-window-item",s.selectedClass.value,e.class],style:e.style},[p.value&&((g=n.default)==null?void 0:g.call(n))]),[[qo,s.isSelected.value]])]}})),{groupItem:s}}}),wX=de({expandOnClick:Boolean,showExpand:Boolean,expanded:{type:Array,default:()=>[]}},"DataTable-expand"),XO=Symbol.for("vuetify:datatable:expanded");function SX(e){const t=Te(e,"expandOnClick"),n=st(e,"expanded",e.expanded,a=>new Set(a),a=>[...a.values()]);function r(a,l){const u=new Set(n.value);l?u.add(a.value):u.delete(a.value),n.value=u}function s(a){return n.value.has(a.value)}function i(a){r(a,!s(a))}const o={expand:r,expanded:n,expandOnClick:t,isExpanded:s,toggleExpand:i};return Gt(XO,o),o}function QO(){const e=Ye(XO);if(!e)throw new Error("foo");return e}const _X=de({groupBy:{type:Array,default:()=>[]}},"DataTable-group"),JO=Symbol.for("vuetify:data-table-group");function kX(e){return{groupBy:st(e,"groupBy")}}function xX(e){const{disableSort:t,groupBy:n,sortBy:r}=e,s=U(new Set),i=R(()=>n.value.map(d=>({...d,order:d.order??!1})).concat(t!=null&&t.value?[]:r.value));function o(d){return s.value.has(d.id)}function a(d){const c=new Set(s.value);o(d)?c.delete(d.id):c.add(d.id),s.value=c}function l(d){function c(f){const p=[];for(const g of f.items)"type"in g&&g.type==="group"?p.push(...c(g)):p.push(g);return p}return c({type:"group",items:d,id:"dummy",key:"dummy",value:"dummy",depth:0})}const u={sortByWithGroups:i,toggleGroup:a,opened:s,groupBy:n,extractRows:l,isGroupOpen:o};return Gt(JO,u),u}function ZO(){const e=Ye(JO);if(!e)throw new Error("Missing group!");return e}function EX(e,t){if(!e.length)return[];const n=new Map;for(const r of e){const s=Va(r.raw,t);n.has(s)||n.set(s,[]),n.get(s).push(r)}return n}function eM(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"root";if(!t.length)return[];const s=EX(e,t[0]),i=[],o=t.slice(1);return s.forEach((a,l)=>{const u=t[0],d=`${r}_${u}_${l}`;i.push({depth:n,id:d,key:u,value:l,items:o.length?eM(a,o,n+1,d):a,type:"group"})}),i}function tM(e,t){const n=[];for(const r of e)"type"in r&&r.type==="group"?(r.value!=null&&n.push(r),(t.has(r.id)||r.value==null)&&n.push(...tM(r.items,t))):n.push(r);return n}function CX(e,t,n){return{flatItems:R(()=>{if(!t.value.length)return e.value;const s=eM(e.value,t.value.map(i=>i.key));return tM(s,n.value)})}}function PX(e){let{page:t,itemsPerPage:n,sortBy:r,groupBy:s,search:i}=e;const o=sn("VDataTable"),a=R(()=>({page:t.value,itemsPerPage:n.value,sortBy:r.value,groupBy:s.value,search:i.value}));let l=null;Ce(a,()=>{Wo(l,a.value)||(l&&l.search!==a.value.search&&(t.value=1),o.emit("update:options",a.value),l=a.value)},{deep:!0,immediate:!0})}const TX=de({page:{type:[Number,String],default:1},itemsPerPage:{type:[Number,String],default:10}},"DataTable-paginate"),nM=Symbol.for("vuetify:data-table-pagination");function RX(e){const t=st(e,"page",void 0,r=>+(r??1)),n=st(e,"itemsPerPage",void 0,r=>+(r??10));return{page:t,itemsPerPage:n}}function IX(e){const{page:t,itemsPerPage:n,itemsLength:r}=e,s=R(()=>n.value===-1?0:n.value*(t.value-1)),i=R(()=>n.value===-1?r.value:Math.min(r.value,s.value+n.value)),o=R(()=>n.value===-1||r.value===0?1:Math.ceil(r.value/n.value));Ce([t,o],()=>{t.value>o.value&&(t.value=o.value)});function a(f){n.value=f,t.value=1}function l(){t.value=Rr(t.value+1,1,o.value)}function u(){t.value=Rr(t.value-1,1,o.value)}function d(f){t.value=Rr(f,1,o.value)}const c={page:t,itemsPerPage:n,startIndex:s,stopIndex:i,pageCount:o,itemsLength:r,nextPage:l,prevPage:u,setPage:d,setItemsPerPage:a};return Gt(nM,c),c}function AX(){const e=Ye(nM);if(!e)throw new Error("Missing pagination!");return e}function OX(e){const t=sn("usePaginatedItems"),{items:n,startIndex:r,stopIndex:s,itemsPerPage:i}=e,o=R(()=>i.value<=0?n.value:n.value.slice(r.value,s.value));return Ce(o,a=>{t.emit("update:currentItems",a)}),{paginatedItems:o}}const MX={showSelectAll:!1,allSelected:()=>[],select:e=>{var r;let{items:t,value:n}=e;return new Set(n?[(r=t[0])==null?void 0:r.value]:[])},selectAll:e=>{let{selected:t}=e;return t}},rM={showSelectAll:!0,allSelected:e=>{let{currentPage:t}=e;return t},select:e=>{let{items:t,value:n,selected:r}=e;for(const s of t)n?r.add(s.value):r.delete(s.value);return r},selectAll:e=>{let{value:t,currentPage:n,selected:r}=e;return rM.select({items:n,value:t,selected:r})}},sM={showSelectAll:!0,allSelected:e=>{let{allItems:t}=e;return t},select:e=>{let{items:t,value:n,selected:r}=e;for(const s of t)n?r.add(s.value):r.delete(s.value);return r},selectAll:e=>{let{value:t,allItems:n,selected:r}=e;return sM.select({items:n,value:t,selected:r})}},DX=de({showSelect:Boolean,selectStrategy:{type:[String,Object],default:"page"},modelValue:{type:Array,default:()=>[]},valueComparator:{type:Function,default:Wo}},"DataTable-select"),iM=Symbol.for("vuetify:data-table-selection");function LX(e,t){let{allItems:n,currentPage:r}=t;const s=st(e,"modelValue",e.modelValue,b=>new Set(Dn(b).map(w=>{var S;return((S=n.value.find(P=>e.valueComparator(w,P.value)))==null?void 0:S.value)??w})),b=>[...b.values()]),i=R(()=>n.value.filter(b=>b.selectable)),o=R(()=>r.value.filter(b=>b.selectable)),a=R(()=>{if(typeof e.selectStrategy=="object")return e.selectStrategy;switch(e.selectStrategy){case"single":return MX;case"all":return sM;case"page":default:return rM}});function l(b){return Dn(b).every(w=>s.value.has(w.value))}function u(b){return Dn(b).some(w=>s.value.has(w.value))}function d(b,w){const S=a.value.select({items:b,value:w,selected:new Set(s.value)});s.value=S}function c(b){d([b],!l([b]))}function f(b){const w=a.value.selectAll({value:b,allItems:i.value,currentPage:o.value,selected:new Set(s.value)});s.value=w}const p=R(()=>s.value.size>0),g=R(()=>{const b=a.value.allSelected({allItems:i.value,currentPage:o.value});return!!b.length&&l(b)}),m=R(()=>a.value.showSelectAll),y={toggleSelect:c,select:d,selectAll:f,isSelected:l,isSomeSelected:u,someSelected:p,allSelected:g,showSelectAll:m};return Gt(iM,y),y}function xm(){const e=Ye(iM);if(!e)throw new Error("Missing selection!");return e}const $X=de({sortBy:{type:Array,default:()=>[]},customKeySort:Object,multiSort:Boolean,mustSort:Boolean},"DataTable-sort"),oM=Symbol.for("vuetify:data-table-sort");function FX(e){const t=st(e,"sortBy"),n=Te(e,"mustSort"),r=Te(e,"multiSort");return{sortBy:t,mustSort:n,multiSort:r}}function NX(e){const{sortBy:t,mustSort:n,multiSort:r,page:s}=e,i=l=>{if(l.key==null)return;let u=t.value.map(c=>({...c}))??[];const d=u.find(c=>c.key===l.key);d?d.order==="desc"?n.value?d.order="asc":u=u.filter(c=>c.key!==l.key):d.order="desc":r.value?u=[...u,{key:l.key,order:"asc"}]:u=[{key:l.key,order:"asc"}],t.value=u,s&&(s.value=1)};function o(l){return!!t.value.find(u=>u.key===l.key)}const a={sortBy:t,toggleSort:i,isSorted:o};return Gt(oM,a),a}function aM(){const e=Ye(oM);if(!e)throw new Error("Missing sort!");return e}function BX(e,t,n,r){const s=es();return{sortedItems:R(()=>{var o,a;return n.value.length?VX(t.value,n.value,s.current.value,{transform:r==null?void 0:r.transform,sortFunctions:{...e.customKeySort,...(o=r==null?void 0:r.sortFunctions)==null?void 0:o.value},sortRawFunctions:(a=r==null?void 0:r.sortRawFunctions)==null?void 0:a.value}):t.value})}}function VX(e,t,n,r){const s=new Intl.Collator(n,{sensitivity:"accent",usage:"sort"});return e.map(o=>[o,r!=null&&r.transform?r.transform(o):o]).sort((o,a)=>{var l,u;for(let d=0;d<t.length;d++){let c=!1;const f=t[d].key,p=t[d].order??"asc";if(p===!1)continue;let g=Va(o[1],f),m=Va(a[1],f),y=o[0].raw,b=a[0].raw;if(p==="desc"&&([g,m]=[m,g],[y,b]=[b,y]),(l=r==null?void 0:r.sortRawFunctions)!=null&&l[f]){const w=r.sortRawFunctions[f](y,b);if(w==null)continue;if(c=!0,w)return w}if((u=r==null?void 0:r.sortFunctions)!=null&&u[f]){const w=r.sortFunctions[f](g,m);if(w==null)continue;if(c=!0,w)return w}if(!c){if(g instanceof Date&&m instanceof Date)return g.getTime()-m.getTime();if([g,m]=[g,m].map(w=>w!=null?w.toString().toLocaleLowerCase():w),g!==m)return rf(g)&&rf(m)?0:rf(g)?-1:rf(m)?1:!isNaN(g)&&!isNaN(m)?Number(g)-Number(m):s.compare(g,m)}}return 0}).map(o=>{let[a]=o;return a})}function UX(){const e=U([]);EC(()=>e.value=[]);function t(n,r){e.value[r]=n}return{refs:e,updateRef:t}}const HX=de({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:Je,default:"$first"},prevIcon:{type:Je,default:"$prev"},nextIcon:{type:Je,default:"$next"},lastIcon:{type:Je,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,...vs(),...Ve(),...Lr(),...bs(),...Bn(),...Pu(),...bt({tag:"nav"}),...Dt(),...Fs({variant:"text"})},"VPagination"),Nk=xe()({name:"VPagination",props:HX(),emits:{"update:modelValue":e=>!0,first:e=>!0,prev:e=>!0,next:e=>!0,last:e=>!0},setup(e,t){let{slots:n,emit:r}=t;const s=st(e,"modelValue"),{t:i,n:o}=es(),{isRtl:a}=Nr(),{themeClasses:l}=Xt(e),{width:u}=mi(),d=Me(-1);Dr(void 0,{scoped:!0});const{resizeRef:c}=Ua(k=>{if(!k.length)return;const{target:x,contentRect:I}=k[0],M=x.querySelector(".v-pagination__list > *");if(!M)return;const O=I.width,A=M.offsetWidth+parseFloat(getComputedStyle(M).marginRight)*2;d.value=m(O,A)}),f=R(()=>parseInt(e.length,10)),p=R(()=>parseInt(e.start,10)),g=R(()=>e.totalVisible!=null?parseInt(e.totalVisible,10):d.value>=0?d.value:m(u.value,58));function m(k,x){const I=e.showFirstLastPage?5:3;return Math.max(0,Math.floor(+((k-x*I)/x).toFixed(2)))}const y=R(()=>{if(f.value<=0||isNaN(f.value)||f.value>Number.MAX_SAFE_INTEGER)return[];if(g.value<=0)return[];if(g.value===1)return[s.value];if(f.value<=g.value)return Cl(f.value,p.value);const k=g.value%2===0,x=k?g.value/2:Math.floor(g.value/2),I=k?x:x+1,M=f.value-x;if(I-s.value>=0)return[...Cl(Math.max(1,g.value-1),p.value),e.ellipsis,f.value];if(s.value-M>=(k?1:0)){const O=g.value-1,A=f.value-O+p.value;return[p.value,e.ellipsis,...Cl(O,A)]}else{const O=Math.max(1,g.value-3),A=O===1?s.value:s.value-Math.ceil(O/2)+p.value;return[p.value,e.ellipsis,...Cl(O,A),e.ellipsis,f.value]}});function b(k,x,I){k.preventDefault(),s.value=x,I&&r(I,x)}const{refs:w,updateRef:S}=UX();Dr({VPaginationBtn:{color:Te(e,"color"),border:Te(e,"border"),density:Te(e,"density"),size:Te(e,"size"),variant:Te(e,"variant"),rounded:Te(e,"rounded"),elevation:Te(e,"elevation")}});const P=R(()=>y.value.map((k,x)=>{const I=M=>S(M,x);if(typeof k=="string")return{isActive:!1,key:`ellipsis-${x}`,page:k,props:{ref:I,ellipsis:!0,icon:!0,disabled:!0}};{const M=k===s.value;return{isActive:M,key:k,page:o(k),props:{ref:I,ellipsis:!1,icon:!0,disabled:!!e.disabled||+e.length<2,color:M?e.activeColor:e.color,"aria-current":M,"aria-label":i(M?e.currentPageAriaLabel:e.pageAriaLabel,k),onClick:O=>b(O,k)}}}})),E=R(()=>{const k=!!e.disabled||s.value<=p.value,x=!!e.disabled||s.value>=p.value+f.value-1;return{first:e.showFirstLastPage?{icon:a.value?e.lastIcon:e.firstIcon,onClick:I=>b(I,p.value,"first"),disabled:k,"aria-label":i(e.firstAriaLabel),"aria-disabled":k}:void 0,prev:{icon:a.value?e.nextIcon:e.prevIcon,onClick:I=>b(I,s.value-1,"prev"),disabled:k,"aria-label":i(e.previousAriaLabel),"aria-disabled":k},next:{icon:a.value?e.prevIcon:e.nextIcon,onClick:I=>b(I,s.value+1,"next"),disabled:x,"aria-label":i(e.nextAriaLabel),"aria-disabled":x},last:e.showFirstLastPage?{icon:a.value?e.firstIcon:e.lastIcon,onClick:I=>b(I,p.value+f.value-1,"last"),disabled:x,"aria-label":i(e.lastAriaLabel),"aria-disabled":x}:void 0}});function T(){var x;const k=s.value-p.value;(x=w.value[k])==null||x.$el.focus()}function C(k){k.key===w_.left&&!e.disabled&&s.value>+e.start?(s.value=s.value-1,Ot(T)):k.key===w_.right&&!e.disabled&&s.value<p.value+f.value-1&&(s.value=s.value+1,Ot(T))}return Ie(()=>h(e.tag,{ref:c,class:["v-pagination",l.value,e.class],style:e.style,role:"navigation","aria-label":i(e.ariaLabel),onKeydown:C,"data-test":"v-pagination-root"},{default:()=>[h("ul",{class:"v-pagination__list"},[e.showFirstLastPage&&h("li",{key:"first",class:"v-pagination__first","data-test":"v-pagination-first"},[n.first?n.first(E.value.first):h(re,me({_as:"VPaginationBtn"},E.value.first),null)]),h("li",{key:"prev",class:"v-pagination__prev","data-test":"v-pagination-prev"},[n.prev?n.prev(E.value.prev):h(re,me({_as:"VPaginationBtn"},E.value.prev),null)]),P.value.map((k,x)=>h("li",{key:k.key,class:["v-pagination__item",{"v-pagination__item--is-active":k.isActive}],"data-test":"v-pagination-item"},[n.item?n.item(k):h(re,me({_as:"VPaginationBtn"},k.props),{default:()=>[k.page]})])),h("li",{key:"next",class:"v-pagination__next","data-test":"v-pagination-next"},[n.next?n.next(E.value.next):h(re,me({_as:"VPaginationBtn"},E.value.next),null)]),e.showFirstLastPage&&h("li",{key:"last",class:"v-pagination__last","data-test":"v-pagination-last"},[n.last?n.last(E.value.last):h(re,me({_as:"VPaginationBtn"},E.value.last),null)])])]})),{}}}),lM=de({prevIcon:{type:Je,default:"$prev"},nextIcon:{type:Je,default:"$next"},firstIcon:{type:Je,default:"$first"},lastIcon:{type:Je,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"),Bk=xe()({name:"VDataTableFooter",props:lM(),setup(e,t){let{slots:n}=t;const{t:r}=es(),{page:s,pageCount:i,startIndex:o,stopIndex:a,itemsLength:l,itemsPerPage:u,setItemsPerPage:d}=AX(),c=R(()=>e.itemsPerPageOptions.map(f=>typeof f=="number"?{value:f,title:f===-1?r("$vuetify.dataFooter.itemsPerPageAll"):String(f)}:{...f,title:isNaN(Number(f.title))?r(f.title):f.title}));return Ie(()=>{var p;const f=Nk.filterProps(e);return h("div",{class:"v-data-table-footer"},[(p=n.prepend)==null?void 0:p.call(n),h("div",{class:"v-data-table-footer__items-per-page"},[h("span",null,[r(e.itemsPerPageText)]),h(Bo,{items:c.value,modelValue:u.value,"onUpdate:modelValue":g=>d(Number(g)),density:"compact",variant:"outlined","hide-details":!0},null)]),h("div",{class:"v-data-table-footer__info"},[h("div",null,[r(e.pageText,l.value?o.value+1:0,a.value,l.value)])]),h("div",{class:"v-data-table-footer__pagination"},[h(Nk,me({modelValue:s.value,"onUpdate:modelValue":g=>s.value=g,density:"comfortable","first-aria-label":e.firstPageLabel,"last-aria-label":e.lastPageLabel,length:i.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)])])}),{}}}),up=NF({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 r=e.tag??"td";return h(r,{class:["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:{height:Ne(e.height),width:Ne(e.width),maxWidth:Ne(e.maxWidth),left:Ne(e.fixedOffset||null)}},{default:()=>{var s;return[(s=n.default)==null?void 0:s.call(n)]}})}),zX=de({headers:Array},"DataTable-header"),uM=Symbol.for("vuetify:data-table-headers"),cM={title:"",sortable:!1},jX={...cM,width:48};function qX(){const t=(arguments.length>0&&arguments[0]!==void 0?arguments[0]:[]).map(n=>({element:n,priority:0}));return{enqueue:(n,r)=>{let s=!1;for(let i=0;i<t.length;i++)if(t[i].priority>r){t.splice(i,0,{element:n,priority:r}),s=!0;break}s||t.push({element:n,priority:r})},size:()=>t.length,count:()=>{let n=0;if(!t.length)return 0;const r=Math.floor(t[0].priority);for(let s=0;s<t.length;s++)Math.floor(t[s].priority)===r&&(n+=1);return n},dequeue:()=>t.shift()}}function Wy(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)Wy(n,t);return t}function dM(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:new Set;for(const n of e)n.key&&t.add(n.key),n.children&&dM(n.children,t);return t}function WX(e){if(e.key){if(e.key==="data-table-group")return cM;if(["data-table-expand","data-table-select"].includes(e.key))return jX}}function Zw(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return e.children?Math.max(t,...e.children.map(n=>Zw(n,t+1))):t}function GX(e){let t=!1;function n(i){let o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;if(i)if(o&&(i.fixed=!0),i.fixed)if(i.children)for(let a=i.children.length-1;a>=0;a--)n(i.children[a],!0);else t?isNaN(+i.width)&&(`${i.key}`,void 0):i.lastFixed=!0,t=!0;else if(i.children)for(let a=i.children.length-1;a>=0;a--)n(i.children[a]);else t=!1}for(let i=e.length-1;i>=0;i--)n(e[i]);function r(i){let o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;if(!i)return o;if(i.children){i.fixedOffset=o;for(const a of i.children)o=r(a,o)}else i.fixed&&(i.fixedOffset=o,o+=parseFloat(i.width||"0")||0);return o}let s=0;for(const i of e)s=r(i,s)}function KX(e,t){const n=[];let r=0;const s=qX(e);for(;s.size()>0;){let o=s.count();const a=[];let l=1;for(;o>0;){const{element:u,priority:d}=s.dequeue(),c=t-r-Zw(u);if(a.push({...u,rowspan:c??1,colspan:u.children?Wy(u).length:1}),u.children)for(const f of u.children){const p=d%1+l/Math.pow(10,r+2);s.enqueue(f,r+c+p)}l+=1,o-=1}r+=1,n.push(a)}return{columns:e.map(o=>Wy(o)).flat(),headers:n}}function fM(e){const t=[];for(const n of e){const r={...WX(n),...n},s=r.key??(typeof r.value=="string"?r.value:null),i=r.value??s??null,o={...r,key:s,value:i,sortable:r.sortable??(r.key!=null||!!r.sort),children:r.children?fM(r.children):void 0};t.push(o)}return t}function YX(e,t){const n=U([]),r=U([]),s=U({}),i=U({}),o=U({});jn(()=>{var m,y,b;const u=(e.headers||Object.keys(e.items[0]??{}).map(w=>({key:w,title:hi(w)}))).slice(),d=dM(u);(m=t==null?void 0:t.groupBy)!=null&&m.value.length&&!d.has("data-table-group")&&u.unshift({key:"data-table-group",title:"Group"}),(y=t==null?void 0:t.showSelect)!=null&&y.value&&!d.has("data-table-select")&&u.unshift({key:"data-table-select"}),(b=t==null?void 0:t.showExpand)!=null&&b.value&&!d.has("data-table-expand")&&u.push({key:"data-table-expand"});const c=fM(u);GX(c);const f=Math.max(...c.map(w=>Zw(w)))+1,p=KX(c,f);n.value=p.headers,r.value=p.columns;const g=p.headers.flat(1);for(const w of g)w.key&&(w.sortable&&(w.sort&&(s.value[w.key]=w.sort),w.sortRaw&&(i.value[w.key]=w.sortRaw)),w.filter&&(o.value[w.key]=w.filter))});const a={headers:n,columns:r,sortFunctions:s,sortRawFunctions:i,filterFunctions:o};return Gt(uM,a),a}function Em(){const e=Ye(uM);if(!e)throw new Error("Missing headers!");return e}const hM=de({color:String,sticky:Boolean,disableSort:Boolean,multiSort:Boolean,sortAscIcon:{type:Je,default:"$sortAsc"},sortDescIcon:{type:Je,default:"$sortDesc"},headerProps:{type:Object},...nl(),...Bp()},"VDataTableHeaders"),Vk=xe()({name:"VDataTableHeaders",props:hM(),setup(e,t){let{slots:n}=t;const{t:r}=es(),{toggleSort:s,sortBy:i,isSorted:o}=aM(),{someSelected:a,allSelected:l,selectAll:u,showSelectAll:d}=xm(),{columns:c,headers:f}=Em(),{loaderClasses:p}=Ad(e);function g(k,x){if(!(!e.sticky&&!k.fixed))return{position:"sticky",left:k.fixed?Ne(k.fixedOffset):void 0,top:e.sticky?`calc(var(--v-table-header-height) * ${x})`:void 0}}function m(k){const x=i.value.find(I=>I.key===k.key);return x?x.order==="asc"?e.sortAscIcon:e.sortDescIcon:e.sortAscIcon}const{backgroundColorClasses:y,backgroundColorStyles:b}=pr(e,"color"),{displayClasses:w,mobile:S}=mi(e),P=R(()=>({headers:f.value,columns:c.value,toggleSort:s,isSorted:o,sortBy:i.value,someSelected:a.value,allSelected:l.value,selectAll:u,getSortIcon:m})),E=R(()=>["v-data-table__th",{"v-data-table__th--sticky":e.sticky},w.value,p.value]),T=k=>{let{column:x,x:I,y:M}=k;const O=x.key==="data-table-select"||x.key==="data-table-expand",A=me(e.headerProps??{},x.headerProps??{});return h(up,me({tag:"th",align:x.align,class:[{"v-data-table__th--sortable":x.sortable&&!e.disableSort,"v-data-table__th--sorted":o(x),"v-data-table__th--fixed":x.fixed},...E.value],style:{width:Ne(x.width),minWidth:Ne(x.minWidth),maxWidth:Ne(x.maxWidth),...g(x,M)},colspan:x.colspan,rowspan:x.rowspan,onClick:x.sortable?()=>s(x):void 0,fixed:x.fixed,nowrap:x.nowrap,lastFixed:x.lastFixed,noPadding:O},A),{default:()=>{var H;const D=`header.${x.key}`,V={column:x,selectAll:u,isSorted:o,toggleSort:s,sortBy:i.value,someSelected:a.value,allSelected:l.value,getSortIcon:m};return n[D]?n[D](V):x.key==="data-table-select"?((H=n["header.data-table-select"])==null?void 0:H.call(n,V))??(d.value&&h(yu,{modelValue:l.value,indeterminate:a.value&&!l.value,"onUpdate:modelValue":u},null)):h("div",{class:"v-data-table-header__content"},[h("span",null,[x.title]),x.sortable&&!e.disableSort&&h(X,{key:"icon",class:"v-data-table-header__sort-icon",icon:m(x)},null),e.multiSort&&o(x)&&h("div",{key:"badge",class:["v-data-table-header__sort-badge",...y.value],style:b.value},[i.value.findIndex(G=>G.key===x.key)+1])])}})},C=()=>{const k=me(e.headerProps??{}??{}),x=R(()=>c.value.filter(M=>(M==null?void 0:M.sortable)&&!e.disableSort)),I=R(()=>{if(c.value.find(O=>O.key==="data-table-select")!=null)return l.value?"$checkboxOn":a.value?"$checkboxIndeterminate":"$checkboxOff"});return h(up,me({tag:"th",class:[...E.value],colspan:f.value.length+1},k),{default:()=>[h("div",{class:"v-data-table-header__content"},[h(Bo,{chips:!0,class:"v-data-table__td-sort-select",clearable:!0,density:"default",items:x.value,label:r("$vuetify.dataTable.sortBy"),multiple:e.multiSort,variant:"underlined","onClick:clear":()=>i.value=[],appendIcon:I.value,"onClick:append":()=>u(!l.value)},{...n,chip:M=>{var O;return h(kn,{onClick:(O=M.item.raw)!=null&&O.sortable?()=>s(M.item.raw):void 0,onMousedown:A=>{A.preventDefault(),A.stopPropagation()}},{default:()=>[M.item.title,h(X,{class:["v-data-table__td-sort-icon",o(M.item.raw)&&"v-data-table__td-sort-icon-active"],icon:m(M.item.raw),size:"small"},null)]})}})])]})};Ie(()=>S.value?h("tr",null,[h(C,null,null)]):h(Re,null,[n.headers?n.headers(P.value):f.value.map((k,x)=>h("tr",null,[k.map((I,M)=>h(T,{column:I,x:M,y:x},null))])),e.loading&&h("tr",{class:"v-data-table-progress"},[h("th",{colspan:c.value.length},[h(Vp,{name:"v-data-table-progress",absolute:!0,active:!0,color:typeof e.loading=="boolean"?void 0:e.loading,indeterminate:!0},{default:n.loader})])])]))}}),XX=de({item:{type:Object,required:!0}},"VDataTableGroupHeaderRow"),QX=xe()({name:"VDataTableGroupHeaderRow",props:XX(),setup(e,t){let{slots:n}=t;const{isGroupOpen:r,toggleGroup:s,extractRows:i}=ZO(),{isSelected:o,isSomeSelected:a,select:l}=xm(),{columns:u}=Em(),d=R(()=>i([e.item]));return()=>h("tr",{class:"v-data-table-group-header-row",style:{"--v-data-table-group-header-row-depth":e.item.depth}},[u.value.map(c=>{var f,p;if(c.key==="data-table-group"){const g=r(e.item)?"$expand":"$next",m=()=>s(e.item);return((f=n["data-table-group"])==null?void 0:f.call(n,{item:e.item,count:d.value.length,props:{icon:g,onClick:m}}))??h(up,{class:"v-data-table-group-header-row__column"},{default:()=>[h(re,{size:"small",variant:"text",icon:g,onClick:m},null),h("span",null,[e.item.value]),h("span",null,[_("("),d.value.length,_(")")])]})}if(c.key==="data-table-select"){const g=o(d.value),m=a(d.value)&&!g,y=b=>l(d.value,b);return((p=n["data-table-select"])==null?void 0:p.call(n,{props:{modelValue:g,indeterminate:m,"onUpdate:modelValue":y}}))??h("td",null,[h(yu,{modelValue:g,indeterminate:m,"onUpdate:modelValue":y},null)])}return h("td",null,null)})])}}),JX=de({index:Number,item:Object,cellProps:[Object,Function],onClick:zn(),onContextmenu:zn(),onDblclick:zn(),...nl()},"VDataTableRow"),ZX=xe()({name:"VDataTableRow",props:JX(),setup(e,t){let{slots:n}=t;const{displayClasses:r,mobile:s}=mi(e,"v-data-table__tr"),{isSelected:i,toggleSelect:o,someSelected:a,allSelected:l,selectAll:u}=xm(),{isExpanded:d,toggleExpand:c}=QO(),{toggleSort:f,sortBy:p,isSorted:g}=aM(),{columns:m}=Em();Ie(()=>h("tr",{class:["v-data-table__tr",{"v-data-table__tr--clickable":!!(e.onClick||e.onContextmenu||e.onDblclick)},r.value],onClick:e.onClick,onContextmenu:e.onContextmenu,onDblclick:e.onDblclick},[e.item&&m.value.map((y,b)=>{const w=e.item,S=`item.${y.key}`,P=`header.${y.key}`,E={index:e.index,item:w.raw,internalItem:w,value:Va(w.columns,y.key),column:y,isSelected:i,toggleSelect:o,isExpanded:d,toggleExpand:c},T={column:y,selectAll:u,isSorted:g,toggleSort:f,sortBy:p.value,someSelected:a.value,allSelected:l.value,getSortIcon:()=>""},C=typeof e.cellProps=="function"?e.cellProps({index:E.index,item:E.item,internalItem:E.internalItem,value:E.value,column:y}):e.cellProps,k=typeof y.cellProps=="function"?y.cellProps({index:E.index,item:E.item,internalItem:E.internalItem,value:E.value}):y.cellProps;return h(up,me({align:y.align,class:{"v-data-table__td--expanded-row":y.key==="data-table-expand","v-data-table__td--select-row":y.key==="data-table-select"},fixed:y.fixed,fixedOffset:y.fixedOffset,lastFixed:y.lastFixed,maxWidth:s.value?void 0:y.maxWidth,noPadding:y.key==="data-table-select"||y.key==="data-table-expand",nowrap:y.nowrap,width:s.value?void 0:y.width},C,k),{default:()=>{var I,M,O,A,D;if(n[S]&&!s.value)return(I=n[S])==null?void 0:I.call(n,E);if(y.key==="data-table-select")return((M=n["item.data-table-select"])==null?void 0:M.call(n,E))??h(yu,{disabled:!w.selectable,modelValue:i([w]),onClick:$t(()=>o(w),["stop"])},null);if(y.key==="data-table-expand")return((O=n["item.data-table-expand"])==null?void 0:O.call(n,E))??h(re,{icon:d(w)?"$collapse":"$expand",size:"small",variant:"text",onClick:$t(()=>c(w),["stop"])},null);const x=ae(E.value);return s.value?h(Re,null,[h("div",{class:"v-data-table__td-title"},[((A=n[P])==null?void 0:A.call(n,T))??y.title]),h("div",{class:"v-data-table__td-value"},[((D=n[S])==null?void 0:D.call(n,E))??x])]):x}})})]))}}),pM=de({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],...nl()},"VDataTableRows"),Uk=xe()({name:"VDataTableRows",inheritAttrs:!1,props:pM(),setup(e,t){let{attrs:n,slots:r}=t;const{columns:s}=Em(),{expandOnClick:i,toggleExpand:o,isExpanded:a}=QO(),{isSelected:l,toggleSelect:u}=xm(),{toggleGroup:d,isGroupOpen:c}=ZO(),{t:f}=es(),{mobile:p}=mi(e);return Ie(()=>{var g,m;return e.loading&&(!e.items.length||r.loading)?h("tr",{class:"v-data-table-rows-loading",key:"loading"},[h("td",{colspan:s.value.length},[((g=r.loading)==null?void 0:g.call(r))??f(e.loadingText)])]):!e.loading&&!e.items.length&&!e.hideNoData?h("tr",{class:"v-data-table-rows-no-data",key:"no-data"},[h("td",{colspan:s.value.length},[((m=r["no-data"])==null?void 0:m.call(r))??f(e.noDataText)])]):h(Re,null,[e.items.map((y,b)=>{var P;if(y.type==="group"){const E={index:b,item:y,columns:s.value,isExpanded:a,toggleExpand:o,isSelected:l,toggleSelect:u,toggleGroup:d,isGroupOpen:c};return r["group-header"]?r["group-header"](E):h(QX,me({key:`group-header_${y.id}`,item:y},B_(n,":group-header",()=>E)),r)}const w={index:b,item:y.raw,internalItem:y,columns:s.value,isExpanded:a,toggleExpand:o,isSelected:l,toggleSelect:u},S={...w,props:me({key:`item_${y.key??y.index}`,onClick:i.value?()=>{o(y)}:void 0,index:b,item:y,cellProps:e.cellProps,mobile:p.value},B_(n,":row",()=>w),typeof e.rowProps=="function"?e.rowProps({item:w.item,index:w.index,internalItem:w.internalItem}):e.rowProps)};return h(Re,{key:S.props.key},[r.item?r.item(S):h(ZX,S.props,r),a(y)&&((P=r["expanded-row"])==null?void 0:P.call(r,w))])})])}),{}}}),mM=de({fixedHeader:Boolean,fixedFooter:Boolean,height:[Number,String],hover:Boolean,...Ve(),...Lr(),...bt(),...Dt()},"VTable"),Gy=xe()({name:"VTable",props:mM(),setup(e,t){let{slots:n,emit:r}=t;const{themeClasses:s}=Xt(e),{densityClasses:i}=ys(e);return Ie(()=>h(e.tag,{class:["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},s.value,i.value,e.class],style:e.style},{default:()=>{var o,a,l;return[(o=n.top)==null?void 0:o.call(n),n.default?h("div",{class:"v-table__wrapper",style:{height:Ne(e.height)}},[h("table",null,[n.default()])]):(a=n.wrapper)==null?void 0:a.call(n),(l=n.bottom)==null?void 0:l.call(n)]}})),{}}}),eQ=de({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 tQ(e,t,n,r){const s=e.returnObject?t:er(t,e.itemValue),i=er(t,e.itemSelectable,!0),o=r.reduce((a,l)=>(l.key!=null&&(a[l.key]=er(t,l.value)),a),{});return{type:"item",key:e.returnObject?er(t,e.itemValue):s,index:n,value:s,selectable:i,columns:o,raw:t}}function nQ(e,t,n){return t.map((r,s)=>tQ(e,r,s,n))}function rQ(e,t){return{items:R(()=>nQ(e,e.items,t.value))}}const sQ=de({...pM(),hideDefaultBody:Boolean,hideDefaultFooter:Boolean,hideDefaultHeader:Boolean,width:[String,Number],search:String,...wX(),..._X(),...zX(),...eQ(),...DX(),...$X(),...hM(),...mM()},"DataTable"),iQ=de({...TX(),...sQ(),...uX(),...lM()},"VDataTable"),oQ=xe()({name:"VDataTable",props:iQ(),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:r}=t;const{groupBy:s}=kX(e),{sortBy:i,multiSort:o,mustSort:a}=FX(e),{page:l,itemsPerPage:u}=RX(e),{disableSort:d}=jo(e),{columns:c,headers:f,sortFunctions:p,sortRawFunctions:g,filterFunctions:m}=YX(e,{groupBy:s,showSelect:Te(e,"showSelect"),showExpand:Te(e,"showExpand")}),{items:y}=rQ(e,c),b=Te(e,"search"),{filteredItems:w}=dX(e,y,b,{transform:J=>J.columns,customKeyFilter:m}),{toggleSort:S}=NX({sortBy:i,multiSort:o,mustSort:a,page:l}),{sortByWithGroups:P,opened:E,extractRows:T,isGroupOpen:C,toggleGroup:k}=xX({groupBy:s,sortBy:i,disableSort:d}),{sortedItems:x}=BX(e,w,P,{transform:J=>({...J.raw,...J.columns}),sortFunctions:p,sortRawFunctions:g}),{flatItems:I}=CX(x,s,E),M=R(()=>I.value.length),{startIndex:O,stopIndex:A,pageCount:D,setItemsPerPage:V}=IX({page:l,itemsPerPage:u,itemsLength:M}),{paginatedItems:H}=OX({items:I,startIndex:O,stopIndex:A,itemsPerPage:u}),G=R(()=>T(H.value)),{isSelected:j,select:B,selectAll:W,toggleSelect:Z,someSelected:q,allSelected:K}=LX(e,{allItems:y,currentPage:G}),{isExpanded:pe,toggleExpand:ue}=SX(e);PX({page:l,itemsPerPage:u,sortBy:i,groupBy:s,search:b}),Dr({VDataTableRows:{hideNoData:Te(e,"hideNoData"),noDataText:Te(e,"noDataText"),loading:Te(e,"loading"),loadingText:Te(e,"loadingText")}});const le=R(()=>({page:l.value,itemsPerPage:u.value,sortBy:i.value,pageCount:D.value,toggleSort:S,setItemsPerPage:V,someSelected:q.value,allSelected:K.value,isSelected:j,select:B,selectAll:W,toggleSelect:Z,isExpanded:pe,toggleExpand:ue,isGroupOpen:C,toggleGroup:k,items:G.value.map(J=>J.raw),internalItems:G.value,groupedItems:H.value,columns:c.value,headers:f.value}));return Ie(()=>{const J=Bk.filterProps(e),be=Vk.filterProps(e),Se=Uk.filterProps(e),te=Gy.filterProps(e);return h(Gy,me({class:["v-data-table",{"v-data-table--show-select":e.showSelect,"v-data-table--loading":e.loading},e.class],style:e.style},te),{top:()=>{var Y;return(Y=r.top)==null?void 0:Y.call(r,le.value)},default:()=>{var Y,ze,F,N,ee,se;return r.default?r.default(le.value):h(Re,null,[(Y=r.colgroup)==null?void 0:Y.call(r,le.value),!e.hideDefaultHeader&&h("thead",{key:"thead"},[h(Vk,be,r)]),(ze=r.thead)==null?void 0:ze.call(r,le.value),!e.hideDefaultBody&&h("tbody",null,[(F=r["body.prepend"])==null?void 0:F.call(r,le.value),r.body?r.body(le.value):h(Uk,me(n,Se,{items:H.value}),r),(N=r["body.append"])==null?void 0:N.call(r,le.value)]),(ee=r.tbody)==null?void 0:ee.call(r,le.value),(se=r.tfoot)==null?void 0:se.call(r,le.value)])},bottom:()=>r.bottom?r.bottom(le.value):!e.hideDefaultFooter&&h(Re,null,[h(yn,null,null),h(Bk,J,{prepend:r["footer.prepend"]})])})}),{}}}),aQ=de({...Ve(),...M6()},"VForm"),eS=xe()({name:"VForm",props:aQ(),emits:{"update:modelValue":e=>!0,submit:e=>!0},setup(e,t){let{slots:n,emit:r}=t;const s=D6(e),i=U();function o(l){l.preventDefault(),s.reset()}function a(l){const u=l,d=s.validate();u.then=d.then.bind(d),u.catch=d.catch.bind(d),u.finally=d.finally.bind(d),r("submit",u),u.defaultPrevented||d.then(c=>{var p;let{valid:f}=c;f&&((p=i.value)==null||p.submit())}),u.preventDefault()}return Ie(()=>{var l;return h("form",{ref:i,class:["v-form",e.class],style:e.style,novalidate:!0,onReset:o,onSubmit:a},[(l=n.default)==null?void 0:l.call(n,s)])}),Wi(s,i)}}),lQ=de({disabled:Boolean,modelValue:{type:Boolean,default:null},...Fb()},"VHover"),Hk=xe()({name:"VHover",props:lQ(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const r=st(e,"modelValue"),{runOpenDelay:s,runCloseDelay:i}=Nb(e,o=>!e.disabled&&(r.value=o));return()=>{var o;return(o=n.default)==null?void 0:o.call(n,{isHovering:r.value,props:{onMouseenter:s,onMouseleave:i}})}}}),tS=Symbol.for("vuetify:v-stepper"),gM=de({color:String,disabled:{type:[Boolean,String],default:!1},prevText:{type:String,default:"$vuetify.stepper.prev"},nextText:{type:String,default:"$vuetify.stepper.next"}},"VStepperActions"),uQ=xe()({name:"VStepperActions",props:gM(),emits:{"click:prev":()=>!0,"click:next":()=>!0},setup(e,t){let{emit:n,slots:r}=t;const{t:s}=es();function i(){n("click:prev")}function o(){n("click:next")}return Ie(()=>{const a={onClick:i},l={onClick:o};return h("div",{class:"v-stepper-actions"},[h(At,{defaults:{VBtn:{disabled:["prev",!0].includes(e.disabled),text:s(e.prevText),variant:"text"}}},{default:()=>{var u;return[((u=r.prev)==null?void 0:u.call(r,{props:a}))??h(re,a,null)]}}),h(At,{defaults:{VBtn:{color:e.color,disabled:["next",!0].includes(e.disabled),text:s(e.nextText),variant:"tonal"}}},{default:()=>{var u;return[((u=r.next)==null?void 0:u.call(r,{props:l}))??h(re,l,null)]}})])}),{}}}),vM=Eu("v-stepper-header"),cQ=de({color:String,title:String,subtitle:String,complete:Boolean,completeIcon:{type:String,default:"$complete"},editable:Boolean,editIcon:{type:String,default:"$edit"},error:Boolean,errorIcon:{type:String,default:"$error"},icon:String,ripple:{type:[Boolean,Object],default:!0},rules:{type:Array,default:()=>[]}},"StepperItem"),dQ=de({...cQ(),...Pd()},"VStepperItem"),fQ=xe()({name:"VStepperItem",directives:{Ripple:Iu},props:dQ(),emits:{"group:selected":e=>!0},setup(e,t){let{slots:n}=t;const r=Td(e,tS,!0),s=R(()=>(r==null?void 0:r.value.value)??e.value),i=R(()=>e.rules.every(f=>f()===!0)),o=R(()=>!e.disabled&&e.editable),a=R(()=>!e.disabled&&e.editable),l=R(()=>e.error||!i.value),u=R(()=>e.complete||e.rules.length>0&&i.value),d=R(()=>l.value?e.errorIcon:u.value?e.completeIcon:r.isSelected.value&&e.editable?e.editIcon:e.icon),c=R(()=>({canEdit:a.value,hasError:l.value,hasCompleted:u.value,title:e.title,subtitle:e.subtitle,step:s.value,value:e.value}));return Ie(()=>{var y,b,w;const f=(!r||r.isSelected.value||u.value||a.value)&&!l.value&&!e.disabled,p=!!(e.title!=null||n.title),g=!!(e.subtitle!=null||n.subtitle);function m(){r==null||r.toggle()}return en(h("button",{class:["v-stepper-item",{"v-stepper-item--complete":u.value,"v-stepper-item--disabled":e.disabled,"v-stepper-item--error":l.value},r==null?void 0:r.selectedClass.value],disabled:!e.editable,onClick:m},[o.value&&Go(!0,"v-stepper-item"),h(lt,{key:"stepper-avatar",class:"v-stepper-item__avatar",color:f?e.color:void 0,size:24},{default:()=>{var S;return[((S=n.icon)==null?void 0:S.call(n,c.value))??(d.value?h(X,{icon:d.value},null):s.value)]}}),h("div",{class:"v-stepper-item__content"},[p&&h("div",{key:"title",class:"v-stepper-item__title"},[((y=n.title)==null?void 0:y.call(n,c.value))??e.title]),g&&h("div",{key:"subtitle",class:"v-stepper-item__subtitle"},[((b=n.subtitle)==null?void 0:b.call(n,c.value))??e.subtitle]),(w=n.default)==null?void 0:w.call(n,c.value)])]),[[mr("ripple"),e.ripple&&e.editable,null]])}),{}}}),hQ=de({...Ds(KO(),["continuous","nextIcon","prevIcon","showArrows","touch","mandatory"])},"VStepperWindow"),pQ=xe()({name:"VStepperWindow",props:hQ(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const r=Ye(tS,null),s=st(e,"modelValue"),i=R({get(){var o;return s.value!=null||!r?s.value:(o=r.items.value.find(a=>r.selected.value.includes(a.id)))==null?void 0:o.value},set(o){s.value=o}});return Ie(()=>{const o=$k.filterProps(e);return h($k,me({_as:"VStepperWindow"},o,{modelValue:i.value,"onUpdate:modelValue":a=>i.value=a,class:["v-stepper-window",e.class],style:e.style,mandatory:!1,touch:!1}),n)}),{}}}),mQ=de({...YO()},"VStepperWindowItem"),gQ=xe()({name:"VStepperWindowItem",props:mQ(),setup(e,t){let{slots:n}=t;return Ie(()=>{const r=Fk.filterProps(e);return h(Fk,me({_as:"VStepperWindowItem"},r,{class:["v-stepper-window-item",e.class],style:e.style}),n)}),{}}}),vQ=de({altLabels:Boolean,bgColor:String,completeIcon:String,editIcon:String,editable:Boolean,errorIcon:String,hideActions:Boolean,items:{type:Array,default:()=>[]},itemTitle:{type:String,default:"title"},itemValue:{type:String,default:"value"},nonLinear:Boolean,flat:Boolean,...nl()},"Stepper"),yQ=de({...vQ(),...Cd({mandatory:"force",selectedClass:"v-stepper-item--selected"}),...$O(),...fP(gM(),["prevText","nextText"])},"VStepper"),bQ=xe()({name:"VStepper",props:yQ(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const{items:r,next:s,prev:i,selected:o}=Cu(e,tS),{displayClasses:a,mobile:l}=mi(e),{completeIcon:u,editIcon:d,errorIcon:c,color:f,editable:p,prevText:g,nextText:m}=jo(e),y=R(()=>e.items.map((S,P)=>{const E=er(S,e.itemTitle,S),T=er(S,e.itemValue,P+1);return{title:E,value:T,raw:S}})),b=R(()=>r.value.findIndex(S=>o.value.includes(S.id))),w=R(()=>e.disabled?e.disabled:b.value===0?"prev":b.value===r.value.length-1?"next":!1);return Dr({VStepperItem:{editable:p,errorIcon:c,completeIcon:u,editIcon:d,prevText:g,nextText:m},VStepperActions:{color:f,disabled:w,prevText:g,nextText:m}}),Ie(()=>{const S=ap.filterProps(e),P=!!(n.header||e.items.length),E=e.items.length>0,T=!e.hideActions&&!!(E||n.actions);return h(ap,me(S,{color:e.bgColor,class:["v-stepper",{"v-stepper--alt-labels":e.altLabels,"v-stepper--flat":e.flat,"v-stepper--non-linear":e.nonLinear,"v-stepper--mobile":l.value},a.value,e.class],style:e.style}),{default:()=>{var C,k;return[P&&h(vM,{key:"stepper-header"},{default:()=>[y.value.map((x,I)=>{let{raw:M,...O}=x;return h(Re,null,[!!I&&h(yn,null,null),h(fQ,O,{default:n[`header-item.${O.value}`]??n.header,icon:n.icon,title:n.title,subtitle:n.subtitle})])})]}),E&&h(pQ,{key:"stepper-window"},{default:()=>[y.value.map(x=>h(gQ,{value:x.value},{default:()=>{var I,M;return((I=n[`item.${x.value}`])==null?void 0:I.call(n,x))??((M=n.item)==null?void 0:M.call(n,x))}}))]}),(C=n.default)==null?void 0:C.call(n,{prev:i,next:s}),T&&(((k=n.actions)==null?void 0:k.call(n,{next:s,prev:i}))??h(uQ,{key:"stepper-actions","onClick:prev":i,"onClick:next":s},n))]}})}),{prev:i,next:s}}}),wQ={class:"mt-4 mb-4"},SQ={key:0},_Q={key:1},kQ={key:0},xQ={key:1},EQ=["colspan"],CQ=Le({__name:"PrintersView",setup(e){const t=Mt(),n=Nt(),r=U(!1),s=rr(),i=Xi(),o=ku(),a=Yi(),l=U([]),u=U([]),d=U(""),c=U(""),f=U(),p=U(""),g=U([]),m=R(()=>a.hasFeature("printerGroupsApi")),y=R(()=>[{title:"Enabled",key:"enabled"},{title:"Printer Name",align:"start",sortable:!0,key:"name"},{title:"Floor",key:"floor",sortable:!1},...a.hasFeature("printerGroupsApi")?[{title:"Group(s)",key:"group",sortable:!0}]:[],{title:"Actions",key:"actions",sortable:!1},{title:"Socket Update",key:"socketupdate",sortable:!1},{title:"",key:"data-table-expand"}]);async function b(){if(r.value=!0,await a.loadFeatures(),a.hasFeature("printerGroupsApi")){const q=await gl.getGroupsWithPrinters();l.value=q}return r.value=!1,l}const w=Vw({queryKey:["printerGroups"],queryFn:b}),S=R(()=>{var K;if(!a.hasFeature("printerGroupsApi")||!((K=u.value)!=null&&K.length))return n.printers;const q=u.value.flatMap(pe=>pe.printers.map(ue=>ue.printerId))||[];return n.printers.filter(pe=>q.includes(pe.id))}),P=R(()=>s.printerCurrentEventReceivedAtById),E=R(()=>{if(!(!f.value&&f.value!==0))return l.value[f.value]}),T=q=>q?(Date.now()-q)/1e3:void 0,C=q=>l.value.filter(K=>K.printers.find(pe=>pe.printerId===q)),k=q=>l.value.filter(K=>!K.printers.find(pe=>pe.printerId===q)),x=q=>i.floorOfPrinter(q),I=q=>{n.setUpdateDialogPrinter(q),o.openDialogWithContext(Jt.AddOrUpdatePrinterDialog)},M=()=>{o.openDialogWithContext(Jt.AddOrUpdatePrinterDialog)},O=(q,K)=>{if(console.log(q,K),K.isExpanded){const pe=g.value.findIndex(ue=>ue===q.id);g.value.splice(pe,1)}else g.value.push(q.id.toString())},A=()=>{o.openDialogWithContext(Jt.BatchJsonCreate)},D=()=>{Fn(Jt.YamlImportExport).openDialog()},V=async()=>{var q,K;if(!((K=(q=d.value)==null?void 0:q.trim())!=null&&K.length))throw new Error("Please set a non-empty group name");await gl.createGroup(d.value.trim()),await w.refetch(),d.value="",t.info("Created group")},H=()=>{var q;E.value&&(c.value=(q=E.value)==null?void 0:q.name)},G=async q=>{var pe,ue;if(!(q!=null&&q.id))throw new Error("Group id was not defined");if(!l.value.find(le=>le.id===q.id))throw new Error("Group was not found, please reload the page");if(!((ue=(pe=c.value)==null?void 0:pe.trim())!=null&&ue.length))throw new Error("Please set a non-empty group name");await gl.updateGroupName(q.id,c.value.trim()),await w.refetch()},j=async q=>{const K=l.value.find(ue=>ue.id===q);if(!K)throw new Error("Group was not found, please reload the page");const pe=K.printers.length;pe>0&&!confirm(`This group contains ${pe} printers, are you sure to delete it?`)||(await gl.deleteGroup(q),await w.refetch(),t.info("Deleted group"))},B=async(q,K)=>{await gl.addPrinterToGroup(q,K),await w.refetch(),t.info("Added printer to group")},W=async(q,K)=>{await gl.deletePrinterFromGroup(q,K),await w.refetch(),t.info("Removed printer from group")},Z=async q=>{if(!q.id)throw new Error("Printer ID not set, cant toggle enabled");q.enabled=!q.enabled,await Wt.toggleEnabled(q.id,q.enabled)};return(q,K)=>{const pe=Pr("v-list-item-group");return $(),we("div",null,[h(yt,null,{default:v(()=>[h(an,null,{default:v(()=>[K[11]||(K[11]=_(" Printers ")),h(wn),m.value&&l.value.length?($(),Q(Bo,{key:0,modelValue:u.value,"onUpdate:modelValue":K[0]||(K[0]=ue=>u.value=ue),multiple:"",items:l.value,"item-title":"name","return-object":!0,placeholder:"Select group to filter by","prepend-icon":"filter_list",label:"Filter by groups"},null,8,["modelValue","items"])):ve("",!0),h(ct,{modelValue:p.value,"onUpdate:modelValue":K[1]||(K[1]=ue=>p.value=ue),class:"p-2",clearable:"",label:"Printer search","prepend-icon":"search","single-line":""},null,8,["modelValue"])]),_:1}),h(ie(oQ),{expanded:g.value,headers:y.value,items:S.value,search:p.value,"single-expand":"",class:"elevation-1","item-key":"id","show-expand":"","onClick:row":O},CC({"no-data":v(()=>[L("div",wQ,[S.value.length===0?($(),we("h3",SQ," No printer has been created yet. Create one here: ")):($(),we("h3",_Q," No printer has been found. Adjust your filters or search criteria. ")),h(oX)])]),top:v(()=>[h(sr,{flat:""},{default:v(()=>[h(mn,null,{default:v(()=>[_(" Showing "+ae(S.value.length||0)+" printers ",1)]),_:1}),h(re,{class:"ml-3",variant:"outlined",type:"button",onClick:K[2]||(K[2]=ue=>A())},{default:v(()=>[h(X,null,{default:v(()=>K[12]||(K[12]=[_("publish")])),_:1}),K[13]||(K[13]=_(" Import OctoFarm Printers "))]),_:1}),h(re,{class:"ml-3",variant:"outlined",type:"button",onClick:K[3]||(K[3]=ue=>M())},{default:v(()=>[h(X,null,{default:v(()=>K[14]||(K[14]=[_("add")])),_:1}),K[15]||(K[15]=_(" Create Printer "))]),_:1}),h(re,{class:"ml-3",color:"primary",type:"button",onClick:K[4]||(K[4]=ue=>D())},{default:v(()=>[h(X,null,{default:v(()=>K[16]||(K[16]=[_("publish")])),_:1}),K[17]||(K[17]=_(" Import/Export YAML "))]),_:1}),h(wn)]),_:1})]),"item.enabled":v(({item:ue})=>[h(lp,{modelValue:ue.enabled,"onUpdate:modelValue":le=>ue.enabled=le,color:"primary",dark:"",inset:"",onClickCapture:$t(le=>Z(ue),["stop"])},{default:v(()=>[_(ae(ue.enabled),1)]),_:2},1032,["modelValue","onUpdate:modelValue","onClickCapture"])]),"item.name":v(({item:ue})=>[h(kn,{color:"primary",dark:""},{default:v(()=>[_(ae(ue.name||ue.printerURL),1)]),_:2},1024)]),"item.floor":v(({item:ue})=>[ue.id?($(),Q(kn,{key:0,color:"primary"},{default:v(()=>{var le;return[_(ae((le=x(ue.id))==null?void 0:le.name),1)]}),_:2},1024)):ve("",!0)]),"item.actions":v(({item:ue})=>[h(JY,{printer:ue},null,8,["printer"]),h(rX,{printer:ue},null,8,["printer"]),h(sX,{printer:ue},null,8,["printer"]),h(iX,{printer:ue},null,8,["printer"]),h(aX,{printer:ue},null,8,["printer"]),h(tX,{printer:ue,"onUpdate:show":le=>I(ue)},null,8,["printer","onUpdate:show"])]),"item.socketupdate":v(({item:ue})=>[P.value[ue.id]?($(),we("span",kQ," Updated "+ae(T(P.value[ue.id]))+" seconds ago ",1)):($(),we("span",xQ," No update received (silence) "))]),"expanded-row":v(({item:ue,columns:le})=>[L("td",{colspan:le.length},[h(QY,{printer:ue},null,8,["printer"])],8,EQ)]),_:2},[m.value?{name:"item.group",fn:v(({item:ue})=>[($(!0),we(Re,null,Zt(C(ue.id),le=>($(),Q(kn,{key:le.id,closable:"",size:"small",class:"ml-2","onClick:close":J=>W(le.id,ue.id)},{default:v(()=>[_(ae(le.name),1)]),_:2},1032,["onClick:close"]))),128)),h(Wd,{"offset-y":""},{activator:v(({props:le})=>[h(kn,me({disabled:!l.value.length,class:"ml-2",size:"small"},le),{default:v(()=>[h(X,{size:"small"},{default:v(()=>K[18]||(K[18]=[_("add")])),_:1})]),_:2},1040,["disabled"])]),default:v(()=>[h(Kt,{density:"compact",style:{border:"1px solid dimgray"}},{default:v(()=>[h(hs,null,{default:v(()=>K[19]||(K[19]=[_(" ADD TO GROUP ")])),_:1}),h(pe,null,{default:v(()=>[($(!0),we(Re,null,Zt(k(ue.id),(le,J)=>($(),Q(Fe,{key:J,onClick:be=>B(le.id,ue.id)},{default:v(()=>[h(ht,null,{default:v(()=>[_(ae(le.name),1)]),_:2},1024)]),_:2},1032,["onClick"]))),128))]),_:2},1024)]),_:2},1024)]),_:2},1024)]),key:"0"}:void 0]),1032,["expanded","headers","items","search"])]),_:1}),m.value?($(),Q(yt,{key:0,class:"mt-4"},{default:v(()=>[h(an,null,{default:v(()=>K[20]||(K[20]=[_(" Printer Groups ")])),_:1}),h(nn,null,{default:v(()=>[K[26]||(K[26]=L("h3",null,"Existing groups:",-1)),h(Pn,null,{default:v(()=>[h(np,{modelValue:f.value,"onUpdate:modelValue":[K[5]||(K[5]=ue=>f.value=ue),K[6]||(K[6]=ue=>H())],"selected-class":"primary--text",column:""},{default:v(()=>[($(!0),we(Re,null,Zt(l.value,ue=>($(),Q(kn,{key:ue.id,size:"small",closable:"",class:"mr-3","onClick:close":le=>j(ue.id)},{default:v(()=>[_(ae(ue.name),1)]),_:2},1032,["onClick:close"]))),128))]),_:1},8,["modelValue"])]),_:1}),K[27]||(K[27]=L("h3",{class:"mt-3"},"Update group name",-1)),h(Pn,null,{default:v(()=>[E.value?ve("",!0):($(),Q(un,{key:0},{default:v(()=>K[21]||(K[21]=[_(" Select a group to update its name. ")])),_:1})),h(ct,{modelValue:c.value,"onUpdate:modelValue":K[7]||(K[7]=ue=>c.value=ue),disabled:!E.value,label:"Group Name",placeholder:"Type group name here"},{default:v(()=>K[22]||(K[22]=[_(" Name ")])),_:1},8,["modelValue","disabled"]),h(re,{onClick:K[8]||(K[8]=ue=>G(E.value))},{default:v(()=>K[23]||(K[23]=[_(" Update name ")])),_:1})]),_:1}),K[28]||(K[28]=L("h3",{class:"mt-3"},"Add group",-1)),h(Pn,null,{default:v(()=>[h(ct,{modelValue:d.value,"onUpdate:modelValue":K[9]||(K[9]=ue=>d.value=ue),label:"Group Name",placeholder:"Type group name here"},{default:v(()=>K[24]||(K[24]=[_(" Name ")])),_:1},8,["modelValue"]),h(re,{onClick:K[10]||(K[10]=ue=>V())},{default:v(()=>K[25]||(K[25]=[_(" Create new group ")])),_:1})]),_:1})]),_:1})]),_:1})):ve("",!0)])}}}),PQ=Le({__name:"SettingsView",setup(e){const t=U([{title:"Grid",icon:"grid_on",path:"/settings/grid",divider:!1},{title:"Floors",icon:"house_siding",path:"/settings/floors",divider:!0},{title:"OctoPrint",icon:"image",path:"/settings/octoprint",divider:!1},{title:"Emergency Commands",icon:"warning",path:"/settings/emergency-commands",divider:!0},{title:"Users",icon:"group",path:"/settings/user-management",divider:!1},{title:"Account",icon:"account_circle",path:"/settings/account",divider:!1},{title:"Server Protection",icon:"security",path:"/settings/server-protection",divider:!0},{title:"Software Upgrade",icon:"upgrade",path:"/settings/software-upgrade",divider:!1},{title:"Diagnostics",icon:"bug_report",path:"/settings/diagnostics",divider:!1},{title:"Experimental",icon:"settings_applications",path:"/settings/experimental",divider:!1}]);return(n,r)=>{const s=Pr("router-view");return $(),we("div",null,[h(at,{"no-gutters":""},{default:v(()=>[h(Rw,{permanent:!0},{default:v(()=>[h(Fe,null,{default:v(()=>[h(ht,{class:"text-h6"},{default:v(()=>r[0]||(r[0]=[_(" Settings ")])),_:1}),h(wt,null,{default:v(()=>r[1]||(r[1]=[_(" Adjust your Fdm Monster ")])),_:1})]),_:1}),h(yn),h(Kt,{density:"compact",nav:""},{default:v(()=>[($(!0),we(Re,null,Zt(ie(t),i=>($(),Q(Fe,{key:i.title,to:i.path,link:"","prepend-icon":i.icon,title:i.title,"router-link":"",style:ci(i.divider?"border-bottom: 1px solid gray":"")},null,8,["to","prepend-icon","title","style"]))),128))]),_:1})]),_:1}),h(Ue,null,{default:v(()=>[h(s)]),_:1})]),_:1})])}}});function TQ(e){const t=new Date(e);return new Intl.DateTimeFormat("default",{dateStyle:"long"}).format(t)}const RQ={key:0,class:"text--primary float-end mr-5 mt-2"},IQ={class:"text-grey-darken-4"},AQ={key:0,class:"text-success"},OQ={key:1,class:"text-error"},MQ={key:0},DQ={key:0},LQ={key:0},$Q={key:1},FQ={key:0},NQ={key:1},BQ=Le({__name:"UserManagementSettings",setup(e){const t=Mt(),n=U(!1),r=U(),s=U([]),i=U([]);async function o(){n.value=!0;try{r.value=await os.getProfile(),i.value=await os.listRoles(),s.value=await os.listUsers()}catch(m){throw n.value=!1,console.error(m),m}return n.value=!1,{users:s,roles:i,profile:r}}const a=Vw({queryKey:["userRolesProfile"],queryFn:o});function l(m){return m.map(y=>{var b;return(b=i.value.find(w=>w.id==y))==null?void 0:b.name})}function u(m){var y;return m.id==((y=r.value)==null?void 0:y.id)}async function d(m){if(confirm(`Are you sure you want to delete ${m.username}?`)){try{n.value=!0,await os.deleteUser(m.id),await a.refetch()}catch(y){throw n.value=!1,console.error(y),y}n.value=!1,t.info(`User ${m.username} deleted`)}}async function c(m,y=!0){if(m.isRootUser){t.error("You are not allowed to do perform this action on an owner");return}if(confirm(`Are you sure you want to ${y?"verify":"unverify"} ${m.username}?`)){try{n.value=!0,await os.setUserVerified(m.id,y),await a.refetch()}catch(b){throw n.value=!1,console.error(b),b}n.value=!1,t.info(y?`User ${m.username} verified`:`User ${m.username} unverified`)}}async function f(m,y=!0){var b;if((b=r.value)!=null&&b.isRootUser||t.error("You are not allowed to do perform this action as you're not an owner"),!!confirm(`You are about to ${y?"set":"remove"} owner rights on ${m.username}. Are you sure?`)){try{n.value=!0,await os.setRootUser(m.id,y),await a.refetch()}catch(w){throw n.value=!1,console.error(w),w}n.value=!1,t.info(y?`User ${m.username} set to owner`:`User ${m.username} is no longer owner`)}}async function p(m){try{n.value=!0,console.log(m.roles),console.log(m.roles.map(y=>typeof y)),await os.setUserRoles(m.id,m.roles),await a.refetch(),t.info(`Roles updated for ${m.username}`)}catch(y){throw n.value=!1,console.error(y),t.error(`Failed to update roles for ${m.username}`),y}n.value=!1}async function g(){await Fn(Jt.CreateUserDialog).openDialog()}return(m,y)=>{const b=Pr("v-list-item-content");return $(),Q(yt,null,{default:v(()=>[h(sr,{color:"primary"},{default:v(()=>{var w;return[h(lt,null,{default:v(()=>[h(X,null,{default:v(()=>y[1]||(y[1]=[_("settings")])),_:1})]),_:1}),h(mn,null,{default:v(()=>y[2]||(y[2]=[_(" Users ")])),_:1}),h(wn),h(re,{disabled:!((w=r.value)!=null&&w.isRootUser),class:"mt-2",color:"primary",onClick:y[0]||(y[0]=S=>g())},{default:v(()=>[h(X,{class:"mr-2"},{default:v(()=>y[3]||(y[3]=[_("verified_user")])),_:1}),y[4]||(y[4]=L("span",null,"Create verified user",-1))]),_:1},8,["disabled"])]}),_:1}),n.value?($(),Q(MO,{key:0,size:20,color:"#a70015",style:{margin:"250px",position:"absolute"}})):ve("",!0),h(Kt,{lines:"three"},{default:v(()=>[h(hs,null,{default:v(()=>y[5]||(y[5]=[_(" Showing all users ")])),_:1}),($(!0),we(Re,null,Zt(s.value,(w,S)=>($(),Q(Fe,{key:S,class:"pl-6",style:{"max-width":"800px","border-top":"1px solid grey","border-bottom":"1px solid grey"}},{default:v(()=>[h(b,{class:Ja(u(w)?"pl-6 grey darken-3":"pl-6 grey darken-4")},{default:v(()=>[h(ht,null,{default:v(()=>[_(" User '"+ae(w.username)+"' ",1),u(w)?($(),we("strong",RQ," Your account ")):ve("",!0)]),_:2},1024),h(wt),L("span",IQ,[L("ul",null,[L("li",null,[w.isVerified?($(),we("span",AQ," Account verified ")):($(),we("span",OQ," Account not verified "))]),L("li",null,"Created at "+ae(ie(TQ)(w.createdAt)),1),w.isDemoUser?($(),we("li",MQ,"Demo user account")):ve("",!0),L("li",null,[y[7]||(y[7]=_(" Role(s) ")),L("ul",null,[w.isRootUser?($(),we("li",DQ,[h(kn,{class:"mb-2 mt-2",size:"small"},{default:v(()=>y[6]||(y[6]=[_(" OWNER ")])),_:1})])):ve("",!0),($(!0),we(Re,null,Zt(l(w.roles),P=>($(),we("li",{key:P},[h(kn,{class:"mb-2 mt-2",size:"small"},{default:v(()=>[_(ae(P),1)]),_:2},1024)]))),128))])])])])]),_:2},1032,["class"]),h(sd,null,{default:v(()=>{var P,E;return[h(re,{disabled:u(w)||w.isRootUser,color:w.isVerified?"error darken-4":"success",onClick:T=>c(w,!w.isVerified)},{default:v(()=>[h(X,{class:"mr-2"},{default:v(()=>y[8]||(y[8]=[_("shield")])),_:1}),w.isVerified?ve("",!0):($(),we("span",LQ," Verify account ")),w.isVerified?($(),we("span",$Q," Un-verify account ")):ve("",!0)]),_:2},1032,["disabled","color","onClick"]),h(re,{color:w.isRootUser?"error darken-4":"success",disabled:u(w)||!((P=r.value)!=null&&P.isRootUser),class:"mt-2",onClick:T=>f(w,!w.isRootUser)},{default:v(()=>[h(X,{class:"mr-2"},{default:v(()=>y[9]||(y[9]=[_("key")])),_:1}),w.isRootUser?($(),we("span",FQ," Remove owner ")):ve("",!0),w.isRootUser?ve("",!0):($(),we("span",NQ," Set owner "))]),_:2},1032,["color","disabled","onClick"]),(E=r.value)!=null&&E.isRootUser?($(),Q(Bo,{key:0,items:i.value.map(T=>({text:T.name,value:T.id})),modelValue:w.roles,"onUpdate:modelValue":T=>w.roles=T,multiple:"",label:"Select roles",onChange:T=>p(w),class:"pt-6",style:{width:"15rem"}},null,8,["items","modelValue","onUpdate:modelValue","onChange"])):ve("",!0),h(re,{disabled:u(w)||w.isRootUser,class:"mt-2",color:"error-darken-2",onClick:T=>d(w)},{default:v(()=>[h(X,{class:"mr-2"},{default:v(()=>y[10]||(y[10]=[_("delete")])),_:1}),y[11]||(y[11]=_(" Delete "))]),_:2},1032,["disabled","onClick"])]}),_:2},1024)]),_:2},1024))),128))]),_:1})]),_:1})}}}),VQ=Le({name:"FdmSettings",props:{},setup:()=>({settingsStore:Bs(),printersStore:Nt(),snackbar:Mt(),printerStateStore:rr()}),data:()=>({fileHandlingSettings:{autoRemoveOldFilesBeforeUpload:!1,autoRemoveOldFilesAtBoot:!1,autoRemoveOldFilesCriteriumDays:7}}),computed:{},watch:{},async created(){const e=await Un.getSettings();this.fileHandlingSettings=e.printerFileClean},mounted(){},methods:{async updateTimeoutSettings(){var e,t,n;if(!((t=(e=this.settingsStore.settings)==null?void 0:e.timeout)!=null&&t.apiTimeout)){this.snackbar.error("Timeout not set");return}this.settingsStore.settings.timeout.apiTimeout<1e3?this.snackbar.error("Timeout is too low - please set it to at least 1000 milliseconds"):(await this.settingsStore.updateTimeoutSettings((n=this.settingsStore.settings)==null?void 0:n.timeout),this.snackbar.info("Timeout settings updated"))},async setFileCleanSettings(){const e=await Un.setFileCleanSettings(this.fileHandlingSettings);this.fileHandlingSettings=e.printerFileClean},async purgeFiles(){await Oo.purgeFiles(),this.snackbar.openInfoMessage({title:"Successfully purged all references to printer files!"})},async bulkDisableGCodeAnalysis(){const e=this.printerStateStore.onlinePrinters;this.snackbar.openInfoMessage({title:`Trying to disable gcode analysis for ${e.length} online printers.`});for(const t of Object.values(e))await jO.setGCodeAnalysis(t.id,!1);this.snackbar.openInfoMessage({title:`Finished disabling gcode analysis for ${e.length} online printers.`})}}});function UQ(e,t,n,r,s,i){return $(),Q(yt,null,{default:v(()=>[h(sr,{color:"primary"},{default:v(()=>[h(lt,null,{default:v(()=>[h(X,null,{default:v(()=>t[8]||(t[8]=[_("settings")])),_:1})]),_:1}),h(mn,null,{default:v(()=>t[9]||(t[9]=[_(" OctoPrint Settings ")])),_:1})]),_:1}),h(Kt,{lines:"three"},{default:v(()=>[h(Fe,null,{default:v(()=>[h(ht,null,{default:v(()=>t[10]||(t[10]=[_(" Pre-upload file cleanup ")])),_:1}),h(wt,null,{default:v(()=>[t[12]||(t[12]=_(" Automatically cleanup old files to ensure the SD card has enough space. ")),t[13]||(t[13]=L("br",null,null,-1)),h(On,{modelValue:e.fileHandlingSettings.autoRemoveOldFilesBeforeUpload,"onUpdate:modelValue":t[0]||(t[0]=o=>e.fileHandlingSettings.autoRemoveOldFilesBeforeUpload=o),label:"Remove old file before upload"},null,8,["modelValue"]),h(ct,{modelValue:e.fileHandlingSettings.autoRemoveOldFilesCriteriumDays,"onUpdate:modelValue":t[1]||(t[1]=o=>e.fileHandlingSettings.autoRemoveOldFilesCriteriumDays=o),disabled:!e.fileHandlingSettings.autoRemoveOldFilesBeforeUpload,label:"Amount of days to keep files",min:"0",variant:"outlined",type:"number"},null,8,["modelValue","disabled"]),h(On,{modelValue:e.fileHandlingSettings.autoRemoveOldFilesAtBoot,"onUpdate:modelValue":t[2]||(t[2]=o=>e.fileHandlingSettings.autoRemoveOldFilesAtBoot=o),label:"Remove old files when (re)booting the server"},null,8,["modelValue"]),h(re,{color:"primary",onClick:t[3]||(t[3]=o=>e.setFileCleanSettings())},{default:v(()=>t[11]||(t[11]=[_(" save file clean settings ")])),_:1})]),_:1})]),_:1}),h(Fe,null,{default:v(()=>{var o;return[h(ht,null,{default:v(()=>t[14]||(t[14]=[_(" Connection Timeout ")])),_:1}),(o=e.settingsStore.settings)!=null&&o.timeout?($(),Q(wt,{key:0},{default:v(()=>[t[16]||(t[16]=_(" The connection timeout is the amount of time in milliseconds that the server will wait for OctoPrint to respond before giving up ")),h(ct,{modelValue:e.settingsStore.settings.timeout.apiTimeout,"onUpdate:modelValue":t[4]||(t[4]=a=>e.settingsStore.settings.timeout.apiTimeout=a),label:"Connection Timeout",min:"0",variant:"outlined",type:"number"},null,8,["modelValue"]),h(re,{color:"primary",onClick:t[5]||(t[5]=a=>e.updateTimeoutSettings())},{default:v(()=>t[15]||(t[15]=[_(" save connection timeout ")])),_:1})]),_:1})):ve("",!0)]}),_:1}),h(Fe,null,{default:v(()=>[h(ht,null,{default:v(()=>t[17]||(t[17]=[_(" Clean file references ")])),_:1}),h(wt,null,{default:v(()=>[t[19]||(t[19]=_(" Clear out the file references for all printers - this does not remove them from OctoPrint! ")),t[20]||(t[20]=L("br",null,null,-1)),h(re,{color:"primary",onClick:t[6]||(t[6]=o=>e.purgeFiles())},{default:v(()=>t[18]||(t[18]=[_(" Purge file references ")])),_:1})]),_:1})]),_:1}),h(Fe,null,{default:v(()=>[h(ht,null,{default:v(()=>t[21]||(t[21]=[_(" Disable inefficient GCode analysis ")])),_:1}),h(wt,null,{default:v(()=>[t[23]||(t[23]=_(" Disable GCode analysis on all printers at once, preventing CPU intensive and inaccurate time/size estimates. ")),t[24]||(t[24]=L("br",null,null,-1)),h(re,{color:"primary",onClick:t[7]||(t[7]=o=>e.bulkDisableGCodeAnalysis())},{default:v(()=>t[22]||(t[22]=[_(" Bulk disable GCode Analysis ")])),_:1})]),_:1})]),_:1})]),_:1})]),_:1})}const HQ=ea(VQ,[["render",UQ]]),zQ=Le({name:"FloorSettings",props:{},setup:()=>({printersStore:Nt(),floorStore:Xi(),dialogsStore:ku(),snackbar:Mt()}),data:()=>({selectedItem:0,editedFloorName:"",editedFloorNumber:0}),computed:{floors(){return this.floorStore.floors},selectedFloor(){return this.floorStore.floors[this.selectedItem]},showAddedPrinters(){var e;return((e=this.selectedFloor.printers)==null?void 0:e.length)+1},unassignedPrinters(){return this.floorStore.floorlessPrinters}},watch:{},created(){},mounted(){},methods:{printerInFloor(e,t){if(!(e!=null&&e.printers))return;const n=e.printers[t-1];if(n)return this.printersStore.printer(n.printerId)},async createFloor(){this.dialogsStore.openDialogWithContext(Jt.AddOrUpdateFloorDialog)},setEditedPrinterFloorName(){this.editedFloorName=this.selectedFloor.name},setEditedPrinterFloorNumber(){this.editedFloorNumber=this.selectedFloor.floor},async updatePrinterFloorName(){var t;if(!((t=this.selectedFloor)!=null&&t.id))return;const{id:e}=this.selectedFloor;await this.floorStore.updateFloorName({floorId:e,name:this.editedFloorName}),this.snackbar.info("Floor name updated")},async updatePrinterFloorNumber(){var t;if(!((t=this.selectedFloor)!=null&&t.id))return;const{id:e}=this.selectedFloor;await this.floorStore.updateFloorNumber({floorId:e,floorNumber:this.editedFloorNumber}),this.snackbar.info("Floor level updated"),this.selectedItem=-1},async clickDeleteFloor(){var e;(e=this.selectedFloor)!=null&&e.id&&(await this.floorStore.deleteFloor(this.selectedFloor.id),this.snackbar.info("Floor deleted"))},async deletePrinterFromFloor(e,t){const n=this.printerInFloor(e,t);!(e!=null&&e.id)||!(n!=null&&n.id)||(await this.floorStore.deletePrinterFromFloor({floorId:e.id,printerId:n.id}),this.snackbar.info("Printer removed from floor"))}}}),jQ={key:1};function qQ(e,t,n,r,s,i){const o=Pr("v-list-item-action-text"),a=Pr("v-list-item-group"),l=Pr("v-edit-dialog"),u=Pr("v-list-item-content");return $(),Q(yt,null,{default:v(()=>[h(sr,{color:"primary"},{default:v(()=>[h(lt,null,{default:v(()=>[h(X,null,{default:v(()=>t[7]||(t[7]=[_("settings")])),_:1})]),_:1}),h(mn,null,{default:v(()=>t[8]||(t[8]=[_(" Floor Management ")])),_:1})]),_:1}),h(Kt,{subheader:"",lines:"three"},{default:v(()=>[h(hs,null,{default:v(()=>t[9]||(t[9]=[_(" Floors ")])),_:1}),h(Fe,null,{default:v(()=>[h(ht,null,{default:v(()=>t[10]||(t[10]=[_(" Create new floor ")])),_:1}),h(wt,null,{default:v(()=>[t[12]||(t[12]=_(" Creates an empty department/floor to view printer groups ")),t[13]||(t[13]=L("br",null,null,-1)),h(re,{color:"primary",onClick:t[0]||(t[0]=d=>e.createFloor())},{default:v(()=>t[11]||(t[11]=[_(" Create floor ")])),_:1})]),_:1})]),_:1})]),_:1}),h(yn),h(at,{"no-gutters":""},{default:v(()=>[h(Ue,null,{default:v(()=>[h(Kt,{density:"compact"},{default:v(()=>[h(a,{modelValue:e.selectedItem,"onUpdate:modelValue":t[1]||(t[1]=d=>e.selectedItem=d)},{default:v(()=>[($(!0),we(Re,null,Zt(e.floors,d=>($(),Q(Fe,{key:d.id},{default:v(()=>[h(ht,null,{default:v(()=>[_(ae(d.name),1)]),_:2},1024),h(wt,null,{default:v(()=>[_(ae(d.printers.length||0)+" assigned ",1)]),_:2},1024),h(o,null,{default:v(()=>[_(" Floor number: "+ae(d.floor),1)]),_:2},1024)]),_:2},1024))),128))]),_:1},8,["modelValue"])]),_:1})]),_:1}),h(Ue,null,{default:v(()=>[h(sr,null,{default:v(()=>[h(Hk,null,{default:v(({isHovering:d,props:c})=>[h(mn,Zg(Eh(c)),{default:v(()=>[e.selectedFloor?($(),Q(l,{key:0,onOpen:e.setEditedPrinterFloorName,onSave:e.updatePrinterFloorName},{input:v(()=>[h(ct,{modelValue:e.editedFloorName,"onUpdate:modelValue":t[2]||(t[2]=f=>e.editedFloorName=f),"return-value":e.editedFloorName,"onUpdate:returnValue":t[3]||(t[3]=f=>e.editedFloorName=f),counter:"",label:"Edit","single-line":""},null,8,["modelValue","return-value"])]),default:v(()=>[h(re,{color:"secondary"},{default:v(()=>[d?($(),Q(X,{key:0,size:"small"},{default:v(()=>t[14]||(t[14]=[_(" edit ")])),_:1})):ve("",!0),_(" "+ae(e.selectedFloor.name),1)]),_:2},1024)]),_:2},1032,["onOpen","onSave"])):($(),we("span",jQ," Select a floor on the left "))]),_:2},1040)]),_:1}),h(Hk,null,{default:v(({isHovering:d,props:c})=>[h(mn,Zg(Eh(c)),{default:v(()=>[e.selectedFloor?($(),Q(l,{key:0,onOpen:e.setEditedPrinterFloorNumber,onSave:e.updatePrinterFloorNumber},{input:v(()=>[h(ct,{modelValue:e.editedFloorNumber,"onUpdate:modelValue":t[4]||(t[4]=f=>e.editedFloorNumber=f),"return-value":e.editedFloorNumber,"onUpdate:returnValue":t[5]||(t[5]=f=>e.editedFloorNumber=f),label:"Edit","single-line":"",type:"number"},null,8,["modelValue","return-value"])]),default:v(()=>[h(re,{color:"secondary"},{default:v(()=>[d?($(),Q(X,{key:0,size:"small"},{default:v(()=>t[15]||(t[15]=[_(" edit ")])),_:1})):ve("",!0),_(" "+ae(e.selectedFloor.floor),1)]),_:2},1024)]),_:2},1032,["onOpen","onSave"])):ve("",!0)]),_:2},1040)]),_:1}),h(wn),e.selectedFloor?($(),Q(re,{key:0,color:"primary",onClick:t[6]||(t[6]=d=>e.clickDeleteFloor())},{default:v(()=>[h(X,null,{default:v(()=>t[16]||(t[16]=[_("delete")])),_:1}),t[17]||(t[17]=_(" Delete floor "))]),_:1})):ve("",!0)]),_:1}),e.selectedFloor?($(),Q(Kt,{key:0},{default:v(()=>[($(!0),we(Re,null,Zt(e.showAddedPrinters,d=>($(),Q(Fe,{key:d},{default:v(()=>[e.printerInFloor(e.selectedFloor,d)?($(),Q(u,{key:0},{default:v(()=>[h(ht,null,{default:v(()=>{var c;return[_(ae((c=e.printerInFloor(e.selectedFloor,d))==null?void 0:c.name),1)]}),_:2},1024)]),_:2},1024)):ve("",!0),e.printerInFloor(e.selectedFloor,d)?($(),Q(sd,{key:1},{default:v(()=>[h(re,{onClick:c=>e.deletePrinterFromFloor(e.selectedFloor,d)},{default:v(()=>[h(X,null,{default:v(()=>t[18]||(t[18]=[_("close")])),_:1}),t[19]||(t[19]=_(" Clear "))]),_:2},1032,["onClick"])]),_:2},1024)):ve("",!0)]),_:2},1024))),128))]),_:1})):ve("",!0)]),_:1})]),_:1})]),_:1})}const WQ=ea(zQ,[["render",qQ]]),GQ="/img/DavidZwart.jpg",yM="0.0.11",KQ={key:0},YQ={key:1},XQ=Le({__name:"AboutView",setup(e){const t=U(""),n=U(""),r=U(yM);return St(async()=>{const s=await ko.getVersion();t.value=s.version,n.value=s.monsterPi}),(s,i)=>($(),Q(yt,null,{default:v(()=>[h(an,null,{default:v(()=>i[0]||(i[0]=[_(" About FDM Monster"),L("strong",null," © ",-1)])),_:1}),h(nn,null,{default:v(()=>i[1]||(i[1]=[_(" The first prototype of FDM Monster"),L("strong",null," © ",-1),_(" was created by David Zwart in 2021 in collaboration with "),L("strong",null,[L("a",{href:"https://mtb3d.com"}," MTB3D ")],-1),_(". This open-source prototype proved a strong factor in process and logistics optimization for a 3D Printing company with 100+ printers. Due to it's success, we decided to keep it open-source and free! ")])),_:1}),h(nn,null,{default:v(()=>[i[4]||(i[4]=_(" The latest 3D Printing Farm server named FDM Monster has been tested for 2 years using a custom image for running 4 OctoPrint images on a Raspberry Pi. ")),i[5]||(i[5]=L("br",null,null,-1)),i[6]||(i[6]=_(" This version uses the famous ")),i[7]||(i[7]=L("a",{href:"https://nodejs.org/en",target:"_blank"},[L("strong",null," Node.js framework ")],-1)),i[8]||(i[8]=_(" together with Awilix and ExpressJS for its server, and ")),i[9]||(i[9]=L("a",{href:"https://vuejs.org/",target:"_blank"},[L("strong",null," Vue 2 ")],-1)),i[10]||(i[10]=_(" and ")),i[11]||(i[11]=L("a",{href:"https://next.vuetifyjs.com/",target:"_blank"},[L("strong",null," Vuetify 2 ")],-1)),i[12]||(i[12]=_(" to set a base for FDM Monster Client")),i[13]||(i[13]=L("strong",null," © ",-1)),i[14]||(i[14]=_(" - the webapp. ")),i[15]||(i[15]=L("br",null,null,-1)),i[16]||(i[16]=L("br",null,null,-1)),L("strong",null," Your server's version is: "+ae(t.value),1),i[17]||(i[17]=L("br",null,null,-1)),L("strong",null," Your clients's version is: "+ae(r.value),1),i[18]||(i[18]=L("br",null,null,-1)),n.value?($(),we("strong",KQ,[_(" Your MonsterPi version is: "+ae(n.value),1),i[2]||(i[2]=L("br",null,null,-1))])):($(),we("strong",YQ," No MonsterPi distro detected. ")),i[19]||(i[19]=L("br",null,null,-1)),h(re,{class:"mt-3",variant:"outlined",to:"/settings/software-upgrade"},{default:v(()=>i[3]||(i[3]=[_(" Visit Upgrade Settings ")])),_:1})]),_:1}),h(an,null,{default:v(()=>i[20]||(i[20]=[_(" Documentation ")])),_:1}),h(nn,null,{default:v(()=>[L("strong",null,[h(re,{color:"primary",href:"https://docs.fdm-monster.net",style:{color:"white"},target:"_blank"},{default:v(()=>[h(X,{class:"mr-2"},{default:v(()=>i[21]||(i[21]=[_("menu_book")])),_:1}),i[22]||(i[22]=_(" FDM Monster documentation site "))]),_:1})]),i[23]||(i[23]=L("br",null,null,-1))]),_:1}),h(an,null,{default:v(()=>[i[25]||(i[25]=_(" Bug reports ")),h(X,null,{default:v(()=>i[24]||(i[24]=[_("bug")])),_:1})]),_:1}),h(nn,null,{default:v(()=>i[26]||(i[26]=[_(" Did you find a bug, or a feature that needs work? We would love to hear about it! "),L("br",null,null,-1),L("strong",null," We have multiple ways to report it: ",-1),L("h3",null,[L("ul",{class:"ml-5"},[L("li",null,"Mail to davidzwa@gmail.com"),L("li",null,[L("a",{href:"https://discord.gg/mwA8uP8CMc",style:{color:"white"},target:"_blank"}," Discord server ")]),L("li",null,[L("strong",null,[L("a",{href:"https://github.com/fdm-monster/fdm-monster/issues",style:{color:"white"},target:"_blank"},[_(" FDM Monster "),L("strong",null," © "),_(" Github Issues ")])])]),L("li",null,[L("a",{href:"https://fdm-monster.net",style:{color:"white"},target:"_blank"}," Website ")])])],-1)])),_:1}),h(an,null,{default:v(()=>i[27]||(i[27]=[_(" About me ")])),_:1}),h(nn,null,{default:v(()=>i[28]||(i[28]=[L("img",{src:GQ,width:"150px"},null,-1),L("h4",{class:"mt-2"},[L("a",{href:"https://www.linkedin.com/in/david-zwart-88514083/",style:{color:"white"},target:"_blank"}," LinkedIn "),L("a",{class:"ml-2",href:"https://github.com/davidzwa",style:{color:"white"},target:"_blank"}," Github Profile ")],-1),_(" David Zwart MSc., post-graduate from the TU Delft (Embedded Systems), author of FDM Monster"),L("strong",null," © ",-1)])),_:1})]),_:1}))}});/*!
68
+ * @kurkle/color v0.3.2
69
+ * https://github.com/kurkle/color#readme
70
+ * (c) 2023 Jukka Kurkela
71
+ * Released under the MIT License
72
+ */function Gd(e){return e+.5|0}const xo=(e,t,n)=>Math.max(Math.min(e,n),t);function hc(e){return xo(Gd(e*2.55),0,255)}function Do(e){return xo(Gd(e*255),0,255)}function Ri(e){return xo(Gd(e/2.55)/100,0,1)}function zk(e){return xo(Gd(e*100),0,100)}const rs={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,A:10,B:11,C:12,D:13,E:14,F:15,a:10,b:11,c:12,d:13,e:14,f:15},Ky=[..."0123456789ABCDEF"],QQ=e=>Ky[e&15],JQ=e=>Ky[(e&240)>>4]+Ky[e&15],Cf=e=>(e&240)>>4===(e&15),ZQ=e=>Cf(e.r)&&Cf(e.g)&&Cf(e.b)&&Cf(e.a);function eJ(e){var t=e.length,n;return e[0]==="#"&&(t===4||t===5?n={r:255&rs[e[1]]*17,g:255&rs[e[2]]*17,b:255&rs[e[3]]*17,a:t===5?rs[e[4]]*17:255}:(t===7||t===9)&&(n={r:rs[e[1]]<<4|rs[e[2]],g:rs[e[3]]<<4|rs[e[4]],b:rs[e[5]]<<4|rs[e[6]],a:t===9?rs[e[7]]<<4|rs[e[8]]:255})),n}const tJ=(e,t)=>e<255?t(e):"";function nJ(e){var t=ZQ(e)?QQ:JQ;return e?"#"+t(e.r)+t(e.g)+t(e.b)+tJ(e.a,t):void 0}const rJ=/^(hsla?|hwb|hsv)\(\s*([-+.e\d]+)(?:deg)?[\s,]+([-+.e\d]+)%[\s,]+([-+.e\d]+)%(?:[\s,]+([-+.e\d]+)(%)?)?\s*\)$/;function bM(e,t,n){const r=t*Math.min(n,1-n),s=(i,o=(i+e/30)%12)=>n-r*Math.max(Math.min(o-3,9-o,1),-1);return[s(0),s(8),s(4)]}function sJ(e,t,n){const r=(s,i=(s+e/60)%6)=>n-n*t*Math.max(Math.min(i,4-i,1),0);return[r(5),r(3),r(1)]}function iJ(e,t,n){const r=bM(e,1,.5);let s;for(t+n>1&&(s=1/(t+n),t*=s,n*=s),s=0;s<3;s++)r[s]*=1-t-n,r[s]+=t;return r}function oJ(e,t,n,r,s){return e===s?(t-n)/r+(t<n?6:0):t===s?(n-e)/r+2:(e-t)/r+4}function nS(e){const n=e.r/255,r=e.g/255,s=e.b/255,i=Math.max(n,r,s),o=Math.min(n,r,s),a=(i+o)/2;let l,u,d;return i!==o&&(d=i-o,u=a>.5?d/(2-i-o):d/(i+o),l=oJ(n,r,s,d,i),l=l*60+.5),[l|0,u||0,a]}function rS(e,t,n,r){return(Array.isArray(t)?e(t[0],t[1],t[2]):e(t,n,r)).map(Do)}function sS(e,t,n){return rS(bM,e,t,n)}function aJ(e,t,n){return rS(iJ,e,t,n)}function lJ(e,t,n){return rS(sJ,e,t,n)}function wM(e){return(e%360+360)%360}function uJ(e){const t=rJ.exec(e);let n=255,r;if(!t)return;t[5]!==r&&(n=t[6]?hc(+t[5]):Do(+t[5]));const s=wM(+t[2]),i=+t[3]/100,o=+t[4]/100;return t[1]==="hwb"?r=aJ(s,i,o):t[1]==="hsv"?r=lJ(s,i,o):r=sS(s,i,o),{r:r[0],g:r[1],b:r[2],a:n}}function cJ(e,t){var n=nS(e);n[0]=wM(n[0]+t),n=sS(n),e.r=n[0],e.g=n[1],e.b=n[2]}function dJ(e){if(!e)return;const t=nS(e),n=t[0],r=zk(t[1]),s=zk(t[2]);return e.a<255?`hsla(${n}, ${r}%, ${s}%, ${Ri(e.a)})`:`hsl(${n}, ${r}%, ${s}%)`}const jk={x:"dark",Z:"light",Y:"re",X:"blu",W:"gr",V:"medium",U:"slate",A:"ee",T:"ol",S:"or",B:"ra",C:"lateg",D:"ights",R:"in",Q:"turquois",E:"hi",P:"ro",O:"al",N:"le",M:"de",L:"yello",F:"en",K:"ch",G:"arks",H:"ea",I:"ightg",J:"wh"},qk={OiceXe:"f0f8ff",antiquewEte:"faebd7",aqua:"ffff",aquamarRe:"7fffd4",azuY:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"0",blanKedOmond:"ffebcd",Xe:"ff",XeviTet:"8a2be2",bPwn:"a52a2a",burlywood:"deb887",caMtXe:"5f9ea0",KartYuse:"7fff00",KocTate:"d2691e",cSO:"ff7f50",cSnflowerXe:"6495ed",cSnsilk:"fff8dc",crimson:"dc143c",cyan:"ffff",xXe:"8b",xcyan:"8b8b",xgTMnPd:"b8860b",xWay:"a9a9a9",xgYF:"6400",xgYy:"a9a9a9",xkhaki:"bdb76b",xmagFta:"8b008b",xTivegYF:"556b2f",xSange:"ff8c00",xScEd:"9932cc",xYd:"8b0000",xsOmon:"e9967a",xsHgYF:"8fbc8f",xUXe:"483d8b",xUWay:"2f4f4f",xUgYy:"2f4f4f",xQe:"ced1",xviTet:"9400d3",dAppRk:"ff1493",dApskyXe:"bfff",dimWay:"696969",dimgYy:"696969",dodgerXe:"1e90ff",fiYbrick:"b22222",flSOwEte:"fffaf0",foYstWAn:"228b22",fuKsia:"ff00ff",gaRsbSo:"dcdcdc",ghostwEte:"f8f8ff",gTd:"ffd700",gTMnPd:"daa520",Way:"808080",gYF:"8000",gYFLw:"adff2f",gYy:"808080",honeyMw:"f0fff0",hotpRk:"ff69b4",RdianYd:"cd5c5c",Rdigo:"4b0082",ivSy:"fffff0",khaki:"f0e68c",lavFMr:"e6e6fa",lavFMrXsh:"fff0f5",lawngYF:"7cfc00",NmoncEffon:"fffacd",ZXe:"add8e6",ZcSO:"f08080",Zcyan:"e0ffff",ZgTMnPdLw:"fafad2",ZWay:"d3d3d3",ZgYF:"90ee90",ZgYy:"d3d3d3",ZpRk:"ffb6c1",ZsOmon:"ffa07a",ZsHgYF:"20b2aa",ZskyXe:"87cefa",ZUWay:"778899",ZUgYy:"778899",ZstAlXe:"b0c4de",ZLw:"ffffe0",lime:"ff00",limegYF:"32cd32",lRF:"faf0e6",magFta:"ff00ff",maPon:"800000",VaquamarRe:"66cdaa",VXe:"cd",VScEd:"ba55d3",VpurpN:"9370db",VsHgYF:"3cb371",VUXe:"7b68ee",VsprRggYF:"fa9a",VQe:"48d1cc",VviTetYd:"c71585",midnightXe:"191970",mRtcYam:"f5fffa",mistyPse:"ffe4e1",moccasR:"ffe4b5",navajowEte:"ffdead",navy:"80",Tdlace:"fdf5e6",Tive:"808000",TivedBb:"6b8e23",Sange:"ffa500",SangeYd:"ff4500",ScEd:"da70d6",pOegTMnPd:"eee8aa",pOegYF:"98fb98",pOeQe:"afeeee",pOeviTetYd:"db7093",papayawEp:"ffefd5",pHKpuff:"ffdab9",peru:"cd853f",pRk:"ffc0cb",plum:"dda0dd",powMrXe:"b0e0e6",purpN:"800080",YbeccapurpN:"663399",Yd:"ff0000",Psybrown:"bc8f8f",PyOXe:"4169e1",saddNbPwn:"8b4513",sOmon:"fa8072",sandybPwn:"f4a460",sHgYF:"2e8b57",sHshell:"fff5ee",siFna:"a0522d",silver:"c0c0c0",skyXe:"87ceeb",UXe:"6a5acd",UWay:"708090",UgYy:"708090",snow:"fffafa",sprRggYF:"ff7f",stAlXe:"4682b4",tan:"d2b48c",teO:"8080",tEstN:"d8bfd8",tomato:"ff6347",Qe:"40e0d0",viTet:"ee82ee",JHt:"f5deb3",wEte:"ffffff",wEtesmoke:"f5f5f5",Lw:"ffff00",LwgYF:"9acd32"};function fJ(){const e={},t=Object.keys(qk),n=Object.keys(jk);let r,s,i,o,a;for(r=0;r<t.length;r++){for(o=a=t[r],s=0;s<n.length;s++)i=n[s],a=a.replace(i,jk[i]);i=parseInt(qk[o],16),e[a]=[i>>16&255,i>>8&255,i&255]}return e}let Pf;function hJ(e){Pf||(Pf=fJ(),Pf.transparent=[0,0,0,0]);const t=Pf[e.toLowerCase()];return t&&{r:t[0],g:t[1],b:t[2],a:t.length===4?t[3]:255}}const pJ=/^rgba?\(\s*([-+.\d]+)(%)?[\s,]+([-+.e\d]+)(%)?[\s,]+([-+.e\d]+)(%)?(?:[\s,/]+([-+.e\d]+)(%)?)?\s*\)$/;function mJ(e){const t=pJ.exec(e);let n=255,r,s,i;if(t){if(t[7]!==r){const o=+t[7];n=t[8]?hc(o):xo(o*255,0,255)}return r=+t[1],s=+t[3],i=+t[5],r=255&(t[2]?hc(r):xo(r,0,255)),s=255&(t[4]?hc(s):xo(s,0,255)),i=255&(t[6]?hc(i):xo(i,0,255)),{r,g:s,b:i,a:n}}}function gJ(e){return e&&(e.a<255?`rgba(${e.r}, ${e.g}, ${e.b}, ${Ri(e.a)})`:`rgb(${e.r}, ${e.g}, ${e.b})`)}const Og=e=>e<=.0031308?e*12.92:Math.pow(e,1/2.4)*1.055-.055,vl=e=>e<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4);function vJ(e,t,n){const r=vl(Ri(e.r)),s=vl(Ri(e.g)),i=vl(Ri(e.b));return{r:Do(Og(r+n*(vl(Ri(t.r))-r))),g:Do(Og(s+n*(vl(Ri(t.g))-s))),b:Do(Og(i+n*(vl(Ri(t.b))-i))),a:e.a+n*(t.a-e.a)}}function Tf(e,t,n){if(e){let r=nS(e);r[t]=Math.max(0,Math.min(r[t]+r[t]*n,t===0?360:1)),r=sS(r),e.r=r[0],e.g=r[1],e.b=r[2]}}function SM(e,t){return e&&Object.assign(t||{},e)}function Wk(e){var t={r:0,g:0,b:0,a:255};return Array.isArray(e)?e.length>=3&&(t={r:e[0],g:e[1],b:e[2],a:255},e.length>3&&(t.a=Do(e[3]))):(t=SM(e,{r:0,g:0,b:0,a:1}),t.a=Do(t.a)),t}function yJ(e){return e.charAt(0)==="r"?mJ(e):uJ(e)}class cd{constructor(t){if(t instanceof cd)return t;const n=typeof t;let r;n==="object"?r=Wk(t):n==="string"&&(r=eJ(t)||hJ(t)||yJ(t)),this._rgb=r,this._valid=!!r}get valid(){return this._valid}get rgb(){var t=SM(this._rgb);return t&&(t.a=Ri(t.a)),t}set rgb(t){this._rgb=Wk(t)}rgbString(){return this._valid?gJ(this._rgb):void 0}hexString(){return this._valid?nJ(this._rgb):void 0}hslString(){return this._valid?dJ(this._rgb):void 0}mix(t,n){if(t){const r=this.rgb,s=t.rgb;let i;const o=n===i?.5:n,a=2*o-1,l=r.a-s.a,u=((a*l===-1?a:(a+l)/(1+a*l))+1)/2;i=1-u,r.r=255&u*r.r+i*s.r+.5,r.g=255&u*r.g+i*s.g+.5,r.b=255&u*r.b+i*s.b+.5,r.a=o*r.a+(1-o)*s.a,this.rgb=r}return this}interpolate(t,n){return t&&(this._rgb=vJ(this._rgb,t._rgb,n)),this}clone(){return new cd(this.rgb)}alpha(t){return this._rgb.a=Do(t),this}clearer(t){const n=this._rgb;return n.a*=1-t,this}greyscale(){const t=this._rgb,n=Gd(t.r*.3+t.g*.59+t.b*.11);return t.r=t.g=t.b=n,this}opaquer(t){const n=this._rgb;return n.a*=1+t,this}negate(){const t=this._rgb;return t.r=255-t.r,t.g=255-t.g,t.b=255-t.b,this}lighten(t){return Tf(this._rgb,2,t),this}darken(t){return Tf(this._rgb,2,-t),this}saturate(t){return Tf(this._rgb,1,t),this}desaturate(t){return Tf(this._rgb,1,-t),this}rotate(t){return cJ(this._rgb,t),this}}/*!
73
+ * Chart.js v4.4.6
74
+ * https://www.chartjs.org
75
+ * (c) 2024 Chart.js Contributors
76
+ * Released under the MIT License
77
+ */function Si(){}const bJ=(()=>{let e=0;return()=>e++})();function Lt(e){return e===null||typeof e>"u"}function on(e){if(Array.isArray&&Array.isArray(e))return!0;const t=Object.prototype.toString.call(e);return t.slice(0,7)==="[object"&&t.slice(-6)==="Array]"}function _t(e){return e!==null&&Object.prototype.toString.call(e)==="[object Object]"}function Mn(e){return(typeof e=="number"||e instanceof Number)&&isFinite(+e)}function Hr(e,t){return Mn(e)?e:t}function Ct(e,t){return typeof e>"u"?t:e}const wJ=(e,t)=>typeof e=="string"&&e.endsWith("%")?parseFloat(e)/100*t:+e;function jt(e,t,n){if(e&&typeof e.call=="function")return e.apply(n,t)}function It(e,t,n,r){let s,i,o;if(on(e))for(i=e.length,s=0;s<i;s++)t.call(n,e[s],s);else if(_t(e))for(o=Object.keys(e),i=o.length,s=0;s<i;s++)t.call(n,e[o[s]],o[s])}function cp(e,t){let n,r,s,i;if(!e||!t||e.length!==t.length)return!1;for(n=0,r=e.length;n<r;++n)if(s=e[n],i=t[n],s.datasetIndex!==i.datasetIndex||s.index!==i.index)return!1;return!0}function dp(e){if(on(e))return e.map(dp);if(_t(e)){const t=Object.create(null),n=Object.keys(e),r=n.length;let s=0;for(;s<r;++s)t[n[s]]=dp(e[n[s]]);return t}return e}function _M(e){return["__proto__","prototype","constructor"].indexOf(e)===-1}function SJ(e,t,n,r){if(!_M(e))return;const s=t[e],i=n[e];_t(s)&&_t(i)?dd(s,i,r):t[e]=dp(i)}function dd(e,t,n){const r=on(t)?t:[t],s=r.length;if(!_t(e))return e;n=n||{};const i=n.merger||SJ;let o;for(let a=0;a<s;++a){if(o=r[a],!_t(o))continue;const l=Object.keys(o);for(let u=0,d=l.length;u<d;++u)i(l[u],e,o,n)}return e}function Oc(e,t){return dd(e,t,{merger:_J})}function _J(e,t,n){if(!_M(e))return;const r=t[e],s=n[e];_t(r)&&_t(s)?Oc(r,s):Object.prototype.hasOwnProperty.call(t,e)||(t[e]=dp(s))}const Gk={"":e=>e,x:e=>e.x,y:e=>e.y};function kJ(e){const t=e.split("."),n=[];let r="";for(const s of t)r+=s,r.endsWith("\\")?r=r.slice(0,-1)+".":(n.push(r),r="");return n}function xJ(e){const t=kJ(e);return n=>{for(const r of t){if(r==="")break;n=n&&n[r]}return n}}function Su(e,t){return(Gk[t]||(Gk[t]=xJ(t)))(e)}function iS(e){return e.charAt(0).toUpperCase()+e.slice(1)}const fd=e=>typeof e<"u",Vo=e=>typeof e=="function",Kk=(e,t)=>{if(e.size!==t.size)return!1;for(const n of e)if(!t.has(n))return!1;return!0};function EJ(e){return e.type==="mouseup"||e.type==="click"||e.type==="contextmenu"}const $n=Math.PI,ui=2*$n,fp=Number.POSITIVE_INFINITY,CJ=$n/180,Xr=$n/2,aa=$n/4,Yk=$n*2/3,Eo=Math.log10,Lo=Math.sign;function ph(e,t,n){return Math.abs(e-t)<n}function Xk(e){const t=Math.round(e);e=ph(e,t,e/1e3)?t:e;const n=Math.pow(10,Math.floor(Eo(e))),r=e/n;return(r<=1?1:r<=2?2:r<=5?5:10)*n}function PJ(e){const t=[],n=Math.sqrt(e);let r;for(r=1;r<n;r++)e%r===0&&(t.push(r),t.push(e/r));return n===(n|0)&&t.push(n),t.sort((s,i)=>s-i).pop(),t}function hp(e){return!isNaN(parseFloat(e))&&isFinite(e)}function TJ(e,t){const n=Math.round(e);return n-t<=e&&n+t>=e}function kM(e,t,n){let r,s,i;for(r=0,s=e.length;r<s;r++)i=e[r][n],isNaN(i)||(t.min=Math.min(t.min,i),t.max=Math.max(t.max,i))}function Co(e){return e*($n/180)}function oS(e){return e*(180/$n)}function Qk(e){if(!Mn(e))return;let t=1,n=0;for(;Math.round(e*t)/t!==e;)t*=10,n++;return n}function RJ(e,t){const n=t.x-e.x,r=t.y-e.y,s=Math.sqrt(n*n+r*r);let i=Math.atan2(r,n);return i<-.5*$n&&(i+=ui),{angle:i,distance:s}}function IJ(e,t){return Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2))}function Xs(e){return(e%ui+ui)%ui}function AJ(e,t,n,r){const s=Xs(e),i=Xs(t),o=Xs(n),a=Xs(i-s),l=Xs(o-s),u=Xs(s-i),d=Xs(s-o);return s===i||s===o||r&&i===o||a>l&&u<d}function Ps(e,t,n){return Math.max(t,Math.min(n,e))}function OJ(e){return Ps(e,-32768,32767)}function Dl(e,t,n,r=1e-6){return e>=Math.min(t,n)-r&&e<=Math.max(t,n)+r}function aS(e,t,n){n=n||(o=>e[o]<t);let r=e.length-1,s=0,i;for(;r-s>1;)i=s+r>>1,n(i)?s=i:r=i;return{lo:s,hi:r}}const Yy=(e,t,n,r)=>aS(e,n,r?s=>{const i=e[s][t];return i<n||i===n&&e[s+1][t]===n}:s=>e[s][t]<n),MJ=(e,t,n)=>aS(e,n,r=>e[r][t]>=n);function DJ(e,t,n){let r=0,s=e.length;for(;r<s&&e[r]<t;)r++;for(;s>r&&e[s-1]>n;)s--;return r>0||s<e.length?e.slice(r,s):e}const xM=["push","pop","shift","splice","unshift"];function LJ(e,t){if(e._chartjs){e._chartjs.listeners.push(t);return}Object.defineProperty(e,"_chartjs",{configurable:!0,enumerable:!1,value:{listeners:[t]}}),xM.forEach(n=>{const r="_onData"+iS(n),s=e[n];Object.defineProperty(e,n,{configurable:!0,enumerable:!1,value(...i){const o=s.apply(this,i);return e._chartjs.listeners.forEach(a=>{typeof a[r]=="function"&&a[r](...i)}),o}})})}function Jk(e,t){const n=e._chartjs;if(!n)return;const r=n.listeners,s=r.indexOf(t);s!==-1&&r.splice(s,1),!(r.length>0)&&(xM.forEach(i=>{delete e[i]}),delete e._chartjs)}function EM(e){const t=new Set(e);return t.size===e.length?e:Array.from(t)}const CM=function(){return typeof window>"u"?function(e){return e()}:window.requestAnimationFrame}();function PM(e,t){let n=[],r=!1;return function(...s){n=s,r||(r=!0,CM.call(window,()=>{r=!1,e.apply(t,n)}))}}function $J(e,t){let n;return function(...r){return t?(clearTimeout(n),n=setTimeout(e,t,r)):e.apply(this,r),t}}const lS=e=>e==="start"?"left":e==="end"?"right":"center",Yn=(e,t,n)=>e==="start"?t:e==="end"?n:(t+n)/2,FJ=(e,t,n,r)=>e===(r?"left":"right")?n:e==="center"?(t+n)/2:t,Rf=e=>e===0||e===1,Zk=(e,t,n)=>-(Math.pow(2,10*(e-=1))*Math.sin((e-t)*ui/n)),ex=(e,t,n)=>Math.pow(2,-10*e)*Math.sin((e-t)*ui/n)+1,Mc={linear:e=>e,easeInQuad:e=>e*e,easeOutQuad:e=>-e*(e-2),easeInOutQuad:e=>(e/=.5)<1?.5*e*e:-.5*(--e*(e-2)-1),easeInCubic:e=>e*e*e,easeOutCubic:e=>(e-=1)*e*e+1,easeInOutCubic:e=>(e/=.5)<1?.5*e*e*e:.5*((e-=2)*e*e+2),easeInQuart:e=>e*e*e*e,easeOutQuart:e=>-((e-=1)*e*e*e-1),easeInOutQuart:e=>(e/=.5)<1?.5*e*e*e*e:-.5*((e-=2)*e*e*e-2),easeInQuint:e=>e*e*e*e*e,easeOutQuint:e=>(e-=1)*e*e*e*e+1,easeInOutQuint:e=>(e/=.5)<1?.5*e*e*e*e*e:.5*((e-=2)*e*e*e*e+2),easeInSine:e=>-Math.cos(e*Xr)+1,easeOutSine:e=>Math.sin(e*Xr),easeInOutSine:e=>-.5*(Math.cos($n*e)-1),easeInExpo:e=>e===0?0:Math.pow(2,10*(e-1)),easeOutExpo:e=>e===1?1:-Math.pow(2,-10*e)+1,easeInOutExpo:e=>Rf(e)?e:e<.5?.5*Math.pow(2,10*(e*2-1)):.5*(-Math.pow(2,-10*(e*2-1))+2),easeInCirc:e=>e>=1?e:-(Math.sqrt(1-e*e)-1),easeOutCirc:e=>Math.sqrt(1-(e-=1)*e),easeInOutCirc:e=>(e/=.5)<1?-.5*(Math.sqrt(1-e*e)-1):.5*(Math.sqrt(1-(e-=2)*e)+1),easeInElastic:e=>Rf(e)?e:Zk(e,.075,.3),easeOutElastic:e=>Rf(e)?e:ex(e,.075,.3),easeInOutElastic(e){return Rf(e)?e:e<.5?.5*Zk(e*2,.1125,.45):.5+.5*ex(e*2-1,.1125,.45)},easeInBack(e){return e*e*((1.70158+1)*e-1.70158)},easeOutBack(e){return(e-=1)*e*((1.70158+1)*e+1.70158)+1},easeInOutBack(e){let t=1.70158;return(e/=.5)<1?.5*(e*e*(((t*=1.525)+1)*e-t)):.5*((e-=2)*e*(((t*=1.525)+1)*e+t)+2)},easeInBounce:e=>1-Mc.easeOutBounce(1-e),easeOutBounce(e){return e<1/2.75?7.5625*e*e:e<2/2.75?7.5625*(e-=1.5/2.75)*e+.75:e<2.5/2.75?7.5625*(e-=2.25/2.75)*e+.9375:7.5625*(e-=2.625/2.75)*e+.984375},easeInOutBounce:e=>e<.5?Mc.easeInBounce(e*2)*.5:Mc.easeOutBounce(e*2-1)*.5+.5};function TM(e){if(e&&typeof e=="object"){const t=e.toString();return t==="[object CanvasPattern]"||t==="[object CanvasGradient]"}return!1}function tx(e){return TM(e)?e:new cd(e)}function Mg(e){return TM(e)?e:new cd(e).saturate(.5).darken(.1).hexString()}const NJ=["x","y","borderWidth","radius","tension"],BJ=["color","borderColor","backgroundColor"];function VJ(e){e.set("animation",{delay:void 0,duration:1e3,easing:"easeOutQuart",fn:void 0,from:void 0,loop:void 0,to:void 0,type:void 0}),e.describe("animation",{_fallback:!1,_indexable:!1,_scriptable:t=>t!=="onProgress"&&t!=="onComplete"&&t!=="fn"}),e.set("animations",{colors:{type:"color",properties:BJ},numbers:{type:"number",properties:NJ}}),e.describe("animations",{_fallback:"animation"}),e.set("transitions",{active:{animation:{duration:400}},resize:{animation:{duration:0}},show:{animations:{colors:{from:"transparent"},visible:{type:"boolean",duration:0}}},hide:{animations:{colors:{to:"transparent"},visible:{type:"boolean",easing:"linear",fn:t=>t|0}}}})}function UJ(e){e.set("layout",{autoPadding:!0,padding:{top:0,right:0,bottom:0,left:0}})}const nx=new Map;function HJ(e,t){t=t||{};const n=e+JSON.stringify(t);let r=nx.get(n);return r||(r=new Intl.NumberFormat(e,t),nx.set(n,r)),r}function uS(e,t,n){return HJ(t,n).format(e)}const RM={values(e){return on(e)?e:""+e},numeric(e,t,n){if(e===0)return"0";const r=this.chart.options.locale;let s,i=e;if(n.length>1){const u=Math.max(Math.abs(n[0].value),Math.abs(n[n.length-1].value));(u<1e-4||u>1e15)&&(s="scientific"),i=zJ(e,n)}const o=Eo(Math.abs(i)),a=isNaN(o)?1:Math.max(Math.min(-1*Math.floor(o),20),0),l={notation:s,minimumFractionDigits:a,maximumFractionDigits:a};return Object.assign(l,this.options.ticks.format),uS(e,r,l)},logarithmic(e,t,n){if(e===0)return"0";const r=n[t].significand||e/Math.pow(10,Math.floor(Eo(e)));return[1,2,3,5,10,15].includes(r)||t>.8*n.length?RM.numeric.call(this,e,t,n):""}};function zJ(e,t){let n=t.length>3?t[2].value-t[1].value:t[1].value-t[0].value;return Math.abs(n)>=1&&e!==Math.floor(e)&&(n=e-Math.floor(e)),n}var Cm={formatters:RM};function jJ(e){e.set("scale",{display:!0,offset:!1,reverse:!1,beginAtZero:!1,bounds:"ticks",clip:!0,grace:0,grid:{display:!0,lineWidth:1,drawOnChartArea:!0,drawTicks:!0,tickLength:8,tickWidth:(t,n)=>n.lineWidth,tickColor:(t,n)=>n.color,offset:!1},border:{display:!0,dash:[],dashOffset:0,width:1},title:{display:!1,text:"",padding:{top:4,bottom:4}},ticks:{minRotation:0,maxRotation:50,mirror:!1,textStrokeWidth:0,textStrokeColor:"",padding:3,display:!0,autoSkip:!0,autoSkipPadding:3,labelOffset:0,callback:Cm.formatters.values,minor:{},major:{},align:"center",crossAlign:"near",showLabelBackdrop:!1,backdropColor:"rgba(255, 255, 255, 0.75)",backdropPadding:2}}),e.route("scale.ticks","color","","color"),e.route("scale.grid","color","","borderColor"),e.route("scale.border","color","","borderColor"),e.route("scale.title","color","","color"),e.describe("scale",{_fallback:!1,_scriptable:t=>!t.startsWith("before")&&!t.startsWith("after")&&t!=="callback"&&t!=="parser",_indexable:t=>t!=="borderDash"&&t!=="tickBorderDash"&&t!=="dash"}),e.describe("scales",{_fallback:"scale"}),e.describe("scale.ticks",{_scriptable:t=>t!=="backdropPadding"&&t!=="callback",_indexable:t=>t!=="backdropPadding"})}const Xa=Object.create(null),Xy=Object.create(null);function Dc(e,t){if(!t)return e;const n=t.split(".");for(let r=0,s=n.length;r<s;++r){const i=n[r];e=e[i]||(e[i]=Object.create(null))}return e}function Dg(e,t,n){return typeof t=="string"?dd(Dc(e,t),n):dd(Dc(e,""),t)}class qJ{constructor(t,n){this.animation=void 0,this.backgroundColor="rgba(0,0,0,0.1)",this.borderColor="rgba(0,0,0,0.1)",this.color="#666",this.datasets={},this.devicePixelRatio=r=>r.chart.platform.getDevicePixelRatio(),this.elements={},this.events=["mousemove","mouseout","click","touchstart","touchmove"],this.font={family:"'Helvetica Neue', 'Helvetica', 'Arial', sans-serif",size:12,style:"normal",lineHeight:1.2,weight:null},this.hover={},this.hoverBackgroundColor=(r,s)=>Mg(s.backgroundColor),this.hoverBorderColor=(r,s)=>Mg(s.borderColor),this.hoverColor=(r,s)=>Mg(s.color),this.indexAxis="x",this.interaction={mode:"nearest",intersect:!0,includeInvisible:!1},this.maintainAspectRatio=!0,this.onHover=null,this.onClick=null,this.parsing=!0,this.plugins={},this.responsive=!0,this.scale=void 0,this.scales={},this.showLine=!0,this.drawActiveElementsOnTop=!0,this.describe(t),this.apply(n)}set(t,n){return Dg(this,t,n)}get(t){return Dc(this,t)}describe(t,n){return Dg(Xy,t,n)}override(t,n){return Dg(Xa,t,n)}route(t,n,r,s){const i=Dc(this,t),o=Dc(this,r),a="_"+n;Object.defineProperties(i,{[a]:{value:i[n],writable:!0},[n]:{enumerable:!0,get(){const l=this[a],u=o[s];return _t(l)?Object.assign({},u,l):Ct(l,u)},set(l){this[a]=l}}})}apply(t){t.forEach(n=>n(this))}}var fn=new qJ({_scriptable:e=>!e.startsWith("on"),_indexable:e=>e!=="events",hover:{_fallback:"interaction"},interaction:{_scriptable:!1,_indexable:!1}},[VJ,UJ,jJ]);function WJ(e){return!e||Lt(e.size)||Lt(e.family)?null:(e.style?e.style+" ":"")+(e.weight?e.weight+" ":"")+e.size+"px "+e.family}function pp(e,t,n,r,s){let i=t[s];return i||(i=t[s]=e.measureText(s).width,n.push(s)),i>r&&(r=i),r}function GJ(e,t,n,r){r=r||{};let s=r.data=r.data||{},i=r.garbageCollect=r.garbageCollect||[];r.font!==t&&(s=r.data={},i=r.garbageCollect=[],r.font=t),e.save(),e.font=t;let o=0;const a=n.length;let l,u,d,c,f;for(l=0;l<a;l++)if(c=n[l],c!=null&&!on(c))o=pp(e,s,i,o,c);else if(on(c))for(u=0,d=c.length;u<d;u++)f=c[u],f!=null&&!on(f)&&(o=pp(e,s,i,o,f));e.restore();const p=i.length/2;if(p>n.length){for(l=0;l<p;l++)delete s[i[l]];i.splice(0,p)}return o}function la(e,t,n){const r=e.currentDevicePixelRatio,s=n!==0?Math.max(n/2,.5):0;return Math.round((t-s)*r)/r+s}function rx(e,t){!t&&!e||(t=t||e.getContext("2d"),t.save(),t.resetTransform(),t.clearRect(0,0,e.width,e.height),t.restore())}function sx(e,t,n,r){IM(e,t,n,r,null)}function IM(e,t,n,r,s){let i,o,a,l,u,d,c,f;const p=t.pointStyle,g=t.rotation,m=t.radius;let y=(g||0)*CJ;if(p&&typeof p=="object"&&(i=p.toString(),i==="[object HTMLImageElement]"||i==="[object HTMLCanvasElement]")){e.save(),e.translate(n,r),e.rotate(y),e.drawImage(p,-p.width/2,-p.height/2,p.width,p.height),e.restore();return}if(!(isNaN(m)||m<=0)){switch(e.beginPath(),p){default:s?e.ellipse(n,r,s/2,m,0,0,ui):e.arc(n,r,m,0,ui),e.closePath();break;case"triangle":d=s?s/2:m,e.moveTo(n+Math.sin(y)*d,r-Math.cos(y)*m),y+=Yk,e.lineTo(n+Math.sin(y)*d,r-Math.cos(y)*m),y+=Yk,e.lineTo(n+Math.sin(y)*d,r-Math.cos(y)*m),e.closePath();break;case"rectRounded":u=m*.516,l=m-u,o=Math.cos(y+aa)*l,c=Math.cos(y+aa)*(s?s/2-u:l),a=Math.sin(y+aa)*l,f=Math.sin(y+aa)*(s?s/2-u:l),e.arc(n-c,r-a,u,y-$n,y-Xr),e.arc(n+f,r-o,u,y-Xr,y),e.arc(n+c,r+a,u,y,y+Xr),e.arc(n-f,r+o,u,y+Xr,y+$n),e.closePath();break;case"rect":if(!g){l=Math.SQRT1_2*m,d=s?s/2:l,e.rect(n-d,r-l,2*d,2*l);break}y+=aa;case"rectRot":c=Math.cos(y)*(s?s/2:m),o=Math.cos(y)*m,a=Math.sin(y)*m,f=Math.sin(y)*(s?s/2:m),e.moveTo(n-c,r-a),e.lineTo(n+f,r-o),e.lineTo(n+c,r+a),e.lineTo(n-f,r+o),e.closePath();break;case"crossRot":y+=aa;case"cross":c=Math.cos(y)*(s?s/2:m),o=Math.cos(y)*m,a=Math.sin(y)*m,f=Math.sin(y)*(s?s/2:m),e.moveTo(n-c,r-a),e.lineTo(n+c,r+a),e.moveTo(n+f,r-o),e.lineTo(n-f,r+o);break;case"star":c=Math.cos(y)*(s?s/2:m),o=Math.cos(y)*m,a=Math.sin(y)*m,f=Math.sin(y)*(s?s/2:m),e.moveTo(n-c,r-a),e.lineTo(n+c,r+a),e.moveTo(n+f,r-o),e.lineTo(n-f,r+o),y+=aa,c=Math.cos(y)*(s?s/2:m),o=Math.cos(y)*m,a=Math.sin(y)*m,f=Math.sin(y)*(s?s/2:m),e.moveTo(n-c,r-a),e.lineTo(n+c,r+a),e.moveTo(n+f,r-o),e.lineTo(n-f,r+o);break;case"line":o=s?s/2:Math.cos(y)*m,a=Math.sin(y)*m,e.moveTo(n-o,r-a),e.lineTo(n+o,r+a);break;case"dash":e.moveTo(n,r),e.lineTo(n+Math.cos(y)*(s?s/2:m),r+Math.sin(y)*m);break;case!1:e.closePath();break}e.fill(),t.borderWidth>0&&e.stroke()}}function Ll(e,t,n){return n=n||.5,!t||e&&e.x>t.left-n&&e.x<t.right+n&&e.y>t.top-n&&e.y<t.bottom+n}function cS(e,t){e.save(),e.beginPath(),e.rect(t.left,t.top,t.right-t.left,t.bottom-t.top),e.clip()}function dS(e){e.restore()}function KJ(e,t){t.translation&&e.translate(t.translation[0],t.translation[1]),Lt(t.rotation)||e.rotate(t.rotation),t.color&&(e.fillStyle=t.color),t.textAlign&&(e.textAlign=t.textAlign),t.textBaseline&&(e.textBaseline=t.textBaseline)}function YJ(e,t,n,r,s){if(s.strikethrough||s.underline){const i=e.measureText(r),o=t-i.actualBoundingBoxLeft,a=t+i.actualBoundingBoxRight,l=n-i.actualBoundingBoxAscent,u=n+i.actualBoundingBoxDescent,d=s.strikethrough?(l+u)/2:u;e.strokeStyle=e.fillStyle,e.beginPath(),e.lineWidth=s.decorationWidth||2,e.moveTo(o,d),e.lineTo(a,d),e.stroke()}}function XJ(e,t){const n=e.fillStyle;e.fillStyle=t.color,e.fillRect(t.left,t.top,t.width,t.height),e.fillStyle=n}function Qa(e,t,n,r,s,i={}){const o=on(t)?t:[t],a=i.strokeWidth>0&&i.strokeColor!=="";let l,u;for(e.save(),e.font=s.string,KJ(e,i),l=0;l<o.length;++l)u=o[l],i.backdrop&&XJ(e,i.backdrop),a&&(i.strokeColor&&(e.strokeStyle=i.strokeColor),Lt(i.strokeWidth)||(e.lineWidth=i.strokeWidth),e.strokeText(u,n,r,i.maxWidth)),e.fillText(u,n,r,i.maxWidth),YJ(e,n,r,u,i),r+=Number(s.lineHeight);e.restore()}function hd(e,t){const{x:n,y:r,w:s,h:i,radius:o}=t;e.arc(n+o.topLeft,r+o.topLeft,o.topLeft,1.5*$n,$n,!0),e.lineTo(n,r+i-o.bottomLeft),e.arc(n+o.bottomLeft,r+i-o.bottomLeft,o.bottomLeft,$n,Xr,!0),e.lineTo(n+s-o.bottomRight,r+i),e.arc(n+s-o.bottomRight,r+i-o.bottomRight,o.bottomRight,Xr,0,!0),e.lineTo(n+s,r+o.topRight),e.arc(n+s-o.topRight,r+o.topRight,o.topRight,0,-Xr,!0),e.lineTo(n+o.topLeft,r)}const QJ=/^(normal|(\d+(?:\.\d+)?)(px|em|%)?)$/,JJ=/^(normal|italic|initial|inherit|unset|(oblique( -?[0-9]?[0-9]deg)?))$/;function ZJ(e,t){const n=(""+e).match(QJ);if(!n||n[1]==="normal")return t*1.2;switch(e=+n[2],n[3]){case"px":return e;case"%":e/=100;break}return t*e}const eZ=e=>+e||0;function AM(e,t){const n={},r=_t(t),s=r?Object.keys(t):t,i=_t(e)?r?o=>Ct(e[o],e[t[o]]):o=>e[o]:()=>e;for(const o of s)n[o]=eZ(i(o));return n}function OM(e){return AM(e,{top:"y",right:"x",bottom:"y",left:"x"})}function $a(e){return AM(e,["topLeft","topRight","bottomLeft","bottomRight"])}function ir(e){const t=OM(e);return t.width=t.left+t.right,t.height=t.top+t.bottom,t}function Cn(e,t){e=e||{},t=t||fn.font;let n=Ct(e.size,t.size);typeof n=="string"&&(n=parseInt(n,10));let r=Ct(e.style,t.style);r&&!(""+r).match(JJ)&&(console.warn('Invalid font style specified: "'+r+'"'),r=void 0);const s={family:Ct(e.family,t.family),lineHeight:ZJ(Ct(e.lineHeight,t.lineHeight),n),size:n,style:r,weight:Ct(e.weight,t.weight),string:""};return s.string=WJ(s),s}function If(e,t,n,r){let s,i,o;for(s=0,i=e.length;s<i;++s)if(o=e[s],o!==void 0&&o!==void 0)return o}function tZ(e,t,n){const{min:r,max:s}=e,i=wJ(t,(s-r)/2),o=(a,l)=>n&&a===0?0:a+l;return{min:o(r,-Math.abs(i)),max:o(s,i)}}function al(e,t){return Object.assign(Object.create(e),t)}function fS(e,t=[""],n,r,s=()=>e[0]){const i=n||e;typeof r>"u"&&(r=$M("_fallback",e));const o={[Symbol.toStringTag]:"Object",_cacheable:!0,_scopes:e,_rootScopes:i,_fallback:r,_getTarget:s,override:a=>fS([a,...e],t,i,r)};return new Proxy(o,{deleteProperty(a,l){return delete a[l],delete a._keys,delete e[0][l],!0},get(a,l){return DM(a,l,()=>uZ(l,t,e,a))},getOwnPropertyDescriptor(a,l){return Reflect.getOwnPropertyDescriptor(a._scopes[0],l)},getPrototypeOf(){return Reflect.getPrototypeOf(e[0])},has(a,l){return ox(a).includes(l)},ownKeys(a){return ox(a)},set(a,l,u){const d=a._storage||(a._storage=s());return a[l]=d[l]=u,delete a._keys,!0}})}function _u(e,t,n,r){const s={_cacheable:!1,_proxy:e,_context:t,_subProxy:n,_stack:new Set,_descriptors:MM(e,r),setContext:i=>_u(e,i,n,r),override:i=>_u(e.override(i),t,n,r)};return new Proxy(s,{deleteProperty(i,o){return delete i[o],delete e[o],!0},get(i,o,a){return DM(i,o,()=>rZ(i,o,a))},getOwnPropertyDescriptor(i,o){return i._descriptors.allKeys?Reflect.has(e,o)?{enumerable:!0,configurable:!0}:void 0:Reflect.getOwnPropertyDescriptor(e,o)},getPrototypeOf(){return Reflect.getPrototypeOf(e)},has(i,o){return Reflect.has(e,o)},ownKeys(){return Reflect.ownKeys(e)},set(i,o,a){return e[o]=a,delete i[o],!0}})}function MM(e,t={scriptable:!0,indexable:!0}){const{_scriptable:n=t.scriptable,_indexable:r=t.indexable,_allKeys:s=t.allKeys}=e;return{allKeys:s,scriptable:n,indexable:r,isScriptable:Vo(n)?n:()=>n,isIndexable:Vo(r)?r:()=>r}}const nZ=(e,t)=>e?e+iS(t):t,hS=(e,t)=>_t(t)&&e!=="adapters"&&(Object.getPrototypeOf(t)===null||t.constructor===Object);function DM(e,t,n){if(Object.prototype.hasOwnProperty.call(e,t)||t==="constructor")return e[t];const r=n();return e[t]=r,r}function rZ(e,t,n){const{_proxy:r,_context:s,_subProxy:i,_descriptors:o}=e;let a=r[t];return Vo(a)&&o.isScriptable(t)&&(a=sZ(t,a,e,n)),on(a)&&a.length&&(a=iZ(t,a,e,o.isIndexable)),hS(t,a)&&(a=_u(a,s,i&&i[t],o)),a}function sZ(e,t,n,r){const{_proxy:s,_context:i,_subProxy:o,_stack:a}=n;if(a.has(e))throw new Error("Recursion detected: "+Array.from(a).join("->")+"->"+e);a.add(e);let l=t(i,o||r);return a.delete(e),hS(e,l)&&(l=pS(s._scopes,s,e,l)),l}function iZ(e,t,n,r){const{_proxy:s,_context:i,_subProxy:o,_descriptors:a}=n;if(typeof i.index<"u"&&r(e))return t[i.index%t.length];if(_t(t[0])){const l=t,u=s._scopes.filter(d=>d!==l);t=[];for(const d of l){const c=pS(u,s,e,d);t.push(_u(c,i,o&&o[e],a))}}return t}function LM(e,t,n){return Vo(e)?e(t,n):e}const oZ=(e,t)=>e===!0?t:typeof e=="string"?Su(t,e):void 0;function aZ(e,t,n,r,s){for(const i of t){const o=oZ(n,i);if(o){e.add(o);const a=LM(o._fallback,n,s);if(typeof a<"u"&&a!==n&&a!==r)return a}else if(o===!1&&typeof r<"u"&&n!==r)return null}return!1}function pS(e,t,n,r){const s=t._rootScopes,i=LM(t._fallback,n,r),o=[...e,...s],a=new Set;a.add(r);let l=ix(a,o,n,i||n,r);return l===null||typeof i<"u"&&i!==n&&(l=ix(a,o,i,l,r),l===null)?!1:fS(Array.from(a),[""],s,i,()=>lZ(t,n,r))}function ix(e,t,n,r,s){for(;n;)n=aZ(e,t,n,r,s);return n}function lZ(e,t,n){const r=e._getTarget();t in r||(r[t]={});const s=r[t];return on(s)&&_t(n)?n:s||{}}function uZ(e,t,n,r){let s;for(const i of t)if(s=$M(nZ(i,e),n),typeof s<"u")return hS(e,s)?pS(n,r,e,s):s}function $M(e,t){for(const n of t){if(!n)continue;const r=n[e];if(typeof r<"u")return r}}function ox(e){let t=e._keys;return t||(t=e._keys=cZ(e._scopes)),t}function cZ(e){const t=new Set;for(const n of e)for(const r of Object.keys(n).filter(s=>!s.startsWith("_")))t.add(r);return Array.from(t)}function mS(){return typeof window<"u"&&typeof document<"u"}function gS(e){let t=e.parentNode;return t&&t.toString()==="[object ShadowRoot]"&&(t=t.host),t}function mp(e,t,n){let r;return typeof e=="string"?(r=parseInt(e,10),e.indexOf("%")!==-1&&(r=r/100*t.parentNode[n])):r=e,r}const Pm=e=>e.ownerDocument.defaultView.getComputedStyle(e,null);function dZ(e,t){return Pm(e).getPropertyValue(t)}const fZ=["top","right","bottom","left"];function Fa(e,t,n){const r={};n=n?"-"+n:"";for(let s=0;s<4;s++){const i=fZ[s];r[i]=parseFloat(e[t+"-"+i+n])||0}return r.width=r.left+r.right,r.height=r.top+r.bottom,r}const hZ=(e,t,n)=>(e>0||t>0)&&(!n||!n.shadowRoot);function pZ(e,t){const n=e.touches,r=n&&n.length?n[0]:e,{offsetX:s,offsetY:i}=r;let o=!1,a,l;if(hZ(s,i,e.target))a=s,l=i;else{const u=t.getBoundingClientRect();a=r.clientX-u.left,l=r.clientY-u.top,o=!0}return{x:a,y:l,box:o}}function pa(e,t){if("native"in e)return e;const{canvas:n,currentDevicePixelRatio:r}=t,s=Pm(n),i=s.boxSizing==="border-box",o=Fa(s,"padding"),a=Fa(s,"border","width"),{x:l,y:u,box:d}=pZ(e,n),c=o.left+(d&&a.left),f=o.top+(d&&a.top);let{width:p,height:g}=t;return i&&(p-=o.width+a.width,g-=o.height+a.height),{x:Math.round((l-c)/p*n.width/r),y:Math.round((u-f)/g*n.height/r)}}function mZ(e,t,n){let r,s;if(t===void 0||n===void 0){const i=e&&gS(e);if(!i)t=e.clientWidth,n=e.clientHeight;else{const o=i.getBoundingClientRect(),a=Pm(i),l=Fa(a,"border","width"),u=Fa(a,"padding");t=o.width-u.width-l.width,n=o.height-u.height-l.height,r=mp(a.maxWidth,i,"clientWidth"),s=mp(a.maxHeight,i,"clientHeight")}}return{width:t,height:n,maxWidth:r||fp,maxHeight:s||fp}}const Af=e=>Math.round(e*10)/10;function gZ(e,t,n,r){const s=Pm(e),i=Fa(s,"margin"),o=mp(s.maxWidth,e,"clientWidth")||fp,a=mp(s.maxHeight,e,"clientHeight")||fp,l=mZ(e,t,n);let{width:u,height:d}=l;if(s.boxSizing==="content-box"){const f=Fa(s,"border","width"),p=Fa(s,"padding");u-=p.width+f.width,d-=p.height+f.height}return u=Math.max(0,u-i.width),d=Math.max(0,r?u/r:d-i.height),u=Af(Math.min(u,o,l.maxWidth)),d=Af(Math.min(d,a,l.maxHeight)),u&&!d&&(d=Af(u/2)),(t!==void 0||n!==void 0)&&r&&l.height&&d>l.height&&(d=l.height,u=Af(Math.floor(d*r))),{width:u,height:d}}function ax(e,t,n){const r=t||1,s=Math.floor(e.height*r),i=Math.floor(e.width*r);e.height=Math.floor(e.height),e.width=Math.floor(e.width);const o=e.canvas;return o.style&&(n||!o.style.height&&!o.style.width)&&(o.style.height=`${e.height}px`,o.style.width=`${e.width}px`),e.currentDevicePixelRatio!==r||o.height!==s||o.width!==i?(e.currentDevicePixelRatio=r,o.height=s,o.width=i,e.ctx.setTransform(r,0,0,r,0,0),!0):!1}const vZ=function(){let e=!1;try{const t={get passive(){return e=!0,!1}};mS()&&(window.addEventListener("test",null,t),window.removeEventListener("test",null,t))}catch{}return e}();function lx(e,t){const n=dZ(e,t),r=n&&n.match(/^(\d+)(\.\d+)?px$/);return r?+r[1]:void 0}const yZ=function(e,t){return{x(n){return e+e+t-n},setWidth(n){t=n},textAlign(n){return n==="center"?n:n==="right"?"left":"right"},xPlus(n,r){return n-r},leftForLtr(n,r){return n-r}}},bZ=function(){return{x(e){return e},setWidth(e){},textAlign(e){return e},xPlus(e,t){return e+t},leftForLtr(e,t){return e}}};function jl(e,t,n){return e?yZ(t,n):bZ()}function FM(e,t){let n,r;(t==="ltr"||t==="rtl")&&(n=e.canvas.style,r=[n.getPropertyValue("direction"),n.getPropertyPriority("direction")],n.setProperty("direction",t,"important"),e.prevTextDirection=r)}function NM(e,t){t!==void 0&&(delete e.prevTextDirection,e.canvas.style.setProperty("direction",t[0],t[1]))}/*!
78
+ * Chart.js v4.4.6
79
+ * https://www.chartjs.org
80
+ * (c) 2024 Chart.js Contributors
81
+ * Released under the MIT License
82
+ */class wZ{constructor(){this._request=null,this._charts=new Map,this._running=!1,this._lastDate=void 0}_notify(t,n,r,s){const i=n.listeners[s],o=n.duration;i.forEach(a=>a({chart:t,initial:n.initial,numSteps:o,currentStep:Math.min(r-n.start,o)}))}_refresh(){this._request||(this._running=!0,this._request=CM.call(window,()=>{this._update(),this._request=null,this._running&&this._refresh()}))}_update(t=Date.now()){let n=0;this._charts.forEach((r,s)=>{if(!r.running||!r.items.length)return;const i=r.items;let o=i.length-1,a=!1,l;for(;o>=0;--o)l=i[o],l._active?(l._total>r.duration&&(r.duration=l._total),l.tick(t),a=!0):(i[o]=i[i.length-1],i.pop());a&&(s.draw(),this._notify(s,r,t,"progress")),i.length||(r.running=!1,this._notify(s,r,t,"complete"),r.initial=!1),n+=i.length}),this._lastDate=t,n===0&&(this._running=!1)}_getAnims(t){const n=this._charts;let r=n.get(t);return r||(r={running:!1,initial:!0,items:[],listeners:{complete:[],progress:[]}},n.set(t,r)),r}listen(t,n,r){this._getAnims(t).listeners[n].push(r)}add(t,n){!n||!n.length||this._getAnims(t).items.push(...n)}has(t){return this._getAnims(t).items.length>0}start(t){const n=this._charts.get(t);n&&(n.running=!0,n.start=Date.now(),n.duration=n.items.reduce((r,s)=>Math.max(r,s._duration),0),this._refresh())}running(t){if(!this._running)return!1;const n=this._charts.get(t);return!(!n||!n.running||!n.items.length)}stop(t){const n=this._charts.get(t);if(!n||!n.items.length)return;const r=n.items;let s=r.length-1;for(;s>=0;--s)r[s].cancel();n.items=[],this._notify(t,n,Date.now(),"complete")}remove(t){return this._charts.delete(t)}}var xi=new wZ;const ux="transparent",SZ={boolean(e,t,n){return n>.5?t:e},color(e,t,n){const r=tx(e||ux),s=r.valid&&tx(t||ux);return s&&s.valid?s.mix(r,n).hexString():t},number(e,t,n){return e+(t-e)*n}};class _Z{constructor(t,n,r,s){const i=n[r];s=If([t.to,s,i,t.from]);const o=If([t.from,i,s]);this._active=!0,this._fn=t.fn||SZ[t.type||typeof o],this._easing=Mc[t.easing]||Mc.linear,this._start=Math.floor(Date.now()+(t.delay||0)),this._duration=this._total=Math.floor(t.duration),this._loop=!!t.loop,this._target=n,this._prop=r,this._from=o,this._to=s,this._promises=void 0}active(){return this._active}update(t,n,r){if(this._active){this._notify(!1);const s=this._target[this._prop],i=r-this._start,o=this._duration-i;this._start=r,this._duration=Math.floor(Math.max(o,t.duration)),this._total+=i,this._loop=!!t.loop,this._to=If([t.to,n,s,t.from]),this._from=If([t.from,s,n])}}cancel(){this._active&&(this.tick(Date.now()),this._active=!1,this._notify(!1))}tick(t){const n=t-this._start,r=this._duration,s=this._prop,i=this._from,o=this._loop,a=this._to;let l;if(this._active=i!==a&&(o||n<r),!this._active){this._target[s]=a,this._notify(!0);return}if(n<0){this._target[s]=i;return}l=n/r%2,l=o&&l>1?2-l:l,l=this._easing(Math.min(1,Math.max(0,l))),this._target[s]=this._fn(i,a,l)}wait(){const t=this._promises||(this._promises=[]);return new Promise((n,r)=>{t.push({res:n,rej:r})})}_notify(t){const n=t?"res":"rej",r=this._promises||[];for(let s=0;s<r.length;s++)r[s][n]()}}class BM{constructor(t,n){this._chart=t,this._properties=new Map,this.configure(n)}configure(t){if(!_t(t))return;const n=Object.keys(fn.animation),r=this._properties;Object.getOwnPropertyNames(t).forEach(s=>{const i=t[s];if(!_t(i))return;const o={};for(const a of n)o[a]=i[a];(on(i.properties)&&i.properties||[s]).forEach(a=>{(a===s||!r.has(a))&&r.set(a,o)})})}_animateOptions(t,n){const r=n.options,s=xZ(t,r);if(!s)return[];const i=this._createAnimations(s,r);return r.$shared&&kZ(t.options.$animations,r).then(()=>{t.options=r},()=>{}),i}_createAnimations(t,n){const r=this._properties,s=[],i=t.$animations||(t.$animations={}),o=Object.keys(n),a=Date.now();let l;for(l=o.length-1;l>=0;--l){const u=o[l];if(u.charAt(0)==="$")continue;if(u==="options"){s.push(...this._animateOptions(t,n));continue}const d=n[u];let c=i[u];const f=r.get(u);if(c)if(f&&c.active()){c.update(f,d,a);continue}else c.cancel();if(!f||!f.duration){t[u]=d;continue}i[u]=c=new _Z(f,t,u,d),s.push(c)}return s}update(t,n){if(this._properties.size===0){Object.assign(t,n);return}const r=this._createAnimations(t,n);if(r.length)return xi.add(this._chart,r),!0}}function kZ(e,t){const n=[],r=Object.keys(t);for(let s=0;s<r.length;s++){const i=e[r[s]];i&&i.active()&&n.push(i.wait())}return Promise.all(n)}function xZ(e,t){if(!t)return;let n=e.options;if(!n){e.options=t;return}return n.$shared&&(e.options=n=Object.assign({},n,{$shared:!1,$animations:{}})),n}function cx(e,t){const n=e&&e.options||{},r=n.reverse,s=n.min===void 0?t:0,i=n.max===void 0?t:0;return{start:r?i:s,end:r?s:i}}function EZ(e,t,n){if(n===!1)return!1;const r=cx(e,n),s=cx(t,n);return{top:s.end,right:r.end,bottom:s.start,left:r.start}}function CZ(e){let t,n,r,s;return _t(e)?(t=e.top,n=e.right,r=e.bottom,s=e.left):t=n=r=s=e,{top:t,right:n,bottom:r,left:s,disabled:e===!1}}function VM(e,t){const n=[],r=e._getSortedDatasetMetas(t);let s,i;for(s=0,i=r.length;s<i;++s)n.push(r[s].index);return n}function dx(e,t,n,r={}){const s=e.keys,i=r.mode==="single";let o,a,l,u;if(t===null)return;let d=!1;for(o=0,a=s.length;o<a;++o){if(l=+s[o],l===n){if(d=!0,r.all)continue;break}u=e.values[l],Mn(u)&&(i||t===0||Lo(t)===Lo(u))&&(t+=u)}return!d&&!r.all?0:t}function PZ(e,t){const{iScale:n,vScale:r}=t,s=n.axis==="x"?"x":"y",i=r.axis==="x"?"x":"y",o=Object.keys(e),a=new Array(o.length);let l,u,d;for(l=0,u=o.length;l<u;++l)d=o[l],a[l]={[s]:d,[i]:e[d]};return a}function Lg(e,t){const n=e&&e.options.stacked;return n||n===void 0&&t.stack!==void 0}function TZ(e,t,n){return`${e.id}.${t.id}.${n.stack||n.type}`}function RZ(e){const{min:t,max:n,minDefined:r,maxDefined:s}=e.getUserBounds();return{min:r?t:Number.NEGATIVE_INFINITY,max:s?n:Number.POSITIVE_INFINITY}}function IZ(e,t,n){const r=e[t]||(e[t]={});return r[n]||(r[n]={})}function fx(e,t,n,r){for(const s of t.getMatchingVisibleMetas(r).reverse()){const i=e[s.index];if(n&&i>0||!n&&i<0)return s.index}return null}function hx(e,t){const{chart:n,_cachedMeta:r}=e,s=n._stacks||(n._stacks={}),{iScale:i,vScale:o,index:a}=r,l=i.axis,u=o.axis,d=TZ(i,o,r),c=t.length;let f;for(let p=0;p<c;++p){const g=t[p],{[l]:m,[u]:y}=g,b=g._stacks||(g._stacks={});f=b[u]=IZ(s,d,m),f[a]=y,f._top=fx(f,o,!0,r.type),f._bottom=fx(f,o,!1,r.type);const w=f._visualValues||(f._visualValues={});w[a]=y}}function $g(e,t){const n=e.scales;return Object.keys(n).filter(r=>n[r].axis===t).shift()}function AZ(e,t){return al(e,{active:!1,dataset:void 0,datasetIndex:t,index:t,mode:"default",type:"dataset"})}function OZ(e,t,n){return al(e,{active:!1,dataIndex:t,parsed:void 0,raw:void 0,element:n,index:t,mode:"default",type:"data"})}function nc(e,t){const n=e.controller.index,r=e.vScale&&e.vScale.axis;if(r){t=t||e._parsed;for(const s of t){const i=s._stacks;if(!i||i[r]===void 0||i[r][n]===void 0)return;delete i[r][n],i[r]._visualValues!==void 0&&i[r]._visualValues[n]!==void 0&&delete i[r]._visualValues[n]}}}const Fg=e=>e==="reset"||e==="none",px=(e,t)=>t?e:Object.assign({},e),MZ=(e,t,n)=>e&&!t.hidden&&t._stacked&&{keys:VM(n,!0),values:null};class Lc{constructor(t,n){this.chart=t,this._ctx=t.ctx,this.index=n,this._cachedDataOpts={},this._cachedMeta=this.getMeta(),this._type=this._cachedMeta.type,this.options=void 0,this._parsing=!1,this._data=void 0,this._objectData=void 0,this._sharedOptions=void 0,this._drawStart=void 0,this._drawCount=void 0,this.enableOptionSharing=!1,this.supportsDecimation=!1,this.$context=void 0,this._syncList=[],this.datasetElementType=new.target.datasetElementType,this.dataElementType=new.target.dataElementType,this.initialize()}initialize(){const t=this._cachedMeta;this.configure(),this.linkScales(),t._stacked=Lg(t.vScale,t),this.addElements(),this.options.fill&&!this.chart.isPluginEnabled("filler")&&console.warn("Tried to use the 'fill' option without the 'Filler' plugin enabled. Please import and register the 'Filler' plugin and make sure it is not disabled in the options")}updateIndex(t){this.index!==t&&nc(this._cachedMeta),this.index=t}linkScales(){const t=this.chart,n=this._cachedMeta,r=this.getDataset(),s=(c,f,p,g)=>c==="x"?f:c==="r"?g:p,i=n.xAxisID=Ct(r.xAxisID,$g(t,"x")),o=n.yAxisID=Ct(r.yAxisID,$g(t,"y")),a=n.rAxisID=Ct(r.rAxisID,$g(t,"r")),l=n.indexAxis,u=n.iAxisID=s(l,i,o,a),d=n.vAxisID=s(l,o,i,a);n.xScale=this.getScaleForId(i),n.yScale=this.getScaleForId(o),n.rScale=this.getScaleForId(a),n.iScale=this.getScaleForId(u),n.vScale=this.getScaleForId(d)}getDataset(){return this.chart.data.datasets[this.index]}getMeta(){return this.chart.getDatasetMeta(this.index)}getScaleForId(t){return this.chart.scales[t]}_getOtherScale(t){const n=this._cachedMeta;return t===n.iScale?n.vScale:n.iScale}reset(){this._update("reset")}_destroy(){const t=this._cachedMeta;this._data&&Jk(this._data,this),t._stacked&&nc(t)}_dataCheck(){const t=this.getDataset(),n=t.data||(t.data=[]),r=this._data;if(_t(n)){const s=this._cachedMeta;this._data=PZ(n,s)}else if(r!==n){if(r){Jk(r,this);const s=this._cachedMeta;nc(s),s._parsed=[]}n&&Object.isExtensible(n)&&LJ(n,this),this._syncList=[],this._data=n}}addElements(){const t=this._cachedMeta;this._dataCheck(),this.datasetElementType&&(t.dataset=new this.datasetElementType)}buildOrUpdateElements(t){const n=this._cachedMeta,r=this.getDataset();let s=!1;this._dataCheck();const i=n._stacked;n._stacked=Lg(n.vScale,n),n.stack!==r.stack&&(s=!0,nc(n),n.stack=r.stack),this._resyncElements(t),(s||i!==n._stacked)&&(hx(this,n._parsed),n._stacked=Lg(n.vScale,n))}configure(){const t=this.chart.config,n=t.datasetScopeKeys(this._type),r=t.getOptionScopes(this.getDataset(),n,!0);this.options=t.createResolver(r,this.getContext()),this._parsing=this.options.parsing,this._cachedDataOpts={}}parse(t,n){const{_cachedMeta:r,_data:s}=this,{iScale:i,_stacked:o}=r,a=i.axis;let l=t===0&&n===s.length?!0:r._sorted,u=t>0&&r._parsed[t-1],d,c,f;if(this._parsing===!1)r._parsed=s,r._sorted=!0,f=s;else{on(s[t])?f=this.parseArrayData(r,s,t,n):_t(s[t])?f=this.parseObjectData(r,s,t,n):f=this.parsePrimitiveData(r,s,t,n);const p=()=>c[a]===null||u&&c[a]<u[a];for(d=0;d<n;++d)r._parsed[d+t]=c=f[d],l&&(p()&&(l=!1),u=c);r._sorted=l}o&&hx(this,f)}parsePrimitiveData(t,n,r,s){const{iScale:i,vScale:o}=t,a=i.axis,l=o.axis,u=i.getLabels(),d=i===o,c=new Array(s);let f,p,g;for(f=0,p=s;f<p;++f)g=f+r,c[f]={[a]:d||i.parse(u[g],g),[l]:o.parse(n[g],g)};return c}parseArrayData(t,n,r,s){const{xScale:i,yScale:o}=t,a=new Array(s);let l,u,d,c;for(l=0,u=s;l<u;++l)d=l+r,c=n[d],a[l]={x:i.parse(c[0],d),y:o.parse(c[1],d)};return a}parseObjectData(t,n,r,s){const{xScale:i,yScale:o}=t,{xAxisKey:a="x",yAxisKey:l="y"}=this._parsing,u=new Array(s);let d,c,f,p;for(d=0,c=s;d<c;++d)f=d+r,p=n[f],u[d]={x:i.parse(Su(p,a),f),y:o.parse(Su(p,l),f)};return u}getParsed(t){return this._cachedMeta._parsed[t]}getDataElement(t){return this._cachedMeta.data[t]}applyStack(t,n,r){const s=this.chart,i=this._cachedMeta,o=n[t.axis],a={keys:VM(s,!0),values:n._stacks[t.axis]._visualValues};return dx(a,o,i.index,{mode:r})}updateRangeFromParsed(t,n,r,s){const i=r[n.axis];let o=i===null?NaN:i;const a=s&&r._stacks[n.axis];s&&a&&(s.values=a,o=dx(s,i,this._cachedMeta.index)),t.min=Math.min(t.min,o),t.max=Math.max(t.max,o)}getMinMax(t,n){const r=this._cachedMeta,s=r._parsed,i=r._sorted&&t===r.iScale,o=s.length,a=this._getOtherScale(t),l=MZ(n,r,this.chart),u={min:Number.POSITIVE_INFINITY,max:Number.NEGATIVE_INFINITY},{min:d,max:c}=RZ(a);let f,p;function g(){p=s[f];const m=p[a.axis];return!Mn(p[t.axis])||d>m||c<m}for(f=0;f<o&&!(!g()&&(this.updateRangeFromParsed(u,t,p,l),i));++f);if(i){for(f=o-1;f>=0;--f)if(!g()){this.updateRangeFromParsed(u,t,p,l);break}}return u}getAllParsedValues(t){const n=this._cachedMeta._parsed,r=[];let s,i,o;for(s=0,i=n.length;s<i;++s)o=n[s][t.axis],Mn(o)&&r.push(o);return r}getMaxOverflow(){return!1}getLabelAndValue(t){const n=this._cachedMeta,r=n.iScale,s=n.vScale,i=this.getParsed(t);return{label:r?""+r.getLabelForValue(i[r.axis]):"",value:s?""+s.getLabelForValue(i[s.axis]):""}}_update(t){const n=this._cachedMeta;this.update(t||"default"),n._clip=CZ(Ct(this.options.clip,EZ(n.xScale,n.yScale,this.getMaxOverflow())))}update(t){}draw(){const t=this._ctx,n=this.chart,r=this._cachedMeta,s=r.data||[],i=n.chartArea,o=[],a=this._drawStart||0,l=this._drawCount||s.length-a,u=this.options.drawActiveElementsOnTop;let d;for(r.dataset&&r.dataset.draw(t,i,a,l),d=a;d<a+l;++d){const c=s[d];c.hidden||(c.active&&u?o.push(c):c.draw(t,i))}for(d=0;d<o.length;++d)o[d].draw(t,i)}getStyle(t,n){const r=n?"active":"default";return t===void 0&&this._cachedMeta.dataset?this.resolveDatasetElementOptions(r):this.resolveDataElementOptions(t||0,r)}getContext(t,n,r){const s=this.getDataset();let i;if(t>=0&&t<this._cachedMeta.data.length){const o=this._cachedMeta.data[t];i=o.$context||(o.$context=OZ(this.getContext(),t,o)),i.parsed=this.getParsed(t),i.raw=s.data[t],i.index=i.dataIndex=t}else i=this.$context||(this.$context=AZ(this.chart.getContext(),this.index)),i.dataset=s,i.index=i.datasetIndex=this.index;return i.active=!!n,i.mode=r,i}resolveDatasetElementOptions(t){return this._resolveElementOptions(this.datasetElementType.id,t)}resolveDataElementOptions(t,n){return this._resolveElementOptions(this.dataElementType.id,n,t)}_resolveElementOptions(t,n="default",r){const s=n==="active",i=this._cachedDataOpts,o=t+"-"+n,a=i[o],l=this.enableOptionSharing&&fd(r);if(a)return px(a,l);const u=this.chart.config,d=u.datasetElementScopeKeys(this._type,t),c=s?[`${t}Hover`,"hover",t,""]:[t,""],f=u.getOptionScopes(this.getDataset(),d),p=Object.keys(fn.elements[t]),g=()=>this.getContext(r,s,n),m=u.resolveNamedOptions(f,p,g,c);return m.$shared&&(m.$shared=l,i[o]=Object.freeze(px(m,l))),m}_resolveAnimations(t,n,r){const s=this.chart,i=this._cachedDataOpts,o=`animation-${n}`,a=i[o];if(a)return a;let l;if(s.options.animation!==!1){const d=this.chart.config,c=d.datasetAnimationScopeKeys(this._type,n),f=d.getOptionScopes(this.getDataset(),c);l=d.createResolver(f,this.getContext(t,r,n))}const u=new BM(s,l&&l.animations);return l&&l._cacheable&&(i[o]=Object.freeze(u)),u}getSharedOptions(t){if(t.$shared)return this._sharedOptions||(this._sharedOptions=Object.assign({},t))}includeOptions(t,n){return!n||Fg(t)||this.chart._animationsDisabled}_getSharedOptions(t,n){const r=this.resolveDataElementOptions(t,n),s=this._sharedOptions,i=this.getSharedOptions(r),o=this.includeOptions(n,i)||i!==s;return this.updateSharedOptions(i,n,r),{sharedOptions:i,includeOptions:o}}updateElement(t,n,r,s){Fg(s)?Object.assign(t,r):this._resolveAnimations(n,s).update(t,r)}updateSharedOptions(t,n,r){t&&!Fg(n)&&this._resolveAnimations(void 0,n).update(t,r)}_setStyle(t,n,r,s){t.active=s;const i=this.getStyle(n,s);this._resolveAnimations(n,r,s).update(t,{options:!s&&this.getSharedOptions(i)||i})}removeHoverStyle(t,n,r){this._setStyle(t,r,"active",!1)}setHoverStyle(t,n,r){this._setStyle(t,r,"active",!0)}_removeDatasetHoverStyle(){const t=this._cachedMeta.dataset;t&&this._setStyle(t,void 0,"active",!1)}_setDatasetHoverStyle(){const t=this._cachedMeta.dataset;t&&this._setStyle(t,void 0,"active",!0)}_resyncElements(t){const n=this._data,r=this._cachedMeta.data;for(const[a,l,u]of this._syncList)this[a](l,u);this._syncList=[];const s=r.length,i=n.length,o=Math.min(i,s);o&&this.parse(0,o),i>s?this._insertElements(s,i-s,t):i<s&&this._removeElements(i,s-i)}_insertElements(t,n,r=!0){const s=this._cachedMeta,i=s.data,o=t+n;let a;const l=u=>{for(u.length+=n,a=u.length-1;a>=o;a--)u[a]=u[a-n]};for(l(i),a=t;a<o;++a)i[a]=new this.dataElementType;this._parsing&&l(s._parsed),this.parse(t,n),r&&this.updateElements(i,t,n,"reset")}updateElements(t,n,r,s){}_removeElements(t,n){const r=this._cachedMeta;if(this._parsing){const s=r._parsed.splice(t,n);r._stacked&&nc(r,s)}r.data.splice(t,n)}_sync(t){if(this._parsing)this._syncList.push(t);else{const[n,r,s]=t;this[n](r,s)}this.chart._dataChanges.push([this.index,...t])}_onDataPush(){const t=arguments.length;this._sync(["_insertElements",this.getDataset().data.length-t,t])}_onDataPop(){this._sync(["_removeElements",this._cachedMeta.data.length-1,1])}_onDataShift(){this._sync(["_removeElements",0,1])}_onDataSplice(t,n){n&&this._sync(["_removeElements",t,n]);const r=arguments.length-2;r&&this._sync(["_insertElements",t,r])}_onDataUnshift(){this._sync(["_insertElements",0,arguments.length])}}he(Lc,"defaults",{}),he(Lc,"datasetElementType",null),he(Lc,"dataElementType",null);function DZ(e,t){if(!e._cache.$bar){const n=e.getMatchingVisibleMetas(t);let r=[];for(let s=0,i=n.length;s<i;s++)r=r.concat(n[s].controller.getAllParsedValues(e));e._cache.$bar=EM(r.sort((s,i)=>s-i))}return e._cache.$bar}function LZ(e){const t=e.iScale,n=DZ(t,e.type);let r=t._length,s,i,o,a;const l=()=>{o===32767||o===-32768||(fd(a)&&(r=Math.min(r,Math.abs(o-a)||r)),a=o)};for(s=0,i=n.length;s<i;++s)o=t.getPixelForValue(n[s]),l();for(a=void 0,s=0,i=t.ticks.length;s<i;++s)o=t.getPixelForTick(s),l();return r}function $Z(e,t,n,r){const s=n.barThickness;let i,o;return Lt(s)?(i=t.min*n.categoryPercentage,o=n.barPercentage):(i=s*r,o=1),{chunk:i/r,ratio:o,start:t.pixels[e]-i/2}}function FZ(e,t,n,r){const s=t.pixels,i=s[e];let o=e>0?s[e-1]:null,a=e<s.length-1?s[e+1]:null;const l=n.categoryPercentage;o===null&&(o=i-(a===null?t.end-t.start:a-i)),a===null&&(a=i+i-o);const u=i-(i-Math.min(o,a))/2*l;return{chunk:Math.abs(a-o)/2*l/r,ratio:n.barPercentage,start:u}}function NZ(e,t,n,r){const s=n.parse(e[0],r),i=n.parse(e[1],r),o=Math.min(s,i),a=Math.max(s,i);let l=o,u=a;Math.abs(o)>Math.abs(a)&&(l=a,u=o),t[n.axis]=u,t._custom={barStart:l,barEnd:u,start:s,end:i,min:o,max:a}}function UM(e,t,n,r){return on(e)?NZ(e,t,n,r):t[n.axis]=n.parse(e,r),t}function mx(e,t,n,r){const s=e.iScale,i=e.vScale,o=s.getLabels(),a=s===i,l=[];let u,d,c,f;for(u=n,d=n+r;u<d;++u)f=t[u],c={},c[s.axis]=a||s.parse(o[u],u),l.push(UM(f,c,i,u));return l}function Ng(e){return e&&e.barStart!==void 0&&e.barEnd!==void 0}function BZ(e,t,n){return e!==0?Lo(e):(t.isHorizontal()?1:-1)*(t.min>=n?1:-1)}function VZ(e){let t,n,r,s,i;return e.horizontal?(t=e.base>e.x,n="left",r="right"):(t=e.base<e.y,n="bottom",r="top"),t?(s="end",i="start"):(s="start",i="end"),{start:n,end:r,reverse:t,top:s,bottom:i}}function UZ(e,t,n,r){let s=t.borderSkipped;const i={};if(!s){e.borderSkipped=i;return}if(s===!0){e.borderSkipped={top:!0,right:!0,bottom:!0,left:!0};return}const{start:o,end:a,reverse:l,top:u,bottom:d}=VZ(e);s==="middle"&&n&&(e.enableBorderRadius=!0,(n._top||0)===r?s=u:(n._bottom||0)===r?s=d:(i[gx(d,o,a,l)]=!0,s=u)),i[gx(s,o,a,l)]=!0,e.borderSkipped=i}function gx(e,t,n,r){return r?(e=HZ(e,t,n),e=vx(e,n,t)):e=vx(e,t,n),e}function HZ(e,t,n){return e===t?n:e===n?t:e}function vx(e,t,n){return e==="start"?t:e==="end"?n:e}function zZ(e,{inflateAmount:t},n){e.inflateAmount=t==="auto"?n===1?.33:0:t}class mh extends Lc{parsePrimitiveData(t,n,r,s){return mx(t,n,r,s)}parseArrayData(t,n,r,s){return mx(t,n,r,s)}parseObjectData(t,n,r,s){const{iScale:i,vScale:o}=t,{xAxisKey:a="x",yAxisKey:l="y"}=this._parsing,u=i.axis==="x"?a:l,d=o.axis==="x"?a:l,c=[];let f,p,g,m;for(f=r,p=r+s;f<p;++f)m=n[f],g={},g[i.axis]=i.parse(Su(m,u),f),c.push(UM(Su(m,d),g,o,f));return c}updateRangeFromParsed(t,n,r,s){super.updateRangeFromParsed(t,n,r,s);const i=r._custom;i&&n===this._cachedMeta.vScale&&(t.min=Math.min(t.min,i.min),t.max=Math.max(t.max,i.max))}getMaxOverflow(){return 0}getLabelAndValue(t){const n=this._cachedMeta,{iScale:r,vScale:s}=n,i=this.getParsed(t),o=i._custom,a=Ng(o)?"["+o.start+", "+o.end+"]":""+s.getLabelForValue(i[s.axis]);return{label:""+r.getLabelForValue(i[r.axis]),value:a}}initialize(){this.enableOptionSharing=!0,super.initialize();const t=this._cachedMeta;t.stack=this.getDataset().stack}update(t){const n=this._cachedMeta;this.updateElements(n.data,0,n.data.length,t)}updateElements(t,n,r,s){const i=s==="reset",{index:o,_cachedMeta:{vScale:a}}=this,l=a.getBasePixel(),u=a.isHorizontal(),d=this._getRuler(),{sharedOptions:c,includeOptions:f}=this._getSharedOptions(n,s);for(let p=n;p<n+r;p++){const g=this.getParsed(p),m=i||Lt(g[a.axis])?{base:l,head:l}:this._calculateBarValuePixels(p),y=this._calculateBarIndexPixels(p,d),b=(g._stacks||{})[a.axis],w={horizontal:u,base:m.base,enableBorderRadius:!b||Ng(g._custom)||o===b._top||o===b._bottom,x:u?m.head:y.center,y:u?y.center:m.head,height:u?y.size:Math.abs(m.size),width:u?Math.abs(m.size):y.size};f&&(w.options=c||this.resolveDataElementOptions(p,t[p].active?"active":s));const S=w.options||t[p].options;UZ(w,S,b,o),zZ(w,S,d.ratio),this.updateElement(t[p],p,w,s)}}_getStacks(t,n){const{iScale:r}=this._cachedMeta,s=r.getMatchingVisibleMetas(this._type).filter(d=>d.controller.options.grouped),i=r.options.stacked,o=[],a=this._cachedMeta.controller.getParsed(n),l=a&&a[r.axis],u=d=>{const c=d._parsed.find(p=>p[r.axis]===l),f=c&&c[d.vScale.axis];if(Lt(f)||isNaN(f))return!0};for(const d of s)if(!(n!==void 0&&u(d))&&((i===!1||o.indexOf(d.stack)===-1||i===void 0&&d.stack===void 0)&&o.push(d.stack),d.index===t))break;return o.length||o.push(void 0),o}_getStackCount(t){return this._getStacks(void 0,t).length}_getStackIndex(t,n,r){const s=this._getStacks(t,r),i=n!==void 0?s.indexOf(n):-1;return i===-1?s.length-1:i}_getRuler(){const t=this.options,n=this._cachedMeta,r=n.iScale,s=[];let i,o;for(i=0,o=n.data.length;i<o;++i)s.push(r.getPixelForValue(this.getParsed(i)[r.axis],i));const a=t.barThickness;return{min:a||LZ(n),pixels:s,start:r._startPixel,end:r._endPixel,stackCount:this._getStackCount(),scale:r,grouped:t.grouped,ratio:a?1:t.categoryPercentage*t.barPercentage}}_calculateBarValuePixels(t){const{_cachedMeta:{vScale:n,_stacked:r,index:s},options:{base:i,minBarLength:o}}=this,a=i||0,l=this.getParsed(t),u=l._custom,d=Ng(u);let c=l[n.axis],f=0,p=r?this.applyStack(n,l,r):c,g,m;p!==c&&(f=p-c,p=c),d&&(c=u.barStart,p=u.barEnd-u.barStart,c!==0&&Lo(c)!==Lo(u.barEnd)&&(f=0),f+=c);const y=!Lt(i)&&!d?i:f;let b=n.getPixelForValue(y);if(this.chart.getDataVisibility(t)?g=n.getPixelForValue(f+p):g=b,m=g-b,Math.abs(m)<o){m=BZ(m,n,a)*o,c===a&&(b-=m/2);const w=n.getPixelForDecimal(0),S=n.getPixelForDecimal(1),P=Math.min(w,S),E=Math.max(w,S);b=Math.max(Math.min(b,E),P),g=b+m,r&&!d&&(l._stacks[n.axis]._visualValues[s]=n.getValueForPixel(g)-n.getValueForPixel(b))}if(b===n.getPixelForValue(a)){const w=Lo(m)*n.getLineWidthForValue(a)/2;b+=w,m-=w}return{size:m,base:b,head:g,center:g+m/2}}_calculateBarIndexPixels(t,n){const r=n.scale,s=this.options,i=s.skipNull,o=Ct(s.maxBarThickness,1/0);let a,l;if(n.grouped){const u=i?this._getStackCount(t):n.stackCount,d=s.barThickness==="flex"?FZ(t,n,s,u):$Z(t,n,s,u),c=this._getStackIndex(this.index,this._cachedMeta.stack,i?t:void 0);a=d.start+d.chunk*c+d.chunk/2,l=Math.min(o,d.chunk*d.ratio)}else a=r.getPixelForValue(this.getParsed(t)[r.axis],t),l=Math.min(o,n.min*n.ratio);return{base:a-l/2,head:a+l/2,center:a,size:l}}draw(){const t=this._cachedMeta,n=t.vScale,r=t.data,s=r.length;let i=0;for(;i<s;++i)this.getParsed(i)[n.axis]!==null&&!r[i].hidden&&r[i].draw(this._ctx)}}he(mh,"id","bar"),he(mh,"defaults",{datasetElementType:!1,dataElementType:"bar",categoryPercentage:.8,barPercentage:.9,grouped:!0,animations:{numbers:{type:"number",properties:["x","y","base","width","height"]}}}),he(mh,"overrides",{scales:{_index_:{type:"category",offset:!0,grid:{offset:!0}},_value_:{type:"linear",beginAtZero:!0}}});function ua(){throw new Error("This method is not implemented: Check that a complete date adapter is provided.")}class vS{constructor(t){he(this,"options");this.options=t||{}}static override(t){Object.assign(vS.prototype,t)}init(){}formats(){return ua()}parse(){return ua()}format(){return ua()}add(){return ua()}diff(){return ua()}startOf(){return ua()}endOf(){return ua()}}var jZ={_date:vS};function qZ(e,t,n,r){const{controller:s,data:i,_sorted:o}=e,a=s._cachedMeta.iScale;if(a&&t===a.axis&&t!=="r"&&o&&i.length){const l=a._reversePixels?MJ:Yy;if(r){if(s._sharedOptions){const u=i[0],d=typeof u.getRange=="function"&&u.getRange(t);if(d){const c=l(i,t,n-d),f=l(i,t,n+d);return{lo:c.lo,hi:f.hi}}}}else return l(i,t,n)}return{lo:0,hi:i.length-1}}function Kd(e,t,n,r,s){const i=e.getSortedVisibleDatasetMetas(),o=n[t];for(let a=0,l=i.length;a<l;++a){const{index:u,data:d}=i[a],{lo:c,hi:f}=qZ(i[a],t,o,s);for(let p=c;p<=f;++p){const g=d[p];g.skip||r(g,u,p)}}}function WZ(e){const t=e.indexOf("x")!==-1,n=e.indexOf("y")!==-1;return function(r,s){const i=t?Math.abs(r.x-s.x):0,o=n?Math.abs(r.y-s.y):0;return Math.sqrt(Math.pow(i,2)+Math.pow(o,2))}}function Bg(e,t,n,r,s){const i=[];return!s&&!e.isPointInArea(t)||Kd(e,n,t,function(a,l,u){!s&&!Ll(a,e.chartArea,0)||a.inRange(t.x,t.y,r)&&i.push({element:a,datasetIndex:l,index:u})},!0),i}function GZ(e,t,n,r){let s=[];function i(o,a,l){const{startAngle:u,endAngle:d}=o.getProps(["startAngle","endAngle"],r),{angle:c}=RJ(o,{x:t.x,y:t.y});AJ(c,u,d)&&s.push({element:o,datasetIndex:a,index:l})}return Kd(e,n,t,i),s}function KZ(e,t,n,r,s,i){let o=[];const a=WZ(n);let l=Number.POSITIVE_INFINITY;function u(d,c,f){const p=d.inRange(t.x,t.y,s);if(r&&!p)return;const g=d.getCenterPoint(s);if(!(!!i||e.isPointInArea(g))&&!p)return;const y=a(t,g);y<l?(o=[{element:d,datasetIndex:c,index:f}],l=y):y===l&&o.push({element:d,datasetIndex:c,index:f})}return Kd(e,n,t,u),o}function Vg(e,t,n,r,s,i){return!i&&!e.isPointInArea(t)?[]:n==="r"&&!r?GZ(e,t,n,s):KZ(e,t,n,r,s,i)}function yx(e,t,n,r,s){const i=[],o=n==="x"?"inXRange":"inYRange";let a=!1;return Kd(e,n,t,(l,u,d)=>{l[o]&&l[o](t[n],s)&&(i.push({element:l,datasetIndex:u,index:d}),a=a||l.inRange(t.x,t.y,s))}),r&&!a?[]:i}var YZ={evaluateInteractionItems:Kd,modes:{index(e,t,n,r){const s=pa(t,e),i=n.axis||"x",o=n.includeInvisible||!1,a=n.intersect?Bg(e,s,i,r,o):Vg(e,s,i,!1,r,o),l=[];return a.length?(e.getSortedVisibleDatasetMetas().forEach(u=>{const d=a[0].index,c=u.data[d];c&&!c.skip&&l.push({element:c,datasetIndex:u.index,index:d})}),l):[]},dataset(e,t,n,r){const s=pa(t,e),i=n.axis||"xy",o=n.includeInvisible||!1;let a=n.intersect?Bg(e,s,i,r,o):Vg(e,s,i,!1,r,o);if(a.length>0){const l=a[0].datasetIndex,u=e.getDatasetMeta(l).data;a=[];for(let d=0;d<u.length;++d)a.push({element:u[d],datasetIndex:l,index:d})}return a},point(e,t,n,r){const s=pa(t,e),i=n.axis||"xy",o=n.includeInvisible||!1;return Bg(e,s,i,r,o)},nearest(e,t,n,r){const s=pa(t,e),i=n.axis||"xy",o=n.includeInvisible||!1;return Vg(e,s,i,n.intersect,r,o)},x(e,t,n,r){const s=pa(t,e);return yx(e,s,"x",n.intersect,r)},y(e,t,n,r){const s=pa(t,e);return yx(e,s,"y",n.intersect,r)}}};const HM=["left","top","right","bottom"];function rc(e,t){return e.filter(n=>n.pos===t)}function bx(e,t){return e.filter(n=>HM.indexOf(n.pos)===-1&&n.box.axis===t)}function sc(e,t){return e.sort((n,r)=>{const s=t?r:n,i=t?n:r;return s.weight===i.weight?s.index-i.index:s.weight-i.weight})}function XZ(e){const t=[];let n,r,s,i,o,a;for(n=0,r=(e||[]).length;n<r;++n)s=e[n],{position:i,options:{stack:o,stackWeight:a=1}}=s,t.push({index:n,box:s,pos:i,horizontal:s.isHorizontal(),weight:s.weight,stack:o&&i+o,stackWeight:a});return t}function QZ(e){const t={};for(const n of e){const{stack:r,pos:s,stackWeight:i}=n;if(!r||!HM.includes(s))continue;const o=t[r]||(t[r]={count:0,placed:0,weight:0,size:0});o.count++,o.weight+=i}return t}function JZ(e,t){const n=QZ(e),{vBoxMaxWidth:r,hBoxMaxHeight:s}=t;let i,o,a;for(i=0,o=e.length;i<o;++i){a=e[i];const{fullSize:l}=a.box,u=n[a.stack],d=u&&a.stackWeight/u.weight;a.horizontal?(a.width=d?d*r:l&&t.availableWidth,a.height=s):(a.width=r,a.height=d?d*s:l&&t.availableHeight)}return n}function ZZ(e){const t=XZ(e),n=sc(t.filter(u=>u.box.fullSize),!0),r=sc(rc(t,"left"),!0),s=sc(rc(t,"right")),i=sc(rc(t,"top"),!0),o=sc(rc(t,"bottom")),a=bx(t,"x"),l=bx(t,"y");return{fullSize:n,leftAndTop:r.concat(i),rightAndBottom:s.concat(l).concat(o).concat(a),chartArea:rc(t,"chartArea"),vertical:r.concat(s).concat(l),horizontal:i.concat(o).concat(a)}}function wx(e,t,n,r){return Math.max(e[n],t[n])+Math.max(e[r],t[r])}function zM(e,t){e.top=Math.max(e.top,t.top),e.left=Math.max(e.left,t.left),e.bottom=Math.max(e.bottom,t.bottom),e.right=Math.max(e.right,t.right)}function eee(e,t,n,r){const{pos:s,box:i}=n,o=e.maxPadding;if(!_t(s)){n.size&&(e[s]-=n.size);const c=r[n.stack]||{size:0,count:1};c.size=Math.max(c.size,n.horizontal?i.height:i.width),n.size=c.size/c.count,e[s]+=n.size}i.getPadding&&zM(o,i.getPadding());const a=Math.max(0,t.outerWidth-wx(o,e,"left","right")),l=Math.max(0,t.outerHeight-wx(o,e,"top","bottom")),u=a!==e.w,d=l!==e.h;return e.w=a,e.h=l,n.horizontal?{same:u,other:d}:{same:d,other:u}}function tee(e){const t=e.maxPadding;function n(r){const s=Math.max(t[r]-e[r],0);return e[r]+=s,s}e.y+=n("top"),e.x+=n("left"),n("right"),n("bottom")}function nee(e,t){const n=t.maxPadding;function r(s){const i={left:0,top:0,right:0,bottom:0};return s.forEach(o=>{i[o]=Math.max(t[o],n[o])}),i}return r(e?["left","right"]:["top","bottom"])}function pc(e,t,n,r){const s=[];let i,o,a,l,u,d;for(i=0,o=e.length,u=0;i<o;++i){a=e[i],l=a.box,l.update(a.width||t.w,a.height||t.h,nee(a.horizontal,t));const{same:c,other:f}=eee(t,n,a,r);u|=c&&s.length,d=d||f,l.fullSize||s.push(a)}return u&&pc(s,t,n,r)||d}function Of(e,t,n,r,s){e.top=n,e.left=t,e.right=t+r,e.bottom=n+s,e.width=r,e.height=s}function Sx(e,t,n,r){const s=n.padding;let{x:i,y:o}=t;for(const a of e){const l=a.box,u=r[a.stack]||{count:1,placed:0,weight:1},d=a.stackWeight/u.weight||1;if(a.horizontal){const c=t.w*d,f=u.size||l.height;fd(u.start)&&(o=u.start),l.fullSize?Of(l,s.left,o,n.outerWidth-s.right-s.left,f):Of(l,t.left+u.placed,o,c,f),u.start=o,u.placed+=c,o=l.bottom}else{const c=t.h*d,f=u.size||l.width;fd(u.start)&&(i=u.start),l.fullSize?Of(l,i,s.top,f,n.outerHeight-s.bottom-s.top):Of(l,i,t.top+u.placed,f,c),u.start=i,u.placed+=c,i=l.right}}t.x=i,t.y=o}var cs={addBox(e,t){e.boxes||(e.boxes=[]),t.fullSize=t.fullSize||!1,t.position=t.position||"top",t.weight=t.weight||0,t._layers=t._layers||function(){return[{z:0,draw(n){t.draw(n)}}]},e.boxes.push(t)},removeBox(e,t){const n=e.boxes?e.boxes.indexOf(t):-1;n!==-1&&e.boxes.splice(n,1)},configure(e,t,n){t.fullSize=n.fullSize,t.position=n.position,t.weight=n.weight},update(e,t,n,r){if(!e)return;const s=ir(e.options.layout.padding),i=Math.max(t-s.width,0),o=Math.max(n-s.height,0),a=ZZ(e.boxes),l=a.vertical,u=a.horizontal;It(e.boxes,m=>{typeof m.beforeLayout=="function"&&m.beforeLayout()});const d=l.reduce((m,y)=>y.box.options&&y.box.options.display===!1?m:m+1,0)||1,c=Object.freeze({outerWidth:t,outerHeight:n,padding:s,availableWidth:i,availableHeight:o,vBoxMaxWidth:i/2/d,hBoxMaxHeight:o/2}),f=Object.assign({},s);zM(f,ir(r));const p=Object.assign({maxPadding:f,w:i,h:o,x:s.left,y:s.top},s),g=JZ(l.concat(u),c);pc(a.fullSize,p,c,g),pc(l,p,c,g),pc(u,p,c,g)&&pc(l,p,c,g),tee(p),Sx(a.leftAndTop,p,c,g),p.x+=p.w,p.y+=p.h,Sx(a.rightAndBottom,p,c,g),e.chartArea={left:p.left,top:p.top,right:p.left+p.w,bottom:p.top+p.h,height:p.h,width:p.w},It(a.chartArea,m=>{const y=m.box;Object.assign(y,e.chartArea),y.update(p.w,p.h,{left:0,top:0,right:0,bottom:0})})}};class jM{acquireContext(t,n){}releaseContext(t){return!1}addEventListener(t,n,r){}removeEventListener(t,n,r){}getDevicePixelRatio(){return 1}getMaximumSize(t,n,r,s){return n=Math.max(0,n||t.width),r=r||t.height,{width:n,height:Math.max(0,s?Math.floor(n/s):r)}}isAttached(t){return!0}updateConfig(t){}}class ree extends jM{acquireContext(t){return t&&t.getContext&&t.getContext("2d")||null}updateConfig(t){t.options.animation=!1}}const gh="$chartjs",see={touchstart:"mousedown",touchmove:"mousemove",touchend:"mouseup",pointerenter:"mouseenter",pointerdown:"mousedown",pointermove:"mousemove",pointerup:"mouseup",pointerleave:"mouseout",pointerout:"mouseout"},_x=e=>e===null||e==="";function iee(e,t){const n=e.style,r=e.getAttribute("height"),s=e.getAttribute("width");if(e[gh]={initial:{height:r,width:s,style:{display:n.display,height:n.height,width:n.width}}},n.display=n.display||"block",n.boxSizing=n.boxSizing||"border-box",_x(s)){const i=lx(e,"width");i!==void 0&&(e.width=i)}if(_x(r))if(e.style.height==="")e.height=e.width/(t||2);else{const i=lx(e,"height");i!==void 0&&(e.height=i)}return e}const qM=vZ?{passive:!0}:!1;function oee(e,t,n){e&&e.addEventListener(t,n,qM)}function aee(e,t,n){e&&e.canvas&&e.canvas.removeEventListener(t,n,qM)}function lee(e,t){const n=see[e.type]||e.type,{x:r,y:s}=pa(e,t);return{type:n,chart:t,native:e,x:r!==void 0?r:null,y:s!==void 0?s:null}}function gp(e,t){for(const n of e)if(n===t||n.contains(t))return!0}function uee(e,t,n){const r=e.canvas,s=new MutationObserver(i=>{let o=!1;for(const a of i)o=o||gp(a.addedNodes,r),o=o&&!gp(a.removedNodes,r);o&&n()});return s.observe(document,{childList:!0,subtree:!0}),s}function cee(e,t,n){const r=e.canvas,s=new MutationObserver(i=>{let o=!1;for(const a of i)o=o||gp(a.removedNodes,r),o=o&&!gp(a.addedNodes,r);o&&n()});return s.observe(document,{childList:!0,subtree:!0}),s}const pd=new Map;let kx=0;function WM(){const e=window.devicePixelRatio;e!==kx&&(kx=e,pd.forEach((t,n)=>{n.currentDevicePixelRatio!==e&&t()}))}function dee(e,t){pd.size||window.addEventListener("resize",WM),pd.set(e,t)}function fee(e){pd.delete(e),pd.size||window.removeEventListener("resize",WM)}function hee(e,t,n){const r=e.canvas,s=r&&gS(r);if(!s)return;const i=PM((a,l)=>{const u=s.clientWidth;n(a,l),u<s.clientWidth&&n()},window),o=new ResizeObserver(a=>{const l=a[0],u=l.contentRect.width,d=l.contentRect.height;u===0&&d===0||i(u,d)});return o.observe(s),dee(e,i),o}function Ug(e,t,n){n&&n.disconnect(),t==="resize"&&fee(e)}function pee(e,t,n){const r=e.canvas,s=PM(i=>{e.ctx!==null&&n(lee(i,e))},e);return oee(r,t,s),s}class mee extends jM{acquireContext(t,n){const r=t&&t.getContext&&t.getContext("2d");return r&&r.canvas===t?(iee(t,n),r):null}releaseContext(t){const n=t.canvas;if(!n[gh])return!1;const r=n[gh].initial;["height","width"].forEach(i=>{const o=r[i];Lt(o)?n.removeAttribute(i):n.setAttribute(i,o)});const s=r.style||{};return Object.keys(s).forEach(i=>{n.style[i]=s[i]}),n.width=n.width,delete n[gh],!0}addEventListener(t,n,r){this.removeEventListener(t,n);const s=t.$proxies||(t.$proxies={}),o={attach:uee,detach:cee,resize:hee}[n]||pee;s[n]=o(t,n,r)}removeEventListener(t,n){const r=t.$proxies||(t.$proxies={}),s=r[n];if(!s)return;({attach:Ug,detach:Ug,resize:Ug}[n]||aee)(t,n,s),r[n]=void 0}getDevicePixelRatio(){return window.devicePixelRatio}getMaximumSize(t,n,r,s){return gZ(t,n,r,s)}isAttached(t){const n=t&&gS(t);return!!(n&&n.isConnected)}}function gee(e){return!mS()||typeof OffscreenCanvas<"u"&&e instanceof OffscreenCanvas?ree:mee}var jf;let ju=(jf=class{constructor(){he(this,"x");he(this,"y");he(this,"active",!1);he(this,"options");he(this,"$animations")}tooltipPosition(t){const{x:n,y:r}=this.getProps(["x","y"],t);return{x:n,y:r}}hasValue(){return hp(this.x)&&hp(this.y)}getProps(t,n){const r=this.$animations;if(!n||!r)return this;const s={};return t.forEach(i=>{s[i]=r[i]&&r[i].active()?r[i]._to:this[i]}),s}},he(jf,"defaults",{}),he(jf,"defaultRoutes"),jf);function vee(e,t){const n=e.options.ticks,r=yee(e),s=Math.min(n.maxTicksLimit||r,r),i=n.major.enabled?wee(t):[],o=i.length,a=i[0],l=i[o-1],u=[];if(o>s)return See(t,u,i,o/s),u;const d=bee(i,t,s);if(o>0){let c,f;const p=o>1?Math.round((l-a)/(o-1)):null;for(Mf(t,u,d,Lt(p)?0:a-p,a),c=0,f=o-1;c<f;c++)Mf(t,u,d,i[c],i[c+1]);return Mf(t,u,d,l,Lt(p)?t.length:l+p),u}return Mf(t,u,d),u}function yee(e){const t=e.options.offset,n=e._tickSize(),r=e._length/n+(t?0:1),s=e._maxLength/n;return Math.floor(Math.min(r,s))}function bee(e,t,n){const r=_ee(e),s=t.length/n;if(!r)return Math.max(s,1);const i=PJ(r);for(let o=0,a=i.length-1;o<a;o++){const l=i[o];if(l>s)return l}return Math.max(s,1)}function wee(e){const t=[];let n,r;for(n=0,r=e.length;n<r;n++)e[n].major&&t.push(n);return t}function See(e,t,n,r){let s=0,i=n[0],o;for(r=Math.ceil(r),o=0;o<e.length;o++)o===i&&(t.push(e[o]),s++,i=n[s*r])}function Mf(e,t,n,r,s){const i=Ct(r,0),o=Math.min(Ct(s,e.length),e.length);let a=0,l,u,d;for(n=Math.ceil(n),s&&(l=s-r,n=l/Math.floor(l/n)),d=i;d<0;)a++,d=Math.round(i+a*n);for(u=Math.max(i,0);u<o;u++)u===d&&(t.push(e[u]),a++,d=Math.round(i+a*n))}function _ee(e){const t=e.length;let n,r;if(t<2)return!1;for(r=e[0],n=1;n<t;++n)if(e[n]-e[n-1]!==r)return!1;return r}const kee=e=>e==="left"?"right":e==="right"?"left":e,xx=(e,t,n)=>t==="top"||t==="left"?e[t]+n:e[t]-n,Ex=(e,t)=>Math.min(t||e,e);function Cx(e,t){const n=[],r=e.length/t,s=e.length;let i=0;for(;i<s;i+=r)n.push(e[Math.floor(i)]);return n}function xee(e,t,n){const r=e.ticks.length,s=Math.min(t,r-1),i=e._startPixel,o=e._endPixel,a=1e-6;let l=e.getPixelForTick(s),u;if(!(n&&(r===1?u=Math.max(l-i,o-l):t===0?u=(e.getPixelForTick(1)-l)/2:u=(l-e.getPixelForTick(s-1))/2,l+=s<t?u:-u,l<i-a||l>o+a)))return l}function Eee(e,t){It(e,n=>{const r=n.gc,s=r.length/2;let i;if(s>t){for(i=0;i<s;++i)delete n.data[r[i]];r.splice(0,s)}})}function ic(e){return e.drawTicks?e.tickLength:0}function Px(e,t){if(!e.display)return 0;const n=Cn(e.font,t),r=ir(e.padding);return(on(e.text)?e.text.length:1)*n.lineHeight+r.height}function Cee(e,t){return al(e,{scale:t,type:"scale"})}function Pee(e,t,n){return al(e,{tick:n,index:t,type:"tick"})}function Tee(e,t,n){let r=lS(e);return(n&&t!=="right"||!n&&t==="right")&&(r=kee(r)),r}function Ree(e,t,n,r){const{top:s,left:i,bottom:o,right:a,chart:l}=e,{chartArea:u,scales:d}=l;let c=0,f,p,g;const m=o-s,y=a-i;if(e.isHorizontal()){if(p=Yn(r,i,a),_t(n)){const b=Object.keys(n)[0],w=n[b];g=d[b].getPixelForValue(w)+m-t}else n==="center"?g=(u.bottom+u.top)/2+m-t:g=xx(e,n,t);f=a-i}else{if(_t(n)){const b=Object.keys(n)[0],w=n[b];p=d[b].getPixelForValue(w)-y+t}else n==="center"?p=(u.left+u.right)/2-y+t:p=xx(e,n,t);g=Yn(r,o,s),c=n==="left"?-Xr:Xr}return{titleX:p,titleY:g,maxWidth:f,rotation:c}}class ll extends ju{constructor(t){super(),this.id=t.id,this.type=t.type,this.options=void 0,this.ctx=t.ctx,this.chart=t.chart,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.width=void 0,this.height=void 0,this._margins={left:0,right:0,top:0,bottom:0},this.maxWidth=void 0,this.maxHeight=void 0,this.paddingTop=void 0,this.paddingBottom=void 0,this.paddingLeft=void 0,this.paddingRight=void 0,this.axis=void 0,this.labelRotation=void 0,this.min=void 0,this.max=void 0,this._range=void 0,this.ticks=[],this._gridLineItems=null,this._labelItems=null,this._labelSizes=null,this._length=0,this._maxLength=0,this._longestTextCache={},this._startPixel=void 0,this._endPixel=void 0,this._reversePixels=!1,this._userMax=void 0,this._userMin=void 0,this._suggestedMax=void 0,this._suggestedMin=void 0,this._ticksLength=0,this._borderValue=0,this._cache={},this._dataLimitsCached=!1,this.$context=void 0}init(t){this.options=t.setContext(this.getContext()),this.axis=t.axis,this._userMin=this.parse(t.min),this._userMax=this.parse(t.max),this._suggestedMin=this.parse(t.suggestedMin),this._suggestedMax=this.parse(t.suggestedMax)}parse(t,n){return t}getUserBounds(){let{_userMin:t,_userMax:n,_suggestedMin:r,_suggestedMax:s}=this;return t=Hr(t,Number.POSITIVE_INFINITY),n=Hr(n,Number.NEGATIVE_INFINITY),r=Hr(r,Number.POSITIVE_INFINITY),s=Hr(s,Number.NEGATIVE_INFINITY),{min:Hr(t,r),max:Hr(n,s),minDefined:Mn(t),maxDefined:Mn(n)}}getMinMax(t){let{min:n,max:r,minDefined:s,maxDefined:i}=this.getUserBounds(),o;if(s&&i)return{min:n,max:r};const a=this.getMatchingVisibleMetas();for(let l=0,u=a.length;l<u;++l)o=a[l].controller.getMinMax(this,t),s||(n=Math.min(n,o.min)),i||(r=Math.max(r,o.max));return n=i&&n>r?r:n,r=s&&n>r?n:r,{min:Hr(n,Hr(r,n)),max:Hr(r,Hr(n,r))}}getPadding(){return{left:this.paddingLeft||0,top:this.paddingTop||0,right:this.paddingRight||0,bottom:this.paddingBottom||0}}getTicks(){return this.ticks}getLabels(){const t=this.chart.data;return this.options.labels||(this.isHorizontal()?t.xLabels:t.yLabels)||t.labels||[]}getLabelItems(t=this.chart.chartArea){return this._labelItems||(this._labelItems=this._computeLabelItems(t))}beforeLayout(){this._cache={},this._dataLimitsCached=!1}beforeUpdate(){jt(this.options.beforeUpdate,[this])}update(t,n,r){const{beginAtZero:s,grace:i,ticks:o}=this.options,a=o.sampleSize;this.beforeUpdate(),this.maxWidth=t,this.maxHeight=n,this._margins=r=Object.assign({left:0,right:0,top:0,bottom:0},r),this.ticks=null,this._labelSizes=null,this._gridLineItems=null,this._labelItems=null,this.beforeSetDimensions(),this.setDimensions(),this.afterSetDimensions(),this._maxLength=this.isHorizontal()?this.width+r.left+r.right:this.height+r.top+r.bottom,this._dataLimitsCached||(this.beforeDataLimits(),this.determineDataLimits(),this.afterDataLimits(),this._range=tZ(this,i,s),this._dataLimitsCached=!0),this.beforeBuildTicks(),this.ticks=this.buildTicks()||[],this.afterBuildTicks();const l=a<this.ticks.length;this._convertTicksToLabels(l?Cx(this.ticks,a):this.ticks),this.configure(),this.beforeCalculateLabelRotation(),this.calculateLabelRotation(),this.afterCalculateLabelRotation(),o.display&&(o.autoSkip||o.source==="auto")&&(this.ticks=vee(this,this.ticks),this._labelSizes=null,this.afterAutoSkip()),l&&this._convertTicksToLabels(this.ticks),this.beforeFit(),this.fit(),this.afterFit(),this.afterUpdate()}configure(){let t=this.options.reverse,n,r;this.isHorizontal()?(n=this.left,r=this.right):(n=this.top,r=this.bottom,t=!t),this._startPixel=n,this._endPixel=r,this._reversePixels=t,this._length=r-n,this._alignToPixels=this.options.alignToPixels}afterUpdate(){jt(this.options.afterUpdate,[this])}beforeSetDimensions(){jt(this.options.beforeSetDimensions,[this])}setDimensions(){this.isHorizontal()?(this.width=this.maxWidth,this.left=0,this.right=this.width):(this.height=this.maxHeight,this.top=0,this.bottom=this.height),this.paddingLeft=0,this.paddingTop=0,this.paddingRight=0,this.paddingBottom=0}afterSetDimensions(){jt(this.options.afterSetDimensions,[this])}_callHooks(t){this.chart.notifyPlugins(t,this.getContext()),jt(this.options[t],[this])}beforeDataLimits(){this._callHooks("beforeDataLimits")}determineDataLimits(){}afterDataLimits(){this._callHooks("afterDataLimits")}beforeBuildTicks(){this._callHooks("beforeBuildTicks")}buildTicks(){return[]}afterBuildTicks(){this._callHooks("afterBuildTicks")}beforeTickToLabelConversion(){jt(this.options.beforeTickToLabelConversion,[this])}generateTickLabels(t){const n=this.options.ticks;let r,s,i;for(r=0,s=t.length;r<s;r++)i=t[r],i.label=jt(n.callback,[i.value,r,t],this)}afterTickToLabelConversion(){jt(this.options.afterTickToLabelConversion,[this])}beforeCalculateLabelRotation(){jt(this.options.beforeCalculateLabelRotation,[this])}calculateLabelRotation(){const t=this.options,n=t.ticks,r=Ex(this.ticks.length,t.ticks.maxTicksLimit),s=n.minRotation||0,i=n.maxRotation;let o=s,a,l,u;if(!this._isVisible()||!n.display||s>=i||r<=1||!this.isHorizontal()){this.labelRotation=s;return}const d=this._getLabelSizes(),c=d.widest.width,f=d.highest.height,p=Ps(this.chart.width-c,0,this.maxWidth);a=t.offset?this.maxWidth/r:p/(r-1),c+6>a&&(a=p/(r-(t.offset?.5:1)),l=this.maxHeight-ic(t.grid)-n.padding-Px(t.title,this.chart.options.font),u=Math.sqrt(c*c+f*f),o=oS(Math.min(Math.asin(Ps((d.highest.height+6)/a,-1,1)),Math.asin(Ps(l/u,-1,1))-Math.asin(Ps(f/u,-1,1)))),o=Math.max(s,Math.min(i,o))),this.labelRotation=o}afterCalculateLabelRotation(){jt(this.options.afterCalculateLabelRotation,[this])}afterAutoSkip(){}beforeFit(){jt(this.options.beforeFit,[this])}fit(){const t={width:0,height:0},{chart:n,options:{ticks:r,title:s,grid:i}}=this,o=this._isVisible(),a=this.isHorizontal();if(o){const l=Px(s,n.options.font);if(a?(t.width=this.maxWidth,t.height=ic(i)+l):(t.height=this.maxHeight,t.width=ic(i)+l),r.display&&this.ticks.length){const{first:u,last:d,widest:c,highest:f}=this._getLabelSizes(),p=r.padding*2,g=Co(this.labelRotation),m=Math.cos(g),y=Math.sin(g);if(a){const b=r.mirror?0:y*c.width+m*f.height;t.height=Math.min(this.maxHeight,t.height+b+p)}else{const b=r.mirror?0:m*c.width+y*f.height;t.width=Math.min(this.maxWidth,t.width+b+p)}this._calculatePadding(u,d,y,m)}}this._handleMargins(),a?(this.width=this._length=n.width-this._margins.left-this._margins.right,this.height=t.height):(this.width=t.width,this.height=this._length=n.height-this._margins.top-this._margins.bottom)}_calculatePadding(t,n,r,s){const{ticks:{align:i,padding:o},position:a}=this.options,l=this.labelRotation!==0,u=a!=="top"&&this.axis==="x";if(this.isHorizontal()){const d=this.getPixelForTick(0)-this.left,c=this.right-this.getPixelForTick(this.ticks.length-1);let f=0,p=0;l?u?(f=s*t.width,p=r*n.height):(f=r*t.height,p=s*n.width):i==="start"?p=n.width:i==="end"?f=t.width:i!=="inner"&&(f=t.width/2,p=n.width/2),this.paddingLeft=Math.max((f-d+o)*this.width/(this.width-d),0),this.paddingRight=Math.max((p-c+o)*this.width/(this.width-c),0)}else{let d=n.height/2,c=t.height/2;i==="start"?(d=0,c=t.height):i==="end"&&(d=n.height,c=0),this.paddingTop=d+o,this.paddingBottom=c+o}}_handleMargins(){this._margins&&(this._margins.left=Math.max(this.paddingLeft,this._margins.left),this._margins.top=Math.max(this.paddingTop,this._margins.top),this._margins.right=Math.max(this.paddingRight,this._margins.right),this._margins.bottom=Math.max(this.paddingBottom,this._margins.bottom))}afterFit(){jt(this.options.afterFit,[this])}isHorizontal(){const{axis:t,position:n}=this.options;return n==="top"||n==="bottom"||t==="x"}isFullSize(){return this.options.fullSize}_convertTicksToLabels(t){this.beforeTickToLabelConversion(),this.generateTickLabels(t);let n,r;for(n=0,r=t.length;n<r;n++)Lt(t[n].label)&&(t.splice(n,1),r--,n--);this.afterTickToLabelConversion()}_getLabelSizes(){let t=this._labelSizes;if(!t){const n=this.options.ticks.sampleSize;let r=this.ticks;n<r.length&&(r=Cx(r,n)),this._labelSizes=t=this._computeLabelSizes(r,r.length,this.options.ticks.maxTicksLimit)}return t}_computeLabelSizes(t,n,r){const{ctx:s,_longestTextCache:i}=this,o=[],a=[],l=Math.floor(n/Ex(n,r));let u=0,d=0,c,f,p,g,m,y,b,w,S,P,E;for(c=0;c<n;c+=l){if(g=t[c].label,m=this._resolveTickFontOptions(c),s.font=y=m.string,b=i[y]=i[y]||{data:{},gc:[]},w=m.lineHeight,S=P=0,!Lt(g)&&!on(g))S=pp(s,b.data,b.gc,S,g),P=w;else if(on(g))for(f=0,p=g.length;f<p;++f)E=g[f],!Lt(E)&&!on(E)&&(S=pp(s,b.data,b.gc,S,E),P+=w);o.push(S),a.push(P),u=Math.max(S,u),d=Math.max(P,d)}Eee(i,n);const T=o.indexOf(u),C=a.indexOf(d),k=x=>({width:o[x]||0,height:a[x]||0});return{first:k(0),last:k(n-1),widest:k(T),highest:k(C),widths:o,heights:a}}getLabelForValue(t){return t}getPixelForValue(t,n){return NaN}getValueForPixel(t){}getPixelForTick(t){const n=this.ticks;return t<0||t>n.length-1?null:this.getPixelForValue(n[t].value)}getPixelForDecimal(t){this._reversePixels&&(t=1-t);const n=this._startPixel+t*this._length;return OJ(this._alignToPixels?la(this.chart,n,0):n)}getDecimalForPixel(t){const n=(t-this._startPixel)/this._length;return this._reversePixels?1-n:n}getBasePixel(){return this.getPixelForValue(this.getBaseValue())}getBaseValue(){const{min:t,max:n}=this;return t<0&&n<0?n:t>0&&n>0?t:0}getContext(t){const n=this.ticks||[];if(t>=0&&t<n.length){const r=n[t];return r.$context||(r.$context=Pee(this.getContext(),t,r))}return this.$context||(this.$context=Cee(this.chart.getContext(),this))}_tickSize(){const t=this.options.ticks,n=Co(this.labelRotation),r=Math.abs(Math.cos(n)),s=Math.abs(Math.sin(n)),i=this._getLabelSizes(),o=t.autoSkipPadding||0,a=i?i.widest.width+o:0,l=i?i.highest.height+o:0;return this.isHorizontal()?l*r>a*s?a/r:l/s:l*s<a*r?l/r:a/s}_isVisible(){const t=this.options.display;return t!=="auto"?!!t:this.getMatchingVisibleMetas().length>0}_computeGridLineItems(t){const n=this.axis,r=this.chart,s=this.options,{grid:i,position:o,border:a}=s,l=i.offset,u=this.isHorizontal(),c=this.ticks.length+(l?1:0),f=ic(i),p=[],g=a.setContext(this.getContext()),m=g.display?g.width:0,y=m/2,b=function(H){return la(r,H,m)};let w,S,P,E,T,C,k,x,I,M,O,A;if(o==="top")w=b(this.bottom),C=this.bottom-f,x=w-y,M=b(t.top)+y,A=t.bottom;else if(o==="bottom")w=b(this.top),M=t.top,A=b(t.bottom)-y,C=w+y,x=this.top+f;else if(o==="left")w=b(this.right),T=this.right-f,k=w-y,I=b(t.left)+y,O=t.right;else if(o==="right")w=b(this.left),I=t.left,O=b(t.right)-y,T=w+y,k=this.left+f;else if(n==="x"){if(o==="center")w=b((t.top+t.bottom)/2+.5);else if(_t(o)){const H=Object.keys(o)[0],G=o[H];w=b(this.chart.scales[H].getPixelForValue(G))}M=t.top,A=t.bottom,C=w+y,x=C+f}else if(n==="y"){if(o==="center")w=b((t.left+t.right)/2);else if(_t(o)){const H=Object.keys(o)[0],G=o[H];w=b(this.chart.scales[H].getPixelForValue(G))}T=w-y,k=T-f,I=t.left,O=t.right}const D=Ct(s.ticks.maxTicksLimit,c),V=Math.max(1,Math.ceil(c/D));for(S=0;S<c;S+=V){const H=this.getContext(S),G=i.setContext(H),j=a.setContext(H),B=G.lineWidth,W=G.color,Z=j.dash||[],q=j.dashOffset,K=G.tickWidth,pe=G.tickColor,ue=G.tickBorderDash||[],le=G.tickBorderDashOffset;P=xee(this,S,l),P!==void 0&&(E=la(r,P,B),u?T=k=I=O=E:C=x=M=A=E,p.push({tx1:T,ty1:C,tx2:k,ty2:x,x1:I,y1:M,x2:O,y2:A,width:B,color:W,borderDash:Z,borderDashOffset:q,tickWidth:K,tickColor:pe,tickBorderDash:ue,tickBorderDashOffset:le}))}return this._ticksLength=c,this._borderValue=w,p}_computeLabelItems(t){const n=this.axis,r=this.options,{position:s,ticks:i}=r,o=this.isHorizontal(),a=this.ticks,{align:l,crossAlign:u,padding:d,mirror:c}=i,f=ic(r.grid),p=f+d,g=c?-d:p,m=-Co(this.labelRotation),y=[];let b,w,S,P,E,T,C,k,x,I,M,O,A="middle";if(s==="top")T=this.bottom-g,C=this._getXAxisLabelAlignment();else if(s==="bottom")T=this.top+g,C=this._getXAxisLabelAlignment();else if(s==="left"){const V=this._getYAxisLabelAlignment(f);C=V.textAlign,E=V.x}else if(s==="right"){const V=this._getYAxisLabelAlignment(f);C=V.textAlign,E=V.x}else if(n==="x"){if(s==="center")T=(t.top+t.bottom)/2+p;else if(_t(s)){const V=Object.keys(s)[0],H=s[V];T=this.chart.scales[V].getPixelForValue(H)+p}C=this._getXAxisLabelAlignment()}else if(n==="y"){if(s==="center")E=(t.left+t.right)/2-p;else if(_t(s)){const V=Object.keys(s)[0],H=s[V];E=this.chart.scales[V].getPixelForValue(H)}C=this._getYAxisLabelAlignment(f).textAlign}n==="y"&&(l==="start"?A="top":l==="end"&&(A="bottom"));const D=this._getLabelSizes();for(b=0,w=a.length;b<w;++b){S=a[b],P=S.label;const V=i.setContext(this.getContext(b));k=this.getPixelForTick(b)+i.labelOffset,x=this._resolveTickFontOptions(b),I=x.lineHeight,M=on(P)?P.length:1;const H=M/2,G=V.color,j=V.textStrokeColor,B=V.textStrokeWidth;let W=C;o?(E=k,C==="inner"&&(b===w-1?W=this.options.reverse?"left":"right":b===0?W=this.options.reverse?"right":"left":W="center"),s==="top"?u==="near"||m!==0?O=-M*I+I/2:u==="center"?O=-D.highest.height/2-H*I+I:O=-D.highest.height+I/2:u==="near"||m!==0?O=I/2:u==="center"?O=D.highest.height/2-H*I:O=D.highest.height-M*I,c&&(O*=-1),m!==0&&!V.showLabelBackdrop&&(E+=I/2*Math.sin(m))):(T=k,O=(1-M)*I/2);let Z;if(V.showLabelBackdrop){const q=ir(V.backdropPadding),K=D.heights[b],pe=D.widths[b];let ue=O-q.top,le=0-q.left;switch(A){case"middle":ue-=K/2;break;case"bottom":ue-=K;break}switch(C){case"center":le-=pe/2;break;case"right":le-=pe;break;case"inner":b===w-1?le-=pe:b>0&&(le-=pe/2);break}Z={left:le,top:ue,width:pe+q.width,height:K+q.height,color:V.backdropColor}}y.push({label:P,font:x,textOffset:O,options:{rotation:m,color:G,strokeColor:j,strokeWidth:B,textAlign:W,textBaseline:A,translation:[E,T],backdrop:Z}})}return y}_getXAxisLabelAlignment(){const{position:t,ticks:n}=this.options;if(-Co(this.labelRotation))return t==="top"?"left":"right";let s="center";return n.align==="start"?s="left":n.align==="end"?s="right":n.align==="inner"&&(s="inner"),s}_getYAxisLabelAlignment(t){const{position:n,ticks:{crossAlign:r,mirror:s,padding:i}}=this.options,o=this._getLabelSizes(),a=t+i,l=o.widest.width;let u,d;return n==="left"?s?(d=this.right+i,r==="near"?u="left":r==="center"?(u="center",d+=l/2):(u="right",d+=l)):(d=this.right-a,r==="near"?u="right":r==="center"?(u="center",d-=l/2):(u="left",d=this.left)):n==="right"?s?(d=this.left+i,r==="near"?u="right":r==="center"?(u="center",d-=l/2):(u="left",d-=l)):(d=this.left+a,r==="near"?u="left":r==="center"?(u="center",d+=l/2):(u="right",d=this.right)):u="right",{textAlign:u,x:d}}_computeLabelArea(){if(this.options.ticks.mirror)return;const t=this.chart,n=this.options.position;if(n==="left"||n==="right")return{top:0,left:this.left,bottom:t.height,right:this.right};if(n==="top"||n==="bottom")return{top:this.top,left:0,bottom:this.bottom,right:t.width}}drawBackground(){const{ctx:t,options:{backgroundColor:n},left:r,top:s,width:i,height:o}=this;n&&(t.save(),t.fillStyle=n,t.fillRect(r,s,i,o),t.restore())}getLineWidthForValue(t){const n=this.options.grid;if(!this._isVisible()||!n.display)return 0;const s=this.ticks.findIndex(i=>i.value===t);return s>=0?n.setContext(this.getContext(s)).lineWidth:0}drawGrid(t){const n=this.options.grid,r=this.ctx,s=this._gridLineItems||(this._gridLineItems=this._computeGridLineItems(t));let i,o;const a=(l,u,d)=>{!d.width||!d.color||(r.save(),r.lineWidth=d.width,r.strokeStyle=d.color,r.setLineDash(d.borderDash||[]),r.lineDashOffset=d.borderDashOffset,r.beginPath(),r.moveTo(l.x,l.y),r.lineTo(u.x,u.y),r.stroke(),r.restore())};if(n.display)for(i=0,o=s.length;i<o;++i){const l=s[i];n.drawOnChartArea&&a({x:l.x1,y:l.y1},{x:l.x2,y:l.y2},l),n.drawTicks&&a({x:l.tx1,y:l.ty1},{x:l.tx2,y:l.ty2},{color:l.tickColor,width:l.tickWidth,borderDash:l.tickBorderDash,borderDashOffset:l.tickBorderDashOffset})}}drawBorder(){const{chart:t,ctx:n,options:{border:r,grid:s}}=this,i=r.setContext(this.getContext()),o=r.display?i.width:0;if(!o)return;const a=s.setContext(this.getContext(0)).lineWidth,l=this._borderValue;let u,d,c,f;this.isHorizontal()?(u=la(t,this.left,o)-o/2,d=la(t,this.right,a)+a/2,c=f=l):(c=la(t,this.top,o)-o/2,f=la(t,this.bottom,a)+a/2,u=d=l),n.save(),n.lineWidth=i.width,n.strokeStyle=i.color,n.beginPath(),n.moveTo(u,c),n.lineTo(d,f),n.stroke(),n.restore()}drawLabels(t){if(!this.options.ticks.display)return;const r=this.ctx,s=this._computeLabelArea();s&&cS(r,s);const i=this.getLabelItems(t);for(const o of i){const a=o.options,l=o.font,u=o.label,d=o.textOffset;Qa(r,u,0,d,l,a)}s&&dS(r)}drawTitle(){const{ctx:t,options:{position:n,title:r,reverse:s}}=this;if(!r.display)return;const i=Cn(r.font),o=ir(r.padding),a=r.align;let l=i.lineHeight/2;n==="bottom"||n==="center"||_t(n)?(l+=o.bottom,on(r.text)&&(l+=i.lineHeight*(r.text.length-1))):l+=o.top;const{titleX:u,titleY:d,maxWidth:c,rotation:f}=Ree(this,l,n,a);Qa(t,r.text,0,0,i,{color:r.color,maxWidth:c,rotation:f,textAlign:Tee(a,n,s),textBaseline:"middle",translation:[u,d]})}draw(t){this._isVisible()&&(this.drawBackground(),this.drawGrid(t),this.drawBorder(),this.drawTitle(),this.drawLabels(t))}_layers(){const t=this.options,n=t.ticks&&t.ticks.z||0,r=Ct(t.grid&&t.grid.z,-1),s=Ct(t.border&&t.border.z,0);return!this._isVisible()||this.draw!==ll.prototype.draw?[{z:n,draw:i=>{this.draw(i)}}]:[{z:r,draw:i=>{this.drawBackground(),this.drawGrid(i),this.drawTitle()}},{z:s,draw:()=>{this.drawBorder()}},{z:n,draw:i=>{this.drawLabels(i)}}]}getMatchingVisibleMetas(t){const n=this.chart.getSortedVisibleDatasetMetas(),r=this.axis+"AxisID",s=[];let i,o;for(i=0,o=n.length;i<o;++i){const a=n[i];a[r]===this.id&&(!t||a.type===t)&&s.push(a)}return s}_resolveTickFontOptions(t){const n=this.options.ticks.setContext(this.getContext(t));return Cn(n.font)}_maxDigits(){const t=this._resolveTickFontOptions(0).lineHeight;return(this.isHorizontal()?this.width:this.height)/t}}class Df{constructor(t,n,r){this.type=t,this.scope=n,this.override=r,this.items=Object.create(null)}isForType(t){return Object.prototype.isPrototypeOf.call(this.type.prototype,t.prototype)}register(t){const n=Object.getPrototypeOf(t);let r;Oee(n)&&(r=this.register(n));const s=this.items,i=t.id,o=this.scope+"."+i;if(!i)throw new Error("class does not have id: "+t);return i in s||(s[i]=t,Iee(t,o,r),this.override&&fn.override(t.id,t.overrides)),o}get(t){return this.items[t]}unregister(t){const n=this.items,r=t.id,s=this.scope;r in n&&delete n[r],s&&r in fn[s]&&(delete fn[s][r],this.override&&delete Xa[r])}}function Iee(e,t,n){const r=dd(Object.create(null),[n?fn.get(n):{},fn.get(t),e.defaults]);fn.set(t,r),e.defaultRoutes&&Aee(t,e.defaultRoutes),e.descriptors&&fn.describe(t,e.descriptors)}function Aee(e,t){Object.keys(t).forEach(n=>{const r=n.split("."),s=r.pop(),i=[e].concat(r).join("."),o=t[n].split("."),a=o.pop(),l=o.join(".");fn.route(i,s,l,a)})}function Oee(e){return"id"in e&&"defaults"in e}class Mee{constructor(){this.controllers=new Df(Lc,"datasets",!0),this.elements=new Df(ju,"elements"),this.plugins=new Df(Object,"plugins"),this.scales=new Df(ll,"scales"),this._typedRegistries=[this.controllers,this.scales,this.elements]}add(...t){this._each("register",t)}remove(...t){this._each("unregister",t)}addControllers(...t){this._each("register",t,this.controllers)}addElements(...t){this._each("register",t,this.elements)}addPlugins(...t){this._each("register",t,this.plugins)}addScales(...t){this._each("register",t,this.scales)}getController(t){return this._get(t,this.controllers,"controller")}getElement(t){return this._get(t,this.elements,"element")}getPlugin(t){return this._get(t,this.plugins,"plugin")}getScale(t){return this._get(t,this.scales,"scale")}removeControllers(...t){this._each("unregister",t,this.controllers)}removeElements(...t){this._each("unregister",t,this.elements)}removePlugins(...t){this._each("unregister",t,this.plugins)}removeScales(...t){this._each("unregister",t,this.scales)}_each(t,n,r){[...n].forEach(s=>{const i=r||this._getRegistryForType(s);r||i.isForType(s)||i===this.plugins&&s.id?this._exec(t,i,s):It(s,o=>{const a=r||this._getRegistryForType(o);this._exec(t,a,o)})})}_exec(t,n,r){const s=iS(t);jt(r["before"+s],[],r),n[t](r),jt(r["after"+s],[],r)}_getRegistryForType(t){for(let n=0;n<this._typedRegistries.length;n++){const r=this._typedRegistries[n];if(r.isForType(t))return r}return this.plugins}_get(t,n,r){const s=n.get(t);if(s===void 0)throw new Error('"'+t+'" is not a registered '+r+".");return s}}var Ys=new Mee;class Dee{constructor(){this._init=[]}notify(t,n,r,s){n==="beforeInit"&&(this._init=this._createDescriptors(t,!0),this._notify(this._init,t,"install"));const i=s?this._descriptors(t).filter(s):this._descriptors(t),o=this._notify(i,t,n,r);return n==="afterDestroy"&&(this._notify(i,t,"stop"),this._notify(this._init,t,"uninstall")),o}_notify(t,n,r,s){s=s||{};for(const i of t){const o=i.plugin,a=o[r],l=[n,s,i.options];if(jt(a,l,o)===!1&&s.cancelable)return!1}return!0}invalidate(){Lt(this._cache)||(this._oldCache=this._cache,this._cache=void 0)}_descriptors(t){if(this._cache)return this._cache;const n=this._cache=this._createDescriptors(t);return this._notifyStateChanges(t),n}_createDescriptors(t,n){const r=t&&t.config,s=Ct(r.options&&r.options.plugins,{}),i=Lee(r);return s===!1&&!n?[]:Fee(t,i,s,n)}_notifyStateChanges(t){const n=this._oldCache||[],r=this._cache,s=(i,o)=>i.filter(a=>!o.some(l=>a.plugin.id===l.plugin.id));this._notify(s(n,r),t,"stop"),this._notify(s(r,n),t,"start")}}function Lee(e){const t={},n=[],r=Object.keys(Ys.plugins.items);for(let i=0;i<r.length;i++)n.push(Ys.getPlugin(r[i]));const s=e.plugins||[];for(let i=0;i<s.length;i++){const o=s[i];n.indexOf(o)===-1&&(n.push(o),t[o.id]=!0)}return{plugins:n,localIds:t}}function $ee(e,t){return!t&&e===!1?null:e===!0?{}:e}function Fee(e,{plugins:t,localIds:n},r,s){const i=[],o=e.getContext();for(const a of t){const l=a.id,u=$ee(r[l],s);u!==null&&i.push({plugin:a,options:Nee(e.config,{plugin:a,local:n[l]},u,o)})}return i}function Nee(e,{plugin:t,local:n},r,s){const i=e.pluginScopeKeys(t),o=e.getOptionScopes(r,i);return n&&t.defaults&&o.push(t.defaults),e.createResolver(o,s,[""],{scriptable:!1,indexable:!1,allKeys:!0})}function Qy(e,t){const n=fn.datasets[e]||{};return((t.datasets||{})[e]||{}).indexAxis||t.indexAxis||n.indexAxis||"x"}function Bee(e,t){let n=e;return e==="_index_"?n=t:e==="_value_"&&(n=t==="x"?"y":"x"),n}function Vee(e,t){return e===t?"_index_":"_value_"}function Tx(e){if(e==="x"||e==="y"||e==="r")return e}function Uee(e){if(e==="top"||e==="bottom")return"x";if(e==="left"||e==="right")return"y"}function Jy(e,...t){if(Tx(e))return e;for(const n of t){const r=n.axis||Uee(n.position)||e.length>1&&Tx(e[0].toLowerCase());if(r)return r}throw new Error(`Cannot determine type of '${e}' axis. Please provide 'axis' or 'position' option.`)}function Rx(e,t,n){if(n[t+"AxisID"]===e)return{axis:t}}function Hee(e,t){if(t.data&&t.data.datasets){const n=t.data.datasets.filter(r=>r.xAxisID===e||r.yAxisID===e);if(n.length)return Rx(e,"x",n[0])||Rx(e,"y",n[0])}return{}}function zee(e,t){const n=Xa[e.type]||{scales:{}},r=t.scales||{},s=Qy(e.type,t),i=Object.create(null);return Object.keys(r).forEach(o=>{const a=r[o];if(!_t(a))return console.error(`Invalid scale configuration for scale: ${o}`);if(a._proxy)return console.warn(`Ignoring resolver passed as options for scale: ${o}`);const l=Jy(o,a,Hee(o,e),fn.scales[a.type]),u=Vee(l,s),d=n.scales||{};i[o]=Oc(Object.create(null),[{axis:l},a,d[l],d[u]])}),e.data.datasets.forEach(o=>{const a=o.type||e.type,l=o.indexAxis||Qy(a,t),d=(Xa[a]||{}).scales||{};Object.keys(d).forEach(c=>{const f=Bee(c,l),p=o[f+"AxisID"]||f;i[p]=i[p]||Object.create(null),Oc(i[p],[{axis:f},r[p],d[c]])})}),Object.keys(i).forEach(o=>{const a=i[o];Oc(a,[fn.scales[a.type],fn.scale])}),i}function GM(e){const t=e.options||(e.options={});t.plugins=Ct(t.plugins,{}),t.scales=zee(e,t)}function KM(e){return e=e||{},e.datasets=e.datasets||[],e.labels=e.labels||[],e}function jee(e){return e=e||{},e.data=KM(e.data),GM(e),e}const Ix=new Map,YM=new Set;function Lf(e,t){let n=Ix.get(e);return n||(n=t(),Ix.set(e,n),YM.add(n)),n}const oc=(e,t,n)=>{const r=Su(t,n);r!==void 0&&e.add(r)};class qee{constructor(t){this._config=jee(t),this._scopeCache=new Map,this._resolverCache=new Map}get platform(){return this._config.platform}get type(){return this._config.type}set type(t){this._config.type=t}get data(){return this._config.data}set data(t){this._config.data=KM(t)}get options(){return this._config.options}set options(t){this._config.options=t}get plugins(){return this._config.plugins}update(){const t=this._config;this.clearCache(),GM(t)}clearCache(){this._scopeCache.clear(),this._resolverCache.clear()}datasetScopeKeys(t){return Lf(t,()=>[[`datasets.${t}`,""]])}datasetAnimationScopeKeys(t,n){return Lf(`${t}.transition.${n}`,()=>[[`datasets.${t}.transitions.${n}`,`transitions.${n}`],[`datasets.${t}`,""]])}datasetElementScopeKeys(t,n){return Lf(`${t}-${n}`,()=>[[`datasets.${t}.elements.${n}`,`datasets.${t}`,`elements.${n}`,""]])}pluginScopeKeys(t){const n=t.id,r=this.type;return Lf(`${r}-plugin-${n}`,()=>[[`plugins.${n}`,...t.additionalOptionScopes||[]]])}_cachedScopes(t,n){const r=this._scopeCache;let s=r.get(t);return(!s||n)&&(s=new Map,r.set(t,s)),s}getOptionScopes(t,n,r){const{options:s,type:i}=this,o=this._cachedScopes(t,r),a=o.get(n);if(a)return a;const l=new Set;n.forEach(d=>{t&&(l.add(t),d.forEach(c=>oc(l,t,c))),d.forEach(c=>oc(l,s,c)),d.forEach(c=>oc(l,Xa[i]||{},c)),d.forEach(c=>oc(l,fn,c)),d.forEach(c=>oc(l,Xy,c))});const u=Array.from(l);return u.length===0&&u.push(Object.create(null)),YM.has(n)&&o.set(n,u),u}chartOptionScopes(){const{options:t,type:n}=this;return[t,Xa[n]||{},fn.datasets[n]||{},{type:n},fn,Xy]}resolveNamedOptions(t,n,r,s=[""]){const i={$shared:!0},{resolver:o,subPrefixes:a}=Ax(this._resolverCache,t,s);let l=o;if(Gee(o,n)){i.$shared=!1,r=Vo(r)?r():r;const u=this.createResolver(t,r,a);l=_u(o,r,u)}for(const u of n)i[u]=l[u];return i}createResolver(t,n,r=[""],s){const{resolver:i}=Ax(this._resolverCache,t,r);return _t(n)?_u(i,n,void 0,s):i}}function Ax(e,t,n){let r=e.get(t);r||(r=new Map,e.set(t,r));const s=n.join();let i=r.get(s);return i||(i={resolver:fS(t,n),subPrefixes:n.filter(a=>!a.toLowerCase().includes("hover"))},r.set(s,i)),i}const Wee=e=>_t(e)&&Object.getOwnPropertyNames(e).some(t=>Vo(e[t]));function Gee(e,t){const{isScriptable:n,isIndexable:r}=MM(e);for(const s of t){const i=n(s),o=r(s),a=(o||i)&&e[s];if(i&&(Vo(a)||Wee(a))||o&&on(a))return!0}return!1}var Kee="4.4.6";const Yee=["top","bottom","left","right","chartArea"];function Ox(e,t){return e==="top"||e==="bottom"||Yee.indexOf(e)===-1&&t==="x"}function Mx(e,t){return function(n,r){return n[e]===r[e]?n[t]-r[t]:n[e]-r[e]}}function Dx(e){const t=e.chart,n=t.options.animation;t.notifyPlugins("afterRender"),jt(n&&n.onComplete,[e],t)}function Xee(e){const t=e.chart,n=t.options.animation;jt(n&&n.onProgress,[e],t)}function XM(e){return mS()&&typeof e=="string"?e=document.getElementById(e):e&&e.length&&(e=e[0]),e&&e.canvas&&(e=e.canvas),e}const vh={},Lx=e=>{const t=XM(e);return Object.values(vh).filter(n=>n.canvas===t).pop()};function Qee(e,t,n){const r=Object.keys(e);for(const s of r){const i=+s;if(i>=t){const o=e[s];delete e[s],(n>0||i>t)&&(e[i+n]=o)}}}function Jee(e,t,n,r){return!n||e.type==="mouseout"?null:r?t:e}function $f(e,t,n){return e.options.clip?e[n]:t[n]}function Zee(e,t){const{xScale:n,yScale:r}=e;return n&&r?{left:$f(n,t,"left"),right:$f(n,t,"right"),top:$f(r,t,"top"),bottom:$f(r,t,"bottom")}:t}var eo;let Tm=(eo=class{static register(...t){Ys.add(...t),$x()}static unregister(...t){Ys.remove(...t),$x()}constructor(t,n){const r=this.config=new qee(n),s=XM(t),i=Lx(s);if(i)throw new Error("Canvas is already in use. Chart with ID '"+i.id+"' must be destroyed before the canvas with ID '"+i.canvas.id+"' can be reused.");const o=r.createResolver(r.chartOptionScopes(),this.getContext());this.platform=new(r.platform||gee(s)),this.platform.updateConfig(r);const a=this.platform.acquireContext(s,o.aspectRatio),l=a&&a.canvas,u=l&&l.height,d=l&&l.width;if(this.id=bJ(),this.ctx=a,this.canvas=l,this.width=d,this.height=u,this._options=o,this._aspectRatio=this.aspectRatio,this._layers=[],this._metasets=[],this._stacks=void 0,this.boxes=[],this.currentDevicePixelRatio=void 0,this.chartArea=void 0,this._active=[],this._lastEvent=void 0,this._listeners={},this._responsiveListeners=void 0,this._sortedMetasets=[],this.scales={},this._plugins=new Dee,this.$proxies={},this._hiddenIndices={},this.attached=!1,this._animationsDisabled=void 0,this.$context=void 0,this._doResize=$J(c=>this.update(c),o.resizeDelay||0),this._dataChanges=[],vh[this.id]=this,!a||!l){console.error("Failed to create chart: can't acquire context from the given item");return}xi.listen(this,"complete",Dx),xi.listen(this,"progress",Xee),this._initialize(),this.attached&&this.update()}get aspectRatio(){const{options:{aspectRatio:t,maintainAspectRatio:n},width:r,height:s,_aspectRatio:i}=this;return Lt(t)?n&&i?i:s?r/s:null:t}get data(){return this.config.data}set data(t){this.config.data=t}get options(){return this._options}set options(t){this.config.options=t}get registry(){return Ys}_initialize(){return this.notifyPlugins("beforeInit"),this.options.responsive?this.resize():ax(this,this.options.devicePixelRatio),this.bindEvents(),this.notifyPlugins("afterInit"),this}clear(){return rx(this.canvas,this.ctx),this}stop(){return xi.stop(this),this}resize(t,n){xi.running(this)?this._resizeBeforeDraw={width:t,height:n}:this._resize(t,n)}_resize(t,n){const r=this.options,s=this.canvas,i=r.maintainAspectRatio&&this.aspectRatio,o=this.platform.getMaximumSize(s,t,n,i),a=r.devicePixelRatio||this.platform.getDevicePixelRatio(),l=this.width?"resize":"attach";this.width=o.width,this.height=o.height,this._aspectRatio=this.aspectRatio,ax(this,a,!0)&&(this.notifyPlugins("resize",{size:o}),jt(r.onResize,[this,o],this),this.attached&&this._doResize(l)&&this.render())}ensureScalesHaveIDs(){const n=this.options.scales||{};It(n,(r,s)=>{r.id=s})}buildOrUpdateScales(){const t=this.options,n=t.scales,r=this.scales,s=Object.keys(r).reduce((o,a)=>(o[a]=!1,o),{});let i=[];n&&(i=i.concat(Object.keys(n).map(o=>{const a=n[o],l=Jy(o,a),u=l==="r",d=l==="x";return{options:a,dposition:u?"chartArea":d?"bottom":"left",dtype:u?"radialLinear":d?"category":"linear"}}))),It(i,o=>{const a=o.options,l=a.id,u=Jy(l,a),d=Ct(a.type,o.dtype);(a.position===void 0||Ox(a.position,u)!==Ox(o.dposition))&&(a.position=o.dposition),s[l]=!0;let c=null;if(l in r&&r[l].type===d)c=r[l];else{const f=Ys.getScale(d);c=new f({id:l,type:d,ctx:this.ctx,chart:this}),r[c.id]=c}c.init(a,t)}),It(s,(o,a)=>{o||delete r[a]}),It(r,o=>{cs.configure(this,o,o.options),cs.addBox(this,o)})}_updateMetasets(){const t=this._metasets,n=this.data.datasets.length,r=t.length;if(t.sort((s,i)=>s.index-i.index),r>n){for(let s=n;s<r;++s)this._destroyDatasetMeta(s);t.splice(n,r-n)}this._sortedMetasets=t.slice(0).sort(Mx("order","index"))}_removeUnreferencedMetasets(){const{_metasets:t,data:{datasets:n}}=this;t.length>n.length&&delete this._stacks,t.forEach((r,s)=>{n.filter(i=>i===r._dataset).length===0&&this._destroyDatasetMeta(s)})}buildOrUpdateControllers(){const t=[],n=this.data.datasets;let r,s;for(this._removeUnreferencedMetasets(),r=0,s=n.length;r<s;r++){const i=n[r];let o=this.getDatasetMeta(r);const a=i.type||this.config.type;if(o.type&&o.type!==a&&(this._destroyDatasetMeta(r),o=this.getDatasetMeta(r)),o.type=a,o.indexAxis=i.indexAxis||Qy(a,this.options),o.order=i.order||0,o.index=r,o.label=""+i.label,o.visible=this.isDatasetVisible(r),o.controller)o.controller.updateIndex(r),o.controller.linkScales();else{const l=Ys.getController(a),{datasetElementType:u,dataElementType:d}=fn.datasets[a];Object.assign(l,{dataElementType:Ys.getElement(d),datasetElementType:u&&Ys.getElement(u)}),o.controller=new l(this,r),t.push(o.controller)}}return this._updateMetasets(),t}_resetElements(){It(this.data.datasets,(t,n)=>{this.getDatasetMeta(n).controller.reset()},this)}reset(){this._resetElements(),this.notifyPlugins("reset")}update(t){const n=this.config;n.update();const r=this._options=n.createResolver(n.chartOptionScopes(),this.getContext()),s=this._animationsDisabled=!r.animation;if(this._updateScales(),this._checkEventBindings(),this._updateHiddenIndices(),this._plugins.invalidate(),this.notifyPlugins("beforeUpdate",{mode:t,cancelable:!0})===!1)return;const i=this.buildOrUpdateControllers();this.notifyPlugins("beforeElementsUpdate");let o=0;for(let u=0,d=this.data.datasets.length;u<d;u++){const{controller:c}=this.getDatasetMeta(u),f=!s&&i.indexOf(c)===-1;c.buildOrUpdateElements(f),o=Math.max(+c.getMaxOverflow(),o)}o=this._minPadding=r.layout.autoPadding?o:0,this._updateLayout(o),s||It(i,u=>{u.reset()}),this._updateDatasets(t),this.notifyPlugins("afterUpdate",{mode:t}),this._layers.sort(Mx("z","_idx"));const{_active:a,_lastEvent:l}=this;l?this._eventHandler(l,!0):a.length&&this._updateHoverStyles(a,a,!0),this.render()}_updateScales(){It(this.scales,t=>{cs.removeBox(this,t)}),this.ensureScalesHaveIDs(),this.buildOrUpdateScales()}_checkEventBindings(){const t=this.options,n=new Set(Object.keys(this._listeners)),r=new Set(t.events);(!Kk(n,r)||!!this._responsiveListeners!==t.responsive)&&(this.unbindEvents(),this.bindEvents())}_updateHiddenIndices(){const{_hiddenIndices:t}=this,n=this._getUniformDataChanges()||[];for(const{method:r,start:s,count:i}of n){const o=r==="_removeElements"?-i:i;Qee(t,s,o)}}_getUniformDataChanges(){const t=this._dataChanges;if(!t||!t.length)return;this._dataChanges=[];const n=this.data.datasets.length,r=i=>new Set(t.filter(o=>o[0]===i).map((o,a)=>a+","+o.splice(1).join(","))),s=r(0);for(let i=1;i<n;i++)if(!Kk(s,r(i)))return;return Array.from(s).map(i=>i.split(",")).map(i=>({method:i[1],start:+i[2],count:+i[3]}))}_updateLayout(t){if(this.notifyPlugins("beforeLayout",{cancelable:!0})===!1)return;cs.update(this,this.width,this.height,t);const n=this.chartArea,r=n.width<=0||n.height<=0;this._layers=[],It(this.boxes,s=>{r&&s.position==="chartArea"||(s.configure&&s.configure(),this._layers.push(...s._layers()))},this),this._layers.forEach((s,i)=>{s._idx=i}),this.notifyPlugins("afterLayout")}_updateDatasets(t){if(this.notifyPlugins("beforeDatasetsUpdate",{mode:t,cancelable:!0})!==!1){for(let n=0,r=this.data.datasets.length;n<r;++n)this.getDatasetMeta(n).controller.configure();for(let n=0,r=this.data.datasets.length;n<r;++n)this._updateDataset(n,Vo(t)?t({datasetIndex:n}):t);this.notifyPlugins("afterDatasetsUpdate",{mode:t})}}_updateDataset(t,n){const r=this.getDatasetMeta(t),s={meta:r,index:t,mode:n,cancelable:!0};this.notifyPlugins("beforeDatasetUpdate",s)!==!1&&(r.controller._update(n),s.cancelable=!1,this.notifyPlugins("afterDatasetUpdate",s))}render(){this.notifyPlugins("beforeRender",{cancelable:!0})!==!1&&(xi.has(this)?this.attached&&!xi.running(this)&&xi.start(this):(this.draw(),Dx({chart:this})))}draw(){let t;if(this._resizeBeforeDraw){const{width:r,height:s}=this._resizeBeforeDraw;this._resizeBeforeDraw=null,this._resize(r,s)}if(this.clear(),this.width<=0||this.height<=0||this.notifyPlugins("beforeDraw",{cancelable:!0})===!1)return;const n=this._layers;for(t=0;t<n.length&&n[t].z<=0;++t)n[t].draw(this.chartArea);for(this._drawDatasets();t<n.length;++t)n[t].draw(this.chartArea);this.notifyPlugins("afterDraw")}_getSortedDatasetMetas(t){const n=this._sortedMetasets,r=[];let s,i;for(s=0,i=n.length;s<i;++s){const o=n[s];(!t||o.visible)&&r.push(o)}return r}getSortedVisibleDatasetMetas(){return this._getSortedDatasetMetas(!0)}_drawDatasets(){if(this.notifyPlugins("beforeDatasetsDraw",{cancelable:!0})===!1)return;const t=this.getSortedVisibleDatasetMetas();for(let n=t.length-1;n>=0;--n)this._drawDataset(t[n]);this.notifyPlugins("afterDatasetsDraw")}_drawDataset(t){const n=this.ctx,r=t._clip,s=!r.disabled,i=Zee(t,this.chartArea),o={meta:t,index:t.index,cancelable:!0};this.notifyPlugins("beforeDatasetDraw",o)!==!1&&(s&&cS(n,{left:r.left===!1?0:i.left-r.left,right:r.right===!1?this.width:i.right+r.right,top:r.top===!1?0:i.top-r.top,bottom:r.bottom===!1?this.height:i.bottom+r.bottom}),t.controller.draw(),s&&dS(n),o.cancelable=!1,this.notifyPlugins("afterDatasetDraw",o))}isPointInArea(t){return Ll(t,this.chartArea,this._minPadding)}getElementsAtEventForMode(t,n,r,s){const i=YZ.modes[n];return typeof i=="function"?i(this,t,r,s):[]}getDatasetMeta(t){const n=this.data.datasets[t],r=this._metasets;let s=r.filter(i=>i&&i._dataset===n).pop();return s||(s={type:null,data:[],dataset:null,controller:null,hidden:null,xAxisID:null,yAxisID:null,order:n&&n.order||0,index:t,_dataset:n,_parsed:[],_sorted:!1},r.push(s)),s}getContext(){return this.$context||(this.$context=al(null,{chart:this,type:"chart"}))}getVisibleDatasetCount(){return this.getSortedVisibleDatasetMetas().length}isDatasetVisible(t){const n=this.data.datasets[t];if(!n)return!1;const r=this.getDatasetMeta(t);return typeof r.hidden=="boolean"?!r.hidden:!n.hidden}setDatasetVisibility(t,n){const r=this.getDatasetMeta(t);r.hidden=!n}toggleDataVisibility(t){this._hiddenIndices[t]=!this._hiddenIndices[t]}getDataVisibility(t){return!this._hiddenIndices[t]}_updateVisibility(t,n,r){const s=r?"show":"hide",i=this.getDatasetMeta(t),o=i.controller._resolveAnimations(void 0,s);fd(n)?(i.data[n].hidden=!r,this.update()):(this.setDatasetVisibility(t,r),o.update(i,{visible:r}),this.update(a=>a.datasetIndex===t?s:void 0))}hide(t,n){this._updateVisibility(t,n,!1)}show(t,n){this._updateVisibility(t,n,!0)}_destroyDatasetMeta(t){const n=this._metasets[t];n&&n.controller&&n.controller._destroy(),delete this._metasets[t]}_stop(){let t,n;for(this.stop(),xi.remove(this),t=0,n=this.data.datasets.length;t<n;++t)this._destroyDatasetMeta(t)}destroy(){this.notifyPlugins("beforeDestroy");const{canvas:t,ctx:n}=this;this._stop(),this.config.clearCache(),t&&(this.unbindEvents(),rx(t,n),this.platform.releaseContext(n),this.canvas=null,this.ctx=null),delete vh[this.id],this.notifyPlugins("afterDestroy")}toBase64Image(...t){return this.canvas.toDataURL(...t)}bindEvents(){this.bindUserEvents(),this.options.responsive?this.bindResponsiveEvents():this.attached=!0}bindUserEvents(){const t=this._listeners,n=this.platform,r=(i,o)=>{n.addEventListener(this,i,o),t[i]=o},s=(i,o,a)=>{i.offsetX=o,i.offsetY=a,this._eventHandler(i)};It(this.options.events,i=>r(i,s))}bindResponsiveEvents(){this._responsiveListeners||(this._responsiveListeners={});const t=this._responsiveListeners,n=this.platform,r=(l,u)=>{n.addEventListener(this,l,u),t[l]=u},s=(l,u)=>{t[l]&&(n.removeEventListener(this,l,u),delete t[l])},i=(l,u)=>{this.canvas&&this.resize(l,u)};let o;const a=()=>{s("attach",a),this.attached=!0,this.resize(),r("resize",i),r("detach",o)};o=()=>{this.attached=!1,s("resize",i),this._stop(),this._resize(0,0),r("attach",a)},n.isAttached(this.canvas)?a():o()}unbindEvents(){It(this._listeners,(t,n)=>{this.platform.removeEventListener(this,n,t)}),this._listeners={},It(this._responsiveListeners,(t,n)=>{this.platform.removeEventListener(this,n,t)}),this._responsiveListeners=void 0}updateHoverStyle(t,n,r){const s=r?"set":"remove";let i,o,a,l;for(n==="dataset"&&(i=this.getDatasetMeta(t[0].datasetIndex),i.controller["_"+s+"DatasetHoverStyle"]()),a=0,l=t.length;a<l;++a){o=t[a];const u=o&&this.getDatasetMeta(o.datasetIndex).controller;u&&u[s+"HoverStyle"](o.element,o.datasetIndex,o.index)}}getActiveElements(){return this._active||[]}setActiveElements(t){const n=this._active||[],r=t.map(({datasetIndex:i,index:o})=>{const a=this.getDatasetMeta(i);if(!a)throw new Error("No dataset found at index "+i);return{datasetIndex:i,element:a.data[o],index:o}});!cp(r,n)&&(this._active=r,this._lastEvent=null,this._updateHoverStyles(r,n))}notifyPlugins(t,n,r){return this._plugins.notify(this,t,n,r)}isPluginEnabled(t){return this._plugins._cache.filter(n=>n.plugin.id===t).length===1}_updateHoverStyles(t,n,r){const s=this.options.hover,i=(l,u)=>l.filter(d=>!u.some(c=>d.datasetIndex===c.datasetIndex&&d.index===c.index)),o=i(n,t),a=r?t:i(t,n);o.length&&this.updateHoverStyle(o,s.mode,!1),a.length&&s.mode&&this.updateHoverStyle(a,s.mode,!0)}_eventHandler(t,n){const r={event:t,replay:n,cancelable:!0,inChartArea:this.isPointInArea(t)},s=o=>(o.options.events||this.options.events).includes(t.native.type);if(this.notifyPlugins("beforeEvent",r,s)===!1)return;const i=this._handleEvent(t,n,r.inChartArea);return r.cancelable=!1,this.notifyPlugins("afterEvent",r,s),(i||r.changed)&&this.render(),this}_handleEvent(t,n,r){const{_active:s=[],options:i}=this,o=n,a=this._getActiveElements(t,s,r,o),l=EJ(t),u=Jee(t,this._lastEvent,r,l);r&&(this._lastEvent=null,jt(i.onHover,[t,a,this],this),l&&jt(i.onClick,[t,a,this],this));const d=!cp(a,s);return(d||n)&&(this._active=a,this._updateHoverStyles(a,s,n)),this._lastEvent=u,d}_getActiveElements(t,n,r,s){if(t.type==="mouseout")return[];if(!r)return n;const i=this.options.hover;return this.getElementsAtEventForMode(t,i.mode,i,s)}},he(eo,"defaults",fn),he(eo,"instances",vh),he(eo,"overrides",Xa),he(eo,"registry",Ys),he(eo,"version",Kee),he(eo,"getChart",Lx),eo);function $x(){return It(Tm.instances,e=>e._plugins.invalidate())}function QM(e,t){const{x:n,y:r,base:s,width:i,height:o}=e.getProps(["x","y","base","width","height"],t);let a,l,u,d,c;return e.horizontal?(c=o/2,a=Math.min(n,s),l=Math.max(n,s),u=r-c,d=r+c):(c=i/2,a=n-c,l=n+c,u=Math.min(r,s),d=Math.max(r,s)),{left:a,top:u,right:l,bottom:d}}function Po(e,t,n,r){return e?0:Ps(t,n,r)}function ete(e,t,n){const r=e.options.borderWidth,s=e.borderSkipped,i=OM(r);return{t:Po(s.top,i.top,0,n),r:Po(s.right,i.right,0,t),b:Po(s.bottom,i.bottom,0,n),l:Po(s.left,i.left,0,t)}}function tte(e,t,n){const{enableBorderRadius:r}=e.getProps(["enableBorderRadius"]),s=e.options.borderRadius,i=$a(s),o=Math.min(t,n),a=e.borderSkipped,l=r||_t(s);return{topLeft:Po(!l||a.top||a.left,i.topLeft,0,o),topRight:Po(!l||a.top||a.right,i.topRight,0,o),bottomLeft:Po(!l||a.bottom||a.left,i.bottomLeft,0,o),bottomRight:Po(!l||a.bottom||a.right,i.bottomRight,0,o)}}function nte(e){const t=QM(e),n=t.right-t.left,r=t.bottom-t.top,s=ete(e,n/2,r/2),i=tte(e,n/2,r/2);return{outer:{x:t.left,y:t.top,w:n,h:r,radius:i},inner:{x:t.left+s.l,y:t.top+s.t,w:n-s.l-s.r,h:r-s.t-s.b,radius:{topLeft:Math.max(0,i.topLeft-Math.max(s.t,s.l)),topRight:Math.max(0,i.topRight-Math.max(s.t,s.r)),bottomLeft:Math.max(0,i.bottomLeft-Math.max(s.b,s.l)),bottomRight:Math.max(0,i.bottomRight-Math.max(s.b,s.r))}}}}function Hg(e,t,n,r){const s=t===null,i=n===null,a=e&&!(s&&i)&&QM(e,r);return a&&(s||Dl(t,a.left,a.right))&&(i||Dl(n,a.top,a.bottom))}function rte(e){return e.topLeft||e.topRight||e.bottomLeft||e.bottomRight}function ste(e,t){e.rect(t.x,t.y,t.w,t.h)}function zg(e,t,n={}){const r=e.x!==n.x?-t:0,s=e.y!==n.y?-t:0,i=(e.x+e.w!==n.x+n.w?t:0)-r,o=(e.y+e.h!==n.y+n.h?t:0)-s;return{x:e.x+r,y:e.y+s,w:e.w+i,h:e.h+o,radius:e.radius}}class yh extends ju{constructor(t){super(),this.options=void 0,this.horizontal=void 0,this.base=void 0,this.width=void 0,this.height=void 0,this.inflateAmount=void 0,t&&Object.assign(this,t)}draw(t){const{inflateAmount:n,options:{borderColor:r,backgroundColor:s}}=this,{inner:i,outer:o}=nte(this),a=rte(o.radius)?hd:ste;t.save(),(o.w!==i.w||o.h!==i.h)&&(t.beginPath(),a(t,zg(o,n,i)),t.clip(),a(t,zg(i,-n,o)),t.fillStyle=r,t.fill("evenodd")),t.beginPath(),a(t,zg(i,n)),t.fillStyle=s,t.fill(),t.restore()}inRange(t,n,r){return Hg(this,t,n,r)}inXRange(t,n){return Hg(this,t,null,n)}inYRange(t,n){return Hg(this,null,t,n)}getCenterPoint(t){const{x:n,y:r,base:s,horizontal:i}=this.getProps(["x","y","base","horizontal"],t);return{x:i?(n+s)/2:n,y:i?r:(r+s)/2}}getRange(t){return t==="x"?this.width/2:this.height/2}}he(yh,"id","bar"),he(yh,"defaults",{borderSkipped:"start",borderWidth:0,borderRadius:0,inflateAmount:"auto",pointStyle:void 0}),he(yh,"defaultRoutes",{backgroundColor:"backgroundColor",borderColor:"borderColor"});const Fx=(e,t)=>{let{boxHeight:n=t,boxWidth:r=t}=e;return e.usePointStyle&&(n=Math.min(n,t),r=e.pointStyleWidth||Math.min(r,t)),{boxWidth:r,boxHeight:n,itemHeight:Math.max(t,n)}},ite=(e,t)=>e!==null&&t!==null&&e.datasetIndex===t.datasetIndex&&e.index===t.index;class Nx extends ju{constructor(t){super(),this._added=!1,this.legendHitBoxes=[],this._hoveredItem=null,this.doughnutMode=!1,this.chart=t.chart,this.options=t.options,this.ctx=t.ctx,this.legendItems=void 0,this.columnSizes=void 0,this.lineWidths=void 0,this.maxHeight=void 0,this.maxWidth=void 0,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.height=void 0,this.width=void 0,this._margins=void 0,this.position=void 0,this.weight=void 0,this.fullSize=void 0}update(t,n,r){this.maxWidth=t,this.maxHeight=n,this._margins=r,this.setDimensions(),this.buildLabels(),this.fit()}setDimensions(){this.isHorizontal()?(this.width=this.maxWidth,this.left=this._margins.left,this.right=this.width):(this.height=this.maxHeight,this.top=this._margins.top,this.bottom=this.height)}buildLabels(){const t=this.options.labels||{};let n=jt(t.generateLabels,[this.chart],this)||[];t.filter&&(n=n.filter(r=>t.filter(r,this.chart.data))),t.sort&&(n=n.sort((r,s)=>t.sort(r,s,this.chart.data))),this.options.reverse&&n.reverse(),this.legendItems=n}fit(){const{options:t,ctx:n}=this;if(!t.display){this.width=this.height=0;return}const r=t.labels,s=Cn(r.font),i=s.size,o=this._computeTitleHeight(),{boxWidth:a,itemHeight:l}=Fx(r,i);let u,d;n.font=s.string,this.isHorizontal()?(u=this.maxWidth,d=this._fitRows(o,i,a,l)+10):(d=this.maxHeight,u=this._fitCols(o,s,a,l)+10),this.width=Math.min(u,t.maxWidth||this.maxWidth),this.height=Math.min(d,t.maxHeight||this.maxHeight)}_fitRows(t,n,r,s){const{ctx:i,maxWidth:o,options:{labels:{padding:a}}}=this,l=this.legendHitBoxes=[],u=this.lineWidths=[0],d=s+a;let c=t;i.textAlign="left",i.textBaseline="middle";let f=-1,p=-d;return this.legendItems.forEach((g,m)=>{const y=r+n/2+i.measureText(g.text).width;(m===0||u[u.length-1]+y+2*a>o)&&(c+=d,u[u.length-(m>0?0:1)]=0,p+=d,f++),l[m]={left:0,top:p,row:f,width:y,height:s},u[u.length-1]+=y+a}),c}_fitCols(t,n,r,s){const{ctx:i,maxHeight:o,options:{labels:{padding:a}}}=this,l=this.legendHitBoxes=[],u=this.columnSizes=[],d=o-t;let c=a,f=0,p=0,g=0,m=0;return this.legendItems.forEach((y,b)=>{const{itemWidth:w,itemHeight:S}=ote(r,n,i,y,s);b>0&&p+S+2*a>d&&(c+=f+a,u.push({width:f,height:p}),g+=f+a,m++,f=p=0),l[b]={left:g,top:p,col:m,width:w,height:S},f=Math.max(f,w),p+=S+a}),c+=f,u.push({width:f,height:p}),c}adjustHitBoxes(){if(!this.options.display)return;const t=this._computeTitleHeight(),{legendHitBoxes:n,options:{align:r,labels:{padding:s},rtl:i}}=this,o=jl(i,this.left,this.width);if(this.isHorizontal()){let a=0,l=Yn(r,this.left+s,this.right-this.lineWidths[a]);for(const u of n)a!==u.row&&(a=u.row,l=Yn(r,this.left+s,this.right-this.lineWidths[a])),u.top+=this.top+t+s,u.left=o.leftForLtr(o.x(l),u.width),l+=u.width+s}else{let a=0,l=Yn(r,this.top+t+s,this.bottom-this.columnSizes[a].height);for(const u of n)u.col!==a&&(a=u.col,l=Yn(r,this.top+t+s,this.bottom-this.columnSizes[a].height)),u.top=l,u.left+=this.left+s,u.left=o.leftForLtr(o.x(u.left),u.width),l+=u.height+s}}isHorizontal(){return this.options.position==="top"||this.options.position==="bottom"}draw(){if(this.options.display){const t=this.ctx;cS(t,this),this._draw(),dS(t)}}_draw(){const{options:t,columnSizes:n,lineWidths:r,ctx:s}=this,{align:i,labels:o}=t,a=fn.color,l=jl(t.rtl,this.left,this.width),u=Cn(o.font),{padding:d}=o,c=u.size,f=c/2;let p;this.drawTitle(),s.textAlign=l.textAlign("left"),s.textBaseline="middle",s.lineWidth=.5,s.font=u.string;const{boxWidth:g,boxHeight:m,itemHeight:y}=Fx(o,c),b=function(T,C,k){if(isNaN(g)||g<=0||isNaN(m)||m<0)return;s.save();const x=Ct(k.lineWidth,1);if(s.fillStyle=Ct(k.fillStyle,a),s.lineCap=Ct(k.lineCap,"butt"),s.lineDashOffset=Ct(k.lineDashOffset,0),s.lineJoin=Ct(k.lineJoin,"miter"),s.lineWidth=x,s.strokeStyle=Ct(k.strokeStyle,a),s.setLineDash(Ct(k.lineDash,[])),o.usePointStyle){const I={radius:m*Math.SQRT2/2,pointStyle:k.pointStyle,rotation:k.rotation,borderWidth:x},M=l.xPlus(T,g/2),O=C+f;IM(s,I,M,O,o.pointStyleWidth&&g)}else{const I=C+Math.max((c-m)/2,0),M=l.leftForLtr(T,g),O=$a(k.borderRadius);s.beginPath(),Object.values(O).some(A=>A!==0)?hd(s,{x:M,y:I,w:g,h:m,radius:O}):s.rect(M,I,g,m),s.fill(),x!==0&&s.stroke()}s.restore()},w=function(T,C,k){Qa(s,k.text,T,C+y/2,u,{strikethrough:k.hidden,textAlign:l.textAlign(k.textAlign)})},S=this.isHorizontal(),P=this._computeTitleHeight();S?p={x:Yn(i,this.left+d,this.right-r[0]),y:this.top+d+P,line:0}:p={x:this.left+d,y:Yn(i,this.top+P+d,this.bottom-n[0].height),line:0},FM(this.ctx,t.textDirection);const E=y+d;this.legendItems.forEach((T,C)=>{s.strokeStyle=T.fontColor,s.fillStyle=T.fontColor;const k=s.measureText(T.text).width,x=l.textAlign(T.textAlign||(T.textAlign=o.textAlign)),I=g+f+k;let M=p.x,O=p.y;l.setWidth(this.width),S?C>0&&M+I+d>this.right&&(O=p.y+=E,p.line++,M=p.x=Yn(i,this.left+d,this.right-r[p.line])):C>0&&O+E>this.bottom&&(M=p.x=M+n[p.line].width+d,p.line++,O=p.y=Yn(i,this.top+P+d,this.bottom-n[p.line].height));const A=l.x(M);if(b(A,O,T),M=FJ(x,M+g+f,S?M+I:this.right,t.rtl),w(l.x(M),O,T),S)p.x+=I+d;else if(typeof T.text!="string"){const D=u.lineHeight;p.y+=JM(T,D)+d}else p.y+=E}),NM(this.ctx,t.textDirection)}drawTitle(){const t=this.options,n=t.title,r=Cn(n.font),s=ir(n.padding);if(!n.display)return;const i=jl(t.rtl,this.left,this.width),o=this.ctx,a=n.position,l=r.size/2,u=s.top+l;let d,c=this.left,f=this.width;if(this.isHorizontal())f=Math.max(...this.lineWidths),d=this.top+u,c=Yn(t.align,c,this.right-f);else{const g=this.columnSizes.reduce((m,y)=>Math.max(m,y.height),0);d=u+Yn(t.align,this.top,this.bottom-g-t.labels.padding-this._computeTitleHeight())}const p=Yn(a,c,c+f);o.textAlign=i.textAlign(lS(a)),o.textBaseline="middle",o.strokeStyle=n.color,o.fillStyle=n.color,o.font=r.string,Qa(o,n.text,p,d,r)}_computeTitleHeight(){const t=this.options.title,n=Cn(t.font),r=ir(t.padding);return t.display?n.lineHeight+r.height:0}_getLegendItemAt(t,n){let r,s,i;if(Dl(t,this.left,this.right)&&Dl(n,this.top,this.bottom)){for(i=this.legendHitBoxes,r=0;r<i.length;++r)if(s=i[r],Dl(t,s.left,s.left+s.width)&&Dl(n,s.top,s.top+s.height))return this.legendItems[r]}return null}handleEvent(t){const n=this.options;if(!ute(t.type,n))return;const r=this._getLegendItemAt(t.x,t.y);if(t.type==="mousemove"||t.type==="mouseout"){const s=this._hoveredItem,i=ite(s,r);s&&!i&&jt(n.onLeave,[t,s,this],this),this._hoveredItem=r,r&&!i&&jt(n.onHover,[t,r,this],this)}else r&&jt(n.onClick,[t,r,this],this)}}function ote(e,t,n,r,s){const i=ate(r,e,t,n),o=lte(s,r,t.lineHeight);return{itemWidth:i,itemHeight:o}}function ate(e,t,n,r){let s=e.text;return s&&typeof s!="string"&&(s=s.reduce((i,o)=>i.length>o.length?i:o)),t+n.size/2+r.measureText(s).width}function lte(e,t,n){let r=e;return typeof t.text!="string"&&(r=JM(t,n)),r}function JM(e,t){const n=e.text?e.text.length:0;return t*n}function ute(e,t){return!!((e==="mousemove"||e==="mouseout")&&(t.onHover||t.onLeave)||t.onClick&&(e==="click"||e==="mouseup"))}var cte={id:"legend",_element:Nx,start(e,t,n){const r=e.legend=new Nx({ctx:e.ctx,options:n,chart:e});cs.configure(e,r,n),cs.addBox(e,r)},stop(e){cs.removeBox(e,e.legend),delete e.legend},beforeUpdate(e,t,n){const r=e.legend;cs.configure(e,r,n),r.options=n},afterUpdate(e){const t=e.legend;t.buildLabels(),t.adjustHitBoxes()},afterEvent(e,t){t.replay||e.legend.handleEvent(t.event)},defaults:{display:!0,position:"top",align:"center",fullSize:!0,reverse:!1,weight:1e3,onClick(e,t,n){const r=t.datasetIndex,s=n.chart;s.isDatasetVisible(r)?(s.hide(r),t.hidden=!0):(s.show(r),t.hidden=!1)},onHover:null,onLeave:null,labels:{color:e=>e.chart.options.color,boxWidth:40,padding:10,generateLabels(e){const t=e.data.datasets,{labels:{usePointStyle:n,pointStyle:r,textAlign:s,color:i,useBorderRadius:o,borderRadius:a}}=e.legend.options;return e._getSortedDatasetMetas().map(l=>{const u=l.controller.getStyle(n?0:void 0),d=ir(u.borderWidth);return{text:t[l.index].label,fillStyle:u.backgroundColor,fontColor:i,hidden:!l.visible,lineCap:u.borderCapStyle,lineDash:u.borderDash,lineDashOffset:u.borderDashOffset,lineJoin:u.borderJoinStyle,lineWidth:(d.width+d.height)/4,strokeStyle:u.borderColor,pointStyle:r||u.pointStyle,rotation:u.rotation,textAlign:s||u.textAlign,borderRadius:o&&(a||u.borderRadius),datasetIndex:l.index}},this)}},title:{color:e=>e.chart.options.color,display:!1,position:"center",text:""}},descriptors:{_scriptable:e=>!e.startsWith("on"),labels:{_scriptable:e=>!["generateLabels","filter","sort"].includes(e)}}};class ZM extends ju{constructor(t){super(),this.chart=t.chart,this.options=t.options,this.ctx=t.ctx,this._padding=void 0,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.width=void 0,this.height=void 0,this.position=void 0,this.weight=void 0,this.fullSize=void 0}update(t,n){const r=this.options;if(this.left=0,this.top=0,!r.display){this.width=this.height=this.right=this.bottom=0;return}this.width=this.right=t,this.height=this.bottom=n;const s=on(r.text)?r.text.length:1;this._padding=ir(r.padding);const i=s*Cn(r.font).lineHeight+this._padding.height;this.isHorizontal()?this.height=i:this.width=i}isHorizontal(){const t=this.options.position;return t==="top"||t==="bottom"}_drawArgs(t){const{top:n,left:r,bottom:s,right:i,options:o}=this,a=o.align;let l=0,u,d,c;return this.isHorizontal()?(d=Yn(a,r,i),c=n+t,u=i-r):(o.position==="left"?(d=r+t,c=Yn(a,s,n),l=$n*-.5):(d=i-t,c=Yn(a,n,s),l=$n*.5),u=s-n),{titleX:d,titleY:c,maxWidth:u,rotation:l}}draw(){const t=this.ctx,n=this.options;if(!n.display)return;const r=Cn(n.font),i=r.lineHeight/2+this._padding.top,{titleX:o,titleY:a,maxWidth:l,rotation:u}=this._drawArgs(i);Qa(t,n.text,0,0,r,{color:n.color,maxWidth:l,rotation:u,textAlign:lS(n.align),textBaseline:"middle",translation:[o,a]})}}function dte(e,t){const n=new ZM({ctx:e.ctx,options:t,chart:e});cs.configure(e,n,t),cs.addBox(e,n),e.titleBlock=n}var fte={id:"title",_element:ZM,start(e,t,n){dte(e,n)},stop(e){const t=e.titleBlock;cs.removeBox(e,t),delete e.titleBlock},beforeUpdate(e,t,n){const r=e.titleBlock;cs.configure(e,r,n),r.options=n},defaults:{align:"center",display:!1,font:{weight:"bold"},fullSize:!0,padding:10,position:"top",text:"",weight:2e3},defaultRoutes:{color:"color"},descriptors:{_scriptable:!0,_indexable:!1}};const mc={average(e){if(!e.length)return!1;let t,n,r=new Set,s=0,i=0;for(t=0,n=e.length;t<n;++t){const a=e[t].element;if(a&&a.hasValue()){const l=a.tooltipPosition();r.add(l.x),s+=l.y,++i}}return i===0||r.size===0?!1:{x:[...r].reduce((a,l)=>a+l)/r.size,y:s/i}},nearest(e,t){if(!e.length)return!1;let n=t.x,r=t.y,s=Number.POSITIVE_INFINITY,i,o,a;for(i=0,o=e.length;i<o;++i){const l=e[i].element;if(l&&l.hasValue()){const u=l.getCenterPoint(),d=IJ(t,u);d<s&&(s=d,a=l)}}if(a){const l=a.tooltipPosition();n=l.x,r=l.y}return{x:n,y:r}}};function Ws(e,t){return t&&(on(t)?Array.prototype.push.apply(e,t):e.push(t)),e}function Ei(e){return(typeof e=="string"||e instanceof String)&&e.indexOf(`
83
+ `)>-1?e.split(`
84
+ `):e}function hte(e,t){const{element:n,datasetIndex:r,index:s}=t,i=e.getDatasetMeta(r).controller,{label:o,value:a}=i.getLabelAndValue(s);return{chart:e,label:o,parsed:i.getParsed(s),raw:e.data.datasets[r].data[s],formattedValue:a,dataset:i.getDataset(),dataIndex:s,datasetIndex:r,element:n}}function Bx(e,t){const n=e.chart.ctx,{body:r,footer:s,title:i}=e,{boxWidth:o,boxHeight:a}=t,l=Cn(t.bodyFont),u=Cn(t.titleFont),d=Cn(t.footerFont),c=i.length,f=s.length,p=r.length,g=ir(t.padding);let m=g.height,y=0,b=r.reduce((P,E)=>P+E.before.length+E.lines.length+E.after.length,0);if(b+=e.beforeBody.length+e.afterBody.length,c&&(m+=c*u.lineHeight+(c-1)*t.titleSpacing+t.titleMarginBottom),b){const P=t.displayColors?Math.max(a,l.lineHeight):l.lineHeight;m+=p*P+(b-p)*l.lineHeight+(b-1)*t.bodySpacing}f&&(m+=t.footerMarginTop+f*d.lineHeight+(f-1)*t.footerSpacing);let w=0;const S=function(P){y=Math.max(y,n.measureText(P).width+w)};return n.save(),n.font=u.string,It(e.title,S),n.font=l.string,It(e.beforeBody.concat(e.afterBody),S),w=t.displayColors?o+2+t.boxPadding:0,It(r,P=>{It(P.before,S),It(P.lines,S),It(P.after,S)}),w=0,n.font=d.string,It(e.footer,S),n.restore(),y+=g.width,{width:y,height:m}}function pte(e,t){const{y:n,height:r}=t;return n<r/2?"top":n>e.height-r/2?"bottom":"center"}function mte(e,t,n,r){const{x:s,width:i}=r,o=n.caretSize+n.caretPadding;if(e==="left"&&s+i+o>t.width||e==="right"&&s-i-o<0)return!0}function gte(e,t,n,r){const{x:s,width:i}=n,{width:o,chartArea:{left:a,right:l}}=e;let u="center";return r==="center"?u=s<=(a+l)/2?"left":"right":s<=i/2?u="left":s>=o-i/2&&(u="right"),mte(u,e,t,n)&&(u="center"),u}function Vx(e,t,n){const r=n.yAlign||t.yAlign||pte(e,n);return{xAlign:n.xAlign||t.xAlign||gte(e,t,n,r),yAlign:r}}function vte(e,t){let{x:n,width:r}=e;return t==="right"?n-=r:t==="center"&&(n-=r/2),n}function yte(e,t,n){let{y:r,height:s}=e;return t==="top"?r+=n:t==="bottom"?r-=s+n:r-=s/2,r}function Ux(e,t,n,r){const{caretSize:s,caretPadding:i,cornerRadius:o}=e,{xAlign:a,yAlign:l}=n,u=s+i,{topLeft:d,topRight:c,bottomLeft:f,bottomRight:p}=$a(o);let g=vte(t,a);const m=yte(t,l,u);return l==="center"?a==="left"?g+=u:a==="right"&&(g-=u):a==="left"?g-=Math.max(d,f)+s:a==="right"&&(g+=Math.max(c,p)+s),{x:Ps(g,0,r.width-t.width),y:Ps(m,0,r.height-t.height)}}function Ff(e,t,n){const r=ir(n.padding);return t==="center"?e.x+e.width/2:t==="right"?e.x+e.width-r.right:e.x+r.left}function Hx(e){return Ws([],Ei(e))}function bte(e,t,n){return al(e,{tooltip:t,tooltipItems:n,type:"tooltip"})}function zx(e,t){const n=t&&t.dataset&&t.dataset.tooltip&&t.dataset.tooltip.callbacks;return n?e.override(n):e}const eD={beforeTitle:Si,title(e){if(e.length>0){const t=e[0],n=t.chart.data.labels,r=n?n.length:0;if(this&&this.options&&this.options.mode==="dataset")return t.dataset.label||"";if(t.label)return t.label;if(r>0&&t.dataIndex<r)return n[t.dataIndex]}return""},afterTitle:Si,beforeBody:Si,beforeLabel:Si,label(e){if(this&&this.options&&this.options.mode==="dataset")return e.label+": "+e.formattedValue||e.formattedValue;let t=e.dataset.label||"";t&&(t+=": ");const n=e.formattedValue;return Lt(n)||(t+=n),t},labelColor(e){const n=e.chart.getDatasetMeta(e.datasetIndex).controller.getStyle(e.dataIndex);return{borderColor:n.borderColor,backgroundColor:n.backgroundColor,borderWidth:n.borderWidth,borderDash:n.borderDash,borderDashOffset:n.borderDashOffset,borderRadius:0}},labelTextColor(){return this.options.bodyColor},labelPointStyle(e){const n=e.chart.getDatasetMeta(e.datasetIndex).controller.getStyle(e.dataIndex);return{pointStyle:n.pointStyle,rotation:n.rotation}},afterLabel:Si,afterBody:Si,beforeFooter:Si,footer:Si,afterFooter:Si};function wr(e,t,n,r){const s=e[t].call(n,r);return typeof s>"u"?eD[t].call(n,r):s}class Zy extends ju{constructor(t){super(),this.opacity=0,this._active=[],this._eventPosition=void 0,this._size=void 0,this._cachedAnimations=void 0,this._tooltipItems=[],this.$animations=void 0,this.$context=void 0,this.chart=t.chart,this.options=t.options,this.dataPoints=void 0,this.title=void 0,this.beforeBody=void 0,this.body=void 0,this.afterBody=void 0,this.footer=void 0,this.xAlign=void 0,this.yAlign=void 0,this.x=void 0,this.y=void 0,this.height=void 0,this.width=void 0,this.caretX=void 0,this.caretY=void 0,this.labelColors=void 0,this.labelPointStyles=void 0,this.labelTextColors=void 0}initialize(t){this.options=t,this._cachedAnimations=void 0,this.$context=void 0}_resolveAnimations(){const t=this._cachedAnimations;if(t)return t;const n=this.chart,r=this.options.setContext(this.getContext()),s=r.enabled&&n.options.animation&&r.animations,i=new BM(this.chart,s);return s._cacheable&&(this._cachedAnimations=Object.freeze(i)),i}getContext(){return this.$context||(this.$context=bte(this.chart.getContext(),this,this._tooltipItems))}getTitle(t,n){const{callbacks:r}=n,s=wr(r,"beforeTitle",this,t),i=wr(r,"title",this,t),o=wr(r,"afterTitle",this,t);let a=[];return a=Ws(a,Ei(s)),a=Ws(a,Ei(i)),a=Ws(a,Ei(o)),a}getBeforeBody(t,n){return Hx(wr(n.callbacks,"beforeBody",this,t))}getBody(t,n){const{callbacks:r}=n,s=[];return It(t,i=>{const o={before:[],lines:[],after:[]},a=zx(r,i);Ws(o.before,Ei(wr(a,"beforeLabel",this,i))),Ws(o.lines,wr(a,"label",this,i)),Ws(o.after,Ei(wr(a,"afterLabel",this,i))),s.push(o)}),s}getAfterBody(t,n){return Hx(wr(n.callbacks,"afterBody",this,t))}getFooter(t,n){const{callbacks:r}=n,s=wr(r,"beforeFooter",this,t),i=wr(r,"footer",this,t),o=wr(r,"afterFooter",this,t);let a=[];return a=Ws(a,Ei(s)),a=Ws(a,Ei(i)),a=Ws(a,Ei(o)),a}_createItems(t){const n=this._active,r=this.chart.data,s=[],i=[],o=[];let a=[],l,u;for(l=0,u=n.length;l<u;++l)a.push(hte(this.chart,n[l]));return t.filter&&(a=a.filter((d,c,f)=>t.filter(d,c,f,r))),t.itemSort&&(a=a.sort((d,c)=>t.itemSort(d,c,r))),It(a,d=>{const c=zx(t.callbacks,d);s.push(wr(c,"labelColor",this,d)),i.push(wr(c,"labelPointStyle",this,d)),o.push(wr(c,"labelTextColor",this,d))}),this.labelColors=s,this.labelPointStyles=i,this.labelTextColors=o,this.dataPoints=a,a}update(t,n){const r=this.options.setContext(this.getContext()),s=this._active;let i,o=[];if(!s.length)this.opacity!==0&&(i={opacity:0});else{const a=mc[r.position].call(this,s,this._eventPosition);o=this._createItems(r),this.title=this.getTitle(o,r),this.beforeBody=this.getBeforeBody(o,r),this.body=this.getBody(o,r),this.afterBody=this.getAfterBody(o,r),this.footer=this.getFooter(o,r);const l=this._size=Bx(this,r),u=Object.assign({},a,l),d=Vx(this.chart,r,u),c=Ux(r,u,d,this.chart);this.xAlign=d.xAlign,this.yAlign=d.yAlign,i={opacity:1,x:c.x,y:c.y,width:l.width,height:l.height,caretX:a.x,caretY:a.y}}this._tooltipItems=o,this.$context=void 0,i&&this._resolveAnimations().update(this,i),t&&r.external&&r.external.call(this,{chart:this.chart,tooltip:this,replay:n})}drawCaret(t,n,r,s){const i=this.getCaretPosition(t,r,s);n.lineTo(i.x1,i.y1),n.lineTo(i.x2,i.y2),n.lineTo(i.x3,i.y3)}getCaretPosition(t,n,r){const{xAlign:s,yAlign:i}=this,{caretSize:o,cornerRadius:a}=r,{topLeft:l,topRight:u,bottomLeft:d,bottomRight:c}=$a(a),{x:f,y:p}=t,{width:g,height:m}=n;let y,b,w,S,P,E;return i==="center"?(P=p+m/2,s==="left"?(y=f,b=y-o,S=P+o,E=P-o):(y=f+g,b=y+o,S=P-o,E=P+o),w=y):(s==="left"?b=f+Math.max(l,d)+o:s==="right"?b=f+g-Math.max(u,c)-o:b=this.caretX,i==="top"?(S=p,P=S-o,y=b-o,w=b+o):(S=p+m,P=S+o,y=b+o,w=b-o),E=S),{x1:y,x2:b,x3:w,y1:S,y2:P,y3:E}}drawTitle(t,n,r){const s=this.title,i=s.length;let o,a,l;if(i){const u=jl(r.rtl,this.x,this.width);for(t.x=Ff(this,r.titleAlign,r),n.textAlign=u.textAlign(r.titleAlign),n.textBaseline="middle",o=Cn(r.titleFont),a=r.titleSpacing,n.fillStyle=r.titleColor,n.font=o.string,l=0;l<i;++l)n.fillText(s[l],u.x(t.x),t.y+o.lineHeight/2),t.y+=o.lineHeight+a,l+1===i&&(t.y+=r.titleMarginBottom-a)}}_drawColorBox(t,n,r,s,i){const o=this.labelColors[r],a=this.labelPointStyles[r],{boxHeight:l,boxWidth:u}=i,d=Cn(i.bodyFont),c=Ff(this,"left",i),f=s.x(c),p=l<d.lineHeight?(d.lineHeight-l)/2:0,g=n.y+p;if(i.usePointStyle){const m={radius:Math.min(u,l)/2,pointStyle:a.pointStyle,rotation:a.rotation,borderWidth:1},y=s.leftForLtr(f,u)+u/2,b=g+l/2;t.strokeStyle=i.multiKeyBackground,t.fillStyle=i.multiKeyBackground,sx(t,m,y,b),t.strokeStyle=o.borderColor,t.fillStyle=o.backgroundColor,sx(t,m,y,b)}else{t.lineWidth=_t(o.borderWidth)?Math.max(...Object.values(o.borderWidth)):o.borderWidth||1,t.strokeStyle=o.borderColor,t.setLineDash(o.borderDash||[]),t.lineDashOffset=o.borderDashOffset||0;const m=s.leftForLtr(f,u),y=s.leftForLtr(s.xPlus(f,1),u-2),b=$a(o.borderRadius);Object.values(b).some(w=>w!==0)?(t.beginPath(),t.fillStyle=i.multiKeyBackground,hd(t,{x:m,y:g,w:u,h:l,radius:b}),t.fill(),t.stroke(),t.fillStyle=o.backgroundColor,t.beginPath(),hd(t,{x:y,y:g+1,w:u-2,h:l-2,radius:b}),t.fill()):(t.fillStyle=i.multiKeyBackground,t.fillRect(m,g,u,l),t.strokeRect(m,g,u,l),t.fillStyle=o.backgroundColor,t.fillRect(y,g+1,u-2,l-2))}t.fillStyle=this.labelTextColors[r]}drawBody(t,n,r){const{body:s}=this,{bodySpacing:i,bodyAlign:o,displayColors:a,boxHeight:l,boxWidth:u,boxPadding:d}=r,c=Cn(r.bodyFont);let f=c.lineHeight,p=0;const g=jl(r.rtl,this.x,this.width),m=function(k){n.fillText(k,g.x(t.x+p),t.y+f/2),t.y+=f+i},y=g.textAlign(o);let b,w,S,P,E,T,C;for(n.textAlign=o,n.textBaseline="middle",n.font=c.string,t.x=Ff(this,y,r),n.fillStyle=r.bodyColor,It(this.beforeBody,m),p=a&&y!=="right"?o==="center"?u/2+d:u+2+d:0,P=0,T=s.length;P<T;++P){for(b=s[P],w=this.labelTextColors[P],n.fillStyle=w,It(b.before,m),S=b.lines,a&&S.length&&(this._drawColorBox(n,t,P,g,r),f=Math.max(c.lineHeight,l)),E=0,C=S.length;E<C;++E)m(S[E]),f=c.lineHeight;It(b.after,m)}p=0,f=c.lineHeight,It(this.afterBody,m),t.y-=i}drawFooter(t,n,r){const s=this.footer,i=s.length;let o,a;if(i){const l=jl(r.rtl,this.x,this.width);for(t.x=Ff(this,r.footerAlign,r),t.y+=r.footerMarginTop,n.textAlign=l.textAlign(r.footerAlign),n.textBaseline="middle",o=Cn(r.footerFont),n.fillStyle=r.footerColor,n.font=o.string,a=0;a<i;++a)n.fillText(s[a],l.x(t.x),t.y+o.lineHeight/2),t.y+=o.lineHeight+r.footerSpacing}}drawBackground(t,n,r,s){const{xAlign:i,yAlign:o}=this,{x:a,y:l}=t,{width:u,height:d}=r,{topLeft:c,topRight:f,bottomLeft:p,bottomRight:g}=$a(s.cornerRadius);n.fillStyle=s.backgroundColor,n.strokeStyle=s.borderColor,n.lineWidth=s.borderWidth,n.beginPath(),n.moveTo(a+c,l),o==="top"&&this.drawCaret(t,n,r,s),n.lineTo(a+u-f,l),n.quadraticCurveTo(a+u,l,a+u,l+f),o==="center"&&i==="right"&&this.drawCaret(t,n,r,s),n.lineTo(a+u,l+d-g),n.quadraticCurveTo(a+u,l+d,a+u-g,l+d),o==="bottom"&&this.drawCaret(t,n,r,s),n.lineTo(a+p,l+d),n.quadraticCurveTo(a,l+d,a,l+d-p),o==="center"&&i==="left"&&this.drawCaret(t,n,r,s),n.lineTo(a,l+c),n.quadraticCurveTo(a,l,a+c,l),n.closePath(),n.fill(),s.borderWidth>0&&n.stroke()}_updateAnimationTarget(t){const n=this.chart,r=this.$animations,s=r&&r.x,i=r&&r.y;if(s||i){const o=mc[t.position].call(this,this._active,this._eventPosition);if(!o)return;const a=this._size=Bx(this,t),l=Object.assign({},o,this._size),u=Vx(n,t,l),d=Ux(t,l,u,n);(s._to!==d.x||i._to!==d.y)&&(this.xAlign=u.xAlign,this.yAlign=u.yAlign,this.width=a.width,this.height=a.height,this.caretX=o.x,this.caretY=o.y,this._resolveAnimations().update(this,d))}}_willRender(){return!!this.opacity}draw(t){const n=this.options.setContext(this.getContext());let r=this.opacity;if(!r)return;this._updateAnimationTarget(n);const s={width:this.width,height:this.height},i={x:this.x,y:this.y};r=Math.abs(r)<.001?0:r;const o=ir(n.padding),a=this.title.length||this.beforeBody.length||this.body.length||this.afterBody.length||this.footer.length;n.enabled&&a&&(t.save(),t.globalAlpha=r,this.drawBackground(i,t,s,n),FM(t,n.textDirection),i.y+=o.top,this.drawTitle(i,t,n),this.drawBody(i,t,n),this.drawFooter(i,t,n),NM(t,n.textDirection),t.restore())}getActiveElements(){return this._active||[]}setActiveElements(t,n){const r=this._active,s=t.map(({datasetIndex:a,index:l})=>{const u=this.chart.getDatasetMeta(a);if(!u)throw new Error("Cannot find a dataset at index "+a);return{datasetIndex:a,element:u.data[l],index:l}}),i=!cp(r,s),o=this._positionChanged(s,n);(i||o)&&(this._active=s,this._eventPosition=n,this._ignoreReplayEvents=!0,this.update(!0))}handleEvent(t,n,r=!0){if(n&&this._ignoreReplayEvents)return!1;this._ignoreReplayEvents=!1;const s=this.options,i=this._active||[],o=this._getActiveElements(t,i,n,r),a=this._positionChanged(o,t),l=n||!cp(o,i)||a;return l&&(this._active=o,(s.enabled||s.external)&&(this._eventPosition={x:t.x,y:t.y},this.update(!0,n))),l}_getActiveElements(t,n,r,s){const i=this.options;if(t.type==="mouseout")return[];if(!s)return n.filter(a=>this.chart.data.datasets[a.datasetIndex]&&this.chart.getDatasetMeta(a.datasetIndex).controller.getParsed(a.index)!==void 0);const o=this.chart.getElementsAtEventForMode(t,i.mode,i,r);return i.reverse&&o.reverse(),o}_positionChanged(t,n){const{caretX:r,caretY:s,options:i}=this,o=mc[i.position].call(this,t,n);return o!==!1&&(r!==o.x||s!==o.y)}}he(Zy,"positioners",mc);var wte={id:"tooltip",_element:Zy,positioners:mc,afterInit(e,t,n){n&&(e.tooltip=new Zy({chart:e,options:n}))},beforeUpdate(e,t,n){e.tooltip&&e.tooltip.initialize(n)},reset(e,t,n){e.tooltip&&e.tooltip.initialize(n)},afterDraw(e){const t=e.tooltip;if(t&&t._willRender()){const n={tooltip:t};if(e.notifyPlugins("beforeTooltipDraw",{...n,cancelable:!0})===!1)return;t.draw(e.ctx),e.notifyPlugins("afterTooltipDraw",n)}},afterEvent(e,t){if(e.tooltip){const n=t.replay;e.tooltip.handleEvent(t.event,n,t.inChartArea)&&(t.changed=!0)}},defaults:{enabled:!0,external:null,position:"average",backgroundColor:"rgba(0,0,0,0.8)",titleColor:"#fff",titleFont:{weight:"bold"},titleSpacing:2,titleMarginBottom:6,titleAlign:"left",bodyColor:"#fff",bodySpacing:2,bodyFont:{},bodyAlign:"left",footerColor:"#fff",footerSpacing:2,footerMarginTop:6,footerFont:{weight:"bold"},footerAlign:"left",padding:6,caretPadding:2,caretSize:5,cornerRadius:6,boxHeight:(e,t)=>t.bodyFont.size,boxWidth:(e,t)=>t.bodyFont.size,multiKeyBackground:"#fff",displayColors:!0,boxPadding:0,borderColor:"rgba(0,0,0,0)",borderWidth:0,animation:{duration:400,easing:"easeOutQuart"},animations:{numbers:{type:"number",properties:["x","y","width","height","caretX","caretY"]},opacity:{easing:"linear",duration:200}},callbacks:eD},defaultRoutes:{bodyFont:"font",footerFont:"font",titleFont:"font"},descriptors:{_scriptable:e=>e!=="filter"&&e!=="itemSort"&&e!=="external",_indexable:!1,callbacks:{_scriptable:!1,_indexable:!1},animation:{_fallback:!1},animations:{_fallback:"animation"}},additionalOptionScopes:["interaction"]};const Ste=(e,t,n,r)=>(typeof t=="string"?(n=e.push(t)-1,r.unshift({index:n,label:t})):isNaN(t)&&(n=null),n);function _te(e,t,n,r){const s=e.indexOf(t);if(s===-1)return Ste(e,t,n,r);const i=e.lastIndexOf(t);return s!==i?n:s}const kte=(e,t)=>e===null?null:Ps(Math.round(e),0,t);function jx(e){const t=this.getLabels();return e>=0&&e<t.length?t[e]:e}class eb extends ll{constructor(t){super(t),this._startValue=void 0,this._valueRange=0,this._addedLabels=[]}init(t){const n=this._addedLabels;if(n.length){const r=this.getLabels();for(const{index:s,label:i}of n)r[s]===i&&r.splice(s,1);this._addedLabels=[]}super.init(t)}parse(t,n){if(Lt(t))return null;const r=this.getLabels();return n=isFinite(n)&&r[n]===t?n:_te(r,t,Ct(n,t),this._addedLabels),kte(n,r.length-1)}determineDataLimits(){const{minDefined:t,maxDefined:n}=this.getUserBounds();let{min:r,max:s}=this.getMinMax(!0);this.options.bounds==="ticks"&&(t||(r=0),n||(s=this.getLabels().length-1)),this.min=r,this.max=s}buildTicks(){const t=this.min,n=this.max,r=this.options.offset,s=[];let i=this.getLabels();i=t===0&&n===i.length-1?i:i.slice(t,n+1),this._valueRange=Math.max(i.length-(r?0:1),1),this._startValue=this.min-(r?.5:0);for(let o=t;o<=n;o++)s.push({value:o});return s}getLabelForValue(t){return jx.call(this,t)}configure(){super.configure(),this.isHorizontal()||(this._reversePixels=!this._reversePixels)}getPixelForValue(t){return typeof t!="number"&&(t=this.parse(t)),t===null?NaN:this.getPixelForDecimal((t-this._startValue)/this._valueRange)}getPixelForTick(t){const n=this.ticks;return t<0||t>n.length-1?null:this.getPixelForValue(n[t].value)}getValueForPixel(t){return Math.round(this._startValue+this.getDecimalForPixel(t)*this._valueRange)}getBasePixel(){return this.bottom}}he(eb,"id","category"),he(eb,"defaults",{ticks:{callback:jx}});function xte(e,t){const n=[],{bounds:s,step:i,min:o,max:a,precision:l,count:u,maxTicks:d,maxDigits:c,includeBounds:f}=e,p=i||1,g=d-1,{min:m,max:y}=t,b=!Lt(o),w=!Lt(a),S=!Lt(u),P=(y-m)/(c+1);let E=Xk((y-m)/g/p)*p,T,C,k,x;if(E<1e-14&&!b&&!w)return[{value:m},{value:y}];x=Math.ceil(y/E)-Math.floor(m/E),x>g&&(E=Xk(x*E/g/p)*p),Lt(l)||(T=Math.pow(10,l),E=Math.ceil(E*T)/T),s==="ticks"?(C=Math.floor(m/E)*E,k=Math.ceil(y/E)*E):(C=m,k=y),b&&w&&i&&TJ((a-o)/i,E/1e3)?(x=Math.round(Math.min((a-o)/E,d)),E=(a-o)/x,C=o,k=a):S?(C=b?o:C,k=w?a:k,x=u-1,E=(k-C)/x):(x=(k-C)/E,ph(x,Math.round(x),E/1e3)?x=Math.round(x):x=Math.ceil(x));const I=Math.max(Qk(E),Qk(C));T=Math.pow(10,Lt(l)?I:l),C=Math.round(C*T)/T,k=Math.round(k*T)/T;let M=0;for(b&&(f&&C!==o?(n.push({value:o}),C<o&&M++,ph(Math.round((C+M*E)*T)/T,o,qx(o,P,e))&&M++):C<o&&M++);M<x;++M){const O=Math.round((C+M*E)*T)/T;if(w&&O>a)break;n.push({value:O})}return w&&f&&k!==a?n.length&&ph(n[n.length-1].value,a,qx(a,P,e))?n[n.length-1].value=a:n.push({value:a}):(!w||k===a)&&n.push({value:k}),n}function qx(e,t,{horizontal:n,minRotation:r}){const s=Co(r),i=(n?Math.sin(s):Math.cos(s))||.001,o=.75*t*(""+e).length;return Math.min(t/i,o)}class vp extends ll{constructor(t){super(t),this.start=void 0,this.end=void 0,this._startValue=void 0,this._endValue=void 0,this._valueRange=0}parse(t,n){return Lt(t)||(typeof t=="number"||t instanceof Number)&&!isFinite(+t)?null:+t}handleTickRangeOptions(){const{beginAtZero:t}=this.options,{minDefined:n,maxDefined:r}=this.getUserBounds();let{min:s,max:i}=this;const o=l=>s=n?s:l,a=l=>i=r?i:l;if(t){const l=Lo(s),u=Lo(i);l<0&&u<0?a(0):l>0&&u>0&&o(0)}if(s===i){let l=i===0?1:Math.abs(i*.05);a(i+l),t||o(s-l)}this.min=s,this.max=i}getTickLimit(){const t=this.options.ticks;let{maxTicksLimit:n,stepSize:r}=t,s;return r?(s=Math.ceil(this.max/r)-Math.floor(this.min/r)+1,s>1e3&&(console.warn(`scales.${this.id}.ticks.stepSize: ${r} would result generating up to ${s} ticks. Limiting to 1000.`),s=1e3)):(s=this.computeTickLimit(),n=n||11),n&&(s=Math.min(n,s)),s}computeTickLimit(){return Number.POSITIVE_INFINITY}buildTicks(){const t=this.options,n=t.ticks;let r=this.getTickLimit();r=Math.max(2,r);const s={maxTicks:r,bounds:t.bounds,min:t.min,max:t.max,precision:n.precision,step:n.stepSize,count:n.count,maxDigits:this._maxDigits(),horizontal:this.isHorizontal(),minRotation:n.minRotation||0,includeBounds:n.includeBounds!==!1},i=this._range||this,o=xte(s,i);return t.bounds==="ticks"&&kM(o,this,"value"),t.reverse?(o.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),o}configure(){const t=this.ticks;let n=this.min,r=this.max;if(super.configure(),this.options.offset&&t.length){const s=(r-n)/Math.max(t.length-1,1)/2;n-=s,r+=s}this._startValue=n,this._endValue=r,this._valueRange=r-n}getLabelForValue(t){return uS(t,this.chart.options.locale,this.options.ticks.format)}}class tb extends vp{determineDataLimits(){const{min:t,max:n}=this.getMinMax(!0);this.min=Mn(t)?t:0,this.max=Mn(n)?n:1,this.handleTickRangeOptions()}computeTickLimit(){const t=this.isHorizontal(),n=t?this.width:this.height,r=Co(this.options.ticks.minRotation),s=(t?Math.sin(r):Math.cos(r))||.001,i=this._resolveTickFontOptions(0);return Math.ceil(n/Math.min(40,i.lineHeight/s))}getPixelForValue(t){return t===null?NaN:this.getPixelForDecimal((t-this._startValue)/this._valueRange)}getValueForPixel(t){return this._startValue+this.getDecimalForPixel(t)*this._valueRange}}he(tb,"id","linear"),he(tb,"defaults",{ticks:{callback:Cm.formatters.numeric}});const md=e=>Math.floor(Eo(e)),ca=(e,t)=>Math.pow(10,md(e)+t);function Wx(e){return e/Math.pow(10,md(e))===1}function Gx(e,t,n){const r=Math.pow(10,n),s=Math.floor(e/r);return Math.ceil(t/r)-s}function Ete(e,t){const n=t-e;let r=md(n);for(;Gx(e,t,r)>10;)r++;for(;Gx(e,t,r)<10;)r--;return Math.min(r,md(e))}function Cte(e,{min:t,max:n}){t=Hr(e.min,t);const r=[],s=md(t);let i=Ete(t,n),o=i<0?Math.pow(10,Math.abs(i)):1;const a=Math.pow(10,i),l=s>i?Math.pow(10,s):0,u=Math.round((t-l)*o)/o,d=Math.floor((t-l)/a/10)*a*10;let c=Math.floor((u-d)/Math.pow(10,i)),f=Hr(e.min,Math.round((l+d+c*Math.pow(10,i))*o)/o);for(;f<n;)r.push({value:f,major:Wx(f),significand:c}),c>=10?c=c<15?15:20:c++,c>=20&&(i++,c=2,o=i>=0?1:o),f=Math.round((l+d+c*Math.pow(10,i))*o)/o;const p=Hr(e.max,f);return r.push({value:p,major:Wx(p),significand:c}),r}class Kx extends ll{constructor(t){super(t),this.start=void 0,this.end=void 0,this._startValue=void 0,this._valueRange=0}parse(t,n){const r=vp.prototype.parse.apply(this,[t,n]);if(r===0){this._zero=!0;return}return Mn(r)&&r>0?r:null}determineDataLimits(){const{min:t,max:n}=this.getMinMax(!0);this.min=Mn(t)?Math.max(0,t):null,this.max=Mn(n)?Math.max(0,n):null,this.options.beginAtZero&&(this._zero=!0),this._zero&&this.min!==this._suggestedMin&&!Mn(this._userMin)&&(this.min=t===ca(this.min,0)?ca(this.min,-1):ca(this.min,0)),this.handleTickRangeOptions()}handleTickRangeOptions(){const{minDefined:t,maxDefined:n}=this.getUserBounds();let r=this.min,s=this.max;const i=a=>r=t?r:a,o=a=>s=n?s:a;r===s&&(r<=0?(i(1),o(10)):(i(ca(r,-1)),o(ca(s,1)))),r<=0&&i(ca(s,-1)),s<=0&&o(ca(r,1)),this.min=r,this.max=s}buildTicks(){const t=this.options,n={min:this._userMin,max:this._userMax},r=Cte(n,this);return t.bounds==="ticks"&&kM(r,this,"value"),t.reverse?(r.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),r}getLabelForValue(t){return t===void 0?"0":uS(t,this.chart.options.locale,this.options.ticks.format)}configure(){const t=this.min;super.configure(),this._startValue=Eo(t),this._valueRange=Eo(this.max)-Eo(t)}getPixelForValue(t){return(t===void 0||t===0)&&(t=this.min),t===null||isNaN(t)?NaN:this.getPixelForDecimal(t===this.min?0:(Eo(t)-this._startValue)/this._valueRange)}getValueForPixel(t){const n=this.getDecimalForPixel(t);return Math.pow(10,this._startValue+n*this._valueRange)}}he(Kx,"id","logarithmic"),he(Kx,"defaults",{ticks:{callback:Cm.formatters.logarithmic,major:{enabled:!0}}});function nb(e){const t=e.ticks;if(t.display&&e.display){const n=ir(t.backdropPadding);return Ct(t.font&&t.font.size,fn.font.size)+n.height}return 0}function Pte(e,t,n){return n=on(n)?n:[n],{w:GJ(e,t.string,n),h:n.length*t.lineHeight}}function Yx(e,t,n,r,s){return e===r||e===s?{start:t-n/2,end:t+n/2}:e<r||e>s?{start:t-n,end:t}:{start:t,end:t+n}}function Tte(e){const t={l:e.left+e._padding.left,r:e.right-e._padding.right,t:e.top+e._padding.top,b:e.bottom-e._padding.bottom},n=Object.assign({},t),r=[],s=[],i=e._pointLabels.length,o=e.options.pointLabels,a=o.centerPointLabels?$n/i:0;for(let l=0;l<i;l++){const u=o.setContext(e.getPointLabelContext(l));s[l]=u.padding;const d=e.getPointPosition(l,e.drawingArea+s[l],a),c=Cn(u.font),f=Pte(e.ctx,c,e._pointLabels[l]);r[l]=f;const p=Xs(e.getIndexAngle(l)+a),g=Math.round(oS(p)),m=Yx(g,d.x,f.w,0,180),y=Yx(g,d.y,f.h,90,270);Rte(n,t,p,m,y)}e.setCenterPoint(t.l-n.l,n.r-t.r,t.t-n.t,n.b-t.b),e._pointLabelItems=Ote(e,r,s)}function Rte(e,t,n,r,s){const i=Math.abs(Math.sin(n)),o=Math.abs(Math.cos(n));let a=0,l=0;r.start<t.l?(a=(t.l-r.start)/i,e.l=Math.min(e.l,t.l-a)):r.end>t.r&&(a=(r.end-t.r)/i,e.r=Math.max(e.r,t.r+a)),s.start<t.t?(l=(t.t-s.start)/o,e.t=Math.min(e.t,t.t-l)):s.end>t.b&&(l=(s.end-t.b)/o,e.b=Math.max(e.b,t.b+l))}function Ite(e,t,n){const r=e.drawingArea,{extra:s,additionalAngle:i,padding:o,size:a}=n,l=e.getPointPosition(t,r+s+o,i),u=Math.round(oS(Xs(l.angle+Xr))),d=Lte(l.y,a.h,u),c=Mte(u),f=Dte(l.x,a.w,c);return{visible:!0,x:l.x,y:d,textAlign:c,left:f,top:d,right:f+a.w,bottom:d+a.h}}function Ate(e,t){if(!t)return!0;const{left:n,top:r,right:s,bottom:i}=e;return!(Ll({x:n,y:r},t)||Ll({x:n,y:i},t)||Ll({x:s,y:r},t)||Ll({x:s,y:i},t))}function Ote(e,t,n){const r=[],s=e._pointLabels.length,i=e.options,{centerPointLabels:o,display:a}=i.pointLabels,l={extra:nb(i)/2,additionalAngle:o?$n/s:0};let u;for(let d=0;d<s;d++){l.padding=n[d],l.size=t[d];const c=Ite(e,d,l);r.push(c),a==="auto"&&(c.visible=Ate(c,u),c.visible&&(u=c))}return r}function Mte(e){return e===0||e===180?"center":e<180?"left":"right"}function Dte(e,t,n){return n==="right"?e-=t:n==="center"&&(e-=t/2),e}function Lte(e,t,n){return n===90||n===270?e-=t/2:(n>270||n<90)&&(e-=t),e}function $te(e,t,n){const{left:r,top:s,right:i,bottom:o}=n,{backdropColor:a}=t;if(!Lt(a)){const l=$a(t.borderRadius),u=ir(t.backdropPadding);e.fillStyle=a;const d=r-u.left,c=s-u.top,f=i-r+u.width,p=o-s+u.height;Object.values(l).some(g=>g!==0)?(e.beginPath(),hd(e,{x:d,y:c,w:f,h:p,radius:l}),e.fill()):e.fillRect(d,c,f,p)}}function Fte(e,t){const{ctx:n,options:{pointLabels:r}}=e;for(let s=t-1;s>=0;s--){const i=e._pointLabelItems[s];if(!i.visible)continue;const o=r.setContext(e.getPointLabelContext(s));$te(n,o,i);const a=Cn(o.font),{x:l,y:u,textAlign:d}=i;Qa(n,e._pointLabels[s],l,u+a.lineHeight/2,a,{color:o.color,textAlign:d,textBaseline:"middle"})}}function tD(e,t,n,r){const{ctx:s}=e;if(n)s.arc(e.xCenter,e.yCenter,t,0,ui);else{let i=e.getPointPosition(0,t);s.moveTo(i.x,i.y);for(let o=1;o<r;o++)i=e.getPointPosition(o,t),s.lineTo(i.x,i.y)}}function Nte(e,t,n,r,s){const i=e.ctx,o=t.circular,{color:a,lineWidth:l}=t;!o&&!r||!a||!l||n<0||(i.save(),i.strokeStyle=a,i.lineWidth=l,i.setLineDash(s.dash||[]),i.lineDashOffset=s.dashOffset,i.beginPath(),tD(e,n,o,r),i.closePath(),i.stroke(),i.restore())}function Bte(e,t,n){return al(e,{label:n,index:t,type:"pointLabel"})}class Nf extends vp{constructor(t){super(t),this.xCenter=void 0,this.yCenter=void 0,this.drawingArea=void 0,this._pointLabels=[],this._pointLabelItems=[]}setDimensions(){const t=this._padding=ir(nb(this.options)/2),n=this.width=this.maxWidth-t.width,r=this.height=this.maxHeight-t.height;this.xCenter=Math.floor(this.left+n/2+t.left),this.yCenter=Math.floor(this.top+r/2+t.top),this.drawingArea=Math.floor(Math.min(n,r)/2)}determineDataLimits(){const{min:t,max:n}=this.getMinMax(!1);this.min=Mn(t)&&!isNaN(t)?t:0,this.max=Mn(n)&&!isNaN(n)?n:0,this.handleTickRangeOptions()}computeTickLimit(){return Math.ceil(this.drawingArea/nb(this.options))}generateTickLabels(t){vp.prototype.generateTickLabels.call(this,t),this._pointLabels=this.getLabels().map((n,r)=>{const s=jt(this.options.pointLabels.callback,[n,r],this);return s||s===0?s:""}).filter((n,r)=>this.chart.getDataVisibility(r))}fit(){const t=this.options;t.display&&t.pointLabels.display?Tte(this):this.setCenterPoint(0,0,0,0)}setCenterPoint(t,n,r,s){this.xCenter+=Math.floor((t-n)/2),this.yCenter+=Math.floor((r-s)/2),this.drawingArea-=Math.min(this.drawingArea/2,Math.max(t,n,r,s))}getIndexAngle(t){const n=ui/(this._pointLabels.length||1),r=this.options.startAngle||0;return Xs(t*n+Co(r))}getDistanceFromCenterForValue(t){if(Lt(t))return NaN;const n=this.drawingArea/(this.max-this.min);return this.options.reverse?(this.max-t)*n:(t-this.min)*n}getValueForDistanceFromCenter(t){if(Lt(t))return NaN;const n=t/(this.drawingArea/(this.max-this.min));return this.options.reverse?this.max-n:this.min+n}getPointLabelContext(t){const n=this._pointLabels||[];if(t>=0&&t<n.length){const r=n[t];return Bte(this.getContext(),t,r)}}getPointPosition(t,n,r=0){const s=this.getIndexAngle(t)-Xr+r;return{x:Math.cos(s)*n+this.xCenter,y:Math.sin(s)*n+this.yCenter,angle:s}}getPointPositionForValue(t,n){return this.getPointPosition(t,this.getDistanceFromCenterForValue(n))}getBasePosition(t){return this.getPointPositionForValue(t||0,this.getBaseValue())}getPointLabelPosition(t){const{left:n,top:r,right:s,bottom:i}=this._pointLabelItems[t];return{left:n,top:r,right:s,bottom:i}}drawBackground(){const{backgroundColor:t,grid:{circular:n}}=this.options;if(t){const r=this.ctx;r.save(),r.beginPath(),tD(this,this.getDistanceFromCenterForValue(this._endValue),n,this._pointLabels.length),r.closePath(),r.fillStyle=t,r.fill(),r.restore()}}drawGrid(){const t=this.ctx,n=this.options,{angleLines:r,grid:s,border:i}=n,o=this._pointLabels.length;let a,l,u;if(n.pointLabels.display&&Fte(this,o),s.display&&this.ticks.forEach((d,c)=>{if(c!==0||c===0&&this.min<0){l=this.getDistanceFromCenterForValue(d.value);const f=this.getContext(c),p=s.setContext(f),g=i.setContext(f);Nte(this,p,l,o,g)}}),r.display){for(t.save(),a=o-1;a>=0;a--){const d=r.setContext(this.getPointLabelContext(a)),{color:c,lineWidth:f}=d;!f||!c||(t.lineWidth=f,t.strokeStyle=c,t.setLineDash(d.borderDash),t.lineDashOffset=d.borderDashOffset,l=this.getDistanceFromCenterForValue(n.reverse?this.min:this.max),u=this.getPointPosition(a,l),t.beginPath(),t.moveTo(this.xCenter,this.yCenter),t.lineTo(u.x,u.y),t.stroke())}t.restore()}}drawBorder(){}drawLabels(){const t=this.ctx,n=this.options,r=n.ticks;if(!r.display)return;const s=this.getIndexAngle(0);let i,o;t.save(),t.translate(this.xCenter,this.yCenter),t.rotate(s),t.textAlign="center",t.textBaseline="middle",this.ticks.forEach((a,l)=>{if(l===0&&this.min>=0&&!n.reverse)return;const u=r.setContext(this.getContext(l)),d=Cn(u.font);if(i=this.getDistanceFromCenterForValue(this.ticks[l].value),u.showLabelBackdrop){t.font=d.string,o=t.measureText(a.label).width,t.fillStyle=u.backdropColor;const c=ir(u.backdropPadding);t.fillRect(-o/2-c.left,-i-d.size/2-c.top,o+c.width,d.size+c.height)}Qa(t,a.label,0,-i,d,{color:u.color,strokeColor:u.textStrokeColor,strokeWidth:u.textStrokeWidth})}),t.restore()}drawTitle(){}}he(Nf,"id","radialLinear"),he(Nf,"defaults",{display:!0,animate:!0,position:"chartArea",angleLines:{display:!0,lineWidth:1,borderDash:[],borderDashOffset:0},grid:{circular:!1},startAngle:0,ticks:{showLabelBackdrop:!0,callback:Cm.formatters.numeric},pointLabels:{backdropColor:void 0,backdropPadding:2,display:!0,font:{size:10},callback(t){return t},padding:5,centerPointLabels:!1}}),he(Nf,"defaultRoutes",{"angleLines.color":"borderColor","pointLabels.color":"color","ticks.color":"color"}),he(Nf,"descriptors",{angleLines:{_fallback:"grid"}});const Rm={millisecond:{common:!0,size:1,steps:1e3},second:{common:!0,size:1e3,steps:60},minute:{common:!0,size:6e4,steps:60},hour:{common:!0,size:36e5,steps:24},day:{common:!0,size:864e5,steps:30},week:{common:!1,size:6048e5,steps:4},month:{common:!0,size:2628e6,steps:12},quarter:{common:!1,size:7884e6,steps:4},year:{common:!0,size:3154e7}},Cr=Object.keys(Rm);function Xx(e,t){return e-t}function Qx(e,t){if(Lt(t))return null;const n=e._adapter,{parser:r,round:s,isoWeekday:i}=e._parseOpts;let o=t;return typeof r=="function"&&(o=r(o)),Mn(o)||(o=typeof r=="string"?n.parse(o,r):n.parse(o)),o===null?null:(s&&(o=s==="week"&&(hp(i)||i===!0)?n.startOf(o,"isoWeek",i):n.startOf(o,s)),+o)}function Jx(e,t,n,r){const s=Cr.length;for(let i=Cr.indexOf(e);i<s-1;++i){const o=Rm[Cr[i]],a=o.steps?o.steps:Number.MAX_SAFE_INTEGER;if(o.common&&Math.ceil((n-t)/(a*o.size))<=r)return Cr[i]}return Cr[s-1]}function Vte(e,t,n,r,s){for(let i=Cr.length-1;i>=Cr.indexOf(n);i--){const o=Cr[i];if(Rm[o].common&&e._adapter.diff(s,r,o)>=t-1)return o}return Cr[n?Cr.indexOf(n):0]}function Ute(e){for(let t=Cr.indexOf(e)+1,n=Cr.length;t<n;++t)if(Rm[Cr[t]].common)return Cr[t]}function Zx(e,t,n){if(!n)e[t]=!0;else if(n.length){const{lo:r,hi:s}=aS(n,t),i=n[r]>=t?n[r]:n[s];e[i]=!0}}function Hte(e,t,n,r){const s=e._adapter,i=+s.startOf(t[0].value,r),o=t[t.length-1].value;let a,l;for(a=i;a<=o;a=+s.add(a,1,r))l=n[a],l>=0&&(t[l].major=!0);return t}function eE(e,t,n){const r=[],s={},i=t.length;let o,a;for(o=0;o<i;++o)a=t[o],s[a]=o,r.push({value:a,major:!1});return i===0||!n?r:Hte(e,r,s,n)}class yp extends ll{constructor(t){super(t),this._cache={data:[],labels:[],all:[]},this._unit="day",this._majorUnit=void 0,this._offsets={},this._normalized=!1,this._parseOpts=void 0}init(t,n={}){const r=t.time||(t.time={}),s=this._adapter=new jZ._date(t.adapters.date);s.init(n),Oc(r.displayFormats,s.formats()),this._parseOpts={parser:r.parser,round:r.round,isoWeekday:r.isoWeekday},super.init(t),this._normalized=n.normalized}parse(t,n){return t===void 0?null:Qx(this,t)}beforeLayout(){super.beforeLayout(),this._cache={data:[],labels:[],all:[]}}determineDataLimits(){const t=this.options,n=this._adapter,r=t.time.unit||"day";let{min:s,max:i,minDefined:o,maxDefined:a}=this.getUserBounds();function l(u){!o&&!isNaN(u.min)&&(s=Math.min(s,u.min)),!a&&!isNaN(u.max)&&(i=Math.max(i,u.max))}(!o||!a)&&(l(this._getLabelBounds()),(t.bounds!=="ticks"||t.ticks.source!=="labels")&&l(this.getMinMax(!1))),s=Mn(s)&&!isNaN(s)?s:+n.startOf(Date.now(),r),i=Mn(i)&&!isNaN(i)?i:+n.endOf(Date.now(),r)+1,this.min=Math.min(s,i-1),this.max=Math.max(s+1,i)}_getLabelBounds(){const t=this.getLabelTimestamps();let n=Number.POSITIVE_INFINITY,r=Number.NEGATIVE_INFINITY;return t.length&&(n=t[0],r=t[t.length-1]),{min:n,max:r}}buildTicks(){const t=this.options,n=t.time,r=t.ticks,s=r.source==="labels"?this.getLabelTimestamps():this._generate();t.bounds==="ticks"&&s.length&&(this.min=this._userMin||s[0],this.max=this._userMax||s[s.length-1]);const i=this.min,o=this.max,a=DJ(s,i,o);return this._unit=n.unit||(r.autoSkip?Jx(n.minUnit,this.min,this.max,this._getLabelCapacity(i)):Vte(this,a.length,n.minUnit,this.min,this.max)),this._majorUnit=!r.major.enabled||this._unit==="year"?void 0:Ute(this._unit),this.initOffsets(s),t.reverse&&a.reverse(),eE(this,a,this._majorUnit)}afterAutoSkip(){this.options.offsetAfterAutoskip&&this.initOffsets(this.ticks.map(t=>+t.value))}initOffsets(t=[]){let n=0,r=0,s,i;this.options.offset&&t.length&&(s=this.getDecimalForValue(t[0]),t.length===1?n=1-s:n=(this.getDecimalForValue(t[1])-s)/2,i=this.getDecimalForValue(t[t.length-1]),t.length===1?r=i:r=(i-this.getDecimalForValue(t[t.length-2]))/2);const o=t.length<3?.5:.25;n=Ps(n,0,o),r=Ps(r,0,o),this._offsets={start:n,end:r,factor:1/(n+1+r)}}_generate(){const t=this._adapter,n=this.min,r=this.max,s=this.options,i=s.time,o=i.unit||Jx(i.minUnit,n,r,this._getLabelCapacity(n)),a=Ct(s.ticks.stepSize,1),l=o==="week"?i.isoWeekday:!1,u=hp(l)||l===!0,d={};let c=n,f,p;if(u&&(c=+t.startOf(c,"isoWeek",l)),c=+t.startOf(c,u?"day":o),t.diff(r,n,o)>1e5*a)throw new Error(n+" and "+r+" are too far apart with stepSize of "+a+" "+o);const g=s.ticks.source==="data"&&this.getDataTimestamps();for(f=c,p=0;f<r;f=+t.add(f,a,o),p++)Zx(d,f,g);return(f===r||s.bounds==="ticks"||p===1)&&Zx(d,f,g),Object.keys(d).sort(Xx).map(m=>+m)}getLabelForValue(t){const n=this._adapter,r=this.options.time;return r.tooltipFormat?n.format(t,r.tooltipFormat):n.format(t,r.displayFormats.datetime)}format(t,n){const s=this.options.time.displayFormats,i=this._unit,o=n||s[i];return this._adapter.format(t,o)}_tickFormatFunction(t,n,r,s){const i=this.options,o=i.ticks.callback;if(o)return jt(o,[t,n,r],this);const a=i.time.displayFormats,l=this._unit,u=this._majorUnit,d=l&&a[l],c=u&&a[u],f=r[n],p=u&&c&&f&&f.major;return this._adapter.format(t,s||(p?c:d))}generateTickLabels(t){let n,r,s;for(n=0,r=t.length;n<r;++n)s=t[n],s.label=this._tickFormatFunction(s.value,n,t)}getDecimalForValue(t){return t===null?NaN:(t-this.min)/(this.max-this.min)}getPixelForValue(t){const n=this._offsets,r=this.getDecimalForValue(t);return this.getPixelForDecimal((n.start+r)*n.factor)}getValueForPixel(t){const n=this._offsets,r=this.getDecimalForPixel(t)/n.factor-n.end;return this.min+r*(this.max-this.min)}_getLabelSize(t){const n=this.options.ticks,r=this.ctx.measureText(t).width,s=Co(this.isHorizontal()?n.maxRotation:n.minRotation),i=Math.cos(s),o=Math.sin(s),a=this._resolveTickFontOptions(0).size;return{w:r*i+a*o,h:r*o+a*i}}_getLabelCapacity(t){const n=this.options.time,r=n.displayFormats,s=r[n.unit]||r.millisecond,i=this._tickFormatFunction(t,0,eE(this,[t],this._majorUnit),s),o=this._getLabelSize(i),a=Math.floor(this.isHorizontal()?this.width/o.w:this.height/o.h)-1;return a>0?a:1}getDataTimestamps(){let t=this._cache.data||[],n,r;if(t.length)return t;const s=this.getMatchingVisibleMetas();if(this._normalized&&s.length)return this._cache.data=s[0].controller.getAllParsedValues(this);for(n=0,r=s.length;n<r;++n)t=t.concat(s[n].controller.getAllParsedValues(this));return this._cache.data=this.normalize(t)}getLabelTimestamps(){const t=this._cache.labels||[];let n,r;if(t.length)return t;const s=this.getLabels();for(n=0,r=s.length;n<r;++n)t.push(Qx(this,s[n]));return this._cache.labels=this._normalized?t:this.normalize(t)}normalize(t){return EM(t.sort(Xx))}}he(yp,"id","time"),he(yp,"defaults",{bounds:"data",adapters:{},time:{parser:!1,unit:!1,round:!1,isoWeekday:!1,minUnit:"millisecond",displayFormats:{}},ticks:{source:"auto",callback:!1,major:{enabled:!1}}});function Bf(e,t,n){let r=0,s=e.length-1,i,o,a,l;n?(t>=e[r].pos&&t<=e[s].pos&&({lo:r,hi:s}=Yy(e,"pos",t)),{pos:i,time:a}=e[r],{pos:o,time:l}=e[s]):(t>=e[r].time&&t<=e[s].time&&({lo:r,hi:s}=Yy(e,"time",t)),{time:i,pos:a}=e[r],{time:o,pos:l}=e[s]);const u=o-i;return u?a+(l-a)*(t-i)/u:a}class tE extends yp{constructor(t){super(t),this._table=[],this._minPos=void 0,this._tableRange=void 0}initOffsets(){const t=this._getTimestampsForTable(),n=this._table=this.buildLookupTable(t);this._minPos=Bf(n,this.min),this._tableRange=Bf(n,this.max)-this._minPos,super.initOffsets(t)}buildLookupTable(t){const{min:n,max:r}=this,s=[],i=[];let o,a,l,u,d;for(o=0,a=t.length;o<a;++o)u=t[o],u>=n&&u<=r&&s.push(u);if(s.length<2)return[{time:n,pos:0},{time:r,pos:1}];for(o=0,a=s.length;o<a;++o)d=s[o+1],l=s[o-1],u=s[o],Math.round((d+l)/2)!==u&&i.push({time:u,pos:o/(a-1)});return i}_generate(){const t=this.min,n=this.max;let r=super.getDataTimestamps();return(!r.includes(t)||!r.length)&&r.splice(0,0,t),(!r.includes(n)||r.length===1)&&r.push(n),r.sort((s,i)=>s-i)}_getTimestampsForTable(){let t=this._cache.all||[];if(t.length)return t;const n=this.getDataTimestamps(),r=this.getLabelTimestamps();return n.length&&r.length?t=this.normalize(n.concat(r)):t=n.length?n:r,t=this._cache.all=t,t}getDecimalForValue(t){return(Bf(this._table,t)-this._minPos)/this._tableRange}getValueForPixel(t){const n=this._offsets,r=this.getDecimalForPixel(t)/n.factor-n.end;return Bf(this._table,r*this._tableRange+this._minPos,!0)}}he(tE,"id","timeseries"),he(tE,"defaults",yp.defaults);const nD={data:{type:Object,required:!0},options:{type:Object,default:()=>({})},plugins:{type:Array,default:()=>[]},datasetIdKey:{type:String,default:"label"},updateMode:{type:String,default:void 0}},zte={ariaLabel:{type:String},ariaDescribedby:{type:String}},jte={type:{type:String,required:!0},destroyDelay:{type:Number,default:0},...nD,...zte},qte=KC[0]==="2"?(e,t)=>Object.assign(e,{attrs:t}):(e,t)=>Object.assign(e,t);function yl(e){return _d(e)?Be(e):e}function Wte(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:e;return _d(t)?new Proxy(e,{}):e}function Gte(e,t){const n=e.options;n&&t&&Object.assign(n,t)}function rD(e,t){e.labels=t}function sD(e,t,n){const r=[];e.datasets=t.map(s=>{const i=e.datasets.find(o=>o[n]===s[n]);return!i||!s.data||r.includes(i)?{...s}:(r.push(i),Object.assign(i,s),i)})}function Kte(e,t){const n={labels:[],datasets:[]};return rD(n,e.labels),sD(n,e.datasets,t),n}const Yte=Le({props:jte,setup(e,t){let{expose:n,slots:r}=t;const s=U(null),i=Me(null);n({chart:i});const o=()=>{if(!s.value)return;const{type:u,data:d,options:c,plugins:f,datasetIdKey:p}=e,g=Kte(d,p),m=Wte(g,d);i.value=new Tm(s.value,{type:u,data:m,options:{...c},plugins:f})},a=()=>{const u=Be(i.value);u&&(e.destroyDelay>0?setTimeout(()=>{u.destroy(),i.value=null},e.destroyDelay):(u.destroy(),i.value=null))},l=u=>{u.update(e.updateMode)};return St(o),Op(a),Ce([()=>e.options,()=>e.data],(u,d)=>{let[c,f]=u,[p,g]=d;const m=Be(i.value);if(!m)return;let y=!1;if(c){const b=yl(c),w=yl(p);b&&b!==w&&(Gte(m,b),y=!0)}if(f){const b=yl(f.labels),w=yl(g.labels),S=yl(f.datasets),P=yl(g.datasets);b!==w&&(rD(m.config.data,b),y=!0),S&&S!==P&&(sD(m.config.data,S,e.datasetIdKey),y=!0)}y&&Ot(()=>{l(m)})},{deep:!0}),()=>Mr("canvas",{role:"img",ariaLabel:e.ariaLabel,ariaDescribedby:e.ariaDescribedby,ref:s},[Mr("p",{},[r.default?r.default():""])])}});function Xte(e,t){return Tm.register(t),Le({props:nD,setup(n,r){let{expose:s}=r;const i=Me(null),o=a=>{i.value=a==null?void 0:a.chart};return s({chart:i}),()=>Mr(Yte,qte({ref:o},{type:e,...n}))}})}const Qte=Xte("bar",mh),Jte={class:"ma-3"},Zte={class:"ml-6"},ene={class:"ml-7 mt-3"},tne={key:0},nne={key:2},rne=Le({__name:"EmergencyCommands",setup(e){Tm.register(eb,tb,yh,fte,wte,cte);const t=Nt(),n=Yi(),r=U(!1),s=U([]),i=U([]),o=U(NaN),a=U(NaN),l=U(NaN),u=U({labels:[],datasets:[{label:"OctoPrint Settings response times (ms)",data:[],borderColor:"#FF6384",backgroundColor:"#ffffff"}]}),d={color:"white",plugins:{title:{color:"red",text:"Response times (ms)",display:!0}},responsive:!0},c=R(()=>n.hasFeature("batchConnectUsbCalls")),f=R(()=>n.hasFeature("batchConnectSocketCalls"));async function p(){const w=t.printers.map(C=>C.id),S=await Ml.batchSettingsGet(w),P=S.map(C=>{var k,x;return((x=(k=C.value)==null?void 0:k.appearance)==null?void 0:x.name)||"ERROR"});i.value=S.filter(C=>!C.success).map(C=>({message:C.error}));const E=S.map(C=>C.time),T=S.map(C=>{var k,x;return((x=(k=C.value)==null?void 0:k.appearance)==null?void 0:x.name)??""});o.value=E.reduce((C,k)=>C+k,0)/E.length,l.value=Math.min(...E),a.value=Math.max(...E),u.value={labels:T,datasets:[{label:"OctoPrint Settings response times (ms)",data:E,borderColor:"#FF6384",backgroundColor:"#ffffff"}]},await LO(500),r.value=!0,s.value=P}async function g(){await od.restartServer()}async function m(w){if(!confirm("Are you sure you want to toggle all printers?"))return;const S=t.printers.map(P=>P.id);await Ml.batchToggleEnabled(S,w)}async function y(){if(!confirm("Are you sure you want to connect all USBs?"))return;const w=t.printers.map(S=>S.id);await Ml.batchConnectUsb(w)}async function b(){if(!confirm("Are you sure you want to connect all sockets?"))return;const w=t.printers.map(S=>S.id);await Ml.batchConnectSocket(w)}return(w,S)=>($(),Q(yt,null,{default:v(()=>[h(sr,{color:"primary"},{default:v(()=>[h(lt,null,{default:v(()=>[h(X,null,{default:v(()=>S[6]||(S[6]=[_("settings")])),_:1})]),_:1}),h(mn,null,{default:v(()=>S[7]||(S[7]=[_(" Emergency Commands ")])),_:1})]),_:1}),h(Kt,{subheader:"",lines:"three"},{default:v(()=>[h(hs,null,{default:v(()=>S[8]||(S[8]=[_(" Emergency Commands to rectify problematic situations ")])),_:1}),h(Fe,null,{default:v(()=>[h(ht,null,{default:v(()=>S[9]||(S[9]=[_(" Server commands ")])),_:1}),h(wt,null,{default:v(()=>[S[11]||(S[11]=_(" Restart the server ")),S[12]||(S[12]=L("br",null,null,-1)),h(re,{color:"primary",disabled:"",onClick:S[0]||(S[0]=P=>g())},{default:v(()=>S[10]||(S[10]=[_(" Restart server (does not work yet) ")])),_:1})]),_:1})]),_:1}),h(Fe,null,{default:v(()=>[h(ht,null,{default:v(()=>S[13]||(S[13]=[_(" Batch disabling ")])),_:1}),h(wt,null,{default:v(()=>[S[15]||(S[15]=_(" Disable all printers in batch (will not affect print) ")),S[16]||(S[16]=L("br",null,null,-1)),h(re,{color:"primary",onClick:S[1]||(S[1]=P=>m(!1))},{default:v(()=>S[14]||(S[14]=[_(" Batch disable ")])),_:1})]),_:1})]),_:1}),h(Fe,null,{default:v(()=>[h(ht,null,{default:v(()=>S[17]||(S[17]=[_(" Batch enabling ")])),_:1}),h(wt,null,{default:v(()=>[S[19]||(S[19]=_(" Enabling all printers in batch (will not affect print and it will skip printers in maintenance mode) ")),S[20]||(S[20]=L("br",null,null,-1)),h(re,{color:"primary",onClick:S[2]||(S[2]=P=>m(!0))},{default:v(()=>S[18]||(S[18]=[_(" Batch enable ")])),_:1})]),_:1})]),_:1}),h(Fe,null,{default:v(()=>[h(ht,null,{default:v(()=>S[21]||(S[21]=[_(" Batch USB connect ")])),_:1}),h(wt,null,{default:v(()=>[S[26]||(S[26]=_(" Connect all USB devices ")),S[27]||(S[27]=L("br",null,null,-1)),h(re,{disabled:!c.value,color:"primary",onClick:S[3]||(S[3]=P=>y())},{default:v(()=>[h(X,{class:"mr-2"},{default:v(()=>S[22]||(S[22]=[_("usb")])),_:1}),S[23]||(S[23]=_(" Connect USBs "))]),_:1},8,["disabled"]),c.value?ve("",!0):($(),Q(un,{key:0},{default:v(()=>[h(X,{class:"mr-2"},{default:v(()=>S[24]||(S[24]=[_("warning")])),_:1}),S[25]||(S[25]=_(" This feature is not available, please update the FDM Monster server "))]),_:1}))]),_:1}),h(wt,{class:"mt-2"},{default:v(()=>[S[30]||(S[30]=_(" Connect all Sockets ")),S[31]||(S[31]=L("br",null,null,-1)),h(re,{disabled:!f.value,color:"primary",onClick:S[4]||(S[4]=P=>b())},{default:v(()=>[h(X,{class:"mr-2"},{default:v(()=>S[28]||(S[28]=[_("hub")])),_:1}),S[29]||(S[29]=_(" Connect Sockets "))]),_:1},8,["disabled"])]),_:1}),f.value?ve("",!0):($(),Q(un,{key:0},{default:v(()=>[h(X,{class:"mr-2"},{default:v(()=>S[32]||(S[32]=[_("warning")])),_:1}),S[33]||(S[33]=_(" This feature is not available, please update the FDM Monster server "))]),_:1}))]),_:1})]),_:1}),L("div",Jte,[h(un,null,{default:v(()=>S[34]||(S[34]=[_(" Test all OctoPrint response times ")])),_:1}),L("div",Zte,[h(re,{color:"primary",onClick:S[5]||(S[5]=P=>p())},{default:v(()=>S[35]||(S[35]=[_(" Measure response times ")])),_:1})]),L("div",ene,[r.value?($(),we("span",tne," Response times: ")):ve("",!0),r.value?($(),Q(ie(Qte),{key:1,data:u.value,options:d,height:"40"},null,8,["data"])):($(),we("span",nne," A graph will be shown, presenting the times in milliseconds (ms) "))])])]),_:1}))}}),sne={class:"text-center"},ine=Le({__name:"NotFoundView",setup(e){const t=Zo(),n=()=>{t.go(-1)};return(r,s)=>($(),Q(Pn,null,{default:v(()=>[s[6]||(s[6]=L("h2",{class:"text-center mt-lg-12"},"This page was not found.",-1)),s[7]||(s[7]=L("h1",{class:"text-center"},": (",-1)),s[8]||(s[8]=L("br",null,null,-1)),L("h4",sne,[h(re,{class:"align-center",color:"primary",to:"/",variant:"elevated"},{default:v(()=>[h(X,{class:"mr-2"},{default:v(()=>s[1]||(s[1]=[_("home")])),_:1}),s[2]||(s[2]=_(" Go home "))]),_:1}),s[5]||(s[5]=L("span",{class:"pa-5"}," or ",-1)),h(re,{class:"align-center",variant:"elevated",onClick:s[0]||(s[0]=i=>n())},{default:v(()=>[h(X,{class:"mr-2"},{default:v(()=>s[3]||(s[3]=[_("arrow_left")])),_:1}),s[4]||(s[4]=_(" Go back "))]),_:1})])]),_:1}))}}),one={key:0},ane={key:1},lne={key:2},une={key:3},cne={key:4},dne=Le({__name:"PermissionDenied",setup(e){const t=gO(),n=R(()=>t.query);return(r,s)=>($(),Q(Pn,{"fill-height":"",fluid:""},{default:v(()=>[h(AO,{color:"primary"},{default:v(()=>[h(mn,{class:"text-uppercase text-white"},{default:v(()=>s[0]||(s[0]=[L("span",{class:"font-weight-light"}," FDM ",-1),L("strong",null," Monster ",-1)])),_:1})]),_:1}),s[11]||(s[11]=L("img",{alt:"FDM Monster Background",class:"grid-bg-img align-content-center",src:Jw,style:{opacity:"0.06"}},null,-1)),h(ym,{"align-center":"",column:"","justify-center":""},{default:v(()=>[h(yt,{class:"flex align-center justify-center pa-lg-16 pa-sm-10",style:{width:"80%"}},{default:v(()=>[h(an,null,{default:v(()=>[h(X,{class:"mr-4",size:"50"},{default:v(()=>s[1]||(s[1]=[_(" lock ")])),_:1}),s[2]||(s[2]=L("h3",null,"Permission Denied",-1))]),_:1}),h(hm,{class:"mt-1"},{default:v(()=>s[3]||(s[3]=[_(" You do not have permission to access a specific resource on this page. ")])),_:1}),n.value?($(),Q(nn,{key:0},{default:v(()=>{var i,o;return[n.value.page?($(),we("div",one,[s[4]||(s[4]=_(" Page: ")),L("strong",null,ae((i=n.value)==null?void 0:i.page),1)])):ve("",!0),n.value.permissions?($(),we("div",ane,[s[5]||(s[5]=_(" Required permission(s): ")),($(!0),we(Re,null,Zt(n.value.permissions,a=>($(),we("strong",{key:a},ae(a),1))),128))])):ve("",!0),n.value.roles?($(),we("div",lne,[s[6]||(s[6]=_(" Usable roles: ")),L("strong",null,ae((o=n.value.roles)==null?void 0:o.join(", ")),1)])):ve("",!0),n.value.url?($(),we("div",une,[s[7]||(s[7]=_(" Problematic API path: ")),L("strong",null,ae(n.value.url),1)])):ve("",!0),n.value.error?($(),we("div",cne,[s[8]||(s[8]=_(" Error: ")),L("strong",null,ae(n.value.error),1)])):ve("",!0)]}),_:1})):ve("",!0),h(Nn,{class:"mt-6"},{default:v(()=>[h(re,{class:"align-center",color:"primary",to:"/",variant:"elevated"},{default:v(()=>[h(X,{class:"mr-2"},{default:v(()=>s[9]||(s[9]=[_("home")])),_:1}),s[10]||(s[10]=_(" Go home "))]),_:1})]),_:1})]),_:1})]),_:1})]),_:1}))}}),fne=Le({__name:"Logo",setup(e){return(t,n)=>($(),Q(Ki,{src:ie(OO),class:"shrink mr-1 pt-3 ml-1",contain:"",style:{opacity:"0.85"},width:"150"},null,8,["src"]))}}),hne=Le({__name:"LoginForm",setup(e){const t=ps(),n=U(""),r=U(""),s=U(!1),i=U(""),o=Zo(),a=gO(),l=U(!1),u=qr("auth:login"),d=Mt(),c=R(()=>{var m;return((m=r.value??"")==null?void 0:m.length)<3||(i.value??"").length<3});St(async()=>{if(t.loadTokens(),await t.checkAuthenticationRequirements(),t.loginRequired===!1)return console.debug("LoginView, no login required, redirecting to",a.query.redirect,"or home"),u.emit(!0),await g();if(!t.hasRefreshToken)return;await t.verifyOrRefreshLoginOnceOrLogout()&&await g()});async function f(){return await o.push({name:qt.Registration})}async function p(){var m,y,b,w;try{l.value=!0,await t.login(r.value,i.value),t.lastLogoutReason=null,i.value="",l.value=!1}catch(S){if(l.value=!1,((m=S==null?void 0:S.response)==null?void 0:m.status)===401){i.value="";const P=(b=(y=S==null?void 0:S.response)==null?void 0:y.data)==null?void 0:b.reasonCode,E=zb(P);P===Er.AccountNotVerified?d.error(E,"Please ask your administrator to verify your account and try again."):P===Er.PasswordChangeRequired&&d.error(E,"Your password needs to be changed. This feature is sadly not finished"),n.value=E;return}d.openErrorMessage({title:"Error logging in",subtitle:"Please test your connection and try again."}),n.value="Error logging in - status code "+((w=S==null?void 0:S.response)==null?void 0:w.status),i.value="";return}return n.value="",u.emit(!0),await g()}async function g(){const m=a.query.redirect;if(m){console.debug("[LoginForm] Redirecting to ",m),await o.push({path:m});return}else{console.debug("[LoginForm] Redirecting to home"),await o.push({name:qt.Home});return}}return(m,y)=>($(),Q(yt,{class:"pa-4",elevation:"10",style:{"border-radius":"10px"}},{default:v(()=>[h(nn,null,{default:v(()=>[h(eS,null,{default:v(()=>[y[7]||(y[7]=L("label",null," Username ",-1)),h(ct,{modelValue:r.value,"onUpdate:modelValue":y[0]||(y[0]=b=>r.value=b),autofocus:"",name:"login",placeholder:"Username","prepend-icon":"person",type:"text",variant:"underlined",onKeyup:y[1]||(y[1]=fv(b=>c.value||p(),["enter"]))},null,8,["modelValue"]),h(ct,{id:"password",modelValue:i.value,"onUpdate:modelValue":y[2]||(y[2]=b=>i.value=b),"append-icon":s.value?"visibility_off":"visibility",type:s.value?"text":"password",label:"Password",name:"password",password:"","prepend-icon":"lock",variant:"underlined","onClick:append":y[3]||(y[3]=b=>s.value=!s.value),onKeyup:y[4]||(y[4]=fv(b=>c.value||p(),["enter"]))},null,8,["modelValue","append-icon","type"]),n.value?($(),Q(un,{key:0,class:"mt-6",color:"error",density:"compact",variant:"outlined"},{default:v(()=>[_(ae(n.value),1)]),_:1})):ve("",!0),ie(t).lastLogoutReason?($(),Q(un,{key:1,class:"mt-6",color:"error-darken-1",density:"compact",variant:"outlined"},{default:v(()=>[_(" Reason for automatic logout: "+ae(ie(t).lastLogoutReason),1)]),_:1})):ve("",!0)]),_:1})]),_:1}),h(Nn,null,{default:v(()=>[h(re,{loading:l.value,class:"pa-4",color:"primary",size:"lg",variant:"flat",style:{width:"100%"},onClick:y[5]||(y[5]=b=>p())},{default:v(()=>y[8]||(y[8]=[_(" Login ")])),_:1},8,["loading"])]),_:1}),h(Nn,null,{default:v(()=>[h(re,{disabled:!ie(t).registration,class:"pa-4",size:"lg",variant:"flat",style:{width:"100%"},onClick:y[6]||(y[6]=b=>f())},{default:v(()=>[_(" Register new account "+ae(ie(t).registration?"":"(not enabled)")+" ",1),h(X,{class:"pl-5",icon:"right"})]),_:1},8,["disabled"])]),_:1})]),_:1}))}}),pne={class:"d-flex align-center",style:{"min-height":"calc(100vh - 148px)"}},mne={class:"pt-6 pl-6 d-flex flex-column align-center"},gne=Le({__name:"LoginView",setup(e){return(t,n)=>{const r=fne;return $(),Q(at,{class:"position-relative","no-gutters":""},{default:v(()=>[h(Ue,{cols:"12",lg:"12"},{default:v(()=>[h(Pn,null,{default:v(()=>[L("div",pne,[h(at,{justify:"center",class:"align-content-center"},{default:v(()=>[L("div",mne,[h(r),h(mn,{class:"text-uppercase text-red"},{default:v(()=>n[0]||(n[0]=[L("strong",null," FDM  ",-1),L("strong",null," Monster ",-1)])),_:1}),h(mn,{class:"mt-lg-6 mt-sm-5 mb-md-5"},{default:v(()=>n[1]||(n[1]=[_(" Login to your account ")])),_:1}),h(hm,{class:"text-grey mb-md-5"},{default:v(()=>n[2]||(n[2]=[_(" Welcome back! Please enter your details ")])),_:1})]),h(Ue,{cols:"12",md:"12"},{default:v(()=>[h(hne,{class:"login-card"})]),_:1})]),_:1})])]),_:1})]),_:1})]),_:1})}}}),vne={class:"d-flex flex-column align-center"},yne=Le({__name:"RegistrationForm",setup(e){const t=ps(),n=Zo(),r=U(""),s=U(""),i=U(!1),o=U(!1),a=U(""),l=U(""),u=U(!1),d=Mt();async function c(){return await n.push({name:qt.Login})}const f=R(()=>{var g;return((g=s.value??"")==null?void 0:g.length)<3||(a.value??"").length<3||a.value!=l.value});St(async()=>{await t.logout(),await t.checkAuthenticationRequirements(),t.registration||(d.info("Registration is disabled, please contact your administrator"),await n.push({name:qt.Login}))});async function p(){var g;try{u.value=!0,await fa.registerAccount(s.value,a.value),u.value=!1}catch(m){if(u.value=!1,((g=m==null?void 0:m.response)==null?void 0:g.status)===401){r.value="Invalid credentials";return}d.openErrorMessage({title:"Error logging in",subtitle:"Please test your connection and try again."});return}r.value="",d.info("Account created, please login"),await c()}return(g,m)=>{const y=Pr("v-flex");return $(),Q(Pn,{"fill-height":"",fluid:""},{default:v(()=>[h(ym,{"align-content-center":"","justify-center":""},{default:v(()=>[h(y,{class:"d-flex flex-column align-content-center",md4:"",sm8:"",style:{"max-width":"450px","margin-top":"10%"},xs12:""},{default:v(()=>[L("div",vne,[h(Ki,{src:require("@/assets/logo.png"),class:"shrink mr-1 pt-3 ml-1",contain:"",style:{opacity:"0.85"},width:"150"},null,8,["src"]),h(mn,{class:"text-uppercase text-red"},{default:v(()=>m[8]||(m[8]=[L("strong",null," FDM  ",-1),L("strong",null," Monster ",-1)])),_:1}),h(mn,{class:"mt-lg-6 mt-sm-5"},{default:v(()=>m[9]||(m[9]=[_(" Register new account ")])),_:1}),h(hm,{class:"text-grey"},{default:v(()=>m[10]||(m[10]=[_(" Welcome! Please register your guest account ")])),_:1})]),h(yt,{class:"elevation-4 pa-4",style:{"border-radius":"10px"}},{default:v(()=>[h(nn,null,{default:v(()=>[h(eS,null,{default:v(()=>[m[11]||(m[11]=L("label",null," Username ",-1)),h(ct,{modelValue:s.value,"onUpdate:modelValue":m[0]||(m[0]=b=>s.value=b),rules:[b=>!!b||"Username is required",b=>((b==null?void 0:b.length)??0)>=3||"Username must be of length 3 or greater",b=>!b.toLowerCase().includes("admin")||"Username may not contain the word admin",b=>!b.toLowerCase().includes("root")||"Username may not contain the word root",b=>b.toLowerCase()!=="demo"||"Username may not equal the word demo"],autofocus:"",name:"login",label:"Username","prepend-icon":"person",type:"text"},null,8,["modelValue","rules"]),h(ct,{id:"password",modelValue:a.value,"onUpdate:modelValue":m[1]||(m[1]=b=>a.value=b),"append-icon":i.value?"visibility":"visibility_off",type:i.value?"text":"password",label:"Password",name:"password",rules:[b=>!!b||"Password is required",b=>!!b&&(b==null?void 0:b.length)>=8||"Password must be of length 8 or greater"],password:"","prepend-icon":"lock","onClick:append":m[2]||(m[2]=b=>i.value=!i.value)},null,8,["modelValue","append-icon","type","rules"]),h(ct,{id:"password",modelValue:l.value,"onUpdate:modelValue":m[3]||(m[3]=b=>l.value=b),"append-icon":o.value?"visibility":"visibility_off",type:o.value?"text":"password",rules:[b=>!!b||"Repeated password is required",b=>b===a.value||"Passwords are not equal"],label:"Repeated Password",name:"password",password:"","prepend-icon":"lock","onClick:append":m[4]||(m[4]=b=>o.value=!o.value),onKeyup:m[5]||(m[5]=fv(b=>f.value||p(),["enter"]))},null,8,["modelValue","append-icon","type","rules"]),r.value?($(),Q(un,{key:0,class:"mt-6",color:"error",density:"compact",variant:"outlined"},{default:v(()=>[_(ae(r.value),1)]),_:1})):ve("",!0)]),_:1})]),_:1}),h(Nn,null,{default:v(()=>[h(re,{loading:u.value,class:"pa-4",color:"primary",size:"large",style:{width:"100%"},onClick:m[6]||(m[6]=b=>p())},{default:v(()=>m[12]||(m[12]=[_(" Register account ")])),_:1},8,["loading"])]),_:1}),h(Nn,null,{default:v(()=>[h(re,{style:{width:"100%"},class:"pa-4",size:"large",onClick:m[7]||(m[7]=b=>c())},{default:v(()=>[h(X,{class:"mr-2"},{default:v(()=>m[13]||(m[13]=[_("arrow_left")])),_:1}),m[14]||(m[14]=_("Back to Login "))]),_:1})]),_:1})]),_:1})]),_:1})]),_:1})]),_:1})}}}),bne=Le({__name:"RegistrationView",setup(e){return(t,n)=>($(),Q(Pn,{"fill-height":"",fluid:""},{default:v(()=>[h(ym,{"align-center":"","justify-center":""},{default:v(()=>[h(yne)]),_:1})]),_:1}))}}),wne=["src"],Sne=Le({__name:"CameraGridView",setup(e){const t=Nt(),n=Fn(Jt.AddOrUpdateCameraDialog),s=Vw({queryKey:["cameraStream"],queryFn:async()=>(await sp.listCameraStreams()).map(d=>({printer:t.printers.find(c=>c.id===d.printerId),cameraStream:d}))}),i=l7({mutationFn:u=>sp.deleteCameraStream(u),onSuccess:()=>s.refetch()});function o(){n.openDialog({addOrUpdate:"add"})}function a(u){u&&n.openDialog({addOrUpdate:"update",cameraId:u})}function l(u){u&&i.mutateAsync(u)}return(u,d)=>($(),we("div",null,[h(sr,null,{default:v(()=>[h(mn,{class:"mr-4"},{default:v(()=>d[1]||(d[1]=[_(" Camera Overview ")])),_:1}),h(re,{color:"primary",onClick:d[0]||(d[0]=c=>o())},{default:v(()=>[h(X,{class:"mr-2"},{default:v(()=>d[2]||(d[2]=[_("add")])),_:1}),d[3]||(d[3]=_(" Add camera "))]),_:1})]),_:1}),h(at,{class:"ma-0"},{default:v(()=>[($(!0),we(Re,null,Zt(ie(s).data.value,c=>($(),we("div",{key:c.cameraStream.id,class:"ma-4",style:{border:"1px solid grey",margin:"0"},width:"300"},[h(yt,{class:"pb-2 pl-2 pr-2",width:"300"},{default:v(()=>{var f;return[h(an,null,{default:v(()=>{var p;return[c.cameraStream.printerId?($(),Q(X,{key:0,class:"mr-2",size:"small"},{default:v(()=>d[4]||(d[4]=[_(" print ")])),_:1})):($(),Q(X,{key:1,class:"mr-2",size:"small"},{default:v(()=>d[5]||(d[5]=[_(" camera_alt ")])),_:1})),_(" "+ae((c==null?void 0:c.cameraStream.name)??((p=c==null?void 0:c.printer)==null?void 0:p.name)??"Camera"),1)]}),_:2},1024),L("img",{src:(f=c.cameraStream)==null?void 0:f.streamURL,width:"100%"},null,8,wne),d[10]||(d[10]=L("br",null,null,-1)),h(re,{class:"mr-1",size:"small",onClick:p=>a(c.cameraStream.id)},{default:v(()=>[h(X,{class:"mr-2"},{default:v(()=>d[6]||(d[6]=[_("edit")])),_:1}),d[7]||(d[7]=_(" Update "))]),_:2},1032,["onClick"]),h(re,{size:"small",onClick:p=>l(c.cameraStream.id)},{default:v(()=>[h(X,{class:"mr-2"},{default:v(()=>d[8]||(d[8]=[_("delete")])),_:1}),d[9]||(d[9]=_(" Delete "))]),_:2},1032,["onClick"])]}),_:2},1024)]))),128))]),_:1})]))}}),_ne="/img/OIG.jpg";class kne extends yr{static async postFirstTimeSetup(t){const n=Oe.completeFirstTimeSetupRoute;return await this.post(n,t)}}const xne={class:"mt-6 border_all"},Ene={class:"d-flex flex-row align-center"},Cne={class:"d-flex flex-row align-center"},Pne={class:"d-flex flex-row align-center"},Tne={class:"d-flex flex-row align-center"},Rne={class:"mt-4"},Ine={class:"mt-4"},Ane={class:"mt-14"},One={class:"mb-5 mt-10"},Mne={class:"mt-14"},Dne=Le({__name:"FirstTimeSetupView",setup(e){const t=Zo(),n=Mt(),r=U(!1),s=ps(),i=U({loginRequired:!0,registration:!1}),o=U({rootUsername:"admin",rootPassword:"",rootPassword2:""}),a=U(1);St(async()=>{var d;await s.checkAuthenticationRequirements(),(d=s.wizardState)!=null&&d.wizardCompleted&&(n.info("Setup already completed."),s.loginRequired?await t.push({name:"Login"}):await t.push({name:"Home"}))});async function l(){if(!r.value){n.error("Please fill out all required fields.");return}const d=i.value,c=o.value;await kne.postFirstTimeSetup({loginRequired:d.loginRequired,registration:d.registration,rootUsername:c.rootUsername,rootPassword:c.rootPassword}),n.openInfoMessage({title:"Setup completed"}),a.value=3}async function u(){await t.push({name:"Login"})}return(d,c)=>{const f=Pr("v-stepper-step"),p=Pr("v-stepper-content"),g=Pr("v-stepper-items");return $(),Q(Pn,null,{default:v(()=>[c[46]||(c[46]=L("img",{alt:"FDM Monster Background",class:"grid-bg-img align-content-center",src:Jw,style:{opacity:"0.08"}},null,-1)),h(bQ,{modelValue:a.value,"onUpdate:modelValue":c[10]||(c[10]=m=>a.value=m),class:"bg-grey-darken-4"},{default:v(()=>[h(vM,null,{default:v(()=>[h(f,{complete:a.value>1,step:"1"},{default:v(()=>c[11]||(c[11]=[_(" Introduction ")])),_:1},8,["complete"]),h(yn),h(f,{complete:a.value>2,step:"2"},{default:v(()=>c[12]||(c[12]=[_(" Login and registration ")])),_:1},8,["complete"]),h(yn),h(f,{step:"3"},{default:v(()=>c[13]||(c[13]=[_(" Summary ")])),_:1})]),_:1}),h(g,null,{default:v(()=>[h(p,{class:"align-content-center align-center text-center",step:"1"},{default:v(()=>[c[17]||(c[17]=L("div",{class:"align-content-center align-center text-center"},[L("img",{class:"rounded-pill ma-4",src:_ne,style:{opacity:"0.7"},width:"400"}),_(" /> "),L("h1",null,"FDM Monster"),L("small",null," This server is still unconfigured. ")],-1)),h(re,{class:"mt-14 mb-14",color:"primary",onClick:c[0]||(c[0]=m=>a.value=2)},{default:v(()=>c[14]||(c[14]=[_(" Start Setup ")])),_:1}),L("div",xne,[h(X,{class:"mr-6"},{default:v(()=>c[15]||(c[15]=[_("question_mark")])),_:1}),c[16]||(c[16]=L("small",null,[_(" If you have questions at any point, reach out on "),L("a",{href:"https://github.com/fdm-monster/fdm-monster/issues"}," Github "),_(" or on "),L("a",{href:"https://discord.gg/mwA8uP8CMc"}," Discord "),_(". ")],-1))])]),_:1}),h(p,{class:"align-content-center align-center text-center",step:"2"},{default:v(()=>[L("h4",null,[h(X,{class:"mr-2"},{default:v(()=>c[18]||(c[18]=[_("settings")])),_:1}),c[19]||(c[19]=_(" Login"))]),h(eS,{modelValue:r.value,"onUpdate:modelValue":c[6]||(c[6]=m=>r.value=m)},{default:v(()=>[h(lp,{modelValue:i.value.loginRequired,"onUpdate:modelValue":c[1]||(c[1]=m=>i.value.loginRequired=m),class:"mt-5"},{message:v(()=>[L("span",Ene,[h(X,{color:i.value.loginRequired?"success":"",disabled:!i.value.loginRequired,class:"ml-3 mr-3"},{default:v(()=>c[20]||(c[20]=[_(" check ")])),_:1},8,["color","disabled"]),c[21]||(c[21]=_(" Login is required. "))]),L("span",Cne,[h(X,{color:i.value.loginRequired?"":"error",disabled:i.value.loginRequired,class:"ml-3 mr-3"},{default:v(()=>c[22]||(c[22]=[_(" close ")])),_:1},8,["color","disabled"]),c[23]||(c[23]=_(" No login is required. The admin role is assumed. "))])]),label:v(()=>c[24]||(c[24]=[_(" Enable Login ")])),_:1},8,["modelValue"]),i.value.loginRequired?ve("",!0):($(),Q(un,{key:0,color:"error-darken-4"},{default:v(()=>c[25]||(c[25]=[_(" You might be exposing your FDM Monster server publicly. Please take care evaluating the "),L("strong",null," Enable Login ",-1),_(" option. ")])),_:1})),h(lp,{modelValue:i.value.registration,"onUpdate:modelValue":c[2]||(c[2]=m=>i.value.registration=m),class:"mt-10 mb-10"},{message:v(()=>[L("span",Pne,[h(X,{color:i.value.registration?"success":"",disabled:!i.value.registration,class:"ml-3 mr-3"},{default:v(()=>c[26]||(c[26]=[_(" check ")])),_:1},8,["color","disabled"]),c[27]||(c[27]=_(" Accounts can be registered with a guest role. "))]),L("span",Tne,[h(X,{color:i.value.registration?"":"error",disabled:i.value.registration,class:"ml-3 mr-3"},{default:v(()=>c[28]||(c[28]=[_(" close ")])),_:1},8,["color","disabled"]),c[29]||(c[29]=_(" No other accounts can be registered. "))])]),label:v(()=>c[30]||(c[30]=[_(" Enable Registration ")])),_:1},8,["modelValue"]),h(yn),L("h4",Rne,[h(X,{class:"mr-2"},{default:v(()=>c[31]||(c[31]=[_("shield")])),_:1}),c[32]||(c[32]=_(" Admin account "))]),h(ct,{modelValue:o.value.rootUsername,"onUpdate:modelValue":c[3]||(c[3]=m=>o.value.rootUsername=m),rules:[m=>!!m||"Username is required"],class:"mt-5",label:"Username","prepend-icon":"person"},{prepend:v(()=>[h(X,null,{default:v(()=>c[33]||(c[33]=[_("person")])),_:1})]),_:1},8,["modelValue","rules"]),h(ct,{modelValue:o.value.rootPassword,"onUpdate:modelValue":c[4]||(c[4]=m=>o.value.rootPassword=m),type:"password","prepend-icon":"lock",rules:[m=>!!m||"Password is required",m=>!!m&&(m==null?void 0:m.length)>=8||"Password must be of length 8 or greater"],class:"mt-5",label:"Password"},{prepend:v(()=>[h(X,null,{default:v(()=>c[34]||(c[34]=[_("password")])),_:1})]),_:1},8,["modelValue","rules"]),h(ct,{modelValue:o.value.rootPassword2,"onUpdate:modelValue":c[5]||(c[5]=m=>o.value.rootPassword2=m),type:"password","prepend-icon":"lock",rules:[m=>!!m||"Repeated password is required",m=>m===o.value.rootPassword||"Passwords are not equal"],class:"mt-5",label:"Repeated Password"},{prepend:v(()=>[h(X,null,{default:v(()=>c[35]||(c[35]=[_("password")])),_:1})]),_:1},8,["modelValue","rules"])]),_:1},8,["modelValue"]),L("div",Ine,[h(re,{class:"mr-4",onClick:c[7]||(c[7]=m=>a.value=1)},{default:v(()=>c[36]||(c[36]=[_(" Back ")])),_:1}),h(re,{disabled:!r.value,color:"primary",onClick:c[8]||(c[8]=m=>l())},{default:v(()=>c[37]||(c[37]=[_(" Verify & Submit ")])),_:1},8,["disabled"])]),h(yn,{class:"mt-4"}),L("div",Ane,[h(X,{class:"mr-6"},{default:v(()=>c[38]||(c[38]=[_("question_mark")])),_:1}),c[39]||(c[39]=L("small",null,[_(" If you have questions at any point, reach out on "),L("a",{href:"https://github.com/fdm-monster/fdm-monster/issues"}," Github "),_(" or on "),L("a",{href:"https://discord.gg/mwA8uP8CMc"}," Discord "),_(". ")],-1))])]),_:1}),h(p,{class:"align-content-center align-center text-center",step:"3"},{default:v(()=>[L("div",One,[h(X,{size:"100",class:"mr-5",color:"green circle"},{default:v(()=>c[40]||(c[40]=[_(" check_circle ")])),_:1}),c[41]||(c[41]=_(" Setup Completed "))]),c[45]||(c[45]=L("br",null,null,-1)),h(re,{color:"primary",class:"mr-4",onClick:c[9]||(c[9]=m=>u())},{default:v(()=>c[42]||(c[42]=[_(" Let's continue ")])),_:1}),L("div",Mne,[h(X,{class:"mr-6"},{default:v(()=>c[43]||(c[43]=[_("question_mark")])),_:1}),c[44]||(c[44]=L("small",null,[_(" If you have questions at any point, reach out on "),L("a",{href:"https://github.com/fdm-monster/fdm-monster/issues"}," Github "),_(" or on "),L("a",{href:"https://discord.gg/mwA8uP8CMc"}," Discord "),_(". ")],-1))])]),_:1})]),_:1})]),_:1},8,["modelValue"])]),_:1})}}}),Lne={class:"ml-4 mb-4"},$ne={class:"ml-4 mb-4"},Fne=Le({__name:"AccountSettings",setup(e){const t=Bs(),n=jw(),r=ps(),s=Zo(),i=Mt(),o=U(),a=U(""),l=U({username:"",newPassword:"",oldPassword:"",repeatPassword:""});St(async()=>{var c;await t.loadSettings(),o.value=(c=t.settings)==null?void 0:c.server.loginRequired,await n.getProfile(),l.value.username=n.username,a.value=n.userId});async function u(){var c,f;if(!((f=(c=a.value)==null?void 0:c.toString())!=null&&f.length)){i.openErrorMessage({title:"User not loaded"});return}await os.changeUsername(a.value,l.value.username),await n.getProfile(),l.value.username=n.username,i.openInfoMessage({title:"Username changed"})}async function d(){var c,f;if(!((f=(c=a.value)==null?void 0:c.toString())!=null&&f.length)){i.openErrorMessage({title:"User not loaded"});return}if(l.value.newPassword!==l.value.repeatPassword){i.openErrorMessage({title:"Passwords do not match"});return}await os.changePassword(a.value,l.value.oldPassword,l.value.newPassword),l.value.oldPassword="",l.value.newPassword="",l.value.repeatPassword="",i.openInfoMessage({title:"Password changed"}),await r.logout(!0),await vO(s)}return(c,f)=>{const p=Pr("v-list-item-content"),g=Pr("v-list-item-action-text");return $(),Q(yt,null,{default:v(()=>[h(sr,{color:"primary"},{default:v(()=>[h(lt,null,{default:v(()=>[h(X,null,{default:v(()=>f[6]||(f[6]=[_("account_circle")])),_:1})]),_:1}),h(mn,null,{default:v(()=>f[7]||(f[7]=[_(" Account Settings ")])),_:1})]),_:1}),h(Kt,{subheader:"",lines:"three"},{default:v(()=>[h(Fe,null,{default:v(()=>[o.value?ve("",!0):($(),Q(p,{key:0},{default:v(()=>[h(un,{color:"primary"},{default:v(()=>f[8]||(f[8]=[_(" Login is currently disabled. To adjust your username and password, please enable that setting at the Server Protection settings page. Then log in and visit this page. ")])),_:1})]),_:1}))]),_:1})]),_:1}),h(Kt,{subheader:"",lines:"three"},{default:v(()=>[h(Fe,null,{default:v(()=>[h(ht,null,{default:v(()=>f[9]||(f[9]=[_(" Username ")])),_:1}),h(g,null,{default:v(()=>[h(ct,{modelValue:l.value.username,"onUpdate:modelValue":f[0]||(f[0]=m=>l.value.username=m),disabled:!o.value,label:"Fill in your username"},null,8,["modelValue","disabled"])]),_:1})]),_:1}),L("div",Lne,[h(re,{disabled:!o.value,color:"primary",onClick:f[1]||(f[1]=m=>u())},{default:v(()=>f[10]||(f[10]=[_(" Change username ")])),_:1},8,["disabled"])]),h(yn),f[14]||(f[14]=L("br",null,null,-1)),h(Fe,null,{default:v(()=>[h(ht,null,{default:v(()=>f[11]||(f[11]=[_(" Old Password ")])),_:1}),h(g,null,{default:v(()=>[h(ct,{modelValue:l.value.oldPassword,"onUpdate:modelValue":f[2]||(f[2]=m=>l.value.oldPassword=m),disabled:!o.value,placeholder:"Old password",type:"password"},null,8,["modelValue","disabled"])]),_:1})]),_:1}),h(Fe,null,{default:v(()=>[h(ht,null,{default:v(()=>f[12]||(f[12]=[_(" New Password ")])),_:1}),h(g,null,{default:v(()=>[h(ct,{modelValue:l.value.newPassword,"onUpdate:modelValue":f[3]||(f[3]=m=>l.value.newPassword=m),disabled:!o.value,placeholder:"New password",type:"password"},null,8,["modelValue","disabled"])]),_:1})]),_:1}),h(Fe,null,{default:v(()=>[h(ht,null,{default:v(()=>f[13]||(f[13]=[_(" Repeat New Password ")])),_:1}),h(g,null,{default:v(()=>[h(ct,{modelValue:l.value.repeatPassword,"onUpdate:modelValue":f[4]||(f[4]=m=>l.value.repeatPassword=m),disabled:!o.value,placeholder:"Repeat new password",type:"password"},null,8,["modelValue","disabled"])]),_:1})]),_:1})]),_:1}),L("div",$ne,[h(re,{disabled:!o.value,color:"primary",onClick:f[5]||(f[5]=m=>d())},{default:v(()=>f[15]||(f[15]=[_(" Change password ")])),_:1},8,["disabled"])]),h(yn)]),_:1})}}}),Nne=Le({__name:"SettingsToolbar",props:["icon","title"],setup(e){const t=e;return(n,r)=>($(),Q(sr,null,{default:v(()=>[h(lt,null,{default:v(()=>[h(X,null,{default:v(()=>[_(ae(t.icon),1)]),_:1})]),_:1}),h(mn,null,{default:v(()=>[_(ae(t.title),1)]),_:1}),Mp(n.$slots,"default")]),_:3}))}}),Bne=Le({__name:"GridSettings",setup(e){return(t,n)=>($(),Q(at,null,{default:v(()=>[h(Ue,{cols:"12"},{default:v(()=>[h(yt,null,{default:v(()=>[h(Nne,{icon:"grid_on",title:"Grid"}),h(UA)]),_:1})]),_:1})]),_:1}))}}),Vne=Le({__name:"ServerProtectionSettings",setup(e){const t=Zo(),n=Mt(),r=ps(),s=U(""),i=U(!1),o=U(!1),a=U(3200),l=U(!1),u=U(-1),d=U(14);async function c(){var S;const b=await Un.getSettings();i.value=b.server.loginRequired,o.value=b.server.registration,s.value=((S=b.connection)==null?void 0:S.clientIp)??"127.0.0.1";const w=await Un.getSettingsSensitive();a.value=w.credentials.jwtExpiresIn/60,l.value=w.credentials.refreshTokenAttempts!==-1,u.value=w.credentials.refreshTokenAttempts,d.value=w.credentials.refreshTokenExpiry/24/3600}St(async()=>{await c()});function f(){l.value||(u.value=-1)}async function p(){const b=i.value;!b&&!confirm("Disabling login will expose your server. Continue?")||(await Un.updateLoginRequiredSettings(b),await r.logout(!0),await r.checkAuthenticationRequirements(),b?await t.push({name:qt.Login}):await t.push({name:qt.Home}),n.info("Login Required settings updated"))}async function g(){await Un.updateRegistrationEnabledSettings(o.value),await r.checkAuthenticationRequirements(),n.info("Registration settings updated")}async function m(){a.value=120,l.value=!1,u.value=-1,d.value=14,await y(),n.info("Login expiry settings reset to default")}async function y(b=!0){if(a.value<2||a.value>120)throw new Error("JWT Expiry must be between 2 and 120 minutes");if(l.value&&(u.value<50||u.value>1e3))throw new Error("Refresh Token Attempts must be between 50 and 1000");if(d.value<1||d.value>30)throw new Error("Refresh Token Expiry must be between 1 and 30 days");await Un.updateCredentialSettings(a.value*60,u.value,d.value*24*3600),n.info("Login expiry settings updated")}return(b,w)=>($(),Q(yt,null,{default:v(()=>[h(sr,{color:"primary"},{default:v(()=>[h(lt,null,{default:v(()=>[h(X,null,{default:v(()=>w[11]||(w[11]=[_("settings")])),_:1})]),_:1}),h(mn,null,{default:v(()=>w[12]||(w[12]=[_(" Server Protection Settings ")])),_:1})]),_:1}),h(Kt,{lines:"three"},{default:v(()=>[h(Fe,null,{default:v(()=>[h(ht,null,{default:v(()=>w[13]||(w[13]=[_(" Login Required ")])),_:1}),h(wt,null,{default:v(()=>[h(at,null,{default:v(()=>[h(Ue,{cols:"12",md:"2"},{default:v(()=>[h(On,{modelValue:i.value,"onUpdate:modelValue":w[0]||(w[0]=S=>i.value=S),label:"Require Login"},null,8,["modelValue"])]),_:1})]),_:1}),h(at,null,{default:v(()=>[h(Ue,null,{default:v(()=>[h(re,{color:"primary",onClick:w[1]||(w[1]=S=>p())},{default:v(()=>w[14]||(w[14]=[_(" save login required setting ")])),_:1})]),_:1})]),_:1})]),_:1})]),_:1}),h(Fe,null,{default:v(()=>[h(ht,null,{default:v(()=>w[15]||(w[15]=[_(" Registration Enabled ")])),_:1}),h(wt,null,{default:v(()=>[h(at,null,{default:v(()=>[h(Ue,{cols:"12",md:"2"},{default:v(()=>[h(On,{modelValue:o.value,"onUpdate:modelValue":w[2]||(w[2]=S=>o.value=S),label:"Enable Registration"},null,8,["modelValue"])]),_:1})]),_:1}),h(at,null,{default:v(()=>[h(Ue,null,{default:v(()=>[h(re,{color:"primary",onClick:w[3]||(w[3]=S=>g())},{default:v(()=>w[16]||(w[16]=[_(" save registration enabled setting ")])),_:1})]),_:1})]),_:1})]),_:1})]),_:1}),h(Fe,null,{default:v(()=>[h(ht,null,{default:v(()=>w[17]||(w[17]=[_(" Login Expiry Settings (advanced) ")])),_:1}),h(wt,null,{default:v(()=>[h(at,null,{default:v(()=>[h(Ue,{cols:"12",md:"2"},{default:v(()=>[h(ct,{modelValue:a.value,"onUpdate:modelValue":w[4]||(w[4]=S=>a.value=S),rules:[S=>!!S&&S>=2&&S<=120],label:"JWT Expiry (minutes)"},null,8,["modelValue","rules"])]),_:1})]),_:1}),h(at,null,{default:v(()=>[h(Ue,{cols:"12",md:"2"},{default:v(()=>[h(On,{modelValue:l.value,"onUpdate:modelValue":[w[5]||(w[5]=S=>l.value=S),w[6]||(w[6]=S=>f())],label:"Enable Refresh Token Attempts"},null,8,["modelValue"])]),_:1})]),_:1}),h(at,null,{default:v(()=>[h(Ue,{cols:"12",md:"2"},{default:v(()=>[h(ct,{modelValue:u.value,"onUpdate:modelValue":w[7]||(w[7]=S=>u.value=S),disabled:!l.value,rules:[S=>!!S&&S>=50],label:"Refresh Token Attempts (disabled: -1)",type:"number"},null,8,["modelValue","disabled","rules"])]),_:1})]),_:1}),h(at,null,{default:v(()=>[h(Ue,{cols:"12",md:"2"},{default:v(()=>[h(ct,{modelValue:d.value,"onUpdate:modelValue":w[8]||(w[8]=S=>d.value=S),rules:[S=>!!S&&S>=1&&S<=30],label:"Refresh Token Expiry (days)"},null,8,["modelValue","rules"])]),_:1})]),_:1}),h(un,{color:"secondary"},{default:v(()=>[h(X,null,{default:v(()=>w[18]||(w[18]=[_("info")])),_:1}),w[19]||(w[19]=_("   Be cautious, setting the wrong expiry could make you lose access to the server or make your user experience highly degraded! "))]),_:1}),h(at,null,{default:v(()=>[h(Ue,null,{default:v(()=>[h(re,{color:"primary",onClick:w[9]||(w[9]=S=>y())},{default:v(()=>w[20]||(w[20]=[_(" save login expiry settings ")])),_:1}),h(re,{color:"default",onClick:w[10]||(w[10]=S=>m())},{default:v(()=>w[21]||(w[21]=[_(" reset to default ")])),_:1})]),_:1})]),_:1})]),_:1})]),_:1})]),_:1})]),_:1}))}});var rb={exports:{}};const Une="2.0.0",iD=256,Hne=Number.MAX_SAFE_INTEGER||9007199254740991,zne=16,jne=iD-6,qne=["major","premajor","minor","preminor","patch","prepatch","prerelease"];var Im={MAX_LENGTH:iD,MAX_SAFE_COMPONENT_LENGTH:zne,MAX_SAFE_BUILD_LENGTH:jne,MAX_SAFE_INTEGER:Hne,RELEASE_TYPES:qne,SEMVER_SPEC_VERSION:Une,FLAG_INCLUDE_PRERELEASE:1,FLAG_LOOSE:2},jg={};const Wne=typeof process=="object"&&jg&&jg.NODE_DEBUG&&/\bsemver\b/i.test(jg.NODE_DEBUG)?(...e)=>console.error("SEMVER",...e):()=>{};var Am=Wne;(function(e,t){const{MAX_SAFE_COMPONENT_LENGTH:n,MAX_SAFE_BUILD_LENGTH:r,MAX_LENGTH:s}=Im,i=Am;t=e.exports={};const o=t.re=[],a=t.safeRe=[],l=t.src=[],u=t.t={};let d=0;const c="[a-zA-Z0-9-]",f=[["\\s",1],["\\d",s],[c,r]],p=m=>{for(const[y,b]of f)m=m.split(`${y}*`).join(`${y}{0,${b}}`).split(`${y}+`).join(`${y}{1,${b}}`);return m},g=(m,y,b)=>{const w=p(y),S=d++;i(m,S,y),u[m]=S,l[S]=y,o[S]=new RegExp(y,b?"g":void 0),a[S]=new RegExp(w,b?"g":void 0)};g("NUMERICIDENTIFIER","0|[1-9]\\d*"),g("NUMERICIDENTIFIERLOOSE","\\d+"),g("NONNUMERICIDENTIFIER",`\\d*[a-zA-Z-]${c}*`),g("MAINVERSION",`(${l[u.NUMERICIDENTIFIER]})\\.(${l[u.NUMERICIDENTIFIER]})\\.(${l[u.NUMERICIDENTIFIER]})`),g("MAINVERSIONLOOSE",`(${l[u.NUMERICIDENTIFIERLOOSE]})\\.(${l[u.NUMERICIDENTIFIERLOOSE]})\\.(${l[u.NUMERICIDENTIFIERLOOSE]})`),g("PRERELEASEIDENTIFIER",`(?:${l[u.NUMERICIDENTIFIER]}|${l[u.NONNUMERICIDENTIFIER]})`),g("PRERELEASEIDENTIFIERLOOSE",`(?:${l[u.NUMERICIDENTIFIERLOOSE]}|${l[u.NONNUMERICIDENTIFIER]})`),g("PRERELEASE",`(?:-(${l[u.PRERELEASEIDENTIFIER]}(?:\\.${l[u.PRERELEASEIDENTIFIER]})*))`),g("PRERELEASELOOSE",`(?:-?(${l[u.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${l[u.PRERELEASEIDENTIFIERLOOSE]})*))`),g("BUILDIDENTIFIER",`${c}+`),g("BUILD",`(?:\\+(${l[u.BUILDIDENTIFIER]}(?:\\.${l[u.BUILDIDENTIFIER]})*))`),g("FULLPLAIN",`v?${l[u.MAINVERSION]}${l[u.PRERELEASE]}?${l[u.BUILD]}?`),g("FULL",`^${l[u.FULLPLAIN]}$`),g("LOOSEPLAIN",`[v=\\s]*${l[u.MAINVERSIONLOOSE]}${l[u.PRERELEASELOOSE]}?${l[u.BUILD]}?`),g("LOOSE",`^${l[u.LOOSEPLAIN]}$`),g("GTLT","((?:<|>)?=?)"),g("XRANGEIDENTIFIERLOOSE",`${l[u.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`),g("XRANGEIDENTIFIER",`${l[u.NUMERICIDENTIFIER]}|x|X|\\*`),g("XRANGEPLAIN",`[v=\\s]*(${l[u.XRANGEIDENTIFIER]})(?:\\.(${l[u.XRANGEIDENTIFIER]})(?:\\.(${l[u.XRANGEIDENTIFIER]})(?:${l[u.PRERELEASE]})?${l[u.BUILD]}?)?)?`),g("XRANGEPLAINLOOSE",`[v=\\s]*(${l[u.XRANGEIDENTIFIERLOOSE]})(?:\\.(${l[u.XRANGEIDENTIFIERLOOSE]})(?:\\.(${l[u.XRANGEIDENTIFIERLOOSE]})(?:${l[u.PRERELEASELOOSE]})?${l[u.BUILD]}?)?)?`),g("XRANGE",`^${l[u.GTLT]}\\s*${l[u.XRANGEPLAIN]}$`),g("XRANGELOOSE",`^${l[u.GTLT]}\\s*${l[u.XRANGEPLAINLOOSE]}$`),g("COERCEPLAIN",`(^|[^\\d])(\\d{1,${n}})(?:\\.(\\d{1,${n}}))?(?:\\.(\\d{1,${n}}))?`),g("COERCE",`${l[u.COERCEPLAIN]}(?:$|[^\\d])`),g("COERCEFULL",l[u.COERCEPLAIN]+`(?:${l[u.PRERELEASE]})?(?:${l[u.BUILD]})?(?:$|[^\\d])`),g("COERCERTL",l[u.COERCE],!0),g("COERCERTLFULL",l[u.COERCEFULL],!0),g("LONETILDE","(?:~>?)"),g("TILDETRIM",`(\\s*)${l[u.LONETILDE]}\\s+`,!0),t.tildeTrimReplace="$1~",g("TILDE",`^${l[u.LONETILDE]}${l[u.XRANGEPLAIN]}$`),g("TILDELOOSE",`^${l[u.LONETILDE]}${l[u.XRANGEPLAINLOOSE]}$`),g("LONECARET","(?:\\^)"),g("CARETTRIM",`(\\s*)${l[u.LONECARET]}\\s+`,!0),t.caretTrimReplace="$1^",g("CARET",`^${l[u.LONECARET]}${l[u.XRANGEPLAIN]}$`),g("CARETLOOSE",`^${l[u.LONECARET]}${l[u.XRANGEPLAINLOOSE]}$`),g("COMPARATORLOOSE",`^${l[u.GTLT]}\\s*(${l[u.LOOSEPLAIN]})$|^$`),g("COMPARATOR",`^${l[u.GTLT]}\\s*(${l[u.FULLPLAIN]})$|^$`),g("COMPARATORTRIM",`(\\s*)${l[u.GTLT]}\\s*(${l[u.LOOSEPLAIN]}|${l[u.XRANGEPLAIN]})`,!0),t.comparatorTrimReplace="$1$2$3",g("HYPHENRANGE",`^\\s*(${l[u.XRANGEPLAIN]})\\s+-\\s+(${l[u.XRANGEPLAIN]})\\s*$`),g("HYPHENRANGELOOSE",`^\\s*(${l[u.XRANGEPLAINLOOSE]})\\s+-\\s+(${l[u.XRANGEPLAINLOOSE]})\\s*$`),g("STAR","(<|>)?=?\\s*\\*"),g("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$"),g("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")})(rb,rb.exports);var Yd=rb.exports;const Gne=Object.freeze({loose:!0}),Kne=Object.freeze({}),Yne=e=>e?typeof e!="object"?Gne:e:Kne;var yS=Yne;const nE=/^[0-9]+$/,oD=(e,t)=>{const n=nE.test(e),r=nE.test(t);return n&&r&&(e=+e,t=+t),e===t?0:n&&!r?-1:r&&!n?1:e<t?-1:1},Xne=(e,t)=>oD(t,e);var aD={compareIdentifiers:oD,rcompareIdentifiers:Xne};const Vf=Am,{MAX_LENGTH:rE,MAX_SAFE_INTEGER:Uf}=Im,{safeRe:sE,t:iE}=Yd,Qne=yS,{compareIdentifiers:bl}=aD;let Jne=class Gs{constructor(t,n){if(n=Qne(n),t instanceof Gs){if(t.loose===!!n.loose&&t.includePrerelease===!!n.includePrerelease)return t;t=t.version}else if(typeof t!="string")throw new TypeError(`Invalid version. Must be a string. Got type "${typeof t}".`);if(t.length>rE)throw new TypeError(`version is longer than ${rE} characters`);Vf("SemVer",t,n),this.options=n,this.loose=!!n.loose,this.includePrerelease=!!n.includePrerelease;const r=t.trim().match(n.loose?sE[iE.LOOSE]:sE[iE.FULL]);if(!r)throw new TypeError(`Invalid Version: ${t}`);if(this.raw=t,this.major=+r[1],this.minor=+r[2],this.patch=+r[3],this.major>Uf||this.major<0)throw new TypeError("Invalid major version");if(this.minor>Uf||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>Uf||this.patch<0)throw new TypeError("Invalid patch version");r[4]?this.prerelease=r[4].split(".").map(s=>{if(/^[0-9]+$/.test(s)){const i=+s;if(i>=0&&i<Uf)return i}return s}):this.prerelease=[],this.build=r[5]?r[5].split("."):[],this.format()}format(){return this.version=`${this.major}.${this.minor}.${this.patch}`,this.prerelease.length&&(this.version+=`-${this.prerelease.join(".")}`),this.version}toString(){return this.version}compare(t){if(Vf("SemVer.compare",this.version,this.options,t),!(t instanceof Gs)){if(typeof t=="string"&&t===this.version)return 0;t=new Gs(t,this.options)}return t.version===this.version?0:this.compareMain(t)||this.comparePre(t)}compareMain(t){return t instanceof Gs||(t=new Gs(t,this.options)),bl(this.major,t.major)||bl(this.minor,t.minor)||bl(this.patch,t.patch)}comparePre(t){if(t instanceof Gs||(t=new Gs(t,this.options)),this.prerelease.length&&!t.prerelease.length)return-1;if(!this.prerelease.length&&t.prerelease.length)return 1;if(!this.prerelease.length&&!t.prerelease.length)return 0;let n=0;do{const r=this.prerelease[n],s=t.prerelease[n];if(Vf("prerelease compare",n,r,s),r===void 0&&s===void 0)return 0;if(s===void 0)return 1;if(r===void 0)return-1;if(r===s)continue;return bl(r,s)}while(++n)}compareBuild(t){t instanceof Gs||(t=new Gs(t,this.options));let n=0;do{const r=this.build[n],s=t.build[n];if(Vf("build compare",n,r,s),r===void 0&&s===void 0)return 0;if(s===void 0)return 1;if(r===void 0)return-1;if(r===s)continue;return bl(r,s)}while(++n)}inc(t,n,r){switch(t){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",n,r);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",n,r);break;case"prepatch":this.prerelease.length=0,this.inc("patch",n,r),this.inc("pre",n,r);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",n,r),this.inc("pre",n,r);break;case"major":(this.minor!==0||this.patch!==0||this.prerelease.length===0)&&this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":(this.patch!==0||this.prerelease.length===0)&&this.minor++,this.patch=0,this.prerelease=[];break;case"patch":this.prerelease.length===0&&this.patch++,this.prerelease=[];break;case"pre":{const s=Number(r)?1:0;if(!n&&r===!1)throw new Error("invalid increment argument: identifier is empty");if(this.prerelease.length===0)this.prerelease=[s];else{let i=this.prerelease.length;for(;--i>=0;)typeof this.prerelease[i]=="number"&&(this.prerelease[i]++,i=-2);if(i===-1){if(n===this.prerelease.join(".")&&r===!1)throw new Error("invalid increment argument: identifier already exists");this.prerelease.push(s)}}if(n){let i=[n,s];r===!1&&(i=[n]),bl(this.prerelease[0],n)===0?isNaN(this.prerelease[1])&&(this.prerelease=i):this.prerelease=i}break}default:throw new Error(`invalid increment argument: ${t}`)}return this.raw=this.format(),this.build.length&&(this.raw+=`+${this.build.join(".")}`),this}};var br=Jne;const oE=br,Zne=(e,t,n=!1)=>{if(e instanceof oE)return e;try{return new oE(e,t)}catch(r){if(!n)return null;throw r}};var qu=Zne;const ere=qu,tre=(e,t)=>{const n=ere(e,t);return n?n.version:null};var nre=tre;const rre=qu,sre=(e,t)=>{const n=rre(e.trim().replace(/^[=v]+/,""),t);return n?n.version:null};var ire=sre;const aE=br,ore=(e,t,n,r,s)=>{typeof n=="string"&&(s=r,r=n,n=void 0);try{return new aE(e instanceof aE?e.version:e,n).inc(t,r,s).version}catch{return null}};var are=ore;const lE=qu,lre=(e,t)=>{const n=lE(e,null,!0),r=lE(t,null,!0),s=n.compare(r);if(s===0)return null;const i=s>0,o=i?n:r,a=i?r:n,l=!!o.prerelease.length;if(!!a.prerelease.length&&!l)return!a.patch&&!a.minor?"major":o.patch?"patch":o.minor?"minor":"major";const d=l?"pre":"";return n.major!==r.major?d+"major":n.minor!==r.minor?d+"minor":n.patch!==r.patch?d+"patch":"prerelease"};var ure=lre;const cre=br,dre=(e,t)=>new cre(e,t).major;var fre=dre;const hre=br,pre=(e,t)=>new hre(e,t).minor;var mre=pre;const gre=br,vre=(e,t)=>new gre(e,t).patch;var yre=vre;const bre=qu,wre=(e,t)=>{const n=bre(e,t);return n&&n.prerelease.length?n.prerelease:null};var Sre=wre;const uE=br,_re=(e,t,n)=>new uE(e,n).compare(new uE(t,n));var Vs=_re;const kre=Vs,xre=(e,t,n)=>kre(t,e,n);var Ere=xre;const Cre=Vs,Pre=(e,t)=>Cre(e,t,!0);var Tre=Pre;const cE=br,Rre=(e,t,n)=>{const r=new cE(e,n),s=new cE(t,n);return r.compare(s)||r.compareBuild(s)};var bS=Rre;const Ire=bS,Are=(e,t)=>e.sort((n,r)=>Ire(n,r,t));var Ore=Are;const Mre=bS,Dre=(e,t)=>e.sort((n,r)=>Mre(r,n,t));var Lre=Dre;const $re=Vs,Fre=(e,t,n)=>$re(e,t,n)>0;var Om=Fre;const Nre=Vs,Bre=(e,t,n)=>Nre(e,t,n)<0;var wS=Bre;const Vre=Vs,Ure=(e,t,n)=>Vre(e,t,n)===0;var lD=Ure;const Hre=Vs,zre=(e,t,n)=>Hre(e,t,n)!==0;var uD=zre;const jre=Vs,qre=(e,t,n)=>jre(e,t,n)>=0;var SS=qre;const Wre=Vs,Gre=(e,t,n)=>Wre(e,t,n)<=0;var _S=Gre;const Kre=lD,Yre=uD,Xre=Om,Qre=SS,Jre=wS,Zre=_S,ese=(e,t,n,r)=>{switch(t){case"===":return typeof e=="object"&&(e=e.version),typeof n=="object"&&(n=n.version),e===n;case"!==":return typeof e=="object"&&(e=e.version),typeof n=="object"&&(n=n.version),e!==n;case"":case"=":case"==":return Kre(e,n,r);case"!=":return Yre(e,n,r);case">":return Xre(e,n,r);case">=":return Qre(e,n,r);case"<":return Jre(e,n,r);case"<=":return Zre(e,n,r);default:throw new TypeError(`Invalid operator: ${t}`)}};var cD=ese;const tse=br,nse=qu,{safeRe:Hf,t:zf}=Yd,rse=(e,t)=>{if(e instanceof tse)return e;if(typeof e=="number"&&(e=String(e)),typeof e!="string")return null;t=t||{};let n=null;if(!t.rtl)n=e.match(t.includePrerelease?Hf[zf.COERCEFULL]:Hf[zf.COERCE]);else{const l=t.includePrerelease?Hf[zf.COERCERTLFULL]:Hf[zf.COERCERTL];let u;for(;(u=l.exec(e))&&(!n||n.index+n[0].length!==e.length);)(!n||u.index+u[0].length!==n.index+n[0].length)&&(n=u),l.lastIndex=u.index+u[1].length+u[2].length;l.lastIndex=-1}if(n===null)return null;const r=n[2],s=n[3]||"0",i=n[4]||"0",o=t.includePrerelease&&n[5]?`-${n[5]}`:"",a=t.includePrerelease&&n[6]?`+${n[6]}`:"";return nse(`${r}.${s}.${i}${o}${a}`,t)};var sse=rse;class ise{constructor(){this.max=1e3,this.map=new Map}get(t){const n=this.map.get(t);if(n!==void 0)return this.map.delete(t),this.map.set(t,n),n}delete(t){return this.map.delete(t)}set(t,n){if(!this.delete(t)&&n!==void 0){if(this.map.size>=this.max){const s=this.map.keys().next().value;this.delete(s)}this.map.set(t,n)}return this}}var ose=ise,qg,dE;function Us(){if(dE)return qg;dE=1;const e=/\s+/g;class t{constructor(V,H){if(H=s(H),V instanceof t)return V.loose===!!H.loose&&V.includePrerelease===!!H.includePrerelease?V:new t(V.raw,H);if(V instanceof i)return this.raw=V.value,this.set=[[V]],this.formatted=void 0,this;if(this.options=H,this.loose=!!H.loose,this.includePrerelease=!!H.includePrerelease,this.raw=V.trim().replace(e," "),this.set=this.raw.split("||").map(G=>this.parseRange(G.trim())).filter(G=>G.length),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${this.raw}`);if(this.set.length>1){const G=this.set[0];if(this.set=this.set.filter(j=>!m(j[0])),this.set.length===0)this.set=[G];else if(this.set.length>1){for(const j of this.set)if(j.length===1&&y(j[0])){this.set=[j];break}}}this.formatted=void 0}get range(){if(this.formatted===void 0){this.formatted="";for(let V=0;V<this.set.length;V++){V>0&&(this.formatted+="||");const H=this.set[V];for(let G=0;G<H.length;G++)G>0&&(this.formatted+=" "),this.formatted+=H[G].toString().trim()}}return this.formatted}format(){return this.range}toString(){return this.range}parseRange(V){const G=((this.options.includePrerelease&&p)|(this.options.loose&&g))+":"+V,j=r.get(G);if(j)return j;const B=this.options.loose,W=B?l[u.HYPHENRANGELOOSE]:l[u.HYPHENRANGE];V=V.replace(W,O(this.options.includePrerelease)),o("hyphen replace",V),V=V.replace(l[u.COMPARATORTRIM],d),o("comparator trim",V),V=V.replace(l[u.TILDETRIM],c),o("tilde trim",V),V=V.replace(l[u.CARETTRIM],f),o("caret trim",V);let Z=V.split(" ").map(ue=>w(ue,this.options)).join(" ").split(/\s+/).map(ue=>M(ue,this.options));B&&(Z=Z.filter(ue=>(o("loose invalid filter",ue,this.options),!!ue.match(l[u.COMPARATORLOOSE])))),o("range list",Z);const q=new Map,K=Z.map(ue=>new i(ue,this.options));for(const ue of K){if(m(ue))return[ue];q.set(ue.value,ue)}q.size>1&&q.has("")&&q.delete("");const pe=[...q.values()];return r.set(G,pe),pe}intersects(V,H){if(!(V instanceof t))throw new TypeError("a Range is required");return this.set.some(G=>b(G,H)&&V.set.some(j=>b(j,H)&&G.every(B=>j.every(W=>B.intersects(W,H)))))}test(V){if(!V)return!1;if(typeof V=="string")try{V=new a(V,this.options)}catch{return!1}for(let H=0;H<this.set.length;H++)if(A(this.set[H],V,this.options))return!0;return!1}}qg=t;const n=ose,r=new n,s=yS,i=Mm(),o=Am,a=br,{safeRe:l,t:u,comparatorTrimReplace:d,tildeTrimReplace:c,caretTrimReplace:f}=Yd,{FLAG_INCLUDE_PRERELEASE:p,FLAG_LOOSE:g}=Im,m=D=>D.value==="<0.0.0-0",y=D=>D.value==="",b=(D,V)=>{let H=!0;const G=D.slice();let j=G.pop();for(;H&&G.length;)H=G.every(B=>j.intersects(B,V)),j=G.pop();return H},w=(D,V)=>(o("comp",D,V),D=T(D,V),o("caret",D),D=P(D,V),o("tildes",D),D=k(D,V),o("xrange",D),D=I(D,V),o("stars",D),D),S=D=>!D||D.toLowerCase()==="x"||D==="*",P=(D,V)=>D.trim().split(/\s+/).map(H=>E(H,V)).join(" "),E=(D,V)=>{const H=V.loose?l[u.TILDELOOSE]:l[u.TILDE];return D.replace(H,(G,j,B,W,Z)=>{o("tilde",D,G,j,B,W,Z);let q;return S(j)?q="":S(B)?q=`>=${j}.0.0 <${+j+1}.0.0-0`:S(W)?q=`>=${j}.${B}.0 <${j}.${+B+1}.0-0`:Z?(o("replaceTilde pr",Z),q=`>=${j}.${B}.${W}-${Z} <${j}.${+B+1}.0-0`):q=`>=${j}.${B}.${W} <${j}.${+B+1}.0-0`,o("tilde return",q),q})},T=(D,V)=>D.trim().split(/\s+/).map(H=>C(H,V)).join(" "),C=(D,V)=>{o("caret",D,V);const H=V.loose?l[u.CARETLOOSE]:l[u.CARET],G=V.includePrerelease?"-0":"";return D.replace(H,(j,B,W,Z,q)=>{o("caret",D,j,B,W,Z,q);let K;return S(B)?K="":S(W)?K=`>=${B}.0.0${G} <${+B+1}.0.0-0`:S(Z)?B==="0"?K=`>=${B}.${W}.0${G} <${B}.${+W+1}.0-0`:K=`>=${B}.${W}.0${G} <${+B+1}.0.0-0`:q?(o("replaceCaret pr",q),B==="0"?W==="0"?K=`>=${B}.${W}.${Z}-${q} <${B}.${W}.${+Z+1}-0`:K=`>=${B}.${W}.${Z}-${q} <${B}.${+W+1}.0-0`:K=`>=${B}.${W}.${Z}-${q} <${+B+1}.0.0-0`):(o("no pr"),B==="0"?W==="0"?K=`>=${B}.${W}.${Z}${G} <${B}.${W}.${+Z+1}-0`:K=`>=${B}.${W}.${Z}${G} <${B}.${+W+1}.0-0`:K=`>=${B}.${W}.${Z} <${+B+1}.0.0-0`),o("caret return",K),K})},k=(D,V)=>(o("replaceXRanges",D,V),D.split(/\s+/).map(H=>x(H,V)).join(" ")),x=(D,V)=>{D=D.trim();const H=V.loose?l[u.XRANGELOOSE]:l[u.XRANGE];return D.replace(H,(G,j,B,W,Z,q)=>{o("xRange",D,G,j,B,W,Z,q);const K=S(B),pe=K||S(W),ue=pe||S(Z),le=ue;return j==="="&&le&&(j=""),q=V.includePrerelease?"-0":"",K?j===">"||j==="<"?G="<0.0.0-0":G="*":j&&le?(pe&&(W=0),Z=0,j===">"?(j=">=",pe?(B=+B+1,W=0,Z=0):(W=+W+1,Z=0)):j==="<="&&(j="<",pe?B=+B+1:W=+W+1),j==="<"&&(q="-0"),G=`${j+B}.${W}.${Z}${q}`):pe?G=`>=${B}.0.0${q} <${+B+1}.0.0-0`:ue&&(G=`>=${B}.${W}.0${q} <${B}.${+W+1}.0-0`),o("xRange return",G),G})},I=(D,V)=>(o("replaceStars",D,V),D.trim().replace(l[u.STAR],"")),M=(D,V)=>(o("replaceGTE0",D,V),D.trim().replace(l[V.includePrerelease?u.GTE0PRE:u.GTE0],"")),O=D=>(V,H,G,j,B,W,Z,q,K,pe,ue,le)=>(S(G)?H="":S(j)?H=`>=${G}.0.0${D?"-0":""}`:S(B)?H=`>=${G}.${j}.0${D?"-0":""}`:W?H=`>=${H}`:H=`>=${H}${D?"-0":""}`,S(K)?q="":S(pe)?q=`<${+K+1}.0.0-0`:S(ue)?q=`<${K}.${+pe+1}.0-0`:le?q=`<=${K}.${pe}.${ue}-${le}`:D?q=`<${K}.${pe}.${+ue+1}-0`:q=`<=${q}`,`${H} ${q}`.trim()),A=(D,V,H)=>{for(let G=0;G<D.length;G++)if(!D[G].test(V))return!1;if(V.prerelease.length&&!H.includePrerelease){for(let G=0;G<D.length;G++)if(o(D[G].semver),D[G].semver!==i.ANY&&D[G].semver.prerelease.length>0){const j=D[G].semver;if(j.major===V.major&&j.minor===V.minor&&j.patch===V.patch)return!0}return!1}return!0};return qg}var Wg,fE;function Mm(){if(fE)return Wg;fE=1;const e=Symbol("SemVer ANY");class t{static get ANY(){return e}constructor(d,c){if(c=n(c),d instanceof t){if(d.loose===!!c.loose)return d;d=d.value}d=d.trim().split(/\s+/).join(" "),o("comparator",d,c),this.options=c,this.loose=!!c.loose,this.parse(d),this.semver===e?this.value="":this.value=this.operator+this.semver.version,o("comp",this)}parse(d){const c=this.options.loose?r[s.COMPARATORLOOSE]:r[s.COMPARATOR],f=d.match(c);if(!f)throw new TypeError(`Invalid comparator: ${d}`);this.operator=f[1]!==void 0?f[1]:"",this.operator==="="&&(this.operator=""),f[2]?this.semver=new a(f[2],this.options.loose):this.semver=e}toString(){return this.value}test(d){if(o("Comparator.test",d,this.options.loose),this.semver===e||d===e)return!0;if(typeof d=="string")try{d=new a(d,this.options)}catch{return!1}return i(d,this.operator,this.semver,this.options)}intersects(d,c){if(!(d instanceof t))throw new TypeError("a Comparator is required");return this.operator===""?this.value===""?!0:new l(d.value,c).test(this.value):d.operator===""?d.value===""?!0:new l(this.value,c).test(d.semver):(c=n(c),c.includePrerelease&&(this.value==="<0.0.0-0"||d.value==="<0.0.0-0")||!c.includePrerelease&&(this.value.startsWith("<0.0.0")||d.value.startsWith("<0.0.0"))?!1:!!(this.operator.startsWith(">")&&d.operator.startsWith(">")||this.operator.startsWith("<")&&d.operator.startsWith("<")||this.semver.version===d.semver.version&&this.operator.includes("=")&&d.operator.includes("=")||i(this.semver,"<",d.semver,c)&&this.operator.startsWith(">")&&d.operator.startsWith("<")||i(this.semver,">",d.semver,c)&&this.operator.startsWith("<")&&d.operator.startsWith(">")))}}Wg=t;const n=yS,{safeRe:r,t:s}=Yd,i=cD,o=Am,a=br,l=Us();return Wg}const ase=Us(),lse=(e,t,n)=>{try{t=new ase(t,n)}catch{return!1}return t.test(e)};var Dm=lse;const use=Us(),cse=(e,t)=>new use(e,t).set.map(n=>n.map(r=>r.value).join(" ").trim().split(" "));var dse=cse;const fse=br,hse=Us(),pse=(e,t,n)=>{let r=null,s=null,i=null;try{i=new hse(t,n)}catch{return null}return e.forEach(o=>{i.test(o)&&(!r||s.compare(o)===-1)&&(r=o,s=new fse(r,n))}),r};var mse=pse;const gse=br,vse=Us(),yse=(e,t,n)=>{let r=null,s=null,i=null;try{i=new vse(t,n)}catch{return null}return e.forEach(o=>{i.test(o)&&(!r||s.compare(o)===1)&&(r=o,s=new gse(r,n))}),r};var bse=yse;const Gg=br,wse=Us(),hE=Om,Sse=(e,t)=>{e=new wse(e,t);let n=new Gg("0.0.0");if(e.test(n)||(n=new Gg("0.0.0-0"),e.test(n)))return n;n=null;for(let r=0;r<e.set.length;++r){const s=e.set[r];let i=null;s.forEach(o=>{const a=new Gg(o.semver.version);switch(o.operator){case">":a.prerelease.length===0?a.patch++:a.prerelease.push(0),a.raw=a.format();case"":case">=":(!i||hE(a,i))&&(i=a);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${o.operator}`)}}),i&&(!n||hE(n,i))&&(n=i)}return n&&e.test(n)?n:null};var _se=Sse;const kse=Us(),xse=(e,t)=>{try{return new kse(e,t).range||"*"}catch{return null}};var Ese=xse;const Cse=br,dD=Mm(),{ANY:Pse}=dD,Tse=Us(),Rse=Dm,pE=Om,mE=wS,Ise=_S,Ase=SS,Ose=(e,t,n,r)=>{e=new Cse(e,r),t=new Tse(t,r);let s,i,o,a,l;switch(n){case">":s=pE,i=Ise,o=mE,a=">",l=">=";break;case"<":s=mE,i=Ase,o=pE,a="<",l="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(Rse(e,t,r))return!1;for(let u=0;u<t.set.length;++u){const d=t.set[u];let c=null,f=null;if(d.forEach(p=>{p.semver===Pse&&(p=new dD(">=0.0.0")),c=c||p,f=f||p,s(p.semver,c.semver,r)?c=p:o(p.semver,f.semver,r)&&(f=p)}),c.operator===a||c.operator===l||(!f.operator||f.operator===a)&&i(e,f.semver))return!1;if(f.operator===l&&o(e,f.semver))return!1}return!0};var kS=Ose;const Mse=kS,Dse=(e,t,n)=>Mse(e,t,">",n);var Lse=Dse;const $se=kS,Fse=(e,t,n)=>$se(e,t,"<",n);var Nse=Fse;const gE=Us(),Bse=(e,t,n)=>(e=new gE(e,n),t=new gE(t,n),e.intersects(t,n));var Vse=Bse;const Use=Dm,Hse=Vs;var zse=(e,t,n)=>{const r=[];let s=null,i=null;const o=e.sort((d,c)=>Hse(d,c,n));for(const d of o)Use(d,t,n)?(i=d,s||(s=d)):(i&&r.push([s,i]),i=null,s=null);s&&r.push([s,null]);const a=[];for(const[d,c]of r)d===c?a.push(d):!c&&d===o[0]?a.push("*"):c?d===o[0]?a.push(`<=${c}`):a.push(`${d} - ${c}`):a.push(`>=${d}`);const l=a.join(" || "),u=typeof t.raw=="string"?t.raw:String(t);return l.length<u.length?l:t};const vE=Us(),xS=Mm(),{ANY:Kg}=xS,ac=Dm,ES=Vs,jse=(e,t,n={})=>{if(e===t)return!0;e=new vE(e,n),t=new vE(t,n);let r=!1;e:for(const s of e.set){for(const i of t.set){const o=Wse(s,i,n);if(r=r||o!==null,o)continue e}if(r)return!1}return!0},qse=[new xS(">=0.0.0-0")],yE=[new xS(">=0.0.0")],Wse=(e,t,n)=>{if(e===t)return!0;if(e.length===1&&e[0].semver===Kg){if(t.length===1&&t[0].semver===Kg)return!0;n.includePrerelease?e=qse:e=yE}if(t.length===1&&t[0].semver===Kg){if(n.includePrerelease)return!0;t=yE}const r=new Set;let s,i;for(const p of e)p.operator===">"||p.operator===">="?s=bE(s,p,n):p.operator==="<"||p.operator==="<="?i=wE(i,p,n):r.add(p.semver);if(r.size>1)return null;let o;if(s&&i){if(o=ES(s.semver,i.semver,n),o>0)return null;if(o===0&&(s.operator!==">="||i.operator!=="<="))return null}for(const p of r){if(s&&!ac(p,String(s),n)||i&&!ac(p,String(i),n))return null;for(const g of t)if(!ac(p,String(g),n))return!1;return!0}let a,l,u,d,c=i&&!n.includePrerelease&&i.semver.prerelease.length?i.semver:!1,f=s&&!n.includePrerelease&&s.semver.prerelease.length?s.semver:!1;c&&c.prerelease.length===1&&i.operator==="<"&&c.prerelease[0]===0&&(c=!1);for(const p of t){if(d=d||p.operator===">"||p.operator===">=",u=u||p.operator==="<"||p.operator==="<=",s){if(f&&p.semver.prerelease&&p.semver.prerelease.length&&p.semver.major===f.major&&p.semver.minor===f.minor&&p.semver.patch===f.patch&&(f=!1),p.operator===">"||p.operator===">="){if(a=bE(s,p,n),a===p&&a!==s)return!1}else if(s.operator===">="&&!ac(s.semver,String(p),n))return!1}if(i){if(c&&p.semver.prerelease&&p.semver.prerelease.length&&p.semver.major===c.major&&p.semver.minor===c.minor&&p.semver.patch===c.patch&&(c=!1),p.operator==="<"||p.operator==="<="){if(l=wE(i,p,n),l===p&&l!==i)return!1}else if(i.operator==="<="&&!ac(i.semver,String(p),n))return!1}if(!p.operator&&(i||s)&&o!==0)return!1}return!(s&&u&&!i&&o!==0||i&&d&&!s&&o!==0||f||c)},bE=(e,t,n)=>{if(!e)return t;const r=ES(e.semver,t.semver,n);return r>0?e:r<0||t.operator===">"&&e.operator===">="?t:e},wE=(e,t,n)=>{if(!e)return t;const r=ES(e.semver,t.semver,n);return r<0?e:r>0||t.operator==="<"&&e.operator==="<="?t:e};var Gse=jse;const Yg=Yd,SE=Im,Kse=br,_E=aD,Yse=qu,Xse=nre,Qse=ire,Jse=are,Zse=ure,eie=fre,tie=mre,nie=yre,rie=Sre,sie=Vs,iie=Ere,oie=Tre,aie=bS,lie=Ore,uie=Lre,cie=Om,die=wS,fie=lD,hie=uD,pie=SS,mie=_S,gie=cD,vie=sse,yie=Mm(),bie=Us(),wie=Dm,Sie=dse,_ie=mse,kie=bse,xie=_se,Eie=Ese,Cie=kS,Pie=Lse,Tie=Nse,Rie=Vse,Iie=zse,Aie=Gse;var lc={parse:Yse,valid:Xse,clean:Qse,inc:Jse,diff:Zse,major:eie,minor:tie,patch:nie,prerelease:rie,compare:sie,rcompare:iie,compareLoose:oie,compareBuild:aie,sort:lie,rsort:uie,gt:cie,lt:die,eq:fie,neq:hie,gte:pie,lte:mie,cmp:gie,coerce:vie,Comparator:yie,Range:bie,satisfies:wie,toComparators:Sie,maxSatisfying:_ie,minSatisfying:kie,minVersion:xie,validRange:Eie,outside:Cie,gtr:Pie,ltr:Tie,intersects:Rie,simplifyRange:Iie,subset:Aie,SemVer:Kse,re:Yg.re,src:Yg.src,tokens:Yg.t,SEMVER_SPEC_VERSION:SE.SEMVER_SPEC_VERSION,RELEASE_TYPES:SE.RELEASE_TYPES,compareIdentifiers:_E.compareIdentifiers,rcompareIdentifiers:_E.rcompareIdentifiers};const Oie={key:0},Mie={key:1},Die={key:0},Lie=Le({__name:"SoftwareUpgradeSettings",setup(e){const t=U(""),n=U(!0),r=U(!1),s=U(!1),i=U(""),o=U(""),a=U(yM),l=U(),u=U(),d=U(),c=U(!1),f=U([]),p=Yi();St(async()=>{var I;await g();const x=await ko.getVersion();i.value=x.version,o.value=((I=x.monsterPi)==null?void 0:I.trim())||""});async function g(){if(n.value=!0,t.value="",r.value=!1,p.hasFeature("githubRateLimitApi"))try{const x=await ko.getGithubRateLimit();if(x.rate.remaining===0){const M=new Date(x.rate.reset).toLocaleTimeString(),O=x.rate.reset*1e3-Date.now(),A=Math.ceil(O/6e4);t.value=`Server has reached a rate limit of the Github API. This limit will be reset at ${M} (in ${A} minutes)`,n.value=!1,r.value=!0;return}}catch{n.value=!1;return}try{const x=await ko.getClientReleases();l.value=x.current,u.value=x.minimum,f.value=x.releases}catch(x){t.value="An error occurred loading the releases: "+x.message}finally{n.value=!1}}const m=R(()=>f.value.filter(x=>{const I=lc.minor(x.tag_name)===lc.minor(u.value.tag_name),M=P(x),O=x.draft;return I&&(b()||c.value||!M)&&!O})),y=R(()=>b());function b(){const x=l.value;return P(x)}function w(x){return C(x)||!T(x,l.value)||E(x)}function S(x){const I=P(x)?`${x.tag_name}, unstable`:x.tag_name;return C(x)?`${I}, currently installed`:E(x)?`${I}, below minimum`:T(x,l.value)?I:`${I}, downgrade not allowed`}function P(x){var I;return(I=x==null?void 0:x.tag_name)!=null&&I.length?x.prerelease||x.tag_name.includes("rc")||x.tag_name.includes("unstable"):!1}function E(x){return lc.compare(x.tag_name,u.value.tag_name)===-1}function T(x,I){if(!I)throw new Error("No current release is known, cannot compare.");return s.value?!0:lc.compare(x.tag_name,I.tag_name)!==-1&&lc.compare(x.tag_name,u.value.tag_name)!==-1}function C(x){var I;return x.tag_name===((I=l.value)==null?void 0:I.tag_name)}async function k(x){confirm("Are you sure? This might cause breaking changes, if the server is outdated")&&(await ko.updateClientDistGithub(x,s.value),location.reload())}return(x,I)=>($(),Q(yt,null,{default:v(()=>[h(sr,{color:"primary"},{default:v(()=>[h(lt,null,{default:v(()=>[h(X,null,{default:v(()=>I[5]||(I[5]=[_("upgrade")])),_:1})]),_:1}),h(mn,null,{default:v(()=>I[6]||(I[6]=[_(" Software Upgrade ")])),_:1})]),_:1}),h(Kt,{lines:"three"},{default:v(()=>[h(Fe,null,{default:v(()=>[h(ht,null,{default:v(()=>I[7]||(I[7]=[_(" Current versions in use: ")])),_:1}),h(wt,null,{default:v(()=>[_(" Your server's version is: "+ae(i.value),1)]),_:1}),h(wt,null,{default:v(()=>[_(" Your client's version is: "+ae(a.value),1)]),_:1}),h(wt,null,{default:v(()=>[o.value?($(),we("div",Oie,[I[8]||(I[8]=_(" MonsterPi: ")),I[9]||(I[9]=L("div",null,"Your MonsterPi version is:",-1)),_(" "+ae(o.value),1)])):($(),we("div",Mie,I[10]||(I[10]=[_(" MonsterPi: "),L("div",null,"No MonsterPi distro was detected.",-1)])))]),_:1})]),_:1})]),_:1}),h(yn),h(Kt,{subheader:"",lines:"three"},{default:v(()=>[h(Fe,null,{default:v(()=>[h(ht,null,{default:v(()=>I[11]||(I[11]=[_(" Server upgrade ")])),_:1}),h(wt,null,{default:v(()=>I[12]||(I[12]=[_(" Please visit "),L("a",{href:"https://docs.fdm-monster.net/docs/installing/"}," the installation documentation ",-1),_(" for instructions on how to upgrade the server. ")])),_:1})]),_:1})]),_:1}),h(yn),h(Kt,{lines:"three"},{default:v(()=>[h(Fe,null,{default:v(()=>[h(ht,null,{default:v(()=>I[13]||(I[13]=[_(" Client upgrade ")])),_:1}),h(wt,null,{default:v(()=>I[14]||(I[14]=[_(" Please visit "),L("a",{href:"https://docs.fdm-monster.net/docs/configuration/updating_client_bundle"}," the installation documentation ",-1),_(" for instructions on how to upgrade the client bundle. ")])),_:1}),h(wt,null,{default:v(()=>I[15]||(I[15]=[_(" Upgrade the client webapp for quickly retrieving small fixes and features ")])),_:1})]),_:1}),h(Fe,null,{default:v(()=>{var M,O,A;return[h(ht,null,{default:v(()=>I[16]||(I[16]=[_(" Select a release to upgrade to: ")])),_:1}),h(wt,{class:"mt-2"},{default:v(()=>{var D;return[_(" Minimum required version: "+ae((D=u.value)==null?void 0:D.tag_name),1)]}),_:1}),n.value?($(),we("span",Die,[h(un,null,{default:v(()=>I[17]||(I[17]=[_(" Loading releases... ")])),_:1})])):ve("",!0),!n.value&&!((M=m.value)!=null&&M.length)?($(),Q(un,{key:1},{default:v(()=>I[18]||(I[18]=[_(" No releases to show. ")])),_:1})):ve("",!0),h(VA,{modelValue:d.value,"onUpdate:modelValue":I[0]||(I[0]=D=>d.value=D)},{default:v(()=>[($(!0),we(Re,null,Zt(m.value,D=>($(),Q(wy,{key:D.tag_name,disabled:w(D),label:S(D),value:D.tag_name},null,8,["disabled","label","value"]))),128))]),_:1},8,["modelValue"]),L("div",null,[c.value?($(),Q(un,{key:0,color:"primary","max-width":"500px"},{default:v(()=>I[19]||(I[19]=[_(" You are viewing prereleases, please install such versions at your own risk! ")])),_:1})):ve("",!0)]),L("div",null,[h(On,{modelValue:s.value,"onUpdate:modelValue":I[1]||(I[1]=D=>s.value=D),label:"Allow downgrade"},null,8,["modelValue"]),h(On,{modelValue:c.value,"onUpdate:modelValue":I[2]||(I[2]=D=>c.value=D),disabled:y.value,label:y.value?"Show prerelease versions (Currently already on prerelease version)":"Show prerelease versions"},null,8,["modelValue","disabled","label"])]),h(re,{class:"mt-2 mr-4",color:"secondary",onClick:I[3]||(I[3]=D=>g())},{default:v(()=>I[20]||(I[20]=[_(" Reload release version list ")])),_:1}),h(re,{disabled:!((O=d.value)!=null&&O.length)||d.value===((A=l.value)==null?void 0:A.tag_name),class:"mt-2",color:"primary",variant:"flat",onClick:I[4]||(I[4]=D=>k(d.value))},{default:v(()=>[h(X,null,{default:v(()=>I[21]||(I[21]=[_("upgrade")])),_:1}),I[22]||(I[22]=_(" Upgrade/downgrade client "))]),_:1},8,["disabled"])]}),_:1})]),_:1})]),_:1}))}}),$ie=Le({__name:"DiagnosticsSettings",setup(e){const t=Mt(),n=Bs(),r=U(!1),s=U(!1),i=U(!1),o=U(!1);St(async()=>{var f,p,g,m;const c=await ko.getFeatures();r.value=((f=c.anonymousDiagnosticsToggle)==null?void 0:f.available)||!1,s.value=((p=c.logDumpZip)==null?void 0:p.available)||!1,i.value=((g=c.clearLogFiles)==null?void 0:g.available)||!1,await n.loadSettings(),o.value=((m=n.serverSettings)==null?void 0:m.sentryDiagnosticsEnabled)||!1});async function a(){await Un.setSentryDiagnosticsSettings(o.value),DO(o.value)}async function l(){const c=`Test Error ${Date.now()} Sentry enabled: ${o.value}`;try{throw new Error(c)}catch(f){li(f),t.openInfoMessage({title:"Test report was sent",subtitle:`Content: ${c}`})}}async function u(){await od.downloadLogDump()}async function d(){await od.clearLogFilesOlderThanWeek(),t.openInfoMessage({title:"Action success",subtitle:"Log files older than a week have been deleted"})}return(c,f)=>($(),Q(yt,null,{default:v(()=>[h(sr,{color:"primary"},{default:v(()=>[h(lt,null,{default:v(()=>[h(X,null,{default:v(()=>f[5]||(f[5]=[_("bug_report")])),_:1})]),_:1}),h(mn,null,{default:v(()=>f[6]||(f[6]=[_(" Diagnostics ")])),_:1})]),_:1}),h(Kt,{subheader:"",lines:"three"},{default:v(()=>[h(hs,null,{default:v(()=>f[7]||(f[7]=[_(" Diagnostics to provide bug reports to the developers of this software ")])),_:1}),r.value?($(),Q(Fe,{key:0},{default:v(()=>[h(ht,null,{default:v(()=>f[8]||(f[8]=[_(" Remote Sentry diagnostic reports: ")])),_:1}),h(wt,null,{default:v(()=>[h(On,{modelValue:o.value,"onUpdate:modelValue":f[0]||(f[0]=p=>o.value=p),label:"Enable remote Sentry diagnostic reports"},null,8,["modelValue"])]),_:1}),h(wt,null,{default:v(()=>[h(re,{color:"primary",onClick:f[1]||(f[1]=p=>a())},{default:v(()=>[h(X,{class:"pr-2"},{default:v(()=>f[9]||(f[9]=[_("save")])),_:1}),f[10]||(f[10]=_(" Save "))]),_:1}),h(re,{color:"secondary",onClick:f[2]||(f[2]=p=>l())},{default:v(()=>[h(X,{class:"pr-2"},{default:v(()=>f[11]||(f[11]=[_("bug_report")])),_:1}),f[12]||(f[12]=_(" Test Error "))]),_:1})]),_:1})]),_:1})):ve("",!0),h(yn),s.value?($(),Q(Fe,{key:1},{default:v(()=>[h(ht,null,{default:v(()=>f[13]||(f[13]=[_(" Logs Dump ")])),_:1}),h(wt,null,{default:v(()=>f[14]||(f[14]=[_(" Download a .zip file containing all logs from the server ")])),_:1}),h(wt,null,{default:v(()=>[f[17]||(f[17]=L("br",null,null,-1)),h(re,{color:"primary",onClick:f[3]||(f[3]=p=>u())},{default:v(()=>[h(X,null,{default:v(()=>f[15]||(f[15]=[_("download")])),_:1}),f[16]||(f[16]=_(" Download Log Files (.zip) "))]),_:1})]),_:1})]),_:1})):ve("",!0),s.value?($(),Q(Fe,{key:2},{default:v(()=>[h(ht,null,{default:v(()=>f[18]||(f[18]=[_(" Clear log files ")])),_:1}),h(wt,null,{default:v(()=>[f[21]||(f[21]=L("br",null,null,-1)),h(re,{color:"default",onClick:f[4]||(f[4]=p=>d())},{default:v(()=>[h(X,null,{default:v(()=>f[19]||(f[19]=[_("download")])),_:1}),f[20]||(f[20]=_(" Clear log files older than a week "))]),_:1})]),_:1})]),_:1})):ve("",!0)]),_:1})]),_:1}))}});class Fie extends yr{static async getCompletions(){const t=`${Oe.printCompletionRoute}`;return await this.get(t)}}const fD=Le({__name:"PrintStatistics",setup(e){const t=U([]),n=U([]),r=U(""),s=Nt(),i=Xi();St(async()=>{await o()}),Ce([()=>r.value],()=>{u()});const o=async()=>{t.value=[],n.value=[],t.value=await Fie.getCompletions(),u()},a=d=>s.printer(d),l=d=>i.floorOfPrinter(d),u=()=>{var p;const d=s.printers.map(g=>g.id),c=d.length?t.value.filter(g=>d.includes(g.printerId)):t.value,f=(p=r.value)!=null&&p.length?c.filter(g=>{const m=s.printers.find(y=>y.id===g.printerId);return m?(m.name+m.printerURL).toLowerCase().includes(r.value.toLowerCase()):!1}):c;n.value=f.sort((g,m)=>g.failureCount===m.failureCount?g.printCount>m.printCount?-1:1:g.failureCount>m.failureCount?-1:1)};return(d,c)=>($(),Q(ap,{height:"100%",width:"100%"},{default:v(()=>[h(Pn,null,{default:v(()=>[h(at,null,{default:v(()=>[h(Ue,null,{default:v(()=>[h(X,null,{default:v(()=>c[2]||(c[2]=[_("filter_list")])),_:1}),c[3]||(c[3]=_(" Filter by printer name (optional) "))]),_:1}),h(Ue,null,{default:v(()=>[h(ct,{modelValue:r.value,"onUpdate:modelValue":c[0]||(c[0]=f=>r.value=f),class:"p-2",clearable:"",label:"Search","prepend-icon":"search","single-line":""},null,8,["modelValue"])]),_:1})]),_:1})]),_:1}),h(un,null,{default:v(()=>[c[5]||(c[5]=_(" Please reload here if you want updated results: ")),h(re,{color:"primary",size:"x-small",onClick:c[1]||(c[1]=f=>o())},{default:v(()=>c[4]||(c[4]=[_(" Reload ")])),_:1})]),_:1}),h(Gy,{dark:""},{default:v(()=>[c[11]||(c[11]=L("thead",null,[L("tr",null,[L("th",{class:"text-left"},"Printer name"),L("th",{class:"text-left"},"Floor"),L("th",{class:"text-left"},"Fail/ Success/ Total"),L("th",{class:"text-left"},"Last success"),L("th",{class:"text-left"},"Last failure"),L("th",{class:"text-left"},"Successes (week/48H/24H)"),L("th",{class:"text-left"},"Failures (week/48H/24H)")])],-1)),L("tbody",null,[($(!0),we(Re,null,Zt(n.value,f=>{var p,g,m,y;return $(),we("tr",{key:f.printerId},[L("td",null,ae(((p=a(f.printerId))==null?void 0:p.name)??"?"),1),L("td",null,ae(((g=l(f.printerId))==null?void 0:g.name)??"?"),1),L("td",null,[_(" × "+ae(f.failureCount)+" / 🗸 "+ae(f.successCount)+" ",1),L("strong",null," ~"+ae(f.printCount),1)]),L("td",null,ae(Date.now()-((m=f.lastSuccess)==null?void 0:m.createdAt)||"-"),1),L("td",null,[h(xt,{location:"bottom"},CC({default:v(()=>{var b,w,S,P;return[L("span",null,[_(ae(((b=f.lastFailure)==null?void 0:b.status)||"-")+" ",1),c[7]||(c[7]=L("br",null,null,-1)),_(" "+ae((w=f.lastFailure)==null?void 0:w.createdAt)+" ",1),c[8]||(c[8]=L("br",null,null,-1)),L("small",null,ae((S=f.lastFailure)==null?void 0:S.fileName),1),c[9]||(c[9]=L("br",null,null,-1)),L("strong",null,ae((P=f.lastFailure)==null?void 0:P.completionLog),1),c[10]||(c[10]=L("br",null,null,-1))])]}),_:2},[(y=f.lastFailure)!=null&&y.status?{name:"activator",fn:v(({props:b})=>[h(X,me({ref_for:!0},b),{default:v(()=>c[6]||(c[6]=[_("info")])),_:2},1040)]),key:"0"}:void 0]),1024)]),L("td",null,ae(f.successEventsLastWeek)+" "+ae(f.successEventsLast48H)+" "+ae(f.successEventsLast24H),1),L("td",null,ae(f.failureEventsLastWeek)+" "+ae(f.failureEventsLast48H)+" "+ae(f.failureEventsLast24H),1)])}),128))])]),_:1})]),_:1}))}}),Nie=Le({name:"PrintStatisticsView",components:{PrintStatistics:fD}});function Bie(e,t,n,r,s,i){const o=fD;return $(),Q(Pn,null,{default:v(()=>[h(o)]),_:1})}const Vie=ea(Nie,[["render",Bie]]),Uie=Le({__name:"ExperimentalSettings",setup(e){const t=U(!1),n=U(!1),r=U(!1);async function s(){const l=await Un.getSettings();t.value=l.server.experimentalMoonrakerSupport,n.value=l.server.experimentalTypeormSupport,r.value=l.server.experimentalClientSupport}St(async()=>{await s()});const i=async()=>{await Un.updateExperimentalMoonrakerSupport(t.value),await Un.updateExperimentalClientSupport(r.value),await s()},o=async()=>{await Un.updateExperimentalMoonrakerSupport(!1),await Un.updateExperimentalClientSupport(!1),await s()},a=async()=>{await Un.updateExperimentalClientSupport(r.value),window.location.reload()};return(l,u)=>($(),Q(at,null,{default:v(()=>[h(Ue,{cols:"12"},{default:v(()=>[h(yt,null,{default:v(()=>[h(an,null,{default:v(()=>u[3]||(u[3]=[L("h2",null,"Settings",-1)])),_:1}),h(nn,null,{default:v(()=>[h(at,null,{default:v(()=>[h(Ue,{cols:"12",md:"6"},{default:v(()=>[h(yt,null,{default:v(()=>[h(an,null,{default:v(()=>[L("h3",null,[u[6]||(u[6]=_(" Experimental Features ")),h(xt,{bottom:""},{activator:v(({props:d})=>[h(X,me({class:"help-icon"},d),{default:v(()=>u[4]||(u[4]=[_("help_outline")])),_:2},1040)]),default:v(()=>[u[5]||(u[5]=L("span",{class:"tooltip-content"}," Moonraker support is currently in beta, use at your own risk. ",-1))]),_:1})])]),_:1}),h(nn,null,{default:v(()=>[h(On,{modelValue:t.value,"onUpdate:modelValue":u[0]||(u[0]=d=>t.value=d),label:"Enable Experimental Moonraker Support","hide-details":""},{label:v(()=>u[7]||(u[7]=[L("span",null,"Enable Experimental Moonraker Support",-1)])),_:1},8,["modelValue"])]),_:1})]),_:1})]),_:1}),h(Ue,{cols:"12",md:"6"},{default:v(()=>[h(yt,null,{default:v(()=>[h(an,null,{default:v(()=>[L("h3",null,[u[10]||(u[10]=_(" Database Settings ")),h(xt,{bottom:""},{activator:v(({props:d})=>[h(X,Zg(Eh(d)),{default:v(()=>u[8]||(u[8]=[_("help_outline")])),_:2},1040)]),default:v(()=>[u[9]||(u[9]=L("span",{class:"tooltip-content"}," By enabling this setting you will set FDM Monster to SQLite as a database source (standalone mode). Please set 'ENABLE_EXPERIMENTAL_TYPEORM' to 'true' to enable this feature. ",-1))]),_:1})])]),_:1}),h(nn,null,{default:v(()=>[h(On,{modelValue:n.value,"onUpdate:modelValue":u[1]||(u[1]=d=>n.value=d),label:"Enable TypeORM Support","hide-details":"",disabled:""},{label:v(()=>u[11]||(u[11]=[L("span",null,"Enable TypeORM Support",-1)])),_:1},8,["modelValue"])]),_:1})]),_:1})]),_:1}),h(Ue,{cols:"12",md:"6"},{default:v(()=>[h(yt,null,{default:v(()=>[h(an,null,{default:v(()=>[L("h3",null,[u[14]||(u[14]=_(" Experimental Features ")),h(xt,{bottom:""},{activator:v(({props:d})=>[h(X,me({class:"help-icon"},d),{default:v(()=>u[12]||(u[12]=[_("help_outline")])),_:2},1040)]),default:v(()=>[u[13]||(u[13]=L("span",{class:"tooltip-content"}," Enables the next version of the FDM Monster UI (experimental). ",-1))]),_:1})])]),_:1}),h(nn,null,{default:v(()=>[h(On,{modelValue:r.value,"onUpdate:modelValue":u[2]||(u[2]=d=>r.value=d),label:"Enable Next Client Version (Experimental)","hide-details":"",onChange:a},{label:v(()=>u[15]||(u[15]=[L("span",null,"Enable Next Client Version (Experimental)",-1)])),_:1},8,["modelValue"])]),_:1})]),_:1})]),_:1})]),_:1})]),_:1}),h(Nn,null,{default:v(()=>[h(wn),h(re,{color:"primary",onClick:i},{default:v(()=>u[16]||(u[16]=[_("Save Settings")])),_:1}),h(re,{onClick:o},{default:v(()=>u[17]||(u[17]=[_("Reset to Default")])),_:1})]),_:1})]),_:1})]),_:1})]),_:1}))}}),Gn={requiresAuth:!0},Xg={requiresAuth:!1},CS=IK({history:oK("/"),routes:[{path:"/",name:qt.Home,meta:Gn,component:WY},{path:"/first-time-setup",name:qt.FirstTimeSetup,meta:Xg,component:Dne},{path:"/login",name:qt.Login,meta:Xg,component:gne},{path:"/registration",name:qt.Registration,meta:Xg,component:bne},{path:"/printers",name:qt.PrintersView,meta:Gn,component:CQ},{path:"/cameras",name:qt.CameraGridView,component:Sne},{path:"/settings",component:PQ,meta:Gn,children:[{path:"",meta:Gn,redirect:"/settings/grid"},{path:"account",meta:Gn,component:Fne},{path:"server-protection",meta:Gn,component:Vne},{path:"grid",meta:Gn,component:Bne},{path:"floors",meta:Gn,component:WQ},{path:"user-management",meta:Gn,component:BQ},{path:"octoprint",meta:Gn,component:HQ},{path:"emergency-commands",meta:Gn,component:rne},{path:"software-upgrade",meta:Gn,component:Lie},{path:"diagnostics",meta:Gn,component:$ie},{path:"experimental",meta:Gn,component:Uie}]},{path:"/statistics",name:qt.PrintStatistics,meta:Gn,component:Vie},{path:"/about",name:"About",component:XQ},{path:"/permission-denied",name:qt.PermissionDenied,meta:Gn,component:dne},{path:"/:pathMatch(.*)*",name:"NotFound",component:ine}]});CS.beforeEach(async(e,t,n)=>{var s,i;const r=ps();if(!((s=e==null?void 0:e.meta)!=null&&s.requiresAuth)||r.loginRequired===!1)return console.debug(`No auth required on route ${e.fullPath}`),n();if(console.debug(`Auth required on route ${e.fullPath} (loginRequired=${r.loginRequired}, registration=${r.registration}, wizardState=${r.wizardState}, requiresAuth=${(i=e==null?void 0:e.meta)==null?void 0:i.requiresAuth})`),r.loadTokens(),!r.hasAuthToken&&!r.hasRefreshToken){if(console.debug("Not logged in, redirecting to login page"),t.path=="/login")throw new Error("Already on login page, cannot redirect");return n({path:"/login",query:{redirect:e.fullPath}})}return n()});const Hie={collapse:"keyboard_arrow_up",complete:"check",cancel:"cancel",close:"close",delete:"cancel",clear:"cancel",success:"check_circle",info:"info",warning:"priority_high",error:"warning",prev:"chevron_left",next:"chevron_right",checkboxOn:"check_box",checkboxOff:"check_box_outline_blank",checkboxIndeterminate:"indeterminate_check_box",delimiter:"fiber_manual_record",sortAsc:"arrow_upward",sortDesc:"arrow_downward",expand:"keyboard_arrow_down",menu:"menu",subgroup:"arrow_drop_down",dropdown:"arrow_drop_down",radioOn:"radio_button_checked",radioOff:"radio_button_unchecked",edit:"edit",ratingEmpty:"star_border",ratingFull:"star",ratingHalf:"star_half",loading:"cached",first:"first_page",last:"last_page",unfold:"unfold_more",file:"attach_file",plus:"add",minus:"remove",calendar:"event",treeviewCollapse:"arrow_drop_down",treeviewExpand:"arrow_right",eyeDropper:"colorize"},zie={component:e=>Mr(eN,{...e,class:"material-icons"})};function hD(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const{blueprint:t,...n}=e,r=tr(t,n),{aliases:s={},components:i={},directives:o={}}=r,a=LF(r.defaults),l=zN(r.display,r.ssr),u=qF(r.theme),d=nN(r.icons),c=cN(r.locale),f=_6(r.date,c),p=Pq(r.goTo,c);return{install:m=>{for(const y in o)m.directive(y,o[y]);for(const y in i)m.component(y,i[y]);for(const y in s)m.component(y,xu({...s[y],name:y,aliasName:s[y].name}));if(u.install(m),m.provide(au,a),m.provide(Tv,l),m.provide(jc,u),m.provide(_v,d),m.provide(Dh,c),m.provide(S6,f.options),m.provide(tk,f.instance),m.provide(KI,p),kt&&r.ssr)if(m.$nuxt)m.$nuxt.hook("app:suspense:resolve",()=>{l.update()});else{const{mount:y}=m;m.mount=function(){const b=y(...arguments);return Ot(()=>l.update()),m.mount=y,b}}vr.reset(),m.mixin({computed:{$vuetify(){return vn({defaults:wl.call(this,au),display:wl.call(this,Tv),theme:wl.call(this,jc),icons:wl.call(this,_v),locale:wl.call(this,Dh),date:wl.call(this,tk)})}}})},defaults:a,display:l,theme:u,icons:d,locale:c,date:f,goTo:p}}const jie="3.7.4";hD.version=jie;function wl(e){var r,s;const t=this.$,n=((r=t.parent)==null?void 0:r.provides)??((s=t.vnode.appContext)==null?void 0:s.provides);if(n&&e in n)return n[e]}const qie=hD({theme:{defaultTheme:"dark",themes:{dark:{dark:!0,colors:{primary:"#9B0505",secondary:"#424242",accent:"#82B1FF",error:"#FF5252",info:"#2196F3",success:"#4CAF50",warning:"#FFC107"}},light:{dark:!1,colors:{primary:"#9B0505",secondary:"#424242",accent:"#82B1FF",error:"#FF5252",info:"#2196F3",success:"#4CAF50",warning:"#FFC107"}}}},icons:{defaultSet:"md",aliases:Hie,sets:{md:zie}}}),Wie=B$();function Gie(e){e.use(qie).use(o7).use(Wie)}const kE=(e,t,n)=>{const r=Nt(),s=Qw(),i=Mt();if(t!=null&&t.length){const o=t.length===1,a=t[0];e.ondrop=async l=>{var f;l.preventDefault(),e.style.border=bp;const u=(f=l.dataTransfer)==null?void 0:f.files;if(!(u!=null&&u.length))return;const d=[...Array.from(u)];let c=[];if(o){const p=d.length===1?d[0].name:null;console.debug("Single printer upload mode",t.length,d.length,p),c=LY(a,d)}else{if(d.length>1)throw"Cannot upload multiple files to multiple printers";console.debug("Multi printer upload mode",t.length,d.length);const p=d[0];c=UO(t,p)}s.queueUploads(c),r.clearSelectedPrinters()}}else e.ondrop=async o=>{o.preventDefault(),e.style.border=bp,i.openInfoMessage({title:"No action performed",subtitle:"Please select one or more printers",warning:!0})}},bp="1px solid #2b2a27",Kie="background-color 0.5s ease",xE="1px solid red";function Yie(){return{mounted:(e,t,n)=>{var r;e.style.border=bp,e.style.transition=Kie,e.ondragenter=s=>{s.preventDefault(),e.style.border=xE},e.ondragover=s=>{s.preventDefault(),e.style.border=xE},e.ondragleave=s=>{s.preventDefault(),e.style.border=bp},kE(e,(r=t.value)==null?void 0:r.printers,n.appContext)},beforeUpdate:(e,t,n)=>{kE(e,t.value,n.appContext)}}}const Qg="1px solid #2b2a27",Xie="1px solid gray",EE=(e,t,n)=>{const r=t==null?void 0:t.printerSet,s=Xi();if(r){e.ondrop=null,e.ondragover=null,e.ondragleave=null;return}e.style.border=Qg,e.ondrop=async i=>{var c;if(e.style.border=Qg,i.preventDefault(),!i.dataTransfer)return;const o=i.dataTransfer.getData("text"),a=JSON.parse(o);if(!PY(a)){console.debug("Drop not recognized",a);return}const u=(c=s.selectedFloor)==null?void 0:c.id;if(!u)throw new Error("Floor is not set");const d=a.printerId;if(!d)throw new Error("PrinterId was not provided");await as.addPrinterToFloor(u,{printerId:d,x:t.x,y:t.y})},e.ondragover=i=>{i!=null&&i.dataTransfer&&(i.dataTransfer&&Array.from(i.dataTransfer.items).filter(o=>o.kind==="file").length||(e.style.border=Xie,i.preventDefault()))},e.ondragleave=i=>{e.style.border=Qg,i.preventDefault()}};function Qie(){return{mounted:(e,t,n)=>{EE(e,t.value,n.appContext)},beforeUpdate:(e,t,n)=>{EE(e,t.value,n.appContext)}}}const ta=L$(vY);console.log("[DEV: false][PROD: true]","0.0.11");iq({app:ta,dsn:"https://f64683e8d1cb4ac291434993cff1bf9b@o4503975545733120.ingest.sentry.io/4503975546912768",integrations:[lq({router:CS}),T8()],release:"0.0.11",environment:"production",enabled:!0,tracesSampleRate:1,replaysSessionSampleRate:.1,replaysOnErrorSampleRate:1});ta.config.errorHandler=e=>{var t;if(e instanceof OT){console.error(`An error was caught [${e.name}]:
85
+ ${e.message}
86
+ ${(t=e.config)==null?void 0:t.url}
87
+ ${e.stack}`),Mt().openErrorMessage({title:"An error occurred",subtitle:e.message,timeout:5e3});return}else console.error(`An error was caught [${e.name}]:
88
+ ${e.message}
89
+ ${e.stack}`);Mt().openErrorMessage({title:"An error occurred",subtitle:e.message,timeout:5e3}),li(e)};ta.directive("drop-upload",Yie());ta.directive("drop-printer-position",Qie());Gie(ta);ta.provide("appConstants",$K());ta.use(CS);ta.mount("#app");
90
+ //# sourceMappingURL=index-DYmkB_cv.js.map