regor 1.4.4 → 1.4.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +127 -0
- package/dist/regor.d.ts +76 -0
- package/dist/regor.es2015.cjs.js +256 -45
- package/dist/regor.es2015.cjs.prod.js +3 -3
- package/dist/regor.es2015.esm.js +256 -45
- package/dist/regor.es2015.esm.prod.js +3 -3
- package/dist/regor.es2015.iife.js +256 -45
- package/dist/regor.es2015.iife.prod.js +3 -3
- package/dist/regor.es2019.cjs.js +256 -45
- package/dist/regor.es2019.cjs.prod.js +3 -3
- package/dist/regor.es2019.esm.js +256 -45
- package/dist/regor.es2019.esm.prod.js +3 -3
- package/dist/regor.es2019.iife.js +256 -45
- package/dist/regor.es2019.iife.prod.js +3 -3
- package/dist/regor.es2022.cjs.js +249 -40
- package/dist/regor.es2022.cjs.prod.js +3 -3
- package/dist/regor.es2022.esm.js +249 -40
- package/dist/regor.es2022.esm.prod.js +3 -3
- package/dist/regor.es2022.iife.js +249 -40
- package/dist/regor.es2022.iife.prod.js +3 -3
- package/package.json +1 -1
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
var sr=Object.defineProperty;var ir=(n,e,t)=>e in n?sr(n,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):n[e]=t;var d=(n,e,t)=>ir(n,typeof e!="symbol"?e+"":e,t);var $e=Symbol(":regor");var Te=n=>{let e=[n];for(let t=0;t<e.length;++t){let o=e[t];ar(o);for(let r=o.lastChild;r!=null;r=r.previousSibling)e.push(r)}},ar=n=>{let e=n[$e];if(!e)return;let t=e.unbinders;for(let o=0;o<t.length;++o)t[o]();t.length=0,n[$e]=void 0};var qe=[],dt=!1,ht,Vn=()=>{if(dt=!1,ht=void 0,qe.length!==0){for(let n=0;n<qe.length;++n)Te(qe[n]);qe.length=0}},G=n=>{n.remove(),qe.push(n),dt||(dt=!0,ht=setTimeout(Vn,1))},cr=async()=>{qe.length===0&&!dt||(ht&&clearTimeout(ht),Vn())};var F=n=>typeof n=="function",z=n=>typeof n=="string",_n=n=>typeof n=="undefined",le=n=>n==null||typeof n=="undefined",J=n=>typeof n!="string"||!(n!=null&&n.trim()),ur=Object.prototype.toString,Zt=n=>ur.call(n),Ae=n=>Zt(n)==="[object Map]",ue=n=>Zt(n)==="[object Set]",en=n=>Zt(n)==="[object Date]",nt=n=>typeof n=="symbol",w=Array.isArray,D=n=>n!==null&&typeof n=="object";var jn={0:"createApp can't find root element. You must define either a valid `selector` or an `element`. Example: createApp({}, {selector: '#app', html: '...'})",1:n=>`Component template cannot be found. selector: ${n} .`,2:"Use composables in scope. usage: useScope(() => new MyApp()).",3:n=>`${n} requires ref source argument`,4:"computed is readonly.",5:"persist requires a string key."},_=(n,...e)=>{let t=jn[n];return new Error(F(t)?t.call(jn,...e):t)};var yt=[],$n=()=>{let n={onMounted:[],onUnmounted:[]};return yt.push(n),n},De=n=>{let e=yt[yt.length-1];if(!e&&!n)throw _(2);return e},qn=n=>{let e=De();return n&&nn(n),yt.pop(),e},tn=Symbol("csp"),nn=n=>{let e=n,t=e[tn];if(t){let o=De();if(t===o)return;o.onMounted.length>0&&t.onMounted.push(...o.onMounted),o.onUnmounted.length>0&&t.onUnmounted.push(...o.onUnmounted);return}e[tn]=De()},gt=n=>n[tn];var Ne=n=>{var t,o;let e=(t=gt(n))==null?void 0:t.onUnmounted;e==null||e.forEach(r=>{r()}),(o=n.unmounted)==null||o.call(n)};var ot=class{constructor(e,t,o,r,s){d(this,"props");d(this,"start");d(this,"end");d(this,"ctx");d(this,"autoProps",!0);d(this,"entangle",!0);d(this,"enableSwitch",!1);d(this,"onAutoPropsAssigned");d(this,"me");d(this,"emit",(e,t)=>{this.me.dispatchEvent(new CustomEvent(e,{detail:t}))});this.props=e,this.me=t,this.ctx=o,this.start=r,this.end=s}findContext(e,t=0){var r;if(t<0)return;let o=0;for(let s of(r=this.ctx)!=null?r:[])if(s instanceof e){if(o===t)return s;++o}}requireContext(e,t=0){let o=this.findContext(e,t);if(o!==void 0)return o;throw new Error(`${e} was not found in the context stack at occurrence ${t}.`)}unmount(){let e=this.start.nextSibling,t=this.end;for(;e&&e!==t;)G(e),e=e.nextSibling;for(let o of this.ctx)Ne(o)}};var Ue=n=>{let e=n,t=e[$e];if(t)return t;let o={unbinders:[],data:{}};return e[$e]=o,o};var K=(n,e)=>{Ue(n).unbinders.push(e)};var Fn={8:n=>`Model binding requires a ref at ${n.outerHTML}`,7:n=>`Model binding is not supported on ${n.tagName} element at ${n.outerHTML}`,0:(n,e)=>`${n} binding expression is missing at ${e.outerHTML}`,1:(n,e,t)=>`invalid ${n} expression: ${e} at ${t.outerHTML}`,2:(n,e)=>`${n} requires object expression at ${e.outerHTML}`,3:(n,e)=>`${n} binder: key is empty on ${e.outerHTML}.`,4:(n,e,t,o)=>({msg:`Failed setting prop "${n}" on <${e.toLowerCase()}>: value ${t} is invalid.`,args:[o]}),5:(n,e)=>`${n} binding missing event type at ${e.outerHTML}`,6:(n,e)=>({msg:n,args:[e]})},H=(n,...e)=>{let t=Fn[n],o=F(t)?t.call(Fn,...e):t,r=bt.warning;r&&(z(o)?r(o):r(o,...o.args))},bt={warning:console.warn};var xt={},Tt={},zn=1,Kn=n=>{let e=(zn++).toString();return xt[e]=n,Tt[e]=0,e},on=n=>{Tt[n]+=1},rn=n=>{--Tt[n]===0&&(delete xt[n],delete Tt[n])},Wn=n=>xt[n],sn=()=>zn!==1&&Object.keys(xt).length>0,rt="r-switch",lr=n=>{let e=n.filter(o=>Be(o)).map(o=>[...o.querySelectorAll("[r-switch]")].map(r=>r.getAttribute(rt))),t=new Set;return e.forEach(o=>{o.forEach(r=>r&&t.add(r))}),[...t]},Fe=(n,e)=>{if(!sn())return;let t=lr(e);t.length!==0&&(t.forEach(on),K(n,()=>{t.forEach(rn)}))};var Ct=()=>{},an=(n,e,t,o)=>{let r=[];for(let s of n){let i=s.cloneNode(!0);t.insertBefore(i,o),r.push(i)}Me(e,r)},cn=Symbol("r-if"),Gn=Symbol("r-else"),Jn=n=>n[Gn]===1,Et=class{constructor(e){d(this,"i");d(this,"D");d(this,"K");d(this,"z");d(this,"W");d(this,"T");d(this,"R");this.i=e,this.D=e.o.u.if,this.K=Ke(e.o.u.if),this.z=e.o.u.else,this.W=e.o.u.elseif,this.T=e.o.u.for,this.R=e.o.u.pre}Ze(e,t){let o=e.parentElement;for(;o!==null&&o!==document.documentElement;){if(o.hasAttribute(t))return!0;o=o.parentElement}return!1}N(e){let t=e.hasAttribute(this.D),o=Oe(e,this.K);for(let r of o)this.b(r);return t}G(e){return e[cn]?!0:(e[cn]=!0,Oe(e,this.K).forEach(t=>t[cn]=!0),!1)}b(e){if(e.hasAttribute(this.R)||this.G(e)||this.Ze(e,this.T))return;let t=e.getAttribute(this.D);if(!t){H(0,this.D,e);return}e.removeAttribute(this.D),this.O(e,t)}U(e,t,o){let r=ze(e),s=e.parentNode,i=document.createComment(`__begin__ :${t}${o!=null?o:""}`);s.insertBefore(i,e),Fe(i,r),r.forEach(c=>{G(c)}),e.remove(),t!=="if"&&(e[Gn]=1);let a=document.createComment(`__end__ :${t}${o!=null?o:""}`);return s.insertBefore(a,i.nextSibling),{nodes:r,parent:s,commentBegin:i,commentEnd:a}}de(e,t){if(!e)return[];let o=e.nextElementSibling;if(e.hasAttribute(this.z)){e.removeAttribute(this.z);let{nodes:r,parent:s,commentBegin:i,commentEnd:a}=this.U(e,"else");return[{mount:()=>{an(r,this.i,s,a)},unmount:()=>{xe(i,a)},isTrue:()=>!0,isMounted:!1}]}else{let r=e.getAttribute(this.W);if(!r)return[];e.removeAttribute(this.W);let{nodes:s,parent:i,commentBegin:a,commentEnd:c}=this.U(e,"elseif",` => ${r} `),l=this.i.m.k(r),u=l.value,f=this.de(o,t),p=Ct;return K(a,()=>{l.stop(),p(),p=Ct}),p=l.subscribe(t),[{mount:()=>{an(s,this.i,i,c)},unmount:()=>{xe(a,c)},isTrue:()=>!!u()[0],isMounted:!1},...f]}}O(e,t){let o=e.nextElementSibling,{nodes:r,parent:s,commentBegin:i,commentEnd:a}=this.U(e,"if",` => ${t} `),c=this.i.m.k(t),l=c.value,u=!1,f=this.i.m,p=f.M(),m=()=>{f.C(p,()=>{if(l()[0])u||(an(r,this.i,s,a),u=!0),y.forEach(g=>{g.unmount(),g.isMounted=!1});else{xe(i,a),u=!1;let g=!1;for(let C of y)!g&&C.isTrue()?(C.isMounted||(C.mount(),C.isMounted=!0),g=!0):(C.unmount(),C.isMounted=!1)}})},y=this.de(o,m),h=Ct;K(i,()=>{c.stop(),h(),h=Ct}),m(),h=c.subscribe(m)}};var ze=n=>{let e=he(n)?n.content.childNodes:[n],t=[];for(let o=0;o<e.length;++o){let r=e[o];if(r.nodeType===1){let s=r==null?void 0:r.tagName;if(s==="SCRIPT"||s==="STYLE")continue}t.push(r)}return t},Me=(n,e)=>{for(let t=0;t<e.length;++t){let o=e[t];o.nodeType===Node.ELEMENT_NODE&&(Jn(o)||n.H(o))}},Oe=(n,e)=>{var o;let t=n.querySelectorAll(e);return(o=n.matches)!=null&&o.call(n,e)?[n,...t]:t},he=n=>n instanceof HTMLTemplateElement,Be=n=>n.nodeType===Node.ELEMENT_NODE,st=n=>n.nodeType===Node.ELEMENT_NODE,Qn=n=>n instanceof HTMLSlotElement,Ce=n=>he(n)?n.content.childNodes:n.childNodes,xe=(n,e)=>{let t=n.nextSibling;for(;t!=null&&t!==e;){let o=t.nextSibling;G(t),t=o}},Xn=function(){return this()},fr=function(n){return this(n)},pr=()=>{throw new Error("value is readonly.")},mr={get:Xn,set:fr,enumerable:!0,configurable:!1},dr={get:Xn,set:pr,enumerable:!0,configurable:!1},ke=(n,e)=>{Object.defineProperty(n,"value",e?dr:mr)},Yn=(n,e)=>{if(!n)return!1;if(n.startsWith("["))return n.substring(1,n.length-1);let t=e.length;return n.startsWith(e)?n.substring(t,n.length-t):!1},Ke=n=>`[${CSS.escape(n)}]`,Rt=(n,e)=>(n.startsWith("@")&&(n=e.u.on+":"+n.slice(1)),n.includes("[")&&(n=n.replace(/[[\]]/g,e.u.dynamic)),n),un=n=>{let e=Object.create(null);return t=>e[t]||(e[t]=n(t))},hr=/-(\w)/g,j=un(n=>n&&n.replace(hr,(e,t)=>t?t.toUpperCase():"")),yr=/\B([A-Z])/g,We=un(n=>n&&n.replace(yr,"-$1").toLowerCase()),it=un(n=>n&&n.charAt(0).toUpperCase()+n.slice(1));var vt={mount:()=>{}};var Ge=n=>{let e=n.trim();return e?e.split(/\s+/):[]};var wt=n=>{var t,o;let e=(t=gt(n))==null?void 0:t.onMounted;e==null||e.forEach(r=>{r()}),(o=n.mounted)==null||o.call(n)};var ln=Symbol("scope"),fn=n=>{try{$n();let e=n();nn(e);let t={context:e,unmount:()=>Ne(e),[ln]:1};return t[ln]=1,t}finally{qn()}},Zn=n=>D(n)?ln in n:!1;var St=Symbol("ref"),Y=Symbol("sref"),At=Symbol("raw");var R=n=>n!=null&&n[Y]===1;var pn={collectRefObj:!0,mount:({parseResult:n})=>({update:({values:e})=>{let t=n.context,o=e[0];if(D(o))for(let r of Object.entries(o)){let s=r[0],i=r[1],a=t[s];a!==i&&(R(a)?a(i):t[s]=i)}}})};var re=(n,e)=>{var t;(t=De(e))==null||t.onUnmounted.push(n)};var se=(n,e,t,o=!0)=>{if(!R(n))throw _(3,"observe");t&&e(n());let s=n(void 0,void 0,0,e);return o&&re(s,!0),s};var at=(n,e)=>{if(n===e)return()=>{};let t=se(n,r=>e(r)),o=se(e,r=>n(r));return e(n()),()=>{t(),o()}};var ct=n=>!!n&&n[At]===1;var Je=n=>(n==null?void 0:n[St])===1;var fe=[],eo=n=>{var e;fe.length!==0&&((e=fe[fe.length-1])==null||e.add(n))},Qe=n=>{if(!n)return()=>{};let e={stop:()=>{}};return gr(n,e),re(()=>e.stop(),!0),e.stop},gr=(n,e)=>{if(!n)return;let t=[],o=!1,r=()=>{for(let s of t)s();t=[],o=!0};e.stop=r;try{let s=new Set;if(fe.push(s),n(i=>t.push(i)),o)return;for(let i of[...s]){let a=se(i,()=>{r(),Qe(n)});t.push(a)}}finally{fe.pop()}},mn=n=>{let e=fe.length,t=e>0&&fe[e-1];try{return t&&fe.push(null),n()}finally{t&&fe.pop()}},dn=n=>{try{let e=new Set;return fe.push(e),{value:n(),refs:[...e]}}finally{fe.pop()}};var Z=(n,e,t)=>{if(!R(n))return;let o=n;if(o(void 0,e,1),!t)return;let r=o();if(r){if(w(r)||ue(r))for(let s of r)Z(s,e,!0);else if(Ae(r))for(let s of r)Z(s[0],e,!0),Z(s[1],e,!0);if(D(r))for(let s in r)Z(r[s],e,!0)}};function br(n,e,t){Object.defineProperty(n,e,{value:t,enumerable:!1,writable:!0,configurable:!0})}var Xe=(n,e,t)=>{t.forEach(function(o){let r=n[o];br(e,o,function(...i){let a=r.apply(this,i),c=this[Y];for(let l of c)Z(l);return a})})},Nt=(n,e)=>{Object.defineProperty(n,Symbol.toStringTag,{value:e,writable:!1,enumerable:!1,configurable:!0})};var to=Array.prototype,hn=Object.create(to),Tr=["push","pop","shift","unshift","splice","sort","reverse"];Xe(to,hn,Tr);var no=Map.prototype,Ot=Object.create(no),xr=["set","clear","delete"];Nt(Ot,"Map");Xe(no,Ot,xr);var oo=Set.prototype,Mt=Object.create(oo),Cr=["add","clear","delete"];Nt(Mt,"Set");Xe(oo,Mt,Cr);var ye={},ae=n=>{if(R(n)||ct(n))return n;let e={auto:!0,_value:n},t=c=>D(c)?Y in c?!0:w(c)?(Object.setPrototypeOf(c,hn),!0):ue(c)?(Object.setPrototypeOf(c,Mt),!0):Ae(c)?(Object.setPrototypeOf(c,Ot),!0):!1:!1,o=t(n),r=new Set,s=(c,l)=>{if(ye.stack&&ye.stack.length){ye.stack[ye.stack.length-1].add(a);return}r.size!==0&&mn(()=>{for(let u of[...r.keys()])r.has(u)&&u(c,l)})},i=c=>{let l=c[Y];l||(c[Y]=l=new Set),l.add(a)},a=(...c)=>{if(!(2 in c)){let u=c[0],f=c[1];return 0 in c?e._value===u||R(u)&&(u=u(),e._value===u)?u:(t(u)&&i(u),e._value=u,e.auto&&s(u,f),e._value):(eo(a),e._value)}switch(c[2]){case 0:{let u=c[3];if(!u)return()=>{};let f=p=>{r.delete(p)};return r.add(u),()=>{f(u)}}case 1:{let u=c[1],f=e._value;s(f,u);break}case 2:return r.size;case 3:{e.auto=!1;break}case 4:e.auto=!0}return e._value};return a[Y]=1,ke(a,!1),o&&i(n),a};var Ee=n=>{if(ct(n))return n;let e;if(R(n)?(e=n,n=e()):e=ae(n),n instanceof Node||n instanceof Date||n instanceof RegExp||n instanceof Promise||n instanceof Error)return e;if(e[St]=1,w(n)){let t=n.length;for(let o=0;o<t;++o){let r=n[o];Je(r)||(n[o]=Ee(r))}return e}if(!D(n))return e;for(let t of Object.entries(n)){let o=t[1];if(Je(o))continue;let r=t[0];nt(r)||(n[r]=null,n[r]=Ee(o))}return e};var ro=Symbol("modelBridge"),kt=()=>{},Er=n=>!!(n!=null&&n[ro]),Rr=n=>{n[ro]=1},vr=n=>{let e=Ee(n());return Rr(e),e},so={collectRefObj:!0,mount:({parseResult:n,option:e})=>{if(typeof e!="string"||!e)return kt;let t=j(e),o,r,s=kt,i=()=>{s(),s=kt,o=void 0,r=void 0},a=()=>{s(),s=kt},c=(u,f)=>{o!==u&&(a(),s=at(u,f),o=u)},l=()=>{var m;let u=(m=n.refs[0])!=null?m:n.value()[0],f=n.context,p=f[t];if(!R(u)){if(r&&p===r){r(u);return}if(i(),R(p)){p(u);return}f[t]=u;return}if(Er(u)){if(p===u)return;R(p)?c(u,p):f[t]=u;return}r||(r=vr(u)),f[t]=r,c(u,r)};return{update:()=>{l()},unmount:()=>{s()}}}};var Lt=class{constructor(e){d(this,"i");d(this,"ye");d(this,"he","");d(this,"ge",-1);this.i=e,this.ye=e.o.u.inherit}N(e){this.et(e)}tt(e){if(this.ge!==e.size){let t=[...e.keys()];this.he=[...t,...t.map(We)].join(","),this.ge=e.size}return this.he}nt(e){var t;for(let o=0;o<e.length;++o){let r=(t=e[o])==null?void 0:t.components;if(r)for(let s in r)return!0}return!1}et(e){var p;let t=this.i,o=t.m,r=t.o.be,s=t.o.j;if(r.size===0&&!this.nt(o.l))return;let i=o.J(),a=o.ot(),c=this.tt(r),l=[...c?[c]:[],...a,...a.map(We)].join(",");if(J(l))return;let u=e.querySelectorAll(l),f=(p=e.matches)!=null&&p.call(e,l)?[e,...u]:u;for(let m of f){if(m.hasAttribute(t.R))continue;let y=m.parentNode;if(!y)continue;let h=m.nextSibling,E=j(m.tagName).toUpperCase(),g=i[E],C=g!=null?g:s.get(E);if(!C)continue;let U=C.template;if(!U)continue;let W=m.parentElement;if(!W)continue;let L=new Comment(" begin component: "+m.tagName),V=new Comment(" end component: "+m.tagName);W.insertBefore(L,m),m.remove();let ie=t.o.u.context,ee=t.o.u.contextAlias,B=t.o.u.bind,b=(x,T)=>{let v={},q=x.hasAttribute(ie);return o.C(T,()=>{o.v(v),q?t.b(pn,x,ie):x.hasAttribute(ee)&&t.b(pn,x,ee);let k=C.props;if(!k||k.length===0)return;k=k.map(j);let S=new Map(k.map(A=>[A.toLowerCase(),A]));for(let A of[...k,...k.map(We)]){let P=x.getAttribute(A);P!==null&&(v[j(A)]=P,x.removeAttribute(A))}let M=t._.xe(x,!1);for(let[A,P]of M.entries()){let[oe,Ie]=P.Q;if(!Ie)continue;let je=S.get(j(Ie).toLowerCase());je&&(oe!=="."&&oe!==":"&&oe!==B||t.b(so,x,A,!0,je,P.X))}}),v},N=[...o.M()],Q=()=>{var q;let x=b(m,N),T=new ot(x,m,N,L,V),v=fn(()=>{var k;return(k=C.context(T))!=null?k:{}}).context;if(T.autoProps){for(let[k,S]of Object.entries(x))if(k in v){let M=v[k];if(M===S)continue;if(R(M)){R(S)?T.entangle?K(L,at(S,M)):M(S()):M(S);continue}}else v[k]=S;(q=T.onAutoPropsAssigned)==null||q.call(T)}return{componentCtx:v,head:T}},{componentCtx:me,head:_e}=Q(),ge=[...Ce(U)],I=ge.length,mt=m.childNodes.length===0,O=x=>{let T=x.parentElement,v=x.name;if(J(v)&&(v=x.getAttributeNames().filter(S=>S.startsWith("#"))[0],J(v)?v="default":v=v.substring(1)),mt){if(v==="default"){let S=t.o.u.text,M=m.getAttribute(S);if(!J(M)){let A=document.createElement("span");A.setAttribute(S,M),T.insertBefore(A,x),m.removeAttribute(S);return}}for(let S of[...x.childNodes])T.insertBefore(S,x);return}let q=m.querySelector(`template[name='${v}'], template[\\#${v}]`);!q&&v==="default"&&(q=m.querySelector("template:not([name])"),q&&q.getAttributeNames().filter(S=>S.startsWith("#")).length>0&&(q=null));let k=S=>{_e.enableSwitch&&o.C(N,()=>{o.v(me);let M=b(x,o.M());o.C(N,()=>{o.v(M);let A=o.M(),P=Kn(A);for(let oe of S)Be(oe)&&(oe.setAttribute(rt,P),on(P),K(oe,()=>{rn(P)}))})})};if(q){let S=[...Ce(q)];for(let M of S)T.insertBefore(M,x);k(S)}else{if(v!=="default"){for(let M of[...Ce(x)])T.insertBefore(M,x);return}let S=[...Ce(m)].filter(M=>!he(M));for(let M of S)T.insertBefore(M,x);k(S)}},X=x=>{if(!Be(x))return;let T=x.querySelectorAll("slot");if(Qn(x)){O(x),x.remove();return}for(let v of T)O(v),v.remove()};(()=>{for(let x=0;x<I;++x)ge[x]=ge[x].cloneNode(!0),y.insertBefore(ge[x],h),X(ge[x])})(),W.insertBefore(V,h);let te=()=>{if(!C.inheritAttrs)return;let x=ge.filter(v=>v.nodeType===Node.ELEMENT_NODE);x.length>1&&(x=x.filter(v=>v.hasAttribute(this.ye)));let T=x[0];if(T)for(let v of m.getAttributeNames()){if(v===ie||v===ee)continue;let q=m.getAttribute(v);if(v==="class"){let k=Ge(q);k.length>0&&T.classList.add(...k)}else if(v==="style"){let k=T.style,S=m.style;for(let M of S)k.setProperty(M,S.getPropertyValue(M))}else T.setAttribute(Rt(v,t.o),q)}},be=()=>{for(let x of m.getAttributeNames())!x.startsWith("@")&&!x.startsWith(t.o.u.on)&&m.removeAttribute(x)},Se=()=>{te(),be(),o.v(me),t.Te(m,!1),me.$emit=_e.emit,Me(t,ge),K(m,()=>{Ne(me)}),K(L,()=>{Te(m)}),wt(me)};o.C(N,Se)}}};var yn=class{constructor(e,t){d(this,"Q");d(this,"X");d(this,"Re",[]);this.Q=e,this.X=t}},It=class{constructor(e){d(this,"i");d(this,"Ce");d(this,"Ee");d(this,"Y");var o;this.i=e,this.Ce=e.o.rt(),this.Y=new Map;let t=new Map;for(let r of this.Ce){let s=(o=r[0])!=null?o:"",i=t.get(s);i?i.push(r):t.set(s,[r])}this.Ee=t}ve(e){let t=this.Y.get(e);if(t)return t;let o=e,r=o.startsWith(".");r&&(o=":"+o.slice(1));let s=o.indexOf("."),a=(s<0?o:o.substring(0,s)).split(/[:@]/);J(a[0])&&(a[0]=r?".":o[0]);let c=s>=0?o.slice(s+1).split("."):[],l=!1,u=!1;for(let p=0;p<c.length;++p){let m=c[p];if(!l&&m==="camel"?l=!0:!u&&m==="prop"&&(u=!0),l&&u)break}l&&(a[a.length-1]=j(a[a.length-1])),u&&(a[0]=".");let f={terms:a,flags:c};return this.Y.set(e,f),f}xe(e,t){let o=new Map;if(!st(e))return o;let r=this.Ee,s=(c,l)=>{var f;let u=r.get((f=l[0])!=null?f:"");if(u)for(let p=0;p<u.length;++p){if(!l.startsWith(u[p]))continue;let m=o.get(l);if(!m){let y=this.ve(l);m=new yn(y.terms,y.flags),o.set(l,m)}m.Re.push(c);return}},i=c=>{var u;let l=c.attributes;if(!(!l||l.length===0))for(let f=0;f<l.length;++f){let p=(u=l.item(f))==null?void 0:u.name;p&&s(c,p)}};if(i(e),!t||!e.firstElementChild)return o;let a=e.querySelectorAll("*");for(let c of a)i(c);return o}};var io=()=>{},wr=(n,e)=>{for(let t of n){let o=t.cloneNode(!0);e.appendChild(o)}},Dt=class{constructor(e){d(this,"i");d(this,"L");d(this,"we");this.i=e,this.L=e.o.u.is,this.we=Ke(this.L)+", [is]"}N(e){let t=e.hasAttribute(this.L),o=Oe(e,this.we);for(let r of o)this.b(r);return t}b(e){let t=e.getAttribute(this.L);if(!t){if(t=e.getAttribute("is"),!t)return;if(!t.startsWith("regor:")){if(!t.startsWith("r-"))return;let o=t.slice(2).trim().toLowerCase();if(!o)return;let r=e.parentNode;if(!r)return;let s=document.createElement(o);for(let i of e.getAttributeNames())i!=="is"&&s.setAttribute(i,e.getAttribute(i));for(;e.firstChild;)s.appendChild(e.firstChild);r.insertBefore(s,e),e.remove(),this.i.H(s);return}t=`'${t.slice(6)}'`,e.removeAttribute("is")}e.removeAttribute(this.L),this.O(e,t)}U(e,t){let o=ze(e),r=e.parentNode,s=document.createComment(`__begin__ dynamic ${t!=null?t:""}`);r.insertBefore(s,e),Fe(s,o),o.forEach(a=>{G(a)}),e.remove();let i=document.createComment(`__end__ dynamic ${t!=null?t:""}`);return r.insertBefore(i,s.nextSibling),{nodes:o,parent:r,commentBegin:s,commentEnd:i}}O(e,t){let{nodes:o,parent:r,commentBegin:s,commentEnd:i}=this.U(e,` => ${t} `),a=this.i.m.k(t),c=a.value,l=this.i.m,u=l.M(),f={name:""},p=he(e)?o:[...o[0].childNodes],m=()=>{l.C(u,()=>{var C;let E=c()[0];if(D(E)&&(E.name?E=E.name:E=(C=Object.entries(l.J()).filter(U=>U[1]===E)[0])==null?void 0:C[0]),!z(E)||J(E)){xe(s,i);return}if(f.name===E)return;xe(s,i);let g=document.createElement(E);for(let U of e.getAttributeNames())U!==this.L&&g.setAttribute(U,e.getAttribute(U));wr(p,g),r.insertBefore(g,i),this.i.H(g),f.name=E})},y=io;K(s,()=>{a.stop(),y(),y=io}),m(),y=a.subscribe(m)}};var $=n=>{let e=n;return e!=null&&e[Y]===1?e():e};var Sr=(n,e)=>{let[t,o]=e;F(o)?o(n,t):n.innerHTML=t==null?void 0:t.toString()},Ut={mount:()=>({update:({el:n,values:e})=>{Sr(n,e)}})};var Bt=class n{constructor(e){d(this,"Z");this.Z=e}static st(e,t){var m,y;let o=e.m,r=e.o,s=r.u,i=new Set([s.for,s.if,s.else,s.elseif,s.pre]),a=r.P,c=o.J();if(Object.keys(c).length>0||r.j.size>0)return;let l=e._,u=[],f=0,p=[];for(let h=t.length-1;h>=0;--h)p.push(t[h]);for(;p.length>0;){let h=p.pop();if(h.nodeType===Node.ELEMENT_NODE){let g=h;if(g.tagName==="TEMPLATE"||g.tagName.includes("-"))return;let C=j(g.tagName).toUpperCase();if(r.j.has(C)||c[C])return;let U=g.attributes;for(let W=0;W<U.length;++W){let L=(m=U.item(W))==null?void 0:m.name;if(!L)continue;if(i.has(L))return;let{terms:V,flags:ie}=l.ve(L),[ee,B]=V,b=(y=a[L])!=null?y:a[ee];if(b){if(b===Ut)return;u.push({nodeIndex:f,attrName:L,directive:b,option:B,flags:ie})}}++f}let E=h.childNodes;for(let g=E.length-1;g>=0;--g)p.push(E[g])}if(u.length!==0)return new n(u)}b(e,t){let o=[],r=[];for(let s=t.length-1;s>=0;--s)r.push(t[s]);for(;r.length>0;){let s=r.pop();s.nodeType===Node.ELEMENT_NODE&&o.push(s);let i=s.childNodes;for(let a=i.length-1;a>=0;--a)r.push(i[a])}for(let s=0;s<this.Z.length;++s){let i=this.Z[s],a=o[i.nodeIndex];a&&e.b(i.directive,a,i.attrName,!1,i.option,i.flags)}}};var Ar=(n,e)=>{let t=e.parentNode;if(t)for(let o=0;o<n.items.length;++o)t.insertBefore(n.items[o],e)},Nr=n=>{var a;let e=n.length,t=n.slice(),o=[],r,s,i;for(let c=0;c<e;++c){let l=n[c];if(l===0)continue;let u=o[o.length-1];if(u===void 0||n[u]<l){t[c]=u!=null?u:-1,o.push(c);continue}for(r=0,s=o.length-1;r<s;)i=r+s>>1,n[o[i]]<l?r=i+1:s=i;l<n[o[r]]&&(r>0&&(t[c]=o[r-1]),o[r]=c)}for(r=o.length,s=(a=o[r-1])!=null?a:-1;r-- >0;)o[r]=s,s=t[s];return o},Pt=class{static it(e){let{oldItems:t,newValues:o,getKey:r,isSameValue:s,mountNewValue:i,removeMountItem:a,endAnchor:c}=e,l=t.length,u=o.length,f=new Array(u),p=new Set;for(let b=0;b<u;++b){let N=r(o[b]);if(N===void 0||p.has(N))return;p.add(N),f[b]=N}let m=new Array(u),y=0,h=l-1,E=u-1;for(;y<=h&&y<=E;){let b=t[y];if(r(b.value)!==f[y]||!s(b.value,o[y]))break;b.value=o[y],m[y]=b,++y}for(;y<=h&&y<=E;){let b=t[h];if(r(b.value)!==f[E]||!s(b.value,o[E]))break;b.value=o[E],m[E]=b,--h,--E}if(y>h){for(let b=E;b>=y;--b){let N=b+1<u?m[b+1].items[0]:c;m[b]=i(b,o[b],N)}return m}if(y>E){for(let b=y;b<=h;++b)a(t[b]);return m}let g=y,C=y,U=E-C+1,W=new Array(U).fill(0),L=new Map;for(let b=C;b<=E;++b)L.set(f[b],b);let V=!1,ie=0;for(let b=g;b<=h;++b){let N=t[b],Q=L.get(r(N.value));if(Q===void 0){a(N);continue}if(!s(N.value,o[Q])){a(N);continue}N.value=o[Q],m[Q]=N,W[Q-C]=b+1,Q>=ie?ie=Q:V=!0}let ee=V?Nr(W):[],B=ee.length-1;for(let b=U-1;b>=0;--b){let N=C+b,Q=N+1<u?m[N+1].items[0]:c;if(W[b]===0){m[N]=i(N,o[N],Q);continue}let me=m[N];V&&(B>=0&&ee[B]===b?--B:me&&Ar(me,Q))}return m}};var ut=class{constructor(e){d(this,"x",[]);d(this,"V",new Map);d(this,"ee");this.ee=e}get w(){return this.x.length}te(e){let t=this.ee(e.value);t!==void 0&&this.V.set(t,e)}ne(e){var o;let t=this.ee((o=this.x[e])==null?void 0:o.value);t!==void 0&&this.V.delete(t)}static at(e,t){return{items:[],index:e,value:t,order:-1}}v(e){e.order=this.w,this.x.push(e),this.te(e)}ct(e,t){let o=this.w;for(let r=e;r<o;++r)this.x[r].order=r+1;t.order=e,this.x.splice(e,0,t),this.te(t)}I(e){return this.x[e]}oe(e,t){this.ne(e),this.x[e]=t,this.te(t),t.order=e}Se(e){this.ne(e),this.x.splice(e,1);let t=this.w;for(let o=e;o<t;++o)this.x[o].order=o}Ae(e){let t=this.w;for(let o=e;o<t;++o)this.ne(o);this.x.splice(e)}Gt(e){return this.V.has(e)}ut(e){var o;let t=this.V.get(e);return(o=t==null?void 0:t.order)!=null?o:-1}};var gn=Symbol("r-for"),Or=n=>-1,ao=()=>{},Vt=class Vt{constructor(e){d(this,"i");d(this,"T");d(this,"re");d(this,"R");this.i=e,this.T=e.o.u.for,this.re=Ke(this.T),this.R=e.o.u.pre}N(e){let t=e.hasAttribute(this.T),o=Oe(e,this.re);for(let r of o)this.pt(r);return t}G(e){return e[gn]?!0:(e[gn]=!0,Oe(e,this.re).forEach(t=>t[gn]=!0),!1)}pt(e){if(e.hasAttribute(this.R)||this.G(e))return;let t=e.getAttribute(this.T);if(!t){H(0,this.T,e);return}e.removeAttribute(this.T),this.lt(e,t)}Ne(e){return le(e)?[]:(F(e)&&(e=e()),Symbol.iterator in Object(e)?e:typeof e=="number"?(o=>({*[Symbol.iterator](){for(let r=1;r<=o;r++)yield r}}))(e):Object.entries(e))}lt(e,t){var mt;let o=this.ft(t);if(!(o!=null&&o.list)){H(1,this.T,t,e);return}let r=this.i.o.u.key,s=this.i.o.u.keyBind,i=(mt=e.getAttribute(r))!=null?mt:e.getAttribute(s);e.removeAttribute(r),e.removeAttribute(s);let a=ze(e),c=Bt.st(this.i,a),l=e.parentNode;if(!l)return;let u=`${this.T} => ${t}`,f=new Comment(`__begin__ ${u}`);l.insertBefore(f,e),Fe(f,a),a.forEach(O=>{G(O)}),e.remove();let p=new Comment(`__end__ ${u}`);l.insertBefore(p,f.nextSibling);let m=this.i,y=m.m,h=y.M(),g=h.length===1?[void 0,h[0]]:void 0,C=this.mt(i),U=(O,X)=>C(O)===C(X),W=(O,X)=>O===X,L=(O,X,ne)=>{let te=o.createContext(X,O),be=ut.at(te.index,X),Se=()=>{var q,k;let x=(k=(q=p.parentNode)!=null?q:f.parentNode)!=null?k:l,T=ne.previousSibling,v=[];for(let S=0;S<a.length;++S){let M=a[S].cloneNode(!0);x.insertBefore(M,ne),v.push(M)}for(c?c.b(m,v):Me(m,v),T=T.nextSibling;T!==ne;)be.items.push(T),T=T.nextSibling};return g?(g[0]=te.ctx,y.C(g,Se)):y.C(h,()=>{y.v(te.ctx),Se()}),be},V=(O,X)=>{let ne=I.I(O).items,te=ne[ne.length-1].nextSibling;for(let be of ne)G(be);I.oe(O,L(O,X,te))},ie=(O,X)=>{I.v(L(O,X,p))},ee=O=>{for(let X of I.I(O).items)G(X)},B=O=>{let X=I.w;for(let ne=O;ne<X;++ne)I.I(ne).index(ne)},b=O=>{let X=f.parentNode,ne=p.parentNode;if(!X||!ne)return;let te=I.w;F(O)&&(O=O());let be=$(O[0]);if(w(be)&&be.length===0){xe(f,p),I.Ae(0);return}let Se=[];for(let A of this.Ne(O[0]))Se.push(A);let x=Pt.it({oldItems:I.x,newValues:Se,getKey:C,isSameValue:W,mountNewValue:(A,P,oe)=>L(A,P,oe),removeMountItem:A=>{for(let P=0;P<A.items.length;++P)G(A.items[P])},endAnchor:p});if(x){I.x=x,I.V.clear();for(let A=0;A<x.length;++A){let P=x[A];P.order=A,P.index(A);let oe=C(P.value);oe!==void 0&&I.V.set(oe,P)}return}let T=0,v=Number.MAX_SAFE_INTEGER,q=te,k=this.i.o.forGrowThreshold,S=()=>I.w<q+k;for(let A of Se){let P=()=>{if(T<te){let oe=I.I(T++);if(U(oe.value,A)){if(W(oe.value,A))return;V(T-1,A);return}let Ie=I.ut(C(A));if(Ie>=T&&Ie-T<10){if(--T,v=Math.min(v,T),ee(T),I.Se(T),--te,Ie>T+1)for(let je=T;je<Ie-1&&je<te&&!U(I.I(T).value,A);)++je,ee(T),I.Se(T),--te;P();return}S()?(I.ct(T-1,L(T,A,I.I(T-1).items[0])),v=Math.min(v,T-1),++te):V(T-1,A)}else ie(T++,A)};P()}let M=T;for(te=I.w;T<te;)ee(T++);I.Ae(M),B(v)},N=()=>{Q.stop(),_e(),_e=ao},Q=y.k(o.list),me=Q.value,_e=ao,ge=0,I=new ut(C);for(let O of this.Ne(me()[0]))I.v(L(ge++,O,p));K(f,N),_e=Q.subscribe(b)}ft(e){var c,l;let t=Vt.dt.exec(e);if(!t)return;let o=(t[1]+((c=t[2])!=null?c:"")).split(",").map(u=>u.trim()),r=o.length>1?o.length-1:-1,s=r!==-1&&(o[r]==="index"||(l=o[r])!=null&&l.startsWith("#"))?o[r]:"";s&&o.splice(r,1);let i=t[3];if(!i||o.length===0)return;let a=/[{[]/.test(e);return{list:i,createContext:(u,f)=>{let p={},m=$(u);if(!a&&o.length===1)p[o[0]]=u;else if(w(m)){let h=0;for(let E of o)p[E]=m[h++]}else for(let h of o)p[h]=m[h];let y={ctx:p,index:Or};return s&&(y.index=p[s.startsWith("#")?s.substring(1):s]=ae(f)),y}}}mt(e){if(!e)return o=>o;let t=e.trim();if(!t)return o=>o;if(t.includes(".")){let o=this.yt(t),r=o.length>1?o.slice(1):void 0;return s=>{let i=$(s),a=this.Oe(i,o);return a!==void 0||!r?a:this.Oe(i,r)}}return o=>{var r;return $((r=$(o))==null?void 0:r[t])}}yt(e){return e.split(".").filter(t=>t.length>0)}Oe(e,t){var r;let o=e;for(let s of t)o=(r=$(o))==null?void 0:r[s];return $(o)}};d(Vt,"dt",/\{?\[?\(?([^)}\]]+)\)?\]?\}?([^)]+)?\s+\b(?:in|of)\b\s+(.*)\s*$/);var Ht=Vt;var _t=class{constructor(e){d(this,"se",0);d(this,"ie",new Map);d(this,"m");d(this,"ke");d(this,"Me");d(this,"Le");d(this,"Ve");d(this,"_");d(this,"o");d(this,"R");d(this,"Ie");this.m=e,this.o=e.o,this.Me=new Ht(this),this.ke=new Et(this),this.Le=new Dt(this),this.Ve=new Lt(this),this._=new It(this),this.R=this.o.u.pre,this.Ie=this.o.u.dynamic}ht(e){let t=he(e)?[e]:e.querySelectorAll("template");for(let o of t){if(o.hasAttribute(this.R))continue;let r=o.parentNode;if(!r)continue;let s=o.nextSibling;if(o.remove(),!o.content)continue;let i=[...o.content.childNodes];for(let a of i)r.insertBefore(a,s);Me(this,i)}}H(e){++this.se;try{if(e.nodeType!==Node.ELEMENT_NODE||e.hasAttribute(this.R)||this.ke.N(e)||this.Me.N(e)||this.Le.N(e))return;this.Ve.N(e),this.ht(e),this.Te(e,!0)}finally{--this.se,this.se===0&&this.gt()}}bt(e,t){let o=document;if(!o){let r=e.parentNode;for(;r!=null&&r.parentNode;)r=r.parentNode;if(!r)return null;o=r}return o.querySelector(t)}De(e,t){let o=this.bt(e,t);if(!o)return!1;let r=e.parentElement;if(!r)return!1;let s=new Comment(`teleported => '${t}'`);return r.insertBefore(s,e),e.teleportedFrom=s,s.teleportedTo=e,K(s,()=>{G(e)}),o.appendChild(e),!0}xt(e,t){this.ie.set(e,t)}gt(){let e=this.ie;if(e.size!==0){this.ie=new Map;for(let[t,o]of e.entries())this.De(t,o)}}Te(e,t){var s;let o=this._.xe(e,t),r=this.o.P;for(let[i,a]of o.entries()){let[c,l]=a.Q,u=(s=r[i])!=null?s:r[c];if(!u){console.error("directive not found:",c);continue}let f=a.Re;for(let p=0;p<f.length;++p){let m=f[p];this.b(u,m,i,!1,l,a.X)}}}b(e,t,o,r,s,i){if(t.hasAttribute(this.R))return;let a=t.getAttribute(o);t.removeAttribute(o);let c=l=>{let u=l;for(;u;){let f=u.getAttribute(rt);if(f)return f;u=u.parentElement}return null};if(sn()){let l=c(t);if(l){this.m.C(Wn(l),()=>{this.O(e,t,a,s,i)});return}}this.O(e,t,a,s,i)}Tt(e,t,o){return e!==vt?!1:(J(o)||this.De(t,o)||this.xt(t,o),!0)}O(e,t,o,r,s){if(t.nodeType!==Node.ELEMENT_NODE||o==null||this.Tt(e,t,o))return;let i=this.Rt(r,e.once),a=this.Ct(e,o),c=this.Et(a,i);K(t,c.stop);let l=this.vt(t,o,a,i,r,s),u=this.wt(e,l,c);if(!u)return;let f=this.St(l,a,i,r,u);f(),e.once||(c.result=a.subscribe(f),i&&(c.dynamic=i.subscribe(f)))}Rt(e,t){let o=Yn(e,this.Ie);if(o)return this.m.k(j(o),void 0,void 0,void 0,t)}Ct(e,t){return this.m.k(t,e.isLazy,e.isLazyKey,e.collectRefObj,e.once)}Et(e,t){let o={stop:()=>{var r,s,i;e.stop(),t==null||t.stop(),(r=o.result)==null||r.call(o),(s=o.dynamic)==null||s.call(o),(i=o.mounted)==null||i.call(o),o.result=void 0,o.dynamic=void 0,o.mounted=void 0}};return o}vt(e,t,o,r,s,i){return{el:e,expr:t,values:o.value(),previousValues:void 0,option:r?r.value()[0]:s,previousOption:void 0,flags:i,parseResult:o,dynamicOption:r}}wt(e,t,o){let r=e.mount(t);if(typeof r=="function"){o.mounted=r;return}return r!=null&&r.unmount&&(o.mounted=r.unmount),r==null?void 0:r.update}St(e,t,o,r,s){let i,a;return()=>{let c=t.value(),l=o?o.value()[0]:r;e.values=c,e.previousValues=i,e.option=l,e.previousOption=a,i=c,a=l,s(e)}}};var co="http://www.w3.org/1999/xlink",Mr={itemscope:2,allowfullscreen:2,formnovalidate:2,ismap:2,nomodule:2,novalidate:2,readonly:2,async:1,autofocus:1,autoplay:1,controls:1,default:1,defer:1,disabled:1,hidden:1,inert:1,loop:1,open:1,required:1,reversed:1,scoped:1,seamless:1,checked:1,muted:1,multiple:1,selected:1};function kr(n){return!!n||n===""}var Lr=(n,e,t,o,r,s)=>{var a;if(o){s&&s.includes("camel")&&(o=j(o)),jt(n,o,e[0],r);return}let i=e.length;for(let c=0;c<i;++c){let l=e[c];if(w(l)){let u=(a=t==null?void 0:t[c])==null?void 0:a[0],f=l[0],p=l[1];jt(n,f,p,u)}else if(D(l))for(let u of Object.entries(l)){let f=u[0],p=u[1],m=t==null?void 0:t[c],y=m&&f in m?f:void 0;jt(n,f,p,y)}else{let u=t==null?void 0:t[c],f=e[c++],p=e[c];jt(n,f,p,u)}}},bn={mount:()=>({update:({el:n,values:e,previousValues:t,option:o,previousOption:r,flags:s})=>{Lr(n,e,t,o,r,s)}})},jt=(n,e,t,o)=>{if(o&&o!==e&&n.removeAttribute(o),le(e)){H(3,"r-bind",n);return}if(!z(e)){H(6,`Attribute key is not string at ${n.outerHTML}`,e);return}if(e.startsWith("xlink:")){le(t)?n.removeAttributeNS(co,e.slice(6,e.length)):n.setAttributeNS(co,e,t);return}let r=e in Mr;le(t)||r&&!kr(t)?n.removeAttribute(e):n.setAttribute(e,r?"":t)};var Ir=(n,e,t)=>{let o=e.length;for(let r=0;r<o;++r){let s=e[r],i=t==null?void 0:t[r];if(w(s)){let a=s.length;for(let c=0;c<a;++c)uo(n,s[c],i==null?void 0:i[c])}else uo(n,s,i)}},Tn={mount:()=>({update:({el:n,values:e,previousValues:t})=>{Ir(n,e,t)}})},uo=(n,e,t)=>{let o=n.classList,r=z(e),s=z(t);if(e&&!r){if(t&&!s)for(let i in t)(!(i in e)||!e[i])&&o.remove(i);for(let i in e)e[i]&&o.add(i)}else if(r){if(t!==e){let i=s?Ge(t):[],a=Ge(e);i.length>0&&o.remove(...i),a.length>0&&o.add(...a)}}else if(t){let i=s?Ge(t):[];i.length>0&&o.remove(...i)}};function Dr(n,e){if(n.length!==e.length)return!1;let t=!0;for(let o=0;t&&o<n.length;o++)t=Re(n[o],e[o]);return t}function Re(n,e){if(n===e)return!0;let t=en(n),o=en(e);if(t||o)return t&&o?n.getTime()===e.getTime():!1;if(t=nt(n),o=nt(e),t||o)return n===e;if(t=w(n),o=w(e),t||o)return t&&o?Dr(n,e):!1;if(t=D(n),o=D(e),t||o){if(!t||!o)return!1;let r=Object.keys(n).length,s=Object.keys(e).length;if(r!==s)return!1;for(let i in n){let a=Object.prototype.hasOwnProperty.call(n,i),c=Object.prototype.hasOwnProperty.call(e,i);if(a&&!c||!Re(n[i],e[i]))return!1}return!0}return String(n)===String(e)}function $t(n,e){return n.findIndex(t=>Re(t,e))}var lo=n=>{let e=parseFloat(n);return isNaN(e)?n:e};var xn=n=>{if(!R(n))throw _(3,"pause");n(void 0,void 0,3)};var Cn=n=>{if(!R(n))throw _(3,"resume");n(void 0,void 0,4)};var po={mount:({el:n,parseResult:e,flags:t})=>({update:({values:o})=>{Ur(n,o[0])},unmount:Br(n,e,t)})},Ur=(n,e)=>{let t=go(n);if(t&&mo(n))w(e)?e=$t(e,ve(n))>-1:ue(e)?e=e.has(ve(n)):e=$r(n,e),n.checked=e;else if(t&&ho(n))n.checked=Re(e,ve(n));else if(t||bo(n))yo(n)?n.value!==(e==null?void 0:e.toString())&&(n.value=e):n.value!==e&&(n.value=e);else if(To(n)){let o=n.options,r=o.length,s=n.multiple;for(let i=0;i<r;i++){let a=o[i],c=ve(a);if(s)w(e)?a.selected=$t(e,c)>-1:a.selected=e.has(c);else if(Re(ve(a),e)){n.selectedIndex!==i&&(n.selectedIndex=i);return}}!s&&n.selectedIndex!==-1&&(n.selectedIndex=-1)}else H(7,n)},lt=n=>(R(n)&&(n=n()),F(n)&&(n=n()),n?z(n)?{trim:n.includes("trim"),lazy:n.includes("lazy"),number:n.includes("number"),int:n.includes("int")}:{trim:!!n.trim,lazy:!!n.lazy,number:!!n.number,int:!!n.int}:{trim:!1,lazy:!1,number:!1,int:!1}),mo=n=>n.type==="checkbox",ho=n=>n.type==="radio",yo=n=>n.type==="number"||n.type==="range",go=n=>n.tagName==="INPUT",bo=n=>n.tagName==="TEXTAREA",To=n=>n.tagName==="SELECT",Br=(n,e,t)=>{let o=e.value,r=lt(t==null?void 0:t.join(",")),s=lt(o()[1]),i={int:r.int||s.int,lazy:r.lazy||s.lazy,number:r.number||s.number,trim:r.trim||s.trim};if(!e.refs[0])return H(8,n),()=>{};let a=()=>e.refs[0],c=go(n);return c&&mo(n)?Hr(n,a):c&&ho(n)?qr(n,a):c||bo(n)?Pr(n,i,a,o):To(n)?Fr(n,a,o):(H(7,n),()=>{})},fo=/[.,' ·٫]/,Pr=(n,e,t,o)=>{let s=e.lazy?"change":"input",i=yo(n),a=()=>{!e.trim&&!lt(o()[1]).trim||(n.value=n.value.trim())},c=p=>{let m=p.target;m.composing=1},l=p=>{let m=p.target;m.composing&&(m.composing=0,m.dispatchEvent(new Event(s)))},u=()=>{n.removeEventListener(s,f),n.removeEventListener("change",a),n.removeEventListener("compositionstart",c),n.removeEventListener("compositionend",l),n.removeEventListener("change",l)},f=p=>{let m=t();if(!m)return;let y=p.target;if(!y||y.composing)return;let h=y.value,E=lt(o()[1]);if(i||E.number||E.int){if(E.int)h=parseInt(h);else{if(fo.test(h[h.length-1])&&h.split(fo).length===2){if(h+="0",h=parseFloat(h),isNaN(h))h="";else if(m()===h)return}h=parseFloat(h)}isNaN(h)&&(h=""),n.value=h}else E.trim&&(h=h.trim());m(h)};return n.addEventListener(s,f),n.addEventListener("change",a),n.addEventListener("compositionstart",c),n.addEventListener("compositionend",l),n.addEventListener("change",l),u},Hr=(n,e)=>{let t="change",o=()=>{n.removeEventListener(t,r)},r=()=>{let s=e();if(!s)return;let i=ve(n),a=n.checked,c=s();if(w(c)){let l=$t(c,i),u=l!==-1;a&&!u?c.push(i):!a&&u&&c.splice(l,1)}else ue(c)?a?c.add(i):c.delete(i):s(jr(n,a))};return n.addEventListener(t,r),o},ve=n=>"_value"in n?n._value:n.value,xo="trueValue",Vr="falseValue",Co="true-value",_r="false-value",jr=(n,e)=>{let t=e?xo:Vr;if(t in n)return n[t];let o=e?Co:_r;return n.hasAttribute(o)?n.getAttribute(o):e},$r=(n,e)=>{if(xo in n)return Re(e,n.trueValue);let o=Co;return n.hasAttribute(o)?Re(e,n.getAttribute(o)):Re(e,!0)},qr=(n,e)=>{let t="change",o=()=>{n.removeEventListener(t,r)},r=()=>{let s=e();if(!s)return;let i=ve(n);s(i)};return n.addEventListener(t,r),o},Fr=(n,e,t)=>{let o="change",r=()=>{n.removeEventListener(o,s)},s=()=>{let i=e();if(!i)return;let c=lt(t()[1]).number,l=Array.prototype.filter.call(n.options,u=>u.selected).map(u=>c?lo(ve(u)):ve(u));if(n.multiple){let u=i();try{if(xn(i),ue(u)){u.clear();for(let f of l)u.add(f)}else w(u)?(u.splice(0),u.push(...l)):i(l)}finally{Cn(i),Z(i)}}else i(l[0])};return n.addEventListener(o,s),r};var zr=["stop","prevent","capture","self","once","left","right","middle","passive"],Kr=n=>{let e={};if(J(n))return;let t=n.split(",");for(let o of zr)e[o]=t.includes(o);return e},Wr=(n,e,t,o,r)=>{var l,u;if(o){let f=e.value(),p=$(o.value()[0]);return z(p)?En(n,j(p),()=>e.value()[0],(l=r==null?void 0:r.join(","))!=null?l:f[1]):()=>{}}else if(t){let f=e.value();return En(n,j(t),()=>e.value()[0],(u=r==null?void 0:r.join(","))!=null?u:f[1])}let s=[],i=()=>{s.forEach(f=>f())},a=e.value(),c=a.length;for(let f=0;f<c;++f){let p=a[f];if(F(p)&&(p=p()),D(p))for(let m of Object.entries(p)){let y=m[0],h=()=>{let g=e.value()[f];return F(g)&&(g=g()),g=g[y],F(g)&&(g=g()),g},E=p[y+"_flags"];s.push(En(n,y,h,E))}else H(2,"r-on",n)}return i},Rn={isLazy:(n,e)=>e===-1&&n%2===0,isLazyKey:(n,e)=>e===0&&!n.endsWith("_flags"),once:!1,collectRefObj:!0,mount:({el:n,parseResult:e,option:t,dynamicOption:o,flags:r})=>Wr(n,e,t,o,r)},Gr=(n,e)=>{if(n.startsWith("keydown")||n.startsWith("keyup")||n.startsWith("keypress")){e!=null||(e="");let t=[...n.split("."),...e.split(",")];n=t[0];let o=t[1],r=t.includes("ctrl"),s=t.includes("shift"),i=t.includes("alt"),a=t.includes("meta"),c=l=>!(r&&!l.ctrlKey||s&&!l.shiftKey||i&&!l.altKey||a&&!l.metaKey);return o?[n,l=>c(l)?l.key.toUpperCase()===o.toUpperCase():!1]:[n,c]}return[n,t=>!0]},En=(n,e,t,o)=>{if(J(e))return H(5,"r-on",n),()=>{};let r=Kr(o),s=r?{capture:r.capture,passive:r.passive,once:r.once}:void 0,i;[e,i]=Gr(e,o);let a=u=>{if(!i(u)||!t&&e==="submit"&&(r!=null&&r.prevent))return;let f=t(u);F(f)&&(f=f(u)),F(f)&&f(u)},c=()=>{n.removeEventListener(e,l,s)},l=u=>{if(!r){a(u);return}try{if(r.left&&u.button!==0||r.middle&&u.button!==1||r.right&&u.button!==2||r.self&&u.target!==n)return;r.stop&&u.stopPropagation(),r.prevent&&u.preventDefault(),a(u)}finally{r.once&&c()}};return n.addEventListener(e,l,s),c};var Jr=(n,e,t,o)=>{if(t){o&&o.includes("camel")&&(t=j(t)),Ye(n,t,e[0]);return}let r=e.length;for(let s=0;s<r;++s){let i=e[s];if(w(i)){let a=i[0],c=i[1];Ye(n,a,c)}else if(D(i))for(let a of Object.entries(i)){let c=a[0],l=a[1];Ye(n,c,l)}else{let a=e[s++],c=e[s];Ye(n,a,c)}}},Eo={mount:()=>({update:({el:n,values:e,option:t,flags:o})=>{Jr(n,e,t,o)}})};function Qr(n){return!!n||n===""}var Ye=(n,e,t)=>{if(le(e)){H(3,":prop",n);return}if(e==="innerHTML"||e==="textContent"){let s=[...n.childNodes];setTimeout(()=>s.forEach(Te),1),n[e]=t!=null?t:"";return}let o=n.tagName;if(e==="value"&&o!=="PROGRESS"&&!o.includes("-")){n._value=t;let s=o==="OPTION"?n.getAttribute("value"):n.value,i=t!=null?t:"";s!==i&&(n.value=i),t==null&&n.removeAttribute(e);return}let r=!1;if(t===""||t==null){let s=typeof n[e];s==="boolean"?t=Qr(t):t==null&&s==="string"?(t="",r=!0):s==="number"&&(t=0,r=!0)}try{n[e]=t}catch(s){r||H(4,e,o,t,s)}r&&n.removeAttribute(e)};var Ro={once:!0,mount:({el:n,parseResult:e,expr:t})=>{let o=e,r=o.value()[0],s=w(r),i=o.refs[0];return s?r.push(n):i?i==null||i(n):o.context[t]=n,()=>{if(s){let a=r.indexOf(n);a!==-1&&r.splice(a,1)}else i==null||i(null)}}};var Xr=(n,e)=>{let t=Ue(n).data,o=t._ord;_n(o)&&(o=t._ord=n.style.display),!!e[0]?n.style.display=o:n.style.display="none"},vo={mount:()=>({update:({el:n,values:e})=>{Xr(n,e)}})};var Yr=(n,e,t)=>{let o=e.length;for(let r=0;r<o;++r){let s=e[r],i=t==null?void 0:t[r];if(w(s)){let a=s.length;for(let c=0;c<a;++c)wo(n,s[c],i==null?void 0:i[c])}else wo(n,s,i)}},qt={mount:()=>({update:({el:n,values:e,previousValues:t})=>{Yr(n,e,t)}})},wo=(n,e,t)=>{let o=n.style,r=z(e);if(e&&!r){if(t&&!z(t))for(let s in t)e[s]==null&&wn(o,s,"");for(let s in e)wn(o,s,e[s])}else{let s=o.display;if(r?t!==e&&(o.cssText=e):t&&n.removeAttribute("style"),"_ord"in Ue(n).data)return;o.display=s}},So=/\s*!important$/;function wn(n,e,t){if(w(t))t.forEach(o=>{wn(n,e,o)});else if(t==null&&(t=""),e.startsWith("--"))n.setProperty(e,t);else{let o=Zr(n,e);So.test(t)?n.setProperty(We(o),t.replace(So,""),"important"):n[o]=t}}var Ao=["Webkit","Moz","ms"],vn={};function Zr(n,e){let t=vn[e];if(t)return t;let o=j(e);if(o!=="filter"&&o in n)return vn[e]=o;o=it(o);for(let r=0;r<Ao.length;r++){let s=Ao[r]+o;if(s in n)return vn[e]=s}return e}var ce=n=>No($(n)),No=(n,e=new WeakMap)=>{if(!n||!D(n))return n;if(w(n))return n.map(ce);if(ue(n)){let o=new Set;for(let r of n.keys())o.add(ce(r));return o}if(Ae(n)){let o=new Map;for(let r of n)o.set(ce(r[0]),ce(r[1]));return o}if(e.has(n))return $(e.get(n));let t={...n};e.set(n,t);for(let o of Object.entries(t))t[o[0]]=No($(o[1]),e);return t};var es=(n,e)=>{var o;let t=e[0];n.textContent=ue(t)?JSON.stringify(ce([...t])):Ae(t)?JSON.stringify(ce([...t])):D(t)?JSON.stringify(ce(t)):(o=t==null?void 0:t.toString())!=null?o:""},Oo={mount:()=>({update:({el:n,values:e})=>{es(n,e)}})};var Mo={mount:()=>({update:({el:n,values:e})=>{Ye(n,"value",e[0])}})};var Le=class Le{constructor(e){d(this,"P",{});d(this,"u",{});d(this,"rt",()=>Object.keys(this.P).filter(e=>e.length===1||!e.startsWith(":")));d(this,"be",new Map);d(this,"j",new Map);d(this,"forGrowThreshold",10);d(this,"globalContext");d(this,"useInterpolation",!0);if(this.setDirectives("r-"),e){this.globalContext=e;return}this.globalContext=this.Nt()}static getDefault(){var e;return(e=Le.Ue)!=null?e:Le.Ue=new Le}Nt(){let e={},t=globalThis;for(let o of Le.At.split(","))e[o]=t[o];return e.ref=Ee,e.sref=ae,e.flatten=ce,e}addComponent(...e){for(let t of e){if(!t.defaultName){bt.warning("Registered component's default name is not defined",t);continue}this.be.set(it(t.defaultName),t),this.j.set(it(t.defaultName).toLocaleUpperCase(),t)}}setDirectives(e){this.P={".":Eo,":":bn,"@":Rn,[`${e}on`]:Rn,[`${e}bind`]:bn,[`${e}html`]:Ut,[`${e}text`]:Oo,[`${e}show`]:vo,[`${e}model`]:po,":style":qt,[`${e}style`]:qt,[`${e}bind:style`]:qt,":class":Tn,[`${e}bind:class`]:Tn,":ref":Ro,":value":Mo,[`${e}teleport`]:vt},this.u={for:`${e}for`,if:`${e}if`,else:`${e}else`,elseif:`${e}else-if`,pre:`${e}pre`,inherit:`${e}inherit`,text:`${e}text`,context:":context",contextAlias:`${e}context`,bind:`${e}bind`,on:`${e}on`,keyBind:":key",key:"key",is:":is",teleport:`${e}teleport`,dynamic:"_d_"}}updateDirectives(e){e(this.P,this.u)}};d(Le,"Ue"),d(Le,"At","Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console");var pe=Le;var Ft=(n,e)=>{if(!n)return;let o=(e!=null?e:pe.getDefault()).u,r=/(\{\{[^]*?\}\}|\[\[[^]*?\]\])/g,s=[{start:"{{",end:"}}"},{start:"[[",end:"]]"}];for(let i of ns(n,o.pre,s))ts(i,o.text,r,s)},ts=(n,e,t,o)=>{var c;let r=n.textContent;if(!r)return;let s=t,i=r.split(s);if(i.length<=1)return;if(((c=n.parentElement)==null?void 0:c.childNodes.length)===1&&i.length===3){let l=i[1],u=ko(l,o);if(u&&J(i[0])&&J(i[2])){let f=n.parentElement;f.setAttribute(e,l.substring(u.start.length,l.length-u.end.length)),f.innerText="";return}}let a=document.createDocumentFragment();for(let l of i){let u=ko(l,o);if(u){let f=document.createElement("span");f.setAttribute(e,l.substring(u.start.length,l.length-u.end.length)),a.appendChild(f)}else a.appendChild(document.createTextNode(l))}n.replaceWith(a)},ns=(n,e,t)=>{let o=[],r=s=>{var i;if(s.nodeType===Node.TEXT_NODE)t.some(a=>{var c;return(c=s.textContent)==null?void 0:c.includes(a.start)})&&o.push(s);else{if((i=s==null?void 0:s.hasAttribute)!=null&&i.call(s,e))return;for(let a of Ce(s))r(a)}};return r(n),o},ko=(n,e)=>e.find(t=>n.startsWith(t.start)&&n.endsWith(t.end));var os=9,rs=10,ss=13,is=32,we=46,zt=44,as=39,cs=34,Kt=40,Ze=41,Wt=91,Sn=93,An=63,us=59,Lo=58,Io=123,Gt=125,He=43,Jt=45,Nn=96,Do=47,On=92,Uo=new Set([2,3]),jo={"=":2.5,"*=":2.5,"**=":2.5,"/=":2.5,"%=":2.5,"+=":2.5,"-=":2.5,"<<=":2.5,">>=":2.5,">>>=":2.5,"&=":2.5,"^=":2.5,"|=":2.5},ls={"=>":2,...jo,"||":3,"??":3,"&&":4,"|":5,"^":6,"&":7,"==":8,"!=":8,"===":8,"!==":8,"<":9,">":9,"<=":9,">=":9,in:9,"<<":10,">>":10,">>>":10,"+":11,"-":11,"*":12,"/":12,"%":12,"**":13},$o=Object.keys(jo),fs=new Set($o),kn=new Set(["=>"]);$o.forEach(n=>kn.add(n));var Bo={true:!0,false:!1,null:null},ps="this",et="Expected ",Ve="Unexpected ",In="Unclosed ",ms=et+":",Po=et+"expression",ds="missing }",hs=Ve+"object property",ys=In+"(",Ho=et+"comma",Vo=Ve+"token ",gs=Ve+"period",Mn=et+"expression after ",bs="missing unaryOp argument",Ts=In+"[",xs=et+"exponent (",Cs="Variable names cannot start with a number (",Es=In+'quote after "',ft=n=>n>=48&&n<=57,_o=n=>ls[n],Ln=class{constructor(e){d(this,"p");d(this,"e");this.p=e,this.e=0}get B(){return this.p.charAt(this.e)}get y(){return this.p.charCodeAt(this.e)}f(e){return this.p.charCodeAt(this.e)===e}$(e){return e>=65&&e<=90||e>=97&&e<=122||e===36||e===95||e>=128}ae(e){return this.$(e)||ft(e)}r(e){return new Error(`${e} at character ${this.e}`)}h(){let e=this.y,t=this.p,o=this.e;for(;e===is||e===os||e===rs||e===ss;)e=t.charCodeAt(++o);this.e=o}parse(){let e=this.ce();return e.length===1?e[0]:{type:0,body:e}}ce(e){let t=[];for(;this.e<this.p.length;){let o=this.y;if(o===us||o===zt)this.e++;else{let r=this.S();if(r)t.push(r);else if(this.e<this.p.length){if(o===e)break;throw this.r(Ve+'"'+this.B+'"')}}}return t}S(){var t;let e=(t=this.Ot())!=null?t:this.Pe();return this.h(),this.kt(e)}ue(){this.h();let e=this.p,t=this.e,o=e.charCodeAt(t),r=e.charCodeAt(t+1),s=e.charCodeAt(t+2),i=e.charCodeAt(t+3);if(isNaN(o))return!1;let a=!1,c=0;return o===62&&r===62&&s===62&&i===61?(a=">>>=",c=4):o===61&&r===61&&s===61?(a="===",c=3):o===33&&r===61&&s===61?(a="!==",c=3):o===62&&r===62&&s===62?(a=">>>",c=3):o===60&&r===60&&s===61?(a="<<=",c=3):o===62&&r===62&&s===61?(a=">>=",c=3):o===42&&r===42&&s===61?(a="**=",c=3):o===61&&r===62?(a="=>",c=2):o===124&&r===124?(a="||",c=2):o===63&&r===63?(a="??",c=2):o===38&&r===38?(a="&&",c=2):o===61&&r===61?(a="==",c=2):o===33&&r===61?(a="!=",c=2):o===60&&r===61?(a="<=",c=2):o===62&&r===61?(a=">=",c=2):o===60&&r===60?(a="<<",c=2):o===62&&r===62?(a=">>",c=2):o===43&&r===61?(a="+=",c=2):o===45&&r===61?(a="-=",c=2):o===42&&r===61?(a="*=",c=2):o===47&&r===61?(a="/=",c=2):o===37&&r===61?(a="%=",c=2):o===38&&r===61?(a="&=",c=2):o===94&&r===61?(a="^=",c=2):o===124&&r===61?(a="|=",c=2):o===42&&r===42?(a="**",c=2):o===105&&r===110?this.ae(e.charCodeAt(t+2))||(a="in",c=2):o===61?(a="=",c=1):o===124?(a="|",c=1):o===94?(a="^",c=1):o===38?(a="&",c=1):o===60?(a="<",c=1):o===62?(a=">",c=1):o===43?(a="+",c=1):o===45?(a="-",c=1):o===42?(a="*",c=1):o===47?(a="/",c=1):o===37&&(a="%",c=1),a?(this.e+=c,a):!1}Pe(){let e,t,o,r,s,i,a,c;if(s=this.q(),!s||(t=this.ue(),!t))return s;if(r={value:t,prec:_o(t),right_a:kn.has(t)},i=this.q(),!i)throw this.r(Mn+t);let l=[s,r,i];for(;t=this.ue();){o=_o(t),r={value:t,prec:o,right_a:kn.has(t)},c=t;let u=f=>r.right_a&&f.right_a?o>f.prec:o<=f.prec;for(;l.length>2&&u(l[l.length-2]);)i=l.pop(),t=l.pop().value,s=l.pop(),e=this.Be(t,s,i),l.push(e);if(e=this.q(),!e)throw this.r(Mn+c);l.push(r,e)}for(a=l.length-1,e=l[a];a>1;)e=this.Be(l[a-1].value,l[a-2],e),a-=2;return e}q(){let e;if(this.h(),e=this.Mt(),e)return this.pe(e);let t=this.y;if(ft(t)||t===we)return this.Lt();if(t===as||t===cs)e=this.Vt();else if(t===Wt)e=this.It();else{let o=this.Dt();if(o){let r=this.q();if(!r)throw this.r(bs);return this.pe({type:7,operator:o,argument:r})}this.$(t)?(e=this.le(),e.name in Bo?e={type:4,value:Bo[e.name],raw:e.name}:e.name===ps&&(e={type:5})):t===Kt&&(e=this.Ut())}return e?(e=this.F(e),this.pe(e)):!1}Be(e,t,o){if(e==="=>"){let r=t.type===1?t.expressions:[t];return{type:15,params:r,body:o}}return fs.has(e)?{type:16,operator:e,left:t,right:o}:{type:8,operator:e,left:t,right:o}}Mt(){let e={node:!1};return this.Pt(e),e.node||(this.Bt(e),e.node)||(this.Ht(e),e.node)||(this.He(e),e.node)||this.jt(e),e.node}pe(e){let t={node:e};return this._t(t),this.$t(t),this.qt(t),t.node}Dt(){let e=this.p,t=this.e,o=e.charCodeAt(t),r=e.charCodeAt(t+1),s=e.charCodeAt(t+2),i=e.charCodeAt(t+3);return o===Jt?(this.e++,"-"):o===33?(this.e++,"!"):o===126?(this.e++,"~"):o===He?(this.e++,"+"):o===110&&r===101&&s===119&&!this.ae(i)?(this.e+=3,"new"):!1}Ot(){let e={};return this.Ft(e),e.node}kt(e){let t={node:e};return this.Kt(t),t.node}F(e){this.h();let t=this.y;for(;t===we||t===Wt||t===Kt||t===An;){let o;if(t===An){if(this.p.charCodeAt(this.e+1)!==we)break;o=!0,this.e+=2,this.h(),t=this.y}if(this.e++,t===Wt){if(e={type:3,computed:!0,object:e,property:this.S()},this.h(),t=this.y,t!==Sn)throw this.r(Ts);this.e++}else t===Kt?e={type:6,arguments:this.je(Ze),callee:e}:(o&&this.e--,this.h(),e={type:3,computed:!1,object:e,property:this.le()});o&&(e.optional=!0),this.h(),t=this.y}return e}Lt(){let e=this.p,t=this.e,o=t;for(;ft(e.charCodeAt(o));)o++;if(e.charCodeAt(o)===we)for(o++;ft(e.charCodeAt(o));)o++;let r=e.charCodeAt(o);if(r===101||r===69){o++;let a=e.charCodeAt(o);(a===He||a===Jt)&&o++;let c=o;for(;ft(e.charCodeAt(o));)o++;if(c===o){this.e=o;let l=e.slice(t,o);throw this.r(xs+l+this.B+")")}}this.e=o;let s=e.slice(t,o),i=e.charCodeAt(o);if(this.$(i))throw this.r(Cs+s+this.B+")");if(i===we||s.length===1&&s.charCodeAt(0)===we)throw this.r(gs);return{type:4,value:parseFloat(s),raw:s}}Vt(){let e=this.p,t=e.length,o=this.e,r=e.charCodeAt(this.e++),s=this.e,i=s,a=[],c=!1,l=!1;for(;s<t;){let f=e.charCodeAt(s);if(f===r){l=!0,this.e=s+1;break}if(f===On){c||(c=!0),a.push(e.slice(i,s));let p=e.charCodeAt(s+1);a.push(this._e(p)),s+=2,i=s}else s++}let u=c?a.join("")+e.slice(i,l?s:t):e.slice(i,l?s:t);if(!l)throw this.e=s,this.r(Es+u+'"');return{type:4,value:u,raw:e.substring(o,this.e)}}_e(e){switch(e){case 110:return`
|
|
2
|
-
`;case 114:return"\r";case 116:return" ";case 98:return"\b";case 102:return"\f";case 118:return"\v";default:return isNaN(e)?"":String.fromCharCode(e)}}le(){let e=this.y,t=this.e;if(this.$(e))this.e++;else throw this.r(Ve+this.B);for(;this.e<this.p.length&&(e=this.y,this.ae(e));)this.e++;return{type:2,name:this.p.slice(t,this.e)}}je(e){let t=[],o=!1,r=0;for(;this.e<this.p.length;){this.h();let s=this.y;if(s===e){if(o=!0,this.e++,e===Ze&&r&&r>=t.length)throw this.r(Vo+String.fromCharCode(e));break}else if(s===zt){if(this.e++,r++,r!==t.length){if(e===Ze)throw this.r(Vo+",");for(let i=t.length;i<r;i++)t.push(null)}}else{if(t.length!==r&&r!==0)throw this.r(Ho);{let i=this.S();if(!i||i.type===0)throw this.r(Ho);t.push(i)}}}if(!o)throw this.r(et+String.fromCharCode(e));return t}Ut(){this.e++;let e=this.ce(Ze);if(this.f(Ze))return this.e++,e.length===1?e[0]:e.length?{type:1,expressions:e}:!1;throw this.r(ys)}It(){return this.e++,{type:9,elements:this.je(Sn)}}Pt(e){if(this.f(Io)){this.e++;let t=[];for(;!isNaN(this.y);){if(this.h(),this.f(Gt)){this.e++,e.node=this.F({type:10,properties:t});return}let o=this.S();if(!o)break;if(this.h(),o.type===2&&(this.f(zt)||this.f(Gt)))t.push({type:12,computed:!1,key:o,value:o,shorthand:!0});else if(this.f(Lo)){this.e++;let r=this.S();if(!r)throw this.r(hs);let s=o.type===9;t.push({type:12,computed:s,key:s?o.elements[0]:o,value:r,shorthand:!1}),this.h()}else t.push(o);this.f(zt)&&this.e++}throw this.r(ds)}}Bt(e){let t=this.y;if((t===He||t===Jt)&&t===this.p.charCodeAt(this.e+1)){this.e+=2;let o=e.node={type:13,operator:t===He?"++":"--",argument:this.F(this.le()),prefix:!0};if(!o.argument||!Uo.has(o.argument.type))throw this.r(Ve+o.operator)}}$t(e){let t=e.node,o=this.y;if((o===He||o===Jt)&&o===this.p.charCodeAt(this.e+1)){if(!Uo.has(t.type))throw this.r(Ve+(o===He?"++":"--"));this.e+=2,e.node={type:13,operator:o===He?"++":"--",argument:t,prefix:!1}}}Ht(e){this.p.charCodeAt(this.e)===we&&this.p.charCodeAt(this.e+1)===we&&this.p.charCodeAt(this.e+2)===we&&(this.e+=3,e.node={type:14,argument:this.S()})}Kt(e){if(e.node&&this.f(An)){this.e++;let t=e.node,o=this.S();if(!o)throw this.r(Po);if(this.h(),this.f(Lo)){this.e++;let r=this.S();if(!r)throw this.r(Po);e.node={type:11,test:t,consequent:o,alternate:r}}else throw this.r(ms)}}Ft(e){if(this.h(),this.f(Kt)){let t=this.e;if(this.e++,this.h(),this.f(Ze)){this.e++;let o=this.ue();if(o==="=>"){let r=this.Pe();if(!r)throw this.r(Mn+o);e.node={type:15,params:null,body:r};return}}this.e=t}}qt(e){let t=e.node,o=t.type;(o===2||o===3)&&this.f(Nn)&&(e.node={type:17,tag:t,quasi:this.He(e)})}He(e){if(!this.f(Nn))return;let t=this.p,o=t.length,r={type:19,quasis:[],expressions:[]},s=++this.e,i=[],a=[],c=!1,l=u=>{if(!c){let m=t.slice(s,this.e);return r.quasis.push({type:18,value:{raw:m,cooked:m},tail:u})}i.push(t.slice(s,this.e)),a.push(t.slice(s,this.e));let f=i.join(""),p=a.join("");return i.length=0,a.length=0,c=!1,r.quasis.push({type:18,value:{raw:f,cooked:p},tail:u})};for(;this.e<o;){let u=t.charCodeAt(this.e);if(u===Nn)return l(!0),this.e+=1,e.node=r,r;if(u===36&&t.charCodeAt(this.e+1)===Io){if(l(!1),this.e+=2,r.expressions.push(...this.ce(Gt)),!this.f(Gt))throw this.r("unclosed ${");this.e+=1,s=this.e}else if(u===On){c||(c=!0),i.push(t.slice(s,this.e)),a.push(t.slice(s,this.e));let f=t.charCodeAt(this.e+1);i.push(t.slice(this.e,this.e+2)),a.push(this._e(f)),this.e+=2,s=this.e}else this.e+=1}throw this.r("Unclosed `")}_t(e){let t=e.node;if(!t||t.operator!=="new"||!t.argument)return;if(!t.argument||![6,3].includes(t.argument.type))throw this.r("Expected new function()");e.node=t.argument;let o=e.node;for(;o.type===3||o.type===6&&o.callee.type===3;)o=o.type===3?o.object:o.callee.object;o.type=20}jt(e){if(!this.f(Do))return;let t=++this.e,o=!1;for(;this.e<this.p.length;){if(this.y===Do&&!o){let r=this.p.slice(t,this.e),s="";for(;++this.e<this.p.length;){let a=this.y;if(a>=97&&a<=122||a>=65&&a<=90||a>=48&&a<=57)s+=this.B;else break}let i;try{i=new RegExp(r,s)}catch(a){throw this.r(a.message)}return e.node={type:4,value:i,raw:this.p.slice(t-1,this.e)},e.node=this.F(e.node),e.node}this.f(Wt)?o=!0:o&&this.f(Sn)&&(o=!1),this.e+=this.f(On)?2:1}throw this.r("Unclosed Regex")}},qo=n=>new Ln(n).parse();var Rs={"=>":(n,e)=>{},"=":(n,e)=>{},"*=":(n,e)=>{},"**=":(n,e)=>{},"/=":(n,e)=>{},"%=":(n,e)=>{},"+=":(n,e)=>{},"-=":(n,e)=>{},"<<=":(n,e)=>{},">>=":(n,e)=>{},">>>=":(n,e)=>{},"&=":(n,e)=>{},"^=":(n,e)=>{},"|=":(n,e)=>{},"||":(n,e)=>n()||e(),"??":(n,e)=>{var t;return(t=n())!=null?t:e()},"&&":(n,e)=>n()&&e(),"|":(n,e)=>n|e,"^":(n,e)=>n^e,"&":(n,e)=>n&e,"==":(n,e)=>n==e,"!=":(n,e)=>n!=e,"===":(n,e)=>n===e,"!==":(n,e)=>n!==e,"<":(n,e)=>n<e,">":(n,e)=>n>e,"<=":(n,e)=>n<=e,">=":(n,e)=>n>=e,in:(n,e)=>n in e,"<<":(n,e)=>n<<e,">>":(n,e)=>n>>e,">>>":(n,e)=>n>>>e,"+":(n,e)=>n+e,"-":(n,e)=>n-e,"*":(n,e)=>n*e,"/":(n,e)=>n/e,"%":(n,e)=>n%e,"**":(n,e)=>n**e},vs={"-":n=>-n,"+":n=>+n,"!":n=>!n,"~":n=>~n,new:n=>n},Wo=n=>{if(!(n!=null&&n.some(Ko)))return n;let e=[];return n.forEach(t=>Ko(t)?e.push(...t):e.push(t)),e},Fo=(...n)=>Wo(n),Dn=(n,e)=>{if(!n)return e;let t=Object.create(e!=null?e:{});return t.$event=n,t},ws={"++":(n,e)=>{let t=n[e];if(R(t)){let o=t();return t(++o),o}return++n[e]},"--":(n,e)=>{let t=n[e];if(R(t)){let o=t();return t(--o),o}return--n[e]}},Ss={"++":(n,e)=>{let t=n[e];if(R(t)){let o=t();return t(o+1),o}return n[e]++},"--":(n,e)=>{let t=n[e];if(R(t)){let o=t();return t(o-1),o}return n[e]--}},zo={"=":(n,e,t)=>{let o=n[e];return R(o)?o(t):n[e]=t},"+=":(n,e,t)=>{let o=n[e];return R(o)?o(o()+t):n[e]+=t},"-=":(n,e,t)=>{let o=n[e];return R(o)?o(o()-t):n[e]-=t},"*=":(n,e,t)=>{let o=n[e];return R(o)?o(o()*t):n[e]*=t},"/=":(n,e,t)=>{let o=n[e];return R(o)?o(o()/t):n[e]/=t},"%=":(n,e,t)=>{let o=n[e];return R(o)?o(o()%t):n[e]%=t},"**=":(n,e,t)=>{let o=n[e];return R(o)?o(o()**t):n[e]**=t},"<<=":(n,e,t)=>{let o=n[e];return R(o)?o(o()<<t):n[e]<<=t},">>=":(n,e,t)=>{let o=n[e];return R(o)?o(o()>>t):n[e]>>=t},">>>=":(n,e,t)=>{let o=n[e];return R(o)?o(o()>>>t):n[e]>>>=t},"|=":(n,e,t)=>{let o=n[e];return R(o)?o(o()|t):n[e]|=t},"&=":(n,e,t)=>{let o=n[e];return R(o)?o(o()&t):n[e]&=t},"^=":(n,e,t)=>{let o=n[e];return R(o)?o(o()^t):n[e]^=t}},Qt=(n,e)=>F(n)?n.bind(e):n,Un=class{constructor(e,t,o,r,s){d(this,"l");d(this,"$e");d(this,"qe");d(this,"Fe");d(this,"A");d(this,"Ke");d(this,"ze");this.l=w(e)?e:[e],this.$e=t,this.qe=o,this.Fe=r,this.ze=!!s}We(e,t){if(t&&e in t)return t;for(let o of this.l)if(e in o)return o}2(e,t,o){let r=e.name;if(r==="$root")return this.l[this.l.length-1];if(r==="$parent")return this.l[1];if(r==="$ctx")return[...this.l];if(o&&r in o)return this.A=o[r],Qt($(o[r]),o);for(let i of this.l)if(r in i)return this.A=i[r],Qt($(i[r]),i);let s=this.$e;if(s&&r in s)return this.A=s[r],Qt($(s[r]),s)}5(e,t,o){return this.l[0]}0(e,t,o){return this.Ge(t,o,Fo,...e.body)}1(e,t,o){return this.E(t,o,(...r)=>r.pop(),...e.expressions)}3(e,t,o){let{obj:r,key:s}=this.fe(e,t,o),i=r==null?void 0:r[s];return this.A=i,Qt($(i),r)}4(e,t,o){return e.value}6(e,t,o){let r=(i,...a)=>F(i)?i(...Wo(a)):i,s=this.E(++t,o,r,e.callee,...e.arguments);return this.A=s,s}7(e,t,o){return this.E(t,o,vs[e.operator],e.argument)}8(e,t,o){let r=Rs[e.operator];switch(e.operator){case"||":case"&&":case"??":return r(()=>this.g(e.left,t,o),()=>this.g(e.right,t,o))}return this.E(t,o,r,e.left,e.right)}9(e,t,o){return this.Ge(++t,o,Fo,...e.elements)}10(e,t,o){let r={},s=(...i)=>{i.forEach(a=>{Object.assign(r,a)})};return this.E(++t,o,s,...e.properties),r}11(e,t,o){return this.E(t,o,r=>this.g(r?e.consequent:e.alternate,t,o),e.test)}12(e,t,o){var u;let r={},s=f=>(f==null?void 0:f.type)!==15,i=(u=this.Fe)!=null?u:()=>!1,a=t===0&&this.ze,c=f=>this.Je(a,e.key,t,Dn(f,o)),l=f=>this.Je(a,e.value,t,Dn(f,o));if(e.shorthand){let f=e.key.name;r[f]=s(e.key)&&i(f,t)?c:c()}else if(e.computed){let f=$(c());r[f]=s(e.value)&&i(f,t)?l:l()}else{let f=e.key.type===4?e.key.value:e.key.name;r[f]=s(e.value)&&i(f,t)?()=>l:l()}return r}fe(e,t,o){let r=this.g(e.object,t,o),s=e.computed?this.g(e.property,t,o):e.property.name;return{obj:r,key:s}}13(e,t,o){let r=e.argument,s=e.operator,i=e.prefix?ws:Ss;if(r.type===2){let a=r.name,c=this.We(a,o);return le(c)?void 0:i[s](c,a)}if(r.type===3){let{obj:a,key:c}=this.fe(r,t,o);return i[s](a,c)}}16(e,t,o){let r=e.left,s=e.operator;if(r.type===2){let i=r.name,a=this.We(i,o);if(le(a))return;let c=this.g(e.right,t,o);return zo[s](a,i,c)}if(r.type===3){let{obj:i,key:a}=this.fe(r,t,o),c=this.g(e.right,t,o);return zo[s](i,a,c)}}14(e,t,o){let r=this.g(e.argument,t,o);return w(r)&&(r.s=Go),r}17(e,t,o){return this[6]({type:6,callee:e.tag,arguments:[{type:9,elements:e.quasi.quasis},...e.quasi.expressions]},t,o)}19(e,t,o){let r=(...s)=>s.reduce((i,a,c)=>i+=a+e.quasis[c+1].value.cooked,e.quasis[0].value.cooked);return this.E(t,o,r,...e.expressions)}18(e,t,o){return e.value.cooked}20(e,t,o){let r=(s,...i)=>new s(...i);return this.E(t,o,r,e.callee,...e.arguments)}15(e,t,o){return(...r)=>{let s=Object.create(o!=null?o:{}),i=e.params;if(i){let a=0;for(let c of i)s[c.name]=r[a++]}return this.g(e.body,t,s)}}g(e,t,o){let r=$(this[e.type](e,t,o));return this.Ke=e.type,r}Je(e,t,o,r){let s=this.g(t,o,r);return e&&this.Qe()?this.A:s}Qe(){let e=this.Ke;return(e===2||e===3||e===6)&&R(this.A)}eval(e,t){let{value:o,refs:r}=dn(()=>this.g(e,-1,t)),s={value:o,refs:r};return this.Qe()&&(s.ref=this.A),s}E(e,t,o,...r){let s=r.map(i=>i&&this.g(i,e,t));return o(...s)}Ge(e,t,o,...r){let s=this.qe;if(!s)return this.E(e,t,o,...r);let i=r.map((a,c)=>a&&(a.type!==15&&s(c,e)?l=>this.g(a,e,Dn(l,t)):this.g(a,e,t)));return o(...i)}},Go=Symbol("s"),Ko=n=>(n==null?void 0:n.s)===Go,Jo=(n,e,t,o,r,s,i)=>new Un(e,t,o,r,i).eval(n,s);var Qo={},Xo=n=>!!n,Xt=class{constructor(e,t){d(this,"l");d(this,"o");d(this,"Xe",[]);this.l=e,this.o=t}v(e){this.l=[e,...this.l]}J(){return this.l.map(t=>t.components).filter(Xo).reverse().reduce((t,o)=>{for(let[r,s]of Object.entries(o))t[r.toUpperCase()]=s;return t},{})}ot(){let e=[],t=new Set,o=this.l.map(r=>r.components).filter(Xo).reverse();for(let r of o)for(let s of Object.keys(r))t.has(s)||(t.add(s),e.push(s));return e}k(e,t,o,r,s){var g;let i=[],a=[],c=new Set,l=()=>{for(let C=0;C<a.length;++C)a[C]();a.length=0},p={value:()=>i,stop:()=>{l(),c.clear()},subscribe:(C,U)=>(c.add(C),U&&C(i),()=>{c.delete(C)}),refs:[],context:this.l[0]};if(J(e))return p;let m=this.o.globalContext,y=[],h=new Set,E=(C,U,W,L)=>{try{let V=Jo(C,U,m,t,o,L,r);return W&&V.refs.length>0&&y.push(...V.refs),{value:V.value,refs:V.refs,ref:V.ref}}catch(V){H(6,`evaluation error: ${e}`,V)}return{value:void 0,refs:[]}};try{let C=(g=Qo[e])!=null?g:qo("["+e+"]");Qo[e]=C;let U=this.l.slice(),W=C.elements,L=W.length,V=new Array(L);p.refs=V;let ie=()=>{y.length=0,s||(h.clear(),l());let ee=new Array(L);for(let B=0;B<L;++B){let b=W[B];if(t!=null&&t(B,-1)){ee[B]=Q=>E(b,U,!1,{$event:Q}).value;continue}let N=E(b,U,!0);ee[B]=N.value,V[B]=N.ref}if(!s)for(let B of y)h.has(B)||(h.add(B),a.push(se(B,ie)));if(i=ee,c.size!==0)for(let B of c)c.has(B)&&B(i)};ie()}catch(C){H(6,`parse error: ${e}`,C)}return p}M(){return this.l.slice()}oe(e){this.Xe.push(this.l),this.l=e}C(e,t){try{this.oe(e),t()}finally{this.zt()}}zt(){var e;this.l=(e=this.Xe.pop())!=null?e:[]}};var Yo=n=>{let e=n.charCodeAt(0);return e>=48&&e<=57||e>=65&&e<=90||e>=97&&e<=122||n==="-"||n==="_"||n===":"},As=(n,e)=>{let t="";for(let o=e;o<n.length;++o){let r=n[o];if(t){r===t&&(t="");continue}if(r==='"'||r==="'"){t=r;continue}if(r===">")return o}return-1},Ns=(n,e)=>{let t=e?2:1;for(;t<n.length&&(n[t]===" "||n[t]===`
|
|
3
|
-
`);)++t;if(t>=n.length||!Yo(n[t]))return null;let o=t;for(;t<n.length&&Yo(n[t]);)++t;return{start:o,end:t}},Zo=new Set(["table","thead","tbody","tfoot"]),Os=new Set(["thead","tbody","tfoot"]),Ms=new Set(["caption","colgroup","thead","tbody","tfoot","tr"]),ks=new Set(["area","base","br","col","embed","hr","img","input","link","meta","param","source","track","wbr"]),er=(n,e)=>`${n.slice(0,n.length-2)}></${e}>`,Yt=n=>{var s;let e=0,t=[],o=[],r=0;for(;e<n.length;){let i=n.indexOf("<",e);if(i===-1){t.push(n.slice(e));break}if(t.push(n.slice(e,i)),n.startsWith("<!--",i)){let g=n.indexOf("-->",i+4);if(g===-1){t.push(n.slice(i));break}t.push(n.slice(i,g+3)),e=g+3;continue}let a=As(n,i);if(a===-1){t.push(n.slice(i));break}let c=n.slice(i,a+1),l=c.startsWith("</");if(c.startsWith("<!")||c.startsWith("<?")){t.push(c),e=a+1;continue}let f=Ns(c,l);if(!f){t.push(c),e=a+1;continue}let p=c.slice(f.start,f.end);if(l){let g=o[o.length-1];g?(o.pop(),t.push(g.replacementHost?`</${g.replacementHost}>`:c),Zo.has(g.effectiveTag)&&--r):t.push(c),e=a+1;continue}let m=c.charCodeAt(c.length-2)===47,y=o[o.length-1],h=null;r===0?p==="tr"?h="trx":p==="td"?h="tdx":p==="th"&&(h="thx"):Os.has((s=y==null?void 0:y.effectiveTag)!=null?s:"")?h=p==="tr"?null:"tr":(y==null?void 0:y.effectiveTag)==="table"?h=Ms.has(p)?null:"tr":(y==null?void 0:y.effectiveTag)==="tr"&&(h=p==="td"||p==="th"?null:"td");let E=m&&!ks.has(h||p);if(h){let g=h==="trx"||h==="tdx"||h==="thx",C=`${c.slice(0,f.start)}${h} is="${g?`r-${p}`:`regor:${p}`}"${c.slice(f.end)}`;t.push(E?er(C,h):C)}else t.push(E?er(c,p):c);if(!m){let g=h==="trx"?"tr":h==="tdx"?"td":h==="thx"?"th":h||p;o.push({replacementHost:h,effectiveTag:g}),Zo.has(g)&&++r}e=a+1}return t.join("")};var Ls="svg,animate,animateMotion,animateTransform,circle,clipPath,color-profile,defs,desc,discard,ellipse,feBlend,feColorMatrix,feComponentTransfer,feComposite,feConvolveMatrix,feDiffuseLighting,feDisplacementMap,feDistantLight,feDropShadow,feFlood,feFuncA,feFuncB,feFuncG,feFuncR,feGaussianBlur,feImage,feMerge,feMergeNode,feMorphology,feOffset,fePointLight,feSpecularLighting,feSpotLight,feTile,feTurbulence,filter,foreignObject,g,hatch,hatchpath,image,line,linearGradient,marker,mask,mesh,meshgradient,meshpatch,meshrow,metadata,mpath,path,pattern,polygon,polyline,radialGradient,rect,set,solidcolor,stop,switch,symbol,text,textPath,title,tspan,unknown,use,view",Is=new Set(Ls.toUpperCase().split(",")),Ds="http://www.w3.org/2000/svg",tr=(n,e)=>{he(n)?n.content.appendChild(e):n.appendChild(e)},Bn=(n,e,t,o)=>{var i;let r=n.t;if(r){let a=t&&Is.has(r.toUpperCase())?document.createElementNS(Ds,r.toLowerCase()):document.createElement(r),c=n.a;if(c)for(let u of Object.entries(c)){let f=u[0],p=u[1];f.startsWith("#")&&(p=f.substring(1),f="name"),a.setAttribute(Rt(f,o),p)}let l=n.c;if(l)for(let u of l)Bn(u,a,t,o);tr(e,a);return}let s=n.d;if(s){let a;switch((i=n.n)!=null?i:Node.TEXT_NODE){case Node.COMMENT_NODE:a=document.createComment(s);break;case Node.TEXT_NODE:a=document.createTextNode(s);break}if(a)tr(e,a);else throw new Error("unsupported node type.")}},tt=(n,e,t)=>{t!=null||(t=pe.getDefault());let o=document.createDocumentFragment();if(!w(n))return Bn(n,o,!!e,t),o;for(let r of n)Bn(r,o,!!e,t);return o};var Us=(n,e={selector:"#app"},t)=>{z(e)&&(e={selector:"#app",template:e}),Zn(n)&&(n=n.context);let o=e.element?e.element:e.selector?document.querySelector(e.selector):null;if(!o||!Be(o))throw _(0);t||(t=pe.getDefault());let r=()=>{for(let a of[...o.childNodes])G(a)},s=a=>{for(let c of a)o.appendChild(c)};if(e.template){let a=document.createRange().createContextualFragment(Yt(e.template));r(),s(a.childNodes),e.element=a}else if(e.json){let a=tt(e.json,e.isSVG,t);r(),s(a.childNodes)}return t.useInterpolation&&Ft(o,t),new Pn(n,o,t).b(),K(o,()=>{Ne(n)}),wt(n),{context:n,unmount:()=>{G(o)},unbind:()=>{Te(o)}}},Pn=class{constructor(e,t,o){d(this,"Wt");d(this,"Ye");d(this,"o");d(this,"m");d(this,"i");this.Wt=e,this.Ye=t,this.o=o,this.m=new Xt([e],o),this.i=new _t(this.m)}b(){this.i.H(this.Ye)}};var pt=n=>{if(w(n))return n.map(r=>pt(r));let e={};if(n.tagName)e.t=n.tagName;else return n.nodeType===Node.COMMENT_NODE&&(e.n=Node.COMMENT_NODE),n.textContent&&(e.d=n.textContent),e;let t=n.getAttributeNames();t.length>0&&(e.a=Object.fromEntries(t.map(r=>{var s;return[r,(s=n.getAttribute(r))!=null?s:""]})));let o=Ce(n);return o.length>0&&(e.c=[...o].map(r=>pt(r))),e};var Bs=(n,e={})=>{var s,i,a,c,l,u;w(e)&&(e={props:e}),z(n)&&(n={template:n});let t=(s=e.context)!=null?s:()=>({}),o=!1;if(n.element){let f=n.element;f.remove(),n.element=f}else if(n.selector){let f=document.querySelector(n.selector);if(!f)throw _(1,n.selector);f.remove(),n.element=f}else if(n.template){let f=document.createRange().createContextualFragment(Yt(n.template));n.element=f}else n.json&&(n.element=tt(n.json,n.isSVG,e.config),o=!0);n.element||(n.element=document.createDocumentFragment()),((i=e.useInterpolation)==null||i)&&Ft(n.element,(a=e.config)!=null?a:pe.getDefault());let r=n.element;if(!o&&(((l=n.isSVG)!=null?l:st(r)&&((c=r.hasAttribute)!=null&&c.call(r,"isSVG")))||st(r)&&r.querySelector("[isSVG]"))){let f=r.content,p=f?[...f.childNodes]:[...r.childNodes],m=pt(p);n.element=tt(m,!0,e.config)}return{context:t,template:n.element,inheritAttrs:(u=e.inheritAttrs)!=null?u:!0,props:e.props,defaultName:e.defaultName}};var Hn=class{constructor(){d(this,"byConstructor",new Map)}register(e){this.byConstructor.set(e.constructor,e)}unregisterByClass(e){this.byConstructor.delete(e)}unregister(e){let t=e.constructor;this.byConstructor.get(t)===e&&this.byConstructor.delete(t)}find(e){for(let t of this.byConstructor.values())if(t instanceof e)return t}require(e){let t=this.find(e);if(t)return t;throw new Error(`${e.name} is not registered in ContextRegistry.`)}};var Ps=n=>{var e;(e=De())==null||e.onMounted.push(n)};var Hs=n=>{let e,t={},o=(...r)=>{if(r.length<=2&&0 in r)throw _(4);return e&&!t.isStopped?e(...r):(e=Vs(n,t),e(...r))};return o[Y]=1,ke(o,!0),o.stop=()=>{var r,s;return(s=(r=t.ref)==null?void 0:r.stop)==null?void 0:s.call(r)},re(()=>o.stop(),!0),o},Vs=(n,e)=>{var s;let t=(s=e.ref)!=null?s:ae(null);e.ref=t,e.isStopped=!1;let o=0,r=Qe(()=>{if(o>0){r(),e.isStopped=!0,Z(t);return}t(n()),++o});return t.stop=r,t};var _s=(n,e)=>{let t={},o,r=(...s)=>{if(s.length<=2&&0 in s)throw _(4);return o&&!t.isStopped?o(...s):(o=js(n,e,t),o(...s))};return r[Y]=1,ke(r,!0),r.stop=()=>{var s,i;return(i=(s=t.ref)==null?void 0:s.stop)==null?void 0:i.call(s)},re(()=>r.stop(),!0),r},js=(n,e,t)=>{var a;let o=(a=t.ref)!=null?a:ae(null);t.ref=o,t.isStopped=!1;let r=0,s=c=>{if(r>0){o.stop(),t.isStopped=!0,Z(o);return}let l=n.map(u=>u());o(e(...l)),++r},i=[];for(let c of n){let l=se(c,s);i.push(l)}return s(null),o.stop=()=>{i.forEach(c=>{c()})},o};var $s=(n,e)=>{let t={},o,r=(...s)=>{if(s.length<=2&&0 in s)throw _(4);return o&&!t.isStopped?o(...s):(o=qs(n,e,t),o(...s))};return r[Y]=1,ke(r,!0),r.stop=()=>{var s,i;return(i=(s=t.ref)==null?void 0:s.stop)==null?void 0:i.call(s)},re(()=>r.stop(),!0),r},qs=(n,e,t)=>{var s;let o=(s=t.ref)!=null?s:ae(null);t.ref=o,t.isStopped=!1;let r=0;return o.stop=se(n,i=>{if(r>0){o.stop(),t.isStopped=!0,Z(o);return}o(e(i)),++r},!0),o};var Fs=n=>(n[At]=1,n);var zs=(n,e)=>{if(!e)throw _(5);let o=Je(n)?Ee:a=>a,r=()=>localStorage.setItem(e,JSON.stringify(ce(n()))),s=localStorage.getItem(e);if(s!=null)try{n(o(JSON.parse(s)))}catch(a){H(6,`persist: failed to parse data for key ${e}`,a),r()}else r();let i=Qe(r);return re(i,!0),n};var nr=(n,...e)=>{let t="",o=n,r=e,s=o.length,i=r.length;for(let a=0;a<s;++a)t+=o[a],a<i&&(t+=r[a]);return t},Ks=nr;var Ws=(n,e,t)=>{let o=[],r=()=>{e(n.map(i=>i()))};for(let i of n)o.push(se(i,r));t&&r();let s=()=>{for(let i of o)i()};return re(s,!0),s};var Gs=n=>{if(!R(n))throw _(3,"observerCount");return n(void 0,void 0,2)};var Js=n=>{or();try{n()}finally{rr()}},or=()=>{ye.stack||(ye.stack=[]),ye.stack.push(new Set)},rr=()=>{let n=ye.stack;if(!n||n.length===0)return;let e=n.pop();if(n.length){let t=n[n.length-1];for(let o of e)t.add(o);return}delete ye.stack;for(let t of e)try{Z(t)}catch(o){console.error(o)}};export{ot as ComponentHead,Hn as ContextRegistry,pe as RegorConfig,K as addUnbinder,Js as batch,dn as collectRefs,_s as computeMany,$s as computeRef,Hs as computed,Us as createApp,Bs as defineComponent,cr as drainUnbind,rr as endBatch,at as entangle,ce as flatten,Ue as getBindData,nr as html,Je as isDeepRef,ct as isRaw,R as isRef,Fs as markRaw,se as observe,Ws as observeMany,Gs as observerCount,Ps as onMounted,re as onUnmounted,xn as pause,zs as persist,Ks as raw,Ee as ref,G as removeNode,Cn as resume,mn as silence,ae as sref,or as startBatch,tt as toFragment,pt as toJsonTemplate,Z as trigger,Te as unbind,$ as unref,fn as useScope,bt as warningHandler,Qe as watchEffect};
|
|
1
|
+
var ir=Object.defineProperty;var ar=(t,e,n)=>e in t?ir(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n;var m=(t,e,n)=>ar(t,typeof e!="symbol"?e+"":e,n);var Be=Symbol(":regor");var ge=t=>{let e=[t];for(let n=0;n<e.length;++n){let o=e[n];cr(o);for(let r=o.lastChild;r!=null;r=r.previousSibling)e.push(r)}},cr=t=>{let e=t[Be];if(!e)return;let n=e.unbinders;for(let o=0;o<n.length;++o)n[o]();n.length=0,t[Be]=void 0};var je=[],ft=!1,pt,jn=()=>{if(ft=!1,pt=void 0,je.length!==0){for(let t=0;t<je.length;++t)ge(je[t]);je.length=0}},J=t=>{t.remove(),je.push(t),ft||(ft=!0,pt=setTimeout(jn,1))},ur=async()=>{je.length===0&&!ft||(pt&&clearTimeout(pt),jn())};var q=t=>typeof t=="function",z=t=>typeof t=="string",_n=t=>typeof t=="undefined",fe=t=>t==null||typeof t=="undefined",F=t=>typeof t!="string"||!(t!=null&&t.trim()),lr=Object.prototype.toString,en=t=>lr.call(t),we=t=>en(t)==="[object Map]",ue=t=>en(t)==="[object Set]",tn=t=>en(t)==="[object Date]",Ye=t=>typeof t=="symbol",w=Array.isArray,I=t=>t!==null&&typeof t=="object";var $n={0:"createApp can't find root element. You must define either a valid `selector` or an `element`. Example: createApp({}, {selector: '#app', html: '...'})",1:t=>`Component template cannot be found. selector: ${t} .`,2:"Use composables in scope. usage: useScope(() => new MyApp()).",3:t=>`${t} requires ref source argument`,4:"computed is readonly.",5:"persist requires a string key."},j=(t,...e)=>{let n=$n[t];return new Error(q(n)?n.call($n,...e):n)};var mt=[],Fn=()=>{let t={onMounted:[],onUnmounted:[]};return mt.push(t),t},Le=t=>{let e=mt[mt.length-1];if(!e&&!t)throw j(2);return e},qn=t=>{let e=Le();return t&&on(t),mt.pop(),e},nn=Symbol("csp"),on=t=>{let e=t,n=e[nn];if(n){let o=Le();if(n===o)return;o.onMounted.length>0&&n.onMounted.push(...o.onMounted),o.onUnmounted.length>0&&n.onUnmounted.push(...o.onUnmounted);return}e[nn]=Le()},dt=t=>t[nn];var Se=t=>{var n,o;let e=(n=dt(t))==null?void 0:n.onUnmounted;e==null||e.forEach(r=>{r()}),(o=t.unmounted)==null||o.call(t)};var Ze=class{constructor(e,n,o,r,s){m(this,"props");m(this,"start");m(this,"end");m(this,"ctx");m(this,"autoProps",!0);m(this,"entangle",!0);m(this,"enableSwitch",!1);m(this,"onAutoPropsAssigned");m(this,"ye");m(this,"emit",(e,n)=>{this.ye.dispatchEvent(new CustomEvent(e,{detail:n}))});this.props=e,this.ye=n,this.ctx=o,this.start=r,this.end=s}findContext(e,n=0){var r;if(n<0)return;let o=0;for(let s of(r=this.ctx)!=null?r:[])if(s instanceof e){if(o===n)return s;++o}}requireContext(e,n=0){let o=this.findContext(e,n);if(o!==void 0)return o;throw new Error(`${e} was not found in the context stack at occurrence ${n}.`)}validateProps(e){let n=this.props;for(let o in e){let r=e[o];if(!r)continue;r(n[o],o,this)}}unmount(){let e=this.start.nextSibling,n=this.end;for(;e&&e!==n;)J(e),e=e.nextSibling;for(let o of this.ctx)Se(o)}};var Ie=t=>{let e=t,n=e[Be];if(n)return n;let o={unbinders:[],data:{}};return e[Be]=o,o};var K=(t,e)=>{Ie(t).unbinders.push(e)};var zn={8:t=>`Model binding requires a ref at ${t.outerHTML}`,7:t=>`Model binding is not supported on ${t.tagName} element at ${t.outerHTML}`,0:(t,e)=>`${t} binding expression is missing at ${e.outerHTML}`,1:(t,e,n)=>`invalid ${t} expression: ${e} at ${n.outerHTML}`,2:(t,e)=>`${t} requires object expression at ${e.outerHTML}`,3:(t,e)=>`${t} binder: key is empty on ${e.outerHTML}.`,4:(t,e,n,o)=>({msg:`Failed setting prop "${t}" on <${e.toLowerCase()}>: value ${n} is invalid.`,args:[o]}),5:(t,e)=>`${t} binding missing event type at ${e.outerHTML}`,6:(t,e)=>({msg:t,args:[e]})},U=(t,...e)=>{let n=zn[t],o=q(n)?n.call(zn,...e):n,r=ht.warning;r&&(z(o)?r(o):r(o,...o.args))},ht={warning:console.warn};var gt={},yt={},Kn=1,Wn=t=>{let e=(Kn++).toString();return gt[e]=t,yt[e]=0,e},rn=t=>{yt[t]+=1},sn=t=>{--yt[t]===0&&(delete gt[t],delete yt[t])},Gn=t=>gt[t],an=()=>Kn!==1&&Object.keys(gt).length>0,et="r-switch",fr=t=>{let e=t.filter(o=>be(o)).map(o=>[...o.querySelectorAll("[r-switch]")].map(r=>r.getAttribute(et))),n=new Set;return e.forEach(o=>{o.forEach(r=>r&&n.add(r))}),[...n]},_e=(t,e)=>{if(!an())return;let n=fr(e);n.length!==0&&(n.forEach(rn),K(t,()=>{n.forEach(sn)}))};var bt=()=>{},cn=(t,e,n,o)=>{let r=[];for(let s of t){let i=s.cloneNode(!0);n.insertBefore(i,o),r.push(i)}Ae(e,r)},un=Symbol("r-if"),Jn=Symbol("r-else"),Qn=t=>t[Jn]===1,Tt=class{constructor(e){m(this,"r");m(this,"N");m(this,"he");m(this,"G");m(this,"J");m(this,"x");m(this,"R");this.r=e,this.N=e.o.u.if,this.he=Ct(e.o.u.if),this.G=e.o.u.else,this.J=e.o.u.elseif,this.x=e.o.u.for,this.R=e.o.u.pre}nt(e,n){let o=e.parentElement;for(;o!==null&&o!==document.documentElement;){if(o.hasAttribute(n))return!0;o=o.parentElement}return!1}k(e){let n=e.hasAttribute(this.N);return n&&this.y(e),this.r.M.j(e,o=>{o.hasAttribute(this.N)&&this.y(o)}),n}Q(e){return e[un]?!0:(e[un]=!0,xt(e,this.he).forEach(n=>n[un]=!0),!1)}y(e){if(e.hasAttribute(this.R)||this.Q(e)||this.nt(e,this.x))return;let n=e.getAttribute(this.N);if(!n){U(0,this.N,e);return}e.removeAttribute(this.N),this.O(e,n)}U(e,n,o){let r=$e(e),s=e.parentNode,i=document.createComment(`__begin__ :${n}${o!=null?o:""}`);s.insertBefore(i,e),_e(i,r),r.forEach(c=>{J(c)}),e.remove(),n!=="if"&&(e[Jn]=1);let a=document.createComment(`__end__ :${n}${o!=null?o:""}`);return s.insertBefore(a,i.nextSibling),{nodes:r,parent:s,commentBegin:i,commentEnd:a}}ge(e,n){if(!e)return[];let o=e.nextElementSibling;if(e.hasAttribute(this.G)){e.removeAttribute(this.G);let{nodes:r,parent:s,commentBegin:i,commentEnd:a}=this.U(e,"else");return[{mount:()=>{cn(r,this.r,s,a)},unmount:()=>{Te(i,a)},isTrue:()=>!0,isMounted:!1}]}else{let r=e.getAttribute(this.J);if(!r)return[];e.removeAttribute(this.J);let{nodes:s,parent:i,commentBegin:a,commentEnd:c}=this.U(e,"elseif",` => ${r} `),u=this.r.m.V(r),l=u.value,f=this.ge(o,n),p=bt;return K(a,()=>{u.stop(),p(),p=bt}),p=u.subscribe(n),[{mount:()=>{cn(s,this.r,i,c)},unmount:()=>{Te(a,c)},isTrue:()=>!!l()[0],isMounted:!1},...f]}}O(e,n){let o=e.nextElementSibling,{nodes:r,parent:s,commentBegin:i,commentEnd:a}=this.U(e,"if",` => ${n} `),c=this.r.m.V(n),u=c.value,l=!1,f=this.r.m,p=f.L(),h=()=>{f.C(p,()=>{if(u()[0])l||(cn(r,this.r,s,a),l=!0),y.forEach(b=>{b.unmount(),b.isMounted=!1});else{Te(i,a),l=!1;let b=!1;for(let E of y)!b&&E.isTrue()?(E.isMounted||(E.mount(),E.isMounted=!0),b=!0):(E.unmount(),E.isMounted=!1)}})},y=this.ge(o,h),d=bt;K(i,()=>{c.stop(),d(),d=bt}),h(),d=c.subscribe(h)}};var $e=t=>{let e=pe(t)?t.content.childNodes:[t],n=[];for(let o=0;o<e.length;++o){let r=e[o];if(r.nodeType===1){let s=r==null?void 0:r.tagName;if(s==="SCRIPT"||s==="STYLE")continue}n.push(r)}return n},Ae=(t,e)=>{for(let n=0;n<e.length;++n){let o=e[n];o.nodeType===Node.ELEMENT_NODE&&(Qn(o)||t._(o))}},xt=(t,e)=>{var o;let n=t.querySelectorAll(e);return(o=t.matches)!=null&&o.call(t,e)?[t,...n]:n},pe=t=>t instanceof HTMLTemplateElement,be=t=>t.nodeType===Node.ELEMENT_NODE,tt=t=>t.nodeType===Node.ELEMENT_NODE,Xn=t=>t instanceof HTMLSlotElement,xe=t=>pe(t)?t.content.childNodes:t.childNodes,Te=(t,e)=>{let n=t.nextSibling;for(;n!=null&&n!==e;){let o=n.nextSibling;J(n),n=o}},Yn=function(){return this()},pr=function(t){return this(t)},mr=()=>{throw new Error("value is readonly.")},dr={get:Yn,set:pr,enumerable:!0,configurable:!1},hr={get:Yn,set:mr,enumerable:!0,configurable:!1},Ne=(t,e)=>{Object.defineProperty(t,"value",e?hr:dr)},Zn=(t,e)=>{if(!t)return!1;if(t.startsWith("["))return t.substring(1,t.length-1);let n=e.length;return t.startsWith(e)?t.substring(n,t.length-n):!1},Ct=t=>`[${CSS.escape(t)}]`,Et=(t,e)=>(t.startsWith("@")&&(t=e.u.on+":"+t.slice(1)),t.includes("[")&&(t=t.replace(/[[\]]/g,e.u.dynamic)),t),ln=t=>{let e=Object.create(null);return n=>e[n]||(e[n]=t(n))},yr=/-(\w)/g,_=ln(t=>t&&t.replace(yr,(e,n)=>n?n.toUpperCase():"")),gr=/\B([A-Z])/g,Fe=ln(t=>t&&t.replace(gr,"-$1").toLowerCase()),nt=ln(t=>t&&t.charAt(0).toUpperCase()+t.slice(1));var Rt={mount:()=>{}};var qe=t=>{let e=t.trim();return e?e.split(/\s+/):[]};var vt=t=>{var n,o;let e=(n=dt(t))==null?void 0:n.onMounted;e==null||e.forEach(r=>{r()}),(o=t.mounted)==null||o.call(t)};var fn=Symbol("scope"),pn=t=>{try{Fn();let e=t();on(e);let n={context:e,unmount:()=>Se(e),[fn]:1};return n[fn]=1,n}finally{qn()}},eo=t=>I(t)?fn in t:!1;var wt=Symbol("ref"),Y=Symbol("sref"),St=Symbol("raw");var x=t=>t!=null&&t[Y]===1;var mn={collectRefObj:!0,mount:({parseResult:t})=>({update:({values:e})=>{let n=t.context,o=e[0];if(I(o))for(let r of Object.entries(o)){let s=r[0],i=r[1],a=n[s];a!==i&&(x(a)?a(i):n[s]=i)}}})};var ne=(t,e)=>{var n;(n=Le(e))==null||n.onUnmounted.push(t)};var re=(t,e,n,o=!0)=>{if(!x(t))throw j(3,"observe");n&&e(t());let s=t(void 0,void 0,0,e);return o&&ne(s,!0),s};var ot=(t,e)=>{if(t===e)return()=>{};let n=re(t,r=>e(r)),o=re(e,r=>t(r));return e(t()),()=>{n(),o()}};var rt=t=>!!t&&t[St]===1;var ze=t=>(t==null?void 0:t[wt])===1;var me=[],to=t=>{var e;me.length!==0&&((e=me[me.length-1])==null||e.add(t))},Ke=t=>{if(!t)return()=>{};let e={stop:()=>{}};return br(t,e),ne(()=>e.stop(),!0),e.stop},br=(t,e)=>{if(!t)return;let n=[],o=!1,r=()=>{for(let s of n)s();n=[],o=!0};e.stop=r;try{let s=new Set;if(me.push(s),t(i=>n.push(i)),o)return;for(let i of[...s]){let a=re(i,()=>{r(),Ke(t)});n.push(a)}}finally{me.pop()}},dn=t=>{let e=me.length,n=e>0&&me[e-1];try{return n&&me.push(null),t()}finally{n&&me.pop()}},hn=t=>{try{let e=new Set;return me.push(e),{value:t(),refs:[...e]}}finally{me.pop()}};var Z=(t,e,n)=>{if(!x(t))return;let o=t;if(o(void 0,e,1),!n)return;let r=o();if(r){if(w(r)||ue(r))for(let s of r)Z(s,e,!0);else if(we(r))for(let s of r)Z(s[0],e,!0),Z(s[1],e,!0);if(I(r))for(let s in r)Z(r[s],e,!0)}};function Tr(t,e,n){Object.defineProperty(t,e,{value:n,enumerable:!1,writable:!0,configurable:!0})}var We=(t,e,n)=>{n.forEach(function(o){let r=t[o];Tr(e,o,function(...i){let a=r.apply(this,i),c=this[Y];for(let u of c)Z(u);return a})})},At=(t,e)=>{Object.defineProperty(t,Symbol.toStringTag,{value:e,writable:!1,enumerable:!1,configurable:!0})};var no=Array.prototype,yn=Object.create(no),xr=["push","pop","shift","unshift","splice","sort","reverse"];We(no,yn,xr);var oo=Map.prototype,Nt=Object.create(oo),Cr=["set","clear","delete"];At(Nt,"Map");We(oo,Nt,Cr);var ro=Set.prototype,Ot=Object.create(ro),Er=["add","clear","delete"];At(Ot,"Set");We(ro,Ot,Er);var ye={},ae=t=>{if(x(t)||rt(t))return t;let e={auto:!0,_value:t},n=c=>I(c)?Y in c?!0:w(c)?(Object.setPrototypeOf(c,yn),!0):ue(c)?(Object.setPrototypeOf(c,Ot),!0):we(c)?(Object.setPrototypeOf(c,Nt),!0):!1:!1,o=n(t),r=new Set,s=(c,u)=>{if(ye.stack&&ye.stack.length){ye.stack[ye.stack.length-1].add(a);return}r.size!==0&&dn(()=>{for(let l of[...r.keys()])r.has(l)&&l(c,u)})},i=c=>{let u=c[Y];u||(c[Y]=u=new Set),u.add(a)},a=(...c)=>{if(!(2 in c)){let l=c[0],f=c[1];return 0 in c?e._value===l||x(l)&&(l=l(),e._value===l)?l:(n(l)&&i(l),e._value=l,e.auto&&s(l,f),e._value):(to(a),e._value)}switch(c[2]){case 0:{let l=c[3];if(!l)return()=>{};let f=p=>{r.delete(p)};return r.add(l),()=>{f(l)}}case 1:{let l=c[1],f=e._value;s(f,l);break}case 2:return r.size;case 3:{e.auto=!1;break}case 4:e.auto=!0}return e._value};return a[Y]=1,Ne(a,!1),o&&i(t),a};var Ce=t=>{if(rt(t))return t;let e;if(x(t)?(e=t,t=e()):e=ae(t),t instanceof Node||t instanceof Date||t instanceof RegExp||t instanceof Promise||t instanceof Error)return e;if(e[wt]=1,w(t)){let n=t.length;for(let o=0;o<n;++o){let r=t[o];ze(r)||(t[o]=Ce(r))}return e}if(!I(t))return e;for(let n of Object.entries(t)){let o=n[1];if(ze(o))continue;let r=n[0];Ye(r)||(t[r]=null,t[r]=Ce(o))}return e};var so=Symbol("modelBridge"),Mt=()=>{},Rr=t=>!!(t!=null&&t[so]),vr=t=>{t[so]=1},wr=t=>{let e=Ce(t());return vr(e),e},io={collectRefObj:!0,mount:({parseResult:t,option:e})=>{if(typeof e!="string"||!e)return Mt;let n=_(e),o,r,s=Mt,i=()=>{s(),s=Mt,o=void 0,r=void 0},a=()=>{s(),s=Mt},c=(l,f)=>{o!==l&&(a(),s=ot(l,f),o=l)},u=()=>{var h;let l=(h=t.refs[0])!=null?h:t.value()[0],f=t.context,p=f[n];if(!x(l)){if(r&&p===r){r(l);return}if(i(),x(p)){p(l);return}f[n]=l;return}if(Rr(l)){if(p===l)return;x(p)?c(l,p):f[n]=l;return}r||(r=wr(l)),f[n]=r,c(l,r)};return{update:()=>{u()},unmount:()=>{s()}}}};var kt=class{constructor(e){m(this,"r");m(this,"be");m(this,"xe","");m(this,"Te",-1);this.r=e,this.be=e.o.u.inherit}k(e){this.ot(e)}rt(e){if(this.Te!==e.size){let n=[...e.keys()];this.xe=[...n,...n.map(Fe)].join(","),this.Te=e.size}return this.xe}st(e){var n;for(let o=0;o<e.length;++o){let r=(n=e[o])==null?void 0:n.components;if(r)for(let s in r)return!0}return!1}it(e){if(!pe(e))return!1;let n=e.getAttributeNames();return e.hasAttribute("name")?!0:n.some(o=>o.startsWith("#"))}at(e){return pe(e)&&e.getAttributeNames().length===0}ot(e){let n=this.r,o=n.m,r=n.o.X,s=n.o.$;if(r.size===0&&!this.st(o.l))return;let i=o.Y(),a=this.Re();if(F(a))return;let c=this.ct(e,a);for(let u of c){if(u.hasAttribute(n.R))continue;let l=u.parentNode;if(!l)continue;let f=u.nextSibling,p=_(u.tagName).toUpperCase(),h=i[p],y=h!=null?h:s.get(p);if(!y)continue;let d=y.template;if(!d)continue;let C=u.parentElement;if(!C)continue;let b=new Comment(" begin component: "+u.tagName),E=new Comment(" end component: "+u.tagName);C.insertBefore(b,u),u.remove();let V=n.o.u.context,W=n.o.u.contextAlias,H=n.o.u.bind,B=(g,S)=>{let v={},G=g.hasAttribute(V);return o.C(S,()=>{o.v(v),G?n.y(mn,g,V):g.hasAttribute(W)&&n.y(mn,g,W);let O=y.props;if(!O||O.length===0)return;O=O.map(_);let R=new Map(O.map(k=>[k.toLowerCase(),k]));for(let k of[...O,...O.map(Fe)]){let te=g.getAttribute(k);te!==null&&(v[_(k)]=te,g.removeAttribute(k))}let A=n.q.Ce(g,!1);for(let[k,te]of A.entries()){let[se,le]=te.Z;if(!le)continue;let P=R.get(_(le).toLowerCase());P&&(se!=="."&&se!==":"&&se!==H||n.y(io,g,k,!0,P,te.ee))}}),v},ee=[...o.L()],oe=()=>{var G;let g=B(u,ee),S=new Ze(g,u,ee,b,E),v=pn(()=>{var O;return(O=y.context(S))!=null?O:{}}).context;if(S.autoProps){for(let[O,R]of Object.entries(g))if(O in v){let A=v[O];if(A===R)continue;if(x(A)){x(R)?S.entangle?K(b,ot(R,A)):A(R()):A(R);continue}}else v[O]=R;(G=S.onAutoPropsAssigned)==null||G.call(S)}return{componentCtx:v,head:S}},{componentCtx:M,head:T}=oe(),N=[...xe(d)],Q=N.length,Ue=u.childNodes.length===0,He=g=>{var R;let S=g.parentElement,v=g.name;if(F(v)&&(v=g.getAttributeNames().filter(A=>A.startsWith("#"))[0],F(v)?v="default":v=v.substring(1)),Ue){if(v==="default"){let A=n.o.u.text,k=u.getAttribute(A);if(!F(k)){let te=document.createElement("span");te.setAttribute(A,k),S.insertBefore(te,g),u.removeAttribute(A);return}}for(let A of[...g.childNodes])S.insertBefore(A,g);return}let G=u.querySelector(`template[name='${v}'], template[\\#${v}]`);!G&&v==="default"&&(G=(R=[...u.querySelectorAll("template:not([name])")].find(k=>this.at(k)))!=null?R:null);let O=A=>{T.enableSwitch&&o.C(ee,()=>{o.v(M);let k=B(g,o.L());o.C(ee,()=>{o.v(k);let te=o.L(),se=Wn(te);for(let le of A)be(le)&&(le.setAttribute(et,se),rn(se),K(le,()=>{sn(se)}))})})};if(G){let A=[...xe(G)];for(let k of A)S.insertBefore(k,g);O(A)}else{if(v!=="default"){for(let k of[...xe(g)])S.insertBefore(k,g);return}let A=[...xe(u)].filter(k=>!this.it(k));for(let k of A)S.insertBefore(k,g);O(A)}},Yt=g=>{if(!be(g))return;let S=g.querySelectorAll("slot");if(Xn(g)){He(g),g.remove();return}for(let v of S)He(v),v.remove()};(()=>{for(let g=0;g<Q;++g)N[g]=N[g].cloneNode(!0),l.insertBefore(N[g],f),Yt(N[g])})(),C.insertBefore(E,f);let ut=()=>{if(!y.inheritAttrs)return;let g=N.filter(v=>v.nodeType===Node.ELEMENT_NODE);g.length>1&&(g=g.filter(v=>v.hasAttribute(this.be)));let S=g[0];if(S)for(let v of u.getAttributeNames()){if(v===V||v===W)continue;let G=u.getAttribute(v);if(v==="class"){let O=qe(G);O.length>0&&S.classList.add(...O)}else if(v==="style"){let O=S.style,R=u.style;for(let A of R)O.setProperty(A,R.getPropertyValue(A))}else S.setAttribute(Et(v,n.o),G)}},L=()=>{for(let g of u.getAttributeNames())!g.startsWith("@")&&!g.startsWith(n.o.u.on)&&u.removeAttribute(g)},X=()=>{ut(),L(),o.v(M),n.Ee(u,!1),M.$emit=T.emit,Ae(n,N),K(u,()=>{Se(M)}),K(b,()=>{ge(u)}),vt(M)};o.C(ee,X)}}Re(){let e=this.r,n=e.m,o=e.o.X,r=n.ut(),s=this.rt(o);return[...s?[s]:[],...r,...r.map(Fe)].join(",")}ct(e,n){var s;let o=[];if(F(n))return o;if((s=e.matches)!=null&&s.call(e,n))return[e];let r=this.F(e).reverse();for(;r.length>0;){let i=r.pop();if(i.matches(n)){o.push(i);continue}r.push(...this.F(i).reverse())}return o}j(e,n){let o=this.Re(),r=this.F(e).reverse();for(;r.length>0;){let s=r.pop();n(s),!(!F(o)&&s.matches(o))&&r.push(...this.F(s).reverse())}}F(e){let n=e==null?void 0:e.children;if((n==null?void 0:n.length)!=null){let r=[];for(let s=0;s<n.length;++s){let i=n[s];be(i)&&r.push(i)}return r}let o=e==null?void 0:e.childNodes;if((o==null?void 0:o.length)!=null){let r=[];for(let s=0;s<o.length;++s){let i=o[s];be(i)&&r.push(i)}return r}return[]}};var gn=class{constructor(e,n){m(this,"Z");m(this,"ee");m(this,"ve",[]);this.Z=e,this.ee=n}},Lt=class{constructor(e){m(this,"r");m(this,"we");m(this,"Se");m(this,"te");var o;this.r=e,this.we=e.o.pt(),this.te=new Map;let n=new Map;for(let r of this.we){let s=(o=r[0])!=null?o:"",i=n.get(s);i?i.push(r):n.set(s,[r])}this.Se=n}Ae(e){let n=this.te.get(e);if(n)return n;let o=e,r=o.startsWith(".");r&&(o=":"+o.slice(1));let s=o.indexOf("."),a=(s<0?o:o.substring(0,s)).split(/[:@]/);F(a[0])&&(a[0]=r?".":o[0]);let c=s>=0?o.slice(s+1).split("."):[],u=!1,l=!1;for(let p=0;p<c.length;++p){let h=c[p];if(!u&&h==="camel"?u=!0:!l&&h==="prop"&&(l=!0),u&&l)break}u&&(a[a.length-1]=_(a[a.length-1])),l&&(a[0]=".");let f={terms:a,flags:c};return this.te.set(e,f),f}Ce(e,n){let o=new Map;if(!tt(e))return o;let r=this.Se,s=(a,c)=>{var l;let u=r.get((l=c[0])!=null?l:"");if(u)for(let f=0;f<u.length;++f){if(!c.startsWith(u[f]))continue;let p=o.get(c);if(!p){let h=this.Ae(c);p=new gn(h.terms,h.flags),o.set(c,p)}p.ve.push(a);return}},i=a=>{var u;let c=a.attributes;if(!(!c||c.length===0))for(let l=0;l<c.length;++l){let f=(u=c.item(l))==null?void 0:u.name;f&&s(a,f)}};return i(e),!n||!e.firstElementChild||this.r.M.j(e,i),o}};var ao=()=>{},Sr=(t,e)=>{for(let n of t){let o=n.cloneNode(!0);e.appendChild(o)}},It=class{constructor(e){m(this,"r");m(this,"I");this.r=e,this.I=e.o.u.is}k(e){let n=e.hasAttribute(this.I);return(n||e.hasAttribute("is"))&&this.y(e),this.r.M.j(e,o=>{(o.hasAttribute(this.I)||o.hasAttribute("is"))&&this.y(o)}),n}y(e){let n=e.getAttribute(this.I);if(!n){if(n=e.getAttribute("is"),!n)return;if(!n.startsWith("regor:")){if(!n.startsWith("r-"))return;let o=n.slice(2).trim().toLowerCase();if(!o)return;let r=e.parentNode;if(!r)return;let s=document.createElement(o);for(let i of e.getAttributeNames())i!=="is"&&s.setAttribute(i,e.getAttribute(i));for(;e.firstChild;)s.appendChild(e.firstChild);r.insertBefore(s,e),e.remove(),this.r._(s);return}n=`'${n.slice(6)}'`,e.removeAttribute("is")}e.removeAttribute(this.I),this.O(e,n)}U(e,n){let o=$e(e),r=e.parentNode,s=document.createComment(`__begin__ dynamic ${n!=null?n:""}`);r.insertBefore(s,e),_e(s,o),o.forEach(a=>{J(a)}),e.remove();let i=document.createComment(`__end__ dynamic ${n!=null?n:""}`);return r.insertBefore(i,s.nextSibling),{nodes:o,parent:r,commentBegin:s,commentEnd:i}}O(e,n){let{nodes:o,parent:r,commentBegin:s,commentEnd:i}=this.U(e,` => ${n} `),a=this.r.m.V(n),c=a.value,u=this.r.m,l=u.L(),f={name:""},p=pe(e)?o:[...o[0].childNodes],h=()=>{u.C(l,()=>{var E;let C=c()[0];if(I(C)&&(C.name?C=C.name:C=(E=Object.entries(u.Y()).filter(V=>V[1]===C)[0])==null?void 0:E[0]),!z(C)||F(C)){Te(s,i);return}if(f.name===C)return;Te(s,i);let b=document.createElement(C);for(let V of e.getAttributeNames())V!==this.I&&b.setAttribute(V,e.getAttribute(V));Sr(p,b),r.insertBefore(b,i),this.r._(b),f.name=C})},y=ao;K(s,()=>{a.stop(),y(),y=ao}),h(),y=a.subscribe(h)}};var $=t=>{let e=t;return e!=null&&e[Y]===1?e():e};var Ar=(t,e)=>{let[n,o]=e;q(o)?o(t,n):t.innerHTML=n==null?void 0:n.toString()},Vt={mount:()=>({update:({el:t,values:e})=>{Ar(t,e)}})};var Dt=class t{constructor(e){m(this,"ne");this.ne=e}static lt(e,n){var h,y;let o=e.m,r=e.o,s=r.u,i=new Set([s.for,s.if,s.else,s.elseif,s.pre]),a=r.B,c=o.Y();if(Object.keys(c).length>0||r.$.size>0)return;let u=e.q,l=[],f=0,p=[];for(let d=n.length-1;d>=0;--d)p.push(n[d]);for(;p.length>0;){let d=p.pop();if(d.nodeType===Node.ELEMENT_NODE){let b=d;if(b.tagName==="TEMPLATE"||b.tagName.includes("-"))return;let E=_(b.tagName).toUpperCase();if(r.$.has(E)||c[E])return;let V=b.attributes;for(let W=0;W<V.length;++W){let H=(h=V.item(W))==null?void 0:h.name;if(!H)continue;if(i.has(H))return;let{terms:B,flags:ee}=u.Ae(H),[oe,M]=B,T=(y=a[H])!=null?y:a[oe];if(T){if(T===Vt)return;l.push({nodeIndex:f,attrName:H,directive:T,option:M,flags:ee})}}++f}let C=d.childNodes;for(let b=C.length-1;b>=0;--b)p.push(C[b])}if(l.length!==0)return new t(l)}y(e,n){let o=[],r=[];for(let s=n.length-1;s>=0;--s)r.push(n[s]);for(;r.length>0;){let s=r.pop();s.nodeType===Node.ELEMENT_NODE&&o.push(s);let i=s.childNodes;for(let a=i.length-1;a>=0;--a)r.push(i[a])}for(let s=0;s<this.ne.length;++s){let i=this.ne[s],a=o[i.nodeIndex];a&&e.y(i.directive,a,i.attrName,!1,i.option,i.flags)}}};var Nr=(t,e)=>{let n=e.parentNode;if(n)for(let o=0;o<t.items.length;++o)n.insertBefore(t.items[o],e)},Or=t=>{var a;let e=t.length,n=t.slice(),o=[],r,s,i;for(let c=0;c<e;++c){let u=t[c];if(u===0)continue;let l=o[o.length-1];if(l===void 0||t[l]<u){n[c]=l!=null?l:-1,o.push(c);continue}for(r=0,s=o.length-1;r<s;)i=r+s>>1,t[o[i]]<u?r=i+1:s=i;u<t[o[r]]&&(r>0&&(n[c]=o[r-1]),o[r]=c)}for(r=o.length,s=(a=o[r-1])!=null?a:-1;r-- >0;)o[r]=s,s=n[s];return o},Pt=class{static ft(e){let{oldItems:n,newValues:o,getKey:r,isSameValue:s,mountNewValue:i,removeMountItem:a,endAnchor:c}=e,u=n.length,l=o.length,f=new Array(l),p=new Set;for(let T=0;T<l;++T){let N=r(o[T]);if(N===void 0||p.has(N))return;p.add(N),f[T]=N}let h=new Array(l),y=0,d=u-1,C=l-1;for(;y<=d&&y<=C;){let T=n[y];if(r(T.value)!==f[y]||!s(T.value,o[y]))break;T.value=o[y],h[y]=T,++y}for(;y<=d&&y<=C;){let T=n[d];if(r(T.value)!==f[C]||!s(T.value,o[C]))break;T.value=o[C],h[C]=T,--d,--C}if(y>d){for(let T=C;T>=y;--T){let N=T+1<l?h[T+1].items[0]:c;h[T]=i(T,o[T],N)}return h}if(y>C){for(let T=y;T<=d;++T)a(n[T]);return h}let b=y,E=y,V=C-E+1,W=new Array(V).fill(0),H=new Map;for(let T=E;T<=C;++T)H.set(f[T],T);let B=!1,ee=0;for(let T=b;T<=d;++T){let N=n[T],Q=H.get(r(N.value));if(Q===void 0){a(N);continue}if(!s(N.value,o[Q])){a(N);continue}N.value=o[Q],h[Q]=N,W[Q-E]=T+1,Q>=ee?ee=Q:B=!0}let oe=B?Or(W):[],M=oe.length-1;for(let T=V-1;T>=0;--T){let N=E+T,Q=N+1<l?h[N+1].items[0]:c;if(W[T]===0){h[N]=i(N,o[N],Q);continue}let Ue=h[N];B&&(M>=0&&oe[M]===T?--M:Ue&&Nr(Ue,Q))}return h}};var st=class{constructor(e){m(this,"T",[]);m(this,"P",new Map);m(this,"oe");this.oe=e}get w(){return this.T.length}re(e){let n=this.oe(e.value);n!==void 0&&this.P.set(n,e)}se(e){var o;let n=this.oe((o=this.T[e])==null?void 0:o.value);n!==void 0&&this.P.delete(n)}static mt(e,n){return{items:[],index:e,value:n,order:-1}}v(e){e.order=this.w,this.T.push(e),this.re(e)}dt(e,n){let o=this.w;for(let r=e;r<o;++r)this.T[r].order=r+1;n.order=e,this.T.splice(e,0,n),this.re(n)}D(e){return this.T[e]}ie(e,n){this.se(e),this.T[e]=n,this.re(n),n.order=e}ke(e){this.se(e),this.T.splice(e,1);let n=this.w;for(let o=e;o<n;++o)this.T[o].order=o}Ne(e){let n=this.w;for(let o=e;o<n;++o)this.se(o);this.T.splice(e)}Zt(e){return this.P.has(e)}yt(e){var o;let n=this.P.get(e);return(o=n==null?void 0:n.order)!=null?o:-1}};var bn=Symbol("r-for"),Mr=t=>-1,co=()=>{},Ht=class Ht{constructor(e){m(this,"r");m(this,"x");m(this,"Me");m(this,"R");this.r=e,this.x=e.o.u.for,this.Me=Ct(this.x),this.R=e.o.u.pre}k(e){let n=e.hasAttribute(this.x);return n&&this.Oe(e),this.r.M.j(e,o=>{o.hasAttribute(this.x)&&this.Oe(o)}),n}Q(e){return e[bn]?!0:(e[bn]=!0,xt(e,this.Me).forEach(n=>n[bn]=!0),!1)}Oe(e){if(e.hasAttribute(this.R)||this.Q(e))return;let n=e.getAttribute(this.x);if(!n){U(0,this.x,e);return}e.removeAttribute(this.x),this.ht(e,n)}Ve(e){return fe(e)?[]:(q(e)&&(e=e()),Symbol.iterator in Object(e)?e:typeof e=="number"?(o=>({*[Symbol.iterator](){for(let r=1;r<=o;r++)yield r}}))(e):Object.entries(e))}ht(e,n){var ut;let o=this.gt(n);if(!(o!=null&&o.list)){U(1,this.x,n,e);return}let r=this.r.o.u.key,s=this.r.o.u.keyBind,i=(ut=e.getAttribute(r))!=null?ut:e.getAttribute(s);e.removeAttribute(r),e.removeAttribute(s);let a=$e(e),c=Dt.lt(this.r,a),u=e.parentNode;if(!u)return;let l=`${this.x} => ${n}`,f=new Comment(`__begin__ ${l}`);u.insertBefore(f,e),_e(f,a),a.forEach(L=>{J(L)}),e.remove();let p=new Comment(`__end__ ${l}`);u.insertBefore(p,f.nextSibling);let h=this.r,y=h.m,d=y.L(),b=d.length===1?[void 0,d[0]]:void 0,E=this.bt(i),V=(L,X)=>E(L)===E(X),W=(L,X)=>L===X,H=(L,X,g)=>{let S=o.createContext(X,L),v=st.mt(S.index,X),G=()=>{var k,te;let O=(te=(k=p.parentNode)!=null?k:f.parentNode)!=null?te:u,R=g.previousSibling,A=[];for(let se=0;se<a.length;++se){let le=a[se].cloneNode(!0);O.insertBefore(le,g),A.push(le)}for(c?c.y(h,A):Ae(h,A),R=R.nextSibling;R!==g;)v.items.push(R),R=R.nextSibling};return b?(b[0]=S.ctx,y.C(b,G)):y.C(d,()=>{y.v(S.ctx),G()}),v},B=(L,X)=>{let g=D.D(L).items,S=g[g.length-1].nextSibling;for(let v of g)J(v);D.ie(L,H(L,X,S))},ee=(L,X)=>{D.v(H(L,X,p))},oe=L=>{for(let X of D.D(L).items)J(X)},M=L=>{let X=D.w;for(let g=L;g<X;++g)D.D(g).index(g)},T=L=>{let X=f.parentNode,g=p.parentNode;if(!X||!g)return;let S=D.w;q(L)&&(L=L());let v=$(L[0]);if(w(v)&&v.length===0){Te(f,p),D.Ne(0);return}let G=[];for(let P of this.Ve(L[0]))G.push(P);let O=Pt.ft({oldItems:D.T,newValues:G,getKey:E,isSameValue:W,mountNewValue:(P,ie,ke)=>H(P,ie,ke),removeMountItem:P=>{for(let ie=0;ie<P.items.length;++ie)J(P.items[ie])},endAnchor:p});if(O){D.T=O,D.P.clear();for(let P=0;P<O.length;++P){let ie=O[P];ie.order=P,ie.index(P);let ke=E(ie.value);ke!==void 0&&D.P.set(ke,ie)}return}let R=0,A=Number.MAX_SAFE_INTEGER,k=S,te=this.r.o.forGrowThreshold,se=()=>D.w<k+te;for(let P of G){let ie=()=>{if(R<S){let ke=D.D(R++);if(V(ke.value,P)){if(W(ke.value,P))return;B(R-1,P);return}let lt=D.yt(E(P));if(lt>=R&<-R<10){if(--R,A=Math.min(A,R),oe(R),D.ke(R),--S,lt>R+1)for(let Zt=R;Zt<lt-1&&Zt<S&&!V(D.D(R).value,P);)++Zt,oe(R),D.ke(R),--S;ie();return}se()?(D.dt(R-1,H(R,P,D.D(R-1).items[0])),A=Math.min(A,R-1),++S):B(R-1,P)}else ee(R++,P)};ie()}let le=R;for(S=D.w;R<S;)oe(R++);D.Ne(le),M(A)},N=()=>{Q.stop(),He(),He=co},Q=y.V(o.list),Ue=Q.value,He=co,Yt=0,D=new st(E);for(let L of this.Ve(Ue()[0]))D.v(H(Yt++,L,p));K(f,N),He=Q.subscribe(T)}gt(e){var c,u;let n=Ht.xt.exec(e);if(!n)return;let o=(n[1]+((c=n[2])!=null?c:"")).split(",").map(l=>l.trim()),r=o.length>1?o.length-1:-1,s=r!==-1&&(o[r]==="index"||(u=o[r])!=null&&u.startsWith("#"))?o[r]:"";s&&o.splice(r,1);let i=n[3];if(!i||o.length===0)return;let a=/[{[]/.test(e);return{list:i,createContext:(l,f)=>{let p={},h=$(l);if(!a&&o.length===1)p[o[0]]=l;else if(w(h)){let d=0;for(let C of o)p[C]=h[d++]}else for(let d of o)p[d]=h[d];let y={ctx:p,index:Mr};return s&&(y.index=p[s.startsWith("#")?s.substring(1):s]=ae(f)),y}}}bt(e){if(!e)return o=>o;let n=e.trim();if(!n)return o=>o;if(n.includes(".")){let o=this.Tt(n),r=o.length>1?o.slice(1):void 0;return s=>{let i=$(s),a=this.Le(i,o);return a!==void 0||!r?a:this.Le(i,r)}}return o=>{var r;return $((r=$(o))==null?void 0:r[n])}}Tt(e){return e.split(".").filter(n=>n.length>0)}Le(e,n){var r;let o=e;for(let s of n)o=(r=$(o))==null?void 0:r[s];return $(o)}};m(Ht,"xt",/\{?\[?\(?([^)}\]]+)\)?\]?\}?([^)]+)?\s+\b(?:in|of)\b\s+(.*)\s*$/);var Ut=Ht;var Bt=class{constructor(e){m(this,"ae",0);m(this,"ce",new Map);m(this,"m");m(this,"Ie");m(this,"Pe");m(this,"De");m(this,"M");m(this,"q");m(this,"o");m(this,"R");m(this,"Ue");this.m=e,this.o=e.o,this.Pe=new Ut(this),this.Ie=new Tt(this),this.De=new It(this),this.M=new kt(this),this.q=new Lt(this),this.R=this.o.u.pre,this.Ue=this.o.u.dynamic}Rt(e){let n=pe(e)?[e]:e.querySelectorAll("template");for(let o of n){if(o.hasAttribute(this.R))continue;let r=o.parentNode;if(!r)continue;let s=o.nextSibling;if(o.remove(),!o.content)continue;let i=[...o.content.childNodes];for(let a of i)r.insertBefore(a,s);Ae(this,i)}}_(e){++this.ae;try{if(e.nodeType!==Node.ELEMENT_NODE||e.hasAttribute(this.R)||this.Ie.k(e)||this.Pe.k(e)||this.De.k(e))return;this.M.k(e),this.Rt(e),this.Ee(e,!0)}finally{--this.ae,this.ae===0&&this.Ct()}}Et(e,n){let o=document;if(!o){let r=e.parentNode;for(;r!=null&&r.parentNode;)r=r.parentNode;if(!r)return null;o=r}return o.querySelector(n)}Be(e,n){let o=this.Et(e,n);if(!o)return!1;let r=e.parentElement;if(!r)return!1;let s=new Comment(`teleported => '${n}'`);return r.insertBefore(s,e),e.teleportedFrom=s,s.teleportedTo=e,K(s,()=>{J(e)}),o.appendChild(e),!0}vt(e,n){this.ce.set(e,n)}Ct(){let e=this.ce;if(e.size!==0){this.ce=new Map;for(let[n,o]of e.entries())this.Be(n,o)}}Ee(e,n){var s;let o=this.q.Ce(e,n),r=this.o.B;for(let[i,a]of o.entries()){let[c,u]=a.Z,l=(s=r[i])!=null?s:r[c];if(!l){console.error("directive not found:",c);continue}let f=a.ve;for(let p=0;p<f.length;++p){let h=f[p];this.y(l,h,i,!1,u,a.ee)}}}y(e,n,o,r,s,i){if(n.hasAttribute(this.R))return;let a=n.getAttribute(o);n.removeAttribute(o);let c=u=>{let l=u;for(;l;){let f=l.getAttribute(et);if(f)return f;l=l.parentElement}return null};if(an()){let u=c(n);if(u){this.m.C(Gn(u),()=>{this.O(e,n,a,s,i)});return}}this.O(e,n,a,s,i)}wt(e,n,o){return e!==Rt?!1:(F(o)||this.Be(n,o)||this.vt(n,o),!0)}O(e,n,o,r,s){if(n.nodeType!==Node.ELEMENT_NODE||o==null||this.wt(e,n,o))return;let i=this.St(r,e.once),a=this.At(e,o),c=this.kt(a,i);K(n,c.stop);let u=this.Nt(n,o,a,i,r,s),l=this.Mt(e,u,c);if(!l)return;let f=this.Ot(u,a,i,r,l);f(),e.once||(c.result=a.subscribe(f),i&&(c.dynamic=i.subscribe(f)))}St(e,n){let o=Zn(e,this.Ue);if(o)return this.m.V(_(o),void 0,void 0,void 0,n)}At(e,n){return this.m.V(n,e.isLazy,e.isLazyKey,e.collectRefObj,e.once)}kt(e,n){let o={stop:()=>{var r,s,i;e.stop(),n==null||n.stop(),(r=o.result)==null||r.call(o),(s=o.dynamic)==null||s.call(o),(i=o.mounted)==null||i.call(o),o.result=void 0,o.dynamic=void 0,o.mounted=void 0}};return o}Nt(e,n,o,r,s,i){return{el:e,expr:n,values:o.value(),previousValues:void 0,option:r?r.value()[0]:s,previousOption:void 0,flags:i,parseResult:o,dynamicOption:r}}Mt(e,n,o){let r=e.mount(n);if(typeof r=="function"){o.mounted=r;return}return r!=null&&r.unmount&&(o.mounted=r.unmount),r==null?void 0:r.update}Ot(e,n,o,r,s){let i,a;return()=>{let c=n.value(),u=o?o.value()[0]:r;e.values=c,e.previousValues=i,e.option=u,e.previousOption=a,i=c,a=u,s(e)}}};var uo="http://www.w3.org/1999/xlink",kr={itemscope:2,allowfullscreen:2,formnovalidate:2,ismap:2,nomodule:2,novalidate:2,readonly:2,async:1,autofocus:1,autoplay:1,controls:1,default:1,defer:1,disabled:1,hidden:1,inert:1,loop:1,open:1,required:1,reversed:1,scoped:1,seamless:1,checked:1,muted:1,multiple:1,selected:1};function Lr(t){return!!t||t===""}var Ir=(t,e,n,o,r,s)=>{var a;if(o){s&&s.includes("camel")&&(o=_(o)),jt(t,o,e[0],r);return}let i=e.length;for(let c=0;c<i;++c){let u=e[c];if(w(u)){let l=(a=n==null?void 0:n[c])==null?void 0:a[0],f=u[0],p=u[1];jt(t,f,p,l)}else if(I(u))for(let l of Object.entries(u)){let f=l[0],p=l[1],h=n==null?void 0:n[c],y=h&&f in h?f:void 0;jt(t,f,p,y)}else{let l=n==null?void 0:n[c],f=e[c++],p=e[c];jt(t,f,p,l)}}},Tn={mount:()=>({update:({el:t,values:e,previousValues:n,option:o,previousOption:r,flags:s})=>{Ir(t,e,n,o,r,s)}})},jt=(t,e,n,o)=>{if(o&&o!==e&&t.removeAttribute(o),fe(e)){U(3,"r-bind",t);return}if(!z(e)){U(6,`Attribute key is not string at ${t.outerHTML}`,e);return}if(e.startsWith("xlink:")){fe(n)?t.removeAttributeNS(uo,e.slice(6,e.length)):t.setAttributeNS(uo,e,n);return}let r=e in kr;fe(n)||r&&!Lr(n)?t.removeAttribute(e):t.setAttribute(e,r?"":n)};var Vr=(t,e,n)=>{let o=e.length;for(let r=0;r<o;++r){let s=e[r],i=n==null?void 0:n[r];if(w(s)){let a=s.length;for(let c=0;c<a;++c)lo(t,s[c],i==null?void 0:i[c])}else lo(t,s,i)}},xn={mount:()=>({update:({el:t,values:e,previousValues:n})=>{Vr(t,e,n)}})},lo=(t,e,n)=>{let o=t.classList,r=z(e),s=z(n);if(e&&!r){if(n&&!s)for(let i in n)(!(i in e)||!e[i])&&o.remove(i);for(let i in e)e[i]&&o.add(i)}else if(r){if(n!==e){let i=s?qe(n):[],a=qe(e);i.length>0&&o.remove(...i),a.length>0&&o.add(...a)}}else if(n){let i=s?qe(n):[];i.length>0&&o.remove(...i)}};function Dr(t,e){if(t.length!==e.length)return!1;let n=!0;for(let o=0;n&&o<t.length;o++)n=Ee(t[o],e[o]);return n}function Ee(t,e){if(t===e)return!0;let n=tn(t),o=tn(e);if(n||o)return n&&o?t.getTime()===e.getTime():!1;if(n=Ye(t),o=Ye(e),n||o)return t===e;if(n=w(t),o=w(e),n||o)return n&&o?Dr(t,e):!1;if(n=I(t),o=I(e),n||o){if(!n||!o)return!1;let r=Object.keys(t).length,s=Object.keys(e).length;if(r!==s)return!1;for(let i in t){let a=Object.prototype.hasOwnProperty.call(t,i),c=Object.prototype.hasOwnProperty.call(e,i);if(a&&!c||!Ee(t[i],e[i]))return!1}return!0}return String(t)===String(e)}function _t(t,e){return t.findIndex(n=>Ee(n,e))}var fo=t=>{let e=parseFloat(t);return isNaN(e)?t:e};var Cn=t=>{if(!x(t))throw j(3,"pause");t(void 0,void 0,3)};var En=t=>{if(!x(t))throw j(3,"resume");t(void 0,void 0,4)};var mo={mount:({el:t,parseResult:e,flags:n})=>({update:({values:o})=>{Pr(t,o[0])},unmount:Ur(t,e,n)})},Pr=(t,e)=>{let n=bo(t);if(n&&ho(t))w(e)?e=_t(e,Re(t))>-1:ue(e)?e=e.has(Re(t)):e=Fr(t,e),t.checked=e;else if(n&&yo(t))t.checked=Ee(e,Re(t));else if(n||To(t))go(t)?t.value!==(e==null?void 0:e.toString())&&(t.value=e):t.value!==e&&(t.value=e);else if(xo(t)){let o=t.options,r=o.length,s=t.multiple;for(let i=0;i<r;i++){let a=o[i],c=Re(a);if(s)w(e)?a.selected=_t(e,c)>-1:a.selected=e.has(c);else if(Ee(Re(a),e)){t.selectedIndex!==i&&(t.selectedIndex=i);return}}!s&&t.selectedIndex!==-1&&(t.selectedIndex=-1)}else U(7,t)},it=t=>(x(t)&&(t=t()),q(t)&&(t=t()),t?z(t)?{trim:t.includes("trim"),lazy:t.includes("lazy"),number:t.includes("number"),int:t.includes("int")}:{trim:!!t.trim,lazy:!!t.lazy,number:!!t.number,int:!!t.int}:{trim:!1,lazy:!1,number:!1,int:!1}),ho=t=>t.type==="checkbox",yo=t=>t.type==="radio",go=t=>t.type==="number"||t.type==="range",bo=t=>t.tagName==="INPUT",To=t=>t.tagName==="TEXTAREA",xo=t=>t.tagName==="SELECT",Ur=(t,e,n)=>{let o=e.value,r=it(n==null?void 0:n.join(",")),s=it(o()[1]),i={int:r.int||s.int,lazy:r.lazy||s.lazy,number:r.number||s.number,trim:r.trim||s.trim};if(!e.refs[0])return U(8,t),()=>{};let a=()=>e.refs[0],c=bo(t);return c&&ho(t)?Br(t,a):c&&yo(t)?qr(t,a):c||To(t)?Hr(t,i,a,o):xo(t)?zr(t,a,o):(U(7,t),()=>{})},po=/[.,' ·٫]/,Hr=(t,e,n,o)=>{let s=e.lazy?"change":"input",i=go(t),a=()=>{!e.trim&&!it(o()[1]).trim||(t.value=t.value.trim())},c=p=>{let h=p.target;h.composing=1},u=p=>{let h=p.target;h.composing&&(h.composing=0,h.dispatchEvent(new Event(s)))},l=()=>{t.removeEventListener(s,f),t.removeEventListener("change",a),t.removeEventListener("compositionstart",c),t.removeEventListener("compositionend",u),t.removeEventListener("change",u)},f=p=>{let h=n();if(!h)return;let y=p.target;if(!y||y.composing)return;let d=y.value,C=it(o()[1]);if(i||C.number||C.int){if(C.int)d=parseInt(d);else{if(po.test(d[d.length-1])&&d.split(po).length===2){if(d+="0",d=parseFloat(d),isNaN(d))d="";else if(h()===d)return}d=parseFloat(d)}isNaN(d)&&(d=""),t.value=d}else C.trim&&(d=d.trim());h(d)};return t.addEventListener(s,f),t.addEventListener("change",a),t.addEventListener("compositionstart",c),t.addEventListener("compositionend",u),t.addEventListener("change",u),l},Br=(t,e)=>{let n="change",o=()=>{t.removeEventListener(n,r)},r=()=>{let s=e();if(!s)return;let i=Re(t),a=t.checked,c=s();if(w(c)){let u=_t(c,i),l=u!==-1;a&&!l?c.push(i):!a&&l&&c.splice(u,1)}else ue(c)?a?c.add(i):c.delete(i):s($r(t,a))};return t.addEventListener(n,r),o},Re=t=>"_value"in t?t._value:t.value,Co="trueValue",jr="falseValue",Eo="true-value",_r="false-value",$r=(t,e)=>{let n=e?Co:jr;if(n in t)return t[n];let o=e?Eo:_r;return t.hasAttribute(o)?t.getAttribute(o):e},Fr=(t,e)=>{if(Co in t)return Ee(e,t.trueValue);let o=Eo;return t.hasAttribute(o)?Ee(e,t.getAttribute(o)):Ee(e,!0)},qr=(t,e)=>{let n="change",o=()=>{t.removeEventListener(n,r)},r=()=>{let s=e();if(!s)return;let i=Re(t);s(i)};return t.addEventListener(n,r),o},zr=(t,e,n)=>{let o="change",r=()=>{t.removeEventListener(o,s)},s=()=>{let i=e();if(!i)return;let c=it(n()[1]).number,u=Array.prototype.filter.call(t.options,l=>l.selected).map(l=>c?fo(Re(l)):Re(l));if(t.multiple){let l=i();try{if(Cn(i),ue(l)){l.clear();for(let f of u)l.add(f)}else w(l)?(l.splice(0),l.push(...u)):i(u)}finally{En(i),Z(i)}}else i(u[0])};return t.addEventListener(o,s),r};var Kr=["stop","prevent","capture","self","once","left","right","middle","passive"],Wr=t=>{let e={};if(F(t))return;let n=t.split(",");for(let o of Kr)e[o]=n.includes(o);return e},Gr=(t,e,n,o,r)=>{var u,l;if(o){let f=e.value(),p=$(o.value()[0]);return z(p)?Rn(t,_(p),()=>e.value()[0],(u=r==null?void 0:r.join(","))!=null?u:f[1]):()=>{}}else if(n){let f=e.value();return Rn(t,_(n),()=>e.value()[0],(l=r==null?void 0:r.join(","))!=null?l:f[1])}let s=[],i=()=>{s.forEach(f=>f())},a=e.value(),c=a.length;for(let f=0;f<c;++f){let p=a[f];if(q(p)&&(p=p()),I(p))for(let h of Object.entries(p)){let y=h[0],d=()=>{let b=e.value()[f];return q(b)&&(b=b()),b=b[y],q(b)&&(b=b()),b},C=p[y+"_flags"];s.push(Rn(t,y,d,C))}else U(2,"r-on",t)}return i},vn={isLazy:(t,e)=>e===-1&&t%2===0,isLazyKey:(t,e)=>e===0&&!t.endsWith("_flags"),once:!1,collectRefObj:!0,mount:({el:t,parseResult:e,option:n,dynamicOption:o,flags:r})=>Gr(t,e,n,o,r)},Jr=(t,e)=>{if(t.startsWith("keydown")||t.startsWith("keyup")||t.startsWith("keypress")){e!=null||(e="");let n=[...t.split("."),...e.split(",")];t=n[0];let o=n[1],r=n.includes("ctrl"),s=n.includes("shift"),i=n.includes("alt"),a=n.includes("meta"),c=u=>!(r&&!u.ctrlKey||s&&!u.shiftKey||i&&!u.altKey||a&&!u.metaKey);return o?[t,u=>c(u)?u.key.toUpperCase()===o.toUpperCase():!1]:[t,c]}return[t,n=>!0]},Rn=(t,e,n,o)=>{if(F(e))return U(5,"r-on",t),()=>{};let r=Wr(o),s=r?{capture:r.capture,passive:r.passive,once:r.once}:void 0,i;[e,i]=Jr(e,o);let a=l=>{if(!i(l)||!n&&e==="submit"&&(r!=null&&r.prevent))return;let f=n(l);q(f)&&(f=f(l)),q(f)&&f(l)},c=()=>{t.removeEventListener(e,u,s)},u=l=>{if(!r){a(l);return}try{if(r.left&&l.button!==0||r.middle&&l.button!==1||r.right&&l.button!==2||r.self&&l.target!==t)return;r.stop&&l.stopPropagation(),r.prevent&&l.preventDefault(),a(l)}finally{r.once&&c()}};return t.addEventListener(e,u,s),c};var Qr=(t,e,n,o)=>{if(n){o&&o.includes("camel")&&(n=_(n)),Ge(t,n,e[0]);return}let r=e.length;for(let s=0;s<r;++s){let i=e[s];if(w(i)){let a=i[0],c=i[1];Ge(t,a,c)}else if(I(i))for(let a of Object.entries(i)){let c=a[0],u=a[1];Ge(t,c,u)}else{let a=e[s++],c=e[s];Ge(t,a,c)}}},Ro={mount:()=>({update:({el:t,values:e,option:n,flags:o})=>{Qr(t,e,n,o)}})};function Xr(t){return!!t||t===""}var Ge=(t,e,n)=>{if(fe(e)){U(3,":prop",t);return}if(e==="innerHTML"||e==="textContent"){let s=[...t.childNodes];setTimeout(()=>s.forEach(ge),1),t[e]=n!=null?n:"";return}let o=t.tagName;if(e==="value"&&o!=="PROGRESS"&&!o.includes("-")){t._value=n;let s=o==="OPTION"?t.getAttribute("value"):t.value,i=n!=null?n:"";s!==i&&(t.value=i),n==null&&t.removeAttribute(e);return}let r=!1;if(n===""||n==null){let s=typeof t[e];s==="boolean"?n=Xr(n):n==null&&s==="string"?(n="",r=!0):s==="number"&&(n=0,r=!0)}try{t[e]=n}catch(s){r||U(4,e,o,n,s)}r&&t.removeAttribute(e)};var vo={once:!0,mount:({el:t,parseResult:e,expr:n})=>{let o=e,r=o.value()[0],s=w(r),i=o.refs[0];return s?r.push(t):i?i==null||i(t):o.context[n]=t,()=>{if(s){let a=r.indexOf(t);a!==-1&&r.splice(a,1)}else i==null||i(null)}}};var Yr=(t,e)=>{let n=Ie(t).data,o=n._ord;_n(o)&&(o=n._ord=t.style.display),!!e[0]?t.style.display=o:t.style.display="none"},wo={mount:()=>({update:({el:t,values:e})=>{Yr(t,e)}})};var Zr=(t,e,n)=>{let o=e.length;for(let r=0;r<o;++r){let s=e[r],i=n==null?void 0:n[r];if(w(s)){let a=s.length;for(let c=0;c<a;++c)So(t,s[c],i==null?void 0:i[c])}else So(t,s,i)}},$t={mount:()=>({update:({el:t,values:e,previousValues:n})=>{Zr(t,e,n)}})},So=(t,e,n)=>{let o=t.style,r=z(e);if(e&&!r){if(n&&!z(n))for(let s in n)e[s]==null&&Sn(o,s,"");for(let s in e)Sn(o,s,e[s])}else{let s=o.display;if(r?n!==e&&(o.cssText=e):n&&t.removeAttribute("style"),"_ord"in Ie(t).data)return;o.display=s}},Ao=/\s*!important$/;function Sn(t,e,n){if(w(n))n.forEach(o=>{Sn(t,e,o)});else if(n==null&&(n=""),e.startsWith("--"))t.setProperty(e,n);else{let o=es(t,e);Ao.test(n)?t.setProperty(Fe(o),n.replace(Ao,""),"important"):t[o]=n}}var No=["Webkit","Moz","ms"],wn={};function es(t,e){let n=wn[e];if(n)return n;let o=_(e);if(o!=="filter"&&o in t)return wn[e]=o;o=nt(o);for(let r=0;r<No.length;r++){let s=No[r]+o;if(s in t)return wn[e]=s}return e}var ce=t=>Oo($(t)),Oo=(t,e=new WeakMap)=>{if(!t||!I(t))return t;if(w(t))return t.map(ce);if(ue(t)){let o=new Set;for(let r of t.keys())o.add(ce(r));return o}if(we(t)){let o=new Map;for(let r of t)o.set(ce(r[0]),ce(r[1]));return o}if(e.has(t))return $(e.get(t));let n={...t};e.set(t,n);for(let o of Object.entries(n))n[o[0]]=Oo($(o[1]),e);return n};var ts=(t,e)=>{var o;let n=e[0];t.textContent=ue(n)?JSON.stringify(ce([...n])):we(n)?JSON.stringify(ce([...n])):I(n)?JSON.stringify(ce(n)):(o=n==null?void 0:n.toString())!=null?o:""},Mo={mount:()=>({update:({el:t,values:e})=>{ts(t,e)}})};var ko={mount:()=>({update:({el:t,values:e})=>{Ge(t,"value",e[0])}})};var Oe=class Oe{constructor(e){m(this,"B",{});m(this,"u",{});m(this,"pt",()=>Object.keys(this.B).filter(e=>e.length===1||!e.startsWith(":")));m(this,"X",new Map);m(this,"$",new Map);m(this,"forGrowThreshold",10);m(this,"globalContext");m(this,"useInterpolation",!0);if(this.setDirectives("r-"),e){this.globalContext=e;return}this.globalContext=this.Lt()}static getDefault(){var e;return(e=Oe.He)!=null?e:Oe.He=new Oe}Lt(){let e={},n=globalThis;for(let o of Oe.Vt.split(","))e[o]=n[o];return e.ref=Ce,e.sref=ae,e.flatten=ce,e}addComponent(...e){for(let n of e){if(!n.defaultName){ht.warning("Registered component's default name is not defined",n);continue}this.X.set(nt(n.defaultName),n),this.$.set(nt(n.defaultName).toLocaleUpperCase(),n)}}setDirectives(e){this.B={".":Ro,":":Tn,"@":vn,[`${e}on`]:vn,[`${e}bind`]:Tn,[`${e}html`]:Vt,[`${e}text`]:Mo,[`${e}show`]:wo,[`${e}model`]:mo,":style":$t,[`${e}style`]:$t,[`${e}bind:style`]:$t,":class":xn,[`${e}bind:class`]:xn,":ref":vo,":value":ko,[`${e}teleport`]:Rt},this.u={for:`${e}for`,if:`${e}if`,else:`${e}else`,elseif:`${e}else-if`,pre:`${e}pre`,inherit:`${e}inherit`,text:`${e}text`,context:":context",contextAlias:`${e}context`,bind:`${e}bind`,on:`${e}on`,keyBind:":key",key:"key",is:":is",teleport:`${e}teleport`,dynamic:"_d_"}}updateDirectives(e){e(this.B,this.u)}};m(Oe,"He"),m(Oe,"Vt","Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console");var de=Oe;var Ft=(t,e)=>{if(!t)return;let o=(e!=null?e:de.getDefault()).u,r=/(\{\{[^]*?\}\}|\[\[[^]*?\]\])/g,s=[{start:"{{",end:"}}"},{start:"[[",end:"]]"}];for(let i of os(t,o.pre,s))ns(i,o.text,r,s)},ns=(t,e,n,o)=>{var c;let r=t.textContent;if(!r)return;let s=n,i=r.split(s);if(i.length<=1)return;if(((c=t.parentElement)==null?void 0:c.childNodes.length)===1&&i.length===3){let u=i[1],l=Lo(u,o);if(l&&F(i[0])&&F(i[2])){let f=t.parentElement;f.setAttribute(e,u.substring(l.start.length,u.length-l.end.length)),f.innerText="";return}}let a=document.createDocumentFragment();for(let u of i){let l=Lo(u,o);if(l){let f=document.createElement("span");f.setAttribute(e,u.substring(l.start.length,u.length-l.end.length)),a.appendChild(f)}else a.appendChild(document.createTextNode(u))}t.replaceWith(a)},os=(t,e,n)=>{let o=[],r=s=>{var i;if(s.nodeType===Node.TEXT_NODE)n.some(a=>{var c;return(c=s.textContent)==null?void 0:c.includes(a.start)})&&o.push(s);else{if((i=s==null?void 0:s.hasAttribute)!=null&&i.call(s,e))return;for(let a of xe(s))r(a)}};return r(t),o},Lo=(t,e)=>e.find(n=>t.startsWith(n.start)&&t.endsWith(n.end));var rs=9,ss=10,is=13,as=32,ve=46,qt=44,cs=39,us=34,zt=40,Je=41,Kt=91,An=93,Nn=63,ls=59,Io=58,Vo=123,Wt=125,De=43,Gt=45,On=96,Do=47,Mn=92,Po=new Set([2,3]),$o={"=":2.5,"*=":2.5,"**=":2.5,"/=":2.5,"%=":2.5,"+=":2.5,"-=":2.5,"<<=":2.5,">>=":2.5,">>>=":2.5,"&=":2.5,"^=":2.5,"|=":2.5},fs={"=>":2,...$o,"||":3,"??":3,"&&":4,"|":5,"^":6,"&":7,"==":8,"!=":8,"===":8,"!==":8,"<":9,">":9,"<=":9,">=":9,in:9,"<<":10,">>":10,">>>":10,"+":11,"-":11,"*":12,"/":12,"%":12,"**":13},Fo=Object.keys($o),ps=new Set(Fo),Ln=new Set(["=>"]);Fo.forEach(t=>Ln.add(t));var Uo={true:!0,false:!1,null:null},ms="this",Qe="Expected ",Pe="Unexpected ",Vn="Unclosed ",ds=Qe+":",Ho=Qe+"expression",hs="missing }",ys=Pe+"object property",gs=Vn+"(",Bo=Qe+"comma",jo=Pe+"token ",bs=Pe+"period",kn=Qe+"expression after ",Ts="missing unaryOp argument",xs=Vn+"[",Cs=Qe+"exponent (",Es="Variable names cannot start with a number (",Rs=Vn+'quote after "',at=t=>t>=48&&t<=57,_o=t=>fs[t],In=class{constructor(e){m(this,"p");m(this,"e");this.p=e,this.e=0}get H(){return this.p.charAt(this.e)}get h(){return this.p.charCodeAt(this.e)}f(e){return this.p.charCodeAt(this.e)===e}K(e){return e>=65&&e<=90||e>=97&&e<=122||e===36||e===95||e>=128}ue(e){return this.K(e)||at(e)}i(e){return new Error(`${e} at character ${this.e}`)}g(){let e=this.h,n=this.p,o=this.e;for(;e===as||e===rs||e===ss||e===is;)e=n.charCodeAt(++o);this.e=o}parse(){let e=this.pe();return e.length===1?e[0]:{type:0,body:e}}pe(e){let n=[];for(;this.e<this.p.length;){let o=this.h;if(o===ls||o===qt)this.e++;else{let r=this.S();if(r)n.push(r);else if(this.e<this.p.length){if(o===e)break;throw this.i(Pe+'"'+this.H+'"')}}}return n}S(){var n;let e=(n=this.It())!=null?n:this.je();return this.g(),this.Pt(e)}le(){this.g();let e=this.p,n=this.e,o=e.charCodeAt(n),r=e.charCodeAt(n+1),s=e.charCodeAt(n+2),i=e.charCodeAt(n+3);if(isNaN(o))return!1;let a=!1,c=0;return o===62&&r===62&&s===62&&i===61?(a=">>>=",c=4):o===61&&r===61&&s===61?(a="===",c=3):o===33&&r===61&&s===61?(a="!==",c=3):o===62&&r===62&&s===62?(a=">>>",c=3):o===60&&r===60&&s===61?(a="<<=",c=3):o===62&&r===62&&s===61?(a=">>=",c=3):o===42&&r===42&&s===61?(a="**=",c=3):o===61&&r===62?(a="=>",c=2):o===124&&r===124?(a="||",c=2):o===63&&r===63?(a="??",c=2):o===38&&r===38?(a="&&",c=2):o===61&&r===61?(a="==",c=2):o===33&&r===61?(a="!=",c=2):o===60&&r===61?(a="<=",c=2):o===62&&r===61?(a=">=",c=2):o===60&&r===60?(a="<<",c=2):o===62&&r===62?(a=">>",c=2):o===43&&r===61?(a="+=",c=2):o===45&&r===61?(a="-=",c=2):o===42&&r===61?(a="*=",c=2):o===47&&r===61?(a="/=",c=2):o===37&&r===61?(a="%=",c=2):o===38&&r===61?(a="&=",c=2):o===94&&r===61?(a="^=",c=2):o===124&&r===61?(a="|=",c=2):o===42&&r===42?(a="**",c=2):o===105&&r===110?this.ue(e.charCodeAt(n+2))||(a="in",c=2):o===61?(a="=",c=1):o===124?(a="|",c=1):o===94?(a="^",c=1):o===38?(a="&",c=1):o===60?(a="<",c=1):o===62?(a=">",c=1):o===43?(a="+",c=1):o===45?(a="-",c=1):o===42?(a="*",c=1):o===47?(a="/",c=1):o===37&&(a="%",c=1),a?(this.e+=c,a):!1}je(){let e,n,o,r,s,i,a,c;if(s=this.z(),!s||(n=this.le(),!n))return s;if(r={value:n,prec:_o(n),right_a:Ln.has(n)},i=this.z(),!i)throw this.i(kn+n);let u=[s,r,i];for(;n=this.le();){o=_o(n),r={value:n,prec:o,right_a:Ln.has(n)},c=n;let l=f=>r.right_a&&f.right_a?o>f.prec:o<=f.prec;for(;u.length>2&&l(u[u.length-2]);)i=u.pop(),n=u.pop().value,s=u.pop(),e=this._e(n,s,i),u.push(e);if(e=this.z(),!e)throw this.i(kn+c);u.push(r,e)}for(a=u.length-1,e=u[a];a>1;)e=this._e(u[a-1].value,u[a-2],e),a-=2;return e}z(){let e;if(this.g(),e=this.Dt(),e)return this.fe(e);let n=this.h;if(at(n)||n===ve)return this.Ut();if(n===cs||n===us)e=this.Bt();else if(n===Kt)e=this.Ht();else{let o=this.jt();if(o){let r=this.z();if(!r)throw this.i(Ts);return this.fe({type:7,operator:o,argument:r})}this.K(n)?(e=this.me(),e.name in Uo?e={type:4,value:Uo[e.name],raw:e.name}:e.name===ms&&(e={type:5})):n===zt&&(e=this._t())}return e?(e=this.W(e),this.fe(e)):!1}_e(e,n,o){if(e==="=>"){let r=n.type===1?n.expressions:[n];return{type:15,params:r,body:o}}return ps.has(e)?{type:16,operator:e,left:n,right:o}:{type:8,operator:e,left:n,right:o}}Dt(){let e={node:!1};return this.$t(e),e.node||(this.qt(e),e.node)||(this.Ft(e),e.node)||(this.$e(e),e.node)||this.Kt(e),e.node}fe(e){let n={node:e};return this.zt(n),this.Wt(n),this.Gt(n),n.node}jt(){let e=this.p,n=this.e,o=e.charCodeAt(n),r=e.charCodeAt(n+1),s=e.charCodeAt(n+2),i=e.charCodeAt(n+3);return o===Gt?(this.e++,"-"):o===33?(this.e++,"!"):o===126?(this.e++,"~"):o===De?(this.e++,"+"):o===110&&r===101&&s===119&&!this.ue(i)?(this.e+=3,"new"):!1}It(){let e={};return this.Jt(e),e.node}Pt(e){let n={node:e};return this.Qt(n),n.node}W(e){this.g();let n=this.h;for(;n===ve||n===Kt||n===zt||n===Nn;){let o;if(n===Nn){if(this.p.charCodeAt(this.e+1)!==ve)break;o=!0,this.e+=2,this.g(),n=this.h}if(this.e++,n===Kt){if(e={type:3,computed:!0,object:e,property:this.S()},this.g(),n=this.h,n!==An)throw this.i(xs);this.e++}else n===zt?e={type:6,arguments:this.qe(Je),callee:e}:(o&&this.e--,this.g(),e={type:3,computed:!1,object:e,property:this.me()});o&&(e.optional=!0),this.g(),n=this.h}return e}Ut(){let e=this.p,n=this.e,o=n;for(;at(e.charCodeAt(o));)o++;if(e.charCodeAt(o)===ve)for(o++;at(e.charCodeAt(o));)o++;let r=e.charCodeAt(o);if(r===101||r===69){o++;let a=e.charCodeAt(o);(a===De||a===Gt)&&o++;let c=o;for(;at(e.charCodeAt(o));)o++;if(c===o){this.e=o;let u=e.slice(n,o);throw this.i(Cs+u+this.H+")")}}this.e=o;let s=e.slice(n,o),i=e.charCodeAt(o);if(this.K(i))throw this.i(Es+s+this.H+")");if(i===ve||s.length===1&&s.charCodeAt(0)===ve)throw this.i(bs);return{type:4,value:parseFloat(s),raw:s}}Bt(){let e=this.p,n=e.length,o=this.e,r=e.charCodeAt(this.e++),s=this.e,i=s,a=[],c=!1,u=!1;for(;s<n;){let f=e.charCodeAt(s);if(f===r){u=!0,this.e=s+1;break}if(f===Mn){c||(c=!0),a.push(e.slice(i,s));let p=e.charCodeAt(s+1);a.push(this.Fe(p)),s+=2,i=s}else s++}let l=c?a.join("")+e.slice(i,u?s:n):e.slice(i,u?s:n);if(!u)throw this.e=s,this.i(Rs+l+'"');return{type:4,value:l,raw:e.substring(o,this.e)}}Fe(e){switch(e){case 110:return`
|
|
2
|
+
`;case 114:return"\r";case 116:return" ";case 98:return"\b";case 102:return"\f";case 118:return"\v";default:return isNaN(e)?"":String.fromCharCode(e)}}me(){let e=this.h,n=this.e;if(this.K(e))this.e++;else throw this.i(Pe+this.H);for(;this.e<this.p.length&&(e=this.h,this.ue(e));)this.e++;return{type:2,name:this.p.slice(n,this.e)}}qe(e){let n=[],o=!1,r=0;for(;this.e<this.p.length;){this.g();let s=this.h;if(s===e){if(o=!0,this.e++,e===Je&&r&&r>=n.length)throw this.i(jo+String.fromCharCode(e));break}else if(s===qt){if(this.e++,r++,r!==n.length){if(e===Je)throw this.i(jo+",");for(let i=n.length;i<r;i++)n.push(null)}}else{if(n.length!==r&&r!==0)throw this.i(Bo);{let i=this.S();if(!i||i.type===0)throw this.i(Bo);n.push(i)}}}if(!o)throw this.i(Qe+String.fromCharCode(e));return n}_t(){this.e++;let e=this.pe(Je);if(this.f(Je))return this.e++,e.length===1?e[0]:e.length?{type:1,expressions:e}:!1;throw this.i(gs)}Ht(){return this.e++,{type:9,elements:this.qe(An)}}$t(e){if(this.f(Vo)){this.e++;let n=[];for(;!isNaN(this.h);){if(this.g(),this.f(Wt)){this.e++,e.node=this.W({type:10,properties:n});return}let o=this.S();if(!o)break;if(this.g(),o.type===2&&(this.f(qt)||this.f(Wt)))n.push({type:12,computed:!1,key:o,value:o,shorthand:!0});else if(this.f(Io)){this.e++;let r=this.S();if(!r)throw this.i(ys);let s=o.type===9;n.push({type:12,computed:s,key:s?o.elements[0]:o,value:r,shorthand:!1}),this.g()}else n.push(o);this.f(qt)&&this.e++}throw this.i(hs)}}qt(e){let n=this.h;if((n===De||n===Gt)&&n===this.p.charCodeAt(this.e+1)){this.e+=2;let o=e.node={type:13,operator:n===De?"++":"--",argument:this.W(this.me()),prefix:!0};if(!o.argument||!Po.has(o.argument.type))throw this.i(Pe+o.operator)}}Wt(e){let n=e.node,o=this.h;if((o===De||o===Gt)&&o===this.p.charCodeAt(this.e+1)){if(!Po.has(n.type))throw this.i(Pe+(o===De?"++":"--"));this.e+=2,e.node={type:13,operator:o===De?"++":"--",argument:n,prefix:!1}}}Ft(e){this.p.charCodeAt(this.e)===ve&&this.p.charCodeAt(this.e+1)===ve&&this.p.charCodeAt(this.e+2)===ve&&(this.e+=3,e.node={type:14,argument:this.S()})}Qt(e){if(e.node&&this.f(Nn)){this.e++;let n=e.node,o=this.S();if(!o)throw this.i(Ho);if(this.g(),this.f(Io)){this.e++;let r=this.S();if(!r)throw this.i(Ho);e.node={type:11,test:n,consequent:o,alternate:r}}else throw this.i(ds)}}Jt(e){if(this.g(),this.f(zt)){let n=this.e;if(this.e++,this.g(),this.f(Je)){this.e++;let o=this.le();if(o==="=>"){let r=this.je();if(!r)throw this.i(kn+o);e.node={type:15,params:null,body:r};return}}this.e=n}}Gt(e){let n=e.node,o=n.type;(o===2||o===3)&&this.f(On)&&(e.node={type:17,tag:n,quasi:this.$e(e)})}$e(e){if(!this.f(On))return;let n=this.p,o=n.length,r={type:19,quasis:[],expressions:[]},s=++this.e,i=[],a=[],c=!1,u=l=>{if(!c){let h=n.slice(s,this.e);return r.quasis.push({type:18,value:{raw:h,cooked:h},tail:l})}i.push(n.slice(s,this.e)),a.push(n.slice(s,this.e));let f=i.join(""),p=a.join("");return i.length=0,a.length=0,c=!1,r.quasis.push({type:18,value:{raw:f,cooked:p},tail:l})};for(;this.e<o;){let l=n.charCodeAt(this.e);if(l===On)return u(!0),this.e+=1,e.node=r,r;if(l===36&&n.charCodeAt(this.e+1)===Vo){if(u(!1),this.e+=2,r.expressions.push(...this.pe(Wt)),!this.f(Wt))throw this.i("unclosed ${");this.e+=1,s=this.e}else if(l===Mn){c||(c=!0),i.push(n.slice(s,this.e)),a.push(n.slice(s,this.e));let f=n.charCodeAt(this.e+1);i.push(n.slice(this.e,this.e+2)),a.push(this.Fe(f)),this.e+=2,s=this.e}else this.e+=1}throw this.i("Unclosed `")}zt(e){let n=e.node;if(!n||n.operator!=="new"||!n.argument)return;if(!n.argument||![6,3].includes(n.argument.type))throw this.i("Expected new function()");e.node=n.argument;let o=e.node;for(;o.type===3||o.type===6&&o.callee.type===3;)o=o.type===3?o.object:o.callee.object;o.type=20}Kt(e){if(!this.f(Do))return;let n=++this.e,o=!1;for(;this.e<this.p.length;){if(this.h===Do&&!o){let r=this.p.slice(n,this.e),s="";for(;++this.e<this.p.length;){let a=this.h;if(a>=97&&a<=122||a>=65&&a<=90||a>=48&&a<=57)s+=this.H;else break}let i;try{i=new RegExp(r,s)}catch(a){throw this.i(a.message)}return e.node={type:4,value:i,raw:this.p.slice(n-1,this.e)},e.node=this.W(e.node),e.node}this.f(Kt)?o=!0:o&&this.f(An)&&(o=!1),this.e+=this.f(Mn)?2:1}throw this.i("Unclosed Regex")}},qo=t=>new In(t).parse();var vs={"=>":(t,e)=>{},"=":(t,e)=>{},"*=":(t,e)=>{},"**=":(t,e)=>{},"/=":(t,e)=>{},"%=":(t,e)=>{},"+=":(t,e)=>{},"-=":(t,e)=>{},"<<=":(t,e)=>{},">>=":(t,e)=>{},">>>=":(t,e)=>{},"&=":(t,e)=>{},"^=":(t,e)=>{},"|=":(t,e)=>{},"||":(t,e)=>t()||e(),"??":(t,e)=>{var n;return(n=t())!=null?n:e()},"&&":(t,e)=>t()&&e(),"|":(t,e)=>t|e,"^":(t,e)=>t^e,"&":(t,e)=>t&e,"==":(t,e)=>t==e,"!=":(t,e)=>t!=e,"===":(t,e)=>t===e,"!==":(t,e)=>t!==e,"<":(t,e)=>t<e,">":(t,e)=>t>e,"<=":(t,e)=>t<=e,">=":(t,e)=>t>=e,in:(t,e)=>t in e,"<<":(t,e)=>t<<e,">>":(t,e)=>t>>e,">>>":(t,e)=>t>>>e,"+":(t,e)=>t+e,"-":(t,e)=>t-e,"*":(t,e)=>t*e,"/":(t,e)=>t/e,"%":(t,e)=>t%e,"**":(t,e)=>t**e},ws={"-":t=>-t,"+":t=>+t,"!":t=>!t,"~":t=>~t,new:t=>t},Go=t=>{if(!(t!=null&&t.some(Wo)))return t;let e=[];return t.forEach(n=>Wo(n)?e.push(...n):e.push(n)),e},zo=(...t)=>Go(t),Dn=(t,e)=>{if(!t)return e;let n=Object.create(e!=null?e:{});return n.$event=t,n},Ss={"++":(t,e)=>{let n=t[e];if(x(n)){let o=n();return n(++o),o}return++t[e]},"--":(t,e)=>{let n=t[e];if(x(n)){let o=n();return n(--o),o}return--t[e]}},As={"++":(t,e)=>{let n=t[e];if(x(n)){let o=n();return n(o+1),o}return t[e]++},"--":(t,e)=>{let n=t[e];if(x(n)){let o=n();return n(o-1),o}return t[e]--}},Ko={"=":(t,e,n)=>{let o=t[e];return x(o)?o(n):t[e]=n},"+=":(t,e,n)=>{let o=t[e];return x(o)?o(o()+n):t[e]+=n},"-=":(t,e,n)=>{let o=t[e];return x(o)?o(o()-n):t[e]-=n},"*=":(t,e,n)=>{let o=t[e];return x(o)?o(o()*n):t[e]*=n},"/=":(t,e,n)=>{let o=t[e];return x(o)?o(o()/n):t[e]/=n},"%=":(t,e,n)=>{let o=t[e];return x(o)?o(o()%n):t[e]%=n},"**=":(t,e,n)=>{let o=t[e];return x(o)?o(o()**n):t[e]**=n},"<<=":(t,e,n)=>{let o=t[e];return x(o)?o(o()<<n):t[e]<<=n},">>=":(t,e,n)=>{let o=t[e];return x(o)?o(o()>>n):t[e]>>=n},">>>=":(t,e,n)=>{let o=t[e];return x(o)?o(o()>>>n):t[e]>>>=n},"|=":(t,e,n)=>{let o=t[e];return x(o)?o(o()|n):t[e]|=n},"&=":(t,e,n)=>{let o=t[e];return x(o)?o(o()&n):t[e]&=n},"^=":(t,e,n)=>{let o=t[e];return x(o)?o(o()^n):t[e]^=n}},Jt=(t,e)=>q(t)?t.bind(e):t,Pn=class{constructor(e,n,o,r,s){m(this,"l");m(this,"Ke");m(this,"ze");m(this,"We");m(this,"A");m(this,"Ge");m(this,"Je");this.l=w(e)?e:[e],this.Ke=n,this.ze=o,this.We=r,this.Je=!!s}Qe(e,n){if(n&&e in n)return n;for(let o of this.l)if(e in o)return o}2(e,n,o){let r=e.name;if(r==="$root")return this.l[this.l.length-1];if(r==="$parent")return this.l[1];if(r==="$ctx")return[...this.l];if(o&&r in o)return this.A=o[r],Jt($(o[r]),o);for(let i of this.l)if(r in i)return this.A=i[r],Jt($(i[r]),i);let s=this.Ke;if(s&&r in s)return this.A=s[r],Jt($(s[r]),s)}5(e,n,o){return this.l[0]}0(e,n,o){return this.Xe(n,o,zo,...e.body)}1(e,n,o){return this.E(n,o,(...r)=>r.pop(),...e.expressions)}3(e,n,o){let{obj:r,key:s}=this.de(e,n,o),i=r==null?void 0:r[s];return this.A=i,Jt($(i),r)}4(e,n,o){return e.value}6(e,n,o){let r=(i,...a)=>q(i)?i(...Go(a)):i,s=this.E(++n,o,r,e.callee,...e.arguments);return this.A=s,s}7(e,n,o){return this.E(n,o,ws[e.operator],e.argument)}8(e,n,o){let r=vs[e.operator];switch(e.operator){case"||":case"&&":case"??":return r(()=>this.b(e.left,n,o),()=>this.b(e.right,n,o))}return this.E(n,o,r,e.left,e.right)}9(e,n,o){return this.Xe(++n,o,zo,...e.elements)}10(e,n,o){let r={},s=(...i)=>{i.forEach(a=>{Object.assign(r,a)})};return this.E(++n,o,s,...e.properties),r}11(e,n,o){return this.E(n,o,r=>this.b(r?e.consequent:e.alternate,n,o),e.test)}12(e,n,o){var l;let r={},s=f=>(f==null?void 0:f.type)!==15,i=(l=this.We)!=null?l:()=>!1,a=n===0&&this.Je,c=f=>this.Ye(a,e.key,n,Dn(f,o)),u=f=>this.Ye(a,e.value,n,Dn(f,o));if(e.shorthand){let f=e.key.name;r[f]=s(e.key)&&i(f,n)?c:c()}else if(e.computed){let f=$(c());r[f]=s(e.value)&&i(f,n)?u:u()}else{let f=e.key.type===4?e.key.value:e.key.name;r[f]=s(e.value)&&i(f,n)?()=>u:u()}return r}de(e,n,o){let r=this.b(e.object,n,o),s=e.computed?this.b(e.property,n,o):e.property.name;return{obj:r,key:s}}13(e,n,o){let r=e.argument,s=e.operator,i=e.prefix?Ss:As;if(r.type===2){let a=r.name,c=this.Qe(a,o);return fe(c)?void 0:i[s](c,a)}if(r.type===3){let{obj:a,key:c}=this.de(r,n,o);return i[s](a,c)}}16(e,n,o){let r=e.left,s=e.operator;if(r.type===2){let i=r.name,a=this.Qe(i,o);if(fe(a))return;let c=this.b(e.right,n,o);return Ko[s](a,i,c)}if(r.type===3){let{obj:i,key:a}=this.de(r,n,o),c=this.b(e.right,n,o);return Ko[s](i,a,c)}}14(e,n,o){let r=this.b(e.argument,n,o);return w(r)&&(r.s=Jo),r}17(e,n,o){return this[6]({type:6,callee:e.tag,arguments:[{type:9,elements:e.quasi.quasis},...e.quasi.expressions]},n,o)}19(e,n,o){let r=(...s)=>s.reduce((i,a,c)=>i+=a+e.quasis[c+1].value.cooked,e.quasis[0].value.cooked);return this.E(n,o,r,...e.expressions)}18(e,n,o){return e.value.cooked}20(e,n,o){let r=(s,...i)=>new s(...i);return this.E(n,o,r,e.callee,...e.arguments)}15(e,n,o){return(...r)=>{let s=Object.create(o!=null?o:{}),i=e.params;if(i){let a=0;for(let c of i)s[c.name]=r[a++]}return this.b(e.body,n,s)}}b(e,n,o){let r=$(this[e.type](e,n,o));return this.Ge=e.type,r}Ye(e,n,o,r){let s=this.b(n,o,r);return e&&this.Ze()?this.A:s}Ze(){let e=this.Ge;return(e===2||e===3||e===6)&&x(this.A)}eval(e,n){let{value:o,refs:r}=hn(()=>this.b(e,-1,n)),s={value:o,refs:r};return this.Ze()&&(s.ref=this.A),s}E(e,n,o,...r){let s=r.map(i=>i&&this.b(i,e,n));return o(...s)}Xe(e,n,o,...r){let s=this.ze;if(!s)return this.E(e,n,o,...r);let i=r.map((a,c)=>a&&(a.type!==15&&s(c,e)?u=>this.b(a,e,Dn(u,n)):this.b(a,e,n)));return o(...i)}},Jo=Symbol("s"),Wo=t=>(t==null?void 0:t.s)===Jo,Qo=(t,e,n,o,r,s,i)=>new Pn(e,n,o,r,i).eval(t,s);var Xo={},Yo=t=>!!t,Qt=class{constructor(e,n){m(this,"l");m(this,"o");m(this,"et",[]);this.l=e,this.o=n}v(e){this.l=[e,...this.l]}Y(){return this.l.map(n=>n.components).filter(Yo).reverse().reduce((n,o)=>{for(let[r,s]of Object.entries(o))n[r.toUpperCase()]=s;return n},{})}ut(){let e=[],n=new Set,o=this.l.map(r=>r.components).filter(Yo).reverse();for(let r of o)for(let s of Object.keys(r))n.has(s)||(n.add(s),e.push(s));return e}V(e,n,o,r,s){var b;let i=[],a=[],c=new Set,u=()=>{for(let E=0;E<a.length;++E)a[E]();a.length=0},p={value:()=>i,stop:()=>{u(),c.clear()},subscribe:(E,V)=>(c.add(E),V&&E(i),()=>{c.delete(E)}),refs:[],context:this.l[0]};if(F(e))return p;let h=this.o.globalContext,y=[],d=new Set,C=(E,V,W,H)=>{try{let B=Qo(E,V,h,n,o,H,r);return W&&B.refs.length>0&&y.push(...B.refs),{value:B.value,refs:B.refs,ref:B.ref}}catch(B){U(6,`evaluation error: ${e}`,B)}return{value:void 0,refs:[]}};try{let E=(b=Xo[e])!=null?b:qo("["+e+"]");Xo[e]=E;let V=this.l.slice(),W=E.elements,H=W.length,B=new Array(H);p.refs=B;let ee=()=>{y.length=0,s||(d.clear(),u());let oe=new Array(H);for(let M=0;M<H;++M){let T=W[M];if(n!=null&&n(M,-1)){oe[M]=Q=>C(T,V,!1,{$event:Q}).value;continue}let N=C(T,V,!0);oe[M]=N.value,B[M]=N.ref}if(!s)for(let M of y)d.has(M)||(d.add(M),a.push(re(M,ee)));if(i=oe,c.size!==0)for(let M of c)c.has(M)&&M(i)};ee()}catch(E){U(6,`parse error: ${e}`,E)}return p}L(){return this.l.slice()}ie(e){this.et.push(this.l),this.l=e}C(e,n){try{this.ie(e),n()}finally{this.Xt()}}Xt(){var e;this.l=(e=this.et.pop())!=null?e:[]}};var Zo=t=>{let e=t.charCodeAt(0);return e>=48&&e<=57||e>=65&&e<=90||e>=97&&e<=122||t==="-"||t==="_"||t===":"},Ns=(t,e)=>{let n="";for(let o=e;o<t.length;++o){let r=t[o];if(n){r===n&&(n="");continue}if(r==='"'||r==="'"){n=r;continue}if(r===">")return o}return-1},Os=(t,e)=>{let n=e?2:1;for(;n<t.length&&(t[n]===" "||t[n]===`
|
|
3
|
+
`);)++n;if(n>=t.length||!Zo(t[n]))return null;let o=n;for(;n<t.length&&Zo(t[n]);)++n;return{start:o,end:n}},er=new Set(["table","thead","tbody","tfoot"]),Ms=new Set(["thead","tbody","tfoot"]),ks=new Set(["caption","colgroup","thead","tbody","tfoot","tr"]),Ls=new Set(["area","base","br","col","embed","hr","img","input","link","meta","param","source","track","wbr"]),tr=(t,e)=>`${t.slice(0,t.length-2)}></${e}>`,Xt=t=>{var s;let e=0,n=[],o=[],r=0;for(;e<t.length;){let i=t.indexOf("<",e);if(i===-1){n.push(t.slice(e));break}if(n.push(t.slice(e,i)),t.startsWith("<!--",i)){let b=t.indexOf("-->",i+4);if(b===-1){n.push(t.slice(i));break}n.push(t.slice(i,b+3)),e=b+3;continue}let a=Ns(t,i);if(a===-1){n.push(t.slice(i));break}let c=t.slice(i,a+1),u=c.startsWith("</");if(c.startsWith("<!")||c.startsWith("<?")){n.push(c),e=a+1;continue}let f=Os(c,u);if(!f){n.push(c),e=a+1;continue}let p=c.slice(f.start,f.end);if(u){let b=o[o.length-1];b?(o.pop(),n.push(b.replacementHost?`</${b.replacementHost}>`:c),er.has(b.effectiveTag)&&--r):n.push(c),e=a+1;continue}let h=c.charCodeAt(c.length-2)===47,y=o[o.length-1],d=null;r===0?p==="tr"?d="trx":p==="td"?d="tdx":p==="th"&&(d="thx"):Ms.has((s=y==null?void 0:y.effectiveTag)!=null?s:"")?d=p==="tr"?null:"tr":(y==null?void 0:y.effectiveTag)==="table"?d=ks.has(p)?null:"tr":(y==null?void 0:y.effectiveTag)==="tr"&&(d=p==="td"||p==="th"?null:"td");let C=h&&!Ls.has(d||p);if(d){let b=d==="trx"||d==="tdx"||d==="thx",E=`${c.slice(0,f.start)}${d} is="${b?`r-${p}`:`regor:${p}`}"${c.slice(f.end)}`;n.push(C?tr(E,d):E)}else n.push(C?tr(c,p):c);if(!h){let b=d==="trx"?"tr":d==="tdx"?"td":d==="thx"?"th":d||p;o.push({replacementHost:d,effectiveTag:b}),er.has(b)&&++r}e=a+1}return n.join("")};var Is="svg,animate,animateMotion,animateTransform,circle,clipPath,color-profile,defs,desc,discard,ellipse,feBlend,feColorMatrix,feComponentTransfer,feComposite,feConvolveMatrix,feDiffuseLighting,feDisplacementMap,feDistantLight,feDropShadow,feFlood,feFuncA,feFuncB,feFuncG,feFuncR,feGaussianBlur,feImage,feMerge,feMergeNode,feMorphology,feOffset,fePointLight,feSpecularLighting,feSpotLight,feTile,feTurbulence,filter,foreignObject,g,hatch,hatchpath,image,line,linearGradient,marker,mask,mesh,meshgradient,meshpatch,meshrow,metadata,mpath,path,pattern,polygon,polyline,radialGradient,rect,set,solidcolor,stop,switch,symbol,text,textPath,title,tspan,unknown,use,view",Vs=new Set(Is.toUpperCase().split(",")),Ds="http://www.w3.org/2000/svg",nr=(t,e)=>{pe(t)?t.content.appendChild(e):t.appendChild(e)},Un=(t,e,n,o)=>{var i;let r=t.t;if(r){let a=n&&Vs.has(r.toUpperCase())?document.createElementNS(Ds,r.toLowerCase()):document.createElement(r),c=t.a;if(c)for(let l of Object.entries(c)){let f=l[0],p=l[1];f.startsWith("#")&&(p=f.substring(1),f="name"),a.setAttribute(Et(f,o),p)}let u=t.c;if(u)for(let l of u)Un(l,a,n,o);nr(e,a);return}let s=t.d;if(s){let a;switch((i=t.n)!=null?i:Node.TEXT_NODE){case Node.COMMENT_NODE:a=document.createComment(s);break;case Node.TEXT_NODE:a=document.createTextNode(s);break}if(a)nr(e,a);else throw new Error("unsupported node type.")}},Xe=(t,e,n)=>{n!=null||(n=de.getDefault());let o=document.createDocumentFragment();if(!w(t))return Un(t,o,!!e,n),o;for(let r of t)Un(r,o,!!e,n);return o};var Ps=(t,e={selector:"#app"},n)=>{z(e)&&(e={selector:"#app",template:e}),eo(t)&&(t=t.context);let o=e.element?e.element:e.selector?document.querySelector(e.selector):null;if(!o||!be(o))throw j(0);n||(n=de.getDefault());let r=()=>{for(let a of[...o.childNodes])J(a)},s=a=>{for(let c of a)o.appendChild(c)};if(e.template){let a=document.createRange().createContextualFragment(Xt(e.template));r(),s(a.childNodes),e.element=a}else if(e.json){let a=Xe(e.json,e.isSVG,n);r(),s(a.childNodes)}return n.useInterpolation&&Ft(o,n),new Hn(t,o,n).y(),K(o,()=>{Se(t)}),vt(t),{context:t,unmount:()=>{J(o)},unbind:()=>{ge(o)}}},Hn=class{constructor(e,n,o){m(this,"Yt");m(this,"tt");m(this,"o");m(this,"m");m(this,"r");this.Yt=e,this.tt=n,this.o=o,this.m=new Qt([e],o),this.r=new Bt(this.m)}y(){this.r._(this.tt)}};var ct=t=>{if(w(t))return t.map(r=>ct(r));let e={};if(t.tagName)e.t=t.tagName;else return t.nodeType===Node.COMMENT_NODE&&(e.n=Node.COMMENT_NODE),t.textContent&&(e.d=t.textContent),e;let n=t.getAttributeNames();n.length>0&&(e.a=Object.fromEntries(n.map(r=>{var s;return[r,(s=t.getAttribute(r))!=null?s:""]})));let o=xe(t);return o.length>0&&(e.c=[...o].map(r=>ct(r))),e};var Us=(t,e={})=>{var s,i,a,c,u,l;w(e)&&(e={props:e}),z(t)&&(t={template:t});let n=(s=e.context)!=null?s:()=>({}),o=!1;if(t.element){let f=t.element;f.remove(),t.element=f}else if(t.selector){let f=document.querySelector(t.selector);if(!f)throw j(1,t.selector);f.remove(),t.element=f}else if(t.template){let f=document.createRange().createContextualFragment(Xt(t.template));t.element=f}else t.json&&(t.element=Xe(t.json,t.isSVG,e.config),o=!0);t.element||(t.element=document.createDocumentFragment()),((i=e.useInterpolation)==null||i)&&Ft(t.element,(a=e.config)!=null?a:de.getDefault());let r=t.element;if(!o&&(((u=t.isSVG)!=null?u:tt(r)&&((c=r.hasAttribute)!=null&&c.call(r,"isSVG")))||tt(r)&&r.querySelector("[isSVG]"))){let f=r.content,p=f?[...f.childNodes]:[...r.childNodes],h=ct(p);t.element=Xe(h,!0,e.config)}return{context:n,template:t.element,inheritAttrs:(l=e.inheritAttrs)!=null?l:!0,props:e.props,defaultName:e.defaultName}};var Me=(t,e)=>{throw new Error(`Invalid prop "${t}": ${e}.`)},Hs=t=>{var n;if(t===null)return"null";if(t===void 0)return"undefined";if(typeof t=="string")return"string";if(typeof t=="number")return"number";if(typeof t=="boolean")return"boolean";if(typeof t=="bigint")return"bigint";if(typeof t=="symbol")return"symbol";if(typeof t=="function")return"function";if(w(t))return"array";if(t instanceof Date)return"Date";if(t instanceof RegExp)return"RegExp";if(t instanceof Map)return"Map";if(t instanceof Set)return"Set";let e=(n=t==null?void 0:t.constructor)==null?void 0:n.name;return e&&e!=="Object"?e:"object"},Bs=t=>typeof t=="string"?`"${t}"`:typeof t=="number"||typeof t=="boolean"?String(t):t===null?"null":t===void 0?"undefined":Hs(t),js=(t,e)=>{typeof t!="string"&&Me(e,"expected string")},_s=(t,e)=>{typeof t!="number"&&Me(e,"expected number")},$s=(t,e)=>{typeof t!="boolean"&&Me(e,"expected boolean")},Fs=t=>(e,n)=>{e instanceof t||Me(n,`expected instance of ${t.name||"provided class"}`)},qs=t=>(e,n,o)=>{e!==void 0&&t(e,n,o)},zs=t=>(e,n,o)=>{e!==null&&t(e,n,o)},Ks=t=>(e,n)=>{t.includes(e)||Me(n,`expected one of ${t.map(o=>Bs(o)).join(", ")}`)},Ws=t=>(e,n,o)=>{w(e)||Me(n,"expected array");let r=e;for(let s=0;s<r.length;++s)t(r[s],`${n}[${s}]`,o)},Gs=t=>(e,n,o)=>{I(e)||Me(n,"expected object");let r=e;for(let s in t){let i=t[s];i(r[s],`${n}.${s}`,o)}},Js=t=>(e,n,o)=>{x(e)||Me(n,"expected ref"),t(e(),`${n}.value`,o)},Qs={isString:js,isNumber:_s,isBoolean:$s,isClass:Fs,optional:qs,nullable:zs,oneOf:Ks,arrayOf:Ws,shape:Gs,refOf:Js};var Bn=class{constructor(){m(this,"byConstructor",new Map)}register(e){this.byConstructor.set(e.constructor,e)}unregisterByClass(e){this.byConstructor.delete(e)}unregister(e){let n=e.constructor;this.byConstructor.get(n)===e&&this.byConstructor.delete(n)}find(e){for(let n of this.byConstructor.values())if(n instanceof e)return n}require(e){let n=this.find(e);if(n)return n;throw new Error(`${e.name} is not registered in ContextRegistry.`)}};var Xs=t=>{var e;(e=Le())==null||e.onMounted.push(t)};var Ys=t=>{let e,n={},o=(...r)=>{if(r.length<=2&&0 in r)throw j(4);return e&&!n.isStopped?e(...r):(e=Zs(t,n),e(...r))};return o[Y]=1,Ne(o,!0),o.stop=()=>{var r,s;return(s=(r=n.ref)==null?void 0:r.stop)==null?void 0:s.call(r)},ne(()=>o.stop(),!0),o},Zs=(t,e)=>{var s;let n=(s=e.ref)!=null?s:ae(null);e.ref=n,e.isStopped=!1;let o=0,r=Ke(()=>{if(o>0){r(),e.isStopped=!0,Z(n);return}n(t()),++o});return n.stop=r,n};var ei=(t,e)=>{let n={},o,r=(...s)=>{if(s.length<=2&&0 in s)throw j(4);return o&&!n.isStopped?o(...s):(o=ti(t,e,n),o(...s))};return r[Y]=1,Ne(r,!0),r.stop=()=>{var s,i;return(i=(s=n.ref)==null?void 0:s.stop)==null?void 0:i.call(s)},ne(()=>r.stop(),!0),r},ti=(t,e,n)=>{var a;let o=(a=n.ref)!=null?a:ae(null);n.ref=o,n.isStopped=!1;let r=0,s=c=>{if(r>0){o.stop(),n.isStopped=!0,Z(o);return}let u=t.map(l=>l());o(e(...u)),++r},i=[];for(let c of t){let u=re(c,s);i.push(u)}return s(null),o.stop=()=>{i.forEach(c=>{c()})},o};var ni=(t,e)=>{let n={},o,r=(...s)=>{if(s.length<=2&&0 in s)throw j(4);return o&&!n.isStopped?o(...s):(o=oi(t,e,n),o(...s))};return r[Y]=1,Ne(r,!0),r.stop=()=>{var s,i;return(i=(s=n.ref)==null?void 0:s.stop)==null?void 0:i.call(s)},ne(()=>r.stop(),!0),r},oi=(t,e,n)=>{var s;let o=(s=n.ref)!=null?s:ae(null);n.ref=o,n.isStopped=!1;let r=0;return o.stop=re(t,i=>{if(r>0){o.stop(),n.isStopped=!0,Z(o);return}o(e(i)),++r},!0),o};var ri=t=>(t[St]=1,t);var si=(t,e)=>{if(!e)throw j(5);let o=ze(t)?Ce:a=>a,r=()=>localStorage.setItem(e,JSON.stringify(ce(t()))),s=localStorage.getItem(e);if(s!=null)try{t(o(JSON.parse(s)))}catch(a){U(6,`persist: failed to parse data for key ${e}`,a),r()}else r();let i=Ke(r);return ne(i,!0),t};var or=(t,...e)=>{let n="",o=t,r=e,s=o.length,i=r.length;for(let a=0;a<s;++a)n+=o[a],a<i&&(n+=r[a]);return n},ii=or;var ai=(t,e,n)=>{let o=[],r=()=>{e(t.map(i=>i()))};for(let i of t)o.push(re(i,r));n&&r();let s=()=>{for(let i of o)i()};return ne(s,!0),s};var ci=t=>{if(!x(t))throw j(3,"observerCount");return t(void 0,void 0,2)};var ui=t=>{rr();try{t()}finally{sr()}},rr=()=>{ye.stack||(ye.stack=[]),ye.stack.push(new Set)},sr=()=>{let t=ye.stack;if(!t||t.length===0)return;let e=t.pop();if(t.length){let n=t[t.length-1];for(let o of e)n.add(o);return}delete ye.stack;for(let n of e)try{Z(n)}catch(o){console.error(o)}};export{Ze as ComponentHead,Bn as ContextRegistry,de as RegorConfig,K as addUnbinder,ui as batch,hn as collectRefs,ei as computeMany,ni as computeRef,Ys as computed,Ps as createApp,Us as defineComponent,ur as drainUnbind,sr as endBatch,ot as entangle,ce as flatten,Ie as getBindData,or as html,ze as isDeepRef,rt as isRaw,x as isRef,ri as markRaw,re as observe,ai as observeMany,ci as observerCount,Xs as onMounted,ne as onUnmounted,Cn as pause,si as persist,Qs as pval,ii as raw,Ce as ref,J as removeNode,En as resume,dn as silence,ae as sref,rr as startBatch,Xe as toFragment,ct as toJsonTemplate,Z as trigger,ge as unbind,$ as unref,pn as useScope,ht as warningHandler,Ke as watchEffect};
|