@devframes/plugin-code-server--assets 0.9.8 → 0.9.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,3 @@
1
+ (function(){let e=document.createElement(`link`).relList;if(e&&e.supports&&e.supports(`modulepreload`))return;for(let e of document.querySelectorAll(`link[rel="modulepreload"]`))n(e);new MutationObserver(e=>{for(let t of e)if(t.type===`childList`)for(let e of t.addedNodes)e.tagName===`LINK`&&e.rel===`modulepreload`&&n(e)}).observe(document,{childList:!0,subtree:!0});function t(e){let t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),t.credentials=e.crossOrigin===`use-credentials`?`include`:e.crossOrigin===`anonymous`?`omit`:`same-origin`,t}function n(e){if(e.ep)return;e.ep=!0;let n=t(e);fetch(e.href,n)}})();function e(e){let t=Object.create(null);for(let n of e.split(`,`))t[n]=1;return e=>e in t}var t={},n=[],r=()=>{},i=()=>!1,a=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),o=e=>e.startsWith(`onUpdate:`),s=Object.assign,c=(e,t)=>{let n=e.indexOf(t);n>-1&&e.splice(n,1)},l=Object.prototype.hasOwnProperty,u=(e,t)=>l.call(e,t),d=Array.isArray,f=e=>x(e)===`[object Map]`,p=e=>x(e)===`[object Set]`,m=e=>x(e)===`[object Date]`,h=e=>typeof e==`function`,g=e=>typeof e==`string`,_=e=>typeof e==`symbol`,v=e=>typeof e==`object`&&!!e,y=e=>(v(e)||h(e))&&h(e.then)&&h(e.catch),b=Object.prototype.toString,x=e=>b.call(e),S=e=>x(e).slice(8,-1),C=e=>x(e)===`[object Object]`,w=e=>g(e)&&e!==`NaN`&&e[0]!==`-`&&``+parseInt(e,10)===e,ee=e(`,key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted`),te=e=>{let t=Object.create(null);return(n=>t[n]||(t[n]=e(n)))},ne=/-\w/g,T=te(e=>e.replace(ne,e=>e.slice(1).toUpperCase())),re=/\B([A-Z])/g,E=te(e=>e.replace(re,`-$1`).toLowerCase()),ie=te(e=>e.charAt(0).toUpperCase()+e.slice(1)),ae=te(e=>e?`on${ie(e)}`:``),D=(e,t)=>!Object.is(e,t),oe=(e,...t)=>{for(let n=0;n<e.length;n++)e[n](...t)},O=(e,t,n,r=!1)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:r,value:n})},se=e=>{let t=parseFloat(e);return isNaN(t)?e:t},ce,le=()=>ce||=typeof globalThis<`u`?globalThis:typeof self<`u`?self:typeof window<`u`?window:typeof global<`u`?global:{};function ue(e){if(d(e)){let t={};for(let n=0;n<e.length;n++){let r=e[n],i=g(r)?me(r):ue(r);if(i)for(let e in i)t[e]=i[e]}return t}if(g(e)||v(e))return e}var de=/;(?![^(]*\))/g,fe=/:([^]+)/,pe=/\/\*[^]*?\*\//g;function me(e){let t={};return e.replace(pe,``).split(de).forEach(e=>{if(e){let n=e.split(fe);n.length>1&&(t[n[0].trim()]=n[1].trim())}}),t}function k(e){let t=``;if(g(e))t=e;else if(d(e))for(let n=0;n<e.length;n++){let r=k(e[n]);r&&(t+=r+` `)}else if(v(e))for(let n in e)e[n]&&(t+=n+` `);return t.trim()}var he=`itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`,ge=e(he);he+``;function _e(e){return!!e||e===``}function ve(e,t){if(e.length!==t.length)return!1;let n=!0;for(let r=0;n&&r<e.length;r++)n=be(e[r],t[r]);return n}function ye(e,t){if(e.size!==t.size)return!1;let n=Array.from(t),r=new Uint8Array(n.length);for(let t of e){let e=-1;for(let i=0;i<n.length;i++)if(!r[i]&&be(t,n[i])){e=i;break}if(e<0)return!1;r[e]=1}return!0}function be(e,t){if(e===t)return!0;let n=m(e),r=m(t);if(n||r)return n&&r?e.getTime()===t.getTime():!1;if(n=_(e),r=_(t),n||r)return e===t;if(n=d(e),r=d(t),n||r)return n&&r?ve(e,t):!1;if(n=v(e),r=v(t),n||r){if(!n||!r)return!1;if(n=f(e),r=f(t),n||r||(n=p(e),r=p(t),n||r))return n&&r?ye(e,t):!1;if(Object.keys(e).length!==Object.keys(t).length)return!1;for(let n in e){let r=e.hasOwnProperty(n),i=t.hasOwnProperty(n);if(r&&!i||!r&&i||!be(e[n],t[n]))return!1}}return String(e)===String(t)}var xe=e=>!!(e&&e.__v_isRef===!0),A=e=>g(e)?e:e==null?``:d(e)||v(e)&&(e.toString===b||!h(e.toString))?xe(e)?A(e.value):JSON.stringify(e,Se,2):String(e),Se=(e,t)=>xe(t)?Se(e,t.value):f(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((e,[t,n],r)=>(e[Ce(t,r)+` =>`]=n,e),{})}:p(t)?{[`Set(${t.size})`]:[...t.values()].map(e=>Ce(e))}:_(t)?Ce(t):v(t)&&!d(t)&&!C(t)?String(t):t,Ce=(e,t=``)=>_(e)?`Symbol(${e.description??t})`:e,j,we=class{constructor(e=!1){this.detached=e,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this._warnOnRun=!0,this.__v_skip=!0,!e&&j&&(j.active?(this.parent=j,this.index=(j.scopes||(j.scopes=[])).push(this)-1):(this._active=!1,this._warnOnRun=!1))}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let e,t;if(this.scopes){let n=this.scopes.slice();for(e=0,t=n.length;e<t;e++)n[e].pause()}for(e=0,t=this.effects.length;e<t;e++)this.effects[e].pause()}}resume(){if(this._active&&this._isPaused){this._isPaused=!1;let e,t;if(this.scopes){let n=this.scopes.slice();for(e=0,t=n.length;e<t;e++)n[e].resume()}let n=this.effects.slice();for(e=0,t=n.length;e<t;e++)n[e].resume()}}run(e){if(this._active){let t=j;try{return j=this,e()}finally{j=t}}}on(){++this._on===1&&(this.prevScope=j,j=this)}off(){if(this._on>0&&--this._on===0){if(j===this)j=this.prevScope;else{let e=j;for(;e;){if(e.prevScope===this){e.prevScope=this.prevScope;break}e=e.prevScope}}this.prevScope=void 0}}stop(e){if(this._active){this._active=!1;let t,n;for(t=0,n=this.effects.length;t<n;t++)this.effects[t].stop();for(this.effects.length=0,t=0,n=this.cleanups.length;t<n;t++)this.cleanups[t]();if(this.cleanups.length=0,this.scopes){let e=this.scopes.slice();for(t=0,n=e.length;t<n;t++)e[t].stop(!0);this.scopes.length=0}if(!this.detached&&this.parent&&!e){let e=this.parent.scopes.pop();e&&e!==this&&(this.parent.scopes[this.index]=e,e.index=this.index)}this.parent=void 0}}};function Te(){return j}function Ee(e,t=!1){j&&j.cleanups.push(e)}var M,De=new WeakSet,Oe=class{constructor(e){this.fn=e,this.deps=void 0,this.depsTail=void 0,this.flags=5,this.next=void 0,this.cleanup=void 0,this.scheduler=void 0,j&&(j.active?j.effects.push(this):this.flags&=-2)}pause(){this.flags|=64}resume(){this.flags&64&&(this.flags&=-65,De.has(this)&&(De.delete(this),this.trigger()))}notify(){this.flags&2&&!(this.flags&32)||this.flags&8||Me(this)}run(){if(!(this.flags&1))return this.fn();this.flags|=2,Ge(this),Fe(this);let e=M,t=Ve;M=this,Ve=!0;try{return this.fn()}finally{Ie(this),M=e,Ve=t,this.flags&=-3}}stop(){if(this.flags&1){for(let e=this.deps;e;e=e.nextDep)ze(e);this.deps=this.depsTail=void 0,Ge(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){this.flags&64?De.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){Le(this)&&this.run()}get dirty(){return Le(this)}},ke=0,Ae,je;function Me(e,t=!1){if(e.flags|=8,t){e.next=je,je=e;return}e.next=Ae,Ae=e}function Ne(){ke++}function Pe(){if(--ke>0)return;if(je){let e=je;for(je=void 0;e;){let t=e.next;e.next=void 0,e.flags&=-9,e=t}}let e;for(;Ae;){let t=Ae;for(Ae=void 0;t;){let n=t.next;if(t.next=void 0,t.flags&=-9,t.flags&1)try{t.trigger()}catch(t){e||=t}t=n}}if(e)throw e}function Fe(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function Ie(e){let t,n=e.depsTail,r=n;for(;r;){let e=r.prevDep;r.version===-1?(r===n&&(n=e),ze(r),Be(r)):t=r,r.dep.activeLink=r.prevActiveLink,r.prevActiveLink=void 0,r=e}e.deps=t,e.depsTail=n}function Le(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(Re(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function Re(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===Ke)||(e.globalVersion=Ke,!e.isSSR&&e.flags&128&&(!e.deps&&!e._dirty||!Le(e))))return;e.flags|=2;let t=e.dep,n=M,r=Ve;M=e,Ve=!0;try{Fe(e);let n=e.fn(e._value);(t.version===0||D(n,e._value))&&(e.flags|=128,e._value=n,t.version++)}catch(e){throw t.version++,e}finally{M=n,Ve=r,Ie(e),e.flags&=-3}}function ze(e,t=!1){let{dep:n,prevSub:r,nextSub:i}=e;if(r&&(r.nextSub=i,e.prevSub=void 0),i&&(i.prevSub=r,e.nextSub=void 0),n.subs===e&&(n.subs=r,!r&&n.computed)){n.computed.flags&=-5;for(let e=n.computed.deps;e;e=e.nextDep)ze(e,!0)}!t&&!--n.sc&&n.map&&n.map.delete(n.key)}function Be(e){let{prevDep:t,nextDep:n}=e;t&&(t.nextDep=n,e.prevDep=void 0),n&&(n.prevDep=t,e.nextDep=void 0)}var Ve=!0,He=[];function Ue(){He.push(Ve),Ve=!1}function We(){let e=He.pop();Ve=e===void 0||e}function Ge(e){let{cleanup:t}=e;if(e.cleanup=void 0,t){let e=M;M=void 0;try{t()}finally{M=e}}}var Ke=0,qe=class{constructor(e,t){this.sub=e,this.dep=t,this.version=t.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}},Je=class{constructor(e){this.computed=e,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(e){if(!M||!Ve||M===this.computed)return;let t=this.activeLink;if(t===void 0||t.sub!==M)t=this.activeLink=new qe(M,this),M.deps?(t.prevDep=M.depsTail,M.depsTail.nextDep=t,M.depsTail=t):M.deps=M.depsTail=t,Ye(t);else if(t.version===-1&&(t.version=this.version,t.nextDep)){let e=t.nextDep;e.prevDep=t.prevDep,t.prevDep&&(t.prevDep.nextDep=e),t.prevDep=M.depsTail,t.nextDep=void 0,M.depsTail.nextDep=t,M.depsTail=t,M.deps===t&&(M.deps=e)}return t}trigger(e){this.version++,Ke++,this.notify(e)}notify(e){Ne();try{for(let e=this.subs;e;e=e.prevSub)e.sub.notify()&&e.sub.dep.notify()}finally{Pe()}}};function Ye(e){if(e.dep.sc++,e.sub.flags&4){let t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let e=t.deps;e;e=e.nextDep)Ye(e)}let n=e.dep.subs;n!==e&&(e.prevSub=n,n&&(n.nextSub=e)),e.dep.subs=e}}var Xe=new WeakMap,Ze=Symbol(``),Qe=Symbol(``),$e=Symbol(``);function N(e,t,n){if(Ve&&M){let t=Xe.get(e);t||Xe.set(e,t=new Map);let r=t.get(n);r||(t.set(n,r=new Je),r.map=t,r.key=n),r.track()}}function et(e,t,n,r,i,a){let o=Xe.get(e);if(!o){Ke++;return}let s=e=>{e&&e.trigger()};if(Ne(),t===`clear`)o.forEach(s);else{let i=d(e),a=i&&w(n);if(i&&n===`length`){let e=Number(r);o.forEach((t,n)=>{(n===`length`||n===$e||!_(n)&&n>=e)&&s(t)})}else switch((n!==void 0||o.has(void 0))&&s(o.get(n)),a&&s(o.get($e)),t){case`add`:i?a&&s(o.get(`length`)):(s(o.get(Ze)),f(e)&&s(o.get(Qe)));break;case`delete`:i||(s(o.get(Ze)),f(e)&&s(o.get(Qe)));break;case`set`:f(e)&&s(o.get(Ze))}}Pe()}function tt(e){let t=F(e);return t===e?t:(N(t,`iterate`,$e),P(e)?t:t.map(Ht))}function nt(e){return N(e=F(e),`iterate`,$e),e}function rt(e,t){return zt(e)?Ut(Rt(e)?Ht(t):t):Ht(t)}var it={__proto__:null,[Symbol.iterator](){return at(this,Symbol.iterator,e=>rt(this,e))},concat(...e){return tt(this).concat(...e.map(e=>d(e)?tt(e):e))},entries(){return at(this,`entries`,e=>(e[1]=rt(this,e[1]),e))},every(e,t){return st(this,`every`,e,t,void 0,arguments)},filter(e,t){return st(this,`filter`,e,t,e=>e.map(e=>rt(this,e)),arguments)},find(e,t){return st(this,`find`,e,t,e=>rt(this,e),arguments)},findIndex(e,t){return st(this,`findIndex`,e,t,void 0,arguments)},findLast(e,t){return st(this,`findLast`,e,t,e=>rt(this,e),arguments)},findLastIndex(e,t){return st(this,`findLastIndex`,e,t,void 0,arguments)},forEach(e,t){return st(this,`forEach`,e,t,void 0,arguments)},includes(...e){return lt(this,`includes`,e)},indexOf(...e){return lt(this,`indexOf`,e)},join(e){return tt(this).join(e)},lastIndexOf(...e){return lt(this,`lastIndexOf`,e)},map(e,t){return st(this,`map`,e,t,void 0,arguments)},pop(){return ut(this,`pop`)},push(...e){return ut(this,`push`,e)},reduce(e,...t){return ct(this,`reduce`,e,t)},reduceRight(e,...t){return ct(this,`reduceRight`,e,t)},shift(){return ut(this,`shift`)},some(e,t){return st(this,`some`,e,t,void 0,arguments)},splice(...e){return ut(this,`splice`,e)},toReversed(){return tt(this).toReversed()},toSorted(e){return tt(this).toSorted(e)},toSpliced(...e){return tt(this).toSpliced(...e)},unshift(...e){return ut(this,`unshift`,e)},values(){return at(this,`values`,e=>rt(this,e))}};function at(e,t,n){let r=nt(e),i=r[t]();return r!==e&&!P(e)&&(i._next=i.next,i.next=()=>{let e=i._next();return e.done||(e.value=n(e.value)),e}),i}var ot=Array.prototype;function st(e,t,n,r,i,a){let o=nt(e),s=o!==e&&!P(e),c=o[t];if(c!==ot[t]){let t=c.apply(e,a);return s?Ht(t):t}let l=n;o!==e&&(s?l=function(t,r){return n.call(this,rt(e,t),r,e)}:n.length>2&&(l=function(t,r){return n.call(this,t,r,e)}));let u=c.call(o,l,r);return s&&i?i(u):u}function ct(e,t,n,r){let i=nt(e),a=i!==e&&!P(e),o=n,s=!1;i!==e&&(a?(s=r.length===0,o=function(t,r,i){return s&&(s=!1,t=rt(e,t)),n.call(this,t,rt(e,r),i,e)}):n.length>3&&(o=function(t,r,i){return n.call(this,t,r,i,e)}));let c=i[t](o,...r);return s?rt(e,c):c}function lt(e,t,n){let r=F(e);N(r,`iterate`,$e);let i=r[t](...n);return(i===-1||i===!1)&&Bt(n[0])?(n[0]=F(n[0]),r[t](...n)):i}function ut(e,t,n=[]){Ue(),Ne();let r=F(e)[t].apply(e,n);return Pe(),We(),r}var dt=e(`__proto__,__v_isRef,__isVue`),ft=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!==`arguments`&&e!==`caller`).map(e=>Symbol[e]).filter(_));function pt(e){_(e)||(e=String(e));let t=F(this);return N(t,`has`,e),t.hasOwnProperty(e)}var mt=class{constructor(e=!1,t=!1){this._isReadonly=e,this._isShallow=t}get(e,t,n){if(t===`__v_skip`)return e.__v_skip;let r=this._isReadonly,i=this._isShallow;if(t===`__v_isReactive`)return!r;if(t===`__v_isReadonly`)return r;if(t===`__v_isShallow`)return i;if(t===`__v_raw`)return n===(r?i?Mt:jt:i?At:kt).get(e)||Object.getPrototypeOf(e)===Object.getPrototypeOf(n)?e:void 0;let a=d(e);if(!r){let e;if(a&&(e=it[t]))return e;if(t===`hasOwnProperty`)return pt}let o=Reflect.get(e,t,I(e)?e:n);if((_(t)?ft.has(t):dt(t))||(r||N(e,`get`,t),i))return o;if(I(o)){let e=a&&w(t)?o:o.value;return r&&v(e)?It(e):e}return v(o)?r?It(o):Pt(o):o}},ht=class extends mt{constructor(e=!1){super(!1,e)}set(e,t,n,r){let i=e[t],a=d(e)&&w(t);if(!this._isShallow){let e=zt(i);if(!P(n)&&!zt(n)&&(i=F(i),n=F(n)),!a&&I(i)&&!I(n))return e||(i.value=n),!0}let o=a?Number(t)<e.length:u(e,t),s=Reflect.set(e,t,n,I(e)?e:r);return e===F(r)&&s&&(o?D(n,i)&&et(e,`set`,t,n,i):et(e,`add`,t,n)),s}deleteProperty(e,t){let n=u(e,t),r=e[t],i=Reflect.deleteProperty(e,t);return i&&n&&et(e,`delete`,t,void 0,r),i}has(e,t){let n=Reflect.has(e,t);return(!_(t)||!ft.has(t))&&N(e,`has`,t),n}ownKeys(e){return N(e,`iterate`,d(e)?`length`:Ze),Reflect.ownKeys(e)}},gt=class extends mt{constructor(e=!1){super(!0,e)}set(e,t){return!0}deleteProperty(e,t){return!0}},_t=new ht,vt=new gt,yt=new ht(!0),bt=e=>e,xt=e=>Reflect.getPrototypeOf(e);function St(e,t,n){return function(...r){let i=this.__v_raw,a=F(i),o=f(a),c=e===`entries`||e===Symbol.iterator&&o,l=e===`keys`&&o,u=i[e](...r),d=n?bt:t?Ut:Ht;return!t&&N(a,`iterate`,l?Qe:Ze),s(Object.create(u),{next(){let{value:e,done:t}=u.next();return t?{value:e,done:t}:{value:c?[d(e[0]),d(e[1])]:d(e),done:t}}})}}function Ct(e){return function(...t){return e===`delete`?!1:e===`clear`?void 0:this}}function wt(e,t){let n={get(n){let r=this.__v_raw,i=F(r),a=F(n);e||(D(n,a)&&N(i,`get`,n),N(i,`get`,a));let{has:o}=xt(i),s=t?bt:e?Ut:Ht;if(o.call(i,n))return s(r.get(n));if(o.call(i,a))return s(r.get(a));r!==i&&r.get(n)},get size(){let t=this.__v_raw;return!e&&N(F(t),`iterate`,Ze),t.size},has(t){let n=this.__v_raw,r=F(n),i=F(t);return e||(D(t,i)&&N(r,`has`,t),N(r,`has`,i)),t===i?n.has(t):n.has(t)||n.has(i)},forEach(n,r){let i=this,a=i.__v_raw,o=F(a),s=t?bt:e?Ut:Ht;return!e&&N(o,`iterate`,Ze),a.forEach((e,t)=>n.call(r,s(e),s(t),i))}};return s(n,e?{add:Ct(`add`),set:Ct(`set`),delete:Ct(`delete`),clear:Ct(`clear`)}:{add(e){let n=F(this),r=xt(n),i=F(e),a=!t&&!P(e)&&!zt(e)?i:e;return r.has.call(n,a)||D(e,a)&&r.has.call(n,e)||D(i,a)&&r.has.call(n,i)||(n.add(a),et(n,`add`,a,a)),this},set(e,n){!t&&!P(n)&&!zt(n)&&(n=F(n));let r=F(this),{has:i,get:a}=xt(r),o=i.call(r,e);o||=(e=F(e),i.call(r,e));let s=a.call(r,e);return r.set(e,n),o?D(n,s)&&et(r,`set`,e,n,s):et(r,`add`,e,n),this},delete(e){let t=F(this),{has:n,get:r}=xt(t),i=n.call(t,e);i||=(e=F(e),n.call(t,e));let a=r?r.call(t,e):void 0,o=t.delete(e);return i&&et(t,`delete`,e,void 0,a),o},clear(){let e=F(this),t=e.size!==0,n=e.clear();return t&&et(e,`clear`,void 0,void 0,void 0),n}}),[`keys`,`values`,`entries`,Symbol.iterator].forEach(r=>{n[r]=St(r,e,t)}),n}function Tt(e,t){let n=wt(e,t);return(t,r,i)=>r===`__v_isReactive`?!e:r===`__v_isReadonly`?e:r===`__v_raw`?t:Reflect.get(u(n,r)&&r in t?n:t,r,i)}var Et={get:Tt(!1,!1)},Dt={get:Tt(!1,!0)},Ot={get:Tt(!0,!1)},kt=new WeakMap,At=new WeakMap,jt=new WeakMap,Mt=new WeakMap;function Nt(e){switch(e){case`Object`:case`Array`:return 1;case`Map`:case`Set`:case`WeakMap`:case`WeakSet`:return 2;default:return 0}}function Pt(e){return zt(e)?e:Lt(e,!1,_t,Et,kt)}function Ft(e){return Lt(e,!1,yt,Dt,At)}function It(e){return Lt(e,!0,vt,Ot,jt)}function Lt(e,t,n,r,i){if(!v(e)||e.__v_raw&&!(t&&e.__v_isReactive)||e.__v_skip||!Object.isExtensible(e))return e;let a=i.get(e);if(a)return a;let o=Nt(S(e));if(o===0)return e;let s=new Proxy(e,o===2?r:n);return i.set(e,s),s}function Rt(e){return zt(e)?Rt(e.__v_raw):!!(e&&e.__v_isReactive)}function zt(e){return!!(e&&e.__v_isReadonly)}function P(e){return!!(e&&e.__v_isShallow)}function Bt(e){return e?!!e.__v_raw:!1}function F(e){let t=e&&e.__v_raw;return t?F(t):e}function Vt(e){return!u(e,`__v_skip`)&&Object.isExtensible(e)&&O(e,`__v_skip`,!0),e}var Ht=e=>v(e)?Pt(e):e,Ut=e=>v(e)?It(e):e;function I(e){return e?e.__v_isRef===!0:!1}function Wt(e){return Kt(e,!1)}function Gt(e){return Kt(e,!0)}function Kt(e,t){return I(e)?e:new qt(e,t)}var qt=class{constructor(e,t){this.dep=new Je,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=t?e:F(e),this._value=t?e:Ht(e),this.__v_isShallow=t}get value(){return this.dep.track(),this._value}set value(e){let t=this._rawValue,n=this.__v_isShallow||P(e)||zt(e);e=n?e:F(e),D(e,t)&&(this._rawValue=e,this._value=n?e:Ht(e),this.dep.trigger())}};function L(e){return I(e)?e.value:e}var Jt={get:(e,t,n)=>t===`__v_raw`?e:L(Reflect.get(e,t,n)),set:(e,t,n,r)=>{let i=e[t];return I(i)&&!I(n)?(i.value=n,!0):Reflect.set(e,t,n,r)}};function Yt(e){return Rt(e)?e:new Proxy(e,Jt)}var Xt=class{constructor(e,t,n){this.fn=e,this.setter=t,this._value=void 0,this.dep=new Je(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=Ke-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!t,this.isSSR=n}notify(){if(this.flags|=16,!(this.flags&8)&&M!==this)return Me(this,!0),!0}get value(){let e=this.dep.track();return Re(this),e&&(e.version=this.dep.version),this._value}set value(e){this.setter&&this.setter(e)}};function Zt(e,t,n=!1){let r,i;return h(e)?r=e:(r=e.get,i=e.set),new Xt(r,i,n)}var Qt={},$t=new WeakMap,en=void 0;function tn(e,t=!1,n=en){if(n){let t=$t.get(n);t||$t.set(n,t=[]),t.push(e)}}function nn(e,n,i=t){let{immediate:a,deep:o,once:s,scheduler:l,augmentJob:u,call:f}=i,p=e=>o?e:P(e)||o===!1||o===0?rn(e,1):rn(e),m,g,_,v,y=!1,b=!1;if(I(e)?(g=()=>e.value,y=P(e)):Rt(e)?(g=()=>p(e),y=!0):d(e)?(b=!0,y=e.some(e=>Rt(e)||P(e)),g=()=>e.map(e=>{if(I(e))return e.value;if(Rt(e))return p(e);if(h(e))return f?f(e,2):e()})):g=h(e)?n?f?()=>f(e,2):e:()=>{if(_){Ue();try{_()}finally{We()}}let t=en;en=m;try{return f?f(e,3,[v]):e(v)}finally{en=t}}:r,n&&o){let e=g,t=o===!0?1/0:o;g=()=>rn(e(),t)}let x=Te(),S=()=>{m.stop(),x&&x.active&&c(x.effects,m)};if(s&&n){let e=n;n=(...t)=>{let n=e(...t);return S(),n}}let C=b?Array(e.length).fill(Qt):Qt,w=e=>{if(!(!(m.flags&1)||!m.dirty&&!e)){if(n){let t=m.run();if(e||o||y||(b?t.some((e,t)=>D(e,C[t])):D(t,C))){_&&_();let e=en;en=m;try{let e=[t,C===Qt?void 0:b&&C[0]===Qt?[]:C,v];C=t,f?f(n,3,e):n(...e)}finally{en=e}}}else m.run()}};return u&&u(w),m=new Oe(g),m.scheduler=l?()=>l(w,!1):w,v=e=>tn(e,!1,m),_=m.onStop=()=>{let e=$t.get(m);if(e){if(f)f(e,4);else for(let t of e)t();$t.delete(m)}},n?a?w(!0):C=m.run():l?l(w.bind(null,!0),!0):m.run(),S.pause=m.pause.bind(m),S.resume=m.resume.bind(m),S.stop=S,S}function rn(e,t=1/0,n){if(t<=0||!v(e)||e.__v_skip||(n||=new Map,(n.get(e)||0)>=t))return e;if(n.set(e,t),t--,I(e))rn(e.value,t,n);else if(d(e))for(let r=0;r<e.length;r++)rn(e[r],t,n);else if(p(e)||f(e))e.forEach(e=>{rn(e,t,n)});else if(C(e)){for(let r in e)rn(e[r],t,n);for(let r of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,r)&&rn(e[r],t,n)}return e}function an(e,t,n,r){try{return r?e(...r):e()}catch(e){sn(e,t,n)}}function on(e,t,n,r){if(h(e)){let i=an(e,t,n,r);return i&&y(i)&&i.catch(e=>{sn(e,t,n)}),i}if(d(e)){let i=[];for(let a=0;a<e.length;a++)i.push(on(e[a],t,n,r));return i}}function sn(e,n,r,i=!0){let a=n?n.vnode:null,{errorHandler:o,throwUnhandledErrorInProduction:s}=n&&n.appContext.config||t;if(n){let t=n.parent,i=n.proxy,a=`https://vuejs.org/error-reference/#runtime-${r}`;for(;t;){let n=t.ec;if(n){for(let t=0;t<n.length;t++)if(n[t](e,i,a)===!1)return}t=t.parent}if(o){Ue(),an(o,null,10,[e,i,a]),We();return}}cn(e,r,a,i,s)}function cn(e,t,n,r=!0,i=!1){if(i)throw e;console.error(e)}var R=[],ln=-1,un=[],dn=null,fn=0,pn=Promise.resolve(),mn=null;function hn(e){let t=mn||pn;return e?t.then(this?e.bind(this):e):t}function gn(e){let t=ln+1,n=R.length;for(;t<n;){let r=t+n>>>1,i=R[r],a=Sn(i);a<e||a===e&&i.flags&2?t=r+1:n=r}return t}function _n(e){if(!(e.flags&1)){let t=Sn(e),n=R[R.length-1];!n||!(e.flags&2)&&t>=Sn(n)?R.push(e):R.splice(gn(t),0,e),e.flags|=1,vn()}}function vn(){mn||=pn.then(Cn)}function yn(e){if(!d(e))dn&&e.id===-1?dn.splice(fn+1,0,e):e.flags&1||(un.push(e),e.flags|=1);else for(let t=0;t<e.length;t++)un.push(e[t]);vn()}function bn(e,t,n=ln+1){for(;n<R.length;n++){let t=R[n];if(t&&t.flags&2){if(e&&t.id!==e.uid)continue;R.splice(n,1),n--,t.flags&4&&(t.flags&=-2),t(),t.flags&4||(t.flags&=-2)}}}function xn(e){if(un.length){let e=[...new Set(un)].sort((e,t)=>Sn(e)-Sn(t));if(un.length=0,dn){for(let t=0;t<e.length;t++)dn.push(e[t]);return}for(dn=e,fn=0;fn<dn.length;fn++){let e=dn[fn];e.flags&4&&(e.flags&=-2),e.flags&8||e(),e.flags&=-2}dn=null,fn=0}}var Sn=e=>e.id==null?e.flags&2?-1:1/0:e.id;function Cn(e){try{for(ln=0;ln<R.length;ln++){let e=R[ln];e&&!(e.flags&8)&&(e.flags&4&&(e.flags&=-2),an(e,e.i,e.i?15:14),e.flags&4||(e.flags&=-2))}}finally{for(;ln<R.length;ln++){let e=R[ln];e&&(e.flags&=-2)}ln=-1,R.length=0,xn(e),mn=null,(R.length||un.length)&&Cn(e)}}var z=null,wn=null;function Tn(e){let t=z;return z=e,wn=e&&e.type.__scopeId||null,t}function En(e,t=z,n){if(!t||e._n)return e;let r=(...n)=>{r._d&&Ri(-1);let i=Tn(t),a=Fi.length,o;try{o=e(...n)}finally{for(let e=Fi.length;e>a;e--)Ii();Tn(i),r._d&&Ri(1)}return o};return r._n=!0,r._c=!0,r._d=!0,r}function Dn(e,n){if(z===null)return e;let r=va(z),i=e.dirs||=[];for(let e=0;e<n.length;e++){let[a,o,s,c=t]=n[e];a&&(h(a)&&(a={mounted:a,updated:a}),a.deep&&rn(o),i.push({dir:a,instance:r,value:o,oldValue:void 0,arg:s,modifiers:c}))}return e}function On(e,t,n,r){let i=e.dirs,a=t&&t.dirs;for(let o=0;o<i.length;o++){let s=i[o];a&&(s.oldValue=a[o].value);let c=s.dir[r];c&&(Ue(),on(c,n,8,[e.el,s,e,t]),We())}}function kn(e,t){if(J){let n=J.provides,r=J.parent&&J.parent.provides;r===n&&(n=J.provides=Object.create(r)),n[e]=t}}function An(e,t,n=!1){let r=aa();if(r||Ur){let i=Ur?Ur._context.provides:r?r.parent==null||r.ce?r.vnode.appContext&&r.vnode.appContext.provides:r.parent.provides:void 0;if(i&&e in i)return i[e];if(arguments.length>1)return n&&h(t)?t.call(r&&r.proxy):t}}var jn=Symbol.for(`v-scx`),Mn=()=>An(jn);function Nn(e,t,n){return Pn(e,t,n)}function Pn(e,n,i=t){let{immediate:a,deep:o,flush:c,once:l}=i,u=s({},i),d=n&&a||!n&&c!==`post`,f;if(da){if(c===`sync`){let e=Mn();f=e.__watcherHandles||=[]}else if(!d){let e=()=>{};return e.stop=r,e.resume=r,e.pause=r,e}}let p=J;u.call=(e,t,n)=>on(e,p,t,n);let m=!1;c===`post`?u.scheduler=e=>{V(e,p&&p.suspense)}:c!==`sync`&&(m=!0,u.scheduler=(e,t)=>{t?e():_n(e)}),u.augmentJob=e=>{n&&(e.flags|=4),m&&(e.flags|=2,p&&(e.id=p.uid,e.i=p))};let h=nn(e,n,u);return da&&(f?f.push(h):d&&h()),h}function Fn(e,t,n){let r=this.proxy,i=g(e)?e.includes(`.`)?In(r,e):()=>r[e]:e.bind(r,r),a;h(t)?a=t:(a=t.handler,n=t);let o=ca(this),s=Pn(i,a.bind(r),n);return o(),s}function In(e,t){let n=t.split(`.`);return()=>{let t=e;for(let e=0;e<n.length&&t;e++)t=t[n[e]];return t}}var Ln=Symbol(`_vte`),Rn=e=>e.__isTeleport,zn=Symbol(`_leaveCb`);function Bn(e){let t=e[0];if(e.length>1){for(let n of e)if(n.type!==Ni){t=n;break}}return t}function Vn(e){if(!Xn(e))return Rn(e.type)&&e.children?Bn(e.children):e;if(e.component)return e.component.subTree;let{shapeFlag:t,children:n}=e;if(n){if(t&16)return n[0];if(t&32&&h(n.default))return n.default()}}function Hn(e,t){if(e.shapeFlag&6&&e.component){e.transition=t;let n=e.component.subTree;Hn(Rn(n.type)&&Vn(n)||n,t)}else e.shapeFlag&128?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function Un(e,t){return h(e)?s({name:e.name},t,{setup:e}):e}function Wn(e){e.ids=[e.ids[0]+e.ids[2]+++`-`,0,0]}function Gn(e,t){let n;return!!((n=Object.getOwnPropertyDescriptor(e,t))&&!n.configurable)}var Kn=new WeakMap;function qn(e,n,r,a,o=!1){if(d(e)){e.forEach((e,t)=>qn(e,n&&(d(n)?n[t]:n),r,a,o));return}if(Yn(a)&&!o){a.shapeFlag&512&&a.type.__asyncResolved&&a.component.subTree.component&&qn(e,n,r,a.component.subTree);return}let s=a.shapeFlag&4?va(a.component):a.el,l=o?null:s,{i:f,r:p}=e,m=n&&n.r,_=f.refs===t?f.refs={}:f.refs,v=f.setupState,y=F(v),b=v===t?i:e=>!Gn(_,e)&&u(y,e),x=(e,t)=>!(t&&Gn(_,t));if(m!=null&&m!==p){if(Jn(n),g(m))_[m]=null,b(m)&&(v[m]=null);else if(I(m)){let e=n;x(m,e.k)&&(m.value=null),e.k&&(_[e.k]=null)}}if(h(p))an(p,f,12,[l,_]);else{let t=g(p),n=I(p);if(t||n){let i=()=>{if(e.f){let n=t?b(p)?v[p]:_[p]:x(p)||!e.k?p.value:_[e.k];if(o)d(n)&&c(n,s);else if(d(n))n.includes(s)||n.push(s);else if(t)_[p]=[s],b(p)&&(v[p]=_[p]);else{let t=[s];x(p,e.k)&&(p.value=t),e.k&&(_[e.k]=t)}}else t?(_[p]=l,b(p)&&(v[p]=l)):n&&(x(p,e.k)&&(p.value=l),e.k&&(_[e.k]=l))};if(l){let t=()=>{i(),Kn.delete(e)};t.id=-1,Kn.set(e,t),V(t,r)}else Jn(e),i()}}}function Jn(e){let t=Kn.get(e);t&&(t.flags|=8,Kn.delete(e))}le().requestIdleCallback,le().cancelIdleCallback;var Yn=e=>!!e.type.__asyncLoader,Xn=e=>e.type.__isKeepAlive;function Zn(e,t){$n(e,`a`,t)}function Qn(e,t){$n(e,`da`,t)}function $n(e,t,n=J){let r=e.__wdc||=()=>{let t=n;for(;t;){if(t.isDeactivated)return;t=t.parent}return e()};if(tr(t,r,n),n){let e=n.parent;for(;e&&e.parent;)Xn(e.parent.vnode)&&er(r,t,n,e),e=e.parent}}function er(e,t,n,r){let i=tr(t,e,r,!0);cr(()=>{c(r[t],i)},n)}function tr(e,t,n=J,r=!1){if(n){let i=n[e]||(n[e]=[]),a=t.__weh||=(...r)=>{Ue();let i=ca(n),a=on(t,n,e,r);return i(),We(),a};return r?i.unshift(a):i.push(a),a}}var nr=e=>(t,n=J)=>{(!da||e===`sp`)&&tr(e,(...e)=>t(...e),n)},rr=nr(`bm`),ir=nr(`m`),ar=nr(`bu`),or=nr(`u`),sr=nr(`bum`),cr=nr(`um`),lr=nr(`sp`),ur=nr(`rtg`),dr=nr(`rtc`);function fr(e,t=J){tr(`ec`,e,t)}var pr=`components`,mr=Symbol.for(`v-ndc`);function hr(e){return g(e)?gr(pr,e,!1)||e:e||mr}function gr(e,t,n=!0,r=!1){let i=z||J;if(i){let n=i.type;if(e===pr){let e=ya(n,!1);if(e&&(e===t||e===T(t)||e===ie(T(t))))return n}let a=_r(i[e]||n[e],t)||_r(i.appContext[e],t);return!a&&r?n:a}}function _r(e,t){return e&&(e[t]||e[T(t)]||e[ie(T(t))])}function vr(e,t,n,r){let i,a=n&&n[r],o=d(e);if(o||g(e)){let n=o&&Rt(e),r=!1,s=!1;n&&(r=!P(e),s=zt(e),e=nt(e)),i=Array(e.length);for(let n=0,o=e.length;n<o;n++)i[n]=t(r?s?Ut(Ht(e[n])):Ht(e[n]):e[n],n,void 0,a&&a[n])}else if(typeof e==`number`){i=Array(e);for(let n=0;n<e;n++)i[n]=t(n+1,n,void 0,a&&a[n])}else if(v(e)){if(e[Symbol.iterator])i=Array.from(e,(e,n)=>t(e,n,void 0,a&&a[n]));else{let n=Object.keys(e);i=Array(n.length);for(let r=0,o=n.length;r<o;r++){let o=n[r];i[r]=t(e[o],o,r,a&&a[r])}}}else i=[];return n&&(n[r]=i),i}function yr(e,t,n,r,i,a){if(n??={},z.ce||z.parent&&Yn(z.parent)&&z.parent.ce){let e=a!=null&&n.key==null?s({},n,{key:a}):n,i=Object.keys(e).length>0;return t!=="default"&&(e.name=t),W(),Bi(H,null,[q(`slot`,e,r&&r())],i?-2:64)}let o=e[t];o&&o._c&&(o._d=!1);let c=Fi.length;W();let l;try{let i=o&&br(o(n)),s=n.key||a||i&&i.key;l=Bi(H,{key:(s&&!_(s)?s:`_${t}`)+(!i&&r?`_fb`:``)},i||(r?r():[]),i&&e._===1?64:-2)}catch(e){for(let e=Fi.length;e>c;e--)Ii();throw e}finally{o&&o._c&&(o._d=!0)}return!i&&l.scopeId&&(l.slotScopeIds=[l.scopeId+`-s`]),l}function br(e){return e.some(e=>!Vi(e)||!(e.type===Ni||e.type===H&&!br(e.children)))?e:null}var xr=e=>e?ua(e)?va(e):xr(e.parent):null,Sr=s(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=>xr(e.parent),$root:e=>xr(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>jr(e),$forceUpdate:e=>e.f||=()=>{_n(e.update)},$nextTick:e=>e.n||=hn.bind(e.proxy),$watch:e=>Fn.bind(e)}),Cr=(e,n)=>e!==t&&!e.__isScriptSetup&&u(e,n),wr={get({_:e},n){if(n===`__v_skip`)return!0;let{ctx:r,setupState:i,data:a,props:o,accessCache:s,type:c,appContext:l}=e;if(n[0]!==`$`){let e=s[n];if(e!==void 0)switch(e){case 1:return i[n];case 2:return a[n];case 4:return r[n];case 3:return o[n]}else if(Cr(i,n))return s[n]=1,i[n];else if(a!==t&&u(a,n))return s[n]=2,a[n];else if(u(o,n))return s[n]=3,o[n];else if(r!==t&&u(r,n))return s[n]=4,r[n];else Er&&(s[n]=0)}let d=Sr[n],f,p;if(d)return n===`$attrs`&&N(e.attrs,`get`,``),d(e);if((f=c.__cssModules)&&(f=f[n]))return f;if(r!==t&&u(r,n))return s[n]=4,r[n];if(p=l.config.globalProperties,u(p,n))return p[n]},set({_:e},n,r){let{data:i,setupState:a,ctx:o}=e;return Cr(a,n)?(a[n]=r,!0):i!==t&&u(i,n)?(i[n]=r,!0):u(e.props,n)||n[0]===`$`&&n.slice(1)in e?!1:(o[n]=r,!0)},has({_:{data:e,setupState:n,accessCache:r,ctx:i,appContext:a,props:o,type:s}},c){let l;return!!(r[c]||e!==t&&c[0]!==`$`&&u(e,c)||Cr(n,c)||u(o,c)||u(i,c)||u(Sr,c)||u(a.config.globalProperties,c)||(l=s.__cssModules)&&l[c])},defineProperty(e,t,n){return n.get==null?u(n,`value`)&&this.set(e,t,n.value,null):e._.accessCache[t]=0,Reflect.defineProperty(e,t,n)}};function Tr(e){return d(e)?e.reduce((e,t)=>(e[t]=null,e),{}):e}var Er=!0;function Dr(e){let t=jr(e),n=e.proxy,i=e.ctx;Er=!1,t.beforeCreate&&kr(t.beforeCreate,e,`bc`);let{data:a,computed:o,methods:s,watch:c,provide:l,inject:u,created:f,beforeMount:p,mounted:m,beforeUpdate:g,updated:_,activated:y,deactivated:b,beforeDestroy:x,beforeUnmount:S,destroyed:C,unmounted:w,render:ee,renderTracked:te,renderTriggered:ne,errorCaptured:T,serverPrefetch:re,expose:E,inheritAttrs:ie,components:ae,directives:D,filters:oe}=t;if(u&&Or(u,i,null),s)for(let e in s){let t=s[e];h(t)&&(i[e]=t.bind(n))}if(a){let t=a.call(n,n);v(t)&&(e.data=Pt(t))}if(Er=!0,o)for(let e in o){let t=o[e],a=Y({get:h(t)?t.bind(n,n):h(t.get)?t.get.bind(n,n):r,set:!h(t)&&h(t.set)?t.set.bind(n):r});Object.defineProperty(i,e,{enumerable:!0,configurable:!0,get:()=>a.value,set:e=>a.value=e})}if(c)for(let e in c)Ar(c[e],i,n,e);if(l){let e=h(l)?l.call(n):l;Reflect.ownKeys(e).forEach(t=>{kn(t,e[t])})}f&&kr(f,e,`c`);function O(e,t){d(t)?t.forEach(t=>e(t.bind(n))):t&&e(t.bind(n))}if(O(rr,p),O(ir,m),O(ar,g),O(or,_),O(Zn,y),O(Qn,b),O(fr,T),O(dr,te),O(ur,ne),O(sr,S),O(cr,w),O(lr,re),d(E)){if(E.length){let t=e.exposed||={};E.forEach(e=>{Object.defineProperty(t,e,{get:()=>n[e],set:t=>n[e]=t,enumerable:!0})})}else e.exposed||={}}ee&&e.render===r&&(e.render=ee),ie!=null&&(e.inheritAttrs=ie),ae&&(e.components=ae),D&&(e.directives=D),re&&Wn(e)}function Or(e,t,n=r){d(e)&&(e=Ir(e));for(let n in e){let r=e[n],i;i=v(r)?`default`in r?An(r.from||n,r.default,!0):An(r.from||n):An(r),I(i)?Object.defineProperty(t,n,{enumerable:!0,configurable:!0,get:()=>i.value,set:e=>i.value=e}):t[n]=i}}function kr(e,t,n){on(d(e)?e.map(e=>e.bind(t.proxy)):e.bind(t.proxy),t,n)}function Ar(e,t,n,r){let i=r.includes(`.`)?In(n,r):()=>n[r];if(g(e)){let n=t[e];h(n)&&Nn(i,n)}else if(h(e))Nn(i,e.bind(n));else if(v(e)){if(d(e))e.forEach(e=>Ar(e,t,n,r));else{let r=h(e.handler)?e.handler.bind(n):t[e.handler];h(r)&&Nn(i,r,e)}}}function jr(e){let t=e.type,{mixins:n,extends:r}=t,{mixins:i,optionsCache:a,config:{optionMergeStrategies:o}}=e.appContext,s=a.get(t),c;return s?c=s:!i.length&&!n&&!r?c=t:(c={},i.length&&i.forEach(e=>Mr(c,e,o,!0)),Mr(c,t,o)),v(t)&&a.set(t,c),c}function Mr(e,t,n,r=!1){let{mixins:i,extends:a}=t;a&&Mr(e,a,n,!0),i&&i.forEach(t=>Mr(e,t,n,!0));for(let i in t)if(!(r&&i===`expose`)){let r=Nr[i]||n&&n[i];e[i]=r?r(e[i],t[i]):t[i]}return e}var Nr={data:Pr,props:Rr,emits:Rr,methods:Lr,computed:Lr,beforeCreate:B,created:B,beforeMount:B,mounted:B,beforeUpdate:B,updated:B,beforeDestroy:B,beforeUnmount:B,destroyed:B,unmounted:B,activated:B,deactivated:B,errorCaptured:B,serverPrefetch:B,components:Lr,directives:Lr,watch:zr,provide:Pr,inject:Fr};function Pr(e,t){return t?e?function(){return s(h(e)?e.call(this,this):e,h(t)?t.call(this,this):t)}:t:e}function Fr(e,t){return Lr(Ir(e),Ir(t))}function Ir(e){if(d(e)){let t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function B(e,t){return e?[...new Set([].concat(e,t))]:t}function Lr(e,t){return e?s(Object.create(null),e,t):t}function Rr(e,t){return e?d(e)&&d(t)?[...new Set([...e,...t])]:s(Object.create(null),Tr(e),Tr(t??{})):t}function zr(e,t){if(!e)return t;if(!t)return e;let n=s(Object.create(null),e);for(let r in t)n[r]=B(e[r],t[r]);return n}function Br(){return{app:null,config:{isNativeTag:i,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}}var Vr=0;function Hr(e,t){return function(n,r=null){h(n)||(n=s({},n)),r!=null&&!v(r)&&(r=null);let i=Br(),a=new WeakSet,o=[],c=!1,l=i.app={_uid:Vr++,_component:n,_props:r,_container:null,_context:i,_instance:null,version:xa,get config(){return i.config},set config(e){},use(e,...t){return a.has(e)||(e&&h(e.install)?(a.add(e),e.install(l,...t)):h(e)&&(a.add(e),e(l,...t))),l},mixin(e){return i.mixins.includes(e)||i.mixins.push(e),l},component(e,t){return t?(i.components[e]=t,l):i.components[e]},directive(e,t){return t?(i.directives[e]=t,l):i.directives[e]},mount(a,o,s){if(!c){let u=l._ceVNode||q(n,r);return u.appContext=i,s===!0?s=`svg`:s===!1&&(s=void 0),o&&t?t(u,a):e(u,a,s),c=!0,l._container=a,a.__vue_app__=l,va(u.component)}},onUnmount(e){o.push(e)},unmount(){c&&(on(o,l._instance,16),e(null,l._container),delete l._container.__vue_app__)},provide(e,t){return i.provides[e]=t,l},runWithContext(e){let t=Ur;Ur=l;try{return e()}finally{Ur=t}}};return l}}var Ur=null,Wr=(e,t)=>t===`modelValue`||t===`model-value`?e.modelModifiers:e[`${t}Modifiers`]||e[`${T(t)}Modifiers`]||e[`${E(t)}Modifiers`];function Gr(e,n,...r){if(e.isUnmounted)return;let i=e.vnode.props||t,a=r,o=n.startsWith(`update:`),s=o&&Wr(i,n.slice(7));s&&(s.trim&&(a=r.map(e=>g(e)?e.trim():e)),s.number&&(a=a.map(se)));let c,l=i[c=ae(n)]||i[c=ae(T(n))];!l&&o&&(l=i[c=ae(E(n))]),l&&on(l,e,6,a);let u=i[c+`Once`];if(u){if(!e.emitted)e.emitted={};else if(e.emitted[c])return;e.emitted[c]=!0,on(u,e,6,a)}}var Kr=new WeakMap;function qr(e,t,n=!1){let r=n?Kr:t.emitsCache,i=r.get(e);if(i!==void 0)return i;let a=e.emits,o={},c=!1;if(!h(e)){let r=e=>{let n=qr(e,t,!0);n&&(c=!0,s(o,n))};!n&&t.mixins.length&&t.mixins.forEach(r),e.extends&&r(e.extends),e.mixins&&e.mixins.forEach(r)}return!a&&!c?(v(e)&&r.set(e,null),null):(d(a)?a.forEach(e=>o[e]=null):s(o,a),v(e)&&r.set(e,o),o)}function Jr(e,t){return!e||!a(t)?!1:(t=t.slice(2),t=t===`Once`?t:t.replace(/Once$/,``),u(e,t[0].toLowerCase()+t.slice(1))||u(e,E(t))||u(e,t))}function Yr(e){let{type:t,vnode:n,proxy:r,withProxy:i,propsOptions:[a],slots:s,attrs:c,emit:l,render:u,renderCache:d,props:f,data:p,setupState:m,ctx:h,inheritAttrs:g}=e,_=Tn(e),v,y;try{if(n.shapeFlag&4){let e=i||r,t=e;v=Zi(u.call(t,e,d,f,m,p,h)),y=c}else{let e=t;v=Zi(e.length>1?e(f,{attrs:c,slots:s,emit:l}):e(f,null)),y=t.props?c:Xr(c)}}catch(t){Fi.length=0,sn(t,e,1),v=q(Ni)}let b=v;if(y&&g!==!1){let e=Object.keys(y),{shapeFlag:t}=b;e.length&&t&7&&(a&&e.some(o)&&(y=Zr(y,a)),b=qi(b,y,!1,!0))}return n.dirs&&(b=qi(b,null,!1,!0),b.dirs=b.dirs?b.dirs.concat(n.dirs):n.dirs),n.transition&&Hn(Rn(b.type)&&Vn(b)||b,n.transition),v=b,Tn(_),v}var Xr=e=>{let t;for(let n in e)(n===`class`||n===`style`||a(n))&&((t||={})[n]=e[n]);return t},Zr=(e,t)=>{let n={};for(let r in e)(!o(r)||!(r.slice(9)in t))&&(n[r]=e[r]);return n};function Qr(e,t,n){let{props:r,children:i,component:a}=e,{props:o,children:s,patchFlag:c}=t,l=a.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&c>=0){if(c&1024)return!0;if(c&16)return r?$r(r,o,l):!!o;if(c&8){let e=t.dynamicProps;for(let t=0;t<e.length;t++){let n=e[t];if(ei(o,r,n)&&!Jr(l,n))return!0}}}else return(i||s)&&(!s||!s.$stable)?!0:r===o?!1:r?!o||$r(r,o,l):!!o;return!1}function $r(e,t,n){let r=Object.keys(t);if(r.length!==Object.keys(e).length)return!0;for(let i=0;i<r.length;i++){let a=r[i];if(ei(t,e,a)&&!Jr(n,a))return!0}return!1}function ei(e,t,n){let r=e[n],i=t[n];return n===`style`&&v(r)&&v(i)?!be(r,i):r!==i}function ti({vnode:e,parent:t,suspense:n},r){for(;t;){let n=t.subTree;if(n.suspense&&n.suspense.activeBranch===e&&(n.suspense.vnode.el=n.el=r,e=n),n===e)(e=t.vnode).el=r,t=t.parent;else break}n&&n.activeBranch===e&&(n.vnode.el=r)}var ni={},ri=()=>Object.create(ni),ii=e=>Object.getPrototypeOf(e)===ni;function ai(e,t,n,r=!1){let i={},a=ri();e.propsDefaults=Object.create(null),si(e,t,i,a);for(let t in e.propsOptions[0])t in i||(i[t]=void 0);e.props=n?r?i:Ft(i):e.type.props?i:a,e.attrs=a}function oi(e,t,n,r){let{props:i,attrs:a,vnode:{patchFlag:o}}=e,s=F(i),[c]=e.propsOptions,l=!1;if((r||o>0)&&!(o&16)){if(o&8){let n=e.vnode.dynamicProps;for(let r=0;r<n.length;r++){let o=n[r];if(Jr(e.emitsOptions,o))continue;let d=t[o];if(c){if(u(a,o))d!==a[o]&&(a[o]=d,l=!0);else{let t=T(o);i[t]=ci(c,s,t,d,e,!1)}}else d!==a[o]&&(a[o]=d,l=!0)}}}else{si(e,t,i,a)&&(l=!0);let r;for(let a in s)(!t||!u(t,a)&&((r=E(a))===a||!u(t,r)))&&(c?n&&(n[a]!==void 0||n[r]!==void 0)&&(i[a]=ci(c,s,a,void 0,e,!0)):delete i[a]);if(a!==s)for(let e in a)(!t||!u(t,e))&&(delete a[e],l=!0)}l&&et(e.attrs,`set`,``)}function si(e,n,r,i){let[a,o]=e.propsOptions,s=!1,c;if(n)for(let t in n){if(ee(t))continue;let l=n[t],d;a&&u(a,d=T(t))?!o||!o.includes(d)?r[d]=l:(c||={})[d]=l:Jr(e.emitsOptions,t)||(!(t in i)||l!==i[t])&&(i[t]=l,s=!0)}if(o){let n=F(r),i=c||t;for(let t=0;t<o.length;t++){let s=o[t];r[s]=ci(a,n,s,i[s],e,!u(i,s))}}return s}function ci(e,t,n,r,i,a){let o=e[n];if(o!=null){let e=u(o,`default`);if(e&&r===void 0){let e=o.default;if(o.type!==Function&&!o.skipFactory&&h(e)){let{propsDefaults:a}=i;if(n in a)r=a[n];else{let o=ca(i);r=a[n]=e.call(null,t),o()}}else r=e;i.ce&&i.ce._setProp(n,r)}o[0]&&(a&&!e?r=!1:o[1]&&(r===``||r===E(n))&&(r=!0))}return r}var li=new WeakMap;function ui(e,r,i=!1){let a=i?li:r.propsCache,o=a.get(e);if(o)return o;let c=e.props,l={},f=[],p=!1;if(!h(e)){let t=e=>{p=!0;let[t,n]=ui(e,r,!0);s(l,t),n&&f.push(...n)};!i&&r.mixins.length&&r.mixins.forEach(t),e.extends&&t(e.extends),e.mixins&&e.mixins.forEach(t)}if(!c&&!p)return v(e)&&a.set(e,n),n;if(d(c))for(let e=0;e<c.length;e++){let n=T(c[e]);di(n)&&(l[n]=t)}else if(c)for(let e in c){let t=T(e);if(di(t)){let n=c[e],r=l[t]=d(n)||h(n)?{type:n}:s({},n),i=r.type,a=!1,o=!0;if(d(i))for(let e=0;e<i.length;++e){let t=i[e],n=h(t)&&t.name;if(n===`Boolean`){a=!0;break}n===`String`&&(o=!1)}else a=h(i)&&i.name===`Boolean`;r[0]=a,r[1]=o,(a||u(r,`default`))&&f.push(t)}}let m=[l,f];return v(e)&&a.set(e,m),m}function di(e){return e[0]!==`$`&&!ee(e)}var fi=e=>e===`_`||e===`_ctx`||e===`$stable`,pi=e=>d(e)?e.map(Zi):[Zi(e)],mi=(e,t,n)=>{if(t._n)return t;let r=En((...e)=>pi(t(...e)),n);return r._c=!1,r},hi=(e,t,n)=>{let r=e._ctx;for(let n in e){if(fi(n))continue;let i=e[n];if(h(i))t[n]=mi(n,i,r);else if(i!=null){let e=pi(i);t[n]=()=>e}}},gi=(e,t)=>{let n=pi(t);e.slots.default=()=>n},_i=(e,t,n)=>{for(let r in t)(n||!fi(r))&&(e[r]=t[r])},vi=(e,t,n)=>{let r=e.slots=ri();if(e.vnode.shapeFlag&32){let e=t._;e?(_i(r,t,n),n&&O(r,`_`,e,!0)):hi(t,r)}else t&&gi(e,t)},yi=(e,n,r)=>{let{vnode:i,slots:a}=e,o=!0,s=t;if(i.shapeFlag&32){let e=n._;e?r&&e===1?o=!1:_i(a,n,r):(o=!n.$stable,hi(n,a)),s=n}else n&&(gi(e,n),s={default:1});if(o)for(let e in a)!fi(e)&&s[e]==null&&delete a[e]},V=ji;function bi(e){return xi(e)}function xi(e,i){let a=le();a.__VUE__=!0;let{insert:o,remove:s,patchProp:c,createElement:l,createText:u,createComment:d,setText:f,setElementText:p,parentNode:m,nextSibling:h,setScopeId:g=r,insertStaticContent:_}=e,v=(e,t,n,r=null,i=null,a=null,o=void 0,s=null,c=!!t.dynamicChildren)=>{if(e===t)return;e&&!Hi(e,t)&&(r=ye(e),k(e,i,a,!0),e=null),t.patchFlag===-2&&(c=!1,t.dynamicChildren=null);let{type:l,ref:u,shapeFlag:d}=t;switch(l){case Mi:y(e,t,n,r);break;case Ni:b(e,t,n,r);break;case Pi:e??x(t,n,r,o);break;case H:ae(e,t,n,r,i,a,o,s,c);break;default:d&1?w(e,t,n,r,i,a,o,s,c):d&6?D(e,t,n,r,i,a,o,s,c):(d&64||d&128)&&l.process(e,t,n,r,i,a,o,s,c,A)}u!=null&&i?qn(u,e&&e.ref,a,t||e,!t):u==null&&e&&e.ref!=null&&qn(e.ref,null,a,e,!0)},y=(e,t,n,r)=>{if(e==null)o(t.el=u(t.children),n,r);else{let n=t.el=e.el;t.children!==e.children&&f(n,t.children)}},b=(e,t,n,r)=>{e==null?o(t.el=d(t.children||``),n,r):t.el=e.el},x=(e,t,n,r)=>{[e.el,e.anchor]=_(e.children,t,n,r,e.el,e.anchor)},S=({el:e,anchor:t},n,r)=>{let i;for(;e&&e!==t;)i=h(e),o(e,n,r),e=i;o(t,n,r)},C=({el:e,anchor:t})=>{let n;for(;e&&e!==t;)n=h(e),s(e),e=n;s(t)},w=(e,t,n,r,i,a,o,s,c)=>{if(t.type===`svg`?o=`svg`:t.type===`math`&&(o=`mathml`),e==null)te(t,n,r,i,a,o,s,c);else{let n=e.el&&e.el._isVueCE?e.el:null;try{n&&n._beginPatch(),re(e,t,i,a,o,s,c)}finally{n&&n._endPatch()}}},te=(e,t,n,r,i,a,s,u)=>{let d,f,{props:m,shapeFlag:h,transition:g,dirs:_}=e;if(d=e.el=l(e.type,a,m&&m.is,m),h&8?p(d,e.children):h&16&&T(e.children,d,null,r,i,Si(e,a),s,u),_&&On(e,null,r,`created`),ne(d,e,e.scopeId,s,r),m){for(let e in m)e!==`value`&&!ee(e)&&c(d,e,null,m[e],a,r);`value`in m&&c(d,`value`,null,m.value,a),(f=m.onVnodeBeforeMount)&&ta(f,r,e)}_&&On(e,null,r,`beforeMount`);let v=wi(i,g);v&&g.beforeEnter(d),o(d,t,n),((f=m&&m.onVnodeMounted)||v||_)&&V(()=>{try{f&&ta(f,r,e),v&&g.enter(d),_&&On(e,null,r,`mounted`)}finally{}},i)},ne=(e,t,n,r,i)=>{if(n&&g(e,n),r)for(let t=0;t<r.length;t++)g(e,r[t]);if(i){let n=i.subTree;if(t===n||Ai(n.type)&&(n.ssContent===t||n.ssFallback===t)){let t=i.vnode;ne(e,t,t.scopeId,t.slotScopeIds,i.parent)}}},T=(e,t,n,r,i,a,o,s,c=0)=>{for(let l=c;l<e.length;l++){let c=e[l]=s?Qi(e[l]):Zi(e[l]);v(null,c,t,n,r,i,a,o,s)}},re=(e,n,r,i,a,o,s)=>{let l=n.el=e.el,{patchFlag:u,dynamicChildren:d,dirs:f}=n;u|=e.patchFlag&16;let m=e.props||t,h=n.props||t,g;if(r&&Ci(r,!1),(g=h.onVnodeBeforeUpdate)&&ta(g,r,n,e),f&&On(n,e,r,`beforeUpdate`),r&&Ci(r,!0),d&&(!e.dynamicChildren||e.dynamicChildren.length!==d.length)&&(u=0,s=!1,d=null),(m.innerHTML&&h.innerHTML==null||m.textContent&&h.textContent==null)&&p(l,``),d?E(e.dynamicChildren,d,l,r,i,Si(n,a),o):s||de(e,n,l,null,r,i,Si(n,a),o,!1),u>0){if(u&16)ie(l,m,h,r,a);else if(u&2&&m.class!==h.class&&c(l,`class`,null,h.class,a),u&4&&c(l,`style`,m.style,h.style,a),u&8){let e=n.dynamicProps;for(let t=0;t<e.length;t++){let n=e[t],i=m[n],o=h[n];(o!==i||n===`value`)&&c(l,n,i,o,a,r)}}u&1&&e.children!==n.children&&p(l,n.children)}else!s&&d==null&&ie(l,m,h,r,a);((g=h.onVnodeUpdated)||f)&&V(()=>{g&&ta(g,r,n,e),f&&On(n,e,r,`updated`)},i)},E=(e,t,n,r,i,a,o)=>{for(let s=0;s<t.length;s++){let c=e[s],l=t[s],u=c.el&&(c.type===H||!Hi(c,l)||c.shapeFlag&198)?m(c.el):n;v(c,l,u,null,r,i,a,o,!0)}},ie=(e,n,r,i,a)=>{if(n!==r){if(n!==t)for(let t in n)!ee(t)&&!(t in r)&&c(e,t,n[t],null,a,i);for(let t in r){if(ee(t))continue;let o=r[t],s=n[t];o!==s&&t!==`value`&&c(e,t,s,o,a,i)}`value`in r&&c(e,`value`,n.value,r.value,a)}},ae=(e,t,n,r,i,a,s,c,l)=>{let d=t.el=e?e.el:u(``),f=t.anchor=e?e.anchor:u(``),{patchFlag:p,dynamicChildren:m,slotScopeIds:h}=t;h&&(c=c?c.concat(h):h),e==null?(o(d,n,r),o(f,n,r),T(t.children||[],n,f,i,a,s,c,l)):p>0&&p&64&&m&&e.dynamicChildren&&e.dynamicChildren.length===m.length?(E(e.dynamicChildren,m,n,i,a,s,c),(t.key!=null||i&&t===i.subTree)&&Ti(e,t,!0)):de(e,t,n,f,i,a,s,c,l)},D=(e,t,n,r,i,a,o,s,c)=>{t.slotScopeIds=s,e==null?t.shapeFlag&512?i.ctx.activate(t,n,r,o,c):O(t,n,r,i,a,o,c):se(e,t,c)},O=(e,t,n,r,i,a,o)=>{let s=e.component=ia(e,r,i);if(Xn(e)&&(s.ctx.renderer=A),fa(s,!1,o),s.asyncDep){if(i&&i.registerDep(s,ce,o),!e.el){let r=s.subTree=q(Ni);b(null,r,t,n),e.placeholder=r.el}}else ce(s,e,t,n,i,a,o)},se=(e,t,n)=>{let r=t.component=e.component;if(Qr(e,t,n)){if(r.asyncDep&&!r.asyncResolved){ue(r,t,n);return}r.next=t,r.update()}else t.el=e.el,r.vnode=t},ce=(e,t,n,r,i,a,o)=>{let s=()=>{if(e.isMounted){let{next:t,bu:n,u:r,parent:s,vnode:c}=e;{let n=Di(e);if(n){t&&(t.el=c.el,ue(e,t,o)),n.asyncDep.then(()=>{V(()=>{e.isUnmounted||l()},i)});return}}let u=t,d;Ci(e,!1),t?(t.el=c.el,ue(e,t,o)):t=c,n&&oe(n),(d=t.props&&t.props.onVnodeBeforeUpdate)&&ta(d,s,t,c),Ci(e,!0);let f=Yr(e),p=e.subTree;e.subTree=f,v(p,f,m(p.el),ye(p),e,i,a),t.el=f.el,u===null&&ti(e,f.el),r&&V(r,i),(d=t.props&&t.props.onVnodeUpdated)&&V(()=>ta(d,s,t,c),i)}else{let o,{el:s,props:c}=t,{bm:l,m:u,parent:d,root:f,type:p}=e,m=Yn(t);if(Ci(e,!1),l&&oe(l),!m&&(o=c&&c.onVnodeBeforeMount)&&ta(o,d,t),Ci(e,!0),s&&Ce){let t=()=>{e.subTree=Yr(e),Ce(s,e.subTree,e,i,null)};m&&p.__asyncHydrate?p.__asyncHydrate(s,e,t):t()}else{f.ce&&f.ce._hasShadowRoot()&&f.ce._injectChildStyle(p,e.parent?e.parent.type:void 0);let o=e.subTree=Yr(e);v(null,o,n,r,e,i,a),t.el=o.el}if(u&&V(u,i),!m&&(o=c&&c.onVnodeMounted)){let e=t;V(()=>ta(o,d,e),i)}(t.shapeFlag&256||d&&Yn(d.vnode)&&d.vnode.shapeFlag&256)&&e.a&&V(e.a,i),e.isMounted=!0,t=n=r=null}};e.scope.on();let c=e.effect=new Oe(s);e.scope.off();let l=e.update=c.run.bind(c),u=e.job=c.runIfDirty.bind(c);u.i=e,u.id=e.uid,c.scheduler=()=>_n(u),Ci(e,!0),l()},ue=(e,t,n)=>{t.component=e;let r=e.vnode.props;e.vnode=t,e.next=null,oi(e,t.props,r,n),yi(e,t.children,n),Ue(),bn(e),We()},de=(e,t,n,r,i,a,o,s,c=!1)=>{let l=e&&e.children,u=e?e.shapeFlag:0,d=t.children,{patchFlag:f,shapeFlag:m}=t;if(f>0){if(f&128){pe(l,d,n,r,i,a,o,s,c);return}if(f&256){fe(l,d,n,r,i,a,o,s,c);return}}m&8?(u&16&&ve(l,i,a),d!==l&&p(n,d)):u&16?m&16?pe(l,d,n,r,i,a,o,s,c):ve(l,i,a,!0):(u&8&&p(n,``),m&16&&T(d,n,r,i,a,o,s,c))},fe=(e,t,r,i,a,o,s,c,l)=>{e||=n,t||=n;let u=e.length,d=t.length,f=Math.min(u,d),p;for(p=0;p<f;p++){let n=t[p]=l?Qi(t[p]):Zi(t[p]);v(e[p],n,r,null,a,o,s,c,l)}u>d?ve(e,a,o,!0,!1,f):T(t,r,i,a,o,s,c,l,f)},pe=(e,t,r,i,a,o,s,c,l)=>{let u=0,d=t.length,f=e.length-1,p=d-1;for(;u<=f&&u<=p;){let n=e[u],i=t[u]=l?Qi(t[u]):Zi(t[u]);if(Hi(n,i))v(n,i,r,null,a,o,s,c,l);else break;u++}for(;u<=f&&u<=p;){let n=e[f],i=t[p]=l?Qi(t[p]):Zi(t[p]);if(Hi(n,i))v(n,i,r,null,a,o,s,c,l);else break;f--,p--}if(u>f){if(u<=p){let e=p+1,n=e<d?t[e].el:i;for(;u<=p;)v(null,t[u]=l?Qi(t[u]):Zi(t[u]),r,n,a,o,s,c,l),u++}}else if(u>p)for(;u<=f;)k(e[u],a,o,!0),u++;else{let m=u,h=u,g=new Map;for(u=h;u<=p;u++){let e=t[u]=l?Qi(t[u]):Zi(t[u]);e.key!=null&&g.set(e.key,u)}let _,y=0,b=p-h+1,x=!1,S=0,C=Array(b);for(u=0;u<b;u++)C[u]=0;for(u=m;u<=f;u++){let n=e[u];if(y>=b){k(n,a,o,!0);continue}let i;if(n.key!=null)i=g.get(n.key);else for(_=h;_<=p;_++)if(C[_-h]===0&&Hi(n,t[_])){i=_;break}i===void 0?k(n,a,o,!0):(C[i-h]=u+1,i>=S?S=i:x=!0,v(n,t[i],r,null,a,o,s,c,l),y++)}let w=x?Ei(C):n;for(_=w.length-1,u=b-1;u>=0;u--){let e=h+u,n=t[e],f=t[e+1],p=e+1<d?f.el||ki(f):i;C[u]===0?v(null,n,r,p,a,o,s,c,l):x&&(_<0||u!==w[_]?me(n,r,p,2):_--)}}},me=(e,t,n,r,i=null)=>{let{el:a,type:c,transition:l,children:u,shapeFlag:d}=e;if(d&6){me(e.component.subTree,t,n,r);return}if(d&128){e.suspense.move(t,n,r);return}if(d&64){c.move(e,t,n,A);return}if(c===H){o(a,t,n);for(let e=0;e<u.length;e++)me(u[e],t,n,r);o(e.anchor,t,n);return}if(c===Pi){S(e,t,n);return}if(r!==2&&d&1&&l){if(r===0)l.persisted&&!a[zn]?o(a,t,n):(l.beforeEnter(a),o(a,t,n),V(()=>l.enter(a),i));else{let{leave:r,delayLeave:i,afterLeave:c}=l,u=()=>{e.ctx.isUnmounted?s(a):o(a,t,n)},d=()=>{let e=a._isLeaving||!!a[zn];a._isLeaving&&a[zn](!0),l.persisted&&!e?u():r(a,()=>{u(),c&&c()})};i?i(a,u,d):d()}}else o(a,t,n)},k=(e,t,n,r=!1,i=!1)=>{let{type:a,props:o,ref:s,children:c,dynamicChildren:l,shapeFlag:u,patchFlag:d,dirs:f,cacheIndex:p,memo:m}=e;if(d===-2&&(i=!1),s!=null&&(Ue(),qn(s,null,n,e,!0),We()),p!=null&&(t.renderCache[p]=void 0),u&256){t.ctx.deactivate(e);return}let h=u&1&&f,g=!Yn(e),_;if(g&&(_=o&&o.onVnodeBeforeUnmount)&&ta(_,t,e),u&6)_e(e.component,n,r);else{if(u&128){e.suspense.unmount(n,r);return}h&&On(e,null,t,`beforeUnmount`),u&64?e.type.remove(e,t,n,A,r):l&&!l.hasOnce&&(a!==H||d>0&&d&64)?ve(l,t,n,!1,!0):(a===H&&d&384||!i&&u&16)&&ve(c,t,n),r&&he(e)}let v=m!=null&&p==null;(g&&(_=o&&o.onVnodeUnmounted)||h||v)&&V(()=>{_&&ta(_,t,e),h&&On(e,null,t,`unmounted`),v&&(e.el=null)},n)},he=e=>{let{type:t,el:n,anchor:r,transition:i}=e;if(t===H){ge(n,r);return}if(t===Pi){C(e);return}let a=()=>{s(n),i&&!i.persisted&&i.afterLeave&&i.afterLeave()};if(e.shapeFlag&1&&i&&!i.persisted){let{leave:t,delayLeave:r}=i,o=()=>t(n,a);r?r(e.el,a,o):o()}else a()},ge=(e,t)=>{let n;for(;e!==t;)n=h(e),s(e),e=n;s(t)},_e=(e,t,n)=>{let{bum:r,scope:i,job:a,subTree:o,um:s,m:c,a:l}=e;Oi(c),Oi(l),r&&oe(r),i.stop(),a&&(a.flags|=8,k(o,e,t,n)),s&&V(s,t),V(()=>{e.isUnmounted=!0},t)},ve=(e,t,n,r=!1,i=!1,a=0)=>{for(let o=a;o<e.length;o++)k(e[o],t,n,r,i)},ye=e=>{if(e.shapeFlag&6)return ye(e.component.subTree);if(e.shapeFlag&128)return e.suspense.next();let t=h(e.anchor||e.el),n=t&&t[Ln];return n?h(n):t},be=!1,xe=(e,t,n)=>{let r;e==null?t._vnode&&(k(t._vnode,null,null,!0),r=t._vnode.component):v(t._vnode||null,e,t,null,null,null,n),t._vnode=e,be||=(be=!0,bn(r),xn(),!1)},A={p:v,um:k,m:me,r:he,mt:O,mc:T,pc:de,pbc:E,n:ye,o:e},Se,Ce;return i&&([Se,Ce]=i(A)),{render:xe,hydrate:Se,createApp:Hr(xe,Se)}}function Si({type:e,props:t},n){return n===`svg`&&e===`foreignObject`||n===`mathml`&&e===`annotation-xml`&&t&&t.encoding&&t.encoding.includes(`html`)?void 0:n}function Ci({effect:e,job:t},n){n?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function wi(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function Ti(e,t,n=!1){let r=e.children,i=t.children;if(d(r)&&d(i))for(let e=0;e<r.length;e++){let t=r[e],a=i[e];a.shapeFlag&1&&!a.dynamicChildren&&((a.patchFlag<=0||a.patchFlag===32)&&(a=i[e]=Qi(i[e]),a.el=t.el),!n&&a.patchFlag!==-2&&Ti(t,a)),a.type===Mi&&(a.patchFlag===-1&&(a=i[e]=Qi(a)),a.el=t.el),a.type===Ni&&!a.el&&(a.el=t.el)}}function Ei(e){let t=e.slice(),n=[0],r,i,a,o,s,c=e.length;for(r=0;r<c;r++){let c=e[r];if(c!==0){if(i=n[n.length-1],e[i]<c){t[r]=i,n.push(r);continue}for(a=0,o=n.length-1;a<o;)s=a+o>>1,e[n[s]]<c?a=s+1:o=s;c<e[n[a]]&&(a>0&&(t[r]=n[a-1]),n[a]=r)}}for(a=n.length,o=n[a-1];a-->0;)n[a]=o,o=t[o];return n}function Di(e){let t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:Di(t)}function Oi(e){if(e)for(let t=0;t<e.length;t++)e[t].flags|=8}function ki(e){if(e.placeholder)return e.placeholder;let t=e.component;return t?ki(t.subTree):null}var Ai=e=>e.__isSuspense;function ji(e,t){t&&t.pendingBranch?d(e)?t.effects.push(...e):t.effects.push(e):yn(e)}var H=Symbol.for(`v-fgt`),Mi=Symbol.for(`v-txt`),Ni=Symbol.for(`v-cmt`),Pi=Symbol.for(`v-stc`),Fi=[],U=null;function W(e=!1){Fi.push(U=e?null:[])}function Ii(){Fi.pop(),U=Fi[Fi.length-1]||null}var Li=1;function Ri(e,t=!1){Li+=e,e<0&&U&&t&&(U.hasOnce=!0)}function zi(e){return e.dynamicChildren=Li>0?U||n:null,Ii(),Li>0&&U&&U.push(e),e}function G(e,t,n,r,i,a){return zi(K(e,t,n,r,i,a,!0))}function Bi(e,t,n,r,i){return zi(q(e,t,n,r,i,!0))}function Vi(e){return e?e.__v_isVNode===!0:!1}function Hi(e,t){return e.type===t.type&&e.key===t.key}var Ui=({key:e})=>e??null,Wi=({ref:e,ref_key:t,ref_for:n})=>(typeof e==`number`&&(e=``+e),e==null?null:g(e)||I(e)||h(e)?{i:z,r:e,k:t,f:!!n}:e);function K(e,t=null,n=null,r=0,i=null,a=e===H?0:1,o=!1,s=!1){let c={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&Ui(t),ref:t&&Wi(t),scopeId:wn,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag:a,patchFlag:r,dynamicProps:i,dynamicChildren:null,appContext:null,ctx:z};return s?($i(c,n),a&128&&e.normalize(c)):n&&(c.shapeFlag|=g(n)?8:16),Li>0&&!o&&U&&(c.patchFlag>0||a&6)&&c.patchFlag!==32&&U.push(c),c}var q=Gi;function Gi(e,t=null,n=null,r=0,i=null,a=!1){if((!e||e===mr)&&(e=Ni),Vi(e)){let r=qi(e,t,!0);return n&&$i(r,n),Li>0&&!a&&U&&(r.shapeFlag&6?U[U.indexOf(e)]=r:U.push(r)),r.patchFlag=-2,r}if(ba(e)&&(e=e.__vccOpts),t){t=Ki(t);let{class:e,style:n}=t;e&&!g(e)&&(t.class=k(e)),v(n)&&(Bt(n)&&!d(n)&&(n=s({},n)),t.style=ue(n))}let o=g(e)?1:Ai(e)?128:Rn(e)?64:v(e)?4:h(e)?2:0;return K(e,t,n,r,i,o,a,!0)}function Ki(e){return e?Bt(e)||ii(e)?s({},e):e:null}function qi(e,t,n=!1,r=!1){let{props:i,ref:a,patchFlag:o,children:s,transition:c}=e,l=t?ea(i||{},t):i,u={__v_isVNode:!0,__v_skip:!0,type:e.type,props:l,key:l&&Ui(l),ref:t&&t.ref?n&&a?d(a)?a.concat(Wi(t)):[a,Wi(t)]:Wi(t):a,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:s,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==H?o===-1?16:o|16:o,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:c,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&qi(e.ssContent),ssFallback:e.ssFallback&&qi(e.ssFallback),placeholder:e.placeholder,el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return c&&r&&Hn(u,c.clone(u)),u}function Ji(e=` `,t=0){return q(Mi,null,e,t)}function Yi(e,t){let n=q(Pi,null,e);return n.staticCount=t,n}function Xi(e=``,t=!1){return t?(W(),Bi(Ni,null,e)):q(Ni,null,e)}function Zi(e){return e==null||typeof e==`boolean`?q(Ni):d(e)?q(H,null,e.slice()):Vi(e)?Qi(e):q(Mi,null,String(e))}function Qi(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:qi(e)}function $i(e,t){let n=0,{shapeFlag:r}=e;if(t==null)t=null;else if(d(t))n=16;else if(typeof t==`object`){if(r&65){let n=t.default;n&&(n._c&&(n._d=!1),$i(e,n()),n._c&&(n._d=!0));return}{n=32;let r=t._;!r&&!ii(t)?t._ctx=z:r===3&&z&&(z.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}}else if(h(t)){if(r&65){$i(e,{default:t});return}t={default:t,_ctx:z},n=32}else t=String(t),r&64?(n=16,t=[Ji(t)]):n=8;e.children=t,e.shapeFlag|=n}function ea(...e){let t={};for(let n=0;n<e.length;n++){let r=e[n];for(let e in r)if(e===`class`)t.class!==r.class&&(t.class=k([t.class,r.class]));else if(e===`style`)t.style=ue([t.style,r.style]);else if(a(e)){let n=t[e],i=r[e];i&&n!==i&&!(d(n)&&n.includes(i))?t[e]=n?[].concat(n,i):i:i==null&&n==null&&!o(e)&&(t[e]=i)}else e!==``&&(t[e]=r[e])}return t}function ta(e,t,n,r=null){on(e,t,7,[n,r])}var na=Br(),ra=0;function ia(e,n,r){let i=e.type,a=(n?n.appContext:e.appContext)||na,o={uid:ra++,vnode:e,type:i,parent:n,appContext:a,root:null,next:null,subTree:null,effect:null,update:null,job:null,scope:new we(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:n?n.provides:Object.create(a.provides),ids:n?n.ids:[``,0,0],accessCache:null,renderCache:[],components:null,directives:null,propsOptions:ui(i,a),emitsOptions:qr(i,a),emit:null,emitted:null,propsDefaults:t,inheritAttrs:i.inheritAttrs,ctx:t,data:t,props:t,attrs:t,slots:t,refs:t,setupState:t,setupContext:null,suspense:r,suspenseId:r?r.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 o.ctx={_:o},o.root=n?n.root:o,o.emit=Gr.bind(null,o),e.ce&&e.ce(o),o}var J=null,aa=()=>J||z,oa,sa;{let e=le(),t=(t,n)=>{let r;return(r=e[t])||(r=e[t]=[]),r.push(n),e=>{r.length>1?r.forEach(t=>t(e)):r[0](e)}};oa=t(`__VUE_INSTANCE_SETTERS__`,e=>J=e),sa=t(`__VUE_SSR_SETTERS__`,e=>da=e)}var ca=e=>{let t=J;return oa(e),e.scope.on(),()=>{e.scope.off(),oa(t)}},la=()=>{J&&J.scope.off(),oa(null)};function ua(e){return e.vnode.shapeFlag&4}var da=!1;function fa(e,t=!1,n=!1){t&&sa(t);let{props:r,children:i}=e.vnode,a=ua(e);ai(e,r,a,t),vi(e,i,n||t);let o=a?pa(e,t):void 0;return t&&sa(!1),o}function pa(e,t){let n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,wr);let{setup:r}=n;if(r){Ue();let n=e.setupContext=r.length>1?_a(e):null,i=ca(e),a=an(r,e,0,[e.props,n]),o=y(a);if(We(),i(),(o||e.sp)&&!Yn(e)&&Wn(e),o){if(a.then(la,la),t)return a.then(n=>{sa(!0);try{ma(e,n,t)}finally{sa(!1)}}).catch(t=>{sn(t,e,0)});e.asyncDep=a}else ma(e,a,t)}else ha(e,t)}function ma(e,t,n){h(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:v(t)&&(e.setupState=Yt(t)),ha(e,n)}function ha(e,t,n){let i=e.type;e.render||=i.render||r;{let t=ca(e);Ue();try{Dr(e)}finally{We(),t()}}}var ga={get(e,t){return N(e,`get`,``),e[t]}};function _a(e){return{attrs:new Proxy(e.attrs,ga),slots:e.slots,emit:e.emit,expose:t=>{e.exposed=t||{}}}}function va(e){return e.exposed?e.exposeProxy||=new Proxy(Yt(Vt(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in Sr)return Sr[n](e)},has(e,t){return t in e||t in Sr}}):e.proxy}function ya(e,t=!0){return h(e)?e.displayName||e.name:e.name||t&&e.__name}function ba(e){return h(e)&&`__vccOpts`in e}var Y=(e,t)=>Zt(e,t,da),xa=`3.5.42`,Sa=void 0,Ca=typeof window<`u`&&window.trustedTypes;if(Ca)try{Sa=Ca.createPolicy(`vue`,{createHTML:e=>e})}catch{}var wa=Sa?e=>Sa.createHTML(e):e=>e,Ta=`http://www.w3.org/2000/svg`,Ea=`http://www.w3.org/1998/Math/MathML`,Da=typeof document<`u`?document:null,Oa=Da&&Da.createElement(`template`),ka={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{let t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,r)=>{let i=t===`svg`?Da.createElementNS(Ta,e):t===`mathml`?Da.createElementNS(Ea,e):n?Da.createElement(e,{is:n}):Da.createElement(e);return e===`select`&&r&&r.multiple!=null&&i.setAttribute(`multiple`,r.multiple),i},createText:e=>Da.createTextNode(e),createComment:e=>Da.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Da.querySelector(e),setScopeId(e,t){e.setAttribute(t,``)},insertStaticContent(e,t,n,r,i,a){let o=n?n.previousSibling:t.lastChild;if(i&&(i===a||i.nextSibling))for(;t.insertBefore(i.cloneNode(!0),n),!(i===a||!(i=i.nextSibling)););else{Oa.innerHTML=wa(r===`svg`?`<svg>${e}</svg>`:r===`mathml`?`<math>${e}</math>`:e);let i=Oa.content;if(r===`svg`||r===`mathml`){let e=i.firstChild;for(;e.firstChild;)i.appendChild(e.firstChild);i.removeChild(e)}t.insertBefore(i,n)}return[o?o.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},Aa=Symbol(`_vtc`);function ja(e,t,n){let r=e[Aa];r&&(t=(t?[t,...r]:[...r]).join(` `)),t==null?e.removeAttribute(`class`):n?e.setAttribute(`class`,t):e.className=t}var Ma=Symbol(`_vod`),Na=Symbol(`_vsh`),Pa={name:`show`,beforeMount(e,{value:t},{transition:n}){e[Ma]=e.style.display===`none`?``:e.style.display,n&&t?n.beforeEnter(e):Fa(e,t)},mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)},updated(e,{value:t,oldValue:n},{transition:r}){!t!=!n&&(r?t?(r.beforeEnter(e),Fa(e,!0),r.enter(e)):r.leave(e,()=>{Fa(e,!1)}):Fa(e,t))},beforeUnmount(e,{value:t}){Fa(e,t)}};function Fa(e,t){e.style.display=t?e[Ma]:`none`,e[Na]=!t}var Ia=Symbol(``),La=/(?:^|;)\s*display\s*:/;function Ra(e,t,n){let r=e.style,i=g(n),a=!1;if(n&&!i){if(t){if(g(t))for(let e of t.split(`;`)){let t=e.slice(0,e.indexOf(`:`)).trim();n[t]??Ba(r,t,``)}else for(let e in t)n[e]??Ba(r,e,``)}for(let i in n){i===`display`&&(a=!0);let o=n[i];o==null?Ba(r,i,``):Wa(e,i,!g(t)&&t?t[i]:void 0,o)||Ba(r,i,o)}}else if(i){if(t!==n){let e=r[Ia];e&&(n+=`;`+e),r.cssText=n,a=La.test(n)}}else t&&e.removeAttribute(`style`);Ma in e&&(e[Ma]=a?r.display:``,e[Na]&&(r.display=`none`))}var za=/\s*!important$/;function Ba(e,t,n){if(d(n))n.forEach(n=>Ba(e,t,n));else if(n??=``,t.startsWith(`--`))za.test(n)?e.setProperty(t,n.replace(za,``),`important`):e.setProperty(t,n);else{let r=Ua(e,t);za.test(n)?e.setProperty(E(r),n.replace(za,``),`important`):e[r]=n}}var Va=[`Webkit`,`Moz`,`ms`],Ha={};function Ua(e,t){let n=Ha[t];if(n)return n;let r=T(t);if(r!==`filter`&&r in e)return Ha[t]=r;r=ie(r);for(let n=0;n<Va.length;n++){let i=Va[n]+r;if(i in e)return Ha[t]=i}return t}function Wa(e,t,n,r){return e.tagName===`TEXTAREA`&&(t===`width`||t===`height`)&&g(r)&&n===r}var Ga=`http://www.w3.org/1999/xlink`;function Ka(e,t,n,r,i,a=ge(t)){r&&t.startsWith(`xlink:`)?n==null?e.removeAttributeNS(Ga,t.slice(6,t.length)):e.setAttributeNS(Ga,t,n):n==null||a&&!_e(n)?e.removeAttribute(t):e.setAttribute(t,a?``:_(n)?String(n):n)}function qa(e,t,n,r,i){if(t===`innerHTML`||t===`textContent`){n!=null&&(e[t]=t===`innerHTML`?wa(n):n);return}let a=e.tagName;if(t===`value`&&a!==`PROGRESS`&&!a.includes(`-`)){let r=a===`OPTION`?e.getAttribute(`value`)||``:e.value,i=n==null?e.type===`checkbox`?`on`:``:String(n);(r!==i||!(`_value`in e))&&(e.value=i),n??e.removeAttribute(t),e._value=n;return}let o=!1;if(n===``||n==null){let r=typeof e[t];r===`boolean`?n=_e(n):n==null&&r===`string`?(n=``,o=!0):r===`number`&&(n=0,o=!0)}try{e[t]=n}catch{}o&&e.removeAttribute(i||t)}function Ja(e,t,n,r){e.addEventListener(t,n,r)}function Ya(e,t,n,r){e.removeEventListener(t,n,r)}var Xa=Symbol(`_vei`);function Za(e,t,n,r,i=null){let a=e[Xa]||(e[Xa]={}),o=a[t];if(r&&o)o.value=r;else{let[n,s]=eo(t);r?Ja(e,n,a[t]=io(r,i),s):o&&(Ya(e,n,o,s),a[t]=void 0)}}var Qa=/(Once|Passive|Capture)$/,$a=/^on:?(?:Once|Passive|Capture)$/;function eo(e){let t,n;for(;(n=e.match(Qa))&&!$a.test(e);)t||={},e=e.slice(0,e.length-n[1].length),t[n[1].toLowerCase()]=!0;return[e[2]===`:`?e.slice(3):E(e.slice(2)),t]}var to=0,no=Promise.resolve(),ro=()=>to||=(no.then(()=>to=0),Date.now());function io(e,t){let n=e=>{if(!e._vts)e._vts=Date.now();else if(e._vts<=n.attached)return;let r=n.value;if(d(r)){let n=e.stopImmediatePropagation;e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0};let i=r.slice(),a=[e];for(let n=0;n<i.length&&!e._stopped;n++){let e=i[n];e&&on(e,t,5,a)}}else on(r,t,5,[e])};return n.value=e,n.attached=ro(),n}var ao=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,oo=(e,t,n,r,i,s)=>{let c=i===`svg`;t===`class`?ja(e,r,c):t===`style`?Ra(e,n,r):a(t)?o(t)||Za(e,t,n,r,s):(t[0]===`.`?(t=t.slice(1),!0):t[0]===`^`?(t=t.slice(1),!1):so(e,t,r,c))?(qa(e,t,r),!e.tagName.includes(`-`)&&(t===`value`||t===`checked`||t===`selected`)&&Ka(e,t,r,c,s,t!==`value`)):e._isVueCE&&(co(e,t)||e._def.__asyncLoader&&(/[A-Z]/.test(t)||!g(r)))?qa(e,T(t),r,s,t):(t===`true-value`?e._trueValue=r:t===`false-value`&&(e._falseValue=r),Ka(e,t,r,c))};function so(e,t,n,r){if(r)return!!(t===`innerHTML`||t===`textContent`||t in e&&ao(t)&&h(n));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`){let t=e.tagName;if(t===`IMG`||t===`VIDEO`||t===`CANVAS`||t===`SOURCE`)return!1}return ao(t)&&g(n)?!1:t in e}function co(e,t){let n=e._def.props;if(!n)return!1;let r=T(t);return Array.isArray(n)?n.some(e=>T(e)===r):Object.keys(n).some(e=>T(e)===r)}var lo=s({patchProp:oo},ka),uo;function fo(){return uo||=bi(lo)}var po=((...e)=>{let t=fo().createApp(...e),{mount:n}=t;return t.mount=e=>{let r=ho(e);if(!r)return;let i=t._component;!h(i)&&!i.render&&!i.template&&(i.template=r.innerHTML),r.nodeType===1&&(r.textContent=``);let a=n(r,!1,mo(r));return r instanceof Element&&(r.removeAttribute(`v-cloak`),r.setAttribute(`data-v-app`,``)),a},t});function mo(e){if(e instanceof SVGElement)return`svg`;if(typeof MathMLElement==`function`&&e instanceof MathMLElement)return`mathml`}function ho(e){return g(e)?document.querySelector(e):e}var go=Un({__name:`FeedbackSpinner`,props:{size:{default:`1em`}},setup(e){let t=e,n=Y(()=>typeof t.size==`number`?`${t.size}px`:t.size);return(e,t)=>(W(),G(`span`,{class:`border-2 border-current border-t-transparent rounded-full inline-block animate-spin`,style:ue({width:n.value,height:n.value}),role:`status`,"aria-label":`Loading`},null,4))}}),_o=Un({__name:`ActionButton`,props:{as:{},to:{},href:{},icon:{},variant:{default:`action`},size:{default:`md`},loading:{type:Boolean},disabled:{type:Boolean}},setup(e){let t=e,n=Y(()=>t.as?t.as:t.href!=null||t.to!=null?`a`:`button`),r=Y(()=>n.value===`a`),i=Y(()=>n.value===`button`),a=Y(()=>t.size===`sm`),o=Y(()=>t.variant===`primary`?a.value?`btn-primary text-sm`:`btn-primary`:t.variant===`text`?a.value?`btn-text text-sm`:`btn-text`:a.value?`btn-action-sm`:`btn-action`),s=Y(()=>t.disabled||t.loading);return(t,a)=>(W(),Bi(hr(n.value),{class:k([o.value,{"pointer-events-none op-mute":s.value&&!i.value}]),href:r.value?e.href??e.to:void 0,to:e.as&&e.to!=null?e.to:void 0,disabled:i.value?s.value:void 0,"aria-disabled":s.value||void 0,"aria-busy":e.loading||void 0},{default:En(()=>[e.loading?(W(),Bi(go,{key:0,size:`1em`})):e.icon?(W(),G(`span`,{key:1,class:k(e.icon),"aria-hidden":`true`},null,2)):Xi(``,!0),yr(t.$slots,`default`)]),_:3},8,[`class`,`href`,`to`,`disabled`,`aria-disabled`,`aria-busy`]))}}),vo={key:0,class:`absolute inset-0 z-nav flex flex-col items-center justify-center gap-4 p-8 text-center bg-base color-base font-sans`},yo={class:`flex flex-col gap-1`},bo={class:`text-lg font-medium`},xo={class:`text-sm color-muted max-w-sm`},So={key:0,class:`mt-1 max-w-sm break-words font-mono text-xs color-faint`},Co=Un({__name:`ConnectionOverlay`,props:{status:{},error:{}},setup(e){let t=e,n={connecting:{icon:`i-ph-plugs-connected-duotone`,title:`Connecting…`,body:`Establishing a connection to the devframe server.`},disconnected:{icon:`i-ph-plugs-duotone`,title:`Disconnected`,body:`Lost the connection to the devframe server. Reload once it is back up.`},unauthorized:{icon:`i-ph-lock-key-duotone`,title:`Not authorized`,body:`Reopen the link printed by your dev server, then reload.`},error:{icon:`i-ph-warning-octagon-duotone`,title:`Connection failed`,body:`Could not reach the devframe server.`}},r=Y(()=>n[t.status]);return(t,n)=>e.status!==`connected`&&r.value?(W(),G(`div`,vo,[K(`div`,{class:k([r.value.icon,`text-4xl color-active`])},null,2),K(`div`,yo,[K(`p`,bo,A(r.value.title),1),K(`p`,xo,A(r.value.body),1),e.error&&e.status===`error`?(W(),G(`code`,So,A(e.error),1)):Xi(``,!0)]),e.status===`connecting`?Xi(``,!0):(W(),Bi(_o,{key:0,variant:`primary`,size:`sm`,onClick:n[0]||=()=>t.location.reload()},{default:En(()=>[...n[1]||=[Ji(` Reload `,-1)]]),_:1}))])):Xi(``,!0)}}),wo=Un({__name:`EditorFrame`,props:{connect:{},port:{}},setup(e){let t=e,n=Wt(null),r=null;function i(){return t.connect.url?t.connect.url:t.port==null?null:`${location.protocol}//${location.hostname}:${t.port}${t.connect.path??`/`}`}function a(){let e=i();if(!(!e||!n.value||e===r)){if(t.connect.cookie){let{name:e,value:n}=t.connect.cookie;document.cookie=`${e}=${n}; path=/; SameSite=Lax`}r=e,n.value.src=e}}return ir(a),Nn(()=>[t.connect,t.port],a,{deep:!0}),(e,t)=>(W(),G(`iframe`,{ref_key:`frame`,ref:n,class:`h-full w-full border-0 bg-base`,title:`Editor`,allow:`clipboard-read; clipboard-write; cross-origin-isolated`},null,512))}}),To={class:`absolute inset-0 flex items-center justify-center p-6 bg-base color-base font-sans`},Eo={class:`w-full max-w-[560px]`},Do={class:`flex items-center gap-1.5 mb-2.5 text-xs tracking-wider uppercase color-muted`},Oo={key:0,class:`flex items-center gap-2.5`},ko={class:`flex items-center gap-2.5`},Ao={class:`text-sm color-muted`},jo={key:0,class:`mt-4 px-3.5 py-3 rounded-md border border-base bg-secondary text-sm`},Mo={class:`flex flex-wrap items-center gap-x-2 gap-y-1`},No=[`href`],Po={class:`font-mono color-base px-1.5 py-0.5 rounded bg-base border border-base tracking-wider`},Fo={class:`flex flex-col gap-3 mb-5`},Io={class:`block mb-1 text-xs color-muted`},Lo={class:`flex items-center gap-2 px-2.5 py-2 rounded-md border border-base bg-secondary`},Ro={class:`flex-1 of-x-auto whitespace-nowrap font-mono text-xs color-base`},zo={class:`flex flex-wrap items-center gap-2.5`},Bo={class:`mb-5 text-sm leading-relaxed color-muted`},Vo={key:0,class:`mb-4 px-3 py-2.5 rounded-md border border-error/35 bg-error/10 text-error text-sm whitespace-pre-wrap break-words`},Ho={class:`flex flex-wrap gap-x-4 gap-y-1.5 mb-5 text-xs color-muted`},Uo={class:`font-mono color-base`},Wo={key:0},Go={class:`font-mono color-base`},Ko={key:1},qo={class:`font-mono color-base`},Jo={class:`font-mono color-base`},Yo=`https://coder.com/docs/code-server/latest/install`,Xo=`https://github.com/coder/code-server`,Zo=Un({__name:`LauncherView`,props:{phase:{},detection:{},server:{},busy:{type:Boolean}},emits:[`launch`,`recheck`],setup(e,{emit:t}){let n=e,r=t,i=[{label:`Install script (Linux / macOS)`,command:`curl -fsSL https://code-server.dev/install.sh | sh`},{label:`npm`,command:`npm install -g code-server`},{label:`Homebrew`,command:`brew install code-server`}],a=Wt(null);function o(e){navigator.clipboard?.writeText(e).then(()=>{a.value=e,setTimeout(()=>{a.value===e&&(a.value=null)},1200)}).catch(()=>{})}let s=Y(()=>n.detection.mode===`tunnel`?`tunnel`:n.detection.backend===`ms-code-serve-web`?`code serve-web`:`code-server`),c=Y(()=>n.server.status===`error`?n.server.error:void 0);return(t,n)=>(W(),G(`div`,To,[K(`div`,Eo,[K(`p`,Do,[n[2]||=K(`span`,{class:`i-ph-code-duotone text-sm`},null,-1),K(`span`,null,A(s.value),1)]),e.phase===`connecting`?(W(),G(`div`,Oo,[q(go,{size:`1rem`,class:`color-muted`}),n[3]||=K(`span`,{class:`text-sm color-muted`},`Connecting to devframe…`,-1)])):e.phase===`starting`?(W(),G(H,{key:1},[K(`div`,ko,[q(go,{size:`1rem`,class:`color-muted`}),K(`span`,Ao,A(e.detection.mode===`tunnel`?`Opening the tunnel…`:`Starting the editor…`),1)]),e.server.login?(W(),G(`div`,jo,[n[7]||=K(`p`,{class:`mb-2 color-muted`},` Authorize the tunnel to continue: `,-1),K(`p`,Mo,[n[5]||=K(`span`,{class:`color-muted`},`Open`,-1),K(`a`,{href:e.server.login.url,target:`_blank`,rel:`noreferrer`,class:`color-active hover:underline underline-offset-2 inline-flex items-center gap-1`},[Ji(A(e.server.login.url)+` `,1),n[4]||=K(`span`,{class:`i-ph-arrow-square-out size-3.5`},null,-1)],8,No),n[6]||=K(`span`,{class:`color-muted`},`and enter code`,-1),K(`code`,Po,A(e.server.login.code),1)])])):Xi(``,!0)],64)):e.phase===`not-installed`?(W(),G(H,{key:2},[n[10]||=Yi(`<h1 class="mb-2 text-[1.35rem] font-semibold"> No editor found </h1><p class="mb-5 text-sm leading-relaxed color-muted"> Install <code class="font-mono color-base">code-server</code> (VS Code in the browser), or the Microsoft <code class="font-mono color-base">code</code> CLI for <code class="font-mono color-base">code serve-web</code>. Pick whichever fits your setup, then re-check. </p>`,2),K(`div`,Fo,[(W(),G(H,null,vr(i,({label:e,command:t})=>K(`div`,{key:e},[K(`label`,Io,A(e),1),K(`div`,Lo,[K(`code`,Ro,A(t),1),q(_o,{variant:`action`,size:`sm`,class:`shrink-0 text-[11px]`,onClick:e=>o(t)},{default:En(()=>[Ji(A(a.value===t?`Copied`:`Copy`),1)]),_:2},1032,[`onClick`])])])),64))]),K(`div`,zo,[q(_o,{variant:`primary`,icon:e.busy?void 0:`i-ph-arrows-clockwise`,loading:e.busy,disabled:e.busy,onClick:n[0]||=e=>r(`recheck`)},{default:En(()=>[Ji(A(e.busy?`Checking…`:`Re-check`),1)]),_:1},8,[`icon`,`loading`,`disabled`]),q(_o,{variant:`text`,size:`sm`,href:Yo,icon:`i-ph-arrow-square-out`},{default:En(()=>[...n[8]||=[Ji(` Installation docs `,-1)]]),_:1}),q(_o,{variant:`text`,size:`sm`,href:Xo,icon:`i-ph-github-logo`},{default:En(()=>[...n[9]||=[Ji(` GitHub `,-1)]]),_:1})])],64)):(W(),G(H,{key:3},[n[15]||=K(`h1`,{class:`mb-2 text-[1.35rem] font-semibold`},` Launch the editor `,-1),K(`p`,Bo,A(e.detection.mode===`tunnel`?`Open a code tunnel and edit this workspace from the hosted vscode.dev editor, right here.`:`Start an editor scoped to this workspace and open VS Code right here, signed in automatically.`),1),c.value?(W(),G(`div`,Vo,A(c.value),1)):Xi(``,!0),K(`div`,Ho,[K(`span`,null,[n[11]||=Ji(`mode `,-1),K(`code`,Uo,A(e.detection.mode),1)]),e.detection.mode===`local`?(W(),G(`span`,Wo,[n[12]||=Ji(`backend `,-1),K(`code`,Go,A(e.detection.backend),1)])):Xi(``,!0),e.detection.version?(W(),G(`span`,Ko,[n[13]||=Ji(`version `,-1),K(`code`,qo,A(e.detection.version),1)])):Xi(``,!0),K(`span`,null,[n[14]||=Ji(`binary `,-1),K(`code`,Jo,A(e.detection.bin),1)])]),q(_o,{variant:`primary`,icon:e.busy?void 0:`i-ph-rocket-launch-duotone`,loading:e.busy,disabled:e.busy,onClick:n[1]||=e=>r(`launch`)},{default:En(()=>[Ji(A(e.busy?`Starting…`:e.detection.mode===`tunnel`?`Open tunnel`:`Launch editor`),1)]),_:1},8,[`icon`,`loading`,`disabled`])],64))])]))}}),X={bus:{agentManifestChanged:`agent:manifest:changed`,agentToolRegistered:`agent:tool:registered`,agentToolUnregistered:`agent:tool:unregistered`,agentResourceRegistered:`agent:resource:registered`,agentResourceUnregistered:`agent:resource:unregistered`},client:{isTrustedUpdated:`rpc:is-trusted:updated`,error:`rpc:error`,connectionStatus:`connection:status`,connectionError:`connection:error`},broadcast:{authRevoked:`devframe:auth:revoked`,clientStateUpdated:`devframe:rpc:client-state:updated`,clientStatePatch:`devframe:rpc:client-state:patch`,streamingChunk:`devframe:streaming:chunk`,streamingEnd:`devframe:streaming:end`,streamingUploadCancel:`devframe:streaming:upload-cancel`},inPageChannel:{panelStateUpdated:`devframe:in-page:panel-state:updated`,panelStatePatch:`devframe:in-page:panel-state:patch`},postMessage:{remoteAssetsError:`devframe:remote-assets-error`,inPageChannel:`devframe:in-page-channel`}},Qo=`__connection.json`,$o=`__DEVFRAME_CONNECTION__`,es=`x-birpc-session`,ts=`__rpc-dump/index.json`,ns=`devframe:services`,rs=`devframe_otp`,is=`devframe_auth_token`;X.postMessage.remoteAssetsError;function as(e){return typeof e==`string`?`'${e}'`:new ls().serialize(e)}var os=` _-,;:!?.'"()[]{}@*/\\&#%\`^+<=>|~$0123456789abcdefghijklmnopqrstuvwxyz`,ss=(function(){let e=new Uint8Array(128);for(let t=0;t<69;t++)e[os.charCodeAt(t)]=t+1;for(let t=65;t<=90;t++)e[t]=e[t+32];return e})();function cs(e,t){if(e===t)return 0;let n=Math.min(e.length,t.length),r=0;for(let i=0;i<n;i++){let n=e.charCodeAt(i),a=t.charCodeAt(i);if(n===a)continue;let o=n<128&&ss[n]?ss[n]:n+128,s=a<128&&ss[a]?ss[a]:a+128;if(o!==s)return o<s?-1:1;r===0&&(r=n>a?-1:1)}return e.length===t.length?r:e.length<t.length?-1:1}var ls=(function(){class e{#e=new Map;compare(e,t){let n=typeof e,r=typeof t;return n===`string`&&r===`string`?cs(e,t):n===`number`&&r===`number`?e-t:cs(this.serialize(e,!0),this.serialize(t,!0))}serialize(e,t){if(e===null)return`null`;switch(typeof e){case`string`:return t?e:`'${e}'`;case`bigint`:return`${e}n`;case`object`:return this.$object(e);case`function`:return this.$function(e)}return String(e)}serializeObject(e){let t=Object.prototype.toString.call(e);if(t!==`[object Object]`)return this.serializeBuiltInType(t.length<10?`unknown:${t}`:t.slice(8,-1),e);let n=e.constructor,r=n===Object||n===void 0?``:n.name;if(r!==``&&globalThis[r]===n)return this.serializeBuiltInType(r,e);if(`toJSON`in e&&typeof e.toJSON==`function`){let t=e.toJSON();return r+(typeof t==`object`&&t?this.$object(t):`(${this.serialize(t)})`)}let i=Object.keys(e).sort(cs),a=`${r}{`;for(let t=0;t<i.length;t++){let n=i[t];a+=`${n}:${this.serialize(e[n])}`,t<i.length-1&&(a+=`,`)}return a+`}`}serializeBuiltInType(e,t){let n=this[`$`+e];if(n)return n.call(this,t);if(typeof t.entries==`function`)return this.serializeObjectEntries(e,t.entries());throw Error(`Cannot serialize ${e}`)}serializeObjectEntries(e,t){let n=Array.from(t).sort((e,t)=>this.compare(e[0],t[0])),r=`${e}{`;for(let e=0;e<n.length;e++){let[t,i]=n[e];r+=`${this.serialize(t,!0)}:${this.serialize(i)}`,e<n.length-1&&(r+=`,`)}return r+`}`}$object(e){let t=this.#e.get(e);return t===void 0&&(this.#e.set(e,`#${this.#e.size}`),t=this.serializeObject(e),this.#e.set(e,t)),t}$function(e){let t=Function.prototype.toString.call(e);return t.slice(-15)===`[native code] }`?`${e.name||``}()[native]`:`${e.name}(${e.length})${t.replace(/\s*\n\s*/g,``)}`}$Array(e){let t=`[`;for(let n=0;n<e.length;n++)t+=this.serialize(e[n]),n<e.length-1&&(t+=`,`);return t+`]`}$Date(e){try{return`Date(${e.toISOString()})`}catch{return`Date(null)`}}$ArrayBuffer(e){return`ArrayBuffer[${new Uint8Array(e).join(`,`)}]`}$Set(e){return`Set${this.$Array(Array.from(e).sort((e,t)=>this.compare(e,t)))}`}$Map(e){return this.serializeObjectEntries(`Map`,e.entries())}}for(let t of[`Error`,`RegExp`,`URL`])e.prototype[`$`+t]=function(e){return`${t}(${e})`};for(let t of[`Int8Array`,`Uint8Array`,`Uint8ClampedArray`,`Int16Array`,`Uint16Array`,`Int32Array`,`Uint32Array`,`Float32Array`,`Float64Array`])e.prototype[`$`+t]=function(e){return`${t}[${e.join(`,`)}]`};for(let t of[`BigInt64Array`,`BigUint64Array`])e.prototype[`$`+t]=function(e){return`${t}[${e.join(`n,`)}${e.length>0?`n`:``}]`};return e})(),us=[1779033703,-1150833019,1013904242,-1521486534,1359893119,-1694144372,528734635,1541459225],ds=[1116352408,1899447441,-1245643825,-373957723,961987163,1508970993,-1841331548,-1424204075,-670586216,310598401,607225278,1426881987,1925078388,-2132889090,-1680079193,-1046744716,-459576895,-272742522,264347078,604807628,770255983,1249150122,1555081692,1996064986,-1740746414,-1473132947,-1341970488,-1084653625,-958395405,-710438585,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,-2117940946,-1838011259,-1564481375,-1474664885,-1035236496,-949202525,-778901479,-694614492,-200395387,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,-2067236844,-1933114872,-1866530822,-1538233109,-1090935817,-965641998],fs=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_`,ps=[],ms=class{_data=new hs;_hash=new hs([...us]);_nDataBytes=0;_minBufferSize=0;finalize(e){e&&this._append(e);let t=this._nDataBytes*8,n=this._data.sigBytes*8;return this._data.words[n>>>5]|=128<<24-n%32,this._data.words[(n+64>>>9<<4)+14]=Math.floor(t/4294967296),this._data.words[(n+64>>>9<<4)+15]=t,this._data.sigBytes=this._data.words.length*4,this._process(),this._hash}_doProcessBlock(e,t){let n=this._hash.words,r=n[0],i=n[1],a=n[2],o=n[3],s=n[4],c=n[5],l=n[6],u=n[7];for(let n=0;n<64;n++){if(n<16)ps[n]=e[t+n]|0;else{let e=ps[n-15],t=(e<<25|e>>>7)^(e<<14|e>>>18)^e>>>3,r=ps[n-2],i=(r<<15|r>>>17)^(r<<13|r>>>19)^r>>>10;ps[n]=t+ps[n-7]+i+ps[n-16]}let d=s&c^~s&l,f=r&i^r&a^i&a,p=(r<<30|r>>>2)^(r<<19|r>>>13)^(r<<10|r>>>22),m=(s<<26|s>>>6)^(s<<21|s>>>11)^(s<<7|s>>>25),h=u+m+d+ds[n]+ps[n],g=p+f;u=l,l=c,c=s,s=o+h|0,o=a,a=i,i=r,r=h+g|0}n[0]=n[0]+r|0,n[1]=n[1]+i|0,n[2]=n[2]+a|0,n[3]=n[3]+o|0,n[4]=n[4]+s|0,n[5]=n[5]+c|0,n[6]=n[6]+l|0,n[7]=n[7]+u|0}_append(e){typeof e==`string`&&(e=hs.fromUtf8(e)),this._data.concat(e),this._nDataBytes+=e.sigBytes}_process(e){let t,n=this._data.sigBytes/64;n=e?Math.ceil(n):Math.max((n|0)-this._minBufferSize,0);let r=n*16,i=Math.min(r*4,this._data.sigBytes);if(r){for(let e=0;e<r;e+=16)this._doProcessBlock(this._data.words,e);t=this._data.words.splice(0,r),this._data.sigBytes-=i}return new hs(t,i)}},hs=class e{words;sigBytes;constructor(e,t){e=this.words=e||[],this.sigBytes=t===void 0?e.length*4:t}static fromUtf8(t){let n=unescape(encodeURIComponent(t)),r=n.length,i=[];for(let e=0;e<r;e++)i[e>>>2]|=(n.charCodeAt(e)&255)<<24-e%4*8;return new e(i,r)}toBase64(){let e=[];for(let t=0;t<this.sigBytes;t+=3){let n=this.words[t>>>2]>>>24-t%4*8&255,r=this.words[t+1>>>2]>>>24-(t+1)%4*8&255,i=this.words[t+2>>>2]>>>24-(t+2)%4*8&255,a=n<<16|r<<8|i;for(let n=0;n<4&&t*8+n*6<this.sigBytes*8;n++)e.push(fs.charAt(a>>>6*(3-n)&63))}return e.join(``)}concat(e){if(this.words[this.sigBytes>>>2]&=4294967295<<32-this.sigBytes%4*8,this.words.length=Math.ceil(this.sigBytes/4),this.sigBytes%4)for(let t=0;t<e.sigBytes;t++){let n=e.words[t>>>2]>>>24-t%4*8&255;this.words[this.sigBytes+t>>>2]|=n<<24-(this.sigBytes+t)%4*8}else for(let t=0;t<e.sigBytes;t+=4)this.words[this.sigBytes+t>>>2]=e.words[t>>>2];this.sigBytes+=e.sigBytes}};function gs(e){return new ms().finalize(e).toBase64()}function _s(e){return gs(as(e))}function vs(e){return _s(e)}var ys=class{cacheMap=new Map;options;keySerializer;constructor(e){this.options=e,this.keySerializer=e.keySerializer||(e=>vs(e))}updateOptions(e){this.options={...this.options,...e}}cached(e,t){let n=this.cacheMap.get(e);if(n)return n.get(this.keySerializer(t))}has(e,t){return this.cacheMap.get(e)?.has(this.keySerializer(t))??!1}apply(e,t){let n=this.cacheMap.get(e.m)||new Map;n.set(this.keySerializer(e.a),t),this.cacheMap.set(e.m,n)}validate(e){return this.options.functions.includes(e)}clear(e){e?this.cacheMap.delete(e):this.cacheMap.clear()}};function bs(e,t){let n=`\x1B[${e}m`,r=`\x1B[${t}m`;return((e,...t)=>{if(Array.isArray(e)&&`raw`in e){let i=e,a=``;for(let e=0;e<i.length;e++)a+=i[e],e<t.length&&(a+=String(t[e]));return`${n}${a}${r}`}return`${n}${String(e)}${r}`})}var xs={blue:bs(34,39),cyan:bs(36,39),gray:bs(90,39),green:bs(32,39),red:bs(31,39),yellow:bs(33,39),bold:bs(1,22),dim:bs(2,22),reset:bs(0,0),underline:bs(4,24)};function Ss(e,...t){return typeof e==`function`?e(...t):e}var Cs=Error.captureStackTrace,ws=class e extends Error{name;code;docs;fix;sources;get why(){return this.message}constructor(t,n=e){super(t.why,{cause:t.cause}),this.code=this.name=t.code,this.fix=t.fix,this.docs=t.docs,this.sources=t.sources,Cs?.(this,n)}toJSON(){return{name:this.name,why:this.why,fix:this.fix,docs:this.docs,sources:this.sources,cause:this.cause,stack:this.stack}}};function Ts(e,t){return typeof e==`string`?`${e}/${t.toLowerCase()}`:e?.(t)}function Es(e){let t=e.reporters??[],n={},{docsBase:r}=e;for(let i of Object.keys(e.codes)){let a=e.codes[i],o=a.docs===!1?void 0:a.docs||Ts(r,i),s=(e={},n={})=>{let r=new ws({code:i,why:Ss(a.why,e),fix:Ss(a.fix,e),docs:o,cause:e.cause,sources:e.sources},s);for(let e of t)e(r,n);return r};n[i]=s}return n}function Ds(e){return t=>{let n=`${e.bold(e.red(`[${t.name}]`))} ${t.message}`,r=[];return t.fix&&r.push(`${e.dim(`fix:`)} ${t.fix}`),t.sources?.length&&r.push(`${e.dim(`sources:`)} ${t.sources.join(`, `)}`),t.docs&&r.push(`${e.dim(`see:`)} ${e.cyan(t.docs)}`),r.length===0?n:[n,...r.map((t,n)=>`${e.dim(n<r.length-1?`├▶`:`╰▶`)} ${t}`)].join(`
2
+ `)}}var Os=Ds(xs);function ks(e,{method:t=`warn`}={}){console[t](Os(e))}function As(e){return Es({...e,reporters:[ks,...e.reporters??[]]})}var js=As({docsBase:`https://devfra.me/errors`,codes:{DF0019:{why:e=>`RPC function "${e.name}" has \`agent\` set but \`jsonSerializable\` is not \`true\`; MCP requires JSON-serializable data.`,fix:"Set `jsonSerializable: true` if the payload is JSON-safe, or remove `agent` to keep it RPC-only."},DF0020:{why:e=>`RPC function "${e.name}" declares \`jsonSerializable: true\` but the value at "${e.path}" is a ${e.type}.`,fix:"Either drop `jsonSerializable: true` (falls back to structured-clone) or change the value to a JSON-safe shape."},DF0021:{why:e=>`RPC function "${e.name}" is already registered`,fix:"Use the `force` parameter to overwrite an existing registration."},DF0022:{why:e=>`RPC function "${e.name}" is not registered. Use register() to add new functions.`},DF0023:{why:e=>`RPC function "${e.name}" is not registered`},DF0024:{why:e=>`Either handler or setup function must be provided for RPC function "${e.name}"`},DF0025:{why:e=>`Function "${e.name}" not found in dump store`},DF0026:{why:e=>`No dump match for "${e.name}" with args: ${e.args}`},DF0027:{why:e=>`Function "${e.name}" with type "${e.type}" cannot have dump configuration. Only "static" and "query" types support dumps.`},DF0028:{why:e=>`Function "${e.name}" with type "${e.type}" cannot use \`snapshot: true\`. Only "query" functions support this sugar; "static" functions have equivalent default behavior already.`,fix:"Remove `snapshot: true`, or change the function type to `query`."},DF0043:{why:e=>`RPC function "${e.name}" received an invalid argument at position ${e.index}: ${e.issues}`,fix:"Pass a value that satisfies the `args` schema declared for this function."},DF0044:{why:e=>`RPC function "${e.name}" returned a value that failed its \`returns\` schema: ${e.issues}`,fix:"Make the handler return a value that satisfies the `returns` schema, or relax the schema."}}});async function Ms(e,t){let n=e[`~standard`].validate(t);return n instanceof Promise?await n:n}function Ns(e){return e.map(e=>{let t=e.path?.map(e=>typeof e==`object`?e.key:e).join(`.`);return t?`${t}: ${e.message}`:e.message}).join(`; `)}async function Ps(e,t,n){let r=n.slice();if(!t||t.length===0)return r;for(let r=0;r<t.length;r++){let i=t[r];if(!i)continue;let a=await Ms(i,n[r]);if(a.issues)throw js.DF0043({name:e,index:r,issues:Ns(a.issues)})}return r}async function Fs(e,t,n){if(!t)return n;let r=await Ms(t,n);if(r.issues)throw js.DF0044({name:e,issues:Ns(r.issues)});return n}async function Is(e,t){if(!e.setup)return{};if(typeof t==`object`&&t){e.__cache??=new WeakMap;let n=e.__cache,r=n.get(t);return r||(r=Promise.resolve(e.setup(t)),r.catch(()=>{n.get(t)===r&&n.delete(t)}),n.set(t,r)),await r}if(!e.__promise){let n=Promise.resolve(e.setup(t));n.catch(()=>{e.__promise===n&&(e.__promise=void 0)}),e.__promise=n}return await e.__promise}async function Ls(e,t){let n=e.handler;if(!n){let r=await Is(e,t);if(!r.handler)throw js.DF0024({name:e.name});n=r.handler}let r=e.args,i=e.returns;if(!r&&!i)return n;let a=n;return async(...t)=>{let n=await Ps(e.name,r,t),o=await a(...n);return await Fs(e.name,i,o)}}var Rs=class{context;definitions=new Map;functions;_onChanged=[];constructor(e){this.context=e;let t=this.definitions,n=this;this.functions=new Proxy({},{get(e,r){let i=t.get(r);if(i)return Ls(i,n.context)},has(e,n){return t.has(n)},getOwnPropertyDescriptor(e,n){return{value:t.get(n)?.handler,configurable:!0,enumerable:!0}},ownKeys(){return Array.from(t.keys())}})}register(e,t=!1){if(this.definitions.has(e.name)&&!t)throw js.DF0021({name:e.name});zs(e),this.definitions.set(e.name,e),this._onChanged.forEach(t=>t(e.name))}update(e,t=!1){if(!this.definitions.has(e.name)&&!t)throw js.DF0022({name:e.name});zs(e),this.definitions.set(e.name,e),this._onChanged.forEach(t=>t(e.name))}onChanged(e){return this._onChanged.push(e),()=>{let t=this._onChanged.indexOf(e);t!==-1&&this._onChanged.splice(t,1)}}async getHandler(e){return await Ls(this.definitions.get(e),this.context)}getSchema(e){let t=this.definitions.get(e);if(!t)throw js.DF0023({name:String(e)});return{args:t.args,returns:t.returns}}has(e){return this.definitions.has(e)}get(e){return this.definitions.get(e)}list(){return Array.from(this.definitions.keys())}};function zs(e){if(e.agent&&e.jsonSerializable!==!0)throw js.DF0019({name:e.name})}function Bs(e,t=``){return JSON.stringify(e,function(e,n){let r=this,i=r==null?n:r[e];if(i===void 0){if(Array.isArray(r))throw Hs(t,`undefined`,r,e);return n}return i!==null&&Vs(i,r,e,t),n})}function Vs(e,t,n,r){if(typeof e==`bigint`)throw Hs(r,`BigInt`,t,n);if(typeof e!=`object`)return;if(e instanceof Map)throw Hs(r,`Map`,t,n);if(e instanceof Set)throw Hs(r,`Set`,t,n);if(e instanceof Date)throw Hs(r,`Date`,t,n);if(Array.isArray(e))return;let i=Object.getPrototypeOf(e);if(i!==null&&i!==Object.prototype)throw Hs(r,e.constructor?.name??`class instance`,t,n)}function Hs(e,t,n,r){let i=Us(n,r);return js.DF0020({name:e||`<anonymous>`,type:t,path:i})}function Us(e,t){return Array.isArray(e)?`[${t}]`:t===``?`<root>`:t}function Ws(){let e={};function t(t,...n){let r=e[t]||[];for(let e=0,t=r.length;e<t;e++){let t=r[e];t&&t(...n)}}function n(n,...r){t(n,...r),delete e[n]}function r(t,n){return(e[t]||=[]).push(n),()=>{e[t]=e[t]?.filter(e=>n!==e)}}function i(e,t){let n=r(e,((...e)=>(n(),t(...e))));return n}return{_listeners:e,emit:t,emitOnce:n,on:r,once:i}}String.fromCharCode;var Gs=/^[\s\w\0+.-]{2,}:([/\\]{1,2})/,Ks=/^[\s\w\0+.-]{2,}:([/\\]{2})?/,qs=/^([/\\]\s*){2,}[^/\\]/,Js=/\/$|\/\?|\/#/,Ys=/^\.?\//;function Xs(e,t={}){return typeof t==`boolean`&&(t={acceptRelative:t}),t.strict?Gs.test(e):Ks.test(e)||(t.acceptRelative?qs.test(e):!1)}function Zs(e=``,t){return t?Js.test(e):e.endsWith(`/`)}function Qs(e=``,t){if(!t)return(Zs(e)?e.slice(0,-1):e)||`/`;if(!Zs(e,!0))return e||`/`;let n=e,r=``,i=e.indexOf(`#`);i!==-1&&(n=e.slice(0,i),r=e.slice(i));let[a,...o]=n.split(`?`);return((a.endsWith(`/`)?a.slice(0,-1):a)||`/`)+(o.length>0?`?${o.join(`?`)}`:``)+r}function $s(e=``,t){if(!t)return e.endsWith(`/`)?e:e+`/`;if(Zs(e,!0))return e||`/`;let n=e,r=``,i=e.indexOf(`#`);if(i!==-1&&(n=e.slice(0,i),r=e.slice(i),!n))return r;let[a,...o]=n.split(`?`);return a+`/`+(o.length>0?`?${o.join(`?`)}`:``)+r}function ec(e,t){if(tc(t)||Xs(e))return e;let n=Qs(t);if(e.startsWith(n)){let t=e[n.length];if(!t||t===`/`||t===`?`)return e}return rc(n,e)}function tc(e){return!e||e===`/`}function nc(e){return e&&e!==`/`}function rc(e,...t){let n=e||``;for(let e of t.filter(e=>nc(e)))if(n){let t=e.replace(Ys,``);n=$s(n)+t}else n=e;return n}function ic(e,t){let n=e.match(Ks);return n||=e.match(/^\/{2,}/),n?t+e.slice(n[0].length):t+e}var ac=`__DEVFRAME_CONNECTION_META__`,oc=`__DEVFRAME_CONNECTION_AUTH_TOKEN__`;function sc(e){let t=[()=>window?.[e],()=>globalThis?.[e],()=>parent.window?.[e]];for(let e of t)try{let t=e();if(t)return t}catch{}}function cc(){return sc($o)}function lc(){return sc(ac)}function uc(e){if(e)return e;try{let e=localStorage.getItem(oc);if(e)return e}catch{}return sc(oc)}function dc(e){globalThis[$o]=e,globalThis[ac]={...e.connectionMeta,baseUrl:e.metaBaseUrl},e.authToken&&fc(e.authToken)}function fc(e){try{localStorage.setItem(oc,e)}catch{}globalThis[oc]=e;let t=cc();t&&(globalThis[$o]={...t,authToken:e})}function pc(e){let t=ec(Qo,e);try{return new URL(t,globalThis.location?.href).href}catch{return t}}function mc(e,t){return t&&t!==e.authToken?{...e,authToken:t}:e}function hc(){let e=cc();if(e)return mc(e,uc()??e.authToken??e.connectionMeta.authToken);let t=lc();if(t)return{connectionMeta:t,metaBaseUrl:t.baseUrl??pc(`./`),authToken:uc(t.authToken)}}async function gc(e={}){if(e.connection){let t=mc(e.connection,uc(e.authToken??e.connection.authToken??e.connection.connectionMeta.authToken));return dc(t),t}let t=Array.isArray(e.baseURL)?e.baseURL:[e.baseURL??`./`];if(e.connectionMeta){let n={connectionMeta:e.connectionMeta,metaBaseUrl:pc(t[0]??`./`),authToken:uc(e.authToken??e.connectionMeta.authToken)};return dc(n),n}let n=hc();if(n){let t=mc(n,uc(e.authToken??n.authToken??n.connectionMeta.authToken));return dc(t),t}let r=[];for(let n of t){let t=ec(Qo,n),i=pc(n);try{let n=await fetch(t);if(!n.ok)throw Error(`Failed to fetch connection meta from ${i}: ${n.status}`);let r=await n.json(),a={connectionMeta:r,metaBaseUrl:n.url||i,authToken:uc(e.authToken??r.authToken)};return dc(a),a}catch(e){r.push(e)}}throw Error(`Failed to get connection meta from ${t.join(`, `)}`,{cause:r})}var _c=class extends Error{name=`DevframeConnectionError`;kind;constructor(e,t,n){super(t,n),this.kind=e}};function vc(e=rs){try{let t=globalThis.location?.hash?.replace(/^#/,``)??``;return new URLSearchParams(t).get(e)||void 0}catch{return}}function yc(e){try{let t=new URL(globalThis.location.href),n=new URLSearchParams(t.hash.replace(/^#/,``));if(!n.has(e))return;n.delete(e),t.hash=n.toString(),globalThis.history?.replaceState(globalThis.history.state,``,t.href)}catch{}}function bc(e=rs){let t=vc(e);return t&&yc(e),t}async function xc(e,t={}){let n=bc(t.param??`devframe_otp`);return n?e.isTrusted?!0:e.requestTrustWithCode(n):!1}function Sc(e){let t={},n=new WeakMap,r,i=()=>(r??=e.sharedState.get(ns,{initialValue:{}}).then(e=>(t=e.value(),e.on(`updated`,e=>{t=e}),e)),r);return i(),{state:i,has:e=>e in t,keys:()=>Object.keys(t),get:r=>{let i=t[r];if(!i)return;let a=n.get(i);return a||(a={...i,rpc:e.scope(i.scope).rpc},n.set(i,a)),a}}}var Cc=Symbol.for(`immer-nothing`),wc=Symbol.for(`immer-draftable`),Z=Symbol.for(`immer-state`);function Q(e,...t){throw Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var $=Object,Tc=$.getPrototypeOf,Ec=`constructor`,Dc=`prototype`,Oc=`configurable`,kc=`enumerable`,Ac=`writable`,jc=`value`,Mc=e=>!!e&&!!e[Z];function Nc(e){return e?Ic(e)||Uc(e)||!!e[wc]||!!e[Ec]?.[wc]||Wc(e)||Gc(e):!1}var Pc=$[Dc][Ec].toString(),Fc=new WeakMap;function Ic(e){if(!e||!Kc(e))return!1;let t=Tc(e);if(t===null||t===$[Dc])return!0;let n=$.hasOwnProperty.call(t,Ec)&&t[Ec];if(n===Object)return!0;if(!qc(n))return!1;let r=Fc.get(n);return r===void 0&&(r=Function.toString.call(n),Fc.set(n,r)),r===Pc}function Lc(e,t,n=!0){Rc(e)===0?(n?Reflect.ownKeys(e):$.keys(e)).forEach(n=>{t(n,e[n],e)}):e.forEach((n,r)=>t(r,n,e))}function Rc(e){let t=e[Z];return t?t.type_:Uc(e)?1:Wc(e)?2:Gc(e)?3:0}var zc=(e,t,n=Rc(e))=>n===2?e.has(t):$[Dc].hasOwnProperty.call(e,t),Bc=(e,t,n=Rc(e))=>n===2?e.get(t):e[t],Vc=(e,t,n,r=Rc(e))=>{r===2?e.set(t,n):r===3?e.add(n):e[t]=n};function Hc(e,t){return e===t?e!==0||1/e==1/t:e!==e&&t!==t}var Uc=Array.isArray,Wc=e=>e instanceof Map,Gc=e=>e instanceof Set,Kc=e=>typeof e==`object`,qc=e=>typeof e==`function`,Jc=e=>typeof e==`boolean`;function Yc(e){let t=+e;return Number.isInteger(t)&&String(t)===e}var Xc=e=>Kc(e)?e?.[Z]:null,Zc=e=>e.copy_||e.base_,Qc=e=>e.modified_?e.copy_:e.base_;function $c(e,t){if(Wc(e))return new Map(e);if(Gc(e))return new Set(e);if(Uc(e))return Array[Dc].slice.call(e);let n=Ic(e);if(t===!0||t===`class_only`&&!n){let t=$.getOwnPropertyDescriptors(e);delete t[Z];let n=Reflect.ownKeys(t);for(let r=0;r<n.length;r++){let i=n[r],a=t[i];a[Ac]===!1&&(a[Ac]=!0,a[Oc]=!0),(a.get||a.set)&&(t[i]={[Oc]:!0,[Ac]:!0,[kc]:a[kc],[jc]:e[i]})}return $.create(Tc(e),t)}{let t=Tc(e);if(t!==null&&n)return{...e};let r=$.create(t);return $.assign(r,e)}}function el(e,t=!1){return rl(e)||Mc(e)||!Nc(e)?e:(Rc(e)>1&&$.defineProperties(e,{set:nl,add:nl,clear:nl,delete:nl}),$.freeze(e),t&&Lc(e,(e,t)=>{el(t,!0)},!1),e)}function tl(){Q(2)}var nl={[jc]:tl};function rl(e){return e===null||!Kc(e)||$.isFrozen(e)}var il=`MapSet`,al=`Patches`,ol=`ArrayMethods`,sl={};function cl(e){let t=sl[e];return t||Q(0,e),t}var ll=e=>!!sl[e];function ul(e,t){sl[e]||(sl[e]=t)}var dl,fl=()=>dl,pl=(e,t)=>({drafts_:[],parent_:e,immer_:t,canAutoFreeze_:!0,unfinalizedDrafts_:0,handledSet_:new Set,processedForPatches_:new Set,mapSetPlugin_:ll(il)?cl(il):void 0,arrayMethodsPlugin_:ll(ol)?cl(ol):void 0});function ml(e,t){t&&(e.patchPlugin_=cl(al),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function hl(e){gl(e),e.drafts_.forEach(vl),e.drafts_=null}function gl(e){e===dl&&(dl=e.parent_)}var _l=e=>dl=pl(dl,e);function vl(e){let t=e[Z];t.type_===0||t.type_===1?t.revoke_():t.revoked_=!0}function yl(e,t){t.unfinalizedDrafts_=t.drafts_.length;let n=t.drafts_[0];if(e!==void 0&&e!==n){n[Z].modified_&&(hl(t),Q(4)),Nc(e)&&(e=bl(t,e));let{patchPlugin_:r}=t;r&&r.generateReplacementPatches_(n[Z].base_,e,t)}else e=bl(t,n);return xl(t,e,!0),hl(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e===Cc?void 0:e}function bl(e,t){if(rl(t))return t;let n=t[Z];if(!n)return kl(t,e.handledSet_,e);if(!Cl(n,e))return t;if(!n.modified_)return n.base_;if(!n.finalized_){let{callbacks_:t}=n;if(t)for(;t.length>0;)t.pop()(e);Dl(n,e)}return n.copy_}function xl(e,t,n=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&el(t,n)}function Sl(e){e.finalized_=!0,e.scope_.unfinalizedDrafts_--}var Cl=(e,t)=>e.scope_===t,wl=[];function Tl(e,t,n,r){let i=Zc(e),a=e.type_;if(r!==void 0&&Bc(i,r,a)===t){Vc(i,r,n,a);return}if(!e.draftLocations_){let t=e.draftLocations_=new Map;Lc(i,(e,n)=>{if(Mc(n)){let r=t.get(n)||[];r.push(e),t.set(n,r)}})}let o=e.draftLocations_.get(t)??wl;for(let e of o)Vc(i,e,n,a)}function El(e,t,n){e.callbacks_.push(function(r){let i=t;if(!i||!Cl(i,r))return;r.mapSetPlugin_?.fixSetContents(i);let a=Qc(i);Tl(e,i.draft_??i,a,n),Dl(i,r)})}function Dl(e,t){if(e.modified_&&!e.finalized_&&(e.type_===3||e.type_===1&&e.allIndicesReassigned_||(e.assigned_?.size??0)>0)){let{patchPlugin_:n}=t;if(n){let r=n.getPath(e);r&&n.generatePatches_(e,r,t)}Sl(e)}}function Ol(e,t,n){let{scope_:r}=e;if(Mc(n)){let i=n[Z];Cl(i,r)&&i.callbacks_.push(function(){Rl(e),Tl(e,n,Qc(i),t)})}else Nc(n)&&e.callbacks_.push(function(){let i=Zc(e);e.type_===3?i.has(n)&&kl(n,r.handledSet_,r):Bc(i,t,e.type_)===n&&r.drafts_.length>1&&(e.assigned_.get(t)??!1)===!0&&e.copy_&&kl(Bc(e.copy_,t,e.type_),r.handledSet_,r)})}function kl(e,t,n){return!n.immer_.autoFreeze_&&n.unfinalizedDrafts_<1||Mc(e)||t.has(e)||!Nc(e)||rl(e)?e:(t.add(e),Lc(e,(r,i)=>{if(Mc(i)){let t=i[Z];Cl(t,n)&&(Vc(e,r,Qc(t),e.type_),Sl(t))}else Nc(i)&&kl(i,t,n)}),e)}function Al(e,t){let n=Uc(e),r={type_:+!!n,scope_:t?t.scope_:fl(),modified_:!1,finalized_:!1,assigned_:void 0,parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1,callbacks_:void 0},i=r,a=jl;n&&(i=[r],a=Ml);let{revoke:o,proxy:s}=Proxy.revocable(i,a);return r.draft_=s,r.revoke_=o,[s,r]}var jl={get(e,t){if(t===Z)return e;let n=e.scope_.arrayMethodsPlugin_,r=e.type_===1&&typeof t==`string`;if(r&&n?.isArrayOperationMethod(t))return n.createMethodInterceptor(e,t);let i=Zc(e);if(!zc(i,t,e.type_))return Fl(e,i,t);let a=i[t];if(e.finalized_||!Nc(a)||r&&e.operationMethod&&n?.isMutatingArrayMethod(e.operationMethod)&&Yc(t))return a;if(a===Nl(e.base_,t)||Pl(e,t,a)){Rl(e);let n=e.type_===1?+t:t,r=Bl(e.scope_,a,e,n);return e.copy_[n]=r}return a},has(e,t){return t in Zc(e)},ownKeys(e){return Reflect.ownKeys(Zc(e))},set(e,t,n){let r=Il(Zc(e),t);if(r?.set)return r.set.call(e.draft_,n),!0;if(!e.modified_){let r=Nl(Zc(e),t),i=r?.[Z];if(i&&i.base_===n)return e.copy_[t]=n,e.assigned_.set(t,!1),!0;if(Hc(n,r)&&(n!==void 0||zc(e.base_,t,e.type_)))return!0;Rl(e),Ll(e)}return e.copy_[t]===n&&(n!==void 0||zc(e.copy_,t,e.type_))||Number.isNaN(n)&&Number.isNaN(e.copy_[t])?!0:(e.copy_[t]=n,e.assigned_.set(t,!0),Ol(e,t,n),!0)},deleteProperty(e,t){return Rl(e),Nl(e.base_,t)!==void 0||t in e.base_?(e.assigned_.set(t,!1),Ll(e)):e.assigned_.delete(t),e.copy_&&delete e.copy_[t],!0},getOwnPropertyDescriptor(e,t){let n=Zc(e),r=Reflect.getOwnPropertyDescriptor(n,t);return r&&{[Ac]:!0,[Oc]:e.type_!==1||t!==`length`,[kc]:r[kc],[jc]:n[t]}},defineProperty(){Q(11)},getPrototypeOf(e){return Tc(e.base_)},setPrototypeOf(){Q(12)}},Ml={};for(let e in jl){let t=jl[e];Ml[e]=function(){let e=arguments;return e[0]=e[0][0],t.apply(this,e)}}Ml.deleteProperty=function(e,t){return Ml.set.call(this,e,t,void 0)},Ml.set=function(e,t,n){return jl.set.call(this,e[0],t,n,e[0])};function Nl(e,t){let n=e[Z];return(n?Zc(n):e)[t]}function Pl(e,t,n){return e.type_!==1||!e.allIndicesReassigned_||e.assigned_?.get(t)||!Nc(n)||n[Z]?!1:e.baseRefs_.has(n)}function Fl(e,t,n){let r=Il(t,n);return r?jc in r?r[jc]:r.get?.call(e.draft_):void 0}function Il(e,t){if(!(t in e))return;let n=Tc(e);for(;n;){let e=Object.getOwnPropertyDescriptor(n,t);if(e)return e;n=Tc(n)}}function Ll(e){e.modified_||(e.modified_=!0,e.parent_&&Ll(e.parent_))}function Rl(e){e.copy_||=(e.assigned_=new Map,$c(e.base_,e.scope_.immer_.useStrictShallowCopy_))}var zl=class{constructor(e){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.useStrictIteration_=!1,this.produce=(e,t,n)=>{if(qc(e)&&!qc(t)){let n=t;t=e;let r=this;return function(e=n,...i){return r.produce(e,e=>t.call(this,e,...i))}}qc(t)||Q(6),n!==void 0&&!qc(n)&&Q(7);let r;if(Nc(e)){let i=_l(this),a=Bl(i,e,void 0),o=!0;try{r=t(a),o=!1}finally{o?hl(i):gl(i)}return ml(i,n),yl(r,i)}if(!e||!Kc(e)){if(r=t(e),r===void 0&&(r=e),r===Cc&&(r=void 0),this.autoFreeze_&&el(r,!0),n){let t=[],i=[];cl(al).generateReplacementPatches_(e,r,{patches_:t,inversePatches_:i}),n(t,i)}return r}Q(1,e)},this.produceWithPatches=(e,t)=>{if(qc(e))return(t,...n)=>this.produceWithPatches(t,t=>e(t,...n));let n,r;return[this.produce(e,t,(e,t)=>{n=e,r=t}),n,r]},Jc(e?.autoFreeze)&&this.setAutoFreeze(e.autoFreeze),Jc(e?.useStrictShallowCopy)&&this.setUseStrictShallowCopy(e.useStrictShallowCopy),Jc(e?.useStrictIteration)&&this.setUseStrictIteration(e.useStrictIteration)}createDraft(e){Nc(e)||Q(8),Mc(e)&&(e=Vl(e));let t=_l(this),n=Bl(t,e,void 0);return n[Z].isManual_=!0,gl(t),n}finishDraft(e,t){let n=e&&e[Z];(!n||!n.isManual_)&&Q(9);let{scope_:r}=n;return ml(r,t),yl(void 0,r)}setAutoFreeze(e){this.autoFreeze_=e}setUseStrictShallowCopy(e){this.useStrictShallowCopy_=e}setUseStrictIteration(e){this.useStrictIteration_=e}shouldUseStrictIteration(){return this.useStrictIteration_}applyPatches(e,t){let n;for(n=t.length-1;n>=0;n--){let r=t[n];if(r.path.length===0&&r.op===`replace`){e=r.value;break}}n>-1&&(t=t.slice(n+1));let r=cl(al).applyPatches_;return Mc(e)?r(e,t):this.produce(e,e=>r(e,t))}};function Bl(e,t,n,r){let[i,a]=Wc(t)?cl(il).proxyMap_(t,n):Gc(t)?cl(il).proxySet_(t,n):Al(t,n);return(n?.scope_??fl()).drafts_.push(i),a.callbacks_=n?.callbacks_??[],a.key_=r,n&&r!==void 0?El(n,a,r):a.callbacks_.push(function(e){e.mapSetPlugin_?.fixSetContents(a);let{patchPlugin_:t}=e;a.modified_&&t&&t.generatePatches_(a,[],e)}),i}function Vl(e){return Mc(e)||Q(10,e),Hl(e)}function Hl(e){if(!Nc(e)||rl(e))return e;let t=e[Z],n,r=!0;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,n=$c(e,t.scope_.immer_.useStrictShallowCopy_),r=t.scope_.immer_.shouldUseStrictIteration()}else n=$c(e,!0);return Lc(n,(e,t)=>{Vc(n,e,Hl(t))},r),t&&(t.finalized_=!1),n}function Ul(){function e(n,r=[]){if(n.key_!==void 0){let e=n.parent_.copy_??n.parent_.base_,t=Xc(Bc(e,n.key_)),i=Bc(e,n.key_);if(i===void 0||i!==n.draft_&&i!==n.base_&&i!==n.copy_||t!=null&&t.base_!==n.base_)return null;let a=n.parent_.type_===3,o;if(a){let e=n.parent_;o=Array.from(e.drafts_.keys()).indexOf(n.key_)}else o=n.key_;if(!(a&&e.size>o||zc(e,o)))return null;r.push(o)}if(n.parent_)return e(n.parent_,r);r.reverse();try{t(n.copy_,r)}catch{return null}return r}function t(e,t){let n=e;for(let e=0;e<t.length-1;e++){let r=t[e];if(n=Bc(n,r),!Kc(n)||n===null)throw Error(`Cannot resolve path at '${t.join(`/`)}'`)}return n}let n=`replace`,r=`remove`;function i(e,t,n){if(e.scope_.processedForPatches_.has(e))return;e.scope_.processedForPatches_.add(e);let{patches_:r,inversePatches_:i}=n;switch(e.type_){case 0:case 2:return o(e,t,r,i);case 1:return a(e,t,r,i);case 3:return s(e,t,r,i)}}function a(e,t,i,a){let{base_:o,assigned_:s}=e,c=e.copy_;c.length<o.length&&([o,c]=[c,o],[i,a]=[a,i]);let l=e.allIndicesReassigned_===!0;for(let e=0;e<o.length;e++){let r=c[e],u=o[e];if((l||s?.get(e.toString()))&&r!==u){let o=r?.[Z];if(o&&o.modified_)continue;let s=t.concat([e]);i.push({op:n,path:s,value:d(r)}),a.push({op:n,path:s,value:d(u)})}}for(let e=o.length;e<c.length;e++){let n=t.concat([e]);i.push({op:`add`,path:n,value:d(c[e])})}for(let e=c.length-1;o.length<=e;--e){let n=t.concat([e]);a.push({op:r,path:n})}}function o(e,t,i,a){let{base_:o,copy_:s,type_:c}=e;Lc(e.assigned_,(e,l)=>{let u=Bc(o,e,c),f=Bc(s,e,c),p=l?zc(o,e)?n:`add`:r;if(u===f&&p===n)return;let m=t.concat(e);i.push(p===r?{op:p,path:m}:{op:p,path:m,value:d(f)}),a.push(p===`add`?{op:r,path:m}:p===r?{op:`add`,path:m,value:d(u)}:{op:n,path:m,value:d(u)})})}function s(e,t,n,i){let{base_:a,copy_:o}=e,s=0;a.forEach(e=>{if(!o.has(e)){let a=t.concat([s]);n.push({op:r,path:a,value:e}),i.unshift({op:`add`,path:a,value:e})}s++}),s=0,o.forEach(e=>{if(!a.has(e)){let a=t.concat([s]);n.push({op:`add`,path:a,value:e}),i.unshift({op:r,path:a,value:e})}s++})}function c(e,t,r){let{patches_:i,inversePatches_:a}=r;i.push({op:n,path:[],value:t===Cc?void 0:t}),a.push({op:n,path:[],value:e})}function l(e,t){return t.forEach(t=>{let{path:i,op:a}=t,o=e;for(let e=0;e<i.length-1;e++){let t=Rc(o),n=i[e];typeof n!=`string`&&typeof n!=`number`&&(n=``+n),(t===0||t===1)&&(n===`__proto__`||n===Ec)&&Q(19),qc(o)&&n===Dc&&Q(19),o=Bc(o,n),(o===null||!Kc(o))&&Q(18,i.join(`/`))}let s=Rc(o),c=u(t.value),l=i[i.length-1];switch(a){case n:switch(s){case 2:return o.set(l,c);case 3:Q(16);default:return o[l]=c}case`add`:switch(s){case 1:return l===`-`?o.push(c):o.splice(l,0,c);case 2:return o.set(l,c);case 3:return o.add(c);default:return o[l]=c}case r:switch(s){case 1:return o.splice(l,1);case 2:return o.delete(l);case 3:return o.delete(t.value);default:return delete o[l]}default:Q(17,a)}}),e}function u(e){if(!Nc(e))return e;if(Uc(e))return e.map(u);if(Wc(e))return new Map(Array.from(e.entries()).map(([e,t])=>[e,u(t)]));if(Gc(e))return new Set(Array.from(e).map(u));let t=Object.create(Tc(e));for(let n in e)t[n]=u(e[n]);return zc(e,wc)&&(t[wc]=e[wc]),t}function d(e){return Mc(e)?u(e):e}ul(al,{applyPatches_:l,generatePatches_:i,generateReplacementPatches_:c,getPath:e})}globalThis.Iterator?.from;var Wl=new zl,Gl=Wl.produce,Kl=Wl.produceWithPatches.bind(Wl),ql=Wl.applyPatches.bind(Wl),Jl=`useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict`;function Yl(e=21){let t=``,n=e;for(;n--;)t+=Jl[Math.random()*64|0];return t}var Xl=1e3;function Zl(e,t){if(e.add(t),e.size>Xl){let t=e.values().next().value;t!==void 0&&e.delete(t)}}function Ql(e){let{enablePatches:t=!1}=e;t&&Ul();let n=Ws(),r=e.initialValue,i=new Set;return{on:n.on,value:()=>r,patch:(e,t=Yl())=>{i.has(t)||(Ul(),r=ql(r,e),Zl(i,t),n.emit(`updated`,r,void 0,t))},mutate:(e,a=Yl())=>{if(!i.has(a)){if(Zl(i,a),t){let[t,i]=Kl(r,e);r=t,n.emit(`updated`,r,i,a)}else r=Gl(r,e),n.emit(`updated`,r,void 0,a)}},syncIds:i}}function $l(e){let t=new Map,n=new Map,r=new Map,i=new Set,a=e.connectionMeta.backend===`static`;function o(e,t){let n=r.get(e);return n&&typeof n==`object`&&!Array.isArray(n)&&typeof t==`object`&&!Array.isArray(t)?{...n,...t}:t}e.client.register({name:X.broadcast.clientStateUpdated,type:`event`,handler:(e,n,r)=>{let i=t.get(e);!i||i.syncIds.has(r)||i.mutate(()=>o(e,n),r)}}),e.client.register({name:X.broadcast.clientStatePatch,type:`event`,handler:(e,n,r)=>{let i=t.get(e);!i||i.syncIds.has(r)||i.patch(n,r)}});function s(t,n){let r=[];return r.push(n.on(`updated`,(n,r,i)=>{a||(r?e.callEvent(`devframe:rpc:server-state:patch`,t,r,i):e.callEvent(`devframe:rpc:server-state:set`,t,n,i))})),()=>{for(let e of r)e()}}return{keys:()=>Array.from(t.keys()),onKeyAdded(e){return i.add(e),()=>{i.delete(e)}},delete(e){let i=n.get(e);n.delete(e);let a=t.delete(e);return r.delete(e),i?.(),a},get:async(c,l)=>{if(l?.initialValue!==void 0&&r.set(c,l.initialValue),t.has(c))return t.get(c);let u=Ql({initialValue:l?.initialValue,enablePatches:!1});async function d(){if(a||e.callEvent(`devframe:rpc:server-state:subscribe`,c),l?.initialValue!==void 0){t.set(c,u);for(let e of i)e(c);return e.call(`devframe:rpc:server-state:get`,c).then(e=>{e!==void 0&&u.mutate(()=>o(c,e))}).catch(e=>{console.error(`Error getting server state`,e)}),n.set(c,s(c,u)),u}{let r=await e.call(`devframe:rpc:server-state:get`,c);u.mutate(()=>o(c,r)),t.set(c,u);for(let e of i)e(c);return n.set(c,s(c,u)),u}}return new Promise(t=>{if(e.isTrusted)d().then(t);else{t(u);let n=!1;e.events.on(X.client.isTrustedUpdated,e=>{e&&!n&&(n=!0,d())})}})}}}var eu=typeof self==`object`?self:globalThis,tu=new Set([`Error`,`EvalError`,`RangeError`,`ReferenceError`,`SyntaxError`,`TypeError`,`URIError`,`AggregateError`]),nu=new Set([`Boolean`,`Number`,`String`,`Int8Array`,`Uint8Array`,`Uint8ClampedArray`,`Int16Array`,`Uint16Array`,`Int32Array`,`Uint32Array`,`Float16Array`,`Float32Array`,`Float64Array`,`BigInt64Array`,`BigUint64Array`]);function ru(e,t){let n=(t,n)=>(e.set(n,t),t),r=i=>{if(e.has(i))return e.get(i);let[a,o]=t[i];switch(a){case 0:case-1:return n(o,i);case 1:{let e=n([],i);for(let t of o)e.push(r(t));return e}case 2:{let e=n({},i);for(let[t,n]of o)e[r(t)]=r(n);return e}case 3:return n(new Date(o),i);case 4:{let{source:e,flags:t}=o;return n(new RegExp(e,t),i)}case 5:{let e=n(new Map,i);for(let[t,n]of o)e.set(r(t),r(n));return e}case 6:{let e=n(new Set,i);for(let t of o)e.add(r(t));return e}case 7:{let{name:e,message:t}=o,r=tu.has(e)?eu[e]:void 0;return n(new(r??eu.Error)(t),i)}case 8:return n(BigInt(o),i);case`BigInt`:return n(Object(BigInt(o)),i);case`ArrayBuffer`:return n(new Uint8Array(o).buffer,o);case`DataView`:{let{buffer:e}=new Uint8Array(o);return n(new DataView(e),o)}}if(typeof a==`string`&&nu.has(a))return n(new eu[a](o),i);throw TypeError(`unable to deserialize unsafe or unknown type: ${String(a)}`)};return r}function iu(e){return ru(new Map,e)(0)}var au=``,{toString:ou}={},{keys:su}=Object;function cu(e){let t=typeof e;if(t!==`object`||!e)return[0,t];let n=ou.call(e).slice(8,-1);switch(n){case`Array`:return[1,au];case`Object`:return[2,au];case`Date`:return[3,au];case`RegExp`:return[4,au];case`Map`:return[5,au];case`Set`:return[6,au];case`DataView`:return[1,n]}return n.includes(`Array`)?[1,n]:n.includes(`Error`)?[7,n]:[2,n]}function lu([e,t]){return e===0&&(t===`function`||t===`symbol`)}function uu(e,t,n,r){let i=(e,t)=>{let i=r.push(e)-1;return n.set(t,i),i},a=r=>{if(n.has(r))return n.get(r);let[o,s]=cu(r);switch(o){case 0:{let t=r;switch(s){case`bigint`:o=8,t=r.toString();break;case`function`:case`symbol`:if(e)throw TypeError(`unable to serialize ${s}`);t=null;break;case`undefined`:return i([-1],r)}return i([o,t],r)}case 1:{if(s){let e=r;return s===`DataView`?e=new Uint8Array(r.buffer):s===`ArrayBuffer`&&(e=new Uint8Array(r)),i([s,[...e]],r)}let e=[],t=i([o,e],r);for(let t of r)e.push(a(t));return t}case 2:{if(s)switch(s){case`BigInt`:return i([s,r.toString()],r);case`Boolean`:case`Number`:case`String`:return i([s,r.valueOf()],r)}if(t&&`toJSON`in r)return a(r.toJSON());let n=[],c=i([o,n],r);for(let t of su(r))(e||!lu(cu(r[t])))&&n.push([a(t),a(r[t])]);return c}case 3:return i([o,r.toISOString()],r);case 4:{let{source:e,flags:t}=r;return i([o,{source:e,flags:t}],r)}case 5:{let t=[],n=i([o,t],r);for(let[n,i]of r)(e||!(lu(cu(n))||lu(cu(i))))&&t.push([a(n),a(i)]);return n}case 6:{let t=[],n=i([o,t],r);for(let n of r)(e||!lu(cu(n)))&&t.push(a(n));return n}}let{message:c}=r;return i([o,{name:s,message:c}],r)};return a}function du(e,t={}){let n=[];return uu(!(t.json||t.lossy),!!t.json,new Map,n)(e),n}var{parse:fu,stringify:pu}=JSON,mu={json:!0,lossy:!0};function hu(e){return iu(fu(e))}function gu(e){return pu(du(e,mu))}function _u(e){return iu(e)}function vu(e){return gu(e)}function yu(e){return hu(e)}var bu=new Map;function xu(e=bu){let t=new Map;return{serialize:n=>{let r;return n.t===`q`?r=n.m:(r=t.get(n.i),t.delete(n.i)),!(n.t===`s`&&`e`in n)&&r&&e.get(r)?.jsonSerializable===!0?Bs(n,r??``):`s:${vu(n)}`},deserialize:e=>{let n=e.startsWith(`s:`)?yu(e.slice(2)):JSON.parse(e);return n.t===`q`&&n.i&&n.m&&t.set(n.i,n.m),n}}}function Su(){}function Cu(e){let t=e.search(/\n\n|\r\n\r\n/);if(!(t<0))return{frame:e.slice(0,t),rest:e.slice(t+(e[t]===`\r`?4:2))}}function wu(e){let t=`message`,n=[];for(let r of e.split(/\r?\n/))r.startsWith(`:`)||(r.startsWith(`event:`)?t=r.slice(6).trimStart():r.startsWith(`data:`)&&n.push(r.slice(5).replace(/^ /,``)));return{event:t,data:n}}function Tu(e){let{onConnected:t=Su,onError:n=Su,onDisconnected:r=Su,definitions:i,fetch:a=globalThis.fetch.bind(globalThis)}=e,o=e.url;e.authToken&&(o=`${o}${o.includes(`?`)?`&`:`?`}${is}=${encodeURIComponent(e.authToken)}`);let s=xu(i),c=new AbortController,l=!1,u,d,f,p,m=new Promise((e,t)=>{f=e,p=t});m.catch(()=>{});function h(e){l||(l=!0,p(e),n(e),r())}function g(){l||(l=!0,p(Error(`Devframe SSE stream closed`)),r())}function _(e,n){if(e===`session`){f(n),t();return}u?.(n)}async function v(e){let t=e.getReader();d=t;let n=new TextDecoder,r=``;for(;;){let{done:e,value:i}=await t.read();if(e)break;for(r+=n.decode(i,{stream:!0});;){let e=Cu(r);if(!e)break;r=e.rest;let{event:t,data:n}=wu(e.frame);n.length>0&&_(t,n.join(`
3
+ `))}}g()}return(async()=>{try{let e=await a(o,{headers:{accept:`text/event-stream`},signal:c.signal});if(!e.ok||!e.body)throw Error(`Devframe SSE stream request failed: ${e.status}`);await v(e.body)}catch(e){if(c.signal.aborted){g();return}h(e instanceof Error?e:Error(String(e)))}})(),{close:()=>{l=!0,c.abort(),d?.cancel().catch(()=>{})},on:e=>{u=e},post:async e=>{let t;try{t=await m}catch{return}if(l){n(Error(`Devframe SSE channel is closed; message dropped`));return}try{let n=await a(o,{method:`POST`,headers:{"content-type":`text/plain; charset=utf-8`,[es]:t},body:e});if(n.status===200){let e=await n.text();e&&u?.(e);return}if(!n.ok)throw Error(`Devframe SSE POST failed: ${n.status}`)}catch(e){n(e instanceof Error?e:Error(String(e)))}},serialize:s.serialize,deserialize:s.deserialize}}function Eu(){let e,t;return{promise:new Promise((n,r)=>{e=n,t=r}),resolve:e,reject:t}}var Du=Math.random.bind(Math),Ou=`useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict`;function ku(e=21){let t=``,n=e;for(;n--;)t+=Ou[Du()*64|0];return t}var Au=6e4,ju=e=>e,Mu=ju,{clearTimeout:Nu,setTimeout:Pu}=globalThis;function Fu(e,t){let{post:n,on:r,off:i=()=>{},eventNames:a=[],serialize:o=ju,deserialize:s=Mu,resolver:c,bind:l=`rpc`,timeout:u=Au,proxify:d=!0}=t,f=!1,p=new Map,m,h;async function g(e,r,i,a){if(f)throw Error(`[birpc] rpc is closed, cannot call "${e}"`);let s={m:e,a:r,t:`q`};a&&(s.o=!0);let c=async e=>n(o(e));if(i){await c(s);return}if(m)try{await m}finally{m=void 0}let{promise:l,resolve:d,reject:g}=Eu(),_=ku();s.i=_;let v;async function y(n=s){return u>=0&&(v=Pu(()=>{try{if(t.onTimeoutError?.call(h,e,r)!==!0)throw Error(`[birpc] timeout on calling "${e}"`)}catch(e){g(e)}p.delete(_)},u),typeof v==`object`&&(v=v.unref?.())),p.set(_,{resolve:d,reject:g,timeoutId:v,method:e}),await c(n),l}try{t.onRequest?await t.onRequest.call(h,s,y,d):await y()}catch(e){if(t.onGeneralError?.call(h,e)!==!0)throw e;return}finally{Nu(v),p.delete(_)}return l}let _={$call:(e,...t)=>g(e,t,!1),$callOptional:(e,...t)=>g(e,t,!1,!0),$callEvent:(e,...t)=>g(e,t,!0),$callRaw:e=>g(e.method,e.args,e.event,e.optional),$rejectPendingCalls:y,get $closed(){return f},get $meta(){return t.meta},$close:v,$functions:e};h=d?new Proxy({},{get(t,n){if(Object.hasOwn(_,n))return _[n];if(n===`then`&&!a.includes(`then`)&&!(`then`in e))return;let r=(...e)=>g(n,e,!0);if(a.includes(n))return r.asEvent=r,r;let i=(...e)=>g(n,e,!1);return i.asEvent=r,i}}):_;function v(e){f=!0,p.forEach(({reject:t,method:n})=>{let r=Error(`[birpc] rpc is closed, cannot call "${n}"`);if(e)return e.cause??=r,t(e);t(r)}),p.clear(),i(b)}function y(e){let t=Array.from(p.values()).map(({method:t,reject:n})=>e?e({method:t,reject:n}):n(Error(`[birpc]: rejected pending call "${t}".`)));return p.clear(),t}async function b(r,...i){let a;try{a=s(r)}catch(e){if(t.onGeneralError?.call(h,e)!==!0)throw e;return}if(a.t===`q`){let{m:r,a:s,o:u}=a,d,f,p=await(c?c.call(h,r,e[r]):e[r]);if(u&&(p||=()=>void 0),!p)f=Error(`[birpc] function "${r}" not found`);else try{d=await p.apply(l===`rpc`?h:e,s)}catch(e){f=e}if(a.i){if(f&&t.onFunctionError&&t.onFunctionError.call(h,f,r,s)===!0)return;if(!f)try{await n(o({t:`s`,i:a.i,r:d}),...i);return}catch(e){if(f=e,t.onGeneralError?.call(h,e,r,s)!==!0)throw e}try{await n(o({t:`s`,i:a.i,e:f}),...i)}catch(e){if(t.onGeneralError?.call(h,e,r,s)!==!0)throw e}}}else{let{i:e,r:t,e:n}=a,r=p.get(e);r&&(Nu(r.timeoutId),n?r.reject(n):r.resolve(t)),p.delete(e)}}return m=r(b),h}function Iu(e,t){let{channel:n,rpcOptions:r={}}=t;return Fu(e,{...n,timeout:-1,...r,proxify:!1})}function Lu(){let e,t;return{promise:new Promise((n,r)=>{e=n,t=r}),resolve:e,reject:t}}function Ru(e){let{transport:t,authToken:n,connectionMeta:r,events:i,clientRpc:a,rpcOptions:o={},callTimeout:s=0}=e,c=!1,l=`connecting`,u=null,d=Lu();function f(e,t=null){if(t?u=t:e===`connected`&&(u=null),e===l)return;let n=l;l=e,i.emit(X.client.connectionStatus,e,n)}let p=new Set;function m(e){for(let t of[...p])t.reject(e)}function h(){return l===`disconnected`||l===`error`?new _c(`connection`,`[devframe] Not connected to the devframe server`,{cause:u??void 0}):l===`unauthorized`?new _c(`auth`,`[devframe] Not authorized by the devframe server`,{cause:u??void 0}):null}function g(e,t){return new Promise((n,r)=>{let a=!1,o,c={reject(e){a||(l(),i.emit(X.client.error,e,t),r(e))}};function l(){a=!0,p.delete(c),o&&clearTimeout(o)}p.add(c),s>0&&(o=setTimeout(()=>{c.reject(new _c(`timeout`,`[devframe] RPC call "${t}" timed out after ${s}ms`))},s)),e.then(e=>{a||(l(),n(e))},e=>{if(a)return;l();let n=e instanceof Error?e:Error(String(e));i.emit(X.client.error,n,t),r(n)})})}let _=new Map;for(let e of r.jsonSerializableMethods??[])_.set(e,{jsonSerializable:!0});let v=e.createChannel({definitions:_,onError(e){f(`error`,e),i.emit(X.client.connectionError,e),m(new _c(`connection`,`[devframe] Connection to the devframe server failed`,{cause:e}))},onDisconnected(){l!==`error`&&f(`disconnected`),m(new _c(`connection`,`[devframe] Disconnected from the devframe server`,{cause:u??void 0}))}}),y=Iu(a.functions,{channel:v,rpcOptions:o});a.register({name:X.broadcast.authRevoked,type:`event`,handler:()=>{c=!1;let e=new _c(`auth`,`[devframe] The devframe server revoked this client's trust`);f(`unauthorized`,e),i.emit(X.client.connectionError,e),m(e),i.emit(X.client.isTrustedUpdated,!1)}});let b=n;async function x(e){b=e;let t=await y.$call(`anonymous:devframe:auth`,{authToken:e,ua:navigator.userAgent,origin:location.origin});if(c=t.isTrusted,c)d.resolve(!0),f(`connected`);else{let e=new _c(`auth`,`[devframe] The devframe server refused this client's credentials`);f(`unauthorized`,e),i.emit(X.client.connectionError,e)}return i.emit(X.client.isTrustedUpdated,c),t.isTrusted}async function S(e){let t=(await y.$call(`anonymous:devframe:auth:exchange`,{code:e,ua:navigator.userAgent,origin:location.origin}))?.authToken??null;return t&&(b=t,c=!0,d.resolve(!0),f(`connected`),i.emit(X.client.isTrustedUpdated,!0)),t}async function C(){return c?!0:x(b??``)}async function w(e=6e4){if(c&&d.resolve(!0),e<=0)return d.promise;let t=()=>{};return await Promise.race([d.promise.then(t),new Promise((n,r)=>{let i=setTimeout(()=>{r(Error(`[devframe] Timeout waiting for rpc to be trusted`))},e);t=()=>clearTimeout(i)})]),c}return{transport:t,get isTrusted(){return c},get status(){return l},get connectionError(){return u},requestTrust:C,requestTrustWithToken:x,requestTrustWithCode:S,ensureTrusted:w,call:(...e)=>{let t=String(e[0]),n=h();return n?(i.emit(X.client.error,n,t),Promise.reject(n)):g(y.$call(...e),t)},callEvent:(...e)=>{let t=h();if(t){i.emit(X.client.error,t,String(e[0]));return}return y.$callEvent(...e)},callOptional:(...e)=>{let t=String(e[0]),n=h();return n?(i.emit(X.client.error,n,t),Promise.reject(n)):g(y.$callOptional(...e),t)},close:()=>{v.close()}}}function zu(e,t,n){let r=(()=>{try{return new URL(t,n.href)}catch{return new URL(n.href)}})();if(e&&typeof e==`object`){if(e.host!=null||e.port!=null){let t=e.host??`${r.hostname}:${e.port}`;return new URL(e.path??`/`,`${r.protocol}//${t}`).href}return new URL(e.path??``,r).href}let i=e??``;return/^https?:\/\//i.test(i)?i:new URL(i,r).href}function Bu(e){let{authToken:t,connectionMeta:n,metaBaseUrl:r,events:i,clientRpc:a,rpcOptions:o={},sseOptions:s={},callTimeout:c=0}=e,l=zu(n.sse,r??`./`,location);return Ru({transport:`sse`,authToken:t,connectionMeta:n,events:i,clientRpc:a,rpcOptions:o,callTimeout:c,createChannel:e=>Tu({url:l,authToken:t,definitions:e.definitions,...s,onConnected(){s.onConnected?.()},onError(t){e.onError(t),s.onError?.(t)},onDisconnected(){e.onDisconnected(),s.onDisconnected?.()}})})}function Vu(e){let{name:t,message:n,cause:r,...i}=e,a=r instanceof Error?r:Hu(r)?Vu(r):r,o=a===void 0?Error(n):Error(n,{cause:a});return o.name=t,Object.assign(o,i),o}function Hu(e){return typeof e==`object`&&!!e&&typeof e.message==`string`&&typeof e.name==`string`}function Uu(e){return typeof e==`object`&&!!e&&e.type===`static`&&typeof e.path==`string`}function Wu(e){return typeof e==`object`&&!!e&&e.type===`query`&&typeof e.records==`object`&&e.records!==null}function Gu(e){return typeof e==`object`&&!!e&&(`output`in e||`error`in e)}function Ku(e){if(e.error)throw Vu(e.error);return e.output}function qu(e){return e.some(e=>e!=null)}function Ju(e){return typeof e==`object`&&e&&`serialization`in e&&`data`in e?e.data:e}function Yu(e,t){let n=new Map,r=new Map;function i(e,t){return t===`structured-clone`&&Array.isArray(e)?_u(e):e}function a(e,t){return i(Ju(e),t)}async function o(e){n.has(e.path)||n.set(e.path,t(e.path).then(t=>a(t,e.serialization)));let r=await n.get(e.path);return Gu(r)?Ku(r):r}async function s(e,n){return r.has(e)||r.set(e,t(e).then(e=>a(e,n))),await r.get(e)}async function c(t,n){if(!(t in e))throw Error(`[devframe-rpc] Function "${t}" not found in dump store`);let r=e[t];if(Uu(r)){if(qu(n))throw Error(`[devframe-rpc] No dump match for "${t}" with args: ${JSON.stringify(n)}`);return await o(r)}if(Wu(r)){let e=vs(n),i=r.records[e];if(i)return Ku(await s(i,r.serialization));if(r.fallback)return Ku(await s(r.fallback,r.serialization));throw Error(`[devframe-rpc] No dump match for "${t}" with args: ${JSON.stringify(n)}`)}if(!qu(n))return r;throw Error(`[devframe-rpc] No dump match for "${t}" with args: ${JSON.stringify(n)}`)}return{call:async(e,t)=>await c(e,t),callOptional:async(t,n)=>{if(t in e)return await c(t,n)},callEvent:async(e,t)=>{}}}async function Xu(e){let t=Yu(await e.fetchJsonFromBases(ts),e.fetchJsonFromBases);return{transport:`static`,isTrusted:!0,status:`connected`,connectionError:null,requestTrust:async()=>!0,requestTrustWithToken:async()=>!0,requestTrustWithCode:async()=>null,ensureTrusted:async()=>!0,call:(...e)=>t.call(e[0],e.slice(1)),callEvent:(...e)=>t.callEvent(e[0],e.slice(1)),callOptional:(...e)=>t.callOptional(e[0],e.slice(1)),close:()=>{}}}var Zu=256,Qu=class extends Error{name=`StreamClosedError`};function $u(e={}){let t=e.id??Yl(),n=Math.max(0,e.replayWindow??0),r=Ws(),i=new AbortController,a=[],o=!1,s=0;function c(e){if(o)throw new Qu(`Cannot write to a closed stream "${t}"`);s+=1,n>0&&(a.push({seq:s,chunk:e}),a.length>n&&a.splice(0,a.length-n)),r.emit(`chunk`,s,e)}function l(e){if(o)return;o=!0;let t=td(e);i.abort(e),r.emit(`end`,t)}function u(){o||(o=!0,i.signal.aborted||i.abort(`stream closed`),r.emit(`end`,void 0))}function d(e){o||i.signal.aborted||i.abort(e??`aborted`)}let f=new WritableStream({write(e){c(e)},close(){u()},abort(e){l(e)}});return{id:t,signal:i.signal,get closed(){return o},get lastSeq(){return s},write:c,error:l,close:u,abort:d,writable:f,events:r,buffer:a}}function ed(e={}){let t=e.id??Yl(),n=Math.max(1,e.highWaterMark??Zu),r=[],i=0,a=!1,o=!1,s,c,l,u;function d(){if(c){if(r.length>0){let e=r.shift(),t=c;c=void 0,t.resolve({value:e,done:!1});return}if(a){let e=c;if(c=void 0,s){let t=Error(s.message);t.name=s.name,e.reject(t)}else e.resolve({value:void 0,done:!0})}}}function f(){if(l){for(;r.length>0;){let e=r.shift();try{l.enqueue(e)}catch{break}}if(a&&l){try{if(s){let e=Error(s.message);e.name=s.name,l.error(e)}else l.close()}catch{}l=void 0}}}function p(t,s){if(!(a||o)&&!(t<=i)){if(i=t,r.push(s),r.length>n){let t=r.length-n;r.splice(0,t),e.onOverflow?.(t)}d(),u&&f()}}function m(e){a||(a=!0,s=e,d(),u&&f())}function h(){o||a||(o=!0,e.onCancel?.(),m(void 0))}function g(){return u||(u=new ReadableStream({start(e){l=e,f()},cancel(){h()}}),u)}return{id:t,get cancelled(){return o},get done(){return a},get lastSeenSeq(){return i},get readable(){return g()},cancel:h,_push:p,_end:m,[Symbol.asyncIterator](){return{next(){if(r.length>0)return Promise.resolve({value:r.shift(),done:!1});if(a){if(s){let e=Error(s.message);return e.name=s.name,Promise.reject(e)}return Promise.resolve({value:void 0,done:!0})}return new Promise((e,t)=>{c={resolve:e,reject:t}})},return(){return h(),Promise.resolve({value:void 0,done:!0})}}}}}function td(e){if(e instanceof Error)return{name:e.name||`Error`,message:e.message};if(typeof e==`string`)return{name:`Error`,message:e};try{return{name:`Error`,message:JSON.stringify(e)}}catch{return{name:`Error`,message:String(e)}}}var nd=``;function rd(e,t){return`${e}${nd}${t}`}function id(e){let t=new Map,n=new Map;e.client.register({name:X.broadcast.streamingChunk,type:`event`,handler(e,n,r,i){t.get(rd(e,n))?._push(r,i)}}),e.client.register({name:X.broadcast.streamingEnd,type:`event`,handler(e,n,r){let i=rd(e,n),a=t.get(i);a&&(a._end(r),t.delete(i))}}),e.client.register({name:X.broadcast.streamingUploadCancel,type:`event`,handler(e,t){let r=rd(e,t),i=n.get(r);i&&(i.abort(`server cancelled upload`),n.delete(r))}}),e.events.on(X.client.isTrustedUpdated,n=>{if(n)for(let[n,r]of t){if(r.cancelled||r.done)continue;let t=n.indexOf(nd);if(t<0)continue;let i=n.slice(0,t),a=n.slice(t+1);e.callEvent(`devframe:streaming:subscribe`,i,a,{afterSeq:r.lastSeenSeq})}});function r(n,r,i={}){let a=rd(n,r),o=t.get(a);if(o)return o;let s=ed({id:r,highWaterMark:i.highWaterMark,onOverflow(e){console.warn(`[devframe] DF0029: Stream "${n}#${r}" dropped ${e} chunk(s) after exceeding the client high-water mark.`)},onCancel(){e.callEvent(`devframe:streaming:cancel`,n,r),t.delete(a)}});if(t.set(a,s),e.isTrusted)e.callEvent(`devframe:streaming:subscribe`,n,r,{afterSeq:0});else{let i=e.events.on(X.client.isTrustedUpdated,o=>{o&&(i(),t.has(a)&&!s.cancelled&&!s.done&&e.callEvent(`devframe:streaming:subscribe`,n,r,{afterSeq:s.lastSeenSeq}))})}return s}function i(t,r){let i=rd(t,r),a=n.get(i);if(a)return a;let o=$u({id:r});return o.events.on(`chunk`,(n,i)=>{e.callEvent(`devframe:streaming:upload-chunk`,t,r,n,i)}),o.events.on(`end`,a=>{e.callEvent(`devframe:streaming:upload-end`,t,r,a),n.delete(i)}),n.set(i,o),o}return{subscribe:r,upload:i}}function ad(){}var od=new Map;function sd(e){let t=e.url;e.authToken&&(t=`${t}?${is}=${encodeURIComponent(e.authToken)}`);let n=new WebSocket(t),{onConnected:r=ad,onError:i=ad,onDisconnected:a=ad,definitions:o=od}=e;n.addEventListener(`open`,e=>{r(e)}),n.addEventListener(`error`,e=>{let t=e instanceof Error?e:Error(e.type);i(t)}),n.addEventListener(`close`,e=>{a(e)});let s=xu(o);return{close:()=>{n.close()},on:e=>{n.addEventListener(`message`,t=>{e(t.data)})},post:e=>{if(n.readyState===WebSocket.OPEN){n.send(e);return}if(n.readyState===WebSocket.CONNECTING){let t=()=>{i(),n.readyState===WebSocket.OPEN&&n.send(e)},r=()=>i();function i(){n.removeEventListener(`open`,t),n.removeEventListener(`close`,r)}n.addEventListener(`open`,t),n.addEventListener(`close`,r);return}i(Error(`Devframe WebSocket is not open; message dropped`))},serialize:s.serialize,deserialize:s.deserialize}}function cd(e,t,n){let r=(()=>{try{return new URL(t,n.href)}catch{return new URL(n.href)}})(),i=r.protocol===`https:`?`wss:`:`ws:`;if(e&&typeof e==`object`){if(e.host!=null||e.port!=null){let t=e.host??`${r.hostname}:${e.port}`,n=new URL(e.path??`/`,`${i}//${t}`);return n.protocol=i,n.href}let t=new URL(e.path??``,r);return t.protocol=i,t.href}if(typeof e==`number`)return`${i}//${r.hostname}:${e}`;let a=e??``;if(/^wss?:\/\//i.test(a))return a;if(/^https?:\/\//i.test(a))return ic(a,/^https/i.test(a)?`wss://`:`ws://`);let o=new URL(a,r);return o.protocol=i,o.href}function ld(e){let{authToken:t,connectionMeta:n,metaBaseUrl:r,events:i,clientRpc:a,rpcOptions:o={},wsOptions:s={},callTimeout:c=0}=e,l=cd(n.websocket,r??`./`,location);return Ru({transport:`websocket`,authToken:t,connectionMeta:n,events:i,clientRpc:a,rpcOptions:o,callTimeout:c,createChannel:e=>sd({url:l,authToken:t,definitions:e.definitions,...s,onConnected(e){s.onConnected?.(e)},onError(t){e.onError(t),s.onError?.(t)},onDisconnected(t){e.onDisconnected(),s.onDisconnected?.(t)}})})}function ud(e){return e.includes(`:`)}function dd(e,t){return ud(t)?t:`${e}:${t}`}function fd(e,t,n){let r=`devframe:settings:${n}:${t}`,i;function a(){return i||=e.sharedState.get(r,{initialValue:{}}),i}return{async get(e){return(await a()).value()[e]},async set(e,t){(await a()).mutate(n=>{n[e]=t})},async delete(e){(await a()).mutate(t=>{delete t[e]})},async all(){return(await a()).value()},async onChange(e){return(await a()).on(`updated`,t=>e(t))}}}function pd(e,t){return{global:fd(e,t,`global`),project:fd(e,t,`project`)}}function md(e,t){return{namespace:t,base:e,rpc:{namespace:t,register(n){if(ud(n.name))throw Error(`[devframe] Scoped client RPC registration for namespace "${t}" received an already-namespaced function name "${n.name}". Pass a bare name without a ":" separator.`);e.client.register({...n,name:`${t}:${n.name}`})},call:((n,...r)=>e.call(dd(t,n),...r)),callEvent:((n,...r)=>e.callEvent(dd(t,n),...r)),callOptional:((n,...r)=>e.callOptional(dd(t,n),...r)),sharedState:((n,r)=>e.sharedState.get(dd(t,n),r)),streaming:{subscribe:(n,r,i)=>e.streaming.subscribe(dd(t,n),r,i),upload:(n,r)=>e.streaming.upload(dd(t,n),r)}},settings:pd(e,t),scope:e.scope}}function hd(e,t){if(t.backend===`static`)return`static`;let n=t.websocket!==void 0,r=t.sse!==void 0;if(e===`websocket`){if(!n)throw Error(`[devframe] transport: 'websocket' was requested, but this server does not advertise a WebSocket endpoint`);return`websocket`}if(e===`sse`){if(!r)throw Error(`[devframe] transport: 'sse' was requested, but this server does not advertise an SSE endpoint`);return`sse`}if(t.backend===`sse`&&r)return`sse`;if(n)return`websocket`;if(r)return`sse`;throw Error(`[devframe] This server advertises no RPC transport (backend "none"), so there is nothing to connect to. Enable the WebSocket or SSE endpoint on the server, or use its static/MCP surfaces instead.`)}async function gd(e={}){let{baseURL:t=`./`,rpcOptions:n={},cacheOptions:r=!1}=e,i=Ws(),a=Array.isArray(t)?t:[t],o=await gc(e),{connectionMeta:s,metaBaseUrl:c,authToken:l}=o,u=a[0]??`./`;try{u=new URL(`.`,c).href}catch{}let d=new ys({functions:[],...typeof e.cacheOptions==`object`?e.cacheOptions:{}}),f={rpc:void 0},p=new Rs(f);async function m(e){let t=[u,...a.filter(e=>e!==u)].filter(e=>e!=null),n=[];for(let r of t)try{return await fetch(ec(e,r)).then(t=>{if(!t.ok)throw Error(`Failed to fetch ${e} from ${r}: ${t.status}`);return t.json()})}catch(e){n.push(e)}throw Error(`Failed to load ${e} from ${t.join(`, `)}`,{cause:n})}let h={authToken:l,connectionMeta:s,metaBaseUrl:c,events:i,clientRpc:p,callTimeout:e.callTimeout,rpcOptions:{...n,async onRequest(e,t,i){if(await n.onRequest?.call(this,e,t,i),r&&d?.validate(e.m)){if(d.has(e.m,e.a))return i(d.cached(e.m,e.a));let n=await t(e);d.apply(e,n)}else await t(e)}}},g=hd(e.transport??`auto`,s),_=g===`static`?await Xu({fetchJsonFromBases:m}):g===`sse`?Bu({...h,sseOptions:e.sseOptions}):ld({...h,wsOptions:e.wsOptions}),v;try{v=new BroadcastChannel(`devframe-auth`)}catch{}let y,b=!1;function x(e){return((...t)=>b||!y?e(...t):y.then(()=>e(...t)))}let S={events:i,get isTrusted(){return _.isTrusted},get status(){return _.status},get connectionError(){return _.connectionError},get transport(){return _.transport??g},get connection(){return o},connectionMeta:s,ensureTrusted:_.ensureTrusted,requestTrust:_.requestTrust,requestTrustWithToken:async e=>(fc(e),o={...o,authToken:e},_.requestTrustWithToken(e)),requestTrustWithCode:async e=>{let t=await _.requestTrustWithCode(e);if(!t)return!1;fc(t),o={...o,authToken:t};try{v?.postMessage({type:`auth-update`,authToken:t})}catch{}return!0},call:x(_.call),callEvent:x(_.callEvent),callOptional:x(_.callOptional),client:p,sharedState:void 0,services:void 0,streaming:void 0,cacheManager:d,scope:void 0,close:()=>_.close?.()};S.sharedState=$l(S),S.streaming=id(S),S.services=Sc(S);let C=new Map;S.scope=(e=>{if(!e)return S;let t=C.get(e);return t||(t=md(S,e),C.set(e,t)),t}),f.rpc=S;function w(){try{return typeof window<`u`&&window.self===window.top}catch{return!1}}async function ee(){if(!(e.simpleAuth===!1||!w())&&typeof globalThis.prompt==`function`)for(;!S.isTrusted;){let e=globalThis.prompt(`devframe: enter the authentication code shown in your terminal`);if(e==null)return;let t=e.trim();if(t&&await S.requestTrustWithCode(t))return}}async function te(){let t=await _.requestTrust(),n=e.otpParam??`devframe_otp`,r=n?await xc(S,{param:n}):!1;t||r||S.isTrusted||await ee()}return y=te().then(()=>{b=!0},()=>{b=!0}),v&&(v.onmessage=e=>{e.data?.type===`auth-update`&&e.data.authToken&&S.requestTrustWithToken(e.data.authToken)}),S}var _d=gd,vd=`devframes:plugin:code-server:state`;function yd(e){return _d(e)}var bd=Pt({connected:!1,status:`connecting`,error:null,backend:null}),xd=Gt(null);function Sd(e){bd.status=e.status,bd.connected=e.status===`connected`,bd.error=e.connectionError?.message??null}async function Cd(){try{let e=await yd();xd.value=e,bd.backend=e.connectionMeta.backend,Sd(e),e.events.on(`connection:status`,()=>Sd(e)),e.connectionMeta.backend===`websocket`&&e.ensureTrusted(5e3).catch(()=>{})}catch(e){bd.status=`error`,bd.error=e?.message??String(e)}}function wd(){return xd}var Td=`devframes:plugin:code-server:detect`,Ed=`devframes:plugin:code-server:status`,Dd=`devframes:plugin:code-server:start`,Od=`devframes:plugin:code-server:stop`;function kd(){let e=wd(),t=Pt({checked:!1,installed:!1,bin:`code-server`,backend:`code-server`,mode:`local`}),n=Pt({status:`stopped`}),r=Gt(void 0),i=Wt(!1),a=Y(()=>n.status===`running`?r.value?`running`:`starting`:n.status===`starting`||i.value&&n.status!==`error`?`starting`:t.checked?t.installed?`launch`:`not-installed`:`connecting`);function o(e){e&&(Object.assign(t,e.detection),Object.assign(n,e.server),e.connect&&(r.value=e.connect))}async function s(t,...r){let i=e.value;if(i)try{return await i.call(t,...r)}catch(e){n.status=`error`,n.error=e instanceof Error?e.message:String(e);return}}async function c(){if(!i.value){i.value=!0;try{o(await s(Dd,{}))}finally{i.value=!1}}}async function l(){if(!i.value){i.value=!0;try{o(await s(Od)),r.value=void 0}finally{i.value=!1}}}async function u(){if(!i.value){i.value=!0;try{await s(Td)}finally{i.value=!1}}}async function d(){o(await s(Ed));let i=e.value;if(!i)return;let a=await i.sharedState.get(vd,{initialValue:{detection:t,server:n}}),c=a.value();Object.assign(t,c.detection),Object.assign(n,c.server);let l=a.on(`updated`,e=>{Object.assign(t,e.detection),Object.assign(n,e.server),n.status===`running`&&!r.value&&s(Ed).then(e=>{e?.connect&&(r.value=e.connect)}),n.status!==`running`&&(r.value=void 0)});Ee(()=>l?.())}return{detection:t,server:n,connect:r,busy:i,phase:a,launch:c,stop:l,recheck:u,bootstrap:d}}var Ad={class:`relative h-full w-full of-hidden bg-base color-base`},jd=Un({__name:`App`,setup(e,{expose:t}){let{detection:n,server:r,connect:i,busy:a,phase:o,launch:s,stop:c,recheck:l,bootstrap:u}=kd(),d=Y(()=>!!i.value);return ir(async()=>{await Cd(),await u()}),t({stop:c}),(e,t)=>(W(),G(`div`,Ad,[d.value?Dn((W(),Bi(wo,{key:0,connect:L(i),port:L(r).port},null,8,[`connect`,`port`])),[[Pa,L(o)===`running`]]):Xi(``,!0),L(o)===`running`?Xi(``,!0):(W(),Bi(Zo,{key:1,phase:L(o),detection:L(n),server:L(r),busy:L(a),onLaunch:L(s),onRecheck:L(l)},null,8,[`phase`,`detection`,`server`,`busy`,`onLaunch`,`onRecheck`])),q(Co,{status:L(bd).status,error:L(bd).error},null,8,[`status`,`error`])]))}}),Md=window.matchMedia(`(prefers-color-scheme: dark)`);function Nd(e){document.documentElement.classList.toggle(`dark`,e),document.documentElement.classList.toggle(`light`,!e)}Nd(Md.matches),Md.addEventListener(`change`,e=>Nd(e.matches)),po(jd).mount(`#app`);
package/dist/index.html CHANGED
@@ -5,7 +5,7 @@
5
5
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
6
6
  <base href="./" />
7
7
  <title>Code Server</title>
8
- <script type="module" crossorigin src="./assets/index--q02GrCE.js"></script>
8
+ <script type="module" crossorigin src="./assets/index-CGeoJ6ut.js"></script>
9
9
  <link rel="stylesheet" crossorigin href="./assets/index-D1CpHvIy.css">
10
10
  </head>
11
11
  <body>
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@devframes/plugin-code-server--assets",
3
3
  "type": "module",
4
- "version": "0.9.8",
4
+ "version": "0.9.9",
5
5
  "description": "Prebuilt browser assets (SPA) for @devframes/plugin-code-server, served on demand through devframe's remote-assets back-proxy.",
6
6
  "author": "Anthony Fu <anthonyfu117@hotmail.com>",
7
7
  "license": "MIT",
@@ -1,3 +0,0 @@
1
- (function(){let e=document.createElement(`link`).relList;if(e&&e.supports&&e.supports(`modulepreload`))return;for(let e of document.querySelectorAll(`link[rel="modulepreload"]`))n(e);new MutationObserver(e=>{for(let t of e)if(t.type===`childList`)for(let e of t.addedNodes)e.tagName===`LINK`&&e.rel===`modulepreload`&&n(e)}).observe(document,{childList:!0,subtree:!0});function t(e){let t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),t.credentials=e.crossOrigin===`use-credentials`?`include`:e.crossOrigin===`anonymous`?`omit`:`same-origin`,t}function n(e){if(e.ep)return;e.ep=!0;let n=t(e);fetch(e.href,n)}})();function e(e){let t=Object.create(null);for(let n of e.split(`,`))t[n]=1;return e=>e in t}var t={},n=[],r=()=>{},i=()=>!1,a=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),o=e=>e.startsWith(`onUpdate:`),s=Object.assign,c=(e,t)=>{let n=e.indexOf(t);n>-1&&e.splice(n,1)},l=Object.prototype.hasOwnProperty,u=(e,t)=>l.call(e,t),d=Array.isArray,f=e=>x(e)===`[object Map]`,p=e=>x(e)===`[object Set]`,m=e=>x(e)===`[object Date]`,h=e=>typeof e==`function`,g=e=>typeof e==`string`,_=e=>typeof e==`symbol`,v=e=>typeof e==`object`&&!!e,y=e=>(v(e)||h(e))&&h(e.then)&&h(e.catch),b=Object.prototype.toString,x=e=>b.call(e),S=e=>x(e).slice(8,-1),C=e=>x(e)===`[object Object]`,w=e=>g(e)&&e!==`NaN`&&e[0]!==`-`&&``+parseInt(e,10)===e,ee=e(`,key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted`),te=e=>{let t=Object.create(null);return(n=>t[n]||(t[n]=e(n)))},ne=/-\w/g,T=te(e=>e.replace(ne,e=>e.slice(1).toUpperCase())),re=/\B([A-Z])/g,E=te(e=>e.replace(re,`-$1`).toLowerCase()),ie=te(e=>e.charAt(0).toUpperCase()+e.slice(1)),ae=te(e=>e?`on${ie(e)}`:``),D=(e,t)=>!Object.is(e,t),oe=(e,...t)=>{for(let n=0;n<e.length;n++)e[n](...t)},O=(e,t,n,r=!1)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:r,value:n})},se=e=>{let t=parseFloat(e);return isNaN(t)?e:t},ce,le=()=>ce||=typeof globalThis<`u`?globalThis:typeof self<`u`?self:typeof window<`u`?window:typeof global<`u`?global:{};function ue(e){if(d(e)){let t={};for(let n=0;n<e.length;n++){let r=e[n],i=g(r)?me(r):ue(r);if(i)for(let e in i)t[e]=i[e]}return t}if(g(e)||v(e))return e}var de=/;(?![^(]*\))/g,fe=/:([^]+)/,pe=/\/\*[^]*?\*\//g;function me(e){let t={};return e.replace(pe,``).split(de).forEach(e=>{if(e){let n=e.split(fe);n.length>1&&(t[n[0].trim()]=n[1].trim())}}),t}function k(e){let t=``;if(g(e))t=e;else if(d(e))for(let n=0;n<e.length;n++){let r=k(e[n]);r&&(t+=r+` `)}else if(v(e))for(let n in e)e[n]&&(t+=n+` `);return t.trim()}var he=`itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`,ge=e(he);he+``;function _e(e){return!!e||e===``}function ve(e,t){if(e.length!==t.length)return!1;let n=!0;for(let r=0;n&&r<e.length;r++)n=be(e[r],t[r]);return n}function ye(e,t){if(e.size!==t.size)return!1;let n=Array.from(t),r=new Uint8Array(n.length);for(let t of e){let e=-1;for(let i=0;i<n.length;i++)if(!r[i]&&be(t,n[i])){e=i;break}if(e<0)return!1;r[e]=1}return!0}function be(e,t){if(e===t)return!0;let n=m(e),r=m(t);if(n||r)return n&&r?e.getTime()===t.getTime():!1;if(n=_(e),r=_(t),n||r)return e===t;if(n=d(e),r=d(t),n||r)return n&&r?ve(e,t):!1;if(n=v(e),r=v(t),n||r){if(!n||!r)return!1;if(n=f(e),r=f(t),n||r||(n=p(e),r=p(t),n||r))return n&&r?ye(e,t):!1;if(Object.keys(e).length!==Object.keys(t).length)return!1;for(let n in e){let r=e.hasOwnProperty(n),i=t.hasOwnProperty(n);if(r&&!i||!r&&i||!be(e[n],t[n]))return!1}}return String(e)===String(t)}var xe=e=>!!(e&&e.__v_isRef===!0),A=e=>g(e)?e:e==null?``:d(e)||v(e)&&(e.toString===b||!h(e.toString))?xe(e)?A(e.value):JSON.stringify(e,Se,2):String(e),Se=(e,t)=>xe(t)?Se(e,t.value):f(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((e,[t,n],r)=>(e[Ce(t,r)+` =>`]=n,e),{})}:p(t)?{[`Set(${t.size})`]:[...t.values()].map(e=>Ce(e))}:_(t)?Ce(t):v(t)&&!d(t)&&!C(t)?String(t):t,Ce=(e,t=``)=>_(e)?`Symbol(${e.description??t})`:e,j,we=class{constructor(e=!1){this.detached=e,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this._warnOnRun=!0,this.__v_skip=!0,!e&&j&&(j.active?(this.parent=j,this.index=(j.scopes||(j.scopes=[])).push(this)-1):(this._active=!1,this._warnOnRun=!1))}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let e,t;if(this.scopes){let n=this.scopes.slice();for(e=0,t=n.length;e<t;e++)n[e].pause()}for(e=0,t=this.effects.length;e<t;e++)this.effects[e].pause()}}resume(){if(this._active&&this._isPaused){this._isPaused=!1;let e,t;if(this.scopes){let n=this.scopes.slice();for(e=0,t=n.length;e<t;e++)n[e].resume()}let n=this.effects.slice();for(e=0,t=n.length;e<t;e++)n[e].resume()}}run(e){if(this._active){let t=j;try{return j=this,e()}finally{j=t}}}on(){++this._on===1&&(this.prevScope=j,j=this)}off(){if(this._on>0&&--this._on===0){if(j===this)j=this.prevScope;else{let e=j;for(;e;){if(e.prevScope===this){e.prevScope=this.prevScope;break}e=e.prevScope}}this.prevScope=void 0}}stop(e){if(this._active){this._active=!1;let t,n;for(t=0,n=this.effects.length;t<n;t++)this.effects[t].stop();for(this.effects.length=0,t=0,n=this.cleanups.length;t<n;t++)this.cleanups[t]();if(this.cleanups.length=0,this.scopes){let e=this.scopes.slice();for(t=0,n=e.length;t<n;t++)e[t].stop(!0);this.scopes.length=0}if(!this.detached&&this.parent&&!e){let e=this.parent.scopes.pop();e&&e!==this&&(this.parent.scopes[this.index]=e,e.index=this.index)}this.parent=void 0}}};function Te(){return j}function Ee(e,t=!1){j&&j.cleanups.push(e)}var M,De=new WeakSet,Oe=class{constructor(e){this.fn=e,this.deps=void 0,this.depsTail=void 0,this.flags=5,this.next=void 0,this.cleanup=void 0,this.scheduler=void 0,j&&(j.active?j.effects.push(this):this.flags&=-2)}pause(){this.flags|=64}resume(){this.flags&64&&(this.flags&=-65,De.has(this)&&(De.delete(this),this.trigger()))}notify(){this.flags&2&&!(this.flags&32)||this.flags&8||Me(this)}run(){if(!(this.flags&1))return this.fn();this.flags|=2,Ge(this),Fe(this);let e=M,t=Ve;M=this,Ve=!0;try{return this.fn()}finally{Ie(this),M=e,Ve=t,this.flags&=-3}}stop(){if(this.flags&1){for(let e=this.deps;e;e=e.nextDep)ze(e);this.deps=this.depsTail=void 0,Ge(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){this.flags&64?De.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){Le(this)&&this.run()}get dirty(){return Le(this)}},ke=0,Ae,je;function Me(e,t=!1){if(e.flags|=8,t){e.next=je,je=e;return}e.next=Ae,Ae=e}function Ne(){ke++}function Pe(){if(--ke>0)return;if(je){let e=je;for(je=void 0;e;){let t=e.next;e.next=void 0,e.flags&=-9,e=t}}let e;for(;Ae;){let t=Ae;for(Ae=void 0;t;){let n=t.next;if(t.next=void 0,t.flags&=-9,t.flags&1)try{t.trigger()}catch(t){e||=t}t=n}}if(e)throw e}function Fe(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function Ie(e){let t,n=e.depsTail,r=n;for(;r;){let e=r.prevDep;r.version===-1?(r===n&&(n=e),ze(r),Be(r)):t=r,r.dep.activeLink=r.prevActiveLink,r.prevActiveLink=void 0,r=e}e.deps=t,e.depsTail=n}function Le(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(Re(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function Re(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===Ke)||(e.globalVersion=Ke,!e.isSSR&&e.flags&128&&(!e.deps&&!e._dirty||!Le(e))))return;e.flags|=2;let t=e.dep,n=M,r=Ve;M=e,Ve=!0;try{Fe(e);let n=e.fn(e._value);(t.version===0||D(n,e._value))&&(e.flags|=128,e._value=n,t.version++)}catch(e){throw t.version++,e}finally{M=n,Ve=r,Ie(e),e.flags&=-3}}function ze(e,t=!1){let{dep:n,prevSub:r,nextSub:i}=e;if(r&&(r.nextSub=i,e.prevSub=void 0),i&&(i.prevSub=r,e.nextSub=void 0),n.subs===e&&(n.subs=r,!r&&n.computed)){n.computed.flags&=-5;for(let e=n.computed.deps;e;e=e.nextDep)ze(e,!0)}!t&&!--n.sc&&n.map&&n.map.delete(n.key)}function Be(e){let{prevDep:t,nextDep:n}=e;t&&(t.nextDep=n,e.prevDep=void 0),n&&(n.prevDep=t,e.nextDep=void 0)}var Ve=!0,He=[];function Ue(){He.push(Ve),Ve=!1}function We(){let e=He.pop();Ve=e===void 0||e}function Ge(e){let{cleanup:t}=e;if(e.cleanup=void 0,t){let e=M;M=void 0;try{t()}finally{M=e}}}var Ke=0,qe=class{constructor(e,t){this.sub=e,this.dep=t,this.version=t.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}},Je=class{constructor(e){this.computed=e,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(e){if(!M||!Ve||M===this.computed)return;let t=this.activeLink;if(t===void 0||t.sub!==M)t=this.activeLink=new qe(M,this),M.deps?(t.prevDep=M.depsTail,M.depsTail.nextDep=t,M.depsTail=t):M.deps=M.depsTail=t,Ye(t);else if(t.version===-1&&(t.version=this.version,t.nextDep)){let e=t.nextDep;e.prevDep=t.prevDep,t.prevDep&&(t.prevDep.nextDep=e),t.prevDep=M.depsTail,t.nextDep=void 0,M.depsTail.nextDep=t,M.depsTail=t,M.deps===t&&(M.deps=e)}return t}trigger(e){this.version++,Ke++,this.notify(e)}notify(e){Ne();try{for(let e=this.subs;e;e=e.prevSub)e.sub.notify()&&e.sub.dep.notify()}finally{Pe()}}};function Ye(e){if(e.dep.sc++,e.sub.flags&4){let t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let e=t.deps;e;e=e.nextDep)Ye(e)}let n=e.dep.subs;n!==e&&(e.prevSub=n,n&&(n.nextSub=e)),e.dep.subs=e}}var Xe=new WeakMap,Ze=Symbol(``),Qe=Symbol(``),$e=Symbol(``);function N(e,t,n){if(Ve&&M){let t=Xe.get(e);t||Xe.set(e,t=new Map);let r=t.get(n);r||(t.set(n,r=new Je),r.map=t,r.key=n),r.track()}}function et(e,t,n,r,i,a){let o=Xe.get(e);if(!o){Ke++;return}let s=e=>{e&&e.trigger()};if(Ne(),t===`clear`)o.forEach(s);else{let i=d(e),a=i&&w(n);if(i&&n===`length`){let e=Number(r);o.forEach((t,n)=>{(n===`length`||n===$e||!_(n)&&n>=e)&&s(t)})}else switch((n!==void 0||o.has(void 0))&&s(o.get(n)),a&&s(o.get($e)),t){case`add`:i?a&&s(o.get(`length`)):(s(o.get(Ze)),f(e)&&s(o.get(Qe)));break;case`delete`:i||(s(o.get(Ze)),f(e)&&s(o.get(Qe)));break;case`set`:f(e)&&s(o.get(Ze))}}Pe()}function tt(e){let t=P(e);return t===e?t:(N(t,`iterate`,$e),Bt(e)?t:t.map(Ut))}function nt(e){return N(e=P(e),`iterate`,$e),e}function rt(e,t){return zt(e)?Wt(Rt(e)?Ut(t):t):Ut(t)}var it={__proto__:null,[Symbol.iterator](){return at(this,Symbol.iterator,e=>rt(this,e))},concat(...e){return tt(this).concat(...e.map(e=>d(e)?tt(e):e))},entries(){return at(this,`entries`,e=>(e[1]=rt(this,e[1]),e))},every(e,t){return st(this,`every`,e,t,void 0,arguments)},filter(e,t){return st(this,`filter`,e,t,e=>e.map(e=>rt(this,e)),arguments)},find(e,t){return st(this,`find`,e,t,e=>rt(this,e),arguments)},findIndex(e,t){return st(this,`findIndex`,e,t,void 0,arguments)},findLast(e,t){return st(this,`findLast`,e,t,e=>rt(this,e),arguments)},findLastIndex(e,t){return st(this,`findLastIndex`,e,t,void 0,arguments)},forEach(e,t){return st(this,`forEach`,e,t,void 0,arguments)},includes(...e){return lt(this,`includes`,e)},indexOf(...e){return lt(this,`indexOf`,e)},join(e){return tt(this).join(e)},lastIndexOf(...e){return lt(this,`lastIndexOf`,e)},map(e,t){return st(this,`map`,e,t,void 0,arguments)},pop(){return ut(this,`pop`)},push(...e){return ut(this,`push`,e)},reduce(e,...t){return ct(this,`reduce`,e,t)},reduceRight(e,...t){return ct(this,`reduceRight`,e,t)},shift(){return ut(this,`shift`)},some(e,t){return st(this,`some`,e,t,void 0,arguments)},splice(...e){return ut(this,`splice`,e)},toReversed(){return tt(this).toReversed()},toSorted(e){return tt(this).toSorted(e)},toSpliced(...e){return tt(this).toSpliced(...e)},unshift(...e){return ut(this,`unshift`,e)},values(){return at(this,`values`,e=>rt(this,e))}};function at(e,t,n){let r=nt(e),i=r[t]();return r!==e&&!Bt(e)&&(i._next=i.next,i.next=()=>{let e=i._next();return e.done||(e.value=n(e.value)),e}),i}var ot=Array.prototype;function st(e,t,n,r,i,a){let o=nt(e),s=o!==e&&!Bt(e),c=o[t];if(c!==ot[t]){let t=c.apply(e,a);return s?Ut(t):t}let l=n;o!==e&&(s?l=function(t,r){return n.call(this,rt(e,t),r,e)}:n.length>2&&(l=function(t,r){return n.call(this,t,r,e)}));let u=c.call(o,l,r);return s&&i?i(u):u}function ct(e,t,n,r){let i=nt(e),a=i!==e&&!Bt(e),o=n,s=!1;i!==e&&(a?(s=r.length===0,o=function(t,r,i){return s&&(s=!1,t=rt(e,t)),n.call(this,t,rt(e,r),i,e)}):n.length>3&&(o=function(t,r,i){return n.call(this,t,r,i,e)}));let c=i[t](o,...r);return s?rt(e,c):c}function lt(e,t,n){let r=P(e);N(r,`iterate`,$e);let i=r[t](...n);return(i===-1||i===!1)&&Vt(n[0])?(n[0]=P(n[0]),r[t](...n)):i}function ut(e,t,n=[]){Ue(),Ne();let r=P(e)[t].apply(e,n);return Pe(),We(),r}var dt=e(`__proto__,__v_isRef,__isVue`),ft=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!==`arguments`&&e!==`caller`).map(e=>Symbol[e]).filter(_));function pt(e){_(e)||(e=String(e));let t=P(this);return N(t,`has`,e),t.hasOwnProperty(e)}var mt=class{constructor(e=!1,t=!1){this._isReadonly=e,this._isShallow=t}get(e,t,n){if(t===`__v_skip`)return e.__v_skip;let r=this._isReadonly,i=this._isShallow;if(t===`__v_isReactive`)return!r;if(t===`__v_isReadonly`)return r;if(t===`__v_isShallow`)return i;if(t===`__v_raw`)return n===(r?i?Mt:jt:i?At:kt).get(e)||Object.getPrototypeOf(e)===Object.getPrototypeOf(n)?e:void 0;let a=d(e);if(!r){let e;if(a&&(e=it[t]))return e;if(t===`hasOwnProperty`)return pt}let o=Reflect.get(e,t,F(e)?e:n);if((_(t)?ft.has(t):dt(t))||(r||N(e,`get`,t),i))return o;if(F(o)){let e=a&&w(t)?o:o.value;return r&&v(e)?It(e):e}return v(o)?r?It(o):Pt(o):o}},ht=class extends mt{constructor(e=!1){super(!1,e)}set(e,t,n,r){let i=e[t],a=d(e)&&w(t);if(!this._isShallow){let e=zt(i);if(!Bt(n)&&!zt(n)&&(i=P(i),n=P(n)),!a&&F(i)&&!F(n))return e||(i.value=n),!0}let o=a?Number(t)<e.length:u(e,t),s=Reflect.set(e,t,n,F(e)?e:r);return e===P(r)&&s&&(o?D(n,i)&&et(e,`set`,t,n,i):et(e,`add`,t,n)),s}deleteProperty(e,t){let n=u(e,t),r=e[t],i=Reflect.deleteProperty(e,t);return i&&n&&et(e,`delete`,t,void 0,r),i}has(e,t){let n=Reflect.has(e,t);return(!_(t)||!ft.has(t))&&N(e,`has`,t),n}ownKeys(e){return N(e,`iterate`,d(e)?`length`:Ze),Reflect.ownKeys(e)}},gt=class extends mt{constructor(e=!1){super(!0,e)}set(e,t){return!0}deleteProperty(e,t){return!0}},_t=new ht,vt=new gt,yt=new ht(!0),bt=e=>e,xt=e=>Reflect.getPrototypeOf(e);function St(e,t,n){return function(...r){let i=this.__v_raw,a=P(i),o=f(a),c=e===`entries`||e===Symbol.iterator&&o,l=e===`keys`&&o,u=i[e](...r),d=n?bt:t?Wt:Ut;return!t&&N(a,`iterate`,l?Qe:Ze),s(Object.create(u),{next(){let{value:e,done:t}=u.next();return t?{value:e,done:t}:{value:c?[d(e[0]),d(e[1])]:d(e),done:t}}})}}function Ct(e){return function(...t){return e===`delete`?!1:e===`clear`?void 0:this}}function wt(e,t){let n={get(n){let r=this.__v_raw,i=P(r),a=P(n);e||(D(n,a)&&N(i,`get`,n),N(i,`get`,a));let{has:o}=xt(i),s=t?bt:e?Wt:Ut;if(o.call(i,n))return s(r.get(n));if(o.call(i,a))return s(r.get(a));r!==i&&r.get(n)},get size(){let t=this.__v_raw;return!e&&N(P(t),`iterate`,Ze),t.size},has(t){let n=this.__v_raw,r=P(n),i=P(t);return e||(D(t,i)&&N(r,`has`,t),N(r,`has`,i)),t===i?n.has(t):n.has(t)||n.has(i)},forEach(n,r){let i=this,a=i.__v_raw,o=P(a),s=t?bt:e?Wt:Ut;return!e&&N(o,`iterate`,Ze),a.forEach((e,t)=>n.call(r,s(e),s(t),i))}};return s(n,e?{add:Ct(`add`),set:Ct(`set`),delete:Ct(`delete`),clear:Ct(`clear`)}:{add(e){let n=P(this),r=xt(n),i=P(e),a=!t&&!Bt(e)&&!zt(e)?i:e;return r.has.call(n,a)||D(e,a)&&r.has.call(n,e)||D(i,a)&&r.has.call(n,i)||(n.add(a),et(n,`add`,a,a)),this},set(e,n){!t&&!Bt(n)&&!zt(n)&&(n=P(n));let r=P(this),{has:i,get:a}=xt(r),o=i.call(r,e);o||=(e=P(e),i.call(r,e));let s=a.call(r,e);return r.set(e,n),o?D(n,s)&&et(r,`set`,e,n,s):et(r,`add`,e,n),this},delete(e){let t=P(this),{has:n,get:r}=xt(t),i=n.call(t,e);i||=(e=P(e),n.call(t,e));let a=r?r.call(t,e):void 0,o=t.delete(e);return i&&et(t,`delete`,e,void 0,a),o},clear(){let e=P(this),t=e.size!==0,n=e.clear();return t&&et(e,`clear`,void 0,void 0,void 0),n}}),[`keys`,`values`,`entries`,Symbol.iterator].forEach(r=>{n[r]=St(r,e,t)}),n}function Tt(e,t){let n=wt(e,t);return(t,r,i)=>r===`__v_isReactive`?!e:r===`__v_isReadonly`?e:r===`__v_raw`?t:Reflect.get(u(n,r)&&r in t?n:t,r,i)}var Et={get:Tt(!1,!1)},Dt={get:Tt(!1,!0)},Ot={get:Tt(!0,!1)},kt=new WeakMap,At=new WeakMap,jt=new WeakMap,Mt=new WeakMap;function Nt(e){switch(e){case`Object`:case`Array`:return 1;case`Map`:case`Set`:case`WeakMap`:case`WeakSet`:return 2;default:return 0}}function Pt(e){return zt(e)?e:Lt(e,!1,_t,Et,kt)}function Ft(e){return Lt(e,!1,yt,Dt,At)}function It(e){return Lt(e,!0,vt,Ot,jt)}function Lt(e,t,n,r,i){if(!v(e)||e.__v_raw&&!(t&&e.__v_isReactive)||e.__v_skip||!Object.isExtensible(e))return e;let a=i.get(e);if(a)return a;let o=Nt(S(e));if(o===0)return e;let s=new Proxy(e,o===2?r:n);return i.set(e,s),s}function Rt(e){return zt(e)?Rt(e.__v_raw):!!(e&&e.__v_isReactive)}function zt(e){return!!(e&&e.__v_isReadonly)}function Bt(e){return!!(e&&e.__v_isShallow)}function Vt(e){return e?!!e.__v_raw:!1}function P(e){let t=e&&e.__v_raw;return t?P(t):e}function Ht(e){return!u(e,`__v_skip`)&&Object.isExtensible(e)&&O(e,`__v_skip`,!0),e}var Ut=e=>v(e)?Pt(e):e,Wt=e=>v(e)?It(e):e;function F(e){return e?e.__v_isRef===!0:!1}function Gt(e){return qt(e,!1)}function Kt(e){return qt(e,!0)}function qt(e,t){return F(e)?e:new Jt(e,t)}var Jt=class{constructor(e,t){this.dep=new Je,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=t?e:P(e),this._value=t?e:Ut(e),this.__v_isShallow=t}get value(){return this.dep.track(),this._value}set value(e){let t=this._rawValue,n=this.__v_isShallow||Bt(e)||zt(e);e=n?e:P(e),D(e,t)&&(this._rawValue=e,this._value=n?e:Ut(e),this.dep.trigger())}};function I(e){return F(e)?e.value:e}var Yt={get:(e,t,n)=>t===`__v_raw`?e:I(Reflect.get(e,t,n)),set:(e,t,n,r)=>{let i=e[t];return F(i)&&!F(n)?(i.value=n,!0):Reflect.set(e,t,n,r)}};function Xt(e){return Rt(e)?e:new Proxy(e,Yt)}var Zt=class{constructor(e,t,n){this.fn=e,this.setter=t,this._value=void 0,this.dep=new Je(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=Ke-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!t,this.isSSR=n}notify(){if(this.flags|=16,!(this.flags&8)&&M!==this)return Me(this,!0),!0}get value(){let e=this.dep.track();return Re(this),e&&(e.version=this.dep.version),this._value}set value(e){this.setter&&this.setter(e)}};function Qt(e,t,n=!1){let r,i;return h(e)?r=e:(r=e.get,i=e.set),new Zt(r,i,n)}var $t={},en=new WeakMap,tn=void 0;function nn(e,t=!1,n=tn){if(n){let t=en.get(n);t||en.set(n,t=[]),t.push(e)}}function rn(e,n,i=t){let{immediate:a,deep:o,once:s,scheduler:l,augmentJob:u,call:f}=i,p=e=>o?e:Bt(e)||o===!1||o===0?an(e,1):an(e),m,g,_,v,y=!1,b=!1;if(F(e)?(g=()=>e.value,y=Bt(e)):Rt(e)?(g=()=>p(e),y=!0):d(e)?(b=!0,y=e.some(e=>Rt(e)||Bt(e)),g=()=>e.map(e=>{if(F(e))return e.value;if(Rt(e))return p(e);if(h(e))return f?f(e,2):e()})):g=h(e)?n?f?()=>f(e,2):e:()=>{if(_){Ue();try{_()}finally{We()}}let t=tn;tn=m;try{return f?f(e,3,[v]):e(v)}finally{tn=t}}:r,n&&o){let e=g,t=o===!0?1/0:o;g=()=>an(e(),t)}let x=Te(),S=()=>{m.stop(),x&&x.active&&c(x.effects,m)};if(s&&n){let e=n;n=(...t)=>{let n=e(...t);return S(),n}}let C=b?Array(e.length).fill($t):$t,w=e=>{if(!(!(m.flags&1)||!m.dirty&&!e)){if(n){let t=m.run();if(e||o||y||(b?t.some((e,t)=>D(e,C[t])):D(t,C))){_&&_();let e=tn;tn=m;try{let e=[t,C===$t?void 0:b&&C[0]===$t?[]:C,v];C=t,f?f(n,3,e):n(...e)}finally{tn=e}}}else m.run()}};return u&&u(w),m=new Oe(g),m.scheduler=l?()=>l(w,!1):w,v=e=>nn(e,!1,m),_=m.onStop=()=>{let e=en.get(m);if(e){if(f)f(e,4);else for(let t of e)t();en.delete(m)}},n?a?w(!0):C=m.run():l?l(w.bind(null,!0),!0):m.run(),S.pause=m.pause.bind(m),S.resume=m.resume.bind(m),S.stop=S,S}function an(e,t=1/0,n){if(t<=0||!v(e)||e.__v_skip||(n||=new Map,(n.get(e)||0)>=t))return e;if(n.set(e,t),t--,F(e))an(e.value,t,n);else if(d(e))for(let r=0;r<e.length;r++)an(e[r],t,n);else if(p(e)||f(e))e.forEach(e=>{an(e,t,n)});else if(C(e)){for(let r in e)an(e[r],t,n);for(let r of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,r)&&an(e[r],t,n)}return e}function on(e,t,n,r){try{return r?e(...r):e()}catch(e){cn(e,t,n)}}function sn(e,t,n,r){if(h(e)){let i=on(e,t,n,r);return i&&y(i)&&i.catch(e=>{cn(e,t,n)}),i}if(d(e)){let i=[];for(let a=0;a<e.length;a++)i.push(sn(e[a],t,n,r));return i}}function cn(e,n,r,i=!0){let a=n?n.vnode:null,{errorHandler:o,throwUnhandledErrorInProduction:s}=n&&n.appContext.config||t;if(n){let t=n.parent,i=n.proxy,a=`https://vuejs.org/error-reference/#runtime-${r}`;for(;t;){let n=t.ec;if(n){for(let t=0;t<n.length;t++)if(n[t](e,i,a)===!1)return}t=t.parent}if(o){Ue(),on(o,null,10,[e,i,a]),We();return}}ln(e,r,a,i,s)}function ln(e,t,n,r=!0,i=!1){if(i)throw e;console.error(e)}var L=[],un=-1,dn=[],fn=null,pn=0,mn=Promise.resolve(),hn=null;function gn(e){let t=hn||mn;return e?t.then(this?e.bind(this):e):t}function _n(e){let t=un+1,n=L.length;for(;t<n;){let r=t+n>>>1,i=L[r],a=Cn(i);a<e||a===e&&i.flags&2?t=r+1:n=r}return t}function vn(e){if(!(e.flags&1)){let t=Cn(e),n=L[L.length-1];!n||!(e.flags&2)&&t>=Cn(n)?L.push(e):L.splice(_n(t),0,e),e.flags|=1,yn()}}function yn(){hn||=mn.then(wn)}function bn(e){if(!d(e))fn&&e.id===-1?fn.splice(pn+1,0,e):e.flags&1||(dn.push(e),e.flags|=1);else for(let t=0;t<e.length;t++)dn.push(e[t]);yn()}function xn(e,t,n=un+1){for(;n<L.length;n++){let t=L[n];if(t&&t.flags&2){if(e&&t.id!==e.uid)continue;L.splice(n,1),n--,t.flags&4&&(t.flags&=-2),t(),t.flags&4||(t.flags&=-2)}}}function Sn(e){if(dn.length){let e=[...new Set(dn)].sort((e,t)=>Cn(e)-Cn(t));if(dn.length=0,fn){for(let t=0;t<e.length;t++)fn.push(e[t]);return}for(fn=e,pn=0;pn<fn.length;pn++){let e=fn[pn];e.flags&4&&(e.flags&=-2),e.flags&8||e(),e.flags&=-2}fn=null,pn=0}}var Cn=e=>e.id==null?e.flags&2?-1:1/0:e.id;function wn(e){try{for(un=0;un<L.length;un++){let e=L[un];e&&!(e.flags&8)&&(e.flags&4&&(e.flags&=-2),on(e,e.i,e.i?15:14),e.flags&4||(e.flags&=-2))}}finally{for(;un<L.length;un++){let e=L[un];e&&(e.flags&=-2)}un=-1,L.length=0,Sn(e),hn=null,(L.length||dn.length)&&wn(e)}}var R=null,Tn=null;function En(e){let t=R;return R=e,Tn=e&&e.type.__scopeId||null,t}function Dn(e,t=R,n){if(!t||e._n)return e;let r=(...n)=>{r._d&&zi(-1);let i=En(t),a=Ii.length,o;try{o=e(...n)}finally{for(let e=Ii.length;e>a;e--)Li();En(i),r._d&&zi(1)}return o};return r._n=!0,r._c=!0,r._d=!0,r}function On(e,n){if(R===null)return e;let r=va(R),i=e.dirs||=[];for(let e=0;e<n.length;e++){let[a,o,s,c=t]=n[e];a&&(h(a)&&(a={mounted:a,updated:a}),a.deep&&an(o),i.push({dir:a,instance:r,value:o,oldValue:void 0,arg:s,modifiers:c}))}return e}function kn(e,t,n,r){let i=e.dirs,a=t&&t.dirs;for(let o=0;o<i.length;o++){let s=i[o];a&&(s.oldValue=a[o].value);let c=s.dir[r];c&&(Ue(),sn(c,n,8,[e.el,s,e,t]),We())}}function An(e,t){if(J){let n=J.provides,r=J.parent&&J.parent.provides;r===n&&(n=J.provides=Object.create(r)),n[e]=t}}function jn(e,t,n=!1){let r=aa();if(r||Wr){let i=Wr?Wr._context.provides:r?r.parent==null||r.ce?r.vnode.appContext&&r.vnode.appContext.provides:r.parent.provides:void 0;if(i&&e in i)return i[e];if(arguments.length>1)return n&&h(t)?t.call(r&&r.proxy):t}}var Mn=Symbol.for(`v-scx`),Nn=()=>jn(Mn);function Pn(e,t,n){return Fn(e,t,n)}function Fn(e,n,i=t){let{immediate:a,deep:o,flush:c,once:l}=i,u=s({},i),d=n&&a||!n&&c!==`post`,f;if(da){if(c===`sync`){let e=Nn();f=e.__watcherHandles||=[]}else if(!d){let e=()=>{};return e.stop=r,e.resume=r,e.pause=r,e}}let p=J;u.call=(e,t,n)=>sn(e,p,t,n);let m=!1;c===`post`?u.scheduler=e=>{B(e,p&&p.suspense)}:c!==`sync`&&(m=!0,u.scheduler=(e,t)=>{t?e():vn(e)}),u.augmentJob=e=>{n&&(e.flags|=4),m&&(e.flags|=2,p&&(e.id=p.uid,e.i=p))};let h=rn(e,n,u);return da&&(f?f.push(h):d&&h()),h}function In(e,t,n){let r=this.proxy,i=g(e)?e.includes(`.`)?Ln(r,e):()=>r[e]:e.bind(r,r),a;h(t)?a=t:(a=t.handler,n=t);let o=ca(this),s=Fn(i,a.bind(r),n);return o(),s}function Ln(e,t){let n=t.split(`.`);return()=>{let t=e;for(let e=0;e<n.length&&t;e++)t=t[n[e]];return t}}var Rn=Symbol(`_vte`),zn=e=>e.__isTeleport,Bn=Symbol(`_leaveCb`);function Vn(e){let t=e[0];if(e.length>1){for(let n of e)if(n.type!==Pi){t=n;break}}return t}function Hn(e){if(!Zn(e))return zn(e.type)&&e.children?Vn(e.children):e;if(e.component)return e.component.subTree;let{shapeFlag:t,children:n}=e;if(n){if(t&16)return n[0];if(t&32&&h(n.default))return n.default()}}function Un(e,t){if(e.shapeFlag&6&&e.component){e.transition=t;let n=e.component.subTree;Un(zn(n.type)&&Hn(n)||n,t)}else e.shapeFlag&128?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function Wn(e,t){return h(e)?s({name:e.name},t,{setup:e}):e}function Gn(e){e.ids=[e.ids[0]+e.ids[2]+++`-`,0,0]}function Kn(e,t){let n;return!!((n=Object.getOwnPropertyDescriptor(e,t))&&!n.configurable)}var qn=new WeakMap;function Jn(e,n,r,a,o=!1){if(d(e)){e.forEach((e,t)=>Jn(e,n&&(d(n)?n[t]:n),r,a,o));return}if(Xn(a)&&!o){a.shapeFlag&512&&a.type.__asyncResolved&&a.component.subTree.component&&Jn(e,n,r,a.component.subTree);return}let s=a.shapeFlag&4?va(a.component):a.el,l=o?null:s,{i:f,r:p}=e,m=n&&n.r,_=f.refs===t?f.refs={}:f.refs,v=f.setupState,y=P(v),b=v===t?i:e=>!Kn(_,e)&&u(y,e),x=(e,t)=>!(t&&Kn(_,t));if(m!=null&&m!==p){if(Yn(n),g(m))_[m]=null,b(m)&&(v[m]=null);else if(F(m)){let e=n;x(m,e.k)&&(m.value=null),e.k&&(_[e.k]=null)}}if(h(p))on(p,f,12,[l,_]);else{let t=g(p),n=F(p);if(t||n){let i=()=>{if(e.f){let n=t?b(p)?v[p]:_[p]:x(p)||!e.k?p.value:_[e.k];if(o)d(n)&&c(n,s);else if(d(n))n.includes(s)||n.push(s);else if(t)_[p]=[s],b(p)&&(v[p]=_[p]);else{let t=[s];x(p,e.k)&&(p.value=t),e.k&&(_[e.k]=t)}}else t?(_[p]=l,b(p)&&(v[p]=l)):n&&(x(p,e.k)&&(p.value=l),e.k&&(_[e.k]=l))};if(l){let t=()=>{i(),qn.delete(e)};t.id=-1,qn.set(e,t),B(t,r)}else Yn(e),i()}}}function Yn(e){let t=qn.get(e);t&&(t.flags|=8,qn.delete(e))}le().requestIdleCallback,le().cancelIdleCallback;var Xn=e=>!!e.type.__asyncLoader,Zn=e=>e.type.__isKeepAlive;function Qn(e,t){er(e,`a`,t)}function $n(e,t){er(e,`da`,t)}function er(e,t,n=J){let r=e.__wdc||=()=>{let t=n;for(;t;){if(t.isDeactivated)return;t=t.parent}return e()};if(nr(t,r,n),n){let e=n.parent;for(;e&&e.parent;)Zn(e.parent.vnode)&&tr(r,t,n,e),e=e.parent}}function tr(e,t,n,r){let i=nr(t,e,r,!0);lr(()=>{c(r[t],i)},n)}function nr(e,t,n=J,r=!1){if(n){let i=n[e]||(n[e]=[]),a=t.__weh||=(...r)=>{Ue();let i=ca(n),a=sn(t,n,e,r);return i(),We(),a};return r?i.unshift(a):i.push(a),a}}var rr=e=>(t,n=J)=>{(!da||e===`sp`)&&nr(e,(...e)=>t(...e),n)},ir=rr(`bm`),ar=rr(`m`),or=rr(`bu`),sr=rr(`u`),cr=rr(`bum`),lr=rr(`um`),ur=rr(`sp`),dr=rr(`rtg`),fr=rr(`rtc`);function pr(e,t=J){nr(`ec`,e,t)}var mr=`components`,hr=Symbol.for(`v-ndc`);function gr(e){return g(e)?_r(mr,e,!1)||e:e||hr}function _r(e,t,n=!0,r=!1){let i=R||J;if(i){let n=i.type;if(e===mr){let e=ya(n,!1);if(e&&(e===t||e===T(t)||e===ie(T(t))))return n}let a=vr(i[e]||n[e],t)||vr(i.appContext[e],t);return!a&&r?n:a}}function vr(e,t){return e&&(e[t]||e[T(t)]||e[ie(T(t))])}function yr(e,t,n,r){let i,a=n&&n[r],o=d(e);if(o||g(e)){let n=o&&Rt(e),r=!1,s=!1;n&&(r=!Bt(e),s=zt(e),e=nt(e)),i=Array(e.length);for(let n=0,o=e.length;n<o;n++)i[n]=t(r?s?Wt(Ut(e[n])):Ut(e[n]):e[n],n,void 0,a&&a[n])}else if(typeof e==`number`){i=Array(e);for(let n=0;n<e;n++)i[n]=t(n+1,n,void 0,a&&a[n])}else if(v(e)){if(e[Symbol.iterator])i=Array.from(e,(e,n)=>t(e,n,void 0,a&&a[n]));else{let n=Object.keys(e);i=Array(n.length);for(let r=0,o=n.length;r<o;r++){let o=n[r];i[r]=t(e[o],o,r,a&&a[r])}}}else i=[];return n&&(n[r]=i),i}function br(e,t,n,r,i,a){if(n??={},R.ce||R.parent&&Xn(R.parent)&&R.parent.ce){let e=a!=null&&n.key==null?s({},n,{key:a}):n,i=Object.keys(e).length>0;return t!=="default"&&(e.name=t),U(),Vi(V,null,[K(`slot`,e,r&&r())],i?-2:64)}let o=e[t];o&&o._c&&(o._d=!1);let c=Ii.length;U();let l;try{let i=o&&xr(o(n)),s=n.key||a||i&&i.key;l=Vi(V,{key:(s&&!_(s)?s:`_${t}`)+(!i&&r?`_fb`:``)},i||(r?r():[]),i&&e._===1?64:-2)}catch(e){for(let e=Ii.length;e>c;e--)Li();throw e}finally{o&&o._c&&(o._d=!0)}return!i&&l.scopeId&&(l.slotScopeIds=[l.scopeId+`-s`]),l}function xr(e){return e.some(e=>!Hi(e)||!(e.type===Pi||e.type===V&&!xr(e.children)))?e:null}var Sr=e=>e?ua(e)?va(e):Sr(e.parent):null,Cr=s(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=>Sr(e.parent),$root:e=>Sr(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>Mr(e),$forceUpdate:e=>e.f||=()=>{vn(e.update)},$nextTick:e=>e.n||=gn.bind(e.proxy),$watch:e=>In.bind(e)}),wr=(e,n)=>e!==t&&!e.__isScriptSetup&&u(e,n),Tr={get({_:e},n){if(n===`__v_skip`)return!0;let{ctx:r,setupState:i,data:a,props:o,accessCache:s,type:c,appContext:l}=e;if(n[0]!==`$`){let e=s[n];if(e!==void 0)switch(e){case 1:return i[n];case 2:return a[n];case 4:return r[n];case 3:return o[n]}else if(wr(i,n))return s[n]=1,i[n];else if(a!==t&&u(a,n))return s[n]=2,a[n];else if(u(o,n))return s[n]=3,o[n];else if(r!==t&&u(r,n))return s[n]=4,r[n];else Dr&&(s[n]=0)}let d=Cr[n],f,p;if(d)return n===`$attrs`&&N(e.attrs,`get`,``),d(e);if((f=c.__cssModules)&&(f=f[n]))return f;if(r!==t&&u(r,n))return s[n]=4,r[n];if(p=l.config.globalProperties,u(p,n))return p[n]},set({_:e},n,r){let{data:i,setupState:a,ctx:o}=e;return wr(a,n)?(a[n]=r,!0):i!==t&&u(i,n)?(i[n]=r,!0):u(e.props,n)||n[0]===`$`&&n.slice(1)in e?!1:(o[n]=r,!0)},has({_:{data:e,setupState:n,accessCache:r,ctx:i,appContext:a,props:o,type:s}},c){let l;return!!(r[c]||e!==t&&c[0]!==`$`&&u(e,c)||wr(n,c)||u(o,c)||u(i,c)||u(Cr,c)||u(a.config.globalProperties,c)||(l=s.__cssModules)&&l[c])},defineProperty(e,t,n){return n.get==null?u(n,`value`)&&this.set(e,t,n.value,null):e._.accessCache[t]=0,Reflect.defineProperty(e,t,n)}};function Er(e){return d(e)?e.reduce((e,t)=>(e[t]=null,e),{}):e}var Dr=!0;function Or(e){let t=Mr(e),n=e.proxy,i=e.ctx;Dr=!1,t.beforeCreate&&Ar(t.beforeCreate,e,`bc`);let{data:a,computed:o,methods:s,watch:c,provide:l,inject:u,created:f,beforeMount:p,mounted:m,beforeUpdate:g,updated:_,activated:y,deactivated:b,beforeDestroy:x,beforeUnmount:S,destroyed:C,unmounted:w,render:ee,renderTracked:te,renderTriggered:ne,errorCaptured:T,serverPrefetch:re,expose:E,inheritAttrs:ie,components:ae,directives:D,filters:oe}=t;if(u&&kr(u,i,null),s)for(let e in s){let t=s[e];h(t)&&(i[e]=t.bind(n))}if(a){let t=a.call(n,n);v(t)&&(e.data=Pt(t))}if(Dr=!0,o)for(let e in o){let t=o[e],a=Y({get:h(t)?t.bind(n,n):h(t.get)?t.get.bind(n,n):r,set:!h(t)&&h(t.set)?t.set.bind(n):r});Object.defineProperty(i,e,{enumerable:!0,configurable:!0,get:()=>a.value,set:e=>a.value=e})}if(c)for(let e in c)jr(c[e],i,n,e);if(l){let e=h(l)?l.call(n):l;Reflect.ownKeys(e).forEach(t=>{An(t,e[t])})}f&&Ar(f,e,`c`);function O(e,t){d(t)?t.forEach(t=>e(t.bind(n))):t&&e(t.bind(n))}if(O(ir,p),O(ar,m),O(or,g),O(sr,_),O(Qn,y),O($n,b),O(pr,T),O(fr,te),O(dr,ne),O(cr,S),O(lr,w),O(ur,re),d(E)){if(E.length){let t=e.exposed||={};E.forEach(e=>{Object.defineProperty(t,e,{get:()=>n[e],set:t=>n[e]=t,enumerable:!0})})}else e.exposed||={}}ee&&e.render===r&&(e.render=ee),ie!=null&&(e.inheritAttrs=ie),ae&&(e.components=ae),D&&(e.directives=D),re&&Gn(e)}function kr(e,t,n=r){d(e)&&(e=Lr(e));for(let n in e){let r=e[n],i;i=v(r)?`default`in r?jn(r.from||n,r.default,!0):jn(r.from||n):jn(r),F(i)?Object.defineProperty(t,n,{enumerable:!0,configurable:!0,get:()=>i.value,set:e=>i.value=e}):t[n]=i}}function Ar(e,t,n){sn(d(e)?e.map(e=>e.bind(t.proxy)):e.bind(t.proxy),t,n)}function jr(e,t,n,r){let i=r.includes(`.`)?Ln(n,r):()=>n[r];if(g(e)){let n=t[e];h(n)&&Pn(i,n)}else if(h(e))Pn(i,e.bind(n));else if(v(e)){if(d(e))e.forEach(e=>jr(e,t,n,r));else{let r=h(e.handler)?e.handler.bind(n):t[e.handler];h(r)&&Pn(i,r,e)}}}function Mr(e){let t=e.type,{mixins:n,extends:r}=t,{mixins:i,optionsCache:a,config:{optionMergeStrategies:o}}=e.appContext,s=a.get(t),c;return s?c=s:!i.length&&!n&&!r?c=t:(c={},i.length&&i.forEach(e=>Nr(c,e,o,!0)),Nr(c,t,o)),v(t)&&a.set(t,c),c}function Nr(e,t,n,r=!1){let{mixins:i,extends:a}=t;a&&Nr(e,a,n,!0),i&&i.forEach(t=>Nr(e,t,n,!0));for(let i in t)if(!(r&&i===`expose`)){let r=Pr[i]||n&&n[i];e[i]=r?r(e[i],t[i]):t[i]}return e}var Pr={data:Fr,props:zr,emits:zr,methods:Rr,computed:Rr,beforeCreate:z,created:z,beforeMount:z,mounted:z,beforeUpdate:z,updated:z,beforeDestroy:z,beforeUnmount:z,destroyed:z,unmounted:z,activated:z,deactivated:z,errorCaptured:z,serverPrefetch:z,components:Rr,directives:Rr,watch:Br,provide:Fr,inject:Ir};function Fr(e,t){return t?e?function(){return s(h(e)?e.call(this,this):e,h(t)?t.call(this,this):t)}:t:e}function Ir(e,t){return Rr(Lr(e),Lr(t))}function Lr(e){if(d(e)){let t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function z(e,t){return e?[...new Set([].concat(e,t))]:t}function Rr(e,t){return e?s(Object.create(null),e,t):t}function zr(e,t){return e?d(e)&&d(t)?[...new Set([...e,...t])]:s(Object.create(null),Er(e),Er(t??{})):t}function Br(e,t){if(!e)return t;if(!t)return e;let n=s(Object.create(null),e);for(let r in t)n[r]=z(e[r],t[r]);return n}function Vr(){return{app:null,config:{isNativeTag:i,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}}var Hr=0;function Ur(e,t){return function(n,r=null){h(n)||(n=s({},n)),r!=null&&!v(r)&&(r=null);let i=Vr(),a=new WeakSet,o=[],c=!1,l=i.app={_uid:Hr++,_component:n,_props:r,_container:null,_context:i,_instance:null,version:xa,get config(){return i.config},set config(e){},use(e,...t){return a.has(e)||(e&&h(e.install)?(a.add(e),e.install(l,...t)):h(e)&&(a.add(e),e(l,...t))),l},mixin(e){return i.mixins.includes(e)||i.mixins.push(e),l},component(e,t){return t?(i.components[e]=t,l):i.components[e]},directive(e,t){return t?(i.directives[e]=t,l):i.directives[e]},mount(a,o,s){if(!c){let u=l._ceVNode||K(n,r);return u.appContext=i,s===!0?s=`svg`:s===!1&&(s=void 0),o&&t?t(u,a):e(u,a,s),c=!0,l._container=a,a.__vue_app__=l,va(u.component)}},onUnmount(e){o.push(e)},unmount(){c&&(sn(o,l._instance,16),e(null,l._container),delete l._container.__vue_app__)},provide(e,t){return i.provides[e]=t,l},runWithContext(e){let t=Wr;Wr=l;try{return e()}finally{Wr=t}}};return l}}var Wr=null,Gr=(e,t)=>t===`modelValue`||t===`model-value`?e.modelModifiers:e[`${t}Modifiers`]||e[`${T(t)}Modifiers`]||e[`${E(t)}Modifiers`];function Kr(e,n,...r){if(e.isUnmounted)return;let i=e.vnode.props||t,a=r,o=n.startsWith(`update:`),s=o&&Gr(i,n.slice(7));s&&(s.trim&&(a=r.map(e=>g(e)?e.trim():e)),s.number&&(a=a.map(se)));let c,l=i[c=ae(n)]||i[c=ae(T(n))];!l&&o&&(l=i[c=ae(E(n))]),l&&sn(l,e,6,a);let u=i[c+`Once`];if(u){if(!e.emitted)e.emitted={};else if(e.emitted[c])return;e.emitted[c]=!0,sn(u,e,6,a)}}var qr=new WeakMap;function Jr(e,t,n=!1){let r=n?qr:t.emitsCache,i=r.get(e);if(i!==void 0)return i;let a=e.emits,o={},c=!1;if(!h(e)){let r=e=>{let n=Jr(e,t,!0);n&&(c=!0,s(o,n))};!n&&t.mixins.length&&t.mixins.forEach(r),e.extends&&r(e.extends),e.mixins&&e.mixins.forEach(r)}return!a&&!c?(v(e)&&r.set(e,null),null):(d(a)?a.forEach(e=>o[e]=null):s(o,a),v(e)&&r.set(e,o),o)}function Yr(e,t){return!e||!a(t)?!1:(t=t.slice(2),t=t===`Once`?t:t.replace(/Once$/,``),u(e,t[0].toLowerCase()+t.slice(1))||u(e,E(t))||u(e,t))}function Xr(e){let{type:t,vnode:n,proxy:r,withProxy:i,propsOptions:[a],slots:s,attrs:c,emit:l,render:u,renderCache:d,props:f,data:p,setupState:m,ctx:h,inheritAttrs:g}=e,_=En(e),v,y;try{if(n.shapeFlag&4){let e=i||r,t=e;v=Zi(u.call(t,e,d,f,m,p,h)),y=c}else{let e=t;v=Zi(e.length>1?e(f,{attrs:c,slots:s,emit:l}):e(f,null)),y=t.props?c:Zr(c)}}catch(t){Ii.length=0,cn(t,e,1),v=K(Pi)}let b=v;if(y&&g!==!1){let e=Object.keys(y),{shapeFlag:t}=b;e.length&&t&7&&(a&&e.some(o)&&(y=Qr(y,a)),b=Ji(b,y,!1,!0))}return n.dirs&&(b=Ji(b,null,!1,!0),b.dirs=b.dirs?b.dirs.concat(n.dirs):n.dirs),n.transition&&Un(zn(b.type)&&Hn(b)||b,n.transition),v=b,En(_),v}var Zr=e=>{let t;for(let n in e)(n===`class`||n===`style`||a(n))&&((t||={})[n]=e[n]);return t},Qr=(e,t)=>{let n={};for(let r in e)(!o(r)||!(r.slice(9)in t))&&(n[r]=e[r]);return n};function $r(e,t,n){let{props:r,children:i,component:a}=e,{props:o,children:s,patchFlag:c}=t,l=a.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&c>=0){if(c&1024)return!0;if(c&16)return r?ei(r,o,l):!!o;if(c&8){let e=t.dynamicProps;for(let t=0;t<e.length;t++){let n=e[t];if(ti(o,r,n)&&!Yr(l,n))return!0}}}else return(i||s)&&(!s||!s.$stable)?!0:r===o?!1:r?!o||ei(r,o,l):!!o;return!1}function ei(e,t,n){let r=Object.keys(t);if(r.length!==Object.keys(e).length)return!0;for(let i=0;i<r.length;i++){let a=r[i];if(ti(t,e,a)&&!Yr(n,a))return!0}return!1}function ti(e,t,n){let r=e[n],i=t[n];return n===`style`&&v(r)&&v(i)?!be(r,i):r!==i}function ni({vnode:e,parent:t,suspense:n},r){for(;t;){let n=t.subTree;if(n.suspense&&n.suspense.activeBranch===e&&(n.suspense.vnode.el=n.el=r,e=n),n===e)(e=t.vnode).el=r,t=t.parent;else break}n&&n.activeBranch===e&&(n.vnode.el=r)}var ri={},ii=()=>Object.create(ri),ai=e=>Object.getPrototypeOf(e)===ri;function oi(e,t,n,r=!1){let i={},a=ii();e.propsDefaults=Object.create(null),ci(e,t,i,a);for(let t in e.propsOptions[0])t in i||(i[t]=void 0);e.props=n?r?i:Ft(i):e.type.props?i:a,e.attrs=a}function si(e,t,n,r){let{props:i,attrs:a,vnode:{patchFlag:o}}=e,s=P(i),[c]=e.propsOptions,l=!1;if((r||o>0)&&!(o&16)){if(o&8){let n=e.vnode.dynamicProps;for(let r=0;r<n.length;r++){let o=n[r];if(Yr(e.emitsOptions,o))continue;let d=t[o];if(c){if(u(a,o))d!==a[o]&&(a[o]=d,l=!0);else{let t=T(o);i[t]=li(c,s,t,d,e,!1)}}else d!==a[o]&&(a[o]=d,l=!0)}}}else{ci(e,t,i,a)&&(l=!0);let r;for(let a in s)(!t||!u(t,a)&&((r=E(a))===a||!u(t,r)))&&(c?n&&(n[a]!==void 0||n[r]!==void 0)&&(i[a]=li(c,s,a,void 0,e,!0)):delete i[a]);if(a!==s)for(let e in a)(!t||!u(t,e))&&(delete a[e],l=!0)}l&&et(e.attrs,`set`,``)}function ci(e,n,r,i){let[a,o]=e.propsOptions,s=!1,c;if(n)for(let t in n){if(ee(t))continue;let l=n[t],d;a&&u(a,d=T(t))?!o||!o.includes(d)?r[d]=l:(c||={})[d]=l:Yr(e.emitsOptions,t)||(!(t in i)||l!==i[t])&&(i[t]=l,s=!0)}if(o){let n=P(r),i=c||t;for(let t=0;t<o.length;t++){let s=o[t];r[s]=li(a,n,s,i[s],e,!u(i,s))}}return s}function li(e,t,n,r,i,a){let o=e[n];if(o!=null){let e=u(o,`default`);if(e&&r===void 0){let e=o.default;if(o.type!==Function&&!o.skipFactory&&h(e)){let{propsDefaults:a}=i;if(n in a)r=a[n];else{let o=ca(i);r=a[n]=e.call(null,t),o()}}else r=e;i.ce&&i.ce._setProp(n,r)}o[0]&&(a&&!e?r=!1:o[1]&&(r===``||r===E(n))&&(r=!0))}return r}var ui=new WeakMap;function di(e,r,i=!1){let a=i?ui:r.propsCache,o=a.get(e);if(o)return o;let c=e.props,l={},f=[],p=!1;if(!h(e)){let t=e=>{p=!0;let[t,n]=di(e,r,!0);s(l,t),n&&f.push(...n)};!i&&r.mixins.length&&r.mixins.forEach(t),e.extends&&t(e.extends),e.mixins&&e.mixins.forEach(t)}if(!c&&!p)return v(e)&&a.set(e,n),n;if(d(c))for(let e=0;e<c.length;e++){let n=T(c[e]);fi(n)&&(l[n]=t)}else if(c)for(let e in c){let t=T(e);if(fi(t)){let n=c[e],r=l[t]=d(n)||h(n)?{type:n}:s({},n),i=r.type,a=!1,o=!0;if(d(i))for(let e=0;e<i.length;++e){let t=i[e],n=h(t)&&t.name;if(n===`Boolean`){a=!0;break}n===`String`&&(o=!1)}else a=h(i)&&i.name===`Boolean`;r[0]=a,r[1]=o,(a||u(r,`default`))&&f.push(t)}}let m=[l,f];return v(e)&&a.set(e,m),m}function fi(e){return e[0]!==`$`&&!ee(e)}var pi=e=>e===`_`||e===`_ctx`||e===`$stable`,mi=e=>d(e)?e.map(Zi):[Zi(e)],hi=(e,t,n)=>{if(t._n)return t;let r=Dn((...e)=>mi(t(...e)),n);return r._c=!1,r},gi=(e,t,n)=>{let r=e._ctx;for(let n in e){if(pi(n))continue;let i=e[n];if(h(i))t[n]=hi(n,i,r);else if(i!=null){let e=mi(i);t[n]=()=>e}}},_i=(e,t)=>{let n=mi(t);e.slots.default=()=>n},vi=(e,t,n)=>{for(let r in t)(n||!pi(r))&&(e[r]=t[r])},yi=(e,t,n)=>{let r=e.slots=ii();if(e.vnode.shapeFlag&32){let e=t._;e?(vi(r,t,n),n&&O(r,`_`,e,!0)):gi(t,r)}else t&&_i(e,t)},bi=(e,n,r)=>{let{vnode:i,slots:a}=e,o=!0,s=t;if(i.shapeFlag&32){let e=n._;e?r&&e===1?o=!1:vi(a,n,r):(o=!n.$stable,gi(n,a)),s=n}else n&&(_i(e,n),s={default:1});if(o)for(let e in a)!pi(e)&&s[e]==null&&delete a[e]},B=Mi;function xi(e){return Si(e)}function Si(e,i){let a=le();a.__VUE__=!0;let{insert:o,remove:s,patchProp:c,createElement:l,createText:u,createComment:d,setText:f,setElementText:p,parentNode:m,nextSibling:h,setScopeId:g=r,insertStaticContent:_}=e,v=(e,t,n,r=null,i=null,a=null,o=void 0,s=null,c=!!t.dynamicChildren)=>{if(e===t)return;e&&!Ui(e,t)&&(r=ye(e),k(e,i,a,!0),e=null),t.patchFlag===-2&&(c=!1,t.dynamicChildren=null);let{type:l,ref:u,shapeFlag:d}=t;switch(l){case Ni:y(e,t,n,r);break;case Pi:b(e,t,n,r);break;case Fi:e??x(t,n,r,o);break;case V:ae(e,t,n,r,i,a,o,s,c);break;default:d&1?w(e,t,n,r,i,a,o,s,c):d&6?D(e,t,n,r,i,a,o,s,c):(d&64||d&128)&&l.process(e,t,n,r,i,a,o,s,c,A)}u!=null&&i?Jn(u,e&&e.ref,a,t||e,!t):u==null&&e&&e.ref!=null&&Jn(e.ref,null,a,e,!0)},y=(e,t,n,r)=>{if(e==null)o(t.el=u(t.children),n,r);else{let n=t.el=e.el;t.children!==e.children&&f(n,t.children)}},b=(e,t,n,r)=>{e==null?o(t.el=d(t.children||``),n,r):t.el=e.el},x=(e,t,n,r)=>{[e.el,e.anchor]=_(e.children,t,n,r,e.el,e.anchor)},S=({el:e,anchor:t},n,r)=>{let i;for(;e&&e!==t;)i=h(e),o(e,n,r),e=i;o(t,n,r)},C=({el:e,anchor:t})=>{let n;for(;e&&e!==t;)n=h(e),s(e),e=n;s(t)},w=(e,t,n,r,i,a,o,s,c)=>{if(t.type===`svg`?o=`svg`:t.type===`math`&&(o=`mathml`),e==null)te(t,n,r,i,a,o,s,c);else{let n=e.el&&e.el._isVueCE?e.el:null;try{n&&n._beginPatch(),re(e,t,i,a,o,s,c)}finally{n&&n._endPatch()}}},te=(e,t,n,r,i,a,s,u)=>{let d,f,{props:m,shapeFlag:h,transition:g,dirs:_}=e;if(d=e.el=l(e.type,a,m&&m.is,m),h&8?p(d,e.children):h&16&&T(e.children,d,null,r,i,Ci(e,a),s,u),_&&kn(e,null,r,`created`),ne(d,e,e.scopeId,s,r),m){for(let e in m)e!==`value`&&!ee(e)&&c(d,e,null,m[e],a,r);`value`in m&&c(d,`value`,null,m.value,a),(f=m.onVnodeBeforeMount)&&ta(f,r,e)}_&&kn(e,null,r,`beforeMount`);let v=Ti(i,g);v&&g.beforeEnter(d),o(d,t,n),((f=m&&m.onVnodeMounted)||v||_)&&B(()=>{try{f&&ta(f,r,e),v&&g.enter(d),_&&kn(e,null,r,`mounted`)}finally{}},i)},ne=(e,t,n,r,i)=>{if(n&&g(e,n),r)for(let t=0;t<r.length;t++)g(e,r[t]);if(i){let n=i.subTree;if(t===n||ji(n.type)&&(n.ssContent===t||n.ssFallback===t)){let t=i.vnode;ne(e,t,t.scopeId,t.slotScopeIds,i.parent)}}},T=(e,t,n,r,i,a,o,s,c=0)=>{for(let l=c;l<e.length;l++){let c=e[l]=s?Qi(e[l]):Zi(e[l]);v(null,c,t,n,r,i,a,o,s)}},re=(e,n,r,i,a,o,s)=>{let l=n.el=e.el,{patchFlag:u,dynamicChildren:d,dirs:f}=n;u|=e.patchFlag&16;let m=e.props||t,h=n.props||t,g;if(r&&wi(r,!1),(g=h.onVnodeBeforeUpdate)&&ta(g,r,n,e),f&&kn(n,e,r,`beforeUpdate`),r&&wi(r,!0),d&&(!e.dynamicChildren||e.dynamicChildren.length!==d.length)&&(u=0,s=!1,d=null),(m.innerHTML&&h.innerHTML==null||m.textContent&&h.textContent==null)&&p(l,``),d?E(e.dynamicChildren,d,l,r,i,Ci(n,a),o):s||de(e,n,l,null,r,i,Ci(n,a),o,!1),u>0){if(u&16)ie(l,m,h,r,a);else if(u&2&&m.class!==h.class&&c(l,`class`,null,h.class,a),u&4&&c(l,`style`,m.style,h.style,a),u&8){let e=n.dynamicProps;for(let t=0;t<e.length;t++){let n=e[t],i=m[n],o=h[n];(o!==i||n===`value`)&&c(l,n,i,o,a,r)}}u&1&&e.children!==n.children&&p(l,n.children)}else!s&&d==null&&ie(l,m,h,r,a);((g=h.onVnodeUpdated)||f)&&B(()=>{g&&ta(g,r,n,e),f&&kn(n,e,r,`updated`)},i)},E=(e,t,n,r,i,a,o)=>{for(let s=0;s<t.length;s++){let c=e[s],l=t[s],u=c.el&&(c.type===V||!Ui(c,l)||c.shapeFlag&198)?m(c.el):n;v(c,l,u,null,r,i,a,o,!0)}},ie=(e,n,r,i,a)=>{if(n!==r){if(n!==t)for(let t in n)!ee(t)&&!(t in r)&&c(e,t,n[t],null,a,i);for(let t in r){if(ee(t))continue;let o=r[t],s=n[t];o!==s&&t!==`value`&&c(e,t,s,o,a,i)}`value`in r&&c(e,`value`,n.value,r.value,a)}},ae=(e,t,n,r,i,a,s,c,l)=>{let d=t.el=e?e.el:u(``),f=t.anchor=e?e.anchor:u(``),{patchFlag:p,dynamicChildren:m,slotScopeIds:h}=t;h&&(c=c?c.concat(h):h),e==null?(o(d,n,r),o(f,n,r),T(t.children||[],n,f,i,a,s,c,l)):p>0&&p&64&&m&&e.dynamicChildren&&e.dynamicChildren.length===m.length?(E(e.dynamicChildren,m,n,i,a,s,c),(t.key!=null||i&&t===i.subTree)&&Ei(e,t,!0)):de(e,t,n,f,i,a,s,c,l)},D=(e,t,n,r,i,a,o,s,c)=>{t.slotScopeIds=s,e==null?t.shapeFlag&512?i.ctx.activate(t,n,r,o,c):O(t,n,r,i,a,o,c):se(e,t,c)},O=(e,t,n,r,i,a,o)=>{let s=e.component=ia(e,r,i);if(Zn(e)&&(s.ctx.renderer=A),fa(s,!1,o),s.asyncDep){if(i&&i.registerDep(s,ce,o),!e.el){let r=s.subTree=K(Pi);b(null,r,t,n),e.placeholder=r.el}}else ce(s,e,t,n,i,a,o)},se=(e,t,n)=>{let r=t.component=e.component;if($r(e,t,n)){if(r.asyncDep&&!r.asyncResolved){ue(r,t,n);return}r.next=t,r.update()}else t.el=e.el,r.vnode=t},ce=(e,t,n,r,i,a,o)=>{let s=()=>{if(e.isMounted){let{next:t,bu:n,u:r,parent:s,vnode:c}=e;{let n=Oi(e);if(n){t&&(t.el=c.el,ue(e,t,o)),n.asyncDep.then(()=>{B(()=>{e.isUnmounted||l()},i)});return}}let u=t,d;wi(e,!1),t?(t.el=c.el,ue(e,t,o)):t=c,n&&oe(n),(d=t.props&&t.props.onVnodeBeforeUpdate)&&ta(d,s,t,c),wi(e,!0);let f=Xr(e),p=e.subTree;e.subTree=f,v(p,f,m(p.el),ye(p),e,i,a),t.el=f.el,u===null&&ni(e,f.el),r&&B(r,i),(d=t.props&&t.props.onVnodeUpdated)&&B(()=>ta(d,s,t,c),i)}else{let o,{el:s,props:c}=t,{bm:l,m:u,parent:d,root:f,type:p}=e,m=Xn(t);if(wi(e,!1),l&&oe(l),!m&&(o=c&&c.onVnodeBeforeMount)&&ta(o,d,t),wi(e,!0),s&&Ce){let t=()=>{e.subTree=Xr(e),Ce(s,e.subTree,e,i,null)};m&&p.__asyncHydrate?p.__asyncHydrate(s,e,t):t()}else{f.ce&&f.ce._hasShadowRoot()&&f.ce._injectChildStyle(p,e.parent?e.parent.type:void 0);let o=e.subTree=Xr(e);v(null,o,n,r,e,i,a),t.el=o.el}if(u&&B(u,i),!m&&(o=c&&c.onVnodeMounted)){let e=t;B(()=>ta(o,d,e),i)}(t.shapeFlag&256||d&&Xn(d.vnode)&&d.vnode.shapeFlag&256)&&e.a&&B(e.a,i),e.isMounted=!0,t=n=r=null}};e.scope.on();let c=e.effect=new Oe(s);e.scope.off();let l=e.update=c.run.bind(c),u=e.job=c.runIfDirty.bind(c);u.i=e,u.id=e.uid,c.scheduler=()=>vn(u),wi(e,!0),l()},ue=(e,t,n)=>{t.component=e;let r=e.vnode.props;e.vnode=t,e.next=null,si(e,t.props,r,n),bi(e,t.children,n),Ue(),xn(e),We()},de=(e,t,n,r,i,a,o,s,c=!1)=>{let l=e&&e.children,u=e?e.shapeFlag:0,d=t.children,{patchFlag:f,shapeFlag:m}=t;if(f>0){if(f&128){pe(l,d,n,r,i,a,o,s,c);return}if(f&256){fe(l,d,n,r,i,a,o,s,c);return}}m&8?(u&16&&ve(l,i,a),d!==l&&p(n,d)):u&16?m&16?pe(l,d,n,r,i,a,o,s,c):ve(l,i,a,!0):(u&8&&p(n,``),m&16&&T(d,n,r,i,a,o,s,c))},fe=(e,t,r,i,a,o,s,c,l)=>{e||=n,t||=n;let u=e.length,d=t.length,f=Math.min(u,d),p;for(p=0;p<f;p++){let n=t[p]=l?Qi(t[p]):Zi(t[p]);v(e[p],n,r,null,a,o,s,c,l)}u>d?ve(e,a,o,!0,!1,f):T(t,r,i,a,o,s,c,l,f)},pe=(e,t,r,i,a,o,s,c,l)=>{let u=0,d=t.length,f=e.length-1,p=d-1;for(;u<=f&&u<=p;){let n=e[u],i=t[u]=l?Qi(t[u]):Zi(t[u]);if(Ui(n,i))v(n,i,r,null,a,o,s,c,l);else break;u++}for(;u<=f&&u<=p;){let n=e[f],i=t[p]=l?Qi(t[p]):Zi(t[p]);if(Ui(n,i))v(n,i,r,null,a,o,s,c,l);else break;f--,p--}if(u>f){if(u<=p){let e=p+1,n=e<d?t[e].el:i;for(;u<=p;)v(null,t[u]=l?Qi(t[u]):Zi(t[u]),r,n,a,o,s,c,l),u++}}else if(u>p)for(;u<=f;)k(e[u],a,o,!0),u++;else{let m=u,h=u,g=new Map;for(u=h;u<=p;u++){let e=t[u]=l?Qi(t[u]):Zi(t[u]);e.key!=null&&g.set(e.key,u)}let _,y=0,b=p-h+1,x=!1,S=0,C=Array(b);for(u=0;u<b;u++)C[u]=0;for(u=m;u<=f;u++){let n=e[u];if(y>=b){k(n,a,o,!0);continue}let i;if(n.key!=null)i=g.get(n.key);else for(_=h;_<=p;_++)if(C[_-h]===0&&Ui(n,t[_])){i=_;break}i===void 0?k(n,a,o,!0):(C[i-h]=u+1,i>=S?S=i:x=!0,v(n,t[i],r,null,a,o,s,c,l),y++)}let w=x?Di(C):n;for(_=w.length-1,u=b-1;u>=0;u--){let e=h+u,n=t[e],f=t[e+1],p=e+1<d?f.el||Ai(f):i;C[u]===0?v(null,n,r,p,a,o,s,c,l):x&&(_<0||u!==w[_]?me(n,r,p,2):_--)}}},me=(e,t,n,r,i=null)=>{let{el:a,type:c,transition:l,children:u,shapeFlag:d}=e;if(d&6){me(e.component.subTree,t,n,r);return}if(d&128){e.suspense.move(t,n,r);return}if(d&64){c.move(e,t,n,A);return}if(c===V){o(a,t,n);for(let e=0;e<u.length;e++)me(u[e],t,n,r);o(e.anchor,t,n);return}if(c===Fi){S(e,t,n);return}if(r!==2&&d&1&&l){if(r===0)l.persisted&&!a[Bn]?o(a,t,n):(l.beforeEnter(a),o(a,t,n),B(()=>l.enter(a),i));else{let{leave:r,delayLeave:i,afterLeave:c}=l,u=()=>{e.ctx.isUnmounted?s(a):o(a,t,n)},d=()=>{let e=a._isLeaving||!!a[Bn];a._isLeaving&&a[Bn](!0),l.persisted&&!e?u():r(a,()=>{u(),c&&c()})};i?i(a,u,d):d()}}else o(a,t,n)},k=(e,t,n,r=!1,i=!1)=>{let{type:a,props:o,ref:s,children:c,dynamicChildren:l,shapeFlag:u,patchFlag:d,dirs:f,cacheIndex:p,memo:m}=e;if(d===-2&&(i=!1),s!=null&&(Ue(),Jn(s,null,n,e,!0),We()),p!=null&&(t.renderCache[p]=void 0),u&256){t.ctx.deactivate(e);return}let h=u&1&&f,g=!Xn(e),_;if(g&&(_=o&&o.onVnodeBeforeUnmount)&&ta(_,t,e),u&6)_e(e.component,n,r);else{if(u&128){e.suspense.unmount(n,r);return}h&&kn(e,null,t,`beforeUnmount`),u&64?e.type.remove(e,t,n,A,r):l&&!l.hasOnce&&(a!==V||d>0&&d&64)?ve(l,t,n,!1,!0):(a===V&&d&384||!i&&u&16)&&ve(c,t,n),r&&he(e)}let v=m!=null&&p==null;(g&&(_=o&&o.onVnodeUnmounted)||h||v)&&B(()=>{_&&ta(_,t,e),h&&kn(e,null,t,`unmounted`),v&&(e.el=null)},n)},he=e=>{let{type:t,el:n,anchor:r,transition:i}=e;if(t===V){ge(n,r);return}if(t===Fi){C(e);return}let a=()=>{s(n),i&&!i.persisted&&i.afterLeave&&i.afterLeave()};if(e.shapeFlag&1&&i&&!i.persisted){let{leave:t,delayLeave:r}=i,o=()=>t(n,a);r?r(e.el,a,o):o()}else a()},ge=(e,t)=>{let n;for(;e!==t;)n=h(e),s(e),e=n;s(t)},_e=(e,t,n)=>{let{bum:r,scope:i,job:a,subTree:o,um:s,m:c,a:l}=e;ki(c),ki(l),r&&oe(r),i.stop(),a&&(a.flags|=8,k(o,e,t,n)),s&&B(s,t),B(()=>{e.isUnmounted=!0},t)},ve=(e,t,n,r=!1,i=!1,a=0)=>{for(let o=a;o<e.length;o++)k(e[o],t,n,r,i)},ye=e=>{if(e.shapeFlag&6)return ye(e.component.subTree);if(e.shapeFlag&128)return e.suspense.next();let t=h(e.anchor||e.el),n=t&&t[Rn];return n?h(n):t},be=!1,xe=(e,t,n)=>{let r;e==null?t._vnode&&(k(t._vnode,null,null,!0),r=t._vnode.component):v(t._vnode||null,e,t,null,null,null,n),t._vnode=e,be||=(be=!0,xn(r),Sn(),!1)},A={p:v,um:k,m:me,r:he,mt:O,mc:T,pc:de,pbc:E,n:ye,o:e},Se,Ce;return i&&([Se,Ce]=i(A)),{render:xe,hydrate:Se,createApp:Ur(xe,Se)}}function Ci({type:e,props:t},n){return n===`svg`&&e===`foreignObject`||n===`mathml`&&e===`annotation-xml`&&t&&t.encoding&&t.encoding.includes(`html`)?void 0:n}function wi({effect:e,job:t},n){n?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function Ti(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function Ei(e,t,n=!1){let r=e.children,i=t.children;if(d(r)&&d(i))for(let e=0;e<r.length;e++){let t=r[e],a=i[e];a.shapeFlag&1&&!a.dynamicChildren&&((a.patchFlag<=0||a.patchFlag===32)&&(a=i[e]=Qi(i[e]),a.el=t.el),!n&&a.patchFlag!==-2&&Ei(t,a)),a.type===Ni&&(a.patchFlag===-1&&(a=i[e]=Qi(a)),a.el=t.el),a.type===Pi&&!a.el&&(a.el=t.el)}}function Di(e){let t=e.slice(),n=[0],r,i,a,o,s,c=e.length;for(r=0;r<c;r++){let c=e[r];if(c!==0){if(i=n[n.length-1],e[i]<c){t[r]=i,n.push(r);continue}for(a=0,o=n.length-1;a<o;)s=a+o>>1,e[n[s]]<c?a=s+1:o=s;c<e[n[a]]&&(a>0&&(t[r]=n[a-1]),n[a]=r)}}for(a=n.length,o=n[a-1];a-->0;)n[a]=o,o=t[o];return n}function Oi(e){let t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:Oi(t)}function ki(e){if(e)for(let t=0;t<e.length;t++)e[t].flags|=8}function Ai(e){if(e.placeholder)return e.placeholder;let t=e.component;return t?Ai(t.subTree):null}var ji=e=>e.__isSuspense;function Mi(e,t){t&&t.pendingBranch?d(e)?t.effects.push(...e):t.effects.push(e):bn(e)}var V=Symbol.for(`v-fgt`),Ni=Symbol.for(`v-txt`),Pi=Symbol.for(`v-cmt`),Fi=Symbol.for(`v-stc`),Ii=[],H=null;function U(e=!1){Ii.push(H=e?null:[])}function Li(){Ii.pop(),H=Ii[Ii.length-1]||null}var Ri=1;function zi(e,t=!1){Ri+=e,e<0&&H&&t&&(H.hasOnce=!0)}function Bi(e){return e.dynamicChildren=Ri>0?H||n:null,Li(),Ri>0&&H&&H.push(e),e}function W(e,t,n,r,i,a){return Bi(G(e,t,n,r,i,a,!0))}function Vi(e,t,n,r,i){return Bi(K(e,t,n,r,i,!0))}function Hi(e){return e?e.__v_isVNode===!0:!1}function Ui(e,t){return e.type===t.type&&e.key===t.key}var Wi=({key:e})=>e??null,Gi=({ref:e,ref_key:t,ref_for:n})=>(typeof e==`number`&&(e=``+e),e==null?null:g(e)||F(e)||h(e)?{i:R,r:e,k:t,f:!!n}:e);function G(e,t=null,n=null,r=0,i=null,a=e===V?0:1,o=!1,s=!1){let c={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&Wi(t),ref:t&&Gi(t),scopeId:Tn,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag:a,patchFlag:r,dynamicProps:i,dynamicChildren:null,appContext:null,ctx:R};return s?($i(c,n),a&128&&e.normalize(c)):n&&(c.shapeFlag|=g(n)?8:16),Ri>0&&!o&&H&&(c.patchFlag>0||a&6)&&c.patchFlag!==32&&H.push(c),c}var K=Ki;function Ki(e,t=null,n=null,r=0,i=null,a=!1){if((!e||e===hr)&&(e=Pi),Hi(e)){let r=Ji(e,t,!0);return n&&$i(r,n),Ri>0&&!a&&H&&(r.shapeFlag&6?H[H.indexOf(e)]=r:H.push(r)),r.patchFlag=-2,r}if(ba(e)&&(e=e.__vccOpts),t){t=qi(t);let{class:e,style:n}=t;e&&!g(e)&&(t.class=k(e)),v(n)&&(Vt(n)&&!d(n)&&(n=s({},n)),t.style=ue(n))}let o=g(e)?1:ji(e)?128:zn(e)?64:v(e)?4:h(e)?2:0;return G(e,t,n,r,i,o,a,!0)}function qi(e){return e?Vt(e)||ai(e)?s({},e):e:null}function Ji(e,t,n=!1,r=!1){let{props:i,ref:a,patchFlag:o,children:s,transition:c}=e,l=t?ea(i||{},t):i,u={__v_isVNode:!0,__v_skip:!0,type:e.type,props:l,key:l&&Wi(l),ref:t&&t.ref?n&&a?d(a)?a.concat(Gi(t)):[a,Gi(t)]:Gi(t):a,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:s,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==V?o===-1?16:o|16:o,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:c,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&Ji(e.ssContent),ssFallback:e.ssFallback&&Ji(e.ssFallback),placeholder:e.placeholder,el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return c&&r&&Un(u,c.clone(u)),u}function q(e=` `,t=0){return K(Ni,null,e,t)}function Yi(e,t){let n=K(Fi,null,e);return n.staticCount=t,n}function Xi(e=``,t=!1){return t?(U(),Vi(Pi,null,e)):K(Pi,null,e)}function Zi(e){return e==null||typeof e==`boolean`?K(Pi):d(e)?K(V,null,e.slice()):Hi(e)?Qi(e):K(Ni,null,String(e))}function Qi(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:Ji(e)}function $i(e,t){let n=0,{shapeFlag:r}=e;if(t==null)t=null;else if(d(t))n=16;else if(typeof t==`object`){if(r&65){let n=t.default;n&&(n._c&&(n._d=!1),$i(e,n()),n._c&&(n._d=!0));return}{n=32;let r=t._;!r&&!ai(t)?t._ctx=R:r===3&&R&&(R.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}}else if(h(t)){if(r&65){$i(e,{default:t});return}t={default:t,_ctx:R},n=32}else t=String(t),r&64?(n=16,t=[q(t)]):n=8;e.children=t,e.shapeFlag|=n}function ea(...e){let t={};for(let n=0;n<e.length;n++){let r=e[n];for(let e in r)if(e===`class`)t.class!==r.class&&(t.class=k([t.class,r.class]));else if(e===`style`)t.style=ue([t.style,r.style]);else if(a(e)){let n=t[e],i=r[e];i&&n!==i&&!(d(n)&&n.includes(i))?t[e]=n?[].concat(n,i):i:i==null&&n==null&&!o(e)&&(t[e]=i)}else e!==``&&(t[e]=r[e])}return t}function ta(e,t,n,r=null){sn(e,t,7,[n,r])}var na=Vr(),ra=0;function ia(e,n,r){let i=e.type,a=(n?n.appContext:e.appContext)||na,o={uid:ra++,vnode:e,type:i,parent:n,appContext:a,root:null,next:null,subTree:null,effect:null,update:null,job:null,scope:new we(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:n?n.provides:Object.create(a.provides),ids:n?n.ids:[``,0,0],accessCache:null,renderCache:[],components:null,directives:null,propsOptions:di(i,a),emitsOptions:Jr(i,a),emit:null,emitted:null,propsDefaults:t,inheritAttrs:i.inheritAttrs,ctx:t,data:t,props:t,attrs:t,slots:t,refs:t,setupState:t,setupContext:null,suspense:r,suspenseId:r?r.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 o.ctx={_:o},o.root=n?n.root:o,o.emit=Kr.bind(null,o),e.ce&&e.ce(o),o}var J=null,aa=()=>J||R,oa,sa;{let e=le(),t=(t,n)=>{let r;return(r=e[t])||(r=e[t]=[]),r.push(n),e=>{r.length>1?r.forEach(t=>t(e)):r[0](e)}};oa=t(`__VUE_INSTANCE_SETTERS__`,e=>J=e),sa=t(`__VUE_SSR_SETTERS__`,e=>da=e)}var ca=e=>{let t=J;return oa(e),e.scope.on(),()=>{e.scope.off(),oa(t)}},la=()=>{J&&J.scope.off(),oa(null)};function ua(e){return e.vnode.shapeFlag&4}var da=!1;function fa(e,t=!1,n=!1){t&&sa(t);let{props:r,children:i}=e.vnode,a=ua(e);oi(e,r,a,t),yi(e,i,n||t);let o=a?pa(e,t):void 0;return t&&sa(!1),o}function pa(e,t){let n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,Tr);let{setup:r}=n;if(r){Ue();let n=e.setupContext=r.length>1?_a(e):null,i=ca(e),a=on(r,e,0,[e.props,n]),o=y(a);if(We(),i(),(o||e.sp)&&!Xn(e)&&Gn(e),o){if(a.then(la,la),t)return a.then(n=>{sa(!0);try{ma(e,n,t)}finally{sa(!1)}}).catch(t=>{cn(t,e,0)});e.asyncDep=a}else ma(e,a,t)}else ha(e,t)}function ma(e,t,n){h(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:v(t)&&(e.setupState=Xt(t)),ha(e,n)}function ha(e,t,n){let i=e.type;e.render||=i.render||r;{let t=ca(e);Ue();try{Or(e)}finally{We(),t()}}}var ga={get(e,t){return N(e,`get`,``),e[t]}};function _a(e){return{attrs:new Proxy(e.attrs,ga),slots:e.slots,emit:e.emit,expose:t=>{e.exposed=t||{}}}}function va(e){return e.exposed?e.exposeProxy||=new Proxy(Xt(Ht(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in Cr)return Cr[n](e)},has(e,t){return t in e||t in Cr}}):e.proxy}function ya(e,t=!0){return h(e)?e.displayName||e.name:e.name||t&&e.__name}function ba(e){return h(e)&&`__vccOpts`in e}var Y=(e,t)=>Qt(e,t,da),xa=`3.5.42`,Sa=void 0,Ca=typeof window<`u`&&window.trustedTypes;if(Ca)try{Sa=Ca.createPolicy(`vue`,{createHTML:e=>e})}catch{}var wa=Sa?e=>Sa.createHTML(e):e=>e,Ta=`http://www.w3.org/2000/svg`,Ea=`http://www.w3.org/1998/Math/MathML`,Da=typeof document<`u`?document:null,Oa=Da&&Da.createElement(`template`),ka={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{let t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,r)=>{let i=t===`svg`?Da.createElementNS(Ta,e):t===`mathml`?Da.createElementNS(Ea,e):n?Da.createElement(e,{is:n}):Da.createElement(e);return e===`select`&&r&&r.multiple!=null&&i.setAttribute(`multiple`,r.multiple),i},createText:e=>Da.createTextNode(e),createComment:e=>Da.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Da.querySelector(e),setScopeId(e,t){e.setAttribute(t,``)},insertStaticContent(e,t,n,r,i,a){let o=n?n.previousSibling:t.lastChild;if(i&&(i===a||i.nextSibling))for(;t.insertBefore(i.cloneNode(!0),n),!(i===a||!(i=i.nextSibling)););else{Oa.innerHTML=wa(r===`svg`?`<svg>${e}</svg>`:r===`mathml`?`<math>${e}</math>`:e);let i=Oa.content;if(r===`svg`||r===`mathml`){let e=i.firstChild;for(;e.firstChild;)i.appendChild(e.firstChild);i.removeChild(e)}t.insertBefore(i,n)}return[o?o.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},Aa=Symbol(`_vtc`);function ja(e,t,n){let r=e[Aa];r&&(t=(t?[t,...r]:[...r]).join(` `)),t==null?e.removeAttribute(`class`):n?e.setAttribute(`class`,t):e.className=t}var Ma=Symbol(`_vod`),Na=Symbol(`_vsh`),Pa={name:`show`,beforeMount(e,{value:t},{transition:n}){e[Ma]=e.style.display===`none`?``:e.style.display,n&&t?n.beforeEnter(e):Fa(e,t)},mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)},updated(e,{value:t,oldValue:n},{transition:r}){!t!=!n&&(r?t?(r.beforeEnter(e),Fa(e,!0),r.enter(e)):r.leave(e,()=>{Fa(e,!1)}):Fa(e,t))},beforeUnmount(e,{value:t}){Fa(e,t)}};function Fa(e,t){e.style.display=t?e[Ma]:`none`,e[Na]=!t}var Ia=Symbol(``),La=/(?:^|;)\s*display\s*:/;function Ra(e,t,n){let r=e.style,i=g(n),a=!1;if(n&&!i){if(t){if(g(t))for(let e of t.split(`;`)){let t=e.slice(0,e.indexOf(`:`)).trim();n[t]??Ba(r,t,``)}else for(let e in t)n[e]??Ba(r,e,``)}for(let i in n){i===`display`&&(a=!0);let o=n[i];o==null?Ba(r,i,``):Wa(e,i,!g(t)&&t?t[i]:void 0,o)||Ba(r,i,o)}}else if(i){if(t!==n){let e=r[Ia];e&&(n+=`;`+e),r.cssText=n,a=La.test(n)}}else t&&e.removeAttribute(`style`);Ma in e&&(e[Ma]=a?r.display:``,e[Na]&&(r.display=`none`))}var za=/\s*!important$/;function Ba(e,t,n){if(d(n))n.forEach(n=>Ba(e,t,n));else if(n??=``,t.startsWith(`--`))za.test(n)?e.setProperty(t,n.replace(za,``),`important`):e.setProperty(t,n);else{let r=Ua(e,t);za.test(n)?e.setProperty(E(r),n.replace(za,``),`important`):e[r]=n}}var Va=[`Webkit`,`Moz`,`ms`],Ha={};function Ua(e,t){let n=Ha[t];if(n)return n;let r=T(t);if(r!==`filter`&&r in e)return Ha[t]=r;r=ie(r);for(let n=0;n<Va.length;n++){let i=Va[n]+r;if(i in e)return Ha[t]=i}return t}function Wa(e,t,n,r){return e.tagName===`TEXTAREA`&&(t===`width`||t===`height`)&&g(r)&&n===r}var Ga=`http://www.w3.org/1999/xlink`;function Ka(e,t,n,r,i,a=ge(t)){r&&t.startsWith(`xlink:`)?n==null?e.removeAttributeNS(Ga,t.slice(6,t.length)):e.setAttributeNS(Ga,t,n):n==null||a&&!_e(n)?e.removeAttribute(t):e.setAttribute(t,a?``:_(n)?String(n):n)}function qa(e,t,n,r,i){if(t===`innerHTML`||t===`textContent`){n!=null&&(e[t]=t===`innerHTML`?wa(n):n);return}let a=e.tagName;if(t===`value`&&a!==`PROGRESS`&&!a.includes(`-`)){let r=a===`OPTION`?e.getAttribute(`value`)||``:e.value,i=n==null?e.type===`checkbox`?`on`:``:String(n);(r!==i||!(`_value`in e))&&(e.value=i),n??e.removeAttribute(t),e._value=n;return}let o=!1;if(n===``||n==null){let r=typeof e[t];r===`boolean`?n=_e(n):n==null&&r===`string`?(n=``,o=!0):r===`number`&&(n=0,o=!0)}try{e[t]=n}catch{}o&&e.removeAttribute(i||t)}function Ja(e,t,n,r){e.addEventListener(t,n,r)}function Ya(e,t,n,r){e.removeEventListener(t,n,r)}var Xa=Symbol(`_vei`);function Za(e,t,n,r,i=null){let a=e[Xa]||(e[Xa]={}),o=a[t];if(r&&o)o.value=r;else{let[n,s]=eo(t);r?Ja(e,n,a[t]=io(r,i),s):o&&(Ya(e,n,o,s),a[t]=void 0)}}var Qa=/(Once|Passive|Capture)$/,$a=/^on:?(?:Once|Passive|Capture)$/;function eo(e){let t,n;for(;(n=e.match(Qa))&&!$a.test(e);)t||={},e=e.slice(0,e.length-n[1].length),t[n[1].toLowerCase()]=!0;return[e[2]===`:`?e.slice(3):E(e.slice(2)),t]}var to=0,no=Promise.resolve(),ro=()=>to||=(no.then(()=>to=0),Date.now());function io(e,t){let n=e=>{if(!e._vts)e._vts=Date.now();else if(e._vts<=n.attached)return;let r=n.value;if(d(r)){let n=e.stopImmediatePropagation;e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0};let i=r.slice(),a=[e];for(let n=0;n<i.length&&!e._stopped;n++){let e=i[n];e&&sn(e,t,5,a)}}else sn(r,t,5,[e])};return n.value=e,n.attached=ro(),n}var ao=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,oo=(e,t,n,r,i,s)=>{let c=i===`svg`;t===`class`?ja(e,r,c):t===`style`?Ra(e,n,r):a(t)?o(t)||Za(e,t,n,r,s):(t[0]===`.`?(t=t.slice(1),!0):t[0]===`^`?(t=t.slice(1),!1):so(e,t,r,c))?(qa(e,t,r),!e.tagName.includes(`-`)&&(t===`value`||t===`checked`||t===`selected`)&&Ka(e,t,r,c,s,t!==`value`)):e._isVueCE&&(co(e,t)||e._def.__asyncLoader&&(/[A-Z]/.test(t)||!g(r)))?qa(e,T(t),r,s,t):(t===`true-value`?e._trueValue=r:t===`false-value`&&(e._falseValue=r),Ka(e,t,r,c))};function so(e,t,n,r){if(r)return!!(t===`innerHTML`||t===`textContent`||t in e&&ao(t)&&h(n));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`){let t=e.tagName;if(t===`IMG`||t===`VIDEO`||t===`CANVAS`||t===`SOURCE`)return!1}return ao(t)&&g(n)?!1:t in e}function co(e,t){let n=e._def.props;if(!n)return!1;let r=T(t);return Array.isArray(n)?n.some(e=>T(e)===r):Object.keys(n).some(e=>T(e)===r)}var lo=s({patchProp:oo},ka),uo;function fo(){return uo||=xi(lo)}var po=((...e)=>{let t=fo().createApp(...e),{mount:n}=t;return t.mount=e=>{let r=ho(e);if(!r)return;let i=t._component;!h(i)&&!i.render&&!i.template&&(i.template=r.innerHTML),r.nodeType===1&&(r.textContent=``);let a=n(r,!1,mo(r));return r instanceof Element&&(r.removeAttribute(`v-cloak`),r.setAttribute(`data-v-app`,``)),a},t});function mo(e){if(e instanceof SVGElement)return`svg`;if(typeof MathMLElement==`function`&&e instanceof MathMLElement)return`mathml`}function ho(e){return g(e)?document.querySelector(e):e}var go=Wn({__name:`FeedbackSpinner`,props:{size:{default:`1em`}},setup(e){let t=e,n=Y(()=>typeof t.size==`number`?`${t.size}px`:t.size);return(e,t)=>(U(),W(`span`,{class:`border-2 border-current border-t-transparent rounded-full inline-block animate-spin`,style:ue({width:n.value,height:n.value}),role:`status`,"aria-label":`Loading`},null,4))}}),_o=Wn({__name:`ActionButton`,props:{as:{},to:{},href:{},icon:{},variant:{default:`action`},size:{default:`md`},loading:{type:Boolean},disabled:{type:Boolean}},setup(e){let t=e,n=Y(()=>t.as?t.as:t.href!=null||t.to!=null?`a`:`button`),r=Y(()=>n.value===`a`),i=Y(()=>n.value===`button`),a=Y(()=>t.size===`sm`),o=Y(()=>t.variant===`primary`?a.value?`btn-primary text-sm`:`btn-primary`:t.variant===`text`?a.value?`btn-text text-sm`:`btn-text`:a.value?`btn-action-sm`:`btn-action`),s=Y(()=>t.disabled||t.loading);return(t,a)=>(U(),Vi(gr(n.value),{class:k([o.value,{"pointer-events-none op-mute":s.value&&!i.value}]),href:r.value?e.href??e.to:void 0,to:e.as&&e.to!=null?e.to:void 0,disabled:i.value?s.value:void 0,"aria-disabled":s.value||void 0,"aria-busy":e.loading||void 0},{default:Dn(()=>[e.loading?(U(),Vi(go,{key:0,size:`1em`})):e.icon?(U(),W(`span`,{key:1,class:k(e.icon),"aria-hidden":`true`},null,2)):Xi(``,!0),br(t.$slots,`default`)]),_:3},8,[`class`,`href`,`to`,`disabled`,`aria-disabled`,`aria-busy`]))}}),vo={key:0,class:`absolute inset-0 z-nav flex flex-col items-center justify-center gap-4 p-8 text-center bg-base color-base font-sans`},yo={class:`flex flex-col gap-1`},bo={class:`text-lg font-medium`},xo={class:`text-sm color-muted max-w-sm`},So={key:0,class:`mt-1 max-w-sm break-words font-mono text-xs color-faint`},Co=Wn({__name:`ConnectionOverlay`,props:{status:{},error:{}},setup(e){let t=e,n={connecting:{icon:`i-ph-plugs-connected-duotone`,title:`Connecting…`,body:`Establishing a connection to the devframe server.`},disconnected:{icon:`i-ph-plugs-duotone`,title:`Disconnected`,body:`Lost the connection to the devframe server. Reload once it is back up.`},unauthorized:{icon:`i-ph-lock-key-duotone`,title:`Not authorized`,body:`Reopen the link printed by your dev server, then reload.`},error:{icon:`i-ph-warning-octagon-duotone`,title:`Connection failed`,body:`Could not reach the devframe server.`}},r=Y(()=>n[t.status]);return(t,n)=>e.status!==`connected`&&r.value?(U(),W(`div`,vo,[G(`div`,{class:k([r.value.icon,`text-4xl color-active`])},null,2),G(`div`,yo,[G(`p`,bo,A(r.value.title),1),G(`p`,xo,A(r.value.body),1),e.error&&e.status===`error`?(U(),W(`code`,So,A(e.error),1)):Xi(``,!0)]),e.status===`connecting`?Xi(``,!0):(U(),Vi(_o,{key:0,variant:`primary`,size:`sm`,onClick:n[0]||=()=>t.location.reload()},{default:Dn(()=>[...n[1]||=[q(` Reload `,-1)]]),_:1}))])):Xi(``,!0)}}),wo=Wn({__name:`EditorFrame`,props:{connect:{},port:{}},setup(e){let t=e,n=Gt(null),r=null;function i(){return t.connect.url?t.connect.url:t.port==null?null:`${location.protocol}//${location.hostname}:${t.port}${t.connect.path??`/`}`}function a(){let e=i();if(!(!e||!n.value||e===r)){if(t.connect.cookie){let{name:e,value:n}=t.connect.cookie;document.cookie=`${e}=${n}; path=/; SameSite=Lax`}r=e,n.value.src=e}}return ar(a),Pn(()=>[t.connect,t.port],a,{deep:!0}),(e,t)=>(U(),W(`iframe`,{ref_key:`frame`,ref:n,class:`h-full w-full border-0 bg-base`,title:`Editor`,allow:`clipboard-read; clipboard-write; cross-origin-isolated`},null,512))}}),To={class:`absolute inset-0 flex items-center justify-center p-6 bg-base color-base font-sans`},Eo={class:`w-full max-w-[560px]`},Do={class:`flex items-center gap-1.5 mb-2.5 text-xs tracking-wider uppercase color-muted`},Oo={key:0,class:`flex items-center gap-2.5`},ko={class:`flex items-center gap-2.5`},Ao={class:`text-sm color-muted`},jo={key:0,class:`mt-4 px-3.5 py-3 rounded-md border border-base bg-secondary text-sm`},Mo={class:`flex flex-wrap items-center gap-x-2 gap-y-1`},No=[`href`],Po={class:`font-mono color-base px-1.5 py-0.5 rounded bg-base border border-base tracking-wider`},Fo={class:`flex flex-col gap-3 mb-5`},Io={class:`block mb-1 text-xs color-muted`},Lo={class:`flex items-center gap-2 px-2.5 py-2 rounded-md border border-base bg-secondary`},Ro={class:`flex-1 of-x-auto whitespace-nowrap font-mono text-xs color-base`},zo={class:`flex flex-wrap items-center gap-2.5`},Bo={class:`mb-5 text-sm leading-relaxed color-muted`},Vo={key:0,class:`mb-4 px-3 py-2.5 rounded-md border border-error/35 bg-error/10 text-error text-sm whitespace-pre-wrap break-words`},Ho={class:`flex flex-wrap gap-x-4 gap-y-1.5 mb-5 text-xs color-muted`},Uo={class:`font-mono color-base`},Wo={key:0},Go={class:`font-mono color-base`},Ko={key:1},qo={class:`font-mono color-base`},Jo={class:`font-mono color-base`},Yo=`https://coder.com/docs/code-server/latest/install`,Xo=`https://github.com/coder/code-server`,Zo=Wn({__name:`LauncherView`,props:{phase:{},detection:{},server:{},busy:{type:Boolean}},emits:[`launch`,`recheck`],setup(e,{emit:t}){let n=e,r=t,i=[{label:`Install script (Linux / macOS)`,command:`curl -fsSL https://code-server.dev/install.sh | sh`},{label:`npm`,command:`npm install -g code-server`},{label:`Homebrew`,command:`brew install code-server`}],a=Gt(null);function o(e){navigator.clipboard?.writeText(e).then(()=>{a.value=e,setTimeout(()=>{a.value===e&&(a.value=null)},1200)}).catch(()=>{})}let s=Y(()=>n.detection.mode===`tunnel`?`tunnel`:n.detection.backend===`ms-code-serve-web`?`code serve-web`:`code-server`),c=Y(()=>n.server.status===`error`?n.server.error:void 0);return(t,n)=>(U(),W(`div`,To,[G(`div`,Eo,[G(`p`,Do,[n[2]||=G(`span`,{class:`i-ph-code-duotone text-sm`},null,-1),G(`span`,null,A(s.value),1)]),e.phase===`connecting`?(U(),W(`div`,Oo,[K(go,{size:`1rem`,class:`color-muted`}),n[3]||=G(`span`,{class:`text-sm color-muted`},`Connecting to devframe…`,-1)])):e.phase===`starting`?(U(),W(V,{key:1},[G(`div`,ko,[K(go,{size:`1rem`,class:`color-muted`}),G(`span`,Ao,A(e.detection.mode===`tunnel`?`Opening the tunnel…`:`Starting the editor…`),1)]),e.server.login?(U(),W(`div`,jo,[n[7]||=G(`p`,{class:`mb-2 color-muted`},` Authorize the tunnel to continue: `,-1),G(`p`,Mo,[n[5]||=G(`span`,{class:`color-muted`},`Open`,-1),G(`a`,{href:e.server.login.url,target:`_blank`,rel:`noreferrer`,class:`color-active hover:underline underline-offset-2 inline-flex items-center gap-1`},[q(A(e.server.login.url)+` `,1),n[4]||=G(`span`,{class:`i-ph-arrow-square-out size-3.5`},null,-1)],8,No),n[6]||=G(`span`,{class:`color-muted`},`and enter code`,-1),G(`code`,Po,A(e.server.login.code),1)])])):Xi(``,!0)],64)):e.phase===`not-installed`?(U(),W(V,{key:2},[n[10]||=Yi(`<h1 class="mb-2 text-[1.35rem] font-semibold"> No editor found </h1><p class="mb-5 text-sm leading-relaxed color-muted"> Install <code class="font-mono color-base">code-server</code> (VS Code in the browser), or the Microsoft <code class="font-mono color-base">code</code> CLI for <code class="font-mono color-base">code serve-web</code>. Pick whichever fits your setup, then re-check. </p>`,2),G(`div`,Fo,[(U(),W(V,null,yr(i,({label:e,command:t})=>G(`div`,{key:e},[G(`label`,Io,A(e),1),G(`div`,Lo,[G(`code`,Ro,A(t),1),K(_o,{variant:`action`,size:`sm`,class:`shrink-0 text-[11px]`,onClick:e=>o(t)},{default:Dn(()=>[q(A(a.value===t?`Copied`:`Copy`),1)]),_:2},1032,[`onClick`])])])),64))]),G(`div`,zo,[K(_o,{variant:`primary`,icon:e.busy?void 0:`i-ph-arrows-clockwise`,loading:e.busy,disabled:e.busy,onClick:n[0]||=e=>r(`recheck`)},{default:Dn(()=>[q(A(e.busy?`Checking…`:`Re-check`),1)]),_:1},8,[`icon`,`loading`,`disabled`]),K(_o,{variant:`text`,size:`sm`,href:Yo,icon:`i-ph-arrow-square-out`},{default:Dn(()=>[...n[8]||=[q(` Installation docs `,-1)]]),_:1}),K(_o,{variant:`text`,size:`sm`,href:Xo,icon:`i-ph-github-logo`},{default:Dn(()=>[...n[9]||=[q(` GitHub `,-1)]]),_:1})])],64)):(U(),W(V,{key:3},[n[15]||=G(`h1`,{class:`mb-2 text-[1.35rem] font-semibold`},` Launch the editor `,-1),G(`p`,Bo,A(e.detection.mode===`tunnel`?`Open a code tunnel and edit this workspace from the hosted vscode.dev editor, right here.`:`Start an editor scoped to this workspace and open VS Code right here — signed in automatically.`),1),c.value?(U(),W(`div`,Vo,A(c.value),1)):Xi(``,!0),G(`div`,Ho,[G(`span`,null,[n[11]||=q(`mode `,-1),G(`code`,Uo,A(e.detection.mode),1)]),e.detection.mode===`local`?(U(),W(`span`,Wo,[n[12]||=q(`backend `,-1),G(`code`,Go,A(e.detection.backend),1)])):Xi(``,!0),e.detection.version?(U(),W(`span`,Ko,[n[13]||=q(`version `,-1),G(`code`,qo,A(e.detection.version),1)])):Xi(``,!0),G(`span`,null,[n[14]||=q(`binary `,-1),G(`code`,Jo,A(e.detection.bin),1)])]),K(_o,{variant:`primary`,icon:e.busy?void 0:`i-ph-rocket-launch-duotone`,loading:e.busy,disabled:e.busy,onClick:n[1]||=e=>r(`launch`)},{default:Dn(()=>[q(A(e.busy?`Starting…`:e.detection.mode===`tunnel`?`Open tunnel`:`Launch editor`),1)]),_:1},8,[`icon`,`loading`,`disabled`])],64))])]))}}),X={bus:{agentManifestChanged:`agent:manifest:changed`,agentToolRegistered:`agent:tool:registered`,agentToolUnregistered:`agent:tool:unregistered`,agentResourceRegistered:`agent:resource:registered`,agentResourceUnregistered:`agent:resource:unregistered`},client:{isTrustedUpdated:`rpc:is-trusted:updated`,error:`rpc:error`,connectionStatus:`connection:status`,connectionError:`connection:error`},broadcast:{authRevoked:`devframe:auth:revoked`,clientStateUpdated:`devframe:rpc:client-state:updated`,clientStatePatch:`devframe:rpc:client-state:patch`,streamingChunk:`devframe:streaming:chunk`,streamingEnd:`devframe:streaming:end`,streamingUploadCancel:`devframe:streaming:upload-cancel`},inPageChannel:{panelStateUpdated:`devframe:in-page:panel-state:updated`,panelStatePatch:`devframe:in-page:panel-state:patch`},postMessage:{remoteAssetsError:`devframe:remote-assets-error`,inPageChannel:`devframe:in-page-channel`}},Qo=`__connection.json`,$o=`__DEVFRAME_CONNECTION__`,es=`x-birpc-session`,ts=`__rpc-dump/index.json`,ns=`devframe:services`,rs=`devframe_otp`,is=`devframe_auth_token`;X.postMessage.remoteAssetsError;function as(e){return typeof e==`string`?`'${e}'`:new ls().serialize(e)}var os=` _-,;:!?.'"()[]{}@*/\\&#%\`^+<=>|~$0123456789abcdefghijklmnopqrstuvwxyz`,ss=(function(){let e=new Uint8Array(128);for(let t=0;t<69;t++)e[os.charCodeAt(t)]=t+1;for(let t=65;t<=90;t++)e[t]=e[t+32];return e})();function cs(e,t){if(e===t)return 0;let n=Math.min(e.length,t.length),r=0;for(let i=0;i<n;i++){let n=e.charCodeAt(i),a=t.charCodeAt(i);if(n===a)continue;let o=n<128&&ss[n]?ss[n]:n+128,s=a<128&&ss[a]?ss[a]:a+128;if(o!==s)return o<s?-1:1;r===0&&(r=n>a?-1:1)}return e.length===t.length?r:e.length<t.length?-1:1}var ls=(function(){class e{#e=new Map;compare(e,t){let n=typeof e,r=typeof t;return n===`string`&&r===`string`?cs(e,t):n===`number`&&r===`number`?e-t:cs(this.serialize(e,!0),this.serialize(t,!0))}serialize(e,t){if(e===null)return`null`;switch(typeof e){case`string`:return t?e:`'${e}'`;case`bigint`:return`${e}n`;case`object`:return this.$object(e);case`function`:return this.$function(e)}return String(e)}serializeObject(e){let t=Object.prototype.toString.call(e);if(t!==`[object Object]`)return this.serializeBuiltInType(t.length<10?`unknown:${t}`:t.slice(8,-1),e);let n=e.constructor,r=n===Object||n===void 0?``:n.name;if(r!==``&&globalThis[r]===n)return this.serializeBuiltInType(r,e);if(`toJSON`in e&&typeof e.toJSON==`function`){let t=e.toJSON();return r+(typeof t==`object`&&t?this.$object(t):`(${this.serialize(t)})`)}let i=Object.keys(e).sort(cs),a=`${r}{`;for(let t=0;t<i.length;t++){let n=i[t];a+=`${n}:${this.serialize(e[n])}`,t<i.length-1&&(a+=`,`)}return a+`}`}serializeBuiltInType(e,t){let n=this[`$`+e];if(n)return n.call(this,t);if(typeof t.entries==`function`)return this.serializeObjectEntries(e,t.entries());throw Error(`Cannot serialize ${e}`)}serializeObjectEntries(e,t){let n=Array.from(t).sort((e,t)=>this.compare(e[0],t[0])),r=`${e}{`;for(let e=0;e<n.length;e++){let[t,i]=n[e];r+=`${this.serialize(t,!0)}:${this.serialize(i)}`,e<n.length-1&&(r+=`,`)}return r+`}`}$object(e){let t=this.#e.get(e);return t===void 0&&(this.#e.set(e,`#${this.#e.size}`),t=this.serializeObject(e),this.#e.set(e,t)),t}$function(e){let t=Function.prototype.toString.call(e);return t.slice(-15)===`[native code] }`?`${e.name||``}()[native]`:`${e.name}(${e.length})${t.replace(/\s*\n\s*/g,``)}`}$Array(e){let t=`[`;for(let n=0;n<e.length;n++)t+=this.serialize(e[n]),n<e.length-1&&(t+=`,`);return t+`]`}$Date(e){try{return`Date(${e.toISOString()})`}catch{return`Date(null)`}}$ArrayBuffer(e){return`ArrayBuffer[${new Uint8Array(e).join(`,`)}]`}$Set(e){return`Set${this.$Array(Array.from(e).sort((e,t)=>this.compare(e,t)))}`}$Map(e){return this.serializeObjectEntries(`Map`,e.entries())}}for(let t of[`Error`,`RegExp`,`URL`])e.prototype[`$`+t]=function(e){return`${t}(${e})`};for(let t of[`Int8Array`,`Uint8Array`,`Uint8ClampedArray`,`Int16Array`,`Uint16Array`,`Int32Array`,`Uint32Array`,`Float32Array`,`Float64Array`])e.prototype[`$`+t]=function(e){return`${t}[${e.join(`,`)}]`};for(let t of[`BigInt64Array`,`BigUint64Array`])e.prototype[`$`+t]=function(e){return`${t}[${e.join(`n,`)}${e.length>0?`n`:``}]`};return e})(),us=[1779033703,-1150833019,1013904242,-1521486534,1359893119,-1694144372,528734635,1541459225],ds=[1116352408,1899447441,-1245643825,-373957723,961987163,1508970993,-1841331548,-1424204075,-670586216,310598401,607225278,1426881987,1925078388,-2132889090,-1680079193,-1046744716,-459576895,-272742522,264347078,604807628,770255983,1249150122,1555081692,1996064986,-1740746414,-1473132947,-1341970488,-1084653625,-958395405,-710438585,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,-2117940946,-1838011259,-1564481375,-1474664885,-1035236496,-949202525,-778901479,-694614492,-200395387,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,-2067236844,-1933114872,-1866530822,-1538233109,-1090935817,-965641998],fs=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_`,ps=[],ms=class{_data=new hs;_hash=new hs([...us]);_nDataBytes=0;_minBufferSize=0;finalize(e){e&&this._append(e);let t=this._nDataBytes*8,n=this._data.sigBytes*8;return this._data.words[n>>>5]|=128<<24-n%32,this._data.words[(n+64>>>9<<4)+14]=Math.floor(t/4294967296),this._data.words[(n+64>>>9<<4)+15]=t,this._data.sigBytes=this._data.words.length*4,this._process(),this._hash}_doProcessBlock(e,t){let n=this._hash.words,r=n[0],i=n[1],a=n[2],o=n[3],s=n[4],c=n[5],l=n[6],u=n[7];for(let n=0;n<64;n++){if(n<16)ps[n]=e[t+n]|0;else{let e=ps[n-15],t=(e<<25|e>>>7)^(e<<14|e>>>18)^e>>>3,r=ps[n-2],i=(r<<15|r>>>17)^(r<<13|r>>>19)^r>>>10;ps[n]=t+ps[n-7]+i+ps[n-16]}let d=s&c^~s&l,f=r&i^r&a^i&a,p=(r<<30|r>>>2)^(r<<19|r>>>13)^(r<<10|r>>>22),m=(s<<26|s>>>6)^(s<<21|s>>>11)^(s<<7|s>>>25),h=u+m+d+ds[n]+ps[n],g=p+f;u=l,l=c,c=s,s=o+h|0,o=a,a=i,i=r,r=h+g|0}n[0]=n[0]+r|0,n[1]=n[1]+i|0,n[2]=n[2]+a|0,n[3]=n[3]+o|0,n[4]=n[4]+s|0,n[5]=n[5]+c|0,n[6]=n[6]+l|0,n[7]=n[7]+u|0}_append(e){typeof e==`string`&&(e=hs.fromUtf8(e)),this._data.concat(e),this._nDataBytes+=e.sigBytes}_process(e){let t,n=this._data.sigBytes/64;n=e?Math.ceil(n):Math.max((n|0)-this._minBufferSize,0);let r=n*16,i=Math.min(r*4,this._data.sigBytes);if(r){for(let e=0;e<r;e+=16)this._doProcessBlock(this._data.words,e);t=this._data.words.splice(0,r),this._data.sigBytes-=i}return new hs(t,i)}},hs=class e{words;sigBytes;constructor(e,t){e=this.words=e||[],this.sigBytes=t===void 0?e.length*4:t}static fromUtf8(t){let n=unescape(encodeURIComponent(t)),r=n.length,i=[];for(let e=0;e<r;e++)i[e>>>2]|=(n.charCodeAt(e)&255)<<24-e%4*8;return new e(i,r)}toBase64(){let e=[];for(let t=0;t<this.sigBytes;t+=3){let n=this.words[t>>>2]>>>24-t%4*8&255,r=this.words[t+1>>>2]>>>24-(t+1)%4*8&255,i=this.words[t+2>>>2]>>>24-(t+2)%4*8&255,a=n<<16|r<<8|i;for(let n=0;n<4&&t*8+n*6<this.sigBytes*8;n++)e.push(fs.charAt(a>>>6*(3-n)&63))}return e.join(``)}concat(e){if(this.words[this.sigBytes>>>2]&=4294967295<<32-this.sigBytes%4*8,this.words.length=Math.ceil(this.sigBytes/4),this.sigBytes%4)for(let t=0;t<e.sigBytes;t++){let n=e.words[t>>>2]>>>24-t%4*8&255;this.words[this.sigBytes+t>>>2]|=n<<24-(this.sigBytes+t)%4*8}else for(let t=0;t<e.sigBytes;t+=4)this.words[this.sigBytes+t>>>2]=e.words[t>>>2];this.sigBytes+=e.sigBytes}};function gs(e){return new ms().finalize(e).toBase64()}function _s(e){return gs(as(e))}function vs(e){return _s(e)}var ys=class{cacheMap=new Map;options;keySerializer;constructor(e){this.options=e,this.keySerializer=e.keySerializer||(e=>vs(e))}updateOptions(e){this.options={...this.options,...e}}cached(e,t){let n=this.cacheMap.get(e);if(n)return n.get(this.keySerializer(t))}has(e,t){return this.cacheMap.get(e)?.has(this.keySerializer(t))??!1}apply(e,t){let n=this.cacheMap.get(e.m)||new Map;n.set(this.keySerializer(e.a),t),this.cacheMap.set(e.m,n)}validate(e){return this.options.functions.includes(e)}clear(e){e?this.cacheMap.delete(e):this.cacheMap.clear()}};function bs(e,t){let n=`\x1B[${e}m`,r=`\x1B[${t}m`;return((e,...t)=>{if(Array.isArray(e)&&`raw`in e){let i=e,a=``;for(let e=0;e<i.length;e++)a+=i[e],e<t.length&&(a+=String(t[e]));return`${n}${a}${r}`}return`${n}${String(e)}${r}`})}var xs={blue:bs(34,39),cyan:bs(36,39),gray:bs(90,39),green:bs(32,39),red:bs(31,39),yellow:bs(33,39),bold:bs(1,22),dim:bs(2,22),reset:bs(0,0),underline:bs(4,24)};function Ss(e,...t){return typeof e==`function`?e(...t):e}var Cs=Error.captureStackTrace,ws=class e extends Error{name;code;docs;fix;sources;get why(){return this.message}constructor(t,n=e){super(t.why,{cause:t.cause}),this.code=this.name=t.code,this.fix=t.fix,this.docs=t.docs,this.sources=t.sources,Cs?.(this,n)}toJSON(){return{name:this.name,why:this.why,fix:this.fix,docs:this.docs,sources:this.sources,cause:this.cause,stack:this.stack}}};function Ts(e,t){return typeof e==`string`?`${e}/${t.toLowerCase()}`:e?.(t)}function Es(e){let t=e.reporters??[],n={},{docsBase:r}=e;for(let i of Object.keys(e.codes)){let a=e.codes[i],o=a.docs===!1?void 0:a.docs||Ts(r,i),s=(e={},n={})=>{let r=new ws({code:i,why:Ss(a.why,e),fix:Ss(a.fix,e),docs:o,cause:e.cause,sources:e.sources},s);for(let e of t)e(r,n);return r};n[i]=s}return n}function Ds(e){return t=>{let n=`${e.bold(e.red(`[${t.name}]`))} ${t.message}`,r=[];return t.fix&&r.push(`${e.dim(`fix:`)} ${t.fix}`),t.sources?.length&&r.push(`${e.dim(`sources:`)} ${t.sources.join(`, `)}`),t.docs&&r.push(`${e.dim(`see:`)} ${e.cyan(t.docs)}`),r.length===0?n:[n,...r.map((t,n)=>`${e.dim(n<r.length-1?`├▶`:`╰▶`)} ${t}`)].join(`
2
- `)}}var Os=Ds(xs);function ks(e,{method:t=`warn`}={}){console[t](Os(e))}function As(e){return Es({...e,reporters:[ks,...e.reporters??[]]})}var js=As({docsBase:`https://devfra.me/errors`,codes:{DF0019:{why:e=>`RPC function "${e.name}" has \`agent\` set but \`jsonSerializable\` is not \`true\` — MCP requires JSON-serializable data.`,fix:"Set `jsonSerializable: true` if the payload is JSON-safe, or remove `agent` to keep it RPC-only."},DF0020:{why:e=>`RPC function "${e.name}" declares \`jsonSerializable: true\` but the value at "${e.path}" is a ${e.type}.`,fix:"Either drop `jsonSerializable: true` (falls back to structured-clone) or change the value to a JSON-safe shape."},DF0021:{why:e=>`RPC function "${e.name}" is already registered`,fix:"Use the `force` parameter to overwrite an existing registration."},DF0022:{why:e=>`RPC function "${e.name}" is not registered. Use register() to add new functions.`},DF0023:{why:e=>`RPC function "${e.name}" is not registered`},DF0024:{why:e=>`Either handler or setup function must be provided for RPC function "${e.name}"`},DF0025:{why:e=>`Function "${e.name}" not found in dump store`},DF0026:{why:e=>`No dump match for "${e.name}" with args: ${e.args}`},DF0027:{why:e=>`Function "${e.name}" with type "${e.type}" cannot have dump configuration. Only "static" and "query" types support dumps.`},DF0028:{why:e=>`Function "${e.name}" with type "${e.type}" cannot use \`snapshot: true\`. Only "query" functions support this sugar; "static" functions have equivalent default behavior already.`,fix:"Remove `snapshot: true`, or change the function type to `query`."},DF0043:{why:e=>`RPC function "${e.name}" received an invalid argument at position ${e.index}: ${e.issues}`,fix:"Pass a value that satisfies the `args` schema declared for this function."},DF0044:{why:e=>`RPC function "${e.name}" returned a value that failed its \`returns\` schema: ${e.issues}`,fix:"Make the handler return a value that satisfies the `returns` schema, or relax the schema."}}});async function Ms(e,t){let n=e[`~standard`].validate(t);return n instanceof Promise?await n:n}function Ns(e){return e.map(e=>{let t=e.path?.map(e=>typeof e==`object`?e.key:e).join(`.`);return t?`${t}: ${e.message}`:e.message}).join(`; `)}async function Ps(e,t,n){let r=n.slice();if(!t||t.length===0)return r;for(let r=0;r<t.length;r++){let i=t[r];if(!i)continue;let a=await Ms(i,n[r]);if(a.issues)throw js.DF0043({name:e,index:r,issues:Ns(a.issues)})}return r}async function Fs(e,t,n){if(!t)return n;let r=await Ms(t,n);if(r.issues)throw js.DF0044({name:e,issues:Ns(r.issues)});return n}async function Is(e,t){if(!e.setup)return{};if(typeof t==`object`&&t){e.__cache??=new WeakMap;let n=e.__cache,r=n.get(t);return r||(r=Promise.resolve(e.setup(t)),r.catch(()=>{n.get(t)===r&&n.delete(t)}),n.set(t,r)),await r}if(!e.__promise){let n=Promise.resolve(e.setup(t));n.catch(()=>{e.__promise===n&&(e.__promise=void 0)}),e.__promise=n}return await e.__promise}async function Ls(e,t){let n=e.handler;if(!n){let r=await Is(e,t);if(!r.handler)throw js.DF0024({name:e.name});n=r.handler}let r=e.args,i=e.returns;if(!r&&!i)return n;let a=n;return async(...t)=>{let n=await Ps(e.name,r,t),o=await a(...n);return await Fs(e.name,i,o)}}var Rs=class{context;definitions=new Map;functions;_onChanged=[];constructor(e){this.context=e;let t=this.definitions,n=this;this.functions=new Proxy({},{get(e,r){let i=t.get(r);if(i)return Ls(i,n.context)},has(e,n){return t.has(n)},getOwnPropertyDescriptor(e,n){return{value:t.get(n)?.handler,configurable:!0,enumerable:!0}},ownKeys(){return Array.from(t.keys())}})}register(e,t=!1){if(this.definitions.has(e.name)&&!t)throw js.DF0021({name:e.name});zs(e),this.definitions.set(e.name,e),this._onChanged.forEach(t=>t(e.name))}update(e,t=!1){if(!this.definitions.has(e.name)&&!t)throw js.DF0022({name:e.name});zs(e),this.definitions.set(e.name,e),this._onChanged.forEach(t=>t(e.name))}onChanged(e){return this._onChanged.push(e),()=>{let t=this._onChanged.indexOf(e);t!==-1&&this._onChanged.splice(t,1)}}async getHandler(e){return await Ls(this.definitions.get(e),this.context)}getSchema(e){let t=this.definitions.get(e);if(!t)throw js.DF0023({name:String(e)});return{args:t.args,returns:t.returns}}has(e){return this.definitions.has(e)}get(e){return this.definitions.get(e)}list(){return Array.from(this.definitions.keys())}};function zs(e){if(e.agent&&e.jsonSerializable!==!0)throw js.DF0019({name:e.name})}function Bs(e,t=``){return JSON.stringify(e,function(e,n){let r=this,i=r==null?n:r[e];if(i===void 0){if(Array.isArray(r))throw Vs(t,`undefined`,r,e);return n}if(i===null)return n;if(typeof i==`bigint`)throw Vs(t,`BigInt`,r,e);if(typeof i==`object`){if(i instanceof Map)throw Vs(t,`Map`,r,e);if(i instanceof Set)throw Vs(t,`Set`,r,e);if(i instanceof Date)throw Vs(t,`Date`,r,e);if(Array.isArray(i))return n;let a=Object.getPrototypeOf(i);if(a!==null&&a!==Object.prototype)throw Vs(t,i.constructor?.name??`class instance`,r,e)}return n})}function Vs(e,t,n,r){let i=Hs(n,r);return js.DF0020({name:e||`<anonymous>`,type:t,path:i})}function Hs(e,t){return Array.isArray(e)?`[${t}]`:t===``?`<root>`:t}function Us(){let e={};function t(t,...n){let r=e[t]||[];for(let e=0,t=r.length;e<t;e++){let t=r[e];t&&t(...n)}}function n(n,...r){t(n,...r),delete e[n]}function r(t,n){return(e[t]||=[]).push(n),()=>{e[t]=e[t]?.filter(e=>n!==e)}}function i(e,t){let n=r(e,((...e)=>(n(),t(...e))));return n}return{_listeners:e,emit:t,emitOnce:n,on:r,once:i}}String.fromCharCode;var Ws=/^[\s\w\0+.-]{2,}:([/\\]{1,2})/,Gs=/^[\s\w\0+.-]{2,}:([/\\]{2})?/,Ks=/^([/\\]\s*){2,}[^/\\]/,qs=/\/$|\/\?|\/#/,Js=/^\.?\//;function Ys(e,t={}){return typeof t==`boolean`&&(t={acceptRelative:t}),t.strict?Ws.test(e):Gs.test(e)||(t.acceptRelative?Ks.test(e):!1)}function Xs(e=``,t){return t?qs.test(e):e.endsWith(`/`)}function Zs(e=``,t){if(!t)return(Xs(e)?e.slice(0,-1):e)||`/`;if(!Xs(e,!0))return e||`/`;let n=e,r=``,i=e.indexOf(`#`);i!==-1&&(n=e.slice(0,i),r=e.slice(i));let[a,...o]=n.split(`?`);return((a.endsWith(`/`)?a.slice(0,-1):a)||`/`)+(o.length>0?`?${o.join(`?`)}`:``)+r}function Qs(e=``,t){if(!t)return e.endsWith(`/`)?e:e+`/`;if(Xs(e,!0))return e||`/`;let n=e,r=``,i=e.indexOf(`#`);if(i!==-1&&(n=e.slice(0,i),r=e.slice(i),!n))return r;let[a,...o]=n.split(`?`);return a+`/`+(o.length>0?`?${o.join(`?`)}`:``)+r}function $s(e,t){if(ec(t)||Ys(e))return e;let n=Zs(t);if(e.startsWith(n)){let t=e[n.length];if(!t||t===`/`||t===`?`)return e}return nc(n,e)}function ec(e){return!e||e===`/`}function tc(e){return e&&e!==`/`}function nc(e,...t){let n=e||``;for(let e of t.filter(e=>tc(e)))if(n){let t=e.replace(Js,``);n=Qs(n)+t}else n=e;return n}function rc(e,t){let n=e.match(Gs);return n||=e.match(/^\/{2,}/),n?t+e.slice(n[0].length):t+e}var ic=`__DEVFRAME_CONNECTION_META__`,ac=`__DEVFRAME_CONNECTION_AUTH_TOKEN__`;function oc(e){let t=[()=>window?.[e],()=>globalThis?.[e],()=>parent.window?.[e]];for(let e of t)try{let t=e();if(t)return t}catch{}}function sc(){return oc($o)}function cc(){return oc(ic)}function lc(e){if(e)return e;try{let e=localStorage.getItem(ac);if(e)return e}catch{}return oc(ac)}function uc(e){globalThis[$o]=e,globalThis[ic]={...e.connectionMeta,baseUrl:e.metaBaseUrl},e.authToken&&dc(e.authToken)}function dc(e){try{localStorage.setItem(ac,e)}catch{}globalThis[ac]=e;let t=sc();t&&(globalThis[$o]={...t,authToken:e})}function fc(e){let t=$s(Qo,e);try{return new URL(t,globalThis.location?.href).href}catch{return t}}function pc(e,t){return t&&t!==e.authToken?{...e,authToken:t}:e}function mc(){let e=sc();if(e)return pc(e,lc()??e.authToken??e.connectionMeta.authToken);let t=cc();if(t)return{connectionMeta:t,metaBaseUrl:t.baseUrl??fc(`./`),authToken:lc(t.authToken)}}async function hc(e={}){if(e.connection){let t=pc(e.connection,lc(e.authToken??e.connection.authToken??e.connection.connectionMeta.authToken));return uc(t),t}let t=Array.isArray(e.baseURL)?e.baseURL:[e.baseURL??`./`];if(e.connectionMeta){let n={connectionMeta:e.connectionMeta,metaBaseUrl:fc(t[0]??`./`),authToken:lc(e.authToken??e.connectionMeta.authToken)};return uc(n),n}let n=mc();if(n){let t=pc(n,lc(e.authToken??n.authToken??n.connectionMeta.authToken));return uc(t),t}let r=[];for(let n of t){let t=$s(Qo,n),i=fc(n);try{let n=await fetch(t);if(!n.ok)throw Error(`Failed to fetch connection meta from ${i}: ${n.status}`);let r=await n.json(),a={connectionMeta:r,metaBaseUrl:n.url||i,authToken:lc(e.authToken??r.authToken)};return uc(a),a}catch(e){r.push(e)}}throw Error(`Failed to get connection meta from ${t.join(`, `)}`,{cause:r})}var gc=class extends Error{name=`DevframeConnectionError`;kind;constructor(e,t,n){super(t,n),this.kind=e}};function _c(e=rs){try{let t=globalThis.location?.hash?.replace(/^#/,``)??``;return new URLSearchParams(t).get(e)||void 0}catch{return}}function vc(e){try{let t=new URL(globalThis.location.href),n=new URLSearchParams(t.hash.replace(/^#/,``));if(!n.has(e))return;n.delete(e),t.hash=n.toString(),globalThis.history?.replaceState(globalThis.history.state,``,t.href)}catch{}}function yc(e=rs){let t=_c(e);return t&&vc(e),t}async function bc(e,t={}){let n=yc(t.param??`devframe_otp`);return n?e.isTrusted?!0:e.requestTrustWithCode(n):!1}function xc(e){let t={},n=new WeakMap,r,i=()=>(r??=e.sharedState.get(ns,{initialValue:{}}).then(e=>(t=e.value(),e.on(`updated`,e=>{t=e}),e)),r);return i(),{state:i,has:e=>e in t,keys:()=>Object.keys(t),get:r=>{let i=t[r];if(!i)return;let a=n.get(i);return a||(a={...i,rpc:e.scope(i.scope).rpc},n.set(i,a)),a}}}var Sc=Symbol.for(`immer-nothing`),Cc=Symbol.for(`immer-draftable`),Z=Symbol.for(`immer-state`);function Q(e,...t){throw Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var $=Object,wc=$.getPrototypeOf,Tc=`constructor`,Ec=`prototype`,Dc=`configurable`,Oc=`enumerable`,kc=`writable`,Ac=`value`,jc=e=>!!e&&!!e[Z];function Mc(e){return e?Fc(e)||Hc(e)||!!e[Cc]||!!e[Tc]?.[Cc]||Uc(e)||Wc(e):!1}var Nc=$[Ec][Tc].toString(),Pc=new WeakMap;function Fc(e){if(!e||!Gc(e))return!1;let t=wc(e);if(t===null||t===$[Ec])return!0;let n=$.hasOwnProperty.call(t,Tc)&&t[Tc];if(n===Object)return!0;if(!Kc(n))return!1;let r=Pc.get(n);return r===void 0&&(r=Function.toString.call(n),Pc.set(n,r)),r===Nc}function Ic(e,t,n=!0){Lc(e)===0?(n?Reflect.ownKeys(e):$.keys(e)).forEach(n=>{t(n,e[n],e)}):e.forEach((n,r)=>t(r,n,e))}function Lc(e){let t=e[Z];return t?t.type_:Hc(e)?1:Uc(e)?2:Wc(e)?3:0}var Rc=(e,t,n=Lc(e))=>n===2?e.has(t):$[Ec].hasOwnProperty.call(e,t),zc=(e,t,n=Lc(e))=>n===2?e.get(t):e[t],Bc=(e,t,n,r=Lc(e))=>{r===2?e.set(t,n):r===3?e.add(n):e[t]=n};function Vc(e,t){return e===t?e!==0||1/e==1/t:e!==e&&t!==t}var Hc=Array.isArray,Uc=e=>e instanceof Map,Wc=e=>e instanceof Set,Gc=e=>typeof e==`object`,Kc=e=>typeof e==`function`,qc=e=>typeof e==`boolean`;function Jc(e){let t=+e;return Number.isInteger(t)&&String(t)===e}var Yc=e=>Gc(e)?e?.[Z]:null,Xc=e=>e.copy_||e.base_,Zc=e=>e.modified_?e.copy_:e.base_;function Qc(e,t){if(Uc(e))return new Map(e);if(Wc(e))return new Set(e);if(Hc(e))return Array[Ec].slice.call(e);let n=Fc(e);if(t===!0||t===`class_only`&&!n){let t=$.getOwnPropertyDescriptors(e);delete t[Z];let n=Reflect.ownKeys(t);for(let r=0;r<n.length;r++){let i=n[r],a=t[i];a[kc]===!1&&(a[kc]=!0,a[Dc]=!0),(a.get||a.set)&&(t[i]={[Dc]:!0,[kc]:!0,[Oc]:a[Oc],[Ac]:e[i]})}return $.create(wc(e),t)}{let t=wc(e);if(t!==null&&n)return{...e};let r=$.create(t);return $.assign(r,e)}}function $c(e,t=!1){return nl(e)||jc(e)||!Mc(e)?e:(Lc(e)>1&&$.defineProperties(e,{set:tl,add:tl,clear:tl,delete:tl}),$.freeze(e),t&&Ic(e,(e,t)=>{$c(t,!0)},!1),e)}function el(){Q(2)}var tl={[Ac]:el};function nl(e){return e===null||!Gc(e)||$.isFrozen(e)}var rl=`MapSet`,il=`Patches`,al=`ArrayMethods`,ol={};function sl(e){let t=ol[e];return t||Q(0,e),t}var cl=e=>!!ol[e];function ll(e,t){ol[e]||(ol[e]=t)}var ul,dl=()=>ul,fl=(e,t)=>({drafts_:[],parent_:e,immer_:t,canAutoFreeze_:!0,unfinalizedDrafts_:0,handledSet_:new Set,processedForPatches_:new Set,mapSetPlugin_:cl(rl)?sl(rl):void 0,arrayMethodsPlugin_:cl(al)?sl(al):void 0});function pl(e,t){t&&(e.patchPlugin_=sl(il),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function ml(e){hl(e),e.drafts_.forEach(_l),e.drafts_=null}function hl(e){e===ul&&(ul=e.parent_)}var gl=e=>ul=fl(ul,e);function _l(e){let t=e[Z];t.type_===0||t.type_===1?t.revoke_():t.revoked_=!0}function vl(e,t){t.unfinalizedDrafts_=t.drafts_.length;let n=t.drafts_[0];if(e!==void 0&&e!==n){n[Z].modified_&&(ml(t),Q(4)),Mc(e)&&(e=yl(t,e));let{patchPlugin_:r}=t;r&&r.generateReplacementPatches_(n[Z].base_,e,t)}else e=yl(t,n);return bl(t,e,!0),ml(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e===Sc?void 0:e}function yl(e,t){if(nl(t))return t;let n=t[Z];if(!n)return Ol(t,e.handledSet_,e);if(!Sl(n,e))return t;if(!n.modified_)return n.base_;if(!n.finalized_){let{callbacks_:t}=n;if(t)for(;t.length>0;)t.pop()(e);El(n,e)}return n.copy_}function bl(e,t,n=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&$c(t,n)}function xl(e){e.finalized_=!0,e.scope_.unfinalizedDrafts_--}var Sl=(e,t)=>e.scope_===t,Cl=[];function wl(e,t,n,r){let i=Xc(e),a=e.type_;if(r!==void 0&&zc(i,r,a)===t){Bc(i,r,n,a);return}if(!e.draftLocations_){let t=e.draftLocations_=new Map;Ic(i,(e,n)=>{if(jc(n)){let r=t.get(n)||[];r.push(e),t.set(n,r)}})}let o=e.draftLocations_.get(t)??Cl;for(let e of o)Bc(i,e,n,a)}function Tl(e,t,n){e.callbacks_.push(function(r){let i=t;if(!i||!Sl(i,r))return;r.mapSetPlugin_?.fixSetContents(i);let a=Zc(i);wl(e,i.draft_??i,a,n),El(i,r)})}function El(e,t){if(e.modified_&&!e.finalized_&&(e.type_===3||e.type_===1&&e.allIndicesReassigned_||(e.assigned_?.size??0)>0)){let{patchPlugin_:n}=t;if(n){let r=n.getPath(e);r&&n.generatePatches_(e,r,t)}xl(e)}}function Dl(e,t,n){let{scope_:r}=e;if(jc(n)){let i=n[Z];Sl(i,r)&&i.callbacks_.push(function(){Ll(e),wl(e,n,Zc(i),t)})}else Mc(n)&&e.callbacks_.push(function(){let i=Xc(e);e.type_===3?i.has(n)&&Ol(n,r.handledSet_,r):zc(i,t,e.type_)===n&&r.drafts_.length>1&&(e.assigned_.get(t)??!1)===!0&&e.copy_&&Ol(zc(e.copy_,t,e.type_),r.handledSet_,r)})}function Ol(e,t,n){return!n.immer_.autoFreeze_&&n.unfinalizedDrafts_<1||jc(e)||t.has(e)||!Mc(e)||nl(e)?e:(t.add(e),Ic(e,(r,i)=>{if(jc(i)){let t=i[Z];Sl(t,n)&&(Bc(e,r,Zc(t),e.type_),xl(t))}else Mc(i)&&Ol(i,t,n)}),e)}function kl(e,t){let n=Hc(e),r={type_:+!!n,scope_:t?t.scope_:dl(),modified_:!1,finalized_:!1,assigned_:void 0,parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1,callbacks_:void 0},i=r,a=Al;n&&(i=[r],a=jl);let{revoke:o,proxy:s}=Proxy.revocable(i,a);return r.draft_=s,r.revoke_=o,[s,r]}var Al={get(e,t){if(t===Z)return e;let n=e.scope_.arrayMethodsPlugin_,r=e.type_===1&&typeof t==`string`;if(r&&n?.isArrayOperationMethod(t))return n.createMethodInterceptor(e,t);let i=Xc(e);if(!Rc(i,t,e.type_))return Pl(e,i,t);let a=i[t];if(e.finalized_||!Mc(a)||r&&e.operationMethod&&n?.isMutatingArrayMethod(e.operationMethod)&&Jc(t))return a;if(a===Ml(e.base_,t)||Nl(e,t,a)){Ll(e);let n=e.type_===1?+t:t,r=zl(e.scope_,a,e,n);return e.copy_[n]=r}return a},has(e,t){return t in Xc(e)},ownKeys(e){return Reflect.ownKeys(Xc(e))},set(e,t,n){let r=Fl(Xc(e),t);if(r?.set)return r.set.call(e.draft_,n),!0;if(!e.modified_){let r=Ml(Xc(e),t),i=r?.[Z];if(i&&i.base_===n)return e.copy_[t]=n,e.assigned_.set(t,!1),!0;if(Vc(n,r)&&(n!==void 0||Rc(e.base_,t,e.type_)))return!0;Ll(e),Il(e)}return e.copy_[t]===n&&(n!==void 0||Rc(e.copy_,t,e.type_))||Number.isNaN(n)&&Number.isNaN(e.copy_[t])?!0:(e.copy_[t]=n,e.assigned_.set(t,!0),Dl(e,t,n),!0)},deleteProperty(e,t){return Ll(e),Ml(e.base_,t)!==void 0||t in e.base_?(e.assigned_.set(t,!1),Il(e)):e.assigned_.delete(t),e.copy_&&delete e.copy_[t],!0},getOwnPropertyDescriptor(e,t){let n=Xc(e),r=Reflect.getOwnPropertyDescriptor(n,t);return r&&{[kc]:!0,[Dc]:e.type_!==1||t!==`length`,[Oc]:r[Oc],[Ac]:n[t]}},defineProperty(){Q(11)},getPrototypeOf(e){return wc(e.base_)},setPrototypeOf(){Q(12)}},jl={};for(let e in Al){let t=Al[e];jl[e]=function(){let e=arguments;return e[0]=e[0][0],t.apply(this,e)}}jl.deleteProperty=function(e,t){return jl.set.call(this,e,t,void 0)},jl.set=function(e,t,n){return Al.set.call(this,e[0],t,n,e[0])};function Ml(e,t){let n=e[Z];return(n?Xc(n):e)[t]}function Nl(e,t,n){return e.type_!==1||!e.allIndicesReassigned_||e.assigned_?.get(t)||!Mc(n)||n[Z]?!1:e.baseRefs_.has(n)}function Pl(e,t,n){let r=Fl(t,n);return r?Ac in r?r[Ac]:r.get?.call(e.draft_):void 0}function Fl(e,t){if(!(t in e))return;let n=wc(e);for(;n;){let e=Object.getOwnPropertyDescriptor(n,t);if(e)return e;n=wc(n)}}function Il(e){e.modified_||(e.modified_=!0,e.parent_&&Il(e.parent_))}function Ll(e){e.copy_||=(e.assigned_=new Map,Qc(e.base_,e.scope_.immer_.useStrictShallowCopy_))}var Rl=class{constructor(e){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.useStrictIteration_=!1,this.produce=(e,t,n)=>{if(Kc(e)&&!Kc(t)){let n=t;t=e;let r=this;return function(e=n,...i){return r.produce(e,e=>t.call(this,e,...i))}}Kc(t)||Q(6),n!==void 0&&!Kc(n)&&Q(7);let r;if(Mc(e)){let i=gl(this),a=zl(i,e,void 0),o=!0;try{r=t(a),o=!1}finally{o?ml(i):hl(i)}return pl(i,n),vl(r,i)}if(!e||!Gc(e)){if(r=t(e),r===void 0&&(r=e),r===Sc&&(r=void 0),this.autoFreeze_&&$c(r,!0),n){let t=[],i=[];sl(il).generateReplacementPatches_(e,r,{patches_:t,inversePatches_:i}),n(t,i)}return r}Q(1,e)},this.produceWithPatches=(e,t)=>{if(Kc(e))return(t,...n)=>this.produceWithPatches(t,t=>e(t,...n));let n,r;return[this.produce(e,t,(e,t)=>{n=e,r=t}),n,r]},qc(e?.autoFreeze)&&this.setAutoFreeze(e.autoFreeze),qc(e?.useStrictShallowCopy)&&this.setUseStrictShallowCopy(e.useStrictShallowCopy),qc(e?.useStrictIteration)&&this.setUseStrictIteration(e.useStrictIteration)}createDraft(e){Mc(e)||Q(8),jc(e)&&(e=Bl(e));let t=gl(this),n=zl(t,e,void 0);return n[Z].isManual_=!0,hl(t),n}finishDraft(e,t){let n=e&&e[Z];(!n||!n.isManual_)&&Q(9);let{scope_:r}=n;return pl(r,t),vl(void 0,r)}setAutoFreeze(e){this.autoFreeze_=e}setUseStrictShallowCopy(e){this.useStrictShallowCopy_=e}setUseStrictIteration(e){this.useStrictIteration_=e}shouldUseStrictIteration(){return this.useStrictIteration_}applyPatches(e,t){let n;for(n=t.length-1;n>=0;n--){let r=t[n];if(r.path.length===0&&r.op===`replace`){e=r.value;break}}n>-1&&(t=t.slice(n+1));let r=sl(il).applyPatches_;return jc(e)?r(e,t):this.produce(e,e=>r(e,t))}};function zl(e,t,n,r){let[i,a]=Uc(t)?sl(rl).proxyMap_(t,n):Wc(t)?sl(rl).proxySet_(t,n):kl(t,n);return(n?.scope_??dl()).drafts_.push(i),a.callbacks_=n?.callbacks_??[],a.key_=r,n&&r!==void 0?Tl(n,a,r):a.callbacks_.push(function(e){e.mapSetPlugin_?.fixSetContents(a);let{patchPlugin_:t}=e;a.modified_&&t&&t.generatePatches_(a,[],e)}),i}function Bl(e){return jc(e)||Q(10,e),Vl(e)}function Vl(e){if(!Mc(e)||nl(e))return e;let t=e[Z],n,r=!0;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,n=Qc(e,t.scope_.immer_.useStrictShallowCopy_),r=t.scope_.immer_.shouldUseStrictIteration()}else n=Qc(e,!0);return Ic(n,(e,t)=>{Bc(n,e,Vl(t))},r),t&&(t.finalized_=!1),n}function Hl(){function e(n,r=[]){if(n.key_!==void 0){let e=n.parent_.copy_??n.parent_.base_,t=Yc(zc(e,n.key_)),i=zc(e,n.key_);if(i===void 0||i!==n.draft_&&i!==n.base_&&i!==n.copy_||t!=null&&t.base_!==n.base_)return null;let a=n.parent_.type_===3,o;if(a){let e=n.parent_;o=Array.from(e.drafts_.keys()).indexOf(n.key_)}else o=n.key_;if(!(a&&e.size>o||Rc(e,o)))return null;r.push(o)}if(n.parent_)return e(n.parent_,r);r.reverse();try{t(n.copy_,r)}catch{return null}return r}function t(e,t){let n=e;for(let e=0;e<t.length-1;e++){let r=t[e];if(n=zc(n,r),!Gc(n)||n===null)throw Error(`Cannot resolve path at '${t.join(`/`)}'`)}return n}let n=`replace`,r=`remove`;function i(e,t,n){if(e.scope_.processedForPatches_.has(e))return;e.scope_.processedForPatches_.add(e);let{patches_:r,inversePatches_:i}=n;switch(e.type_){case 0:case 2:return o(e,t,r,i);case 1:return a(e,t,r,i);case 3:return s(e,t,r,i)}}function a(e,t,i,a){let{base_:o,assigned_:s}=e,c=e.copy_;c.length<o.length&&([o,c]=[c,o],[i,a]=[a,i]);let l=e.allIndicesReassigned_===!0;for(let e=0;e<o.length;e++){let r=c[e],u=o[e];if((l||s?.get(e.toString()))&&r!==u){let o=r?.[Z];if(o&&o.modified_)continue;let s=t.concat([e]);i.push({op:n,path:s,value:d(r)}),a.push({op:n,path:s,value:d(u)})}}for(let e=o.length;e<c.length;e++){let n=t.concat([e]);i.push({op:`add`,path:n,value:d(c[e])})}for(let e=c.length-1;o.length<=e;--e){let n=t.concat([e]);a.push({op:r,path:n})}}function o(e,t,i,a){let{base_:o,copy_:s,type_:c}=e;Ic(e.assigned_,(e,l)=>{let u=zc(o,e,c),f=zc(s,e,c),p=l?Rc(o,e)?n:`add`:r;if(u===f&&p===n)return;let m=t.concat(e);i.push(p===r?{op:p,path:m}:{op:p,path:m,value:d(f)}),a.push(p===`add`?{op:r,path:m}:p===r?{op:`add`,path:m,value:d(u)}:{op:n,path:m,value:d(u)})})}function s(e,t,n,i){let{base_:a,copy_:o}=e,s=0;a.forEach(e=>{if(!o.has(e)){let a=t.concat([s]);n.push({op:r,path:a,value:e}),i.unshift({op:`add`,path:a,value:e})}s++}),s=0,o.forEach(e=>{if(!a.has(e)){let a=t.concat([s]);n.push({op:`add`,path:a,value:e}),i.unshift({op:r,path:a,value:e})}s++})}function c(e,t,r){let{patches_:i,inversePatches_:a}=r;i.push({op:n,path:[],value:t===Sc?void 0:t}),a.push({op:n,path:[],value:e})}function l(e,t){return t.forEach(t=>{let{path:i,op:a}=t,o=e;for(let e=0;e<i.length-1;e++){let t=Lc(o),n=i[e];typeof n!=`string`&&typeof n!=`number`&&(n=``+n),(t===0||t===1)&&(n===`__proto__`||n===Tc)&&Q(19),Kc(o)&&n===Ec&&Q(19),o=zc(o,n),(o===null||!Gc(o))&&Q(18,i.join(`/`))}let s=Lc(o),c=u(t.value),l=i[i.length-1];switch(a){case n:switch(s){case 2:return o.set(l,c);case 3:Q(16);default:return o[l]=c}case`add`:switch(s){case 1:return l===`-`?o.push(c):o.splice(l,0,c);case 2:return o.set(l,c);case 3:return o.add(c);default:return o[l]=c}case r:switch(s){case 1:return o.splice(l,1);case 2:return o.delete(l);case 3:return o.delete(t.value);default:return delete o[l]}default:Q(17,a)}}),e}function u(e){if(!Mc(e))return e;if(Hc(e))return e.map(u);if(Uc(e))return new Map(Array.from(e.entries()).map(([e,t])=>[e,u(t)]));if(Wc(e))return new Set(Array.from(e).map(u));let t=Object.create(wc(e));for(let n in e)t[n]=u(e[n]);return Rc(e,Cc)&&(t[Cc]=e[Cc]),t}function d(e){return jc(e)?u(e):e}ll(il,{applyPatches_:l,generatePatches_:i,generateReplacementPatches_:c,getPath:e})}globalThis.Iterator?.from;var Ul=new Rl,Wl=Ul.produce,Gl=Ul.produceWithPatches.bind(Ul),Kl=Ul.applyPatches.bind(Ul),ql=`useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict`;function Jl(e=21){let t=``,n=e;for(;n--;)t+=ql[Math.random()*64|0];return t}var Yl=1e3;function Xl(e,t){if(e.add(t),e.size>Yl){let t=e.values().next().value;t!==void 0&&e.delete(t)}}function Zl(e){let{enablePatches:t=!1}=e;t&&Hl();let n=Us(),r=e.initialValue,i=new Set;return{on:n.on,value:()=>r,patch:(e,t=Jl())=>{i.has(t)||(Hl(),r=Kl(r,e),Xl(i,t),n.emit(`updated`,r,void 0,t))},mutate:(e,a=Jl())=>{if(!i.has(a)){if(Xl(i,a),t){let[t,i]=Gl(r,e);r=t,n.emit(`updated`,r,i,a)}else r=Wl(r,e),n.emit(`updated`,r,void 0,a)}},syncIds:i}}function Ql(e){let t=new Map,n=new Map,r=new Map,i=new Set,a=e.connectionMeta.backend===`static`;function o(e,t){let n=r.get(e);return n&&typeof n==`object`&&!Array.isArray(n)&&typeof t==`object`&&!Array.isArray(t)?{...n,...t}:t}e.client.register({name:X.broadcast.clientStateUpdated,type:`event`,handler:(e,n,r)=>{let i=t.get(e);!i||i.syncIds.has(r)||i.mutate(()=>o(e,n),r)}}),e.client.register({name:X.broadcast.clientStatePatch,type:`event`,handler:(e,n,r)=>{let i=t.get(e);!i||i.syncIds.has(r)||i.patch(n,r)}});function s(t,n){let r=[];return r.push(n.on(`updated`,(n,r,i)=>{a||(r?e.callEvent(`devframe:rpc:server-state:patch`,t,r,i):e.callEvent(`devframe:rpc:server-state:set`,t,n,i))})),()=>{for(let e of r)e()}}return{keys:()=>Array.from(t.keys()),onKeyAdded(e){return i.add(e),()=>{i.delete(e)}},delete(e){let i=n.get(e);n.delete(e);let a=t.delete(e);return r.delete(e),i?.(),a},get:async(c,l)=>{if(l?.initialValue!==void 0&&r.set(c,l.initialValue),t.has(c))return t.get(c);let u=Zl({initialValue:l?.initialValue,enablePatches:!1});async function d(){if(a||e.callEvent(`devframe:rpc:server-state:subscribe`,c),l?.initialValue!==void 0){t.set(c,u);for(let e of i)e(c);return e.call(`devframe:rpc:server-state:get`,c).then(e=>{e!==void 0&&u.mutate(()=>o(c,e))}).catch(e=>{console.error(`Error getting server state`,e)}),n.set(c,s(c,u)),u}{let r=await e.call(`devframe:rpc:server-state:get`,c);u.mutate(()=>o(c,r)),t.set(c,u);for(let e of i)e(c);return n.set(c,s(c,u)),u}}return new Promise(t=>{if(e.isTrusted)d().then(t);else{t(u);let n=!1;e.events.on(X.client.isTrustedUpdated,e=>{e&&!n&&(n=!0,d())})}})}}}var $l=typeof self==`object`?self:globalThis,eu=new Set([`Error`,`EvalError`,`RangeError`,`ReferenceError`,`SyntaxError`,`TypeError`,`URIError`,`AggregateError`]),tu=new Set([`Boolean`,`Number`,`String`,`Int8Array`,`Uint8Array`,`Uint8ClampedArray`,`Int16Array`,`Uint16Array`,`Int32Array`,`Uint32Array`,`Float16Array`,`Float32Array`,`Float64Array`,`BigInt64Array`,`BigUint64Array`]);function nu(e,t){let n=(t,n)=>(e.set(n,t),t),r=i=>{if(e.has(i))return e.get(i);let[a,o]=t[i];switch(a){case 0:case-1:return n(o,i);case 1:{let e=n([],i);for(let t of o)e.push(r(t));return e}case 2:{let e=n({},i);for(let[t,n]of o)e[r(t)]=r(n);return e}case 3:return n(new Date(o),i);case 4:{let{source:e,flags:t}=o;return n(new RegExp(e,t),i)}case 5:{let e=n(new Map,i);for(let[t,n]of o)e.set(r(t),r(n));return e}case 6:{let e=n(new Set,i);for(let t of o)e.add(r(t));return e}case 7:{let{name:e,message:t}=o,r=eu.has(e)?$l[e]:void 0;return n(new(r??$l.Error)(t),i)}case 8:return n(BigInt(o),i);case`BigInt`:return n(Object(BigInt(o)),i);case`ArrayBuffer`:return n(new Uint8Array(o).buffer,o);case`DataView`:{let{buffer:e}=new Uint8Array(o);return n(new DataView(e),o)}}if(typeof a==`string`&&tu.has(a))return n(new $l[a](o),i);throw TypeError(`unable to deserialize unsafe or unknown type: ${String(a)}`)};return r}function ru(e){return nu(new Map,e)(0)}var iu=``,{toString:au}={},{keys:ou}=Object;function su(e){let t=typeof e;if(t!==`object`||!e)return[0,t];let n=au.call(e).slice(8,-1);switch(n){case`Array`:return[1,iu];case`Object`:return[2,iu];case`Date`:return[3,iu];case`RegExp`:return[4,iu];case`Map`:return[5,iu];case`Set`:return[6,iu];case`DataView`:return[1,n]}return n.includes(`Array`)?[1,n]:n.includes(`Error`)?[7,n]:[2,n]}function cu([e,t]){return e===0&&(t===`function`||t===`symbol`)}function lu(e,t,n,r){let i=(e,t)=>{let i=r.push(e)-1;return n.set(t,i),i},a=r=>{if(n.has(r))return n.get(r);let[o,s]=su(r);switch(o){case 0:{let t=r;switch(s){case`bigint`:o=8,t=r.toString();break;case`function`:case`symbol`:if(e)throw TypeError(`unable to serialize ${s}`);t=null;break;case`undefined`:return i([-1],r)}return i([o,t],r)}case 1:{if(s){let e=r;return s===`DataView`?e=new Uint8Array(r.buffer):s===`ArrayBuffer`&&(e=new Uint8Array(r)),i([s,[...e]],r)}let e=[],t=i([o,e],r);for(let t of r)e.push(a(t));return t}case 2:{if(s)switch(s){case`BigInt`:return i([s,r.toString()],r);case`Boolean`:case`Number`:case`String`:return i([s,r.valueOf()],r)}if(t&&`toJSON`in r)return a(r.toJSON());let n=[],c=i([o,n],r);for(let t of ou(r))(e||!cu(su(r[t])))&&n.push([a(t),a(r[t])]);return c}case 3:return i([o,r.toISOString()],r);case 4:{let{source:e,flags:t}=r;return i([o,{source:e,flags:t}],r)}case 5:{let t=[],n=i([o,t],r);for(let[n,i]of r)(e||!(cu(su(n))||cu(su(i))))&&t.push([a(n),a(i)]);return n}case 6:{let t=[],n=i([o,t],r);for(let n of r)(e||!cu(su(n)))&&t.push(a(n));return n}}let{message:c}=r;return i([o,{name:s,message:c}],r)};return a}function uu(e,t={}){let n=[];return lu(!(t.json||t.lossy),!!t.json,new Map,n)(e),n}var{parse:du,stringify:fu}=JSON,pu={json:!0,lossy:!0};function mu(e){return ru(du(e))}function hu(e){return fu(uu(e,pu))}function gu(e){return ru(e)}function _u(e){return hu(e)}function vu(e){return mu(e)}var yu=new Map;function bu(e=yu){let t=new Map;return{serialize:n=>{let r;return n.t===`q`?r=n.m:(r=t.get(n.i),t.delete(n.i)),!(n.t===`s`&&`e`in n)&&r&&e.get(r)?.jsonSerializable===!0?Bs(n,r??``):`s:${_u(n)}`},deserialize:e=>{let n=e.startsWith(`s:`)?vu(e.slice(2)):JSON.parse(e);return n.t===`q`&&n.i&&n.m&&t.set(n.i,n.m),n}}}function xu(){}function Su(e){let{onConnected:t=xu,onError:n=xu,onDisconnected:r=xu,definitions:i,fetch:a=globalThis.fetch.bind(globalThis)}=e,o=e.url;e.authToken&&(o=`${o}${o.includes(`?`)?`&`:`?`}${is}=${encodeURIComponent(e.authToken)}`);let s=bu(i),c=new AbortController,l=!1,u,d,f,p,m=new Promise((e,t)=>{f=e,p=t});m.catch(()=>{});function h(e){l||(l=!0,p(e),n(e),r())}function g(){l||(l=!0,p(Error(`Devframe SSE stream closed`)),r())}function _(e,n){if(e===`session`){f(n),t();return}u?.(n)}async function v(e){let t=e.getReader();d=t;let n=new TextDecoder,r=``;for(;;){let{done:e,value:i}=await t.read();if(e)break;for(r+=n.decode(i,{stream:!0});;){let e=r.search(/\n\n|\r\n\r\n/);if(e<0)break;let t=r.slice(0,e);r=r.slice(e+(r[e]===`\r`?4:2));let n=`message`,i=[];for(let e of t.split(/\r?\n/))e.startsWith(`:`)||(e.startsWith(`event:`)?n=e.slice(6).trimStart():e.startsWith(`data:`)&&i.push(e.slice(5).replace(/^ /,``)));i.length>0&&_(n,i.join(`
3
- `))}}g()}return(async()=>{try{let e=await a(o,{headers:{accept:`text/event-stream`},signal:c.signal});if(!e.ok||!e.body)throw Error(`Devframe SSE stream request failed: ${e.status}`);await v(e.body)}catch(e){if(c.signal.aborted){g();return}h(e instanceof Error?e:Error(String(e)))}})(),{close:()=>{l=!0,c.abort(),d?.cancel().catch(()=>{})},on:e=>{u=e},post:async e=>{let t;try{t=await m}catch{return}if(l){n(Error(`Devframe SSE channel is closed; message dropped`));return}try{let n=await a(o,{method:`POST`,headers:{"content-type":`text/plain; charset=utf-8`,[es]:t},body:e});if(n.status===200){let e=await n.text();e&&u?.(e);return}if(!n.ok)throw Error(`Devframe SSE POST failed: ${n.status}`)}catch(e){n(e instanceof Error?e:Error(String(e)))}},serialize:s.serialize,deserialize:s.deserialize}}function Cu(){let e,t;return{promise:new Promise((n,r)=>{e=n,t=r}),resolve:e,reject:t}}var wu=Math.random.bind(Math),Tu=`useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict`;function Eu(e=21){let t=``,n=e;for(;n--;)t+=Tu[wu()*64|0];return t}var Du=6e4,Ou=e=>e,ku=Ou,{clearTimeout:Au,setTimeout:ju}=globalThis;function Mu(e,t){let{post:n,on:r,off:i=()=>{},eventNames:a=[],serialize:o=Ou,deserialize:s=ku,resolver:c,bind:l=`rpc`,timeout:u=Du,proxify:d=!0}=t,f=!1,p=new Map,m,h;async function g(e,r,i,a){if(f)throw Error(`[birpc] rpc is closed, cannot call "${e}"`);let s={m:e,a:r,t:`q`};a&&(s.o=!0);let c=async e=>n(o(e));if(i){await c(s);return}if(m)try{await m}finally{m=void 0}let{promise:l,resolve:d,reject:g}=Cu(),_=Eu();s.i=_;let v;async function y(n=s){return u>=0&&(v=ju(()=>{try{if(t.onTimeoutError?.call(h,e,r)!==!0)throw Error(`[birpc] timeout on calling "${e}"`)}catch(e){g(e)}p.delete(_)},u),typeof v==`object`&&(v=v.unref?.())),p.set(_,{resolve:d,reject:g,timeoutId:v,method:e}),await c(n),l}try{t.onRequest?await t.onRequest.call(h,s,y,d):await y()}catch(e){if(t.onGeneralError?.call(h,e)!==!0)throw e;return}finally{Au(v),p.delete(_)}return l}let _={$call:(e,...t)=>g(e,t,!1),$callOptional:(e,...t)=>g(e,t,!1,!0),$callEvent:(e,...t)=>g(e,t,!0),$callRaw:e=>g(e.method,e.args,e.event,e.optional),$rejectPendingCalls:y,get $closed(){return f},get $meta(){return t.meta},$close:v,$functions:e};h=d?new Proxy({},{get(t,n){if(Object.hasOwn(_,n))return _[n];if(n===`then`&&!a.includes(`then`)&&!(`then`in e))return;let r=(...e)=>g(n,e,!0);if(a.includes(n))return r.asEvent=r,r;let i=(...e)=>g(n,e,!1);return i.asEvent=r,i}}):_;function v(e){f=!0,p.forEach(({reject:t,method:n})=>{let r=Error(`[birpc] rpc is closed, cannot call "${n}"`);if(e)return e.cause??=r,t(e);t(r)}),p.clear(),i(b)}function y(e){let t=Array.from(p.values()).map(({method:t,reject:n})=>e?e({method:t,reject:n}):n(Error(`[birpc]: rejected pending call "${t}".`)));return p.clear(),t}async function b(r,...i){let a;try{a=s(r)}catch(e){if(t.onGeneralError?.call(h,e)!==!0)throw e;return}if(a.t===`q`){let{m:r,a:s,o:u}=a,d,f,p=await(c?c.call(h,r,e[r]):e[r]);if(u&&(p||=()=>void 0),!p)f=Error(`[birpc] function "${r}" not found`);else try{d=await p.apply(l===`rpc`?h:e,s)}catch(e){f=e}if(a.i){if(f&&t.onFunctionError&&t.onFunctionError.call(h,f,r,s)===!0)return;if(!f)try{await n(o({t:`s`,i:a.i,r:d}),...i);return}catch(e){if(f=e,t.onGeneralError?.call(h,e,r,s)!==!0)throw e}try{await n(o({t:`s`,i:a.i,e:f}),...i)}catch(e){if(t.onGeneralError?.call(h,e,r,s)!==!0)throw e}}}else{let{i:e,r:t,e:n}=a,r=p.get(e);r&&(Au(r.timeoutId),n?r.reject(n):r.resolve(t)),p.delete(e)}}return m=r(b),h}function Nu(e,t){let{channel:n,rpcOptions:r={}}=t;return Mu(e,{...n,timeout:-1,...r,proxify:!1})}function Pu(){let e,t;return{promise:new Promise((n,r)=>{e=n,t=r}),resolve:e,reject:t}}function Fu(e){let{transport:t,authToken:n,connectionMeta:r,events:i,clientRpc:a,rpcOptions:o={},callTimeout:s=0}=e,c=!1,l=`connecting`,u=null,d=Pu();function f(e,t=null){if(t?u=t:e===`connected`&&(u=null),e===l)return;let n=l;l=e,i.emit(X.client.connectionStatus,e,n)}let p=new Set;function m(e){for(let t of[...p])t.reject(e)}function h(){return l===`disconnected`||l===`error`?new gc(`connection`,`[devframe] Not connected to the devframe server`,{cause:u??void 0}):l===`unauthorized`?new gc(`auth`,`[devframe] Not authorized by the devframe server`,{cause:u??void 0}):null}function g(e,t){return new Promise((n,r)=>{let a=!1,o,c={reject(e){a||(l(),i.emit(X.client.error,e,t),r(e))}};function l(){a=!0,p.delete(c),o&&clearTimeout(o)}p.add(c),s>0&&(o=setTimeout(()=>{c.reject(new gc(`timeout`,`[devframe] RPC call "${t}" timed out after ${s}ms`))},s)),e.then(e=>{a||(l(),n(e))},e=>{if(a)return;l();let n=e instanceof Error?e:Error(String(e));i.emit(X.client.error,n,t),r(n)})})}let _=new Map;for(let e of r.jsonSerializableMethods??[])_.set(e,{jsonSerializable:!0});let v=e.createChannel({definitions:_,onError(e){f(`error`,e),i.emit(X.client.connectionError,e),m(new gc(`connection`,`[devframe] Connection to the devframe server failed`,{cause:e}))},onDisconnected(){l!==`error`&&f(`disconnected`),m(new gc(`connection`,`[devframe] Disconnected from the devframe server`,{cause:u??void 0}))}}),y=Nu(a.functions,{channel:v,rpcOptions:o});a.register({name:X.broadcast.authRevoked,type:`event`,handler:()=>{c=!1;let e=new gc(`auth`,`[devframe] The devframe server revoked this client's trust`);f(`unauthorized`,e),i.emit(X.client.connectionError,e),m(e),i.emit(X.client.isTrustedUpdated,!1)}});let b=n;async function x(e){b=e;let t=await y.$call(`anonymous:devframe:auth`,{authToken:e,ua:navigator.userAgent,origin:location.origin});if(c=t.isTrusted,c)d.resolve(!0),f(`connected`);else{let e=new gc(`auth`,`[devframe] The devframe server refused this client's credentials`);f(`unauthorized`,e),i.emit(X.client.connectionError,e)}return i.emit(X.client.isTrustedUpdated,c),t.isTrusted}async function S(e){let t=(await y.$call(`anonymous:devframe:auth:exchange`,{code:e,ua:navigator.userAgent,origin:location.origin}))?.authToken??null;return t&&(b=t,c=!0,d.resolve(!0),f(`connected`),i.emit(X.client.isTrustedUpdated,!0)),t}async function C(){return c?!0:x(b??``)}async function w(e=6e4){if(c&&d.resolve(!0),e<=0)return d.promise;let t=()=>{};return await Promise.race([d.promise.then(t),new Promise((n,r)=>{let i=setTimeout(()=>{r(Error(`[devframe] Timeout waiting for rpc to be trusted`))},e);t=()=>clearTimeout(i)})]),c}return{transport:t,get isTrusted(){return c},get status(){return l},get connectionError(){return u},requestTrust:C,requestTrustWithToken:x,requestTrustWithCode:S,ensureTrusted:w,call:(...e)=>{let t=String(e[0]),n=h();return n?(i.emit(X.client.error,n,t),Promise.reject(n)):g(y.$call(...e),t)},callEvent:(...e)=>{let t=h();if(t){i.emit(X.client.error,t,String(e[0]));return}return y.$callEvent(...e)},callOptional:(...e)=>{let t=String(e[0]),n=h();return n?(i.emit(X.client.error,n,t),Promise.reject(n)):g(y.$callOptional(...e),t)},close:()=>{v.close()}}}function Iu(e,t,n){let r=(()=>{try{return new URL(t,n.href)}catch{return new URL(n.href)}})();if(e&&typeof e==`object`){if(e.host!=null||e.port!=null){let t=e.host??`${r.hostname}:${e.port}`;return new URL(e.path??`/`,`${r.protocol}//${t}`).href}return new URL(e.path??``,r).href}let i=e??``;return/^https?:\/\//i.test(i)?i:new URL(i,r).href}function Lu(e){let{authToken:t,connectionMeta:n,metaBaseUrl:r,events:i,clientRpc:a,rpcOptions:o={},sseOptions:s={},callTimeout:c=0}=e,l=Iu(n.sse,r??`./`,location);return Fu({transport:`sse`,authToken:t,connectionMeta:n,events:i,clientRpc:a,rpcOptions:o,callTimeout:c,createChannel:e=>Su({url:l,authToken:t,definitions:e.definitions,...s,onConnected(){s.onConnected?.()},onError(t){e.onError(t),s.onError?.(t)},onDisconnected(){e.onDisconnected(),s.onDisconnected?.()}})})}function Ru(e){let t=e.cause instanceof Error?e.cause:zu(e.cause)?Ru(e.cause):e.cause,n=t===void 0?Error(e.message):Error(e.message,{cause:t});n.name=e.name;for(let t of Object.keys(e))t!==`name`&&t!==`message`&&t!==`cause`&&(n[t]=e[t]);return n}function zu(e){return typeof e==`object`&&!!e&&typeof e.message==`string`&&typeof e.name==`string`}function Bu(e){return typeof e==`object`&&!!e&&e.type===`static`&&typeof e.path==`string`}function Vu(e){return typeof e==`object`&&!!e&&e.type===`query`&&typeof e.records==`object`&&e.records!==null}function Hu(e){return typeof e==`object`&&!!e&&(`output`in e||`error`in e)}function Uu(e){if(e.error)throw Ru(e.error);return e.output}function Wu(e){return e.some(e=>e!=null)}function Gu(e){return typeof e==`object`&&e&&`serialization`in e&&`data`in e?e.data:e}function Ku(e,t){let n=new Map,r=new Map;function i(e,t){return t===`structured-clone`&&Array.isArray(e)?gu(e):e}function a(e,t){return i(Gu(e),t)}async function o(e){n.has(e.path)||n.set(e.path,t(e.path).then(t=>a(t,e.serialization)));let r=await n.get(e.path);return Hu(r)?Uu(r):r}async function s(e,n){return r.has(e)||r.set(e,t(e).then(e=>a(e,n))),await r.get(e)}async function c(t,n){if(!(t in e))throw Error(`[devframe-rpc] Function "${t}" not found in dump store`);let r=e[t];if(Bu(r)){if(Wu(n))throw Error(`[devframe-rpc] No dump match for "${t}" with args: ${JSON.stringify(n)}`);return await o(r)}if(Vu(r)){let e=vs(n),i=r.records[e];if(i)return Uu(await s(i,r.serialization));if(r.fallback)return Uu(await s(r.fallback,r.serialization));throw Error(`[devframe-rpc] No dump match for "${t}" with args: ${JSON.stringify(n)}`)}if(!Wu(n))return r;throw Error(`[devframe-rpc] No dump match for "${t}" with args: ${JSON.stringify(n)}`)}return{call:async(e,t)=>await c(e,t),callOptional:async(t,n)=>{if(t in e)return await c(t,n)},callEvent:async(e,t)=>{}}}async function qu(e){let t=Ku(await e.fetchJsonFromBases(ts),e.fetchJsonFromBases);return{transport:`static`,isTrusted:!0,status:`connected`,connectionError:null,requestTrust:async()=>!0,requestTrustWithToken:async()=>!0,requestTrustWithCode:async()=>null,ensureTrusted:async()=>!0,call:(...e)=>t.call(e[0],e.slice(1)),callEvent:(...e)=>t.callEvent(e[0],e.slice(1)),callOptional:(...e)=>t.callOptional(e[0],e.slice(1)),close:()=>{}}}var Ju=256,Yu=class extends Error{name=`StreamClosedError`};function Xu(e={}){let t=e.id??Jl(),n=Math.max(0,e.replayWindow??0),r=Us(),i=new AbortController,a=[],o=!1,s=0;function c(e){if(o)throw new Yu(`Cannot write to a closed stream "${t}"`);s+=1,n>0&&(a.push({seq:s,chunk:e}),a.length>n&&a.splice(0,a.length-n)),r.emit(`chunk`,s,e)}function l(e){if(o)return;o=!0;let t=Qu(e);i.abort(e),r.emit(`end`,t)}function u(){o||(o=!0,i.signal.aborted||i.abort(`stream closed`),r.emit(`end`,void 0))}function d(e){o||i.signal.aborted||i.abort(e??`aborted`)}let f=new WritableStream({write(e){c(e)},close(){u()},abort(e){l(e)}});return{id:t,signal:i.signal,get closed(){return o},get lastSeq(){return s},write:c,error:l,close:u,abort:d,writable:f,events:r,buffer:a}}function Zu(e={}){let t=e.id??Jl(),n=Math.max(1,e.highWaterMark??Ju),r=[],i=0,a=!1,o=!1,s,c,l,u;function d(){if(c){if(r.length>0){let e=r.shift(),t=c;c=void 0,t.resolve({value:e,done:!1});return}if(a){let e=c;if(c=void 0,s){let t=Error(s.message);t.name=s.name,e.reject(t)}else e.resolve({value:void 0,done:!0})}}}function f(){if(l){for(;r.length>0;){let e=r.shift();try{l.enqueue(e)}catch{break}}if(a&&l){try{if(s){let e=Error(s.message);e.name=s.name,l.error(e)}else l.close()}catch{}l=void 0}}}function p(t,s){if(!(a||o)&&!(t<=i)){if(i=t,r.push(s),r.length>n){let t=r.length-n;r.splice(0,t),e.onOverflow?.(t)}d(),u&&f()}}function m(e){a||(a=!0,s=e,d(),u&&f())}function h(){o||a||(o=!0,e.onCancel?.(),m(void 0))}function g(){return u||(u=new ReadableStream({start(e){l=e,f()},cancel(){h()}}),u)}return{id:t,get cancelled(){return o},get done(){return a},get lastSeenSeq(){return i},get readable(){return g()},cancel:h,_push:p,_end:m,[Symbol.asyncIterator](){return{next(){if(r.length>0)return Promise.resolve({value:r.shift(),done:!1});if(a){if(s){let e=Error(s.message);return e.name=s.name,Promise.reject(e)}return Promise.resolve({value:void 0,done:!0})}return new Promise((e,t)=>{c={resolve:e,reject:t}})},return(){return h(),Promise.resolve({value:void 0,done:!0})}}}}}function Qu(e){if(e instanceof Error)return{name:e.name||`Error`,message:e.message};if(typeof e==`string`)return{name:`Error`,message:e};try{return{name:`Error`,message:JSON.stringify(e)}}catch{return{name:`Error`,message:String(e)}}}var $u=``;function ed(e,t){return`${e}${$u}${t}`}function td(e){let t=new Map,n=new Map;e.client.register({name:X.broadcast.streamingChunk,type:`event`,handler(e,n,r,i){t.get(ed(e,n))?._push(r,i)}}),e.client.register({name:X.broadcast.streamingEnd,type:`event`,handler(e,n,r){let i=ed(e,n),a=t.get(i);a&&(a._end(r),t.delete(i))}}),e.client.register({name:X.broadcast.streamingUploadCancel,type:`event`,handler(e,t){let r=ed(e,t),i=n.get(r);i&&(i.abort(`server cancelled upload`),n.delete(r))}}),e.events.on(X.client.isTrustedUpdated,n=>{if(n)for(let[n,r]of t){if(r.cancelled||r.done)continue;let t=n.indexOf($u);if(t<0)continue;let i=n.slice(0,t),a=n.slice(t+1);e.callEvent(`devframe:streaming:subscribe`,i,a,{afterSeq:r.lastSeenSeq})}});function r(n,r,i={}){let a=ed(n,r),o=t.get(a);if(o)return o;let s=Zu({id:r,highWaterMark:i.highWaterMark,onOverflow(e){console.warn(`[devframe] DF0029: Stream "${n}#${r}" dropped ${e} chunk(s) after exceeding the client high-water mark.`)},onCancel(){e.callEvent(`devframe:streaming:cancel`,n,r),t.delete(a)}});if(t.set(a,s),e.isTrusted)e.callEvent(`devframe:streaming:subscribe`,n,r,{afterSeq:0});else{let i=e.events.on(X.client.isTrustedUpdated,o=>{o&&(i(),t.has(a)&&!s.cancelled&&!s.done&&e.callEvent(`devframe:streaming:subscribe`,n,r,{afterSeq:s.lastSeenSeq}))})}return s}function i(t,r){let i=ed(t,r),a=n.get(i);if(a)return a;let o=Xu({id:r});return o.events.on(`chunk`,(n,i)=>{e.callEvent(`devframe:streaming:upload-chunk`,t,r,n,i)}),o.events.on(`end`,a=>{e.callEvent(`devframe:streaming:upload-end`,t,r,a),n.delete(i)}),n.set(i,o),o}return{subscribe:r,upload:i}}function nd(){}var rd=new Map;function id(e){let t=e.url;e.authToken&&(t=`${t}?${is}=${encodeURIComponent(e.authToken)}`);let n=new WebSocket(t),{onConnected:r=nd,onError:i=nd,onDisconnected:a=nd,definitions:o=rd}=e;n.addEventListener(`open`,e=>{r(e)}),n.addEventListener(`error`,e=>{let t=e instanceof Error?e:Error(e.type);i(t)}),n.addEventListener(`close`,e=>{a(e)});let s=bu(o);return{close:()=>{n.close()},on:e=>{n.addEventListener(`message`,t=>{e(t.data)})},post:e=>{if(n.readyState===WebSocket.OPEN){n.send(e);return}if(n.readyState===WebSocket.CONNECTING){let t=()=>{i(),n.readyState===WebSocket.OPEN&&n.send(e)},r=()=>i();function i(){n.removeEventListener(`open`,t),n.removeEventListener(`close`,r)}n.addEventListener(`open`,t),n.addEventListener(`close`,r);return}i(Error(`Devframe WebSocket is not open; message dropped`))},serialize:s.serialize,deserialize:s.deserialize}}function ad(e,t,n){let r=(()=>{try{return new URL(t,n.href)}catch{return new URL(n.href)}})(),i=r.protocol===`https:`?`wss:`:`ws:`;if(e&&typeof e==`object`){if(e.host!=null||e.port!=null){let t=e.host??`${r.hostname}:${e.port}`,n=new URL(e.path??`/`,`${i}//${t}`);return n.protocol=i,n.href}let t=new URL(e.path??``,r);return t.protocol=i,t.href}if(typeof e==`number`)return`${i}//${r.hostname}:${e}`;let a=e??``;if(/^wss?:\/\//i.test(a))return a;if(/^https?:\/\//i.test(a))return rc(a,/^https/i.test(a)?`wss://`:`ws://`);let o=new URL(a,r);return o.protocol=i,o.href}function od(e){let{authToken:t,connectionMeta:n,metaBaseUrl:r,events:i,clientRpc:a,rpcOptions:o={},wsOptions:s={},callTimeout:c=0}=e,l=ad(n.websocket,r??`./`,location);return Fu({transport:`websocket`,authToken:t,connectionMeta:n,events:i,clientRpc:a,rpcOptions:o,callTimeout:c,createChannel:e=>id({url:l,authToken:t,definitions:e.definitions,...s,onConnected(e){s.onConnected?.(e)},onError(t){e.onError(t),s.onError?.(t)},onDisconnected(t){e.onDisconnected(),s.onDisconnected?.(t)}})})}function sd(e){return e.includes(`:`)}function cd(e,t){return sd(t)?t:`${e}:${t}`}function ld(e,t,n){let r=`devframe:settings:${n}:${t}`,i;function a(){return i||=e.sharedState.get(r,{initialValue:{}}),i}return{async get(e){return(await a()).value()[e]},async set(e,t){(await a()).mutate(n=>{n[e]=t})},async delete(e){(await a()).mutate(t=>{delete t[e]})},async all(){return(await a()).value()},async onChange(e){return(await a()).on(`updated`,t=>e(t))}}}function ud(e,t){return{global:ld(e,t,`global`),project:ld(e,t,`project`)}}function dd(e,t){return{namespace:t,base:e,rpc:{namespace:t,register(n){if(sd(n.name))throw Error(`[devframe] Scoped client RPC registration for namespace "${t}" received an already-namespaced function name "${n.name}". Pass a bare name without a ":" separator.`);e.client.register({...n,name:`${t}:${n.name}`})},call:((n,...r)=>e.call(cd(t,n),...r)),callEvent:((n,...r)=>e.callEvent(cd(t,n),...r)),callOptional:((n,...r)=>e.callOptional(cd(t,n),...r)),sharedState:((n,r)=>e.sharedState.get(cd(t,n),r)),streaming:{subscribe:(n,r,i)=>e.streaming.subscribe(cd(t,n),r,i),upload:(n,r)=>e.streaming.upload(cd(t,n),r)}},settings:ud(e,t),scope:e.scope}}function fd(e,t){if(t.backend===`static`)return`static`;let n=t.websocket!==void 0,r=t.sse!==void 0;if(e===`websocket`){if(!n)throw Error(`[devframe] transport: 'websocket' was requested, but this server does not advertise a WebSocket endpoint`);return`websocket`}if(e===`sse`){if(!r)throw Error(`[devframe] transport: 'sse' was requested, but this server does not advertise an SSE endpoint`);return`sse`}if(t.backend===`sse`&&r)return`sse`;if(n)return`websocket`;if(r)return`sse`;throw Error(`[devframe] This server advertises no RPC transport (backend "none") — nothing to connect to. Enable the WebSocket or SSE endpoint on the server, or use its static/MCP surfaces instead.`)}async function pd(e={}){let{baseURL:t=`./`,rpcOptions:n={},cacheOptions:r=!1}=e,i=Us(),a=Array.isArray(t)?t:[t],o=await hc(e),{connectionMeta:s,metaBaseUrl:c,authToken:l}=o,u=a[0]??`./`;try{u=new URL(`.`,c).href}catch{}let d=new ys({functions:[],...typeof e.cacheOptions==`object`?e.cacheOptions:{}}),f={rpc:void 0},p=new Rs(f);async function m(e){let t=[u,...a.filter(e=>e!==u)].filter(e=>e!=null),n=[];for(let r of t)try{return await fetch($s(e,r)).then(t=>{if(!t.ok)throw Error(`Failed to fetch ${e} from ${r}: ${t.status}`);return t.json()})}catch(e){n.push(e)}throw Error(`Failed to load ${e} from ${t.join(`, `)}`,{cause:n})}let h={authToken:l,connectionMeta:s,metaBaseUrl:c,events:i,clientRpc:p,callTimeout:e.callTimeout,rpcOptions:{...n,async onRequest(e,t,i){if(await n.onRequest?.call(this,e,t,i),r&&d?.validate(e.m)){if(d.has(e.m,e.a))return i(d.cached(e.m,e.a));let n=await t(e);d.apply(e,n)}else await t(e)}}},g=fd(e.transport??`auto`,s),_=g===`static`?await qu({fetchJsonFromBases:m}):g===`sse`?Lu({...h,sseOptions:e.sseOptions}):od({...h,wsOptions:e.wsOptions}),v;try{v=new BroadcastChannel(`devframe-auth`)}catch{}let y,b=!1;function x(e){return((...t)=>b||!y?e(...t):y.then(()=>e(...t)))}let S={events:i,get isTrusted(){return _.isTrusted},get status(){return _.status},get connectionError(){return _.connectionError},get transport(){return _.transport??g},get connection(){return o},connectionMeta:s,ensureTrusted:_.ensureTrusted,requestTrust:_.requestTrust,requestTrustWithToken:async e=>(dc(e),o={...o,authToken:e},_.requestTrustWithToken(e)),requestTrustWithCode:async e=>{let t=await _.requestTrustWithCode(e);if(!t)return!1;dc(t),o={...o,authToken:t};try{v?.postMessage({type:`auth-update`,authToken:t})}catch{}return!0},call:x(_.call),callEvent:x(_.callEvent),callOptional:x(_.callOptional),client:p,sharedState:void 0,services:void 0,streaming:void 0,cacheManager:d,scope:void 0,close:()=>_.close?.()};S.sharedState=Ql(S),S.streaming=td(S),S.services=xc(S);let C=new Map;S.scope=(e=>{if(!e)return S;let t=C.get(e);return t||(t=dd(S,e),C.set(e,t)),t}),f.rpc=S;function w(){try{return typeof window<`u`&&window.self===window.top}catch{return!1}}async function ee(){if(!(e.simpleAuth===!1||!w())&&typeof globalThis.prompt==`function`)for(;!S.isTrusted;){let e=globalThis.prompt(`devframe: enter the authentication code shown in your terminal`);if(e==null)return;let t=e.trim();if(t&&await S.requestTrustWithCode(t))return}}async function te(){let t=await _.requestTrust(),n=e.otpParam??`devframe_otp`,r=n?await bc(S,{param:n}):!1;t||r||S.isTrusted||await ee()}return y=te().then(()=>{b=!0},()=>{b=!0}),v&&(v.onmessage=e=>{e.data?.type===`auth-update`&&e.data.authToken&&S.requestTrustWithToken(e.data.authToken)}),S}var md=pd,hd=`devframes:plugin:code-server:state`;function gd(e){return md(e)}var _d=Pt({connected:!1,status:`connecting`,error:null,backend:null}),vd=Kt(null);function yd(e){_d.status=e.status,_d.connected=e.status===`connected`,_d.error=e.connectionError?.message??null}async function bd(){try{let e=await gd();vd.value=e,_d.backend=e.connectionMeta.backend,yd(e),e.events.on(`connection:status`,()=>yd(e)),e.connectionMeta.backend===`websocket`&&e.ensureTrusted(5e3).catch(()=>{})}catch(e){_d.status=`error`,_d.error=e?.message??String(e)}}function xd(){return vd}var Sd=`devframes:plugin:code-server:detect`,Cd=`devframes:plugin:code-server:status`,wd=`devframes:plugin:code-server:start`,Td=`devframes:plugin:code-server:stop`;function Ed(){let e=xd(),t=Pt({checked:!1,installed:!1,bin:`code-server`,backend:`code-server`,mode:`local`}),n=Pt({status:`stopped`}),r=Kt(void 0),i=Gt(!1),a=Y(()=>n.status===`running`?r.value?`running`:`starting`:n.status===`starting`||i.value&&n.status!==`error`?`starting`:t.checked?t.installed?`launch`:`not-installed`:`connecting`);function o(e){e&&(Object.assign(t,e.detection),Object.assign(n,e.server),e.connect&&(r.value=e.connect))}async function s(t,...r){let i=e.value;if(i)try{return await i.call(t,...r)}catch(e){n.status=`error`,n.error=e instanceof Error?e.message:String(e);return}}async function c(){if(!i.value){i.value=!0;try{o(await s(wd,{}))}finally{i.value=!1}}}async function l(){if(!i.value){i.value=!0;try{o(await s(Td)),r.value=void 0}finally{i.value=!1}}}async function u(){if(!i.value){i.value=!0;try{await s(Sd)}finally{i.value=!1}}}async function d(){o(await s(Cd));let i=e.value;if(!i)return;let a=await i.sharedState.get(hd,{initialValue:{detection:t,server:n}}),c=a.value();Object.assign(t,c.detection),Object.assign(n,c.server);let l=a.on(`updated`,e=>{Object.assign(t,e.detection),Object.assign(n,e.server),n.status===`running`&&!r.value&&s(Cd).then(e=>{e?.connect&&(r.value=e.connect)}),n.status!==`running`&&(r.value=void 0)});Ee(()=>l?.())}return{detection:t,server:n,connect:r,busy:i,phase:a,launch:c,stop:l,recheck:u,bootstrap:d}}var Dd={class:`relative h-full w-full of-hidden bg-base color-base`},Od=Wn({__name:`App`,setup(e,{expose:t}){let{detection:n,server:r,connect:i,busy:a,phase:o,launch:s,stop:c,recheck:l,bootstrap:u}=Ed(),d=Y(()=>!!i.value);return ar(async()=>{await bd(),await u()}),t({stop:c}),(e,t)=>(U(),W(`div`,Dd,[d.value?On((U(),Vi(wo,{key:0,connect:I(i),port:I(r).port},null,8,[`connect`,`port`])),[[Pa,I(o)===`running`]]):Xi(``,!0),I(o)===`running`?Xi(``,!0):(U(),Vi(Zo,{key:1,phase:I(o),detection:I(n),server:I(r),busy:I(a),onLaunch:I(s),onRecheck:I(l)},null,8,[`phase`,`detection`,`server`,`busy`,`onLaunch`,`onRecheck`])),K(Co,{status:I(_d).status,error:I(_d).error},null,8,[`status`,`error`])]))}}),kd=window.matchMedia(`(prefers-color-scheme: dark)`);function Ad(e){document.documentElement.classList.toggle(`dark`,e),document.documentElement.classList.toggle(`light`,!e)}Ad(kd.matches),kd.addEventListener(`change`,e=>Ad(e.matches)),po(Od).mount(`#app`);