Files
vnt/vnt-web/static/assets/index-BxCqIugQ.js
T

169 lines
199 KiB
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))n(o);new MutationObserver(o=>{for(const l of o)if(l.type==="childList")for(const r of l.addedNodes)r.tagName==="LINK"&&r.rel==="modulepreload"&&n(r)}).observe(document,{childList:!0,subtree:!0});function s(o){const l={};return o.integrity&&(l.integrity=o.integrity),o.referrerPolicy&&(l.referrerPolicy=o.referrerPolicy),o.crossOrigin==="use-credentials"?l.credentials="include":o.crossOrigin==="anonymous"?l.credentials="omit":l.credentials="same-origin",l}function n(o){if(o.ep)return;o.ep=!0;const l=s(o);fetch(o.href,l)}})();function Uo(e){const t=Object.create(null);for(const s of e.split(","))t[s]=1;return s=>s in t}const ke={},vs=[],_t=()=>{},Tr=()=>!1,An=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),$n=e=>e.startsWith("onUpdate:"),Re=Object.assign,Ho=(e,t)=>{const s=e.indexOf(t);s>-1&&e.splice(s,1)},wa=Object.prototype.hasOwnProperty,ve=(e,t)=>wa.call(e,t),J=Array.isArray,bs=e=>nn(e)==="[object Map]",Es=e=>nn(e)==="[object Set]",xl=e=>nn(e)==="[object Date]",le=e=>typeof e=="function",Ce=e=>typeof e=="string",Xe=e=>typeof e=="symbol",be=e=>e!==null&&typeof e=="object",Ar=e=>(be(e)||le(e))&&le(e.then)&&le(e.catch),$r=Object.prototype.toString,nn=e=>$r.call(e),Ca=e=>nn(e).slice(8,-1),Ir=e=>nn(e)==="[object Object]",In=e=>Ce(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,Ds=Uo(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),Rn=e=>{const t=Object.create(null);return(s=>t[s]||(t[s]=e(s)))},Sa=/-\w/g,Ge=Rn(e=>e.replace(Sa,t=>t.slice(1).toUpperCase())),Ea=/\B([A-Z])/g,is=Rn(e=>e.replace(Ea,"-$1").toLowerCase()),Pn=Rn(e=>e.charAt(0).toUpperCase()+e.slice(1)),Xn=Rn(e=>e?`on${Pn(e)}`:""),vt=(e,t)=>!Object.is(e,t),hn=(e,...t)=>{for(let s=0;s<e.length;s++)e[s](...t)},Rr=(e,t,s,n=!1)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:n,value:s})},On=e=>{const t=parseFloat(e);return isNaN(t)?e:t},Ta=e=>{const t=Ce(e)?Number(e):NaN;return isNaN(t)?e:t};let yl;const Mn=()=>yl||(yl=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function Ln(e){if(J(e)){const t={};for(let s=0;s<e.length;s++){const n=e[s],o=Ce(n)?Ra(n):Ln(n);if(o)for(const l in o)t[l]=o[l]}return t}else if(Ce(e)||be(e))return e}const Aa=/;(?![^(]*\))/g,$a=/:([^]+)/,Ia=/\/\*[^]*?\*\//g;function Ra(e){const t={};return e.replace(Ia,"").split(Aa).forEach(s=>{if(s){const n=s.split($a);n.length>1&&(t[n[0].trim()]=n[1].trim())}}),t}function G(e){let t="";if(Ce(e))t=e;else if(J(e))for(let s=0;s<e.length;s++){const n=G(e[s]);n&&(t+=n+" ")}else if(be(e))for(const s in e)e[s]&&(t+=s+" ");return t.trim()}const Pa="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",Oa=Uo(Pa);function Pr(e){return!!e||e===""}function Ma(e,t){if(e.length!==t.length)return!1;let s=!0;for(let n=0;s&&n<e.length;n++)s=Ts(e[n],t[n]);return s}function Ts(e,t){if(e===t)return!0;let s=xl(e),n=xl(t);if(s||n)return s&&n?e.getTime()===t.getTime():!1;if(s=Xe(e),n=Xe(t),s||n)return e===t;if(s=J(e),n=J(t),s||n)return s&&n?Ma(e,t):!1;if(s=be(e),n=be(t),s||n){if(!s||!n)return!1;const o=Object.keys(e).length,l=Object.keys(t).length;if(o!==l)return!1;for(const r in e){const i=e.hasOwnProperty(r),c=t.hasOwnProperty(r);if(i&&!c||!i&&c||!Ts(e[r],t[r]))return!1}}return String(e)===String(t)}function Wo(e,t){return e.findIndex(s=>Ts(s,t))}const Or=e=>!!(e&&e.__v_isRef===!0),V=e=>Ce(e)?e:e==null?"":J(e)||be(e)&&(e.toString===$r||!le(e.toString))?Or(e)?V(e.value):JSON.stringify(e,Mr,2):String(e),Mr=(e,t)=>Or(t)?Mr(e,t.value):bs(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((s,[n,o],l)=>(s[eo(n,l)+" =>"]=o,s),{})}:Es(t)?{[`Set(${t.size})`]:[...t.values()].map(s=>eo(s))}:Xe(t)?eo(t):be(t)&&!J(t)&&!Ir(t)?String(t):t,eo=(e,t="")=>{var s;return Xe(e)?`Symbol(${(s=e.description)!=null?s:t})`:e};let Me;class Lr{constructor(t=!1){this.detached=t,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this._warnOnRun=!0,this.__v_skip=!0,!t&&Me&&(Me.active?(this.parent=Me,this.index=(Me.scopes||(Me.scopes=[])).push(this)-1):(this._active=!1,this._warnOnRun=!1))}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let t,s;if(this.scopes){const n=this.scopes.slice();for(t=0,s=n.length;t<s;t++)n[t].pause()}for(t=0,s=this.effects.length;t<s;t++)this.effects[t].pause()}}resume(){if(this._active&&this._isPaused){this._isPaused=!1;let t,s;if(this.scopes){const o=this.scopes.slice();for(t=0,s=o.length;t<s;t++)o[t].resume()}const n=this.effects.slice();for(t=0,s=n.length;t<s;t++)n[t].resume()}}run(t){if(this._active){const s=Me;try{return Me=this,t()}finally{Me=s}}}on(){++this._on===1&&(this.prevScope=Me,Me=this)}off(){if(this._on>0&&--this._on===0){if(Me===this)Me=this.prevScope;else{let t=Me;for(;t;){if(t.prevScope===this){t.prevScope=this.prevScope;break}t=t.prevScope}}this.prevScope=void 0}}stop(t){if(this._active){this._active=!1;let s,n;for(s=0,n=this.effects.length;s<n;s++)this.effects[s].stop();for(this.effects.length=0,s=0,n=this.cleanups.length;s<n;s++)this.cleanups[s]();if(this.cleanups.length=0,this.scopes){const o=this.scopes.slice();for(s=0,n=o.length;s<n;s++)o[s].stop(!0);this.scopes.length=0}if(!this.detached&&this.parent&&!t){const o=this.parent.scopes.pop();o&&o!==this&&(this.parent.scopes[this.index]=o,o.index=this.index)}this.parent=void 0}}}function Nr(e){return new Lr(e)}function Vr(){return Me}function La(e,t=!1){Me&&Me.cleanups.push(e)}let we;const to=new WeakSet;class jr{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,Me&&(Me.active?Me.effects.push(this):this.flags&=-2)}pause(){this.flags|=64}resume(){this.flags&64&&(this.flags&=-65,to.has(this)&&(to.delete(this),this.trigger()))}notify(){this.flags&2&&!(this.flags&32)||this.flags&8||Br(this)}run(){if(!(this.flags&1))return this.fn();this.flags|=2,kl(this),Fr(this);const t=we,s=lt;we=this,lt=!0;try{return this.fn()}finally{Ur(this),we=t,lt=s,this.flags&=-3}}stop(){if(this.flags&1){for(let t=this.deps;t;t=t.nextDep)qo(t);this.deps=this.depsTail=void 0,kl(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){this.flags&64?to.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){xo(this)&&this.run()}get dirty(){return xo(this)}}let Dr=0,Bs,Fs;function Br(e,t=!1){if(e.flags|=8,t){e.next=Fs,Fs=e;return}e.next=Bs,Bs=e}function Ko(){Dr++}function Go(){if(--Dr>0)return;if(Fs){let t=Fs;for(Fs=void 0;t;){const s=t.next;t.next=void 0,t.flags&=-9,t=s}}let e;for(;Bs;){let t=Bs;for(Bs=void 0;t;){const s=t.next;if(t.next=void 0,t.flags&=-9,t.flags&1)try{t.trigger()}catch(n){e||(e=n)}t=s}}if(e)throw e}function Fr(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function Ur(e){let t,s=e.depsTail,n=s;for(;n;){const o=n.prevDep;n.version===-1?(n===s&&(s=o),qo(n),Na(n)):t=n,n.dep.activeLink=n.prevActiveLink,n.prevActiveLink=void 0,n=o}e.deps=t,e.depsTail=s}function xo(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(Hr(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function Hr(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===qs)||(e.globalVersion=qs,!e.isSSR&&e.flags&128&&(!e.deps&&!e._dirty||!xo(e))))return;e.flags|=2;const t=e.dep,s=we,n=lt;we=e,lt=!0;try{Fr(e);const o=e.fn(e._value);(t.version===0||vt(o,e._value))&&(e.flags|=128,e._value=o,t.version++)}catch(o){throw t.version++,o}finally{we=s,lt=n,Ur(e),e.flags&=-3}}function qo(e,t=!1){const{dep:s,prevSub:n,nextSub:o}=e;if(n&&(n.nextSub=o,e.prevSub=void 0),o&&(o.prevSub=n,e.nextSub=void 0),s.subs===e&&(s.subs=n,!n&&s.computed)){s.computed.flags&=-5;for(let l=s.computed.deps;l;l=l.nextDep)qo(l,!0)}!t&&!--s.sc&&s.map&&s.map.delete(s.key)}function Na(e){const{prevDep:t,nextDep:s}=e;t&&(t.nextDep=s,e.prevDep=void 0),s&&(s.prevDep=t,e.nextDep=void 0)}let lt=!0;const Wr=[];function At(){Wr.push(lt),lt=!1}function $t(){const e=Wr.pop();lt=e===void 0?!0:e}function kl(e){const{cleanup:t}=e;if(e.cleanup=void 0,t){const s=we;we=void 0;try{t()}finally{we=s}}}let qs=0;class Va{constructor(t,s){this.sub=t,this.dep=s,this.version=s.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}}class zo{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,this.__v_skip=!0}track(t){if(!we||!lt||we===this.computed)return;let s=this.activeLink;if(s===void 0||s.sub!==we)s=this.activeLink=new Va(we,this),we.deps?(s.prevDep=we.depsTail,we.depsTail.nextDep=s,we.depsTail=s):we.deps=we.depsTail=s,Kr(s);else if(s.version===-1&&(s.version=this.version,s.nextDep)){const n=s.nextDep;n.prevDep=s.prevDep,s.prevDep&&(s.prevDep.nextDep=n),s.prevDep=we.depsTail,s.nextDep=void 0,we.depsTail.nextDep=s,we.depsTail=s,we.deps===s&&(we.deps=n)}return s}trigger(t){this.version++,qs++,this.notify(t)}notify(t){Ko();try{for(let s=this.subs;s;s=s.prevSub)s.sub.notify()&&s.sub.dep.notify()}finally{Go()}}}function Kr(e){if(e.dep.sc++,e.sub.flags&4){const t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let n=t.deps;n;n=n.nextDep)Kr(n)}const s=e.dep.subs;s!==e&&(e.prevSub=s,s&&(s.nextSub=e)),e.dep.subs=e}}const gn=new WeakMap,ns=Symbol(""),yo=Symbol(""),zs=Symbol("");function Ve(e,t,s){if(lt&&we){let n=gn.get(e);n||gn.set(e,n=new Map);let o=n.get(s);o||(n.set(s,o=new zo),o.map=n,o.key=s),o.track()}}function Ct(e,t,s,n,o,l){const r=gn.get(e);if(!r){qs++;return}const i=c=>{c&&c.trigger()};if(Ko(),t==="clear")r.forEach(i);else{const c=J(e),f=c&&In(s);if(c&&s==="length"){const u=Number(n);r.forEach((d,g)=>{(g==="length"||g===zs||!Xe(g)&&g>=u)&&i(d)})}else switch((s!==void 0||r.has(void 0))&&i(r.get(s)),f&&i(r.get(zs)),t){case"add":c?f&&i(r.get("length")):(i(r.get(ns)),bs(e)&&i(r.get(yo)));break;case"delete":c||(i(r.get(ns)),bs(e)&&i(r.get(yo)));break;case"set":bs(e)&&i(r.get(ns));break}}Go()}function ja(e,t){const s=gn.get(e);return s&&s.get(t)}function fs(e){const t=pe(e);return t===e?t:(Ve(t,"iterate",zs),Ye(e)?t:t.map(rt))}function Nn(e){return Ve(e=pe(e),"iterate",zs),e}function mt(e,t){return It(e)?ys(Et(e)?rt(t):t):rt(t)}const Da={__proto__:null,[Symbol.iterator](){return so(this,Symbol.iterator,e=>mt(this,e))},concat(...e){return fs(this).concat(...e.map(t=>J(t)?fs(t):t))},entries(){return so(this,"entries",e=>(e[1]=mt(this,e[1]),e))},every(e,t){return xt(this,"every",e,t,void 0,arguments)},filter(e,t){return xt(this,"filter",e,t,s=>s.map(n=>mt(this,n)),arguments)},find(e,t){return xt(this,"find",e,t,s=>mt(this,s),arguments)},findIndex(e,t){return xt(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return xt(this,"findLast",e,t,s=>mt(this,s),arguments)},findLastIndex(e,t){return xt(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return xt(this,"forEach",e,t,void 0,arguments)},includes(...e){return no(this,"includes",e)},indexOf(...e){return no(this,"indexOf",e)},join(e){return fs(this).join(e)},lastIndexOf(...e){return no(this,"lastIndexOf",e)},map(e,t){return xt(this,"map",e,t,void 0,arguments)},pop(){return Is(this,"pop")},push(...e){return Is(this,"push",e)},reduce(e,...t){return wl(this,"reduce",e,t)},reduceRight(e,...t){return wl(this,"reduceRight",e,t)},shift(){return Is(this,"shift")},some(e,t){return xt(this,"some",e,t,void 0,arguments)},splice(...e){return Is(this,"splice",e)},toReversed(){return fs(this).toReversed()},toSorted(e){return fs(this).toSorted(e)},toSpliced(...e){return fs(this).toSpliced(...e)},unshift(...e){return Is(this,"unshift",e)},values(){return so(this,"values",e=>mt(this,e))}};function so(e,t,s){const n=Nn(e),o=n[t]();return n!==e&&!Ye(e)&&(o._next=o.next,o.next=()=>{const l=o._next();return l.done||(l.value=s(l.value)),l}),o}const Ba=Array.prototype;function xt(e,t,s,n,o,l){const r=Nn(e),i=r!==e&&!Ye(e),c=r[t];if(c!==Ba[t]){const d=c.apply(e,l);return i?rt(d):d}let f=s;r!==e&&(i?f=function(d,g){return s.call(this,mt(e,d),g,e)}:s.length>2&&(f=function(d,g){return s.call(this,d,g,e)}));const u=c.call(r,f,n);return i&&o?o(u):u}function wl(e,t,s,n){const o=Nn(e),l=o!==e&&!Ye(e);let r=s,i=!1;o!==e&&(l?(i=n.length===0,r=function(f,u,d){return i&&(i=!1,f=mt(e,f)),s.call(this,f,mt(e,u),d,e)}):s.length>3&&(r=function(f,u,d){return s.call(this,f,u,d,e)}));const c=o[t](r,...n);return i?mt(e,c):c}function no(e,t,s){const n=pe(e);Ve(n,"iterate",zs);const o=n[t](...s);return(o===-1||o===!1)&&Vn(s[0])?(s[0]=pe(s[0]),n[t](...s)):o}function Is(e,t,s=[]){At(),Ko();const n=pe(e)[t].apply(e,s);return Go(),$t(),n}const Fa=Uo("__proto__,__v_isRef,__isVue"),Gr=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(Xe));function Ua(e){Xe(e)||(e=String(e));const t=pe(this);return Ve(t,"has",e),t.hasOwnProperty(e)}class qr{constructor(t=!1,s=!1){this._isReadonly=t,this._isShallow=s}get(t,s,n){if(s==="__v_skip")return t.__v_skip;const o=this._isReadonly,l=this._isShallow;if(s==="__v_isReactive")return!o;if(s==="__v_isReadonly")return o;if(s==="__v_isShallow")return l;if(s==="__v_raw")return n===(o?l?Qa:Yr:l?Jr:Zr).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(n)?t:void 0;const r=J(t);if(!o){let c;if(r&&(c=Da[s]))return c;if(s==="hasOwnProperty")return Ua}const i=Reflect.get(t,s,Te(t)?t:n);if((Xe(s)?Gr.has(s):Fa(s))||(o||Ve(t,"get",s),l))return i;if(Te(i)){const c=r&&In(s)?i:i.value;return o&&be(c)?wo(c):c}return be(i)?o?wo(i):Kt(i):i}}class zr extends qr{constructor(t=!1){super(!1,t)}set(t,s,n,o){let l=t[s];const r=J(t)&&In(s);if(!this._isShallow){const f=It(l);if(!Ye(n)&&!It(n)&&(l=pe(l),n=pe(n)),!r&&Te(l)&&!Te(n))return f||(l.value=n),!0}const i=r?Number(s)<t.length:ve(t,s),c=Reflect.set(t,s,n,Te(t)?t:o);return t===pe(o)&&c&&(i?vt(n,l)&&Ct(t,"set",s,n):Ct(t,"add",s,n)),c}deleteProperty(t,s){const n=ve(t,s);t[s];const o=Reflect.deleteProperty(t,s);return o&&n&&Ct(t,"delete",s,void 0),o}has(t,s){const n=Reflect.has(t,s);return(!Xe(s)||!Gr.has(s))&&Ve(t,"has",s),n}ownKeys(t){return Ve(t,"iterate",J(t)?"length":ns),Reflect.ownKeys(t)}}class Ha extends qr{constructor(t=!1){super(!0,t)}set(t,s){return!0}deleteProperty(t,s){return!0}}const Wa=new zr,Ka=new Ha,Ga=new zr(!0);const ko=e=>e,cn=e=>Reflect.getPrototypeOf(e);function qa(e,t,s){return function(...n){const o=this.__v_raw,l=pe(o),r=bs(l),i=e==="entries"||e===Symbol.iterator&&r,c=e==="keys"&&r,f=o[e](...n),u=s?ko:t?ys:rt;return!t&&Ve(l,"iterate",c?yo:ns),Re(Object.create(f),{next(){const{value:d,done:g}=f.next();return g?{value:d,done:g}:{value:i?[u(d[0]),u(d[1])]:u(d),done:g}}})}}function un(e){return function(...t){return e==="delete"?!1:e==="clear"?void 0:this}}function za(e,t){const s={get(o){const l=this.__v_raw,r=pe(l),i=pe(o);e||(vt(o,i)&&Ve(r,"get",o),Ve(r,"get",i));const{has:c}=cn(r),f=t?ko:e?ys:rt;if(c.call(r,o))return f(l.get(o));if(c.call(r,i))return f(l.get(i));l!==r&&l.get(o)},get size(){const o=this.__v_raw;return!e&&Ve(pe(o),"iterate",ns),o.size},has(o){const l=this.__v_raw,r=pe(l),i=pe(o);return e||(vt(o,i)&&Ve(r,"has",o),Ve(r,"has",i)),o===i?l.has(o):l.has(o)||l.has(i)},forEach(o,l){const r=this,i=r.__v_raw,c=pe(i),f=t?ko:e?ys:rt;return!e&&Ve(c,"iterate",ns),i.forEach((u,d)=>o.call(l,f(u),f(d),r))}};return Re(s,e?{add:un("add"),set:un("set"),delete:un("delete"),clear:un("clear")}:{add(o){const l=pe(this),r=cn(l),i=pe(o),c=!t&&!Ye(o)&&!It(o)?i:o;return r.has.call(l,c)||vt(o,c)&&r.has.call(l,o)||vt(i,c)&&r.has.call(l,i)||(l.add(c),Ct(l,"add",c,c)),this},set(o,l){!t&&!Ye(l)&&!It(l)&&(l=pe(l));const r=pe(this),{has:i,get:c}=cn(r);let f=i.call(r,o);f||(o=pe(o),f=i.call(r,o));const u=c.call(r,o);return r.set(o,l),f?vt(l,u)&&Ct(r,"set",o,l):Ct(r,"add",o,l),this},delete(o){const l=pe(this),{has:r,get:i}=cn(l);let c=r.call(l,o);c||(o=pe(o),c=r.call(l,o)),i&&i.call(l,o);const f=l.delete(o);return c&&Ct(l,"delete",o,void 0),f},clear(){const o=pe(this),l=o.size!==0,r=o.clear();return l&&Ct(o,"clear",void 0,void 0),r}}),["keys","values","entries",Symbol.iterator].forEach(o=>{s[o]=qa(o,e,t)}),s}function Zo(e,t){const s=za(e,t);return(n,o,l)=>o==="__v_isReactive"?!e:o==="__v_isReadonly"?e:o==="__v_raw"?n:Reflect.get(ve(s,o)&&o in n?s:n,o,l)}const Za={get:Zo(!1,!1)},Ja={get:Zo(!1,!0)},Ya={get:Zo(!0,!1)};const Zr=new WeakMap,Jr=new WeakMap,Yr=new WeakMap,Qa=new WeakMap;function Xa(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function Kt(e){return It(e)?e:Jo(e,!1,Wa,Za,Zr)}function Qr(e){return Jo(e,!1,Ga,Ja,Jr)}function wo(e){return Jo(e,!0,Ka,Ya,Yr)}function Jo(e,t,s,n,o){if(!be(e)||e.__v_raw&&!(t&&e.__v_isReactive)||e.__v_skip||!Object.isExtensible(e))return e;const l=o.get(e);if(l)return l;const r=Xa(Ca(e));if(r===0)return e;const i=new Proxy(e,r===2?n:s);return o.set(e,i),i}function Et(e){return It(e)?Et(e.__v_raw):!!(e&&e.__v_isReactive)}function It(e){return!!(e&&e.__v_isReadonly)}function Ye(e){return!!(e&&e.__v_isShallow)}function Vn(e){return e?!!e.__v_raw:!1}function pe(e){const t=e&&e.__v_raw;return t?pe(t):e}function Yo(e){return!ve(e,"__v_skip")&&Object.isExtensible(e)&&Rr(e,"__v_skip",!0),e}const rt=e=>be(e)?Kt(e):e,ys=e=>be(e)?wo(e):e;function Te(e){return e?e.__v_isRef===!0:!1}function oe(e){return Xr(e,!1)}function ec(e){return Xr(e,!0)}function Xr(e,t){return Te(e)?e:new tc(e,t)}class tc{constructor(t,s){this.dep=new zo,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=s?t:pe(t),this._value=s?t:rt(t),this.__v_isShallow=s}get value(){return this.dep.track(),this._value}set value(t){const s=this._rawValue,n=this.__v_isShallow||Ye(t)||It(t);t=n?t:pe(t),vt(t,s)&&(this._rawValue=t,this._value=n?t:rt(t),this.dep.trigger())}}function O(e){return Te(e)?e.value:e}const sc={get:(e,t,s)=>t==="__v_raw"?e:O(Reflect.get(e,t,s)),set:(e,t,s,n)=>{const o=e[t];return Te(o)&&!Te(s)?(o.value=s,!0):Reflect.set(e,t,s,n)}};function ei(e){return Et(e)?e:new Proxy(e,sc)}function nc(e){const t=J(e)?new Array(e.length):{};for(const s in e)t[s]=lc(e,s);return t}class oc{constructor(t,s,n){this._object=t,this._defaultValue=n,this.__v_isRef=!0,this._value=void 0,this._key=Xe(s)?s:String(s),this._raw=pe(t);let o=!0,l=t;if(!J(t)||Xe(this._key)||!In(this._key))do o=!Vn(l)||Ye(l);while(o&&(l=l.__v_raw));this._shallow=o}get value(){let t=this._object[this._key];return this._shallow&&(t=O(t)),this._value=t===void 0?this._defaultValue:t}set value(t){if(this._shallow&&Te(this._raw[this._key])){const s=this._object[this._key];if(Te(s)){s.value=t;return}}this._object[this._key]=t}get dep(){return ja(this._raw,this._key)}}function lc(e,t,s){return new oc(e,t,s)}class rc{constructor(t,s,n){this.fn=t,this.setter=s,this._value=void 0,this.dep=new zo(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=qs-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!s,this.isSSR=n}notify(){if(this.flags|=16,!(this.flags&8)&&we!==this)return Br(this,!0),!0}get value(){const t=this.dep.track();return Hr(this),t&&(t.version=this.dep.version),this._value}set value(t){this.setter&&this.setter(t)}}function ic(e,t,s=!1){let n,o;return le(e)?n=e:(n=e.get,o=e.set),new rc(n,o,s)}const fn={},vn=new WeakMap;let Xt;function ac(e,t=!1,s=Xt){if(s){let n=vn.get(s);n||vn.set(s,n=[]),n.push(e)}}function cc(e,t,s=ke){const{immediate:n,deep:o,once:l,scheduler:r,augmentJob:i,call:c}=s,f=k=>o?k:Ye(k)||o===!1||o===0?St(k,1):St(k);let u,d,g,h,C=!1,x=!1;if(Te(e)?(d=()=>e.value,C=Ye(e)):Et(e)?(d=()=>f(e),C=!0):J(e)?(x=!0,C=e.some(k=>Et(k)||Ye(k)),d=()=>e.map(k=>{if(Te(k))return k.value;if(Et(k))return f(k);if(le(k))return c?c(k,2):k()})):le(e)?t?d=c?()=>c(e,2):e:d=()=>{if(g){At();try{g()}finally{$t()}}const k=Xt;Xt=u;try{return c?c(e,3,[h]):e(h)}finally{Xt=k}}:d=_t,t&&o){const k=d,S=o===!0?1/0:o;d=()=>St(k(),S)}const L=Vr(),w=()=>{u.stop(),L&&L.active&&Ho(L.effects,u)};if(l&&t){const k=t;t=(...S)=>{const q=k(...S);return w(),q}}let p=x?new Array(e.length).fill(fn):fn;const b=k=>{if(!(!(u.flags&1)||!u.dirty&&!k))if(t){const S=u.run();if(k||o||C||(x?S.some((q,D)=>vt(q,p[D])):vt(S,p))){g&&g();const q=Xt;Xt=u;try{const D=[S,p===fn?void 0:x&&p[0]===fn?[]:p,h];p=S,c?c(t,3,D):t(...D)}finally{Xt=q}}}else u.run()};return i&&i(b),u=new jr(d),u.scheduler=r?()=>r(b,!1):b,h=k=>ac(k,!1,u),g=u.onStop=()=>{const k=vn.get(u);if(k){if(c)c(k,4);else for(const S of k)S();vn.delete(u)}},t?n?b(!0):p=u.run():r?r(b.bind(null,!0),!0):u.run(),w.pause=u.pause.bind(u),w.resume=u.resume.bind(u),w.stop=w,w}function St(e,t=1/0,s){if(t<=0||!be(e)||e.__v_skip||(s=s||new Map,(s.get(e)||0)>=t))return e;if(s.set(e,t),t--,Te(e))St(e.value,t,s);else if(J(e))for(let n=0;n<e.length;n++)St(e[n],t,s);else if(Es(e)||bs(e))e.forEach(n=>{St(n,t,s)});else if(Ir(e)){for(const n in e)St(e[n],t,s);for(const n of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,n)&&St(e[n],t,s)}return e}function on(e,t,s,n){try{return n?e(...n):e()}catch(o){jn(o,t,s)}}function nt(e,t,s,n){if(le(e)){const o=on(e,t,s,n);return o&&Ar(o)&&o.catch(l=>{jn(l,t,s)}),o}if(J(e)){const o=[];for(let l=0;l<e.length;l++)o.push(nt(e[l],t,s,n));return o}}function jn(e,t,s,n=!0){const o=t?t.vnode:null,{errorHandler:l,throwUnhandledErrorInProduction:r}=t&&t.appContext.config||ke;if(t){let i=t.parent;const c=t.proxy,f=`https://vuejs.org/error-reference/#runtime-${s}`;for(;i;){const u=i.ec;if(u){for(let d=0;d<u.length;d++)if(u[d](e,c,f)===!1)return}i=i.parent}if(l){At(),on(l,null,10,[e,c,f]),$t();return}}uc(e,s,o,n,r)}function uc(e,t,s,n=!0,o=!1){if(o)throw e;console.error(e)}const Ke=[];let ht=-1;const _s=[];let Ft=null,ms=0;const ti=Promise.resolve();let bn=null;function Rt(e){const t=bn||ti;return e?t.then(this?e.bind(this):e):t}function fc(e){let t=ht+1,s=Ke.length;for(;t<s;){const n=t+s>>>1,o=Ke[n],l=Zs(o);l<e||l===e&&o.flags&2?t=n+1:s=n}return t}function Qo(e){if(!(e.flags&1)){const t=Zs(e),s=Ke[Ke.length-1];!s||!(e.flags&2)&&t>=Zs(s)?Ke.push(e):Ke.splice(fc(t),0,e),e.flags|=1,si()}}function si(){bn||(bn=ti.then(oi))}function dc(e){if(!J(e))Ft&&e.id===-1?Ft.splice(ms+1,0,e):e.flags&1||(_s.push(e),e.flags|=1);else for(let t=0;t<e.length;t++)_s.push(e[t]);si()}function Cl(e,t,s=ht+1){for(;s<Ke.length;s++){const n=Ke[s];if(n&&n.flags&2){if(e&&n.id!==e.uid)continue;Ke.splice(s,1),s--,n.flags&4&&(n.flags&=-2),n(),n.flags&4||(n.flags&=-2)}}}function ni(e){if(_s.length){const t=[...new Set(_s)].sort((s,n)=>Zs(s)-Zs(n));if(_s.length=0,Ft){for(let s=0;s<t.length;s++)Ft.push(t[s]);return}for(Ft=t,ms=0;ms<Ft.length;ms++){const s=Ft[ms];s.flags&4&&(s.flags&=-2),s.flags&8||s(),s.flags&=-2}Ft=null,ms=0}}const Zs=e=>e.id==null?e.flags&2?-1:1/0:e.id;function oi(e){try{for(ht=0;ht<Ke.length;ht++){const t=Ke[ht];t&&!(t.flags&8)&&(t.flags&4&&(t.flags&=-2),on(t,t.i,t.i?15:14),t.flags&4||(t.flags&=-2))}}finally{for(;ht<Ke.length;ht++){const t=Ke[ht];t&&(t.flags&=-2)}ht=-1,Ke.length=0,ni(),bn=null,(Ke.length||_s.length)&&oi()}}let Ne=null,li=null;function _n(e){const t=Ne;return Ne=e,li=e&&e.type.__scopeId||null,t}function Ae(e,t=Ne,s){if(!t||e._n)return e;const n=(...o)=>{n._d&&wn(-1);const l=_n(t),r=Tt.length;let i;try{i=e(...o)}finally{for(let c=Tt.length;c>r;c--)ll();_n(l),n._d&&wn(1)}return i};return n._n=!0,n._c=!0,n._d=!0,n}function me(e,t){if(Ne===null)return e;const s=Kn(Ne),n=e.dirs||(e.dirs=[]);for(let o=0;o<t.length;o++){let[l,r,i,c=ke]=t[o];l&&(le(l)&&(l={mounted:l,updated:l}),l.deep&&St(r),n.push({dir:l,instance:s,value:r,oldValue:void 0,arg:i,modifiers:c}))}return e}function qt(e,t,s,n){const o=e.dirs,l=t&&t.dirs;for(let r=0;r<o.length;r++){const i=o[r];l&&(i.oldValue=l[r].value);let c=i.dir[n];c&&(At(),nt(c,s,8,[e.el,i,e,t]),$t())}}function Us(e,t){if(De){let s=De.provides;const n=De.parent&&De.parent.provides;n===s&&(s=De.provides=Object.create(n)),s[e]=t}}function Qe(e,t,s=!1){const n=ln();if(n||os){let o=os?os._context.provides:n?n.parent==null||n.ce?n.vnode.appContext&&n.vnode.appContext.provides:n.parent.provides:void 0;if(o&&e in o)return o[e];if(arguments.length>1)return s&&le(t)?t.call(n&&n.proxy):t}}function pc(){return!!(ln()||os)}const hc=Symbol.for("v-scx"),mc=()=>Qe(hc);function Be(e,t,s){return ri(e,t,s)}function ri(e,t,s=ke){const{immediate:n,deep:o,flush:l,once:r}=s,i=Re({},s),c=t&&n||!t&&l!=="post";let f;if(en){if(l==="sync"){const h=mc();f=h.__watcherHandles||(h.__watcherHandles=[])}else if(!c){const h=()=>{};return h.stop=_t,h.resume=_t,h.pause=_t,h}}const u=De;i.call=(h,C,x)=>nt(h,u,C,x);let d=!1;l==="post"?i.scheduler=h=>{He(h,u&&u.suspense)}:l!=="sync"&&(d=!0,i.scheduler=(h,C)=>{C?h():Qo(h)}),i.augmentJob=h=>{t&&(h.flags|=4),d&&(h.flags|=2,u&&(h.id=u.uid,h.i=u))};const g=cc(e,t,i);return en&&(f?f.push(g):c&&g()),g}function gc(e,t,s){const n=this.proxy,o=Ce(e)?e.includes(".")?ii(n,e):()=>n[e]:e.bind(n,n);let l;le(t)?l=t:(l=t.handler,s=t);const r=rn(this),i=ri(o,l.bind(n),s);return r(),i}function ii(e,t){const s=t.split(".");return()=>{let n=e;for(let o=0;o<s.length&&n;o++)n=n[s[o]];return n}}const jt=new WeakMap,ai=Symbol("_vte"),Dn=e=>e.__isTeleport,es=e=>e&&(e.disabled||e.disabled===""),vc=e=>e&&(e.defer||e.defer===""),Sl=e=>typeof SVGElement<"u"&&e instanceof SVGElement,El=e=>typeof MathMLElement=="function"&&e instanceof MathMLElement,Co=(e,t)=>{const s=e&&e.to;return Ce(s)?t?t(s):null:s},bc={name:"Teleport",__isTeleport:!0,process(e,t,s,n,o,l,r,i,c,f){const{mc:u,pc:d,pbc:g,o:{insert:h,querySelector:C,createText:x,createComment:L,parentNode:w}}=f,p=es(t.props);let{dynamicChildren:b}=t;const k=(D,U,M)=>{D.shapeFlag&16&&u(D.children,U,M,o,l,r,i,c)},S=(D=t)=>{const U=es(D.props),M=D.target=Co(D.props,C),z=So(M,D,x,h);M&&(r!=="svg"&&Sl(M)?r="svg":r!=="mathml"&&El(M)&&(r="mathml"),o&&o.isCE&&(o.ce._teleportTargets||(o.ce._teleportTargets=new Set)).add(M),U||(k(D,M,z),Ls(D,!1)))},q=D=>{const U=()=>{if(jt.get(D)===U){if(jt.delete(D),es(D.props)){const M=w(D.el)||s;k(D,M,D.anchor),Ls(D,!0)}S(D)}};jt.set(D,U),He(U,l)};if(e==null){const D=t.el=x(""),U=t.anchor=x("");if(h(D,s,n),h(U,s,n),vc(t.props)||l&&l.pendingBranch){q(t);return}p&&(k(t,s,U),Ls(t,!0)),S()}else{t.el=e.el;const D=t.anchor=e.anchor,U=jt.get(e);if(U){U.flags|=8,jt.delete(e),q(t);return}t.targetStart=e.targetStart;const M=t.target=e.target,z=t.targetAnchor=e.targetAnchor,ne=es(e.props),B=ne?s:M,Z=ne?D:z;if(r==="svg"||Sl(M)?r="svg":(r==="mathml"||El(M))&&(r="mathml"),b?(g(e.dynamicChildren,b,B,o,l,r,i),ol(e,t,!0)):c||d(e,t,B,Z,o,l,r,i,!1),p)ne?t.props&&e.props&&t.props.to!==e.props.to&&(t.props.to=e.props.to):dn(t,s,D,f,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){const R=Co(t.props,C);R&&(t.target=R,dn(t,R,null,f,0))}else ne&&dn(t,M,z,f,1);Ls(t,p)}},remove(e,t,s,{um:n,o:{remove:o}},l){const{shapeFlag:r,children:i,anchor:c,targetStart:f,targetAnchor:u,target:d,props:g}=e,h=es(g),C=l||!h,x=jt.get(e);if(x&&(x.flags|=8,jt.delete(e)),d&&(o(f),o(u)),l&&o(c),!x&&(h||d)&&r&16)for(let L=0;L<i.length;L++){const w=i[L];n(w,t,s,C,!!w.dynamicChildren)}},move:dn,hydrate:_c};function dn(e,t,s,{o:{insert:n},m:o},l=2){l===0&&n(e.targetAnchor,t,s);const{el:r,anchor:i,shapeFlag:c,children:f,props:u}=e,d=l===2;if(d&&n(r,t,s),!jt.has(e)&&(!d||es(u))&&c&16)for(let g=0;g<f.length;g++)o(f[g],t,s,2);d&&n(i,t,s)}function _c(e,t,s,n,o,l,{o:{nextSibling:r,parentNode:i,querySelector:c,insert:f,createText:u}},d){function g(L,w){let p=w;for(;p;){if(p&&p.nodeType===8){if(p.data==="teleport start anchor")t.targetStart=p;else if(p.data==="teleport anchor"){t.targetAnchor=p,L._lpa=t.targetAnchor&&r(t.targetAnchor);break}}p=r(p)}}function h(L,w){w.anchor=d(r(L),w,i(L),s,n,o,l)}const C=t.target=Co(t.props,c),x=es(t.props);if(C){const L=C._lpa||C.firstChild;t.shapeFlag&16&&(x?(h(e,t),g(C,L),t.targetAnchor||So(C,t,u,f,i(e)===C?e:null)):(t.anchor=r(e),g(C,L),t.targetAnchor||So(C,t,u,f),d(L&&r(L),t,C,s,n,o,l))),Ls(t,x)}else x&&t.shapeFlag&16&&(h(e,t),t.targetStart=e,t.targetAnchor=r(e));return t.anchor&&r(t.anchor)}const Xo=bc;function Ls(e,t){const s=e.ctx;if(s&&s.ut){let n,o;for(t?(n=e.el,o=e.anchor):(n=e.targetStart,o=e.targetAnchor);n&&n!==o;)n.nodeType===1&&n.setAttribute("data-v-owner",s.uid),n=n.nextSibling;s.ut()}}function So(e,t,s,n,o=null){const l=t.targetStart=s(""),r=t.targetAnchor=s("");return l[ai]=r,e&&(n(l,e,o),n(r,e,o)),r}const st=Symbol("_leaveCb"),Rs=Symbol("_enterCb");function ci(){const e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return Ot(()=>{e.isMounted=!0}),tl(()=>{e.isUnmounting=!0}),e}const tt=[Function,Array],ui={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:tt,onEnter:tt,onAfterEnter:tt,onEnterCancelled:tt,onBeforeLeave:tt,onLeave:tt,onAfterLeave:tt,onLeaveCancelled:tt,onBeforeAppear:tt,onAppear:tt,onAfterAppear:tt,onAppearCancelled:tt},fi=e=>{const t=e.subTree;return t.component?fi(t.component):t},xc={name:"BaseTransition",props:ui,setup(e,{slots:t}){const s=ln(),n=ci();return()=>{const o=t.default&&el(t.default(),!0),l=o&&o.length?di(o):s.subTree?fe():void 0;if(!l)return;const r=pe(e),{mode:i}=r;if(n.isLeaving)return oo(l);const c=xn(l);if(!c)return oo(l);let f=Js(c,r,n,s,d=>f=d);c.type!==je&&rs(c,f);let u=s.subTree&&xn(s.subTree);if(u&&u.type!==je&&!ts(u,c)&&fi(s).type!==je){let d=Js(u,r,n,s);if(rs(u,d),i==="out-in"&&c.type!==je)return n.isLeaving=!0,d.afterLeave=()=>{n.isLeaving=!1,s.job.flags&8||s.update(),delete d.afterLeave,u=void 0},oo(l);i==="in-out"&&c.type!==je?d.delayLeave=(g,h,C)=>{const x=pi(n,u);x[String(u.key)]=u,g[st]=()=>{h(),g[st]=void 0,delete f.delayedLeave,u=void 0},f.delayedLeave=()=>{C(),delete f.delayedLeave,u=void 0}}:u=void 0}else u&&(u=void 0);return l}}};function di(e){let t=e[0];if(e.length>1){for(const s of e)if(s.type!==je){t=s;break}}return t}const yc=xc;function pi(e,t){const{leavingVNodes:s}=e;let n=s.get(t.type);return n||(n=Object.create(null),s.set(t.type,n)),n}function Js(e,t,s,n,o){const{appear:l,mode:r,persisted:i=!1,onBeforeEnter:c,onEnter:f,onAfterEnter:u,onEnterCancelled:d,onBeforeLeave:g,onLeave:h,onAfterLeave:C,onLeaveCancelled:x,onBeforeAppear:L,onAppear:w,onAfterAppear:p,onAppearCancelled:b}=t,k=String(e.key),S=pi(s,e),q=(M,z)=>{M&&nt(M,n,9,z)},D=(M,z)=>{const ne=z[1];q(M,z),J(M)?M.every(B=>B.length<=1)&&ne():M.length<=1&&ne()},U={mode:r,persisted:i,beforeEnter(M){let z=c;if(!s.isMounted)if(l)z=L||c;else return;M[st]&&M[st](!0);const ne=S[k];ne&&ts(e,ne)&&ne.el[st]&&ne.el[st](),q(z,[M])},enter(M){if(S[k]===e)return;let z=f,ne=u,B=d;if(!s.isMounted)if(l)z=w||f,ne=p||u,B=b||d;else return;let Z=!1;M[Rs]=ee=>{Z||(Z=!0,ee?q(B,[M]):q(ne,[M]),U.delayedLeave&&U.delayedLeave(),M[Rs]=void 0)};const R=M[Rs].bind(null,!1);z?D(z,[M,R]):R()},leave(M,z){const ne=String(e.key);if(M[Rs]&&M[Rs](!0),s.isUnmounting)return z();q(g,[M]);let B=!1;M[st]=R=>{B||(B=!0,z(),R?q(x,[M]):q(C,[M]),M[st]=void 0,S[ne]===e&&delete S[ne])};const Z=M[st].bind(null,!1);S[ne]=e,h?D(h,[M,Z]):Z()},clone(M){const z=Js(M,t,s,n,o);return o&&o(z),z}};return U}function oo(e){if(Bn(e))return e=Wt(e),e.children=null,e}function xn(e){if(!Bn(e))return Dn(e.type)&&e.children?di(e.children):e;if(e.component)return e.component.subTree;const{shapeFlag:t,children:s}=e;if(s){if(t&16)return s[0];if(t&32&&le(s.default))return s.default()}}function rs(e,t){if(e.shapeFlag&6&&e.component){e.transition=t;const s=e.component.subTree;rs(Dn(s.type)&&xn(s)||s,t)}else e.shapeFlag&128?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function el(e,t=!1,s){let n=[],o=0;for(let l=0;l<e.length;l++){let r=e[l];const i=s==null?r.key:String(s)+String(r.key!=null?r.key:l);r.type===ie?(r.patchFlag&128&&o++,n=n.concat(el(r.children,t,i))):(t||r.type!==je)&&n.push(i!=null?Wt(r,{key:i}):r)}if(o>1)for(let l=0;l<n.length;l++)n[l].patchFlag=-2;return n}function hi(e,t){return le(e)?Re({name:e.name},t,{setup:e}):e}function mi(e){e.ids=[e.ids[0]+e.ids[2]+++"-",0,0]}function Tl(e,t){let s;return!!((s=Object.getOwnPropertyDescriptor(e,t))&&!s.configurable)}const yn=new WeakMap;function Hs(e,t,s,n,o=!1){if(J(e)){e.forEach((x,L)=>Hs(x,t&&(J(t)?t[L]:t),s,n,o));return}if(xs(n)&&!o){n.shapeFlag&512&&n.type.__asyncResolved&&n.component.subTree.component&&Hs(e,t,s,n.component.subTree);return}const l=n.shapeFlag&4?Kn(n.component):n.el,r=o?null:l,{i,r:c}=e,f=t&&t.r,u=i.refs===ke?i.refs={}:i.refs,d=i.setupState,g=pe(d),h=d===ke?Tr:x=>Tl(u,x)?!1:ve(g,x),C=(x,L)=>!(L&&Tl(u,L));if(f!=null&&f!==c){if(Al(t),Ce(f))u[f]=null,h(f)&&(d[f]=null);else if(Te(f)){const x=t;C(f,x.k)&&(f.value=null),x.k&&(u[x.k]=null)}}if(le(c))on(c,i,12,[r,u]);else{const x=Ce(c),L=Te(c);if(x||L){const w=()=>{if(e.f){const p=x?h(c)?d[c]:u[c]:C()||!e.k?c.value:u[e.k];if(o)J(p)&&Ho(p,l);else if(J(p))p.includes(l)||p.push(l);else if(x)u[c]=[l],h(c)&&(d[c]=u[c]);else{const b=[l];C(c,e.k)&&(c.value=b),e.k&&(u[e.k]=b)}}else x?(u[c]=r,h(c)&&(d[c]=r)):L&&(C(c,e.k)&&(c.value=r),e.k&&(u[e.k]=r))};if(r){const p=()=>{w(),yn.delete(e)};p.id=-1,yn.set(e,p),He(p,s)}else Al(e),w()}}}function Al(e){const t=yn.get(e);t&&(t.flags|=8,yn.delete(e))}Mn().requestIdleCallback;Mn().cancelIdleCallback;const xs=e=>!!e.type.__asyncLoader,Bn=e=>e.type.__isKeepAlive;function kc(e,t){gi(e,"a",t)}function wc(e,t){gi(e,"da",t)}function gi(e,t,s=De){const n=e.__wdc||(e.__wdc=()=>{let o=s;for(;o;){if(o.isDeactivated)return;o=o.parent}return e()});if(Fn(t,n,s),s){let o=s.parent;for(;o&&o.parent;)Bn(o.parent.vnode)&&Cc(n,t,s,o),o=o.parent}}function Cc(e,t,s,n){const o=Fn(t,e,n,!0);As(()=>{Ho(n[t],o)},s)}function Fn(e,t,s=De,n=!1){if(s){const o=s[e]||(s[e]=[]),l=t.__weh||(t.__weh=(...r)=>{At();const i=rn(s),c=nt(t,s,e,r);return i(),$t(),c});return n?o.unshift(l):o.push(l),l}}const Pt=e=>(t,s=De)=>{(!en||e==="sp")&&Fn(e,(...n)=>t(...n),s)},Sc=Pt("bm"),Ot=Pt("m"),Ec=Pt("bu"),vi=Pt("u"),tl=Pt("bum"),As=Pt("um"),Tc=Pt("sp"),Ac=Pt("rtg"),$c=Pt("rtc");function Ic(e,t=De){Fn("ec",e,t)}const bi="components";function Un(e,t){return xi(bi,e,!0,t)||e}const _i=Symbol.for("v-ndc");function Rc(e){return Ce(e)?xi(bi,e,!1)||e:e||_i}function xi(e,t,s=!0,n=!1){const o=Ne||De;if(o){const l=o.type;{const i=hu(l,!1);if(i&&(i===t||i===Ge(t)||i===Pn(Ge(t))))return l}const r=$l(o[e]||l[e],t)||$l(o.appContext[e],t);return!r&&n?l:r}}function $l(e,t){return e&&(e[t]||e[Ge(t)]||e[Pn(Ge(t))])}function Ee(e,t,s,n){let o;const l=s,r=J(e);if(r||Ce(e)){const i=r&&Et(e);let c=!1,f=!1;i&&(c=!Ye(e),f=It(e),e=Nn(e)),o=new Array(e.length);for(let u=0,d=e.length;u<d;u++)o[u]=t(c?f?ys(rt(e[u])):rt(e[u]):e[u],u,void 0,l)}else if(typeof e=="number"){o=new Array(e);for(let i=0;i<e;i++)o[i]=t(i+1,i,void 0,l)}else if(be(e))if(e[Symbol.iterator])o=Array.from(e,(i,c)=>t(i,c,void 0,l));else{const i=Object.keys(e);o=new Array(i.length);for(let c=0,f=i.length;c<f;c++){const u=i[c];o[c]=t(e[u],u,c,l)}}else o=[];return o}function lo(e,t,s,n,o,l){if(s==null&&(s={}),Ne.ce||Ne.parent&&xs(Ne.parent)&&Ne.parent.ce){const f=s,u=Object.keys(f).length>0;return t!=="default"&&(f.name=t),y(),Ie(ie,null,[ue("slot",f,n)],u?-2:64)}let r=e[t];r&&r._c&&(r._d=!1);const i=Tt.length;y();let c;try{const f=r&&yi(r(s)),u=s.key||l||f&&f.key;c=Ie(ie,{key:(u&&!Xe(u)?u:`_${t}`)+(!f&&n?"_fb":"")},f||(n?n():[]),f&&e._===1?64:-2)}catch(f){for(let u=Tt.length;u>i;u--)ll();throw f}finally{r&&r._c&&(r._d=!0)}return c.scopeId&&(c.slotScopeIds=[c.scopeId+"-s"]),c}function yi(e){return e.some(t=>Qs(t)?!(t.type===je||t.type===ie&&!yi(t.children)):!0)?e:null}const Eo=e=>e?Bi(e)?Kn(e):Eo(e.parent):null,Ws=Re(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=>Eo(e.parent),$root:e=>Eo(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>wi(e),$forceUpdate:e=>e.f||(e.f=()=>{Qo(e.update)}),$nextTick:e=>e.n||(e.n=Rt.bind(e.proxy)),$watch:e=>gc.bind(e)}),ro=(e,t)=>e!==ke&&!e.__isScriptSetup&&ve(e,t),Pc={get({_:e},t){if(t==="__v_skip")return!0;const{ctx:s,setupState:n,data:o,props:l,accessCache:r,type:i,appContext:c}=e;if(t[0]!=="$"){const g=r[t];if(g!==void 0)switch(g){case 1:return n[t];case 2:return o[t];case 4:return s[t];case 3:return l[t]}else{if(ro(n,t))return r[t]=1,n[t];if(o!==ke&&ve(o,t))return r[t]=2,o[t];if(ve(l,t))return r[t]=3,l[t];if(s!==ke&&ve(s,t))return r[t]=4,s[t];To&&(r[t]=0)}}const f=Ws[t];let u,d;if(f)return t==="$attrs"&&Ve(e.attrs,"get",""),f(e);if((u=i.__cssModules)&&(u=u[t]))return u;if(s!==ke&&ve(s,t))return r[t]=4,s[t];if(d=c.config.globalProperties,ve(d,t))return d[t]},set({_:e},t,s){const{data:n,setupState:o,ctx:l}=e;return ro(o,t)?(o[t]=s,!0):n!==ke&&ve(n,t)?(n[t]=s,!0):ve(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(l[t]=s,!0)},has({_:{data:e,setupState:t,accessCache:s,ctx:n,appContext:o,props:l,type:r}},i){let c;return!!(s[i]||e!==ke&&i[0]!=="$"&&ve(e,i)||ro(t,i)||ve(l,i)||ve(n,i)||ve(Ws,i)||ve(o.config.globalProperties,i)||(c=r.__cssModules)&&c[i])},defineProperty(e,t,s){return s.get!=null?e._.accessCache[t]=0:ve(s,"value")&&this.set(e,t,s.value,null),Reflect.defineProperty(e,t,s)}};function Il(e){return J(e)?e.reduce((t,s)=>(t[s]=null,t),{}):e}let To=!0;function Oc(e){const t=wi(e),s=e.proxy,n=e.ctx;To=!1,t.beforeCreate&&Rl(t.beforeCreate,e,"bc");const{data:o,computed:l,methods:r,watch:i,provide:c,inject:f,created:u,beforeMount:d,mounted:g,beforeUpdate:h,updated:C,activated:x,deactivated:L,beforeDestroy:w,beforeUnmount:p,destroyed:b,unmounted:k,render:S,renderTracked:q,renderTriggered:D,errorCaptured:U,serverPrefetch:M,expose:z,inheritAttrs:ne,components:B,directives:Z,filters:R}=t;if(f&&Mc(f,n,null),r)for(const te in r){const re=r[te];le(re)&&(n[te]=re.bind(s))}if(o){const te=o.call(s,s);be(te)&&(e.data=Kt(te))}if(To=!0,l)for(const te in l){const re=l[te],Fe=le(re)?re.bind(s,s):le(re.get)?re.get.bind(s,s):_t,qe=!le(re)&&le(re.set)?re.set.bind(s):_t,at=_e({get:Fe,set:qe});Object.defineProperty(n,te,{enumerable:!0,configurable:!0,get:()=>at.value,set:ze=>at.value=ze})}if(i)for(const te in i)ki(i[te],n,s,te);if(c){const te=le(c)?c.call(s):c;Reflect.ownKeys(te).forEach(re=>{Us(re,te[re])})}u&&Rl(u,e,"c");function ce(te,re){J(re)?re.forEach(Fe=>te(Fe.bind(s))):re&&te(re.bind(s))}if(ce(Sc,d),ce(Ot,g),ce(Ec,h),ce(vi,C),ce(kc,x),ce(wc,L),ce(Ic,U),ce($c,q),ce(Ac,D),ce(tl,p),ce(As,k),ce(Tc,M),J(z))if(z.length){const te=e.exposed||(e.exposed={});z.forEach(re=>{Object.defineProperty(te,re,{get:()=>s[re],set:Fe=>s[re]=Fe,enumerable:!0})})}else e.exposed||(e.exposed={});S&&e.render===_t&&(e.render=S),ne!=null&&(e.inheritAttrs=ne),B&&(e.components=B),Z&&(e.directives=Z),M&&mi(e)}function Mc(e,t,s=_t){J(e)&&(e=Ao(e));for(const n in e){const o=e[n];let l;be(o)?"default"in o?l=Qe(o.from||n,o.default,!0):l=Qe(o.from||n):l=Qe(o),Te(l)?Object.defineProperty(t,n,{enumerable:!0,configurable:!0,get:()=>l.value,set:r=>l.value=r}):t[n]=l}}function Rl(e,t,s){nt(J(e)?e.map(n=>n.bind(t.proxy)):e.bind(t.proxy),t,s)}function ki(e,t,s,n){let o=n.includes(".")?ii(s,n):()=>s[n];if(Ce(e)){const l=t[e];le(l)&&Be(o,l)}else if(le(e))Be(o,e.bind(s));else if(be(e))if(J(e))e.forEach(l=>ki(l,t,s,n));else{const l=le(e.handler)?e.handler.bind(s):t[e.handler];le(l)&&Be(o,l,e)}}function wi(e){const t=e.type,{mixins:s,extends:n}=t,{mixins:o,optionsCache:l,config:{optionMergeStrategies:r}}=e.appContext,i=l.get(t);let c;return i?c=i:!o.length&&!s&&!n?c=t:(c={},o.length&&o.forEach(f=>kn(c,f,r,!0)),kn(c,t,r)),be(t)&&l.set(t,c),c}function kn(e,t,s,n=!1){const{mixins:o,extends:l}=t;l&&kn(e,l,s,!0),o&&o.forEach(r=>kn(e,r,s,!0));for(const r in t)if(!(n&&r==="expose")){const i=Lc[r]||s&&s[r];e[r]=i?i(e[r],t[r]):t[r]}return e}const Lc={data:Pl,props:Ol,emits:Ol,methods:Ns,computed:Ns,beforeCreate:Ue,created:Ue,beforeMount:Ue,mounted:Ue,beforeUpdate:Ue,updated:Ue,beforeDestroy:Ue,beforeUnmount:Ue,destroyed:Ue,unmounted:Ue,activated:Ue,deactivated:Ue,errorCaptured:Ue,serverPrefetch:Ue,components:Ns,directives:Ns,watch:Vc,provide:Pl,inject:Nc};function Pl(e,t){return t?e?function(){return Re(le(e)?e.call(this,this):e,le(t)?t.call(this,this):t)}:t:e}function Nc(e,t){return Ns(Ao(e),Ao(t))}function Ao(e){if(J(e)){const t={};for(let s=0;s<e.length;s++)t[e[s]]=e[s];return t}return e}function Ue(e,t){return e?[...new Set([].concat(e,t))]:t}function Ns(e,t){return e?Re(Object.create(null),e,t):t}function Ol(e,t){return e?J(e)&&J(t)?[...new Set([...e,...t])]:Re(Object.create(null),Il(e),Il(t??{})):t}function Vc(e,t){if(!e)return t;if(!t)return e;const s=Re(Object.create(null),e);for(const n in t)s[n]=Ue(e[n],t[n]);return s}function Ci(){return{app:null,config:{isNativeTag:Tr,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 jc=0;function Dc(e,t){return function(n,o=null){le(n)||(n=Re({},n)),o!=null&&!be(o)&&(o=null);const l=Ci(),r=new WeakSet,i=[];let c=!1;const f=l.app={_uid:jc++,_component:n,_props:o,_container:null,_context:l,_instance:null,version:gu,get config(){return l.config},set config(u){},use(u,...d){return r.has(u)||(u&&le(u.install)?(r.add(u),u.install(f,...d)):le(u)&&(r.add(u),u(f,...d))),f},mixin(u){return l.mixins.includes(u)||l.mixins.push(u),f},component(u,d){return d?(l.components[u]=d,f):l.components[u]},directive(u,d){return d?(l.directives[u]=d,f):l.directives[u]},mount(u,d,g){if(!c){const h=f._ceVNode||ue(n,o);return h.appContext=l,g===!0?g="svg":g===!1&&(g=void 0),e(h,u,g),c=!0,f._container=u,u.__vue_app__=f,Kn(h.component)}},onUnmount(u){i.push(u)},unmount(){c&&(nt(i,f._instance,16),e(null,f._container),delete f._container.__vue_app__)},provide(u,d){return l.provides[u]=d,f},runWithContext(u){const d=os;os=f;try{return u()}finally{os=d}}};return f}}let os=null;const Bc=(e,t)=>t==="modelValue"||t==="model-value"?e.modelModifiers:e[`${t}Modifiers`]||e[`${Ge(t)}Modifiers`]||e[`${is(t)}Modifiers`];function Fc(e,t,...s){if(e.isUnmounted)return;const n=e.vnode.props||ke;let o=s;const l=t.startsWith("update:"),r=l&&Bc(n,t.slice(7));r&&(r.trim&&(o=s.map(u=>Ce(u)?u.trim():u)),r.number&&(o=s.map(On)));let i,c=n[i=Xn(t)]||n[i=Xn(Ge(t))];!c&&l&&(c=n[i=Xn(is(t))]),c&&nt(c,e,6,o);const f=n[i+"Once"];if(f){if(!e.emitted)e.emitted={};else if(e.emitted[i])return;e.emitted[i]=!0,nt(f,e,6,o)}}const Uc=new WeakMap;function Si(e,t,s=!1){const n=s?Uc:t.emitsCache,o=n.get(e);if(o!==void 0)return o;const l=e.emits;let r={},i=!1;if(!le(e)){const c=f=>{const u=Si(f,t,!0);u&&(i=!0,Re(r,u))};!s&&t.mixins.length&&t.mixins.forEach(c),e.extends&&c(e.extends),e.mixins&&e.mixins.forEach(c)}return!l&&!i?(be(e)&&n.set(e,null),null):(J(l)?l.forEach(c=>r[c]=null):Re(r,l),be(e)&&n.set(e,r),r)}function Hn(e,t){return!e||!An(t)?!1:(t=t.slice(2),t=t==="Once"?t:t.replace(/Once$/,""),ve(e,t[0].toLowerCase()+t.slice(1))||ve(e,is(t))||ve(e,t))}function Ml(e){const{type:t,vnode:s,proxy:n,withProxy:o,propsOptions:[l],slots:r,attrs:i,emit:c,render:f,renderCache:u,props:d,data:g,setupState:h,ctx:C,inheritAttrs:x}=e,L=_n(e);let w,p;try{if(s.shapeFlag&4){const k=o||n,S=k;w=gt(f.call(S,k,u,d,h,g,C)),p=i}else{const k=t;w=gt(k.length>1?k(d,{attrs:i,slots:r,emit:c}):k(d,null)),p=t.props?i:Hc(i)}}catch(k){Tt.length=0,jn(k,e,1),w=ue(je)}let b=w;if(p&&x!==!1){const k=Object.keys(p),{shapeFlag:S}=b;k.length&&S&7&&(l&&k.some($n)&&(p=Wc(p,l)),b=Wt(b,p,!1,!0))}if(s.dirs&&(b=Wt(b,null,!1,!0),b.dirs=b.dirs?b.dirs.concat(s.dirs):s.dirs),s.transition){const k=Dn(b.type)&&xn(b)||b;rs(k,s.transition)}return w=b,_n(L),w}const Hc=e=>{let t;for(const s in e)(s==="class"||s==="style"||An(s))&&((t||(t={}))[s]=e[s]);return t},Wc=(e,t)=>{const s={};for(const n in e)(!$n(n)||!(n.slice(9)in t))&&(s[n]=e[n]);return s};function Kc(e,t,s){const{props:n,children:o,component:l}=e,{props:r,children:i,patchFlag:c}=t,f=l.emitsOptions;if(t.dirs||t.transition)return!0;if(s&&c>=0){if(c&1024)return!0;if(c&16)return n?Ll(n,r,f):!!r;if(c&8){const u=t.dynamicProps;for(let d=0;d<u.length;d++){const g=u[d];if(Ei(r,n,g)&&!Hn(f,g))return!0}}}else return(o||i)&&(!i||!i.$stable)?!0:n===r?!1:n?r?Ll(n,r,f):!0:!!r;return!1}function Ll(e,t,s){const n=Object.keys(t);if(n.length!==Object.keys(e).length)return!0;for(let o=0;o<n.length;o++){const l=n[o];if(Ei(t,e,l)&&!Hn(s,l))return!0}return!1}function Ei(e,t,s){const n=e[s],o=t[s];return s==="style"&&be(n)&&be(o)?!Ts(n,o):n!==o}function Gc({vnode:e,parent:t,suspense:s},n){for(;t;){const o=t.subTree;if(o.suspense&&o.suspense.activeBranch===e&&(o.suspense.vnode.el=o.el=n,e=o),o===e)(e=t.vnode).el=n,t=t.parent;else break}s&&s.activeBranch===e&&(s.vnode.el=n)}const Ti={},Ai=()=>Object.create(Ti),$i=e=>Object.getPrototypeOf(e)===Ti;function qc(e,t,s,n=!1){const o={},l=Ai();e.propsDefaults=Object.create(null),Ii(e,t,o,l);for(const r in e.propsOptions[0])r in o||(o[r]=void 0);s?e.props=n?o:Qr(o):e.type.props?e.props=o:e.props=l,e.attrs=l}function zc(e,t,s,n){const{props:o,attrs:l,vnode:{patchFlag:r}}=e,i=pe(o),[c]=e.propsOptions;let f=!1;if((n||r>0)&&!(r&16)){if(r&8){const u=e.vnode.dynamicProps;for(let d=0;d<u.length;d++){let g=u[d];if(Hn(e.emitsOptions,g))continue;const h=t[g];if(c)if(ve(l,g))h!==l[g]&&(l[g]=h,f=!0);else{const C=Ge(g);o[C]=$o(c,i,C,h,e,!1)}else h!==l[g]&&(l[g]=h,f=!0)}}}else{Ii(e,t,o,l)&&(f=!0);let u;for(const d in i)(!t||!ve(t,d)&&((u=is(d))===d||!ve(t,u)))&&(c?s&&(s[d]!==void 0||s[u]!==void 0)&&(o[d]=$o(c,i,d,void 0,e,!0)):delete o[d]);if(l!==i)for(const d in l)(!t||!ve(t,d))&&(delete l[d],f=!0)}f&&Ct(e.attrs,"set","")}function Ii(e,t,s,n){const[o,l]=e.propsOptions;let r=!1,i;if(t)for(let c in t){if(Ds(c))continue;const f=t[c];let u;o&&ve(o,u=Ge(c))?!l||!l.includes(u)?s[u]=f:(i||(i={}))[u]=f:Hn(e.emitsOptions,c)||(!(c in n)||f!==n[c])&&(n[c]=f,r=!0)}if(l){const c=pe(s),f=i||ke;for(let u=0;u<l.length;u++){const d=l[u];s[d]=$o(o,c,d,f[d],e,!ve(f,d))}}return r}function $o(e,t,s,n,o,l){const r=e[s];if(r!=null){const i=ve(r,"default");if(i&&n===void 0){const c=r.default;if(r.type!==Function&&!r.skipFactory&&le(c)){const{propsDefaults:f}=o;if(s in f)n=f[s];else{const u=rn(o);n=f[s]=c.call(null,t),u()}}else n=c;o.ce&&o.ce._setProp(s,n)}r[0]&&(l&&!i?n=!1:r[1]&&(n===""||n===is(s))&&(n=!0))}return n}const Zc=new WeakMap;function Ri(e,t,s=!1){const n=s?Zc:t.propsCache,o=n.get(e);if(o)return o;const l=e.props,r={},i=[];let c=!1;if(!le(e)){const u=d=>{c=!0;const[g,h]=Ri(d,t,!0);Re(r,g),h&&i.push(...h)};!s&&t.mixins.length&&t.mixins.forEach(u),e.extends&&u(e.extends),e.mixins&&e.mixins.forEach(u)}if(!l&&!c)return be(e)&&n.set(e,vs),vs;if(J(l))for(let u=0;u<l.length;u++){const d=Ge(l[u]);Nl(d)&&(r[d]=ke)}else if(l)for(const u in l){const d=Ge(u);if(Nl(d)){const g=l[u],h=r[d]=J(g)||le(g)?{type:g}:Re({},g),C=h.type;let x=!1,L=!0;if(J(C))for(let w=0;w<C.length;++w){const p=C[w],b=le(p)&&p.name;if(b==="Boolean"){x=!0;break}else b==="String"&&(L=!1)}else x=le(C)&&C.name==="Boolean";h[0]=x,h[1]=L,(x||ve(h,"default"))&&i.push(d)}}const f=[r,i];return be(e)&&n.set(e,f),f}function Nl(e){return e[0]!=="$"&&!Ds(e)}const sl=e=>e==="_"||e==="_ctx"||e==="$stable",nl=e=>J(e)?e.map(gt):[gt(e)],Jc=(e,t,s)=>{if(t._n)return t;const n=Ae((...o)=>nl(t(...o)),s);return n._c=!1,n},Pi=(e,t,s)=>{const n=e._ctx;for(const o in e){if(sl(o))continue;const l=e[o];if(le(l))t[o]=Jc(o,l,n);else if(l!=null){const r=nl(l);t[o]=()=>r}}},Oi=(e,t)=>{const s=nl(t);e.slots.default=()=>s},Mi=(e,t,s)=>{for(const n in t)(s||!sl(n))&&(e[n]=t[n])},Yc=(e,t,s)=>{const n=e.slots=Ai();if(e.vnode.shapeFlag&32){const o=t._;o?(Mi(n,t,s),s&&Rr(n,"_",o,!0)):Pi(t,n)}else t&&Oi(e,t)},Qc=(e,t,s)=>{const{vnode:n,slots:o}=e;let l=!0,r=ke;if(n.shapeFlag&32){const i=t._;i?s&&i===1?l=!1:Mi(o,t,s):(l=!t.$stable,Pi(t,o)),r=t}else t&&(Oi(e,t),r={default:1});if(l)for(const i in o)!sl(i)&&r[i]==null&&delete o[i]},He=nu;function Xc(e){return eu(e)}function eu(e,t){const s=Mn();s.__VUE__=!0;const{insert:n,remove:o,patchProp:l,createElement:r,createText:i,createComment:c,setText:f,setElementText:u,parentNode:d,nextSibling:g,setScopeId:h=_t,insertStaticContent:C}=e,x=(m,v,_,A=null,I=null,T=null,F=void 0,j=null,N=!!v.dynamicChildren)=>{if(m===v)return;m&&!ts(m,v)&&(A=$(m),ze(m,I,T,!0),m=null),v.patchFlag===-2&&(N=!1,v.dynamicChildren=null);const{type:P,ref:X,shapeFlag:W}=v;switch(P){case Wn:L(m,v,_,A);break;case je:w(m,v,_,A);break;case ao:m==null&&p(v,_,A,F);break;case ie:B(m,v,_,A,I,T,F,j,N);break;default:W&1?S(m,v,_,A,I,T,F,j,N):W&6?Z(m,v,_,A,I,T,F,j,N):(W&64||W&128)&&P.process(m,v,_,A,I,T,F,j,N,Y)}X!=null&&I?Hs(X,m&&m.ref,T,v||m,!v):X==null&&m&&m.ref!=null&&Hs(m.ref,null,T,m,!0)},L=(m,v,_,A)=>{if(m==null)n(v.el=i(v.children),_,A);else{const I=v.el=m.el;v.children!==m.children&&f(I,v.children)}},w=(m,v,_,A)=>{m==null?n(v.el=c(v.children||""),_,A):v.el=m.el},p=(m,v,_,A)=>{[m.el,m.anchor]=C(m.children,v,_,A,m.el,m.anchor)},b=({el:m,anchor:v},_,A)=>{let I;for(;m&&m!==v;)I=g(m),n(m,_,A),m=I;n(v,_,A)},k=({el:m,anchor:v})=>{let _;for(;m&&m!==v;)_=g(m),o(m),m=_;o(v)},S=(m,v,_,A,I,T,F,j,N)=>{if(v.type==="svg"?F="svg":v.type==="math"&&(F="mathml"),m==null)q(v,_,A,I,T,F,j,N);else{const P=m.el&&m.el._isVueCE?m.el:null;try{P&&P._beginPatch(),M(m,v,I,T,F,j,N)}finally{P&&P._endPatch()}}},q=(m,v,_,A,I,T,F,j)=>{let N,P;const{props:X,shapeFlag:W,transition:Q,dirs:se}=m;if(N=m.el=r(m.type,T,X&&X.is,X),W&8?u(N,m.children):W&16&&U(m.children,N,null,A,I,io(m,T),F,j),se&&qt(m,null,A,"created"),D(N,m,m.scopeId,F,A),X){for(const ye in X)ye!=="value"&&!Ds(ye)&&l(N,ye,null,X[ye],T,A);"value"in X&&l(N,"value",null,X.value,T),(P=X.onVnodeBeforeMount)&&dt(P,A,m)}se&&qt(m,null,A,"beforeMount");const he=tu(I,Q);he&&Q.beforeEnter(N),n(N,v,_),((P=X&&X.onVnodeMounted)||he||se)&&He(()=>{P&&dt(P,A,m),he&&Q.enter(N),se&&qt(m,null,A,"mounted")},I)},D=(m,v,_,A,I)=>{if(_&&h(m,_),A)for(let T=0;T<A.length;T++)h(m,A[T]);if(I){let T=I.subTree;if(v===T||Vi(T.type)&&(T.ssContent===v||T.ssFallback===v)){const F=I.vnode;D(m,F,F.scopeId,F.slotScopeIds,I.parent)}}},U=(m,v,_,A,I,T,F,j,N=0)=>{for(let P=N;P<m.length;P++){const X=m[P]=j?wt(m[P]):gt(m[P]);x(null,X,v,_,A,I,T,F,j)}},M=(m,v,_,A,I,T,F)=>{const j=v.el=m.el;let{patchFlag:N,dynamicChildren:P,dirs:X}=v;N|=m.patchFlag&16;const W=m.props||ke,Q=v.props||ke;let se;if(_&&zt(_,!1),(se=Q.onVnodeBeforeUpdate)&&dt(se,_,v,m),X&&qt(v,m,_,"beforeUpdate"),_&&zt(_,!0),P&&(!m.dynamicChildren||m.dynamicChildren.length!==P.length)&&(N=0,F=!1,P=null),(W.innerHTML&&Q.innerHTML==null||W.textContent&&Q.textContent==null)&&u(j,""),P?z(m.dynamicChildren,P,j,_,A,io(v,I),T):F||re(m,v,j,null,_,A,io(v,I),T,!1),N>0){if(N&16)ne(j,W,Q,_,I);else if(N&2&&W.class!==Q.class&&l(j,"class",null,Q.class,I),N&4&&l(j,"style",W.style,Q.style,I),N&8){const he=v.dynamicProps;for(let ye=0;ye<he.length;ye++){const xe=he[ye],$e=W[xe],Le=Q[xe];(Le!==$e||xe==="value")&&l(j,xe,$e,Le,I,_)}}N&1&&m.children!==v.children&&u(j,v.children)}else!F&&P==null&&ne(j,W,Q,_,I);((se=Q.onVnodeUpdated)||X)&&He(()=>{se&&dt(se,_,v,m),X&&qt(v,m,_,"updated")},A)},z=(m,v,_,A,I,T,F)=>{for(let j=0;j<v.length;j++){const N=m[j],P=v[j],X=N.el&&(N.type===ie||!ts(N,P)||N.shapeFlag&198)?d(N.el):_;x(N,P,X,null,A,I,T,F,!0)}},ne=(m,v,_,A,I)=>{if(v!==_){if(v!==ke)for(const T in v)!Ds(T)&&!(T in _)&&l(m,T,v[T],null,I,A);for(const T in _){if(Ds(T))continue;const F=_[T],j=v[T];F!==j&&T!=="value"&&l(m,T,j,F,I,A)}"value"in _&&l(m,"value",v.value,_.value,I)}},B=(m,v,_,A,I,T,F,j,N)=>{const P=v.el=m?m.el:i(""),X=v.anchor=m?m.anchor:i("");let{patchFlag:W,dynamicChildren:Q,slotScopeIds:se}=v;se&&(j=j?j.concat(se):se),m==null?(n(P,_,A),n(X,_,A),U(v.children||[],_,X,I,T,F,j,N)):W>0&&W&64&&Q&&m.dynamicChildren&&m.dynamicChildren.length===Q.length?(z(m.dynamicChildren,Q,_,I,T,F,j),(v.key!=null||I&&v===I.subTree)&&ol(m,v,!0)):re(m,v,_,X,I,T,F,j,N)},Z=(m,v,_,A,I,T,F,j,N)=>{v.slotScopeIds=j,m==null?v.shapeFlag&512?I.ctx.activate(v,_,A,F,N):R(v,_,A,I,T,F,N):ee(m,v,N)},R=(m,v,_,A,I,T,F)=>{const j=m.component=cu(m,A,I);if(Bn(m)&&(j.ctx.renderer=Y),uu(j,!1,F),j.asyncDep){if(I&&I.registerDep(j,ce,F),!m.el){const N=j.subTree=ue(je);w(null,N,v,_),m.placeholder=N.el}}else ce(j,m,v,_,I,T,F)},ee=(m,v,_)=>{const A=v.component=m.component;if(Kc(m,v,_))if(A.asyncDep&&!A.asyncResolved){te(A,v,_);return}else A.next=v,A.update();else v.el=m.el,A.vnode=v},ce=(m,v,_,A,I,T,F)=>{const j=()=>{if(m.isMounted){let{next:W,bu:Q,u:se,parent:he,vnode:ye}=m;{const ut=Li(m);if(ut){W&&(W.el=ye.el,te(m,W,F)),ut.asyncDep.then(()=>{He(()=>{m.isUnmounted||P()},I)});return}}let xe=W,$e;zt(m,!1),W?(W.el=ye.el,te(m,W,F)):W=ye,Q&&hn(Q),($e=W.props&&W.props.onVnodeBeforeUpdate)&&dt($e,he,W,ye),zt(m,!0);const Le=Ml(m),ct=m.subTree;m.subTree=Le,x(ct,Le,d(ct.el),$(ct),m,I,T),W.el=Le.el,xe===null&&Gc(m,Le.el),se&&He(se,I),($e=W.props&&W.props.onVnodeUpdated)&&He(()=>dt($e,he,W,ye),I)}else{let W;const{el:Q,props:se}=v,{bm:he,m:ye,parent:xe,root:$e,type:Le}=m,ct=xs(v);zt(m,!1),he&&hn(he),!ct&&(W=se&&se.onVnodeBeforeMount)&&dt(W,xe,v),zt(m,!0);{$e.ce&&$e.ce._hasShadowRoot()&&$e.ce._injectChildStyle(Le,m.parent?m.parent.type:void 0);const ut=m.subTree=Ml(m);x(null,ut,_,A,m,I,T),v.el=ut.el}if(ye&&He(ye,I),!ct&&(W=se&&se.onVnodeMounted)){const ut=v;He(()=>dt(W,xe,ut),I)}(v.shapeFlag&256||xe&&xs(xe.vnode)&&xe.vnode.shapeFlag&256)&&m.a&&He(m.a,I),m.isMounted=!0,v=_=A=null}};m.scope.on();const N=m.effect=new jr(j);m.scope.off();const P=m.update=N.run.bind(N),X=m.job=N.runIfDirty.bind(N);X.i=m,X.id=m.uid,N.scheduler=()=>Qo(X),zt(m,!0),P()},te=(m,v,_)=>{v.component=m;const A=m.vnode.props;m.vnode=v,m.next=null,zc(m,v.props,A,_),Qc(m,v.children,_),At(),Cl(m),$t()},re=(m,v,_,A,I,T,F,j,N=!1)=>{const P=m&&m.children,X=m?m.shapeFlag:0,W=v.children,{patchFlag:Q,shapeFlag:se}=v;if(Q>0){if(Q&128){qe(P,W,_,A,I,T,F,j,N);return}else if(Q&256){Fe(P,W,_,A,I,T,F,j,N);return}}se&8?(X&16&&et(P,I,T),W!==P&&u(_,W)):X&16?se&16?qe(P,W,_,A,I,T,F,j,N):et(P,I,T,!0):(X&8&&u(_,""),se&16&&U(W,_,A,I,T,F,j,N))},Fe=(m,v,_,A,I,T,F,j,N)=>{m=m||vs,v=v||vs;const P=m.length,X=v.length,W=Math.min(P,X);let Q;for(Q=0;Q<W;Q++){const se=v[Q]=N?wt(v[Q]):gt(v[Q]);x(m[Q],se,_,null,I,T,F,j,N)}P>X?et(m,I,T,!0,!1,W):U(v,_,A,I,T,F,j,N,W)},qe=(m,v,_,A,I,T,F,j,N)=>{let P=0;const X=v.length;let W=m.length-1,Q=X-1;for(;P<=W&&P<=Q;){const se=m[P],he=v[P]=N?wt(v[P]):gt(v[P]);if(ts(se,he))x(se,he,_,null,I,T,F,j,N);else break;P++}for(;P<=W&&P<=Q;){const se=m[W],he=v[Q]=N?wt(v[Q]):gt(v[Q]);if(ts(se,he))x(se,he,_,null,I,T,F,j,N);else break;W--,Q--}if(P>W){if(P<=Q){const se=Q+1,he=se<X?v[se].el:A;for(;P<=Q;)x(null,v[P]=N?wt(v[P]):gt(v[P]),_,he,I,T,F,j,N),P++}}else if(P>Q)for(;P<=W;)ze(m[P],I,T,!0),P++;else{const se=P,he=P,ye=new Map;for(P=he;P<=Q;P++){const Ze=v[P]=N?wt(v[P]):gt(v[P]);Ze.key!=null&&ye.set(Ze.key,P)}let xe,$e=0;const Le=Q-he+1;let ct=!1,ut=0;const $s=new Array(Le);for(P=0;P<Le;P++)$s[P]=0;for(P=se;P<=W;P++){const Ze=m[P];if($e>=Le){ze(Ze,I,T,!0);continue}let ft;if(Ze.key!=null)ft=ye.get(Ze.key);else for(xe=he;xe<=Q;xe++)if($s[xe-he]===0&&ts(Ze,v[xe])){ft=xe;break}ft===void 0?ze(Ze,I,T,!0):($s[ft-he]=P+1,ft>=ut?ut=ft:ct=!0,x(Ze,v[ft],_,null,I,T,F,j,N),$e++)}const vl=ct?su($s):vs;for(xe=vl.length-1,P=Le-1;P>=0;P--){const Ze=he+P,ft=v[Ze],bl=v[Ze+1],_l=Ze+1<X?bl.el||Ni(bl):A;$s[P]===0?x(null,ft,_,_l,I,T,F,j,N):ct&&(xe<0||P!==vl[xe]?at(ft,_,_l,2):xe--)}}},at=(m,v,_,A,I=null)=>{const{el:T,type:F,transition:j,children:N,shapeFlag:P}=m;if(P&6){at(m.component.subTree,v,_,A);return}if(P&128){m.suspense.move(v,_,A);return}if(P&64){F.move(m,v,_,Y);return}if(F===ie){n(T,v,_);for(let W=0;W<N.length;W++)at(N[W],v,_,A);n(m.anchor,v,_);return}if(F===ao){b(m,v,_);return}if(A!==2&&P&1&&j)if(A===0)j.persisted&&!T[st]?n(T,v,_):(j.beforeEnter(T),n(T,v,_),He(()=>j.enter(T),I));else{const{leave:W,delayLeave:Q,afterLeave:se}=j,he=()=>{m.ctx.isUnmounted?o(T):n(T,v,_)},ye=()=>{const xe=T._isLeaving||!!T[st];T._isLeaving&&T[st](!0),j.persisted&&!xe?he():W(T,()=>{he(),se&&se()})};Q?Q(T,he,ye):ye()}else n(T,v,_)},ze=(m,v,_,A=!1,I=!1)=>{const{type:T,props:F,ref:j,children:N,dynamicChildren:P,shapeFlag:X,patchFlag:W,dirs:Q,cacheIndex:se,memo:he}=m;if(W===-2&&(I=!1),j!=null&&(At(),Hs(j,null,_,m,!0),$t()),se!=null&&(v.renderCache[se]=void 0),X&256){v.ctx.deactivate(m);return}const ye=X&1&&Q,xe=!xs(m);let $e;if(xe&&($e=F&&F.onVnodeBeforeUnmount)&&dt($e,v,m),X&6)Gt(m.component,_,A);else{if(X&128){m.suspense.unmount(_,A);return}ye&&qt(m,null,v,"beforeUnmount"),X&64?m.type.remove(m,v,_,Y,A):P&&!P.hasOnce&&(T!==ie||W>0&&W&64)?et(P,v,_,!1,!0):(T===ie&&W&384||!I&&X&16)&&et(N,v,_),A&&cs(m)}const Le=he!=null&&se==null;(xe&&($e=F&&F.onVnodeUnmounted)||ye||Le)&&He(()=>{$e&&dt($e,v,m),ye&&qt(m,null,v,"unmounted"),Le&&(m.el=null)},_)},cs=m=>{const{type:v,el:_,anchor:A,transition:I}=m;if(v===ie){us(_,A);return}if(v===ao){k(m);return}const T=()=>{o(_),I&&!I.persisted&&I.afterLeave&&I.afterLeave()};if(m.shapeFlag&1&&I&&!I.persisted){const{leave:F,delayLeave:j}=I,N=()=>F(_,T);j?j(m.el,T,N):N()}else T()},us=(m,v)=>{let _;for(;m!==v;)_=g(m),o(m),m=_;o(v)},Gt=(m,v,_)=>{const{bum:A,scope:I,job:T,subTree:F,um:j,m:N,a:P}=m;Vl(N),Vl(P),A&&hn(A),I.stop(),T&&(T.flags|=8,ze(F,m,v,_)),j&&He(j,v),He(()=>{m.isUnmounted=!0},v)},et=(m,v,_,A=!1,I=!1,T=0)=>{for(let F=T;F<m.length;F++)ze(m[F],v,_,A,I)},$=m=>{if(m.shapeFlag&6)return $(m.component.subTree);if(m.shapeFlag&128)return m.suspense.next();const v=g(m.anchor||m.el),_=v&&v[ai];return _?g(_):v};let K=!1;const H=(m,v,_)=>{let A;m==null?v._vnode&&(ze(v._vnode,null,null,!0),A=v._vnode.component):x(v._vnode||null,m,v,null,null,null,_),v._vnode=m,K||(K=!0,Cl(A),ni(),K=!1)},Y={p:x,um:ze,m:at,r:cs,mt:R,mc:U,pc:re,pbc:z,n:$,o:e};return{render:H,hydrate:void 0,createApp:Dc(H)}}function io({type:e,props:t},s){return s==="svg"&&e==="foreignObject"||s==="mathml"&&e==="annotation-xml"&&t&&t.encoding&&t.encoding.includes("html")?void 0:s}function zt({effect:e,job:t},s){s?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function tu(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function ol(e,t,s=!1){const n=e.children,o=t.children;if(J(n)&&J(o))for(let l=0;l<n.length;l++){const r=n[l];let i=o[l];i.shapeFlag&1&&!i.dynamicChildren&&((i.patchFlag<=0||i.patchFlag===32)&&(i=o[l]=wt(o[l]),i.el=r.el),!s&&i.patchFlag!==-2&&ol(r,i)),i.type===Wn&&(i.patchFlag===-1&&(i=o[l]=wt(i)),i.el=r.el),i.type===je&&!i.el&&(i.el=r.el)}}function su(e){const t=e.slice(),s=[0];let n,o,l,r,i;const c=e.length;for(n=0;n<c;n++){const f=e[n];if(f!==0){if(o=s[s.length-1],e[o]<f){t[n]=o,s.push(n);continue}for(l=0,r=s.length-1;l<r;)i=l+r>>1,e[s[i]]<f?l=i+1:r=i;f<e[s[l]]&&(l>0&&(t[n]=s[l-1]),s[l]=n)}}for(l=s.length,r=s[l-1];l-- >0;)s[l]=r,r=t[r];return s}function Li(e){const t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:Li(t)}function Vl(e){if(e)for(let t=0;t<e.length;t++)e[t].flags|=8}function Ni(e){if(e.placeholder)return e.placeholder;const t=e.component;return t?Ni(t.subTree):null}const Vi=e=>e.__isSuspense;function nu(e,t){t&&t.pendingBranch?J(e)?t.effects.push(...e):t.effects.push(e):dc(e)}const ie=Symbol.for("v-fgt"),Wn=Symbol.for("v-txt"),je=Symbol.for("v-cmt"),ao=Symbol.for("v-stc"),Tt=[];let Je=null;function y(e=!1){Tt.push(Je=e?null:[])}function ll(){Tt.pop(),Je=Tt[Tt.length-1]||null}let Ys=1;function wn(e,t=!1){Ys+=e,e<0&&Je&&t&&(Je.hasOnce=!0)}function ji(e){return e.dynamicChildren=Ys>0?Je||vs:null,ll(),Ys>0&&Je&&Je.push(e),e}function E(e,t,s,n,o,l){return ji(a(e,t,s,n,o,l,!0))}function Ie(e,t,s,n,o){return ji(ue(e,t,s,n,o,!0))}function Qs(e){return e?e.__v_isVNode===!0:!1}function ts(e,t){return e.type===t.type&&e.key===t.key}const Di=({key:e})=>e??null,mn=({ref:e,ref_key:t,ref_for:s})=>(typeof e=="number"&&(e=""+e),e!=null?Ce(e)||Te(e)||le(e)?{i:Ne,r:e,k:t,f:!!s}:e:null);function a(e,t=null,s=null,n=0,o=null,l=e===ie?0:1,r=!1,i=!1){const c={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&Di(t),ref:t&&mn(t),scopeId:li,slotScopeIds:null,children:s,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:l,patchFlag:n,dynamicProps:o,dynamicChildren:null,appContext:null,ctx:Ne};return i?(Cn(c,s),l&128&&e.normalize(c)):s&&(c.shapeFlag|=Ce(s)?8:16),Ys>0&&!r&&Je&&(c.patchFlag>0||l&6)&&c.patchFlag!==32&&Je.push(c),c}const ue=ou;function ou(e,t=null,s=null,n=0,o=null,l=!1){if((!e||e===_i)&&(e=je),Qs(e)){const i=Wt(e,t,!0);return s&&Cn(i,s),Ys>0&&!l&&Je&&(i.shapeFlag&6?Je[Je.indexOf(e)]=i:Je.push(i)),i.patchFlag=-2,i}if(mu(e)&&(e=e.__vccOpts),t){t=lu(t);let{class:i,style:c}=t;i&&!Ce(i)&&(t.class=G(i)),be(c)&&(Vn(c)&&!J(c)&&(c=Re({},c)),t.style=Ln(c))}const r=Ce(e)?1:Vi(e)?128:Dn(e)?64:be(e)?4:le(e)?2:0;return a(e,t,s,n,o,r,l,!0)}function lu(e){return e?Vn(e)||$i(e)?Re({},e):e:null}function Wt(e,t,s=!1,n=!1){const{props:o,ref:l,patchFlag:r,children:i,transition:c}=e,f=t?ru(o||{},t):o,u={__v_isVNode:!0,__v_skip:!0,type:e.type,props:f,key:f&&Di(f),ref:t&&t.ref?s&&l?J(l)?l.concat(mn(t)):[l,mn(t)]:mn(t):l,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:i,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==ie?r===-1?16:r|16:r,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:c,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&Wt(e.ssContent),ssFallback:e.ssFallback&&Wt(e.ssFallback),placeholder:e.placeholder,el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return c&&n&&rs(u,c.clone(u)),u}function ae(e=" ",t=0){return ue(Wn,null,e,t)}function fe(e="",t=!1){return t?(y(),Ie(je,null,e)):ue(je,null,e)}function gt(e){return e==null||typeof e=="boolean"?ue(je):J(e)?ue(ie,null,e.slice()):Qs(e)?wt(e):ue(Wn,null,String(e))}function wt(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:Wt(e)}function Cn(e,t){let s=0;const{shapeFlag:n}=e;if(t==null)t=null;else if(J(t))s=16;else if(typeof t=="object")if(n&65){const o=t.default;o&&(o._c&&(o._d=!1),Cn(e,o()),o._c&&(o._d=!0));return}else{s=32;const o=t._;!o&&!$i(t)?t._ctx=Ne:o===3&&Ne&&(Ne.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else if(le(t)){if(n&65){Cn(e,{default:t});return}t={default:t,_ctx:Ne},s=32}else t=String(t),n&64?(s=16,t=[ae(t)]):s=8;e.children=t,e.shapeFlag|=s}function ru(...e){const t={};for(let s=0;s<e.length;s++){const n=e[s];for(const o in n)if(o==="class")t.class!==n.class&&(t.class=G([t.class,n.class]));else if(o==="style")t.style=Ln([t.style,n.style]);else if(An(o)){const l=t[o],r=n[o];r&&l!==r&&!(J(l)&&l.includes(r))?t[o]=l?[].concat(l,r):r:r==null&&l==null&&!$n(o)&&(t[o]=r)}else o!==""&&(t[o]=n[o])}return t}function dt(e,t,s,n=null){nt(e,t,7,[s,n])}const iu=Ci();let au=0;function cu(e,t,s){const n=e.type,o=(t?t.appContext:e.appContext)||iu,l={uid:au++,vnode:e,type:n,parent:t,appContext:o,root:null,next:null,subTree:null,effect:null,update:null,job:null,scope:new Lr(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(o.provides),ids:t?t.ids:["",0,0],accessCache:null,renderCache:[],components:null,directives:null,propsOptions:Ri(n,o),emitsOptions:Si(n,o),emit:null,emitted:null,propsDefaults:ke,inheritAttrs:n.inheritAttrs,ctx:ke,data:ke,props:ke,attrs:ke,slots:ke,refs:ke,setupState:ke,setupContext:null,suspense:s,suspenseId:s?s.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 l.ctx={_:l},l.root=t?t.root:l,l.emit=Fc.bind(null,l),e.ce&&e.ce(l),l}let De=null;const ln=()=>De||Ne;let Sn,Xs;{const e=Mn(),t=(s,n)=>{let o;return(o=e[s])||(o=e[s]=[]),o.push(n),l=>{o.length>1?o.forEach(r=>r(l)):o[0](l)}};Sn=t("__VUE_INSTANCE_SETTERS__",s=>De=s),Xs=t("__VUE_SSR_SETTERS__",s=>en=s)}const rn=e=>{const t=De;return Sn(e),e.scope.on(),()=>{e.scope.off(),Sn(t)}},jl=()=>{De&&De.scope.off(),Sn(null)};function Bi(e){return e.vnode.shapeFlag&4}let en=!1;function uu(e,t=!1,s=!1){t&&Xs(t);const{props:n,children:o}=e.vnode,l=Bi(e);qc(e,n,l,t),Yc(e,o,s||t);const r=l?fu(e,t):void 0;return t&&Xs(!1),r}function fu(e,t){const s=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,Pc);const{setup:n}=s;if(n){At();const o=e.setupContext=n.length>1?pu(e):null,l=rn(e),r=on(n,e,0,[e.props,o]),i=Ar(r);if($t(),l(),(i||e.sp)&&!xs(e)&&mi(e),i){if(r.then(jl,jl),t)return r.then(c=>{Xs(!0);try{Dl(e,c,t)}finally{Xs(!1)}}).catch(c=>{jn(c,e,0)});e.asyncDep=r}else Dl(e,r)}else Fi(e)}function Dl(e,t,s){le(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:be(t)&&(e.setupState=ei(t)),Fi(e)}function Fi(e,t,s){const n=e.type;e.render||(e.render=n.render||_t);{const o=rn(e);At();try{Oc(e)}finally{$t(),o()}}}const du={get(e,t){return Ve(e,"get",""),e[t]}};function pu(e){const t=s=>{e.exposed=s||{}};return{attrs:new Proxy(e.attrs,du),slots:e.slots,emit:e.emit,expose:t}}function Kn(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(ei(Yo(e.exposed)),{get(t,s){if(s in t)return t[s];if(s in Ws)return Ws[s](e)},has(t,s){return s in t||s in Ws}})):e.proxy}function hu(e,t=!0){return le(e)?e.displayName||e.name:e.name||t&&e.__name}function mu(e){return le(e)&&"__vccOpts"in e}const _e=(e,t)=>ic(e,t,en);function rl(e,t,s){try{wn(-1);const n=arguments.length;return n===2?be(t)&&!J(t)?Qs(t)?ue(e,null,[t]):ue(e,t):ue(e,null,t):(n>3?s=Array.prototype.slice.call(arguments,2):n===3&&Qs(s)&&(s=[s]),ue(e,t,s))}finally{wn(1)}}const gu="3.5.41";let Io;const Bl=typeof window<"u"&&window.trustedTypes;if(Bl)try{Io=Bl.createPolicy("vue",{createHTML:e=>e})}catch{}const Ui=Io?e=>Io.createHTML(e):e=>e,vu="http://www.w3.org/2000/svg",bu="http://www.w3.org/1998/Math/MathML",kt=typeof document<"u"?document:null,Fl=kt&&kt.createElement("template"),_u={insert:(e,t,s)=>{t.insertBefore(e,s||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,s,n)=>{const o=t==="svg"?kt.createElementNS(vu,e):t==="mathml"?kt.createElementNS(bu,e):s?kt.createElement(e,{is:s}):kt.createElement(e);return e==="select"&&n&&n.multiple!=null&&o.setAttribute("multiple",n.multiple),o},createText:e=>kt.createTextNode(e),createComment:e=>kt.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>kt.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,s,n,o,l){const r=s?s.previousSibling:t.lastChild;if(o&&(o===l||o.nextSibling))for(;t.insertBefore(o.cloneNode(!0),s),!(o===l||!(o=o.nextSibling)););else{Fl.innerHTML=Ui(n==="svg"?`<svg>${e}</svg>`:n==="mathml"?`<math>${e}</math>`:e);const i=Fl.content;if(n==="svg"||n==="mathml"){const c=i.firstChild;for(;c.firstChild;)i.appendChild(c.firstChild);i.removeChild(c)}t.insertBefore(i,s)}return[r?r.nextSibling:t.firstChild,s?s.previousSibling:t.lastChild]}},Lt="transition",Ps="animation",ks=Symbol("_vtc"),Hi={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},Wi=Re({},ui,Hi),xu=e=>(e.displayName="Transition",e.props=Wi,e),Ro=xu((e,{slots:t})=>rl(yc,Ki(e),t)),Zt=(e,t=[])=>{J(e)?e.forEach(s=>s(...t)):e&&e(...t)},Ul=e=>e?J(e)?e.some(t=>t.length>1):e.length>1:!1;function Ki(e){const t={};for(const B in e)B in Hi||(t[B]=e[B]);if(e.css===!1)return t;const{name:s="v",type:n,duration:o,enterFromClass:l=`${s}-enter-from`,enterActiveClass:r=`${s}-enter-active`,enterToClass:i=`${s}-enter-to`,appearFromClass:c=l,appearActiveClass:f=r,appearToClass:u=i,leaveFromClass:d=`${s}-leave-from`,leaveActiveClass:g=`${s}-leave-active`,leaveToClass:h=`${s}-leave-to`}=e,C=yu(o),x=C&&C[0],L=C&&C[1],{onBeforeEnter:w,onEnter:p,onEnterCancelled:b,onLeave:k,onLeaveCancelled:S,onBeforeAppear:q=w,onAppear:D=p,onAppearCancelled:U=b}=t,M=(B,Z,R,ee)=>{B._enterCancelled=ee,Dt(B,Z?u:i),Dt(B,Z?f:r),R&&R()},z=(B,Z)=>{B._isLeaving=!1,Dt(B,d),Dt(B,h),Dt(B,g),Z&&Z()},ne=B=>(Z,R)=>{const ee=B?D:p,ce=()=>M(Z,B,R);Zt(ee,[Z,ce]),Hl(()=>{Dt(Z,B?c:l),pt(Z,B?u:i),Ul(ee)||Wl(Z,n,x,ce)})};return Re(t,{onBeforeEnter(B){Zt(w,[B]),pt(B,l),pt(B,r)},onBeforeAppear(B){Zt(q,[B]),pt(B,c),pt(B,f)},onEnter:ne(!1),onAppear:ne(!0),onLeave(B,Z){B._isLeaving=!0;const R=()=>z(B,Z);pt(B,d),B._enterCancelled?(pt(B,g),Po(B)):(Po(B),pt(B,g)),Hl(()=>{B._isLeaving&&(Dt(B,d),pt(B,h),Ul(k)||Wl(B,n,L,R))}),Zt(k,[B,R])},onEnterCancelled(B){M(B,!1,void 0,!0),Zt(b,[B])},onAppearCancelled(B){M(B,!0,void 0,!0),Zt(U,[B])},onLeaveCancelled(B){z(B),Zt(S,[B])}})}function yu(e){if(e==null)return null;if(be(e))return[co(e.enter),co(e.leave)];{const t=co(e);return[t,t]}}function co(e){return Ta(e)}function pt(e,t){t.split(/\s+/).forEach(s=>s&&e.classList.add(s)),(e[ks]||(e[ks]=new Set)).add(t)}function Dt(e,t){t.split(/\s+/).forEach(n=>n&&e.classList.remove(n));const s=e[ks];s&&(s.delete(t),s.size||(e[ks]=void 0))}function Hl(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}let ku=0;function Wl(e,t,s,n){const o=e._endId=++ku,l=()=>{o===e._endId&&n()};if(s!=null)return setTimeout(l,s);const{type:r,timeout:i,propCount:c}=Gi(e,t);if(!r)return n();const f=r+"end";let u=0;const d=()=>{e.removeEventListener(f,g),l()},g=h=>{h.target===e&&++u>=c&&d()};setTimeout(()=>{u<c&&d()},i+1),e.addEventListener(f,g)}function Gi(e,t){const s=window.getComputedStyle(e),n=C=>(s[C]||"").split(", "),o=n(`${Lt}Delay`),l=n(`${Lt}Duration`),r=Kl(o,l),i=n(`${Ps}Delay`),c=n(`${Ps}Duration`),f=Kl(i,c);let u=null,d=0,g=0;t===Lt?r>0&&(u=Lt,d=r,g=l.length):t===Ps?f>0&&(u=Ps,d=f,g=c.length):(d=Math.max(r,f),u=d>0?r>f?Lt:Ps:null,g=u?u===Lt?l.length:c.length:0);const h=u===Lt&&/\b(?:transform|all)(?:,|$)/.test(n(`${Lt}Property`).toString());return{type:u,timeout:d,propCount:g,hasTransform:h}}function Kl(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max(...t.map((s,n)=>Gl(s)+Gl(e[n])))}function Gl(e){return e==="auto"?0:Number(e.slice(0,-1).replace(",","."))*1e3}function Po(e){return(e?e.ownerDocument:document).body.offsetHeight}function wu(e,t,s){const n=e[ks];n&&(t=(t?[t,...n]:[...n]).join(" ")),t==null?e.removeAttribute("class"):s?e.setAttribute("class",t):e.className=t}const En=Symbol("_vod"),il=Symbol("_vsh"),ql={name:"show",beforeMount(e,{value:t},{transition:s}){e[En]=e.style.display==="none"?"":e.style.display,s&&t?s.beforeEnter(e):Os(e,t)},mounted(e,{value:t},{transition:s}){s&&t&&s.enter(e)},updated(e,{value:t,oldValue:s},{transition:n}){!t!=!s&&(n?t?(n.beforeEnter(e),Os(e,!0),n.enter(e)):n.leave(e,()=>{Os(e,!1)}):Os(e,t))},beforeUnmount(e,{value:t}){Os(e,t)}};function Os(e,t){e.style.display=t?e[En]:"none",e[il]=!t}const Cu=Symbol(""),Su=/(?:^|;)\s*display\s*:/;function Eu(e,t,s){const n=e.style,o=Ce(s);let l=!1;if(s&&!o){if(t)if(Ce(t))for(const r of t.split(";")){const i=r.slice(0,r.indexOf(":")).trim();s[i]==null&&Vs(n,i,"")}else for(const r in t)s[r]==null&&Vs(n,r,"");for(const r in s){r==="display"&&(l=!0);const i=s[r];i!=null?Au(e,r,!Ce(t)&&t?t[r]:void 0,i)||Vs(n,r,i):Vs(n,r,"")}}else if(o){if(t!==s){const r=n[Cu];r&&(s+=";"+r),n.cssText=s,l=Su.test(s)}}else t&&e.removeAttribute("style");En in e&&(e[En]=l?n.display:"",e[il]&&(n.display="none"))}const zl=/\s*!important$/;function Vs(e,t,s){if(J(s))s.forEach(n=>Vs(e,t,n));else if(s==null&&(s=""),t.startsWith("--"))e.setProperty(t,s);else{const n=Tu(e,t);zl.test(s)?e.setProperty(is(n),s.replace(zl,""),"important"):e[n]=s}}const Zl=["Webkit","Moz","ms"],uo={};function Tu(e,t){const s=uo[t];if(s)return s;let n=Ge(t);if(n!=="filter"&&n in e)return uo[t]=n;n=Pn(n);for(let o=0;o<Zl.length;o++){const l=Zl[o]+n;if(l in e)return uo[t]=l}return t}function Au(e,t,s,n){return e.tagName==="TEXTAREA"&&(t==="width"||t==="height")&&Ce(n)&&s===n}const Jl="http://www.w3.org/1999/xlink";function Yl(e,t,s,n,o,l=Oa(t)){n&&t.startsWith("xlink:")?s==null?e.removeAttributeNS(Jl,t.slice(6,t.length)):e.setAttributeNS(Jl,t,s):s==null||l&&!Pr(s)?e.removeAttribute(t):e.setAttribute(t,l?"":Xe(s)?String(s):s)}function Ql(e,t,s,n,o){if(t==="innerHTML"||t==="textContent"){s!=null&&(e[t]=t==="innerHTML"?Ui(s):s);return}const l=e.tagName;if(t==="value"&&l!=="PROGRESS"&&!l.includes("-")){const i=l==="OPTION"?e.getAttribute("value")||"":e.value,c=s==null?e.type==="checkbox"?"on":"":String(s);(i!==c||!("_value"in e))&&(e.value=c),s==null&&e.removeAttribute(t),e._value=s;return}let r=!1;if(s===""||s==null){const i=typeof e[t];i==="boolean"?s=Pr(s):s==null&&i==="string"?(s="",r=!0):i==="number"&&(s=0,r=!0)}try{e[t]=s}catch{}r&&e.removeAttribute(o||t)}function Ht(e,t,s,n){e.addEventListener(t,s,n)}function $u(e,t,s,n){e.removeEventListener(t,s,n)}const Xl=Symbol("_vei");function Iu(e,t,s,n,o=null){const l=e[Xl]||(e[Xl]={}),r=l[t];if(n&&r)r.value=n;else{const[i,c]=Ou(t);if(n){const f=l[t]=Nu(n,o);Ht(e,i,f,c)}else r&&($u(e,i,r,c),l[t]=void 0)}}const Ru=/(Once|Passive|Capture)$/,Pu=/^on:?(?:Once|Passive|Capture)$/;function Ou(e){let t,s;for(;(s=e.match(Ru))&&!Pu.test(e);)t||(t={}),e=e.slice(0,e.length-s[1].length),t[s[1].toLowerCase()]=!0;return[e[2]===":"?e.slice(3):is(e.slice(2)),t]}let fo=0;const Mu=Promise.resolve(),Lu=()=>fo||(Mu.then(()=>fo=0),fo=Date.now());function Nu(e,t){const s=n=>{if(!n._vts)n._vts=Date.now();else if(n._vts<=s.attached)return;const o=s.value;if(J(o)){const l=n.stopImmediatePropagation;n.stopImmediatePropagation=()=>{l.call(n),n._stopped=!0};const r=o.slice(),i=[n];for(let c=0;c<r.length&&!n._stopped;c++){const f=r[c];f&&nt(f,t,5,i)}}else nt(o,t,5,[n])};return s.value=e,s.attached=Lu(),s}const er=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,Vu=(e,t,s,n,o,l)=>{const r=o==="svg";t==="class"?wu(e,n,r):t==="style"?Eu(e,s,n):An(t)?$n(t)||Iu(e,t,s,n,l):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):ju(e,t,n,r))?(Ql(e,t,n),!e.tagName.includes("-")&&(t==="value"||t==="checked"||t==="selected")&&Yl(e,t,n,r,l,t!=="value")):e._isVueCE&&(Du(e,t)||e._def.__asyncLoader&&(/[A-Z]/.test(t)||!Ce(n)))?Ql(e,Ge(t),n,l,t):(t==="true-value"?e._trueValue=n:t==="false-value"&&(e._falseValue=n),Yl(e,t,n,r))};function ju(e,t,s,n){if(n)return!!(t==="innerHTML"||t==="textContent"||t in e&&er(t)&&le(s));if(t==="spellcheck"||t==="draggable"||t==="translate"||t==="autocorrect"||t==="sandbox"&&e.tagName==="IFRAME"||t==="form"||t==="list"&&e.tagName==="INPUT"||t==="type"&&e.tagName==="TEXTAREA")return!1;if(t==="width"||t==="height"){const o=e.tagName;if(o==="IMG"||o==="VIDEO"||o==="CANVAS"||o==="SOURCE")return!1}return er(t)&&Ce(s)?!1:t in e}function Du(e,t){const s=e._def.props;if(!s)return!1;const n=Ge(t);return Array.isArray(s)?s.some(o=>Ge(o)===n):Object.keys(s).some(o=>Ge(o)===n)}const qi=new WeakMap,zi=new WeakMap,Tn=Symbol("_moveCb"),tr=Symbol("_enterCb"),Bu=e=>(delete e.props.mode,e),Fu=Bu({name:"TransitionGroup",props:Re({},Wi,{tag:String,moveClass:String}),setup(e,{slots:t}){const s=ln(),n=ci();let o,l;return vi(()=>{if(!o.length)return;const r=e.moveClass||`${e.name||"v"}-move`;if(!Ku(o[0].el,s.vnode.el,r)){o=[];return}o.forEach(Uu),o.forEach(Hu);const i=o.filter(Wu);Po(s.vnode.el),i.forEach(c=>{const f=c.el,u=f.style;pt(f,r),u.transform=u.webkitTransform=u.transitionDuration="";const d=f[Tn]=g=>{g&&g.target!==f||(!g||g.propertyName.endsWith("transform"))&&(f.removeEventListener("transitionend",d),f[Tn]=null,Dt(f,r))};f.addEventListener("transitionend",d)}),o=[]}),()=>{const r=pe(e),i=Ki(r);let c=r.tag||ie;if(o=[],l)for(let f=0;f<l.length;f++){const u=l[f];u.el&&u.el instanceof Element&&!u.el[il]&&(o.push(u),rs(u,Js(u,i,n,s)),qi.set(u,Zi(u.el)))}l=t.default?el(t.default()):[];for(let f=0;f<l.length;f++){const u=l[f];u.key!=null&&rs(u,Js(u,i,n,s))}return ue(c,null,l)}}}),al=Fu;function Uu(e){const t=e.el;t[Tn]&&t[Tn](),t[tr]&&t[tr]()}function Hu(e){zi.set(e,Zi(e.el))}function Wu(e){const t=qi.get(e),s=zi.get(e),n=t.left-s.left,o=t.top-s.top;if(n||o){const l=e.el,r=l.style,i=l.getBoundingClientRect();let c=1,f=1;return l.offsetWidth&&(c=i.width/l.offsetWidth),l.offsetHeight&&(f=i.height/l.offsetHeight),(!Number.isFinite(c)||c===0)&&(c=1),(!Number.isFinite(f)||f===0)&&(f=1),Math.abs(c-1)<.01&&(c=1),Math.abs(f-1)<.01&&(f=1),r.transform=r.webkitTransform=`translate(${n/c}px,${o/f}px)`,r.transitionDuration="0s",e}}function Zi(e){const t=e.getBoundingClientRect();return{left:t.left,top:t.top}}function Ku(e,t,s){const n=e.cloneNode(),o=e[ks];o&&o.forEach(i=>{i.split(/\s+/).forEach(c=>c&&n.classList.remove(c))}),s.split(/\s+/).forEach(i=>i&&n.classList.add(i)),n.style.display="none";const l=t.nodeType===1?t:t.parentNode;l.appendChild(n);const{hasTransform:r}=Gi(n);return l.removeChild(n),r}const ws=e=>{const t=e.props["onUpdate:modelValue"]||!1;return J(t)?s=>hn(t,s):t};function Gu(e){e.target.composing=!0}function sr(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const bt=Symbol("_assign"),pn=Symbol("_initialValue");function po(e,t,s){return t&&(e=e.trim()),s&&(e=On(e)),e}const Oe={created(e,{modifiers:{lazy:t,trim:s,number:n}},o){e.parentNode&&(e.type==="text"?e[pn]=e.defaultValue.replace(/[\r\n]/g,""):e.type==="textarea"&&(e[pn]=e.defaultValue.replace(/\r\n?/g,`
`))),e[bt]=ws(o);const l=n||o.props&&o.props.type==="number";Ht(e,t?"change":"input",r=>{r.target.composing||e[bt](po(e.value,s,l))}),(s||l)&&Ht(e,"change",()=>{e.value=po(e.value,s,l)}),t||(Ht(e,"compositionstart",Gu),Ht(e,"compositionend",sr),Ht(e,"change",sr))},mounted(e,{value:t,modifiers:{trim:s,number:n}}){const o=t??"",l=e[pn];delete e[pn],l!==void 0&&(e.type==="text"||e.type==="textarea")&&e.value!==l?e[bt](po(e.value,s,n)):e.value=o},beforeUpdate(e,{value:t,oldValue:s,modifiers:{lazy:n,trim:o,number:l}},r){if(e[bt]=ws(r),e.composing)return;const i=(l||e.type==="number")&&!/^0\d/.test(e.value)?On(e.value):e.value,c=t??"";if(i===c)return;const f=e.getRootNode();(f instanceof Document||f instanceof ShadowRoot)&&f.activeElement===e&&e.type!=="range"&&(n&&t===s||o&&e.value.trim()===c)||(e.value=c)}},Jt={deep:!0,created(e,t,s){e[bt]=ws(s),Ht(e,"change",()=>{const n=e._modelValue,o=tn(e),l=e.checked,r=e[bt];if(J(n)){const i=Wo(n,o),c=i!==-1;if(l&&!c)r(n.concat(o));else if(!l&&c){const f=[...n];f.splice(i,1),r(f)}}else if(Es(n)){const i=new Set(n);l?i.add(o):i.delete(o),r(i)}else r(Ji(e,l))})},mounted:nr,beforeUpdate(e,t,s){e[bt]=ws(s),nr(e,t,s)}};function nr(e,{value:t,oldValue:s},n){e._modelValue=t;let o;if(J(t))o=Wo(t,n.props.value)>-1;else if(Es(t))o=t.has(n.props.value);else{if(t===s)return;o=Ts(t,Ji(e,!0))}e.checked!==o&&(e.checked=o)}const cl={deep:!0,created(e,{value:t,modifiers:{number:s}},n){e._modelValue=t,Ht(e,"change",()=>{const o=Array.prototype.filter.call(e.options,l=>l.selected).map(l=>s?On(tn(l)):tn(l));e[bt](e.multiple?Es(e._modelValue)?new Set(o):o:o[0]),e._assigning=!0,Rt(()=>{e._assigning=!1})}),e[bt]=ws(n)},mounted(e,{value:t}){or(e,t)},beforeUpdate(e,{value:t},s){e._modelValue=t,e[bt]=ws(s)},updated(e,{value:t}){e._assigning||or(e,t)}};function or(e,t){const s=e.multiple,n=J(t);if(!(s&&!n&&!Es(t))){for(let o=0,l=e.options.length;o<l;o++){const r=e.options[o],i=tn(r);if(s)if(n){const c=typeof i;c==="string"||c==="number"?r.selected=t.some(f=>String(f)===String(i)):r.selected=Wo(t,i)>-1}else r.selected=t.has(i);else if(Ts(tn(r),t)){e.selectedIndex!==o&&(e.selectedIndex=o);return}}!s&&e.selectedIndex!==-1&&(e.selectedIndex=-1)}}function tn(e){return"_value"in e?e._value:e.value}function Ji(e,t){const s=t?"_trueValue":"_falseValue";return s in e?e[s]:t}const qu=["ctrl","shift","alt","meta"],zu={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)=>qu.some(s=>e[`${s}Key`]&&!t.includes(s))},ls=(e,t)=>{if(!e)return e;const s=e._withMods||(e._withMods={}),n=t.join(".");return s[n]||(s[n]=((o,...l)=>{for(let r=0;r<t.length;r++){const i=zu[t[r]];if(i&&i(o,t))return}return e(o,...l)}))},Zu=Re({patchProp:Vu},_u);let lr;function Ju(){return lr||(lr=Xc(Zu))}const Yu=((...e)=>{const t=Ju().createApp(...e),{mount:s}=t;return t.mount=n=>{const o=Xu(n);if(!o)return;const l=t._component;!le(l)&&!l.render&&!l.template&&(l.template=o.innerHTML),o.nodeType===1&&(o.textContent="");const r=s(o,!1,Qu(o));return o instanceof Element&&(o.removeAttribute("v-cloak"),o.setAttribute("data-v-app","")),r},t});function Qu(e){if(e instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&e instanceof MathMLElement)return"mathml"}function Xu(e){return Ce(e)?document.querySelector(e):e}let Yi;const Gn=e=>Yi=e,Qi=Symbol();function Oo(e){return e&&typeof e=="object"&&Object.prototype.toString.call(e)==="[object Object]"&&typeof e.toJSON!="function"}var Ks;(function(e){e.direct="direct",e.patchObject="patch object",e.patchFunction="patch function"})(Ks||(Ks={}));function ef(){const e=Nr(!0),t=e.run(()=>oe({}));let s=[],n=[];const o=Yo({install(l){Gn(o),o._a=l,l.provide(Qi,o),l.config.globalProperties.$pinia=o,n.forEach(r=>s.push(r)),n=[]},use(l){return this._a?s.push(l):n.push(l),this},_p:s,_a:null,_e:e,_s:new Map,state:t});return o}const Xi=()=>{};function rr(e,t,s,n=Xi){e.add(t);const o=()=>{e.delete(t)&&n()};return!s&&Vr()&&La(o),o}function ds(e,...t){e.forEach(s=>{s(...t)})}const tf=e=>e(),ir=Symbol(),ho=Symbol();function Mo(e,t){e instanceof Map&&t instanceof Map?t.forEach((s,n)=>e.set(n,s)):e instanceof Set&&t instanceof Set&&t.forEach(e.add,e);for(const s in t){if(!t.hasOwnProperty(s))continue;const n=t[s],o=e[s];Oo(o)&&Oo(n)&&e.hasOwnProperty(s)&&!Te(n)&&!Et(n)?e[s]=Mo(o,n):e[s]=n}return e}const sf=Symbol();function nf(e){return!Oo(e)||!Object.prototype.hasOwnProperty.call(e,sf)}const{assign:Bt}=Object;function of(e){return!!(Te(e)&&e.effect)}function lf(e,t,s,n){const{state:o,actions:l,getters:r}=t,i=s.state.value[e];let c;function f(){i||(s.state.value[e]=o?o():{});const u=nc(s.state.value[e]);return Bt(u,l,Object.keys(r||{}).reduce((d,g)=>(d[g]=Yo(_e(()=>{Gn(s);const h=s._s.get(e);return r[g].call(h,h)})),d),{}))}return c=ea(e,f,t,s,n,!0),c}function ea(e,t,s={},n,o,l){let r;const i=Bt({actions:{}},s),c={deep:!0};let f,u,d=new Set,g=new Set,h;const C=n.state.value[e];!l&&!C&&(n.state.value[e]={});let x;function L(U){let M;f=u=!1,typeof U=="function"?(U(n.state.value[e]),M={type:Ks.patchFunction,storeId:e,events:h}):(Mo(n.state.value[e],U),M={type:Ks.patchObject,payload:U,storeId:e,events:h});const z=x=Symbol();Rt().then(()=>{x===z&&(f=!0)}),u=!0,ds(d,M,n.state.value[e])}const w=l?function(){const{state:M}=s,z=M?M():{};this.$patch(ne=>{Bt(ne,z)})}:Xi;function p(){r.stop(),d.clear(),g.clear(),n._s.delete(e)}const b=(U,M="")=>{if(ir in U)return U[ho]=M,U;const z=function(){Gn(n);const ne=Array.from(arguments),B=new Set,Z=new Set;function R(te){B.add(te)}function ee(te){Z.add(te)}ds(g,{args:ne,name:z[ho],store:S,after:R,onError:ee});let ce;try{ce=U.apply(this&&this.$id===e?this:S,ne)}catch(te){throw ds(Z,te),te}return ce instanceof Promise?ce.then(te=>(ds(B,te),te)).catch(te=>(ds(Z,te),Promise.reject(te))):(ds(B,ce),ce)};return z[ir]=!0,z[ho]=M,z},k={_p:n,$id:e,$onAction:rr.bind(null,g),$patch:L,$reset:w,$subscribe(U,M={}){const z=rr(d,U,M.detached,()=>ne()),ne=r.run(()=>Be(()=>n.state.value[e],B=>{(M.flush==="sync"?u:f)&&U({storeId:e,type:Ks.direct,events:h},B)},Bt({},c,M)));return z},$dispose:p},S=Kt(k);n._s.set(e,S);const D=(n._a&&n._a.runWithContext||tf)(()=>n._e.run(()=>(r=Nr()).run(()=>t({action:b}))));for(const U in D){const M=D[U];if(Te(M)&&!of(M)||Et(M))l||(C&&nf(M)&&(Te(M)?M.value=C[U]:Mo(M,C[U])),n.state.value[e][U]=M);else if(typeof M=="function"){const z=b(M,U);D[U]=z,i.actions[U]=M}}return Bt(S,D),Bt(pe(S),D),Object.defineProperty(S,"$state",{get:()=>n.state.value[e],set:U=>{L(M=>{Bt(M,U)})}}),n._p.forEach(U=>{Bt(S,r.run(()=>U({store:S,app:n._a,pinia:n,options:i})))}),C&&l&&s.hydrate&&s.hydrate(S.$state,C),f=!0,u=!0,S}function ul(e,t,s){let n;const o=typeof t=="function";n=o?s:t;function l(r,i){const c=pc();return r=r||(c?Qe(Qi,null):null),r&&Gn(r),r=Yi,r._s.has(e)||(o?ea(e,t,n,r):lf(e,n,r)),r._s.get(e)}return l.$id=e,l}const gs=typeof document<"u";function ta(e){return typeof e=="object"||"displayName"in e||"props"in e||"__vccOpts"in e}function rf(e){return e.__esModule||e[Symbol.toStringTag]==="Module"||e.default&&ta(e.default)}const ge=Object.assign;function mo(e,t){const s={};for(const n in t){const o=t[n];s[n]=it(o)?o.map(e):e(o)}return s}const Gs=()=>{},it=Array.isArray;function ar(e,t){const s={};for(const n in e)s[n]=n in t?t[n]:e[n];return s}const sa=/#/g,af=/&/g,cf=/\//g,uf=/=/g,ff=/\?/g,na=/\+/g,df=/%5B/g,pf=/%5D/g,oa=/%5E/g,hf=/%60/g,la=/%7B/g,mf=/%7C/g,ra=/%7D/g,gf=/%20/g;function fl(e){return e==null?"":encodeURI(""+e).replace(mf,"|").replace(df,"[").replace(pf,"]")}function vf(e){return fl(e).replace(la,"{").replace(ra,"}").replace(oa,"^")}function Lo(e){return fl(e).replace(na,"%2B").replace(gf,"+").replace(sa,"%23").replace(af,"%26").replace(hf,"`").replace(la,"{").replace(ra,"}").replace(oa,"^")}function bf(e){return Lo(e).replace(uf,"%3D")}function _f(e){return fl(e).replace(sa,"%23").replace(ff,"%3F")}function xf(e){return _f(e).replace(cf,"%2F")}function sn(e){if(e==null)return null;try{return decodeURIComponent(""+e)}catch{}return""+e}const yf=/\/$/,kf=e=>e.replace(yf,"");function go(e,t,s="/"){let n,o={},l="",r="";const i=t.indexOf("#");let c=t.indexOf("?");return c=i>=0&&c>i?-1:c,c>=0&&(n=t.slice(0,c),l=t.slice(c,i>0?i:t.length),o=e(l.slice(1))),i>=0&&(n=n||t.slice(0,i),r=t.slice(i,t.length)),n=Ef(n??t,s),{fullPath:n+l+r,path:n,query:o,hash:sn(r)}}function wf(e,t){const s=t.query?e(t.query):"";return t.path+(s&&"?")+s+(t.hash||"")}function cr(e,t){return!t||!e.toLowerCase().startsWith(t.toLowerCase())?e:e.slice(t.length)||"/"}function Cf(e,t,s){const n=t.matched.length-1,o=s.matched.length-1;return n>-1&&n===o&&Cs(t.matched[n],s.matched[o])&&ia(t.params,s.params)&&e(t.query)===e(s.query)&&t.hash===s.hash}function Cs(e,t){return(e.aliasOf||e)===(t.aliasOf||t)}function ia(e,t){if(Object.keys(e).length!==Object.keys(t).length)return!1;for(var s in e)if(!Sf(e[s],t[s]))return!1;return!0}function Sf(e,t){return it(e)?ur(e,t):it(t)?ur(t,e):e?.valueOf()===t?.valueOf()}function ur(e,t){return it(t)?e.length===t.length&&e.every((s,n)=>s===t[n]):e.length===1&&e[0]===t}function Ef(e,t){if(e.startsWith("/"))return e;if(!e)return t;const s=t.split("/"),n=e.split("/"),o=n[n.length-1];(o===".."||o===".")&&n.push("");let l=s.length-1,r,i;for(r=0;r<n.length;r++)if(i=n[r],i!==".")if(i==="..")l>1&&l--;else break;return s.slice(0,l).join("/")+"/"+n.slice(r).join("/")}const Nt={path:"/",name:void 0,params:{},query:{},hash:"",fullPath:"/",matched:[],meta:{},redirectedFrom:void 0};let No=(function(e){return e.pop="pop",e.push="push",e})({}),vo=(function(e){return e.back="back",e.forward="forward",e.unknown="",e})({});function Tf(e){if(!e)if(gs){const t=document.querySelector("base");e=t&&t.getAttribute("href")||"/",e=e.replace(/^\w+:\/\/[^\/]+/,"")}else e="/";return e[0]!=="/"&&e[0]!=="#"&&(e="/"+e),kf(e)}const Af=/^[^#]+#/;function $f(e,t){return e.replace(Af,"#")+t}function If(e,t){const s=document.documentElement.getBoundingClientRect(),n=e.getBoundingClientRect();return{behavior:t.behavior,left:n.left-s.left-(t.left||0),top:n.top-s.top-(t.top||0)}}const qn=()=>({left:window.scrollX,top:window.scrollY});function Rf(e){let t;if("el"in e){const s=e.el,n=typeof s=="string"&&s.startsWith("#"),o=typeof s=="string"?n?document.getElementById(s.slice(1)):document.querySelector(s):s;if(!o)return;t=If(o,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 fr(e,t){return(history.state?history.state.position-t:-1)+e}const Vo=new Map;function Pf(e,t){Vo.set(e,t)}function Of(e){const t=Vo.get(e);return Vo.delete(e),t}function Mf(e){return typeof e=="string"||e&&typeof e=="object"}function aa(e){return typeof e=="string"||typeof e=="symbol"}let Se=(function(e){return e[e.MATCHER_NOT_FOUND=1]="MATCHER_NOT_FOUND",e[e.NAVIGATION_GUARD_REDIRECT=2]="NAVIGATION_GUARD_REDIRECT",e[e.NAVIGATION_ABORTED=4]="NAVIGATION_ABORTED",e[e.NAVIGATION_CANCELLED=8]="NAVIGATION_CANCELLED",e[e.NAVIGATION_DUPLICATED=16]="NAVIGATION_DUPLICATED",e})({});const ca=Symbol("");Se.MATCHER_NOT_FOUND+"",Se.NAVIGATION_GUARD_REDIRECT+"",Se.NAVIGATION_ABORTED+"",Se.NAVIGATION_CANCELLED+"",Se.NAVIGATION_DUPLICATED+"";function Ss(e,t){return ge(new Error,{type:e,[ca]:!0},t)}function yt(e,t){return e instanceof Error&&ca in e&&(t==null||!!(e.type&t))}const Lf=["params","query","hash"];function Nf(e){if(typeof e=="string")return e;if(e.path!=null)return e.path;const t={};for(const s of Lf)s in e&&(t[s]=e[s]);return JSON.stringify(t,null,2)}function Vf(e){const t={};if(e===""||e==="?")return t;const s=(e[0]==="?"?e.slice(1):e).split("&");for(let n=0;n<s.length;++n){const o=s[n].replace(na," "),l=o.indexOf("="),r=sn(l<0?o:o.slice(0,l)),i=l<0?null:sn(o.slice(l+1));if(r in t){let c=t[r];it(c)||(c=t[r]=[c]),c.push(i)}else t[r]=i}return t}function dr(e){let t="";for(let s in e){const n=e[s];if(s=bf(s),n==null){n!==void 0&&(t+=(t.length?"&":"")+s);continue}(it(n)?n.map(o=>o&&Lo(o)):[n&&Lo(n)]).forEach(o=>{o!==void 0&&(t+=(t.length?"&":"")+s,o!=null&&(t+="="+o))})}return t}function jf(e){const t={};for(const s in e){const n=e[s];n!==void 0&&(t[s]=it(n)?n.map(o=>o==null?null:""+o):n==null?n:""+n)}return t}const Df=Symbol(""),pr=Symbol(""),zn=Symbol(""),dl=Symbol(""),jo=Symbol("");function Ms(){let e=[];function t(n){return e.push(n),()=>{const o=e.indexOf(n);o>-1&&e.splice(o,1)}}function s(){e=[]}return{add:t,list:()=>e.slice(),reset:s}}function Ut(e,t,s,n,o,l=r=>r()){const r=n&&(n.enterCallbacks[o]=n.enterCallbacks[o]||[]);return()=>new Promise((i,c)=>{const f=g=>{g===!1?c(Ss(Se.NAVIGATION_ABORTED,{from:s,to:t})):g instanceof Error?c(g):Mf(g)?c(Ss(Se.NAVIGATION_GUARD_REDIRECT,{from:t,to:g})):(r&&n.enterCallbacks[o]===r&&typeof g=="function"&&r.push(g),i())},u=l(()=>e.call(n&&n.instances[o],t,s,f));let d=Promise.resolve(u);e.length<3&&(d=d.then(f)),d.catch(g=>c(g))})}function bo(e,t,s,n,o=l=>l()){const l=[];for(const r of e)for(const i in r.components){let c=r.components[i];if(!(t!=="beforeRouteEnter"&&!r.instances[i]))if(ta(c)){const f=(c.__vccOpts||c)[t];f&&l.push(Ut(f,s,n,r,i,o))}else{let f=c();l.push(()=>f.then(u=>{if(!u)throw new Error(`Couldn't resolve component "${i}" at "${r.path}"`);const d=rf(u)?u.default:u;r.mods[i]=u,r.components[i]=d;const g=(d.__vccOpts||d)[t];return g&&Ut(g,s,n,r,i,o)()}))}}return l}function Bf(e,t){const s=[],n=[],o=[],l=Math.max(t.matched.length,e.matched.length);for(let r=0;r<l;r++){const i=t.matched[r];i&&(e.matched.find(f=>Cs(f,i))?n.push(i):s.push(i));const c=e.matched[r];c&&(t.matched.find(f=>Cs(f,c))||o.push(c))}return[s,n,o]}let Ff=()=>location.protocol+"//"+location.host;function ua(e,t){const{pathname:s,search:n,hash:o}=t,l=e.indexOf("#");if(l>-1){let r=o.includes(e.slice(l))?e.slice(l).length:1,i=o.slice(r);return i[0]!=="/"&&(i="/"+i),cr(i,"")}return cr(s,e)+n+o}function Uf(e,t,s,n){let o=[],l=[],r=null;const i=({state:g})=>{const h=ua(e,location),C=s.value,x=t.value;let L=0;if(g){if(s.value=h,t.value=g,r&&r===C){r=null;return}L=x?g.position-x.position:0}else n(h);o.forEach(w=>{w(s.value,C,{delta:L,type:No.pop,direction:L?L>0?vo.forward:vo.back:vo.unknown})})};function c(){r=s.value}function f(g){o.push(g);const h=()=>{const C=o.indexOf(g);C>-1&&o.splice(C,1)};return l.push(h),h}function u(){if(document.visibilityState==="hidden"){const{history:g}=window;if(!g.state)return;g.replaceState(ge({},g.state,{scroll:qn()}),"")}}function d(){for(const g of l)g();l=[],window.removeEventListener("popstate",i),window.removeEventListener("pagehide",u),document.removeEventListener("visibilitychange",u)}return window.addEventListener("popstate",i),window.addEventListener("pagehide",u),document.addEventListener("visibilitychange",u),{pauseListeners:c,listen:f,destroy:d}}function hr(e,t,s,n=!1,o=!1){return{back:e,current:t,forward:s,replaced:n,position:window.history.length,scroll:o?qn():null}}function Hf(e){const{history:t,location:s}=window,n={value:ua(e,s)},o={value:t.state};o.value||l(n.value,{back:null,current:n.value,forward:null,position:t.length-1,replaced:!0,scroll:null},!0);function l(c,f,u){const d=e.indexOf("#"),g=d>-1?(s.host&&document.querySelector("base")?e:e.slice(d))+c:Ff()+e+c;try{t[u?"replaceState":"pushState"](f,"",g),o.value=f}catch(h){console.error(h),s[u?"replace":"assign"](g)}}function r(c,f){l(c,ge({},t.state,hr(o.value.back,c,o.value.forward,!0),f,{position:o.value.position}),!0),n.value=c}function i(c,f){const u=ge({},o.value,t.state,{forward:c,scroll:qn()});l(u.current,u,!0),l(c,ge({},hr(n.value,c,null),{position:u.position+1},f),!1),n.value=c}return{location:n,state:o,push:i,replace:r}}function Wf(e){e=Tf(e);const t=Hf(e),s=Uf(e,t.state,t.location,t.replace);function n(l,r=!0){r||s.pauseListeners(),history.go(l)}const o=ge({location:"",base:e,go:n,createHref:$f.bind(null,e)},t,s);return Object.defineProperty(o,"location",{enumerable:!0,get:()=>t.location.value}),Object.defineProperty(o,"state",{enumerable:!0,get:()=>t.state.value}),o}function Kf(e){return e=location.host?e||location.pathname+location.search:"",e.includes("#")||(e+="#"),Wf(e)}let ss=(function(e){return e[e.Static=0]="Static",e[e.Param=1]="Param",e[e.Group=2]="Group",e})({});var Pe=(function(e){return e[e.Static=0]="Static",e[e.Param=1]="Param",e[e.ParamRegExp=2]="ParamRegExp",e[e.ParamRegExpEnd=3]="ParamRegExpEnd",e[e.EscapeNext=4]="EscapeNext",e})(Pe||{});const Gf={type:ss.Static,value:""},qf=/[a-zA-Z0-9_]/;function zf(e){if(!e)return[[]];if(e==="/")return[[Gf]];if(!e.startsWith("/"))throw new Error(`Invalid path "${e}"`);function t(h){throw new Error(`ERR (${s})/"${f}": ${h}`)}let s=Pe.Static,n=s;const o=[];let l;function r(){l&&o.push(l),l=[]}let i=0,c,f="",u="";function d(){f&&(s===Pe.Static?l.push({type:ss.Static,value:f}):s===Pe.Param||s===Pe.ParamRegExp||s===Pe.ParamRegExpEnd?(l.length>1&&(c==="*"||c==="+")&&t(`A repeatable param (${f}) must be alone in its segment. eg: '/:ids+.`),l.push({type:ss.Param,value:f,regexp:u,repeatable:c==="*"||c==="+",optional:c==="*"||c==="?"})):t("Invalid state to consume buffer"),f="")}function g(){f+=c}for(;i<e.length;){if(c=e[i++],c==="\\"&&s!==Pe.ParamRegExp){n=s,s=Pe.EscapeNext;continue}switch(s){case Pe.Static:c==="/"?(f&&d(),r()):c===":"?(d(),s=Pe.Param):g();break;case Pe.EscapeNext:g(),s=n;break;case Pe.Param:c==="("?s=Pe.ParamRegExp:qf.test(c)?g():(d(),s=Pe.Static,c!=="*"&&c!=="?"&&c!=="+"&&i--);break;case Pe.ParamRegExp:c===")"?u[u.length-1]=="\\"?u=u.slice(0,-1)+c:s=Pe.ParamRegExpEnd:u+=c;break;case Pe.ParamRegExpEnd:d(),s=Pe.Static,c!=="*"&&c!=="?"&&c!=="+"&&i--,u="";break;default:t("Unknown state");break}}return s===Pe.ParamRegExp&&t(`Unfinished custom RegExp for param "${f}"`),d(),r(),o}const mr="[^/]+?",Zf={sensitive:!1,strict:!1,start:!0,end:!0};var We=(function(e){return e[e._multiplier=10]="_multiplier",e[e.Root=90]="Root",e[e.Segment=40]="Segment",e[e.SubSegment=30]="SubSegment",e[e.Static=40]="Static",e[e.Dynamic=20]="Dynamic",e[e.BonusCustomRegExp=10]="BonusCustomRegExp",e[e.BonusWildcard=-50]="BonusWildcard",e[e.BonusRepeatable=-20]="BonusRepeatable",e[e.BonusOptional=-8]="BonusOptional",e[e.BonusStrict=.7000000000000001]="BonusStrict",e[e.BonusCaseSensitive=.25]="BonusCaseSensitive",e})(We||{});const Jf=/[.+*?^${}()[\]/\\]/g;function Yf(e,t){const s=ge({},Zf,t),n=[];let o=s.start?"^":"";const l=[];for(const f of e){const u=f.length?[]:[We.Root];s.strict&&!f.length&&(o+="/");for(let d=0;d<f.length;d++){const g=f[d];let h=We.Segment+(s.sensitive?We.BonusCaseSensitive:0);if(g.type===ss.Static)d||(o+="/"),o+=g.value.replace(Jf,"\\$&"),h+=We.Static;else if(g.type===ss.Param){const{value:C,repeatable:x,optional:L,regexp:w}=g;l.push({name:C,repeatable:x,optional:L});const p=w||mr;if(p!==mr){h+=We.BonusCustomRegExp;try{`${p}`}catch(k){throw new Error(`Invalid custom RegExp for param "${C}" (${p}): `+k.message)}}let b=x?`((?:${p})(?:/(?:${p}))*)`:`(${p})`;d||(b=L&&f.length<2?`(?:/${b})`:"/"+b),L&&(b+="?"),o+=b,h+=We.Dynamic,L&&(h+=We.BonusOptional),x&&(h+=We.BonusRepeatable),p===".*"&&(h+=We.BonusWildcard)}u.push(h)}n.push(u)}if(s.strict&&s.end){const f=n.length-1;n[f][n[f].length-1]+=We.BonusStrict}s.strict||(o+="/?"),s.end?o+="$":s.strict&&!o.endsWith("/")&&(o+="(?:/|$)");const r=new RegExp(o,s.sensitive?"":"i");function i(f){const u=f.match(r),d={};if(!u)return null;for(let g=1;g<u.length;g++){const h=u[g]||"",C=l[g-1];d[C.name]=h&&C.repeatable?h.split("/"):h}return d}function c(f){let u="",d=!1;for(const g of e){(!d||!u.endsWith("/"))&&(u+="/"),d=!1;for(const h of g)if(h.type===ss.Static)u+=h.value;else if(h.type===ss.Param){const{value:C,repeatable:x,optional:L}=h,w=C in f?f[C]:"";if(it(w)&&!x)throw new Error(`Provided param "${C}" is an array but it is not repeatable (* or + modifiers)`);const p=it(w)?w.join("/"):w;if(!p)if(L)g.length<2&&(u.endsWith("/")?u=u.slice(0,-1):d=!0);else throw new Error(`Missing required param "${C}"`);u+=p}}return u||"/"}return{re:r,score:n,keys:l,parse:i,stringify:c}}function Qf(e,t){let s=0;for(;s<e.length&&s<t.length;){const n=t[s]-e[s];if(n)return n;s++}return e.length<t.length?e.length===1&&e[0]===We.Static+We.Segment?-1:1:e.length>t.length?t.length===1&&t[0]===We.Static+We.Segment?1:-1:0}function fa(e,t){let s=0;const n=e.score,o=t.score;for(;s<n.length&&s<o.length;){const l=Qf(n[s],o[s]);if(l)return l;s++}if(Math.abs(o.length-n.length)===1){if(gr(n))return 1;if(gr(o))return-1}return o.length-n.length}function gr(e){const t=e[e.length-1];return e.length>0&&t[t.length-1]<0}const Xf={strict:!1,end:!0,sensitive:!1};function ed(e,t,s){const n=Yf(zf(e.path),s),o=ge(n,{record:e,parent:t,children:[],alias:[]});return t&&!o.record.aliasOf==!t.record.aliasOf&&t.children.push(o),o}function td(e,t){const s=[],n=new Map;t=ar(Xf,t);function o(d){return n.get(d)}function l(d,g,h){const C=!h,x=br(d);x.aliasOf=h&&h.record;const L=ar(t,d),w=[x];if("alias"in d){const k=typeof d.alias=="string"?[d.alias]:d.alias;for(const S of k)w.push(br(ge({},x,{components:h?h.record.components:x.components,path:S,aliasOf:h?h.record:x})))}let p,b;for(const k of w){const{path:S}=k;if(g&&S[0]!=="/"){const q=g.record.path,D=q[q.length-1]==="/"?"":"/";k.path=g.record.path+(S&&D+S)}if(p=ed(k,g,L),h?h.alias.push(p):(b=b||p,b!==p&&b.alias.push(p),C&&d.name&&!_r(p)&&r(d.name)),da(p)&&c(p),x.children){const q=x.children;for(let D=0;D<q.length;D++)l(q[D],p,h&&h.children[D])}h=h||p}return b?()=>{r(b)}:Gs}function r(d){if(aa(d)){const g=n.get(d);g&&(n.delete(d),s.splice(s.indexOf(g),1),g.children.forEach(r),g.alias.forEach(r))}else{const g=s.indexOf(d);g>-1&&(s.splice(g,1),d.record.name&&n.delete(d.record.name),d.children.forEach(r),d.alias.forEach(r))}}function i(){return s}function c(d){const g=od(d,s);s.splice(g,0,d),d.record.name&&!_r(d)&&n.set(d.record.name,d)}function f(d,g){let h,C={},x,L;if("name"in d&&d.name){if(h=n.get(d.name),!h)throw Ss(Se.MATCHER_NOT_FOUND,{location:d});L=h.record.name,C=ge(vr(g.params,h.keys.filter(b=>!b.optional).concat(h.parent?h.parent.keys.filter(b=>b.optional):[]).map(b=>b.name)),d.params&&vr(d.params,h.keys.map(b=>b.name))),x=h.stringify(C)}else if(d.path!=null)x=d.path,h=s.find(b=>b.re.test(x)),h&&(C=h.parse(x),L=h.record.name);else{if(h=g.name?n.get(g.name):s.find(b=>b.re.test(g.path)),!h)throw Ss(Se.MATCHER_NOT_FOUND,{location:d,currentLocation:g});L=h.record.name,C=ge({},g.params,d.params),x=h.stringify(C)}const w=[];let p=h;for(;p;)w.unshift(p.record),p=p.parent;return{name:L,path:x,params:C,matched:w,meta:nd(w)}}e.forEach(d=>l(d));function u(){s.length=0,n.clear()}return{addRoute:l,resolve:f,removeRoute:r,clearRoutes:u,getRoutes:i,getRecordMatcher:o}}function vr(e,t){const s={};for(const n of t)n in e&&(s[n]=e[n]);return s}function br(e){const t={path:e.path,redirect:e.redirect,name:e.name,meta:e.meta||{},aliasOf:e.aliasOf,beforeEnter:e.beforeEnter,props:sd(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 sd(e){const t={},s=e.props||!1;if("component"in e)t.default=s;else for(const n in e.components)t[n]=typeof s=="object"?s[n]:s;return t}function _r(e){for(;e;){if(e.record.aliasOf)return!0;e=e.parent}return!1}function nd(e){return e.reduce((t,s)=>ge(t,s.meta),{})}function od(e,t){let s=0,n=t.length;for(;s!==n;){const l=s+n>>1;fa(e,t[l])<0?n=l:s=l+1}const o=ld(e);return o&&(n=t.lastIndexOf(o,n-1)),n}function ld(e){let t=e;for(;t=t.parent;)if(da(t)&&fa(e,t)===0)return t}function da({record:e}){return!!(e.name||e.components&&Object.keys(e.components).length||e.redirect)}function xr(e){const t=Qe(zn),s=Qe(dl),n=_e(()=>{const c=O(e.to);return t.resolve(c)}),o=_e(()=>{const{matched:c}=n.value,{length:f}=c,u=c[f-1],d=s.matched;if(!u||!d.length)return-1;const g=d.findIndex(Cs.bind(null,u));if(g>-1)return g;const h=yr(c[f-2]);return f>1&&yr(u)===h&&d[d.length-1].path!==h?d.findIndex(Cs.bind(null,c[f-2])):g}),l=_e(()=>o.value>-1&&ud(s.params,n.value.params)),r=_e(()=>o.value>-1&&o.value===s.matched.length-1&&ia(s.params,n.value.params));function i(c={}){if(cd(c)){const f=t[O(e.replace)?"replace":"push"](O(e.to)).catch(Gs);return e.viewTransition&&typeof document<"u"&&"startViewTransition"in document&&document.startViewTransition(()=>f),f}return Promise.resolve()}return{route:n,href:_e(()=>n.value.href),isActive:l,isExactActive:r,navigate:i}}function rd(e){return e.length===1?e[0]:e}const id=hi({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:xr,setup(e,{slots:t}){const s=Kt(xr(e)),{options:n}=Qe(zn),o=_e(()=>({[kr(e.activeClass,n.linkActiveClass,"router-link-active")]:s.isActive,[kr(e.exactActiveClass,n.linkExactActiveClass,"router-link-exact-active")]:s.isExactActive}));return()=>{const l=t.default&&rd(t.default(s));return e.custom?l:rl("a",{"aria-current":s.isExactActive?e.ariaCurrentValue:null,href:s.href,onClick:s.navigate,class:o.value},l)}}}),ad=id;function cd(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 ud(e,t){for(const s in t){const n=t[s],o=e[s];if(typeof n=="string"){if(n!==o)return!1}else if(!it(o)||o.length!==n.length||n.some((l,r)=>l.valueOf()!==o[r].valueOf()))return!1}return!0}function yr(e){return e?e.aliasOf?e.aliasOf.path:e.path:""}const kr=(e,t,s)=>e??t??s,fd=hi({name:"RouterView",inheritAttrs:!1,props:{name:{type:String,default:"default"},route:Object},compatConfig:{MODE:3},setup(e,{attrs:t,slots:s}){const n=Qe(jo),o=_e(()=>e.route||n.value),l=Qe(pr,0),r=_e(()=>{let f=O(l);const{matched:u}=o.value;let d;for(;(d=u[f])&&!d.components;)f++;return f}),i=_e(()=>o.value.matched[r.value]);Us(pr,_e(()=>r.value+1)),Us(Df,i),Us(jo,o);const c=oe();return Be(()=>[c.value,i.value,e.name],([f,u,d],[g,h,C])=>{u&&(u.instances[d]=f,h&&h!==u&&f&&f===g&&(u.leaveGuards.size||(u.leaveGuards=h.leaveGuards),u.updateGuards.size||(u.updateGuards=h.updateGuards))),f&&u&&(!h||!Cs(u,h)||!g)&&(u.enterCallbacks[d]||[]).forEach(x=>x(f))},{flush:"post"}),()=>{const f=o.value,u=e.name,d=i.value,g=d&&d.components[u];if(!g)return wr(s.default,{Component:g,route:f});const h=d.props[u],C=h?h===!0?f.params:typeof h=="function"?h(f):h:null,L=rl(g,ge({},C,t,{onVnodeUnmounted:w=>{w.component.isUnmounted&&(d.instances[u]=null)},ref:c}));return wr(s.default,{Component:L,route:f})||L}}});function wr(e,t){if(!e)return null;const s=e(t);return s.length===1?s[0]:s}const dd=fd;function pd(e){const t=td(e.routes,e),s=e.parseQuery||Vf,n=e.stringifyQuery||dr,o=e.history,l=Ms(),r=Ms(),i=Ms(),c=ec(Nt);let f=Nt;gs&&e.scrollBehavior&&"scrollRestoration"in history&&(history.scrollRestoration="manual");const u=mo.bind(null,$=>""+$),d=mo.bind(null,xf),g=mo.bind(null,sn);function h($,K){let H,Y;return aa($)?(H=t.getRecordMatcher($),Y=K):Y=$,t.addRoute(Y,H)}function C($){const K=t.getRecordMatcher($);K&&t.removeRoute(K)}function x(){return t.getRoutes().map($=>$.record)}function L($){return!!t.getRecordMatcher($)}function w($,K){if(K=ge({},K||c.value),typeof $=="string"){const _=go(s,$,K.path),A=t.resolve({path:_.path},K),I=o.createHref(_.fullPath);return ge(_,A,{params:g(A.params),hash:sn(_.hash),redirectedFrom:void 0,href:I})}let H;if($.path!=null)H=ge({},$,{path:go(s,$.path,K.path).path});else{const _=ge({},$.params);for(const A in _)_[A]==null&&delete _[A];H=ge({},$,{params:d(_)}),K.params=d(K.params)}const Y=t.resolve(H,K),de=$.hash||"";Y.params=u(g(Y.params));const m=wf(n,ge({},$,{hash:vf(de),path:Y.path})),v=o.createHref(m);return ge({fullPath:m,hash:de,query:n===dr?jf($.query):$.query||{}},Y,{redirectedFrom:void 0,href:v})}function p($){return typeof $=="string"?go(s,$,c.value.path):ge({},$)}function b($,K){if(f!==$)return Ss(Se.NAVIGATION_CANCELLED,{from:K,to:$})}function k($){return D($)}function S($){return k(ge(p($),{replace:!0}))}function q($,K){const H=$.matched[$.matched.length-1];if(H&&H.redirect){const{redirect:Y}=H;let de=typeof Y=="function"?Y($,K):Y;return typeof de=="string"&&(de=de.includes("?")||de.includes("#")?de=p(de):{path:de},de.params={}),ge({query:$.query,hash:$.hash,params:de.path!=null?{}:$.params},de)}}function D($,K){const H=f=w($),Y=c.value,de=$.state,m=$.force,v=$.replace===!0,_=q(H,Y);if(_)return D(ge(p(_),{state:typeof _=="object"?ge({},de,_.state):de,force:m,replace:v}),K||H);const A=H;A.redirectedFrom=K;let I;return!m&&Cf(n,Y,H)&&(I=Ss(Se.NAVIGATION_DUPLICATED,{to:A,from:Y}),at(Y,Y,!0,!1)),(I?Promise.resolve(I):z(A,Y)).catch(T=>yt(T)?yt(T,Se.NAVIGATION_GUARD_REDIRECT)?T:qe(T):re(T,A,Y)).then(T=>{if(T){if(yt(T,Se.NAVIGATION_GUARD_REDIRECT))return D(ge({replace:v},p(T.to),{state:typeof T.to=="object"?ge({},de,T.to.state):de,force:m}),K||A)}else T=B(A,Y,!0,v,de);return ne(A,Y,T),T})}function U($,K){const H=b($,K);return H?Promise.reject(H):Promise.resolve()}function M($){const K=us.values().next().value;return K&&typeof K.runWithContext=="function"?K.runWithContext($):$()}function z($,K){let H;const[Y,de,m]=Bf($,K);H=bo(Y.reverse(),"beforeRouteLeave",$,K);for(const _ of Y)_.leaveGuards.forEach(A=>{H.push(Ut(A,$,K))});const v=U.bind(null,$,K);return H.push(v),et(H).then(()=>{H=[];for(const _ of l.list())H.push(Ut(_,$,K));return H.push(v),et(H)}).then(()=>{H=bo(de,"beforeRouteUpdate",$,K);for(const _ of de)_.updateGuards.forEach(A=>{H.push(Ut(A,$,K))});return H.push(v),et(H)}).then(()=>{H=[];for(const _ of m)if(_.beforeEnter)if(it(_.beforeEnter))for(const A of _.beforeEnter)H.push(Ut(A,$,K));else H.push(Ut(_.beforeEnter,$,K));return H.push(v),et(H)}).then(()=>($.matched.forEach(_=>_.enterCallbacks={}),H=bo(m,"beforeRouteEnter",$,K,M),H.push(v),et(H))).then(()=>{H=[];for(const _ of r.list())H.push(Ut(_,$,K));return H.push(v),et(H)}).catch(_=>yt(_,Se.NAVIGATION_CANCELLED)?_:Promise.reject(_))}function ne($,K,H){i.list().forEach(Y=>M(()=>Y($,K,H)))}function B($,K,H,Y,de){const m=b($,K);if(m)return m;const v=K===Nt,_=gs?history.state:{};H&&(Y||v?o.replace($.fullPath,ge({scroll:v&&_&&_.scroll},de)):o.push($.fullPath,de)),c.value=$,at($,K,H,v),qe()}let Z;function R(){Z||(Z=o.listen(($,K,H)=>{if(!Gt.listening)return;const Y=w($),de=q(Y,Gt.currentRoute.value);if(de){D(ge(de,{replace:!0,force:!0}),Y).catch(Gs);return}f=Y;const m=c.value;gs&&Pf(fr(m.fullPath,H.delta),qn()),z(Y,m).catch(v=>yt(v,Se.NAVIGATION_ABORTED|Se.NAVIGATION_CANCELLED)?v:yt(v,Se.NAVIGATION_GUARD_REDIRECT)?(D(ge(p(v.to),{force:!0}),Y).then(_=>{yt(_,Se.NAVIGATION_ABORTED|Se.NAVIGATION_DUPLICATED)&&!H.delta&&H.type===No.pop&&o.go(-1,!1)}).catch(Gs),Promise.reject()):(H.delta&&o.go(-H.delta,!1),re(v,Y,m))).then(v=>{v=v||B(Y,m,!1),v&&(H.delta&&!yt(v,Se.NAVIGATION_CANCELLED)?o.go(-H.delta,!1):H.type===No.pop&&yt(v,Se.NAVIGATION_ABORTED|Se.NAVIGATION_DUPLICATED)&&o.go(-1,!1)),ne(Y,m,v)}).catch(Gs)}))}let ee=Ms(),ce=Ms(),te;function re($,K,H){qe($);const Y=ce.list();return Y.length?Y.forEach(de=>de($,K,H)):console.error($),Promise.reject($)}function Fe(){return te&&c.value!==Nt?Promise.resolve():new Promise(($,K)=>{ee.add([$,K])})}function qe($){return te||(te=!$,R(),ee.list().forEach(([K,H])=>$?H($):K()),ee.reset()),$}function at($,K,H,Y){const{scrollBehavior:de}=e;if(!gs||!de)return Promise.resolve();const m=!H&&Of(fr($.fullPath,0))||(Y||!H)&&history.state&&history.state.scroll||null;return Rt().then(()=>de($,K,m)).then(v=>v&&Rf(v)).catch(v=>re(v,$,K))}const ze=$=>o.go($);let cs;const us=new Set,Gt={currentRoute:c,listening:!0,addRoute:h,removeRoute:C,clearRoutes:t.clearRoutes,hasRoute:L,getRoutes:x,resolve:w,options:e,push:k,replace:S,go:ze,back:()=>ze(-1),forward:()=>ze(1),beforeEach:l.add,beforeResolve:r.add,afterEach:i.add,onError:ce.add,isReady:Fe,install($){$.component("RouterLink",ad),$.component("RouterView",dd),$.config.globalProperties.$router=Gt,Object.defineProperty($.config.globalProperties,"$route",{enumerable:!0,get:()=>O(c)}),gs&&!cs&&c.value===Nt&&(cs=!0,k(o.location).catch(Y=>{}));const K={};for(const Y in Nt)Object.defineProperty(K,Y,{get:()=>c.value[Y],enumerable:!0});$.provide(zn,Gt),$.provide(dl,Qr(K)),$.provide(jo,c);const H=$.unmount;us.add($),$.unmount=function(){us.delete($),us.size<1&&(f=Nt,Z&&Z(),Z=null,c.value=Nt,cs=!1,te=!1),H()}}};function et($){return $.reduce((K,H)=>K.then(()=>M(H)),Promise.resolve())}return Gt}function hd(){return Qe(zn)}function pa(e){return Qe(dl)}const Zn="vnt-web-access-token",Jn=!!globalThis.__VNT_DESKTOP__,js=new URL(window.location.href),Do=js.searchParams.get("token")||"";Do&&(localStorage.setItem(Zn,Do),js.searchParams.delete("token"),window.history.replaceState({},"",`${js.pathname}${js.search}${js.hash}`));const Yn=oe(Jn?"":Do||localStorage.getItem(Zn)||""),pl=oe(Jn||!!Yn.value),ha=()=>Yn.value,md=e=>{const t=e.trim();localStorage.setItem(Zn,t),Yn.value=t,pl.value=!!t},gd=()=>{localStorage.removeItem(Zn),Yn.value="",pl.value=!1},ot=async(e,t={})=>{if(globalThis.__VNT_IPC_REQUEST__){const r=await globalThis.__VNT_IPC_REQUEST__({method:t.method||"GET",path:e,body:t.body||null});if(r.code!==0)throw new Error(r.msg||"请求失败");return r.data}const s=new Headers(t.headers||{}),n=ha();n&&s.set("Authorization",`Bearer ${n}`);const o=await fetch(e,{...t,headers:s}),l=await o.json();if(o.status===401&&gd(),l.code!==0)throw new Error(l.msg||"请求失败");return l.data},ma={"Content-Type":"application/json"},vd=e=>ot(`/api/info?file_name=${encodeURIComponent(e)}`),bd=e=>ot(`/api/peers?file_name=${encodeURIComponent(e)}`),_d=e=>ot(`/api/routes?file_name=${encodeURIComponent(e)}`),xd=e=>ot(`/api/start/status?file_name=${encodeURIComponent(e)}`),yd=()=>ot("/api/version"),kd=()=>ot("/api/instances"),wd=e=>ot(`/api/instance?file_name=${encodeURIComponent(e)}`,{method:"DELETE"}),hl=(e,t)=>ot(e,{method:"POST",headers:ma,body:JSON.stringify({file_name:t})}),Cd=e=>hl("/api/start",e),ga=e=>hl("/api/stop",e),Sd=e=>hl("/api/restart",e),Ed=()=>ot("/api/config/list"),Td=e=>ot(`/api/config?file_name=${encodeURIComponent(e)}`),Ad=(e,t)=>ot("/api/config",{method:"POST",headers:ma,body:JSON.stringify({file_name:e||null,config:t})}),$d=e=>ot(`/api/config?file_name=${encodeURIComponent(e)}`,{method:"DELETE"});let Id=0;const as=ul("ui",()=>{const e=oe([]),t=(i,c,f=3e3)=>{const u=++Id;e.value.push({id:u,type:i,message:c}),setTimeout(()=>{e.value=e.value.filter(d=>d.id!==u)},f)},s={success:i=>t("success",i),error:i=>t("error",i,4500),info:i=>t("info",i)},n=Kt({show:!1,title:"",message:"",danger:!1,confirmText:"确定",resolve:null});return{toasts:e,toast:s,confirmState:n,confirm:({title:i="确认操作",message:c="",danger:f=!1,confirmText:u="确定"}={})=>new Promise(d=>{n.show=!0,n.title=i,n.message=c,n.danger=f,n.confirmText=u,n.resolve=d}),confirmOk:()=>{n.show=!1,n.resolve&&n.resolve(!0),n.resolve=null},confirmCancel:()=>{n.show=!1,n.resolve&&n.resolve(!1),n.resolve=null}}}),va=ul("startLog",()=>{const e=oe(!1),t=oe([]),s=oe("stopped"),n=oe(null),o=oe(null);let l=null,r=null,i=null,c=null;const f=({fetchInstances:w,instanceList:p,configList:b})=>{r=w,i=p,c=b},u=_e(()=>{if(!n.value)return"";const w=(i?.value||[]).find(b=>b.file_name===n.value);if(w)return w.config_name||w.file_name;const p=(c?.value||[]).find(b=>b.file_name===n.value);return p?p.config_name||p.file_name:n.value}),d=async()=>{if(n.value)try{const w=await xd(n.value);t.value=w.logs||[],s.value=w.status,Rt(()=>{o.value&&(o.value.scrollTop=o.value.scrollHeight)}),s.value==="running"?(g(),r&&r(),e.value=!1):s.value==="stopped"&&t.value.length>0&&(g(),r&&r())}catch(w){console.error(w)}},g=()=>{l&&(clearInterval(l),l=null)},h=()=>{g(),l=setInterval(d,1e3),d()};return{showStartLog:e,startLogs:t,startStatus:s,logFileName:n,logContainer:o,logConfigName:u,bindApp:f,openStartLog:w=>{n.value=w,t.value=[],s.value="starting",e.value=!0,h()},pollStartStatus:d,startPolling:h,stopPolling:g,cancelStart:async()=>{g();const w=n.value;if(w)try{await ga(w),t.value.push("启动已手动取消")}catch{}s.value="stopped",r&&r()},close:()=>{e.value=!1}}}),Mt=ul("app",()=>{const e=as(),t=va(),s=oe({}),n=oe([]),o=oe(null),l=oe([]),r=oe({}),i=oe({}),c=oe(!document.hidden),f=()=>{c.value=!document.hidden};let u=null;const d=_e(()=>n.value.filter(R=>R.status==="running").length),g=_e(()=>n.value.filter(R=>R.status==="starting").length),h=_e(()=>d.value>0?`运行中 x${d.value}`:g.value>0?"启动中...":"未启动"),C=_e(()=>o.value&&s.value[o.value]||null),x=_e(()=>{if(!o.value)return"";const R=n.value.find(ee=>ee.file_name===o.value);return R?R.config_name||R.file_name:o.value}),L=oe(""),w=async()=>{try{L.value=await yd()||""}catch(R){console.error("Fetch version error",R)}},p=_e(()=>!!(C.value&&C.value.server_info&&C.value.server_info.some(R=>R.connected))),b=_e(()=>{const R=C.value;return!R||!R.server_info||!R.server_info.length?"未配置服务器":`${R.server_info.filter(ee=>ee.connected).length} / ${R.server_info.length} 已连接`}),k=R=>s.value[R]||{},S=async R=>{try{s.value[R]=await vd(R)}catch(ee){console.error("Fetch info error",ee)}},q=async()=>{try{const R=await kd()||[];n.value=R;for(const ee of Object.keys(s.value))R.some(ce=>ce.file_name===ee)||delete s.value[ee];for(const ee of Object.keys(i.value)){const ce=R.find(te=>te.file_name===ee);(!ce||ce.status==="stopped")&&delete i.value[ee]}if(!o.value||!R.some(ee=>ee.file_name===o.value)){const ee=R.find(ce=>ce.status==="running");o.value=ee?ee.file_name:R.length>0?R[0].file_name:null}for(const ee of R)ee.status==="running"&&S(ee.file_name)}catch(R){console.error("Fetch instances error",R)}},D=async()=>{try{l.value=await Ed()||[]}catch(R){console.error("Fetch list error",R)}},U=async R=>{if(!R){e.toast.error("请先选择一个配置");return}if(!r.value[R]){r.value[R]=!0;try{await Cd(R),t.openStartLog(R),q()}catch(ee){e.toast.error("启动失败: "+ee.message)}finally{r.value[R]=!1}}},M=async R=>{if(!(!R||r.value[R])){r.value[R]=!0,i.value[R]=!0;try{await ga(R),e.toast.success("已停止"),t.logFileName===R&&(t.stopPolling(),t.showStartLog=!1),q()}catch(ee){e.toast.error("停止失败: "+ee.message),console.error(ee),delete i.value[R]}finally{r.value[R]=!1}}},z=async R=>{if(!(!R||r.value[R])){r.value[R]=!0;try{await Sd(R),t.openStartLog(R),q()}catch(ee){e.toast.error("重启失败: "+ee.message)}finally{r.value[R]=!1}}},ne=async R=>{if(!(!R||r.value[R])){r.value[R]=!0;try{await wd(R),e.toast.success("已移除"),t.logFileName===R&&(t.stopPolling(),t.showStartLog=!1),o.value===R&&(o.value=null),q()}catch(ee){e.toast.error("移除失败: "+ee.message)}finally{r.value[R]=!1}}};t.bindApp({fetchInstances:q,instanceList:n,configList:l});const B=async()=>{if(!Jn&&!ha())return;document.addEventListener("visibilitychange",f),w(),await q(),D();const R=n.value.find(ee=>ee.status==="starting");R&&t.openStartLog(R.file_name),u=setInterval(()=>{c.value&&q()},3e3)},Z=()=>{document.removeEventListener("visibilitychange",f),t.stopPolling(),u&&clearInterval(u)};return ln()&&(Ot(B),As(Z)),{instances:s,instanceList:n,selectedInstance:o,configList:l,loadingMap:r,stoppingMap:i,isPageVisible:c,runningCount:d,startingCount:g,headerStatusText:h,selectedInfo:C,selectedConfigName:x,version:L,isServerConnected:p,serverStatusText:b,infoOf:k,fetchInstances:q,fetchInstanceInfo:S,fetchConfigList:D,startVnt:U,stopVnt:M,restartVnt:z,dismissInstance:ne}}),Rd=[{to:"/",label:"网络总览",shortLabel:"总览",icon:"M4 4h6v6H4V4Zm10 0h6v6h-6V4ZM4 14h6v6H4v-6Zm10 0h6v6h-6v-6Z"},{to:"/instances",label:"运行实例",shortLabel:"实例",icon:"M4 18V8m5 10V4m6 14v-7m5 7V6"},{to:"/peers",label:"在线设备",shortLabel:"设备",icon:"M15 19a6 6 0 0 0-12 0m18 0a5 5 0 0 0-5-5m-7-3a4 4 0 1 0 0-8 4 4 0 0 0 0 8Zm8 0a3 3 0 1 0 0-6"},{to:"/routes",label:"路由表",shortLabel:"路由",icon:"M6 8a2 2 0 1 0 0-4 2 2 0 0 0 0 4Zm12 12a2 2 0 1 0 0-4 2 2 0 0 0 0 4ZM8 6h6a4 4 0 0 1 4 4v2m-3-3 3 3 3-3M16 18h-6a4 4 0 0 1-4-4v-2"},{to:"/config",label:"组网配置",shortLabel:"配置",icon:"M12 15.5a3.5 3.5 0 1 0 0-7 3.5 3.5 0 0 0 0 7Zm7.4-.5a1.7 1.7 0 0 0 .3 1.9l.1.1-2.8 2.8-.1-.1a1.7 1.7 0 0 0-1.9-.3A1.7 1.7 0 0 0 14 21v.2h-4V21a1.7 1.7 0 0 0-1-1.6 1.7 1.7 0 0 0-1.9.3l-.1.1L4.2 17l.1-.1a1.7 1.7 0 0 0 .3-1.9A1.7 1.7 0 0 0 3 14h-.2v-4H3a1.7 1.7 0 0 0 1.6-1 1.7 1.7 0 0 0-.3-1.9L4.2 7 7 4.2l.1.1A1.7 1.7 0 0 0 9 4.6 1.7 1.7 0 0 0 10 3v-.2h4V3a1.7 1.7 0 0 0 1 1.6 1.7 1.7 0 0 0 1.9-.3l.1-.1L19.8 7l-.1.1a1.7 1.7 0 0 0-.3 1.9 1.7 1.7 0 0 0 1.6 1h.2v4H21a1.7 1.7 0 0 0-1.6 1Z"},{to:"/web-access",label:"Web 访问",shortLabel:"Web",desktopOnly:!0,icon:"M12 21a9 9 0 1 0 0-18 9 9 0 0 0 0 18Zm0 0c2.2-2.5 3.3-5.5 3.3-9S14.2 5.5 12 3m0 18c-2.2-2.5-3.3-5.5-3.3-9S9.8 5.5 12 3M3.5 9h17m-17 6h17"}],ba=()=>Rd.filter(e=>!e.desktopOnly||globalThis.__VNT_DESKTOP__),ml="/assets/vnt-icon-CtSHy0mt.png",Pd={class:"flex h-full min-h-0 flex-col bg-white dark:bg-slate-900"},Od={class:"flex h-16 shrink-0 items-center gap-3 border-b border-slate-200 px-5 dark:border-slate-800"},Md=["src"],Ld={class:"mx-3 mt-4 flex items-center gap-3 rounded-xl border border-slate-200 bg-slate-50 px-3 py-3 dark:border-slate-700 dark:bg-slate-800/60"},Nd={class:"min-w-0"},Vd={class:"mt-0.5 truncate text-xs font-medium text-slate-700 dark:text-slate-200"},jd={class:"mt-4 flex min-h-0 flex-1 flex-col gap-1 overflow-y-auto px-3","aria-label":"主导航"},Dd={class:"h-[18px] w-[18px] shrink-0 fill-none stroke-current",viewBox:"0 0 24 24"},Bd=["d"],Fd={class:"mx-3 mt-3 shrink-0 border-t border-slate-200 px-1 py-4 dark:border-slate-800"},Ud={class:"flex items-center gap-2 text-xs text-slate-400"},Hd={class:"ml-auto font-mono text-[10px]"},Cr={__name:"AppSidebar",emits:["navigate"],setup(e){const t=pa(),s=Mt(),n=ba();return(o,l)=>{const r=Un("router-link");return y(),E("div",Pd,[a("div",Od,[a("img",{src:O(ml),alt:"",class:"h-8 w-8 shrink-0"},null,8,Md),l[1]||(l[1]=a("div",null,[a("div",{class:"text-sm font-bold tracking-wide text-slate-900 dark:text-white"},"VNT"),a("div",{class:"text-[9px] font-semibold tracking-[0.18em] text-slate-400"},"CONTROL CENTER")],-1))]),a("div",Ld,[a("span",{class:G(["h-2.5 w-2.5 shrink-0 rounded-full",O(s).runningCount>0?"bg-green-500":O(s).startingCount>0?"animate-pulse bg-amber-400":"bg-slate-300 dark:bg-slate-600"])},null,2),a("div",Nd,[l[2]||(l[2]=a("div",{class:"text-[9px] font-semibold tracking-wider text-slate-400"},"虚拟网络",-1)),a("div",Vd,V(O(s).headerStatusText),1)])]),a("nav",jd,[(y(!0),E(ie,null,Ee(O(n),i=>(y(),Ie(r,{key:i.to,to:i.to,class:G(["flex min-h-10 items-center gap-3 rounded-lg px-3 text-sm font-medium transition-colors",O(t).path===i.to?"bg-indigo-50 text-indigo-700 dark:bg-indigo-500/10 dark:text-indigo-300":"text-slate-500 hover:bg-slate-100 hover:text-slate-900 dark:text-slate-400 dark:hover:bg-slate-800 dark:hover:text-white"]),onClick:l[0]||(l[0]=c=>o.$emit("navigate"))},{default:Ae(()=>[(y(),E("svg",Dd,[a("path",{d:i.icon,"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"1.7"},null,8,Bd)])),a("span",null,V(i.label),1)]),_:2},1032,["to","class"]))),128))]),a("div",Fd,[a("div",Ud,[a("span",{class:G(["h-1.5 w-1.5 rounded-full",O(s).version?"bg-green-500":"bg-amber-400"])},null,2),a("span",null,V(O(s).version?"本地服务正常":"正在连接服务…"),1),a("span",Hd,"v"+V(O(s).version||"2.0"),1)])])])}}},Wd={key:0,class:"flex shrink-0 items-center justify-between gap-3 border-b border-slate-200 bg-slate-50/60 px-6 py-4 dark:border-slate-700 dark:bg-slate-800/50"},Kd={class:"custom-scrollbar min-h-0 flex-1 overflow-y-auto"},Gd={key:1,class:"flex shrink-0 items-center justify-end gap-3 border-t border-slate-200 bg-slate-50/60 px-6 py-4 dark:border-slate-700 dark:bg-slate-800/50"},gl={__name:"AppModal",props:{show:{type:Boolean,default:!1},maskClosable:{type:Boolean,default:!0},escClosable:{type:Boolean,default:!0},panelClass:{type:String,default:"w-full max-w-2xl"}},emits:["close"],setup(e,{emit:t}){const s=e,n=t,o=r=>{s.escClosable&&r.key==="Escape"&&n("close")};Be(()=>s.show,r=>{r?window.addEventListener("keydown",o):window.removeEventListener("keydown",o)}),As(()=>window.removeEventListener("keydown",o));const l=()=>{s.maskClosable&&n("close")};return(r,i)=>(y(),Ie(Xo,{to:"body"},[ue(Ro,{name:"modal"},{default:Ae(()=>[e.show?(y(),E("div",{key:0,class:"fixed inset-0 z-50 flex items-center justify-center bg-slate-900/40 p-4 backdrop-blur-sm",onClick:ls(l,["self"])},[a("div",{class:G(["modal-panel flex max-h-[90vh] flex-col overflow-hidden rounded-xl border border-slate-200 bg-white shadow-2xl dark:border-slate-700 dark:bg-slate-900",e.panelClass])},[r.$slots.header?(y(),E("div",Wd,[lo(r.$slots,"header")])):fe("",!0),a("div",Kd,[lo(r.$slots,"body")]),r.$slots.footer?(y(),E("div",Gd,[lo(r.$slots,"footer")])):fe("",!0)],2)])):fe("",!0)]),_:3})]))}},qd={class:"w-auto min-w-[260px] max-w-[320px] rounded-lg border border-slate-200 bg-white p-4 text-left text-sm text-slate-600 shadow-2xl dark:border-slate-600 dark:bg-slate-800 dark:text-slate-200"},zd={class:"relative z-10 mb-2 flex items-center justify-between border-b border-slate-200 pb-2 dark:border-slate-600"},Zd={class:"badge-green border border-green-200 dark:border-green-800"},Jd={key:0,class:"relative z-10 mb-3"},Yd={class:"flex flex-wrap gap-1"},Qd={key:1,class:"relative z-10"},Xd={class:"whitespace-normal break-all rounded border border-slate-200 bg-slate-50 p-1.5 font-mono text-xs leading-relaxed text-slate-600 dark:border-slate-700/50 dark:bg-slate-900/50 dark:text-slate-200"},ep={__name:"AppTooltip",setup(e,{expose:t}){const s=oe({show:!1,x:0,y:0,info:null});let n=null;const o=(c,f)=>{if(!f.nat_info)return;n&&(clearTimeout(n),n=null);const u=c.currentTarget.getBoundingClientRect();s.value={show:!0,x:u.left+u.width/2,y:u.bottom+10,info:f.nat_info}},l=()=>{n=setTimeout(()=>{s.value.show=!1},100)},r=()=>{n&&(clearTimeout(n),n=null)},i=()=>{s.value.show=!1};return t({showPeerTooltip:o,hidePeerTooltip:l}),(c,f)=>(y(),Ie(Xo,{to:"body"},[s.value.show?(y(),E("div",{key:0,style:Ln({top:s.value.y+"px",left:s.value.x+"px"}),class:"fixed z-[9999] mt-1 -translate-x-1/2 transform",onMouseenter:r,onMouseleave:i},[a("div",qd,[f[3]||(f[3]=a("div",{class:"absolute -top-2 left-1/2 h-4 w-4 -translate-x-1/2 rotate-45 transform border-l border-t border-slate-200 bg-white dark:border-slate-600 dark:bg-slate-800"},null,-1)),a("div",zd,[f[0]||(f[0]=a("span",{class:"text-xs font-bold uppercase text-slate-400"},"NAT Type",-1)),a("span",Zd,V(s.value.info.nat_type),1)]),s.value.info.public_ips&&s.value.info.public_ips.length>0?(y(),E("div",Jd,[f[1]||(f[1]=a("span",{class:"mb-1 block text-xs text-slate-400"},"Public IPv4:",-1)),a("div",Yd,[(y(!0),E(ie,null,Ee(s.value.info.public_ips,u=>(y(),E("span",{key:u,class:"rounded border border-slate-200 bg-slate-100 px-1.5 py-0.5 font-mono text-xs tabular-nums text-slate-600 dark:border-slate-600 dark:bg-slate-700 dark:text-slate-200"},V(u),1))),128))])])):fe("",!0),s.value.info.ipv6?(y(),E("div",Qd,[f[2]||(f[2]=a("span",{class:"mb-1 block text-xs text-slate-400"},"IPv6:",-1)),a("div",Xd,V(s.value.info.ipv6),1)])):fe("",!0)])],36)):fe("",!0)]))}},tp={class:"text-lg font-bold text-slate-900 flex items-center gap-2 dark:text-white"},sp={key:0,class:"w-5 h-5 text-red-400",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},np={class:"px-6 py-5 text-sm text-slate-600 break-all dark:text-slate-300"},op={__name:"ConfirmHost",setup(e){const t=as();return(s,n)=>(y(),Ie(gl,{show:O(t).confirmState.show,"panel-class":"w-full max-w-sm",onClose:O(t).confirmCancel},{header:Ae(()=>[a("h3",tp,[O(t).confirmState.danger?(y(),E("svg",sp,[...n[2]||(n[2]=[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M12 9v2m0 4h.01m-6.938 4h13.856c1.54 0 2.502-1.667 1.732-3L13.732 4c-.77-1.333-2.694-1.333-3.464 0L3.34 16c-.77 1.333.192 3 1.732 3z"},null,-1)])])):fe("",!0),ae(" "+V(O(t).confirmState.title),1)])]),body:Ae(()=>[a("p",np,V(O(t).confirmState.message),1)]),footer:Ae(()=>[a("button",{class:"btn-ghost",onClick:n[0]||(n[0]=(...o)=>O(t).confirmCancel&&O(t).confirmCancel(...o))},"取消"),a("button",{class:G(O(t).confirmState.danger?"btn-danger":"btn-primary"),onClick:n[1]||(n[1]=(...o)=>O(t).confirmOk&&O(t).confirmOk(...o))},V(O(t).confirmState.confirmText),3)]),_:1},8,["show","onClose"]))}},lp={class:"pointer-events-none fixed right-4 top-4 z-[100] flex flex-col items-end gap-2"},rp={class:"flex items-center gap-2 px-4 py-2.5"},ip=["d"],ap={class:"break-all text-sm text-slate-700 dark:text-slate-200"},cp={__name:"ToastHost",setup(e){const t=as(),s=l=>l==="success"?"bg-green-500":l==="error"?"bg-red-500":"bg-indigo-500",n=l=>l==="success"?"text-green-500":l==="error"?"text-red-500":"text-indigo-500",o=l=>l==="success"?"M5 13l4 4L19 7":l==="error"?"M6 18L18 6M6 6l12 12":"M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z";return(l,r)=>(y(),Ie(Xo,{to:"body"},[a("div",lp,[ue(al,{name:"toast"},{default:Ae(()=>[(y(!0),E(ie,null,Ee(O(t).toasts,i=>(y(),E("div",{key:i.id,class:"pointer-events-auto flex max-w-sm items-stretch overflow-hidden rounded-lg border border-slate-200 bg-white shadow-lg dark:border-slate-700 dark:bg-slate-800"},[a("span",{class:G(["w-1 shrink-0",s(i.type)])},null,2),a("div",rp,[(y(),E("svg",{class:G(["h-4 w-4 shrink-0",n(i.type)]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:o(i.type)},null,8,ip)],2)),a("span",ap,V(i.message),1)])]))),128))]),_:1})])]))}},up={class:"grid h-[100dvh] place-items-center overflow-y-auto bg-slate-50 p-4 text-slate-700 dark:bg-slate-950 dark:text-slate-200"},fp={class:"mb-7 flex items-center gap-3"},dp=["src"],pp=["disabled"],hp={__name:"AccessGate",setup(e){const t=oe(""),s=()=>{t.value.trim()&&(md(t.value),window.location.reload())};return(n,o)=>(y(),E("main",up,[a("form",{class:"w-full max-w-md rounded-2xl border border-slate-200 bg-white p-6 shadow-sm sm:p-8 dark:border-slate-800 dark:bg-slate-900",onSubmit:ls(s,["prevent"])},[a("div",fp,[a("img",{src:O(ml),alt:"",class:"h-10 w-10 shrink-0"},null,8,dp),o[1]||(o[1]=a("div",null,[a("h1",{class:"text-lg font-bold text-slate-900 dark:text-white"},"访问 VNT 控制台"),a("p",{class:"mt-0.5 text-xs text-slate-400"},"请输入桌面端 Web 访问设置中的令牌")],-1))]),o[2]||(o[2]=a("label",{class:"mb-2 block text-sm font-medium text-slate-700 dark:text-slate-200",for:"access-token"},"访问令牌",-1)),me(a("input",{id:"access-token","onUpdate:modelValue":o[0]||(o[0]=l=>t.value=l),class:"input font-mono",type:"password",autocomplete:"current-password",autofocus:"",placeholder:"粘贴访问令牌"},null,512),[[Oe,t.value]]),a("button",{class:"btn-primary mt-5 w-full",type:"submit",disabled:!t.value.trim()},"进入控制台",8,pp),o[3]||(o[3]=a("p",{class:"mt-5 text-center text-xs leading-5 text-slate-400"},"令牌只保存在当前浏览器中,可随时在桌面端重新生成。",-1))],32)]))}},mp={key:1,class:"flex h-[100dvh] min-h-0 overflow-hidden bg-slate-50 text-slate-700 dark:bg-slate-950 dark:text-slate-200"},gp={class:"hidden w-60 shrink-0 border-r border-slate-200 dark:border-slate-800 lg:block"},vp={key:0,class:"fixed inset-0 z-40 lg:hidden"},bp={class:"drawer-panel relative h-full w-[min(82vw,288px)] border-r border-slate-200 shadow-2xl dark:border-slate-700"},_p={class:"flex min-w-0 flex-1 flex-col"},xp={class:"flex h-16 shrink-0 items-center gap-3 border-b border-slate-200 bg-white/90 px-4 backdrop-blur lg:px-6 dark:border-slate-800 dark:bg-slate-900/90"},yp={class:"min-w-0"},kp={class:"truncate text-lg font-bold text-slate-900 dark:text-white"},wp={class:"ml-auto flex items-center gap-2"},Cp={class:"flex h-8 items-center gap-2 rounded-lg border border-slate-200 bg-white px-2.5 text-xs font-medium text-slate-500 sm:px-3 dark:border-slate-700 dark:bg-slate-800 dark:text-slate-300"},Sp={class:"hidden sm:inline"},Ep=["title","aria-label"],Tp={key:0,class:"h-4 w-4 fill-none stroke-current",viewBox:"0 0 24 24"},Ap={key:1,class:"h-4 w-4 fill-none stroke-current",viewBox:"0 0 24 24"},$p={class:"custom-scrollbar min-h-0 flex-1 overflow-x-hidden overflow-y-auto"},Ip={class:"mx-auto w-full max-w-7xl px-4 py-5 sm:px-5 lg:px-7 lg:py-6"},Rp={class:"flex min-w-0 items-center gap-3"},Pp={class:"truncate text-base font-bold text-slate-900 sm:text-lg dark:text-white"},Op={class:"max-w-[40%] truncate font-mono text-xs text-indigo-600 dark:text-indigo-400"},Mp={class:"break-all"},Lp={key:0,class:"animate-pulse text-indigo-600 dark:text-indigo-400"},Np={__name:"App",setup(e){const t=Mt(),s=va(),n=pa(),o=hd(),l=oe(null);Us("peerTooltip",l);const r=oe(!1),i=ba(),c=_e(()=>i.find(C=>C.to===n.path)||i[0]),f=localStorage.getItem("vnt-theme"),u=oe(f?f==="dark":window.matchMedia("(prefers-color-scheme: dark)").matches),d=()=>document.documentElement.classList.toggle("dark",u.value),g=()=>{u.value=!u.value,localStorage.setItem("vnt-theme",u.value?"dark":"light"),d()};d(),Be(()=>n.path,()=>{r.value=!1});const h=C=>{if(!(C.ctrlKey||C.metaKey)||C.altKey)return;const x=Number(C.key)-1;x>=0&&x<i.length&&(C.preventDefault(),o.push(i[x].to))};return Ot(()=>window.addEventListener("keydown",h)),tl(()=>window.removeEventListener("keydown",h)),(C,x)=>{const L=Un("router-view");return!O(Jn)&&!O(pl)?(y(),Ie(hp,{key:0})):(y(),E("div",mp,[a("aside",gp,[ue(Cr)]),ue(Ro,{name:"drawer"},{default:Ae(()=>[r.value?(y(),E("div",vp,[a("button",{class:"absolute inset-0 bg-slate-950/45 backdrop-blur-[2px]","aria-label":"关闭导航",onClick:x[0]||(x[0]=w=>r.value=!1)}),a("aside",bp,[ue(Cr,{onNavigate:x[1]||(x[1]=w=>r.value=!1)})])])):fe("",!0)]),_:1}),a("div",_p,[a("header",xp,[a("button",{class:"grid h-9 w-9 shrink-0 place-items-center rounded-lg text-slate-500 hover:bg-slate-100 hover:text-slate-900 lg:hidden dark:text-slate-400 dark:hover:bg-slate-800 dark:hover:text-white","aria-label":"打开导航",onClick:x[2]||(x[2]=w=>r.value=!0)},[...x[5]||(x[5]=[a("svg",{class:"h-5 w-5 fill-none stroke-current",viewBox:"0 0 24 24"},[a("path",{d:"M4 7h16M4 12h16M4 17h16","stroke-linecap":"round","stroke-width":"2"})],-1)])]),a("div",yp,[a("h1",kp,V(c.value.label),1),x[6]||(x[6]=a("p",{class:"hidden text-xs text-slate-400 sm:block"},"VNT 虚拟局域网管理",-1))]),a("div",wp,[a("div",Cp,[a("span",{class:G(["h-1.5 w-1.5 rounded-full",O(t).runningCount>0?"bg-green-500":O(t).startingCount>0?"animate-pulse bg-amber-400":"bg-slate-300 dark:bg-slate-600"])},null,2),a("span",Sp,V(O(t).headerStatusText),1)]),a("button",{class:"grid h-8 w-8 place-items-center rounded-lg border border-slate-200 bg-white text-slate-500 hover:border-indigo-300 hover:text-indigo-600 dark:border-slate-700 dark:bg-slate-800 dark:text-slate-400 dark:hover:border-indigo-500 dark:hover:text-indigo-400",title:u.value?"切换浅色模式":"切换深色模式","aria-label":u.value?"切换浅色模式":"切换深色模式",onClick:g},[u.value?(y(),E("svg",Tp,[...x[7]||(x[7]=[a("circle",{cx:"12",cy:"12",r:"4"},null,-1),a("path",{d:"M12 2v2m0 16v2M4.9 4.9l1.4 1.4m11.4 11.4 1.4 1.4M2 12h2m16 0h2M4.9 19.1l1.4-1.4M17.7 6.3l1.4-1.4","stroke-linecap":"round","stroke-width":"1.7"},null,-1)])])):(y(),E("svg",Ap,[...x[8]||(x[8]=[a("path",{d:"M20.5 15.2A8.5 8.5 0 0 1 8.8 3.5 8.5 8.5 0 1 0 20.5 15.2Z","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"1.7"},null,-1)])]))],8,Ep)])]),a("main",$p,[a("div",Ip,[ue(L,null,{default:Ae(({Component:w})=>[ue(Ro,{name:"fade",mode:"out-in"},{default:Ae(()=>[(y(),Ie(Rc(w)))]),_:2},1024)]),_:1})])])]),ue(gl,{show:O(s).showStartLog,"mask-closable":O(s).startStatus!=="starting","esc-closable":O(s).startStatus!=="starting","panel-class":"w-full max-w-2xl",onClose:O(s).close},{header:Ae(()=>[a("div",Rp,[a("span",{class:G(["h-2 w-2 shrink-0 rounded-full",O(s).startStatus==="starting"?"animate-pulse bg-amber-400":O(s).startStatus==="running"?"bg-green-500":"bg-red-500"])},null,2),a("h3",Pp,V(O(s).startStatus==="starting"?"正在建立虚拟网络":O(s).startStatus==="running"?"网络已连接":"连接未完成"),1)]),a("span",Op,V(O(s).logConfigName),1)]),body:Ae(()=>[a("div",{ref:w=>O(s).logContainer=w,class:"custom-scrollbar h-64 space-y-2 overflow-y-auto border-y border-slate-200 bg-slate-50 p-4 font-mono text-xs text-slate-600 sm:h-80 sm:p-6 dark:border-slate-800 dark:bg-slate-950 dark:text-slate-300"},[(y(!0),E(ie,null,Ee(O(s).startLogs,(w,p)=>(y(),E("div",{key:p,class:"flex gap-3"},[x[9]||(x[9]=a("span",{class:"text-indigo-600 dark:text-indigo-400"},"",-1)),a("span",Mp,V(w),1)]))),128)),O(s).startStatus==="starting"?(y(),E("div",Lp,"等待下一阶段…")):fe("",!0)],512)]),footer:Ae(()=>[O(s).startStatus==="starting"?(y(),E("button",{key:0,class:"btn-ghost",onClick:x[3]||(x[3]=(...w)=>O(s).cancelStart&&O(s).cancelStart(...w))},"取消连接")):(y(),E("button",{key:1,class:"btn-primary",onClick:x[4]||(x[4]=(...w)=>O(s).close&&O(s).close(...w))},"完成"))]),_:1},8,["show","mask-closable","esc-closable","onClose"]),ue(cp),ue(op),ue(ep,{ref_key:"tooltipRef",ref:l},null,512)]))}}},Vp={class:"card"},jp={key:0,class:"flex flex-wrap items-center justify-between gap-3"},Dp={key:1,class:"text-sm muted"},Bp={key:2,class:"flex flex-col gap-3 sm:flex-row sm:items-end"},Fp={class:"flex-1"},Up=["value"],Hp=["disabled"],Wp={key:0,class:"animate-spin"},_a={__name:"StartPanel",setup(e){const t=Mt(),s=as(),n=oe(""),o=_e(()=>t.configList.filter(r=>!t.instanceList.some(i=>i.file_name===r.file_name)));Be(o,r=>{r.some(i=>i.file_name===n.value)||(n.value=r.length?r[0].file_name:"")},{immediate:!0});const l=()=>{if(!n.value){s.toast.error("请先选择一个配置");return}t.startVnt(n.value)};return(r,i)=>{const c=Un("router-link");return y(),E("div",Vp,[i[6]||(i[6]=a("h2",{class:"mb-4 text-base font-bold text-slate-900 dark:text-white"},"启动组网",-1)),O(t).configList.length===0?(y(),E("div",jp,[i[2]||(i[2]=a("p",{class:"text-sm muted"},"还没有任何配置,先创建一个组网配置吧。",-1)),ue(c,{to:"/config",class:"btn-primary btn-sm"},{default:Ae(()=>[...i[1]||(i[1]=[ae("去新建配置",-1)])]),_:1})])):o.value.length===0?(y(),E("div",Dp," 所有配置均已启动。 ")):(y(),E("div",Bp,[a("div",Fp,[i[4]||(i[4]=a("label",{class:"mb-1.5 block text-xs font-medium muted"},"选择配置",-1)),me(a("select",{"onUpdate:modelValue":i[0]||(i[0]=f=>n.value=f),class:"input"},[i[3]||(i[3]=a("option",{value:"",disabled:""},"请选择配置...",-1)),(y(!0),E(ie,null,Ee(o.value,f=>(y(),E("option",{key:f.file_name,value:f.file_name},V(f.config_name||f.file_name),9,Up))),128))],512),[[cl,n.value]])]),a("button",{class:"btn-primary px-8",disabled:!n.value||!!O(t).loadingMap[n.value],onClick:l},[O(t).loadingMap[n.value]?(y(),E("span",Wp,"⟳")):fe("",!0),i[5]||(i[5]=ae(" 启动 ",-1))],8,Hp)]))])}}},Kp={class:"flex items-center justify-between gap-2"},Gp=["title"],qp={class:"flex shrink-0 items-center gap-1.5"},zp={key:0,class:"badge-yellow",title:"配置文件在启动后被修改,重启实例后生效"},Zp={class:"mt-2 text-sm"},Jp={class:"ml-1 font-mono tabular-nums text-indigo-600 dark:text-indigo-400"},Yp={class:"mt-3 flex gap-4 text-xs muted"},Qp={class:"font-bold tabular-nums text-blue-600 dark:text-blue-400"},Xp={class:"font-bold tabular-nums text-green-600 dark:text-green-400"},e0={class:"font-bold tabular-nums text-slate-400"},t0={class:"mt-4 flex flex-wrap justify-end gap-2"},s0={key:0,class:"flex items-center gap-1.5 text-xs muted"},n0=["disabled"],o0={key:0,class:"animate-spin"},l0=["disabled"],r0={key:0,class:"animate-spin"},i0=["disabled"],a0={key:0,class:"animate-spin"},xa={__name:"InstanceCard",props:{inst:{type:Object,required:!0},selectable:{type:Boolean,default:!1}},setup(e){const t=e,s=Mt(),n=as(),o=_e(()=>s.infoOf(t.inst.file_name)),l=_e(()=>!!s.loadingMap[t.inst.file_name]),r=_e(()=>!!s.stoppingMap[t.inst.file_name]),i=_e(()=>t.inst.config_name||t.inst.file_name),c=C=>r.value?"badge-yellow":C==="running"?"badge-green":C==="starting"?"badge-blue":"badge-gray",f=C=>r.value?"停止中":C==="running"?"运行中":C==="starting"?"启动中":"已停止",u=()=>{t.selectable&&(s.selectedInstance=t.inst.file_name)},d=async()=>{await n.confirm({title:"停止组网",message:`确定要停止 ${i.value} 吗?`,danger:!0,confirmText:"停止"})&&s.stopVnt(t.inst.file_name)},g=async()=>{await n.confirm({title:"重启组网",message:`确定要重启 ${i.value} 吗?`})&&s.restartVnt(t.inst.file_name)},h=async()=>{await n.confirm({title:"移除实例",message:`确定要移除已停止的实例 ${i.value} 吗?`,danger:!0,confirmText:"移除"})&&s.dismissInstance(t.inst.file_name)};return(C,x)=>(y(),E("div",{class:G(["card",[e.selectable?"cursor-pointer":"",e.selectable&&O(s).selectedInstance===e.inst.file_name?"ring-2 ring-indigo-500 dark:ring-indigo-400":""]]),onClick:u},[a("div",Kp,[a("h3",{class:"truncate text-base font-bold text-slate-900 dark:text-white",title:e.inst.file_name},V(i.value),9,Gp),a("div",qp,[o.value.config_changed?(y(),E("span",zp," 配置发生变化 ")):fe("",!0),a("span",{class:G([c(e.inst.status),r.value?"animate-pulse":""])},V(f(e.inst.status)),3)])]),a("div",Zp,[x[0]||(x[0]=a("span",{class:"muted"},"虚拟 IP:",-1)),a("span",Jp,V(o.value.ip||"-"),1)]),a("div",Yp,[a("span",null,[x[1]||(x[1]=ae(" 在线 ",-1)),a("span",Qp,V(o.value.online_client_num||0),1)]),a("span",null,[x[2]||(x[2]=ae(" 直连 ",-1)),a("span",Xp,V(o.value.direct_client_num||0),1)]),a("span",null,[x[3]||(x[3]=ae(" 离线 ",-1)),a("span",e0,V(o.value.offline_client_num||0),1)])]),a("div",t0,[r.value?(y(),E("span",s0,[...x[4]||(x[4]=[a("span",{class:"inline-block animate-spin"},"⟳",-1),ae(" 正在停止,请稍候... ",-1)])])):(y(),E(ie,{key:1},[e.inst.status==="running"||e.inst.status==="stopped"?(y(),E("button",{key:0,class:"btn-primary btn-sm",disabled:l.value,onClick:ls(g,["stop"])},[l.value?(y(),E("span",o0,"⟳")):fe("",!0),ae(" "+V(e.inst.status==="stopped"?"重新启动":"重启"),1)],8,n0)):fe("",!0),e.inst.status!=="stopped"?(y(),E("button",{key:1,class:"btn-danger btn-sm",disabled:l.value,onClick:ls(d,["stop"])},[l.value?(y(),E("span",r0,"⟳")):fe("",!0),x[5]||(x[5]=ae(" 停止 ",-1))],8,l0)):fe("",!0),e.inst.status==="stopped"?(y(),E("button",{key:2,class:"btn-ghost btn-sm",disabled:l.value,onClick:ls(h,["stop"])},[l.value?(y(),E("span",a0,"⟳")):fe("",!0),x[6]||(x[6]=ae(" 移除 ",-1))],8,i0)):fe("",!0)],64))])],2))}},c0={class:"card p-12 text-center text-slate-500 dark:text-slate-400"},an={__name:"EmptyState",props:{text:{type:String,default:"暂无数据"}},setup(e){return(t,s)=>(y(),E("div",c0,[s[0]||(s[0]=a("svg",{class:"w-12 h-12 mx-auto mb-3 text-slate-300 dark:text-slate-600",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"1.5",d:"M20 13V6a2 2 0 00-2-2H6a2 2 0 00-2 2v7m16 0v5a2 2 0 01-2 2H6a2 2 0 01-2-2v-5m16 0h-2.586a1 1 0 00-.707.293l-2.414 2.414a1 1 0 01-.707.293h-3.172a1 1 0 01-.707-.293l-2.414-2.414A1 1 0 006.586 13H4"})],-1)),a("p",null,V(e.text),1)]))}},u0={class:"space-y-6"},f0={class:"flex flex-wrap items-end justify-between gap-4"},d0={class:"page-subtitle"},p0={class:"grid grid-cols-2 gap-4 lg:grid-cols-4"},h0={class:"card"},m0={class:"mt-2 text-2xl font-bold tabular-nums text-slate-900 dark:text-white"},g0={class:"ml-1 text-sm font-normal muted"},v0={class:"card"},b0={class:"mt-2 text-2xl font-bold tabular-nums text-slate-900 dark:text-white"},_0={class:"card"},x0={class:"mt-2 text-2xl font-bold tabular-nums text-slate-900 dark:text-white"},y0={class:"card"},k0={class:"mt-2 text-2xl font-bold tabular-nums text-slate-900 dark:text-white"},w0={class:"text-sm font-normal muted"},C0={key:1,class:"muted"},S0={class:"mb-3 flex items-center justify-between"},E0={__name:"DashboardView",setup(e){const t=Mt(),s=_e(()=>Object.values(t.instances).reduce((l,r)=>l+(r?.online_client_num||0),0)),n=_e(()=>{const l=t.instanceList.filter(i=>i.status==="running");return{connected:l.filter(i=>t.instances[i.file_name]?.server_info?.some(f=>f.connected)).length,total:l.length}}),o=_e(()=>t.runningCount>0?`运行中 ${t.runningCount} 个实例`:t.startingCount>0?"有实例正在启动...":"全部实例已停止");return(l,r)=>{const i=Un("router-link");return y(),E("div",u0,[a("div",f0,[a("div",null,[r[0]||(r[0]=a("h1",{class:"page-title"},"总览",-1)),a("p",d0,V(o.value),1)]),ue(i,{to:"/config",class:"btn-ghost btn-sm"},{default:Ae(()=>[...r[1]||(r[1]=[ae("管理配置",-1)])]),_:1})]),a("div",p0,[a("div",h0,[r[2]||(r[2]=a("div",{class:"text-xs font-medium muted"},"运行实例",-1)),a("div",m0,[ae(V(O(t).runningCount),1),a("span",g0,"/ "+V(O(t).instanceList.length),1)])]),a("div",v0,[r[3]||(r[3]=a("div",{class:"text-xs font-medium muted"},"配置总数",-1)),a("div",b0,V(O(t).configList.length),1)]),a("div",_0,[r[4]||(r[4]=a("div",{class:"text-xs font-medium muted"},"在线设备",-1)),a("div",x0,V(s.value),1)]),a("div",y0,[r[5]||(r[5]=a("div",{class:"text-xs font-medium muted"},"服务器连接",-1)),a("div",k0,[n.value.total>0?(y(),E(ie,{key:0},[a("span",{class:G(n.value.connected>0?"text-green-600 dark:text-green-400":"text-red-500")},V(n.value.connected),3),a("span",w0,"/ "+V(n.value.total)+" 已连接",1)],64)):(y(),E("span",C0,"-"))])])]),ue(_a),a("div",null,[a("div",S0,[r[7]||(r[7]=a("h2",{class:"text-base font-bold text-slate-900 dark:text-white"},"实例概览",-1)),ue(i,{to:"/instances",class:"text-sm font-medium text-indigo-600 hover:text-indigo-500 dark:text-indigo-400"},{default:Ae(()=>[...r[6]||(r[6]=[ae("查看详情 →",-1)])]),_:1})]),O(t).instanceList.length===0?(y(),Ie(an,{key:0,text:O(t).configList.length===0?"暂无配置,请先新建配置":"暂无运行中的组网,请在上方选择配置启动"},null,8,["text"])):(y(),Ie(al,{key:1,name:"card-list",tag:"div",class:"grid grid-cols-1 gap-4 md:grid-cols-2"},{default:Ae(()=>[(y(!0),E(ie,null,Ee(O(t).instanceList,c=>(y(),Ie(xa,{key:c.file_name,inst:c},null,8,["inst"]))),128))]),_:1}))])])}}},T0={class:"space-y-6"},A0={class:"card"},$0={class:"mb-4 text-lg font-bold text-slate-900 dark:text-white"},I0={class:"ml-2 text-sm font-medium text-indigo-600 dark:text-indigo-400"},R0={class:"grid grid-cols-1 gap-4 text-sm md:grid-cols-2"},P0={class:"flex justify-between border-b border-slate-100 pb-2 dark:border-slate-700"},O0={class:"font-mono tabular-nums text-slate-900 dark:text-white"},M0={class:"flex justify-between border-b border-slate-100 pb-2 dark:border-slate-700"},L0={class:"font-mono text-slate-900 dark:text-white"},N0={class:"flex justify-between border-b border-slate-100 pb-2 dark:border-slate-700"},V0={class:"font-mono text-slate-900 dark:text-white"},j0={class:"flex justify-between border-b border-slate-100 pb-2 dark:border-slate-700"},D0={class:"font-mono tabular-nums text-slate-900 dark:text-white"},B0={class:"flex justify-between border-b border-slate-100 pb-2 dark:border-slate-700"},F0={class:"font-mono text-indigo-600 dark:text-indigo-400"},U0={class:"flex justify-between border-b border-slate-100 pb-2 dark:border-slate-700"},H0=["title"],W0={class:"flex justify-between border-b border-slate-100 pb-2 dark:border-slate-700"},K0={class:"text-slate-900 dark:text-white"},G0={class:"flex justify-between border-b border-slate-100 pb-2 dark:border-slate-700"},q0=["title"],z0={class:"mt-4 grid grid-cols-2 gap-3 md:grid-cols-4"},Z0={class:"text-sm text-slate-600 dark:text-slate-300"},J0={class:"mt-4"},Y0={class:"flex flex-wrap gap-2"},Q0={key:0,class:"text-xs text-slate-400"},X0={class:"card p-0 overflow-hidden"},eh={class:"custom-scrollbar max-h-[400px] overflow-x-auto"},th={class:"table"},sh={class:"font-mono"},nh={class:"tabular-nums"},oh={key:0},lh={__name:"InstancesView",setup(e){const t=Mt();return(s,n)=>(y(),E("div",T0,[n[13]||(n[13]=a("div",null,[a("h1",{class:"page-title"},"实例"),a("p",{class:"page-subtitle"},"管理组网实例,点击卡片查看详情")],-1)),ue(_a),O(t).instanceList.length===0?(y(),Ie(an,{key:0,text:"暂无运行中的组网,请在上方选择配置启动"})):(y(),Ie(al,{key:1,name:"card-list",tag:"div",class:"grid grid-cols-1 gap-4 md:grid-cols-2"},{default:Ae(()=>[(y(!0),E(ie,null,Ee(O(t).instanceList,o=>(y(),Ie(xa,{key:o.file_name,inst:o,selectable:""},null,8,["inst"]))),128))]),_:1})),O(t).selectedInstance&&O(t).selectedInfo?(y(),E(ie,{key:2},[a("div",A0,[a("h2",$0,[n[0]||(n[0]=ae(" 网络详情 ",-1)),a("span",I0,V(O(t).selectedConfigName),1)]),a("div",R0,[a("div",P0,[n[1]||(n[1]=a("span",{class:"muted"},"虚拟 IP / 掩码",-1)),a("span",O0,V(O(t).selectedInfo.ip||"-")+" / "+V(O(t).selectedInfo.prefix_len||"-"),1)]),a("div",M0,[n[2]||(n[2]=a("span",{class:"muted"},"网关",-1)),a("span",L0,V(O(t).selectedInfo.gateway||"-"),1)]),a("div",N0,[n[3]||(n[3]=a("span",{class:"muted"},"网络编号",-1)),a("span",V0,V(O(t).selectedInfo.network_code||"-"),1)]),a("div",j0,[n[4]||(n[4]=a("span",{class:"muted"},"MTU",-1)),a("span",D0,V(O(t).selectedInfo.mtu||""),1)]),a("div",B0,[n[5]||(n[5]=a("span",{class:"muted"},"NAT 类型",-1)),a("span",F0,V(O(t).selectedInfo.nat_type||"Unknown"),1)]),a("div",U0,[n[6]||(n[6]=a("span",{class:"muted"},"Public IPv6",-1)),a("span",{class:"max-w-[200px] truncate font-mono text-slate-900 dark:text-white",title:O(t).selectedInfo.public_ipv6},V(O(t).selectedInfo.public_ipv6||"-"),9,H0)]),a("div",W0,[n[7]||(n[7]=a("span",{class:"muted"},"设备名称",-1)),a("span",K0,V(O(t).selectedInfo.name||"-"),1)]),a("div",G0,[n[8]||(n[8]=a("span",{class:"muted"},"设备 ID",-1)),a("span",{class:"max-w-[200px] truncate font-mono text-xs text-slate-500 dark:text-slate-400",title:O(t).selectedInfo.device_id},V(O(t).selectedInfo.device_id||"-"),9,q0)])]),a("div",z0,[(y(),E(ie,null,Ee([{key:"encrypt",label:"加密"},{key:"compress",label:"压缩"},{key:"fec",label:"FEC纠错"},{key:"rtx",label:"QUIC传输"}],o=>a("div",{key:o.key,class:"flex items-center gap-2 rounded-lg bg-slate-50 px-3 py-2 dark:bg-slate-800/50"},[a("span",{class:G(["h-2 w-2 rounded-full",O(t).selectedInfo[o.key]?"bg-green-500":"bg-slate-300 dark:bg-slate-600"])},null,2),a("span",Z0,V(o.label),1)])),64))]),a("div",J0,[n[9]||(n[9]=a("span",{class:"mb-2 block text-sm muted"},"Public IPv4s",-1)),a("div",Y0,[(y(!0),E(ie,null,Ee(O(t).selectedInfo.public_ipv4s,o=>(y(),E("span",{key:o,class:"rounded border border-slate-200 bg-slate-50 px-2 py-1 font-mono text-xs tabular-nums text-green-700 dark:border-slate-600 dark:bg-slate-800 dark:text-green-300"},V(o),1))),128)),!O(t).selectedInfo.public_ipv4s||O(t).selectedInfo.public_ipv4s.length===0?(y(),E("span",Q0,"无")):fe("",!0)])])]),a("div",X0,[n[12]||(n[12]=a("div",{class:"border-b border-slate-200 px-6 py-4 dark:border-slate-700"},[a("h2",{class:"text-lg font-bold text-slate-900 dark:text-white"},"服务器连接列表")],-1)),a("div",eh,[a("table",th,[n[11]||(n[11]=a("thead",null,[a("tr",null,[a("th",null,"地址"),a("th",null,"状态"),a("th",null,"延迟"),a("th",null,"版本")])],-1)),a("tbody",null,[(y(!0),E(ie,null,Ee(O(t).selectedInfo.server_info,(o,l)=>(y(),E("tr",{key:l},[a("td",sh,V(o.server),1),a("td",null,[a("span",{class:G(o.connected?"badge-green":"badge-red")},V(o.connected?"已连接":"未连接"),3)]),a("td",nh,V(o.server_rtt?o.server_rtt+" ms":"-"),1),a("td",null,V(o.server_version||"-"),1)]))),128)),!O(t).selectedInfo.server_info||O(t).selectedInfo.server_info.length===0?(y(),E("tr",oh,[...n[10]||(n[10]=[a("td",{colspan:"4",class:"text-center text-slate-400"},"暂无数据",-1)])])):fe("",!0)])])])])],64)):fe("",!0)]))}},Bo=()=>({config_name:"",network_code:"",server:[""],ip:"",mtu:null,rtx:!1,fec:!1,compress:!1,no_punch:!1,input:[],output:[],no_nat:!1,no_tun:!1,port_mapping:[],allow_mapping:!1,device_name:"",device_id:"",tun_name:"",password:"",cert_mode:"skip",fingerprint:"",udp_stun:[],tcp_stun:[],tunnel_port:null}),Sr=e=>{const t=Bo(),s=e.split(`
`);for(const n of s){const o=n.trim();if(!(!o||o.startsWith("#"))){if(o.includes("config_name")){const l=o.match(/config_name\s*=\s*"([^"]*)"/);l&&(t.config_name=l[1])}else if(o.includes("network_code")){const l=o.match(/network_code\s*=\s*"([^"]*)"/);l&&(t.network_code=l[1])}else if(o.startsWith("server")){const l=o.match(/server\s*=\s*\[(.*)\]/);if(l){const r=l[1].match(/"([^"]*)"/g);r&&(t.server=r.map(i=>i.replace(/"/g,"")))}}else if(o.includes("ip =")){const l=o.match(/ip\s*=\s*"([^"]*)"/);l&&(t.ip=l[1])}else if(o.includes("mtu =")){const l=o.match(/mtu\s*=\s*(\d+)/);l&&(t.mtu=parseInt(l[1]))}else if(o.match(/^rtx\s*=/))t.rtx=o.includes("true");else if(o.match(/^fec\s*=/))t.fec=o.includes("true");else if(o.match(/^compress\s*=/))t.compress=o.includes("true");else if(o.match(/^no_punch\s*=/))t.no_punch=o.includes("true");else if(o.startsWith("input")){const l=o.match(/input\s*=\s*\[(.*)\]/);if(l){const r=l[1].match(/"([^"]*)"/g);r&&(t.input=r.map(i=>i.replace(/"/g,"")))}}else if(o.startsWith("output")){const l=o.match(/output\s*=\s*\[(.*)\]/);if(l){const r=l[1].match(/"([^"]*)"/g);r&&(t.output=r.map(i=>i.replace(/"/g,"")))}}else if(o.match(/^no_nat\s*=/))t.no_nat=o.includes("true");else if(o.match(/^no_tun\s*=/))t.no_tun=o.includes("true");else if(o.startsWith("port_mapping")){const l=o.match(/port_mapping\s*=\s*\[(.*)\]/);if(l){const r=l[1].match(/"([^"]*)"/g);r&&(t.port_mapping=r.map(i=>i.replace(/"/g,"")))}}else if(o.match(/^allow_mapping\s*=/))t.allow_mapping=o.includes("true");else if(o.includes("device_name")){const l=o.match(/device_name\s*=\s*"([^"]*)"/);l&&(t.device_name=l[1])}else if(o.includes("device_id")){const l=o.match(/device_id\s*=\s*"([^"]*)"/);l&&(t.device_id=l[1])}else if(o.includes("tun_name")){const l=o.match(/tun_name\s*=\s*"([^"]*)"/);l&&(t.tun_name=l[1])}else if(o.includes("password =")){const l=o.match(/password\s*=\s*"([^"]*)"/);l&&(t.password=l[1])}else if(o.includes("cert_mode")){const l=o.match(/cert_mode\s*=\s*"([^"]*)"/);if(l){const r=l[1];r.startsWith("finger:")?(t.cert_mode="finger",t.fingerprint=r.substring(7)):t.cert_mode=r}}else if(o.startsWith("udp_stun")){const l=o.match(/udp_stun\s*=\s*\[(.*)\]/);if(l){const r=l[1].match(/"([^"]*)"/g);r&&(t.udp_stun=r.map(i=>i.replace(/"/g,"")))}}else if(o.startsWith("tcp_stun")){const l=o.match(/tcp_stun\s*=\s*\[(.*)\]/);if(l){const r=l[1].match(/"([^"]*)"/g);r&&(t.tcp_stun=r.map(i=>i.replace(/"/g,"")))}}}}return t},_o=e=>{let t="";e.config_name&&(t+=`# 配置名称
config_name = "${e.config_name}"
`),t+=`
# --- 网络配置 ---
`,t+=`# 网络编号,相同网络编号的会组在同一个虚拟网 (必填)
`,t+=`network_code = "${e.network_code}"
`;const s=e.server.filter(c=>c.trim());s.length>0&&(t+=`# 服务器地址列表(支持 quic / tcp / wss / dynamic) (必填)
`,t+=`# dynamic 协议使用dns txt解析记录值
`,t+=`server = [${s.map(c=>`"${c}"`).join(", ")}]
`),e.ip&&(t+=`
# 自定义虚拟 IP (可选)
`,t+=`ip = "${e.ip}"
`),e.rtx&&(t+=`
# 是否启用quic优化传输 (默认 false)
`,t+=`# 开启后传输过程几乎不会丢包,但是延迟可能会有波动
`,t+=`rtx = true
`),e.fec&&(t+=`
# 是否启用 FEC 前向纠错 (默认 false)
`,t+=`# 开启后可以减少丢包率,损失带宽但是延迟比较稳定,带宽充足时可以使用此功能
`,t+=`fec = true
`),e.no_punch&&(t+=`
# 是否关闭 P2P 打洞 (默认 false)
`,t+=`no_punch = true
`),e.compress&&(t+=`
# 是否启用 LZ4 压缩 (默认 false)
`,t+=`compress = true
`);const n=e.input.filter(c=>c.trim());n.length>0&&(t+=`
# 入栈监听网段 (逗号分隔的 CIDR 和目标 IP),用于点对网,将指定网段的流量发送到目标节点
`,t+=`# 例如192.168.0.0/24,10.26.0.2 表示将192.168.0.0/24网段的数据转发到10.26.0.2
`,t+=`input = [${n.map(c=>`"${c}"`).join(", ")}]
`);const o=e.output.filter(c=>c.trim());o.length>0&&(t+=`
# 出栈允许网段,用于点对网,允许指定网段的转发
`,t+=`output = [${o.map(c=>`"${c}"`).join(", ")}]
`),e.no_nat&&(t+=`
# 是否关闭内置子网NAT,关闭后需要配置网卡转发,否则无法使用点对网
`,t+=`# 通常关闭内置子网NAT,使用系统的网卡转发,点对网性能会更好
`,t+=`no_nat = true
`),e.no_tun&&(t+=`
# 是否关闭TUN虚拟网卡,关闭后只能充当流量出口或者进行端口映射,关闭后无需管理员权限
`,t+=`no_tun = true
`);const l=e.port_mapping.filter(c=>c.trim());l.length>0&&(t+=`
# 端口映射,格式为:协议://本地监听地址-目标虚拟IP-目标映射地址
`,t+=`# 端口映射用于在本地监听指定端口,并将收到的网络流量经由指定虚拟节点转发到目标地址
`,t+=`# 例如: tcp://0.0.0.0:81-10.0.0.2-10.0.0.2:80 表示将本地tcp的81端口的数据转发到10.0.0.2:80
`,t+=`# 例如: tcp://0.0.0.0:81-10.0.0.2-192.168.1.10:80 则表示将本地tcp的81端口的数据经过10.0.0.2转到192.168.1.10:80
`,t+=`# 例如: tcp://0.0.0.0:81-10.0.0.2-anyonehost:80 则表示将本地tcp的81端口的数据经过10.0.0.2转到anyonehost:80
`,t+=`port_mapping = [${l.map(c=>`"${c}"`).join(", ")}]
`),e.allow_mapping&&(t+=`
# 是否允许作为端口映射出口,开启后其他设备才可使用本设备的ip为"目标虚拟IP"
`,t+=`# 开启后虚拟网络其他设备可以使用此设备当跳板访问其他网络
`,t+=`allow_mapping = true
`),e.mtu&&(t+=`
# MTU 设置
`,t+=`mtu = ${e.mtu}
`),t+=`
# --- 设备配置 ---
`,e.device_name&&(t+=`
# 设备名称 (可选,默认读取本机 hostname)
`,t+=`device_name = "${e.device_name}"
`),e.device_id&&(t+=`
# 设备 ID (可选,不填自动生成,不同设备ID不能相同)
`,t+=`device_id = "${e.device_id}"
`),e.tun_name&&(t+=`
# 虚拟网卡名称
`,t+=`tun_name = "${e.tun_name}"
`),t+=`
# --- 安全配置 ---
`,e.password&&(t+=`
# 组网加密密码 (可选)
`,t+=`password = "${e.password}"
`),e.cert_mode&&e.cert_mode!=="skip"&&(t+=`
# 证书校验方式:
`,t+=`# skip 跳过验证(默认)
`,t+=`# standard 使用系统证书验证
`,t+=`# finger 使用证书指纹验证,服务端启动时日志会输出指纹
`,e.cert_mode==="finger"&&e.fingerprint?t+=`cert_mode = "finger:${e.fingerprint}"
`:t+=`cert_mode = "${e.cert_mode}"
`);const r=e.udp_stun.filter(c=>c.trim());r.length>0&&(t+=`
# 自定义UDP STUN地址,不设置则用默认stun
`,t+=`udp_stun = [${r.map(c=>`"${c}"`).join(", ")}]
`);const i=e.tcp_stun.filter(c=>c.trim());return i.length>0&&(t+=`
# 自定义TCP STUN地址,不设置则用默认stun
`,t+=`tcp_stun = [${i.map(c=>`"${c}"`).join(", ")}]
`),t},rh=`# config_name = "配置名称"
# --- 网络配置 ---
# 网络编号,相同网络编号的会组在同一个虚拟网 (必填)
network_code = "your_network_code"
# 服务器地址列表(支持 quic / tcp / wss / dynamic) (必填)
# dynamic 协议使用dns txt解析记录值
server = ["quic://1.2.3.4:29872"]
# ===简单使用以下参数可以不动===
# 自定义虚拟 IP (可选)
# ip = "10.10.0.2"
# 是否启用quic优化传输 (默认 false,设置为true时开启)
# 开启后传输过程几乎不会丢包,但是延迟会有波动
# rtx = false
# 是否启用 FEC 前向纠错,损失一定带宽来提升网络稳定性(默认 false,设置为true时开启)
# 开启后可以减少丢包率,损失带宽但是延迟比较稳定,带宽充足时可以使用此功能
# fec = false
# 是否关闭 P2P 打洞 (默认 false,设置为true时关闭)
# no_punch = false
# 是否启用 LZ4 压缩 (默认 false,设置为true时开启)
# compress = false
# 入栈监听网段 (逗号分隔的 CIDR 和目标 IP),用于点对网,将指定网段的流量发送到目标节点
# input = ["192.168.0.0/24,10.26.0.2", "192.168.1.0/24,10.26.0.3"]
# 出栈允许网段,用于点对网,允许指定网段的转发
# output = ["0.0.0.0/0"]
# 是否关闭内置子网NAT,关闭(设为true)后需要配置网卡转发,否则无法使用点对网。通常关闭内置子网NAT,使用系统的网卡转发,点对网性能会更好
# no_nat = false
# 是否关闭TUN虚拟网卡,关闭(设为true)后只能充当流量出口或者进行端口映射,关闭后无需管理员权限
# no_tun = false
# 端口映射,格式为:协议://本地监听地址-目标虚拟IP-目标映射地址
# 端口映射用于在本地监听指定端口,并将收到的网络流量经由指定虚拟节点转发到目标地址,从而实现跨网络或内网服务访问
# 例如 port_mapping = ["tcp://0.0.0.0:81-10.0.0.2-10.0.0.2:80"]
# tcp://0.0.0.0:81-10.0.0.2-10.0.0.2:80 则表示将本地tcp的81端口的数据转发到10.0.0.2:80
# tcp://0.0.0.0:81-10.0.0.2-192.168.1.10:80 则表示将本地tcp的81端口的数据经过10.0.0.2转到192.168.1.10:80
# tcp://0.0.0.0:81-10.0.0.2-anyonehost:80 则表示将本地tcp的81端口的数据经过10.0.0.2转到anyonehost:80
# port_mapping = []
# 是否允许作为端口映射出口,开启(设置为true)后其他设备才可使用本设备的ip为"目标虚拟IP"
# 开启后虚拟网络其他设备可以使用此设备当跳板访问其他网络
# allow_mapping = false
# MTU 设置
# mtu = 1400
# --- 设备配置 ---
# 设备名称 (可选,默认读取本机 hostname)
# device_name = "my-device"
# 设备 ID (可选,不填自动生成,不同设备ID不能相同)
# device_id = "device-id-xxxx"
# 虚拟网卡名称
# tun_name = "vnt-tun"
# --- 安全配置 ---
# 加密密码 (可选)
# password = "123456"
# 证书校验方式:
# skip 跳过验证(默认)
# standard 使用系统证书验证
# finger 使用证书指纹验证,服务端启动时日志会输出指纹,
# 例如 finger:3bdd8675606837cdf95d5e13445606315762315a78555f9da652940a25feaec1
# cert_mode = "skip"
# --- 其他配置 ---
# 自定义stun地址,分别用于udp打洞和tcp打洞,需要单独配置,不设置则用默认stun
# udp_stun = ["stun.chat.bilibili.com"]
# tcp_stun = ["stun.nextcloud.com:443"]`,ih={class:"text-lg font-bold text-slate-900 dark:text-white"},ah={class:"flex items-center gap-4"},ch={class:"flex rounded-lg border border-slate-300 bg-slate-100 p-1 dark:border-slate-600 dark:bg-slate-800"},uh={key:0,class:"text-sm text-slate-500 font-mono hidden md:block"},fh={class:"h-full overflow-y-auto scrollbar-hide p-6"},dh={class:"max-w-4xl mx-auto space-y-6"},ph={class:"card"},hh={class:"grid grid-cols-1 md:grid-cols-2 gap-4"},mh={class:"mt-4"},gh={class:"space-y-2"},vh=["onUpdate:modelValue"],bh=["onClick"],_h={class:"card"},xh={class:"grid grid-cols-1 md:grid-cols-2 gap-4"},yh={class:"card"},kh={class:"grid grid-cols-1 md:grid-cols-2 gap-4"},wh={class:"card"},Ch={class:"space-y-4"},Sh={class:"grid grid-cols-1 md:grid-cols-2 gap-4"},Eh={key:0},Th={class:"card"},Ah={class:"space-y-4"},$h={class:"space-y-2"},Ih=["onUpdate:modelValue"],Rh=["onClick"],Ph={class:"space-y-2"},Oh=["onUpdate:modelValue"],Mh=["onClick"],Lh={class:"grid grid-cols-1 md:grid-cols-2 gap-4"},Nh={class:"card"},Vh={class:"space-y-4"},jh={class:"space-y-2"},Dh=["onUpdate:modelValue"],Bh=["onClick"],Fh={class:"card"},Uh={class:"grid grid-cols-1 md:grid-cols-3 gap-4"},Hh={class:"card"},Wh={class:"grid grid-cols-1 md:grid-cols-2 gap-4"},Kh={class:"space-y-2"},Gh=["onUpdate:modelValue"],qh=["onClick"],zh={class:"space-y-2"},Zh=["onUpdate:modelValue"],Jh=["onClick"],Yh={class:"h-full"},Qh={class:"flex-1 text-left text-xs text-slate-500"},Xh={key:0},em={key:1},Yt="h-5 w-5 rounded border-slate-300 bg-white text-indigo-600 focus:ring-indigo-500 dark:border-slate-600 dark:bg-slate-700",Qt="flex cursor-pointer items-center justify-between gap-2 rounded-lg border border-slate-200 bg-slate-50 p-3 transition-colors hover:bg-slate-100 dark:border-slate-700 dark:bg-slate-800/50 dark:hover:bg-slate-800",ps="shrink-0 rounded-lg bg-red-50 px-3 py-2 text-red-500 transition-colors hover:bg-red-100 dark:bg-red-900/20 dark:text-red-500 dark:hover:bg-red-900/40",hs="flex w-full items-center justify-center gap-1 rounded-lg bg-slate-100 px-3 py-2 text-sm text-slate-600 transition-colors hover:bg-slate-200 dark:bg-slate-700/50 dark:text-slate-300 dark:hover:bg-slate-700",Vt="text-md mb-4 flex items-center font-bold text-slate-900 dark:text-white",tm={__name:"ConfigEditor",props:{show:{type:Boolean,default:!1},fileName:{type:String,default:null}},emits:["close","saved"],setup(e,{emit:t}){const s=e,n=t,o=as(),l=oe(""),r=oe(""),i=oe("new"),c=oe("form"),f=oe(""),u=oe(!1),d=oe(!1),g=oe(!1),h=oe(Bo());Be(()=>s.show,async w=>{if(w)if(r.value=s.fileName||"",i.value=s.fileName?"edit":"new",c.value="form",u.value=!1,d.value=!1,s.fileName)try{const p=await Td(s.fileName);l.value=p,f.value=p,g.value=!0,h.value=Sr(p),Rt(()=>{g.value=!1})}catch(p){o.toast.error("获取配置失败: "+p.message),n("close")}else f.value="",h.value=Bo(),l.value=rh});const C=()=>{c.value==="toml"?(c.value="form",g.value=!0,h.value=Sr(l.value),Rt(()=>{g.value=!1})):c.value="form"},x=()=>{c.value==="form"&&(d.value?(l.value=_o(h.value),d.value=!1):f.value&&!u.value?l.value=f.value:l.value=_o(h.value)),c.value="toml"};Be(l,(w,p)=>{c.value==="toml"&&p!==void 0&&(u.value=!0)}),Be(h,()=>{c.value==="form"&&s.show&&!g.value&&(d.value=!0)},{deep:!0});const L=async()=>{try{let w=l.value;if(c.value==="form"){if(!h.value.network_code.trim()){o.toast.error("请填写网络编号");return}if(h.value.server.filter(b=>b.trim()).length===0){o.toast.error("请至少填写一个服务器地址");return}w=_o(h.value)}await Ad(r.value||null,w),o.toast.success("配置已保存"),n("close"),n("saved")}catch(w){o.toast.error("保存失败: "+w.message)}};return(w,p)=>(y(),Ie(gl,{show:e.show,"mask-closable":!1,"panel-class":"w-full max-w-6xl h-[85vh]",onClose:p[26]||(p[26]=b=>n("close"))},{header:Ae(()=>[a("h3",ih,V(i.value==="new"?"新建配置":"编辑配置"),1),a("div",ah,[a("div",ch,[a("button",{onClick:C,class:G([c.value==="form"?"bg-white text-slate-900 shadow-sm dark:bg-indigo-600 dark:text-white":"text-slate-500 hover:text-slate-900 dark:text-slate-400 dark:hover:text-white","px-4 py-1.5 rounded text-sm font-medium transition-colors flex items-center"])},[...p[27]||(p[27]=[a("svg",{class:"w-4 h-4 mr-1.5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M9 12h6m-6 4h6m2 5H7a2 2 0 01-2-2V5a2 2 0 012-2h5.586a1 1 0 01.707.293l5.414 5.414a1 1 0 01.293.707V19a2 2 0 01-2 2z"})],-1),ae(" 表单模式 ",-1)])],2),a("button",{onClick:x,class:G([c.value==="toml"?"bg-white text-slate-900 shadow-sm dark:bg-indigo-600 dark:text-white":"text-slate-500 hover:text-slate-900 dark:text-slate-400 dark:hover:text-white","px-4 py-1.5 rounded text-sm font-medium transition-colors flex items-center"])},[...p[28]||(p[28]=[a("svg",{class:"w-4 h-4 mr-1.5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M10 20l4-16m4 4l4 4-4 4M6 16l-4-4 4-4"})],-1),ae(" TOML模式 ",-1)])],2)]),r.value?(y(),E("div",uh,V(r.value),1)):fe("",!0)])]),body:Ae(()=>[me(a("div",fh,[a("div",dh,[a("div",ph,[a("h4",{class:G(Vt)},[...p[29]||(p[29]=[a("svg",{class:"w-5 h-5 mr-2",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M13 10V3L4 14h7v7l9-11h-7z"})],-1),ae(" 基础配置 ",-1)])]),a("div",hh,[a("div",null,[p[30]||(p[30]=a("label",{class:"mb-2 block text-sm font-medium text-slate-600 dark:text-slate-300"},"配置名称",-1)),me(a("input",{"onUpdate:modelValue":p[0]||(p[0]=b=>h.value.config_name=b),type:"text",placeholder:"例如: 我的VPN配置",class:"input"},null,512),[[Oe,h.value.config_name]])]),a("div",null,[p[31]||(p[31]=a("label",{class:"mb-2 block text-sm font-medium text-slate-600 dark:text-slate-300"},[ae(" 网络编号 "),a("span",{class:"text-red-500"},"*")],-1)),me(a("input",{"onUpdate:modelValue":p[1]||(p[1]=b=>h.value.network_code=b),type:"text",placeholder:"例如: my_network",required:"",class:"input"},null,512),[[Oe,h.value.network_code]])])]),a("div",mh,[p[34]||(p[34]=a("label",{class:"mb-2 block text-sm font-medium text-slate-600 dark:text-slate-300"},[ae(" 服务器地址 "),a("span",{class:"text-red-500"},"*"),a("span",{class:"text-xs text-slate-500 ml-2"},"支持 quic:// tcp:// wss:// dynamic://")],-1)),a("div",gh,[(y(!0),E(ie,null,Ee(h.value.server,(b,k)=>(y(),E("div",{key:k,class:"flex gap-2"},[me(a("input",{"onUpdate:modelValue":S=>h.value.server[k]=S,type:"text",placeholder:"例如: quic://1.2.3.4:29872",class:"input flex-1"},null,8,vh),[[Oe,h.value.server[k]]]),h.value.server.length>1?(y(),E("button",{key:0,onClick:S=>h.value.server.splice(k,1),class:G(ps)},[...p[32]||(p[32]=[a("svg",{class:"w-5 h-5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M19 7l-.867 12.142A2 2 0 0116.138 21H7.862a2 2 0 01-1.995-1.858L5 7m5 4v6m4-6v6m1-10V4a1 1 0 00-1-1h-4a1 1 0 00-1 1v3M4 7h16"})],-1)])],8,bh)):fe("",!0)]))),128)),a("button",{onClick:p[2]||(p[2]=b=>h.value.server.push("")),class:G(hs)},[...p[33]||(p[33]=[a("svg",{class:"w-4 h-4 mr-1",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M12 4v16m8-8H4"})],-1),ae(" 添加服务器 ",-1)])])])])]),a("div",_h,[a("h4",{class:G(Vt)},[...p[35]||(p[35]=[a("svg",{class:"w-5 h-5 mr-2",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M21 12a9 9 0 01-9 9m9-9a9 9 0 00-9-9m9 9H3m9 9a9 9 0 01-9-9m9 9c1.657 0 3-4.03 3-9s-1.343-9-3-9m0 18c-1.657 0-3-4.03-3-9s1.343-9 3-9m-9 9a9 9 0 019-9"})],-1),ae(" 网络设置 ",-1)])]),a("div",xh,[a("div",null,[p[36]||(p[36]=a("label",{class:"mb-2 block text-sm font-medium text-slate-600 dark:text-slate-300"},[ae(" 自定义虚拟IP "),a("span",{class:"text-xs text-slate-500 ml-1"},"(可选)")],-1)),me(a("input",{"onUpdate:modelValue":p[3]||(p[3]=b=>h.value.ip=b),type:"text",placeholder:"例如: 10.26.0.2",class:"input"},null,512),[[Oe,h.value.ip]])]),a("div",null,[p[37]||(p[37]=a("label",{class:"mb-2 block text-sm font-medium text-slate-600 dark:text-slate-300"},"MTU",-1)),me(a("input",{"onUpdate:modelValue":p[4]||(p[4]=b=>h.value.mtu=b),type:"number",placeholder:"1380",class:"input"},null,512),[[Oe,h.value.mtu,void 0,{number:!0}]])]),a("div",null,[p[38]||(p[38]=a("label",{class:"mb-2 block text-sm font-medium text-slate-600 dark:text-slate-300"},"隧道端口",-1)),me(a("input",{"onUpdate:modelValue":p[5]||(p[5]=b=>h.value.tunnel_port=b),type:"number",placeholder:"0 (自动分配)",class:"input"},null,512),[[Oe,h.value.tunnel_port,void 0,{number:!0}]])])])]),a("div",yh,[a("h4",{class:G(Vt)},[...p[39]||(p[39]=[a("svg",{class:"w-5 h-5 mr-2",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M13 10V3L4 14h7v7l9-11h-7z"})],-1),ae(" 传输优化 ",-1)])]),a("div",kh,[a("label",{class:G(Qt)},[p[40]||(p[40]=a("div",{class:"flex-1"},[a("div",{class:"text-sm font-medium text-slate-800 dark:text-white"},"QUIC传输优化"),a("div",{class:"text-xs text-slate-400 mt-0.5"},"重传丢包")],-1)),me(a("input",{"onUpdate:modelValue":p[6]||(p[6]=b=>h.value.rtx=b),type:"checkbox",class:G(Yt)},null,512),[[Jt,h.value.rtx]])]),a("label",{class:G(Qt)},[p[41]||(p[41]=a("div",{class:"flex-1"},[a("div",{class:"text-sm font-medium text-slate-800 dark:text-white"},"FEC前向纠错"),a("div",{class:"text-xs text-slate-400 mt-0.5"},"损失部分带宽提升稳定性")],-1)),me(a("input",{"onUpdate:modelValue":p[7]||(p[7]=b=>h.value.fec=b),type:"checkbox",class:G(Yt)},null,512),[[Jt,h.value.fec]])]),a("label",{class:G(Qt)},[p[42]||(p[42]=a("div",{class:"flex-1"},[a("div",{class:"text-sm font-medium text-slate-800 dark:text-white"},"LZ4压缩"),a("div",{class:"text-xs text-slate-400 mt-0.5"},"减少传输数据量")],-1)),me(a("input",{"onUpdate:modelValue":p[8]||(p[8]=b=>h.value.compress=b),type:"checkbox",class:G(Yt)},null,512),[[Jt,h.value.compress]])]),a("label",{class:G(Qt)},[p[43]||(p[43]=a("div",{class:"flex-1"},[a("div",{class:"text-sm font-medium text-slate-800 dark:text-white"},"关闭P2P打洞"),a("div",{class:"text-xs text-slate-400 mt-0.5"},"仅通过服务器中转")],-1)),me(a("input",{"onUpdate:modelValue":p[9]||(p[9]=b=>h.value.no_punch=b),type:"checkbox",class:G(Yt)},null,512),[[Jt,h.value.no_punch]])])])]),a("div",wh,[a("h4",{class:G(Vt)},[...p[44]||(p[44]=[a("svg",{class:"w-5 h-5 mr-2",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M12 15v2m-6 4h12a2 2 0 002-2v-6a2 2 0 00-2-2H6a2 2 0 00-2 2v6a2 2 0 002 2zm10-10V7a4 4 0 00-8 0v4h8z"})],-1),ae(" 安全配置 ",-1)])]),a("div",Ch,[a("div",Sh,[a("div",null,[p[45]||(p[45]=a("label",{class:"mb-2 block text-sm font-medium text-slate-600 dark:text-slate-300"},"组网加密密码(连接公共服务器时建议填写,同一组网密码需要相同)",-1)),me(a("input",{"onUpdate:modelValue":p[10]||(p[10]=b=>h.value.password=b),type:"password",placeholder:"留空则不加密",class:"input"},null,512),[[Oe,h.value.password]])]),a("div",null,[p[47]||(p[47]=a("label",{class:"mb-2 block text-sm font-medium text-slate-600 dark:text-slate-300"},"服务端证书校验模式",-1)),me(a("select",{"onUpdate:modelValue":p[11]||(p[11]=b=>h.value.cert_mode=b),class:"input"},[...p[46]||(p[46]=[a("option",{value:"skip"},"跳过验证 (默认)",-1),a("option",{value:"standard"},"系统证书验证",-1),a("option",{value:"finger"},"证书指纹验证",-1)])],512),[[cl,h.value.cert_mode]])])]),h.value.cert_mode==="finger"?(y(),E("div",Eh,[p[48]||(p[48]=a("label",{class:"mb-2 block text-sm font-medium text-slate-600 dark:text-slate-300"},[ae(" 证书指纹 "),a("span",{class:"text-xs text-slate-500 ml-1"},"(服务端启动时日志会输出指纹)")],-1)),me(a("input",{"onUpdate:modelValue":p[12]||(p[12]=b=>h.value.fingerprint=b),type:"text",placeholder:"例如: 3bdd8675606837cdf95d5e13445606315762315a78555f9da652940a25feaec1",class:"input font-mono text-sm"},null,512),[[Oe,h.value.fingerprint]])])):fe("",!0)])]),a("div",Th,[a("h4",{class:G(Vt)},[...p[49]||(p[49]=[a("svg",{class:"w-5 h-5 mr-2",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M9 20l-5.447-2.724A1 1 0 013 16.382V5.618a1 1 0 011.447-.894L9 7m0 13l6-3m-6 3V7m6 10l4.553 2.276A1 1 0 0021 18.382V7.618a1 1 0 01-.806-.98L15 9m0 0V7m0 2v6"})],-1),ae(" NAT与路由 (点对网) ",-1)])]),a("div",Ah,[a("div",null,[p[51]||(p[51]=a("label",{class:"mb-2 block text-sm font-medium text-slate-600 dark:text-slate-300"},[ae(" 入栈网段 "),a("span",{class:"text-xs text-slate-500 ml-1"},"格式: CIDR,目标IP")],-1)),a("div",$h,[(y(!0),E(ie,null,Ee(h.value.input,(b,k)=>(y(),E("div",{key:k,class:"flex gap-2"},[me(a("input",{"onUpdate:modelValue":S=>h.value.input[k]=S,type:"text",placeholder:"例如: 192.168.0.0/24,10.26.0.2",class:"input flex-1"},null,8,Ih),[[Oe,h.value.input[k]]]),a("button",{onClick:S=>h.value.input.splice(k,1),class:G(ps)},[...p[50]||(p[50]=[a("svg",{class:"w-5 h-5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M6 18L18 6M6 6l12 12"})],-1)])],8,Rh)]))),128)),a("button",{onClick:p[13]||(p[13]=b=>h.value.input.push("")),class:G(hs)}," + 添加入栈网段 ")])]),a("div",null,[p[53]||(p[53]=a("label",{class:"mb-2 block text-sm font-medium text-slate-600 dark:text-slate-300"},[ae(" 出栈网段 "),a("span",{class:"text-xs text-slate-500 ml-1"},"格式: CIDR (允许转发的网段)")],-1)),a("div",Ph,[(y(!0),E(ie,null,Ee(h.value.output,(b,k)=>(y(),E("div",{key:k,class:"flex gap-2"},[me(a("input",{"onUpdate:modelValue":S=>h.value.output[k]=S,type:"text",placeholder:"例如: 0.0.0.0/0",class:"input flex-1"},null,8,Oh),[[Oe,h.value.output[k]]]),a("button",{onClick:S=>h.value.output.splice(k,1),class:G(ps)},[...p[52]||(p[52]=[a("svg",{class:"w-5 h-5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M6 18L18 6M6 6l12 12"})],-1)])],8,Mh)]))),128)),a("button",{onClick:p[14]||(p[14]=b=>h.value.output.push("")),class:G(hs)}," + 添加出栈网段 ")])]),a("div",Lh,[a("label",{class:G(Qt)},[p[54]||(p[54]=a("div",{class:"flex-1"},[a("div",{class:"text-sm font-medium text-slate-800 dark:text-white"},"关闭内置NAT"),a("div",{class:"text-xs text-slate-400 mt-0.5"},"使用系统网卡转发")],-1)),me(a("input",{"onUpdate:modelValue":p[15]||(p[15]=b=>h.value.no_nat=b),type:"checkbox",class:G(Yt)},null,512),[[Jt,h.value.no_nat]])]),a("label",{class:G(Qt)},[p[55]||(p[55]=a("div",{class:"flex-1"},[a("div",{class:"text-sm font-medium text-slate-800 dark:text-white"},"关闭TUN网卡"),a("div",{class:"text-xs text-slate-400 mt-0.5"},"仅作流量出口或端口映射")],-1)),me(a("input",{"onUpdate:modelValue":p[16]||(p[16]=b=>h.value.no_tun=b),type:"checkbox",class:G(Yt)},null,512),[[Jt,h.value.no_tun]])])])])]),a("div",Nh,[a("h4",{class:G(Vt)},[...p[56]||(p[56]=[a("svg",{class:"w-5 h-5 mr-2",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M8 9l3 3-3 3m5 0h3M5 20h14a2 2 0 002-2V6a2 2 0 00-2-2H5a2 2 0 00-2 2v12a2 2 0 002 2z"})],-1),ae(" 端口映射 ",-1)])]),a("div",Vh,[a("div",null,[p[58]||(p[58]=a("label",{class:"mb-2 block text-sm font-medium text-slate-600 dark:text-slate-300"},[ae(" 映射规则 "),a("span",{class:"text-xs text-slate-500 ml-1"},"格式: 协议://监听地址-虚拟IP-目标地址")],-1)),a("div",jh,[(y(!0),E(ie,null,Ee(h.value.port_mapping,(b,k)=>(y(),E("div",{key:k,class:"flex gap-2"},[me(a("input",{"onUpdate:modelValue":S=>h.value.port_mapping[k]=S,type:"text",placeholder:"例如: tcp://0.0.0.0:81-10.0.0.2-10.0.0.2:80",class:"input flex-1 font-mono"},null,8,Dh),[[Oe,h.value.port_mapping[k]]]),a("button",{onClick:S=>h.value.port_mapping.splice(k,1),class:G(ps)},[...p[57]||(p[57]=[a("svg",{class:"w-5 h-5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M6 18L18 6M6 6l12 12"})],-1)])],8,Bh)]))),128)),a("button",{onClick:p[17]||(p[17]=b=>h.value.port_mapping.push("")),class:G(hs)}," + 添加映射规则 ")])]),a("label",{class:G(Qt)},[p[59]||(p[59]=a("div",{class:"flex-1"},[a("div",{class:"text-sm font-medium text-slate-800 dark:text-white"},"允许作为映射出口"),a("div",{class:"text-xs text-slate-400 mt-0.5"},"允许其他设备使用本机作跳板")],-1)),me(a("input",{"onUpdate:modelValue":p[18]||(p[18]=b=>h.value.allow_mapping=b),type:"checkbox",class:G(Yt)},null,512),[[Jt,h.value.allow_mapping]])])])]),a("div",Fh,[a("h4",{class:G(Vt)},[...p[60]||(p[60]=[a("svg",{class:"w-5 h-5 mr-2",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M9.75 17L9 20l-1 1h8l-1-1-.75-3M3 13h18M5 17h14a2 2 0 002-2V5a2 2 0 00-2-2H5a2 2 0 00-2 2v10a2 2 0 002 2z"})],-1),ae(" 设备配置 ",-1)])]),a("div",Uh,[a("div",null,[p[61]||(p[61]=a("label",{class:"mb-2 block text-sm font-medium text-slate-600 dark:text-slate-300"},"设备名称",-1)),me(a("input",{"onUpdate:modelValue":p[19]||(p[19]=b=>h.value.device_name=b),type:"text",placeholder:"默认为主机名",class:"input"},null,512),[[Oe,h.value.device_name]])]),a("div",null,[p[62]||(p[62]=a("label",{class:"mb-2 block text-sm font-medium text-slate-600 dark:text-slate-300"},"设备ID",-1)),me(a("input",{"onUpdate:modelValue":p[20]||(p[20]=b=>h.value.device_id=b),type:"text",placeholder:"自动生成",class:"input"},null,512),[[Oe,h.value.device_id]])]),a("div",null,[p[63]||(p[63]=a("label",{class:"mb-2 block text-sm font-medium text-slate-600 dark:text-slate-300"},"虚拟网卡名",-1)),me(a("input",{"onUpdate:modelValue":p[21]||(p[21]=b=>h.value.tun_name=b),type:"text",placeholder:"默认为vnt-tun",class:"input"},null,512),[[Oe,h.value.tun_name]])])])]),a("div",Hh,[a("h4",{class:G(Vt)},[...p[64]||(p[64]=[a("svg",{class:"w-5 h-5 mr-2",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M3.055 11H5a2 2 0 012 2v1a2 2 0 002 2 2 2 0 012 2v2.945M8 3.935V5.5A2.5 2.5 0 0010.5 8h.5a2 2 0 012 2 2 2 0 104 0 2 2 0 012-2h1.064M15 20.488V18a2 2 0 012-2h3.064M21 12a9 9 0 11-18 0 9 9 0 0118 0z"})],-1),ae(" STUN配置 (高级) ",-1)])]),a("div",Wh,[a("div",null,[p[66]||(p[66]=a("label",{class:"mb-2 block text-sm font-medium text-slate-600 dark:text-slate-300"},"UDP STUN服务器",-1)),a("div",Kh,[(y(!0),E(ie,null,Ee(h.value.udp_stun,(b,k)=>(y(),E("div",{key:k,class:"flex gap-2"},[me(a("input",{"onUpdate:modelValue":S=>h.value.udp_stun[k]=S,type:"text",placeholder:"例如: stun.l.google.com:19302",class:"input flex-1"},null,8,Gh),[[Oe,h.value.udp_stun[k]]]),a("button",{onClick:S=>h.value.udp_stun.splice(k,1),class:G(ps)},[...p[65]||(p[65]=[a("svg",{class:"w-5 h-5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M6 18L18 6M6 6l12 12"})],-1)])],8,qh)]))),128)),a("button",{onClick:p[22]||(p[22]=b=>h.value.udp_stun.push("")),class:G(hs)}," + 添加UDP STUN ")])]),a("div",null,[p[68]||(p[68]=a("label",{class:"mb-2 block text-sm font-medium text-slate-600 dark:text-slate-300"},"TCP STUN服务器",-1)),a("div",zh,[(y(!0),E(ie,null,Ee(h.value.tcp_stun,(b,k)=>(y(),E("div",{key:k,class:"flex gap-2"},[me(a("input",{"onUpdate:modelValue":S=>h.value.tcp_stun[k]=S,type:"text",placeholder:"例如: stun.nextcloud.com:443",class:"input flex-1"},null,8,Zh),[[Oe,h.value.tcp_stun[k]]]),a("button",{onClick:S=>h.value.tcp_stun.splice(k,1),class:G(ps)},[...p[67]||(p[67]=[a("svg",{class:"w-5 h-5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M6 18L18 6M6 6l12 12"})],-1)])],8,Jh)]))),128)),a("button",{onClick:p[23]||(p[23]=b=>h.value.tcp_stun.push("")),class:G(hs)}," + 添加TCP STUN ")])])])])])],512),[[ql,c.value==="form"]]),me(a("div",Yh,[me(a("textarea",{"onUpdate:modelValue":p[24]||(p[24]=b=>l.value=b),class:"h-full w-full resize-none bg-slate-50 p-4 font-mono text-sm text-slate-800 focus:outline-none dark:bg-slate-950 dark:text-slate-200",spellcheck:"false",placeholder:"# 在此处输入 TOML 配置..."},null,512),[[Oe,l.value]])],512),[[ql,c.value==="toml"]])]),footer:Ae(()=>[a("div",Qh,[c.value==="form"?(y(),E("span",Xh,"填写完成后保存即可生成配置文件")):(y(),E("span",em,"* 请使用标准 TOML 格式"))]),a("button",{class:"btn-ghost",onClick:p[25]||(p[25]=b=>n("close"))},"取消"),a("button",{class:"btn-primary",onClick:L},"保存配置")]),_:1},8,["show"]))}},ya=(e,t)=>{const s=e.__vccOpts||e;for(const[n,o]of t)s[n]=o;return s},sm={class:"space-y-6"},nm={class:"flex items-end justify-between gap-4"},om={key:1,class:"grid grid-cols-1 gap-4 md:grid-cols-2 lg:grid-cols-3"},lm=["onClick"],rm={key:0,class:"absolute right-0 top-0 rounded-bl bg-green-500 px-2 py-1 text-xs text-white"},im={key:1,class:"absolute right-0 top-0 rounded-bl bg-indigo-500 px-2 py-1 text-xs text-white"},am={class:"flex items-start"},cm={class:"overflow-hidden"},um=["title"],fm=["title"],dm={class:"config-card-actions mt-4 flex justify-end transition-opacity"},pm=["onClick"],hm=["onClick"],mm={__name:"ConfigView",setup(e){const t=Mt(),s=as(),n=oe(!1),o=oe(null),l=u=>{const d=t.instanceList.find(g=>g.file_name===u);return d?d.status:null},r=u=>{const d=l(u);return d==="running"?"ring-2 ring-green-500/60":d==="starting"?"ring-2 ring-indigo-500/60":""},i=u=>{o.value=u,n.value=!0},c=()=>{t.fetchConfigList()},f=async u=>{if(await s.confirm({title:"删除配置",message:`确定要删除配置 ${u} 吗?`,danger:!0,confirmText:"删除"}))try{await $d(u),s.toast.success("配置已删除"),t.fetchConfigList()}catch(g){s.toast.error(g.message)}};return Ot(()=>t.fetchConfigList()),(u,d)=>(y(),E("div",sm,[a("div",nm,[d[3]||(d[3]=a("div",null,[a("h1",{class:"page-title"},"配置"),a("p",{class:"page-subtitle"},"管理组网配置文件")],-1)),a("button",{class:"btn-primary",onClick:d[0]||(d[0]=g=>i(null))},[...d[2]||(d[2]=[a("svg",{class:"h-4 w-4",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M12 4v16m8-8H4"})],-1),ae(" 新建配置 ",-1)])])]),O(t).configList.length===0?(y(),Ie(an,{key:0,text:"暂无配置,点击右上角新建"})):(y(),E("div",om,[(y(!0),E(ie,null,Ee(O(t).configList,g=>(y(),E("div",{key:g.file_name,class:G([r(g.file_name),"card group relative flex min-h-[140px] cursor-pointer flex-col justify-between overflow-hidden"]),onClick:h=>i(g.file_name)},[l(g.file_name)==="running"?(y(),E("div",rm," 运行中 ")):l(g.file_name)==="starting"?(y(),E("div",im," 启动中 ")):fe("",!0),a("div",am,[d[4]||(d[4]=a("div",{class:"mr-3 mt-1 rounded-lg bg-indigo-50 p-2 text-indigo-600 dark:bg-indigo-500/10 dark:text-indigo-400"},[a("svg",{class:"h-6 w-6",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M9 12h6m-6 4h6m2 5H7a2 2 0 01-2-2V5a2 2 0 012-2h5.586a1 1 0 01.707.293l5.414 5.414a1 1 0 01.293.707V19a2 2 0 01-2 2z"})])],-1)),a("div",cm,[a("h3",{class:"truncate text-lg font-bold text-slate-900 dark:text-white",title:g.config_name},V(g.config_name||"Unnamed"),9,um),a("p",{class:"truncate font-mono text-xs text-slate-400",title:g.file_name},V(g.file_name),9,fm)])]),a("div",dm,[a("button",{class:"mr-4 text-sm text-indigo-600 hover:text-indigo-500 dark:text-indigo-400",onClick:ls(h=>i(g.file_name),["stop"])}," 编辑 ",8,pm),a("button",{class:"text-sm text-red-500 hover:text-red-400",onClick:ls(h=>f(g.file_name),["stop"])}," 删除 ",8,hm)])],10,lm))),128))])),ue(tm,{show:n.value,"file-name":o.value,onClose:d[1]||(d[1]=g=>n.value=!1),onSaved:c},null,8,["show","file-name"])]))}},gm=ya(mm,[["__scopeId","data-v-b7dce6ea"]]),vm=e=>{if(!e)return"-";const t=new Date(e*1e3),s=n=>n<10?"0"+n:n;return`${t.getFullYear()}-${s(t.getMonth()+1)}-${s(t.getDate())} ${s(t.getHours())}:${s(t.getMinutes())}:${s(t.getSeconds())}`},Er=e=>{if(e===0||e===void 0||e===null)return"0B";const t=["B","KB","MB","GB","TB"];let s=0,n=e;for(;n>=1024&&s<t.length-1;)n/=1024,s++;return s===0?n+t[s]:n.toFixed(2)+t[s]},Fo=e=>{if(e===0||e===void 0||e===null)return"0B/s";const t=["B/s","KB/s","MB/s","GB/s"];let s=0,n=e;for(;n>=1024&&s<t.length-1;)n/=1024,s++;return s===0?n+t[s]:n.toFixed(2)+t[s]},bm=e=>{const t=[1024,10240,102400,1048576,10485760,104857600,1073741824];for(const s of t)if(e<=s)return s;return Math.ceil(e/(1024*1024*1024))*1024*1024*1024},ka={__name:"StatusDot",props:{status:{type:String,default:"stopped"},size:{type:String,default:"w-2.5 h-2.5"}},setup(e){const t=s=>s==="running"?"bg-green-500":s==="starting"?"bg-blue-500 animate-pulse":"bg-slate-400 dark:bg-slate-500";return(s,n)=>(y(),E("span",{class:G(["rounded-full inline-block shrink-0",[e.size,t(e.status)]])},null,2))}},_m={class:"flex items-center gap-4 mb-2 text-xs text-slate-400"},xm={class:"ml-auto"},ym={__name:"SpeedChart",props:{history:{type:Object,required:!0},size:{type:Number,default:60}},setup(e,{expose:t}){const s=e,n=oe(null),o=oe(""),l=()=>{const r=n.value;if(!r)return;const i=r.getContext("2d"),c=s.history?s.history.tx:[],f=s.history?s.history.rx:[],u=s.size,d=window.devicePixelRatio||1,g=r.getBoundingClientRect();if(g.width===0)return;r.width=g.width*d,r.height=g.height*d,i.setTransform(d,0,0,d,0,0);const h=g.width,C=g.height,L=document.documentElement.classList.contains("dark")?{bg:"#0c1222",grid:"rgba(71, 85, 105, 0.3)",rx:"#60a5fa",rxFill:"rgba(96, 165, 250, 0.15)",tx:"#4ade80",txFill:"rgba(74, 222, 128, 0.15)"}:{bg:"#f8fafc",grid:"rgba(148, 163, 184, 0.35)",rx:"#3b82f6",rxFill:"rgba(59, 130, 246, 0.12)",tx:"#22c55e",txFill:"rgba(34, 197, 94, 0.12)"},w=8,p=4,b=0,S=h-b-0,q=C-w-p;i.fillStyle=L.bg,i.fillRect(0,0,h,C);const D=[...c,...f];let U=D.length>0?Math.max(...D):0;U<1024&&(U=1024);const M=bm(U);o.value="峰值: "+Fo(M);const z=4;i.strokeStyle=L.grid,i.lineWidth=1;for(let Z=0;Z<=z;Z++){const R=w+q/z*Z;i.beginPath(),i.moveTo(b,R),i.lineTo(b+S,R),i.stroke()}const ne=6;for(let Z=0;Z<=ne;Z++){const R=b+S/ne*Z;i.beginPath(),i.moveTo(R,w),i.lineTo(R,w+q),i.stroke()}const B=(Z,R,ee)=>{if(Z.length<2)return;const ce=S/(u-1),te=u-Z.length;i.beginPath(),i.moveTo(b+te*ce,w+q);for(let re=0;re<Z.length;re++){const Fe=b+(te+re)*ce,qe=w+q-Z[re]/M*q;i.lineTo(Fe,qe)}i.lineTo(b+(te+Z.length-1)*ce,w+q),i.closePath(),i.fillStyle=ee,i.fill(),i.beginPath();for(let re=0;re<Z.length;re++){const Fe=b+(te+re)*ce,qe=w+q-Z[re]/M*q;re===0?i.moveTo(Fe,qe):i.lineTo(Fe,qe)}i.strokeStyle=R,i.lineWidth=1.5,i.stroke()};B(f,L.rx,L.rxFill),B(c,L.tx,L.txFill)};return Ot(()=>Rt(l)),Be(()=>[s.history?.tx?.length,s.history?.rx?.length,s.history?.tx?.at(-1),s.history?.rx?.at(-1)],()=>Rt(l)),t({draw:l}),(r,i)=>(y(),E("div",null,[a("div",_m,[i[0]||(i[0]=a("span",{class:"flex items-center"},[a("span",{class:"inline-block w-3 h-0.5 bg-green-400 mr-1"}),ae("上传速度")],-1)),i[1]||(i[1]=a("span",{class:"flex items-center"},[a("span",{class:"inline-block w-3 h-0.5 bg-blue-400 mr-1"}),ae("下载速度")],-1)),a("span",xm,V(o.value),1)]),a("canvas",{ref_key:"canvasRef",ref:n,class:"rounded w-full block h-[150px]"},null,512)]))}},km={class:"space-y-4"},wm={key:0,class:"scrollbar-hide flex items-center gap-2 overflow-x-auto"},Cm=["onClick"],Sm={key:2,class:"card overflow-hidden p-0"},Em={class:"flex items-center justify-between border-b border-slate-200 px-6 py-4 dark:border-slate-700"},Tm={class:"flex gap-4 text-sm muted"},Am={class:"font-medium tabular-nums text-slate-900 dark:text-white"},$m={class:"font-medium tabular-nums text-slate-900 dark:text-white"},Im={class:"custom-scrollbar max-h-[600px] overflow-x-auto"},Rm={class:"table"},Pm={class:"transition-colors hover:bg-slate-50 dark:hover:bg-slate-800/50"},Om=["onClick"],Mm={class:"font-mono tabular-nums text-indigo-600 dark:text-indigo-400"},Lm=["onMouseenter"],Nm={class:"hidden text-xs text-slate-400 md:table-cell"},Vm={class:"flex items-center gap-2"},jm={key:0,class:"tooltip"},Dm={key:1,class:"tooltip"},Bm={key:2,class:"tooltip cursor-help"},Fm={class:"tooltip-text"},Um={key:1,class:"text-yellow-600 dark:text-yellow-400"},Hm={key:2,class:"text-slate-400"},Wm={class:"tabular-nums"},Km=["title"],Gm={key:1,class:"text-slate-400"},qm={class:"text-xs"},zm={key:0,class:"leading-relaxed"},Zm={class:"text-green-600 tabular-nums dark:text-green-400"},Jm={class:"text-blue-600 tabular-nums dark:text-blue-400"},Ym={key:1,class:"text-slate-400"},Qm={class:"hidden font-mono text-xs text-slate-400 md:table-cell"},Xm={key:0},eg={colspan:"10",class:"p-0"},tg={class:"border-t border-slate-200 bg-slate-50 px-4 py-3 dark:border-slate-700/50 dark:bg-slate-950/60"},sg=60,ng={__name:"PeersView",setup(e){const t=Mt(),s=Qe("peerTooltip"),n=(b,k)=>s.value?.showPeerTooltip(b,k),o=()=>s.value?.hidePeerTooltip(),l=oe([]);let r=null,i={},c=0;const f=Kt({}),u={},d=b=>{f[b]=!f[b]},g=()=>{const b=t.instanceList.find(k=>k.file_name===t.selectedInstance);return b?b.status:null},h=()=>{l.value=[],i={},c=0;for(const b in u)delete u[b];for(const b in f)delete f[b]},C=async()=>{if(!t.selectedInstance||g()!=="running"){h();return}try{const b=await bd(t.selectedInstance)||[],k=Date.now(),S=c>0?(k-c)/1e3:0,q={};for(const D of b)if(D.traffic){const U=D.ip,M=i[U];if(M&&S>0){const z=Math.max(0,D.traffic.tx_bytes-M.tx_bytes),ne=Math.max(0,D.traffic.rx_bytes-M.rx_bytes);D.traffic.tx_speed=Math.round(z/S),D.traffic.rx_speed=Math.round(ne/S)}else D.traffic.tx_speed=0,D.traffic.rx_speed=0;q[U]={tx_bytes:D.traffic.tx_bytes,rx_bytes:D.traffic.rx_bytes},u[U]||(u[U]={tx:[],rx:[]}),u[U].tx.push(D.traffic.tx_speed),u[U].rx.push(D.traffic.rx_speed),u[U].tx.length>sg&&(u[U].tx.shift(),u[U].rx.shift())}i=q,c=k,l.value=b}catch(b){console.error(b)}};Ot(()=>{C(),r=setInterval(()=>{t.isPageVisible&&C()},3e3)}),As(()=>{r&&clearInterval(r)}),Be(()=>t.selectedInstance,()=>{h(),C()}),Be(g,b=>{b==="running"&&C()});const x=b=>b.metric===1?"text-purple-600 font-medium dark:text-purple-400":"text-blue-600 dark:text-blue-400",L=b=>{const k=b.metric===1,S=b.protocol.includes("Tcp");return k?S?"打洞TCP直连":"打洞UDP直连":S?"客户端TCP中继":"客户端UDP中继"},w=b=>b===3?"己方加密对方未加密":b===4?"己方未加密对方加密":b===5?"密钥不一致":"未知错误",p=b=>t.selectedInstance===b?"border-indigo-600 bg-indigo-600 text-white dark:border-indigo-500 dark:bg-indigo-500":"border-slate-300 bg-white text-slate-600 hover:bg-slate-50 dark:border-slate-600 dark:bg-slate-800 dark:text-slate-300 dark:hover:bg-slate-700";return(b,k)=>(y(),E("div",km,[k[8]||(k[8]=a("div",null,[a("h1",{class:"page-title"},"设备列表"),a("p",{class:"page-subtitle"},"查看各实例的设备连接与流量状况")],-1)),O(t).instanceList.length>0?(y(),E("div",wm,[(y(!0),E(ie,null,Ee(O(t).instanceList,S=>(y(),E("button",{key:S.file_name,onClick:q=>O(t).selectedInstance=S.file_name,class:G([p(S.file_name),"flex shrink-0 items-center rounded-lg border px-4 py-2 text-sm font-medium transition-colors"])},[ue(ka,{status:S.status,size:"w-2 h-2",class:"mr-2"},null,8,["status"]),ae(" "+V(S.config_name||S.file_name),1)],10,Cm))),128))])):fe("",!0),O(t).selectedInstance?(y(),E("div",Sm,[a("div",Em,[k[2]||(k[2]=a("h2",{class:"text-base font-bold text-slate-900 dark:text-white"},"设备列表",-1)),a("div",Tm,[a("span",null,[k[0]||(k[0]=ae(" Online: ",-1)),a("span",Am,V(l.value.filter(S=>S.online).length),1)]),a("span",null,[k[1]||(k[1]=ae(" Total: ",-1)),a("span",$m,V(l.value.length),1)])])]),a("div",Im,[a("table",Rm,[k[7]||(k[7]=a("thead",null,[a("tr",null,[a("th",{class:"w-8 px-2"}),a("th",null,"IP地址"),a("th",null,"名称"),a("th",{class:"hidden md:table-cell"},"版本"),a("th",null,"状态"),a("th",null,"模式"),a("th",null,"延迟"),a("th",null,"丢包率"),a("th",null,"流量"),a("th",{class:"hidden md:table-cell"},"最后在线")])],-1)),a("tbody",null,[(y(!0),E(ie,null,Ee(l.value,S=>(y(),E(ie,{key:S.ip},[a("tr",Pm,[a("td",{class:"cursor-pointer select-none px-2 text-center",onClick:q=>d(S.ip)},[(y(),E("svg",{class:G(["inline-block h-4 w-4 text-slate-400 transition-transform duration-200",{"rotate-90":f[S.ip]}]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[...k[3]||(k[3]=[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M9 5l7 7-7 7"},null,-1)])],2))],8,Om),a("td",Mm,[a("span",{class:"cursor-help border-b border-dotted border-indigo-400/50 pb-0.5",onMouseenter:q=>n(q,S),onMouseleave:o},V(S.ip),41,Lm)]),a("td",null,V(S.name||"-"),1),a("td",Nm,V(S.version||"-"),1),a("td",null,[a("div",Vm,[a("span",{class:G(S.online?"badge-green":"badge-gray")},V(S.online?"Online":"Offline"),3),S.online&&S.key_equal===1?(y(),E("div",jm,[...k[4]||(k[4]=[a("svg",{class:"h-4 w-4 text-green-500",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M12 15v2m-6 4h12a2 2 0 002-2v-6a2 2 0 00-2-2H6a2 2 0 00-2 2v6a2 2 0 002 2zm10-10V7a4 4 0 00-8 0v4h8z"})],-1),a("span",{class:"tooltip-text"},"双方加密传输",-1)])])):S.online&&S.key_equal===2?(y(),E("div",Dm,[...k[5]||(k[5]=[a("svg",{class:"h-4 w-4 text-yellow-500",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M8 11V7a4 4 0 118 0m-4 8v2m-6 4h12a2 2 0 002-2v-6a2 2 0 00-2-2H6a2 2 0 00-2 2v6a2 2 0 002 2z"})],-1),a("span",{class:"tooltip-text"},"双方未加密",-1)])])):S.online&&[3,4,5].includes(S.key_equal)?(y(),E("div",Bm,[k[6]||(k[6]=a("svg",{class:"h-4 w-4 text-red-500",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M12 8v4m0 4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z"})],-1)),a("span",Fm,V(w(S.key_equal)),1)])):fe("",!0)])]),a("td",null,[S.online&&S.route?(y(),E("span",{key:0,class:G(x(S.route))},V(L(S.route)),3)):S.online?(y(),E("span",Um,"服务器中继")):(y(),E("span",Hm,"-"))]),a("td",Wm,V(S.route?S.route.rtt+" ms":"-"),1),a("td",null,[S.packet_loss?(y(),E("span",{key:0,class:G(S.packet_loss.loss_rate>10?"text-red-600 dark:text-red-400":S.packet_loss.loss_rate>5?"text-yellow-600 dark:text-yellow-400":"text-green-600 dark:text-green-400"),title:"Sent: "+S.packet_loss.sent+", Received: "+S.packet_loss.received},V(S.packet_loss.loss_rate.toFixed(1))+"%",11,Km)):(y(),E("span",Gm,"-"))]),a("td",qm,[S.traffic?(y(),E("div",zm,[a("div",Zm," ↑ "+V(O(Er)(S.traffic.tx_bytes))+" ("+V(O(Fo)(S.traffic.tx_speed))+") ",1),a("div",Jm," ↓ "+V(O(Er)(S.traffic.rx_bytes))+" ("+V(O(Fo)(S.traffic.rx_speed))+") ",1)])):(y(),E("span",Ym,"-"))]),a("td",Qm,V(O(vm)(S.last_connected_time)),1)]),f[S.ip]?(y(),E("tr",Xm,[a("td",eg,[a("div",tg,[ue(ym,{history:u[S.ip]||{tx:[],rx:[]},size:60},null,8,["history"])])])])):fe("",!0)],64))),128))])])])])):(y(),Ie(an,{key:1,text:"暂无运行中的组网实例"}))]))}},og={class:"space-y-4"},lg={key:0,class:"scrollbar-hide flex items-center gap-2 overflow-x-auto"},rg=["onClick"],ig={key:2,class:"card overflow-hidden p-0"},ag={class:"custom-scrollbar max-h-[600px] overflow-x-auto"},cg={class:"table"},ug=["rowspan"],fg={class:"font-mono tabular-nums text-yellow-700 dark:text-yellow-300"},dg={class:"tabular-nums"},pg={class:"tabular-nums"},hg={__name:"RoutesView",setup(e){const t=Mt(),s=oe([]);let n=null;const o=()=>{const i=t.instanceList.find(c=>c.file_name===t.selectedInstance);return i?i.status:null},l=async()=>{if(!t.selectedInstance||o()!=="running"){s.value=[];return}try{s.value=await _d(t.selectedInstance)||[]}catch(i){console.error(i)}};Ot(()=>{l(),n=setInterval(()=>{t.isPageVisible&&l()},3e3)}),As(()=>{n&&clearInterval(n)}),Be(()=>t.selectedInstance,()=>{l()}),Be(o,i=>{i==="running"&&l()});const r=i=>t.selectedInstance===i?"border-indigo-600 bg-indigo-600 text-white dark:border-indigo-500 dark:bg-indigo-500":"border-slate-300 bg-white text-slate-600 hover:bg-slate-50 dark:border-slate-600 dark:bg-slate-800 dark:text-slate-300 dark:hover:bg-slate-700";return(i,c)=>(y(),E("div",og,[c[2]||(c[2]=a("div",null,[a("h1",{class:"page-title"},"路由"),a("p",{class:"page-subtitle"},"查看各实例的路由表")],-1)),O(t).instanceList.length>0?(y(),E("div",lg,[(y(!0),E(ie,null,Ee(O(t).instanceList,f=>(y(),E("button",{key:f.file_name,onClick:u=>O(t).selectedInstance=f.file_name,class:G([r(f.file_name),"flex shrink-0 items-center rounded-lg border px-4 py-2 text-sm font-medium transition-colors"])},[ue(ka,{status:f.status,size:"w-2 h-2",class:"mr-2"},null,8,["status"]),ae(" "+V(f.config_name||f.file_name),1)],10,rg))),128))])):fe("",!0),O(t).selectedInstance?(y(),E("div",ig,[c[1]||(c[1]=a("div",{class:"border-b border-slate-200 px-6 py-4 dark:border-slate-700"},[a("h2",{class:"text-base font-bold text-slate-900 dark:text-white"},"路由表")],-1)),a("div",ag,[a("table",cg,[c[0]||(c[0]=a("thead",null,[a("tr",null,[a("th",null,"目标节点IP"),a("th",null,"目标网络"),a("th",null,"跳数"),a("th",null,"延迟")])],-1)),a("tbody",null,[(y(!0),E(ie,null,Ee(s.value,f=>(y(),E(ie,{key:f.ip},[(y(!0),E(ie,null,Ee(f.routes,(u,d)=>(y(),E("tr",{key:d,class:"hover:bg-slate-50 dark:hover:bg-slate-800/50"},[d===0?(y(),E("td",{key:0,rowspan:f.routes.length,class:"font-mono tabular-nums text-indigo-600 dark:text-indigo-400"},V(f.ip),9,ug)):fe("",!0),a("td",fg,V(u.addr),1),a("td",dg,V(u.metric),1),a("td",pg,V(u.rtt)+" ms",1)]))),128))],64))),128))])])])])):(y(),Ie(an,{key:1,text:"暂无运行中的组网实例"}))]))}},mg={class:"mx-auto max-w-4xl space-y-5"},gg={key:0,class:"card text-sm text-slate-400"},vg={key:1,class:"card border-red-200 text-sm text-red-600 dark:border-red-900 dark:text-red-300"},bg={class:"card space-y-6"},_g={class:"flex items-start justify-between gap-5"},xg=["aria-checked","disabled"],yg={class:"grid gap-5 sm:grid-cols-2"},kg={class:"block"},wg=["disabled"],Cg={class:"block"},Sg=["disabled"],Eg={class:"mb-2 flex items-center justify-between gap-3"},Tg=["disabled"],Ag={class:"flex items-center gap-2"},$g={class:"min-w-0 flex-1 truncate rounded-lg border border-slate-200 bg-slate-50 px-3 py-2.5 text-xs text-slate-600 dark:border-slate-700 dark:bg-slate-950 dark:text-slate-300"},Ig=["disabled"],Rg={key:0,class:"border-t border-slate-200 pt-5 dark:border-slate-800"},Pg={key:0,class:"text-xs text-green-600 dark:text-green-400"},Og={key:1,class:"text-xs text-red-600 dark:text-red-400"},Mg={class:"card"},Lg={class:"flex items-start gap-3"},Ng={class:"min-w-0 flex-1"},Vg={class:"text-sm font-semibold text-slate-900 dark:text-white"},jg={class:"mt-1 text-xs text-slate-400"},Dg={key:0,class:"mt-4 rounded-lg border border-slate-200 bg-slate-50 px-3 py-2.5 font-mono text-xs text-slate-600 dark:border-slate-700 dark:bg-slate-950 dark:text-slate-300"},Bg={class:"block truncate"},Fg={key:1,class:"mt-3 flex flex-wrap gap-2"},Ug={__name:"WebAccessView",setup(e){const t=globalThis.__VNT_WEB_ACCESS__,s=Kt({enabled:!1,port:19099,global:!1,token:""}),n=oe(null),o=oe(!0),l=oe(!1),r=oe(""),i=oe(""),c=w=>{n.value=w,Object.assign(s,{enabled:w.enabled,port:w.port,global:w.global,token:w.token})},f=async()=>{o.value=!0,i.value="";try{if(!t)throw new Error("Web 访问设置仅在桌面客户端中提供");c(await t.status())}catch(w){i.value=w.message||String(w)}finally{o.value=!1}},u=async(w,p)=>{l.value=!0,i.value="",r.value="";try{c(await t.update({...s,...w,port:Number(w.port??s.port)})),r.value=p}catch(b){const k=b.message||String(b);try{c(await t.status())}catch{}i.value=k}finally{l.value=!1}},d=async()=>{const w=!s.enabled;await u({enabled:w},w?"Web 服务已启动":"Web 服务已关闭")},g=async()=>{const w=await t.generateToken();await u({token:w},s.enabled?"新令牌已生效,Web 服务已重新加载":"新令牌已生成")},h=async()=>{s.enabled||await u({},"监听设置已自动保存")},C=async()=>{await navigator.clipboard.writeText(s.token),r.value="访问令牌已复制"},x=async()=>{await navigator.clipboard.writeText(n.value.url),r.value="访问地址已复制"},L=async()=>{await t.openUrl(n.value.url)};return Ot(f),(w,p)=>(y(),E("div",mg,[p[9]||(p[9]=a("div",{class:"page-title"},[a("div",null,[a("h2",null,"Web 访问"),a("p",null,"从浏览器访问当前 VNT 进程,API 请求由持久访问令牌保护。")])],-1)),o.value?(y(),E("div",gg,"正在读取 Web 服务状态…")):O(t)?(y(),E(ie,{key:2},[a("section",bg,[a("div",_g,[p[2]||(p[2]=a("div",null,[a("h3",{class:"text-sm font-semibold text-slate-900 dark:text-white"},"启用 Web 服务"),a("p",{class:"mt-1 text-xs leading-5 text-slate-400"},"服务内置于桌面客户端,不会启动单独的 vnt2_web 进程。")],-1)),a("button",{type:"button",role:"switch","aria-label":"启用 Web 服务","aria-checked":s.enabled,disabled:l.value,class:G(["web-switch transition-colors disabled:opacity-50",s.enabled?"bg-indigo-600 dark:bg-indigo-500":"bg-slate-300 dark:bg-slate-600"]),onClick:d},[a("span",{class:G(["web-switch-knob bg-white shadow-sm",{"web-switch-knob-on":s.enabled}])},null,2)],10,xg)]),a("div",yg,[a("label",kg,[p[3]||(p[3]=a("span",{class:"mb-2 block text-sm font-medium text-slate-700 dark:text-slate-200"},"监听端口",-1)),me(a("input",{"onUpdate:modelValue":p[0]||(p[0]=b=>s.port=b),class:"input font-mono",type:"number",min:"1",max:"65535",disabled:l.value||s.enabled,onChange:h},null,40,wg),[[Oe,s.port,void 0,{number:!0}]])]),a("label",Cg,[p[5]||(p[5]=a("span",{class:"mb-2 block text-sm font-medium text-slate-700 dark:text-slate-200"},"监听范围",-1)),me(a("select",{"onUpdate:modelValue":p[1]||(p[1]=b=>s.global=b),class:"input",disabled:l.value||s.enabled,onChange:h},[...p[4]||(p[4]=[a("option",{value:!1},"仅本机(推荐)",-1),a("option",{value:!0},"局域网内所有设备",-1)])],40,Sg),[[cl,s.global]])])]),p[8]||(p[8]=a("p",{class:"-mt-3 text-xs text-slate-400"},"端口和监听范围会自动保存;需要修改时请先关闭 Web 服务。",-1)),a("div",null,[a("div",Eg,[p[6]||(p[6]=a("span",{class:"text-sm font-medium text-slate-700 dark:text-slate-200"},"访问令牌",-1)),a("button",{class:"text-xs font-medium text-indigo-600 hover:text-indigo-500 disabled:opacity-50 dark:text-indigo-400",type:"button",disabled:l.value,onClick:g},"更换令牌",8,Tg)]),a("div",Ag,[a("code",$g,V(s.token),1),a("button",{class:"btn-ghost shrink-0",type:"button",disabled:l.value,onClick:C},"复制令牌",8,Ig)]),p[7]||(p[7]=a("p",{class:"mt-2 text-xs text-slate-400"},"更换令牌后,已登录的浏览器需要使用新令牌重新鉴权。",-1))]),r.value||i.value?(y(),E("div",Rg,[r.value?(y(),E("span",Pg,V(r.value),1)):fe("",!0),i.value?(y(),E("span",Og,V(i.value),1)):fe("",!0)])):fe("",!0)]),a("section",Mg,[a("div",Lg,[a("span",{class:G(["mt-1 h-2.5 w-2.5 shrink-0 rounded-full",n.value?.running?"bg-green-500":"bg-slate-300 dark:bg-slate-600"])},null,2),a("div",Ng,[a("div",Vg,V(n.value?.running?"运行中":"未运行"),1),a("div",jg,"监听地址:"+V(n.value?.listenAddress),1),n.value?.running?(y(),E("div",Dg,[a("span",Bg,V(n.value.url),1)])):fe("",!0),n.value?.running?(y(),E("div",Fg,[a("button",{class:"btn-primary btn-sm",type:"button",onClick:L},"打开浏览器"),a("button",{class:"btn-ghost btn-sm",type:"button",onClick:x},"复制访问地址")])):fe("",!0)])])])],64)):(y(),E("div",vg,V(i.value),1))]))}},Hg=ya(Ug,[["__scopeId","data-v-2bc5d3bf"]]),Wg=[{path:"/",component:E0},{path:"/instances",component:lh},{path:"/general",redirect:"/instances"},{path:"/config",component:gm},{path:"/peers",component:ng},{path:"/routes",component:hg},{path:"/web-access",component:Hg}],Kg=pd({history:Kf(),routes:Wg}),Qn=document.querySelector('link[rel~="icon"]')||document.createElement("link");Qn.rel="icon";Qn.type="image/png";Qn.href=ml;document.head.appendChild(Qn);Yu(Np).use(ef()).use(Kg).mount("#app");