regor 1.0.8 → 1.0.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/regor.d.ts CHANGED
@@ -44,13 +44,13 @@ export type RawTypes = string | Function | number | boolean | symbol | undefined
44
44
  declare const RefSymbol: unique symbol;
45
45
  declare const RawSymbol: unique symbol;
46
46
  declare const ScopeSymbol: unique symbol;
47
- export type AnyRef = (newValue?: unknown, eventSource?: unknown) => any & {
47
+ export type AnyRef = (newValue?: any, eventSource?: any) => any & {
48
48
  [RefSymbol]: true;
49
49
  };
50
- export type Ref<TValueType> = ((newValue?: RefContent<TValueType> | Ref<RefParam<TValueType>> | SRef<RefContent<TValueType>>, eventSource?: any) => RefContent<TValueType>) & AnyRef & {
50
+ export type Ref<TValueType> = ((newValue?: RefContent<TValueType> | Ref<RefParam<TValueType>> | SRef<RefContent<TValueType>>, eventSource?: any) => RefContent<TValueType>) & {
51
51
  value: RefContent<TValueType>;
52
52
  };
53
- export type SRef<TValueType> = ((newValue?: TValueType | SRef<TValueType>, eventSource?: any) => SRefContent<TValueType>) & AnyRef & {
53
+ export type SRef<TValueType> = ((newValue?: TValueType | SRef<TValueType>, eventSource?: any) => SRefContent<TValueType>) & {
54
54
  value: SRefContent<TValueType>;
55
55
  };
56
56
  export type ComputedRef<TValueType> = SRef<TValueType> & {
@@ -1,3 +1,3 @@
1
- "use strict";var jt=Object.defineProperty;var zr=Object.getOwnPropertyDescriptor;var Kr=Object.getOwnPropertyNames;var Wr=Object.prototype.hasOwnProperty;var Gr=(t,e)=>{for(var n in e)jt(t,n,{get:e[n],enumerable:!0})},Jr=(t,e,n,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of Kr(e))!Wr.call(t,o)&&o!==n&&jt(t,o,{get:()=>e[o],enumerable:!(r=zr(e,o))||r.enumerable});return t};var Qr=t=>Jr(jt({},"__esModule",{value:!0}),t);var us={};Gr(us,{ComponentHead:()=>Pe,RegorConfig:()=>re,addUnbinder:()=>k,batch:()=>Fr,collectRefs:()=>mt,computeMany:()=>Hr,computeRef:()=>_r,computed:()=>Ur,createApp:()=>Ir,createComponent:()=>Dr,endBatch:()=>vn,entangle:()=>Et,flatten:()=>J,getBindData:()=>me,html:()=>Tn,isDeepRef:()=>Ne,isRaw:()=>Be,isRef:()=>m,markRaw:()=>Br,observe:()=>C,observeMany:()=>jr,observerCount:()=>$r,onMounted:()=>qr,onUnmounted:()=>K,pause:()=>Ht,persist:()=>Vr,raw:()=>Pr,ref:()=>Te,removeNode:()=>P,resume:()=>_t,silence:()=>ut,sref:()=>z,startBatch:()=>En,toFragment:()=>Me,toJsonTemplate:()=>Ke,trigger:()=>F,unbind:()=>te,unref:()=>V,useScope:()=>Tt,warningHandler:()=>Qe,watchEffect:()=>we});module.exports=Qr(us);var U=t=>typeof t=="function",H=t=>typeof t=="string",xn=t=>typeof t>"u",Y=t=>t==null||typeof t>"u",$=t=>typeof t!="string"||!t?.trim(),Xr=Object.prototype.toString,$t=t=>Xr.call(t),ue=t=>$t(t)==="[object Map]",X=t=>$t(t)==="[object Set]",Ft=t=>$t(t)==="[object Date]",Je=t=>typeof t=="symbol",T=Array.isArray,w=t=>t!==null&&typeof t=="object";var Cn={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."},_=(t,...e)=>{let n=Cn[t];return new Error(U(n)?n.call(Cn,...e):n)};var ke=Symbol(":regor");var me=t=>{let e=t[ke];if(e)return e;let n={unbinders:[],data:{}};return t[ke]=n,n};var k=(t,e)=>{me(t).unbinders.push(e)};var ot=[],Rn=()=>{let t={onMounted:[],onUnmounted:[]};return ot.push(t),t},Re=t=>{let e=ot[ot.length-1];if(!e&&!t)throw _(2);return e},Sn=t=>{let e=Re();return t&&zt(t),ot.pop(),e},qt=Symbol("csp"),zt=t=>{let e=t,n=e[qt];if(n){let r=Re();if(n===r)return;r.onMounted.length>0&&n.onMounted.push(...r.onMounted),r.onUnmounted.length>0&&n.onUnmounted.push(...r.onUnmounted);return}e[qt]=Re()},st=t=>t[qt];var K=(t,e)=>{Re(e)?.onUnmounted.push(t)};var it=Symbol("ref"),G=Symbol("sref"),at=Symbol("raw");var m=t=>t?.[G]===1;var C=(t,e,n)=>{if(!m(t))throw _(3,"observe");n&&e(t());let o=t(void 0,void 0,0,e);return K(o,!0),o};var te=t=>{let e=[t];for(;e.length>0;){let n=e.shift();Yr(n);let r=n.childNodes;if(r)for(let o of r)e.push(o)}},Yr=t=>{let e=t[ke];if(e){for(let n of e.unbinders)n();e.unbinders.splice(0),delete t[ke]}};var P=t=>{t.remove(),setTimeout(()=>te(t),1)};var wn={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,r)=>({msg:`Failed setting prop "${t}" on <${e.toLowerCase()}>: value ${n} is invalid.`,args:[r]}),5:(t,e)=>`${t} binding missing event type at ${e.outerHTML}`,6:(t,e)=>({msg:t,args:[e]})},I=(t,...e)=>{let n=wn[t],r=U(n)?n.call(wn,...e):n,o=Qe.warning;o&&(H(r)?o(r):o(r,...r.args))},Qe={warning:console.warn};var pt={},ct={},An=1,On=t=>{let e=(An++).toString();return pt[e]=t,ct[e]=0,e},Kt=t=>{ct[t]+=1},Wt=t=>{--ct[t]===0&&(delete pt[t],delete ct[t])},Nn=t=>pt[t],Gt=()=>An!==1&&Object.keys(pt).length>0,Xe="r-switch",Zr=t=>{let e=t.filter(r=>Se(r)).map(r=>[...r.querySelectorAll("[r-switch]")].map(o=>o.getAttribute(Xe))),n=new Set;return e.forEach(r=>{r.forEach(o=>o&&n.add(o))}),[...n]},Ie=(t,e)=>{if(!Gt())return;let n=Zr(e);n.length!==0&&(n.forEach(Kt),k(t,()=>{n.forEach(Wt)}))};var Jt=(t,e,n,r)=>{let o=[];for(let s of t){let i=s.cloneNode(!0);n.insertBefore(i,r),o.push(i)}ye(e,o)},Qt=Symbol("r-if"),Mn=Symbol("r-else"),Ln=t=>t[Mn]===1,ft=class{p;P;q;K;z;b;T;constructor(e){this.p=e,this.P=e.o.l.if,this.q=He(e.o.l.if),this.K=e.o.l.else,this.z=e.o.l.elseif,this.b=e.o.l.for,this.T=e.o.l.pre}qe(e,n){let r=e.parentElement;for(;r!==null&&r!==document.documentElement;){if(r.hasAttribute(n))return!0;r=r.parentElement}return!1}N(e){let n=e.hasAttribute(this.P),r=de(e,this.q);for(let o of r)this.x(o);return n}W(e){return e[Qt]?!0:(e[Qt]=!0,de(e,this.q).forEach(n=>n[Qt]=!0),!1)}x(e){if(e.hasAttribute(this.T)||this.W(e)||this.qe(e,this.b))return;let n=e.getAttribute(this.P);if(!n){I(0,this.P,e);return}e.removeAttribute(this.P),this.k(e,n)}B(e,n,r){let o=Ue(e),s=e.parentNode,i=document.createComment(`__begin__ :${n}${r??""}`);s.insertBefore(i,e),Ie(i,o),o.forEach(c=>{P(c)}),e.remove(),n!=="if"&&(e[Mn]=1);let a=document.createComment(`__end__ :${n}${r??""}`);return s.insertBefore(a,i.nextSibling),{nodes:o,parent:s,commentBegin:i,commentEnd:a}}pe(e,n){if(!e)return[];let r=e.nextElementSibling;if(e.hasAttribute(this.K)){e.removeAttribute(this.K);let{nodes:o,parent:s,commentBegin:i,commentEnd:a}=this.B(e,"else");return[{mount:()=>{Jt(o,this.p,s,a)},unmount:()=>{ae(i,a)},isTrue:()=>!0,isMounted:!1}]}else{let o=e.getAttribute(this.z);if(!o)return[];e.removeAttribute(this.z);let{nodes:s,parent:i,commentBegin:a,commentEnd:c}=this.B(e,"elseif",` => ${o} `),f=this.p.h.v(o),p=f.value,l=this.pe(r,n),b=[];k(a,()=>{f.stop();for(let v of b)v();b.length=0});let y=C(p,n);return b.push(y),[{mount:()=>{Jt(s,this.p,i,c)},unmount:()=>{ae(a,c)},isTrue:()=>!!p()[0],isMounted:!1}].concat(l)}}k(e,n){let r=e.nextElementSibling,{nodes:o,parent:s,commentBegin:i,commentEnd:a}=this.B(e,"if",` => ${n} `),c=this.p.h.v(n),f=c.value,p=!1,l=this.p.h,b=l.V(),u=()=>{l.C(b,()=>{if(f()[0])p||(Jt(o,this.p,s,a),p=!0),y.forEach(A=>{A.unmount(),A.isMounted=!1});else{ae(i,a),p=!1;let A=!1;for(let O of y)!A&&O.isTrue()?(O.isMounted||(O.mount(),O.isMounted=!0),A=!0):(O.unmount(),O.isMounted=!1)}})},y=this.pe(r,u),v=[];k(i,()=>{c.stop();for(let A of v)A();v.length=0}),u();let h=C(f,u);v.push(h)}};var Ue=t=>{let e=ne(t)?t.content.childNodes:[t];return Array.from(e).filter(n=>{let r=n?.tagName;return r!=="SCRIPT"&&r!=="STYLE"})},ye=(t,e)=>{for(let n of e)!Ln(n)&&t.G(n)},de=(t,e)=>{let n=t.querySelectorAll(e);return t.matches?.(e)?[t,...n]:n},ne=t=>t instanceof HTMLTemplateElement,Se=t=>t.nodeType===Node.ELEMENT_NODE,Ye=t=>t.nodeType===Node.ELEMENT_NODE,kn=t=>t instanceof HTMLSlotElement,ce=t=>ne(t)?t.content.childNodes:t.childNodes,ae=(t,e)=>{let n=t.nextSibling;for(;n!=null&&n!==e;){let r=n.nextSibling;P(n),n=r}},he=(t,e)=>{Object.defineProperty(t,"value",{get(){return t()},set(n){if(e)throw new Error("value is readonly.");return t(n)},enumerable:!0,configurable:!1})},In=(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},He=t=>`[${CSS.escape(t)}]`,lt=(t,e)=>(t.startsWith("@")&&(t=e.l.on+":"+t.slice(1)),t.includes("[")&&(t=t.replace(/[[\]]/g,e.l.dynamic)),t),Xt=t=>{let e=Object.create(null);return n=>e[n]||(e[n]=t(n))},eo=/-(\w)/g,B=Xt(t=>t&&t.replace(eo,(e,n)=>n?n.toUpperCase():"")),to=/\B([A-Z])/g,_e=Xt(t=>t&&t.replace(to,"-$1").toLowerCase()),Ze=Xt(t=>t&&t.charAt(0).toUpperCase()+t.slice(1));var Z=[],Dn=t=>{Z.length!==0&&Z[Z.length-1]?.add(t)},we=t=>{if(!t)return()=>{};let e={stop:()=>{}};return no(t,e),K(()=>e.stop(),!0),e.stop},no=(t,e)=>{if(!t)return;let n=[],r=!1,o=()=>{for(let s of n)s();n=[],r=!0};e.stop=o;try{let s=new Set;if(Z.push(s),t(i=>n.push(i)),r)return;for(let i of[...s]){let a=C(i,()=>{o(),we(t)});n.push(a)}}finally{Z.pop()}},ut=t=>{let e=Z.length,n=e>0&&Z[e-1];try{return n&&Z.push(null),t()}finally{n&&Z.pop()}},mt=t=>{try{let e=new Set;return Z.push(e),{value:t(),refs:[...e]}}finally{Z.pop()}};var Be=t=>!!t&&t[at]===1;var F=(t,e,n)=>{if(!m(t))return;let r=t;if(r(void 0,e,1),!n)return;let o=r();if(o){if(T(o)||X(o))for(let s of o)F(s,e,!0);else if(ue(o))for(let s of o)F(s[0],e,!0),F(s[1],e,!0);if(w(o))for(let s in o)F(o[s],e,!0)}};function ro(t,e,n){Object.defineProperty(t,e,{value:n,enumerable:!1,writable:!0,configurable:!0})}var Ve=(t,e,n)=>{n.forEach(function(r){let o=t[r];ro(e,r,function(...i){let a=o.apply(this,i),c=this[G];for(let f of c)F(f);return a})})},dt=(t,e)=>{Object.defineProperty(t,Symbol.toStringTag,{value:e,writable:!1,enumerable:!1,configurable:!0})};var Un=Array.prototype,Yt=Object.create(Un),oo=["push","pop","shift","unshift","splice","sort","reverse"];Ve(Un,Yt,oo);var Hn=Map.prototype,yt=Object.create(Hn),so=["set","clear","delete"];dt(yt,"Map");Ve(Hn,yt,so);var _n=Set.prototype,ht=Object.create(_n),io=["add","clear","delete"];dt(ht,"Set");Ve(_n,ht,io);var Ae={},z=t=>{if(m(t)||Be(t))return t;let e={auto:!0,_value:t},n=c=>w(c)?G in c?!0:T(c)?(Object.setPrototypeOf(c,Yt),!0):X(c)?(Object.setPrototypeOf(c,ht),!0):ue(c)?(Object.setPrototypeOf(c,yt),!0):!1:!1,r=n(t),o=new Set,s=(c,f)=>{if(Ae.set){Ae.set.add(a);return}o.size!==0&&ut(()=>{for(let p of[...o.keys()])o.has(p)&&p(c,f)})},i=c=>{let f=c[G];f||(c[G]=f=new Set),f.add(a)},a=(...c)=>{if(!(2 in c)){let p=c[0],l=c[1];return 0 in c?e._value===p||m(p)&&(p=p(),e._value===p)?p:(n(p)&&i(p),e._value=p,e.auto&&s(p,l),e._value):(Dn(a),e._value)}switch(c[2]){case 0:{let p=c[3];if(!p)return()=>{};let l=b=>{o.delete(b)};return o.add(p),()=>{l(p)}}case 1:{let p=c[1],l=e._value;s(l,p);break}case 2:return o.size;case 3:{e.auto=!1;break}case 4:e.auto=!0}return e._value};return a[G]=1,he(a,!1),r&&i(t),a};var V=t=>m(t)?t():t;var et=class{E=[];_=new Map;get S(){return this.E.length}J;constructor(e){this.J=e}Q(e){let n=this.J(e.value);n&&this._.set(n,e)}X(e){let n=this.J(this.E[e]?.value);n&&this._.delete(n)}static Ke(e,n){return{items:[],index:e,value:n,order:-1}}w(e){e.order=this.S,this.E.push(e),this.Q(e)}ze(e,n){let r=this.S;for(let o=e;o<r;++o)this.E[o].order=o+1;n.order=e,this.E.splice(e,0,n),this.Q(n)}I(e){return this.E[e]}Y(e,n){this.X(e),this.E[e]=n,this.Q(n),n.order=e}ce(e){this.X(e),this.E.splice(e,1);let n=this.S;for(let r=e;r<n;++r)this.E[r].order=r}le(e){let n=this.S;for(let r=e;r<n;++r)this.X(r);this.E.splice(e)}Rt(e){return this._.has(e)}We(e){return this._.get(e)?.order??-1}};var Zt=Symbol("r-for"),gt=class t{p;b;Z;T;constructor(e){this.p=e,this.b=e.o.l.for,this.Z=He(this.b),this.T=e.o.l.pre}N(e){let n=e.hasAttribute(this.b),r=de(e,this.Z);for(let o of r)this.Ge(o);return n}W(e){return e[Zt]?!0:(e[Zt]=!0,de(e,this.Z).forEach(n=>n[Zt]=!0),!1)}Ge(e){if(e.hasAttribute(this.T)||this.W(e))return;let n=e.getAttribute(this.b);if(!n){I(0,this.b,e);return}e.removeAttribute(this.b),this.Je(e,n)}fe(e){return Y(e)?[]:(U(e)&&(e=e()),Symbol.iterator in Object(e)?e:typeof e=="number"?(r=>({*[Symbol.iterator](){for(let o=1;o<=r;o++)yield o}}))(e):Object.entries(e))}Je(e,n){let r=this.Qe(n);if(!r?.list){I(1,this.b,n,e);return}let o=this.p.o.l.key,s=this.p.o.l.keyBind,i=e.getAttribute(o)??e.getAttribute(s);e.removeAttribute(o),e.removeAttribute(s);let a=i?x=>V(V(x)?.[i]):x=>x,c=(x,N)=>a(x)===a(N),f=Ue(e),p=e.parentNode;if(!p)return;let l=`${this.b} => ${n}`,b=new Comment(`__begin__ ${l}`);p.insertBefore(b,e),Ie(b,f),f.forEach(x=>{P(x)}),e.remove();let u=new Comment(`__end__ ${l}`);p.insertBefore(u,b.nextSibling);let y=this.p,v=y.h,S=v.V(),h=(x,N,q)=>{let R=r.createContext(N,x),Q=et.Ke(R.index,N);return v.C(S,()=>{v.w(R.ctx);let ee=q.previousSibling,Le=[];for(let d of f){let M=d.cloneNode(!0);p.insertBefore(M,q),Le.push(M)}for(ye(y,Le),ee=ee.nextSibling;ee!==q;)Q.items.push(ee),ee=ee.nextSibling}),Q},A=(x,N)=>{let q=L.I(x).items,R=q[q.length-1].nextSibling;for(let Q of q)P(Q);L.Y(x,h(x,N,R))},O=(x,N)=>{L.w(h(x,N,u))},Ee=x=>{for(let N of L.I(x).items)P(N)},We=x=>{let N=L.S;for(let q=x;q<N;++q)L.I(q).index(q)},Vt=x=>{let N=L.S;U(x)&&(x=x());let q=V(x[0]);if(T(q)&&q.length===0){ae(b,u),L.le(0);return}let R=0,Q=Number.MAX_SAFE_INTEGER,ee=N,Le=this.p.o.forGrowThreshold,d=()=>L.S<ee+Le;for(let g of this.fe(x[0])){let D=()=>{if(R<N){let W=L.I(R++);if(c(W.value,g))return;let E=L.We(a(g));if(E>=R&&E-R<10){if(--R,Q=Math.min(Q,R),Ee(R),L.ce(R),--N,E>R+1)for(let j=R;j<E-1&&j<N&&!c(L.I(R).value,g);)++j,Ee(R),L.ce(R),--N;D();return}d()?(L.ze(R-1,h(R,g,L.I(R-1).items[0])),Q=Math.min(Q,R-1),++N):A(R-1,g)}else O(R++,g)};D()}let M=R;for(N=L.S;R<N;)Ee(R++);L.le(M),We(Q)},nt=()=>{Ge=C(le,Vt)},ve=()=>{rt.stop(),Ge()},rt=v.v(r.list),le=rt.value,Ge,oe=0,L=new et(a);for(let x of this.fe(le()[0]))L.w(h(oe++,x,u));k(b,ve),nt()}static Xe=/\{?\[?\(?([^)}\]]+)\)?\]?\}?([^)]+)?\s+\b(?:in|of)\b\s+([^\s]+)\s*/;Qe(e){let n=t.Xe.exec(e);if(!n)return;let r=(n[1]+(n[2]??"")).split(",").map(c=>c.trim()),o=r.length>1?r.length-1:-1,s=o!==-1&&(r[o]==="index"||r[o]?.startsWith("#"))?r[o]:"";s&&r.splice(o,1);let i=n[3];if(!i||r.length===0)return;let a=/[{[]/.test(e);return{list:i,createContext:(c,f)=>{let p={},l=V(c);if(!a&&r.length===1)p[r[0]]=c;else if(T(l)){let u=0;for(let y of r)p[y]=l[u++]}else for(let u of r)p[u]=l[u];let b={ctx:p,index:z(-1)};return s&&(b.index=p[s.startsWith("#")?s.substring(1):s]=z(f)),b}}}};var ao=(t,e)=>{for(let n of t){let r=n.cloneNode(!0);e.appendChild(r)}},bt=class{p;D;ue;constructor(e){this.p=e,this.D=e.o.l.is,this.ue=He(this.D)+", [is]"}N(e){let n=e.hasAttribute(this.D),r=de(e,this.ue);for(let o of r)this.x(o);return n}x(e){let n=e.getAttribute(this.D);if(!n){if(n=e.getAttribute("is"),!n||!n.startsWith("regor:"))return;n=`'${n.slice(6)}'`,e.removeAttribute("is")}e.removeAttribute(this.D),this.k(e,n)}B(e,n){let r=Ue(e),o=e.parentNode,s=document.createComment(`__begin__ dynamic ${n??""}`);o.insertBefore(s,e),Ie(s,r),r.forEach(a=>{P(a)}),e.remove();let i=document.createComment(`__end__ dynamic ${n??""}`);return o.insertBefore(i,s.nextSibling),{nodes:r,parent:o,commentBegin:s,commentEnd:i}}k(e,n){let{nodes:r,parent:o,commentBegin:s,commentEnd:i}=this.B(e,` => ${n} `),a=this.p.h.v(n),c=a.value,f=this.p.h,p=f.V(),l={name:""},b=ne(e)?r:[...r[0].childNodes],u=()=>{f.C(p,()=>{let h=c()[0];if(w(h)&&(h.name?h=h.name:h=Object.entries(f.me()).filter(O=>O[1]===h)[0]?.[0]),!H(h)||$(h)){ae(s,i);return}if(l.name===h)return;ae(s,i);let A=document.createElement(h);for(let O of e.getAttributeNames())O!==this.D&&A.setAttribute(O,e.getAttribute(O));ao(b,A),o.insertBefore(A,i),this.p.G(A),l.name=h})},y=[];k(s,()=>{a.stop();for(let h of y)h();y.length=0}),u();let S=C(c,u);y.push(S)}};var Bn={collectRefObj:!0,onBind:(t,e)=>C(e.value,()=>{let r=e.value(),o=e.context,s=r[0];if(w(s))for(let i of Object.entries(s)){let a=i[0],c=i[1],f=o[a];f!==c&&(m(f)?f(c):o[a]=c)}},!0)};var Vn={collectRefObj:!0,once:!0,onBind:(t,e)=>{let n=e.value(),r=e.context,o=n[0];if(!w(o))return()=>{};for(let s of Object.entries(o)){let i=s[0],a=s[1],c=r[i];c!==a&&(m(c)?c(a):r[i]=a)}return()=>{}}};var ge=t=>{st(t)?.onUnmounted?.forEach(n=>{n()}),t.unmounted?.()};var Pe=class{props;start;end;ctx;autoProps=!0;entangle=!0;disableSwitch=!1;onAutoPropsAssigned;de;constructor(e,n,r,o,s){this.props=e,this.de=n,this.ctx=r,this.start=o,this.end=s}emit=(e,n)=>{this.de.dispatchEvent(new CustomEvent(e,{detail:n}))};unmount(){let e=this.start.nextSibling,n=this.end;for(;e&&e!==n;)P(e),e=e.nextSibling;ge(this)}};var en=Symbol("scope"),Tt=t=>{try{Rn();let e=t();zt(e);let n={context:e,unmount:()=>ge(e),[en]:1};return n[en]=1,n}finally{Sn()}},Pn=t=>w(t)?en in t:!1;var Et=(t,e)=>{if(t===e)return()=>{};let n=C(t,o=>e(o)),r=C(e,o=>t(o));return e(t()),()=>{n(),r()}};var vt=t=>{st(t)?.onMounted?.forEach(n=>{n()}),t.mounted?.()};var jn={collectRefObj:!0,onBind:(t,e,n,r,o,s)=>{if(!r)return()=>{};let i=B(r);return C(e.value,()=>{let c=e.refs[0]??e.value()[0],f=e.context,p=f[r];p!==c&&(m(p)?p(c):f[i]=c)},!0)}};var xt=class{p;ye;constructor(e){this.p=e,this.ye=e.o.l.inherit}N(e){this.Ye(e)}Ye(e){let n=this.p,r=n.h,o=n.o.he,s=n.o.ge,i=r.me(),a=[...o.keys(),...Object.keys(i),...[...o.keys()].map(_e),...[...Object.keys(i)].map(_e)].join(",");if($(a))return;let c=e.querySelectorAll(a),f=e.matches?.(a)?[e,...c]:c;for(let p of f){if(p.hasAttribute(n.T))continue;let l=p.parentNode;if(!l)continue;let b=p.nextSibling,u=B(p.tagName).toUpperCase(),v=i[u]??s.get(u);if(!v)continue;let S=v.template;if(!S)continue;let h=p.parentElement;if(!h)continue;let A=new Comment(" begin component: "+p.tagName),O=new Comment(" end component: "+p.tagName);h.insertBefore(A,p),p.remove();let Ee=n.o.l.props,We=n.o.l.propsOnce,Vt=n.o.l.bind,nt=(d,M)=>{let g={},D=d.hasAttribute(Ee),W=d.hasAttribute(We);return r.C(M,()=>{r.w(g),D&&n.x(Bn,d,Ee),W&&n.x(Vn,d,We);let E=v.props;if(!E||E.length===0)return;E=E.map(B);for(let xe of E.concat(E.map(_e))){let se=d.getAttribute(xe);se!==null&&(g[B(xe)]=se,d.removeAttribute(xe))}let j=n.ee.be(d,!1);for(let[xe,se]of j.entries()){let[Ce,Pt]=se.te;Pt&&E.includes(B(Pt))&&(Ce!=="."&&Ce!==":"&&Ce!==Vt||n.x(jn,d,xe,!0,Pt,se.ne))}}),g},ve=[...r.V()],rt=()=>{let d=nt(p,ve),M=new Pe(d,p,ve,A,O),g=Tt(()=>v.context(M)??{}).context;if(M.autoProps){for(let[D,W]of Object.entries(d))if(D in g){let E=g[D];if(E===W)continue;M.entangle&&m(E)&&m(W)?k(A,Et(W,E)):m(E)?E(W):g[D]=V(W)}else g[D]=W;M.onAutoPropsAssigned?.()}return{componentCtx:g,head:M}},{componentCtx:le,head:Ge}=rt(),oe=[...ce(S)],L=oe.length,x=p.childNodes.length===0,N=d=>{let M=d.parentElement;if(x){for(let E of[...d.childNodes])M.insertBefore(E,d);return}let g=d.name;$(g)&&(g=d.getAttributeNames().filter(E=>E.startsWith("#"))[0],$(g)?g="default":g=g.substring(1));let D=p.querySelector(`template[name='${g}'], template[\\#${g}]`);!D&&g==="default"&&(D=p.querySelector("template:not([name])"),D&&D.getAttributeNames().filter(E=>E.startsWith("#")).length>0&&(D=null));let W=E=>{Ge.disableSwitch||r.C(ve,()=>{r.w(le);let j=nt(d,r.V());r.C(ve,()=>{r.w(j);let xe=r.V(),se=On(xe);for(let Ce of E)Se(Ce)&&(Ce.setAttribute(Xe,se),Kt(se),k(Ce,()=>{Wt(se)}))})})};if(D){let E=[...ce(D)];for(let j of E)M.insertBefore(j,d);W(E)}else{if(g!=="default"){for(let j of[...ce(d)])M.insertBefore(j,d);return}let E=[...ce(p)].filter(j=>!ne(j));for(let j of E)M.insertBefore(j,d);W(E)}},q=d=>{if(!Se(d))return;let M=d.querySelectorAll("slot");if(kn(d)){N(d),d.remove();return}for(let g of M)N(g),g.remove()};(()=>{for(let d=0;d<L;++d)oe[d]=oe[d].cloneNode(!0),l.insertBefore(oe[d],b),q(oe[d])})(),h.insertBefore(O,b);let Q=()=>{if(!v.inheritAttrs)return;let d=oe.filter(g=>g.nodeType===Node.ELEMENT_NODE);d.length>1&&(d=d.filter(g=>g.hasAttribute(this.ye)));let M=d[0];if(M)for(let g of p.getAttributeNames()){if(g===Ee||g===We)continue;let D=p.getAttribute(g);if(g==="class")M.classList.add(...D.split(" "));else if(g==="style"){let W=M.style,E=p.style;for(let j of E)W.setProperty(j,E.getPropertyValue(j))}else M.setAttribute(lt(g,n.o),D)}},ee=()=>{for(let d of p.getAttributeNames())!d.startsWith("@")&&!d.startsWith(n.o.l.on)&&p.removeAttribute(d)},Le=()=>{Q(),ee(),r.w(le),n.Te(p,!1),le.$emit=Ge.emit,ye(n,oe),k(p,()=>{ge(le)}),k(A,()=>{te(p)}),vt(le)};r.C(ve,Le)}}};var tn=class{xe;te=[];ne=[];Ee=[];constructor(e){this.xe=e,this.v()}v(){let e=this.xe,n=e.startsWith(".");n&&(e=":"+e.slice(1));let r=e.indexOf("."),o=this.te=(r<0?e:e.substring(0,r)).split(/[:@]/);if($(o[0])&&(o[0]=n?".":e[0]),r>=0){let s=this.ne=e.slice(r+1).split(".");if(s.includes("camel")){let i=o.length-1;o[i]=B(o[i])}s.includes("prop")&&(o[0]=".")}}},Ct=class{p;Re;constructor(e){this.p=e,this.Re=e.o.Ze()}be(e,n){let r=new Map;if(!Ye(e))return r;let o=this.Re,s=a=>{let c=a.getAttributeNames().filter(f=>o.some(p=>f.startsWith(p)));for(let f of c)r.has(f)||r.set(f,new tn(f)),r.get(f).Ee.push(a)};if(s(e),!n)return r;let i=e.querySelectorAll("*");for(let a of i)s(a);return r}};var Rt={};var St=class{h;ve;Ce;Se;we;ee;o;T;Ae;constructor(e){this.h=e,this.o=e.o,this.Ce=new gt(this),this.ve=new ft(this),this.Se=new bt(this),this.we=new xt(this),this.ee=new Ct(this),this.T=this.o.l.pre,this.Ae=this.o.l.dynamic}et(e){let n=ne(e)?[e]:e.querySelectorAll("template");for(let r of n){if(r.hasAttribute(this.T))continue;let o=r.parentNode;if(!o)continue;let s=r.nextSibling;if(r.remove(),!r.content)continue;let i=[...r.content.childNodes];for(let a of i)o.insertBefore(a,s);ye(this,i)}}G(e){e.nodeType!==Node.ELEMENT_NODE||e.hasAttribute(this.T)||this.ve.N(e)||this.Ce.N(e)||this.Se.N(e)||(this.we.N(e),this.et(e),this.Te(e,!0))}Te(e,n){let r=this.ee.be(e,n),o=this.o.H;for(let[s,i]of r.entries()){let[a,c]=i.te,f=o[s]??o[a];if(!f){console.error("directive not found:",a);continue}i.Ee.forEach(p=>{this.x(f,p,s,!1,c,i.ne)})}}x(e,n,r,o,s,i){if(n.hasAttribute(this.T))return;let a=n.getAttribute(r);n.removeAttribute(r);let c=f=>{let p=f.getAttribute(Xe);return p||(f.parentElement?c(f.parentElement):null)};if(Gt()){let f=c(n);if(f){this.h.C(Nn(f),()=>{this.k(e,n,a,s,i)});return}}this.k(e,n,a,s,i)}tt(e,n,r){if(e!==Rt)return!1;if($(r))return!0;let o=document.querySelector(r);if(o){let s=n.parentElement;if(!s)return!0;let i=new Comment(`teleported => '${r}'`);s.insertBefore(i,n),n.teleportedFrom=i,i.teleportedTo=n,k(i,()=>{P(n)}),o.appendChild(n)}return!0}k(e,n,r,o,s){if(n.nodeType!==Node.ELEMENT_NODE||r==null||this.tt(e,n,r))return;let i=this.h.v(r,e.isLazy,e.isLazyKey,e.collectRefObj,e.once),a=[];k(n,()=>{i.stop(),p?.stop();for(let S of a)S();a.length=0});let f=In(o,this.Ae),p;f&&(p=this.h.v(B(f),void 0,void 0,void 0,e.once));let l,b=()=>(l=i.value(),l),u,y=()=>p?(u=p.value()[0],u):(u=o,o),v=()=>{if(!e.onChange)return;let S=C(i.value,h=>{let A=l,O=u;e.onChange?.(n,b(),A,y(),O,s)});if(a.push(S),p){let h=C(p.value,A=>{let O=u;e.onChange?.(n,b(),O,y(),O,s)});a.push(h)}};e.once||v(),e.onBind&&a.push(e.onBind(n,i,r,o,p,s)),e.onChange?.(n,b(),void 0,y(),void 0,s)}};var co=9,po=10,fo=13,lo=32,be=46,wt=44,uo=39,mo=34,At=40,je=41,Ot=91,Nt=93,nn=63,yo=59,$n=58,ho=123,Mt=125,on=43,go=45,Fn=96,qn=47,bo=92,zn=[2,3],Kn=[on,go],Yn={"-":1,"!":1,"~":1,"+":1,new:1},Zn={"=":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},Fe={"=>":2,...Zn,"||":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},er=Object.keys(Zn),To=new Set(er),Lt=new Set;Lt.add("=>");er.forEach(t=>Lt.add(t));var Eo=new Set(["$","_"]),Wn={true:!0,false:!1,null:null},vo="this";function tr(t){return Math.max(0,...Object.keys(t).map(e=>e.length))}var xo=tr(Yn),Co=tr(Fe),qe="Expected ",Oe="Unexpected ",an="Unclosed ",Ro=qe+":",Gn=qe+"expression",So="missing }",wo=Oe+"object property",Ao=an+"(",Jn=qe+"comma",Qn=Oe+"token ",Oo=Oe+"period",rn=qe+"expression after ",No="missing unaryOp argument",Mo=an+"[",Lo=qe+"exponent (",ko="Variable names cannot start with a number (",Io=an+'quote after "';var $e=t=>t>=48&&t<=57,Xn=t=>Fe[t]||0,sn=class{nt={0:[this.rt],1:[this.ot,this.st,this.it],2:[this.at,this.pt,this.ct,this.Oe,this.lt],3:[this.ft,this.ut,this.mt]};r;e;get M(){return this.r.charAt(this.e)}get f(){return this.r.charCodeAt(this.e)}u(e){return this.r.charCodeAt(this.e)===e}constructor(e){this.r=e,this.e=0}U(e){let n=String.fromCharCode(e);return e>=65&&e<=90||e>=97&&e<=122||e>=128&&!(n in Fe)||Eo.has(n)}re(e){return this.U(e)||$e(e)}i(e){return new Error(`${e} at character ${this.e}`)}L(e,n,r){let o=this.nt[e];if(!o)return r;let s={node:r},i=a=>{a.call(this,s)};return n===0?o.forEach(i):o.find(i),s.node}y(){let e=this.f,n=this.r,r=this.e;for(;e===lo||e===co||e===po||e===fo;)e=n.charCodeAt(++r);this.e=r}parse(){let e=this.oe();return e.length===1?e[0]:{type:0,body:e}}oe(e){let n=[];for(;this.e<this.r.length;){let r=this.f;if(r===yo||r===wt)this.e++;else{let o=this.A();if(o)n.push(o);else if(this.e<this.r.length){if(r===e)break;throw this.i(Oe+'"'+this.M+'"')}}}return n}A(){let e=this.L(0,1)??this.Ne();return this.y(),this.L(1,0,e)}se(){this.y();let e=this.e,n=this.r,r=n.substr(e,Co),o=r.length;for(;o>0;){if(r in Fe&&(!this.U(this.f)||e+r.length<n.length&&!this.re(n.charCodeAt(e+r.length))))return e+=o,this.e=e,r;r=r.substr(0,--o)}return!1}Ne(){let e,n,r,o,s,i,a,c;if(s=this.j(),!s||(n=this.se(),!n))return s;if(o={value:n,prec:Xn(n),right_a:Lt.has(n)},i=this.j(),!i)throw this.i(rn+n);let f=[s,o,i];for(;n=this.se();){if(r=Xn(n),r===0){this.e-=n.length;break}o={value:n,prec:r,right_a:Lt.has(n)},c=n;let p=l=>o.right_a&&l.right_a?r>l.prec:r<=l.prec;for(;f.length>2&&p(f[f.length-2]);)i=f.pop(),n=f.pop().value,s=f.pop(),e={type:8,operator:n,left:s,right:i},f.push(e);if(e=this.j(),!e)throw this.i(rn+c);f.push(o,e)}for(a=f.length-1,e=f[a];a>1;)e={type:8,operator:f[a-1].value,left:f[a-2],right:e},a-=2;return e}j(){let e,n,r;if(this.y(),r=this.L(2,1),r)return this.L(3,0,r);let o=this.f;if($e(o)||o===be)return this.dt();if(o===uo||o===mo)r=this.yt();else if(o===Ot)r=this.ht();else{for(e=this.r.substr(this.e,xo),n=e.length;n>0;){if(Object.prototype.hasOwnProperty.call(Yn,e)&&(!this.U(this.f)||this.e+e.length<this.r.length&&!this.re(this.r.charCodeAt(this.e+e.length)))){this.e+=n;let s=this.j();if(!s)throw this.i(No);return this.L(3,0,{type:7,operator:e,argument:s})}e=e.substr(0,--n)}this.U(o)?(r=this.ie(),r.name in Wn?r={type:4,value:Wn[r.name],raw:r.name}:r.name===vo&&(r={type:5})):o===At&&(r=this.gt())}return r?(r=this.F(r),this.L(3,0,r)):this.L(3,0,!1)}F(e){this.y();let n=this.f;for(;n===be||n===Ot||n===At||n===nn;){let r;if(n===nn){if(this.r.charCodeAt(this.e+1)!==be)break;r=!0,this.e+=2,this.y(),n=this.f}if(this.e++,n===Ot){if(e={type:3,computed:!0,object:e,property:this.A()},this.y(),n=this.f,n!==Nt)throw this.i(Mo);this.e++}else n===At?e={type:6,arguments:this.Me(je),callee:e}:(n===be||r)&&(r&&this.e--,this.y(),e={type:3,computed:!1,object:e,property:this.ie()});r&&(e.optional=!0),this.y(),n=this.f}return e}dt(){let e="",n;for(;$e(this.f);)e+=this.r.charAt(this.e++);if(this.u(be))for(e+=this.r.charAt(this.e++);$e(this.f);)e+=this.r.charAt(this.e++);if(n=this.M,n==="e"||n==="E"){for(e+=this.r.charAt(this.e++),n=this.M,(n==="+"||n==="-")&&(e+=this.r.charAt(this.e++));$e(this.f);)e+=this.r.charAt(this.e++);if(!$e(this.r.charCodeAt(this.e-1)))throw this.i(Lo+e+this.M+")")}let r=this.f;if(this.U(r))throw this.i(ko+e+this.M+")");if(r===be||e.length===1&&e.charCodeAt(0)===be)throw this.i(Oo);return{type:4,value:parseFloat(e),raw:e}}yt(){let e="",n=this.e,r=this.r.charAt(this.e++),o=!1;for(;this.e<this.r.length;){let s=this.r.charAt(this.e++);if(s===r){o=!0;break}else if(s==="\\")switch(s=this.r.charAt(this.e++),s){case"n":e+=`
1
+ "use strict";var jt=Object.defineProperty;var zr=Object.getOwnPropertyDescriptor;var Kr=Object.getOwnPropertyNames;var Wr=Object.prototype.hasOwnProperty;var Gr=(t,e)=>{for(var n in e)jt(t,n,{get:e[n],enumerable:!0})},Jr=(t,e,n,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of Kr(e))!Wr.call(t,o)&&o!==n&&jt(t,o,{get:()=>e[o],enumerable:!(r=zr(e,o))||r.enumerable});return t};var Qr=t=>Jr(jt({},"__esModule",{value:!0}),t);var us={};Gr(us,{ComponentHead:()=>Pe,RegorConfig:()=>re,addUnbinder:()=>k,batch:()=>Fr,collectRefs:()=>mt,computeMany:()=>Hr,computeRef:()=>_r,computed:()=>Ur,createApp:()=>Ir,createComponent:()=>Dr,endBatch:()=>vn,entangle:()=>Et,flatten:()=>J,getBindData:()=>me,html:()=>Tn,isDeepRef:()=>Ne,isRaw:()=>Be,isRef:()=>m,markRaw:()=>Br,observe:()=>C,observeMany:()=>jr,observerCount:()=>$r,onMounted:()=>qr,onUnmounted:()=>K,pause:()=>Ht,persist:()=>Vr,raw:()=>Pr,ref:()=>Te,removeNode:()=>P,resume:()=>_t,silence:()=>ut,sref:()=>z,startBatch:()=>En,toFragment:()=>Me,toJsonTemplate:()=>Ke,trigger:()=>F,unbind:()=>te,unref:()=>V,useScope:()=>Tt,warningHandler:()=>Qe,watchEffect:()=>we});module.exports=Qr(us);var U=t=>typeof t=="function",H=t=>typeof t=="string",xn=t=>typeof t>"u",Y=t=>t==null||typeof t>"u",$=t=>typeof t!="string"||!t?.trim(),Xr=Object.prototype.toString,$t=t=>Xr.call(t),ue=t=>$t(t)==="[object Map]",X=t=>$t(t)==="[object Set]",Ft=t=>$t(t)==="[object Date]",Je=t=>typeof t=="symbol",T=Array.isArray,w=t=>t!==null&&typeof t=="object";var Cn={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."},_=(t,...e)=>{let n=Cn[t];return new Error(U(n)?n.call(Cn,...e):n)};var ke=Symbol(":regor");var me=t=>{let e=t[ke];if(e)return e;let n={unbinders:[],data:{}};return t[ke]=n,n};var k=(t,e)=>{me(t).unbinders.push(e)};var ot=[],Rn=()=>{let t={onMounted:[],onUnmounted:[]};return ot.push(t),t},Re=t=>{let e=ot[ot.length-1];if(!e&&!t)throw _(2);return e},Sn=t=>{let e=Re();return t&&zt(t),ot.pop(),e},qt=Symbol("csp"),zt=t=>{let e=t,n=e[qt];if(n){let r=Re();if(n===r)return;r.onMounted.length>0&&n.onMounted.push(...r.onMounted),r.onUnmounted.length>0&&n.onUnmounted.push(...r.onUnmounted);return}e[qt]=Re()},st=t=>t[qt];var K=(t,e)=>{Re(e)?.onUnmounted.push(t)};var it=Symbol("ref"),G=Symbol("sref"),at=Symbol("raw");var m=t=>t?.[G]===1;var C=(t,e,n)=>{if(!m(t))throw _(3,"observe");n&&e(t());let o=t(void 0,void 0,0,e);return K(o,!0),o};var te=t=>{let e=[t];for(;e.length>0;){let n=e.shift();Yr(n);let r=n.childNodes;if(r)for(let o of r)e.push(o)}},Yr=t=>{let e=t[ke];if(e){for(let n of e.unbinders)n();e.unbinders.splice(0),delete t[ke]}};var P=t=>{t.remove(),setTimeout(()=>te(t),1)};var wn={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,r)=>({msg:`Failed setting prop "${t}" on <${e.toLowerCase()}>: value ${n} is invalid.`,args:[r]}),5:(t,e)=>`${t} binding missing event type at ${e.outerHTML}`,6:(t,e)=>({msg:t,args:[e]})},I=(t,...e)=>{let n=wn[t],r=U(n)?n.call(wn,...e):n,o=Qe.warning;o&&(H(r)?o(r):o(r,...r.args))},Qe={warning:console.warn};var pt={},ct={},An=1,On=t=>{let e=(An++).toString();return pt[e]=t,ct[e]=0,e},Kt=t=>{ct[t]+=1},Wt=t=>{--ct[t]===0&&(delete pt[t],delete ct[t])},Nn=t=>pt[t],Gt=()=>An!==1&&Object.keys(pt).length>0,Xe="r-switch",Zr=t=>{let e=t.filter(r=>Se(r)).map(r=>[...r.querySelectorAll("[r-switch]")].map(o=>o.getAttribute(Xe))),n=new Set;return e.forEach(r=>{r.forEach(o=>o&&n.add(o))}),[...n]},Ie=(t,e)=>{if(!Gt())return;let n=Zr(e);n.length!==0&&(n.forEach(Kt),k(t,()=>{n.forEach(Wt)}))};var Jt=(t,e,n,r)=>{let o=[];for(let s of t){let i=s.cloneNode(!0);n.insertBefore(i,r),o.push(i)}ye(e,o)},Qt=Symbol("r-if"),Mn=Symbol("r-else"),Ln=t=>t[Mn]===1,ft=class{p;P;q;K;z;b;T;constructor(e){this.p=e,this.P=e.o.l.if,this.q=He(e.o.l.if),this.K=e.o.l.else,this.z=e.o.l.elseif,this.b=e.o.l.for,this.T=e.o.l.pre}qe(e,n){let r=e.parentElement;for(;r!==null&&r!==document.documentElement;){if(r.hasAttribute(n))return!0;r=r.parentElement}return!1}N(e){let n=e.hasAttribute(this.P),r=de(e,this.q);for(let o of r)this.x(o);return n}W(e){return e[Qt]?!0:(e[Qt]=!0,de(e,this.q).forEach(n=>n[Qt]=!0),!1)}x(e){if(e.hasAttribute(this.T)||this.W(e)||this.qe(e,this.b))return;let n=e.getAttribute(this.P);if(!n){I(0,this.P,e);return}e.removeAttribute(this.P),this.V(e,n)}B(e,n,r){let o=Ue(e),s=e.parentNode,i=document.createComment(`__begin__ :${n}${r??""}`);s.insertBefore(i,e),Ie(i,o),o.forEach(c=>{P(c)}),e.remove(),n!=="if"&&(e[Mn]=1);let a=document.createComment(`__end__ :${n}${r??""}`);return s.insertBefore(a,i.nextSibling),{nodes:o,parent:s,commentBegin:i,commentEnd:a}}pe(e,n){if(!e)return[];let r=e.nextElementSibling;if(e.hasAttribute(this.K)){e.removeAttribute(this.K);let{nodes:o,parent:s,commentBegin:i,commentEnd:a}=this.B(e,"else");return[{mount:()=>{Jt(o,this.p,s,a)},unmount:()=>{ae(i,a)},isTrue:()=>!0,isMounted:!1}]}else{let o=e.getAttribute(this.z);if(!o)return[];e.removeAttribute(this.z);let{nodes:s,parent:i,commentBegin:a,commentEnd:c}=this.B(e,"elseif",` => ${o} `),f=this.p.h.v(o),p=f.value,l=this.pe(r,n),b=[];k(a,()=>{f.stop();for(let v of b)v();b.length=0});let y=C(p,n);return b.push(y),[{mount:()=>{Jt(s,this.p,i,c)},unmount:()=>{ae(a,c)},isTrue:()=>!!p()[0],isMounted:!1}].concat(l)}}V(e,n){let r=e.nextElementSibling,{nodes:o,parent:s,commentBegin:i,commentEnd:a}=this.B(e,"if",` => ${n} `),c=this.p.h.v(n),f=c.value,p=!1,l=this.p.h,b=l.k(),u=()=>{l.C(b,()=>{if(f()[0])p||(Jt(o,this.p,s,a),p=!0),y.forEach(A=>{A.unmount(),A.isMounted=!1});else{ae(i,a),p=!1;let A=!1;for(let O of y)!A&&O.isTrue()?(O.isMounted||(O.mount(),O.isMounted=!0),A=!0):(O.unmount(),O.isMounted=!1)}})},y=this.pe(r,u),v=[];k(i,()=>{c.stop();for(let A of v)A();v.length=0}),u();let h=C(f,u);v.push(h)}};var Ue=t=>{let e=ne(t)?t.content.childNodes:[t];return Array.from(e).filter(n=>{let r=n?.tagName;return r!=="SCRIPT"&&r!=="STYLE"})},ye=(t,e)=>{for(let n of e)!Ln(n)&&t.G(n)},de=(t,e)=>{let n=t.querySelectorAll(e);return t.matches?.(e)?[t,...n]:n},ne=t=>t instanceof HTMLTemplateElement,Se=t=>t.nodeType===Node.ELEMENT_NODE,Ye=t=>t.nodeType===Node.ELEMENT_NODE,kn=t=>t instanceof HTMLSlotElement,ce=t=>ne(t)?t.content.childNodes:t.childNodes,ae=(t,e)=>{let n=t.nextSibling;for(;n!=null&&n!==e;){let r=n.nextSibling;P(n),n=r}},he=(t,e)=>{Object.defineProperty(t,"value",{get(){return t()},set(n){if(e)throw new Error("value is readonly.");return t(n)},enumerable:!0,configurable:!1})},In=(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},He=t=>`[${CSS.escape(t)}]`,lt=(t,e)=>(t.startsWith("@")&&(t=e.l.on+":"+t.slice(1)),t.includes("[")&&(t=t.replace(/[[\]]/g,e.l.dynamic)),t),Xt=t=>{let e=Object.create(null);return n=>e[n]||(e[n]=t(n))},eo=/-(\w)/g,B=Xt(t=>t&&t.replace(eo,(e,n)=>n?n.toUpperCase():"")),to=/\B([A-Z])/g,_e=Xt(t=>t&&t.replace(to,"-$1").toLowerCase()),Ze=Xt(t=>t&&t.charAt(0).toUpperCase()+t.slice(1));var Z=[],Dn=t=>{Z.length!==0&&Z[Z.length-1]?.add(t)},we=t=>{if(!t)return()=>{};let e={stop:()=>{}};return no(t,e),K(()=>e.stop(),!0),e.stop},no=(t,e)=>{if(!t)return;let n=[],r=!1,o=()=>{for(let s of n)s();n=[],r=!0};e.stop=o;try{let s=new Set;if(Z.push(s),t(i=>n.push(i)),r)return;for(let i of[...s]){let a=C(i,()=>{o(),we(t)});n.push(a)}}finally{Z.pop()}},ut=t=>{let e=Z.length,n=e>0&&Z[e-1];try{return n&&Z.push(null),t()}finally{n&&Z.pop()}},mt=t=>{try{let e=new Set;return Z.push(e),{value:t(),refs:[...e]}}finally{Z.pop()}};var Be=t=>!!t&&t[at]===1;var F=(t,e,n)=>{if(!m(t))return;let r=t;if(r(void 0,e,1),!n)return;let o=r();if(o){if(T(o)||X(o))for(let s of o)F(s,e,!0);else if(ue(o))for(let s of o)F(s[0],e,!0),F(s[1],e,!0);if(w(o))for(let s in o)F(o[s],e,!0)}};function ro(t,e,n){Object.defineProperty(t,e,{value:n,enumerable:!1,writable:!0,configurable:!0})}var Ve=(t,e,n)=>{n.forEach(function(r){let o=t[r];ro(e,r,function(...i){let a=o.apply(this,i),c=this[G];for(let f of c)F(f);return a})})},dt=(t,e)=>{Object.defineProperty(t,Symbol.toStringTag,{value:e,writable:!1,enumerable:!1,configurable:!0})};var Un=Array.prototype,Yt=Object.create(Un),oo=["push","pop","shift","unshift","splice","sort","reverse"];Ve(Un,Yt,oo);var Hn=Map.prototype,yt=Object.create(Hn),so=["set","clear","delete"];dt(yt,"Map");Ve(Hn,yt,so);var _n=Set.prototype,ht=Object.create(_n),io=["add","clear","delete"];dt(ht,"Set");Ve(_n,ht,io);var Ae={},z=t=>{if(m(t)||Be(t))return t;let e={auto:!0,_value:t},n=c=>w(c)?G in c?!0:T(c)?(Object.setPrototypeOf(c,Yt),!0):X(c)?(Object.setPrototypeOf(c,ht),!0):ue(c)?(Object.setPrototypeOf(c,yt),!0):!1:!1,r=n(t),o=new Set,s=(c,f)=>{if(Ae.set){Ae.set.add(a);return}o.size!==0&&ut(()=>{for(let p of[...o.keys()])o.has(p)&&p(c,f)})},i=c=>{let f=c[G];f||(c[G]=f=new Set),f.add(a)},a=(...c)=>{if(!(2 in c)){let p=c[0],l=c[1];return 0 in c?e._value===p||m(p)&&(p=p(),e._value===p)?p:(n(p)&&i(p),e._value=p,e.auto&&s(p,l),e._value):(Dn(a),e._value)}switch(c[2]){case 0:{let p=c[3];if(!p)return()=>{};let l=b=>{o.delete(b)};return o.add(p),()=>{l(p)}}case 1:{let p=c[1],l=e._value;s(l,p);break}case 2:return o.size;case 3:{e.auto=!1;break}case 4:e.auto=!0}return e._value};return a[G]=1,he(a,!1),r&&i(t),a};var V=t=>m(t)?t():t;var et=class{E=[];_=new Map;get S(){return this.E.length}J;constructor(e){this.J=e}Q(e){let n=this.J(e.value);n&&this._.set(n,e)}X(e){let n=this.J(this.E[e]?.value);n&&this._.delete(n)}static Ke(e,n){return{items:[],index:e,value:n,order:-1}}w(e){e.order=this.S,this.E.push(e),this.Q(e)}ze(e,n){let r=this.S;for(let o=e;o<r;++o)this.E[o].order=o+1;n.order=e,this.E.splice(e,0,n),this.Q(n)}I(e){return this.E[e]}Y(e,n){this.X(e),this.E[e]=n,this.Q(n),n.order=e}ce(e){this.X(e),this.E.splice(e,1);let n=this.S;for(let r=e;r<n;++r)this.E[r].order=r}le(e){let n=this.S;for(let r=e;r<n;++r)this.X(r);this.E.splice(e)}Rt(e){return this._.has(e)}We(e){return this._.get(e)?.order??-1}};var Zt=Symbol("r-for"),gt=class t{p;b;Z;T;constructor(e){this.p=e,this.b=e.o.l.for,this.Z=He(this.b),this.T=e.o.l.pre}N(e){let n=e.hasAttribute(this.b),r=de(e,this.Z);for(let o of r)this.Ge(o);return n}W(e){return e[Zt]?!0:(e[Zt]=!0,de(e,this.Z).forEach(n=>n[Zt]=!0),!1)}Ge(e){if(e.hasAttribute(this.T)||this.W(e))return;let n=e.getAttribute(this.b);if(!n){I(0,this.b,e);return}e.removeAttribute(this.b),this.Je(e,n)}fe(e){return Y(e)?[]:(U(e)&&(e=e()),Symbol.iterator in Object(e)?e:typeof e=="number"?(r=>({*[Symbol.iterator](){for(let o=1;o<=r;o++)yield o}}))(e):Object.entries(e))}Je(e,n){let r=this.Qe(n);if(!r?.list){I(1,this.b,n,e);return}let o=this.p.o.l.key,s=this.p.o.l.keyBind,i=e.getAttribute(o)??e.getAttribute(s);e.removeAttribute(o),e.removeAttribute(s);let a=i?x=>V(V(x)?.[i]):x=>x,c=(x,N)=>a(x)===a(N),f=Ue(e),p=e.parentNode;if(!p)return;let l=`${this.b} => ${n}`,b=new Comment(`__begin__ ${l}`);p.insertBefore(b,e),Ie(b,f),f.forEach(x=>{P(x)}),e.remove();let u=new Comment(`__end__ ${l}`);p.insertBefore(u,b.nextSibling);let y=this.p,v=y.h,S=v.k(),h=(x,N,q)=>{let R=r.createContext(N,x),Q=et.Ke(R.index,N);return v.C(S,()=>{v.w(R.ctx);let ee=q.previousSibling,Le=[];for(let d of f){let M=d.cloneNode(!0);p.insertBefore(M,q),Le.push(M)}for(ye(y,Le),ee=ee.nextSibling;ee!==q;)Q.items.push(ee),ee=ee.nextSibling}),Q},A=(x,N)=>{let q=L.I(x).items,R=q[q.length-1].nextSibling;for(let Q of q)P(Q);L.Y(x,h(x,N,R))},O=(x,N)=>{L.w(h(x,N,u))},Ee=x=>{for(let N of L.I(x).items)P(N)},We=x=>{let N=L.S;for(let q=x;q<N;++q)L.I(q).index(q)},Vt=x=>{let N=L.S;U(x)&&(x=x());let q=V(x[0]);if(T(q)&&q.length===0){ae(b,u),L.le(0);return}let R=0,Q=Number.MAX_SAFE_INTEGER,ee=N,Le=this.p.o.forGrowThreshold,d=()=>L.S<ee+Le;for(let g of this.fe(x[0])){let D=()=>{if(R<N){let W=L.I(R++);if(c(W.value,g))return;let E=L.We(a(g));if(E>=R&&E-R<10){if(--R,Q=Math.min(Q,R),Ee(R),L.ce(R),--N,E>R+1)for(let j=R;j<E-1&&j<N&&!c(L.I(R).value,g);)++j,Ee(R),L.ce(R),--N;D();return}d()?(L.ze(R-1,h(R,g,L.I(R-1).items[0])),Q=Math.min(Q,R-1),++N):A(R-1,g)}else O(R++,g)};D()}let M=R;for(N=L.S;R<N;)Ee(R++);L.le(M),We(Q)},nt=()=>{Ge=C(le,Vt)},ve=()=>{rt.stop(),Ge()},rt=v.v(r.list),le=rt.value,Ge,oe=0,L=new et(a);for(let x of this.fe(le()[0]))L.w(h(oe++,x,u));k(b,ve),nt()}static Xe=/\{?\[?\(?([^)}\]]+)\)?\]?\}?([^)]+)?\s+\b(?:in|of)\b\s+([^\s]+)\s*/;Qe(e){let n=t.Xe.exec(e);if(!n)return;let r=(n[1]+(n[2]??"")).split(",").map(c=>c.trim()),o=r.length>1?r.length-1:-1,s=o!==-1&&(r[o]==="index"||r[o]?.startsWith("#"))?r[o]:"";s&&r.splice(o,1);let i=n[3];if(!i||r.length===0)return;let a=/[{[]/.test(e);return{list:i,createContext:(c,f)=>{let p={},l=V(c);if(!a&&r.length===1)p[r[0]]=c;else if(T(l)){let u=0;for(let y of r)p[y]=l[u++]}else for(let u of r)p[u]=l[u];let b={ctx:p,index:z(-1)};return s&&(b.index=p[s.startsWith("#")?s.substring(1):s]=z(f)),b}}}};var ao=(t,e)=>{for(let n of t){let r=n.cloneNode(!0);e.appendChild(r)}},bt=class{p;D;ue;constructor(e){this.p=e,this.D=e.o.l.is,this.ue=He(this.D)+", [is]"}N(e){let n=e.hasAttribute(this.D),r=de(e,this.ue);for(let o of r)this.x(o);return n}x(e){let n=e.getAttribute(this.D);if(!n){if(n=e.getAttribute("is"),!n||!n.startsWith("regor:"))return;n=`'${n.slice(6)}'`,e.removeAttribute("is")}e.removeAttribute(this.D),this.V(e,n)}B(e,n){let r=Ue(e),o=e.parentNode,s=document.createComment(`__begin__ dynamic ${n??""}`);o.insertBefore(s,e),Ie(s,r),r.forEach(a=>{P(a)}),e.remove();let i=document.createComment(`__end__ dynamic ${n??""}`);return o.insertBefore(i,s.nextSibling),{nodes:r,parent:o,commentBegin:s,commentEnd:i}}V(e,n){let{nodes:r,parent:o,commentBegin:s,commentEnd:i}=this.B(e,` => ${n} `),a=this.p.h.v(n),c=a.value,f=this.p.h,p=f.k(),l={name:""},b=ne(e)?r:[...r[0].childNodes],u=()=>{f.C(p,()=>{let h=c()[0];if(w(h)&&(h.name?h=h.name:h=Object.entries(f.me()).filter(O=>O[1]===h)[0]?.[0]),!H(h)||$(h)){ae(s,i);return}if(l.name===h)return;ae(s,i);let A=document.createElement(h);for(let O of e.getAttributeNames())O!==this.D&&A.setAttribute(O,e.getAttribute(O));ao(b,A),o.insertBefore(A,i),this.p.G(A),l.name=h})},y=[];k(s,()=>{a.stop();for(let h of y)h();y.length=0}),u();let S=C(c,u);y.push(S)}};var Bn={collectRefObj:!0,onBind:(t,e)=>C(e.value,()=>{let r=e.value(),o=e.context,s=r[0];if(w(s))for(let i of Object.entries(s)){let a=i[0],c=i[1],f=o[a];f!==c&&(m(f)?f(c):o[a]=c)}},!0)};var Vn={collectRefObj:!0,once:!0,onBind:(t,e)=>{let n=e.value(),r=e.context,o=n[0];if(!w(o))return()=>{};for(let s of Object.entries(o)){let i=s[0],a=s[1],c=r[i];c!==a&&(m(c)?c(a):r[i]=a)}return()=>{}}};var ge=t=>{st(t)?.onUnmounted?.forEach(n=>{n()}),t.unmounted?.()};var Pe=class{props;start;end;ctx;autoProps=!0;entangle=!0;disableSwitch=!1;onAutoPropsAssigned;de;constructor(e,n,r,o,s){this.props=e,this.de=n,this.ctx=r,this.start=o,this.end=s}emit=(e,n)=>{this.de.dispatchEvent(new CustomEvent(e,{detail:n}))};unmount(){let e=this.start.nextSibling,n=this.end;for(;e&&e!==n;)P(e),e=e.nextSibling;ge(this)}};var en=Symbol("scope"),Tt=t=>{try{Rn();let e=t();zt(e);let n={context:e,unmount:()=>ge(e),[en]:1};return n[en]=1,n}finally{Sn()}},Pn=t=>w(t)?en in t:!1;var Et=(t,e)=>{if(t===e)return()=>{};let n=C(t,o=>e(o)),r=C(e,o=>t(o));return e(t()),()=>{n(),r()}};var vt=t=>{st(t)?.onMounted?.forEach(n=>{n()}),t.mounted?.()};var jn={collectRefObj:!0,onBind:(t,e,n,r,o,s)=>{if(!r)return()=>{};let i=B(r);return C(e.value,()=>{let c=e.refs[0]??e.value()[0],f=e.context,p=f[r];p!==c&&(m(p)?p(c):f[i]=c)},!0)}};var xt=class{p;ye;constructor(e){this.p=e,this.ye=e.o.l.inherit}N(e){this.Ye(e)}Ye(e){let n=this.p,r=n.h,o=n.o.he,s=n.o.ge,i=r.me(),a=[...o.keys(),...Object.keys(i),...[...o.keys()].map(_e),...[...Object.keys(i)].map(_e)].join(",");if($(a))return;let c=e.querySelectorAll(a),f=e.matches?.(a)?[e,...c]:c;for(let p of f){if(p.hasAttribute(n.T))continue;let l=p.parentNode;if(!l)continue;let b=p.nextSibling,u=B(p.tagName).toUpperCase(),v=i[u]??s.get(u);if(!v)continue;let S=v.template;if(!S)continue;let h=p.parentElement;if(!h)continue;let A=new Comment(" begin component: "+p.tagName),O=new Comment(" end component: "+p.tagName);h.insertBefore(A,p),p.remove();let Ee=n.o.l.props,We=n.o.l.propsOnce,Vt=n.o.l.bind,nt=(d,M)=>{let g={},D=d.hasAttribute(Ee),W=d.hasAttribute(We);return r.C(M,()=>{r.w(g),D&&n.x(Bn,d,Ee),W&&n.x(Vn,d,We);let E=v.props;if(!E||E.length===0)return;E=E.map(B);for(let xe of E.concat(E.map(_e))){let se=d.getAttribute(xe);se!==null&&(g[B(xe)]=se,d.removeAttribute(xe))}let j=n.ee.be(d,!1);for(let[xe,se]of j.entries()){let[Ce,Pt]=se.te;Pt&&E.includes(B(Pt))&&(Ce!=="."&&Ce!==":"&&Ce!==Vt||n.x(jn,d,xe,!0,Pt,se.ne))}}),g},ve=[...r.k()],rt=()=>{let d=nt(p,ve),M=new Pe(d,p,ve,A,O),g=Tt(()=>v.context(M)??{}).context;if(M.autoProps){for(let[D,W]of Object.entries(d))if(D in g){let E=g[D];if(E===W)continue;M.entangle&&m(E)&&m(W)?k(A,Et(W,E)):m(E)?E(W):g[D]=V(W)}else g[D]=W;M.onAutoPropsAssigned?.()}return{componentCtx:g,head:M}},{componentCtx:le,head:Ge}=rt(),oe=[...ce(S)],L=oe.length,x=p.childNodes.length===0,N=d=>{let M=d.parentElement;if(x){for(let E of[...d.childNodes])M.insertBefore(E,d);return}let g=d.name;$(g)&&(g=d.getAttributeNames().filter(E=>E.startsWith("#"))[0],$(g)?g="default":g=g.substring(1));let D=p.querySelector(`template[name='${g}'], template[\\#${g}]`);!D&&g==="default"&&(D=p.querySelector("template:not([name])"),D&&D.getAttributeNames().filter(E=>E.startsWith("#")).length>0&&(D=null));let W=E=>{Ge.disableSwitch||r.C(ve,()=>{r.w(le);let j=nt(d,r.k());r.C(ve,()=>{r.w(j);let xe=r.k(),se=On(xe);for(let Ce of E)Se(Ce)&&(Ce.setAttribute(Xe,se),Kt(se),k(Ce,()=>{Wt(se)}))})})};if(D){let E=[...ce(D)];for(let j of E)M.insertBefore(j,d);W(E)}else{if(g!=="default"){for(let j of[...ce(d)])M.insertBefore(j,d);return}let E=[...ce(p)].filter(j=>!ne(j));for(let j of E)M.insertBefore(j,d);W(E)}},q=d=>{if(!Se(d))return;let M=d.querySelectorAll("slot");if(kn(d)){N(d),d.remove();return}for(let g of M)N(g),g.remove()};(()=>{for(let d=0;d<L;++d)oe[d]=oe[d].cloneNode(!0),l.insertBefore(oe[d],b),q(oe[d])})(),h.insertBefore(O,b);let Q=()=>{if(!v.inheritAttrs)return;let d=oe.filter(g=>g.nodeType===Node.ELEMENT_NODE);d.length>1&&(d=d.filter(g=>g.hasAttribute(this.ye)));let M=d[0];if(M)for(let g of p.getAttributeNames()){if(g===Ee||g===We)continue;let D=p.getAttribute(g);if(g==="class")M.classList.add(...D.split(" "));else if(g==="style"){let W=M.style,E=p.style;for(let j of E)W.setProperty(j,E.getPropertyValue(j))}else M.setAttribute(lt(g,n.o),D)}},ee=()=>{for(let d of p.getAttributeNames())!d.startsWith("@")&&!d.startsWith(n.o.l.on)&&p.removeAttribute(d)},Le=()=>{Q(),ee(),r.w(le),n.Te(p,!1),le.$emit=Ge.emit,ye(n,oe),k(p,()=>{ge(le)}),k(A,()=>{te(p)}),vt(le)};r.C(ve,Le)}}};var tn=class{xe;te=[];ne=[];Ee=[];constructor(e){this.xe=e,this.v()}v(){let e=this.xe,n=e.startsWith(".");n&&(e=":"+e.slice(1));let r=e.indexOf("."),o=this.te=(r<0?e:e.substring(0,r)).split(/[:@]/);if($(o[0])&&(o[0]=n?".":e[0]),r>=0){let s=this.ne=e.slice(r+1).split(".");if(s.includes("camel")){let i=o.length-1;o[i]=B(o[i])}s.includes("prop")&&(o[0]=".")}}},Ct=class{p;Re;constructor(e){this.p=e,this.Re=e.o.Ze()}be(e,n){let r=new Map;if(!Ye(e))return r;let o=this.Re,s=a=>{let c=a.getAttributeNames().filter(f=>o.some(p=>f.startsWith(p)));for(let f of c)r.has(f)||r.set(f,new tn(f)),r.get(f).Ee.push(a)};if(s(e),!n)return r;let i=e.querySelectorAll("*");for(let a of i)s(a);return r}};var Rt={};var St=class{h;ve;Ce;Se;we;ee;o;T;Ae;constructor(e){this.h=e,this.o=e.o,this.Ce=new gt(this),this.ve=new ft(this),this.Se=new bt(this),this.we=new xt(this),this.ee=new Ct(this),this.T=this.o.l.pre,this.Ae=this.o.l.dynamic}et(e){let n=ne(e)?[e]:e.querySelectorAll("template");for(let r of n){if(r.hasAttribute(this.T))continue;let o=r.parentNode;if(!o)continue;let s=r.nextSibling;if(r.remove(),!r.content)continue;let i=[...r.content.childNodes];for(let a of i)o.insertBefore(a,s);ye(this,i)}}G(e){e.nodeType!==Node.ELEMENT_NODE||e.hasAttribute(this.T)||this.ve.N(e)||this.Ce.N(e)||this.Se.N(e)||(this.we.N(e),this.et(e),this.Te(e,!0))}Te(e,n){let r=this.ee.be(e,n),o=this.o.H;for(let[s,i]of r.entries()){let[a,c]=i.te,f=o[s]??o[a];if(!f){console.error("directive not found:",a);continue}i.Ee.forEach(p=>{this.x(f,p,s,!1,c,i.ne)})}}x(e,n,r,o,s,i){if(n.hasAttribute(this.T))return;let a=n.getAttribute(r);n.removeAttribute(r);let c=f=>{let p=f.getAttribute(Xe);return p||(f.parentElement?c(f.parentElement):null)};if(Gt()){let f=c(n);if(f){this.h.C(Nn(f),()=>{this.V(e,n,a,s,i)});return}}this.V(e,n,a,s,i)}tt(e,n,r){if(e!==Rt)return!1;if($(r))return!0;let o=document.querySelector(r);if(o){let s=n.parentElement;if(!s)return!0;let i=new Comment(`teleported => '${r}'`);s.insertBefore(i,n),n.teleportedFrom=i,i.teleportedTo=n,k(i,()=>{P(n)}),o.appendChild(n)}return!0}V(e,n,r,o,s){if(n.nodeType!==Node.ELEMENT_NODE||r==null||this.tt(e,n,r))return;let i=this.h.v(r,e.isLazy,e.isLazyKey,e.collectRefObj,e.once),a=[];k(n,()=>{i.stop(),p?.stop();for(let S of a)S();a.length=0});let f=In(o,this.Ae),p;f&&(p=this.h.v(B(f),void 0,void 0,void 0,e.once));let l,b=()=>(l=i.value(),l),u,y=()=>p?(u=p.value()[0],u):(u=o,o),v=()=>{if(!e.onChange)return;let S=C(i.value,h=>{let A=l,O=u;e.onChange?.(n,b(),A,y(),O,s)});if(a.push(S),p){let h=C(p.value,A=>{let O=u;e.onChange?.(n,b(),O,y(),O,s)});a.push(h)}};e.once||v(),e.onBind&&a.push(e.onBind(n,i,r,o,p,s)),e.onChange?.(n,b(),void 0,y(),void 0,s)}};var co=9,po=10,fo=13,lo=32,be=46,wt=44,uo=39,mo=34,At=40,je=41,Ot=91,Nt=93,nn=63,yo=59,$n=58,ho=123,Mt=125,on=43,go=45,Fn=96,qn=47,bo=92,zn=[2,3],Kn=[on,go],Yn={"-":1,"!":1,"~":1,"+":1,new:1},Zn={"=":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},Fe={"=>":2,...Zn,"||":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},er=Object.keys(Zn),To=new Set(er),Lt=new Set;Lt.add("=>");er.forEach(t=>Lt.add(t));var Eo=new Set(["$","_"]),Wn={true:!0,false:!1,null:null},vo="this";function tr(t){return Math.max(0,...Object.keys(t).map(e=>e.length))}var xo=tr(Yn),Co=tr(Fe),qe="Expected ",Oe="Unexpected ",an="Unclosed ",Ro=qe+":",Gn=qe+"expression",So="missing }",wo=Oe+"object property",Ao=an+"(",Jn=qe+"comma",Qn=Oe+"token ",Oo=Oe+"period",rn=qe+"expression after ",No="missing unaryOp argument",Mo=an+"[",Lo=qe+"exponent (",ko="Variable names cannot start with a number (",Io=an+'quote after "';var $e=t=>t>=48&&t<=57,Xn=t=>Fe[t]||0,sn=class{nt={0:[this.rt],1:[this.ot,this.st,this.it],2:[this.at,this.pt,this.ct,this.Oe,this.lt],3:[this.ft,this.ut,this.mt]};r;e;get M(){return this.r.charAt(this.e)}get f(){return this.r.charCodeAt(this.e)}u(e){return this.r.charCodeAt(this.e)===e}constructor(e){this.r=e,this.e=0}U(e){let n=String.fromCharCode(e);return e>=65&&e<=90||e>=97&&e<=122||e>=128&&!(n in Fe)||Eo.has(n)}re(e){return this.U(e)||$e(e)}i(e){return new Error(`${e} at character ${this.e}`)}L(e,n,r){let o=this.nt[e];if(!o)return r;let s={node:r},i=a=>{a.call(this,s)};return n===0?o.forEach(i):o.find(i),s.node}y(){let e=this.f,n=this.r,r=this.e;for(;e===lo||e===co||e===po||e===fo;)e=n.charCodeAt(++r);this.e=r}parse(){let e=this.oe();return e.length===1?e[0]:{type:0,body:e}}oe(e){let n=[];for(;this.e<this.r.length;){let r=this.f;if(r===yo||r===wt)this.e++;else{let o=this.A();if(o)n.push(o);else if(this.e<this.r.length){if(r===e)break;throw this.i(Oe+'"'+this.M+'"')}}}return n}A(){let e=this.L(0,1)??this.Ne();return this.y(),this.L(1,0,e)}se(){this.y();let e=this.e,n=this.r,r=n.substr(e,Co),o=r.length;for(;o>0;){if(r in Fe&&(!this.U(this.f)||e+r.length<n.length&&!this.re(n.charCodeAt(e+r.length))))return e+=o,this.e=e,r;r=r.substr(0,--o)}return!1}Ne(){let e,n,r,o,s,i,a,c;if(s=this.j(),!s||(n=this.se(),!n))return s;if(o={value:n,prec:Xn(n),right_a:Lt.has(n)},i=this.j(),!i)throw this.i(rn+n);let f=[s,o,i];for(;n=this.se();){if(r=Xn(n),r===0){this.e-=n.length;break}o={value:n,prec:r,right_a:Lt.has(n)},c=n;let p=l=>o.right_a&&l.right_a?r>l.prec:r<=l.prec;for(;f.length>2&&p(f[f.length-2]);)i=f.pop(),n=f.pop().value,s=f.pop(),e={type:8,operator:n,left:s,right:i},f.push(e);if(e=this.j(),!e)throw this.i(rn+c);f.push(o,e)}for(a=f.length-1,e=f[a];a>1;)e={type:8,operator:f[a-1].value,left:f[a-2],right:e},a-=2;return e}j(){let e,n,r;if(this.y(),r=this.L(2,1),r)return this.L(3,0,r);let o=this.f;if($e(o)||o===be)return this.dt();if(o===uo||o===mo)r=this.yt();else if(o===Ot)r=this.ht();else{for(e=this.r.substr(this.e,xo),n=e.length;n>0;){if(Object.prototype.hasOwnProperty.call(Yn,e)&&(!this.U(this.f)||this.e+e.length<this.r.length&&!this.re(this.r.charCodeAt(this.e+e.length)))){this.e+=n;let s=this.j();if(!s)throw this.i(No);return this.L(3,0,{type:7,operator:e,argument:s})}e=e.substr(0,--n)}this.U(o)?(r=this.ie(),r.name in Wn?r={type:4,value:Wn[r.name],raw:r.name}:r.name===vo&&(r={type:5})):o===At&&(r=this.gt())}return r?(r=this.F(r),this.L(3,0,r)):this.L(3,0,!1)}F(e){this.y();let n=this.f;for(;n===be||n===Ot||n===At||n===nn;){let r;if(n===nn){if(this.r.charCodeAt(this.e+1)!==be)break;r=!0,this.e+=2,this.y(),n=this.f}if(this.e++,n===Ot){if(e={type:3,computed:!0,object:e,property:this.A()},this.y(),n=this.f,n!==Nt)throw this.i(Mo);this.e++}else n===At?e={type:6,arguments:this.Me(je),callee:e}:(n===be||r)&&(r&&this.e--,this.y(),e={type:3,computed:!1,object:e,property:this.ie()});r&&(e.optional=!0),this.y(),n=this.f}return e}dt(){let e="",n;for(;$e(this.f);)e+=this.r.charAt(this.e++);if(this.u(be))for(e+=this.r.charAt(this.e++);$e(this.f);)e+=this.r.charAt(this.e++);if(n=this.M,n==="e"||n==="E"){for(e+=this.r.charAt(this.e++),n=this.M,(n==="+"||n==="-")&&(e+=this.r.charAt(this.e++));$e(this.f);)e+=this.r.charAt(this.e++);if(!$e(this.r.charCodeAt(this.e-1)))throw this.i(Lo+e+this.M+")")}let r=this.f;if(this.U(r))throw this.i(ko+e+this.M+")");if(r===be||e.length===1&&e.charCodeAt(0)===be)throw this.i(Oo);return{type:4,value:parseFloat(e),raw:e}}yt(){let e="",n=this.e,r=this.r.charAt(this.e++),o=!1;for(;this.e<this.r.length;){let s=this.r.charAt(this.e++);if(s===r){o=!0;break}else if(s==="\\")switch(s=this.r.charAt(this.e++),s){case"n":e+=`
2
2
  `;break;case"r":e+="\r";break;case"t":e+=" ";break;case"b":e+="\b";break;case"f":e+="\f";break;case"v":e+="\v";break;default:e+=s}else e+=s}if(!o)throw this.i(Io+e+'"');return{type:4,value:e,raw:this.r.substring(n,this.e)}}ie(){let e=this.f,n=this.e;if(this.U(e))this.e++;else throw this.i(Oe+this.M);for(;this.e<this.r.length&&(e=this.f,this.re(e));)this.e++;return{type:2,name:this.r.slice(n,this.e)}}Me(e){let n=[],r=!1,o=0;for(;this.e<this.r.length;){this.y();let s=this.f;if(s===e){if(r=!0,this.e++,e===je&&o&&o>=n.length)throw this.i(Qn+String.fromCharCode(e));break}else if(s===wt){if(this.e++,o++,o!==n.length){if(e===je)throw this.i(Qn+",");if(e===Nt)for(let i=n.length;i<o;i++)n.push(null)}}else{if(n.length!==o&&o!==0)throw this.i(Jn);{let i=this.A();if(!i||i.type===0)throw this.i(Jn);n.push(i)}}}if(!r)throw this.i(qe+String.fromCharCode(e));return n}gt(){this.e++;let e=this.oe(je);if(this.u(je))return this.e++,e.length===1?e[0]:e.length?{type:1,expressions:e}:!1;throw this.i(Ao)}ht(){return this.e++,{type:9,elements:this.Me(Nt)}}at(e){if(this.u(ho)){this.e++;let n=[];for(;!isNaN(this.f);){if(this.y(),this.u(Mt)){this.e++,e.node=this.F({type:10,properties:n});return}let r=this.A();if(!r)break;if(this.y(),r.type===2&&(this.u(wt)||this.u(Mt)))n.push({type:12,computed:!1,key:r,value:r,shorthand:!0});else if(this.u($n)){this.e++;let o=this.A();if(!o)throw this.i(wo);let s=r.type===9;n.push({type:12,computed:s,key:s?r.elements[0]:r,value:o,shorthand:!1}),this.y()}else r&&n.push(r);this.u(wt)&&this.e++}throw this.i(So)}}pt(e){let n=this.f;if(Kn.some(r=>r===n&&r===this.r.charCodeAt(this.e+1))){this.e+=2;let r=e.node={type:13,operator:n===on?"++":"--",argument:this.F(this.ie()),prefix:!0};if(!r.argument||!zn.includes(r.argument.type))throw this.i(Oe+r.operator)}}ut(e){if(e.node){let n=this.f;if(Kn.some(r=>r===n&&r===this.r.charCodeAt(this.e+1))){if(!zn.includes(e.node.type))throw this.i(Oe+e.node.operator);this.e+=2,e.node={type:13,operator:n===on?"++":"--",argument:e.node,prefix:!1}}}}ct(e){[0,1,2].every(n=>this.r.charCodeAt(this.e+n)===be)&&(this.e+=3,e.node={type:14,argument:this.A()})}it(e){if(e.node&&this.u(nn)){this.e++;let n=e.node,r=this.A();if(!r)throw this.i(Gn);if(this.y(),this.u($n)){this.e++;let o=this.A();if(!o)throw this.i(Gn);if(e.node={type:11,test:n,consequent:r,alternate:o},n.operator&&Fe[n.operator]<=.9){let s=n;for(;s.right.operator&&Fe[s.right.operator]<=.9;)s=s.right;e.node.test=s.right,s.right=e.node,e.node=n}}else throw this.i(Ro)}}rt(e){if(this.y(),this.u(At)){let n=this.e;if(this.e++,this.y(),this.u(je)){this.e++;let r=this.se();if(r==="=>"){let o=this.Ne();if(!o)throw this.i(rn+r);e.node={type:15,params:null,body:o};return}}this.e=n}}ot(e){this.Le(e.node)}Le(e){e&&(Object.values(e).forEach(n=>{n&&typeof n=="object"&&this.Le(n)}),e.operator==="=>"&&(e.type=15,e.params=e.left?[e.left]:null,e.body=e.right,e.params&&e.params[0].type===1&&(e.params=e.params[0].expressions),delete e.left,delete e.right,delete e.operator))}st(e){e.node&&this.$(e.node)}$(e){To.has(e.operator)?(e.type=16,this.$(e.left),this.$(e.right)):e.operator||Object.values(e).forEach(n=>{n&&typeof n=="object"&&this.$(n)})}mt(e){if(!e.node)return;let n=e.node.type;(n===2||n===3)&&this.u(Fn)&&(e.node={type:17,tag:e.node,quasi:this.Oe(e)})}Oe(e){if(!this.u(Fn))return;let n={type:19,quasis:[],expressions:[]},r="",o="",s=!1,i=this.r.length,a=()=>n.quasis.push({type:18,value:{raw:o,cooked:r},tail:s});for(;this.e<i;){let c=this.r.charAt(++this.e);if(c==="`")return this.e+=1,s=!0,a(),e.node=n,n;if(c==="$"&&this.r.charAt(this.e+1)==="{"){if(this.e+=2,a(),o="",r="",n.expressions.push(...this.oe(Mt)),!this.u(Mt))throw this.i("unclosed ${")}else if(c==="\\")switch(o+=c,c=this.r.charAt(++this.e),o+=c,c){case"n":r+=`
3
- `;break;case"r":r+="\r";break;case"t":r+=" ";break;case"b":r+="\b";break;case"f":r+="\f";break;case"v":r+="\v";break;default:r+=c}else r+=c,o+=c}throw this.i("Unclosed `")}ft(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 r=e.node;for(;r.type===3||r.type===6&&r?.callee?.type===3;)r=r.type===3?r.object:r.callee.object;r.type=20}lt(e){if(!this.u(qn))return;let n=++this.e,r=!1;for(;this.e<this.r.length;){if(this.f===qn&&!r){let o=this.r.slice(n,this.e),s="";for(;++this.e<this.r.length;){let a=this.f;if(a>=97&&a<=122||a>=65&&a<=90||a>=48&&a<=57)s+=this.M;else break}let i;try{i=new RegExp(o,s)}catch(a){throw this.i(a.message)}return e.node={type:4,value:i,raw:this.r.slice(n-1,this.e)},e.node=this.F(e.node),e.node}this.u(Ot)?r=!0:r&&this.u(Nt)&&(r=!1),this.e+=this.u(bo)?2:1}throw this.i("Unclosed Regex")}},nr=t=>new sn(t).parse();var Do={"=>":(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,"&":(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},Uo={"-":t=>-t,"+":t=>+t,"!":t=>!t,"~":t=>~t,new:t=>t},ir=t=>{if(!t?.some(sr))return t;let e=[];return t.forEach(n=>sr(n)?e.push(...n):e.push(n)),e},rr=(...t)=>ir(t),cn=(t,e)=>{if(!t)return e;let n=Object.create(e??{});return n.$event=t,n},Ho={"++":(t,e)=>{let n=t[e];if(m(n)){let r=n();return n(++r),r}return++t[e]},"--":(t,e)=>{let n=t[e];if(m(n)){let r=n();return n(--r),r}return--t[e]}},_o={"++":(t,e)=>{let n=t[e];if(m(n)){let r=n();return n(r+1),r}return t[e]++},"--":(t,e)=>{let n=t[e];if(m(n)){let r=n();return n(r-1),r}return t[e]--}},or={"=":(t,e,n)=>{let r=t[e];return m(r)?r(n):t[e]=n},"+=":(t,e,n)=>{let r=t[e];return m(r)?r(r()+n):t[e]+=n},"-=":(t,e,n)=>{let r=t[e];return m(r)?r(r()-n):t[e]-=n},"*=":(t,e,n)=>{let r=t[e];return m(r)?r(r()*n):t[e]*=n},"/=":(t,e,n)=>{let r=t[e];return m(r)?r(r()/n):t[e]/=n},"%=":(t,e,n)=>{let r=t[e];return m(r)?r(r()%n):t[e]%=n},"**=":(t,e,n)=>{let r=t[e];return m(r)?r(r()**n):t[e]**=n},"<<=":(t,e,n)=>{let r=t[e];return m(r)?r(r()<<n):t[e]<<=n},">>=":(t,e,n)=>{let r=t[e];return m(r)?r(r()>>n):t[e]>>=n},">>>=":(t,e,n)=>{let r=t[e];return m(r)?r(r()>>>n):t[e]>>>=n},"|=":(t,e,n)=>{let r=t[e];return m(r)?r(r()|n):t[e]|=n},"&=":(t,e,n)=>{let r=t[e];return m(r)?r(r()&n):t[e]&=n},"^=":(t,e,n)=>{let r=t[e];return m(r)?r(r()^n):t[e]^=n}},kt=(t,e)=>U(t)?t.bind(e):t,pn=class{m;ke;Ve;Ie;O;De;Ue;constructor(e,n,r,o,s){this.m=T(e)?e:[e],this.ke=n,this.Ve=r,this.Ie=o,this.Ue=!!s}Pe(e,n){if(n&&e in n)return n;for(let r of this.m)if(e in r)return r}2(e,n,r){let o=e.name;if(o==="$root")return this.m[this.m.length-1];if(o==="$parent")return this.m[1];if(o==="$ctx")return[...this.m];if(r&&o in r)return this.O=r[o],kt(V(r[o]),r);for(let i of this.m)if(o in i)return this.O=i[o],kt(V(i[o]),i);let s=this.ke;if(s&&o in s)return this.O=s[o],kt(V(s[o]),s)}5(e,n,r){return this.m[0]}0(e,n,r){return this.Be(n,r,rr,...e.body)}1(e,n,r){return this.R(n,r,(...o)=>o.pop(),...e.expressions)}3(e,n,r){let{obj:o,key:s}=this.ae(e,n,r),i=o?.[s];return this.O=i,kt(V(i),o)}4(e,n,r){return e.value}6(e,n,r){let o=(i,...a)=>U(i)?i(...ir(a)):i,s=this.R(++n,r,o,e.callee,...e.arguments);return this.O=s,s}7(e,n,r){return this.R(n,r,Uo[e.operator],e.argument)}8(e,n,r){let o=Do[e.operator];switch(e.operator){case"||":case"&&":case"??":return o(()=>this.g(e.left,n,r),()=>this.g(e.right,n,r))}return this.R(n,r,o,e.left,e.right)}9(e,n,r){return this.Be(++n,r,rr,...e.elements)}10(e,n,r){let o={},s=(...i)=>{i.forEach(a=>{Object.assign(o,a)})};return this.R(++n,r,s,...e.properties),o}11(e,n,r){return this.R(n,r,o=>this.g(o?e.consequent:e.alternate,n,r),e.test)}12(e,n,r){let o={},s=p=>p?.type!==15,i=this.Ie??(()=>!1),a=n===0&&this.Ue,c=p=>this._e(a,e.key,n,cn(p,r)),f=p=>this._e(a,e.value,n,cn(p,r));if(e.shorthand){let p=e.key.name;o[p]=s(e.key)&&i(p,n)?c:c()}else if(e.computed){let p=V(c());o[p]=s(e.value)&&i(p,n)?f:f()}else{let p=e.key.type===4?e.key.value:e.key.name;o[p]=s(e.value)&&i(p,n)?()=>f:f()}return o}ae(e,n,r){let o=this.g(e.object,n,r),s=e.computed?this.g(e.property,n,r):e.property.name;return{obj:o,key:s}}13(e,n,r){let o=e.argument,s=e.operator,i=e.prefix?Ho:_o;if(o.type===2){let a=o.name,c=this.Pe(a,r);return Y(c)?void 0:i[s](c,a)}if(o.type===3){let{obj:a,key:c}=this.ae(o,n,r);return i[s](a,c)}}16(e,n,r){let o=e.left,s=e.operator;if(o.type===2){let i=o.name,a=this.Pe(i,r);if(Y(a))return;let c=this.g(e.right,n,r);return or[s](a,i,c)}if(o.type===3){let{obj:i,key:a}=this.ae(o,n,r),c=this.g(e.right,n,r);return or[s](i,a,c)}}14(e,n,r){let o=this.g(e.argument,n,r);return T(o)&&(o.s=ar),o}17(e,n,r){return this[6]({type:6,callee:e.tag,arguments:[{type:9,elements:e.quasi.quasis},...e.quasi.expressions]},n,r)}19(e,n,r){let o=(...s)=>s.reduce((i,a,c)=>i+=a+e.quasis[c+1].value.cooked,e.quasis[0].value.cooked);return this.R(n,r,o,...e.expressions)}18(e,n,r){return e.value.cooked}20(e,n,r){let o=(s,...i)=>new s(...i);return this.R(n,r,o,e.callee,...e.arguments)}15(e,n,r){return(...o)=>{let s=Object.create(r??{}),i=e.params;if(i){let a=0;for(let c of i)s[c.name]=o[a++]}return this.g(e.body,n,s)}}g(e,n,r){let o=V(this[e.type](e,n,r));return this.De=e.type,o}_e(e,n,r,o){let s=this.g(n,r,o);return e&&this.He()?this.O:s}He(){let e=this.De;return(e===2||e===3||e===6)&&m(this.O)}eval(e,n){let{value:r,refs:o}=mt(()=>this.g(e,-1,n)),s={value:r,refs:o};return this.He()&&(s.ref=this.O),s}R(e,n,r,...o){let s=o.map(i=>i&&this.g(i,e,n));return r(...s)}Be(e,n,r,...o){let s=this.Ve;if(!s)return this.R(e,n,r,...o);let i=o.map((a,c)=>a&&(a.type!==15&&s(c,e)?f=>this.g(a,e,cn(f,n)):this.g(a,e,n)));return r(...i)}},ar=Symbol("s"),sr=t=>t?.s===ar,cr=(t,e,n,r,o,s,i)=>new pn(e,n,r,o,i).eval(t,s);var pr={},It=class{m;o;constructor(e,n){this.m=e,this.o=n}w(e){this.m=[e,...this.m]}me(){return this.m.map(n=>n.components).filter(n=>!!n).reverse().reduce((n,r)=>{for(let[o,s]of Object.entries(r))n[o.toUpperCase()]=s;return n},{})}v(e,n,r,o,s){let i=z([]),a=[],c=()=>{for(let u of a)u();a.length=0},f={value:i,stop:c,refs:[],context:this.m[0]};if($(e))return f;let p=this.o.globalContext,l=[],b=(u,y,v,S)=>{try{let h=cr(u,y,p,n,r,S,o);return v&&l.push(...h.refs),{value:h.value,refs:h.refs,ref:h.ref}}catch(h){I(6,`evaluation error: ${e}`,h)}return{value:void 0,refs:[]}};try{let u=pr[e]??nr("["+e+"]");pr[e]=u;let y=this.m,v=()=>{l.splice(0),c();let S=u.elements.map((h,A)=>n?.(A,-1)?{value:O=>b(h,y,!1,{$event:O}).value,refs:[]}:b(h,y,!0));if(!s)for(let h of l){let A=C(h,v);a.push(A)}i(S.map(h=>h.value)),f.refs=S.map(h=>h.ref)};v()}catch(u){I(6,`parse error: ${e}`,u)}return f}V(){return this.m}je=[];Y(e){this.je.push(this.m),this.m=e}C(e,n){try{this.Y(e),n()}finally{this.bt()}}bt(){this.m=this.je.pop()??[]}};var fr="http://www.w3.org/1999/xlink",Bo={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 Vo(t){return!!t||t===""}var fn={onChange:(t,e,n,r,o,s)=>{if(r){s&&s.includes("camel")&&(r=B(r)),Dt(t,r,e[0],o);return}let i=e.length;for(let a=0;a<i;++a){let c=e[a];if(T(c)){let f=n?.[a]?.[0],p=c[0],l=c[1];Dt(t,p,l,f)}else if(w(c))for(let f of Object.entries(c)){let p=f[0],l=f[1],b=n?.[a],u=b&&p in b?p:void 0;Dt(t,p,l,u)}else{let f=n?.[a],p=e[a++],l=e[a];Dt(t,p,l,f)}}}},Dt=(t,e,n,r)=>{if(r&&r!==e&&t.removeAttribute(r),Y(e)){I(3,name,t);return}if(!H(e)){I(6,`Attribute key is not string at ${t.outerHTML}`,e);return}if(e.startsWith("xlink:")){Y(n)?t.removeAttributeNS(fr,e.slice(6,e.length)):t.setAttributeNS(fr,e,n);return}let o=e in Bo;Y(n)||o&&!Vo(n)?t.removeAttribute(e):t.setAttribute(e,o?"":n)};var ln={onChange:(t,e,n)=>{let r=e.length;for(let o=0;o<r;++o){let s=e[o],i=n?.[o];if(T(s)){let a=s.length;for(let c=0;c<a;++c)lr(t,s[c],i?.[c])}else lr(t,s,i)}}},lr=(t,e,n)=>{let r=t.classList,o=H(e),s=H(n);if(e&&!o){if(n&&!s)for(let i in n)i in e||r.remove(i);for(let i in e)e[i]&&r.add(i)}else o?n!==e&&(s&&r.remove(...n?.split(",")),r.add(...e.split(","))):n&&s&&r.remove(...n?.split(","))};var ur={onChange:(t,e)=>{let[n,r]=e;U(r)?r(t,n):t.innerHTML=n?.toString()}};function Po(t,e){if(t.length!==e.length)return!1;let n=!0;for(let r=0;n&&r<t.length;r++)n=pe(t[r],e[r]);return n}function pe(t,e){if(t===e)return!0;let n=Ft(t),r=Ft(e);if(n||r)return n&&r?t.getTime()===e.getTime():!1;if(n=Je(t),r=Je(e),n||r)return t===e;if(n=T(t),r=T(e),n||r)return n&&r?Po(t,e):!1;if(n=w(t),r=w(e),n||r){if(!n||!r)return!1;let o=Object.keys(t).length,s=Object.keys(e).length;if(o!==s)return!1;for(let i in t){let a=t.hasOwnProperty(i),c=e.hasOwnProperty(i);if(a&&!c||!a&&c||!pe(t[i],e[i]))return!1}}return String(t)===String(e)}function Ut(t,e){return t.findIndex(n=>pe(n,e))}var mr=t=>{let e=parseFloat(t);return isNaN(e)?t:e};var Ht=t=>{if(!m(t))throw _(3,"pause");t(void 0,void 0,3)};var _t=t=>{if(!m(t))throw _(3,"resume");t(void 0,void 0,4)};var yr={onChange:(t,e)=>{jo(t,e[0])},onBind:(t,e,n,r,o,s)=>$o(t,e,s)},jo=(t,e)=>{let n=Tr(t);if(n&&hr(t))T(e)?e=Ut(e,fe(t))>-1:X(e)?e=e.has(fe(t)):e=Go(t,e),t.checked=e;else if(n&&gr(t))t.checked=pe(e,fe(t));else if(n||Er(t))br(t)?t.value!==e?.toString()&&(t.value=e):t.value!==e&&(t.value=e);else if(vr(t)){let r=t.options,o=r.length,s=t.multiple;for(let i=0;i<o;i++){let a=r[i],c=fe(a);if(s)T(e)?a.selected=Ut(e,c)>-1:a.selected=e.has(c);else if(pe(fe(a),e)){t.selectedIndex!==i&&(t.selectedIndex=i);return}}!s&&t.selectedIndex!==-1&&(t.selectedIndex=-1)}else I(7,t)},tt=t=>(m(t)&&(t=t()),U(t)&&(t=t()),t?H(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}),hr=t=>t.type==="checkbox",gr=t=>t.type==="radio",br=t=>t.type==="number"||t.type==="range",Tr=t=>t.tagName==="INPUT",Er=t=>t.tagName==="TEXTAREA",vr=t=>t.tagName==="SELECT",$o=(t,e,n)=>{let r=e.value,o=tt(n?.join(",")),s=tt(r()[1]),i={int:o.int||o.int,lazy:o.lazy||s.lazy,number:o.number||s.number,trim:o.trim||s.trim},a=e.refs[0];if(!a)return I(8,t),()=>{};let c=Tr(t);return c&&hr(t)?qo(t,a):c&&gr(t)?Jo(t,a):c||Er(t)?Fo(t,i,a,r):vr(t)?Qo(t,a,r):(I(7,t),()=>{})},dr=/[.,' ·٫]/,Fo=(t,e,n,r)=>{let s=e.lazy?"change":"input",i=br(t),a=()=>{!e.trim&&!tt(r()[1]).trim||(t.value=t.value.trim())},c=b=>{let u=b.target;u.composing=1},f=b=>{let u=b.target;u.composing&&(u.composing=0,u.dispatchEvent(new Event(s)))},p=()=>{t.removeEventListener(s,l),t.removeEventListener("change",a),t.removeEventListener("compositionstart",c),t.removeEventListener("compositionend",f),t.removeEventListener("change",f)},l=b=>{let u=b.target;if(!u||u.composing)return;let y=u.value,v=tt(r()[1]);if(i||v.number||v.int){if(v.int)y=parseInt(y);else{if(dr.test(y[y.length-1])&&y.split(dr).length===2){if(y+="0",y=parseFloat(y),isNaN(y))y="";else if(n()===y)return}y=parseFloat(y)}isNaN(y)&&(y=""),t.value=y}else v.trim&&(y=y.trim());n(y)};return t.addEventListener(s,l),t.addEventListener("change",a),t.addEventListener("compositionstart",c),t.addEventListener("compositionend",f),t.addEventListener("change",f),p},qo=(t,e)=>{let n="change",r=()=>{t.removeEventListener(n,o)},o=()=>{let s=fe(t),i=t.checked,a=e();if(T(a)){let c=Ut(a,s),f=c!==-1;i&&!f?a.push(s):!i&&f&&a.splice(c,1)}else X(a)?i?a.add(s):a.delete(s):e(Wo(t,i))};return t.addEventListener(n,o),r},fe=t=>"_value"in t?t._value:t.value,xr="trueValue",zo="falseValue",Cr="true-value",Ko="false-value",Wo=(t,e)=>{let n=e?xr:zo;if(n in t)return t[n];let r=e?Cr:Ko;return t.hasAttribute(r)?t.getAttribute(r):e},Go=(t,e)=>{if(xr in t)return pe(e,t.trueValue);let r=Cr;return t.hasAttribute(r)?pe(e,t.getAttribute(r)):pe(e,!0)},Jo=(t,e)=>{let n="change",r=()=>{t.removeEventListener(n,o)},o=()=>{let s=fe(t);e(s)};return t.addEventListener(n,o),r},Qo=(t,e,n)=>{let r="change",o=()=>{t.removeEventListener(r,s)},s=()=>{let a=tt(n()[1]).number,c=Array.prototype.filter.call(t.options,f=>f.selected).map(f=>a?mr(fe(f)):fe(f));if(t.multiple){let f=e();try{if(Ht(e),X(f)){f.clear();for(let p of c)f.add(p)}else T(f)?(f.splice(0),f.push(...c)):e(c)}finally{_t(e),F(e)}}else e(c[0])};return t.addEventListener(r,s),o};var Xo=["stop","prevent","capture","self","once","left","right","middle","passive"],Yo=t=>{let e={};if($(t))return;let n=t.split(",");for(let r of Xo)e[r]=n.includes(r);return e},mn={isLazy:(t,e)=>e===-1&&t%2===0,isLazyKey:(t,e)=>e===0&&!t.endsWith("_flags"),once:!1,collectRefObj:!0,onBind:(t,e,n,r,o,s)=>{if(o){let p=e.value(),l=V(o.value()[0]);return H(l)?un(t,B(l),()=>e.value()[0],s?.join(",")??p[1]):()=>{}}else if(r){let p=e.value();return un(t,B(r),()=>e.value()[0],s?.join(",")??p[1])}let i=[],a=()=>{i.forEach(p=>p())},c=e.value(),f=c.length;for(let p=0;p<f;++p){let l=c[p];if(U(l)&&(l=l()),w(l))for(let b of Object.entries(l)){let u=b[0],y=()=>{let S=e.value()[p];return U(S)&&(S=S()),S=S[u],U(S)&&(S=S()),S},v=l[u+"_flags"];i.push(un(t,u,y,v))}else I(2,name,t)}return a}},Zo=(t,e)=>{if(t.startsWith("keydown")||t.startsWith("keyup")||t.startsWith("keypress")){e??="";let n=t.split(".").concat(e.split(","));t=n[0];let r=n[1],o=n.includes("ctrl"),s=n.includes("shift"),i=n.includes("alt"),a=n.includes("meta"),c=f=>!(o&&!f.ctrlKey||s&&!f.shiftKey||i&&!f.altKey||a&&!f.metaKey);return r?[t,f=>c(f)?f.key.toUpperCase()===r.toUpperCase():!1]:[t,c]}return[t,n=>!0]},un=(t,e,n,r)=>{if($(e))return I(5,name,t),()=>{};let o=Yo(r),s=o?{capture:o.capture,passive:o.passive,once:o.once}:void 0,i;[e,i]=Zo(e,r);let a=p=>{if(!i(p)||!n&&e==="submit"&&o?.prevent)return;let l=n(p);U(l)&&(l=l(p)),U(l)&&l(p)},c=()=>{t.removeEventListener(e,f,s)},f=p=>{if(!o){a(p);return}try{if(o.left&&p.button!==1||o.middle&&p.button!==2||o.right&&p.button!==3||o.self&&p.target!==t)return;o.stop&&p.stopPropagation(),o.prevent&&p.preventDefault(),a(p)}finally{o.once&&c()}};return t.addEventListener(e,f,s),c};var Rr={onChange:(t,e,n,r,o,s)=>{if(r){s&&s.includes("camel")&&(r=B(r)),ze(t,r,e[0]);return}let i=e.length;for(let a=0;a<i;++a){let c=e[a];if(T(c)){let f=c[0],p=c[1];ze(t,f,p)}else if(w(c))for(let f of Object.entries(c)){let p=f[0],l=f[1];ze(t,p,l)}else{let f=e[a++],p=e[a];ze(t,f,p)}}}};function es(t){return!!t||t===""}var ze=(t,e,n)=>{if(Y(e)){I(3,name,t);return}if(e==="innerHTML"||e==="textContent"){let s=[...t.childNodes];setTimeout(()=>s.forEach(te),1),t[e]=n??"";return}let r=t.tagName;if(e==="value"&&r!=="PROGRESS"&&!r.includes("-")){t._value=n;let s=r==="OPTION"?t.getAttribute("value"):t.value,i=n??"";s!==i&&(t.value=i),n==null&&t.removeAttribute(e);return}let o=!1;if(n===""||n==null){let s=typeof t[e];s==="boolean"?n=es(n):n==null&&s==="string"?(n="",o=!0):s==="number"&&(n=0,o=!0)}try{t[e]=n}catch(s){o||I(4,e,r,n,s)}o&&t.removeAttribute(e)};var Sr={once:!0,onBind:(t,e,n)=>{let r=e.value()[0],o=T(r),s=e.refs[0];return o?r.push(t):s?s?.(t):e.context[n]=t,()=>{if(o){let i=r.indexOf(t);i!==-1&&r.splice(i,1)}else s?.(null)}}};var wr={onChange:(t,e)=>{let n=me(t).data,r=n._ord;xn(r)&&(r=n._ord=t.style.display),!!e[0]?t.style.display=r:t.style.display="none"}};var hn={onChange:(t,e,n)=>{let r=e.length;for(let o=0;o<r;++o){let s=e[o],i=n?.[o];if(T(s)){let a=s.length;for(let c=0;c<a;++c)Ar(t,s[c],i?.[c])}else Ar(t,s,i)}}},Ar=(t,e,n)=>{let r=t.style,o=H(e);if(e&&!o){if(n&&!H(n))for(let s in n)e[s]==null&&yn(r,s,"");for(let s in e)yn(r,s,e[s])}else{let s=r.display;if(o?n!==e&&(r.cssText=e):n&&t.removeAttribute("style"),"_ord"in me(t).data)return;r.display=s}},Or=/\s*!important$/;function yn(t,e,n){if(T(n))n.forEach(r=>{yn(t,e,r)});else if(n==null&&(n=""),e.startsWith("--"))t.setProperty(e,n);else{let r=ts(t,e);Or.test(n)?t.setProperty(_e(r),n.replace(Or,""),"important"):t[r]=n}}var Nr=["Webkit","Moz","ms"],dn={};function ts(t,e){let n=dn[e];if(n)return n;let r=B(e);if(r!=="filter"&&r in t)return dn[e]=r;r=Ze(r);for(let o=0;o<Nr.length;o++){let s=Nr[o]+r;if(s in t)return dn[e]=s}return e}var J=t=>ns(V(t)),ns=t=>{if(!t||!w(t))return t;if(T(t))return t.map(J);if(X(t)){let n=new Set;for(let r of t.keys())n.add(J(r));return n}if(ue(t)){let n=new Map;for(let r of n)n.set(J(r[0]),J(r[1]));return n}let e={...t};for(let n of Object.entries(e))e[n[0]]=J(n[1]);return e};var Mr={onChange:(t,e)=>{let n=e[0];t.textContent=X(n)?JSON.stringify(J([...n])):ue(n)?JSON.stringify(J([...n])):w(n)?JSON.stringify(J(n)):n?.toString()??""}};var Lr={onChange:(t,e)=>{ze(t,"value",e[0])}};var Ne=t=>t?.[it]===1;var Te=t=>{if(Be(t))return t;let e;if(m(t)?(e=t,t=e()):e=z(t),t instanceof Node||t instanceof Date||t instanceof RegExp||t instanceof Promise||t instanceof Error)return e;if(e[it]=1,T(t)){let n=t.length;for(let r=0;r<n;++r){let o=t[r];Ne(o)||(t[r]=Te(o))}return e}if(!w(t))return e;for(let n of Object.entries(t)){let r=n[1];if(Ne(r))continue;let o=n[0];Je(o)||(t[o]=Te(r))}return e};var re=class t{static getDefault(){return t.Fe??(t.Fe=new t)}H={};l={};Ze=()=>Object.keys(this.H).filter(e=>e.length===1||!e.startsWith(":"));he=new Map;ge=new Map;static Fe;static Tt="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";forGrowThreshold=10;globalContext;useInterpolation=!0;constructor(e){if(this.setDirectives("r-"),e){this.globalContext=e;return}this.globalContext=this.xt()}xt(){let e={},n=globalThis;for(let r of t.Tt.split(","))e[r]=n[r];return e.ref=Te,e.sref=z,e.flatten=J,e}addComponent(...e){for(let n of e){if(!n.defaultName){Qe.warning("Registered component's default name is not defined",n);continue}this.he.set(Ze(n.defaultName),n),this.ge.set(Ze(n.defaultName).toLocaleUpperCase(),n)}}setDirectives(e){this.H={".":Rr,":":fn,"@":mn,[`${e}on`]:mn,[`${e}bind`]:fn,[`${e}html`]:ur,[`${e}text`]:Mr,[`${e}show`]:wr,[`${e}model`]:yr,":style":hn,[`${e}bind:style`]:hn,":class":ln,[`${e}bind:class`]:ln,":ref":Sr,":value":Lr,teleport:Rt},this.l={for:`${e}for`,if:`${e}if`,else:`${e}else`,elseif:`${e}else-if`,pre:`${e}pre`,inherit:`${e}inherit`,text:`${e}text`,props:":props",propsOnce:":props-once",bind:`${e}bind`,on:`${e}on`,keyBind:":key",key:"key",is:":is",teleport:`${e}teleport`,dynamic:"_d_"}}updateDirectives(e){e(this.H,this.l)}};var Bt=(t,e)=>{if(!t)return;let n=(e??re.getDefault()).l;for(let r of ss(t,n.pre))os(r,n.text)},rs=/({{[^]*?}})/g,os=(t,e)=>{let n=t.textContent;if(!n)return;let r=rs,o=n.split(r);if(o.length<=1)return;if(t.parentElement?.childNodes.length===1&&o.length===3){let i=o[1];if($(o[0])&&$(o[2])&&i.startsWith("{{")&&i.endsWith("}}")){let a=t.parentElement;a.setAttribute(e,i.substring(2,i.length-2)),a.innerText="";return}}let s=document.createDocumentFragment();for(let i of o)if(i.startsWith("{{")&&i.endsWith("}}")){let a=document.createElement("span");a.setAttribute(e,i.substring(2,i.length-2)),s.appendChild(a)}else s.appendChild(document.createTextNode(i));t.replaceWith(s)},ss=(t,e)=>{let n=[],r=o=>{if(o.nodeType===Node.TEXT_NODE)o.textContent?.includes("{{")&&n.push(o);else{if(o?.hasAttribute?.(e))return;for(let s of ce(o))r(s)}};return r(t),n};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",as=new Set(is.toUpperCase().split(",")),cs="http://www.w3.org/2000/svg",kr=(t,e)=>{ne(t)?t.content.appendChild(e):t.appendChild(e)},gn=(t,e,n,r)=>{let o=t.t;if(o){let i=n&&as.has(o.toUpperCase())?document.createElementNS(cs,o.toLowerCase()):document.createElement(o),a=t.a;if(a)for(let f of Object.entries(a)){let p=f[0],l=f[1];p.startsWith("#")&&(l=p.substring(1),p="name"),i.setAttribute(lt(p,r),l)}let c=t.c;if(c)for(let f of c)gn(f,i,n,r);kr(e,i);return}let s=t.d;if(s){let i;switch(t.n??Node.TEXT_NODE){case Node.COMMENT_NODE:i=document.createComment(s);break;case Node.TEXT_NODE:i=document.createTextNode(s);break}if(i)kr(e,i);else throw new Error("unsupported node type.")}},Me=(t,e,n)=>{n??=re.getDefault();let r=document.createDocumentFragment();if(!T(t))return gn(t,r,!!e,n),r;for(let o of t)gn(o,r,!!e,n);return r};var Ir=(t,e={selector:"#app"},n)=>{H(e)&&(e={selector:"#app",template:e}),Pn(t)&&(t=t.context);let r=e.element?e.element:e.selector?document.querySelector(e.selector):null;if(!r||!Se(r))throw _(0);n||(n=re.getDefault());let o=()=>{for(let a of[...r.childNodes])P(a)},s=a=>{for(let c of a)r.appendChild(c)};if(e.template){let a=document.createRange().createContextualFragment(e.template);o(),s(a.childNodes),e.element=a}else if(e.json){let a=Me(e.json,e.isSVG,n);o(),s(a.childNodes)}return n.useInterpolation&&Bt(r,n),new bn(t,r,n).x(),k(r,()=>{ge(t)}),vt(t),{context:t,unmount:()=>{P(r)},unbind:()=>{te(r)}}},bn=class{Et;$e;o;h;p;constructor(e,n,r){this.Et=e,this.$e=n,this.o=r,this.h=new It([e],r),this.p=new St(this.h)}x(){this.p.G(this.$e)}};var Ke=t=>{if(T(t))return t.map(o=>Ke(o));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(o=>[o,t.getAttribute(o)])));let r=ce(t);return r.length>0&&(e.c=[...r].map(o=>Ke(o))),e};var Dr=(t,e,n={})=>{T(n)&&(n={props:n}),H(e)&&(e={template:e});let r=!1;if(e.element){let s=e.element;s.remove(),e.element=s}else if(e.selector){let s=document.querySelector(e.selector);if(!s)throw _(1,e.selector);s.remove(),e.element=s}else if(e.template){let s=document.createRange().createContextualFragment(e.template);e.element=s}else e.json&&(e.element=Me(e.json,e.isSVG,n.config),r=!0);e.element||(e.element=document.createDocumentFragment()),(n.useInterpolation??!0)&&Bt(e.element);let o=e.element;if(!r&&((e.isSVG??(Ye(o)&&o.hasAttribute?.("isSVG")))||Ye(o)&&o.querySelector("[isSVG]"))){let s=e.element.content,i=s?[...s.childNodes]:[...o.childNodes],a=Ke(i);e.element=Me(a,!0,n.config)}return{context:t,template:e.element,inheritAttrs:n.inheritAttrs??!0,props:n.props,defaultName:n.defaultName}};var Ur=t=>{let e,n={},r=(...o)=>{if(o.length<=2&&0 in o)throw _(4);return e&&!n.isStopped?e(...o):(e=ps(t,n),e(...o))};return r[G]=1,he(r,!0),r.stop=()=>n.ref?.stop?.(),K(()=>r.stop(),!0),r},ps=(t,e)=>{let n=e.ref??z(null);e.ref=n,e.isStopped=!1;let r=0,o=we(()=>{if(r>0){o(),e.isStopped=!0,F(n);return}n(t()),++r});return n.stop=o,n};var Hr=(t,e)=>{let n={},r,o=(...s)=>{if(s.length<=2&&0 in s)throw _(4);return r&&!n.isStopped?r(...s):(r=fs(t,e,n),r(...s))};return o[G]=1,he(o,!0),o.stop=()=>n.ref?.stop?.(),K(()=>o.stop(),!0),o},fs=(t,e,n)=>{let r=n.ref??z(null);n.ref=r,n.isStopped=!1;let o=0,s=a=>{if(o>0){r.stop(),n.isStopped=!0,F(r);return}r(e(...t.map(c=>c()))),++o},i=[];for(let a of t){let c=C(a,s);i.push(c)}return s(null),r.stop=()=>{i.forEach(a=>{a()})},r};var _r=(t,e)=>{let n={},r,o=(...s)=>{if(s.length<=2&&0 in s)throw _(4);return r&&!n.isStopped?r(...s):(r=ls(t,e,n),r(...s))};return o[G]=1,he(o,!0),o.stop=()=>n.ref?.stop?.(),K(()=>o.stop(),!0),o},ls=(t,e,n)=>{let r=n.ref??z(null);n.ref=r,n.isStopped=!1;let o=0;return r.stop=C(t,s=>{if(o>0){r.stop(),n.isStopped=!0,F(r);return}r(e(s)),++o},!0),r};var Br=t=>(t[at]=1,t);var Vr=(t,e)=>{if(!e)throw new Error("persist requires a string key.");let r=Ne(t)?Te:a=>a,o=()=>localStorage.setItem(e,JSON.stringify(J(t()))),s=localStorage.getItem(e);s!=null?t(r(JSON.parse(s))):o();let i=we(o);return K(()=>i,!0),t};var Tn=(t,...e)=>{let n="";return e.length===0?t.join():(t.forEach((r,o)=>{n+=r+e[o]}),n)},Pr=Tn;var jr=(t,e,n)=>{let r=[],o=()=>{e(t.map(i=>i()))};for(let i of t)r.push(C(i,o));n&&o();let s=()=>{for(let i of r)i()};return K(s,!0),s};var $r=t=>{if(!m(t))throw _(3,"observe");return t(void 0,void 0,2)};var Fr=t=>{En();try{t()}finally{vn()}},En=()=>{Ae.set||(Ae.set=new Set)},vn=()=>{let t=Ae.set;if(t){delete Ae.set;for(let e of t)try{F(e)}catch(n){console.error(n)}}};var qr=t=>{Re()?.onMounted.push(t)};
3
+ `;break;case"r":r+="\r";break;case"t":r+=" ";break;case"b":r+="\b";break;case"f":r+="\f";break;case"v":r+="\v";break;default:r+=c}else r+=c,o+=c}throw this.i("Unclosed `")}ft(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 r=e.node;for(;r.type===3||r.type===6&&r?.callee?.type===3;)r=r.type===3?r.object:r.callee.object;r.type=20}lt(e){if(!this.u(qn))return;let n=++this.e,r=!1;for(;this.e<this.r.length;){if(this.f===qn&&!r){let o=this.r.slice(n,this.e),s="";for(;++this.e<this.r.length;){let a=this.f;if(a>=97&&a<=122||a>=65&&a<=90||a>=48&&a<=57)s+=this.M;else break}let i;try{i=new RegExp(o,s)}catch(a){throw this.i(a.message)}return e.node={type:4,value:i,raw:this.r.slice(n-1,this.e)},e.node=this.F(e.node),e.node}this.u(Ot)?r=!0:r&&this.u(Nt)&&(r=!1),this.e+=this.u(bo)?2:1}throw this.i("Unclosed Regex")}},nr=t=>new sn(t).parse();var Do={"=>":(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,"&":(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},Uo={"-":t=>-t,"+":t=>+t,"!":t=>!t,"~":t=>~t,new:t=>t},ir=t=>{if(!t?.some(sr))return t;let e=[];return t.forEach(n=>sr(n)?e.push(...n):e.push(n)),e},rr=(...t)=>ir(t),cn=(t,e)=>{if(!t)return e;let n=Object.create(e??{});return n.$event=t,n},Ho={"++":(t,e)=>{let n=t[e];if(m(n)){let r=n();return n(++r),r}return++t[e]},"--":(t,e)=>{let n=t[e];if(m(n)){let r=n();return n(--r),r}return--t[e]}},_o={"++":(t,e)=>{let n=t[e];if(m(n)){let r=n();return n(r+1),r}return t[e]++},"--":(t,e)=>{let n=t[e];if(m(n)){let r=n();return n(r-1),r}return t[e]--}},or={"=":(t,e,n)=>{let r=t[e];return m(r)?r(n):t[e]=n},"+=":(t,e,n)=>{let r=t[e];return m(r)?r(r()+n):t[e]+=n},"-=":(t,e,n)=>{let r=t[e];return m(r)?r(r()-n):t[e]-=n},"*=":(t,e,n)=>{let r=t[e];return m(r)?r(r()*n):t[e]*=n},"/=":(t,e,n)=>{let r=t[e];return m(r)?r(r()/n):t[e]/=n},"%=":(t,e,n)=>{let r=t[e];return m(r)?r(r()%n):t[e]%=n},"**=":(t,e,n)=>{let r=t[e];return m(r)?r(r()**n):t[e]**=n},"<<=":(t,e,n)=>{let r=t[e];return m(r)?r(r()<<n):t[e]<<=n},">>=":(t,e,n)=>{let r=t[e];return m(r)?r(r()>>n):t[e]>>=n},">>>=":(t,e,n)=>{let r=t[e];return m(r)?r(r()>>>n):t[e]>>>=n},"|=":(t,e,n)=>{let r=t[e];return m(r)?r(r()|n):t[e]|=n},"&=":(t,e,n)=>{let r=t[e];return m(r)?r(r()&n):t[e]&=n},"^=":(t,e,n)=>{let r=t[e];return m(r)?r(r()^n):t[e]^=n}},kt=(t,e)=>U(t)?t.bind(e):t,pn=class{m;Ve;ke;Ie;O;De;Ue;constructor(e,n,r,o,s){this.m=T(e)?e:[e],this.Ve=n,this.ke=r,this.Ie=o,this.Ue=!!s}Pe(e,n){if(n&&e in n)return n;for(let r of this.m)if(e in r)return r}2(e,n,r){let o=e.name;if(o==="$root")return this.m[this.m.length-1];if(o==="$parent")return this.m[1];if(o==="$ctx")return[...this.m];if(r&&o in r)return this.O=r[o],kt(V(r[o]),r);for(let i of this.m)if(o in i)return this.O=i[o],kt(V(i[o]),i);let s=this.Ve;if(s&&o in s)return this.O=s[o],kt(V(s[o]),s)}5(e,n,r){return this.m[0]}0(e,n,r){return this.Be(n,r,rr,...e.body)}1(e,n,r){return this.R(n,r,(...o)=>o.pop(),...e.expressions)}3(e,n,r){let{obj:o,key:s}=this.ae(e,n,r),i=o?.[s];return this.O=i,kt(V(i),o)}4(e,n,r){return e.value}6(e,n,r){let o=(i,...a)=>U(i)?i(...ir(a)):i,s=this.R(++n,r,o,e.callee,...e.arguments);return this.O=s,s}7(e,n,r){return this.R(n,r,Uo[e.operator],e.argument)}8(e,n,r){let o=Do[e.operator];switch(e.operator){case"||":case"&&":case"??":return o(()=>this.g(e.left,n,r),()=>this.g(e.right,n,r))}return this.R(n,r,o,e.left,e.right)}9(e,n,r){return this.Be(++n,r,rr,...e.elements)}10(e,n,r){let o={},s=(...i)=>{i.forEach(a=>{Object.assign(o,a)})};return this.R(++n,r,s,...e.properties),o}11(e,n,r){return this.R(n,r,o=>this.g(o?e.consequent:e.alternate,n,r),e.test)}12(e,n,r){let o={},s=p=>p?.type!==15,i=this.Ie??(()=>!1),a=n===0&&this.Ue,c=p=>this._e(a,e.key,n,cn(p,r)),f=p=>this._e(a,e.value,n,cn(p,r));if(e.shorthand){let p=e.key.name;o[p]=s(e.key)&&i(p,n)?c:c()}else if(e.computed){let p=V(c());o[p]=s(e.value)&&i(p,n)?f:f()}else{let p=e.key.type===4?e.key.value:e.key.name;o[p]=s(e.value)&&i(p,n)?()=>f:f()}return o}ae(e,n,r){let o=this.g(e.object,n,r),s=e.computed?this.g(e.property,n,r):e.property.name;return{obj:o,key:s}}13(e,n,r){let o=e.argument,s=e.operator,i=e.prefix?Ho:_o;if(o.type===2){let a=o.name,c=this.Pe(a,r);return Y(c)?void 0:i[s](c,a)}if(o.type===3){let{obj:a,key:c}=this.ae(o,n,r);return i[s](a,c)}}16(e,n,r){let o=e.left,s=e.operator;if(o.type===2){let i=o.name,a=this.Pe(i,r);if(Y(a))return;let c=this.g(e.right,n,r);return or[s](a,i,c)}if(o.type===3){let{obj:i,key:a}=this.ae(o,n,r),c=this.g(e.right,n,r);return or[s](i,a,c)}}14(e,n,r){let o=this.g(e.argument,n,r);return T(o)&&(o.s=ar),o}17(e,n,r){return this[6]({type:6,callee:e.tag,arguments:[{type:9,elements:e.quasi.quasis},...e.quasi.expressions]},n,r)}19(e,n,r){let o=(...s)=>s.reduce((i,a,c)=>i+=a+e.quasis[c+1].value.cooked,e.quasis[0].value.cooked);return this.R(n,r,o,...e.expressions)}18(e,n,r){return e.value.cooked}20(e,n,r){let o=(s,...i)=>new s(...i);return this.R(n,r,o,e.callee,...e.arguments)}15(e,n,r){return(...o)=>{let s=Object.create(r??{}),i=e.params;if(i){let a=0;for(let c of i)s[c.name]=o[a++]}return this.g(e.body,n,s)}}g(e,n,r){let o=V(this[e.type](e,n,r));return this.De=e.type,o}_e(e,n,r,o){let s=this.g(n,r,o);return e&&this.He()?this.O:s}He(){let e=this.De;return(e===2||e===3||e===6)&&m(this.O)}eval(e,n){let{value:r,refs:o}=mt(()=>this.g(e,-1,n)),s={value:r,refs:o};return this.He()&&(s.ref=this.O),s}R(e,n,r,...o){let s=o.map(i=>i&&this.g(i,e,n));return r(...s)}Be(e,n,r,...o){let s=this.ke;if(!s)return this.R(e,n,r,...o);let i=o.map((a,c)=>a&&(a.type!==15&&s(c,e)?f=>this.g(a,e,cn(f,n)):this.g(a,e,n)));return r(...i)}},ar=Symbol("s"),sr=t=>t?.s===ar,cr=(t,e,n,r,o,s,i)=>new pn(e,n,r,o,i).eval(t,s);var pr={},It=class{m;o;constructor(e,n){this.m=e,this.o=n}w(e){this.m=[e,...this.m]}me(){return this.m.map(n=>n.components).filter(n=>!!n).reverse().reduce((n,r)=>{for(let[o,s]of Object.entries(r))n[o.toUpperCase()]=s;return n},{})}v(e,n,r,o,s){let i=z([]),a=[],c=()=>{for(let u of a)u();a.length=0},f={value:i,stop:c,refs:[],context:this.m[0]};if($(e))return f;let p=this.o.globalContext,l=[],b=(u,y,v,S)=>{try{let h=cr(u,y,p,n,r,S,o);return v&&l.push(...h.refs),{value:h.value,refs:h.refs,ref:h.ref}}catch(h){I(6,`evaluation error: ${e}`,h)}return{value:void 0,refs:[]}};try{let u=pr[e]??nr("["+e+"]");pr[e]=u;let y=this.m,v=()=>{l.splice(0),c();let S=u.elements.map((h,A)=>n?.(A,-1)?{value:O=>b(h,y,!1,{$event:O}).value,refs:[]}:b(h,y,!0));if(!s)for(let h of l){let A=C(h,v);a.push(A)}i(S.map(h=>h.value)),f.refs=S.map(h=>h.ref)};v()}catch(u){I(6,`parse error: ${e}`,u)}return f}k(){return this.m}je=[];Y(e){this.je.push(this.m),this.m=e}C(e,n){try{this.Y(e),n()}finally{this.bt()}}bt(){this.m=this.je.pop()??[]}};var fr="http://www.w3.org/1999/xlink",Bo={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 Vo(t){return!!t||t===""}var fn={onChange:(t,e,n,r,o,s)=>{if(r){s&&s.includes("camel")&&(r=B(r)),Dt(t,r,e[0],o);return}let i=e.length;for(let a=0;a<i;++a){let c=e[a];if(T(c)){let f=n?.[a]?.[0],p=c[0],l=c[1];Dt(t,p,l,f)}else if(w(c))for(let f of Object.entries(c)){let p=f[0],l=f[1],b=n?.[a],u=b&&p in b?p:void 0;Dt(t,p,l,u)}else{let f=n?.[a],p=e[a++],l=e[a];Dt(t,p,l,f)}}}},Dt=(t,e,n,r)=>{if(r&&r!==e&&t.removeAttribute(r),Y(e)){I(3,name,t);return}if(!H(e)){I(6,`Attribute key is not string at ${t.outerHTML}`,e);return}if(e.startsWith("xlink:")){Y(n)?t.removeAttributeNS(fr,e.slice(6,e.length)):t.setAttributeNS(fr,e,n);return}let o=e in Bo;Y(n)||o&&!Vo(n)?t.removeAttribute(e):t.setAttribute(e,o?"":n)};var ln={onChange:(t,e,n)=>{let r=e.length;for(let o=0;o<r;++o){let s=e[o],i=n?.[o];if(T(s)){let a=s.length;for(let c=0;c<a;++c)lr(t,s[c],i?.[c])}else lr(t,s,i)}}},lr=(t,e,n)=>{let r=t.classList,o=H(e),s=H(n);if(e&&!o){if(n&&!s)for(let i in n)i in e||r.remove(i);for(let i in e)e[i]&&r.add(i)}else o?n!==e&&(s&&r.remove(...n?.split(",")),r.add(...e.split(","))):n&&s&&r.remove(...n?.split(","))};var ur={onChange:(t,e)=>{let[n,r]=e;U(r)?r(t,n):t.innerHTML=n?.toString()}};function Po(t,e){if(t.length!==e.length)return!1;let n=!0;for(let r=0;n&&r<t.length;r++)n=pe(t[r],e[r]);return n}function pe(t,e){if(t===e)return!0;let n=Ft(t),r=Ft(e);if(n||r)return n&&r?t.getTime()===e.getTime():!1;if(n=Je(t),r=Je(e),n||r)return t===e;if(n=T(t),r=T(e),n||r)return n&&r?Po(t,e):!1;if(n=w(t),r=w(e),n||r){if(!n||!r)return!1;let o=Object.keys(t).length,s=Object.keys(e).length;if(o!==s)return!1;for(let i in t){let a=t.hasOwnProperty(i),c=e.hasOwnProperty(i);if(a&&!c||!a&&c||!pe(t[i],e[i]))return!1}}return String(t)===String(e)}function Ut(t,e){return t.findIndex(n=>pe(n,e))}var mr=t=>{let e=parseFloat(t);return isNaN(e)?t:e};var Ht=t=>{if(!m(t))throw _(3,"pause");t(void 0,void 0,3)};var _t=t=>{if(!m(t))throw _(3,"resume");t(void 0,void 0,4)};var yr={onChange:(t,e)=>{jo(t,e[0])},onBind:(t,e,n,r,o,s)=>$o(t,e,s)},jo=(t,e)=>{let n=Tr(t);if(n&&hr(t))T(e)?e=Ut(e,fe(t))>-1:X(e)?e=e.has(fe(t)):e=Go(t,e),t.checked=e;else if(n&&gr(t))t.checked=pe(e,fe(t));else if(n||Er(t))br(t)?t.value!==e?.toString()&&(t.value=e):t.value!==e&&(t.value=e);else if(vr(t)){let r=t.options,o=r.length,s=t.multiple;for(let i=0;i<o;i++){let a=r[i],c=fe(a);if(s)T(e)?a.selected=Ut(e,c)>-1:a.selected=e.has(c);else if(pe(fe(a),e)){t.selectedIndex!==i&&(t.selectedIndex=i);return}}!s&&t.selectedIndex!==-1&&(t.selectedIndex=-1)}else I(7,t)},tt=t=>(m(t)&&(t=t()),U(t)&&(t=t()),t?H(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}),hr=t=>t.type==="checkbox",gr=t=>t.type==="radio",br=t=>t.type==="number"||t.type==="range",Tr=t=>t.tagName==="INPUT",Er=t=>t.tagName==="TEXTAREA",vr=t=>t.tagName==="SELECT",$o=(t,e,n)=>{let r=e.value,o=tt(n?.join(",")),s=tt(r()[1]),i={int:o.int||o.int,lazy:o.lazy||s.lazy,number:o.number||s.number,trim:o.trim||s.trim},a=e.refs[0];if(!a)return I(8,t),()=>{};let c=Tr(t);return c&&hr(t)?qo(t,a):c&&gr(t)?Jo(t,a):c||Er(t)?Fo(t,i,a,r):vr(t)?Qo(t,a,r):(I(7,t),()=>{})},dr=/[.,' ·٫]/,Fo=(t,e,n,r)=>{let s=e.lazy?"change":"input",i=br(t),a=()=>{!e.trim&&!tt(r()[1]).trim||(t.value=t.value.trim())},c=b=>{let u=b.target;u.composing=1},f=b=>{let u=b.target;u.composing&&(u.composing=0,u.dispatchEvent(new Event(s)))},p=()=>{t.removeEventListener(s,l),t.removeEventListener("change",a),t.removeEventListener("compositionstart",c),t.removeEventListener("compositionend",f),t.removeEventListener("change",f)},l=b=>{let u=b.target;if(!u||u.composing)return;let y=u.value,v=tt(r()[1]);if(i||v.number||v.int){if(v.int)y=parseInt(y);else{if(dr.test(y[y.length-1])&&y.split(dr).length===2){if(y+="0",y=parseFloat(y),isNaN(y))y="";else if(n()===y)return}y=parseFloat(y)}isNaN(y)&&(y=""),t.value=y}else v.trim&&(y=y.trim());n(y)};return t.addEventListener(s,l),t.addEventListener("change",a),t.addEventListener("compositionstart",c),t.addEventListener("compositionend",f),t.addEventListener("change",f),p},qo=(t,e)=>{let n="change",r=()=>{t.removeEventListener(n,o)},o=()=>{let s=fe(t),i=t.checked,a=e();if(T(a)){let c=Ut(a,s),f=c!==-1;i&&!f?a.push(s):!i&&f&&a.splice(c,1)}else X(a)?i?a.add(s):a.delete(s):e(Wo(t,i))};return t.addEventListener(n,o),r},fe=t=>"_value"in t?t._value:t.value,xr="trueValue",zo="falseValue",Cr="true-value",Ko="false-value",Wo=(t,e)=>{let n=e?xr:zo;if(n in t)return t[n];let r=e?Cr:Ko;return t.hasAttribute(r)?t.getAttribute(r):e},Go=(t,e)=>{if(xr in t)return pe(e,t.trueValue);let r=Cr;return t.hasAttribute(r)?pe(e,t.getAttribute(r)):pe(e,!0)},Jo=(t,e)=>{let n="change",r=()=>{t.removeEventListener(n,o)},o=()=>{let s=fe(t);e(s)};return t.addEventListener(n,o),r},Qo=(t,e,n)=>{let r="change",o=()=>{t.removeEventListener(r,s)},s=()=>{let a=tt(n()[1]).number,c=Array.prototype.filter.call(t.options,f=>f.selected).map(f=>a?mr(fe(f)):fe(f));if(t.multiple){let f=e();try{if(Ht(e),X(f)){f.clear();for(let p of c)f.add(p)}else T(f)?(f.splice(0),f.push(...c)):e(c)}finally{_t(e),F(e)}}else e(c[0])};return t.addEventListener(r,s),o};var Xo=["stop","prevent","capture","self","once","left","right","middle","passive"],Yo=t=>{let e={};if($(t))return;let n=t.split(",");for(let r of Xo)e[r]=n.includes(r);return e},mn={isLazy:(t,e)=>e===-1&&t%2===0,isLazyKey:(t,e)=>e===0&&!t.endsWith("_flags"),once:!1,collectRefObj:!0,onBind:(t,e,n,r,o,s)=>{if(o){let p=e.value(),l=V(o.value()[0]);return H(l)?un(t,B(l),()=>e.value()[0],s?.join(",")??p[1]):()=>{}}else if(r){let p=e.value();return un(t,B(r),()=>e.value()[0],s?.join(",")??p[1])}let i=[],a=()=>{i.forEach(p=>p())},c=e.value(),f=c.length;for(let p=0;p<f;++p){let l=c[p];if(U(l)&&(l=l()),w(l))for(let b of Object.entries(l)){let u=b[0],y=()=>{let S=e.value()[p];return U(S)&&(S=S()),S=S[u],U(S)&&(S=S()),S},v=l[u+"_flags"];i.push(un(t,u,y,v))}else I(2,name,t)}return a}},Zo=(t,e)=>{if(t.startsWith("keydown")||t.startsWith("keyup")||t.startsWith("keypress")){e??="";let n=t.split(".").concat(e.split(","));t=n[0];let r=n[1],o=n.includes("ctrl"),s=n.includes("shift"),i=n.includes("alt"),a=n.includes("meta"),c=f=>!(o&&!f.ctrlKey||s&&!f.shiftKey||i&&!f.altKey||a&&!f.metaKey);return r?[t,f=>c(f)?f.key.toUpperCase()===r.toUpperCase():!1]:[t,c]}return[t,n=>!0]},un=(t,e,n,r)=>{if($(e))return I(5,name,t),()=>{};let o=Yo(r),s=o?{capture:o.capture,passive:o.passive,once:o.once}:void 0,i;[e,i]=Zo(e,r);let a=p=>{if(!i(p)||!n&&e==="submit"&&o?.prevent)return;let l=n(p);U(l)&&(l=l(p)),U(l)&&l(p)},c=()=>{t.removeEventListener(e,f,s)},f=p=>{if(!o){a(p);return}try{if(o.left&&p.button!==1||o.middle&&p.button!==2||o.right&&p.button!==3||o.self&&p.target!==t)return;o.stop&&p.stopPropagation(),o.prevent&&p.preventDefault(),a(p)}finally{o.once&&c()}};return t.addEventListener(e,f,s),c};var Rr={onChange:(t,e,n,r,o,s)=>{if(r){s&&s.includes("camel")&&(r=B(r)),ze(t,r,e[0]);return}let i=e.length;for(let a=0;a<i;++a){let c=e[a];if(T(c)){let f=c[0],p=c[1];ze(t,f,p)}else if(w(c))for(let f of Object.entries(c)){let p=f[0],l=f[1];ze(t,p,l)}else{let f=e[a++],p=e[a];ze(t,f,p)}}}};function es(t){return!!t||t===""}var ze=(t,e,n)=>{if(Y(e)){I(3,name,t);return}if(e==="innerHTML"||e==="textContent"){let s=[...t.childNodes];setTimeout(()=>s.forEach(te),1),t[e]=n??"";return}let r=t.tagName;if(e==="value"&&r!=="PROGRESS"&&!r.includes("-")){t._value=n;let s=r==="OPTION"?t.getAttribute("value"):t.value,i=n??"";s!==i&&(t.value=i),n==null&&t.removeAttribute(e);return}let o=!1;if(n===""||n==null){let s=typeof t[e];s==="boolean"?n=es(n):n==null&&s==="string"?(n="",o=!0):s==="number"&&(n=0,o=!0)}try{t[e]=n}catch(s){o||I(4,e,r,n,s)}o&&t.removeAttribute(e)};var Sr={once:!0,onBind:(t,e,n)=>{let r=e.value()[0],o=T(r),s=e.refs[0];return o?r.push(t):s?s?.(t):e.context[n]=t,()=>{if(o){let i=r.indexOf(t);i!==-1&&r.splice(i,1)}else s?.(null)}}};var wr={onChange:(t,e)=>{let n=me(t).data,r=n._ord;xn(r)&&(r=n._ord=t.style.display),!!e[0]?t.style.display=r:t.style.display="none"}};var hn={onChange:(t,e,n)=>{let r=e.length;for(let o=0;o<r;++o){let s=e[o],i=n?.[o];if(T(s)){let a=s.length;for(let c=0;c<a;++c)Ar(t,s[c],i?.[c])}else Ar(t,s,i)}}},Ar=(t,e,n)=>{let r=t.style,o=H(e);if(e&&!o){if(n&&!H(n))for(let s in n)e[s]==null&&yn(r,s,"");for(let s in e)yn(r,s,e[s])}else{let s=r.display;if(o?n!==e&&(r.cssText=e):n&&t.removeAttribute("style"),"_ord"in me(t).data)return;r.display=s}},Or=/\s*!important$/;function yn(t,e,n){if(T(n))n.forEach(r=>{yn(t,e,r)});else if(n==null&&(n=""),e.startsWith("--"))t.setProperty(e,n);else{let r=ts(t,e);Or.test(n)?t.setProperty(_e(r),n.replace(Or,""),"important"):t[r]=n}}var Nr=["Webkit","Moz","ms"],dn={};function ts(t,e){let n=dn[e];if(n)return n;let r=B(e);if(r!=="filter"&&r in t)return dn[e]=r;r=Ze(r);for(let o=0;o<Nr.length;o++){let s=Nr[o]+r;if(s in t)return dn[e]=s}return e}var J=t=>ns(V(t)),ns=t=>{if(!t||!w(t))return t;if(T(t))return t.map(J);if(X(t)){let n=new Set;for(let r of t.keys())n.add(J(r));return n}if(ue(t)){let n=new Map;for(let r of n)n.set(J(r[0]),J(r[1]));return n}let e={...t};for(let n of Object.entries(e))e[n[0]]=J(n[1]);return e};var Mr={onChange:(t,e)=>{let n=e[0];t.textContent=X(n)?JSON.stringify(J([...n])):ue(n)?JSON.stringify(J([...n])):w(n)?JSON.stringify(J(n)):n?.toString()??""}};var Lr={onChange:(t,e)=>{ze(t,"value",e[0])}};var Ne=t=>t?.[it]===1;var Te=t=>{if(Be(t))return t;let e;if(m(t)?(e=t,t=e()):e=z(t),t instanceof Node||t instanceof Date||t instanceof RegExp||t instanceof Promise||t instanceof Error)return e;if(e[it]=1,T(t)){let n=t.length;for(let r=0;r<n;++r){let o=t[r];Ne(o)||(t[r]=Te(o))}return e}if(!w(t))return e;for(let n of Object.entries(t)){let r=n[1];if(Ne(r))continue;let o=n[0];Je(o)||(t[o]=Te(r))}return e};var re=class t{static getDefault(){return t.Fe??(t.Fe=new t)}H={};l={};Ze=()=>Object.keys(this.H).filter(e=>e.length===1||!e.startsWith(":"));he=new Map;ge=new Map;static Fe;static Tt="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";forGrowThreshold=10;globalContext;useInterpolation=!0;constructor(e){if(this.setDirectives("r-"),e){this.globalContext=e;return}this.globalContext=this.xt()}xt(){let e={},n=globalThis;for(let r of t.Tt.split(","))e[r]=n[r];return e.ref=Te,e.sref=z,e.flatten=J,e}addComponent(...e){for(let n of e){if(!n.defaultName){Qe.warning("Registered component's default name is not defined",n);continue}this.he.set(Ze(n.defaultName),n),this.ge.set(Ze(n.defaultName).toLocaleUpperCase(),n)}}setDirectives(e){this.H={".":Rr,":":fn,"@":mn,[`${e}on`]:mn,[`${e}bind`]:fn,[`${e}html`]:ur,[`${e}text`]:Mr,[`${e}show`]:wr,[`${e}model`]:yr,":style":hn,[`${e}bind:style`]:hn,":class":ln,[`${e}bind:class`]:ln,":ref":Sr,":value":Lr,teleport:Rt},this.l={for:`${e}for`,if:`${e}if`,else:`${e}else`,elseif:`${e}else-if`,pre:`${e}pre`,inherit:`${e}inherit`,text:`${e}text`,props:":props",propsOnce:":props-once",bind:`${e}bind`,on:`${e}on`,keyBind:":key",key:"key",is:":is",teleport:`${e}teleport`,dynamic:"_d_"}}updateDirectives(e){e(this.H,this.l)}};var Bt=(t,e)=>{if(!t)return;let n=(e??re.getDefault()).l;for(let r of ss(t,n.pre))os(r,n.text)},rs=/({{[^]*?}})/g,os=(t,e)=>{let n=t.textContent;if(!n)return;let r=rs,o=n.split(r);if(o.length<=1)return;if(t.parentElement?.childNodes.length===1&&o.length===3){let i=o[1];if($(o[0])&&$(o[2])&&i.startsWith("{{")&&i.endsWith("}}")){let a=t.parentElement;a.setAttribute(e,i.substring(2,i.length-2)),a.innerText="";return}}let s=document.createDocumentFragment();for(let i of o)if(i.startsWith("{{")&&i.endsWith("}}")){let a=document.createElement("span");a.setAttribute(e,i.substring(2,i.length-2)),s.appendChild(a)}else s.appendChild(document.createTextNode(i));t.replaceWith(s)},ss=(t,e)=>{let n=[],r=o=>{if(o.nodeType===Node.TEXT_NODE)o.textContent?.includes("{{")&&n.push(o);else{if(o?.hasAttribute?.(e))return;for(let s of ce(o))r(s)}};return r(t),n};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",as=new Set(is.toUpperCase().split(",")),cs="http://www.w3.org/2000/svg",kr=(t,e)=>{ne(t)?t.content.appendChild(e):t.appendChild(e)},gn=(t,e,n,r)=>{let o=t.t;if(o){let i=n&&as.has(o.toUpperCase())?document.createElementNS(cs,o.toLowerCase()):document.createElement(o),a=t.a;if(a)for(let f of Object.entries(a)){let p=f[0],l=f[1];p.startsWith("#")&&(l=p.substring(1),p="name"),i.setAttribute(lt(p,r),l)}let c=t.c;if(c)for(let f of c)gn(f,i,n,r);kr(e,i);return}let s=t.d;if(s){let i;switch(t.n??Node.TEXT_NODE){case Node.COMMENT_NODE:i=document.createComment(s);break;case Node.TEXT_NODE:i=document.createTextNode(s);break}if(i)kr(e,i);else throw new Error("unsupported node type.")}},Me=(t,e,n)=>{n??=re.getDefault();let r=document.createDocumentFragment();if(!T(t))return gn(t,r,!!e,n),r;for(let o of t)gn(o,r,!!e,n);return r};var Ir=(t,e={selector:"#app"},n)=>{H(e)&&(e={selector:"#app",template:e}),Pn(t)&&(t=t.context);let r=e.element?e.element:e.selector?document.querySelector(e.selector):null;if(!r||!Se(r))throw _(0);n||(n=re.getDefault());let o=()=>{for(let a of[...r.childNodes])P(a)},s=a=>{for(let c of a)r.appendChild(c)};if(e.template){let a=document.createRange().createContextualFragment(e.template);o(),s(a.childNodes),e.element=a}else if(e.json){let a=Me(e.json,e.isSVG,n);o(),s(a.childNodes)}return n.useInterpolation&&Bt(r,n),new bn(t,r,n).x(),k(r,()=>{ge(t)}),vt(t),{context:t,unmount:()=>{P(r)},unbind:()=>{te(r)}}},bn=class{Et;$e;o;h;p;constructor(e,n,r){this.Et=e,this.$e=n,this.o=r,this.h=new It([e],r),this.p=new St(this.h)}x(){this.p.G(this.$e)}};var Ke=t=>{if(T(t))return t.map(o=>Ke(o));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(o=>[o,t.getAttribute(o)])));let r=ce(t);return r.length>0&&(e.c=[...r].map(o=>Ke(o))),e};var Dr=(t,e,n={})=>{T(n)&&(n={props:n}),H(e)&&(e={template:e});let r=!1;if(e.element){let s=e.element;s.remove(),e.element=s}else if(e.selector){let s=document.querySelector(e.selector);if(!s)throw _(1,e.selector);s.remove(),e.element=s}else if(e.template){let s=document.createRange().createContextualFragment(e.template);e.element=s}else e.json&&(e.element=Me(e.json,e.isSVG,n.config),r=!0);e.element||(e.element=document.createDocumentFragment()),(n.useInterpolation??!0)&&Bt(e.element);let o=e.element;if(!r&&((e.isSVG??(Ye(o)&&o.hasAttribute?.("isSVG")))||Ye(o)&&o.querySelector("[isSVG]"))){let s=e.element.content,i=s?[...s.childNodes]:[...o.childNodes],a=Ke(i);e.element=Me(a,!0,n.config)}return{context:t,template:e.element,inheritAttrs:n.inheritAttrs??!0,props:n.props,defaultName:n.defaultName}};var Ur=t=>{let e,n={},r=(...o)=>{if(o.length<=2&&0 in o)throw _(4);return e&&!n.isStopped?e(...o):(e=ps(t,n),e(...o))};return r[G]=1,he(r,!0),r.stop=()=>n.ref?.stop?.(),K(()=>r.stop(),!0),r},ps=(t,e)=>{let n=e.ref??z(null);e.ref=n,e.isStopped=!1;let r=0,o=we(()=>{if(r>0){o(),e.isStopped=!0,F(n);return}n(t()),++r});return n.stop=o,n};var Hr=(t,e)=>{let n={},r,o=(...s)=>{if(s.length<=2&&0 in s)throw _(4);return r&&!n.isStopped?r(...s):(r=fs(t,e,n),r(...s))};return o[G]=1,he(o,!0),o.stop=()=>n.ref?.stop?.(),K(()=>o.stop(),!0),o},fs=(t,e,n)=>{let r=n.ref??z(null);n.ref=r,n.isStopped=!1;let o=0,s=a=>{if(o>0){r.stop(),n.isStopped=!0,F(r);return}r(e(...t.map(c=>c()))),++o},i=[];for(let a of t){let c=C(a,s);i.push(c)}return s(null),r.stop=()=>{i.forEach(a=>{a()})},r};var _r=(t,e)=>{let n={},r,o=(...s)=>{if(s.length<=2&&0 in s)throw _(4);return r&&!n.isStopped?r(...s):(r=ls(t,e,n),r(...s))};return o[G]=1,he(o,!0),o.stop=()=>n.ref?.stop?.(),K(()=>o.stop(),!0),o},ls=(t,e,n)=>{let r=n.ref??z(null);n.ref=r,n.isStopped=!1;let o=0;return r.stop=C(t,s=>{if(o>0){r.stop(),n.isStopped=!0,F(r);return}r(e(s)),++o},!0),r};var Br=t=>(t[at]=1,t);var Vr=(t,e)=>{if(!e)throw new Error("persist requires a string key.");let r=Ne(t)?Te:a=>a,o=()=>localStorage.setItem(e,JSON.stringify(J(t()))),s=localStorage.getItem(e);s!=null?t(r(JSON.parse(s))):o();let i=we(o);return K(()=>i,!0),t};var Tn=(t,...e)=>{let n="";return e.length===0?t.join():(t.forEach((r,o)=>{n+=r+e[o]}),n)},Pr=Tn;var jr=(t,e,n)=>{let r=[],o=()=>{e(t.map(i=>i()))};for(let i of t)r.push(C(i,o));n&&o();let s=()=>{for(let i of r)i()};return K(s,!0),s};var $r=t=>{if(!m(t))throw _(3,"observe");return t(void 0,void 0,2)};var Fr=t=>{En();try{t()}finally{vn()}},En=()=>{Ae.set||(Ae.set=new Set)},vn=()=>{let t=Ae.set;if(t){delete Ae.set;for(let e of t)try{F(e)}catch(n){console.error(n)}}};var qr=t=>{Re()?.onMounted.push(t)};
@@ -1,3 +1,3 @@
1
- var D=t=>typeof t=="function",U=t=>typeof t=="string",bn=t=>typeof t>"u",Y=t=>t==null||typeof t>"u",j=t=>typeof t!="string"||!t?.trim(),kr=Object.prototype.toString,Ut=t=>kr.call(t),ue=t=>Ut(t)==="[object Map]",X=t=>Ut(t)==="[object Set]",Ht=t=>Ut(t)==="[object Date]",Ke=t=>typeof t=="symbol",T=Array.isArray,w=t=>t!==null&&typeof t=="object";var Tn={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."},H=(t,...e)=>{let n=Tn[t];return new Error(D(n)?n.call(Tn,...e):n)};var Ne=Symbol(":regor");var xe=t=>{let e=t[Ne];if(e)return e;let n={unbinders:[],data:{}};return t[Ne]=n,n};var _=(t,e)=>{xe(t).unbinders.push(e)};var rt=[],En=()=>{let t={onMounted:[],onUnmounted:[]};return rt.push(t),t},Ce=t=>{let e=rt[rt.length-1];if(!e&&!t)throw H(2);return e},vn=t=>{let e=Ce();return t&&Bt(t),rt.pop(),e},_t=Symbol("csp"),Bt=t=>{let e=t,n=e[_t];if(n){let r=Ce();if(n===r)return;r.onMounted.length>0&&n.onMounted.push(...r.onMounted),r.onUnmounted.length>0&&n.onUnmounted.push(...r.onUnmounted);return}e[_t]=Ce()},ot=t=>t[_t];var W=(t,e)=>{Ce(e)?.onUnmounted.push(t)};var st=Symbol("ref"),G=Symbol("sref"),it=Symbol("raw");var m=t=>t?.[G]===1;var R=(t,e,n)=>{if(!m(t))throw H(3,"observe");n&&e(t());let o=t(void 0,void 0,0,e);return W(o,!0),o};var se=t=>{let e=[t];for(;e.length>0;){let n=e.shift();Ir(n);let r=n.childNodes;if(r)for(let o of r)e.push(o)}},Ir=t=>{let e=t[Ne];if(e){for(let n of e.unbinders)n();e.unbinders.splice(0),delete t[Ne]}};var $=t=>{t.remove(),setTimeout(()=>se(t),1)};var xn={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,r)=>({msg:`Failed setting prop "${t}" on <${e.toLowerCase()}>: value ${n} is invalid.`,args:[r]}),5:(t,e)=>`${t} binding missing event type at ${e.outerHTML}`,6:(t,e)=>({msg:t,args:[e]})},k=(t,...e)=>{let n=xn[t],r=D(n)?n.call(xn,...e):n,o=at.warning;o&&(U(r)?o(r):o(r,...r.args))},at={warning:console.warn};var pt={},ct={},Cn=1,Rn=t=>{let e=(Cn++).toString();return pt[e]=t,ct[e]=0,e},Vt=t=>{ct[t]+=1},Pt=t=>{--ct[t]===0&&(delete pt[t],delete ct[t])},Sn=t=>pt[t],jt=()=>Cn!==1&&Object.keys(pt).length>0,We="r-switch",Dr=t=>{let e=t.filter(r=>Re(r)).map(r=>[...r.querySelectorAll("[r-switch]")].map(o=>o.getAttribute(We))),n=new Set;return e.forEach(r=>{r.forEach(o=>o&&n.add(o))}),[...n]},Me=(t,e)=>{if(!jt())return;let n=Dr(e);n.length!==0&&(n.forEach(Vt),_(t,()=>{n.forEach(Pt)}))};var $t=(t,e,n,r)=>{let o=[];for(let s of t){let i=s.cloneNode(!0);n.insertBefore(i,r),o.push(i)}de(e,o)},Ft=Symbol("r-if"),wn=Symbol("r-else"),An=t=>t[wn]===1,ft=class{p;P;q;K;z;b;T;constructor(e){this.p=e,this.P=e.o.l.if,this.q=Ie(e.o.l.if),this.K=e.o.l.else,this.z=e.o.l.elseif,this.b=e.o.l.for,this.T=e.o.l.pre}qe(e,n){let r=e.parentElement;for(;r!==null&&r!==document.documentElement;){if(r.hasAttribute(n))return!0;r=r.parentElement}return!1}N(e){let n=e.hasAttribute(this.P),r=me(e,this.q);for(let o of r)this.x(o);return n}W(e){return e[Ft]?!0:(e[Ft]=!0,me(e,this.q).forEach(n=>n[Ft]=!0),!1)}x(e){if(e.hasAttribute(this.T)||this.W(e)||this.qe(e,this.b))return;let n=e.getAttribute(this.P);if(!n){k(0,this.P,e);return}e.removeAttribute(this.P),this.k(e,n)}B(e,n,r){let o=ke(e),s=e.parentNode,i=document.createComment(`__begin__ :${n}${r??""}`);s.insertBefore(i,e),Me(i,o),o.forEach(c=>{$(c)}),e.remove(),n!=="if"&&(e[wn]=1);let a=document.createComment(`__end__ :${n}${r??""}`);return s.insertBefore(a,i.nextSibling),{nodes:o,parent:s,commentBegin:i,commentEnd:a}}pe(e,n){if(!e)return[];let r=e.nextElementSibling;if(e.hasAttribute(this.K)){e.removeAttribute(this.K);let{nodes:o,parent:s,commentBegin:i,commentEnd:a}=this.B(e,"else");return[{mount:()=>{$t(o,this.p,s,a)},unmount:()=>{ie(i,a)},isTrue:()=>!0,isMounted:!1}]}else{let o=e.getAttribute(this.z);if(!o)return[];e.removeAttribute(this.z);let{nodes:s,parent:i,commentBegin:a,commentEnd:c}=this.B(e,"elseif",` => ${o} `),f=this.p.h.v(o),p=f.value,l=this.pe(r,n),b=[];_(a,()=>{f.stop();for(let v of b)v();b.length=0});let y=R(p,n);return b.push(y),[{mount:()=>{$t(s,this.p,i,c)},unmount:()=>{ie(a,c)},isTrue:()=>!!p()[0],isMounted:!1}].concat(l)}}k(e,n){let r=e.nextElementSibling,{nodes:o,parent:s,commentBegin:i,commentEnd:a}=this.B(e,"if",` => ${n} `),c=this.p.h.v(n),f=c.value,p=!1,l=this.p.h,b=l.V(),u=()=>{l.C(b,()=>{if(f()[0])p||($t(o,this.p,s,a),p=!0),y.forEach(A=>{A.unmount(),A.isMounted=!1});else{ie(i,a),p=!1;let A=!1;for(let O of y)!A&&O.isTrue()?(O.isMounted||(O.mount(),O.isMounted=!0),A=!0):(O.unmount(),O.isMounted=!1)}})},y=this.pe(r,u),v=[];_(i,()=>{c.stop();for(let A of v)A();v.length=0}),u();let h=R(f,u);v.push(h)}};var ke=t=>{let e=te(t)?t.content.childNodes:[t];return Array.from(e).filter(n=>{let r=n?.tagName;return r!=="SCRIPT"&&r!=="STYLE"})},de=(t,e)=>{for(let n of e)!An(n)&&t.G(n)},me=(t,e)=>{let n=t.querySelectorAll(e);return t.matches?.(e)?[t,...n]:n},te=t=>t instanceof HTMLTemplateElement,Re=t=>t.nodeType===Node.ELEMENT_NODE,Ge=t=>t.nodeType===Node.ELEMENT_NODE,On=t=>t instanceof HTMLSlotElement,ae=t=>te(t)?t.content.childNodes:t.childNodes,ie=(t,e)=>{let n=t.nextSibling;for(;n!=null&&n!==e;){let r=n.nextSibling;$(n),n=r}},ye=(t,e)=>{Object.defineProperty(t,"value",{get(){return t()},set(n){if(e)throw new Error("value is readonly.");return t(n)},enumerable:!0,configurable:!1})},Nn=(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},Ie=t=>`[${CSS.escape(t)}]`,lt=(t,e)=>(t.startsWith("@")&&(t=e.l.on+":"+t.slice(1)),t.includes("[")&&(t=t.replace(/[[\]]/g,e.l.dynamic)),t),qt=t=>{let e=Object.create(null);return n=>e[n]||(e[n]=t(n))},Ur=/-(\w)/g,B=qt(t=>t&&t.replace(Ur,(e,n)=>n?n.toUpperCase():"")),Hr=/\B([A-Z])/g,De=qt(t=>t&&t.replace(Hr,"-$1").toLowerCase()),Je=qt(t=>t&&t.charAt(0).toUpperCase()+t.slice(1));var Z=[],Mn=t=>{Z.length!==0&&Z[Z.length-1]?.add(t)},Ue=t=>{if(!t)return()=>{};let e={stop:()=>{}};return _r(t,e),W(()=>e.stop(),!0),e.stop},_r=(t,e)=>{if(!t)return;let n=[],r=!1,o=()=>{for(let s of n)s();n=[],r=!0};e.stop=o;try{let s=new Set;if(Z.push(s),t(i=>n.push(i)),r)return;for(let i of[...s]){let a=R(i,()=>{o(),Ue(t)});n.push(a)}}finally{Z.pop()}},zt=t=>{let e=Z.length,n=e>0&&Z[e-1];try{return n&&Z.push(null),t()}finally{n&&Z.pop()}},Kt=t=>{try{let e=new Set;return Z.push(e),{value:t(),refs:[...e]}}finally{Z.pop()}};var Qe=t=>!!t&&t[it]===1;var q=(t,e,n)=>{if(!m(t))return;let r=t;if(r(void 0,e,1),!n)return;let o=r();if(o){if(T(o)||X(o))for(let s of o)q(s,e,!0);else if(ue(o))for(let s of o)q(s[0],e,!0),q(s[1],e,!0);if(w(o))for(let s in o)q(o[s],e,!0)}};function Br(t,e,n){Object.defineProperty(t,e,{value:n,enumerable:!1,writable:!0,configurable:!0})}var He=(t,e,n)=>{n.forEach(function(r){let o=t[r];Br(e,r,function(...i){let a=o.apply(this,i),c=this[G];for(let f of c)q(f);return a})})},ut=(t,e)=>{Object.defineProperty(t,Symbol.toStringTag,{value:e,writable:!1,enumerable:!1,configurable:!0})};var Ln=Array.prototype,Wt=Object.create(Ln),Vr=["push","pop","shift","unshift","splice","sort","reverse"];He(Ln,Wt,Vr);var kn=Map.prototype,mt=Object.create(kn),Pr=["set","clear","delete"];ut(mt,"Map");He(kn,mt,Pr);var In=Set.prototype,dt=Object.create(In),jr=["add","clear","delete"];ut(dt,"Set");He(In,dt,jr);var Se={},z=t=>{if(m(t)||Qe(t))return t;let e={auto:!0,_value:t},n=c=>w(c)?G in c?!0:T(c)?(Object.setPrototypeOf(c,Wt),!0):X(c)?(Object.setPrototypeOf(c,dt),!0):ue(c)?(Object.setPrototypeOf(c,mt),!0):!1:!1,r=n(t),o=new Set,s=(c,f)=>{if(Se.set){Se.set.add(a);return}o.size!==0&&zt(()=>{for(let p of[...o.keys()])o.has(p)&&p(c,f)})},i=c=>{let f=c[G];f||(c[G]=f=new Set),f.add(a)},a=(...c)=>{if(!(2 in c)){let p=c[0],l=c[1];return 0 in c?e._value===p||m(p)&&(p=p(),e._value===p)?p:(n(p)&&i(p),e._value=p,e.auto&&s(p,l),e._value):(Mn(a),e._value)}switch(c[2]){case 0:{let p=c[3];if(!p)return()=>{};let l=b=>{o.delete(b)};return o.add(p),()=>{l(p)}}case 1:{let p=c[1],l=e._value;s(l,p);break}case 2:return o.size;case 3:{e.auto=!1;break}case 4:e.auto=!0}return e._value};return a[G]=1,ye(a,!1),r&&i(t),a};var V=t=>m(t)?t():t;var Xe=class{E=[];_=new Map;get S(){return this.E.length}J;constructor(e){this.J=e}Q(e){let n=this.J(e.value);n&&this._.set(n,e)}X(e){let n=this.J(this.E[e]?.value);n&&this._.delete(n)}static Ke(e,n){return{items:[],index:e,value:n,order:-1}}w(e){e.order=this.S,this.E.push(e),this.Q(e)}ze(e,n){let r=this.S;for(let o=e;o<r;++o)this.E[o].order=o+1;n.order=e,this.E.splice(e,0,n),this.Q(n)}I(e){return this.E[e]}Y(e,n){this.X(e),this.E[e]=n,this.Q(n),n.order=e}ce(e){this.X(e),this.E.splice(e,1);let n=this.S;for(let r=e;r<n;++r)this.E[r].order=r}le(e){let n=this.S;for(let r=e;r<n;++r)this.X(r);this.E.splice(e)}Rt(e){return this._.has(e)}We(e){return this._.get(e)?.order??-1}};var Gt=Symbol("r-for"),yt=class t{p;b;Z;T;constructor(e){this.p=e,this.b=e.o.l.for,this.Z=Ie(this.b),this.T=e.o.l.pre}N(e){let n=e.hasAttribute(this.b),r=me(e,this.Z);for(let o of r)this.Ge(o);return n}W(e){return e[Gt]?!0:(e[Gt]=!0,me(e,this.Z).forEach(n=>n[Gt]=!0),!1)}Ge(e){if(e.hasAttribute(this.T)||this.W(e))return;let n=e.getAttribute(this.b);if(!n){k(0,this.b,e);return}e.removeAttribute(this.b),this.Je(e,n)}fe(e){return Y(e)?[]:(D(e)&&(e=e()),Symbol.iterator in Object(e)?e:typeof e=="number"?(r=>({*[Symbol.iterator](){for(let o=1;o<=r;o++)yield o}}))(e):Object.entries(e))}Je(e,n){let r=this.Qe(n);if(!r?.list){k(1,this.b,n,e);return}let o=this.p.o.l.key,s=this.p.o.l.keyBind,i=e.getAttribute(o)??e.getAttribute(s);e.removeAttribute(o),e.removeAttribute(s);let a=i?x=>V(V(x)?.[i]):x=>x,c=(x,N)=>a(x)===a(N),f=ke(e),p=e.parentNode;if(!p)return;let l=`${this.b} => ${n}`,b=new Comment(`__begin__ ${l}`);p.insertBefore(b,e),Me(b,f),f.forEach(x=>{$(x)}),e.remove();let u=new Comment(`__end__ ${l}`);p.insertBefore(u,b.nextSibling);let y=this.p,v=y.h,S=v.V(),h=(x,N,F)=>{let C=r.createContext(N,x),Q=Xe.Ke(C.index,N);return v.C(S,()=>{v.w(C.ctx);let ee=F.previousSibling,Oe=[];for(let d of f){let M=d.cloneNode(!0);p.insertBefore(M,F),Oe.push(M)}for(de(y,Oe),ee=ee.nextSibling;ee!==F;)Q.items.push(ee),ee=ee.nextSibling}),Q},A=(x,N)=>{let F=L.I(x).items,C=F[F.length-1].nextSibling;for(let Q of F)$(Q);L.Y(x,h(x,N,C))},O=(x,N)=>{L.w(h(x,N,u))},be=x=>{for(let N of L.I(x).items)$(N)},qe=x=>{let N=L.S;for(let F=x;F<N;++F)L.I(F).index(F)},It=x=>{let N=L.S;D(x)&&(x=x());let F=V(x[0]);if(T(F)&&F.length===0){ie(b,u),L.le(0);return}let C=0,Q=Number.MAX_SAFE_INTEGER,ee=N,Oe=this.p.o.forGrowThreshold,d=()=>L.S<ee+Oe;for(let g of this.fe(x[0])){let I=()=>{if(C<N){let K=L.I(C++);if(c(K.value,g))return;let E=L.We(a(g));if(E>=C&&E-C<10){if(--C,Q=Math.min(Q,C),be(C),L.ce(C),--N,E>C+1)for(let P=C;P<E-1&&P<N&&!c(L.I(C).value,g);)++P,be(C),L.ce(C),--N;I();return}d()?(L.ze(C-1,h(C,g,L.I(C-1).items[0])),Q=Math.min(Q,C-1),++N):A(C-1,g)}else O(C++,g)};I()}let M=C;for(N=L.S;C<N;)be(C++);L.le(M),qe(Q)},tt=()=>{ze=R(le,It)},Te=()=>{nt.stop(),ze()},nt=v.v(r.list),le=nt.value,ze,ne=0,L=new Xe(a);for(let x of this.fe(le()[0]))L.w(h(ne++,x,u));_(b,Te),tt()}static Xe=/\{?\[?\(?([^)}\]]+)\)?\]?\}?([^)]+)?\s+\b(?:in|of)\b\s+([^\s]+)\s*/;Qe(e){let n=t.Xe.exec(e);if(!n)return;let r=(n[1]+(n[2]??"")).split(",").map(c=>c.trim()),o=r.length>1?r.length-1:-1,s=o!==-1&&(r[o]==="index"||r[o]?.startsWith("#"))?r[o]:"";s&&r.splice(o,1);let i=n[3];if(!i||r.length===0)return;let a=/[{[]/.test(e);return{list:i,createContext:(c,f)=>{let p={},l=V(c);if(!a&&r.length===1)p[r[0]]=c;else if(T(l)){let u=0;for(let y of r)p[y]=l[u++]}else for(let u of r)p[u]=l[u];let b={ctx:p,index:z(-1)};return s&&(b.index=p[s.startsWith("#")?s.substring(1):s]=z(f)),b}}}};var $r=(t,e)=>{for(let n of t){let r=n.cloneNode(!0);e.appendChild(r)}},ht=class{p;D;ue;constructor(e){this.p=e,this.D=e.o.l.is,this.ue=Ie(this.D)+", [is]"}N(e){let n=e.hasAttribute(this.D),r=me(e,this.ue);for(let o of r)this.x(o);return n}x(e){let n=e.getAttribute(this.D);if(!n){if(n=e.getAttribute("is"),!n||!n.startsWith("regor:"))return;n=`'${n.slice(6)}'`,e.removeAttribute("is")}e.removeAttribute(this.D),this.k(e,n)}B(e,n){let r=ke(e),o=e.parentNode,s=document.createComment(`__begin__ dynamic ${n??""}`);o.insertBefore(s,e),Me(s,r),r.forEach(a=>{$(a)}),e.remove();let i=document.createComment(`__end__ dynamic ${n??""}`);return o.insertBefore(i,s.nextSibling),{nodes:r,parent:o,commentBegin:s,commentEnd:i}}k(e,n){let{nodes:r,parent:o,commentBegin:s,commentEnd:i}=this.B(e,` => ${n} `),a=this.p.h.v(n),c=a.value,f=this.p.h,p=f.V(),l={name:""},b=te(e)?r:[...r[0].childNodes],u=()=>{f.C(p,()=>{let h=c()[0];if(w(h)&&(h.name?h=h.name:h=Object.entries(f.me()).filter(O=>O[1]===h)[0]?.[0]),!U(h)||j(h)){ie(s,i);return}if(l.name===h)return;ie(s,i);let A=document.createElement(h);for(let O of e.getAttributeNames())O!==this.D&&A.setAttribute(O,e.getAttribute(O));$r(b,A),o.insertBefore(A,i),this.p.G(A),l.name=h})},y=[];_(s,()=>{a.stop();for(let h of y)h();y.length=0}),u();let S=R(c,u);y.push(S)}};var Dn={collectRefObj:!0,onBind:(t,e)=>R(e.value,()=>{let r=e.value(),o=e.context,s=r[0];if(w(s))for(let i of Object.entries(s)){let a=i[0],c=i[1],f=o[a];f!==c&&(m(f)?f(c):o[a]=c)}},!0)};var Un={collectRefObj:!0,once:!0,onBind:(t,e)=>{let n=e.value(),r=e.context,o=n[0];if(!w(o))return()=>{};for(let s of Object.entries(o)){let i=s[0],a=s[1],c=r[i];c!==a&&(m(c)?c(a):r[i]=a)}return()=>{}}};var he=t=>{ot(t)?.onUnmounted?.forEach(n=>{n()}),t.unmounted?.()};var Ye=class{props;start;end;ctx;autoProps=!0;entangle=!0;disableSwitch=!1;onAutoPropsAssigned;de;constructor(e,n,r,o,s){this.props=e,this.de=n,this.ctx=r,this.start=o,this.end=s}emit=(e,n)=>{this.de.dispatchEvent(new CustomEvent(e,{detail:n}))};unmount(){let e=this.start.nextSibling,n=this.end;for(;e&&e!==n;)$(e),e=e.nextSibling;he(this)}};var Jt=Symbol("scope"),Qt=t=>{try{En();let e=t();Bt(e);let n={context:e,unmount:()=>he(e),[Jt]:1};return n[Jt]=1,n}finally{vn()}},Hn=t=>w(t)?Jt in t:!1;var Xt=(t,e)=>{if(t===e)return()=>{};let n=R(t,o=>e(o)),r=R(e,o=>t(o));return e(t()),()=>{n(),r()}};var gt=t=>{ot(t)?.onMounted?.forEach(n=>{n()}),t.mounted?.()};var _n={collectRefObj:!0,onBind:(t,e,n,r,o,s)=>{if(!r)return()=>{};let i=B(r);return R(e.value,()=>{let c=e.refs[0]??e.value()[0],f=e.context,p=f[r];p!==c&&(m(p)?p(c):f[i]=c)},!0)}};var bt=class{p;ye;constructor(e){this.p=e,this.ye=e.o.l.inherit}N(e){this.Ye(e)}Ye(e){let n=this.p,r=n.h,o=n.o.he,s=n.o.ge,i=r.me(),a=[...o.keys(),...Object.keys(i),...[...o.keys()].map(De),...[...Object.keys(i)].map(De)].join(",");if(j(a))return;let c=e.querySelectorAll(a),f=e.matches?.(a)?[e,...c]:c;for(let p of f){if(p.hasAttribute(n.T))continue;let l=p.parentNode;if(!l)continue;let b=p.nextSibling,u=B(p.tagName).toUpperCase(),v=i[u]??s.get(u);if(!v)continue;let S=v.template;if(!S)continue;let h=p.parentElement;if(!h)continue;let A=new Comment(" begin component: "+p.tagName),O=new Comment(" end component: "+p.tagName);h.insertBefore(A,p),p.remove();let be=n.o.l.props,qe=n.o.l.propsOnce,It=n.o.l.bind,tt=(d,M)=>{let g={},I=d.hasAttribute(be),K=d.hasAttribute(qe);return r.C(M,()=>{r.w(g),I&&n.x(Dn,d,be),K&&n.x(Un,d,qe);let E=v.props;if(!E||E.length===0)return;E=E.map(B);for(let Ee of E.concat(E.map(De))){let re=d.getAttribute(Ee);re!==null&&(g[B(Ee)]=re,d.removeAttribute(Ee))}let P=n.ee.be(d,!1);for(let[Ee,re]of P.entries()){let[ve,Dt]=re.te;Dt&&E.includes(B(Dt))&&(ve!=="."&&ve!==":"&&ve!==It||n.x(_n,d,Ee,!0,Dt,re.ne))}}),g},Te=[...r.V()],nt=()=>{let d=tt(p,Te),M=new Ye(d,p,Te,A,O),g=Qt(()=>v.context(M)??{}).context;if(M.autoProps){for(let[I,K]of Object.entries(d))if(I in g){let E=g[I];if(E===K)continue;M.entangle&&m(E)&&m(K)?_(A,Xt(K,E)):m(E)?E(K):g[I]=V(K)}else g[I]=K;M.onAutoPropsAssigned?.()}return{componentCtx:g,head:M}},{componentCtx:le,head:ze}=nt(),ne=[...ae(S)],L=ne.length,x=p.childNodes.length===0,N=d=>{let M=d.parentElement;if(x){for(let E of[...d.childNodes])M.insertBefore(E,d);return}let g=d.name;j(g)&&(g=d.getAttributeNames().filter(E=>E.startsWith("#"))[0],j(g)?g="default":g=g.substring(1));let I=p.querySelector(`template[name='${g}'], template[\\#${g}]`);!I&&g==="default"&&(I=p.querySelector("template:not([name])"),I&&I.getAttributeNames().filter(E=>E.startsWith("#")).length>0&&(I=null));let K=E=>{ze.disableSwitch||r.C(Te,()=>{r.w(le);let P=tt(d,r.V());r.C(Te,()=>{r.w(P);let Ee=r.V(),re=Rn(Ee);for(let ve of E)Re(ve)&&(ve.setAttribute(We,re),Vt(re),_(ve,()=>{Pt(re)}))})})};if(I){let E=[...ae(I)];for(let P of E)M.insertBefore(P,d);K(E)}else{if(g!=="default"){for(let P of[...ae(d)])M.insertBefore(P,d);return}let E=[...ae(p)].filter(P=>!te(P));for(let P of E)M.insertBefore(P,d);K(E)}},F=d=>{if(!Re(d))return;let M=d.querySelectorAll("slot");if(On(d)){N(d),d.remove();return}for(let g of M)N(g),g.remove()};(()=>{for(let d=0;d<L;++d)ne[d]=ne[d].cloneNode(!0),l.insertBefore(ne[d],b),F(ne[d])})(),h.insertBefore(O,b);let Q=()=>{if(!v.inheritAttrs)return;let d=ne.filter(g=>g.nodeType===Node.ELEMENT_NODE);d.length>1&&(d=d.filter(g=>g.hasAttribute(this.ye)));let M=d[0];if(M)for(let g of p.getAttributeNames()){if(g===be||g===qe)continue;let I=p.getAttribute(g);if(g==="class")M.classList.add(...I.split(" "));else if(g==="style"){let K=M.style,E=p.style;for(let P of E)K.setProperty(P,E.getPropertyValue(P))}else M.setAttribute(lt(g,n.o),I)}},ee=()=>{for(let d of p.getAttributeNames())!d.startsWith("@")&&!d.startsWith(n.o.l.on)&&p.removeAttribute(d)},Oe=()=>{Q(),ee(),r.w(le),n.Te(p,!1),le.$emit=ze.emit,de(n,ne),_(p,()=>{he(le)}),_(A,()=>{se(p)}),gt(le)};r.C(Te,Oe)}}};var Yt=class{xe;te=[];ne=[];Ee=[];constructor(e){this.xe=e,this.v()}v(){let e=this.xe,n=e.startsWith(".");n&&(e=":"+e.slice(1));let r=e.indexOf("."),o=this.te=(r<0?e:e.substring(0,r)).split(/[:@]/);if(j(o[0])&&(o[0]=n?".":e[0]),r>=0){let s=this.ne=e.slice(r+1).split(".");if(s.includes("camel")){let i=o.length-1;o[i]=B(o[i])}s.includes("prop")&&(o[0]=".")}}},Tt=class{p;Re;constructor(e){this.p=e,this.Re=e.o.Ze()}be(e,n){let r=new Map;if(!Ge(e))return r;let o=this.Re,s=a=>{let c=a.getAttributeNames().filter(f=>o.some(p=>f.startsWith(p)));for(let f of c)r.has(f)||r.set(f,new Yt(f)),r.get(f).Ee.push(a)};if(s(e),!n)return r;let i=e.querySelectorAll("*");for(let a of i)s(a);return r}};var Et={};var vt=class{h;ve;Ce;Se;we;ee;o;T;Ae;constructor(e){this.h=e,this.o=e.o,this.Ce=new yt(this),this.ve=new ft(this),this.Se=new ht(this),this.we=new bt(this),this.ee=new Tt(this),this.T=this.o.l.pre,this.Ae=this.o.l.dynamic}et(e){let n=te(e)?[e]:e.querySelectorAll("template");for(let r of n){if(r.hasAttribute(this.T))continue;let o=r.parentNode;if(!o)continue;let s=r.nextSibling;if(r.remove(),!r.content)continue;let i=[...r.content.childNodes];for(let a of i)o.insertBefore(a,s);de(this,i)}}G(e){e.nodeType!==Node.ELEMENT_NODE||e.hasAttribute(this.T)||this.ve.N(e)||this.Ce.N(e)||this.Se.N(e)||(this.we.N(e),this.et(e),this.Te(e,!0))}Te(e,n){let r=this.ee.be(e,n),o=this.o.H;for(let[s,i]of r.entries()){let[a,c]=i.te,f=o[s]??o[a];if(!f){console.error("directive not found:",a);continue}i.Ee.forEach(p=>{this.x(f,p,s,!1,c,i.ne)})}}x(e,n,r,o,s,i){if(n.hasAttribute(this.T))return;let a=n.getAttribute(r);n.removeAttribute(r);let c=f=>{let p=f.getAttribute(We);return p||(f.parentElement?c(f.parentElement):null)};if(jt()){let f=c(n);if(f){this.h.C(Sn(f),()=>{this.k(e,n,a,s,i)});return}}this.k(e,n,a,s,i)}tt(e,n,r){if(e!==Et)return!1;if(j(r))return!0;let o=document.querySelector(r);if(o){let s=n.parentElement;if(!s)return!0;let i=new Comment(`teleported => '${r}'`);s.insertBefore(i,n),n.teleportedFrom=i,i.teleportedTo=n,_(i,()=>{$(n)}),o.appendChild(n)}return!0}k(e,n,r,o,s){if(n.nodeType!==Node.ELEMENT_NODE||r==null||this.tt(e,n,r))return;let i=this.h.v(r,e.isLazy,e.isLazyKey,e.collectRefObj,e.once),a=[];_(n,()=>{i.stop(),p?.stop();for(let S of a)S();a.length=0});let f=Nn(o,this.Ae),p;f&&(p=this.h.v(B(f),void 0,void 0,void 0,e.once));let l,b=()=>(l=i.value(),l),u,y=()=>p?(u=p.value()[0],u):(u=o,o),v=()=>{if(!e.onChange)return;let S=R(i.value,h=>{let A=l,O=u;e.onChange?.(n,b(),A,y(),O,s)});if(a.push(S),p){let h=R(p.value,A=>{let O=u;e.onChange?.(n,b(),O,y(),O,s)});a.push(h)}};e.once||v(),e.onBind&&a.push(e.onBind(n,i,r,o,p,s)),e.onChange?.(n,b(),void 0,y(),void 0,s)}};var Fr=9,qr=10,zr=13,Kr=32,ge=46,xt=44,Wr=39,Gr=34,Ct=40,_e=41,Rt=91,St=93,Zt=63,Jr=59,Bn=58,Qr=123,wt=125,tn=43,Xr=45,Vn=96,Pn=47,Yr=92,jn=[2,3],$n=[tn,Xr],Gn={"-":1,"!":1,"~":1,"+":1,new:1},Jn={"=":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},Ve={"=>":2,...Jn,"||":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},Qn=Object.keys(Jn),Zr=new Set(Qn),At=new Set;At.add("=>");Qn.forEach(t=>At.add(t));var eo=new Set(["$","_"]),Fn={true:!0,false:!1,null:null},to="this";function Xn(t){return Math.max(0,...Object.keys(t).map(e=>e.length))}var no=Xn(Gn),ro=Xn(Ve),Pe="Expected ",we="Unexpected ",rn="Unclosed ",oo=Pe+":",qn=Pe+"expression",so="missing }",io=we+"object property",ao=rn+"(",zn=Pe+"comma",Kn=we+"token ",co=we+"period",en=Pe+"expression after ",po="missing unaryOp argument",fo=rn+"[",lo=Pe+"exponent (",uo="Variable names cannot start with a number (",mo=rn+'quote after "';var Be=t=>t>=48&&t<=57,Wn=t=>Ve[t]||0,nn=class{nt={0:[this.rt],1:[this.ot,this.st,this.it],2:[this.at,this.pt,this.ct,this.Oe,this.lt],3:[this.ft,this.ut,this.mt]};r;e;get M(){return this.r.charAt(this.e)}get f(){return this.r.charCodeAt(this.e)}u(e){return this.r.charCodeAt(this.e)===e}constructor(e){this.r=e,this.e=0}U(e){let n=String.fromCharCode(e);return e>=65&&e<=90||e>=97&&e<=122||e>=128&&!(n in Ve)||eo.has(n)}re(e){return this.U(e)||Be(e)}i(e){return new Error(`${e} at character ${this.e}`)}L(e,n,r){let o=this.nt[e];if(!o)return r;let s={node:r},i=a=>{a.call(this,s)};return n===0?o.forEach(i):o.find(i),s.node}y(){let e=this.f,n=this.r,r=this.e;for(;e===Kr||e===Fr||e===qr||e===zr;)e=n.charCodeAt(++r);this.e=r}parse(){let e=this.oe();return e.length===1?e[0]:{type:0,body:e}}oe(e){let n=[];for(;this.e<this.r.length;){let r=this.f;if(r===Jr||r===xt)this.e++;else{let o=this.A();if(o)n.push(o);else if(this.e<this.r.length){if(r===e)break;throw this.i(we+'"'+this.M+'"')}}}return n}A(){let e=this.L(0,1)??this.Ne();return this.y(),this.L(1,0,e)}se(){this.y();let e=this.e,n=this.r,r=n.substr(e,ro),o=r.length;for(;o>0;){if(r in Ve&&(!this.U(this.f)||e+r.length<n.length&&!this.re(n.charCodeAt(e+r.length))))return e+=o,this.e=e,r;r=r.substr(0,--o)}return!1}Ne(){let e,n,r,o,s,i,a,c;if(s=this.j(),!s||(n=this.se(),!n))return s;if(o={value:n,prec:Wn(n),right_a:At.has(n)},i=this.j(),!i)throw this.i(en+n);let f=[s,o,i];for(;n=this.se();){if(r=Wn(n),r===0){this.e-=n.length;break}o={value:n,prec:r,right_a:At.has(n)},c=n;let p=l=>o.right_a&&l.right_a?r>l.prec:r<=l.prec;for(;f.length>2&&p(f[f.length-2]);)i=f.pop(),n=f.pop().value,s=f.pop(),e={type:8,operator:n,left:s,right:i},f.push(e);if(e=this.j(),!e)throw this.i(en+c);f.push(o,e)}for(a=f.length-1,e=f[a];a>1;)e={type:8,operator:f[a-1].value,left:f[a-2],right:e},a-=2;return e}j(){let e,n,r;if(this.y(),r=this.L(2,1),r)return this.L(3,0,r);let o=this.f;if(Be(o)||o===ge)return this.dt();if(o===Wr||o===Gr)r=this.yt();else if(o===Rt)r=this.ht();else{for(e=this.r.substr(this.e,no),n=e.length;n>0;){if(Object.prototype.hasOwnProperty.call(Gn,e)&&(!this.U(this.f)||this.e+e.length<this.r.length&&!this.re(this.r.charCodeAt(this.e+e.length)))){this.e+=n;let s=this.j();if(!s)throw this.i(po);return this.L(3,0,{type:7,operator:e,argument:s})}e=e.substr(0,--n)}this.U(o)?(r=this.ie(),r.name in Fn?r={type:4,value:Fn[r.name],raw:r.name}:r.name===to&&(r={type:5})):o===Ct&&(r=this.gt())}return r?(r=this.F(r),this.L(3,0,r)):this.L(3,0,!1)}F(e){this.y();let n=this.f;for(;n===ge||n===Rt||n===Ct||n===Zt;){let r;if(n===Zt){if(this.r.charCodeAt(this.e+1)!==ge)break;r=!0,this.e+=2,this.y(),n=this.f}if(this.e++,n===Rt){if(e={type:3,computed:!0,object:e,property:this.A()},this.y(),n=this.f,n!==St)throw this.i(fo);this.e++}else n===Ct?e={type:6,arguments:this.Me(_e),callee:e}:(n===ge||r)&&(r&&this.e--,this.y(),e={type:3,computed:!1,object:e,property:this.ie()});r&&(e.optional=!0),this.y(),n=this.f}return e}dt(){let e="",n;for(;Be(this.f);)e+=this.r.charAt(this.e++);if(this.u(ge))for(e+=this.r.charAt(this.e++);Be(this.f);)e+=this.r.charAt(this.e++);if(n=this.M,n==="e"||n==="E"){for(e+=this.r.charAt(this.e++),n=this.M,(n==="+"||n==="-")&&(e+=this.r.charAt(this.e++));Be(this.f);)e+=this.r.charAt(this.e++);if(!Be(this.r.charCodeAt(this.e-1)))throw this.i(lo+e+this.M+")")}let r=this.f;if(this.U(r))throw this.i(uo+e+this.M+")");if(r===ge||e.length===1&&e.charCodeAt(0)===ge)throw this.i(co);return{type:4,value:parseFloat(e),raw:e}}yt(){let e="",n=this.e,r=this.r.charAt(this.e++),o=!1;for(;this.e<this.r.length;){let s=this.r.charAt(this.e++);if(s===r){o=!0;break}else if(s==="\\")switch(s=this.r.charAt(this.e++),s){case"n":e+=`
1
+ var D=t=>typeof t=="function",U=t=>typeof t=="string",bn=t=>typeof t>"u",Y=t=>t==null||typeof t>"u",j=t=>typeof t!="string"||!t?.trim(),kr=Object.prototype.toString,Ut=t=>kr.call(t),ue=t=>Ut(t)==="[object Map]",X=t=>Ut(t)==="[object Set]",Ht=t=>Ut(t)==="[object Date]",Ke=t=>typeof t=="symbol",T=Array.isArray,w=t=>t!==null&&typeof t=="object";var Tn={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."},H=(t,...e)=>{let n=Tn[t];return new Error(D(n)?n.call(Tn,...e):n)};var Ne=Symbol(":regor");var xe=t=>{let e=t[Ne];if(e)return e;let n={unbinders:[],data:{}};return t[Ne]=n,n};var _=(t,e)=>{xe(t).unbinders.push(e)};var rt=[],En=()=>{let t={onMounted:[],onUnmounted:[]};return rt.push(t),t},Ce=t=>{let e=rt[rt.length-1];if(!e&&!t)throw H(2);return e},vn=t=>{let e=Ce();return t&&Bt(t),rt.pop(),e},_t=Symbol("csp"),Bt=t=>{let e=t,n=e[_t];if(n){let r=Ce();if(n===r)return;r.onMounted.length>0&&n.onMounted.push(...r.onMounted),r.onUnmounted.length>0&&n.onUnmounted.push(...r.onUnmounted);return}e[_t]=Ce()},ot=t=>t[_t];var W=(t,e)=>{Ce(e)?.onUnmounted.push(t)};var st=Symbol("ref"),G=Symbol("sref"),it=Symbol("raw");var m=t=>t?.[G]===1;var R=(t,e,n)=>{if(!m(t))throw H(3,"observe");n&&e(t());let o=t(void 0,void 0,0,e);return W(o,!0),o};var se=t=>{let e=[t];for(;e.length>0;){let n=e.shift();Ir(n);let r=n.childNodes;if(r)for(let o of r)e.push(o)}},Ir=t=>{let e=t[Ne];if(e){for(let n of e.unbinders)n();e.unbinders.splice(0),delete t[Ne]}};var $=t=>{t.remove(),setTimeout(()=>se(t),1)};var xn={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,r)=>({msg:`Failed setting prop "${t}" on <${e.toLowerCase()}>: value ${n} is invalid.`,args:[r]}),5:(t,e)=>`${t} binding missing event type at ${e.outerHTML}`,6:(t,e)=>({msg:t,args:[e]})},k=(t,...e)=>{let n=xn[t],r=D(n)?n.call(xn,...e):n,o=at.warning;o&&(U(r)?o(r):o(r,...r.args))},at={warning:console.warn};var pt={},ct={},Cn=1,Rn=t=>{let e=(Cn++).toString();return pt[e]=t,ct[e]=0,e},Vt=t=>{ct[t]+=1},Pt=t=>{--ct[t]===0&&(delete pt[t],delete ct[t])},Sn=t=>pt[t],jt=()=>Cn!==1&&Object.keys(pt).length>0,We="r-switch",Dr=t=>{let e=t.filter(r=>Re(r)).map(r=>[...r.querySelectorAll("[r-switch]")].map(o=>o.getAttribute(We))),n=new Set;return e.forEach(r=>{r.forEach(o=>o&&n.add(o))}),[...n]},Me=(t,e)=>{if(!jt())return;let n=Dr(e);n.length!==0&&(n.forEach(Vt),_(t,()=>{n.forEach(Pt)}))};var $t=(t,e,n,r)=>{let o=[];for(let s of t){let i=s.cloneNode(!0);n.insertBefore(i,r),o.push(i)}de(e,o)},Ft=Symbol("r-if"),wn=Symbol("r-else"),An=t=>t[wn]===1,ft=class{p;P;q;K;z;b;T;constructor(e){this.p=e,this.P=e.o.l.if,this.q=Ie(e.o.l.if),this.K=e.o.l.else,this.z=e.o.l.elseif,this.b=e.o.l.for,this.T=e.o.l.pre}qe(e,n){let r=e.parentElement;for(;r!==null&&r!==document.documentElement;){if(r.hasAttribute(n))return!0;r=r.parentElement}return!1}N(e){let n=e.hasAttribute(this.P),r=me(e,this.q);for(let o of r)this.x(o);return n}W(e){return e[Ft]?!0:(e[Ft]=!0,me(e,this.q).forEach(n=>n[Ft]=!0),!1)}x(e){if(e.hasAttribute(this.T)||this.W(e)||this.qe(e,this.b))return;let n=e.getAttribute(this.P);if(!n){k(0,this.P,e);return}e.removeAttribute(this.P),this.V(e,n)}B(e,n,r){let o=ke(e),s=e.parentNode,i=document.createComment(`__begin__ :${n}${r??""}`);s.insertBefore(i,e),Me(i,o),o.forEach(c=>{$(c)}),e.remove(),n!=="if"&&(e[wn]=1);let a=document.createComment(`__end__ :${n}${r??""}`);return s.insertBefore(a,i.nextSibling),{nodes:o,parent:s,commentBegin:i,commentEnd:a}}pe(e,n){if(!e)return[];let r=e.nextElementSibling;if(e.hasAttribute(this.K)){e.removeAttribute(this.K);let{nodes:o,parent:s,commentBegin:i,commentEnd:a}=this.B(e,"else");return[{mount:()=>{$t(o,this.p,s,a)},unmount:()=>{ie(i,a)},isTrue:()=>!0,isMounted:!1}]}else{let o=e.getAttribute(this.z);if(!o)return[];e.removeAttribute(this.z);let{nodes:s,parent:i,commentBegin:a,commentEnd:c}=this.B(e,"elseif",` => ${o} `),f=this.p.h.v(o),p=f.value,l=this.pe(r,n),b=[];_(a,()=>{f.stop();for(let v of b)v();b.length=0});let y=R(p,n);return b.push(y),[{mount:()=>{$t(s,this.p,i,c)},unmount:()=>{ie(a,c)},isTrue:()=>!!p()[0],isMounted:!1}].concat(l)}}V(e,n){let r=e.nextElementSibling,{nodes:o,parent:s,commentBegin:i,commentEnd:a}=this.B(e,"if",` => ${n} `),c=this.p.h.v(n),f=c.value,p=!1,l=this.p.h,b=l.k(),u=()=>{l.C(b,()=>{if(f()[0])p||($t(o,this.p,s,a),p=!0),y.forEach(A=>{A.unmount(),A.isMounted=!1});else{ie(i,a),p=!1;let A=!1;for(let O of y)!A&&O.isTrue()?(O.isMounted||(O.mount(),O.isMounted=!0),A=!0):(O.unmount(),O.isMounted=!1)}})},y=this.pe(r,u),v=[];_(i,()=>{c.stop();for(let A of v)A();v.length=0}),u();let h=R(f,u);v.push(h)}};var ke=t=>{let e=te(t)?t.content.childNodes:[t];return Array.from(e).filter(n=>{let r=n?.tagName;return r!=="SCRIPT"&&r!=="STYLE"})},de=(t,e)=>{for(let n of e)!An(n)&&t.G(n)},me=(t,e)=>{let n=t.querySelectorAll(e);return t.matches?.(e)?[t,...n]:n},te=t=>t instanceof HTMLTemplateElement,Re=t=>t.nodeType===Node.ELEMENT_NODE,Ge=t=>t.nodeType===Node.ELEMENT_NODE,On=t=>t instanceof HTMLSlotElement,ae=t=>te(t)?t.content.childNodes:t.childNodes,ie=(t,e)=>{let n=t.nextSibling;for(;n!=null&&n!==e;){let r=n.nextSibling;$(n),n=r}},ye=(t,e)=>{Object.defineProperty(t,"value",{get(){return t()},set(n){if(e)throw new Error("value is readonly.");return t(n)},enumerable:!0,configurable:!1})},Nn=(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},Ie=t=>`[${CSS.escape(t)}]`,lt=(t,e)=>(t.startsWith("@")&&(t=e.l.on+":"+t.slice(1)),t.includes("[")&&(t=t.replace(/[[\]]/g,e.l.dynamic)),t),qt=t=>{let e=Object.create(null);return n=>e[n]||(e[n]=t(n))},Ur=/-(\w)/g,B=qt(t=>t&&t.replace(Ur,(e,n)=>n?n.toUpperCase():"")),Hr=/\B([A-Z])/g,De=qt(t=>t&&t.replace(Hr,"-$1").toLowerCase()),Je=qt(t=>t&&t.charAt(0).toUpperCase()+t.slice(1));var Z=[],Mn=t=>{Z.length!==0&&Z[Z.length-1]?.add(t)},Ue=t=>{if(!t)return()=>{};let e={stop:()=>{}};return _r(t,e),W(()=>e.stop(),!0),e.stop},_r=(t,e)=>{if(!t)return;let n=[],r=!1,o=()=>{for(let s of n)s();n=[],r=!0};e.stop=o;try{let s=new Set;if(Z.push(s),t(i=>n.push(i)),r)return;for(let i of[...s]){let a=R(i,()=>{o(),Ue(t)});n.push(a)}}finally{Z.pop()}},zt=t=>{let e=Z.length,n=e>0&&Z[e-1];try{return n&&Z.push(null),t()}finally{n&&Z.pop()}},Kt=t=>{try{let e=new Set;return Z.push(e),{value:t(),refs:[...e]}}finally{Z.pop()}};var Qe=t=>!!t&&t[it]===1;var q=(t,e,n)=>{if(!m(t))return;let r=t;if(r(void 0,e,1),!n)return;let o=r();if(o){if(T(o)||X(o))for(let s of o)q(s,e,!0);else if(ue(o))for(let s of o)q(s[0],e,!0),q(s[1],e,!0);if(w(o))for(let s in o)q(o[s],e,!0)}};function Br(t,e,n){Object.defineProperty(t,e,{value:n,enumerable:!1,writable:!0,configurable:!0})}var He=(t,e,n)=>{n.forEach(function(r){let o=t[r];Br(e,r,function(...i){let a=o.apply(this,i),c=this[G];for(let f of c)q(f);return a})})},ut=(t,e)=>{Object.defineProperty(t,Symbol.toStringTag,{value:e,writable:!1,enumerable:!1,configurable:!0})};var Ln=Array.prototype,Wt=Object.create(Ln),Vr=["push","pop","shift","unshift","splice","sort","reverse"];He(Ln,Wt,Vr);var kn=Map.prototype,mt=Object.create(kn),Pr=["set","clear","delete"];ut(mt,"Map");He(kn,mt,Pr);var In=Set.prototype,dt=Object.create(In),jr=["add","clear","delete"];ut(dt,"Set");He(In,dt,jr);var Se={},z=t=>{if(m(t)||Qe(t))return t;let e={auto:!0,_value:t},n=c=>w(c)?G in c?!0:T(c)?(Object.setPrototypeOf(c,Wt),!0):X(c)?(Object.setPrototypeOf(c,dt),!0):ue(c)?(Object.setPrototypeOf(c,mt),!0):!1:!1,r=n(t),o=new Set,s=(c,f)=>{if(Se.set){Se.set.add(a);return}o.size!==0&&zt(()=>{for(let p of[...o.keys()])o.has(p)&&p(c,f)})},i=c=>{let f=c[G];f||(c[G]=f=new Set),f.add(a)},a=(...c)=>{if(!(2 in c)){let p=c[0],l=c[1];return 0 in c?e._value===p||m(p)&&(p=p(),e._value===p)?p:(n(p)&&i(p),e._value=p,e.auto&&s(p,l),e._value):(Mn(a),e._value)}switch(c[2]){case 0:{let p=c[3];if(!p)return()=>{};let l=b=>{o.delete(b)};return o.add(p),()=>{l(p)}}case 1:{let p=c[1],l=e._value;s(l,p);break}case 2:return o.size;case 3:{e.auto=!1;break}case 4:e.auto=!0}return e._value};return a[G]=1,ye(a,!1),r&&i(t),a};var V=t=>m(t)?t():t;var Xe=class{E=[];_=new Map;get S(){return this.E.length}J;constructor(e){this.J=e}Q(e){let n=this.J(e.value);n&&this._.set(n,e)}X(e){let n=this.J(this.E[e]?.value);n&&this._.delete(n)}static Ke(e,n){return{items:[],index:e,value:n,order:-1}}w(e){e.order=this.S,this.E.push(e),this.Q(e)}ze(e,n){let r=this.S;for(let o=e;o<r;++o)this.E[o].order=o+1;n.order=e,this.E.splice(e,0,n),this.Q(n)}I(e){return this.E[e]}Y(e,n){this.X(e),this.E[e]=n,this.Q(n),n.order=e}ce(e){this.X(e),this.E.splice(e,1);let n=this.S;for(let r=e;r<n;++r)this.E[r].order=r}le(e){let n=this.S;for(let r=e;r<n;++r)this.X(r);this.E.splice(e)}Rt(e){return this._.has(e)}We(e){return this._.get(e)?.order??-1}};var Gt=Symbol("r-for"),yt=class t{p;b;Z;T;constructor(e){this.p=e,this.b=e.o.l.for,this.Z=Ie(this.b),this.T=e.o.l.pre}N(e){let n=e.hasAttribute(this.b),r=me(e,this.Z);for(let o of r)this.Ge(o);return n}W(e){return e[Gt]?!0:(e[Gt]=!0,me(e,this.Z).forEach(n=>n[Gt]=!0),!1)}Ge(e){if(e.hasAttribute(this.T)||this.W(e))return;let n=e.getAttribute(this.b);if(!n){k(0,this.b,e);return}e.removeAttribute(this.b),this.Je(e,n)}fe(e){return Y(e)?[]:(D(e)&&(e=e()),Symbol.iterator in Object(e)?e:typeof e=="number"?(r=>({*[Symbol.iterator](){for(let o=1;o<=r;o++)yield o}}))(e):Object.entries(e))}Je(e,n){let r=this.Qe(n);if(!r?.list){k(1,this.b,n,e);return}let o=this.p.o.l.key,s=this.p.o.l.keyBind,i=e.getAttribute(o)??e.getAttribute(s);e.removeAttribute(o),e.removeAttribute(s);let a=i?x=>V(V(x)?.[i]):x=>x,c=(x,N)=>a(x)===a(N),f=ke(e),p=e.parentNode;if(!p)return;let l=`${this.b} => ${n}`,b=new Comment(`__begin__ ${l}`);p.insertBefore(b,e),Me(b,f),f.forEach(x=>{$(x)}),e.remove();let u=new Comment(`__end__ ${l}`);p.insertBefore(u,b.nextSibling);let y=this.p,v=y.h,S=v.k(),h=(x,N,F)=>{let C=r.createContext(N,x),Q=Xe.Ke(C.index,N);return v.C(S,()=>{v.w(C.ctx);let ee=F.previousSibling,Oe=[];for(let d of f){let M=d.cloneNode(!0);p.insertBefore(M,F),Oe.push(M)}for(de(y,Oe),ee=ee.nextSibling;ee!==F;)Q.items.push(ee),ee=ee.nextSibling}),Q},A=(x,N)=>{let F=L.I(x).items,C=F[F.length-1].nextSibling;for(let Q of F)$(Q);L.Y(x,h(x,N,C))},O=(x,N)=>{L.w(h(x,N,u))},be=x=>{for(let N of L.I(x).items)$(N)},qe=x=>{let N=L.S;for(let F=x;F<N;++F)L.I(F).index(F)},It=x=>{let N=L.S;D(x)&&(x=x());let F=V(x[0]);if(T(F)&&F.length===0){ie(b,u),L.le(0);return}let C=0,Q=Number.MAX_SAFE_INTEGER,ee=N,Oe=this.p.o.forGrowThreshold,d=()=>L.S<ee+Oe;for(let g of this.fe(x[0])){let I=()=>{if(C<N){let K=L.I(C++);if(c(K.value,g))return;let E=L.We(a(g));if(E>=C&&E-C<10){if(--C,Q=Math.min(Q,C),be(C),L.ce(C),--N,E>C+1)for(let P=C;P<E-1&&P<N&&!c(L.I(C).value,g);)++P,be(C),L.ce(C),--N;I();return}d()?(L.ze(C-1,h(C,g,L.I(C-1).items[0])),Q=Math.min(Q,C-1),++N):A(C-1,g)}else O(C++,g)};I()}let M=C;for(N=L.S;C<N;)be(C++);L.le(M),qe(Q)},tt=()=>{ze=R(le,It)},Te=()=>{nt.stop(),ze()},nt=v.v(r.list),le=nt.value,ze,ne=0,L=new Xe(a);for(let x of this.fe(le()[0]))L.w(h(ne++,x,u));_(b,Te),tt()}static Xe=/\{?\[?\(?([^)}\]]+)\)?\]?\}?([^)]+)?\s+\b(?:in|of)\b\s+([^\s]+)\s*/;Qe(e){let n=t.Xe.exec(e);if(!n)return;let r=(n[1]+(n[2]??"")).split(",").map(c=>c.trim()),o=r.length>1?r.length-1:-1,s=o!==-1&&(r[o]==="index"||r[o]?.startsWith("#"))?r[o]:"";s&&r.splice(o,1);let i=n[3];if(!i||r.length===0)return;let a=/[{[]/.test(e);return{list:i,createContext:(c,f)=>{let p={},l=V(c);if(!a&&r.length===1)p[r[0]]=c;else if(T(l)){let u=0;for(let y of r)p[y]=l[u++]}else for(let u of r)p[u]=l[u];let b={ctx:p,index:z(-1)};return s&&(b.index=p[s.startsWith("#")?s.substring(1):s]=z(f)),b}}}};var $r=(t,e)=>{for(let n of t){let r=n.cloneNode(!0);e.appendChild(r)}},ht=class{p;D;ue;constructor(e){this.p=e,this.D=e.o.l.is,this.ue=Ie(this.D)+", [is]"}N(e){let n=e.hasAttribute(this.D),r=me(e,this.ue);for(let o of r)this.x(o);return n}x(e){let n=e.getAttribute(this.D);if(!n){if(n=e.getAttribute("is"),!n||!n.startsWith("regor:"))return;n=`'${n.slice(6)}'`,e.removeAttribute("is")}e.removeAttribute(this.D),this.V(e,n)}B(e,n){let r=ke(e),o=e.parentNode,s=document.createComment(`__begin__ dynamic ${n??""}`);o.insertBefore(s,e),Me(s,r),r.forEach(a=>{$(a)}),e.remove();let i=document.createComment(`__end__ dynamic ${n??""}`);return o.insertBefore(i,s.nextSibling),{nodes:r,parent:o,commentBegin:s,commentEnd:i}}V(e,n){let{nodes:r,parent:o,commentBegin:s,commentEnd:i}=this.B(e,` => ${n} `),a=this.p.h.v(n),c=a.value,f=this.p.h,p=f.k(),l={name:""},b=te(e)?r:[...r[0].childNodes],u=()=>{f.C(p,()=>{let h=c()[0];if(w(h)&&(h.name?h=h.name:h=Object.entries(f.me()).filter(O=>O[1]===h)[0]?.[0]),!U(h)||j(h)){ie(s,i);return}if(l.name===h)return;ie(s,i);let A=document.createElement(h);for(let O of e.getAttributeNames())O!==this.D&&A.setAttribute(O,e.getAttribute(O));$r(b,A),o.insertBefore(A,i),this.p.G(A),l.name=h})},y=[];_(s,()=>{a.stop();for(let h of y)h();y.length=0}),u();let S=R(c,u);y.push(S)}};var Dn={collectRefObj:!0,onBind:(t,e)=>R(e.value,()=>{let r=e.value(),o=e.context,s=r[0];if(w(s))for(let i of Object.entries(s)){let a=i[0],c=i[1],f=o[a];f!==c&&(m(f)?f(c):o[a]=c)}},!0)};var Un={collectRefObj:!0,once:!0,onBind:(t,e)=>{let n=e.value(),r=e.context,o=n[0];if(!w(o))return()=>{};for(let s of Object.entries(o)){let i=s[0],a=s[1],c=r[i];c!==a&&(m(c)?c(a):r[i]=a)}return()=>{}}};var he=t=>{ot(t)?.onUnmounted?.forEach(n=>{n()}),t.unmounted?.()};var Ye=class{props;start;end;ctx;autoProps=!0;entangle=!0;disableSwitch=!1;onAutoPropsAssigned;de;constructor(e,n,r,o,s){this.props=e,this.de=n,this.ctx=r,this.start=o,this.end=s}emit=(e,n)=>{this.de.dispatchEvent(new CustomEvent(e,{detail:n}))};unmount(){let e=this.start.nextSibling,n=this.end;for(;e&&e!==n;)$(e),e=e.nextSibling;he(this)}};var Jt=Symbol("scope"),Qt=t=>{try{En();let e=t();Bt(e);let n={context:e,unmount:()=>he(e),[Jt]:1};return n[Jt]=1,n}finally{vn()}},Hn=t=>w(t)?Jt in t:!1;var Xt=(t,e)=>{if(t===e)return()=>{};let n=R(t,o=>e(o)),r=R(e,o=>t(o));return e(t()),()=>{n(),r()}};var gt=t=>{ot(t)?.onMounted?.forEach(n=>{n()}),t.mounted?.()};var _n={collectRefObj:!0,onBind:(t,e,n,r,o,s)=>{if(!r)return()=>{};let i=B(r);return R(e.value,()=>{let c=e.refs[0]??e.value()[0],f=e.context,p=f[r];p!==c&&(m(p)?p(c):f[i]=c)},!0)}};var bt=class{p;ye;constructor(e){this.p=e,this.ye=e.o.l.inherit}N(e){this.Ye(e)}Ye(e){let n=this.p,r=n.h,o=n.o.he,s=n.o.ge,i=r.me(),a=[...o.keys(),...Object.keys(i),...[...o.keys()].map(De),...[...Object.keys(i)].map(De)].join(",");if(j(a))return;let c=e.querySelectorAll(a),f=e.matches?.(a)?[e,...c]:c;for(let p of f){if(p.hasAttribute(n.T))continue;let l=p.parentNode;if(!l)continue;let b=p.nextSibling,u=B(p.tagName).toUpperCase(),v=i[u]??s.get(u);if(!v)continue;let S=v.template;if(!S)continue;let h=p.parentElement;if(!h)continue;let A=new Comment(" begin component: "+p.tagName),O=new Comment(" end component: "+p.tagName);h.insertBefore(A,p),p.remove();let be=n.o.l.props,qe=n.o.l.propsOnce,It=n.o.l.bind,tt=(d,M)=>{let g={},I=d.hasAttribute(be),K=d.hasAttribute(qe);return r.C(M,()=>{r.w(g),I&&n.x(Dn,d,be),K&&n.x(Un,d,qe);let E=v.props;if(!E||E.length===0)return;E=E.map(B);for(let Ee of E.concat(E.map(De))){let re=d.getAttribute(Ee);re!==null&&(g[B(Ee)]=re,d.removeAttribute(Ee))}let P=n.ee.be(d,!1);for(let[Ee,re]of P.entries()){let[ve,Dt]=re.te;Dt&&E.includes(B(Dt))&&(ve!=="."&&ve!==":"&&ve!==It||n.x(_n,d,Ee,!0,Dt,re.ne))}}),g},Te=[...r.k()],nt=()=>{let d=tt(p,Te),M=new Ye(d,p,Te,A,O),g=Qt(()=>v.context(M)??{}).context;if(M.autoProps){for(let[I,K]of Object.entries(d))if(I in g){let E=g[I];if(E===K)continue;M.entangle&&m(E)&&m(K)?_(A,Xt(K,E)):m(E)?E(K):g[I]=V(K)}else g[I]=K;M.onAutoPropsAssigned?.()}return{componentCtx:g,head:M}},{componentCtx:le,head:ze}=nt(),ne=[...ae(S)],L=ne.length,x=p.childNodes.length===0,N=d=>{let M=d.parentElement;if(x){for(let E of[...d.childNodes])M.insertBefore(E,d);return}let g=d.name;j(g)&&(g=d.getAttributeNames().filter(E=>E.startsWith("#"))[0],j(g)?g="default":g=g.substring(1));let I=p.querySelector(`template[name='${g}'], template[\\#${g}]`);!I&&g==="default"&&(I=p.querySelector("template:not([name])"),I&&I.getAttributeNames().filter(E=>E.startsWith("#")).length>0&&(I=null));let K=E=>{ze.disableSwitch||r.C(Te,()=>{r.w(le);let P=tt(d,r.k());r.C(Te,()=>{r.w(P);let Ee=r.k(),re=Rn(Ee);for(let ve of E)Re(ve)&&(ve.setAttribute(We,re),Vt(re),_(ve,()=>{Pt(re)}))})})};if(I){let E=[...ae(I)];for(let P of E)M.insertBefore(P,d);K(E)}else{if(g!=="default"){for(let P of[...ae(d)])M.insertBefore(P,d);return}let E=[...ae(p)].filter(P=>!te(P));for(let P of E)M.insertBefore(P,d);K(E)}},F=d=>{if(!Re(d))return;let M=d.querySelectorAll("slot");if(On(d)){N(d),d.remove();return}for(let g of M)N(g),g.remove()};(()=>{for(let d=0;d<L;++d)ne[d]=ne[d].cloneNode(!0),l.insertBefore(ne[d],b),F(ne[d])})(),h.insertBefore(O,b);let Q=()=>{if(!v.inheritAttrs)return;let d=ne.filter(g=>g.nodeType===Node.ELEMENT_NODE);d.length>1&&(d=d.filter(g=>g.hasAttribute(this.ye)));let M=d[0];if(M)for(let g of p.getAttributeNames()){if(g===be||g===qe)continue;let I=p.getAttribute(g);if(g==="class")M.classList.add(...I.split(" "));else if(g==="style"){let K=M.style,E=p.style;for(let P of E)K.setProperty(P,E.getPropertyValue(P))}else M.setAttribute(lt(g,n.o),I)}},ee=()=>{for(let d of p.getAttributeNames())!d.startsWith("@")&&!d.startsWith(n.o.l.on)&&p.removeAttribute(d)},Oe=()=>{Q(),ee(),r.w(le),n.Te(p,!1),le.$emit=ze.emit,de(n,ne),_(p,()=>{he(le)}),_(A,()=>{se(p)}),gt(le)};r.C(Te,Oe)}}};var Yt=class{xe;te=[];ne=[];Ee=[];constructor(e){this.xe=e,this.v()}v(){let e=this.xe,n=e.startsWith(".");n&&(e=":"+e.slice(1));let r=e.indexOf("."),o=this.te=(r<0?e:e.substring(0,r)).split(/[:@]/);if(j(o[0])&&(o[0]=n?".":e[0]),r>=0){let s=this.ne=e.slice(r+1).split(".");if(s.includes("camel")){let i=o.length-1;o[i]=B(o[i])}s.includes("prop")&&(o[0]=".")}}},Tt=class{p;Re;constructor(e){this.p=e,this.Re=e.o.Ze()}be(e,n){let r=new Map;if(!Ge(e))return r;let o=this.Re,s=a=>{let c=a.getAttributeNames().filter(f=>o.some(p=>f.startsWith(p)));for(let f of c)r.has(f)||r.set(f,new Yt(f)),r.get(f).Ee.push(a)};if(s(e),!n)return r;let i=e.querySelectorAll("*");for(let a of i)s(a);return r}};var Et={};var vt=class{h;ve;Ce;Se;we;ee;o;T;Ae;constructor(e){this.h=e,this.o=e.o,this.Ce=new yt(this),this.ve=new ft(this),this.Se=new ht(this),this.we=new bt(this),this.ee=new Tt(this),this.T=this.o.l.pre,this.Ae=this.o.l.dynamic}et(e){let n=te(e)?[e]:e.querySelectorAll("template");for(let r of n){if(r.hasAttribute(this.T))continue;let o=r.parentNode;if(!o)continue;let s=r.nextSibling;if(r.remove(),!r.content)continue;let i=[...r.content.childNodes];for(let a of i)o.insertBefore(a,s);de(this,i)}}G(e){e.nodeType!==Node.ELEMENT_NODE||e.hasAttribute(this.T)||this.ve.N(e)||this.Ce.N(e)||this.Se.N(e)||(this.we.N(e),this.et(e),this.Te(e,!0))}Te(e,n){let r=this.ee.be(e,n),o=this.o.H;for(let[s,i]of r.entries()){let[a,c]=i.te,f=o[s]??o[a];if(!f){console.error("directive not found:",a);continue}i.Ee.forEach(p=>{this.x(f,p,s,!1,c,i.ne)})}}x(e,n,r,o,s,i){if(n.hasAttribute(this.T))return;let a=n.getAttribute(r);n.removeAttribute(r);let c=f=>{let p=f.getAttribute(We);return p||(f.parentElement?c(f.parentElement):null)};if(jt()){let f=c(n);if(f){this.h.C(Sn(f),()=>{this.V(e,n,a,s,i)});return}}this.V(e,n,a,s,i)}tt(e,n,r){if(e!==Et)return!1;if(j(r))return!0;let o=document.querySelector(r);if(o){let s=n.parentElement;if(!s)return!0;let i=new Comment(`teleported => '${r}'`);s.insertBefore(i,n),n.teleportedFrom=i,i.teleportedTo=n,_(i,()=>{$(n)}),o.appendChild(n)}return!0}V(e,n,r,o,s){if(n.nodeType!==Node.ELEMENT_NODE||r==null||this.tt(e,n,r))return;let i=this.h.v(r,e.isLazy,e.isLazyKey,e.collectRefObj,e.once),a=[];_(n,()=>{i.stop(),p?.stop();for(let S of a)S();a.length=0});let f=Nn(o,this.Ae),p;f&&(p=this.h.v(B(f),void 0,void 0,void 0,e.once));let l,b=()=>(l=i.value(),l),u,y=()=>p?(u=p.value()[0],u):(u=o,o),v=()=>{if(!e.onChange)return;let S=R(i.value,h=>{let A=l,O=u;e.onChange?.(n,b(),A,y(),O,s)});if(a.push(S),p){let h=R(p.value,A=>{let O=u;e.onChange?.(n,b(),O,y(),O,s)});a.push(h)}};e.once||v(),e.onBind&&a.push(e.onBind(n,i,r,o,p,s)),e.onChange?.(n,b(),void 0,y(),void 0,s)}};var Fr=9,qr=10,zr=13,Kr=32,ge=46,xt=44,Wr=39,Gr=34,Ct=40,_e=41,Rt=91,St=93,Zt=63,Jr=59,Bn=58,Qr=123,wt=125,tn=43,Xr=45,Vn=96,Pn=47,Yr=92,jn=[2,3],$n=[tn,Xr],Gn={"-":1,"!":1,"~":1,"+":1,new:1},Jn={"=":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},Ve={"=>":2,...Jn,"||":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},Qn=Object.keys(Jn),Zr=new Set(Qn),At=new Set;At.add("=>");Qn.forEach(t=>At.add(t));var eo=new Set(["$","_"]),Fn={true:!0,false:!1,null:null},to="this";function Xn(t){return Math.max(0,...Object.keys(t).map(e=>e.length))}var no=Xn(Gn),ro=Xn(Ve),Pe="Expected ",we="Unexpected ",rn="Unclosed ",oo=Pe+":",qn=Pe+"expression",so="missing }",io=we+"object property",ao=rn+"(",zn=Pe+"comma",Kn=we+"token ",co=we+"period",en=Pe+"expression after ",po="missing unaryOp argument",fo=rn+"[",lo=Pe+"exponent (",uo="Variable names cannot start with a number (",mo=rn+'quote after "';var Be=t=>t>=48&&t<=57,Wn=t=>Ve[t]||0,nn=class{nt={0:[this.rt],1:[this.ot,this.st,this.it],2:[this.at,this.pt,this.ct,this.Oe,this.lt],3:[this.ft,this.ut,this.mt]};r;e;get M(){return this.r.charAt(this.e)}get f(){return this.r.charCodeAt(this.e)}u(e){return this.r.charCodeAt(this.e)===e}constructor(e){this.r=e,this.e=0}U(e){let n=String.fromCharCode(e);return e>=65&&e<=90||e>=97&&e<=122||e>=128&&!(n in Ve)||eo.has(n)}re(e){return this.U(e)||Be(e)}i(e){return new Error(`${e} at character ${this.e}`)}L(e,n,r){let o=this.nt[e];if(!o)return r;let s={node:r},i=a=>{a.call(this,s)};return n===0?o.forEach(i):o.find(i),s.node}y(){let e=this.f,n=this.r,r=this.e;for(;e===Kr||e===Fr||e===qr||e===zr;)e=n.charCodeAt(++r);this.e=r}parse(){let e=this.oe();return e.length===1?e[0]:{type:0,body:e}}oe(e){let n=[];for(;this.e<this.r.length;){let r=this.f;if(r===Jr||r===xt)this.e++;else{let o=this.A();if(o)n.push(o);else if(this.e<this.r.length){if(r===e)break;throw this.i(we+'"'+this.M+'"')}}}return n}A(){let e=this.L(0,1)??this.Ne();return this.y(),this.L(1,0,e)}se(){this.y();let e=this.e,n=this.r,r=n.substr(e,ro),o=r.length;for(;o>0;){if(r in Ve&&(!this.U(this.f)||e+r.length<n.length&&!this.re(n.charCodeAt(e+r.length))))return e+=o,this.e=e,r;r=r.substr(0,--o)}return!1}Ne(){let e,n,r,o,s,i,a,c;if(s=this.j(),!s||(n=this.se(),!n))return s;if(o={value:n,prec:Wn(n),right_a:At.has(n)},i=this.j(),!i)throw this.i(en+n);let f=[s,o,i];for(;n=this.se();){if(r=Wn(n),r===0){this.e-=n.length;break}o={value:n,prec:r,right_a:At.has(n)},c=n;let p=l=>o.right_a&&l.right_a?r>l.prec:r<=l.prec;for(;f.length>2&&p(f[f.length-2]);)i=f.pop(),n=f.pop().value,s=f.pop(),e={type:8,operator:n,left:s,right:i},f.push(e);if(e=this.j(),!e)throw this.i(en+c);f.push(o,e)}for(a=f.length-1,e=f[a];a>1;)e={type:8,operator:f[a-1].value,left:f[a-2],right:e},a-=2;return e}j(){let e,n,r;if(this.y(),r=this.L(2,1),r)return this.L(3,0,r);let o=this.f;if(Be(o)||o===ge)return this.dt();if(o===Wr||o===Gr)r=this.yt();else if(o===Rt)r=this.ht();else{for(e=this.r.substr(this.e,no),n=e.length;n>0;){if(Object.prototype.hasOwnProperty.call(Gn,e)&&(!this.U(this.f)||this.e+e.length<this.r.length&&!this.re(this.r.charCodeAt(this.e+e.length)))){this.e+=n;let s=this.j();if(!s)throw this.i(po);return this.L(3,0,{type:7,operator:e,argument:s})}e=e.substr(0,--n)}this.U(o)?(r=this.ie(),r.name in Fn?r={type:4,value:Fn[r.name],raw:r.name}:r.name===to&&(r={type:5})):o===Ct&&(r=this.gt())}return r?(r=this.F(r),this.L(3,0,r)):this.L(3,0,!1)}F(e){this.y();let n=this.f;for(;n===ge||n===Rt||n===Ct||n===Zt;){let r;if(n===Zt){if(this.r.charCodeAt(this.e+1)!==ge)break;r=!0,this.e+=2,this.y(),n=this.f}if(this.e++,n===Rt){if(e={type:3,computed:!0,object:e,property:this.A()},this.y(),n=this.f,n!==St)throw this.i(fo);this.e++}else n===Ct?e={type:6,arguments:this.Me(_e),callee:e}:(n===ge||r)&&(r&&this.e--,this.y(),e={type:3,computed:!1,object:e,property:this.ie()});r&&(e.optional=!0),this.y(),n=this.f}return e}dt(){let e="",n;for(;Be(this.f);)e+=this.r.charAt(this.e++);if(this.u(ge))for(e+=this.r.charAt(this.e++);Be(this.f);)e+=this.r.charAt(this.e++);if(n=this.M,n==="e"||n==="E"){for(e+=this.r.charAt(this.e++),n=this.M,(n==="+"||n==="-")&&(e+=this.r.charAt(this.e++));Be(this.f);)e+=this.r.charAt(this.e++);if(!Be(this.r.charCodeAt(this.e-1)))throw this.i(lo+e+this.M+")")}let r=this.f;if(this.U(r))throw this.i(uo+e+this.M+")");if(r===ge||e.length===1&&e.charCodeAt(0)===ge)throw this.i(co);return{type:4,value:parseFloat(e),raw:e}}yt(){let e="",n=this.e,r=this.r.charAt(this.e++),o=!1;for(;this.e<this.r.length;){let s=this.r.charAt(this.e++);if(s===r){o=!0;break}else if(s==="\\")switch(s=this.r.charAt(this.e++),s){case"n":e+=`
2
2
  `;break;case"r":e+="\r";break;case"t":e+=" ";break;case"b":e+="\b";break;case"f":e+="\f";break;case"v":e+="\v";break;default:e+=s}else e+=s}if(!o)throw this.i(mo+e+'"');return{type:4,value:e,raw:this.r.substring(n,this.e)}}ie(){let e=this.f,n=this.e;if(this.U(e))this.e++;else throw this.i(we+this.M);for(;this.e<this.r.length&&(e=this.f,this.re(e));)this.e++;return{type:2,name:this.r.slice(n,this.e)}}Me(e){let n=[],r=!1,o=0;for(;this.e<this.r.length;){this.y();let s=this.f;if(s===e){if(r=!0,this.e++,e===_e&&o&&o>=n.length)throw this.i(Kn+String.fromCharCode(e));break}else if(s===xt){if(this.e++,o++,o!==n.length){if(e===_e)throw this.i(Kn+",");if(e===St)for(let i=n.length;i<o;i++)n.push(null)}}else{if(n.length!==o&&o!==0)throw this.i(zn);{let i=this.A();if(!i||i.type===0)throw this.i(zn);n.push(i)}}}if(!r)throw this.i(Pe+String.fromCharCode(e));return n}gt(){this.e++;let e=this.oe(_e);if(this.u(_e))return this.e++,e.length===1?e[0]:e.length?{type:1,expressions:e}:!1;throw this.i(ao)}ht(){return this.e++,{type:9,elements:this.Me(St)}}at(e){if(this.u(Qr)){this.e++;let n=[];for(;!isNaN(this.f);){if(this.y(),this.u(wt)){this.e++,e.node=this.F({type:10,properties:n});return}let r=this.A();if(!r)break;if(this.y(),r.type===2&&(this.u(xt)||this.u(wt)))n.push({type:12,computed:!1,key:r,value:r,shorthand:!0});else if(this.u(Bn)){this.e++;let o=this.A();if(!o)throw this.i(io);let s=r.type===9;n.push({type:12,computed:s,key:s?r.elements[0]:r,value:o,shorthand:!1}),this.y()}else r&&n.push(r);this.u(xt)&&this.e++}throw this.i(so)}}pt(e){let n=this.f;if($n.some(r=>r===n&&r===this.r.charCodeAt(this.e+1))){this.e+=2;let r=e.node={type:13,operator:n===tn?"++":"--",argument:this.F(this.ie()),prefix:!0};if(!r.argument||!jn.includes(r.argument.type))throw this.i(we+r.operator)}}ut(e){if(e.node){let n=this.f;if($n.some(r=>r===n&&r===this.r.charCodeAt(this.e+1))){if(!jn.includes(e.node.type))throw this.i(we+e.node.operator);this.e+=2,e.node={type:13,operator:n===tn?"++":"--",argument:e.node,prefix:!1}}}}ct(e){[0,1,2].every(n=>this.r.charCodeAt(this.e+n)===ge)&&(this.e+=3,e.node={type:14,argument:this.A()})}it(e){if(e.node&&this.u(Zt)){this.e++;let n=e.node,r=this.A();if(!r)throw this.i(qn);if(this.y(),this.u(Bn)){this.e++;let o=this.A();if(!o)throw this.i(qn);if(e.node={type:11,test:n,consequent:r,alternate:o},n.operator&&Ve[n.operator]<=.9){let s=n;for(;s.right.operator&&Ve[s.right.operator]<=.9;)s=s.right;e.node.test=s.right,s.right=e.node,e.node=n}}else throw this.i(oo)}}rt(e){if(this.y(),this.u(Ct)){let n=this.e;if(this.e++,this.y(),this.u(_e)){this.e++;let r=this.se();if(r==="=>"){let o=this.Ne();if(!o)throw this.i(en+r);e.node={type:15,params:null,body:o};return}}this.e=n}}ot(e){this.Le(e.node)}Le(e){e&&(Object.values(e).forEach(n=>{n&&typeof n=="object"&&this.Le(n)}),e.operator==="=>"&&(e.type=15,e.params=e.left?[e.left]:null,e.body=e.right,e.params&&e.params[0].type===1&&(e.params=e.params[0].expressions),delete e.left,delete e.right,delete e.operator))}st(e){e.node&&this.$(e.node)}$(e){Zr.has(e.operator)?(e.type=16,this.$(e.left),this.$(e.right)):e.operator||Object.values(e).forEach(n=>{n&&typeof n=="object"&&this.$(n)})}mt(e){if(!e.node)return;let n=e.node.type;(n===2||n===3)&&this.u(Vn)&&(e.node={type:17,tag:e.node,quasi:this.Oe(e)})}Oe(e){if(!this.u(Vn))return;let n={type:19,quasis:[],expressions:[]},r="",o="",s=!1,i=this.r.length,a=()=>n.quasis.push({type:18,value:{raw:o,cooked:r},tail:s});for(;this.e<i;){let c=this.r.charAt(++this.e);if(c==="`")return this.e+=1,s=!0,a(),e.node=n,n;if(c==="$"&&this.r.charAt(this.e+1)==="{"){if(this.e+=2,a(),o="",r="",n.expressions.push(...this.oe(wt)),!this.u(wt))throw this.i("unclosed ${")}else if(c==="\\")switch(o+=c,c=this.r.charAt(++this.e),o+=c,c){case"n":r+=`
3
- `;break;case"r":r+="\r";break;case"t":r+=" ";break;case"b":r+="\b";break;case"f":r+="\f";break;case"v":r+="\v";break;default:r+=c}else r+=c,o+=c}throw this.i("Unclosed `")}ft(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 r=e.node;for(;r.type===3||r.type===6&&r?.callee?.type===3;)r=r.type===3?r.object:r.callee.object;r.type=20}lt(e){if(!this.u(Pn))return;let n=++this.e,r=!1;for(;this.e<this.r.length;){if(this.f===Pn&&!r){let o=this.r.slice(n,this.e),s="";for(;++this.e<this.r.length;){let a=this.f;if(a>=97&&a<=122||a>=65&&a<=90||a>=48&&a<=57)s+=this.M;else break}let i;try{i=new RegExp(o,s)}catch(a){throw this.i(a.message)}return e.node={type:4,value:i,raw:this.r.slice(n-1,this.e)},e.node=this.F(e.node),e.node}this.u(Rt)?r=!0:r&&this.u(St)&&(r=!1),this.e+=this.u(Yr)?2:1}throw this.i("Unclosed Regex")}},Yn=t=>new nn(t).parse();var yo={"=>":(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,"&":(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},ho={"-":t=>-t,"+":t=>+t,"!":t=>!t,"~":t=>~t,new:t=>t},nr=t=>{if(!t?.some(tr))return t;let e=[];return t.forEach(n=>tr(n)?e.push(...n):e.push(n)),e},Zn=(...t)=>nr(t),on=(t,e)=>{if(!t)return e;let n=Object.create(e??{});return n.$event=t,n},go={"++":(t,e)=>{let n=t[e];if(m(n)){let r=n();return n(++r),r}return++t[e]},"--":(t,e)=>{let n=t[e];if(m(n)){let r=n();return n(--r),r}return--t[e]}},bo={"++":(t,e)=>{let n=t[e];if(m(n)){let r=n();return n(r+1),r}return t[e]++},"--":(t,e)=>{let n=t[e];if(m(n)){let r=n();return n(r-1),r}return t[e]--}},er={"=":(t,e,n)=>{let r=t[e];return m(r)?r(n):t[e]=n},"+=":(t,e,n)=>{let r=t[e];return m(r)?r(r()+n):t[e]+=n},"-=":(t,e,n)=>{let r=t[e];return m(r)?r(r()-n):t[e]-=n},"*=":(t,e,n)=>{let r=t[e];return m(r)?r(r()*n):t[e]*=n},"/=":(t,e,n)=>{let r=t[e];return m(r)?r(r()/n):t[e]/=n},"%=":(t,e,n)=>{let r=t[e];return m(r)?r(r()%n):t[e]%=n},"**=":(t,e,n)=>{let r=t[e];return m(r)?r(r()**n):t[e]**=n},"<<=":(t,e,n)=>{let r=t[e];return m(r)?r(r()<<n):t[e]<<=n},">>=":(t,e,n)=>{let r=t[e];return m(r)?r(r()>>n):t[e]>>=n},">>>=":(t,e,n)=>{let r=t[e];return m(r)?r(r()>>>n):t[e]>>>=n},"|=":(t,e,n)=>{let r=t[e];return m(r)?r(r()|n):t[e]|=n},"&=":(t,e,n)=>{let r=t[e];return m(r)?r(r()&n):t[e]&=n},"^=":(t,e,n)=>{let r=t[e];return m(r)?r(r()^n):t[e]^=n}},Ot=(t,e)=>D(t)?t.bind(e):t,sn=class{m;ke;Ve;Ie;O;De;Ue;constructor(e,n,r,o,s){this.m=T(e)?e:[e],this.ke=n,this.Ve=r,this.Ie=o,this.Ue=!!s}Pe(e,n){if(n&&e in n)return n;for(let r of this.m)if(e in r)return r}2(e,n,r){let o=e.name;if(o==="$root")return this.m[this.m.length-1];if(o==="$parent")return this.m[1];if(o==="$ctx")return[...this.m];if(r&&o in r)return this.O=r[o],Ot(V(r[o]),r);for(let i of this.m)if(o in i)return this.O=i[o],Ot(V(i[o]),i);let s=this.ke;if(s&&o in s)return this.O=s[o],Ot(V(s[o]),s)}5(e,n,r){return this.m[0]}0(e,n,r){return this.Be(n,r,Zn,...e.body)}1(e,n,r){return this.R(n,r,(...o)=>o.pop(),...e.expressions)}3(e,n,r){let{obj:o,key:s}=this.ae(e,n,r),i=o?.[s];return this.O=i,Ot(V(i),o)}4(e,n,r){return e.value}6(e,n,r){let o=(i,...a)=>D(i)?i(...nr(a)):i,s=this.R(++n,r,o,e.callee,...e.arguments);return this.O=s,s}7(e,n,r){return this.R(n,r,ho[e.operator],e.argument)}8(e,n,r){let o=yo[e.operator];switch(e.operator){case"||":case"&&":case"??":return o(()=>this.g(e.left,n,r),()=>this.g(e.right,n,r))}return this.R(n,r,o,e.left,e.right)}9(e,n,r){return this.Be(++n,r,Zn,...e.elements)}10(e,n,r){let o={},s=(...i)=>{i.forEach(a=>{Object.assign(o,a)})};return this.R(++n,r,s,...e.properties),o}11(e,n,r){return this.R(n,r,o=>this.g(o?e.consequent:e.alternate,n,r),e.test)}12(e,n,r){let o={},s=p=>p?.type!==15,i=this.Ie??(()=>!1),a=n===0&&this.Ue,c=p=>this._e(a,e.key,n,on(p,r)),f=p=>this._e(a,e.value,n,on(p,r));if(e.shorthand){let p=e.key.name;o[p]=s(e.key)&&i(p,n)?c:c()}else if(e.computed){let p=V(c());o[p]=s(e.value)&&i(p,n)?f:f()}else{let p=e.key.type===4?e.key.value:e.key.name;o[p]=s(e.value)&&i(p,n)?()=>f:f()}return o}ae(e,n,r){let o=this.g(e.object,n,r),s=e.computed?this.g(e.property,n,r):e.property.name;return{obj:o,key:s}}13(e,n,r){let o=e.argument,s=e.operator,i=e.prefix?go:bo;if(o.type===2){let a=o.name,c=this.Pe(a,r);return Y(c)?void 0:i[s](c,a)}if(o.type===3){let{obj:a,key:c}=this.ae(o,n,r);return i[s](a,c)}}16(e,n,r){let o=e.left,s=e.operator;if(o.type===2){let i=o.name,a=this.Pe(i,r);if(Y(a))return;let c=this.g(e.right,n,r);return er[s](a,i,c)}if(o.type===3){let{obj:i,key:a}=this.ae(o,n,r),c=this.g(e.right,n,r);return er[s](i,a,c)}}14(e,n,r){let o=this.g(e.argument,n,r);return T(o)&&(o.s=rr),o}17(e,n,r){return this[6]({type:6,callee:e.tag,arguments:[{type:9,elements:e.quasi.quasis},...e.quasi.expressions]},n,r)}19(e,n,r){let o=(...s)=>s.reduce((i,a,c)=>i+=a+e.quasis[c+1].value.cooked,e.quasis[0].value.cooked);return this.R(n,r,o,...e.expressions)}18(e,n,r){return e.value.cooked}20(e,n,r){let o=(s,...i)=>new s(...i);return this.R(n,r,o,e.callee,...e.arguments)}15(e,n,r){return(...o)=>{let s=Object.create(r??{}),i=e.params;if(i){let a=0;for(let c of i)s[c.name]=o[a++]}return this.g(e.body,n,s)}}g(e,n,r){let o=V(this[e.type](e,n,r));return this.De=e.type,o}_e(e,n,r,o){let s=this.g(n,r,o);return e&&this.He()?this.O:s}He(){let e=this.De;return(e===2||e===3||e===6)&&m(this.O)}eval(e,n){let{value:r,refs:o}=Kt(()=>this.g(e,-1,n)),s={value:r,refs:o};return this.He()&&(s.ref=this.O),s}R(e,n,r,...o){let s=o.map(i=>i&&this.g(i,e,n));return r(...s)}Be(e,n,r,...o){let s=this.Ve;if(!s)return this.R(e,n,r,...o);let i=o.map((a,c)=>a&&(a.type!==15&&s(c,e)?f=>this.g(a,e,on(f,n)):this.g(a,e,n)));return r(...i)}},rr=Symbol("s"),tr=t=>t?.s===rr,or=(t,e,n,r,o,s,i)=>new sn(e,n,r,o,i).eval(t,s);var sr={},Nt=class{m;o;constructor(e,n){this.m=e,this.o=n}w(e){this.m=[e,...this.m]}me(){return this.m.map(n=>n.components).filter(n=>!!n).reverse().reduce((n,r)=>{for(let[o,s]of Object.entries(r))n[o.toUpperCase()]=s;return n},{})}v(e,n,r,o,s){let i=z([]),a=[],c=()=>{for(let u of a)u();a.length=0},f={value:i,stop:c,refs:[],context:this.m[0]};if(j(e))return f;let p=this.o.globalContext,l=[],b=(u,y,v,S)=>{try{let h=or(u,y,p,n,r,S,o);return v&&l.push(...h.refs),{value:h.value,refs:h.refs,ref:h.ref}}catch(h){k(6,`evaluation error: ${e}`,h)}return{value:void 0,refs:[]}};try{let u=sr[e]??Yn("["+e+"]");sr[e]=u;let y=this.m,v=()=>{l.splice(0),c();let S=u.elements.map((h,A)=>n?.(A,-1)?{value:O=>b(h,y,!1,{$event:O}).value,refs:[]}:b(h,y,!0));if(!s)for(let h of l){let A=R(h,v);a.push(A)}i(S.map(h=>h.value)),f.refs=S.map(h=>h.ref)};v()}catch(u){k(6,`parse error: ${e}`,u)}return f}V(){return this.m}je=[];Y(e){this.je.push(this.m),this.m=e}C(e,n){try{this.Y(e),n()}finally{this.bt()}}bt(){this.m=this.je.pop()??[]}};var ir="http://www.w3.org/1999/xlink",To={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 Eo(t){return!!t||t===""}var an={onChange:(t,e,n,r,o,s)=>{if(r){s&&s.includes("camel")&&(r=B(r)),Mt(t,r,e[0],o);return}let i=e.length;for(let a=0;a<i;++a){let c=e[a];if(T(c)){let f=n?.[a]?.[0],p=c[0],l=c[1];Mt(t,p,l,f)}else if(w(c))for(let f of Object.entries(c)){let p=f[0],l=f[1],b=n?.[a],u=b&&p in b?p:void 0;Mt(t,p,l,u)}else{let f=n?.[a],p=e[a++],l=e[a];Mt(t,p,l,f)}}}},Mt=(t,e,n,r)=>{if(r&&r!==e&&t.removeAttribute(r),Y(e)){k(3,name,t);return}if(!U(e)){k(6,`Attribute key is not string at ${t.outerHTML}`,e);return}if(e.startsWith("xlink:")){Y(n)?t.removeAttributeNS(ir,e.slice(6,e.length)):t.setAttributeNS(ir,e,n);return}let o=e in To;Y(n)||o&&!Eo(n)?t.removeAttribute(e):t.setAttribute(e,o?"":n)};var cn={onChange:(t,e,n)=>{let r=e.length;for(let o=0;o<r;++o){let s=e[o],i=n?.[o];if(T(s)){let a=s.length;for(let c=0;c<a;++c)ar(t,s[c],i?.[c])}else ar(t,s,i)}}},ar=(t,e,n)=>{let r=t.classList,o=U(e),s=U(n);if(e&&!o){if(n&&!s)for(let i in n)i in e||r.remove(i);for(let i in e)e[i]&&r.add(i)}else o?n!==e&&(s&&r.remove(...n?.split(",")),r.add(...e.split(","))):n&&s&&r.remove(...n?.split(","))};var cr={onChange:(t,e)=>{let[n,r]=e;D(r)?r(t,n):t.innerHTML=n?.toString()}};function vo(t,e){if(t.length!==e.length)return!1;let n=!0;for(let r=0;n&&r<t.length;r++)n=ce(t[r],e[r]);return n}function ce(t,e){if(t===e)return!0;let n=Ht(t),r=Ht(e);if(n||r)return n&&r?t.getTime()===e.getTime():!1;if(n=Ke(t),r=Ke(e),n||r)return t===e;if(n=T(t),r=T(e),n||r)return n&&r?vo(t,e):!1;if(n=w(t),r=w(e),n||r){if(!n||!r)return!1;let o=Object.keys(t).length,s=Object.keys(e).length;if(o!==s)return!1;for(let i in t){let a=t.hasOwnProperty(i),c=e.hasOwnProperty(i);if(a&&!c||!a&&c||!ce(t[i],e[i]))return!1}}return String(t)===String(e)}function Lt(t,e){return t.findIndex(n=>ce(n,e))}var pr=t=>{let e=parseFloat(t);return isNaN(e)?t:e};var pn=t=>{if(!m(t))throw H(3,"pause");t(void 0,void 0,3)};var fn=t=>{if(!m(t))throw H(3,"resume");t(void 0,void 0,4)};var lr={onChange:(t,e)=>{xo(t,e[0])},onBind:(t,e,n,r,o,s)=>Co(t,e,s)},xo=(t,e)=>{let n=yr(t);if(n&&ur(t))T(e)?e=Lt(e,pe(t))>-1:X(e)?e=e.has(pe(t)):e=No(t,e),t.checked=e;else if(n&&mr(t))t.checked=ce(e,pe(t));else if(n||hr(t))dr(t)?t.value!==e?.toString()&&(t.value=e):t.value!==e&&(t.value=e);else if(gr(t)){let r=t.options,o=r.length,s=t.multiple;for(let i=0;i<o;i++){let a=r[i],c=pe(a);if(s)T(e)?a.selected=Lt(e,c)>-1:a.selected=e.has(c);else if(ce(pe(a),e)){t.selectedIndex!==i&&(t.selectedIndex=i);return}}!s&&t.selectedIndex!==-1&&(t.selectedIndex=-1)}else k(7,t)},Ze=t=>(m(t)&&(t=t()),D(t)&&(t=t()),t?U(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}),ur=t=>t.type==="checkbox",mr=t=>t.type==="radio",dr=t=>t.type==="number"||t.type==="range",yr=t=>t.tagName==="INPUT",hr=t=>t.tagName==="TEXTAREA",gr=t=>t.tagName==="SELECT",Co=(t,e,n)=>{let r=e.value,o=Ze(n?.join(",")),s=Ze(r()[1]),i={int:o.int||o.int,lazy:o.lazy||s.lazy,number:o.number||s.number,trim:o.trim||s.trim},a=e.refs[0];if(!a)return k(8,t),()=>{};let c=yr(t);return c&&ur(t)?So(t,a):c&&mr(t)?Mo(t,a):c||hr(t)?Ro(t,i,a,r):gr(t)?Lo(t,a,r):(k(7,t),()=>{})},fr=/[.,' ·٫]/,Ro=(t,e,n,r)=>{let s=e.lazy?"change":"input",i=dr(t),a=()=>{!e.trim&&!Ze(r()[1]).trim||(t.value=t.value.trim())},c=b=>{let u=b.target;u.composing=1},f=b=>{let u=b.target;u.composing&&(u.composing=0,u.dispatchEvent(new Event(s)))},p=()=>{t.removeEventListener(s,l),t.removeEventListener("change",a),t.removeEventListener("compositionstart",c),t.removeEventListener("compositionend",f),t.removeEventListener("change",f)},l=b=>{let u=b.target;if(!u||u.composing)return;let y=u.value,v=Ze(r()[1]);if(i||v.number||v.int){if(v.int)y=parseInt(y);else{if(fr.test(y[y.length-1])&&y.split(fr).length===2){if(y+="0",y=parseFloat(y),isNaN(y))y="";else if(n()===y)return}y=parseFloat(y)}isNaN(y)&&(y=""),t.value=y}else v.trim&&(y=y.trim());n(y)};return t.addEventListener(s,l),t.addEventListener("change",a),t.addEventListener("compositionstart",c),t.addEventListener("compositionend",f),t.addEventListener("change",f),p},So=(t,e)=>{let n="change",r=()=>{t.removeEventListener(n,o)},o=()=>{let s=pe(t),i=t.checked,a=e();if(T(a)){let c=Lt(a,s),f=c!==-1;i&&!f?a.push(s):!i&&f&&a.splice(c,1)}else X(a)?i?a.add(s):a.delete(s):e(Oo(t,i))};return t.addEventListener(n,o),r},pe=t=>"_value"in t?t._value:t.value,br="trueValue",wo="falseValue",Tr="true-value",Ao="false-value",Oo=(t,e)=>{let n=e?br:wo;if(n in t)return t[n];let r=e?Tr:Ao;return t.hasAttribute(r)?t.getAttribute(r):e},No=(t,e)=>{if(br in t)return ce(e,t.trueValue);let r=Tr;return t.hasAttribute(r)?ce(e,t.getAttribute(r)):ce(e,!0)},Mo=(t,e)=>{let n="change",r=()=>{t.removeEventListener(n,o)},o=()=>{let s=pe(t);e(s)};return t.addEventListener(n,o),r},Lo=(t,e,n)=>{let r="change",o=()=>{t.removeEventListener(r,s)},s=()=>{let a=Ze(n()[1]).number,c=Array.prototype.filter.call(t.options,f=>f.selected).map(f=>a?pr(pe(f)):pe(f));if(t.multiple){let f=e();try{if(pn(e),X(f)){f.clear();for(let p of c)f.add(p)}else T(f)?(f.splice(0),f.push(...c)):e(c)}finally{fn(e),q(e)}}else e(c[0])};return t.addEventListener(r,s),o};var ko=["stop","prevent","capture","self","once","left","right","middle","passive"],Io=t=>{let e={};if(j(t))return;let n=t.split(",");for(let r of ko)e[r]=n.includes(r);return e},un={isLazy:(t,e)=>e===-1&&t%2===0,isLazyKey:(t,e)=>e===0&&!t.endsWith("_flags"),once:!1,collectRefObj:!0,onBind:(t,e,n,r,o,s)=>{if(o){let p=e.value(),l=V(o.value()[0]);return U(l)?ln(t,B(l),()=>e.value()[0],s?.join(",")??p[1]):()=>{}}else if(r){let p=e.value();return ln(t,B(r),()=>e.value()[0],s?.join(",")??p[1])}let i=[],a=()=>{i.forEach(p=>p())},c=e.value(),f=c.length;for(let p=0;p<f;++p){let l=c[p];if(D(l)&&(l=l()),w(l))for(let b of Object.entries(l)){let u=b[0],y=()=>{let S=e.value()[p];return D(S)&&(S=S()),S=S[u],D(S)&&(S=S()),S},v=l[u+"_flags"];i.push(ln(t,u,y,v))}else k(2,name,t)}return a}},Do=(t,e)=>{if(t.startsWith("keydown")||t.startsWith("keyup")||t.startsWith("keypress")){e??="";let n=t.split(".").concat(e.split(","));t=n[0];let r=n[1],o=n.includes("ctrl"),s=n.includes("shift"),i=n.includes("alt"),a=n.includes("meta"),c=f=>!(o&&!f.ctrlKey||s&&!f.shiftKey||i&&!f.altKey||a&&!f.metaKey);return r?[t,f=>c(f)?f.key.toUpperCase()===r.toUpperCase():!1]:[t,c]}return[t,n=>!0]},ln=(t,e,n,r)=>{if(j(e))return k(5,name,t),()=>{};let o=Io(r),s=o?{capture:o.capture,passive:o.passive,once:o.once}:void 0,i;[e,i]=Do(e,r);let a=p=>{if(!i(p)||!n&&e==="submit"&&o?.prevent)return;let l=n(p);D(l)&&(l=l(p)),D(l)&&l(p)},c=()=>{t.removeEventListener(e,f,s)},f=p=>{if(!o){a(p);return}try{if(o.left&&p.button!==1||o.middle&&p.button!==2||o.right&&p.button!==3||o.self&&p.target!==t)return;o.stop&&p.stopPropagation(),o.prevent&&p.preventDefault(),a(p)}finally{o.once&&c()}};return t.addEventListener(e,f,s),c};var Er={onChange:(t,e,n,r,o,s)=>{if(r){s&&s.includes("camel")&&(r=B(r)),je(t,r,e[0]);return}let i=e.length;for(let a=0;a<i;++a){let c=e[a];if(T(c)){let f=c[0],p=c[1];je(t,f,p)}else if(w(c))for(let f of Object.entries(c)){let p=f[0],l=f[1];je(t,p,l)}else{let f=e[a++],p=e[a];je(t,f,p)}}}};function Uo(t){return!!t||t===""}var je=(t,e,n)=>{if(Y(e)){k(3,name,t);return}if(e==="innerHTML"||e==="textContent"){let s=[...t.childNodes];setTimeout(()=>s.forEach(se),1),t[e]=n??"";return}let r=t.tagName;if(e==="value"&&r!=="PROGRESS"&&!r.includes("-")){t._value=n;let s=r==="OPTION"?t.getAttribute("value"):t.value,i=n??"";s!==i&&(t.value=i),n==null&&t.removeAttribute(e);return}let o=!1;if(n===""||n==null){let s=typeof t[e];s==="boolean"?n=Uo(n):n==null&&s==="string"?(n="",o=!0):s==="number"&&(n=0,o=!0)}try{t[e]=n}catch(s){o||k(4,e,r,n,s)}o&&t.removeAttribute(e)};var vr={once:!0,onBind:(t,e,n)=>{let r=e.value()[0],o=T(r),s=e.refs[0];return o?r.push(t):s?s?.(t):e.context[n]=t,()=>{if(o){let i=r.indexOf(t);i!==-1&&r.splice(i,1)}else s?.(null)}}};var xr={onChange:(t,e)=>{let n=xe(t).data,r=n._ord;bn(r)&&(r=n._ord=t.style.display),!!e[0]?t.style.display=r:t.style.display="none"}};var yn={onChange:(t,e,n)=>{let r=e.length;for(let o=0;o<r;++o){let s=e[o],i=n?.[o];if(T(s)){let a=s.length;for(let c=0;c<a;++c)Cr(t,s[c],i?.[c])}else Cr(t,s,i)}}},Cr=(t,e,n)=>{let r=t.style,o=U(e);if(e&&!o){if(n&&!U(n))for(let s in n)e[s]==null&&dn(r,s,"");for(let s in e)dn(r,s,e[s])}else{let s=r.display;if(o?n!==e&&(r.cssText=e):n&&t.removeAttribute("style"),"_ord"in xe(t).data)return;r.display=s}},Rr=/\s*!important$/;function dn(t,e,n){if(T(n))n.forEach(r=>{dn(t,e,r)});else if(n==null&&(n=""),e.startsWith("--"))t.setProperty(e,n);else{let r=Ho(t,e);Rr.test(n)?t.setProperty(De(r),n.replace(Rr,""),"important"):t[r]=n}}var Sr=["Webkit","Moz","ms"],mn={};function Ho(t,e){let n=mn[e];if(n)return n;let r=B(e);if(r!=="filter"&&r in t)return mn[e]=r;r=Je(r);for(let o=0;o<Sr.length;o++){let s=Sr[o]+r;if(s in t)return mn[e]=s}return e}var J=t=>_o(V(t)),_o=t=>{if(!t||!w(t))return t;if(T(t))return t.map(J);if(X(t)){let n=new Set;for(let r of t.keys())n.add(J(r));return n}if(ue(t)){let n=new Map;for(let r of n)n.set(J(r[0]),J(r[1]));return n}let e={...t};for(let n of Object.entries(e))e[n[0]]=J(n[1]);return e};var wr={onChange:(t,e)=>{let n=e[0];t.textContent=X(n)?JSON.stringify(J([...n])):ue(n)?JSON.stringify(J([...n])):w(n)?JSON.stringify(J(n)):n?.toString()??""}};var Ar={onChange:(t,e)=>{je(t,"value",e[0])}};var $e=t=>t?.[st]===1;var Ae=t=>{if(Qe(t))return t;let e;if(m(t)?(e=t,t=e()):e=z(t),t instanceof Node||t instanceof Date||t instanceof RegExp||t instanceof Promise||t instanceof Error)return e;if(e[st]=1,T(t)){let n=t.length;for(let r=0;r<n;++r){let o=t[r];$e(o)||(t[r]=Ae(o))}return e}if(!w(t))return e;for(let n of Object.entries(t)){let r=n[1];if($e(r))continue;let o=n[0];Ke(o)||(t[o]=Ae(r))}return e};var fe=class t{static getDefault(){return t.Fe??(t.Fe=new t)}H={};l={};Ze=()=>Object.keys(this.H).filter(e=>e.length===1||!e.startsWith(":"));he=new Map;ge=new Map;static Fe;static Tt="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";forGrowThreshold=10;globalContext;useInterpolation=!0;constructor(e){if(this.setDirectives("r-"),e){this.globalContext=e;return}this.globalContext=this.xt()}xt(){let e={},n=globalThis;for(let r of t.Tt.split(","))e[r]=n[r];return e.ref=Ae,e.sref=z,e.flatten=J,e}addComponent(...e){for(let n of e){if(!n.defaultName){at.warning("Registered component's default name is not defined",n);continue}this.he.set(Je(n.defaultName),n),this.ge.set(Je(n.defaultName).toLocaleUpperCase(),n)}}setDirectives(e){this.H={".":Er,":":an,"@":un,[`${e}on`]:un,[`${e}bind`]:an,[`${e}html`]:cr,[`${e}text`]:wr,[`${e}show`]:xr,[`${e}model`]:lr,":style":yn,[`${e}bind:style`]:yn,":class":cn,[`${e}bind:class`]:cn,":ref":vr,":value":Ar,teleport:Et},this.l={for:`${e}for`,if:`${e}if`,else:`${e}else`,elseif:`${e}else-if`,pre:`${e}pre`,inherit:`${e}inherit`,text:`${e}text`,props:":props",propsOnce:":props-once",bind:`${e}bind`,on:`${e}on`,keyBind:":key",key:"key",is:":is",teleport:`${e}teleport`,dynamic:"_d_"}}updateDirectives(e){e(this.H,this.l)}};var kt=(t,e)=>{if(!t)return;let n=(e??fe.getDefault()).l;for(let r of Po(t,n.pre))Vo(r,n.text)},Bo=/({{[^]*?}})/g,Vo=(t,e)=>{let n=t.textContent;if(!n)return;let r=Bo,o=n.split(r);if(o.length<=1)return;if(t.parentElement?.childNodes.length===1&&o.length===3){let i=o[1];if(j(o[0])&&j(o[2])&&i.startsWith("{{")&&i.endsWith("}}")){let a=t.parentElement;a.setAttribute(e,i.substring(2,i.length-2)),a.innerText="";return}}let s=document.createDocumentFragment();for(let i of o)if(i.startsWith("{{")&&i.endsWith("}}")){let a=document.createElement("span");a.setAttribute(e,i.substring(2,i.length-2)),s.appendChild(a)}else s.appendChild(document.createTextNode(i));t.replaceWith(s)},Po=(t,e)=>{let n=[],r=o=>{if(o.nodeType===Node.TEXT_NODE)o.textContent?.includes("{{")&&n.push(o);else{if(o?.hasAttribute?.(e))return;for(let s of ae(o))r(s)}};return r(t),n};var jo="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",$o=new Set(jo.toUpperCase().split(",")),Fo="http://www.w3.org/2000/svg",Or=(t,e)=>{te(t)?t.content.appendChild(e):t.appendChild(e)},hn=(t,e,n,r)=>{let o=t.t;if(o){let i=n&&$o.has(o.toUpperCase())?document.createElementNS(Fo,o.toLowerCase()):document.createElement(o),a=t.a;if(a)for(let f of Object.entries(a)){let p=f[0],l=f[1];p.startsWith("#")&&(l=p.substring(1),p="name"),i.setAttribute(lt(p,r),l)}let c=t.c;if(c)for(let f of c)hn(f,i,n,r);Or(e,i);return}let s=t.d;if(s){let i;switch(t.n??Node.TEXT_NODE){case Node.COMMENT_NODE:i=document.createComment(s);break;case Node.TEXT_NODE:i=document.createTextNode(s);break}if(i)Or(e,i);else throw new Error("unsupported node type.")}},Fe=(t,e,n)=>{n??=fe.getDefault();let r=document.createDocumentFragment();if(!T(t))return hn(t,r,!!e,n),r;for(let o of t)hn(o,r,!!e,n);return r};var qo=(t,e={selector:"#app"},n)=>{U(e)&&(e={selector:"#app",template:e}),Hn(t)&&(t=t.context);let r=e.element?e.element:e.selector?document.querySelector(e.selector):null;if(!r||!Re(r))throw H(0);n||(n=fe.getDefault());let o=()=>{for(let a of[...r.childNodes])$(a)},s=a=>{for(let c of a)r.appendChild(c)};if(e.template){let a=document.createRange().createContextualFragment(e.template);o(),s(a.childNodes),e.element=a}else if(e.json){let a=Fe(e.json,e.isSVG,n);o(),s(a.childNodes)}return n.useInterpolation&&kt(r,n),new gn(t,r,n).x(),_(r,()=>{he(t)}),gt(t),{context:t,unmount:()=>{$(r)},unbind:()=>{se(r)}}},gn=class{Et;$e;o;h;p;constructor(e,n,r){this.Et=e,this.$e=n,this.o=r,this.h=new Nt([e],r),this.p=new vt(this.h)}x(){this.p.G(this.$e)}};var et=t=>{if(T(t))return t.map(o=>et(o));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(o=>[o,t.getAttribute(o)])));let r=ae(t);return r.length>0&&(e.c=[...r].map(o=>et(o))),e};var zo=(t,e,n={})=>{T(n)&&(n={props:n}),U(e)&&(e={template:e});let r=!1;if(e.element){let s=e.element;s.remove(),e.element=s}else if(e.selector){let s=document.querySelector(e.selector);if(!s)throw H(1,e.selector);s.remove(),e.element=s}else if(e.template){let s=document.createRange().createContextualFragment(e.template);e.element=s}else e.json&&(e.element=Fe(e.json,e.isSVG,n.config),r=!0);e.element||(e.element=document.createDocumentFragment()),(n.useInterpolation??!0)&&kt(e.element);let o=e.element;if(!r&&((e.isSVG??(Ge(o)&&o.hasAttribute?.("isSVG")))||Ge(o)&&o.querySelector("[isSVG]"))){let s=e.element.content,i=s?[...s.childNodes]:[...o.childNodes],a=et(i);e.element=Fe(a,!0,n.config)}return{context:t,template:e.element,inheritAttrs:n.inheritAttrs??!0,props:n.props,defaultName:n.defaultName}};var Ko=t=>{let e,n={},r=(...o)=>{if(o.length<=2&&0 in o)throw H(4);return e&&!n.isStopped?e(...o):(e=Wo(t,n),e(...o))};return r[G]=1,ye(r,!0),r.stop=()=>n.ref?.stop?.(),W(()=>r.stop(),!0),r},Wo=(t,e)=>{let n=e.ref??z(null);e.ref=n,e.isStopped=!1;let r=0,o=Ue(()=>{if(r>0){o(),e.isStopped=!0,q(n);return}n(t()),++r});return n.stop=o,n};var Go=(t,e)=>{let n={},r,o=(...s)=>{if(s.length<=2&&0 in s)throw H(4);return r&&!n.isStopped?r(...s):(r=Jo(t,e,n),r(...s))};return o[G]=1,ye(o,!0),o.stop=()=>n.ref?.stop?.(),W(()=>o.stop(),!0),o},Jo=(t,e,n)=>{let r=n.ref??z(null);n.ref=r,n.isStopped=!1;let o=0,s=a=>{if(o>0){r.stop(),n.isStopped=!0,q(r);return}r(e(...t.map(c=>c()))),++o},i=[];for(let a of t){let c=R(a,s);i.push(c)}return s(null),r.stop=()=>{i.forEach(a=>{a()})},r};var Qo=(t,e)=>{let n={},r,o=(...s)=>{if(s.length<=2&&0 in s)throw H(4);return r&&!n.isStopped?r(...s):(r=Xo(t,e,n),r(...s))};return o[G]=1,ye(o,!0),o.stop=()=>n.ref?.stop?.(),W(()=>o.stop(),!0),o},Xo=(t,e,n)=>{let r=n.ref??z(null);n.ref=r,n.isStopped=!1;let o=0;return r.stop=R(t,s=>{if(o>0){r.stop(),n.isStopped=!0,q(r);return}r(e(s)),++o},!0),r};var Yo=t=>(t[it]=1,t);var Zo=(t,e)=>{if(!e)throw new Error("persist requires a string key.");let r=$e(t)?Ae:a=>a,o=()=>localStorage.setItem(e,JSON.stringify(J(t()))),s=localStorage.getItem(e);s!=null?t(r(JSON.parse(s))):o();let i=Ue(o);return W(()=>i,!0),t};var Nr=(t,...e)=>{let n="";return e.length===0?t.join():(t.forEach((r,o)=>{n+=r+e[o]}),n)},es=Nr;var ts=(t,e,n)=>{let r=[],o=()=>{e(t.map(i=>i()))};for(let i of t)r.push(R(i,o));n&&o();let s=()=>{for(let i of r)i()};return W(s,!0),s};var ns=t=>{if(!m(t))throw H(3,"observe");return t(void 0,void 0,2)};var rs=t=>{Mr();try{t()}finally{Lr()}},Mr=()=>{Se.set||(Se.set=new Set)},Lr=()=>{let t=Se.set;if(t){delete Se.set;for(let e of t)try{q(e)}catch(n){console.error(n)}}};var os=t=>{Ce()?.onMounted.push(t)};export{Ye as ComponentHead,fe as RegorConfig,_ as addUnbinder,rs as batch,Kt as collectRefs,Go as computeMany,Qo as computeRef,Ko as computed,qo as createApp,zo as createComponent,Lr as endBatch,Xt as entangle,J as flatten,xe as getBindData,Nr as html,$e as isDeepRef,Qe as isRaw,m as isRef,Yo as markRaw,R as observe,ts as observeMany,ns as observerCount,os as onMounted,W as onUnmounted,pn as pause,Zo as persist,es as raw,Ae as ref,$ as removeNode,fn as resume,zt as silence,z as sref,Mr as startBatch,Fe as toFragment,et as toJsonTemplate,q as trigger,se as unbind,V as unref,Qt as useScope,at as warningHandler,Ue as watchEffect};
3
+ `;break;case"r":r+="\r";break;case"t":r+=" ";break;case"b":r+="\b";break;case"f":r+="\f";break;case"v":r+="\v";break;default:r+=c}else r+=c,o+=c}throw this.i("Unclosed `")}ft(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 r=e.node;for(;r.type===3||r.type===6&&r?.callee?.type===3;)r=r.type===3?r.object:r.callee.object;r.type=20}lt(e){if(!this.u(Pn))return;let n=++this.e,r=!1;for(;this.e<this.r.length;){if(this.f===Pn&&!r){let o=this.r.slice(n,this.e),s="";for(;++this.e<this.r.length;){let a=this.f;if(a>=97&&a<=122||a>=65&&a<=90||a>=48&&a<=57)s+=this.M;else break}let i;try{i=new RegExp(o,s)}catch(a){throw this.i(a.message)}return e.node={type:4,value:i,raw:this.r.slice(n-1,this.e)},e.node=this.F(e.node),e.node}this.u(Rt)?r=!0:r&&this.u(St)&&(r=!1),this.e+=this.u(Yr)?2:1}throw this.i("Unclosed Regex")}},Yn=t=>new nn(t).parse();var yo={"=>":(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,"&":(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},ho={"-":t=>-t,"+":t=>+t,"!":t=>!t,"~":t=>~t,new:t=>t},nr=t=>{if(!t?.some(tr))return t;let e=[];return t.forEach(n=>tr(n)?e.push(...n):e.push(n)),e},Zn=(...t)=>nr(t),on=(t,e)=>{if(!t)return e;let n=Object.create(e??{});return n.$event=t,n},go={"++":(t,e)=>{let n=t[e];if(m(n)){let r=n();return n(++r),r}return++t[e]},"--":(t,e)=>{let n=t[e];if(m(n)){let r=n();return n(--r),r}return--t[e]}},bo={"++":(t,e)=>{let n=t[e];if(m(n)){let r=n();return n(r+1),r}return t[e]++},"--":(t,e)=>{let n=t[e];if(m(n)){let r=n();return n(r-1),r}return t[e]--}},er={"=":(t,e,n)=>{let r=t[e];return m(r)?r(n):t[e]=n},"+=":(t,e,n)=>{let r=t[e];return m(r)?r(r()+n):t[e]+=n},"-=":(t,e,n)=>{let r=t[e];return m(r)?r(r()-n):t[e]-=n},"*=":(t,e,n)=>{let r=t[e];return m(r)?r(r()*n):t[e]*=n},"/=":(t,e,n)=>{let r=t[e];return m(r)?r(r()/n):t[e]/=n},"%=":(t,e,n)=>{let r=t[e];return m(r)?r(r()%n):t[e]%=n},"**=":(t,e,n)=>{let r=t[e];return m(r)?r(r()**n):t[e]**=n},"<<=":(t,e,n)=>{let r=t[e];return m(r)?r(r()<<n):t[e]<<=n},">>=":(t,e,n)=>{let r=t[e];return m(r)?r(r()>>n):t[e]>>=n},">>>=":(t,e,n)=>{let r=t[e];return m(r)?r(r()>>>n):t[e]>>>=n},"|=":(t,e,n)=>{let r=t[e];return m(r)?r(r()|n):t[e]|=n},"&=":(t,e,n)=>{let r=t[e];return m(r)?r(r()&n):t[e]&=n},"^=":(t,e,n)=>{let r=t[e];return m(r)?r(r()^n):t[e]^=n}},Ot=(t,e)=>D(t)?t.bind(e):t,sn=class{m;Ve;ke;Ie;O;De;Ue;constructor(e,n,r,o,s){this.m=T(e)?e:[e],this.Ve=n,this.ke=r,this.Ie=o,this.Ue=!!s}Pe(e,n){if(n&&e in n)return n;for(let r of this.m)if(e in r)return r}2(e,n,r){let o=e.name;if(o==="$root")return this.m[this.m.length-1];if(o==="$parent")return this.m[1];if(o==="$ctx")return[...this.m];if(r&&o in r)return this.O=r[o],Ot(V(r[o]),r);for(let i of this.m)if(o in i)return this.O=i[o],Ot(V(i[o]),i);let s=this.Ve;if(s&&o in s)return this.O=s[o],Ot(V(s[o]),s)}5(e,n,r){return this.m[0]}0(e,n,r){return this.Be(n,r,Zn,...e.body)}1(e,n,r){return this.R(n,r,(...o)=>o.pop(),...e.expressions)}3(e,n,r){let{obj:o,key:s}=this.ae(e,n,r),i=o?.[s];return this.O=i,Ot(V(i),o)}4(e,n,r){return e.value}6(e,n,r){let o=(i,...a)=>D(i)?i(...nr(a)):i,s=this.R(++n,r,o,e.callee,...e.arguments);return this.O=s,s}7(e,n,r){return this.R(n,r,ho[e.operator],e.argument)}8(e,n,r){let o=yo[e.operator];switch(e.operator){case"||":case"&&":case"??":return o(()=>this.g(e.left,n,r),()=>this.g(e.right,n,r))}return this.R(n,r,o,e.left,e.right)}9(e,n,r){return this.Be(++n,r,Zn,...e.elements)}10(e,n,r){let o={},s=(...i)=>{i.forEach(a=>{Object.assign(o,a)})};return this.R(++n,r,s,...e.properties),o}11(e,n,r){return this.R(n,r,o=>this.g(o?e.consequent:e.alternate,n,r),e.test)}12(e,n,r){let o={},s=p=>p?.type!==15,i=this.Ie??(()=>!1),a=n===0&&this.Ue,c=p=>this._e(a,e.key,n,on(p,r)),f=p=>this._e(a,e.value,n,on(p,r));if(e.shorthand){let p=e.key.name;o[p]=s(e.key)&&i(p,n)?c:c()}else if(e.computed){let p=V(c());o[p]=s(e.value)&&i(p,n)?f:f()}else{let p=e.key.type===4?e.key.value:e.key.name;o[p]=s(e.value)&&i(p,n)?()=>f:f()}return o}ae(e,n,r){let o=this.g(e.object,n,r),s=e.computed?this.g(e.property,n,r):e.property.name;return{obj:o,key:s}}13(e,n,r){let o=e.argument,s=e.operator,i=e.prefix?go:bo;if(o.type===2){let a=o.name,c=this.Pe(a,r);return Y(c)?void 0:i[s](c,a)}if(o.type===3){let{obj:a,key:c}=this.ae(o,n,r);return i[s](a,c)}}16(e,n,r){let o=e.left,s=e.operator;if(o.type===2){let i=o.name,a=this.Pe(i,r);if(Y(a))return;let c=this.g(e.right,n,r);return er[s](a,i,c)}if(o.type===3){let{obj:i,key:a}=this.ae(o,n,r),c=this.g(e.right,n,r);return er[s](i,a,c)}}14(e,n,r){let o=this.g(e.argument,n,r);return T(o)&&(o.s=rr),o}17(e,n,r){return this[6]({type:6,callee:e.tag,arguments:[{type:9,elements:e.quasi.quasis},...e.quasi.expressions]},n,r)}19(e,n,r){let o=(...s)=>s.reduce((i,a,c)=>i+=a+e.quasis[c+1].value.cooked,e.quasis[0].value.cooked);return this.R(n,r,o,...e.expressions)}18(e,n,r){return e.value.cooked}20(e,n,r){let o=(s,...i)=>new s(...i);return this.R(n,r,o,e.callee,...e.arguments)}15(e,n,r){return(...o)=>{let s=Object.create(r??{}),i=e.params;if(i){let a=0;for(let c of i)s[c.name]=o[a++]}return this.g(e.body,n,s)}}g(e,n,r){let o=V(this[e.type](e,n,r));return this.De=e.type,o}_e(e,n,r,o){let s=this.g(n,r,o);return e&&this.He()?this.O:s}He(){let e=this.De;return(e===2||e===3||e===6)&&m(this.O)}eval(e,n){let{value:r,refs:o}=Kt(()=>this.g(e,-1,n)),s={value:r,refs:o};return this.He()&&(s.ref=this.O),s}R(e,n,r,...o){let s=o.map(i=>i&&this.g(i,e,n));return r(...s)}Be(e,n,r,...o){let s=this.ke;if(!s)return this.R(e,n,r,...o);let i=o.map((a,c)=>a&&(a.type!==15&&s(c,e)?f=>this.g(a,e,on(f,n)):this.g(a,e,n)));return r(...i)}},rr=Symbol("s"),tr=t=>t?.s===rr,or=(t,e,n,r,o,s,i)=>new sn(e,n,r,o,i).eval(t,s);var sr={},Nt=class{m;o;constructor(e,n){this.m=e,this.o=n}w(e){this.m=[e,...this.m]}me(){return this.m.map(n=>n.components).filter(n=>!!n).reverse().reduce((n,r)=>{for(let[o,s]of Object.entries(r))n[o.toUpperCase()]=s;return n},{})}v(e,n,r,o,s){let i=z([]),a=[],c=()=>{for(let u of a)u();a.length=0},f={value:i,stop:c,refs:[],context:this.m[0]};if(j(e))return f;let p=this.o.globalContext,l=[],b=(u,y,v,S)=>{try{let h=or(u,y,p,n,r,S,o);return v&&l.push(...h.refs),{value:h.value,refs:h.refs,ref:h.ref}}catch(h){k(6,`evaluation error: ${e}`,h)}return{value:void 0,refs:[]}};try{let u=sr[e]??Yn("["+e+"]");sr[e]=u;let y=this.m,v=()=>{l.splice(0),c();let S=u.elements.map((h,A)=>n?.(A,-1)?{value:O=>b(h,y,!1,{$event:O}).value,refs:[]}:b(h,y,!0));if(!s)for(let h of l){let A=R(h,v);a.push(A)}i(S.map(h=>h.value)),f.refs=S.map(h=>h.ref)};v()}catch(u){k(6,`parse error: ${e}`,u)}return f}k(){return this.m}je=[];Y(e){this.je.push(this.m),this.m=e}C(e,n){try{this.Y(e),n()}finally{this.bt()}}bt(){this.m=this.je.pop()??[]}};var ir="http://www.w3.org/1999/xlink",To={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 Eo(t){return!!t||t===""}var an={onChange:(t,e,n,r,o,s)=>{if(r){s&&s.includes("camel")&&(r=B(r)),Mt(t,r,e[0],o);return}let i=e.length;for(let a=0;a<i;++a){let c=e[a];if(T(c)){let f=n?.[a]?.[0],p=c[0],l=c[1];Mt(t,p,l,f)}else if(w(c))for(let f of Object.entries(c)){let p=f[0],l=f[1],b=n?.[a],u=b&&p in b?p:void 0;Mt(t,p,l,u)}else{let f=n?.[a],p=e[a++],l=e[a];Mt(t,p,l,f)}}}},Mt=(t,e,n,r)=>{if(r&&r!==e&&t.removeAttribute(r),Y(e)){k(3,name,t);return}if(!U(e)){k(6,`Attribute key is not string at ${t.outerHTML}`,e);return}if(e.startsWith("xlink:")){Y(n)?t.removeAttributeNS(ir,e.slice(6,e.length)):t.setAttributeNS(ir,e,n);return}let o=e in To;Y(n)||o&&!Eo(n)?t.removeAttribute(e):t.setAttribute(e,o?"":n)};var cn={onChange:(t,e,n)=>{let r=e.length;for(let o=0;o<r;++o){let s=e[o],i=n?.[o];if(T(s)){let a=s.length;for(let c=0;c<a;++c)ar(t,s[c],i?.[c])}else ar(t,s,i)}}},ar=(t,e,n)=>{let r=t.classList,o=U(e),s=U(n);if(e&&!o){if(n&&!s)for(let i in n)i in e||r.remove(i);for(let i in e)e[i]&&r.add(i)}else o?n!==e&&(s&&r.remove(...n?.split(",")),r.add(...e.split(","))):n&&s&&r.remove(...n?.split(","))};var cr={onChange:(t,e)=>{let[n,r]=e;D(r)?r(t,n):t.innerHTML=n?.toString()}};function vo(t,e){if(t.length!==e.length)return!1;let n=!0;for(let r=0;n&&r<t.length;r++)n=ce(t[r],e[r]);return n}function ce(t,e){if(t===e)return!0;let n=Ht(t),r=Ht(e);if(n||r)return n&&r?t.getTime()===e.getTime():!1;if(n=Ke(t),r=Ke(e),n||r)return t===e;if(n=T(t),r=T(e),n||r)return n&&r?vo(t,e):!1;if(n=w(t),r=w(e),n||r){if(!n||!r)return!1;let o=Object.keys(t).length,s=Object.keys(e).length;if(o!==s)return!1;for(let i in t){let a=t.hasOwnProperty(i),c=e.hasOwnProperty(i);if(a&&!c||!a&&c||!ce(t[i],e[i]))return!1}}return String(t)===String(e)}function Lt(t,e){return t.findIndex(n=>ce(n,e))}var pr=t=>{let e=parseFloat(t);return isNaN(e)?t:e};var pn=t=>{if(!m(t))throw H(3,"pause");t(void 0,void 0,3)};var fn=t=>{if(!m(t))throw H(3,"resume");t(void 0,void 0,4)};var lr={onChange:(t,e)=>{xo(t,e[0])},onBind:(t,e,n,r,o,s)=>Co(t,e,s)},xo=(t,e)=>{let n=yr(t);if(n&&ur(t))T(e)?e=Lt(e,pe(t))>-1:X(e)?e=e.has(pe(t)):e=No(t,e),t.checked=e;else if(n&&mr(t))t.checked=ce(e,pe(t));else if(n||hr(t))dr(t)?t.value!==e?.toString()&&(t.value=e):t.value!==e&&(t.value=e);else if(gr(t)){let r=t.options,o=r.length,s=t.multiple;for(let i=0;i<o;i++){let a=r[i],c=pe(a);if(s)T(e)?a.selected=Lt(e,c)>-1:a.selected=e.has(c);else if(ce(pe(a),e)){t.selectedIndex!==i&&(t.selectedIndex=i);return}}!s&&t.selectedIndex!==-1&&(t.selectedIndex=-1)}else k(7,t)},Ze=t=>(m(t)&&(t=t()),D(t)&&(t=t()),t?U(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}),ur=t=>t.type==="checkbox",mr=t=>t.type==="radio",dr=t=>t.type==="number"||t.type==="range",yr=t=>t.tagName==="INPUT",hr=t=>t.tagName==="TEXTAREA",gr=t=>t.tagName==="SELECT",Co=(t,e,n)=>{let r=e.value,o=Ze(n?.join(",")),s=Ze(r()[1]),i={int:o.int||o.int,lazy:o.lazy||s.lazy,number:o.number||s.number,trim:o.trim||s.trim},a=e.refs[0];if(!a)return k(8,t),()=>{};let c=yr(t);return c&&ur(t)?So(t,a):c&&mr(t)?Mo(t,a):c||hr(t)?Ro(t,i,a,r):gr(t)?Lo(t,a,r):(k(7,t),()=>{})},fr=/[.,' ·٫]/,Ro=(t,e,n,r)=>{let s=e.lazy?"change":"input",i=dr(t),a=()=>{!e.trim&&!Ze(r()[1]).trim||(t.value=t.value.trim())},c=b=>{let u=b.target;u.composing=1},f=b=>{let u=b.target;u.composing&&(u.composing=0,u.dispatchEvent(new Event(s)))},p=()=>{t.removeEventListener(s,l),t.removeEventListener("change",a),t.removeEventListener("compositionstart",c),t.removeEventListener("compositionend",f),t.removeEventListener("change",f)},l=b=>{let u=b.target;if(!u||u.composing)return;let y=u.value,v=Ze(r()[1]);if(i||v.number||v.int){if(v.int)y=parseInt(y);else{if(fr.test(y[y.length-1])&&y.split(fr).length===2){if(y+="0",y=parseFloat(y),isNaN(y))y="";else if(n()===y)return}y=parseFloat(y)}isNaN(y)&&(y=""),t.value=y}else v.trim&&(y=y.trim());n(y)};return t.addEventListener(s,l),t.addEventListener("change",a),t.addEventListener("compositionstart",c),t.addEventListener("compositionend",f),t.addEventListener("change",f),p},So=(t,e)=>{let n="change",r=()=>{t.removeEventListener(n,o)},o=()=>{let s=pe(t),i=t.checked,a=e();if(T(a)){let c=Lt(a,s),f=c!==-1;i&&!f?a.push(s):!i&&f&&a.splice(c,1)}else X(a)?i?a.add(s):a.delete(s):e(Oo(t,i))};return t.addEventListener(n,o),r},pe=t=>"_value"in t?t._value:t.value,br="trueValue",wo="falseValue",Tr="true-value",Ao="false-value",Oo=(t,e)=>{let n=e?br:wo;if(n in t)return t[n];let r=e?Tr:Ao;return t.hasAttribute(r)?t.getAttribute(r):e},No=(t,e)=>{if(br in t)return ce(e,t.trueValue);let r=Tr;return t.hasAttribute(r)?ce(e,t.getAttribute(r)):ce(e,!0)},Mo=(t,e)=>{let n="change",r=()=>{t.removeEventListener(n,o)},o=()=>{let s=pe(t);e(s)};return t.addEventListener(n,o),r},Lo=(t,e,n)=>{let r="change",o=()=>{t.removeEventListener(r,s)},s=()=>{let a=Ze(n()[1]).number,c=Array.prototype.filter.call(t.options,f=>f.selected).map(f=>a?pr(pe(f)):pe(f));if(t.multiple){let f=e();try{if(pn(e),X(f)){f.clear();for(let p of c)f.add(p)}else T(f)?(f.splice(0),f.push(...c)):e(c)}finally{fn(e),q(e)}}else e(c[0])};return t.addEventListener(r,s),o};var ko=["stop","prevent","capture","self","once","left","right","middle","passive"],Io=t=>{let e={};if(j(t))return;let n=t.split(",");for(let r of ko)e[r]=n.includes(r);return e},un={isLazy:(t,e)=>e===-1&&t%2===0,isLazyKey:(t,e)=>e===0&&!t.endsWith("_flags"),once:!1,collectRefObj:!0,onBind:(t,e,n,r,o,s)=>{if(o){let p=e.value(),l=V(o.value()[0]);return U(l)?ln(t,B(l),()=>e.value()[0],s?.join(",")??p[1]):()=>{}}else if(r){let p=e.value();return ln(t,B(r),()=>e.value()[0],s?.join(",")??p[1])}let i=[],a=()=>{i.forEach(p=>p())},c=e.value(),f=c.length;for(let p=0;p<f;++p){let l=c[p];if(D(l)&&(l=l()),w(l))for(let b of Object.entries(l)){let u=b[0],y=()=>{let S=e.value()[p];return D(S)&&(S=S()),S=S[u],D(S)&&(S=S()),S},v=l[u+"_flags"];i.push(ln(t,u,y,v))}else k(2,name,t)}return a}},Do=(t,e)=>{if(t.startsWith("keydown")||t.startsWith("keyup")||t.startsWith("keypress")){e??="";let n=t.split(".").concat(e.split(","));t=n[0];let r=n[1],o=n.includes("ctrl"),s=n.includes("shift"),i=n.includes("alt"),a=n.includes("meta"),c=f=>!(o&&!f.ctrlKey||s&&!f.shiftKey||i&&!f.altKey||a&&!f.metaKey);return r?[t,f=>c(f)?f.key.toUpperCase()===r.toUpperCase():!1]:[t,c]}return[t,n=>!0]},ln=(t,e,n,r)=>{if(j(e))return k(5,name,t),()=>{};let o=Io(r),s=o?{capture:o.capture,passive:o.passive,once:o.once}:void 0,i;[e,i]=Do(e,r);let a=p=>{if(!i(p)||!n&&e==="submit"&&o?.prevent)return;let l=n(p);D(l)&&(l=l(p)),D(l)&&l(p)},c=()=>{t.removeEventListener(e,f,s)},f=p=>{if(!o){a(p);return}try{if(o.left&&p.button!==1||o.middle&&p.button!==2||o.right&&p.button!==3||o.self&&p.target!==t)return;o.stop&&p.stopPropagation(),o.prevent&&p.preventDefault(),a(p)}finally{o.once&&c()}};return t.addEventListener(e,f,s),c};var Er={onChange:(t,e,n,r,o,s)=>{if(r){s&&s.includes("camel")&&(r=B(r)),je(t,r,e[0]);return}let i=e.length;for(let a=0;a<i;++a){let c=e[a];if(T(c)){let f=c[0],p=c[1];je(t,f,p)}else if(w(c))for(let f of Object.entries(c)){let p=f[0],l=f[1];je(t,p,l)}else{let f=e[a++],p=e[a];je(t,f,p)}}}};function Uo(t){return!!t||t===""}var je=(t,e,n)=>{if(Y(e)){k(3,name,t);return}if(e==="innerHTML"||e==="textContent"){let s=[...t.childNodes];setTimeout(()=>s.forEach(se),1),t[e]=n??"";return}let r=t.tagName;if(e==="value"&&r!=="PROGRESS"&&!r.includes("-")){t._value=n;let s=r==="OPTION"?t.getAttribute("value"):t.value,i=n??"";s!==i&&(t.value=i),n==null&&t.removeAttribute(e);return}let o=!1;if(n===""||n==null){let s=typeof t[e];s==="boolean"?n=Uo(n):n==null&&s==="string"?(n="",o=!0):s==="number"&&(n=0,o=!0)}try{t[e]=n}catch(s){o||k(4,e,r,n,s)}o&&t.removeAttribute(e)};var vr={once:!0,onBind:(t,e,n)=>{let r=e.value()[0],o=T(r),s=e.refs[0];return o?r.push(t):s?s?.(t):e.context[n]=t,()=>{if(o){let i=r.indexOf(t);i!==-1&&r.splice(i,1)}else s?.(null)}}};var xr={onChange:(t,e)=>{let n=xe(t).data,r=n._ord;bn(r)&&(r=n._ord=t.style.display),!!e[0]?t.style.display=r:t.style.display="none"}};var yn={onChange:(t,e,n)=>{let r=e.length;for(let o=0;o<r;++o){let s=e[o],i=n?.[o];if(T(s)){let a=s.length;for(let c=0;c<a;++c)Cr(t,s[c],i?.[c])}else Cr(t,s,i)}}},Cr=(t,e,n)=>{let r=t.style,o=U(e);if(e&&!o){if(n&&!U(n))for(let s in n)e[s]==null&&dn(r,s,"");for(let s in e)dn(r,s,e[s])}else{let s=r.display;if(o?n!==e&&(r.cssText=e):n&&t.removeAttribute("style"),"_ord"in xe(t).data)return;r.display=s}},Rr=/\s*!important$/;function dn(t,e,n){if(T(n))n.forEach(r=>{dn(t,e,r)});else if(n==null&&(n=""),e.startsWith("--"))t.setProperty(e,n);else{let r=Ho(t,e);Rr.test(n)?t.setProperty(De(r),n.replace(Rr,""),"important"):t[r]=n}}var Sr=["Webkit","Moz","ms"],mn={};function Ho(t,e){let n=mn[e];if(n)return n;let r=B(e);if(r!=="filter"&&r in t)return mn[e]=r;r=Je(r);for(let o=0;o<Sr.length;o++){let s=Sr[o]+r;if(s in t)return mn[e]=s}return e}var J=t=>_o(V(t)),_o=t=>{if(!t||!w(t))return t;if(T(t))return t.map(J);if(X(t)){let n=new Set;for(let r of t.keys())n.add(J(r));return n}if(ue(t)){let n=new Map;for(let r of n)n.set(J(r[0]),J(r[1]));return n}let e={...t};for(let n of Object.entries(e))e[n[0]]=J(n[1]);return e};var wr={onChange:(t,e)=>{let n=e[0];t.textContent=X(n)?JSON.stringify(J([...n])):ue(n)?JSON.stringify(J([...n])):w(n)?JSON.stringify(J(n)):n?.toString()??""}};var Ar={onChange:(t,e)=>{je(t,"value",e[0])}};var $e=t=>t?.[st]===1;var Ae=t=>{if(Qe(t))return t;let e;if(m(t)?(e=t,t=e()):e=z(t),t instanceof Node||t instanceof Date||t instanceof RegExp||t instanceof Promise||t instanceof Error)return e;if(e[st]=1,T(t)){let n=t.length;for(let r=0;r<n;++r){let o=t[r];$e(o)||(t[r]=Ae(o))}return e}if(!w(t))return e;for(let n of Object.entries(t)){let r=n[1];if($e(r))continue;let o=n[0];Ke(o)||(t[o]=Ae(r))}return e};var fe=class t{static getDefault(){return t.Fe??(t.Fe=new t)}H={};l={};Ze=()=>Object.keys(this.H).filter(e=>e.length===1||!e.startsWith(":"));he=new Map;ge=new Map;static Fe;static Tt="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";forGrowThreshold=10;globalContext;useInterpolation=!0;constructor(e){if(this.setDirectives("r-"),e){this.globalContext=e;return}this.globalContext=this.xt()}xt(){let e={},n=globalThis;for(let r of t.Tt.split(","))e[r]=n[r];return e.ref=Ae,e.sref=z,e.flatten=J,e}addComponent(...e){for(let n of e){if(!n.defaultName){at.warning("Registered component's default name is not defined",n);continue}this.he.set(Je(n.defaultName),n),this.ge.set(Je(n.defaultName).toLocaleUpperCase(),n)}}setDirectives(e){this.H={".":Er,":":an,"@":un,[`${e}on`]:un,[`${e}bind`]:an,[`${e}html`]:cr,[`${e}text`]:wr,[`${e}show`]:xr,[`${e}model`]:lr,":style":yn,[`${e}bind:style`]:yn,":class":cn,[`${e}bind:class`]:cn,":ref":vr,":value":Ar,teleport:Et},this.l={for:`${e}for`,if:`${e}if`,else:`${e}else`,elseif:`${e}else-if`,pre:`${e}pre`,inherit:`${e}inherit`,text:`${e}text`,props:":props",propsOnce:":props-once",bind:`${e}bind`,on:`${e}on`,keyBind:":key",key:"key",is:":is",teleport:`${e}teleport`,dynamic:"_d_"}}updateDirectives(e){e(this.H,this.l)}};var kt=(t,e)=>{if(!t)return;let n=(e??fe.getDefault()).l;for(let r of Po(t,n.pre))Vo(r,n.text)},Bo=/({{[^]*?}})/g,Vo=(t,e)=>{let n=t.textContent;if(!n)return;let r=Bo,o=n.split(r);if(o.length<=1)return;if(t.parentElement?.childNodes.length===1&&o.length===3){let i=o[1];if(j(o[0])&&j(o[2])&&i.startsWith("{{")&&i.endsWith("}}")){let a=t.parentElement;a.setAttribute(e,i.substring(2,i.length-2)),a.innerText="";return}}let s=document.createDocumentFragment();for(let i of o)if(i.startsWith("{{")&&i.endsWith("}}")){let a=document.createElement("span");a.setAttribute(e,i.substring(2,i.length-2)),s.appendChild(a)}else s.appendChild(document.createTextNode(i));t.replaceWith(s)},Po=(t,e)=>{let n=[],r=o=>{if(o.nodeType===Node.TEXT_NODE)o.textContent?.includes("{{")&&n.push(o);else{if(o?.hasAttribute?.(e))return;for(let s of ae(o))r(s)}};return r(t),n};var jo="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",$o=new Set(jo.toUpperCase().split(",")),Fo="http://www.w3.org/2000/svg",Or=(t,e)=>{te(t)?t.content.appendChild(e):t.appendChild(e)},hn=(t,e,n,r)=>{let o=t.t;if(o){let i=n&&$o.has(o.toUpperCase())?document.createElementNS(Fo,o.toLowerCase()):document.createElement(o),a=t.a;if(a)for(let f of Object.entries(a)){let p=f[0],l=f[1];p.startsWith("#")&&(l=p.substring(1),p="name"),i.setAttribute(lt(p,r),l)}let c=t.c;if(c)for(let f of c)hn(f,i,n,r);Or(e,i);return}let s=t.d;if(s){let i;switch(t.n??Node.TEXT_NODE){case Node.COMMENT_NODE:i=document.createComment(s);break;case Node.TEXT_NODE:i=document.createTextNode(s);break}if(i)Or(e,i);else throw new Error("unsupported node type.")}},Fe=(t,e,n)=>{n??=fe.getDefault();let r=document.createDocumentFragment();if(!T(t))return hn(t,r,!!e,n),r;for(let o of t)hn(o,r,!!e,n);return r};var qo=(t,e={selector:"#app"},n)=>{U(e)&&(e={selector:"#app",template:e}),Hn(t)&&(t=t.context);let r=e.element?e.element:e.selector?document.querySelector(e.selector):null;if(!r||!Re(r))throw H(0);n||(n=fe.getDefault());let o=()=>{for(let a of[...r.childNodes])$(a)},s=a=>{for(let c of a)r.appendChild(c)};if(e.template){let a=document.createRange().createContextualFragment(e.template);o(),s(a.childNodes),e.element=a}else if(e.json){let a=Fe(e.json,e.isSVG,n);o(),s(a.childNodes)}return n.useInterpolation&&kt(r,n),new gn(t,r,n).x(),_(r,()=>{he(t)}),gt(t),{context:t,unmount:()=>{$(r)},unbind:()=>{se(r)}}},gn=class{Et;$e;o;h;p;constructor(e,n,r){this.Et=e,this.$e=n,this.o=r,this.h=new Nt([e],r),this.p=new vt(this.h)}x(){this.p.G(this.$e)}};var et=t=>{if(T(t))return t.map(o=>et(o));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(o=>[o,t.getAttribute(o)])));let r=ae(t);return r.length>0&&(e.c=[...r].map(o=>et(o))),e};var zo=(t,e,n={})=>{T(n)&&(n={props:n}),U(e)&&(e={template:e});let r=!1;if(e.element){let s=e.element;s.remove(),e.element=s}else if(e.selector){let s=document.querySelector(e.selector);if(!s)throw H(1,e.selector);s.remove(),e.element=s}else if(e.template){let s=document.createRange().createContextualFragment(e.template);e.element=s}else e.json&&(e.element=Fe(e.json,e.isSVG,n.config),r=!0);e.element||(e.element=document.createDocumentFragment()),(n.useInterpolation??!0)&&kt(e.element);let o=e.element;if(!r&&((e.isSVG??(Ge(o)&&o.hasAttribute?.("isSVG")))||Ge(o)&&o.querySelector("[isSVG]"))){let s=e.element.content,i=s?[...s.childNodes]:[...o.childNodes],a=et(i);e.element=Fe(a,!0,n.config)}return{context:t,template:e.element,inheritAttrs:n.inheritAttrs??!0,props:n.props,defaultName:n.defaultName}};var Ko=t=>{let e,n={},r=(...o)=>{if(o.length<=2&&0 in o)throw H(4);return e&&!n.isStopped?e(...o):(e=Wo(t,n),e(...o))};return r[G]=1,ye(r,!0),r.stop=()=>n.ref?.stop?.(),W(()=>r.stop(),!0),r},Wo=(t,e)=>{let n=e.ref??z(null);e.ref=n,e.isStopped=!1;let r=0,o=Ue(()=>{if(r>0){o(),e.isStopped=!0,q(n);return}n(t()),++r});return n.stop=o,n};var Go=(t,e)=>{let n={},r,o=(...s)=>{if(s.length<=2&&0 in s)throw H(4);return r&&!n.isStopped?r(...s):(r=Jo(t,e,n),r(...s))};return o[G]=1,ye(o,!0),o.stop=()=>n.ref?.stop?.(),W(()=>o.stop(),!0),o},Jo=(t,e,n)=>{let r=n.ref??z(null);n.ref=r,n.isStopped=!1;let o=0,s=a=>{if(o>0){r.stop(),n.isStopped=!0,q(r);return}r(e(...t.map(c=>c()))),++o},i=[];for(let a of t){let c=R(a,s);i.push(c)}return s(null),r.stop=()=>{i.forEach(a=>{a()})},r};var Qo=(t,e)=>{let n={},r,o=(...s)=>{if(s.length<=2&&0 in s)throw H(4);return r&&!n.isStopped?r(...s):(r=Xo(t,e,n),r(...s))};return o[G]=1,ye(o,!0),o.stop=()=>n.ref?.stop?.(),W(()=>o.stop(),!0),o},Xo=(t,e,n)=>{let r=n.ref??z(null);n.ref=r,n.isStopped=!1;let o=0;return r.stop=R(t,s=>{if(o>0){r.stop(),n.isStopped=!0,q(r);return}r(e(s)),++o},!0),r};var Yo=t=>(t[it]=1,t);var Zo=(t,e)=>{if(!e)throw new Error("persist requires a string key.");let r=$e(t)?Ae:a=>a,o=()=>localStorage.setItem(e,JSON.stringify(J(t()))),s=localStorage.getItem(e);s!=null?t(r(JSON.parse(s))):o();let i=Ue(o);return W(()=>i,!0),t};var Nr=(t,...e)=>{let n="";return e.length===0?t.join():(t.forEach((r,o)=>{n+=r+e[o]}),n)},es=Nr;var ts=(t,e,n)=>{let r=[],o=()=>{e(t.map(i=>i()))};for(let i of t)r.push(R(i,o));n&&o();let s=()=>{for(let i of r)i()};return W(s,!0),s};var ns=t=>{if(!m(t))throw H(3,"observe");return t(void 0,void 0,2)};var rs=t=>{Mr();try{t()}finally{Lr()}},Mr=()=>{Se.set||(Se.set=new Set)},Lr=()=>{let t=Se.set;if(t){delete Se.set;for(let e of t)try{q(e)}catch(n){console.error(n)}}};var os=t=>{Ce()?.onMounted.push(t)};export{Ye as ComponentHead,fe as RegorConfig,_ as addUnbinder,rs as batch,Kt as collectRefs,Go as computeMany,Qo as computeRef,Ko as computed,qo as createApp,zo as createComponent,Lr as endBatch,Xt as entangle,J as flatten,xe as getBindData,Nr as html,$e as isDeepRef,Qe as isRaw,m as isRef,Yo as markRaw,R as observe,ts as observeMany,ns as observerCount,os as onMounted,W as onUnmounted,pn as pause,Zo as persist,es as raw,Ae as ref,$ as removeNode,fn as resume,zt as silence,z as sref,Mr as startBatch,Fe as toFragment,et as toJsonTemplate,q as trigger,se as unbind,V as unref,Qt as useScope,at as warningHandler,Ue as watchEffect};
@@ -1,3 +1,3 @@
1
- "use strict";var Regor=(()=>{var jt=Object.defineProperty;var zr=Object.getOwnPropertyDescriptor;var Kr=Object.getOwnPropertyNames;var Wr=Object.prototype.hasOwnProperty;var Gr=(t,e)=>{for(var n in e)jt(t,n,{get:e[n],enumerable:!0})},Jr=(t,e,n,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of Kr(e))!Wr.call(t,o)&&o!==n&&jt(t,o,{get:()=>e[o],enumerable:!(r=zr(e,o))||r.enumerable});return t};var Qr=t=>Jr(jt({},"__esModule",{value:!0}),t);var us={};Gr(us,{ComponentHead:()=>Pe,RegorConfig:()=>re,addUnbinder:()=>k,batch:()=>Fr,collectRefs:()=>mt,computeMany:()=>Hr,computeRef:()=>_r,computed:()=>Ur,createApp:()=>Ir,createComponent:()=>Dr,endBatch:()=>vn,entangle:()=>Et,flatten:()=>J,getBindData:()=>me,html:()=>Tn,isDeepRef:()=>Ne,isRaw:()=>Be,isRef:()=>m,markRaw:()=>Br,observe:()=>C,observeMany:()=>jr,observerCount:()=>$r,onMounted:()=>qr,onUnmounted:()=>K,pause:()=>Ht,persist:()=>Vr,raw:()=>Pr,ref:()=>Te,removeNode:()=>P,resume:()=>_t,silence:()=>ut,sref:()=>z,startBatch:()=>En,toFragment:()=>Me,toJsonTemplate:()=>Ke,trigger:()=>F,unbind:()=>te,unref:()=>V,useScope:()=>Tt,warningHandler:()=>Qe,watchEffect:()=>we});var U=t=>typeof t=="function",H=t=>typeof t=="string",xn=t=>typeof t>"u",Y=t=>t==null||typeof t>"u",$=t=>typeof t!="string"||!t?.trim(),Xr=Object.prototype.toString,$t=t=>Xr.call(t),ue=t=>$t(t)==="[object Map]",X=t=>$t(t)==="[object Set]",Ft=t=>$t(t)==="[object Date]",Je=t=>typeof t=="symbol",T=Array.isArray,w=t=>t!==null&&typeof t=="object";var Cn={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."},_=(t,...e)=>{let n=Cn[t];return new Error(U(n)?n.call(Cn,...e):n)};var ke=Symbol(":regor");var me=t=>{let e=t[ke];if(e)return e;let n={unbinders:[],data:{}};return t[ke]=n,n};var k=(t,e)=>{me(t).unbinders.push(e)};var ot=[],Rn=()=>{let t={onMounted:[],onUnmounted:[]};return ot.push(t),t},Re=t=>{let e=ot[ot.length-1];if(!e&&!t)throw _(2);return e},Sn=t=>{let e=Re();return t&&zt(t),ot.pop(),e},qt=Symbol("csp"),zt=t=>{let e=t,n=e[qt];if(n){let r=Re();if(n===r)return;r.onMounted.length>0&&n.onMounted.push(...r.onMounted),r.onUnmounted.length>0&&n.onUnmounted.push(...r.onUnmounted);return}e[qt]=Re()},st=t=>t[qt];var K=(t,e)=>{Re(e)?.onUnmounted.push(t)};var it=Symbol("ref"),G=Symbol("sref"),at=Symbol("raw");var m=t=>t?.[G]===1;var C=(t,e,n)=>{if(!m(t))throw _(3,"observe");n&&e(t());let o=t(void 0,void 0,0,e);return K(o,!0),o};var te=t=>{let e=[t];for(;e.length>0;){let n=e.shift();Yr(n);let r=n.childNodes;if(r)for(let o of r)e.push(o)}},Yr=t=>{let e=t[ke];if(e){for(let n of e.unbinders)n();e.unbinders.splice(0),delete t[ke]}};var P=t=>{t.remove(),setTimeout(()=>te(t),1)};var wn={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,r)=>({msg:`Failed setting prop "${t}" on <${e.toLowerCase()}>: value ${n} is invalid.`,args:[r]}),5:(t,e)=>`${t} binding missing event type at ${e.outerHTML}`,6:(t,e)=>({msg:t,args:[e]})},I=(t,...e)=>{let n=wn[t],r=U(n)?n.call(wn,...e):n,o=Qe.warning;o&&(H(r)?o(r):o(r,...r.args))},Qe={warning:console.warn};var pt={},ct={},An=1,On=t=>{let e=(An++).toString();return pt[e]=t,ct[e]=0,e},Kt=t=>{ct[t]+=1},Wt=t=>{--ct[t]===0&&(delete pt[t],delete ct[t])},Nn=t=>pt[t],Gt=()=>An!==1&&Object.keys(pt).length>0,Xe="r-switch",Zr=t=>{let e=t.filter(r=>Se(r)).map(r=>[...r.querySelectorAll("[r-switch]")].map(o=>o.getAttribute(Xe))),n=new Set;return e.forEach(r=>{r.forEach(o=>o&&n.add(o))}),[...n]},Ie=(t,e)=>{if(!Gt())return;let n=Zr(e);n.length!==0&&(n.forEach(Kt),k(t,()=>{n.forEach(Wt)}))};var Jt=(t,e,n,r)=>{let o=[];for(let s of t){let i=s.cloneNode(!0);n.insertBefore(i,r),o.push(i)}ye(e,o)},Qt=Symbol("r-if"),Mn=Symbol("r-else"),Ln=t=>t[Mn]===1,ft=class{p;P;q;K;z;b;T;constructor(e){this.p=e,this.P=e.o.l.if,this.q=He(e.o.l.if),this.K=e.o.l.else,this.z=e.o.l.elseif,this.b=e.o.l.for,this.T=e.o.l.pre}qe(e,n){let r=e.parentElement;for(;r!==null&&r!==document.documentElement;){if(r.hasAttribute(n))return!0;r=r.parentElement}return!1}N(e){let n=e.hasAttribute(this.P),r=de(e,this.q);for(let o of r)this.x(o);return n}W(e){return e[Qt]?!0:(e[Qt]=!0,de(e,this.q).forEach(n=>n[Qt]=!0),!1)}x(e){if(e.hasAttribute(this.T)||this.W(e)||this.qe(e,this.b))return;let n=e.getAttribute(this.P);if(!n){I(0,this.P,e);return}e.removeAttribute(this.P),this.k(e,n)}B(e,n,r){let o=Ue(e),s=e.parentNode,i=document.createComment(`__begin__ :${n}${r??""}`);s.insertBefore(i,e),Ie(i,o),o.forEach(c=>{P(c)}),e.remove(),n!=="if"&&(e[Mn]=1);let a=document.createComment(`__end__ :${n}${r??""}`);return s.insertBefore(a,i.nextSibling),{nodes:o,parent:s,commentBegin:i,commentEnd:a}}pe(e,n){if(!e)return[];let r=e.nextElementSibling;if(e.hasAttribute(this.K)){e.removeAttribute(this.K);let{nodes:o,parent:s,commentBegin:i,commentEnd:a}=this.B(e,"else");return[{mount:()=>{Jt(o,this.p,s,a)},unmount:()=>{ae(i,a)},isTrue:()=>!0,isMounted:!1}]}else{let o=e.getAttribute(this.z);if(!o)return[];e.removeAttribute(this.z);let{nodes:s,parent:i,commentBegin:a,commentEnd:c}=this.B(e,"elseif",` => ${o} `),f=this.p.h.v(o),p=f.value,l=this.pe(r,n),b=[];k(a,()=>{f.stop();for(let v of b)v();b.length=0});let y=C(p,n);return b.push(y),[{mount:()=>{Jt(s,this.p,i,c)},unmount:()=>{ae(a,c)},isTrue:()=>!!p()[0],isMounted:!1}].concat(l)}}k(e,n){let r=e.nextElementSibling,{nodes:o,parent:s,commentBegin:i,commentEnd:a}=this.B(e,"if",` => ${n} `),c=this.p.h.v(n),f=c.value,p=!1,l=this.p.h,b=l.V(),u=()=>{l.C(b,()=>{if(f()[0])p||(Jt(o,this.p,s,a),p=!0),y.forEach(A=>{A.unmount(),A.isMounted=!1});else{ae(i,a),p=!1;let A=!1;for(let O of y)!A&&O.isTrue()?(O.isMounted||(O.mount(),O.isMounted=!0),A=!0):(O.unmount(),O.isMounted=!1)}})},y=this.pe(r,u),v=[];k(i,()=>{c.stop();for(let A of v)A();v.length=0}),u();let h=C(f,u);v.push(h)}};var Ue=t=>{let e=ne(t)?t.content.childNodes:[t];return Array.from(e).filter(n=>{let r=n?.tagName;return r!=="SCRIPT"&&r!=="STYLE"})},ye=(t,e)=>{for(let n of e)!Ln(n)&&t.G(n)},de=(t,e)=>{let n=t.querySelectorAll(e);return t.matches?.(e)?[t,...n]:n},ne=t=>t instanceof HTMLTemplateElement,Se=t=>t.nodeType===Node.ELEMENT_NODE,Ye=t=>t.nodeType===Node.ELEMENT_NODE,kn=t=>t instanceof HTMLSlotElement,ce=t=>ne(t)?t.content.childNodes:t.childNodes,ae=(t,e)=>{let n=t.nextSibling;for(;n!=null&&n!==e;){let r=n.nextSibling;P(n),n=r}},he=(t,e)=>{Object.defineProperty(t,"value",{get(){return t()},set(n){if(e)throw new Error("value is readonly.");return t(n)},enumerable:!0,configurable:!1})},In=(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},He=t=>`[${CSS.escape(t)}]`,lt=(t,e)=>(t.startsWith("@")&&(t=e.l.on+":"+t.slice(1)),t.includes("[")&&(t=t.replace(/[[\]]/g,e.l.dynamic)),t),Xt=t=>{let e=Object.create(null);return n=>e[n]||(e[n]=t(n))},eo=/-(\w)/g,B=Xt(t=>t&&t.replace(eo,(e,n)=>n?n.toUpperCase():"")),to=/\B([A-Z])/g,_e=Xt(t=>t&&t.replace(to,"-$1").toLowerCase()),Ze=Xt(t=>t&&t.charAt(0).toUpperCase()+t.slice(1));var Z=[],Dn=t=>{Z.length!==0&&Z[Z.length-1]?.add(t)},we=t=>{if(!t)return()=>{};let e={stop:()=>{}};return no(t,e),K(()=>e.stop(),!0),e.stop},no=(t,e)=>{if(!t)return;let n=[],r=!1,o=()=>{for(let s of n)s();n=[],r=!0};e.stop=o;try{let s=new Set;if(Z.push(s),t(i=>n.push(i)),r)return;for(let i of[...s]){let a=C(i,()=>{o(),we(t)});n.push(a)}}finally{Z.pop()}},ut=t=>{let e=Z.length,n=e>0&&Z[e-1];try{return n&&Z.push(null),t()}finally{n&&Z.pop()}},mt=t=>{try{let e=new Set;return Z.push(e),{value:t(),refs:[...e]}}finally{Z.pop()}};var Be=t=>!!t&&t[at]===1;var F=(t,e,n)=>{if(!m(t))return;let r=t;if(r(void 0,e,1),!n)return;let o=r();if(o){if(T(o)||X(o))for(let s of o)F(s,e,!0);else if(ue(o))for(let s of o)F(s[0],e,!0),F(s[1],e,!0);if(w(o))for(let s in o)F(o[s],e,!0)}};function ro(t,e,n){Object.defineProperty(t,e,{value:n,enumerable:!1,writable:!0,configurable:!0})}var Ve=(t,e,n)=>{n.forEach(function(r){let o=t[r];ro(e,r,function(...i){let a=o.apply(this,i),c=this[G];for(let f of c)F(f);return a})})},dt=(t,e)=>{Object.defineProperty(t,Symbol.toStringTag,{value:e,writable:!1,enumerable:!1,configurable:!0})};var Un=Array.prototype,Yt=Object.create(Un),oo=["push","pop","shift","unshift","splice","sort","reverse"];Ve(Un,Yt,oo);var Hn=Map.prototype,yt=Object.create(Hn),so=["set","clear","delete"];dt(yt,"Map");Ve(Hn,yt,so);var _n=Set.prototype,ht=Object.create(_n),io=["add","clear","delete"];dt(ht,"Set");Ve(_n,ht,io);var Ae={},z=t=>{if(m(t)||Be(t))return t;let e={auto:!0,_value:t},n=c=>w(c)?G in c?!0:T(c)?(Object.setPrototypeOf(c,Yt),!0):X(c)?(Object.setPrototypeOf(c,ht),!0):ue(c)?(Object.setPrototypeOf(c,yt),!0):!1:!1,r=n(t),o=new Set,s=(c,f)=>{if(Ae.set){Ae.set.add(a);return}o.size!==0&&ut(()=>{for(let p of[...o.keys()])o.has(p)&&p(c,f)})},i=c=>{let f=c[G];f||(c[G]=f=new Set),f.add(a)},a=(...c)=>{if(!(2 in c)){let p=c[0],l=c[1];return 0 in c?e._value===p||m(p)&&(p=p(),e._value===p)?p:(n(p)&&i(p),e._value=p,e.auto&&s(p,l),e._value):(Dn(a),e._value)}switch(c[2]){case 0:{let p=c[3];if(!p)return()=>{};let l=b=>{o.delete(b)};return o.add(p),()=>{l(p)}}case 1:{let p=c[1],l=e._value;s(l,p);break}case 2:return o.size;case 3:{e.auto=!1;break}case 4:e.auto=!0}return e._value};return a[G]=1,he(a,!1),r&&i(t),a};var V=t=>m(t)?t():t;var et=class{E=[];_=new Map;get S(){return this.E.length}J;constructor(e){this.J=e}Q(e){let n=this.J(e.value);n&&this._.set(n,e)}X(e){let n=this.J(this.E[e]?.value);n&&this._.delete(n)}static Ke(e,n){return{items:[],index:e,value:n,order:-1}}w(e){e.order=this.S,this.E.push(e),this.Q(e)}ze(e,n){let r=this.S;for(let o=e;o<r;++o)this.E[o].order=o+1;n.order=e,this.E.splice(e,0,n),this.Q(n)}I(e){return this.E[e]}Y(e,n){this.X(e),this.E[e]=n,this.Q(n),n.order=e}ce(e){this.X(e),this.E.splice(e,1);let n=this.S;for(let r=e;r<n;++r)this.E[r].order=r}le(e){let n=this.S;for(let r=e;r<n;++r)this.X(r);this.E.splice(e)}Rt(e){return this._.has(e)}We(e){return this._.get(e)?.order??-1}};var Zt=Symbol("r-for"),gt=class t{p;b;Z;T;constructor(e){this.p=e,this.b=e.o.l.for,this.Z=He(this.b),this.T=e.o.l.pre}N(e){let n=e.hasAttribute(this.b),r=de(e,this.Z);for(let o of r)this.Ge(o);return n}W(e){return e[Zt]?!0:(e[Zt]=!0,de(e,this.Z).forEach(n=>n[Zt]=!0),!1)}Ge(e){if(e.hasAttribute(this.T)||this.W(e))return;let n=e.getAttribute(this.b);if(!n){I(0,this.b,e);return}e.removeAttribute(this.b),this.Je(e,n)}fe(e){return Y(e)?[]:(U(e)&&(e=e()),Symbol.iterator in Object(e)?e:typeof e=="number"?(r=>({*[Symbol.iterator](){for(let o=1;o<=r;o++)yield o}}))(e):Object.entries(e))}Je(e,n){let r=this.Qe(n);if(!r?.list){I(1,this.b,n,e);return}let o=this.p.o.l.key,s=this.p.o.l.keyBind,i=e.getAttribute(o)??e.getAttribute(s);e.removeAttribute(o),e.removeAttribute(s);let a=i?x=>V(V(x)?.[i]):x=>x,c=(x,N)=>a(x)===a(N),f=Ue(e),p=e.parentNode;if(!p)return;let l=`${this.b} => ${n}`,b=new Comment(`__begin__ ${l}`);p.insertBefore(b,e),Ie(b,f),f.forEach(x=>{P(x)}),e.remove();let u=new Comment(`__end__ ${l}`);p.insertBefore(u,b.nextSibling);let y=this.p,v=y.h,S=v.V(),h=(x,N,q)=>{let R=r.createContext(N,x),Q=et.Ke(R.index,N);return v.C(S,()=>{v.w(R.ctx);let ee=q.previousSibling,Le=[];for(let d of f){let M=d.cloneNode(!0);p.insertBefore(M,q),Le.push(M)}for(ye(y,Le),ee=ee.nextSibling;ee!==q;)Q.items.push(ee),ee=ee.nextSibling}),Q},A=(x,N)=>{let q=L.I(x).items,R=q[q.length-1].nextSibling;for(let Q of q)P(Q);L.Y(x,h(x,N,R))},O=(x,N)=>{L.w(h(x,N,u))},Ee=x=>{for(let N of L.I(x).items)P(N)},We=x=>{let N=L.S;for(let q=x;q<N;++q)L.I(q).index(q)},Vt=x=>{let N=L.S;U(x)&&(x=x());let q=V(x[0]);if(T(q)&&q.length===0){ae(b,u),L.le(0);return}let R=0,Q=Number.MAX_SAFE_INTEGER,ee=N,Le=this.p.o.forGrowThreshold,d=()=>L.S<ee+Le;for(let g of this.fe(x[0])){let D=()=>{if(R<N){let W=L.I(R++);if(c(W.value,g))return;let E=L.We(a(g));if(E>=R&&E-R<10){if(--R,Q=Math.min(Q,R),Ee(R),L.ce(R),--N,E>R+1)for(let j=R;j<E-1&&j<N&&!c(L.I(R).value,g);)++j,Ee(R),L.ce(R),--N;D();return}d()?(L.ze(R-1,h(R,g,L.I(R-1).items[0])),Q=Math.min(Q,R-1),++N):A(R-1,g)}else O(R++,g)};D()}let M=R;for(N=L.S;R<N;)Ee(R++);L.le(M),We(Q)},nt=()=>{Ge=C(le,Vt)},ve=()=>{rt.stop(),Ge()},rt=v.v(r.list),le=rt.value,Ge,oe=0,L=new et(a);for(let x of this.fe(le()[0]))L.w(h(oe++,x,u));k(b,ve),nt()}static Xe=/\{?\[?\(?([^)}\]]+)\)?\]?\}?([^)]+)?\s+\b(?:in|of)\b\s+([^\s]+)\s*/;Qe(e){let n=t.Xe.exec(e);if(!n)return;let r=(n[1]+(n[2]??"")).split(",").map(c=>c.trim()),o=r.length>1?r.length-1:-1,s=o!==-1&&(r[o]==="index"||r[o]?.startsWith("#"))?r[o]:"";s&&r.splice(o,1);let i=n[3];if(!i||r.length===0)return;let a=/[{[]/.test(e);return{list:i,createContext:(c,f)=>{let p={},l=V(c);if(!a&&r.length===1)p[r[0]]=c;else if(T(l)){let u=0;for(let y of r)p[y]=l[u++]}else for(let u of r)p[u]=l[u];let b={ctx:p,index:z(-1)};return s&&(b.index=p[s.startsWith("#")?s.substring(1):s]=z(f)),b}}}};var ao=(t,e)=>{for(let n of t){let r=n.cloneNode(!0);e.appendChild(r)}},bt=class{p;D;ue;constructor(e){this.p=e,this.D=e.o.l.is,this.ue=He(this.D)+", [is]"}N(e){let n=e.hasAttribute(this.D),r=de(e,this.ue);for(let o of r)this.x(o);return n}x(e){let n=e.getAttribute(this.D);if(!n){if(n=e.getAttribute("is"),!n||!n.startsWith("regor:"))return;n=`'${n.slice(6)}'`,e.removeAttribute("is")}e.removeAttribute(this.D),this.k(e,n)}B(e,n){let r=Ue(e),o=e.parentNode,s=document.createComment(`__begin__ dynamic ${n??""}`);o.insertBefore(s,e),Ie(s,r),r.forEach(a=>{P(a)}),e.remove();let i=document.createComment(`__end__ dynamic ${n??""}`);return o.insertBefore(i,s.nextSibling),{nodes:r,parent:o,commentBegin:s,commentEnd:i}}k(e,n){let{nodes:r,parent:o,commentBegin:s,commentEnd:i}=this.B(e,` => ${n} `),a=this.p.h.v(n),c=a.value,f=this.p.h,p=f.V(),l={name:""},b=ne(e)?r:[...r[0].childNodes],u=()=>{f.C(p,()=>{let h=c()[0];if(w(h)&&(h.name?h=h.name:h=Object.entries(f.me()).filter(O=>O[1]===h)[0]?.[0]),!H(h)||$(h)){ae(s,i);return}if(l.name===h)return;ae(s,i);let A=document.createElement(h);for(let O of e.getAttributeNames())O!==this.D&&A.setAttribute(O,e.getAttribute(O));ao(b,A),o.insertBefore(A,i),this.p.G(A),l.name=h})},y=[];k(s,()=>{a.stop();for(let h of y)h();y.length=0}),u();let S=C(c,u);y.push(S)}};var Bn={collectRefObj:!0,onBind:(t,e)=>C(e.value,()=>{let r=e.value(),o=e.context,s=r[0];if(w(s))for(let i of Object.entries(s)){let a=i[0],c=i[1],f=o[a];f!==c&&(m(f)?f(c):o[a]=c)}},!0)};var Vn={collectRefObj:!0,once:!0,onBind:(t,e)=>{let n=e.value(),r=e.context,o=n[0];if(!w(o))return()=>{};for(let s of Object.entries(o)){let i=s[0],a=s[1],c=r[i];c!==a&&(m(c)?c(a):r[i]=a)}return()=>{}}};var ge=t=>{st(t)?.onUnmounted?.forEach(n=>{n()}),t.unmounted?.()};var Pe=class{props;start;end;ctx;autoProps=!0;entangle=!0;disableSwitch=!1;onAutoPropsAssigned;de;constructor(e,n,r,o,s){this.props=e,this.de=n,this.ctx=r,this.start=o,this.end=s}emit=(e,n)=>{this.de.dispatchEvent(new CustomEvent(e,{detail:n}))};unmount(){let e=this.start.nextSibling,n=this.end;for(;e&&e!==n;)P(e),e=e.nextSibling;ge(this)}};var en=Symbol("scope"),Tt=t=>{try{Rn();let e=t();zt(e);let n={context:e,unmount:()=>ge(e),[en]:1};return n[en]=1,n}finally{Sn()}},Pn=t=>w(t)?en in t:!1;var Et=(t,e)=>{if(t===e)return()=>{};let n=C(t,o=>e(o)),r=C(e,o=>t(o));return e(t()),()=>{n(),r()}};var vt=t=>{st(t)?.onMounted?.forEach(n=>{n()}),t.mounted?.()};var jn={collectRefObj:!0,onBind:(t,e,n,r,o,s)=>{if(!r)return()=>{};let i=B(r);return C(e.value,()=>{let c=e.refs[0]??e.value()[0],f=e.context,p=f[r];p!==c&&(m(p)?p(c):f[i]=c)},!0)}};var xt=class{p;ye;constructor(e){this.p=e,this.ye=e.o.l.inherit}N(e){this.Ye(e)}Ye(e){let n=this.p,r=n.h,o=n.o.he,s=n.o.ge,i=r.me(),a=[...o.keys(),...Object.keys(i),...[...o.keys()].map(_e),...[...Object.keys(i)].map(_e)].join(",");if($(a))return;let c=e.querySelectorAll(a),f=e.matches?.(a)?[e,...c]:c;for(let p of f){if(p.hasAttribute(n.T))continue;let l=p.parentNode;if(!l)continue;let b=p.nextSibling,u=B(p.tagName).toUpperCase(),v=i[u]??s.get(u);if(!v)continue;let S=v.template;if(!S)continue;let h=p.parentElement;if(!h)continue;let A=new Comment(" begin component: "+p.tagName),O=new Comment(" end component: "+p.tagName);h.insertBefore(A,p),p.remove();let Ee=n.o.l.props,We=n.o.l.propsOnce,Vt=n.o.l.bind,nt=(d,M)=>{let g={},D=d.hasAttribute(Ee),W=d.hasAttribute(We);return r.C(M,()=>{r.w(g),D&&n.x(Bn,d,Ee),W&&n.x(Vn,d,We);let E=v.props;if(!E||E.length===0)return;E=E.map(B);for(let xe of E.concat(E.map(_e))){let se=d.getAttribute(xe);se!==null&&(g[B(xe)]=se,d.removeAttribute(xe))}let j=n.ee.be(d,!1);for(let[xe,se]of j.entries()){let[Ce,Pt]=se.te;Pt&&E.includes(B(Pt))&&(Ce!=="."&&Ce!==":"&&Ce!==Vt||n.x(jn,d,xe,!0,Pt,se.ne))}}),g},ve=[...r.V()],rt=()=>{let d=nt(p,ve),M=new Pe(d,p,ve,A,O),g=Tt(()=>v.context(M)??{}).context;if(M.autoProps){for(let[D,W]of Object.entries(d))if(D in g){let E=g[D];if(E===W)continue;M.entangle&&m(E)&&m(W)?k(A,Et(W,E)):m(E)?E(W):g[D]=V(W)}else g[D]=W;M.onAutoPropsAssigned?.()}return{componentCtx:g,head:M}},{componentCtx:le,head:Ge}=rt(),oe=[...ce(S)],L=oe.length,x=p.childNodes.length===0,N=d=>{let M=d.parentElement;if(x){for(let E of[...d.childNodes])M.insertBefore(E,d);return}let g=d.name;$(g)&&(g=d.getAttributeNames().filter(E=>E.startsWith("#"))[0],$(g)?g="default":g=g.substring(1));let D=p.querySelector(`template[name='${g}'], template[\\#${g}]`);!D&&g==="default"&&(D=p.querySelector("template:not([name])"),D&&D.getAttributeNames().filter(E=>E.startsWith("#")).length>0&&(D=null));let W=E=>{Ge.disableSwitch||r.C(ve,()=>{r.w(le);let j=nt(d,r.V());r.C(ve,()=>{r.w(j);let xe=r.V(),se=On(xe);for(let Ce of E)Se(Ce)&&(Ce.setAttribute(Xe,se),Kt(se),k(Ce,()=>{Wt(se)}))})})};if(D){let E=[...ce(D)];for(let j of E)M.insertBefore(j,d);W(E)}else{if(g!=="default"){for(let j of[...ce(d)])M.insertBefore(j,d);return}let E=[...ce(p)].filter(j=>!ne(j));for(let j of E)M.insertBefore(j,d);W(E)}},q=d=>{if(!Se(d))return;let M=d.querySelectorAll("slot");if(kn(d)){N(d),d.remove();return}for(let g of M)N(g),g.remove()};(()=>{for(let d=0;d<L;++d)oe[d]=oe[d].cloneNode(!0),l.insertBefore(oe[d],b),q(oe[d])})(),h.insertBefore(O,b);let Q=()=>{if(!v.inheritAttrs)return;let d=oe.filter(g=>g.nodeType===Node.ELEMENT_NODE);d.length>1&&(d=d.filter(g=>g.hasAttribute(this.ye)));let M=d[0];if(M)for(let g of p.getAttributeNames()){if(g===Ee||g===We)continue;let D=p.getAttribute(g);if(g==="class")M.classList.add(...D.split(" "));else if(g==="style"){let W=M.style,E=p.style;for(let j of E)W.setProperty(j,E.getPropertyValue(j))}else M.setAttribute(lt(g,n.o),D)}},ee=()=>{for(let d of p.getAttributeNames())!d.startsWith("@")&&!d.startsWith(n.o.l.on)&&p.removeAttribute(d)},Le=()=>{Q(),ee(),r.w(le),n.Te(p,!1),le.$emit=Ge.emit,ye(n,oe),k(p,()=>{ge(le)}),k(A,()=>{te(p)}),vt(le)};r.C(ve,Le)}}};var tn=class{xe;te=[];ne=[];Ee=[];constructor(e){this.xe=e,this.v()}v(){let e=this.xe,n=e.startsWith(".");n&&(e=":"+e.slice(1));let r=e.indexOf("."),o=this.te=(r<0?e:e.substring(0,r)).split(/[:@]/);if($(o[0])&&(o[0]=n?".":e[0]),r>=0){let s=this.ne=e.slice(r+1).split(".");if(s.includes("camel")){let i=o.length-1;o[i]=B(o[i])}s.includes("prop")&&(o[0]=".")}}},Ct=class{p;Re;constructor(e){this.p=e,this.Re=e.o.Ze()}be(e,n){let r=new Map;if(!Ye(e))return r;let o=this.Re,s=a=>{let c=a.getAttributeNames().filter(f=>o.some(p=>f.startsWith(p)));for(let f of c)r.has(f)||r.set(f,new tn(f)),r.get(f).Ee.push(a)};if(s(e),!n)return r;let i=e.querySelectorAll("*");for(let a of i)s(a);return r}};var Rt={};var St=class{h;ve;Ce;Se;we;ee;o;T;Ae;constructor(e){this.h=e,this.o=e.o,this.Ce=new gt(this),this.ve=new ft(this),this.Se=new bt(this),this.we=new xt(this),this.ee=new Ct(this),this.T=this.o.l.pre,this.Ae=this.o.l.dynamic}et(e){let n=ne(e)?[e]:e.querySelectorAll("template");for(let r of n){if(r.hasAttribute(this.T))continue;let o=r.parentNode;if(!o)continue;let s=r.nextSibling;if(r.remove(),!r.content)continue;let i=[...r.content.childNodes];for(let a of i)o.insertBefore(a,s);ye(this,i)}}G(e){e.nodeType!==Node.ELEMENT_NODE||e.hasAttribute(this.T)||this.ve.N(e)||this.Ce.N(e)||this.Se.N(e)||(this.we.N(e),this.et(e),this.Te(e,!0))}Te(e,n){let r=this.ee.be(e,n),o=this.o.H;for(let[s,i]of r.entries()){let[a,c]=i.te,f=o[s]??o[a];if(!f){console.error("directive not found:",a);continue}i.Ee.forEach(p=>{this.x(f,p,s,!1,c,i.ne)})}}x(e,n,r,o,s,i){if(n.hasAttribute(this.T))return;let a=n.getAttribute(r);n.removeAttribute(r);let c=f=>{let p=f.getAttribute(Xe);return p||(f.parentElement?c(f.parentElement):null)};if(Gt()){let f=c(n);if(f){this.h.C(Nn(f),()=>{this.k(e,n,a,s,i)});return}}this.k(e,n,a,s,i)}tt(e,n,r){if(e!==Rt)return!1;if($(r))return!0;let o=document.querySelector(r);if(o){let s=n.parentElement;if(!s)return!0;let i=new Comment(`teleported => '${r}'`);s.insertBefore(i,n),n.teleportedFrom=i,i.teleportedTo=n,k(i,()=>{P(n)}),o.appendChild(n)}return!0}k(e,n,r,o,s){if(n.nodeType!==Node.ELEMENT_NODE||r==null||this.tt(e,n,r))return;let i=this.h.v(r,e.isLazy,e.isLazyKey,e.collectRefObj,e.once),a=[];k(n,()=>{i.stop(),p?.stop();for(let S of a)S();a.length=0});let f=In(o,this.Ae),p;f&&(p=this.h.v(B(f),void 0,void 0,void 0,e.once));let l,b=()=>(l=i.value(),l),u,y=()=>p?(u=p.value()[0],u):(u=o,o),v=()=>{if(!e.onChange)return;let S=C(i.value,h=>{let A=l,O=u;e.onChange?.(n,b(),A,y(),O,s)});if(a.push(S),p){let h=C(p.value,A=>{let O=u;e.onChange?.(n,b(),O,y(),O,s)});a.push(h)}};e.once||v(),e.onBind&&a.push(e.onBind(n,i,r,o,p,s)),e.onChange?.(n,b(),void 0,y(),void 0,s)}};var co=9,po=10,fo=13,lo=32,be=46,wt=44,uo=39,mo=34,At=40,je=41,Ot=91,Nt=93,nn=63,yo=59,$n=58,ho=123,Mt=125,on=43,go=45,Fn=96,qn=47,bo=92,zn=[2,3],Kn=[on,go],Yn={"-":1,"!":1,"~":1,"+":1,new:1},Zn={"=":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},Fe={"=>":2,...Zn,"||":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},er=Object.keys(Zn),To=new Set(er),Lt=new Set;Lt.add("=>");er.forEach(t=>Lt.add(t));var Eo=new Set(["$","_"]),Wn={true:!0,false:!1,null:null},vo="this";function tr(t){return Math.max(0,...Object.keys(t).map(e=>e.length))}var xo=tr(Yn),Co=tr(Fe),qe="Expected ",Oe="Unexpected ",an="Unclosed ",Ro=qe+":",Gn=qe+"expression",So="missing }",wo=Oe+"object property",Ao=an+"(",Jn=qe+"comma",Qn=Oe+"token ",Oo=Oe+"period",rn=qe+"expression after ",No="missing unaryOp argument",Mo=an+"[",Lo=qe+"exponent (",ko="Variable names cannot start with a number (",Io=an+'quote after "';var $e=t=>t>=48&&t<=57,Xn=t=>Fe[t]||0,sn=class{nt={0:[this.rt],1:[this.ot,this.st,this.it],2:[this.at,this.pt,this.ct,this.Oe,this.lt],3:[this.ft,this.ut,this.mt]};r;e;get M(){return this.r.charAt(this.e)}get f(){return this.r.charCodeAt(this.e)}u(e){return this.r.charCodeAt(this.e)===e}constructor(e){this.r=e,this.e=0}U(e){let n=String.fromCharCode(e);return e>=65&&e<=90||e>=97&&e<=122||e>=128&&!(n in Fe)||Eo.has(n)}re(e){return this.U(e)||$e(e)}i(e){return new Error(`${e} at character ${this.e}`)}L(e,n,r){let o=this.nt[e];if(!o)return r;let s={node:r},i=a=>{a.call(this,s)};return n===0?o.forEach(i):o.find(i),s.node}y(){let e=this.f,n=this.r,r=this.e;for(;e===lo||e===co||e===po||e===fo;)e=n.charCodeAt(++r);this.e=r}parse(){let e=this.oe();return e.length===1?e[0]:{type:0,body:e}}oe(e){let n=[];for(;this.e<this.r.length;){let r=this.f;if(r===yo||r===wt)this.e++;else{let o=this.A();if(o)n.push(o);else if(this.e<this.r.length){if(r===e)break;throw this.i(Oe+'"'+this.M+'"')}}}return n}A(){let e=this.L(0,1)??this.Ne();return this.y(),this.L(1,0,e)}se(){this.y();let e=this.e,n=this.r,r=n.substr(e,Co),o=r.length;for(;o>0;){if(r in Fe&&(!this.U(this.f)||e+r.length<n.length&&!this.re(n.charCodeAt(e+r.length))))return e+=o,this.e=e,r;r=r.substr(0,--o)}return!1}Ne(){let e,n,r,o,s,i,a,c;if(s=this.j(),!s||(n=this.se(),!n))return s;if(o={value:n,prec:Xn(n),right_a:Lt.has(n)},i=this.j(),!i)throw this.i(rn+n);let f=[s,o,i];for(;n=this.se();){if(r=Xn(n),r===0){this.e-=n.length;break}o={value:n,prec:r,right_a:Lt.has(n)},c=n;let p=l=>o.right_a&&l.right_a?r>l.prec:r<=l.prec;for(;f.length>2&&p(f[f.length-2]);)i=f.pop(),n=f.pop().value,s=f.pop(),e={type:8,operator:n,left:s,right:i},f.push(e);if(e=this.j(),!e)throw this.i(rn+c);f.push(o,e)}for(a=f.length-1,e=f[a];a>1;)e={type:8,operator:f[a-1].value,left:f[a-2],right:e},a-=2;return e}j(){let e,n,r;if(this.y(),r=this.L(2,1),r)return this.L(3,0,r);let o=this.f;if($e(o)||o===be)return this.dt();if(o===uo||o===mo)r=this.yt();else if(o===Ot)r=this.ht();else{for(e=this.r.substr(this.e,xo),n=e.length;n>0;){if(Object.prototype.hasOwnProperty.call(Yn,e)&&(!this.U(this.f)||this.e+e.length<this.r.length&&!this.re(this.r.charCodeAt(this.e+e.length)))){this.e+=n;let s=this.j();if(!s)throw this.i(No);return this.L(3,0,{type:7,operator:e,argument:s})}e=e.substr(0,--n)}this.U(o)?(r=this.ie(),r.name in Wn?r={type:4,value:Wn[r.name],raw:r.name}:r.name===vo&&(r={type:5})):o===At&&(r=this.gt())}return r?(r=this.F(r),this.L(3,0,r)):this.L(3,0,!1)}F(e){this.y();let n=this.f;for(;n===be||n===Ot||n===At||n===nn;){let r;if(n===nn){if(this.r.charCodeAt(this.e+1)!==be)break;r=!0,this.e+=2,this.y(),n=this.f}if(this.e++,n===Ot){if(e={type:3,computed:!0,object:e,property:this.A()},this.y(),n=this.f,n!==Nt)throw this.i(Mo);this.e++}else n===At?e={type:6,arguments:this.Me(je),callee:e}:(n===be||r)&&(r&&this.e--,this.y(),e={type:3,computed:!1,object:e,property:this.ie()});r&&(e.optional=!0),this.y(),n=this.f}return e}dt(){let e="",n;for(;$e(this.f);)e+=this.r.charAt(this.e++);if(this.u(be))for(e+=this.r.charAt(this.e++);$e(this.f);)e+=this.r.charAt(this.e++);if(n=this.M,n==="e"||n==="E"){for(e+=this.r.charAt(this.e++),n=this.M,(n==="+"||n==="-")&&(e+=this.r.charAt(this.e++));$e(this.f);)e+=this.r.charAt(this.e++);if(!$e(this.r.charCodeAt(this.e-1)))throw this.i(Lo+e+this.M+")")}let r=this.f;if(this.U(r))throw this.i(ko+e+this.M+")");if(r===be||e.length===1&&e.charCodeAt(0)===be)throw this.i(Oo);return{type:4,value:parseFloat(e),raw:e}}yt(){let e="",n=this.e,r=this.r.charAt(this.e++),o=!1;for(;this.e<this.r.length;){let s=this.r.charAt(this.e++);if(s===r){o=!0;break}else if(s==="\\")switch(s=this.r.charAt(this.e++),s){case"n":e+=`
1
+ "use strict";var Regor=(()=>{var jt=Object.defineProperty;var zr=Object.getOwnPropertyDescriptor;var Kr=Object.getOwnPropertyNames;var Wr=Object.prototype.hasOwnProperty;var Gr=(t,e)=>{for(var n in e)jt(t,n,{get:e[n],enumerable:!0})},Jr=(t,e,n,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of Kr(e))!Wr.call(t,o)&&o!==n&&jt(t,o,{get:()=>e[o],enumerable:!(r=zr(e,o))||r.enumerable});return t};var Qr=t=>Jr(jt({},"__esModule",{value:!0}),t);var us={};Gr(us,{ComponentHead:()=>Pe,RegorConfig:()=>re,addUnbinder:()=>k,batch:()=>Fr,collectRefs:()=>mt,computeMany:()=>Hr,computeRef:()=>_r,computed:()=>Ur,createApp:()=>Ir,createComponent:()=>Dr,endBatch:()=>vn,entangle:()=>Et,flatten:()=>J,getBindData:()=>me,html:()=>Tn,isDeepRef:()=>Ne,isRaw:()=>Be,isRef:()=>m,markRaw:()=>Br,observe:()=>C,observeMany:()=>jr,observerCount:()=>$r,onMounted:()=>qr,onUnmounted:()=>K,pause:()=>Ht,persist:()=>Vr,raw:()=>Pr,ref:()=>Te,removeNode:()=>P,resume:()=>_t,silence:()=>ut,sref:()=>z,startBatch:()=>En,toFragment:()=>Me,toJsonTemplate:()=>Ke,trigger:()=>F,unbind:()=>te,unref:()=>V,useScope:()=>Tt,warningHandler:()=>Qe,watchEffect:()=>we});var U=t=>typeof t=="function",H=t=>typeof t=="string",xn=t=>typeof t>"u",Y=t=>t==null||typeof t>"u",$=t=>typeof t!="string"||!t?.trim(),Xr=Object.prototype.toString,$t=t=>Xr.call(t),ue=t=>$t(t)==="[object Map]",X=t=>$t(t)==="[object Set]",Ft=t=>$t(t)==="[object Date]",Je=t=>typeof t=="symbol",T=Array.isArray,w=t=>t!==null&&typeof t=="object";var Cn={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."},_=(t,...e)=>{let n=Cn[t];return new Error(U(n)?n.call(Cn,...e):n)};var ke=Symbol(":regor");var me=t=>{let e=t[ke];if(e)return e;let n={unbinders:[],data:{}};return t[ke]=n,n};var k=(t,e)=>{me(t).unbinders.push(e)};var ot=[],Rn=()=>{let t={onMounted:[],onUnmounted:[]};return ot.push(t),t},Re=t=>{let e=ot[ot.length-1];if(!e&&!t)throw _(2);return e},Sn=t=>{let e=Re();return t&&zt(t),ot.pop(),e},qt=Symbol("csp"),zt=t=>{let e=t,n=e[qt];if(n){let r=Re();if(n===r)return;r.onMounted.length>0&&n.onMounted.push(...r.onMounted),r.onUnmounted.length>0&&n.onUnmounted.push(...r.onUnmounted);return}e[qt]=Re()},st=t=>t[qt];var K=(t,e)=>{Re(e)?.onUnmounted.push(t)};var it=Symbol("ref"),G=Symbol("sref"),at=Symbol("raw");var m=t=>t?.[G]===1;var C=(t,e,n)=>{if(!m(t))throw _(3,"observe");n&&e(t());let o=t(void 0,void 0,0,e);return K(o,!0),o};var te=t=>{let e=[t];for(;e.length>0;){let n=e.shift();Yr(n);let r=n.childNodes;if(r)for(let o of r)e.push(o)}},Yr=t=>{let e=t[ke];if(e){for(let n of e.unbinders)n();e.unbinders.splice(0),delete t[ke]}};var P=t=>{t.remove(),setTimeout(()=>te(t),1)};var wn={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,r)=>({msg:`Failed setting prop "${t}" on <${e.toLowerCase()}>: value ${n} is invalid.`,args:[r]}),5:(t,e)=>`${t} binding missing event type at ${e.outerHTML}`,6:(t,e)=>({msg:t,args:[e]})},I=(t,...e)=>{let n=wn[t],r=U(n)?n.call(wn,...e):n,o=Qe.warning;o&&(H(r)?o(r):o(r,...r.args))},Qe={warning:console.warn};var pt={},ct={},An=1,On=t=>{let e=(An++).toString();return pt[e]=t,ct[e]=0,e},Kt=t=>{ct[t]+=1},Wt=t=>{--ct[t]===0&&(delete pt[t],delete ct[t])},Nn=t=>pt[t],Gt=()=>An!==1&&Object.keys(pt).length>0,Xe="r-switch",Zr=t=>{let e=t.filter(r=>Se(r)).map(r=>[...r.querySelectorAll("[r-switch]")].map(o=>o.getAttribute(Xe))),n=new Set;return e.forEach(r=>{r.forEach(o=>o&&n.add(o))}),[...n]},Ie=(t,e)=>{if(!Gt())return;let n=Zr(e);n.length!==0&&(n.forEach(Kt),k(t,()=>{n.forEach(Wt)}))};var Jt=(t,e,n,r)=>{let o=[];for(let s of t){let i=s.cloneNode(!0);n.insertBefore(i,r),o.push(i)}ye(e,o)},Qt=Symbol("r-if"),Mn=Symbol("r-else"),Ln=t=>t[Mn]===1,ft=class{p;P;q;K;z;b;T;constructor(e){this.p=e,this.P=e.o.l.if,this.q=He(e.o.l.if),this.K=e.o.l.else,this.z=e.o.l.elseif,this.b=e.o.l.for,this.T=e.o.l.pre}qe(e,n){let r=e.parentElement;for(;r!==null&&r!==document.documentElement;){if(r.hasAttribute(n))return!0;r=r.parentElement}return!1}N(e){let n=e.hasAttribute(this.P),r=de(e,this.q);for(let o of r)this.x(o);return n}W(e){return e[Qt]?!0:(e[Qt]=!0,de(e,this.q).forEach(n=>n[Qt]=!0),!1)}x(e){if(e.hasAttribute(this.T)||this.W(e)||this.qe(e,this.b))return;let n=e.getAttribute(this.P);if(!n){I(0,this.P,e);return}e.removeAttribute(this.P),this.V(e,n)}B(e,n,r){let o=Ue(e),s=e.parentNode,i=document.createComment(`__begin__ :${n}${r??""}`);s.insertBefore(i,e),Ie(i,o),o.forEach(c=>{P(c)}),e.remove(),n!=="if"&&(e[Mn]=1);let a=document.createComment(`__end__ :${n}${r??""}`);return s.insertBefore(a,i.nextSibling),{nodes:o,parent:s,commentBegin:i,commentEnd:a}}pe(e,n){if(!e)return[];let r=e.nextElementSibling;if(e.hasAttribute(this.K)){e.removeAttribute(this.K);let{nodes:o,parent:s,commentBegin:i,commentEnd:a}=this.B(e,"else");return[{mount:()=>{Jt(o,this.p,s,a)},unmount:()=>{ae(i,a)},isTrue:()=>!0,isMounted:!1}]}else{let o=e.getAttribute(this.z);if(!o)return[];e.removeAttribute(this.z);let{nodes:s,parent:i,commentBegin:a,commentEnd:c}=this.B(e,"elseif",` => ${o} `),f=this.p.h.v(o),p=f.value,l=this.pe(r,n),b=[];k(a,()=>{f.stop();for(let v of b)v();b.length=0});let y=C(p,n);return b.push(y),[{mount:()=>{Jt(s,this.p,i,c)},unmount:()=>{ae(a,c)},isTrue:()=>!!p()[0],isMounted:!1}].concat(l)}}V(e,n){let r=e.nextElementSibling,{nodes:o,parent:s,commentBegin:i,commentEnd:a}=this.B(e,"if",` => ${n} `),c=this.p.h.v(n),f=c.value,p=!1,l=this.p.h,b=l.k(),u=()=>{l.C(b,()=>{if(f()[0])p||(Jt(o,this.p,s,a),p=!0),y.forEach(A=>{A.unmount(),A.isMounted=!1});else{ae(i,a),p=!1;let A=!1;for(let O of y)!A&&O.isTrue()?(O.isMounted||(O.mount(),O.isMounted=!0),A=!0):(O.unmount(),O.isMounted=!1)}})},y=this.pe(r,u),v=[];k(i,()=>{c.stop();for(let A of v)A();v.length=0}),u();let h=C(f,u);v.push(h)}};var Ue=t=>{let e=ne(t)?t.content.childNodes:[t];return Array.from(e).filter(n=>{let r=n?.tagName;return r!=="SCRIPT"&&r!=="STYLE"})},ye=(t,e)=>{for(let n of e)!Ln(n)&&t.G(n)},de=(t,e)=>{let n=t.querySelectorAll(e);return t.matches?.(e)?[t,...n]:n},ne=t=>t instanceof HTMLTemplateElement,Se=t=>t.nodeType===Node.ELEMENT_NODE,Ye=t=>t.nodeType===Node.ELEMENT_NODE,kn=t=>t instanceof HTMLSlotElement,ce=t=>ne(t)?t.content.childNodes:t.childNodes,ae=(t,e)=>{let n=t.nextSibling;for(;n!=null&&n!==e;){let r=n.nextSibling;P(n),n=r}},he=(t,e)=>{Object.defineProperty(t,"value",{get(){return t()},set(n){if(e)throw new Error("value is readonly.");return t(n)},enumerable:!0,configurable:!1})},In=(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},He=t=>`[${CSS.escape(t)}]`,lt=(t,e)=>(t.startsWith("@")&&(t=e.l.on+":"+t.slice(1)),t.includes("[")&&(t=t.replace(/[[\]]/g,e.l.dynamic)),t),Xt=t=>{let e=Object.create(null);return n=>e[n]||(e[n]=t(n))},eo=/-(\w)/g,B=Xt(t=>t&&t.replace(eo,(e,n)=>n?n.toUpperCase():"")),to=/\B([A-Z])/g,_e=Xt(t=>t&&t.replace(to,"-$1").toLowerCase()),Ze=Xt(t=>t&&t.charAt(0).toUpperCase()+t.slice(1));var Z=[],Dn=t=>{Z.length!==0&&Z[Z.length-1]?.add(t)},we=t=>{if(!t)return()=>{};let e={stop:()=>{}};return no(t,e),K(()=>e.stop(),!0),e.stop},no=(t,e)=>{if(!t)return;let n=[],r=!1,o=()=>{for(let s of n)s();n=[],r=!0};e.stop=o;try{let s=new Set;if(Z.push(s),t(i=>n.push(i)),r)return;for(let i of[...s]){let a=C(i,()=>{o(),we(t)});n.push(a)}}finally{Z.pop()}},ut=t=>{let e=Z.length,n=e>0&&Z[e-1];try{return n&&Z.push(null),t()}finally{n&&Z.pop()}},mt=t=>{try{let e=new Set;return Z.push(e),{value:t(),refs:[...e]}}finally{Z.pop()}};var Be=t=>!!t&&t[at]===1;var F=(t,e,n)=>{if(!m(t))return;let r=t;if(r(void 0,e,1),!n)return;let o=r();if(o){if(T(o)||X(o))for(let s of o)F(s,e,!0);else if(ue(o))for(let s of o)F(s[0],e,!0),F(s[1],e,!0);if(w(o))for(let s in o)F(o[s],e,!0)}};function ro(t,e,n){Object.defineProperty(t,e,{value:n,enumerable:!1,writable:!0,configurable:!0})}var Ve=(t,e,n)=>{n.forEach(function(r){let o=t[r];ro(e,r,function(...i){let a=o.apply(this,i),c=this[G];for(let f of c)F(f);return a})})},dt=(t,e)=>{Object.defineProperty(t,Symbol.toStringTag,{value:e,writable:!1,enumerable:!1,configurable:!0})};var Un=Array.prototype,Yt=Object.create(Un),oo=["push","pop","shift","unshift","splice","sort","reverse"];Ve(Un,Yt,oo);var Hn=Map.prototype,yt=Object.create(Hn),so=["set","clear","delete"];dt(yt,"Map");Ve(Hn,yt,so);var _n=Set.prototype,ht=Object.create(_n),io=["add","clear","delete"];dt(ht,"Set");Ve(_n,ht,io);var Ae={},z=t=>{if(m(t)||Be(t))return t;let e={auto:!0,_value:t},n=c=>w(c)?G in c?!0:T(c)?(Object.setPrototypeOf(c,Yt),!0):X(c)?(Object.setPrototypeOf(c,ht),!0):ue(c)?(Object.setPrototypeOf(c,yt),!0):!1:!1,r=n(t),o=new Set,s=(c,f)=>{if(Ae.set){Ae.set.add(a);return}o.size!==0&&ut(()=>{for(let p of[...o.keys()])o.has(p)&&p(c,f)})},i=c=>{let f=c[G];f||(c[G]=f=new Set),f.add(a)},a=(...c)=>{if(!(2 in c)){let p=c[0],l=c[1];return 0 in c?e._value===p||m(p)&&(p=p(),e._value===p)?p:(n(p)&&i(p),e._value=p,e.auto&&s(p,l),e._value):(Dn(a),e._value)}switch(c[2]){case 0:{let p=c[3];if(!p)return()=>{};let l=b=>{o.delete(b)};return o.add(p),()=>{l(p)}}case 1:{let p=c[1],l=e._value;s(l,p);break}case 2:return o.size;case 3:{e.auto=!1;break}case 4:e.auto=!0}return e._value};return a[G]=1,he(a,!1),r&&i(t),a};var V=t=>m(t)?t():t;var et=class{E=[];_=new Map;get S(){return this.E.length}J;constructor(e){this.J=e}Q(e){let n=this.J(e.value);n&&this._.set(n,e)}X(e){let n=this.J(this.E[e]?.value);n&&this._.delete(n)}static Ke(e,n){return{items:[],index:e,value:n,order:-1}}w(e){e.order=this.S,this.E.push(e),this.Q(e)}ze(e,n){let r=this.S;for(let o=e;o<r;++o)this.E[o].order=o+1;n.order=e,this.E.splice(e,0,n),this.Q(n)}I(e){return this.E[e]}Y(e,n){this.X(e),this.E[e]=n,this.Q(n),n.order=e}ce(e){this.X(e),this.E.splice(e,1);let n=this.S;for(let r=e;r<n;++r)this.E[r].order=r}le(e){let n=this.S;for(let r=e;r<n;++r)this.X(r);this.E.splice(e)}Rt(e){return this._.has(e)}We(e){return this._.get(e)?.order??-1}};var Zt=Symbol("r-for"),gt=class t{p;b;Z;T;constructor(e){this.p=e,this.b=e.o.l.for,this.Z=He(this.b),this.T=e.o.l.pre}N(e){let n=e.hasAttribute(this.b),r=de(e,this.Z);for(let o of r)this.Ge(o);return n}W(e){return e[Zt]?!0:(e[Zt]=!0,de(e,this.Z).forEach(n=>n[Zt]=!0),!1)}Ge(e){if(e.hasAttribute(this.T)||this.W(e))return;let n=e.getAttribute(this.b);if(!n){I(0,this.b,e);return}e.removeAttribute(this.b),this.Je(e,n)}fe(e){return Y(e)?[]:(U(e)&&(e=e()),Symbol.iterator in Object(e)?e:typeof e=="number"?(r=>({*[Symbol.iterator](){for(let o=1;o<=r;o++)yield o}}))(e):Object.entries(e))}Je(e,n){let r=this.Qe(n);if(!r?.list){I(1,this.b,n,e);return}let o=this.p.o.l.key,s=this.p.o.l.keyBind,i=e.getAttribute(o)??e.getAttribute(s);e.removeAttribute(o),e.removeAttribute(s);let a=i?x=>V(V(x)?.[i]):x=>x,c=(x,N)=>a(x)===a(N),f=Ue(e),p=e.parentNode;if(!p)return;let l=`${this.b} => ${n}`,b=new Comment(`__begin__ ${l}`);p.insertBefore(b,e),Ie(b,f),f.forEach(x=>{P(x)}),e.remove();let u=new Comment(`__end__ ${l}`);p.insertBefore(u,b.nextSibling);let y=this.p,v=y.h,S=v.k(),h=(x,N,q)=>{let R=r.createContext(N,x),Q=et.Ke(R.index,N);return v.C(S,()=>{v.w(R.ctx);let ee=q.previousSibling,Le=[];for(let d of f){let M=d.cloneNode(!0);p.insertBefore(M,q),Le.push(M)}for(ye(y,Le),ee=ee.nextSibling;ee!==q;)Q.items.push(ee),ee=ee.nextSibling}),Q},A=(x,N)=>{let q=L.I(x).items,R=q[q.length-1].nextSibling;for(let Q of q)P(Q);L.Y(x,h(x,N,R))},O=(x,N)=>{L.w(h(x,N,u))},Ee=x=>{for(let N of L.I(x).items)P(N)},We=x=>{let N=L.S;for(let q=x;q<N;++q)L.I(q).index(q)},Vt=x=>{let N=L.S;U(x)&&(x=x());let q=V(x[0]);if(T(q)&&q.length===0){ae(b,u),L.le(0);return}let R=0,Q=Number.MAX_SAFE_INTEGER,ee=N,Le=this.p.o.forGrowThreshold,d=()=>L.S<ee+Le;for(let g of this.fe(x[0])){let D=()=>{if(R<N){let W=L.I(R++);if(c(W.value,g))return;let E=L.We(a(g));if(E>=R&&E-R<10){if(--R,Q=Math.min(Q,R),Ee(R),L.ce(R),--N,E>R+1)for(let j=R;j<E-1&&j<N&&!c(L.I(R).value,g);)++j,Ee(R),L.ce(R),--N;D();return}d()?(L.ze(R-1,h(R,g,L.I(R-1).items[0])),Q=Math.min(Q,R-1),++N):A(R-1,g)}else O(R++,g)};D()}let M=R;for(N=L.S;R<N;)Ee(R++);L.le(M),We(Q)},nt=()=>{Ge=C(le,Vt)},ve=()=>{rt.stop(),Ge()},rt=v.v(r.list),le=rt.value,Ge,oe=0,L=new et(a);for(let x of this.fe(le()[0]))L.w(h(oe++,x,u));k(b,ve),nt()}static Xe=/\{?\[?\(?([^)}\]]+)\)?\]?\}?([^)]+)?\s+\b(?:in|of)\b\s+([^\s]+)\s*/;Qe(e){let n=t.Xe.exec(e);if(!n)return;let r=(n[1]+(n[2]??"")).split(",").map(c=>c.trim()),o=r.length>1?r.length-1:-1,s=o!==-1&&(r[o]==="index"||r[o]?.startsWith("#"))?r[o]:"";s&&r.splice(o,1);let i=n[3];if(!i||r.length===0)return;let a=/[{[]/.test(e);return{list:i,createContext:(c,f)=>{let p={},l=V(c);if(!a&&r.length===1)p[r[0]]=c;else if(T(l)){let u=0;for(let y of r)p[y]=l[u++]}else for(let u of r)p[u]=l[u];let b={ctx:p,index:z(-1)};return s&&(b.index=p[s.startsWith("#")?s.substring(1):s]=z(f)),b}}}};var ao=(t,e)=>{for(let n of t){let r=n.cloneNode(!0);e.appendChild(r)}},bt=class{p;D;ue;constructor(e){this.p=e,this.D=e.o.l.is,this.ue=He(this.D)+", [is]"}N(e){let n=e.hasAttribute(this.D),r=de(e,this.ue);for(let o of r)this.x(o);return n}x(e){let n=e.getAttribute(this.D);if(!n){if(n=e.getAttribute("is"),!n||!n.startsWith("regor:"))return;n=`'${n.slice(6)}'`,e.removeAttribute("is")}e.removeAttribute(this.D),this.V(e,n)}B(e,n){let r=Ue(e),o=e.parentNode,s=document.createComment(`__begin__ dynamic ${n??""}`);o.insertBefore(s,e),Ie(s,r),r.forEach(a=>{P(a)}),e.remove();let i=document.createComment(`__end__ dynamic ${n??""}`);return o.insertBefore(i,s.nextSibling),{nodes:r,parent:o,commentBegin:s,commentEnd:i}}V(e,n){let{nodes:r,parent:o,commentBegin:s,commentEnd:i}=this.B(e,` => ${n} `),a=this.p.h.v(n),c=a.value,f=this.p.h,p=f.k(),l={name:""},b=ne(e)?r:[...r[0].childNodes],u=()=>{f.C(p,()=>{let h=c()[0];if(w(h)&&(h.name?h=h.name:h=Object.entries(f.me()).filter(O=>O[1]===h)[0]?.[0]),!H(h)||$(h)){ae(s,i);return}if(l.name===h)return;ae(s,i);let A=document.createElement(h);for(let O of e.getAttributeNames())O!==this.D&&A.setAttribute(O,e.getAttribute(O));ao(b,A),o.insertBefore(A,i),this.p.G(A),l.name=h})},y=[];k(s,()=>{a.stop();for(let h of y)h();y.length=0}),u();let S=C(c,u);y.push(S)}};var Bn={collectRefObj:!0,onBind:(t,e)=>C(e.value,()=>{let r=e.value(),o=e.context,s=r[0];if(w(s))for(let i of Object.entries(s)){let a=i[0],c=i[1],f=o[a];f!==c&&(m(f)?f(c):o[a]=c)}},!0)};var Vn={collectRefObj:!0,once:!0,onBind:(t,e)=>{let n=e.value(),r=e.context,o=n[0];if(!w(o))return()=>{};for(let s of Object.entries(o)){let i=s[0],a=s[1],c=r[i];c!==a&&(m(c)?c(a):r[i]=a)}return()=>{}}};var ge=t=>{st(t)?.onUnmounted?.forEach(n=>{n()}),t.unmounted?.()};var Pe=class{props;start;end;ctx;autoProps=!0;entangle=!0;disableSwitch=!1;onAutoPropsAssigned;de;constructor(e,n,r,o,s){this.props=e,this.de=n,this.ctx=r,this.start=o,this.end=s}emit=(e,n)=>{this.de.dispatchEvent(new CustomEvent(e,{detail:n}))};unmount(){let e=this.start.nextSibling,n=this.end;for(;e&&e!==n;)P(e),e=e.nextSibling;ge(this)}};var en=Symbol("scope"),Tt=t=>{try{Rn();let e=t();zt(e);let n={context:e,unmount:()=>ge(e),[en]:1};return n[en]=1,n}finally{Sn()}},Pn=t=>w(t)?en in t:!1;var Et=(t,e)=>{if(t===e)return()=>{};let n=C(t,o=>e(o)),r=C(e,o=>t(o));return e(t()),()=>{n(),r()}};var vt=t=>{st(t)?.onMounted?.forEach(n=>{n()}),t.mounted?.()};var jn={collectRefObj:!0,onBind:(t,e,n,r,o,s)=>{if(!r)return()=>{};let i=B(r);return C(e.value,()=>{let c=e.refs[0]??e.value()[0],f=e.context,p=f[r];p!==c&&(m(p)?p(c):f[i]=c)},!0)}};var xt=class{p;ye;constructor(e){this.p=e,this.ye=e.o.l.inherit}N(e){this.Ye(e)}Ye(e){let n=this.p,r=n.h,o=n.o.he,s=n.o.ge,i=r.me(),a=[...o.keys(),...Object.keys(i),...[...o.keys()].map(_e),...[...Object.keys(i)].map(_e)].join(",");if($(a))return;let c=e.querySelectorAll(a),f=e.matches?.(a)?[e,...c]:c;for(let p of f){if(p.hasAttribute(n.T))continue;let l=p.parentNode;if(!l)continue;let b=p.nextSibling,u=B(p.tagName).toUpperCase(),v=i[u]??s.get(u);if(!v)continue;let S=v.template;if(!S)continue;let h=p.parentElement;if(!h)continue;let A=new Comment(" begin component: "+p.tagName),O=new Comment(" end component: "+p.tagName);h.insertBefore(A,p),p.remove();let Ee=n.o.l.props,We=n.o.l.propsOnce,Vt=n.o.l.bind,nt=(d,M)=>{let g={},D=d.hasAttribute(Ee),W=d.hasAttribute(We);return r.C(M,()=>{r.w(g),D&&n.x(Bn,d,Ee),W&&n.x(Vn,d,We);let E=v.props;if(!E||E.length===0)return;E=E.map(B);for(let xe of E.concat(E.map(_e))){let se=d.getAttribute(xe);se!==null&&(g[B(xe)]=se,d.removeAttribute(xe))}let j=n.ee.be(d,!1);for(let[xe,se]of j.entries()){let[Ce,Pt]=se.te;Pt&&E.includes(B(Pt))&&(Ce!=="."&&Ce!==":"&&Ce!==Vt||n.x(jn,d,xe,!0,Pt,se.ne))}}),g},ve=[...r.k()],rt=()=>{let d=nt(p,ve),M=new Pe(d,p,ve,A,O),g=Tt(()=>v.context(M)??{}).context;if(M.autoProps){for(let[D,W]of Object.entries(d))if(D in g){let E=g[D];if(E===W)continue;M.entangle&&m(E)&&m(W)?k(A,Et(W,E)):m(E)?E(W):g[D]=V(W)}else g[D]=W;M.onAutoPropsAssigned?.()}return{componentCtx:g,head:M}},{componentCtx:le,head:Ge}=rt(),oe=[...ce(S)],L=oe.length,x=p.childNodes.length===0,N=d=>{let M=d.parentElement;if(x){for(let E of[...d.childNodes])M.insertBefore(E,d);return}let g=d.name;$(g)&&(g=d.getAttributeNames().filter(E=>E.startsWith("#"))[0],$(g)?g="default":g=g.substring(1));let D=p.querySelector(`template[name='${g}'], template[\\#${g}]`);!D&&g==="default"&&(D=p.querySelector("template:not([name])"),D&&D.getAttributeNames().filter(E=>E.startsWith("#")).length>0&&(D=null));let W=E=>{Ge.disableSwitch||r.C(ve,()=>{r.w(le);let j=nt(d,r.k());r.C(ve,()=>{r.w(j);let xe=r.k(),se=On(xe);for(let Ce of E)Se(Ce)&&(Ce.setAttribute(Xe,se),Kt(se),k(Ce,()=>{Wt(se)}))})})};if(D){let E=[...ce(D)];for(let j of E)M.insertBefore(j,d);W(E)}else{if(g!=="default"){for(let j of[...ce(d)])M.insertBefore(j,d);return}let E=[...ce(p)].filter(j=>!ne(j));for(let j of E)M.insertBefore(j,d);W(E)}},q=d=>{if(!Se(d))return;let M=d.querySelectorAll("slot");if(kn(d)){N(d),d.remove();return}for(let g of M)N(g),g.remove()};(()=>{for(let d=0;d<L;++d)oe[d]=oe[d].cloneNode(!0),l.insertBefore(oe[d],b),q(oe[d])})(),h.insertBefore(O,b);let Q=()=>{if(!v.inheritAttrs)return;let d=oe.filter(g=>g.nodeType===Node.ELEMENT_NODE);d.length>1&&(d=d.filter(g=>g.hasAttribute(this.ye)));let M=d[0];if(M)for(let g of p.getAttributeNames()){if(g===Ee||g===We)continue;let D=p.getAttribute(g);if(g==="class")M.classList.add(...D.split(" "));else if(g==="style"){let W=M.style,E=p.style;for(let j of E)W.setProperty(j,E.getPropertyValue(j))}else M.setAttribute(lt(g,n.o),D)}},ee=()=>{for(let d of p.getAttributeNames())!d.startsWith("@")&&!d.startsWith(n.o.l.on)&&p.removeAttribute(d)},Le=()=>{Q(),ee(),r.w(le),n.Te(p,!1),le.$emit=Ge.emit,ye(n,oe),k(p,()=>{ge(le)}),k(A,()=>{te(p)}),vt(le)};r.C(ve,Le)}}};var tn=class{xe;te=[];ne=[];Ee=[];constructor(e){this.xe=e,this.v()}v(){let e=this.xe,n=e.startsWith(".");n&&(e=":"+e.slice(1));let r=e.indexOf("."),o=this.te=(r<0?e:e.substring(0,r)).split(/[:@]/);if($(o[0])&&(o[0]=n?".":e[0]),r>=0){let s=this.ne=e.slice(r+1).split(".");if(s.includes("camel")){let i=o.length-1;o[i]=B(o[i])}s.includes("prop")&&(o[0]=".")}}},Ct=class{p;Re;constructor(e){this.p=e,this.Re=e.o.Ze()}be(e,n){let r=new Map;if(!Ye(e))return r;let o=this.Re,s=a=>{let c=a.getAttributeNames().filter(f=>o.some(p=>f.startsWith(p)));for(let f of c)r.has(f)||r.set(f,new tn(f)),r.get(f).Ee.push(a)};if(s(e),!n)return r;let i=e.querySelectorAll("*");for(let a of i)s(a);return r}};var Rt={};var St=class{h;ve;Ce;Se;we;ee;o;T;Ae;constructor(e){this.h=e,this.o=e.o,this.Ce=new gt(this),this.ve=new ft(this),this.Se=new bt(this),this.we=new xt(this),this.ee=new Ct(this),this.T=this.o.l.pre,this.Ae=this.o.l.dynamic}et(e){let n=ne(e)?[e]:e.querySelectorAll("template");for(let r of n){if(r.hasAttribute(this.T))continue;let o=r.parentNode;if(!o)continue;let s=r.nextSibling;if(r.remove(),!r.content)continue;let i=[...r.content.childNodes];for(let a of i)o.insertBefore(a,s);ye(this,i)}}G(e){e.nodeType!==Node.ELEMENT_NODE||e.hasAttribute(this.T)||this.ve.N(e)||this.Ce.N(e)||this.Se.N(e)||(this.we.N(e),this.et(e),this.Te(e,!0))}Te(e,n){let r=this.ee.be(e,n),o=this.o.H;for(let[s,i]of r.entries()){let[a,c]=i.te,f=o[s]??o[a];if(!f){console.error("directive not found:",a);continue}i.Ee.forEach(p=>{this.x(f,p,s,!1,c,i.ne)})}}x(e,n,r,o,s,i){if(n.hasAttribute(this.T))return;let a=n.getAttribute(r);n.removeAttribute(r);let c=f=>{let p=f.getAttribute(Xe);return p||(f.parentElement?c(f.parentElement):null)};if(Gt()){let f=c(n);if(f){this.h.C(Nn(f),()=>{this.V(e,n,a,s,i)});return}}this.V(e,n,a,s,i)}tt(e,n,r){if(e!==Rt)return!1;if($(r))return!0;let o=document.querySelector(r);if(o){let s=n.parentElement;if(!s)return!0;let i=new Comment(`teleported => '${r}'`);s.insertBefore(i,n),n.teleportedFrom=i,i.teleportedTo=n,k(i,()=>{P(n)}),o.appendChild(n)}return!0}V(e,n,r,o,s){if(n.nodeType!==Node.ELEMENT_NODE||r==null||this.tt(e,n,r))return;let i=this.h.v(r,e.isLazy,e.isLazyKey,e.collectRefObj,e.once),a=[];k(n,()=>{i.stop(),p?.stop();for(let S of a)S();a.length=0});let f=In(o,this.Ae),p;f&&(p=this.h.v(B(f),void 0,void 0,void 0,e.once));let l,b=()=>(l=i.value(),l),u,y=()=>p?(u=p.value()[0],u):(u=o,o),v=()=>{if(!e.onChange)return;let S=C(i.value,h=>{let A=l,O=u;e.onChange?.(n,b(),A,y(),O,s)});if(a.push(S),p){let h=C(p.value,A=>{let O=u;e.onChange?.(n,b(),O,y(),O,s)});a.push(h)}};e.once||v(),e.onBind&&a.push(e.onBind(n,i,r,o,p,s)),e.onChange?.(n,b(),void 0,y(),void 0,s)}};var co=9,po=10,fo=13,lo=32,be=46,wt=44,uo=39,mo=34,At=40,je=41,Ot=91,Nt=93,nn=63,yo=59,$n=58,ho=123,Mt=125,on=43,go=45,Fn=96,qn=47,bo=92,zn=[2,3],Kn=[on,go],Yn={"-":1,"!":1,"~":1,"+":1,new:1},Zn={"=":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},Fe={"=>":2,...Zn,"||":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},er=Object.keys(Zn),To=new Set(er),Lt=new Set;Lt.add("=>");er.forEach(t=>Lt.add(t));var Eo=new Set(["$","_"]),Wn={true:!0,false:!1,null:null},vo="this";function tr(t){return Math.max(0,...Object.keys(t).map(e=>e.length))}var xo=tr(Yn),Co=tr(Fe),qe="Expected ",Oe="Unexpected ",an="Unclosed ",Ro=qe+":",Gn=qe+"expression",So="missing }",wo=Oe+"object property",Ao=an+"(",Jn=qe+"comma",Qn=Oe+"token ",Oo=Oe+"period",rn=qe+"expression after ",No="missing unaryOp argument",Mo=an+"[",Lo=qe+"exponent (",ko="Variable names cannot start with a number (",Io=an+'quote after "';var $e=t=>t>=48&&t<=57,Xn=t=>Fe[t]||0,sn=class{nt={0:[this.rt],1:[this.ot,this.st,this.it],2:[this.at,this.pt,this.ct,this.Oe,this.lt],3:[this.ft,this.ut,this.mt]};r;e;get M(){return this.r.charAt(this.e)}get f(){return this.r.charCodeAt(this.e)}u(e){return this.r.charCodeAt(this.e)===e}constructor(e){this.r=e,this.e=0}U(e){let n=String.fromCharCode(e);return e>=65&&e<=90||e>=97&&e<=122||e>=128&&!(n in Fe)||Eo.has(n)}re(e){return this.U(e)||$e(e)}i(e){return new Error(`${e} at character ${this.e}`)}L(e,n,r){let o=this.nt[e];if(!o)return r;let s={node:r},i=a=>{a.call(this,s)};return n===0?o.forEach(i):o.find(i),s.node}y(){let e=this.f,n=this.r,r=this.e;for(;e===lo||e===co||e===po||e===fo;)e=n.charCodeAt(++r);this.e=r}parse(){let e=this.oe();return e.length===1?e[0]:{type:0,body:e}}oe(e){let n=[];for(;this.e<this.r.length;){let r=this.f;if(r===yo||r===wt)this.e++;else{let o=this.A();if(o)n.push(o);else if(this.e<this.r.length){if(r===e)break;throw this.i(Oe+'"'+this.M+'"')}}}return n}A(){let e=this.L(0,1)??this.Ne();return this.y(),this.L(1,0,e)}se(){this.y();let e=this.e,n=this.r,r=n.substr(e,Co),o=r.length;for(;o>0;){if(r in Fe&&(!this.U(this.f)||e+r.length<n.length&&!this.re(n.charCodeAt(e+r.length))))return e+=o,this.e=e,r;r=r.substr(0,--o)}return!1}Ne(){let e,n,r,o,s,i,a,c;if(s=this.j(),!s||(n=this.se(),!n))return s;if(o={value:n,prec:Xn(n),right_a:Lt.has(n)},i=this.j(),!i)throw this.i(rn+n);let f=[s,o,i];for(;n=this.se();){if(r=Xn(n),r===0){this.e-=n.length;break}o={value:n,prec:r,right_a:Lt.has(n)},c=n;let p=l=>o.right_a&&l.right_a?r>l.prec:r<=l.prec;for(;f.length>2&&p(f[f.length-2]);)i=f.pop(),n=f.pop().value,s=f.pop(),e={type:8,operator:n,left:s,right:i},f.push(e);if(e=this.j(),!e)throw this.i(rn+c);f.push(o,e)}for(a=f.length-1,e=f[a];a>1;)e={type:8,operator:f[a-1].value,left:f[a-2],right:e},a-=2;return e}j(){let e,n,r;if(this.y(),r=this.L(2,1),r)return this.L(3,0,r);let o=this.f;if($e(o)||o===be)return this.dt();if(o===uo||o===mo)r=this.yt();else if(o===Ot)r=this.ht();else{for(e=this.r.substr(this.e,xo),n=e.length;n>0;){if(Object.prototype.hasOwnProperty.call(Yn,e)&&(!this.U(this.f)||this.e+e.length<this.r.length&&!this.re(this.r.charCodeAt(this.e+e.length)))){this.e+=n;let s=this.j();if(!s)throw this.i(No);return this.L(3,0,{type:7,operator:e,argument:s})}e=e.substr(0,--n)}this.U(o)?(r=this.ie(),r.name in Wn?r={type:4,value:Wn[r.name],raw:r.name}:r.name===vo&&(r={type:5})):o===At&&(r=this.gt())}return r?(r=this.F(r),this.L(3,0,r)):this.L(3,0,!1)}F(e){this.y();let n=this.f;for(;n===be||n===Ot||n===At||n===nn;){let r;if(n===nn){if(this.r.charCodeAt(this.e+1)!==be)break;r=!0,this.e+=2,this.y(),n=this.f}if(this.e++,n===Ot){if(e={type:3,computed:!0,object:e,property:this.A()},this.y(),n=this.f,n!==Nt)throw this.i(Mo);this.e++}else n===At?e={type:6,arguments:this.Me(je),callee:e}:(n===be||r)&&(r&&this.e--,this.y(),e={type:3,computed:!1,object:e,property:this.ie()});r&&(e.optional=!0),this.y(),n=this.f}return e}dt(){let e="",n;for(;$e(this.f);)e+=this.r.charAt(this.e++);if(this.u(be))for(e+=this.r.charAt(this.e++);$e(this.f);)e+=this.r.charAt(this.e++);if(n=this.M,n==="e"||n==="E"){for(e+=this.r.charAt(this.e++),n=this.M,(n==="+"||n==="-")&&(e+=this.r.charAt(this.e++));$e(this.f);)e+=this.r.charAt(this.e++);if(!$e(this.r.charCodeAt(this.e-1)))throw this.i(Lo+e+this.M+")")}let r=this.f;if(this.U(r))throw this.i(ko+e+this.M+")");if(r===be||e.length===1&&e.charCodeAt(0)===be)throw this.i(Oo);return{type:4,value:parseFloat(e),raw:e}}yt(){let e="",n=this.e,r=this.r.charAt(this.e++),o=!1;for(;this.e<this.r.length;){let s=this.r.charAt(this.e++);if(s===r){o=!0;break}else if(s==="\\")switch(s=this.r.charAt(this.e++),s){case"n":e+=`
2
2
  `;break;case"r":e+="\r";break;case"t":e+=" ";break;case"b":e+="\b";break;case"f":e+="\f";break;case"v":e+="\v";break;default:e+=s}else e+=s}if(!o)throw this.i(Io+e+'"');return{type:4,value:e,raw:this.r.substring(n,this.e)}}ie(){let e=this.f,n=this.e;if(this.U(e))this.e++;else throw this.i(Oe+this.M);for(;this.e<this.r.length&&(e=this.f,this.re(e));)this.e++;return{type:2,name:this.r.slice(n,this.e)}}Me(e){let n=[],r=!1,o=0;for(;this.e<this.r.length;){this.y();let s=this.f;if(s===e){if(r=!0,this.e++,e===je&&o&&o>=n.length)throw this.i(Qn+String.fromCharCode(e));break}else if(s===wt){if(this.e++,o++,o!==n.length){if(e===je)throw this.i(Qn+",");if(e===Nt)for(let i=n.length;i<o;i++)n.push(null)}}else{if(n.length!==o&&o!==0)throw this.i(Jn);{let i=this.A();if(!i||i.type===0)throw this.i(Jn);n.push(i)}}}if(!r)throw this.i(qe+String.fromCharCode(e));return n}gt(){this.e++;let e=this.oe(je);if(this.u(je))return this.e++,e.length===1?e[0]:e.length?{type:1,expressions:e}:!1;throw this.i(Ao)}ht(){return this.e++,{type:9,elements:this.Me(Nt)}}at(e){if(this.u(ho)){this.e++;let n=[];for(;!isNaN(this.f);){if(this.y(),this.u(Mt)){this.e++,e.node=this.F({type:10,properties:n});return}let r=this.A();if(!r)break;if(this.y(),r.type===2&&(this.u(wt)||this.u(Mt)))n.push({type:12,computed:!1,key:r,value:r,shorthand:!0});else if(this.u($n)){this.e++;let o=this.A();if(!o)throw this.i(wo);let s=r.type===9;n.push({type:12,computed:s,key:s?r.elements[0]:r,value:o,shorthand:!1}),this.y()}else r&&n.push(r);this.u(wt)&&this.e++}throw this.i(So)}}pt(e){let n=this.f;if(Kn.some(r=>r===n&&r===this.r.charCodeAt(this.e+1))){this.e+=2;let r=e.node={type:13,operator:n===on?"++":"--",argument:this.F(this.ie()),prefix:!0};if(!r.argument||!zn.includes(r.argument.type))throw this.i(Oe+r.operator)}}ut(e){if(e.node){let n=this.f;if(Kn.some(r=>r===n&&r===this.r.charCodeAt(this.e+1))){if(!zn.includes(e.node.type))throw this.i(Oe+e.node.operator);this.e+=2,e.node={type:13,operator:n===on?"++":"--",argument:e.node,prefix:!1}}}}ct(e){[0,1,2].every(n=>this.r.charCodeAt(this.e+n)===be)&&(this.e+=3,e.node={type:14,argument:this.A()})}it(e){if(e.node&&this.u(nn)){this.e++;let n=e.node,r=this.A();if(!r)throw this.i(Gn);if(this.y(),this.u($n)){this.e++;let o=this.A();if(!o)throw this.i(Gn);if(e.node={type:11,test:n,consequent:r,alternate:o},n.operator&&Fe[n.operator]<=.9){let s=n;for(;s.right.operator&&Fe[s.right.operator]<=.9;)s=s.right;e.node.test=s.right,s.right=e.node,e.node=n}}else throw this.i(Ro)}}rt(e){if(this.y(),this.u(At)){let n=this.e;if(this.e++,this.y(),this.u(je)){this.e++;let r=this.se();if(r==="=>"){let o=this.Ne();if(!o)throw this.i(rn+r);e.node={type:15,params:null,body:o};return}}this.e=n}}ot(e){this.Le(e.node)}Le(e){e&&(Object.values(e).forEach(n=>{n&&typeof n=="object"&&this.Le(n)}),e.operator==="=>"&&(e.type=15,e.params=e.left?[e.left]:null,e.body=e.right,e.params&&e.params[0].type===1&&(e.params=e.params[0].expressions),delete e.left,delete e.right,delete e.operator))}st(e){e.node&&this.$(e.node)}$(e){To.has(e.operator)?(e.type=16,this.$(e.left),this.$(e.right)):e.operator||Object.values(e).forEach(n=>{n&&typeof n=="object"&&this.$(n)})}mt(e){if(!e.node)return;let n=e.node.type;(n===2||n===3)&&this.u(Fn)&&(e.node={type:17,tag:e.node,quasi:this.Oe(e)})}Oe(e){if(!this.u(Fn))return;let n={type:19,quasis:[],expressions:[]},r="",o="",s=!1,i=this.r.length,a=()=>n.quasis.push({type:18,value:{raw:o,cooked:r},tail:s});for(;this.e<i;){let c=this.r.charAt(++this.e);if(c==="`")return this.e+=1,s=!0,a(),e.node=n,n;if(c==="$"&&this.r.charAt(this.e+1)==="{"){if(this.e+=2,a(),o="",r="",n.expressions.push(...this.oe(Mt)),!this.u(Mt))throw this.i("unclosed ${")}else if(c==="\\")switch(o+=c,c=this.r.charAt(++this.e),o+=c,c){case"n":r+=`
3
- `;break;case"r":r+="\r";break;case"t":r+=" ";break;case"b":r+="\b";break;case"f":r+="\f";break;case"v":r+="\v";break;default:r+=c}else r+=c,o+=c}throw this.i("Unclosed `")}ft(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 r=e.node;for(;r.type===3||r.type===6&&r?.callee?.type===3;)r=r.type===3?r.object:r.callee.object;r.type=20}lt(e){if(!this.u(qn))return;let n=++this.e,r=!1;for(;this.e<this.r.length;){if(this.f===qn&&!r){let o=this.r.slice(n,this.e),s="";for(;++this.e<this.r.length;){let a=this.f;if(a>=97&&a<=122||a>=65&&a<=90||a>=48&&a<=57)s+=this.M;else break}let i;try{i=new RegExp(o,s)}catch(a){throw this.i(a.message)}return e.node={type:4,value:i,raw:this.r.slice(n-1,this.e)},e.node=this.F(e.node),e.node}this.u(Ot)?r=!0:r&&this.u(Nt)&&(r=!1),this.e+=this.u(bo)?2:1}throw this.i("Unclosed Regex")}},nr=t=>new sn(t).parse();var Do={"=>":(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,"&":(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},Uo={"-":t=>-t,"+":t=>+t,"!":t=>!t,"~":t=>~t,new:t=>t},ir=t=>{if(!t?.some(sr))return t;let e=[];return t.forEach(n=>sr(n)?e.push(...n):e.push(n)),e},rr=(...t)=>ir(t),cn=(t,e)=>{if(!t)return e;let n=Object.create(e??{});return n.$event=t,n},Ho={"++":(t,e)=>{let n=t[e];if(m(n)){let r=n();return n(++r),r}return++t[e]},"--":(t,e)=>{let n=t[e];if(m(n)){let r=n();return n(--r),r}return--t[e]}},_o={"++":(t,e)=>{let n=t[e];if(m(n)){let r=n();return n(r+1),r}return t[e]++},"--":(t,e)=>{let n=t[e];if(m(n)){let r=n();return n(r-1),r}return t[e]--}},or={"=":(t,e,n)=>{let r=t[e];return m(r)?r(n):t[e]=n},"+=":(t,e,n)=>{let r=t[e];return m(r)?r(r()+n):t[e]+=n},"-=":(t,e,n)=>{let r=t[e];return m(r)?r(r()-n):t[e]-=n},"*=":(t,e,n)=>{let r=t[e];return m(r)?r(r()*n):t[e]*=n},"/=":(t,e,n)=>{let r=t[e];return m(r)?r(r()/n):t[e]/=n},"%=":(t,e,n)=>{let r=t[e];return m(r)?r(r()%n):t[e]%=n},"**=":(t,e,n)=>{let r=t[e];return m(r)?r(r()**n):t[e]**=n},"<<=":(t,e,n)=>{let r=t[e];return m(r)?r(r()<<n):t[e]<<=n},">>=":(t,e,n)=>{let r=t[e];return m(r)?r(r()>>n):t[e]>>=n},">>>=":(t,e,n)=>{let r=t[e];return m(r)?r(r()>>>n):t[e]>>>=n},"|=":(t,e,n)=>{let r=t[e];return m(r)?r(r()|n):t[e]|=n},"&=":(t,e,n)=>{let r=t[e];return m(r)?r(r()&n):t[e]&=n},"^=":(t,e,n)=>{let r=t[e];return m(r)?r(r()^n):t[e]^=n}},kt=(t,e)=>U(t)?t.bind(e):t,pn=class{m;ke;Ve;Ie;O;De;Ue;constructor(e,n,r,o,s){this.m=T(e)?e:[e],this.ke=n,this.Ve=r,this.Ie=o,this.Ue=!!s}Pe(e,n){if(n&&e in n)return n;for(let r of this.m)if(e in r)return r}2(e,n,r){let o=e.name;if(o==="$root")return this.m[this.m.length-1];if(o==="$parent")return this.m[1];if(o==="$ctx")return[...this.m];if(r&&o in r)return this.O=r[o],kt(V(r[o]),r);for(let i of this.m)if(o in i)return this.O=i[o],kt(V(i[o]),i);let s=this.ke;if(s&&o in s)return this.O=s[o],kt(V(s[o]),s)}5(e,n,r){return this.m[0]}0(e,n,r){return this.Be(n,r,rr,...e.body)}1(e,n,r){return this.R(n,r,(...o)=>o.pop(),...e.expressions)}3(e,n,r){let{obj:o,key:s}=this.ae(e,n,r),i=o?.[s];return this.O=i,kt(V(i),o)}4(e,n,r){return e.value}6(e,n,r){let o=(i,...a)=>U(i)?i(...ir(a)):i,s=this.R(++n,r,o,e.callee,...e.arguments);return this.O=s,s}7(e,n,r){return this.R(n,r,Uo[e.operator],e.argument)}8(e,n,r){let o=Do[e.operator];switch(e.operator){case"||":case"&&":case"??":return o(()=>this.g(e.left,n,r),()=>this.g(e.right,n,r))}return this.R(n,r,o,e.left,e.right)}9(e,n,r){return this.Be(++n,r,rr,...e.elements)}10(e,n,r){let o={},s=(...i)=>{i.forEach(a=>{Object.assign(o,a)})};return this.R(++n,r,s,...e.properties),o}11(e,n,r){return this.R(n,r,o=>this.g(o?e.consequent:e.alternate,n,r),e.test)}12(e,n,r){let o={},s=p=>p?.type!==15,i=this.Ie??(()=>!1),a=n===0&&this.Ue,c=p=>this._e(a,e.key,n,cn(p,r)),f=p=>this._e(a,e.value,n,cn(p,r));if(e.shorthand){let p=e.key.name;o[p]=s(e.key)&&i(p,n)?c:c()}else if(e.computed){let p=V(c());o[p]=s(e.value)&&i(p,n)?f:f()}else{let p=e.key.type===4?e.key.value:e.key.name;o[p]=s(e.value)&&i(p,n)?()=>f:f()}return o}ae(e,n,r){let o=this.g(e.object,n,r),s=e.computed?this.g(e.property,n,r):e.property.name;return{obj:o,key:s}}13(e,n,r){let o=e.argument,s=e.operator,i=e.prefix?Ho:_o;if(o.type===2){let a=o.name,c=this.Pe(a,r);return Y(c)?void 0:i[s](c,a)}if(o.type===3){let{obj:a,key:c}=this.ae(o,n,r);return i[s](a,c)}}16(e,n,r){let o=e.left,s=e.operator;if(o.type===2){let i=o.name,a=this.Pe(i,r);if(Y(a))return;let c=this.g(e.right,n,r);return or[s](a,i,c)}if(o.type===3){let{obj:i,key:a}=this.ae(o,n,r),c=this.g(e.right,n,r);return or[s](i,a,c)}}14(e,n,r){let o=this.g(e.argument,n,r);return T(o)&&(o.s=ar),o}17(e,n,r){return this[6]({type:6,callee:e.tag,arguments:[{type:9,elements:e.quasi.quasis},...e.quasi.expressions]},n,r)}19(e,n,r){let o=(...s)=>s.reduce((i,a,c)=>i+=a+e.quasis[c+1].value.cooked,e.quasis[0].value.cooked);return this.R(n,r,o,...e.expressions)}18(e,n,r){return e.value.cooked}20(e,n,r){let o=(s,...i)=>new s(...i);return this.R(n,r,o,e.callee,...e.arguments)}15(e,n,r){return(...o)=>{let s=Object.create(r??{}),i=e.params;if(i){let a=0;for(let c of i)s[c.name]=o[a++]}return this.g(e.body,n,s)}}g(e,n,r){let o=V(this[e.type](e,n,r));return this.De=e.type,o}_e(e,n,r,o){let s=this.g(n,r,o);return e&&this.He()?this.O:s}He(){let e=this.De;return(e===2||e===3||e===6)&&m(this.O)}eval(e,n){let{value:r,refs:o}=mt(()=>this.g(e,-1,n)),s={value:r,refs:o};return this.He()&&(s.ref=this.O),s}R(e,n,r,...o){let s=o.map(i=>i&&this.g(i,e,n));return r(...s)}Be(e,n,r,...o){let s=this.Ve;if(!s)return this.R(e,n,r,...o);let i=o.map((a,c)=>a&&(a.type!==15&&s(c,e)?f=>this.g(a,e,cn(f,n)):this.g(a,e,n)));return r(...i)}},ar=Symbol("s"),sr=t=>t?.s===ar,cr=(t,e,n,r,o,s,i)=>new pn(e,n,r,o,i).eval(t,s);var pr={},It=class{m;o;constructor(e,n){this.m=e,this.o=n}w(e){this.m=[e,...this.m]}me(){return this.m.map(n=>n.components).filter(n=>!!n).reverse().reduce((n,r)=>{for(let[o,s]of Object.entries(r))n[o.toUpperCase()]=s;return n},{})}v(e,n,r,o,s){let i=z([]),a=[],c=()=>{for(let u of a)u();a.length=0},f={value:i,stop:c,refs:[],context:this.m[0]};if($(e))return f;let p=this.o.globalContext,l=[],b=(u,y,v,S)=>{try{let h=cr(u,y,p,n,r,S,o);return v&&l.push(...h.refs),{value:h.value,refs:h.refs,ref:h.ref}}catch(h){I(6,`evaluation error: ${e}`,h)}return{value:void 0,refs:[]}};try{let u=pr[e]??nr("["+e+"]");pr[e]=u;let y=this.m,v=()=>{l.splice(0),c();let S=u.elements.map((h,A)=>n?.(A,-1)?{value:O=>b(h,y,!1,{$event:O}).value,refs:[]}:b(h,y,!0));if(!s)for(let h of l){let A=C(h,v);a.push(A)}i(S.map(h=>h.value)),f.refs=S.map(h=>h.ref)};v()}catch(u){I(6,`parse error: ${e}`,u)}return f}V(){return this.m}je=[];Y(e){this.je.push(this.m),this.m=e}C(e,n){try{this.Y(e),n()}finally{this.bt()}}bt(){this.m=this.je.pop()??[]}};var fr="http://www.w3.org/1999/xlink",Bo={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 Vo(t){return!!t||t===""}var fn={onChange:(t,e,n,r,o,s)=>{if(r){s&&s.includes("camel")&&(r=B(r)),Dt(t,r,e[0],o);return}let i=e.length;for(let a=0;a<i;++a){let c=e[a];if(T(c)){let f=n?.[a]?.[0],p=c[0],l=c[1];Dt(t,p,l,f)}else if(w(c))for(let f of Object.entries(c)){let p=f[0],l=f[1],b=n?.[a],u=b&&p in b?p:void 0;Dt(t,p,l,u)}else{let f=n?.[a],p=e[a++],l=e[a];Dt(t,p,l,f)}}}},Dt=(t,e,n,r)=>{if(r&&r!==e&&t.removeAttribute(r),Y(e)){I(3,name,t);return}if(!H(e)){I(6,`Attribute key is not string at ${t.outerHTML}`,e);return}if(e.startsWith("xlink:")){Y(n)?t.removeAttributeNS(fr,e.slice(6,e.length)):t.setAttributeNS(fr,e,n);return}let o=e in Bo;Y(n)||o&&!Vo(n)?t.removeAttribute(e):t.setAttribute(e,o?"":n)};var ln={onChange:(t,e,n)=>{let r=e.length;for(let o=0;o<r;++o){let s=e[o],i=n?.[o];if(T(s)){let a=s.length;for(let c=0;c<a;++c)lr(t,s[c],i?.[c])}else lr(t,s,i)}}},lr=(t,e,n)=>{let r=t.classList,o=H(e),s=H(n);if(e&&!o){if(n&&!s)for(let i in n)i in e||r.remove(i);for(let i in e)e[i]&&r.add(i)}else o?n!==e&&(s&&r.remove(...n?.split(",")),r.add(...e.split(","))):n&&s&&r.remove(...n?.split(","))};var ur={onChange:(t,e)=>{let[n,r]=e;U(r)?r(t,n):t.innerHTML=n?.toString()}};function Po(t,e){if(t.length!==e.length)return!1;let n=!0;for(let r=0;n&&r<t.length;r++)n=pe(t[r],e[r]);return n}function pe(t,e){if(t===e)return!0;let n=Ft(t),r=Ft(e);if(n||r)return n&&r?t.getTime()===e.getTime():!1;if(n=Je(t),r=Je(e),n||r)return t===e;if(n=T(t),r=T(e),n||r)return n&&r?Po(t,e):!1;if(n=w(t),r=w(e),n||r){if(!n||!r)return!1;let o=Object.keys(t).length,s=Object.keys(e).length;if(o!==s)return!1;for(let i in t){let a=t.hasOwnProperty(i),c=e.hasOwnProperty(i);if(a&&!c||!a&&c||!pe(t[i],e[i]))return!1}}return String(t)===String(e)}function Ut(t,e){return t.findIndex(n=>pe(n,e))}var mr=t=>{let e=parseFloat(t);return isNaN(e)?t:e};var Ht=t=>{if(!m(t))throw _(3,"pause");t(void 0,void 0,3)};var _t=t=>{if(!m(t))throw _(3,"resume");t(void 0,void 0,4)};var yr={onChange:(t,e)=>{jo(t,e[0])},onBind:(t,e,n,r,o,s)=>$o(t,e,s)},jo=(t,e)=>{let n=Tr(t);if(n&&hr(t))T(e)?e=Ut(e,fe(t))>-1:X(e)?e=e.has(fe(t)):e=Go(t,e),t.checked=e;else if(n&&gr(t))t.checked=pe(e,fe(t));else if(n||Er(t))br(t)?t.value!==e?.toString()&&(t.value=e):t.value!==e&&(t.value=e);else if(vr(t)){let r=t.options,o=r.length,s=t.multiple;for(let i=0;i<o;i++){let a=r[i],c=fe(a);if(s)T(e)?a.selected=Ut(e,c)>-1:a.selected=e.has(c);else if(pe(fe(a),e)){t.selectedIndex!==i&&(t.selectedIndex=i);return}}!s&&t.selectedIndex!==-1&&(t.selectedIndex=-1)}else I(7,t)},tt=t=>(m(t)&&(t=t()),U(t)&&(t=t()),t?H(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}),hr=t=>t.type==="checkbox",gr=t=>t.type==="radio",br=t=>t.type==="number"||t.type==="range",Tr=t=>t.tagName==="INPUT",Er=t=>t.tagName==="TEXTAREA",vr=t=>t.tagName==="SELECT",$o=(t,e,n)=>{let r=e.value,o=tt(n?.join(",")),s=tt(r()[1]),i={int:o.int||o.int,lazy:o.lazy||s.lazy,number:o.number||s.number,trim:o.trim||s.trim},a=e.refs[0];if(!a)return I(8,t),()=>{};let c=Tr(t);return c&&hr(t)?qo(t,a):c&&gr(t)?Jo(t,a):c||Er(t)?Fo(t,i,a,r):vr(t)?Qo(t,a,r):(I(7,t),()=>{})},dr=/[.,' ·٫]/,Fo=(t,e,n,r)=>{let s=e.lazy?"change":"input",i=br(t),a=()=>{!e.trim&&!tt(r()[1]).trim||(t.value=t.value.trim())},c=b=>{let u=b.target;u.composing=1},f=b=>{let u=b.target;u.composing&&(u.composing=0,u.dispatchEvent(new Event(s)))},p=()=>{t.removeEventListener(s,l),t.removeEventListener("change",a),t.removeEventListener("compositionstart",c),t.removeEventListener("compositionend",f),t.removeEventListener("change",f)},l=b=>{let u=b.target;if(!u||u.composing)return;let y=u.value,v=tt(r()[1]);if(i||v.number||v.int){if(v.int)y=parseInt(y);else{if(dr.test(y[y.length-1])&&y.split(dr).length===2){if(y+="0",y=parseFloat(y),isNaN(y))y="";else if(n()===y)return}y=parseFloat(y)}isNaN(y)&&(y=""),t.value=y}else v.trim&&(y=y.trim());n(y)};return t.addEventListener(s,l),t.addEventListener("change",a),t.addEventListener("compositionstart",c),t.addEventListener("compositionend",f),t.addEventListener("change",f),p},qo=(t,e)=>{let n="change",r=()=>{t.removeEventListener(n,o)},o=()=>{let s=fe(t),i=t.checked,a=e();if(T(a)){let c=Ut(a,s),f=c!==-1;i&&!f?a.push(s):!i&&f&&a.splice(c,1)}else X(a)?i?a.add(s):a.delete(s):e(Wo(t,i))};return t.addEventListener(n,o),r},fe=t=>"_value"in t?t._value:t.value,xr="trueValue",zo="falseValue",Cr="true-value",Ko="false-value",Wo=(t,e)=>{let n=e?xr:zo;if(n in t)return t[n];let r=e?Cr:Ko;return t.hasAttribute(r)?t.getAttribute(r):e},Go=(t,e)=>{if(xr in t)return pe(e,t.trueValue);let r=Cr;return t.hasAttribute(r)?pe(e,t.getAttribute(r)):pe(e,!0)},Jo=(t,e)=>{let n="change",r=()=>{t.removeEventListener(n,o)},o=()=>{let s=fe(t);e(s)};return t.addEventListener(n,o),r},Qo=(t,e,n)=>{let r="change",o=()=>{t.removeEventListener(r,s)},s=()=>{let a=tt(n()[1]).number,c=Array.prototype.filter.call(t.options,f=>f.selected).map(f=>a?mr(fe(f)):fe(f));if(t.multiple){let f=e();try{if(Ht(e),X(f)){f.clear();for(let p of c)f.add(p)}else T(f)?(f.splice(0),f.push(...c)):e(c)}finally{_t(e),F(e)}}else e(c[0])};return t.addEventListener(r,s),o};var Xo=["stop","prevent","capture","self","once","left","right","middle","passive"],Yo=t=>{let e={};if($(t))return;let n=t.split(",");for(let r of Xo)e[r]=n.includes(r);return e},mn={isLazy:(t,e)=>e===-1&&t%2===0,isLazyKey:(t,e)=>e===0&&!t.endsWith("_flags"),once:!1,collectRefObj:!0,onBind:(t,e,n,r,o,s)=>{if(o){let p=e.value(),l=V(o.value()[0]);return H(l)?un(t,B(l),()=>e.value()[0],s?.join(",")??p[1]):()=>{}}else if(r){let p=e.value();return un(t,B(r),()=>e.value()[0],s?.join(",")??p[1])}let i=[],a=()=>{i.forEach(p=>p())},c=e.value(),f=c.length;for(let p=0;p<f;++p){let l=c[p];if(U(l)&&(l=l()),w(l))for(let b of Object.entries(l)){let u=b[0],y=()=>{let S=e.value()[p];return U(S)&&(S=S()),S=S[u],U(S)&&(S=S()),S},v=l[u+"_flags"];i.push(un(t,u,y,v))}else I(2,name,t)}return a}},Zo=(t,e)=>{if(t.startsWith("keydown")||t.startsWith("keyup")||t.startsWith("keypress")){e??="";let n=t.split(".").concat(e.split(","));t=n[0];let r=n[1],o=n.includes("ctrl"),s=n.includes("shift"),i=n.includes("alt"),a=n.includes("meta"),c=f=>!(o&&!f.ctrlKey||s&&!f.shiftKey||i&&!f.altKey||a&&!f.metaKey);return r?[t,f=>c(f)?f.key.toUpperCase()===r.toUpperCase():!1]:[t,c]}return[t,n=>!0]},un=(t,e,n,r)=>{if($(e))return I(5,name,t),()=>{};let o=Yo(r),s=o?{capture:o.capture,passive:o.passive,once:o.once}:void 0,i;[e,i]=Zo(e,r);let a=p=>{if(!i(p)||!n&&e==="submit"&&o?.prevent)return;let l=n(p);U(l)&&(l=l(p)),U(l)&&l(p)},c=()=>{t.removeEventListener(e,f,s)},f=p=>{if(!o){a(p);return}try{if(o.left&&p.button!==1||o.middle&&p.button!==2||o.right&&p.button!==3||o.self&&p.target!==t)return;o.stop&&p.stopPropagation(),o.prevent&&p.preventDefault(),a(p)}finally{o.once&&c()}};return t.addEventListener(e,f,s),c};var Rr={onChange:(t,e,n,r,o,s)=>{if(r){s&&s.includes("camel")&&(r=B(r)),ze(t,r,e[0]);return}let i=e.length;for(let a=0;a<i;++a){let c=e[a];if(T(c)){let f=c[0],p=c[1];ze(t,f,p)}else if(w(c))for(let f of Object.entries(c)){let p=f[0],l=f[1];ze(t,p,l)}else{let f=e[a++],p=e[a];ze(t,f,p)}}}};function es(t){return!!t||t===""}var ze=(t,e,n)=>{if(Y(e)){I(3,name,t);return}if(e==="innerHTML"||e==="textContent"){let s=[...t.childNodes];setTimeout(()=>s.forEach(te),1),t[e]=n??"";return}let r=t.tagName;if(e==="value"&&r!=="PROGRESS"&&!r.includes("-")){t._value=n;let s=r==="OPTION"?t.getAttribute("value"):t.value,i=n??"";s!==i&&(t.value=i),n==null&&t.removeAttribute(e);return}let o=!1;if(n===""||n==null){let s=typeof t[e];s==="boolean"?n=es(n):n==null&&s==="string"?(n="",o=!0):s==="number"&&(n=0,o=!0)}try{t[e]=n}catch(s){o||I(4,e,r,n,s)}o&&t.removeAttribute(e)};var Sr={once:!0,onBind:(t,e,n)=>{let r=e.value()[0],o=T(r),s=e.refs[0];return o?r.push(t):s?s?.(t):e.context[n]=t,()=>{if(o){let i=r.indexOf(t);i!==-1&&r.splice(i,1)}else s?.(null)}}};var wr={onChange:(t,e)=>{let n=me(t).data,r=n._ord;xn(r)&&(r=n._ord=t.style.display),!!e[0]?t.style.display=r:t.style.display="none"}};var hn={onChange:(t,e,n)=>{let r=e.length;for(let o=0;o<r;++o){let s=e[o],i=n?.[o];if(T(s)){let a=s.length;for(let c=0;c<a;++c)Ar(t,s[c],i?.[c])}else Ar(t,s,i)}}},Ar=(t,e,n)=>{let r=t.style,o=H(e);if(e&&!o){if(n&&!H(n))for(let s in n)e[s]==null&&yn(r,s,"");for(let s in e)yn(r,s,e[s])}else{let s=r.display;if(o?n!==e&&(r.cssText=e):n&&t.removeAttribute("style"),"_ord"in me(t).data)return;r.display=s}},Or=/\s*!important$/;function yn(t,e,n){if(T(n))n.forEach(r=>{yn(t,e,r)});else if(n==null&&(n=""),e.startsWith("--"))t.setProperty(e,n);else{let r=ts(t,e);Or.test(n)?t.setProperty(_e(r),n.replace(Or,""),"important"):t[r]=n}}var Nr=["Webkit","Moz","ms"],dn={};function ts(t,e){let n=dn[e];if(n)return n;let r=B(e);if(r!=="filter"&&r in t)return dn[e]=r;r=Ze(r);for(let o=0;o<Nr.length;o++){let s=Nr[o]+r;if(s in t)return dn[e]=s}return e}var J=t=>ns(V(t)),ns=t=>{if(!t||!w(t))return t;if(T(t))return t.map(J);if(X(t)){let n=new Set;for(let r of t.keys())n.add(J(r));return n}if(ue(t)){let n=new Map;for(let r of n)n.set(J(r[0]),J(r[1]));return n}let e={...t};for(let n of Object.entries(e))e[n[0]]=J(n[1]);return e};var Mr={onChange:(t,e)=>{let n=e[0];t.textContent=X(n)?JSON.stringify(J([...n])):ue(n)?JSON.stringify(J([...n])):w(n)?JSON.stringify(J(n)):n?.toString()??""}};var Lr={onChange:(t,e)=>{ze(t,"value",e[0])}};var Ne=t=>t?.[it]===1;var Te=t=>{if(Be(t))return t;let e;if(m(t)?(e=t,t=e()):e=z(t),t instanceof Node||t instanceof Date||t instanceof RegExp||t instanceof Promise||t instanceof Error)return e;if(e[it]=1,T(t)){let n=t.length;for(let r=0;r<n;++r){let o=t[r];Ne(o)||(t[r]=Te(o))}return e}if(!w(t))return e;for(let n of Object.entries(t)){let r=n[1];if(Ne(r))continue;let o=n[0];Je(o)||(t[o]=Te(r))}return e};var re=class t{static getDefault(){return t.Fe??(t.Fe=new t)}H={};l={};Ze=()=>Object.keys(this.H).filter(e=>e.length===1||!e.startsWith(":"));he=new Map;ge=new Map;static Fe;static Tt="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";forGrowThreshold=10;globalContext;useInterpolation=!0;constructor(e){if(this.setDirectives("r-"),e){this.globalContext=e;return}this.globalContext=this.xt()}xt(){let e={},n=globalThis;for(let r of t.Tt.split(","))e[r]=n[r];return e.ref=Te,e.sref=z,e.flatten=J,e}addComponent(...e){for(let n of e){if(!n.defaultName){Qe.warning("Registered component's default name is not defined",n);continue}this.he.set(Ze(n.defaultName),n),this.ge.set(Ze(n.defaultName).toLocaleUpperCase(),n)}}setDirectives(e){this.H={".":Rr,":":fn,"@":mn,[`${e}on`]:mn,[`${e}bind`]:fn,[`${e}html`]:ur,[`${e}text`]:Mr,[`${e}show`]:wr,[`${e}model`]:yr,":style":hn,[`${e}bind:style`]:hn,":class":ln,[`${e}bind:class`]:ln,":ref":Sr,":value":Lr,teleport:Rt},this.l={for:`${e}for`,if:`${e}if`,else:`${e}else`,elseif:`${e}else-if`,pre:`${e}pre`,inherit:`${e}inherit`,text:`${e}text`,props:":props",propsOnce:":props-once",bind:`${e}bind`,on:`${e}on`,keyBind:":key",key:"key",is:":is",teleport:`${e}teleport`,dynamic:"_d_"}}updateDirectives(e){e(this.H,this.l)}};var Bt=(t,e)=>{if(!t)return;let n=(e??re.getDefault()).l;for(let r of ss(t,n.pre))os(r,n.text)},rs=/({{[^]*?}})/g,os=(t,e)=>{let n=t.textContent;if(!n)return;let r=rs,o=n.split(r);if(o.length<=1)return;if(t.parentElement?.childNodes.length===1&&o.length===3){let i=o[1];if($(o[0])&&$(o[2])&&i.startsWith("{{")&&i.endsWith("}}")){let a=t.parentElement;a.setAttribute(e,i.substring(2,i.length-2)),a.innerText="";return}}let s=document.createDocumentFragment();for(let i of o)if(i.startsWith("{{")&&i.endsWith("}}")){let a=document.createElement("span");a.setAttribute(e,i.substring(2,i.length-2)),s.appendChild(a)}else s.appendChild(document.createTextNode(i));t.replaceWith(s)},ss=(t,e)=>{let n=[],r=o=>{if(o.nodeType===Node.TEXT_NODE)o.textContent?.includes("{{")&&n.push(o);else{if(o?.hasAttribute?.(e))return;for(let s of ce(o))r(s)}};return r(t),n};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",as=new Set(is.toUpperCase().split(",")),cs="http://www.w3.org/2000/svg",kr=(t,e)=>{ne(t)?t.content.appendChild(e):t.appendChild(e)},gn=(t,e,n,r)=>{let o=t.t;if(o){let i=n&&as.has(o.toUpperCase())?document.createElementNS(cs,o.toLowerCase()):document.createElement(o),a=t.a;if(a)for(let f of Object.entries(a)){let p=f[0],l=f[1];p.startsWith("#")&&(l=p.substring(1),p="name"),i.setAttribute(lt(p,r),l)}let c=t.c;if(c)for(let f of c)gn(f,i,n,r);kr(e,i);return}let s=t.d;if(s){let i;switch(t.n??Node.TEXT_NODE){case Node.COMMENT_NODE:i=document.createComment(s);break;case Node.TEXT_NODE:i=document.createTextNode(s);break}if(i)kr(e,i);else throw new Error("unsupported node type.")}},Me=(t,e,n)=>{n??=re.getDefault();let r=document.createDocumentFragment();if(!T(t))return gn(t,r,!!e,n),r;for(let o of t)gn(o,r,!!e,n);return r};var Ir=(t,e={selector:"#app"},n)=>{H(e)&&(e={selector:"#app",template:e}),Pn(t)&&(t=t.context);let r=e.element?e.element:e.selector?document.querySelector(e.selector):null;if(!r||!Se(r))throw _(0);n||(n=re.getDefault());let o=()=>{for(let a of[...r.childNodes])P(a)},s=a=>{for(let c of a)r.appendChild(c)};if(e.template){let a=document.createRange().createContextualFragment(e.template);o(),s(a.childNodes),e.element=a}else if(e.json){let a=Me(e.json,e.isSVG,n);o(),s(a.childNodes)}return n.useInterpolation&&Bt(r,n),new bn(t,r,n).x(),k(r,()=>{ge(t)}),vt(t),{context:t,unmount:()=>{P(r)},unbind:()=>{te(r)}}},bn=class{Et;$e;o;h;p;constructor(e,n,r){this.Et=e,this.$e=n,this.o=r,this.h=new It([e],r),this.p=new St(this.h)}x(){this.p.G(this.$e)}};var Ke=t=>{if(T(t))return t.map(o=>Ke(o));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(o=>[o,t.getAttribute(o)])));let r=ce(t);return r.length>0&&(e.c=[...r].map(o=>Ke(o))),e};var Dr=(t,e,n={})=>{T(n)&&(n={props:n}),H(e)&&(e={template:e});let r=!1;if(e.element){let s=e.element;s.remove(),e.element=s}else if(e.selector){let s=document.querySelector(e.selector);if(!s)throw _(1,e.selector);s.remove(),e.element=s}else if(e.template){let s=document.createRange().createContextualFragment(e.template);e.element=s}else e.json&&(e.element=Me(e.json,e.isSVG,n.config),r=!0);e.element||(e.element=document.createDocumentFragment()),(n.useInterpolation??!0)&&Bt(e.element);let o=e.element;if(!r&&((e.isSVG??(Ye(o)&&o.hasAttribute?.("isSVG")))||Ye(o)&&o.querySelector("[isSVG]"))){let s=e.element.content,i=s?[...s.childNodes]:[...o.childNodes],a=Ke(i);e.element=Me(a,!0,n.config)}return{context:t,template:e.element,inheritAttrs:n.inheritAttrs??!0,props:n.props,defaultName:n.defaultName}};var Ur=t=>{let e,n={},r=(...o)=>{if(o.length<=2&&0 in o)throw _(4);return e&&!n.isStopped?e(...o):(e=ps(t,n),e(...o))};return r[G]=1,he(r,!0),r.stop=()=>n.ref?.stop?.(),K(()=>r.stop(),!0),r},ps=(t,e)=>{let n=e.ref??z(null);e.ref=n,e.isStopped=!1;let r=0,o=we(()=>{if(r>0){o(),e.isStopped=!0,F(n);return}n(t()),++r});return n.stop=o,n};var Hr=(t,e)=>{let n={},r,o=(...s)=>{if(s.length<=2&&0 in s)throw _(4);return r&&!n.isStopped?r(...s):(r=fs(t,e,n),r(...s))};return o[G]=1,he(o,!0),o.stop=()=>n.ref?.stop?.(),K(()=>o.stop(),!0),o},fs=(t,e,n)=>{let r=n.ref??z(null);n.ref=r,n.isStopped=!1;let o=0,s=a=>{if(o>0){r.stop(),n.isStopped=!0,F(r);return}r(e(...t.map(c=>c()))),++o},i=[];for(let a of t){let c=C(a,s);i.push(c)}return s(null),r.stop=()=>{i.forEach(a=>{a()})},r};var _r=(t,e)=>{let n={},r,o=(...s)=>{if(s.length<=2&&0 in s)throw _(4);return r&&!n.isStopped?r(...s):(r=ls(t,e,n),r(...s))};return o[G]=1,he(o,!0),o.stop=()=>n.ref?.stop?.(),K(()=>o.stop(),!0),o},ls=(t,e,n)=>{let r=n.ref??z(null);n.ref=r,n.isStopped=!1;let o=0;return r.stop=C(t,s=>{if(o>0){r.stop(),n.isStopped=!0,F(r);return}r(e(s)),++o},!0),r};var Br=t=>(t[at]=1,t);var Vr=(t,e)=>{if(!e)throw new Error("persist requires a string key.");let r=Ne(t)?Te:a=>a,o=()=>localStorage.setItem(e,JSON.stringify(J(t()))),s=localStorage.getItem(e);s!=null?t(r(JSON.parse(s))):o();let i=we(o);return K(()=>i,!0),t};var Tn=(t,...e)=>{let n="";return e.length===0?t.join():(t.forEach((r,o)=>{n+=r+e[o]}),n)},Pr=Tn;var jr=(t,e,n)=>{let r=[],o=()=>{e(t.map(i=>i()))};for(let i of t)r.push(C(i,o));n&&o();let s=()=>{for(let i of r)i()};return K(s,!0),s};var $r=t=>{if(!m(t))throw _(3,"observe");return t(void 0,void 0,2)};var Fr=t=>{En();try{t()}finally{vn()}},En=()=>{Ae.set||(Ae.set=new Set)},vn=()=>{let t=Ae.set;if(t){delete Ae.set;for(let e of t)try{F(e)}catch(n){console.error(n)}}};var qr=t=>{Re()?.onMounted.push(t)};return Qr(us);})();
3
+ `;break;case"r":r+="\r";break;case"t":r+=" ";break;case"b":r+="\b";break;case"f":r+="\f";break;case"v":r+="\v";break;default:r+=c}else r+=c,o+=c}throw this.i("Unclosed `")}ft(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 r=e.node;for(;r.type===3||r.type===6&&r?.callee?.type===3;)r=r.type===3?r.object:r.callee.object;r.type=20}lt(e){if(!this.u(qn))return;let n=++this.e,r=!1;for(;this.e<this.r.length;){if(this.f===qn&&!r){let o=this.r.slice(n,this.e),s="";for(;++this.e<this.r.length;){let a=this.f;if(a>=97&&a<=122||a>=65&&a<=90||a>=48&&a<=57)s+=this.M;else break}let i;try{i=new RegExp(o,s)}catch(a){throw this.i(a.message)}return e.node={type:4,value:i,raw:this.r.slice(n-1,this.e)},e.node=this.F(e.node),e.node}this.u(Ot)?r=!0:r&&this.u(Nt)&&(r=!1),this.e+=this.u(bo)?2:1}throw this.i("Unclosed Regex")}},nr=t=>new sn(t).parse();var Do={"=>":(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,"&":(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},Uo={"-":t=>-t,"+":t=>+t,"!":t=>!t,"~":t=>~t,new:t=>t},ir=t=>{if(!t?.some(sr))return t;let e=[];return t.forEach(n=>sr(n)?e.push(...n):e.push(n)),e},rr=(...t)=>ir(t),cn=(t,e)=>{if(!t)return e;let n=Object.create(e??{});return n.$event=t,n},Ho={"++":(t,e)=>{let n=t[e];if(m(n)){let r=n();return n(++r),r}return++t[e]},"--":(t,e)=>{let n=t[e];if(m(n)){let r=n();return n(--r),r}return--t[e]}},_o={"++":(t,e)=>{let n=t[e];if(m(n)){let r=n();return n(r+1),r}return t[e]++},"--":(t,e)=>{let n=t[e];if(m(n)){let r=n();return n(r-1),r}return t[e]--}},or={"=":(t,e,n)=>{let r=t[e];return m(r)?r(n):t[e]=n},"+=":(t,e,n)=>{let r=t[e];return m(r)?r(r()+n):t[e]+=n},"-=":(t,e,n)=>{let r=t[e];return m(r)?r(r()-n):t[e]-=n},"*=":(t,e,n)=>{let r=t[e];return m(r)?r(r()*n):t[e]*=n},"/=":(t,e,n)=>{let r=t[e];return m(r)?r(r()/n):t[e]/=n},"%=":(t,e,n)=>{let r=t[e];return m(r)?r(r()%n):t[e]%=n},"**=":(t,e,n)=>{let r=t[e];return m(r)?r(r()**n):t[e]**=n},"<<=":(t,e,n)=>{let r=t[e];return m(r)?r(r()<<n):t[e]<<=n},">>=":(t,e,n)=>{let r=t[e];return m(r)?r(r()>>n):t[e]>>=n},">>>=":(t,e,n)=>{let r=t[e];return m(r)?r(r()>>>n):t[e]>>>=n},"|=":(t,e,n)=>{let r=t[e];return m(r)?r(r()|n):t[e]|=n},"&=":(t,e,n)=>{let r=t[e];return m(r)?r(r()&n):t[e]&=n},"^=":(t,e,n)=>{let r=t[e];return m(r)?r(r()^n):t[e]^=n}},kt=(t,e)=>U(t)?t.bind(e):t,pn=class{m;Ve;ke;Ie;O;De;Ue;constructor(e,n,r,o,s){this.m=T(e)?e:[e],this.Ve=n,this.ke=r,this.Ie=o,this.Ue=!!s}Pe(e,n){if(n&&e in n)return n;for(let r of this.m)if(e in r)return r}2(e,n,r){let o=e.name;if(o==="$root")return this.m[this.m.length-1];if(o==="$parent")return this.m[1];if(o==="$ctx")return[...this.m];if(r&&o in r)return this.O=r[o],kt(V(r[o]),r);for(let i of this.m)if(o in i)return this.O=i[o],kt(V(i[o]),i);let s=this.Ve;if(s&&o in s)return this.O=s[o],kt(V(s[o]),s)}5(e,n,r){return this.m[0]}0(e,n,r){return this.Be(n,r,rr,...e.body)}1(e,n,r){return this.R(n,r,(...o)=>o.pop(),...e.expressions)}3(e,n,r){let{obj:o,key:s}=this.ae(e,n,r),i=o?.[s];return this.O=i,kt(V(i),o)}4(e,n,r){return e.value}6(e,n,r){let o=(i,...a)=>U(i)?i(...ir(a)):i,s=this.R(++n,r,o,e.callee,...e.arguments);return this.O=s,s}7(e,n,r){return this.R(n,r,Uo[e.operator],e.argument)}8(e,n,r){let o=Do[e.operator];switch(e.operator){case"||":case"&&":case"??":return o(()=>this.g(e.left,n,r),()=>this.g(e.right,n,r))}return this.R(n,r,o,e.left,e.right)}9(e,n,r){return this.Be(++n,r,rr,...e.elements)}10(e,n,r){let o={},s=(...i)=>{i.forEach(a=>{Object.assign(o,a)})};return this.R(++n,r,s,...e.properties),o}11(e,n,r){return this.R(n,r,o=>this.g(o?e.consequent:e.alternate,n,r),e.test)}12(e,n,r){let o={},s=p=>p?.type!==15,i=this.Ie??(()=>!1),a=n===0&&this.Ue,c=p=>this._e(a,e.key,n,cn(p,r)),f=p=>this._e(a,e.value,n,cn(p,r));if(e.shorthand){let p=e.key.name;o[p]=s(e.key)&&i(p,n)?c:c()}else if(e.computed){let p=V(c());o[p]=s(e.value)&&i(p,n)?f:f()}else{let p=e.key.type===4?e.key.value:e.key.name;o[p]=s(e.value)&&i(p,n)?()=>f:f()}return o}ae(e,n,r){let o=this.g(e.object,n,r),s=e.computed?this.g(e.property,n,r):e.property.name;return{obj:o,key:s}}13(e,n,r){let o=e.argument,s=e.operator,i=e.prefix?Ho:_o;if(o.type===2){let a=o.name,c=this.Pe(a,r);return Y(c)?void 0:i[s](c,a)}if(o.type===3){let{obj:a,key:c}=this.ae(o,n,r);return i[s](a,c)}}16(e,n,r){let o=e.left,s=e.operator;if(o.type===2){let i=o.name,a=this.Pe(i,r);if(Y(a))return;let c=this.g(e.right,n,r);return or[s](a,i,c)}if(o.type===3){let{obj:i,key:a}=this.ae(o,n,r),c=this.g(e.right,n,r);return or[s](i,a,c)}}14(e,n,r){let o=this.g(e.argument,n,r);return T(o)&&(o.s=ar),o}17(e,n,r){return this[6]({type:6,callee:e.tag,arguments:[{type:9,elements:e.quasi.quasis},...e.quasi.expressions]},n,r)}19(e,n,r){let o=(...s)=>s.reduce((i,a,c)=>i+=a+e.quasis[c+1].value.cooked,e.quasis[0].value.cooked);return this.R(n,r,o,...e.expressions)}18(e,n,r){return e.value.cooked}20(e,n,r){let o=(s,...i)=>new s(...i);return this.R(n,r,o,e.callee,...e.arguments)}15(e,n,r){return(...o)=>{let s=Object.create(r??{}),i=e.params;if(i){let a=0;for(let c of i)s[c.name]=o[a++]}return this.g(e.body,n,s)}}g(e,n,r){let o=V(this[e.type](e,n,r));return this.De=e.type,o}_e(e,n,r,o){let s=this.g(n,r,o);return e&&this.He()?this.O:s}He(){let e=this.De;return(e===2||e===3||e===6)&&m(this.O)}eval(e,n){let{value:r,refs:o}=mt(()=>this.g(e,-1,n)),s={value:r,refs:o};return this.He()&&(s.ref=this.O),s}R(e,n,r,...o){let s=o.map(i=>i&&this.g(i,e,n));return r(...s)}Be(e,n,r,...o){let s=this.ke;if(!s)return this.R(e,n,r,...o);let i=o.map((a,c)=>a&&(a.type!==15&&s(c,e)?f=>this.g(a,e,cn(f,n)):this.g(a,e,n)));return r(...i)}},ar=Symbol("s"),sr=t=>t?.s===ar,cr=(t,e,n,r,o,s,i)=>new pn(e,n,r,o,i).eval(t,s);var pr={},It=class{m;o;constructor(e,n){this.m=e,this.o=n}w(e){this.m=[e,...this.m]}me(){return this.m.map(n=>n.components).filter(n=>!!n).reverse().reduce((n,r)=>{for(let[o,s]of Object.entries(r))n[o.toUpperCase()]=s;return n},{})}v(e,n,r,o,s){let i=z([]),a=[],c=()=>{for(let u of a)u();a.length=0},f={value:i,stop:c,refs:[],context:this.m[0]};if($(e))return f;let p=this.o.globalContext,l=[],b=(u,y,v,S)=>{try{let h=cr(u,y,p,n,r,S,o);return v&&l.push(...h.refs),{value:h.value,refs:h.refs,ref:h.ref}}catch(h){I(6,`evaluation error: ${e}`,h)}return{value:void 0,refs:[]}};try{let u=pr[e]??nr("["+e+"]");pr[e]=u;let y=this.m,v=()=>{l.splice(0),c();let S=u.elements.map((h,A)=>n?.(A,-1)?{value:O=>b(h,y,!1,{$event:O}).value,refs:[]}:b(h,y,!0));if(!s)for(let h of l){let A=C(h,v);a.push(A)}i(S.map(h=>h.value)),f.refs=S.map(h=>h.ref)};v()}catch(u){I(6,`parse error: ${e}`,u)}return f}k(){return this.m}je=[];Y(e){this.je.push(this.m),this.m=e}C(e,n){try{this.Y(e),n()}finally{this.bt()}}bt(){this.m=this.je.pop()??[]}};var fr="http://www.w3.org/1999/xlink",Bo={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 Vo(t){return!!t||t===""}var fn={onChange:(t,e,n,r,o,s)=>{if(r){s&&s.includes("camel")&&(r=B(r)),Dt(t,r,e[0],o);return}let i=e.length;for(let a=0;a<i;++a){let c=e[a];if(T(c)){let f=n?.[a]?.[0],p=c[0],l=c[1];Dt(t,p,l,f)}else if(w(c))for(let f of Object.entries(c)){let p=f[0],l=f[1],b=n?.[a],u=b&&p in b?p:void 0;Dt(t,p,l,u)}else{let f=n?.[a],p=e[a++],l=e[a];Dt(t,p,l,f)}}}},Dt=(t,e,n,r)=>{if(r&&r!==e&&t.removeAttribute(r),Y(e)){I(3,name,t);return}if(!H(e)){I(6,`Attribute key is not string at ${t.outerHTML}`,e);return}if(e.startsWith("xlink:")){Y(n)?t.removeAttributeNS(fr,e.slice(6,e.length)):t.setAttributeNS(fr,e,n);return}let o=e in Bo;Y(n)||o&&!Vo(n)?t.removeAttribute(e):t.setAttribute(e,o?"":n)};var ln={onChange:(t,e,n)=>{let r=e.length;for(let o=0;o<r;++o){let s=e[o],i=n?.[o];if(T(s)){let a=s.length;for(let c=0;c<a;++c)lr(t,s[c],i?.[c])}else lr(t,s,i)}}},lr=(t,e,n)=>{let r=t.classList,o=H(e),s=H(n);if(e&&!o){if(n&&!s)for(let i in n)i in e||r.remove(i);for(let i in e)e[i]&&r.add(i)}else o?n!==e&&(s&&r.remove(...n?.split(",")),r.add(...e.split(","))):n&&s&&r.remove(...n?.split(","))};var ur={onChange:(t,e)=>{let[n,r]=e;U(r)?r(t,n):t.innerHTML=n?.toString()}};function Po(t,e){if(t.length!==e.length)return!1;let n=!0;for(let r=0;n&&r<t.length;r++)n=pe(t[r],e[r]);return n}function pe(t,e){if(t===e)return!0;let n=Ft(t),r=Ft(e);if(n||r)return n&&r?t.getTime()===e.getTime():!1;if(n=Je(t),r=Je(e),n||r)return t===e;if(n=T(t),r=T(e),n||r)return n&&r?Po(t,e):!1;if(n=w(t),r=w(e),n||r){if(!n||!r)return!1;let o=Object.keys(t).length,s=Object.keys(e).length;if(o!==s)return!1;for(let i in t){let a=t.hasOwnProperty(i),c=e.hasOwnProperty(i);if(a&&!c||!a&&c||!pe(t[i],e[i]))return!1}}return String(t)===String(e)}function Ut(t,e){return t.findIndex(n=>pe(n,e))}var mr=t=>{let e=parseFloat(t);return isNaN(e)?t:e};var Ht=t=>{if(!m(t))throw _(3,"pause");t(void 0,void 0,3)};var _t=t=>{if(!m(t))throw _(3,"resume");t(void 0,void 0,4)};var yr={onChange:(t,e)=>{jo(t,e[0])},onBind:(t,e,n,r,o,s)=>$o(t,e,s)},jo=(t,e)=>{let n=Tr(t);if(n&&hr(t))T(e)?e=Ut(e,fe(t))>-1:X(e)?e=e.has(fe(t)):e=Go(t,e),t.checked=e;else if(n&&gr(t))t.checked=pe(e,fe(t));else if(n||Er(t))br(t)?t.value!==e?.toString()&&(t.value=e):t.value!==e&&(t.value=e);else if(vr(t)){let r=t.options,o=r.length,s=t.multiple;for(let i=0;i<o;i++){let a=r[i],c=fe(a);if(s)T(e)?a.selected=Ut(e,c)>-1:a.selected=e.has(c);else if(pe(fe(a),e)){t.selectedIndex!==i&&(t.selectedIndex=i);return}}!s&&t.selectedIndex!==-1&&(t.selectedIndex=-1)}else I(7,t)},tt=t=>(m(t)&&(t=t()),U(t)&&(t=t()),t?H(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}),hr=t=>t.type==="checkbox",gr=t=>t.type==="radio",br=t=>t.type==="number"||t.type==="range",Tr=t=>t.tagName==="INPUT",Er=t=>t.tagName==="TEXTAREA",vr=t=>t.tagName==="SELECT",$o=(t,e,n)=>{let r=e.value,o=tt(n?.join(",")),s=tt(r()[1]),i={int:o.int||o.int,lazy:o.lazy||s.lazy,number:o.number||s.number,trim:o.trim||s.trim},a=e.refs[0];if(!a)return I(8,t),()=>{};let c=Tr(t);return c&&hr(t)?qo(t,a):c&&gr(t)?Jo(t,a):c||Er(t)?Fo(t,i,a,r):vr(t)?Qo(t,a,r):(I(7,t),()=>{})},dr=/[.,' ·٫]/,Fo=(t,e,n,r)=>{let s=e.lazy?"change":"input",i=br(t),a=()=>{!e.trim&&!tt(r()[1]).trim||(t.value=t.value.trim())},c=b=>{let u=b.target;u.composing=1},f=b=>{let u=b.target;u.composing&&(u.composing=0,u.dispatchEvent(new Event(s)))},p=()=>{t.removeEventListener(s,l),t.removeEventListener("change",a),t.removeEventListener("compositionstart",c),t.removeEventListener("compositionend",f),t.removeEventListener("change",f)},l=b=>{let u=b.target;if(!u||u.composing)return;let y=u.value,v=tt(r()[1]);if(i||v.number||v.int){if(v.int)y=parseInt(y);else{if(dr.test(y[y.length-1])&&y.split(dr).length===2){if(y+="0",y=parseFloat(y),isNaN(y))y="";else if(n()===y)return}y=parseFloat(y)}isNaN(y)&&(y=""),t.value=y}else v.trim&&(y=y.trim());n(y)};return t.addEventListener(s,l),t.addEventListener("change",a),t.addEventListener("compositionstart",c),t.addEventListener("compositionend",f),t.addEventListener("change",f),p},qo=(t,e)=>{let n="change",r=()=>{t.removeEventListener(n,o)},o=()=>{let s=fe(t),i=t.checked,a=e();if(T(a)){let c=Ut(a,s),f=c!==-1;i&&!f?a.push(s):!i&&f&&a.splice(c,1)}else X(a)?i?a.add(s):a.delete(s):e(Wo(t,i))};return t.addEventListener(n,o),r},fe=t=>"_value"in t?t._value:t.value,xr="trueValue",zo="falseValue",Cr="true-value",Ko="false-value",Wo=(t,e)=>{let n=e?xr:zo;if(n in t)return t[n];let r=e?Cr:Ko;return t.hasAttribute(r)?t.getAttribute(r):e},Go=(t,e)=>{if(xr in t)return pe(e,t.trueValue);let r=Cr;return t.hasAttribute(r)?pe(e,t.getAttribute(r)):pe(e,!0)},Jo=(t,e)=>{let n="change",r=()=>{t.removeEventListener(n,o)},o=()=>{let s=fe(t);e(s)};return t.addEventListener(n,o),r},Qo=(t,e,n)=>{let r="change",o=()=>{t.removeEventListener(r,s)},s=()=>{let a=tt(n()[1]).number,c=Array.prototype.filter.call(t.options,f=>f.selected).map(f=>a?mr(fe(f)):fe(f));if(t.multiple){let f=e();try{if(Ht(e),X(f)){f.clear();for(let p of c)f.add(p)}else T(f)?(f.splice(0),f.push(...c)):e(c)}finally{_t(e),F(e)}}else e(c[0])};return t.addEventListener(r,s),o};var Xo=["stop","prevent","capture","self","once","left","right","middle","passive"],Yo=t=>{let e={};if($(t))return;let n=t.split(",");for(let r of Xo)e[r]=n.includes(r);return e},mn={isLazy:(t,e)=>e===-1&&t%2===0,isLazyKey:(t,e)=>e===0&&!t.endsWith("_flags"),once:!1,collectRefObj:!0,onBind:(t,e,n,r,o,s)=>{if(o){let p=e.value(),l=V(o.value()[0]);return H(l)?un(t,B(l),()=>e.value()[0],s?.join(",")??p[1]):()=>{}}else if(r){let p=e.value();return un(t,B(r),()=>e.value()[0],s?.join(",")??p[1])}let i=[],a=()=>{i.forEach(p=>p())},c=e.value(),f=c.length;for(let p=0;p<f;++p){let l=c[p];if(U(l)&&(l=l()),w(l))for(let b of Object.entries(l)){let u=b[0],y=()=>{let S=e.value()[p];return U(S)&&(S=S()),S=S[u],U(S)&&(S=S()),S},v=l[u+"_flags"];i.push(un(t,u,y,v))}else I(2,name,t)}return a}},Zo=(t,e)=>{if(t.startsWith("keydown")||t.startsWith("keyup")||t.startsWith("keypress")){e??="";let n=t.split(".").concat(e.split(","));t=n[0];let r=n[1],o=n.includes("ctrl"),s=n.includes("shift"),i=n.includes("alt"),a=n.includes("meta"),c=f=>!(o&&!f.ctrlKey||s&&!f.shiftKey||i&&!f.altKey||a&&!f.metaKey);return r?[t,f=>c(f)?f.key.toUpperCase()===r.toUpperCase():!1]:[t,c]}return[t,n=>!0]},un=(t,e,n,r)=>{if($(e))return I(5,name,t),()=>{};let o=Yo(r),s=o?{capture:o.capture,passive:o.passive,once:o.once}:void 0,i;[e,i]=Zo(e,r);let a=p=>{if(!i(p)||!n&&e==="submit"&&o?.prevent)return;let l=n(p);U(l)&&(l=l(p)),U(l)&&l(p)},c=()=>{t.removeEventListener(e,f,s)},f=p=>{if(!o){a(p);return}try{if(o.left&&p.button!==1||o.middle&&p.button!==2||o.right&&p.button!==3||o.self&&p.target!==t)return;o.stop&&p.stopPropagation(),o.prevent&&p.preventDefault(),a(p)}finally{o.once&&c()}};return t.addEventListener(e,f,s),c};var Rr={onChange:(t,e,n,r,o,s)=>{if(r){s&&s.includes("camel")&&(r=B(r)),ze(t,r,e[0]);return}let i=e.length;for(let a=0;a<i;++a){let c=e[a];if(T(c)){let f=c[0],p=c[1];ze(t,f,p)}else if(w(c))for(let f of Object.entries(c)){let p=f[0],l=f[1];ze(t,p,l)}else{let f=e[a++],p=e[a];ze(t,f,p)}}}};function es(t){return!!t||t===""}var ze=(t,e,n)=>{if(Y(e)){I(3,name,t);return}if(e==="innerHTML"||e==="textContent"){let s=[...t.childNodes];setTimeout(()=>s.forEach(te),1),t[e]=n??"";return}let r=t.tagName;if(e==="value"&&r!=="PROGRESS"&&!r.includes("-")){t._value=n;let s=r==="OPTION"?t.getAttribute("value"):t.value,i=n??"";s!==i&&(t.value=i),n==null&&t.removeAttribute(e);return}let o=!1;if(n===""||n==null){let s=typeof t[e];s==="boolean"?n=es(n):n==null&&s==="string"?(n="",o=!0):s==="number"&&(n=0,o=!0)}try{t[e]=n}catch(s){o||I(4,e,r,n,s)}o&&t.removeAttribute(e)};var Sr={once:!0,onBind:(t,e,n)=>{let r=e.value()[0],o=T(r),s=e.refs[0];return o?r.push(t):s?s?.(t):e.context[n]=t,()=>{if(o){let i=r.indexOf(t);i!==-1&&r.splice(i,1)}else s?.(null)}}};var wr={onChange:(t,e)=>{let n=me(t).data,r=n._ord;xn(r)&&(r=n._ord=t.style.display),!!e[0]?t.style.display=r:t.style.display="none"}};var hn={onChange:(t,e,n)=>{let r=e.length;for(let o=0;o<r;++o){let s=e[o],i=n?.[o];if(T(s)){let a=s.length;for(let c=0;c<a;++c)Ar(t,s[c],i?.[c])}else Ar(t,s,i)}}},Ar=(t,e,n)=>{let r=t.style,o=H(e);if(e&&!o){if(n&&!H(n))for(let s in n)e[s]==null&&yn(r,s,"");for(let s in e)yn(r,s,e[s])}else{let s=r.display;if(o?n!==e&&(r.cssText=e):n&&t.removeAttribute("style"),"_ord"in me(t).data)return;r.display=s}},Or=/\s*!important$/;function yn(t,e,n){if(T(n))n.forEach(r=>{yn(t,e,r)});else if(n==null&&(n=""),e.startsWith("--"))t.setProperty(e,n);else{let r=ts(t,e);Or.test(n)?t.setProperty(_e(r),n.replace(Or,""),"important"):t[r]=n}}var Nr=["Webkit","Moz","ms"],dn={};function ts(t,e){let n=dn[e];if(n)return n;let r=B(e);if(r!=="filter"&&r in t)return dn[e]=r;r=Ze(r);for(let o=0;o<Nr.length;o++){let s=Nr[o]+r;if(s in t)return dn[e]=s}return e}var J=t=>ns(V(t)),ns=t=>{if(!t||!w(t))return t;if(T(t))return t.map(J);if(X(t)){let n=new Set;for(let r of t.keys())n.add(J(r));return n}if(ue(t)){let n=new Map;for(let r of n)n.set(J(r[0]),J(r[1]));return n}let e={...t};for(let n of Object.entries(e))e[n[0]]=J(n[1]);return e};var Mr={onChange:(t,e)=>{let n=e[0];t.textContent=X(n)?JSON.stringify(J([...n])):ue(n)?JSON.stringify(J([...n])):w(n)?JSON.stringify(J(n)):n?.toString()??""}};var Lr={onChange:(t,e)=>{ze(t,"value",e[0])}};var Ne=t=>t?.[it]===1;var Te=t=>{if(Be(t))return t;let e;if(m(t)?(e=t,t=e()):e=z(t),t instanceof Node||t instanceof Date||t instanceof RegExp||t instanceof Promise||t instanceof Error)return e;if(e[it]=1,T(t)){let n=t.length;for(let r=0;r<n;++r){let o=t[r];Ne(o)||(t[r]=Te(o))}return e}if(!w(t))return e;for(let n of Object.entries(t)){let r=n[1];if(Ne(r))continue;let o=n[0];Je(o)||(t[o]=Te(r))}return e};var re=class t{static getDefault(){return t.Fe??(t.Fe=new t)}H={};l={};Ze=()=>Object.keys(this.H).filter(e=>e.length===1||!e.startsWith(":"));he=new Map;ge=new Map;static Fe;static Tt="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";forGrowThreshold=10;globalContext;useInterpolation=!0;constructor(e){if(this.setDirectives("r-"),e){this.globalContext=e;return}this.globalContext=this.xt()}xt(){let e={},n=globalThis;for(let r of t.Tt.split(","))e[r]=n[r];return e.ref=Te,e.sref=z,e.flatten=J,e}addComponent(...e){for(let n of e){if(!n.defaultName){Qe.warning("Registered component's default name is not defined",n);continue}this.he.set(Ze(n.defaultName),n),this.ge.set(Ze(n.defaultName).toLocaleUpperCase(),n)}}setDirectives(e){this.H={".":Rr,":":fn,"@":mn,[`${e}on`]:mn,[`${e}bind`]:fn,[`${e}html`]:ur,[`${e}text`]:Mr,[`${e}show`]:wr,[`${e}model`]:yr,":style":hn,[`${e}bind:style`]:hn,":class":ln,[`${e}bind:class`]:ln,":ref":Sr,":value":Lr,teleport:Rt},this.l={for:`${e}for`,if:`${e}if`,else:`${e}else`,elseif:`${e}else-if`,pre:`${e}pre`,inherit:`${e}inherit`,text:`${e}text`,props:":props",propsOnce:":props-once",bind:`${e}bind`,on:`${e}on`,keyBind:":key",key:"key",is:":is",teleport:`${e}teleport`,dynamic:"_d_"}}updateDirectives(e){e(this.H,this.l)}};var Bt=(t,e)=>{if(!t)return;let n=(e??re.getDefault()).l;for(let r of ss(t,n.pre))os(r,n.text)},rs=/({{[^]*?}})/g,os=(t,e)=>{let n=t.textContent;if(!n)return;let r=rs,o=n.split(r);if(o.length<=1)return;if(t.parentElement?.childNodes.length===1&&o.length===3){let i=o[1];if($(o[0])&&$(o[2])&&i.startsWith("{{")&&i.endsWith("}}")){let a=t.parentElement;a.setAttribute(e,i.substring(2,i.length-2)),a.innerText="";return}}let s=document.createDocumentFragment();for(let i of o)if(i.startsWith("{{")&&i.endsWith("}}")){let a=document.createElement("span");a.setAttribute(e,i.substring(2,i.length-2)),s.appendChild(a)}else s.appendChild(document.createTextNode(i));t.replaceWith(s)},ss=(t,e)=>{let n=[],r=o=>{if(o.nodeType===Node.TEXT_NODE)o.textContent?.includes("{{")&&n.push(o);else{if(o?.hasAttribute?.(e))return;for(let s of ce(o))r(s)}};return r(t),n};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",as=new Set(is.toUpperCase().split(",")),cs="http://www.w3.org/2000/svg",kr=(t,e)=>{ne(t)?t.content.appendChild(e):t.appendChild(e)},gn=(t,e,n,r)=>{let o=t.t;if(o){let i=n&&as.has(o.toUpperCase())?document.createElementNS(cs,o.toLowerCase()):document.createElement(o),a=t.a;if(a)for(let f of Object.entries(a)){let p=f[0],l=f[1];p.startsWith("#")&&(l=p.substring(1),p="name"),i.setAttribute(lt(p,r),l)}let c=t.c;if(c)for(let f of c)gn(f,i,n,r);kr(e,i);return}let s=t.d;if(s){let i;switch(t.n??Node.TEXT_NODE){case Node.COMMENT_NODE:i=document.createComment(s);break;case Node.TEXT_NODE:i=document.createTextNode(s);break}if(i)kr(e,i);else throw new Error("unsupported node type.")}},Me=(t,e,n)=>{n??=re.getDefault();let r=document.createDocumentFragment();if(!T(t))return gn(t,r,!!e,n),r;for(let o of t)gn(o,r,!!e,n);return r};var Ir=(t,e={selector:"#app"},n)=>{H(e)&&(e={selector:"#app",template:e}),Pn(t)&&(t=t.context);let r=e.element?e.element:e.selector?document.querySelector(e.selector):null;if(!r||!Se(r))throw _(0);n||(n=re.getDefault());let o=()=>{for(let a of[...r.childNodes])P(a)},s=a=>{for(let c of a)r.appendChild(c)};if(e.template){let a=document.createRange().createContextualFragment(e.template);o(),s(a.childNodes),e.element=a}else if(e.json){let a=Me(e.json,e.isSVG,n);o(),s(a.childNodes)}return n.useInterpolation&&Bt(r,n),new bn(t,r,n).x(),k(r,()=>{ge(t)}),vt(t),{context:t,unmount:()=>{P(r)},unbind:()=>{te(r)}}},bn=class{Et;$e;o;h;p;constructor(e,n,r){this.Et=e,this.$e=n,this.o=r,this.h=new It([e],r),this.p=new St(this.h)}x(){this.p.G(this.$e)}};var Ke=t=>{if(T(t))return t.map(o=>Ke(o));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(o=>[o,t.getAttribute(o)])));let r=ce(t);return r.length>0&&(e.c=[...r].map(o=>Ke(o))),e};var Dr=(t,e,n={})=>{T(n)&&(n={props:n}),H(e)&&(e={template:e});let r=!1;if(e.element){let s=e.element;s.remove(),e.element=s}else if(e.selector){let s=document.querySelector(e.selector);if(!s)throw _(1,e.selector);s.remove(),e.element=s}else if(e.template){let s=document.createRange().createContextualFragment(e.template);e.element=s}else e.json&&(e.element=Me(e.json,e.isSVG,n.config),r=!0);e.element||(e.element=document.createDocumentFragment()),(n.useInterpolation??!0)&&Bt(e.element);let o=e.element;if(!r&&((e.isSVG??(Ye(o)&&o.hasAttribute?.("isSVG")))||Ye(o)&&o.querySelector("[isSVG]"))){let s=e.element.content,i=s?[...s.childNodes]:[...o.childNodes],a=Ke(i);e.element=Me(a,!0,n.config)}return{context:t,template:e.element,inheritAttrs:n.inheritAttrs??!0,props:n.props,defaultName:n.defaultName}};var Ur=t=>{let e,n={},r=(...o)=>{if(o.length<=2&&0 in o)throw _(4);return e&&!n.isStopped?e(...o):(e=ps(t,n),e(...o))};return r[G]=1,he(r,!0),r.stop=()=>n.ref?.stop?.(),K(()=>r.stop(),!0),r},ps=(t,e)=>{let n=e.ref??z(null);e.ref=n,e.isStopped=!1;let r=0,o=we(()=>{if(r>0){o(),e.isStopped=!0,F(n);return}n(t()),++r});return n.stop=o,n};var Hr=(t,e)=>{let n={},r,o=(...s)=>{if(s.length<=2&&0 in s)throw _(4);return r&&!n.isStopped?r(...s):(r=fs(t,e,n),r(...s))};return o[G]=1,he(o,!0),o.stop=()=>n.ref?.stop?.(),K(()=>o.stop(),!0),o},fs=(t,e,n)=>{let r=n.ref??z(null);n.ref=r,n.isStopped=!1;let o=0,s=a=>{if(o>0){r.stop(),n.isStopped=!0,F(r);return}r(e(...t.map(c=>c()))),++o},i=[];for(let a of t){let c=C(a,s);i.push(c)}return s(null),r.stop=()=>{i.forEach(a=>{a()})},r};var _r=(t,e)=>{let n={},r,o=(...s)=>{if(s.length<=2&&0 in s)throw _(4);return r&&!n.isStopped?r(...s):(r=ls(t,e,n),r(...s))};return o[G]=1,he(o,!0),o.stop=()=>n.ref?.stop?.(),K(()=>o.stop(),!0),o},ls=(t,e,n)=>{let r=n.ref??z(null);n.ref=r,n.isStopped=!1;let o=0;return r.stop=C(t,s=>{if(o>0){r.stop(),n.isStopped=!0,F(r);return}r(e(s)),++o},!0),r};var Br=t=>(t[at]=1,t);var Vr=(t,e)=>{if(!e)throw new Error("persist requires a string key.");let r=Ne(t)?Te:a=>a,o=()=>localStorage.setItem(e,JSON.stringify(J(t()))),s=localStorage.getItem(e);s!=null?t(r(JSON.parse(s))):o();let i=we(o);return K(()=>i,!0),t};var Tn=(t,...e)=>{let n="";return e.length===0?t.join():(t.forEach((r,o)=>{n+=r+e[o]}),n)},Pr=Tn;var jr=(t,e,n)=>{let r=[],o=()=>{e(t.map(i=>i()))};for(let i of t)r.push(C(i,o));n&&o();let s=()=>{for(let i of r)i()};return K(s,!0),s};var $r=t=>{if(!m(t))throw _(3,"observe");return t(void 0,void 0,2)};var Fr=t=>{En();try{t()}finally{vn()}},En=()=>{Ae.set||(Ae.set=new Set)},vn=()=>{let t=Ae.set;if(t){delete Ae.set;for(let e of t)try{F(e)}catch(n){console.error(n)}}};var qr=t=>{Re()?.onMounted.push(t)};return Qr(us);})();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "regor",
3
- "version": "1.0.8",
3
+ "version": "1.0.9",
4
4
  "description": "A modern UI framework for web and desktop applications, inspired by Vue's concepts and powered by simplicity and flexibility.",
5
5
  "author": "Ahmed Yasin Koculu",
6
6
  "license": "MIT",