@tempots/ui 9.0.0 → 10.0.0

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/index.cjs CHANGED
@@ -1 +1 @@
1
- "use strict";var Le=Object.defineProperty;var Pe=(t,e,o)=>e in t?Le(t,e,{enumerable:!0,configurable:!0,writable:!0,value:o}):t[e]=o;var vt=(t,e,o)=>Pe(t,typeof e!="symbol"?e+"":e,o);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("@tempots/dom"),R=require("@tempots/std"),qt=t=>{const e=t.split("/").pop();if(e==null||e.startsWith("."))return;const o=e.split(".")||[];return o.length>1?"."+o.pop():void 0},Yt=(t,e)=>{const o=qt(e);return o!=null&&(t.length===0||!t.some(n=>o==n))},Te=(t,e,o,n)=>{let s=t.target;for(;s!=null&&!(s instanceof HTMLAnchorElement);)s=s.parentElement;if(s==null)return!0;const r=s;if(t.button!==0||t.ctrlKey||t.metaKey||r.target!=="_self"&&r.target!==""||r.getAttribute("download")!=null)return!0;const{pathname:i,search:c,hash:a}=r;if(n){const u=i+c+a,h=r.getAttribute("href");if(!(h!=null&&h.startsWith("#"))&&h!==u)return!0}return e?!1:Yt(o,i)},Qt=(t,e={ignoreUrlWithExtension:!0,allowedExtensions:[],ignoreExternalUrl:!0})=>{const o=e.ignoreUrlWithExtension===!0&&Array.isArray(e.allowedExtensions)?e.allowedExtensions.map(n=>n.startsWith(".")?n:"."+n):[];return n=>{Te(n,e.ignoreUrlWithExtension??!0,o,e.ignoreExternalUrl??!0)||t()&&n.preventDefault()}},Xt=(t,e)=>t.pathname===e.pathname&&JSON.stringify(t.search)===JSON.stringify(e.search)&&t.hash===e.hash,Pt=(t,e)=>{var r,i;const o=new URL(t,e??((r=l.getWindow())==null?void 0:r.location.toString())),n=Object.fromEntries(((i=o.searchParams)==null?void 0:i.entries())??[]);let s=o.hash;return s.startsWith("#")&&(s=s.substring(1)),{pathname:o.pathname,search:n,hash:s===""?void 0:s}},Rt=(t,e)=>{const o=Pt(e);return t.set(o),t},lt=t=>{const o=new URLSearchParams(t.search).toString(),n=t.hash;return`${t.pathname}${o?`?${o}`:""}${n?`#${n}`:""}`},ke=t=>t.startsWith("http://")||t.startsWith("https://")||t.startsWith("//"),Se=t=>{const e=t.container.currentURL,o=e.iso(n=>Pt(n),n=>{if(ke(n.pathname))return lt(n);const s=new URL(n.pathname,e.value),r=s.origin+s.pathname;return lt({...n,pathname:r})});return{value:o,dispose:o.dispose}},De=()=>{const t=l.getWindow(),e=(t==null?void 0:t.location.hash)===""?void 0:(t==null?void 0:t.location.hash.substring(1))??void 0;return{pathname:(t==null?void 0:t.location.pathname)??"",search:Object.fromEntries(new URLSearchParams((t==null?void 0:t.location.search)??"").entries()),hash:e}},We=()=>{const t=l.prop(De(),Xt),e=l.getWindow(),o=()=>{let n=(e==null?void 0:e.location.hash)??"";n.startsWith("#")&&(n=n.substring(1));const s={pathname:(e==null?void 0:e.location.pathname)??"",search:Object.fromEntries(new URLSearchParams((e==null?void 0:e.location.search)??"").entries()),hash:n===""?void 0:n};t.set(s)};return e==null||e.addEventListener("popstate",o),t.onDispose(()=>{e==null||e.removeEventListener("popstate",o)}),t.on(n=>{e==null||e.history.pushState({},"",lt(n))}),{value:t,dispose:t.dispose}},gt={mark:l.makeProviderMark("Location"),create:(t,e)=>{if(e.isBrowser())return We();if(e.isHeadless())return Se(e);throw new Error("Unknown context")}},Ce=t=>{document.startViewTransition?document.startViewTransition(t):t()},Jt=(t,...e)=>{if(typeof t=="string"||l.Signal.is(t))return Jt({href:t},...e);const{href:o,withViewTransition:n,...s}=t;return l.Use(gt,r=>l.html.a(l.on.click(Qt(()=>(n===!0?Ce(()=>{Rt(r,l.Value.get(o))}):Rt(r,l.Value.get(o)),!0),s)),l.attr.href(o),...e))},Fe={mark:l.makeProviderMark("Appearance"),create:()=>{const t=Gt();return{value:t,dispose:t.dispose}}};function Gt(){const t=l.getWindow(),e=t!=null&&t.matchMedia!=null?t.matchMedia("(prefers-color-scheme: dark)"):void 0,o=(e==null?void 0:e.matches)??!1,n=l.prop(o?"dark":"light"),s=r=>n.set(r.matches?"dark":"light");return e==null||e.addEventListener("change",s),n.onDispose(()=>e==null?void 0:e.removeEventListener("change",s)),n}const Tt=(t,e)=>{if(typeof e=="function")return Tt(t,{success:e});const o=e.failure??(i=>i.map(c=>`Error: ${c}`)),n=e.success,s=e.loading??(()=>l.Empty),r=e.notAsked??(()=>l.Empty);return l.OneOfType(l.Value.toSignal(t),{AsyncSuccess:i=>n(i.$.value),AsyncFailure:i=>o(i.$.error),Loading:i=>s(i.map(c=>c.previousValue)),NotAsked:r})},Ve=(t=10)=>l.WithElement(e=>l.OnDispose(R.delayed(()=>e==null?void 0:e.focus(),t))),Me=(t=10)=>l.WithElement(e=>{const o=R.delayed(()=>e.select(),t);return l.OnDispose(o)});function Ne(t){const e=Object.entries(t);return l.Fragment(...e.map(([o,n])=>l.attr.class(l.Value.map(n,s=>s?o:void 0))))}const Ue=l.WithElement(t=>{const e=t.style.getPropertyValue(":empty");return t.style.setProperty(":empty","display:none"),l.OnDispose(o=>{o&&t.style.setProperty(":empty",e)})}),He=t=>l.Portal("head > title",l.attr.innerText(t)),$e={partial:{root:null,rootMargin:"0px",threshold:0},full:{root:null,rootMargin:"0px",threshold:1}},at={partial:new Map,full:new Map},tt={partial:null,full:null};function Ke(t){return tt[t]==null&&(tt[t]=new IntersectionObserver(e=>{e.forEach(o=>{const n=at[t].get(o.target);n==null||n.set(o.isIntersecting)})},$e[t])),tt[t]}const Zt=({mode:t="partial",once:e=!1},o)=>{const n=l.prop(!1);return l.Fragment(l.WithElement(s=>{const r=typeof IntersectionObserver<"u"?Ke(t):null;at[t].set(s,n),r==null||r.observe(s);function i(){var a;r==null||r.unobserve(s),at[t].delete(s),at[t].size===0&&((a=tt[t])==null||a.disconnect(),tt[t]=null)}let c=null;return e&&(c=n.on(a=>{a&&i()})),l.OnDispose(()=>{n.dispose(),i(),c==null||c()})}),l.renderableOfTNode(o(n)))},Be=(t,e,o)=>Zt(t,n=>l.When(n,e,o??(()=>l.Empty)));function te(t){return l.WithElement(e=>{const o=n=>{e.contains(n.target)||t(n)};return document.addEventListener("click",o),l.OnDispose(()=>{document.removeEventListener("click",o)})})}const Y=(t,e)=>t===void 0||t===e,Nt=(t,e)=>t===void 0||t===e;function ee(t,e){return typeof t=="string"?e.key===t:Nt(t.key,e.key)&&Nt(t.code,e.code)&&Y(t.ctrlKey,e.ctrlKey)&&Y(t.altKey,e.altKey)&&Y(t.shiftKey,e.shiftKey)&&Y(t.metaKey,e.metaKey)&&Y(t.repeat,e.repeat)&&Y(t.commandOrControlKey,e.metaKey||e.ctrlKey)}function kt({allowedKeys:t,handler:e}){return l.WithElement(o=>{const n=s=>{if(o.contains(s.target)){for(const r of t)if(ee(r,s)){e(s);break}}};return document.addEventListener("keydown",n),l.OnDispose(()=>{document.removeEventListener("keydown",n)})})}function ze(t){return kt({allowedKeys:["Enter"],handler:t})}function _e(t){return kt({allowedKeys:["Escape"],handler:t})}const ne=({mutate:t,convertError:e,onSuccess:o,onError:n,onSettled:s})=>{let r;const i=l.prop(R.AsyncResult.notAsked),c=i.map(d=>R.AsyncResult.isSuccess(d)?d.value:void 0),a=i.map(d=>R.AsyncResult.isFailure(d)?d.error:void 0),u=i.map(d=>R.AsyncResult.isLoading(d)),h=()=>{r==null||r.abort(),r=void 0};return{status:i,value:c,error:a,pending:u,execute:async(d,y)=>{h(),r=new AbortController;const g=r.signal,v=i.get(),x=(y==null?void 0:y.optimisticValue)??((y==null?void 0:y.optimisticFromRequest)!=null?y.optimisticFromRequest(d):void 0);x!=null?i.set(R.AsyncResult.loading(x)):i.set(R.AsyncResult.loading(R.AsyncResult.getOrUndefined(v)));try{const w=await t({request:d,abortSignal:g,previous:v});r=void 0,i.set(R.AsyncResult.success(w)),o==null||o(w,d)}catch(w){r=void 0,i.set(R.AsyncResult.failure(e(w))),n==null||n(e(w),d)}s==null||s(i.get(),d)},cancel:d=>{h(),i.set(d??R.AsyncResult.notAsked)},dispose:()=>{r==null||r.abort(),r=void 0,i.dispose()}}},oe=(t,e)=>{const{status:o,dispose:n,execute:s,cancel:r,pending:i,error:c,value:a}=t,{content:u}=e,h=l.previousSignal(a);return l.Fragment(l.OnDispose(n),u({previous:h,execute:s,cancel:r,pending:i,error:c,value:a,status:o}))},je=({mutate:t,convertError:e=i=>i,onSuccess:o,onError:n,onSettled:s,content:r})=>{const i=ne({mutate:t,convertError:e,onSuccess:o,onError:n,onSettled:s});return oe(i,{content:r})},X=Math.min,j=Math.max,ut=Math.round,ct=Math.floor,C=t=>({x:t,y:t}),Ie={left:"right",right:"left",bottom:"top",top:"bottom"},qe={start:"end",end:"start"};function At(t,e,o){return j(t,X(e,o))}function ot(t,e){return typeof t=="function"?t(e):t}function I(t){return t.split("-")[0]}function st(t){return t.split("-")[1]}function se(t){return t==="x"?"y":"x"}function St(t){return t==="y"?"height":"width"}function H(t){return["top","bottom"].includes(I(t))?"y":"x"}function Dt(t){return se(H(t))}function Ye(t,e,o){o===void 0&&(o=!1);const n=st(t),s=Dt(t),r=St(s);let i=s==="x"?n===(o?"end":"start")?"right":"left":n==="start"?"bottom":"top";return e.reference[r]>e.floating[r]&&(i=ft(i)),[i,ft(i)]}function Qe(t){const e=ft(t);return[bt(t),e,bt(e)]}function bt(t){return t.replace(/start|end/g,e=>qe[e])}function Xe(t,e,o){const n=["left","right"],s=["right","left"],r=["top","bottom"],i=["bottom","top"];switch(t){case"top":case"bottom":return o?e?s:n:e?n:s;case"left":case"right":return e?r:i;default:return[]}}function Je(t,e,o,n){const s=st(t);let r=Xe(I(t),o==="start",n);return s&&(r=r.map(i=>i+"-"+s),e&&(r=r.concat(r.map(bt)))),r}function ft(t){return t.replace(/left|right|bottom|top/g,e=>Ie[e])}function Ge(t){return{top:0,right:0,bottom:0,left:0,...t}}function ie(t){return typeof t!="number"?Ge(t):{top:t,right:t,bottom:t,left:t}}function ht(t){const{x:e,y:o,width:n,height:s}=t;return{width:n,height:s,top:o,left:e,right:e+n,bottom:o+s,x:e,y:o}}function Ut(t,e,o){let{reference:n,floating:s}=t;const r=H(e),i=Dt(e),c=St(i),a=I(e),u=r==="y",h=n.x+n.width/2-s.width/2,m=n.y+n.height/2-s.height/2,p=n[c]/2-s[c]/2;let f;switch(a){case"top":f={x:h,y:n.y-s.height};break;case"bottom":f={x:h,y:n.y+n.height};break;case"right":f={x:n.x+n.width,y:m};break;case"left":f={x:n.x-s.width,y:m};break;default:f={x:n.x,y:n.y}}switch(st(e)){case"start":f[i]-=p*(o&&u?-1:1);break;case"end":f[i]+=p*(o&&u?-1:1);break}return f}const Ze=async(t,e,o)=>{const{placement:n="bottom",strategy:s="absolute",middleware:r=[],platform:i}=o,c=r.filter(Boolean),a=await(i.isRTL==null?void 0:i.isRTL(e));let u=await i.getElementRects({reference:t,floating:e,strategy:s}),{x:h,y:m}=Ut(u,n,a),p=n,f={},d=0;for(let y=0;y<c.length;y++){const{name:g,fn:v}=c[y],{x,y:w,data:b,reset:A}=await v({x:h,y:m,initialPlacement:n,placement:p,strategy:s,middlewareData:f,rects:u,platform:i,elements:{reference:t,floating:e}});h=x??h,m=w??m,f={...f,[g]:{...f[g],...b}},A&&d<=50&&(d++,typeof A=="object"&&(A.placement&&(p=A.placement),A.rects&&(u=A.rects===!0?await i.getElementRects({reference:t,floating:e,strategy:s}):A.rects),{x:h,y:m}=Ut(u,p,a)),y=-1)}return{x:h,y:m,placement:p,strategy:s,middlewareData:f}};async function re(t,e){var o;e===void 0&&(e={});const{x:n,y:s,platform:r,rects:i,elements:c,strategy:a}=t,{boundary:u="clippingAncestors",rootBoundary:h="viewport",elementContext:m="floating",altBoundary:p=!1,padding:f=0}=ot(e,t),d=ie(f),g=c[p?m==="floating"?"reference":"floating":m],v=ht(await r.getClippingRect({element:(o=await(r.isElement==null?void 0:r.isElement(g)))==null||o?g:g.contextElement||await(r.getDocumentElement==null?void 0:r.getDocumentElement(c.floating)),boundary:u,rootBoundary:h,strategy:a})),x=m==="floating"?{x:n,y:s,width:i.floating.width,height:i.floating.height}:i.reference,w=await(r.getOffsetParent==null?void 0:r.getOffsetParent(c.floating)),b=await(r.isElement==null?void 0:r.isElement(w))?await(r.getScale==null?void 0:r.getScale(w))||{x:1,y:1}:{x:1,y:1},A=ht(r.convertOffsetParentRelativeRectToViewportRelativeRect?await r.convertOffsetParentRelativeRectToViewportRelativeRect({elements:c,rect:x,offsetParent:w,strategy:a}):x);return{top:(v.top-A.top+d.top)/b.y,bottom:(A.bottom-v.bottom+d.bottom)/b.y,left:(v.left-A.left+d.left)/b.x,right:(A.right-v.right+d.right)/b.x}}const tn=t=>({name:"arrow",options:t,async fn(e){const{x:o,y:n,placement:s,rects:r,platform:i,elements:c,middlewareData:a}=e,{element:u,padding:h=0}=ot(t,e)||{};if(u==null)return{};const m=ie(h),p={x:o,y:n},f=Dt(s),d=St(f),y=await i.getDimensions(u),g=f==="y",v=g?"top":"left",x=g?"bottom":"right",w=g?"clientHeight":"clientWidth",b=r.reference[d]+r.reference[f]-p[f]-r.floating[d],A=p[f]-r.reference[f],P=await(i.getOffsetParent==null?void 0:i.getOffsetParent(u));let O=P?P[w]:0;(!O||!await(i.isElement==null?void 0:i.isElement(P)))&&(O=c.floating[w]||r.floating[d]);const K=b/2-A/2,M=O/2-y[d]/2-1,T=X(m[v],M),B=X(m[x],M),z=T,Z=O-y[d]-B,E=O/2-y[d]/2+K,_=At(z,E,Z),N=!a.arrow&&st(s)!=null&&E!==_&&r.reference[d]/2-(E<z?T:B)-y[d]/2<0,k=N?E<z?E-z:E-Z:0;return{[f]:p[f]+k,data:{[f]:_,centerOffset:E-_-k,...N&&{alignmentOffset:k}},reset:N}}}),en=function(t){return t===void 0&&(t={}),{name:"flip",options:t,async fn(e){var o,n;const{placement:s,middlewareData:r,rects:i,initialPlacement:c,platform:a,elements:u}=e,{mainAxis:h=!0,crossAxis:m=!0,fallbackPlacements:p,fallbackStrategy:f="bestFit",fallbackAxisSideDirection:d="none",flipAlignment:y=!0,...g}=ot(t,e);if((o=r.arrow)!=null&&o.alignmentOffset)return{};const v=I(s),x=H(c),w=I(c)===c,b=await(a.isRTL==null?void 0:a.isRTL(u.floating)),A=p||(w||!y?[ft(c)]:Qe(c)),P=d!=="none";!p&&P&&A.push(...Je(c,y,d,b));const O=[c,...A],K=await re(e,g),M=[];let T=((n=r.flip)==null?void 0:n.overflows)||[];if(h&&M.push(K[v]),m){const E=Ye(s,i,b);M.push(K[E[0]],K[E[1]])}if(T=[...T,{placement:s,overflows:M}],!M.every(E=>E<=0)){var B,z;const E=(((B=r.flip)==null?void 0:B.index)||0)+1,_=O[E];if(_&&(!(m==="alignment"?x!==H(_):!1)||T.every(S=>S.overflows[0]>0&&H(S.placement)===x)))return{data:{index:E,overflows:T},reset:{placement:_}};let N=(z=T.filter(k=>k.overflows[0]<=0).sort((k,S)=>k.overflows[1]-S.overflows[1])[0])==null?void 0:z.placement;if(!N)switch(f){case"bestFit":{var Z;const k=(Z=T.filter(S=>{if(P){const U=H(S.placement);return U===x||U==="y"}return!0}).map(S=>[S.placement,S.overflows.filter(U=>U>0).reduce((U,Ee)=>U+Ee,0)]).sort((S,U)=>S[1]-U[1])[0])==null?void 0:Z[0];k&&(N=k);break}case"initialPlacement":N=c;break}if(s!==N)return{reset:{placement:N}}}return{}}}};async function nn(t,e){const{placement:o,platform:n,elements:s}=t,r=await(n.isRTL==null?void 0:n.isRTL(s.floating)),i=I(o),c=st(o),a=H(o)==="y",u=["left","top"].includes(i)?-1:1,h=r&&a?-1:1,m=ot(e,t);let{mainAxis:p,crossAxis:f,alignmentAxis:d}=typeof m=="number"?{mainAxis:m,crossAxis:0,alignmentAxis:null}:{mainAxis:m.mainAxis||0,crossAxis:m.crossAxis||0,alignmentAxis:m.alignmentAxis};return c&&typeof d=="number"&&(f=c==="end"?d*-1:d),a?{x:f*h,y:p*u}:{x:p*u,y:f*h}}const on=function(t){return t===void 0&&(t=0),{name:"offset",options:t,async fn(e){var o,n;const{x:s,y:r,placement:i,middlewareData:c}=e,a=await nn(e,t);return i===((o=c.offset)==null?void 0:o.placement)&&(n=c.arrow)!=null&&n.alignmentOffset?{}:{x:s+a.x,y:r+a.y,data:{...a,placement:i}}}}},sn=function(t){return t===void 0&&(t={}),{name:"shift",options:t,async fn(e){const{x:o,y:n,placement:s}=e,{mainAxis:r=!0,crossAxis:i=!1,limiter:c={fn:g=>{let{x:v,y:x}=g;return{x:v,y:x}}},...a}=ot(t,e),u={x:o,y:n},h=await re(e,a),m=H(I(s)),p=se(m);let f=u[p],d=u[m];if(r){const g=p==="y"?"top":"left",v=p==="y"?"bottom":"right",x=f+h[g],w=f-h[v];f=At(x,f,w)}if(i){const g=m==="y"?"top":"left",v=m==="y"?"bottom":"right",x=d+h[g],w=d-h[v];d=At(x,d,w)}const y=c.fn({...e,[p]:f,[m]:d});return{...y,data:{x:y.x-o,y:y.y-n,enabled:{[p]:r,[m]:i}}}}}};function pt(){return typeof window<"u"}function G(t){return ce(t)?(t.nodeName||"").toLowerCase():"#document"}function L(t){var e;return(t==null||(e=t.ownerDocument)==null?void 0:e.defaultView)||window}function V(t){var e;return(e=(ce(t)?t.ownerDocument:t.document)||window.document)==null?void 0:e.documentElement}function ce(t){return pt()?t instanceof Node||t instanceof L(t).Node:!1}function D(t){return pt()?t instanceof Element||t instanceof L(t).Element:!1}function F(t){return pt()?t instanceof HTMLElement||t instanceof L(t).HTMLElement:!1}function Ht(t){return!pt()||typeof ShadowRoot>"u"?!1:t instanceof ShadowRoot||t instanceof L(t).ShadowRoot}function it(t){const{overflow:e,overflowX:o,overflowY:n,display:s}=W(t);return/auto|scroll|overlay|hidden|clip/.test(e+n+o)&&!["inline","contents"].includes(s)}function rn(t){return["table","td","th"].includes(G(t))}function yt(t){return[":popover-open",":modal"].some(e=>{try{return t.matches(e)}catch{return!1}})}function Wt(t){const e=Ct(),o=D(t)?W(t):t;return["transform","translate","scale","rotate","perspective"].some(n=>o[n]?o[n]!=="none":!1)||(o.containerType?o.containerType!=="normal":!1)||!e&&(o.backdropFilter?o.backdropFilter!=="none":!1)||!e&&(o.filter?o.filter!=="none":!1)||["transform","translate","scale","rotate","perspective","filter"].some(n=>(o.willChange||"").includes(n))||["paint","layout","strict","content"].some(n=>(o.contain||"").includes(n))}function cn(t){let e=$(t);for(;F(e)&&!J(e);){if(Wt(e))return e;if(yt(e))return null;e=$(e)}return null}function Ct(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function J(t){return["html","body","#document"].includes(G(t))}function W(t){return L(t).getComputedStyle(t)}function wt(t){return D(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.scrollX,scrollTop:t.scrollY}}function $(t){if(G(t)==="html")return t;const e=t.assignedSlot||t.parentNode||Ht(t)&&t.host||V(t);return Ht(e)?e.host:e}function ae(t){const e=$(t);return J(e)?t.ownerDocument?t.ownerDocument.body:t.body:F(e)&&it(e)?e:ae(e)}function et(t,e,o){var n;e===void 0&&(e=[]),o===void 0&&(o=!0);const s=ae(t),r=s===((n=t.ownerDocument)==null?void 0:n.body),i=L(s);if(r){const c=Ot(i);return e.concat(i,i.visualViewport||[],it(s)?s:[],c&&o?et(c):[])}return e.concat(s,et(s,[],o))}function Ot(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}function le(t){const e=W(t);let o=parseFloat(e.width)||0,n=parseFloat(e.height)||0;const s=F(t),r=s?t.offsetWidth:o,i=s?t.offsetHeight:n,c=ut(o)!==r||ut(n)!==i;return c&&(o=r,n=i),{width:o,height:n,$:c}}function Ft(t){return D(t)?t:t.contextElement}function Q(t){const e=Ft(t);if(!F(e))return C(1);const o=e.getBoundingClientRect(),{width:n,height:s,$:r}=le(e);let i=(r?ut(o.width):o.width)/n,c=(r?ut(o.height):o.height)/s;return(!i||!Number.isFinite(i))&&(i=1),(!c||!Number.isFinite(c))&&(c=1),{x:i,y:c}}const an=C(0);function ue(t){const e=L(t);return!Ct()||!e.visualViewport?an:{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}}function ln(t,e,o){return e===void 0&&(e=!1),!o||e&&o!==L(t)?!1:e}function q(t,e,o,n){e===void 0&&(e=!1),o===void 0&&(o=!1);const s=t.getBoundingClientRect(),r=Ft(t);let i=C(1);e&&(n?D(n)&&(i=Q(n)):i=Q(t));const c=ln(r,o,n)?ue(r):C(0);let a=(s.left+c.x)/i.x,u=(s.top+c.y)/i.y,h=s.width/i.x,m=s.height/i.y;if(r){const p=L(r),f=n&&D(n)?L(n):n;let d=p,y=Ot(d);for(;y&&n&&f!==d;){const g=Q(y),v=y.getBoundingClientRect(),x=W(y),w=v.left+(y.clientLeft+parseFloat(x.paddingLeft))*g.x,b=v.top+(y.clientTop+parseFloat(x.paddingTop))*g.y;a*=g.x,u*=g.y,h*=g.x,m*=g.y,a+=w,u+=b,d=L(y),y=Ot(d)}}return ht({width:h,height:m,x:a,y:u})}function Vt(t,e){const o=wt(t).scrollLeft;return e?e.left+o:q(V(t)).left+o}function fe(t,e,o){o===void 0&&(o=!1);const n=t.getBoundingClientRect(),s=n.left+e.scrollLeft-(o?0:Vt(t,n)),r=n.top+e.scrollTop;return{x:s,y:r}}function un(t){let{elements:e,rect:o,offsetParent:n,strategy:s}=t;const r=s==="fixed",i=V(n),c=e?yt(e.floating):!1;if(n===i||c&&r)return o;let a={scrollLeft:0,scrollTop:0},u=C(1);const h=C(0),m=F(n);if((m||!m&&!r)&&((G(n)!=="body"||it(i))&&(a=wt(n)),F(n))){const f=q(n);u=Q(n),h.x=f.x+n.clientLeft,h.y=f.y+n.clientTop}const p=i&&!m&&!r?fe(i,a,!0):C(0);return{width:o.width*u.x,height:o.height*u.y,x:o.x*u.x-a.scrollLeft*u.x+h.x+p.x,y:o.y*u.y-a.scrollTop*u.y+h.y+p.y}}function fn(t){return Array.from(t.getClientRects())}function hn(t){const e=V(t),o=wt(t),n=t.ownerDocument.body,s=j(e.scrollWidth,e.clientWidth,n.scrollWidth,n.clientWidth),r=j(e.scrollHeight,e.clientHeight,n.scrollHeight,n.clientHeight);let i=-o.scrollLeft+Vt(t);const c=-o.scrollTop;return W(n).direction==="rtl"&&(i+=j(e.clientWidth,n.clientWidth)-s),{width:s,height:r,x:i,y:c}}function dn(t,e){const o=L(t),n=V(t),s=o.visualViewport;let r=n.clientWidth,i=n.clientHeight,c=0,a=0;if(s){r=s.width,i=s.height;const u=Ct();(!u||u&&e==="fixed")&&(c=s.offsetLeft,a=s.offsetTop)}return{width:r,height:i,x:c,y:a}}function mn(t,e){const o=q(t,!0,e==="fixed"),n=o.top+t.clientTop,s=o.left+t.clientLeft,r=F(t)?Q(t):C(1),i=t.clientWidth*r.x,c=t.clientHeight*r.y,a=s*r.x,u=n*r.y;return{width:i,height:c,x:a,y:u}}function $t(t,e,o){let n;if(e==="viewport")n=dn(t,o);else if(e==="document")n=hn(V(t));else if(D(e))n=mn(e,o);else{const s=ue(t);n={x:e.x-s.x,y:e.y-s.y,width:e.width,height:e.height}}return ht(n)}function he(t,e){const o=$(t);return o===e||!D(o)||J(o)?!1:W(o).position==="fixed"||he(o,e)}function gn(t,e){const o=e.get(t);if(o)return o;let n=et(t,[],!1).filter(c=>D(c)&&G(c)!=="body"),s=null;const r=W(t).position==="fixed";let i=r?$(t):t;for(;D(i)&&!J(i);){const c=W(i),a=Wt(i);!a&&c.position==="fixed"&&(s=null),(r?!a&&!s:!a&&c.position==="static"&&!!s&&["absolute","fixed"].includes(s.position)||it(i)&&!a&&he(t,i))?n=n.filter(h=>h!==i):s=c,i=$(i)}return e.set(t,n),n}function pn(t){let{element:e,boundary:o,rootBoundary:n,strategy:s}=t;const i=[...o==="clippingAncestors"?yt(e)?[]:gn(e,this._c):[].concat(o),n],c=i[0],a=i.reduce((u,h)=>{const m=$t(e,h,s);return u.top=j(m.top,u.top),u.right=X(m.right,u.right),u.bottom=X(m.bottom,u.bottom),u.left=j(m.left,u.left),u},$t(e,c,s));return{width:a.right-a.left,height:a.bottom-a.top,x:a.left,y:a.top}}function yn(t){const{width:e,height:o}=le(t);return{width:e,height:o}}function wn(t,e,o){const n=F(e),s=V(e),r=o==="fixed",i=q(t,!0,r,e);let c={scrollLeft:0,scrollTop:0};const a=C(0);function u(){a.x=Vt(s)}if(n||!n&&!r)if((G(e)!=="body"||it(s))&&(c=wt(e)),n){const f=q(e,!0,r,e);a.x=f.x+e.clientLeft,a.y=f.y+e.clientTop}else s&&u();r&&!n&&s&&u();const h=s&&!n&&!r?fe(s,c):C(0),m=i.left+c.scrollLeft-a.x-h.x,p=i.top+c.scrollTop-a.y-h.y;return{x:m,y:p,width:i.width,height:i.height}}function xt(t){return W(t).position==="static"}function Kt(t,e){if(!F(t)||W(t).position==="fixed")return null;if(e)return e(t);let o=t.offsetParent;return V(t)===o&&(o=o.ownerDocument.body),o}function de(t,e){const o=L(t);if(yt(t))return o;if(!F(t)){let s=$(t);for(;s&&!J(s);){if(D(s)&&!xt(s))return s;s=$(s)}return o}let n=Kt(t,e);for(;n&&rn(n)&&xt(n);)n=Kt(n,e);return n&&J(n)&&xt(n)&&!Wt(n)?o:n||cn(t)||o}const vn=async function(t){const e=this.getOffsetParent||de,o=this.getDimensions,n=await o(t.floating);return{reference:wn(t.reference,await e(t.floating),t.strategy),floating:{x:0,y:0,width:n.width,height:n.height}}};function xn(t){return W(t).direction==="rtl"}const Rn={convertOffsetParentRelativeRectToViewportRelativeRect:un,getDocumentElement:V,getClippingRect:pn,getOffsetParent:de,getElementRects:vn,getClientRects:fn,getDimensions:yn,getScale:Q,isElement:D,isRTL:xn};function me(t,e){return t.x===e.x&&t.y===e.y&&t.width===e.width&&t.height===e.height}function An(t,e){let o=null,n;const s=V(t);function r(){var c;clearTimeout(n),(c=o)==null||c.disconnect(),o=null}function i(c,a){c===void 0&&(c=!1),a===void 0&&(a=1),r();const u=t.getBoundingClientRect(),{left:h,top:m,width:p,height:f}=u;if(c||e(),!p||!f)return;const d=ct(m),y=ct(s.clientWidth-(h+p)),g=ct(s.clientHeight-(m+f)),v=ct(h),w={rootMargin:-d+"px "+-y+"px "+-g+"px "+-v+"px",threshold:j(0,X(1,a))||1};let b=!0;function A(P){const O=P[0].intersectionRatio;if(O!==a){if(!b)return i();O?i(!1,O):n=setTimeout(()=>{i(!1,1e-7)},1e3)}O===1&&!me(u,t.getBoundingClientRect())&&i(),b=!1}try{o=new IntersectionObserver(A,{...w,root:s.ownerDocument})}catch{o=new IntersectionObserver(A,w)}o.observe(t)}return i(!0),r}function bn(t,e,o,n){n===void 0&&(n={});const{ancestorScroll:s=!0,ancestorResize:r=!0,elementResize:i=typeof ResizeObserver=="function",layoutShift:c=typeof IntersectionObserver=="function",animationFrame:a=!1}=n,u=Ft(t),h=s||r?[...u?et(u):[],...et(e)]:[];h.forEach(v=>{s&&v.addEventListener("scroll",o,{passive:!0}),r&&v.addEventListener("resize",o)});const m=u&&c?An(u,o):null;let p=-1,f=null;i&&(f=new ResizeObserver(v=>{let[x]=v;x&&x.target===u&&f&&(f.unobserve(e),cancelAnimationFrame(p),p=requestAnimationFrame(()=>{var w;(w=f)==null||w.observe(e)})),o()}),u&&!a&&f.observe(u),f.observe(e));let d,y=a?q(t):null;a&&g();function g(){const v=q(t);y&&!me(y,v)&&o(),y=v,d=requestAnimationFrame(g)}return o(),()=>{var v;h.forEach(x=>{s&&x.removeEventListener("scroll",o),r&&x.removeEventListener("resize",o)}),m==null||m(),(v=f)==null||v.disconnect(),f=null,a&&cancelAnimationFrame(d)}}const On=on,En=sn,Bt=en,Ln=tn,Pn=(t,e,o)=>{const n=new Map,s={platform:Rn,...o},r={...s.platform,_c:n};return Ze(t,e,{...s,platform:r})},Tn=["top","top-start","top-end","right","right-start","right-end","bottom","bottom-start","bottom-end","left","left-start","left-end"],kn=(t,e={isOpen:!1})=>{const o=[];let n=null;const s=l.Value.deriveProp(e.isOpen);function r(c){n=c,s.set(!0)}function i(){s.set(!1),o.forEach(c=>c()),o.length=0}return l.Fragment(t(r,i),l.When(s,()=>l.Fragment((n==null?void 0:n.onClickOutside)!=null?te(n.onClickOutside):null,l.WithElement(c=>l.Portal("body",l.html.div(l.WithElement(a=>{a.style.position="absolute";const u=typeof(n==null?void 0:n.target)=="string"?c.querySelector(n.target):(n==null?void 0:n.target)??c;if(u==null)throw new Error(`Target not found: ${n==null?void 0:n.target}`);let h=null;const m=l.Value.toSignal((n==null?void 0:n.mainAxisOffset)??0),p=l.Value.toSignal((n==null?void 0:n.crossAxisOffset)??0),f=l.Value.toSignal((n==null?void 0:n.placement)??"top"),d=l.Value.toSignal((n==null?void 0:n.arrowPadding)??0),y=n==null?void 0:n.arrow,g=l.prop({centerOffset:0,alignmentOffset:0,containerWidth:0,containerHeight:0,x:void 0,y:void 0});async function v(){const w=[Bt(),On({mainAxis:m.get(),crossAxis:p.get()}),En(),Bt()];y!=null&&h!=null&&w.push(Ln({element:h,padding:d.get()}));const b=await Pn(u,a,{placement:f.get(),strategy:"absolute",middleware:w}),{x:A,y:P,middlewareData:O}=b;if(a.style.top=`${P}px`,a.style.left=`${A}px`,h!=null&&O.arrow!=null){const{x:K,y:M,centerOffset:T,alignmentOffset:B}=O.arrow;g.set({x:K,y:M,centerOffset:T,alignmentOffset:B,containerWidth:a.offsetWidth,containerHeight:a.offsetHeight})}}const x=l.effectOf(m,p,f)(v);return l.Fragment(n==null?void 0:n.content,(n==null?void 0:n.arrow)!=null?l.html.div(n==null?void 0:n.arrow(l.computedOf(g,f)((w,b)=>({...w,placement:b}))),l.WithElement(w=>{h=w,v()})):null,l.OnDispose(g.dispose,bn(u,a,v),x))})))))))},ge=({request:t,load:e,convertError:o,onSuccess:n,onError:s,onSettled:r})=>{let i;const c=l.prop(R.AsyncResult.notAsked),a=c.map(g=>R.AsyncResult.isSuccess(g)?g.value:void 0),u=c.map(g=>R.AsyncResult.isFailure(g)?g.error:void 0),h=c.map(g=>R.AsyncResult.isLoading(g)),m=()=>{i==null||i.abort(),i=void 0},p=g=>{m(),c.set(g??R.AsyncResult.notAsked)},f=async g=>{m(),i=new AbortController;const v=i.signal,x=c.get();c.set(R.AsyncResult.loading(R.AsyncResult.getOrUndefined(x)));try{const w=await e({request:g,abortSignal:v,previous:x});await Promise.resolve(),i=void 0,c.set(R.AsyncResult.success(w)),n==null||n(w,g)}catch(w){i=void 0,c.set(R.AsyncResult.failure(o(w))),s==null||s(o(w),g)}r==null||r(c.get(),g)},d=()=>f(l.Value.get(t)),y=()=>{i==null||i.abort(),i=void 0,c.dispose()};return c.onDispose(l.Value.on(t,f)),{status:c,value:a,error:u,loading:h,cancel:p,reload:d,dispose:y}},pe=(t,e)=>{const{status:o,dispose:n,reload:s}=t,{pending:r,failure:i,success:c}=e;return l.Fragment(l.OnDispose(n),Tt(o,{loading:r!=null?a=>r({previous:a,reload:s,cancel:t.cancel}):void 0,failure:i!=null?a=>i({error:a,reload:s}):void 0,success:a=>c({value:a,reload:s})}))},Sn=({request:t,load:e,convertError:o=u=>u,onSuccess:n,onError:s,onSettled:r,success:i,pending:c,failure:a})=>{const u=ge({request:t,load:e,convertError:o,onSuccess:n,onError:s,onSettled:r});return pe(u,{success:i,pending:c,failure:a})},ye=(t,e)=>{if(typeof e=="function")return ye(t,{success:e});const o=e.failure??(s=>l.Fragment(l.OnDispose(s.on(console.error)),s.map(r=>`Error: ${r}`))),n=e.success;return l.OneOfType(l.Value.toSignal(t),{Success:s=>n(s.$.value),Failure:s=>o(s.$.error)})},Dn=()=>l.on.focus(t=>{var e;return(e=t.target)==null?void 0:e.select()});class rt{constructor(e,o,n,s,r,i){vt(this,"equals",e=>R.nearEqual(this.left,e.left)&&R.nearEqual(this.top,e.top)&&R.nearEqual(this.width,e.width)&&R.nearEqual(this.height,e.height));this.left=e,this.top=o,this.width=n,this.height=s,this.localLeft=r,this.localTop=i}static of({left:e=0,top:o=0,width:n=0,height:s=0,localLeft:r=0,localTop:i=0}){return new rt(e,o,n,s,r,i)}get right(){return this.left+this.width}get bottom(){return this.top+this.height}get center(){return{x:this.left+this.width/2,y:this.top+this.height/2}}get localCenter(){return{x:this.localLeft+this.width/2,y:this.localTop+this.height/2}}get localBottom(){return this.localTop+this.height}get localRight(){return this.localLeft+this.width}get size(){return{width:this.width,height:this.height}}}function Et(t){const e=t.getBoundingClientRect();return rt.of({top:e.top+window.scrollY,left:e.left+window.scrollX,width:e.width,height:e.height,localLeft:t.offsetLeft,localTop:t.offsetTop})}const Wn=t=>l.WithBrowserCtx(e=>{const{element:o}=e,n=l.prop(Et(o),(c,a)=>c.equals(a)),s=l.renderableOfTNode(t(n))(e),r=()=>n.set(rt.of(Et(o)));let i=null;return typeof ResizeObserver<"u"&&(i=new ResizeObserver(r)),i==null||i.observe(o),l.OnDispose(c=>{i==null||i.disconnect(),s(c)})});function zt(t){return{width:(t==null?void 0:t.innerWidth)??0,height:(t==null?void 0:t.innerHeight)??0}}const Cn=t=>e=>{const o=l.getWindow(),n=l.prop(zt(o),(i,c)=>i.width===c.width&&i.height===c.height),s=l.renderableOfTNode(t(n))(e),r=()=>n.set(zt(o));return o==null||o.addEventListener("resize",r),i=>{o==null||o.removeEventListener("resize",r),s(i)}},we=(t,e)=>{const o=e.split("/").filter(s=>s!==""),n={};for(let s=0;s<t.length;s++){const r=t[s],i=o[s];if(!i&&r.type!=="catch-all")return null;if(r.type==="literal"){if(r.value!==i)return null}else if(r.type==="param")n[r.name]=i;else if(r.type==="catch-all")return{params:n,path:e}}return o.length!==t.length?null:{params:n,path:e}},Mt=t=>t.split("/").map(e=>e.startsWith(":")?{type:"param",name:e.slice(1)}:e==="*"?{type:"catch-all"}:{type:"literal",value:e}).filter(e=>e.type!=="literal"||e.value!==""),Fn=t=>{const e=t.map(o=>{const n=Mt(o);return{route:o,segments:n}});return function(n){for(const{segments:s,route:r}of e){const i=we(s,n);if(i)return{...i,route:r}}return null}},dt={mark:l.makeProviderMark("RouterContext"),create:()=>{const t=l.prop([]);return{value:t,dispose:()=>t.dispose()}}},Vn=(t,e,o)=>{const n=o.split("/").filter(i=>i!==""),s={};let r=0;for(let i=0;i<t.length;i++){const c=t[i],a=n[i];if(!a&&c.type!=="catch-all")return null;if(c.type==="literal"){if(c.value!==a)return null;r++}else if(c.type==="param")s[c.name]=a,r++;else if(c.type==="catch-all"){const u="/"+n.slice(0,r).join("/"),h="/"+n.slice(r).join("/");return{params:s,matchedPath:u==="/"?"":u,remainingPath:h==="/"?"":h,route:e}}}if(n.length===t.length){const i="/"+n.join("/");return{params:s,matchedPath:i==="/"?"":i,remainingPath:"",route:e}}return null},ve=t=>{const e=t.map(o=>{const n=Mt(o);return{route:o,segments:n}});return function(n){for(const{segments:s,route:r}of e){const i=Vn(s,r,n);if(i)return i}return null}},Mn=t=>{const e=ve(Object.keys(t));return l.Provide(dt,{},()=>l.Use(gt,o=>l.Use(dt,n=>{const s=o.map(r=>{const i=e(r.pathname);if(i==null)throw console.error("No route found for",r),new Error("No route found");const c={matchedPath:i.matchedPath,remainingPath:i.remainingPath,fullPath:r.pathname,params:i.params};return n.value=[...n.value,c],{params:i.params,route:i.route,path:i.matchedPath||r.pathname,search:r.search,hash:r.hash}});return l.OneOfTuple(s.map(r=>[r.route,r]),t)})))},Nn=t=>{const e=ve(Object.keys(t));return l.Use(dt,o=>l.Use(gt,n=>{const s=o.map(r=>{const i=r[r.length-1],c=(i==null?void 0:i.remainingPath)||"";if(c==="")throw console.error("No remaining path for SubRouter",r),new Error("No remaining path for SubRouter");const a=e(c);if(a==null)throw console.error("No route found for remaining path",c),new Error("No route found");return{params:a.params,route:a.route,path:a.matchedPath,search:n.value.search,hash:n.value.hash}});return l.OneOfTuple(s.map(r=>[r.route,r]),t)}))},mt=60*1e3,Lt=60*mt,nt=24*Lt,_t=7*nt,jt=30*nt,Un=365*nt,Hn=[{max:mt*90,value:mt,name:"minute",past:{singular:"a minute ago",plural:"{} minutes ago"},future:{singular:"in a minute",plural:"in {} minutes"}},{max:Lt*36,value:Lt,name:"hour",past:{singular:"an hour ago",plural:"{} hours ago"},future:{singular:"in an hour",plural:"in {} hours"}},{max:nt*10,value:nt,name:"day",past:{singular:"yesterday",plural:"{} days ago"},future:{singular:"tomorrow",plural:"in {} days"}},{max:_t*6,value:_t,name:"week",past:{singular:"last week",plural:"{} weeks ago"},future:{singular:"in a week",plural:"in {} weeks"}},{max:jt*18,value:jt,name:"month",past:{singular:"last month",plural:"{} months ago"},future:{singular:"in a month",plural:"in {} months"}},{max:1/0,value:Un,name:"year",past:{singular:"last year",plural:"{} years ago"},future:{singular:"in a year",plural:"in {} years"}}];function It(t,e,o,n){const s=Math.round(t/e);return s<=1?o:n.replace("{}",s.toLocaleString(void 0,{maximumFractionDigits:0,minimumFractionDigits:0}))}const xe=(t=1e3)=>{const e=l.prop(new Date),o=R.interval(()=>e.set(new Date),t);return e.onDispose(o),e},Re=t=>{const e=Math.abs(t);if(e<mt)return t<0?"just now":"in a moment";for(const o of Hn)if(e<o.max)return t<0?It(e,o.value,o.past.singular,o.past.plural):It(e,o.value,o.future.singular,o.future.plural);throw new Error("unreachable")},Ae=(t,{now:e,frequency:o=1e4}={})=>{const n=e!=null?l.Signal.is(e)?e.derive():l.prop(e):xe(o),s=l.computedOf(t,n)((r,i)=>r.getTime()-i.getTime());return s.onDispose(()=>l.Value.dispose(n)),s},be=(t,e={})=>{const o=Ae(t,e),n=o.map(Re);return n.onDispose(o.dispose),n},$n=(t,e={})=>be(t,e);class Oe extends l.Prop{constructor(){super(...arguments);vt(this,"tick",()=>this.update(o=>o+1))}}const Kn=(t=0)=>new Oe(t,(e,o)=>e===o);exports.Anchor=Jt;exports.Appearance=Fe;exports.AsyncResultView=Tt;exports.AutoFocus=Ve;exports.AutoSelect=Me;exports.ChildRouter=Nn;exports.ElementRect=Wn;exports.HTMLTitle=He;exports.HiddenWhenEmpty=Ue;exports.InViewport=Zt;exports.Location=gt;exports.Mutation=je;exports.MutationDisplay=oe;exports.OnClickOutside=te;exports.OnEnterKey=ze;exports.OnEscapeKey=_e;exports.OnKeyPressed=kt;exports.PopOver=kn;exports.Query=Sn;exports.QueryDisplay=pe;exports.Rect=rt;exports.ResultView=ye;exports.RootRouter=Mn;exports.RouterContextProvider=dt;exports.SelectOnFocus=Dn;exports.Ticker=Oe;exports.WhenInViewport=Be;exports.WindowSize=Cn;exports._checkExtensionCondition=Yt;exports._getExtension=qt;exports._makeRouteMatcher=Fn;exports._parseRouteSegments=Mt;exports.allPlacements=Tn;exports.areLocationsEqual=Xt;exports.classes=Ne;exports.getAbsoluteRect=Et;exports.handleAnchorClick=Qt;exports.locationFromURL=Pt;exports.makeMutationResource=ne;exports.makeQueryResource=ge;exports.matchesKeyCombo=ee;exports.matchesRoute=we;exports.nowSignal=xe;exports.relativeTime=$n;exports.relativeTimeMillisSignal=Ae;exports.relativeTimeSignal=be;exports.setLocationFromUrl=Rt;exports.ticker=Kn;exports.timeDiffToString=Re;exports.urlFromLocation=lt;exports.useAppearance=Gt;
1
+ "use strict";var De=Object.defineProperty;var We=(t,e,o)=>e in t?De(t,e,{enumerable:!0,configurable:!0,writable:!0,value:o}):t[e]=o;var Rt=(t,e,o)=>We(t,typeof e!="symbol"?e+"":e,o);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const u=require("@tempots/dom"),O=require("@tempots/std"),Jt=t=>{const e=t.split("/").pop();if(e==null||e.startsWith("."))return;const o=e.split(".")||[];return o.length>1?"."+o.pop():void 0},Gt=(t,e)=>{const o=Jt(e);return o!=null&&(t.length===0||!t.some(n=>o==n))},Ce=(t,e,o,n)=>{let r=t.target;for(;r!=null&&!(r instanceof HTMLAnchorElement);)r=r.parentElement;if(r==null)return!0;const i=r;if(t.button!==0||t.ctrlKey||t.metaKey||i.target!=="_self"&&i.target!==""||i.getAttribute("download")!=null)return!0;const{pathname:s,search:c,hash:a}=i;if(n){const l=s+c+a,f=i.getAttribute("href");if(!(f!=null&&f.startsWith("#"))&&f!==l)return!0}return e?!1:Gt(o,s)},Zt=(t,e={ignoreUrlWithExtension:!0,allowedExtensions:[],ignoreExternalUrl:!0})=>{const o=e.ignoreUrlWithExtension===!0&&Array.isArray(e.allowedExtensions)?e.allowedExtensions.map(n=>n.startsWith(".")?n:"."+n):[];return n=>{Ce(n,e.ignoreUrlWithExtension??!0,o,e.ignoreExternalUrl??!0)||t()&&n.preventDefault()}},te=(t,e)=>t.pathname===e.pathname&&JSON.stringify(t.search)===JSON.stringify(e.search)&&t.hash===e.hash,ft=(t,e)=>{var i,s;const o=new URL(t,e??((i=u.getWindow())==null?void 0:i.location.toString())),n=Object.fromEntries(((s=o.searchParams)==null?void 0:s.entries())??[]);let r=o.hash;return r.startsWith("#")&&(r=r.substring(1)),{pathname:o.pathname,search:n,hash:r===""?void 0:r}},nt=t=>{const o=new URLSearchParams(t.search).toString(),n=t.hash;return`${t.pathname}${o?`?${o}`:""}${n?`#${n}`:""}`},Fe=t=>{document.startViewTransition?document.startViewTransition(t):t()},Ht=()=>{const t=u.getWindow(),e=(t==null?void 0:t.location.hash)??"";return{pathname:(t==null?void 0:t.location.pathname)??"",search:Object.fromEntries(new URLSearchParams((t==null?void 0:t.location.search)??"").entries()),hash:e.startsWith("#")?e.substring(1)||void 0:e===""?void 0:e}},_t=t=>{if((t==null?void 0:t.scroll)!=="auto")return;const e=u.getWindow();e&&e.requestAnimationFrame(()=>e.scrollTo({top:0,left:0,behavior:"auto"}))},$t=(t,e)=>{e!=null&&e.viewTransition?Fe(t):t()},Me=()=>{const t=u.prop(Ht(),te),e=u.getWindow(),o=()=>{t.set(Ht())};e==null||e.addEventListener("popstate",o),e==null||e.addEventListener("hashchange",o);const n=(a,l,f)=>{$t(()=>{if(e){const d=nt(a),y=(l==null?void 0:l.state)??{};f==="replaceState"||l!=null&&l.replace?e.history.replaceState(y,"",d):e.history.pushState(y,"",d)}t.set(a)},l),_t(l)},r=(a,l)=>{$t(()=>{e==null||e.history.go(a)},l),_t(l)};return{location:t,commit:n,go:r,back:a=>r(-1,a),forward:a=>r(1,a),resolve:a=>ft(a),dispose:()=>{e==null||e.removeEventListener("popstate",o),e==null||e.removeEventListener("hashchange",o),t.dispose()}}},Ve=t=>t.startsWith("http://")||t.startsWith("https://")||t.startsWith("//"),Ne=t=>{const e=t.container.currentURL,o=e.iso(s=>ft(s,e.value),s=>{if(Ve(s.pathname))return nt(s);const c=new URL(s.pathname,e.value),a=c.origin+c.pathname;return nt({...s,pathname:a})});return{location:o,dispose:()=>{o.dispose()},commit:(s,c,a)=>{o.set(s)},go:(s,c)=>{},back:s=>{},forward:s=>{},resolve:s=>ft(s,e.value)}},tt=t=>({pathname:t.pathname,search:{...t.search},hash:t.hash??void 0}),At=t=>{if(t==null)return;const e=`${t}`;return e===""?void 0:e},ee=(t,e)=>{const o={...t};for(const[n,r]of Object.entries(e))r==null?delete o[n]:o[n]=r;return o};class He{constructor(e){this.current=e}get location(){return this.current}setLocation(e){return this.current=tt(e),this}setPathname(e){return this.current={...this.current,pathname:e},this}setHash(e){const o=At(e);if(o==null){const{hash:n,...r}=this.current;this.current=r}else this.current={...this.current,hash:o};return this}clearHash(){const{hash:e,...o}=this.current;return this.current=o,this}setSearch(e){return this.current={...this.current,search:ee(this.current.search,e)},this}setSearchParam(e,o){return this.setSearch({[e]:o})}updateSearch(e){return this.current={...this.current,search:{...e({...this.current.search})}},this}}const _e=(t,e)=>t!=null&&t.replace?"replaceState":e,$e=t=>{const e=t.location,o=e.map(nt),n=e.map(g=>g.pathname),r=e.map(g=>({...g.search})),i=e.map(g=>g.hash),s=(g,b,A)=>{const S=tt({...g,hash:At(g.hash??void 0)});t.commit(S,b,A)},c=(g,b)=>{const A=_e(b,"pushState");s(g,b,A)},a=(g,b)=>{const A=g(tt(t.location.value));c(A,b)},l=(g,b)=>{const A=t.resolve(g);c(A,b)},f=(g,b)=>{const A={...b,replace:!0};l(g,A)},d=(g,b)=>{t.go(g,b)},y=g=>{t.back(g)},h=g=>{t.forward(g)},m=(g,b)=>a(A=>({...A,pathname:g}),b),w=(g,b)=>a(A=>{const S={...A},M=At(g);return M==null?delete S.hash:S.hash=M,S},b),p=g=>w(void 0,g),v=(g,b)=>a(A=>({...A,search:ee(A.search,g)}),b);return{handle:{location:e,url:o,pathname:n,search:r,hash:i,setLocation:c,updateLocation:a,navigate:l,replace:f,go:d,back:y,forward:h,setPathname:m,setHash:w,clearHash:p,setSearch:v,setSearchParam:(g,b,A)=>v({[g]:b},A),updateSearch:(g,b)=>a(A=>({...A,search:{...g({...A.search})}}),b),queryParam:g=>e.map(b=>b.search[g]),run:(g,b)=>{const A=new He(tt(t.location.value));g(A),c(tt(A.location),b)}},dispose:()=>{t.dispose(),o.dispose(),n.dispose(),r.dispose(),i.dispose()}}},ze=t=>{if(t.isBrowser())return Me();if(t.isHeadless())return Ne(t);throw new Error("Unknown context")},yt={mark:u.makeProviderMark("Location"),create:(t,e)=>{const o=ze(e),{handle:n,dispose:r}=$e(o);return{value:n,dispose:r}}},ne=(t,...e)=>{if(typeof t=="string"||u.Signal.is(t))return ne({href:t},...e);const{href:o,state:n,scroll:r,viewTransition:i,replace:s,...c}=t;return u.Use(yt,a=>u.html.a(u.on.click(Zt(()=>{let l=!1;const f={};return n!==void 0&&(f.state=n,l=!0),r!==void 0&&(f.scroll=r,l=!0),i!==void 0&&(f.viewTransition=i,l=!0),s!==void 0&&(f.replace=s,l=!0),a.navigate(u.Value.get(o),l?f:void 0),!0},c)),u.attr.href(o),...e))},Ue={mark:u.makeProviderMark("Appearance"),create:()=>{const t=oe();return{value:t,dispose:t.dispose}}};function oe(){const t=u.getWindow(),e=t!=null&&t.matchMedia!=null?t.matchMedia("(prefers-color-scheme: dark)"):void 0,o=(e==null?void 0:e.matches)??!1,n=u.prop(o?"dark":"light"),r=i=>n.set(i.matches?"dark":"light");return e==null||e.addEventListener("change",r),n.onDispose(()=>e==null?void 0:e.removeEventListener("change",r)),n}const Tt=(t,e)=>{if(typeof e=="function")return Tt(t,{success:e});const o=e.failure??(s=>s.map(c=>`Error: ${c}`)),n=e.success,r=e.loading??(()=>u.Empty),i=e.notAsked??(()=>u.Empty);return u.OneOfType(u.Value.toSignal(t),{AsyncSuccess:s=>n(s.$.value),AsyncFailure:s=>o(s.$.error),Loading:s=>r(s.map(c=>c.previousValue)),NotAsked:i})},Ke=(t=10)=>u.WithElement(e=>u.OnDispose(O.delayed(()=>e==null?void 0:e.focus(),t))),Be=(t=10)=>u.WithElement(e=>{const o=O.delayed(()=>e.select(),t);return u.OnDispose(o)});function je(t){const e=Object.entries(t);return u.Fragment(...e.map(([o,n])=>u.attr.class(u.Value.map(n,r=>r?o:void 0))))}const Ie=u.WithElement(t=>{const e=t.style.getPropertyValue(":empty");return t.style.setProperty(":empty","display:none"),u.OnDispose(o=>{o&&t.style.setProperty(":empty",e)})}),qe=t=>u.Portal("head > title",u.attr.innerText(t)),Ye={partial:{root:null,rootMargin:"0px",threshold:0},full:{root:null,rootMargin:"0px",threshold:1}},ut={partial:new Map,full:new Map},et={partial:null,full:null};function Qe(t){return et[t]==null&&(et[t]=new IntersectionObserver(e=>{e.forEach(o=>{const n=ut[t].get(o.target);n==null||n.set(o.isIntersecting)})},Ye[t])),et[t]}const se=({mode:t="partial",once:e=!1},o)=>{const n=u.prop(!1);return u.Fragment(u.WithElement(r=>{const i=typeof IntersectionObserver<"u"?Qe(t):null;ut[t].set(r,n),i==null||i.observe(r);function s(){var a;i==null||i.unobserve(r),ut[t].delete(r),ut[t].size===0&&((a=et[t])==null||a.disconnect(),et[t]=null)}let c=null;return e&&(c=n.on(a=>{a&&s()})),u.OnDispose(()=>{n.dispose(),s(),c==null||c()})}),u.renderableOfTNode(o(n)))},Xe=(t,e,o)=>se(t,n=>u.When(n,e,o??(()=>u.Empty)));function re(t){return u.WithElement(e=>{const o=n=>{e.contains(n.target)||t(n)};return document.addEventListener("click",o),u.OnDispose(()=>{document.removeEventListener("click",o)})})}const Y=(t,e)=>t===void 0||t===e,zt=(t,e)=>t===void 0||t===e;function ie(t,e){return typeof t=="string"?e.key===t:zt(t.key,e.key)&&zt(t.code,e.code)&&Y(t.ctrlKey,e.ctrlKey)&&Y(t.altKey,e.altKey)&&Y(t.shiftKey,e.shiftKey)&&Y(t.metaKey,e.metaKey)&&Y(t.repeat,e.repeat)&&Y(t.commandOrControlKey,e.metaKey||e.ctrlKey)}function kt({allowedKeys:t,handler:e}){return u.WithElement(o=>{const n=r=>{if(o.contains(r.target)){for(const i of t)if(ie(i,r)){e(r);break}}};return document.addEventListener("keydown",n),u.OnDispose(()=>{document.removeEventListener("keydown",n)})})}function Je(t){return kt({allowedKeys:["Enter"],handler:t})}function Ge(t){return kt({allowedKeys:["Escape"],handler:t})}const ce=({mutate:t,convertError:e,onSuccess:o,onError:n,onSettled:r})=>{let i;const s=u.prop(O.AsyncResult.notAsked),c=s.map(m=>O.AsyncResult.isSuccess(m)?m.value:void 0),a=s.map(m=>O.AsyncResult.isFailure(m)?m.error:void 0),l=s.map(m=>O.AsyncResult.isLoading(m)),f=()=>{i==null||i.abort(),i=void 0};return{status:s,value:c,error:a,pending:l,execute:async(m,w)=>{f(),i=new AbortController;const p=i.signal,v=s.get(),R=(w==null?void 0:w.optimisticValue)??((w==null?void 0:w.optimisticFromRequest)!=null?w.optimisticFromRequest(m):void 0);R!=null?s.set(O.AsyncResult.loading(R)):s.set(O.AsyncResult.loading(O.AsyncResult.getOrUndefined(v)));try{const x=await t({request:m,abortSignal:p,previous:v});i=void 0,s.set(O.AsyncResult.success(x)),o==null||o(x,m)}catch(x){i=void 0,s.set(O.AsyncResult.failure(e(x))),n==null||n(e(x),m)}r==null||r(s.get(),m)},cancel:m=>{f(),s.set(m??O.AsyncResult.notAsked)},dispose:()=>{i==null||i.abort(),i=void 0,s.dispose()}}},ae=(t,e)=>{const{status:o,dispose:n,execute:r,cancel:i,pending:s,error:c,value:a}=t,{content:l}=e,f=u.previousSignal(a);return u.Fragment(u.OnDispose(n),l({previous:f,execute:r,cancel:i,pending:s,error:c,value:a,status:o}))},Ze=({mutate:t,convertError:e=s=>s,onSuccess:o,onError:n,onSettled:r,content:i})=>{const s=ce({mutate:t,convertError:e,onSuccess:o,onError:n,onSettled:r});return ae(s,{content:i})},X=Math.min,j=Math.max,ht=Math.round,lt=Math.floor,V=t=>({x:t,y:t}),tn={left:"right",right:"left",bottom:"top",top:"bottom"},en={start:"end",end:"start"};function Ot(t,e,o){return j(t,X(e,o))}function rt(t,e){return typeof t=="function"?t(e):t}function I(t){return t.split("-")[0]}function it(t){return t.split("-")[1]}function le(t){return t==="x"?"y":"x"}function Dt(t){return t==="y"?"height":"width"}function z(t){return["top","bottom"].includes(I(t))?"y":"x"}function Wt(t){return le(z(t))}function nn(t,e,o){o===void 0&&(o=!1);const n=it(t),r=Wt(t),i=Dt(r);let s=r==="x"?n===(o?"end":"start")?"right":"left":n==="start"?"bottom":"top";return e.reference[i]>e.floating[i]&&(s=dt(s)),[s,dt(s)]}function on(t){const e=dt(t);return[Et(t),e,Et(e)]}function Et(t){return t.replace(/start|end/g,e=>en[e])}function sn(t,e,o){const n=["left","right"],r=["right","left"],i=["top","bottom"],s=["bottom","top"];switch(t){case"top":case"bottom":return o?e?r:n:e?n:r;case"left":case"right":return e?i:s;default:return[]}}function rn(t,e,o,n){const r=it(t);let i=sn(I(t),o==="start",n);return r&&(i=i.map(s=>s+"-"+r),e&&(i=i.concat(i.map(Et)))),i}function dt(t){return t.replace(/left|right|bottom|top/g,e=>tn[e])}function cn(t){return{top:0,right:0,bottom:0,left:0,...t}}function ue(t){return typeof t!="number"?cn(t):{top:t,right:t,bottom:t,left:t}}function mt(t){const{x:e,y:o,width:n,height:r}=t;return{width:n,height:r,top:o,left:e,right:e+n,bottom:o+r,x:e,y:o}}function Ut(t,e,o){let{reference:n,floating:r}=t;const i=z(e),s=Wt(e),c=Dt(s),a=I(e),l=i==="y",f=n.x+n.width/2-r.width/2,d=n.y+n.height/2-r.height/2,y=n[c]/2-r[c]/2;let h;switch(a){case"top":h={x:f,y:n.y-r.height};break;case"bottom":h={x:f,y:n.y+n.height};break;case"right":h={x:n.x+n.width,y:d};break;case"left":h={x:n.x-r.width,y:d};break;default:h={x:n.x,y:n.y}}switch(it(e)){case"start":h[s]-=y*(o&&l?-1:1);break;case"end":h[s]+=y*(o&&l?-1:1);break}return h}const an=async(t,e,o)=>{const{placement:n="bottom",strategy:r="absolute",middleware:i=[],platform:s}=o,c=i.filter(Boolean),a=await(s.isRTL==null?void 0:s.isRTL(e));let l=await s.getElementRects({reference:t,floating:e,strategy:r}),{x:f,y:d}=Ut(l,n,a),y=n,h={},m=0;for(let w=0;w<c.length;w++){const{name:p,fn:v}=c[w],{x:R,y:x,data:P,reset:E}=await v({x:f,y:d,initialPlacement:n,placement:y,strategy:r,middlewareData:h,rects:l,platform:s,elements:{reference:t,floating:e}});f=R??f,d=x??d,h={...h,[p]:{...h[p],...P}},E&&m<=50&&(m++,typeof E=="object"&&(E.placement&&(y=E.placement),E.rects&&(l=E.rects===!0?await s.getElementRects({reference:t,floating:e,strategy:r}):E.rects),{x:f,y:d}=Ut(l,y,a)),w=-1)}return{x:f,y:d,placement:y,strategy:r,middlewareData:h}};async function fe(t,e){var o;e===void 0&&(e={});const{x:n,y:r,platform:i,rects:s,elements:c,strategy:a}=t,{boundary:l="clippingAncestors",rootBoundary:f="viewport",elementContext:d="floating",altBoundary:y=!1,padding:h=0}=rt(e,t),m=ue(h),p=c[y?d==="floating"?"reference":"floating":d],v=mt(await i.getClippingRect({element:(o=await(i.isElement==null?void 0:i.isElement(p)))==null||o?p:p.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(c.floating)),boundary:l,rootBoundary:f,strategy:a})),R=d==="floating"?{x:n,y:r,width:s.floating.width,height:s.floating.height}:s.reference,x=await(i.getOffsetParent==null?void 0:i.getOffsetParent(c.floating)),P=await(i.isElement==null?void 0:i.isElement(x))?await(i.getScale==null?void 0:i.getScale(x))||{x:1,y:1}:{x:1,y:1},E=mt(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:c,rect:R,offsetParent:x,strategy:a}):R);return{top:(v.top-E.top+m.top)/P.y,bottom:(E.bottom-v.bottom+m.bottom)/P.y,left:(v.left-E.left+m.left)/P.x,right:(E.right-v.right+m.right)/P.x}}const ln=t=>({name:"arrow",options:t,async fn(e){const{x:o,y:n,placement:r,rects:i,platform:s,elements:c,middlewareData:a}=e,{element:l,padding:f=0}=rt(t,e)||{};if(l==null)return{};const d=ue(f),y={x:o,y:n},h=Wt(r),m=Dt(h),w=await s.getDimensions(l),p=h==="y",v=p?"top":"left",R=p?"bottom":"right",x=p?"clientHeight":"clientWidth",P=i.reference[m]+i.reference[h]-y[h]-i.floating[m],E=y[h]-i.reference[h],k=await(s.getOffsetParent==null?void 0:s.getOffsetParent(l));let g=k?k[x]:0;(!g||!await(s.isElement==null?void 0:s.isElement(k)))&&(g=c.floating[x]||i.floating[m]);const b=P/2-E/2,A=g/2-w[m]/2-1,S=X(d[v],A),M=X(d[R],A),K=S,Z=g-w[m]-M,L=g/2-w[m]/2+b,B=Ot(K,L,Z),_=!a.arrow&&it(r)!=null&&L!==B&&i.reference[m]/2-(L<K?S:M)-w[m]/2<0,D=_?L<K?L-K:L-Z:0;return{[h]:y[h]+D,data:{[h]:B,centerOffset:L-B-D,..._&&{alignmentOffset:D}},reset:_}}}),un=function(t){return t===void 0&&(t={}),{name:"flip",options:t,async fn(e){var o,n;const{placement:r,middlewareData:i,rects:s,initialPlacement:c,platform:a,elements:l}=e,{mainAxis:f=!0,crossAxis:d=!0,fallbackPlacements:y,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:m="none",flipAlignment:w=!0,...p}=rt(t,e);if((o=i.arrow)!=null&&o.alignmentOffset)return{};const v=I(r),R=z(c),x=I(c)===c,P=await(a.isRTL==null?void 0:a.isRTL(l.floating)),E=y||(x||!w?[dt(c)]:on(c)),k=m!=="none";!y&&k&&E.push(...rn(c,w,m,P));const g=[c,...E],b=await fe(e,p),A=[];let S=((n=i.flip)==null?void 0:n.overflows)||[];if(f&&A.push(b[v]),d){const L=nn(r,s,P);A.push(b[L[0]],b[L[1]])}if(S=[...S,{placement:r,overflows:A}],!A.every(L=>L<=0)){var M,K;const L=(((M=i.flip)==null?void 0:M.index)||0)+1,B=g[L];if(B&&(!(d==="alignment"?R!==z(B):!1)||S.every(W=>W.overflows[0]>0&&z(W.placement)===R)))return{data:{index:L,overflows:S},reset:{placement:B}};let _=(K=S.filter(D=>D.overflows[0]<=0).sort((D,W)=>D.overflows[1]-W.overflows[1])[0])==null?void 0:K.placement;if(!_)switch(h){case"bestFit":{var Z;const D=(Z=S.filter(W=>{if(k){const $=z(W.placement);return $===R||$==="y"}return!0}).map(W=>[W.placement,W.overflows.filter($=>$>0).reduce(($,ke)=>$+ke,0)]).sort((W,$)=>W[1]-$[1])[0])==null?void 0:Z[0];D&&(_=D);break}case"initialPlacement":_=c;break}if(r!==_)return{reset:{placement:_}}}return{}}}};async function fn(t,e){const{placement:o,platform:n,elements:r}=t,i=await(n.isRTL==null?void 0:n.isRTL(r.floating)),s=I(o),c=it(o),a=z(o)==="y",l=["left","top"].includes(s)?-1:1,f=i&&a?-1:1,d=rt(e,t);let{mainAxis:y,crossAxis:h,alignmentAxis:m}=typeof d=="number"?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return c&&typeof m=="number"&&(h=c==="end"?m*-1:m),a?{x:h*f,y:y*l}:{x:y*l,y:h*f}}const hn=function(t){return t===void 0&&(t=0),{name:"offset",options:t,async fn(e){var o,n;const{x:r,y:i,placement:s,middlewareData:c}=e,a=await fn(e,t);return s===((o=c.offset)==null?void 0:o.placement)&&(n=c.arrow)!=null&&n.alignmentOffset?{}:{x:r+a.x,y:i+a.y,data:{...a,placement:s}}}}},dn=function(t){return t===void 0&&(t={}),{name:"shift",options:t,async fn(e){const{x:o,y:n,placement:r}=e,{mainAxis:i=!0,crossAxis:s=!1,limiter:c={fn:p=>{let{x:v,y:R}=p;return{x:v,y:R}}},...a}=rt(t,e),l={x:o,y:n},f=await fe(e,a),d=z(I(r)),y=le(d);let h=l[y],m=l[d];if(i){const p=y==="y"?"top":"left",v=y==="y"?"bottom":"right",R=h+f[p],x=h-f[v];h=Ot(R,h,x)}if(s){const p=d==="y"?"top":"left",v=d==="y"?"bottom":"right",R=m+f[p],x=m-f[v];m=Ot(R,m,x)}const w=c.fn({...e,[y]:h,[d]:m});return{...w,data:{x:w.x-o,y:w.y-n,enabled:{[y]:i,[d]:s}}}}}};function wt(){return typeof window<"u"}function G(t){return he(t)?(t.nodeName||"").toLowerCase():"#document"}function T(t){var e;return(t==null||(e=t.ownerDocument)==null?void 0:e.defaultView)||window}function H(t){var e;return(e=(he(t)?t.ownerDocument:t.document)||window.document)==null?void 0:e.documentElement}function he(t){return wt()?t instanceof Node||t instanceof T(t).Node:!1}function C(t){return wt()?t instanceof Element||t instanceof T(t).Element:!1}function N(t){return wt()?t instanceof HTMLElement||t instanceof T(t).HTMLElement:!1}function Kt(t){return!wt()||typeof ShadowRoot>"u"?!1:t instanceof ShadowRoot||t instanceof T(t).ShadowRoot}function ct(t){const{overflow:e,overflowX:o,overflowY:n,display:r}=F(t);return/auto|scroll|overlay|hidden|clip/.test(e+n+o)&&!["inline","contents"].includes(r)}function mn(t){return["table","td","th"].includes(G(t))}function vt(t){return[":popover-open",":modal"].some(e=>{try{return t.matches(e)}catch{return!1}})}function Ct(t){const e=Ft(),o=C(t)?F(t):t;return["transform","translate","scale","rotate","perspective"].some(n=>o[n]?o[n]!=="none":!1)||(o.containerType?o.containerType!=="normal":!1)||!e&&(o.backdropFilter?o.backdropFilter!=="none":!1)||!e&&(o.filter?o.filter!=="none":!1)||["transform","translate","scale","rotate","perspective","filter"].some(n=>(o.willChange||"").includes(n))||["paint","layout","strict","content"].some(n=>(o.contain||"").includes(n))}function gn(t){let e=U(t);for(;N(e)&&!J(e);){if(Ct(e))return e;if(vt(e))return null;e=U(e)}return null}function Ft(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function J(t){return["html","body","#document"].includes(G(t))}function F(t){return T(t).getComputedStyle(t)}function xt(t){return C(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.scrollX,scrollTop:t.scrollY}}function U(t){if(G(t)==="html")return t;const e=t.assignedSlot||t.parentNode||Kt(t)&&t.host||H(t);return Kt(e)?e.host:e}function de(t){const e=U(t);return J(e)?t.ownerDocument?t.ownerDocument.body:t.body:N(e)&&ct(e)?e:de(e)}function ot(t,e,o){var n;e===void 0&&(e=[]),o===void 0&&(o=!0);const r=de(t),i=r===((n=t.ownerDocument)==null?void 0:n.body),s=T(r);if(i){const c=Pt(s);return e.concat(s,s.visualViewport||[],ct(r)?r:[],c&&o?ot(c):[])}return e.concat(r,ot(r,[],o))}function Pt(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}function me(t){const e=F(t);let o=parseFloat(e.width)||0,n=parseFloat(e.height)||0;const r=N(t),i=r?t.offsetWidth:o,s=r?t.offsetHeight:n,c=ht(o)!==i||ht(n)!==s;return c&&(o=i,n=s),{width:o,height:n,$:c}}function Mt(t){return C(t)?t:t.contextElement}function Q(t){const e=Mt(t);if(!N(e))return V(1);const o=e.getBoundingClientRect(),{width:n,height:r,$:i}=me(e);let s=(i?ht(o.width):o.width)/n,c=(i?ht(o.height):o.height)/r;return(!s||!Number.isFinite(s))&&(s=1),(!c||!Number.isFinite(c))&&(c=1),{x:s,y:c}}const pn=V(0);function ge(t){const e=T(t);return!Ft()||!e.visualViewport?pn:{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}}function yn(t,e,o){return e===void 0&&(e=!1),!o||e&&o!==T(t)?!1:e}function q(t,e,o,n){e===void 0&&(e=!1),o===void 0&&(o=!1);const r=t.getBoundingClientRect(),i=Mt(t);let s=V(1);e&&(n?C(n)&&(s=Q(n)):s=Q(t));const c=yn(i,o,n)?ge(i):V(0);let a=(r.left+c.x)/s.x,l=(r.top+c.y)/s.y,f=r.width/s.x,d=r.height/s.y;if(i){const y=T(i),h=n&&C(n)?T(n):n;let m=y,w=Pt(m);for(;w&&n&&h!==m;){const p=Q(w),v=w.getBoundingClientRect(),R=F(w),x=v.left+(w.clientLeft+parseFloat(R.paddingLeft))*p.x,P=v.top+(w.clientTop+parseFloat(R.paddingTop))*p.y;a*=p.x,l*=p.y,f*=p.x,d*=p.y,a+=x,l+=P,m=T(w),w=Pt(m)}}return mt({width:f,height:d,x:a,y:l})}function Vt(t,e){const o=xt(t).scrollLeft;return e?e.left+o:q(H(t)).left+o}function pe(t,e,o){o===void 0&&(o=!1);const n=t.getBoundingClientRect(),r=n.left+e.scrollLeft-(o?0:Vt(t,n)),i=n.top+e.scrollTop;return{x:r,y:i}}function wn(t){let{elements:e,rect:o,offsetParent:n,strategy:r}=t;const i=r==="fixed",s=H(n),c=e?vt(e.floating):!1;if(n===s||c&&i)return o;let a={scrollLeft:0,scrollTop:0},l=V(1);const f=V(0),d=N(n);if((d||!d&&!i)&&((G(n)!=="body"||ct(s))&&(a=xt(n)),N(n))){const h=q(n);l=Q(n),f.x=h.x+n.clientLeft,f.y=h.y+n.clientTop}const y=s&&!d&&!i?pe(s,a,!0):V(0);return{width:o.width*l.x,height:o.height*l.y,x:o.x*l.x-a.scrollLeft*l.x+f.x+y.x,y:o.y*l.y-a.scrollTop*l.y+f.y+y.y}}function vn(t){return Array.from(t.getClientRects())}function xn(t){const e=H(t),o=xt(t),n=t.ownerDocument.body,r=j(e.scrollWidth,e.clientWidth,n.scrollWidth,n.clientWidth),i=j(e.scrollHeight,e.clientHeight,n.scrollHeight,n.clientHeight);let s=-o.scrollLeft+Vt(t);const c=-o.scrollTop;return F(n).direction==="rtl"&&(s+=j(e.clientWidth,n.clientWidth)-r),{width:r,height:i,x:s,y:c}}function Rn(t,e){const o=T(t),n=H(t),r=o.visualViewport;let i=n.clientWidth,s=n.clientHeight,c=0,a=0;if(r){i=r.width,s=r.height;const l=Ft();(!l||l&&e==="fixed")&&(c=r.offsetLeft,a=r.offsetTop)}return{width:i,height:s,x:c,y:a}}function bn(t,e){const o=q(t,!0,e==="fixed"),n=o.top+t.clientTop,r=o.left+t.clientLeft,i=N(t)?Q(t):V(1),s=t.clientWidth*i.x,c=t.clientHeight*i.y,a=r*i.x,l=n*i.y;return{width:s,height:c,x:a,y:l}}function Bt(t,e,o){let n;if(e==="viewport")n=Rn(t,o);else if(e==="document")n=xn(H(t));else if(C(e))n=bn(e,o);else{const r=ge(t);n={x:e.x-r.x,y:e.y-r.y,width:e.width,height:e.height}}return mt(n)}function ye(t,e){const o=U(t);return o===e||!C(o)||J(o)?!1:F(o).position==="fixed"||ye(o,e)}function An(t,e){const o=e.get(t);if(o)return o;let n=ot(t,[],!1).filter(c=>C(c)&&G(c)!=="body"),r=null;const i=F(t).position==="fixed";let s=i?U(t):t;for(;C(s)&&!J(s);){const c=F(s),a=Ct(s);!a&&c.position==="fixed"&&(r=null),(i?!a&&!r:!a&&c.position==="static"&&!!r&&["absolute","fixed"].includes(r.position)||ct(s)&&!a&&ye(t,s))?n=n.filter(f=>f!==s):r=c,s=U(s)}return e.set(t,n),n}function On(t){let{element:e,boundary:o,rootBoundary:n,strategy:r}=t;const s=[...o==="clippingAncestors"?vt(e)?[]:An(e,this._c):[].concat(o),n],c=s[0],a=s.reduce((l,f)=>{const d=Bt(e,f,r);return l.top=j(d.top,l.top),l.right=X(d.right,l.right),l.bottom=X(d.bottom,l.bottom),l.left=j(d.left,l.left),l},Bt(e,c,r));return{width:a.right-a.left,height:a.bottom-a.top,x:a.left,y:a.top}}function En(t){const{width:e,height:o}=me(t);return{width:e,height:o}}function Pn(t,e,o){const n=N(e),r=H(e),i=o==="fixed",s=q(t,!0,i,e);let c={scrollLeft:0,scrollTop:0};const a=V(0);function l(){a.x=Vt(r)}if(n||!n&&!i)if((G(e)!=="body"||ct(r))&&(c=xt(e)),n){const h=q(e,!0,i,e);a.x=h.x+e.clientLeft,a.y=h.y+e.clientTop}else r&&l();i&&!n&&r&&l();const f=r&&!n&&!i?pe(r,c):V(0),d=s.left+c.scrollLeft-a.x-f.x,y=s.top+c.scrollTop-a.y-f.y;return{x:d,y,width:s.width,height:s.height}}function bt(t){return F(t).position==="static"}function jt(t,e){if(!N(t)||F(t).position==="fixed")return null;if(e)return e(t);let o=t.offsetParent;return H(t)===o&&(o=o.ownerDocument.body),o}function we(t,e){const o=T(t);if(vt(t))return o;if(!N(t)){let r=U(t);for(;r&&!J(r);){if(C(r)&&!bt(r))return r;r=U(r)}return o}let n=jt(t,e);for(;n&&mn(n)&&bt(n);)n=jt(n,e);return n&&J(n)&&bt(n)&&!Ct(n)?o:n||gn(t)||o}const Sn=async function(t){const e=this.getOffsetParent||we,o=this.getDimensions,n=await o(t.floating);return{reference:Pn(t.reference,await e(t.floating),t.strategy),floating:{x:0,y:0,width:n.width,height:n.height}}};function Ln(t){return F(t).direction==="rtl"}const Tn={convertOffsetParentRelativeRectToViewportRelativeRect:wn,getDocumentElement:H,getClippingRect:On,getOffsetParent:we,getElementRects:Sn,getClientRects:vn,getDimensions:En,getScale:Q,isElement:C,isRTL:Ln};function ve(t,e){return t.x===e.x&&t.y===e.y&&t.width===e.width&&t.height===e.height}function kn(t,e){let o=null,n;const r=H(t);function i(){var c;clearTimeout(n),(c=o)==null||c.disconnect(),o=null}function s(c,a){c===void 0&&(c=!1),a===void 0&&(a=1),i();const l=t.getBoundingClientRect(),{left:f,top:d,width:y,height:h}=l;if(c||e(),!y||!h)return;const m=lt(d),w=lt(r.clientWidth-(f+y)),p=lt(r.clientHeight-(d+h)),v=lt(f),x={rootMargin:-m+"px "+-w+"px "+-p+"px "+-v+"px",threshold:j(0,X(1,a))||1};let P=!0;function E(k){const g=k[0].intersectionRatio;if(g!==a){if(!P)return s();g?s(!1,g):n=setTimeout(()=>{s(!1,1e-7)},1e3)}g===1&&!ve(l,t.getBoundingClientRect())&&s(),P=!1}try{o=new IntersectionObserver(E,{...x,root:r.ownerDocument})}catch{o=new IntersectionObserver(E,x)}o.observe(t)}return s(!0),i}function Dn(t,e,o,n){n===void 0&&(n={});const{ancestorScroll:r=!0,ancestorResize:i=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:c=typeof IntersectionObserver=="function",animationFrame:a=!1}=n,l=Mt(t),f=r||i?[...l?ot(l):[],...ot(e)]:[];f.forEach(v=>{r&&v.addEventListener("scroll",o,{passive:!0}),i&&v.addEventListener("resize",o)});const d=l&&c?kn(l,o):null;let y=-1,h=null;s&&(h=new ResizeObserver(v=>{let[R]=v;R&&R.target===l&&h&&(h.unobserve(e),cancelAnimationFrame(y),y=requestAnimationFrame(()=>{var x;(x=h)==null||x.observe(e)})),o()}),l&&!a&&h.observe(l),h.observe(e));let m,w=a?q(t):null;a&&p();function p(){const v=q(t);w&&!ve(w,v)&&o(),w=v,m=requestAnimationFrame(p)}return o(),()=>{var v;f.forEach(R=>{r&&R.removeEventListener("scroll",o),i&&R.removeEventListener("resize",o)}),d==null||d(),(v=h)==null||v.disconnect(),h=null,a&&cancelAnimationFrame(m)}}const Wn=hn,Cn=dn,It=un,Fn=ln,Mn=(t,e,o)=>{const n=new Map,r={platform:Tn,...o},i={...r.platform,_c:n};return an(t,e,{...r,platform:i})},Vn=["top","top-start","top-end","right","right-start","right-end","bottom","bottom-start","bottom-end","left","left-start","left-end"],Nn=(t,e={isOpen:!1})=>{const o=[];let n=null;const r=u.Value.deriveProp(e.isOpen);function i(c){n=c,r.set(!0)}function s(){r.set(!1),o.forEach(c=>c()),o.length=0}return u.Fragment(t(i,s),u.When(r,()=>u.Fragment((n==null?void 0:n.onClickOutside)!=null?re(n.onClickOutside):null,u.WithElement(c=>u.Portal("body",u.html.div(u.WithElement(a=>{a.style.position="absolute";const l=typeof(n==null?void 0:n.target)=="string"?c.querySelector(n.target):(n==null?void 0:n.target)??c;if(l==null)throw new Error(`Target not found: ${n==null?void 0:n.target}`);let f=null;const d=u.Value.toSignal((n==null?void 0:n.mainAxisOffset)??0),y=u.Value.toSignal((n==null?void 0:n.crossAxisOffset)??0),h=u.Value.toSignal((n==null?void 0:n.placement)??"top"),m=u.Value.toSignal((n==null?void 0:n.arrowPadding)??0),w=n==null?void 0:n.arrow,p=u.prop({centerOffset:0,alignmentOffset:0,containerWidth:0,containerHeight:0,x:void 0,y:void 0});async function v(){const x=[It(),Wn({mainAxis:d.get(),crossAxis:y.get()}),Cn(),It()];w!=null&&f!=null&&x.push(Fn({element:f,padding:m.get()}));const P=await Mn(l,a,{placement:h.get(),strategy:"absolute",middleware:x}),{x:E,y:k,middlewareData:g}=P;if(a.style.top=`${k}px`,a.style.left=`${E}px`,f!=null&&g.arrow!=null){const{x:b,y:A,centerOffset:S,alignmentOffset:M}=g.arrow;p.set({x:b,y:A,centerOffset:S,alignmentOffset:M,containerWidth:a.offsetWidth,containerHeight:a.offsetHeight})}}const R=u.effectOf(d,y,h)(v);return u.Fragment(n==null?void 0:n.content,(n==null?void 0:n.arrow)!=null?u.html.div(n==null?void 0:n.arrow(u.computedOf(p,h)((x,P)=>({...x,placement:P}))),u.WithElement(x=>{f=x,v()})):null,u.OnDispose(p.dispose,Dn(l,a,v),R))})))))))},xe=({request:t,load:e,convertError:o,onSuccess:n,onError:r,onSettled:i})=>{let s;const c=u.prop(O.AsyncResult.notAsked),a=c.map(p=>O.AsyncResult.isSuccess(p)?p.value:void 0),l=c.map(p=>O.AsyncResult.isFailure(p)?p.error:void 0),f=c.map(p=>O.AsyncResult.isLoading(p)),d=()=>{s==null||s.abort(),s=void 0},y=p=>{d(),c.set(p??O.AsyncResult.notAsked)},h=async p=>{d(),s=new AbortController;const v=s.signal,R=c.get();c.set(O.AsyncResult.loading(O.AsyncResult.getOrUndefined(R)));try{const x=await e({request:p,abortSignal:v,previous:R});await Promise.resolve(),s=void 0,c.set(O.AsyncResult.success(x)),n==null||n(x,p)}catch(x){s=void 0,c.set(O.AsyncResult.failure(o(x))),r==null||r(o(x),p)}i==null||i(c.get(),p)},m=()=>h(u.Value.get(t)),w=()=>{s==null||s.abort(),s=void 0,c.dispose()};return c.onDispose(u.Value.on(t,h)),{status:c,value:a,error:l,loading:f,cancel:y,reload:m,dispose:w}},Re=(t,e)=>{const{status:o,dispose:n,reload:r}=t,{pending:i,failure:s,success:c}=e;return u.Fragment(u.OnDispose(n),Tt(o,{loading:i!=null?a=>i({previous:a,reload:r,cancel:t.cancel}):void 0,failure:s!=null?a=>s({error:a,reload:r}):void 0,success:a=>c({value:a,reload:r})}))},Hn=({request:t,load:e,convertError:o=l=>l,onSuccess:n,onError:r,onSettled:i,success:s,pending:c,failure:a})=>{const l=xe({request:t,load:e,convertError:o,onSuccess:n,onError:r,onSettled:i});return Re(l,{success:s,pending:c,failure:a})},be=(t,e)=>{if(typeof e=="function")return be(t,{success:e});const o=e.failure??(r=>u.Fragment(u.OnDispose(r.on(console.error)),r.map(i=>`Error: ${i}`))),n=e.success;return u.OneOfType(u.Value.toSignal(t),{Success:r=>n(r.$.value),Failure:r=>o(r.$.error)})},_n=()=>u.on.focus(t=>{var e;return(e=t.target)==null?void 0:e.select()});class at{constructor(e,o,n,r,i,s){Rt(this,"equals",e=>O.nearEqual(this.left,e.left)&&O.nearEqual(this.top,e.top)&&O.nearEqual(this.width,e.width)&&O.nearEqual(this.height,e.height));this.left=e,this.top=o,this.width=n,this.height=r,this.localLeft=i,this.localTop=s}static of({left:e=0,top:o=0,width:n=0,height:r=0,localLeft:i=0,localTop:s=0}){return new at(e,o,n,r,i,s)}get right(){return this.left+this.width}get bottom(){return this.top+this.height}get center(){return{x:this.left+this.width/2,y:this.top+this.height/2}}get localCenter(){return{x:this.localLeft+this.width/2,y:this.localTop+this.height/2}}get localBottom(){return this.localTop+this.height}get localRight(){return this.localLeft+this.width}get size(){return{width:this.width,height:this.height}}}function St(t){const e=t.getBoundingClientRect();return at.of({top:e.top+window.scrollY,left:e.left+window.scrollX,width:e.width,height:e.height,localLeft:t.offsetLeft,localTop:t.offsetTop})}const $n=t=>u.WithBrowserCtx(e=>{const{element:o}=e,n=u.prop(St(o),(c,a)=>c.equals(a)),r=u.renderableOfTNode(t(n))(e),i=()=>n.set(at.of(St(o)));let s=null;return typeof ResizeObserver<"u"&&(s=new ResizeObserver(i)),s==null||s.observe(o),u.OnDispose(c=>{s==null||s.disconnect(),r(c)})});function qt(t){return{width:(t==null?void 0:t.innerWidth)??0,height:(t==null?void 0:t.innerHeight)??0}}const zn=t=>e=>{const o=u.getWindow(),n=u.prop(qt(o),(s,c)=>s.width===c.width&&s.height===c.height),r=u.renderableOfTNode(t(n))(e),i=()=>n.set(qt(o));return o==null||o.addEventListener("resize",i),s=>{o==null||o.removeEventListener("resize",i),r(s)}},Ae=(t,e)=>{const o=e.split("/").filter(r=>r!==""),n={};for(let r=0;r<t.length;r++){const i=t[r],s=o[r];if(!s&&i.type!=="catch-all")return null;if(i.type==="literal"){if(i.value!==s)return null}else if(i.type==="param")n[i.name]=s;else if(i.type==="catch-all"){if(i.name){const c=o.slice(r).join("/");n[i.name]=c}return{params:n,path:e}}}return o.length!==t.length?null:{params:n,path:e}},Nt=t=>t.split("/").map(e=>{if(e.startsWith(":"))return{type:"param",name:e.slice(1)};if(e.startsWith("*")){const o=e.slice(1);return o!=""?{type:"catch-all",name:o}:{type:"catch-all"}}else return{type:"literal",value:e}}).filter(e=>e.type!=="literal"||e.value!==""),Un=t=>{const e=t.map(o=>{const n=Nt(o);return{route:o,segments:n}});return function(n){for(const{segments:r,route:i}of e){const s=Ae(r,n);if(s)return{...s,route:i}}return null}},gt={mark:u.makeProviderMark("RouterContext"),create:()=>{const t=u.prop([]);return{value:t,dispose:()=>t.dispose()}}},Kn=(t,e,o)=>{const n=o.split("/").filter(s=>s!==""),r={};let i=0;for(let s=0;s<t.length;s++){const c=t[s],a=n[s];if(!a&&c.type!=="catch-all")return null;if(c.type==="literal"){if(c.value!==a)return null;i++}else if(c.type==="param")r[c.name]=a,i++;else if(c.type==="catch-all"){c.name&&(r[c.name]=n.slice(i).join("/"));const l="/"+n.slice(0,i).join("/"),f="/"+n.slice(i).join("/");return{params:r,matchedPath:l==="/"?"":l,remainingPath:f==="/"?"":f,route:e}}}if(n.length===t.length){const s="/"+n.join("/");return{params:r,matchedPath:s==="/"?"":s,remainingPath:"",route:e}}return null},Oe=t=>{const e=t.map(o=>{const n=Nt(o);return{route:o,segments:n}});return function(n){for(const{segments:r,route:i}of e){const s=Kn(r,i,n);if(s)return s}return null}},Bn=t=>{const e=Oe(Object.keys(t));return u.Provide(gt,{},()=>u.Use(yt,o=>u.Use(gt,n=>{const r=o.location.map(i=>{const s=e(i.pathname);if(s==null)throw console.error("No route found for",i),new Error("No route found");const c={matchedPath:s.matchedPath,remainingPath:s.remainingPath,fullPath:i.pathname,params:s.params};return n.value=[...n.value,c],{params:s.params,route:s.route,path:s.matchedPath||i.pathname,search:i.search,hash:i.hash}});return u.OneOfTuple(r.map(i=>[i.route,i]),t)})))},jn=t=>{const e=Oe(Object.keys(t));return u.Use(gt,o=>u.Use(yt,n=>{const r=o.map(i=>{const s=i[i.length-1],c=(s==null?void 0:s.remainingPath)||"";if(c==="")throw console.error("No remaining path for SubRouter",i),new Error("No remaining path for SubRouter");const a=e(c);if(a==null)throw console.error("No route found for remaining path",c),new Error("No route found");return{params:a.params,route:a.route,path:a.matchedPath,search:n.location.value.search,hash:n.location.value.hash}});return u.OneOfTuple(r.map(i=>[i.route,i]),t)}))},pt=60*1e3,Lt=60*pt,st=24*Lt,Yt=7*st,Qt=30*st,In=365*st,qn=[{max:pt*90,value:pt,name:"minute",past:{singular:"a minute ago",plural:"{} minutes ago"},future:{singular:"in a minute",plural:"in {} minutes"}},{max:Lt*36,value:Lt,name:"hour",past:{singular:"an hour ago",plural:"{} hours ago"},future:{singular:"in an hour",plural:"in {} hours"}},{max:st*10,value:st,name:"day",past:{singular:"yesterday",plural:"{} days ago"},future:{singular:"tomorrow",plural:"in {} days"}},{max:Yt*6,value:Yt,name:"week",past:{singular:"last week",plural:"{} weeks ago"},future:{singular:"in a week",plural:"in {} weeks"}},{max:Qt*18,value:Qt,name:"month",past:{singular:"last month",plural:"{} months ago"},future:{singular:"in a month",plural:"in {} months"}},{max:1/0,value:In,name:"year",past:{singular:"last year",plural:"{} years ago"},future:{singular:"in a year",plural:"in {} years"}}];function Xt(t,e,o,n){const r=Math.round(t/e);return r<=1?o:n.replace("{}",r.toLocaleString(void 0,{maximumFractionDigits:0,minimumFractionDigits:0}))}const Ee=(t=1e3)=>{const e=u.prop(new Date),o=O.interval(()=>e.set(new Date),t);return e.onDispose(o),e},Pe=t=>{const e=Math.abs(t);if(e<pt)return t<0?"just now":"in a moment";for(const o of qn)if(e<o.max)return t<0?Xt(e,o.value,o.past.singular,o.past.plural):Xt(e,o.value,o.future.singular,o.future.plural);throw new Error("unreachable")},Se=(t,{now:e,frequency:o=1e4}={})=>{const n=e!=null?u.Signal.is(e)?e.derive():u.prop(e):Ee(o),r=u.computedOf(t,n)((i,s)=>i.getTime()-s.getTime());return r.onDispose(()=>u.Value.dispose(n)),r},Le=(t,e={})=>{const o=Se(t,e),n=o.map(Pe);return n.onDispose(o.dispose),n},Yn=(t,e={})=>Le(t,e);class Te extends u.Prop{constructor(){super(...arguments);Rt(this,"tick",()=>this.update(o=>o+1))}}const Qn=(t=0)=>new Te(t,(e,o)=>e===o);exports.Anchor=ne;exports.Appearance=Ue;exports.AsyncResultView=Tt;exports.AutoFocus=Ke;exports.AutoSelect=Be;exports.ChildRouter=jn;exports.ElementRect=$n;exports.HTMLTitle=qe;exports.HiddenWhenEmpty=Ie;exports.InViewport=se;exports.Location=yt;exports.Mutation=Ze;exports.MutationDisplay=ae;exports.OnClickOutside=re;exports.OnEnterKey=Je;exports.OnEscapeKey=Ge;exports.OnKeyPressed=kt;exports.PopOver=Nn;exports.Query=Hn;exports.QueryDisplay=Re;exports.Rect=at;exports.ResultView=be;exports.RootRouter=Bn;exports.RouterContextProvider=gt;exports.SelectOnFocus=_n;exports.Ticker=Te;exports.WhenInViewport=Xe;exports.WindowSize=zn;exports._checkExtensionCondition=Gt;exports._getExtension=Jt;exports._makeRouteMatcher=Un;exports._parseRouteSegments=Nt;exports.allPlacements=Vn;exports.areLocationsEqual=te;exports.classes=je;exports.getAbsoluteRect=St;exports.handleAnchorClick=Zt;exports.locationFromURL=ft;exports.makeMutationResource=ce;exports.makeQueryResource=xe;exports.matchesKeyCombo=ie;exports.matchesRoute=Ae;exports.nowSignal=Ee;exports.relativeTime=Yn;exports.relativeTimeMillisSignal=Se;exports.relativeTimeSignal=Le;exports.ticker=Qn;exports.timeDiffToString=Pe;exports.urlFromLocation=nt;exports.useAppearance=oe;