var ki=Object.defineProperty;var Ai=(e,t,n)=>t in e?ki(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var uo=(e,t,n)=>(Ai(e,typeof t!="symbol"?t+"":t,n),n);(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))s(o);new MutationObserver(o=>{for(const r of o)if(r.type==="childList")for(const i of r.addedNodes)i.tagName==="LINK"&&i.rel==="modulepreload"&&s(i)}).observe(document,{childList:!0,subtree:!0});function n(o){const r={};return o.integrity&&(r.integrity=o.integrity),o.referrerPolicy&&(r.referrerPolicy=o.referrerPolicy),o.crossOrigin==="use-credentials"?r.credentials="include":o.crossOrigin==="anonymous"?r.credentials="omit":r.credentials="same-origin",r}function s(o){if(o.ep)return;o.ep=!0;const r=n(o);fetch(o.href,r)}})();function Ms(e,t){const n=Object.create(null),s=e.split(",");for(let o=0;o!!n[o.toLowerCase()]:o=>!!n[o]}const le={},kt=[],De=()=>{},Ti=()=>!1,Mi=/^on[^a-z]/,$n=e=>Mi.test(e),Ls=e=>e.startsWith("onUpdate:"),ve=Object.assign,$s=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},Li=Object.prototype.hasOwnProperty,Y=(e,t)=>Li.call(e,t),V=Array.isArray,At=e=>fn(e)==="[object Map]",Dn=e=>fn(e)==="[object Set]",ao=e=>fn(e)==="[object Date]",K=e=>typeof e=="function",he=e=>typeof e=="string",nn=e=>typeof e=="symbol",ie=e=>e!==null&&typeof e=="object",ar=e=>ie(e)&&K(e.then)&&K(e.catch),fr=Object.prototype.toString,fn=e=>fr.call(e),$i=e=>fn(e).slice(8,-1),dr=e=>fn(e)==="[object Object]",Ds=e=>he(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,bn=Ms(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),Fn=e=>{const t=Object.create(null);return n=>t[n]||(t[n]=e(n))},Di=/-(\w)/g,ze=Fn(e=>e.replace(Di,(t,n)=>n?n.toUpperCase():"")),Fi=/\B([A-Z])/g,wt=Fn(e=>e.replace(Fi,"-$1").toLowerCase()),jn=Fn(e=>e.charAt(0).toUpperCase()+e.slice(1)),ss=Fn(e=>e?`on${jn(e)}`:""),sn=(e,t)=>!Object.is(e,t),En=(e,t)=>{for(let n=0;n{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,value:n})},ps=e=>{const t=parseFloat(e);return isNaN(t)?e:t};let fo;const hs=()=>fo||(fo=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function Fs(e){if(V(e)){const t={};for(let n=0;n{if(n){const s=n.split(Ni);s.length>1&&(t[s[0].trim()]=s[1].trim())}}),t}function _t(e){let t="";if(he(e))t=e;else if(V(e))for(let n=0;nNn(n,t))}const Ke=e=>he(e)?e:e==null?"":V(e)||ie(e)&&(e.toString===fr||!K(e.toString))?JSON.stringify(e,gr,2):String(e),gr=(e,t)=>t&&t.__v_isRef?gr(e,t.value):At(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((n,[s,o])=>(n[`${s} =>`]=o,n),{})}:Dn(t)?{[`Set(${t.size})`]:[...t.values()]}:ie(t)&&!V(t)&&!dr(t)?String(t):t;let ke;class mr{constructor(t=!1){this.detached=t,this._active=!0,this.effects=[],this.cleanups=[],this.parent=ke,!t&&ke&&(this.index=(ke.scopes||(ke.scopes=[])).push(this)-1)}get active(){return this._active}run(t){if(this._active){const n=ke;try{return ke=this,t()}finally{ke=n}}}on(){ke=this}off(){ke=this.parent}stop(t){if(this._active){let n,s;for(n=0,s=this.effects.length;n{const t=new Set(e);return t.w=0,t.n=0,t},yr=e=>(e.w&ct)>0,br=e=>(e.n&ct)>0,qi=({deps:e})=>{if(e.length)for(let t=0;t{const{deps:t}=e;if(t.length){let n=0;for(let s=0;s{(a==="length"||a>=c)&&l.push(u)})}else switch(n!==void 0&&l.push(i.get(n)),t){case"add":V(e)?Ds(n)&&l.push(i.get("length")):(l.push(i.get(yt)),At(e)&&l.push(i.get(ms)));break;case"delete":V(e)||(l.push(i.get(yt)),At(e)&&l.push(i.get(ms)));break;case"set":At(e)&&l.push(i.get(yt));break}if(l.length===1)l[0]&&_s(l[0]);else{const c=[];for(const u of l)u&&c.push(...u);_s(js(c))}}function _s(e,t){const n=V(e)?e:[...e];for(const s of n)s.computed&&ho(s);for(const s of n)s.computed||ho(s)}function ho(e,t){(e!==Le||e.allowRecurse)&&(e.scheduler?e.scheduler():e.run())}function Qi(e,t){var n;return(n=Pn.get(e))==null?void 0:n.get(t)}const Yi=Ms("__proto__,__v_isRef,__isVue"),xr=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(nn)),Xi=Vs(),Zi=Vs(!1,!0),Gi=Vs(!0),go=el();function el(){const e={};return["includes","indexOf","lastIndexOf"].forEach(t=>{e[t]=function(...n){const s=X(this);for(let r=0,i=this.length;r{e[t]=function(...n){Vt();const s=X(this)[t].apply(this,n);return Ut(),s}}),e}function tl(e){const t=X(this);return Oe(t,"has",e),t.hasOwnProperty(e)}function Vs(e=!1,t=!1){return function(s,o,r){if(o==="__v_isReactive")return!e;if(o==="__v_isReadonly")return e;if(o==="__v_isShallow")return t;if(o==="__v_raw"&&r===(e?t?_l:Ir:t?Cr:Or).get(s))return s;const i=V(s);if(!e){if(i&&Y(go,o))return Reflect.get(go,o,r);if(o==="hasOwnProperty")return tl}const l=Reflect.get(s,o,r);return(nn(o)?xr.has(o):Yi(o))||(e||Oe(s,"get",o),t)?l:ae(l)?i&&Ds(o)?l:l.value:ie(l)?e?kr(l):Bt(l):l}}const nl=Rr(),sl=Rr(!0);function Rr(e=!1){return function(n,s,o,r){let i=n[s];if(Mt(i)&&ae(i)&&!ae(o))return!1;if(!e&&(!On(o)&&!Mt(o)&&(i=X(i),o=X(o)),!V(n)&&ae(i)&&!ae(o)))return i.value=o,!0;const l=V(n)&&Ds(s)?Number(s)e,Vn=e=>Reflect.getPrototypeOf(e);function hn(e,t,n=!1,s=!1){e=e.__v_raw;const o=X(e),r=X(t);n||(t!==r&&Oe(o,"get",t),Oe(o,"get",r));const{has:i}=Vn(o),l=s?Us:n?Ks:on;if(i.call(o,t))return l(e.get(t));if(i.call(o,r))return l(e.get(r));e!==o&&e.get(t)}function gn(e,t=!1){const n=this.__v_raw,s=X(n),o=X(e);return t||(e!==o&&Oe(s,"has",e),Oe(s,"has",o)),e===o?n.has(e):n.has(e)||n.has(o)}function mn(e,t=!1){return e=e.__v_raw,!t&&Oe(X(e),"iterate",yt),Reflect.get(e,"size",e)}function mo(e){e=X(e);const t=X(this);return Vn(t).has.call(t,e)||(t.add(e),Ye(t,"add",e,e)),this}function _o(e,t){t=X(t);const n=X(this),{has:s,get:o}=Vn(n);let r=s.call(n,e);r||(e=X(e),r=s.call(n,e));const i=o.call(n,e);return n.set(e,t),r?sn(t,i)&&Ye(n,"set",e,t):Ye(n,"add",e,t),this}function vo(e){const t=X(this),{has:n,get:s}=Vn(t);let o=n.call(t,e);o||(e=X(e),o=n.call(t,e)),s&&s.call(t,e);const r=t.delete(e);return o&&Ye(t,"delete",e,void 0),r}function yo(){const e=X(this),t=e.size!==0,n=e.clear();return t&&Ye(e,"clear",void 0,void 0),n}function _n(e,t){return function(s,o){const r=this,i=r.__v_raw,l=X(i),c=t?Us:e?Ks:on;return!e&&Oe(l,"iterate",yt),i.forEach((u,a)=>s.call(o,c(u),c(a),r))}}function vn(e,t,n){return function(...s){const o=this.__v_raw,r=X(o),i=At(r),l=e==="entries"||e===Symbol.iterator&&i,c=e==="keys"&&i,u=o[e](...s),a=n?Us:t?Ks:on;return!t&&Oe(r,"iterate",c?ms:yt),{next(){const{value:p,done:h}=u.next();return h?{value:p,done:h}:{value:l?[a(p[0]),a(p[1])]:a(p),done:h}},[Symbol.iterator](){return this}}}}function et(e){return function(...t){return e==="delete"?!1:this}}function ul(){const e={get(r){return hn(this,r)},get size(){return mn(this)},has:gn,add:mo,set:_o,delete:vo,clear:yo,forEach:_n(!1,!1)},t={get(r){return hn(this,r,!1,!0)},get size(){return mn(this)},has:gn,add:mo,set:_o,delete:vo,clear:yo,forEach:_n(!1,!0)},n={get(r){return hn(this,r,!0)},get size(){return mn(this,!0)},has(r){return gn.call(this,r,!0)},add:et("add"),set:et("set"),delete:et("delete"),clear:et("clear"),forEach:_n(!0,!1)},s={get(r){return hn(this,r,!0,!0)},get size(){return mn(this,!0)},has(r){return gn.call(this,r,!0)},add:et("add"),set:et("set"),delete:et("delete"),clear:et("clear"),forEach:_n(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach(r=>{e[r]=vn(r,!1,!1),n[r]=vn(r,!0,!1),t[r]=vn(r,!1,!0),s[r]=vn(r,!0,!0)}),[e,n,t,s]}const[al,fl,dl,pl]=ul();function Bs(e,t){const n=t?e?pl:dl:e?fl:al;return(s,o,r)=>o==="__v_isReactive"?!e:o==="__v_isReadonly"?e:o==="__v_raw"?s:Reflect.get(Y(n,o)&&o in s?n:s,o,r)}const hl={get:Bs(!1,!1)},gl={get:Bs(!1,!0)},ml={get:Bs(!0,!1)},Or=new WeakMap,Cr=new WeakMap,Ir=new WeakMap,_l=new WeakMap;function vl(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function yl(e){return e.__v_skip||!Object.isExtensible(e)?0:vl($i(e))}function Bt(e){return Mt(e)?e:Hs(e,!1,Pr,hl,Or)}function Sr(e){return Hs(e,!1,cl,gl,Cr)}function kr(e){return Hs(e,!0,ll,ml,Ir)}function Hs(e,t,n,s,o){if(!ie(e)||e.__v_raw&&!(t&&e.__v_isReactive))return e;const r=o.get(e);if(r)return r;const i=yl(e);if(i===0)return e;const l=new Proxy(e,i===2?s:n);return o.set(e,l),l}function it(e){return Mt(e)?it(e.__v_raw):!!(e&&e.__v_isReactive)}function Mt(e){return!!(e&&e.__v_isReadonly)}function On(e){return!!(e&&e.__v_isShallow)}function Ar(e){return it(e)||Mt(e)}function X(e){const t=e&&e.__v_raw;return t?X(t):e}function Un(e){return Rn(e,"__v_skip",!0),e}const on=e=>ie(e)?Bt(e):e,Ks=e=>ie(e)?kr(e):e;function Tr(e){rt&&Le&&(e=X(e),wr(e.dep||(e.dep=js())))}function Mr(e,t){e=X(e);const n=e.dep;n&&_s(n)}function ae(e){return!!(e&&e.__v_isRef===!0)}function fe(e){return Lr(e,!1)}function bl(e){return Lr(e,!0)}function Lr(e,t){return ae(e)?e:new El(e,t)}class El{constructor(t,n){this.__v_isShallow=n,this.dep=void 0,this.__v_isRef=!0,this._rawValue=n?t:X(t),this._value=n?t:on(t)}get value(){return Tr(this),this._value}set value(t){const n=this.__v_isShallow||On(t)||Mt(t);t=n?t:X(t),sn(t,this._rawValue)&&(this._rawValue=t,this._value=n?t:on(t),Mr(this))}}function de(e){return ae(e)?e.value:e}const wl={get:(e,t,n)=>de(Reflect.get(e,t,n)),set:(e,t,n,s)=>{const o=e[t];return ae(o)&&!ae(n)?(o.value=n,!0):Reflect.set(e,t,n,s)}};function $r(e){return it(e)?e:new Proxy(e,wl)}function xl(e){const t=V(e)?new Array(e.length):{};for(const n in e)t[n]=Pl(e,n);return t}class Rl{constructor(t,n,s){this._object=t,this._key=n,this._defaultValue=s,this.__v_isRef=!0}get value(){const t=this._object[this._key];return t===void 0?this._defaultValue:t}set value(t){this._object[this._key]=t}get dep(){return Qi(X(this._object),this._key)}}function Pl(e,t,n){const s=e[t];return ae(s)?s:new Rl(e,t,n)}class Ol{constructor(t,n,s,o){this._setter=n,this.dep=void 0,this.__v_isRef=!0,this.__v_isReadonly=!1,this._dirty=!0,this.effect=new Ns(t,()=>{this._dirty||(this._dirty=!0,Mr(this))}),this.effect.computed=this,this.effect.active=this._cacheable=!o,this.__v_isReadonly=s}get value(){const t=X(this);return Tr(t),(t._dirty||!t._cacheable)&&(t._dirty=!1,t._value=t.effect.run()),t._value}set value(t){this._setter(t)}}function Cl(e,t,n=!1){let s,o;const r=K(e);return r?(s=e,o=De):(s=e.get,o=e.set),new Ol(s,o,r||!o,n)}function lt(e,t,n,s){let o;try{o=s?e(...s):e()}catch(r){dn(r,t,n)}return o}function Fe(e,t,n,s){if(K(e)){const r=lt(e,t,n,s);return r&&ar(r)&&r.catch(i=>{dn(i,t,n)}),r}const o=[];for(let r=0;r>>1;ln(we[s])We&&we.splice(t,1)}function Al(e){V(e)?Tt.push(...e):(!Qe||!Qe.includes(e,e.allowRecurse?ht+1:ht))&&Tt.push(e),Fr()}function bo(e,t=rn?We+1:0){for(;tln(n)-ln(s)),ht=0;hte.id==null?1/0:e.id,Tl=(e,t)=>{const n=ln(e)-ln(t);if(n===0){if(e.pre&&!t.pre)return-1;if(t.pre&&!e.pre)return 1}return n};function Nr(e){vs=!1,rn=!0,we.sort(Tl);const t=De;try{for(We=0;Wehe(m)?m.trim():m)),p&&(o=n.map(ps))}let l,c=s[l=ss(t)]||s[l=ss(ze(t))];!c&&r&&(c=s[l=ss(wt(t))]),c&&Fe(c,e,6,o);const u=s[l+"Once"];if(u){if(!e.emitted)e.emitted={};else if(e.emitted[l])return;e.emitted[l]=!0,Fe(u,e,6,o)}}function Vr(e,t,n=!1){const s=t.emitsCache,o=s.get(e);if(o!==void 0)return o;const r=e.emits;let i={},l=!1;if(!K(e)){const c=u=>{const a=Vr(u,t,!0);a&&(l=!0,ve(i,a))};!n&&t.mixins.length&&t.mixins.forEach(c),e.extends&&c(e.extends),e.mixins&&e.mixins.forEach(c)}return!r&&!l?(ie(e)&&s.set(e,null),null):(V(r)?r.forEach(c=>i[c]=null):ve(i,r),ie(e)&&s.set(e,i),i)}function Kn(e,t){return!e||!$n(t)?!1:(t=t.slice(2).replace(/Once$/,""),Y(e,t[0].toLowerCase()+t.slice(1))||Y(e,wt(t))||Y(e,t))}let ye=null,Wn=null;function Cn(e){const t=ye;return ye=e,Wn=e&&e.type.__scopeId||null,t}function zn(e){Wn=e}function qn(){Wn=null}function zs(e,t=ye,n){if(!t||e._n)return e;const s=(...o)=>{s._d&&Ao(-1);const r=Cn(t);let i;try{i=e(...o)}finally{Cn(r),s._d&&Ao(1)}return i};return s._n=!0,s._c=!0,s._d=!0,s}function os(e){const{type:t,vnode:n,proxy:s,withProxy:o,props:r,propsOptions:[i],slots:l,attrs:c,emit:u,render:a,renderCache:p,data:h,setupState:m,ctx:b,inheritAttrs:O}=e;let T,k;const S=Cn(e);try{if(n.shapeFlag&4){const E=o||s;T=He(a.call(E,E,p,r,m,h,b)),k=c}else{const E=t;T=He(E.length>1?E(r,{attrs:c,slots:l,emit:u}):E(r,null)),k=t.props?c:Ll(c)}}catch(E){Zt.length=0,dn(E,e,1),T=Q(ut)}let R=T;if(k&&O!==!1){const E=Object.keys(k),{shapeFlag:U}=R;E.length&&U&7&&(i&&E.some(Ls)&&(k=$l(k,i)),R=Lt(R,k))}return n.dirs&&(R=Lt(R),R.dirs=R.dirs?R.dirs.concat(n.dirs):n.dirs),n.transition&&(R.transition=n.transition),T=R,Cn(S),T}const Ll=e=>{let t;for(const n in e)(n==="class"||n==="style"||$n(n))&&((t||(t={}))[n]=e[n]);return t},$l=(e,t)=>{const n={};for(const s in e)(!Ls(s)||!(s.slice(9)in t))&&(n[s]=e[s]);return n};function Dl(e,t,n){const{props:s,children:o,component:r}=e,{props:i,children:l,patchFlag:c}=t,u=r.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&c>=0){if(c&1024)return!0;if(c&16)return s?Eo(s,i,u):!!i;if(c&8){const a=t.dynamicProps;for(let p=0;pe.__isSuspense;function Nl(e,t){t&&t.pendingBranch?V(e)?t.effects.push(...e):t.effects.push(e):Al(e)}function In(e,t){return qs(e,null,t)}const yn={};function Qt(e,t,n){return qs(e,t,n)}function qs(e,t,{immediate:n,deep:s,flush:o,onTrack:r,onTrigger:i}=le){var l;const c=vr()===((l=ge)==null?void 0:l.scope)?ge:null;let u,a=!1,p=!1;if(ae(e)?(u=()=>e.value,a=On(e)):it(e)?(u=()=>e,s=!0):V(e)?(p=!0,a=e.some(E=>it(E)||On(E)),u=()=>e.map(E=>{if(ae(E))return E.value;if(it(E))return vt(E);if(K(E))return lt(E,c,2)})):K(e)?t?u=()=>lt(e,c,2):u=()=>{if(!(c&&c.isUnmounted))return h&&h(),Fe(e,c,3,[m])}:u=De,t&&s){const E=u;u=()=>vt(E())}let h,m=E=>{h=S.onStop=()=>{lt(E,c,4)}},b;if(Dt)if(m=De,t?n&&Fe(t,c,3,[u(),p?[]:void 0,m]):u(),o==="sync"){const E=Ac();b=E.__watcherHandles||(E.__watcherHandles=[])}else return De;let O=p?new Array(e.length).fill(yn):yn;const T=()=>{if(S.active)if(t){const E=S.run();(s||a||(p?E.some((U,D)=>sn(U,O[D])):sn(E,O)))&&(h&&h(),Fe(t,c,3,[E,O===yn?void 0:p&&O[0]===yn?[]:O,m]),O=E)}else S.run()};T.allowRecurse=!!t;let k;o==="sync"?k=T:o==="post"?k=()=>Pe(T,c&&c.suspense):(T.pre=!0,c&&(T.id=c.uid),k=()=>Hn(T));const S=new Ns(u,k);t?n?T():O=S.run():o==="post"?Pe(S.run.bind(S),c&&c.suspense):S.run();const R=()=>{S.stop(),c&&c.scope&&$s(c.scope.effects,S)};return b&&b.push(R),R}function Vl(e,t,n){const s=this.proxy,o=he(e)?e.includes(".")?Ur(s,e):()=>s[e]:e.bind(s,s);let r;K(t)?r=t:(r=t.handler,n=t);const i=ge;$t(this);const l=qs(o,r.bind(s),n);return i?$t(i):Et(),l}function Ur(e,t){const n=t.split(".");return()=>{let s=e;for(let o=0;o{vt(n,t)});else if(dr(e))for(const n in e)vt(e[n],t);return e}function Sn(e,t){const n=ye;if(n===null)return e;const s=Zn(n)||n.proxy,o=e.dirs||(e.dirs=[]);for(let r=0;rve({name:e.name},t,{setup:e}))():e}const Yt=e=>!!e.type.__asyncLoader;function Br(e){K(e)&&(e={loader:e});const{loader:t,loadingComponent:n,errorComponent:s,delay:o=200,timeout:r,suspensible:i=!0,onError:l}=e;let c=null,u,a=0;const p=()=>(a++,c=null,h()),h=()=>{let m;return c||(m=c=t().catch(b=>{if(b=b instanceof Error?b:new Error(String(b)),l)return new Promise((O,T)=>{l(b,()=>O(p()),()=>T(b),a+1)});throw b}).then(b=>m!==c&&c?c:(b&&(b.__esModule||b[Symbol.toStringTag]==="Module")&&(b=b.default),u=b,b)))};return Ce({name:"AsyncComponentWrapper",__asyncLoader:h,get __asyncResolved(){return u},setup(){const m=ge;if(u)return()=>rs(u,m);const b=S=>{c=null,dn(S,m,13,!s)};if(i&&m.suspense||Dt)return h().then(S=>()=>rs(S,m)).catch(S=>(b(S),()=>s?Q(s,{error:S}):null));const O=fe(!1),T=fe(),k=fe(!!o);return o&&setTimeout(()=>{k.value=!1},o),r!=null&&setTimeout(()=>{if(!O.value&&!T.value){const S=new Error(`Async component timed out after ${r}ms.`);b(S),T.value=S}},r),h().then(()=>{O.value=!0,m.parent&&Js(m.parent.vnode)&&Hn(m.parent.update)}).catch(S=>{b(S),T.value=S}),()=>{if(O.value&&u)return rs(u,m);if(T.value&&s)return Q(s,{error:T.value});if(n&&!k.value)return Q(n)}}})}function rs(e,t){const{ref:n,props:s,children:o,ce:r}=t.vnode,i=Q(e,s,o);return i.ref=n,i.ce=r,delete t.vnode.ce,i}const Js=e=>e.type.__isKeepAlive;function Ul(e,t){Hr(e,"a",t)}function Bl(e,t){Hr(e,"da",t)}function Hr(e,t,n=ge){const s=e.__wdc||(e.__wdc=()=>{let o=n;for(;o;){if(o.isDeactivated)return;o=o.parent}return e()});if(Jn(t,s,n),n){let o=n.parent;for(;o&&o.parent;)Js(o.parent.vnode)&&Hl(s,t,n,o),o=o.parent}}function Hl(e,t,n,s){const o=Jn(t,e,s,!0);Qs(()=>{$s(s[t],o)},n)}function Jn(e,t,n=ge,s=!1){if(n){const o=n[e]||(n[e]=[]),r=t.__weh||(t.__weh=(...i)=>{if(n.isUnmounted)return;Vt(),$t(n);const l=Fe(t,n,e,i);return Et(),Ut(),l});return s?o.unshift(r):o.push(r),r}}const Xe=e=>(t,n=ge)=>(!Dt||e==="sp")&&Jn(e,(...s)=>t(...s),n),Kl=Xe("bm"),Qn=Xe("m"),Wl=Xe("bu"),zl=Xe("u"),ql=Xe("bum"),Qs=Xe("um"),Jl=Xe("sp"),Ql=Xe("rtg"),Yl=Xe("rtc");function Xl(e,t=ge){Jn("ec",e,t)}const Kr="components",Wr=Symbol.for("v-ndc");function zr(e){return he(e)?Zl(Kr,e,!1)||e:e||Wr}function Zl(e,t,n=!0,s=!1){const o=ye||ge;if(o){const r=o.type;if(e===Kr){const l=Ic(r,!1);if(l&&(l===t||l===ze(t)||l===jn(ze(t))))return r}const i=wo(o[e]||r[e],t)||wo(o.appContext[e],t);return!i&&s?r:i}}function wo(e,t){return e&&(e[t]||e[ze(t)]||e[jn(ze(t))])}function qr(e,t,n,s){let o;const r=n&&n[s];if(V(e)||he(e)){o=new Array(e.length);for(let i=0,l=e.length;it(i,l,void 0,r&&r[l]));else{const i=Object.keys(e);o=new Array(i.length);for(let l=0,c=i.length;lAn(t)?!(t.type===ut||t.type===me&&!Jr(t.children)):!0)?e:null}const ys=e=>e?ii(e)?Zn(e)||e.proxy:ys(e.parent):null,Xt=ve(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=>ys(e.parent),$root:e=>ys(e.root),$emit:e=>e.emit,$options:e=>Xs(e),$forceUpdate:e=>e.f||(e.f=()=>Hn(e.update)),$nextTick:e=>e.n||(e.n=Bn.bind(e.proxy)),$watch:e=>Vl.bind(e)}),is=(e,t)=>e!==le&&!e.__isScriptSetup&&Y(e,t),Gl={get({_:e},t){const{ctx:n,setupState:s,data:o,props:r,accessCache:i,type:l,appContext:c}=e;let u;if(t[0]!=="$"){const m=i[t];if(m!==void 0)switch(m){case 1:return s[t];case 2:return o[t];case 4:return n[t];case 3:return r[t]}else{if(is(s,t))return i[t]=1,s[t];if(o!==le&&Y(o,t))return i[t]=2,o[t];if((u=e.propsOptions[0])&&Y(u,t))return i[t]=3,r[t];if(n!==le&&Y(n,t))return i[t]=4,n[t];bs&&(i[t]=0)}}const a=Xt[t];let p,h;if(a)return t==="$attrs"&&Oe(e,"get",t),a(e);if((p=l.__cssModules)&&(p=p[t]))return p;if(n!==le&&Y(n,t))return i[t]=4,n[t];if(h=c.config.globalProperties,Y(h,t))return h[t]},set({_:e},t,n){const{data:s,setupState:o,ctx:r}=e;return is(o,t)?(o[t]=n,!0):s!==le&&Y(s,t)?(s[t]=n,!0):Y(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(r[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:s,appContext:o,propsOptions:r}},i){let l;return!!n[i]||e!==le&&Y(e,i)||is(t,i)||(l=r[0])&&Y(l,i)||Y(s,i)||Y(Xt,i)||Y(o.config.globalProperties,i)},defineProperty(e,t,n){return n.get!=null?e._.accessCache[t]=0:Y(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}};function xo(e){return V(e)?e.reduce((t,n)=>(t[n]=null,t),{}):e}let bs=!0;function ec(e){const t=Xs(e),n=e.proxy,s=e.ctx;bs=!1,t.beforeCreate&&Ro(t.beforeCreate,e,"bc");const{data:o,computed:r,methods:i,watch:l,provide:c,inject:u,created:a,beforeMount:p,mounted:h,beforeUpdate:m,updated:b,activated:O,deactivated:T,beforeDestroy:k,beforeUnmount:S,destroyed:R,unmounted:E,render:U,renderTracked:D,renderTriggered:J,errorCaptured:W,serverPrefetch:z,expose:ce,inheritAttrs:be,components:Ie,directives:Ae,filters:at}=t;if(u&&tc(u,s,null),i)for(const oe in i){const G=i[oe];K(G)&&(s[oe]=G.bind(n))}if(o){const oe=o.call(n,n);ie(oe)&&(e.data=Bt(oe))}if(bs=!0,r)for(const oe in r){const G=r[oe],qe=K(G)?G.bind(n,n):K(G.get)?G.get.bind(n,n):De,Ge=!K(G)&&K(G.set)?G.set.bind(n):De,Ve=_e({get:qe,set:Ge});Object.defineProperty(s,oe,{enumerable:!0,configurable:!0,get:()=>Ve.value,set:Re=>Ve.value=Re})}if(l)for(const oe in l)Qr(l[oe],s,n,oe);if(c){const oe=K(c)?c.call(n):c;Reflect.ownKeys(oe).forEach(G=>{wn(G,oe[G])})}a&&Ro(a,e,"c");function Z(oe,G){V(G)?G.forEach(qe=>oe(qe.bind(n))):G&&oe(G.bind(n))}if(Z(Kl,p),Z(Qn,h),Z(Wl,m),Z(zl,b),Z(Ul,O),Z(Bl,T),Z(Xl,W),Z(Yl,D),Z(Ql,J),Z(ql,S),Z(Qs,E),Z(Jl,z),V(ce))if(ce.length){const oe=e.exposed||(e.exposed={});ce.forEach(G=>{Object.defineProperty(oe,G,{get:()=>n[G],set:qe=>n[G]=qe})})}else e.exposed||(e.exposed={});U&&e.render===De&&(e.render=U),be!=null&&(e.inheritAttrs=be),Ie&&(e.components=Ie),Ae&&(e.directives=Ae)}function tc(e,t,n=De){V(e)&&(e=Es(e));for(const s in e){const o=e[s];let r;ie(o)?"default"in o?r=je(o.from||s,o.default,!0):r=je(o.from||s):r=je(o),ae(r)?Object.defineProperty(t,s,{enumerable:!0,configurable:!0,get:()=>r.value,set:i=>r.value=i}):t[s]=r}}function Ro(e,t,n){Fe(V(e)?e.map(s=>s.bind(t.proxy)):e.bind(t.proxy),t,n)}function Qr(e,t,n,s){const o=s.includes(".")?Ur(n,s):()=>n[s];if(he(e)){const r=t[e];K(r)&&Qt(o,r)}else if(K(e))Qt(o,e.bind(n));else if(ie(e))if(V(e))e.forEach(r=>Qr(r,t,n,s));else{const r=K(e.handler)?e.handler.bind(n):t[e.handler];K(r)&&Qt(o,r,e)}}function Xs(e){const t=e.type,{mixins:n,extends:s}=t,{mixins:o,optionsCache:r,config:{optionMergeStrategies:i}}=e.appContext,l=r.get(t);let c;return l?c=l:!o.length&&!n&&!s?c=t:(c={},o.length&&o.forEach(u=>kn(c,u,i,!0)),kn(c,t,i)),ie(t)&&r.set(t,c),c}function kn(e,t,n,s=!1){const{mixins:o,extends:r}=t;r&&kn(e,r,n,!0),o&&o.forEach(i=>kn(e,i,n,!0));for(const i in t)if(!(s&&i==="expose")){const l=nc[i]||n&&n[i];e[i]=l?l(e[i],t[i]):t[i]}return e}const nc={data:Po,props:Oo,emits:Oo,methods:Jt,computed:Jt,beforeCreate:xe,created:xe,beforeMount:xe,mounted:xe,beforeUpdate:xe,updated:xe,beforeDestroy:xe,beforeUnmount:xe,destroyed:xe,unmounted:xe,activated:xe,deactivated:xe,errorCaptured:xe,serverPrefetch:xe,components:Jt,directives:Jt,watch:oc,provide:Po,inject:sc};function Po(e,t){return t?e?function(){return ve(K(e)?e.call(this,this):e,K(t)?t.call(this,this):t)}:t:e}function sc(e,t){return Jt(Es(e),Es(t))}function Es(e){if(V(e)){const t={};for(let n=0;n1)return n&&K(t)?t.call(s&&s.proxy):t}}function lc(){return!!(ge||ye||cn)}function cc(e,t,n,s=!1){const o={},r={};Rn(r,Xn,1),e.propsDefaults=Object.create(null),Xr(e,t,o,r);for(const i in e.propsOptions[0])i in o||(o[i]=void 0);n?e.props=s?o:Sr(o):e.type.props?e.props=o:e.props=r,e.attrs=r}function uc(e,t,n,s){const{props:o,attrs:r,vnode:{patchFlag:i}}=e,l=X(o),[c]=e.propsOptions;let u=!1;if((s||i>0)&&!(i&16)){if(i&8){const a=e.vnode.dynamicProps;for(let p=0;p{c=!0;const[h,m]=Zr(p,t,!0);ve(i,h),m&&l.push(...m)};!n&&t.mixins.length&&t.mixins.forEach(a),e.extends&&a(e.extends),e.mixins&&e.mixins.forEach(a)}if(!r&&!c)return ie(e)&&s.set(e,kt),kt;if(V(r))for(let a=0;a-1,m[1]=O<0||b-1||Y(m,"default"))&&l.push(p)}}}const u=[i,l];return ie(e)&&s.set(e,u),u}function Co(e){return e[0]!=="$"}function Io(e){const t=e&&e.toString().match(/^\s*(function|class) (\w+)/);return t?t[2]:e===null?"null":""}function So(e,t){return Io(e)===Io(t)}function ko(e,t){return V(t)?t.findIndex(n=>So(n,e)):K(t)&&So(t,e)?0:-1}const Gr=e=>e[0]==="_"||e==="$stable",Zs=e=>V(e)?e.map(He):[He(e)],ac=(e,t,n)=>{if(t._n)return t;const s=zs((...o)=>Zs(t(...o)),n);return s._c=!1,s},ei=(e,t,n)=>{const s=e._ctx;for(const o in e){if(Gr(o))continue;const r=e[o];if(K(r))t[o]=ac(o,r,s);else if(r!=null){const i=Zs(r);t[o]=()=>i}}},ti=(e,t)=>{const n=Zs(t);e.slots.default=()=>n},fc=(e,t)=>{if(e.vnode.shapeFlag&32){const n=t._;n?(e.slots=X(t),Rn(t,"_",n)):ei(t,e.slots={})}else e.slots={},t&&ti(e,t);Rn(e.slots,Xn,1)},dc=(e,t,n)=>{const{vnode:s,slots:o}=e;let r=!0,i=le;if(s.shapeFlag&32){const l=t._;l?n&&l===1?r=!1:(ve(o,t),!n&&l===1&&delete o._):(r=!t.$stable,ei(t,o)),i=t}else t&&(ti(e,t),i={default:1});if(r)for(const l in o)!Gr(l)&&!(l in i)&&delete o[l]};function xs(e,t,n,s,o=!1){if(V(e)){e.forEach((h,m)=>xs(h,t&&(V(t)?t[m]:t),n,s,o));return}if(Yt(s)&&!o)return;const r=s.shapeFlag&4?Zn(s.component)||s.component.proxy:s.el,i=o?null:r,{i:l,r:c}=e,u=t&&t.r,a=l.refs===le?l.refs={}:l.refs,p=l.setupState;if(u!=null&&u!==c&&(he(u)?(a[u]=null,Y(p,u)&&(p[u]=null)):ae(u)&&(u.value=null)),K(c))lt(c,l,12,[i,a]);else{const h=he(c),m=ae(c);if(h||m){const b=()=>{if(e.f){const O=h?Y(p,c)?p[c]:a[c]:c.value;o?V(O)&&$s(O,r):V(O)?O.includes(r)||O.push(r):h?(a[c]=[r],Y(p,c)&&(p[c]=a[c])):(c.value=[r],e.k&&(a[e.k]=c.value))}else h?(a[c]=i,Y(p,c)&&(p[c]=i)):m&&(c.value=i,e.k&&(a[e.k]=i))};i?(b.id=-1,Pe(b,n)):b()}}}const Pe=Nl;function pc(e){return hc(e)}function hc(e,t){const n=hs();n.__VUE__=!0;const{insert:s,remove:o,patchProp:r,createElement:i,createText:l,createComment:c,setText:u,setElementText:a,parentNode:p,nextSibling:h,setScopeId:m=De,insertStaticContent:b}=e,O=(f,d,g,_=null,y=null,w=null,A=!1,P=null,C=!!d.dynamicChildren)=>{if(f===d)return;f&&!Wt(f,d)&&(_=v(f),Re(f,y,w,!0),f=null),d.patchFlag===-2&&(C=!1,d.dynamicChildren=null);const{type:x,ref:j,shapeFlag:L}=d;switch(x){case Yn:T(f,d,g,_);break;case ut:k(f,d,g,_);break;case ls:f==null&&S(d,g,_,A);break;case me:Ie(f,d,g,_,y,w,A,P,C);break;default:L&1?U(f,d,g,_,y,w,A,P,C):L&6?Ae(f,d,g,_,y,w,A,P,C):(L&64||L&128)&&x.process(f,d,g,_,y,w,A,P,C,I)}j!=null&&y&&xs(j,f&&f.ref,w,d||f,!d)},T=(f,d,g,_)=>{if(f==null)s(d.el=l(d.children),g,_);else{const y=d.el=f.el;d.children!==f.children&&u(y,d.children)}},k=(f,d,g,_)=>{f==null?s(d.el=c(d.children||""),g,_):d.el=f.el},S=(f,d,g,_)=>{[f.el,f.anchor]=b(f.children,d,g,_,f.el,f.anchor)},R=({el:f,anchor:d},g,_)=>{let y;for(;f&&f!==d;)y=h(f),s(f,g,_),f=y;s(d,g,_)},E=({el:f,anchor:d})=>{let g;for(;f&&f!==d;)g=h(f),o(f),f=g;o(d)},U=(f,d,g,_,y,w,A,P,C)=>{A=A||d.type==="svg",f==null?D(d,g,_,y,w,A,P,C):z(f,d,y,w,A,P,C)},D=(f,d,g,_,y,w,A,P)=>{let C,x;const{type:j,props:L,shapeFlag:N,transition:H,dirs:q}=f;if(C=f.el=i(f.type,w,L&&L.is,L),N&8?a(C,f.children):N&16&&W(f.children,C,null,_,y,w&&j!=="foreignObject",A,P),q&&ft(f,null,_,"created"),J(C,f,f.scopeId,A,_),L){for(const ne in L)ne!=="value"&&!bn(ne)&&r(C,ne,null,L[ne],w,f.children,_,y,Ee);"value"in L&&r(C,"value",null,L.value),(x=L.onVnodeBeforeMount)&&Be(x,_,f)}q&&ft(f,null,_,"beforeMount");const re=(!y||y&&!y.pendingBranch)&&H&&!H.persisted;re&&H.beforeEnter(C),s(C,d,g),((x=L&&L.onVnodeMounted)||re||q)&&Pe(()=>{x&&Be(x,_,f),re&&H.enter(C),q&&ft(f,null,_,"mounted")},y)},J=(f,d,g,_,y)=>{if(g&&m(f,g),_)for(let w=0;w<_.length;w++)m(f,_[w]);if(y){let w=y.subTree;if(d===w){const A=y.vnode;J(f,A,A.scopeId,A.slotScopeIds,y.parent)}}},W=(f,d,g,_,y,w,A,P,C=0)=>{for(let x=C;x{const P=d.el=f.el;let{patchFlag:C,dynamicChildren:x,dirs:j}=d;C|=f.patchFlag&16;const L=f.props||le,N=d.props||le;let H;g&&dt(g,!1),(H=N.onVnodeBeforeUpdate)&&Be(H,g,d,f),j&&ft(d,f,g,"beforeUpdate"),g&&dt(g,!0);const q=y&&d.type!=="foreignObject";if(x?ce(f.dynamicChildren,x,P,g,_,q,w):A||G(f,d,P,null,g,_,q,w,!1),C>0){if(C&16)be(P,d,L,N,g,_,y);else if(C&2&&L.class!==N.class&&r(P,"class",null,N.class,y),C&4&&r(P,"style",L.style,N.style,y),C&8){const re=d.dynamicProps;for(let ne=0;ne{H&&Be(H,g,d,f),j&&ft(d,f,g,"updated")},_)},ce=(f,d,g,_,y,w,A)=>{for(let P=0;P{if(g!==_){if(g!==le)for(const P in g)!bn(P)&&!(P in _)&&r(f,P,g[P],null,A,d.children,y,w,Ee);for(const P in _){if(bn(P))continue;const C=_[P],x=g[P];C!==x&&P!=="value"&&r(f,P,x,C,A,d.children,y,w,Ee)}"value"in _&&r(f,"value",g.value,_.value)}},Ie=(f,d,g,_,y,w,A,P,C)=>{const x=d.el=f?f.el:l(""),j=d.anchor=f?f.anchor:l("");let{patchFlag:L,dynamicChildren:N,slotScopeIds:H}=d;H&&(P=P?P.concat(H):H),f==null?(s(x,g,_),s(j,g,_),W(d.children,g,j,y,w,A,P,C)):L>0&&L&64&&N&&f.dynamicChildren?(ce(f.dynamicChildren,N,g,y,w,A,P),(d.key!=null||y&&d===y.subTree)&&ni(f,d,!0)):G(f,d,g,j,y,w,A,P,C)},Ae=(f,d,g,_,y,w,A,P,C)=>{d.slotScopeIds=P,f==null?d.shapeFlag&512?y.ctx.activate(d,g,_,A,C):at(d,g,_,y,w,A,C):Te(f,d,C)},at=(f,d,g,_,y,w,A)=>{const P=f.component=xc(f,_,y);if(Js(f)&&(P.ctx.renderer=I),Rc(P),P.asyncDep){if(y&&y.registerDep(P,Z),!f.el){const C=P.subTree=Q(ut);k(null,C,d,g)}return}Z(P,f,d,g,y,w,A)},Te=(f,d,g)=>{const _=d.component=f.component;if(Dl(f,d,g))if(_.asyncDep&&!_.asyncResolved){oe(_,d,g);return}else _.next=d,kl(_.update),_.update();else d.el=f.el,_.vnode=d},Z=(f,d,g,_,y,w,A)=>{const P=()=>{if(f.isMounted){let{next:j,bu:L,u:N,parent:H,vnode:q}=f,re=j,ne;dt(f,!1),j?(j.el=q.el,oe(f,j,A)):j=q,L&&En(L),(ne=j.props&&j.props.onVnodeBeforeUpdate)&&Be(ne,H,j,q),dt(f,!0);const pe=os(f),Me=f.subTree;f.subTree=pe,O(Me,pe,p(Me.el),v(Me),f,y,w),j.el=pe.el,re===null&&Fl(f,pe.el),N&&Pe(N,y),(ne=j.props&&j.props.onVnodeUpdated)&&Pe(()=>Be(ne,H,j,q),y)}else{let j;const{el:L,props:N}=d,{bm:H,m:q,parent:re}=f,ne=Yt(d);if(dt(f,!1),H&&En(H),!ne&&(j=N&&N.onVnodeBeforeMount)&&Be(j,re,d),dt(f,!0),L&&ee){const pe=()=>{f.subTree=os(f),ee(L,f.subTree,f,y,null)};ne?d.type.__asyncLoader().then(()=>!f.isUnmounted&&pe()):pe()}else{const pe=f.subTree=os(f);O(null,pe,g,_,f,y,w),d.el=pe.el}if(q&&Pe(q,y),!ne&&(j=N&&N.onVnodeMounted)){const pe=d;Pe(()=>Be(j,re,pe),y)}(d.shapeFlag&256||re&&Yt(re.vnode)&&re.vnode.shapeFlag&256)&&f.a&&Pe(f.a,y),f.isMounted=!0,d=g=_=null}},C=f.effect=new Ns(P,()=>Hn(x),f.scope),x=f.update=()=>C.run();x.id=f.uid,dt(f,!0),x()},oe=(f,d,g)=>{d.component=f;const _=f.vnode.props;f.vnode=d,f.next=null,uc(f,d.props,_,g),dc(f,d.children,g),Vt(),bo(),Ut()},G=(f,d,g,_,y,w,A,P,C=!1)=>{const x=f&&f.children,j=f?f.shapeFlag:0,L=d.children,{patchFlag:N,shapeFlag:H}=d;if(N>0){if(N&128){Ge(x,L,g,_,y,w,A,P,C);return}else if(N&256){qe(x,L,g,_,y,w,A,P,C);return}}H&8?(j&16&&Ee(x,y,w),L!==x&&a(g,L)):j&16?H&16?Ge(x,L,g,_,y,w,A,P,C):Ee(x,y,w,!0):(j&8&&a(g,""),H&16&&W(L,g,_,y,w,A,P,C))},qe=(f,d,g,_,y,w,A,P,C)=>{f=f||kt,d=d||kt;const x=f.length,j=d.length,L=Math.min(x,j);let N;for(N=0;Nj?Ee(f,y,w,!0,!1,L):W(d,g,_,y,w,A,P,C,L)},Ge=(f,d,g,_,y,w,A,P,C)=>{let x=0;const j=d.length;let L=f.length-1,N=j-1;for(;x<=L&&x<=N;){const H=f[x],q=d[x]=C?st(d[x]):He(d[x]);if(Wt(H,q))O(H,q,g,null,y,w,A,P,C);else break;x++}for(;x<=L&&x<=N;){const H=f[L],q=d[N]=C?st(d[N]):He(d[N]);if(Wt(H,q))O(H,q,g,null,y,w,A,P,C);else break;L--,N--}if(x>L){if(x<=N){const H=N+1,q=HN)for(;x<=L;)Re(f[x],y,w,!0),x++;else{const H=x,q=x,re=new Map;for(x=q;x<=N;x++){const Se=d[x]=C?st(d[x]):He(d[x]);Se.key!=null&&re.set(Se.key,x)}let ne,pe=0;const Me=N-q+1;let Ot=!1,io=0;const Kt=new Array(Me);for(x=0;x=Me){Re(Se,y,w,!0);continue}let Ue;if(Se.key!=null)Ue=re.get(Se.key);else for(ne=q;ne<=N;ne++)if(Kt[ne-q]===0&&Wt(Se,d[ne])){Ue=ne;break}Ue===void 0?Re(Se,y,w,!0):(Kt[Ue-q]=x+1,Ue>=io?io=Ue:Ot=!0,O(Se,d[Ue],g,null,y,w,A,P,C),pe++)}const lo=Ot?gc(Kt):kt;for(ne=lo.length-1,x=Me-1;x>=0;x--){const Se=q+x,Ue=d[Se],co=Se+1{const{el:w,type:A,transition:P,children:C,shapeFlag:x}=f;if(x&6){Ve(f.component.subTree,d,g,_);return}if(x&128){f.suspense.move(d,g,_);return}if(x&64){A.move(f,d,g,I);return}if(A===me){s(w,d,g);for(let L=0;LP.enter(w),y);else{const{leave:L,delayLeave:N,afterLeave:H}=P,q=()=>s(w,d,g),re=()=>{L(w,()=>{q(),H&&H()})};N?N(w,q,re):re()}else s(w,d,g)},Re=(f,d,g,_=!1,y=!1)=>{const{type:w,props:A,ref:P,children:C,dynamicChildren:x,shapeFlag:j,patchFlag:L,dirs:N}=f;if(P!=null&&xs(P,null,g,f,!0),j&256){d.ctx.deactivate(f);return}const H=j&1&&N,q=!Yt(f);let re;if(q&&(re=A&&A.onVnodeBeforeUnmount)&&Be(re,d,f),j&6)pn(f.component,g,_);else{if(j&128){f.suspense.unmount(g,_);return}H&&ft(f,null,d,"beforeUnmount"),j&64?f.type.remove(f,d,g,y,I,_):x&&(w!==me||L>0&&L&64)?Ee(x,d,g,!1,!0):(w===me&&L&384||!y&&j&16)&&Ee(C,d,g),_&&Rt(f)}(q&&(re=A&&A.onVnodeUnmounted)||H)&&Pe(()=>{re&&Be(re,d,f),H&&ft(f,null,d,"unmounted")},g)},Rt=f=>{const{type:d,el:g,anchor:_,transition:y}=f;if(d===me){Pt(g,_);return}if(d===ls){E(f);return}const w=()=>{o(g),y&&!y.persisted&&y.afterLeave&&y.afterLeave()};if(f.shapeFlag&1&&y&&!y.persisted){const{leave:A,delayLeave:P}=y,C=()=>A(g,w);P?P(f.el,w,C):C()}else w()},Pt=(f,d)=>{let g;for(;f!==d;)g=h(f),o(f),f=g;o(d)},pn=(f,d,g)=>{const{bum:_,scope:y,update:w,subTree:A,um:P}=f;_&&En(_),y.stop(),w&&(w.active=!1,Re(A,f,d,g)),P&&Pe(P,d),Pe(()=>{f.isUnmounted=!0},d),d&&d.pendingBranch&&!d.isUnmounted&&f.asyncDep&&!f.asyncResolved&&f.suspenseId===d.pendingId&&(d.deps--,d.deps===0&&d.resolve())},Ee=(f,d,g,_=!1,y=!1,w=0)=>{for(let A=w;Af.shapeFlag&6?v(f.component.subTree):f.shapeFlag&128?f.suspense.next():h(f.anchor||f.el),M=(f,d,g)=>{f==null?d._vnode&&Re(d._vnode,null,null,!0):O(d._vnode||null,f,d,null,null,null,g),bo(),jr(),d._vnode=f},I={p:O,um:Re,m:Ve,r:Rt,mt:at,mc:W,pc:G,pbc:ce,n:v,o:e};let F,ee;return t&&([F,ee]=t(I)),{render:M,hydrate:F,createApp:ic(M,F)}}function dt({effect:e,update:t},n){e.allowRecurse=t.allowRecurse=n}function ni(e,t,n=!1){const s=e.children,o=t.children;if(V(s)&&V(o))for(let r=0;r>1,e[n[l]]0&&(t[s]=n[r-1]),n[r]=s)}}for(r=n.length,i=n[r-1];r-- >0;)n[r]=i,i=t[i];return n}const mc=e=>e.__isTeleport,me=Symbol.for("v-fgt"),Yn=Symbol.for("v-txt"),ut=Symbol.for("v-cmt"),ls=Symbol.for("v-stc"),Zt=[];let $e=null;function se(e=!1){Zt.push($e=e?null:[])}function _c(){Zt.pop(),$e=Zt[Zt.length-1]||null}let un=1;function Ao(e){un+=e}function si(e){return e.dynamicChildren=un>0?$e||kt:null,_c(),un>0&&$e&&$e.push(e),e}function ue(e,t,n,s,o,r){return si(B(e,t,n,s,o,r,!0))}function xt(e,t,n,s,o){return si(Q(e,t,n,s,o,!0))}function An(e){return e?e.__v_isVNode===!0:!1}function Wt(e,t){return e.type===t.type&&e.key===t.key}const Xn="__vInternal",oi=({key:e})=>e??null,xn=({ref:e,ref_key:t,ref_for:n})=>(typeof e=="number"&&(e=""+e),e!=null?he(e)||ae(e)||K(e)?{i:ye,r:e,k:t,f:!!n}:e:null);function B(e,t=null,n=null,s=0,o=null,r=e===me?0:1,i=!1,l=!1){const c={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&oi(t),ref:t&&xn(t),scopeId:Wn,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetAnchor:null,staticCount:0,shapeFlag:r,patchFlag:s,dynamicProps:o,dynamicChildren:null,appContext:null,ctx:ye};return l?(Gs(c,n),r&128&&e.normalize(c)):n&&(c.shapeFlag|=he(n)?8:16),un>0&&!i&&$e&&(c.patchFlag>0||r&6)&&c.patchFlag!==32&&$e.push(c),c}const Q=vc;function vc(e,t=null,n=null,s=0,o=null,r=!1){if((!e||e===Wr)&&(e=ut),An(e)){const l=Lt(e,t,!0);return n&&Gs(l,n),un>0&&!r&&$e&&(l.shapeFlag&6?$e[$e.indexOf(e)]=l:$e.push(l)),l.patchFlag|=-2,l}if(Sc(e)&&(e=e.__vccOpts),t){t=yc(t);let{class:l,style:c}=t;l&&!he(l)&&(t.class=_t(l)),ie(c)&&(Ar(c)&&!V(c)&&(c=ve({},c)),t.style=Fs(c))}const i=he(e)?1:jl(e)?128:mc(e)?64:ie(e)?4:K(e)?2:0;return B(e,t,n,s,o,i,r,!0)}function yc(e){return e?Ar(e)||Xn in e?ve({},e):e:null}function Lt(e,t,n=!1){const{props:s,ref:o,patchFlag:r,children:i}=e,l=t?bc(s||{},t):s;return{__v_isVNode:!0,__v_skip:!0,type:e.type,props:l,key:l&&oi(l),ref:t&&t.ref?n&&o?V(o)?o.concat(xn(t)):[o,xn(t)]:xn(t):o,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:i,target:e.target,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==me?r===-1?16:r|16:r,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:e.transition,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&Lt(e.ssContent),ssFallback:e.ssFallback&&Lt(e.ssFallback),el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce}}function ri(e=" ",t=0){return Q(Yn,null,e,t)}function bt(e="",t=!1){return t?(se(),xt(ut,null,e)):Q(ut,null,e)}function He(e){return e==null||typeof e=="boolean"?Q(ut):V(e)?Q(me,null,e.slice()):typeof e=="object"?st(e):Q(Yn,null,String(e))}function st(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:Lt(e)}function Gs(e,t){let n=0;const{shapeFlag:s}=e;if(t==null)t=null;else if(V(t))n=16;else if(typeof t=="object")if(s&65){const o=t.default;o&&(o._c&&(o._d=!1),Gs(e,o()),o._c&&(o._d=!0));return}else{n=32;const o=t._;!o&&!(Xn in t)?t._ctx=ye:o===3&&ye&&(ye.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else K(t)?(t={default:t,_ctx:ye},n=32):(t=String(t),s&64?(n=16,t=[ri(t)]):n=8);e.children=t,e.shapeFlag|=n}function bc(...e){const t={};for(let n=0;nge=e),eo=e=>{Ct.length>1?Ct.forEach(t=>t(e)):Ct[0](e)};const $t=e=>{eo(e),e.scope.on()},Et=()=>{ge&&ge.scope.off(),eo(null)};function ii(e){return e.vnode.shapeFlag&4}let Dt=!1;function Rc(e,t=!1){Dt=t;const{props:n,children:s}=e.vnode,o=ii(e);cc(e,n,o,t),fc(e,s);const r=o?Pc(e,t):void 0;return Dt=!1,r}function Pc(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=Un(new Proxy(e.ctx,Gl));const{setup:s}=n;if(s){const o=e.setupContext=s.length>1?Cc(e):null;$t(e),Vt();const r=lt(s,e,0,[e.props,o]);if(Ut(),Et(),ar(r)){if(r.then(Et,Et),t)return r.then(i=>{Mo(e,i,t)}).catch(i=>{dn(i,e,0)});e.asyncDep=r}else Mo(e,r,t)}else li(e,t)}function Mo(e,t,n){K(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:ie(t)&&(e.setupState=$r(t)),li(e,n)}let Lo;function li(e,t,n){const s=e.type;if(!e.render){if(!t&&Lo&&!s.render){const o=s.template||Xs(e).template;if(o){const{isCustomElement:r,compilerOptions:i}=e.appContext.config,{delimiters:l,compilerOptions:c}=s,u=ve(ve({isCustomElement:r,delimiters:l},i),c);s.render=Lo(o,u)}}e.render=s.render||De}$t(e),Vt(),ec(e),Ut(),Et()}function Oc(e){return e.attrsProxy||(e.attrsProxy=new Proxy(e.attrs,{get(t,n){return Oe(e,"get","$attrs"),t[n]}}))}function Cc(e){const t=n=>{e.exposed=n||{}};return{get attrs(){return Oc(e)},slots:e.slots,emit:e.emit,expose:t}}function Zn(e){if(e.exposed)return e.exposeProxy||(e.exposeProxy=new Proxy($r(Un(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in Xt)return Xt[n](e)},has(t,n){return n in t||n in Xt}}))}function Ic(e,t=!0){return K(e)?e.displayName||e.name:e.name||t&&e.__name}function Sc(e){return K(e)&&"__vccOpts"in e}const _e=(e,t)=>Cl(e,t,Dt);function ci(e,t,n){const s=arguments.length;return s===2?ie(t)&&!V(t)?An(t)?Q(e,null,[t]):Q(e,t):Q(e,null,t):(s>3?n=Array.prototype.slice.call(arguments,2):s===3&&An(n)&&(n=[n]),Q(e,t,n))}const kc=Symbol.for("v-scx"),Ac=()=>je(kc),Tc="3.3.4",Mc="http://www.w3.org/2000/svg",gt=typeof document<"u"?document:null,$o=gt&>.createElement("template"),Lc={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,s)=>{const o=t?gt.createElementNS(Mc,e):gt.createElement(e,n?{is:n}:void 0);return e==="select"&&s&&s.multiple!=null&&o.setAttribute("multiple",s.multiple),o},createText:e=>gt.createTextNode(e),createComment:e=>gt.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>gt.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,n,s,o,r){const i=n?n.previousSibling:t.lastChild;if(o&&(o===r||o.nextSibling))for(;t.insertBefore(o.cloneNode(!0),n),!(o===r||!(o=o.nextSibling)););else{$o.innerHTML=s?`${e}`:e;const l=$o.content;if(s){const c=l.firstChild;for(;c.firstChild;)l.appendChild(c.firstChild);l.removeChild(c)}t.insertBefore(l,n)}return[i?i.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}};function $c(e,t,n){const s=e._vtc;s&&(t=(t?[t,...s]:[...s]).join(" ")),t==null?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}function Dc(e,t,n){const s=e.style,o=he(n);if(n&&!o){if(t&&!he(t))for(const r in t)n[r]==null&&Rs(s,r,"");for(const r in n)Rs(s,r,n[r])}else{const r=s.display;o?t!==n&&(s.cssText=n):t&&e.removeAttribute("style"),"_vod"in e&&(s.display=r)}}const Do=/\s*!important$/;function Rs(e,t,n){if(V(n))n.forEach(s=>Rs(e,t,s));else if(n==null&&(n=""),t.startsWith("--"))e.setProperty(t,n);else{const s=Fc(e,t);Do.test(n)?e.setProperty(wt(s),n.replace(Do,""),"important"):e[s]=n}}const Fo=["Webkit","Moz","ms"],cs={};function Fc(e,t){const n=cs[t];if(n)return n;let s=ze(t);if(s!=="filter"&&s in e)return cs[t]=s;s=jn(s);for(let o=0;ous||(Hc.then(()=>us=0),us=Date.now());function Wc(e,t){const n=s=>{if(!s._vts)s._vts=Date.now();else if(s._vts<=n.attached)return;Fe(zc(s,n.value),t,5,[s])};return n.value=e,n.attached=Kc(),n}function zc(e,t){if(V(t)){const n=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0},t.map(s=>o=>!o._stopped&&s&&s(o))}else return t}const Vo=/^on[a-z]/,qc=(e,t,n,s,o=!1,r,i,l,c)=>{t==="class"?$c(e,s,o):t==="style"?Dc(e,n,s):$n(t)?Ls(t)||Uc(e,t,n,s,i):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):Jc(e,t,s,o))?Nc(e,t,s,r,i,l,c):(t==="true-value"?e._trueValue=s:t==="false-value"&&(e._falseValue=s),jc(e,t,s,o))};function Jc(e,t,n,s){return s?!!(t==="innerHTML"||t==="textContent"||t in e&&Vo.test(t)&&K(n)):t==="spellcheck"||t==="draggable"||t==="translate"||t==="form"||t==="list"&&e.tagName==="INPUT"||t==="type"&&e.tagName==="TEXTAREA"||Vo.test(t)&&he(n)?!1:t in e}const Tn=e=>{const t=e.props["onUpdate:modelValue"]||!1;return V(t)?n=>En(t,n):t};function Qc(e){e.target.composing=!0}function Uo(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const Ps={created(e,{modifiers:{lazy:t,trim:n,number:s}},o){e._assign=Tn(o);const r=s||o.props&&o.props.type==="number";mt(e,t?"change":"input",i=>{if(i.target.composing)return;let l=e.value;n&&(l=l.trim()),r&&(l=ps(l)),e._assign(l)}),n&&mt(e,"change",()=>{e.value=e.value.trim()}),t||(mt(e,"compositionstart",Qc),mt(e,"compositionend",Uo),mt(e,"change",Uo))},mounted(e,{value:t}){e.value=t??""},beforeUpdate(e,{value:t,modifiers:{lazy:n,trim:s,number:o}},r){if(e._assign=Tn(r),e.composing||document.activeElement===e&&e.type!=="range"&&(n||s&&e.value.trim()===t||(o||e.type==="number")&&ps(e.value)===t))return;const i=t??"";e.value!==i&&(e.value=i)}},Yc={deep:!0,created(e,t,n){e._assign=Tn(n),mt(e,"change",()=>{const s=e._modelValue,o=Xc(e),r=e.checked,i=e._assign;if(V(s)){const l=hr(s,o),c=l!==-1;if(r&&!c)i(s.concat(o));else if(!r&&c){const u=[...s];u.splice(l,1),i(u)}}else if(Dn(s)){const l=new Set(s);r?l.add(o):l.delete(o),i(l)}else i(ui(e,r))})},mounted:Bo,beforeUpdate(e,t,n){e._assign=Tn(n),Bo(e,t,n)}};function Bo(e,{value:t,oldValue:n},s){e._modelValue=t,V(t)?e.checked=hr(t,s.props.value)>-1:Dn(t)?e.checked=t.has(s.props.value):t!==n&&(e.checked=Nn(t,ui(e,!0)))}function Xc(e){return"_value"in e?e._value:e.value}function ui(e,t){const n=t?"_trueValue":"_falseValue";return n in e?e[n]:t}const Zc=["ctrl","shift","alt","meta"],Gc={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)=>Zc.some(n=>e[`${n}Key`]&&!t.includes(n))},pt=(e,t)=>(n,...s)=>{for(let o=0;on=>{if(!("key"in n))return;const s=wt(n.key);if(t.some(o=>o===s||eu[o]===s))return e(n)},tu=ve({patchProp:qc},Lc);let Ho;function nu(){return Ho||(Ho=pc(tu))}const su=(...e)=>{const t=nu().createApp(...e),{mount:n}=t;return t.mount=s=>{const o=ou(s);if(!o)return;const r=t._component;!K(r)&&!r.render&&!r.template&&(r.template=o.innerHTML),o.innerHTML="";const i=n(o,!1,o instanceof SVGElement);return o instanceof Element&&(o.removeAttribute("v-cloak"),o.setAttribute("data-v-app","")),i},t};function ou(e){return he(e)?document.querySelector(e):e}var ru=!1;/*! * pinia v2.1.6 * (c) 2023 Eduardo San Martin Morote * @license MIT */let ai;const Gn=e=>ai=e,fi=Symbol();function Cs(e){return e&&typeof e=="object"&&Object.prototype.toString.call(e)==="[object Object]"&&typeof e.toJSON!="function"}var Gt;(function(e){e.direct="direct",e.patchObject="patch object",e.patchFunction="patch function"})(Gt||(Gt={}));function iu(){const e=_r(!0),t=e.run(()=>fe({}));let n=[],s=[];const o=Un({install(r){Gn(o),o._a=r,r.provide(fi,o),r.config.globalProperties.$pinia=o,s.forEach(i=>n.push(i)),s=[]},use(r){return!this._a&&!ru?s.push(r):n.push(r),this},_p:n,_a:null,_e:e,_s:new Map,state:t});return o}const di=()=>{};function Ko(e,t,n,s=di){e.push(t);const o=()=>{const r=e.indexOf(t);r>-1&&(e.splice(r,1),s())};return!n&&vr()&&zi(o),o}function It(e,...t){e.slice().forEach(n=>{n(...t)})}const lu=e=>e();function Is(e,t){e instanceof Map&&t instanceof Map&&t.forEach((n,s)=>e.set(s,n)),e instanceof Set&&t instanceof Set&&t.forEach(e.add,e);for(const n in t){if(!t.hasOwnProperty(n))continue;const s=t[n],o=e[n];Cs(o)&&Cs(s)&&e.hasOwnProperty(n)&&!ae(s)&&!it(s)?e[n]=Is(o,s):e[n]=s}return e}const cu=Symbol();function uu(e){return!Cs(e)||!e.hasOwnProperty(cu)}const{assign:nt}=Object;function au(e){return!!(ae(e)&&e.effect)}function fu(e,t,n,s){const{state:o,actions:r,getters:i}=t,l=n.state.value[e];let c;function u(){l||(n.state.value[e]=o?o():{});const a=xl(n.state.value[e]);return nt(a,r,Object.keys(i||{}).reduce((p,h)=>(p[h]=Un(_e(()=>{Gn(n);const m=n._s.get(e);return i[h].call(m,m)})),p),{}))}return c=pi(e,u,t,n,s,!0),c}function pi(e,t,n={},s,o,r){let i;const l=nt({actions:{}},n),c={deep:!0};let u,a,p=[],h=[],m;const b=s.state.value[e];!r&&!b&&(s.state.value[e]={}),fe({});let O;function T(W){let z;u=a=!1,typeof W=="function"?(W(s.state.value[e]),z={type:Gt.patchFunction,storeId:e,events:m}):(Is(s.state.value[e],W),z={type:Gt.patchObject,payload:W,storeId:e,events:m});const ce=O=Symbol();Bn().then(()=>{O===ce&&(u=!0)}),a=!0,It(p,z,s.state.value[e])}const k=r?function(){const{state:z}=n,ce=z?z():{};this.$patch(be=>{nt(be,ce)})}:di;function S(){i.stop(),p=[],h=[],s._s.delete(e)}function R(W,z){return function(){Gn(s);const ce=Array.from(arguments),be=[],Ie=[];function Ae(Z){be.push(Z)}function at(Z){Ie.push(Z)}It(h,{args:ce,name:W,store:U,after:Ae,onError:at});let Te;try{Te=z.apply(this&&this.$id===e?this:U,ce)}catch(Z){throw It(Ie,Z),Z}return Te instanceof Promise?Te.then(Z=>(It(be,Z),Z)).catch(Z=>(It(Ie,Z),Promise.reject(Z))):(It(be,Te),Te)}}const E={_p:s,$id:e,$onAction:Ko.bind(null,h),$patch:T,$reset:k,$subscribe(W,z={}){const ce=Ko(p,W,z.detached,()=>be()),be=i.run(()=>Qt(()=>s.state.value[e],Ie=>{(z.flush==="sync"?a:u)&&W({storeId:e,type:Gt.direct,events:m},Ie)},nt({},c,z)));return ce},$dispose:S},U=Bt(E);s._s.set(e,U);const D=s._a&&s._a.runWithContext||lu,J=s._e.run(()=>(i=_r(),D(()=>i.run(t))));for(const W in J){const z=J[W];if(ae(z)&&!au(z)||it(z))r||(b&&uu(z)&&(ae(z)?z.value=b[W]:Is(z,b[W])),s.state.value[e][W]=z);else if(typeof z=="function"){const ce=R(W,z);J[W]=ce,l.actions[W]=z}}return nt(U,J),nt(X(U),J),Object.defineProperty(U,"$state",{get:()=>s.state.value[e],set:W=>{T(z=>{nt(z,W)})}}),s._p.forEach(W=>{nt(U,i.run(()=>W({store:U,app:s._a,pinia:s,options:l})))}),b&&r&&n.hydrate&&n.hydrate(U.$state,b),u=!0,a=!0,U}function du(e,t,n){let s,o;const r=typeof t=="function";typeof e=="string"?(s=e,o=r?n:t):(o=e,s=e.id);function i(l,c){const u=lc();return l=l||(u?je(fi,null):null),l&&Gn(l),l=ai,l._s.has(s)||(r?pi(s,t,o,l):fu(s,o,l)),l._s.get(s)}return i.$id=s,i}const pu="modulepreload",hu=function(e){return"/"+e},Wo={},$=function(t,n,s){if(!n||n.length===0)return t();const o=document.getElementsByTagName("link");return Promise.all(n.map(r=>{if(r=hu(r),r in Wo)return;Wo[r]=!0;const i=r.endsWith(".css"),l=i?'[rel="stylesheet"]':"";if(!!s)for(let a=o.length-1;a>=0;a--){const p=o[a];if(p.href===r&&(!i||p.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${r}"]${l}`))return;const u=document.createElement("link");if(u.rel=i?"stylesheet":pu,i||(u.as="script",u.crossOrigin=""),u.href=r,document.head.appendChild(u),i)return new Promise((a,p)=>{u.addEventListener("load",a),u.addEventListener("error",()=>p(new Error(`Unable to preload CSS for ${r}`)))})})).then(()=>t()).catch(r=>{const i=new Event("vite:preloadError",{cancelable:!0});if(i.payload=r,window.dispatchEvent(i),!i.defaultPrevented)throw r})},gu={class:"breadcrumb"},mu={href:"#/"},_u=["href"],vu=Ce({__name:"BreadCrumb",props:{path:{}},setup(e){const t=e,n=Br(()=>$(()=>import("./home-dada510e.js"),[]));return(s,o)=>(se(),ue("div",gu,[B("a",mu,[(se(),xt(zr(de(n))))]),(se(!0),ue(me,null,qr(t.path,(r,i)=>(se(),ue("a",{key:i,href:`/#/${t.path.slice(0,i+1).join("/")}/`},Ke(r),9,_u))),128))]))}});const yu=(e,t)=>{const n=e[t];return n?typeof n=="function"?n():Promise.resolve(n):new Promise((s,o)=>{(typeof queueMicrotask=="function"?queueMicrotask:setTimeout)(o.bind(null,new Error("Unknown variable dynamic import: "+t)))})},bu={class:"action-button"},Eu=Ce({__name:"SvgButton",props:{name:{}},setup(e){const t=e,n=Br(()=>yu(Object.assign({"../assets/svg/add-file.svg":()=>$(()=>import("./add-file-2fc04ac1.js"),[]),"../assets/svg/add-folder.svg":()=>$(()=>import("./add-folder-94f58a28.js"),[]),"../assets/svg/arrow.svg":()=>$(()=>import("./arrow-21a21451.js"),[]),"../assets/svg/arrows-h.svg":()=>$(()=>import("./arrows-h-b550237f.js"),[]),"../assets/svg/arrows-v.svg":()=>$(()=>import("./arrows-v-caecdc3b.js"),[]),"../assets/svg/check.svg":()=>$(()=>import("./check-046415f8.js"),[]),"../assets/svg/code.svg":()=>$(()=>import("./code-4bea7bf3.js"),[]),"../assets/svg/cog.svg":()=>$(()=>import("./cog-ecf051b6.js"),[]),"../assets/svg/copy.svg":()=>$(()=>import("./copy-5b170f54.js"),[]),"../assets/svg/create-file.svg":()=>$(()=>import("./create-file-6e490c88.js"),[]),"../assets/svg/create-folder.svg":()=>$(()=>import("./create-folder-1568e94d.js"),[]),"../assets/svg/cross.svg":()=>$(()=>import("./cross-27a61986.js"),[]),"../assets/svg/disk.svg":()=>$(()=>import("./disk-5653090a.js"),[]),"../assets/svg/download.svg":()=>$(()=>import("./download-ec9f2727.js"),[]),"../assets/svg/exclamation.svg":()=>$(()=>import("./exclamation-08d41d7b.js"),[]),"../assets/svg/eye.svg":()=>$(()=>import("./eye-0e667df9.js"),[]),"../assets/svg/find.svg":()=>$(()=>import("./find-30f89a67.js"),[]),"../assets/svg/fullscreen.svg":()=>$(()=>import("./fullscreen-c6a4526c.js"),[]),"../assets/svg/github.svg":()=>$(()=>import("./github-8848d98d.js"),[]),"../assets/svg/home.svg":()=>$(()=>import("./home-dada510e.js"),[]),"../assets/svg/info.svg":()=>$(()=>import("./info-3df4ac5e.js"),[]),"../assets/svg/link.svg":()=>$(()=>import("./link-c46ae613.js"),[]),"../assets/svg/logo.svg":()=>$(()=>import("./logo-d85fdccc.js"),[]),"../assets/svg/loop.svg":()=>$(()=>import("./loop-cc973f38.js"),[]),"../assets/svg/menu.svg":()=>$(()=>import("./menu-e55e97c7.js"),[]),"../assets/svg/next.svg":()=>$(()=>import("./next-19846e48.js"),[]),"../assets/svg/open.svg":()=>$(()=>import("./open-f15f038e.js"),[]),"../assets/svg/paste.svg":()=>$(()=>import("./paste-1a4eb209.js"),[]),"../assets/svg/pause.svg":()=>$(()=>import("./pause-6a903b0a.js"),[]),"../assets/svg/pencil.svg":()=>$(()=>import("./pencil-8d9c2a53.js"),[]),"../assets/svg/play.svg":()=>$(()=>import("./play-36147315.js"),[]),"../assets/svg/plus.svg":()=>$(()=>import("./plus-e1eb8193.js"),[]),"../assets/svg/previous.svg":()=>$(()=>import("./previous-b395fe95.js"),[]),"../assets/svg/reload.svg":()=>$(()=>import("./reload-f2a93360.js"),[]),"../assets/svg/rename.svg":()=>$(()=>import("./rename-08cee169.js"),[]),"../assets/svg/scissors.svg":()=>$(()=>import("./scissors-307de9f3.js"),[]),"../assets/svg/shuffle.svg":()=>$(()=>import("./shuffle-fc22ffda.js"),[]),"../assets/svg/signin.svg":()=>$(()=>import("./signin-48d65111.js"),[]),"../assets/svg/signout.svg":()=>$(()=>import("./signout-25062183.js"),[]),"../assets/svg/skip.svg":()=>$(()=>import("./skip-9f8471f2.js"),[]),"../assets/svg/spinner.svg":()=>$(()=>import("./spinner-cdd81338.js"),[]),"../assets/svg/stop.svg":()=>$(()=>import("./stop-f29d283e.js"),[]),"../assets/svg/trash.svg":()=>$(()=>import("./trash-ca0eb8f0.js"),[]),"../assets/svg/triangle.svg":()=>$(()=>import("./triangle-6572f504.js"),[]),"../assets/svg/unfullscreen.svg":()=>$(()=>import("./unfullscreen-a46c175b.js"),[]),"../assets/svg/up-arrow.svg":()=>$(()=>import("./up-arrow-24665650.js"),[]),"../assets/svg/upload-cloud.svg":()=>$(()=>import("./upload-cloud-9ae045e2.js"),[]),"../assets/svg/user-cog.svg":()=>$(()=>import("./user-cog-c3be44ba.js"),[]),"../assets/svg/user.svg":()=>$(()=>import("./user-690c1004.js"),[]),"../assets/svg/volume-high.svg":()=>$(()=>import("./volume-high-2d5673be.js"),[]),"../assets/svg/volume-low.svg":()=>$(()=>import("./volume-low-1f6dfbf0.js"),[]),"../assets/svg/volume-medium.svg":()=>$(()=>import("./volume-medium-388c1627.js"),[]),"../assets/svg/volume-mute.svg":()=>$(()=>import("./volume-mute-e5a998df.js"),[]),"../assets/svg/window-cross.svg":()=>$(()=>import("./window-cross-d65c5d08.js"),[]),"../assets/svg/window.svg":()=>$(()=>import("./window-8624d9ca.js"),[]),"../assets/svg/wordwrap.svg":()=>$(()=>import("./wordwrap-6a772d8f.js"),[]),"../assets/svg/zoomin.svg":()=>$(()=>import("./zoomin-a1c6edbd.js"),[]),"../assets/svg/zoomout.svg":()=>$(()=>import("./zoomout-21f32b89.js"),[])}),`../assets/svg/${t.name}.svg`));return(s,o)=>(se(),ue("button",bu,[(se(),xt(zr(de(n)))),Ys(s.$slots,"default",{},void 0,!0)]))}});const Ht=(e,t)=>{const n=e.__vccOpts||e;for(const[s,o]of t)n[s]=o;return n},to=Ht(Eu,[["__scopeId","data-v-4f4f7fe2"]]);function hi(e){if(e===0)return"empty";for(const t of[null,"kB","MB","GB","TB","PB","EB"]){if(e<1e4)return e.toLocaleString().replace(","," ")+(t?` ${t}`:"");e=Math.round(e/1e3)}return"huge"}function Ss(e){const t=new Date(e*1e3),n=new Date,s=t.getTime()-n.getTime(),o=new Intl.RelativeTimeFormat("en",{numeric:"auto"});return Math.abs(s)<=5e3?"now":Math.abs(s)<=6e4?o.format(Math.round(s/1e3),"second"):Math.abs(s)<=36e5?o.format(Math.round(s/6e4),"minute"):Math.abs(s)<=864e5?o.format(Math.round(s/36e5),"hour"):Math.abs(s)<=6048e5?o.format(Math.round(s/864e5),"day"):t.toLocaleDateString(void 0,{weekday:"short",year:"numeric",month:"short",day:"numeric"})}var no={};Object.defineProperty(no,"__esModule",{value:!0});var gi=no.localeIncludes=void 0,wu=["position","locales"];function xu(e,t){if(e==null)return{};var n=Ru(e,t),s,o;if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(o=0;o=0)&&Object.prototype.propertyIsEnumerable.call(e,s)&&(n[s]=e[s])}return n}function Ru(e,t){if(e==null)return{};var n={},s=Object.keys(e),o,r;for(r=0;r=0)&&(n[o]=e[o]);return n}var Pu=function(t,n){var s=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},o=s.position,r=o===void 0?0:o,i=s.locales,l=xu(s,wu);if(t==null||n===void 0||n===null)throw new Error("localeIncludes requires at least 2 parameters");for(var c=t.length,u=n.length,a=c-u,p=r;p<=a;p++)if(t.substring(p,p+u).localeCompare(n,i,l)===0)return!0;return!1};gi=no.localeIncludes=Pu;const Ze=du({id:"documents",state:()=>({root:{},document:[],selected:new Set,uploadingDocuments:[],uploadCount:0,wsWatch:void 0,wsUpload:void 0,fileExplorer:null,error:"",user:{username:"",privileged:!1,isLoggedIn:!1,isOpenLoginModal:!1}}),actions:{updateTable(e){const t=[];for(const[n,s]of Object.entries(e)){const{id:o,size:r,mtime:i}=s,l={name:n,key:o,size:r,sizedisp:hi(r),mtime:i,modified:Ss(i),type:"dir"in s?"folder":"file"};t.push(l)}t.sort((n,s)=>n.type===s.type?n.name.localeCompare(s.name,void 0,{numeric:!0,sensitivity:"base"}):n.type==="folder"?-1:1),this.document=t},setFilter(e){if(e==="")return this.updateTable({});function t(s,o){if("dir"in s)for(const[r,i]of Object.entries(s.dir)){const l=`${o}/${r}`;gi(r,e,{usage:"search",numeric:!0,sensitivity:"base"})&&(n[l.slice(1)]=i),t(i,l)}}const n={};t(this.root,""),this.updateTable(n)},setActualDocument(e){e=decodeURIComponent(e);let t=this.root;const n=[];try{for(const s of e.split("/").slice(1))if(s){if(!("dir"in t))throw Error("Target folder not available");n.push(s),t=t.dir[s]}}catch(s){console.error("Cannot show requested folder",e,n.join("/"),s)}if(!("dir"in t)){this.document=[];return}this.updateTable(t.dir)},updateUploadingDocuments(e,t){for(const n of this.uploadingDocuments)n.key===e&&(n.progress=t)},pushUploadingDocuments(e){this.uploadCount++;const t={key:this.uploadCount,name:e,progress:0};return this.uploadingDocuments.push(t),t},deleteUploadingDocument(e){this.uploadingDocuments=this.uploadingDocuments.filter(t=>t.key!==e)},updateModified(){for(const e of this.document)"mtime"in e&&(e.modified=Ss(e.mtime))},login(e,t){this.user.username=e,this.user.privileged=t,this.user.isLoggedIn=!0,this.user.isOpenLoginModal=!1}},getters:{mainDocument(){return this.document},isUserLogged(){return this.user.isLoggedIn},selectedFiles(){function e(s,o,r){if("dir"in s)for(const[i,l]of Object.entries(s.dir)){const c=o?`${o}/${i}`:i;let u=r;t.has(l.id)&&!r?(n.selected.add(l.id),n.rootdir[i]=l,u=i):r&&(u=`${r}/${i}`),u&&(n.entries[l.id]=l,n.fullpath[l.id]=c,n.relpath[l.id]=u,n.ids.push(l.id),"dir"in l||(n.url[l.id]=`/files/${c}`)),e(l,c,u)}}const t=this.selected,n={selected:new Set,missing:new Set,rootdir:{},entries:{},fullpath:{},relpath:{},url:{},ids:[]};e(this.root,"","");for(const s of t)n.selected.has(s)||n.missing.add(s);return n.ids.sort((s,o)=>n.relpath[s].localeCompare(n.relpath[o],void 0,{numeric:!0,sensitivity:"base"})),n}}}),Ou=Ce({__name:"UploadButton",setup(e){const t=fe(),n=fe(),s=Ze(),o=a=>i(),r=fe(!1),i=a=>{r.value||(r.value=!0)};async function l(a,p,h){const m=new FileReader,b=new Promise(T=>m.onload=T);m.readAsArrayBuffer(a.slice(p,h));const O=await b;if(O.target&&O.target instanceof FileReader)return O.target.result;throw new Error("Error loading file")}async function c(a,p,h){const m=s.wsUpload;if(m){const b=await l(a,p,h);m.send(JSON.stringify({name:a.name,size:a.size,start:p,end:h})),m.send(b)}}async function u(a){const p=a.target,h=1<<20;if(p&&p.files&&p.files.length>0){const m=p.files[0],b=Math.ceil(m.size/h),O=s.pushUploadingDocuments(m.name);o();for(let T=0;T{const h=to;return se(),ue(me,null,[B("template",null,[B("input",{ref_key:"fileUploadButton",ref:t,onChange:u,class:"upload-input",type:"file",multiple:""},null,544),B("input",{ref_key:"folderUploadButton",ref:n,onChange:u,class:"upload-input",type:"file",webkitdirectory:""},null,544)]),Q(h,{name:"add-file",onClick:p[0]||(p[0]=m=>t.value.click())}),Q(h,{name:"add-folder",onClick:p[1]||(p[1]=m=>n.value.click())})],64)}}}),Cu=e=>(zn("data-v-5fac5f71"),e=e(),qn(),e),Iu={class:"buttons"},Su=Cu(()=>B("div",{class:"spacer"},null,-1)),ku=["onKeyup"],Au=Ce({__name:"HeaderMain",setup(e,{expose:t}){const n=Ze(),s=fe(!1),o=fe(),r=fe(),i=()=>{s.value=!s.value,Bn(()=>{const c=o.value;c?c.focus():r.value&&r.value.blur(),l()})},l=()=>{var c;n.setFilter(((c=o.value)==null?void 0:c.value)??"")};return t({toggleSearchInput:i}),(c,u)=>{const a=Ou,p=to;return se(),ue("nav",null,[B("div",Iu,[Q(a),Q(p,{name:"create-folder",onClick:u[0]||(u[0]=()=>de(n).fileExplorer.newFolder())}),Ys(c.$slots,"default",{},void 0,!0),Su,s.value?(se(),ue("input",{key:0,ref_key:"search",ref:o,type:"search",class:"margin-input",onKeyup:Os(i,["esc"]),onInput:l},null,40,ku)):bt("",!0),Q(p,{ref_key:"searchButton",ref:r,name:"find",onClick:i},null,512),Q(p,{name:"cog",onClick:u[1]||(u[1]=h=>console.log("TODO open settings"))})])])}}});const Tu=Ht(Au,[["__scopeId","data-v-5fac5f71"]]);function Ft(e,t){const n=new URL(e,location.origin.replace(/^http/,"ws")),s=new WebSocket(n);return s.onmessage=t,s}const Mu=e=>(zn("data-v-54db91c1"),e=e(),qn(),e),Lu=Mu(()=>B("div",{class:"smallgap"},null,-1)),$u={class:"select-text"},Du=Ce({__name:"HeaderSelected",props:{path:Array},setup(e){const t=e,n=Ze(),s=_e(()=>t.path.join("/")),o=(c,u)=>{const a=n.selectedFiles,p={op:c,sel:a.ids.filter(m=>a.selected.has(m)).map(m=>a.fullpath[m])};u!==void 0&&(p.dst=u);const h=Ft("/api/control",m=>{const b=JSON.parse(m.data);if("error"in b){console.error("Control socket error",p,b.error);return}else if(b.status==="ack"){console.log("Control ack OK",b),h.close(),n.selected.clear();return}else console.log("Unknown control respons",p,b)});h.onopen=()=>{h.send(JSON.stringify(p))}},r=c=>{const u=document.createElement("a");u.href=c,u.download="",u.click()},i=async(c,u)=>{let a="",p=u,h=[];for(const m of c.ids)h.push(c.relpath[m]);console.log("Downloading to filesystem",h);for(const m of c.ids){const b=c.relpath[m],O=c.url[m];b.startsWith(a)||(a="",p=u);const T=b.slice(a.length);for(const U of T.split("/").slice(0,O?-1:void 0)){a+=`${U}/`;try{p=await p.getDirectoryHandle(U.normalize("NFC"),{create:!0})}catch(D){console.error("Failed to create directory",a,D);return}console.log("Created",a)}if(!O)continue;const k=b.split("/").pop().normalize("NFC");let S;try{S=await p.getFileHandle(k,{create:!0})}catch(U){console.error("Failed to create file",a+k,U);return}const R=await S.createWritable();console.log("Fetching",O);const E=await fetch(O);if(!E.ok)throw new Error(`Failed to download ${O}: ${E.status} ${E.statusText}`);E.body?await E.body.pipeTo(R):(await R.truncate(0),await R.close()),console.log("Saved",a+k)}},l=async()=>{const c=n.selectedFiles;if(console.log("Download",c),c.selected.size===0){console.warn("Attempted download but no files found. Missing:",c.missing),n.selected.clear();return}const u=Object.values(c.url);if(u.length===1)return n.selected.clear(),r(u[0]);if("showDirectoryPicker"in window)try{const a=await window.showDirectoryPicker({startIn:"downloads",mode:"readwrite"});i(c,a).then(()=>{n.selected.clear()});return}catch(a){console.error("Download to folder aborted",a)}r(`/zip/${Array.from(c.selected).join("+")}/download.zip`),n.selected.clear()};return(c,u)=>{const a=to;return de(n).selected.size?(se(),ue(me,{key:0},[Lu,B("p",$u,Ke(de(n).selected.size)+" selected ➤",1),Q(a,{name:"download",onClick:l}),Q(a,{name:"copy",onClick:u[0]||(u[0]=p=>o("cp",s.value))}),Q(a,{name:"paste",onClick:u[1]||(u[1]=p=>o("mv",s.value))}),Q(a,{name:"trash",onClick:u[2]||(u[2]=p=>o("rm"))}),B("button",{onClick:u[3]||(u[3]=p=>de(n).selected.clear())},"❌")],64)):bt("",!0)}}});const Fu=Ht(Du,[["__scopeId","data-v-54db91c1"]]),ju={key:0},Nu=B("button",{onclick:"dialog.close()"},"OK",-1),Vu=Ce({__name:"ModalDialog",props:{title:{default:""}},setup(e){const t=e,n=fe(null);return Qn(()=>{n.value.showModal()}),(s,o)=>(se(),ue("dialog",{ref_key:"dialog",ref:n},[t.title?(se(),ue("h1",ju,Ke(t.title),1)):bt("",!0),B("div",null,[Ys(s.$slots,"default",{},()=>[ri(" Dialog with no content "),Nu])])],512))}});class Uu{async post(t,n){const s=await fetch(t,{method:"POST",headers:{accept:"application/json","content-type":"application/json"},body:n!==void 0?JSON.stringify(n):void 0});let o;try{o=await s.json()}catch{throw new zo(s.status,`HTTP ${s.status} ${s.statusText}`)}if("error"in o)throw new zo(o.error.code,o.error.message);return o}}const mi=new Uu;class zo extends Error{constructor(n,s){super(s);uo(this,"code");this.code=n}}const Bu="/login",Hu="/logout ";async function Ku(e,t){return await mi.post(Bu,{username:e,password:t})}async function Wu(){return await mi.post(Hu)}const so=e=>(zn("data-v-0167bcf4"),e=e(),qn(),e),zu=["onSubmit"],qu={class:"login-container"},Ju=so(()=>B("label",{for:"username"},"Username:",-1)),Qu=so(()=>B("label",{for:"password"},"Password:",-1)),Yu={key:0,class:"error-text"},Xu=so(()=>B("input",{id:"submit",type:"submit",class:"button-login"},null,-1)),Zu=Ce({__name:"LoginModal",setup(e){const t=fe(!1),n=Ze(),s=async()=>{try{await Wu()}finally{location.reload()}},o=Bt({username:"",password:"",error:""}),r=async()=>{try{o.error="",t.value=!0;const i=await Ku(o.username,o.password);console.log("Logged in",i),n.login(i.username,!!i.privileged)}catch(i){const l=i;l.name&&(o.error=l.message)}finally{t.value=!1}};return(i,l)=>{const c=Vu;return se(),ue(me,null,[de(n).isUserLogged?(se(),ue("button",{key:0,onClick:s,class:"action-button"}," Logout "+Ke(de(n).user.username),1)):bt("",!0),de(n).user.isOpenLoginModal?(se(),xt(c,{key:1,title:"Login"},{default:zs(()=>[B("form",{onSubmit:pt(r,["prevent"])},[B("div",qu,[Ju,Sn(B("input",{id:"username",name:"username",autocomplete:"username",required:"","onUpdate:modelValue":l[0]||(l[0]=u=>o.username=u)},null,512),[[Ps,o.username]]),Qu,Sn(B("input",{id:"password",name:"password",type:"password",autocomplete:"current-password",required:"","onUpdate:modelValue":l[1]||(l[1]=u=>o.password=u)},null,512),[[Ps,o.password]])]),o.error.length>0?(se(),ue("h3",Yu,Ke(o.error),1)):bt("",!0),Xu],40,zu)]),_:1})):bt("",!0)],64)}}});const Gu=Ht(Zu,[["__scopeId","data-v-0167bcf4"]]);/*! * vue-router v4.2.4 * (c) 2023 Eduardo San Martin Morote * @license MIT */const St=typeof window<"u";function ea(e){return e.__esModule||e[Symbol.toStringTag]==="Module"}const te=Object.assign;function as(e,t){const n={};for(const s in t){const o=t[s];n[s]=Ne(o)?o.map(e):e(o)}return n}const en=()=>{},Ne=Array.isArray,ta=/\/$/,na=e=>e.replace(ta,"");function fs(e,t,n="/"){let s,o={},r="",i="";const l=t.indexOf("#");let c=t.indexOf("?");return l=0&&(c=-1),c>-1&&(s=t.slice(0,c),r=t.slice(c+1,l>-1?l:t.length),o=e(r)),l>-1&&(s=s||t.slice(0,l),i=t.slice(l,t.length)),s=ia(s??t,n),{fullPath:s+(r&&"?")+r+i,path:s,query:o,hash:i}}function sa(e,t){const n=t.query?e(t.query):"";return t.path+(n&&"?")+n+(t.hash||"")}function qo(e,t){return!t||!e.toLowerCase().startsWith(t.toLowerCase())?e:e.slice(t.length)||"/"}function oa(e,t,n){const s=t.matched.length-1,o=n.matched.length-1;return s>-1&&s===o&&jt(t.matched[s],n.matched[o])&&_i(t.params,n.params)&&e(t.query)===e(n.query)&&t.hash===n.hash}function jt(e,t){return(e.aliasOf||e)===(t.aliasOf||t)}function _i(e,t){if(Object.keys(e).length!==Object.keys(t).length)return!1;for(const n in e)if(!ra(e[n],t[n]))return!1;return!0}function ra(e,t){return Ne(e)?Jo(e,t):Ne(t)?Jo(t,e):e===t}function Jo(e,t){return Ne(t)?e.length===t.length&&e.every((n,s)=>n===t[s]):e.length===1&&e[0]===t}function ia(e,t){if(e.startsWith("/"))return e;if(!e)return t;const n=t.split("/"),s=e.split("/"),o=s[s.length-1];(o===".."||o===".")&&s.push("");let r=n.length-1,i,l;for(i=0;i1&&r--;else break;return n.slice(0,r).join("/")+"/"+s.slice(i-(i===s.length?1:0)).join("/")}var an;(function(e){e.pop="pop",e.push="push"})(an||(an={}));var tn;(function(e){e.back="back",e.forward="forward",e.unknown=""})(tn||(tn={}));function la(e){if(!e)if(St){const t=document.querySelector("base");e=t&&t.getAttribute("href")||"/",e=e.replace(/^\w+:\/\/[^\/]+/,"")}else e="/";return e[0]!=="/"&&e[0]!=="#"&&(e="/"+e),na(e)}const ca=/^[^#]+#/;function ua(e,t){return e.replace(ca,"#")+t}function aa(e,t){const n=document.documentElement.getBoundingClientRect(),s=e.getBoundingClientRect();return{behavior:t.behavior,left:s.left-n.left-(t.left||0),top:s.top-n.top-(t.top||0)}}const es=()=>({left:window.pageXOffset,top:window.pageYOffset});function fa(e){let t;if("el"in e){const n=e.el,s=typeof n=="string"&&n.startsWith("#"),o=typeof n=="string"?s?document.getElementById(n.slice(1)):document.querySelector(n):n;if(!o)return;t=aa(o,e)}else t=e;"scrollBehavior"in document.documentElement.style?window.scrollTo(t):window.scrollTo(t.left!=null?t.left:window.pageXOffset,t.top!=null?t.top:window.pageYOffset)}function Qo(e,t){return(history.state?history.state.position-t:-1)+e}const ks=new Map;function da(e,t){ks.set(e,t)}function pa(e){const t=ks.get(e);return ks.delete(e),t}let ha=()=>location.protocol+"//"+location.host;function vi(e,t){const{pathname:n,search:s,hash:o}=t,r=e.indexOf("#");if(r>-1){let l=o.includes(e.slice(r))?e.slice(r).length:1,c=o.slice(l);return c[0]!=="/"&&(c="/"+c),qo(c,"")}return qo(n,e)+s+o}function ga(e,t,n,s){let o=[],r=[],i=null;const l=({state:h})=>{const m=vi(e,location),b=n.value,O=t.value;let T=0;if(h){if(n.value=m,t.value=h,i&&i===b){i=null;return}T=O?h.position-O.position:0}else s(m);o.forEach(k=>{k(n.value,b,{delta:T,type:an.pop,direction:T?T>0?tn.forward:tn.back:tn.unknown})})};function c(){i=n.value}function u(h){o.push(h);const m=()=>{const b=o.indexOf(h);b>-1&&o.splice(b,1)};return r.push(m),m}function a(){const{history:h}=window;h.state&&h.replaceState(te({},h.state,{scroll:es()}),"")}function p(){for(const h of r)h();r=[],window.removeEventListener("popstate",l),window.removeEventListener("beforeunload",a)}return window.addEventListener("popstate",l),window.addEventListener("beforeunload",a,{passive:!0}),{pauseListeners:c,listen:u,destroy:p}}function Yo(e,t,n,s=!1,o=!1){return{back:e,current:t,forward:n,replaced:s,position:window.history.length,scroll:o?es():null}}function ma(e){const{history:t,location:n}=window,s={value:vi(e,n)},o={value:t.state};o.value||r(s.value,{back:null,current:s.value,forward:null,position:t.length-1,replaced:!0,scroll:null},!0);function r(c,u,a){const p=e.indexOf("#"),h=p>-1?(n.host&&document.querySelector("base")?e:e.slice(p))+c:ha()+e+c;try{t[a?"replaceState":"pushState"](u,"",h),o.value=u}catch(m){console.error(m),n[a?"replace":"assign"](h)}}function i(c,u){const a=te({},t.state,Yo(o.value.back,c,o.value.forward,!0),u,{position:o.value.position});r(c,a,!0),s.value=c}function l(c,u){const a=te({},o.value,t.state,{forward:c,scroll:es()});r(a.current,a,!0);const p=te({},Yo(s.value,c,null),{position:a.position+1},u);r(c,p,!1),s.value=c}return{location:s,state:o,push:l,replace:i}}function _a(e){e=la(e);const t=ma(e),n=ga(e,t.state,t.location,t.replace);function s(r,i=!0){i||n.pauseListeners(),history.go(r)}const o=te({location:"",base:e,go:s,createHref:ua.bind(null,e)},t,n);return Object.defineProperty(o,"location",{enumerable:!0,get:()=>t.location.value}),Object.defineProperty(o,"state",{enumerable:!0,get:()=>t.state.value}),o}function va(e){return e=location.host?e||location.pathname+location.search:"",e.includes("#")||(e+="#"),_a(e)}function ya(e){return typeof e=="string"||e&&typeof e=="object"}function yi(e){return typeof e=="string"||typeof e=="symbol"}const tt={path:"/",name:void 0,params:{},query:{},hash:"",fullPath:"/",matched:[],meta:{},redirectedFrom:void 0},bi=Symbol("");var Xo;(function(e){e[e.aborted=4]="aborted",e[e.cancelled=8]="cancelled",e[e.duplicated=16]="duplicated"})(Xo||(Xo={}));function Nt(e,t){return te(new Error,{type:e,[bi]:!0},t)}function Je(e,t){return e instanceof Error&&bi in e&&(t==null||!!(e.type&t))}const Zo="[^/]+?",ba={sensitive:!1,strict:!1,start:!0,end:!0},Ea=/[.+*?^${}()[\]/\\]/g;function wa(e,t){const n=te({},ba,t),s=[];let o=n.start?"^":"";const r=[];for(const u of e){const a=u.length?[]:[90];n.strict&&!u.length&&(o+="/");for(let p=0;pt.length?t.length===1&&t[0]===40+40?1:-1:0}function Ra(e,t){let n=0;const s=e.score,o=t.score;for(;n0&&t[t.length-1]<0}const Pa={type:0,value:""},Oa=/[a-zA-Z0-9_]/;function Ca(e){if(!e)return[[]];if(e==="/")return[[Pa]];if(!e.startsWith("/"))throw new Error(`Invalid path "${e}"`);function t(m){throw new Error(`ERR (${n})/"${u}": ${m}`)}let n=0,s=n;const o=[];let r;function i(){r&&o.push(r),r=[]}let l=0,c,u="",a="";function p(){u&&(n===0?r.push({type:0,value:u}):n===1||n===2||n===3?(r.length>1&&(c==="*"||c==="+")&&t(`A repeatable param (${u}) must be alone in its segment. eg: '/:ids+.`),r.push({type:1,value:u,regexp:a,repeatable:c==="*"||c==="+",optional:c==="*"||c==="?"})):t("Invalid state to consume buffer"),u="")}function h(){u+=c}for(;l{i(S)}:en}function i(a){if(yi(a)){const p=s.get(a);p&&(s.delete(a),n.splice(n.indexOf(p),1),p.children.forEach(i),p.alias.forEach(i))}else{const p=n.indexOf(a);p>-1&&(n.splice(p,1),a.record.name&&s.delete(a.record.name),a.children.forEach(i),a.alias.forEach(i))}}function l(){return n}function c(a){let p=0;for(;p=0&&(a.record.path!==n[p].record.path||!Ei(a,n[p]));)p++;n.splice(p,0,a),a.record.name&&!tr(a)&&s.set(a.record.name,a)}function u(a,p){let h,m={},b,O;if("name"in a&&a.name){if(h=s.get(a.name),!h)throw Nt(1,{location:a});O=h.record.name,m=te(er(p.params,h.keys.filter(S=>!S.optional).map(S=>S.name)),a.params&&er(a.params,h.keys.map(S=>S.name))),b=h.stringify(m)}else if("path"in a)b=a.path,h=n.find(S=>S.re.test(b)),h&&(m=h.parse(b),O=h.record.name);else{if(h=p.name?s.get(p.name):n.find(S=>S.re.test(p.path)),!h)throw Nt(1,{location:a,currentLocation:p});O=h.record.name,m=te({},p.params,a.params),b=h.stringify(m)}const T=[];let k=h;for(;k;)T.unshift(k.record),k=k.parent;return{name:O,path:b,params:m,matched:T,meta:Ta(T)}}return e.forEach(a=>r(a)),{addRoute:r,resolve:u,removeRoute:i,getRoutes:l,getRecordMatcher:o}}function er(e,t){const n={};for(const s of t)s in e&&(n[s]=e[s]);return n}function ka(e){return{path:e.path,redirect:e.redirect,name:e.name,meta:e.meta||{},aliasOf:void 0,beforeEnter:e.beforeEnter,props:Aa(e),children:e.children||[],instances:{},leaveGuards:new Set,updateGuards:new Set,enterCallbacks:{},components:"components"in e?e.components||null:e.component&&{default:e.component}}}function Aa(e){const t={},n=e.props||!1;if("component"in e)t.default=n;else for(const s in e.components)t[s]=typeof n=="object"?n[s]:n;return t}function tr(e){for(;e;){if(e.record.aliasOf)return!0;e=e.parent}return!1}function Ta(e){return e.reduce((t,n)=>te(t,n.meta),{})}function nr(e,t){const n={};for(const s in e)n[s]=s in t?t[s]:e[s];return n}function Ei(e,t){return t.children.some(n=>n===e||Ei(e,n))}const wi=/#/g,Ma=/&/g,La=/\//g,$a=/=/g,Da=/\?/g,xi=/\+/g,Fa=/%5B/g,ja=/%5D/g,Ri=/%5E/g,Na=/%60/g,Pi=/%7B/g,Va=/%7C/g,Oi=/%7D/g,Ua=/%20/g;function oo(e){return encodeURI(""+e).replace(Va,"|").replace(Fa,"[").replace(ja,"]")}function Ba(e){return oo(e).replace(Pi,"{").replace(Oi,"}").replace(Ri,"^")}function As(e){return oo(e).replace(xi,"%2B").replace(Ua,"+").replace(wi,"%23").replace(Ma,"%26").replace(Na,"`").replace(Pi,"{").replace(Oi,"}").replace(Ri,"^")}function Ha(e){return As(e).replace($a,"%3D")}function Ka(e){return oo(e).replace(wi,"%23").replace(Da,"%3F")}function Wa(e){return e==null?"":Ka(e).replace(La,"%2F")}function Mn(e){try{return decodeURIComponent(""+e)}catch{}return""+e}function za(e){const t={};if(e===""||e==="?")return t;const s=(e[0]==="?"?e.slice(1):e).split("&");for(let o=0;or&&As(r)):[s&&As(s)]).forEach(r=>{r!==void 0&&(t+=(t.length?"&":"")+n,r!=null&&(t+="="+r))})}return t}function qa(e){const t={};for(const n in e){const s=e[n];s!==void 0&&(t[n]=Ne(s)?s.map(o=>o==null?null:""+o):s==null?s:""+s)}return t}const Ja=Symbol(""),or=Symbol(""),ts=Symbol(""),Ci=Symbol(""),Ts=Symbol("");function zt(){let e=[];function t(s){return e.push(s),()=>{const o=e.indexOf(s);o>-1&&e.splice(o,1)}}function n(){e=[]}return{add:t,list:()=>e.slice(),reset:n}}function ot(e,t,n,s,o){const r=s&&(s.enterCallbacks[o]=s.enterCallbacks[o]||[]);return()=>new Promise((i,l)=>{const c=p=>{p===!1?l(Nt(4,{from:n,to:t})):p instanceof Error?l(p):ya(p)?l(Nt(2,{from:t,to:p})):(r&&s.enterCallbacks[o]===r&&typeof p=="function"&&r.push(p),i())},u=e.call(s&&s.instances[o],t,n,c);let a=Promise.resolve(u);e.length<3&&(a=a.then(c)),a.catch(p=>l(p))})}function ds(e,t,n,s){const o=[];for(const r of e)for(const i in r.components){let l=r.components[i];if(!(t!=="beforeRouteEnter"&&!r.instances[i]))if(Qa(l)){const u=(l.__vccOpts||l)[t];u&&o.push(ot(u,n,s,r,i))}else{let c=l();o.push(()=>c.then(u=>{if(!u)return Promise.reject(new Error(`Couldn't resolve component "${i}" at "${r.path}"`));const a=ea(u)?u.default:u;r.components[i]=a;const h=(a.__vccOpts||a)[t];return h&&ot(h,n,s,r,i)()}))}}return o}function Qa(e){return typeof e=="object"||"displayName"in e||"props"in e||"__vccOpts"in e}function rr(e){const t=je(ts),n=je(Ci),s=_e(()=>t.resolve(de(e.to))),o=_e(()=>{const{matched:c}=s.value,{length:u}=c,a=c[u-1],p=n.matched;if(!a||!p.length)return-1;const h=p.findIndex(jt.bind(null,a));if(h>-1)return h;const m=ir(c[u-2]);return u>1&&ir(a)===m&&p[p.length-1].path!==m?p.findIndex(jt.bind(null,c[u-2])):h}),r=_e(()=>o.value>-1&&Ga(n.params,s.value.params)),i=_e(()=>o.value>-1&&o.value===n.matched.length-1&&_i(n.params,s.value.params));function l(c={}){return Za(c)?t[de(e.replace)?"replace":"push"](de(e.to)).catch(en):Promise.resolve()}return{route:s,href:_e(()=>s.value.href),isActive:r,isExactActive:i,navigate:l}}const Ya=Ce({name:"RouterLink",compatConfig:{MODE:3},props:{to:{type:[String,Object],required:!0},replace:Boolean,activeClass:String,exactActiveClass:String,custom:Boolean,ariaCurrentValue:{type:String,default:"page"}},useLink:rr,setup(e,{slots:t}){const n=Bt(rr(e)),{options:s}=je(ts),o=_e(()=>({[lr(e.activeClass,s.linkActiveClass,"router-link-active")]:n.isActive,[lr(e.exactActiveClass,s.linkExactActiveClass,"router-link-exact-active")]:n.isExactActive}));return()=>{const r=t.default&&t.default(n);return e.custom?r:ci("a",{"aria-current":n.isExactActive?e.ariaCurrentValue:null,href:n.href,onClick:n.navigate,class:o.value},r)}}}),Xa=Ya;function Za(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 Ga(e,t){for(const n in t){const s=t[n],o=e[n];if(typeof s=="string"){if(s!==o)return!1}else if(!Ne(o)||o.length!==s.length||s.some((r,i)=>r!==o[i]))return!1}return!0}function ir(e){return e?e.aliasOf?e.aliasOf.path:e.path:""}const lr=(e,t,n)=>e??t??n,ef=Ce({name:"RouterView",inheritAttrs:!1,props:{name:{type:String,default:"default"},route:Object},compatConfig:{MODE:3},setup(e,{attrs:t,slots:n}){const s=je(Ts),o=_e(()=>e.route||s.value),r=je(or,0),i=_e(()=>{let u=de(r);const{matched:a}=o.value;let p;for(;(p=a[u])&&!p.components;)u++;return u}),l=_e(()=>o.value.matched[i.value]);wn(or,_e(()=>i.value+1)),wn(Ja,l),wn(Ts,o);const c=fe();return Qt(()=>[c.value,l.value,e.name],([u,a,p],[h,m,b])=>{a&&(a.instances[p]=u,m&&m!==a&&u&&u===h&&(a.leaveGuards.size||(a.leaveGuards=m.leaveGuards),a.updateGuards.size||(a.updateGuards=m.updateGuards))),u&&a&&(!m||!jt(a,m)||!h)&&(a.enterCallbacks[p]||[]).forEach(O=>O(u))},{flush:"post"}),()=>{const u=o.value,a=e.name,p=l.value,h=p&&p.components[a];if(!h)return cr(n.default,{Component:h,route:u});const m=p.props[a],b=m?m===!0?u.params:typeof m=="function"?m(u):m:null,T=ci(h,te({},b,t,{onVnodeUnmounted:k=>{k.component.isUnmounted&&(p.instances[a]=null)},ref:c}));return cr(n.default,{Component:T,route:u})||T}}});function cr(e,t){if(!e)return null;const n=e(t);return n.length===1?n[0]:n}const Ii=ef;function tf(e){const t=Sa(e.routes,e),n=e.parseQuery||za,s=e.stringifyQuery||sr,o=e.history,r=zt(),i=zt(),l=zt(),c=bl(tt);let u=tt;St&&e.scrollBehavior&&"scrollRestoration"in history&&(history.scrollRestoration="manual");const a=as.bind(null,v=>""+v),p=as.bind(null,Wa),h=as.bind(null,Mn);function m(v,M){let I,F;return yi(v)?(I=t.getRecordMatcher(v),F=M):F=v,t.addRoute(F,I)}function b(v){const M=t.getRecordMatcher(v);M&&t.removeRoute(M)}function O(){return t.getRoutes().map(v=>v.record)}function T(v){return!!t.getRecordMatcher(v)}function k(v,M){if(M=te({},M||c.value),typeof v=="string"){const g=fs(n,v,M.path),_=t.resolve({path:g.path},M),y=o.createHref(g.fullPath);return te(g,_,{params:h(_.params),hash:Mn(g.hash),redirectedFrom:void 0,href:y})}let I;if("path"in v)I=te({},v,{path:fs(n,v.path,M.path).path});else{const g=te({},v.params);for(const _ in g)g[_]==null&&delete g[_];I=te({},v,{params:p(g)}),M.params=p(M.params)}const F=t.resolve(I,M),ee=v.hash||"";F.params=a(h(F.params));const f=sa(s,te({},v,{hash:Ba(ee),path:F.path})),d=o.createHref(f);return te({fullPath:f,hash:ee,query:s===sr?qa(v.query):v.query||{}},F,{redirectedFrom:void 0,href:d})}function S(v){return typeof v=="string"?fs(n,v,c.value.path):te({},v)}function R(v,M){if(u!==v)return Nt(8,{from:M,to:v})}function E(v){return J(v)}function U(v){return E(te(S(v),{replace:!0}))}function D(v){const M=v.matched[v.matched.length-1];if(M&&M.redirect){const{redirect:I}=M;let F=typeof I=="function"?I(v):I;return typeof F=="string"&&(F=F.includes("?")||F.includes("#")?F=S(F):{path:F},F.params={}),te({query:v.query,hash:v.hash,params:"path"in F?{}:v.params},F)}}function J(v,M){const I=u=k(v),F=c.value,ee=v.state,f=v.force,d=v.replace===!0,g=D(I);if(g)return J(te(S(g),{state:typeof g=="object"?te({},ee,g.state):ee,force:f,replace:d}),M||I);const _=I;_.redirectedFrom=M;let y;return!f&&oa(s,F,I)&&(y=Nt(16,{to:_,from:F}),Ve(F,F,!0,!1)),(y?Promise.resolve(y):ce(_,F)).catch(w=>Je(w)?Je(w,2)?w:Ge(w):G(w,_,F)).then(w=>{if(w){if(Je(w,2))return J(te({replace:d},S(w.to),{state:typeof w.to=="object"?te({},ee,w.to.state):ee,force:f}),M||_)}else w=Ie(_,F,!0,d,ee);return be(_,F,w),w})}function W(v,M){const I=R(v,M);return I?Promise.reject(I):Promise.resolve()}function z(v){const M=Pt.values().next().value;return M&&typeof M.runWithContext=="function"?M.runWithContext(v):v()}function ce(v,M){let I;const[F,ee,f]=nf(v,M);I=ds(F.reverse(),"beforeRouteLeave",v,M);for(const g of F)g.leaveGuards.forEach(_=>{I.push(ot(_,v,M))});const d=W.bind(null,v,M);return I.push(d),Ee(I).then(()=>{I=[];for(const g of r.list())I.push(ot(g,v,M));return I.push(d),Ee(I)}).then(()=>{I=ds(ee,"beforeRouteUpdate",v,M);for(const g of ee)g.updateGuards.forEach(_=>{I.push(ot(_,v,M))});return I.push(d),Ee(I)}).then(()=>{I=[];for(const g of f)if(g.beforeEnter)if(Ne(g.beforeEnter))for(const _ of g.beforeEnter)I.push(ot(_,v,M));else I.push(ot(g.beforeEnter,v,M));return I.push(d),Ee(I)}).then(()=>(v.matched.forEach(g=>g.enterCallbacks={}),I=ds(f,"beforeRouteEnter",v,M),I.push(d),Ee(I))).then(()=>{I=[];for(const g of i.list())I.push(ot(g,v,M));return I.push(d),Ee(I)}).catch(g=>Je(g,8)?g:Promise.reject(g))}function be(v,M,I){l.list().forEach(F=>z(()=>F(v,M,I)))}function Ie(v,M,I,F,ee){const f=R(v,M);if(f)return f;const d=M===tt,g=St?history.state:{};I&&(F||d?o.replace(v.fullPath,te({scroll:d&&g&&g.scroll},ee)):o.push(v.fullPath,ee)),c.value=v,Ve(v,M,I,d),Ge()}let Ae;function at(){Ae||(Ae=o.listen((v,M,I)=>{if(!pn.listening)return;const F=k(v),ee=D(F);if(ee){J(te(ee,{replace:!0}),F).catch(en);return}u=F;const f=c.value;St&&da(Qo(f.fullPath,I.delta),es()),ce(F,f).catch(d=>Je(d,12)?d:Je(d,2)?(J(d.to,F).then(g=>{Je(g,20)&&!I.delta&&I.type===an.pop&&o.go(-1,!1)}).catch(en),Promise.reject()):(I.delta&&o.go(-I.delta,!1),G(d,F,f))).then(d=>{d=d||Ie(F,f,!1),d&&(I.delta&&!Je(d,8)?o.go(-I.delta,!1):I.type===an.pop&&Je(d,20)&&o.go(-1,!1)),be(F,f,d)}).catch(en)}))}let Te=zt(),Z=zt(),oe;function G(v,M,I){Ge(v);const F=Z.list();return F.length?F.forEach(ee=>ee(v,M,I)):console.error(v),Promise.reject(v)}function qe(){return oe&&c.value!==tt?Promise.resolve():new Promise((v,M)=>{Te.add([v,M])})}function Ge(v){return oe||(oe=!v,at(),Te.list().forEach(([M,I])=>v?I(v):M()),Te.reset()),v}function Ve(v,M,I,F){const{scrollBehavior:ee}=e;if(!St||!ee)return Promise.resolve();const f=!I&&pa(Qo(v.fullPath,0))||(F||!I)&&history.state&&history.state.scroll||null;return Bn().then(()=>ee(v,M,f)).then(d=>d&&fa(d)).catch(d=>G(d,v,M))}const Re=v=>o.go(v);let Rt;const Pt=new Set,pn={currentRoute:c,listening:!0,addRoute:m,removeRoute:b,hasRoute:T,getRoutes:O,resolve:k,options:e,push:E,replace:U,go:Re,back:()=>Re(-1),forward:()=>Re(1),beforeEach:r.add,beforeResolve:i.add,afterEach:l.add,onError:Z.add,isReady:qe,install(v){const M=this;v.component("RouterLink",Xa),v.component("RouterView",Ii),v.config.globalProperties.$router=M,Object.defineProperty(v.config.globalProperties,"$route",{enumerable:!0,get:()=>de(c)}),St&&!Rt&&c.value===tt&&(Rt=!0,E(o.location).catch(ee=>{}));const I={};for(const ee in tt)Object.defineProperty(I,ee,{get:()=>c.value[ee],enumerable:!0});v.provide(ts,M),v.provide(Ci,Sr(I)),v.provide(Ts,c);const F=v.unmount;Pt.add(v),v.unmount=function(){Pt.delete(v),Pt.size<1&&(u=tt,Ae&&Ae(),Ae=null,c.value=tt,Rt=!1,oe=!1),F()}}};function Ee(v){return v.reduce((M,I)=>M.then(()=>z(I)),Promise.resolve())}return pn}function nf(e,t){const n=[],s=[],o=[],r=Math.max(t.matched.length,e.matched.length);for(let i=0;ijt(u,l))?s.push(l):n.push(l));const c=e.matched[i];c&&(t.matched.find(u=>jt(u,c))||o.push(c))}return[n,s,o]}function sf(){return je(ts)}const Si="/api/watch",of="/api/upload";class rf{constructor(t=Ze()){this.store=t,this.handleWebSocketMessage=this.handleWebSocketMessage.bind(this)}handleWebSocketMessage(t){const n=JSON.parse(t.data);switch("error"in n&&(n.error.code===401?(this.store.user.isLoggedIn=!1,this.store.user.isOpenLoginModal=!0):this.store.error=n.error.message,setTimeout(()=>{this.store.wsWatch=Ft(Si,this.handleWebSocketMessage)},1e3)),!0){case!!n.root:this.handleRootMessage(n);break;case!!n.update:this.handleUpdateMessage(n);break;case!!n.error:this.handleError(n);break}}handleRootMessage({root:t}){this.store&&this.store.root&&(this.store.user.isLoggedIn=!0,this.store.root=t)}handleUpdateMessage(t){var s,o;let n=this.store.root;for(const r of t.update){if(r.deleted){delete n.dir[r.name];break}r.name!==void 0&&(n=(s=n.dir)[o=r.name]||(s[o]={})),r.id!==void 0&&(n.id=r.id),r.size!==void 0&&(n.size=r.size),r.mtime!==void 0&&(n.mtime=r.mtime),r.dir!==void 0&&(n.dir=r.dir)}}handleError(t){if(t.error.code===401){this.store.user.isOpenLoginModal=!0,this.store.user.isLoggedIn=!1;return}}}class lf{constructor(t=Ze()){this.store=t,this.handleWebSocketMessage=this.handleWebSocketMessage.bind(this)}handleWebSocketMessage(t){const n=JSON.parse(t.data);switch(!0){case!!n.written:this.handleWrittenMessage(n);break}}handleWrittenMessage(t){console.log("Written message",t.written)}}const cf=["onKeyup"],ur=Ce({__name:"FileRenameInput",props:{doc:{},rename:{type:Function},exit:{type:Function}},setup(e){const t=e,n=fe(null),s=fe("");Qn(()=>{s.value=t.doc.name;const r=s.value.lastIndexOf(".");n.value.focus(),n.value.setSelectionRange(0,r>0?r:s.value.length)});const o=()=>{t.exit(),!(t.doc.key!=="new"&&(s.value===t.doc.name||s.value.length===0))&&t.rename(t.doc,s.value)};return(r,i)=>Sn((se(),ue("input",{ref_key:"input",ref:n,id:"FileRenameInput",type:"text","onUpdate:modelValue":i[0]||(i[0]=l=>s.value=l),onKeyup:[i[1]||(i[1]=Os((...l)=>r.exit&&r.exit(...l),["esc"])),Os(o,["enter"])]},null,40,cf)),[[Ps,s.value]])}});const ro=e=>(zn("data-v-79d60fb2"),e=e(),qn(),e),uf={class:"selection"},af=["indeterminate"],ff=ro(()=>B("th",{class:"menu"},null,-1)),df={key:0,class:"folder"},pf=ro(()=>B("td",{class:"selection"},null,-1)),hf={class:"name"},gf={class:"modified right"},mf={class:"size right"},_f=ro(()=>B("td",{class:"menu"},null,-1)),vf=["id","onClick","onContextmenu"],yf=["onClick"],bf=["checked","onChange"],Ef={class:"name"},wf=["href","onFocus"],xf=["onClick"],Rf={class:"modified right"},Pf={class:"size right"},Of={class:"menu"},Cf=["onClick"],If={key:1,class:"empty-container"},Sf=Ce({__name:"FileExplorer",props:{path:{},documents:{}},setup(e,{expose:t}){const n=e,s=Ze(),o=sf(),r=_e(()=>n.path.join("/")),i=_e(()=>`/files/${r.value}`),l=R=>R.type==="folder"?`#${r.value}/${R.name}/`:`${i.value}/${R.name}`,c=fe(null),u=fe(null),a=(R,E)=>{const U=R.name,D=Ft("/api/control",J=>{const W=JSON.parse(J.data);"error"in W?(console.error("Rename failed",W.error.message,W.error),R.name=U):console.log("Rename succeeded",W)});D.onopen=()=>{D.send(JSON.stringify({op:"rename",path:`${decodeURIComponent(r.value)}/${U}`,to:E}))},R.name=E};t({newFolder(){const R=Date.now()/1e3;u.value={key:"new",name:"New Folder",type:"folder",mtime:R,size:0,sizedisp:hi(0),modified:Ss(R)}},toggleSelectAll(){console.log("Select"),k.value=!k.value},toggleSortColumn(R){h(["","name","modified","size",""][R])},isCursor(){return c.value!==null&&u.value===null},cursorRename(){u.value=c.value},cursorSelect(){console.log("select",s.selected);const R=c.value;R&&(s.selected.has(R.key)?s.selected.delete(R.key):s.selected.add(R.key))},cursorMove(R){const E=O(n.documents);if(E.length===0){c.value=null;return}const U=(W,z)=>(W%z+z)%z,D=c.value!==null?E.indexOf(c.value):-1;c.value=E[U(D+R,E.length+1)]??null;const J=document.getElementById(`file-${c.value.key}`);J&&J.scrollIntoView({block:"center",behavior:"instant"})}}),In(()=>{if(c.value){const R=document.querySelector(`#file-${c.value.key} .name a`);R&&R.focus()}});const p=(R,E)=>{const U=Ft("/api/control",D=>{const J=JSON.parse(D.data);"error"in J?(console.error("Mkdir failed",J.error.message,J.error),u.value=null):(console.log("mkdir",J),o.push(`/${r.value}/${E}/`))});U.onopen=()=>{U.send(JSON.stringify({op:"mkdir",path:`${decodeURIComponent(r.value)}/${E}`}))},R.name=E},h=R=>{m.value=m.value===R?"":R},m=fe(""),b={name:(R,E)=>R.name.localeCompare(E.name,void 0,{numeric:!0,sensitivity:"base"}),modified:(R,E)=>E.mtime-R.mtime,size:(R,E)=>E.size-R.size},O=R=>{const E=b[m.value],U=[...R];return E&&U.sort(E),U},T=_e({get:()=>n.documents.length>0&&n.documents.some(R=>s.selected.has(R.key))&&!k.value,set:R=>{}}),k=_e({get:()=>n.documents.length>0&&n.documents.every(R=>s.selected.has(R.key)),set:R=>{console.log("Setting allSelected",R);for(const E of n.documents)R?s.selected.add(E.key):s.selected.delete(E.key)}}),S=(R,E)=>{console.log("Context menu",R,E)};return(R,E)=>{var U;return n.documents.length||u.value?(se(),ue("table",{key:0,onBlur:E[6]||(E[6]=D=>c.value=null)},[B("thead",null,[B("tr",null,[B("th",uf,[Sn(B("input",{type:"checkbox",tabindex:"-1","onUpdate:modelValue":E[0]||(E[0]=D=>k.value=D),indeterminate:T.value},null,8,af),[[Yc,k.value]])]),B("th",{class:_t(["sortcolumn",{sortactive:m.value==="name"}]),onClick:E[1]||(E[1]=D=>h("name"))}," Name ",2),B("th",{class:_t(["sortcolumn modified right",{sortactive:m.value==="modified"}]),onClick:E[2]||(E[2]=D=>h("modified"))}," Modified ",2),B("th",{class:_t(["sortcolumn size right",{sortactive:m.value==="size"}]),onClick:E[3]||(E[3]=D=>h("size"))}," Size ",2),ff])]),B("tbody",null,[((U=u.value)==null?void 0:U.key)==="new"?(se(),ue("tr",df,[pf,B("td",hf,[Q(ur,{doc:u.value,rename:p,exit:()=>{u.value=null}},null,8,["doc","exit"])]),B("td",gf,Ke(u.value.modified),1),B("td",mf,Ke(u.value.sizedisp),1),_f])):bt("",!0),(se(!0),ue(me,null,qr(O(n.documents),D=>(se(),ue("tr",{key:D.key,id:`file-${D.key}`,class:_t({file:D.type==="file",folder:D.type==="folder",cursor:c.value===D}),onClick:J=>c.value=c.value===D?null:D,onContextmenu:pt(J=>S(J,D),["prevent"])},[B("td",{class:"selection",onClick:pt(J=>c.value=c.value===D?D:null,["stop"])},[B("input",{type:"checkbox",tabindex:"-1",checked:de(s).selected.has(D.key),onChange:J=>J.target.checked?de(s).selected.add(D.key):de(s).selected.delete(D.key)},null,40,bf)],8,yf),B("td",Ef,[u.value===D?(se(),xt(ur,{key:0,doc:D,rename:a,exit:()=>{u.value=null}},null,8,["doc","exit"])):(se(),ue(me,{key:1},[B("a",{href:l(D),tabindex:"-1",onContextmenu:E[4]||(E[4]=pt(()=>{},["stop"])),onClick:E[5]||(E[5]=pt(()=>{},["stop"])),onFocus:pt(J=>c.value=D,["stop"])},Ke(D.name),41,wf),B("button",{onClick:()=>u.value=D},"🖊️",8,xf)],64))]),B("td",Rf,Ke(D.modified),1),B("td",Pf,Ke(D.sizedisp),1),B("td",Of,[B("button",{tabindex:"-1",onClick:pt(J=>{c.value=D,S(J,D)},["stop"])}," ⋮ ",8,Cf)])],42,vf))),128))])],32)):(se(),ue("div",If,"Nothing to see here"))}}});const kf=Ht(Sf,[["__scopeId","data-v-79d60fb2"]]),Af=Ce({__name:"ExplorerView",props:{path:Array},setup(e){const t=e,n=Ze(),s=fe();return In(()=>{n.fileExplorer=s.value}),In(async()=>{const o=new String(Ln.currentRoute.value.path);n.setActualDocument(o.toString())}),(o,r)=>{const i=kf;return se(),xt(i,{ref_key:"fileExplorer",ref:s,key:de(Ln).currentRoute.value.path,path:t.path,documents:de(n).mainDocument},null,8,["path","documents"])}}}),Ln=tf({history:va("/"),routes:[{path:"/:pathMatch(.*)*",name:"explorer",component:Af}]}),Tf=Ce({__name:"App",setup(e){const t=Ze(),n=_e(()=>{const l=decodeURIComponent(Ln.currentRoute.value.path),c=l.split("/").filter(u=>u!=="");return{path:l,pathList:c}});setInterval(t.updateModified,1e3),In(()=>{const l=new rf,c=new lf,u=Ft(Si,l.handleWebSocketMessage),a=Ft(of,c.handleWebSocketMessage);t.wsWatch=u,t.wsUpload=a});const s=fe(null);let o=0,r=null;const i=l=>{if(l.repeat)return;const c=t.fileExplorer.isCursor(),u=l.type==="keyup";if(l.key==="ArrowUp")o=u?0:l.altKey?-10:-1;else if(l.key==="ArrowDown")o=u?0:l.altKey?10:1;else if(!u&&l.key==="f"&&(l.ctrlKey||l.metaKey))s.value.toggleSearchInput();else if(!u&&l.key==="a"&&(l.ctrlKey||l.metaKey))t.fileExplorer.toggleSelectAll();else if(c&&u&&(l.key==="1"||l.key==="2"||l.key==="3"))t.fileExplorer.toggleSortColumn(+l.key);else if(c&&u&&!l.ctrlKey&&(l.key==="F2"||l.key==="r"))t.fileExplorer.cursorRename();else if(c&&l.code==="Space")u&&!l.altKey&&!l.ctrlKey&&t.fileExplorer.cursorSelect();else return;l.preventDefault(),r!==null&&clearInterval(r),r=null,o&&(r=setInterval(()=>{t.fileExplorer.cursorMove(o)},30))};return Qn(()=>{window.addEventListener("keydown",i),window.addEventListener("keyup",i)}),Qs(()=>{window.removeEventListener("keydown",i),window.removeEventListener("keyup",i)}),(l,c)=>{const u=Gu,a=Fu,p=Tu,h=vu;return se(),ue(me,null,[Q(u),B("header",null,[Q(p,{ref_key:"headerMain",ref:s},{default:zs(()=>[Q(a,{path:n.value.pathList},null,8,["path"])]),_:1},512),Q(h,{path:n.value.pathList},null,8,["path"])]),B("main",null,[Q(de(Ii),{path:n.value.pathList},null,8,["path"])])],64)}}});const Mf=Ht(Tf,[["__scopeId","data-v-6650a4c9"]]),ns=su(Mf);ns.config.errorHandler=e=>{console.log(e)};ns.use(iu());ns.use(Ln);ns.mount("#app");export{B as a,ue as c,se as o};