@fdm-monster/client-next 0.0.18 → 0.0.20
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.
- package/.eslintrc-auto-import.json +3 -1
- package/.yarn/install-state.gz +0 -0
- package/.yarn/releases/yarn-4.9.1.cjs +948 -0
- package/.yarnrc.yml +1 -1
- package/RELEASE_NOTES.MD +17 -0
- package/dist/assets/index-CXYoPsmd.js +93 -0
- package/dist/assets/index-CXYoPsmd.js.map +1 -0
- package/dist/assets/index-DEBy2iV3.css +5 -0
- package/dist/index.html +2 -2
- package/package.json +2 -2
- package/tsconfig.json +1 -1
- package/.yarn/releases/yarn-4.7.0.cjs +0 -935
- package/dist/assets/index-C1eI61Be.css +0 -5
- package/dist/assets/index-DxmHK0SK.js +0 -90
- package/dist/assets/index-DxmHK0SK.js.map +0 -1
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
var eD=Object.defineProperty;var qw=e=>{throw TypeError(e)};var tD=(e,t,n)=>t in e?eD(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var we=(e,t,n)=>tD(e,typeof t!="symbol"?t+"":t,n),qm=(e,t,n)=>t.has(e)||qw("Cannot "+n);var W=(e,t,n)=>(qm(e,t,"read from private field"),n?n.call(e):t.get(e)),je=(e,t,n)=>t.has(e)?qw("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),De=(e,t,n,r)=>(qm(e,t,"write to private field"),r?r.call(e,n):t.set(e,n),n),tt=(e,t,n)=>(qm(e,t,"access private method"),n);var Yd=(e,t,n,r)=>({set _(s){De(e,t,s,n)},get _(){return W(e,t,r)}});try{let e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="267d68d6-2605-44f4-ba06-e9dde9f91ca4",e._sentryDebugIdIdentifier="sentry-dbid-267d68d6-2605-44f4-ba06-e9dde9f91ca4")}catch{}{let e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{};e.SENTRY_RELEASE={id:"6080011e7f20e4d9cdf998d563ab54d4f45513f4"}}(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 Eb(e){const t=Object.create(null);for(const n of e.split(","))t[n]=1;return n=>n in t}const $t={},Dl=[],oi=()=>{},nD=()=>!1,Cp=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),Cb=e=>e.startsWith("onUpdate:"),vn=Object.assign,Tb=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},rD=Object.prototype.hasOwnProperty,Tt=(e,t)=>rD.call(e,t),We=Array.isArray,Ll=e=>Tp(e)==="[object Map]",ZE=e=>Tp(e)==="[object Set]",Xe=e=>typeof e=="function",rn=e=>typeof e=="string",Gi=e=>typeof e=="symbol",Yt=e=>e!==null&&typeof e=="object",eC=e=>(Yt(e)||Xe(e))&&Xe(e.then)&&Xe(e.catch),tC=Object.prototype.toString,Tp=e=>tC.call(e),sD=e=>Tp(e).slice(8,-1),nC=e=>Tp(e)==="[object Object]",Pb=e=>rn(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,yc=Eb(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),Pp=e=>{const t=Object.create(null);return n=>t[n]||(t[n]=e(n))},iD=/-(\w)/g,Rr=Pp(e=>e.replace(iD,(t,n)=>n?n.toUpperCase():"")),oD=/\B([A-Z])/g,No=Pp(e=>e.replace(oD,"-$1").toLowerCase()),ci=Pp(e=>e.charAt(0).toUpperCase()+e.slice(1)),Wm=Pp(e=>e?`on${ci(e)}`:""),xo=(e,t)=>!Object.is(e,t),jf=(e,...t)=>{for(let n=0;n<e.length;n++)e[n](...t)},rC=(e,t,n,r=!1)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:r,value:n})},vv=e=>{const t=parseFloat(e);return isNaN(t)?e:t},aD=e=>{const t=rn(e)?Number(e):NaN;return isNaN(t)?e:t};let Ww;const Rp=()=>Ww||(Ww=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function is(e){if(We(e)){const t={};for(let n=0;n<e.length;n++){const r=e[n],s=rn(r)?dD(r):is(r);if(s)for(const i in s)t[i]=s[i]}return t}else if(rn(e)||Yt(e))return e}const lD=/;(?![^(]*\))/g,uD=/:([^]+)/,cD=/\/\*[^]*?\*\//g;function dD(e){const t={};return e.replace(cD,"").split(lD).forEach(n=>{if(n){const r=n.split(uD);r.length>1&&(t[r[0].trim()]=r[1].trim())}}),t}function Bo(e){let t="";if(rn(e))t=e;else if(We(e))for(let n=0;n<e.length;n++){const r=Bo(e[n]);r&&(t+=r+" ")}else if(Yt(e))for(const n in e)e[n]&&(t+=n+" ");return t.trim()}function yv(e){if(!e)return null;let{class:t,style:n}=e;return t&&!rn(t)&&(e.class=Bo(t)),n&&(e.style=is(n)),e}const fD="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",hD=Eb(fD);function sC(e){return!!e||e===""}const iC=e=>!!(e&&e.__v_isRef===!0),re=e=>rn(e)?e:e==null?"":We(e)||Yt(e)&&(e.toString===tC||!Xe(e.toString))?iC(e)?re(e.value):JSON.stringify(e,oC,2):String(e),oC=(e,t)=>iC(t)?oC(e,t.value):Ll(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((n,[r,s],i)=>(n[Gm(r,i)+" =>"]=s,n),{})}:ZE(t)?{[`Set(${t.size})`]:[...t.values()].map(n=>Gm(n))}:Gi(t)?Gm(t):Yt(t)&&!We(t)&&!nC(t)?String(t):t,Gm=(e,t="")=>{var n;return Gi(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 ur;class aC{constructor(t=!1){this.detached=t,this._active=!0,this.effects=[],this.cleanups=[],this._isPaused=!1,this.parent=ur,!t&&ur&&(this.index=(ur.scopes||(ur.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=ur;try{return ur=this,t()}finally{ur=n}}}on(){ur=this}off(){ur=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 $a(e){return new aC(e)}function Ip(){return ur}function yn(e,t=!1){ur&&ur.cleanups.push(e)}let jt;const Km=new WeakSet;class lC{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,ur&&ur.active&&ur.effects.push(this)}pause(){this.flags|=64}resume(){this.flags&64&&(this.flags&=-65,Km.has(this)&&(Km.delete(this),this.trigger()))}notify(){this.flags&2&&!(this.flags&32)||this.flags&8||cC(this)}run(){if(!(this.flags&1))return this.fn();this.flags|=2,Gw(this),dC(this);const t=jt,n=Rs;jt=this,Rs=!0;try{return this.fn()}finally{fC(this),jt=t,Rs=n,this.flags&=-3}}stop(){if(this.flags&1){for(let t=this.deps;t;t=t.nextDep)Ab(t);this.deps=this.depsTail=void 0,Gw(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){this.flags&64?Km.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){bv(this)&&this.run()}get dirty(){return bv(this)}}let uC=0,bc,wc;function cC(e,t=!1){if(e.flags|=8,t){e.next=wc,wc=e;return}e.next=bc,bc=e}function Rb(){uC++}function Ib(){if(--uC>0)return;if(wc){let t=wc;for(wc=void 0;t;){const n=t.next;t.next=void 0,t.flags&=-9,t=n}}let e;for(;bc;){let t=bc;for(bc=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 dC(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function fC(e){let t,n=e.depsTail,r=n;for(;r;){const s=r.prevDep;r.version===-1?(r===n&&(n=s),Ab(r),pD(r)):t=r,r.dep.activeLink=r.prevActiveLink,r.prevActiveLink=void 0,r=s}e.deps=t,e.depsTail=n}function bv(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(hC(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function hC(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===Bc))return;e.globalVersion=Bc;const t=e.dep;if(e.flags|=2,t.version>0&&!e.isSSR&&e.deps&&!bv(e)){e.flags&=-3;return}const n=jt,r=Rs;jt=e,Rs=!0;try{dC(e);const s=e.fn(e._value);(t.version===0||xo(s,e._value))&&(e._value=s,t.version++)}catch(s){throw t.version++,s}finally{jt=n,Rs=r,fC(e),e.flags&=-3}}function Ab(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)Ab(i,!0)}!t&&!--n.sc&&n.map&&n.map.delete(n.key)}function pD(e){const{prevDep:t,nextDep:n}=e;t&&(t.nextDep=n,e.prevDep=void 0),n&&(n.prevDep=t,e.nextDep=void 0)}let Rs=!0;const pC=[];function Vo(){pC.push(Rs),Rs=!1}function Uo(){const e=pC.pop();Rs=e===void 0?!0:e}function Gw(e){const{cleanup:t}=e;if(e.cleanup=void 0,t){const n=jt;jt=void 0;try{t()}finally{jt=n}}}let Bc=0;class mD{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 Ob{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(!jt||!Rs||jt===this.computed)return;let n=this.activeLink;if(n===void 0||n.sub!==jt)n=this.activeLink=new mD(jt,this),jt.deps?(n.prevDep=jt.depsTail,jt.depsTail.nextDep=n,jt.depsTail=n):jt.deps=jt.depsTail=n,mC(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=jt.depsTail,n.nextDep=void 0,jt.depsTail.nextDep=n,jt.depsTail=n,jt.deps===n&&(jt.deps=r)}return n}trigger(t){this.version++,Bc++,this.notify(t)}notify(t){Rb();try{for(let n=this.subs;n;n=n.prevSub)n.sub.notify()&&n.sub.dep.notify()}finally{Ib()}}}function mC(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)mC(r)}const n=e.dep.subs;n!==e&&(e.prevSub=n,n&&(n.nextSub=e)),e.dep.subs=e}}const kh=new WeakMap,Ea=Symbol(""),wv=Symbol(""),Vc=Symbol("");function Yn(e,t,n){if(Rs&&jt){let r=kh.get(e);r||kh.set(e,r=new Map);let s=r.get(n);s||(r.set(n,s=new Ob),s.map=r,s.key=n),s.track()}}function Oi(e,t,n,r,s,i){const o=kh.get(e);if(!o){Bc++;return}const a=l=>{l&&l.trigger()};if(Rb(),t==="clear")o.forEach(a);else{const l=We(e),u=l&&Pb(n);if(l&&n==="length"){const c=Number(r);o.forEach((d,f)=>{(f==="length"||f===Vc||!Gi(f)&&f>=c)&&a(d)})}else switch((n!==void 0||o.has(void 0))&&a(o.get(n)),u&&a(o.get(Vc)),t){case"add":l?u&&a(o.get("length")):(a(o.get(Ea)),Ll(e)&&a(o.get(wv)));break;case"delete":l||(a(o.get(Ea)),Ll(e)&&a(o.get(wv)));break;case"set":Ll(e)&&a(o.get(Ea));break}}Ib()}function gD(e,t){const n=kh.get(e);return n&&n.get(t)}function al(e){const t=Be(e);return t===e?t:(Yn(t,"iterate",Vc),os(e)?t:t.map(Xn))}function Ap(e){return Yn(e=Be(e),"iterate",Vc),e}const vD={__proto__:null,[Symbol.iterator](){return Ym(this,Symbol.iterator,Xn)},concat(...e){return al(this).concat(...e.map(t=>We(t)?al(t):t))},entries(){return Ym(this,"entries",e=>(e[1]=Xn(e[1]),e))},every(e,t){return gi(this,"every",e,t,void 0,arguments)},filter(e,t){return gi(this,"filter",e,t,n=>n.map(Xn),arguments)},find(e,t){return gi(this,"find",e,t,Xn,arguments)},findIndex(e,t){return gi(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return gi(this,"findLast",e,t,Xn,arguments)},findLastIndex(e,t){return gi(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return gi(this,"forEach",e,t,void 0,arguments)},includes(...e){return Xm(this,"includes",e)},indexOf(...e){return Xm(this,"indexOf",e)},join(e){return al(this).join(e)},lastIndexOf(...e){return Xm(this,"lastIndexOf",e)},map(e,t){return gi(this,"map",e,t,void 0,arguments)},pop(){return Yu(this,"pop")},push(...e){return Yu(this,"push",e)},reduce(e,...t){return Kw(this,"reduce",e,t)},reduceRight(e,...t){return Kw(this,"reduceRight",e,t)},shift(){return Yu(this,"shift")},some(e,t){return gi(this,"some",e,t,void 0,arguments)},splice(...e){return Yu(this,"splice",e)},toReversed(){return al(this).toReversed()},toSorted(e){return al(this).toSorted(e)},toSpliced(...e){return al(this).toSpliced(...e)},unshift(...e){return Yu(this,"unshift",e)},values(){return Ym(this,"values",Xn)}};function Ym(e,t,n){const r=Ap(e),s=r[t]();return r!==e&&!os(e)&&(s._next=s.next,s.next=()=>{const i=s._next();return i.value&&(i.value=n(i.value)),i}),s}const yD=Array.prototype;function gi(e,t,n,r,s,i){const o=Ap(e),a=o!==e&&!os(e),l=o[t];if(l!==yD[t]){const d=l.apply(e,i);return a?Xn(d):d}let u=n;o!==e&&(a?u=function(d,f){return n.call(this,Xn(d),f,e)}:n.length>2&&(u=function(d,f){return n.call(this,d,f,e)}));const c=l.call(o,u,r);return a&&s?s(c):c}function Kw(e,t,n,r){const s=Ap(e);let i=n;return s!==e&&(os(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,Xn(a),l,e)}),s[t](i,...r)}function Xm(e,t,n){const r=Be(e);Yn(r,"iterate",Vc);const s=r[t](...n);return(s===-1||s===!1)&&wd(n[0])?(n[0]=Be(n[0]),r[t](...n)):s}function Yu(e,t,n=[]){Vo(),Rb();const r=Be(e)[t].apply(e,n);return Ib(),Uo(),r}const bD=Eb("__proto__,__v_isRef,__isVue"),gC=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(Gi));function wD(e){Gi(e)||(e=String(e));const t=Be(this);return Yn(t,"has",e),t.hasOwnProperty(e)}class vC{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?kC:_C:i?SC:wC).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(r)?t:void 0;const o=We(t);if(!s){let l;if(o&&(l=vD[n]))return l;if(n==="hasOwnProperty")return wD}const a=Reflect.get(t,n,et(t)?t:r);return(Gi(n)?gC.has(n):bD(n))||(s||Yn(t,"get",n),i)?a:et(a)?o&&Pb(n)?a:a.value:Yt(a)?s?zo(a):cn(a):a}}class yC extends vC{constructor(t=!1){super(!1,t)}set(t,n,r,s){let i=t[n];if(!this._isShallow){const l=Fa(i);if(!os(r)&&!Fa(r)&&(i=Be(i),r=Be(r)),!We(t)&&et(i)&&!et(r))return l?!1:(i.value=r,!0)}const o=We(t)&&Pb(n)?Number(n)<t.length:Tt(t,n),a=Reflect.set(t,n,r,et(t)?t:s);return t===Be(s)&&(o?xo(r,i)&&Oi(t,"set",n,r):Oi(t,"add",n,r)),a}deleteProperty(t,n){const r=Tt(t,n);t[n];const s=Reflect.deleteProperty(t,n);return s&&r&&Oi(t,"delete",n,void 0),s}has(t,n){const r=Reflect.has(t,n);return(!Gi(n)||!gC.has(n))&&Yn(t,"has",n),r}ownKeys(t){return Yn(t,"iterate",We(t)?"length":Ea),Reflect.ownKeys(t)}}class bC extends vC{constructor(t=!1){super(!0,t)}set(t,n){return!0}deleteProperty(t,n){return!0}}const SD=new yC,_D=new bC,kD=new yC(!0),xD=new bC(!0),Sv=e=>e,Xd=e=>Reflect.getPrototypeOf(e);function ED(e,t,n){return function(...r){const s=this.__v_raw,i=Be(s),o=Ll(i),a=e==="entries"||e===Symbol.iterator&&o,l=e==="keys"&&o,u=s[e](...r),c=n?Sv:t?_v:Xn;return!t&&Yn(i,"iterate",l?wv:Ea),{next(){const{value:d,done:f}=u.next();return f?{value:d,done:f}:{value:a?[c(d[0]),c(d[1])]:c(d),done:f}},[Symbol.iterator](){return this}}}}function Qd(e){return function(...t){return e==="delete"?!1:e==="clear"?void 0:this}}function CD(e,t){const n={get(s){const i=this.__v_raw,o=Be(i),a=Be(s);e||(xo(s,a)&&Yn(o,"get",s),Yn(o,"get",a));const{has:l}=Xd(o),u=t?Sv:e?_v:Xn;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&&Yn(Be(s),"iterate",Ea),Reflect.get(s,"size",s)},has(s){const i=this.__v_raw,o=Be(i),a=Be(s);return e||(xo(s,a)&&Yn(o,"has",s),Yn(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?Sv:e?_v:Xn;return!e&&Yn(l,"iterate",Ea),a.forEach((c,d)=>s.call(i,u(c),u(d),o))}};return vn(n,e?{add:Qd("add"),set:Qd("set"),delete:Qd("delete"),clear:Qd("clear")}:{add(s){!t&&!os(s)&&!Fa(s)&&(s=Be(s));const i=Be(this);return Xd(i).has.call(i,s)||(i.add(s),Oi(i,"add",s,s)),this},set(s,i){!t&&!os(i)&&!Fa(i)&&(i=Be(i));const o=Be(this),{has:a,get:l}=Xd(o);let u=a.call(o,s);u||(s=Be(s),u=a.call(o,s));const c=l.call(o,s);return o.set(s,i),u?xo(i,c)&&Oi(o,"set",s,i):Oi(o,"add",s,i),this},delete(s){const i=Be(this),{has:o,get:a}=Xd(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&&Oi(i,"delete",s,void 0),u},clear(){const s=Be(this),i=s.size!==0,o=s.clear();return i&&Oi(s,"clear",void 0,void 0),o}}),["keys","values","entries",Symbol.iterator].forEach(s=>{n[s]=ED(s,e,t)}),n}function Op(e,t){const n=CD(e,t);return(r,s,i)=>s==="__v_isReactive"?!e:s==="__v_isReadonly"?e:s==="__v_raw"?r:Reflect.get(Tt(n,s)&&s in r?n:r,s,i)}const TD={get:Op(!1,!1)},PD={get:Op(!1,!0)},RD={get:Op(!0,!1)},ID={get:Op(!0,!0)},wC=new WeakMap,SC=new WeakMap,_C=new WeakMap,kC=new WeakMap;function AD(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function OD(e){return e.__v_skip||!Object.isExtensible(e)?0:AD(sD(e))}function cn(e){return Fa(e)?e:Dp(e,!1,SD,TD,wC)}function Mp(e){return Dp(e,!1,kD,PD,SC)}function zo(e){return Dp(e,!0,_D,RD,_C)}function Mb(e){return Dp(e,!0,xD,ID,kC)}function Dp(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=OD(e);if(o===0)return e;const a=new Proxy(e,o===2?r:n);return s.set(e,a),a}function Eo(e){return Fa(e)?Eo(e.__v_raw):!!(e&&e.__v_isReactive)}function Fa(e){return!!(e&&e.__v_isReadonly)}function os(e){return!!(e&&e.__v_isShallow)}function wd(e){return e?!!e.__v_raw:!1}function Be(e){const t=e&&e.__v_raw;return t?Be(t):e}function Lp(e){return!Tt(e,"__v_skip")&&Object.isExtensible(e)&&rC(e,"__v_skip",!0),e}const Xn=e=>Yt(e)?cn(e):e,_v=e=>Yt(e)?zo(e):e;function et(e){return e?e.__v_isRef===!0:!1}function j(e){return xC(e,!1)}function Ie(e){return xC(e,!0)}function xC(e,t){return et(e)?e:new MD(e,t)}class MD{constructor(t,n){this.dep=new Ob,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=n?t:Be(t),this._value=n?t:Xn(t),this.__v_isShallow=n}get value(){return this.dep.track(),this._value}set value(t){const n=this._rawValue,r=this.__v_isShallow||os(t)||Fa(t);t=r?t:Be(t),xo(t,n)&&(this._rawValue=t,this._value=r?t:Xn(t),this.dep.trigger())}}function Q(e){return et(e)?e.value:e}function Nn(e){return Xe(e)?e():Q(e)}const DD={get:(e,t,n)=>t==="__v_raw"?e:Q(Reflect.get(e,t,n)),set:(e,t,n,r)=>{const s=e[t];return et(s)&&!et(n)?(s.value=n,!0):Reflect.set(e,t,n,r)}};function EC(e){return Eo(e)?e:new Proxy(e,DD)}function Qa(e){const t=We(e)?new Array(e.length):{};for(const n in e)t[n]=CC(e,n);return t}class LD{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 gD(Be(this._object),this._key)}}class $D{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 ae(e,t,n){return et(e)?e:Xe(e)?new $D(e):Yt(e)&&arguments.length>1?CC(e,t,n):j(e)}function CC(e,t,n){const r=e[t];return et(r)?r:new LD(e,t,n)}class FD{constructor(t,n,r){this.fn=t,this.setter=n,this._value=void 0,this.dep=new Ob(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=Bc-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!n,this.isSSR=r}notify(){if(this.flags|=16,!(this.flags&8)&&jt!==this)return cC(this,!0),!0}get value(){const t=this.dep.track();return hC(this),t&&(t.version=this.dep.version),this._value}set value(t){this.setter&&this.setter(t)}}function ND(e,t,n=!1){let r,s;return Xe(e)?r=e:(r=e.get,s=e.set),new FD(r,s,n)}const Jd={},xh=new WeakMap;let ia;function BD(e,t=!1,n=ia){if(n){let r=xh.get(n);r||xh.set(n,r=[]),r.push(e)}}function VD(e,t,n=$t){const{immediate:r,deep:s,once:i,scheduler:o,augmentJob:a,call:l}=n,u=C=>s?C:os(C)||s===!1||s===0?Mi(C,1):Mi(C);let c,d,f,p,g=!1,m=!1;if(et(e)?(d=()=>e.value,g=os(e)):Eo(e)?(d=()=>u(e),g=!0):We(e)?(m=!0,g=e.some(C=>Eo(C)||os(C)),d=()=>e.map(C=>{if(et(C))return C.value;if(Eo(C))return u(C);if(Xe(C))return l?l(C,2):C()})):Xe(e)?t?d=l?()=>l(e,2):e:d=()=>{if(f){Vo();try{f()}finally{Uo()}}const C=ia;ia=c;try{return l?l(e,3,[p]):e(p)}finally{ia=C}}:d=oi,t&&s){const C=d,_=s===!0?1/0:s;d=()=>Mi(C(),_)}const y=Ip(),w=()=>{c.stop(),y&&y.active&&Tb(y.effects,c)};if(i&&t){const C=t;t=(..._)=>{C(..._),w()}}let b=m?new Array(e.length).fill(Jd):Jd;const k=C=>{if(!(!(c.flags&1)||!c.dirty&&!C))if(t){const _=c.run();if(s||g||(m?_.some((T,P)=>xo(T,b[P])):xo(_,b))){f&&f();const T=ia;ia=c;try{const P=[_,b===Jd?void 0:m&&b[0]===Jd?[]:b,p];l?l(t,3,P):t(...P),b=_}finally{ia=T}}}else c.run()};return a&&a(k),c=new lC(d),c.scheduler=o?()=>o(k,!1):k,p=C=>BD(C,!1,c),f=c.onStop=()=>{const C=xh.get(c);if(C){if(l)l(C,4);else for(const _ of C)_();xh.delete(c)}},t?r?k(!0):b=c.run():o?o(k.bind(null,!0),!0):c.run(),w.pause=c.pause.bind(c),w.resume=c.resume.bind(c),w.stop=w,w}function Mi(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--,et(e))Mi(e.value,t,n);else if(We(e))for(let r=0;r<e.length;r++)Mi(e[r],t,n);else if(ZE(e)||Ll(e))e.forEach(r=>{Mi(r,t,n)});else if(nC(e)){for(const r in e)Mi(e[r],t,n);for(const r of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,r)&&Mi(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 Sd(e,t,n,r){try{return r?e(...r):e()}catch(s){$p(s,t,n)}}function Is(e,t,n,r){if(Xe(e)){const s=Sd(e,t,n,r);return s&&eC(s)&&s.catch(i=>{$p(i,t,n)}),s}if(We(e)){const s=[];for(let i=0;i<e.length;i++)s.push(Is(e[i],t,n,r));return s}}function $p(e,t,n,r=!0){const s=t?t.vnode:null,{errorHandler:i,throwUnhandledErrorInProduction:o}=t&&t.appContext.config||$t;if(t){let a=t.parent;const l=t.proxy,u=`https://vuejs.org/error-reference/#runtime-${n}`;for(;a;){const c=a.ec;if(c){for(let d=0;d<c.length;d++)if(c[d](e,l,u)===!1)return}a=a.parent}if(i){Vo(),Sd(i,null,10,[e,l,u]),Uo();return}}UD(e,n,s,r,o)}function UD(e,t,n,r=!0,s=!1){if(s)throw e;console.error(e)}const cr=[];let Xs=-1;const $l=[];let so=null,bl=0;const TC=Promise.resolve();let Eh=null;function Mt(e){const t=Eh||TC;return e?t.then(this?e.bind(this):e):t}function zD(e){let t=Xs+1,n=cr.length;for(;t<n;){const r=t+n>>>1,s=cr[r],i=Uc(s);i<e||i===e&&s.flags&2?t=r+1:n=r}return t}function Db(e){if(!(e.flags&1)){const t=Uc(e),n=cr[cr.length-1];!n||!(e.flags&2)&&t>=Uc(n)?cr.push(e):cr.splice(zD(t),0,e),e.flags|=1,PC()}}function PC(){Eh||(Eh=TC.then(IC))}function HD(e){We(e)?$l.push(...e):so&&e.id===-1?so.splice(bl+1,0,e):e.flags&1||($l.push(e),e.flags|=1),PC()}function Yw(e,t,n=Xs+1){for(;n<cr.length;n++){const r=cr[n];if(r&&r.flags&2){if(e&&r.id!==e.uid)continue;cr.splice(n,1),n--,r.flags&4&&(r.flags&=-2),r(),r.flags&4||(r.flags&=-2)}}}function RC(e){if($l.length){const t=[...new Set($l)].sort((n,r)=>Uc(n)-Uc(r));if($l.length=0,so){so.push(...t);return}for(so=t,bl=0;bl<so.length;bl++){const n=so[bl];n.flags&4&&(n.flags&=-2),n.flags&8||n(),n.flags&=-2}so=null,bl=0}}const Uc=e=>e.id==null?e.flags&2?-1:1/0:e.id;function IC(e){try{for(Xs=0;Xs<cr.length;Xs++){const t=cr[Xs];t&&!(t.flags&8)&&(t.flags&4&&(t.flags&=-2),Sd(t,t.i,t.i?15:14),t.flags&4||(t.flags&=-2))}}finally{for(;Xs<cr.length;Xs++){const t=cr[Xs];t&&(t.flags&=-2)}Xs=-1,cr.length=0,RC(),Eh=null,(cr.length||$l.length)&&IC()}}let xn=null,AC=null;function Ch(e){const t=xn;return xn=e,AC=e&&e.type.__scopeId||null,t}function v(e,t=xn,n){if(!t||e._n)return e;const r=(...s)=>{r._d&&lS(-1);const i=Ch(t);let o;try{o=e(...s)}finally{Ch(i),r._d&&lS(1)}return o};return r._n=!0,r._c=!0,r._d=!0,r}function Bt(e,t){if(xn===null)return e;const n=Hp(xn),r=e.dirs||(e.dirs=[]);for(let s=0;s<t.length;s++){let[i,o,a,l=$t]=t[s];i&&(Xe(i)&&(i={mounted:i,updated:i}),i.deep&&Mi(o),r.push({dir:i,instance:n,value:o,oldValue:void 0,arg:a,modifiers:l}))}return e}function Xo(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&&(Vo(),Is(l,n,8,[e.el,a,e,t]),Uo())}}const OC=Symbol("_vte"),MC=e=>e.__isTeleport,Sc=e=>e&&(e.disabled||e.disabled===""),Xw=e=>e&&(e.defer||e.defer===""),Qw=e=>typeof SVGElement<"u"&&e instanceof SVGElement,Jw=e=>typeof MathMLElement=="function"&&e instanceof MathMLElement,kv=(e,t)=>{const n=e&&e.to;return rn(n)?t?t(n):null:n},DC={name:"Teleport",__isTeleport:!0,process(e,t,n,r,s,i,o,a,l,u){const{mc:c,pc:d,pbc:f,o:{insert:p,querySelector:g,createText:m,createComment:y}}=u,w=Sc(t.props);let{shapeFlag:b,children:k,dynamicChildren:C}=t;if(e==null){const _=t.el=m(""),T=t.anchor=m("");p(_,n,r),p(T,n,r);const P=(E,I)=>{b&16&&(s&&s.isCE&&(s.ce._teleportTarget=E),c(k,E,I,s,i,o,a,l))},S=()=>{const E=t.target=kv(t.props,g),I=LC(E,t,m,p);E&&(o!=="svg"&&Qw(E)?o="svg":o!=="mathml"&&Jw(E)&&(o="mathml"),w||(P(E,I),qf(t,!1)))};w&&(P(n,T),qf(t,!0)),Xw(t.props)?lr(()=>{S(),t.el.__isMounted=!0},i):S()}else{if(Xw(t.props)&&!e.el.__isMounted){lr(()=>{DC.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 _=t.anchor=e.anchor,T=t.target=e.target,P=t.targetAnchor=e.targetAnchor,S=Sc(e.props),E=S?n:T,I=S?_:P;if(o==="svg"||Qw(T)?o="svg":(o==="mathml"||Jw(T))&&(o="mathml"),C?(f(e.dynamicChildren,C,E,s,i,o,a),zb(e,t,!0)):l||d(e,t,E,I,s,i,o,a,!1),w)S?t.props&&e.props&&t.props.to!==e.props.to&&(t.props.to=e.props.to):Zd(t,n,_,u,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){const O=t.target=kv(t.props,g);O&&Zd(t,O,null,u,0)}else S&&Zd(t,T,P,u,1);qf(t,w)}},remove(e,t,n,{um:r,o:{remove:s}},i){const{shapeFlag:o,children:a,anchor:l,targetStart:u,targetAnchor:c,target:d,props:f}=e;if(d&&(s(u),s(c)),i&&s(l),o&16){const p=i||!Sc(f);for(let g=0;g<a.length;g++){const m=a[g];r(m,t,n,p,!!m.dynamicChildren)}}},move:Zd,hydrate:jD};function Zd(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:c}=e,d=i===2;if(d&&r(o,t,n),(!d||Sc(c))&&l&16)for(let f=0;f<u.length;f++)s(u[f],t,n,2);d&&r(a,t,n)}function jD(e,t,n,r,s,i,{o:{nextSibling:o,parentNode:a,querySelector:l,insert:u,createText:c}},d){const f=t.target=kv(t.props,l);if(f){const p=Sc(t.props),g=f._lpa||f.firstChild;if(t.shapeFlag&16)if(p)t.anchor=d(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||LC(f,t,c,u),d(g&&o(g),t,f,n,r,s,i)}qf(t,p)}return t.anchor&&o(t.anchor)}const qD=DC;function qf(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 LC(e,t,n,r){const s=t.targetStart=n(""),i=t.targetAnchor=n("");return s[OC]=i,e&&(r(s,e),r(i,e)),i}const io=Symbol("_leaveCb"),ef=Symbol("_enterCb");function $C(){const e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return St(()=>{e.isMounted=!0}),Cn(()=>{e.isUnmounting=!0}),e}const Xr=[Function,Array],FC={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:Xr,onEnter:Xr,onAfterEnter:Xr,onEnterCancelled:Xr,onBeforeLeave:Xr,onLeave:Xr,onAfterLeave:Xr,onLeaveCancelled:Xr,onBeforeAppear:Xr,onAppear:Xr,onAfterAppear:Xr,onAppearCancelled:Xr},NC=e=>{const t=e.subTree;return t.component?NC(t.component):t},WD={name:"BaseTransition",props:FC,setup(e,{slots:t}){const n=zp(),r=$C();return()=>{const s=t.default&&Lb(t.default(),!0);if(!s||!s.length)return;const i=BC(s),o=Be(e),{mode:a}=o;if(r.isLeaving)return Qm(i);const l=Zw(i);if(!l)return Qm(i);let u=zc(l,o,r,n,d=>u=d);l.type!==Qn&&Na(l,u);let c=n.subTree&&Zw(n.subTree);if(c&&c.type!==Qn&&!ua(l,c)&&NC(n).type!==Qn){let d=zc(c,o,r,n);if(Na(c,d),a==="out-in"&&l.type!==Qn)return r.isLeaving=!0,d.afterLeave=()=>{r.isLeaving=!1,n.job.flags&8||n.update(),delete d.afterLeave,c=void 0},Qm(i);a==="in-out"&&l.type!==Qn?d.delayLeave=(f,p,g)=>{const m=VC(r,c);m[String(c.key)]=c,f[io]=()=>{p(),f[io]=void 0,delete u.delayedLeave,c=void 0},u.delayedLeave=()=>{g(),delete u.delayedLeave,c=void 0}}:c=void 0}else c&&(c=void 0);return i}}};function BC(e){let t=e[0];if(e.length>1){for(const n of e)if(n.type!==Qn){t=n;break}}return t}const GD=WD;function VC(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 zc(e,t,n,r,s){const{appear:i,mode:o,persisted:a=!1,onBeforeEnter:l,onEnter:u,onAfterEnter:c,onEnterCancelled:d,onBeforeLeave:f,onLeave:p,onAfterLeave:g,onLeaveCancelled:m,onBeforeAppear:y,onAppear:w,onAfterAppear:b,onAppearCancelled:k}=t,C=String(e.key),_=VC(n,e),T=(E,I)=>{E&&Is(E,r,9,I)},P=(E,I)=>{const O=I[1];T(E,I),We(E)?E.every(R=>R.length<=1)&&O():E.length<=1&&O()},S={mode:o,persisted:a,beforeEnter(E){let I=l;if(!n.isMounted)if(i)I=y||l;else return;E[io]&&E[io](!0);const O=_[C];O&&ua(e,O)&&O.el[io]&&O.el[io](),T(I,[E])},enter(E){let I=u,O=c,R=d;if(!n.isMounted)if(i)I=w||u,O=b||c,R=k||d;else return;let M=!1;const D=E[ef]=F=>{M||(M=!0,F?T(R,[E]):T(O,[E]),S.delayedLeave&&S.delayedLeave(),E[ef]=void 0)};I?P(I,[E,D]):D()},leave(E,I){const O=String(e.key);if(E[ef]&&E[ef](!0),n.isUnmounting)return I();T(f,[E]);let R=!1;const M=E[io]=D=>{R||(R=!0,I(),D?T(m,[E]):T(g,[E]),E[io]=void 0,_[O]===e&&delete _[O])};_[O]=e,p?P(p,[E,M]):M()},clone(E){const I=zc(E,t,n,r,s);return s&&s(I),I}};return S}function Qm(e){if(Fp(e))return e=Ni(e),e.children=null,e}function Zw(e){if(!Fp(e))return MC(e.type)&&e.children?BC(e.children):e;const{shapeFlag:t,children:n}=e;if(n){if(t&16)return n[0];if(t&32&&Xe(n.default))return n.default()}}function Na(e,t){e.shapeFlag&6&&e.component?(e.transition=t,Na(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 Lb(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===Ae?(o.patchFlag&128&&s++,r=r.concat(Lb(o.children,t,a))):(t||o.type!==Qn)&&r.push(a!=null?Ni(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 Xe(e)?vn({name:e.name},t,{setup:e}):e}function ms(){const e=zp();return e?(e.appContext.config.idPrefix||"v")+"-"+e.ids[0]+e.ids[1]++:""}function UC(e){e.ids=[e.ids[0]+e.ids[2]+++"-",0,0]}function Th(e,t,n,r,s=!1){if(We(e)){e.forEach((g,m)=>Th(g,t&&(We(t)?t[m]:t),n,r,s));return}if(Fl(r)&&!s){r.shapeFlag&512&&r.type.__asyncResolved&&r.component.subTree.component&&Th(e,t,n,r.component.subTree);return}const i=r.shapeFlag&4?Hp(r.component):r.el,o=s?null:i,{i:a,r:l}=e,u=t&&t.r,c=a.refs===$t?a.refs={}:a.refs,d=a.setupState,f=Be(d),p=d===$t?()=>!1:g=>Tt(f,g);if(u!=null&&u!==l&&(rn(u)?(c[u]=null,p(u)&&(d[u]=null)):et(u)&&(u.value=null)),Xe(l))Sd(l,a,12,[o,c]);else{const g=rn(l),m=et(l);if(g||m){const y=()=>{if(e.f){const w=g?p(l)?d[l]:c[l]:l.value;s?We(w)&&Tb(w,i):We(w)?w.includes(i)||w.push(i):g?(c[l]=[i],p(l)&&(d[l]=c[l])):(l.value=[i],e.k&&(c[e.k]=l.value))}else g?(c[l]=o,p(l)&&(d[l]=o)):m&&(l.value=o,e.k&&(c[e.k]=o))};o?(y.id=-1,lr(y,n)):y()}}}Rp().requestIdleCallback;Rp().cancelIdleCallback;const Fl=e=>!!e.type.__asyncLoader,Fp=e=>e.type.__isKeepAlive;function zC(e,t){HC(e,"a",t)}function $b(e,t){HC(e,"da",t)}function HC(e,t,n=Rn){const r=e.__wdc||(e.__wdc=()=>{let s=n;for(;s;){if(s.isDeactivated)return;s=s.parent}return e()});if(Np(t,r,n),n){let s=n.parent;for(;s&&s.parent;)Fp(s.parent.vnode)&&KD(r,t,n,s),s=s.parent}}function KD(e,t,n,r){const s=Np(t,e,r,!0);Bp(()=>{Tb(r[t],s)},n)}function Np(e,t,n=Rn,r=!1){if(n){const s=n[e]||(n[e]=[]),i=t.__weh||(t.__weh=(...o)=>{Vo();const a=kd(n),l=Is(t,n,e,o);return a(),Uo(),l});return r?s.unshift(i):s.push(i),i}}const Ki=e=>(t,n=Rn)=>{(!jc||e==="sp")&&Np(e,(...r)=>t(...r),n)},Su=Ki("bm"),St=Ki("m"),jC=Ki("bu"),Fb=Ki("u"),Cn=Ki("bum"),Bp=Ki("um"),YD=Ki("sp"),XD=Ki("rtg"),QD=Ki("rtc");function JD(e,t=Rn){Np("ec",e,t)}const Nb="components",ZD="directives";function In(e,t){return Bb(Nb,e,!0,t)||e}const eL=Symbol.for("v-ndc");function tL(e){return rn(e)&&Bb(Nb,e,!1)||e}function hr(e){return Bb(ZD,e)}function Bb(e,t,n=!0,r=!1){const s=xn||Rn;if(s){const i=s.type;if(e===Nb){const a=BL(i,!1);if(a&&(a===t||a===Rr(t)||a===ci(Rr(t))))return i}const o=eS(s[e]||i[e],t)||eS(s.appContext[e],t);return!o&&r?i:o}}function eS(e,t){return e&&(e[t]||e[Rr(t)]||e[ci(Rr(t))])}function Gt(e,t,n,r){let s;const i=n,o=We(e);if(o||rn(e)){const a=o&&Eo(e);let l=!1;a&&(l=!os(e),e=Ap(e)),s=new Array(e.length);for(let u=0,c=e.length;u<c;u++)s[u]=t(l?Xn(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 c=a[l];s[l]=t(e[c],c,l,i)}}else s=[];return s}function qC(e,t){for(let n=0;n<t.length;n++){const r=t[n];if(We(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 Vp(e,t,n={},r,s){if(xn.ce||xn.parent&&Fl(xn.parent)&&xn.parent.ce)return $(),te(Ae,null,[h("slot",n,r&&r())],64);let i=e[t];i&&i._c&&(i._d=!1),$();const o=i&&WC(i(n)),a=n.key||o&&o.key,l=te(Ae,{key:(a&&!Gi(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 WC(e){return e.some(t=>tu(t)?!(t.type===Qn||t.type===Ae&&!WC(t.children)):!0)?e:null}const xv=e=>e?dT(e)?Hp(e):xv(e.parent):null,_c=vn(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=>xv(e.parent),$root:e=>xv(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>Vb(e),$forceUpdate:e=>e.f||(e.f=()=>{Db(e.update)}),$nextTick:e=>e.n||(e.n=Mt.bind(e.proxy)),$watch:e=>_L.bind(e)}),Jm=(e,t)=>e!==$t&&!e.__isScriptSetup&&Tt(e,t),nL={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(Jm(r,t))return o[t]=1,r[t];if(s!==$t&&Tt(s,t))return o[t]=2,s[t];if((u=e.propsOptions[0])&&Tt(u,t))return o[t]=3,i[t];if(n!==$t&&Tt(n,t))return o[t]=4,n[t];Ev&&(o[t]=0)}}const c=_c[t];let d,f;if(c)return t==="$attrs"&&Yn(e.attrs,"get",""),c(e);if((d=a.__cssModules)&&(d=d[t]))return d;if(n!==$t&&Tt(n,t))return o[t]=4,n[t];if(f=l.config.globalProperties,Tt(f,t))return f[t]},set({_:e},t,n){const{data:r,setupState:s,ctx:i}=e;return Jm(s,t)?(s[t]=n,!0):r!==$t&&Tt(r,t)?(r[t]=n,!0):Tt(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!==$t&&Tt(e,o)||Jm(t,o)||(a=i[0])&&Tt(a,o)||Tt(r,o)||Tt(_c,o)||Tt(s.config.globalProperties,o)},defineProperty(e,t,n){return n.get!=null?e._.accessCache[t]=0:Tt(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}};function tS(e){return We(e)?e.reduce((t,n)=>(t[n]=null,t),{}):e}let Ev=!0;function rL(e){const t=Vb(e),n=e.proxy,r=e.ctx;Ev=!1,t.beforeCreate&&nS(t.beforeCreate,e,"bc");const{data:s,computed:i,methods:o,watch:a,provide:l,inject:u,created:c,beforeMount:d,mounted:f,beforeUpdate:p,updated:g,activated:m,deactivated:y,beforeDestroy:w,beforeUnmount:b,destroyed:k,unmounted:C,render:_,renderTracked:T,renderTriggered:P,errorCaptured:S,serverPrefetch:E,expose:I,inheritAttrs:O,components:R,directives:M,filters:D}=t;if(u&&sL(u,r,null),o)for(const K in o){const X=o[K];Xe(X)&&(r[K]=X.bind(n))}if(s){const K=s.call(n,n);Yt(K)&&(e.data=cn(K))}if(Ev=!0,i)for(const K in i){const X=i[K],H=Xe(X)?X.bind(n,n):Xe(X.get)?X.get.bind(n,n):oi,B=!Xe(X)&&Xe(X.set)?X.set.bind(n):oi,ee=A({get:H,set:B});Object.defineProperty(r,K,{enumerable:!0,configurable:!0,get:()=>ee.value,set:q=>ee.value=q})}if(a)for(const K in a)GC(a[K],r,n,K);if(l){const K=Xe(l)?l.call(n):l;Reflect.ownKeys(K).forEach(X=>{Kt(X,K[X])})}c&&nS(c,e,"c");function U(K,X){We(X)?X.forEach(H=>K(H.bind(n))):X&&K(X.bind(n))}if(U(Su,d),U(St,f),U(jC,p),U(Fb,g),U(zC,m),U($b,y),U(JD,S),U(QD,T),U(XD,P),U(Cn,b),U(Bp,C),U(YD,E),We(I))if(I.length){const K=e.exposed||(e.exposed={});I.forEach(X=>{Object.defineProperty(K,X,{get:()=>n[X],set:H=>n[X]=H})})}else e.exposed||(e.exposed={});_&&e.render===oi&&(e.render=_),O!=null&&(e.inheritAttrs=O),R&&(e.components=R),M&&(e.directives=M),E&&UC(e)}function sL(e,t,n=oi){We(e)&&(e=Cv(e));for(const r in e){const s=e[r];let i;Yt(s)?"default"in s?i=Qe(s.from||r,s.default,!0):i=Qe(s.from||r):i=Qe(s),et(i)?Object.defineProperty(t,r,{enumerable:!0,configurable:!0,get:()=>i.value,set:o=>i.value=o}):t[r]=i}}function nS(e,t,n){Is(We(e)?e.map(r=>r.bind(t.proxy)):e.bind(t.proxy),t,n)}function GC(e,t,n,r){let s=r.includes(".")?oT(n,r):()=>n[r];if(rn(e)){const i=t[e];Xe(i)&&Ee(s,i)}else if(Xe(e))Ee(s,e.bind(n));else if(Yt(e))if(We(e))e.forEach(i=>GC(i,t,n,r));else{const i=Xe(e.handler)?e.handler.bind(n):t[e.handler];Xe(i)&&Ee(s,i,e)}}function Vb(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=>Ph(l,u,o,!0)),Ph(l,t,o)),Yt(t)&&i.set(t,l),l}function Ph(e,t,n,r=!1){const{mixins:s,extends:i}=t;i&&Ph(e,i,n,!0),s&&s.forEach(o=>Ph(e,o,n,!0));for(const o in t)if(!(r&&o==="expose")){const a=iL[o]||n&&n[o];e[o]=a?a(e[o],t[o]):t[o]}return e}const iL={data:rS,props:sS,emits:sS,methods:dc,computed:dc,beforeCreate:sr,created:sr,beforeMount:sr,mounted:sr,beforeUpdate:sr,updated:sr,beforeDestroy:sr,beforeUnmount:sr,destroyed:sr,unmounted:sr,activated:sr,deactivated:sr,errorCaptured:sr,serverPrefetch:sr,components:dc,directives:dc,watch:aL,provide:rS,inject:oL};function rS(e,t){return t?e?function(){return vn(Xe(e)?e.call(this,this):e,Xe(t)?t.call(this,this):t)}:t:e}function oL(e,t){return dc(Cv(e),Cv(t))}function Cv(e){if(We(e)){const t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function sr(e,t){return e?[...new Set([].concat(e,t))]:t}function dc(e,t){return e?vn(Object.create(null),e,t):t}function sS(e,t){return e?We(e)&&We(t)?[...new Set([...e,...t])]:vn(Object.create(null),tS(e),tS(t??{})):t}function aL(e,t){if(!e)return t;if(!t)return e;const n=vn(Object.create(null),e);for(const r in t)n[r]=sr(e[r],t[r]);return n}function KC(){return{app:null,config:{isNativeTag:nD,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 lL=0;function uL(e,t){return function(r,s=null){Xe(r)||(r=vn({},r)),s!=null&&!Yt(s)&&(s=null);const i=KC(),o=new WeakSet,a=[];let l=!1;const u=i.app={_uid:lL++,_component:r,_props:s,_container:null,_context:i,_instance:null,version:hT,get config(){return i.config},set config(c){},use(c,...d){return o.has(c)||(c&&Xe(c.install)?(o.add(c),c.install(u,...d)):Xe(c)&&(o.add(c),c(u,...d))),u},mixin(c){return i.mixins.includes(c)||i.mixins.push(c),u},component(c,d){return d?(i.components[c]=d,u):i.components[c]},directive(c,d){return d?(i.directives[c]=d,u):i.directives[c]},mount(c,d,f){if(!l){const p=u._ceVNode||h(r,s);return p.appContext=i,f===!0?f="svg":f===!1&&(f=void 0),d&&t?t(p,c):e(p,c,f),l=!0,u._container=c,c.__vue_app__=u,Hp(p.component)}},onUnmount(c){a.push(c)},unmount(){l&&(Is(a,u._instance,16),e(null,u._container),delete u._container.__vue_app__)},provide(c,d){return i.provides[c]=d,u},runWithContext(c){const d=Ca;Ca=u;try{return c()}finally{Ca=d}}};return u}}let Ca=null;function Kt(e,t){if(Rn){let n=Rn.provides;const r=Rn.parent&&Rn.parent.provides;r===n&&(n=Rn.provides=Object.create(r)),n[e]=t}}function Qe(e,t,n=!1){const r=Rn||xn;if(r||Ca){const s=Ca?Ca._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&&Xe(t)?t.call(r&&r.proxy):t}}function YC(){return!!(Rn||xn||Ca)}const XC={},QC=()=>Object.create(XC),JC=e=>Object.getPrototypeOf(e)===XC;function cL(e,t,n,r=!1){const s={},i=QC();e.propsDefaults=Object.create(null),ZC(e,t,s,i);for(const o in e.propsOptions[0])o in s||(s[o]=void 0);n?e.props=r?s:Mp(s):e.type.props?e.props=s:e.props=i,e.attrs=i}function dL(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 c=e.vnode.dynamicProps;for(let d=0;d<c.length;d++){let f=c[d];if(Up(e.emitsOptions,f))continue;const p=t[f];if(l)if(Tt(i,f))p!==i[f]&&(i[f]=p,u=!0);else{const g=Rr(f);s[g]=Tv(l,a,g,p,e,!1)}else p!==i[f]&&(i[f]=p,u=!0)}}}else{ZC(e,t,s,i)&&(u=!0);let c;for(const d in a)(!t||!Tt(t,d)&&((c=No(d))===d||!Tt(t,c)))&&(l?n&&(n[d]!==void 0||n[c]!==void 0)&&(s[d]=Tv(l,a,d,void 0,e,!0)):delete s[d]);if(i!==a)for(const d in i)(!t||!Tt(t,d))&&(delete i[d],u=!0)}u&&Oi(e.attrs,"set","")}function ZC(e,t,n,r){const[s,i]=e.propsOptions;let o=!1,a;if(t)for(let l in t){if(yc(l))continue;const u=t[l];let c;s&&Tt(s,c=Rr(l))?!i||!i.includes(c)?n[c]=u:(a||(a={}))[c]=u:Up(e.emitsOptions,l)||(!(l in r)||u!==r[l])&&(r[l]=u,o=!0)}if(i){const l=Be(n),u=a||$t;for(let c=0;c<i.length;c++){const d=i[c];n[d]=Tv(s,l,d,u[d],e,!Tt(u,d))}}return o}function Tv(e,t,n,r,s,i){const o=e[n];if(o!=null){const a=Tt(o,"default");if(a&&r===void 0){const l=o.default;if(o.type!==Function&&!o.skipFactory&&Xe(l)){const{propsDefaults:u}=s;if(n in u)r=u[n];else{const c=kd(s);r=u[n]=l.call(null,t),c()}}else r=l;s.ce&&s.ce._setProp(n,r)}o[0]&&(i&&!a?r=!1:o[1]&&(r===""||r===No(n))&&(r=!0))}return r}const fL=new WeakMap;function eT(e,t,n=!1){const r=n?fL:t.propsCache,s=r.get(e);if(s)return s;const i=e.props,o={},a=[];let l=!1;if(!Xe(e)){const c=d=>{l=!0;const[f,p]=eT(d,t,!0);vn(o,f),p&&a.push(...p)};!n&&t.mixins.length&&t.mixins.forEach(c),e.extends&&c(e.extends),e.mixins&&e.mixins.forEach(c)}if(!i&&!l)return Yt(e)&&r.set(e,Dl),Dl;if(We(i))for(let c=0;c<i.length;c++){const d=Rr(i[c]);iS(d)&&(o[d]=$t)}else if(i)for(const c in i){const d=Rr(c);if(iS(d)){const f=i[c],p=o[d]=We(f)||Xe(f)?{type:f}:vn({},f),g=p.type;let m=!1,y=!0;if(We(g))for(let w=0;w<g.length;++w){const b=g[w],k=Xe(b)&&b.name;if(k==="Boolean"){m=!0;break}else k==="String"&&(y=!1)}else m=Xe(g)&&g.name==="Boolean";p[0]=m,p[1]=y,(m||Tt(p,"default"))&&a.push(d)}}const u=[o,a];return Yt(e)&&r.set(e,u),u}function iS(e){return e[0]!=="$"&&!yc(e)}const tT=e=>e[0]==="_"||e==="$stable",Ub=e=>We(e)?e.map(ti):[ti(e)],hL=(e,t,n)=>{if(t._n)return t;const r=v((...s)=>Ub(t(...s)),n);return r._c=!1,r},nT=(e,t,n)=>{const r=e._ctx;for(const s in e){if(tT(s))continue;const i=e[s];if(Xe(i))t[s]=hL(s,i,r);else if(i!=null){const o=Ub(i);t[s]=()=>o}}},rT=(e,t)=>{const n=Ub(t);e.slots.default=()=>n},sT=(e,t,n)=>{for(const r in t)(n||r!=="_")&&(e[r]=t[r])},pL=(e,t,n)=>{const r=e.slots=QC();if(e.vnode.shapeFlag&32){const s=t._;s?(sT(r,t,n),n&&rC(r,"_",s,!0)):nT(t,r)}else t&&rT(e,t)},mL=(e,t,n)=>{const{vnode:r,slots:s}=e;let i=!0,o=$t;if(r.shapeFlag&32){const a=t._;a?n&&a===1?i=!1:sT(s,t,n):(i=!t.$stable,nT(t,s)),o=t}else t&&(rT(e,t),o={default:1});if(i)for(const a in s)!tT(a)&&o[a]==null&&delete s[a]},lr=RL;function gL(e){return vL(e)}function vL(e,t){const n=Rp();n.__VUE__=!0;const{insert:r,remove:s,patchProp:i,createElement:o,createText:a,createComment:l,setText:u,setElementText:c,parentNode:d,nextSibling:f,setScopeId:p=oi,insertStaticContent:g}=e,m=(N,V,Y,fe=null,ce=null,be=null,Re=void 0,ye=null,_e=!!V.dynamicChildren)=>{if(N===V)return;N&&!ua(N,V)&&(fe=Z(N),q(N,ce,be,!0),N=null),V.patchFlag===-2&&(_e=!1,V.dynamicChildren=null);const{type:me,ref:$e,shapeFlag:Te}=V;switch(me){case _d:y(N,V,Y,fe);break;case Qn:w(N,V,Y,fe);break;case tg:N==null&&b(V,Y,fe,Re);break;case Ae:R(N,V,Y,fe,ce,be,Re,ye,_e);break;default:Te&1?_(N,V,Y,fe,ce,be,Re,ye,_e):Te&6?M(N,V,Y,fe,ce,be,Re,ye,_e):(Te&64||Te&128)&&me.process(N,V,Y,fe,ce,be,Re,ye,_e,z)}$e!=null&&ce&&Th($e,N&&N.ref,be,V||N,!V)},y=(N,V,Y,fe)=>{if(N==null)r(V.el=a(V.children),Y,fe);else{const ce=V.el=N.el;V.children!==N.children&&u(ce,V.children)}},w=(N,V,Y,fe)=>{N==null?r(V.el=l(V.children||""),Y,fe):V.el=N.el},b=(N,V,Y,fe)=>{[N.el,N.anchor]=g(N.children,V,Y,fe,N.el,N.anchor)},k=({el:N,anchor:V},Y,fe)=>{let ce;for(;N&&N!==V;)ce=f(N),r(N,Y,fe),N=ce;r(V,Y,fe)},C=({el:N,anchor:V})=>{let Y;for(;N&&N!==V;)Y=f(N),s(N),N=Y;s(V)},_=(N,V,Y,fe,ce,be,Re,ye,_e)=>{V.type==="svg"?Re="svg":V.type==="math"&&(Re="mathml"),N==null?T(V,Y,fe,ce,be,Re,ye,_e):E(N,V,ce,be,Re,ye,_e)},T=(N,V,Y,fe,ce,be,Re,ye)=>{let _e,me;const{props:$e,shapeFlag:Te,transition:Ce,dirs:Ge}=N;if(_e=N.el=o(N.type,be,$e&&$e.is,$e),Te&8?c(_e,N.children):Te&16&&S(N.children,_e,null,fe,ce,Zm(N,be),Re,ye),Ge&&Xo(N,null,fe,"created"),P(_e,N,N.scopeId,Re,fe),$e){for(const zt in $e)zt!=="value"&&!yc(zt)&&i(_e,zt,null,$e[zt],be,fe);"value"in $e&&i(_e,"value",null,$e.value,be),(me=$e.onVnodeBeforeMount)&&zs(me,fe,N)}Ge&&Xo(N,null,fe,"beforeMount");const mt=yL(ce,Ce);mt&&Ce.beforeEnter(_e),r(_e,V,Y),((me=$e&&$e.onVnodeMounted)||mt||Ge)&&lr(()=>{me&&zs(me,fe,N),mt&&Ce.enter(_e),Ge&&Xo(N,null,fe,"mounted")},ce)},P=(N,V,Y,fe,ce)=>{if(Y&&p(N,Y),fe)for(let be=0;be<fe.length;be++)p(N,fe[be]);if(ce){let be=ce.subTree;if(V===be||lT(be.type)&&(be.ssContent===V||be.ssFallback===V)){const Re=ce.vnode;P(N,Re,Re.scopeId,Re.slotScopeIds,ce.parent)}}},S=(N,V,Y,fe,ce,be,Re,ye,_e=0)=>{for(let me=_e;me<N.length;me++){const $e=N[me]=ye?oo(N[me]):ti(N[me]);m(null,$e,V,Y,fe,ce,be,Re,ye)}},E=(N,V,Y,fe,ce,be,Re)=>{const ye=V.el=N.el;let{patchFlag:_e,dynamicChildren:me,dirs:$e}=V;_e|=N.patchFlag&16;const Te=N.props||$t,Ce=V.props||$t;let Ge;if(Y&&Qo(Y,!1),(Ge=Ce.onVnodeBeforeUpdate)&&zs(Ge,Y,V,N),$e&&Xo(V,N,Y,"beforeUpdate"),Y&&Qo(Y,!0),(Te.innerHTML&&Ce.innerHTML==null||Te.textContent&&Ce.textContent==null)&&c(ye,""),me?I(N.dynamicChildren,me,ye,Y,fe,Zm(V,ce),be):Re||X(N,V,ye,null,Y,fe,Zm(V,ce),be,!1),_e>0){if(_e&16)O(ye,Te,Ce,Y,ce);else if(_e&2&&Te.class!==Ce.class&&i(ye,"class",null,Ce.class,ce),_e&4&&i(ye,"style",Te.style,Ce.style,ce),_e&8){const mt=V.dynamicProps;for(let zt=0;zt<mt.length;zt++){const Rt=mt[zt],Lr=Te[Rt],jn=Ce[Rt];(jn!==Lr||Rt==="value")&&i(ye,Rt,Lr,jn,ce,Y)}}_e&1&&N.children!==V.children&&c(ye,V.children)}else!Re&&me==null&&O(ye,Te,Ce,Y,ce);((Ge=Ce.onVnodeUpdated)||$e)&&lr(()=>{Ge&&zs(Ge,Y,V,N),$e&&Xo(V,N,Y,"updated")},fe)},I=(N,V,Y,fe,ce,be,Re)=>{for(let ye=0;ye<V.length;ye++){const _e=N[ye],me=V[ye],$e=_e.el&&(_e.type===Ae||!ua(_e,me)||_e.shapeFlag&70)?d(_e.el):Y;m(_e,me,$e,null,fe,ce,be,Re,!0)}},O=(N,V,Y,fe,ce)=>{if(V!==Y){if(V!==$t)for(const be in V)!yc(be)&&!(be in Y)&&i(N,be,V[be],null,ce,fe);for(const be in Y){if(yc(be))continue;const Re=Y[be],ye=V[be];Re!==ye&&be!=="value"&&i(N,be,ye,Re,ce,fe)}"value"in Y&&i(N,"value",V.value,Y.value,ce)}},R=(N,V,Y,fe,ce,be,Re,ye,_e)=>{const me=V.el=N?N.el:a(""),$e=V.anchor=N?N.anchor:a("");let{patchFlag:Te,dynamicChildren:Ce,slotScopeIds:Ge}=V;Ge&&(ye=ye?ye.concat(Ge):Ge),N==null?(r(me,Y,fe),r($e,Y,fe),S(V.children||[],Y,$e,ce,be,Re,ye,_e)):Te>0&&Te&64&&Ce&&N.dynamicChildren?(I(N.dynamicChildren,Ce,Y,ce,be,Re,ye),(V.key!=null||ce&&V===ce.subTree)&&zb(N,V,!0)):X(N,V,Y,$e,ce,be,Re,ye,_e)},M=(N,V,Y,fe,ce,be,Re,ye,_e)=>{V.slotScopeIds=ye,N==null?V.shapeFlag&512?ce.ctx.activate(V,Y,fe,Re,_e):D(V,Y,fe,ce,be,Re,_e):F(N,V,_e)},D=(N,V,Y,fe,ce,be,Re)=>{const ye=N.component=DL(N,fe,ce);if(Fp(N)&&(ye.ctx.renderer=z),LL(ye,!1,Re),ye.asyncDep){if(ce&&ce.registerDep(ye,U,Re),!N.el){const _e=ye.subTree=h(Qn);w(null,_e,V,Y)}}else U(ye,N,V,Y,ce,be,Re)},F=(N,V,Y)=>{const fe=V.component=N.component;if(TL(N,V,Y))if(fe.asyncDep&&!fe.asyncResolved){K(fe,V,Y);return}else fe.next=V,fe.update();else V.el=N.el,fe.vnode=V},U=(N,V,Y,fe,ce,be,Re)=>{const ye=()=>{if(N.isMounted){let{next:Te,bu:Ce,u:Ge,parent:mt,vnode:zt}=N;{const $r=iT(N);if($r){Te&&(Te.el=zt.el,K(N,Te,Re)),$r.asyncDep.then(()=>{N.isUnmounted||ye()});return}}let Rt=Te,Lr;Qo(N,!1),Te?(Te.el=zt.el,K(N,Te,Re)):Te=zt,Ce&&jf(Ce),(Lr=Te.props&&Te.props.onVnodeBeforeUpdate)&&zs(Lr,mt,Te,zt),Qo(N,!0);const jn=eg(N),ws=N.subTree;N.subTree=jn,m(ws,jn,d(ws.el),Z(ws),N,ce,be),Te.el=jn.el,Rt===null&&PL(N,jn.el),Ge&&lr(Ge,ce),(Lr=Te.props&&Te.props.onVnodeUpdated)&&lr(()=>zs(Lr,mt,Te,zt),ce)}else{let Te;const{el:Ce,props:Ge}=V,{bm:mt,m:zt,parent:Rt,root:Lr,type:jn}=N,ws=Fl(V);if(Qo(N,!1),mt&&jf(mt),!ws&&(Te=Ge&&Ge.onVnodeBeforeMount)&&zs(Te,Rt,V),Qo(N,!0),Ce&&Fe){const $r=()=>{N.subTree=eg(N),Fe(Ce,N.subTree,N,ce,null)};ws&&jn.__asyncHydrate?jn.__asyncHydrate(Ce,N,$r):$r()}else{Lr.ce&&Lr.ce._injectChildStyle(jn);const $r=N.subTree=eg(N);m(null,$r,Y,fe,N,ce,be),V.el=$r.el}if(zt&&lr(zt,ce),!ws&&(Te=Ge&&Ge.onVnodeMounted)){const $r=V;lr(()=>zs(Te,Rt,$r),ce)}(V.shapeFlag&256||Rt&&Fl(Rt.vnode)&&Rt.vnode.shapeFlag&256)&&N.a&&lr(N.a,ce),N.isMounted=!0,V=Y=fe=null}};N.scope.on();const _e=N.effect=new lC(ye);N.scope.off();const me=N.update=_e.run.bind(_e),$e=N.job=_e.runIfDirty.bind(_e);$e.i=N,$e.id=N.uid,_e.scheduler=()=>Db($e),Qo(N,!0),me()},K=(N,V,Y)=>{V.component=N;const fe=N.vnode.props;N.vnode=V,N.next=null,dL(N,V.props,fe,Y),mL(N,V.children,Y),Vo(),Yw(N),Uo()},X=(N,V,Y,fe,ce,be,Re,ye,_e=!1)=>{const me=N&&N.children,$e=N?N.shapeFlag:0,Te=V.children,{patchFlag:Ce,shapeFlag:Ge}=V;if(Ce>0){if(Ce&128){B(me,Te,Y,fe,ce,be,Re,ye,_e);return}else if(Ce&256){H(me,Te,Y,fe,ce,be,Re,ye,_e);return}}Ge&8?($e&16&&Se(me,ce,be),Te!==me&&c(Y,Te)):$e&16?Ge&16?B(me,Te,Y,fe,ce,be,Re,ye,_e):Se(me,ce,be,!0):($e&8&&c(Y,""),Ge&16&&S(Te,Y,fe,ce,be,Re,ye,_e))},H=(N,V,Y,fe,ce,be,Re,ye,_e)=>{N=N||Dl,V=V||Dl;const me=N.length,$e=V.length,Te=Math.min(me,$e);let Ce;for(Ce=0;Ce<Te;Ce++){const Ge=V[Ce]=_e?oo(V[Ce]):ti(V[Ce]);m(N[Ce],Ge,Y,null,ce,be,Re,ye,_e)}me>$e?Se(N,ce,be,!0,!1,Te):S(V,Y,fe,ce,be,Re,ye,_e,Te)},B=(N,V,Y,fe,ce,be,Re,ye,_e)=>{let me=0;const $e=V.length;let Te=N.length-1,Ce=$e-1;for(;me<=Te&&me<=Ce;){const Ge=N[me],mt=V[me]=_e?oo(V[me]):ti(V[me]);if(ua(Ge,mt))m(Ge,mt,Y,null,ce,be,Re,ye,_e);else break;me++}for(;me<=Te&&me<=Ce;){const Ge=N[Te],mt=V[Ce]=_e?oo(V[Ce]):ti(V[Ce]);if(ua(Ge,mt))m(Ge,mt,Y,null,ce,be,Re,ye,_e);else break;Te--,Ce--}if(me>Te){if(me<=Ce){const Ge=Ce+1,mt=Ge<$e?V[Ge].el:fe;for(;me<=Ce;)m(null,V[me]=_e?oo(V[me]):ti(V[me]),Y,mt,ce,be,Re,ye,_e),me++}}else if(me>Ce)for(;me<=Te;)q(N[me],ce,be,!0),me++;else{const Ge=me,mt=me,zt=new Map;for(me=mt;me<=Ce;me++){const Fr=V[me]=_e?oo(V[me]):ti(V[me]);Fr.key!=null&&zt.set(Fr.key,me)}let Rt,Lr=0;const jn=Ce-mt+1;let ws=!1,$r=0;const Ku=new Array(jn);for(me=0;me<jn;me++)Ku[me]=0;for(me=Ge;me<=Te;me++){const Fr=N[me];if(Lr>=jn){q(Fr,ce,be,!0);continue}let Us;if(Fr.key!=null)Us=zt.get(Fr.key);else for(Rt=mt;Rt<=Ce;Rt++)if(Ku[Rt-mt]===0&&ua(Fr,V[Rt])){Us=Rt;break}Us===void 0?q(Fr,ce,be,!0):(Ku[Us-mt]=me+1,Us>=$r?$r=Us:ws=!0,m(Fr,V[Us],Y,null,ce,be,Re,ye,_e),Lr++)}const Hw=ws?bL(Ku):Dl;for(Rt=Hw.length-1,me=jn-1;me>=0;me--){const Fr=mt+me,Us=V[Fr],jw=Fr+1<$e?V[Fr+1].el:fe;Ku[me]===0?m(null,Us,Y,jw,ce,be,Re,ye,_e):ws&&(Rt<0||me!==Hw[Rt]?ee(Us,Y,jw,2):Rt--)}}},ee=(N,V,Y,fe,ce=null)=>{const{el:be,type:Re,transition:ye,children:_e,shapeFlag:me}=N;if(me&6){ee(N.component.subTree,V,Y,fe);return}if(me&128){N.suspense.move(V,Y,fe);return}if(me&64){Re.move(N,V,Y,z);return}if(Re===Ae){r(be,V,Y);for(let Te=0;Te<_e.length;Te++)ee(_e[Te],V,Y,fe);r(N.anchor,V,Y);return}if(Re===tg){k(N,V,Y);return}if(fe!==2&&me&1&&ye)if(fe===0)ye.beforeEnter(be),r(be,V,Y),lr(()=>ye.enter(be),ce);else{const{leave:Te,delayLeave:Ce,afterLeave:Ge}=ye,mt=()=>r(be,V,Y),zt=()=>{Te(be,()=>{mt(),Ge&&Ge()})};Ce?Ce(be,mt,zt):zt()}else r(be,V,Y)},q=(N,V,Y,fe=!1,ce=!1)=>{const{type:be,props:Re,ref:ye,children:_e,dynamicChildren:me,shapeFlag:$e,patchFlag:Te,dirs:Ce,cacheIndex:Ge}=N;if(Te===-2&&(ce=!1),ye!=null&&Th(ye,null,Y,N,!0),Ge!=null&&(V.renderCache[Ge]=void 0),$e&256){V.ctx.deactivate(N);return}const mt=$e&1&&Ce,zt=!Fl(N);let Rt;if(zt&&(Rt=Re&&Re.onVnodeBeforeUnmount)&&zs(Rt,V,N),$e&6)ie(N.component,Y,fe);else{if($e&128){N.suspense.unmount(Y,fe);return}mt&&Xo(N,null,V,"beforeUnmount"),$e&64?N.type.remove(N,V,Y,z,fe):me&&!me.hasOnce&&(be!==Ae||Te>0&&Te&64)?Se(me,V,Y,!1,!0):(be===Ae&&Te&384||!ce&&$e&16)&&Se(_e,V,Y),fe&&G(N)}(zt&&(Rt=Re&&Re.onVnodeUnmounted)||mt)&&lr(()=>{Rt&&zs(Rt,V,N),mt&&Xo(N,null,V,"unmounted")},Y)},G=N=>{const{type:V,el:Y,anchor:fe,transition:ce}=N;if(V===Ae){le(Y,fe);return}if(V===tg){C(N);return}const be=()=>{s(Y),ce&&!ce.persisted&&ce.afterLeave&&ce.afterLeave()};if(N.shapeFlag&1&&ce&&!ce.persisted){const{leave:Re,delayLeave:ye}=ce,_e=()=>Re(Y,be);ye?ye(N.el,be,_e):_e()}else be()},le=(N,V)=>{let Y;for(;N!==V;)Y=f(N),s(N),N=Y;s(V)},ie=(N,V,Y)=>{const{bum:fe,scope:ce,job:be,subTree:Re,um:ye,m:_e,a:me}=N;oS(_e),oS(me),fe&&jf(fe),ce.stop(),be&&(be.flags|=8,q(Re,N,V,Y)),ye&&lr(ye,V),lr(()=>{N.isUnmounted=!0},V),V&&V.pendingBranch&&!V.isUnmounted&&N.asyncDep&&!N.asyncResolved&&N.suspenseId===V.pendingId&&(V.deps--,V.deps===0&&V.resolve())},Se=(N,V,Y,fe=!1,ce=!1,be=0)=>{for(let Re=be;Re<N.length;Re++)q(N[Re],V,Y,fe,ce)},Z=N=>{if(N.shapeFlag&6)return Z(N.component.subTree);if(N.shapeFlag&128)return N.suspense.next();const V=f(N.anchor||N.el),Y=V&&V[OC];return Y?f(Y):V};let he=!1;const ne=(N,V,Y)=>{N==null?V._vnode&&q(V._vnode,null,null,!0):m(V._vnode||null,N,V,null,null,null,Y),V._vnode=N,he||(he=!0,Yw(),RC(),he=!1)},z={p:m,um:q,m:ee,r:G,mt:D,mc:S,pc:X,pbc:I,n:Z,o:e};let xe,Fe;return{render:ne,hydrate:xe,createApp:uL(ne,xe)}}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 Qo({effect:e,job:t},n){n?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function yL(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function zb(e,t,n=!1){const r=e.children,s=t.children;if(We(r)&&We(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&&zb(o,a)),a.type===_d&&(a.el=o.el)}}function bL(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 iT(e){const t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:iT(t)}function oS(e){if(e)for(let t=0;t<e.length;t++)e[t].flags|=8}const wL=Symbol.for("v-scx"),SL=()=>Qe(wL);function On(e,t){return Hb(e,null,t)}function Ee(e,t,n){return Hb(e,t,n)}function Hb(e,t,n=$t){const{immediate:r,deep:s,flush:i,once:o}=n,a=vn({},n),l=t&&r||!t&&i!=="post";let u;if(jc){if(i==="sync"){const p=SL();u=p.__watcherHandles||(p.__watcherHandles=[])}else if(!l){const p=()=>{};return p.stop=oi,p.resume=oi,p.pause=oi,p}}const c=Rn;a.call=(p,g,m)=>Is(p,c,g,m);let d=!1;i==="post"?a.scheduler=p=>{lr(p,c&&c.suspense)}:i!=="sync"&&(d=!0,a.scheduler=(p,g)=>{g?p():Db(p)}),a.augmentJob=p=>{t&&(p.flags|=4),d&&(p.flags|=2,c&&(p.id=c.uid,p.i=c))};const f=VD(e,t,a);return jc&&(u?u.push(f):l&&f()),f}function _L(e,t,n){const r=this.proxy,s=rn(e)?e.includes(".")?oT(r,e):()=>r[e]:e.bind(r,r);let i;Xe(t)?i=t:(i=t.handler,n=t);const o=kd(this),a=Hb(s,i.bind(r),n);return o(),a}function oT(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 kL=(e,t)=>t==="modelValue"||t==="model-value"?e.modelModifiers:e[`${t}Modifiers`]||e[`${Rr(t)}Modifiers`]||e[`${No(t)}Modifiers`];function xL(e,t,...n){if(e.isUnmounted)return;const r=e.vnode.props||$t;let s=n;const i=t.startsWith("update:"),o=i&&kL(r,t.slice(7));o&&(o.trim&&(s=n.map(c=>rn(c)?c.trim():c)),o.number&&(s=n.map(vv)));let a,l=r[a=Wm(t)]||r[a=Wm(Rr(t))];!l&&i&&(l=r[a=Wm(No(t))]),l&&Is(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,Is(u,e,6,s)}}function aT(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(!Xe(e)){const l=u=>{const c=aT(u,t,!0);c&&(a=!0,vn(o,c))};!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):(We(i)?i.forEach(l=>o[l]=null):vn(o,i),Yt(e)&&r.set(e,o),o)}function Up(e,t){return!e||!Cp(t)?!1:(t=t.slice(2).replace(/Once$/,""),Tt(e,t[0].toLowerCase()+t.slice(1))||Tt(e,No(t))||Tt(e,t))}function eg(e){const{type:t,vnode:n,proxy:r,withProxy:s,propsOptions:[i],slots:o,attrs:a,emit:l,render:u,renderCache:c,props:d,data:f,setupState:p,ctx:g,inheritAttrs:m}=e,y=Ch(e);let w,b;try{if(n.shapeFlag&4){const C=s||r,_=C;w=ti(u.call(_,C,c,d,p,f,g)),b=a}else{const C=t;w=ti(C.length>1?C(d,{attrs:a,slots:o,emit:l}):C(d,null)),b=t.props?a:EL(a)}}catch(C){kc.length=0,$p(C,e,1),w=h(Qn)}let k=w;if(b&&m!==!1){const C=Object.keys(b),{shapeFlag:_}=k;C.length&&_&7&&(i&&C.some(Cb)&&(b=CL(b,i)),k=Ni(k,b,!1,!0))}return n.dirs&&(k=Ni(k,null,!1,!0),k.dirs=k.dirs?k.dirs.concat(n.dirs):n.dirs),n.transition&&Na(k,n.transition),w=k,Ch(y),w}const EL=e=>{let t;for(const n in e)(n==="class"||n==="style"||Cp(n))&&((t||(t={}))[n]=e[n]);return t},CL=(e,t)=>{const n={};for(const r in e)(!Cb(r)||!(r.slice(9)in t))&&(n[r]=e[r]);return n};function TL(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?aS(r,o,u):!!o;if(l&8){const c=t.dynamicProps;for(let d=0;d<c.length;d++){const f=c[d];if(o[f]!==r[f]&&!Up(u,f))return!0}}}else return(s||a)&&(!a||!a.$stable)?!0:r===o?!1:r?o?aS(r,o,u):!0:!!o;return!1}function aS(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]&&!Up(n,i))return!0}return!1}function PL({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 lT=e=>e.__isSuspense;function RL(e,t){t&&t.pendingBranch?We(e)?t.effects.push(...e):t.effects.push(e):HD(e)}const Ae=Symbol.for("v-fgt"),_d=Symbol.for("v-txt"),Qn=Symbol.for("v-cmt"),tg=Symbol.for("v-stc"),kc=[];let Ur=null;function $(e=!1){kc.push(Ur=e?null:[])}function IL(){kc.pop(),Ur=kc[kc.length-1]||null}let Hc=1;function lS(e,t=!1){Hc+=e,e<0&&Ur&&t&&(Ur.hasOnce=!0)}function uT(e){return e.dynamicChildren=Hc>0?Ur||Dl:null,IL(),Hc>0&&Ur&&Ur.push(e),e}function ve(e,t,n,r,s,i){return uT(L(e,t,n,r,s,i,!0))}function te(e,t,n,r,s){return uT(h(e,t,n,r,s,!0))}function tu(e){return e?e.__v_isVNode===!0:!1}function ua(e,t){return e.type===t.type&&e.key===t.key}const cT=({key:e})=>e??null,Wf=({ref:e,ref_key:t,ref_for:n})=>(typeof e=="number"&&(e=""+e),e!=null?rn(e)||et(e)||Xe(e)?{i:xn,r:e,k:t,f:!!n}:e:null);function L(e,t=null,n=null,r=0,s=null,i=e===Ae?0:1,o=!1,a=!1){const l={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&cT(t),ref:t&&Wf(t),scopeId:AC,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?(jb(l,n),i&128&&e.normalize(l)):n&&(l.shapeFlag|=rn(n)?8:16),Hc>0&&!o&&Ur&&(l.patchFlag>0||i&6)&&l.patchFlag!==32&&Ur.push(l),l}const h=AL;function AL(e,t=null,n=null,r=0,s=null,i=!1){if((!e||e===eL)&&(e=Qn),tu(e)){const a=Ni(e,t,!0);return n&&jb(a,n),Hc>0&&!i&&Ur&&(a.shapeFlag&6?Ur[Ur.indexOf(e)]=a:Ur.push(a)),a.patchFlag=-2,a}if(VL(e)&&(e=e.__vccOpts),t){t=Rh(t);let{class:a,style:l}=t;a&&!rn(a)&&(t.class=Bo(a)),Yt(l)&&(wd(l)&&!We(l)&&(l=vn({},l)),t.style=is(l))}const o=rn(e)?1:lT(e)?128:MC(e)?64:Yt(e)?4:Xe(e)?2:0;return L(e,t,n,r,s,o,i,!0)}function Rh(e){return e?wd(e)||JC(e)?vn({},e):e:null}function Ni(e,t,n=!1,r=!1){const{props:s,ref:i,patchFlag:o,children:a,transition:l}=e,u=t?ge(s||{},t):s,c={__v_isVNode:!0,__v_skip:!0,type:e.type,props:u,key:u&&cT(u),ref:t&&t.ref?n&&i?We(i)?i.concat(Wf(t)):[i,Wf(t)]:Wf(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!==Ae?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&&Ni(e.ssContent),ssFallback:e.ssFallback&&Ni(e.ssFallback),el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return l&&r&&Na(c,l.clone(c)),c}function x(e=" ",t=0){return h(_d,null,e,t)}function pe(e="",t=!1){return t?($(),te(Qn,null,e)):h(Qn,null,e)}function ti(e){return e==null||typeof e=="boolean"?h(Qn):We(e)?h(Ae,null,e.slice()):tu(e)?oo(e):h(_d,null,String(e))}function oo(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:Ni(e)}function jb(e,t){let n=0;const{shapeFlag:r}=e;if(t==null)t=null;else if(We(t))n=16;else if(typeof t=="object")if(r&65){const s=t.default;s&&(s._c&&(s._d=!1),jb(e,s()),s._c&&(s._d=!0));return}else{n=32;const s=t._;!s&&!JC(t)?t._ctx=xn:s===3&&xn&&(xn.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else Xe(t)?(t={default:t,_ctx:xn},n=32):(t=String(t),r&64?(n=16,t=[x(t)]):n=8);e.children=t,e.shapeFlag|=n}function ge(...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=Bo([t.class,r.class]));else if(s==="style")t.style=is([t.style,r.style]);else if(Cp(s)){const i=t[s],o=r[s];o&&i!==o&&!(We(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){Is(e,t,7,[n,r])}const OL=KC();let ML=0;function DL(e,t,n){const r=e.type,s=(t?t.appContext:e.appContext)||OL,i={uid:ML++,vnode:e,type:r,parent:t,appContext:s,root:null,next:null,subTree:null,effect:null,update:null,job:null,scope:new aC(!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:eT(r,s),emitsOptions:aT(r,s),emit:null,emitted:null,propsDefaults:$t,inheritAttrs:r.inheritAttrs,ctx:$t,data:$t,props:$t,attrs:$t,slots:$t,refs:$t,setupState:$t,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=xL.bind(null,i),e.ce&&e.ce(i),i}let Rn=null;const zp=()=>Rn||xn;let Ih,Pv;{const e=Rp(),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)}};Ih=t("__VUE_INSTANCE_SETTERS__",n=>Rn=n),Pv=t("__VUE_SSR_SETTERS__",n=>jc=n)}const kd=e=>{const t=Rn;return Ih(e),e.scope.on(),()=>{e.scope.off(),Ih(t)}},uS=()=>{Rn&&Rn.scope.off(),Ih(null)};function dT(e){return e.vnode.shapeFlag&4}let jc=!1;function LL(e,t=!1,n=!1){t&&Pv(t);const{props:r,children:s}=e.vnode,i=dT(e);cL(e,r,i,t),pL(e,s,n);const o=i?$L(e,t):void 0;return t&&Pv(!1),o}function $L(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,nL);const{setup:r}=n;if(r){Vo();const s=e.setupContext=r.length>1?NL(e):null,i=kd(e),o=Sd(r,e,0,[e.props,s]),a=eC(o);if(Uo(),i(),(a||e.sp)&&!Fl(e)&&UC(e),a){if(o.then(uS,uS),t)return o.then(l=>{cS(e,l,t)}).catch(l=>{$p(l,e,0)});e.asyncDep=o}else cS(e,o,t)}else fT(e,t)}function cS(e,t,n){Xe(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:Yt(t)&&(e.setupState=EC(t)),fT(e,n)}let dS;function fT(e,t,n){const r=e.type;if(!e.render){if(!t&&dS&&!r.render){const s=r.template||Vb(e).template;if(s){const{isCustomElement:i,compilerOptions:o}=e.appContext.config,{delimiters:a,compilerOptions:l}=r,u=vn(vn({isCustomElement:i,delimiters:a},o),l);r.render=dS(s,u)}}e.render=r.render||oi}{const s=kd(e);Vo();try{rL(e)}finally{Uo(),s()}}}const FL={get(e,t){return Yn(e,"get",""),e[t]}};function NL(e){const t=n=>{e.exposed=n||{}};return{attrs:new Proxy(e.attrs,FL),slots:e.slots,emit:e.emit,expose:t}}function Hp(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(EC(Lp(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in _c)return _c[n](e)},has(t,n){return n in t||n in _c}})):e.proxy}function BL(e,t=!0){return Xe(e)?e.displayName||e.name:e.name||t&&e.__name}function VL(e){return Xe(e)&&"__vccOpts"in e}const A=(e,t)=>ND(e,t,jc);function pr(e,t,n){const r=arguments.length;return r===2?Yt(t)&&!We(t)?tu(t)?h(e,null,[t]):h(e,t):h(e,null,t):(r>3?n=Array.prototype.slice.call(arguments,2):r===3&&tu(n)&&(n=[n]),h(e,t,n))}const hT="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 Rv;const fS=typeof window<"u"&&window.trustedTypes;if(fS)try{Rv=fS.createPolicy("vue",{createHTML:e=>e})}catch{}const pT=Rv?e=>Rv.createHTML(e):e=>e,UL="http://www.w3.org/2000/svg",zL="http://www.w3.org/1998/Math/MathML",Ci=typeof document<"u"?document:null,hS=Ci&&Ci.createElement("template"),HL={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(UL,e):t==="mathml"?Ci.createElementNS(zL,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{hS.innerHTML=pT(r==="svg"?`<svg>${e}</svg>`:r==="mathml"?`<math>${e}</math>`:e);const a=hS.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]}},Ji="transition",Xu="animation",nu=Symbol("_vtc"),mT={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},gT=vn({},FC,mT),jL=e=>(e.displayName="Transition",e.props=gT,e),Oo=jL((e,{slots:t})=>pr(GD,vT(e),t)),Jo=(e,t=[])=>{We(e)?e.forEach(n=>n(...t)):e&&e(...t)},pS=e=>e?We(e)?e.some(t=>t.length>1):e.length>1:!1;function vT(e){const t={};for(const R in e)R in mT||(t[R]=e[R]);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:c=a,leaveFromClass:d=`${n}-leave-from`,leaveActiveClass:f=`${n}-leave-active`,leaveToClass:p=`${n}-leave-to`}=e,g=qL(s),m=g&&g[0],y=g&&g[1],{onBeforeEnter:w,onEnter:b,onEnterCancelled:k,onLeave:C,onLeaveCancelled:_,onBeforeAppear:T=w,onAppear:P=b,onAppearCancelled:S=k}=t,E=(R,M,D,F)=>{R._enterCancelled=F,to(R,M?c:a),to(R,M?u:o),D&&D()},I=(R,M)=>{R._isLeaving=!1,to(R,d),to(R,p),to(R,f),M&&M()},O=R=>(M,D)=>{const F=R?P:b,U=()=>E(M,R,D);Jo(F,[M,U]),mS(()=>{to(M,R?l:i),Gs(M,R?c:a),pS(F)||gS(M,r,m,U)})};return vn(t,{onBeforeEnter(R){Jo(w,[R]),Gs(R,i),Gs(R,o)},onBeforeAppear(R){Jo(T,[R]),Gs(R,l),Gs(R,u)},onEnter:O(!1),onAppear:O(!0),onLeave(R,M){R._isLeaving=!0;const D=()=>I(R,M);Gs(R,d),R._enterCancelled?(Gs(R,f),Iv()):(Iv(),Gs(R,f)),mS(()=>{R._isLeaving&&(to(R,d),Gs(R,p),pS(C)||gS(R,r,y,D))}),Jo(C,[R,D])},onEnterCancelled(R){E(R,!1,void 0,!0),Jo(k,[R])},onAppearCancelled(R){E(R,!0,void 0,!0),Jo(S,[R])},onLeaveCancelled(R){I(R),Jo(_,[R])}})}function qL(e){if(e==null)return null;if(Yt(e))return[ng(e.enter),ng(e.leave)];{const t=ng(e);return[t,t]}}function ng(e){return aD(e)}function Gs(e,t){t.split(/\s+/).forEach(n=>n&&e.classList.add(n)),(e[nu]||(e[nu]=new Set)).add(t)}function to(e,t){t.split(/\s+/).forEach(r=>r&&e.classList.remove(r));const n=e[nu];n&&(n.delete(t),n.size||(e[nu]=void 0))}function mS(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}let WL=0;function gS(e,t,n,r){const s=e._endId=++WL,i=()=>{s===e._endId&&r()};if(n!=null)return setTimeout(i,n);const{type:o,timeout:a,propCount:l}=yT(e,t);if(!o)return r();const u=o+"end";let c=0;const d=()=>{e.removeEventListener(u,f),i()},f=p=>{p.target===e&&++c>=l&&d()};setTimeout(()=>{c<l&&d()},a+1),e.addEventListener(u,f)}function yT(e,t){const n=window.getComputedStyle(e),r=g=>(n[g]||"").split(", "),s=r(`${Ji}Delay`),i=r(`${Ji}Duration`),o=vS(s,i),a=r(`${Xu}Delay`),l=r(`${Xu}Duration`),u=vS(a,l);let c=null,d=0,f=0;t===Ji?o>0&&(c=Ji,d=o,f=i.length):t===Xu?u>0&&(c=Xu,d=u,f=l.length):(d=Math.max(o,u),c=d>0?o>u?Ji:Xu:null,f=c?c===Ji?i.length:l.length:0);const p=c===Ji&&/\b(transform|all)(,|$)/.test(r(`${Ji}Property`).toString());return{type:c,timeout:d,propCount:f,hasTransform:p}}function vS(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max(...t.map((n,r)=>yS(n)+yS(e[r])))}function yS(e){return e==="auto"?0:Number(e.slice(0,-1).replace(",","."))*1e3}function Iv(){return document.body.offsetHeight}function GL(e,t,n){const r=e[nu];r&&(t=(t?[t,...r]:[...r]).join(" ")),t==null?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}const Ah=Symbol("_vod"),bT=Symbol("_vsh"),Yi={beforeMount(e,{value:t},{transition:n}){e[Ah]=e.style.display==="none"?"":e.style.display,n&&t?n.beforeEnter(e):Qu(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),Qu(e,!0),r.enter(e)):r.leave(e,()=>{Qu(e,!1)}):Qu(e,t))},beforeUnmount(e,{value:t}){Qu(e,t)}};function Qu(e,t){e.style.display=t?e[Ah]:"none",e[bT]=!t}const KL=Symbol(""),YL=/(^|;)\s*display\s*:/;function XL(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&&Gf(r,a,"")}else for(const o in t)n[o]==null&&Gf(r,o,"");for(const o in n)o==="display"&&(i=!0),Gf(r,o,n[o])}else if(s){if(t!==n){const o=r[KL];o&&(n+=";"+o),r.cssText=n,i=YL.test(n)}}else t&&e.removeAttribute("style");Ah in e&&(e[Ah]=i?r.display:"",e[bT]&&(r.display="none"))}const bS=/\s*!important$/;function Gf(e,t,n){if(We(n))n.forEach(r=>Gf(e,t,r));else if(n==null&&(n=""),t.startsWith("--"))e.setProperty(t,n);else{const r=QL(e,t);bS.test(n)?e.setProperty(No(r),n.replace(bS,""),"important"):e[r]=n}}const wS=["Webkit","Moz","ms"],rg={};function QL(e,t){const n=rg[t];if(n)return n;let r=Rr(t);if(r!=="filter"&&r in e)return rg[t]=r;r=ci(r);for(let s=0;s<wS.length;s++){const i=wS[s]+r;if(i in e)return rg[t]=i}return t}const SS="http://www.w3.org/1999/xlink";function _S(e,t,n,r,s,i=hD(t)){r&&t.startsWith("xlink:")?n==null?e.removeAttributeNS(SS,t.slice(6,t.length)):e.setAttributeNS(SS,t,n):n==null||i&&!sC(n)?e.removeAttribute(t):e.setAttribute(t,i?"":Gi(n)?String(n):n)}function kS(e,t,n,r,s){if(t==="innerHTML"||t==="textContent"){n!=null&&(e[t]=t==="innerHTML"?pT(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=sC(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 wl(e,t,n,r){e.addEventListener(t,n,r)}function JL(e,t,n,r){e.removeEventListener(t,n,r)}const xS=Symbol("_vei");function ZL(e,t,n,r,s=null){const i=e[xS]||(e[xS]={}),o=i[t];if(r&&o)o.value=r;else{const[a,l]=e$(t);if(r){const u=i[t]=r$(r,s);wl(e,a,u,l)}else o&&(JL(e,a,o,l),i[t]=void 0)}}const ES=/(?:Once|Passive|Capture)$/;function e$(e){let t;if(ES.test(e)){t={};let r;for(;r=e.match(ES);)e=e.slice(0,e.length-r[0].length),t[r[0].toLowerCase()]=!0}return[e[2]===":"?e.slice(3):No(e.slice(2)),t]}let sg=0;const t$=Promise.resolve(),n$=()=>sg||(t$.then(()=>sg=0),sg=Date.now());function r$(e,t){const n=r=>{if(!r._vts)r._vts=Date.now();else if(r._vts<=n.attached)return;Is(s$(r,n.value),t,5,[r])};return n.value=e,n.attached=n$(),n}function s$(e,t){if(We(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 CS=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,i$=(e,t,n,r,s,i)=>{const o=s==="svg";t==="class"?GL(e,r,o):t==="style"?XL(e,n,r):Cp(t)?Cb(t)||ZL(e,t,n,r,i):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):o$(e,t,r,o))?(kS(e,t,r),!e.tagName.includes("-")&&(t==="value"||t==="checked"||t==="selected")&&_S(e,t,r,o,i,t!=="value")):e._isVueCE&&(/[A-Z]/.test(t)||!rn(r))?kS(e,Rr(t),r,i,t):(t==="true-value"?e._trueValue=r:t==="false-value"&&(e._falseValue=r),_S(e,t,r,o))};function o$(e,t,n,r){if(r)return!!(t==="innerHTML"||t==="textContent"||t in e&&CS(t)&&Xe(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 CS(t)&&rn(n)?!1:t in e}const wT=new WeakMap,ST=new WeakMap,Oh=Symbol("_moveCb"),TS=Symbol("_enterCb"),a$=e=>(delete e.props.mode,e),l$=a$({name:"TransitionGroup",props:vn({},gT,{tag:String,moveClass:String}),setup(e,{slots:t}){const n=zp(),r=$C();let s,i;return Fb(()=>{if(!s.length)return;const o=e.moveClass||`${e.name||"v"}-move`;if(!f$(s[0].el,n.vnode.el,o))return;s.forEach(u$),s.forEach(c$);const a=s.filter(d$);Iv(),a.forEach(l=>{const u=l.el,c=u.style;Gs(u,o),c.transform=c.webkitTransform=c.transitionDuration="";const d=u[Oh]=f=>{f&&f.target!==u||(!f||/transform$/.test(f.propertyName))&&(u.removeEventListener("transitionend",d),u[Oh]=null,to(u,o))};u.addEventListener("transitionend",d)})}),()=>{const o=Be(e),a=vT(o);let l=o.tag||Ae;if(s=[],i)for(let u=0;u<i.length;u++){const c=i[u];c.el&&c.el instanceof Element&&(s.push(c),Na(c,zc(c,a,r,n)),wT.set(c,c.el.getBoundingClientRect()))}i=t.default?Lb(t.default()):[];for(let u=0;u<i.length;u++){const c=i[u];c.key!=null&&Na(c,zc(c,a,r,n))}return h(l,null,i)}}}),qb=l$;function u$(e){const t=e.el;t[Oh]&&t[Oh](),t[TS]&&t[TS]()}function c$(e){ST.set(e,e.el.getBoundingClientRect())}function d$(e){const t=wT.get(e),n=ST.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 f$(e,t,n){const r=e.cloneNode(),s=e[nu];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}=yT(r);return i.removeChild(r),o}const PS=e=>{const t=e.props["onUpdate:modelValue"]||!1;return We(t)?n=>jf(t,n):t};function h$(e){e.target.composing=!0}function RS(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const ig=Symbol("_assign"),p$={created(e,{modifiers:{lazy:t,trim:n,number:r}},s){e[ig]=PS(s);const i=r||s.props&&s.props.type==="number";wl(e,t?"change":"input",o=>{if(o.target.composing)return;let a=e.value;n&&(a=a.trim()),i&&(a=vv(a)),e[ig](a)}),n&&wl(e,"change",()=>{e.value=e.value.trim()}),t||(wl(e,"compositionstart",h$),wl(e,"compositionend",RS),wl(e,"change",RS))},mounted(e,{value:t}){e.value=t??""},beforeUpdate(e,{value:t,oldValue:n,modifiers:{lazy:r,trim:s,number:i}},o){if(e[ig]=PS(o),e.composing)return;const a=(i||e.type==="number")&&!/^0\d/.test(e.value)?vv(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))}},m$=["ctrl","shift","alt","meta"],g$={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)=>m$.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=g$[t[o]];if(a&&a(s,t))return}return e(s,...i)})},v$={esc:"escape",space:" ",up:"arrow-up",left:"arrow-left",right:"arrow-right",down:"arrow-down",delete:"backspace"},Av=(e,t)=>{const n=e._withKeys||(e._withKeys={}),r=t.join(".");return n[r]||(n[r]=s=>{if(!("key"in s))return;const i=No(s.key);if(t.some(o=>o===i||v$[o]===i))return e(s)})},y$=vn({patchProp:i$},HL);let IS;function _T(){return IS||(IS=gL(y$))}const kT=(...e)=>{_T().render(...e)},b$=(...e)=>{const t=_T().createApp(...e),{mount:n}=t;return t.mount=r=>{const s=S$(r);if(!s)return;const i=t._component;!Xe(i)&&!i.render&&!i.template&&(i.template=s.innerHTML),s.nodeType===1&&(s.textContent="");const o=n(s,!1,w$(s));return s instanceof Element&&(s.removeAttribute("v-cloak"),s.setAttribute("data-v-app","")),o},t};function w$(e){if(e instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&e instanceof MathMLElement)return"mathml"}function S$(e){return rn(e)?document.querySelector(e):e}/*!
|
|
18
|
+
* pinia v3.0.2
|
|
19
|
+
* (c) 2025 Eduardo San Martin Morote
|
|
20
|
+
* @license MIT
|
|
21
|
+
*/let xT;const jp=e=>xT=e,ET=Symbol();function Ov(e){return e&&typeof e=="object"&&Object.prototype.toString.call(e)==="[object Object]"&&typeof e.toJSON!="function"}var xc;(function(e){e.direct="direct",e.patchObject="patch object",e.patchFunction="patch function"})(xc||(xc={}));function _$(){const e=$a(!0),t=e.run(()=>j({}));let n=[],r=[];const s=Lp({install(i){jp(s),s._a=i,i.provide(ET,s),i.config.globalProperties.$pinia=s,r.forEach(o=>n.push(o)),r=[]},use(i){return this._a?n.push(i):r.push(i),this},_p:n,_a:null,_e:e,_s:new Map,state:t});return s}const CT=()=>{};function AS(e,t,n,r=CT){e.push(t);const s=()=>{const i=e.indexOf(t);i>-1&&(e.splice(i,1),r())};return!n&&Ip()&&yn(s),s}function ll(e,...t){e.slice().forEach(n=>{n(...t)})}const k$=e=>e(),OS=Symbol(),og=Symbol();function Mv(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];Ov(s)&&Ov(r)&&e.hasOwnProperty(n)&&!et(r)&&!Eo(r)?e[n]=Mv(s,r):e[n]=r}return e}const x$=Symbol();function E$(e){return!Ov(e)||!Object.prototype.hasOwnProperty.call(e,x$)}const{assign:no}=Object;function C$(e){return!!(et(e)&&e.effect)}function T$(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 c=Qa(n.state.value[e]);return no(c,i,Object.keys(o||{}).reduce((d,f)=>(d[f]=Lp(A(()=>{jp(n);const p=n._s.get(e);return o[f].call(p,p)})),d),{}))}return l=TT(e,u,t,n,r,!0),l}function TT(e,t,n={},r,s,i){let o;const a=no({actions:{}},n),l={deep:!0};let u,c,d=[],f=[],p;const g=r.state.value[e];!i&&!g&&(r.state.value[e]={}),j({});let m;function y(S){let E;u=c=!1,typeof S=="function"?(S(r.state.value[e]),E={type:xc.patchFunction,storeId:e,events:p}):(Mv(r.state.value[e],S),E={type:xc.patchObject,payload:S,storeId:e,events:p});const I=m=Symbol();Mt().then(()=>{m===I&&(u=!0)}),c=!0,ll(d,E,r.state.value[e])}const w=i?function(){const{state:E}=n,I=E?E():{};this.$patch(O=>{no(O,I)})}:CT;function b(){o.stop(),d=[],f=[],r._s.delete(e)}const k=(S,E="")=>{if(OS in S)return S[og]=E,S;const I=function(){jp(r);const O=Array.from(arguments),R=[],M=[];function D(K){R.push(K)}function F(K){M.push(K)}ll(f,{args:O,name:I[og],store:_,after:D,onError:F});let U;try{U=S.apply(this&&this.$id===e?this:_,O)}catch(K){throw ll(M,K),K}return U instanceof Promise?U.then(K=>(ll(R,K),K)).catch(K=>(ll(M,K),Promise.reject(K))):(ll(R,U),U)};return I[OS]=!0,I[og]=E,I},C={_p:r,$id:e,$onAction:AS.bind(null,f),$patch:y,$reset:w,$subscribe(S,E={}){const I=AS(d,S,E.detached,()=>O()),O=o.run(()=>Ee(()=>r.state.value[e],R=>{(E.flush==="sync"?c:u)&&S({storeId:e,type:xc.direct,events:p},R)},no({},l,E)));return I},$dispose:b},_=cn(C);r._s.set(e,_);const P=(r._a&&r._a.runWithContext||k$)(()=>r._e.run(()=>(o=$a()).run(()=>t({action:k}))));for(const S in P){const E=P[S];if(et(E)&&!C$(E)||Eo(E))i||(g&&E$(E)&&(et(E)?E.value=g[S]:Mv(E,g[S])),r.state.value[e][S]=E);else if(typeof E=="function"){const I=k(E,S);P[S]=I,a.actions[S]=E}}return no(_,P),no(Be(_),P),Object.defineProperty(_,"$state",{get:()=>r.state.value[e],set:S=>{y(E=>{no(E,S)})}}),r._p.forEach(S=>{no(_,o.run(()=>S({store:_,app:r._a,pinia:r,options:a})))}),g&&i&&n.hydrate&&n.hydrate(_.$state,g),u=!0,c=!0,_}/*! #__NO_SIDE_EFFECTS__ */function gs(e,t,n){let r;const s=typeof t=="function";r=s?n:t;function i(o,a){const l=YC();return o=o||(l?Qe(ET,null):null),o&&jp(o),o=xT,o._s.has(e)||(s?TT(e,t,r,o):T$(e,r,o)),o._s.get(e)}return i.$id=e,i}const PT=gs("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 Dv(e){return Ip()?(yn(e),!0):!1}const Lv=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const P$=Object.prototype.toString,R$=e=>P$.call(e)==="[object Object]";function ag(e){return Array.isArray(e)?e:[e]}function I$(e,t=1e3,n={}){const{immediate:r=!0,immediateCallback:s=!1}=n;let i=null;const o=Ie(!1);function a(){i&&(clearInterval(i),i=null)}function l(){o.value=!1,a()}function u(){const c=Nn(t);c<=0||(o.value=!0,s&&e(),a(),o.value&&(i=setInterval(e,c)))}if(r&&Lv&&u(),et(t)||typeof t=="function"){const c=Ee(t,()=>{o.value&&Lv&&u()});Dv(c)}return Dv(l),{isActive:Mb(o),pause:l,resume:u}}function A$(e,t,n){return Ee(e,t,{...n,immediate:!0})}const RT=Lv?window:void 0;function O$(e){var t;const n=Nn(e);return(t=n==null?void 0:n.$el)!=null?t:n}function M$(...e){const t=[],n=()=>{t.forEach(a=>a()),t.length=0},r=(a,l,u,c)=>(a.addEventListener(l,u,c),()=>a.removeEventListener(l,u,c)),s=A(()=>{const a=ag(Nn(e[0])).filter(l=>l!=null);return a.every(l=>typeof l!="string")?a:void 0}),i=A$(()=>{var a,l;return[(l=(a=s.value)==null?void 0:a.map(u=>O$(u)))!=null?l:[RT].filter(u=>u!=null),ag(Nn(s.value?e[1]:e[0])),ag(Q(s.value?e[2]:e[1])),Nn(s.value?e[3]:e[2])]},([a,l,u,c])=>{if(n(),!(a!=null&&a.length)||!(l!=null&&l.length)||!(u!=null&&u.length))return;const d=R$(c)?{...c}:c;t.push(...a.flatMap(f=>l.flatMap(p=>u.map(g=>r(f,p,g,d)))))},{flush:"post"}),o=()=>{i(),n()};return Dv(n),o}function D$(e){return typeof e=="function"?e:typeof e=="string"?t=>t.key===e:Array.isArray(e)?t=>e.includes(t.key):()=>!0}function L$(...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=RT,eventName:i="keydown",passive:o=!1,dedupe:a=!1}=r,l=D$(t);return M$(s,i,c=>{c.repeat&&Nn(a)||l(c)&&n(c)},o)}const Ju=new Map;function Br(e){const t=Ip();function n(a){var l;const u=Ju.get(e)||new Set;u.add(a),Ju.set(e,u);const c=()=>s(a);return(l=t==null?void 0:t.cleanups)==null||l.push(c),c}function r(a){function l(...u){s(l),a(...u)}return n(l)}function s(a){const l=Ju.get(e);l&&(l.delete(a),l.size||i())}function i(){Ju.delete(e)}function o(a,l){var u;(u=Ju.get(e))==null||u.forEach(c=>c(a,l))}return{on:n,once:r,off:s,emit:o,reset:i}}function tn(e){const t=PT();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=>{On(()=>{t.isDialogOpened(e)||s(t.getOutput(e))})}))}}const Et=typeof window<"u",Wb=Et&&"IntersectionObserver"in window,$$=Et&&("ontouchstart"in window||window.navigator.maxTouchPoints>0);function MS(e,t,n){F$(e,t),t.set(e,n)}function F$(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function DS(e,t,n){return e.set(IT(e,t),n),n}function vi(e,t){return e.get(IT(e,t))}function IT(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 AT(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 as(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=>as(e[r],t[r]))}function Ba(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(/^\./,""),AT(e,t.split("."),n))}function Fn(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 Ba(e,t,n);if(Array.isArray(t))return AT(e,t,n);if(typeof t!="function")return n;const r=t(e,n);return typeof r>"u"?n:r}function xl(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;const n=Number(e);return isNaN(n)?String(e):isFinite(n)?`${n}${t}`:void 0}function Mh(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)}function LS(e){let t;return e!==null&&typeof e=="object"&&((t=Object.getPrototypeOf(e))===Object.prototype||t===null)}function Gb(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 $S=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}),FS=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 OT(e){return Object.keys(e)}function lg(e,t){return t.every(n=>e.hasOwnProperty(n))}function xd(e,t){const n={};for(const r of t)Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}function $v(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 Ms(e,t){const n={...e};return t.forEach(r=>delete n[r]),n}const MT=/^on[^a-z]/,Kb=e=>MT.test(e),N$=["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 Ja(e){const[t,n]=$v(e,[MT]),r=Ms(t,N$),[s,i]=$v(n,["class","style","id",/^data-/]);return Object.assign(s,t),Object.assign(i,r),[s,i]}function An(e){return e==null?[]:Array.isArray(e)?e:[e]}function B$(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),Q(t))};return r.clear=()=>{clearTimeout(n)},r.immediate=e,r}function Cr(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 NS(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 BS(e,t){return(arguments.length>2&&arguments[2]!==void 0?arguments[2]:"0").repeat(Math.max(0,t-e.length))+e}function V$(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 VS(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 Zn(){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(LS(i)&&LS(o)){r[s]=Zn(i,o,n);continue}if(n&&Array.isArray(i)&&Array.isArray(o)){r[s]=n(i,o);continue}r[s]=o}return r}function DT(e){return e.map(t=>t.type===Ae?DT(t.children):t).flat()}function Ta(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";if(Ta.cache.has(e))return Ta.cache.get(e);const t=e.replace(/[^a-z]/gi,"-").replace(/\B([A-Z])/g,"-$1").toLowerCase();return Ta.cache.set(e,t),t}Ta.cache=new Map;function El(e,t){if(!t||typeof t!="object")return[];if(Array.isArray(t))return t.map(n=>El(e,n)).flat(1);if(t.suspense)return El(e,t.ssContent);if(Array.isArray(t.children))return t.children.map(n=>El(e,n)).flat(1);if(t.component){if(Object.getOwnPropertySymbols(t.component.provides).includes(e))return[t.component];if(t.component.subTree)return El(e,t.component.subTree).flat(1)}return[]}var ul=new WeakMap,Zo=new WeakMap;class LT{constructor(t){MS(this,ul,[]),MS(this,Zo,0),this.size=t}get isFull(){return vi(ul,this).length===this.size}push(t){vi(ul,this)[vi(Zo,this)]=t,DS(Zo,this,(vi(Zo,this)+1)%this.size)}values(){return vi(ul,this).slice(vi(Zo,this)).concat(vi(ul,this).slice(0,vi(Zo,this)))}clear(){vi(ul,this).length=0,DS(Zo,this,0)}}function Yb(e){const t=cn({});On(()=>{const r=e();for(const s in r)t[s]=r[s]},{flush:"sync"});const n={};for(const r in t)n[r]=ae(()=>t[r]);return n}function Dh(e,t){return e.includes(t)}function $T(e){return e[2].toLowerCase()+e.slice(3)}const Bn=()=>[Function,Array];function US(e,t){return t="on"+ci(t),!!(e[t]||e[`${t}Once`]||e[`${t}Capture`]||e[`${t}OnceCapture`]||e[`${t}CaptureOnce`])}function qp(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 qc(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 FT(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 Ec(e,t){var r,s,i,o;const n=qc(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=FT(n,t);a?a.focus():Ec(e,t==="next"?"first":"last")}}function tf(e){return e==null||typeof e=="string"&&e.trim()===""}function Lh(e,t){if(!(Et&&typeof CSS<"u"&&typeof CSS.supports<"u"&&CSS.supports(`selector(${t})`)))return null;try{return!!e&&e.matches(t)}catch{return null}}function NT(e){return e.some(t=>tu(t)?t.type===Qn?!1:t.type!==Ae||NT(t.children):!0)?e:null}function U$(e,t){if(!Et||e===0)return t(),()=>{};const n=window.setTimeout(t,e);return()=>window.clearTimeout(n)}function z$(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 Fv(){const e=Ie(),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:()=>Gb(e.value)}),t}function zS(e){const t=e.key.length===1,n=!e.ctrlKey&&!e.metaKey&&!e.altKey;return t&&n}function BT(e){return typeof e=="string"||typeof e=="number"||typeof e=="boolean"||typeof e=="bigint"}const VT=["top","bottom"],H$=["start","end","left","right"];function Nv(e,t){let[n,r]=e.split(" ");return r||(r=Dh(VT,n)?"start":Dh(H$,n)?"top":"center"),{side:Bv(n,t),align:Bv(r,t)}}function Bv(e,t){return e==="start"?t?"right":"left":e==="end"?t?"left":"right":e}function ug(e){return{side:{center:"center",top:"bottom",bottom:"top",left:"right",right:"left"}[e.side],align:e.align}}function cg(e){return{side:e.side,align:{center:"center",top:"bottom",bottom:"top",left:"right",right:"left"}[e.align]}}function HS(e){return{side:e.align,align:e.side}}function jS(e){return Dh(VT,e.side)?"y":"x"}class So{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 qS(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 UT(e){return Array.isArray(e)?new So({x:e[0],y:e[1],width:0,height:0}):e.getBoundingClientRect()}function Xb(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=Number(s[0]),o=Number(s[5]),a=Number(s[12]),l=Number(s[13]);else if(r.startsWith("matrix("))s=r.slice(7,-1).split(/, /),i=Number(s[0]),o=Number(s[3]),a=Number(s[4]),l=Number(s[5]);else return new So(t);const u=n.transformOrigin,c=t.x-a-(1-i)*parseFloat(u),d=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 So({x:c,y:d,width:f,height:p})}else return new So(t)}function Cl(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 Kf=new WeakMap;function j$(e,t){Object.keys(t).forEach(n=>{if(Kb(n)){const r=$T(n),s=Kf.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]]),Kf.has(e)||Kf.set(e,i)}}else t[n]==null?e.removeAttribute(n):e.setAttribute(n,t[n])})}function q$(e,t){Object.keys(t).forEach(n=>{if(Kb(n)){const r=$T(n),s=Kf.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 cl=2.4,WS=.2126729,GS=.7151522,KS=.072175,W$=.55,G$=.58,K$=.57,Y$=.62,nf=.03,YS=1.45,X$=5e-4,Q$=1.25,J$=1.25,XS=.078,QS=12.82051282051282,rf=.06,JS=.001;function ZS(e,t){const n=(e.r/255)**cl,r=(e.g/255)**cl,s=(e.b/255)**cl,i=(t.r/255)**cl,o=(t.g/255)**cl,a=(t.b/255)**cl;let l=n*WS+r*GS+s*KS,u=i*WS+o*GS+a*KS;if(l<=nf&&(l+=(nf-l)**YS),u<=nf&&(u+=(nf-u)**YS),Math.abs(u-l)<X$)return 0;let c;if(u>l){const d=(u**W$-l**G$)*Q$;c=d<JS?0:d<XS?d-d*QS*rf:d-rf}else{const d=(u**Y$-l**K$)*J$;c=d>-JS?0:d>-XS?d-d*QS*rf:d+rf}return c*100}function Z$(e,t){t=Array.isArray(t)?t.slice(0,-1).map(n=>`'${n}'`).join(", ")+` or '${t.at(-1)}'`:`'${t}'`}const $h=.20689655172413793,eF=e=>e>$h**3?Math.cbrt(e):e/(3*$h**2)+4/29,tF=e=>e>$h?e**3:3*$h**2*(e-4/29);function zT(e){const t=eF,n=t(e[1]);return[116*n-16,500*(t(e[0]/.95047)-n),200*(n-t(e[2]/1.08883))]}function HT(e){const t=tF,n=(e[0]+16)/116;return[t(n+e[1]/500)*.95047,t(n),t(n-e[2]/200)*1.08883]}const nF=[[3.2406,-1.5372,-.4986],[-.9689,1.8758,.0415],[.0557,-.204,1.057]],rF=e=>e<=.0031308?e*12.92:1.055*e**(1/2.4)-.055,sF=[[.4124,.3576,.1805],[.2126,.7152,.0722],[.0193,.1192,.9505]],iF=e=>e<=.04045?e/12.92:((e+.055)/1.055)**2.4;function jT(e){const t=Array(3),n=rF,r=nF;for(let s=0;s<3;++s)t[s]=Math.round(Cr(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 Qb(e){let{r:t,g:n,b:r}=e;const s=[0,0,0],i=iF,o=sF;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 Vv(e){return!!e&&/^(#|var\(--|(rgb|hsl)a?\()/.test(e)}function oF(e){return Vv(e)&&!/^((rgb|hsl)a?\()?var\(--/.test(e)}const e1=/^(?<fn>(?:rgb|hsl)a?)\((?<values>.+)\)/,aF={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)=>t1({h:e,s:t,l:n,a:r}),hsla:(e,t,n,r)=>t1({h:e,s:t,l:n,a:r}),hsv:(e,t,n,r)=>Wc({h:e,s:t,v:n,a:r}),hsva:(e,t,n,r)=>Wc({h:e,s:t,v:n,a:r})};function ri(e){if(typeof e=="number")return{r:(e&16711680)>>16,g:(e&65280)>>8,b:e&255};if(typeof e=="string"&&e1.test(e)){const{groups:t}=e.match(e1),{fn:n,values:r}=t,s=r.split(/,\s*|\s*\/\s*|\s+/).map((i,o)=>i.endsWith("%")||o>0&&o<3&&["hsl","hsla","hsv","hsva"].includes(n)?parseFloat(i)/100:parseFloat(i));return aF[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),uF(t)}else if(typeof e=="object"){if(lg(e,["r","g","b"]))return e;if(lg(e,["h","s","l"]))return Wc(qT(e));if(lg(e,["h","s","v"]))return Wc(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 Wc(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 t1(e){return Wc(qT(e))}function qT(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 sf(e){const t=Math.round(e).toString(16);return("00".substr(0,2-t.length)+t).toUpperCase()}function lF(e){let{r:t,g:n,b:r,a:s}=e;return`#${[sf(t),sf(n),sf(r),s!==void 0?sf(Math.round(s*255)):""].join("")}`}function uF(e){e=cF(e);let[t,n,r,s]=V$(e,2).map(i=>parseInt(i,16));return s=s===void 0?s:s/255,{r:t,g:n,b:r,a:s}}function cF(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=NS(NS(e,6),8,"F")),e}function dF(e,t){const n=zT(Qb(e));return n[0]=n[0]+t*10,jT(HT(n))}function fF(e,t){const n=zT(Qb(e));return n[0]=n[0]-t*10,jT(HT(n))}function hF(e){const t=ri(e);return Qb(t)[1]}function WT(e){const t=Math.abs(ZS(ri(0),ri(e)));return Math.abs(ZS(ri(16777215),ri(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 Ue=de({class:[String,Array,Object],style:{type:[String,Array,Object],default:null}},"component");function an(e,t){const n=zp();if(!n)throw new Error(`[Vuetify] ${e} must be called from inside a setup function`);return n}function di(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"composables";const t=an(e).type;return Ta((t==null?void 0:t.aliasName)||(t==null?void 0:t.name))}function pF(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:an("injectSelf");const{provides:n}=t;if(n&&e in n)return n[e]}const ru=Symbol.for("vuetify:defaults");function mF(e){return j(e)}function Jb(){const e=Qe(ru);if(!e)throw new Error("[Vuetify] Could not find defaults instance");return e}function Ir(e,t){const n=Jb(),r=j(e),s=A(()=>{if(Q(t==null?void 0:t.disabled))return n.value;const o=Q(t==null?void 0:t.scoped),a=Q(t==null?void 0:t.reset),l=Q(t==null?void 0:t.root);if(r.value==null&&!(o||a||l))return n.value;let u=Zn(r.value,{prev:n.value});if(o)return u;if(a||l){const c=Number(a||1/0);for(let d=0;d<=c&&!(!u||!("prev"in u));d++)u=u.prev;return u&&typeof l=="string"&&l in u&&(u=Zn(Zn(u,{prev:u}),u[l])),u}return u.prev?Zn(u.prev,u):u});return Kt(ru,s),s}function gF(e,t){return e.props&&(typeof e.props[t]<"u"||typeof e.props[Ta(t)]<"u")}function vF(){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]:Jb();const r=an("useDefaults");if(t=t??r.type.name??r.type.__name,!t)throw new Error("[Vuetify] Could not determine component name");const s=A(()=>{var l;return(l=n.value)==null?void 0:l[e._as??t]}),i=new Proxy(e,{get(l,u){var p,g,m,y;const c=Reflect.get(l,u);if(u==="class"||u==="style")return[(p=s.value)==null?void 0:p[u],c].filter(w=>w!=null);if(gF(r.vnode,u))return c;const d=(g=s.value)==null?void 0:g[u];if(d!==void 0)return d;const f=(y=(m=n.value)==null?void 0:m.global)==null?void 0:y[u];return f!==void 0?f:c}}),o=Ie();On(()=>{if(s.value){const l=Object.entries(s.value).filter(u=>{let[c]=u;return c.startsWith(c[0].toUpperCase())});o.value=l.length?Object.fromEntries(l):void 0}else o.value=void 0});function a(){const l=pF(ru,r);Kt(ru,A(()=>o.value?Zn((l==null?void 0:l.value)??{},o.value):l==null?void 0:l.value))}return{props:i,provideSubDefaults:a}}function _u(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 xd(r,t)},e.props._as=String,e.setup=function(r,s){const i=Jb();if(!i.value)return e._setup(r,s);const{props:o,provideSubDefaults:a}=vF(r,r._as??e.name,i),l=e._setup(o,s);return a(),l}}return e}function ke(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;return t=>(e?_u:Le)(t)}function yF(e,t){return t.props=e,t}function ku(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"div",n=arguments.length>2?arguments[2]:void 0;return ke()({name:n??ci(Rr(e.replace(/__/g,"-"))),props:{tag:{type:String,default:t},...Ue()},setup(r,s){let{slots:i}=s;return()=>{var o;return pr(r.tag,{class:[e,r.class],style:r.style},(o=i.default)==null?void 0:o.call(i))}}})}function GT(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 Fh="cubic-bezier(0.4, 0, 0.2, 1)",bF="cubic-bezier(0.0, 0, 0.2, 1)",wF="cubic-bezier(0.4, 0, 1, 1)";function n1(e,t,n){return Object.keys(e).filter(r=>Kb(r)&&r.endsWith(t)).reduce((r,s)=>(r[s.slice(0,-t.length)]=i=>e[s](i,n(i)),r),{})}function KT(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;for(;e;){if(t?SF(e):Zb(e))return e;e=e.parentElement}return document.scrollingElement}function Nh(e,t){const n=[];if(t&&e&&!t.contains(e))return n;for(;e&&(Zb(e)&&n.push(e),e!==t);)e=e.parentElement;return n}function Zb(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 SF(e){if(!e||e.nodeType!==Node.ELEMENT_NODE)return!1;const t=window.getComputedStyle(e);return["scroll","auto"].includes(t.overflowY)}function _F(e){for(;e;){if(window.getComputedStyle(e).position==="fixed")return!0;e=e.offsetParent}return!1}function Oe(e){const t=an("useRender");t.render=e}const vs=de({border:[Boolean,Number,String]},"border");function Ds(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:di();return{borderClasses:A(()=>{const r=e.border;return r===!0||r===""?`${t}--border`:typeof r=="string"||r===0?String(r).split(" ").map(s=>`border-${s}`):[]})}}const kF=[null,"default","comfortable","compact"],Ar=de({density:{type:String,default:"default",validator:e=>kF.includes(e)}},"density");function ys(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:di();return{densityClasses:ae(()=>`${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 Ls(e){return{elevationClasses:ae(()=>{const n=et(e)?e.value:e.elevation;return n==null?[]:[`elevation-${n}`]})}}const Dn=de({rounded:{type:[Boolean,Number,String],default:void 0},tile:Boolean},"rounded");function zn(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:di();return{roundedClasses:A(()=>{const r=et(e)?e.value:e.rounded,s=et(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 yt=de({tag:{type:[String,Object,Function],default:"div"}},"tag"),Gc=Symbol.for("vuetify:theme"),Lt=de({theme:String},"theme");function r1(){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":"#c8c8c8","on-surface-variant":"#000000",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"}}},stylesheetId:"vuetify-theme-stylesheet"}}function xF(){var r,s;let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:r1();const t=r1();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]=Zn(a,o)}return Zn(t,{...e,themes:n})}function ea(e,t,n,r){e.push(`${PF(t,r)} {
|
|
23
|
+
`,...n.map(s=>` ${s};
|
|
24
|
+
`),`}
|
|
25
|
+
`)}function s1(e){const t=e.dark?2:1,n=e.dark?1:2,r=[];for(const[s,i]of Object.entries(e.colors)){const o=ri(i);r.push(`--v-theme-${s}: ${o.r},${o.g},${o.b}`),s.startsWith("on-")||r.push(`--v-theme-${s}-overlay-multiplier: ${hF(i)>.18?t:n}`)}for(const[s,i]of Object.entries(e.variables)){const o=typeof i=="string"&&i.startsWith("#")?ri(i):void 0,a=o?`${o.r}, ${o.g}, ${o.b}`:void 0;r.push(`--v-${s}: ${a??i}`)}return r}function EF(e,t,n){const r={};if(n)for(const s of["lighten","darken"]){const i=s==="lighten"?dF:fF;for(const o of xl(n[s],1))r[`${e}-${s}-${o}`]=lF(i(ri(t),o))}return r}function CF(e,t){if(!t)return{};let n={};for(const r of t.colors){const s=e[r];s&&(n={...n,...EF(r,s,t)})}return n}function TF(e){const t={};for(const n of Object.keys(e)){if(n.startsWith("on-")||e[`on-${n}`])continue;const r=`on-${n}`,s=ri(e[n]);t[r]=WT(s)}return t}function PF(e,t){if(!t)return e;const n=`:where(${t})`;return e===":root"?n:`${n} ${e}`}function RF(e,t){e&&(e.innerHTML=t)}function IF(e,t){if(!Et)return null;let n=document.getElementById(e);return n||(n=document.createElement("style"),n.id=e,n.type="text/css",t&&n.setAttribute("nonce",t),document.head.appendChild(n)),n}function AF(e){const t=xF(e),n=Ie(t.defaultTheme),r=j(t.themes),s=A(()=>{const u={};for(const[c,d]of Object.entries(r.value)){const f={...d.colors,...CF(d.colors,t.variations)};u[c]={...d,colors:{...f,...TF(f)}}}return u}),i=ae(()=>s.value[n.value]),o=A(()=>{var p;const u=[];(p=i.value)!=null&&p.dark&&ea(u,":root",["color-scheme: dark"],t.scope),ea(u,":root",s1(i.value),t.scope);for(const[g,m]of Object.entries(s.value))ea(u,`.v-theme--${g}`,[`color-scheme: ${m.dark?"dark":"normal"}`,...s1(m)],t.scope);const c=[],d=[],f=new Set(Object.values(s.value).flatMap(g=>Object.keys(g.colors)));for(const g of f)g.startsWith("on-")?ea(d,`.${g}`,[`color: rgb(var(--v-theme-${g})) !important`],t.scope):(ea(c,`.bg-${g}`,[`--v-theme-overlay-multiplier: var(--v-theme-${g}-overlay-multiplier)`,`background-color: rgb(var(--v-theme-${g})) !important`,`color: rgb(var(--v-theme-on-${g})) !important`],t.scope),ea(d,`.text-${g}`,[`color: rgb(var(--v-theme-${g})) !important`],t.scope),ea(d,`.border-${g}`,[`--v-border-color: var(--v-theme-${g})`],t.scope));return u.push(...c,...d),u.map((g,m)=>m===0?g:` ${g}`).join("")});function a(u){if(t.isDisabled)return;const c=u._context.provides.usehead;if(c){let p=function(){return{style:[{textContent:o.value,id:t.stylesheetId,nonce:t.cspNonce||!1}]}};var d=p;if(c.push){const g=c.push(p);Et&&Ee(o,()=>{g.patch(p)})}else Et?(c.addHeadObjs(ae(p)),On(()=>c.updateDOM())):c.addHeadObjs(p())}else{let p=function(){RF(IF(t.stylesheetId,t.cspNonce),o.value)};var f=p;Et?Ee(o,p,{immediate:!0}):p()}}const l=ae(()=>t.isDisabled?void 0:`v-theme--${n.value}`);return{install:a,isDisabled:t.isDisabled,name:n,themes:r,current:i,computedThemes:s,themeClasses:l,styles:o,global:{name:n,current:i}}}function Zt(e){an("provideTheme");const t=Qe(Gc,null);if(!t)throw new Error("Could not find Vuetify theme injection");const n=ae(()=>e.theme??t.name.value),r=ae(()=>t.themes.value[n.value]),s=ae(()=>t.isDisabled?void 0:`v-theme--${n.value}`),i={...t,name:n,current:r,themeClasses:s};return Kt(Gc,i),i}function YT(){an("useTheme");const e=Qe(Gc,null);if(!e)throw new Error("Could not find Vuetify theme injection");return e}function e0(e){return Yb(()=>{const t=Nn(e),n=[],r={};if(t.background)if(Vv(t.background)){if(r.backgroundColor=t.background,!t.text&&oF(t.background)){const s=ri(t.background);if(s.a==null||s.a===1){const i=WT(s);r.color=i,r.caretColor=i}}}else n.push(`bg-${t.background}`);return t.text&&(Vv(t.text)?(r.color=t.text,r.caretColor=t.text):n.push(`text-${t.text}`)),{colorClasses:n,colorStyles:r}})}function As(e){const{colorClasses:t,colorStyles:n}=e0(()=>({text:Nn(e)}));return{textColorClasses:t,textColorStyles:n}}function fr(e){const{colorClasses:t,colorStyles:n}=e0(()=>({background:Nn(e)}));return{backgroundColorClasses:t,backgroundColorStyles:n}}const OF=["elevated","flat","tonal","outlined","text","plain"];function Ho(e,t){return h(Ae,null,[e&&h("span",{key:"overlay",class:`${t}__overlay`},null),h("span",{key:"underlay",class:`${t}__underlay`},null)])}const $s=de({color:String,variant:{type:String,default:"elevated",validator:e=>OF.includes(e)}},"variant");function Za(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:di();const n=ae(()=>{const{variant:i}=Nn(e);return`${t}--variant-${i}`}),{colorClasses:r,colorStyles:s}=e0(()=>{const{variant:i,color:o}=Nn(e);return{[["elevated","flat"].includes(i)?"background":"text"]:o}});return{colorClasses:r,colorStyles:s,variantClasses:n}}const XT=de({baseColor:String,divided:Boolean,...vs(),...Ue(),...Ar(),...bs(),...Dn(),...yt(),...Lt(),...$s()},"VBtnGroup"),i1=ke()({name:"VBtnGroup",props:XT(),setup(e,t){let{slots:n}=t;const{themeClasses:r}=Zt(e),{densityClasses:s}=ys(e),{borderClasses:i}=Ds(e),{elevationClasses:o}=Ls(e),{roundedClasses:a}=zn(e);Ir({VBtn:{height:"auto",baseColor:ae(()=>e.baseColor),color:ae(()=>e.color),density:ae(()=>e.density),flat:!0,variant:ae(()=>e.variant)}}),Oe(()=>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 Hr(e,t){let n;function r(){n=$a(),n.run(()=>t.length?t(()=>{n==null||n.stop(),r()}):t())}Ee(e,s=>{s&&!n?r():s||(n==null||n.stop(),n=void 0)},{immediate:!0}),yn(()=>{n==null||n.stop()})}function st(e,t,n){let r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:d=>d,s=arguments.length>4&&arguments[4]!==void 0?arguments[4]:d=>d;const i=an("useProxiedModel"),o=j(e[t]!==void 0?e[t]:n),a=Ta(t),u=A(a!==t?()=>{var d,f,p,g;return e[t],!!(((d=i.vnode.props)!=null&&d.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 d,f;return e[t],!!((d=i.vnode.props)!=null&&d.hasOwnProperty(t)&&((f=i.vnode.props)!=null&&f.hasOwnProperty(`onUpdate:${t}`)))});Hr(()=>!u.value,()=>{Ee(()=>e[t],d=>{o.value=d})});const c=A({get(){const d=e[t];return r(u.value?d:o.value)},set(d){const f=s(d),p=Be(u.value?e[t]:o.value);p===f||r(p)===d||(o.value=f,i==null||i.emit(`update:${t}`,f))}});return Object.defineProperty(c,"externalValue",{get:()=>u.value?e[t]:o.value}),c}const Ed=de({modelValue:{type:null,default:void 0},multiple:Boolean,mandatory:[Boolean,String],max:Number,selectedClass:String,disabled:Boolean},"group"),Cd=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=an("useGroupItem");if(!r)throw new Error("[Vuetify] useGroupItem composable must be used inside a component setup function");const s=ms();Kt(Symbol.for(`${t.description}:id`),s);const i=Qe(t,null);if(!i){if(!n)return i;throw new Error(`[Vuetify] Could not find useGroup injection with symbol ${t.description}`)}const o=ae(()=>e.value),a=A(()=>!!(i.disabled.value||e.disabled));i.register({id:s,value:o,disabled:a},r),Cn(()=>{i.unregister(s)});const l=A(()=>i.isSelected(s)),u=A(()=>i.items.value[0].id===s),c=A(()=>i.items.value[i.items.value.length-1].id===s),d=A(()=>l.value&&[i.selectedClass.value,e.selectedClass]);return Ee(l,f=>{r.emit("group:selected",{value:f})},{flush:"sync"}),{id:s,isSelected:l,isFirst:u,isLast:c,toggle:()=>i.select(s,!l.value),select:f=>i.select(s,f),selectedClass:d,value:o,disabled:a,group:i}}function xu(e,t){let n=!1;const r=cn([]),s=st(e,"modelValue",[],f=>f==null?[]:QT(r,An(f)),f=>{const p=DF(r,f);return e.multiple?p:p[0]}),i=an("useGroup");function o(f,p){const g=f,m=Symbol.for(`${t.description}:id`),w=El(m,i==null?void 0:i.vnode).indexOf(p);Q(g.value)==null&&(g.value=w,g.useIndexAsValue=!0),w>-1?r.splice(w,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()}),Cn(()=>{n=!0}),Fb(()=>{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(b=>b===f),w=~y;if(p=p??!w,w&&e.mandatory&&m.length<=1||!w&&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 c(f){if(e.multiple,s.value.length){const p=s.value[0],g=r.findIndex(w=>w.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 d={register:o,unregister:a,selected:s,select:u,disabled:ae(()=>e.disabled),prev:()=>c(r.length-1),next:()=>c(1),isSelected:f=>s.value.includes(f),selectedClass:ae(()=>e.selectedClass),items:ae(()=>r),getItemIndex:f=>MF(r,f)};return Kt(t,d),d}function MF(e,t){const n=QT(e,[t]);return n.length?e.findIndex(r=>r.id===n[0]):-1}function QT(e,t){const n=[];return t.forEach(r=>{const s=e.find(o=>as(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 DF(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 JT=Symbol.for("vuetify:v-btn-toggle"),LF=de({...XT(),...Ed()},"VBtnToggle"),ZT=ke()({name:"VBtnToggle",props:LF(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const{isSelected:r,next:s,prev:i,select:o,selected:a}=xu(e,JT);return Oe(()=>{const l=i1.filterProps(e);return h(i1,ge({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}}}),$F=de({defaults:Object,disabled:Boolean,reset:[Number,String],root:[Boolean,String],scoped:Boolean},"VDefaultsProvider"),Ot=ke(!1)({name:"VDefaultsProvider",props:$F(),setup(e,t){let{slots:n}=t;const{defaults:r,disabled:s,reset:i,root:o,scoped:a}=Qa(e);return Ir(r,{reset:i,root:o,scoped:a,disabled:s}),()=>{var l;return(l=n.default)==null?void 0:l.call(n)}}}),FF={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",upload:"mdi-cloud-upload"},NF={component:e=>pr(tP,{...e,class:"mdi"})},He=[String,Function,Object,Array],Uv=Symbol.for("vuetify:icons"),Wp=de({icon:{type:He},tag:{type:[String,Object,Function],required:!0}},"icon"),o1=ke()({name:"VComponentIcon",props:Wp(),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)]}})}}}),eP=_u({name:"VSvgIcon",inheritAttrs:!1,props:Wp(),setup(e,t){let{attrs:n}=t;return()=>h(e.tag,ge(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)])]})}}),BF=_u({name:"VLigatureIcon",props:Wp(),setup(e){return()=>h(e.tag,null,{default:()=>[e.icon]})}}),tP=_u({name:"VClassIcon",props:Wp(),setup(e){return()=>h(e.tag,{class:e.icon},null)}});function VF(){return{svg:{component:eP},class:{component:tP}}}function UF(e){const t=VF(),n=(e==null?void 0:e.defaultSet)??"mdi";return n==="mdi"&&!t.mdi&&(t.mdi=NF),Zn({defaultSet:n,sets:t,aliases:{...FF,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 zF=e=>{const t=Qe(Uv);if(!t)throw new Error("Missing Vuetify Icons provide!");return{iconData:A(()=>{var l;const r=Nn(e);if(!r)return{component:o1};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:eP,icon:s};if(typeof s!="string")return{component:o1,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}})}},HF=["x-small","small","default","large","x-large"],Eu=de({size:{type:[String,Number],default:"default"}},"size");function Pd(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:di();return Yb(()=>{const n=e.size;let r,s;return Dh(HF,n)?r=`${t}--size-${n}`:n&&(s={width:Ne(n),height:Ne(n)}),{sizeClasses:r,sizeStyles:s}})}const jF=de({color:String,disabled:Boolean,start:Boolean,end:Boolean,icon:He,opacity:[String,Number],...Ue(),...Eu(),...yt({tag:"i"}),...Lt()},"VIcon"),J=ke()({name:"VIcon",props:jF(),setup(e,t){let{attrs:n,slots:r}=t;const s=Ie(),{themeClasses:i}=YT(),{iconData:o}=zF(()=>s.value||e.icon),{sizeClasses:a}=Pd(e),{textColorClasses:l,textColorStyles:u}=As(()=>e.color);return Oe(()=>{var f,p;const c=(f=r.default)==null?void 0:f.call(r);c&&(s.value=(p=DT(c).filter(g=>g.type===_d&&g.children&&typeof g.children=="string")[0])==null?void 0:p.children);const d=!!(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":d,"v-icon--disabled":e.disabled,"v-icon--start":e.start,"v-icon--end":e.end},e.class],style:[{"--v-icon-opacity":e.opacity},a.value?void 0:{fontSize:Ne(e.size),height:Ne(e.size),width:Ne(e.size)},u.value,e.style],role:d?"button":void 0,"aria-hidden":!d,tabindex:d?e.disabled?-1:0:void 0},{default:()=>[c]})}),{}}});function nP(e,t){const n=j(),r=Ie(!1);if(Wb){const s=new IntersectionObserver(i=>{r.value=!!i.find(o=>o.isIntersecting)},t);Cn(()=>{s.disconnect()}),Ee(n,(i,o)=>{o&&(s.unobserve(o),r.value=!1),i&&s.observe(i)},{flush:"post"})}return{intersectionRef:n,isIntersecting:r}}function Va(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"content";const n=Fv(),r=j();if(Et){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())});Cn(()=>{s.disconnect()}),Ee(()=>n.el,(i,o)=>{o&&(s.unobserve(o),r.value=void 0),i&&s.observe(i)},{flush:"post"})}return{resizeRef:n,contentRect:zo(r)}}const qF=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},...Ue(),...Eu(),...yt({tag:"div"}),...Lt()},"VProgressCircular"),ni=ke()({name:"VProgressCircular",props:qF(),setup(e,t){let{slots:n}=t;const r=20,s=2*Math.PI*r,i=j(),{themeClasses:o}=Zt(e),{sizeClasses:a,sizeStyles:l}=Pd(e),{textColorClasses:u,textColorStyles:c}=As(()=>e.color),{textColorClasses:d,textColorStyles:f}=As(()=>e.bgColor),{intersectionRef:p,isIntersecting:g}=nP(),{resizeRef:m,contentRect:y}=Va(),w=ae(()=>Math.max(0,Math.min(100,parseFloat(e.modelValue)))),b=ae(()=>Number(e.width)),k=ae(()=>l.value?Number(e.size):y.value?y.value.width:Math.max(b.value,32)),C=ae(()=>r/(1-b.value/k.value)*2),_=ae(()=>b.value/k.value*C.value),T=ae(()=>Ne((100-w.value)/100*s));return On(()=>{p.value=i.value,m.value=i.value}),Oe(()=>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,c.value,e.style],role:"progressbar","aria-valuemin":"0","aria-valuemax":"100","aria-valuenow":e.indeterminate?void 0:w.value},{default:()=>[h("svg",{style:{transform:`rotate(calc(-90deg + ${Number(e.rotate)}deg))`},xmlns:"http://www.w3.org/2000/svg",viewBox:`0 0 ${C.value} ${C.value}`},[h("circle",{class:["v-progress-circular__underlay",d.value],style:f.value,fill:"transparent",cx:"50%",cy:"50%",r,"stroke-width":_.value,"stroke-dasharray":s,"stroke-dashoffset":0},null),h("circle",{class:"v-progress-circular__overlay",fill:"transparent",cx:"50%",cy:"50%",r,"stroke-width":_.value,"stroke-dasharray":s,"stroke-dashoffset":T.value},null)]),n.default&&h("div",{class:"v-progress-circular__content"},[n.default({value:w.value})])]})),{}}}),Or=de({height:[Number,String],maxHeight:[Number,String],maxWidth:[Number,String],minHeight:[Number,String],minWidth:[Number,String],width:[Number,String]},"dimension");function Mr(e){return{dimensionStyles:A(()=>{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 WF={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)"},fileUpload:{title:"Drag and drop files here",divider:"or",browse:"Browse Files"},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"},rules:{required:"This field is required",email:"Please enter a valid email",number:"This field can only contain numbers",integer:"This field can only contain integer values",capital:"This field can only contain uppercase letters",maxLength:"You must enter a maximum of {0} characters",minLength:"You must enter a minimum of {0} characters",strictLength:"The length of the entered field is invalid",exclude:"The {0} character is not allowed",notEmpty:"Please choose at least one value",pattern:"Invalid format"}},a1="$vuetify.",l1=(e,t)=>e.replace(/\{(\d+)\}/g,(n,r)=>String(t[Number(r)])),rP=(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(a1))return l1(r,i);const a=r.replace(a1,""),l=e.value&&n.value[e.value],u=t.value&&n.value[t.value];let c=Ba(l,a,null);return c||(`${r}${e.value}`,c=Ba(u,a,null)),c||(c=r),typeof c!="string"&&(c=r),l1(c,i)};function sP(e,t){return(n,r)=>new Intl.NumberFormat([e.value,t.value],r).format(n)}function dg(e,t,n){const r=st(e,t,e[t]??n.value);return r.value=e[t]??n.value,Ee(n,s=>{e[t]==null&&(r.value=n.value)}),r}function iP(e){return t=>{const n=dg(t,"locale",e.current),r=dg(t,"fallback",e.fallback),s=dg(t,"messages",e.messages);return{name:"vuetify",current:n,fallback:r,messages:s,t:rP(n,r,s),n:sP(n,r),provide:iP({current:n,fallback:r,messages:s})}}}function GF(e){const t=Ie((e==null?void 0:e.locale)??"en"),n=Ie((e==null?void 0:e.fallback)??"en"),r=j({en:WF,...e==null?void 0:e.messages});return{name:"vuetify",current:t,fallback:n,messages:r,t:rP(t,n,r),n:sP(t,n),provide:iP({current:t,fallback:n,messages:r})}}const Bh=Symbol.for("vuetify:locale");function KF(e){return e.name!=null}function YF(e){const t=e!=null&&e.adapter&&KF(e==null?void 0:e.adapter)?e==null?void 0:e.adapter:GF(e),n=QF(t,e);return{...t,...n}}function Gr(){const e=Qe(Bh);if(!e)throw new Error("[Vuetify] Could not find injected locale instance");return e}function XF(){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 QF(e,t){const n=j((t==null?void 0:t.rtl)??XF()),r=A(()=>n.value[e.current.value]??!1);return{isRtl:r,rtl:n,rtlClasses:ae(()=>`v-locale--is-${r.value?"rtl":"ltr"}`)}}function Dr(){const e=Qe(Bh);if(!e)throw new Error("[Vuetify] Could not find injected rtl instance");return{isRtl:e.isRtl,rtlClasses:e.rtlClasses}}const u1={center:"center",top:"bottom",bottom:"top",left:"right",right:"left"},jo=de({location:String},"location");function el(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,n=arguments.length>2?arguments[2]:void 0;const{isRtl:r}=Dr();return{locationStyles:A(()=>{if(!e.location)return{};const{side:i,align:o}=Nv(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[u1[i]]=`calc(100% - ${a(i)}px)`:l[i]=0),o!=="center"?t?l[u1[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 JF=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,...Ue(),...jo({location:"top"}),...Dn(),...yt(),...Lt()},"VProgressLinear"),su=ke()({name:"VProgressLinear",props:JF(),emits:{"update:modelValue":e=>!0},setup(e,t){var O;let{slots:n}=t;const r=st(e,"modelValue"),{isRtl:s,rtlClasses:i}=Dr(),{themeClasses:o}=Zt(e),{locationStyles:a}=el(e),{textColorClasses:l,textColorStyles:u}=As(()=>e.color),{backgroundColorClasses:c,backgroundColorStyles:d}=fr(()=>e.bgColor||e.color),{backgroundColorClasses:f,backgroundColorStyles:p}=fr(()=>e.bufferColor||e.bgColor||e.color),{backgroundColorClasses:g,backgroundColorStyles:m}=fr(()=>e.color),{roundedClasses:y}=zn(e),{intersectionRef:w,isIntersecting:b}=nP(),k=A(()=>parseFloat(e.max)),C=A(()=>parseFloat(e.height)),_=A(()=>Cr(parseFloat(e.bufferValue)/k.value*100,0,100)),T=A(()=>Cr(parseFloat(r.value)/k.value*100,0,100)),P=A(()=>s.value!==e.reverse),S=A(()=>e.indeterminate?"fade-transition":"slide-x-transition"),E=Et&&((O=window.matchMedia)==null?void 0:O.call(window,"(forced-colors: active)").matches);function I(R){if(!w.value)return;const{left:M,right:D,width:F}=w.value.getBoundingClientRect(),U=P.value?F-R.clientX+(D-F):R.clientX-M;r.value=Math.round(U/F*k.value)}return Oe(()=>h(e.tag,{ref:w,class:["v-progress-linear",{"v-progress-linear--absolute":e.absolute,"v-progress-linear--active":e.active&&b.value,"v-progress-linear--reverse":P.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(C.value):0,"--v-progress-linear-height":Ne(C.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:Math.min(parseFloat(r.value),k.value),onClick:e.clickable&&I},{default:()=>[e.stream&&h("div",{key:"stream",class:["v-progress-linear__stream",l.value],style:{...u.value,[P.value?"left":"right"]:Ne(-C.value),borderTop:`${Ne(C.value/2)} dotted`,opacity:parseFloat(e.bufferOpacity),top:`calc(50% - ${Ne(C.value/4)})`,width:Ne(100-_.value,"%"),"--v-progress-linear-stream-to":Ne(C.value*(P.value?1:-1))}},null),h("div",{class:["v-progress-linear__background",E?void 0:c.value],style:[d.value,{opacity:parseFloat(e.bgOpacity),width:e.stream?0:void 0}]},null),h("div",{class:["v-progress-linear__buffer",E?void 0:f.value],style:[p.value,{opacity:parseFloat(e.bufferOpacity),width:Ne(_.value,"%")}]},null),h(Oo,{name:S.value},{default:()=>[e.indeterminate?h("div",{class:"v-progress-linear__indeterminate"},[["long","short"].map(R=>h("div",{key:R,class:["v-progress-linear__indeterminate",R,E?void 0:g.value],style:m.value},null))]):h("div",{class:["v-progress-linear__determinate",E?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:_.value})])]})),{}}}),Gp=de({loading:[Boolean,String]},"loader");function Rd(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:di();return{loaderClasses:ae(()=>({[`${t}--loading`]:e.loading}))}}function Kp(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(su,{absolute:e.absolute,active:e.active,color:e.color,height:"2",indeterminate:!0},null)])}const ZF=["static","relative","fixed","absolute","sticky"],Cu=de({position:{type:String,validator:e=>ZF.includes(e)}},"position");function Tu(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:di();return{positionClasses:ae(()=>e.position?`${t}--${e.position}`:void 0)}}function eN(){const e=an("useRoute");return A(()=>{var t;return(t=e==null?void 0:e.proxy)==null?void 0:t.$route})}function oP(){var e,t;return(t=(e=an("useRouter"))==null?void 0:e.proxy)==null?void 0:t.$router}function Yp(e,t){var c,d;const n=tL("RouterLink"),r=ae(()=>!!(e.href||e.to)),s=A(()=>(r==null?void 0:r.value)||US(t,"click")||US(e,"click"));if(typeof n=="string"||!("useLink"in n)){const f=ae(()=>e.href);return{isLink:r,isClickable:s,href:f,linkProps:cn({href:f})}}const i=n.useLink({to:ae(()=>e.to||""),replace:ae(()=>e.replace)}),o=A(()=>e.to?i:void 0),a=eN(),l=A(()=>{var f,p,g;return o.value?e.exact?a.value?((g=o.value.isExactActive)==null?void 0:g.value)&&as(o.value.route.value.query,a.value.query):((p=o.value.isExactActive)==null?void 0:p.value)??!1:((f=o.value.isActive)==null?void 0:f.value)??!1:!1}),u=A(()=>{var f;return e.to?(f=o.value)==null?void 0:f.route.value.href:e.href});return{isLink:r,isClickable:s,isActive:l,route:(c=o.value)==null?void 0:c.route,navigate:(d=o.value)==null?void 0:d.navigate,href:u,linkProps:cn({href:u,"aria-current":ae(()=>l.value?"page":void 0)})}}const Xp=de({href:String,replace:Boolean,to:[String,Object],exact:Boolean},"router");let fg=!1;function tN(e,t){let n=!1,r,s;Et&&(e!=null&&e.beforeEach)&&(Mt(()=>{window.addEventListener("popstate",i),r=e.beforeEach((o,a,l)=>{fg?n?t(l):l():setTimeout(()=>n?t(l):l()),fg=!0}),s=e==null?void 0:e.afterEach(()=>{fg=!1})}),yn(()=>{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 nN(e,t){Ee(()=>{var n;return(n=e.isActive)==null?void 0:n.value},n=>{e.isLink.value&&n&&t&&Mt(()=>{t(!0)})},{immediate:!0})}const zv=Symbol("rippleStop"),rN=80;function c1(e,t){e.style.transform=t,e.style.webkitTransform=t}function Hv(e){return e.constructor.name==="TouchEvent"}function aP(e){return e.constructor.name==="KeyboardEvent"}const sN=function(e,t){var d;let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=0,s=0;if(!aP(e)){const f=t.getBoundingClientRect(),p=Hv(e)?e.touches[e.touches.length-1]:e;r=p.clientX-f.left,s=p.clientY-f.top}let i=0,o=.3;(d=t._ripple)!=null&&d.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`,c=n.center?l:`${s-i}px`;return{radius:i,scale:o,x:u,y:c,centerX:a,centerY:l}},Vh={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:c}=sN(e,t,n),d=`${i*2}px`;s.className="v-ripple__animation",s.style.width=d,s.style.height=d,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"),c1(s,`translate(${a}, ${l}) scale3d(${o},${o},${o})`),s.dataset.activated=String(performance.now()),requestAnimationFrame(()=>{requestAnimationFrame(()=>{s.classList.remove("v-ripple__animation--enter"),s.classList.add("v-ripple__animation--in"),c1(s,`translate(${u}, ${c}) scale3d(1,1,1)`)})})},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 lP(e){return typeof e>"u"||!!e}function Kc(e){const t={},n=e.currentTarget;if(!(!(n!=null&&n._ripple)||n._ripple.touched||e[zv])){if(e[zv]=!0,Hv(e))n._ripple.touched=!0,n._ripple.isTouch=!0;else if(n._ripple.isTouch)return;if(t.center=n._ripple.centered||aP(e),n._ripple.class&&(t.class=n._ripple.class),Hv(e)){if(n._ripple.showTimerCommit)return;n._ripple.showTimerCommit=()=>{Vh.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)},rN)}else Vh.show(e,n,t)}}function d1(e){e[zv]=!0}function Vr(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(()=>{Vr(e)});return}window.setTimeout(()=>{t._ripple&&(t._ripple.touched=!1)}),Vh.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 Yc=!1;function cP(e){!Yc&&(e.keyCode===$S.enter||e.keyCode===$S.space)&&(Yc=!0,Kc(e))}function dP(e){Yc=!1,Vr(e)}function fP(e){Yc&&(Yc=!1,Vr(e))}function hP(e,t,n){const{value:r,modifiers:s}=t,i=lP(r);if(i||Vh.hide(e),e._ripple=e._ripple??{},e._ripple.enabled=i,e._ripple.centered=s.center,e._ripple.circle=s.circle,Mh(r)&&r.class&&(e._ripple.class=r.class),i&&!n){if(s.stop){e.addEventListener("touchstart",d1,{passive:!0}),e.addEventListener("mousedown",d1);return}e.addEventListener("touchstart",Kc,{passive:!0}),e.addEventListener("touchend",Vr,{passive:!0}),e.addEventListener("touchmove",uP,{passive:!0}),e.addEventListener("touchcancel",Vr),e.addEventListener("mousedown",Kc),e.addEventListener("mouseup",Vr),e.addEventListener("mouseleave",Vr),e.addEventListener("keydown",cP),e.addEventListener("keyup",dP),e.addEventListener("blur",fP),e.addEventListener("dragstart",Vr,{passive:!0})}else!i&&n&&pP(e)}function pP(e){e.removeEventListener("mousedown",Kc),e.removeEventListener("touchstart",Kc),e.removeEventListener("touchend",Vr),e.removeEventListener("touchmove",uP),e.removeEventListener("touchcancel",Vr),e.removeEventListener("mouseup",Vr),e.removeEventListener("mouseleave",Vr),e.removeEventListener("keydown",cP),e.removeEventListener("keyup",dP),e.removeEventListener("dragstart",Vr),e.removeEventListener("blur",fP)}function iN(e,t){hP(e,t,!1)}function oN(e){delete e._ripple,pP(e)}function aN(e,t){if(t.value===t.oldValue)return;const n=lP(t.oldValue);hP(e,t,n)}const Pu={mounted:iN,unmounted:oN,updated:aN},mP=de({active:{type:Boolean,default:void 0},activeColor:String,baseColor:String,symbol:{type:null,default:JT},flat:Boolean,icon:[Boolean,String,Function,Object],prependIcon:He,appendIcon:He,block:Boolean,readonly:Boolean,slim:Boolean,stacked:Boolean,ripple:{type:[Boolean,Object],default:!0},text:{type:[String,Number,Boolean],default:void 0},...vs(),...Ue(),...Ar(),...Or(),...bs(),...Cd(),...Gp(),...jo(),...Cu(),...Dn(),...Xp(),...Eu(),...yt({tag:"button"}),...Lt(),...$s({variant:"elevated"})},"VBtn"),se=ke()({name:"VBtn",props:mP(),emits:{"group:selected":e=>!0},setup(e,t){let{attrs:n,slots:r}=t;const{themeClasses:s}=Zt(e),{borderClasses:i}=Ds(e),{densityClasses:o}=ys(e),{dimensionStyles:a}=Mr(e),{elevationClasses:l}=Ls(e),{loaderClasses:u}=Rd(e),{locationStyles:c}=el(e),{positionClasses:d}=Tu(e),{roundedClasses:f}=zn(e),{sizeClasses:p,sizeStyles:g}=Pd(e),m=Td(e,e.symbol,!1),y=Yp(e,n),w=A(()=>{var O;return e.active!==void 0?e.active:y.isLink.value?(O=y.isActive)==null?void 0:O.value:m==null?void 0:m.isSelected.value}),b=ae(()=>w.value?e.activeColor??e.color:e.color),k=A(()=>{var R,M;return{color:(m==null?void 0:m.isSelected.value)&&(!y.isLink.value||((R=y.isActive)==null?void 0:R.value))||!m||((M=y.isActive)==null?void 0:M.value)?b.value??e.baseColor:e.baseColor,variant:e.variant}}),{colorClasses:C,colorStyles:_,variantClasses:T}=Za(k),P=A(()=>(m==null?void 0:m.disabled.value)||e.disabled),S=ae(()=>e.variant==="elevated"&&!(e.disabled||e.flat||e.border)),E=A(()=>{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(O){var R;P.value||y.isLink.value&&(O.metaKey||O.ctrlKey||O.shiftKey||O.button!==0||n.target==="_blank")||((R=y.navigate)==null||R.call(y,O),m==null||m.toggle())}return nN(y,m==null?void 0:m.select),Oe(()=>{const O=y.isLink.value?"a":e.tag,R=!!(e.prependIcon||r.prepend),M=!!(e.appendIcon||r.append),D=!!(e.icon&&e.icon!==!0);return Bt(h(O,ge({type:O==="a"?void 0:"button",class:["v-btn",m==null?void 0:m.selectedClass.value,{"v-btn--active":w.value,"v-btn--block":e.block,"v-btn--disabled":P.value,"v-btn--elevated":S.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,C.value,o.value,l.value,u.value,d.value,f.value,p.value,T.value,e.class],style:[_.value,a.value,c.value,g.value,e.style],"aria-busy":e.loading?!0:void 0,disabled:P.value||void 0,tabindex:e.loading||e.readonly?-1:void 0,onClick:I,value:E.value},y.linkProps),{default:()=>{var F;return[Ho(!0,"v-btn"),!e.icon&&R&&h("span",{key:"prepend",class:"v-btn__prepend"},[r.prepend?h(Ot,{key:"prepend-defaults",disabled:!e.prependIcon,defaults:{VIcon:{icon:e.prependIcon}}},r.prepend):h(J,{key:"prepend-icon",icon:e.prependIcon},null)]),h("span",{class:"v-btn__content","data-no-activator":""},[!r.default&&D?h(J,{key:"content-icon",icon:e.icon},null):h(Ot,{key:"content-defaults",disabled:!D,defaults:{VIcon:{icon:e.icon}}},{default:()=>{var U;return[((U=r.default)==null?void 0:U.call(r))??re(e.text)]}})]),!e.icon&&M&&h("span",{key:"append",class:"v-btn__append"},[r.append?h(Ot,{key:"append-defaults",disabled:!e.appendIcon,defaults:{VIcon:{icon:e.appendIcon}}},r.append):h(J,{key:"append-icon",icon:e.appendIcon},null)]),!!e.loading&&h("span",{key:"loader",class:"v-btn__loader"},[((F=r.loader)==null?void 0:F.call(r))??h(ni,{color:typeof e.loading=="boolean"?void 0:e.loading,indeterminate:!0,width:"2"},null)])]}}),[[Pu,!P.value&&e.ripple,"",{center:!!e.icon}]])}),{group:m}}}),lN=de({disabled:Boolean,group:Boolean,hideOnLeave:Boolean,leaveAbsolute:Boolean,mode:String,origin:String},"transition");function Kr(e,t,n){return ke()({name:e,props:lN({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:c,offsetHeight:d}=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=`${c}px`,a.style.height=`${d}px`}r.hideOnLeave&&a.style.setProperty("display","none","important")},onAfterLeave(a){if(r.leaveAbsolute&&(a!=null&&a._transitionInitialStyles)){const{position:l,top:u,left:c,width:d,height:f}=a._transitionInitialStyles;delete a._transitionInitialStyles,a.style.position=l||"",a.style.top=u||"",a.style.left=c||"",a.style.width=d||"",a.style.height=f||""}}};return()=>{const a=r.group?qb:Oo;return pr(a,{name:r.disabled?"":e,css:!r.disabled,...r.group?void 0:{mode:r.mode},...r.disabled?{}:o},i.default)}}})}function gP(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"in-out";return ke()({name:e,props:{mode:{type:String,default:n},disabled:Boolean,group:Boolean},setup(r,s){let{slots:i}=s;const o=r.group?qb:Oo;return()=>pr(o,{name:r.disabled?"":e,css:!r.disabled,...r.disabled?{}:t},i.default)}})}function vP(){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=Rr(`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;if(!a)return;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){if(!o._initialStyle)return;const a=o._initialStyle[n];o.style.overflow=o._initialStyle.overflow,a!=null&&(o.style[n]=a),delete o._initialStyle}}const uN=de({target:[Object,Array]},"v-dialog-transition"),hg=new WeakMap,t0=ke()({name:"VDialogTransition",props:uN(),setup(e,t){let{slots:n}=t;const r={onBeforeEnter(s){s.style.pointerEvents="none",s.style.visibility="hidden"},async onEnter(s,i){var p;await new Promise(g=>requestAnimationFrame(g)),await new Promise(g=>requestAnimationFrame(g)),s.style.visibility="";const o=h1(e.target,s),{x:a,y:l,sx:u,sy:c,speed:d}=o;hg.set(s,o);const f=Cl(s,[{transform:`translate(${a}px, ${l}px) scale(${u}, ${c})`,opacity:0},{}],{duration:225*d,easing:bF});(p=f1(s))==null||p.forEach(g=>{Cl(g,[{opacity:0},{opacity:0,offset:.33},{}],{duration:225*2*d,easing:Fh})}),f.finished.then(()=>i())},onAfterEnter(s){s.style.removeProperty("pointer-events")},onBeforeLeave(s){s.style.pointerEvents="none"},async onLeave(s,i){var p;await new Promise(g=>requestAnimationFrame(g));let o;!hg.has(s)||Array.isArray(e.target)||e.target.offsetParent||e.target.getClientRects().length?o=h1(e.target,s):o=hg.get(s);const{x:a,y:l,sx:u,sy:c,speed:d}=o;Cl(s,[{},{transform:`translate(${a}px, ${l}px) scale(${u}, ${c})`,opacity:0}],{duration:125*d,easing:wF}).finished.then(()=>i()),(p=f1(s))==null||p.forEach(g=>{Cl(g,[{},{opacity:0,offset:.2},{opacity:0}],{duration:125*2*d,easing:Fh})})},onAfterLeave(s){s.style.removeProperty("pointer-events")}};return()=>e.target?h(Oo,ge({name:"dialog-transition"},r,{css:!1}),n):h(Oo,{name:"dialog-transition"},n)}});function f1(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 h1(e,t){const n=UT(e),r=Xb(t),[s,i]=getComputedStyle(t).transformOrigin.split(" ").map(w=>parseFloat(w)),[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 c=n.width/r.width,d=n.height/r.height,f=Math.max(1,c,d),p=c/f||0,g=d/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}}Kr("fab-transition","center center","out-in");Kr("dialog-bottom-transition");Kr("dialog-top-transition");const p1=Kr("fade-transition"),cN=Kr("scale-transition");Kr("scroll-x-transition");Kr("scroll-x-reverse-transition");const dN=Kr("scroll-y-transition");Kr("scroll-y-reverse-transition");Kr("slide-x-transition");Kr("slide-x-reverse-transition");const yP=Kr("slide-y-transition");Kr("slide-y-reverse-transition");const bP=gP("expand-transition",vP()),wP=gP("expand-x-transition",vP("",!0));function pg(e,t){return{x:e.x+t.x,y:e.y+t.y}}function fN(e,t){return{x:e.x-t.x,y:e.y-t.y}}function m1(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 pg({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 pg({x:s,y:i},t)}return pg({x:t.width/2,y:t.height/2},t)}const SP={static:mN,connected:vN},hN=de({locationStrategy:{type:[String,Function],default:"static",validator:e=>typeof e=="function"||e in SP},location:{type:String,default:"bottom"},origin:{type:String,default:"auto"},offset:[Number,String,Array]},"VOverlay-location-strategies");function pN(e,t){const n=j({}),r=j();Et&&Hr(()=>!!(t.isActive.value&&e.locationStrategy),i=>{var o,a;Ee(()=>e.locationStrategy,i),yn(()=>{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=SP[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 mN(){}function gN(e,t){const n=Xb(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 vN(e,t,n){(Array.isArray(e.target.value)||_F(e.target.value))&&Object.assign(n.value,{position:"fixed",top:0,[e.isRtl.value?"right":"left"]:0});const{preferredAnchor:s,preferredOrigin:i}=Yb(()=>{const w=Nv(t.location,e.isRtl.value),b=t.origin==="overlap"?w:t.origin==="auto"?ug(w):Nv(t.origin,e.isRtl.value);return w.side===b.side&&w.align===cg(b).align?{preferredAnchor:HS(w),preferredOrigin:HS(b)}:{preferredAnchor:w,preferredOrigin:b}}),[o,a,l,u]=["minWidth","minHeight","maxWidth","maxHeight"].map(w=>A(()=>{const b=parseFloat(t[w]);return isNaN(b)?1/0:b})),c=A(()=>{if(Array.isArray(t.offset))return t.offset;if(typeof t.offset=="string"){const w=t.offset.split(" ").map(parseFloat);return w.length<2&&w.push(0),w}return typeof t.offset=="number"?[t.offset,0]:[0,0]});let d=!1,f=-1;const p=new LT(4),g=new ResizeObserver(()=>{if(!d)return;if(requestAnimationFrame(b=>{b!==f&&p.clear(),requestAnimationFrame(k=>{f=k})}),p.isFull){const b=p.values();if(as(b.at(-1),b.at(-3)))return}const w=y();w&&p.push(w.flipped)});Ee([e.target,e.contentEl],(w,b)=>{let[k,C]=w,[_,T]=b;_&&!Array.isArray(_)&&g.unobserve(_),k&&!Array.isArray(k)&&g.observe(k),T&&g.unobserve(T),C&&g.observe(C)},{immediate:!0}),yn(()=>{g.disconnect()});let m=new So({x:0,y:0,width:0,height:0});function y(){if(d=!1,requestAnimationFrame(()=>d=!0),!e.target.value||!e.contentEl.value)return;(Array.isArray(e.target.value)||e.target.value.offsetParent||e.target.value.getClientRects().length)&&(m=UT(e.target.value));const w=gN(e.contentEl.value,e.isRtl.value),b=Nh(e.contentEl.value),k=12;b.length||(b.push(document.documentElement),e.contentEl.value.style.top&&e.contentEl.value.style.left||(w.x-=parseFloat(document.documentElement.style.getPropertyValue("--v-body-scroll-x")||0),w.y-=parseFloat(document.documentElement.style.getPropertyValue("--v-body-scroll-y")||0)));const C=b.reduce((M,D)=>{const F=D.getBoundingClientRect(),U=new So({x:D===document.documentElement?0:F.x,y:D===document.documentElement?0:F.y,width:D.clientWidth,height:D.clientHeight});return M?new So({x:Math.max(M.left,U.left),y:Math.max(M.top,U.top),width:Math.min(M.right,U.right)-Math.max(M.left,U.left),height:Math.min(M.bottom,U.bottom)-Math.max(M.top,U.top)}):U},void 0);C.x+=k,C.y+=k,C.width-=k*2,C.height-=k*2;let _={anchor:s.value,origin:i.value};function T(M){const D=new So(w),F=m1(M.anchor,m),U=m1(M.origin,D);let{x:K,y:X}=fN(F,U);switch(M.anchor.side){case"top":X-=c.value[0];break;case"bottom":X+=c.value[0];break;case"left":K-=c.value[0];break;case"right":K+=c.value[0];break}switch(M.anchor.align){case"top":X-=c.value[1];break;case"bottom":X+=c.value[1];break;case"left":K-=c.value[1];break;case"right":K+=c.value[1];break}return D.x+=K,D.y+=X,D.width=Math.min(D.width,l.value),D.height=Math.min(D.height,u.value),{overflows:qS(D,C),x:K,y:X}}let P=0,S=0;const E={x:0,y:0},I={x:!1,y:!1};let O=-1;for(;!(O++>10);){const{x:M,y:D,overflows:F}=T(_);P+=M,S+=D,w.x+=M,w.y+=D;{const U=jS(_.anchor),K=F.x.before||F.x.after,X=F.y.before||F.y.after;let H=!1;if(["x","y"].forEach(B=>{if(B==="x"&&K&&!I.x||B==="y"&&X&&!I.y){const ee={anchor:{..._.anchor},origin:{..._.origin}},q=B==="x"?U==="y"?cg:ug:U==="y"?ug:cg;ee.anchor=q(ee.anchor),ee.origin=q(ee.origin);const{overflows:G}=T(ee);(G[B].before<=F[B].before&&G[B].after<=F[B].after||G[B].before+G[B].after<(F[B].before+F[B].after)/2)&&(_=ee,H=I[B]=!0)}}),H)continue}F.x.before&&(P+=F.x.before,w.x+=F.x.before),F.x.after&&(P-=F.x.after,w.x-=F.x.after),F.y.before&&(S+=F.y.before,w.y+=F.y.before),F.y.after&&(S-=F.y.after,w.y-=F.y.after);{const U=qS(w,C);E.x=C.width-U.x.before-U.x.after,E.y=C.height-U.y.before-U.y.after,P+=U.x.before,w.x+=U.x.before,S+=U.y.before,w.y+=U.y.before}break}const R=jS(_.anchor);return Object.assign(n.value,{"--v-overlay-anchor-origin":`${_.anchor.side} ${_.anchor.align}`,transformOrigin:`${_.origin.side} ${_.origin.align}`,top:Ne(mg(S)),left:e.isRtl.value?void 0:Ne(mg(P)),right:e.isRtl.value?Ne(mg(-P)):void 0,minWidth:Ne(R==="y"?Math.min(o.value,m.width):o.value),maxWidth:Ne(g1(Cr(E.x,o.value===1/0?0:o.value,l.value))),maxHeight:Ne(g1(Cr(E.y,a.value===1/0?0:a.value,u.value)))}),{available:E,contentBox:w,flipped:I}}return Ee(()=>[s.value,i.value,t.offset,t.minWidth,t.minHeight,t.maxWidth,t.maxHeight],()=>y()),Mt(()=>{const w=y();if(!w)return;const{available:b,contentBox:k}=w;k.height>b.y&&requestAnimationFrame(()=>{y(),requestAnimationFrame(()=>{y()})})}),{updateLocation:y}}function mg(e){return Math.round(e*devicePixelRatio)/devicePixelRatio}function g1(e){return Math.ceil(e*devicePixelRatio)/devicePixelRatio}let jv=!0;const Uh=[];function yN(e){!jv||Uh.length?(Uh.push(e),qv()):(jv=!1,e(),qv())}let v1=-1;function qv(){cancelAnimationFrame(v1),v1=requestAnimationFrame(()=>{const e=Uh.shift();e&&e(),Uh.length?qv():jv=!0})}const Yf={none:null,close:SN,block:_N,reposition:kN},bN=de({scrollStrategy:{type:[String,Function],default:"block",validator:e=>typeof e=="function"||e in Yf}},"VOverlay-scroll-strategies");function wN(e,t){if(!Et)return;let n;On(async()=>{n==null||n.stop(),t.isActive.value&&e.scrollStrategy&&(n=$a(),await new Promise(r=>setTimeout(r)),n.active&&n.run(()=>{var r;typeof e.scrollStrategy=="function"?e.scrollStrategy(t,e,n):(r=Yf[e.scrollStrategy])==null||r.call(Yf,t,e,n)}))}),yn(()=>{n==null||n.stop()})}function SN(e){function t(n){e.isActive.value=!1}_P(e.targetEl.value??e.contentEl.value,t)}function _N(e,t){var o;const n=(o=e.root.value)==null?void 0:o.offsetParent,r=[...new Set([...Nh(e.targetEl.value,t.contained?n:void 0),...Nh(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=>Zb(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")}),yn(()=>{r.forEach((a,l)=>{const u=parseFloat(a.style.getPropertyValue("--v-body-scroll-x")),c=parseFloat(a.style.getPropertyValue("--v-body-scroll-y")),d=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=-c,a.style.scrollBehavior=d}),i&&e.root.value.classList.remove("v-overlay--scroll-blocked")})}function kN(e,t,n){let r=!1,s=-1,i=-1;function o(a){yN(()=>{var c,d;const l=performance.now();(d=(c=e.updateLocation).value)==null||d.call(c,a),r=(performance.now()-l)/(1e3/60)>2})}i=(typeof requestIdleCallback>"u"?a=>a():requestIdleCallback)(()=>{n.run(()=>{_P(e.targetEl.value??e.contentEl.value,a=>{r?(cancelAnimationFrame(s),s=requestAnimationFrame(()=>{s=requestAnimationFrame(()=>{o(a)})})):o(a)})})}),yn(()=>{typeof cancelIdleCallback<"u"&&cancelIdleCallback(i),cancelAnimationFrame(s)})}function _P(e,t){const n=[document,...Nh(e)];n.forEach(r=>{r.addEventListener("scroll",t,{passive:!0})}),yn(()=>{n.forEach(r=>{r.removeEventListener("scroll",t)})})}const Wv=Symbol.for("vuetify:v-menu"),n0=de({closeDelay:[Number,String],openDelay:[Number,String]},"delay");function r0(e,t){let n=()=>{};function r(o){n==null||n();const a=Number(o?e.openDelay:e.closeDelay);return new Promise(l=>{n=U$(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 xN=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,...n0()},"VOverlay-activator");function EN(e,t){let{isActive:n,isTop:r,contentEl:s}=t;const i=an("useActivator"),o=j();let a=!1,l=!1,u=!0;const c=A(()=>e.openOnFocus||e.openOnFocus==null&&e.openOnHover),d=A(()=>e.openOnClick||e.openOnClick==null&&!e.openOnHover&&!c.value),{runOpenDelay:f,runCloseDelay:p}=r0(e,S=>{S===(e.openOnHover&&a||c.value&&l)&&!(e.openOnHover&&n.value&&!r.value)&&(n.value!==S&&(u=!0),n.value=S)}),g=j(),m={onClick:S=>{S.stopPropagation(),o.value=S.currentTarget||S.target,n.value||(g.value=[S.clientX,S.clientY]),n.value=!n.value},onMouseenter:S=>{var E;(E=S.sourceCapabilities)!=null&&E.firesTouchEvents||(a=!0,o.value=S.currentTarget||S.target,f())},onMouseleave:S=>{a=!1,p()},onFocus:S=>{Lh(S.target,":focus-visible")!==!1&&(l=!0,S.stopPropagation(),o.value=S.currentTarget||S.target,f())},onBlur:S=>{l=!1,S.stopPropagation(),p()}},y=A(()=>{const S={};return d.value&&(S.onClick=m.onClick),e.openOnHover&&(S.onMouseenter=m.onMouseenter,S.onMouseleave=m.onMouseleave),c.value&&(S.onFocus=m.onFocus,S.onBlur=m.onBlur),S}),w=A(()=>{const S={};if(e.openOnHover&&(S.onMouseenter=()=>{a=!0,f()},S.onMouseleave=()=>{a=!1,p()}),c.value&&(S.onFocusin=()=>{l=!0,f()},S.onFocusout=()=>{l=!1,p()}),e.closeOnContentClick){const E=Qe(Wv,null);S.onClick=()=>{n.value=!1,E==null||E.closeParents()}}return S}),b=A(()=>{const S={};return e.openOnHover&&(S.onMouseenter=()=>{u&&(a=!0,u=!1,f())},S.onMouseleave=()=>{a=!1,p()}),S});Ee(r,S=>{var E;S&&(e.openOnHover&&!a&&(!c.value||!l)||c.value&&!l&&(!e.openOnHover||!a))&&!((E=s.value)!=null&&E.contains(document.activeElement))&&(n.value=!1)}),Ee(n,S=>{S||setTimeout(()=>{g.value=void 0})},{flush:"post"});const k=Fv();On(()=>{k.value&&Mt(()=>{o.value=k.el})});const C=Fv(),_=A(()=>e.target==="cursor"&&g.value?g.value:C.value?C.el:kP(e.target,i)||o.value),T=A(()=>Array.isArray(_.value)?void 0:_.value);let P;return Ee(()=>!!e.activator,S=>{S&&Et?(P=$a(),P.run(()=>{CN(e,i,{activatorEl:o,activatorEvents:y})})):P&&P.stop()},{flush:"post",immediate:!0}),yn(()=>{P==null||P.stop()}),{activatorEl:o,activatorRef:k,target:_,targetEl:T,targetRef:C,activatorEvents:y,contentEvents:w,scrimEvents:b}}function CN(e,t,n){let{activatorEl:r,activatorEvents:s}=n;Ee(()=>e.activator,(l,u)=>{if(u&&l!==u){const c=a(u);c&&o(c)}l&&Mt(()=>i())},{immediate:!0}),Ee(()=>e.activatorProps,()=>{i()}),yn(()=>{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&&j$(l,ge(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&&q$(l,ge(s.value,u))}function a(){let l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:e.activator;const u=kP(l,t);return r.value=(u==null?void 0:u.nodeType)===Node.ELEMENT_NODE?u:void 0,r.value}}function kP(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 Qp=["sm","md","lg","xl","xxl"],Gv=Symbol.for("vuetify:display"),y1={mobileBreakpoint:"lg",thresholds:{xs:0,sm:600,md:960,lg:1280,xl:1920,xxl:2560}},TN=function(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:y1;return Zn(y1,e)};function b1(e){return Et&&!e?window.innerWidth:typeof e=="object"&&e.clientWidth||0}function w1(e){return Et&&!e?window.innerHeight:typeof e=="object"&&e.clientHeight||0}function S1(e){const t=Et&&!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),c=n(/opera/i),d=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:c,win:d,mac:f,linux:p,touch:$$,ssr:t==="ssr"}}function PN(e,t){const{thresholds:n,mobileBreakpoint:r}=TN(e),s=Ie(w1(t)),i=Ie(S1(t)),o=cn({}),a=Ie(b1(t));function l(){s.value=w1(),a.value=b1()}function u(){l(),i.value=S1()}return On(()=>{const c=a.value<n.sm,d=a.value<n.md&&!c,f=a.value<n.lg&&!(d||c),p=a.value<n.xl&&!(f||d||c),g=a.value<n.xxl&&!(p||f||d||c),m=a.value>=n.xxl,y=c?"xs":d?"sm":f?"md":p?"lg":g?"xl":"xxl",w=typeof r=="number"?r:n[r],b=a.value<w;o.xs=c,o.sm=d,o.md=f,o.lg=p,o.xl=g,o.xxl=m,o.smAndUp=!c,o.mdAndUp=!(c||d),o.lgAndUp=!(c||d||f),o.xlAndUp=!(c||d||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=b,o.mobileBreakpoint=r,o.platform=i.value,o.thresholds=n}),Et&&(window.addEventListener("resize",l,{passive:!0}),yn(()=>{window.removeEventListener("resize",l)},!0)),{...Qa(o),update:u,ssr:!!t}}const tl=de({mobile:{type:Boolean,default:!1},mobileBreakpoint:[Number,String]},"display");function fi(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{mobile:null},t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:di();const n=Qe(Gv);if(!n)throw new Error("Could not find Vuetify display injection");const r=A(()=>e.mobile?!0:typeof e.mobileBreakpoint=="number"?n.width.value<e.mobileBreakpoint:e.mobileBreakpoint?n.width.value<n.thresholds.value[e.mobileBreakpoint]:e.mobile===null?n.mobile.value:!1),s=ae(()=>t?{[`${t}--mobile`]:r.value}:{});return{...n,displayClasses:s,mobile:r}}function RN(){if(!Et)return Ie(!1);const{ssr:e}=fi();if(e){const t=Ie(!1);return St(()=>{t.value=!0}),t}else return Ie(!0)}const xP=de({eager:Boolean},"lazy");function EP(e,t){const n=Ie(!1),r=ae(()=>n.value||e.eager||t.value);Ee(t,()=>n.value=!0);function s(){e.eager||(n.value=!1)}return{isBooted:n,hasContent:r,onAfterLeave:s}}function Ru(){const t=an("useScopeId").vnode.scopeId;return{scopeId:t?{[t]:""}:void 0}}const _1=Symbol.for("vuetify:stack"),Zu=cn([]);function IN(e,t,n){const r=an("useStack"),s=!n,i=Qe(_1,void 0),o=cn({activeChildren:new Set});Kt(_1,o);const a=Ie(Number(Nn(t)));Hr(e,()=>{var d;const c=(d=Zu.at(-1))==null?void 0:d[1];a.value=c?c+10:Number(Nn(t)),s&&Zu.push([r.uid,a.value]),i==null||i.activeChildren.add(r.uid),yn(()=>{if(s){const f=Be(Zu).findIndex(p=>p[0]===r.uid);Zu.splice(f,1)}i==null||i.activeChildren.delete(r.uid)})});const l=Ie(!0);s&&On(()=>{var d;const c=((d=Zu.at(-1))==null?void 0:d[0])===r.uid;setTimeout(()=>l.value=c)});const u=ae(()=>!o.activeChildren.size);return{globalTop:zo(l),localTop:u,stackStyles:ae(()=>({zIndex:a.value}))}}function AN(e){return{teleportTarget:A(()=>{const n=e();if(n===!0||!Et)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 Iu=de({transition:{type:null,default:"fade-transition",validator:e=>e!==!0}},"transition"),si=(e,t)=>{let{slots:n}=t;const{transition:r,disabled:s,group:i,...o}=e,{component:a=i?qb:Oo,...l}=Mh(r)?r:{};let u;return Mh(r)?u=ge(l,JSON.parse(JSON.stringify({disabled:s,group:i})),o):u=ge({name:s||!r?"":r},o),pr(a,u,n)};function ON(){return!0}function CP(e,t,n){if(!e||TP(e,n)===!1)return!1;const r=GT(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 TP(e,t){return(typeof t.value=="object"&&t.value.closeConditional||ON)(e)}function MN(e,t,n){const r=typeof n.value=="function"?n.value:n.value.handler;e.shadowTarget=e.target,t._clickOutside.lastMousedownWasOutside&&CP(e,t,n)&&setTimeout(()=>{TP(e,n)&&r&&r(e)},0)}function k1(e,t){const n=GT(e);t(document),typeof ShadowRoot<"u"&&n instanceof ShadowRoot&&t(n)}const DN={mounted(e,t){const n=s=>MN(s,e,t),r=s=>{e._clickOutside.lastMousedownWasOutside=CP(s,e,t)};k1(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&&(k1(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 LN(e){const{modelValue:t,color:n,...r}=e;return h(Oo,{name:"fade-transition",appear:!0},{default:()=>[e.modelValue&&h("div",ge({class:["v-overlay__scrim",e.color.backgroundColorClasses.value],style:e.color.backgroundColorStyles.value},r),null)]})}const Id=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},...xN(),...Ue(),...Or(),...xP(),...hN(),...bN(),...Lt(),...Iu()},"VOverlay"),Bi=ke()({name:"VOverlay",directives:{ClickOutside:DN},inheritAttrs:!1,props:{_disableGlobalStack:Boolean,...Id()},emits:{"click:outside":e=>!0,"update:modelValue":e=>!0,keydown:e=>!0,afterEnter:()=>!0,afterLeave:()=>!0},setup(e,t){let{slots:n,attrs:r,emit:s}=t;const i=an("VOverlay"),o=j(),a=j(),l=j(),u=st(e,"modelValue"),c=A({get:()=>u.value,set:Z=>{Z&&e.disabled||(u.value=Z)}}),{themeClasses:d}=Zt(e),{rtlClasses:f,isRtl:p}=Dr(),{hasContent:g,onAfterLeave:m}=EP(e,c),y=fr(()=>typeof e.scrim=="string"?e.scrim:null),{globalTop:w,localTop:b,stackStyles:k}=IN(c,()=>e.zIndex,e._disableGlobalStack),{activatorEl:C,activatorRef:_,target:T,targetEl:P,targetRef:S,activatorEvents:E,contentEvents:I,scrimEvents:O}=EN(e,{isActive:c,isTop:b,contentEl:l}),{teleportTarget:R}=AN(()=>{var ne,z,xe;const Z=e.attach||e.contained;if(Z)return Z;const he=((ne=C==null?void 0:C.value)==null?void 0:ne.getRootNode())||((xe=(z=i.proxy)==null?void 0:z.$el)==null?void 0:xe.getRootNode());return he instanceof ShadowRoot?he:!1}),{dimensionStyles:M}=Mr(e),D=RN(),{scopeId:F}=Ru();Ee(()=>e.disabled,Z=>{Z&&(c.value=!1)});const{contentStyles:U,updateLocation:K}=pN(e,{isRtl:p,contentEl:l,target:T,isActive:c});wN(e,{root:o,contentEl:l,targetEl:P,isActive:c,updateLocation:K});function X(Z){s("click:outside",Z),e.persistent?le():c.value=!1}function H(Z){return c.value&&w.value&&(!e.scrim||Z.target===a.value||Z instanceof MouseEvent&&Z.shadowTarget===a.value)}Et&&Ee(c,Z=>{Z?window.addEventListener("keydown",B):window.removeEventListener("keydown",B)},{immediate:!0}),Cn(()=>{Et&&window.removeEventListener("keydown",B)});function B(Z){var he,ne,z;Z.key==="Escape"&&w.value&&((he=l.value)!=null&&he.contains(document.activeElement)||s("keydown",Z),e.persistent?le():(c.value=!1,(ne=l.value)!=null&&ne.contains(document.activeElement)&&((z=C.value)==null||z.focus())))}function ee(Z){Z.key==="Escape"&&!w.value||s("keydown",Z)}const q=oP();Hr(()=>e.closeOnBack,()=>{tN(q,Z=>{w.value&&c.value?(Z(!1),e.persistent?le():c.value=!1):Z()})});const G=j();Ee(()=>c.value&&(e.absolute||e.contained)&&R.value==null,Z=>{if(Z){const he=KT(o.value);he&&he!==document.scrollingElement&&(G.value=he.scrollTop)}});function le(){e.noClickAnimation||l.value&&Cl(l.value,[{transformOrigin:"center"},{transform:"scale(1.03)"},{transformOrigin:"center"}],{duration:150,easing:Fh})}function ie(){s("afterEnter")}function Se(){m(),s("afterLeave")}return Oe(()=>{var Z;return h(Ae,null,[(Z=n.activator)==null?void 0:Z.call(n,{isActive:c.value,targetRef:S,props:ge({ref:_},E.value,e.activatorProps)}),D.value&&g.value&&h(qD,{disabled:!R.value,to:R.value},{default:()=>[h("div",ge({class:["v-overlay",{"v-overlay--absolute":e.absolute||e.contained,"v-overlay--active":c.value,"v-overlay--contained":e.contained},d.value,f.value,e.class],style:[k.value,{"--v-overlay-opacity":e.opacity,top:Ne(G.value)},e.style],ref:o,onKeydown:ee},F,r),[h(LN,ge({color:y,modelValue:c.value&&!!e.scrim,ref:a},O.value),null),h(si,{appear:!0,persisted:!0,transition:e.transition,target:T.value,onAfterEnter:ie,onAfterLeave:Se},{default:()=>{var he;return[Bt(h("div",ge({ref:l,class:["v-overlay__content",e.contentClass],style:[M.value,U.value]},I.value,e.contentProps),[(he=n.default)==null?void 0:he.call(n,{isActive:c})]),[[Yi,c.value],[hr("click-outside"),{handler:X,closeConditional:H,include:()=>[C.value]}]])]}})])]})])}),{activatorEl:C,scrimEl:a,target:T,animateClick:le,contentEl:l,globalTop:w,localTop:b,updateLocation:K}}}),gg=Symbol("Forwarded refs");function vg(e,t){let n=e;for(;n;){const r=Reflect.getOwnPropertyDescriptor(n,t);if(r)return r;n=Object.getPrototypeOf(n)}}function Xi(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[gg]=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=vg(l.value,i)??("_"in l.value?vg((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[gg];if(!u)continue;const c=u.slice();for(;c.length;){const d=c.shift(),f=vg(d.value,i);if(f)return f;const p=d.value&&d.value[gg];p&&c.push(...p)}}}}})}const $N=de({fullscreen:Boolean,retainFocus:{type:Boolean,default:!0},scrollable:Boolean,...Id({origin:"center center",scrollStrategy:"block",transition:{component:t0},zIndex:2400})},"VDialog"),PP=ke()({name:"VDialog",props:$N(),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}=Ru(),o=j();function a(c){var p,g;const d=c.relatedTarget,f=c.target;if(d!==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=qc(o.value.contentEl);if(!m.length)return;const y=m[0],w=m[m.length-1];d===y?w.focus():y.focus()}}Cn(()=>{document.removeEventListener("focusin",a)}),Et&&Ee(()=>s.value&&e.retainFocus,c=>{c?document.addEventListener("focusin",a):document.removeEventListener("focusin",a)},{immediate:!0});function l(){var c;n("afterEnter"),(e.scrim||e.retainFocus)&&((c=o.value)!=null&&c.contentEl)&&!o.value.contentEl.contains(document.activeElement)&&o.value.contentEl.focus({preventScroll:!0})}function u(){n("afterLeave")}return Ee(s,async c=>{var d;c||(await Mt(),(d=o.value.activatorEl)==null||d.focus({preventScroll:!0}))}),Oe(()=>{const c=Bi.filterProps(e),d=ge({"aria-haspopup":"dialog"},e.activatorProps),f=ge({tabindex:-1},e.contentProps);return h(Bi,ge({ref:o,class:["v-dialog",{"v-dialog--fullscreen":e.fullscreen,"v-dialog--scrollable":e.scrollable},e.class],style:e.style},c,{modelValue:s.value,"onUpdate:modelValue":p=>s.value=p,"aria-modal":"true",activatorProps:d,contentProps:f,height:e.fullscreen?void 0:e.height,width:e.fullscreen?void 0:e.width,maxHeight:e.fullscreen?void 0:e.maxHeight,maxWidth:e.fullscreen?void 0:e.maxWidth,role:"dialog",onAfterEnter: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(Ot,{root:"VDialog"},{default:()=>{var y;return[(y=r.default)==null?void 0:y.call(r,...g)]}})}})}),Xi({},o)}}),FN={class:"pa-3 text--primary"},hi=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=PT(),s=t,i=tn(n.id);function o(c){return s("opened",c)}function a(c){return s("beforeOpened",c)}St(async()=>{L$("Escape",c=>{l.value&&(c.preventDefault(),u())}),r.registerDialogReference(n.id,{beforeOpenedCallback:a,openedCallback:o})}),Cn(()=>{r.unregisterDialogReference(n.id)});const l=A(()=>{if(!n.id)return;const c=r.isDialogOpened(n.id);return c&&console.debug(`[BaseDialog ${n.id}] Showing dialog: ${i==null?void 0:i.isDialogOpened()}`),c});function u(){s("escape")}return(c,d)=>($(),te(PP,{"max-width":e.maxWidth,"retain-focus":!1,"model-value":l.value,persistent:"",onClose:d[1]||(d[1]=f=>u())},{default:v(()=>[Vp(c.$slots,"default",{},()=>[L("div",FN,[d[4]||(d[4]=x(" No content defined in dialog. ")),h(se,{onClick:d[0]||(d[0]=f=>Q(i).closeDialog())},{default:v(()=>[h(J,{class:"mr-3"},{default:v(()=>d[2]||(d[2]=[x("close")])),_:1}),d[3]||(d[3]=x("Close "))]),_:1})])])]),_:3},8,["max-width","model-value"]))}});var nn=(e=>(e.ImportOctoFarmDialog="ImportOctoFarmDialog",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))(nn||{});function RP(e,t){return function(){return e.apply(t,arguments)}}const{toString:NN}=Object.prototype,{getPrototypeOf:s0}=Object,{iterator:Jp,toStringTag:IP}=Symbol,Zp=(e=>t=>{const n=NN.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),Fs=e=>(e=e.toLowerCase(),t=>Zp(t)===e),em=e=>t=>typeof t===e,{isArray:Au}=Array,Xc=em("undefined");function BN(e){return e!==null&&!Xc(e)&&e.constructor!==null&&!Xc(e.constructor)&&Tr(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const AP=Fs("ArrayBuffer");function VN(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&AP(e.buffer),t}const UN=em("string"),Tr=em("function"),OP=em("number"),tm=e=>e!==null&&typeof e=="object",zN=e=>e===!0||e===!1,Xf=e=>{if(Zp(e)!=="object")return!1;const t=s0(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(IP in e)&&!(Jp in e)},HN=Fs("Date"),jN=Fs("File"),qN=Fs("Blob"),WN=Fs("FileList"),GN=e=>tm(e)&&Tr(e.pipe),KN=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||Tr(e.append)&&((t=Zp(e))==="formdata"||t==="object"&&Tr(e.toString)&&e.toString()==="[object FormData]"))},YN=Fs("URLSearchParams"),[XN,QN,JN,ZN]=["ReadableStream","Request","Response","Headers"].map(Fs),eB=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Ad(e,t,{allOwnKeys:n=!1}={}){if(e===null||typeof e>"u")return;let r,s;if(typeof e!="object"&&(e=[e]),Au(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 MP(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 da=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,DP=e=>!Xc(e)&&e!==da;function Kv(){const{caseless:e}=DP(this)&&this||{},t={},n=(r,s)=>{const i=e&&MP(t,s)||s;Xf(t[i])&&Xf(r)?t[i]=Kv(t[i],r):Xf(r)?t[i]=Kv({},r):Au(r)?t[i]=r.slice():t[i]=r};for(let r=0,s=arguments.length;r<s;r++)arguments[r]&&Ad(arguments[r],n);return t}const tB=(e,t,n,{allOwnKeys:r}={})=>(Ad(t,(s,i)=>{n&&Tr(s)?e[i]=RP(s,n):e[i]=s},{allOwnKeys:r}),e),nB=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),rB=(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)},sB=(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&&s0(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},iB=(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},oB=e=>{if(!e)return null;if(Au(e))return e;let t=e.length;if(!OP(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},aB=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&s0(Uint8Array)),lB=(e,t)=>{const r=(e&&e[Jp]).call(e);let s;for(;(s=r.next())&&!s.done;){const i=s.value;t.call(e,i[0],i[1])}},uB=(e,t)=>{let n;const r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},cB=Fs("HTMLFormElement"),dB=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,s){return r.toUpperCase()+s}),x1=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),fB=Fs("RegExp"),LP=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};Ad(n,(s,i)=>{let o;(o=t(s,i,e))!==!1&&(r[i]=o||s)}),Object.defineProperties(e,r)},hB=e=>{LP(e,(t,n)=>{if(Tr(e)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const r=e[n];if(Tr(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+"'")})}})},pB=(e,t)=>{const n={},r=s=>{s.forEach(i=>{n[i]=!0})};return Au(e)?r(e):r(String(e).split(t)),n},mB=()=>{},gB=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function vB(e){return!!(e&&Tr(e.append)&&e[IP]==="FormData"&&e[Jp])}const yB=e=>{const t=new Array(10),n=(r,s)=>{if(tm(r)){if(t.indexOf(r)>=0)return;if(!("toJSON"in r)){t[s]=r;const i=Au(r)?[]:{};return Ad(r,(o,a)=>{const l=n(o,s+1);!Xc(l)&&(i[a]=l)}),t[s]=void 0,i}}return r};return n(e,0)},bB=Fs("AsyncFunction"),wB=e=>e&&(tm(e)||Tr(e))&&Tr(e.then)&&Tr(e.catch),$P=((e,t)=>e?setImmediate:t?((n,r)=>(da.addEventListener("message",({source:s,data:i})=>{s===da&&i===n&&r.length&&r.shift()()},!1),s=>{r.push(s),da.postMessage(n,"*")}))(`axios@${Math.random()}`,[]):n=>setTimeout(n))(typeof setImmediate=="function",Tr(da.postMessage)),SB=typeof queueMicrotask<"u"?queueMicrotask.bind(da):typeof process<"u"&&process.nextTick||$P,_B=e=>e!=null&&Tr(e[Jp]),ue={isArray:Au,isArrayBuffer:AP,isBuffer:BN,isFormData:KN,isArrayBufferView:VN,isString:UN,isNumber:OP,isBoolean:zN,isObject:tm,isPlainObject:Xf,isReadableStream:XN,isRequest:QN,isResponse:JN,isHeaders:ZN,isUndefined:Xc,isDate:HN,isFile:jN,isBlob:qN,isRegExp:fB,isFunction:Tr,isStream:GN,isURLSearchParams:YN,isTypedArray:aB,isFileList:WN,forEach:Ad,merge:Kv,extend:tB,trim:eB,stripBOM:nB,inherits:rB,toFlatObject:sB,kindOf:Zp,kindOfTest:Fs,endsWith:iB,toArray:oB,forEachEntry:lB,matchAll:uB,isHTMLForm:cB,hasOwnProperty:x1,hasOwnProp:x1,reduceDescriptors:LP,freezeMethods:hB,toObjectSet:pB,toCamelCase:dB,noop:mB,toFiniteNumber:gB,findKey:MP,global:da,isContextDefined:DP,isSpecCompliantForm:vB,toJSONObject:yB,isAsyncFn:bB,isThenable:wB,setImmediate:$P,asap:SB,isIterable:_B};function Ze(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)}ue.inherits(Ze,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:ue.toJSONObject(this.config),code:this.code,status:this.status}}});const FP=Ze.prototype,NP={};["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=>{NP[e]={value:e}});Object.defineProperties(Ze,NP);Object.defineProperty(FP,"isAxiosError",{value:!0});Ze.from=(e,t,n,r,s,i)=>{const o=Object.create(FP);return ue.toFlatObject(e,o,function(l){return l!==Error.prototype},a=>a!=="isAxiosError"),Ze.call(o,e.message,t,n,r,s),o.cause=e,o.name=e.name,i&&Object.assign(o,i),o};const kB=null;function Yv(e){return ue.isPlainObject(e)||ue.isArray(e)}function BP(e){return ue.endsWith(e,"[]")?e.slice(0,-2):e}function E1(e,t,n){return e?e.concat(t).map(function(s,i){return s=BP(s),!n&&i?"["+s+"]":s}).join(n?".":""):t}function xB(e){return ue.isArray(e)&&!e.some(Yv)}const EB=ue.toFlatObject(ue,{},null,function(t){return/^is[A-Z]/.test(t)});function nm(e,t,n){if(!ue.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=ue.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(m,y){return!ue.isUndefined(y[m])});const r=n.metaTokens,s=n.visitor||c,i=n.dots,o=n.indexes,l=(n.Blob||typeof Blob<"u"&&Blob)&&ue.isSpecCompliantForm(t);if(!ue.isFunction(s))throw new TypeError("visitor must be a function");function u(g){if(g===null)return"";if(ue.isDate(g))return g.toISOString();if(!l&&ue.isBlob(g))throw new Ze("Blob is not supported. Use a Buffer instead.");return ue.isArrayBuffer(g)||ue.isTypedArray(g)?l&&typeof Blob=="function"?new Blob([g]):Buffer.from(g):g}function c(g,m,y){let w=g;if(g&&!y&&typeof g=="object"){if(ue.endsWith(m,"{}"))m=r?m:m.slice(0,-2),g=JSON.stringify(g);else if(ue.isArray(g)&&xB(g)||(ue.isFileList(g)||ue.endsWith(m,"[]"))&&(w=ue.toArray(g)))return m=BP(m),w.forEach(function(k,C){!(ue.isUndefined(k)||k===null)&&t.append(o===!0?E1([m],C,i):o===null?m:m+"[]",u(k))}),!1}return Yv(g)?!0:(t.append(E1(y,m,i),u(g)),!1)}const d=[],f=Object.assign(EB,{defaultVisitor:c,convertValue:u,isVisitable:Yv});function p(g,m){if(!ue.isUndefined(g)){if(d.indexOf(g)!==-1)throw Error("Circular reference detected in "+m.join("."));d.push(g),ue.forEach(g,function(w,b){(!(ue.isUndefined(w)||w===null)&&s.call(t,w,ue.isString(b)?b.trim():b,m,f))===!0&&p(w,m?m.concat(b):[b])}),d.pop()}}if(!ue.isObject(e))throw new TypeError("data must be an object");return p(e),t}function C1(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(r){return t[r]})}function i0(e,t){this._pairs=[],e&&nm(e,this,t)}const VP=i0.prototype;VP.append=function(t,n){this._pairs.push([t,n])};VP.toString=function(t){const n=t?function(r){return t.call(this,r,C1)}:C1;return this._pairs.map(function(s){return n(s[0])+"="+n(s[1])},"").join("&")};function CB(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function UP(e,t,n){if(!t)return e;const r=n&&n.encode||CB;ue.isFunction(n)&&(n={serialize:n});const s=n&&n.serialize;let i;if(s?i=s(t,n):i=ue.isURLSearchParams(t)?t.toString():new i0(t,n).toString(r),i){const o=e.indexOf("#");o!==-1&&(e=e.slice(0,o)),e+=(e.indexOf("?")===-1?"?":"&")+i}return e}class T1{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){ue.forEach(this.handlers,function(r){r!==null&&t(r)})}}const zP={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},TB=typeof URLSearchParams<"u"?URLSearchParams:i0,PB=typeof FormData<"u"?FormData:null,RB=typeof Blob<"u"?Blob:null,IB={isBrowser:!0,classes:{URLSearchParams:TB,FormData:PB,Blob:RB},protocols:["http","https","file","blob","url","data"]},o0=typeof window<"u"&&typeof document<"u",Xv=typeof navigator=="object"&&navigator||void 0,AB=o0&&(!Xv||["ReactNative","NativeScript","NS"].indexOf(Xv.product)<0),OB=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",MB=o0&&window.location.href||"http://localhost",DB=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:o0,hasStandardBrowserEnv:AB,hasStandardBrowserWebWorkerEnv:OB,navigator:Xv,origin:MB},Symbol.toStringTag,{value:"Module"})),Jn={...DB,...IB};function LB(e,t){return nm(e,new Jn.classes.URLSearchParams,Object.assign({visitor:function(n,r,s,i){return Jn.isNode&&ue.isBuffer(n)?(this.append(r,n.toString("base64")),!1):i.defaultVisitor.apply(this,arguments)}},t))}function $B(e){return ue.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function FB(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 HP(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&&ue.isArray(s)?s.length:o,l?(ue.hasOwnProp(s,o)?s[o]=[s[o],r]:s[o]=r,!a):((!s[o]||!ue.isObject(s[o]))&&(s[o]=[]),t(n,r,s[o],i)&&ue.isArray(s[o])&&(s[o]=FB(s[o])),!a)}if(ue.isFormData(e)&&ue.isFunction(e.entries)){const n={};return ue.forEachEntry(e,(r,s)=>{t($B(r),s,n,0)}),n}return null}function NB(e,t,n){if(ue.isString(e))try{return(t||JSON.parse)(e),ue.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(0,JSON.stringify)(e)}const Od={transitional:zP,adapter:["xhr","http","fetch"],transformRequest:[function(t,n){const r=n.getContentType()||"",s=r.indexOf("application/json")>-1,i=ue.isObject(t);if(i&&ue.isHTMLForm(t)&&(t=new FormData(t)),ue.isFormData(t))return s?JSON.stringify(HP(t)):t;if(ue.isArrayBuffer(t)||ue.isBuffer(t)||ue.isStream(t)||ue.isFile(t)||ue.isBlob(t)||ue.isReadableStream(t))return t;if(ue.isArrayBufferView(t))return t.buffer;if(ue.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 LB(t,this.formSerializer).toString();if((a=ue.isFileList(t))||r.indexOf("multipart/form-data")>-1){const l=this.env&&this.env.FormData;return nm(a?{"files[]":t}:t,l&&new l,this.formSerializer)}}return i||s?(n.setContentType("application/json",!1),NB(t)):t}],transformResponse:[function(t){const n=this.transitional||Od.transitional,r=n&&n.forcedJSONParsing,s=this.responseType==="json";if(ue.isResponse(t)||ue.isReadableStream(t))return t;if(t&&ue.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"?Ze.from(a,Ze.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:Jn.classes.FormData,Blob:Jn.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};ue.forEach(["delete","get","head","post","put","patch"],e=>{Od.headers[e]={}});const BB=ue.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"]),VB=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]&&BB[n])&&(n==="set-cookie"?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)}),t},P1=Symbol("internals");function ec(e){return e&&String(e).trim().toLowerCase()}function Qf(e){return e===!1||e==null?e:ue.isArray(e)?e.map(Qf):String(e)}function UB(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 zB=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function yg(e,t,n,r,s){if(ue.isFunction(r))return r.call(this,t,n);if(s&&(t=n),!!ue.isString(t)){if(ue.isString(r))return t.indexOf(r)!==-1;if(ue.isRegExp(r))return r.test(t)}}function HB(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,n,r)=>n.toUpperCase()+r)}function jB(e,t){const n=ue.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 Pr=class{constructor(t){t&&this.set(t)}set(t,n,r){const s=this;function i(a,l,u){const c=ec(l);if(!c)throw new Error("header name must be a non-empty string");const d=ue.findKey(s,c);(!d||s[d]===void 0||u===!0||u===void 0&&s[d]!==!1)&&(s[d||l]=Qf(a))}const o=(a,l)=>ue.forEach(a,(u,c)=>i(u,c,l));if(ue.isPlainObject(t)||t instanceof this.constructor)o(t,n);else if(ue.isString(t)&&(t=t.trim())&&!zB(t))o(VB(t),n);else if(ue.isObject(t)&&ue.isIterable(t)){let a={},l,u;for(const c of t){if(!ue.isArray(c))throw TypeError("Object iterator must return a key-value pair");a[u=c[0]]=(l=a[u])?ue.isArray(l)?[...l,c[1]]:[l,c[1]]:c[1]}o(a,n)}else t!=null&&i(n,t,r);return this}get(t,n){if(t=ec(t),t){const r=ue.findKey(this,t);if(r){const s=this[r];if(!n)return s;if(n===!0)return UB(s);if(ue.isFunction(n))return n.call(this,s,r);if(ue.isRegExp(n))return n.exec(s);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,n){if(t=ec(t),t){const r=ue.findKey(this,t);return!!(r&&this[r]!==void 0&&(!n||yg(this,this[r],r,n)))}return!1}delete(t,n){const r=this;let s=!1;function i(o){if(o=ec(o),o){const a=ue.findKey(r,o);a&&(!n||yg(r,r[a],a,n))&&(delete r[a],s=!0)}}return ue.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||yg(this,this[i],i,t,!0))&&(delete this[i],s=!0)}return s}normalize(t){const n=this,r={};return ue.forEach(this,(s,i)=>{const o=ue.findKey(r,i);if(o){n[o]=Qf(s),delete n[i];return}const a=t?HB(i):String(i).trim();a!==i&&delete n[i],n[a]=Qf(s),r[a]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const n=Object.create(null);return ue.forEach(this,(r,s)=>{r!=null&&r!==!1&&(n[s]=t&&ue.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
|
+
`)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...n){const r=new this(t);return n.forEach(s=>r.set(s)),r}static accessor(t){const r=(this[P1]=this[P1]={accessors:{}}).accessors,s=this.prototype;function i(o){const a=ec(o);r[a]||(jB(s,o),r[a]=!0)}return ue.isArray(t)?t.forEach(i):i(t),this}};Pr.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);ue.reduceDescriptors(Pr.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(r){this[n]=r}}});ue.freezeMethods(Pr);function bg(e,t){const n=this||Od,r=t||n,s=Pr.from(r.headers);let i=r.data;return ue.forEach(e,function(a){i=a.call(n,i,s.normalize(),t?t.status:void 0)}),s.normalize(),i}function jP(e){return!!(e&&e.__CANCEL__)}function Ou(e,t,n){Ze.call(this,e??"canceled",Ze.ERR_CANCELED,t,n),this.name="CanceledError"}ue.inherits(Ou,Ze,{__CANCEL__:!0});function qP(e,t,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new Ze("Request failed with status code "+n.status,[Ze.ERR_BAD_REQUEST,Ze.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}function qB(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function WB(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(),c=r[i];o||(o=u),n[s]=l,r[s]=u;let d=i,f=0;for(;d!==s;)f+=n[d++],d=d%e;if(s=(s+1)%e,s===i&&(i=(i+1)%e),u-o<t)return;const p=c&&u-c;return p?Math.round(f*1e3/p):void 0}}function GB(e,t){let n=0,r=1e3/t,s,i;const o=(u,c=Date.now())=>{n=c,s=null,i&&(clearTimeout(i),i=null),e.apply(null,u)};return[(...u)=>{const c=Date.now(),d=c-n;d>=r?o(u,c):(s=u,i||(i=setTimeout(()=>{i=null,o(s)},r-d)))},()=>s&&o(s)]}const zh=(e,t,n=3)=>{let r=0;const s=WB(50,250);return GB(i=>{const o=i.loaded,a=i.lengthComputable?i.total:void 0,l=o-r,u=s(l),c=o<=a;r=o;const d={loaded:o,total:a,progress:a?o/a:void 0,bytes:l,rate:u||void 0,estimated:u&&a&&c?(a-o)/u:void 0,event:i,lengthComputable:a!=null,[t?"download":"upload"]:!0};e(d)},n)},R1=(e,t)=>{const n=e!=null;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},I1=e=>(...t)=>ue.asap(()=>e(...t)),KB=Jn.hasStandardBrowserEnv?((e,t)=>n=>(n=new URL(n,Jn.origin),e.protocol===n.protocol&&e.host===n.host&&(t||e.port===n.port)))(new URL(Jn.origin),Jn.navigator&&/(msie|trident)/i.test(Jn.navigator.userAgent)):()=>!0,YB=Jn.hasStandardBrowserEnv?{write(e,t,n,r,s,i){const o=[e+"="+encodeURIComponent(t)];ue.isNumber(n)&&o.push("expires="+new Date(n).toGMTString()),ue.isString(r)&&o.push("path="+r),ue.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 XB(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function QB(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function WP(e,t,n){let r=!XB(t);return e&&(r||n==!1)?QB(e,t):t}const A1=e=>e instanceof Pr?{...e}:e;function Ua(e,t){t=t||{};const n={};function r(u,c,d,f){return ue.isPlainObject(u)&&ue.isPlainObject(c)?ue.merge.call({caseless:f},u,c):ue.isPlainObject(c)?ue.merge({},c):ue.isArray(c)?c.slice():c}function s(u,c,d,f){if(ue.isUndefined(c)){if(!ue.isUndefined(u))return r(void 0,u,d,f)}else return r(u,c,d,f)}function i(u,c){if(!ue.isUndefined(c))return r(void 0,c)}function o(u,c){if(ue.isUndefined(c)){if(!ue.isUndefined(u))return r(void 0,u)}else return r(void 0,c)}function a(u,c,d){if(d in t)return r(u,c);if(d 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,c,d)=>s(A1(u),A1(c),d,!0)};return ue.forEach(Object.keys(Object.assign({},e,t)),function(c){const d=l[c]||s,f=d(e[c],t[c],c);ue.isUndefined(f)&&d!==a||(n[c]=f)}),n}const GP=e=>{const t=Ua({},e);let{data:n,withXSRFToken:r,xsrfHeaderName:s,xsrfCookieName:i,headers:o,auth:a}=t;t.headers=o=Pr.from(o),t.url=UP(WP(t.baseURL,t.url,t.allowAbsoluteUrls),e.params,e.paramsSerializer),a&&o.set("Authorization","Basic "+btoa((a.username||"")+":"+(a.password?unescape(encodeURIComponent(a.password)):"")));let l;if(ue.isFormData(n)){if(Jn.hasStandardBrowserEnv||Jn.hasStandardBrowserWebWorkerEnv)o.setContentType(void 0);else if((l=o.getContentType())!==!1){const[u,...c]=l?l.split(";").map(d=>d.trim()).filter(Boolean):[];o.setContentType([u||"multipart/form-data",...c].join("; "))}}if(Jn.hasStandardBrowserEnv&&(r&&ue.isFunction(r)&&(r=r(t)),r||r!==!1&&KB(t.url))){const u=s&&i&&YB.read(i);u&&o.set(s,u)}return t},JB=typeof XMLHttpRequest<"u",ZB=JB&&function(e){return new Promise(function(n,r){const s=GP(e);let i=s.data;const o=Pr.from(s.headers).normalize();let{responseType:a,onUploadProgress:l,onDownloadProgress:u}=s,c,d,f,p,g;function m(){p&&p(),g&&g(),s.cancelToken&&s.cancelToken.unsubscribe(c),s.signal&&s.signal.removeEventListener("abort",c)}let y=new XMLHttpRequest;y.open(s.method.toUpperCase(),s.url,!0),y.timeout=s.timeout;function w(){if(!y)return;const k=Pr.from("getAllResponseHeaders"in y&&y.getAllResponseHeaders()),_={data:!a||a==="text"||a==="json"?y.responseText:y.response,status:y.status,statusText:y.statusText,headers:k,config:e,request:y};qP(function(P){n(P),m()},function(P){r(P),m()},_),y=null}"onloadend"in y?y.onloadend=w:y.onreadystatechange=function(){!y||y.readyState!==4||y.status===0&&!(y.responseURL&&y.responseURL.indexOf("file:")===0)||setTimeout(w)},y.onabort=function(){y&&(r(new Ze("Request aborted",Ze.ECONNABORTED,e,y)),y=null)},y.onerror=function(){r(new Ze("Network Error",Ze.ERR_NETWORK,e,y)),y=null},y.ontimeout=function(){let C=s.timeout?"timeout of "+s.timeout+"ms exceeded":"timeout exceeded";const _=s.transitional||zP;s.timeoutErrorMessage&&(C=s.timeoutErrorMessage),r(new Ze(C,_.clarifyTimeoutError?Ze.ETIMEDOUT:Ze.ECONNABORTED,e,y)),y=null},i===void 0&&o.setContentType(null),"setRequestHeader"in y&&ue.forEach(o.toJSON(),function(C,_){y.setRequestHeader(_,C)}),ue.isUndefined(s.withCredentials)||(y.withCredentials=!!s.withCredentials),a&&a!=="json"&&(y.responseType=s.responseType),u&&([f,g]=zh(u,!0),y.addEventListener("progress",f)),l&&y.upload&&([d,p]=zh(l),y.upload.addEventListener("progress",d),y.upload.addEventListener("loadend",p)),(s.cancelToken||s.signal)&&(c=k=>{y&&(r(!k||k.type?new Ou(null,e,y):k),y.abort(),y=null)},s.cancelToken&&s.cancelToken.subscribe(c),s.signal&&(s.signal.aborted?c():s.signal.addEventListener("abort",c)));const b=qB(s.url);if(b&&Jn.protocols.indexOf(b)===-1){r(new Ze("Unsupported protocol "+b+":",Ze.ERR_BAD_REQUEST,e));return}y.send(i||null)})},eV=(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 c=u instanceof Error?u:this.reason;r.abort(c instanceof Ze?c:new Ou(c instanceof Error?c.message:c))}};let o=t&&setTimeout(()=>{o=null,i(new Ze(`timeout ${t} of ms exceeded`,Ze.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=()=>ue.asap(a),l}},tV=function*(e,t){let n=e.byteLength;if(n<t){yield e;return}let r=0,s;for(;r<n;)s=r+t,yield e.slice(r,s),r=s},nV=async function*(e,t){for await(const n of rV(e))yield*tV(n,t)},rV=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()}},O1=(e,t,n,r)=>{const s=nV(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:c}=await s.next();if(u){a(),l.close();return}let d=c.byteLength;if(n){let f=i+=d;n(f)}l.enqueue(new Uint8Array(c))}catch(u){throw a(u),u}},cancel(l){return a(l),s.return()}},{highWaterMark:2})},rm=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",KP=rm&&typeof ReadableStream=="function",sV=rm&&(typeof TextEncoder=="function"?(e=>t=>e.encode(t))(new TextEncoder):async e=>new Uint8Array(await new Response(e).arrayBuffer())),YP=(e,...t)=>{try{return!!e(...t)}catch{return!1}},iV=KP&&YP(()=>{let e=!1;const t=new Request(Jn.origin,{body:new ReadableStream,method:"POST",get duplex(){return e=!0,"half"}}).headers.has("Content-Type");return e&&!t}),M1=64*1024,Qv=KP&&YP(()=>ue.isReadableStream(new Response("").body)),Hh={stream:Qv&&(e=>e.body)};rm&&(e=>{["text","arrayBuffer","blob","formData","stream"].forEach(t=>{!Hh[t]&&(Hh[t]=ue.isFunction(e[t])?n=>n[t]():(n,r)=>{throw new Ze(`Response type '${t}' is not supported`,Ze.ERR_NOT_SUPPORT,r)})})})(new Response);const oV=async e=>{if(e==null)return 0;if(ue.isBlob(e))return e.size;if(ue.isSpecCompliantForm(e))return(await new Request(Jn.origin,{method:"POST",body:e}).arrayBuffer()).byteLength;if(ue.isArrayBufferView(e)||ue.isArrayBuffer(e))return e.byteLength;if(ue.isURLSearchParams(e)&&(e=e+""),ue.isString(e))return(await sV(e)).byteLength},aV=async(e,t)=>{const n=ue.toFiniteNumber(e.getContentLength());return n??oV(t)},lV=rm&&(async e=>{let{url:t,method:n,data:r,signal:s,cancelToken:i,timeout:o,onDownloadProgress:a,onUploadProgress:l,responseType:u,headers:c,withCredentials:d="same-origin",fetchOptions:f}=GP(e);u=u?(u+"").toLowerCase():"text";let p=eV([s,i&&i.toAbortSignal()],o),g;const m=p&&p.unsubscribe&&(()=>{p.unsubscribe()});let y;try{if(l&&iV&&n!=="get"&&n!=="head"&&(y=await aV(c,r))!==0){let _=new Request(t,{method:"POST",body:r,duplex:"half"}),T;if(ue.isFormData(r)&&(T=_.headers.get("content-type"))&&c.setContentType(T),_.body){const[P,S]=R1(y,zh(I1(l)));r=O1(_.body,M1,P,S)}}ue.isString(d)||(d=d?"include":"omit");const w="credentials"in Request.prototype;g=new Request(t,{...f,signal:p,method:n.toUpperCase(),headers:c.normalize().toJSON(),body:r,duplex:"half",credentials:w?d:void 0});let b=await fetch(g);const k=Qv&&(u==="stream"||u==="response");if(Qv&&(a||k&&m)){const _={};["status","statusText","headers"].forEach(E=>{_[E]=b[E]});const T=ue.toFiniteNumber(b.headers.get("content-length")),[P,S]=a&&R1(T,zh(I1(a),!0))||[];b=new Response(O1(b.body,M1,P,()=>{S&&S(),m&&m()}),_)}u=u||"text";let C=await Hh[ue.findKey(Hh,u)||"text"](b,e);return!k&&m&&m(),await new Promise((_,T)=>{qP(_,T,{data:C,headers:Pr.from(b.headers),status:b.status,statusText:b.statusText,config:e,request:g})})}catch(w){throw m&&m(),w&&w.name==="TypeError"&&/Load failed|fetch/i.test(w.message)?Object.assign(new Ze("Network Error",Ze.ERR_NETWORK,e,g),{cause:w.cause||w}):Ze.from(w,w&&w.code,e,g)}}),Jv={http:kB,xhr:ZB,fetch:lV};ue.forEach(Jv,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const D1=e=>`- ${e}`,uV=e=>ue.isFunction(e)||e===null||e===!1,XP={getAdapter:e=>{e=ue.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,!uV(n)&&(r=Jv[(o=String(n)).toLowerCase()],r===void 0))throw new Ze(`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(D1).join(`
|
|
29
|
+
`):" "+D1(i[0]):"as no adapter specified";throw new Ze("There is no suitable adapter to dispatch the request "+o,"ERR_NOT_SUPPORT")}return r},adapters:Jv};function wg(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Ou(null,e)}function L1(e){return wg(e),e.headers=Pr.from(e.headers),e.data=bg.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),XP.getAdapter(e.adapter||Od.adapter)(e).then(function(r){return wg(e),r.data=bg.call(e,e.transformResponse,r),r.headers=Pr.from(r.headers),r},function(r){return jP(r)||(wg(e),r&&r.response&&(r.response.data=bg.call(e,e.transformResponse,r.response),r.response.headers=Pr.from(r.response.headers))),Promise.reject(r)})}const QP="1.9.0",sm={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{sm[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});const $1={};sm.transitional=function(t,n,r){function s(i,o){return"[Axios v"+QP+"] Transitional option '"+i+"'"+o+(r?". "+r:"")}return(i,o,a)=>{if(t===!1)throw new Ze(s(o," has been removed"+(n?" in "+n:"")),Ze.ERR_DEPRECATED);return n&&!$1[o]&&($1[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}};sm.spelling=function(t){return(n,r)=>(console.warn(`${r} is likely a misspelling of ${t}`),!0)};function cV(e,t,n){if(typeof e!="object")throw new Ze("options must be an object",Ze.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 Ze("option "+i+" must be "+l,Ze.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new Ze("Unknown option "+i,Ze.ERR_BAD_OPTION)}}const Jf={assertOptions:cV,validators:sm},Hs=Jf.validators;let Pa=class{constructor(t){this.defaults=t||{},this.interceptors={request:new T1,response:new T1}}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=Ua(this.defaults,n);const{transitional:r,paramsSerializer:s,headers:i}=n;r!==void 0&&Jf.assertOptions(r,{silentJSONParsing:Hs.transitional(Hs.boolean),forcedJSONParsing:Hs.transitional(Hs.boolean),clarifyTimeoutError:Hs.transitional(Hs.boolean)},!1),s!=null&&(ue.isFunction(s)?n.paramsSerializer={serialize:s}:Jf.assertOptions(s,{encode:Hs.function,serialize:Hs.function},!0)),n.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?n.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:n.allowAbsoluteUrls=!0),Jf.assertOptions(n,{baseUrl:Hs.spelling("baseURL"),withXsrfToken:Hs.spelling("withXSRFToken")},!0),n.method=(n.method||this.defaults.method||"get").toLowerCase();let o=i&&ue.merge(i.common,i[n.method]);i&&ue.forEach(["delete","get","head","post","put","patch","common"],g=>{delete i[g]}),n.headers=Pr.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 c,d=0,f;if(!l){const g=[L1.bind(this),void 0];for(g.unshift.apply(g,a),g.push.apply(g,u),f=g.length,c=Promise.resolve(n);d<f;)c=c.then(g[d++],g[d++]);return c}f=a.length;let p=n;for(d=0;d<f;){const g=a[d++],m=a[d++];try{p=g(p)}catch(y){m.call(this,y);break}}try{c=L1.call(this,p)}catch(g){return Promise.reject(g)}for(d=0,f=u.length;d<f;)c=c.then(u[d++],u[d++]);return c}getUri(t){t=Ua(this.defaults,t);const n=WP(t.baseURL,t.url,t.allowAbsoluteUrls);return UP(n,t.params,t.paramsSerializer)}};ue.forEach(["delete","get","head","options"],function(t){Pa.prototype[t]=function(n,r){return this.request(Ua(r||{},{method:t,url:n,data:(r||{}).data}))}});ue.forEach(["post","put","patch"],function(t){function n(r){return function(i,o,a){return this.request(Ua(a||{},{method:t,headers:r?{"Content-Type":"multipart/form-data"}:{},url:i,data:o}))}}Pa.prototype[t]=n(),Pa.prototype[t+"Form"]=n(!0)});let dV=class JP{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 Ou(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 JP(function(s){t=s}),cancel:t}}};function fV(e){return function(n){return e.apply(null,n)}}function hV(e){return ue.isObject(e)&&e.isAxiosError===!0}const Zv={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(Zv).forEach(([e,t])=>{Zv[t]=e});function ZP(e){const t=new Pa(e),n=RP(Pa.prototype.request,t);return ue.extend(n,Pa.prototype,t,{allOwnKeys:!0}),ue.extend(n,t,null,{allOwnKeys:!0}),n.create=function(s){return ZP(Ua(e,s))},n}const hn=ZP(Od);hn.Axios=Pa;hn.CanceledError=Ou;hn.CancelToken=dV;hn.isCancel=jP;hn.VERSION=QP;hn.toFormData=nm;hn.AxiosError=Ze;hn.Cancel=hn.CanceledError;hn.all=function(t){return Promise.all(t)};hn.spread=fV;hn.isAxiosError=hV;hn.mergeConfig=Ua;hn.AxiosHeaders=Pr;hn.formToJSON=e=>HP(ue.isHTMLForm(e)?new FormData(e):e);hn.getAdapter=XP.getAdapter;hn.HttpStatusCode=Zv;hn.default=hn;const{Axios:yae,AxiosError:eR,CanceledError:bae,isCancel:wae,CancelToken:Sae,VERSION:_ae,all:kae,Cancel:xae,isAxiosError:Eae,spread:Cae,toFormData:Tae,AxiosHeaders:Pae,HttpStatusCode:fa,formToJSON:Rae,getAdapter:Iae,mergeConfig:Aae}=hn;class fc extends Error{}fc.prototype.name="InvalidTokenError";function pV(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 mV(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 pV(t)}catch{return atob(t)}}function gV(e,t){if(typeof e!="string")throw new fc("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 fc(`Invalid token specified: missing part #${n+1}`);let s;try{s=mV(r)}catch(i){throw new fc(`Invalid token specified: invalid base64 for part #${n+1} (${i.message})`)}try{return JSON.parse(s)}catch(i){throw new fc(`Invalid token specified: invalid json for part #${n+1} (${i.message})`)}}function vV(e,t={}){const{onError:n,fallbackValue:r=null}=t,s=(a,l)=>{try{return gV(a,l)}catch(u){return n==null||n(u),r}},i=A(()=>s(Nn(e),{header:!0})),o=A(()=>s(Nn(e)));return{header:i,payload:o}}class oa{static async getLoginRequired(){return await(await Kn(!1,!1)).get("/api/auth/login-required")}static async postLogin(t,n){return await(await Kn(!1,!1)).post("/api/auth/login",{username:t,password:n})}static async logout(){return await(await Kn(!0,!1)).post("/api/auth/logout")}static async refreshLogin(t){return await(await Kn(!1,!1)).post("/api/auth/refresh",{refreshToken:t})}static async verifyLogin(){return await(await Kn(!0,!1)).post("/api/auth/verify")}static async registerAccount(t,n){return await(await Kn(!0,!1)).post("/api/auth/register",{username:t,password:n})}}const kr={IncorrectCredentials:"IncorrectCredentials",InvalidOrExpiredRefreshToken:"InvalidOrExpiredRefreshToken",InvalidOrExpiredAuthToken:"InvalidOrExpiredAuthToken",PasswordChangeRequired:"PasswordChangeRequired",LoginRequired:"LoginRequired",AccountNotVerified:"AccountNotVerified"};function a0(e){switch(e){case kr.IncorrectCredentials:return"Incorrect credentials";case kr.InvalidOrExpiredRefreshToken:return"Invalid or expired refresh token";case kr.InvalidOrExpiredAuthToken:return"Invalid or expired auth token";case kr.PasswordChangeRequired:return"Password change required";case kr.LoginRequired:return"Login required";case kr.AccountNotVerified:return"Account not verified";default:return"Authentication error"}}const us=gs("auth",{state:()=>({isDemoMode:null,token:null,refreshToken:null,loginRequired:null,registration:null,wizardState:null,lastLogoutReason:null}),actions:{async checkAuthenticationRequirements(){return await oa.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 oa.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 oa.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 oa.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)!==fa.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,a0(s)),console.error(`[AuthStore] 401 Unauthorized - emitting 'auth:${s}' with reason ${s}`),Br(`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 oa.verifyLogin()}catch(o){const a=o;if(((t=a.response)==null?void 0:t.status)===fa.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===kr.AccountNotVerified||t===kr.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 oa.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)==fa.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=vV(this.token,{fallbackValue:null});return e?e.payload.value:null}}}),qe=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,Ra="9.18.0",dt=globalThis;function nl(){return im(dt),dt}function im(e){const t=e.__SENTRY__=e.__SENTRY__||{};return t.version=t.version||Ra,t[Ra]=t[Ra]||{}}function om(e,t,n=dt){const r=n.__SENTRY__=n.__SENTRY__||{},s=r[Ra]=r[Ra]||{};return s[e]||(s[e]=t())}const tR=Object.prototype.toString;function l0(e){switch(tR.call(e)){case"[object Error]":case"[object Exception]":case"[object DOMException]":case"[object WebAssembly.Exception]":return!0;default:return Vi(e,Error)}}function Mu(e,t){return tR.call(e)===`[object ${t}]`}function nR(e){return Mu(e,"ErrorEvent")}function F1(e){return Mu(e,"DOMError")}function yV(e){return Mu(e,"DOMException")}function Di(e){return Mu(e,"String")}function u0(e){return typeof e=="object"&&e!==null&&"__sentry_template_string__"in e&&"__sentry_template_values__"in e}function c0(e){return e===null||u0(e)||typeof e!="object"&&typeof e!="function"}function Qc(e){return Mu(e,"Object")}function am(e){return typeof Event<"u"&&Vi(e,Event)}function bV(e){return typeof Element<"u"&&Vi(e,Element)}function wV(e){return Mu(e,"RegExp")}function lm(e){return!!(e!=null&&e.then&&typeof e.then=="function")}function SV(e){return Qc(e)&&"nativeEvent"in e&&"preventDefault"in e&&"stopPropagation"in e}function Vi(e,t){try{return e instanceof t}catch{return!1}}function rR(e){return!!(typeof e=="object"&&e!==null&&(e.__isVue||e._isVue))}function sR(e){return typeof Request<"u"&&Vi(e,Request)}const d0=dt,_V=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 c=Array.isArray(t)?t:t.keyAttrs,d=!Array.isArray(t)&&t.maxStringLength||_V;for(;n&&i++<r&&(u=kV(n,c),!(u==="html"||i>1&&o+s.length*l+u.length>=d));)s.push(u),o+=u.length,n=n.parentNode;return s.reverse().join(a)}catch{return"<unknown>"}}function kV(e,t){const n=e,r=[];if(!(n!=null&&n.tagName))return"";if(d0.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!=null&&t.length?t.filter(o=>n.getAttribute(o)).map(o=>[o,n.getAttribute(o)]):null;if(s!=null&&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 Du(){try{return d0.document.location.href}catch{return""}}function iR(e){if(!d0.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}const xV="Sentry Logger ",ey=["debug","info","warn","error","log","assert","trace"],jh={};function pi(e){if(!("console"in dt))return e();const t=dt.console,n={},r=Object.keys(jh);r.forEach(s=>{const i=jh[s];n[s]=t[s],t[s]=i});try{return e()}finally{r.forEach(s=>{t[s]=n[s]})}}function EV(){let e=!1;const t={enable:()=>{e=!0},disable:()=>{e=!1},isEnabled:()=>e};return qe?ey.forEach(n=>{t[n]=(...r)=>{e&&pi(()=>{dt.console[n](`${xV}[${n}]:`,...r)})}}):ey.forEach(n=>{t[n]=()=>{}}),t}const Pe=om("logger",EV);function qh(e,t=0){return typeof e!="string"||t===0||e.length<=t?e:`${e.slice(0,t)}...`}function N1(e,t){if(!Array.isArray(e))return"";const n=[];for(let r=0;r<e.length;r++){const s=e[r];try{rR(s)?n.push("[VueViewModel]"):n.push(String(s))}catch{n.push("[value cannot be serialized]")}}return n.join(t)}function CV(e,t,n=!1){return Di(e)?wV(t)?t.test(e):Di(t)?n?e===t:e.includes(t):!1:!1}function Co(e,t=[],n=!1){return t.some(r=>CV(e,r,n))}function Er(e,t,n){if(!(t in e))return;const r=e[t];if(typeof r!="function")return;const s=n(r);typeof s=="function"&&oR(s,r);try{e[t]=s}catch{qe&&Pe.log(`Failed to replace method "${t}" in object`,e)}}function Wr(e,t,n){try{Object.defineProperty(e,t,{value:n,writable:!0,configurable:!0})}catch{qe&&Pe.log(`Failed to add non-enumerable property "${t}" to object`,e)}}function oR(e,t){try{const n=t.prototype||{};e.prototype=t.prototype=n,Wr(e,"__sentry_original__",t)}catch{}}function f0(e){return e.__sentry_original__}function aR(e){if(l0(e))return{message:e.message,name:e.name,stack:e.stack,...V1(e)};if(am(e)){const t={type:e.type,target:B1(e.target),currentTarget:B1(e.currentTarget),...V1(e)};return typeof CustomEvent<"u"&&Vi(e,CustomEvent)&&(t.detail=e.detail),t}else return e}function B1(e){try{return bV(e)?Ui(e):Object.prototype.toString.call(e)}catch{return"<unknown>"}}function V1(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 TV(e,t=40){const n=Object.keys(aR(e));n.sort();const r=n[0];if(!r)return"[object has no keys]";if(r.length>=t)return qh(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:qh(i,t)}return""}function PV(){const e=dt;return e.crypto||e.msCrypto}function jr(e=PV()){let t=()=>Math.random()*16;try{if(e!=null&&e.randomUUID)return e.randomUUID().replace(/-/g,"");e!=null&&e.getRandomValues&&(t=()=>{const n=new Uint8Array(1);return e.getRandomValues(n),n[0]})}catch{}return("10000000100040008000"+1e11).replace(/[018]/g,n=>(n^(t()&15)>>n/4).toString(16))}function lR(e){var t,n;return(n=(t=e.exception)==null?void 0:t.values)==null?void 0:n[0]}function ca(e){const{message:t,event_id:n}=e;if(t)return t;const r=lR(e);return r?r.type&&r.value?`${r.type}: ${r.value}`:r.type||r.value||n||"<unknown>":n||"<unknown>"}function ty(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 iu(e,t){const n=lR(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==null?void 0:s.data,...t.data};n.mechanism.data=i}}function U1(e){if(RV(e))return!0;try{Wr(e,"__sentry_captured__",!0)}catch{}return!1}function RV(e){try{return e.__sentry_captured__}catch{}}const uR=1e3;function Md(){return Date.now()/uR}function IV(){const{performance:e}=dt;if(!(e!=null&&e.now))return Md;const t=Date.now()-e.now(),n=e.timeOrigin==null?t:e.timeOrigin;return()=>(n+e.now())/uR}const tr=IV();let Sg;function AV(){var c;const{performance:e}=dt;if(!(e!=null&&e.now))return[void 0,"none"];const t=3600*1e3,n=e.now(),r=Date.now(),s=e.timeOrigin?Math.abs(e.timeOrigin+n-r):t,i=s<t,o=(c=e.timing)==null?void 0:c.navigationStart,l=typeof o=="number"?Math.abs(o+n-r):t,u=l<t;return i||u?s<=l?[e.timeOrigin,"timeOrigin"]:[o,"navigationStart"]:[r,"dateNow"]}function Yr(){return Sg||(Sg=AV()),Sg[0]}function OV(e){const t=tr(),n={sid:jr(),init:!0,timestamp:t,started:t,duration:0,status:"ok",errors:0,ignoreDuration:!1,toJSON:()=>DV(n)};return e&&ou(n,e),n}function ou(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||tr(),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:jr()),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 MV(e,t){let n={};e.status==="ok"&&(n={status:"exited"}),ou(e,n)}function DV(e){return{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 Dd(e,t,n=2){if(!t||typeof t!="object"||n<=0)return t;if(e&&Object.keys(t).length===0)return e;const r={...e};for(const s in t)Object.prototype.hasOwnProperty.call(t,s)&&(r[s]=Dd(r[s],t[s],n-1));return r}const ny="_sentrySpan";function Jc(e,t){t?Wr(e,ny,t):delete e[ny]}function Wh(e){return e[ny]}function Mo(){return jr()}function Ld(){return jr().substring(16)}const LV=100;class li{constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext={traceId:Mo(),sampleRand:Math.random()}}clone(){const t=new li;return t._breadcrumbs=[...this._breadcrumbs],t._tags={...this._tags},t._extra={...this._extra},t._contexts={...this._contexts},this._contexts.flags&&(t._contexts.flags={values:[...this._contexts.flags.values]}),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._attachments=[...this._attachments],t._sdkProcessingMetadata={...this._sdkProcessingMetadata},t._propagationContext={...this._propagationContext},t._client=this._client,t._lastEventId=this._lastEventId,Jc(t,Wh(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&&ou(this._session,{user:t}),this._notifyScopeListeners(),this}getUser(){return this._user}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=n instanceof li?n.getScopeData():Qc(n)?t:void 0,{tags:s,extra:i,user:o,contexts:a,level:l,fingerprint:u=[],propagationContext:c}=r||{};return this._tags={...this._tags,...s},this._extra={...this._extra,...i},this._contexts={...this._contexts,...a},o&&Object.keys(o).length&&(this._user=o),l&&(this._level=l),u.length&&(this._fingerprint=u),c&&(this._propagationContext=c),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._session=void 0,Jc(this,void 0),this._attachments=[],this.setPropagationContext({traceId:Mo(),sampleRand:Math.random()}),this._notifyScopeListeners(),this}addBreadcrumb(t,n){var i;const r=typeof n=="number"?n:LV;if(r<=0)return this;const s={timestamp:Md(),...t,message:t.message?qh(t.message,2048):t.message};return this._breadcrumbs.push(s),this._breadcrumbs.length>r&&(this._breadcrumbs=this._breadcrumbs.slice(-r),(i=this._client)==null||i.recordDroppedEvent("buffer_overflow","log_item")),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:Wh(this)}}setSDKProcessingMetadata(t){return this._sdkProcessingMetadata=Dd(this._sdkProcessingMetadata,t,2),this}setPropagationContext(t){return this._propagationContext=t,this}getPropagationContext(){return this._propagationContext}captureException(t,n){const r=(n==null?void 0:n.event_id)||jr();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==null?void 0:r.event_id)||jr();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==null?void 0:n.event_id)||jr();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)}}function $V(){return om("defaultCurrentScope",()=>new li)}function FV(){return om("defaultIsolationScope",()=>new li)}class NV{constructor(t,n){let r;t?r=t:r=new li;let s;n?s=n:s=new li,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 lm(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 au(){const e=nl(),t=im(e);return t.stack=t.stack||new NV($V(),FV())}function BV(e){return au().withScope(e)}function VV(e,t){const n=au();return n.withScope(()=>(n.getStackTop().scope=e,t(e)))}function z1(e){return au().withScope(()=>e(au().getIsolationScope()))}function UV(){return{withIsolationScope:z1,withScope:BV,withSetScope:VV,withSetIsolationScope:(e,t)=>z1(t),getCurrentScope:()=>au().getScope(),getIsolationScope:()=>au().getIsolationScope()}}function Lu(e){const t=im(e);return t.acs?t.acs:UV()}function Vt(){const e=nl();return Lu(e).getCurrentScope()}function mi(){const e=nl();return Lu(e).getIsolationScope()}function zV(){return om("globalScope",()=>new li)}function h0(...e){const t=nl(),n=Lu(t);if(e.length===2){const[r,s]=e;return r?n.withSetScope(r,s):n.withScope(s)}return n.withScope(e[0])}function ct(){return Vt().getClient()}function HV(e){const t=e.getPropagationContext(),{traceId:n,parentSpanId:r,propagationSpanId:s}=t,i={trace_id:n,span_id:s||Ld()};return r&&(i.parent_span_id=r),i}const zr="sentry.source",p0="sentry.sample_rate",cR="sentry.previous_trace_sample_rate",za="sentry.op",on="sentry.origin",ry="sentry.idle_span_finish_reason",um="sentry.measurement_unit",cm="sentry.measurement_value",H1="sentry.custom_span_name",m0="sentry.profile_id",$d="sentry.exclusive_time",jV="sentry.link.type",qV=0,dR=1,Tn=2;function WV(e){if(e<400&&e>=100)return{code:dR};if(e>=400&&e<500)switch(e){case 401:return{code:Tn,message:"unauthenticated"};case 403:return{code:Tn,message:"permission_denied"};case 404:return{code:Tn,message:"not_found"};case 409:return{code:Tn,message:"already_exists"};case 413:return{code:Tn,message:"failed_precondition"};case 429:return{code:Tn,message:"resource_exhausted"};case 499:return{code:Tn,message:"cancelled"};default:return{code:Tn,message:"invalid_argument"}}if(e>=500&&e<600)switch(e){case 501:return{code:Tn,message:"unimplemented"};case 503:return{code:Tn,message:"unavailable"};case 504:return{code:Tn,message:"deadline_exceeded"};default:return{code:Tn,message:"internal_error"}}return{code:Tn,message:"unknown_error"}}function fR(e,t){e.setAttribute("http.response.status_code",t);const n=WV(t);n.message!=="unknown_error"&&e.setStatus(n)}const hR="_sentryScope",pR="_sentryIsolationScope";function GV(e,t,n){e&&(Wr(e,pR,n),Wr(e,hR,t))}function Gh(e){return{scope:e[hR],isolationScope:e[pR]}}function Ha(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))return t}const g0="sentry-",KV=/^sentry-/,YV=8192;function mR(e){const t=QV(e);if(!t)return;const n=Object.entries(t).reduce((r,[s,i])=>{if(s.match(KV)){const o=s.slice(g0.length);r[o]=i}return r},{});if(Object.keys(n).length>0)return n}function XV(e){if(!e)return;const t=Object.entries(e).reduce((n,[r,s])=>(s&&(n[`${g0}${r}`]=s),n),{});return JV(t)}function QV(e){if(!(!e||!Di(e)&&!Array.isArray(e)))return Array.isArray(e)?e.reduce((t,n)=>{const r=j1(n);return Object.entries(r).forEach(([s,i])=>{t[s]=i}),t},{}):j1(e)}function j1(e){return e.split(",").map(t=>t.split("=").map(n=>{try{return decodeURIComponent(n.trim())}catch{return}})).reduce((t,[n,r])=>(n&&r&&(t[n]=r),t),{})}function JV(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>YV?(qe&&Pe.warn(`Not adding key: ${n} with val: ${r} to baggage header due to exceeding baggage size limits.`),t):o},"")}const gR=new RegExp("^[ \\t]*([0-9a-f]{32})?-?([0-9a-f]{16})?-?([01])?[ \\t]*$");function ZV(e){if(!e)return;const t=e.match(gR);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 e3(e,t){const n=ZV(e),r=mR(t);if(!(n!=null&&n.traceId))return{traceId:Mo(),sampleRand:Math.random()};const s=t3(n,r);r&&(r.sample_rand=s.toString());const{traceId:i,parentSpanId:o,parentSampled:a}=n;return{traceId:i,parentSpanId:o,sampled:a,dsc:r||{},sampleRand:s}}function vR(e=Mo(),t=Ld(),n){let r="";return n!==void 0&&(r=n?"-1":"-0"),`${e}-${t}${r}`}function t3(e,t){const n=Ha(t==null?void 0:t.sample_rand);if(n!==void 0)return n;const r=Ha(t==null?void 0:t.sample_rate);return r&&(e==null?void 0:e.parentSampled)!==void 0?e.parentSampled?Math.random()*r:r+Math.random()*(1-r):Math.random()}const yR=0,v0=1;let q1=!1;function n3(e){const{spanId:t,traceId:n}=e.spanContext(),{data:r,op:s,parent_span_id:i,status:o,origin:a,links:l}=kt(e);return{parent_span_id:i,span_id:t,trace_id:n,data:r,op:s,status:o,origin:a,links:l}}function r3(e){const{spanId:t,traceId:n,isRemote:r}=e.spanContext(),s=r?t:kt(e).parent_span_id,i=Gh(e).scope,o=r?(i==null?void 0:i.getPropagationContext().propagationSpanId)||Ld():t;return{parent_span_id:s,span_id:o,trace_id:n}}function s3(e){const{traceId:t,spanId:n}=e.spanContext(),r=rl(e);return vR(t,n,r)}function bR(e){if(e&&e.length>0)return e.map(({context:{spanId:t,traceId:n,traceFlags:r,...s},attributes:i})=>({span_id:t,trace_id:n,sampled:r===v0,attributes:i,...s}))}function Ia(e){return typeof e=="number"?W1(e):Array.isArray(e)?e[0]+e[1]/1e9:e instanceof Date?W1(e.getTime()):tr()}function W1(e){return e>9999999999?e/1e3:e}function kt(e){var r;if(o3(e))return e.getSpanJSON();const{spanId:t,traceId:n}=e.spanContext();if(i3(e)){const{attributes:s,startTime:i,name:o,endTime:a,status:l,links:u}=e,c="parentSpanId"in e?e.parentSpanId:"parentSpanContext"in e?(r=e.parentSpanContext)==null?void 0:r.spanId:void 0;return{span_id:t,trace_id:n,data:s,description:o,parent_span_id:c,start_timestamp:Ia(i),timestamp:Ia(a)||void 0,status:wR(l),op:s[za],origin:s[on],links:bR(u)}}return{span_id:t,trace_id:n,start_timestamp:0,data:{}}}function i3(e){const t=e;return!!t.attributes&&!!t.startTime&&!!t.name&&!!t.endTime&&!!t.status}function o3(e){return typeof e.getSpanJSON=="function"}function rl(e){const{traceFlags:t}=e.spanContext();return t===v0}function wR(e){if(!(!e||e.code===qV))return e.code===dR?"ok":e.message||"unknown_error"}const Aa="_sentryChildSpans",sy="_sentryRootSpan";function SR(e,t){const n=e[sy]||e;Wr(t,sy,n),e[Aa]?e[Aa].add(t):Wr(e,Aa,new Set([t]))}function a3(e,t){e[Aa]&&e[Aa].delete(t)}function Zf(e){const t=new Set;function n(r){if(!t.has(r)&&rl(r)){t.add(r);const s=r[Aa]?Array.from(r[Aa]):[];for(const i of s)n(i)}}return n(e),Array.from(t)}function Vn(e){return e[sy]||e}function Hn(){const e=nl(),t=Lu(e);return t.getActiveSpan?t.getActiveSpan():Wh(Vt())}function iy(){q1||(pi(()=>{console.warn("[Sentry] Returning null from `beforeSendSpan` is disallowed. To drop certain spans, configure the respective integrations directly.")}),q1=!0)}const _R=50,ja="?",G1=/\(error: (.*)\)/,K1=/captureMessage|captureException/;function kR(...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=G1.test(l)?l.replace(G1,"$1"):l;if(!u.match(/\S*Error: /)){for(const c of t){const d=c(u);if(d){i.push(d);break}}if(i.length>=_R+s)break}}return u3(i.slice(s))}}function l3(e){return Array.isArray(e)?kR(...e):e}function u3(e){if(!e.length)return[];const t=Array.from(e);return/sentryWrapped/.test(of(t).function||"")&&t.pop(),t.reverse(),K1.test(of(t).function||"")&&(t.pop(),K1.test(of(t).function||"")&&t.pop()),t.slice(0,_R).map(n=>({...n,filename:n.filename||of(t).filename,function:n.function||ja}))}function of(e){return e[e.length-1]||{}}const _g="<anonymous>";function zi(e){try{return!e||typeof e!="function"?_g:e.name||_g}catch{return _g}}function Y1(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={},X1={};function qo(e,t){eh[e]=eh[e]||[],eh[e].push(t)}function Wo(e,t){if(!X1[e]){X1[e]=!0;try{t()}catch(n){qe&&Pe.error(`Error while instrumenting ${e}`,n)}}}function ls(e,t){const n=e&&eh[e];if(n)for(const r of n)try{r(t)}catch(s){qe&&Pe.error(`Error while triggering instrumentation handler.
|
|
32
|
+
Type: ${e}
|
|
33
|
+
Name: ${zi(r)}
|
|
34
|
+
Error:`,s)}}let kg=null;function xR(e){const t="error";qo(t,e),Wo(t,c3)}function c3(){kg=dt.onerror,dt.onerror=function(e,t,n,r,s){return ls("error",{column:r,error:s,line:n,msg:e,url:t}),kg?kg.apply(this,arguments):!1},dt.onerror.__SENTRY_INSTRUMENTED__=!0}let xg=null;function ER(e){const t="unhandledrejection";qo(t,e),Wo(t,d3)}function d3(){xg=dt.onunhandledrejection,dt.onunhandledrejection=function(e){return ls("unhandledrejection",e),xg?xg.apply(this,arguments):!0},dt.onunhandledrejection.__SENTRY_INSTRUMENTED__=!0}let Q1=!1;function f3(){Q1||(Q1=!0,xR(oy),ER(oy))}function oy(){const e=Hn(),t=e&&Vn(e);if(t){const n="internal_error";qe&&Pe.log(`[Tracing] Root span: ${n} -> Global error occurred`),t.setStatus({code:Tn,message:n})}}oy.tag="sentry_tracingErrorCallback";function Hi(e){var n;if(typeof __SENTRY_TRACING__=="boolean"&&!__SENTRY_TRACING__)return!1;const t=e||((n=ct())==null?void 0:n.getOptions());return!!t&&(t.tracesSampleRate!=null||!!t.tracesSampler)}const y0="production",CR="_frozenDsc";function th(e,t){Wr(e,CR,t)}function TR(e,t){const n=t.getOptions(),{publicKey:r}=t.getDsn()||{},s={environment:n.environment||y0,release:n.release,public_key:r,trace_id:e};return t.emit("createDsc",s),s}function PR(e,t){const n=t.getPropagationContext();return n.dsc||TR(n.traceId,e)}function ji(e){var g;const t=ct();if(!t)return{};const n=Vn(e),r=kt(n),s=r.data,i=n.spanContext().traceState,o=(i==null?void 0:i.get("sentry.sample_rate"))??s[p0]??s[cR];function a(m){return(typeof o=="number"||typeof o=="string")&&(m.sample_rate=`${o}`),m}const l=n[CR];if(l)return a(l);const u=i==null?void 0:i.get("sentry.dsc"),c=u&&mR(u);if(c)return a(c);const d=TR(e.spanContext().traceId,t),f=s[zr],p=r.description;return f!=="url"&&p&&(d.transaction=p),Hi()&&(d.sampled=String(rl(n)),d.sample_rand=(i==null?void 0:i.get("sentry.sample_rand"))??((g=Gh(n).scope)==null?void 0:g.getPropagationContext().sampleRand.toString())),a(d),t.emit("createDsc",d,n),d}class qa{constructor(t={}){this._traceId=t.traceId||Mo(),this._spanId=t.spanId||Ld()}spanContext(){return{spanId:this._spanId,traceId:this._traceId,traceFlags:yR}}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){}}function h3(e){if(!qe)return;const{description:t="< unknown name >",op:n="< unknown op >",parent_span_id:r}=kt(e),{spanId:s}=e.spanContext(),i=rl(e),o=Vn(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:c,description:d}=kt(o);u.push(`root ID: ${o.spanContext().spanId}`),c&&u.push(`root op: ${c}`),d&&u.push(`root description: ${d}`)}Pe.log(`${l}
|
|
35
|
+
${u.join(`
|
|
36
|
+
`)}`)}function p3(e){if(!qe)return;const{description:t="< unknown name >",op:n="< unknown op >"}=kt(e),{spanId:r}=e.spanContext(),i=Vn(e)===e,o=`[Tracing] Finishing "${n}" ${i?"root ":""}span "${t}" with ID ${r}`;Pe.log(o)}function m3(e,t,n){if(!Hi(e))return[!1];let r,s;typeof e.tracesSampler=="function"?(s=e.tracesSampler({...t,inheritOrSampleWith:a=>typeof t.parentSampleRate=="number"?t.parentSampleRate:typeof t.parentSampled=="boolean"?Number(t.parentSampled):a}),r=!0):t.parentSampled!==void 0?s=t.parentSampled:typeof e.tracesSampleRate<"u"&&(s=e.tracesSampleRate,r=!0);const i=Ha(s);if(i===void 0)return qe&&Pe.warn(`[Tracing] Discarding root span because of invalid sample rate. Sample rate must be a boolean or a number between 0 and 1. Got ${JSON.stringify(s)} of type ${JSON.stringify(typeof s)}.`),[!1];if(!i)return qe&&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,i,r];const o=n<i;return o||qe&&Pe.log(`[Tracing] Discarding transaction because it's not included in the random sample (sampling rate = ${Number(s)})`),[o,i,r]}const g3=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+)?)?@)([\w.-]+)(?::(\d+))?\/(.+)/;function v3(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 y3(e){const t=g3.exec(e);if(!t){pi(()=>{console.error(`Invalid Sentry Dsn: ${e}`)});return}const[n,r,s="",i="",o="",a=""]=t.slice(1);let l="",u=a;const c=u.split("/");if(c.length>1&&(l=c.slice(0,-1).join("/"),u=c.pop()),u){const d=u.match(/^\d+/);d&&(u=d[0])}return RR({host:i,pass:s,path:l,projectId:u,port:o,protocol:n,publicKey:r})}function RR(e){return{protocol:e.protocol,publicKey:e.publicKey||"",pass:e.pass||"",host:e.host,port:e.port||"",path:e.path||"",projectId:e.projectId}}function b3(e){if(!qe)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+$/)?v3(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 w3(e){const t=typeof e=="string"?y3(e):RR(e);if(!(!t||!b3(t)))return t}function xs(e,t=100,n=1/0){try{return ay("",e,t,n)}catch(r){return{ERROR:`**non-serializable** (${r})`}}}function IR(e,t=3,n=100*1024){const r=xs(e,t);return x3(r)>n?IR(e,t-1,n):r}function ay(e,t,n=1/0,r=1/0,s=E3()){const[i,o]=s;if(t==null||["boolean","string"].includes(typeof t)||typeof t=="number"&&Number.isFinite(t))return t;const a=S3(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 ay("",p,l-1,r,s)}catch{}const c=Array.isArray(t)?[]:{};let d=0;const f=aR(t);for(const p in f){if(!Object.prototype.hasOwnProperty.call(f,p))continue;if(d>=r){c[p]="[MaxProperties ~]";break}const g=f[p];c[p]=ay(p,g,l-1,r,s),d++}return o(t),c}function S3(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(rR(t))return"[VueViewModel]";if(SV(t))return"[SyntheticEvent]";if(typeof t=="number"&&!Number.isFinite(t))return`[${t}]`;if(typeof t=="function")return`[Function: ${zi(t)}]`;if(typeof t=="symbol")return`[${String(t)}]`;if(typeof t=="bigint")return`[BigInt: ${String(t)}]`;const n=_3(t);return/^HTML(\w*)Element$/.test(n)?`[HTMLElement: ${n}]`:`[object ${n}]`}catch(n){return`**non-serializable** (${n})`}}function _3(e){const t=Object.getPrototypeOf(e);return t!=null&&t.constructor?t.constructor.name:"null prototype"}function k3(e){return~-encodeURI(e).split(/%..|./).length}function x3(e){return k3(JSON.stringify(e))}function E3(){const e=new WeakSet;function t(r){return e.has(r)?!0:(e.add(r),!1)}function n(r){e.delete(r)}return[t,n]}function sl(e,t=[]){return[e,t]}function C3(e,t){const[n,r]=e;return[n,[...r,t]]}function J1(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 ly(e){const t=im(dt);return t.encodePolyfill?t.encodePolyfill(e):new TextEncoder().encode(e)}function T3(e){const[t,n]=e;let r=JSON.stringify(t);function s(i){typeof r=="string"?r=typeof i=="string"?r+i:[ly(r),i]:r.push(typeof i=="string"?ly(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(xs(a))}s(l)}}return typeof r=="string"?r:P3(r)}function P3(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 R3(e){return[{type:"span"},e]}function I3(e){const t=typeof e.data=="string"?ly(e.data):e.data;return[{type:"attachment",length:t.length,filename:e.filename,content_type:e.contentType,attachment_type:e.attachmentType},t]}const A3={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",raw_security:"security",log:"log_item"};function Z1(e){return A3[e]}function b0(e){if(!(e!=null&&e.sdk))return;const{name:t,version:n}=e.sdk;return{name:t,version:n}}function AR(e,t,n,r){var i;const s=(i=e.sdkProcessingMetadata)==null?void 0:i.dynamicSamplingContext;return{event_id:e.event_id,sent_at:new Date().toISOString(),...t&&{sdk:t},...!!n&&r&&{dsn:Fd(r)},...s&&{trace:s}}}function O3(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 M3(e,t,n,r){const s=b0(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 D3(e,t,n,r){const s=b0(n),i=e.type&&e.type!=="replay_event"?e.type:"event";O3(e,n==null?void 0:n.sdk);const o=AR(e,s,r,t);return delete e.sdkProcessingMetadata,sl(o,[[{type:i},e]])}function L3(e,t){function n(c){return!!c.trace_id&&!!c.public_key}const r=ji(e[0]),s=t==null?void 0:t.getDsn(),i=t==null?void 0:t.getOptions().tunnel,o={sent_at:new Date().toISOString(),...n(r)&&{trace:r},...!!i&&s&&{dsn:Fd(s)}},a=t==null?void 0:t.getOptions().beforeSendSpan,l=a?c=>{const d=kt(c),f=a(d);return f||(iy(),d)}:kt,u=[];for(const c of e){const d=l(c);d&&u.push(R3(d))}return sl(o,u)}function $3(e,t,n,r=Hn()){const s=r&&Vn(r);s&&(qe&&Pe.log(`[Measurement] Setting measurement on root span: ${e} = ${t} ${n}`),s.addEvent(e,{[cm]:t,[um]:n}))}function e_(e){if(!e||e.length===0)return;const t={};return e.forEach(n=>{const r=n.attributes||{},s=r[um],i=r[cm];typeof s=="string"&&typeof i=="number"&&(t[n.name]={value:i,unit:s})}),t}const t_=1e3;class w0{constructor(t={}){this._traceId=t.traceId||Mo(),this._spanId=t.spanId||Ld(),this._startTime=t.startTimestamp||tr(),this._links=t.links,this._attributes={},this.setAttributes({[on]:"manual",[za]: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._links?this._links.push(t):this._links=[t],this}addLinks(t){return this._links?this._links.push(...t):this._links=t,this}recordException(t,n){}spanContext(){const{_spanId:t,_traceId:n,_sampled:r}=this;return{spanId:t,traceId:n,traceFlags:r?v0:yR}}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=Ia(t)}setStatus(t){return this._status=t,this}updateName(t){return this._name=t,this.setAttribute(zr,"custom"),this}end(t){this._endTime||(this._endTime=Ia(t),p3(this),this._onSpanEnded())}getSpanJSON(){return{data:this._attributes,description:this._name,op:this._attributes[za],parent_span_id:this._parentSpanId,span_id:this._spanId,start_timestamp:this._startTime,status:wR(this._status),timestamp:this._endTime,trace_id:this._traceId,origin:this._attributes[on],profile_id:this._attributes[m0],exclusive_time:this._attributes[$d],measurements:e_(this._events),is_segment:this._isStandaloneSpan&&Vn(this)===this||void 0,segment_id:this._isStandaloneSpan?Vn(this).spanContext().spanId:void 0,links:bR(this._links)}}isRecording(){return!this._endTime&&!!this._sampled}addEvent(t,n,r){qe&&Pe.log("[Tracing] Adding an event to span:",t);const s=n_(n)?n:r||tr(),i=n_(n)?{}:n||{},o={name:t,time:Ia(s),attributes:i};return this._events.push(o),this}isStandaloneSpan(){return!!this._isStandaloneSpan}_onSpanEnded(){const t=ct();if(t&&t.emit("spanEnd",this),!(this._isStandaloneSpan||this===Vn(this)))return;if(this._isStandaloneSpan){this._sampled?N3(L3([this],t)):(qe&&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&&(Gh(this).scope||Vt()).captureEvent(r)}_convertSpanToTransaction(){if(!r_(kt(this)))return;this._name||(qe&&Pe.warn("Transaction has no name, falling back to `<unlabeled transaction>`."),this._name="<unlabeled transaction>");const{scope:t,isolationScope:n}=Gh(this);if(this._sampled!==!0)return;const s=Zf(this).filter(u=>u!==this&&!F3(u)).map(u=>kt(u)).filter(r_),i=this._attributes[zr];delete this._attributes[H1],s.forEach(u=>{delete u.data[H1]});const o={contexts:{trace:n3(this)},spans:s.length>t_?s.sort((u,c)=>u.start_timestamp-c.start_timestamp).slice(0,t_):s,start_timestamp:this._startTime,timestamp:this._endTime,transaction:this._name,type:"transaction",sdkProcessingMetadata:{capturedSpanScope:t,capturedSpanIsolationScope:n,dynamicSamplingContext:ji(this)},...i&&{transaction_info:{source:i}}},a=e_(this._events);return a&&Object.keys(a).length&&(qe&&Pe.log("[Measurements] Adding measurements to transaction event",JSON.stringify(a,void 0,2)),o.measurements=a),o}}function n_(e){return e&&typeof e=="number"||e instanceof Date||Array.isArray(e)}function r_(e){return!!e.start_timestamp&&!!e.timestamp&&!!e.span_id&&!!e.trace_id}function F3(e){return e instanceof w0&&e.isStandaloneSpan()}function N3(e){const t=ct();if(!t)return;const n=e[1];if(!n||n.length===0){t.recordDroppedEvent("before_send","span");return}t.sendEnvelope(e)}const OR="__SENTRY_SUPPRESS_TRACING__";function Wa(e){const t=DR();if(t.startInactiveSpan)return t.startInactiveSpan(e);const n=V3(e),{forceTransaction:r,parentSpan:s}=e;return(e.scope?o=>h0(e.scope,o):s!==void 0?o=>MR(s,o):o=>o())(()=>{const o=Vt(),a=z3(o);return e.onlyIfParent&&!a?new qa:B3({parentSpan:a,spanArguments:n,forceTransaction:r,scope:o})})}function MR(e,t){const n=DR();return n.withActiveSpan?n.withActiveSpan(e,t):h0(r=>(Jc(r,e||void 0),t(r)))}function B3({parentSpan:e,spanArguments:t,forceTransaction:n,scope:r}){if(!Hi()){const o=new qa;if(n||!e){const a={sampled:"false",sample_rate:"0",transaction:t.name,...ji(o)};th(o,a)}return o}const s=mi();let i;if(e&&!n)i=U3(e,r,t),SR(e,i);else if(e){const o=ji(e),{traceId:a,spanId:l}=e.spanContext(),u=rl(e);i=s_({traceId:a,parentSpanId:l,...t},r,u),th(i,o)}else{const{traceId:o,dsc:a,parentSpanId:l,sampled:u}={...s.getPropagationContext(),...r.getPropagationContext()};i=s_({traceId:o,parentSpanId:l,...t},r,u),a&&th(i,a)}return h3(i),GV(i,r,s),i}function V3(e){const n={isStandalone:(e.experimental||{}).standalone,...e};if(e.startTime){const r={...n};return r.startTimestamp=Ia(e.startTime),delete r.startTime,r}return n}function DR(){const e=nl();return Lu(e)}function s_(e,t,n){var g;const r=ct(),s=(r==null?void 0:r.getOptions())||{},{name:i=""}=e,o={spanAttributes:{...e.attributes},spanName:i,parentSampled:n};r==null||r.emit("beforeSampling",o,{decision:!1});const a=o.parentSampled??n,l=o.spanAttributes,u=t.getPropagationContext(),[c,d,f]=t.getScopeData().sdkProcessingMetadata[OR]?[!1]:m3(s,{name:i,parentSampled:a,attributes:l,parentSampleRate:Ha((g=u.dsc)==null?void 0:g.sample_rate)},u.sampleRand),p=new w0({...e,attributes:{[zr]:"custom",[p0]:d!==void 0&&f?d:void 0,...l},sampled:c});return!c&&r&&(qe&&Pe.log("[Tracing] Discarding root span because its trace was not chosen to be sampled."),r.recordDroppedEvent("sample_rate","transaction")),r&&r.emit("spanStart",p),p}function U3(e,t,n){const{spanId:r,traceId:s}=e.spanContext(),i=t.getScopeData().sdkProcessingMetadata[OR]?!1:rl(e),o=i?new w0({...n,parentSpanId:r,traceId:s,sampled:i}):new qa({traceId:s});SR(e,o);const a=ct();return a&&(a.emit("spanStart",o),n.endTimestamp&&a.emit("spanEnd",o)),o}function z3(e){const t=Wh(e);if(!t)return;const n=ct();return(n?n.getOptions():{}).parentSpanIsAlwaysRootSpan?Vn(t):t}const nh={idleTimeout:1e3,finalTimeout:3e4,childSpanTimeout:15e3},H3="heartbeatFailed",j3="idleTimeout",q3="finalTimeout",W3="externalFinish";function LR(e,t={}){const n=new Map;let r=!1,s,i=W3,o=!t.disableAutoFinish;const a=[],{idleTimeout:l=nh.idleTimeout,finalTimeout:u=nh.finalTimeout,childSpanTimeout:c=nh.childSpanTimeout,beforeSpanEnd:d}=t,f=ct();if(!f||!Hi()){const T=new qa,P={sample_rate:"0",sampled:"false",...ji(T)};return th(T,P),T}const p=Vt(),g=Hn(),m=G3(e);m.end=new Proxy(m.end,{apply(T,P,S){if(d&&d(m),P instanceof qa)return;const[E,...I]=S,O=E||tr(),R=Ia(O),M=Zf(m).filter(X=>X!==m);if(!M.length)return _(R),Reflect.apply(T,P,[R,...I]);const D=M.map(X=>kt(X).timestamp).filter(X=>!!X),F=D.length?Math.max(...D):void 0,U=kt(m).start_timestamp,K=Math.min(U?U+u/1e3:1/0,Math.max(U||-1/0,Math.min(R,F||1/0)));return _(K),Reflect.apply(T,P,[K,...I])}});function y(){s&&(clearTimeout(s),s=void 0)}function w(T){y(),s=setTimeout(()=>{!r&&n.size===0&&o&&(i=j3,m.end(T))},l)}function b(T){s=setTimeout(()=>{!r&&o&&(i=H3,m.end(T))},c)}function k(T){y(),n.set(T,!0);const P=tr();b(P+c/1e3)}function C(T){if(n.has(T)&&n.delete(T),n.size===0){const P=tr();w(P+l/1e3)}}function _(T){r=!0,n.clear(),a.forEach(R=>R()),Jc(p,g);const P=kt(m),{start_timestamp:S}=P;if(!S)return;P.data[ry]||m.setAttribute(ry,i),Pe.log(`[Tracing] Idle span "${P.op}" finished`);const I=Zf(m).filter(R=>R!==m);let O=0;I.forEach(R=>{R.isRecording()&&(R.setStatus({code:Tn,message:"cancelled"}),R.end(T),qe&&Pe.log("[Tracing] Cancelling span since span ended early",JSON.stringify(R,void 0,2)));const M=kt(R),{timestamp:D=0,start_timestamp:F=0}=M,U=F<=T,K=(u+l)/1e3,X=D-F<=K;if(qe){const H=JSON.stringify(R,void 0,2);U?X||Pe.log("[Tracing] Discarding span since it finished after idle span final timeout",H):Pe.log("[Tracing] Discarding span since it happened after idle span was finished",H)}(!X||!U)&&(a3(m,R),O++)}),O>0&&m.setAttribute("sentry.idle_span_discarded_spans",O)}return a.push(f.on("spanStart",T=>{if(r||T===m||kt(T).timestamp)return;Zf(m).includes(T)&&k(T.spanContext().spanId)})),a.push(f.on("spanEnd",T=>{r||C(T.spanContext().spanId)})),a.push(f.on("idleSpanEnableAutoFinish",T=>{T===m&&(o=!0,w(),n.size&&b())})),t.disableAutoFinish||w(),setTimeout(()=>{r||(m.setStatus({code:Tn,message:"deadline_exceeded"}),i=q3,m.end())},u),m}function G3(e){const t=Wa(e);return Jc(Vt(),t),qe&&Pe.log("[Tracing] Started span is an idle span"),t}var Ti;(function(e){e[e.PENDING=0]="PENDING";const n=1;e[e.RESOLVED=n]="RESOLVED";const r=2;e[e.REJECTED=r]="REJECTED"})(Ti||(Ti={}));function qi(e){return new Do(t=>{t(e)})}function Kh(e){return new Do((t,n)=>{n(e)})}class Do{constructor(t){this._state=Ti.PENDING,this._handlers=[],this._runExecutor(t)}then(t,n){return new Do((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 Do((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)})})}_executeHandlers(){if(this._state===Ti.PENDING)return;const t=this._handlers.slice();this._handlers=[],t.forEach(n=>{n[0]||(this._state===Ti.RESOLVED&&n[1](this._value),this._state===Ti.REJECTED&&n[2](this._value),n[0]=!0)})}_runExecutor(t){const n=(i,o)=>{if(this._state===Ti.PENDING){if(lm(o)){o.then(r,s);return}this._state=i,this._value=o,this._executeHandlers()}},r=i=>{n(Ti.RESOLVED,i)},s=i=>{n(Ti.REJECTED,i)};try{t(r,s)}catch(i){s(i)}}}function uy(e,t,n,r=0){return new Do((s,i)=>{const o=e[r];if(t===null||typeof o!="function")s(t);else{const a=o({...t},n);qe&&o.id&&a===null&&Pe.log(`Event processor "${o.id}" dropped event`),lm(a)?a.then(l=>uy(e,l,n,r+1).then(s)).then(null,i):uy(e,a,n,r+1).then(s).then(null,i)}})}let af,i_,lf;function K3(e){const t=dt._sentryDebugIds;if(!t)return{};const n=Object.keys(t);return lf&&n.length===i_||(i_=n.length,lf=n.reduce((r,s)=>{af||(af={});const i=af[s];if(i)r[i[0]]=i[1];else{const o=e(s);for(let a=o.length-1;a>=0;a--){const l=o[a],u=l==null?void 0:l.filename,c=t[s];if(u&&c){r[u]=c,af[s]=[u,c];break}}}return r},{})),lf}function Y3(e,t){const{fingerprint:n,span:r,breadcrumbs:s,sdkProcessingMetadata:i}=t;X3(e,t),r&&Z3(e,r),eU(e,n),Q3(e,s),J3(e,i)}function o_(e,t){const{extra:n,tags:r,user:s,contexts:i,level:o,sdkProcessingMetadata:a,breadcrumbs:l,fingerprint:u,eventProcessors:c,attachments:d,propagationContext:f,transactionName:p,span:g}=t;uf(e,"extra",n),uf(e,"tags",r),uf(e,"user",s),uf(e,"contexts",i),e.sdkProcessingMetadata=Dd(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]),c.length&&(e.eventProcessors=[...e.eventProcessors,...c]),d.length&&(e.attachments=[...e.attachments,...d]),e.propagationContext={...e.propagationContext,...f}}function uf(e,t,n){e[t]=Dd(e[t],n,1)}function X3(e,t){const{extra:n,tags:r,user:s,contexts:i,level:o,transactionName:a}=t;Object.keys(n).length&&(e.extra={...n,...e.extra}),Object.keys(r).length&&(e.tags={...r,...e.tags}),Object.keys(s).length&&(e.user={...s,...e.user}),Object.keys(i).length&&(e.contexts={...i,...e.contexts}),o&&(e.level=o),a&&e.type!=="transaction"&&(e.transaction=a)}function Q3(e,t){const n=[...e.breadcrumbs||[],...t];e.breadcrumbs=n.length?n:void 0}function J3(e,t){e.sdkProcessingMetadata={...e.sdkProcessingMetadata,...t}}function Z3(e,t){e.contexts={trace:r3(t),...e.contexts},e.sdkProcessingMetadata={dynamicSamplingContext:ji(t),...e.sdkProcessingMetadata};const n=Vn(t),r=kt(n).description;r&&!e.transaction&&e.type==="transaction"&&(e.transaction=r)}function eU(e,t){e.fingerprint=e.fingerprint?Array.isArray(e.fingerprint)?e.fingerprint:[e.fingerprint]:[],t&&(e.fingerprint=e.fingerprint.concat(t)),e.fingerprint.length||delete e.fingerprint}function $R(e,t,n,r,s,i){const{normalizeDepth:o=3,normalizeMaxBreadth:a=1e3}=e,l={...t,event_id:t.event_id||n.event_id||jr(),timestamp:t.timestamp||Md()},u=n.integrations||e.integrations.map(y=>y.name);tU(l,e),sU(l,u),s&&s.emit("applyFrameMetadata",t),t.type===void 0&&nU(l,e.stackParser);const c=oU(r,n.captureContext);n.mechanism&&iu(l,n.mechanism);const d=s?s.getEventProcessors():[],f=zV().getScopeData();if(i){const y=i.getScopeData();o_(f,y)}if(c){const y=c.getScopeData();o_(f,y)}const p=[...n.attachments||[],...f.attachments];p.length&&(n.attachments=p),Y3(l,f);const g=[...d,...f.eventProcessors];return uy(g,l,n).then(y=>(y&&rU(y),typeof o=="number"&&o>0?iU(y,o,a):y))}function tU(e,t){const{environment:n,release:r,dist:s,maxValueLength:i=250}=t;e.environment=e.environment||n||y0,!e.release&&r&&(e.release=r),!e.dist&&s&&(e.dist=s);const o=e.request;o!=null&&o.url&&(o.url=qh(o.url,i))}function nU(e,t){var r,s;const n=K3(t);(s=(r=e.exception)==null?void 0:r.values)==null||s.forEach(i=>{var o,a;(a=(o=i.stacktrace)==null?void 0:o.frames)==null||a.forEach(l=>{l.filename&&(l.debug_id=n[l.filename])})})}function rU(e){var r,s;const t={};if((s=(r=e.exception)==null?void 0:r.values)==null||s.forEach(i=>{var o,a;(a=(o=i.stacktrace)==null?void 0:o.frames)==null||a.forEach(l=>{l.debug_id&&(l.abs_path?t[l.abs_path]=l.debug_id:l.filename&&(t[l.filename]=l.debug_id),delete l.debug_id)})}),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(([i,o])=>{n.push({type:"sourcemap",code_file:i,debug_id:o})})}function sU(e,t){t.length>0&&(e.sdk=e.sdk||{},e.sdk.integrations=[...e.sdk.integrations||[],...t])}function iU(e,t,n){var s,i;if(!e)return null;const r={...e,...e.breadcrumbs&&{breadcrumbs:e.breadcrumbs.map(o=>({...o,...o.data&&{data:xs(o.data,t,n)}}))},...e.user&&{user:xs(e.user,t,n)},...e.contexts&&{contexts:xs(e.contexts,t,n)},...e.extra&&{extra:xs(e.extra,t,n)}};return(s=e.contexts)!=null&&s.trace&&r.contexts&&(r.contexts.trace=e.contexts.trace,e.contexts.trace.data&&(r.contexts.trace.data=xs(e.contexts.trace.data,t,n))),e.spans&&(r.spans=e.spans.map(o=>({...o,...o.data&&{data:xs(o.data,t,n)}}))),(i=e.contexts)!=null&&i.flags&&r.contexts&&(r.contexts.flags=xs(e.contexts.flags,3,n)),r}function oU(e,t){if(!t)return e;const n=e?e.clone():new li;return n.update(t),n}function aU(e){if(e)return lU(e)?{captureContext:e}:cU(e)?{captureContext:e}:e}function lU(e){return e instanceof li||typeof e=="function"}const uU=["user","level","extra","contexts","tags","fingerprint","propagationContext"];function cU(e){return Object.keys(e).some(t=>uU.includes(t))}function ai(e,t){return Vt().captureException(e,aU(t))}function FR(e,t){return Vt().captureEvent(e,t)}function dU(e,t){mi().setContext(e,t)}function fU(){const e=ct();return(e==null?void 0:e.getOptions().enabled)!==!1&&!!(e!=null&&e.getTransport())}function hU(e){mi().addEventProcessor(e)}function a_(e){const t=mi(),n=Vt(),{userAgent:r}=dt.navigator||{},s=OV({user:n.getUser()||t.getUser(),...r&&{userAgent:r},...e}),i=t.getSession();return(i==null?void 0:i.status)==="ok"&&ou(i,{status:"exited"}),NR(),t.setSession(s),s}function NR(){const e=mi(),n=Vt().getSession()||e.getSession();n&&MV(n),BR(),e.setSession()}function BR(){const e=mi(),t=ct(),n=e.getSession();n&&t&&t.captureSession(n)}function l_(e=!1){if(e){NR();return}BR()}const pU="7";function mU(e){const t=e.protocol?`${e.protocol}:`:"",n=e.port?`:${e.port}`:"";return`${t}//${e.host}${n}${e.path?`/${e.path}`:""}/api/`}function gU(e){return`${mU(e)}${e.projectId}/envelope/`}function vU(e,t){const n={sentry_version:pU};return e.publicKey&&(n.sentry_key=e.publicKey),t&&(n.sentry_client=`${t.name}/${t.version}`),new URLSearchParams(n).toString()}function yU(e,t,n){return t||`${gU(e)}?${vU(e,n)}`}const u_=[];function bU(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 wU(e){const t=e.defaultIntegrations||[],n=e.integrations;t.forEach(s=>{s.isDefaultInstance=!0});let r;if(Array.isArray(n))r=[...t,...n];else if(typeof n=="function"){const s=n(t);r=Array.isArray(s)?s:[s]}else r=t;return bU(r)}function SU(e,t){const n={};return t.forEach(r=>{r&&VR(e,r,n)}),n}function c_(e,t){for(const n of t)n!=null&&n.afterAllSetup&&n.afterAllSetup(e)}function VR(e,t,n){if(n[t.name]){qe&&Pe.log(`Integration skipped because it was already installed: ${t.name}`);return}if(n[t.name]=t,u_.indexOf(t.name)===-1&&typeof t.setupOnce=="function"&&(t.setupOnce(),u_.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)}qe&&Pe.log(`Integration installed: ${t.name}`)}function UR(e){const t=[];e.message&&t.push(e.message);try{const n=e.exception.values[e.exception.values.length-1];n!=null&&n.value&&(t.push(n.value),n.type&&t.push(`${n.type}: ${n.value}`))}catch{}return t}function _U(e){var l;const{trace_id:t,parent_span_id:n,span_id:r,status:s,origin:i,data:o,op:a}=((l=e.contexts)==null?void 0:l.trace)??{};return{data:o??{},description:e.transaction,op:a,parent_span_id:n,span_id:r??"",start_timestamp:e.start_timestamp??0,status:s,timestamp:e.timestamp,trace_id:t??"",origin:i,profile_id:o==null?void 0:o[m0],exclusive_time:o==null?void 0:o[$d],measurements:e.measurements,is_segment:!0}}function kU(e){return{type:"transaction",timestamp:e.timestamp,start_timestamp:e.start_timestamp,transaction:e.description,contexts:{trace:{trace_id:e.trace_id,span_id:e.span_id,parent_span_id:e.parent_span_id,op:e.op,status:e.status,origin:e.origin,data:{...e.data,...e.profile_id&&{[m0]:e.profile_id},...e.exclusive_time&&{[$d]:e.exclusive_time}}}},measurements:e.measurements}}function xU(e,t,n){const r=[{type:"client_report"},{timestamp:Md(),discarded_events:e}];return sl(t?{dsn:t}:{},[r])}const d_="Not capturing exception because it's already been captured.",f_="Discarded session because of missing or non-string release",zR=Symbol.for("SentryInternalError"),HR=Symbol.for("SentryDoNotSendEventError");function rh(e){return{message:e,[zR]:!0}}function Eg(e){return{message:e,[HR]:!0}}function h_(e){return!!e&&typeof e=="object"&&zR in e}function p_(e){return!!e&&typeof e=="object"&&HR in e}class EU{constructor(t){if(this._options=t,this._integrations={},this._numProcessing=0,this._outcomes={},this._hooks={},this._eventProcessors=[],t.dsn?this._dsn=w3(t.dsn):qe&&Pe.warn("No DSN provided, client will not send events."),this._dsn){const n=yU(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=jr();if(U1(t))return qe&&Pe.log(d_),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:jr(),...r},o=u0(t)?t:String(t),a=c0(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=jr();if(n!=null&&n.originalException&&U1(n.originalException))return qe&&Pe.log(d_),s;const i={event_id:s,...n},o=t.sdkProcessingMetadata||{},a=o.capturedSpanScope,l=o.capturedSpanIsolationScope;return this._process(this._captureEvent(t,i,a||r,l)),i.event_id}captureSession(t){this.sendSession(t),ou(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))):qi(!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];VR(this,t,this._integrations),n||c_(this,[t])}sendEvent(t,n={}){this.emit("beforeSendEvent",t,n);let r=D3(t,this._dsn,this._options._metadata,this._options.tunnel);for(const i of n.attachments||[])r=C3(r,I3(i));const s=this.sendEnvelope(r);s&&s.then(i=>this.emit("afterSendEvent",t,i),null)}sendSession(t){const{release:n,environment:r=y0}=this._options;if("aggregates"in t){const i=t.attrs||{};if(!i.release&&!n){qe&&Pe.warn(f_);return}i.release=i.release||n,i.environment=i.environment||r,t.attrs=i}else{if(!t.release&&!n){qe&&Pe.warn(f_);return}t.release=t.release||n,t.environment=t.environment||r}this.emit("beforeSendSession",t);const s=M3(t,this._dsn,this._options._metadata,this._options.tunnel);this.sendEnvelope(s)}recordDroppedEvent(t,n,r=1){if(this._options.sendClientReports){const s=`${t}:${n}`;qe&&Pe.log(`Recording outcome: "${s}"${r>1?` (${r} times)`:""}`),this._outcomes[s]=(this._outcomes[s]||0)+r}}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=>(qe&&Pe.error("Error while sending envelope:",n),n)):(qe&&Pe.error("Transport disabled"),qi({}))}_setupIntegrations(){const{integrations:t}=this._options;this._integrations=SU(this,t),c_(this,t)}_updateSessionFromEvent(t,n){var l;let r=n.level==="fatal",s=!1;const i=(l=n.exception)==null?void 0:l.values;if(i){s=!0;for(const u of i){const c=u.mechanism;if((c==null?void 0:c.handled)===!1){r=!0;break}}}const o=t.status==="ok";(o&&t.errors===0||o&&r)&&(ou(t,{...r&&{status:"crashed"},errors:t.errors||Number(s||r)}),this.captureSession(t))}_isClientDoneProcessing(t){return new Do(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){const i=this.getOptions(),o=Object.keys(this._integrations);return!n.integrations&&(o!=null&&o.length)&&(n.integrations=o),this.emit("preprocessEvent",t,n),t.type||s.setLastEventId(t.event_id||n.event_id),$R(i,t,n,r,this,s).then(a=>{if(a===null)return a;this.emit("postprocessEvent",a,n),a.contexts={trace:HV(r),...a.contexts};const l=PR(this,r);return a.sdkProcessingMetadata={dynamicSamplingContext:l,...a.sdkProcessingMetadata},a})}_captureEvent(t,n={},r=Vt(),s=mi()){return qe&&cy(t)&&Pe.log(`Captured error event \`${UR(t)[0]||"<unknown>"}\``),this._processEvent(t,n,r,s).then(i=>i.event_id,i=>{qe&&(p_(i)?Pe.log(i.message):h_(i)?Pe.warn(i.message):Pe.warn(i))})}_processEvent(t,n,r,s){const i=this.getOptions(),{sampleRate:o}=i,a=jR(t),l=cy(t),u=t.type||"error",c=`before send for type \`${u}\``,d=typeof o>"u"?void 0:Ha(o);if(l&&typeof d=="number"&&Math.random()>d)return this.recordDroppedEvent("sample_rate","error"),Kh(Eg(`Discarding event because it's not included in the random sample (sampling rate = ${o})`));const f=u==="replay_event"?"replay":u;return this._prepareEvent(t,n,r,s).then(p=>{if(p===null)throw this.recordDroppedEvent("event_processor",f),Eg("An event processor returned `null`, will not send event.");if(n.data&&n.data.__sentry__===!0)return p;const m=TU(this,i,p,n);return CU(m,c)}).then(p=>{var y;if(p===null){if(this.recordDroppedEvent("before_send",f),a){const b=1+(t.spans||[]).length;this.recordDroppedEvent("before_send","span",b)}throw Eg(`${c} returned \`null\`, will not send event.`)}const g=r.getSession()||s.getSession();if(l&&g&&this._updateSessionFromEvent(g,p),a){const w=((y=p.sdkProcessingMetadata)==null?void 0:y.spanCountBeforeProcessing)||0,b=p.spans?p.spans.length:0,k=w-b;k>0&&this.recordDroppedEvent("before_send","span",k)}const m=p.transaction_info;if(a&&m&&p.transaction!==t.transaction){const w="custom";p.transaction_info={...m,source:w}}return this.sendEvent(p,n),p}).then(null,p=>{throw p_(p)||h_(p)?p:(this.captureException(p,{data:{__sentry__:!0},originalException:p}),rh(`Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event.
|
|
39
|
+
Reason: ${p}`))})}_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(){qe&&Pe.log("Flushing outcomes...");const t=this._clearOutcomes();if(t.length===0){qe&&Pe.log("No outcomes to send");return}if(!this._dsn){qe&&Pe.log("No dsn provided, will not send outcomes");return}qe&&Pe.log("Sending outcomes:",t);const n=xU(t,this._options.tunnel&&Fd(this._dsn));this.sendEnvelope(n)}}function CU(e,t){const n=`${t} must return \`null\` or a valid event.`;if(lm(e))return e.then(r=>{if(!Qc(r)&&r!==null)throw rh(n);return r},r=>{throw rh(`${t} rejected with ${r}`)});if(!Qc(e)&&e!==null)throw rh(n);return e}function TU(e,t,n,r){const{beforeSend:s,beforeSendTransaction:i,beforeSendSpan:o}=t;let a=n;if(cy(a)&&s)return s(a,r);if(jR(a)){if(o){const l=o(_U(a));if(l?a=Dd(n,kU(l)):iy(),a.spans){const u=[];for(const c of a.spans){const d=o(c);d?u.push(d):(iy(),u.push(c))}a.spans=u}}if(i){if(a.spans){const l=a.spans.length;a.sdkProcessingMetadata={...n.sdkProcessingMetadata,spanCountBeforeProcessing:l}}return i(a,r)}}return a}function cy(e){return e.type===void 0}function jR(e){return e.type==="transaction"}function PU(e){return[{type:"log",item_count:e.length,content_type:"application/vnd.sentry.items.log+json"},{items:e}]}function RU(e,t,n,r){const s={};return t!=null&&t.sdk&&(s.sdk={name:t.sdk.name,version:t.sdk.version}),n&&r&&(s.dsn=Fd(r)),sl(s,[PU(e)])}dt._sentryClientToLogBufferMap=new WeakMap;function Cg(e,t){var i;const n=IU(e)??[];if(n.length===0)return;const r=e.getOptions(),s=RU(n,r._metadata,r.tunnel,e.getDsn());(i=dt._sentryClientToLogBufferMap)==null||i.set(e,[]),e.emit("flushLogs"),e.sendEnvelope(s)}function IU(e){var t;return(t=dt._sentryClientToLogBufferMap)==null?void 0:t.get(e)}function AU(e,t){t.debug===!0&&(qe?Pe.enable():pi(()=>{console.warn("[Sentry] Cannot initialize SDK with `debug` option using a non-debug bundle.")})),Vt().update(t.initialScope);const r=new e(t);return OU(r),r.init(),r}function OU(e){Vt().setClient(e)}const qR=Symbol.for("SentryBufferFullError");function MU(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 Kh(qR);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 Do((a,l)=>{let u=t.length;if(!u)return a(!0);const c=setTimeout(()=>{o&&o>0&&a(!1)},o);t.forEach(d=>{qi(d).then(()=>{--u||(clearTimeout(c),a(!0))},l)})})}return{$:t,add:s,drain:i}}const DU=60*1e3;function LU(e,t=Date.now()){const n=parseInt(`${e}`,10);if(!isNaN(n))return n*1e3;const r=Date.parse(`${e}`);return isNaN(r)?DU:r-t}function $U(e,t){return e[t]||e.all||0}function WR(e,t,n=Date.now()){return $U(e,t)>n}function GR(e,{statusCode:t,headers:n},r=Date.now()){const s={...e},i=n==null?void 0:n["x-sentry-rate-limits"],o=n==null?void 0:n["retry-after"];if(i)for(const a of i.trim().split(",")){const[l,u,,,c]=a.split(":",5),d=parseInt(l,10),f=(isNaN(d)?60:d)*1e3;if(!u)s.all=r+f;else for(const p of u.split(";"))p==="metric_bucket"?(!c||c.split(";").includes("custom"))&&(s[p]=r+f):s[p]=r+f}else o?s.all=r+LU(o,r):t===429&&(s.all=r+60*1e3);return s}const FU=64;function NU(e,t,n=MU(e.bufferSize||FU)){let r={};const s=o=>n.drain(o);function i(o){const a=[];if(J1(o,(d,f)=>{const p=Z1(f);WR(r,p)?e.recordDroppedEvent("ratelimit_backoff",p):a.push(d)}),a.length===0)return qi({});const l=sl(o[0],a),u=d=>{J1(l,(f,p)=>{e.recordDroppedEvent(d,Z1(p))})},c=()=>t({body:T3(l)}).then(d=>(d.statusCode!==void 0&&(d.statusCode<200||d.statusCode>=300)&&qe&&Pe.warn(`Sentry responded with status code ${d.statusCode} to sent event.`),r=GR(r,d),d),d=>{throw u("network_error"),qe&&Pe.error("Encountered error running transport request:",d),d});return n.add(c).then(d=>d,d=>{if(d===qR)return qe&&Pe.error("Skipped sending event because buffer is full."),u("queue_overflow"),qi({});throw d})}return{send:i,flush:s}}function BU(e,t){const n=t==null?void 0:t.getDsn(),r=t==null?void 0:t.getOptions().tunnel;return UU(e,n)||VU(e,r)}function VU(e,t){return t?m_(e)===m_(t):!1}function UU(e,t){return t?e.includes(t.host):!1}function m_(e){return e[e.length-1]==="/"?e.slice(0,-1):e}function zU(e){var t;((t=e.user)==null?void 0:t.ip_address)===void 0&&(e.user={...e.user,ip_address:"{{auto}}"})}function HU(e){var t;"aggregates"in e?((t=e.attrs)==null?void 0:t.ip_address)===void 0&&(e.attrs={...e.attrs,ip_address:"{{auto}}"}):e.ipAddress===void 0&&(e.ipAddress="{{auto}}")}function KR(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:Ra})),version:Ra}),e._metadata=s}function YR(e={}){const t=ct();if(!fU()||!t)return{};const n=nl(),r=Lu(n);if(r.getTraceData)return r.getTraceData(e);const s=Vt(),i=e.span||Hn(),o=i?s3(i):jU(s),a=i?ji(i):PR(t,s),l=XV(a);return gR.test(o)?{"sentry-trace":o,baggage:l}:(Pe.warn("Invalid sentry-trace data. Cannot generate trace data"),{})}function jU(e){const{traceId:t,sampled:n,propagationSpanId:r}=e.getPropagationContext();return vR(t,r,n)}const qU=100;function Lo(e,t){const n=ct(),r=mi();if(!n)return;const{beforeBreadcrumb:s=null,maxBreadcrumbs:i=qU}=n.getOptions();if(i<=0)return;const a={timestamp:Md(),...e},l=s?pi(()=>s(a,t)):a;l!==null&&(n.emit&&n.emit("beforeAddBreadcrumb",l,t),r.addBreadcrumb(l,i))}let g_;const WU="FunctionToString",v_=new WeakMap,GU=()=>({name:WU,setupOnce(){g_=Function.prototype.toString;try{Function.prototype.toString=function(...e){const t=f0(this),n=v_.has(ct())&&t!==void 0?t:this;return g_.apply(n,e)}}catch{}},setup(e){v_.set(e,!0)}}),KU=GU,YU=[/^Script error\.?$/,/^Javascript error: Script error\.? on line 0$/,/^ResizeObserver loop completed with undelivered notifications.$/,/^Cannot redefine property: googletag$/,/^Can't find variable: gmo$/,/^undefined is not an object \(evaluating 'a\.[A-Z]'\)$/,`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",/^Non-Error promise rejection captured with value: Object Not Found Matching Id:\d+, MethodName:simulateEvent, ParamCount:\d+$/,/^Java exception was raised during method invocation$/],XU="EventFilters",QU=(e={})=>{let t;return{name:XU,setup(n){const r=n.getOptions();t=y_(e,r)},processEvent(n,r,s){if(!t){const i=s.getOptions();t=y_(e,i)}return ZU(n,t)?null:n}}},JU=(e={})=>({...QU(e),name:"InboundFilters"});function y_(e={},t={}){return{allowUrls:[...e.allowUrls||[],...t.allowUrls||[]],denyUrls:[...e.denyUrls||[],...t.denyUrls||[]],ignoreErrors:[...e.ignoreErrors||[],...t.ignoreErrors||[],...e.disableErrorDefaults?[]:YU],ignoreTransactions:[...e.ignoreTransactions||[],...t.ignoreTransactions||[]]}}function ZU(e,t){if(e.type){if(e.type==="transaction"&&t4(e,t.ignoreTransactions))return qe&&Pe.warn(`Event dropped due to being matched by \`ignoreTransactions\` option.
|
|
40
|
+
Event: ${ca(e)}`),!0}else{if(e4(e,t.ignoreErrors))return qe&&Pe.warn(`Event dropped due to being matched by \`ignoreErrors\` option.
|
|
41
|
+
Event: ${ca(e)}`),!0;if(i4(e))return qe&&Pe.warn(`Event dropped due to not having an error message, error type or stacktrace.
|
|
42
|
+
Event: ${ca(e)}`),!0;if(n4(e,t.denyUrls))return qe&&Pe.warn(`Event dropped due to being matched by \`denyUrls\` option.
|
|
43
|
+
Event: ${ca(e)}.
|
|
44
|
+
Url: ${Yh(e)}`),!0;if(!r4(e,t.allowUrls))return qe&&Pe.warn(`Event dropped due to not being matched by \`allowUrls\` option.
|
|
45
|
+
Event: ${ca(e)}.
|
|
46
|
+
Url: ${Yh(e)}`),!0}return!1}function e4(e,t){return t!=null&&t.length?UR(e).some(n=>Co(n,t)):!1}function t4(e,t){if(!(t!=null&&t.length))return!1;const n=e.transaction;return n?Co(n,t):!1}function n4(e,t){if(!(t!=null&&t.length))return!1;const n=Yh(e);return n?Co(n,t):!1}function r4(e,t){if(!(t!=null&&t.length))return!0;const n=Yh(e);return n?Co(n,t):!0}function s4(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 Yh(e){var t,n;try{const r=[...((t=e.exception)==null?void 0:t.values)??[]].reverse().find(i=>{var o,a,l;return((o=i.mechanism)==null?void 0:o.parent_id)===void 0&&((l=(a=i.stacktrace)==null?void 0:a.frames)==null?void 0:l.length)}),s=(n=r==null?void 0:r.stacktrace)==null?void 0:n.frames;return s?s4(s):null}catch{return qe&&Pe.error(`Cannot extract url for event ${ca(e)}`),null}}function i4(e){var t,n;return(n=(t=e.exception)==null?void 0:t.values)!=null&&n.length?!e.message&&!e.exception.values.some(r=>r.stacktrace||r.type&&r.type!=="Error"||r.value):!1}function o4(e,t,n,r,s,i){var a;if(!((a=s.exception)!=null&&a.values)||!i||!Vi(i.originalException,Error))return;const o=s.exception.values.length>0?s.exception.values[s.exception.values.length-1]:void 0;o&&(s.exception.values=dy(e,t,r,i.originalException,n,s.exception.values,o,0))}function dy(e,t,n,r,s,i,o,a){if(i.length>=n+1)return i;let l=[...i];if(Vi(r[s],Error)){b_(o,a);const u=e(t,r[s]),c=l.length;w_(u,s,c,a),l=dy(e,t,n,r[s],s,[u,...l],u,c)}return Array.isArray(r.errors)&&r.errors.forEach((u,c)=>{if(Vi(u,Error)){b_(o,a);const d=e(t,u),f=l.length;w_(d,`errors[${c}]`,f,a),l=dy(e,t,n,u,s,[d,...l],d,f)}}),l}function b_(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 w_(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 a4(e){const t="console";qo(t,e),Wo(t,l4)}function l4(){"console"in dt&&ey.forEach(function(e){e in dt.console&&Er(dt.console,e,function(t){return jh[e]=t,function(...n){ls("console",{args:n,level:e});const s=jh[e];s==null||s.apply(dt.console,n)}})})}function XR(e){return e==="warn"?"warning":["fatal","error","warning","log","info","debug"].includes(e)?e:"log"}const u4="Dedupe",c4=()=>{let e;return{name:u4,processEvent(t){if(t.type)return t;try{if(f4(t,e))return qe&&Pe.warn("Event dropped due to being a duplicate of previously captured event."),null}catch{}return e=t}}},d4=c4;function f4(e,t){return t?!!(h4(e,t)||p4(e,t)):!1}function h4(e,t){const n=e.message,r=t.message;return!(!n&&!r||n&&!r||!n&&r||n!==r||!JR(e,t)||!QR(e,t))}function p4(e,t){const n=S_(t),r=S_(e);return!(!n||!r||n.type!==r.type||n.value!==r.value||!JR(e,t)||!QR(e,t))}function QR(e,t){let n=Y1(e),r=Y1(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 JR(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 S_(e){var t;return((t=e.exception)==null?void 0:t.values)&&e.exception.values[0]}const m4="thismessage:/";function ZR(e){return"isRelative"in e}function g4(e,t){const n=e.indexOf("://")<=0&&e.indexOf("//")!==0,r=n?m4:void 0;try{if("canParse"in URL&&!URL.canParse(e,r))return;const s=new URL(e,r);return n?{isRelative:n,pathname:s.pathname,search:s.search,hash:s.hash}:s}catch{}}function v4(e){if(ZR(e))return e.pathname;const t=new URL(e);return t.search="",t.hash="",["80","443"].includes(t.port)&&(t.port=""),t.password&&(t.password="%filtered%"),t.username&&(t.username="%filtered%"),t.toString()}function Oa(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 y4(e){return e.split(/[?#]/,1)[0]}function b4(e,t,n,r,s="auto.http.browser"){if(!e.fetchData)return;const{method:i,url:o}=e.fetchData,a=Hi()&&t(o);if(e.endTimestamp&&a){const d=e.fetchData.__span;if(!d)return;const f=r[d];f&&(S4(f,e),delete r[d]);return}const l=!!Hn(),u=a&&l?Wa(k4(o,i,s)):new qa;if(e.fetchData.__span=u.spanContext().spanId,r[u.spanContext().spanId]=u,n(e.fetchData.url)){const d=e.args[0],f=e.args[1]||{},p=w4(d,f,Hi()&&l?u:void 0);p&&(e.args[1]=f,f.headers=p)}const c=ct();if(c){const d={input:e.args,response:e.response,startTimestamp:e.startTimestamp,endTimestamp:e.endTimestamp};c.emit("beforeOutgoingRequestSpan",u,d)}return u}function w4(e,t,n){const r=YR({span:n}),s=r["sentry-trace"],i=r.baggage;if(!s)return;const o=t.headers||(sR(e)?e.headers:void 0);if(o)if(_4(o)){const a=new Headers(o);if(a.get("sentry-trace")||a.set("sentry-trace",s),i){const l=a.get("baggage");l?cf(l)||a.set("baggage",`${l},${i}`):a.set("baggage",i)}return a}else if(Array.isArray(o)){const a=[...o];o.find(u=>u[0]==="sentry-trace")||a.push(["sentry-trace",s]);const l=o.find(u=>u[0]==="baggage"&&cf(u[1]));return i&&!l&&a.push(["baggage",i]),a}else{const a="sentry-trace"in o?o["sentry-trace"]:void 0,l="baggage"in o?o.baggage:void 0,u=l?Array.isArray(l)?[...l]:[l]:[],c=l&&(Array.isArray(l)?l.find(d=>cf(d)):cf(l));return i&&!c&&u.push(i),{...o,"sentry-trace":a??s,baggage:u.length>0?u.join(","):void 0}}else return{...r}}function S4(e,t){var n;if(t.response){fR(e,t.response.status);const r=((n=t.response)==null?void 0:n.headers)&&t.response.headers.get("content-length");if(r){const s=parseInt(r);s>0&&e.setAttribute("http.response_content_length",s)}}else t.error&&e.setStatus({code:Tn,message:"internal_error"});e.end()}function cf(e){return e.split(",").some(t=>t.trim().startsWith(g0))}function _4(e){return typeof Headers<"u"&&Vi(e,Headers)}function k4(e,t,n){const r=g4(e);return{name:r?`${t} ${v4(r)}`:t,attributes:x4(e,r,t,n)}}function x4(e,t,n,r){const s={url:e,type:"fetch","http.method":n,[on]:r,[za]:"http.client"};return t&&(ZR(t)||(s["http.url"]=t.href,s["server.address"]=t.host),t.search&&(s["http.query"]=t.search),t.hash&&(s["http.fragment"]=t.hash)),s}function eI(e){if(e!==void 0)return e>=400&&e<500?"warning":e>=500?"error":void 0}const Zc=dt;function E4(){return"history"in Zc&&!!Zc.history}function tI(){if(!("fetch"in Zc))return!1;try{return new Headers,new Request("http://www.example.com"),new Response,!0}catch{return!1}}function fy(e){return e&&/^function\s+\w+\(\)\s+\{\s+\[native code\]\s+\}$/.test(e.toString())}function C4(){var n;if(typeof EdgeRuntime=="string")return!0;if(!tI())return!1;if(fy(Zc.fetch))return!0;let e=!1;const t=Zc.document;if(t&&typeof t.createElement=="function")try{const r=t.createElement("iframe");r.hidden=!0,t.head.appendChild(r),(n=r.contentWindow)!=null&&n.fetch&&(e=fy(r.contentWindow.fetch)),t.head.removeChild(r)}catch(r){qe&&Pe.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",r)}return e}function nI(e,t){const n="fetch";qo(n,e),Wo(n,()=>rI(void 0,t))}function T4(e){const t="fetch-body-resolved";qo(t,e),Wo(t,()=>rI(R4))}function rI(e,t=!1){t&&!C4()||Er(dt,"fetch",function(n){return function(...r){const s=new Error,{method:i,url:o}=I4(r),a={args:r,fetchData:{method:i,url:o},startTimestamp:tr()*1e3,virtualError:s,headers:A4(r)};return e||ls("fetch",{...a}),n.apply(dt,r).then(async l=>(e?e(l):ls("fetch",{...a,endTimestamp:tr()*1e3,response:l}),l),l=>{if(ls("fetch",{...a,endTimestamp:tr()*1e3,error:l}),l0(l)&&l.stack===void 0&&(l.stack=s.stack,Wr(l,"framesToPop",1)),l instanceof TypeError&&(l.message==="Failed to fetch"||l.message==="Load failed"||l.message==="NetworkError when attempting to fetch resource."))try{const u=new URL(a.fetchData.url);l.message=`${l.message} (${u.host})`}catch{}throw l})}})}async function P4(e,t){if(e!=null&&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 R4(e){let t;try{t=e.clone()}catch{return}P4(t,()=>{ls("fetch-body-resolved",{endTimestamp:tr()*1e3,response:e})})}function hy(e,t){return!!e&&typeof e=="object"&&!!e[t]}function __(e){return typeof e=="string"?e:e?hy(e,"url")?e.url:e.toString?e.toString():"":""}function I4(e){if(e.length===0)return{method:"GET",url:""};if(e.length===2){const[n,r]=e;return{url:__(n),method:hy(r,"method")?String(r.method).toUpperCase():"GET"}}const t=e[0];return{url:__(t),method:hy(t,"method")?String(t.method).toUpperCase():"GET"}}function A4(e){const[t,n]=e;try{if(typeof n=="object"&&n!==null&&"headers"in n&&n.headers)return new Headers(n.headers);if(sR(t))return new Headers(t.headers)}catch{}}function O4(){return typeof __SENTRY_BROWSER_BUNDLE__<"u"&&!!__SENTRY_BROWSER_BUNDLE__}function M4(){return"npm"}function D4(){return!O4()&&Object.prototype.toString.call(typeof process<"u"?process:0)==="[object process]"}function k_(){return typeof window<"u"&&(!D4()||L4())}function L4(){const e=dt.process;return(e==null?void 0:e.type)==="renderer"}const wt=dt;let py=0;function sI(){return py>0}function $4(){py++,setTimeout(()=>{py--})}function lu(e,t={}){function n(s){return typeof s=="function"}if(!n(e))return e;try{const s=e.__sentry_wrapped__;if(s)return typeof s=="function"?s:e;if(f0(e))return e}catch{return e}const r=function(...s){try{const i=s.map(o=>lu(o,t));return e.apply(this,i)}catch(i){throw $4(),h0(o=>{o.addEventProcessor(a=>(t.mechanism&&(ty(a,void 0),iu(a,t.mechanism)),a.extra={...a.extra,arguments:s},a)),ai(i)}),i}};try{for(const s in e)Object.prototype.hasOwnProperty.call(e,s)&&(r[s]=e[s])}catch{}oR(r,e),Wr(e,"__sentry_wrapped__",r);try{Object.getOwnPropertyDescriptor(r,"name").configurable&&Object.defineProperty(r,"name",{get(){return e.name}})}catch{}return r}function S0(e,t){const n=_0(e,t),r={type:U4(t),value:z4(t)};return n.length&&(r.stacktrace={frames:n}),r.type===void 0&&r.value===""&&(r.value="Unrecoverable error caught"),r}function F4(e,t,n,r){const s=ct(),i=s==null?void 0:s.getOptions().normalizeDepth,o=G4(t),a={__serialized__:IR(t,i)};if(o)return{exception:{values:[S0(e,o)]},extra:a};const l={exception:{values:[{type:am(t)?t.constructor.name:r?"UnhandledRejection":"Error",value:q4(t,{isUnhandledRejection:r})}]},extra:a};if(n){const u=_0(e,n);u.length&&(l.exception.values[0].stacktrace={frames:u})}return l}function Tg(e,t){return{exception:{values:[S0(e,t)]}}}function _0(e,t){const n=t.stacktrace||t.stack||"",r=B4(t),s=V4(t);try{return e(n,r,s)}catch{}return[]}const N4=/Minified React error #\d+;/i;function B4(e){return e&&N4.test(e.message)?1:0}function V4(e){return typeof e.framesToPop=="number"?e.framesToPop:0}function iI(e){return typeof WebAssembly<"u"&&typeof WebAssembly.Exception<"u"?e instanceof WebAssembly.Exception:!1}function U4(e){const t=e==null?void 0:e.name;return!t&&iI(e)?e.message&&Array.isArray(e.message)&&e.message.length==2?e.message[0]:"WebAssembly.Exception":t}function z4(e){const t=e==null?void 0:e.message;return iI(e)?Array.isArray(e.message)&&e.message.length==2?e.message[1]:"wasm exception":t?t.error&&typeof t.error.message=="string"?t.error.message:t:"No error message"}function H4(e,t,n,r){const s=(n==null?void 0:n.syntheticException)||void 0,i=k0(e,t,s,r);return iu(i),i.level="error",n!=null&&n.event_id&&(i.event_id=n.event_id),qi(i)}function j4(e,t,n="info",r,s){const i=(r==null?void 0:r.syntheticException)||void 0,o=my(e,t,i,s);return o.level=n,r!=null&&r.event_id&&(o.event_id=r.event_id),qi(o)}function k0(e,t,n,r,s){let i;if(nR(t)&&t.error)return Tg(e,t.error);if(F1(t)||yV(t)){const o=t;if("stack"in t)i=Tg(e,t);else{const a=o.name||(F1(o)?"DOMError":"DOMException"),l=o.message?`${a}: ${o.message}`:a;i=my(e,l,n,r),ty(i,l)}return"code"in o&&(i.tags={...i.tags,"DOMException.code":`${o.code}`}),i}return l0(t)?Tg(e,t):Qc(t)||am(t)?(i=F4(e,t,n,s),iu(i,{synthetic:!0}),i):(i=my(e,t,n,r),ty(i,`${t}`),iu(i,{synthetic:!0}),i)}function my(e,t,n,r){const s={};if(r&&n){const i=_0(e,n);i.length&&(s.exception={values:[{value:t,stacktrace:{frames:i}}]}),iu(s,{synthetic:!0})}if(u0(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 q4(e,{isUnhandledRejection:t}){const n=TV(e),r=t?"promise rejection":"exception";return nR(e)?`Event \`ErrorEvent\` captured as ${r} with message \`${e.message}\``:am(e)?`Event \`${W4(e)}\` (type=${e.type}) captured as ${r}`:`Object captured as ${r} with keys: ${n}`}function W4(e){try{const t=Object.getPrototypeOf(e);return t?t.constructor.name:void 0}catch{}}function G4(e){for(const t in e)if(Object.prototype.hasOwnProperty.call(e,t)){const n=e[t];if(n instanceof Error)return n}}const K4=5e3;class Y4 extends EU{constructor(t){const n={parentSpanIsAlwaysRootSpan:!0,...t},r=wt.SENTRY_SDK_SOURCE||M4();KR(n,"browser",["browser"],r),super(n);const s=this,{sendDefaultPii:i,_experiments:o}=s._options,a=o==null?void 0:o.enableLogs;n.sendClientReports&&wt.document&&wt.document.addEventListener("visibilitychange",()=>{wt.document.visibilityState==="hidden"&&(this._flushOutcomes(),a&&Cg(s))}),a&&(s.on("flush",()=>{Cg(s)}),s.on("afterCaptureLog",()=>{s._logFlushIdleTimeout&&clearTimeout(s._logFlushIdleTimeout),s._logFlushIdleTimeout=setTimeout(()=>{Cg(s)},K4)})),i&&(s.on("postprocessEvent",zU),s.on("beforeSendSession",HU))}eventFromException(t,n){return H4(this._options.stackParser,t,n,this._options.attachStacktrace)}eventFromMessage(t,n="info",r){return j4(this._options.stackParser,t,n,r,this._options.attachStacktrace)}_prepareEvent(t,n,r,s){return t.platform=t.platform||"javascript",super._prepareEvent(t,n,r,s)}}const ed=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,X4=(e,t)=>e>t[1]?"poor":e>t[0]?"needs-improvement":"good",$u=(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=X4(t.value,n),e(t)))}},lt=dt,Q4=()=>`v4-${Date.now()}-${Math.floor(Math.random()*(9e12-1))+1e12}`,Nd=(e=!0)=>{var n,r;const t=(r=(n=lt.performance)==null?void 0:n.getEntriesByType)==null?void 0:r.call(n,"navigation")[0];if(!e||t&&t.responseStart>0&&t.responseStart<performance.now())return t},Bd=()=>{const e=Nd();return(e==null?void 0:e.activationStart)||0},Fu=(e,t)=>{var i,o;const n=Nd();let r="navigate";return n&&((i=lt.document)!=null&&i.prerendering||Bd()>0?r="prerender":(o=lt.document)!=null&&o.wasDiscarded?r="restore":n.type&&(r=n.type.replace(/_/g,"-"))),{name:e,value:typeof t>"u"?-1:t,rating:"good",delta:0,entries:[],id:Q4(),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{}},Nu=e=>{const t=n=>{var r;(n.type==="pagehide"||((r=lt.document)==null?void 0:r.visibilityState)==="hidden")&&e(n)};lt.document&&(addEventListener("visibilitychange",t,!0),addEventListener("pagehide",t,!0))},dm=e=>{let t=!1;return()=>{t||(e(),t=!0)}};let Cc=-1;const J4=()=>lt.document.visibilityState==="hidden"&&!lt.document.prerendering?0:1/0,Xh=e=>{lt.document.visibilityState==="hidden"&&Cc>-1&&(Cc=e.type==="visibilitychange"?e.timeStamp:0,e5())},Z4=()=>{addEventListener("visibilitychange",Xh,!0),addEventListener("prerenderingchange",Xh,!0)},e5=()=>{removeEventListener("visibilitychange",Xh,!0),removeEventListener("prerenderingchange",Xh,!0)},fm=()=>(lt.document&&Cc<0&&(Cc=J4(),Z4()),{get firstHiddenTime(){return Cc}}),Vd=e=>{var t;(t=lt.document)!=null&&t.prerendering?addEventListener("prerenderingchange",()=>e(),!0):e()},t5=[1800,3e3],n5=(e,t={})=>{Vd(()=>{const n=fm(),r=Fu("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=$u(e,r,t5,t.reportAllChanges))})},r5=[.1,.25],s5=(e,t={})=>{n5(dm(()=>{const n=Fu("CLS",0);let r,s=0,i=[];const o=l=>{l.forEach(u=>{if(!u.hadRecentInput){const c=i[0],d=i[i.length-1];s&&c&&d&&u.startTime-d.startTime<1e3&&u.startTime-c.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=$u(e,n,r5,t.reportAllChanges),Nu(()=>{o(a.takeRecords()),r(!0)}),setTimeout(r,0))}))},i5=[100,300],o5=(e,t={})=>{Vd(()=>{const n=fm(),r=Fu("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=$u(e,r,i5,t.reportAllChanges),a&&Nu(dm(()=>{o(a.takeRecords()),a.disconnect()}))})};let oI=0,Pg=1/0,df=0;const a5=e=>{e.forEach(t=>{t.interactionId&&(Pg=Math.min(Pg,t.interactionId),df=Math.max(df,t.interactionId),oI=df?(df-Pg)/7+1:0)})};let gy;const l5=()=>gy?oI:performance.interactionCount||0,u5=()=>{"interactionCount"in performance||gy||(gy=il("event",a5,{type:"event",buffered:!0,durationThreshold:0}))},Pi=[],Rg=new Map,c5=40;let d5=0;const f5=()=>l5()-d5,h5=()=>{const e=Math.min(Pi.length-1,Math.floor(f5()/50));return Pi[e]},Ig=10,p5=[],m5=e=>{var r;if(p5.forEach(s=>s(e)),!(e.interactionId||e.entryType==="first-input"))return;const t=Pi[Pi.length-1],n=Rg.get(e.interactionId);if(n||Pi.length<Ig||t&&e.duration>t.latency){if(n)e.duration>n.latency?(n.entries=[e],n.latency=e.duration):e.duration===n.latency&&e.startTime===((r=n.entries[0])==null?void 0:r.startTime)&&n.entries.push(e);else{const s={id:e.interactionId,latency:e.duration,entries:[e]};Rg.set(s.id,s),Pi.push(s)}Pi.sort((s,i)=>i.latency-s.latency),Pi.length>Ig&&Pi.splice(Ig).forEach(s=>Rg.delete(s.id))}},aI=e=>{var r;const t=lt.requestIdleCallback||lt.setTimeout;let n=-1;return e=dm(e),((r=lt.document)==null?void 0:r.visibilityState)==="hidden"?e():(n=t(e),Nu(e)),n},g5=[200,500],v5=(e,t={})=>{"PerformanceEventTiming"in lt&&"interactionId"in PerformanceEventTiming.prototype&&Vd(()=>{u5();const n=Fu("INP");let r;const s=o=>{aI(()=>{o.forEach(m5);const a=h5();a&&a.latency!==n.value&&(n.value=a.latency,n.entries=a.entries,r())})},i=il("event",s,{durationThreshold:t.durationThreshold!=null?t.durationThreshold:c5});r=$u(e,n,g5,t.reportAllChanges),i&&(i.observe({type:"first-input",buffered:!0}),Nu(()=>{s(i.takeRecords()),r(!0)}))})},y5=[2500,4e3],x_={},b5=(e,t={})=>{Vd(()=>{const n=fm(),r=Fu("LCP");let s;const i=a=>{t.reportAllChanges||(a=a.slice(-1)),a.forEach(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=$u(e,r,y5,t.reportAllChanges);const a=dm(()=>{x_[r.id]||(i(o.takeRecords()),o.disconnect(),x_[r.id]=!0,s(!0))});["keydown","click"].forEach(l=>{lt.document&&addEventListener(l,()=>aI(a),{once:!0,capture:!0})}),Nu(a)}})},w5=[800,1800],vy=e=>{var t,n;(t=lt.document)!=null&&t.prerendering?Vd(()=>vy(e)):((n=lt.document)==null?void 0:n.readyState)!=="complete"?addEventListener("load",()=>vy(e),!0):setTimeout(e,0)},S5=(e,t={})=>{const n=Fu("TTFB"),r=$u(e,n,w5,t.reportAllChanges);vy(()=>{const s=Nd();s&&(n.value=Math.max(s.responseStart-Bd(),0),n.entries=[s],r(!0))})},Tc={},Qh={};let lI,uI,cI,dI,fI;function x0(e,t=!1){return Ud("cls",e,k5,lI,t)}function hI(e,t=!1){return Ud("lcp",e,E5,cI,t)}function pI(e){return Ud("fid",e,x5,uI)}function _5(e){return Ud("ttfb",e,C5,dI)}function mI(e){return Ud("inp",e,T5,fI)}function uu(e,t){return gI(e,t),Qh[e]||(P5(e),Qh[e]=!0),vI(e,t)}function Bu(e,t){const n=Tc[e];if(n!=null&&n.length)for(const r of n)try{r(t)}catch(s){ed&&Pe.error(`Error while triggering instrumentation handler.
|
|
47
|
+
Type: ${e}
|
|
48
|
+
Name: ${zi(r)}
|
|
49
|
+
Error:`,s)}}function k5(){return s5(e=>{Bu("cls",{metric:e}),lI=e},{reportAllChanges:!0})}function x5(){return o5(e=>{Bu("fid",{metric:e}),uI=e})}function E5(){return b5(e=>{Bu("lcp",{metric:e}),cI=e},{reportAllChanges:!0})}function C5(){return S5(e=>{Bu("ttfb",{metric:e}),dI=e})}function T5(){return v5(e=>{Bu("inp",{metric:e}),fI=e})}function Ud(e,t,n,r,s=!1){gI(e,t);let i;return Qh[e]||(i=n(),Qh[e]=!0),r&&t({metric:r}),vI(e,t,s?i:void 0)}function P5(e){const t={};e==="event"&&(t.durationThreshold=0),il(e,n=>{Bu(e,{entries:n})},t)}function gI(e,t){Tc[e]=Tc[e]||[],Tc[e].push(t)}function vI(e,t,n){return()=>{n&&n();const r=Tc[e];if(!r)return;const s=r.indexOf(t);s!==-1&&r.splice(s,1)}}function R5(e){return"duration"in e}function Ag(e){return typeof e=="number"&&isFinite(e)}function Wi(e,t,n,{...r}){const s=kt(e).start_timestamp;return s&&s>t&&typeof e.updateStartTime=="function"&&e.updateStartTime(t),MR(e,()=>{const i=Wa({startTime:t,...r});return i&&i.end(n),i})}function yI(e){var y;const t=ct();if(!t)return;const{name:n,transaction:r,attributes:s,startTime:i}=e,{release:o,environment:a,sendDefaultPii:l}=t.getOptions(),u=t.getIntegrationByName("Replay"),c=u==null?void 0:u.getReplayId(),d=Vt(),f=d.getUser(),p=f!==void 0?f.email||f.id||f.ip_address:void 0;let g;try{g=d.getScopeData().contexts.profile.profile_id}catch{}const m={release:o,environment:a,user:p||void 0,profile_id:g||void 0,replay_id:c||void 0,transaction:r,"user_agent.original":(y=lt.navigator)==null?void 0:y.userAgent,"client.address":l?"{{auto}}":void 0,...s};return Wa({name:n,attributes:m,startTime:i,experimental:{standalone:!0}})}function E0(){return lt.addEventListener&<.performance}function pn(e){return e/1e3}function bI(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 I5(){let e=0,t,n;if(!O5())return;let r=!1;function s(){r||(r=!0,n&&A5(e,t,n),i())}const i=x0(({metric:o})=>{const a=o.entries[o.entries.length-1];a&&(e=o.value,t=a)},!0);Nu(()=>{s()}),setTimeout(()=>{const o=ct();if(!o)return;const a=o.on("startNavigationSpan",()=>{s(),a==null||a()}),l=Hn();if(l){const u=Vn(l);kt(u).op==="pageload"&&(n=u.spanContext().spanId)}},0)}function A5(e,t,n){var l;ed&&Pe.log(`Sending CLS span (${e})`);const r=pn((Yr()||0)+((t==null?void 0:t.startTime)||0)),s=Vt().getScopeData().transactionName,i=t?Ui((l=t.sources[0])==null?void 0:l.node):"Layout shift",o={[on]:"auto.http.browser.cls",[za]:"ui.webvital.cls",[$d]:(t==null?void 0:t.duration)||0,"sentry.pageload.span_id":n},a=yI({name:i,transaction:s,attributes:o,startTime:r});a&&(a.addEvent("cls",{[um]:"",[cm]:e}),a.end(r))}function O5(){try{return PerformanceObserver.supportedEntryTypes.includes("layout-shift")}catch{return!1}}const M5=2147483647;let E_=0,Ln={},br,Tl;function D5({recordClsStandaloneSpans:e}){const t=E0();if(t&&Yr()){t.mark&<.performance.mark("sentry-tracing-init");const n=V5(),r=B5(),s=U5(),i=e?I5():N5();return()=>{n(),r(),s(),i==null||i()}}return()=>{}}function L5(){uu("longtask",({entries:e})=>{const t=Hn();if(!t)return;const{op:n,start_timestamp:r}=kt(t);for(const s of e){const i=pn(Yr()+s.startTime),o=pn(s.duration);n==="navigation"&&r&&i<r||Wi(t,i,i+o,{name:"Main UI thread blocked",op:"ui.long-task",attributes:{[on]:"auto.ui.browser.metrics"}})}})}function $5(){new PerformanceObserver(t=>{const n=Hn();if(n)for(const r of t.getEntries()){if(!r.scripts[0])continue;const s=pn(Yr()+r.startTime),{start_timestamp:i,op:o}=kt(n);if(o==="navigation"&&i&&s<i)continue;const a=pn(r.duration),l={[on]:"auto.ui.browser.metrics"},u=r.scripts[0],{invoker:c,invokerType:d,sourceURL:f,sourceFunctionName:p,sourceCharPosition:g}=u;l["browser.script.invoker"]=c,l["browser.script.invoker_type"]=d,f&&(l["code.filepath"]=f),p&&(l["code.function"]=p),g!==-1&&(l["browser.script.source_char_position"]=g),Wi(n,s,s+a,{name:"Main UI thread blocked",op:"ui.long-animation-frame",attributes:l})}}).observe({type:"long-animation-frame",buffered:!0})}function F5(){uu("event",({entries:e})=>{const t=Hn();if(t){for(const n of e)if(n.name==="click"){const r=pn(Yr()+n.startTime),s=pn(n.duration),i={name:Ui(n.target),op:`ui.interaction.${n.name}`,startTime:r,attributes:{[on]:"auto.ui.browser.metrics"}},o=iR(n.target);o&&(i.attributes["ui.component_name"]=o),Wi(t,r,r+s,i)}}})}function N5(){return x0(({metric:e})=>{const t=e.entries[e.entries.length-1];t&&(Ln.cls={value:e.value,unit:""},Tl=t)},!0)}function B5(){return hI(({metric:e})=>{const t=e.entries[e.entries.length-1];t&&(Ln.lcp={value:e.value,unit:"millisecond"},br=t)},!0)}function V5(){return pI(({metric:e})=>{const t=e.entries[e.entries.length-1];if(!t)return;const n=pn(Yr()),r=pn(t.startTime);Ln.fid={value:e.value,unit:"millisecond"},Ln["mark.fid"]={value:n+r,unit:"second"}})}function U5(){return _5(({metric:e})=>{e.entries[e.entries.length-1]&&(Ln.ttfb={value:e.value,unit:"millisecond"})})}function z5(e,t){const n=E0(),r=Yr();if(!(n!=null&&n.getEntries)||!r)return;const s=pn(r),i=n.getEntries(),{op:o,start_timestamp:a}=kt(e);if(i.slice(E_).forEach(l=>{const u=pn(l.startTime),c=pn(Math.max(0,l.duration));if(!(o==="navigation"&&a&&s+u<a))switch(l.entryType){case"navigation":{j5(e,l,s);break}case"mark":case"paint":case"measure":{H5(e,l,u,c,s);const d=fm(),f=l.startTime<d.firstHiddenTime;l.name==="first-paint"&&f&&(Ln.fp={value:l.startTime,unit:"millisecond"}),l.name==="first-contentful-paint"&&f&&(Ln.fcp={value:l.startTime,unit:"millisecond"});break}case"resource":{G5(e,l,l.name,u,c,s);break}}}),E_=Math.max(i.length-1,0),K5(e),o==="pageload"){X5(Ln);const l=Ln["mark.fid"];l&&Ln.fid&&(Wi(e,l.value,l.value+pn(Ln.fid.value),{name:"first input delay",op:"ui.action",attributes:{[on]:"auto.ui.browser.metrics"}}),delete Ln["mark.fid"]),(!("fcp"in Ln)||!t.recordClsOnPageloadSpan)&&delete Ln.cls,Object.entries(Ln).forEach(([u,c])=>{$3(u,c.value,c.unit)}),e.setAttribute("performance.timeOrigin",s),e.setAttribute("performance.activationStart",Bd()),Y5(e)}br=void 0,Tl=void 0,Ln={}}function H5(e,t,n,r,s){const i=Nd(!1),o=pn(i?i.requestStart:0),a=s+Math.max(n,o),l=s+n,u=l+r,c={[on]:"auto.resource.browser.metrics"};a!==l&&(c["sentry.browser.measure_happened_before_request"]=!0,c["sentry.browser.measure_start_time"]=a),a<=u&&Wi(e,a,u,{name:t.name,op:t.entryType,attributes:c})}function j5(e,t,n){["unloadEvent","redirect","domContentLoadedEvent","loadEvent","connect"].forEach(r=>{ff(e,t,r,n)}),ff(e,t,"secureConnection",n,"TLS/SSL"),ff(e,t,"fetch",n,"cache"),ff(e,t,"domainLookup",n,"DNS"),W5(e,t,n)}function ff(e,t,n,r,s=n){const i=q5(n),o=t[i],a=t[`${n}Start`];!a||!o||Wi(e,r+pn(a),r+pn(o),{op:`browser.${s}`,name:t.name,attributes:{[on]:"auto.ui.browser.metrics",...n==="redirect"&&t.redirectCount!=null?{"http.redirect_count":t.redirectCount}:{}}})}function q5(e){return e==="secureConnection"?"connectEnd":e==="fetch"?"domainLookupStart":`${e}End`}function W5(e,t,n){const r=n+pn(t.requestStart),s=n+pn(t.responseEnd),i=n+pn(t.responseStart);t.responseEnd&&(Wi(e,r,s,{op:"browser.request",name:t.name,attributes:{[on]:"auto.ui.browser.metrics"}}),Wi(e,i,s,{op:"browser.response",name:t.name,attributes:{[on]:"auto.ui.browser.metrics"}}))}function G5(e,t,n,r,s,i){if(t.initiatorType==="xmlhttprequest"||t.initiatorType==="fetch")return;const o=Oa(n),a={[on]:"auto.resource.browser.metrics"};Og(a,t,"transferSize","http.response_transfer_size"),Og(a,t,"encodedBodySize","http.response_content_length"),Og(a,t,"decodedBodySize","http.decoded_response_content_length");const l=t.deliveryType;l!=null&&(a["http.response_delivery_type"]=l);const u=t.renderBlockingStatus;u&&(a["resource.render_blocking_status"]=u),o.protocol&&(a["url.scheme"]=o.protocol.split(":").pop()),o.host&&(a["server.address"]=o.host),a["url.same_origin"]=n.includes(lt.location.origin);const{name:c,version:d}=bI(t.nextHopProtocol);a["network.protocol.name"]=c,a["network.protocol.version"]=d;const f=i+r,p=f+s;Wi(e,f,p,{name:n.replace(lt.location.origin,""),op:t.initiatorType?`resource.${t.initiatorType}`:"resource.other",attributes:a})}function K5(e){const t=lt.navigator;if(!t)return;const n=t.connection;n&&(n.effectiveType&&e.setAttribute("effectiveConnectionType",n.effectiveType),n.type&&e.setAttribute("connectionType",n.type),Ag(n.rtt)&&(Ln["connection.rtt"]={value:n.rtt,unit:"millisecond"})),Ag(t.deviceMemory)&&e.setAttribute("deviceMemory",`${t.deviceMemory} GB`),Ag(t.hardwareConcurrency)&&e.setAttribute("hardwareConcurrency",String(t.hardwareConcurrency))}function Y5(e){br&&(br.element&&e.setAttribute("lcp.element",Ui(br.element)),br.id&&e.setAttribute("lcp.id",br.id),br.url&&e.setAttribute("lcp.url",br.url.trim().slice(0,200)),br.loadTime!=null&&e.setAttribute("lcp.loadTime",br.loadTime),br.renderTime!=null&&e.setAttribute("lcp.renderTime",br.renderTime),e.setAttribute("lcp.size",br.size)),Tl!=null&&Tl.sources&&Tl.sources.forEach((t,n)=>e.setAttribute(`cls.source.${n+1}`,Ui(t.node)))}function Og(e,t,n,r){const s=t[n];s!=null&&s<M5&&(e[r]=s)}function X5(e){const t=Nd(!1);if(!t)return;const{responseStart:n,requestStart:r}=t;r<=n&&(e["ttfb.requestTime"]={value:n-r,unit:"millisecond"})}const Q5=1e3;let C_,yy,by;function wI(e){const t="dom";qo(t,e),Wo(t,J5)}function J5(){if(!lt.document)return;const e=ls.bind(null,"dom"),t=T_(e,!0);lt.document.addEventListener("click",t,!1),lt.document.addEventListener("keypress",t,!1),["EventTarget","Node"].forEach(n=>{var i,o;const s=(i=lt[n])==null?void 0:i.prototype;(o=s==null?void 0:s.hasOwnProperty)!=null&&o.call(s,"addEventListener")&&(Er(s,"addEventListener",function(a){return function(l,u,c){if(l==="click"||l=="keypress")try{const d=this.__sentry_instrumentation_handlers__=this.__sentry_instrumentation_handlers__||{},f=d[l]=d[l]||{refCount:0};if(!f.handler){const p=T_(e);f.handler=p,a.call(this,l,p,c)}f.refCount++}catch{}return a.call(this,l,u,c)}}),Er(s,"removeEventListener",function(a){return function(l,u,c){if(l==="click"||l=="keypress")try{const d=this.__sentry_instrumentation_handlers__||{},f=d[l];f&&(f.refCount--,f.refCount<=0&&(a.call(this,l,f.handler,c),f.handler=void 0,delete d[l]),Object.keys(d).length===0&&delete this.__sentry_instrumentation_handlers__)}catch{}return a.call(this,l,u,c)}}))})}function Z5(e){if(e.type!==yy)return!1;try{if(!e.target||e.target._sentryId!==by)return!1}catch{}return!0}function ez(e,t){return e!=="keypress"?!1:t!=null&&t.tagName?!(t.tagName==="INPUT"||t.tagName==="TEXTAREA"||t.isContentEditable):!0}function T_(e,t=!1){return n=>{if(!n||n._sentryCaptured)return;const r=tz(n);if(ez(n.type,r))return;Wr(n,"_sentryCaptured",!0),r&&!r._sentryId&&Wr(r,"_sentryId",jr());const s=n.type==="keypress"?"input":n.type;Z5(n)||(e({event:n,name:s,global:t}),yy=n.type,by=r?r._sentryId:void 0),clearTimeout(C_),C_=lt.setTimeout(()=>{by=void 0,yy=void 0},Q5)}}function tz(e){try{return e.target}catch{return null}}let hf;function hm(e){const t="history";qo(t,e),Wo(t,nz)}function nz(){if(lt.addEventListener("popstate",()=>{const t=lt.location.href,n=hf;if(hf=t,n===t)return;ls("history",{from:n,to:t})}),!E4())return;function e(t){return function(...n){const r=n.length>2?n[2]:void 0;if(r){const s=hf,i=String(r);if(hf=i,s===i)return t.apply(this,n);ls("history",{from:s,to:i})}return t.apply(this,n)}}Er(lt.history,"pushState",e),Er(lt.history,"replaceState",e)}const sh={};function SI(e){const t=sh[e];if(t)return t;let n=lt[e];if(fy(n))return sh[e]=n.bind(lt);const r=lt.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!=null&&i[e]&&(n=i[e]),r.head.removeChild(s)}catch(s){ed&&Pe.warn(`Could not create sandbox iframe for ${e} check, bailing to window.${e}: `,s)}return n&&(sh[e]=n.bind(lt))}function P_(e){sh[e]=void 0}function cu(...e){return SI("setTimeout")(...e)}const ha="__sentry_xhr_v3__";function _I(e){const t="xhr";qo(t,e),Wo(t,rz)}function rz(){if(!lt.XMLHttpRequest)return;const e=XMLHttpRequest.prototype;e.open=new Proxy(e.open,{apply(t,n,r){const s=new Error,i=tr()*1e3,o=Di(r[0])?r[0].toUpperCase():void 0,a=sz(r[1]);if(!o||!a)return t.apply(n,r);n[ha]={method:o,url:a,request_headers:{}},o==="POST"&&a.match(/sentry_key/)&&(n.__sentry_own_request__=!0);const l=()=>{const u=n[ha];if(u&&n.readyState===4){try{u.status_code=n.status}catch{}const c={endTimestamp:tr()*1e3,startTimestamp:i,xhr:n,virtualError:s};ls("xhr",c)}};return"onreadystatechange"in n&&typeof n.onreadystatechange=="function"?n.onreadystatechange=new Proxy(n.onreadystatechange,{apply(u,c,d){return l(),u.apply(c,d)}}):n.addEventListener("readystatechange",l),n.setRequestHeader=new Proxy(n.setRequestHeader,{apply(u,c,d){const[f,p]=d,g=c[ha];return g&&Di(f)&&Di(p)&&(g.request_headers[f.toLowerCase()]=p),u.apply(c,d)}}),t.apply(n,r)}}),e.send=new Proxy(e.send,{apply(t,n,r){const s=n[ha];if(!s)return t.apply(n,r);r[0]!==void 0&&(s.body=r[0]);const i={startTimestamp:tr()*1e3,xhr:n};return ls("xhr",i),t.apply(n,r)}})}function sz(e){if(Di(e))return e;try{return e.toString()}catch{}}function kI(e){return new URLSearchParams(e).toString()}function xI(e,t=Pe){try{if(typeof e=="string")return[e];if(e instanceof URLSearchParams)return[e.toString()];if(e instanceof FormData)return[kI(e)];if(!e)return[void 0]}catch(n){return ed&&t.error(n,"Failed to serialize body",e),[void 0,"BODY_PARSE_ERROR"]}return ed&&t.info("Skipping network body because of body type",e),[void 0,"UNPARSEABLE_BODY_TYPE"]}function EI(e=[]){if(!(e.length!==2||typeof e[1]!="object"))return e[1].body}const Mg=[],ih=new Map;function iz(){if(E0()&&Yr()){const t=oz();return()=>{t()}}return()=>{}}const R_={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 oz(){return mI(({metric:e})=>{if(e.value==null)return;const t=e.entries.find(g=>g.duration===e.value&&R_[g.name]);if(!t)return;const{interactionId:n}=t,r=R_[t.name],s=pn(Yr()+t.startTime),i=pn(e.value),o=Hn(),a=o?Vn(o):void 0,u=(n!=null?ih.get(n):void 0)||a,c=u?kt(u).description:Vt().getScopeData().transactionName,d=Ui(t.target),f={[on]:"auto.http.browser.inp",[za]:`ui.interaction.${r}`,[$d]:t.duration},p=yI({name:d,transaction:c,attributes:f,startTime:s});p&&(p.addEvent("inp",{[um]:"millisecond",[cm]:e.value}),p.end(s+i))})}function az(){const e=({entries:t})=>{const n=Hn(),r=n&&Vn(n);t.forEach(s=>{if(!R5(s)||!r)return;const i=s.interactionId;if(i!=null&&!ih.has(i)){if(Mg.length>10){const o=Mg.shift();ih.delete(o)}Mg.push(i),ih.set(i,r)}})};uu("event",e),uu("first-input",e)}function lz(e,t=SI("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:"strict-origin",headers:e.headers,keepalive:n<=6e4&&r<15,...e.fetchOptions};if(!t)return P_("fetch"),Kh("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 P_("fetch"),n-=o,r--,Kh(l)}}return NU(e,s)}const uz=30,cz=50;function wy(e,t,n,r){const s={filename:e,function:t==="<anonymous>"?ja:t,in_app:!0};return n!==void 0&&(s.lineno=n),r!==void 0&&(s.colno=r),s}const dz=/^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i,fz=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,hz=/\((\S*)(?::(\d+))(?::(\d+))\)/,pz=e=>{const t=dz.exec(e);if(t){const[,r,s,i]=t;return wy(r,ja,+s,+i)}const n=fz.exec(e);if(n){if(n[2]&&n[2].indexOf("eval")===0){const o=hz.exec(n[2]);o&&(n[2]=o[1],n[3]=o[2],n[4]=o[3])}const[s,i]=CI(n[1]||ja,n[2]);return wy(i,s,n[3]?+n[3]:void 0,n[4]?+n[4]:void 0)}},mz=[uz,pz],gz=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,vz=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,yz=e=>{const t=gz.exec(e);if(t){if(t[3]&&t[3].indexOf(" > eval")>-1){const i=vz.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]||ja;return[s,r]=CI(s,r),wy(r,s,t[4]?+t[4]:void 0,t[5]?+t[5]:void 0)}},bz=[cz,yz],wz=[mz,bz],Sz=kR(...wz),CI=(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]:ja,n?`safari-extension:${t}`:`safari-web-extension:${t}`]:[e,t]},cs=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,pf=1024,_z="Breadcrumbs",kz=(e={})=>{const t={console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0,...e};return{name:_z,setup(n){t.console&&a4(Tz(n)),t.dom&&wI(Cz(n,t.dom)),t.xhr&&_I(Pz(n)),t.fetch&&nI(Rz(n)),t.history&&hm(Iz(n)),t.sentry&&n.on("beforeSendEvent",Ez(n))}}},xz=kz;function Ez(e){return function(n){ct()===e&&Lo({category:`sentry.${n.type==="transaction"?"transaction":"event"}`,event_id:n.event_id,level:n.level,message:ca(n)},{event:n})}}function Cz(e,t){return function(r){if(ct()!==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>pf&&(cs&&Pe.warn(`\`dom.maxStringLength\` cannot exceed ${pf}, but a value of ${a} was configured. Sentry will use ${pf} instead.`),a=pf),typeof o=="string"&&(o=[o]);try{const u=r.event,c=Az(u)?u.target:u;s=Ui(c,{keyAttrs:o,maxStringLength:a}),i=iR(c)}catch{s="<unknown>"}if(s.length===0)return;const l={category:`ui.${r.name}`,message:s};i&&(l.data={"ui.component_name":i}),Lo(l,{event:r.event,name:r.name,global:r.global})}}function Tz(e){return function(n){if(ct()!==e)return;const r={category:"console",data:{arguments:n.args,logger:"console"},level:XR(n.level),message:N1(n.args," ")};if(n.level==="assert")if(n.args[0]===!1)r.message=`Assertion failed: ${N1(n.args.slice(1)," ")||"console.assert"}`,r.data.arguments=n.args.slice(1);else return;Lo(r,{input:n.args,level:n.level})}}function Pz(e){return function(n){if(ct()!==e)return;const{startTimestamp:r,endTimestamp:s}=n,i=n.xhr[ha];if(!r||!s||!i)return;const{method:o,url:a,status_code:l,body:u}=i,c={method:o,url:a,status_code:l},d={xhr:n.xhr,input:u,startTimestamp:r,endTimestamp:s},f={category:"xhr",data:c,type:"http",level:eI(l)};e.emit("beforeOutgoingRequestBreadcrumb",f,d),Lo(f,d)}}function Rz(e){return function(n){if(ct()!==e)return;const{startTimestamp:r,endTimestamp:s}=n;if(s&&!(n.fetchData.url.match(/sentry_key/)&&n.fetchData.method==="POST"))if(n.fetchData.method,n.fetchData.url,n.error){const i=n.fetchData,o={data:n.error,input:n.args,startTimestamp:r,endTimestamp:s},a={category:"fetch",data:i,level:"error",type:"http"};e.emit("beforeOutgoingRequestBreadcrumb",a,o),Lo(a,o)}else{const i=n.response,o={...n.fetchData,status_code:i==null?void 0:i.status};n.fetchData.request_body_size,n.fetchData.response_body_size,i==null||i.status;const a={input:n.args,response:i,startTimestamp:r,endTimestamp:s},l={category:"fetch",data:o,type:"http",level:eI(o.status_code)};e.emit("beforeOutgoingRequestBreadcrumb",l,a),Lo(l,a)}}}function Iz(e){return function(n){if(ct()!==e)return;let r=n.from,s=n.to;const i=Oa(wt.location.href);let o=r?Oa(r):void 0;const a=Oa(s);o!=null&&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),Lo({category:"navigation",data:{from:r,to:s}})}}function Az(e){return!!e&&!!e.target}const Oz=["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"],Mz="BrowserApiErrors",Dz=(e={})=>{const t={XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0,...e};return{name:Mz,setupOnce(){t.setTimeout&&Er(wt,"setTimeout",I_),t.setInterval&&Er(wt,"setInterval",I_),t.requestAnimationFrame&&Er(wt,"requestAnimationFrame",$z),t.XMLHttpRequest&&"XMLHttpRequest"in wt&&Er(XMLHttpRequest.prototype,"send",Fz);const n=t.eventTarget;n&&(Array.isArray(n)?n:Oz).forEach(Nz)}}},Lz=Dz;function I_(e){return function(...t){const n=t[0];return t[0]=lu(n,{mechanism:{data:{function:zi(e)},handled:!1,type:"instrument"}}),e.apply(this,t)}}function $z(e){return function(t){return e.apply(this,[lu(t,{mechanism:{data:{function:"requestAnimationFrame",handler:zi(e)},handled:!1,type:"instrument"}})])}}function Fz(e){return function(...t){const n=this;return["onload","onerror","onprogress","onreadystatechange"].forEach(s=>{s in n&&typeof n[s]=="function"&&Er(n,s,function(i){const o={mechanism:{data:{function:s,handler:zi(i)},handled:!1,type:"instrument"}},a=f0(i);return a&&(o.mechanism.data.handler=zi(a)),lu(i,o)})}),e.apply(this,t)}}function Nz(e){var r,s;const n=(r=wt[e])==null?void 0:r.prototype;(s=n==null?void 0:n.hasOwnProperty)!=null&&s.call(n,"addEventListener")&&(Er(n,"addEventListener",function(i){return function(o,a,l){try{Bz(a)&&(a.handleEvent=lu(a.handleEvent,{mechanism:{data:{function:"handleEvent",handler:zi(a),target:e},handled:!1,type:"instrument"}}))}catch{}return i.apply(this,[o,lu(a,{mechanism:{data:{function:"addEventListener",handler:zi(a),target:e},handled:!1,type:"instrument"}}),l])}}),Er(n,"removeEventListener",function(i){return function(o,a,l){try{const u=a.__sentry_wrapped__;u&&i.call(this,o,u,l)}catch{}return i.call(this,o,a,l)}}))}function Bz(e){return typeof e.handleEvent=="function"}const Vz=()=>({name:"BrowserSession",setupOnce(){if(typeof wt.document>"u"){cs&&Pe.warn("Using the `browserSessionIntegration` in non-browser environments is not supported.");return}a_({ignoreDuration:!0}),l_(),hm(({from:e,to:t})=>{e!==void 0&&e!==t&&(a_({ignoreDuration:!0}),l_())})}}),Uz="GlobalHandlers",zz=(e={})=>{const t={onerror:!0,onunhandledrejection:!0,...e};return{name:Uz,setupOnce(){Error.stackTraceLimit=50},setup(n){t.onerror&&(jz(n),A_("onerror")),t.onunhandledrejection&&(qz(n),A_("onunhandledrejection"))}}},Hz=zz;function jz(e){xR(t=>{const{stackParser:n,attachStacktrace:r}=TI();if(ct()!==e||sI())return;const{msg:s,url:i,line:o,column:a,error:l}=t,u=Kz(k0(n,l||s,void 0,r,!1),i,o,a);u.level="error",FR(u,{originalException:l,mechanism:{handled:!1,type:"onerror"}})})}function qz(e){ER(t=>{const{stackParser:n,attachStacktrace:r}=TI();if(ct()!==e||sI())return;const s=Wz(t),i=c0(s)?Gz(s):k0(n,s,void 0,r,!0);i.level="error",FR(i,{originalException:s,mechanism:{handled:!1,type:"onunhandledrejection"}})})}function Wz(e){if(c0(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 Gz(e){return{exception:{values:[{type:"UnhandledRejection",value:`Non-Error promise rejection captured with value: ${String(e)}`}]}}}function Kz(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=r,c=n,d=Di(t)&&t.length>0?t:Du();return l.length===0&&l.push({colno:u,filename:d,function:ja,in_app:!0,lineno:c}),e}function A_(e){cs&&Pe.log(`Global Handler attached: ${e}`)}function TI(){const e=ct();return(e==null?void 0:e.getOptions())||{stackParser:()=>[],attachStacktrace:!1}}const Yz=()=>({name:"HttpContext",preprocessEvent(e){var o,a;if(!wt.navigator&&!wt.location&&!wt.document)return;const t=((o=e.request)==null?void 0:o.url)||Du(),{referrer:n}=wt.document||{},{userAgent:r}=wt.navigator||{},s={...(a=e.request)==null?void 0:a.headers,...n&&{Referer:n},...r&&{"User-Agent":r}},i={...e.request,...t&&{url:t},headers:s};e.request=i}}),Xz="cause",Qz=5,Jz="LinkedErrors",Zz=(e={})=>{const t=e.limit||Qz,n=e.key||Xz;return{name:Jz,preprocessEvent(r,s,i){const o=i.getOptions();o4(S0,o.stackParser,n,t,r,s)}}},eH=Zz;function PI(e){return[JU(),KU(),Lz(),xz(),Hz(),eH(),d4(),Yz(),Vz()]}function tH(e={}){var n;return{...{defaultIntegrations:PI(),release:typeof __SENTRY_RELEASE__=="string"?__SENTRY_RELEASE__:(n=wt.SENTRY_RELEASE)==null?void 0:n.id,sendClientReports:!0},...nH(e)}}function nH(e){const t={};for(const n of Object.getOwnPropertyNames(e)){const r=n;e[r]!==void 0&&(t[r]=e[r])}return t}function rH(){var l;const e=typeof wt.window<"u"&&wt;if(!e)return!1;const t=e.chrome?"chrome":"browser",n=e[t],r=(l=n==null?void 0:n.runtime)==null?void 0:l.id,s=Du()||"",i=["chrome-extension:","moz-extension:","ms-browser-extension:","safari-web-extension:"],o=!!r&&wt===wt.top&&i.some(u=>s.startsWith(`${u}//`)),a=typeof e.nw<"u";return!!r&&!o&&!a}function sH(e={}){const t=tH(e);if(!t.skipBrowserExtensionCheck&&rH()){cs&&pi(()=>{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}cs&&!tI()&&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:l3(t.stackParser||Sz),integrations:wU(t),transport:t.transport||lz};return AU(Y4,n)}const qt=dt,C0="sentryReplaySession",iH="replay_event",T0="Unable to send Replay",oH=3e5,aH=9e5,lH=5e3,uH=5500,cH=6e4,dH=5e3,fH=3,O_=15e4,mf=5e3,hH=3e3,pH=300,P0=2e7,mH=4999,gH=15e3,M_=36e5;var vH=Object.defineProperty,yH=(e,t,n)=>t in e?vH(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,D_=(e,t,n)=>yH(e,typeof t!="symbol"?t+"":t,n),Pn=(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",e))(Pn||{});function bH(e){return e.nodeType===e.ELEMENT_NODE}function Pc(e){const t=e==null?void 0:e.host;return(t==null?void 0:t.shadowRoot)===e}function Rc(e){return Object.prototype.toString.call(e)==="[object ShadowRoot]"}function wH(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 SH(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 Jh(e){try{const t=e.rules||e.cssRules;return t?wH(Array.from(t,RI).join("")):null}catch{return null}}function _H(e){let t="";for(let n=0;n<e.style.length;n++){const r=e.style,s=r[n],i=r.getPropertyPriority(s);t+=`${s}:${r.getPropertyValue(s)}${i?" !important":""};`}return`${e.selectorText} { ${t} }`}function RI(e){let t;if(xH(e))try{t=Jh(e.styleSheet)||SH(e)}catch{}else if(EH(e)){let n=e.cssText;const r=e.selectorText.includes(":"),s=typeof e.style.all=="string"&&e.style.all;if(s&&(n=_H(e)),r&&(n=kH(n)),r||s)return n}return t||e.cssText}function kH(e){const t=/(\[(?:[\w-]+)[^\\])(:(?:[\w-]+)\])/gm;return e.replace(t,"$1\\$2")}function xH(e){return"styleSheet"in e}function EH(e){return"selectorText"in e}class II{constructor(){D_(this,"idNodeMap",new Map),D_(this,"nodeMetaMap",new WeakMap)}getId(t){var r;return t?((r=this.getMeta(t))==null?void 0:r.id)??-1:-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 CH(){return new II}function pm({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 td({isMasked:e,element:t,value:n,maskInputFn:r}){let s=n||"";return e?(r&&(s=r(s,t)),"*".repeat(s.length)):s}function du(e){return e.toLowerCase()}function Sy(e){return e.toUpperCase()}const L_="__rrweb_original__";function TH(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=L_ in i?i[L_]: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 R0(e){const t=e.type;return e.hasAttribute("data-rr-is-password")?"password":t?du(t):null}function Zh(e,t,n){return t==="INPUT"&&(n==="radio"||n==="checkbox")?e.getAttribute("value")||"":e.value}function AI(e,t){let n;try{n=new URL(e,t??window.location.href)}catch{return null}const r=/\.([0-9a-z]+)(?:$)/i,s=n.pathname.match(r);return(s==null?void 0:s[1])??null}const $_={};function OI(e){const t=$_[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 $_[e]=r.bind(window)}function _y(...e){return OI("setTimeout")(...e)}function MI(...e){return OI("clearTimeout")(...e)}function DI(e){try{return e.contentDocument}catch{}}let PH=1;const RH=new RegExp("[^a-z0-9-_:]"),nd=-2;function I0(){return PH++}function IH(e){if(e instanceof HTMLFormElement)return"form";const t=du(e.tagName);return RH.test(t)?"div":t}function AH(e){let t="";return e.indexOf("//")>-1?t=e.split("/").slice(0,3).join("/"):t=e.split("/")[0],t=t.split("?")[0],t}let dl,F_;const OH=/url\((?:(')([^']*)'|(")(.*?)"|([^)]*))\)/gm,MH=/^(?:[a-z+]+:)?\/\//i,DH=/^www\..*/i,LH=/^(data:)([^,]*),(.*)/i;function ep(e,t){return(e||"").replace(OH,(n,r,s,i,o,a)=>{const l=s||o||a,u=r||i||"";if(!l)return n;if(MH.test(l)||DH.test(l))return`url(${u}${l}${u})`;if(LH.test(l))return`url(${u}${l}${u})`;if(l[0]==="/")return`url(${u}${AH(t)+l}${u})`;const c=t.split("/"),d=l.split("/");c.pop();for(const f of d)f!=="."&&(f===".."?c.pop():c.push(f));return`url(${u}${c.join("/")}${u})`})}const $H=/^[^ \t\n\r\u000c]+/,FH=/^[, \t\n\r\u000c]+/;function NH(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(FH),!(n>=t.length);){let i=r($H);if(i.slice(-1)===",")i=Pl(e,i.substring(0,i.length-1)),s.push(i);else{let o="";i=Pl(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 N_=new WeakMap;function Pl(e,t){return!t||t.trim()===""?t:mm(e,t)}function BH(e){return!!(e.tagName==="svg"||e.ownerSVGElement)}function mm(e,t){let n=N_.get(e);if(n||(n=e.createElement("a"),N_.set(e,n)),!t)t="";else if(t.startsWith("blob:")||t.startsWith("data:"))return t;return n.setAttribute("href",t),n.href}function LI(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")?Pl(e,r):n==="srcset"?NH(e,r):n==="style"?ep(r,mm(e)):t==="object"&&n==="data"?Pl(e,r):typeof i=="function"?i(n,r,s):r)}function $I(e,t,n){return(e==="video"||e==="audio")&&t==="autoplay"}function FI(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 VH(e,t){for(let n=e.classList.length;n--;){const r=e.classList[n];if(t.test(r))return!0}return!1}function pa(e,t,n=1/0,r=0){return!e||e.nodeType!==e.ELEMENT_NODE||r>n?-1:t(e)?r:pa(e.parentNode,t,n,r+1)}function Rl(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(VH(r,e))return!0}return!!(t&&r.matches(t))}catch{return!1}}}function fu(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=pa(o,Rl(r,s)),l<0)return!0;a=pa(o,Rl(t,n),l>=0?l:1/0)}else{if(a=pa(o,Rl(t,n)),a<0)return!1;l=pa(o,Rl(r,s),a>=0?a:1/0)}return a>=0?l>=0?a<=l:!0:l>=0?!1:!!i}catch{}return!!i}function UH(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=_y(()=>{s||(t(),s=!0)},n);e.addEventListener("load",()=>{MI(a),s=!0,t()});return}const o="about:blank";if(r.location.href!==o||e.src===o||e.src==="")return _y(t,0),e.addEventListener("load",t);e.addEventListener("load",t)}function zH(e,t,n){let r=!1,s;try{s=e.sheet}catch{return}if(s)return;const i=_y(()=>{r||(t(),r=!0)},n);e.addEventListener("load",()=>{MI(i),r=!0,t()})}function HH(e,t){const{doc:n,mirror:r,blockClass:s,blockSelector:i,unblockSelector:o,maskAllText:a,maskAttributeFn:l,maskTextClass:u,unmaskTextClass:c,maskTextSelector:d,unmaskTextSelector:f,inlineStylesheet:p,maskInputOptions:g={},maskTextFn:m,maskInputFn:y,dataURLOptions:w={},inlineImages:b,recordCanvas:k,keepIframeSrcFn:C,newlyAddedElement:_=!1}=t,T=jH(n,r);switch(e.nodeType){case e.DOCUMENT_NODE:return e.compatMode!=="CSS1Compat"?{type:Pn.Document,childNodes:[],compatMode:e.compatMode}:{type:Pn.Document,childNodes:[]};case e.DOCUMENT_TYPE_NODE:return{type:Pn.DocumentType,name:e.name,publicId:e.publicId,systemId:e.systemId,rootId:T};case e.ELEMENT_NODE:return WH(e,{doc:n,blockClass:s,blockSelector:i,unblockSelector:o,inlineStylesheet:p,maskAttributeFn:l,maskInputOptions:g,maskInputFn:y,dataURLOptions:w,inlineImages:b,recordCanvas:k,keepIframeSrcFn:C,newlyAddedElement:_,rootId:T,maskTextClass:u,unmaskTextClass:c,maskTextSelector:d,unmaskTextSelector:f});case e.TEXT_NODE:return qH(e,{doc:n,maskAllText:a,maskTextClass:u,unmaskTextClass:c,maskTextSelector:d,unmaskTextSelector:f,maskTextFn:m,maskInputOptions:g,maskInputFn:y,rootId:T});case e.CDATA_SECTION_NODE:return{type:Pn.CDATA,textContent:"",rootId:T};case e.COMMENT_NODE:return{type:Pn.Comment,textContent:e.textContent||"",rootId:T};default:return!1}}function jH(e,t){if(!t.hasNode(e))return;const n=t.getId(e);return n===1?void 0:n}function qH(e,t){var w;const{maskAllText:n,maskTextClass:r,unmaskTextClass:s,maskTextSelector:i,unmaskTextSelector:o,maskTextFn:a,maskInputOptions:l,maskInputFn:u,rootId:c}=t,d=e.parentNode&&e.parentNode.tagName;let f=e.textContent;const p=d==="STYLE"?!0:void 0,g=d==="SCRIPT"?!0:void 0,m=d==="TEXTAREA"?!0:void 0;if(p&&f){try{e.nextSibling||e.previousSibling||(w=e.parentNode.sheet)!=null&&w.cssRules&&(f=Jh(e.parentNode.sheet))}catch(b){console.warn(`Cannot get CSS styles from text's parentNode. Error: ${b}`,e)}f=ep(f,mm(t.doc))}g&&(f="SCRIPT_PLACEHOLDER");const y=fu(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,"*")),d==="OPTION"&&f){const b=pm({type:null,tagName:d,maskInputOptions:l});f=td({isMasked:fu(e,r,i,s,o,b),element:e,value:f,maskInputFn:u})}return{type:Pn.Text,textContent:f||"",isStyle:p,rootId:c}}function WH(e,t){const{doc:n,blockClass:r,blockSelector:s,unblockSelector:i,inlineStylesheet:o,maskInputOptions:a={},maskAttributeFn:l,maskInputFn:u,dataURLOptions:c={},inlineImages:d,recordCanvas:f,keepIframeSrcFn:p,newlyAddedElement:g=!1,rootId:m,maskTextClass:y,unmaskTextClass:w,maskTextSelector:b,unmaskTextSelector:k}=t,C=FI(e,r,s,i),_=IH(e);let T={};const P=e.attributes.length;for(let E=0;E<P;E++){const I=e.attributes[E];I.name&&!$I(_,I.name,I.value)&&(T[I.name]=LI(n,_,du(I.name),I.value,e,l))}if(_==="link"&&o){const E=Array.from(n.styleSheets).find(O=>O.href===e.href);let I=null;E&&(I=Jh(E)),I&&(T.rel=null,T.href=null,T.crossorigin=null,T._cssText=ep(I,E.href))}if(_==="style"&&e.sheet&&!(e.innerText||e.textContent||"").trim().length){const E=Jh(e.sheet);E&&(T._cssText=ep(E,mm(n)))}if(_==="input"||_==="textarea"||_==="select"||_==="option"){const E=e,I=R0(E),O=Zh(E,Sy(_),I),R=E.checked;if(I!=="submit"&&I!=="button"&&O){const M=fu(E,y,b,w,k,pm({type:I,tagName:Sy(_),maskInputOptions:a}));T.value=td({isMasked:M,element:E,value:O,maskInputFn:u})}R&&(T.checked=R)}if(_==="option"&&(e.selected&&!a.select?T.selected=!0:delete T.selected),_==="canvas"&&f){if(e.__context==="2d")TH(e)||(T.rr_dataURL=e.toDataURL(c.type,c.quality));else if(!("__context"in e)){const E=e.toDataURL(c.type,c.quality),I=n.createElement("canvas");I.width=e.width,I.height=e.height;const O=I.toDataURL(c.type,c.quality);E!==O&&(T.rr_dataURL=E)}}if(_==="img"&&d){dl||(dl=n.createElement("canvas"),F_=dl.getContext("2d"));const E=e,I=E.currentSrc||E.getAttribute("src")||"<unknown-src>",O=E.crossOrigin,R=()=>{E.removeEventListener("load",R);try{dl.width=E.naturalWidth,dl.height=E.naturalHeight,F_.drawImage(E,0,0),T.rr_dataURL=dl.toDataURL(c.type,c.quality)}catch(M){if(E.crossOrigin!=="anonymous"){E.crossOrigin="anonymous",E.complete&&E.naturalWidth!==0?R():E.addEventListener("load",R);return}else console.warn(`Cannot inline img src=${I}! Error: ${M}`)}E.crossOrigin==="anonymous"&&(O?T.crossOrigin=O:E.removeAttribute("crossorigin"))};E.complete&&E.naturalWidth!==0?R():E.addEventListener("load",R)}if((_==="audio"||_==="video")&&(T.rr_mediaState=e.paused?"paused":"played",T.rr_mediaCurrentTime=e.currentTime),g||(e.scrollLeft&&(T.rr_scrollLeft=e.scrollLeft),e.scrollTop&&(T.rr_scrollTop=e.scrollTop)),C){const{width:E,height:I}=e.getBoundingClientRect();T={class:T.class,rr_width:`${E}px`,rr_height:`${I}px`}}_==="iframe"&&!p(T.src)&&(!C&&!DI(e)&&(T.rr_src=T.src),delete T.src);let S;try{customElements.get(_)&&(S=!0)}catch{}return{type:Pn.Element,tagName:_,attributes:T,childNodes:[],isSVG:BH(e)||void 0,needBlock:C,rootId:m,isCustom:S}}function Ht(e){return e==null?"":e.toLowerCase()}function GH(e,t){if(t.comment&&e.type===Pn.Comment)return!0;if(e.type===Pn.Element){if(t.script&&(e.tagName==="script"||e.tagName==="link"&&(e.attributes.rel==="preload"||e.attributes.rel==="modulepreload")||e.tagName==="link"&&e.attributes.rel==="prefetch"&&typeof e.attributes.href=="string"&&AI(e.attributes.href)==="js"))return!0;if(t.headFavicon&&(e.tagName==="link"&&e.attributes.rel==="shortcut icon"||e.tagName==="meta"&&(Ht(e.attributes.name).match(/^msapplication-tile(image|color)$/)||Ht(e.attributes.name)==="application-name"||Ht(e.attributes.rel)==="icon"||Ht(e.attributes.rel)==="apple-touch-icon"||Ht(e.attributes.rel)==="shortcut icon")))return!0;if(e.tagName==="meta"){if(t.headMetaDescKeywords&&Ht(e.attributes.name).match(/^description|keywords$/))return!0;if(t.headMetaSocial&&(Ht(e.attributes.property).match(/^(og|twitter|fb):/)||Ht(e.attributes.name).match(/^(og|twitter):/)||Ht(e.attributes.name)==="pinterest"))return!0;if(t.headMetaRobots&&(Ht(e.attributes.name)==="robots"||Ht(e.attributes.name)==="googlebot"||Ht(e.attributes.name)==="bingbot"))return!0;if(t.headMetaHttpEquiv&&e.attributes["http-equiv"]!==void 0)return!0;if(t.headMetaAuthorship&&(Ht(e.attributes.name)==="author"||Ht(e.attributes.name)==="generator"||Ht(e.attributes.name)==="framework"||Ht(e.attributes.name)==="publisher"||Ht(e.attributes.name)==="progid"||Ht(e.attributes.property).match(/^article:/)||Ht(e.attributes.property).match(/^product:/)))return!0;if(t.headMetaVerification&&(Ht(e.attributes.name)==="google-site-verification"||Ht(e.attributes.name)==="yandex-verification"||Ht(e.attributes.name)==="csrf-token"||Ht(e.attributes.name)==="p:domain_verify"||Ht(e.attributes.name)==="verify-v1"||Ht(e.attributes.name)==="verification"||Ht(e.attributes.name)==="shopify-checkout-api-token"))return!0}}return!1}function Il(e,t){const{doc:n,mirror:r,blockClass:s,blockSelector:i,unblockSelector:o,maskAllText:a,maskTextClass:l,unmaskTextClass:u,maskTextSelector:c,unmaskTextSelector:d,skipChild:f=!1,inlineStylesheet:p=!0,maskInputOptions:g={},maskAttributeFn:m,maskTextFn:y,maskInputFn:w,slimDOMOptions:b,dataURLOptions:k={},inlineImages:C=!1,recordCanvas:_=!1,onSerialize:T,onIframeLoad:P,iframeLoadTimeout:S=5e3,onStylesheetLoad:E,stylesheetLoadTimeout:I=5e3,keepIframeSrcFn:O=()=>!1,newlyAddedElement:R=!1}=t;let{preserveWhiteSpace:M=!0}=t;const D=HH(e,{doc:n,mirror:r,blockClass:s,blockSelector:i,maskAllText:a,unblockSelector:o,maskTextClass:l,unmaskTextClass:u,maskTextSelector:c,unmaskTextSelector:d,inlineStylesheet:p,maskInputOptions:g,maskAttributeFn:m,maskTextFn:y,maskInputFn:w,dataURLOptions:k,inlineImages:C,recordCanvas:_,keepIframeSrcFn:O,newlyAddedElement:R});if(!D)return console.warn(e,"not serialized"),null;let F;r.hasNode(e)?F=r.getId(e):GH(D,b)||!M&&D.type===Pn.Text&&!D.isStyle&&!D.textContent.replace(/^\s+|\s+$/gm,"").length?F=nd:F=I0();const U=Object.assign(D,{id:F});if(r.add(e,U),F===nd)return null;T&&T(e);let K=!f;if(U.type===Pn.Element){K=K&&!U.needBlock,delete U.needBlock;const X=e.shadowRoot;X&&Rc(X)&&(U.isShadowHost=!0)}if((U.type===Pn.Document||U.type===Pn.Element)&&K){b.headWhitespace&&U.type===Pn.Element&&U.tagName==="head"&&(M=!1);const X={doc:n,mirror:r,blockClass:s,blockSelector:i,maskAllText:a,unblockSelector:o,maskTextClass:l,unmaskTextClass:u,maskTextSelector:c,unmaskTextSelector:d,skipChild:f,inlineStylesheet:p,maskInputOptions:g,maskAttributeFn:m,maskTextFn:y,maskInputFn:w,slimDOMOptions:b,dataURLOptions:k,inlineImages:C,recordCanvas:_,preserveWhiteSpace:M,onSerialize:T,onIframeLoad:P,iframeLoadTimeout:S,onStylesheetLoad:E,stylesheetLoadTimeout:I,keepIframeSrcFn:O};for(const H of Array.from(e.childNodes)){const B=Il(H,X);B&&U.childNodes.push(B)}if(bH(e)&&e.shadowRoot)for(const H of Array.from(e.shadowRoot.childNodes)){const B=Il(H,X);B&&(Rc(e.shadowRoot)&&(B.isShadow=!0),U.childNodes.push(B))}}return e.parentNode&&Pc(e.parentNode)&&Rc(e.parentNode)&&(U.isShadow=!0),U.type===Pn.Element&&U.tagName==="iframe"&&!FI(e,s,i,o)&&UH(e,()=>{const X=DI(e);if(X&&P){const H=Il(X,{doc:X,mirror:r,blockClass:s,blockSelector:i,unblockSelector:o,maskAllText:a,maskTextClass:l,unmaskTextClass:u,maskTextSelector:c,unmaskTextSelector:d,skipChild:!1,inlineStylesheet:p,maskInputOptions:g,maskAttributeFn:m,maskTextFn:y,maskInputFn:w,slimDOMOptions:b,dataURLOptions:k,inlineImages:C,recordCanvas:_,preserveWhiteSpace:M,onSerialize:T,onIframeLoad:P,iframeLoadTimeout:S,onStylesheetLoad:E,stylesheetLoadTimeout:I,keepIframeSrcFn:O});H&&P(e,H)}},S),U.type===Pn.Element&&U.tagName==="link"&&typeof U.attributes.rel=="string"&&(U.attributes.rel==="stylesheet"||U.attributes.rel==="preload"&&typeof U.attributes.href=="string"&&AI(U.attributes.href)==="css")&&zH(e,()=>{if(E){const X=Il(e,{doc:n,mirror:r,blockClass:s,blockSelector:i,unblockSelector:o,maskAllText:a,maskTextClass:l,unmaskTextClass:u,maskTextSelector:c,unmaskTextSelector:d,skipChild:!1,inlineStylesheet:p,maskInputOptions:g,maskAttributeFn:m,maskTextFn:y,maskInputFn:w,slimDOMOptions:b,dataURLOptions:k,inlineImages:C,recordCanvas:_,preserveWhiteSpace:M,onSerialize:T,onIframeLoad:P,iframeLoadTimeout:S,onStylesheetLoad:E,stylesheetLoadTimeout:I,keepIframeSrcFn:O});X&&E(e,X)}},I),U}function KH(e,t){const{mirror:n=new II,blockClass:r="rr-block",blockSelector:s=null,unblockSelector:i=null,maskAllText:o=!1,maskTextClass:a="rr-mask",unmaskTextClass:l=null,maskTextSelector:u=null,unmaskTextSelector:c=null,inlineStylesheet:d=!0,inlineImages:f=!1,recordCanvas:p=!1,maskAllInputs:g=!1,maskAttributeFn:m,maskTextFn:y,maskInputFn:w,slimDOM:b=!1,dataURLOptions:k,preserveWhiteSpace:C,onSerialize:_,onIframeLoad:T,iframeLoadTimeout:P,onStylesheetLoad:S,stylesheetLoadTimeout:E,keepIframeSrcFn:I=()=>!1}=t||{};return Il(e,{doc:e,mirror:n,blockClass:r,blockSelector:s,unblockSelector:i,maskAllText:o,maskTextClass:a,unmaskTextClass:l,maskTextSelector:u,unmaskTextSelector:c,skipChild:!1,inlineStylesheet:d,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:w,slimDOMOptions:b===!0||b==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaDescKeywords:b==="all",headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaAuthorship:!0,headMetaVerification:!0}:b===!1?{}:b,dataURLOptions:k,inlineImages:f,recordCanvas:p,preserveWhiteSpace:C,onSerialize:_,onIframeLoad:T,iframeLoadTimeout:P,onStylesheetLoad:S,stylesheetLoadTimeout:E,keepIframeSrcFn:I,newlyAddedElement:!1})}function dr(e,t,n=document){const r={capture:!0,passive:!0};return n.addEventListener(e,t,r),()=>n.removeEventListener(e,t,r)}const Sl=`Please stop import mirror directly. Instead of that,\r
|
|
50
|
+
now you can use replayer.getMirror() to access the mirror instance of a replayer,\r
|
|
51
|
+
or you can use record.mirror to access the mirror instance during recording.`;let B_={map:{},getId(){return console.error(Sl),-1},getNode(){return console.error(Sl),null},removeNodeFromMap(){console.error(Sl)},has(){return console.error(Sl),!1},reset(){console.error(Sl)}};typeof window<"u"&&window.Proxy&&window.Reflect&&(B_=new Proxy(B_,{get(e,t,n){return t==="map"&&console.error(Sl),Reflect.get(e,t,n)}}));function rd(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&&(t8(r),r=null),s=o,e.apply(l,i)):!r&&n.trailing!==!1&&(r=gm(()=>{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){gm(()=>{n.set.call(this,o)},0),i&&i.set&&i.set.call(this,o)}}),()=>NI(e,t,i||{},!0)}function A0(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 tp=Date.now;/[1-9][0-9]{12}/.test(Date.now().toString())||(tp=()=>new Date().getTime());function BI(e){var n,r,s,i,o,a;const t=e.document;return{left:t.scrollingElement?t.scrollingElement.scrollLeft:e.pageXOffset!==void 0?e.pageXOffset:(t==null?void 0:t.documentElement.scrollLeft)||((r=(n=t==null?void 0:t.body)==null?void 0:n.parentElement)==null?void 0:r.scrollLeft)||((s=t==null?void 0:t.body)==null?void 0:s.scrollLeft)||0,top:t.scrollingElement?t.scrollingElement.scrollTop:e.pageYOffset!==void 0?e.pageYOffset:(t==null?void 0:t.documentElement.scrollTop)||((o=(i=t==null?void 0:t.body)==null?void 0:i.parentElement)==null?void 0:o.scrollTop)||((a=t==null?void 0:t.body)==null?void 0:a.scrollTop)||0}}function VI(){return window.innerHeight||document.documentElement&&document.documentElement.clientHeight||document.body&&document.body.clientHeight}function UI(){return window.innerWidth||document.documentElement&&document.documentElement.clientWidth||document.body&&document.body.clientWidth}function zI(e){if(!e)return null;try{return e.nodeType===e.ELEMENT_NODE?e:e.parentElement}catch{return null}}function Nr(e,t,n,r,s){if(!e)return!1;const i=zI(e);if(!i)return!1;const o=Rl(t,n);if(!s){const u=r&&i.matches(r);return o(i)&&!u}const a=pa(i,o);let l=-1;return a<0?!1:(r&&(l=pa(i,Rl(null,r))),a>-1&&l<0?!0:a<l)}function YH(e,t){return t.getId(e)!==-1}function Dg(e,t){return t.getId(e)===nd}function HI(e,t){if(Pc(e))return!1;const n=t.getId(e);return t.has(n)?e.parentNode&&e.parentNode.nodeType===e.DOCUMENT_NODE?!1:e.parentNode?HI(e.parentNode,t):!0:!0}function ky(e){return!!e.changedTouches}function XH(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 jI(e,t){return!!(e.nodeName==="IFRAME"&&t.getMeta(e))}function qI(e,t){return!!(e.nodeName==="LINK"&&e.nodeType===e.ELEMENT_NODE&&e.getAttribute&&e.getAttribute("rel")==="stylesheet"&&t.getMeta(e))}function xy(e){return!!(e!=null&&e.shadowRoot)}class QH{constructor(){this.id=1,this.styleIDMap=new WeakMap,this.idStyleMap=new Map}getId(t){return 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 WI(e){var n,r;let t=null;return((r=(n=e.getRootNode)==null?void 0:n.call(e))==null?void 0:r.nodeType)===Node.DOCUMENT_FRAGMENT_NODE&&e.getRootNode().host&&(t=e.getRootNode().host),t}function JH(e){let t=e,n;for(;n=WI(t);)t=n;return t}function ZH(e){const t=e.ownerDocument;if(!t)return!1;const n=JH(e);return t.contains(n)}function GI(e){const t=e.ownerDocument;return t?t.contains(e)||ZH(e):!1}const V_={};function O0(e){const t=V_[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 V_[e]=r.bind(window)}function e8(...e){return O0("requestAnimationFrame")(...e)}function gm(...e){return O0("setTimeout")(...e)}function t8(...e){return O0("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||{}),Je=(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))(Je||{}),ir=(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))(ir||{}),_i=(e=>(e[e.Mouse=0]="Mouse",e[e.Pen=1]="Pen",e[e.Touch=2]="Touch",e))(_i||{}),_l=(e=>(e[e.Play=0]="Play",e[e.Pause=1]="Pause",e[e.Seeked=2]="Seeked",e[e.VolumeChange=3]="VolumeChange",e[e.RateChange=4]="RateChange",e))(_l||{});function M0(e){try{return e.contentDocument}catch{}}function n8(e){try{return e.contentWindow}catch{}}function U_(e){return"__ln"in e}class r8{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=(n==null?void 0:n.next)||null;return n}addNode(t){const n={value:t,previous:null,next:null};if(t.__ln=n,t.previousSibling&&U_(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&&U_(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 z_=(e,t)=>`${e}@${t}`;class s8{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 r8,s=l=>{let u=l,c=nd;for(;c===nd;)u=u&&u.nextSibling,c=u&&this.mirror.getId(u);return c},i=l=>{if(!l.parentNode||!GI(l))return;const u=Pc(l.parentNode)?this.mirror.getId(WI(l)):this.mirror.getId(l.parentNode),c=s(l);if(u===-1||c===-1)return r.addNode(l);const d=Il(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=>{jI(f,this.mirror)&&!Nr(f,this.blockClass,this.blockSelector,this.unblockSelector,!1)&&this.iframeManager.addIframe(f),qI(f,this.mirror)&&this.stylesheetManager.trackLinkElement(f),xy(l)&&this.shadowDomManager.addShadowRoot(l.shadowRoot,this.doc)},onIframeLoad:(f,p)=>{Nr(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)}});d&&(t.push({parentId:u,nextId:c,node:d}),n.add(d.id))};for(;this.mapRemoves.length;)this.mirror.removeNodeFromMap(this.mapRemoves.shift());for(const l of this.movedSet)H_(this.removes,l,this.mirror)&&!this.movedSet.has(l.parentNode)||i(l);for(const l of this.addedSet)!j_(this.droppedSet,l)&&!H_(this.removes,l,this.mirror)||j_(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),c=s(o.value);u!==-1&&c!==-1&&(l=o)}if(!l){let u=r.tail;for(;u;){const c=u;if(u=u.previous,c){const d=this.mirror.getId(c.value.parentNode);if(s(c.value)===-1)continue;if(d!==-1){l=c;break}else{const p=c.value;if(p.parentNode&&p.parentNode.nodeType===Node.DOCUMENT_FRAGMENT_NODE){const g=p.parentNode.host;if(this.mirror.getId(g)!==-1){l=c;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 c=JSON.stringify(l.styleDiff),d=JSON.stringify(l._unchangedStyles);c.length<u.style.length&&(c+d).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(!Dg(t.target,this.mirror))switch(t.type){case"characterData":{const n=t.target.textContent;!Nr(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)&&n!==t.oldValue&&this.texts.push({value:fu(t.target,this.maskTextClass,this.maskTextSelector,this.unmaskTextClass,this.unmaskTextSelector,this.maskAllText)&&n?this.maskTextFn?this.maskTextFn(n,zI(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=R0(n),a=n.tagName;s=Zh(n,a,o);const l=pm({maskInputOptions:this.maskInputOptions,tagName:a,type:o}),u=fu(t.target,this.maskTextClass,this.maskTextSelector,this.unmaskTextClass,this.unmaskTextSelector,l);s=td({isMasked:u,element:n,value:s,maskInputFn:this.maskInputFn})}if(Nr(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(!M0(n))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"),!$I(n.tagName,r)&&(i.attributes[r]=LI(this.doc,du(n.tagName),du(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(Nr(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=Pc(t.target)?this.mirror.getId(t.target.host):this.mirror.getId(t.target);Nr(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)||Dg(n,this.mirror)||!YH(n,this.mirror)||(this.addedSet.has(n)?(Ey(this.addedSet,n),this.droppedSet.add(n)):this.addedSet.has(t.target)&&r===-1||HI(t.target,this.mirror)||(this.movedSet.has(n)&&this.movedMap[z_(r,s)]?Ey(this.movedSet,n):this.removes.push({parentId:s,id:r,isShadow:Pc(t.target)&&Rc(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(Dg(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[z_(this.mirror.getId(t),r)]=!0)}else this.addedSet.add(t),this.droppedSet.delete(t);Nr(t,this.blockClass,this.blockSelector,this.unblockSelector,!1)||(t.childNodes.forEach(r=>this.genAdds(r)),xy(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 Ey(e,t){e.delete(t),t.childNodes.forEach(n=>Ey(e,n))}function H_(e,t,n){return e.length===0?!1:i8(e,t,n)}function i8(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 j_(e,t){return e.size===0?!1:KI(e,t)}function KI(e,t){const{parentNode:n}=t;return n?e.has(n)?!0:KI(e,n):!1}let Ic;function o8(e){Ic=e}function a8(){Ic=void 0}const gt=e=>Ic?(...n)=>{try{return e(...n)}catch(r){if(Ic&&Ic(r)===!0)return()=>{};throw r}}:e,Al=[];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 YI(e,t){var o,a;const n=new s8;Al.push(n),n.init(e);let r=window.MutationObserver||window.__rrMutationObserver;const s=(a=(o=window==null?void 0:window.Zone)==null?void 0:o.__symbol__)==null?void 0:a.call(o,"MutationObserver");s&&window[s]&&(r=window[s]);const i=new r(gt(l=>{e.onMutation&&e.onMutation(l)===!1||n.processMutations.bind(n)(l)}));return i.observe(t,{attributes:!0,attributeOldValue:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0}),i}function l8({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=rd(gt(d=>{const f=Date.now()-a;e(o.map(p=>(p.timeOffset-=f,p)),d),o=[],a=null}),i),u=gt(rd(gt(d=>{const f=zd(d),{clientX:p,clientY:g}=ky(d)?d.changedTouches[0]:d;a||(a=tp()),o.push({x:p,y:g,id:r.getId(f),timeOffset:tp()-a}),l(typeof DragEvent<"u"&&d instanceof DragEvent?Je.Drag:d instanceof MouseEvent?Je.MouseMove:Je.TouchMove)}),s,{trailing:!1})),c=[dr("mousemove",u,n),dr("touchmove",u,n),dr("drag",u,n)];return gt(()=>{c.forEach(d=>d())})}function u8({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 c=d=>f=>{const p=zd(f);if(Nr(p,r,s,i,!0))return;let g=null,m=d;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?ir[d]===ir.MouseDown?m="TouchStart":ir[d]===ir.MouseUp&&(m="TouchEnd"):_i.Pen}else ky(f)&&(g=_i.Touch);g!==null?(u=g,(m.startsWith("Touch")&&g===_i.Touch||m.startsWith("Mouse")&&g===_i.Mouse)&&(g=null)):ir[d]===ir.Click&&(g=u,u=null);const y=ky(f)?f.changedTouches[0]:f;if(!y)return;const w=n.getId(p),{clientX:b,clientY:k}=y;gt(e)({type:ir[m],id:w,x:b,y:k,...g!==null&&{pointerType:g}})};return Object.keys(ir).filter(d=>Number.isNaN(Number(d))&&!d.endsWith("_Departed")&&a[d]!==!1).forEach(d=>{let f=du(d);const p=c(d);if(window.PointerEvent)switch(ir[d]){case ir.MouseDown:case ir.MouseUp:f=f.replace("mouse","pointer");break;case ir.TouchStart:case ir.TouchEnd:return}l.push(dr(f,p,t))}),gt(()=>{l.forEach(d=>d())})}function XI({scrollCb:e,doc:t,mirror:n,blockClass:r,blockSelector:s,unblockSelector:i,sampling:o}){const a=gt(rd(gt(l=>{const u=zd(l);if(!u||Nr(u,r,s,i,!0))return;const c=n.getId(u);if(u===t&&t.defaultView){const d=BI(t.defaultView);e({id:c,x:d.left,y:d.top})}else e({id:c,x:u.scrollLeft,y:u.scrollTop})}),o.scroll||100));return dr("scroll",a,t)}function c8({viewportResizeCb:e},{win:t}){let n=-1,r=-1;const s=gt(rd(gt(()=>{const i=VI(),o=UI();(n!==i||r!==o)&&(e({width:Number(o),height:Number(i)}),n=i,r=o)}),200));return dr("resize",s,t)}const d8=["INPUT","TEXTAREA","SELECT"],q_=new WeakMap;function f8({inputCb:e,doc:t,mirror:n,blockClass:r,blockSelector:s,unblockSelector:i,ignoreClass:o,ignoreSelector:a,maskInputOptions:l,maskInputFn:u,sampling:c,userTriggeredOnInput:d,maskTextClass:f,unmaskTextClass:p,maskTextSelector:g,unmaskTextSelector:m}){function y(P){let S=zd(P);const E=P.isTrusted,I=S&&Sy(S.tagName);if(I==="OPTION"&&(S=S.parentElement),!S||!I||d8.indexOf(I)<0||Nr(S,r,s,i,!0))return;const O=S;if(O.classList.contains(o)||a&&O.matches(a))return;const R=R0(S);let M=Zh(O,I,R),D=!1;const F=pm({maskInputOptions:l,tagName:I,type:R}),U=fu(S,f,g,p,m,F);(R==="radio"||R==="checkbox")&&(D=S.checked),M=td({isMasked:U,element:S,value:M,maskInputFn:u}),w(S,d?{text:M,isChecked:D,userTriggered:E}:{text:M,isChecked:D});const K=S.name;R==="radio"&&K&&D&&t.querySelectorAll(`input[type="radio"][name="${K}"]`).forEach(X=>{if(X!==S){const H=td({isMasked:U,element:X,value:Zh(X,I,R),maskInputFn:u});w(X,d?{text:H,isChecked:!D,userTriggered:!1}:{text:H,isChecked:!D})}})}function w(P,S){const E=q_.get(P);if(!E||E.text!==S.text||E.isChecked!==S.isChecked){q_.set(P,S);const I=n.getId(P);gt(e)({...S,id:I})}}const k=(c.input==="last"?["change"]:["input","change"]).map(P=>dr(P,gt(y),t)),C=t.defaultView;if(!C)return()=>{k.forEach(P=>P())};const _=C.Object.getOwnPropertyDescriptor(C.HTMLInputElement.prototype,"value"),T=[[C.HTMLInputElement.prototype,"value"],[C.HTMLInputElement.prototype,"checked"],[C.HTMLSelectElement.prototype,"value"],[C.HTMLTextAreaElement.prototype,"value"],[C.HTMLSelectElement.prototype,"selectedIndex"],[C.HTMLOptionElement.prototype,"selected"]];return _&&_.set&&k.push(...T.map(P=>NI(P[0],P[1],{set(){gt(y)({target:this,isTrusted:!1})}},!1,C))),gt(()=>{k.forEach(P=>P())})}function np(e){const t=[];function n(r,s){if(gf("CSSGroupingRule")&&r.parentRule instanceof CSSGroupingRule||gf("CSSMediaRule")&&r.parentRule instanceof CSSMediaRule||gf("CSSSupportsRule")&&r.parentRule instanceof CSSSupportsRule||gf("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 ao(e,t,n){let r,s;return e?(e.ownerNode?r=t.getId(e.ownerNode):s=n.getId(e),{styleId:s,id:r}):{}}function h8({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:gt((c,d,f)=>{const[p,g]=f,{id:m,styleId:y}=ao(d,t,n.styleMirror);return(m&&m!==-1||y&&y!==-1)&&e({id:m,styleId:y,adds:[{rule:p,index:g}]}),c.apply(d,f)})});const i=r.CSSStyleSheet.prototype.deleteRule;r.CSSStyleSheet.prototype.deleteRule=new Proxy(i,{apply:gt((c,d,f)=>{const[p]=f,{id:g,styleId:m}=ao(d,t,n.styleMirror);return(g&&g!==-1||m&&m!==-1)&&e({id:g,styleId:m,removes:[{index:p}]}),c.apply(d,f)})});let o;r.CSSStyleSheet.prototype.replace&&(o=r.CSSStyleSheet.prototype.replace,r.CSSStyleSheet.prototype.replace=new Proxy(o,{apply:gt((c,d,f)=>{const[p]=f,{id:g,styleId:m}=ao(d,t,n.styleMirror);return(g&&g!==-1||m&&m!==-1)&&e({id:g,styleId:m,replace:p}),c.apply(d,f)})}));let a;r.CSSStyleSheet.prototype.replaceSync&&(a=r.CSSStyleSheet.prototype.replaceSync,r.CSSStyleSheet.prototype.replaceSync=new Proxy(a,{apply:gt((c,d,f)=>{const[p]=f,{id:g,styleId:m}=ao(d,t,n.styleMirror);return(g&&g!==-1||m&&m!==-1)&&e({id:g,styleId:m,replaceSync:p}),c.apply(d,f)})}));const l={};vf("CSSGroupingRule")?l.CSSGroupingRule=r.CSSGroupingRule:(vf("CSSMediaRule")&&(l.CSSMediaRule=r.CSSMediaRule),vf("CSSConditionRule")&&(l.CSSConditionRule=r.CSSConditionRule),vf("CSSSupportsRule")&&(l.CSSSupportsRule=r.CSSSupportsRule));const u={};return Object.entries(l).forEach(([c,d])=>{u[c]={insertRule:d.prototype.insertRule,deleteRule:d.prototype.deleteRule},d.prototype.insertRule=new Proxy(u[c].insertRule,{apply:gt((f,p,g)=>{const[m,y]=g,{id:w,styleId:b}=ao(p.parentStyleSheet,t,n.styleMirror);return(w&&w!==-1||b&&b!==-1)&&e({id:w,styleId:b,adds:[{rule:m,index:[...np(p),y||0]}]}),f.apply(p,g)})}),d.prototype.deleteRule=new Proxy(u[c].deleteRule,{apply:gt((f,p,g)=>{const[m]=g,{id:y,styleId:w}=ao(p.parentStyleSheet,t,n.styleMirror);return(y&&y!==-1||w&&w!==-1)&&e({id:y,styleId:w,removes:[{index:[...np(p),m]}]}),f.apply(p,g)})})}),gt(()=>{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(([c,d])=>{d.prototype.insertRule=u[c].insertRule,d.prototype.deleteRule=u[c].deleteRule})})}function QI({mirror:e,stylesheetManager:t},n){var o,a,l;let r=null;n.nodeName==="#document"?r=e.getId(n):r=e.getId(n.host);const s=n.nodeName==="#document"?(o=n.defaultView)==null?void 0:o.Document:(l=(a=n.ownerDocument)==null?void 0:a.defaultView)==null?void 0:l.ShadowRoot,i=s!=null&&s.prototype?Object.getOwnPropertyDescriptor(s==null?void 0:s.prototype,"adoptedStyleSheets"):void 0;return r===null||r===-1||!s||!i?()=>{}:(Object.defineProperty(n,"adoptedStyleSheets",{configurable:i.configurable,enumerable:i.enumerable,get(){var u;return(u=i.get)==null?void 0:u.call(this)},set(u){var d;const c=(d=i.set)==null?void 0:d.call(this,u);if(r!==null&&r!==-1)try{t.adoptStyleSheets(u,r)}catch{}return c}}),gt(()=>{Object.defineProperty(n,"adoptedStyleSheets",{configurable:i.configurable,enumerable:i.enumerable,get:i.get,set:i.set})}))}function p8({styleDeclarationCb:e,mirror:t,ignoreCSSAttributes:n,stylesheetManager:r},{win:s}){const i=s.CSSStyleDeclaration.prototype.setProperty;s.CSSStyleDeclaration.prototype.setProperty=new Proxy(i,{apply:gt((a,l,u)=>{var m;const[c,d,f]=u;if(n.has(c))return i.apply(l,[c,d,f]);const{id:p,styleId:g}=ao((m=l.parentRule)==null?void 0:m.parentStyleSheet,t,r.styleMirror);return(p&&p!==-1||g&&g!==-1)&&e({id:p,styleId:g,set:{property:c,value:d,priority:f},index:np(l.parentRule)}),a.apply(l,u)})});const o=s.CSSStyleDeclaration.prototype.removeProperty;return s.CSSStyleDeclaration.prototype.removeProperty=new Proxy(o,{apply:gt((a,l,u)=>{var p;const[c]=u;if(n.has(c))return o.apply(l,[c]);const{id:d,styleId:f}=ao((p=l.parentRule)==null?void 0:p.parentStyleSheet,t,r.styleMirror);return(d&&d!==-1||f&&f!==-1)&&e({id:d,styleId:f,remove:{property:c},index:np(l.parentRule)}),a.apply(l,u)})}),gt(()=>{s.CSSStyleDeclaration.prototype.setProperty=i,s.CSSStyleDeclaration.prototype.removeProperty=o})}function m8({mediaInteractionCb:e,blockClass:t,blockSelector:n,unblockSelector:r,mirror:s,sampling:i,doc:o}){const a=gt(u=>rd(gt(c=>{const d=zd(c);if(!d||Nr(d,t,n,r,!0))return;const{currentTime:f,volume:p,muted:g,playbackRate:m}=d;e({type:u,id:s.getId(d),currentTime:f,volume:p,muted:g,playbackRate:m})}),i.media||500)),l=[dr("play",a(_l.Play),o),dr("pause",a(_l.Pause),o),dr("seeked",a(_l.Seeked),o),dr("volumechange",a(_l.VolumeChange),o),dr("ratechange",a(_l.RateChange),o)];return gt(()=>{l.forEach(u=>u())})}function g8({fontCb:e,doc:t}){const n=t.defaultView;if(!n)return()=>{};const r=[],s=new WeakMap,i=n.FontFace;n.FontFace=function(l,u,c){const d=new i(l,u,c);return s.set(d,{family:l,buffer:typeof u!="string",descriptors:c,fontSource:typeof u=="string"?u:JSON.stringify(Array.from(new Uint8Array(u)))}),d};const o=A0(t.fonts,"add",function(a){return function(l){return gm(gt(()=>{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),gt(()=>{r.forEach(a=>a())})}function v8(e){const{doc:t,mirror:n,blockClass:r,blockSelector:s,unblockSelector:i,selectionCb:o}=e;let a=!0;const l=gt(()=>{const u=t.getSelection();if(!u||a&&(u!=null&&u.isCollapsed))return;a=u.isCollapsed||!1;const c=[],d=u.rangeCount||0;for(let f=0;f<d;f++){const p=u.getRangeAt(f),{startContainer:g,startOffset:m,endContainer:y,endOffset:w}=p;Nr(g,r,s,i,!0)||Nr(y,r,s,i,!0)||c.push({start:n.getId(g),startOffset:m,end:n.getId(y),endOffset:w})}o({ranges:c})});return l(),dr("selectionchange",l)}function y8({doc:e,customElementCb:t}){const n=e.defaultView;return!n||!n.customElements?()=>{}:A0(n.customElements,"define",function(s){return function(i,o,a){try{t({define:{name:i}})}catch{}return s.apply(this,[i,o,a])}})}function b8(e,t={}){const n=e.doc.defaultView;if(!n)return()=>{};let r;e.recordDOM&&(r=YI(e,e.doc));const s=l8(e),i=u8(e),o=XI(e),a=c8(e,{win:n}),l=f8(e),u=m8(e);let c=()=>{},d=()=>{},f=()=>{},p=()=>{};e.recordDOM&&(c=h8(e,{win:n}),d=QI(e,e.doc),f=p8(e,{win:n}),e.collectFonts&&(p=g8(e)));const g=v8(e),m=y8(e),y=[];for(const w of e.plugins)y.push(w.observer(w.callback,n,w.options));return gt(()=>{Al.forEach(w=>w.reset()),r==null||r.disconnect(),s(),i(),o(),a(),l(),u(),c(),d(),f(),p(),g(),m(),y.forEach(w=>w())})}function gf(e){return typeof window[e]<"u"}function vf(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}}class w8{constructor(){this.crossOriginIframeMirror=new Cy(I0),this.crossOriginIframeRootIdMap=new WeakMap}addIframe(){}addLoadListener(){}attachIframe(){}}class S8{constructor(t){this.iframes=new WeakMap,this.crossOriginIframeMap=new WeakMap,this.crossOriginIframeMirror=new Cy(I0),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){var s,i;this.mutationCb({adds:[{parentId:this.mirror.getId(t),nextId:null,node:n}],removes:[],texts:[],attributes:[],isAttachIframe:!0}),this.recordCrossOriginIframes&&((s=t.contentWindow)==null||s.addEventListener("message",this.handleMessage.bind(this))),(i=this.loadListener)==null||i.call(this,t);const r=M0(t);r&&r.adoptedStyleSheets&&r.adoptedStyleSheets.length>0&&this.stylesheetManager.adoptStyleSheets(r.adoptedStyleSheets,this.mirror.getId(r))}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){var r;switch(n.type){case ot.FullSnapshot:{this.crossOriginIframeMirror.reset(t),this.crossOriginIframeStyleMirror.reset(t),this.replaceIdOnNode(n.data.node,t);const s=n.data.node.id;return this.crossOriginIframeRootIdMap.set(t,s),this.patchRootIdOnNode(n.data.node,s),{timestamp:n.timestamp,type:ot.IncrementalSnapshot,data:{source:Je.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 Je.Mutation:return n.data.adds.forEach(s=>{this.replaceIds(s,t,["parentId","nextId","previousId"]),this.replaceIdOnNode(s.node,t);const i=this.crossOriginIframeRootIdMap.get(t);i&&this.patchRootIdOnNode(s.node,i)}),n.data.removes.forEach(s=>{this.replaceIds(s,t,["parentId","id"])}),n.data.attributes.forEach(s=>{this.replaceIds(s,t,["id"])}),n.data.texts.forEach(s=>{this.replaceIds(s,t,["id"])}),n;case Je.Drag:case Je.TouchMove:case Je.MouseMove:return n.data.positions.forEach(s=>{this.replaceIds(s,t,["id"])}),n;case Je.ViewportResize:return!1;case Je.MediaInteraction:case Je.MouseInteraction:case Je.Scroll:case Je.CanvasMutation:case Je.Input:return this.replaceIds(n.data,t,["id"]),n;case Je.StyleSheetRule:case Je.StyleDeclaration:return this.replaceIds(n.data,t,["id"]),this.replaceStyleIds(n.data,t,["styleId"]),n;case Je.Font:return n;case Je.Selection:return n.data.ranges.forEach(s=>{this.replaceIds(s,t,["start","end"])}),n;case Je.AdoptedStyleSheet:return this.replaceIds(n.data,t,["id"]),this.replaceStyleIds(n.data,t,["styleIds"]),(r=n.data.styles)==null||r.forEach(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!==Pn.Document&&!t.rootId&&(t.rootId=n),"childNodes"in t&&t.childNodes.forEach(r=>{this.patchRootIdOnNode(r,n)})}}class _8{init(){}addShadowRoot(){}observeAttachShadow(){}reset(){}}class k8{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(!Rc(t)||this.shadowDoms.has(t))return;this.shadowDoms.add(t),this.bypassOptions.canvasManager.addShadowRoot(t);const r=YI({...this.bypassOptions,doc:n,mutationCb:this.mutationCb,mirror:this.mirror,shadowDomManager:this},t);this.restoreHandlers.push(()=>r.disconnect()),this.restoreHandlers.push(XI({...this.bypassOptions,scrollCb:this.scrollCb,doc:t,mirror:this.mirror})),gm(()=>{t.adoptedStyleSheets&&t.adoptedStyleSheets.length>0&&this.bypassOptions.stylesheetManager.adoptStyleSheets(t.adoptedStyleSheets,this.mirror.getId(t.host)),this.restoreHandlers.push(QI({mirror:this.mirror,stylesheetManager:this.bypassOptions.stylesheetManager},t))},0)}observeAttachShadow(t){const n=M0(t),r=n8(t);!n||!r||this.patchAttachShadow(r.Element,n)}patchAttachShadow(t,n){const r=this;this.restoreHandlers.push(A0(t.prototype,"attachShadow",function(s){return function(i){const o=s.call(this,i);return this.shadowRoot&&GI(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()}}var W_="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",x8=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(var yf=0;yf<W_.length;yf++)x8[W_.charCodeAt(yf)]=yf;class G_{reset(){}freeze(){}unfreeze(){}lock(){}unlock(){}snapshot(){}addWindow(){}addShadowRoot(){}resetShadowRoots(){}}class E8{constructor(t){this.trackedLinkElements=new WeakSet,this.styleMirror=new QH,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:RI(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 C8{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,e8(()=>{this.nodeMap=new WeakMap,this.active=!1})),this.nodeMap.set(t,(this.nodeMap.get(t)||new Set).add(n))}destroy(){}}let ln,rp;var zE;try{if(Array.from([1],e=>e*2)[0]!==2){const e=document.createElement("iframe");document.body.appendChild(e),Array.from=((zE=e.contentWindow)==null?void 0:zE.Array.from)||Array.from,document.body.removeChild(e)}}catch(e){console.debug("Unable to override Array.from",e)}const Ss=CH();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:c="rr-mask",unmaskTextClass:d=null,maskTextSelector:f=null,unmaskTextSelector:p=null,inlineStylesheet:g=!0,maskAllInputs:m,maskInputOptions:y,slimDOMOptions:w,maskAttributeFn:b,maskInputFn:k,maskTextFn:C,maxCanvasSize:_=null,packFn:T,sampling:P={},dataURLOptions:S={},mousemoveWait:E,recordDOM:I=!0,recordCanvas:O=!1,recordCrossOriginIframes:R=!1,recordAfter:M=e.recordAfter==="DOMContentLoaded"?e.recordAfter:"load",userTriggeredOnInput:D=!1,collectFonts:F=!1,inlineImages:U=!1,plugins:K,keepIframeSrcFn:X=()=>!1,ignoreCSSAttributes:H=new Set([]),errorHandler:B,onMutation:ee,getCanvasManager:q}=e;o8(B);const G=R?window.parent===window:!0;let le=!1;if(!G)try{window.parent.document&&(le=!1)}catch{le=!0}if(G&&!t)throw new Error("emit function is required");if(!G&&!le)return()=>{};E!==void 0&&P.mousemove===void 0&&(P.mousemove=E),Ss.reset();const ie=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:{},Se=w===!0||w==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaVerification:!0,headMetaAuthorship:w==="all",headMetaDescKeywords:w==="all"}:w||{};XH();let Z,he=0;const ne=ye=>{for(const _e of K||[])_e.eventProcessor&&(ye=_e.eventProcessor(ye));return T&&!le&&(ye=T(ye)),ye};ln=(ye,_e)=>{var $e;const me=ye;if(me.timestamp=tp(),($e=Al[0])!=null&&$e.isFrozen()&&me.type!==ot.FullSnapshot&&!(me.type===ot.IncrementalSnapshot&&me.data.source===Je.Mutation)&&Al.forEach(Te=>Te.unfreeze()),G)t==null||t(ne(me),_e);else if(le){const Te={type:"rrweb",event:ne(me),origin:window.location.origin,isCheckout:_e};window.parent.postMessage(Te,"*")}if(me.type===ot.FullSnapshot)Z=me,he=0;else if(me.type===ot.IncrementalSnapshot){if(me.data.source===Je.Mutation&&me.data.isAttachIframe)return;he++;const Te=r&&he>=r,Ce=n&&Z&&me.timestamp-Z.timestamp>n;(Te||Ce)&&Re(!0)}};const z=ye=>{ln({type:ot.IncrementalSnapshot,data:{source:Je.Mutation,...ye}})},xe=ye=>ln({type:ot.IncrementalSnapshot,data:{source:Je.Scroll,...ye}}),Fe=ye=>ln({type:ot.IncrementalSnapshot,data:{source:Je.CanvasMutation,...ye}}),N=ye=>ln({type:ot.IncrementalSnapshot,data:{source:Je.AdoptedStyleSheet,...ye}}),V=new E8({mutationCb:z,adoptedStyleSheetCb:N}),Y=typeof __RRWEB_EXCLUDE_IFRAME__=="boolean"&&__RRWEB_EXCLUDE_IFRAME__?new w8:new S8({mirror:Ss,mutationCb:z,stylesheetManager:V,recordCrossOriginIframes:R,wrappedEmit:ln});for(const ye of K||[])ye.getMirror&&ye.getMirror({nodeMirror:Ss,crossOriginIframeMirror:Y.crossOriginIframeMirror,crossOriginIframeStyleMirror:Y.crossOriginIframeStyleMirror});const fe=new C8,ce=P8(q,{mirror:Ss,win:window,mutationCb:ye=>ln({type:ot.IncrementalSnapshot,data:{source:Je.CanvasMutation,...ye}}),recordCanvas:O,blockClass:s,blockSelector:i,unblockSelector:o,maxCanvasSize:_,sampling:P.canvas,dataURLOptions:S,errorHandler:B}),be=typeof __RRWEB_EXCLUDE_SHADOW_DOM__=="boolean"&&__RRWEB_EXCLUDE_SHADOW_DOM__?new _8:new k8({mutationCb:z,scrollCb:xe,bypassOptions:{onMutation:ee,blockClass:s,blockSelector:i,unblockSelector:o,maskAllText:u,maskTextClass:c,unmaskTextClass:d,maskTextSelector:f,unmaskTextSelector:p,inlineStylesheet:g,maskInputOptions:ie,dataURLOptions:S,maskAttributeFn:b,maskTextFn:C,maskInputFn:k,recordCanvas:O,inlineImages:U,sampling:P,slimDOMOptions:Se,iframeManager:Y,stylesheetManager:V,canvasManager:ce,keepIframeSrcFn:X,processedNodeManager:fe},mirror:Ss}),Re=(ye=!1)=>{if(!I)return;ln({type:ot.Meta,data:{href:window.location.href,width:UI(),height:VI()}},ye),V.reset(),be.init(),Al.forEach(me=>me.lock());const _e=KH(document,{mirror:Ss,blockClass:s,blockSelector:i,unblockSelector:o,maskAllText:u,maskTextClass:c,unmaskTextClass:d,maskTextSelector:f,unmaskTextSelector:p,inlineStylesheet:g,maskAllInputs:ie,maskAttributeFn:b,maskInputFn:k,maskTextFn:C,slimDOM:Se,dataURLOptions:S,recordCanvas:O,inlineImages:U,onSerialize:me=>{jI(me,Ss)&&Y.addIframe(me),qI(me,Ss)&&V.trackLinkElement(me),xy(me)&&be.addShadowRoot(me.shadowRoot,document)},onIframeLoad:(me,$e)=>{Y.attachIframe(me,$e),me.contentWindow&&ce.addWindow(me.contentWindow),be.observeAttachShadow(me)},onStylesheetLoad:(me,$e)=>{V.attachLinkElement(me,$e)},keepIframeSrcFn:X});if(!_e)return console.warn("Failed to snapshot the document");ln({type:ot.FullSnapshot,data:{node:_e,initialOffset:BI(window)}}),Al.forEach(me=>me.unlock()),document.adoptedStyleSheets&&document.adoptedStyleSheets.length>0&&V.adoptStyleSheets(document.adoptedStyleSheets,Ss.getId(document))};rp=Re;try{const ye=[],_e=$e=>{var Te;return gt(b8)({onMutation:ee,mutationCb:z,mousemoveCb:(Ce,Ge)=>ln({type:ot.IncrementalSnapshot,data:{source:Ge,positions:Ce}}),mouseInteractionCb:Ce=>ln({type:ot.IncrementalSnapshot,data:{source:Je.MouseInteraction,...Ce}}),scrollCb:xe,viewportResizeCb:Ce=>ln({type:ot.IncrementalSnapshot,data:{source:Je.ViewportResize,...Ce}}),inputCb:Ce=>ln({type:ot.IncrementalSnapshot,data:{source:Je.Input,...Ce}}),mediaInteractionCb:Ce=>ln({type:ot.IncrementalSnapshot,data:{source:Je.MediaInteraction,...Ce}}),styleSheetRuleCb:Ce=>ln({type:ot.IncrementalSnapshot,data:{source:Je.StyleSheetRule,...Ce}}),styleDeclarationCb:Ce=>ln({type:ot.IncrementalSnapshot,data:{source:Je.StyleDeclaration,...Ce}}),canvasMutationCb:Fe,fontCb:Ce=>ln({type:ot.IncrementalSnapshot,data:{source:Je.Font,...Ce}}),selectionCb:Ce=>{ln({type:ot.IncrementalSnapshot,data:{source:Je.Selection,...Ce}})},customElementCb:Ce=>{ln({type:ot.IncrementalSnapshot,data:{source:Je.CustomElement,...Ce}})},blockClass:s,ignoreClass:a,ignoreSelector:l,maskAllText:u,maskTextClass:c,unmaskTextClass:d,maskTextSelector:f,unmaskTextSelector:p,maskInputOptions:ie,inlineStylesheet:g,sampling:P,recordDOM:I,recordCanvas:O,inlineImages:U,userTriggeredOnInput:D,collectFonts:F,doc:$e,maskAttributeFn:b,maskInputFn:k,maskTextFn:C,keepIframeSrcFn:X,blockSelector:i,unblockSelector:o,slimDOMOptions:Se,dataURLOptions:S,mirror:Ss,iframeManager:Y,stylesheetManager:V,shadowDomManager:be,processedNodeManager:fe,canvasManager:ce,ignoreCSSAttributes:H,plugins:((Te=K==null?void 0:K.filter(Ce=>Ce.observer))==null?void 0:Te.map(Ce=>({observer:Ce.observer,options:Ce.options,callback:Ge=>ln({type:ot.Plugin,data:{plugin:Ce.name,payload:Ge}})})))||[]},{})};Y.addLoadListener($e=>{try{ye.push(_e($e.contentDocument))}catch(Te){console.warn(Te)}});const me=()=>{Re(),ye.push(_e(document))};return document.readyState==="interactive"||document.readyState==="complete"?me():(ye.push(dr("DOMContentLoaded",()=>{ln({type:ot.DomContentLoaded,data:{}}),M==="DOMContentLoaded"&&me()})),ye.push(dr("load",()=>{ln({type:ot.Load,data:{}}),M==="load"&&me()},window))),()=>{ye.forEach($e=>$e()),fe.destroy(),rp=void 0,a8()}}catch(ye){console.warn(ye)}}function T8(e){if(!rp)throw new Error("please take full snapshot after start recording");rp(e)}Li.mirror=Ss;Li.takeFullSnapshot=T8;function P8(e,t){try{return e?e(t):new G_}catch{return console.warn("Unable to initialize CanvasManager"),new G_}}var K_;(function(e){e[e.NotStarted=0]="NotStarted",e[e.Running=1]="Running",e[e.Stopped=2]="Stopped"})(K_||(K_={}));const R8=3,I8=5;function D0(e){return e>9999999999?e:e*1e3}function Lg(e){return e>9999999999?e/1e3:e}function Hd(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:xs(t,10,1e3)}}),t.category==="console")))}const A8="button,a";function JI(e){return e.closest(A8)||e}function ZI(e){const t=eA(e);return!t||!(t instanceof Element)?t:JI(t)}function eA(e){return O8(e)?e.target:e}function O8(e){return typeof e=="object"&&!!e&&"target"in e}let lo;function M8(e){return lo||(lo=[],D8()),lo.push(e),()=>{const t=lo?lo.indexOf(e):-1;t>-1&&lo.splice(t,1)}}function D8(){Er(qt,"open",function(e){return function(...t){if(lo)try{lo.forEach(n=>n())}catch{}return e.apply(qt,t)}})}const L8=new Set([Je.Mutation,Je.StyleSheetRule,Je.StyleDeclaration,Je.AdoptedStyleSheet,Je.CanvasMutation,Je.Selection,Je.MediaInteraction]);function $8(e,t,n){e.handleClick(t,n)}class F8{constructor(t,n,r=Hd){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=M8(()=>{this._lastMutation=Y_()});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(B8(n,this._ignoreSelector)||!V8(t))return;const r={timestamp:Lg(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=Lg(t)}registerScroll(t=Date.now()){this._lastScroll=Lg(t)}registerClick(t){const n=JI(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=Y_();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",c={type:"default",message:a.message,timestamp:a.timestamp,category:"ui.slowClickDetected",data:{...a.data,url:qt.location.href,route:n.getCurrentRoute(),timeAfterClickMs:l,endReason:u,clickCount:o||1}};this._addBreadcrumbEvent(n,c);return}if(o>1){const l={type:"default",message:a.message,timestamp:a.timestamp,category:"ui.multiClick",data:{...a.data,url:qt.location.href,route:n.getCurrentRoute(),clickCount:o,metric:!0}};this._addBreadcrumbEvent(n,l)}}_scheduleCheckClicks(){this._checkClickTimeout&&clearTimeout(this._checkClickTimeout),this._checkClickTimeout=cu(()=>this._checkClicks(),1e3)}}const N8=["A","BUTTON","INPUT"];function B8(e,t){return!!(!N8.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 V8(e){return!!(e.data&&typeof e.data.nodeId=="number"&&e.timestamp)}function Y_(){return Date.now()/1e3}function U8(e,t){try{if(!z8(t))return;const{source:n}=t.data;if(L8.has(n)&&e.registerMutation(t.timestamp),n===Je.Scroll&&e.registerScroll(t.timestamp),H8(t)){const{type:r,id:s}=t.data,i=Li.mirror.getNode(s);i instanceof HTMLElement&&r===ir.Click&&e.registerClick(i)}}catch{}}function z8(e){return e.type===R8}function H8(e){return e.data.source===Je.MouseInteraction}function ii(e){return{timestamp:Date.now()/1e3,type:"default",...e}}var L0=(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",e))(L0||{});const j8=new Set(["id","class","aria-label","role","name","alt","title","data-test-id","data-testid","disabled","aria-disabled","data-sentry-component"]);function q8(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(j8.has(n)){let r=n;(n==="data-testid"||n==="data-test-id")&&(r="testId"),t[r]=e[n]}return t}const W8=e=>t=>{if(!e.isEnabled())return;const n=G8(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&&$8(e.clickDetector,n,ZI(t.event)),Hd(e,n)};function tA(e,t){const n=Li.mirror.getId(e),r=n&&Li.mirror.getNode(n),s=r&&Li.mirror.getMeta(r),i=s&&Y8(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===L0.Text&&o.textContent).filter(Boolean).map(o=>o.trim()).join(""),attributes:q8(i.attributes)}}:{}}}function G8(e){const{target:t,message:n}=K8(e);return ii({category:`ui.${e.name}`,...tA(t,n)})}function K8(e){const t=e.name==="click";let n,r=null;try{r=t?ZI(e.event):eA(e.event),n=Ui(r,{maxStringLength:200})||"<unknown>"}catch{n="<unknown>"}return{target:r,message:n}}function Y8(e){return e.type===L0.Element}function X8(e,t){if(!e.isEnabled())return;e.updateUserActivity();const n=Q8(t);n&&Hd(e,n)}function Q8(e){const{metaKey:t,shiftKey:n,ctrlKey:r,altKey:s,key:i,target:o}=e;if(!o||J8(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>",c=tA(o,u);return ii({category:"ui.keyDown",message:u,data:{...c.data,metaKey:t,shiftKey:n,ctrlKey:r,altKey:s,key:i}})}function J8(e){return e.tagName==="INPUT"||e.tagName==="TEXTAREA"||e.isContentEditable}const Z8={resource:sj,paint:nj,navigation:rj};function bf(e,t){return({metric:n})=>void t.replayPerformanceEntries.push(e(n))}function ej(e){return e.map(tj).filter(Boolean)}function tj(e){const t=Z8[e.entryType];return t?t(e):null}function hu(e){return((Yr()||qt.performance.timeOrigin)+e)/1e3}function nj(e){const{duration:t,entryType:n,name:r,startTime:s}=e,i=hu(s);return{type:n,name:r,start:i,end:i+t,data:void 0}}function rj(e){const{entryType:t,name:n,decodedBodySize:r,duration:s,domComplete:i,encodedBodySize:o,domContentLoadedEventStart:a,domContentLoadedEventEnd:l,domInteractive:u,loadEventStart:c,loadEventEnd:d,redirectCount:f,startTime:p,transferSize:g,type:m}=e;return s===0?null:{type:`${t}.${m}`,start:hu(p),end:hu(i),name:n,data:{size:g,decodedBodySize:r,encodedBodySize:o,duration:s,domInteractive:u,domContentLoadedEventStart:a,domContentLoadedEventEnd:l,loadEventStart:c,loadEventEnd:d,domComplete:i,redirectCount:f}}}function sj(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:hu(i),end:hu(s),name:r,data:{size:u,statusCode:l,decodedBodySize:o,encodedBodySize:a}}}function ij(e){const t=e.entries[e.entries.length-1],n=t!=null&&t.element?[t.element]:void 0;return vm(e,"largest-contentful-paint",n)}function oj(e){return e.sources!==void 0}function aj(e){const t=[],n=[];for(const r of e.entries)if(oj(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 vm(e,"cumulative-layout-shift",n,t)}function lj(e){const t=e.entries[e.entries.length-1],n=t!=null&&t.target?[t.target]:void 0;return vm(e,"first-input-delay",n)}function uj(e){const t=e.entries[e.entries.length-1],n=t!=null&&t.target?[t.target]:void 0;return vm(e,"interaction-to-next-paint",n)}function vm(e,t,n,r){const s=e.value,i=e.rating,o=hu(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 cj(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(uu(s,n))}),r.push(hI(bf(ij,e)),x0(bf(aj,e)),pI(bf(lj,e)),mI(bf(uj,e))),()=>{r.forEach(s=>s())}}const Ke=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,dj='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]),s=new t([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),a=function(t,e){for(var i=new n(31),s=0;s<31;++s)i[s]=e+=1<<t[s-1];var a=new r(i[30]);for(s=1;s<30;++s)for(var o=i[s];o<i[s+1];++o)a[o]=o-i[s]<<5|s;return{b:i,r:a}},o=a(e,2),h=o.b,f=o.r;h[28]=258,f[258]=28;for(var l=a(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,s=0,a=new n(r);s<i;++s)t[s]&&++a[t[s]-1];var o,h=new n(r);for(s=1;s<r;++s)h[s]=h[s-1]+a[s-1]<<1;if(e){o=new n(1<<r);var f=15-r;for(s=0;s<i;++s)if(t[s])for(var l=s<<4|t[s],c=r-t[s],v=h[t[s]-1]++<<c,d=v|(1<<c)-1;v<=d;++v)o[u[v]>>f]=l}else for(o=new n(i),s=0;s<i;++s)t[s]&&(o[s]=u[h[t[s]-1]++]>>15-t[s]);return o},p=new t(288);for(c=0;c<144;++c)p[c]=8;for(c=144;c<256;++c)p[c]=9;for(c=256;c<280;++c)p[c]=7;for(c=280;c<288;++c)p[c]=8;var g=new t(32);for(c=0;c<32;++c)g[c]=5;var w=d(p,9,0),y=d(g,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=[],s=0;s<r.length;++s)r[s]&&i.push({s:s,f:r[s]});var a=i.length,o=i.slice();if(!a)return{t:F,l:0};if(1==a){var h=new t(i[0].s+1);return h[i[0].s]=1,{t:h,l:1}}i.sort((function(t,n){return t.f-n.f})),i.push({s:-1,f:25001});var f=i[0],l=i[1],u=0,c=1,v=2;for(i[0]={s:-1,f:f.f+l.f,l:f,r:l};c!=a-1;)f=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:f.f+l.f,l:f,r:l};var d=o[0].s;for(s=1;s<a;++s)o[s].s>d&&(d=o[s].s);var p=new n(d+1),g=A(i[c-1],p,0);if(g>e){s=0;var w=0,y=g-e,m=1<<y;for(o.sort((function(t,n){return p[n.s]-p[t.s]||t.f-n.f}));s<a;++s){var b=o[s].s;if(!(p[b]>e))break;w+=m-(1<<g-p[b]),p[b]=e}for(w>>=y;w>0;){var M=o[s].s;p[M]<e?w-=1<<e-p[M]++-1:++s}for(;s>=0&&w;--s){var E=o[s].s;p[E]==e&&(--p[E],++w)}g=e}return{t:new t(p),l:g}},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,s=t[0],a=1,o=function(t){e[i++]=t},h=1;h<=r;++h)if(t[h]==s&&h!=r)++a;else{if(!s&&a>2){for(;a>138;a-=138)o(32754);a>2&&(o(a>10?a-11<<5|28690:a-3<<5|12305),a=0)}else if(a>3){for(o(s),--a;a>6;a-=6)o(8304);a>2&&(o(a-3<<5|8208),a=0)}for(;a--;)o(s);a=1,s=t[h]}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 s=0;s<e;++s)t[i+s+4]=r[s];return 8*(i+4+e)},U=function(t,r,a,o,h,f,l,u,c,v,m){z(r,m++,a),++h[256];for(var b=x(h,15),M=b.t,E=b.l,A=x(f,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[s[K-1]];--K);var N,P,Q,R,V=v+5<<3,W=T(h,p)+T(f,g)+l,X=T(h,M)+T(f,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[s[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=w,P=p,Q=y,R=g;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,s=0|r.length,a=0;a!=s;){for(var o=Math.min(a+2655,s);a<o;++a)i+=e+=r[a];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(s,a,o,h,u){if(!u&&(u={l:1},a.dictionary)){var c=a.dictionary.subarray(-32768),v=new t(c.length+s.length);v.set(c),v.set(s,c.length),s=v,u.w=c.length}return function(s,a,o,h,u,c){var v=c.z||s.length,d=new t(h+v+5*(1+Math.ceil(v/7e3))+u),p=d.subarray(h,d.length-u),g=c.l,w=7&(c.r||0);if(a){w&&(p[0]=c.r>>3);for(var y=C[a-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(s[t]^s[t+1]<<A^s[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||!g)){w=U(s,p,0,F,I,S,O,q,G,j-G,w),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(s[j+Q]==s[j+Q-W]){for(var $=0;$<Z&&s[j+$]==s[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|f[Q]<<18|l[R];var it=31&f[Q],st=31&l[R];O+=e[it]+i[st],++I[257+it],++S[st],B=j+Q,++L}else F[q++]=s[j],++I[s[j]]}}for(j=Math.max(j,B);j<v;++j)F[q++]=s[j],++I[s[j]];w=U(s,p,g,F,I,S,O,q,G,j-G,w),g||(c.r=7&w|p[w/8|0]<<3,w-=7,c.h=x,c.p=_,c.i=j,c.w=B)}else{for(j=c.w||0;j<v+g;j+=65535){var at=j+65535;at>=v&&(p[w/8|0]=g,at=v),w=k(p,w+1,s.subarray(j,at))}c.i=v}return b(d,0,h+m(w)+u)}(s,null==a.level?6:a.level,null==a.mem?u.l?Math.ceil(1.5*Math.max(8,Math.min(13,Math.log(s.length)))):20:12+a.mem,o,h,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 s=this.b.length-this.s.z;this.b.set(n.subarray(0,s),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(s),32768),this.s.z=n.length-s+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.prototype.flush=function(){this.ondata||E(5),this.s.l&&E(4),this.p(this.b,!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.prototype.flush=function(){G.prototype.flush.call(this)},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)),s=0,a=function(t){i[s++]=t},o=0;o<e;++o){if(s+5>i.length){var h=new t(s+8+(e-o<<1));h.set(i),i=h}var f=n.charCodeAt(o);f<128||r?a(f):f<2048?(a(192|f>>6),a(128|63&f)):f>55295&&f<57344?(a(240|(f=65536+(1047552&f)|1023&n.charCodeAt(++o))>>18),a(128|f>>12&63),a(128|f>>6&63),a(128|63&f)):(a(224|f>>12),a(128|f>>6&63),a(128|63&f))}return b(i,0,s)}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),s=i.length;return q(i,n),j(i,s-8,r.d()),j(i,s-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 fj(){const e=new Blob([dj]);return URL.createObjectURL(e)}const X_=["info","warn","error","log"],oh="[Replay] ";function $g(e,t="info"){Lo({category:"console",data:{logger:"replay"},level:t,message:`${oh}${e}`},{level:t})}function hj(){let e=!1,t=!1;const n={exception:()=>{},infoTick:()=>{},setConfig:r=>{e=!!r.captureExceptions,t=!!r.traceInternals}};return Ke?(X_.forEach(r=>{n[r]=(...s)=>{Pe[r](oh,...s),t&&$g(s.join(""),XR(r))}}),n.exception=(r,...s)=>{s.length&&n.error&&n.error(...s),Pe.error(oh,r),e?ai(r):t&&$g(r,"error")},n.infoTick=(...r)=>{Pe.info(oh,...r),t&&setTimeout(()=>$g(r[0]),0)}):X_.forEach(r=>{n[r]=()=>{}}),n}const Ye=hj();class $0 extends Error{constructor(){super(`Event buffer exceeded maximum size of ${P0}.`)}}class nA{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>P0)throw new $0;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?D0(t):null}}class pj{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(){Ke&&Ye.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){Ke&&Ye.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 mj{constructor(t){this._worker=new pj(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=D0(t.timestamp);(!this._earliestTimestamp||n<this._earliestTimestamp)&&(this._earliestTimestamp=n);const r=JSON.stringify(t);return this._totalSize+=r.length,this._totalSize>P0?Promise.reject(new $0):this._sendEventToWorker(r)}finish(){return this._finishRequest()}clear(){this._earliestTimestamp=null,this._totalSize=0,this.hasCheckout=!1,this._worker.postMessage("clear").then(null,t=>{Ke&&Ye.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 gj{constructor(t){this._fallback=new nA,this._compression=new mj(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){Ke&&Ye.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){Ke&&Ye.exception(i,"Failed to add events when switching buffers.")}}}function vj({useCompression:e,workerUrl:t}){if(e&&window.Worker){const n=yj(t);if(n)return n}return Ke&&Ye.info("Using simple buffer"),new nA}function yj(e){try{const t=e||bj();if(!t)return;Ke&&Ye.info(`Using compression worker${e?` from ${e}`:""}`);const n=new Worker(t);return new gj(n)}catch(t){Ke&&Ye.exception(t,"Failed to create compression worker")}}function bj(){return typeof __SENTRY_EXCLUDE_REPLAY_WORKER__>"u"||!__SENTRY_EXCLUDE_REPLAY_WORKER__?fj():""}function F0(){try{return"sessionStorage"in qt&&!!qt.sessionStorage}catch{return!1}}function wj(e){Sj(),e.session=void 0}function Sj(){if(F0())try{qt.sessionStorage.removeItem(C0)}catch{}}function rA(e){return e===void 0?!1:Math.random()<e}function N0(e){if(F0())try{qt.sessionStorage.setItem(C0,JSON.stringify(e))}catch{}}function sA(e){const t=Date.now(),n=e.id||jr(),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 _j(e,t){return rA(e)?"session":t?"buffer":!1}function Q_({sessionSampleRate:e,allowBuffering:t,stickySession:n=!1},{previousSessionId:r}={}){const s=_j(e,t),i=sA({sampled:s,previousSessionId:r});return n&&N0(i),i}function kj(){if(!F0())return null;try{const e=qt.sessionStorage.getItem(C0);if(!e)return null;const t=JSON.parse(e);return Ke&&Ye.infoTick("Loading existing session"),sA(t)}catch{return null}}function Ty(e,t,n=+new Date){return e===null||t===void 0||t<0?!0:t===0?!1:e+t<=n}function iA(e,{maxReplayDuration:t,sessionIdleExpire:n,targetTime:r=Date.now()}){return Ty(e.started,t,r)||Ty(e.lastActivity,n,r)}function oA(e,{sessionIdleExpire:t,maxReplayDuration:n}){return!(!iA(e,{sessionIdleExpire:t,maxReplayDuration:n})||e.sampled==="buffer"&&e.segmentId===0)}function Fg({sessionIdleExpire:e,maxReplayDuration:t,previousSessionId:n},r){const s=r.stickySession&&kj();return s?oA(s,{sessionIdleExpire:e,maxReplayDuration:t})?(Ke&&Ye.infoTick("Session in sessionStorage is expired, creating new one..."),Q_(r,{previousSessionId:s.id})):s:(Ke&&Ye.infoTick("Creating new session"),Q_(r,{previousSessionId:n}))}function xj(e){return e.type===ot.Custom}function B0(e,t,n){return lA(e,t)?(aA(e,t,n),!0):!1}function Ej(e,t,n){return lA(e,t)?aA(e,t,n):Promise.resolve(null)}async function aA(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=Cj(t,i.beforeAddRecordingEvent);return o?await r.addEvent(o):void 0}catch(i){const o=i&&i instanceof $0,a=o?"addEventSizeExceeded":"addEvent";if(o&&s)return r.clear(),r.waitForCheckout=!0,null;e.handleException(i),await e.stop({reason:a});const l=ct();l&&l.recordDroppedEvent("internal_sdk_error","replay")}}function lA(e,t){if(!e.eventBuffer||e.isPaused()||!e.isEnabled())return!1;const n=D0(t.timestamp);return n+e.timeouts.sessionIdlePause<Date.now()?!1:n>e.getContext().initialTimestamp+e.getOptions().maxReplayDuration?(Ke&&Ye.infoTick(`Skipping event with timestamp ${n} because it is after maxReplayDuration`),!1):!0}function Cj(e,t){try{if(typeof t=="function"&&xj(e))return t(e)}catch(n){return Ke&&Ye.exception(n,"An error occurred in the `beforeAddRecordingEvent` callback, skipping the event..."),null}return e}function V0(e){return!e.type}function Py(e){return e.type==="transaction"}function Tj(e){return e.type==="replay_event"}function J_(e){return e.type==="feedback"}function Pj(e){return(t,n)=>{if(!e.isEnabled()||!V0(t)&&!Py(t))return;const r=n==null?void 0:n.statusCode;if(!(!r||r<200||r>=300)){if(Py(t)){Rj(e,t);return}Ij(e,t)}}}function Rj(e,t){var r,s;const n=e.getContext();(s=(r=t.contexts)==null?void 0:r.trace)!=null&&s.trace_id&&n.traceIds.size<100&&n.traceIds.add(t.contexts.trace.trace_id)}function Ij(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)||cu(async()=>{try{await e.sendBufferedReplayOrFlush()}catch(s){e.handleException(s)}})}function Aj(e){return t=>{!e.isEnabled()||!V0(t)||Oj(e,t)}}function Oj(e,t){var r,s,i;const n=(i=(s=(r=t.exception)==null?void 0:r.values)==null?void 0:s[0])==null?void 0:i.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 o=ii({category:"replay.hydrate-error",data:{url:Du()}});Hd(e,o)}}function Mj(e){const t=ct();t&&t.on("beforeAddBreadcrumb",n=>Dj(e,n))}function Dj(e,t){if(!e.isEnabled()||!uA(t))return;const n=Lj(t);n&&Hd(e,n)}function Lj(e){return!uA(e)||["fetch","xhr","sentry.event","sentry.transaction"].includes(e.category)||e.category.startsWith("ui.")?null:e.category==="console"?$j(e):ii(e)}function $j(e){var s;const t=(s=e.data)==null?void 0:s.arguments;if(!Array.isArray(t)||t.length===0)return ii(e);let n=!1;const r=t.map(i=>{if(!i)return i;if(typeof i=="string")return i.length>mf?(n=!0,`${i.slice(0,mf)}…`):i;if(typeof i=="object")try{const o=xs(i,7);return JSON.stringify(o).length>mf?(n=!0,`${JSON.stringify(o,null,2).slice(0,mf)}…`):o}catch{}return i});return ii({...e,data:{...e.data,arguments:r,...n?{_meta:{warnings:["CONSOLE_ARG_TRUNCATED"]}}:{}}})}function uA(e){return!!e.category}function Fj(e,t){var n;return e.type||!e.exception||!e.exception.values||!e.exception.values.length?!1:!!((n=t.originalException)!=null&&n.__rrweb__)}function cA(){const e=Vt().getPropagationContext().dsc;e&&delete e.replay_id;const t=Hn();if(t){const n=ji(t);delete n.replay_id}}function Nj(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 Bj(e,t){return e.recordingMode!=="buffer"||t.message===T0||!t.exception||t.type?!1:rA(e.getOptions().errorSampleRate)}function Vj(e){return Object.assign((t,n)=>!e.isEnabled()||e.isPaused()?t:Tj(t)?(delete t.breadcrumbs,t):!V0(t)&&!Py(t)&&!J_(t)?t:e.checkAndHandleExpiredSession()?J_(t)?(e.flush(),t.contexts.feedback.replay_id=e.getSessionId(),Nj(e,t),t):Fj(t,n)&&!e.getOptions()._experiments.captureExceptions?(Ke&&Ye.log("Ignoring error from rrweb internals",t),null):((Bj(e,t)||e.recordingMode==="session")&&(t.tags={...t.tags,replayId:e.getSessionId()}),t):(cA(),t),{id:"Replay"})}function ym(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 Uj(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 zj(e){return t=>{if(!e.isEnabled())return;const n=Uj(t);n!==null&&(e.getContext().urls.push(n.name),e.triggerUserActivity(),e.addUpdate(()=>(ym(e,[n]),!1)))}}function Hj(e,t){return Ke&&e.getOptions()._experiments.traceInternals?!1:BU(t,ct())}function dA(e,t){e.isEnabled()&&t!==null&&(Hj(e,t.name)||e.addUpdate(()=>(ym(e,[t]),!0)))}function bm(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=kI(e);return t.encode(n).length}if(e instanceof Blob)return e.size;if(e instanceof ArrayBuffer)return e.byteLength}catch{}}function fA(e){if(!e)return;const t=parseInt(e,10);return isNaN(t)?void 0:t}function sp(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 hA(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:{method:i,statusCode:o,request:a,response:l}}}function sd(e){return{headers:{},size:e,_meta:{warnings:["URL_SKIPPED"]}}}function To(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}=jj(n);return r.body=s,i!=null&&i.length&&(r._meta={warnings:i}),r}function Ry(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 jj(e){if(!e||typeof e!="string")return{body:e};const t=e.length>O_,n=qj(e);if(t){const r=e.slice(0,O_);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 qj(e){const t=e[0],n=e[e.length-1];return t==="["&&n==="]"||t==="{"&&n==="}"}function ip(e,t){const n=Wj(e);return Co(n,t)}function Wj(e,t=qt.document.baseURI){if(e.startsWith("http://")||e.startsWith("https://")||e.startsWith(qt.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 Gj(e,t,n){try{const r=await Yj(e,t,n),s=hA("resource.fetch",r);dA(n.replay,s)}catch(r){Ke&&Ye.exception(r,"Failed to capture fetch breadcrumb")}}function Kj(e,t){const{input:n,response:r}=t,s=n?EI(n):void 0,i=bm(s),o=r?fA(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 Yj(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:c}=e.data,d=ip(o,n.networkDetailAllowUrls)&&!ip(o,n.networkDetailDenyUrls),f=d?Xj(n,t.input,u):sd(u),p=await Qj(d,n,t.response,c);return{startTimestamp:s,endTimestamp:i,url:o,method:a,statusCode:l,request:f,response:p}}function Xj({networkCaptureBodies:e,networkRequestHeaders:t},n,r){const s=n?e6(n,t):{};if(!e)return To(s,r,void 0);const i=EI(n),[o,a]=xI(i,Ye),l=To(s,r,o);return a?sp(l,a):l}async function Qj(e,{networkCaptureBodies:t,networkResponseHeaders:n},r,s){if(!e&&s!==void 0)return sd(s);const i=r?pA(r.headers,n):{};if(!r||!t&&s!==void 0)return To(i,s,void 0);const[o,a]=await Zj(r),l=Jj(o,{networkCaptureBodies:t,responseBodySize:s,captureDetails:e,headers:i});return a?sp(l,a):l}function Jj(e,{networkCaptureBodies:t,responseBodySize:n,captureDetails:r,headers:s}){try{const i=e!=null&&e.length&&n===void 0?bm(e):n;return r?t?To(s,i,e):To(s,i,void 0):sd(i)}catch(i){return Ke&&Ye.exception(i,"Failed to serialize response body"),To(s,n,void 0)}}async function Zj(e){const t=t6(e);if(!t)return[void 0,"BODY_PARSE_ERROR"];try{return[await n6(t)]}catch(n){return n instanceof Error&&n.message.indexOf("Timeout")>-1?(Ke&&Ye.warn("Parsing text body from response timed out"),[void 0,"BODY_PARSE_TIMEOUT"]):(Ke&&Ye.exception(n,"Failed to get text body from response"),[void 0,"BODY_PARSE_ERROR"])}}function pA(e,t){const n={};return t.forEach(r=>{e.get(r)&&(n[r]=e.get(r))}),n}function e6(e,t){return e.length===1&&typeof e[0]!="string"?Z_(e[0],t):e.length===2?Z_(e[1],t):{}}function Z_(e,t){if(!e)return{};const n=e.headers;return n?n instanceof Headers?pA(n,t):Array.isArray(n)?{}:Ry(n,t):{}}function t6(e){try{return e.clone()}catch(t){Ke&&Ye.exception(t,"Failed to clone response body")}}function n6(e){return new Promise((t,n)=>{const r=cu(()=>n(new Error("Timeout while trying to read response body")),500);r6(e).then(s=>t(s),s=>n(s)).finally(()=>clearTimeout(r))})}async function r6(e){return await e.text()}async function s6(e,t,n){try{const r=o6(e,t,n),s=hA("resource.xhr",r);dA(n.replay,s)}catch(r){Ke&&Ye.exception(r,"Failed to capture xhr breadcrumb")}}function i6(e,t){const{xhr:n,input:r}=t;if(!n)return;const s=bm(r),i=n.getResponseHeader("content-length")?fA(n.getResponseHeader("content-length")):c6(n.response,n.responseType);s!==void 0&&(e.data.request_body_size=s),i!==void 0&&(e.data.response_body_size=i)}function o6(e,t,n){const r=Date.now(),{startTimestamp:s=r,endTimestamp:i=r,input:o,xhr:a}=t,{url:l,method:u,status_code:c=0,request_body_size:d,response_body_size:f}=e.data;if(!l)return null;if(!a||!ip(l,n.networkDetailAllowUrls)||ip(l,n.networkDetailDenyUrls)){const T=sd(d),P=sd(f);return{startTimestamp:s,endTimestamp:i,url:l,method:u,statusCode:c,request:T,response:P}}const p=a[ha],g=p?Ry(p.request_headers,n.networkRequestHeaders):{},m=Ry(a6(a),n.networkResponseHeaders),[y,w]=n.networkCaptureBodies?xI(o,Ye):[void 0],[b,k]=n.networkCaptureBodies?l6(a):[void 0],C=To(g,d,y),_=To(m,f,b);return{startTimestamp:s,endTimestamp:i,url:l,method:u,statusCode:c,request:w?sp(C,w):C,response:k?sp(_,k):_}}function a6(e){const t=e.getAllResponseHeaders();return t?t.split(`\r
|
|
52
|
+
`).reduce((n,r)=>{const[s,i]=r.split(": ");return i&&(n[s.toLowerCase()]=i),n},{}):{}}function l6(e){const t=[];try{return[e.responseText]}catch(n){t.push(n)}try{return u6(e.response,e.responseType)}catch(n){t.push(n)}return Ke&&Ye.warn("Failed to get xhr response body",...t),[void 0]}function u6(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 Ke&&Ye.exception(n,"Failed to serialize body",e),[void 0,"BODY_PARSE_ERROR"]}return Ke&&Ye.info("Skipping network body because of body type",e),[void 0,"UNPARSEABLE_BODY_TYPE"]}function c6(e,t){try{const n=t==="json"&&e&&typeof e=="object"?JSON.stringify(e):e;return bm(n)}catch{return}}function d6(e){const t=ct();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)=>f6(a,l,u))}catch{}}function f6(e,t,n){if(t.data)try{h6(t)&&m6(n)&&(i6(t,n),s6(t,n,e)),p6(t)&&g6(n)&&(Kj(t,n),Gj(t,n,e))}catch(r){Ke&&Ye.exception(r,"Error when enriching network breadcrumb")}}function h6(e){return e.category==="xhr"}function p6(e){return e.category==="fetch"}function m6(e){return e==null?void 0:e.xhr}function g6(e){return e==null?void 0:e.response}function v6(e,{autoFlushOnFeedback:t}){const n=ct();wI(W8(e)),hm(zj(e)),Mj(e),d6(e);const r=Vj(e);hU(r),n&&(n.on("beforeSendEvent",Aj(e)),n.on("afterSendEvent",Pj(e)),n.on("createDsc",s=>{const i=e.getSessionId();i&&e.isEnabled()&&e.recordingMode==="session"&&e.checkAndHandleExpiredSession()&&(s.replay_id=i)}),n.on("spanStart",s=>{e.lastActiveSpan=s}),n.on("spanEnd",s=>{e.lastActiveSpan=s}),n.on("beforeSendFeedback",async(s,i)=>{var a;const o=e.getSessionId();i!=null&&i.includeReplay&&e.isEnabled()&&o&&((a=s.contexts)!=null&&a.feedback)&&(s.contexts.feedback.source==="api"&&t&&await e.flush(),s.contexts.feedback.replay_id=o)}),t&&n.on("openFeedbackWidget",async()=>{await e.flush()}))}async function y6(e){try{return Promise.all(ym(e,[b6(qt.performance.memory)]))}catch{return[]}}function b6(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 w6(e,t,n){let r,s,i;const o=n!=null&&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 c(){return s&&clearTimeout(s),s=cu(a,t),o&&i===void 0&&(i=cu(a,o)),r}return c.cancel=l,c.flush=u,c}const Qr=dt.navigator;function S6(){return/iPhone|iPad|iPod/i.test((Qr==null?void 0:Qr.userAgent)??"")||/Macintosh/i.test((Qr==null?void 0:Qr.userAgent)??"")&&(Qr!=null&&Qr.maxTouchPoints)&&(Qr==null?void 0:Qr.maxTouchPoints)>1?{sampling:{mousemove:!1}}:{}}function _6(e){let t=!1;return(n,r)=>{if(!e.checkAndHandleExpiredSession()){Ke&&Ye.warn("Received replay event after session expired.");return}const s=r||!t;t=!0,e.clickDetector&&U8(e.clickDetector,n),e.addUpdate(()=>{if(e.recordingMode==="buffer"&&s&&e.setInitialState(),!B0(e,n,s))return!0;if(!s)return!1;const i=e.session;if(x6(e,s),e.recordingMode==="buffer"&&i&&e.eventBuffer){const o=e.eventBuffer.getEarliestTimestamp();o&&(Ke&&Ye.info(`Updating session start time to earliest event in buffer to ${new Date(o)}`),i.started=o,e.getOptions().stickySession&&N0(i))}return i!=null&&i.previousSessionId||e.recordingMode==="session"&&e.flush(),!0})}}function k6(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 x6(e,t){!t||!e.session||e.session.segmentId!==0||B0(e,k6(e),!1)}function E6(e,t,n,r){return sl(AR(e,b0(e),r,n),[[{type:"replay_event"},e],[{type:"replay_recording",length:typeof t=="string"?new TextEncoder().encode(t).length:t.length},t]])}function C6({recordingData:e,headers:t}){let n;const r=`${JSON.stringify(t)}
|
|
53
|
+
`;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 T6({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 $R(e.getOptions(),r,i,t,e,mi());if(!o)return null;e.emit("postprocessEvent",o,i),o.platform=o.platform||"javascript";const a=e.getSdkMetadata(),{name:l,version:u}=(a==null?void 0:a.sdk)||{};return o.sdk={...o.sdk,name:l||"sentry.javascript.unknown",version:u||"0.0.0"},o}async function P6({recordingData:e,replayId:t,segmentId:n,eventContext:r,timestamp:s,session:i}){const o=C6({recordingData:e,headers:{segment_id:n}}),{urls:a,errorIds:l,traceIds:u,initialTimestamp:c}=r,d=ct(),f=Vt(),p=d==null?void 0:d.getTransport(),g=d==null?void 0:d.getDsn();if(!d||!p||!g||!i.sampled)return qi({});const m={type:iH,replay_start_timestamp:c/1e3,timestamp:s/1e3,error_ids:l,trace_ids:u,urls:a,replay_id:t,segment_id:n,replay_type:i.sampled},y=await T6({scope:f,client:d,replayId:t,event:m});if(!y)return d.recordDroppedEvent("event_processor","replay"),Ke&&Ye.info("An event processor returned `null`, will not send event."),qi({});delete y.sdkProcessingMetadata;const w=E6(y,o,g,d.getOptions().tunnel);let b;try{b=await p.send(w)}catch(C){const _=new Error(T0);try{_.cause=C}catch{}throw _}if(typeof b.statusCode=="number"&&(b.statusCode<200||b.statusCode>=300))throw new mA(b.statusCode);const k=GR({},b);if(WR(k,"replay"))throw new U0(k);return b}class mA extends Error{constructor(t){super(`Transport returned status code ${t}`)}}class U0 extends Error{constructor(t){super("Rate limit hit"),this.rateLimits=t}}async function gA(e,t={count:0,interval:dH}){const{recordingData:n,onError:r}=e;if(n.length)try{return await P6(e),!0}catch(s){if(s instanceof mA||s instanceof U0)throw s;if(dU("Replays",{_retryCount:t.count}),r&&r(s),t.count>=fH){const i=new Error(`${T0} - max retries exceeded`);try{i.cause=s}catch{}throw i}return t.interval*=++t.count,new Promise((i,o)=>{cu(async()=>{try{await gA(e,t),i(!0)}catch(a){o(a)}},t.interval)})}}const vA="__THROTTLED",R6="__SKIPPED";function I6(e,t,n){const r=new Map,s=a=>{const l=a-n;r.forEach((u,c)=>{c<l&&r.delete(c)})},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 c=o;return o=!0,c?R6:vA}o=!1;const u=r.get(l)||0;return r.set(l,u+1),e(...a)}}class A6{constructor({options:t,recordingOptions:n}){this.eventBuffer=null,this.performanceEntries=[],this.replayPerformanceEntries=[],this.recordingMode="session",this.timeouts={sessionIdlePause:oH,sessionIdleExpire:aH},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=w6(()=>this._flush(),this._options.flushMinDelay,{maxWait:this._options.flushMaxDelay}),this._throttledAddEvent=I6((o,a)=>Ej(this,o,a),300,5);const{slowClickTimeout:r,slowClickIgnoreSelectors:s}=this.getOptions(),i=r?{threshold:Math.min(hH,r),timeout:r,scrollTimeout:pH,ignoreSelector:s?s.join(","):""}:void 0;if(i&&(this.clickDetector=new F8(this,i)),Ke){const o=t._experiments;Ye.setConfig({captureExceptions:!!o.captureExceptions,traceInternals:!!o.traceInternals})}this._handleVisibilityChange=()=>{qt.document.visibilityState==="visible"?this._doChangeToForegroundTasks():this._doChangeToBackgroundTasks()},this._handleWindowBlur=()=>{const o=ii({category:"ui.blur"});this._doChangeToBackgroundTasks(o)},this._handleWindowFocus=()=>{const o=ii({category:"ui.focus"});this._doChangeToForegroundTasks(o)},this._handleKeyboardEvent=o=>{X8(this,o)}}getContext(){return this._context}isEnabled(){return this._isEnabled}isPaused(){return this._isPaused}isRecordingCanvas(){return!!this._canvas}getOptions(){return this._options}handleException(t){Ke&&Ye.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){Ke&&Ye.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",Ke&&Ye.infoTick(`Starting replay in ${this.recordingMode} mode`),this._initializeRecording())}}start(){if(this._isEnabled&&this.recordingMode==="session"){Ke&&Ye.info("Recording is already in progress");return}if(this._isEnabled&&this.recordingMode==="buffer"){Ke&&Ye.info("Buffering is in progress, call `flush()` to save the replay");return}Ke&&Ye.infoTick("Starting replay in session mode"),this._updateUserActivity();const t=Fg({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){Ke&&Ye.info("Buffering is in progress, call `flush()` to save the replay");return}Ke&&Ye.infoTick("Starting replay in buffer mode");const t=Fg({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:cH}:this._options._experiments.continuousCheckout&&{checkoutEveryNms:Math.max(36e4,this._options._experiments.continuousCheckout)},emit:_6(this),...S6(),onMutation:this._onMutationHandler.bind(this),...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}={}){var r;if(this._isEnabled){this._isEnabled=!1;try{Ke&&Ye.info(`Stopping Replay${n?` triggered by ${n}`:""}`),cA(),this._removeListeners(),this.stopRecording(),this._debouncedFlush.cancel(),t&&await this._flush({force:!0}),(r=this.eventBuffer)==null||r.destroy(),this.eventBuffer=null,wj(this)}catch(s){this.handleException(s)}}}pause(){this._isPaused||(this._isPaused=!0,this.stopRecording(),Ke&&Ye.info("Pausing replay"))}resume(){!this._isPaused||!this._checkSession()||(this._isPaused=!1,this.startRecording(),Ke&&Ye.info("Resuming replay"))}async sendBufferedReplayOrFlush({continueRecording:t=!0}={}){if(this.recordingMode==="session")return this.flushImmediate();const n=Date.now();Ke&&Ye.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(){var t;return(t=this.session)==null?void 0:t.id}checkAndHandleExpiredSession(){if(this._lastActivity&&Ty(this._lastActivity,this.timeouts.sessionIdlePause)&&this.session&&this.session.sampled==="session"){this.pause();return}return!!this._checkSession()}setInitialState(){const t=`${qt.location.pathname}${qt.location.hash}${qt.location.search}`,n=`${qt.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===vA){const s=ii({category:"replay.throttled"});this.addUpdate(()=>!B0(this,{type:I8,timestamp:s.timestamp||0,data:{tag:"breadcrumb",payload:s,metric:!0}}))}return r}getCurrentRoute(){const t=this.lastActiveSpan||Hn(),n=t&&Vn(t),s=(n&&kt(n).data||{})[zr];if(!(!n||!s||!["route","custom"].includes(s)))return kt(n).description}_initializeRecording(){this.setInitialState(),this._updateSessionActivity(),this.eventBuffer=vj({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=Fg({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 oA(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{qt.document.addEventListener("visibilitychange",this._handleVisibilityChange),qt.addEventListener("blur",this._handleWindowBlur),qt.addEventListener("focus",this._handleWindowFocus),qt.addEventListener("keydown",this._handleKeyboardEvent),this.clickDetector&&this.clickDetector.addListeners(),this._hasInitializedCoreListeners||(v6(this,{autoFlushOnFeedback:this._options._experiments.autoFlushOnFeedback}),this._hasInitializedCoreListeners=!0)}catch(t){this.handleException(t)}this._performanceCleanupCallback=cj(this)}_removeListeners(){try{qt.document.removeEventListener("visibilitychange",this._handleVisibilityChange),qt.removeEventListener("blur",this._handleWindowBlur),qt.removeEventListener("focus",this._handleWindowFocus),qt.removeEventListener("keydown",this._handleKeyboardEvent),this.clickDetector&&this.clickDetector.removeListeners(),this._performanceCleanupCallback&&this._performanceCleanupCallback()}catch(t){this.handleException(t)}}_doChangeToBackgroundTasks(t){!this.session||iA(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()){Ke&&Ye.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=ej(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(ym(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(){var n;const t=this.getSessionId();if(!this.session||!this.eventBuffer||!t){Ke&&Ye.error("No session or eventBuffer found to flush.");return}if(await this._addPerformanceEntries(),!!((n=this.eventBuffer)!=null&&n.hasEvents)&&(await y6(this),!!this.eventBuffer&&t===this.getSessionId()))try{this._updateInitialTimestampFromEventBuffer();const r=Date.now();if(r-this._context.initialTimestamp>this._options.maxReplayDuration+3e4)throw new Error("Session is too long, not sending replay");const s=this._popEventContext(),i=this.session.segmentId++;this._maybeSaveSession();const o=await this.eventBuffer.finish();await gA({replayId:t,recordingData:o,segmentId:i,eventContext:s,session:this.session,timestamp:r,onError:a=>this.handleException(a)})}catch(r){this.handleException(r),this.stop({reason:"sendReplay"});const s=ct();if(s){const i=r instanceof U0?"ratelimit_backoff":"send_error";s.recordDroppedEvent(i,"replay")}}}async _flush({force:t=!1}={}){if(!this._isEnabled&&!t)return;if(!this.checkAndHandleExpiredSession()){Ke&&Ye.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){Ke&&Ye.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&&Ke&&Ye.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&&N0(this.session)}_onMutationHandler(t){const n=t.length,r=this._options.mutationLimit,s=this._options.mutationBreadcrumbLimit,i=r&&n>r;if(n>s||i){const o=ii({category:"replay.mutations",data:{count:n,limit:i}});this._createCustomBreadcrumb(o)}return i?(this.stop({reason:"mutationLimit",forceFlush:this.recordingMode==="session"}),!1):!0}}function tc(e,t){return[...e,...t].join(",")}function O6({mask:e,unmask:t,block:n,unblock:r,ignore:s}){const i=["base","iframe[srcdoc]:not([src])"],o=tc(e,[".sentry-mask","[data-sentry-mask]"]),a=tc(t,[]);return{maskTextSelector:o,unmaskTextSelector:a,blockSelector:tc(n,[".sentry-block","[data-sentry-block]",...i]),unblockSelector:tc(r,[]),ignoreSelector:tc(s,[".sentry-ignore","[data-sentry-ignore]",'input[type="file"]'])}}function M6({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 ek='img,image,svg,video,object,picture,embed,map,audio,link[rel="icon"],link[rel="apple-touch-icon"]',D6=["content-length","content-type","accept"];let tk=!1;const L6=e=>new $6(e);class $6{constructor({flushMinDelay:t=lH,flushMaxDelay:n=uH,minReplayDuration:r=mH,maxReplayDuration:s=M_,stickySession:i=!0,useCompression:o=!0,workerUrl:a,_experiments:l={},maskAllText:u=!0,maskAllInputs:c=!0,blockAllMedia:d=!0,mutationBreadcrumbLimit:f=750,mutationLimit:p=1e4,slowClickTimeout:g=7e3,slowClickIgnoreSelectors:m=[],networkDetailAllowUrls:y=[],networkDetailDenyUrls:w=[],networkCaptureBodies:b=!0,networkRequestHeaders:k=[],networkResponseHeaders:C=[],mask:_=[],maskAttributes:T=["title","placeholder"],unmask:P=[],block:S=[],unblock:E=[],ignore:I=[],maskFn:O,beforeAddRecordingEvent:R,beforeErrorSampling:M,onError:D}={}){this.name="Replay";const F=O6({mask:_,unmask:P,block:S,unblock:E,ignore:I});if(this._recordingOptions={maskAllInputs:c,maskAllText:u,maskInputOptions:{password:!0},maskTextFn:O,maskInputFn:O,maskAttributeFn:(U,K,X)=>M6({maskAttributes:T,maskAllText:u,privacyOptions:F,key:U,value:K,el:X}),...F,slimDOMOptions:"all",inlineStylesheet:!0,inlineImages:!1,collectFonts:!0,errorHandler:U=>{try{U.__rrweb__=!0}catch{}},recordCrossOriginIframes:!!l.recordCrossOriginIframes},this._initialOptions={flushMinDelay:t,flushMaxDelay:n,minReplayDuration:Math.min(r,gH),maxReplayDuration:Math.min(s,M_),stickySession:i,useCompression:o,workerUrl:a,blockAllMedia:d,maskAllInputs:c,maskAllText:u,mutationBreadcrumbLimit:f,mutationLimit:p,slowClickTimeout:g,slowClickIgnoreSelectors:m,networkDetailAllowUrls:y,networkDetailDenyUrls:w,networkCaptureBodies:b,networkRequestHeaders:nk(k),networkResponseHeaders:nk(C),beforeAddRecordingEvent:R,beforeErrorSampling:M,onError:D,_experiments:l},this._initialOptions.blockAllMedia&&(this._recordingOptions.blockSelector=this._recordingOptions.blockSelector?`${this._recordingOptions.blockSelector},${ek}`:ek),this._isInitialized&&k_())throw new Error("Multiple Sentry Session Replay instances are not supported");this._isInitialized=!0}get _isInitialized(){return tk}set _isInitialized(t){tk=t}afterAllSetup(t){!k_()||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(){var t;if((t=this._replay)!=null&&t.isEnabled())return this._replay.getSessionId()}getRecordingMode(){var t;if((t=this._replay)!=null&&t.isEnabled())return this._replay.recordingMode}_initialize(t){this._replay&&(this._maybeLoadFromReplayCanvasIntegration(t),this._replay.initializeSampling())}_setup(t){const n=F6(this._initialOptions,t);this._replay=new A6({options:n,recordingOptions:this._recordingOptions})}_maybeLoadFromReplayCanvasIntegration(t){try{const n=t.getIntegrationByName("ReplayCanvas");if(!n)return;this._replay._canvas=n.getOptions()}catch{}}}function F6(e,t){const n=t.getOptions(),r={sessionSampleRate:0,errorSampleRate:0,...e},s=Ha(n.replaysSessionSampleRate),i=Ha(n.replaysOnErrorSampleRate);return s==null&&i==null&&pi(()=>{console.warn("Replay is disabled because neither `replaysSessionSampleRate` nor `replaysOnErrorSampleRate` are set.")}),s!=null&&(r.sessionSampleRate=s),i!=null&&(r.errorSampleRate=i),r}function nk(e){return[...D6,...e.map(t=>t.toLowerCase())]}const rk=new WeakMap,Ng=new Map,yA={traceFetch:!0,traceXHR:!0,enableHTTPTimings:!0,trackFetchStreamPerformance:!1};function N6(e,t){const{traceFetch:n,traceXHR:r,trackFetchStreamPerformance:s,shouldCreateSpanForRequest:i,enableHTTPTimings:o,tracePropagationTargets:a,onRequestSpanStart:l}={...yA,...t},u=typeof i=="function"?i:f=>!0,c=f=>U6(f,a),d={};n&&(e.addEventProcessor(f=>(f.type==="transaction"&&f.spans&&f.spans.forEach(p=>{if(p.op==="http.client"){const g=Ng.get(p.span_id);g&&(p.timestamp=g/1e3,Ng.delete(p.span_id))}}),f)),s&&T4(f=>{if(f.response){const p=rk.get(f.response);p&&f.endTimestamp&&Ng.set(p,f.endTimestamp)}}),nI(f=>{const p=b4(f,u,c,d);if(f.response&&f.fetchData.__span&&rk.set(f.response,f.fetchData.__span),p){const g=bA(f.fetchData.url),m=g?Oa(g).host:void 0;p.setAttributes({"http.url":g,"server.address":m}),o&&sk(p),l==null||l(p,{headers:f.headers})}})),r&&_I(f=>{var g;const p=z6(f,u,c,d);if(p){o&&sk(p);let m;try{m=new Headers((g=f.xhr.__sentry_xhr_v3__)==null?void 0:g.request_headers)}catch{}l==null||l(p,{headers:m})}})}function B6(e){return e.entryType==="resource"&&"initiatorType"in e&&typeof e.nextHopProtocol=="string"&&(e.initiatorType==="fetch"||e.initiatorType==="xmlhttprequest")}function sk(e){const{url:t}=kt(e).data;if(!t||typeof t!="string")return;const n=uu("resource",({entries:r})=>{r.forEach(s=>{B6(s)&&s.name.endsWith(t)&&(V6(s).forEach(o=>e.setAttribute(...o)),setTimeout(n))})})}function js(e=0){return((Yr()||performance.timeOrigin)+e)/1e3}function V6(e){const{name:t,version:n}=bI(e.nextHopProtocol),r=[];return r.push(["network.protocol.version",n],["network.protocol.name",t]),Yr()?[...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 U6(e,t){const n=Du();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?Co(r.toString(),t)||i&&Co(r.pathname,t):i}else{const r=!!e.match(/^\/(?!\/)/);return t?Co(e,t):r}}function z6(e,t,n,r){const s=e.xhr,i=s==null?void 0:s[ha];if(!s||s.__sentry_own_request__||!i)return;const{url:o,method:a}=i,l=Hi()&&t(o);if(e.endTimestamp&&l){const m=s.__sentry_xhr_span_id__;if(!m)return;const y=r[m];y&&i.status_code!==void 0&&(fR(y,i.status_code),y.end(),delete r[m]);return}const u=bA(o),c=Oa(u||o),d=y4(o),f=!!Hn(),p=l&&f?Wa({name:`${a} ${d}`,attributes:{url:o,type:"xhr","http.method":a,"http.url":u,"server.address":c==null?void 0:c.host,[on]:"auto.http.browser",[za]:"http.client",...(c==null?void 0:c.search)&&{"http.query":c==null?void 0:c.search},...(c==null?void 0:c.hash)&&{"http.fragment":c==null?void 0:c.hash}}}):new qa;s.__sentry_xhr_span_id__=p.spanContext().spanId,r[s.__sentry_xhr_span_id__]=p,n(o)&&H6(s,Hi()&&f?p:void 0);const g=ct();return g&&g.emit("beforeOutgoingRequestSpan",p,e),p}function H6(e,t){const{"sentry-trace":n,baggage:r}=YR({span:t});n&&j6(e,n,r)}function j6(e,t,n){var s;const r=(s=e.__sentry_xhr_v3__)==null?void 0:s.request_headers;if(!(r!=null&&r["sentry-trace"]))try{if(e.setRequestHeader("sentry-trace",t),n){const i=r==null?void 0:r.baggage;(!i||!q6(i))&&e.setRequestHeader("baggage",n)}}catch{}}function q6(e){return e.split(",").some(t=>t.trim().startsWith("sentry-"))}function bA(e){try{return new URL(e,wt.location.origin).href}catch{return}}function W6(){wt.document?wt.document.addEventListener("visibilitychange",()=>{const e=Hn();if(!e)return;const t=Vn(e);if(wt.document.hidden&&t){const n="cancelled",{op:r,status:s}=kt(t);cs&&Pe.log(`[Tracing] Transaction: ${n} -> since tab moved to the background, op: ${r}`),s||t.setStatus({code:Tn,message:n}),t.setAttribute("sentry.cancellation_reason","document.hidden"),t.end()}}):cs&&Pe.warn("[Tracing] Could not set up background tab detection due to lack of global document")}const G6=3600,wA="sentry_previous_trace",K6="sentry.previous_trace";function Y6(e,{linkPreviousTrace:t,consistentTraceSampling:n}){const r=t==="session-storage";let s=r?J6():void 0;e.on("spanStart",o=>{if(Vn(o)!==o)return;const a=Vt().getPropagationContext();s=X6(s,o,a),r&&Q6(s)});let i=!0;n&&e.on("beforeSampling",o=>{if(!s)return;const a=Vt(),l=a.getPropagationContext();if(i&&l.parentSpanId){i=!1;return}a.setPropagationContext({...l,dsc:{...l.dsc,sample_rate:String(s.sampleRate),sampled:String(Iy(s.spanContext))},sampleRand:s.sampleRand}),o.parentSampled=Iy(s.spanContext),o.parentSampleRate=s.sampleRate,o.spanAttributes={...o.spanAttributes,[cR]:s.sampleRate}})}function X6(e,t,n){const r=kt(t);function s(){var a,l;try{return Number((a=n.dsc)==null?void 0:a.sample_rate)??Number((l=r.data)==null?void 0:l[p0])}catch{return 0}}const i={spanContext:t.spanContext(),startTimestamp:r.start_timestamp,sampleRate:s(),sampleRand:n.sampleRand};if(!e)return i;const o=e.spanContext;return o.traceId===r.trace_id?e:(Date.now()/1e3-e.startTimestamp<=G6&&(cs&&Pe.info(`Adding previous_trace ${o} link to span ${{op:r.op,...t.spanContext()}}`),t.addLink({context:o,attributes:{[jV]:"previous_trace"}}),t.setAttribute(K6,`${o.traceId}-${o.spanId}-${Iy(o)?1:0}`)),i)}function Q6(e){try{wt.sessionStorage.setItem(wA,JSON.stringify(e))}catch(t){cs&&Pe.warn("Could not store previous trace in sessionStorage",t)}}function J6(){var e;try{const t=(e=wt.sessionStorage)==null?void 0:e.getItem(wA);return JSON.parse(t)}catch{return}}function Iy(e){return e.traceFlags===1}const Z6="BrowserTracing",eq={...nh,instrumentNavigation:!0,instrumentPageLoad:!0,markBackgroundSpan:!0,enableLongTask:!0,enableLongAnimationFrame:!0,enableInp:!0,linkPreviousTrace:"in-memory",consistentTraceSampling:!1,_experiments:{},...yA};let ik=!1;const ok=(e={})=>{ik&&pi(()=>{console.warn("Multiple browserTracingIntegration instances are not supported.")}),ik=!0;const t=wt.document;f3();const{enableInp:n,enableLongTask:r,enableLongAnimationFrame:s,_experiments:{enableInteractions:i,enableStandaloneClsSpans:o},beforeStartSpan:a,idleTimeout:l,finalTimeout:u,childSpanTimeout:c,markBackgroundSpan:d,traceFetch:f,traceXHR:p,trackFetchStreamPerformance:g,shouldCreateSpanForRequest:m,enableHTTPTimings:y,instrumentPageLoad:w,instrumentNavigation:b,linkPreviousTrace:k,consistentTraceSampling:C,onRequestSpanStart:_}={...eq,...e},T=D5({recordClsStandaloneSpans:o||!1});n&&iz(),s&&dt.PerformanceObserver&&PerformanceObserver.supportedEntryTypes&&PerformanceObserver.supportedEntryTypes.includes("long-animation-frame")?$5():r&&L5(),i&&F5();const P={name:void 0,source:void 0};function S(E,I){const O=I.op==="pageload",R=a?a(I):I,M=R.attributes||{};I.name!==R.name&&(M[zr]="custom",R.attributes=M),P.name=R.name,P.source=M[zr];const D=LR(R,{idleTimeout:l,finalTimeout:u,childSpanTimeout:c,disableAutoFinish:O,beforeSpanEnd:U=>{T(),z5(U,{recordClsOnPageloadSpan:!o}),lk(E,void 0);const K=Vt(),X=K.getPropagationContext();K.setPropagationContext({...X,traceId:D.spanContext().traceId,sampled:rl(D),dsc:ji(U)})}});lk(E,D);function F(){t&&["interactive","complete"].includes(t.readyState)&&E.emit("idleSpanEnableAutoFinish",D)}O&&t&&(t.addEventListener("readystatechange",()=>{F()}),F())}return{name:Z6,afterAllSetup(E){let I=Du();function O(){const R=wm(E);R&&!kt(R).timestamp&&(cs&&Pe.log(`[Tracing] Finishing current active span with op: ${kt(R).op}`),R.end())}if(E.on("startNavigationSpan",R=>{ct()===E&&(O(),mi().setPropagationContext({traceId:Mo(),sampleRand:Math.random()}),Vt().setPropagationContext({traceId:Mo(),sampleRand:Math.random()}),S(E,{op:"navigation",...R}))}),E.on("startPageLoadSpan",(R,M={})=>{if(ct()!==E)return;O();const D=M.sentryTrace||ak("sentry-trace"),F=M.baggage||ak("baggage"),U=e3(D,F);Vt().setPropagationContext(U),S(E,{op:"pageload",...R})}),k!=="off"&&Y6(E,{linkPreviousTrace:k,consistentTraceSampling:C}),wt.location){if(w){const R=Yr();tq(E,{name:wt.location.pathname,startTime:R?R/1e3:void 0,attributes:{[zr]:"url",[on]:"auto.pageload.browser"}})}b&&hm(({to:R,from:M})=>{if(M===void 0&&(I==null?void 0:I.indexOf(R))!==-1){I=void 0;return}M!==R&&(I=void 0,SA(E,{name:wt.location.pathname,attributes:{[zr]:"url",[on]:"auto.navigation.browser"}}))})}d&&W6(),i&&nq(E,l,u,c,P),n&&az(),N6(E,{traceFetch:f,traceXHR:p,trackFetchStreamPerformance:g,tracePropagationTargets:E.getOptions().tracePropagationTargets,shouldCreateSpanForRequest:m,enableHTTPTimings:y,onRequestSpanStart:_})}}};function tq(e,t,n){return e.emit("startPageLoadSpan",t,n),Vt().setTransactionName(t.name),wm(e)}function SA(e,t){return e.emit("startNavigationSpan",t),Vt().setTransactionName(t.name),wm(e)}function ak(e){const t=wt.document,n=t==null?void 0:t.querySelector(`meta[name=${e}]`);return(n==null?void 0:n.getAttribute("content"))||void 0}function nq(e,t,n,r,s){const i=wt.document;let o;const a=()=>{const l="ui.action.click",u=wm(e);if(u){const c=kt(u).op;if(["navigation","pageload"].includes(c)){cs&&Pe.warn(`[Tracing] Did not create ${l} span because a pageload or navigation span is in progress.`);return}}if(o&&(o.setAttribute(ry,"interactionInterrupted"),o.end(),o=void 0),!s.name){cs&&Pe.warn(`[Tracing] Did not create ${l} transaction because _latestRouteName is missing.`);return}o=LR({name:s.name,op:l,attributes:{[zr]:s.source||"url"}},{idleTimeout:t,finalTimeout:n,childSpanTimeout:r})};i&&addEventListener("click",a,{once:!1,capture:!0})}const _A="_sentry_idleSpan";function wm(e){return e[_A]}function lk(e,t){Wr(e,_A,t)}const kA=["activate","mount"],xA=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,rq=/(?:^|[-_])(\w)/g,sq=e=>e.replace(rq,t=>t.toUpperCase()).replace(/[-_]/g,""),iq="<Root>",Bg="<Anonymous>",oq=(e,t)=>e.repeat(t),Ac=(e,t)=>{if(!e)return Bg;if(e.$root===e)return iq;if(!e.$options)return Bg;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?`<${sq(r)}>`:Bg)+(s&&t!==!1?` at ${s}`:"")},aq=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`
|
|
54
|
+
|
|
55
|
+
found in
|
|
56
|
+
|
|
57
|
+
${t.map((s,i)=>`${(i===0?"---> ":oq(" ",5+i*2))+(Array.isArray(s)?`${Ac(s[0])}... (${s[1]} recursive calls)`:Ac(s))}`).join(`
|
|
58
|
+
`)}`}return`
|
|
59
|
+
|
|
60
|
+
(found in ${Ac(e)})`},lq=(e,t)=>{const{errorHandler:n}=e.config;e.config.errorHandler=(r,s,i)=>{var u;const o=Ac(s,!1),a=s?aq(s):"",l={componentName:o,lifecycleHook:i,trace:a};if(t.attachProps&&s&&((u=s.$options)!=null&&u.propsData?l.propsData=s.$options.propsData:s.$props&&(l.propsData=s.$props)),setTimeout(()=>{ai(r,{captureContext:{contexts:{vue:l}},mechanism:{handled:!!n,type:"vue"}})}),typeof n=="function"&&e.config.errorHandler)n.call(e,r,s,i);else throw r}},uk="ui.vue",uq={activate:["activated","deactivated"],create:["beforeCreate","created"],unmount:["beforeUnmount","unmounted"],destroy:["beforeDestroy","destroyed"],mount:["beforeMount","mounted"],update:["beforeUpdate","updated"]};function cq(e,t,n){e.$_sentryRootSpanTimer&&clearTimeout(e.$_sentryRootSpanTimer),e.$_sentryRootSpanTimer=setTimeout(()=>{var r;(r=e.$root)!=null&&r.$_sentryRootSpan&&(e.$root.$_sentryRootSpan.end(t),e.$root.$_sentryRootSpan=void 0)},n)}function dq(e,t){function n(s){return s.replace(/^<([^\s]*)>(?: at [^\s]*)?$/,"$1")}return e.some(s=>n(t)===n(s))}const fq=(e={})=>{const t=(e.hooks||[]).concat(kA).filter((r,s,i)=>i.indexOf(r)===s),n={};for(const r of t){const s=uq[r];if(!s){xA&&Pe.warn(`Unknown hook: ${r}`);continue}for(const i of s)n[i]=function(){var u;const o=this.$root===this;o&&(this.$_sentryRootSpan=this.$_sentryRootSpan||Wa({name:"Application Render",op:`${uk}.render`,attributes:{[on]:"auto.ui.vue"},onlyIfParent:!0}));const a=Ac(this,!1),l=Array.isArray(e.trackComponents)?dq(e.trackComponents,a):e.trackComponents;if(!(!o&&!l))if(this.$_sentrySpans=this.$_sentrySpans||{},i==s[0]){if(((u=this.$root)==null?void 0:u.$_sentryRootSpan)||Hn()){const d=this.$_sentrySpans[r];d&&d.end(),this.$_sentrySpans[r]=Wa({name:`Vue ${a}`,op:`${uk}.${r}`,attributes:{[on]:"auto.ui.vue"},onlyIfParent:!0})}}else{const c=this.$_sentrySpans[r];if(!c)return;c.end(),cq(this,tr(),e.timeout||2e3)}}}return n},hq=dt,pq={Vue:hq.Vue,attachProps:!0,attachErrorHandler:!0,tracingOptions:{hooks:kA,timeout:2e3,trackComponents:!1}},mq="Vue",gq=(e={})=>({name:mq,setup(t){const n={...pq,...t.getOptions(),...e};if(!n.Vue&&!n.app){pi(()=>{console.warn("[@sentry/vue]: Misconfigured SDK. Vue specific errors will not be captured. Update your `Sentry.init` call with an appropriate config option: `app` (Application Instance - Vue 3) or `Vue` (Vue Constructor - Vue 2).")});return}n.app?(Array.isArray(n.app)?n.app:[n.app]).forEach(s=>ck(s,n)):n.Vue&&ck(n.Vue,n)}}),ck=(e,t)=>{var n;xA&&((n=e._instance)==null?void 0:n.isMounted)===!0&&pi(()=>{console.warn("[@sentry/vue]: Misconfigured SDK. Vue app is already mounted. Make sure to call `app.mount()` after `Sentry.init()`.")}),t.attachErrorHandler&&lq(e,t),Hi(t)&&e.mixin(fq(t.tracingOptions))};function vq(e={}){const t={defaultIntegrations:[...PI(),gq()],...e};return KR(t,"vue"),sH(t)}function yq(e,t,n){let r=!0;e.onError(s=>ai(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={[on]:"auto.navigation.vue"};for(const d of Object.keys(s.params))l[`params.${d}`]=s.params[d];for(const d of Object.keys(s.query)){const f=s.query[d];f&&(l[`query.${d}`]=f)}let u=s.path,c="url";if(s.name&&t.routeLabel!=="path")u=s.name.toString(),c="custom";else if(s.matched.length>0){const d=s.matched.length-1;u=s.matched[d].path,c="route"}if(Vt().setTransactionName(u),t.instrumentPageLoad&&a){const d=bq();d&&(kt(d).data[zr]!=="custom"&&(d.updateName(u),d.setAttribute(zr,c)),d.setAttributes({...l,[on]:"auto.pageload.vue"}))}t.instrumentNavigation&&!a&&(l[zr]=c,l[on]="auto.navigation.vue",n({name:u,op:"navigation",attributes:l})),o&&o()})}function bq(){const e=Hn(),t=e&&Vn(e);if(!t)return;const n=kt(t).op;return n==="navigation"||n==="pageload"?t:void 0}function wq(e={}){if(!e.router)return ok(e);const t=ok({...e,instrumentNavigation:!1}),{router:n,instrumentNavigation:r=!0,instrumentPageLoad:s=!0,routeLabel:i="name"}=e;return{...t,afterAllSetup(o){t.afterAllSetup(o),yq(n,{routeLabel:i,instrumentNavigation:r,instrumentPageLoad:s},l=>{SA(o,l)})}}}async function EA(){return"/"}async function Kn(e=!0,t=!0){const n=hn.create({baseURL:await EA()});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=us();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 d;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===fa.FailedDependency)return Promise.reject(r);if(![fa.Unauthorized,fa.Forbidden].includes(s.status))return console.error("Error in axios response interceptor which is not 401 or 403",r),ai(r),Promise.reject({message:`${r.message} - URL ${i==null?void 0:i.url}`,stack:r.stack});if(s.status===fa.Forbidden){const f=(d=r==null?void 0:r.response)==null?void 0:d.data;return console.error("[HttpClient] 403 Forbidden",f),Br("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=us();o.loadTokens();const{reasonCode:a,url:l}=o.extractSpecialReasonCode(r);if(a)return await o.logout(!1,a0(a)),console.error(`[AuthStore] 401 Unauthorized - emitting 'auth:${a}' with reason ${a}`),Br(`auth:${a}`).emit({url:l,error:r.message,reasonCode:a}),Promise.reject(r);await o.checkAuthenticationRequirements();const{success:u,handled:c}=await o.verifyOrRefreshLoginOnceOrLogout();if(c)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'"),Br("auth:failure").emit({url:i==null?void 0:i.url,error:r.message}),Promise.reject(r)}),n}class gr{static async get(t){return(await(await Kn(!0)).get(t)).data}static async put(t,n){return(await(await Kn(!0)).put(t,n)).data}static async post(t,n){return(await(await Kn(!0)).post(t,n)).data}static async postUpload(t,n,r){return await(await Kn(!0)).post(t,n,r)}static async getDownload(t,n){return await(await Kn(!0)).request({method:"GET",url:t,data:n,responseType:"arraybuffer"})}static async delete(t,n){return(await(await Kn(!0)).request({url:t,method:"delete",data:n})).data}static async patch(t,n){return(await(await Kn(!0)).patch(t,n)).data}}const oe=class oe{};we(oe,"base","/api"),we(oe,"firstTimeSetupRoute",`${oe.base}/first-time-setup`),we(oe,"completeFirstTimeSetupRoute",`${oe.firstTimeSetupRoute}/complete`),we(oe,"printerRoute",`${oe.base}/printer`),we(oe,"printerBatchRoute",`${oe.printerRoute}/batch`),we(oe,"printerTestConnectionRoute",`${oe.printerRoute}/test-connection`),we(oe,"printerSettingsRoute",`${oe.base}/printer-settings`),we(oe,"floorRoute",`${oe.base}/floor`),we(oe,"batchRoute",`${oe.base}/batch`),we(oe,"batchGetLastPrintedFilesRoute",`${oe.batchRoute}/reprint/list`),we(oe,"batchReprintFilesRoute",`${oe.batchRoute}/reprint/execute`),we(oe,"printCompletionRoute",`${oe.base}/print-completion`),we(oe,"printerFilesRoute",`${oe.base}/printer-files`),we(oe,"printerFilesPurgeRoute",`${oe.printerFilesRoute}/purge`),we(oe,"printerGroupRoute",`${oe.base}/printer-group`),we(oe,"createGroupRoute",`${oe.base}/printer-group`),we(oe,"customGCodeRoute",`${oe.base}/custom-gcode`),we(oe,"userRoute",`${oe.base}/user`),we(oe,"rolesRoute",`${oe.base}/user/roles`),we(oe,"userProfileRoute",`${oe.userRoute}/profile`),we(oe,"settingsRoute",`${oe.base}/settings`),we(oe,"settingsSensitiveRoute",`${oe.settingsRoute}/sensitive`),we(oe,"updateLoginRequiredRoute",`${oe.settingsRoute}/login-required`),we(oe,"updateRegistrationEnabledRoute",`${oe.settingsRoute}/registration-enabled`),we(oe,"updateCredentialSettings",`${oe.settingsRoute}/credential`),we(oe,"fileCleanSettingsRoute",`${oe.settingsRoute}/file-clean`),we(oe,"updateFrontendSettingsRoute",`${oe.settingsRoute}/frontend`),we(oe,"updateTimeoutSettingRoute",`${oe.settingsRoute}/timeout`),we(oe,"serverSentryDiagnosticsSettingRoute",`${oe.settingsRoute}/sentry-diagnostics`),we(oe,"updateExperimentalMoonrakerSupportRoute",`${oe.settingsRoute}/experimental-moonraker-support`),we(oe,"updateExperimentalThumbnailSupportRoute",`${oe.settingsRoute}/experimental-thumbnail-support`),we(oe,"updateExperimentalClientSupportRoute",`${oe.settingsRoute}/experimental-client-support`),we(oe,"updateExperimentalPrusaLinkSupportRoute",`${oe.settingsRoute}/experimental-prusa-link-support`),we(oe,"deleteGroupRoute",t=>`${oe.base}/printer-group/${t}`),we(oe,"updateGroupNameRoute",t=>`${oe.base}/printer-group/${t}/name`),we(oe,"addPrinterToGroupRoute",t=>`${oe.base}/printer-group/${t}/printer`),we(oe,"deletePrinterFromGroupRoute",oe.addPrinterToGroupRoute),we(oe,"getPrinterRoute",t=>`${oe.printerRoute}/${t}`),we(oe,"postPrinterDisabledReasonRoute",t=>`${oe.printerRoute}/${t}/disabled-reason`),we(oe,"getPrinterLoginDetailsRoute",t=>`${oe.getPrinterRoute(t)}/login-details`),we(oe,"restartOctoPrintRoute",t=>`${oe.getPrinterRoute(t)}/restart-octoprint`),we(oe,"refreshSocketRoute",t=>`${oe.getPrinterRoute(t)}/refresh-socket`),we(oe,"getPrinterSettingsRoute",t=>`${oe.printerSettingsRoute}/${t}`),we(oe,"setPrinterSettingsGCodeAnalysisRoute",t=>`${oe.getPrinterSettingsRoute(t)}/gcode-analysis`),we(oe,"syncPrinterNameSettingRoute",t=>`${oe.getPrinterSettingsRoute(t)}/sync-printername`),we(oe,"getFloorRoute",t=>`${oe.floorRoute}/${t}`),we(oe,"addOrRemovePrinterFromFloorRoute",t=>`${oe.getFloorRoute(t)}/printer`),we(oe,"sendQuickStopM112Route",t=>`${oe.customGCodeRoute}/send-emergency-m112/${t}`),we(oe,"updatePrinterFloorNameRoute",t=>`${oe.getFloorRoute(t)}/name`),we(oe,"updatePrinterFloorNumberRoute",t=>`${oe.getFloorRoute(t)}/floor-number`),we(oe,"printerFilesClearRoute",t=>`${oe.printerFilesRoute}/${t}/clear`),we(oe,"printerFilesSelectAndPrintRoute",t=>`${oe.printerFilesRoute}/${t}/select`),we(oe,"printerFilesUploadRoute",t=>`${oe.printerFilesRoute}/${t}/upload`),we(oe,"printerFilesCacheRoute",t=>`${oe.printerFilesRoute}/${t}/cache`),we(oe,"printerEnabledRoute",t=>`${oe.getPrinterRoute(t)}/enabled`),we(oe,"printerSerialConnectRoute",t=>`${oe.getPrinterRoute(t)}/serial-connect`),we(oe,"printerJogCommandRoute",t=>`${oe.getPrinterRoute(t)}/jog`),we(oe,"printerHomeCommandRoute",t=>`${oe.getPrinterRoute(t)}/home`),we(oe,"printerSerialDisconnectRoute",t=>`${oe.getPrinterRoute(t)}/serial-disconnect`),we(oe,"printerJobRoute",t=>`${oe.getPrinterRoute(t)}/job`),we(oe,"printerStopJobRoute",t=>`${oe.printerJobRoute(t)}/stop`),we(oe,"printerPauseJobRoute",t=>`${oe.printerJobRoute(t)}/pause`),we(oe,"printerResumeJobRoute",t=>`${oe.printerJobRoute(t)}/resume`),we(oe,"userChangeUsernameRoute",t=>`${oe.userRoute}/${t}/change-username`),we(oe,"userChangePasswordRoute",t=>`${oe.userRoute}/${t}/change-password`),we(oe,"userDeleteRoute",t=>`${oe.userRoute}/${t}`),we(oe,"userSetVerifiedRoute",t=>`${oe.userRoute}/${t}/set-verified`),we(oe,"userSetRootUserRoute",t=>`${oe.userRoute}/${t}/set-root-user`),we(oe,"userSetUserRolesRoute",t=>`${oe.userRoute}/${t}/set-user-roles`);let Me=oe;const Sq=Symbol("Progress snackbar message event symbol"),_q=Symbol("Info snackbar message event symbol"),kq=Symbol("Error snackbar message event symbol");function Dt(){const{emit:e,on:t}=Br(Sq),{emit:n,on:r}=Br(_q),{emit:s,on:i}=Br(kq);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 Ay(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 $i extends gr{static async getFiles(t){const n=`${Me.printerFilesRoute}/${t}`;return await this.get(n)}static async getThumbnail(t){const n=`${Me.printerFilesRoute}/${t}/thumbnail`;return await this.get(n)}static async getFileCache(t){const n=`${Me.printerFilesCacheRoute(t)}`;return await this.get(n)}static async selectAndPrintFile(t,n,r=!0){const s=Me.printerFilesSelectAndPrintRoute(t);return await this.post(s,{filePath:n,print:r})}static async uploadFile(t,n){const r=Me.printerFilesUploadRoute(t.id),s=new FormData;return s.append("files[0]",n),this.postUpload(r,s,{onUploadProgress:i=>{Dt().openProgressMessage("single-file-upload",`Uploading file ${n.name}`,100*i.loaded/i.total,!1)}})}static async clearFiles(t){const n=`${Me.printerFilesClearRoute(t)}`;return this.delete(n)}static async purgeFiles(){const t=`${Me.printerFilesPurgeRoute}`;return this.post(t)}static async deleteFileOrFolder(t,n){const r=`${Me.printerFilesRoute}/${t}?path=${encodeURIComponent(n)}`;return this.delete(r)}static async downloadFile(t,n){const r=`${Me.printerFilesRoute}/${t}/download/${encodeURIComponent(n)}`,s=await this.getDownload(r);Ay(s.data,n)}}const xq=["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"],Eq=["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 dk(e){return e?e.charAt(0).toUpperCase()+e.slice(1):""}function Vu(){const e=Math.round(Math.random()*1124),t=Math.round(Math.random()*3260);return`${dk(xq[e])} ${dk(Eq[t])}`}function Sm(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 Oy=()=>({id:void 0,name:Vu(),apiKey:"",username:"",password:"",printerURL:"",printerType:0,enabled:!0});class Qt extends gr{static convertPrinterToCreateForm(t){const n=Oy();return n.id=t.id,n.printerURL=t.printerURL,n.name=t.name||Vu(),n.apiKey=t.apiKey,n.username=t.username,n.password=t.password,n.enabled=t.enabled,n}static openPrinterURL(t){t&&window.open(t)}static async getPrinters(){const t=Me.printerRoute;return await this.get(t)}static async getPrinterLoginDetails(t){const n=Me.getPrinterLoginDetailsRoute(t);return await this.get(n)}static async restartOctoPrint(t){const n=`${Me.restartOctoPrintRoute(t)}`;return await this.post(n)}static async refreshSocket(t){const n=`${Me.refreshSocketRoute(t)}`;return await this.post(n)}static async sendPrinterConnectCommand(t){const n=Me.printerSerialConnectRoute(t);return await this.post(n)}static async sendPrinterDisconnectCommand(t){const n=Me.printerSerialDisconnectRoute(t);return await this.post(n)}static async sendPrinterJogCommand(t,n){const r=Me.printerJogCommandRoute(t);return await this.post(r,n)}static async sendPrinterHomeCommand(t,n){const r=Me.printerHomeCommandRoute(t);return await this.post(r,n)}static async createPrinter(t,n){const r=`${Me.printerRoute}?forceSave=${n}`;return await this.post(r,t)}static async batchImportPrinters(t){const n=Me.printerBatchRoute;return await this.post(n,t)}static async deletePrinter(t){const n=Me.getPrinterRoute(t);return await this.delete(n)}static async updatePrinter(t,n,r){const i=`${Me.getPrinterRoute(t)}?forceSave=${r}`;return await this.patch(i,n)}static async updatePrinterMaintenance(t,n=null){const r=Me.postPrinterDisabledReasonRoute(t);return await this.patch(r,{disabledReason:n})}static async testConnection(t){const n=Me.printerTestConnectionRoute;return await this.post(n,t)}static async toggleEnabled(t,n){const r=Me.printerEnabledRoute(t);return await this.patch(r,{enabled:n})}}class bn extends gr{static async getSettings(){const t=Me.settingsRoute;return await this.get(t)}static async getSettingsSensitive(){const t=Me.settingsSensitiveRoute;return await this.get(t)}static async updateLoginRequiredSettings(t){const n=`${Me.updateLoginRequiredRoute}`;return await this.put(n,{loginRequired:t})}static async updateRegistrationEnabledSettings(t){const n=`${Me.updateRegistrationEnabledRoute}`;return await this.put(n,{registrationEnabled:t})}static async updateCredentialSettings(t,n,r){const s=`${Me.updateCredentialSettings}`;return await this.put(s,{jwtExpiresIn:t,refreshTokenAttempts:n,refreshTokenExpiry:r})}static async updateFrontendSettings(t){const n=`${Me.updateFrontendSettingsRoute}`;return await this.put(n,t)}static async setSentryDiagnosticsSettings(t){const n=`${Me.serverSentryDiagnosticsSettingRoute}`;return await this.patch(n,{enabled:t})}static async updateTimeoutSettings(t){const n=`${Me.updateTimeoutSettingRoute}`;return await this.put(n,t)}static async setFileCleanSettings(t){const n=`${Me.fileCleanSettingsRoute}`;return await this.put(n,t)}static async updateExperimentalMoonrakerSupport(t){const n=Me.updateExperimentalMoonrakerSupportRoute;return await this.put(n,{enabled:t})}static async updateExperimentalPrusaLinkSupport(t){const n=Me.updateExperimentalPrusaLinkSupportRoute;return await this.put(n,{enabled:t})}static async updateExperimentalClientSupport(t){const n=Me.updateExperimentalClientSupportRoute;return await this.put(n,{enabled:t})}}class Ma extends gr{static async stopPrintJob(t){const n=Me.printerStopJobRoute(t);return await this.post(n)}static async pausePrintJob(t){const n=Me.printerPauseJobRoute(t);return await this.post(n)}static async resumePrintJob(t){const n=Me.printerResumeJobRoute(t);return await this.post(n)}}const Ns=gs("Settings",{state:()=>({settings:void 0,frontendDebugSettings:{showPrinterStateUpdateSideNav:!1,showInterpretedPrinterState:!1,showJobsRendered:!1}}),actions:{async loadSettings(){const e=await bn.getSettings();return this.settings=e,e},async updateFrontendSettings(e){const t=await bn.updateFrontendSettings(e);return this.settings=t,t},async saveFrontendSettings(){if(!this.settings)return;const e=await bn.updateFrontendSettings(this.settings.frontend);this.settings=e},async updateTimeoutSettings(e){const t=await bn.updateTimeoutSettings(e);return this.settings=t,t}},getters:{serverSettings(){var e;return(e=this.settings)==null?void 0:e.server},frontendSettings(){var e;return(e=this.settings)==null?void 0:e.frontend},preferCancelOverQuickStop(){var e,t;return((t=(e=this.settings)==null?void 0:e.frontend)==null?void 0:t.tilePreferCancelOverQuickStop)||!1},thumbnailsEnabled(){var e;return((e=this.settings)==null?void 0:e.server.experimentalThumbnailSupport)||!1},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"},fl={Disabled:"Disabled",Maintenance:"Maintenance",Offline:"Offline",Finding:"Finding",Disconnected:"Disconnected",Error:"Error",Paused:"Paused",Operational:"Operational",Printing:"Printing"};function CA(e,t,n){var f,p,g,m;const s=Ns().frontendDebugSettings.showInterpretedPrinterState,i={};if(!e.enabled)return(f=e.disabledReason)!=null&&f.length?{...i,color:yi.danger,rgb:bi.Black,text:fl.Maintenance}:{...i,color:yi.secondary,rgb:bi.DarkBlue,text:fl.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",c=(g=(p=n==null?void 0:n.current)==null?void 0:p.payload)==null?void 0:g.state,d=c==null?void 0:c.flags;if(!l||!d)return s&&console.debug(`Socket opened ${l?1:0}, socketAuthing ${u?1:0} printerState ${n?1:0},
|
|
61
|
+
currentState: ${c}, FLAGS ${d}`),{...i,color:yi.danger,rgb:bi.Red,text:n?"Awaiting state":"No USB"};if(!d){console.error("No flags",d);return}return d.error||d.closedOrError?{...i,color:yi.danger,rgb:bi.Red,text:((m=c.text)==null?void 0:m.replace("Offline","Disconnected"))||fl.Error,description:c.error}:d.paused||d.pausing?{...i,color:yi.success,rgb:bi.Brown,text:fl.Paused}:d.printing?{...i,color:yi.success,rgb:bi.LightBrown,text:fl.Printing}:{...i,color:yi.dark,rgb:bi.DarkGray,text:fl.Operational,description:c.error}}const Da=e=>{var t,n;return(n=(t=e==null?void 0:e.current)==null?void 0:t.payload)==null?void 0:n.state},Cq=e=>{var t;return(t=Da(e))==null?void 0:t.flags.printing},Tq=(e,t)=>{var n,r,s;return!_m(e)&&(e==null?void 0:e.enabled)&&!((n=Da(t))!=null&&n.flags.operational)||((r=Da(t))==null?void 0:r.flags.error)||((s=Da(t))==null?void 0:s.flags.closedOrError)},TA=e=>!_m(e)&&!(e!=null&&e.enabled),_m=e=>{var t;return!(e!=null&&e.enabled)&&((t=e==null?void 0:e.disabledReason)==null?void 0:t.length)},Pq=(e,t)=>{var n,r,s;return((n=Da(t))==null?void 0:n.flags)&&!((r=Da(t))!=null&&r.flags.printing)&&((s=Da(t))==null?void 0:s.flags.operational)&&!TA(e)&&!_m(e)},nr=gs("PrinterState",{state:()=>({printerIds:[],printerEventsById:{},socketStatesById:{}}),getters:{operationalPrintersById(){const e=Ft(),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)||(n==null?void 0:n.pausing)}},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)||(n==null?void 0:n.pausing)}},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=Ft(),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=nr();return Object.values(e.onlinePrintersWithStates).filter(t=>Cq(t.printerState)).length},operationalNotPrintingCount(){return this.onlinePrintersWithStates.filter(e=>Pq(e.printer,e.printerState)).length},isApiResponding(){return e=>Object.keys(this.onlinePrinters).includes(e.toString())},isPrinterNotOnline(){return e=>!this.isApiResponding(e)},printerJobsById(){const e=Ft(),t=Ns().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||i!=null&&i.pausing){const c=e.printer(r);if(c)n[c.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=Ft(),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||s!=null&&s.pausing){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,c;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||r!=null&&r.pausing)&&(e[t]=(c=(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:c.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||!Ft().printer(e))){if(this.isPrinterPrinting(e)){alert("This printer is printing or not connected! Either way printing is not an option.");return}await $i.selectAndPrintFile(e,t,!0)}}}}),Ft=gs("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(TA).length},disconnectedCount(){const e=nr();return this.printers.filter(t=>Tq(t,e.printerEventsById[t.id])).length},maintenanceCount(){return this.printers.filter(e=>_m(e)).length}},actions:{async createPrinter(e,t){const n=await Qt.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=nr(),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 Qt.updatePrinter(e,t,n);return this._replacePrinter({printerId:e,printer:r}),r},async loadPrinters(){const e=await Qt.getPrinters();return this.setPrinters(e),e},async deletePrinter(e){const t=await Qt.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 deletePrinterFiles(e){if(!e)throw new Error("No printerId was provided");const t=await $i.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 $i.getFiles(e);return t.sort((n,r)=>n.date<r.date?1:-1),this.printerFileCache[e]=t,t},async deletePrinterFile(e,t){await $i.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=nr();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 Ma.stopPrintJob(n.id)}}}),Mn=ke()({name:"VCardActions",props:Ue(),setup(e,t){let{slots:n}=t;return Ir({VBtn:{slim:!0,variant:"text"}}),Oe(()=>{var r;return h("div",{class:["v-card-actions",e.class],style:e.style},[(r=n.default)==null?void 0:r.call(n)])}),{}}}),Rq=de({opacity:[Number,String],...Ue(),...yt()},"VCardSubtitle"),km=ke()({name:"VCardSubtitle",props:Rq(),setup(e,t){let{slots:n}=t;return Oe(()=>h(e.tag,{class:["v-card-subtitle",e.class],style:[{"--v-card-subtitle-opacity":e.opacity},e.style]},n)),{}}}),sn=ku("v-card-title");function Iq(e){return{aspectStyles:A(()=>{const t=Number(e.aspectRatio);return t?{paddingBottom:String(1/t*100)+"%"}:void 0})}}const PA=de({aspectRatio:[String,Number],contentClass:null,inline:Boolean,...Ue(),...Or()},"VResponsive"),fk=ke()({name:"VResponsive",props:PA(),setup(e,t){let{slots:n}=t;const{aspectStyles:r}=Iq(e),{dimensionStyles:s}=Mr(e);return Oe(()=>{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 Aq(e,t){if(!Wb)return;const n=t.modifiers||{},r=t.value,{handler:s,options:i}=typeof r=="object"?r:{handler:r,options:{}},o=new IntersectionObserver(function(){var d;let a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],l=arguments.length>1?arguments[1]:void 0;const u=(d=e._observe)==null?void 0:d[t.instance.$.uid];if(!u)return;const c=a.some(f=>f.isIntersecting);s&&(!n.quiet||u.init)&&(!n.once||c||u.init)&&s(c,a,l),c&&n.once?RA(e,t):u.init=!0},i);e._observe=Object(e._observe),e._observe[t.instance.$.uid]={init:!1,observer:o},o.observe(e)}function RA(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 z0={mounted:Aq,unmounted:RA},Oq=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,...PA(),...Ue(),...Dn(),...Iu()},"VImg"),ds=ke()({name:"VImg",directives:{intersect:z0},props:Oq(),emits:{loadstart:e=>!0,load:e=>!0,error:e=>!0},setup(e,t){let{emit:n,slots:r}=t;const{backgroundColorClasses:s,backgroundColorStyles:i}=fr(()=>e.color),{roundedClasses:o}=zn(e),a=an("VImg"),l=Ie(""),u=j(),c=Ie(e.eager?"loading":"idle"),d=Ie(),f=Ie(),p=A(()=>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=A(()=>p.value.aspect||d.value/f.value||0);Ee(()=>e.src,()=>{m(c.value!=="idle")}),Ee(g,(R,M)=>{!R&&M&&u.value&&C(u.value)}),Su(()=>m());function m(R){if(!(e.eager&&R)&&!(Wb&&!R&&!e.eager)){if(c.value="loading",p.value.lazySrc){const M=new Image;M.src=p.value.lazySrc,C(M,null)}p.value.src&&Mt(()=>{var M;n("loadstart",((M=u.value)==null?void 0:M.currentSrc)||p.value.src),setTimeout(()=>{var D;if(!a.isUnmounted)if((D=u.value)!=null&&D.complete){if(u.value.naturalWidth||w(),c.value==="error")return;g.value||C(u.value,null),c.value==="loading"&&y()}else g.value||C(u.value),b()})})}}function y(){var R;a.isUnmounted||(b(),C(u.value),c.value="loaded",n("load",((R=u.value)==null?void 0:R.currentSrc)||p.value.src))}function w(){var R;a.isUnmounted||(c.value="error",n("error",((R=u.value)==null?void 0:R.currentSrc)||p.value.src))}function b(){const R=u.value;R&&(l.value=R.currentSrc||R.src)}let k=-1;Cn(()=>{clearTimeout(k)});function C(R){let M=arguments.length>1&&arguments[1]!==void 0?arguments[1]:100;const D=()=>{if(clearTimeout(k),a.isUnmounted)return;const{naturalHeight:F,naturalWidth:U}=R;F||U?(d.value=U,f.value=F):!R.complete&&c.value==="loading"&&M!=null?k=window.setTimeout(D,M):(R.currentSrc.endsWith(".svg")||R.currentSrc.startsWith("data:image/svg+xml"))&&(d.value=1,f.value=1)};D()}const _=ae(()=>({"v-img__img--cover":e.cover,"v-img__img--contain":!e.cover})),T=()=>{var D;if(!p.value.src||c.value==="idle")return null;const R=h("img",{class:["v-img__img",_.value],style:{objectPosition:e.position},crossorigin:e.crossorigin,src:p.value.src,srcset:p.value.srcset,alt:e.alt,referrerpolicy:e.referrerpolicy,draggable:e.draggable,sizes:e.sizes,ref:u,onLoad:y,onError:w},null),M=(D=r.sources)==null?void 0:D.call(r);return h(si,{transition:e.transition,appear:!0},{default:()=>[Bt(M?h("picture",{class:"v-img__picture"},[M,R]):R,[[Yi,c.value==="loaded"]])]})},P=()=>h(si,{transition:e.transition},{default:()=>[p.value.lazySrc&&c.value!=="loaded"&&h("img",{class:["v-img__img","v-img__img--preload",_.value],style:{objectPosition:e.position},crossorigin:e.crossorigin,src:p.value.lazySrc,alt:e.alt,referrerpolicy:e.referrerpolicy,draggable:e.draggable},null)]}),S=()=>r.placeholder?h(si,{transition:e.transition,appear:!0},{default:()=>[(c.value==="loading"||c.value==="error"&&!r.error)&&h("div",{class:"v-img__placeholder"},[r.placeholder()])]}):null,E=()=>r.error?h(si,{transition:e.transition,appear:!0},{default:()=>[c.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,O=Ie(!1);{const R=Ee(g,M=>{M&&(requestAnimationFrame(()=>{requestAnimationFrame(()=>{O.value=!0})}),R())})}return Oe(()=>{const R=fk.filterProps(e);return Bt(h(fk,ge({class:["v-img",{"v-img--absolute":e.absolute,"v-img--booting":!O.value},s.value,o.value,e.class],style:[{width:Ne(e.width==="auto"?d.value:e.width)},i.value,e.style]},R,{aspectRatio:g.value,"aria-label":e.alt,role:e.alt?"img":void 0}),{additional:()=>h(Ae,null,[h(T,null,null),h(P,null,null),h(I,null,null),h(S,null,null),h(E,null,null)]),default:r.default}),[[hr("intersect"),{handler:m,options:e.options},null,{once:!0}]])}),{currentSrc:l,image:u,state:c,naturalWidth:d,naturalHeight:f}}}),Mq=de({start:Boolean,end:Boolean,icon:He,image:String,text:String,...vs(),...Ue(),...Ar(),...Dn(),...Eu(),...yt(),...Lt(),...$s({variant:"flat"})},"VAvatar"),ut=ke()({name:"VAvatar",props:Mq(),setup(e,t){let{slots:n}=t;const{themeClasses:r}=Zt(e),{borderClasses:s}=Ds(e),{colorClasses:i,colorStyles:o,variantClasses:a}=Za(e),{densityClasses:l}=ys(e),{roundedClasses:u}=zn(e),{sizeClasses:c,sizeStyles:d}=Pd(e);return Oe(()=>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,c.value,a.value,e.class],style:[o.value,d.value,e.style]},{default:()=>[n.default?h(Ot,{key:"content-defaults",defaults:{VImg:{cover:!0,src:e.image},VIcon:{icon:e.icon}}},{default:()=>[n.default()]}):e.image?h(ds,{key:"image",src:e.image,alt:"",cover:!0},null):e.icon?h(J,{key:"icon",icon:e.icon},null):e.text,Ho(!1,"v-avatar")]})),{}}}),Dq=de({appendAvatar:String,appendIcon:He,prependAvatar:String,prependIcon:He,subtitle:{type:[String,Number,Boolean],default:void 0},title:{type:[String,Number,Boolean],default:void 0},...Ue(),...Ar()},"VCardItem"),Lq=ke()({name:"VCardItem",props:Dq(),setup(e,t){let{slots:n}=t;return Oe(()=>{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(Ot,{key:"prepend-defaults",disabled:!r,defaults:{VAvatar:{density:e.density,image:e.prependAvatar},VIcon:{density:e.density,icon:e.prependIcon}}},n.prepend):h(Ae,null,[e.prependAvatar&&h(ut,{key:"prepend-avatar",density:e.density,image:e.prependAvatar},null),e.prependIcon&&h(J,{key:"prepend-icon",density:e.density,icon:e.prependIcon},null)])]),h("div",{class:"v-card-item__content"},[a&&h(sn,{key:"title"},{default:()=>{var c;return[((c=n.title)==null?void 0:c.call(n))??re(e.title)]}}),l&&h(km,{key:"subtitle"},{default:()=>{var c;return[((c=n.subtitle)==null?void 0:c.call(n))??re(e.subtitle)]}}),(u=n.default)==null?void 0:u.call(n)]),o&&h("div",{key:"append",class:"v-card-item__append"},[n.append?h(Ot,{key:"append-defaults",disabled:!i,defaults:{VAvatar:{density:e.density,image:e.appendAvatar},VIcon:{density:e.density,icon:e.appendIcon}}},n.append):h(Ae,null,[e.appendIcon&&h(J,{key:"append-icon",density:e.density,icon:e.appendIcon},null),e.appendAvatar&&h(ut,{key:"append-avatar",density:e.density,image:e.appendAvatar},null)])])])}),{}}}),$q=de({opacity:[Number,String],...Ue(),...yt()},"VCardText"),en=ke()({name:"VCardText",props:$q(),setup(e,t){let{slots:n}=t;return Oe(()=>h(e.tag,{class:["v-card-text",e.class],style:[{"--v-card-text-opacity":e.opacity},e.style]},n)),{}}}),Fq=de({appendAvatar:String,appendIcon:He,disabled:Boolean,flat:Boolean,hover:Boolean,image:String,link:{type:Boolean,default:void 0},prependAvatar:String,prependIcon:He,ripple:{type:[Boolean,Object],default:!0},subtitle:{type:[String,Number,Boolean],default:void 0},text:{type:[String,Number,Boolean],default:void 0},title:{type:[String,Number,Boolean],default:void 0},...vs(),...Ue(),...Ar(),...Or(),...bs(),...Gp(),...jo(),...Cu(),...Dn(),...Xp(),...yt(),...Lt(),...$s({variant:"elevated"})},"VCard"),vt=ke()({name:"VCard",directives:{Ripple:Pu},props:Fq(),setup(e,t){let{attrs:n,slots:r}=t;const{themeClasses:s}=Zt(e),{borderClasses:i}=Ds(e),{colorClasses:o,colorStyles:a,variantClasses:l}=Za(e),{densityClasses:u}=ys(e),{dimensionStyles:c}=Mr(e),{elevationClasses:d}=Ls(e),{loaderClasses:f}=Rd(e),{locationStyles:p}=el(e),{positionClasses:g}=Tu(e),{roundedClasses:m}=zn(e),y=Yp(e,n);return Oe(()=>{const w=e.link!==!1&&y.isLink.value,b=!e.disabled&&e.link!==!1&&(e.link||y.isClickable.value),k=w?"a":e.tag,C=!!(r.title||e.title!=null),_=!!(r.subtitle||e.subtitle!=null),T=C||_,P=!!(r.append||e.appendAvatar||e.appendIcon),S=!!(r.prepend||e.prependAvatar||e.prependIcon),E=!!(r.image||e.image),I=T||S||P,O=!!(r.text||e.text!=null);return Bt(h(k,ge({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":b},s.value,i.value,o.value,u.value,d.value,f.value,g.value,m.value,l.value,e.class],style:[a.value,c.value,p.value,e.style],onClick:b&&y.navigate,tabindex:e.disabled?-1:void 0},y.linkProps),{default:()=>{var R;return[E&&h("div",{key:"image",class:"v-card__image"},[r.image?h(Ot,{key:"image-defaults",disabled:!e.image,defaults:{VImg:{cover:!0,src:e.image}}},r.image):h(ds,{key:"image-img",cover:!0,src:e.image},null)]),h(Kp,{name:"v-card",active:!!e.loading,color:typeof e.loading=="boolean"?void 0:e.loading},{default:r.loader}),I&&h(Lq,{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}),O&&h(en,{key:"text"},{default:()=>{var M;return[((M=r.text)==null?void 0:M.call(r))??e.text]}}),(R=r.default)==null?void 0:R.call(r),r.actions&&h(Mn,null,{default:r.actions}),Ho(b,"v-card")]}}),[[hr("ripple"),b&&e.ripple]])}),{}}}),IA=Symbol.for("vuetify:goto");function AA(){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 Nq(e){return H0(e)??(document.scrollingElement||document.body)}function H0(e){return typeof e=="string"?document.querySelector(e):Gb(e)}function Vg(e,t,n){if(typeof e=="number")return t&&n?-e:e;let r=H0(e),s=0;for(;r;)s+=t?r.offsetLeft:r.offsetTop,r=r.offsetParent;return s}function Bq(e,t){return{rtl:t.isRtl,options:Zn(AA(),e)}}async function hk(e,t,n,r){const s=n?"scrollLeft":"scrollTop",i=Zn((r==null?void 0:r.options)??AA(),t),o=r==null?void 0:r.rtl.value,a=(typeof e=="number"?e:H0(e))??0,l=i.container==="parent"&&a instanceof HTMLElement?a.parentElement:Nq(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 c;if(typeof a=="number")c=Vg(a,n,o);else if(c=Vg(a,n,o)-Vg(l,n,o),i.layout){const g=window.getComputedStyle(a).getPropertyValue("--v-layout-top");g&&(c-=parseInt(g,10))}c+=i.offset,c=Uq(l,c,!!o,!!n);const d=l[s]??0;if(c===d)return Promise.resolve(c);const f=performance.now();return new Promise(p=>requestAnimationFrame(function g(m){const w=(m-f)/i.duration,b=Math.floor(d+(c-d)*u(Cr(w,0,1)));if(l[s]=b,w>=1&&Math.abs(b-l[s])<10)return p(c);if(w>2)return p(l[s]);requestAnimationFrame(g)}))}function Vq(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const t=Qe(IA),{isRtl:n}=Dr();if(!t)throw new Error("[Vuetify] Could not find injected goto instance");const r={...t,rtl:ae(()=>t.rtl.value||n.value)};async function s(i,o){return hk(i,Zn(e,o),!1,r)}return s.horizontal=async(i,o)=>hk(i,Zn(e,o),!0,r),s}function Uq(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 zq(e){let{selectedElement:t,containerElement:n,isRtl:r,isHorizontal:s}=e;const i=id(s,n),o=OA(s,r,n),a=id(s,t),l=MA(s,t),u=a*.4;return o>l?l-u:o+i<l+a?l-i+a+u:o}function Hq(e){let{selectedElement:t,containerElement:n,isHorizontal:r}=e;const s=id(r,n),i=MA(r,t),o=id(r,t);return i-s/2+o/2}function pk(e,t){const n=e?"scrollWidth":"scrollHeight";return(t==null?void 0:t[n])||0}function jq(e,t){const n=e?"clientWidth":"clientHeight";return(t==null?void 0:t[n])||0}function OA(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 id(e,t){const n=e?"offsetWidth":"offsetHeight";return(t==null?void 0:t[n])||0}function MA(e,t){const n=e?"offsetLeft":"offsetTop";return(t==null?void 0:t[n])||0}const qq=Symbol.for("vuetify:v-slide-group"),DA=de({centerActive:Boolean,direction:{type:String,default:"horizontal"},symbol:{type:null,default:qq},nextIcon:{type:He,default:"$next"},prevIcon:{type:He,default:"$prev"},showArrows:{type:[Boolean,String],validator:e=>typeof e=="boolean"||["always","desktop","mobile"].includes(e)},...Ue(),...tl({mobile:null}),...yt(),...Ed({selectedClass:"v-slide-group-item--active"})},"VSlideGroup"),mk=ke()({name:"VSlideGroup",props:DA(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const{isRtl:r}=Dr(),{displayClasses:s,mobile:i}=fi(e),o=xu(e,e.symbol),a=Ie(!1),l=Ie(0),u=Ie(0),c=Ie(0),d=A(()=>e.direction==="horizontal"),{resizeRef:f,contentRect:p}=Va(),{resizeRef:g,contentRect:m}=Va(),y=Vq(),w=A(()=>({container:f.el,duration:200,easing:"easeOutQuart"})),b=A(()=>o.selected.value.length?o.items.value.findIndex(ee=>ee.id===o.selected.value[0]):-1),k=A(()=>o.selected.value.length?o.items.value.findIndex(ee=>ee.id===o.selected.value[o.selected.value.length-1]):-1);if(Et){let ee=-1;Ee(()=>[o.selected.value,p.value,m.value,d.value],()=>{cancelAnimationFrame(ee),ee=requestAnimationFrame(()=>{if(p.value&&m.value){const q=d.value?"width":"height";u.value=p.value[q],c.value=m.value[q],a.value=u.value+1<c.value}if(b.value>=0&&g.el){const q=g.el.children[k.value];_(q,e.centerActive)}})})}const C=Ie(!1);function _(ee,q){let G=0;q?G=Hq({containerElement:f.el,isHorizontal:d.value,selectedElement:ee}):G=zq({containerElement:f.el,isHorizontal:d.value,isRtl:r.value,selectedElement:ee}),T(G)}function T(ee){if(!Et||!f.el)return;const q=id(d.value,f.el),G=OA(d.value,r.value,f.el);if(!(pk(d.value,f.el)<=q||Math.abs(ee-G)<16)){if(d.value&&r.value&&f.el){const{scrollWidth:ie,offsetWidth:Se}=f.el;ee=ie-Se-ee}d.value?y.horizontal(ee,w.value):y(ee,w.value)}}function P(ee){const{scrollTop:q,scrollLeft:G}=ee.target;l.value=d.value?G:q}function S(ee){if(C.value=!0,!(!a.value||!g.el)){for(const q of ee.composedPath())for(const G of g.el.children)if(G===q){_(G);return}}}function E(ee){C.value=!1}let I=!1;function O(ee){var q;!I&&!C.value&&!(ee.relatedTarget&&((q=g.el)!=null&&q.contains(ee.relatedTarget)))&&F(),I=!1}function R(){I=!0}function M(ee){if(!g.el)return;function q(G){ee.preventDefault(),F(G)}d.value?ee.key==="ArrowRight"?q(r.value?"prev":"next"):ee.key==="ArrowLeft"&&q(r.value?"next":"prev"):ee.key==="ArrowDown"?q("next"):ee.key==="ArrowUp"&&q("prev"),ee.key==="Home"?q("first"):ee.key==="End"&&q("last")}function D(ee,q){if(!ee)return;let G=ee;do G=G==null?void 0:G[q==="next"?"nextElementSibling":"previousElementSibling"];while(G!=null&&G.hasAttribute("disabled"));return G}function F(ee){if(!g.el)return;let q;if(!ee)q=qc(g.el)[0];else if(ee==="next"){if(q=D(g.el.querySelector(":focus"),ee),!q)return F("first")}else if(ee==="prev"){if(q=D(g.el.querySelector(":focus"),ee),!q)return F("last")}else ee==="first"?(q=g.el.firstElementChild,q!=null&&q.hasAttribute("disabled")&&(q=D(q,"next"))):ee==="last"&&(q=g.el.lastElementChild,q!=null&&q.hasAttribute("disabled")&&(q=D(q,"prev")));q&&q.focus({preventScroll:!0})}function U(ee){const q=d.value&&r.value?-1:1,G=(ee==="prev"?-q:q)*u.value;let le=l.value+G;if(d.value&&r.value&&f.el){const{scrollWidth:ie,offsetWidth:Se}=f.el;le+=ie-Se}T(le)}const K=A(()=>({next:o.next,prev:o.prev,select:o.select,isSelected:o.isSelected})),X=A(()=>{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)}}),H=A(()=>Math.abs(l.value)>1),B=A(()=>{if(!f.value)return!1;const ee=pk(d.value,f.el),q=jq(d.value,f.el);return ee-q-Math.abs(l.value)>1});return Oe(()=>h(e.tag,{class:["v-slide-group",{"v-slide-group--vertical":!d.value,"v-slide-group--has-affixes":X.value,"v-slide-group--is-overflowing":a.value},s.value,e.class],style:e.style,tabindex:C.value||o.selected.value.length?-1:0,onFocus:O},{default:()=>{var ee,q,G;return[X.value&&h("div",{key:"prev",class:["v-slide-group__prev",{"v-slide-group__prev--disabled":!H.value}],onMousedown:R,onClick:()=>H.value&&U("prev")},[((ee=n.prev)==null?void 0:ee.call(n,K.value))??h(p1,null,{default:()=>[h(J,{icon:r.value?e.nextIcon:e.prevIcon},null)]})]),h("div",{key:"container",ref:f,class:"v-slide-group__container",onScroll:P},[h("div",{ref:g,class:"v-slide-group__content",onFocusin:S,onFocusout:E,onKeydown:M},[(q=n.default)==null?void 0:q.call(n,K.value)])]),X.value&&h("div",{key:"next",class:["v-slide-group__next",{"v-slide-group__next--disabled":!B.value}],onMousedown:R,onClick:()=>B.value&&U("next")},[((G=n.next)==null?void 0:G.call(n,K.value))??h(p1,null,{default:()=>[h(J,{icon:r.value?e.prevIcon:e.nextIcon},null)]})])]}})),{selected:o.selected,scrollTo:U,scrollOffset:l,focus:F,hasPrev:H,hasNext:B}}}),LA=Symbol.for("vuetify:v-chip-group"),Wq=de({baseColor:String,column:Boolean,filter:Boolean,valueComparator:{type:Function,default:as},...DA(),...Ue(),...Ed({selectedClass:"v-chip--selected"}),...yt(),...Lt(),...$s({variant:"tonal"})},"VChipGroup"),op=ke()({name:"VChipGroup",props:Wq(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const{themeClasses:r}=Zt(e),{isSelected:s,select:i,next:o,prev:a,selected:l}=xu(e,LA);return Ir({VChip:{baseColor:ae(()=>e.baseColor),color:ae(()=>e.color),disabled:ae(()=>e.disabled),filter:ae(()=>e.filter),variant:ae(()=>e.variant)}}),Oe(()=>{const u=mk.filterProps(e);return h(mk,ge(u,{class:["v-chip-group",{"v-chip-group--column":e.column},r.value,e.class],style:e.style}),{default:()=>{var c;return[(c=n.default)==null?void 0:c.call(n,{isSelected:s,select:i,next:o,prev:a,selected:l.value})]}})}),{}}}),Gq=de({activeClass:String,appendAvatar:String,appendIcon:He,baseColor:String,closable:Boolean,closeIcon:{type:He,default:"$delete"},closeLabel:{type:String,default:"$vuetify.close"},draggable:Boolean,filter:Boolean,filterIcon:{type:He,default:"$complete"},label:Boolean,link:{type:Boolean,default:void 0},pill:Boolean,prependAvatar:String,prependIcon:He,ripple:{type:[Boolean,Object],default:!0},text:{type:[String,Number,Boolean],default:void 0},modelValue:{type:Boolean,default:!0},onClick:Bn(),onClickOnce:Bn(),...vs(),...Ue(),...Ar(),...bs(),...Cd(),...Dn(),...Xp(),...Eu(),...yt({tag:"span"}),...Lt(),...$s({variant:"tonal"})},"VChip"),_n=ke()({name:"VChip",directives:{Ripple:Pu},props:Gq(),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}=Gr(),{borderClasses:o}=Ds(e),{densityClasses:a}=ys(e),{elevationClasses:l}=Ls(e),{roundedClasses:u}=zn(e),{sizeClasses:c}=Pd(e),{themeClasses:d}=Zt(e),f=st(e,"modelValue"),p=Td(e,LA,!1),g=Yp(e,n),m=ae(()=>e.link!==!1&&g.isLink.value),y=A(()=>!e.disabled&&e.link!==!1&&(!!p||e.link||g.isClickable.value)),w=ae(()=>({"aria-label":i(e.closeLabel),onClick(P){P.preventDefault(),P.stopPropagation(),f.value=!1,r("click:close",P)}})),{colorClasses:b,colorStyles:k,variantClasses:C}=Za(()=>({color:!p||p.isSelected.value?e.color??e.baseColor:e.baseColor,variant:e.variant}));function _(P){var S;r("click",P),y.value&&((S=g.navigate)==null||S.call(g,P),p==null||p.toggle())}function T(P){(P.key==="Enter"||P.key===" ")&&(P.preventDefault(),_(P))}return()=>{var D;const P=g.isLink.value?"a":e.tag,S=!!(e.appendIcon||e.appendAvatar),E=!!(S||s.append),I=!!(s.close||e.closable),O=!!(s.filter||e.filter)&&p,R=!!(e.prependIcon||e.prependAvatar),M=!!(R||s.prepend);return f.value&&Bt(h(P,ge({class:["v-chip",{"v-chip--disabled":e.disabled,"v-chip--label":e.label,"v-chip--link":y.value,"v-chip--filter":O,"v-chip--pill":e.pill,[`${e.activeClass}`]:e.activeClass&&((D=g.isActive)==null?void 0:D.value)},d.value,o.value,b.value,a.value,l.value,u.value,c.value,C.value,p==null?void 0:p.selectedClass.value,e.class],style:[k.value,e.style],disabled:e.disabled||void 0,draggable:e.draggable,tabindex:y.value?0:void 0,onClick:_,onKeydown:y.value&&!m.value&&T},g.linkProps),{default:()=>{var F;return[Ho(y.value,"v-chip"),O&&h(wP,{key:"filter"},{default:()=>[Bt(h("div",{class:"v-chip__filter"},[s.filter?h(Ot,{key:"filter-defaults",disabled:!e.filterIcon,defaults:{VIcon:{icon:e.filterIcon}}},s.filter):h(J,{key:"filter-icon",icon:e.filterIcon},null)]),[[Yi,p.isSelected.value]])]}),M&&h("div",{key:"prepend",class:"v-chip__prepend"},[s.prepend?h(Ot,{key:"prepend-defaults",disabled:!R,defaults:{VAvatar:{image:e.prependAvatar,start:!0},VIcon:{icon:e.prependIcon,start:!0}}},s.prepend):h(Ae,null,[e.prependIcon&&h(J,{key:"prepend-icon",icon:e.prependIcon,start:!0},null),e.prependAvatar&&h(ut,{key:"prepend-avatar",image:e.prependAvatar,start:!0},null)])]),h("div",{class:"v-chip__content","data-no-activator":""},[((F=s.default)==null?void 0:F.call(s,{isSelected:p==null?void 0:p.isSelected.value,selectedClass:p==null?void 0:p.selectedClass.value,select:p==null?void 0:p.select,toggle:p==null?void 0:p.toggle,value:p==null?void 0:p.value.value,disabled:e.disabled}))??re(e.text)]),E&&h("div",{key:"append",class:"v-chip__append"},[s.append?h(Ot,{key:"append-defaults",disabled:!S,defaults:{VAvatar:{end:!0,image:e.appendAvatar},VIcon:{end:!0,icon:e.appendIcon}}},s.append):h(Ae,null,[e.appendIcon&&h(J,{key:"append-icon",end:!0,icon:e.appendIcon},null),e.appendAvatar&&h(ut,{key:"append-avatar",end:!0,image:e.appendAvatar},null)])]),I&&h("button",ge({key:"close",class:"v-chip__close",type:"button","data-testid":"close-chip"},w.value),[s.close?h(Ot,{key:"close-defaults",defaults:{VIcon:{icon:e.closeIcon,size:"x-small"}}},s.close):h(J,{key:"close-icon",icon:e.closeIcon,size:"x-small"},null)])]}}),[[hr("ripple"),y.value&&e.ripple,null]])}}}),Kq=de({fluid:{type:Boolean,default:!1},...Ue(),...Or(),...yt()},"VContainer"),Un=ke()({name:"VContainer",props:Kq(),setup(e,t){let{slots:n}=t;const{rtlClasses:r}=Dr(),{dimensionStyles:s}=Mr(e);return Oe(()=>h(e.tag,{class:["v-container",{"v-container--fluid":e.fluid},r.value,e.class],style:[s.value,e.style]},n)),{}}}),$A=Qp.reduce((e,t)=>(e[t]={type:[Boolean,String,Number],default:!1},e),{}),FA=Qp.reduce((e,t)=>{const n="offset"+ci(t);return e[n]={type:[String,Number],default:null},e},{}),NA=Qp.reduce((e,t)=>{const n="order"+ci(t);return e[n]={type:[String,Number],default:null},e},{}),gk={col:Object.keys($A),offset:Object.keys(FA),order:Object.keys(NA)};function Yq(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 Xq=["auto","start","end","center","baseline","stretch"],Qq=de({cols:{type:[Boolean,String,Number],default:!1},...$A,offset:{type:[String,Number],default:null},...FA,order:{type:[String,Number],default:null},...NA,alignSelf:{type:String,default:null,validator:e=>Xq.includes(e)},...Ue(),...yt()},"VCol"),ze=ke()({name:"VCol",props:Qq(),setup(e,t){let{slots:n}=t;const r=A(()=>{const s=[];let i;for(i in gk)gk[i].forEach(a=>{const l=e[a],u=Yq(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 pr(e.tag,{class:[r.value,e.class],style:e.style},(s=n.default)==null?void 0:s.call(n))}}}),j0=["start","end","center"],BA=["space-between","space-around","space-evenly"];function q0(e,t){return Qp.reduce((n,r)=>{const s=e+ci(r);return n[s]=t(),n},{})}const Jq=[...j0,"baseline","stretch"],VA=e=>Jq.includes(e),UA=q0("align",()=>({type:String,default:null,validator:VA})),Zq=[...j0,...BA],zA=e=>Zq.includes(e),HA=q0("justify",()=>({type:String,default:null,validator:zA})),eW=[...j0,...BA,"stretch"],jA=e=>eW.includes(e),qA=q0("alignContent",()=>({type:String,default:null,validator:jA})),vk={align:Object.keys(UA),justify:Object.keys(HA),alignContent:Object.keys(qA)},tW={align:"align",justify:"justify",alignContent:"align-content"};function nW(e,t,n){let r=tW[e];if(n!=null){if(t){const s=t.replace(e,"");r+=`-${s}`}return r+=`-${n}`,r.toLowerCase()}}const rW=de({dense:Boolean,noGutters:Boolean,align:{type:String,default:null,validator:VA},...UA,justify:{type:String,default:null,validator:zA},...HA,alignContent:{type:String,default:null,validator:jA},...qA,...Ue(),...yt()},"VRow"),rt=ke()({name:"VRow",props:rW(),setup(e,t){let{slots:n}=t;const r=A(()=>{const s=[];let i;for(i in vk)vk[i].forEach(o=>{const a=e[o],l=nW(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 pr(e.tag,{class:["v-row",r.value,e.class],style:e.style},(s=n.default)==null?void 0:s.call(n))}}}),Sn=ku("v-spacer","div","VSpacer"),sW=Le({__name:"PrinterControlDialog",setup(e){const t=tn(nn.PrinterControlDialog),n=Ft(),r=nr(),s=A(()=>{var d;return(d=t.context())==null?void 0:d.printerId}),i=A(()=>{if(s.value)return n.printer(s.value)}),o=j(10),a=A(()=>{var f,p,g,m,y,w,b,k,C,_;const d=r.printerEventsById[s.value];return(g=(p=(f=d==null?void 0:d.current)==null?void 0:f.payload)==null?void 0:p.temps)!=null&&g.length&&((b=(w=(y=(m=d==null?void 0:d.current)==null?void 0:m.payload)==null?void 0:y.temps[0])==null?void 0:w.tool0)!=null&&b.actual)?(_=(C=(k=d==null?void 0:d.current)==null?void 0:k.payload)==null?void 0:C.temps[0])==null?void 0:_.tool0:null}),l=async(d,f,p)=>{await Qt.sendPrinterJogCommand(s.value,{x:d*o.value,y:f*o.value,z:p*o.value})},u=async d=>{await Qt.sendPrinterHomeCommand(s.value,d)},c=()=>{t.closeDialog()};return(d,f)=>{const p=hi;return $(),te(p,{id:Q(t).dialogId,"max-width":"700px",onEscape:f[14]||(f[14]=g=>c())},{default:v(()=>[h(vt,null,{default:v(()=>[h(sn,null,{default:v(()=>f[15]||(f[15]=[x(" Printer Controls ")])),_:1}),h(en,null,{default:v(()=>[i.value?($(),te(Un,{key:0},{default:v(()=>[h(rt,null,{default:v(()=>[h(ze,{cols:12},{default:v(()=>{var g;return[x(" Printer: "+re((g=i.value)==null?void 0:g.name)+" ",1),f[16]||(f[16]=L("br",null,null,-1)),h(_n,{color:"primary"},{default:v(()=>{var m,y;return[x(re((m=a.value)==null?void 0:m.actual)+"C / "+re((y=a.value)==null?void 0:y.target)+"C ",1)]}),_:1})]}),_:1})]),_:1}),h(rt,null,{default:v(()=>[h(ze,{cols:8},{default:v(()=>[f[26]||(f[26]=x(" X/Y ")),f[27]||(f[27]=L("br",null,null,-1)),h(se,{class:"bg-primary",variant:"outlined",size:"x-large",onClick:f[0]||(f[0]=g=>l(-1,1,0))},{default:v(()=>[h(J,null,{default:v(()=>f[17]||(f[17]=[x("north_west")])),_:1})]),_:1}),h(se,{class:"bg-primary",variant:"outlined",size:"x-large",onClick:f[1]||(f[1]=g=>l(0,1,0))},{default:v(()=>[h(J,null,{default:v(()=>f[18]||(f[18]=[x("north")])),_:1})]),_:1}),h(se,{class:"bg-primary",variant:"outlined",size:"x-large",onClick:f[2]||(f[2]=g=>l(1,1,0))},{default:v(()=>[h(J,null,{default:v(()=>f[19]||(f[19]=[x("north_east")])),_:1})]),_:1}),f[28]||(f[28]=L("br",null,null,-1)),h(se,{class:"bg-primary",variant:"outlined",size:"x-large",onClick:f[3]||(f[3]=g=>l(-1,0,0))},{default:v(()=>[h(J,null,{default:v(()=>f[20]||(f[20]=[x("west")])),_:1})]),_:1}),h(se,{class:"bg-primary",variant:"outlined",size:"x-large",onClick:f[4]||(f[4]=g=>u(["x","y"]))},{default:v(()=>[h(J,null,{default:v(()=>f[21]||(f[21]=[x("home")])),_:1})]),_:1}),h(se,{class:"bg-primary",variant:"outlined",size:"x-large",onClick:f[5]||(f[5]=g=>l(1,0,0))},{default:v(()=>[h(J,null,{default:v(()=>f[22]||(f[22]=[x("east")])),_:1})]),_:1}),f[29]||(f[29]=L("br",null,null,-1)),h(se,{class:"bg-primary",variant:"outlined",size:"x-large",onClick:f[6]||(f[6]=g=>l(-1,-1,0))},{default:v(()=>[h(J,null,{default:v(()=>f[23]||(f[23]=[x("south_west")])),_:1})]),_:1}),h(se,{class:"bg-primary",variant:"outlined",size:"x-large",onClick:f[7]||(f[7]=g=>l(0,-1,0))},{default:v(()=>[h(J,null,{default:v(()=>f[24]||(f[24]=[x("south")])),_:1})]),_:1}),h(se,{class:"bg-primary",variant:"outlined",size:"x-large",onClick:f[8]||(f[8]=g=>l(1,-1,0))},{default:v(()=>[h(J,null,{default:v(()=>f[25]||(f[25]=[x("south_east")])),_:1})]),_:1})]),_:1}),h(ze,{cols:"4"},{default:v(()=>[f[33]||(f[33]=x(" Z ")),f[34]||(f[34]=L("br",null,null,-1)),h(se,{class:"bg-primary",variant:"outlined",size:"x-large",onClick:f[9]||(f[9]=g=>l(0,0,1))},{default:v(()=>[h(J,null,{default:v(()=>f[30]||(f[30]=[x("north")])),_:1})]),_:1}),f[35]||(f[35]=L("br",null,null,-1)),h(se,{class:"bg-primary",variant:"outlined",size:"x-large",onClick:f[10]||(f[10]=g=>u(["z"]))},{default:v(()=>[h(J,null,{default:v(()=>f[31]||(f[31]=[x("home")])),_:1})]),_:1}),f[36]||(f[36]=L("br",null,null,-1)),h(se,{class:"bg-primary",variant:"outlined",size:"x-large",onClick:f[11]||(f[11]=g=>l(1,0,1))},{default:v(()=>[h(J,null,{default:v(()=>f[32]||(f[32]=[x("south")])),_:1})]),_:1})]),_:1})]),_:1}),h(rt,null,{default:v(()=>[h(ze,{cols:"12"},{default:v(()=>[h(ZT,{modelValue:o.value,"onUpdate:modelValue":f[12]||(f[12]=g=>o.value=g)},{default:v(()=>[h(se,{value:.1},{default:v(()=>f[37]||(f[37]=[x(" 0.1 ")])),_:1}),h(se,{value:1},{default:v(()=>f[38]||(f[38]=[x(" 1 ")])),_:1}),h(se,{value:10},{default:v(()=>f[39]||(f[39]=[x(" 10 ")])),_:1}),h(se,{value:100},{default:v(()=>f[40]||(f[40]=[x(" 100 ")])),_:1})]),_:1},8,["modelValue"])]),_:1})]),_:1})]),_:1})):pe("",!0)]),_:1}),h(Mn,null,{default:v(()=>[h(Sn),h(se,{variant:"text",onClick:f[13]||(f[13]=g=>c())},{default:v(()=>f[41]||(f[41]=[x(" Close ")])),_:1})]),_:1})]),_:1})]),_:1},8,["id"])}}});class Ol extends gr{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=Me.batchGetLastPrintedFilesRoute;return await this.post(n,{printerIds:t})}static async batchReprintFiles(t){const n=Me.batchReprintFilesRoute;return await this.post(n,{prints:t})}}var aa=(e=>(e[e.PrinterNotAvailable=0]="PrinterNotAvailable",e[e.NoLastPrint=1]="NoLastPrint",e[e.LastPrintReady=2]="LastPrintReady",e))(aa||{});function iW(e){return e.message?`${e.message}
|
|
62
|
+
${e.stack}`:`'${e}'`}const oW=ku("v-alert-title"),aW=["success","info","warning","error"],lW=de({border:{type:[Boolean,String],validator:e=>typeof e=="boolean"||["top","end","bottom","start"].includes(e)},borderColor:String,closable:Boolean,closeIcon:{type:He,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=>aW.includes(e)},...Ue(),...Ar(),...Or(),...bs(),...jo(),...Cu(),...Dn(),...yt(),...Lt(),...$s({variant:"flat"})},"VAlert"),fn=ke()({name:"VAlert",props:lW(),emits:{"click:close":e=>!0,"update:modelValue":e=>!0},setup(e,t){let{emit:n,slots:r}=t;const s=st(e,"modelValue"),i=ae(()=>{if(e.icon!==!1)return e.type?e.icon??`$${e.type}`:e.icon}),{themeClasses:o}=Zt(e),{colorClasses:a,colorStyles:l,variantClasses:u}=Za(()=>({color:e.color??e.type,variant:e.variant})),{densityClasses:c}=ys(e),{dimensionStyles:d}=Mr(e),{elevationClasses:f}=Ls(e),{locationStyles:p}=el(e),{positionClasses:g}=Tu(e),{roundedClasses:m}=zn(e),{textColorClasses:y,textColorStyles:w}=As(()=>e.borderColor),{t:b}=Gr(),k=ae(()=>({"aria-label":b(e.closeLabel),onClick(C){s.value=!1,n("click:close",C)}}));return()=>{const C=!!(r.prepend||i.value),_=!!(r.title||e.title),T=!!(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},o.value,a.value,c.value,f.value,g.value,m.value,u.value,e.class],style:[l.value,d.value,p.value,e.style],role:"alert"},{default:()=>{var P,S;return[Ho(!1,"v-alert"),e.border&&h("div",{key:"border",class:["v-alert__border",y.value],style:w.value},null),C&&h("div",{key:"prepend",class:"v-alert__prepend"},[r.prepend?h(Ot,{key:"prepend-defaults",disabled:!i.value,defaults:{VIcon:{density:e.density,icon:i.value,size:e.prominent?44:28}}},r.prepend):h(J,{key:"prepend-icon",density:e.density,icon:i.value,size:e.prominent?44:28},null)]),h("div",{class:"v-alert__content"},[_&&h(oW,{key:"title"},{default:()=>{var E;return[((E=r.title)==null?void 0:E.call(r))??e.title]}}),((P=r.text)==null?void 0:P.call(r))??e.text,(S=r.default)==null?void 0:S.call(r)]),r.append&&h("div",{key:"append",class:"v-alert__append"},[r.append()]),T&&h("div",{key:"close",class:"v-alert__close"},[r.close?h(Ot,{key:"close-defaults",defaults:{VBtn:{icon:e.closeIcon,size:"x-small",variant:"text"}}},{default:()=>{var E;return[(E=r.close)==null?void 0:E.call(r,{props:k.value})]}}):h(se,ge({key:"close-btn",icon:e.closeIcon,size:"x-small",variant:"text"},k.value),null)])]}})}}}),My=Symbol.for("vuetify:list");function WA(){const e=Qe(My,{hasPrepend:Ie(!1),updateHasPrepend:()=>null}),t={hasPrepend:Ie(!1),updateHasPrepend:n=>{n&&(t.hasPrepend.value=n)}};return Kt(My,t),e}function GA(){return Qe(My,null)}const W0=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 An(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},KA=e=>{const t=W0(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=An(r);a.length&&(o=t.in(a.slice(0,1),s,i))}return o},out:(r,s,i)=>t.out(r,s,i)}},uW=e=>{const t=W0(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}},cW=e=>{const t=KA(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}},dW={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},YA={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},fW={open:YA.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)}},G0=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,c]=l;return c==="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)=>{const i=new Map;for(const o of n||[])t.select({id:o,value:!0,selected: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},XA=e=>{const t=G0(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)=>r!=null&&r.length?t.in(r.slice(0,1),s,i):new Map,out:(r,s,i)=>t.out(r,s,i)}},hW=e=>{const t=G0(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}},pW=e=>{const t=XA(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}},QA=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 d=u.shift();i.set(Be(d),s?"on":"off"),o.has(d)&&u.push(...o.get(d))}let c=Be(a.get(r));for(;c;){const d=o.get(c),f=d.every(g=>i.get(Be(g))==="on"),p=d.every(g=>!i.has(Be(g))||i.get(Be(g))==="off");i.set(c,f?"on":p?"off":"indeterminate"),c=Be(a.get(c))}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: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},mW=e=>{const t=QA(e);return{select:t.select,in:t.in,out:(r,s,i)=>{const o=[];for(const[a,l]of r.entries())if(l==="on"){if(i.has(a)){const u=i.get(a);if(r.get(u)==="on")continue}o.push(a)}return o}}},od=Symbol.for("vuetify:nested"),JA={id:Ie(),root:{register:()=>null,unregister:()=>null,parents:j(new Map),children:j(new Map),open:()=>null,openOnSelect:()=>null,activate:()=>null,select:()=>null,activatable:j(!1),selectable:j(!1),opened:j(new Set),activated:j(new Set),selected:j(new Map),selectedValues:j([]),getPath:()=>[]}},gW=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"),vW=e=>{let t=!1;const n=j(new Map),r=j(new Map),s=st(e,"opened",e.opened,g=>new Set(g),g=>[...g.values()]),i=A(()=>{if(typeof e.activeStrategy=="object")return e.activeStrategy;if(typeof e.activeStrategy=="function")return e.activeStrategy(e.mandatory);switch(e.activeStrategy){case"leaf":return uW(e.mandatory);case"single-leaf":return cW(e.mandatory);case"independent":return W0(e.mandatory);case"single-independent":default:return KA(e.mandatory)}}),o=A(()=>{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 pW(e.mandatory);case"leaf":return hW(e.mandatory);case"independent":return G0(e.mandatory);case"single-independent":return XA(e.mandatory);case"trunk":return mW(e.mandatory);case"classic":default:return QA(e.mandatory)}}),a=A(()=>{if(typeof e.openStrategy=="object")return e.openStrategy;switch(e.openStrategy){case"list":return fW;case"single":return dW;case"multiple":default:return YA}}),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));Cn(()=>{t=!0});function c(g){const m=[];let y=g;for(;y!=null;)m.unshift(y),y=r.value.get(y);return m}const d=an("nested"),f=new Set,p={id:Ie(),root:{opened:s,activatable:ae(()=>e.activatable),selectable:ae(()=>e.selectable),activated:l,selected:u,selectedValues:A(()=>{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)){c(g).map(String).join(" -> "),c(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(w=>w!==g))}r.value.delete(g)},open:(g,m,y)=>{d.emit("click:open",{id:g,value:m,path:c(g),event:y});const w=a.value.open({id:g,value:m,opened:new Set(s.value),children:n.value,parents:r.value,event:y});w&&(s.value=w)},openOnSelect:(g,m,y)=>{const w=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});w&&(s.value=w)},select:(g,m,y)=>{d.emit("click:select",{id:g,value:m,path:c(g),event:y});const w=o.value.select({id:g,value:m,selected:new Map(u.value),children:n.value,parents:r.value,event:y});w&&(u.value=w),p.root.openOnSelect(g,m,y)},activate:(g,m,y)=>{if(!e.activatable)return p.root.select(g,!0,y);d.emit("click:activate",{id:g,value:m,path:c(g),event:y});const w=i.value.activate({id:g,value:m,activated:new Set(l.value),children:n.value,parents:r.value,event:y});if(w.size!==l.value.size)l.value=w;else{for(const b of w)if(!l.value.has(b)){l.value=w;return}for(const b of l.value)if(!w.has(b)){l.value=w;return}}},children:n,parents:r,getPath:c}};return Kt(od,p),p.root},ZA=(e,t)=>{const n=Qe(od,JA),r=Symbol("nested item"),s=A(()=>Nn(e)??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:A(()=>n.root.opened.value.has(s.value)),parent:A(()=>n.root.parents.value.get(s.value)),activate:(o,a)=>n.root.activate(s.value,o,a),isActivated:A(()=>n.root.activated.value.has(Be(s.value))),select:(o,a)=>n.root.select(s.value,o,a),isSelected:A(()=>n.root.selected.value.get(Be(s.value))==="on"),isIndeterminate:A(()=>n.root.selected.value.get(Be(s.value))==="indeterminate"),isLeaf:A(()=>!n.root.children.value.get(s.value)),isGroupActivator:n.isGroupActivator};return Su(()=>{!n.isGroupActivator&&n.root.register(s.value,n.id.value,t)}),Cn(()=>{!n.isGroupActivator&&n.root.unregister(s.value)}),t&&Kt(od,i),i},yW=()=>{const e=Qe(od,JA);Kt(od,{...e,isGroupActivator:!0})};function jd(){const e=Ie(!1);return St(()=>{window.requestAnimationFrame(()=>{e.value=!0})}),{ssrBootStyles:ae(()=>e.value?void 0:{transition:"none !important"}),isBooted:zo(e)}}const bW=_u({name:"VListGroupActivator",setup(e,t){let{slots:n}=t;return yW(),()=>{var r;return(r=n.default)==null?void 0:r.call(n)}}}),wW=de({activeColor:String,baseColor:String,color:String,collapseIcon:{type:He,default:"$collapse"},expandIcon:{type:He,default:"$expand"},prependIcon:He,appendIcon:He,fluid:Boolean,subgroup:Boolean,title:String,value:null,...Ue(),...yt()},"VListGroup"),Dy=ke()({name:"VListGroup",props:wW(),setup(e,t){let{slots:n}=t;const{isOpen:r,open:s,id:i}=ZA(()=>e.value,!0),o=A(()=>`v-list-group--id-${String(i.value)}`),a=GA(),{isBooted:l}=jd();function u(p){var g;p.stopPropagation(),!["INPUT","TEXTAREA"].includes((g=p.target)==null?void 0:g.tagName)&&s(!r.value,p)}const c=A(()=>({onClick:u,class:"v-list-group__header",id:o.value})),d=A(()=>r.value?e.collapseIcon:e.expandIcon),f=A(()=>({VListItem:{active:r.value,activeColor:e.activeColor,baseColor:e.baseColor,color:e.color,prependIcon:e.prependIcon||e.subgroup&&d.value,appendIcon:e.appendIcon||!e.subgroup&&d.value,title:e.title,value:e.value}}));return Oe(()=>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(Ot,{defaults:f.value},{default:()=>[h(bW,null,{default:()=>[n.activator({props:c.value,isOpen:r.value})]})]}),h(si,{transition:{component:bP},disabled:!l.value},{default:()=>{var p;return[Bt(h("div",{class:"v-list-group__items",role:"group","aria-labelledby":o.value},[(p=n.default)==null?void 0:p.call(n)]),[[Yi,r.value]])]}})]})),{isOpen:r}}}),SW=de({opacity:[Number,String],...Ue(),...yt()},"VListItemSubtitle"),bt=ke()({name:"VListItemSubtitle",props:SW(),setup(e,t){let{slots:n}=t;return Oe(()=>h(e.tag,{class:["v-list-item-subtitle",e.class],style:[{"--v-list-item-subtitle-opacity":e.opacity},e.style]},n)),{}}}),ft=ku("v-list-item-title"),_W=de({active:{type:Boolean,default:void 0},activeClass:String,activeColor:String,appendAvatar:String,appendIcon:He,baseColor:String,disabled:Boolean,lines:[Boolean,String],link:{type:Boolean,default:void 0},nav:Boolean,prependAvatar:String,prependIcon:He,ripple:{type:[Boolean,Object],default:!0},slim:Boolean,subtitle:{type:[String,Number,Boolean],default:void 0},title:{type:[String,Number,Boolean],default:void 0},value:null,onClick:Bn(),onClickOnce:Bn(),...vs(),...Ue(),...Ar(),...Or(),...bs(),...Dn(),...Xp(),...yt(),...Lt(),...$s({variant:"text"})},"VListItem"),Ve=ke()({name:"VListItem",directives:{Ripple:Pu},props:_W(),emits:{click:e=>!0},setup(e,t){let{attrs:n,slots:r,emit:s}=t;const i=Yp(e,n),o=A(()=>e.value===void 0?i.href.value:e.value),{activate:a,isActivated:l,select:u,isOpen:c,isSelected:d,isIndeterminate:f,isGroupActivator:p,root:g,parent:m,openOnSelect:y,id:w}=ZA(o,!1),b=GA(),k=A(()=>{var le;return e.active!==!1&&(e.active||((le=i.isActive)==null?void 0:le.value)||(g.activatable.value?l.value:d.value))}),C=ae(()=>e.link!==!1&&i.isLink.value),_=A(()=>!!b&&(g.selectable.value||g.activatable.value||e.value!=null)),T=A(()=>!e.disabled&&e.link!==!1&&(e.link||i.isClickable.value||_.value)),P=ae(()=>e.rounded||e.nav),S=ae(()=>e.color??e.activeColor),E=ae(()=>({color:k.value?S.value??e.baseColor:e.baseColor,variant:e.variant}));Ee(()=>{var le;return(le=i.isActive)==null?void 0:le.value},le=>{le&&I()}),Su(()=>{var le;(le=i.isActive)!=null&&le.value&&I()});function I(){m.value!=null&&g.open(m.value,!0),y(!0)}const{themeClasses:O}=Zt(e),{borderClasses:R}=Ds(e),{colorClasses:M,colorStyles:D,variantClasses:F}=Za(E),{densityClasses:U}=ys(e),{dimensionStyles:K}=Mr(e),{elevationClasses:X}=Ls(e),{roundedClasses:H}=zn(P),B=ae(()=>e.lines?`v-list-item--${e.lines}-line`:void 0),ee=A(()=>({isActive:k.value,select:u,isOpen:c.value,isSelected:d.value,isIndeterminate:f.value}));function q(le){var ie,Se;s("click",le),!["INPUT","TEXTAREA"].includes((ie=le.target)==null?void 0:ie.tagName)&&T.value&&((Se=i.navigate)==null||Se.call(i,le),!p&&(g.activatable.value?a(!l.value,le):(g.selectable.value||e.value!=null)&&u(!d.value,le)))}function G(le){const ie=le.target;["INPUT","TEXTAREA"].includes(ie.tagName)||(le.key==="Enter"||le.key===" ")&&(le.preventDefault(),le.target.dispatchEvent(new MouseEvent("click",le)))}return Oe(()=>{const le=C.value?"a":e.tag,ie=r.title||e.title!=null,Se=r.subtitle||e.subtitle!=null,Z=!!(e.appendAvatar||e.appendIcon),he=!!(Z||r.append),ne=!!(e.prependAvatar||e.prependIcon),z=!!(ne||r.prepend);return b==null||b.updateHasPrepend(z),e.activeColor&&Z$("active-color",["color","base-color"]),Bt(h(le,ge({class:["v-list-item",{"v-list-item--active":k.value,"v-list-item--disabled":e.disabled,"v-list-item--link":T.value,"v-list-item--nav":e.nav,"v-list-item--prepend":!z&&(b==null?void 0:b.hasPrepend.value),"v-list-item--slim":e.slim,[`${e.activeClass}`]:e.activeClass&&k.value},O.value,R.value,M.value,U.value,X.value,B.value,H.value,F.value,e.class],style:[D.value,K.value,e.style],tabindex:T.value?b?-2:0:void 0,"aria-selected":_.value?g.activatable.value?l.value:g.selectable.value?d.value:k.value:void 0,onClick:q,onKeydown:T.value&&!C.value&&G},i.linkProps),{default:()=>{var xe;return[Ho(T.value||k.value,"v-list-item"),z&&h("div",{key:"prepend",class:"v-list-item__prepend"},[r.prepend?h(Ot,{key:"prepend-defaults",disabled:!ne,defaults:{VAvatar:{density:e.density,image:e.prependAvatar},VIcon:{density:e.density,icon:e.prependIcon},VListItemAction:{start:!0}}},{default:()=>{var Fe;return[(Fe=r.prepend)==null?void 0:Fe.call(r,ee.value)]}}):h(Ae,null,[e.prependAvatar&&h(ut,{key:"prepend-avatar",density:e.density,image:e.prependAvatar},null),e.prependIcon&&h(J,{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":""},[ie&&h(ft,{key:"title"},{default:()=>{var Fe;return[((Fe=r.title)==null?void 0:Fe.call(r,{title:e.title}))??re(e.title)]}}),Se&&h(bt,{key:"subtitle"},{default:()=>{var Fe;return[((Fe=r.subtitle)==null?void 0:Fe.call(r,{subtitle:e.subtitle}))??re(e.subtitle)]}}),(xe=r.default)==null?void 0:xe.call(r,ee.value)]),he&&h("div",{key:"append",class:"v-list-item__append"},[r.append?h(Ot,{key:"append-defaults",disabled:!Z,defaults:{VAvatar:{density:e.density,image:e.appendAvatar},VIcon:{density:e.density,icon:e.appendIcon},VListItemAction:{end:!0}}},{default:()=>{var Fe;return[(Fe=r.append)==null?void 0:Fe.call(r,ee.value)]}}):h(Ae,null,[e.appendIcon&&h(J,{key:"append-icon",density:e.density,icon:e.appendIcon},null),e.appendAvatar&&h(ut,{key:"append-avatar",density:e.density,image:e.appendAvatar},null)]),h("div",{class:"v-list-item__spacer"},null)])]}}),[[hr("ripple"),T.value&&e.ripple]])}),{activate:a,isActivated:l,isGroupActivator:p,isSelected:d,list:b,select:u,root:g,id:w,link:i}}}),kW=de({color:String,inset:Boolean,sticky:Boolean,title:String,...Ue(),...yt()},"VListSubheader"),qr=ke()({name:"VListSubheader",props:kW(),setup(e,t){let{slots:n}=t;const{textColorClasses:r,textColorStyles:s}=As(()=>e.color);return Oe(()=>{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])]}})}),{}}}),xW=de({color:String,inset:Boolean,length:[Number,String],opacity:[Number,String],thickness:[Number,String],vertical:Boolean,...Ue(),...Lt()},"VDivider"),dn=ke()({name:"VDivider",props:xW(),setup(e,t){let{attrs:n,slots:r}=t;const{themeClasses:s}=Zt(e),{textColorClasses:i,textColorStyles:o}=As(()=>e.color),a=A(()=>{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 Oe(()=>{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}),{}}}),EW=de({items:Array,returnObject:Boolean},"VListChildren"),eO=ke()({name:"VListChildren",props:EW(),setup(e,t){let{slots:n}=t;return WA(),()=>{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(dn,a,null);if(l==="subheader")return((p=n.subheader)==null?void 0:p.call(n,{props:a}))??h(qr,a,null);const c={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},d=Dy.filterProps(a);return o?h(Dy,ge({value:a==null?void 0:a.value},d),{activator:g=>{let{props:m}=g;const y={...a,...m,value:e.returnObject?u:a.value};return n.header?n.header({props:y}):h(Ve,y,c)},default:()=>h(eO,{items:o,returnObject:e.returnObject},n)}):n.item?n.item({props:a}):h(Ve,ge(a,{value:e.returnObject?u:a.value}),c)}))}}}),tO=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:Function},"list-items");function Ly(e,t){const n=Fn(t,e.itemTitle,t),r=Fn(t,e.itemValue,n),s=Fn(t,e.itemChildren),i=e.itemProps===!0?typeof t=="object"&&t!=null&&!Array.isArray(t)?"children"in t?Ms(t,["children"]):t:void 0:Fn(t,e.itemProps),o={title:n,value:r,...i};return{title:String(o.title??""),value:o.value,props:o,children:Array.isArray(s)?nO(e,s):void 0,raw:t}}function nO(e,t){const n=xd(e,["itemTitle","itemValue","itemChildren","itemProps","returnObject","valueComparator"]),r=[];for(const s of t)r.push(Ly(n,s));return r}function CW(e){const t=A(()=>nO(e,e.items)),n=A(()=>t.value.some(a=>a.value===null)),r=Ie(new Map),s=Ie([]);On(()=>{const a=t.value,l=new Map,u=[];for(let c=0;c<a.length;c++){const d=a[c];if(BT(d.value)||d.value===null){let f=l.get(d.value);f||(f=[],l.set(d.value,f)),f.push(d)}else u.push(d)}r.value=l,s.value=u});function i(a){const l=r.value,u=t.value,c=s.value,d=n.value,f=e.returnObject,p=!!e.valueComparator,g=e.valueComparator||as,m=xd(e,["itemTitle","itemValue","itemChildren","itemProps","returnObject","valueComparator"]),y=[];e:for(const w of a){if(!d&&w===null)continue;if(f&&typeof w=="string"){y.push(Ly(m,w));continue}const b=l.get(w);if(p||!b){for(const k of p?u:c)if(g(w,k.value)){y.push(k);continue e}y.push(Ly(m,w));continue}y.push(...b)}return y}function o(a){return e.returnObject?a.map(l=>{let{raw:u}=l;return u}):a.map(l=>{let{value:u}=l;return u})}return{items:t,transformIn:i,transformOut:o}}function TW(e,t){const n=Fn(t,e.itemType,"item"),r=BT(t)?t:Fn(t,e.itemTitle),s=Fn(t,e.itemValue,void 0),i=Fn(t,e.itemChildren),o=e.itemProps===!0?Ms(t,["children"]):Fn(t,e.itemProps),a={title:r,value:s,...o};return{type:n,title:a.title,value:a.value,props:a,children:n==="item"&&i?rO(e,i):void 0,raw:t}}function rO(e,t){const n=[];for(const r of t)n.push(TW(e,r));return n}function PW(e){return{items:A(()=>rO(e,e.items))}}const RW=de({baseColor:String,activeColor:String,activeClass:String,bgColor:String,disabled:Boolean,expandIcon:He,collapseIcon:He,lines:{type:[Boolean,String],default:"one"},slim:Boolean,nav:Boolean,"onClick:open":Bn(),"onClick:select":Bn(),"onUpdate:opened":Bn(),...gW({selectStrategy:"single-leaf",openStrategy:"list"}),...vs(),...Ue(),...Ar(),...Or(),...bs(),itemType:{type:String,default:"type"},...tO(),...Dn(),...yt(),...Lt(),...$s({variant:"text"})},"VList"),Ut=ke()({name:"VList",props:RW(),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}=PW(e),{themeClasses:s}=Zt(e),{backgroundColorClasses:i,backgroundColorStyles:o}=fr(()=>e.bgColor),{borderClasses:a}=Ds(e),{densityClasses:l}=ys(e),{dimensionStyles:u}=Mr(e),{elevationClasses:c}=Ls(e),{roundedClasses:d}=zn(e),{children:f,open:p,parents:g,select:m,getPath:y}=vW(e),w=ae(()=>e.lines?`v-list--${e.lines}-line`:void 0),b=ae(()=>e.activeColor),k=ae(()=>e.baseColor),C=ae(()=>e.color);WA(),Ir({VListGroup:{activeColor:b,baseColor:k,color:C,expandIcon:ae(()=>e.expandIcon),collapseIcon:ae(()=>e.collapseIcon)},VListItem:{activeClass:ae(()=>e.activeClass),activeColor:b,baseColor:k,color:C,density:ae(()=>e.density),disabled:ae(()=>e.disabled),lines:ae(()=>e.lines),nav:ae(()=>e.nav),slim:ae(()=>e.slim),variant:ae(()=>e.variant)}});const _=Ie(!1),T=j();function P(M){_.value=!0}function S(M){_.value=!1}function E(M){var D;!_.value&&!(M.relatedTarget&&((D=T.value)!=null&&D.contains(M.relatedTarget)))&&R()}function I(M){const D=M.target;if(!(!T.value||["INPUT","TEXTAREA"].includes(D.tagName))){if(M.key==="ArrowDown")R("next");else if(M.key==="ArrowUp")R("prev");else if(M.key==="Home")R("first");else if(M.key==="End")R("last");else return;M.preventDefault()}}function O(M){_.value=!0}function R(M){if(T.value)return Ec(T.value,M)}return Oe(()=>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,c.value,w.value,d.value,e.class],style:[o.value,u.value,e.style],tabindex:e.disabled?-1:0,role:"listbox","aria-activedescendant":void 0,onFocusin:P,onFocusout:S,onFocus:E,onKeydown:I,onMousedown:O},{default:()=>[h(eO,{items:r.value,returnObject:e.returnObject},n)]})),{open:p,select:m,focus:R,children:f,parents:g,getPath:y}}}),IW=de({start:Boolean,end:Boolean,...Ue(),...yt()},"VListItemAction"),pu=ke()({name:"VListItemAction",props:IW(),setup(e,t){let{slots:n}=t;return Oe(()=>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)),{}}}),AW=de({start:Boolean,end:Boolean,...Ue(),...yt()},"VListItemMedia"),OW=ke()({name:"VListItemMedia",props:AW(),setup(e,t){let{slots:n}=t;return Oe(()=>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)),{}}}),MW={key:1},DW={key:2},LW={class:"mt-3"},$W={key:0},FW={key:1},NW={key:2},BW=Le({__name:"BatchReprintDialog",setup(e){const t=Ft(),n=j(),r=tn(nn.BatchReprintDialog),s=j(!1),i=j(!1),o=j([]),a=j([]),l=j(""),u=Dt();function c(g){s.value=!0}async function d(g){n.value=g;try{const m=await Ol.batchGetLastPrintedFiles(n.value);o.value=m,a.value=m.filter(y=>y.connectionState==="Operational"&&y.reprintState==aa.LastPrintReady)}catch(m){l.value=m.code.toString()??""}s.value=!1}async function f(){i.value=!0;try{await Ol.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=iW(g)}finally{i.value=!1}}function p(){r.closeDialog(r.context())}return(g,m)=>{const y=hi;return $(),te(y,{id:Q(r).dialogId,"max-width":"1000px",onBeforeOpened:c,onEscape:m[3]||(m[3]=w=>p()),onOpened:d},{default:v(()=>[h(vt,{class:"pa-4"},{default:v(()=>[h(sn,null,{default:v(()=>m[4]||(m[4]=[L("span",{class:"text-h5"}," Batch - Submit Reprint Jobs ",-1)])),_:1}),h(en,null,{default:v(()=>{var w;return[(w=l.value)!=null&&w.length?($(),te(fn,{key:0,color:"error"},{default:v(()=>[x(re(l.value),1)]),_:1})):pe("",!0),s.value?($(),ve("span",MW," Loading... ")):($(),ve("div",DW,[h(Ut,{density:"compact"},{default:v(()=>[h(qr,null,{default:v(()=>m[5]||(m[5]=[x(" Reprinted Files - Select from list ")])),_:1}),h(Dy,{modelValue:a.value,"onUpdate:modelValue":m[0]||(m[0]=b=>a.value=b),multiple:""},{default:v(()=>[($(!0),ve(Ae,null,Gt(o.value,(b,k)=>($(),te(Ve,{key:k,value:b,disabled:b.connectionState!=="Operational"||b.reprintState!==Q(aa).LastPrintReady},{prepend:v(()=>[b.reprintState==Q(aa).LastPrintReady?($(),te(J,{key:0},{default:v(()=>m[6]||(m[6]=[x("checklist")])),_:1})):pe("",!0),b.reprintState==Q(aa).NoLastPrint?($(),te(J,{key:1},{default:v(()=>m[7]||(m[7]=[x(" question_mark ")])),_:1})):pe("",!0),b.reprintState==Q(aa).PrinterNotAvailable?($(),te(J,{key:2},{default:v(()=>m[8]||(m[8]=[x(" signal_disconnected ")])),_:1})):pe("",!0)]),default:v(()=>{var C,_;return[(_=(C=b.file)==null?void 0:C.path)!=null&&_.length?($(),te(ft,{key:0},{default:v(()=>{var T;return[x(re((T=b.file)==null?void 0:T.path)+" ",1),b.connectionState!=="Operational"?($(),te(_n,{key:0},{default:v(()=>m[9]||(m[9]=[x(" Printer busy ")])),_:1})):pe("",!0)]}),_:2},1024)):b.reprintState==Q(aa).NoLastPrint?($(),te(ft,{key:1},{default:v(()=>m[10]||(m[10]=[x(" No file is present to print again ")])),_:1})):($(),te(ft,{key:2},{default:v(()=>m[11]||(m[11]=[x(" OctoPrint cant be reached ")])),_:1})),h(bt,null,{default:v(()=>{var T;return[x(" Printer '"+re(((T=Q(t).printer(b.printerId))==null?void 0:T.name)??"Unknown printer")+"' ",1)]}),_:2},1024)]}),_:2},1032,["value","disabled"]))),128))]),_:1},8,["modelValue"])]),_:1})])),L("div",LW,[i.value?($(),ve("div",$W,[h(ni,{class:"ma-3",indeterminate:"",color:"blue"}),m[12]||(m[12]=x(" Submitting "))])):a.value.length>0?($(),ve("div",FW,re(a.value.length)+" reprint selected ",1)):($(),ve("div",NW,"Must select at least one file"))]),m[14]||(m[14]=L("br",null,null,-1)),h(se,{disabled:i.value||a.value.length===0,onClick:m[1]||(m[1]=b=>f())},{default:v(()=>m[13]||(m[13]=[x(" Submit Batch Reprint ")])),_:1},8,["disabled"])]}),_:1}),h(Mn,null,{default:v(()=>[h(Sn),h(se,{variant:"text",onClick:m[2]||(m[2]=w=>Q(r).closeDialog())},{default:v(()=>m[15]||(m[15]=[x(" Close ")])),_:1})]),_:1})]),_:1})]),_:1},8,["id"])}}});function sO(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]}const $y="/assets/octoprint-tentacle-D_4slObB.svg",ah=0,Fy=1,lh=2;function iO(e){return e===ah}function ap(e){return e===Fy}function lp(e){return e===lh}function Oc(e){return iO(e)?"OctoPrint":ap(e)?"Moonraker":lp(e)?"PrusaLink":"Unknown"}function VW(e){let{rootEl:t,isSticky:n,layoutItemStyles:r}=e;const s=Ie(!1),i=Ie(0),o=A(()=>{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(()=>{Ee(n,u=>{u?window.addEventListener("scroll",l,{passive:!0}):window.removeEventListener("scroll",l)},{immediate:!0})}),Cn(()=>{window.removeEventListener("scroll",l)});let a=0;function l(){const u=a>window.scrollY?"up":"down",c=t.value.getBoundingClientRect(),d=parseFloat(r.value.top??0),f=window.scrollY-Math.max(0,i.value-d),p=c.height+Math.max(i.value,d)-window.scrollY-window.innerHeight,g=parseFloat(getComputedStyle(t.value).getPropertyValue("--v-body-scroll-y"))||0;c.height<window.innerHeight-d?(s.value="top",i.value=d):u==="up"&&s.value==="bottom"||u==="down"&&s.value==="top"?(i.value=window.scrollY+c.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+d,s.value="top"):(i.value=c.top+f,s.value="top")),a=window.scrollY}return{isStuck:s,stickyStyles:o}}const UW=100,zW=20;function yk(e){return(e<0?-1:1)*Math.sqrt(Math.abs(e))*1.41421356237}function bk(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=yk(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 yk(t)*1e3}function HW(){const e={};function t(s){Array.from(s.changedTouches).forEach(i=>{(e[i.identifier]??(e[i.identifier]=new LT(zW))).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 c of i){if(o[0]-c[0]>UW)break;a.push({t:c[0],d:c[1].clientX}),l.push({t:c[0],d:c[1].clientY})}return{x:bk(a),y:bk(l),get direction(){const{x:c,y:d}=this,[f,p]=[Math.abs(c),Math.abs(d)];return f>p&&c>=0?"right":f>p&&c<=0?"left":p>f&&d>=0?"down":p>f&&d<=0?"up":jW()}}}return{addMovement:t,endTouch:n,getVelocity:r}}function jW(){throw new Error}function qW(e){let{el:t,isActive:n,isTemporary:r,width:s,touchless:i,position:o}=e;St(()=>{window.addEventListener("touchstart",b,{passive:!0}),window.addEventListener("touchmove",k,{passive:!1}),window.addEventListener("touchend",C,{passive:!0})}),Cn(()=>{window.removeEventListener("touchstart",b),window.removeEventListener("touchmove",k),window.removeEventListener("touchend",C)});const a=A(()=>["left","right"].includes(o.value)),{addMovement:l,endTouch:u,getVelocity:c}=HW();let d=!1;const f=Ie(!1),p=Ie(0),g=Ie(0);let m;function y(T,P){return(o.value==="left"?T:o.value==="right"?document.documentElement.clientWidth-T:o.value==="top"?T:o.value==="bottom"?document.documentElement.clientHeight-T:hl())-(P?s.value:0)}function w(T){let P=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;const S=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:hl();return P?Math.max(0,Math.min(1,S)):S}function b(T){if(i.value)return;const P=T.changedTouches[0].clientX,S=T.changedTouches[0].clientY,E=25,I=o.value==="left"?P<E:o.value==="right"?P>document.documentElement.clientWidth-E:o.value==="top"?S<E:o.value==="bottom"?S>document.documentElement.clientHeight-E:hl(),O=n.value&&(o.value==="left"?P<s.value:o.value==="right"?P>document.documentElement.clientWidth-s.value:o.value==="top"?S<s.value:o.value==="bottom"?S>document.documentElement.clientHeight-s.value:hl());(I||O||n.value&&r.value)&&(m=[P,S],g.value=y(a.value?P:S,n.value),p.value=w(a.value?P:S),d=g.value>-20&&g.value<80,u(T),l(T))}function k(T){const P=T.changedTouches[0].clientX,S=T.changedTouches[0].clientY;if(d){if(!T.cancelable){d=!1;return}const I=Math.abs(P-m[0]),O=Math.abs(S-m[1]);(a.value?I>O&&I>3:O>I&&O>3)?(f.value=!0,d=!1):(a.value?O:I)>3&&(d=!1)}if(!f.value)return;T.preventDefault(),l(T);const E=w(a.value?P:S,!1);p.value=Math.max(0,Math.min(1,E)),E>1?g.value=y(a.value?P:S,!0):E<0&&(g.value=y(a.value?P:S,!1))}function C(T){if(d=!1,!f.value)return;l(T),f.value=!1;const P=c(T.changedTouches[0].identifier),S=Math.abs(P.x),E=Math.abs(P.y);(a.value?S>E&&S>400:E>S&&E>3)?n.value=P.direction===({left:"right",right:"left",top:"down",bottom:"up"}[o.value]||hl()):n.value=p.value>.5}const _=A(()=>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))`:hl(),transition:"none"}:void 0);return Hr(f,()=>{var S,E;const T=((S=t.value)==null?void 0:S.style.transform)??null,P=((E=t.value)==null?void 0:E.style.transition)??null;On(()=>{var I,O,R,M;(O=t.value)==null||O.style.setProperty("transform",((I=_.value)==null?void 0:I.transform)||"none"),(M=t.value)==null||M.style.setProperty("transition",((R=_.value)==null?void 0:R.transition)||null)}),yn(()=>{var I,O;(I=t.value)==null||I.style.setProperty("transform",T),(O=t.value)==null||O.style.setProperty("transition",P)})}),{isDragging:f,dragProgress:p,dragStyles:_}}function hl(){throw new Error}function qd(e){const t=e.slice(-2).toUpperCase();switch(!0){case e==="GB-alt-variant":return{firstDay:0,firstWeekSize:4};case e==="001":return{firstDay:1,firstWeekSize:1};case`AG AS BD BR BS BT BW BZ CA CO DM DO ET GT GU HK HN ID IL IN JM JP KE
|
|
63
|
+
KH KR LA MH MM MO MT MX MZ NI NP PA PE PH PK PR PY SA SG SV TH TT TW UM US
|
|
64
|
+
VE VI WS YE ZA ZW`.includes(t):return{firstDay:0,firstWeekSize:1};case`AI AL AM AR AU AZ BA BM BN BY CL CM CN CR CY EC GE HR KG KZ LB LK LV
|
|
65
|
+
MD ME MK MN MY NZ RO RS SI TJ TM TR UA UY UZ VN XK`.includes(t):return{firstDay:1,firstWeekSize:1};case`AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GP GR HU IE IS
|
|
66
|
+
IT LI LT LU MC MQ NL NO PL RE RU SE SK SM VA`.includes(t):return{firstDay:1,firstWeekSize:4};case"AE AF BH DJ DZ EG IQ IR JO KW LY OM QA SD SY".includes(t):return{firstDay:6,firstWeekSize:1};case t==="MV":return{firstDay:5,firstWeekSize:1};case t==="PT":return{firstDay:0,firstWeekSize:4};default:return null}}function WW(e,t,n){var c;const r=[];let s=[];const i=oO(e),o=aO(e),a=n??((c=qd(t))==null?void 0:c.firstDay)??0,l=(i.getDay()-a+7)%7,u=(o.getDay()-a+7)%7;for(let d=0;d<l;d++){const f=new Date(i);f.setDate(f.getDate()-(l-d)),s.push(f)}for(let d=1;d<=o.getDate();d++){const f=new Date(e.getFullYear(),e.getMonth(),d);s.push(f),s.length===7&&(r.push(s),s=[])}for(let d=1;d<7-u;d++){const f=new Date(o);f.setDate(f.getDate()+d),s.push(f)}return s.length>0&&r.push(s),r}function Ny(e,t,n){var i;const r=n??((i=qd(t))==null?void 0:i.firstDay)??0,s=new Date(e);for(;s.getDay()!==r;)s.setDate(s.getDate()-1);return s}function GW(e,t){var s;const n=new Date(e),r=((((s=qd(t))==null?void 0:s.firstDay)??0)+6)%7;for(;n.getDay()!==r;)n.setDate(n.getDate()+1);return n}function oO(e){return new Date(e.getFullYear(),e.getMonth(),1)}function aO(e){return new Date(e.getFullYear(),e.getMonth()+1,0)}function KW(e){const t=e.split("-").map(Number);return new Date(t[0],t[1]-1,t[2])}const YW=/^([12]\d{3}-([1-9]|0[1-9]|1[0-2])-([1-9]|0[1-9]|[12]\d|3[01]))$/;function lO(e){if(e==null)return new Date;if(e instanceof Date)return e;if(typeof e=="string"){let t;if(YW.test(e))return KW(e);if(t=Date.parse(e),!isNaN(t))return new Date(t)}return null}const wk=new Date(2e3,0,2);function XW(e,t){var r;const n=t??((r=qd(e))==null?void 0:r.firstDay)??0;return xl(7).map(s=>{const i=new Date(wk);return i.setDate(wk.getDate()+n+s),new Intl.DateTimeFormat(e,{weekday:"narrow"}).format(i)})}function QW(e,t,n,r){const s=lO(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"};break;case"fullTime12h":o={hour:"numeric",minute:"numeric",hour12:!0};break;case"fullTime24h":o={hour:"numeric",minute:"numeric",hour12:!1};break;case"fullDateTime":o={year:"numeric",month:"short",day:"numeric",hour:"numeric",minute:"numeric"};break;case"fullDateTime12h":o={year:"numeric",month:"short",day:"numeric",hour:"numeric",minute:"numeric",hour12:!0};break;case"fullDateTime24h":o={year:"numeric",month:"short",day:"numeric",hour:"numeric",minute:"numeric",hour12:!1};break;case"keyboardDate":o={year:"numeric",month:"2-digit",day:"2-digit"};break;case"keyboardDateTime":return o={year:"numeric",month:"2-digit",day:"2-digit",hour:"numeric",minute:"numeric"},new Intl.DateTimeFormat(n,o).format(s).replace(/, /g," ");case"keyboardDateTime12h":return o={year:"numeric",month:"2-digit",day:"2-digit",hour:"numeric",minute:"numeric",hour12:!0},new Intl.DateTimeFormat(n,o).format(s).replace(/, /g," ");case"keyboardDateTime24h":return o={year:"numeric",month:"2-digit",day:"2-digit",hour:"numeric",minute:"numeric",hour12:!1},new Intl.DateTimeFormat(n,o).format(s).replace(/, /g," ");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=BS(String(n.getMonth()+1),2,"0"),i=BS(String(n.getDate()),2,"0");return`${r}-${s}-${i}`}function ZW(e){const[t,n,r]=e.split("-").map(Number);return new Date(t,n-1,r)}function e7(e,t){const n=new Date(e);return n.setMinutes(n.getMinutes()+t),n}function t7(e,t){const n=new Date(e);return n.setHours(n.getHours()+t),n}function uh(e,t){const n=new Date(e);return n.setDate(n.getDate()+t),n}function n7(e,t){const n=new Date(e);return n.setDate(n.getDate()+t*7),n}function r7(e,t){const n=new Date(e);return n.setDate(1),n.setMonth(n.getMonth()+t),n}function By(e){return e.getFullYear()}function s7(e){return e.getMonth()}function i7(e,t,n,r){const s=qd(t),i=n??(s==null?void 0:s.firstDay)??0,o=r??(s==null?void 0:s.firstWeekSize)??1;function a(p){const g=new Date(p,0,1);return 7-Vy(g,Ny(g,t,i),"days")}let l=By(e);const u=uh(Ny(e,t,i),6);l<By(u)&&a(l+1)>=o&&l++;const c=new Date(l,0,1),d=a(l),f=d>=o?uh(c,d-7):uh(c,d);return 1+Vy(e,f,"weeks")}function o7(e){return e.getDate()}function a7(e){return new Date(e.getFullYear(),e.getMonth()+1,1)}function l7(e){return new Date(e.getFullYear(),e.getMonth()-1,1)}function u7(e){return e.getHours()}function c7(e){return e.getMinutes()}function d7(e){return new Date(e.getFullYear(),0,1)}function f7(e){return new Date(e.getFullYear(),11,31)}function h7(e,t){return up(e,t[0])&&g7(e,t[1])}function p7(e){const t=new Date(e);return t instanceof Date&&!isNaN(t.getTime())}function up(e,t){return e.getTime()>t.getTime()}function m7(e,t){return up(Uy(e),Uy(t))}function g7(e,t){return e.getTime()<t.getTime()}function Sk(e,t){return e.getTime()===t.getTime()}function v7(e,t){return e.getDate()===t.getDate()&&e.getMonth()===t.getMonth()&&e.getFullYear()===t.getFullYear()}function y7(e,t){return e.getMonth()===t.getMonth()&&e.getFullYear()===t.getFullYear()}function b7(e,t){return e.getFullYear()===t.getFullYear()}function Vy(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 w7(e,t){const n=new Date(e);return n.setHours(t),n}function S7(e,t){const n=new Date(e);return n.setMinutes(t),n}function _7(e,t){const n=new Date(e);return n.setMonth(t),n}function k7(e,t){const n=new Date(e);return n.setDate(t),n}function x7(e,t){const n=new Date(e);return n.setFullYear(t),n}function Uy(e){return new Date(e.getFullYear(),e.getMonth(),e.getDate(),0,0,0,0)}function E7(e){return new Date(e.getFullYear(),e.getMonth(),e.getDate(),23,59,59,999)}class C7{constructor(t){this.locale=t.locale,this.formats=t.formats}date(t){return lO(t)}toJsDate(t){return t}toISO(t){return JW(this,t)}parseISO(t){return ZW(t)}addMinutes(t,n){return e7(t,n)}addHours(t,n){return t7(t,n)}addDays(t,n){return uh(t,n)}addWeeks(t,n){return n7(t,n)}addMonths(t,n){return r7(t,n)}getWeekArray(t,n){const r=n!==void 0?Number(n):void 0;return WW(t,this.locale,r)}startOfWeek(t,n){const r=n!==void 0?Number(n):void 0;return Ny(t,this.locale,r)}endOfWeek(t){return GW(t,this.locale)}startOfMonth(t){return oO(t)}endOfMonth(t){return aO(t)}format(t,n){return QW(t,n,this.locale,this.formats)}isEqual(t,n){return Sk(t,n)}isValid(t){return p7(t)}isWithinRange(t,n){return h7(t,n)}isAfter(t,n){return up(t,n)}isAfterDay(t,n){return m7(t,n)}isBefore(t,n){return!up(t,n)&&!Sk(t,n)}isSameDay(t,n){return v7(t,n)}isSameMonth(t,n){return y7(t,n)}isSameYear(t,n){return b7(t,n)}setMinutes(t,n){return S7(t,n)}setHours(t,n){return w7(t,n)}setMonth(t,n){return _7(t,n)}setDate(t,n){return k7(t,n)}setYear(t,n){return x7(t,n)}getDiff(t,n,r){return Vy(t,n,r)}getWeekdays(t){const n=t!==void 0?Number(t):void 0;return XW(this.locale,n)}getYear(t){return By(t)}getMonth(t){return s7(t)}getWeek(t,n,r){const s=n!==void 0?Number(n):void 0;return i7(t,this.locale,s,r)}getDate(t){return o7(t)}getNextMonth(t){return a7(t)}getPreviousMonth(t){return l7(t)}getHours(t){return u7(t)}getMinutes(t){return c7(t)}startOfDay(t){return Uy(t)}endOfDay(t){return E7(t)}startOfYear(t){return d7(t)}endOfYear(t){return f7(t)}}const T7=Symbol.for("vuetify:date-options"),_k=Symbol.for("vuetify:date-adapter");function P7(e,t){const n=Zn({adapter:C7,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:R7(n,t)}}function R7(e,t){const n=cn(typeof e.adapter=="function"?new e.adapter({locale:e.locale[t.current.value]??t.current.value,formats:e.formats}):e.adapter);return Ee(t.current,r=>{n.locale=e.locale[r]??r??n.locale}),n}const ad=Symbol.for("vuetify:layout"),uO=Symbol.for("vuetify:layout-item"),kk=1e3,cO=de({overlaps:{type:Array,default:()=>[]},fullHeight:Boolean},"layout"),dO=de({name:{type:String},order:{type:[Number,String],default:0},absolute:Boolean},"layout-item");function fO(){const e=Qe(ad);if(!e)throw new Error("[Vuetify] Could not find injected layout");return{getLayoutItem:e.getLayoutItem,mainRect:e.mainRect,mainStyles:e.mainStyles}}function hO(e){const t=Qe(ad);if(!t)throw new Error("[Vuetify] Could not find injected layout");const n=e.id??`layout-item-${ms()}`,r=an("useLayoutItem");Kt(uO,{id:n});const s=Ie(!1);$b(()=>s.value=!0),zC(()=>s.value=!1);const{layoutItemStyles:i,layoutItemScrimStyles:o}=t.register(r,{...e,active:A(()=>s.value?!1:e.active.value),id:n});return Cn(()=>t.unregister(n)),{layoutItemStyles:i,layoutRect:t.layoutRect,layoutItemScrimStyles:o}}const I7=(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 c={...s,[a.value]:parseInt(s[a.value],10)+(u.value?parseInt(l.value,10):0)};i.push({id:o,layer:c}),s=c}return i};function pO(e){const t=Qe(ad,null),n=A(()=>t?t.rootZIndex.value-100:kk),r=j([]),s=cn(new Map),i=cn(new Map),o=cn(new Map),a=cn(new Map),l=cn(new Map),{resizeRef:u,contentRect:c}=Va(),d=A(()=>{const T=new Map,P=e.overlaps??[];for(const S of P.filter(E=>E.includes(":"))){const[E,I]=S.split(":");if(!r.value.includes(E)||!r.value.includes(I))continue;const O=s.get(E),R=s.get(I),M=i.get(E),D=i.get(I);!O||!R||!M||!D||(T.set(I,{position:O.value,amount:parseInt(M.value,10)}),T.set(E,{position:R.value,amount:-parseInt(D.value,10)}))}return T}),f=A(()=>{const T=[...new Set([...o.values()].map(S=>S.value))].sort((S,E)=>S-E),P=[];for(const S of T){const E=r.value.filter(I=>{var O;return((O=o.get(I))==null?void 0:O.value)===S});P.push(...E)}return I7(P,s,i,a)}),p=A(()=>!Array.from(l.values()).some(T=>T.value)),g=A(()=>f.value[f.value.length-1].layer),m=ae(()=>({"--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=A(()=>f.value.slice(1).map((T,P)=>{let{id:S}=T;const{layer:E}=f.value[P],I=i.get(S),O=s.get(S);return{id:S,...E,size:Number(I.value),position:O.value}})),w=T=>y.value.find(P=>P.id===T),b=an("createLayout"),k=Ie(!1);St(()=>{k.value=!0}),Kt(ad,{register:(T,P)=>{let{id:S,order:E,position:I,layoutSize:O,elementSize:R,active:M,disableTransitions:D,absolute:F}=P;o.set(S,E),s.set(S,I),i.set(S,O),a.set(S,M),D&&l.set(S,D);const K=El(uO,b==null?void 0:b.vnode).indexOf(T);K>-1?r.value.splice(K,0,S):r.value.push(S);const X=A(()=>y.value.findIndex(q=>q.id===S)),H=A(()=>n.value+f.value.length*2-X.value*2),B=A(()=>{const q=I.value==="left"||I.value==="right",G=I.value==="right",le=I.value==="bottom",ie=R.value??O.value,Se=ie===0?"%":"px",Z={[I.value]:0,zIndex:H.value,transform:`translate${q?"X":"Y"}(${(M.value?0:-(ie===0?100:ie))*(G||le?-1:1)}${Se})`,position:F.value||n.value!==kk?"absolute":"fixed",...p.value?void 0:{transition:"none"}};if(!k.value)return Z;const he=y.value[X.value];if(!he)throw new Error(`[Vuetify] Could not find layout item "${S}"`);const ne=d.value.get(S);return ne&&(he[ne.position]+=ne.amount),{...Z,height:q?`calc(100% - ${he.top}px - ${he.bottom}px)`:R.value?`${R.value}px`:void 0,left:G?void 0:`${he.left}px`,right:G?`${he.right}px`:void 0,top:I.value!=="bottom"?`${he.top}px`:void 0,bottom:I.value!=="top"?`${he.bottom}px`:void 0,width:q?R.value?`${R.value}px`:void 0:`calc(100% - ${he.left}px - ${he.right}px)`}}),ee=A(()=>({zIndex:H.value-1}));return{layoutItemStyles:B,layoutItemScrimStyles:ee,zIndex:H}},unregister:T=>{o.delete(T),s.delete(T),i.delete(T),a.delete(T),l.delete(T),r.value=r.value.filter(P=>P!==T)},mainRect:g,mainStyles:m,getLayoutItem:w,items:y,layoutRect:c,rootZIndex:n});const C=ae(()=>["v-layout",{"v-layout--full-height":e.fullHeight}]),_=ae(()=>({zIndex:t?n.value:void 0,position:t?"relative":void 0,overflow:t?"hidden":void 0}));return{layoutClasses:C,layoutStyles:_,getLayoutItem:w,items:y,layoutRect:c,layoutRef:u}}const A7=["start","end","left","right","top","bottom"],O7=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=>A7.includes(e)},sticky:Boolean,...vs(),...Ue(),...n0(),...tl({mobile:null}),...bs(),...dO(),...Dn(),...yt({tag:"nav"}),...Lt()},"VNavigationDrawer"),K0=ke()({name:"VNavigationDrawer",props:O7(),emits:{"update:modelValue":e=>!0,"update:rail":e=>!0},setup(e,t){let{attrs:n,emit:r,slots:s}=t;const{isRtl:i}=Dr(),{themeClasses:o}=Zt(e),{borderClasses:a}=Ds(e),{backgroundColorClasses:l,backgroundColorStyles:u}=fr(()=>e.color),{elevationClasses:c}=Ls(e),{displayClasses:d,mobile:f}=fi(e),{roundedClasses:p}=zn(e),g=oP(),m=st(e,"modelValue",null,B=>!!B),{ssrBootStyles:y}=jd(),{scopeId:w}=Ru(),b=j(),k=Ie(!1),{runOpenDelay:C,runCloseDelay:_}=r0(e,B=>{k.value=B}),T=A(()=>e.rail&&e.expandOnHover&&k.value?Number(e.width):Number(e.rail?e.railWidth:e.width)),P=A(()=>Bv(e.location,i.value)),S=ae(()=>e.persistent),E=A(()=>!e.permanent&&(f.value||e.temporary)),I=A(()=>e.sticky&&!E.value&&P.value!=="bottom");Hr(()=>e.expandOnHover&&e.rail!=null,()=>{Ee(k,B=>r("update:rail",!B))}),Hr(()=>!e.disableResizeWatcher,()=>{Ee(E,B=>!e.permanent&&Mt(()=>m.value=!B))}),Hr(()=>!e.disableRouteWatcher&&!!g,()=>{Ee(g.currentRoute,()=>E.value&&(m.value=!1))}),Ee(()=>e.permanent,B=>{B&&(m.value=!0)}),e.modelValue==null&&!E.value&&(m.value=e.permanent||!f.value);const{isDragging:O,dragProgress:R}=qW({el:b,isActive:m,isTemporary:E,width:T,touchless:ae(()=>e.touchless),position:P}),M=A(()=>{const B=E.value?0:e.rail&&e.expandOnHover?Number(e.railWidth):T.value;return O.value?B*R.value:B}),{layoutItemStyles:D,layoutItemScrimStyles:F}=hO({id:e.name,order:A(()=>parseInt(e.order,10)),position:P,layoutSize:M,elementSize:T,active:zo(m),disableTransitions:ae(()=>O.value),absolute:A(()=>e.absolute||I.value&&typeof U.value!="string")}),{isStuck:U,stickyStyles:K}=VW({rootEl:b,isSticky:I,layoutItemStyles:D}),X=fr(()=>typeof e.scrim=="string"?e.scrim:null),H=A(()=>({...O.value?{opacity:R.value*.2,transition:"none"}:void 0,...F.value}));return Ir({VList:{bgColor:"transparent"}}),Oe(()=>{const B=s.image||e.image;return h(Ae,null,[h(e.tag,ge({ref:b,onMouseenter:C,onMouseleave:_,class:["v-navigation-drawer",`v-navigation-drawer--${P.value}`,{"v-navigation-drawer--expand-on-hover":e.expandOnHover,"v-navigation-drawer--floating":e.floating,"v-navigation-drawer--is-hovering":k.value,"v-navigation-drawer--rail":e.rail,"v-navigation-drawer--temporary":E.value,"v-navigation-drawer--persistent":S.value,"v-navigation-drawer--active":m.value,"v-navigation-drawer--sticky":I.value},o.value,l.value,a.value,d.value,c.value,p.value,e.class],style:[u.value,D.value,y.value,K.value,e.style]},w,n),{default:()=>{var ee,q,G;return[B&&h("div",{key:"image",class:"v-navigation-drawer__img"},[s.image?h(Ot,{key:"image-defaults",disabled:!e.image,defaults:{VImg:{alt:"",cover:!0,height:"inherit",src:e.image}}},s.image):h(ds,{key:"image-img",alt:"",cover:!0,height:"inherit",src:e.image},null)]),s.prepend&&h("div",{class:"v-navigation-drawer__prepend"},[(ee=s.prepend)==null?void 0:ee.call(s)]),h("div",{class:"v-navigation-drawer__content"},[(q=s.default)==null?void 0:q.call(s)]),s.append&&h("div",{class:"v-navigation-drawer__append"},[(G=s.append)==null?void 0:G.call(s)])]}}),h(Oo,{name:"fade-transition"},{default:()=>[E.value&&(O.value||m.value)&&!!e.scrim&&h("div",ge({class:["v-navigation-drawer__scrim",X.backgroundColorClasses.value],style:[H.value,X.backgroundColorStyles.value],onClick:()=>{S.value||(m.value=!1)}},w),null)]})])}),{isStuck:U}}}),M7=de({active:Boolean,disabled:Boolean,max:[Number,String],value:{type:[Number,String],default:0},...Ue(),...Iu({transition:{component:yP}})},"VCounter"),Y0=ke()({name:"VCounter",functional:!0,props:M7(),setup(e,t){let{slots:n}=t;const r=ae(()=>e.max?`${e.value} / ${e.max}`:String(e.value));return Oe(()=>h(si,{transition:e.transition},{default:()=>[Bt(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]),[[Yi,e.active]])]})),{}}}),D7=de({text:String,onClick:Bn(),...Ue(),...Lt()},"VLabel"),X0=ke()({name:"VLabel",props:D7(),setup(e,t){let{slots:n}=t;return Oe(()=>{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)])}),{}}}),L7=de({floating:Boolean,...Ue()},"VFieldLabel"),wf=ke()({name:"VFieldLabel",props:L7(),setup(e,t){let{slots:n}=t;return Oe(()=>h(X0,{class:["v-field-label",{"v-field-label--floating":e.floating},e.class],style:e.style,"aria-hidden":e.floating||void 0},n)),{}}});function mO(e){const{t}=Gr();function n(r){let{name:s,color:i}=r;const o={prepend:"prependAction",prependInner:"prependAction",append:"appendAction",appendInner:"appendAction",clear:"clear"}[s],a=e[`onClick:${s}`];function l(c){c.key!=="Enter"&&c.key!==" "||(c.preventDefault(),c.stopPropagation(),qp(a,new PointerEvent("click",c)))}const u=a&&o?t(`$vuetify.input.${o}`,e.label??""):void 0;return h(J,{icon:e[`${s}Icon`],"aria-label":u,onClick:a,onKeydown:l,color:i},null)}return{InputIcon:n}}const gO=de({focused:Boolean,"onUpdate:focused":Bn()},"focus");function Uu(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:di();const n=st(e,"focused"),r=ae(()=>({[`${t}--focused`]:n.value}));function s(){n.value=!0}function i(){n.value=!1}return{focusClasses:r,isFocused:n,focus:s,blur:i}}const $7=["underlined","outlined","filled","solo","solo-inverted","solo-filled","plain"],xm=de({appendInnerIcon:He,bgColor:String,clearable:Boolean,clearIcon:{type:He,default:"$clear"},active:Boolean,centerAffix:{type:Boolean,default:void 0},color:String,baseColor:String,dirty:Boolean,disabled:{type:Boolean,default:null},glow:Boolean,error:Boolean,flat:Boolean,iconColor:[Boolean,String],label:String,persistentClear:Boolean,prependInnerIcon:He,reverse:Boolean,singleLine:Boolean,variant:{type:String,default:"filled",validator:e=>$7.includes(e)},"onClick:clear":Bn(),"onClick:appendInner":Bn(),"onClick:prependInner":Bn(),...Ue(),...Gp(),...Dn(),...Lt()},"VField"),mu=ke()({name:"VField",inheritAttrs:!1,props:{id:String,...gO(),...xm()},emits:{"update:focused":e=>!0,"update:modelValue":e=>!0},setup(e,t){let{attrs:n,emit:r,slots:s}=t;const{themeClasses:i}=Zt(e),{loaderClasses:o}=Rd(e),{focusClasses:a,isFocused:l,focus:u,blur:c}=Uu(e),{InputIcon:d}=mO(e),{roundedClasses:f}=zn(e),{rtlClasses:p}=Dr(),g=ae(()=>e.dirty||e.active),m=ae(()=>!!(e.label||s.label)),y=ae(()=>!e.singleLine&&m.value),w=ms(),b=A(()=>e.id||`input-${w}`),k=ae(()=>`${b.value}-messages`),C=j(),_=j(),T=j(),P=A(()=>["plain","underlined"].includes(e.variant)),S=A(()=>e.error||e.disabled?void 0:g.value&&l.value?e.color:e.baseColor),E=A(()=>{if(!(!e.iconColor||e.glow&&!l.value))return e.iconColor===!0?S.value:e.iconColor}),{backgroundColorClasses:I,backgroundColorStyles:O}=fr(()=>e.bgColor),{textColorClasses:R,textColorStyles:M}=As(S);Ee(g,U=>{if(y.value){const K=C.value.$el,X=_.value.$el;requestAnimationFrame(()=>{const H=Xb(K),B=X.getBoundingClientRect(),ee=B.x-H.x,q=B.y-H.y-(H.height/2-B.height/2),G=B.width/.75,le=Math.abs(G-H.width)>1?{maxWidth:Ne(G)}:void 0,ie=getComputedStyle(K),Se=getComputedStyle(X),Z=parseFloat(ie.transitionDuration)*1e3||150,he=parseFloat(Se.getPropertyValue("--v-field-label-scale")),ne=Se.getPropertyValue("color");K.style.visibility="visible",X.style.visibility="hidden",Cl(K,{transform:`translate(${ee}px, ${q}px) scale(${he})`,color:ne,...le},{duration:Z,easing:Fh,direction:U?"normal":"reverse"}).finished.then(()=>{K.style.removeProperty("visibility"),X.style.removeProperty("visibility")})})}},{flush:"post"});const D=A(()=>({isActive:g,isFocused:l,controlRef:T,blur:c,focus:u}));function F(U){U.target!==document.activeElement&&U.preventDefault()}return Oe(()=>{var ee,q,G;const U=e.variant==="outlined",K=!!(s["prepend-inner"]||e.prependInnerIcon),X=!!(e.clearable||s.clear)&&!e.disabled,H=!!(s["append-inner"]||e.appendInnerIcon||X),B=()=>s.label?s.label({...D.value,label:e.label,props:{for:b.value}}):e.label;return h("div",ge({class:["v-field",{"v-field--active":g.value,"v-field--appended":H,"v-field--center-affix":e.centerAffix??!P.value,"v-field--disabled":e.disabled,"v-field--dirty":e.dirty,"v-field--error":e.error,"v-field--glow":e.glow,"v-field--flat":e.flat,"v-field--has-background":!!e.bgColor,"v-field--persistent-clear":e.persistentClear,"v-field--prepended":K,"v-field--reverse":e.reverse,"v-field--single-line":e.singleLine,"v-field--no-label":!B(),[`v-field--variant-${e.variant}`]:!0},i.value,I.value,a.value,o.value,f.value,p.value,e.class],style:[O.value,e.style],onClick:F},n),[h("div",{class:"v-field__overlay"},null),h(Kp,{name:"v-field",active:!!e.loading,color:e.error?"error":typeof e.loading=="string"?e.loading:e.color},{default:s.loader}),K&&h("div",{key:"prepend",class:"v-field__prepend-inner"},[e.prependInnerIcon&&h(d,{key:"prepend-icon",name:"prependInner",color:E.value},null),(ee=s["prepend-inner"])==null?void 0:ee.call(s,D.value)]),h("div",{class:"v-field__field","data-no-activator":""},[["filled","solo","solo-inverted","solo-filled"].includes(e.variant)&&y.value&&h(wf,{key:"floating-label",ref:_,class:[R.value],floating:!0,for:b.value,style:M.value},{default:()=>[B()]}),m.value&&h(wf,{key:"label",ref:C,for:b.value},{default:()=>[B()]}),((q=s.default)==null?void 0:q.call(s,{...D.value,props:{id:b.value,class:"v-field__input","aria-describedby":k.value},focus:u,blur:c}))??h("div",{id:b.value,class:"v-field__input","aria-describedby":k.value},null)]),X&&h(wP,{key:"clear"},{default:()=>[Bt(h("div",{class:"v-field__clearable",onMousedown:le=>{le.preventDefault(),le.stopPropagation()}},[h(Ot,{defaults:{VIcon:{icon:e.clearIcon}}},{default:()=>[s.clear?s.clear({...D.value,props:{onFocus:u,onBlur:c,onClick:e["onClick:clear"]}}):h(d,{name:"clear",onFocus:u,onBlur:c},null)]})]),[[Yi,e.dirty]])]}),H&&h("div",{key:"append",class:"v-field__append-inner"},[(G=s["append-inner"])==null?void 0:G.call(s,D.value),e.appendInnerIcon&&h(d,{key:"append-icon",name:"appendInner",color:E.value},null)]),h("div",{class:["v-field__outline",R.value],style:M.value},[U&&h(Ae,null,[h("div",{class:"v-field__outline__start"},null),y.value&&h("div",{class:"v-field__outline__notch"},[h(wf,{ref:_,floating:!0,for:b.value},{default:()=>[B()]})]),h("div",{class:"v-field__outline__end"},null)]),P.value&&y.value&&h(wf,{ref:_,floating:!0,for:b.value},{default:()=>[B()]})])])}),{controlRef:T,fieldIconColor:E}}}),F7=de({active:Boolean,color:String,messages:{type:[Array,String],default:()=>[]},...Ue(),...Iu({transition:{component:yP,leaveAbsolute:!0,group:!0}})},"VMessages"),N7=ke()({name:"VMessages",props:F7(),setup(e,t){let{slots:n}=t;const r=A(()=>An(e.messages)),{textColorClasses:s,textColorStyles:i}=As(()=>e.color);return Oe(()=>h(si,{transition:e.transition,tag:"div",class:["v-messages",s.value,e.class],style:[i.value,e.style]},{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]))]})),{}}}),vO=Symbol.for("vuetify:form"),B7=de({disabled:Boolean,fastFail:Boolean,readonly:Boolean,modelValue:{type:Boolean,default:null},validateOn:{type:String,default:"input"}},"form");function V7(e){const t=st(e,"modelValue"),n=ae(()=>e.disabled),r=ae(()=>e.readonly),s=Ie(!1),i=j([]),o=j([]);async function a(){const c=[];let d=!0;o.value=[],s.value=!0;for(const f of i.value){const p=await f.validate();if(p.length>0&&(d=!1,c.push({id:f.id,errorMessages:p})),!d&&e.fastFail)break}return o.value=c,s.value=!1,{valid:d,errors:o.value}}function l(){i.value.forEach(c=>c.reset())}function u(){i.value.forEach(c=>c.resetValidation())}return Ee(i,()=>{let c=0,d=0;const f=[];for(const p of i.value)p.isValid===!1?(d++,f.push({id:p.id,errorMessages:p.errorMessages})):p.isValid===!0&&c++;o.value=f,t.value=d>0?!1:c===i.value.length?!0:null},{deep:!0,flush:"post"}),Kt(vO,{register:c=>{let{id:d,vm:f,validate:p,reset:g,resetValidation:m}=c;i.value.some(y=>y.id===d),i.value.push({id:d,validate:p,reset:g,resetValidation:m,vm:Lp(f),isValid:null,errorMessages:[]})},unregister:c=>{i.value=i.value.filter(d=>d.id!==c)},update:(c,d,f)=>{const p=i.value.find(g=>g.id===c);p&&(p.isValid=d,p.errorMessages=f)},isDisabled:n,isReadonly:r,isValidating:s,isValid:t,items:i,validateOn:ae(()=>e.validateOn)}),{errors:o,isDisabled:n,isReadonly:r,isValidating:s,isValid:t,items:i,validate:a,reset:l,resetValidation:u}}function yO(e){const t=Qe(vO,null);return{...t,isReadonly:A(()=>!!((e==null?void 0:e.readonly)??(t==null?void 0:t.isReadonly.value))),isDisabled:A(()=>!!((e==null?void 0:e.disabled)??(t==null?void 0:t.isDisabled.value)))}}const U7=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,...gO()},"validation");function z7(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:di(),n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:ms();const r=st(e,"modelValue"),s=A(()=>e.validationValue===void 0?r.value:e.validationValue),i=yO(e),o=j([]),a=Ie(!0),l=A(()=>!!(An(r.value===""?null:r.value).length||An(s.value===""?null:s.value).length)),u=A(()=>{var k;return(k=e.errorMessages)!=null&&k.length?An(e.errorMessages).concat(o.value).slice(0,Math.max(0,Number(e.maxErrors))):o.value}),c=A(()=>{var _;let k=(e.validateOn??((_=i.validateOn)==null?void 0:_.value))||"input";k==="lazy"&&(k="input lazy"),k==="eager"&&(k="input eager");const C=new Set((k==null?void 0:k.split(" "))??[]);return{input:C.has("input"),blur:C.has("blur")||C.has("input")||C.has("invalid-input"),invalidInput:C.has("invalid-input"),lazy:C.has("lazy"),eager:C.has("eager")}}),d=A(()=>{var k;return e.error||(k=e.errorMessages)!=null&&k.length?!1:e.rules.length?a.value?o.value.length||c.value.lazy?null:!0:!o.value.length:!0}),f=Ie(!1),p=A(()=>({[`${t}--error`]:d.value===!1,[`${t}--dirty`]:l.value,[`${t}--disabled`]:i.isDisabled.value,[`${t}--readonly`]:i.isReadonly.value})),g=an("validation"),m=A(()=>e.name??Q(n));Su(()=>{var k;(k=i.register)==null||k.call(i,{id:m.value,vm:g,validate:b,reset:y,resetValidation:w})}),Cn(()=>{var k;(k=i.unregister)==null||k.call(i,m.value)}),St(async()=>{var k;c.value.lazy||await b(!c.value.eager),(k=i.update)==null||k.call(i,m.value,d.value,u.value)}),Hr(()=>c.value.input||c.value.invalidInput&&d.value===!1,()=>{Ee(s,()=>{if(s.value!=null)b();else if(e.focused){const k=Ee(()=>e.focused,C=>{C||b(),k()})}})}),Hr(()=>c.value.blur,()=>{Ee(()=>e.focused,k=>{k||b()})}),Ee([d,u],()=>{var k;(k=i.update)==null||k.call(i,m.value,d.value,u.value)});async function y(){r.value=null,await Mt(),await w()}async function w(){a.value=!0,c.value.lazy?o.value=[]:await b(!c.value.eager)}async function b(){let k=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;const C=[];f.value=!0;for(const _ of e.rules){if(C.length>=Number(e.maxErrors??1))break;const P=await(typeof _=="function"?_:()=>_)(s.value);if(P!==!0){if(P!==!1&&typeof P!="string"){console.warn(`${P} is not a valid value. Rule functions must return boolean true or a string.`);continue}C.push(P||"")}}return o.value=C,f.value=!1,a.value=k,o.value}return{errorMessages:u,isDirty:l,isDisabled:i.isDisabled,isReadonly:i.isReadonly,isPristine:a,isValid:d,isValidating:f,reset:y,resetValidation:w,validate:b,validationClasses:p}}const ol=de({id:String,appendIcon:He,baseColor:String,centerAffix:{type:Boolean,default:!0},color:String,glow:Boolean,iconColor:[Boolean,String],prependIcon:He,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":Bn(),"onClick:append":Bn(),...Ue(),...Ar(),...xd(Or(),["maxWidth","minWidth","width"]),...Lt(),...U7()},"VInput"),fs=ke()({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}=Mr(e),{themeClasses:a}=Zt(e),{rtlClasses:l}=Dr(),{InputIcon:u}=mO(e),c=ms(),d=A(()=>e.id||`input-${c}`),f=A(()=>`${d.value}-messages`),{errorMessages:p,isDirty:g,isDisabled:m,isReadonly:y,isPristine:w,isValid:b,isValidating:k,reset:C,resetValidation:_,validate:T,validationClasses:P}=z7(e,"v-input",d),S=A(()=>({id:d,messagesId:f,isDirty:g,isDisabled:m,isReadonly:y,isPristine:w,isValid:b,isValidating:k,reset:C,resetValidation:_,validate:T})),E=ae(()=>e.error||e.disabled?void 0:e.focused?e.color:e.baseColor),I=ae(()=>{if(e.iconColor)return e.iconColor===!0?E.value:e.iconColor}),O=A(()=>{var R;return(R=e.errorMessages)!=null&&R.length||!w.value&&p.value.length?p.value:e.hint&&(e.persistentHint||e.focused)?e.hint:e.messages});return Oe(()=>{var U,K,X,H;const R=!!(r.prepend||e.prependIcon),M=!!(r.append||e.appendIcon),D=O.value.length>0,F=!e.hideDetails||e.hideDetails==="auto"&&(D||!!r.details);return h("div",{class:["v-input",`v-input--${e.direction}`,{"v-input--center-affix":e.centerAffix,"v-input--focused":e.focused,"v-input--glow":e.glow,"v-input--hide-spin-buttons":e.hideSpinButtons},i.value,a.value,l.value,P.value,e.class],style:[o.value,e.style]},[R&&h("div",{key:"prepend",class:"v-input__prepend"},[(U=r.prepend)==null?void 0:U.call(r,S.value),e.prependIcon&&h(u,{key:"prepend-icon",name:"prepend",color:I.value},null)]),r.default&&h("div",{class:"v-input__control"},[(K=r.default)==null?void 0:K.call(r,S.value)]),M&&h("div",{key:"append",class:"v-input__append"},[e.appendIcon&&h(u,{key:"append-icon",name:"append",color:I.value},null),(X=r.append)==null?void 0:X.call(r,S.value)]),F&&h("div",{id:f.value,class:"v-input__details",role:"alert","aria-live":"polite"},[h(N7,{active:D,messages:O.value},{message:r.message}),(H=r.details)==null?void 0:H.call(r,S.value)])])}),{reset:C,resetValidation:_,validate:T,isValid:b,errorMessages:p}}}),H7=["color","file","time","date","datetime-local","week","month"],bO=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(),...xm()},"VTextField"),at=ke()({name:"VTextField",directives:{Intersect:z0},inheritAttrs:!1,props:bO(),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=A(()=>typeof e.counterValue=="function"?e.counterValue(i.value):typeof e.counterValue=="number"?e.counterValue:(i.value??"").toString().length),c=A(()=>{if(n.maxlength)return n.maxlength;if(!(!e.counter||typeof e.counter!="number"&&typeof e.counter!="string"))return e.counter}),d=A(()=>["plain","underlined"].includes(e.variant));function f(T,P){var S,E;!e.autofocus||!T||(E=(S=P[0].target)==null?void 0:S.focus)==null||E.call(S)}const p=j(),g=j(),m=j(),y=A(()=>H7.includes(e.type)||e.persistentPlaceholder||o.value||e.active);function w(){var T;m.value!==document.activeElement&&((T=m.value)==null||T.focus()),o.value||a()}function b(T){r("mousedown:control",T),T.target!==m.value&&(w(),T.preventDefault())}function k(T){w(),r("click:control",T)}function C(T,P){T.stopPropagation(),w(),Mt(()=>{i.value=null,P(),qp(e["onClick:clear"],T)})}function _(T){var S;const P=T.target;if(i.value=P.value,(S=e.modelModifiers)!=null&&S.trim&&["text","search","password","tel","url"].includes(e.type)){const E=[P.selectionStart,P.selectionEnd];Mt(()=>{P.selectionStart=E[0],P.selectionEnd=E[1]})}}return Oe(()=>{const T=!!(s.counter||e.counter!==!1&&e.counter!=null),P=!!(T||s.details),[S,E]=Ja(n),{modelValue:I,...O}=fs.filterProps(e),R=mu.filterProps(e);return h(fs,ge({ref:p,modelValue:i.value,"onUpdate:modelValue":M=>i.value=M,class:["v-text-field",{"v-text-field--prefixed":e.prefix,"v-text-field--suffixed":e.suffix,"v-input--plain-underlined":d.value},e.class],style:e.style},S,O,{centerAffix:!d.value,focused:o.value}),{...s,default:M=>{let{id:D,isDisabled:F,isDirty:U,isReadonly:K,isValid:X,reset:H}=M;return h(mu,ge({ref:g,onMousedown:b,onClick:k,"onClick:clear":B=>C(B,H),"onClick:prependInner":e["onClick:prependInner"],"onClick:appendInner":e["onClick:appendInner"],role:e.role},R,{id:D.value,active:y.value||U.value,dirty:U.value||e.dirty,disabled:F.value,focused:o.value,error:X.value===!1}),{...s,default:B=>{let{props:{class:ee,...q}}=B;const G=Bt(h("input",ge({ref:m,value:i.value,onInput:_,autofocus:e.autofocus,readonly:K.value,disabled:F.value,name:e.name,placeholder:e.placeholder,size:1,type:e.type,onFocus:w,onBlur:l},q,E),null),[[hr("intersect"),{handler:f},null,{once:!0}]]);return h(Ae,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:ee,"data-no-activator":""},[s.default(),G]):Ni(G,{class:ee}),e.suffix&&h("span",{class:"v-text-field__suffix"},[h("span",{class:"v-text-field__suffix__text"},[e.suffix])])])}})},details:P?M=>{var D;return h(Ae,null,[(D=s.details)==null?void 0:D.call(s,M),T&&h(Ae,null,[h("span",null,null),h(Y0,{active:e.persistentCounter||o.value,value:u.value,max:c.value,disabled:e.disabled},s.counter)])])}:void 0})}),Xi({},p,g,m)}}),j7=de({id:String,interactive:Boolean,text:String,...Ms(Id({closeOnBack:!1,location:"end",locationStrategy:"connected",eager:!0,minWidth:0,offset:10,openOnClick:!1,openOnHover:!0,origin:"auto",scrim:!1,scrollStrategy:"reposition",transition:null}),["absolute","persistent"])},"VTooltip"),nt=ke()({name:"VTooltip",props:j7(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const r=st(e,"modelValue"),{scopeId:s}=Ru(),i=ms(),o=ae(()=>e.id||`v-tooltip-${i}`),a=j(),l=A(()=>e.location.split(" ").length>1?e.location:e.location+" center"),u=A(()=>e.origin==="auto"||e.origin==="overlap"||e.origin.split(" ").length>1||e.location.split(" ").length>1?e.origin:e.origin+" center"),c=ae(()=>e.transition!=null?e.transition:r.value?"scale-transition":"fade-transition"),d=A(()=>ge({"aria-describedby":o.value},e.activatorProps));return Oe(()=>{const f=Bi.filterProps(e);return h(Bi,ge({ref:a,class:["v-tooltip",{"v-tooltip--interactive":e.interactive},e.class],style:e.style,id:o.value},f,{modelValue:r.value,"onUpdate:modelValue":p=>r.value=p,transition:c.value,absolute:!0,location:l.value,origin:u.value,persistent:!0,role:"tooltip",activatorProps:d.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}})}),Xi({},a)}}),q7={key:0,class:"d-flex justify-center static-disabled"},W7={key:1,class:"pulsating-red d-flex justify-center"},G7={key:0,class:"d-flex justify-center"},K7={key:0},Y7={key:1},X7={key:1},Q7={key:2},J7={key:3},Z7={key:0},eG={key:1},tG={key:0},nG={key:1},rG={key:0},sG={key:1},iG={key:2},oG=Le({__name:"FileExplorerSideNav",setup(e){const t=Ft(),n=nr(),r=j(36),s=j(void 0),i=j(void 0),o=j(!1),a=j(!0),l=A(()=>t.sideNavPrinter),u=A(()=>{var ne;return(ne=l.value)==null?void 0:ne.id}),c=A(()=>u.value?n.isApiResponding(u.value):!1),d=A(()=>{var ne;return iO((ne=l.value)==null?void 0:ne.printerType)}),f=A(()=>{var ne;return ap((ne=l.value)==null?void 0:ne.printerType)}),p=A(()=>{var ne;return lp((ne=l.value)==null?void 0:ne.printerType)}),g=A(()=>{var ne;return Oc((ne=l.value)==null?void 0:ne.printerType)}),m=A(()=>u.value?n.isPrinterOperational(u.value):!1),y=A(()=>{var ne;return(ne=l.value)==null?void 0:ne.enabled}),w=A(()=>{var ne,z;return!!((z=(ne=l.value)==null?void 0:ne.disabledReason)!=null&&z.length)}),b=A(()=>u.value?n.isPrinterPrinting(u.value):!1),k=A(()=>{var ne;return(ne=i.value)!=null&&ne.length?i.value.filter(z=>{var xe;return(xe=s.value)!=null&&xe.length?`${z.path}`.toLowerCase().includes(s.value):!0})||[]:[]}),C=A(()=>!l.value||!u.value?!1:n.isPrinterStoppable(u.value)),_=A(()=>!l.value||!u.value?!1:n.isPrinterPaused(u.value)),T=A(()=>{var ne;return u.value?((ne=i.value)==null?void 0:ne.length)&&n.isApiResponding(u.value):!1}),P=A(()=>{if(!u.value)throw new Error("Printer ID not set, cannot get current job");return n.printerJobsById[u.value]}),S=A(()=>{if(!u.value)throw new Error("Printer ID not set, cannot get current printing file name");return n.printingFilePathsByPrinterId[u.value]}),E=A(()=>{var N;if(!u.value||!l.value)return null;const ne=n.printerEventsById[u.value],z=n.socketStatesById[u.value],xe=CA(l.value,z,ne);return((N=Ns().frontendDebugSettings)==null?void 0:N.showInterpretedPrinterState)&&console.debug("[FileExplorerSideNav] rendered for printerId",u.value,xe==null?void 0:xe.text,xe==null?void 0:xe.color,xe==null?void 0:xe.rgb),xe}),I=async()=>{var z;a.value=!0;const ne=(z=l.value)==null?void 0:z.id;if(ne)try{n.isApiResponding(ne)?i.value=await t.loadPrinterFiles(ne):i.value=await $i.getFileCache(ne)}finally{a.value=!1}},O=async ne=>{u.value&&await t.deletePrinterFile(u.value,ne.path)};Ee(l,async(ne,z)=>{o.value=!!ne;const xe=ne==null?void 0:ne.id;!ne||!xe||(!i.value||ne.id!==(z==null?void 0:z.id)||!z)&&await I()}),Ee(o,ne=>{ne||t.setSideNavPrinter(void 0)});function R(ne){return ne?ne==null?void 0:ne.toFixed(1):""}function M(ne){return u.value?n.printingFilePathsByPrinterId[u.value]===ne.path:!1}function D(){const ne=l.value;if(ne&&o.value)return Sm(ne.name)}function F(){l.value&&(Qt.openPrinterURL(l.value.printerURL),he())}function U(){if(!l.value)return;const ne=new URL(l.value.printerURL);ne.port="8080",Qt.openPrinterURL(ne.toString()),he()}async function K(){if(u.value){if(n.isPrinterOperational(u.value))return await Qt.sendPrinterDisconnectCommand(u.value);await Qt.sendPrinterConnectCommand(u.value)}}async function X(){if(!u.value)throw new Error("Printer ID not set, cant toggle enabled");if(!l.value)throw new Error("Cant toggle enabled, sidenav printer unset");const ne=!l.value.enabled;await Qt.toggleEnabled(u.value,ne)}async function H(){if(!u.value)throw new Error("Printer ID not set, cant toggle maintenance");if(!l.value)throw new Error("Cant toggle enabled, sidenav printer unset");if(w.value){await Qt.updatePrinterMaintenance(u.value);return}t.setMaintenanceDialogPrinter(l.value),await tn(nn.PrinterMaintenanceDialog).openDialog(),he()}async function B(){u.value&&await Qt.refreshSocket(u.value)}async function ee(){u.value&&confirm("Are you sure to cancel the current print job?")&&await Ma.stopPrintJob(u.value)}async function q(){u.value&&await Ma.pausePrintJob(u.value)}async function G(){u.value&&await Ma.resumePrintJob(u.value)}async function le(){u.value&&confirm("Are you sure to delete all files for this printer?")&&(a.value=!0,await t.deletePrinterFiles(u.value),a.value=!1,i.value=t.printerFiles(u.value))}function ie(){l.value&&(t.setUpdateDialogPrinter(l.value),tn(nn.AddOrUpdatePrinterDialog).openDialog(),he())}async function Se(ne){u.value&&await n.selectAndPrintFile({printerId:u.value,fullPath:ne.path})}function Z(ne){u.value&&$i.downloadFile(u.value,ne)}function he(){t.setSideNavPrinter(void 0)}return(ne,z)=>{const xe=hr("drop-upload");return $(),te(K0,{modelValue:o.value,"onUpdate:modelValue":z[14]||(z[14]=Fe=>o.value=Fe),absolute:"",loading:"true",location:"right",scrim:"white",temporary:"",width:"700",onClose:z[15]||(z[15]=Fe=>he())},{default:v(()=>{var Fe,N,V;return[l.value?($(),te(Ve,{key:0,lines:"two"},{prepend:v(()=>[h(nt,{location:"left"},{activator:v(({props:Y})=>[h(se,ge({size:r.value,class:"mr-4 mt-1",color:"primary",icon:""},Y,{onClick:z[0]||(z[0]=fe=>F()),onMouseup:z[1]||(z[1]=_t(fe=>F(),["middle"]))}),{default:v(()=>[h(ut,{size:r.value,class:"font-weight-bold",color:"primary"},{default:v(()=>[x(re(D()),1)]),_:1},8,["size"])]),_:2},1040,["size"])]),default:v(()=>[L("span",null," Visit the "+re(g.value)+" associated to this printer ",1)]),_:1})]),default:v(()=>[h(ft,{class:"font-weight-bold"},{default:v(()=>[x(re(l.value.name),1)]),_:1}),h(bt),h(OW,null,{default:v(()=>{var Y,fe,ce,be;return[!y.value||!c.value?($(),ve("strong",q7,re(y.value?"Enabled":"Disabled")+" - "+re(c.value?(fe=(Y=E.value)==null?void 0:Y.text)==null?void 0:fe.toUpperCase():"Offline"),1)):pe("",!0),y.value&&((ce=E.value)!=null&&ce.text)&&m.value&&c.value?($(),ve("strong",W7," Enabled - "+re((be=E.value)==null?void 0:be.text),1)):pe("",!0)]}),_:1}),P.value?($(),te(bt,{key:0},{default:v(()=>{var Y,fe,ce,be;return[(Y=P.value)!=null&&Y.progress?($(),ve("span",G7," Progress: "+re(R((fe=P.value)==null?void 0:fe.progress.completion))+"% ",1)):pe("",!0),(ce=P.value)!=null&&ce.progress?($(),te(su,{key:1,"model-value":R((be=P.value.progress)==null?void 0:be.completion),class:"mt-1 mb-1",height:"8px"},null,8,["model-value"])):pe("",!0),h(nt,{location:"bottom"},{activator:v(({props:Re})=>[h(se,ge({size:"small"},Re,{variant:"outlined"}),{default:v(()=>[x(re(S.value),1)]),_:2},1040)]),default:v(()=>[L("span",null,re(S.value),1)]),_:1})]}),_:1})):pe("",!0)]),_:1})):pe("",!0),!y.value||!c.value?($(),te(fn,{key:1,color:"primary"},{default:v(()=>[y.value?($(),ve("span",Y7,[x(" This "+re(g.value)+" seems unreachable... Will keep trying for you ",1),h(J,null,{default:v(()=>z[16]||(z[16]=[x("hourglass_top")])),_:1})])):($(),ve("span",K7," Disabled "+re(g.value)+", enable it first to get live updates ",1))]),_:1})):pe("",!0),!((Fe=l.value)!=null&&Fe.enabled)&&!((N=l.value)!=null&&N.disabledReason)?($(),te(fn,{key:2,color:"secondary"},{default:v(()=>[x(" This "+re(g.value)+" was disabled without reason. ",1)]),_:1})):pe("",!0),(V=l.value)!=null&&V.disabledReason?($(),te(fn,{key:3,color:"black"},{default:v(()=>{var Y;return[x(" This "+re(g.value)+" was disabled for maintenance: ",1),z[17]||(z[17]=L("br",null,null,-1)),L("small",null," "+re((Y=l.value)==null?void 0:Y.disabledReason),1)]}),_:1})):pe("",!0),h(dn),Bt(($(),te(Ut,{density:"compact"},{default:v(()=>[h(qr,{inset:""},{default:v(()=>z[18]||(z[18]=[x(" Manage FDM Monster instance")])),_:1}),h(nt,{location:"left"},{activator:v(({props:Y})=>[h(Ve,ge({class:"extra-dense-list-item",link:""},Y,{onClick:z[2]||(z[2]=_t(fe=>F(),["prevent","stop"]))}),{prepend:v(()=>[h(ut,{size:r.value,class:"ml-3 mr-6 ma-5"},{default:v(()=>[d.value?($(),te(ds,{key:0,src:Q($y)},null,8,["src"])):f.value?($(),ve("span",X7,"MR")):p.value?($(),ve("span",Q7,"PL")):($(),ve("span",J7,"?"))]),_:1},8,["size"])]),default:v(()=>[L("span",null," Open "+re(g.value),1)]),_:2},1040)]),default:v(()=>[L("span",null," Visit the "+re(g.value)+" associated to this printer ",1)]),_:1}),f.value?($(),te(nt,{key:0,location:"left"},{activator:v(({props:Y})=>[h(Ve,ge({class:"extra-dense-list-item",link:""},Y,{onClick:z[3]||(z[3]=_t(fe=>U(),["prevent","stop"]))}),{prepend:v(()=>[h(ut,{size:r.value,class:"ml-3 mr-6 ma-5"},{default:v(()=>z[19]||(z[19]=[L("span",null,"MA",-1)])),_:1},8,["size"])]),default:v(()=>[z[20]||(z[20]=L("span",null," Open Mainsail ",-1))]),_:2},1040)]),default:v(()=>[z[21]||(z[21]=L("span",null," Visit the Mainsail for this printer ",-1))]),_:1})):pe("",!0),h(nt,{location:"left"},{activator:v(({props:Y})=>[h(Ve,ge({class:"extra-dense-list-item",link:""},Y,{onClick:z[4]||(z[4]=_t(fe=>X(),["prevent","stop"]))}),{prepend:v(()=>[h(ut,{size:r.value,color:"grey-lighten-1"},{default:v(()=>[h(J,{color:y.value?"primary":"green"},{default:v(()=>z[22]||(z[22]=[x(" dns")])),_:1},8,["color"])]),_:1},8,["size"])]),default:v(()=>[y.value?($(),ve("span",Z7," Disable Printer Location ")):y.value?pe("",!0):($(),ve("span",eG," Enable Printer Location "))]),_:2},1040)]),default:v(()=>[z[23]||(z[23]=L("span",null," Deactivate connection, without impacting print ",-1))]),_:1}),h(nt,{location:"left"},{activator:v(({props:Y})=>[h(Ve,ge({class:"extra-dense-list-item",link:""},Y,{onClick:z[5]||(z[5]=_t(fe=>H(),["prevent","stop"]))}),{default:v(()=>[h(ut,{size:r.value,color:"grey-lighten-1"},{default:v(()=>[h(J,{color:w.value?"green":"primary"},{default:v(()=>z[24]||(z[24]=[x(" construction ")])),_:1},8,["color"])]),_:1},8,["size"]),w.value?w.value?($(),ve("span",nG," Complete Maintenance ")):pe("",!0):($(),ve("span",tG," Enable Maintenance "))]),_:2},1040)]),default:v(()=>[z[25]||(z[25]=L("span",null," Deactivate, set under repair, without impacting print ",-1))]),_:1}),h(nt,{location:"left"},{activator:v(({props:Y})=>[h(Ve,ge({class:"extra-dense-list-item",link:""},Y,{onClick:z[6]||(z[6]=_t(fe=>B(),["prevent","stop"]))}),{default:v(()=>[h(ut,{size:r.value},{default:v(()=>[h(J,{color:w.value?"green":"primary",class:"grey-lighten-1"},{default:v(()=>z[26]||(z[26]=[x(" autorenew ")])),_:1},8,["color"])]),_:1},8,["size"]),z[27]||(z[27]=L("span",null,[x(" Refresh State "),L("small",null," - this does not affect the print! ")],-1))]),_:2},1040)]),default:v(()=>[z[28]||(z[28]=L("span",null," Let FDM Monster know you are experiencing inconsistencies, reset all volatile states ",-1))]),_:1}),h(dn),h(qr,{inset:""},{default:v(()=>z[29]||(z[29]=[x(" Commands")])),_:1}),h(nt,{location:"left"},{activator:v(({props:Y})=>{var fe;return[h(Ve,ge({disabled:!((fe=l.value)!=null&&fe.enabled)||!c.value,class:"extra-dense-list-item",link:""},Y,{onClick:z[7]||(z[7]=_t(ce=>K(),["prevent","stop"]))}),{default:v(()=>[h(ut,{size:r.value},{default:v(()=>[h(J,null,{default:v(()=>z[30]||(z[30]=[x(" usb")])),_:1})]),_:1},8,["size"]),C.value?($(),ve("span",rG," Disconnect USB & Stop Print ")):m.value?($(),ve("span",sG," Disconnect USB ")):($(),ve("span",iG," Connect USB "))]),_:2},1040,["disabled"])]}),default:v(()=>[z[31]||(z[31]=L("span",null," Disconnect USB, disrupting any print ",-1))]),_:1}),h(nt,{location:"left"},{activator:v(({props:Y})=>[h(Ve,ge({disabled:!c.value||!b.value,class:"extra-dense-list-item",link:""},Y,{onClick:z[8]||(z[8]=_t(fe=>_.value?G():q(),["prevent","stop"]))}),{default:v(()=>[h(ut,{size:r.value},{default:v(()=>[_.value?pe("",!0):($(),te(J,{key:0},{default:v(()=>z[32]||(z[32]=[x(" pause")])),_:1})),_.value?($(),te(J,{key:1},{default:v(()=>z[33]||(z[33]=[x(" play_circle_outline")])),_:1})):pe("",!0)]),_:1},8,["size"]),x(" "+re(_.value?"Resume print":"Pause print"),1)]),_:2},1040,["disabled"])]),default:v(()=>[z[34]||(z[34]=L("span",null," Send Pause or Resume command ",-1))]),_:1}),h(nt,{location:"left"},{activator:v(({props:Y})=>[h(Ve,ge({disabled:!C.value,class:"extra-dense-list-item",link:""},Y,{onClick:z[9]||(z[9]=_t(fe=>ee(),["prevent","stop"]))}),{default:v(()=>[h(ut,{size:r.value},{default:v(()=>[h(J,null,{default:v(()=>z[35]||(z[35]=[x(" stop")])),_:1})]),_:1},8,["size"]),z[36]||(z[36]=x(" Cancel print "))]),_:2},1040,["disabled"])]),default:v(()=>[z[37]||(z[37]=L("span",null," Cancel print gracefully ",-1))]),_:1}),h(nt,{location:"left"},{activator:v(({props:Y})=>[h(Ve,ge({disabled:!T.value,class:"extra-dense-list-item",link:""},Y,{onClick:z[10]||(z[10]=_t(fe=>le(),["prevent","stop"]))}),{default:v(()=>[h(ut,{size:r.value},{default:v(()=>[h(J,null,{default:v(()=>z[38]||(z[38]=[x(" delete")])),_:1})]),_:1},8,["size"]),z[39]||(z[39]=x(" Delete files "))]),_:2},1040,["disabled"])]),default:v(()=>[z[40]||(z[40]=L("span",null," Clear all files present on OctoPrint (local) ",-1))]),_:1}),h(nt,{location:"left"},{activator:v(({props:Y})=>[h(Ve,ge({class:"extra-dense-list-item",link:""},Y,{onClick:z[11]||(z[11]=_t(fe=>I(),["prevent","stop"]))}),{default:v(()=>[h(ut,{size:r.value},{default:v(()=>[h(J,null,{default:v(()=>z[41]||(z[41]=[x(" refresh")])),_:1})]),_:1},8,["size"]),z[42]||(z[42]=x(" Refresh files "))]),_:2},1040)]),default:v(()=>[z[43]||(z[43]=L("span",null," Rebuild the file list on OctoPrint (local) ",-1))]),_:1}),h(nt,{location:"left"},{activator:v(({props:Y})=>[h(Ve,ge({class:"extra-dense-list-item",link:""},Y,{onClick:z[12]||(z[12]=_t(fe=>ie(),["prevent","stop"]))}),{default:v(()=>[h(ut,{size:r.value},{default:v(()=>[h(J,null,{default:v(()=>z[44]||(z[44]=[x(" settings")])),_:1})]),_:1},8,["size"]),z[45]||(z[45]=x(" Settings "))]),_:2},1040)]),default:v(()=>[z[46]||(z[46]=L("span",null," Edit the printer settings ",-1))]),_:1})]),_:1})),[[xe,{printers:[l.value]}]]),h(dn),Bt(($(),te(Ut,{density:"compact"},{default:v(()=>[h(qr,{inset:""},{default:v(()=>z[47]||(z[47]=[x(" Files - drag 'n drop!")])),_:1}),h(at,{modelValue:s.value,"onUpdate:modelValue":z[13]||(z[13]=Y=>s.value=Y),class:"ml-5 mr-5",clearable:"",label:"Search files...","prepend-icon":"search"},null,8,["modelValue"]),k.value.length?pe("",!0):($(),te(Ve,{key:0},{default:v(()=>[h(ut,{size:r.value},{default:v(()=>[h(J,null,{default:v(()=>z[48]||(z[48]=[x(" clear")])),_:1})]),_:1},8,["size"]),h(ft,null,{default:v(()=>z[49]||(z[49]=[x(" No files to show")])),_:1})]),_:1})),a.value?($(),te(su,{key:1,indeterminate:""})):pe("",!0),($(!0),ve(Ae,null,Gt(k.value,(Y,fe)=>($(),te(Ve,{key:fe,density:"compact",link:"",style:{"padding-top":"0"}},{default:v(()=>[h(ut,{size:r.value},{default:v(()=>[h(nt,{location:"left"},{activator:v(({props:ce})=>[h(se,ge({ref_for:!0},ce,{onClick:be=>Z(Y.path)}),{default:v(()=>[h(J,null,{default:v(()=>z[50]||(z[50]=[x(" download")])),_:1})]),_:2},1040,["onClick"])]),default:v(()=>[z[51]||(z[51]=L("span",null," Download GCode ",-1))]),_:2},1024)]),_:2},1032,["size"]),h(pu,null,{default:v(()=>[h(nt,{location:"left"},{activator:v(({props:ce})=>[h(se,ge({disabled:M(Y),icon:"",ref_for:!0},ce,{onClick:be=>Se(Y)}),{default:v(()=>[h(J,null,{default:v(()=>z[52]||(z[52]=[x(" play_arrow")])),_:1})]),_:2},1040,["disabled","onClick"])]),default:v(()=>[z[53]||(z[53]=L("span",null," Select & Print ",-1))]),_:2},1024)]),_:2},1024),h(nt,{location:"left"},{activator:v(({props:ce})=>[L("span",ge({class:{"current-file-print":M(Y)},ref_for:!0},ce),re(Y.path),17)]),default:v(()=>[L("span",null,[x(" File: "+re(Y.path)+" ",1),z[54]||(z[54]=L("br",null,null,-1)),x(" Size: "+re(Q(sO)(Y.size))+" ",1),z[55]||(z[55]=L("br",null,null,-1)),L("strong",null,re(M(Y)?"Printing":"Unused"),1)])]),_:2},1024),h(pu,null,{default:v(()=>[h(nt,{location:"left"},{activator:v(({props:ce})=>[h(se,ge({disabled:M(Y),ref_for:!0},ce,{onClick:be=>O(Y)}),{default:v(()=>[h(J,{color:"grey-lighten-1"},{default:v(()=>z[56]||(z[56]=[x(" delete")])),_:1})]),_:2},1040,["disabled","onClick"])]),default:v(()=>[z[57]||(z[57]=L("span",null," Delete file ",-1))]),_:2},1024)]),_:2},1024)]),_:2},1024))),128))]),_:1})),[[xe,{printers:[l.value]}]])]}),_:1},8,["modelValue"])}}});class cp extends gr{static async downloadYamlExport(t){const r=await(await Kn()).request({method:"POST",url:"api/server/export-printers-floors-yaml",data:t,responseType:"arraybuffer"});Ay(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 Kn()).request({method:"POST",url:"api/server/dump-fdm-monster-logs",responseType:"arraybuffer"});Ay(n.data,"logs-fdm-monster-"+Date.now()+".zip")}static async clearLogFilesOlderThanWeek(){return await this.delete("api/server/clear-outdated-fdm-monster-logs")}}class ma extends gr{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 Kn(!1,!1)).get("/api/test")}}const Em=gs("Feature",{state:()=>({features:void 0}),getters:{getFeatures(){return this.features},getFeature:e=>t=>{if(!e.features){console.warn("Feature[getFeature] store not loaded");return}return e.features[t]},hasFeature:e=>t=>{if(!e.features)return console.warn("Feature[hasFeature] 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 ma.getFeatures();this.setFeatures(e)}catch{this.features={}}},setFeatures(e){this.features=e}}}),wO=Symbol.for("vuetify:selection-control-group"),Q0=de({color:String,disabled:{type:Boolean,default:null},defaultsTarget:String,error:Boolean,id:String,inline:Boolean,falseIcon:He,trueIcon:He,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:as},...Ue(),...Ar(),...Lt()},"SelectionControlGroup"),aG=de({...Q0({defaultsTarget:"VSelectionControl"})},"VSelectionControlGroup"),lG=ke()({name:"VSelectionControlGroup",props:aG(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const r=st(e,"modelValue"),s=ms(),i=ae(()=>e.id||`v-selection-control-group-${s}`),o=ae(()=>e.name||i.value),a=new Set;return Kt(wO,{modelValue:r,forceUpdate:()=>{a.forEach(l=>l())},onForceUpdate:l=>{a.add(l),yn(()=>{a.delete(l)})}}),Ir({[e.defaultsTarget]:{color:ae(()=>e.color),disabled:ae(()=>e.disabled),density:ae(()=>e.density),error:ae(()=>e.error),inline:ae(()=>e.inline),modelValue:r,multiple:ae(()=>!!e.multiple||e.multiple==null&&Array.isArray(r.value)),name:o,falseIcon:ae(()=>e.falseIcon),trueIcon:ae(()=>e.trueIcon),readonly:ae(()=>e.readonly),ripple:ae(()=>e.ripple),type:ae(()=>e.type),valueComparator:ae(()=>e.valueComparator)}}),Oe(()=>{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)])}),{}}}),Cm=de({label:String,baseColor:String,trueValue:null,falseValue:null,value:null,...Ue(),...Q0()},"VSelectionControl");function uG(e){const t=Qe(wO,void 0),{densityClasses:n}=ys(e),r=st(e,"modelValue"),s=A(()=>e.trueValue!==void 0?e.trueValue:e.value!==void 0?e.value:!0),i=A(()=>e.falseValue!==void 0?e.falseValue:!1),o=A(()=>!!e.multiple||e.multiple==null&&Array.isArray(r.value)),a=A({get(){const p=t?t.modelValue.value:r.value;return o.value?An(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?[...An(r.value),g]:An(r.value).filter(y=>!e.valueComparator(y,s.value))),t?t.modelValue.value=m:r.value=m}}),{textColorClasses:l,textColorStyles:u}=As(()=>{if(!(e.error||e.disabled))return a.value?e.color:e.baseColor}),{backgroundColorClasses:c,backgroundColorStyles:d}=fr(()=>a.value&&!e.error&&!e.disabled?e.color:e.baseColor),f=A(()=>a.value?e.trueIcon:e.falseIcon);return{group:t,densityClasses:n,trueValue:s,falseValue:i,model:a,textColorClasses:l,textColorStyles:u,backgroundColorClasses:c,backgroundColorStyles:d,icon:f}}const Ga=ke()({name:"VSelectionControl",directives:{Ripple:Pu},inheritAttrs:!1,props:Cm(),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:c,backgroundColorStyles:d,trueValue:f}=uG(e),p=ms(),g=Ie(!1),m=Ie(!1),y=j(),w=ae(()=>e.id||`input-${p}`),b=ae(()=>!e.disabled&&!e.readonly);s==null||s.onForceUpdate(()=>{y.value&&(y.value.checked=a.value)});function k(P){b.value&&(g.value=!0,Lh(P.target,":focus-visible")!==!1&&(m.value=!0))}function C(){g.value=!1,m.value=!1}function _(P){P.stopPropagation()}function T(P){if(!b.value){y.value&&(y.value.checked=a.value);return}e.readonly&&s&&Mt(()=>s.forceUpdate()),a.value=P.target.checked}return Oe(()=>{var O,R;const P=r.label?r.label({label:e.label,props:{for:w.value}}):e.label,[S,E]=Ja(n),I=h("input",ge({ref:y,checked:a.value,disabled:!!e.disabled,id:w.value,onBlur:C,onFocus:k,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},E),null);return h("div",ge({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]},S,{style:e.style}),[h("div",{class:["v-selection-control__wrapper",l.value],style:u.value},[(O=r.default)==null?void 0:O.call(r,{backgroundColorClasses:c,backgroundColorStyles:d}),Bt(h("div",{class:["v-selection-control__input"]},[((R=r.input)==null?void 0:R.call(r,{model:a,textColorClasses:l,textColorStyles:u,backgroundColorClasses:c,backgroundColorStyles:d,inputNode:I,icon:o.value,props:{onFocus:k,onBlur:C,id:w.value}}))??h(Ae,null,[o.value&&h(J,{key:"icon",icon:o.value},null),I])]),[[hr("ripple"),e.ripple&&[!e.disabled&&!e.readonly,null,["center","circle"]]]])]),P&&h(X0,{for:w.value,onClick:_},{default:()=>[P]})])}),{isFocused:g,input:y}}}),SO=de({indeterminate:Boolean,indeterminateIcon:{type:He,default:"$checkboxIndeterminate"},...Cm({falseIcon:"$checkboxOff",trueIcon:"$checkboxOn"})},"VCheckboxBtn"),gu=ke()({name:"VCheckboxBtn",props:SO(),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=ae(()=>r.value?e.indeterminateIcon:e.falseIcon),a=ae(()=>r.value?e.indeterminateIcon:e.trueIcon);return Oe(()=>{const l=Ms(Ga.filterProps(e),["modelValue"]);return h(Ga,ge(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)}),{}}}),cG=de({...ol(),...Ms(SO(),["inline"])},"VCheckbox"),mn=ke()({name:"VCheckbox",inheritAttrs:!1,props:cG(),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=ms();return Oe(()=>{const[u,c]=Ja(n),d=fs.filterProps(e),f=gu.filterProps(e);return h(fs,ge({class:["v-checkbox",e.class]},u,d,{modelValue:s.value,"onUpdate:modelValue":p=>s.value=p,id:e.id||`checkbox-${l}`,focused:i.value,style:e.style}),{...r,default:p=>{let{id:g,messagesId:m,isDisabled:y,isReadonly:w,isValid:b}=p;return h(gu,ge(f,{id:g.value,"aria-describedby":m.value,disabled:y.value,readonly:w.value},c,{error:b.value===!1,modelValue:s.value,"onUpdate:modelValue":k=>s.value=k,onFocus:o,onBlur:a}),r)}})}),{}}}),dG=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=>An(e).every(t=>t!=null&&typeof t=="object")},...xm({clearable:!0})},"VFileInput"),_O=ke()({name:"VFileInput",inheritAttrs:!1,props:dG(),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}=Gr(),o=st(e,"modelValue",e.modelValue,M=>An(M),M=>!e.multiple&&Array.isArray(M)?M[0]:M),{isFocused:a,focus:l,blur:u}=Uu(e),c=A(()=>typeof e.showSize!="boolean"?e.showSize:void 0),d=A(()=>(o.value??[]).reduce((M,D)=>{let{size:F=0}=D;return M+F},0)),f=A(()=>VS(d.value,c.value)),p=A(()=>(o.value??[]).map(M=>{const{name:D="",size:F=0}=M;return e.showSize?`${D} (${VS(F,c.value)})`:D})),g=A(()=>{var D;const M=((D=o.value)==null?void 0:D.length)??0;return e.showSize?i(e.counterSizeString,M,f.value):i(e.counterString,M)}),m=j(),y=j(),w=j(),b=ae(()=>a.value||e.active),k=A(()=>["plain","underlined"].includes(e.variant)),C=Ie(!1);function _(){var M;w.value!==document.activeElement&&((M=w.value)==null||M.focus()),a.value||l()}function T(M){var D;(D=w.value)==null||D.click()}function P(M){r("mousedown:control",M)}function S(M){var D;(D=w.value)==null||D.click(),r("click:control",M)}function E(M){M.stopPropagation(),_(),Mt(()=>{o.value=[],qp(e["onClick:clear"],M)})}function I(M){M.preventDefault(),M.stopImmediatePropagation(),C.value=!0}function O(M){M.preventDefault(),C.value=!1}function R(M){var F,U;if(M.preventDefault(),M.stopImmediatePropagation(),C.value=!1,!((U=(F=M.dataTransfer)==null?void 0:F.files)!=null&&U.length)||!w.value)return;const D=new DataTransfer;for(const K of M.dataTransfer.files)D.items.add(K);w.value.files=D.files,w.value.dispatchEvent(new Event("change",{bubbles:!0}))}return Ee(o,M=>{(!Array.isArray(M)||!M.length)&&w.value&&(w.value.value="")}),Oe(()=>{const M=!!(s.counter||e.counter),D=!!(M||s.details),[F,U]=Ja(n),{modelValue:K,...X}=fs.filterProps(e),H=mu.filterProps(e);return h(fs,ge({ref:m,modelValue:e.multiple?o.value:o.value[0],class:["v-file-input",{"v-file-input--chips":!!e.chips,"v-file-input--dragging":C.value,"v-file-input--hide":e.hideInput,"v-input--plain-underlined":k.value},e.class],style:e.style,"onClick:prepend":T},F,X,{centerAffix:!k.value,focused:a.value}),{...s,default:B=>{let{id:ee,isDisabled:q,isDirty:G,isReadonly:le,isValid:ie}=B;return h(mu,ge({ref:y,"prepend-icon":e.prependIcon,onMousedown:P,onClick:S,"onClick:clear":E,"onClick:prependInner":e["onClick:prependInner"],"onClick:appendInner":e["onClick:appendInner"]},H,{id:ee.value,active:b.value||G.value,dirty:G.value||e.dirty,disabled:q.value,focused:a.value,error:ie.value===!1,onDragover:I,onDrop:R}),{...s,default:Se=>{var ne;let{props:{class:Z,...he}}=Se;return h(Ae,null,[h("input",ge({ref:w,type:"file",readonly:le.value,disabled:q.value,multiple:e.multiple,name:e.name,onClick:z=>{z.stopPropagation(),le.value&&z.preventDefault(),_()},onChange:z=>{if(!z.target)return;const xe=z.target;o.value=[...xe.files??[]]},onDragleave:O,onFocus:_,onBlur:u},he,U),null),h("div",{class:Z},[!!((ne=o.value)!=null&&ne.length)&&!e.hideInput&&(s.selection?s.selection({fileNames:p.value,totalBytes:d.value,totalBytesReadable:f.value}):e.chips?p.value.map(z=>h(_n,{key:z,size:"small",text:z},null)):p.value.join(", "))])])}})},details:D?B=>{var ee,q;return h(Ae,null,[(ee=s.details)==null?void 0:ee.call(s,B),M&&h(Ae,null,[h("span",null,null),h(Y0,{active:!!((q=o.value)!=null&&q.length),value:g.value,disabled:e.disabled},s.counter)])])}:void 0})}),Xi({},m,y,w)}}),fG=de({...Cm({falseIcon:"$radioOff",trueIcon:"$radioOn"})},"VRadio"),zy=ke()({name:"VRadio",props:fG(),setup(e,t){let{slots:n}=t;return Oe(()=>{const r=Ga.filterProps(e);return h(Ga,ge(r,{class:["v-radio",e.class],style:e.style,type:"radio"}),n)}),{}}}),hG=de({height:{type:[Number,String],default:"auto"},...ol(),...Ms(Q0(),["multiple"]),trueIcon:{type:He,default:"$radioOn"},falseIcon:{type:He,default:"$radioOff"},type:{type:String,default:"radio"}},"VRadioGroup"),kO=ke()({name:"VRadioGroup",inheritAttrs:!1,props:hG(),emits:{"update:modelValue":e=>!0},setup(e,t){let{attrs:n,slots:r}=t;const s=ms(),i=A(()=>e.id||`radio-group-${s}`),o=st(e,"modelValue");return Oe(()=>{const[a,l]=Ja(n),u=fs.filterProps(e),c=Ga.filterProps(e),d=r.label?r.label({label:e.label,props:{for:i.value}}):e.label;return h(fs,ge({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(Ae,null,[d&&h(X0,{id:p.value},{default:()=>[d]}),h(lG,ge(c,{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":d?p.value:void 0,multiple:!1},l,{modelValue:o.value,"onUpdate:modelValue":w=>o.value=w}),r)])}})}),{}}}),pG=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(),...xm()},"VTextarea"),xO=ke()({name:"VTextarea",directives:{Intersect:z0},inheritAttrs:!1,props:pG(),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=A(()=>typeof e.counterValue=="function"?e.counterValue(i.value):(i.value||"").toString().length),c=A(()=>{if(n.maxlength)return n.maxlength;if(!(!e.counter||typeof e.counter!="number"&&typeof e.counter!="string"))return e.counter});function d(O,R){var M,D;!e.autofocus||!O||(D=(M=R[0].target)==null?void 0:M.focus)==null||D.call(M)}const f=j(),p=j(),g=Ie(""),m=j(),y=A(()=>e.persistentPlaceholder||o.value||e.active);function w(){var O;m.value!==document.activeElement&&((O=m.value)==null||O.focus()),o.value||a()}function b(O){w(),r("click:control",O)}function k(O){r("mousedown:control",O)}function C(O){O.stopPropagation(),w(),Mt(()=>{i.value="",qp(e["onClick:clear"],O)})}function _(O){var M;const R=O.target;if(i.value=R.value,(M=e.modelModifiers)!=null&&M.trim){const D=[R.selectionStart,R.selectionEnd];Mt(()=>{R.selectionStart=D[0],R.selectionEnd=D[1]})}}const T=j(),P=j(Number(e.rows)),S=A(()=>["plain","underlined"].includes(e.variant));On(()=>{e.autoGrow||(P.value=Number(e.rows))});function E(){e.autoGrow&&Mt(()=>{if(!T.value||!p.value)return;const O=getComputedStyle(T.value),R=getComputedStyle(p.value.$el),M=parseFloat(O.getPropertyValue("--v-field-padding-top"))+parseFloat(O.getPropertyValue("--v-input-padding-top"))+parseFloat(O.getPropertyValue("--v-field-padding-bottom")),D=T.value.scrollHeight,F=parseFloat(O.lineHeight),U=Math.max(parseFloat(e.rows)*F+M,parseFloat(R.getPropertyValue("--v-input-control-height"))),K=parseFloat(e.maxRows)*F+M||1/0,X=Cr(D??0,U,K);P.value=Math.floor((X-M)/F),g.value=Ne(X)})}St(E),Ee(i,E),Ee(()=>e.rows,E),Ee(()=>e.maxRows,E),Ee(()=>e.density,E);let I;return Ee(T,O=>{O?(I=new ResizeObserver(E),I.observe(T.value)):I==null||I.disconnect()}),Cn(()=>{I==null||I.disconnect()}),Oe(()=>{const O=!!(s.counter||e.counter||e.counterValue),R=!!(O||s.details),[M,D]=Ja(n),{modelValue:F,...U}=fs.filterProps(e),K=mu.filterProps(e);return h(fs,ge({ref:f,modelValue:i.value,"onUpdate:modelValue":X=>i.value=X,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":S.value},e.class],style:e.style},M,U,{centerAffix:P.value===1&&!S.value,focused:o.value}),{...s,default:X=>{let{id:H,isDisabled:B,isDirty:ee,isReadonly:q,isValid:G}=X;return h(mu,ge({ref:p,style:{"--v-textarea-control-height":g.value},onClick:b,onMousedown:k,"onClick:clear":C,"onClick:prependInner":e["onClick:prependInner"],"onClick:appendInner":e["onClick:appendInner"]},K,{id:H.value,active:y.value||ee.value,centerAffix:P.value===1&&!S.value,dirty:ee.value||e.dirty,disabled:B.value,focused:o.value,error:G.value===!1}),{...s,default:le=>{let{props:{class:ie,...Se}}=le;return h(Ae,null,[e.prefix&&h("span",{class:"v-text-field__prefix"},[e.prefix]),Bt(h("textarea",ge({ref:m,class:ie,value:i.value,onInput:_,autofocus:e.autofocus,readonly:q.value,disabled:B.value,placeholder:e.placeholder,rows:e.rows,name:e.name,onFocus:w,onBlur:l},Se,D),null),[[hr("intersect"),{handler:d},null,{once:!0}]]),e.autoGrow&&Bt(h("textarea",{class:[ie,"v-textarea__sizer"],id:`${Se.id}-sizer`,"onUpdate:modelValue":Z=>i.value=Z,ref:T,readonly:!0,"aria-hidden":"true"},null),[[p$,i.value]]),e.suffix&&h("span",{class:"v-text-field__suffix"},[e.suffix])])}})},details:R?X=>{var H;return h(Ae,null,[(H=s.details)==null?void 0:H.call(s,X),O&&h(Ae,null,[h("span",null,null),h(Y0,{active:e.persistentCounter||o.value,value:u.value,max:c.value,disabled:e.disabled},s.counter)])])}:void 0})}),Xi({},f,p,m)}}),mG={key:0,class:"pl-2"},gG={key:1},vG=Le({__name:"YamlImportExportDialog",setup(e){const t=Em(),n=tn(nn.YamlImportExport),r=Dt(),s=j(""),i=j(""),o=j(0),a=j(!0),l=j(!0),u=j(!0),c=j(!0),d=j(void 0),f=j(""),p=A(()=>!t.hasFeature("printerGroupsApi")),g=A(()=>!!d.value),m=A(()=>o.value===0),y=async()=>{await t.loadFeatures(),u.value=t.hasFeature("printerGroupsApi")},w=async()=>{d.value=void 0,s.value="",i.value="",f.value=""},b=async()=>{l.value&&(c.value=!0),await cp.downloadYamlExport({exportPrinters:c.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=""},k=async()=>{if(s.value="",i.value="",!d.value){s.value="The import file was not specified";return}try{await cp.uploadAndImportYaml(d.value),d.value=void 0,r.openInfoMessage({title:"Imported the YAML file"}),C()}catch(_){s.value="An error occurred uring import",i.value=_.message.toString(),d.value=void 0}},C=()=>{d.value=void 0,s.value="",i.value="",f.value="",n.closeDialog()};return(_,T)=>{const P=hi;return $(),te(P,{id:Q(n).dialogId,"max-width":"700px",onEscape:T[10]||(T[10]=S=>C()),onOpened:w,onBeforeOpened:y},{default:v(()=>[h(vt,{class:"pa-4"},{default:v(()=>[h(sn,null,{default:v(()=>T[11]||(T[11]=[L("span",{class:"text-h5"}," YAML export and import ",-1)])),_:1}),h(en,null,{default:v(()=>[T[18]||(T[18]=L("div",null,"Choose mode:",-1)),h(rt,null,{default:v(()=>[T[12]||(T[12]=L("br",null,null,-1)),h(kO,{modelValue:Q(o),"onUpdate:modelValue":T[0]||(T[0]=S=>et(o)?o.value=S:null),class:"ml-3",inline:""},{default:v(()=>[h(zy,{value:0,label:"Import YAML"}),h(zy,{value:1,label:"Export YAML"})]),_:1},8,["modelValue"])]),_:1}),L("div",null,[Q(m)?($(),ve("div",mG,[h(_O,{modelValue:Q(d),"onUpdate:modelValue":T[1]||(T[1]=S=>et(d)?d.value=S:null),accept:".yaml",label:"Select a YAML file for import *"},null,8,["modelValue"])])):($(),ve("div",gG,[h(mn,{modelValue:Q(a),"onUpdate:modelValue":T[2]||(T[2]=S=>et(a)?a.value=S:null),class:"pa-0 ma-0 mt-2 ml-2",label:"Include floors"},null,8,["modelValue"]),h(mn,{modelValue:Q(u),"onUpdate:modelValue":T[3]||(T[3]=S=>et(u)?u.value=S:null),disabled:Q(p),class:"pa-0 ma-0 mt-2 ml-2",label:"Include groups"},null,8,["modelValue","disabled"]),h(mn,{modelValue:Q(c),"onUpdate:modelValue":T[4]||(T[4]=S=>et(c)?c.value=S:null),class:"pa-0 ma-0 ml-2",label:"Include printers"},null,8,["modelValue"]),h(mn,{modelValue:Q(l),"onUpdate:modelValue":T[5]||(T[5]=S=>et(l)?l.value=S:null),class:"pa-0 ma-0 ml-2",label:"Include grid positions (auto-includes printers)"},null,8,["modelValue"]),T[13]||(T[13]=x(" Include notes (for yourself): ")),h(xO,{modelValue:Q(f),"onUpdate:modelValue":T[6]||(T[6]=S=>et(f)?f.value=S:null),rows:"1"},null,8,["modelValue"])])),Q(m)?pe("",!0):($(),te(se,{key:2,onClick:T[7]||(T[7]=S=>b())},{default:v(()=>[h(J,null,{default:v(()=>T[14]||(T[14]=[x("download")])),_:1}),T[15]||(T[15]=x(" Export YAML file "))]),_:1})),Q(m)?($(),te(se,{key:3,disabled:!Q(g),onClick:T[8]||(T[8]=S=>k())},{default:v(()=>[h(J,null,{default:v(()=>T[16]||(T[16]=[x("upload")])),_:1}),T[17]||(T[17]=x(" Import YAML data "))]),_:1},8,["disabled"])):pe("",!0)])]),_:1}),h(Mn,null,{default:v(()=>[T[20]||(T[20]=L("em",{class:"text-red"}," * indicates required field ",-1)),h(Sn),h(se,{variant:"text",onClick:T[9]||(T[9]=S=>C())},{default:v(()=>T[19]||(T[19]=[x(" Close ")])),_:1})]),_:1})]),_:1})]),_:1},8,["id"])}}}),yG="/assets/octofarm-printer-export-Dw0Zh14I.gif",J0=Symbol.for("vuetify:v-stepper"),EO=de({color:String,disabled:{type:[Boolean,String],default:!1},prevText:{type:String,default:"$vuetify.stepper.prev"},nextText:{type:String,default:"$vuetify.stepper.next"}},"VStepperActions"),bG=ke()({name:"VStepperActions",props:EO(),emits:{"click:prev":()=>!0,"click:next":()=>!0},setup(e,t){let{emit:n,slots:r}=t;const{t:s}=Gr();function i(){n("click:prev")}function o(){n("click:next")}return Oe(()=>{const a={onClick:i},l={onClick:o};return h("div",{class:"v-stepper-actions"},[h(Ot,{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(se,a,null)]}}),h(Ot,{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(se,l,null)]}})])}),{}}}),Z0=ku("v-stepper-header"),wG=de({color:String,title:String,subtitle:String,complete:Boolean,completeIcon:{type:He,default:"$complete"},editable:Boolean,editIcon:{type:He,default:"$edit"},error:Boolean,errorIcon:{type:He,default:"$error"},icon:He,ripple:{type:[Boolean,Object],default:!0},rules:{type:Array,default:()=>[]}},"StepperItem"),SG=de({...wG(),...Cd()},"VStepperItem"),ch=ke()({name:"VStepperItem",directives:{Ripple:Pu},props:SG(),emits:{"group:selected":e=>!0},setup(e,t){let{slots:n}=t;const r=Td(e,J0,!0),s=A(()=>(r==null?void 0:r.value.value)??e.value),i=A(()=>e.rules.every(f=>f()===!0)),o=A(()=>!e.disabled&&e.editable),a=A(()=>!e.disabled&&e.editable),l=A(()=>e.error||!i.value),u=A(()=>e.complete||e.rules.length>0&&i.value),c=A(()=>l.value?e.errorIcon:u.value?e.completeIcon:r.isSelected.value&&e.editable?e.editIcon:e.icon),d=A(()=>({canEdit:a.value,hasError:l.value,hasCompleted:u.value,title:e.title,subtitle:e.subtitle,step:s.value,value:e.value}));return Oe(()=>{var y,w,b;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 Bt(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,type:"button",onClick:m},[o.value&&Ho(!0,"v-stepper-item"),h(ut,{key:"stepper-avatar",class:"v-stepper-item__avatar",color:f?e.color:void 0,size:24},{default:()=>{var k;return[((k=n.icon)==null?void 0:k.call(n,d.value))??(c.value?h(J,{icon:c.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,d.value))??e.title]),g&&h("div",{key:"subtitle",class:"v-stepper-item__subtitle"},[((w=n.subtitle)==null?void 0:w.call(n,d.value))??e.subtitle]),(b=n.default)==null?void 0:b.call(n,d.value)])]),[[hr("ripple"),e.ripple&&e.editable,null]])}),{}}}),_G=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 kG(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 xG(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}),_G(t)}function EG(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 CG(){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=>kG(n,t),touchend:n=>xG(n,t),touchmove:n=>EG(n,t)}}function TG(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=CG(t.value);r._touchHandlers=r._touchHandlers??Object.create(null),r._touchHandlers[i]=o,OT(o).forEach(l=>{r.addEventListener(l,o[l],s)})}function PG(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];OT(s).forEach(a=>{n.removeEventListener(a,s[a])}),delete n._touchHandlers[r]}const CO={mounted:TG,unmounted:PG},TO=Symbol.for("vuetify:v-window"),PO=Symbol.for("vuetify:v-window-group"),RO=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"},...Ue(),...yt(),...Lt()},"VWindow"),xk=ke()({name:"VWindow",directives:{Touch:CO},props:RO(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const{themeClasses:r}=Zt(e),{isRtl:s}=Dr(),{t:i}=Gr(),o=xu(e,PO),a=j(),l=A(()=>s.value?!e.reverse:e.reverse),u=Ie(!1),c=A(()=>{const C=e.direction==="vertical"?"y":"x",T=(l.value?!u.value:u.value)?"-reverse":"";return`v-window-${C}${T}-transition`}),d=Ie(0),f=j(void 0),p=A(()=>o.items.value.findIndex(C=>o.selected.value.includes(C.id)));Ee(p,(C,_)=>{const T=o.items.value.length,P=T-1;T<=2?u.value=C<_:C===P&&_===0?u.value=!0:C===0&&_===P?u.value=!1:u.value=C<_}),Kt(TO,{transition:c,isReversed:u,transitionCount:d,transitionHeight:f,rootRef:a});const g=ae(()=>e.continuous||p.value!==0),m=ae(()=>e.continuous||p.value!==o.items.value.length-1);function y(){g.value&&o.prev()}function w(){m.value&&o.next()}const b=A(()=>{const C=[],_={icon:s.value?e.nextIcon:e.prevIcon,class:`v-window__${l.value?"right":"left"}`,onClick:o.prev,"aria-label":i("$vuetify.carousel.prev")};C.push(g.value?n.prev?n.prev({props:_}):h(se,_,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 C.push(m.value?n.next?n.next({props:T}):h(se,T,null):h("div",null,null)),C}),k=A(()=>e.touch===!1?e.touch:{...{left:()=>{l.value?y():w()},right:()=>{l.value?w():y()},start:_=>{let{originalEvent:T}=_;T.stopPropagation()}},...e.touch===!0?{}:e.touch});return Oe(()=>Bt(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 C,_;return[h("div",{class:"v-window__container",style:{height:f.value}},[(C=n.default)==null?void 0:C.call(n,{group:o}),e.showArrows!==!1&&h("div",{class:"v-window__controls"},[b.value])]),(_=n.additional)==null?void 0:_.call(n,{group:o})]}}),[[hr("touch"),k.value]])),{group:o}}}),RG=de({...Ms(RO(),["continuous","nextIcon","prevIcon","showArrows","touch","mandatory"])},"VStepperWindow"),IO=ke()({name:"VStepperWindow",props:RG(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const r=Qe(J0,null),s=st(e,"modelValue"),i=A({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 Oe(()=>{const o=xk.filterProps(e);return h(xk,ge({_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)}),{}}}),AO=de({reverseTransition:{type:[Boolean,String],default:void 0},transition:{type:[Boolean,String],default:void 0},...Ue(),...Cd(),...xP()},"VWindowItem"),Ek=ke()({name:"VWindowItem",directives:{Touch:CO},props:AO(),emits:{"group:selected":e=>!0},setup(e,t){let{slots:n}=t;const r=Qe(TO),s=Td(e,PO),{isBooted:i}=jd();if(!r||!s)throw new Error("[Vuetify] VWindowItem must be used inside VWindow");const o=Ie(!1),a=A(()=>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 c(){l()}function d(g){o.value&&Mt(()=>{!a.value||!o.value||!r||(r.transitionHeight.value=Ne(g.clientHeight))})}const f=A(()=>{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:c,onBeforeLeave:u,onAfterLeave:l,onLeaveCancelled:c,onEnter:d}:!1}),{hasContent:p}=EP(e,s.isSelected);return Oe(()=>h(si,{transition:f.value,disabled:!i.value},{default:()=>{var g;return[Bt(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))]),[[Yi,s.isSelected.value]])]}})),{groupItem:s}}}),IG=de({...AO()},"VStepperWindowItem"),dh=ke()({name:"VStepperWindowItem",props:IG(),setup(e,t){let{slots:n}=t;return Oe(()=>{const r=Ek.filterProps(e);return h(Ek,ge({_as:"VStepperWindowItem"},r,{class:["v-stepper-window-item",e.class],style:e.style}),n)}),{}}}),OO=de({color:String,...vs(),...Ue(),...Or(),...bs(),...jo(),...Cu(),...Dn(),...yt(),...Lt()},"VSheet"),dp=ke()({name:"VSheet",props:OO(),setup(e,t){let{slots:n}=t;const{themeClasses:r}=Zt(e),{backgroundColorClasses:s,backgroundColorStyles:i}=fr(()=>e.color),{borderClasses:o}=Ds(e),{dimensionStyles:a}=Mr(e),{elevationClasses:l}=Ls(e),{locationStyles:u}=el(e),{positionClasses:c}=Tu(e),{roundedClasses:d}=zn(e);return Oe(()=>h(e.tag,{class:["v-sheet",r.value,s.value,o.value,l.value,c.value,d.value,e.class],style:[i.value,a.value,u.value,e.style]},n)),{}}}),AG=de({altLabels:Boolean,bgColor:String,completeIcon:He,editIcon:He,editable:Boolean,errorIcon:He,hideActions:Boolean,items:{type:Array,default:()=>[]},itemTitle:{type:String,default:"title"},itemValue:{type:String,default:"value"},nonLinear:Boolean,flat:Boolean,...tl()},"Stepper"),OG=de({...AG(),...Ed({mandatory:"force",selectedClass:"v-stepper-item--selected"}),...OO(),...xd(EO(),["prevText","nextText"])},"VStepper"),MO=ke()({name:"VStepper",props:OG(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const{items:r,next:s,prev:i,selected:o}=xu(e,J0),{displayClasses:a,mobile:l}=fi(e),{completeIcon:u,editIcon:c,errorIcon:d,color:f,editable:p,prevText:g,nextText:m}=Qa(e),y=A(()=>e.items.map((k,C)=>{const _=Fn(k,e.itemTitle,k),T=Fn(k,e.itemValue,C+1);return{title:_,value:T,raw:k}})),w=A(()=>r.value.findIndex(k=>o.value.includes(k.id))),b=A(()=>e.disabled?e.disabled:w.value===0?"prev":w.value===r.value.length-1?"next":!1);return Ir({VStepperItem:{editable:p,errorIcon:d,completeIcon:u,editIcon:c,prevText:g,nextText:m},VStepperActions:{color:f,disabled:b,prevText:g,nextText:m}}),Oe(()=>{const k=dp.filterProps(e),C=!!(n.header||e.items.length),_=e.items.length>0,T=!e.hideActions&&!!(_||n.actions);return h(dp,ge(k,{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 P,S;return[C&&h(Z0,{key:"stepper-header"},{default:()=>[y.value.map((E,I)=>{let{raw:O,...R}=E;return h(Ae,null,[!!I&&h(dn,null,null),h(ch,R,{default:n[`header-item.${R.value}`]??n.header,icon:n.icon,title:n.title,subtitle:n.subtitle})])})]}),_&&h(IO,{key:"stepper-window"},{default:()=>[y.value.map(E=>h(dh,{value:E.value},{default:()=>{var I,O;return((I=n[`item.${E.value}`])==null?void 0:I.call(n,E))??((O=n.item)==null?void 0:O.call(n,E))}}))]}),(P=n.default)==null?void 0:P.call(n,{prev:i,next:s}),T&&(((S=n.actions)==null?void 0:S.call(n,{next:s,prev:i}))??h(bG,{key:"stepper-actions","onClick:prev":i,"onClick:next":s},n))]}})}),{prev:i,next:s}}}),MG={class:"my-3"},DG={key:0},LG={key:1},$G={class:"my-2"},FG={key:0},NG={class:"mr-4"},BG={class:"mr-4"},VG={class:"mr-4"},UG={class:"my-3"},zG={key:0,class:"mb-5 mt-10"},HG={key:1},jG={class:"ml-5 mt-2"},qG={key:0,class:"ml-5 mt-2"},WG=Le({__name:"OctoFarmImportDialog",setup(e){const t=j(),n=j(!1),r=j(!1),s=j(""),i=j(""),o=j(),a=j(0),l=j([]),u=j([]),c=j(!1),d=tn(nn.ImportOctoFarmDialog);function f(){}async function p(){}const g=async()=>{if(!o.value){n.value=!1;return}const C=JSON.parse(await o.value.text());if(!C||!Array.isArray(C))return[];if(!(C!=null&&C.length))return[];let _=C;C.length===1&&Array.isArray(C[0])&&(_=C[0]),_=_.map(S=>{var E,I;return S._id&&delete S._id,S.apikey&&(S.apiKey=S.apikey,delete S.apikey),S.settingsApperance&&(S.settingsAppearance=S.settingsApperance,delete S.settingsApperance),(E=S.settingsAppearance)!=null&&E.name?(S.name=(I=S.settingsAppearance)==null?void 0:I.name,delete S.settingsAppearance):S.name=S.printerURL,{enabled:!S.disabled,apiKey:S.apiKey,printerURL:S.printerURL,name:S.name}});let T=!1;const P=[];s.value="",i.value="";for(const S of _){const E=Object.keys(S);E.includes("enabled")&&(S.enabled===!1||S.enabled===!0)&&E.includes("apiKey")&&S.apiKey.length&&E.includes("printerURL")&&S.printerURL.length&&E.includes("name")&&S.name||(P.push(S.name||S.printerURL||"No name known for printer"),T||(T=!0))}return n.value=!T,T&&(s.value="Imported file failed the validation step",i.value="These printers failed validation: "+P.join(", ")),_},m=async()=>{const C=await g();C!=null&&C.length&&(u.value=[...Array(C.length)].map((_,T)=>T),l.value=C||[],t.value=2)},y=()=>{u.value.length?u.value=[]:u.value=[...Array(l.value.length)].map((_,T)=>T)},w=async()=>{var C;a.value=((C=await g())==null?void 0:C.length)||0},b=async()=>{t.value=3;const C=l.value.filter((_,T)=>u.value.includes(T));if(C!=null&&C.length)try{await Qt.batchImportPrinters(C),c.value=!0}catch(_){c.value=!1,o.value=void 0,s.value="An error occurred",i.value=_.message.toString()}},k=()=>{o.value=void 0,d.closeDialog(),t.value=1};return(C,_)=>{const T=In("v-subheader"),P=In("v-list-item-content"),S=In("v-list-item-group"),E=hi;return $(),te(E,{id:Q(d).dialogId,"max-width":"700px",onBeforeOpened:_[8]||(_[8]=I=>void 0),onEscape:_[9]||(_[9]=I=>k()),onOpened:_[10]||(_[10]=I=>p())},{default:v(()=>[h(vt,{class:"pa-4"},{default:v(()=>[h(sn,null,{default:v(()=>_[11]||(_[11]=[L("span",{class:"text-h5"}," Import OctoFarm Printers ",-1)])),_:1}),h(en,null,{default:v(()=>[h(rt,null,{default:v(()=>[h(ze,{cols:"12"},{default:v(()=>[h(MO,{modelValue:Q(t),"onUpdate:modelValue":_[6]||(_[6]=I=>et(t)?t.value=I:null),"non-linear":""},{default:v(()=>[h(Z0,null,{default:v(()=>[h(ch,{complete:Q(t)>1,value:"1",editable:""},{default:v(()=>_[12]||(_[12]=[x(" Export PrintersDB from OctoFarm ")])),_:1},8,["complete"]),h(ch,{complete:Q(t)>2,value:"2",editable:""},{default:v(()=>_[13]||(_[13]=[x(" Show printers & decide ")])),_:1},8,["complete"]),h(ch,{complete:Q(t)>3,value:"3",editable:""},{default:v(()=>_[14]||(_[14]=[x(" Import printers into FDM Monster ")])),_:1},8,["complete"])]),_:1}),h(IO,null,{default:v(()=>[h(dh,{value:"1"},{default:v(()=>[h(_O,{class:"mt-2",style:{"max-width":"400px"},modelValue:Q(o),"onUpdate:modelValue":_[0]||(_[0]=I=>et(o)?o.value=I:null),filled:"",accept:".json",clearable:"",label:"Upload PrintersDB.json file",onChange:_[1]||(_[1]=I=>w())},null,8,["modelValue"]),L("ol",null,[L("li",null,[L("h4",null,[h(J,null,{default:v(()=>_[15]||(_[15]=[x("navigation")])),_:1}),_[16]||(_[16]=x(" Go to your OctoFarm System page "))])]),L("li",null,[L("h4",null,[h(J,null,{default:v(()=>_[17]||(_[17]=[x("mouse")])),_:1}),_[18]||(_[18]=x(" Click 'Database' "))])]),L("li",null,[L("h4",null,[h(J,null,{default:v(()=>_[19]||(_[19]=[x("mouse")])),_:1}),_[20]||(_[20]=x(" Click the button 'Export Printers' "))])]),L("li",null,[L("h4",null,[h(J,null,{default:v(()=>_[21]||(_[21]=[x("upload")])),_:1}),_[22]||(_[22]=x(" Upload 'PrintersDB.json' above "))])])]),L("div",MG,[h(J,{class:"pr-2"},{default:v(()=>_[23]||(_[23]=[x("info")])),_:1}),_[25]||(_[25]=x(' OctoFarm printers should be exported as a JSON file. Please upload the correct "PrintersDB.json" database file using the steps provided. ')),h(se,{small:"",class:"ml-2",color:"success",onClick:_[2]||(_[2]=I=>r.value=!Q(r))},{default:v(()=>[h(J,{class:"pr-2"},{default:v(()=>_[24]||(_[24]=[x("gif")])),_:1}),Q(r)?($(),ve("span",LG,"Hide GIF")):($(),ve("span",DG,"Show GIF"))]),_:1})]),Q(r)?($(),te(ds,{key:0,class:"my-4",src:Q(yG),style:{border:"3px solid dimgray","max-width":"800px"},elevation:"10"},null,8,["src"])):pe("",!0),_[27]||(_[27]=L("br",null,null,-1)),h(se,{color:"primary",onClick:_[3]||(_[3]=I=>m()),disabled:!Q(o)},{default:v(()=>_[26]||(_[26]=[x(" Validate ")])),_:1},8,["disabled"])]),_:1}),h(dh,{value:"2"},{default:v(()=>{var I;return[L("div",$G,[h(J,{class:"pr-2"},{default:v(()=>_[28]||(_[28]=[x("info")])),_:1}),x(" Import state: "+re(Q(n)?"success":"failed")+" - "+re(Q(a))+" printer(s) found ",1)]),Q(s)?($(),te(fn,{key:0,class:"my-2",type:"error"},{default:v(()=>{var O,R;return[x(re(Q(s))+" ",1),_[29]||(_[29]=L("br",null,null,-1)),x(" Details: "+re((O=Q(i))==null?void 0:O.slice(0,75))+" ",1),((R=Q(i))==null?void 0:R.length)>75?($(),ve("span",FG,"...")):pe("",!0)]}),_:1})):pe("",!0),h(dn,{class:"mt-2"}),h(Ut,{"two-line":"",flat:"",subheader:"",dense:"",class:"mt-2"},{default:v(()=>[h(T,null,{default:v(()=>_[30]||(_[30]=[x("Found printers")])),_:1}),h(S,{modelValue:Q(u),"onUpdate:modelValue":_[4]||(_[4]=O=>et(u)?u.value=O:null),multiple:""},{default:v(()=>[($(!0),ve(Ae,null,Gt(Q(l),O=>($(),te(Ve,{dense:"",key:O.name,title:O.name},{default:v(({isActive:R})=>[h(pu,null,{default:v(()=>[h(mn,{"input-value":R},null,8,["input-value"])]),_:2},1024),h(P,null,{default:v(()=>[h(ft,null,{default:v(()=>[x(re(O.name),1)]),_:2},1024),h(bt,null,{default:v(()=>[L("span",NG,"URL: "+re(O.printerURL),1),L("span",BG,"Enabled: "+re(O.enabled),1),L("span",VG,"API Key: "+re(O.apiKey),1)]),_:2},1024)]),_:2},1024)]),_:2},1032,["title"]))),128))]),_:1},8,["modelValue"]),h(T,null,{default:v(()=>[h(se,{onClick:y,class:"my-2",small:""},{default:v(()=>[h(J,{class:"mr-2"},{default:v(()=>_[31]||(_[31]=[x("check")])),_:1}),_[32]||(_[32]=x(" Toggle selection "))]),_:1})]),_:1})]),_:1}),L("div",UG,[h(J,{class:"pr-2"},{default:v(()=>_[33]||(_[33]=[x("info")])),_:1}),_[34]||(_[34]=x(" At this moment, the following properties will be imported: enabled, name, printerURL and apiKey "))]),h(se,{class:"my-2",color:"primary",onClick:_[5]||(_[5]=O=>b()),disabled:!((I=Q(u))!=null&&I.length)},{default:v(()=>{var O;return[x(" Submit "+re((O=Q(u))==null?void 0:O.length)+" printers ",1)]}),_:1},8,["disabled"])]}),_:1}),h(dh,{value:"3"},{default:v(()=>{var I,O;return[Q(c)?($(),ve("div",zG,[h(J,{size:"100",class:"mr-5",color:"green circle"},{default:v(()=>_[35]||(_[35]=[x("check_circle")])),_:1}),_[36]||(_[36]=x(" Import Completed "))])):($(),ve("div",HG,[h(J,{size:"100",class:"mr-5",color:"red circle"},{default:v(()=>_[37]||(_[37]=[x("error")])),_:1}),x(" Something went wrong: "+re(Q(s))+" ",1),_[38]||(_[38]=L("br",null,null,-1)),L("span",jG," Details: "+re((I=Q(i))==null?void 0:I.slice(0,75)),1),((O=Q(i))==null?void 0:O.length)>75?($(),ve("span",qG,"...")):pe("",!0)]))]}),_:1})]),_:1})]),_:1},8,["modelValue"])]),_:1})]),_:1}),h(se,{class:"mt-2"},{default:v(()=>_[39]||(_[39]=[x(" Validate printers ")])),_:1})]),_:1}),h(Mn,null,{default:v(()=>[h(Sn),h(se,{onClick:_[7]||(_[7]=I=>k())},{default:v(()=>[h(J,{class:"mr-2"},{default:v(()=>_[40]||(_[40]=[x("close")])),_:1}),_[41]||(_[41]=x(" Close "))]),_:1})]),_:1})]),_:1})]),_:1},8,["id"])}}}),GG=de({id:String,submenu:Boolean,...Ms(Id({closeDelay:250,closeOnContentClick:!0,locationStrategy:"connected",location:void 0,openDelay:300,scrim:!1,scrollStrategy:"reposition",transition:{component:t0}}),["absolute"])},"VMenu"),Tm=ke()({name:"VMenu",props:GG(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const r=st(e,"modelValue"),{scopeId:s}=Ru(),{isRtl:i}=Dr(),o=ms(),a=ae(()=>e.id||`v-menu-${o}`),l=j(),u=Qe(Wv,null),c=Ie(new Set);Kt(Wv,{register(){c.value.add(o)},unregister(){c.value.delete(o)},closeParents(y){setTimeout(()=>{var w;!c.value.size&&!e.persistent&&(y==null||(w=l.value)!=null&&w.contentEl&&!z$(y,l.value.contentEl))&&(r.value=!1,u==null||u.closeParents())},40)}}),Cn(()=>{u==null||u.unregister(),document.removeEventListener("focusin",d)}),$b(()=>r.value=!1);async function d(y){var k,C,_;const w=y.relatedTarget,b=y.target;await Mt(),r.value&&w!==b&&((k=l.value)!=null&&k.contentEl)&&((C=l.value)!=null&&C.globalTop)&&![document,l.value.contentEl].includes(b)&&!l.value.contentEl.contains(b)&&((_=qc(l.value.contentEl)[0])==null||_.focus())}Ee(r,y=>{y?(u==null||u.register(),Et&&document.addEventListener("focusin",d,{once:!0})):(u==null||u.unregister(),Et&&document.removeEventListener("focusin",d))},{immediate:!0});function f(y){u==null||u.closeParents(y)}function p(y){var w,b,k,C,_;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(),FT(qc((w=l.value)==null?void 0:w.contentEl,!1),y.shiftKey?"prev":"next",P=>P.tabIndex>=0)||(r.value=!1,(k=(b=l.value)==null?void 0:b.activatorEl)==null||k.focus())}else e.submenu&&y.key===(i.value?"ArrowRight":"ArrowLeft")&&(r.value=!1,(_=(C=l.value)==null?void 0:C.activatorEl)==null||_.focus())}function g(y){var b;if(e.disabled)return;const w=(b=l.value)==null?void 0:b.contentEl;w&&r.value?y.key==="ArrowDown"?(y.preventDefault(),y.stopImmediatePropagation(),Ec(w,"next")):y.key==="ArrowUp"?(y.preventDefault(),y.stopImmediatePropagation(),Ec(w,"prev")):e.submenu&&(y.key===(i.value?"ArrowRight":"ArrowLeft")?r.value=!1:y.key===(i.value?"ArrowLeft":"ArrowRight")&&(y.preventDefault(),Ec(w,"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=A(()=>ge({"aria-haspopup":"menu","aria-expanded":String(r.value),"aria-controls":a.value,onKeydown:g},e.activatorProps));return Oe(()=>{const y=Bi.filterProps(e);return h(Bi,ge({ref:l,id:a.value,class:["v-menu",e.class],style:e.style},y,{modelValue:r.value,"onUpdate:modelValue":w=>r.value=w,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 w=arguments.length,b=new Array(w),k=0;k<w;k++)b[k]=arguments[k];return h(Ot,{root:"VMenu"},{default:()=>{var C;return[(C=n.default)==null?void 0:C.call(n,...b)]}})}})}),Xi({id:a,ΨopenChildren:c},l)}}),KG=de({renderless:Boolean,...Ue()},"VVirtualScrollItem"),YG=ke()({name:"VVirtualScrollItem",inheritAttrs:!1,props:KG(),emits:{"update:height":e=>!0},setup(e,t){let{attrs:n,emit:r,slots:s}=t;const{resizeRef:i,contentRect:o}=Va(void 0,"border");Ee(()=>{var a;return(a=o.value)==null?void 0:a.height},a=>{a!=null&&r("update:height",a)}),Oe(()=>{var a,l;return e.renderless?h(Ae,null,[(a=s.default)==null?void 0:a.call(s,{itemRef:i})]):h("div",ge({ref:i,class:["v-virtual-scroll__item",e.class],style:e.style},n),[(l=s.default)==null?void 0:l.call(s)])})}}),XG=-1,QG=1,Ug=100,JG=de({itemHeight:{type:[Number,String],default:null},itemKey:{type:[String,Array,Function],default:null},height:[Number,String]},"virtual");function ZG(e,t){const n=fi(),r=Ie(0);On(()=>{r.value=parseFloat(e.itemHeight||0)});const s=Ie(0),i=Ie(Math.ceil((parseInt(e.height)||n.height.value)/(r.value||16))||1),o=Ie(0),a=Ie(0),l=j(),u=j();let c=0;const{resizeRef:d,contentRect:f}=Va();On(()=>{d.value=l.value});const p=A(()=>{var B;return l.value===document.documentElement?n.height.value:((B=f.value)==null?void 0:B.height)||parseInt(e.height)||0}),g=A(()=>!!(l.value&&u.value&&p.value&&r.value));let m=Array.from({length:t.value.length}),y=Array.from({length:t.value.length});const w=Ie(0);let b=-1;function k(B){return m[B]||r.value}const C=B$(()=>{const B=performance.now();y[0]=0;const ee=t.value.length;for(let q=1;q<=ee-1;q++)y[q]=(y[q-1]||0)+k(q-1);w.value=Math.max(w.value,performance.now()-B)},w),_=Ee(g,B=>{B&&(_(),c=u.value.offsetTop,C.immediate(),U(),~b&&Mt(()=>{Et&&window.requestAnimationFrame(()=>{X(b),b=-1})}))});yn(()=>{C.clear()});function T(B,ee){const q=m[B],G=r.value;r.value=G?Math.min(r.value,ee):ee,(q!==ee||G!==r.value)&&(m[B]=ee,C())}function P(B){return B=Cr(B,0,t.value.length-1),y[B]||0}function S(B){return e9(y,B)}let E=0,I=0,O=0;Ee(p,(B,ee)=>{ee&&(U(),B<ee&&requestAnimationFrame(()=>{I=0,U()}))});let R=-1;function M(){if(!l.value||!u.value)return;const B=l.value.scrollTop,ee=performance.now();ee-O>500?(I=Math.sign(B-E),c=u.value.offsetTop):I=B-E,E=B,O=ee,window.clearTimeout(R),R=window.setTimeout(D,500),U()}function D(){!l.value||!u.value||(I=0,O=0,window.clearTimeout(R),U())}let F=-1;function U(){cancelAnimationFrame(F),F=requestAnimationFrame(K)}function K(){if(!l.value||!p.value)return;const B=E-c,ee=Math.sign(I),q=Math.max(0,B-Ug),G=Cr(S(q),0,t.value.length),le=B+p.value+Ug,ie=Cr(S(le)+1,G+1,t.value.length);if((ee!==XG||G<s.value)&&(ee!==QG||ie>i.value)){const Se=P(s.value)-P(G),Z=P(ie)-P(i.value);Math.max(Se,Z)>Ug?(s.value=G,i.value=ie):(G<=0&&(s.value=G),ie>=t.value.length&&(i.value=ie))}o.value=P(s.value),a.value=P(t.value.length)-P(i.value)}function X(B){const ee=P(B);!l.value||B&&!ee?b=B:l.value.scrollTop=ee}const H=A(()=>t.value.slice(s.value,i.value).map((B,ee)=>{const q=ee+s.value;return{raw:B,index:q,key:Fn(B,e.itemKey,q)}}));return Ee(t,()=>{m=Array.from({length:t.value.length}),y=Array.from({length:t.value.length}),C.immediate(),U()},{deep:1}),{calculateVisibleItems:U,containerRef:l,markerRef:u,computedItems:H,paddingTop:o,paddingBottom:a,scrollToIndex:X,handleScroll:M,handleScrollend:D,handleItemResize:T}}function e9(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 t9=de({items:{type:Array,default:()=>[]},renderless:Boolean,...JG(),...Ue(),...Or()},"VVirtualScroll"),n9=ke()({name:"VVirtualScroll",props:t9(),setup(e,t){let{slots:n}=t;const r=an("VVirtualScroll"),{dimensionStyles:s}=Mr(e),{calculateVisibleItems:i,containerRef:o,markerRef:a,handleScroll:l,handleScrollend:u,handleItemResize:c,scrollToIndex:d,paddingTop:f,paddingBottom:p,computedItems:g}=ZG(e,ae(()=>e.items));return Hr(()=>e.renderless,()=>{function m(){var b,k;const w=(arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1)?"addEventListener":"removeEventListener";o.value===document.documentElement?(document[w]("scroll",l,{passive:!0}),document[w]("scrollend",u)):((b=o.value)==null||b[w]("scroll",l,{passive:!0}),(k=o.value)==null||k[w]("scrollend",u))}St(()=>{o.value=KT(r.vnode.el,!0),m(!0)}),yn(m)}),Oe(()=>{const m=g.value.map(y=>h(YG,{key:y.key,renderless:e.renderless,"onUpdate:height":w=>c(y.index,w)},{default:w=>{var b;return(b=n.default)==null?void 0:b.call(n,{item:y.raw,index:y.index,...w})}}));return e.renderless?h(Ae,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:d}}});function r9(e,t){const n=Ie(!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=Ee(n,()=>{l(),a()})}else a()})}async function o(a){var c,d;if(a.key==="Tab"&&((c=t.value)==null||c.focus()),!["PageDown","PageUp","Home","End"].includes(a.key))return;const l=(d=e.value)==null?void 0:d.$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 s9=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:He,default:"$dropdown"},menuProps:{type:Object},multiple:Boolean,noDataText:{type:String,default:"$vuetify.noDataText"},openOnClear:Boolean,itemColor:String,...tO({itemChildren:!1})},"Select"),i9=de({...s9(),...Ms(bO({modelValue:null,role:"combobox"}),["validationValue","dirty","appendInnerIcon"]),...Iu({transition:{component:t0}})},"VSelect"),$o=ke()({name:"VSelect",props:i9(),emits:{"update:focused":e=>!0,"update:modelValue":e=>!0,"update:menu":e=>!0},setup(e,t){let{slots:n}=t;const{t:r}=Gr(),s=j(),i=j(),o=j(),{items:a,transformIn:l,transformOut:u}=CW(e),c=st(e,"modelValue",[],H=>l(H===null?[null]:An(H)),H=>{const B=u(H);return e.multiple?B:B[0]??null}),d=A(()=>typeof e.counterValue=="function"?e.counterValue(c.value):typeof e.counterValue=="number"?e.counterValue:c.value.length),f=yO(e),p=A(()=>c.value.map(H=>H.value)),g=Ie(!1);let m="",y;const w=A(()=>e.hideSelected?a.value.filter(H=>!c.value.some(B=>(e.valueComparator||as)(B,H))):a.value),b=A(()=>e.hideNoData&&!w.value.length||f.isReadonly.value||f.isDisabled.value),k=st(e,"menu"),C=A({get:()=>k.value,set:H=>{var B;k.value&&!H&&((B=i.value)!=null&&B.ΨopenChildren.size)||H&&b.value||(k.value=H)}}),_=ae(()=>C.value?e.closeText:e.openText),T=A(()=>{var H;return{...e.menuProps,activatorProps:{...((H=e.menuProps)==null?void 0:H.activatorProps)||{},"aria-haspopup":"listbox"}}}),P=j(),S=r9(P,s);function E(H){e.openOnClear&&(C.value=!0)}function I(){b.value||(C.value=!C.value)}function O(H){zS(H)&&R(H)}function R(H){var G,le;if(!H.key||f.isReadonly.value)return;["Enter"," ","ArrowDown","ArrowUp","Home","End"].includes(H.key)&&H.preventDefault(),["Enter","ArrowDown"," "].includes(H.key)&&(C.value=!0),["Escape","Tab"].includes(H.key)&&(C.value=!1),H.key==="Home"?(G=P.value)==null||G.focus("first"):H.key==="End"&&((le=P.value)==null||le.focus("last"));const B=1e3;if(!zS(H))return;const ee=performance.now();ee-y>B&&(m=""),m+=H.key.toLowerCase(),y=ee;const q=a.value.find(ie=>ie.title.toLowerCase().startsWith(m));if(q!==void 0){c.value=[q];const ie=w.value.indexOf(q);Et&&window.requestAnimationFrame(()=>{var Se;ie>=0&&((Se=o.value)==null||Se.scrollToIndex(ie))})}}function M(H){let B=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;if(!H.props.disabled)if(e.multiple){const ee=c.value.findIndex(G=>(e.valueComparator||as)(G.value,H.value)),q=B??!~ee;if(~ee){const G=q?[...c.value,H]:[...c.value];G.splice(ee,1),c.value=G}else q&&(c.value=[...c.value,H])}else{const ee=B!==!1;c.value=ee?[H]:[],Mt(()=>{C.value=!1})}}function D(H){var B;(B=P.value)!=null&&B.$el.contains(H.relatedTarget)||(C.value=!1)}function F(){var H;e.eager&&((H=o.value)==null||H.calculateVisibleItems())}function U(){var H;g.value&&((H=s.value)==null||H.focus())}function K(H){g.value=!0}function X(H){if(H==null)c.value=[];else if(Lh(s.value,":autofill")||Lh(s.value,":-webkit-autofill")){const B=a.value.find(ee=>ee.title===H);B&&M(B)}else s.value&&(s.value.value="")}return Ee(C,()=>{if(!e.hideSelected&&C.value&&c.value.length){const H=w.value.findIndex(B=>c.value.some(ee=>(e.valueComparator||as)(ee.value,B.value)));Et&&window.requestAnimationFrame(()=>{var B;H>=0&&((B=o.value)==null||B.scrollToIndex(H))})}}),Ee(()=>e.items,(H,B)=>{C.value||g.value&&!B.length&&H.length&&(C.value=!0)}),Oe(()=>{const H=!!(e.chips||n.chip),B=!!(!e.hideNoData||w.value.length||n["prepend-item"]||n["append-item"]||n["no-data"]),ee=c.value.length>0,q=at.filterProps(e),G=ee||!g.value&&e.label&&!e.persistentPlaceholder?void 0:e.placeholder;return h(at,ge({ref:s},q,{modelValue:c.value.map(le=>le.props.value).join(", "),"onUpdate:modelValue":X,focused:g.value,"onUpdate:focused":le=>g.value=le,validationValue:c.externalValue,counterValue:d.value,dirty:ee,class:["v-select",{"v-select--active-menu":C.value,"v-select--chips":!!e.chips,[`v-select--${e.multiple?"multiple":"single"}`]:!0,"v-select--selected":c.value.length,"v-select--selection-slot":!!n.selection},e.class],style:e.style,inputmode:"none",placeholder:G,"onClick:clear":E,"onMousedown:control":I,onBlur:D,onKeydown:R,"aria-label":r(_.value),title:r(_.value)}),{...n,default:()=>h(Ae,null,[h(Tm,ge({ref:i,modelValue:C.value,"onUpdate:modelValue":le=>C.value=le,activator:"parent",contentClass:"v-select__content",disabled:b.value,eager:e.eager,maxHeight:310,openOnClick:!1,closeOnContentClick:!1,transition:e.transition,onAfterEnter:F,onAfterLeave:U},T.value),{default:()=>[B&&h(Ut,ge({ref:P,selected:p.value,selectStrategy:e.multiple?"independent":"single-independent",onMousedown:le=>le.preventDefault(),onKeydown:O,onFocusin:K,tabindex:"-1","aria-live":"polite","aria-label":`${e.label}-list`,color:e.itemColor??e.color},S,e.listProps),{default:()=>{var le,ie,Se;return[(le=n["prepend-item"])==null?void 0:le.call(n),!w.value.length&&!e.hideNoData&&(((ie=n["no-data"])==null?void 0:ie.call(n))??h(Ve,{key:"no-data",title:r(e.noDataText)},null)),h(n9,{ref:o,renderless:!0,items:w.value,itemKey:"value"},{default:Z=>{var Fe;let{item:he,index:ne,itemRef:z}=Z;const xe=ge(he.props,{ref:z,key:he.value,onClick:()=>M(he,null)});return((Fe=n.item)==null?void 0:Fe.call(n,{item:he,index:ne,props:xe}))??h(Ve,ge(xe,{role:"option"}),{prepend:N=>{let{isSelected:V}=N;return h(Ae,null,[e.multiple&&!e.hideSelected?h(gu,{key:he.value,modelValue:V,ripple:!1,tabindex:"-1"},null):void 0,he.props.prependAvatar&&h(ut,{image:he.props.prependAvatar},null),he.props.prependIcon&&h(J,{icon:he.props.prependIcon},null)])}})}}),(Se=n["append-item"])==null?void 0:Se.call(n)]}})]}),c.value.map((le,ie)=>{function Se(z){z.stopPropagation(),z.preventDefault(),M(le,!1)}const Z={"onClick:close":Se,onKeydown(z){z.key!=="Enter"&&z.key!==" "||(z.preventDefault(),z.stopPropagation(),Se(z))},onMousedown(z){z.preventDefault(),z.stopPropagation()},modelValue:!0,"onUpdate:modelValue":void 0},he=H?!!n.chip:!!n.selection,ne=he?NT(H?n.chip({item:le,index:ie,props:Z}):n.selection({item:le,index:ie})):void 0;if(!(he&&!ne))return h("div",{key:le.value,class:"v-select__selection"},[H?n.chip?h(Ot,{key:"chip-defaults",defaults:{VChip:{closable:e.closableChips,size:"small",text:le.title}}},{default:()=>[ne]}):h(_n,ge({key:"chip",closable:e.closableChips,size:"small",text:le.title,disabled:le.props.disabled},Z),null):ne??h("span",{class:"v-select__selection-text"},[le.title,e.multiple&&ie<c.value.length-1&&h("span",{class:"v-select__selection-comma"},[x(",")])])])})]),"append-inner":function(){var Z,he;for(var le=arguments.length,ie=new Array(le),Se=0;Se<le;Se++)ie[Se]=arguments[Se];return h(Ae,null,[(Z=n["append-inner"])==null?void 0:Z.call(n,...ie),e.menuIcon?h(J,{class:"v-select__menu-icon",color:(he=s.value)==null?void 0:he.fieldIconColor,icon:e.menuIcon},null):void 0])}})}),Xi({isFocused:g,menu:C,select:M},s)}}),o9={class:"text-h5"},a9=Le({__name:"PrinterMaintenanceDialog",setup(e){const t=j([]),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=j({}),s=Ft(),i=tn(nn.PrinterMaintenanceDialog),o=A(()=>s.maintenanceDialogPrinter),a=()=>{r.value.disabledReason=t.value.join(", ")},l=async()=>{var f;const c=(f=o.value)==null?void 0:f.id;if(!c){r.value={},u();return}const d=r.value.disabledReason;await Qt.updatePrinterMaintenance(c,d),r.value={},u()},u=()=>{t.value=[],i.closeDialog(),s.setMaintenanceDialogPrinter()};return(c,d)=>{const f=hi;return $(),te(f,{id:Q(i).dialogId,"max-width":"700px",onEscape:d[5]||(d[5]=p=>u())},{default:v(()=>[h(vt,{class:"pa-4"},{default:v(()=>[h(sn,null,{default:v(()=>{var p;return[L("span",o9," Mark '"+re((p=o.value)==null?void 0:p.name)+"' for maintenance ",1)]}),_:1}),h(fn,{color:"secondary"},{default:v(()=>d[6]||(d[6]=[x(" Keep this info clear and stick to convention ")])),_:1}),h(en,null,{default:v(()=>[h(rt,null,{default:v(()=>[h(ze,{cols:"12"},{default:v(()=>[h($o,{modelValue:t.value,"onUpdate:modelValue":[d[0]||(d[0]=p=>t.value=p),d[1]||(d[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(xO,{modelValue:r.value.disabledReason,"onUpdate:modelValue":d[2]||(d[2]=p=>r.value.disabledReason=p),"data-vv-validate-on":"change|blur"},{label:v(()=>d[7]||(d[7]=[L("div",null,"Type the reason*",-1)])),_:1},8,["modelValue"])]),_:1})]),_:1})]),_:1}),h(Mn,null,{default:v(()=>[d[10]||(d[10]=L("em",{class:"text-red"}," * indicates required field ",-1)),h(Sn),h(se,{variant:"text",onClick:d[3]||(d[3]=p=>u())},{default:v(()=>d[8]||(d[8]=[x(" Close ")])),_:1}),h(se,{color:"blue-darken-1",variant:"text",onClick:d[4]||(d[4]=p=>l())},{default:v(()=>d[9]||(d[9]=[x(" Save ")])),_:1})]),_:1})]),_:1})]),_:1},8,["id"])}}}),l9=[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16],u9=[1,2,3,4,5,6,7,8,9,10,11,12],DO=Le({__name:"GridSettingsList",setup(e){const t=Ns(),n=Dt(),r=A(()=>t.largeTiles),s=A(()=>t.preferCancelOverQuickStop);async function i(u){if(u)return l(u,t.gridRows)}async function o(u){if(u)return l(t.gridCols,u)}async function a(){return l(t.gridCols,t.gridRows)}async function l(u,c){await t.updateFrontendSettings({gridCols:c,gridRows:u,largeTiles:r.value,tilePreferCancelOverQuickStop:s.value}),n.info("Grid settings updated")}return(u,c)=>($(),ve("div",null,[h(en,null,{default:v(()=>[h(Ut,{subheader:"",lines:"three"},{default:v(()=>{var d;return[h(qr,null,{default:v(()=>c[2]||(c[2]=[x(" Grid Rows and Columns ")])),_:1}),(d=Q(t).settings)!=null&&d.frontend?($(),te(Ve,{key:0},{default:v(()=>[h(rt,null,{default:v(()=>[h(ze,{cols:"3"},{default:v(()=>[h($o,{type:"number","onUpdate:modelValue":o,value:Q(t).settings.frontend.gridRows,items:Q(l9),label:"Set the grid rows"},null,8,["value","items"])]),_:1}),h(ze,{cols:"3"},{default:v(()=>[h($o,{type:"number","onUpdate:modelValue":i,value:Q(t).settings.frontend.gridCols,items:Q(u9),label:"Set the grid columns"},null,8,["value","items"])]),_:1})]),_:1})]),_:1})):pe("",!0)]}),_:1}),h(dn),h(Ut,{subheader:"",lines:"three"},{default:v(()=>[h(qr,null,{default:v(()=>c[3]||(c[3]=[x(" Large or Compact Tiles ")])),_:1}),h(Ve,null,{default:v(()=>{var d;return[(d=Q(t).settings)!=null&&d.frontend?($(),te(rt,{key:0},{default:v(()=>[h(ze,{cols:"5"},{default:v(()=>[h(mn,{onChange:a,modelValue:Q(t).settings.frontend.largeTiles,"onUpdate:modelValue":c[0]||(c[0]=f=>Q(t).settings.frontend.largeTiles=f),label:"Large tiles"},null,8,["modelValue"])]),_:1})]),_:1})):pe("",!0)]}),_:1})]),_:1}),h(dn),h(Ut,{subheader:"","three-line":""},{default:v(()=>[h(qr,null,{default:v(()=>c[4]||(c[4]=[x("Large or Compact Tiles")])),_:1}),h(Ve,null,{default:v(()=>{var d;return[(d=Q(t).settings)!=null&&d.frontend?($(),te(rt,{key:0},{default:v(()=>[h(ze,{cols:"5"},{default:v(()=>[h(mn,{onChange:a,modelValue:Q(t).settings.frontend.tilePreferCancelOverQuickStop,"onUpdate:modelValue":c[1]||(c[1]=f=>Q(t).settings.frontend.tilePreferCancelOverQuickStop=f),label:"Print tile - show cancel instead of quick stop"},null,8,["modelValue"])]),_:1})]),_:1})):pe("",!0)]}),_:1})]),_:1})]),_:1})]))}}),c9={class:"text-h5"},d9=Le({__name:"GridSettingsDialog",setup(e){const t=tn(nn.GridSettingsDialog);function n(){t.closeDialog(t.context())}return(r,s)=>{const i=hi;return $(),te(i,{id:Q(t).dialogId,"max-width":"1000px",onEscape:s[1]||(s[1]=o=>n())},{default:v(()=>[h(vt,{class:"pa-4"},{default:v(()=>[h(sn,null,{default:v(()=>[L("span",c9,[s[4]||(s[4]=x(" Grid Settings ")),h(nt,{top:""},{activator:v(({props:o})=>[h(se,ge(o,{class:"ma-2",fab:"","x-small":""}),{default:v(()=>[h(J,null,{default:v(()=>s[2]||(s[2]=[x("question_mark")])),_:1})]),_:2},1040)]),default:v(()=>s[3]||(s[3]=[x(" Change your grid rows, columns and tile settings. ")])),_:1})])]),_:1}),h(DO),h(Mn,null,{default:v(()=>[h(Sn),h(se,{onClick:s[0]||(s[0]=o=>Q(t).closeDialog())},{default:v(()=>s[5]||(s[5]=[x("Close")])),_:1})]),_:1})]),_:1})]),_:1},8,["id"])}}});class ts extends gr{static async createUser(t){const n=Me.userRoute;return await this.post(n,t)}static async listUsers(){const t=Me.userRoute;return await this.get(t)}static async listRoles(){const t=Me.rolesRoute;return await this.get(t)}static async getProfile(){const t=Me.userProfileRoute;return await this.get(t)}static async changePassword(t,n,r){const s=Me.userChangePasswordRoute(t);return await this.post(s,{oldPassword:n,newPassword:r})}static async changeUsername(t,n){const r=Me.userChangeUsernameRoute(t);return await this.post(r,{username:n})}static async deleteUser(t){const n=Me.userDeleteRoute(t);return await this.delete(n)}static async setUserVerified(t,n){const r=Me.userSetVerifiedRoute(t);return await this.post(r,{isVerified:n})}static async setRootUser(t,n){const r=Me.userSetRootUserRoute(t);return await this.post(r,{isRootUser:n})}static async setUserRoles(t,n){const r=Me.userSetUserRolesRoute(t);return await this.post(r,{roleIds:n})}}const f9={class:"text-h5"},h9={class:"pl-5"},p9=Le({__name:"CreateUserDialog",setup(e){const t=tn(nn.CreateUserDialog),n=Qe("appConstants"),r=Dt(),s=j({username:"",password:"",roleIds:[]}),i=j(""),o=j([]),a=A(()=>{var f,p;return(p=(f=s.value)==null?void 0:f.username)!=null&&p.length?Sm(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),c=async()=>{if(u())try{await ts.createUser(s.value),r.openInfoMessage({title:`User ${s.value.username} created successfully`}),d()}catch(f){r.openErrorMessage({title:"Failed to create user",subtitle:f instanceof Error?f.message:"Unknown error"})}},d=()=>{s.value={username:"",password:"",roleIds:[]},i.value="",t.closeDialog()};return St(async()=>{try{o.value=await ts.listRoles()}catch(f){r.openErrorMessage({title:"Failed to load roles",subtitle:f instanceof Error?f.message:"Unknown error"})}}),(f,p)=>{const g=hi;return $(),te(g,{id:Q(t).dialogId,"max-width":"700px",onEscape:d},{default:v(()=>[h(vt,{class:"pa-4"},{default:v(()=>[h(sn,null,{default:v(()=>[L("span",f9,[h(ut,{color:"primary",size:"56"},{default:v(()=>[x(re(a.value),1)]),_:1}),L("span",h9,[p[6]||(p[6]=x("New verified User ")),h(nt,{top:""},{activator:v(({props:m})=>[h(se,ge({class:"ma-2",fab:""},m,{"x-small":""}),{default:v(()=>[h(J,null,{default:v(()=>p[4]||(p[4]=[x("question_mark")])),_:1})]),_:2},1040)]),default:v(()=>p[5]||(p[5]=[x(" The user will be set to verified and assigned roles. Please share the username and password with them manually. ")])),_:1})])])]),_:1}),h(en,null,{default:v(()=>[h(rt,null,{default:v(()=>[h(ze,{cols:12},{default:v(()=>[h(Un,null,{default:v(()=>[h(rt,null,{default:v(()=>[h(ze,{cols:"12",md:"6"},{default:v(()=>[h(at,{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(at,{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(at,{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($o,{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(Mn,null,{default:v(()=>[p[9]||(p[9]=L("em",{class:"text-red"}," * indicates required field ",-1)),h(Sn),h(se,{variant:"text",onClick:d},{default:v(()=>p[7]||(p[7]=[x("Close")])),_:1}),h(se,{color:"blue-darken-1",variant:"text",onClick:c},{default:v(()=>p[8]||(p[8]=[x("Create")])),_:1})]),_:1})]),_:1})]),_:1},8,["id"])}}}),LO=()=>({id:void 0,name:Vu(),floor:"1",printers:[]});class ns extends gr{static convertPrinterFloorToCreateForm(t){const n=LO();return n.id=t==null?void 0:t.id,n.name=(t==null?void 0:t.name)||Vu(),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=`${Me.floorRoute}/`;return await this.get(t)}static async createFloor(t){const n=`${Me.floorRoute}/`;return await this.post(n,t)}static async updateFloorName(t,n){const r=`${Me.updatePrinterFloorNameRoute(t)}/`;return await this.patch(r,{name:n})}static async updateFloorNumber(t,n){const r=`${Me.updatePrinterFloorNumberRoute(t)}/`;return await this.patch(r,{floor:n})}static async deleteFloor(t){const n=`${Me.getFloorRoute(t)}/`;return await this.delete(n)}static async addPrinterToFloor(t,n){const r=`${Me.addOrRemovePrinterFromFloorRoute(t)}/`;return await this.post(r,n)}static async deletePrinterFromFloor(t,n){const r=`${Me.addOrRemovePrinterFromFloorRoute(t)}/`;return await this.delete(r,{printerId:n})}}const Qi=gs("Floors",{state:()=>({floors:[],selectedFloorIndex:0}),getters:{selectedFloor(e){return e.floors.length<=e.selectedFloorIndex?null:e.floors[e.selectedFloorIndex]},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 Ft().printers.filter(n=>!e.floors.find(r=>r.printers.find(s=>s.printerId===n.id)))},gridSortedPrinters(){const e=Ns(),t=e.gridCols,n=e.gridRows,s=Ft().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 c=i.find(d=>d.x===a&&d.y===u);if(!c)l.push(void 0);else{const d=s.find(f=>f.id===c.printerId);l.push(d)}}}return o}},actions:{async loadFloors(){const e=await ns.getFloors();return this.saveFloors(e),e},async createFloor(e){const t=await ns.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.findIndex(s=>s.id===t);this.selectedFloorIndex=n===-1?0:n},async deleteFloor(e){await ns.deleteFloor(e),this._popPrinterFloor(e)},async updateFloorName({floorId:e,name:t}){const n=await ns.updateFloorName(e,t);return this._replaceFloor(n),n},async updateFloorNumber({floorId:e,floorNumber:t}){const n=await ns.updateFloorNumber(e,t);return this._replaceFloor(n),n},async addPrinterToFloor({floorId:e,printerId:t,x:n,y:r}){const s=await ns.addPrinterToFloor(e,{printerId:t,x:n,y:r});this._replaceFloor(s)},async changeSelectedFloorByIndex(e){var n;if(!((n=this.floors)!=null&&n.length))return;if(this.floors.length<=e){console.warn("Selected floor index exceeds floors array"),this.selectedFloorIndex=0;return}if(!this.floors[e]){console.warn("Selected floor index did not exist in floors array"),this.selectedFloorIndex=0;return}this.selectedFloorIndex=e},async deletePrinterFromFloor({floorId:e,printerId:t}){const n=await ns.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)}}}),m9={class:"text-h5"},g9=Le({__name:"AddOrUpdateFloorDialog",setup(e){const t=tn(nn.AddOrUpdateFloorDialog),n=Qi(),r=Qe("appConstants"),s=Dt(),i=j(LO()),o=A(()=>{var d;return(d=t.context())==null?void 0:d.printerFloorId}),a=A(()=>i.value?Sm(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 d=ns.convertCreateFormToFloor(i.value);await n.createFloor(d),s.openInfoMessage({title:`Floor ${d.name} created`}),i.value.name=Vu();const f=Math.max(...n.floors.map(p=>p.floor))+1;i.value.floor=f.toString(),c()},c=()=>{t.closeDialog()};return Ee(o,d=>{if(d){const f=n.floor(d);i.value=ns.convertPrinterFloorToCreateForm(f)}}),St(()=>{var d;if(o.value){const f=n.floor(o.value);i.value=ns.convertPrinterFloorToCreateForm(f)}else if((d=n.floors)!=null&&d.length){const f=Math.max(...n.floors.map(p=>p.floor))+1;i.value.floor=f.toString()}}),(d,f)=>{const p=hi;return $(),te(p,{id:Q(t).dialogId,"max-width":"700px",onEscape:c},{default:v(()=>[h(vt,null,{default:v(()=>[h(sn,null,{default:v(()=>[L("span",m9,[h(ut,{color:"primary",size:"56"},{default:v(()=>[x(re(a.value),1)]),_:1}),f[2]||(f[2]=x(" New Floor "))])]),_:1}),h(en,null,{default:v(()=>[h(rt,null,{default:v(()=>[h(ze,{cols:12},{default:v(()=>[h(Un,null,{default:v(()=>[h(rt,null,{default:v(()=>[i.value?($(),te(ze,{key:0,cols:"12",md:"6"},{default:v(()=>[h(at,{modelValue:i.value.name,"onUpdate:modelValue":f[0]||(f[0]=g=>i.value.name=g),autofocus:"",label:"Floor name*",required:""},null,8,["modelValue"]),h(at,{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})):pe("",!0)]),_:1})]),_:1})]),_:1})]),_:1})]),_:1}),h(Mn,null,{default:v(()=>[f[5]||(f[5]=L("em",{class:"text-red"}," * indicates required field ",-1)),h(Sn),h(se,{variant:"text",onClick:c},{default:v(()=>f[3]||(f[3]=[x("Close")])),_:1}),h(se,{color:"blue-darken-1",variant:"text",onClick:u},{default:v(()=>f[4]||(f[4]=[x("Create")])),_:1})]),_:1})]),_:1})]),_:1},8,["id"])}}});class fp extends gr{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 zu=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 es(){}function v9(e,t){return typeof e=="function"?e(t):e}function Hy(e){return typeof e=="number"&&e>=0&&e!==1/0}function $O(e,t){return Math.max(e+(t||0)-Date.now(),0)}function Nl(e,t){return typeof e=="function"?e(t):e}function Cs(e,t){return typeof e=="function"?e(t):e}function Ck(e,t){const{type:n="all",exact:r,fetchStatus:s,predicate:i,queryKey:o,stale:a}=e;if(o){if(r){if(t.queryHash!==ew(o,t.options))return!1}else if(!ld(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 Tk(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(!ld(t.options.mutationKey,i))return!1}return!(r&&t.state.status!==r||s&&!s(t))}function ew(e,t){return((t==null?void 0:t.queryKeyHashFn)||Ya)(e)}function Ya(e){return JSON.stringify(e,(t,n)=>jy(n)?Object.keys(n).sort().reduce((r,s)=>(r[s]=n[s],r),{}):n)}function ld(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?Object.keys(t).every(n=>ld(e[n],t[n])):!1}function FO(e,t){if(e===t)return e;const n=Pk(e)&&Pk(t);if(n||jy(e)&&jy(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 c=n?u:i[u];(!n&&r.includes(c)||n)&&e[c]===void 0&&t[c]===void 0?(a[c]=void 0,l++):(a[c]=FO(e[c],t[c]),a[c]===e[c]&&e[c]!==void 0&&l++)}return s===o&&l===s?e:a}return t}function hp(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 Pk(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function jy(e){if(!Rk(e))return!1;const t=e.constructor;if(t===void 0)return!0;const n=t.prototype;return!(!Rk(n)||!n.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function Rk(e){return Object.prototype.toString.call(e)==="[object Object]"}function y9(e){return new Promise(t=>{setTimeout(t,e)})}function qy(e,t,n){return typeof n.structuralSharing=="function"?n.structuralSharing(e,t):n.structuralSharing!==!1?FO(e,t):t}function b9(e,t,n=0){const r=[...e,t];return n&&r.length>n?r.slice(1):r}function w9(e,t,n=0){const r=[t,...e];return n&&r.length>n?r.slice(0,-1):r}var tw=Symbol();function NO(e,t){return!e.queryFn&&(t!=null&&t.initialPromise)?()=>t.initialPromise:!e.queryFn||e.queryFn===tw?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}function Wy(e,t){return typeof e=="function"?e(...t):!!e}var va,co,zl,HE,S9=(HE=class extends zu{constructor(){super();je(this,va);je(this,co);je(this,zl);De(this,zl,t=>{if(!Ka&&window.addEventListener){const n=()=>t();return window.addEventListener("visibilitychange",n,!1),()=>{window.removeEventListener("visibilitychange",n)}}})}onSubscribe(){W(this,co)||this.setEventListener(W(this,zl))}onUnsubscribe(){var t;this.hasListeners()||((t=W(this,co))==null||t.call(this),De(this,co,void 0))}setEventListener(t){var n;De(this,zl,t),(n=W(this,co))==null||n.call(this),De(this,co,t(r=>{typeof r=="boolean"?this.setFocused(r):this.onFocus()}))}setFocused(t){W(this,va)!==t&&(De(this,va,t),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach(n=>{n(t)})}isFocused(){var t;return typeof W(this,va)=="boolean"?W(this,va):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},va=new WeakMap,co=new WeakMap,zl=new WeakMap,HE),nw=new S9,Hl,fo,jl,jE,_9=(jE=class extends zu{constructor(){super();je(this,Hl,!0);je(this,fo);je(this,jl);De(this,jl,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(){W(this,fo)||this.setEventListener(W(this,jl))}onUnsubscribe(){var t;this.hasListeners()||((t=W(this,fo))==null||t.call(this),De(this,fo,void 0))}setEventListener(t){var n;De(this,jl,t),(n=W(this,fo))==null||n.call(this),De(this,fo,t(this.setOnline.bind(this)))}setOnline(t){W(this,Hl)!==t&&(De(this,Hl,t),this.listeners.forEach(r=>{r(t)}))}isOnline(){return W(this,Hl)}},Hl=new WeakMap,fo=new WeakMap,jl=new WeakMap,jE),pp=new _9;function Gy(){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 k9(e){return Math.min(1e3*2**e,3e4)}function BO(e){return(e??"online")==="online"?pp.isOnline():!0}var VO=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function zg(e){return e instanceof VO}function UO(e){let t=!1,n=0,r=!1,s;const i=Gy(),o=m=>{var y;r||(f(new VO(m)),(y=e.abort)==null||y.call(e))},a=()=>{t=!0},l=()=>{t=!1},u=()=>nw.isFocused()&&(e.networkMode==="always"||pp.isOnline())&&e.canRun(),c=()=>BO(e.networkMode)&&e.canRun(),d=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=w=>{(r||u())&&m(w)},(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(w){m=Promise.reject(w)}Promise.resolve(m).then(d).catch(w=>{var T;if(r)return;const b=e.retry??(Ka?0:3),k=e.retryDelay??k9,C=typeof k=="function"?k(n,w):k,_=b===!0||typeof b=="number"&&n<b||typeof b=="function"&&b(n,w);if(t||!_){f(w);return}n++,(T=e.onFail)==null||T.call(e,n,w),y9(C).then(()=>u()?void 0:p()).then(()=>{t?f(w):g()})})};return{promise:i,cancel:o,continue:()=>(s==null||s(),i),cancelRetry:a,continueRetry:l,canStart:c,start:()=>(c()?g():p().then(g),i)}}var x9=e=>setTimeout(e,0);function E9(){let e=[],t=0,n=a=>{a()},r=a=>{a()},s=x9;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 $n=E9(),ya,qE,zO=(qE=class{constructor(){je(this,ya)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),Hy(this.gcTime)&&De(this,ya,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(Ka?1/0:5*60*1e3))}clearGcTimeout(){W(this,ya)&&(clearTimeout(W(this,ya)),De(this,ya,void 0))}},ya=new WeakMap,qE),ql,Wl,Zr,ba,Wn,gd,wa,_s,ki,WE,C9=(WE=class extends zO{constructor(t){super();je(this,_s);je(this,ql);je(this,Wl);je(this,Zr);je(this,ba);je(this,Wn);je(this,gd);je(this,wa);De(this,wa,!1),De(this,gd,t.defaultOptions),this.setOptions(t.options),this.observers=[],De(this,ba,t.client),De(this,Zr,W(this,ba).getQueryCache()),this.queryKey=t.queryKey,this.queryHash=t.queryHash,De(this,ql,T9(this.options)),this.state=t.state??W(this,ql),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var t;return(t=W(this,Wn))==null?void 0:t.promise}setOptions(t){this.options={...W(this,gd),...t},this.updateGcTime(this.options.gcTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&W(this,Zr).remove(this)}setData(t,n){const r=qy(this.state.data,t,this.options);return tt(this,_s,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){tt(this,_s,ki).call(this,{type:"setState",state:t,setStateOptions:n})}cancel(t){var r,s;const n=(r=W(this,Wn))==null?void 0:r.promise;return(s=W(this,Wn))==null||s.cancel(t),n?n.then(es).catch(es):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(W(this,ql))}isActive(){return this.observers.some(t=>Cs(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===tw||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||!$O(this.state.dataUpdatedAt,t)}onFocus(){var n;const t=this.observers.find(r=>r.shouldFetchOnWindowFocus());t==null||t.refetch({cancelRefetch:!1}),(n=W(this,Wn))==null||n.continue()}onOnline(){var n;const t=this.observers.find(r=>r.shouldFetchOnReconnect());t==null||t.refetch({cancelRefetch:!1}),(n=W(this,Wn))==null||n.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),W(this,Zr).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(n=>n!==t),this.observers.length||(W(this,Wn)&&(W(this,wa)?W(this,Wn).cancel({revert:!0}):W(this,Wn).cancelRetry()),this.scheduleGc()),W(this,Zr).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||tt(this,_s,ki).call(this,{type:"invalidate"})}fetch(t,n){var l,u,c;if(this.state.fetchStatus!=="idle"){if(this.state.data!==void 0&&(n!=null&&n.cancelRefetch))this.cancel({silent:!0});else if(W(this,Wn))return W(this,Wn).continueRetry(),W(this,Wn).promise}if(t&&this.setOptions(t),!this.options.queryFn){const d=this.observers.find(f=>f.options.queryFn);d&&this.setOptions(d.options)}const r=new AbortController,s=d=>{Object.defineProperty(d,"signal",{enumerable:!0,get:()=>(De(this,wa,!0),r.signal)})},i=()=>{const d=NO(this.options,n),f={client:W(this,ba),queryKey:this.queryKey,meta:this.meta};return s(f),De(this,wa,!1),this.options.persister?this.options.persister(d,f,this):d(f)},o={fetchOptions:n,options:this.options,queryKey:this.queryKey,client:W(this,ba),state:this.state,fetchFn:i};s(o),(l=this.options.behavior)==null||l.onFetch(o,this),De(this,Wl,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((u=o.fetchOptions)==null?void 0:u.meta))&&tt(this,_s,ki).call(this,{type:"fetch",meta:(c=o.fetchOptions)==null?void 0:c.meta});const a=d=>{var f,p,g,m;zg(d)&&d.silent||tt(this,_s,ki).call(this,{type:"error",error:d}),zg(d)||((p=(f=W(this,Zr).config).onError)==null||p.call(f,d,this),(m=(g=W(this,Zr).config).onSettled)==null||m.call(g,this.state.data,d,this)),this.scheduleGc()};return De(this,Wn,UO({initialPromise:n==null?void 0:n.initialPromise,fn:o.fetchFn,abort:r.abort.bind(r),onSuccess:d=>{var f,p,g,m;if(d===void 0){a(new Error(`${this.queryHash} data is undefined`));return}try{this.setData(d)}catch(y){a(y);return}(p=(f=W(this,Zr).config).onSuccess)==null||p.call(f,d,this),(m=(g=W(this,Zr).config).onSettled)==null||m.call(g,d,this.state.error,this),this.scheduleGc()},onError:a,onFail:(d,f)=>{tt(this,_s,ki).call(this,{type:"failed",failureCount:d,error:f})},onPause:()=>{tt(this,_s,ki).call(this,{type:"pause"})},onContinue:()=>{tt(this,_s,ki).call(this,{type:"continue"})},retry:o.options.retry,retryDelay:o.options.retryDelay,networkMode:o.options.networkMode,canRun:()=>!0})),W(this,Wn).start()}},ql=new WeakMap,Wl=new WeakMap,Zr=new WeakMap,ba=new WeakMap,Wn=new WeakMap,gd=new WeakMap,wa=new WeakMap,_s=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,...HO(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 zg(s)&&s.revert&&W(this,Wl)?{...W(this,Wl),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),$n.batch(()=>{this.observers.forEach(r=>{r.onQueryUpdate()}),W(this,Zr).notify({query:this,type:"updated",action:t})})},WE);function HO(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:BO(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function T9(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 Js,GE,jO=(GE=class extends zu{constructor(n={}){super();je(this,Js);this.config=n,De(this,Js,new Map)}build(n,r,s){const i=r.queryKey,o=r.queryHash??ew(i,r);let a=this.get(o);return a||(a=new C9({client:n,queryKey:i,queryHash:o,options:n.defaultQueryOptions(r),state:s,defaultOptions:n.getQueryDefaults(i)}),this.add(a)),a}add(n){W(this,Js).has(n.queryHash)||(W(this,Js).set(n.queryHash,n),this.notify({type:"added",query:n}))}remove(n){const r=W(this,Js).get(n.queryHash);r&&(n.destroy(),r===n&&W(this,Js).delete(n.queryHash),this.notify({type:"removed",query:n}))}clear(){$n.batch(()=>{this.getAll().forEach(n=>{this.remove(n)})})}get(n){return W(this,Js).get(n)}getAll(){return[...W(this,Js).values()]}find(n){const r={exact:!0,...n};return this.getAll().find(s=>Ck(r,s))}findAll(n={}){const r=this.getAll();return Object.keys(n).length>0?r.filter(s=>Ck(n,s)):r}notify(n){$n.batch(()=>{this.listeners.forEach(r=>{r(n)})})}onFocus(){$n.batch(()=>{this.getAll().forEach(n=>{n.onFocus()})})}onOnline(){$n.batch(()=>{this.getAll().forEach(n=>{n.onOnline()})})}},Js=new WeakMap,GE),Zs,or,Sa,ei,ro,KE,P9=(KE=class extends zO{constructor(t){super();je(this,ei);je(this,Zs);je(this,or);je(this,Sa);this.mutationId=t.mutationId,De(this,or,t.mutationCache),De(this,Zs,[]),this.state=t.state||qO(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){W(this,Zs).includes(t)||(W(this,Zs).push(t),this.clearGcTimeout(),W(this,or).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){De(this,Zs,W(this,Zs).filter(n=>n!==t)),this.scheduleGc(),W(this,or).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){W(this,Zs).length||(this.state.status==="pending"?this.scheduleGc():W(this,or).remove(this))}continue(){var t;return((t=W(this,Sa))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var i,o,a,l,u,c,d,f,p,g,m,y,w,b,k,C,_,T,P,S;const n=()=>{tt(this,ei,ro).call(this,{type:"continue"})};De(this,Sa,UO({fn:()=>this.options.mutationFn?this.options.mutationFn(t):Promise.reject(new Error("No mutationFn found")),onFail:(E,I)=>{tt(this,ei,ro).call(this,{type:"failed",failureCount:E,error:I})},onPause:()=>{tt(this,ei,ro).call(this,{type:"pause"})},onContinue:n,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>W(this,or).canRun(this)}));const r=this.state.status==="pending",s=!W(this,Sa).canStart();try{if(r)n();else{tt(this,ei,ro).call(this,{type:"pending",variables:t,isPaused:s}),await((o=(i=W(this,or).config).onMutate)==null?void 0:o.call(i,t,this));const I=await((l=(a=this.options).onMutate)==null?void 0:l.call(a,t));I!==this.state.context&&tt(this,ei,ro).call(this,{type:"pending",context:I,variables:t,isPaused:s})}const E=await W(this,Sa).start();return await((c=(u=W(this,or).config).onSuccess)==null?void 0:c.call(u,E,t,this.state.context,this)),await((f=(d=this.options).onSuccess)==null?void 0:f.call(d,E,t,this.state.context)),await((g=(p=W(this,or).config).onSettled)==null?void 0:g.call(p,E,null,this.state.variables,this.state.context,this)),await((y=(m=this.options).onSettled)==null?void 0:y.call(m,E,null,t,this.state.context)),tt(this,ei,ro).call(this,{type:"success",data:E}),E}catch(E){try{throw await((b=(w=W(this,or).config).onError)==null?void 0:b.call(w,E,t,this.state.context,this)),await((C=(k=this.options).onError)==null?void 0:C.call(k,E,t,this.state.context)),await((T=(_=W(this,or).config).onSettled)==null?void 0:T.call(_,void 0,E,this.state.variables,this.state.context,this)),await((S=(P=this.options).onSettled)==null?void 0:S.call(P,void 0,E,t,this.state.context)),E}finally{tt(this,ei,ro).call(this,{type:"error",error:E})}}finally{W(this,or).runNext(this)}}},Zs=new WeakMap,or=new WeakMap,Sa=new WeakMap,ei=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),$n.batch(()=>{W(this,Zs).forEach(r=>{r.onMutationUpdate(t)}),W(this,or).notify({mutation:this,type:"updated",action:t})})},KE);function qO(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var Ii,ks,vd,YE,WO=(YE=class extends zu{constructor(n={}){super();je(this,Ii);je(this,ks);je(this,vd);this.config=n,De(this,Ii,new Set),De(this,ks,new Map),De(this,vd,0)}build(n,r,s){const i=new P9({mutationCache:this,mutationId:++Yd(this,vd)._,options:n.defaultMutationOptions(r),state:s});return this.add(i),i}add(n){W(this,Ii).add(n);const r=Sf(n);if(typeof r=="string"){const s=W(this,ks).get(r);s?s.push(n):W(this,ks).set(r,[n])}this.notify({type:"added",mutation:n})}remove(n){if(W(this,Ii).delete(n)){const r=Sf(n);if(typeof r=="string"){const s=W(this,ks).get(r);if(s)if(s.length>1){const i=s.indexOf(n);i!==-1&&s.splice(i,1)}else s[0]===n&&W(this,ks).delete(r)}}this.notify({type:"removed",mutation:n})}canRun(n){const r=Sf(n);if(typeof r=="string"){const s=W(this,ks).get(r),i=s==null?void 0:s.find(o=>o.state.status==="pending");return!i||i===n}else return!0}runNext(n){var s;const r=Sf(n);if(typeof r=="string"){const i=(s=W(this,ks).get(r))==null?void 0:s.find(o=>o!==n&&o.state.isPaused);return(i==null?void 0:i.continue())??Promise.resolve()}else return Promise.resolve()}clear(){$n.batch(()=>{W(this,Ii).forEach(n=>{this.notify({type:"removed",mutation:n})}),W(this,Ii).clear(),W(this,ks).clear()})}getAll(){return Array.from(W(this,Ii))}find(n){const r={exact:!0,...n};return this.getAll().find(s=>Tk(r,s))}findAll(n={}){return this.getAll().filter(r=>Tk(n,r))}notify(n){$n.batch(()=>{this.listeners.forEach(r=>{r(n)})})}resumePausedMutations(){const n=this.getAll().filter(r=>r.state.isPaused);return $n.batch(()=>Promise.all(n.map(r=>r.continue().catch(es))))}},Ii=new WeakMap,ks=new WeakMap,vd=new WeakMap,YE);function Sf(e){var t;return(t=e.options.scope)==null?void 0:t.id}function Ik(e){return{onFetch:(t,n)=>{var c,d,f,p,g;const r=t.options,s=(f=(d=(c=t.fetchOptions)==null?void 0:c.meta)==null?void 0:d.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=k=>{Object.defineProperty(k,"signal",{enumerable:!0,get:()=>(t.signal.aborted?m=!0:t.signal.addEventListener("abort",()=>{m=!0}),t.signal)})},w=NO(t.options,t.fetchOptions),b=async(k,C,_)=>{if(m)return Promise.reject();if(C==null&&k.pages.length)return Promise.resolve(k);const T={client:t.client,queryKey:t.queryKey,pageParam:C,direction:_?"backward":"forward",meta:t.options.meta};y(T);const P=await w(T),{maxPages:S}=t.options,E=_?w9:b9;return{pages:E(k.pages,P,S),pageParams:E(k.pageParams,C,S)}};if(s&&i.length){const k=s==="backward",C=k?R9:Ak,_={pages:i,pageParams:o},T=C(r,_);a=await b(_,T,k)}else{const k=e??i.length;do{const C=l===0?o[0]??r.initialPageParam:Ak(r,a);if(l>0&&C==null)break;a=await b(a,C),l++}while(l<k)}return a};t.options.persister?t.fetchFn=()=>{var m,y;return(y=(m=t.options).persister)==null?void 0:y.call(m,u,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},n)}:t.fetchFn=u}}}function Ak(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 R9(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 un,ho,po,Gl,Kl,mo,Yl,Xl,XE,I9=(XE=class{constructor(t={}){je(this,un);je(this,ho);je(this,po);je(this,Gl);je(this,Kl);je(this,mo);je(this,Yl);je(this,Xl);De(this,un,t.queryCache||new jO),De(this,ho,t.mutationCache||new WO),De(this,po,t.defaultOptions||{}),De(this,Gl,new Map),De(this,Kl,new Map),De(this,mo,0)}mount(){Yd(this,mo)._++,W(this,mo)===1&&(De(this,Yl,nw.subscribe(async t=>{t&&(await this.resumePausedMutations(),W(this,un).onFocus())})),De(this,Xl,pp.subscribe(async t=>{t&&(await this.resumePausedMutations(),W(this,un).onOnline())})))}unmount(){var t,n;Yd(this,mo)._--,W(this,mo)===0&&((t=W(this,Yl))==null||t.call(this),De(this,Yl,void 0),(n=W(this,Xl))==null||n.call(this),De(this,Xl,void 0))}isFetching(t){return W(this,un).findAll({...t,fetchStatus:"fetching"}).length}isMutating(t){return W(this,ho).findAll({...t,status:"pending"}).length}getQueryData(t){var r;const n=this.defaultQueryOptions({queryKey:t});return(r=W(this,un).get(n.queryHash))==null?void 0:r.state.data}ensureQueryData(t){const n=this.defaultQueryOptions(t),r=W(this,un).build(this,n),s=r.state.data;return s===void 0?this.fetchQuery(t):(t.revalidateIfStale&&r.isStaleByTime(Nl(n.staleTime,r))&&this.prefetchQuery(n),Promise.resolve(s))}getQueriesData(t){return W(this,un).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=W(this,un).get(s.queryHash),o=i==null?void 0:i.state.data,a=v9(n,o);if(a!==void 0)return W(this,un).build(this,s).setData(a,{...r,manual:!0})}setQueriesData(t,n,r){return $n.batch(()=>W(this,un).findAll(t).map(({queryKey:s})=>[s,this.setQueryData(s,n,r)]))}getQueryState(t){var r;const n=this.defaultQueryOptions({queryKey:t});return(r=W(this,un).get(n.queryHash))==null?void 0:r.state}removeQueries(t){const n=W(this,un);$n.batch(()=>{n.findAll(t).forEach(r=>{n.remove(r)})})}resetQueries(t,n){const r=W(this,un);return $n.batch(()=>(r.findAll(t).forEach(s=>{s.reset()}),this.refetchQueries({type:"active",...t},n)))}cancelQueries(t,n={}){const r={revert:!0,...n},s=$n.batch(()=>W(this,un).findAll(t).map(i=>i.cancel(r)));return Promise.all(s).then(es).catch(es)}invalidateQueries(t,n={}){return $n.batch(()=>(W(this,un).findAll(t).forEach(r=>{r.invalidate()}),(t==null?void 0:t.refetchType)==="none"?Promise.resolve():this.refetchQueries({...t,type:(t==null?void 0:t.refetchType)??(t==null?void 0:t.type)??"active"},n)))}refetchQueries(t,n={}){const r={...n,cancelRefetch:n.cancelRefetch??!0},s=$n.batch(()=>W(this,un).findAll(t).filter(i=>!i.isDisabled()).map(i=>{let o=i.fetch(void 0,r);return r.throwOnError||(o=o.catch(es)),i.state.fetchStatus==="paused"?Promise.resolve():o}));return Promise.all(s).then(es)}fetchQuery(t){const n=this.defaultQueryOptions(t);n.retry===void 0&&(n.retry=!1);const r=W(this,un).build(this,n);return r.isStaleByTime(Nl(n.staleTime,r))?r.fetch(n):Promise.resolve(r.state.data)}prefetchQuery(t){return this.fetchQuery(t).then(es).catch(es)}fetchInfiniteQuery(t){return t.behavior=Ik(t.pages),this.fetchQuery(t)}prefetchInfiniteQuery(t){return this.fetchInfiniteQuery(t).then(es).catch(es)}ensureInfiniteQueryData(t){return t.behavior=Ik(t.pages),this.ensureQueryData(t)}resumePausedMutations(){return pp.isOnline()?W(this,ho).resumePausedMutations():Promise.resolve()}getQueryCache(){return W(this,un)}getMutationCache(){return W(this,ho)}getDefaultOptions(){return W(this,po)}setDefaultOptions(t){De(this,po,t)}setQueryDefaults(t,n){W(this,Gl).set(Ya(t),{queryKey:t,defaultOptions:n})}getQueryDefaults(t){const n=[...W(this,Gl).values()],r={};return n.forEach(s=>{ld(t,s.queryKey)&&Object.assign(r,s.defaultOptions)}),r}setMutationDefaults(t,n){W(this,Kl).set(Ya(t),{mutationKey:t,defaultOptions:n})}getMutationDefaults(t){const n=[...W(this,Kl).values()],r={};return n.forEach(s=>{ld(t,s.mutationKey)&&Object.assign(r,s.defaultOptions)}),r}defaultQueryOptions(t){if(t._defaulted)return t;const n={...W(this,po).queries,...this.getQueryDefaults(t.queryKey),...t,_defaulted:!0};return n.queryHash||(n.queryHash=ew(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.queryFn===tw&&(n.enabled=!1),n}defaultMutationOptions(t){return t!=null&&t._defaulted?t:{...W(this,po).mutations,...(t==null?void 0:t.mutationKey)&&this.getMutationDefaults(t.mutationKey),...t,_defaulted:!0}}clear(){W(this,un).clear(),W(this,ho).clear()}},un=new WeakMap,ho=new WeakMap,po=new WeakMap,Gl=new WeakMap,Kl=new WeakMap,mo=new WeakMap,Yl=new WeakMap,Xl=new WeakMap,XE),wr,ht,yd,ar,_a,Ql,go,vo,bd,Jl,Zl,ka,xa,yo,eu,Pt,hc,Ky,Yy,Xy,Qy,Jy,Zy,eb,GO,QE,A9=(QE=class extends zu{constructor(t,n){super();je(this,Pt);je(this,wr);je(this,ht);je(this,yd);je(this,ar);je(this,_a);je(this,Ql);je(this,go);je(this,vo);je(this,bd);je(this,Jl);je(this,Zl);je(this,ka);je(this,xa);je(this,yo);je(this,eu,new Set);this.options=n,De(this,wr,t),De(this,vo,null),De(this,go,Gy()),this.options.experimental_prefetchInRender||W(this,go).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&&(W(this,ht).addObserver(this),Ok(W(this,ht),this.options)?tt(this,Pt,hc).call(this):this.updateResult(),tt(this,Pt,Qy).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return tb(W(this,ht),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return tb(W(this,ht),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,tt(this,Pt,Jy).call(this),tt(this,Pt,Zy).call(this),W(this,ht).removeObserver(this)}setOptions(t){const n=this.options,r=W(this,ht);if(this.options=W(this,wr).defaultQueryOptions(t),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof Cs(this.options.enabled,W(this,ht))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");tt(this,Pt,eb).call(this),W(this,ht).setOptions(this.options),n._defaulted&&!hp(this.options,n)&&W(this,wr).getQueryCache().notify({type:"observerOptionsUpdated",query:W(this,ht),observer:this});const s=this.hasListeners();s&&Mk(W(this,ht),r,this.options,n)&&tt(this,Pt,hc).call(this),this.updateResult(),s&&(W(this,ht)!==r||Cs(this.options.enabled,W(this,ht))!==Cs(n.enabled,W(this,ht))||Nl(this.options.staleTime,W(this,ht))!==Nl(n.staleTime,W(this,ht)))&&tt(this,Pt,Ky).call(this);const i=tt(this,Pt,Yy).call(this);s&&(W(this,ht)!==r||Cs(this.options.enabled,W(this,ht))!==Cs(n.enabled,W(this,ht))||i!==W(this,yo))&&tt(this,Pt,Xy).call(this,i)}getOptimisticResult(t){const n=W(this,wr).getQueryCache().build(W(this,wr),t),r=this.createResult(n,t);return M9(this,r)&&(De(this,ar,r),De(this,Ql,this.options),De(this,_a,W(this,ht).state)),r}getCurrentResult(){return W(this,ar)}trackResult(t,n){return new Proxy(t,{get:(r,s)=>(this.trackProp(s),n==null||n(s),Reflect.get(r,s))})}trackProp(t){W(this,eu).add(t)}getCurrentQuery(){return W(this,ht)}refetch({...t}={}){return this.fetch({...t})}fetchOptimistic(t){const n=W(this,wr).defaultQueryOptions(t),r=W(this,wr).getQueryCache().build(W(this,wr),n);return r.fetch().then(()=>this.createResult(r,n))}fetch(t){return tt(this,Pt,hc).call(this,{...t,cancelRefetch:t.cancelRefetch??!0}).then(()=>(this.updateResult(),W(this,ar)))}createResult(t,n){var E;const r=W(this,ht),s=this.options,i=W(this,ar),o=W(this,_a),a=W(this,Ql),u=t!==r?t.state:W(this,yd),{state:c}=t;let d={...c},f=!1,p;if(n._optimisticResults){const I=this.hasListeners(),O=!I&&Ok(t,n),R=I&&Mk(t,r,n,s);(O||R)&&(d={...d,...HO(c.data,t.options)}),n._optimisticResults==="isRestoring"&&(d.fetchStatus="idle")}let{error:g,errorUpdatedAt:m,status:y}=d;p=d.data;let w=!1;if(n.placeholderData!==void 0&&p===void 0&&y==="pending"){let I;i!=null&&i.isPlaceholderData&&n.placeholderData===(a==null?void 0:a.placeholderData)?(I=i.data,w=!0):I=typeof n.placeholderData=="function"?n.placeholderData((E=W(this,Zl))==null?void 0:E.state.data,W(this,Zl)):n.placeholderData,I!==void 0&&(y="success",p=qy(i==null?void 0:i.data,I,n),f=!0)}if(n.select&&p!==void 0&&!w)if(i&&p===(o==null?void 0:o.data)&&n.select===W(this,bd))p=W(this,Jl);else try{De(this,bd,n.select),p=n.select(p),p=qy(i==null?void 0:i.data,p,n),De(this,Jl,p),De(this,vo,null)}catch(I){De(this,vo,I)}W(this,vo)&&(g=W(this,vo),p=W(this,Jl),m=Date.now(),y="error");const b=d.fetchStatus==="fetching",k=y==="pending",C=y==="error",_=k&&b,T=p!==void 0,S={status:y,fetchStatus:d.fetchStatus,isPending:k,isSuccess:y==="success",isError:C,isInitialLoading:_,isLoading:_,data:p,dataUpdatedAt:d.dataUpdatedAt,error:g,errorUpdatedAt:m,failureCount:d.fetchFailureCount,failureReason:d.fetchFailureReason,errorUpdateCount:d.errorUpdateCount,isFetched:d.dataUpdateCount>0||d.errorUpdateCount>0,isFetchedAfterMount:d.dataUpdateCount>u.dataUpdateCount||d.errorUpdateCount>u.errorUpdateCount,isFetching:b,isRefetching:b&&!k,isLoadingError:C&&!T,isPaused:d.fetchStatus==="paused",isPlaceholderData:f,isRefetchError:C&&T,isStale:rw(t,n),refetch:this.refetch,promise:W(this,go)};if(this.options.experimental_prefetchInRender){const I=M=>{S.status==="error"?M.reject(S.error):S.data!==void 0&&M.resolve(S.data)},O=()=>{const M=De(this,go,S.promise=Gy());I(M)},R=W(this,go);switch(R.status){case"pending":t.queryHash===r.queryHash&&I(R);break;case"fulfilled":(S.status==="error"||S.data!==R.value)&&O();break;case"rejected":(S.status!=="error"||S.error!==R.reason)&&O();break}}return S}updateResult(){const t=W(this,ar),n=this.createResult(W(this,ht),this.options);if(De(this,_a,W(this,ht).state),De(this,Ql,this.options),W(this,_a).data!==void 0&&De(this,Zl,W(this,ht)),hp(n,t))return;De(this,ar,n);const r=()=>{if(!t)return!0;const{notifyOnChangeProps:s}=this.options,i=typeof s=="function"?s():s;if(i==="all"||!i&&!W(this,eu).size)return!0;const o=new Set(i??W(this,eu));return this.options.throwOnError&&o.add("error"),Object.keys(W(this,ar)).some(a=>{const l=a;return W(this,ar)[l]!==t[l]&&o.has(l)})};tt(this,Pt,GO).call(this,{listeners:r()})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&tt(this,Pt,Qy).call(this)}},wr=new WeakMap,ht=new WeakMap,yd=new WeakMap,ar=new WeakMap,_a=new WeakMap,Ql=new WeakMap,go=new WeakMap,vo=new WeakMap,bd=new WeakMap,Jl=new WeakMap,Zl=new WeakMap,ka=new WeakMap,xa=new WeakMap,yo=new WeakMap,eu=new WeakMap,Pt=new WeakSet,hc=function(t){tt(this,Pt,eb).call(this);let n=W(this,ht).fetch(this.options,t);return t!=null&&t.throwOnError||(n=n.catch(es)),n},Ky=function(){tt(this,Pt,Jy).call(this);const t=Nl(this.options.staleTime,W(this,ht));if(Ka||W(this,ar).isStale||!Hy(t))return;const r=$O(W(this,ar).dataUpdatedAt,t)+1;De(this,ka,setTimeout(()=>{W(this,ar).isStale||this.updateResult()},r))},Yy=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(W(this,ht)):this.options.refetchInterval)??!1},Xy=function(t){tt(this,Pt,Zy).call(this),De(this,yo,t),!(Ka||Cs(this.options.enabled,W(this,ht))===!1||!Hy(W(this,yo))||W(this,yo)===0)&&De(this,xa,setInterval(()=>{(this.options.refetchIntervalInBackground||nw.isFocused())&&tt(this,Pt,hc).call(this)},W(this,yo)))},Qy=function(){tt(this,Pt,Ky).call(this),tt(this,Pt,Xy).call(this,tt(this,Pt,Yy).call(this))},Jy=function(){W(this,ka)&&(clearTimeout(W(this,ka)),De(this,ka,void 0))},Zy=function(){W(this,xa)&&(clearInterval(W(this,xa)),De(this,xa,void 0))},eb=function(){const t=W(this,wr).getQueryCache().build(W(this,wr),this.options);if(t===W(this,ht))return;const n=W(this,ht);De(this,ht,t),De(this,yd,t.state),this.hasListeners()&&(n==null||n.removeObserver(this),t.addObserver(this))},GO=function(t){$n.batch(()=>{t.listeners&&this.listeners.forEach(n=>{n(W(this,ar))}),W(this,wr).getQueryCache().notify({query:W(this,ht),type:"observerResultsUpdated"})})},QE);function O9(e,t){return Cs(t.enabled,e)!==!1&&e.state.data===void 0&&!(e.state.status==="error"&&t.retryOnMount===!1)}function Ok(e,t){return O9(e,t)||e.state.data!==void 0&&tb(e,t,t.refetchOnMount)}function tb(e,t,n){if(Cs(t.enabled,e)!==!1){const r=typeof n=="function"?n(e):n;return r==="always"||r!==!1&&rw(e,t)}return!1}function Mk(e,t,n,r){return(e!==t||Cs(r.enabled,e)===!1)&&(!n.suspense||e.state.status!=="error")&&rw(e,n)}function rw(e,t){return Cs(t.enabled,e)!==!1&&e.isStaleByTime(Nl(t.staleTime,e))}function M9(e,t){return!hp(e.getCurrentResult(),t)}var bo,wo,Sr,Ai,Fi,fh,nb,JE,D9=(JE=class extends zu{constructor(n,r){super();je(this,Fi);je(this,bo);je(this,wo);je(this,Sr);je(this,Ai);De(this,bo,n),this.setOptions(r),this.bindMethods(),tt(this,Fi,fh).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=W(this,bo).defaultMutationOptions(n),hp(this.options,r)||W(this,bo).getMutationCache().notify({type:"observerOptionsUpdated",mutation:W(this,Sr),observer:this}),r!=null&&r.mutationKey&&this.options.mutationKey&&Ya(r.mutationKey)!==Ya(this.options.mutationKey)?this.reset():((s=W(this,Sr))==null?void 0:s.state.status)==="pending"&&W(this,Sr).setOptions(this.options)}onUnsubscribe(){var n;this.hasListeners()||(n=W(this,Sr))==null||n.removeObserver(this)}onMutationUpdate(n){tt(this,Fi,fh).call(this),tt(this,Fi,nb).call(this,n)}getCurrentResult(){return W(this,wo)}reset(){var n;(n=W(this,Sr))==null||n.removeObserver(this),De(this,Sr,void 0),tt(this,Fi,fh).call(this),tt(this,Fi,nb).call(this)}mutate(n,r){var s;return De(this,Ai,r),(s=W(this,Sr))==null||s.removeObserver(this),De(this,Sr,W(this,bo).getMutationCache().build(W(this,bo),this.options)),W(this,Sr).addObserver(this),W(this,Sr).execute(n)}},bo=new WeakMap,wo=new WeakMap,Sr=new WeakMap,Ai=new WeakMap,Fi=new WeakSet,fh=function(){var r;const n=((r=W(this,Sr))==null?void 0:r.state)??qO();De(this,wo,{...n,isPending:n.status==="pending",isSuccess:n.status==="success",isError:n.status==="error",isIdle:n.status==="idle",mutate:this.mutate,reset:this.reset})},nb=function(n){$n.batch(()=>{var r,s,i,o,a,l,u,c;if(W(this,Ai)&&this.hasListeners()){const d=W(this,wo).variables,f=W(this,wo).context;(n==null?void 0:n.type)==="success"?((s=(r=W(this,Ai)).onSuccess)==null||s.call(r,n.data,d,f),(o=(i=W(this,Ai)).onSettled)==null||o.call(i,n.data,null,d,f)):(n==null?void 0:n.type)==="error"&&((l=(a=W(this,Ai)).onError)==null||l.call(a,n.error,d,f),(c=(u=W(this,Ai)).onSettled)==null||c.call(u,void 0,n.error,d,f))}this.listeners.forEach(d=>{d(W(this,wo))})})},JE),L9="VUE_QUERY_CLIENT";function KO(e){const t=e?`:${e}`:"";return`${L9}${t}`}function rb(e,t){Object.keys(e).forEach(n=>{e[n]=t[n]})}function sb(e,t,n="",r=0){if(t){const s=t(e,n,r);if(s===void 0&&et(e)||s!==void 0)return s}if(Array.isArray(e))return e.map((s,i)=>sb(s,t,String(i),r+1));if(typeof e=="object"&&F9(e)){const s=Object.entries(e).map(([i,o])=>[i,sb(o,t,i,r+1)]);return Object.fromEntries(s)}return e}function $9(e,t){return sb(e,t)}function it(e,t=!1){return $9(e,(n,r,s)=>{if(s===1&&r==="queryKey")return it(n,!0);if(t&&N9(n))return it(n(),t);if(et(n))return it(Q(n),t)})}function F9(e){if(Object.prototype.toString.call(e)!=="[object Object]")return!1;const t=Object.getPrototypeOf(e);return t===null||t===Object.prototype}function N9(e){return typeof e=="function"}function sw(e=""){if(!YC())throw new Error("vue-query hooks can only be used inside setup() function or functions that support injection context.");const t=KO(e),n=Qe(t);if(!n)throw new Error("No 'queryClient' found in Vue context, use 'VueQueryPlugin' to properly initialize the library.");return n}var B9=class extends jO{find(e){return super.find(it(e))}findAll(e={}){return super.findAll(it(e))}},V9=class extends WO{find(e){return super.find(it(e))}findAll(e={}){return super.findAll(it(e))}},U9=class extends I9{constructor(e={}){const t={defaultOptions:e.defaultOptions,queryCache:e.queryCache||new B9,mutationCache:e.mutationCache||new V9};super(t),this.isRestoring=j(!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 Mt().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))}},z9={install:(e,t={})=>{const n=KO(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 U9(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 H9(e,t,n){const r=sw(),s=A(()=>{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=s.value.shallow?Mp(i.getCurrentResult()):cn(i.getCurrentResult());let a=()=>{};Ee(r.isRestoring,p=>{p||(a(),a=i.subscribe(g=>{rb(o,g)}))},{immediate:!0});const l=()=>{i.setOptions(s.value),rb(o,i.getCurrentResult())};Ee(s,l),yn(()=>{a()});const u=(...p)=>(l(),o.refetch(...p)),c=()=>new Promise((p,g)=>{let m=()=>{};const y=()=>{if(s.value.enabled!==!1){i.setOptions(s.value);const w=i.getOptimisticResult(s.value);w.isStale?(m(),i.fetchOptimistic(s.value).then(p,b=>{Wy(s.value.throwOnError,[b,i.getCurrentQuery()])?g(b):p(i.getCurrentResult())})):(m(),p(w))}};y(),m=Ee(s,y)});Ee(()=>o.error,p=>{if(o.isError&&!o.isFetching&&Wy(s.value.throwOnError,[p,i.getCurrentQuery()]))throw p});const d=s.value.shallow?Mb(o):zo(o),f=Qa(d);for(const p in o)typeof o[p]=="function"&&(f[p]=o[p]);return f.suspense=c,f.refetch=u,f}function Pm(e,t){return H9(A9,e)}function j9(e,t){const n=sw(),r=A(()=>n.defaultMutationOptions(it(e))),s=new D9(n,r.value),i=r.value.shallow?Mp(s.getCurrentResult()):cn(s.getCurrentResult()),o=s.subscribe(c=>{rb(i,c)}),a=(c,d)=>{s.mutate(c,d).catch(()=>{})};Ee(r,()=>{s.setOptions(r.value)}),yn(()=>{o()});const l=r.value.shallow?Mb(i):zo(i),u=Qa(l);return Ee(()=>i.error,c=>{if(c&&Wy(r.value.throwOnError,[c]))throw c}),{...u,mutate:a,mutateAsync:i.mutate,reset:i.reset}}const q9=de({...Ue(),...Or(),...cO()},"VLayout"),Rm=ke()({name:"VLayout",props:q9(),setup(e,t){let{slots:n}=t;const{layoutClasses:r,layoutStyles:s,getLayoutItem:i,items:o,layoutRef:a}=pO(e),{dimensionStyles:l}=Mr(e);return Oe(()=>{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}}}),W9={class:"text-h5"},G9={key:0},K9={key:1},Y9=Le({__name:"AddOrUpdateCameraStreamDialog",setup(e){const t=sw(),n=tn(nn.AddOrUpdateCameraDialog),r=A(()=>"C"),s=j({name:"",streamURL:""}),i=()=>{var d;return((d=n.context())==null?void 0:d.addOrUpdate)==="update"},o=A(()=>i());Ee(()=>n.context(),d=>{var p;if(!d||(d==null?void 0:d.addOrUpdate)!=="update"){s.value.streamURL="",s.value.name="";return}const f=(p=t.getQueryData(["cameraStream"]))==null?void 0:p.find(g=>g.cameraStream.id===d.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 fp.createCameraStream({streamURL:s.value.streamURL,name:s.value.name}),await t.refetchQueries({queryKey:["cameraStream"]}),n.closeDialog()}async function u(){var d;await fp.updateCameraStream((d=n.context())==null?void 0:d.cameraId,{streamURL:s.value.streamURL,name:s.value.name}),await t.refetchQueries({queryKey:["cameraStream"]}),n.closeDialog()}function c(){n.closeDialog()}return(d,f)=>{const p=hi;return $(),te(p,{id:Q(n).dialogId,"max-width":"800px",onEscape:f[3]||(f[3]=g=>a())},{default:v(()=>[h(vt,null,{default:v(()=>[h(sn,null,{default:v(()=>[L("span",W9,[h(ut,{class:"mr-2",color:"primary",size:"56"},{default:v(()=>[x(re(r.value),1)]),_:1}),o.value?($(),ve("span",G9," Updating Camera ")):($(),ve("span",K9," New Camera "))])]),_:1}),h(en,null,{default:v(()=>[h(Un,{"grid-list-md":""},{default:v(()=>[h(Rm,{wrap:""},{default:v(()=>[h(at,{modelValue:s.value.name,"onUpdate:modelValue":f[0]||(f[0]=g=>s.value.name=g),label:"Name",required:""},null,8,["modelValue"]),h(at,{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(Mn,null,{default:v(()=>[h(Sn),h(se,{color:"primary-darken-2",onClick:c},{default:v(()=>f[4]||(f[4]=[x(" Cancel ")])),_:1}),h(se,{color:"primary",onClick:f[2]||(f[2]=g=>o.value?u():l())},{default:v(()=>[x(re(o.value?"Update":"Create"),1)]),_:1})]),_:1})]),_:1})]),_:1},8,["id"])}}}),iw=gs("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 Qt.testConnection(e)},saveEvent(e){var t;(t=this.testPrinterEvents)==null||t.push(e)}}}),X9="error",Q9="success",J9=Le({__name:"PrinterChecksPanel",setup(e){const t=iw(),n=j(4);function r(){return t.getEvents().map(s=>({label:s.event,text:s.payload,color:s.failure?X9:Q9}))}return(s,i)=>($(),te(ze,{cols:Q(n)},{default:v(()=>[i[0]||(i[0]=L("strong",null," Checks: ",-1)),($(!0),ve(Ae,null,Gt(r(),(o,a)=>($(),te(fn,{key:a,type:o.color,density:"compact"},{default:v(()=>[L("small",null,re(o.label)+" "+re(o.text),1)]),_:2},1032,["type"]))),128))]),_:1},8,["cols"]))}}),Z9="/assets/klipper-logo-B1Hu-a1R.svg",eK="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3c!DOCTYPE%20svg%20PUBLIC%20'-//W3C//DTD%20SVG%201.1//EN'%20'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3e%3c!--%20Creator:%20CorelDRAW%202017%20--%3e%3csvg%20xmlns='http://www.w3.org/2000/svg'%20xml:space='preserve'%20width='76.1823mm'%20height='18.3444mm'%20version='1.1'%20style='shape-rendering:geometricPrecision;%20text-rendering:geometricPrecision;%20image-rendering:optimizeQuality;%20fill-rule:evenodd;%20clip-rule:evenodd'%20viewBox='0%200%205483.86%201320.49'%20xmlns:xlink='http://www.w3.org/1999/xlink'%3e%3cdefs%3e%3cstyle%20type='text/css'%3e%3c![CDATA[%20.fil0%20{fill:%23FEFEFE}%20.fil2%20{fill:%23FA6831}%20.fil3%20{fill:%23FEFEFE;fill-rule:nonzero}%20.fil1%20{fill:%232B2A29;fill-rule:nonzero}%20]]%3e%3c/style%3e%3c/defs%3e%3cg%20id='Layer_x0020_1'%3e%3cmetadata%20id='CorelCorpID_0Corel-Layer'/%3e%3cpath%20class='fil0'%20d='M-0%20385.77l3064.43%200%200%20934.72%20-3064.43%200%200%20-934.72zm5417.22%200l-2227.07%200%200%20934.72%202227.07%200%200%20-934.72z'/%3e%3cpath%20class='fil1'%20d='M3381.47%201144.22l426.16%200%200%20-131.38%20-273.43%200%200%20-454.89%20-152.73%200%200%20586.27zm-3073.6%20-463.92l102.63%200c46.8,0%2082.11,21.34%2082.11,77.18%200,53.37%20-33.66,73.08%20-82.11,73.08l-102.63%200%200%20-150.26zm-152.73%20463.92l152.73%200%200%20-195.42%20125.63%200c128.92,0%20211.85,-56.66%20211.85,-201.99%200,-138.76%20-102.64,-188.86%20-211.85,-188.86l-278.35%200%200%20586.27zm689.32%20-463.92l121.52%200c42.7,0%2077.18,19.7%2077.18,63.22%200,45.16%20-24.63,68.97%20-70.61,68.97l-128.09%200%200%20-132.2zm-152.73%20463.92l152.73%200%200%20-213.49%20115.78%200c72.26,0%2081.28,60.76%2085.39,119.88%202.46,17.25%204.1,73.08%2017.24,93.61l151.09%200c-20.53,-22.99%20-22.17,-106.74%20-24.63,-132.2%20-4.11,-55.84%20-23.81,-124.8%20-85.4,-140.41l0%20-1.64c62.41,-23.81%2091.97,-83.75%2091.97,-146.98%200,-118.24%20-102.63,-165.04%20-205.27,-165.04l-298.88%200%200%20586.27zm1073.59%20-586.27l-152.72%200%200%20353.08c0,75.54%20-27.1,114.13%20-102.64,114.13%20-75.54,0%20-102.63,-38.59%20-102.63,-114.13l0%20-353.08%20-152.73%200%200%20344.04c0,169.97%2078,254.54%20255.36,254.54%20177.36,0%20255.36,-84.57%20255.36,-254.54l0%20-344.04zm42.29%20389.21c0,150.26%20120.7,209.38%20254.54,209.38%20128.91,0%20255.36,-47.62%20255.36,-196.24%200,-105.92%20-85.39,-145.33%20-169.97,-169.15%20-85.39,-23.81%20-169.97,-31.2%20-169.97,-77.19%200,-38.59%2041.05,-50.09%2073.9,-50.09%2045.98,0%2096.89,18.07%2094.43,70.62l152.72%200c0,-131.38%20-119.06,-188.86%20-234.83,-188.86%20-110.03,0%20-238.94,50.09%20-238.94,178.18%200,108.39%2088.68,145.33%20171.61,169.15%2084.57,23.81%20168.33,32.85%20168.33,85.39%200,43.52%20-47.62,59.94%20-93.61,59.94%20-65.68,0%20-107.56,-22.17%20-110.85,-91.14l-152.72%200zm495.53%20197.06l156.83%200%2036.95%20-105.1%20204.45%200%2036.13%20105.1%20159.3%200%20-219.24%20-586.27%20-155.18%200%20-219.24%20586.27zm295.6%20-423.69l1.64%200%2064.86%20205.27%20-133.02%200%2066.51%20-205.27zm1258.56%20423.69l152.73%200%200%20-586.27%20-152.73%200%200%20586.27zm231.14%200l143.69%200%200%20-365.39%201.64%200%20203.63%20365.39%20156.83%200%200%20-586.27%20-143.69%200%200%20361.28%20-1.64%200%20-203.63%20-361.28%20-156.83%200%200%20586.27zm584.21%200l152.73%200%200%20-180.64%2062.4%20-65.68%20157.65%20246.33%20189.68%200%20-243.87%20-355.53%20216.77%20-230.74%20-189.68%200%20-192.96%20224.98%200%20-224.98%20-152.73%200%200%20586.27z'/%3e%3cpolygon%20class='fil2'%20points='5483.86,0%204170.36,0%204170.36,486.71%205483.86,486.71%20'/%3e%3cpath%20class='fil3'%20d='M4377.66%20154.79l62.68%200c16.97,0%2033.08,7.4%2033.08,30.03%200,22.2%20-19.15,29.6%20-33.08,29.6l-62.68%200%200%20-59.63zm-80.96%20248.1l149.29%200c66.6,0%20121,-22.63%20121,-96.63%200,-35.26%20-20.46,-63.55%20-53.54,-73.56%2024.38,-12.19%2040.92,-34.82%2040.92,-62.68%200,-64.42%20-58.76,-79.22%20-112.29,-77.91l-145.38%200%200%20310.77zm80.96%20-136.24l64.85%200c24.37,0%2043.53,9.14%2043.53,36.56%200,25.68%20-17.84,34.82%20-43.53,34.82l-64.85%200%200%20-71.38zm219.59%20136.24l252.01%200%200%20-69.64%20-171.05%200%200%20-59.19%20152.34%200%200%20-62.68%20-152.34%200%200%20-54.41%20166.71%200%200%20-64.85%20-247.67%200%200%20310.77zm530.8%20-310.77l-266.38%200%200%2069.64%2092.71%200%200%20241.14%2080.96%200%200%20-241.14%2092.71%200%200%20-69.64zm-49.83%20310.77l83.13%200%2019.59%20-55.72%20108.38%200%2019.15%2055.72%2084.44%200%20-116.21%20-310.77%20-82.27%200%20-116.21%20310.77zm156.69%20-224.6l0.87%200%2034.39%20108.82%20-70.51%200%2035.26%20-108.82z'/%3e%3c/g%3e%3c/svg%3e",YO=Symbol.for("vuetify:v-item-group"),tK=de({...Ue(),...Ed({selectedClass:"v-item--selected"}),...yt(),...Lt()},"VItemGroup"),nK=ke()({name:"VItemGroup",props:tK(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const{themeClasses:r}=Zt(e),{isSelected:s,select:i,next:o,prev:a,selected:l}=xu(e,YO);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})]}})}}),rK=ke()({name:"VItem",props:Cd(),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,YO);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})}}}),sK={class:"text-h5"},iK={key:0},oK={key:1},aK={class:"ml-3 align-center"},lK=Le({__name:"AddOrUpdatePrinterDialog",setup(e){const t=tn(nn.AddOrUpdatePrinterDialog),n=Ft(),r=iw(),s=Em(),i=Qe("appConstants"),o=Dt(),a=j(null),l=j(!1),u=j(!1),c=j(!1),d=j(""),f=j(Oy()),p=A(()=>{var D,F,U,K;if(s.hasFeature("multiplePrinterServices")){const X=s.getFeature("multiplePrinterServices"),H=(F=(D=X==null?void 0:X.subFeatures)==null?void 0:D.types)==null?void 0:F.includes("klipper"),B=(K=(U=X==null?void 0:X.subFeatures)==null?void 0:U.types)==null?void 0:K.includes("prusaLink");return[{name:Oc(ah),logo:$y,height:"60px"},...H?[{name:Oc(Fy),logo:Z9,height:"60px"}]:[],...B?[{name:Oc(lh),logo:eK,height:"20px"}]:[]]}return[{name:"OctoPrint",logo:$y,height:"75px"}]}),g=A(()=>{var D;return(D=n.updateDialogPrinter)==null?void 0:D.id});St(async()=>{if(g.value){const D=n.printer(g.value);f.value=Qt.convertPrinterToCreateForm(D)}}),Ee(g,D=>{if(!D)return;const F=n.printer(D);f.value=Qt.convertPrinterToCreateForm(F)});const m=A(()=>n.updateDialogPrinter),y=A(()=>!!m.value),w=A(()=>y?"Save":"Create"),b=A(()=>{var D;return f?Sm((D=f.value)==null?void 0:D.name):"?"}),k=A(()=>({required:!0,max:i.maxPrinterNameLength})),C=A(()=>({required:!0,length:i.apiKeyLength,alpha_num:!0}));function _(){f.value=Oy()}function T(){c.value=!0}async function P(){if(!S())return;r.clearEvents(),T();const{correlationToken:D}=await r.createTestPrinter(f.value);r.currentCorrelationToken=D}const S=()=>{var F,U,K,X,H,B,ee,q,G;const D=f.value;return D?ap(D.printerType)?((F=D.printerURL)==null?void 0:F.length)&&((U=D.name)==null?void 0:U.length):lp(D.printerType)?((K=D.printerURL)==null?void 0:K.length)&&((X=D.name)==null?void 0:X.length)&&((H=D.username)==null?void 0:H.length)&&((B=D.password)==null?void 0:B.length):((ee=D.printerURL)==null?void 0:ee.length)&&((q=D.name)==null?void 0:q.length)&&((G=D.apiKey)==null?void 0:G.length):!1};async function E(D){await n.createPrinter(D,u.value),o.openInfoMessage({title:`Printer ${D.name} created`})}async function I(D){const F=D.id;await n.updatePrinter({printerId:F,updatedPrinter:D},u.value),o.openInfoMessage({title:`Printer ${D.name} updated`})}async function O(){var F,U,K,X,H;if(!S())return;a.value=null,l.value=!0,(F=f.value.printerURL)!=null&&F.length&&!((U=f.value.printerURL)!=null&&U.startsWith("http://"))&&!((K=f.value.printerURL)!=null&&K.startsWith("https://"))&&(f.value.printerURL+="https://");const D=f.value;(ap(D.printerType)||lp(D.printerType))&&(D.apiKey="");try{y.value?await I(D):await E(D),M()}catch(B){B instanceof eR?(a.value=((H=(X=B.response)==null?void 0:X.data)==null?void 0:H.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 R(){f.value.name=Vu(),n.updateDialogPrinter=void 0,a.value=null,u.value=!1,a.value=null}function M(){t.closeDialog(),u.value=!1,a.value=null,c.value=!1,r.clearEvents(),_(),n.updateDialogPrinter=void 0,d.value=""}return(D,F)=>{const U=J9,K=hi;return $(),te(K,{id:Q(t).dialogId,"max-width":Q(c)?"900px":"700px",onEscape:F[13]||(F[13]=X=>M())},{default:v(()=>[h(vt,{class:"pa-4"},{default:v(()=>[h(sn,null,{default:v(()=>[L("span",sK,[h(ut,{color:"primary",size:"56"},{default:v(()=>[x(re(Q(b)),1)]),_:1}),Q(y)?($(),ve("span",iK," Updating Printer ")):($(),ve("span",oK," New Printer "))])]),_:1}),h(en,null,{default:v(()=>{var X;return[F[16]||(F[16]=L("h4",null,"Printer type",-1)),h(nK,{modelValue:Q(f).printerType,"onUpdate:modelValue":F[0]||(F[0]=H=>Q(f).printerType=H),mandatory:""},{default:v(()=>[h(Un,null,{default:v(()=>[h(rt,null,{default:v(()=>[($(!0),ve(Ae,null,Gt(Q(p),H=>($(),te(ze,{key:H.name,cols:"4",md:"4"},{default:v(()=>[h(rK,null,{default:v(({isSelected:B,toggle:ee})=>[h(vt,{color:B?"primary":"blue-grey darken-4",class:"d-flex align-center justify-center elevation-8",height:"60px",width:"225px",onClick:ee},{default:v(()=>[h(ds,{height:H.height,src:H.logo,"max-width":"100px",width:"125px"},null,8,["height","src"]),h(dN,null,{default:v(()=>[L("h3",aK,re(H.name),1)]),_:2},1024)]),_:2},1032,["color","onClick"])]),_:2},1024)]),_:2},1024))),128))]),_:1})]),_:1})]),_:1},8,["modelValue"]),h(rt,null,{default:v(()=>[h(ze,{cols:Q(c)?8:12},{default:v(()=>[Q(f)?($(),te(rt,{key:0},{default:v(()=>[h(ze,null,{default:v(()=>[h(at,{modelValue:Q(f).name,"onUpdate:modelValue":F[1]||(F[1]=H=>Q(f).name=H),counter:Q(k).max,autofocus:"",class:"ma-1",label:"Printer name*",required:""},null,8,["modelValue","counter"])]),_:1}),h(ze,null,{default:v(()=>[h(mn,{modelValue:Q(f).enabled,"onUpdate:modelValue":F[2]||(F[2]=H=>Q(f).enabled=H),hint:"Disabling makes the printer passive",label:"Enabled*","persistent-hint":"",required:""},null,8,["modelValue"])]),_:1})]),_:1})):pe("",!0),h(at,{modelValue:Q(f).printerURL,"onUpdate:modelValue":F[3]||(F[3]=H=>Q(f).printerURL=H),class:"ma-1",hint:"F.e. 'octopi.local' or 'https://my.printer.com'",label:"Printer URL*"},null,8,["modelValue"]),Q(f).printerType===Q(ah)?($(),te(at,{key:1,modelValue:Q(f).apiKey,"onUpdate:modelValue":F[4]||(F[4]=H=>Q(f).apiKey=H),counter:Q(C).length,class:"ma-1",hint:"User or Application Key with 32 or 43 characters (Global API key will fail)",label:Q(f).printerType===Q(ah)||Q(f).printerType===Q(Fy)?"API Key (unsupported)":"API Key (required)*","persistent-hint":"",required:""},null,8,["modelValue","counter","label"])):pe("",!0),Q(f).printerType===Q(lh)?($(),te(at,{key:2,modelValue:Q(f).username,"onUpdate:modelValue":F[5]||(F[5]=H=>Q(f).username=H),class:"ma-1",hint:"Username (often 'maker')",label:"Username","persistent-hint":"",required:""},null,8,["modelValue"])):pe("",!0),Q(f).printerType===Q(lh)?($(),te(at,{key:3,modelValue:Q(f).password,"onUpdate:modelValue":F[6]||(F[6]=H=>Q(f).password=H),class:"ma-1",hint:"Password (visit your printer settings)",label:"Password","persistent-hint":"",required:""},null,8,["modelValue"])):pe("",!0)]),_:1},8,["cols"]),Q(c)?($(),te(U,{key:0,cols:4},{default:v(()=>[h(se,{onClick:F[7]||(F[7]=H=>c.value=!1)},{default:v(()=>F[14]||(F[14]=[x(" Hide checks")])),_:1})]),_:1})):pe("",!0)]),_:1}),(X=Q(a))!=null&&X.length?($(),te(fn,{key:0,class:"my-3",color:"primary"},{default:v(()=>[x(re(Q(a))+" ",1),h(mn,{modelValue:Q(u),"onUpdate:modelValue":F[8]||(F[8]=H=>et(u)?u.value=H:null),color:"warning",label:"Force save"},null,8,["modelValue"])]),_:1})):pe("",!0),Q(l)?($(),te(fn,{key:1,class:"my-3"},{default:v(()=>[F[15]||(F[15]=x(" Validating printer ")),h(ni,{indeterminate:""})]),_:1})):pe("",!0)]}),_:1}),h(Mn,null,{default:v(()=>[F[20]||(F[20]=L("em",{class:"text-red"}," * indicates required field ",-1)),h(Sn),h(se,{variant:"text",onClick:F[9]||(F[9]=X=>M())},{default:v(()=>F[17]||(F[17]=[x(" Close ")])),_:1}),Q(y)?($(),te(se,{key:0,color:"gray",variant:"text",onClick:F[10]||(F[10]=X=>R())},{default:v(()=>F[18]||(F[18]=[x(" Duplicate ")])),_:1})):pe("",!0),h(se,{color:"warning",variant:"text",onClick:F[11]||(F[11]=X=>P())},{default:v(()=>F[19]||(F[19]=[x(" Test connection ")])),_:1}),h(se,{color:"blue-darken-1",variant:"text",onClick:F[12]||(F[12]=X=>O())},{default:v(()=>[x(re(Q(w)),1)]),_:1})]),_:1})]),_:1})]),_:1},8,["id","max-width"])}}}),uK=de({text:String,...Ue(),...yt()},"VToolbarTitle"),En=ke()({name:"VToolbarTitle",props:uK(),setup(e,t){let{slots:n}=t;return Oe(()=>{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)])]}})}),{}}}),cK=[null,"prominent","default","comfortable","compact"],XO=de({absolute:Boolean,collapse:Boolean,color:String,density:{type:String,default:"default",validator:e=>cK.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(),...Ue(),...bs(),...Dn(),...yt({tag:"header"}),...Lt()},"VToolbar"),mr=ke()({name:"VToolbar",props:XO(),setup(e,t){var p;let{slots:n}=t;const{backgroundColorClasses:r,backgroundColorStyles:s}=fr(()=>e.color),{borderClasses:i}=Ds(e),{elevationClasses:o}=Ls(e),{roundedClasses:a}=zn(e),{themeClasses:l}=Zt(e),{rtlClasses:u}=Dr(),c=Ie(!!(e.extended||(p=n.extension)!=null&&p.call(n))),d=A(()=>parseInt(Number(e.height)+(e.density==="prominent"?Number(e.height):0)-(e.density==="comfortable"?8:0)-(e.density==="compact"?16:0),10)),f=A(()=>c.value?parseInt(Number(e.extensionHeight)+(e.density==="prominent"?Number(e.extensionHeight):0)-(e.density==="comfortable"?4:0)-(e.density==="compact"?8:0),10):0);return Ir({VBtn:{variant:"text"}}),Oe(()=>{var w;const g=!!(e.title||n.title),m=!!(n.image||e.image),y=(w=n.extension)==null?void 0:w.call(n);return c.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(Ot,{key:"image-defaults",disabled:!e.image,defaults:{VImg:{cover:!0,src:e.image}}},n.image):h(ds,{key:"image-img",cover:!0,src:e.image},null)]),h(Ot,{defaults:{VTabs:{height:Ne(d.value)}}},{default:()=>{var b,k,C;return[h("div",{class:"v-toolbar__content",style:{height:Ne(d.value)}},[n.prepend&&h("div",{class:"v-toolbar__prepend"},[(b=n.prepend)==null?void 0:b.call(n)]),g&&h(En,{key:"title",text:e.title},{text:n.title}),(k=n.default)==null?void 0:k.call(n),n.append&&h("div",{class:"v-toolbar__append"},[(C=n.append)==null?void 0:C.call(n)])])]}}),h(Ot,{defaults:{VTabs:{height:Ne(f.value)}}},{default:()=>[h(bP,null,{default:()=>[c.value&&h("div",{class:"v-toolbar__extension",style:{height:Ne(f.value)}},[y])]})]})]})}),{contentHeight:d,extensionHeight:f}}}),dK=Le({__name:"HelpOverlay",setup(e){const t=j(!1);return(n,r)=>($(),te(PP,{modelValue:Q(t),"onUpdate:modelValue":r[0]||(r[0]=s=>et(t)?t.value=s:null),fullscreen:"",eager:"",transition:"dialog-bottom-transition",width:"100%"},{activator:v(({props:s})=>[h(nt,{location:"top"},{activator:v(({props:i})=>[h(se,ge({icon:"help"},{...s,...i}),{default:v(()=>[h(J,null,{default:v(()=>r[1]||(r[1]=[x("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(vt,{height:"100%",width:"100%"},{default:v(()=>[h(mr,{color:"primary"},{default:v(()=>[h(J,{class:"ml-5"},{default:v(()=>r[3]||(r[3]=[x("help")])),_:1}),r[6]||(r[6]=L("h2",{class:"ml-10"},"FDM Monster Documentation",-1)),h(Sn),r[7]||(r[7]=L("span",{class:"mr-10"}," docs.fdm-monster.net ",-1)),h(se,{variant:"flat",onClick:i=>s.value=!1},{default:v(()=>[h(J,{class:"mr-2"},{default:v(()=>r[4]||(r[4]=[x("close")])),_:1}),r[5]||(r[5]=x(" 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"]))}}),fK=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)=>($(),te(nt,{location:t.location},{activator:v(({props:s})=>[h(se,ge(s,{variant:"outlined",class:"ml-2",color:n.color,onClick:r[0]||(r[0]=i=>n.$emit("click"))}),{default:v(()=>[Vp(n.$slots,"default",{},()=>{var i;return[(i=t.icon)!=null&&i.length?($(),te(J,{key:0,class:Bo("mr-2 "+t.iconClass)},{default:v(()=>[x(re(t.icon),1)]),_:1},8,["class"])):pe("",!0),x(" "+re(t.text),1)]})]),_:2},1040,["color"])]),default:v(()=>[L("span",null,re(t.tooltip),1)]),_:3},8,["location"]))}});/*!
|
|
67
|
+
* vue-router v4.5.1
|
|
68
|
+
* (c) 2025 Eduardo San Martin Morote
|
|
69
|
+
* @license MIT
|
|
70
|
+
*/const kl=typeof document<"u";function QO(e){return typeof e=="object"||"displayName"in e||"props"in e||"__vccOpts"in e}function hK(e){return e.__esModule||e[Symbol.toStringTag]==="Module"||e.default&&QO(e.default)}const Ct=Object.assign;function Hg(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 Mc=()=>{},Os=Array.isArray,JO=/#/g,pK=/&/g,mK=/\//g,gK=/=/g,vK=/\?/g,ZO=/\+/g,yK=/%5B/g,bK=/%5D/g,eM=/%5E/g,wK=/%60/g,tM=/%7B/g,SK=/%7C/g,nM=/%7D/g,_K=/%20/g;function ow(e){return encodeURI(""+e).replace(SK,"|").replace(yK,"[").replace(bK,"]")}function kK(e){return ow(e).replace(tM,"{").replace(nM,"}").replace(eM,"^")}function ib(e){return ow(e).replace(ZO,"%2B").replace(_K,"+").replace(JO,"%23").replace(pK,"%26").replace(wK,"`").replace(tM,"{").replace(nM,"}").replace(eM,"^")}function xK(e){return ib(e).replace(gK,"%3D")}function EK(e){return ow(e).replace(JO,"%23").replace(vK,"%3F")}function CK(e){return e==null?"":EK(e).replace(mK,"%2F")}function ud(e){try{return decodeURIComponent(""+e)}catch{}return""+e}const TK=/\/$/,PK=e=>e.replace(TK,"");function jg(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=OK(r??t,n),{fullPath:r+(i&&"?")+i+o,path:r,query:s,hash:ud(o)}}function RK(e,t){const n=t.query?e(t.query):"";return t.path+(n&&"?")+n+(t.hash||"")}function Dk(e,t){return!t||!e.toLowerCase().startsWith(t.toLowerCase())?e:e.slice(t.length)||"/"}function IK(e,t,n){const r=t.matched.length-1,s=n.matched.length-1;return r>-1&&r===s&&vu(t.matched[r],n.matched[s])&&rM(t.params,n.params)&&e(t.query)===e(n.query)&&t.hash===n.hash}function vu(e,t){return(e.aliasOf||e)===(t.aliasOf||t)}function rM(e,t){if(Object.keys(e).length!==Object.keys(t).length)return!1;for(const n in e)if(!AK(e[n],t[n]))return!1;return!0}function AK(e,t){return Os(e)?Lk(e,t):Os(t)?Lk(t,e):e===t}function Lk(e,t){return Os(t)?e.length===t.length&&e.every((n,r)=>n===t[r]):e.length===1&&e[0]===t}function OK(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 cd;(function(e){e.pop="pop",e.push="push"})(cd||(cd={}));var Dc;(function(e){e.back="back",e.forward="forward",e.unknown=""})(Dc||(Dc={}));function MK(e){if(!e)if(kl){const t=document.querySelector("base");e=t&&t.getAttribute("href")||"/",e=e.replace(/^\w+:\/\/[^\/]+/,"")}else e="/";return e[0]!=="/"&&e[0]!=="#"&&(e="/"+e),PK(e)}const DK=/^[^#]+#/;function LK(e,t){return e.replace(DK,"#")+t}function $K(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 Im=()=>({left:window.scrollX,top:window.scrollY});function FK(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=$K(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 $k(e,t){return(history.state?history.state.position-t:-1)+e}const ob=new Map;function NK(e,t){ob.set(e,t)}function BK(e){const t=ob.get(e);return ob.delete(e),t}let VK=()=>location.protocol+"//"+location.host;function sM(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),Dk(l,"")}return Dk(n,e)+r+s}function UK(e,t,n,r){let s=[],i=[],o=null;const a=({state:f})=>{const p=sM(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(w=>{w(n.value,g,{delta:y,type:cd.pop,direction:y?y>0?Dc.forward:Dc.back:Dc.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 c(){const{history:f}=window;f.state&&f.replaceState(Ct({},f.state,{scroll:Im()}),"")}function d(){for(const f of i)f();i=[],window.removeEventListener("popstate",a),window.removeEventListener("beforeunload",c)}return window.addEventListener("popstate",a),window.addEventListener("beforeunload",c,{passive:!0}),{pauseListeners:l,listen:u,destroy:d}}function Fk(e,t,n,r=!1,s=!1){return{back:e,current:t,forward:n,replaced:r,position:window.history.length,scroll:s?Im():null}}function zK(e){const{history:t,location:n}=window,r={value:sM(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,c){const d=e.indexOf("#"),f=d>-1?(n.host&&document.querySelector("base")?e:e.slice(d))+l:VK()+e+l;try{t[c?"replaceState":"pushState"](u,"",f),s.value=u}catch(p){console.error(p),n[c?"replace":"assign"](f)}}function o(l,u){const c=Ct({},t.state,Fk(s.value.back,l,s.value.forward,!0),u,{position:s.value.position});i(l,c,!0),r.value=l}function a(l,u){const c=Ct({},s.value,t.state,{forward:l,scroll:Im()});i(c.current,c,!0);const d=Ct({},Fk(r.value,l,null),{position:c.position+1},u);i(l,d,!1),r.value=l}return{location:r,state:s,push:a,replace:o}}function HK(e){e=MK(e);const t=zK(e),n=UK(e,t.state,t.location,t.replace);function r(i,o=!0){o||n.pauseListeners(),history.go(i)}const s=Ct({location:"",base:e,go:r,createHref:LK.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 jK(e){return typeof e=="string"||e&&typeof e=="object"}function iM(e){return typeof e=="string"||typeof e=="symbol"}const oM=Symbol("");var Nk;(function(e){e[e.aborted=4]="aborted",e[e.cancelled=8]="cancelled",e[e.duplicated=16]="duplicated"})(Nk||(Nk={}));function yu(e,t){return Ct(new Error,{type:e,[oM]:!0},t)}function wi(e,t){return e instanceof Error&&oM in e&&(t==null||!!(e.type&t))}const Bk="[^/]+?",qK={sensitive:!1,strict:!1,start:!0,end:!0},WK=/[.+*?^${}()[\]/\\]/g;function GK(e,t){const n=Ct({},qK,t),r=[];let s=n.start?"^":"";const i=[];for(const u of e){const c=u.length?[]:[90];n.strict&&!u.length&&(s+="/");for(let d=0;d<u.length;d++){const f=u[d];let p=40+(n.sensitive?.25:0);if(f.type===0)d||(s+="/"),s+=f.value.replace(WK,"\\$&"),p+=40;else if(f.type===1){const{value:g,repeatable:m,optional:y,regexp:w}=f;i.push({name:g,repeatable:m,optional:y});const b=w||Bk;if(b!==Bk){p+=10;try{new RegExp(`(${b})`)}catch(C){throw new Error(`Invalid custom RegExp for param "${g}" (${b}): `+C.message)}}let k=m?`((?:${b})(?:/(?:${b}))*)`:`(${b})`;d||(k=y&&u.length<2?`(?:/${k})`:"/"+k),y&&(k+="?"),s+=k,p+=20,y&&(p+=-8),m&&(p+=-20),b===".*"&&(p+=-50)}c.push(p)}r.push(c)}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.endsWith("/")&&(s+="(?:/|$)");const o=new RegExp(s,n.sensitive?"":"i");function a(u){const c=u.match(o),d={};if(!c)return null;for(let f=1;f<c.length;f++){const p=c[f]||"",g=i[f-1];d[g.name]=p&&g.repeatable?p.split("/"):p}return d}function l(u){let c="",d=!1;for(const f of e){(!d||!c.endsWith("/"))&&(c+="/"),d=!1;for(const p of f)if(p.type===0)c+=p.value;else if(p.type===1){const{value:g,repeatable:m,optional:y}=p,w=g in u?u[g]:"";if(Os(w)&&!m)throw new Error(`Provided param "${g}" is an array but it is not repeatable (* or + modifiers)`);const b=Os(w)?w.join("/"):w;if(!b)if(y)f.length<2&&(c.endsWith("/")?c=c.slice(0,-1):d=!0);else throw new Error(`Missing required param "${g}"`);c+=b}}return c||"/"}return{re:o,score:r,keys:i,parse:a,stringify:l}}function KK(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 aM(e,t){let n=0;const r=e.score,s=t.score;for(;n<r.length&&n<s.length;){const i=KK(r[n],s[n]);if(i)return i;n++}if(Math.abs(s.length-r.length)===1){if(Vk(r))return 1;if(Vk(s))return-1}return s.length-r.length}function Vk(e){const t=e[e.length-1];return e.length>0&&t[t.length-1]<0}const YK={type:0,value:""},XK=/[a-zA-Z0-9_]/;function QK(e){if(!e)return[[]];if(e==="/")return[[YK]];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="",c="";function d(){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:c,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&&d(),o()):l===":"?(d(),n=1):f();break;case 4:f(),n=r;break;case 1:l==="("?n=2:XK.test(l)?f():(d(),n=0,l!=="*"&&l!=="?"&&l!=="+"&&a--);break;case 2:l===")"?c[c.length-1]=="\\"?c=c.slice(0,-1)+l:n=3:c+=l;break;case 3:d(),n=0,l!=="*"&&l!=="?"&&l!=="+"&&a--,c="";break;default:t("Unknown state");break}}return n===2&&t(`Unfinished custom RegExp for param "${u}"`),d(),o(),s}function JK(e,t,n){const r=GK(QK(e.path),n),s=Ct(r,{record:e,parent:t,children:[],alias:[]});return t&&!s.record.aliasOf==!t.record.aliasOf&&t.children.push(s),s}function ZK(e,t){const n=[],r=new Map;t=jk({strict:!1,end:!0,sensitive:!1},t);function s(d){return r.get(d)}function i(d,f,p){const g=!p,m=zk(d);m.aliasOf=p&&p.record;const y=jk(t,d),w=[m];if("alias"in d){const C=typeof d.alias=="string"?[d.alias]:d.alias;for(const _ of C)w.push(zk(Ct({},m,{components:p?p.record.components:m.components,path:_,aliasOf:p?p.record:m})))}let b,k;for(const C of w){const{path:_}=C;if(f&&_[0]!=="/"){const T=f.record.path,P=T[T.length-1]==="/"?"":"/";C.path=f.record.path+(_&&P+_)}if(b=JK(C,f,y),p?p.alias.push(b):(k=k||b,k!==b&&k.alias.push(b),g&&d.name&&!Hk(b)&&o(d.name)),lM(b)&&l(b),m.children){const T=m.children;for(let P=0;P<T.length;P++)i(T[P],b,p&&p.children[P])}p=p||b}return k?()=>{o(k)}:Mc}function o(d){if(iM(d)){const f=r.get(d);f&&(r.delete(d),n.splice(n.indexOf(f),1),f.children.forEach(o),f.alias.forEach(o))}else{const f=n.indexOf(d);f>-1&&(n.splice(f,1),d.record.name&&r.delete(d.record.name),d.children.forEach(o),d.alias.forEach(o))}}function a(){return n}function l(d){const f=nY(d,n);n.splice(f,0,d),d.record.name&&!Hk(d)&&r.set(d.record.name,d)}function u(d,f){let p,g={},m,y;if("name"in d&&d.name){if(p=r.get(d.name),!p)throw yu(1,{location:d});y=p.record.name,g=Ct(Uk(f.params,p.keys.filter(k=>!k.optional).concat(p.parent?p.parent.keys.filter(k=>k.optional):[]).map(k=>k.name)),d.params&&Uk(d.params,p.keys.map(k=>k.name))),m=p.stringify(g)}else if(d.path!=null)m=d.path,p=n.find(k=>k.re.test(m)),p&&(g=p.parse(m),y=p.record.name);else{if(p=f.name?r.get(f.name):n.find(k=>k.re.test(f.path)),!p)throw yu(1,{location:d,currentLocation:f});y=p.record.name,g=Ct({},f.params,d.params),m=p.stringify(g)}const w=[];let b=p;for(;b;)w.unshift(b.record),b=b.parent;return{name:y,path:m,params:g,matched:w,meta:tY(w)}}e.forEach(d=>i(d));function c(){n.length=0,r.clear()}return{addRoute:i,resolve:u,removeRoute:o,clearRoutes:c,getRoutes:a,getRecordMatcher:s}}function Uk(e,t){const n={};for(const r of t)r in e&&(n[r]=e[r]);return n}function zk(e){const t={path:e.path,redirect:e.redirect,name:e.name,meta:e.meta||{},aliasOf:e.aliasOf,beforeEnter:e.beforeEnter,props:eY(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 eY(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 Hk(e){for(;e;){if(e.record.aliasOf)return!0;e=e.parent}return!1}function tY(e){return e.reduce((t,n)=>Ct(t,n.meta),{})}function jk(e,t){const n={};for(const r in e)n[r]=r in t?t[r]:e[r];return n}function nY(e,t){let n=0,r=t.length;for(;n!==r;){const i=n+r>>1;aM(e,t[i])<0?r=i:n=i+1}const s=rY(e);return s&&(r=t.lastIndexOf(s,r-1)),r}function rY(e){let t=e;for(;t=t.parent;)if(lM(t)&&aM(e,t)===0)return t}function lM({record:e}){return!!(e.name||e.components&&Object.keys(e.components).length||e.redirect)}function sY(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(ZO," "),o=i.indexOf("="),a=ud(o<0?i:i.slice(0,o)),l=o<0?null:ud(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 qk(e){let t="";for(let n in e){const r=e[n];if(n=xK(n),r==null){r!==void 0&&(t+=(t.length?"&":"")+n);continue}(Os(r)?r.map(i=>i&&ib(i)):[r&&ib(r)]).forEach(i=>{i!==void 0&&(t+=(t.length?"&":"")+n,i!=null&&(t+="="+i))})}return t}function iY(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 oY=Symbol(""),Wk=Symbol(""),Am=Symbol(""),aw=Symbol(""),ab=Symbol("");function nc(){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 uo(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(yu(4,{from:n,to:t})):f instanceof Error?l(f):jK(f)?l(yu(2,{from:t,to:f})):(o&&r.enterCallbacks[s]===o&&typeof f=="function"&&o.push(f),a())},c=i(()=>e.call(r&&r.instances[s],t,n,u));let d=Promise.resolve(c);e.length<3&&(d=d.then(u)),d.catch(f=>l(f))})}function qg(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(QO(l)){const c=(l.__vccOpts||l)[t];c&&i.push(uo(c,n,r,o,a,s))}else{let u=l();i.push(()=>u.then(c=>{if(!c)throw new Error(`Couldn't resolve component "${a}" at "${o.path}"`);const d=hK(c)?c.default:c;o.mods[a]=c,o.components[a]=d;const p=(d.__vccOpts||d)[t];return p&&uo(p,n,r,o,a,s)()}))}}return i}function Gk(e){const t=Qe(Am),n=Qe(aw),r=A(()=>{const l=Q(e.to);return t.resolve(l)}),s=A(()=>{const{matched:l}=r.value,{length:u}=l,c=l[u-1],d=n.matched;if(!c||!d.length)return-1;const f=d.findIndex(vu.bind(null,c));if(f>-1)return f;const p=Kk(l[u-2]);return u>1&&Kk(c)===p&&d[d.length-1].path!==p?d.findIndex(vu.bind(null,l[u-2])):f}),i=A(()=>s.value>-1&&dY(n.params,r.value.params)),o=A(()=>s.value>-1&&s.value===n.matched.length-1&&rM(n.params,r.value.params));function a(l={}){if(cY(l)){const u=t[Q(e.replace)?"replace":"push"](Q(e.to)).catch(Mc);return e.viewTransition&&typeof document<"u"&&"startViewTransition"in document&&document.startViewTransition(()=>u),u}return Promise.resolve()}return{route:r,href:A(()=>r.value.href),isActive:i,isExactActive:o,navigate:a}}function aY(e){return e.length===1?e[0]:e}const lY=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"},viewTransition:Boolean},useLink:Gk,setup(e,{slots:t}){const n=cn(Gk(e)),{options:r}=Qe(Am),s=A(()=>({[Yk(e.activeClass,r.linkActiveClass,"router-link-active")]:n.isActive,[Yk(e.exactActiveClass,r.linkExactActiveClass,"router-link-exact-active")]:n.isExactActive}));return()=>{const i=t.default&&aY(t.default(n));return e.custom?i:pr("a",{"aria-current":n.isExactActive?e.ariaCurrentValue:null,href:n.href,onClick:n.navigate,class:s.value},i)}}}),uY=lY;function cY(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 dY(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 Kk(e){return e?e.aliasOf?e.aliasOf.path:e.path:""}const Yk=(e,t,n)=>e??t??n,fY=Le({name:"RouterView",inheritAttrs:!1,props:{name:{type:String,default:"default"},route:Object},compatConfig:{MODE:3},setup(e,{attrs:t,slots:n}){const r=Qe(ab),s=A(()=>e.route||r.value),i=Qe(Wk,0),o=A(()=>{let u=Q(i);const{matched:c}=s.value;let d;for(;(d=c[u])&&!d.components;)u++;return u}),a=A(()=>s.value.matched[o.value]);Kt(Wk,A(()=>o.value+1)),Kt(oY,a),Kt(ab,s);const l=j();return Ee(()=>[l.value,a.value,e.name],([u,c,d],[f,p,g])=>{c&&(c.instances[d]=u,p&&p!==c&&u&&u===f&&(c.leaveGuards.size||(c.leaveGuards=p.leaveGuards),c.updateGuards.size||(c.updateGuards=p.updateGuards))),u&&c&&(!p||!vu(c,p)||!f)&&(c.enterCallbacks[d]||[]).forEach(m=>m(u))},{flush:"post"}),()=>{const u=s.value,c=e.name,d=a.value,f=d&&d.components[c];if(!f)return Xk(n.default,{Component:f,route:u});const p=d.props[c],g=p?p===!0?u.params:typeof p=="function"?p(u):p:null,y=pr(f,Ct({},g,t,{onVnodeUnmounted:w=>{w.component.isUnmounted&&(d.instances[c]=null)},ref:l}));return Xk(n.default,{Component:y,route:u})||y}}});function Xk(e,t){if(!e)return null;const n=e(t);return n.length===1?n[0]:n}const hY=fY;function pY(e){const t=ZK(e.routes,e),n=e.parseQuery||sY,r=e.stringifyQuery||qk,s=e.history,i=nc(),o=nc(),a=nc(),l=Ie(Zi);let u=Zi;kl&&e.scrollBehavior&&"scrollRestoration"in history&&(history.scrollRestoration="manual");const c=Hg.bind(null,Z=>""+Z),d=Hg.bind(null,CK),f=Hg.bind(null,ud);function p(Z,he){let ne,z;return iM(Z)?(ne=t.getRecordMatcher(Z),z=he):z=Z,t.addRoute(z,ne)}function g(Z){const he=t.getRecordMatcher(Z);he&&t.removeRoute(he)}function m(){return t.getRoutes().map(Z=>Z.record)}function y(Z){return!!t.getRecordMatcher(Z)}function w(Z,he){if(he=Ct({},he||l.value),typeof Z=="string"){const V=jg(n,Z,he.path),Y=t.resolve({path:V.path},he),fe=s.createHref(V.fullPath);return Ct(V,Y,{params:f(Y.params),hash:ud(V.hash),redirectedFrom:void 0,href:fe})}let ne;if(Z.path!=null)ne=Ct({},Z,{path:jg(n,Z.path,he.path).path});else{const V=Ct({},Z.params);for(const Y in V)V[Y]==null&&delete V[Y];ne=Ct({},Z,{params:d(V)}),he.params=d(he.params)}const z=t.resolve(ne,he),xe=Z.hash||"";z.params=c(f(z.params));const Fe=RK(r,Ct({},Z,{hash:kK(xe),path:z.path})),N=s.createHref(Fe);return Ct({fullPath:Fe,hash:xe,query:r===qk?iY(Z.query):Z.query||{}},z,{redirectedFrom:void 0,href:N})}function b(Z){return typeof Z=="string"?jg(n,Z,l.value.path):Ct({},Z)}function k(Z,he){if(u!==Z)return yu(8,{from:he,to:Z})}function C(Z){return P(Z)}function _(Z){return C(Ct(b(Z),{replace:!0}))}function T(Z){const he=Z.matched[Z.matched.length-1];if(he&&he.redirect){const{redirect:ne}=he;let z=typeof ne=="function"?ne(Z):ne;return typeof z=="string"&&(z=z.includes("?")||z.includes("#")?z=b(z):{path:z},z.params={}),Ct({query:Z.query,hash:Z.hash,params:z.path!=null?{}:Z.params},z)}}function P(Z,he){const ne=u=w(Z),z=l.value,xe=Z.state,Fe=Z.force,N=Z.replace===!0,V=T(ne);if(V)return P(Ct(b(V),{state:typeof V=="object"?Ct({},xe,V.state):xe,force:Fe,replace:N}),he||ne);const Y=ne;Y.redirectedFrom=he;let fe;return!Fe&&IK(r,z,ne)&&(fe=yu(16,{to:Y,from:z}),ee(z,z,!0,!1)),(fe?Promise.resolve(fe):I(Y,z)).catch(ce=>wi(ce)?wi(ce,2)?ce:B(ce):X(ce,Y,z)).then(ce=>{if(ce){if(wi(ce,2))return P(Ct({replace:N},b(ce.to),{state:typeof ce.to=="object"?Ct({},xe,ce.to.state):xe,force:Fe}),he||Y)}else ce=R(Y,z,!0,N,xe);return O(Y,z,ce),ce})}function S(Z,he){const ne=k(Z,he);return ne?Promise.reject(ne):Promise.resolve()}function E(Z){const he=le.values().next().value;return he&&typeof he.runWithContext=="function"?he.runWithContext(Z):Z()}function I(Z,he){let ne;const[z,xe,Fe]=mY(Z,he);ne=qg(z.reverse(),"beforeRouteLeave",Z,he);for(const V of z)V.leaveGuards.forEach(Y=>{ne.push(uo(Y,Z,he))});const N=S.bind(null,Z,he);return ne.push(N),Se(ne).then(()=>{ne=[];for(const V of i.list())ne.push(uo(V,Z,he));return ne.push(N),Se(ne)}).then(()=>{ne=qg(xe,"beforeRouteUpdate",Z,he);for(const V of xe)V.updateGuards.forEach(Y=>{ne.push(uo(Y,Z,he))});return ne.push(N),Se(ne)}).then(()=>{ne=[];for(const V of Fe)if(V.beforeEnter)if(Os(V.beforeEnter))for(const Y of V.beforeEnter)ne.push(uo(Y,Z,he));else ne.push(uo(V.beforeEnter,Z,he));return ne.push(N),Se(ne)}).then(()=>(Z.matched.forEach(V=>V.enterCallbacks={}),ne=qg(Fe,"beforeRouteEnter",Z,he,E),ne.push(N),Se(ne))).then(()=>{ne=[];for(const V of o.list())ne.push(uo(V,Z,he));return ne.push(N),Se(ne)}).catch(V=>wi(V,8)?V:Promise.reject(V))}function O(Z,he,ne){a.list().forEach(z=>E(()=>z(Z,he,ne)))}function R(Z,he,ne,z,xe){const Fe=k(Z,he);if(Fe)return Fe;const N=he===Zi,V=kl?history.state:{};ne&&(z||N?s.replace(Z.fullPath,Ct({scroll:N&&V&&V.scroll},xe)):s.push(Z.fullPath,xe)),l.value=Z,ee(Z,he,ne,N),B()}let M;function D(){M||(M=s.listen((Z,he,ne)=>{if(!ie.listening)return;const z=w(Z),xe=T(z);if(xe){P(Ct(xe,{replace:!0,force:!0}),z).catch(Mc);return}u=z;const Fe=l.value;kl&&NK($k(Fe.fullPath,ne.delta),Im()),I(z,Fe).catch(N=>wi(N,12)?N:wi(N,2)?(P(Ct(b(N.to),{force:!0}),z).then(V=>{wi(V,20)&&!ne.delta&&ne.type===cd.pop&&s.go(-1,!1)}).catch(Mc),Promise.reject()):(ne.delta&&s.go(-ne.delta,!1),X(N,z,Fe))).then(N=>{N=N||R(z,Fe,!1),N&&(ne.delta&&!wi(N,8)?s.go(-ne.delta,!1):ne.type===cd.pop&&wi(N,20)&&s.go(-1,!1)),O(z,Fe,N)}).catch(Mc)}))}let F=nc(),U=nc(),K;function X(Z,he,ne){B(Z);const z=U.list();return z.length?z.forEach(xe=>xe(Z,he,ne)):console.error(Z),Promise.reject(Z)}function H(){return K&&l.value!==Zi?Promise.resolve():new Promise((Z,he)=>{F.add([Z,he])})}function B(Z){return K||(K=!Z,D(),F.list().forEach(([he,ne])=>Z?ne(Z):he()),F.reset()),Z}function ee(Z,he,ne,z){const{scrollBehavior:xe}=e;if(!kl||!xe)return Promise.resolve();const Fe=!ne&&BK($k(Z.fullPath,0))||(z||!ne)&&history.state&&history.state.scroll||null;return Mt().then(()=>xe(Z,he,Fe)).then(N=>N&&FK(N)).catch(N=>X(N,Z,he))}const q=Z=>s.go(Z);let G;const le=new Set,ie={currentRoute:l,listening:!0,addRoute:p,removeRoute:g,clearRoutes:t.clearRoutes,hasRoute:y,getRoutes:m,resolve:w,options:e,push:C,replace:_,go:q,back:()=>q(-1),forward:()=>q(1),beforeEach:i.add,beforeResolve:o.add,afterEach:a.add,onError:U.add,isReady:H,install(Z){const he=this;Z.component("RouterLink",uY),Z.component("RouterView",hY),Z.config.globalProperties.$router=he,Object.defineProperty(Z.config.globalProperties,"$route",{enumerable:!0,get:()=>Q(l)}),kl&&!G&&l.value===Zi&&(G=!0,C(s.location).catch(xe=>{}));const ne={};for(const xe in Zi)Object.defineProperty(ne,xe,{get:()=>l.value[xe],enumerable:!0});Z.provide(Am,he),Z.provide(aw,Mp(ne)),Z.provide(ab,l);const z=Z.unmount;le.add(Z),Z.unmount=function(){le.delete(Z),le.size<1&&(u=Zi,M&&M(),M=null,l.value=Zi,G=!1,K=!1),z()}}};function Se(Z){return Z.reduce((he,ne)=>he.then(()=>E(ne)),Promise.resolve())}return ie}function mY(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=>vu(u,a))?r.push(a):n.push(a));const l=e.matched[o];l&&(t.matched.find(u=>vu(u,l))||s.push(l))}return[n,r,s]}function Go(){return Qe(Am)}function uM(e){return Qe(aw)}const gY={class:"text-center"},vY={class:"float-end"},yY=Le({__name:"PrintJobsMenu",setup(e){const t=nr(),n=j(""),r=j(!1),s=A(()=>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())||"",c=((m=a.printer.printerURL)==null?void 0:m.toLowerCase())||"",d=((y=a.printer.name)==null?void 0:y.toLowerCase())||"",f=`${u} ${c} ${d}`;return!n.value||f.includes(n.value.toLowerCase())})),i=A(()=>s.value.length||0);function o(a){return a?a==null?void 0:a.toFixed(0):""}return Ee(r,()=>{n.value=""}),(a,l)=>($(),ve("div",gY,[h(Tm,{modelValue:Q(r),"onUpdate:modelValue":l[3]||(l[3]=u=>et(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(se,ge({color:Q(i)?"green":"secondary",dark:""},u),{default:v(()=>[L("span",null," Print jobs "+re(Q(i)?`(${Q(i)})`:""),1),h(J,{end:""},{default:v(()=>l[4]||(l[4]=[x(" work ")])),_:1})]),_:2},1040,["color"])]),default:v(()=>[h(vt,{class:"d-flex flex-column","min-width":"300"},{default:v(()=>[h(Ut,{style:{"overflow-y":"hidden","flex-shrink":"0"}},{default:v(()=>[h(Ve,null,{prepend:v(()=>[h(ut,{class:"font-weight-bold",color:"primary",size:"44"},{default:v(()=>[x(re(Q(i)),1)]),_:1})]),default:v(()=>[h(ft,null,{default:v(()=>[l[7]||(l[7]=x(" Print Jobs ")),L("span",vY,[h(se,{variant:"tonal",onClick:l[0]||(l[0]=u=>r.value=!1)},{default:v(()=>[h(J,null,{default:v(()=>l[5]||(l[5]=[x("close")])),_:1}),l[6]||(l[6]=x("Close "))]),_:1})])]),_:1}),h(pu,{class:"mt-2"},{default:v(()=>[h(at,{modelValue:Q(n),"onUpdate:modelValue":l[1]||(l[1]=u=>et(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(dn),h(Ut,{style:{"overflow-y":"auto","flex-shrink":"1"}},{default:v(()=>[Q(i)?pe("",!0):($(),te(Ve,{key:0},{default:v(()=>l[8]||(l[8]=[x(" No active prints ")])),_:1})),($(!0),ve(Ae,null,Gt(Q(s),({printer:u,job:c})=>($(),te(Ve,{key:u.id,lines:"two"},{prepend:v(()=>[h(ut,{size:"70"},{default:v(()=>{var d;return[h(ni,{"model-value":(d=c==null?void 0:c.progress)==null?void 0:d.completion,width:5,color:"green",size:"50"},{default:v(()=>{var f;return[x(re(o((f=c.progress)==null?void 0:f.completion)+"%"||""),1)]}),_:2},1032,["model-value"])]}),_:2},1024)]),default:v(()=>[h(ft,null,{default:v(()=>{var d,f;return[x(re((f=(d=c.job)==null?void 0:d.file)==null?void 0:f.name),1)]}),_:2},1024),h(bt,null,{default:v(()=>[x(" Elapsed: "+re(Math.round((c==null?void 0:c.progress.printTime)??0/60))+" minutes ",1),l[9]||(l[9]=L("br",null,null,-1)),x(" Printer: "+re(u.name),1)]),_:2},1024)]),_:2},1024))),128))]),_:1}),h(Mn,null,{default:v(()=>[h(Sn),h(se,{onClick:l[2]||(l[2]=u=>r.value=!1)},{default:v(()=>l[10]||(l[10]=[x(" Close ")])),_:1})]),_:1})]),_:1})]),_:1},8,["modelValue"])]))}}),lw=gs("profile",{state:()=>({username:null,isDemoUser:null,userId:null}),actions:{async getProfile(){return await ts.getProfile().then(e=>{this.username=e.username,this.userId=e.id,this.isDemoUser=e.isDemoUser})}}}),Wt={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 bY(e,t){return e.push({name:t})}async function cM(e){if(e.currentRoute.value.path==="/login"){console.log("routeToLogin: already at login page");return}return bY(e,Wt.Login)}const Qk=!0,wY=()=>Object.freeze({apiKeyLength:43,maxPort:65535,maxPrinterNameLength:25,maxPrinterGroupNameLength:30,maxPrinterGroupLocationX:4,maxPrinterGroupLocationY:4,minPrinterFloorNameLength:3,minUsernameLength:3}),ui=Object.create(null);ui.open="0";ui.close="1";ui.ping="2";ui.pong="3";ui.message="4";ui.upgrade="5";ui.noop="6";const hh=Object.create(null);Object.keys(ui).forEach(e=>{hh[ui[e]]=e});const lb={type:"error",data:"parser error"},dM=typeof Blob=="function"||typeof Blob<"u"&&Object.prototype.toString.call(Blob)==="[object BlobConstructor]",fM=typeof ArrayBuffer=="function",hM=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e&&e.buffer instanceof ArrayBuffer,uw=({type:e,data:t},n,r)=>dM&&t instanceof Blob?n?r(t):Jk(t,r):fM&&(t instanceof ArrayBuffer||hM(t))?n?r(t):Jk(new Blob([t]),r):r(ui[e]+(t||"")),Jk=(e,t)=>{const n=new FileReader;return n.onload=function(){const r=n.result.split(",")[1];t("b"+(r||""))},n.readAsDataURL(e)};function Zk(e){return e instanceof Uint8Array?e:e instanceof ArrayBuffer?new Uint8Array(e):new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}let Wg;function SY(e,t){if(dM&&e.data instanceof Blob)return e.data.arrayBuffer().then(Zk).then(t);if(fM&&(e.data instanceof ArrayBuffer||hM(e.data)))return t(Zk(e.data));uw(e,!1,n=>{Wg||(Wg=new TextEncoder),t(Wg.encode(n))})}const ex="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",pc=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(let e=0;e<ex.length;e++)pc[ex.charCodeAt(e)]=e;const _Y=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),c=new Uint8Array(u);for(r=0;r<n;r+=4)i=pc[e.charCodeAt(r)],o=pc[e.charCodeAt(r+1)],a=pc[e.charCodeAt(r+2)],l=pc[e.charCodeAt(r+3)],c[s++]=i<<2|o>>4,c[s++]=(o&15)<<4|a>>2,c[s++]=(a&3)<<6|l&63;return u},kY=typeof ArrayBuffer=="function",cw=(e,t)=>{if(typeof e!="string")return{type:"message",data:pM(e,t)};const n=e.charAt(0);return n==="b"?{type:"message",data:xY(e.substring(1),t)}:hh[n]?e.length>1?{type:hh[n],data:e.substring(1)}:{type:hh[n]}:lb},xY=(e,t)=>{if(kY){const n=_Y(e);return pM(n,t)}else return{base64:!0,data:e}},pM=(e,t)=>{switch(t){case"blob":return e instanceof Blob?e:new Blob([e]);case"arraybuffer":default:return e instanceof ArrayBuffer?e:e.buffer}},mM="",EY=(e,t)=>{const n=e.length,r=new Array(n);let s=0;e.forEach((i,o)=>{uw(i,!1,a=>{r[o]=a,++s===n&&t(r.join(mM))})})},CY=(e,t)=>{const n=e.split(mM),r=[];for(let s=0;s<n.length;s++){const i=cw(n[s],t);if(r.push(i),i.type==="error")break}return r};function TY(){return new TransformStream({transform(e,t){SY(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 Gg;function _f(e){return e.reduce((t,n)=>t+n.length,0)}function kf(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 PY(e,t){Gg||(Gg=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(_f(n)<1)break;const l=kf(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(_f(n)<2)break;const l=kf(n,2);s=new DataView(l.buffer,l.byteOffset,l.length).getUint16(0),r=3}else if(r===2){if(_f(n)<8)break;const l=kf(n,8),u=new DataView(l.buffer,l.byteOffset,l.length),c=u.getUint32(0);if(c>Math.pow(2,21)-1){a.enqueue(lb);break}s=c*Math.pow(2,32)+u.getUint32(4),r=3}else{if(_f(n)<s)break;const l=kf(n,s);a.enqueue(cw(i?l:Gg.decode(l),t)),r=0}if(s===0||s>e){a.enqueue(lb);break}}}})}const gM=4;function wn(e){if(e)return RY(e)}function RY(e){for(var t in wn.prototype)e[t]=wn.prototype[t];return e}wn.prototype.on=wn.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this};wn.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this};wn.prototype.off=wn.prototype.removeListener=wn.prototype.removeAllListeners=wn.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};wn.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};wn.prototype.emitReserved=wn.prototype.emit;wn.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]};wn.prototype.hasListeners=function(e){return!!this.listeners(e).length};const Om=typeof Promise=="function"&&typeof Promise.resolve=="function"?t=>Promise.resolve().then(t):(t,n)=>n(t,0),rs=typeof self<"u"?self:typeof window<"u"?window:Function("return this")(),IY="arraybuffer";function vM(e,...t){return t.reduce((n,r)=>(e.hasOwnProperty(r)&&(n[r]=e[r]),n),{})}const AY=rs.setTimeout,OY=rs.clearTimeout;function Mm(e,t){t.useNativeTimers?(e.setTimeoutFn=AY.bind(rs),e.clearTimeoutFn=OY.bind(rs)):(e.setTimeoutFn=rs.setTimeout.bind(rs),e.clearTimeoutFn=rs.clearTimeout.bind(rs))}const MY=1.33;function DY(e){return typeof e=="string"?LY(e):Math.ceil((e.byteLength||e.size)*MY)}function LY(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 yM(){return Date.now().toString(36).substring(3)+Math.random().toString(36).substring(2,5)}function $Y(e){let t="";for(let n in e)e.hasOwnProperty(n)&&(t.length&&(t+="&"),t+=encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return t}function FY(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 NY extends Error{constructor(t,n,r){super(t),this.description=n,this.context=r,this.type="TransportError"}}class dw extends wn{constructor(t){super(),this.writable=!1,Mm(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 NY(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=cw(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=$Y(t);return n.length?"?"+n:""}}class BY extends dw{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)};CY(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,EY(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]=yM()),!this.supportsBinary&&!n.sid&&(n.b64=1),this.createUri(t,n)}}let bM=!1;try{bM=typeof XMLHttpRequest<"u"&&"withCredentials"in new XMLHttpRequest}catch{}const VY=bM;function UY(){}class zY extends BY{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 Bl=class ph extends wn{constructor(t,n,r){super(),this.createRequest=t,Mm(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=vM(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=ph.requestsCount++,ph.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=UY,t)try{this._xhr.abort()}catch{}typeof document<"u"&&delete ph.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()}};Bl.requestsCount=0;Bl.requests={};if(typeof document<"u"){if(typeof attachEvent=="function")attachEvent("onunload",tx);else if(typeof addEventListener=="function"){const e="onpagehide"in rs?"pagehide":"unload";addEventListener(e,tx,!1)}}function tx(){for(let e in Bl.requests)Bl.requests.hasOwnProperty(e)&&Bl.requests[e].abort()}const HY=function(){const e=wM({xdomain:!1});return e&&e.responseType!==null}();class jY extends zY{constructor(t){super(t);const n=t&&t.forceBase64;this.supportsBinary=HY&&!n}request(t={}){return Object.assign(t,{xd:this.xd},this.opts),new Bl(wM,this.uri(),t)}}function wM(e){const t=e.xdomain;try{if(typeof XMLHttpRequest<"u"&&(!t||VY))return new XMLHttpRequest}catch{}if(!t)try{return new rs[["Active"].concat("Object").join("X")]("Microsoft.XMLHTTP")}catch{}}const SM=typeof navigator<"u"&&typeof navigator.product=="string"&&navigator.product.toLowerCase()==="reactnative";class qY extends dw{get name(){return"websocket"}doOpen(){const t=this.uri(),n=this.opts.protocols,r=SM?{}:vM(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;uw(r,this.supportsBinary,i=>{try{this.doWrite(r,i)}catch{}s&&Om(()=>{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]=yM()),this.supportsBinary||(n.b64=1),this.createUri(t,n)}}const Kg=rs.WebSocket||rs.MozWebSocket;class WY extends qY{createSocket(t,n,r){return SM?new Kg(t,n,r):n?new Kg(t,n):new Kg(t)}doWrite(t,n){this.ws.send(n)}}class GY extends dw{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=PY(Number.MAX_SAFE_INTEGER,this.socket.binaryType),r=t.readable.pipeThrough(n).getReader(),s=TY();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&&Om(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){var t;(t=this._transport)===null||t===void 0||t.close()}}const KY={websocket:WY,webtransport:GY,polling:jY},YY=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,XY=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function ub(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=YY.exec(e||""),i={},o=14;for(;o--;)i[XY[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=QY(i,i.path),i.queryKey=JY(i,i.query),i}function QY(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 JY(e,t){const n={};return t.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(r,s,i){s&&(n[s]=i)}),n}const cb=typeof addEventListener=="function"&&typeof removeEventListener=="function",mh=[];cb&&addEventListener("offline",()=>{mh.forEach(e=>e())},!1);class Po extends wn{constructor(t,n){if(super(),this.binaryType=IY,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=ub(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=ub(n.host).host);Mm(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=FY(this.opts.query)),cb&&(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"})},mh.push(this._offlineEventListener))),this.opts.withCredentials&&(this._cookieJar=void 0),this._open()}createTransport(t){const n=Object.assign({},this.opts.query);n.EIO=gM,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&&Po.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",Po.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+=DY(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,Om(()=>{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(Po.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(),cb&&(this._beforeunloadEventListener&&removeEventListener("beforeunload",this._beforeunloadEventListener,!1),this._offlineEventListener)){const r=mh.indexOf(this._offlineEventListener);r!==-1&&mh.splice(r,1)}this.readyState="closed",this.id=null,this.emitReserved("close",t,n),this.writeBuffer=[],this._prevBufferLen=0}}}Po.protocol=gM;class ZY extends Po{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;Po.priorWebsocketSuccess=!1;const s=()=>{r||(n.send([{type:"ping",data:"probe"}]),n.once("packet",d=>{if(!r)if(d.type==="pong"&&d.data==="probe"){if(this.upgrading=!0,this.emitReserved("upgrading",n),!n)return;Po.priorWebsocketSuccess=n.name==="websocket",this.transport.pause(()=>{r||this.readyState!=="closed"&&(c(),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,c(),n.close(),n=null)}const o=d=>{const f=new Error("probe error: "+d);f.transport=n.name,i(),this.emitReserved("upgradeError",f)};function a(){o("transport closed")}function l(){o("socket closed")}function u(d){n&&d.name!==n.name&&i()}const c=()=>{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 eX=class extends ZY{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=>KY[s]).filter(s=>!!s)),super(t,r)}};function tX(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=ub(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 nX=typeof ArrayBuffer=="function",rX=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e.buffer instanceof ArrayBuffer,_M=Object.prototype.toString,sX=typeof Blob=="function"||typeof Blob<"u"&&_M.call(Blob)==="[object BlobConstructor]",iX=typeof File=="function"||typeof File<"u"&&_M.call(File)==="[object FileConstructor]";function fw(e){return nX&&(e instanceof ArrayBuffer||rX(e))||sX&&e instanceof Blob||iX&&e instanceof File}function gh(e,t){if(!e||typeof e!="object")return!1;if(Array.isArray(e)){for(let n=0,r=e.length;n<r;n++)if(gh(e[n]))return!0;return!1}if(fw(e))return!0;if(e.toJSON&&typeof e.toJSON=="function"&&arguments.length===1)return gh(e.toJSON(),!0);for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&gh(e[n]))return!0;return!1}function oX(e){const t=[],n=e.data,r=e;return r.data=db(n,t),r.attachments=t.length,{packet:r,buffers:t}}function db(e,t){if(!e)return e;if(fw(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]=db(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]=db(e[r],t));return n}return e}function aX(e,t){return e.data=fb(e.data,t),delete e.attachments,e}function fb(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]=fb(e[n],t);else if(typeof e=="object")for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(e[n]=fb(e[n],t));return e}const lX=["connect","connect_error","disconnect","disconnecting","newListener","removeListener"],uX=5;var pt;(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"})(pt||(pt={}));class cX{constructor(t){this.replacer=t}encode(t){return(t.type===pt.EVENT||t.type===pt.ACK)&&gh(t)?this.encodeAsBinary({type:t.type===pt.EVENT?pt.BINARY_EVENT:pt.BINARY_ACK,nsp:t.nsp,data:t.data,id:t.id}):[this.encodeAsString(t)]}encodeAsString(t){let n=""+t.type;return(t.type===pt.BINARY_EVENT||t.type===pt.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=oX(t),r=this.encodeAsString(n.packet),s=n.buffers;return s.unshift(r),s}}function nx(e){return Object.prototype.toString.call(e)==="[object Object]"}class hw extends wn{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===pt.BINARY_EVENT;r||n.type===pt.BINARY_ACK?(n.type=r?pt.EVENT:pt.ACK,this.reconstructor=new dX(n),n.attachments===0&&super.emitReserved("decoded",n)):super.emitReserved("decoded",n)}else if(fw(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(pt[r.type]===void 0)throw new Error("unknown packet type "+r.type);if(r.type===pt.BINARY_EVENT||r.type===pt.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(hw.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 pt.CONNECT:return nx(n);case pt.DISCONNECT:return n===void 0;case pt.CONNECT_ERROR:return typeof n=="string"||nx(n);case pt.EVENT:case pt.BINARY_EVENT:return Array.isArray(n)&&(typeof n[0]=="number"||typeof n[0]=="string"&&lX.indexOf(n[0])===-1);case pt.ACK:case pt.BINARY_ACK:return Array.isArray(n)}}destroy(){this.reconstructor&&(this.reconstructor.finishedReconstruction(),this.reconstructor=null)}}class dX{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=aX(this.reconPack,this.buffers);return this.finishedReconstruction(),n}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}}const fX=Object.freeze(Object.defineProperty({__proto__:null,Decoder:hw,Encoder:cX,get PacketType(){return pt},protocol:uX},Symbol.toStringTag,{value:"Module"}));function Es(e,t,n){return e.on(t,n),function(){e.off(t,n)}}const hX=Object.freeze({connect:1,connect_error:1,disconnect:1,disconnecting:1,newListener:1,removeListener:1});class kM extends wn{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=[Es(t,"open",this.onopen.bind(this)),Es(t,"packet",this.onpacket.bind(this)),Es(t,"error",this.onerror.bind(this)),Es(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(hX.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:pt.EVENT,data:n};if(o.options={},o.options.compress=this.flags.compress!==!1,typeof n[n.length-1]=="function"){const c=this.ids++,d=n.pop();this._registerAckCallback(c,d),o.id=c}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:pt.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 pt.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 pt.EVENT:case pt.BINARY_EVENT:this.onevent(t);break;case pt.ACK:case pt.BINARY_ACK:this.onack(t);break;case pt.DISCONNECT:this.ondisconnect();break;case pt.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:pt.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:pt.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 Hu(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}Hu.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};Hu.prototype.reset=function(){this.attempts=0};Hu.prototype.setMin=function(e){this.ms=e};Hu.prototype.setMax=function(e){this.max=e};Hu.prototype.setJitter=function(e){this.jitter=e};class hb extends wn{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,Mm(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 Hu({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||fX;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 eX(this.uri,this.opts);const n=this.engine,r=this;this._readyState="opening",this.skipReconnect=!1;const s=Es(n,"open",function(){r.onopen(),t&&t()}),i=a=>{this.cleanup(),this._readyState="closed",this.emitReserved("error",a),t?t(a):this.maybeReconnectOnOpen()},o=Es(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(Es(t,"ping",this.onping.bind(this)),Es(t,"data",this.ondata.bind(this)),Es(t,"error",this.onerror.bind(this)),Es(t,"close",this.onclose.bind(this)),Es(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){Om(()=>{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 kM(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 rc={};function vh(e,t){typeof e=="object"&&(t=e,e=void 0),t=t||{};const n=tX(e,t.path||"/socket.io"),r=n.source,s=n.id,i=n.path,o=rc[s]&&i in rc[s].nsps,a=t.forceNew||t["force new connection"]||t.multiplex===!1||o;let l;return a?l=new hb(r,t):(rc[s]||(rc[s]=new hb(r,t)),l=rc[s]),n.query&&!t.query&&(t.query=n.queryKey),l.socket(n.path,t)}Object.assign(vh,{Manager:hb,Socket:kM,io:vh,connect:vh});let Jt=null;const _r=cn({connected:!1,setup:!1,id:""});function pX(e,t){if(_r.setup)throw new Error("Socket already set up");_r.setup=!1,Jt=vh(e,{auth:t!=null&&t.length?{token:t}:void 0}),_r.setup=!0,Jt.on("connect",()=>{_r.id=Jt.id||"",_r.connected=!0}),Jt.on("disconnect",()=>{_r.id="",_r.connected=!1})}function mX(){_r.connected=!1,Jt==null||Jt.close(),Jt==null||Jt.open()}function gX(){Jt&&Jt.close(),Jt=null,_r.setup=!1,_r.connected=!1,_r.id=""}function vX(){if(!Jt)return console.warn("Socket not set-up"),{setup:!1};const e={setup:!0,active:Jt.active,connected:Jt.connected,id:Jt.id,recovered:Jt.recovered};return console.warn(e),e}const yX=de({scrollTarget:{type:String},scrollThreshold:{type:[String,Number],default:300}},"scroll");function bX(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const{canScroll:n}=t;let r=0,s=0;const i=j(null),o=Ie(0),a=Ie(0),l=Ie(0),u=Ie(!1),c=Ie(!1),d=A(()=>Number(e.scrollThreshold)),f=A(()=>Cr((d.value-o.value)/d.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}c.value=o.value<r,l.value=Math.abs(o.value-d.value)};return Ee(c,()=>{a.value=a.value||o.value}),Ee(u,()=>{a.value=0}),St(()=>{Ee(()=>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})}),Cn(()=>{var g;(g=i.value)==null||g.removeEventListener("scroll",p)}),n&&Ee(n,p,{immediate:!0}),{scrollThreshold:d,currentScroll:o,currentThreshold:l,isScrollActive:u,scrollRatio:f,isScrollingUp:c,savedScroll:a}}const wX=de({scrollBehavior:String,modelValue:{type:Boolean,default:!0},location:{type:String,default:"top",validator:e=>["top","bottom"].includes(e)},...XO(),...dO(),...yX(),height:{type:[Number,String],default:64}},"VAppBar"),xM=ke()({name:"VAppBar",props:wX(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const r=j(),s=st(e,"modelValue"),i=A(()=>{var k;const b=new Set(((k=e.scrollBehavior)==null?void 0:k.split(" "))??[]);return{hide:b.has("hide"),fullyHide:b.has("fully-hide"),inverted:b.has("inverted"),collapse:b.has("collapse"),elevate:b.has("elevate"),fadeImage:b.has("fade-image")}}),o=A(()=>{const b=i.value;return b.hide||b.fullyHide||b.inverted||b.collapse||b.elevate||b.fadeImage||!s.value}),{currentScroll:a,scrollThreshold:l,isScrollingUp:u,scrollRatio:c}=bX(e,{canScroll:o}),d=ae(()=>i.value.hide||i.value.fullyHide),f=A(()=>e.collapse||i.value.collapse&&(i.value.inverted?c.value>0:c.value===0)),p=A(()=>e.flat||i.value.fullyHide&&!s.value||i.value.elevate&&(i.value.inverted?a.value>0:a.value===0)),g=A(()=>i.value.fadeImage?i.value.inverted?1-c.value:c.value:void 0),m=A(()=>{var C,_;if(i.value.hide&&i.value.inverted)return 0;const b=((C=r.value)==null?void 0:C.contentHeight)??0,k=((_=r.value)==null?void 0:_.extensionHeight)??0;return d.value?a.value<l.value||i.value.fullyHide?b+k:b:b+k});Hr(()=>!!e.scrollBehavior,()=>{On(()=>{d.value?i.value.inverted?s.value=a.value>l.value:s.value=u.value||a.value<l.value:s.value=!0})});const{ssrBootStyles:y}=jd(),{layoutItemStyles:w}=hO({id:e.name,order:A(()=>parseInt(e.order,10)),position:ae(()=>e.location),layoutSize:m,elementSize:Ie(void 0),active:s,absolute:ae(()=>e.absolute)});return Oe(()=>{const b=mr.filterProps(e);return h(mr,ge({ref:r,class:["v-app-bar",{"v-app-bar--bottom":e.location==="bottom"},e.class],style:[{...w.value,"--v-toolbar-image-opacity":g.value,height:void 0,...y.value},e.style]},b,{collapse:f.value,flat:p.value}),n)}),{}}}),SX=de({...mP({icon:"$menu",variant:"text"})},"VAppBarNavIcon"),_X=ke()({name:"VAppBarNavIcon",props:SX(),setup(e,t){let{slots:n}=t;return Oe(()=>h(se,ge(e,{class:["v-app-bar-nav-icon"]}),n)),{}}}),kX={key:1,class:"text-uppercase text--white"},xX={key:3,class:"ml-2"},EX={key:4,class:"ml-2"},CX=Le({__name:"TopBar",setup(e){const t=lw(),n=us(),r=Go(),s=[{title:"Open Profile",icon:"person",path:"/settings/account"}],i=j(Date.now());I$(()=>{i.value=Date.now()},1e3);const o=A(()=>{var d;if(!((d=n.tokenClaims)!=null&&d.exp))return"";const c=n.tokenClaims.exp-i.value/1e3;return`${Math.round(c)}s`}),a=A(()=>t.username),l=A(()=>n.isDemoMode);async function u(){await n.logout(!0),await cM(r)}return(c,d)=>{const f=fK,p=dK;return $(),te(xM,{elevation:"0"},{default:v(()=>[h(En,{class:"text-uppercase text-white"},{default:v(()=>d[1]||(d[1]=[L("span",{class:"font-weight-light"}," FDM ",-1),L("strong",null," Monster ",-1)])),_:1}),l.value?($(),te(Sn,{key:0})):pe("",!0),l.value?($(),ve("h2",kX," DEMO MODE ")):pe("",!0),h(Sn),h(yY),Q(n).hasAuthToken&&!Q(n).isLoginExpired?($(),te(Tm,{key:2,"close-on-content-click":!1,location:"bottom right","open-on-hover":"",transition:"slide-y-transition"},{activator:v(({props:g})=>[h(se,ge({class:"ml-2",color:"secondary",theme:"dark"},g),{default:v(()=>[h(J,{class:"mr-2"},{default:v(()=>d[2]||(d[2]=[x("person")])),_:1}),x(" "+re(a.value),1)]),_:2},1040)]),default:v(()=>[h(Ut,null,{default:v(()=>[($(),ve(Ae,null,Gt(s,(g,m)=>h(Ve,{key:m,to:g.path,title:g.title,"prepend-avatar":g.icon,link:""},null,8,["to","title","prepend-avatar"])),64))]),_:1})]),_:1})):pe("",!0),Q(Qk)&&o.value?($(),ve("span",xX," AuthExp "+re(o.value),1)):pe("",!0),Q(Qk)?($(),ve("span",EX,[L("small",null," S"+re(Q(_r).setup?1:0)+" C"+re(Q(_r).connected?1:0)+" "+re(Q(_r).id),1)])):pe("",!0),Q(n).loginRequired===!0?($(),te(f,{key:5,tooltip:"Go back to login",text:"Logout",color:"secondary",icon:"logout",onClick:d[0]||(d[0]=g=>u())})):pe("",!0),Q(n).loginRequired===!0?($(),te(se,{key:6,class:"ml-2"},{default:v(()=>[h(J,{class:"mr-2"},{default:v(()=>d[3]||(d[3]=[x("logout")])),_:1}),d[4]||(d[4]=x(" Logout "))]),_:1})):pe("",!0),h(p)]),_:1})}}}),pw="/assets/logo-CJVdjy51.png",TX=Le({__name:"NavigationBar",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)=>($(),te(K0,{permanent:"",rail:""},{default:v(()=>[h(_X,{class:"ml-1 mt-2"},{default:v(()=>[h(ds,{alt:"FDM Monster Logo",src:Q(pw),class:"shrink mr-1 pt-3 ml-1",transition:"scale-transition",width:"40"},null,8,["src"])]),_:1}),h(dn),h(Ut,{density:"compact",nav:""},{default:v(()=>[($(),ve(Ae,null,Gt(t,([s,i,o],a)=>h(Ve,{key:a,to:o,"prepend-icon":s,title:i,density:"comfortable","router-link":""},null,8,["to","prepend-icon","title"])),64))]),_:1})]),_:1}))}});function PX(e){const t=Ie(e());let n=-1;function r(){clearInterval(n)}function s(){r(),Mt(()=>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 c=performance.now()-u+l;t.value=Math.max(e()-c,0),t.value<=0&&r()},l)}return yn(r),{clear:r,time:t,start:i,reset:s}}const RX=de({multiLine:Boolean,text:String,timer:[Boolean,String],timeout:{type:[Number,String],default:5e3},vertical:Boolean,...jo({location:"bottom"}),...Cu(),...Dn(),...$s(),...Lt(),...Ms(Id({transition:"v-snackbar-transition"}),["persistent","noClickAnimation","scrim","scrollStrategy"])},"VSnackbar"),mw=ke()({name:"VSnackbar",props:RX(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const r=st(e,"modelValue"),{positionClasses:s}=Tu(e),{scopeId:i}=Ru(),{themeClasses:o}=Zt(e),{colorClasses:a,colorStyles:l,variantClasses:u}=Za(e),{roundedClasses:c}=zn(e),d=PX(()=>Number(e.timeout)),f=j(),p=j(),g=Ie(!1),m=Ie(0),y=j(),w=Qe(ad,void 0);Hr(()=>!!w,()=>{const O=fO();On(()=>{y.value=O.mainStyles.value})}),Ee(r,k),Ee(()=>e.timeout,k),St(()=>{r.value&&k()});let b=-1;function k(){d.reset(),window.clearTimeout(b);const O=Number(e.timeout);if(!r.value||O===-1)return;const R=Gb(p.value);d.start(R),b=window.setTimeout(()=>{r.value=!1},O)}function C(){d.reset(),window.clearTimeout(b)}function _(){g.value=!0,C()}function T(){g.value=!1,k()}function P(O){m.value=O.touches[0].clientY}function S(O){Math.abs(m.value-O.changedTouches[0].clientY)>50&&(r.value=!1)}function E(){g.value&&T()}const I=A(()=>e.location.split(" ").reduce((O,R)=>(O[`v-snackbar--${R}`]=!0,O),{}));return Oe(()=>{const O=Bi.filterProps(e),R=!!(n.default||n.text||e.text);return h(Bi,ge({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]},O,{modelValue:r.value,"onUpdate:modelValue":M=>r.value=M,contentProps:ge({class:["v-snackbar__wrapper",o.value,a.value,c.value,u.value],style:[l.value],onPointerenter:_,onPointerleave:T},O.contentProps),persistent:!0,noClickAnimation:!0,scrim:!1,scrollStrategy:"none",_disableGlobalStack:!0,onTouchstartPassive:P,onTouchend:S,onAfterLeave:E},i),{default:()=>{var M,D;return[Ho(!1,"v-snackbar"),e.timer&&!g.value&&h("div",{key:"timer",class:"v-snackbar__timer"},[h(su,{ref:p,color:typeof e.timer=="string"?e.timer:"info",max:e.timeout,"model-value":d.time.value},null)]),R&&h("div",{key:"content",class:"v-snackbar__content",role:"status","aria-live":"polite"},[((M=n.text)==null?void 0:M.call(n))??e.text,(D=n.default)==null?void 0:D.call(n)]),n.actions&&h(Ot,{defaults:{VBtn:{variant:"text",ripple:!1,slim:!0}}},{default:()=>[h("div",{class:"v-snackbar__actions"},[n.actions({isActive:r})])]})]},activator:n.activator})}),Xi({},f)}}),IX={style:{width:"100%"}},AX={class:"font-weight-bold text-button"},OX=Le({__name:"AppProgressSnackbar",setup(e){const t=Dt(),n=j(!1),r=j(""),s=j([]),i=j(100);function o(u){return s.value.find(c=>c.key===u)}function a(u,c,d=0,f=!1,p=Date.now()+1500){console.log(`[AppProgressSnackbar] Adding ${u} tracker with progress ${d}`),s.value.push({key:u,title:c,value:d,completed:f,startedAt:Date.now(),expiresAt:p,timeoutAt:void 0})}function l(u){s.value=s.value.filter(c=>c.key!==u)}return St(()=>{setInterval(()=>{if(s.value.length){for(const u of s.value){const{value:c,completed:d,expiresAt:f,key:p}=u;(d||c>=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:c,value:d,title:f,completed:p}=u,g=o(c);if(g)Math.min(100,d)>=g.value&&(g.expiresAt=Date.now()+1500,g.value=d,g.completed=p);else{if(d>=100)return;a(c,f,d,!1,Date.now()+1500)}r.value="Uploading files"})}),(u,c)=>($(),te(mw,{modelValue:n.value,"onUpdate:modelValue":c[1]||(c[1]=d=>n.value=d),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(rt,null,{default:v(()=>[h(ze,{cols:"2"},{default:v(()=>[h(se,{icon:"file_upload",size:"large"})]),_:1}),h(ze,{class:"d-flex align-center flex-row",cols:"8"},{default:v(()=>[L("div",IX,[L("span",AX,re(r.value),1),($(!0),ve(Ae,null,Gt(s.value,(d,f)=>($(),ve("div",{key:f,class:"mb-2"},[d.completed?($(),te(J,{key:0},{default:v(()=>c[2]||(c[2]=[x("check")])),_:1})):d.timeoutAt?($(),te(J,{key:1},{default:v(()=>c[3]||(c[3]=[x("pause")])),_:1})):($(),te(J,{key:2},{default:v(()=>c[4]||(c[4]=[x("hourglass_bottom")])),_:1})),x(" "+re(d.title)+" "+re((d.completed?100:d.value).toFixed(1))+"% ",1),c[5]||(c[5]=L("br",null,null,-1)),($(),te(su,{key:d.key,"model-value":d.completed?100:d.value,color:d.timeoutAt?"red":"success"},null,8,["model-value","color"]))]))),128))])]),_:1}),h(ze,{cols:"1"},{default:v(()=>[h(se,{icon:"close",size:"large",onClick:c[0]||(c[0]=d=>n.value=!1)})]),_:1})]),_:1})]),_:1},8,["modelValue","timeout"]))}}),MX={class:"font-weight-bold text-button"},DX={key:0},LX=Le({__name:"AppErrorSnackbar",setup(e){const t=Dt(),n=j(-1),r=j(!1),s=j(""),i=j("");return St(()=>{t.onErrorMessage(o=>{s.value=o.title,i.value=o.subtitle??"",r.value=!0,n.value=o.timeout??1e4})}),(o,a)=>($(),te(mw,{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(rt,null,{default:v(()=>[h(ze,{cols:"2"},{default:v(()=>[h(se,{icon:"error"})]),_:1}),h(ze,{class:"d-flex align-center flex-row",cols:"8"},{default:v(()=>{var l;return[L("div",null,[L("span",MX,re(s.value),1),(l=i.value)!=null&&l.length?($(),ve("div",DX,re(i.value),1)):pe("",!0)])]}),_:1}),h(ze,{cols:"1"},{default:v(()=>[h(se,{icon:"close",onClick:a[0]||(a[0]=l=>r.value=!1)})]),_:1})]),_:1})]),_:1},8,["modelValue","timeout"]))}}),$X={class:"font-weight-bold text-button"},FX={key:0},NX=Le({__name:"AppInfoSnackbar",setup(e){const t=Dt(),n=j(!1),r=j(""),s=j(""),i=j(2e3),o=j(!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)=>($(),te(mw,{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(rt,null,{default:v(()=>[h(ze,{cols:"2"},{default:v(()=>[h(se,{icon:"info"})]),_:1}),h(ze,{cols:"8",class:"d-flex align-center flex-row"},{default:v(()=>{var u;return[L("div",null,[L("span",$X,re(r.value),1),(u=s.value)!=null&&u.length?($(),ve("div",FX,re(s.value),1)):pe("",!0)])]}),_:1}),h(ze,{cols:"2"},{default:v(()=>[h(se,{icon:"close",onClick:l[0]||(l[0]=u=>n.value=!1)})]),_:1})]),_:1})]),_:1},8,["modelValue","color","timeout"]))}}),gw=gs("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=Dt();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 $i.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}}}),BX="/img/OIG.JYDC2RaWdz7g9.jpg",Ko=(e,t)=>{const n=e.__vccOpts||e;for(const[r,s]of t)n[r]=s;return n},VX=e=>Math.random()*e,UX={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:VX,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 zX(e,t,n,r,s,i){return n.loading?($(),ve("div",{key:0,style:is(i.getWrapperStyle())},[($(),ve(Ae,null,Gt(9,o=>L("div",{key:o,style:is(i.getCircleStyle(i.random(100)))},null,4)),64))],4)):pe("",!0)}const EM=Ko(UX,[["render",zX]]);function CM(e){const t=ct();t.getOptions().enabled=e,console.warn("Sentry enabled:",e)}const HX=e=>new Promise(t=>setTimeout(t,e)),jX=gs("tracked-uploads",()=>{const e=j([]),t=A(()=>e.value.filter(r=>!r.completed));function n(r){e.value.splice(0),e.value.push(...r)}return{current:e,setUploads:n,activeUploads:t}});class qX{constructor(){we(this,"printerStore",Ft());we(this,"floorStore",Qi());we(this,"printerStateStore",nr());we(this,"testPrinterStore",iw());we(this,"trackedUploadsStore",jX());we(this,"snackbar",Dt())}socketState(){return vX()}async setupSocketConnection(){console.debug("Setting up socket.io client");const t=await EA(),n=us();n.loadTokens(),pX(t,n.loginRequired?n.token:void 0),Jt==null||Jt.on("legacy-update",r=>this.onMessage(JSON.parse(r))),Jt==null||Jt.on("test-printer-state",r=>{this.testPrinterStore.saveEvent(r),console.log(r)})}disconnect(){gX()}reconnect(){Jt&&(console.debug("Resetting socket.io client connection"),mX())}onMessage(t){var n,r,s;(n=t.trackedUploads.current)!=null&&n.length&&(this.trackedUploadsStore.setUploads(t==null?void 0:t.trackedUploads.current),this.trackedUploadsStore.activeUploads.forEach(o=>{this.snackbar.openProgressMessage(o.correlationToken,o.multerFile.originalname,(o.progress||0)*100,o.completed)})),(r=t.floors)!=null&&r.length&&this.floorStore.saveFloors(t.floors),(s=t.printers)!=null&&s.length&&this.printerStore.setPrinters(t.printers),t.socketStates&&this.printerStateStore.setSocketStates(t.socketStates),t.printerEvents&&this.printerStateStore.setPrinterEvents(t.printerEvents)}}const WX={key:1,style:{margin:"50px"}},GX={class:"mt-2 mb-2"},KX={key:0,class:"mt-2 mb-2"},YX={key:1,class:"mt-2 mb-2"},XX={key:2,style:{animation:"fadeIn 0.75s"}},QX=Le({__name:"AppLoader",setup(e){const t=us(),n=Ns(),r=Em(),s=lw(),i=j(!1),o=Go(),a=j(""),l=j(!0),u=j(),c=j(),d=j(),f=Dt(),p=new qX;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(P,S=""){P?(a.value=S,u.value=null,c.value=null,d.value=null):a.value="",i.value=P}async function w(){var P;try{await n.loadSettings(),await r.loadFeatures(),await s.getProfile();const S=(P=n.serverSettings)==null?void 0:P.sentryDiagnosticsEnabled;CM(!!S)}catch(S){console.log("Error when loading settings.",S),f.openErrorMessage({title:"Error",subtitle:"Error when loading settings, features and/or profile."}),ai(S)}p.socketState().setup?p.reconnect():await p.setupSocketConnection(),y(!1)}return Br("auth:permission-denied").on(async P=>{console.log("[AppLoader] Permission denied, going to permission denied page"),y(!0,"Permission denied"),await o.push({name:Wt.PermissionDenied,query:{roles:P==null?void 0:P.roles,page:String(o.currentRoute.value.name),permissions:P==null?void 0:P.permissions,error:P==null?void 0:P.error,url:P==null?void 0:P.url}}),y(!1)}),Br("auth:failure").on(async P=>{console.debug(`[AppLoader] Event received: 'auth:failure', going back to login, context: ${P}`),y(!0,"Authentication failed, going back to login"),o.currentRoute.value.name!==Wt.Login&&await o.push({name:Wt.Login}),y(!1)}),Br("auth:login").on(async()=>{console.debug("[AppLoader] Event received: 'auth:login', loading app"),y(!0,"Loading app"),await w()}),Br(`auth:${kr.AccountNotVerified}`).on(async()=>{console.debug(`[AppLoader] Event received: 'auth:${kr.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!==Wt.Login&&await o.push({name:Wt.Login}),y(!1)}),Br(`auth:${kr.PasswordChangeRequired}`).on(async()=>{console.debug(`[AppLoader] Event received: 'auth:${kr.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!==Wt.Login&&await o.push({name:Wt.Login}),y(!1)}),Bp(()=>{p&&p.disconnect()}),Su(async()=>{var O,R;l.value=!0;const P=["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"],S=P[Math.floor(Math.random()*P.length)];y(!0,S);try{await ma.test()}catch(M){l.value=!1,u.value=M,c.value="api/test",ai(M);return}const{loginRequired:E,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!==Wt.FirstTimeSetup&&await o.replace({name:Wt.FirstTimeSetup}),y(!1);return}if(!E)return console.debug("[AppLoader] Login not required, loading app"),await w();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:M,handled:D}=await t.verifyOrRefreshLoginOnceOrLogout();if(D){console.debug("[AppLoader] received handled event, hiding overlay");return}if(!M){console.debug("[AppLoader] No success refreshing"),y(!0,"Login expired, going back to login"),await HX(500),o.currentRoute.value.name!==Wt.Login&&await o.push({name:Wt.Login}),y(!1);return}}catch(M){console.log("[AppLoader] Error when refreshing login",M),l.value=!1,u.value=M.message,c.value=(O=M.config)==null?void 0:O.url,d.value=(R=M.response)==null?void 0:R.data,ai(M);return}console.debug("[AppLoader] Loading app"),await w()}),(P,S)=>($(),ve(Ae,null,[h(Bi,{modelValue:i.value,"onUpdate:modelValue":S[2]||(S[2]=E=>i.value=E),opacity:"0.98",style:{"z-index":"7"}},{default:v(()=>[l.value?($(),te(EM,{key:0,size:20,class:"ma-auto",color:"#a70015"})):pe("",!0),S[19]||(S[19]=L("br",null,null,-1)),u.value?($(),ve("div",WX,[S[16]||(S[16]=L("h1",null,"FDM Monster Server Error",-1)),S[17]||(S[17]=L("p",null," Did not expect this answer from the server. Please check your configuration and logs. ",-1)),h(dp,{class:"pa-4 rounded",color:"grey-darken-2",width:"80%"},{default:v(()=>[S[11]||(S[11]=x(" Details: ")),L("div",GX,re(JSON.stringify(u.value,null,4)),1),c.value?($(),ve("div",KX," Original URL: "+re(c.value),1)):pe("",!0),d.value?($(),ve("div",YX," Response body: "+re(d.value),1)):pe("",!0),S[12]||(S[12]=L("br",null,null,-1)),h(se,{class:"mb-2",color:"secondary",onClick:S[0]||(S[0]=E=>m())},{default:v(()=>[h(J,{class:"mr-2"},{default:v(()=>S[3]||(S[3]=[x("content_copy")])),_:1}),S[4]||(S[4]=x(" Copy error details "))]),_:1}),S[13]||(S[13]=L("br",null,null,-1)),h(se,{color:"primary mb-2",onClick:S[1]||(S[1]=E=>g())},{default:v(()=>[h(J,{class:"mr-2"},{default:v(()=>S[5]||(S[5]=[x("refresh")])),_:1}),S[6]||(S[6]=x(" reload the page "))]),_:1}),S[14]||(S[14]=L("br",null,null,-1)),h(se,{color:"darken-2 mb-2",href:"https://docs.fdm-monster.net",style:{color:"white"},target:"_blank"},{default:v(()=>[h(J,{class:"mr-2"},{default:v(()=>S[7]||(S[7]=[x("menu_book")])),_:1}),S[8]||(S[8]=x(" view documentation "))]),_:1}),S[15]||(S[15]=L("br",null,null,-1)),h(se,{color:"purple-darken-4",href:"https://discord.gg/mwA8uP8CMc",style:{color:"white"},target:"_blank"},{default:v(()=>[h(J,{class:"mr-2"},{default:v(()=>S[9]||(S[9]=[x("chat")])),_:1}),S[10]||(S[10]=x(" join our Discord "))]),_:1})]),_:1}),S[18]||(S[18]=L("img",{class:"justify-center align-center align-content-center rounded-pill mt-8 ma-4",src:BX,style:{opacity:"0.9"},width:"400"},null,-1))])):pe("",!0),l.value?($(),ve("div",XX,re(a.value),1)):pe("",!0)]),_:1},8,["modelValue"]),i.value?pe("",!0):Vp(P.$slots,"default",{key:0})],64))}});async function JX(){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 ZX=de({...Ue(),...cO({fullHeight:!0}),...Lt()},"VApp"),eQ=ke()({name:"VApp",props:ZX(),setup(e,t){let{slots:n}=t;const r=Zt(e),{layoutClasses:s,getLayoutItem:i,items:o,layoutRef:a}=pO(e),{rtlClasses:l}=Dr();return Oe(()=>{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}}}),tQ=de({scrollable:Boolean,...Ue(),...Or(),...yt({tag:"main"})},"VMain"),nQ=ke()({name:"VMain",props:tQ(),setup(e,t){let{slots:n}=t;const{dimensionStyles:r}=Mr(e),{mainStyles:s}=fO(),{ssrBootStyles:i}=jd();return Oe(()=>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)]}})),{}}}),rQ=Le({__name:"App",setup(e){const t=gw(),n=us(),r=t.queuedUploads;return Ee(r,async()=>{await t.handleNextUpload()}),St(()=>{JX(),console.debug(`App.vue mounted. Logged in: ${n.hasAuthToken}, Expired: ${n.isLoginExpired}`)}),(s,i)=>{const o=NX,a=LX,l=OX,u=TX,c=CX,d=In("router-view"),f=lK,p=Y9,g=g9,m=p9,y=d9,w=a9,b=WG,k=vG,C=oG,_=BW,T=sW;return $(),te(eQ,null,{default:v(()=>[h(o),h(a),h(l),Q(n).hasAuthToken&&!Q(n).isLoginExpired||!Q(n).loginRequired?($(),te(u,{key:0})):pe("",!0),Q(n).hasAuthToken&&!Q(n).isLoginExpired||!Q(n).loginRequired?($(),te(c,{key:1})):pe("",!0),h(QX,null,{default:v(()=>[h(nQ,null,{default:v(()=>[h(d)]),_:1})]),_:1}),h(f),h(p),h(g),h(m),h(y),h(w),h(b),h(k),h(C),h(_),h(T)]),_:1})}}}),vw="/img/logo.svg",TM=Le({__name:"PrinterCreateAction",props:{floorId:{},floorX:{},floorY:{}},setup(e){const t=e,n=tn(nn.AddOrUpdatePrinterDialog);function r(){n.openDialog(t)}return(s,i)=>($(),te(se,{class:"ma-2",color:"primary",size:"small",rounded:"",onClickCapture:i[0]||(i[0]=_t(o=>r(),["stop"]))},{default:v(()=>[h(J,null,{default:v(()=>i[1]||(i[1]=[x("add")])),_:1}),i[2]||(i[2]=x(" New printer "))]),_:1}))}});class PM extends gr{static async postQuickStopM112Command(t){const n=Me.sendQuickStopM112Route(t);return await this.post(n)}}const Dm=gs("GridStore",{state:()=>({gridEditMode:!1})}),sQ="thumbnail",iQ=(e,t)=>Pm({queryKey:[sQ,e],queryFn:async()=>e.value?$i.getThumbnail(e.value).then(n=>n.thumbnailBase64||""):"",enabled:!!e&&!!t}),oQ={class:"d-flex flex flex-column justify-center",style:{height:"100%"}},aQ={key:1,class:"printer-file-or-stream-viewer"},lQ={key:2,class:"printer-file-or-stream-viewer"},uQ={key:3,class:"printer-menu"},cQ={class:"file-name"},dQ={key:5,class:"centered-controls"},fQ={key:0},hQ={key:1},rx="rgba(100,100,100,0.1)",pQ=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=Ft(),r=nr(),s=Qi(),i=Ns(),o=Dm(),a=tn(nn.PrinterControlDialog),l=tn(nn.AddOrUpdatePrinterDialog),u=Dt(),c=A(()=>{var H;return(H=t.printer)==null?void 0:H.id}),d=A(()=>i.largeTiles),f=A(()=>d.value?"80px":"40px"),{data:p}=iQ(c,i.thumbnailsEnabled),g=A(()=>c.value?r.isApiResponding(c.value):!1),m=A(()=>c.value?r.isPrinterOperational(c.value):!1),y=A(()=>c.value?r.isPrinterPrinting(c.value):!1),w=A(()=>c.value?r.isPrinterPaused(c.value):!1),b=A(()=>c.value?n.isSelectedPrinter(c.value):!1),k=A(()=>{var H;return((H=n.selectedPrinters)==null?void 0:H.length)&&!b.value}),C=A(()=>i.preferCancelOverQuickStop),_=A(()=>{if(!c.value)return;const H=n.printer(c.value);if(!H)return;const B=r.printerEventsById[c.value],ee=r.socketStatesById[c.value];return CA(H,ee,B)}),T=A(()=>{const H=_.value;return H&&H.rgb||rx}),P=A(()=>{if(c.value)return r.printerJobsById[c.value]}),S=A(()=>{if(c.value)return r.printingFilePathsByPrinterId[c.value]}),E=async()=>{c.value&&confirm("Are you sure to cancel the current print job?")&&await Ma.stopPrintJob(c.value)},I=async()=>{c.value&&await Ma.pausePrintJob(c.value)},O=async()=>{c.value&&await Ma.resumePrintJob(c.value)},R=()=>{n.setSideNavPrinter(t.printer)},M=async()=>{c.value&&(await Qt.refreshSocket(c.value),u.openInfoMessage({title:"Refreshing connection state"}))},D=()=>{n.setUpdateDialogPrinter(t.printer),l.openDialog()},F=async()=>{if(!c.value)throw new Error("PrinterId not set, cant open dialog");await a.openDialog({printerId:c})},U=async()=>{c.value&&confirm("Are you sure to abort the print in Quick Stop mode? Please reconnect after.")&&await PM.postQuickStopM112Command(c.value)},K=async()=>{c.value&&await Qt.sendPrinterConnectCommand(c.value)},X=async()=>{var H;if(!(!t.printer||!c.value)){if(o.gridEditMode){const B=(H=s.selectedFloor)==null?void 0:H.id;if(!B)throw new Error("Cant clear printer, floor not selected");await ns.deletePrinterFromFloor(B,c.value);return}n.toggleSelectedPrinter(t.printer)}};return(H,B)=>{const ee=TM,q=hr("drop-upload"),G=hr("drop-printer-position");return Bt(($(),ve("div",null,[Bt(($(),te(vt,{class:Bo([{"tile-large":d.value,"tile-selected":b.value,"tile-unselected":k.value,"tile-no-printer":!e.printer},"tile colored-tile rounded-lg"]),elevation:"5",onClick:B[8]||(B[8]=le=>X())},{default:v(()=>{var le,ie,Se,Z,he,ne,z;return[Bt(L("div",{class:"printer-title"},re(((le=e.printer)==null?void 0:le.name)??" "),513),[[Yi,e.printer]]),!e.printer||Q(o).gridEditMode?($(),ve("div",{key:0,style:is([{height:d.value?"calc(120px - 20px)":"calc(84px - 20px)"},{position:"absolute"}]),class:"plus-hover-icon"},[L("div",oQ,[e.printer?pe("",!0):($(),te(ee,{key:0,"floor-id":(ie=Q(s).selectedFloor)==null?void 0:ie.id,"floor-x":e.x,"floor-y":e.y},null,8,["floor-id","floor-x","floor-y"])),e.printer?($(),te(se,{key:1,color:"error",rounded:"",small:"",onClickCapture:B[0]||(B[0]=_t(xe=>X(),["stop"]))},{default:v(()=>[h(J,null,{default:v(()=>B[9]||(B[9]=[x("clear")])),_:1}),B[10]||(B[10]=x(" Clear position "))]),_:1})):pe("",!0)])],4)):pe("",!0),e.printer&&g.value?($(),ve("div",aQ,[(Se=Q(p))!=null&&Se.length?($(),te(ds,{key:1,src:"data:image/png;base64,"+(Q(p)??""),width:f.value},null,8,["src","width"])):($(),te(ds,{key:0,src:Q(pw),width:f.value,alt:"No thumbnail was found in GCode",style:{opacity:"0.3",filter:"grayscale(100%)"}},null,8,["src","width"]))])):e.printer?($(),ve("div",lQ,[(Z=_.value)!=null&&Z.text.includes("API")?($(),te(J,{key:0,size:f.value,color:"secondary"},{default:v(()=>B[11]||(B[11]=[x(" wifi_off ")])),_:1},8,["size"])):pe("",!0),e.printer.enabled?pe("",!0):($(),te(J,{key:1,size:f.value,color:"secondary"},{default:v(()=>B[12]||(B[12]=[x(" disabled_by_default ")])),_:1},8,["size"])),(he=_.value)!=null&&he.text.includes("unset")?($(),te(J,{key:2,size:f.value,color:"secondary"},{default:v(()=>B[13]||(B[13]=[x(" question_mark ")])),_:1},8,["size"])):pe("",!0)])):pe("",!0),e.printer&&!Q(o).gridEditMode?($(),ve("div",uQ,[h(nt,{top:""},{activator:v(({props:xe})=>[h(se,ge({color:"darkgray",elevation:"0",small:"",style:{"border-radius":"7px"}},xe,{onClick:B[1]||(B[1]=_t(Fe=>R(),["prevent","stop"]))}),{default:v(()=>[h(J,{dark:""},{default:v(()=>B[14]||(B[14]=[x("menu")])),_:1})]),_:2},1040)]),default:v(()=>B[15]||(B[15]=[x("Open printer details")])),_:1})])):pe("",!0),e.printer&&!Q(o).gridEditMode?($(),ve("div",{key:4,style:is([{position:d.value?"inherit":"absolute",top:d.value?"inherit":"30px"},{overflow:"clip"}]),class:"printer-controls"},[L("small",cQ,re(S.value??" "),1)],4)):pe("",!0),e.printer&&!Q(o).gridEditMode?($(),ve("div",dQ,[h(nt,{top:""},{activator:v(({props:xe})=>[h(se,ge({disabled:!g.value||!m.value,size:d.value?"small":"x-small",color:"darkgray",elevation:"0",style:{"border-radius":"7px"}},xe,{onClick:B[2]||(B[2]=_t(Fe=>F(),["prevent","stop"]))}),{default:v(()=>[h(J,null,{default:v(()=>B[16]||(B[16]=[x("open_with")])),_:1})]),_:2},1040,["disabled","size"])]),default:v(()=>B[17]||(B[17]=[x("Move and home printer")])),_:1}),h(nt,{top:""},{activator:v(({props:xe})=>[!m.value&&g.value?($(),te(se,ge({key:0,size:d.value?"small":"x-small",color:"darkgray",elevation:"0",style:{"border-radius":"7px"}},xe,{onClick:B[3]||(B[3]=_t(Fe=>K(),["prevent","stop"]))}),{default:v(()=>[h(J,null,{default:v(()=>B[18]||(B[18]=[x("usb")])),_:1})]),_:2},1040,["size"])):pe("",!0)]),default:v(()=>B[19]||(B[19]=[x("Connect USB (only for OctoPrint)")])),_:1}),h(nt,{top:""},{activator:v(({props:xe})=>[h(se,ge({size:d.value?"small":"x-small",color:"darkgray",elevation:"0",style:{"border-radius":"7px"}},xe,{onClick:B[4]||(B[4]=_t(Fe=>M(),["prevent","stop"]))}),{default:v(()=>[h(J,null,{default:v(()=>B[20]||(B[20]=[x("refresh")])),_:1})]),_:2},1040,["size"])]),default:v(()=>B[21]||(B[21]=[x("Reload printer websocket and refresh all states ")])),_:1}),h(nt,{top:""},{activator:v(({props:xe})=>[h(se,ge({disabled:!g.value||!w.value&&!y.value,size:d.value?"small":"x-small",color:"darkgray",elevation:"0",style:{"border-radius":"7px"}},xe,{onClick:B[5]||(B[5]=_t(Fe=>w.value?O():I(),["prevent","stop"]))}),{default:v(()=>[w.value?pe("",!0):($(),te(J,{key:0},{default:v(()=>B[22]||(B[22]=[x("pause")])),_:1})),w.value?($(),te(J,{key:1},{default:v(()=>B[23]||(B[23]=[x("play_arrow")])),_:1})):pe("",!0)]),_:2},1040,["disabled","size"])]),default:v(()=>[x(re(w.value?"Resume print":"Pause print"),1)]),_:1}),h(nt,{top:""},{activator:v(({props:xe})=>[h(se,ge({disabled:!g.value||C.value&&!y.value&&!w.value,size:d.value?"small":"x-small",color:"darkgray",elevation:"0",style:{"border-radius":"7px"}},xe,{onClick:B[6]||(B[6]=_t(Fe=>C.value?E():U(),["prevent","stop"]))}),{default:v(()=>[h(J,null,{default:v(()=>[x(re(C.value?"stop":"dangerous"),1)]),_:1})]),_:2},1040,["disabled","size"])]),default:v(()=>[x(re(C.value?"Cancel current print gracefully":"Perform quick stop of printer"),1)]),_:1}),h(nt,{top:""},{activator:v(({props:xe})=>[h(se,ge({size:d.value?"small":"x-small",color:"darkgray",elevation:"0",style:{"border-radius":"7px"}},xe,{onClick:B[7]||(B[7]=_t(Fe=>D(),["prevent","stop"]))}),{default:v(()=>[h(J,null,{default:v(()=>B[24]||(B[24]=[x("settings")])),_:1})]),_:2},1040,["size"])]),default:v(()=>B[25]||(B[25]=[x("Open printer settings")])),_:1})])):pe("",!0),e.printer&&!Q(o).gridEditMode?($(),te(su,{key:6,value:(z=(ne=P.value)==null?void 0:ne.progress)==null?void 0:z.completion,"background-color":"dark-gray",class:"progress-bar",height:"14"},{default:v(({value:xe})=>{var Fe;return[L("strong",null,re((xe==null?void 0:xe.toFixed(1))+"%"),1),h(nt,{disabled:(Fe=e.printer)==null?void 0:Fe.enabled,"close-delay":"100",color:"danger","open-delay":"0",top:""},{activator:v(({props:N})=>{var V,Y,fe;return[L("span",ge({class:"xsmall-resized-font text--secondary ml-sm-2"},N),[(V=e.printer)!=null&&V.disabledReason?($(),ve("span",fQ,[B[27]||(B[27]=L("small",null," MAINTENANCE",-1)),h(J,{class:"d-none d-xl-inline",color:"primary",small:""},{default:v(()=>B[26]||(B[26]=[x("info")])),_:1})])):($(),ve("span",hQ,[L("small",{style:is({"background-color":T.value+"99","border-left":"5px solid "+T.value+"ff",padding:"5px"})},re((fe=(Y=_.value)==null?void 0:Y.text)==null?void 0:fe.toUpperCase()),5)]))],16)]}),default:v(()=>{var N;return[L("span",null,re(((N=e.printer)==null?void 0:N.disabledReason)??"Printer disabled"),1)]}),_:1},8,["disabled"])]}),_:1},8,["value"])):pe("",!0)]}),_:1},8,["class"])),[[q,{printers:[e.printer]}]])])),[[G,{x:e.x,y:e.y,printerSet:e.printer}]])}}}),RM="FDM-Monster-Client-Vue2";var IM=(e=>(e.PRINTER_PLACE="PRINTER_PLACE",e))(IM||{});function mQ(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===RM&&e.intent==="PRINTER_PLACE"}const gQ=de({color:String,density:String,...Ue()},"VBannerActions"),vQ=ke()({name:"VBannerActions",props:gQ(),setup(e,t){let{slots:n}=t;return Ir({VBtn:{color:e.color,density:e.density,slim:!0,variant:"text"}}),Oe(()=>{var r;return h("div",{class:["v-banner-actions",e.class],style:e.style},[(r=n.default)==null?void 0:r.call(n)])}),{}}}),yQ=ku("v-banner-text"),bQ=de({avatar:String,bgColor:String,color:String,icon:He,lines:String,stacked:Boolean,sticky:Boolean,text:String,...vs(),...Ue(),...Ar(),...Or(),...tl({mobile:null}),...bs(),...jo(),...Cu(),...Dn(),...yt(),...Lt()},"VBanner"),AM=ke()({name:"VBanner",props:bQ(),setup(e,t){let{slots:n}=t;const{backgroundColorClasses:r,backgroundColorStyles:s}=fr(()=>e.bgColor),{borderClasses:i}=Ds(e),{densityClasses:o}=ys(e),{displayClasses:a,mobile:l}=fi(e),{dimensionStyles:u}=Mr(e),{elevationClasses:c}=Ls(e),{locationStyles:d}=el(e),{positionClasses:f}=Tu(e),{roundedClasses:p}=zn(e),{themeClasses:g}=Zt(e),m=ae(()=>e.color),y=ae(()=>e.density);Ir({VBannerActions:{color:m,density:y}}),Oe(()=>{const w=!!(e.text||n.text),b=!!(e.avatar||e.icon),k=!!(b||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,c.value,f.value,p.value,e.class],style:[s.value,u.value,d.value,e.style],role:"banner"},{default:()=>{var C;return[k&&h("div",{key:"prepend",class:"v-banner__prepend"},[n.prepend?h(Ot,{key:"prepend-defaults",disabled:!b,defaults:{VAvatar:{color:m.value,density:y.value,icon:e.icon,image:e.avatar}}},n.prepend):h(ut,{key:"prepend-avatar",color:m.value,density:y.value,icon:e.icon,image:e.avatar},null)]),h("div",{class:"v-banner__content"},[w&&h(yQ,{key:"text"},{default:()=>{var _;return[((_=n.text)==null?void 0:_.call(n))??e.text]}}),(C=n.default)==null?void 0:C.call(n)]),n.actions&&h(vQ,{key:"actions"},n.actions)]}})})}}),wQ={class:"printer-grid-container"},SQ={key:0,class:"d-flex flex-row justify-start",style:{gap:"10px",width:"100%"}},_Q={key:0,class:"d-flex flex-column justify-start",style:{gap:"10px","margin-top":"10px"}},kQ=Le({__name:"PrinterGrid",props:{gap:{type:String,default:"4px"}},setup(e){const t=Ft(),n=Qi(),r=Ns(),s=Dm();St(async()=>{await t.loadPrinters(),await n.loadFloors()});const i=e,o=A(()=>n.gridSortedPrinters),a=A(()=>r.gridCols),l=A(()=>r.gridRows),u=A(()=>r.largeTiles),c=A(()=>l.value*a.value),d=A(()=>({display:"grid",gridTemplateColumns:`repeat(${a.value}, 1fr)`,gap:i.gap})),f=C=>C%a.value,p=C=>Math.floor(C/a.value);function g(C,_){_.dataTransfer&&C.id&&_.dataTransfer.setData("text",JSON.stringify({appId:RM,intent:IM.PRINTER_PLACE,printerId:C.id}))}function m(C,_){var S;const T=C,P=_;if(!(!((S=o.value)!=null&&S.length)||!o.value[T]))return o.value[T][P]}async function y(){!s.gridEditMode||!r.frontendSettings||r.frontendSettings.gridRows>=16||(r.frontendSettings.gridRows++,await r.saveFrontendSettings())}async function w(){!s.gridEditMode||!r.frontendSettings||r.frontendSettings.gridCols>=12||(r.frontendSettings.gridCols++,await r.saveFrontendSettings())}async function b(){!s.gridEditMode||!r.frontendSettings||r.frontendSettings.gridRows!=1&&(r.frontendSettings.gridRows--,await r.saveFrontendSettings())}async function k(){!s.gridEditMode||!r.frontendSettings||r.frontendSettings.gridCols!=1&&(r.frontendSettings.gridCols--,await r.saveFrontendSettings())}return(C,_)=>($(),ve("div",null,[Q(s).gridEditMode?($(),te(AM,{key:0},{default:v(()=>[h(rt,{style:{"margin-bottom":"-5px"}},{default:v(()=>[h(ze,null,{default:v(()=>[L("span",null," Drag "+re(Q(n).floorlessPrinters.length)+" unplaced printer(s) from here to place it on the grid. ",1),h(op,null,{default:v(()=>[($(!0),ve(Ae,null,Gt(Q(n).floorlessPrinters,T=>($(),te(_n,{key:T.id,draggable:"",size:"small",style:{cursor:"move"},onDragstart:P=>g(T,P)},{default:v(()=>[x(re(T.name),1)]),_:2},1032,["onDragstart"]))),128))]),_:1})]),_:1}),h(ze,null,{default:v(()=>[L("div",null,[_[6]||(_[6]=x(" Clear printers by clicking on ")),L("strong",null,[h(J,null,{default:v(()=>_[4]||(_[4]=[x("disabled_visible")])),_:1}),_[5]||(_[5]=x(" Click to clear "))])])]),_:1})]),_:1})]),_:1})):pe("",!0),L("div",wQ,[L("div",{class:"printer-grid",style:is(d.value)},[($(!0),ve(Ae,null,Gt(c.value,T=>($(),ve("div",{key:`printer-${f(T-1)}-${p(T-1)}`,class:Bo(["printer-cell",{"printer-cell-large":u.value}])},[h(pQ,{printer:m(f(T-1),p(T-1)),x:f(T-1),y:p(T-1)},null,8,["printer","x","y"])],2))),128)),Q(s).gridEditMode?($(),ve("div",SQ,[_[9]||(_[9]=x(" Columns ")),h(se,{"x-small":"",rounded:"",disabled:Q(r).gridCols<=1,onClick:_[0]||(_[0]=T=>k())},{default:v(()=>[h(J,null,{default:v(()=>_[7]||(_[7]=[x("remove")])),_:1})]),_:1},8,["disabled"]),h(se,{"x-small":"",rounded:"",disabled:Q(r).gridCols>=12,onClick:_[1]||(_[1]=T=>w())},{default:v(()=>[h(J,null,{default:v(()=>_[8]||(_[8]=[x("add")])),_:1})]),_:1},8,["disabled"])])):pe("",!0)],4),Q(s).gridEditMode?($(),ve("div",_Q,[_[12]||(_[12]=x(" Rows ")),h(se,{"x-small":"",rounded:"",disabled:Q(r).gridRows<=1,onClick:_[2]||(_[2]=T=>b())},{default:v(()=>[h(J,null,{default:v(()=>_[10]||(_[10]=[x("remove")])),_:1})]),_:1},8,["disabled"]),h(se,{"x-small":"",rounded:"",disabled:Q(r).gridRows>=16,onClick:_[3]||(_[3]=T=>y())},{default:v(()=>[h(J,null,{default:v(()=>_[11]||(_[11]=[x("add")])),_:1})]),_:1},8,["disabled"])])):pe("",!0)]),_[13]||(_[13]=L("img",{alt:"FDM Monster Background",class:"grid-bg-img align-content-center",src:vw,style:{opacity:"0.08","pointer-events":"none"}},null,-1))]))}}),xQ=Ko(kQ,[["__scopeId","data-v-0a20edf3"]]);function EQ(e,t){return e?t.map(n=>({file:n,printer:e})):[]}function OM(e,t){return!(e!=null&&e.length)||!t?[]:e.map(n=>({file:t,printer:n}))}const CQ=de({indeterminate:Boolean,inset:Boolean,flat:Boolean,loading:{type:[Boolean,String],default:!1},...ol(),...Cm()},"VSwitch"),mp=ke()({name:"VSwitch",inheritAttrs:!1,props:CQ(),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}=Rd(e),{isFocused:a,focus:l,blur:u}=Uu(e),c=j(),d=Et&&window.matchMedia("(forced-colors: active)").matches,f=ae(()=>typeof e.loading=="string"&&e.loading!==""?e.loading:e.color),p=ms(),g=ae(()=>e.id||`switch-${p}`);function m(){s.value&&(s.value=!1)}function y(w){var b,k;w.stopPropagation(),w.preventDefault(),(k=(b=c.value)==null?void 0:b.input)==null||k.click()}return Oe(()=>{const[w,b]=Ja(n),k=fs.filterProps(e),C=Ga.filterProps(e);return h(fs,ge({class:["v-switch",{"v-switch--flat":e.flat},{"v-switch--inset":e.inset},{"v-switch--indeterminate":s.value},o.value,e.class]},w,k,{modelValue:i.value,"onUpdate:modelValue":_=>i.value=_,id:g.value,focused:a.value,style:e.style}),{...r,default:_=>{let{id:T,messagesId:P,isDisabled:S,isReadonly:E,isValid:I}=_;const O={model:i,isValid:I};return h(Ga,ge({ref:c},C,{modelValue:i.value,"onUpdate:modelValue":[R=>i.value=R,m],id:T.value,"aria-describedby":P.value,type:"checkbox","aria-checked":s.value?"mixed":void 0,disabled:S.value,readonly:E.value,onFocus:l,onBlur:u},b),{...r,default:R=>{let{backgroundColorClasses:M,backgroundColorStyles:D}=R;return h("div",{class:["v-switch__track",d?void 0:M.value],style:D.value,onClick:y},[r["track-true"]&&h("div",{key:"prepend",class:"v-switch__track-true"},[r["track-true"](O)]),r["track-false"]&&h("div",{key:"append",class:"v-switch__track-false"},[r["track-false"](O)])])},input:R=>{let{inputNode:M,icon:D,backgroundColorClasses:F,backgroundColorStyles:U}=R;return h(Ae,null,[M,h("div",{class:["v-switch__thumb",{"v-switch__thumb--filled":D||e.loading},e.inset||d?void 0:F.value],style:e.inset?void 0:U.value},[r.thumb?h(Ot,{defaults:{VIcon:{icon:D,size:"x-small"}}},{default:()=>[r.thumb({...O,icon:D})]}):h(cN,null,{default:()=>[e.loading?h(Kp,{name:"v-switch",active:!0,color:I.value===!1?void 0:f.value},{default:K=>r.loader?r.loader(K):h(ni,{active:K.isActive,color:K.color,indeterminate:!0,size:"16",width:"2"},null)}):D&&h(J,{key:String(D),icon:D,size:"x-small"},null)]})])])}})}})}),{}}}),TQ={class:"d-flex flex-wrap gap-2"},PQ={class:"pr-2"},RQ={class:"pr-2"},IQ={class:"pr-2"},AQ={class:"pr-2"},OQ={class:"pr-2"},MQ={class:"ma-4 pt-6"},DQ=Le({__name:"HomeToolbar",setup(e){const t=Ft(),n=nr(),r=Qi(),s=Dm(),i=A(()=>r.selectedFloorIndex),o=A(()=>r.floors);function a(l){r.changeSelectedFloorByIndex(l)}return(l,u)=>($(),te(mr,{flat:""},{default:v(()=>{var c;return[h(ZT,{"model-value":i.value,class:"ml-7",mandatory:"",rounded:"","onUpdate:modelValue":a},{default:v(()=>[($(!0),ve(Ae,null,Gt(o.value,d=>($(),te(se,{key:d.id,size:"small"},{default:v(()=>[h(J,null,{default:v(()=>u[2]||(u[2]=[x("layers")])),_:1}),x(" "+re(d.name),1)]),_:2},1024))),128))]),_:1},8,["model-value"]),(c=Q(t).printers)!=null&&c.length?pe("",!0):($(),te(se,{key:0,class:"mt-0 ml-6",color:"primary",to:"/printers"},{default:v(()=>u[3]||(u[3]=[x(" You have no printers. Click here to start! ")])),_:1})),Q(r).floorlessPrinters.length?($(),te(fn,{key:1,class:"ml-4"},{default:v(()=>[h(J,null,{default:v(()=>u[4]||(u[4]=[x("warning")])),_:1}),x(" "+re(Q(r).floorlessPrinters.length)+" unplaced printer(s)! ",1)]),_:1})):pe("",!0),h(Sn),L("span",TQ,[L("span",PQ,[h(J,null,{default:v(()=>u[5]||(u[5]=[x("print")])),_:1}),x(" "+re(Q(n).printingCount),1)]),L("span",RQ,[h(J,null,{default:v(()=>u[6]||(u[6]=[x("ac_unit")])),_:1}),x(" "+re(Q(n).operationalNotPrintingCount),1)]),L("span",IQ,[h(J,null,{default:v(()=>u[7]||(u[7]=[x("handyman")])),_:1}),x(" "+re(Q(t).maintenanceCount),1)]),L("span",AQ,[h(J,null,{default:v(()=>u[8]||(u[8]=[x("usb_off")])),_:1}),x(" "+re(Q(t).disconnectedCount),1)]),L("span",OQ,[h(J,null,{default:v(()=>u[9]||(u[9]=[x("print_disabled")])),_:1}),x(" "+re(Q(t).disabledCount),1)])]),h(se,{elevation:"2",small:"",class:"ml-6",icon:"",onClick:u[0]||(u[0]=d=>Q(tn)(Q(nn).GridSettingsDialog).openDialog())},{default:v(()=>[h(J,null,{default:v(()=>u[10]||(u[10]=[x("settings")])),_:1})]),_:1}),L("div",MQ,[h(mp,{modelValue:Q(s).gridEditMode,"onUpdate:modelValue":u[1]||(u[1]=d=>Q(s).gridEditMode=d),label:"Grid Edit Mode"},null,8,["modelValue"])])]}),_:1}))}}),LQ={class:"pl-1"},$Q=Le({__name:"PrinterGridView",setup(e){const t=Dm(),n=Ft(),r=nr(),s=gw(),i=Dt(),o=j(void 0),a=A(()=>n.selectedPrinters.length>0),l=A(()=>n.selectedPrinters),u=j(null),c=()=>{u.value&&(u.value.value="",o.value=void 0)},d=()=>{n.clearSelectedPrinters()},f=async()=>{var b;const w=await tn(nn.BatchReprintDialog).handleAsync((b=n.selectedPrinters)==null?void 0:b.map(k=>k.id));console.log("[PrinterGridView] Dialog completed",w)},p=()=>{const w=l.value,b=w.filter(_=>r.isApiResponding(_.id));if(!o.value)return;const k=w.length-b.length;k>0&&i.openInfoMessage({title:`${k} printers inaccessible`,subtitle:"These were skipped from uploading."});const C=OM(b,o.value);s.queueUploads(C),u.value&&(u.value.value=""),d()},g=()=>{u.value&&u.value.files?o.value=u.value.files[0]:o.value=void 0},m=w=>{n.toggleSelectedPrinter(w)},y=w=>{Qt.openPrinterURL(w.printerURL)};return(w,b)=>{const k=hr("drop-upload");return $(),ve("div",null,[h(DQ),Q(t).gridEditMode?pe("",!0):Bt(($(),te(AM,{key:0},{default:v(()=>[h(rt,{style:{"margin-bottom":"-5px"}},{default:v(()=>[h(ze,{style:{padding:"5px 0 0 15px"}},{default:v(()=>[h(op,{class:"d-inline-block"},{default:v(()=>[l.value.length===0?($(),te(_n,{key:0,size:"small"},{default:v(()=>b[6]||(b[6]=[x(" No selected printers ")])),_:1})):pe("",!0),($(!0),ve(Ae,null,Gt(l.value,C=>($(),te(_n,{key:C.id,closable:"",color:"primary",size:"small",onClick:_=>y(C),"onClick:close":_=>m(C)},{default:v(()=>[x(re(C.name),1)]),_:2},1032,["onClick","onClick:close"]))),128))]),_:1})]),_:1}),h(ze,{align:"right",style:{padding:"0"}},{default:v(()=>[o.value?($(),te(op,{key:0,class:"float-end"},{default:v(()=>[h(_n,{closable:"","onClick:close":b[0]||(b[0]=C=>c())},{default:v(()=>[x(re(o.value.name)+" ",1),L("strong",LQ,re(Q(sO)(o.value.size)),1)]),_:1})]),_:1})):pe("",!0),b[12]||(b[12]=L("br",null,null,-1)),h(se,{disabled:!a.value,color:"primary",size:"x-small",onClick:b[1]||(b[1]=C=>f())},{default:v(()=>[h(J,{class:"pr-2",size:"small"},{default:v(()=>b[7]||(b[7]=[x(" refresh ")])),_:1}),b[8]||(b[8]=x(" Batch reprint "))]),_:1},8,["disabled"]),h(se,{color:a.value?"primary":"secondary",class:"ml-2",size:"x-small",onClick:b[2]||(b[2]=C=>d())},{default:v(()=>[h(J,{class:"pr-2",size:"small"},{default:v(()=>b[9]||(b[9]=[x(" delete ")])),_:1}),x(" Clear all ("+re(l.value.length)+") ",1)]),_:1},8,["color"]),h(se,{class:"ml-2",color:"primary",size:"x-small",onClick:b[3]||(b[3]=C=>{var _;return(_=u.value)==null?void 0:_.click()})},{default:v(()=>b[10]||(b[10]=[x(" Select gcode file ")])),_:1}),h(se,{disabled:!o.value,class:"ml-2 mr-5",color:"green",size:"x-small",onClick:b[4]||(b[4]=C=>p())},{default:v(()=>b[11]||(b[11]=[x(" Upload gcode file ")])),_:1},8,["disabled"]),L("input",{ref_key:"fileUpload",ref:u,multiple:!1,accept:".gcode",style:{display:"none"},type:"file",onChange:b[5]||(b[5]=C=>g())},null,544)]),_:1})]),_:1})]),_:1})),[[k,{printers:l.value}]]),h(xQ,{class:"ma-2"})])}}}),FQ=Le({name:"RefreshFilesAction",components:{},props:{printer:Object},setup:()=>({printersStore:Ft()}),methods:{async getFiles(){this.printer&&await this.printersStore.loadPrinterFiles(this.printer.id)}}});function NQ(e,t,n,r,s,i){return $(),te(se,{color:"secondary",onClick:t[0]||(t[0]=o=>e.getFiles())},{default:v(()=>[h(J,null,{default:v(()=>t[1]||(t[1]=[x("refresh")])),_:1}),t[2]||(t[2]=L("span",{class:"d-none d-lg-inline"}," Refresh files ",-1))]),_:1})}const MM=Ko(FQ,[["render",NQ]]),BQ=Le({name:"PrinterDetails",components:{RefreshFilesAction:MM},props:{printer:Object},setup:()=>({printersStore:Ft(),printerStateStore:nr()}),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 VQ(e,t,n,r,s,i){const o=MM,a=hr("drop-upload");return e.printer?Bt(($(),te(Un,{key:0,style:is(e.dragging?"background-color:red":""),transition:"scale-transition"},{default:v(()=>[h(rt,null,{default:v(()=>[h(ze,null,{default:v(()=>[x(" Name: "+re(e.printer.name)+" ",1),t[0]||(t[0]=L("br",null,null,-1)),x(" URL: "+re(e.printer.printerURL)+" ",1),t[1]||(t[1]=L("br",null,null,-1)),t[2]||(t[2]=x(" Host: ")),h(_n,{size:"small"},{default:v(()=>[x(re(e.apiState),1)]),_:1}),t[3]||(t[3]=L("br",null,null,-1)),t[4]||(t[4]=x(" WebSocket: ")),h(_n,{size:"small"},{default:v(()=>[x(re(e.socketState),1)]),_:1}),t[5]||(t[5]=L("br",null,null,-1)),t[6]||(t[6]=x(" Printer: ")),h(_n,{size:"small"},{default:v(()=>[x(re(e.printerTextState),1)]),_:1})]),_:1}),h(ze,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]}]]):pe("",!0)}const UQ=Ko(BQ,[["render",VQ]]),zQ=Le({__name:"PrinterUrlAction",props:{printer:{}},setup(e){const t=e;async function n(){Qt.openPrinterURL(t.printer.printerURL)}return(r,s)=>($(),te(nt,{location:"top"},{activator:v(({props:i})=>[h(se,ge(i,{color:"secondary",rounded:"",size:"small",onClickCapture:s[0]||(s[0]=_t(o=>n(),["stop"]))}),{default:v(()=>[h(J,null,{default:v(()=>s[1]||(s[1]=[x("directions")])),_:1})]),_:2},1040)]),default:v(()=>s[2]||(s[2]=[x("Visit printer service")])),_:1}))}}),HQ=Le({name:"PrinterSettingsAction",props:{printer:Object},computed:{printerId(){return this.printer.id}},methods:{openSettings(){this.$emit("update:show",this.printer.id)}}});function jQ(e,t,n,r,s,i){return $(),te(nt,{location:"top"},{activator:v(({props:o})=>[h(se,ge(o,{color:"secondary",class:"ma-2",size:"small",rounded:"",onClickCapture:t[0]||(t[0]=_t(a=>e.openSettings(),["stop"]))}),{default:v(()=>[h(J,null,{default:v(()=>t[1]||(t[1]=[x("settings")])),_:1})]),_:2},1040)]),default:v(()=>t[2]||(t[2]=[x("Update printer settings")])),_:1})}const qQ=Ko(HQ,[["render",jQ]]),WQ=de({bordered:Boolean,color:String,content:[Number,String],dot:Boolean,floating:Boolean,icon:He,inline:Boolean,label:{type:String,default:"$vuetify.badge"},max:[Number,String],modelValue:{type:Boolean,default:!0},offsetX:[Number,String],offsetY:[Number,String],textColor:String,...Ue(),...jo({location:"top end"}),...Dn(),...yt(),...Lt(),...Iu({transition:"scale-rotate-transition"})},"VBadge"),DM=ke()({name:"VBadge",inheritAttrs:!1,props:WQ(),setup(e,t){const{backgroundColorClasses:n,backgroundColorStyles:r}=fr(()=>e.color),{roundedClasses:s}=zn(e),{t:i}=Gr(),{textColorClasses:o,textColorStyles:a}=As(()=>e.textColor),{themeClasses:l}=YT(),{locationStyles:u}=el(e,!0,c=>(e.floating?e.dot?2:4:e.dot?8:12)+(["top","bottom"].includes(c)?Number(e.offsetY??0):["left","right"].includes(c)?Number(e.offsetX??0):0));return Oe(()=>{const c=Number(e.content),d=!e.max||isNaN(c)?e.content:c<=Number(e.max)?c:`${e.max}+`,[f,p]=$v(t.attrs,["aria-atomic","aria-label","aria-live","role","title"]);return h(e.tag,ge({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(si,{transition:e.transition},{default:()=>{var y,w;return[Bt(h("span",ge({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,c),"aria-live":"polite",role:"status"},f),[e.dot?void 0:t.slots.badge?(w=(y=t.slots).badge)==null?void 0:w.call(y):e.icon?h(J,{icon:e.icon},null):d]),[[Yi,e.modelValue]])]}})])]}})}),{}}}),GQ=Le({__name:"PrinterConnectionAction",props:{printer:{}},setup(e){const t=e,n=nr();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 Qt.sendPrinterDisconnectCommand(t.printer.id);await Qt.sendPrinterConnectCommand(t.printer.id)}return(o,a)=>($(),te(nt,{location:"top"},{activator:v(({props:l})=>[o.printer.enabled?($(),te(DM,{key:0,color:r()?"green":"red",class:"pa-2"},{badge:v(()=>[r()?($(),te(J,{key:0},{default:v(()=>a[0]||(a[0]=[x("check")])),_:1})):($(),te(J,{key:1},{default:v(()=>a[1]||(a[1]=[x("close")])),_:1}))]),default:v(()=>[h(se,ge({disabled:s()},l,{color:"secondary",rounded:"",size:"small",onClick:_t(i,["stop"])}),{default:v(()=>[h(J,null,{default:v(()=>a[2]||(a[2]=[x("usb")])),_:1})]),_:2},1040,["disabled"])]),_:2},1032,["color"])):pe("",!0)]),default:v(()=>a[3]||(a[3]=[x("Connect USB (OctoPrint only)")])),_:1}))}}),KQ=Le({__name:"PrinterQuickStopAction",props:{printer:{}},setup(e){const t=e;async function n(){confirm("Are you sure to quick stop this printer?")&&await PM.postQuickStopM112Command(t.printer.id)}return(r,s)=>($(),te(nt,{location:"top"},{activator:v(({props:i})=>[r.printer.enabled?($(),te(DM,{key:0,class:"ma-2"},{badge:v(()=>[h(J,null,{default:v(()=>s[0]||(s[0]=[x("bolt")])),_:1})]),default:v(()=>[h(se,ge(i,{color:"secondary",size:"small",rounded:"",onClick:_t(n,["stop"])}),{default:v(()=>[h(J,null,{default:v(()=>s[1]||(s[1]=[x("dangerous")])),_:1})]),_:2},1040)]),_:2},1024)):pe("",!0)]),default:v(()=>s[2]||(s[2]=[x("Perform quick stop of printer")])),_:1}))}});class LM extends gr{static async getSettings(t){const n=`${Me.getPrinterSettingsRoute(t)}`;return await this.get(n)}static async setGCodeAnalysis(t,n=!1){const r=`${Me.setPrinterSettingsGCodeAnalysisRoute(t)}`;return await this.post(r,{enabled:n})}static async syncPrinterName(t){const n=`${Me.syncPrinterNameSettingRoute(t)}`;return await this.post(n)}}const YQ=Le({__name:"SyncPrinterNameAction",props:{printer:{}},setup(e){const t=e,n=Dt();async function r(){await LM.syncPrinterName(t.printer.id),n.openInfoMessage({title:"Synced printer name to OctoPrint"})}return(s,i)=>($(),te(nt,{location:"top"},{activator:v(({props:o})=>[h(se,ge(o,{color:"secondary",size:"small",rounded:"",onClickCapture:i[0]||(i[0]=_t(a=>r(),["stop"]))}),{default:v(()=>[h(J,null,{default:v(()=>i[1]||(i[1]=[x("badge")])),_:1})]),_:2},1040)]),default:v(()=>i[2]||(i[2]=[x(" Set OctoPrints name to the FDM Monster Name ")])),_:1}))}}),XQ=Le({__name:"PrinterDeleteAction",props:{printer:{}},setup(e){const t=e,n=Ft(),r=nr();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)=>($(),te(nt,{location:"top"},{activator:v(({props:a})=>[h(se,ge(a,{class:"ms-4",color:"secondary",size:"small",rounded:"",onClick:_t(s,["prevent","stop"])}),{default:v(()=>[h(J,null,{default:v(()=>o[0]||(o[0]=[x("delete")])),_:1})]),_:2},1040)]),default:v(()=>o[1]||(o[1]=[x("Delete printer")])),_:1}))}});class pl extends gr{static async createGroup(t){const n=`${Me.createGroupRoute}`,r={name:t};return await this.post(n,r)}static async deleteGroup(t){const n=`${Me.deleteGroupRoute(t)}`;return await this.delete(n)}static async getGroupsWithPrinters(){const t=`${Me.printerGroupRoute}`;return await this.get(t)}static async addPrinterToGroup(t,n){const r=`${Me.addPrinterToGroupRoute(t)}`,s={printerId:n};return await this.post(r,s)}static async deletePrinterFromGroup(t,n){const r=`${Me.deletePrinterFromGroupRoute(t)}`,s={printerId:n};return await this.delete(r,s)}static async updateGroupName(t,n){const r=`${Me.updateGroupNameRoute(t)}`,s={name:n};return await this.patch(r,s)}}const QQ=(e,t,n)=>{if(e==null||t==null)return-1;if(!t.length)return 0;e=e.toString().toLocaleLowerCase(),t=t.toString().toLocaleLowerCase();const r=[];let s=e.indexOf(t);for(;~s;)r.push([s,s+t.length]),s=e.indexOf(t,s+t.length);return r.length?r:-1};function Yg(e,t){if(!(e==null||typeof e=="boolean"||e===-1))return typeof e=="number"?[[e,e+t.length]]:Array.isArray(e[0])?e:[e]}const JQ=de({customFilter:Function,customKeyFilter:Object,filterKeys:[Array,String],filterMode:{type:String,default:"intersection"},noFilter:Boolean},"filter");function ZQ(e,t,n){var a;const r=[],s=(n==null?void 0:n.default)??QQ,i=n!=null&&n.filterKeys?An(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,c=u]=An(e[l]),d={},f={};let p=-1;if((t||o>0)&&!(n!=null&&n.noFilter)){if(typeof u=="object"){const y=i||Object.keys(c);for(const w of y){const b=Fn(c,w),k=(a=n==null?void 0:n.customKeyFilter)==null?void 0:a[w];if(p=k?k(b,t,u):s(b,t,u),p!==-1&&p!==!1)k?d[w]=Yg(p,t):f[w]=Yg(p,t);else if((n==null?void 0:n.filterMode)==="every")continue e}}else p=s(u,t,u),p!==-1&&p!==!1&&(f.title=Yg(p,t));const g=Object.keys(f).length,m=Object.keys(d).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,...d}})}return r}function eJ(e,t,n,r){const s=Ie([]),i=Ie(new Map),o=A(()=>r!=null&&r.transform?Q(t).map(l=>[l,r.transform(l)]):Q(t));On(()=>{const l=typeof n=="function"?n():Q(n),u=typeof l!="string"&&typeof l!="number"?"":String(l),c=ZQ(o.value,u,{customKeyFilter:{...e.customKeyFilter,...Q(r==null?void 0:r.customKeyFilter)},default:e.customFilter,filterKeys:e.filterKeys,filterMode:e.filterMode,noFilter:e.noFilter}),d=Q(t),f=[],p=new Map;c.forEach(g=>{let{index:m,matches:y}=g;const w=d[m];f.push(w),p.set(w.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 tJ=de({expandOnClick:Boolean,showExpand:Boolean,expanded:{type:Array,default:()=>[]}},"DataTable-expand"),$M=Symbol.for("vuetify:datatable:expanded");function nJ(e){const t=ae(()=>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 Kt($M,o),o}function FM(){const e=Qe($M);if(!e)throw new Error("foo");return e}const rJ=de({groupBy:{type:Array,default:()=>[]}},"DataTable-group"),NM=Symbol.for("vuetify:data-table-group");function sJ(e){return{groupBy:st(e,"groupBy")}}function iJ(e){const{disableSort:t,groupBy:n,sortBy:r}=e,s=j(new Set),i=A(()=>n.value.map(c=>({...c,order:c.order??!1})).concat(t!=null&&t.value?[]:r.value));function o(c){return s.value.has(c.id)}function a(c){const d=new Set(s.value);o(c)?d.delete(c.id):d.add(c.id),s.value=d}function l(c){function d(f){const p=[];for(const g of f.items)"type"in g&&g.type==="group"?p.push(...d(g)):p.push(g);return[...new Set(p)]}return d({type:"group",items:c,id:"dummy",key:"dummy",value:"dummy",depth:0})}const u={sortByWithGroups:i,toggleGroup:a,opened:s,groupBy:n,extractRows:l,isGroupOpen:o};return Kt(NM,u),u}function BM(){const e=Qe(NM);if(!e)throw new Error("Missing group!");return e}function oJ(e,t){if(!e.length)return[];const n=new Map;for(const r of e){const s=Ba(r.raw,t);n.has(s)||n.set(s,[]),n.get(s).push(r)}return n}function VM(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=oJ(e,t[0]),i=[],o=t.slice(1);return s.forEach((a,l)=>{const u=t[0],c=`${r}_${u}_${l}`;i.push({depth:n,id:c,key:u,value:l,items:o.length?VM(a,o,n+1,c):a,type:"group"})}),i}function UM(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(...UM(r.items,t))):n.push(r);return n}function aJ(e,t,n){return{flatItems:A(()=>{if(!t.value.length)return e.value;const s=VM(e.value,t.value.map(i=>i.key));return UM(s,n.value)})}}function lJ(e){let{page:t,itemsPerPage:n,sortBy:r,groupBy:s,search:i}=e;const o=an("VDataTable"),a=()=>({page:t.value,itemsPerPage:n.value,sortBy:r.value,groupBy:s.value,search:i.value});let l=null;Ee(a,u=>{as(l,u)||(l&&l.search!==u.search&&(t.value=1),o.emit("update:options",u),l=u)},{deep:!0,immediate:!0})}const uJ=de({page:{type:[Number,String],default:1},itemsPerPage:{type:[Number,String],default:10}},"DataTable-paginate"),zM=Symbol.for("vuetify:data-table-pagination");function cJ(e){const t=st(e,"page",void 0,r=>Number(r??1)),n=st(e,"itemsPerPage",void 0,r=>Number(r??10));return{page:t,itemsPerPage:n}}function dJ(e){const{page:t,itemsPerPage:n,itemsLength:r}=e,s=A(()=>n.value===-1?0:n.value*(t.value-1)),i=A(()=>n.value===-1?r.value:Math.min(r.value,s.value+n.value)),o=A(()=>n.value===-1||r.value===0?1:Math.ceil(r.value/n.value));Ee([t,o],()=>{t.value>o.value&&(t.value=o.value)});function a(f){n.value=f,t.value=1}function l(){t.value=Cr(t.value+1,1,o.value)}function u(){t.value=Cr(t.value-1,1,o.value)}function c(f){t.value=Cr(f,1,o.value)}const d={page:t,itemsPerPage:n,startIndex:s,stopIndex:i,pageCount:o,itemsLength:r,nextPage:l,prevPage:u,setPage:c,setItemsPerPage:a};return Kt(zM,d),d}function fJ(){const e=Qe(zM);if(!e)throw new Error("Missing pagination!");return e}function hJ(e){const t=an("usePaginatedItems"),{items:n,startIndex:r,stopIndex:s,itemsPerPage:i}=e,o=A(()=>i.value<=0?n.value:n.value.slice(r.value,s.value));return Ee(o,a=>{t.emit("update:currentItems",a)},{immediate:!0}),{paginatedItems:o}}const pJ={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}},HM={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 HM.select({items:n,value:t,selected:r})}},jM={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 jM.select({items:n,value:t,selected:r})}},mJ=de({showSelect:Boolean,selectStrategy:{type:[String,Object],default:"page"},modelValue:{type:Array,default:()=>[]},valueComparator:{type:Function,default:as}},"DataTable-select"),qM=Symbol.for("vuetify:data-table-selection");function gJ(e,t){let{allItems:n,currentPage:r}=t;const s=st(e,"modelValue",e.modelValue,b=>new Set(An(b).map(k=>{var C;return((C=n.value.find(_=>e.valueComparator(k,_.value)))==null?void 0:C.value)??k})),b=>[...b.values()]),i=A(()=>n.value.filter(b=>b.selectable)),o=A(()=>r.value.filter(b=>b.selectable)),a=A(()=>{if(typeof e.selectStrategy=="object")return e.selectStrategy;switch(e.selectStrategy){case"single":return pJ;case"all":return jM;case"page":default:return HM}}),l=Ie(null);function u(b){return An(b).every(k=>s.value.has(k.value))}function c(b){return An(b).some(k=>s.value.has(k.value))}function d(b,k){const C=a.value.select({items:b,value:k,selected:new Set(s.value)});s.value=C}function f(b,k,C){const _=[];if(k=k??r.value.findIndex(T=>T.value===b.value),e.selectStrategy!=="single"&&(C!=null&&C.shiftKey)&&l.value!==null){const[T,P]=[l.value,k].sort((S,E)=>S-E);_.push(...r.value.slice(T,P+1).filter(S=>S.selectable))}else _.push(b),l.value=k;d(_,!u([b]))}function p(b){const k=a.value.selectAll({value:b,allItems:i.value,currentPage:o.value,selected:new Set(s.value)});s.value=k}const g=A(()=>s.value.size>0),m=A(()=>{const b=a.value.allSelected({allItems:i.value,currentPage:o.value});return!!b.length&&u(b)}),y=ae(()=>a.value.showSelectAll),w={toggleSelect:f,select:d,selectAll:p,isSelected:u,isSomeSelected:c,someSelected:g,allSelected:m,showSelectAll:y,lastSelectedIndex:l,selectStrategy:a};return Kt(qM,w),w}function Lm(){const e=Qe(qM);if(!e)throw new Error("Missing selection!");return e}const vJ=de({sortBy:{type:Array,default:()=>[]},customKeySort:Object,multiSort:Boolean,mustSort:Boolean},"DataTable-sort"),WM=Symbol.for("vuetify:data-table-sort");function yJ(e){const t=st(e,"sortBy"),n=ae(()=>e.mustSort),r=ae(()=>e.multiSort);return{sortBy:t,mustSort:n,multiSort:r}}function bJ(e){const{sortBy:t,mustSort:n,multiSort:r,page:s}=e,i=l=>{if(l.key==null)return;let u=t.value.map(d=>({...d}))??[];const c=u.find(d=>d.key===l.key);c?c.order==="desc"?n.value&&u.length===1?c.order="asc":u=u.filter(d=>d.key!==l.key):c.order="desc":r.value?u.push({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 Kt(WM,a),a}function GM(){const e=Qe(WM);if(!e)throw new Error("Missing sort!");return e}function wJ(e,t,n,r){const s=Gr();return{sortedItems:A(()=>{var o,a;return n.value.length?SJ(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 SJ(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 c=0;c<t.length;c++){let d=!1;const f=t[c].key,p=t[c].order??"asc";if(p===!1)continue;let g=Ba(o[1],f),m=Ba(a[1],f),y=o[0].raw,w=a[0].raw;if(p==="desc"&&([g,m]=[m,g],[y,w]=[w,y]),(l=r==null?void 0:r.sortRawFunctions)!=null&&l[f]){const b=r.sortRawFunctions[f](y,w);if(b==null)continue;if(d=!0,b)return b}if((u=r==null?void 0:r.sortFunctions)!=null&&u[f]){const b=r.sortFunctions[f](g,m);if(b==null)continue;if(d=!0,b)return b}if(!d){if(g instanceof Date&&m instanceof Date)return g.getTime()-m.getTime();if([g,m]=[g,m].map(b=>b!=null?b.toString().toLocaleLowerCase():b),g!==m)return tf(g)&&tf(m)?0:tf(g)?-1:tf(m)?1:!isNaN(g)&&!isNaN(m)?Number(g)-Number(m):s.compare(g,m)}}return 0}).map(o=>{let[a]=o;return a})}function _J(){const e=j([]);jC(()=>e.value=[]);function t(n,r){e.value[r]=n}return{refs:e,updateRef:t}}const kJ=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:He,default:"$first"},prevIcon:{type:He,default:"$prev"},nextIcon:{type:He,default:"$next"},lastIcon:{type:He,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(),...Ue(),...Ar(),...bs(),...Dn(),...Eu(),...yt({tag:"nav"}),...Lt(),...$s({variant:"text"})},"VPagination"),sx=ke()({name:"VPagination",props:kJ(),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}=Gr(),{isRtl:a}=Dr(),{themeClasses:l}=Zt(e),{width:u}=fi(),c=Ie(-1);Ir(void 0,{scoped:!0});const{resizeRef:d}=Va(S=>{if(!S.length)return;const{target:E,contentRect:I}=S[0],O=E.querySelector(".v-pagination__list > *");if(!O)return;const R=I.width,M=O.offsetWidth+parseFloat(getComputedStyle(O).marginRight)*2;c.value=m(R,M)}),f=A(()=>parseInt(e.length,10)),p=A(()=>parseInt(e.start,10)),g=A(()=>e.totalVisible!=null?parseInt(e.totalVisible,10):c.value>=0?c.value:m(u.value,58));function m(S,E){const I=e.showFirstLastPage?5:3;return Math.max(0,Math.floor(Number(((S-E*I)/E).toFixed(2))))}const y=A(()=>{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 xl(f.value,p.value);const S=g.value%2===0,E=S?g.value/2:Math.floor(g.value/2),I=S?E:E+1,O=f.value-E;if(I-s.value>=0)return[...xl(Math.max(1,g.value-1),p.value),e.ellipsis,f.value];if(s.value-O>=(S?1:0)){const R=g.value-1,M=f.value-R+p.value;return[p.value,e.ellipsis,...xl(R,M)]}else{const R=Math.max(1,g.value-2),M=R===1?s.value:s.value-Math.ceil(R/2)+p.value;return[p.value,e.ellipsis,...xl(R,M),e.ellipsis,f.value]}});function w(S,E,I){S.preventDefault(),s.value=E,I&&r(I,E)}const{refs:b,updateRef:k}=_J();Ir({VPaginationBtn:{color:ae(()=>e.color),border:ae(()=>e.border),density:ae(()=>e.density),size:ae(()=>e.size),variant:ae(()=>e.variant),rounded:ae(()=>e.rounded),elevation:ae(()=>e.elevation)}});const C=A(()=>y.value.map((S,E)=>{const I=O=>k(O,E);if(typeof S=="string")return{isActive:!1,key:`ellipsis-${E}`,page:S,props:{ref:I,ellipsis:!0,icon:!0,disabled:!0}};{const O=S===s.value;return{isActive:O,key:S,page:o(S),props:{ref:I,ellipsis:!1,icon:!0,disabled:!!e.disabled||Number(e.length)<2,color:O?e.activeColor:e.color,"aria-current":O,"aria-label":i(O?e.currentPageAriaLabel:e.pageAriaLabel,S),onClick:R=>w(R,S)}}}})),_=A(()=>{const S=!!e.disabled||s.value<=p.value,E=!!e.disabled||s.value>=p.value+f.value-1;return{first:e.showFirstLastPage?{icon:a.value?e.lastIcon:e.firstIcon,onClick:I=>w(I,p.value,"first"),disabled:S,"aria-label":i(e.firstAriaLabel),"aria-disabled":S}:void 0,prev:{icon:a.value?e.nextIcon:e.prevIcon,onClick:I=>w(I,s.value-1,"prev"),disabled:S,"aria-label":i(e.previousAriaLabel),"aria-disabled":S},next:{icon:a.value?e.prevIcon:e.nextIcon,onClick:I=>w(I,s.value+1,"next"),disabled:E,"aria-label":i(e.nextAriaLabel),"aria-disabled":E},last:e.showFirstLastPage?{icon:a.value?e.firstIcon:e.lastIcon,onClick:I=>w(I,p.value+f.value-1,"last"),disabled:E,"aria-label":i(e.lastAriaLabel),"aria-disabled":E}:void 0}});function T(){var E;const S=s.value-p.value;(E=b.value[S])==null||E.$el.focus()}function P(S){S.key===FS.left&&!e.disabled&&s.value>Number(e.start)?(s.value=s.value-1,Mt(T)):S.key===FS.right&&!e.disabled&&s.value<p.value+f.value-1&&(s.value=s.value+1,Mt(T))}return Oe(()=>h(e.tag,{ref:d,class:["v-pagination",l.value,e.class],style:e.style,role:"navigation","aria-label":i(e.ariaLabel),onKeydown:P,"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(_.value.first):h(se,ge({_as:"VPaginationBtn"},_.value.first),null)]),h("li",{key:"prev",class:"v-pagination__prev","data-test":"v-pagination-prev"},[n.prev?n.prev(_.value.prev):h(se,ge({_as:"VPaginationBtn"},_.value.prev),null)]),C.value.map((S,E)=>h("li",{key:S.key,class:["v-pagination__item",{"v-pagination__item--is-active":S.isActive}],"data-test":"v-pagination-item"},[n.item?n.item(S):h(se,ge({_as:"VPaginationBtn"},S.props),{default:()=>[S.page]})])),h("li",{key:"next",class:"v-pagination__next","data-test":"v-pagination-next"},[n.next?n.next(_.value.next):h(se,ge({_as:"VPaginationBtn"},_.value.next),null)]),e.showFirstLastPage&&h("li",{key:"last",class:"v-pagination__last","data-test":"v-pagination-last"},[n.last?n.last(_.value.last):h(se,ge({_as:"VPaginationBtn"},_.value.last),null)])])]})),{}}}),KM=de({prevIcon:{type:He,default:"$prev"},nextIcon:{type:He,default:"$next"},firstIcon:{type:He,default:"$first"},lastIcon:{type:He,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"),ix=ke()({name:"VDataTableFooter",props:KM(),setup(e,t){let{slots:n}=t;const{t:r}=Gr(),{page:s,pageCount:i,startIndex:o,stopIndex:a,itemsLength:l,itemsPerPage:u,setItemsPerPage:c}=fJ(),d=A(()=>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 Oe(()=>{var p;const f=sx.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($o,{items:d.value,modelValue:u.value,"onUpdate:modelValue":g=>c(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(sx,ge({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)])])}),{}}}),gp=yF({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)]}})}),xJ=de({headers:Array},"DataTable-header"),YM=Symbol.for("vuetify:data-table-headers"),XM={title:"",sortable:!1},EJ={...XM,width:48};function CJ(){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 pb(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)pb(n,t);return t}function QM(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&&QM(n.children,t);return t}function TJ(e){if(e.key){if(e.key==="data-table-group")return XM;if(["data-table-expand","data-table-select"].includes(e.key))return EJ}}function yw(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return e.children?Math.max(t,...e.children.map(n=>yw(n,t+1))):t}function PJ(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(Number(i.width))?(`${i.key}`,void 0):i.minWidth=Math.max(Number(i.width)||0,Number(i.minWidth)||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 RJ(e,t){const n=[];let r=0;const s=CJ(e);for(;s.size()>0;){let o=s.count();const a=[];let l=1;for(;o>0;){const{element:u,priority:c}=s.dequeue(),d=t-r-yw(u);if(a.push({...u,rowspan:d??1,colspan:u.children?pb(u).length:1}),u.children)for(const f of u.children){const p=c%1+l/Math.pow(10,r+2);s.enqueue(f,r+d+p)}l+=1,o-=1}r+=1,n.push(a)}return{columns:e.map(o=>pb(o)).flat(),headers:n}}function JM(e){const t=[];for(const n of e){const r={...TJ(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?JM(r.children):void 0};t.push(o)}return t}function IJ(e,t){const n=j([]),r=j([]),s=j({}),i=j({}),o=j({});On(()=>{var m,y,w;const u=(e.headers||Object.keys(e.items[0]??{}).map(b=>({key:b,title:ci(b)}))).slice(),c=QM(u);(m=t==null?void 0:t.groupBy)!=null&&m.value.length&&!c.has("data-table-group")&&u.unshift({key:"data-table-group",title:"Group"}),(y=t==null?void 0:t.showSelect)!=null&&y.value&&!c.has("data-table-select")&&u.unshift({key:"data-table-select"}),(w=t==null?void 0:t.showExpand)!=null&&w.value&&!c.has("data-table-expand")&&u.push({key:"data-table-expand"});const d=JM(u);PJ(d);const f=Math.max(...d.map(b=>yw(b)))+1,p=RJ(d,f);n.value=p.headers,r.value=p.columns;const g=p.headers.flat(1);for(const b of g)b.key&&(b.sortable&&(b.sort&&(s.value[b.key]=b.sort),b.sortRaw&&(i.value[b.key]=b.sortRaw)),b.filter&&(o.value[b.key]=b.filter))});const a={headers:n,columns:r,sortFunctions:s,sortRawFunctions:i,filterFunctions:o};return Kt(YM,a),a}function $m(){const e=Qe(YM);if(!e)throw new Error("Missing headers!");return e}const ZM=de({color:String,disableSort:Boolean,fixedHeader:Boolean,multiSort:Boolean,sortAscIcon:{type:He,default:"$sortAsc"},sortDescIcon:{type:He,default:"$sortDesc"},headerProps:{type:Object},sticky:Boolean,...tl(),...Gp()},"VDataTableHeaders"),ox=ke()({name:"VDataTableHeaders",props:ZM(),setup(e,t){let{slots:n}=t;const{t:r}=Gr(),{toggleSort:s,sortBy:i,isSorted:o}=GM(),{someSelected:a,allSelected:l,selectAll:u,showSelectAll:c}=Lm(),{columns:d,headers:f}=$m(),{loaderClasses:p}=Rd(e);function g(S,E){if(!(!(e.sticky||e.fixedHeader)&&!S.fixed))return{position:"sticky",left:S.fixed?Ne(S.fixedOffset):void 0,top:e.sticky||e.fixedHeader?`calc(var(--v-table-header-height) * ${E})`:void 0}}function m(S){const E=i.value.find(I=>I.key===S.key);return E?E.order==="asc"?e.sortAscIcon:e.sortDescIcon:e.sortAscIcon}const{backgroundColorClasses:y,backgroundColorStyles:w}=fr(()=>e.color),{displayClasses:b,mobile:k}=fi(e),C=A(()=>({headers:f.value,columns:d.value,toggleSort:s,isSorted:o,sortBy:i.value,someSelected:a.value,allSelected:l.value,selectAll:u,getSortIcon:m})),_=A(()=>["v-data-table__th",{"v-data-table__th--sticky":e.sticky||e.fixedHeader},b.value,p.value]),T=S=>{let{column:E,x:I,y:O}=S;const R=E.key==="data-table-select"||E.key==="data-table-expand",M=ge(e.headerProps??{},E.headerProps??{});return h(gp,ge({tag:"th",align:E.align,class:[{"v-data-table__th--sortable":E.sortable&&!e.disableSort,"v-data-table__th--sorted":o(E),"v-data-table__th--fixed":E.fixed},..._.value],style:{width:Ne(E.width),minWidth:Ne(E.minWidth),maxWidth:Ne(E.maxWidth),...g(E,O)},colspan:E.colspan,rowspan:E.rowspan,onClick:E.sortable?()=>s(E):void 0,fixed:E.fixed,nowrap:E.nowrap,lastFixed:E.lastFixed,noPadding:R},M),{default:()=>{var U;const D=`header.${E.key}`,F={column:E,selectAll:u,isSorted:o,toggleSort:s,sortBy:i.value,someSelected:a.value,allSelected:l.value,getSortIcon:m};return n[D]?n[D](F):E.key==="data-table-select"?((U=n["header.data-table-select"])==null?void 0:U.call(n,F))??(c.value&&h(gu,{modelValue:l.value,indeterminate:a.value&&!l.value,"onUpdate:modelValue":u},null)):h("div",{class:"v-data-table-header__content"},[h("span",null,[E.title]),E.sortable&&!e.disableSort&&h(J,{key:"icon",class:"v-data-table-header__sort-icon",icon:m(E)},null),e.multiSort&&o(E)&&h("div",{key:"badge",class:["v-data-table-header__sort-badge",...y.value],style:w.value},[i.value.findIndex(K=>K.key===E.key)+1])])}})},P=()=>{const S=A(()=>d.value.filter(I=>(I==null?void 0:I.sortable)&&!e.disableSort)),E=A(()=>{if(d.value.find(O=>O.key==="data-table-select")!=null)return l.value?"$checkboxOn":a.value?"$checkboxIndeterminate":"$checkboxOff"});return h(gp,ge({tag:"th",class:[..._.value],colspan:f.value.length+1},e.headerProps),{default:()=>[h("div",{class:"v-data-table-header__content"},[h($o,{chips:!0,class:"v-data-table__td-sort-select",clearable:!0,density:"default",items:S.value,label:r("$vuetify.dataTable.sortBy"),multiple:e.multiSort,variant:"underlined","onClick:clear":()=>i.value=[],appendIcon:E.value,"onClick:append":()=>u(!l.value)},{...n,chip:I=>{var O;return h(_n,{onClick:(O=I.item.raw)!=null&&O.sortable?()=>s(I.item.raw):void 0,onMousedown:R=>{R.preventDefault(),R.stopPropagation()}},{default:()=>[I.item.title,h(J,{class:["v-data-table__td-sort-icon",o(I.item.raw)&&"v-data-table__td-sort-icon-active"],icon:m(I.item.raw),size:"small"},null)]})}})])]})};Oe(()=>k.value?h("tr",null,[h(P,null,null)]):h(Ae,null,[n.headers?n.headers(C.value):f.value.map((S,E)=>h("tr",null,[S.map((I,O)=>h(T,{column:I,x:O,y:E},null))])),e.loading&&h("tr",{class:"v-data-table-progress"},[h("th",{colspan:d.value.length},[h(Kp,{name:"v-data-table-progress",absolute:!0,active:!0,color:typeof e.loading=="boolean"?void 0:e.loading,indeterminate:!0},{default:n.loader})])])]))}}),AJ=de({item:{type:Object,required:!0}},"VDataTableGroupHeaderRow"),OJ=ke()({name:"VDataTableGroupHeaderRow",props:AJ(),setup(e,t){let{slots:n}=t;const{isGroupOpen:r,toggleGroup:s,extractRows:i}=BM(),{isSelected:o,isSomeSelected:a,select:l}=Lm(),{columns:u}=$m(),c=A(()=>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(d=>{var f,p;if(d.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:c.value.length,props:{icon:g,onClick:m}}))??h(gp,{class:"v-data-table-group-header-row__column"},{default:()=>[h(se,{size:"small",variant:"text",icon:g,onClick:m},null),h("span",null,[e.item.value]),h("span",null,[x("("),c.value.length,x(")")])]})}if(d.key==="data-table-select"){const g=o(c.value),m=a(c.value)&&!g,y=w=>l(c.value,w);return((p=n["data-table-select"])==null?void 0:p.call(n,{props:{modelValue:g,indeterminate:m,"onUpdate:modelValue":y}}))??h("td",null,[h(gu,{modelValue:g,indeterminate:m,"onUpdate:modelValue":y},null)])}return h("td",null,null)})])}}),MJ=de({index:Number,item:Object,cellProps:[Object,Function],onClick:Bn(),onContextmenu:Bn(),onDblclick:Bn(),...tl()},"VDataTableRow"),DJ=ke()({name:"VDataTableRow",props:MJ(),setup(e,t){let{slots:n}=t;const{displayClasses:r,mobile:s}=fi(e,"v-data-table__tr"),{isSelected:i,toggleSelect:o,someSelected:a,allSelected:l,selectAll:u}=Lm(),{isExpanded:c,toggleExpand:d}=FM(),{toggleSort:f,sortBy:p,isSorted:g}=GM(),{columns:m}=$m();Oe(()=>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,w)=>{const b=e.item,k=`item.${y.key}`,C=`header.${y.key}`,_={index:e.index,item:b.raw,internalItem:b,value:Ba(b.columns,y.key),column:y,isSelected:i,toggleSelect:o,isExpanded:c,toggleExpand:d},T={column:y,selectAll:u,isSorted:g,toggleSort:f,sortBy:p.value,someSelected:a.value,allSelected:l.value,getSortIcon:()=>""},P=typeof e.cellProps=="function"?e.cellProps({index:_.index,item:_.item,internalItem:_.internalItem,value:_.value,column:y}):e.cellProps,S=typeof y.cellProps=="function"?y.cellProps({index:_.index,item:_.item,internalItem:_.internalItem,value:_.value}):y.cellProps;return h(gp,ge({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},P,S),{default:()=>{var I,O,R,M;if(y.key==="data-table-select")return((I=n["item.data-table-select"])==null?void 0:I.call(n,{..._,props:{disabled:!b.selectable,modelValue:i([b]),onClick:_t(()=>o(b),["stop"])}}))??h(gu,{disabled:!b.selectable,modelValue:i([b]),onClick:_t(D=>o(b,e.index,D),["stop"])},null);if(y.key==="data-table-expand")return((O=n["item.data-table-expand"])==null?void 0:O.call(n,{..._,props:{icon:c(b)?"$collapse":"$expand",size:"small",variant:"text",onClick:_t(()=>d(b),["stop"])}}))??h(se,{icon:c(b)?"$collapse":"$expand",size:"small",variant:"text",onClick:_t(()=>d(b),["stop"])},null);if(n[k]&&!s.value)return n[k](_);const E=re(_.value);return s.value?h(Ae,null,[h("div",{class:"v-data-table__td-title"},[((R=n[C])==null?void 0:R.call(n,T))??y.title]),h("div",{class:"v-data-table__td-value"},[((M=n[k])==null?void 0:M.call(n,_))??E])]):E}})})]))}}),e2=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],...tl()},"VDataTableRows"),ax=ke()({name:"VDataTableRows",inheritAttrs:!1,props:e2(),setup(e,t){let{attrs:n,slots:r}=t;const{columns:s}=$m(),{expandOnClick:i,toggleExpand:o,isExpanded:a}=FM(),{isSelected:l,toggleSelect:u}=Lm(),{toggleGroup:c,isGroupOpen:d}=BM(),{t:f}=Gr(),{mobile:p}=fi(e);return Oe(()=>{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(Ae,null,[e.items.map((y,w)=>{var C;if(y.type==="group"){const _={index:w,item:y,columns:s.value,isExpanded:a,toggleExpand:o,isSelected:l,toggleSelect:u,toggleGroup:c,isGroupOpen:d};return r["group-header"]?r["group-header"](_):h(OJ,ge({key:`group-header_${y.id}`,item:y},n1(n,":group-header",()=>_)),r)}const b={index:w,item:y.raw,internalItem:y,columns:s.value,isExpanded:a,toggleExpand:o,isSelected:l,toggleSelect:u},k={...b,props:ge({key:`item_${y.key??y.index}`,onClick:i.value?()=>{o(y)}:void 0,index:w,item:y,cellProps:e.cellProps,mobile:p.value},n1(n,":row",()=>b),typeof e.rowProps=="function"?e.rowProps({item:b.item,index:b.index,internalItem:b.internalItem}):e.rowProps)};return h(Ae,{key:k.props.key},[r.item?r.item(k):h(DJ,k.props,r),a(y)&&((C=r["expanded-row"])==null?void 0:C.call(r,b))])})])}),{}}}),t2=de({fixedHeader:Boolean,fixedFooter:Boolean,height:[Number,String],hover:Boolean,...Ue(),...Ar(),...yt(),...Lt()},"VTable"),mb=ke()({name:"VTable",props:t2(),setup(e,t){let{slots:n,emit:r}=t;const{themeClasses:s}=Zt(e),{densityClasses:i}=ys(e);return Oe(()=>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)]}})),{}}}),LJ=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 $J(e,t,n,r){const s=e.returnObject?t:Fn(t,e.itemValue),i=Fn(t,e.itemSelectable,!0),o=r.reduce((a,l)=>(l.key!=null&&(a[l.key]=Fn(t,l.value)),a),{});return{type:"item",key:e.returnObject?Fn(t,e.itemValue):s,index:n,value:s,selectable:i,columns:o,raw:t}}function FJ(e,t,n){return t.map((r,s)=>$J(e,r,s,n))}function NJ(e,t){return{items:A(()=>FJ(e,e.items,t.value))}}const BJ=de({...e2(),hideDefaultBody:Boolean,hideDefaultFooter:Boolean,hideDefaultHeader:Boolean,width:[String,Number],search:String,...tJ(),...rJ(),...xJ(),...LJ(),...mJ(),...vJ(),...ZM(),...t2()},"DataTable"),VJ=de({...uJ(),...BJ(),...JQ(),...KM()},"VDataTable"),UJ=ke()({name:"VDataTable",props:VJ(),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}=sJ(e),{sortBy:i,multiSort:o,mustSort:a}=yJ(e),{page:l,itemsPerPage:u}=cJ(e),{disableSort:c}=Qa(e),{columns:d,headers:f,sortFunctions:p,sortRawFunctions:g,filterFunctions:m}=IJ(e,{groupBy:s,showSelect:ae(()=>e.showSelect),showExpand:ae(()=>e.showExpand)}),{items:y}=NJ(e,d),w=ae(()=>e.search),{filteredItems:b}=eJ(e,y,w,{transform:Z=>Z.columns,customKeyFilter:m}),{toggleSort:k}=bJ({sortBy:i,multiSort:o,mustSort:a,page:l}),{sortByWithGroups:C,opened:_,extractRows:T,isGroupOpen:P,toggleGroup:S}=iJ({groupBy:s,sortBy:i,disableSort:c}),{sortedItems:E}=wJ(e,b,C,{transform:Z=>({...Z.raw,...Z.columns}),sortFunctions:p,sortRawFunctions:g}),{flatItems:I}=aJ(E,s,_),O=A(()=>I.value.length),{startIndex:R,stopIndex:M,pageCount:D,setItemsPerPage:F}=dJ({page:l,itemsPerPage:u,itemsLength:O}),{paginatedItems:U}=hJ({items:I,startIndex:R,stopIndex:M,itemsPerPage:u}),K=A(()=>T(U.value)),{isSelected:X,select:H,selectAll:B,toggleSelect:ee,someSelected:q,allSelected:G}=gJ(e,{allItems:y,currentPage:K}),{isExpanded:le,toggleExpand:ie}=nJ(e);lJ({page:l,itemsPerPage:u,sortBy:i,groupBy:s,search:w}),Ir({VDataTableRows:{hideNoData:ae(()=>e.hideNoData),noDataText:ae(()=>e.noDataText),loading:ae(()=>e.loading),loadingText:ae(()=>e.loadingText)}});const Se=A(()=>({page:l.value,itemsPerPage:u.value,sortBy:i.value,pageCount:D.value,toggleSort:k,setItemsPerPage:F,someSelected:q.value,allSelected:G.value,isSelected:X,select:H,selectAll:B,toggleSelect:ee,isExpanded:le,toggleExpand:ie,isGroupOpen:P,toggleGroup:S,items:K.value.map(Z=>Z.raw),internalItems:K.value,groupedItems:U.value,columns:d.value,headers:f.value}));return Oe(()=>{const Z=ix.filterProps(e),he=ox.filterProps(e),ne=ax.filterProps(e),z=mb.filterProps(e);return h(mb,ge({class:["v-data-table",{"v-data-table--show-select":e.showSelect,"v-data-table--loading":e.loading},e.class],style:e.style},z,{fixedHeader:e.fixedHeader||e.sticky}),{top:()=>{var xe;return(xe=r.top)==null?void 0:xe.call(r,Se.value)},default:()=>{var xe,Fe,N,V,Y,fe;return r.default?r.default(Se.value):h(Ae,null,[(xe=r.colgroup)==null?void 0:xe.call(r,Se.value),!e.hideDefaultHeader&&h("thead",{key:"thead"},[h(ox,he,r)]),(Fe=r.thead)==null?void 0:Fe.call(r,Se.value),!e.hideDefaultBody&&h("tbody",null,[(N=r["body.prepend"])==null?void 0:N.call(r,Se.value),r.body?r.body(Se.value):h(ax,ge(n,ne,{items:U.value}),r),(V=r["body.append"])==null?void 0:V.call(r,Se.value)]),(Y=r.tbody)==null?void 0:Y.call(r,Se.value),(fe=r.tfoot)==null?void 0:fe.call(r,Se.value)])},bottom:()=>r.bottom?r.bottom(Se.value):!e.hideDefaultFooter&&h(Ae,null,[h(dn,null,null),h(ix,Z,{prepend:r["footer.prepend"]})])})}),{}}}),zJ=de({...Ue(),...B7()},"VForm"),bw=ke()({name:"VForm",props:zJ(),emits:{"update:modelValue":e=>!0,submit:e=>!0},setup(e,t){let{slots:n,emit:r}=t;const s=V7(e),i=j();function o(l){l.preventDefault(),s.reset()}function a(l){const u=l,c=s.validate();u.then=c.then.bind(c),u.catch=c.catch.bind(c),u.finally=c.finally.bind(c),r("submit",u),u.defaultPrevented||c.then(d=>{var p;let{valid:f}=d;f&&((p=i.value)==null||p.submit())}),u.preventDefault()}return Oe(()=>{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)])}),Xi(s,i)}}),HJ=de({disabled:Boolean,modelValue:{type:Boolean,default:null},...n0()},"VHover"),lx=ke()({name:"VHover",props:HJ(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const r=st(e,"modelValue"),{runOpenDelay:s,runCloseDelay:i}=r0(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}})}}}),jJ={class:"mt-4 mb-4"},qJ={key:0},WJ={key:1},GJ={key:0},KJ={key:1},YJ=["colspan"],XJ=Le({__name:"PrintersView",setup(e){const t=Dt(),n=Ft(),r=j(!1),s=nr(),i=Qi(),o=Em(),a=tn(nn.AddOrUpdatePrinterDialog),l=j([]),u=j([]),c=j(""),d=j(""),f=j(),p=j(""),g=j([]),m=A(()=>o.hasFeature("printerGroupsApi")),y=A(()=>[{title:"Enabled",key:"enabled"},{title:"Type",key:"printerType"},{title:"Printer Name",align:"start",sortable:!0,key:"name"},{title:"Floor",key:"floor",sortable:!1},...o.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 w(){return r.value=!0,await o.loadFeatures(),o.hasFeature("printerGroupsApi")&&(l.value=await pl.getGroupsWithPrinters()),r.value=!1,l}const b=Pm({queryKey:["printerGroups"],queryFn:w}),k=A(()=>{var G;if(!o.hasFeature("printerGroupsApi")||!((G=u.value)!=null&&G.length))return n.printers;const q=u.value.flatMap(le=>le.printers.map(ie=>ie.printerId))||[];return n.printers.filter(le=>q.includes(le.id))}),C=A(()=>s.printerCurrentEventReceivedAtById),_=A(()=>{if(!(!f.value&&f.value!==0))return l.value[f.value]}),T=q=>q?(Date.now()-q)/1e3:void 0,P=q=>l.value.filter(G=>G.printers.find(le=>le.printerId===q)),S=q=>l.value.filter(G=>!G.printers.find(le=>le.printerId===q)),E=q=>i.floorOfPrinter(q),I=q=>{n.setUpdateDialogPrinter(q),a.openDialog(q)},O=()=>{a.openDialog()},R=(q,G)=>{if(console.log(q,G),G.isExpanded){const le=g.value.findIndex(ie=>ie===q.id);g.value.splice(le,1)}else g.value.push(q.id.toString())},M=()=>{tn(nn.ImportOctoFarmDialog).openDialog()},D=()=>{tn(nn.YamlImportExport).openDialog()},F=async()=>{var q,G;if(!((G=(q=c.value)==null?void 0:q.trim())!=null&&G.length))throw new Error("Please set a non-empty group name");await pl.createGroup(c.value.trim()),await b.refetch(),c.value="",t.info("Created group")},U=()=>{var q;_.value&&(d.value=(q=_.value)==null?void 0:q.name)},K=async q=>{var le,ie;if(!(q!=null&&q.id))throw new Error("Group id was not defined");if(!l.value.find(Se=>Se.id===q.id))throw new Error("Group was not found, please reload the page");if(!((ie=(le=d.value)==null?void 0:le.trim())!=null&&ie.length))throw new Error("Please set a non-empty group name");await pl.updateGroupName(q.id,d.value.trim()),await b.refetch()},X=async q=>{const G=l.value.find(ie=>ie.id===q);if(!G)throw new Error("Group was not found, please reload the page");const le=G.printers.length;le>0&&!confirm(`This group contains ${le} printers, are you sure to delete it?`)||(await pl.deleteGroup(q),await b.refetch(),t.info("Deleted group"))},H=async(q,G)=>{await pl.addPrinterToGroup(q,G),await b.refetch(),t.info("Added printer to group")},B=async(q,G)=>{await pl.deletePrinterFromGroup(q,G),await b.refetch(),t.info("Removed printer from group")},ee=async q=>{if(!q.id)throw new Error("Printer ID not set, cant toggle enabled");q.enabled=!q.enabled,await Qt.toggleEnabled(q.id,q.enabled)};return(q,G)=>{const le=In("v-list-item-group");return $(),ve("div",null,[h(vt,null,{default:v(()=>[h(sn,null,{default:v(()=>[G[11]||(G[11]=x(" Printers ")),h(Sn),m.value&&l.value.length?($(),te($o,{key:0,modelValue:u.value,"onUpdate:modelValue":G[0]||(G[0]=ie=>u.value=ie),items:l.value,"return-object":!0,"item-title":"name",label:"Filter by groups",multiple:"",placeholder:"Select group to filter by","prepend-icon":"filter_list"},null,8,["modelValue","items"])):pe("",!0),h(at,{modelValue:p.value,"onUpdate:modelValue":G[1]||(G[1]=ie=>p.value=ie),class:"p-2",clearable:"",label:"Printer search","prepend-icon":"search","single-line":""},null,8,["modelValue"])]),_:1}),h(Q(UJ),{expanded:g.value,headers:y.value,items:k.value,search:p.value,class:"elevation-1","item-key":"id","show-expand":"","single-expand":"","onClick:row":R},qC({"no-data":v(()=>[L("div",jJ,[k.value.length===0?($(),ve("h3",qJ," No printer has been created yet. Create one here: ")):($(),ve("h3",WJ," No printer has been found. Adjust your filters or search criteria. ")),h(TM)])]),top:v(()=>[h(mr,{flat:""},{default:v(()=>[h(En,null,{default:v(()=>[x(" Showing "+re(k.value.length||0)+" printers ",1)]),_:1}),h(se,{class:"ml-3",type:"button",variant:"outlined",onClick:G[2]||(G[2]=ie=>M())},{default:v(()=>[h(J,null,{default:v(()=>G[12]||(G[12]=[x("publish")])),_:1}),G[13]||(G[13]=x(" Import OctoFarm Printers "))]),_:1}),h(se,{class:"ml-3",type:"button",variant:"outlined",onClick:G[3]||(G[3]=ie=>O())},{default:v(()=>[h(J,null,{default:v(()=>G[14]||(G[14]=[x("add")])),_:1}),G[15]||(G[15]=x(" Create Printer "))]),_:1}),h(se,{class:"ml-3",color:"primary",type:"button",onClick:G[4]||(G[4]=ie=>D())},{default:v(()=>[h(J,null,{default:v(()=>G[16]||(G[16]=[x("publish")])),_:1}),G[17]||(G[17]=x(" Import/Export YAML "))]),_:1}),h(Sn)]),_:1})]),"item.enabled":v(({item:ie})=>[h(mp,{modelValue:ie.enabled,"onUpdate:modelValue":Se=>ie.enabled=Se,color:"primary",inset:"",onClickCapture:_t(Se=>ee(ie),["stop"])},{default:v(()=>[x(re(ie.enabled),1)]),_:2},1032,["modelValue","onUpdate:modelValue","onClickCapture"])]),"item.printerType":v(({item:ie})=>[x(re(Q(Oc)(ie.printerType)),1)]),"item.name":v(({item:ie})=>[h(_n,null,{default:v(()=>[x(re(ie.name||ie.printerURL),1)]),_:2},1024)]),"item.floor":v(({item:ie})=>[ie.id?($(),te(_n,{key:0},{default:v(()=>{var Se;return[x(re((Se=E(ie.id))==null?void 0:Se.name),1)]}),_:2},1024)):pe("",!0)]),"item.actions":v(({item:ie})=>[h(zQ,{printer:ie},null,8,["printer"]),h(GQ,{printer:ie},null,8,["printer"]),h(KQ,{printer:ie},null,8,["printer"]),h(YQ,{printer:ie},null,8,["printer"]),h(XQ,{printer:ie},null,8,["printer"]),h(qQ,{printer:ie,"onUpdate:show":Se=>I(ie)},null,8,["printer","onUpdate:show"])]),"item.socketupdate":v(({item:ie})=>[C.value[ie.id]?($(),ve("span",GJ," Updated "+re(T(C.value[ie.id]))+" seconds ago ",1)):($(),ve("span",KJ," No update received (silence) "))]),"expanded-row":v(({item:ie,columns:Se})=>[L("td",{colspan:Se.length},[h(UQ,{printer:ie},null,8,["printer"])],8,YJ)]),_:2},[m.value?{name:"item.group",fn:v(({item:ie})=>[($(!0),ve(Ae,null,Gt(P(ie.id),Se=>($(),te(_n,{key:Se.id,class:"ml-2",closable:"",size:"small","onClick:close":Z=>B(Se.id,ie.id)},{default:v(()=>[x(re(Se.name),1)]),_:2},1032,["onClick:close"]))),128)),h(Tm,{"offset-y":""},{activator:v(({props:Se})=>[h(_n,ge({disabled:!l.value.length,class:"ml-2",size:"small"},Se),{default:v(()=>[h(J,{size:"small"},{default:v(()=>G[18]||(G[18]=[x("add")])),_:1})]),_:2},1040,["disabled"])]),default:v(()=>[h(Ut,{density:"compact",style:{border:"1px solid dimgray"}},{default:v(()=>[h(qr,null,{default:v(()=>G[19]||(G[19]=[x(" ADD TO GROUP")])),_:1}),h(le,null,{default:v(()=>[($(!0),ve(Ae,null,Gt(S(ie.id),(Se,Z)=>($(),te(Ve,{key:Z,onClick:he=>H(Se.id,ie.id)},{default:v(()=>[h(ft,null,{default:v(()=>[x(re(Se.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?($(),te(vt,{key:0,class:"mt-4"},{default:v(()=>[h(sn,null,{default:v(()=>G[20]||(G[20]=[x(" Printer Groups ")])),_:1}),h(en,null,{default:v(()=>[G[26]||(G[26]=L("h3",null,"Existing groups:",-1)),h(Un,null,{default:v(()=>[h(op,{modelValue:f.value,"onUpdate:modelValue":[G[5]||(G[5]=ie=>f.value=ie),G[6]||(G[6]=ie=>U())],column:"","selected-class":"primary--text"},{default:v(()=>[($(!0),ve(Ae,null,Gt(l.value,ie=>($(),te(_n,{key:ie.id,class:"mr-3",closable:"",size:"small","onClick:close":Se=>X(ie.id)},{default:v(()=>[x(re(ie.name),1)]),_:2},1032,["onClick:close"]))),128))]),_:1},8,["modelValue"])]),_:1}),G[27]||(G[27]=L("h3",{class:"mt-3"},"Update group name",-1)),h(Un,null,{default:v(()=>[_.value?pe("",!0):($(),te(fn,{key:0},{default:v(()=>G[21]||(G[21]=[x(" Select a group to update its name. ")])),_:1})),h(at,{modelValue:d.value,"onUpdate:modelValue":G[7]||(G[7]=ie=>d.value=ie),disabled:!_.value,label:"Group Name",placeholder:"Type group name here"},{default:v(()=>G[22]||(G[22]=[x(" Name ")])),_:1},8,["modelValue","disabled"]),h(se,{onClick:G[8]||(G[8]=ie=>K(_.value))},{default:v(()=>G[23]||(G[23]=[x(" Update name ")])),_:1})]),_:1}),G[28]||(G[28]=L("h3",{class:"mt-3"},"Add group",-1)),h(Un,null,{default:v(()=>[h(at,{modelValue:c.value,"onUpdate:modelValue":G[9]||(G[9]=ie=>c.value=ie),label:"Group Name",placeholder:"Type group name here"},{default:v(()=>G[24]||(G[24]=[x(" Name ")])),_:1},8,["modelValue"]),h(se,{onClick:G[10]||(G[10]=ie=>F())},{default:v(()=>G[25]||(G[25]=[x(" Create new group")])),_:1})]),_:1})]),_:1})]),_:1})):pe("",!0)])}}}),qs={grid:"grid",floors:"floors",octoprint:"octoprint",emergencyCommands:"emergencyCommands",users:"users",account:"account",serverProtection:"serverProtection",softwareUpgrade:"softwareUpgrade",diagnostics:"diagnostics",experimental:"experimental"},QJ={[qs.grid]:{title:"Grid",icon:"grid_on",path:"/settings/grid",divider:!1},[qs.floors]:{title:"Floors",icon:"house_siding",path:"/settings/floors",divider:!0},[qs.octoprint]:{title:"OctoPrint",icon:"image",path:"/settings/octoprint",divider:!1},[qs.emergencyCommands]:{title:"Emergency Commands",icon:"warning",path:"/settings/emergency-commands",divider:!0},[qs.users]:{title:"Users",icon:"group",path:"/settings/user-management",divider:!1},[qs.account]:{title:"Account",icon:"account_circle",path:"/settings/account",divider:!1},[qs.serverProtection]:{title:"Server Protection",icon:"security",path:"/settings/server-protection",divider:!0},[qs.softwareUpgrade]:{title:"Software Upgrade",icon:"upgrade",path:"/settings/software-upgrade",divider:!1},[qs.diagnostics]:{title:"Diagnostics",icon:"bug_report",path:"/settings/diagnostics",divider:!1},[qs.experimental]:{title:"Experimental",icon:"settings_applications",path:"/settings/experimental",divider:!1}},JJ=Le({__name:"SettingsView",setup(e){const t=j(QJ);return(n,r)=>{const s=In("router-view");return $(),ve("div",null,[h(rt,{"no-gutters":""},{default:v(()=>[h(K0,{permanent:!0},{default:v(()=>[h(Ve,null,{default:v(()=>[h(ft,{class:"text-h6"},{default:v(()=>r[0]||(r[0]=[x(" Settings ")])),_:1}),h(bt,null,{default:v(()=>r[1]||(r[1]=[x(" Adjust your FDM Monster ")])),_:1})]),_:1}),h(dn),h(Ut,{density:"compact",nav:""},{default:v(()=>[($(!0),ve(Ae,null,Gt(Q(t),i=>($(),te(Ve,{key:i.title,to:i.path,link:"","prepend-icon":i.icon,title:i.title,"router-link":"",style:is(i.divider?"border-bottom: 1px solid gray":"")},null,8,["to","prepend-icon","title","style"]))),128))]),_:1})]),_:1}),h(ze,null,{default:v(()=>[h(s)]),_:1})]),_:1})])}}});function ZJ(e){const t=new Date(e);return new Intl.DateTimeFormat("default",{dateStyle:"long"}).format(t)}const eZ={key:0,class:"text--primary float-end mr-5 mt-2"},tZ={class:"text-grey-darken-4"},nZ={key:0,class:"text-success"},rZ={key:1,class:"text-error"},sZ={key:0},iZ={key:0},oZ={key:0},aZ={key:1},lZ={key:0},uZ={key:1},cZ=Le({__name:"UserManagementSettings",setup(e){const t=Dt(),n=j(!1),r=j(),s=j([]),i=j([]);async function o(){n.value=!0;try{r.value=await ts.getProfile(),i.value=await ts.listRoles(),s.value=await ts.listUsers()}catch(m){throw n.value=!1,console.error(m),m}return n.value=!1,{users:s,roles:i,profile:r}}const a=Pm({queryKey:["userRolesProfile"],queryFn:o});function l(m){return m.map(y=>{var w;return(w=i.value.find(b=>b.id==y))==null?void 0:w.name})}function u(m){var y;return m.id==((y=r.value)==null?void 0:y.id)}async function c(m){if(confirm(`Are you sure you want to delete ${m.username}?`)){try{n.value=!0,await ts.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 d(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 ts.setUserVerified(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} verified`:`User ${m.username} unverified`)}}async function f(m,y=!0){var w;if((w=r.value)!=null&&w.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 ts.setRootUser(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} 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 ts.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 tn(nn.CreateUserDialog).openDialog()}return(m,y)=>{const w=In("v-list-item-content");return $(),te(vt,null,{default:v(()=>[h(mr,{color:"primary"},{default:v(()=>{var b;return[h(ut,null,{default:v(()=>[h(J,null,{default:v(()=>y[1]||(y[1]=[x("settings")])),_:1})]),_:1}),h(En,null,{default:v(()=>y[2]||(y[2]=[x(" Users ")])),_:1}),h(Sn),h(se,{disabled:!((b=r.value)!=null&&b.isRootUser),class:"mt-2",color:"primary",onClick:y[0]||(y[0]=k=>g())},{default:v(()=>[h(J,{class:"mr-2"},{default:v(()=>y[3]||(y[3]=[x("verified_user")])),_:1}),y[4]||(y[4]=L("span",null,"Create verified user",-1))]),_:1},8,["disabled"])]}),_:1}),n.value?($(),te(EM,{key:0,size:20,color:"#a70015",style:{margin:"250px",position:"absolute"}})):pe("",!0),h(Ut,{lines:"three"},{default:v(()=>[h(qr,null,{default:v(()=>y[5]||(y[5]=[x(" Showing all users ")])),_:1}),($(!0),ve(Ae,null,Gt(s.value,(b,k)=>($(),te(Ve,{key:k,class:"pl-6",style:{"max-width":"800px","border-top":"1px solid grey","border-bottom":"1px solid grey"}},{default:v(()=>[h(w,{class:Bo(u(b)?"pl-6 grey darken-3":"pl-6 grey darken-4")},{default:v(()=>[h(ft,null,{default:v(()=>[x(" User '"+re(b.username)+"' ",1),u(b)?($(),ve("strong",eZ," Your account ")):pe("",!0)]),_:2},1024),h(bt),L("span",tZ,[L("ul",null,[L("li",null,[b.isVerified?($(),ve("span",nZ," Account verified ")):($(),ve("span",rZ," Account not verified "))]),L("li",null,"Created at "+re(Q(ZJ)(b.createdAt)),1),b.isDemoUser?($(),ve("li",sZ,"Demo user account")):pe("",!0),L("li",null,[y[7]||(y[7]=x(" Role(s) ")),L("ul",null,[b.isRootUser?($(),ve("li",iZ,[h(_n,{class:"mb-2 mt-2",size:"small"},{default:v(()=>y[6]||(y[6]=[x(" OWNER ")])),_:1})])):pe("",!0),($(!0),ve(Ae,null,Gt(l(b.roles),C=>($(),ve("li",{key:C},[h(_n,{class:"mb-2 mt-2",size:"small"},{default:v(()=>[x(re(C),1)]),_:2},1024)]))),128))])])])])]),_:2},1032,["class"]),h(pu,null,{default:v(()=>{var C,_;return[h(se,{disabled:u(b)||b.isRootUser,color:b.isVerified?"error darken-4":"success",onClick:T=>d(b,!b.isVerified)},{default:v(()=>[h(J,{class:"mr-2"},{default:v(()=>y[8]||(y[8]=[x("shield")])),_:1}),b.isVerified?pe("",!0):($(),ve("span",oZ," Verify account ")),b.isVerified?($(),ve("span",aZ," Un-verify account ")):pe("",!0)]),_:2},1032,["disabled","color","onClick"]),h(se,{color:b.isRootUser?"error darken-4":"success",disabled:u(b)||!((C=r.value)!=null&&C.isRootUser),class:"mt-2",onClick:T=>f(b,!b.isRootUser)},{default:v(()=>[h(J,{class:"mr-2"},{default:v(()=>y[9]||(y[9]=[x("key")])),_:1}),b.isRootUser?($(),ve("span",lZ," Remove owner ")):pe("",!0),b.isRootUser?pe("",!0):($(),ve("span",uZ," Set owner "))]),_:2},1032,["color","disabled","onClick"]),(_=r.value)!=null&&_.isRootUser?($(),te($o,{key:0,items:i.value.map(T=>({text:T.name,value:T.id})),modelValue:b.roles,"onUpdate:modelValue":T=>b.roles=T,multiple:"",label:"Select roles",onChange:T=>p(b),class:"pt-6",style:{width:"15rem"}},null,8,["items","modelValue","onUpdate:modelValue","onChange"])):pe("",!0),h(se,{disabled:u(b)||b.isRootUser,class:"mt-2",color:"error-darken-2",onClick:T=>c(b)},{default:v(()=>[h(J,{class:"mr-2"},{default:v(()=>y[10]||(y[10]=[x("delete")])),_:1}),y[11]||(y[11]=x(" Delete "))]),_:2},1032,["disabled","onClick"])]}),_:2},1024)]),_:2},1024))),128))]),_:1})]),_:1})}}}),dZ=Le({name:"FdmSettings",props:{},setup:()=>({settingsStore:Ns(),printersStore:Ft(),snackbar:Dt(),printerStateStore:nr()}),data:()=>({fileHandlingSettings:{autoRemoveOldFilesBeforeUpload:!1,autoRemoveOldFilesAtBoot:!1,autoRemoveOldFilesCriteriumDays:7}}),computed:{},watch:{},async created(){const e=await bn.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 bn.setFileCleanSettings(this.fileHandlingSettings);this.fileHandlingSettings=e.printerFileClean},async purgeFiles(){await $i.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 LM.setGCodeAnalysis(t.id,!1);this.snackbar.openInfoMessage({title:`Finished disabling gcode analysis for ${e.length} online printers.`})}}});function fZ(e,t,n,r,s,i){return $(),te(vt,null,{default:v(()=>[h(mr,{color:"primary"},{default:v(()=>[h(ut,null,{default:v(()=>[h(J,null,{default:v(()=>t[8]||(t[8]=[x("settings")])),_:1})]),_:1}),h(En,null,{default:v(()=>t[9]||(t[9]=[x(" OctoPrint Settings ")])),_:1})]),_:1}),h(Ut,{lines:"three"},{default:v(()=>[h(Ve,null,{default:v(()=>[h(ft,null,{default:v(()=>t[10]||(t[10]=[x(" Pre-upload file cleanup ")])),_:1}),h(bt,null,{default:v(()=>[t[12]||(t[12]=x(" Automatically cleanup old files to ensure the SD card has enough space. ")),t[13]||(t[13]=L("br",null,null,-1)),h(mn,{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(at,{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(mn,{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(se,{color:"primary",onClick:t[3]||(t[3]=o=>e.setFileCleanSettings())},{default:v(()=>t[11]||(t[11]=[x(" save file clean settings ")])),_:1})]),_:1})]),_:1}),h(Ve,null,{default:v(()=>{var o;return[h(ft,null,{default:v(()=>t[14]||(t[14]=[x(" Connection Timeout ")])),_:1}),(o=e.settingsStore.settings)!=null&&o.timeout?($(),te(bt,{key:0},{default:v(()=>[t[16]||(t[16]=x(" The connection timeout is the amount of time in milliseconds that the server will wait for OctoPrint to respond before giving up ")),h(at,{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(se,{color:"primary",onClick:t[5]||(t[5]=a=>e.updateTimeoutSettings())},{default:v(()=>t[15]||(t[15]=[x(" save connection timeout ")])),_:1})]),_:1})):pe("",!0)]}),_:1}),h(Ve,null,{default:v(()=>[h(ft,null,{default:v(()=>t[17]||(t[17]=[x(" Clean file references ")])),_:1}),h(bt,null,{default:v(()=>[t[19]||(t[19]=x(" 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(se,{color:"primary",onClick:t[6]||(t[6]=o=>e.purgeFiles())},{default:v(()=>t[18]||(t[18]=[x(" Purge file references ")])),_:1})]),_:1})]),_:1}),h(Ve,null,{default:v(()=>[h(ft,null,{default:v(()=>t[21]||(t[21]=[x(" Disable inefficient GCode analysis ")])),_:1}),h(bt,null,{default:v(()=>[t[23]||(t[23]=x(" 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(se,{color:"primary",onClick:t[7]||(t[7]=o=>e.bulkDisableGCodeAnalysis())},{default:v(()=>t[22]||(t[22]=[x(" Bulk disable GCode Analysis ")])),_:1})]),_:1})]),_:1})]),_:1})]),_:1})}const hZ=Ko(dZ,[["render",fZ]]),n2=Le({__name:"SettingsToolbar",props:["icon","title"],setup(e){const t=e;return(n,r)=>($(),te(mr,null,{default:v(()=>[h(ut,null,{default:v(()=>[h(J,null,{default:v(()=>[x(re(t.icon),1)]),_:1})]),_:1}),h(En,null,{default:v(()=>[x(re(t.title),1)]),_:1}),Vp(n.$slots,"default")]),_:3}))}}),pZ=Le({name:"FloorSettings",props:{},setup:()=>({printersStore:Ft(),floorStore:Qi(),addOrUpdateFloorDialog:tn(nn.AddOrUpdateFloorDialog),snackbar:Dt()}),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}},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(){await this.addOrUpdateFloorDialog.openDialog()},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"))}}}),mZ={key:1};function gZ(e,t,n,r,s,i){const o=n2,a=In("v-list-item-action-text"),l=In("v-list-item-group"),u=In("v-edit-dialog"),c=In("v-list-item-content");return $(),te(vt,null,{default:v(()=>[h(o,{icon:"house_siding",title:"Floors"}),h(Ut,{subheader:"",lines:"three"},{default:v(()=>[h(qr,null,{default:v(()=>t[7]||(t[7]=[x("Floors")])),_:1}),h(Ve,null,{default:v(()=>[h(ft,null,{default:v(()=>t[8]||(t[8]=[x(" Create new floor ")])),_:1}),h(bt,null,{default:v(()=>[t[10]||(t[10]=x(" Creates an empty department/floor to view printer groups ")),t[11]||(t[11]=L("br",null,null,-1)),h(se,{color:"primary",onClick:t[0]||(t[0]=d=>e.createFloor())},{default:v(()=>t[9]||(t[9]=[x(" Create floor ")])),_:1})]),_:1})]),_:1})]),_:1}),h(dn),h(rt,{"no-gutters":""},{default:v(()=>[h(ze,null,{default:v(()=>[h(Ut,{density:"compact"},{default:v(()=>[h(l,{modelValue:e.selectedItem,"onUpdate:modelValue":t[1]||(t[1]=d=>e.selectedItem=d)},{default:v(()=>[($(!0),ve(Ae,null,Gt(e.floors,d=>($(),te(Ve,{key:d.id},{default:v(()=>[h(ft,null,{default:v(()=>[x(re(d.name),1)]),_:2},1024),h(bt,null,{default:v(()=>[x(re(d.printers.length||0)+" assigned ",1)]),_:2},1024),h(a,null,{default:v(()=>[x(" Floor number: "+re(d.floor),1)]),_:2},1024)]),_:2},1024))),128))]),_:1},8,["modelValue"])]),_:1})]),_:1}),h(ze,null,{default:v(()=>[h(mr,null,{default:v(()=>[h(lx,null,{default:v(({isHovering:d,props:f})=>[h(En,yv(Rh(f)),{default:v(()=>[e.selectedFloor?($(),te(u,{key:0,onOpen:e.setEditedPrinterFloorName,onSave:e.updatePrinterFloorName},{input:v(()=>[h(at,{modelValue:e.editedFloorName,"onUpdate:modelValue":t[2]||(t[2]=p=>e.editedFloorName=p),"return-value":e.editedFloorName,"onUpdate:returnValue":t[3]||(t[3]=p=>e.editedFloorName=p),counter:"",label:"Edit","single-line":""},null,8,["modelValue","return-value"])]),default:v(()=>[h(se,{color:"secondary"},{default:v(()=>[d?($(),te(J,{key:0,size:"small"},{default:v(()=>t[12]||(t[12]=[x(" edit ")])),_:1})):pe("",!0),x(" "+re(e.selectedFloor.name),1)]),_:2},1024)]),_:2},1032,["onOpen","onSave"])):($(),ve("span",mZ," Select a floor on the left "))]),_:2},1040)]),_:1}),h(lx,null,{default:v(({isHovering:d,props:f})=>[h(En,yv(Rh(f)),{default:v(()=>[e.selectedFloor?($(),te(u,{key:0,onOpen:e.setEditedPrinterFloorNumber,onSave:e.updatePrinterFloorNumber},{input:v(()=>[h(at,{modelValue:e.editedFloorNumber,"onUpdate:modelValue":t[4]||(t[4]=p=>e.editedFloorNumber=p),"return-value":e.editedFloorNumber,"onUpdate:returnValue":t[5]||(t[5]=p=>e.editedFloorNumber=p),label:"Edit","single-line":"",type:"number"},null,8,["modelValue","return-value"])]),default:v(()=>[h(se,{color:"secondary"},{default:v(()=>[d?($(),te(J,{key:0,size:"small"},{default:v(()=>t[13]||(t[13]=[x(" edit ")])),_:1})):pe("",!0),x(" "+re(e.selectedFloor.floor),1)]),_:2},1024)]),_:2},1032,["onOpen","onSave"])):pe("",!0)]),_:2},1040)]),_:1}),h(Sn),e.selectedFloor?($(),te(se,{key:0,color:"primary",onClick:t[6]||(t[6]=d=>e.clickDeleteFloor())},{default:v(()=>[h(J,null,{default:v(()=>t[14]||(t[14]=[x("delete")])),_:1}),t[15]||(t[15]=x(" Delete floor "))]),_:1})):pe("",!0)]),_:1}),e.selectedFloor?($(),te(Ut,{key:0},{default:v(()=>[($(!0),ve(Ae,null,Gt(e.showAddedPrinters,d=>($(),te(Ve,{key:d},{default:v(()=>[e.printerInFloor(e.selectedFloor,d)?($(),te(c,{key:0},{default:v(()=>[h(ft,null,{default:v(()=>{var f;return[x(re((f=e.printerInFloor(e.selectedFloor,d))==null?void 0:f.name),1)]}),_:2},1024)]),_:2},1024)):pe("",!0),e.printerInFloor(e.selectedFloor,d)?($(),te(pu,{key:1},{default:v(()=>[h(se,{onClick:f=>e.deletePrinterFromFloor(e.selectedFloor,d)},{default:v(()=>[h(J,null,{default:v(()=>t[16]||(t[16]=[x("close")])),_:1}),t[17]||(t[17]=x(" Clear "))]),_:2},1032,["onClick"])]),_:2},1024)):pe("",!0)]),_:2},1024))),128))]),_:1})):pe("",!0)]),_:1})]),_:1})]),_:1})}const vZ=Ko(pZ,[["render",gZ]]),yZ="/img/DavidZwart.jpg",r2="0.0.20",bZ={key:0},wZ={key:1},SZ=Le({__name:"AboutView",setup(e){const t=j(""),n=j(""),r=j(r2);return St(async()=>{const s=await ma.getVersion();t.value=s.version,n.value=s.monsterPi}),(s,i)=>($(),te(vt,null,{default:v(()=>[h(sn,null,{default:v(()=>i[0]||(i[0]=[x(" About FDM Monster"),L("strong",null," © ",-1)])),_:1}),h(en,null,{default:v(()=>i[1]||(i[1]=[x(" The first prototype of FDM Monster"),L("strong",null," © ",-1),x(" was created by David Zwart in 2021 in collaboration with "),L("strong",null,[L("a",{href:"https://mtb3d.com"}," MTB3D ")],-1),x(". 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(en,null,{default:v(()=>[i[4]||(i[4]=x(" 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]=x(" 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]=x(" 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]=x(" and ")),i[11]||(i[11]=L("a",{href:"https://next.vuetifyjs.com/",target:"_blank"},[L("strong",null," Vuetify 2 ")],-1)),i[12]||(i[12]=x(" to set a base for FDM Monster Client")),i[13]||(i[13]=L("strong",null," © ",-1)),i[14]||(i[14]=x(" - 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: "+re(t.value),1),i[17]||(i[17]=L("br",null,null,-1)),L("strong",null," Your clients's version is: "+re(r.value),1),i[18]||(i[18]=L("br",null,null,-1)),n.value?($(),ve("strong",bZ,[x(" Your MonsterPi version is: "+re(n.value),1),i[2]||(i[2]=L("br",null,null,-1))])):($(),ve("strong",wZ," No MonsterPi distro detected. ")),i[19]||(i[19]=L("br",null,null,-1)),h(se,{class:"mt-3",variant:"outlined",to:"/settings/software-upgrade"},{default:v(()=>i[3]||(i[3]=[x(" Visit Upgrade Settings ")])),_:1})]),_:1}),h(sn,null,{default:v(()=>i[20]||(i[20]=[x(" Documentation ")])),_:1}),h(en,null,{default:v(()=>[L("strong",null,[h(se,{color:"primary",href:"https://docs.fdm-monster.net",style:{color:"white"},target:"_blank"},{default:v(()=>[h(J,{class:"mr-2"},{default:v(()=>i[21]||(i[21]=[x("menu_book")])),_:1}),i[22]||(i[22]=x(" FDM Monster documentation site "))]),_:1})]),i[23]||(i[23]=L("br",null,null,-1))]),_:1}),h(sn,null,{default:v(()=>[i[25]||(i[25]=x(" Bug reports ")),h(J,null,{default:v(()=>i[24]||(i[24]=[x("bug")])),_:1})]),_:1}),h(en,null,{default:v(()=>i[26]||(i[26]=[x(" 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"},[x(" FDM Monster "),L("strong",null," © "),x(" Github Issues ")])])]),L("li",null,[L("a",{href:"https://fdm-monster.net",style:{color:"white"},target:"_blank"}," Website ")])])],-1)])),_:1}),h(sn,null,{default:v(()=>i[27]||(i[27]=[x(" About me ")])),_:1}),h(en,null,{default:v(()=>i[28]||(i[28]=[L("img",{src:yZ,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),x(" David Zwart MSc., post-graduate from the TU Delft (Embedded Systems), author of FDM Monster"),L("strong",null," © ",-1)])),_:1})]),_:1}))}});/*!
|
|
71
|
+
* @kurkle/color v0.3.2
|
|
72
|
+
* https://github.com/kurkle/color#readme
|
|
73
|
+
* (c) 2023 Jukka Kurkela
|
|
74
|
+
* Released under the MIT License
|
|
75
|
+
*/function Wd(e){return e+.5|0}const _o=(e,t,n)=>Math.max(Math.min(e,n),t);function mc(e){return _o(Wd(e*2.55),0,255)}function Ro(e){return _o(Wd(e*255),0,255)}function Ri(e){return _o(Wd(e/2.55)/100,0,1)}function ux(e){return _o(Wd(e*100),0,100)}const Jr={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},gb=[..."0123456789ABCDEF"],_Z=e=>gb[e&15],kZ=e=>gb[(e&240)>>4]+gb[e&15],xf=e=>(e&240)>>4===(e&15),xZ=e=>xf(e.r)&&xf(e.g)&&xf(e.b)&&xf(e.a);function EZ(e){var t=e.length,n;return e[0]==="#"&&(t===4||t===5?n={r:255&Jr[e[1]]*17,g:255&Jr[e[2]]*17,b:255&Jr[e[3]]*17,a:t===5?Jr[e[4]]*17:255}:(t===7||t===9)&&(n={r:Jr[e[1]]<<4|Jr[e[2]],g:Jr[e[3]]<<4|Jr[e[4]],b:Jr[e[5]]<<4|Jr[e[6]],a:t===9?Jr[e[7]]<<4|Jr[e[8]]:255})),n}const CZ=(e,t)=>e<255?t(e):"";function TZ(e){var t=xZ(e)?_Z:kZ;return e?"#"+t(e.r)+t(e.g)+t(e.b)+CZ(e.a,t):void 0}const PZ=/^(hsla?|hwb|hsv)\(\s*([-+.e\d]+)(?:deg)?[\s,]+([-+.e\d]+)%[\s,]+([-+.e\d]+)%(?:[\s,]+([-+.e\d]+)(%)?)?\s*\)$/;function s2(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 RZ(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 IZ(e,t,n){const r=s2(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 AZ(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 ww(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,c;return i!==o&&(c=i-o,u=a>.5?c/(2-i-o):c/(i+o),l=AZ(n,r,s,c,i),l=l*60+.5),[l|0,u||0,a]}function Sw(e,t,n,r){return(Array.isArray(t)?e(t[0],t[1],t[2]):e(t,n,r)).map(Ro)}function _w(e,t,n){return Sw(s2,e,t,n)}function OZ(e,t,n){return Sw(IZ,e,t,n)}function MZ(e,t,n){return Sw(RZ,e,t,n)}function i2(e){return(e%360+360)%360}function DZ(e){const t=PZ.exec(e);let n=255,r;if(!t)return;t[5]!==r&&(n=t[6]?mc(+t[5]):Ro(+t[5]));const s=i2(+t[2]),i=+t[3]/100,o=+t[4]/100;return t[1]==="hwb"?r=OZ(s,i,o):t[1]==="hsv"?r=MZ(s,i,o):r=_w(s,i,o),{r:r[0],g:r[1],b:r[2],a:n}}function LZ(e,t){var n=ww(e);n[0]=i2(n[0]+t),n=_w(n),e.r=n[0],e.g=n[1],e.b=n[2]}function $Z(e){if(!e)return;const t=ww(e),n=t[0],r=ux(t[1]),s=ux(t[2]);return e.a<255?`hsla(${n}, ${r}%, ${s}%, ${Ri(e.a)})`:`hsl(${n}, ${r}%, ${s}%)`}const cx={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"},dx={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 FZ(){const e={},t=Object.keys(dx),n=Object.keys(cx);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,cx[i]);i=parseInt(dx[o],16),e[a]=[i>>16&255,i>>8&255,i&255]}return e}let Ef;function NZ(e){Ef||(Ef=FZ(),Ef.transparent=[0,0,0,0]);const t=Ef[e.toLowerCase()];return t&&{r:t[0],g:t[1],b:t[2],a:t.length===4?t[3]:255}}const BZ=/^rgba?\(\s*([-+.\d]+)(%)?[\s,]+([-+.e\d]+)(%)?[\s,]+([-+.e\d]+)(%)?(?:[\s,/]+([-+.e\d]+)(%)?)?\s*\)$/;function VZ(e){const t=BZ.exec(e);let n=255,r,s,i;if(t){if(t[7]!==r){const o=+t[7];n=t[8]?mc(o):_o(o*255,0,255)}return r=+t[1],s=+t[3],i=+t[5],r=255&(t[2]?mc(r):_o(r,0,255)),s=255&(t[4]?mc(s):_o(s,0,255)),i=255&(t[6]?mc(i):_o(i,0,255)),{r,g:s,b:i,a:n}}}function UZ(e){return e&&(e.a<255?`rgba(${e.r}, ${e.g}, ${e.b}, ${Ri(e.a)})`:`rgb(${e.r}, ${e.g}, ${e.b})`)}const Xg=e=>e<=.0031308?e*12.92:Math.pow(e,1/2.4)*1.055-.055,ml=e=>e<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4);function zZ(e,t,n){const r=ml(Ri(e.r)),s=ml(Ri(e.g)),i=ml(Ri(e.b));return{r:Ro(Xg(r+n*(ml(Ri(t.r))-r))),g:Ro(Xg(s+n*(ml(Ri(t.g))-s))),b:Ro(Xg(i+n*(ml(Ri(t.b))-i))),a:e.a+n*(t.a-e.a)}}function Cf(e,t,n){if(e){let r=ww(e);r[t]=Math.max(0,Math.min(r[t]+r[t]*n,t===0?360:1)),r=_w(r),e.r=r[0],e.g=r[1],e.b=r[2]}}function o2(e,t){return e&&Object.assign(t||{},e)}function fx(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=Ro(e[3]))):(t=o2(e,{r:0,g:0,b:0,a:1}),t.a=Ro(t.a)),t}function HZ(e){return e.charAt(0)==="r"?VZ(e):DZ(e)}class dd{constructor(t){if(t instanceof dd)return t;const n=typeof t;let r;n==="object"?r=fx(t):n==="string"&&(r=EZ(t)||NZ(t)||HZ(t)),this._rgb=r,this._valid=!!r}get valid(){return this._valid}get rgb(){var t=o2(this._rgb);return t&&(t.a=Ri(t.a)),t}set rgb(t){this._rgb=fx(t)}rgbString(){return this._valid?UZ(this._rgb):void 0}hexString(){return this._valid?TZ(this._rgb):void 0}hslString(){return this._valid?$Z(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=zZ(this._rgb,t._rgb,n)),this}clone(){return new dd(this.rgb)}alpha(t){return this._rgb.a=Ro(t),this}clearer(t){const n=this._rgb;return n.a*=1-t,this}greyscale(){const t=this._rgb,n=Wd(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 Cf(this._rgb,2,t),this}darken(t){return Cf(this._rgb,2,-t),this}saturate(t){return Cf(this._rgb,1,t),this}desaturate(t){return Cf(this._rgb,1,-t),this}rotate(t){return LZ(this._rgb,t),this}}/*!
|
|
76
|
+
* Chart.js v4.4.9
|
|
77
|
+
* https://www.chartjs.org
|
|
78
|
+
* (c) 2025 Chart.js Contributors
|
|
79
|
+
* Released under the MIT License
|
|
80
|
+
*/function Si(){}const jZ=(()=>{let e=0;return()=>e++})();function Nt(e){return e==null}function kn(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 xt(e){return e!==null&&Object.prototype.toString.call(e)==="[object Object]"}function hs(e){return(typeof e=="number"||e instanceof Number)&&isFinite(+e)}function Ws(e,t){return hs(e)?e:t}function At(e,t){return typeof e>"u"?t:e}const qZ=(e,t)=>typeof e=="string"&&e.endsWith("%")?parseFloat(e)/100*t:+e;function Xt(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(kn(e))for(i=e.length,s=0;s<i;s++)t.call(n,e[s],s);else if(xt(e))for(o=Object.keys(e),i=o.length,s=0;s<i;s++)t.call(n,e[o[s]],o[s])}function vp(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 yp(e){if(kn(e))return e.map(yp);if(xt(e)){const t=Object.create(null),n=Object.keys(e),r=n.length;let s=0;for(;s<r;++s)t[n[s]]=yp(e[n[s]]);return t}return e}function a2(e){return["__proto__","prototype","constructor"].indexOf(e)===-1}function WZ(e,t,n,r){if(!a2(e))return;const s=t[e],i=n[e];xt(s)&&xt(i)?fd(s,i,r):t[e]=yp(i)}function fd(e,t,n){const r=kn(t)?t:[t],s=r.length;if(!xt(e))return e;n=n||{};const i=n.merger||WZ;let o;for(let a=0;a<s;++a){if(o=r[a],!xt(o))continue;const l=Object.keys(o);for(let u=0,c=l.length;u<c;++u)i(l[u],e,o,n)}return e}function Lc(e,t){return fd(e,t,{merger:GZ})}function GZ(e,t,n){if(!a2(e))return;const r=t[e],s=n[e];xt(r)&&xt(s)?Lc(r,s):Object.prototype.hasOwnProperty.call(t,e)||(t[e]=yp(s))}const hx={"":e=>e,x:e=>e.x,y:e=>e.y};function KZ(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 YZ(e){const t=KZ(e);return n=>{for(const r of t){if(r==="")break;n=n&&n[r]}return n}}function bu(e,t){return(hx[t]||(hx[t]=YZ(t)))(e)}function kw(e){return e.charAt(0).toUpperCase()+e.slice(1)}const hd=e=>typeof e<"u",Fo=e=>typeof e=="function",px=(e,t)=>{if(e.size!==t.size)return!1;for(const n of e)if(!t.has(n))return!1;return!0};function XZ(e){return e.type==="mouseup"||e.type==="click"||e.type==="contextmenu"}const rr=Math.PI,Io=2*rr,bp=Number.POSITIVE_INFINITY,QZ=rr/180,Ts=rr/2,ta=rr/4,mx=rr*2/3,vb=Math.log10,Ao=Math.sign;function yh(e,t,n){return Math.abs(e-t)<n}function gx(e){const t=Math.round(e);e=yh(e,t,e/1e3)?t:e;const n=Math.pow(10,Math.floor(vb(e))),r=e/n;return(r<=1?1:r<=2?2:r<=5?5:10)*n}function JZ(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 ZZ(e){return typeof e=="symbol"||typeof e=="object"&&e!==null&&!(Symbol.toPrimitive in e||"toString"in e||"valueOf"in e)}function wp(e){return!ZZ(e)&&!isNaN(parseFloat(e))&&isFinite(e)}function eee(e,t){const n=Math.round(e);return n-t<=e&&n+t>=e}function tee(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 ga(e){return e*(rr/180)}function nee(e){return e*(180/rr)}function vx(e){if(!hs(e))return;let t=1,n=0;for(;Math.round(e*t)/t!==e;)t*=10,n++;return n}function ree(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*rr&&(i+=Io),{angle:i,distance:s}}function see(e,t){return Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2))}function na(e){return(e%Io+Io)%Io}function iee(e,t,n,r){const s=na(e),i=na(t),o=na(n),a=na(i-s),l=na(o-s),u=na(s-i),c=na(s-o);return s===i||s===o||r&&i===o||a>l&&u<c}function Ps(e,t,n){return Math.max(t,Math.min(n,e))}function oee(e){return Ps(e,-32768,32767)}function Ml(e,t,n,r=1e-6){return e>=Math.min(t,n)-r&&e<=Math.max(t,n)+r}function xw(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 yb=(e,t,n,r)=>xw(e,n,r?s=>{const i=e[s][t];return i<n||i===n&&e[s+1][t]===n}:s=>e[s][t]<n),aee=(e,t,n)=>xw(e,n,r=>e[r][t]>=n);function lee(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 l2=["push","pop","shift","splice","unshift"];function uee(e,t){if(e._chartjs){e._chartjs.listeners.push(t);return}Object.defineProperty(e,"_chartjs",{configurable:!0,enumerable:!1,value:{listeners:[t]}}),l2.forEach(n=>{const r="_onData"+kw(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 yx(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)&&(l2.forEach(i=>{delete e[i]}),delete e._chartjs)}function u2(e){const t=new Set(e);return t.size===e.length?e:Array.from(t)}const c2=function(){return typeof window>"u"?function(e){return e()}:window.requestAnimationFrame}();function d2(e,t){let n=[],r=!1;return function(...s){n=s,r||(r=!0,c2.call(window,()=>{r=!1,e.apply(t,n)}))}}function cee(e,t){let n;return function(...r){return t?(clearTimeout(n),n=setTimeout(e,t,r)):e.apply(this,r),t}}const Ew=e=>e==="start"?"left":e==="end"?"right":"center",Gn=(e,t,n)=>e==="start"?t:e==="end"?n:(t+n)/2,dee=(e,t,n,r)=>e===(r?"left":"right")?n:e==="center"?(t+n)/2:t,Tf=e=>e===0||e===1,bx=(e,t,n)=>-(Math.pow(2,10*(e-=1))*Math.sin((e-t)*Io/n)),wx=(e,t,n)=>Math.pow(2,-10*e)*Math.sin((e-t)*Io/n)+1,$c={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*Ts)+1,easeOutSine:e=>Math.sin(e*Ts),easeInOutSine:e=>-.5*(Math.cos(rr*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=>Tf(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=>Tf(e)?e:bx(e,.075,.3),easeOutElastic:e=>Tf(e)?e:wx(e,.075,.3),easeInOutElastic(e){return Tf(e)?e:e<.5?.5*bx(e*2,.1125,.45):.5+.5*wx(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-$c.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?$c.easeInBounce(e*2)*.5:$c.easeOutBounce(e*2-1)*.5+.5};function f2(e){if(e&&typeof e=="object"){const t=e.toString();return t==="[object CanvasPattern]"||t==="[object CanvasGradient]"}return!1}function Sx(e){return f2(e)?e:new dd(e)}function Qg(e){return f2(e)?e:new dd(e).saturate(.5).darken(.1).hexString()}const fee=["x","y","borderWidth","radius","tension"],hee=["color","borderColor","backgroundColor"];function pee(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:hee},numbers:{type:"number",properties:fee}}),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 mee(e){e.set("layout",{autoPadding:!0,padding:{top:0,right:0,bottom:0,left:0}})}const _x=new Map;function gee(e,t){t=t||{};const n=e+JSON.stringify(t);let r=_x.get(n);return r||(r=new Intl.NumberFormat(e,t),_x.set(n,r)),r}function h2(e,t,n){return gee(t,n).format(e)}const p2={values(e){return kn(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=vee(e,n)}const o=vb(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),h2(e,r,l)},logarithmic(e,t,n){if(e===0)return"0";const r=n[t].significand||e/Math.pow(10,Math.floor(vb(e)));return[1,2,3,5,10,15].includes(r)||t>.8*n.length?p2.numeric.call(this,e,t,n):""}};function vee(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 m2={formatters:p2};function yee(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:m2.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),bb=Object.create(null);function Fc(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 Jg(e,t,n){return typeof t=="string"?fd(Fc(e,t),n):fd(Fc(e,""),t)}class bee{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)=>Qg(s.backgroundColor),this.hoverBorderColor=(r,s)=>Qg(s.borderColor),this.hoverColor=(r,s)=>Qg(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 Jg(this,t,n)}get(t){return Fc(this,t)}describe(t,n){return Jg(bb,t,n)}override(t,n){return Jg(Xa,t,n)}route(t,n,r,s){const i=Fc(this,t),o=Fc(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 xt(l)?Object.assign({},u,l):At(l,u)},set(l){this[a]=l}}})}apply(t){t.forEach(n=>n(this))}}var gn=new bee({_scriptable:e=>!e.startsWith("on"),_indexable:e=>e!=="events",hover:{_fallback:"interaction"},interaction:{_scriptable:!1,_indexable:!1}},[pee,mee,yee]);function wee(e){return!e||Nt(e.size)||Nt(e.family)?null:(e.style?e.style+" ":"")+(e.weight?e.weight+" ":"")+e.size+"px "+e.family}function kx(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 ra(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 xx(e,t){!t&&!e||(t=t||e.getContext("2d"),t.save(),t.resetTransform(),t.clearRect(0,0,e.width,e.height),t.restore())}function Ex(e,t,n,r){g2(e,t,n,r,null)}function g2(e,t,n,r,s){let i,o,a,l,u,c,d,f;const p=t.pointStyle,g=t.rotation,m=t.radius;let y=(g||0)*QZ;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,Io):e.arc(n,r,m,0,Io),e.closePath();break;case"triangle":c=s?s/2:m,e.moveTo(n+Math.sin(y)*c,r-Math.cos(y)*m),y+=mx,e.lineTo(n+Math.sin(y)*c,r-Math.cos(y)*m),y+=mx,e.lineTo(n+Math.sin(y)*c,r-Math.cos(y)*m),e.closePath();break;case"rectRounded":u=m*.516,l=m-u,o=Math.cos(y+ta)*l,d=Math.cos(y+ta)*(s?s/2-u:l),a=Math.sin(y+ta)*l,f=Math.sin(y+ta)*(s?s/2-u:l),e.arc(n-d,r-a,u,y-rr,y-Ts),e.arc(n+f,r-o,u,y-Ts,y),e.arc(n+d,r+a,u,y,y+Ts),e.arc(n-f,r+o,u,y+Ts,y+rr),e.closePath();break;case"rect":if(!g){l=Math.SQRT1_2*m,c=s?s/2:l,e.rect(n-c,r-l,2*c,2*l);break}y+=ta;case"rectRot":d=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-d,r-a),e.lineTo(n+f,r-o),e.lineTo(n+d,r+a),e.lineTo(n-f,r+o),e.closePath();break;case"crossRot":y+=ta;case"cross":d=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-d,r-a),e.lineTo(n+d,r+a),e.moveTo(n+f,r-o),e.lineTo(n-f,r+o);break;case"star":d=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-d,r-a),e.lineTo(n+d,r+a),e.moveTo(n+f,r-o),e.lineTo(n-f,r+o),y+=ta,d=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-d,r-a),e.lineTo(n+d,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 v2(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 Cw(e,t){e.save(),e.beginPath(),e.rect(t.left,t.top,t.right-t.left,t.bottom-t.top),e.clip()}function Tw(e){e.restore()}function See(e,t){t.translation&&e.translate(t.translation[0],t.translation[1]),Nt(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 _ee(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,c=s.strikethrough?(l+u)/2:u;e.strokeStyle=e.fillStyle,e.beginPath(),e.lineWidth=s.decorationWidth||2,e.moveTo(o,c),e.lineTo(a,c),e.stroke()}}function kee(e,t){const n=e.fillStyle;e.fillStyle=t.color,e.fillRect(t.left,t.top,t.width,t.height),e.fillStyle=n}function pd(e,t,n,r,s,i={}){const o=kn(t)?t:[t],a=i.strokeWidth>0&&i.strokeColor!=="";let l,u;for(e.save(),e.font=s.string,See(e,i),l=0;l<o.length;++l)u=o[l],i.backdrop&&kee(e,i.backdrop),a&&(i.strokeColor&&(e.strokeStyle=i.strokeColor),Nt(i.strokeWidth)||(e.lineWidth=i.strokeWidth),e.strokeText(u,n,r,i.maxWidth)),e.fillText(u,n,r,i.maxWidth),_ee(e,n,r,u,i),r+=Number(s.lineHeight);e.restore()}function Sp(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*rr,rr,!0),e.lineTo(n,r+i-o.bottomLeft),e.arc(n+o.bottomLeft,r+i-o.bottomLeft,o.bottomLeft,rr,Ts,!0),e.lineTo(n+s-o.bottomRight,r+i),e.arc(n+s-o.bottomRight,r+i-o.bottomRight,o.bottomRight,Ts,0,!0),e.lineTo(n+s,r+o.topRight),e.arc(n+s-o.topRight,r+o.topRight,o.topRight,0,-Ts,!0),e.lineTo(n+o.topLeft,r)}const xee=/^(normal|(\d+(?:\.\d+)?)(px|em|%)?)$/,Eee=/^(normal|italic|initial|inherit|unset|(oblique( -?[0-9]?[0-9]deg)?))$/;function Cee(e,t){const n=(""+e).match(xee);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 Tee=e=>+e||0;function y2(e,t){const n={},r=xt(t),s=r?Object.keys(t):t,i=xt(e)?r?o=>At(e[o],e[t[o]]):o=>e[o]:()=>e;for(const o of s)n[o]=Tee(i(o));return n}function b2(e){return y2(e,{top:"y",right:"x",bottom:"y",left:"x"})}function Vl(e){return y2(e,["topLeft","topRight","bottomLeft","bottomRight"])}function ps(e){const t=b2(e);return t.width=t.left+t.right,t.height=t.top+t.bottom,t}function er(e,t){e=e||{},t=t||gn.font;let n=At(e.size,t.size);typeof n=="string"&&(n=parseInt(n,10));let r=At(e.style,t.style);r&&!(""+r).match(Eee)&&(console.warn('Invalid font style specified: "'+r+'"'),r=void 0);const s={family:At(e.family,t.family),lineHeight:Cee(At(e.lineHeight,t.lineHeight),n),size:n,style:r,weight:At(e.weight,t.weight),string:""};return s.string=wee(s),s}function Pf(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 Pee(e,t,n){const{min:r,max:s}=e,i=qZ(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 ju(e,t){return Object.assign(Object.create(e),t)}function Pw(e,t=[""],n,r,s=()=>e[0]){const i=n||e;typeof r>"u"&&(r=k2("_fallback",e));const o={[Symbol.toStringTag]:"Object",_cacheable:!0,_scopes:e,_rootScopes:i,_fallback:r,_getTarget:s,override:a=>Pw([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 S2(a,l,()=>$ee(l,t,e,a))},getOwnPropertyDescriptor(a,l){return Reflect.getOwnPropertyDescriptor(a._scopes[0],l)},getPrototypeOf(){return Reflect.getPrototypeOf(e[0])},has(a,l){return Tx(a).includes(l)},ownKeys(a){return Tx(a)},set(a,l,u){const c=a._storage||(a._storage=s());return a[l]=c[l]=u,delete a._keys,!0}})}function wu(e,t,n,r){const s={_cacheable:!1,_proxy:e,_context:t,_subProxy:n,_stack:new Set,_descriptors:w2(e,r),setContext:i=>wu(e,i,n,r),override:i=>wu(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 S2(i,o,()=>Iee(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 w2(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:Fo(n)?n:()=>n,isIndexable:Fo(r)?r:()=>r}}const Ree=(e,t)=>e?e+kw(t):t,Rw=(e,t)=>xt(t)&&e!=="adapters"&&(Object.getPrototypeOf(t)===null||t.constructor===Object);function S2(e,t,n){if(Object.prototype.hasOwnProperty.call(e,t)||t==="constructor")return e[t];const r=n();return e[t]=r,r}function Iee(e,t,n){const{_proxy:r,_context:s,_subProxy:i,_descriptors:o}=e;let a=r[t];return Fo(a)&&o.isScriptable(t)&&(a=Aee(t,a,e,n)),kn(a)&&a.length&&(a=Oee(t,a,e,o.isIndexable)),Rw(t,a)&&(a=wu(a,s,i&&i[t],o)),a}function Aee(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),Rw(e,l)&&(l=Iw(s._scopes,s,e,l)),l}function Oee(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(xt(t[0])){const l=t,u=s._scopes.filter(c=>c!==l);t=[];for(const c of l){const d=Iw(u,s,e,c);t.push(wu(d,i,o&&o[e],a))}}return t}function _2(e,t,n){return Fo(e)?e(t,n):e}const Mee=(e,t)=>e===!0?t:typeof e=="string"?bu(t,e):void 0;function Dee(e,t,n,r,s){for(const i of t){const o=Mee(n,i);if(o){e.add(o);const a=_2(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 Iw(e,t,n,r){const s=t._rootScopes,i=_2(t._fallback,n,r),o=[...e,...s],a=new Set;a.add(r);let l=Cx(a,o,n,i||n,r);return l===null||typeof i<"u"&&i!==n&&(l=Cx(a,o,i,l,r),l===null)?!1:Pw(Array.from(a),[""],s,i,()=>Lee(t,n,r))}function Cx(e,t,n,r,s){for(;n;)n=Dee(e,t,n,r,s);return n}function Lee(e,t,n){const r=e._getTarget();t in r||(r[t]={});const s=r[t];return kn(s)&&xt(n)?n:s||{}}function $ee(e,t,n,r){let s;for(const i of t)if(s=k2(Ree(i,e),n),typeof s<"u")return Rw(e,s)?Iw(n,r,e,s):s}function k2(e,t){for(const n of t){if(!n)continue;const r=n[e];if(typeof r<"u")return r}}function Tx(e){let t=e._keys;return t||(t=e._keys=Fee(e._scopes)),t}function Fee(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 Aw(){return typeof window<"u"&&typeof document<"u"}function Ow(e){let t=e.parentNode;return t&&t.toString()==="[object ShadowRoot]"&&(t=t.host),t}function _p(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 Fm=e=>e.ownerDocument.defaultView.getComputedStyle(e,null);function Nee(e,t){return Fm(e).getPropertyValue(t)}const Bee=["top","right","bottom","left"];function La(e,t,n){const r={};n=n?"-"+n:"";for(let s=0;s<4;s++){const i=Bee[s];r[i]=parseFloat(e[t+"-"+i+n])||0}return r.width=r.left+r.right,r.height=r.top+r.bottom,r}const Vee=(e,t,n)=>(e>0||t>0)&&(!n||!n.shadowRoot);function Uee(e,t){const n=e.touches,r=n&&n.length?n[0]:e,{offsetX:s,offsetY:i}=r;let o=!1,a,l;if(Vee(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 la(e,t){if("native"in e)return e;const{canvas:n,currentDevicePixelRatio:r}=t,s=Fm(n),i=s.boxSizing==="border-box",o=La(s,"padding"),a=La(s,"border","width"),{x:l,y:u,box:c}=Uee(e,n),d=o.left+(c&&a.left),f=o.top+(c&&a.top);let{width:p,height:g}=t;return i&&(p-=o.width+a.width,g-=o.height+a.height),{x:Math.round((l-d)/p*n.width/r),y:Math.round((u-f)/g*n.height/r)}}function zee(e,t,n){let r,s;if(t===void 0||n===void 0){const i=e&&Ow(e);if(!i)t=e.clientWidth,n=e.clientHeight;else{const o=i.getBoundingClientRect(),a=Fm(i),l=La(a,"border","width"),u=La(a,"padding");t=o.width-u.width-l.width,n=o.height-u.height-l.height,r=_p(a.maxWidth,i,"clientWidth"),s=_p(a.maxHeight,i,"clientHeight")}}return{width:t,height:n,maxWidth:r||bp,maxHeight:s||bp}}const Rf=e=>Math.round(e*10)/10;function Hee(e,t,n,r){const s=Fm(e),i=La(s,"margin"),o=_p(s.maxWidth,e,"clientWidth")||bp,a=_p(s.maxHeight,e,"clientHeight")||bp,l=zee(e,t,n);let{width:u,height:c}=l;if(s.boxSizing==="content-box"){const f=La(s,"border","width"),p=La(s,"padding");u-=p.width+f.width,c-=p.height+f.height}return u=Math.max(0,u-i.width),c=Math.max(0,r?u/r:c-i.height),u=Rf(Math.min(u,o,l.maxWidth)),c=Rf(Math.min(c,a,l.maxHeight)),u&&!c&&(c=Rf(u/2)),(t!==void 0||n!==void 0)&&r&&l.height&&c>l.height&&(c=l.height,u=Rf(Math.floor(c*r))),{width:u,height:c}}function Px(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 jee=function(){let e=!1;try{const t={get passive(){return e=!0,!1}};Aw()&&(window.addEventListener("test",null,t),window.removeEventListener("test",null,t))}catch{}return e}();function Rx(e,t){const n=Nee(e,t),r=n&&n.match(/^(\d+)(\.\d+)?px$/);return r?+r[1]:void 0}const qee=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}}},Wee=function(){return{x(e){return e},setWidth(e){},textAlign(e){return e},xPlus(e,t){return e+t},leftForLtr(e,t){return e}}};function Ul(e,t,n){return e?qee(t,n):Wee()}function x2(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 E2(e,t){t!==void 0&&(delete e.prevTextDirection,e.canvas.style.setProperty("direction",t[0],t[1]))}function If(e,t,n){return e.options.clip?e[n]:t[n]}function Gee(e,t){const{xScale:n,yScale:r}=e;return n&&r?{left:If(n,t,"left"),right:If(n,t,"right"),top:If(r,t,"top"),bottom:If(r,t,"bottom")}:t}function Kee(e,t){const n=t._clip;if(n.disabled)return!1;const r=Gee(t,e.chartArea);return{left:n.left===!1?0:r.left-(n.left===!0?0:n.left),right:n.right===!1?e.width:r.right+(n.right===!0?0:n.right),top:n.top===!1?0:r.top-(n.top===!0?0:n.top),bottom:n.bottom===!1?e.height:r.bottom+(n.bottom===!0?0:n.bottom)}}/*!
|
|
81
|
+
* Chart.js v4.4.9
|
|
82
|
+
* https://www.chartjs.org
|
|
83
|
+
* (c) 2025 Chart.js Contributors
|
|
84
|
+
* Released under the MIT License
|
|
85
|
+
*/class Yee{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=c2.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 Yee;const Ix="transparent",Xee={boolean(e,t,n){return n>.5?t:e},color(e,t,n){const r=Sx(e||Ix),s=r.valid&&Sx(t||Ix);return s&&s.valid?s.mix(r,n).hexString():t},number(e,t,n){return e+(t-e)*n}};class Qee{constructor(t,n,r,s){const i=n[r];s=Pf([t.to,s,i,t.from]);const o=Pf([t.from,i,s]);this._active=!0,this._fn=t.fn||Xee[t.type||typeof o],this._easing=$c[t.easing]||$c.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=Pf([t.to,n,s,t.from]),this._from=Pf([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 C2{constructor(t,n){this._chart=t,this._properties=new Map,this.configure(n)}configure(t){if(!xt(t))return;const n=Object.keys(gn.animation),r=this._properties;Object.getOwnPropertyNames(t).forEach(s=>{const i=t[s];if(!xt(i))return;const o={};for(const a of n)o[a]=i[a];(kn(i.properties)&&i.properties||[s]).forEach(a=>{(a===s||!r.has(a))&&r.set(a,o)})})}_animateOptions(t,n){const r=n.options,s=Zee(t,r);if(!s)return[];const i=this._createAnimations(s,r);return r.$shared&&Jee(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 c=n[u];let d=i[u];const f=r.get(u);if(d)if(f&&d.active()){d.update(f,c,a);continue}else d.cancel();if(!f||!f.duration){t[u]=c;continue}i[u]=d=new Qee(f,t,u,c),s.push(d)}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 Jee(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 Zee(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 Ax(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 ete(e,t,n){if(n===!1)return!1;const r=Ax(e,n),s=Ax(t,n);return{top:s.end,right:r.end,bottom:s.start,left:r.start}}function tte(e){let t,n,r,s;return xt(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 T2(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 Ox(e,t,n,r={}){const s=e.keys,i=r.mode==="single";let o,a,l,u;if(t===null)return;let c=!1;for(o=0,a=s.length;o<a;++o){if(l=+s[o],l===n){if(c=!0,r.all)continue;break}u=e.values[l],hs(u)&&(i||t===0||Ao(t)===Ao(u))&&(t+=u)}return!c&&!r.all?0:t}function nte(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,c;for(l=0,u=o.length;l<u;++l)c=o[l],a[l]={[s]:c,[i]:e[c]};return a}function Zg(e,t){const n=e&&e.options.stacked;return n||n===void 0&&t.stack!==void 0}function rte(e,t,n){return`${e.id}.${t.id}.${n.stack||n.type}`}function ste(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 ite(e,t,n){const r=e[t]||(e[t]={});return r[n]||(r[n]={})}function Mx(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 Dx(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,c=rte(i,o,r),d=t.length;let f;for(let p=0;p<d;++p){const g=t[p],{[l]:m,[u]:y}=g,w=g._stacks||(g._stacks={});f=w[u]=ite(s,c,m),f[a]=y,f._top=Mx(f,o,!0,r.type),f._bottom=Mx(f,o,!1,r.type);const b=f._visualValues||(f._visualValues={});b[a]=y}}function ev(e,t){const n=e.scales;return Object.keys(n).filter(r=>n[r].axis===t).shift()}function ote(e,t){return ju(e,{active:!1,dataset:void 0,datasetIndex:t,index:t,mode:"default",type:"dataset"})}function ate(e,t,n){return ju(e,{active:!1,dataIndex:t,parsed:void 0,raw:void 0,element:n,index:t,mode:"default",type:"data"})}function sc(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 tv=e=>e==="reset"||e==="none",Lx=(e,t)=>t?e:Object.assign({},e),lte=(e,t,n)=>e&&!t.hidden&&t._stacked&&{keys:T2(n,!0),values:null};class Nc{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=Zg(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&&sc(this._cachedMeta),this.index=t}linkScales(){const t=this.chart,n=this._cachedMeta,r=this.getDataset(),s=(d,f,p,g)=>d==="x"?f:d==="r"?g:p,i=n.xAxisID=At(r.xAxisID,ev(t,"x")),o=n.yAxisID=At(r.yAxisID,ev(t,"y")),a=n.rAxisID=At(r.rAxisID,ev(t,"r")),l=n.indexAxis,u=n.iAxisID=s(l,i,o,a),c=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(c)}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&&yx(this._data,this),t._stacked&&sc(t)}_dataCheck(){const t=this.getDataset(),n=t.data||(t.data=[]),r=this._data;if(xt(n)){const s=this._cachedMeta;this._data=nte(n,s)}else if(r!==n){if(r){yx(r,this);const s=this._cachedMeta;sc(s),s._parsed=[]}n&&Object.isExtensible(n)&&uee(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=Zg(n.vScale,n),n.stack!==r.stack&&(s=!0,sc(n),n.stack=r.stack),this._resyncElements(t),(s||i!==n._stacked)&&(Dx(this,n._parsed),n._stacked=Zg(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],c,d,f;if(this._parsing===!1)r._parsed=s,r._sorted=!0,f=s;else{kn(s[t])?f=this.parseArrayData(r,s,t,n):xt(s[t])?f=this.parseObjectData(r,s,t,n):f=this.parsePrimitiveData(r,s,t,n);const p=()=>d[a]===null||u&&d[a]<u[a];for(c=0;c<n;++c)r._parsed[c+t]=d=f[c],l&&(p()&&(l=!1),u=d);r._sorted=l}o&&Dx(this,f)}parsePrimitiveData(t,n,r,s){const{iScale:i,vScale:o}=t,a=i.axis,l=o.axis,u=i.getLabels(),c=i===o,d=new Array(s);let f,p,g;for(f=0,p=s;f<p;++f)g=f+r,d[f]={[a]:c||i.parse(u[g],g),[l]:o.parse(n[g],g)};return d}parseArrayData(t,n,r,s){const{xScale:i,yScale:o}=t,a=new Array(s);let l,u,c,d;for(l=0,u=s;l<u;++l)c=l+r,d=n[c],a[l]={x:i.parse(d[0],c),y:o.parse(d[1],c)};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 c,d,f,p;for(c=0,d=s;c<d;++c)f=c+r,p=n[f],u[c]={x:i.parse(bu(p,a),f),y:o.parse(bu(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:T2(s,!0),values:n._stacks[t.axis]._visualValues};return Ox(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=Ox(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=lte(n,r,this.chart),u={min:Number.POSITIVE_INFINITY,max:Number.NEGATIVE_INFINITY},{min:c,max:d}=ste(a);let f,p;function g(){p=s[f];const m=p[a.axis];return!hs(p[t.axis])||c>m||d<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],hs(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=tte(At(this.options.clip,ete(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 c;for(r.dataset&&r.dataset.draw(t,i,a,l),c=a;c<a+l;++c){const d=s[c];d.hidden||(d.active&&u?o.push(d):d.draw(t,i))}for(c=0;c<o.length;++c)o[c].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=ate(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=ote(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&&hd(r);if(a)return Lx(a,l);const u=this.chart.config,c=u.datasetElementScopeKeys(this._type,t),d=s?[`${t}Hover`,"hover",t,""]:[t,""],f=u.getOptionScopes(this.getDataset(),c),p=Object.keys(gn.elements[t]),g=()=>this.getContext(r,s,n),m=u.resolveNamedOptions(f,p,g,d);return m.$shared&&(m.$shared=l,i[o]=Object.freeze(Lx(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 c=this.chart.config,d=c.datasetAnimationScopeKeys(this._type,n),f=c.getOptionScopes(this.getDataset(),d);l=c.createResolver(f,this.getContext(t,r,n))}const u=new C2(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||tv(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){tv(s)?Object.assign(t,r):this._resolveAnimations(n,s).update(t,r)}updateSharedOptions(t,n,r){t&&!tv(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&&sc(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])}}we(Nc,"defaults",{}),we(Nc,"datasetElementType",null),we(Nc,"dataElementType",null);function ute(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=u2(r.sort((s,i)=>s-i))}return e._cache.$bar}function cte(e){const t=e.iScale,n=ute(t,e.type);let r=t._length,s,i,o,a;const l=()=>{o===32767||o===-32768||(hd(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 dte(e,t,n,r){const s=n.barThickness;let i,o;return Nt(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 fte(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 hte(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 P2(e,t,n,r){return kn(e)?hte(e,t,n,r):t[n.axis]=n.parse(e,r),t}function $x(e,t,n,r){const s=e.iScale,i=e.vScale,o=s.getLabels(),a=s===i,l=[];let u,c,d,f;for(u=n,c=n+r;u<c;++u)f=t[u],d={},d[s.axis]=a||s.parse(o[u],u),l.push(P2(f,d,i,u));return l}function nv(e){return e&&e.barStart!==void 0&&e.barEnd!==void 0}function pte(e,t,n){return e!==0?Ao(e):(t.isHorizontal()?1:-1)*(t.min>=n?1:-1)}function mte(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 gte(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:c}=mte(e);s==="middle"&&n&&(e.enableBorderRadius=!0,(n._top||0)===r?s=u:(n._bottom||0)===r?s=c:(i[Fx(c,o,a,l)]=!0,s=u)),i[Fx(s,o,a,l)]=!0,e.borderSkipped=i}function Fx(e,t,n,r){return r?(e=vte(e,t,n),e=Nx(e,n,t)):e=Nx(e,t,n),e}function vte(e,t,n){return e===t?n:e===n?t:e}function Nx(e,t,n){return e==="start"?t:e==="end"?n:e}function yte(e,{inflateAmount:t},n){e.inflateAmount=t==="auto"?n===1?.33:0:t}class bh extends Nc{parsePrimitiveData(t,n,r,s){return $x(t,n,r,s)}parseArrayData(t,n,r,s){return $x(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,c=o.axis==="x"?a:l,d=[];let f,p,g,m;for(f=r,p=r+s;f<p;++f)m=n[f],g={},g[i.axis]=i.parse(bu(m,u),f),d.push(P2(bu(m,c),g,o,f));return d}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=nv(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(),c=this._getRuler(),{sharedOptions:d,includeOptions:f}=this._getSharedOptions(n,s);for(let p=n;p<n+r;p++){const g=this.getParsed(p),m=i||Nt(g[a.axis])?{base:l,head:l}:this._calculateBarValuePixels(p),y=this._calculateBarIndexPixels(p,c),w=(g._stacks||{})[a.axis],b={horizontal:u,base:m.base,enableBorderRadius:!w||nv(g._custom)||o===w._top||o===w._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&&(b.options=d||this.resolveDataElementOptions(p,t[p].active?"active":s));const k=b.options||t[p].options;gte(b,k,w,o),yte(b,k,c.ratio),this.updateElement(t[p],p,b,s)}}_getStacks(t,n){const{iScale:r}=this._cachedMeta,s=r.getMatchingVisibleMetas(this._type).filter(c=>c.controller.options.grouped),i=r.options.stacked,o=[],a=this._cachedMeta.controller.getParsed(n),l=a&&a[r.axis],u=c=>{const d=c._parsed.find(p=>p[r.axis]===l),f=d&&d[c.vScale.axis];if(Nt(f)||isNaN(f))return!0};for(const c of s)if(!(n!==void 0&&u(c))&&((i===!1||o.indexOf(c.stack)===-1||i===void 0&&c.stack===void 0)&&o.push(c.stack),c.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||cte(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,c=nv(u);let d=l[n.axis],f=0,p=r?this.applyStack(n,l,r):d,g,m;p!==d&&(f=p-d,p=d),c&&(d=u.barStart,p=u.barEnd-u.barStart,d!==0&&Ao(d)!==Ao(u.barEnd)&&(f=0),f+=d);const y=!Nt(i)&&!c?i:f;let w=n.getPixelForValue(y);if(this.chart.getDataVisibility(t)?g=n.getPixelForValue(f+p):g=w,m=g-w,Math.abs(m)<o){m=pte(m,n,a)*o,d===a&&(w-=m/2);const b=n.getPixelForDecimal(0),k=n.getPixelForDecimal(1),C=Math.min(b,k),_=Math.max(b,k);w=Math.max(Math.min(w,_),C),g=w+m,r&&!c&&(l._stacks[n.axis]._visualValues[s]=n.getValueForPixel(g)-n.getValueForPixel(w))}if(w===n.getPixelForValue(a)){const b=Ao(m)*n.getLineWidthForValue(a)/2;w+=b,m-=b}return{size:m,base:w,head:g,center:g+m/2}}_calculateBarIndexPixels(t,n){const r=n.scale,s=this.options,i=s.skipNull,o=At(s.maxBarThickness,1/0);let a,l;if(n.grouped){const u=i?this._getStackCount(t):n.stackCount,c=s.barThickness==="flex"?fte(t,n,s,u):dte(t,n,s,u),d=this._getStackIndex(this.index,this._cachedMeta.stack,i?t:void 0);a=c.start+c.chunk*d+c.chunk/2,l=Math.min(o,c.chunk*c.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)}}we(bh,"id","bar"),we(bh,"defaults",{datasetElementType:!1,dataElementType:"bar",categoryPercentage:.8,barPercentage:.9,grouped:!0,animations:{numbers:{type:"number",properties:["x","y","base","width","height"]}}}),we(bh,"overrides",{scales:{_index_:{type:"category",offset:!0,grid:{offset:!0}},_value_:{type:"linear",beginAtZero:!0}}});function sa(){throw new Error("This method is not implemented: Check that a complete date adapter is provided.")}class Mw{constructor(t){we(this,"options");this.options=t||{}}static override(t){Object.assign(Mw.prototype,t)}init(){}formats(){return sa()}parse(){return sa()}format(){return sa()}add(){return sa()}diff(){return sa()}startOf(){return sa()}endOf(){return sa()}}var bte={_date:Mw};function wte(e,t,n,r){const{controller:s,data:i,_sorted:o}=e,a=s._cachedMeta.iScale,l=e.dataset&&e.dataset.options?e.dataset.options.spanGaps:null;if(a&&t===a.axis&&t!=="r"&&o&&i.length){const u=a._reversePixels?aee:yb;if(r){if(s._sharedOptions){const c=i[0],d=typeof c.getRange=="function"&&c.getRange(t);if(d){const f=u(i,t,n-d),p=u(i,t,n+d);return{lo:f.lo,hi:p.hi}}}}else{const c=u(i,t,n);if(l){const{vScale:d}=s._cachedMeta,{_parsed:f}=e,p=f.slice(0,c.lo+1).reverse().findIndex(m=>!Nt(m[d.axis]));c.lo-=Math.max(0,p);const g=f.slice(c.hi).findIndex(m=>!Nt(m[d.axis]));c.hi+=Math.max(0,g)}return c}}return{lo:0,hi:i.length-1}}function Gd(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:c}=i[a],{lo:d,hi:f}=wte(i[a],t,o,s);for(let p=d;p<=f;++p){const g=c[p];g.skip||r(g,u,p)}}}function Ste(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 rv(e,t,n,r,s){const i=[];return!s&&!e.isPointInArea(t)||Gd(e,n,t,function(a,l,u){!s&&!v2(a,e.chartArea,0)||a.inRange(t.x,t.y,r)&&i.push({element:a,datasetIndex:l,index:u})},!0),i}function _te(e,t,n,r){let s=[];function i(o,a,l){const{startAngle:u,endAngle:c}=o.getProps(["startAngle","endAngle"],r),{angle:d}=ree(o,{x:t.x,y:t.y});iee(d,u,c)&&s.push({element:o,datasetIndex:a,index:l})}return Gd(e,n,t,i),s}function kte(e,t,n,r,s,i){let o=[];const a=Ste(n);let l=Number.POSITIVE_INFINITY;function u(c,d,f){const p=c.inRange(t.x,t.y,s);if(r&&!p)return;const g=c.getCenterPoint(s);if(!(!!i||e.isPointInArea(g))&&!p)return;const y=a(t,g);y<l?(o=[{element:c,datasetIndex:d,index:f}],l=y):y===l&&o.push({element:c,datasetIndex:d,index:f})}return Gd(e,n,t,u),o}function sv(e,t,n,r,s,i){return!i&&!e.isPointInArea(t)?[]:n==="r"&&!r?_te(e,t,n,s):kte(e,t,n,r,s,i)}function Bx(e,t,n,r,s){const i=[],o=n==="x"?"inXRange":"inYRange";let a=!1;return Gd(e,n,t,(l,u,c)=>{l[o]&&l[o](t[n],s)&&(i.push({element:l,datasetIndex:u,index:c}),a=a||l.inRange(t.x,t.y,s))}),r&&!a?[]:i}var xte={evaluateInteractionItems:Gd,modes:{index(e,t,n,r){const s=la(t,e),i=n.axis||"x",o=n.includeInvisible||!1,a=n.intersect?rv(e,s,i,r,o):sv(e,s,i,!1,r,o),l=[];return a.length?(e.getSortedVisibleDatasetMetas().forEach(u=>{const c=a[0].index,d=u.data[c];d&&!d.skip&&l.push({element:d,datasetIndex:u.index,index:c})}),l):[]},dataset(e,t,n,r){const s=la(t,e),i=n.axis||"xy",o=n.includeInvisible||!1;let a=n.intersect?rv(e,s,i,r,o):sv(e,s,i,!1,r,o);if(a.length>0){const l=a[0].datasetIndex,u=e.getDatasetMeta(l).data;a=[];for(let c=0;c<u.length;++c)a.push({element:u[c],datasetIndex:l,index:c})}return a},point(e,t,n,r){const s=la(t,e),i=n.axis||"xy",o=n.includeInvisible||!1;return rv(e,s,i,r,o)},nearest(e,t,n,r){const s=la(t,e),i=n.axis||"xy",o=n.includeInvisible||!1;return sv(e,s,i,n.intersect,r,o)},x(e,t,n,r){const s=la(t,e);return Bx(e,s,"x",n.intersect,r)},y(e,t,n,r){const s=la(t,e);return Bx(e,s,"y",n.intersect,r)}}};const R2=["left","top","right","bottom"];function ic(e,t){return e.filter(n=>n.pos===t)}function Vx(e,t){return e.filter(n=>R2.indexOf(n.pos)===-1&&n.box.axis===t)}function oc(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 Ete(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 Cte(e){const t={};for(const n of e){const{stack:r,pos:s,stackWeight:i}=n;if(!r||!R2.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 Tte(e,t){const n=Cte(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],c=u&&a.stackWeight/u.weight;a.horizontal?(a.width=c?c*r:l&&t.availableWidth,a.height=s):(a.width=r,a.height=c?c*s:l&&t.availableHeight)}return n}function Pte(e){const t=Ete(e),n=oc(t.filter(u=>u.box.fullSize),!0),r=oc(ic(t,"left"),!0),s=oc(ic(t,"right")),i=oc(ic(t,"top"),!0),o=oc(ic(t,"bottom")),a=Vx(t,"x"),l=Vx(t,"y");return{fullSize:n,leftAndTop:r.concat(i),rightAndBottom:s.concat(l).concat(o).concat(a),chartArea:ic(t,"chartArea"),vertical:r.concat(s).concat(l),horizontal:i.concat(o).concat(a)}}function Ux(e,t,n,r){return Math.max(e[n],t[n])+Math.max(e[r],t[r])}function I2(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 Rte(e,t,n,r){const{pos:s,box:i}=n,o=e.maxPadding;if(!xt(s)){n.size&&(e[s]-=n.size);const d=r[n.stack]||{size:0,count:1};d.size=Math.max(d.size,n.horizontal?i.height:i.width),n.size=d.size/d.count,e[s]+=n.size}i.getPadding&&I2(o,i.getPadding());const a=Math.max(0,t.outerWidth-Ux(o,e,"left","right")),l=Math.max(0,t.outerHeight-Ux(o,e,"top","bottom")),u=a!==e.w,c=l!==e.h;return e.w=a,e.h=l,n.horizontal?{same:u,other:c}:{same:c,other:u}}function Ite(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 Ate(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 gc(e,t,n,r){const s=[];let i,o,a,l,u,c;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,Ate(a.horizontal,t));const{same:d,other:f}=Rte(t,n,a,r);u|=d&&s.length,c=c||f,l.fullSize||s.push(a)}return u&&gc(s,t,n,r)||c}function Af(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 zx(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},c=a.stackWeight/u.weight||1;if(a.horizontal){const d=t.w*c,f=u.size||l.height;hd(u.start)&&(o=u.start),l.fullSize?Af(l,s.left,o,n.outerWidth-s.right-s.left,f):Af(l,t.left+u.placed,o,d,f),u.start=o,u.placed+=d,o=l.bottom}else{const d=t.h*c,f=u.size||l.width;hd(u.start)&&(i=u.start),l.fullSize?Af(l,i,s.top,f,n.outerHeight-s.bottom-s.top):Af(l,i,t.top+u.placed,f,d),u.start=i,u.placed+=d,i=l.right}}t.x=i,t.y=o}var ss={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=ps(e.options.layout.padding),i=Math.max(t-s.width,0),o=Math.max(n-s.height,0),a=Pte(e.boxes),l=a.vertical,u=a.horizontal;It(e.boxes,m=>{typeof m.beforeLayout=="function"&&m.beforeLayout()});const c=l.reduce((m,y)=>y.box.options&&y.box.options.display===!1?m:m+1,0)||1,d=Object.freeze({outerWidth:t,outerHeight:n,padding:s,availableWidth:i,availableHeight:o,vBoxMaxWidth:i/2/c,hBoxMaxHeight:o/2}),f=Object.assign({},s);I2(f,ps(r));const p=Object.assign({maxPadding:f,w:i,h:o,x:s.left,y:s.top},s),g=Tte(l.concat(u),d);gc(a.fullSize,p,d,g),gc(l,p,d,g),gc(u,p,d,g)&&gc(l,p,d,g),Ite(p),zx(a.leftAndTop,p,d,g),p.x+=p.w,p.y+=p.h,zx(a.rightAndBottom,p,d,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 A2{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 Ote extends A2{acquireContext(t){return t&&t.getContext&&t.getContext("2d")||null}updateConfig(t){t.options.animation=!1}}const wh="$chartjs",Mte={touchstart:"mousedown",touchmove:"mousemove",touchend:"mouseup",pointerenter:"mouseenter",pointerdown:"mousedown",pointermove:"mousemove",pointerup:"mouseup",pointerleave:"mouseout",pointerout:"mouseout"},Hx=e=>e===null||e==="";function Dte(e,t){const n=e.style,r=e.getAttribute("height"),s=e.getAttribute("width");if(e[wh]={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",Hx(s)){const i=Rx(e,"width");i!==void 0&&(e.width=i)}if(Hx(r))if(e.style.height==="")e.height=e.width/(t||2);else{const i=Rx(e,"height");i!==void 0&&(e.height=i)}return e}const O2=jee?{passive:!0}:!1;function Lte(e,t,n){e&&e.addEventListener(t,n,O2)}function $te(e,t,n){e&&e.canvas&&e.canvas.removeEventListener(t,n,O2)}function Fte(e,t){const n=Mte[e.type]||e.type,{x:r,y:s}=la(e,t);return{type:n,chart:t,native:e,x:r!==void 0?r:null,y:s!==void 0?s:null}}function kp(e,t){for(const n of e)if(n===t||n.contains(t))return!0}function Nte(e,t,n){const r=e.canvas,s=new MutationObserver(i=>{let o=!1;for(const a of i)o=o||kp(a.addedNodes,r),o=o&&!kp(a.removedNodes,r);o&&n()});return s.observe(document,{childList:!0,subtree:!0}),s}function Bte(e,t,n){const r=e.canvas,s=new MutationObserver(i=>{let o=!1;for(const a of i)o=o||kp(a.removedNodes,r),o=o&&!kp(a.addedNodes,r);o&&n()});return s.observe(document,{childList:!0,subtree:!0}),s}const md=new Map;let jx=0;function M2(){const e=window.devicePixelRatio;e!==jx&&(jx=e,md.forEach((t,n)=>{n.currentDevicePixelRatio!==e&&t()}))}function Vte(e,t){md.size||window.addEventListener("resize",M2),md.set(e,t)}function Ute(e){md.delete(e),md.size||window.removeEventListener("resize",M2)}function zte(e,t,n){const r=e.canvas,s=r&&Ow(r);if(!s)return;const i=d2((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,c=l.contentRect.height;u===0&&c===0||i(u,c)});return o.observe(s),Vte(e,i),o}function iv(e,t,n){n&&n.disconnect(),t==="resize"&&Ute(e)}function Hte(e,t,n){const r=e.canvas,s=d2(i=>{e.ctx!==null&&n(Fte(i,e))},e);return Lte(r,t,s),s}class jte extends A2{acquireContext(t,n){const r=t&&t.getContext&&t.getContext("2d");return r&&r.canvas===t?(Dte(t,n),r):null}releaseContext(t){const n=t.canvas;if(!n[wh])return!1;const r=n[wh].initial;["height","width"].forEach(i=>{const o=r[i];Nt(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[wh],!0}addEventListener(t,n,r){this.removeEventListener(t,n);const s=t.$proxies||(t.$proxies={}),o={attach:Nte,detach:Bte,resize:zte}[n]||Hte;s[n]=o(t,n,r)}removeEventListener(t,n){const r=t.$proxies||(t.$proxies={}),s=r[n];if(!s)return;({attach:iv,detach:iv,resize:iv}[n]||$te)(t,n,s),r[n]=void 0}getDevicePixelRatio(){return window.devicePixelRatio}getMaximumSize(t,n,r,s){return Hee(t,n,r,s)}isAttached(t){const n=t&&Ow(t);return!!(n&&n.isConnected)}}function qte(e){return!Aw()||typeof OffscreenCanvas<"u"&&e instanceof OffscreenCanvas?Ote:jte}var Hf;let qu=(Hf=class{constructor(){we(this,"x");we(this,"y");we(this,"active",!1);we(this,"options");we(this,"$animations")}tooltipPosition(t){const{x:n,y:r}=this.getProps(["x","y"],t);return{x:n,y:r}}hasValue(){return wp(this.x)&&wp(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}},we(Hf,"defaults",{}),we(Hf,"defaultRoutes"),Hf);function Wte(e,t){const n=e.options.ticks,r=Gte(e),s=Math.min(n.maxTicksLimit||r,r),i=n.major.enabled?Yte(t):[],o=i.length,a=i[0],l=i[o-1],u=[];if(o>s)return Xte(t,u,i,o/s),u;const c=Kte(i,t,s);if(o>0){let d,f;const p=o>1?Math.round((l-a)/(o-1)):null;for(Of(t,u,c,Nt(p)?0:a-p,a),d=0,f=o-1;d<f;d++)Of(t,u,c,i[d],i[d+1]);return Of(t,u,c,l,Nt(p)?t.length:l+p),u}return Of(t,u,c),u}function Gte(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 Kte(e,t,n){const r=Qte(e),s=t.length/n;if(!r)return Math.max(s,1);const i=JZ(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 Yte(e){const t=[];let n,r;for(n=0,r=e.length;n<r;n++)e[n].major&&t.push(n);return t}function Xte(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 Of(e,t,n,r,s){const i=At(r,0),o=Math.min(At(s,e.length),e.length);let a=0,l,u,c;for(n=Math.ceil(n),s&&(l=s-r,n=l/Math.floor(l/n)),c=i;c<0;)a++,c=Math.round(i+a*n);for(u=Math.max(i,0);u<o;u++)u===c&&(t.push(e[u]),a++,c=Math.round(i+a*n))}function Qte(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 Jte=e=>e==="left"?"right":e==="right"?"left":e,qx=(e,t,n)=>t==="top"||t==="left"?e[t]+n:e[t]-n,Wx=(e,t)=>Math.min(t||e,e);function Gx(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 Zte(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 ene(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 ac(e){return e.drawTicks?e.tickLength:0}function Kx(e,t){if(!e.display)return 0;const n=er(e.font,t),r=ps(e.padding);return(kn(e.text)?e.text.length:1)*n.lineHeight+r.height}function tne(e,t){return ju(e,{scale:t,type:"scale"})}function nne(e,t,n){return ju(e,{tick:n,index:t,type:"tick"})}function rne(e,t,n){let r=Ew(e);return(n&&t!=="right"||!n&&t==="right")&&(r=Jte(r)),r}function sne(e,t,n,r){const{top:s,left:i,bottom:o,right:a,chart:l}=e,{chartArea:u,scales:c}=l;let d=0,f,p,g;const m=o-s,y=a-i;if(e.isHorizontal()){if(p=Gn(r,i,a),xt(n)){const w=Object.keys(n)[0],b=n[w];g=c[w].getPixelForValue(b)+m-t}else n==="center"?g=(u.bottom+u.top)/2+m-t:g=qx(e,n,t);f=a-i}else{if(xt(n)){const w=Object.keys(n)[0],b=n[w];p=c[w].getPixelForValue(b)-y+t}else n==="center"?p=(u.left+u.right)/2-y+t:p=qx(e,n,t);g=Gn(r,o,s),d=n==="left"?-Ts:Ts}return{titleX:p,titleY:g,maxWidth:f,rotation:d}}class Wu extends qu{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=Ws(t,Number.POSITIVE_INFINITY),n=Ws(n,Number.NEGATIVE_INFINITY),r=Ws(r,Number.POSITIVE_INFINITY),s=Ws(s,Number.NEGATIVE_INFINITY),{min:Ws(t,r),max:Ws(n,s),minDefined:hs(t),maxDefined:hs(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:Ws(n,Ws(r,n)),max:Ws(r,Ws(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(){Xt(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=Pee(this,i,s),this._dataLimitsCached=!0),this.beforeBuildTicks(),this.ticks=this.buildTicks()||[],this.afterBuildTicks();const l=a<this.ticks.length;this._convertTicksToLabels(l?Gx(this.ticks,a):this.ticks),this.configure(),this.beforeCalculateLabelRotation(),this.calculateLabelRotation(),this.afterCalculateLabelRotation(),o.display&&(o.autoSkip||o.source==="auto")&&(this.ticks=Wte(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(){Xt(this.options.afterUpdate,[this])}beforeSetDimensions(){Xt(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(){Xt(this.options.afterSetDimensions,[this])}_callHooks(t){this.chart.notifyPlugins(t,this.getContext()),Xt(this.options[t],[this])}beforeDataLimits(){this._callHooks("beforeDataLimits")}determineDataLimits(){}afterDataLimits(){this._callHooks("afterDataLimits")}beforeBuildTicks(){this._callHooks("beforeBuildTicks")}buildTicks(){return[]}afterBuildTicks(){this._callHooks("afterBuildTicks")}beforeTickToLabelConversion(){Xt(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=Xt(n.callback,[i.value,r,t],this)}afterTickToLabelConversion(){Xt(this.options.afterTickToLabelConversion,[this])}beforeCalculateLabelRotation(){Xt(this.options.beforeCalculateLabelRotation,[this])}calculateLabelRotation(){const t=this.options,n=t.ticks,r=Wx(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 c=this._getLabelSizes(),d=c.widest.width,f=c.highest.height,p=Ps(this.chart.width-d,0,this.maxWidth);a=t.offset?this.maxWidth/r:p/(r-1),d+6>a&&(a=p/(r-(t.offset?.5:1)),l=this.maxHeight-ac(t.grid)-n.padding-Kx(t.title,this.chart.options.font),u=Math.sqrt(d*d+f*f),o=nee(Math.min(Math.asin(Ps((c.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(){Xt(this.options.afterCalculateLabelRotation,[this])}afterAutoSkip(){}beforeFit(){Xt(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=Kx(s,n.options.font);if(a?(t.width=this.maxWidth,t.height=ac(i)+l):(t.height=this.maxHeight,t.width=ac(i)+l),r.display&&this.ticks.length){const{first:u,last:c,widest:d,highest:f}=this._getLabelSizes(),p=r.padding*2,g=ga(this.labelRotation),m=Math.cos(g),y=Math.sin(g);if(a){const w=r.mirror?0:y*d.width+m*f.height;t.height=Math.min(this.maxHeight,t.height+w+p)}else{const w=r.mirror?0:m*d.width+y*f.height;t.width=Math.min(this.maxWidth,t.width+w+p)}this._calculatePadding(u,c,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 c=this.getPixelForTick(0)-this.left,d=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-c+o)*this.width/(this.width-c),0),this.paddingRight=Math.max((p-d+o)*this.width/(this.width-d),0)}else{let c=n.height/2,d=t.height/2;i==="start"?(c=0,d=t.height):i==="end"&&(c=n.height,d=0),this.paddingTop=c+o,this.paddingBottom=d+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(){Xt(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++)Nt(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=Gx(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/Wx(n,r));let u=0,c=0,d,f,p,g,m,y,w,b,k,C,_;for(d=0;d<n;d+=l){if(g=t[d].label,m=this._resolveTickFontOptions(d),s.font=y=m.string,w=i[y]=i[y]||{data:{},gc:[]},b=m.lineHeight,k=C=0,!Nt(g)&&!kn(g))k=kx(s,w.data,w.gc,k,g),C=b;else if(kn(g))for(f=0,p=g.length;f<p;++f)_=g[f],!Nt(_)&&!kn(_)&&(k=kx(s,w.data,w.gc,k,_),C+=b);o.push(k),a.push(C),u=Math.max(k,u),c=Math.max(C,c)}ene(i,n);const T=o.indexOf(u),P=a.indexOf(c),S=E=>({width:o[E]||0,height:a[E]||0});return{first:S(0),last:S(n-1),widest:S(T),highest:S(P),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 oee(this._alignToPixels?ra(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=nne(this.getContext(),t,r))}return this.$context||(this.$context=tne(this.chart.getContext(),this))}_tickSize(){const t=this.options.ticks,n=ga(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(),d=this.ticks.length+(l?1:0),f=ac(i),p=[],g=a.setContext(this.getContext()),m=g.display?g.width:0,y=m/2,w=function(U){return ra(r,U,m)};let b,k,C,_,T,P,S,E,I,O,R,M;if(o==="top")b=w(this.bottom),P=this.bottom-f,E=b-y,O=w(t.top)+y,M=t.bottom;else if(o==="bottom")b=w(this.top),O=t.top,M=w(t.bottom)-y,P=b+y,E=this.top+f;else if(o==="left")b=w(this.right),T=this.right-f,S=b-y,I=w(t.left)+y,R=t.right;else if(o==="right")b=w(this.left),I=t.left,R=w(t.right)-y,T=b+y,S=this.left+f;else if(n==="x"){if(o==="center")b=w((t.top+t.bottom)/2+.5);else if(xt(o)){const U=Object.keys(o)[0],K=o[U];b=w(this.chart.scales[U].getPixelForValue(K))}O=t.top,M=t.bottom,P=b+y,E=P+f}else if(n==="y"){if(o==="center")b=w((t.left+t.right)/2);else if(xt(o)){const U=Object.keys(o)[0],K=o[U];b=w(this.chart.scales[U].getPixelForValue(K))}T=b-y,S=T-f,I=t.left,R=t.right}const D=At(s.ticks.maxTicksLimit,d),F=Math.max(1,Math.ceil(d/D));for(k=0;k<d;k+=F){const U=this.getContext(k),K=i.setContext(U),X=a.setContext(U),H=K.lineWidth,B=K.color,ee=X.dash||[],q=X.dashOffset,G=K.tickWidth,le=K.tickColor,ie=K.tickBorderDash||[],Se=K.tickBorderDashOffset;C=Zte(this,k,l),C!==void 0&&(_=ra(r,C,H),u?T=S=I=R=_:P=E=O=M=_,p.push({tx1:T,ty1:P,tx2:S,ty2:E,x1:I,y1:O,x2:R,y2:M,width:H,color:B,borderDash:ee,borderDashOffset:q,tickWidth:G,tickColor:le,tickBorderDash:ie,tickBorderDashOffset:Se}))}return this._ticksLength=d,this._borderValue=b,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:c,mirror:d}=i,f=ac(r.grid),p=f+c,g=d?-c:p,m=-ga(this.labelRotation),y=[];let w,b,k,C,_,T,P,S,E,I,O,R,M="middle";if(s==="top")T=this.bottom-g,P=this._getXAxisLabelAlignment();else if(s==="bottom")T=this.top+g,P=this._getXAxisLabelAlignment();else if(s==="left"){const F=this._getYAxisLabelAlignment(f);P=F.textAlign,_=F.x}else if(s==="right"){const F=this._getYAxisLabelAlignment(f);P=F.textAlign,_=F.x}else if(n==="x"){if(s==="center")T=(t.top+t.bottom)/2+p;else if(xt(s)){const F=Object.keys(s)[0],U=s[F];T=this.chart.scales[F].getPixelForValue(U)+p}P=this._getXAxisLabelAlignment()}else if(n==="y"){if(s==="center")_=(t.left+t.right)/2-p;else if(xt(s)){const F=Object.keys(s)[0],U=s[F];_=this.chart.scales[F].getPixelForValue(U)}P=this._getYAxisLabelAlignment(f).textAlign}n==="y"&&(l==="start"?M="top":l==="end"&&(M="bottom"));const D=this._getLabelSizes();for(w=0,b=a.length;w<b;++w){k=a[w],C=k.label;const F=i.setContext(this.getContext(w));S=this.getPixelForTick(w)+i.labelOffset,E=this._resolveTickFontOptions(w),I=E.lineHeight,O=kn(C)?C.length:1;const U=O/2,K=F.color,X=F.textStrokeColor,H=F.textStrokeWidth;let B=P;o?(_=S,P==="inner"&&(w===b-1?B=this.options.reverse?"left":"right":w===0?B=this.options.reverse?"right":"left":B="center"),s==="top"?u==="near"||m!==0?R=-O*I+I/2:u==="center"?R=-D.highest.height/2-U*I+I:R=-D.highest.height+I/2:u==="near"||m!==0?R=I/2:u==="center"?R=D.highest.height/2-U*I:R=D.highest.height-O*I,d&&(R*=-1),m!==0&&!F.showLabelBackdrop&&(_+=I/2*Math.sin(m))):(T=S,R=(1-O)*I/2);let ee;if(F.showLabelBackdrop){const q=ps(F.backdropPadding),G=D.heights[w],le=D.widths[w];let ie=R-q.top,Se=0-q.left;switch(M){case"middle":ie-=G/2;break;case"bottom":ie-=G;break}switch(P){case"center":Se-=le/2;break;case"right":Se-=le;break;case"inner":w===b-1?Se-=le:w>0&&(Se-=le/2);break}ee={left:Se,top:ie,width:le+q.width,height:G+q.height,color:F.backdropColor}}y.push({label:C,font:E,textOffset:R,options:{rotation:m,color:K,strokeColor:X,strokeWidth:H,textAlign:B,textBaseline:M,translation:[_,T],backdrop:ee}})}return y}_getXAxisLabelAlignment(){const{position:t,ticks:n}=this.options;if(-ga(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,c;return n==="left"?s?(c=this.right+i,r==="near"?u="left":r==="center"?(u="center",c+=l/2):(u="right",c+=l)):(c=this.right-a,r==="near"?u="right":r==="center"?(u="center",c-=l/2):(u="left",c=this.left)):n==="right"?s?(c=this.left+i,r==="near"?u="right":r==="center"?(u="center",c-=l/2):(u="left",c-=l)):(c=this.left+a,r==="near"?u="left":r==="center"?(u="center",c+=l/2):(u="right",c=this.right)):u="right",{textAlign:u,x:c}}_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,c)=>{!c.width||!c.color||(r.save(),r.lineWidth=c.width,r.strokeStyle=c.color,r.setLineDash(c.borderDash||[]),r.lineDashOffset=c.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,c,d,f;this.isHorizontal()?(u=ra(t,this.left,o)-o/2,c=ra(t,this.right,a)+a/2,d=f=l):(d=ra(t,this.top,o)-o/2,f=ra(t,this.bottom,a)+a/2,u=c=l),n.save(),n.lineWidth=i.width,n.strokeStyle=i.color,n.beginPath(),n.moveTo(u,d),n.lineTo(c,f),n.stroke(),n.restore()}drawLabels(t){if(!this.options.ticks.display)return;const r=this.ctx,s=this._computeLabelArea();s&&Cw(r,s);const i=this.getLabelItems(t);for(const o of i){const a=o.options,l=o.font,u=o.label,c=o.textOffset;pd(r,u,0,c,l,a)}s&&Tw(r)}drawTitle(){const{ctx:t,options:{position:n,title:r,reverse:s}}=this;if(!r.display)return;const i=er(r.font),o=ps(r.padding),a=r.align;let l=i.lineHeight/2;n==="bottom"||n==="center"||xt(n)?(l+=o.bottom,kn(r.text)&&(l+=i.lineHeight*(r.text.length-1))):l+=o.top;const{titleX:u,titleY:c,maxWidth:d,rotation:f}=sne(this,l,n,a);pd(t,r.text,0,0,i,{color:r.color,maxWidth:d,rotation:f,textAlign:rne(a,n,s),textBaseline:"middle",translation:[u,c]})}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=At(t.grid&&t.grid.z,-1),s=At(t.border&&t.border.z,0);return!this._isVisible()||this.draw!==Wu.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 er(n.font)}_maxDigits(){const t=this._resolveTickFontOptions(0).lineHeight;return(this.isHorizontal()?this.width:this.height)/t}}class Mf{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;ane(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,ine(t,o,r),this.override&&gn.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 gn[s]&&(delete gn[s][r],this.override&&delete Xa[r])}}function ine(e,t,n){const r=fd(Object.create(null),[n?gn.get(n):{},gn.get(t),e.defaults]);gn.set(t,r),e.defaultRoutes&&one(t,e.defaultRoutes),e.descriptors&&gn.describe(t,e.descriptors)}function one(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(".");gn.route(i,s,l,a)})}function ane(e){return"id"in e&&"defaults"in e}class lne{constructor(){this.controllers=new Mf(Nc,"datasets",!0),this.elements=new Mf(qu,"elements"),this.plugins=new Mf(Object,"plugins"),this.scales=new Mf(Wu,"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=kw(t);Xt(r["before"+s],[],r),n[t](r),Xt(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 Qs=new lne;class une{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(Xt(a,l,o)===!1&&s.cancelable)return!1}return!0}invalidate(){Nt(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=At(r.options&&r.options.plugins,{}),i=cne(r);return s===!1&&!n?[]:fne(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 cne(e){const t={},n=[],r=Object.keys(Qs.plugins.items);for(let i=0;i<r.length;i++)n.push(Qs.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 dne(e,t){return!t&&e===!1?null:e===!0?{}:e}function fne(e,{plugins:t,localIds:n},r,s){const i=[],o=e.getContext();for(const a of t){const l=a.id,u=dne(r[l],s);u!==null&&i.push({plugin:a,options:hne(e.config,{plugin:a,local:n[l]},u,o)})}return i}function hne(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 wb(e,t){const n=gn.datasets[e]||{};return((t.datasets||{})[e]||{}).indexAxis||t.indexAxis||n.indexAxis||"x"}function pne(e,t){let n=e;return e==="_index_"?n=t:e==="_value_"&&(n=t==="x"?"y":"x"),n}function mne(e,t){return e===t?"_index_":"_value_"}function Yx(e){if(e==="x"||e==="y"||e==="r")return e}function gne(e){if(e==="top"||e==="bottom")return"x";if(e==="left"||e==="right")return"y"}function Sb(e,...t){if(Yx(e))return e;for(const n of t){const r=n.axis||gne(n.position)||e.length>1&&Yx(e[0].toLowerCase());if(r)return r}throw new Error(`Cannot determine type of '${e}' axis. Please provide 'axis' or 'position' option.`)}function Xx(e,t,n){if(n[t+"AxisID"]===e)return{axis:t}}function vne(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 Xx(e,"x",n[0])||Xx(e,"y",n[0])}return{}}function yne(e,t){const n=Xa[e.type]||{scales:{}},r=t.scales||{},s=wb(e.type,t),i=Object.create(null);return Object.keys(r).forEach(o=>{const a=r[o];if(!xt(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=Sb(o,a,vne(o,e),gn.scales[a.type]),u=mne(l,s),c=n.scales||{};i[o]=Lc(Object.create(null),[{axis:l},a,c[l],c[u]])}),e.data.datasets.forEach(o=>{const a=o.type||e.type,l=o.indexAxis||wb(a,t),c=(Xa[a]||{}).scales||{};Object.keys(c).forEach(d=>{const f=pne(d,l),p=o[f+"AxisID"]||f;i[p]=i[p]||Object.create(null),Lc(i[p],[{axis:f},r[p],c[d]])})}),Object.keys(i).forEach(o=>{const a=i[o];Lc(a,[gn.scales[a.type],gn.scale])}),i}function D2(e){const t=e.options||(e.options={});t.plugins=At(t.plugins,{}),t.scales=yne(e,t)}function L2(e){return e=e||{},e.datasets=e.datasets||[],e.labels=e.labels||[],e}function bne(e){return e=e||{},e.data=L2(e.data),D2(e),e}const Qx=new Map,$2=new Set;function Df(e,t){let n=Qx.get(e);return n||(n=t(),Qx.set(e,n),$2.add(n)),n}const lc=(e,t,n)=>{const r=bu(t,n);r!==void 0&&e.add(r)};class wne{constructor(t){this._config=bne(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=L2(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(),D2(t)}clearCache(){this._scopeCache.clear(),this._resolverCache.clear()}datasetScopeKeys(t){return Df(t,()=>[[`datasets.${t}`,""]])}datasetAnimationScopeKeys(t,n){return Df(`${t}.transition.${n}`,()=>[[`datasets.${t}.transitions.${n}`,`transitions.${n}`],[`datasets.${t}`,""]])}datasetElementScopeKeys(t,n){return Df(`${t}-${n}`,()=>[[`datasets.${t}.elements.${n}`,`datasets.${t}`,`elements.${n}`,""]])}pluginScopeKeys(t){const n=t.id,r=this.type;return Df(`${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(c=>{t&&(l.add(t),c.forEach(d=>lc(l,t,d))),c.forEach(d=>lc(l,s,d)),c.forEach(d=>lc(l,Xa[i]||{},d)),c.forEach(d=>lc(l,gn,d)),c.forEach(d=>lc(l,bb,d))});const u=Array.from(l);return u.length===0&&u.push(Object.create(null)),$2.has(n)&&o.set(n,u),u}chartOptionScopes(){const{options:t,type:n}=this;return[t,Xa[n]||{},gn.datasets[n]||{},{type:n},gn,bb]}resolveNamedOptions(t,n,r,s=[""]){const i={$shared:!0},{resolver:o,subPrefixes:a}=Jx(this._resolverCache,t,s);let l=o;if(_ne(o,n)){i.$shared=!1,r=Fo(r)?r():r;const u=this.createResolver(t,r,a);l=wu(o,r,u)}for(const u of n)i[u]=l[u];return i}createResolver(t,n,r=[""],s){const{resolver:i}=Jx(this._resolverCache,t,r);return xt(n)?wu(i,n,void 0,s):i}}function Jx(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:Pw(t,n),subPrefixes:n.filter(a=>!a.toLowerCase().includes("hover"))},r.set(s,i)),i}const Sne=e=>xt(e)&&Object.getOwnPropertyNames(e).some(t=>Fo(e[t]));function _ne(e,t){const{isScriptable:n,isIndexable:r}=w2(e);for(const s of t){const i=n(s),o=r(s),a=(o||i)&&e[s];if(i&&(Fo(a)||Sne(a))||o&&kn(a))return!0}return!1}var kne="4.4.9";const xne=["top","bottom","left","right","chartArea"];function Zx(e,t){return e==="top"||e==="bottom"||xne.indexOf(e)===-1&&t==="x"}function eE(e,t){return function(n,r){return n[e]===r[e]?n[t]-r[t]:n[e]-r[e]}}function tE(e){const t=e.chart,n=t.options.animation;t.notifyPlugins("afterRender"),Xt(n&&n.onComplete,[e],t)}function Ene(e){const t=e.chart,n=t.options.animation;Xt(n&&n.onProgress,[e],t)}function F2(e){return Aw()&&typeof e=="string"?e=document.getElementById(e):e&&e.length&&(e=e[0]),e&&e.canvas&&(e=e.canvas),e}const Sh={},nE=e=>{const t=F2(e);return Object.values(Sh).filter(n=>n.canvas===t).pop()};function Cne(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 Tne(e,t,n,r){return!n||e.type==="mouseout"?null:r?t:e}var eo;let Nm=(eo=class{static register(...t){Qs.add(...t),rE()}static unregister(...t){Qs.remove(...t),rE()}constructor(t,n){const r=this.config=new wne(n),s=F2(t),i=nE(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||qte(s)),this.platform.updateConfig(r);const a=this.platform.acquireContext(s,o.aspectRatio),l=a&&a.canvas,u=l&&l.height,c=l&&l.width;if(this.id=jZ(),this.ctx=a,this.canvas=l,this.width=c,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 une,this.$proxies={},this._hiddenIndices={},this.attached=!1,this._animationsDisabled=void 0,this.$context=void 0,this._doResize=cee(d=>this.update(d),o.resizeDelay||0),this._dataChanges=[],Sh[this.id]=this,!a||!l){console.error("Failed to create chart: can't acquire context from the given item");return}xi.listen(this,"complete",tE),xi.listen(this,"progress",Ene),this._initialize(),this.attached&&this.update()}get aspectRatio(){const{options:{aspectRatio:t,maintainAspectRatio:n},width:r,height:s,_aspectRatio:i}=this;return Nt(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 Qs}_initialize(){return this.notifyPlugins("beforeInit"),this.options.responsive?this.resize():Px(this,this.options.devicePixelRatio),this.bindEvents(),this.notifyPlugins("afterInit"),this}clear(){return xx(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,Px(this,a,!0)&&(this.notifyPlugins("resize",{size:o}),Xt(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=Sb(o,a),u=l==="r",c=l==="x";return{options:a,dposition:u?"chartArea":c?"bottom":"left",dtype:u?"radialLinear":c?"category":"linear"}}))),It(i,o=>{const a=o.options,l=a.id,u=Sb(l,a),c=At(a.type,o.dtype);(a.position===void 0||Zx(a.position,u)!==Zx(o.dposition))&&(a.position=o.dposition),s[l]=!0;let d=null;if(l in r&&r[l].type===c)d=r[l];else{const f=Qs.getScale(c);d=new f({id:l,type:c,ctx:this.ctx,chart:this}),r[d.id]=d}d.init(a,t)}),It(s,(o,a)=>{o||delete r[a]}),It(r,o=>{ss.configure(this,o,o.options),ss.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(eE("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||wb(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=Qs.getController(a),{datasetElementType:u,dataElementType:c}=gn.datasets[a];Object.assign(l,{dataElementType:Qs.getElement(c),datasetElementType:u&&Qs.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,c=this.data.datasets.length;u<c;u++){const{controller:d}=this.getDatasetMeta(u),f=!s&&i.indexOf(d)===-1;d.buildOrUpdateElements(f),o=Math.max(+d.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(eE("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=>{ss.removeBox(this,t)}),this.ensureScalesHaveIDs(),this.buildOrUpdateScales()}_checkEventBindings(){const t=this.options,n=new Set(Object.keys(this._listeners)),r=new Set(t.events);(!px(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;Cne(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(!px(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;ss.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,Fo(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(),tE({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={meta:t,index:t.index,cancelable:!0},s=Kee(this,t);this.notifyPlugins("beforeDatasetDraw",r)!==!1&&(s&&Cw(n,s),t.controller.draw(),s&&Tw(n),r.cancelable=!1,this.notifyPlugins("afterDatasetDraw",r))}isPointInArea(t){return v2(t,this.chartArea,this._minPadding)}getElementsAtEventForMode(t,n,r,s){const i=xte.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=ju(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);hd(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(),xx(t,n),this.platform.releaseContext(n),this.canvas=null,this.ctx=null),delete Sh[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}});!vp(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(c=>!u.some(d=>c.datasetIndex===d.datasetIndex&&c.index===d.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=XZ(t),u=Tne(t,this._lastEvent,r,l);r&&(this._lastEvent=null,Xt(i.onHover,[t,a,this],this),l&&Xt(i.onClick,[t,a,this],this));const c=!vp(a,s);return(c||n)&&(this._active=a,this._updateHoverStyles(a,s,n)),this._lastEvent=u,c}_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)}},we(eo,"defaults",gn),we(eo,"instances",Sh),we(eo,"overrides",Xa),we(eo,"registry",Qs),we(eo,"version",kne),we(eo,"getChart",nE),eo);function rE(){return It(Nm.instances,e=>e._plugins.invalidate())}function N2(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,c,d;return e.horizontal?(d=o/2,a=Math.min(n,s),l=Math.max(n,s),u=r-d,c=r+d):(d=i/2,a=n-d,l=n+d,u=Math.min(r,s),c=Math.max(r,s)),{left:a,top:u,right:l,bottom:c}}function ko(e,t,n,r){return e?0:Ps(t,n,r)}function Pne(e,t,n){const r=e.options.borderWidth,s=e.borderSkipped,i=b2(r);return{t:ko(s.top,i.top,0,n),r:ko(s.right,i.right,0,t),b:ko(s.bottom,i.bottom,0,n),l:ko(s.left,i.left,0,t)}}function Rne(e,t,n){const{enableBorderRadius:r}=e.getProps(["enableBorderRadius"]),s=e.options.borderRadius,i=Vl(s),o=Math.min(t,n),a=e.borderSkipped,l=r||xt(s);return{topLeft:ko(!l||a.top||a.left,i.topLeft,0,o),topRight:ko(!l||a.top||a.right,i.topRight,0,o),bottomLeft:ko(!l||a.bottom||a.left,i.bottomLeft,0,o),bottomRight:ko(!l||a.bottom||a.right,i.bottomRight,0,o)}}function Ine(e){const t=N2(e),n=t.right-t.left,r=t.bottom-t.top,s=Pne(e,n/2,r/2),i=Rne(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 ov(e,t,n,r){const s=t===null,i=n===null,a=e&&!(s&&i)&&N2(e,r);return a&&(s||Ml(t,a.left,a.right))&&(i||Ml(n,a.top,a.bottom))}function Ane(e){return e.topLeft||e.topRight||e.bottomLeft||e.bottomRight}function One(e,t){e.rect(t.x,t.y,t.w,t.h)}function av(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 _h extends qu{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}=Ine(this),a=Ane(o.radius)?Sp:One;t.save(),(o.w!==i.w||o.h!==i.h)&&(t.beginPath(),a(t,av(o,n,i)),t.clip(),a(t,av(i,-n,o)),t.fillStyle=r,t.fill("evenodd")),t.beginPath(),a(t,av(i,n)),t.fillStyle=s,t.fill(),t.restore()}inRange(t,n,r){return ov(this,t,n,r)}inXRange(t,n){return ov(this,t,null,n)}inYRange(t,n){return ov(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}}we(_h,"id","bar"),we(_h,"defaults",{borderSkipped:"start",borderWidth:0,borderRadius:0,inflateAmount:"auto",pointStyle:void 0}),we(_h,"defaultRoutes",{backgroundColor:"backgroundColor",borderColor:"borderColor"});const sE=(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)}},Mne=(e,t)=>e!==null&&t!==null&&e.datasetIndex===t.datasetIndex&&e.index===t.index;class iE extends qu{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=Xt(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=er(r.font),i=s.size,o=this._computeTitleHeight(),{boxWidth:a,itemHeight:l}=sE(r,i);let u,c;n.font=s.string,this.isHorizontal()?(u=this.maxWidth,c=this._fitRows(o,i,a,l)+10):(c=this.maxHeight,u=this._fitCols(o,s,a,l)+10),this.width=Math.min(u,t.maxWidth||this.maxWidth),this.height=Math.min(c,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],c=s+a;let d=t;i.textAlign="left",i.textBaseline="middle";let f=-1,p=-c;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)&&(d+=c,u[u.length-(m>0?0:1)]=0,p+=c,f++),l[m]={left:0,top:p,row:f,width:y,height:s},u[u.length-1]+=y+a}),d}_fitCols(t,n,r,s){const{ctx:i,maxHeight:o,options:{labels:{padding:a}}}=this,l=this.legendHitBoxes=[],u=this.columnSizes=[],c=o-t;let d=a,f=0,p=0,g=0,m=0;return this.legendItems.forEach((y,w)=>{const{itemWidth:b,itemHeight:k}=Dne(r,n,i,y,s);w>0&&p+k+2*a>c&&(d+=f+a,u.push({width:f,height:p}),g+=f+a,m++,f=p=0),l[w]={left:g,top:p,col:m,width:b,height:k},f=Math.max(f,b),p+=k+a}),d+=f,u.push({width:f,height:p}),d}adjustHitBoxes(){if(!this.options.display)return;const t=this._computeTitleHeight(),{legendHitBoxes:n,options:{align:r,labels:{padding:s},rtl:i}}=this,o=Ul(i,this.left,this.width);if(this.isHorizontal()){let a=0,l=Gn(r,this.left+s,this.right-this.lineWidths[a]);for(const u of n)a!==u.row&&(a=u.row,l=Gn(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=Gn(r,this.top+t+s,this.bottom-this.columnSizes[a].height);for(const u of n)u.col!==a&&(a=u.col,l=Gn(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;Cw(t,this),this._draw(),Tw(t)}}_draw(){const{options:t,columnSizes:n,lineWidths:r,ctx:s}=this,{align:i,labels:o}=t,a=gn.color,l=Ul(t.rtl,this.left,this.width),u=er(o.font),{padding:c}=o,d=u.size,f=d/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}=sE(o,d),w=function(T,P,S){if(isNaN(g)||g<=0||isNaN(m)||m<0)return;s.save();const E=At(S.lineWidth,1);if(s.fillStyle=At(S.fillStyle,a),s.lineCap=At(S.lineCap,"butt"),s.lineDashOffset=At(S.lineDashOffset,0),s.lineJoin=At(S.lineJoin,"miter"),s.lineWidth=E,s.strokeStyle=At(S.strokeStyle,a),s.setLineDash(At(S.lineDash,[])),o.usePointStyle){const I={radius:m*Math.SQRT2/2,pointStyle:S.pointStyle,rotation:S.rotation,borderWidth:E},O=l.xPlus(T,g/2),R=P+f;g2(s,I,O,R,o.pointStyleWidth&&g)}else{const I=P+Math.max((d-m)/2,0),O=l.leftForLtr(T,g),R=Vl(S.borderRadius);s.beginPath(),Object.values(R).some(M=>M!==0)?Sp(s,{x:O,y:I,w:g,h:m,radius:R}):s.rect(O,I,g,m),s.fill(),E!==0&&s.stroke()}s.restore()},b=function(T,P,S){pd(s,S.text,T,P+y/2,u,{strikethrough:S.hidden,textAlign:l.textAlign(S.textAlign)})},k=this.isHorizontal(),C=this._computeTitleHeight();k?p={x:Gn(i,this.left+c,this.right-r[0]),y:this.top+c+C,line:0}:p={x:this.left+c,y:Gn(i,this.top+C+c,this.bottom-n[0].height),line:0},x2(this.ctx,t.textDirection);const _=y+c;this.legendItems.forEach((T,P)=>{s.strokeStyle=T.fontColor,s.fillStyle=T.fontColor;const S=s.measureText(T.text).width,E=l.textAlign(T.textAlign||(T.textAlign=o.textAlign)),I=g+f+S;let O=p.x,R=p.y;l.setWidth(this.width),k?P>0&&O+I+c>this.right&&(R=p.y+=_,p.line++,O=p.x=Gn(i,this.left+c,this.right-r[p.line])):P>0&&R+_>this.bottom&&(O=p.x=O+n[p.line].width+c,p.line++,R=p.y=Gn(i,this.top+C+c,this.bottom-n[p.line].height));const M=l.x(O);if(w(M,R,T),O=dee(E,O+g+f,k?O+I:this.right,t.rtl),b(l.x(O),R,T),k)p.x+=I+c;else if(typeof T.text!="string"){const D=u.lineHeight;p.y+=B2(T,D)+c}else p.y+=_}),E2(this.ctx,t.textDirection)}drawTitle(){const t=this.options,n=t.title,r=er(n.font),s=ps(n.padding);if(!n.display)return;const i=Ul(t.rtl,this.left,this.width),o=this.ctx,a=n.position,l=r.size/2,u=s.top+l;let c,d=this.left,f=this.width;if(this.isHorizontal())f=Math.max(...this.lineWidths),c=this.top+u,d=Gn(t.align,d,this.right-f);else{const g=this.columnSizes.reduce((m,y)=>Math.max(m,y.height),0);c=u+Gn(t.align,this.top,this.bottom-g-t.labels.padding-this._computeTitleHeight())}const p=Gn(a,d,d+f);o.textAlign=i.textAlign(Ew(a)),o.textBaseline="middle",o.strokeStyle=n.color,o.fillStyle=n.color,o.font=r.string,pd(o,n.text,p,c,r)}_computeTitleHeight(){const t=this.options.title,n=er(t.font),r=ps(t.padding);return t.display?n.lineHeight+r.height:0}_getLegendItemAt(t,n){let r,s,i;if(Ml(t,this.left,this.right)&&Ml(n,this.top,this.bottom)){for(i=this.legendHitBoxes,r=0;r<i.length;++r)if(s=i[r],Ml(t,s.left,s.left+s.width)&&Ml(n,s.top,s.top+s.height))return this.legendItems[r]}return null}handleEvent(t){const n=this.options;if(!Fne(t.type,n))return;const r=this._getLegendItemAt(t.x,t.y);if(t.type==="mousemove"||t.type==="mouseout"){const s=this._hoveredItem,i=Mne(s,r);s&&!i&&Xt(n.onLeave,[t,s,this],this),this._hoveredItem=r,r&&!i&&Xt(n.onHover,[t,r,this],this)}else r&&Xt(n.onClick,[t,r,this],this)}}function Dne(e,t,n,r,s){const i=Lne(r,e,t,n),o=$ne(s,r,t.lineHeight);return{itemWidth:i,itemHeight:o}}function Lne(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 $ne(e,t,n){let r=e;return typeof t.text!="string"&&(r=B2(t,n)),r}function B2(e,t){const n=e.text?e.text.length:0;return t*n}function Fne(e,t){return!!((e==="mousemove"||e==="mouseout")&&(t.onHover||t.onLeave)||t.onClick&&(e==="click"||e==="mouseup"))}var Nne={id:"legend",_element:iE,start(e,t,n){const r=e.legend=new iE({ctx:e.ctx,options:n,chart:e});ss.configure(e,r,n),ss.addBox(e,r)},stop(e){ss.removeBox(e,e.legend),delete e.legend},beforeUpdate(e,t,n){const r=e.legend;ss.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),c=ps(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:(c.width+c.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 V2 extends qu{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=kn(r.text)?r.text.length:1;this._padding=ps(r.padding);const i=s*er(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,c,d;return this.isHorizontal()?(c=Gn(a,r,i),d=n+t,u=i-r):(o.position==="left"?(c=r+t,d=Gn(a,s,n),l=rr*-.5):(c=i-t,d=Gn(a,n,s),l=rr*.5),u=s-n),{titleX:c,titleY:d,maxWidth:u,rotation:l}}draw(){const t=this.ctx,n=this.options;if(!n.display)return;const r=er(n.font),i=r.lineHeight/2+this._padding.top,{titleX:o,titleY:a,maxWidth:l,rotation:u}=this._drawArgs(i);pd(t,n.text,0,0,r,{color:n.color,maxWidth:l,rotation:u,textAlign:Ew(n.align),textBaseline:"middle",translation:[o,a]})}}function Bne(e,t){const n=new V2({ctx:e.ctx,options:t,chart:e});ss.configure(e,n,t),ss.addBox(e,n),e.titleBlock=n}var Vne={id:"title",_element:V2,start(e,t,n){Bne(e,n)},stop(e){const t=e.titleBlock;ss.removeBox(e,t),delete e.titleBlock},beforeUpdate(e,t,n){const r=e.titleBlock;ss.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 vc={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(),c=see(t,u);c<s&&(s=c,a=l)}}if(a){const l=a.tooltipPosition();n=l.x,r=l.y}return{x:n,y:r}}};function Ks(e,t){return t&&(kn(t)?Array.prototype.push.apply(e,t):e.push(t)),e}function Ei(e){return(typeof e=="string"||e instanceof String)&&e.indexOf(`
|
|
86
|
+
`)>-1?e.split(`
|
|
87
|
+
`):e}function Une(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 oE(e,t){const n=e.chart.ctx,{body:r,footer:s,title:i}=e,{boxWidth:o,boxHeight:a}=t,l=er(t.bodyFont),u=er(t.titleFont),c=er(t.footerFont),d=i.length,f=s.length,p=r.length,g=ps(t.padding);let m=g.height,y=0,w=r.reduce((C,_)=>C+_.before.length+_.lines.length+_.after.length,0);if(w+=e.beforeBody.length+e.afterBody.length,d&&(m+=d*u.lineHeight+(d-1)*t.titleSpacing+t.titleMarginBottom),w){const C=t.displayColors?Math.max(a,l.lineHeight):l.lineHeight;m+=p*C+(w-p)*l.lineHeight+(w-1)*t.bodySpacing}f&&(m+=t.footerMarginTop+f*c.lineHeight+(f-1)*t.footerSpacing);let b=0;const k=function(C){y=Math.max(y,n.measureText(C).width+b)};return n.save(),n.font=u.string,It(e.title,k),n.font=l.string,It(e.beforeBody.concat(e.afterBody),k),b=t.displayColors?o+2+t.boxPadding:0,It(r,C=>{It(C.before,k),It(C.lines,k),It(C.after,k)}),b=0,n.font=c.string,It(e.footer,k),n.restore(),y+=g.width,{width:y,height:m}}function zne(e,t){const{y:n,height:r}=t;return n<r/2?"top":n>e.height-r/2?"bottom":"center"}function Hne(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 jne(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"),Hne(u,e,t,n)&&(u="center"),u}function aE(e,t,n){const r=n.yAlign||t.yAlign||zne(e,n);return{xAlign:n.xAlign||t.xAlign||jne(e,t,n,r),yAlign:r}}function qne(e,t){let{x:n,width:r}=e;return t==="right"?n-=r:t==="center"&&(n-=r/2),n}function Wne(e,t,n){let{y:r,height:s}=e;return t==="top"?r+=n:t==="bottom"?r-=s+n:r-=s/2,r}function lE(e,t,n,r){const{caretSize:s,caretPadding:i,cornerRadius:o}=e,{xAlign:a,yAlign:l}=n,u=s+i,{topLeft:c,topRight:d,bottomLeft:f,bottomRight:p}=Vl(o);let g=qne(t,a);const m=Wne(t,l,u);return l==="center"?a==="left"?g+=u:a==="right"&&(g-=u):a==="left"?g-=Math.max(c,f)+s:a==="right"&&(g+=Math.max(d,p)+s),{x:Ps(g,0,r.width-t.width),y:Ps(m,0,r.height-t.height)}}function Lf(e,t,n){const r=ps(n.padding);return t==="center"?e.x+e.width/2:t==="right"?e.x+e.width-r.right:e.x+r.left}function uE(e){return Ks([],Ei(e))}function Gne(e,t,n){return ju(e,{tooltip:t,tooltipItems:n,type:"tooltip"})}function cE(e,t){const n=t&&t.dataset&&t.dataset.tooltip&&t.dataset.tooltip.callbacks;return n?e.override(n):e}const U2={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 Nt(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 yr(e,t,n,r){const s=e[t].call(n,r);return typeof s>"u"?U2[t].call(n,r):s}var gv;let dE=(gv=class extends qu{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 C2(this.chart,s);return s._cacheable&&(this._cachedAnimations=Object.freeze(i)),i}getContext(){return this.$context||(this.$context=Gne(this.chart.getContext(),this,this._tooltipItems))}getTitle(t,n){const{callbacks:r}=n,s=yr(r,"beforeTitle",this,t),i=yr(r,"title",this,t),o=yr(r,"afterTitle",this,t);let a=[];return a=Ks(a,Ei(s)),a=Ks(a,Ei(i)),a=Ks(a,Ei(o)),a}getBeforeBody(t,n){return uE(yr(n.callbacks,"beforeBody",this,t))}getBody(t,n){const{callbacks:r}=n,s=[];return It(t,i=>{const o={before:[],lines:[],after:[]},a=cE(r,i);Ks(o.before,Ei(yr(a,"beforeLabel",this,i))),Ks(o.lines,yr(a,"label",this,i)),Ks(o.after,Ei(yr(a,"afterLabel",this,i))),s.push(o)}),s}getAfterBody(t,n){return uE(yr(n.callbacks,"afterBody",this,t))}getFooter(t,n){const{callbacks:r}=n,s=yr(r,"beforeFooter",this,t),i=yr(r,"footer",this,t),o=yr(r,"afterFooter",this,t);let a=[];return a=Ks(a,Ei(s)),a=Ks(a,Ei(i)),a=Ks(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(Une(this.chart,n[l]));return t.filter&&(a=a.filter((c,d,f)=>t.filter(c,d,f,r))),t.itemSort&&(a=a.sort((c,d)=>t.itemSort(c,d,r))),It(a,c=>{const d=cE(t.callbacks,c);s.push(yr(d,"labelColor",this,c)),i.push(yr(d,"labelPointStyle",this,c)),o.push(yr(d,"labelTextColor",this,c))}),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=vc[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=oE(this,r),u=Object.assign({},a,l),c=aE(this.chart,r,u),d=lE(r,u,c,this.chart);this.xAlign=c.xAlign,this.yAlign=c.yAlign,i={opacity:1,x:d.x,y:d.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:c,bottomRight:d}=Vl(a),{x:f,y:p}=t,{width:g,height:m}=n;let y,w,b,k,C,_;return i==="center"?(C=p+m/2,s==="left"?(y=f,w=y-o,k=C+o,_=C-o):(y=f+g,w=y+o,k=C-o,_=C+o),b=y):(s==="left"?w=f+Math.max(l,c)+o:s==="right"?w=f+g-Math.max(u,d)-o:w=this.caretX,i==="top"?(k=p,C=k-o,y=w-o,b=w+o):(k=p+m,C=k+o,y=w+o,b=w-o),_=k),{x1:y,x2:w,x3:b,y1:k,y2:C,y3:_}}drawTitle(t,n,r){const s=this.title,i=s.length;let o,a,l;if(i){const u=Ul(r.rtl,this.x,this.width);for(t.x=Lf(this,r.titleAlign,r),n.textAlign=u.textAlign(r.titleAlign),n.textBaseline="middle",o=er(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,c=er(i.bodyFont),d=Lf(this,"left",i),f=s.x(d),p=l<c.lineHeight?(c.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,w=g+l/2;t.strokeStyle=i.multiKeyBackground,t.fillStyle=i.multiKeyBackground,Ex(t,m,y,w),t.strokeStyle=o.borderColor,t.fillStyle=o.backgroundColor,Ex(t,m,y,w)}else{t.lineWidth=xt(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),w=Vl(o.borderRadius);Object.values(w).some(b=>b!==0)?(t.beginPath(),t.fillStyle=i.multiKeyBackground,Sp(t,{x:m,y:g,w:u,h:l,radius:w}),t.fill(),t.stroke(),t.fillStyle=o.backgroundColor,t.beginPath(),Sp(t,{x:y,y:g+1,w:u-2,h:l-2,radius:w}),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:c}=r,d=er(r.bodyFont);let f=d.lineHeight,p=0;const g=Ul(r.rtl,this.x,this.width),m=function(S){n.fillText(S,g.x(t.x+p),t.y+f/2),t.y+=f+i},y=g.textAlign(o);let w,b,k,C,_,T,P;for(n.textAlign=o,n.textBaseline="middle",n.font=d.string,t.x=Lf(this,y,r),n.fillStyle=r.bodyColor,It(this.beforeBody,m),p=a&&y!=="right"?o==="center"?u/2+c:u+2+c:0,C=0,T=s.length;C<T;++C){for(w=s[C],b=this.labelTextColors[C],n.fillStyle=b,It(w.before,m),k=w.lines,a&&k.length&&(this._drawColorBox(n,t,C,g,r),f=Math.max(d.lineHeight,l)),_=0,P=k.length;_<P;++_)m(k[_]),f=d.lineHeight;It(w.after,m)}p=0,f=d.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=Ul(r.rtl,this.x,this.width);for(t.x=Lf(this,r.footerAlign,r),t.y+=r.footerMarginTop,n.textAlign=l.textAlign(r.footerAlign),n.textBaseline="middle",o=er(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:c}=r,{topLeft:d,topRight:f,bottomLeft:p,bottomRight:g}=Vl(s.cornerRadius);n.fillStyle=s.backgroundColor,n.strokeStyle=s.borderColor,n.lineWidth=s.borderWidth,n.beginPath(),n.moveTo(a+d,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+c-g),n.quadraticCurveTo(a+u,l+c,a+u-g,l+c),o==="bottom"&&this.drawCaret(t,n,r,s),n.lineTo(a+p,l+c),n.quadraticCurveTo(a,l+c,a,l+c-p),o==="center"&&i==="left"&&this.drawCaret(t,n,r,s),n.lineTo(a,l+d),n.quadraticCurveTo(a,l,a+d,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=vc[t.position].call(this,this._active,this._eventPosition);if(!o)return;const a=this._size=oE(this,t),l=Object.assign({},o,this._size),u=aE(n,t,l),c=lE(t,l,u,n);(s._to!==c.x||i._to!==c.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,c))}}_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=ps(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),x2(t,n.textDirection),i.y+=o.top,this.drawTitle(i,t,n),this.drawBody(i,t,n),this.drawFooter(i,t,n),E2(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=!vp(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||!vp(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=vc[i.position].call(this,t,n);return o!==!1&&(r!==o.x||s!==o.y)}},we(gv,"positioners",vc),gv);var Kne={id:"tooltip",_element:dE,positioners:vc,afterInit(e,t,n){n&&(e.tooltip=new dE({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:U2},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 Yne=(e,t,n,r)=>(typeof t=="string"?(n=e.push(t)-1,r.unshift({index:n,label:t})):isNaN(t)&&(n=null),n);function Xne(e,t,n,r){const s=e.indexOf(t);if(s===-1)return Yne(e,t,n,r);const i=e.lastIndexOf(t);return s!==i?n:s}const Qne=(e,t)=>e===null?null:Ps(Math.round(e),0,t);function fE(e){const t=this.getLabels();return e>=0&&e<t.length?t[e]:e}class _b extends Wu{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(Nt(t))return null;const r=this.getLabels();return n=isFinite(n)&&r[n]===t?n:Xne(r,t,At(n,t),this._addedLabels),Qne(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 fE.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}}we(_b,"id","category"),we(_b,"defaults",{ticks:{callback:fE}});function Jne(e,t){const n=[],{bounds:s,step:i,min:o,max:a,precision:l,count:u,maxTicks:c,maxDigits:d,includeBounds:f}=e,p=i||1,g=c-1,{min:m,max:y}=t,w=!Nt(o),b=!Nt(a),k=!Nt(u),C=(y-m)/(d+1);let _=gx((y-m)/g/p)*p,T,P,S,E;if(_<1e-14&&!w&&!b)return[{value:m},{value:y}];E=Math.ceil(y/_)-Math.floor(m/_),E>g&&(_=gx(E*_/g/p)*p),Nt(l)||(T=Math.pow(10,l),_=Math.ceil(_*T)/T),s==="ticks"?(P=Math.floor(m/_)*_,S=Math.ceil(y/_)*_):(P=m,S=y),w&&b&&i&&eee((a-o)/i,_/1e3)?(E=Math.round(Math.min((a-o)/_,c)),_=(a-o)/E,P=o,S=a):k?(P=w?o:P,S=b?a:S,E=u-1,_=(S-P)/E):(E=(S-P)/_,yh(E,Math.round(E),_/1e3)?E=Math.round(E):E=Math.ceil(E));const I=Math.max(vx(_),vx(P));T=Math.pow(10,Nt(l)?I:l),P=Math.round(P*T)/T,S=Math.round(S*T)/T;let O=0;for(w&&(f&&P!==o?(n.push({value:o}),P<o&&O++,yh(Math.round((P+O*_)*T)/T,o,hE(o,C,e))&&O++):P<o&&O++);O<E;++O){const R=Math.round((P+O*_)*T)/T;if(b&&R>a)break;n.push({value:R})}return b&&f&&S!==a?n.length&&yh(n[n.length-1].value,a,hE(a,C,e))?n[n.length-1].value=a:n.push({value:a}):(!b||S===a)&&n.push({value:S}),n}function hE(e,t,{horizontal:n,minRotation:r}){const s=ga(r),i=(n?Math.sin(s):Math.cos(s))||.001,o=.75*t*(""+e).length;return Math.min(t/i,o)}class Zne extends Wu{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 Nt(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=Ao(s),u=Ao(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=Jne(s,i);return t.bounds==="ticks"&&tee(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 h2(t,this.chart.options.locale,this.options.ticks.format)}}class kb extends Zne{determineDataLimits(){const{min:t,max:n}=this.getMinMax(!0);this.min=hs(t)?t:0,this.max=hs(n)?n:1,this.handleTickRangeOptions()}computeTickLimit(){const t=this.isHorizontal(),n=t?this.width:this.height,r=ga(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}}we(kb,"id","linear"),we(kb,"defaults",{ticks:{callback:m2.formatters.numeric}});const Bm={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}},xr=Object.keys(Bm);function pE(e,t){return e-t}function mE(e,t){if(Nt(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)),hs(o)||(o=typeof r=="string"?n.parse(o,r):n.parse(o)),o===null?null:(s&&(o=s==="week"&&(wp(i)||i===!0)?n.startOf(o,"isoWeek",i):n.startOf(o,s)),+o)}function gE(e,t,n,r){const s=xr.length;for(let i=xr.indexOf(e);i<s-1;++i){const o=Bm[xr[i]],a=o.steps?o.steps:Number.MAX_SAFE_INTEGER;if(o.common&&Math.ceil((n-t)/(a*o.size))<=r)return xr[i]}return xr[s-1]}function ere(e,t,n,r,s){for(let i=xr.length-1;i>=xr.indexOf(n);i--){const o=xr[i];if(Bm[o].common&&e._adapter.diff(s,r,o)>=t-1)return o}return xr[n?xr.indexOf(n):0]}function tre(e){for(let t=xr.indexOf(e)+1,n=xr.length;t<n;++t)if(Bm[xr[t]].common)return xr[t]}function vE(e,t,n){if(!n)e[t]=!0;else if(n.length){const{lo:r,hi:s}=xw(n,t),i=n[r]>=t?n[r]:n[s];e[i]=!0}}function nre(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 yE(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:nre(e,r,s,n)}class xp extends Wu{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 bte._date(t.adapters.date);s.init(n),Lc(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:mE(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=hs(s)&&!isNaN(s)?s:+n.startOf(Date.now(),r),i=hs(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=lee(s,i,o);return this._unit=n.unit||(r.autoSkip?gE(n.minUnit,this.min,this.max,this._getLabelCapacity(i)):ere(this,a.length,n.minUnit,this.min,this.max)),this._majorUnit=!r.major.enabled||this._unit==="year"?void 0:tre(this._unit),this.initOffsets(s),t.reverse&&a.reverse(),yE(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||gE(i.minUnit,n,r,this._getLabelCapacity(n)),a=At(s.ticks.stepSize,1),l=o==="week"?i.isoWeekday:!1,u=wp(l)||l===!0,c={};let d=n,f,p;if(u&&(d=+t.startOf(d,"isoWeek",l)),d=+t.startOf(d,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=d,p=0;f<r;f=+t.add(f,a,o),p++)vE(c,f,g);return(f===r||s.bounds==="ticks"||p===1)&&vE(c,f,g),Object.keys(c).sort(pE).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 Xt(o,[t,n,r],this);const a=i.time.displayFormats,l=this._unit,u=this._majorUnit,c=l&&a[l],d=u&&a[u],f=r[n],p=u&&d&&f&&f.major;return this._adapter.format(t,s||(p?d:c))}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=ga(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,yE(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(mE(this,s[n]));return this._cache.labels=this._normalized?t:this.normalize(t)}normalize(t){return u2(t.sort(pE))}}we(xp,"id","time"),we(xp,"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 $f(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}=yb(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}=yb(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 bE extends xp{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=$f(n,this.min),this._tableRange=$f(n,this.max)-this._minPos,super.initOffsets(t)}buildLookupTable(t){const{min:n,max:r}=this,s=[],i=[];let o,a,l,u,c;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)c=s[o+1],l=s[o-1],u=s[o],Math.round((c+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($f(this._table,t)-this._minPos)/this._tableRange}getValueForPixel(t){const n=this._offsets,r=this.getDecimalForPixel(t)/n.factor-n.end;return $f(this._table,r*this._tableRange+this._minPos,!0)}}we(bE,"id","timeseries"),we(bE,"defaults",xp.defaults);const z2={data:{type:Object,required:!0},options:{type:Object,default:()=>({})},plugins:{type:Array,default:()=>[]},datasetIdKey:{type:String,default:"label"},updateMode:{type:String,default:void 0}},rre={ariaLabel:{type:String},ariaDescribedby:{type:String}},sre={type:{type:String,required:!0},destroyDelay:{type:Number,default:0},...z2,...rre},ire=hT[0]==="2"?(e,t)=>Object.assign(e,{attrs:t}):(e,t)=>Object.assign(e,t);function gl(e){return wd(e)?Be(e):e}function ore(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:e;return wd(t)?new Proxy(e,{}):e}function are(e,t){const n=e.options;n&&t&&Object.assign(n,t)}function H2(e,t){e.labels=t}function j2(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 lre(e,t){const n={labels:[],datasets:[]};return H2(n,e.labels),j2(n,e.datasets,t),n}const ure=Le({props:sre,setup(e,t){let{expose:n,slots:r}=t;const s=j(null),i=Ie(null);n({chart:i});const o=()=>{if(!s.value)return;const{type:u,data:c,options:d,plugins:f,datasetIdKey:p}=e,g=lre(c,p),m=ore(g,c);i.value=new Nm(s.value,{type:u,data:m,options:{...d},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),Bp(a),Ee([()=>e.options,()=>e.data],(u,c)=>{let[d,f]=u,[p,g]=c;const m=Be(i.value);if(!m)return;let y=!1;if(d){const w=gl(d),b=gl(p);w&&w!==b&&(are(m,w),y=!0)}if(f){const w=gl(f.labels),b=gl(g.labels),k=gl(f.datasets),C=gl(g.datasets);w!==b&&(H2(m.config.data,w),y=!0),k&&k!==C&&(j2(m.config.data,k,e.datasetIdKey),y=!0)}y&&Mt(()=>{l(m)})},{deep:!0}),()=>pr("canvas",{role:"img",ariaLabel:e.ariaLabel,ariaDescribedby:e.ariaDescribedby,ref:s},[pr("p",{},[r.default?r.default():""])])}});function cre(e,t){return Nm.register(t),Le({props:z2,setup(n,r){let{expose:s}=r;const i=Ie(null),o=a=>{i.value=a==null?void 0:a.chart};return s({chart:i}),()=>pr(ure,ire({ref:o},{type:e,...n}))}})}const dre=cre("bar",bh);function fre(e,t){const n=typeof e=="string"?In(e):e,r=hre(n,t);return{mounted:r,updated:r,unmounted(s){kT(null,s)}}}function hre(e,t){return function(n,r,s){var d,f,p;const i=typeof t=="function"?t(r):t,o=((d=r.value)==null?void 0:d.text)??r.value??(i==null?void 0:i.text),a=Mh(r.value)?r.value:{},l=()=>o??n.textContent,u=(s.ctx===r.instance.$?(f=pre(s,r.instance.$))==null?void 0:f.provides:(p=s.ctx)==null?void 0:p.provides)??r.instance.$.provides,c=pr(e,ge(i,a),l);c.appContext=Object.assign(Object.create(null),r.instance.$.appContext,{provides:u}),kT(c,n)}}function pre(e,t){const n=new Set,r=i=>{var o,a;for(const l of i){if(!l)continue;if(l===e||l.el&&e.el&&l.el===e.el)return!0;n.add(l);let u;if(l.suspense?u=r([l.ssContent]):Array.isArray(l.children)?u=r(l.children):(o=l.component)!=null&&o.vnode&&(u=r([(a=l.component)==null?void 0:a.subTree])),u)return u;n.delete(l)}return!1};if(!r([t.subTree]))return t;const s=Array.from(n).reverse();for(const i of s)if(i.component)return i.component;return t}const mre=fre(nt,e=>{var t;return{activator:"parent",location:(t=e.arg)==null?void 0:t.replace("-"," "),text:typeof e.value=="boolean"?void 0:e.value}}),gre={class:"ma-3"},vre={class:"ml-6"},yre={class:"ml-7 mt-3"},bre={key:0},wre={key:2},Sre=Le({__name:"EmergencyCommands",setup(e){Nm.register(_b,kb,_h,Vne,Kne,Nne);const t=Ft(),n=j(!1),r=j(!1),s=j([]),i=j([]),o=j(NaN),a=j(NaN),l=j(NaN),u=j({labels:[],datasets:[{label:"OctoPrint Settings response times (ms)",data:[],borderColor:"#FF6384",backgroundColor:"#ffffff"}]}),c={color:"white",plugins:{title:{color:"red",text:"Response times (ms)",display:!0}},responsive:!0},d=A(()=>t.printers.length===0||t.printers.every(w=>!w.enabled)),f=A(()=>t.printers.length===0||t.printers.every(w=>!!w.enabled));async function p(){try{n.value=!0;const w=t.printers.map(T=>T.id),b=await Ol.batchSettingsGet(w),k=b.map(T=>{var P,S;return((S=(P=T.value)==null?void 0:P.appearance)==null?void 0:S.name)||"ERROR"});i.value=b.filter(T=>!T.success).map(T=>({message:T.error}));const C=b.map(T=>T.time),_=b.map(T=>{var P,S;return((S=(P=T.value)==null?void 0:P.appearance)==null?void 0:S.name)??""});o.value=C.reduce((T,P)=>T+P,0)/C.length,l.value=Math.min(...C),a.value=Math.max(...C),u.value={labels:_,datasets:[{label:"OctoPrint Settings response times (ms)",data:C,borderColor:"#FF6384",backgroundColor:"#ffffff"}]},r.value=!0,s.value=k}finally{n.value=!1}}async function g(w){if(confirm("Are you sure you want to toggle all printers?")){n.value=!0;try{await Ol.batchToggleEnabled(t.printers.map(b=>b.id),w)}finally{n.value=!1}}}async function m(){if(confirm("Are you sure you want to connect all USBs?"))try{await Ol.batchConnectUsb(t.printers.map(w=>w.id))}finally{n.value=!1}}async function y(){confirm("Are you sure you want to connect all sockets?")&&(n.value=!0,await Ol.batchConnectSocket(t.printers.map(w=>w.id)),n.value=!1)}return(w,b)=>($(),te(vt,null,{default:v(()=>[h(mr,{color:"primary"},{default:v(()=>[h(ut,null,{default:v(()=>[h(J,null,{default:v(()=>b[3]||(b[3]=[x("settings")])),_:1})]),_:1}),h(En,null,{default:v(()=>b[4]||(b[4]=[x(" Emergency Commands")])),_:1})]),_:1}),h(Ut,{lines:"three",subheader:""},{default:v(()=>[h(qr,null,{default:v(()=>b[5]||(b[5]=[x(" Emergency Commands to rectify problematic situations ")])),_:1}),h(Ve,null,{default:v(()=>[h(ft,null,{default:v(()=>b[6]||(b[6]=[x(" Batch disabling")])),_:1}),h(bt,null,{default:v(()=>[b[9]||(b[9]=x(" Disable all printers in batch (will not affect print) ")),b[10]||(b[10]=L("br",null,null,-1)),h(se,{disabled:n.value||d.value,class:"ml-4",color:"primary",onClick:b[0]||(b[0]=k=>g(!1))},{default:v(()=>b[7]||(b[7]=[x(" Batch disable ")])),_:1},8,["disabled"]),n.value?($(),te(ni,{key:0,class:"ml-2",indeterminate:"",size:"30",width:"4"})):pe("",!0),d.value?($(),te(J,{key:1,class:"ml-2",color:"warning"},{default:v(()=>b[8]||(b[8]=[x(" warning ")])),_:1})):pe("",!0)]),_:1})]),_:1}),h(Ve,null,{default:v(()=>[h(ft,null,{default:v(()=>b[11]||(b[11]=[x(" Batch enabling")])),_:1}),h(bt,null,{default:v(()=>[b[14]||(b[14]=x(" Enabling all printers in batch (will not affect print and it will skip printers in maintenance mode) ")),b[15]||(b[15]=L("br",null,null,-1)),h(se,{disabled:n.value||f.value,class:"ml-4",color:"primary",onClick:b[1]||(b[1]=k=>g(!0))},{default:v(()=>b[12]||(b[12]=[x(" Batch enable ")])),_:1},8,["disabled"]),n.value?($(),te(ni,{key:0,class:"ml-2",indeterminate:"",size:"30",width:"4"})):pe("",!0),f.value?Bt(($(),te(J,{key:1,class:"ml-2",color:"warning"},{default:v(()=>b[13]||(b[13]=[x("warning ")])),_:1})),[[mre,"No printers available",void 0,{bottom:!0}]]):pe("",!0)]),_:1})]),_:1}),h(Ve,null,{default:v(()=>[h(ft,null,{default:v(()=>b[16]||(b[16]=[x(" Batch USB connect")])),_:1}),h(bt,null,{default:v(()=>[b[19]||(b[19]=x(" Connect all USB devices ")),b[20]||(b[20]=L("br",null,null,-1)),h(se,{disabled:n.value||d.value,class:"ml-4",color:"primary",onClick:m},{default:v(()=>[h(J,{class:"mr-2"},{default:v(()=>b[17]||(b[17]=[x("usb")])),_:1}),b[18]||(b[18]=x(" Connect USBs "))]),_:1},8,["disabled"]),n.value?($(),te(ni,{key:0,class:"ml-2",indeterminate:"",size:"30",width:"4"})):pe("",!0)]),_:1}),h(bt,{class:"mt-2"},{default:v(()=>[b[23]||(b[23]=x(" Connect all Sockets ")),b[24]||(b[24]=L("br",null,null,-1)),h(se,{disabled:n.value||d.value,class:"ml-4",color:"primary",onClick:y},{default:v(()=>[h(J,{class:"mr-2"},{default:v(()=>b[21]||(b[21]=[x("hub")])),_:1}),b[22]||(b[22]=x(" Connect Sockets "))]),_:1},8,["disabled"])]),_:1}),n.value?($(),te(ni,{key:0,class:"ml-2",indeterminate:"",size:"30",width:"4"})):pe("",!0)]),_:1})]),_:1}),L("div",gre,[h(fn,null,{default:v(()=>b[25]||(b[25]=[x(" Test all OctoPrint response times")])),_:1}),L("div",vre,[h(se,{loading:n.value,color:"primary",onClick:b[2]||(b[2]=k=>p())},{default:v(()=>b[26]||(b[26]=[x(" Measure network response times ")])),_:1},8,["loading"])]),L("div",yre,[r.value?($(),ve("span",bre," Response times: ")):pe("",!0),r.value?($(),te(Q(dre),{key:1,data:u.value,options:c,height:"100",style:{"background-color":"#272727"}},null,8,["data"])):($(),ve("span",wre,"A graph will be shown, presenting the times in milliseconds (ms)")),n.value?($(),te(ni,{key:3,class:"ml-2",indeterminate:"",size:"30",width:"4"})):pe("",!0)])])]),_:1}))}}),_re={class:"text-center"},kre=Le({__name:"NotFoundView",setup(e){const t=Go(),n=()=>{t.go(-1)};return(r,s)=>($(),te(Un,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",_re,[h(se,{class:"align-center",color:"primary",to:"/",variant:"elevated"},{default:v(()=>[h(J,{class:"mr-2"},{default:v(()=>s[1]||(s[1]=[x("home")])),_:1}),s[2]||(s[2]=x(" Go home "))]),_:1}),s[5]||(s[5]=L("span",{class:"pa-5"}," or ",-1)),h(se,{class:"align-center",variant:"elevated",onClick:s[0]||(s[0]=i=>n())},{default:v(()=>[h(J,{class:"mr-2"},{default:v(()=>s[3]||(s[3]=[x("arrow_left")])),_:1}),s[4]||(s[4]=x(" Go back "))]),_:1})])]),_:1}))}}),xre={key:0},Ere={key:1},Cre={key:2},Tre={key:3},Pre={key:4},Rre=Le({__name:"PermissionDenied",setup(e){const t=uM(),n=A(()=>t.query);return(r,s)=>($(),te(Un,{"fill-height":"",fluid:""},{default:v(()=>[h(xM,{color:"primary"},{default:v(()=>[h(En,{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:vw,style:{opacity:"0.06"}},null,-1)),h(Rm,{"align-center":"",column:"","justify-center":""},{default:v(()=>[h(vt,{class:"flex align-center justify-center pa-lg-16 pa-sm-10",style:{width:"80%"}},{default:v(()=>[h(sn,null,{default:v(()=>[h(J,{class:"mr-4",size:"50"},{default:v(()=>s[1]||(s[1]=[x(" lock ")])),_:1}),s[2]||(s[2]=L("h3",null,"Permission Denied",-1))]),_:1}),h(km,{class:"mt-1"},{default:v(()=>s[3]||(s[3]=[x(" You do not have permission to access a specific resource on this page. ")])),_:1}),n.value?($(),te(en,{key:0},{default:v(()=>{var i,o;return[n.value.page?($(),ve("div",xre,[s[4]||(s[4]=x(" Page: ")),L("strong",null,re((i=n.value)==null?void 0:i.page),1)])):pe("",!0),n.value.permissions?($(),ve("div",Ere,[s[5]||(s[5]=x(" Required permission(s): ")),($(!0),ve(Ae,null,Gt(n.value.permissions,a=>($(),ve("strong",{key:a},re(a),1))),128))])):pe("",!0),n.value.roles?($(),ve("div",Cre,[s[6]||(s[6]=x(" Usable roles: ")),L("strong",null,re((o=n.value.roles)==null?void 0:o.join(", ")),1)])):pe("",!0),n.value.url?($(),ve("div",Tre,[s[7]||(s[7]=x(" Problematic API path: ")),L("strong",null,re(n.value.url),1)])):pe("",!0),n.value.error?($(),ve("div",Pre,[s[8]||(s[8]=x(" Error: ")),L("strong",null,re(n.value.error),1)])):pe("",!0)]}),_:1})):pe("",!0),h(Mn,{class:"mt-6"},{default:v(()=>[h(se,{class:"align-center",color:"primary",to:"/",variant:"elevated"},{default:v(()=>[h(J,{class:"mr-2"},{default:v(()=>s[9]||(s[9]=[x("home")])),_:1}),s[10]||(s[10]=x(" Go home "))]),_:1})]),_:1})]),_:1})]),_:1})]),_:1}))}}),Ire=Le({__name:"Logo",setup(e){return(t,n)=>($(),te(ds,{src:Q(pw),class:"shrink mr-1 pt-3 ml-1",contain:"",style:{opacity:"0.85"},width:"150"},null,8,["src"]))}}),Are=Le({__name:"LoginForm",setup(e){const t=us(),n=j(""),r=j(""),s=j(!1),i=j(""),o=Go(),a=uM(),l=j(!1),u=Br("auth:login"),c=Dt(),d=A(()=>{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:Wt.Registration})}async function p(){var m,y,w,b;try{l.value=!0,await t.login(r.value,i.value),t.lastLogoutReason=null,i.value="",l.value=!1}catch(k){if(l.value=!1,((m=k==null?void 0:k.response)==null?void 0:m.status)===401){i.value="";const C=(w=(y=k==null?void 0:k.response)==null?void 0:y.data)==null?void 0:w.reasonCode,_=a0(C);C===kr.AccountNotVerified?c.error(_,"Please ask your administrator to verify your account and try again."):C===kr.PasswordChangeRequired&&c.error(_,"Your password needs to be changed. This feature is sadly not finished"),n.value=_;return}c.openErrorMessage({title:"Error logging in",subtitle:"Please test your connection and try again."}),n.value="Error logging in - status code "+((b=k==null?void 0:k.response)==null?void 0:b.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:Wt.Home});return}}return(m,y)=>($(),te(vt,{class:"pa-4",elevation:"10",style:{"border-radius":"10px"}},{default:v(()=>[h(en,null,{default:v(()=>[h(bw,null,{default:v(()=>[y[7]||(y[7]=L("label",null," Username ",-1)),h(at,{modelValue:r.value,"onUpdate:modelValue":y[0]||(y[0]=w=>r.value=w),"prepend-icon":"person",autofocus:"",label:"Username",name:"login",type:"text",variant:"underlined",onKeyup:y[1]||(y[1]=Av(w=>d.value||p(),["enter"]))},null,8,["modelValue"]),h(at,{modelValue:i.value,"onUpdate:modelValue":y[2]||(y[2]=w=>i.value=w),"append-inner-icon":s.value?"visibility_off":"visibility","onClick:appendInner":y[3]||(y[3]=w=>s.value=!s.value),type:s.value?"text":"password",label:"Password",name:"password",password:"","prepend-icon":"lock",variant:"underlined",onKeyup:y[4]||(y[4]=Av(w=>d.value||p(),["enter"]))},null,8,["modelValue","append-inner-icon","type"]),n.value?($(),te(fn,{key:0,class:"mt-6",color:"error",density:"compact",variant:"outlined"},{default:v(()=>[x(re(n.value),1)]),_:1})):pe("",!0),Q(t).lastLogoutReason?($(),te(fn,{key:1,class:"mt-6",color:"error-darken-1",density:"compact",variant:"outlined"},{default:v(()=>[x(" Reason for automatic logout: "+re(Q(t).lastLogoutReason),1)]),_:1})):pe("",!0)]),_:1})]),_:1}),h(Mn,null,{default:v(()=>[h(se,{loading:l.value,class:"pa-4",color:"primary",size:"lg",variant:"flat",style:{width:"100%"},onClick:y[5]||(y[5]=w=>p())},{default:v(()=>y[8]||(y[8]=[x(" Login ")])),_:1},8,["loading"])]),_:1}),h(Mn,null,{default:v(()=>[h(se,{disabled:!Q(t).registration,class:"pa-4",size:"lg",variant:"flat",style:{width:"100%"},onClick:y[6]||(y[6]=w=>f())},{default:v(()=>[x(" Register new account "+re(Q(t).registration?"":"(not enabled)")+" ",1),h(J,{class:"pl-5",icon:"right"})]),_:1},8,["disabled"])]),_:1})]),_:1}))}}),Ore={class:"d-flex align-center",style:{"min-height":"calc(100vh - 148px)"}},Mre={class:"pt-6 pl-6 d-flex flex-column align-center"},Dre=Le({__name:"LoginView",setup(e){return(t,n)=>{const r=Ire;return $(),te(rt,{class:"position-relative","no-gutters":""},{default:v(()=>[h(ze,{cols:"12",lg:"12"},{default:v(()=>[h(Un,null,{default:v(()=>[L("div",Ore,[h(rt,{justify:"center",class:"align-content-center"},{default:v(()=>[L("div",Mre,[h(r),h(En,{class:"text-uppercase text-red"},{default:v(()=>n[0]||(n[0]=[L("strong",null," FDM ",-1),L("strong",null," Monster ",-1)])),_:1}),h(En,{class:"mt-lg-6 mt-sm-5 mb-md-5"},{default:v(()=>n[1]||(n[1]=[x(" Login to your account ")])),_:1}),h(km,{class:"text-grey mb-md-5"},{default:v(()=>n[2]||(n[2]=[x(" Welcome back! Please enter your details ")])),_:1})]),h(ze,{cols:"12",md:"12"},{default:v(()=>[h(Are,{class:"login-card"})]),_:1})]),_:1})])]),_:1})]),_:1})]),_:1})}}}),Lre={class:"d-flex flex-column align-center"},$re=Le({__name:"RegistrationForm",setup(e){const t=us(),n=Go(),r=j(""),s=j(""),i=j(!1),o=j(!1),a=j(""),l=j(""),u=j(!1),c=Dt();async function d(){return await n.push({name:Wt.Login})}const f=A(()=>{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||(c.info("Registration is disabled, please contact your administrator"),await n.push({name:Wt.Login}))});async function p(){var g;try{u.value=!0,await oa.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}c.openErrorMessage({title:"Error logging in",subtitle:"Please test your connection and try again."});return}r.value="",c.info("Account created, please login"),await d()}return(g,m)=>{const y=In("v-flex");return $(),te(Un,{"fill-height":"",fluid:""},{default:v(()=>[h(Rm,{"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",Lre,[h(ds,{src:require("@/assets/logo.png"),class:"shrink mr-1 pt-3 ml-1",contain:"",style:{opacity:"0.85"},width:"150"},null,8,["src"]),h(En,{class:"text-uppercase text-red"},{default:v(()=>m[8]||(m[8]=[L("strong",null," FDM ",-1),L("strong",null," Monster ",-1)])),_:1}),h(En,{class:"mt-lg-6 mt-sm-5"},{default:v(()=>m[9]||(m[9]=[x(" Register new account ")])),_:1}),h(km,{class:"text-grey"},{default:v(()=>m[10]||(m[10]=[x(" Welcome! Please register your guest account ")])),_:1})]),h(vt,{class:"elevation-4 pa-4",style:{"border-radius":"10px"}},{default:v(()=>[h(en,null,{default:v(()=>[h(bw,null,{default:v(()=>[m[11]||(m[11]=L("label",null," Username ",-1)),h(at,{modelValue:s.value,"onUpdate:modelValue":m[0]||(m[0]=w=>s.value=w),rules:[w=>!!w||"Username is required",w=>((w==null?void 0:w.length)??0)>=3||"Username must be of length 3 or greater",w=>!w.toLowerCase().includes("admin")||"Username may not contain the word admin",w=>!w.toLowerCase().includes("root")||"Username may not contain the word root",w=>w.toLowerCase()!=="demo"||"Username may not equal the word demo"],autofocus:"",name:"login",label:"Username","prepend-icon":"person",type:"text"},null,8,["modelValue","rules"]),h(at,{id:"password",modelValue:a.value,"onUpdate:modelValue":m[1]||(m[1]=w=>a.value=w),"append-icon":i.value?"visibility":"visibility_off",type:i.value?"text":"password",label:"Password",name:"password",rules:[w=>!!w||"Password is required",w=>!!w&&(w==null?void 0:w.length)>=8||"Password must be of length 8 or greater"],password:"","prepend-icon":"lock","onClick:append":m[2]||(m[2]=w=>i.value=!i.value)},null,8,["modelValue","append-icon","type","rules"]),h(at,{id:"password",modelValue:l.value,"onUpdate:modelValue":m[3]||(m[3]=w=>l.value=w),"append-icon":o.value?"visibility":"visibility_off",type:o.value?"text":"password",rules:[w=>!!w||"Repeated password is required",w=>w===a.value||"Passwords are not equal"],label:"Repeated Password",name:"password",password:"","prepend-icon":"lock","onClick:append":m[4]||(m[4]=w=>o.value=!o.value),onKeyup:m[5]||(m[5]=Av(w=>f.value||p(),["enter"]))},null,8,["modelValue","append-icon","type","rules"]),r.value?($(),te(fn,{key:0,class:"mt-6",color:"error",density:"compact",variant:"outlined"},{default:v(()=>[x(re(r.value),1)]),_:1})):pe("",!0)]),_:1})]),_:1}),h(Mn,null,{default:v(()=>[h(se,{loading:u.value,class:"pa-4",color:"primary",size:"large",style:{width:"100%"},onClick:m[6]||(m[6]=w=>p())},{default:v(()=>m[12]||(m[12]=[x(" Register account ")])),_:1},8,["loading"])]),_:1}),h(Mn,null,{default:v(()=>[h(se,{style:{width:"100%"},class:"pa-4",size:"large",onClick:m[7]||(m[7]=w=>d())},{default:v(()=>[h(J,{class:"mr-2"},{default:v(()=>m[13]||(m[13]=[x("arrow_left")])),_:1}),m[14]||(m[14]=x("Back to Login "))]),_:1})]),_:1})]),_:1})]),_:1})]),_:1})]),_:1})}}}),Fre=Le({__name:"RegistrationView",setup(e){return(t,n)=>($(),te(Un,{"fill-height":"",fluid:""},{default:v(()=>[h(Rm,{"align-center":"","justify-center":""},{default:v(()=>[h($re)]),_:1})]),_:1}))}}),Nre=["src"],Bre=Le({__name:"CameraGridView",setup(e){const t=Ft(),n=tn(nn.AddOrUpdateCameraDialog),s=Pm({queryKey:["cameraStream"],queryFn:async()=>(await fp.listCameraStreams()).map(c=>({printer:t.printers.find(d=>d.id===c.printerId),cameraStream:c}))}),i=j9({mutationFn:u=>fp.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,c)=>($(),ve("div",null,[h(mr,null,{default:v(()=>[h(En,{class:"mr-4"},{default:v(()=>c[1]||(c[1]=[x(" Camera Overview ")])),_:1}),h(se,{color:"primary",onClick:c[0]||(c[0]=d=>o())},{default:v(()=>[h(J,{class:"mr-2"},{default:v(()=>c[2]||(c[2]=[x("add")])),_:1}),c[3]||(c[3]=x(" Add camera "))]),_:1})]),_:1}),h(rt,{class:"ma-0"},{default:v(()=>[($(!0),ve(Ae,null,Gt(Q(s).data.value,d=>($(),ve("div",{key:d.cameraStream.id,class:"ma-4",style:{border:"1px solid grey",margin:"0"},width:"300"},[h(vt,{class:"pb-2 pl-2 pr-2",width:"300"},{default:v(()=>{var f;return[h(sn,null,{default:v(()=>{var p;return[d.cameraStream.printerId?($(),te(J,{key:0,class:"mr-2",size:"small"},{default:v(()=>c[4]||(c[4]=[x(" print ")])),_:1})):($(),te(J,{key:1,class:"mr-2",size:"small"},{default:v(()=>c[5]||(c[5]=[x(" camera_alt ")])),_:1})),x(" "+re((d==null?void 0:d.cameraStream.name)??((p=d==null?void 0:d.printer)==null?void 0:p.name)??"Camera"),1)]}),_:2},1024),L("img",{src:(f=d.cameraStream)==null?void 0:f.streamURL,width:"100%"},null,8,Nre),c[10]||(c[10]=L("br",null,null,-1)),h(se,{class:"mr-1",size:"small",onClick:p=>a(d.cameraStream.id)},{default:v(()=>[h(J,{class:"mr-2"},{default:v(()=>c[6]||(c[6]=[x("edit")])),_:1}),c[7]||(c[7]=x(" Update "))]),_:2},1032,["onClick"]),h(se,{size:"small",onClick:p=>l(d.cameraStream.id)},{default:v(()=>[h(J,{class:"mr-2"},{default:v(()=>c[8]||(c[8]=[x("delete")])),_:1}),c[9]||(c[9]=x(" Delete "))]),_:2},1032,["onClick"])]}),_:2},1024)]))),128))]),_:1})]))}}),Vre="/img/OIG.jpg";class Ure extends gr{static async postFirstTimeSetup(t){const n=Me.completeFirstTimeSetupRoute;return await this.post(n,t)}}const zre={class:"mt-6 border_all"},Hre={class:"d-flex flex-row align-center"},jre={class:"d-flex flex-row align-center"},qre={class:"d-flex flex-row align-center"},Wre={class:"d-flex flex-row align-center"},Gre={class:"mt-4"},Kre={class:"mt-4"},Yre={class:"mt-14"},Xre={class:"mb-5 mt-10"},Qre={class:"mt-14"},Jre=Le({__name:"FirstTimeSetupView",setup(e){const t=Go(),n=Dt(),r=j(!1),s=us(),i=j({loginRequired:!0,registration:!1}),o=j({rootUsername:"admin",rootPassword:"",rootPassword2:""}),a=j(1);St(async()=>{var c;await s.checkAuthenticationRequirements(),(c=s.wizardState)!=null&&c.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 c=i.value,d=o.value;await Ure.postFirstTimeSetup({loginRequired:c.loginRequired,registration:c.registration,rootUsername:d.rootUsername,rootPassword:d.rootPassword}),n.openInfoMessage({title:"Setup completed"}),a.value=3}async function u(){await t.push({name:"Login"})}return(c,d)=>{const f=In("v-stepper-step"),p=In("v-stepper-content"),g=In("v-stepper-items");return $(),te(Un,null,{default:v(()=>[d[46]||(d[46]=L("img",{alt:"FDM Monster Background",class:"grid-bg-img align-content-center",src:vw,style:{opacity:"0.08"}},null,-1)),h(MO,{modelValue:a.value,"onUpdate:modelValue":d[10]||(d[10]=m=>a.value=m),class:"bg-grey-darken-4"},{default:v(()=>[h(Z0,null,{default:v(()=>[h(f,{complete:a.value>1,step:"1"},{default:v(()=>d[11]||(d[11]=[x(" Introduction ")])),_:1},8,["complete"]),h(dn),h(f,{complete:a.value>2,step:"2"},{default:v(()=>d[12]||(d[12]=[x(" Login and registration ")])),_:1},8,["complete"]),h(dn),h(f,{step:"3"},{default:v(()=>d[13]||(d[13]=[x(" Summary ")])),_:1})]),_:1}),h(g,null,{default:v(()=>[h(p,{class:"align-content-center align-center text-center",step:"1"},{default:v(()=>[d[17]||(d[17]=L("div",{class:"align-content-center align-center text-center"},[L("img",{class:"rounded-pill ma-4",src:Vre,style:{opacity:"0.7"},width:"400"}),x(" /> "),L("h1",null,"FDM Monster"),L("small",null," This server is still unconfigured. ")],-1)),h(se,{class:"mt-14 mb-14",color:"primary",onClick:d[0]||(d[0]=m=>a.value=2)},{default:v(()=>d[14]||(d[14]=[x(" Start Setup ")])),_:1}),L("div",zre,[h(J,{class:"mr-6"},{default:v(()=>d[15]||(d[15]=[x("question_mark")])),_:1}),d[16]||(d[16]=L("small",null,[x(" If you have questions at any point, reach out on "),L("a",{href:"https://github.com/fdm-monster/fdm-monster/issues"}," Github "),x(" or on "),L("a",{href:"https://discord.gg/mwA8uP8CMc"}," Discord "),x(". ")],-1))])]),_:1}),h(p,{class:"align-content-center align-center text-center",step:"2"},{default:v(()=>[L("h4",null,[h(J,{class:"mr-2"},{default:v(()=>d[18]||(d[18]=[x("settings")])),_:1}),d[19]||(d[19]=x(" Login"))]),h(bw,{modelValue:r.value,"onUpdate:modelValue":d[6]||(d[6]=m=>r.value=m)},{default:v(()=>[h(mp,{modelValue:i.value.loginRequired,"onUpdate:modelValue":d[1]||(d[1]=m=>i.value.loginRequired=m),class:"mt-5"},{message:v(()=>[L("span",Hre,[h(J,{color:i.value.loginRequired?"success":"",disabled:!i.value.loginRequired,class:"ml-3 mr-3"},{default:v(()=>d[20]||(d[20]=[x(" check ")])),_:1},8,["color","disabled"]),d[21]||(d[21]=x(" Login is required. "))]),L("span",jre,[h(J,{color:i.value.loginRequired?"":"error",disabled:i.value.loginRequired,class:"ml-3 mr-3"},{default:v(()=>d[22]||(d[22]=[x(" close ")])),_:1},8,["color","disabled"]),d[23]||(d[23]=x(" No login is required. The admin role is assumed. "))])]),label:v(()=>d[24]||(d[24]=[x(" Enable Login ")])),_:1},8,["modelValue"]),i.value.loginRequired?pe("",!0):($(),te(fn,{key:0,color:"error-darken-4"},{default:v(()=>d[25]||(d[25]=[x(" You might be exposing your FDM Monster server publicly. Please take care evaluating the "),L("strong",null," Enable Login ",-1),x(" option. ")])),_:1})),h(mp,{modelValue:i.value.registration,"onUpdate:modelValue":d[2]||(d[2]=m=>i.value.registration=m),class:"mt-10 mb-10"},{message:v(()=>[L("span",qre,[h(J,{color:i.value.registration?"success":"",disabled:!i.value.registration,class:"ml-3 mr-3"},{default:v(()=>d[26]||(d[26]=[x(" check ")])),_:1},8,["color","disabled"]),d[27]||(d[27]=x(" Accounts can be registered with a guest role. "))]),L("span",Wre,[h(J,{color:i.value.registration?"":"error",disabled:i.value.registration,class:"ml-3 mr-3"},{default:v(()=>d[28]||(d[28]=[x(" close ")])),_:1},8,["color","disabled"]),d[29]||(d[29]=x(" No other accounts can be registered. "))])]),label:v(()=>d[30]||(d[30]=[x(" Enable Registration ")])),_:1},8,["modelValue"]),h(dn),L("h4",Gre,[h(J,{class:"mr-2"},{default:v(()=>d[31]||(d[31]=[x("shield")])),_:1}),d[32]||(d[32]=x(" Admin account "))]),h(at,{modelValue:o.value.rootUsername,"onUpdate:modelValue":d[3]||(d[3]=m=>o.value.rootUsername=m),rules:[m=>!!m||"Username is required"],class:"mt-5",label:"Username","prepend-icon":"person"},{prepend:v(()=>[h(J,null,{default:v(()=>d[33]||(d[33]=[x("person")])),_:1})]),_:1},8,["modelValue","rules"]),h(at,{modelValue:o.value.rootPassword,"onUpdate:modelValue":d[4]||(d[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(J,null,{default:v(()=>d[34]||(d[34]=[x("password")])),_:1})]),_:1},8,["modelValue","rules"]),h(at,{modelValue:o.value.rootPassword2,"onUpdate:modelValue":d[5]||(d[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(J,null,{default:v(()=>d[35]||(d[35]=[x("password")])),_:1})]),_:1},8,["modelValue","rules"])]),_:1},8,["modelValue"]),L("div",Kre,[h(se,{class:"mr-4",onClick:d[7]||(d[7]=m=>a.value=1)},{default:v(()=>d[36]||(d[36]=[x(" Back ")])),_:1}),h(se,{disabled:!r.value,color:"primary",onClick:d[8]||(d[8]=m=>l())},{default:v(()=>d[37]||(d[37]=[x(" Verify & Submit ")])),_:1},8,["disabled"])]),h(dn,{class:"mt-4"}),L("div",Yre,[h(J,{class:"mr-6"},{default:v(()=>d[38]||(d[38]=[x("question_mark")])),_:1}),d[39]||(d[39]=L("small",null,[x(" If you have questions at any point, reach out on "),L("a",{href:"https://github.com/fdm-monster/fdm-monster/issues"}," Github "),x(" or on "),L("a",{href:"https://discord.gg/mwA8uP8CMc"}," Discord "),x(". ")],-1))])]),_:1}),h(p,{class:"align-content-center align-center text-center",step:"3"},{default:v(()=>[L("div",Xre,[h(J,{size:"100",class:"mr-5",color:"green circle"},{default:v(()=>d[40]||(d[40]=[x(" check_circle ")])),_:1}),d[41]||(d[41]=x(" Setup Completed "))]),d[45]||(d[45]=L("br",null,null,-1)),h(se,{color:"primary",class:"mr-4",onClick:d[9]||(d[9]=m=>u())},{default:v(()=>d[42]||(d[42]=[x(" Let's continue ")])),_:1}),L("div",Qre,[h(J,{class:"mr-6"},{default:v(()=>d[43]||(d[43]=[x("question_mark")])),_:1}),d[44]||(d[44]=L("small",null,[x(" If you have questions at any point, reach out on "),L("a",{href:"https://github.com/fdm-monster/fdm-monster/issues"}," Github "),x(" or on "),L("a",{href:"https://discord.gg/mwA8uP8CMc"}," Discord "),x(". ")],-1))])]),_:1})]),_:1})]),_:1},8,["modelValue"])]),_:1})}}}),Zre={class:"ml-4 mb-4"},ese={class:"ml-4 mb-4"},tse=Le({__name:"AccountSettings",setup(e){const t=Ns(),n=lw(),r=us(),s=Go(),i=Dt(),o=j(),a=j(""),l=j({username:"",newPassword:"",oldPassword:"",repeatPassword:""});St(async()=>{var d;await t.loadSettings(),o.value=(d=t.settings)==null?void 0:d.server.loginRequired,await n.getProfile(),l.value.username=n.username,a.value=n.userId});async function u(){var d,f;if(!((f=(d=a.value)==null?void 0:d.toString())!=null&&f.length)){i.openErrorMessage({title:"User not loaded"});return}await ts.changeUsername(a.value,l.value.username),await n.getProfile(),l.value.username=n.username,i.openInfoMessage({title:"Username changed"})}async function c(){var d,f;if(!((f=(d=a.value)==null?void 0:d.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 ts.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 cM(s)}return(d,f)=>{const p=In("v-list-item-content"),g=In("v-list-item-action-text");return $(),te(vt,null,{default:v(()=>[h(mr,{color:"primary"},{default:v(()=>[h(ut,null,{default:v(()=>[h(J,null,{default:v(()=>f[6]||(f[6]=[x("account_circle")])),_:1})]),_:1}),h(En,null,{default:v(()=>f[7]||(f[7]=[x(" Account Settings ")])),_:1})]),_:1}),h(Ut,{subheader:"",lines:"three"},{default:v(()=>[h(Ve,null,{default:v(()=>[o.value?pe("",!0):($(),te(p,{key:0},{default:v(()=>[h(fn,{color:"primary"},{default:v(()=>f[8]||(f[8]=[x(" 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(Ut,{subheader:"",lines:"three"},{default:v(()=>[h(Ve,null,{default:v(()=>[h(ft,null,{default:v(()=>f[9]||(f[9]=[x(" Username ")])),_:1}),h(g,null,{default:v(()=>[h(at,{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",Zre,[h(se,{disabled:!o.value,color:"primary",onClick:f[1]||(f[1]=m=>u())},{default:v(()=>f[10]||(f[10]=[x(" Change username ")])),_:1},8,["disabled"])]),h(dn),f[14]||(f[14]=L("br",null,null,-1)),h(Ve,null,{default:v(()=>[h(ft,null,{default:v(()=>f[11]||(f[11]=[x(" Old Password ")])),_:1}),h(g,null,{default:v(()=>[h(at,{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(Ve,null,{default:v(()=>[h(ft,null,{default:v(()=>f[12]||(f[12]=[x(" New Password ")])),_:1}),h(g,null,{default:v(()=>[h(at,{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(Ve,null,{default:v(()=>[h(ft,null,{default:v(()=>f[13]||(f[13]=[x(" Repeat New Password ")])),_:1}),h(g,null,{default:v(()=>[h(at,{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",ese,[h(se,{disabled:!o.value,color:"primary",onClick:f[5]||(f[5]=m=>c())},{default:v(()=>f[15]||(f[15]=[x(" Change password ")])),_:1},8,["disabled"])]),h(dn)]),_:1})}}}),nse=Le({__name:"GridSettings",setup(e){return(t,n)=>($(),te(rt,null,{default:v(()=>[h(ze,{cols:"12"},{default:v(()=>[h(vt,null,{default:v(()=>[h(n2,{icon:"grid_on",title:"Grid"}),h(DO)]),_:1})]),_:1})]),_:1}))}}),rse=Le({__name:"ServerProtectionSettings",setup(e){const t=Go(),n=Dt(),r=us(),s=j(""),i=j(!1),o=j(!1),a=j(3200),l=j(!1),u=j(-1),c=j(14);async function d(){var k;const w=await bn.getSettings();i.value=w.server.loginRequired,o.value=w.server.registration,s.value=((k=w.connection)==null?void 0:k.clientIp)??"127.0.0.1";const b=await bn.getSettingsSensitive();a.value=b.credentials.jwtExpiresIn/60,l.value=b.credentials.refreshTokenAttempts!==-1,u.value=b.credentials.refreshTokenAttempts,c.value=b.credentials.refreshTokenExpiry/24/3600}St(async()=>{await d()});function f(){l.value||(u.value=-1)}async function p(){const w=i.value;!w&&!confirm("Disabling login will expose your server. Continue?")||(await bn.updateLoginRequiredSettings(w),await r.logout(!0),await r.checkAuthenticationRequirements(),w?await t.push({name:Wt.Login}):await t.push({name:Wt.Home}),n.info("Login Required settings updated"))}async function g(){await bn.updateRegistrationEnabledSettings(o.value),await r.checkAuthenticationRequirements(),n.info("Registration settings updated")}async function m(){a.value=120,l.value=!1,u.value=-1,c.value=14,await y(),n.info("Login expiry settings reset to default")}async function y(w=!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(c.value<1||c.value>30)throw new Error("Refresh Token Expiry must be between 1 and 30 days");await bn.updateCredentialSettings(a.value*60,u.value,c.value*24*3600),n.info("Login expiry settings updated")}return(w,b)=>($(),te(vt,null,{default:v(()=>[h(mr,{color:"primary"},{default:v(()=>[h(ut,null,{default:v(()=>[h(J,null,{default:v(()=>b[11]||(b[11]=[x("settings")])),_:1})]),_:1}),h(En,null,{default:v(()=>b[12]||(b[12]=[x(" Server Protection Settings ")])),_:1})]),_:1}),h(Ut,{lines:"three"},{default:v(()=>[h(Ve,null,{default:v(()=>[h(ft,null,{default:v(()=>b[13]||(b[13]=[x(" Login Required ")])),_:1}),h(bt,null,{default:v(()=>[h(rt,null,{default:v(()=>[h(ze,{cols:"12",md:"2"},{default:v(()=>[h(mn,{modelValue:i.value,"onUpdate:modelValue":b[0]||(b[0]=k=>i.value=k),label:"Require Login"},null,8,["modelValue"])]),_:1})]),_:1}),h(rt,null,{default:v(()=>[h(ze,null,{default:v(()=>[h(se,{color:"primary",onClick:b[1]||(b[1]=k=>p())},{default:v(()=>b[14]||(b[14]=[x(" save login required setting ")])),_:1})]),_:1})]),_:1})]),_:1})]),_:1}),h(Ve,null,{default:v(()=>[h(ft,null,{default:v(()=>b[15]||(b[15]=[x(" Registration Enabled ")])),_:1}),h(bt,null,{default:v(()=>[h(rt,null,{default:v(()=>[h(ze,{cols:"12",md:"2"},{default:v(()=>[h(mn,{modelValue:o.value,"onUpdate:modelValue":b[2]||(b[2]=k=>o.value=k),label:"Enable Registration"},null,8,["modelValue"])]),_:1})]),_:1}),h(rt,null,{default:v(()=>[h(ze,null,{default:v(()=>[h(se,{color:"primary",onClick:b[3]||(b[3]=k=>g())},{default:v(()=>b[16]||(b[16]=[x(" save registration enabled setting ")])),_:1})]),_:1})]),_:1})]),_:1})]),_:1}),h(Ve,null,{default:v(()=>[h(ft,null,{default:v(()=>b[17]||(b[17]=[x(" Login Expiry Settings (advanced) ")])),_:1}),h(bt,null,{default:v(()=>[h(rt,null,{default:v(()=>[h(ze,{cols:"12",md:"2"},{default:v(()=>[h(at,{modelValue:a.value,"onUpdate:modelValue":b[4]||(b[4]=k=>a.value=k),rules:[k=>!!k&&k>=2&&k<=120],label:"JWT Expiry (minutes)"},null,8,["modelValue","rules"])]),_:1})]),_:1}),h(rt,null,{default:v(()=>[h(ze,{cols:"12",md:"2"},{default:v(()=>[h(mn,{modelValue:l.value,"onUpdate:modelValue":[b[5]||(b[5]=k=>l.value=k),b[6]||(b[6]=k=>f())],label:"Enable Refresh Token Attempts"},null,8,["modelValue"])]),_:1})]),_:1}),h(rt,null,{default:v(()=>[h(ze,{cols:"12",md:"2"},{default:v(()=>[h(at,{modelValue:u.value,"onUpdate:modelValue":b[7]||(b[7]=k=>u.value=k),disabled:!l.value,rules:[k=>!!k&&k>=50],label:"Refresh Token Attempts (disabled: -1)",type:"number"},null,8,["modelValue","disabled","rules"])]),_:1})]),_:1}),h(rt,null,{default:v(()=>[h(ze,{cols:"12",md:"2"},{default:v(()=>[h(at,{modelValue:c.value,"onUpdate:modelValue":b[8]||(b[8]=k=>c.value=k),rules:[k=>!!k&&k>=1&&k<=30],label:"Refresh Token Expiry (days)"},null,8,["modelValue","rules"])]),_:1})]),_:1}),h(fn,{color:"secondary"},{default:v(()=>[h(J,null,{default:v(()=>b[18]||(b[18]=[x("info")])),_:1}),b[19]||(b[19]=x(" Be cautious, setting the wrong expiry could make you lose access to the server or make your user experience highly degraded! "))]),_:1}),h(rt,null,{default:v(()=>[h(ze,null,{default:v(()=>[h(se,{color:"primary",onClick:b[9]||(b[9]=k=>y())},{default:v(()=>b[20]||(b[20]=[x(" save login expiry settings ")])),_:1}),h(se,{color:"default",onClick:b[10]||(b[10]=k=>m())},{default:v(()=>b[21]||(b[21]=[x(" reset to default ")])),_:1})]),_:1})]),_:1})]),_:1})]),_:1})]),_:1})]),_:1}))}});var xb={exports:{}};const sse="2.0.0",q2=256,ise=Number.MAX_SAFE_INTEGER||9007199254740991,ose=16,ase=q2-6,lse=["major","premajor","minor","preminor","patch","prepatch","prerelease"];var Vm={MAX_LENGTH:q2,MAX_SAFE_COMPONENT_LENGTH:ose,MAX_SAFE_BUILD_LENGTH:ase,MAX_SAFE_INTEGER:ise,RELEASE_TYPES:lse,SEMVER_SPEC_VERSION:sse,FLAG_INCLUDE_PRERELEASE:1,FLAG_LOOSE:2},lv={};const use=typeof process=="object"&&lv&&lv.NODE_DEBUG&&/\bsemver\b/i.test(lv.NODE_DEBUG)?(...e)=>console.error("SEMVER",...e):()=>{};var Um=use;(function(e,t){const{MAX_SAFE_COMPONENT_LENGTH:n,MAX_SAFE_BUILD_LENGTH:r,MAX_LENGTH:s}=Vm,i=Um;t=e.exports={};const o=t.re=[],a=t.safeRe=[],l=t.src=[],u=t.safeSrc=[],c=t.t={};let d=0;const f="[a-zA-Z0-9-]",p=[["\\s",1],["\\d",s],[f,r]],g=y=>{for(const[w,b]of p)y=y.split(`${w}*`).join(`${w}{0,${b}}`).split(`${w}+`).join(`${w}{1,${b}}`);return y},m=(y,w,b)=>{const k=g(w),C=d++;i(y,C,w),c[y]=C,l[C]=w,u[C]=k,o[C]=new RegExp(w,b?"g":void 0),a[C]=new RegExp(k,b?"g":void 0)};m("NUMERICIDENTIFIER","0|[1-9]\\d*"),m("NUMERICIDENTIFIERLOOSE","\\d+"),m("NONNUMERICIDENTIFIER",`\\d*[a-zA-Z-]${f}*`),m("MAINVERSION",`(${l[c.NUMERICIDENTIFIER]})\\.(${l[c.NUMERICIDENTIFIER]})\\.(${l[c.NUMERICIDENTIFIER]})`),m("MAINVERSIONLOOSE",`(${l[c.NUMERICIDENTIFIERLOOSE]})\\.(${l[c.NUMERICIDENTIFIERLOOSE]})\\.(${l[c.NUMERICIDENTIFIERLOOSE]})`),m("PRERELEASEIDENTIFIER",`(?:${l[c.NONNUMERICIDENTIFIER]}|${l[c.NUMERICIDENTIFIER]})`),m("PRERELEASEIDENTIFIERLOOSE",`(?:${l[c.NONNUMERICIDENTIFIER]}|${l[c.NUMERICIDENTIFIERLOOSE]})`),m("PRERELEASE",`(?:-(${l[c.PRERELEASEIDENTIFIER]}(?:\\.${l[c.PRERELEASEIDENTIFIER]})*))`),m("PRERELEASELOOSE",`(?:-?(${l[c.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${l[c.PRERELEASEIDENTIFIERLOOSE]})*))`),m("BUILDIDENTIFIER",`${f}+`),m("BUILD",`(?:\\+(${l[c.BUILDIDENTIFIER]}(?:\\.${l[c.BUILDIDENTIFIER]})*))`),m("FULLPLAIN",`v?${l[c.MAINVERSION]}${l[c.PRERELEASE]}?${l[c.BUILD]}?`),m("FULL",`^${l[c.FULLPLAIN]}$`),m("LOOSEPLAIN",`[v=\\s]*${l[c.MAINVERSIONLOOSE]}${l[c.PRERELEASELOOSE]}?${l[c.BUILD]}?`),m("LOOSE",`^${l[c.LOOSEPLAIN]}$`),m("GTLT","((?:<|>)?=?)"),m("XRANGEIDENTIFIERLOOSE",`${l[c.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`),m("XRANGEIDENTIFIER",`${l[c.NUMERICIDENTIFIER]}|x|X|\\*`),m("XRANGEPLAIN",`[v=\\s]*(${l[c.XRANGEIDENTIFIER]})(?:\\.(${l[c.XRANGEIDENTIFIER]})(?:\\.(${l[c.XRANGEIDENTIFIER]})(?:${l[c.PRERELEASE]})?${l[c.BUILD]}?)?)?`),m("XRANGEPLAINLOOSE",`[v=\\s]*(${l[c.XRANGEIDENTIFIERLOOSE]})(?:\\.(${l[c.XRANGEIDENTIFIERLOOSE]})(?:\\.(${l[c.XRANGEIDENTIFIERLOOSE]})(?:${l[c.PRERELEASELOOSE]})?${l[c.BUILD]}?)?)?`),m("XRANGE",`^${l[c.GTLT]}\\s*${l[c.XRANGEPLAIN]}$`),m("XRANGELOOSE",`^${l[c.GTLT]}\\s*${l[c.XRANGEPLAINLOOSE]}$`),m("COERCEPLAIN",`(^|[^\\d])(\\d{1,${n}})(?:\\.(\\d{1,${n}}))?(?:\\.(\\d{1,${n}}))?`),m("COERCE",`${l[c.COERCEPLAIN]}(?:$|[^\\d])`),m("COERCEFULL",l[c.COERCEPLAIN]+`(?:${l[c.PRERELEASE]})?(?:${l[c.BUILD]})?(?:$|[^\\d])`),m("COERCERTL",l[c.COERCE],!0),m("COERCERTLFULL",l[c.COERCEFULL],!0),m("LONETILDE","(?:~>?)"),m("TILDETRIM",`(\\s*)${l[c.LONETILDE]}\\s+`,!0),t.tildeTrimReplace="$1~",m("TILDE",`^${l[c.LONETILDE]}${l[c.XRANGEPLAIN]}$`),m("TILDELOOSE",`^${l[c.LONETILDE]}${l[c.XRANGEPLAINLOOSE]}$`),m("LONECARET","(?:\\^)"),m("CARETTRIM",`(\\s*)${l[c.LONECARET]}\\s+`,!0),t.caretTrimReplace="$1^",m("CARET",`^${l[c.LONECARET]}${l[c.XRANGEPLAIN]}$`),m("CARETLOOSE",`^${l[c.LONECARET]}${l[c.XRANGEPLAINLOOSE]}$`),m("COMPARATORLOOSE",`^${l[c.GTLT]}\\s*(${l[c.LOOSEPLAIN]})$|^$`),m("COMPARATOR",`^${l[c.GTLT]}\\s*(${l[c.FULLPLAIN]})$|^$`),m("COMPARATORTRIM",`(\\s*)${l[c.GTLT]}\\s*(${l[c.LOOSEPLAIN]}|${l[c.XRANGEPLAIN]})`,!0),t.comparatorTrimReplace="$1$2$3",m("HYPHENRANGE",`^\\s*(${l[c.XRANGEPLAIN]})\\s+-\\s+(${l[c.XRANGEPLAIN]})\\s*$`),m("HYPHENRANGELOOSE",`^\\s*(${l[c.XRANGEPLAINLOOSE]})\\s+-\\s+(${l[c.XRANGEPLAINLOOSE]})\\s*$`),m("STAR","(<|>)?=?\\s*\\*"),m("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$"),m("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")})(xb,xb.exports);var Kd=xb.exports;const cse=Object.freeze({loose:!0}),dse=Object.freeze({}),fse=e=>e?typeof e!="object"?cse:e:dse;var Dw=fse;const wE=/^[0-9]+$/,W2=(e,t)=>{const n=wE.test(e),r=wE.test(t);return n&&r&&(e=+e,t=+t),e===t?0:n&&!r?-1:r&&!n?1:e<t?-1:1},hse=(e,t)=>W2(t,e);var G2={compareIdentifiers:W2,rcompareIdentifiers:hse};const Ff=Um,{MAX_LENGTH:SE,MAX_SAFE_INTEGER:Nf}=Vm,{safeRe:Bf,t:Vf}=Kd,pse=Dw,{compareIdentifiers:vl}=G2;let mse=class Ys{constructor(t,n){if(n=pse(n),t instanceof Ys){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>SE)throw new TypeError(`version is longer than ${SE} characters`);Ff("SemVer",t,n),this.options=n,this.loose=!!n.loose,this.includePrerelease=!!n.includePrerelease;const r=t.trim().match(n.loose?Bf[Vf.LOOSE]:Bf[Vf.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>Nf||this.major<0)throw new TypeError("Invalid major version");if(this.minor>Nf||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>Nf||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<Nf)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(Ff("SemVer.compare",this.version,this.options,t),!(t instanceof Ys)){if(typeof t=="string"&&t===this.version)return 0;t=new Ys(t,this.options)}return t.version===this.version?0:this.compareMain(t)||this.comparePre(t)}compareMain(t){return t instanceof Ys||(t=new Ys(t,this.options)),vl(this.major,t.major)||vl(this.minor,t.minor)||vl(this.patch,t.patch)}comparePre(t){if(t instanceof Ys||(t=new Ys(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(Ff("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 vl(r,s)}while(++n)}compareBuild(t){t instanceof Ys||(t=new Ys(t,this.options));let n=0;do{const r=this.build[n],s=t.build[n];if(Ff("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 vl(r,s)}while(++n)}inc(t,n,r){if(t.startsWith("pre")){if(!n&&r===!1)throw new Error("invalid increment argument: identifier is empty");if(n){const s=`-${n}`.match(this.options.loose?Bf[Vf.PRERELEASELOOSE]:Bf[Vf.PRERELEASE]);if(!s||s[1]!==n)throw new Error(`invalid identifier: ${n}`)}}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"release":if(this.prerelease.length===0)throw new Error(`version ${this.raw} is not a prerelease`);this.prerelease.length=0;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(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]),vl(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 vr=mse;const _E=vr,gse=(e,t,n=!1)=>{if(e instanceof _E)return e;try{return new _E(e,t)}catch(r){if(!n)return null;throw r}};var Gu=gse;const vse=Gu,yse=(e,t)=>{const n=vse(e,t);return n?n.version:null};var bse=yse;const wse=Gu,Sse=(e,t)=>{const n=wse(e.trim().replace(/^[=v]+/,""),t);return n?n.version:null};var _se=Sse;const kE=vr,kse=(e,t,n,r,s)=>{typeof n=="string"&&(s=r,r=n,n=void 0);try{return new kE(e instanceof kE?e.version:e,n).inc(t,r,s).version}catch{return null}};var xse=kse;const xE=Gu,Ese=(e,t)=>{const n=xE(e,null,!0),r=xE(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){if(!a.patch&&!a.minor)return"major";if(a.compareMain(o)===0)return a.minor&&!a.patch?"minor":"patch"}const c=l?"pre":"";return n.major!==r.major?c+"major":n.minor!==r.minor?c+"minor":n.patch!==r.patch?c+"patch":"prerelease"};var Cse=Ese;const Tse=vr,Pse=(e,t)=>new Tse(e,t).major;var Rse=Pse;const Ise=vr,Ase=(e,t)=>new Ise(e,t).minor;var Ose=Ase;const Mse=vr,Dse=(e,t)=>new Mse(e,t).patch;var Lse=Dse;const $se=Gu,Fse=(e,t)=>{const n=$se(e,t);return n&&n.prerelease.length?n.prerelease:null};var Nse=Fse;const EE=vr,Bse=(e,t,n)=>new EE(e,n).compare(new EE(t,n));var Bs=Bse;const Vse=Bs,Use=(e,t,n)=>Vse(t,e,n);var zse=Use;const Hse=Bs,jse=(e,t)=>Hse(e,t,!0);var qse=jse;const CE=vr,Wse=(e,t,n)=>{const r=new CE(e,n),s=new CE(t,n);return r.compare(s)||r.compareBuild(s)};var Lw=Wse;const Gse=Lw,Kse=(e,t)=>e.sort((n,r)=>Gse(n,r,t));var Yse=Kse;const Xse=Lw,Qse=(e,t)=>e.sort((n,r)=>Xse(r,n,t));var Jse=Qse;const Zse=Bs,eie=(e,t,n)=>Zse(e,t,n)>0;var zm=eie;const tie=Bs,nie=(e,t,n)=>tie(e,t,n)<0;var $w=nie;const rie=Bs,sie=(e,t,n)=>rie(e,t,n)===0;var K2=sie;const iie=Bs,oie=(e,t,n)=>iie(e,t,n)!==0;var Y2=oie;const aie=Bs,lie=(e,t,n)=>aie(e,t,n)>=0;var Fw=lie;const uie=Bs,cie=(e,t,n)=>uie(e,t,n)<=0;var Nw=cie;const die=K2,fie=Y2,hie=zm,pie=Fw,mie=$w,gie=Nw,vie=(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 die(e,n,r);case"!=":return fie(e,n,r);case">":return hie(e,n,r);case">=":return pie(e,n,r);case"<":return mie(e,n,r);case"<=":return gie(e,n,r);default:throw new TypeError(`Invalid operator: ${t}`)}};var X2=vie;const yie=vr,bie=Gu,{safeRe:Uf,t:zf}=Kd,wie=(e,t)=>{if(e instanceof yie)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?Uf[zf.COERCEFULL]:Uf[zf.COERCE]);else{const l=t.includePrerelease?Uf[zf.COERCERTLFULL]:Uf[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 bie(`${r}.${s}.${i}${o}${a}`,t)};var Sie=wie;class _ie{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 kie=_ie,uv,TE;function Vs(){if(TE)return uv;TE=1;const e=/\s+/g;class t{constructor(F,U){if(U=s(U),F instanceof t)return F.loose===!!U.loose&&F.includePrerelease===!!U.includePrerelease?F:new t(F.raw,U);if(F instanceof i)return this.raw=F.value,this.set=[[F]],this.formatted=void 0,this;if(this.options=U,this.loose=!!U.loose,this.includePrerelease=!!U.includePrerelease,this.raw=F.trim().replace(e," "),this.set=this.raw.split("||").map(K=>this.parseRange(K.trim())).filter(K=>K.length),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${this.raw}`);if(this.set.length>1){const K=this.set[0];if(this.set=this.set.filter(X=>!m(X[0])),this.set.length===0)this.set=[K];else if(this.set.length>1){for(const X of this.set)if(X.length===1&&y(X[0])){this.set=[X];break}}}this.formatted=void 0}get range(){if(this.formatted===void 0){this.formatted="";for(let F=0;F<this.set.length;F++){F>0&&(this.formatted+="||");const U=this.set[F];for(let K=0;K<U.length;K++)K>0&&(this.formatted+=" "),this.formatted+=U[K].toString().trim()}}return this.formatted}format(){return this.range}toString(){return this.range}parseRange(F){const K=((this.options.includePrerelease&&p)|(this.options.loose&&g))+":"+F,X=r.get(K);if(X)return X;const H=this.options.loose,B=H?l[u.HYPHENRANGELOOSE]:l[u.HYPHENRANGE];F=F.replace(B,R(this.options.includePrerelease)),o("hyphen replace",F),F=F.replace(l[u.COMPARATORTRIM],c),o("comparator trim",F),F=F.replace(l[u.TILDETRIM],d),o("tilde trim",F),F=F.replace(l[u.CARETTRIM],f),o("caret trim",F);let ee=F.split(" ").map(ie=>b(ie,this.options)).join(" ").split(/\s+/).map(ie=>O(ie,this.options));H&&(ee=ee.filter(ie=>(o("loose invalid filter",ie,this.options),!!ie.match(l[u.COMPARATORLOOSE])))),o("range list",ee);const q=new Map,G=ee.map(ie=>new i(ie,this.options));for(const ie of G){if(m(ie))return[ie];q.set(ie.value,ie)}q.size>1&&q.has("")&&q.delete("");const le=[...q.values()];return r.set(K,le),le}intersects(F,U){if(!(F instanceof t))throw new TypeError("a Range is required");return this.set.some(K=>w(K,U)&&F.set.some(X=>w(X,U)&&K.every(H=>X.every(B=>H.intersects(B,U)))))}test(F){if(!F)return!1;if(typeof F=="string")try{F=new a(F,this.options)}catch{return!1}for(let U=0;U<this.set.length;U++)if(M(this.set[U],F,this.options))return!0;return!1}}uv=t;const n=kie,r=new n,s=Dw,i=Hm(),o=Um,a=vr,{safeRe:l,t:u,comparatorTrimReplace:c,tildeTrimReplace:d,caretTrimReplace:f}=Kd,{FLAG_INCLUDE_PRERELEASE:p,FLAG_LOOSE:g}=Vm,m=D=>D.value==="<0.0.0-0",y=D=>D.value==="",w=(D,F)=>{let U=!0;const K=D.slice();let X=K.pop();for(;U&&K.length;)U=K.every(H=>X.intersects(H,F)),X=K.pop();return U},b=(D,F)=>(o("comp",D,F),D=T(D,F),o("caret",D),D=C(D,F),o("tildes",D),D=S(D,F),o("xrange",D),D=I(D,F),o("stars",D),D),k=D=>!D||D.toLowerCase()==="x"||D==="*",C=(D,F)=>D.trim().split(/\s+/).map(U=>_(U,F)).join(" "),_=(D,F)=>{const U=F.loose?l[u.TILDELOOSE]:l[u.TILDE];return D.replace(U,(K,X,H,B,ee)=>{o("tilde",D,K,X,H,B,ee);let q;return k(X)?q="":k(H)?q=`>=${X}.0.0 <${+X+1}.0.0-0`:k(B)?q=`>=${X}.${H}.0 <${X}.${+H+1}.0-0`:ee?(o("replaceTilde pr",ee),q=`>=${X}.${H}.${B}-${ee} <${X}.${+H+1}.0-0`):q=`>=${X}.${H}.${B} <${X}.${+H+1}.0-0`,o("tilde return",q),q})},T=(D,F)=>D.trim().split(/\s+/).map(U=>P(U,F)).join(" "),P=(D,F)=>{o("caret",D,F);const U=F.loose?l[u.CARETLOOSE]:l[u.CARET],K=F.includePrerelease?"-0":"";return D.replace(U,(X,H,B,ee,q)=>{o("caret",D,X,H,B,ee,q);let G;return k(H)?G="":k(B)?G=`>=${H}.0.0${K} <${+H+1}.0.0-0`:k(ee)?H==="0"?G=`>=${H}.${B}.0${K} <${H}.${+B+1}.0-0`:G=`>=${H}.${B}.0${K} <${+H+1}.0.0-0`:q?(o("replaceCaret pr",q),H==="0"?B==="0"?G=`>=${H}.${B}.${ee}-${q} <${H}.${B}.${+ee+1}-0`:G=`>=${H}.${B}.${ee}-${q} <${H}.${+B+1}.0-0`:G=`>=${H}.${B}.${ee}-${q} <${+H+1}.0.0-0`):(o("no pr"),H==="0"?B==="0"?G=`>=${H}.${B}.${ee}${K} <${H}.${B}.${+ee+1}-0`:G=`>=${H}.${B}.${ee}${K} <${H}.${+B+1}.0-0`:G=`>=${H}.${B}.${ee} <${+H+1}.0.0-0`),o("caret return",G),G})},S=(D,F)=>(o("replaceXRanges",D,F),D.split(/\s+/).map(U=>E(U,F)).join(" ")),E=(D,F)=>{D=D.trim();const U=F.loose?l[u.XRANGELOOSE]:l[u.XRANGE];return D.replace(U,(K,X,H,B,ee,q)=>{o("xRange",D,K,X,H,B,ee,q);const G=k(H),le=G||k(B),ie=le||k(ee),Se=ie;return X==="="&&Se&&(X=""),q=F.includePrerelease?"-0":"",G?X===">"||X==="<"?K="<0.0.0-0":K="*":X&&Se?(le&&(B=0),ee=0,X===">"?(X=">=",le?(H=+H+1,B=0,ee=0):(B=+B+1,ee=0)):X==="<="&&(X="<",le?H=+H+1:B=+B+1),X==="<"&&(q="-0"),K=`${X+H}.${B}.${ee}${q}`):le?K=`>=${H}.0.0${q} <${+H+1}.0.0-0`:ie&&(K=`>=${H}.${B}.0${q} <${H}.${+B+1}.0-0`),o("xRange return",K),K})},I=(D,F)=>(o("replaceStars",D,F),D.trim().replace(l[u.STAR],"")),O=(D,F)=>(o("replaceGTE0",D,F),D.trim().replace(l[F.includePrerelease?u.GTE0PRE:u.GTE0],"")),R=D=>(F,U,K,X,H,B,ee,q,G,le,ie,Se)=>(k(K)?U="":k(X)?U=`>=${K}.0.0${D?"-0":""}`:k(H)?U=`>=${K}.${X}.0${D?"-0":""}`:B?U=`>=${U}`:U=`>=${U}${D?"-0":""}`,k(G)?q="":k(le)?q=`<${+G+1}.0.0-0`:k(ie)?q=`<${G}.${+le+1}.0-0`:Se?q=`<=${G}.${le}.${ie}-${Se}`:D?q=`<${G}.${le}.${+ie+1}-0`:q=`<=${q}`,`${U} ${q}`.trim()),M=(D,F,U)=>{for(let K=0;K<D.length;K++)if(!D[K].test(F))return!1;if(F.prerelease.length&&!U.includePrerelease){for(let K=0;K<D.length;K++)if(o(D[K].semver),D[K].semver!==i.ANY&&D[K].semver.prerelease.length>0){const X=D[K].semver;if(X.major===F.major&&X.minor===F.minor&&X.patch===F.patch)return!0}return!1}return!0};return uv}var cv,PE;function Hm(){if(PE)return cv;PE=1;const e=Symbol("SemVer ANY");class t{static get ANY(){return e}constructor(c,d){if(d=n(d),c instanceof t){if(c.loose===!!d.loose)return c;c=c.value}c=c.trim().split(/\s+/).join(" "),o("comparator",c,d),this.options=d,this.loose=!!d.loose,this.parse(c),this.semver===e?this.value="":this.value=this.operator+this.semver.version,o("comp",this)}parse(c){const d=this.options.loose?r[s.COMPARATORLOOSE]:r[s.COMPARATOR],f=c.match(d);if(!f)throw new TypeError(`Invalid comparator: ${c}`);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(c){if(o("Comparator.test",c,this.options.loose),this.semver===e||c===e)return!0;if(typeof c=="string")try{c=new a(c,this.options)}catch{return!1}return i(c,this.operator,this.semver,this.options)}intersects(c,d){if(!(c instanceof t))throw new TypeError("a Comparator is required");return this.operator===""?this.value===""?!0:new l(c.value,d).test(this.value):c.operator===""?c.value===""?!0:new l(this.value,d).test(c.semver):(d=n(d),d.includePrerelease&&(this.value==="<0.0.0-0"||c.value==="<0.0.0-0")||!d.includePrerelease&&(this.value.startsWith("<0.0.0")||c.value.startsWith("<0.0.0"))?!1:!!(this.operator.startsWith(">")&&c.operator.startsWith(">")||this.operator.startsWith("<")&&c.operator.startsWith("<")||this.semver.version===c.semver.version&&this.operator.includes("=")&&c.operator.includes("=")||i(this.semver,"<",c.semver,d)&&this.operator.startsWith(">")&&c.operator.startsWith("<")||i(this.semver,">",c.semver,d)&&this.operator.startsWith("<")&&c.operator.startsWith(">")))}}cv=t;const n=Dw,{safeRe:r,t:s}=Kd,i=X2,o=Um,a=vr,l=Vs();return cv}const xie=Vs(),Eie=(e,t,n)=>{try{t=new xie(t,n)}catch{return!1}return t.test(e)};var jm=Eie;const Cie=Vs(),Tie=(e,t)=>new Cie(e,t).set.map(n=>n.map(r=>r.value).join(" ").trim().split(" "));var Pie=Tie;const Rie=vr,Iie=Vs(),Aie=(e,t,n)=>{let r=null,s=null,i=null;try{i=new Iie(t,n)}catch{return null}return e.forEach(o=>{i.test(o)&&(!r||s.compare(o)===-1)&&(r=o,s=new Rie(r,n))}),r};var Oie=Aie;const Mie=vr,Die=Vs(),Lie=(e,t,n)=>{let r=null,s=null,i=null;try{i=new Die(t,n)}catch{return null}return e.forEach(o=>{i.test(o)&&(!r||s.compare(o)===1)&&(r=o,s=new Mie(r,n))}),r};var $ie=Lie;const dv=vr,Fie=Vs(),RE=zm,Nie=(e,t)=>{e=new Fie(e,t);let n=new dv("0.0.0");if(e.test(n)||(n=new dv("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 dv(o.semver.version);switch(o.operator){case">":a.prerelease.length===0?a.patch++:a.prerelease.push(0),a.raw=a.format();case"":case">=":(!i||RE(a,i))&&(i=a);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${o.operator}`)}}),i&&(!n||RE(n,i))&&(n=i)}return n&&e.test(n)?n:null};var Bie=Nie;const Vie=Vs(),Uie=(e,t)=>{try{return new Vie(e,t).range||"*"}catch{return null}};var zie=Uie;const Hie=vr,Q2=Hm(),{ANY:jie}=Q2,qie=Vs(),Wie=jm,IE=zm,AE=$w,Gie=Nw,Kie=Fw,Yie=(e,t,n,r)=>{e=new Hie(e,r),t=new qie(t,r);let s,i,o,a,l;switch(n){case">":s=IE,i=Gie,o=AE,a=">",l=">=";break;case"<":s=AE,i=Kie,o=IE,a="<",l="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(Wie(e,t,r))return!1;for(let u=0;u<t.set.length;++u){const c=t.set[u];let d=null,f=null;if(c.forEach(p=>{p.semver===jie&&(p=new Q2(">=0.0.0")),d=d||p,f=f||p,s(p.semver,d.semver,r)?d=p:o(p.semver,f.semver,r)&&(f=p)}),d.operator===a||d.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 Bw=Yie;const Xie=Bw,Qie=(e,t,n)=>Xie(e,t,">",n);var Jie=Qie;const Zie=Bw,eoe=(e,t,n)=>Zie(e,t,"<",n);var toe=eoe;const OE=Vs(),noe=(e,t,n)=>(e=new OE(e,n),t=new OE(t,n),e.intersects(t,n));var roe=noe;const soe=jm,ioe=Bs;var ooe=(e,t,n)=>{const r=[];let s=null,i=null;const o=e.sort((c,d)=>ioe(c,d,n));for(const c of o)soe(c,t,n)?(i=c,s||(s=c)):(i&&r.push([s,i]),i=null,s=null);s&&r.push([s,null]);const a=[];for(const[c,d]of r)c===d?a.push(c):!d&&c===o[0]?a.push("*"):d?c===o[0]?a.push(`<=${d}`):a.push(`${c} - ${d}`):a.push(`>=${c}`);const l=a.join(" || "),u=typeof t.raw=="string"?t.raw:String(t);return l.length<u.length?l:t};const ME=Vs(),Vw=Hm(),{ANY:fv}=Vw,uc=jm,Uw=Bs,aoe=(e,t,n={})=>{if(e===t)return!0;e=new ME(e,n),t=new ME(t,n);let r=!1;e:for(const s of e.set){for(const i of t.set){const o=uoe(s,i,n);if(r=r||o!==null,o)continue e}if(r)return!1}return!0},loe=[new Vw(">=0.0.0-0")],DE=[new Vw(">=0.0.0")],uoe=(e,t,n)=>{if(e===t)return!0;if(e.length===1&&e[0].semver===fv){if(t.length===1&&t[0].semver===fv)return!0;n.includePrerelease?e=loe:e=DE}if(t.length===1&&t[0].semver===fv){if(n.includePrerelease)return!0;t=DE}const r=new Set;let s,i;for(const p of e)p.operator===">"||p.operator===">="?s=LE(s,p,n):p.operator==="<"||p.operator==="<="?i=$E(i,p,n):r.add(p.semver);if(r.size>1)return null;let o;if(s&&i){if(o=Uw(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&&!uc(p,String(s),n)||i&&!uc(p,String(i),n))return null;for(const g of t)if(!uc(p,String(g),n))return!1;return!0}let a,l,u,c,d=i&&!n.includePrerelease&&i.semver.prerelease.length?i.semver:!1,f=s&&!n.includePrerelease&&s.semver.prerelease.length?s.semver:!1;d&&d.prerelease.length===1&&i.operator==="<"&&d.prerelease[0]===0&&(d=!1);for(const p of t){if(c=c||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=LE(s,p,n),a===p&&a!==s)return!1}else if(s.operator===">="&&!uc(s.semver,String(p),n))return!1}if(i){if(d&&p.semver.prerelease&&p.semver.prerelease.length&&p.semver.major===d.major&&p.semver.minor===d.minor&&p.semver.patch===d.patch&&(d=!1),p.operator==="<"||p.operator==="<="){if(l=$E(i,p,n),l===p&&l!==i)return!1}else if(i.operator==="<="&&!uc(i.semver,String(p),n))return!1}if(!p.operator&&(i||s)&&o!==0)return!1}return!(s&&u&&!i&&o!==0||i&&c&&!s&&o!==0||f||d)},LE=(e,t,n)=>{if(!e)return t;const r=Uw(e.semver,t.semver,n);return r>0?e:r<0||t.operator===">"&&e.operator===">="?t:e},$E=(e,t,n)=>{if(!e)return t;const r=Uw(e.semver,t.semver,n);return r<0?e:r>0||t.operator==="<"&&e.operator==="<="?t:e};var coe=aoe;const hv=Kd,FE=Vm,doe=vr,NE=G2,foe=Gu,hoe=bse,poe=_se,moe=xse,goe=Cse,voe=Rse,yoe=Ose,boe=Lse,woe=Nse,Soe=Bs,_oe=zse,koe=qse,xoe=Lw,Eoe=Yse,Coe=Jse,Toe=zm,Poe=$w,Roe=K2,Ioe=Y2,Aoe=Fw,Ooe=Nw,Moe=X2,Doe=Sie,Loe=Hm(),$oe=Vs(),Foe=jm,Noe=Pie,Boe=Oie,Voe=$ie,Uoe=Bie,zoe=zie,Hoe=Bw,joe=Jie,qoe=toe,Woe=roe,Goe=ooe,Koe=coe;var cc={parse:foe,valid:hoe,clean:poe,inc:moe,diff:goe,major:voe,minor:yoe,patch:boe,prerelease:woe,compare:Soe,rcompare:_oe,compareLoose:koe,compareBuild:xoe,sort:Eoe,rsort:Coe,gt:Toe,lt:Poe,eq:Roe,neq:Ioe,gte:Aoe,lte:Ooe,cmp:Moe,coerce:Doe,Comparator:Loe,Range:$oe,satisfies:Foe,toComparators:Noe,maxSatisfying:Boe,minSatisfying:Voe,minVersion:Uoe,validRange:zoe,outside:Hoe,gtr:joe,ltr:qoe,intersects:Woe,simplifyRange:Goe,subset:Koe,SemVer:doe,re:hv.re,src:hv.src,tokens:hv.t,SEMVER_SPEC_VERSION:FE.SEMVER_SPEC_VERSION,RELEASE_TYPES:FE.RELEASE_TYPES,compareIdentifiers:NE.compareIdentifiers,rcompareIdentifiers:NE.rcompareIdentifiers};const Yoe={key:0},Xoe={key:1},Qoe={key:0},Joe=Le({__name:"SoftwareUpgradeSettings",setup(e){const t=j(""),n=j(!0),r=j(!1),s=j(!1),i=j(""),o=j(""),a=j(r2),l=j(),u=j(),c=j(),d=j(!1),f=j([]);St(async()=>{var E;await p();const S=await ma.getVersion();i.value=S.version,o.value=((E=S.monsterPi)==null?void 0:E.trim())||""});async function p(){n.value=!0,t.value="",r.value=!1;try{const S=await ma.getGithubRateLimit();if(S.rate.remaining===0){const I=new Date(S.rate.reset).toLocaleTimeString(),O=S.rate.reset*1e3-Date.now(),R=Math.ceil(O/6e4);t.value=`Server has reached a rate limit of the Github API. This limit will be reset at ${I} (in ${R} minutes)`,n.value=!1,r.value=!0;return}}catch{n.value=!1;return}try{const S=await ma.getClientReleases();l.value=S.current,u.value=S.minimum,f.value=S.releases}catch(S){t.value="An error occurred loading the releases: "+S.message}finally{n.value=!1}}const g=A(()=>f.value.filter(S=>{const E=cc.minor(S.tag_name)===cc.minor(u.value.tag_name),I=k(S),O=S.draft;return E&&(y()||d.value||!I)&&!O})),m=A(()=>y());function y(){const S=l.value;return k(S)}function w(S){return T(S)||!_(S,l.value)||C(S)}function b(S){const E=k(S)?`${S.tag_name}, unstable`:S.tag_name;return T(S)?`${E}, currently installed`:C(S)?`${E}, below minimum`:_(S,l.value)?E:`${E}, downgrade not allowed`}function k(S){var E;return(E=S==null?void 0:S.tag_name)!=null&&E.length?S.prerelease||S.tag_name.includes("rc")||S.tag_name.includes("unstable"):!1}function C(S){return cc.compare(S.tag_name,u.value.tag_name)===-1}function _(S,E){if(!E)throw new Error("No current release is known, cannot compare.");return s.value?!0:cc.compare(S.tag_name,E.tag_name)!==-1&&cc.compare(S.tag_name,u.value.tag_name)!==-1}function T(S){var E;return S.tag_name===((E=l.value)==null?void 0:E.tag_name)}async function P(S){confirm("Are you sure? This might cause breaking changes, if the server is outdated")&&(await ma.updateClientDistGithub(S,s.value),location.reload())}return(S,E)=>($(),te(vt,null,{default:v(()=>[h(mr,{color:"primary"},{default:v(()=>[h(ut,null,{default:v(()=>[h(J,null,{default:v(()=>E[5]||(E[5]=[x("upgrade")])),_:1})]),_:1}),h(En,null,{default:v(()=>E[6]||(E[6]=[x(" Software Upgrade")])),_:1})]),_:1}),h(Ut,{lines:"three"},{default:v(()=>[h(Ve,null,{default:v(()=>[h(ft,null,{default:v(()=>E[7]||(E[7]=[x(" Current versions in use:")])),_:1}),h(bt,null,{default:v(()=>[x(" Your server's version is: "+re(i.value),1)]),_:1}),h(bt,null,{default:v(()=>[x(" Your client's version is: "+re(a.value),1)]),_:1}),h(bt,null,{default:v(()=>[o.value?($(),ve("div",Yoe,[E[8]||(E[8]=x(" MonsterPi: ")),E[9]||(E[9]=L("div",null,"Your MonsterPi version is:",-1)),x(" "+re(o.value),1)])):($(),ve("div",Xoe,E[10]||(E[10]=[x(" MonsterPi: "),L("div",null,"No MonsterPi distro was detected.",-1)])))]),_:1})]),_:1})]),_:1}),h(dn),h(Ut,{lines:"three",subheader:""},{default:v(()=>[h(Ve,null,{default:v(()=>[h(ft,null,{default:v(()=>E[11]||(E[11]=[x(" Server upgrade")])),_:1}),h(bt,null,{default:v(()=>E[12]||(E[12]=[x(" Please visit "),L("a",{href:"https://docs.fdm-monster.net/docs/installing/"}," the installation documentation ",-1),x(" for instructions on how to upgrade the server. ")])),_:1})]),_:1})]),_:1}),h(dn),h(Ut,{lines:"three"},{default:v(()=>[h(Ve,null,{default:v(()=>[h(ft,null,{default:v(()=>E[13]||(E[13]=[x(" Client upgrade")])),_:1}),h(bt,null,{default:v(()=>E[14]||(E[14]=[x(" Please visit "),L("a",{href:"https://docs.fdm-monster.net/docs/configuration/updating_client_bundle"}," the installation documentation ",-1),x(" for instructions on how to upgrade the client bundle. ")])),_:1}),h(bt,null,{default:v(()=>E[15]||(E[15]=[x(" Upgrade the client webapp for quickly retrieving small fixes and features ")])),_:1})]),_:1}),h(Ve,null,{default:v(()=>{var I,O,R;return[h(ft,null,{default:v(()=>E[16]||(E[16]=[x(" Select a release to upgrade to:")])),_:1}),h(bt,{class:"mt-2"},{default:v(()=>{var M;return[x(" Minimum required version: "+re((M=u.value)==null?void 0:M.tag_name),1)]}),_:1}),n.value?($(),ve("span",Qoe,[h(fn,null,{default:v(()=>E[17]||(E[17]=[x(" Loading releases... ")])),_:1})])):pe("",!0),!n.value&&!((I=g.value)!=null&&I.length)?($(),te(fn,{key:1},{default:v(()=>E[18]||(E[18]=[x(" No releases to show. ")])),_:1})):pe("",!0),h(kO,{modelValue:c.value,"onUpdate:modelValue":E[0]||(E[0]=M=>c.value=M)},{default:v(()=>[($(!0),ve(Ae,null,Gt(g.value,M=>($(),te(zy,{key:M.tag_name,disabled:w(M),label:b(M),value:M.tag_name},null,8,["disabled","label","value"]))),128))]),_:1},8,["modelValue"]),L("div",null,[d.value?($(),te(fn,{key:0,color:"primary","max-width":"500px"},{default:v(()=>E[19]||(E[19]=[x(" You are viewing prereleases, please install such versions at your own risk! ")])),_:1})):pe("",!0)]),L("div",null,[h(mn,{modelValue:s.value,"onUpdate:modelValue":E[1]||(E[1]=M=>s.value=M),label:"Allow downgrade"},null,8,["modelValue"]),h(mn,{modelValue:d.value,"onUpdate:modelValue":E[2]||(E[2]=M=>d.value=M),disabled:m.value,label:m.value?"Show prerelease versions (Currently already on prerelease version)":"Show prerelease versions"},null,8,["modelValue","disabled","label"])]),h(se,{class:"mt-2 mr-4",color:"secondary",onClick:E[3]||(E[3]=M=>p())},{default:v(()=>E[20]||(E[20]=[x(" Reload release version list ")])),_:1}),h(se,{disabled:!((O=c.value)!=null&&O.length)||c.value===((R=l.value)==null?void 0:R.tag_name),class:"mt-2",color:"primary",variant:"flat",onClick:E[4]||(E[4]=M=>P(c.value))},{default:v(()=>[h(J,null,{default:v(()=>E[21]||(E[21]=[x("upgrade")])),_:1}),E[22]||(E[22]=x(" Upgrade/downgrade client "))]),_:1},8,["disabled"])]}),_:1})]),_:1})]),_:1}))}}),Zoe=Le({__name:"DiagnosticsSettings",setup(e){const t=Dt(),n=Ns(),r=j(!1);St(async()=>{var l;await n.loadSettings(),r.value=((l=n.serverSettings)==null?void 0:l.sentryDiagnosticsEnabled)||!1});async function s(){await bn.setSentryDiagnosticsSettings(r.value),CM(r.value)}async function i(){const l=`Test Error ${Date.now()} Sentry enabled: ${r.value}`;try{throw new Error(l)}catch(u){ai(u),t.openInfoMessage({title:"Test report was sent",subtitle:`Content: ${l}`})}}async function o(){await cp.downloadLogDump()}async function a(){await cp.clearLogFilesOlderThanWeek(),t.openInfoMessage({title:"Action success",subtitle:"Log files older than a week have been deleted"})}return(l,u)=>($(),te(vt,null,{default:v(()=>[h(mr,{color:"primary"},{default:v(()=>[h(ut,null,{default:v(()=>[h(J,null,{default:v(()=>u[5]||(u[5]=[x("bug_report")])),_:1})]),_:1}),h(En,null,{default:v(()=>u[6]||(u[6]=[x(" Diagnostics")])),_:1})]),_:1}),h(Ut,{lines:"three",subheader:""},{default:v(()=>[h(qr,null,{default:v(()=>u[7]||(u[7]=[x(" Diagnostics to provide bug reports to the developers of this software ")])),_:1}),h(Ve,null,{default:v(()=>[h(ft,null,{default:v(()=>u[8]||(u[8]=[x(" Remote Sentry diagnostic reports: ")])),_:1}),h(bt,null,{default:v(()=>[h(mn,{modelValue:r.value,"onUpdate:modelValue":u[0]||(u[0]=c=>r.value=c),label:"Enable remote Sentry diagnostic reports"},null,8,["modelValue"])]),_:1}),h(bt,null,{default:v(()=>[h(se,{color:"primary",onClick:u[1]||(u[1]=c=>s())},{default:v(()=>[h(J,{class:"pr-2"},{default:v(()=>u[9]||(u[9]=[x("save")])),_:1}),u[10]||(u[10]=x(" Save "))]),_:1}),h(se,{color:"secondary",onClick:u[2]||(u[2]=c=>i())},{default:v(()=>[h(J,{class:"pr-2"},{default:v(()=>u[11]||(u[11]=[x("bug_report")])),_:1}),u[12]||(u[12]=x(" Test Error "))]),_:1})]),_:1})]),_:1}),h(dn),h(Ve,null,{default:v(()=>[h(ft,null,{default:v(()=>u[13]||(u[13]=[x(" Logs Dump")])),_:1}),h(bt,null,{default:v(()=>u[14]||(u[14]=[x(" Download a .zip file containing all logs from the server ")])),_:1}),h(bt,null,{default:v(()=>[u[17]||(u[17]=L("br",null,null,-1)),h(se,{color:"primary",onClick:u[3]||(u[3]=c=>o())},{default:v(()=>[h(J,null,{default:v(()=>u[15]||(u[15]=[x("download")])),_:1}),u[16]||(u[16]=x(" Download Log Files (.zip) "))]),_:1})]),_:1})]),_:1}),h(Ve,null,{default:v(()=>[h(ft,null,{default:v(()=>u[18]||(u[18]=[x(" Clear log files")])),_:1}),h(bt,null,{default:v(()=>[u[21]||(u[21]=L("br",null,null,-1)),h(se,{color:"default",onClick:u[4]||(u[4]=c=>a())},{default:v(()=>[h(J,null,{default:v(()=>u[19]||(u[19]=[x("download")])),_:1}),u[20]||(u[20]=x(" Clear log files older than a week "))]),_:1})]),_:1})]),_:1})]),_:1})]),_:1}))}});class eae extends gr{static async getCompletions(){const t=`${Me.printCompletionRoute}`;return await this.get(t)}}const J2=Le({__name:"PrintStatistics",setup(e){const t=j([]),n=j([]),r=j(""),s=Ft(),i=Qi();St(async()=>{await o()}),Ee([()=>r.value],()=>{u()});const o=async()=>{t.value=[],n.value=[],t.value=await eae.getCompletions(),u()},a=c=>s.printer(c),l=c=>i.floorOfPrinter(c),u=()=>{var p;const c=s.printers.map(g=>g.id),d=c.length?t.value.filter(g=>c.includes(g.printerId)):t.value,f=(p=r.value)!=null&&p.length?d.filter(g=>{const m=s.printers.find(y=>y.id===g.printerId);return m?(m.name+m.printerURL).toLowerCase().includes(r.value.toLowerCase()):!1}):d;n.value=f.sort((g,m)=>g.failureCount===m.failureCount?g.printCount>m.printCount?-1:1:g.failureCount>m.failureCount?-1:1)};return(c,d)=>($(),te(dp,{height:"100%",width:"100%"},{default:v(()=>[h(Un,null,{default:v(()=>[h(rt,null,{default:v(()=>[h(ze,null,{default:v(()=>[h(J,null,{default:v(()=>d[2]||(d[2]=[x("filter_list")])),_:1}),d[3]||(d[3]=x(" Filter by printer name (optional) "))]),_:1}),h(ze,null,{default:v(()=>[h(at,{modelValue:r.value,"onUpdate:modelValue":d[0]||(d[0]=f=>r.value=f),class:"p-2",clearable:"",label:"Search","prepend-icon":"search","single-line":""},null,8,["modelValue"])]),_:1})]),_:1})]),_:1}),h(fn,null,{default:v(()=>[d[5]||(d[5]=x(" Please reload here if you want updated results: ")),h(se,{color:"primary",size:"x-small",onClick:d[1]||(d[1]=f=>o())},{default:v(()=>d[4]||(d[4]=[x(" Reload ")])),_:1})]),_:1}),h(mb,{dark:""},{default:v(()=>[d[11]||(d[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),ve(Ae,null,Gt(n.value,f=>{var p,g,m,y;return $(),ve("tr",{key:f.printerId},[L("td",null,re(((p=a(f.printerId))==null?void 0:p.name)??"?"),1),L("td",null,re(((g=l(f.printerId))==null?void 0:g.name)??"?"),1),L("td",null,[x(" × "+re(f.failureCount)+" / 🗸 "+re(f.successCount)+" ",1),L("strong",null," ~"+re(f.printCount),1)]),L("td",null,re(Date.now()-((m=f.lastSuccess)==null?void 0:m.createdAt)||"-"),1),L("td",null,[h(nt,{location:"bottom"},qC({default:v(()=>{var w,b,k,C;return[L("span",null,[x(re(((w=f.lastFailure)==null?void 0:w.status)||"-")+" ",1),d[7]||(d[7]=L("br",null,null,-1)),x(" "+re((b=f.lastFailure)==null?void 0:b.createdAt)+" ",1),d[8]||(d[8]=L("br",null,null,-1)),L("small",null,re((k=f.lastFailure)==null?void 0:k.fileName),1),d[9]||(d[9]=L("br",null,null,-1)),L("strong",null,re((C=f.lastFailure)==null?void 0:C.completionLog),1),d[10]||(d[10]=L("br",null,null,-1))])]}),_:2},[(y=f.lastFailure)!=null&&y.status?{name:"activator",fn:v(({props:w})=>[h(J,ge({ref_for:!0},w),{default:v(()=>d[6]||(d[6]=[x("info")])),_:2},1040)]),key:"0"}:void 0]),1024)]),L("td",null,re(f.successEventsLastWeek)+" "+re(f.successEventsLast48H)+" "+re(f.successEventsLast24H),1),L("td",null,re(f.failureEventsLastWeek)+" "+re(f.failureEventsLast48H)+" "+re(f.failureEventsLast24H),1)])}),128))])]),_:1})]),_:1}))}}),tae=Le({name:"PrintStatisticsView",components:{PrintStatistics:J2}});function nae(e,t,n,r,s,i){const o=J2;return $(),te(Un,null,{default:v(()=>[h(o)]),_:1})}const rae=Ko(tae,[["render",nae]]),sae=Le({__name:"ExperimentalSettings",setup(e){const t=j(!1),n=j(!1),r=j(!1),s=j(!1);async function i(){const u=await bn.getSettings();t.value=u.server.experimentalMoonrakerSupport,n.value=u.server.experimentalPrusaLinkSupport,r.value=u.server.experimentalTypeormSupport,s.value=u.server.experimentalClientSupport}St(async()=>{await i()});const o=async()=>{await bn.updateExperimentalMoonrakerSupport(t.value),await bn.updateExperimentalPrusaLinkSupport(n.value),await bn.updateExperimentalClientSupport(s.value),await i()},a=async()=>{await bn.updateExperimentalMoonrakerSupport(!1),await bn.updateExperimentalPrusaLinkSupport(!1),await bn.updateExperimentalClientSupport(!1),await i()},l=async()=>{await bn.updateExperimentalClientSupport(s.value),window.location.reload()};return(u,c)=>($(),te(rt,null,{default:v(()=>[h(ze,{cols:"12"},{default:v(()=>[h(vt,null,{default:v(()=>[h(sn,null,{default:v(()=>c[4]||(c[4]=[L("h2",null,"Settings",-1)])),_:1}),h(en,null,{default:v(()=>[h(rt,null,{default:v(()=>[h(ze,{cols:"12",md:"6"},{default:v(()=>[h(vt,null,{default:v(()=>[h(sn,null,{default:v(()=>[L("h3",null,[c[7]||(c[7]=x(" Experimental Features ")),h(nt,{bottom:""},{activator:v(({props:d})=>[h(J,ge({class:"help-icon"},d),{default:v(()=>c[5]||(c[5]=[x("help_outline")])),_:2},1040)]),default:v(()=>[c[6]||(c[6]=L("span",{class:"tooltip-content"}," Moonraker support is currently in beta, use at your own risk. ",-1))]),_:1})])]),_:1}),h(en,null,{default:v(()=>[h(mn,{modelValue:t.value,"onUpdate:modelValue":c[0]||(c[0]=d=>t.value=d),label:"Enable Experimental Moonraker Support","hide-details":""},{label:v(()=>c[8]||(c[8]=[L("span",null,"Enable Experimental Moonraker Support",-1)])),_:1},8,["modelValue"]),h(mn,{modelValue:n.value,"onUpdate:modelValue":c[1]||(c[1]=d=>n.value=d),label:"Enable Experimental PrusaLink Support","hide-details":""},{label:v(()=>c[9]||(c[9]=[L("span",null,"Enable Experimental PrusaLink Support",-1)])),_:1},8,["modelValue"])]),_:1})]),_:1})]),_:1}),h(ze,{cols:"12",md:"6"},{default:v(()=>[h(vt,null,{default:v(()=>[h(sn,null,{default:v(()=>[L("h3",null,[c[12]||(c[12]=x(" Database Settings ")),h(nt,{bottom:""},{activator:v(({props:d})=>[h(J,yv(Rh(d)),{default:v(()=>c[10]||(c[10]=[x("help_outline")])),_:2},1040)]),default:v(()=>[c[11]||(c[11]=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(en,null,{default:v(()=>[h(mn,{modelValue:r.value,"onUpdate:modelValue":c[2]||(c[2]=d=>r.value=d),label:"Enable TypeORM Support","hide-details":"",disabled:""},{label:v(()=>c[13]||(c[13]=[L("span",null,"Enable TypeORM Support",-1)])),_:1},8,["modelValue"])]),_:1})]),_:1})]),_:1}),h(ze,{cols:"12",md:"6"},{default:v(()=>[h(vt,null,{default:v(()=>[h(sn,null,{default:v(()=>[L("h3",null,[c[16]||(c[16]=x(" Experimental Features ")),h(nt,{bottom:""},{activator:v(({props:d})=>[h(J,ge({class:"help-icon"},d),{default:v(()=>c[14]||(c[14]=[x("help_outline")])),_:2},1040)]),default:v(()=>[c[15]||(c[15]=L("span",{class:"tooltip-content"}," Enables the next version of the FDM Monster UI (experimental). ",-1))]),_:1})])]),_:1}),h(en,null,{default:v(()=>[h(mn,{modelValue:s.value,"onUpdate:modelValue":c[3]||(c[3]=d=>s.value=d),label:"Enable Next Client Version (Experimental)","hide-details":"",onChange:l},{label:v(()=>c[17]||(c[17]=[L("span",null,"Enable Next Client Version (Experimental)",-1)])),_:1},8,["modelValue"])]),_:1})]),_:1})]),_:1})]),_:1})]),_:1}),h(Mn,null,{default:v(()=>[h(Sn),h(se,{color:"primary",onClick:o},{default:v(()=>c[18]||(c[18]=[x("Save Settings")])),_:1}),h(se,{onClick:a},{default:v(()=>c[19]||(c[19]=[x("Reset to Default")])),_:1})]),_:1})]),_:1})]),_:1})]),_:1}))}}),qn={requiresAuth:!0},pv={requiresAuth:!1},zw=pY({history:HK("/"),routes:[{path:"/",name:Wt.Home,meta:qn,component:$Q},{path:"/first-time-setup",name:Wt.FirstTimeSetup,meta:pv,component:Jre},{path:"/login",name:Wt.Login,meta:pv,component:Dre},{path:"/registration",name:Wt.Registration,meta:pv,component:Fre},{path:"/printers",name:Wt.PrintersView,meta:qn,component:XJ},{path:"/cameras",name:Wt.CameraGridView,component:Bre},{path:"/settings",component:JJ,meta:qn,children:[{path:"",meta:qn,redirect:"/settings/grid"},{path:"account",meta:qn,component:tse},{path:"server-protection",meta:qn,component:rse},{path:"grid",meta:qn,component:nse},{path:"floors",meta:qn,component:vZ},{path:"user-management",meta:qn,component:cZ},{path:"octoprint",meta:qn,component:hZ},{path:"emergency-commands",meta:qn,component:Sre},{path:"software-upgrade",meta:qn,component:Joe},{path:"diagnostics",meta:qn,component:Zoe},{path:"experimental",meta:qn,component:sae}]},{path:"/statistics",name:Wt.PrintStatistics,meta:qn,component:rae},{path:"/about",name:"About",component:SZ},{path:"/permission-denied",name:Wt.PermissionDenied,meta:qn,component:Rre},{path:"/:pathMatch(.*)*",name:"NotFound",component:kre}]});zw.beforeEach(async(e,t,n)=>{var s,i;const r=us();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 iae={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"},oae={component:e=>pr(BF,{...e,class:"material-icons"})};function Z2(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const{blueprint:t,...n}=e,r=Zn(t,n),{aliases:s={},components:i={},directives:o={}}=r,a=$a();return a.run(()=>{const l=mF(r.defaults),u=PN(r.display,r.ssr),c=AF(r.theme),d=UF(r.icons),f=YF(r.locale),p=P7(r.date,f),g=Bq(r.goTo,f);function m(w){for(const k in o)w.directive(k,o[k]);for(const k in i)w.component(k,i[k]);for(const k in s)w.component(k,_u({...s[k],name:k,aliasName:s[k].name}));const b=$a();if(b.run(()=>{c.install(w)}),w.onUnmount(()=>b.stop()),w.provide(ru,l),w.provide(Gv,u),w.provide(Gc,c),w.provide(Uv,d),w.provide(Bh,f),w.provide(T7,p.options),w.provide(_k,p.instance),w.provide(IA,g),Et&&r.ssr)if(w.$nuxt)w.$nuxt.hook("app:suspense:resolve",()=>{u.update()});else{const{mount:k}=w;w.mount=function(){const C=k(...arguments);return Mt(()=>u.update()),w.mount=k,C}}w.mixin({computed:{$vuetify(){return cn({defaults:yl.call(this,ru),display:yl.call(this,Gv),theme:yl.call(this,Gc),icons:yl.call(this,Uv),locale:yl.call(this,Bh),date:yl.call(this,_k)})}}})}function y(){a.stop()}return{install:m,unmount:y,defaults:l,display:u,theme:c,icons:d,locale:f,date:p,goTo:g}})}const aae="3.8.4";Z2.version=aae;function yl(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 lae=Z2({theme:{defaultTheme:"dark",themes:{dark:{dark:!0,colors:{primary:"#1eb6c3",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:iae,sets:{md:oae}}}),uae=_$();function cae(e){e.use(lae).use(z9).use(uae)}const BE=(e,t,n)=>{const r=Ft(),s=gw(),i=Dt();if(t!=null&&t.length){const o=t.length===1,a=t[0];e.ondrop=async l=>{var f;l.preventDefault(),e.style.border=Ep;const u=(f=l.dataTransfer)==null?void 0:f.files;if(!(u!=null&&u.length))return;const c=[...Array.from(u)];let d=[];if(o){const p=c.length===1?c[0].name:null;console.debug("Single printer upload mode",t.length,c.length,p),d=EQ(a,c)}else{if(c.length>1)throw"Cannot upload multiple files to multiple printers";console.debug("Multi printer upload mode",t.length,c.length);const p=c[0];d=OM(t,p)}s.queueUploads(d),r.clearSelectedPrinters()}}else e.ondrop=async o=>{o.preventDefault(),e.style.border=Ep,i.openInfoMessage({title:"No action performed",subtitle:"Please select one or more printers",warning:!0})}},Ep="1px solid #2b2a27",dae="background-color 0.5s ease",VE="1px solid red";function fae(){return{mounted:(e,t,n)=>{var r;e.style.border=Ep,e.style.transition=dae,e.ondragenter=s=>{s.preventDefault(),e.style.border=VE},e.ondragover=s=>{s.preventDefault(),e.style.border=VE},e.ondragleave=s=>{s.preventDefault(),e.style.border=Ep},BE(e,(r=t.value)==null?void 0:r.printers,n.appContext)},beforeUpdate:(e,t,n)=>{BE(e,t.value,n.appContext)}}}const mv="1px solid #2b2a27",hae="1px solid gray",UE=(e,t,n)=>{const r=t==null?void 0:t.printerSet,s=Qi();if(r){e.ondrop=null,e.ondragover=null,e.ondragleave=null;return}e.style.border=mv,e.ondrop=async i=>{var d;if(e.style.border=mv,i.preventDefault(),!i.dataTransfer)return;const o=i.dataTransfer.getData("text"),a=JSON.parse(o);if(!mQ(a)){console.debug("Drop not recognized",a);return}const u=(d=s.selectedFloor)==null?void 0:d.id;if(!u)throw new Error("Floor is not set");const c=a.printerId;if(!c)throw new Error("PrinterId was not provided");await ns.addPrinterToFloor(u,{printerId:c,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=hae,i.preventDefault()))},e.ondragleave=i=>{e.style.border=mv,i.preventDefault()}};function pae(){return{mounted:(e,t,n)=>{UE(e,t.value,n.appContext)},beforeUpdate:(e,t,n)=>{UE(e,t.value,n.appContext)}}}const Yo=b$(rQ);console.log("[DEV: false][PROD: true]","0.0.20");vq({app:Yo,dsn:"https://f64683e8d1cb4ac291434993cff1bf9b@o4503975545733120.ingest.sentry.io/4503975546912768",integrations:[wq({router:zw}),L6()],release:"0.0.20",environment:"production",enabled:!0,tracesSampleRate:1,replaysSessionSampleRate:.1,replaysOnErrorSampleRate:1});Yo.config.errorHandler=e=>{var t;if(e instanceof eR){console.error(`An error was caught [${e.name}]:
|
|
88
|
+
${e.message}
|
|
89
|
+
${(t=e.config)==null?void 0:t.url}
|
|
90
|
+
${e.stack}`),Dt().openErrorMessage({title:"An error occurred",subtitle:e.message,timeout:5e3});return}else console.error(`An error was caught [${e.name}]:
|
|
91
|
+
${e.message}
|
|
92
|
+
${e.stack}`);Dt().openErrorMessage({title:"An error occurred",subtitle:e.message,timeout:5e3}),ai(e)};Yo.directive("drop-upload",fae());Yo.directive("drop-printer-position",pae());cae(Yo);Yo.provide("appConstants",wY());Yo.use(zw);Yo.mount("#app");
|
|
93
|
+
//# sourceMappingURL=index-CXYoPsmd.js.map
|