react-lib-tools 0.0.14 → 0.0.18
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/{GettingStartedRoute-Bea34m1X.js → GettingStartedRoute-DmHalwMP.js} +2 -2
- package/dist/{GettingStartedRoute-Bea34m1X.js.map → GettingStartedRoute-DmHalwMP.js.map} +1 -1
- package/dist/{GettingStartedRoute-BJh6Q9Fv.cjs → GettingStartedRoute-LGDNviy5.cjs} +2 -2
- package/dist/{GettingStartedRoute-BJh6Q9Fv.cjs.map → GettingStartedRoute-LGDNviy5.cjs.map} +1 -1
- package/dist/{PageNotFound-CrHjMQNv.cjs → PageNotFound-DIt5wQ4x.cjs} +2 -2
- package/dist/{PageNotFound-CrHjMQNv.cjs.map → PageNotFound-DIt5wQ4x.cjs.map} +1 -1
- package/dist/{PageNotFound-DE5Z0RR6.js → PageNotFound-DuD7brn5.js} +2 -2
- package/dist/{PageNotFound-DE5Z0RR6.js.map → PageNotFound-DuD7brn5.js.map} +1 -1
- package/dist/{SupportRoute-DPlYEYJn.js → SupportRoute-B9n9OCoW.js} +2 -2
- package/dist/{SupportRoute-DPlYEYJn.js.map → SupportRoute-B9n9OCoW.js.map} +1 -1
- package/dist/{SupportRoute-Bww0QSix.cjs → SupportRoute-DWEe-0A7.cjs} +2 -2
- package/dist/{SupportRoute-Bww0QSix.cjs.map → SupportRoute-DWEe-0A7.cjs.map} +1 -1
- package/dist/VersionsRoute-Br6RZivR.cjs +2 -0
- package/dist/VersionsRoute-Br6RZivR.cjs.map +1 -0
- package/dist/VersionsRoute-DOa8Yrmb.js +60 -0
- package/dist/VersionsRoute-DOa8Yrmb.js.map +1 -0
- package/dist/{index-DdaUFzS-.js → index-D1Hn63kY.js} +218 -216
- package/dist/index-D1Hn63kY.js.map +1 -0
- package/dist/{index-BpfFWZm4.cjs → index-DleNtYr0.cjs} +5 -5
- package/dist/index-DleNtYr0.cjs.map +1 -0
- package/dist/react-lib-tools.cjs +1 -1
- package/dist/react-lib-tools.d.ts +11 -2
- package/dist/react-lib-tools.js +4 -4
- package/package.json +6 -4
- package/dist/index-BpfFWZm4.cjs.map +0 -1
- package/dist/index-DdaUFzS-.js.map +0 -1
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
"use client";"use strict";const E=require("react/jsx-runtime"),p=require("react"),Ge=require("react-dom");function Bo(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const g=Bo(p),Zt=Bo(Ge);function Ji({title:e,titleId:t,...n},r){return g.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?g.createElement("title",{id:t},e):null,g.createElement("path",{fillRule:"evenodd",d:"M15.312 11.424a5.5 5.5 0 0 1-9.201 2.466l-.312-.311h2.433a.75.75 0 0 0 0-1.5H3.989a.75.75 0 0 0-.75.75v4.242a.75.75 0 0 0 1.5 0v-2.43l.31.31a7 7 0 0 0 11.712-3.138.75.75 0 0 0-1.449-.39Zm1.23-3.723a.75.75 0 0 0 .219-.53V2.929a.75.75 0 0 0-1.5 0V5.36l-.31-.31A7 7 0 0 0 3.239 8.188a.75.75 0 1 0 1.448.389A5.5 5.5 0 0 1 13.89 6.11l.311.31h-2.432a.75.75 0 0 0 0 1.5h4.243a.75.75 0 0 0 .53-.219Z",clipRule:"evenodd"}))}const Qi=g.forwardRef(Ji);function ea({title:e,titleId:t,...n},r){return g.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?g.createElement("title",{id:t},e):null,g.createElement("path",{fillRule:"evenodd",d:"M4.25 5.5a.75.75 0 0 0-.75.75v8.5c0 .414.336.75.75.75h8.5a.75.75 0 0 0 .75-.75v-4a.75.75 0 0 1 1.5 0v4A2.25 2.25 0 0 1 12.75 17h-8.5A2.25 2.25 0 0 1 2 14.75v-8.5A2.25 2.25 0 0 1 4.25 4h5a.75.75 0 0 1 0 1.5h-5Z",clipRule:"evenodd"}),g.createElement("path",{fillRule:"evenodd",d:"M6.194 12.753a.75.75 0 0 0 1.06.053L16.5 4.44v2.81a.75.75 0 0 0 1.5 0v-4.5a.75.75 0 0 0-.75-.75h-4.5a.75.75 0 0 0 0 1.5h2.553l-9.056 8.194a.75.75 0 0 0-.053 1.06Z",clipRule:"evenodd"}))}const Ho=g.forwardRef(ea);function ta({title:e,titleId:t,...n},r){return g.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?g.createElement("title",{id:t},e):null,g.createElement("path",{fillRule:"evenodd",d:"M2 3.75A.75.75 0 0 1 2.75 3h14.5a.75.75 0 0 1 0 1.5H2.75A.75.75 0 0 1 2 3.75Zm0 4.167a.75.75 0 0 1 .75-.75h14.5a.75.75 0 0 1 0 1.5H2.75a.75.75 0 0 1-.75-.75Zm0 4.166a.75.75 0 0 1 .75-.75h14.5a.75.75 0 0 1 0 1.5H2.75a.75.75 0 0 1-.75-.75Zm0 4.167a.75.75 0 0 1 .75-.75h14.5a.75.75 0 0 1 0 1.5H2.75a.75.75 0 0 1-.75-.75Z",clipRule:"evenodd"}))}const na=g.forwardRef(ta);function ra({title:e,titleId:t,...n},r){return g.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?g.createElement("title",{id:t},e):null,g.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 1 0 0-16 8 8 0 0 0 0 16Zm3.857-9.809a.75.75 0 0 0-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 1 0-1.06 1.061l2.5 2.5a.75.75 0 0 0 1.137-.089l4-5.5Z",clipRule:"evenodd"}))}const oa=g.forwardRef(ra);function la({title:e,titleId:t,...n},r){return g.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?g.createElement("title",{id:t},e):null,g.createElement("path",{fillRule:"evenodd",d:"M8.22 5.22a.75.75 0 0 1 1.06 0l4.25 4.25a.75.75 0 0 1 0 1.06l-4.25 4.25a.75.75 0 0 1-1.06-1.06L11.94 10 8.22 6.28a.75.75 0 0 1 0-1.06Z",clipRule:"evenodd"}))}const Vo=g.forwardRef(la);function ia({title:e,titleId:t,...n},r){return g.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?g.createElement("title",{id:t},e):null,g.createElement("path",{fillRule:"evenodd",d:"M10.53 3.47a.75.75 0 0 0-1.06 0L6.22 6.72a.75.75 0 0 0 1.06 1.06L10 5.06l2.72 2.72a.75.75 0 1 0 1.06-1.06l-3.25-3.25Zm-4.31 9.81 3.25 3.25a.75.75 0 0 0 1.06 0l3.25-3.25a.75.75 0 1 0-1.06-1.06L10 14.94l-2.72-2.72a.75.75 0 0 0-1.06 1.06Z",clipRule:"evenodd"}))}const aa=g.forwardRef(ia);function sa({title:e,titleId:t,...n},r){return g.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?g.createElement("title",{id:t},e):null,g.createElement("path",{fillRule:"evenodd",d:"M8.485 2.495c.673-1.167 2.357-1.167 3.03 0l6.28 10.875c.673 1.167-.17 2.625-1.516 2.625H3.72c-1.347 0-2.189-1.458-1.515-2.625L8.485 2.495ZM10 5a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 10 5Zm0 9a1 1 0 1 0 0-2 1 1 0 0 0 0 2Z",clipRule:"evenodd"}))}const ua=g.forwardRef(sa);function ca({title:e,titleId:t,...n},r){return g.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?g.createElement("title",{id:t},e):null,g.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 1 1-16 0 8 8 0 0 1 16 0Zm-7-4a1 1 0 1 1-2 0 1 1 0 0 1 2 0ZM9 9a.75.75 0 0 0 0 1.5h.253a.25.25 0 0 1 .244.304l-.459 2.066A1.75 1.75 0 0 0 10.747 15H11a.75.75 0 0 0 0-1.5h-.253a.25.25 0 0 1-.244-.304l.459-2.066A1.75 1.75 0 0 0 9.253 9H9Z",clipRule:"evenodd"}))}const da=g.forwardRef(ca);function fa({title:e,titleId:t,...n},r){return g.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?g.createElement("title",{id:t},e):null,g.createElement("path",{d:"M6.28 5.22a.75.75 0 0 0-1.06 1.06L8.94 10l-3.72 3.72a.75.75 0 1 0 1.06 1.06L10 11.06l3.72 3.72a.75.75 0 1 0 1.06-1.06L11.06 10l3.72-3.72a.75.75 0 0 0-1.06-1.06L10 8.94 6.28 5.22Z"}))}const pa=g.forwardRef(fa);var Hr="popstate";function ma(e={}){function t(r,o){let{pathname:l,search:i,hash:a}=r.location;return Vn("",{pathname:l,search:i,hash:a},o.state&&o.state.usr||null,o.state&&o.state.key||"default")}function n(r,o){return typeof o=="string"?o:xt(o)}return ga(t,n,null,e)}function G(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function we(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function ha(){return Math.random().toString(36).substring(2,10)}function Vr(e,t){return{usr:e.state,key:e.key,idx:t}}function Vn(e,t,n=null,r){return{pathname:typeof e=="string"?e:e.pathname,search:"",hash:"",...typeof t=="string"?lt(t):t,state:n,key:t&&t.key||r||ha()}}function xt({pathname:e="/",search:t="",hash:n=""}){return t&&t!=="?"&&(e+=t.charAt(0)==="?"?t:"?"+t),n&&n!=="#"&&(e+=n.charAt(0)==="#"?n:"#"+n),e}function lt(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substring(n),e=e.substring(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substring(r),e=e.substring(0,r)),e&&(t.pathname=e)}return t}function ga(e,t,n,r={}){let{window:o=document.defaultView,v5Compat:l=!1}=r,i=o.history,a="POP",s=null,u=c();u==null&&(u=0,i.replaceState({...i.state,idx:u},""));function c(){return(i.state||{idx:null}).idx}function d(){a="POP";let b=c(),x=b==null?null:b-u;u=b,s&&s({action:a,location:v.location,delta:x})}function m(b,x){a="PUSH";let y=Vn(v.location,b,x);u=c()+1;let w=Vr(y,u),S=v.createHref(y);try{i.pushState(w,"",S)}catch(C){if(C instanceof DOMException&&C.name==="DataCloneError")throw C;o.location.assign(S)}l&&s&&s({action:a,location:v.location,delta:1})}function f(b,x){a="REPLACE";let y=Vn(v.location,b,x);u=c();let w=Vr(y,u),S=v.createHref(y);i.replaceState(w,"",S),l&&s&&s({action:a,location:v.location,delta:0})}function h(b){return va(b)}let v={get action(){return a},get location(){return e(o,i)},listen(b){if(s)throw new Error("A history only accepts one active listener");return o.addEventListener(Hr,d),s=b,()=>{o.removeEventListener(Hr,d),s=null}},createHref(b){return t(o,b)},createURL:h,encodeLocation(b){let x=h(b);return{pathname:x.pathname,search:x.search,hash:x.hash}},push:m,replace:f,go(b){return i.go(b)}};return v}function va(e,t=!1){let n="http://localhost";typeof window<"u"&&(n=window.location.origin!=="null"?window.location.origin:window.location.href),G(n,"No window.location.(origin|href) available to create URL");let r=typeof e=="string"?e:xt(e);return r=r.replace(/ $/,"%20"),!t&&r.startsWith("//")&&(r=n+r),new URL(r,n)}function zo(e,t,n="/"){return ba(e,t,n,!1)}function ba(e,t,n,r){let o=typeof t=="string"?lt(t):t,l=Le(o.pathname||"/",n);if(l==null)return null;let i=Wo(e);xa(i);let a=null;for(let s=0;a==null&&s<i.length;++s){let u=qo(l);a=Oa(i[s],u,r)}return a}function Wo(e,t=[],n=[],r="",o=!1){let l=(i,a,s=o,u)=>{let c={relativePath:u===void 0?i.path||"":u,caseSensitive:i.caseSensitive===!0,childrenIndex:a,route:i};if(c.relativePath.startsWith("/")){if(!c.relativePath.startsWith(r)&&s)return;G(c.relativePath.startsWith(r),`Absolute route path "${c.relativePath}" nested under path "${r}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),c.relativePath=c.relativePath.slice(r.length)}let d=Pe([r,c.relativePath]),m=n.concat(c);i.children&&i.children.length>0&&(G(i.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${d}".`),Wo(i.children,t,m,d,s)),!(i.path==null&&!i.index)&&t.push({path:d,score:ka(d,i.index),routesMeta:m})};return e.forEach((i,a)=>{if(i.path===""||!i.path?.includes("?"))l(i,a);else for(let s of Uo(i.path))l(i,a,!0,s)}),t}function Uo(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,o=n.endsWith("?"),l=n.replace(/\?$/,"");if(r.length===0)return o?[l,""]:[l];let i=Uo(r.join("/")),a=[];return a.push(...i.map(s=>s===""?l:[l,s].join("/"))),o&&a.push(...i),a.map(s=>e.startsWith("/")&&s===""?"/":s)}function xa(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:Ra(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}var wa=/^:[\w-]+$/,ya=3,Ea=2,Ca=1,Sa=10,$a=-2,zr=e=>e==="*";function ka(e,t){let n=e.split("/"),r=n.length;return n.some(zr)&&(r+=$a),t&&(r+=Ea),n.filter(o=>!zr(o)).reduce((o,l)=>o+(wa.test(l)?ya:l===""?Ca:Sa),r)}function Ra(e,t){return e.length===t.length&&e.slice(0,-1).every((r,o)=>r===t[o])?e[e.length-1]-t[t.length-1]:0}function Oa(e,t,n=!1){let{routesMeta:r}=e,o={},l="/",i=[];for(let a=0;a<r.length;++a){let s=r[a],u=a===r.length-1,c=l==="/"?t:t.slice(l.length)||"/",d=wt({path:s.relativePath,caseSensitive:s.caseSensitive,end:u},c),m=s.route;if(!d&&u&&n&&!r[r.length-1].route.index&&(d=wt({path:s.relativePath,caseSensitive:s.caseSensitive,end:!1},c)),!d)return null;Object.assign(o,d.params),i.push({params:o,pathname:Pe([l,d.pathname]),pathnameBase:Ma(Pe([l,d.pathnameBase])),route:m}),d.pathnameBase!=="/"&&(l=Pe([l,d.pathnameBase]))}return i}function wt(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=Ta(e.path,e.caseSensitive,e.end),o=t.match(n);if(!o)return null;let l=o[0],i=l.replace(/(.)\/+$/,"$1"),a=o.slice(1);return{params:r.reduce((u,{paramName:c,isOptional:d},m)=>{if(c==="*"){let h=a[m]||"";i=l.slice(0,l.length-h.length).replace(/(.)\/+$/,"$1")}const f=a[m];return d&&!f?u[c]=void 0:u[c]=(f||"").replace(/%2F/g,"/"),u},{}),pathname:l,pathnameBase:i,pattern:e}}function Ta(e,t=!1,n=!0){we(e==="*"||!e.endsWith("*")||e.endsWith("/*"),`Route path "${e}" will be treated as if it were "${e.replace(/\*$/,"/*")}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${e.replace(/\*$/,"/*")}".`);let r=[],o="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(i,a,s)=>(r.push({paramName:a,isOptional:s!=null}),s?"/?([^\\/]+)?":"/([^\\/]+)")).replace(/\/([\w-]+)\?(\/|$)/g,"(/$1)?$2");return e.endsWith("*")?(r.push({paramName:"*"}),o+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?o+="\\/*$":e!==""&&e!=="/"&&(o+="(?:(?=\\/|$))"),[new RegExp(o,t?void 0:"i"),r]}function qo(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return we(!1,`The URL path "${e}" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (${t}).`),e}}function Le(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,r=e.charAt(n);return r&&r!=="/"?null:e.slice(n)||"/"}var Pa=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,La=e=>Pa.test(e);function Aa(e,t="/"){let{pathname:n,search:r="",hash:o=""}=typeof e=="string"?lt(e):e,l;if(n)if(La(n))l=n;else{if(n.includes("//")){let i=n;n=n.replace(/\/\/+/g,"/"),we(!1,`Pathnames cannot have embedded double slashes - normalizing ${i} -> ${n}`)}n.startsWith("/")?l=Wr(n.substring(1),"/"):l=Wr(n,t)}else l=t;return{pathname:l,search:Na(r),hash:Ia(o)}}function Wr(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(o=>{o===".."?n.length>1&&n.pop():o!=="."&&n.push(o)}),n.length>1?n.join("/"):"/"}function Sn(e,t,n,r){return`Cannot include a '${e}' character in a manually specified \`to.${t}\` field [${JSON.stringify(r)}]. Please separate it out to the \`to.${n}\` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.`}function Fa(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function Go(e){let t=Fa(e);return t.map((n,r)=>r===t.length-1?n.pathname:n.pathnameBase)}function Ko(e,t,n,r=!1){let o;typeof e=="string"?o=lt(e):(o={...e},G(!o.pathname||!o.pathname.includes("?"),Sn("?","pathname","search",o)),G(!o.pathname||!o.pathname.includes("#"),Sn("#","pathname","hash",o)),G(!o.search||!o.search.includes("#"),Sn("#","search","hash",o)));let l=e===""||o.pathname==="",i=l?"/":o.pathname,a;if(i==null)a=n;else{let d=t.length-1;if(!r&&i.startsWith("..")){let m=i.split("/");for(;m[0]==="..";)m.shift(),d-=1;o.pathname=m.join("/")}a=d>=0?t[d]:"/"}let s=Aa(o,a),u=i&&i!=="/"&&i.endsWith("/"),c=(l||i===".")&&n.endsWith("/");return!s.pathname.endsWith("/")&&(u||c)&&(s.pathname+="/"),s}var Pe=e=>e.join("/").replace(/\/\/+/g,"/"),Ma=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),Na=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,Ia=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function ja(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}function Da(e){return e.map(t=>t.route.path).filter(Boolean).join("/").replace(/\/\/*/g,"/")||"/"}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");var Yo=["POST","PUT","PATCH","DELETE"];new Set(Yo);var _a=["GET",...Yo];new Set(_a);var it=g.createContext(null);it.displayName="DataRouter";var ln=g.createContext(null);ln.displayName="DataRouterState";g.createContext(!1);var Zo=g.createContext({isTransitioning:!1});Zo.displayName="ViewTransition";var Ba=g.createContext(new Map);Ba.displayName="Fetchers";var Ha=g.createContext(null);Ha.displayName="Await";var Ee=g.createContext(null);Ee.displayName="Navigation";var kt=g.createContext(null);kt.displayName="Location";var Ae=g.createContext({outlet:null,matches:[],isDataRoute:!1});Ae.displayName="Route";var ar=g.createContext(null);ar.displayName="RouteError";function Va(e,{relative:t}={}){G(at(),"useHref() may be used only in the context of a <Router> component.");let{basename:n,navigator:r}=g.useContext(Ee),{hash:o,pathname:l,search:i}=Rt(e,{relative:t}),a=l;return n!=="/"&&(a=l==="/"?n:Pe([n,l])),r.createHref({pathname:a,search:i,hash:o})}function at(){return g.useContext(kt)!=null}function Fe(){return G(at(),"useLocation() may be used only in the context of a <Router> component."),g.useContext(kt).location}function za(e){G(at(),"useMatch() may be used only in the context of a <Router> component.");let{pathname:t}=Fe();return g.useMemo(()=>wt(e,qo(t)),[t,e])}var Xo="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function Jo(e){g.useContext(Ee).static||g.useLayoutEffect(e)}function Qo(){let{isDataRoute:e}=g.useContext(Ae);return e?ns():Wa()}function Wa(){G(at(),"useNavigate() may be used only in the context of a <Router> component.");let e=g.useContext(it),{basename:t,navigator:n}=g.useContext(Ee),{matches:r}=g.useContext(Ae),{pathname:o}=Fe(),l=JSON.stringify(Go(r)),i=g.useRef(!1);return Jo(()=>{i.current=!0}),g.useCallback((s,u={})=>{if(we(i.current,Xo),!i.current)return;if(typeof s=="number"){n.go(s);return}let c=Ko(s,JSON.parse(l),o,u.relative==="path");e==null&&t!=="/"&&(c.pathname=c.pathname==="/"?t:Pe([t,c.pathname])),(u.replace?n.replace:n.push)(c,u.state,u)},[t,n,l,o,e])}g.createContext(null);function Rt(e,{relative:t}={}){let{matches:n}=g.useContext(Ae),{pathname:r}=Fe(),o=JSON.stringify(Go(n));return g.useMemo(()=>Ko(e,JSON.parse(o),r,t==="path"),[e,o,r,t])}function Ua(e,t){return el(e,t)}function el(e,t,n,r,o){G(at(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:l}=g.useContext(Ee),{matches:i}=g.useContext(Ae),a=i[i.length-1],s=a?a.params:{},u=a?a.pathname:"/",c=a?a.pathnameBase:"/",d=a&&a.route;{let y=d&&d.path||"";tl(u,!d||y.endsWith("*")||y.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${u}" (under <Route path="${y}">) but the parent route path has no trailing "*". This means if you navigate deeper, the parent won't match anymore and therefore the child routes will never render.
|
|
1
|
+
"use client";"use strict";const E=require("react/jsx-runtime"),p=require("react"),Ge=require("react-dom");function Bo(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const g=Bo(p),Zt=Bo(Ge);function Qi({title:e,titleId:t,...n},r){return g.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?g.createElement("title",{id:t},e):null,g.createElement("path",{fillRule:"evenodd",d:"M15.312 11.424a5.5 5.5 0 0 1-9.201 2.466l-.312-.311h2.433a.75.75 0 0 0 0-1.5H3.989a.75.75 0 0 0-.75.75v4.242a.75.75 0 0 0 1.5 0v-2.43l.31.31a7 7 0 0 0 11.712-3.138.75.75 0 0 0-1.449-.39Zm1.23-3.723a.75.75 0 0 0 .219-.53V2.929a.75.75 0 0 0-1.5 0V5.36l-.31-.31A7 7 0 0 0 3.239 8.188a.75.75 0 1 0 1.448.389A5.5 5.5 0 0 1 13.89 6.11l.311.31h-2.432a.75.75 0 0 0 0 1.5h4.243a.75.75 0 0 0 .53-.219Z",clipRule:"evenodd"}))}const ea=g.forwardRef(Qi);function ta({title:e,titleId:t,...n},r){return g.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?g.createElement("title",{id:t},e):null,g.createElement("path",{fillRule:"evenodd",d:"M4.25 5.5a.75.75 0 0 0-.75.75v8.5c0 .414.336.75.75.75h8.5a.75.75 0 0 0 .75-.75v-4a.75.75 0 0 1 1.5 0v4A2.25 2.25 0 0 1 12.75 17h-8.5A2.25 2.25 0 0 1 2 14.75v-8.5A2.25 2.25 0 0 1 4.25 4h5a.75.75 0 0 1 0 1.5h-5Z",clipRule:"evenodd"}),g.createElement("path",{fillRule:"evenodd",d:"M6.194 12.753a.75.75 0 0 0 1.06.053L16.5 4.44v2.81a.75.75 0 0 0 1.5 0v-4.5a.75.75 0 0 0-.75-.75h-4.5a.75.75 0 0 0 0 1.5h2.553l-9.056 8.194a.75.75 0 0 0-.053 1.06Z",clipRule:"evenodd"}))}const Ho=g.forwardRef(ta);function na({title:e,titleId:t,...n},r){return g.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?g.createElement("title",{id:t},e):null,g.createElement("path",{fillRule:"evenodd",d:"M2 3.75A.75.75 0 0 1 2.75 3h14.5a.75.75 0 0 1 0 1.5H2.75A.75.75 0 0 1 2 3.75Zm0 4.167a.75.75 0 0 1 .75-.75h14.5a.75.75 0 0 1 0 1.5H2.75a.75.75 0 0 1-.75-.75Zm0 4.166a.75.75 0 0 1 .75-.75h14.5a.75.75 0 0 1 0 1.5H2.75a.75.75 0 0 1-.75-.75Zm0 4.167a.75.75 0 0 1 .75-.75h14.5a.75.75 0 0 1 0 1.5H2.75a.75.75 0 0 1-.75-.75Z",clipRule:"evenodd"}))}const ra=g.forwardRef(na);function oa({title:e,titleId:t,...n},r){return g.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?g.createElement("title",{id:t},e):null,g.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 1 0 0-16 8 8 0 0 0 0 16Zm3.857-9.809a.75.75 0 0 0-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 1 0-1.06 1.061l2.5 2.5a.75.75 0 0 0 1.137-.089l4-5.5Z",clipRule:"evenodd"}))}const la=g.forwardRef(oa);function ia({title:e,titleId:t,...n},r){return g.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?g.createElement("title",{id:t},e):null,g.createElement("path",{fillRule:"evenodd",d:"M8.22 5.22a.75.75 0 0 1 1.06 0l4.25 4.25a.75.75 0 0 1 0 1.06l-4.25 4.25a.75.75 0 0 1-1.06-1.06L11.94 10 8.22 6.28a.75.75 0 0 1 0-1.06Z",clipRule:"evenodd"}))}const Vo=g.forwardRef(ia);function aa({title:e,titleId:t,...n},r){return g.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?g.createElement("title",{id:t},e):null,g.createElement("path",{fillRule:"evenodd",d:"M10.53 3.47a.75.75 0 0 0-1.06 0L6.22 6.72a.75.75 0 0 0 1.06 1.06L10 5.06l2.72 2.72a.75.75 0 1 0 1.06-1.06l-3.25-3.25Zm-4.31 9.81 3.25 3.25a.75.75 0 0 0 1.06 0l3.25-3.25a.75.75 0 1 0-1.06-1.06L10 14.94l-2.72-2.72a.75.75 0 0 0-1.06 1.06Z",clipRule:"evenodd"}))}const sa=g.forwardRef(aa);function ua({title:e,titleId:t,...n},r){return g.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?g.createElement("title",{id:t},e):null,g.createElement("path",{fillRule:"evenodd",d:"M8.485 2.495c.673-1.167 2.357-1.167 3.03 0l6.28 10.875c.673 1.167-.17 2.625-1.516 2.625H3.72c-1.347 0-2.189-1.458-1.515-2.625L8.485 2.495ZM10 5a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 10 5Zm0 9a1 1 0 1 0 0-2 1 1 0 0 0 0 2Z",clipRule:"evenodd"}))}const ca=g.forwardRef(ua);function da({title:e,titleId:t,...n},r){return g.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?g.createElement("title",{id:t},e):null,g.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 1 1-16 0 8 8 0 0 1 16 0Zm-7-4a1 1 0 1 1-2 0 1 1 0 0 1 2 0ZM9 9a.75.75 0 0 0 0 1.5h.253a.25.25 0 0 1 .244.304l-.459 2.066A1.75 1.75 0 0 0 10.747 15H11a.75.75 0 0 0 0-1.5h-.253a.25.25 0 0 1-.244-.304l.459-2.066A1.75 1.75 0 0 0 9.253 9H9Z",clipRule:"evenodd"}))}const fa=g.forwardRef(da);function pa({title:e,titleId:t,...n},r){return g.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?g.createElement("title",{id:t},e):null,g.createElement("path",{d:"M6.28 5.22a.75.75 0 0 0-1.06 1.06L8.94 10l-3.72 3.72a.75.75 0 1 0 1.06 1.06L10 11.06l3.72 3.72a.75.75 0 1 0 1.06-1.06L11.06 10l3.72-3.72a.75.75 0 0 0-1.06-1.06L10 8.94 6.28 5.22Z"}))}const ma=g.forwardRef(pa);var Hr="popstate";function ha(e={}){function t(r,o){let{pathname:l,search:i,hash:a}=r.location;return Vn("",{pathname:l,search:i,hash:a},o.state&&o.state.usr||null,o.state&&o.state.key||"default")}function n(r,o){return typeof o=="string"?o:xt(o)}return va(t,n,null,e)}function G(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function we(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function ga(){return Math.random().toString(36).substring(2,10)}function Vr(e,t){return{usr:e.state,key:e.key,idx:t}}function Vn(e,t,n=null,r){return{pathname:typeof e=="string"?e:e.pathname,search:"",hash:"",...typeof t=="string"?lt(t):t,state:n,key:t&&t.key||r||ga()}}function xt({pathname:e="/",search:t="",hash:n=""}){return t&&t!=="?"&&(e+=t.charAt(0)==="?"?t:"?"+t),n&&n!=="#"&&(e+=n.charAt(0)==="#"?n:"#"+n),e}function lt(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substring(n),e=e.substring(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substring(r),e=e.substring(0,r)),e&&(t.pathname=e)}return t}function va(e,t,n,r={}){let{window:o=document.defaultView,v5Compat:l=!1}=r,i=o.history,a="POP",s=null,u=c();u==null&&(u=0,i.replaceState({...i.state,idx:u},""));function c(){return(i.state||{idx:null}).idx}function d(){a="POP";let b=c(),x=b==null?null:b-u;u=b,s&&s({action:a,location:v.location,delta:x})}function m(b,x){a="PUSH";let y=Vn(v.location,b,x);u=c()+1;let w=Vr(y,u),S=v.createHref(y);try{i.pushState(w,"",S)}catch(C){if(C instanceof DOMException&&C.name==="DataCloneError")throw C;o.location.assign(S)}l&&s&&s({action:a,location:v.location,delta:1})}function f(b,x){a="REPLACE";let y=Vn(v.location,b,x);u=c();let w=Vr(y,u),S=v.createHref(y);i.replaceState(w,"",S),l&&s&&s({action:a,location:v.location,delta:0})}function h(b){return ba(b)}let v={get action(){return a},get location(){return e(o,i)},listen(b){if(s)throw new Error("A history only accepts one active listener");return o.addEventListener(Hr,d),s=b,()=>{o.removeEventListener(Hr,d),s=null}},createHref(b){return t(o,b)},createURL:h,encodeLocation(b){let x=h(b);return{pathname:x.pathname,search:x.search,hash:x.hash}},push:m,replace:f,go(b){return i.go(b)}};return v}function ba(e,t=!1){let n="http://localhost";typeof window<"u"&&(n=window.location.origin!=="null"?window.location.origin:window.location.href),G(n,"No window.location.(origin|href) available to create URL");let r=typeof e=="string"?e:xt(e);return r=r.replace(/ $/,"%20"),!t&&r.startsWith("//")&&(r=n+r),new URL(r,n)}function zo(e,t,n="/"){return xa(e,t,n,!1)}function xa(e,t,n,r){let o=typeof t=="string"?lt(t):t,l=Le(o.pathname||"/",n);if(l==null)return null;let i=Wo(e);wa(i);let a=null;for(let s=0;a==null&&s<i.length;++s){let u=qo(l);a=Ta(i[s],u,r)}return a}function Wo(e,t=[],n=[],r="",o=!1){let l=(i,a,s=o,u)=>{let c={relativePath:u===void 0?i.path||"":u,caseSensitive:i.caseSensitive===!0,childrenIndex:a,route:i};if(c.relativePath.startsWith("/")){if(!c.relativePath.startsWith(r)&&s)return;G(c.relativePath.startsWith(r),`Absolute route path "${c.relativePath}" nested under path "${r}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),c.relativePath=c.relativePath.slice(r.length)}let d=Pe([r,c.relativePath]),m=n.concat(c);i.children&&i.children.length>0&&(G(i.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${d}".`),Wo(i.children,t,m,d,s)),!(i.path==null&&!i.index)&&t.push({path:d,score:Ra(d,i.index),routesMeta:m})};return e.forEach((i,a)=>{if(i.path===""||!i.path?.includes("?"))l(i,a);else for(let s of Uo(i.path))l(i,a,!0,s)}),t}function Uo(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,o=n.endsWith("?"),l=n.replace(/\?$/,"");if(r.length===0)return o?[l,""]:[l];let i=Uo(r.join("/")),a=[];return a.push(...i.map(s=>s===""?l:[l,s].join("/"))),o&&a.push(...i),a.map(s=>e.startsWith("/")&&s===""?"/":s)}function wa(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:Oa(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}var ya=/^:[\w-]+$/,Ea=3,Ca=2,Sa=1,$a=10,ka=-2,zr=e=>e==="*";function Ra(e,t){let n=e.split("/"),r=n.length;return n.some(zr)&&(r+=ka),t&&(r+=Ca),n.filter(o=>!zr(o)).reduce((o,l)=>o+(ya.test(l)?Ea:l===""?Sa:$a),r)}function Oa(e,t){return e.length===t.length&&e.slice(0,-1).every((r,o)=>r===t[o])?e[e.length-1]-t[t.length-1]:0}function Ta(e,t,n=!1){let{routesMeta:r}=e,o={},l="/",i=[];for(let a=0;a<r.length;++a){let s=r[a],u=a===r.length-1,c=l==="/"?t:t.slice(l.length)||"/",d=wt({path:s.relativePath,caseSensitive:s.caseSensitive,end:u},c),m=s.route;if(!d&&u&&n&&!r[r.length-1].route.index&&(d=wt({path:s.relativePath,caseSensitive:s.caseSensitive,end:!1},c)),!d)return null;Object.assign(o,d.params),i.push({params:o,pathname:Pe([l,d.pathname]),pathnameBase:Na(Pe([l,d.pathnameBase])),route:m}),d.pathnameBase!=="/"&&(l=Pe([l,d.pathnameBase]))}return i}function wt(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=Pa(e.path,e.caseSensitive,e.end),o=t.match(n);if(!o)return null;let l=o[0],i=l.replace(/(.)\/+$/,"$1"),a=o.slice(1);return{params:r.reduce((u,{paramName:c,isOptional:d},m)=>{if(c==="*"){let h=a[m]||"";i=l.slice(0,l.length-h.length).replace(/(.)\/+$/,"$1")}const f=a[m];return d&&!f?u[c]=void 0:u[c]=(f||"").replace(/%2F/g,"/"),u},{}),pathname:l,pathnameBase:i,pattern:e}}function Pa(e,t=!1,n=!0){we(e==="*"||!e.endsWith("*")||e.endsWith("/*"),`Route path "${e}" will be treated as if it were "${e.replace(/\*$/,"/*")}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${e.replace(/\*$/,"/*")}".`);let r=[],o="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(i,a,s)=>(r.push({paramName:a,isOptional:s!=null}),s?"/?([^\\/]+)?":"/([^\\/]+)")).replace(/\/([\w-]+)\?(\/|$)/g,"(/$1)?$2");return e.endsWith("*")?(r.push({paramName:"*"}),o+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?o+="\\/*$":e!==""&&e!=="/"&&(o+="(?:(?=\\/|$))"),[new RegExp(o,t?void 0:"i"),r]}function qo(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return we(!1,`The URL path "${e}" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (${t}).`),e}}function Le(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,r=e.charAt(n);return r&&r!=="/"?null:e.slice(n)||"/"}var La=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Aa=e=>La.test(e);function Fa(e,t="/"){let{pathname:n,search:r="",hash:o=""}=typeof e=="string"?lt(e):e,l;if(n)if(Aa(n))l=n;else{if(n.includes("//")){let i=n;n=n.replace(/\/\/+/g,"/"),we(!1,`Pathnames cannot have embedded double slashes - normalizing ${i} -> ${n}`)}n.startsWith("/")?l=Wr(n.substring(1),"/"):l=Wr(n,t)}else l=t;return{pathname:l,search:Ia(r),hash:ja(o)}}function Wr(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(o=>{o===".."?n.length>1&&n.pop():o!=="."&&n.push(o)}),n.length>1?n.join("/"):"/"}function Sn(e,t,n,r){return`Cannot include a '${e}' character in a manually specified \`to.${t}\` field [${JSON.stringify(r)}]. Please separate it out to the \`to.${n}\` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.`}function Ma(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function Go(e){let t=Ma(e);return t.map((n,r)=>r===t.length-1?n.pathname:n.pathnameBase)}function Ko(e,t,n,r=!1){let o;typeof e=="string"?o=lt(e):(o={...e},G(!o.pathname||!o.pathname.includes("?"),Sn("?","pathname","search",o)),G(!o.pathname||!o.pathname.includes("#"),Sn("#","pathname","hash",o)),G(!o.search||!o.search.includes("#"),Sn("#","search","hash",o)));let l=e===""||o.pathname==="",i=l?"/":o.pathname,a;if(i==null)a=n;else{let d=t.length-1;if(!r&&i.startsWith("..")){let m=i.split("/");for(;m[0]==="..";)m.shift(),d-=1;o.pathname=m.join("/")}a=d>=0?t[d]:"/"}let s=Fa(o,a),u=i&&i!=="/"&&i.endsWith("/"),c=(l||i===".")&&n.endsWith("/");return!s.pathname.endsWith("/")&&(u||c)&&(s.pathname+="/"),s}var Pe=e=>e.join("/").replace(/\/\/+/g,"/"),Na=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),Ia=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,ja=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function Da(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}function _a(e){return e.map(t=>t.route.path).filter(Boolean).join("/").replace(/\/\/*/g,"/")||"/"}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");var Yo=["POST","PUT","PATCH","DELETE"];new Set(Yo);var Ba=["GET",...Yo];new Set(Ba);var it=g.createContext(null);it.displayName="DataRouter";var ln=g.createContext(null);ln.displayName="DataRouterState";g.createContext(!1);var Zo=g.createContext({isTransitioning:!1});Zo.displayName="ViewTransition";var Ha=g.createContext(new Map);Ha.displayName="Fetchers";var Va=g.createContext(null);Va.displayName="Await";var Ee=g.createContext(null);Ee.displayName="Navigation";var kt=g.createContext(null);kt.displayName="Location";var Ae=g.createContext({outlet:null,matches:[],isDataRoute:!1});Ae.displayName="Route";var ar=g.createContext(null);ar.displayName="RouteError";function za(e,{relative:t}={}){G(at(),"useHref() may be used only in the context of a <Router> component.");let{basename:n,navigator:r}=g.useContext(Ee),{hash:o,pathname:l,search:i}=Rt(e,{relative:t}),a=l;return n!=="/"&&(a=l==="/"?n:Pe([n,l])),r.createHref({pathname:a,search:i,hash:o})}function at(){return g.useContext(kt)!=null}function Fe(){return G(at(),"useLocation() may be used only in the context of a <Router> component."),g.useContext(kt).location}function Wa(e){G(at(),"useMatch() may be used only in the context of a <Router> component.");let{pathname:t}=Fe();return g.useMemo(()=>wt(e,qo(t)),[t,e])}var Xo="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function Jo(e){g.useContext(Ee).static||g.useLayoutEffect(e)}function Qo(){let{isDataRoute:e}=g.useContext(Ae);return e?rs():Ua()}function Ua(){G(at(),"useNavigate() may be used only in the context of a <Router> component.");let e=g.useContext(it),{basename:t,navigator:n}=g.useContext(Ee),{matches:r}=g.useContext(Ae),{pathname:o}=Fe(),l=JSON.stringify(Go(r)),i=g.useRef(!1);return Jo(()=>{i.current=!0}),g.useCallback((s,u={})=>{if(we(i.current,Xo),!i.current)return;if(typeof s=="number"){n.go(s);return}let c=Ko(s,JSON.parse(l),o,u.relative==="path");e==null&&t!=="/"&&(c.pathname=c.pathname==="/"?t:Pe([t,c.pathname])),(u.replace?n.replace:n.push)(c,u.state,u)},[t,n,l,o,e])}g.createContext(null);function Rt(e,{relative:t}={}){let{matches:n}=g.useContext(Ae),{pathname:r}=Fe(),o=JSON.stringify(Go(n));return g.useMemo(()=>Ko(e,JSON.parse(o),r,t==="path"),[e,o,r,t])}function qa(e,t){return el(e,t)}function el(e,t,n,r,o){G(at(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:l}=g.useContext(Ee),{matches:i}=g.useContext(Ae),a=i[i.length-1],s=a?a.params:{},u=a?a.pathname:"/",c=a?a.pathnameBase:"/",d=a&&a.route;{let y=d&&d.path||"";tl(u,!d||y.endsWith("*")||y.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${u}" (under <Route path="${y}">) but the parent route path has no trailing "*". This means if you navigate deeper, the parent won't match anymore and therefore the child routes will never render.
|
|
2
2
|
|
|
3
|
-
Please change the parent <Route path="${y}"> to <Route path="${y==="/"?"*":`${y}/*`}">.`)}let m=Fe(),f;if(t){let y=typeof t=="string"?lt(t):t;G(c==="/"||y.pathname?.startsWith(c),`When overriding the location using \`<Routes location>\` or \`useRoutes(routes, location)\`, the location pathname must begin with the portion of the URL pathname that was matched by all parent routes. The current pathname base is "${c}" but pathname "${y.pathname}" was given in the \`location\` prop.`),f=y}else f=m;let h=f.pathname||"/",v=h;if(c!=="/"){let y=c.replace(/^\//,"").split("/");v="/"+h.replace(/^\//,"").split("/").slice(y.length).join("/")}let b=zo(e,{pathname:v});we(d||b!=null,`No routes matched location "${f.pathname}${f.search}${f.hash}" `),we(b==null||b[b.length-1].route.element!==void 0||b[b.length-1].route.Component!==void 0||b[b.length-1].route.lazy!==void 0,`Matched leaf route at location "${f.pathname}${f.search}${f.hash}" does not have an element or Component. This means it will render an <Outlet /> with a null value by default resulting in an "empty" page.`);let x=Za(b&&b.map(y=>Object.assign({},y,{params:Object.assign({},s,y.params),pathname:Pe([c,l.encodeLocation?l.encodeLocation(y.pathname.replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:y.pathname]),pathnameBase:y.pathnameBase==="/"?c:Pe([c,l.encodeLocation?l.encodeLocation(y.pathnameBase.replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:y.pathnameBase])})),i,n,r,o);return t&&x?g.createElement(kt.Provider,{value:{location:{pathname:"/",search:"",hash:"",state:null,key:"default",...f},navigationType:"POP"}},x):x}function qa(){let e=ts(),t=ja(e)?`${e.status} ${e.statusText}`:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,r="rgba(200,200,200, 0.5)",o={padding:"0.5rem",backgroundColor:r},l={padding:"2px 4px",backgroundColor:r},i=null;return console.error("Error handled by React Router default ErrorBoundary:",e),i=g.createElement(g.Fragment,null,g.createElement("p",null,"💿 Hey developer 👋"),g.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",g.createElement("code",{style:l},"ErrorBoundary")," or"," ",g.createElement("code",{style:l},"errorElement")," prop on your route.")),g.createElement(g.Fragment,null,g.createElement("h2",null,"Unexpected Application Error!"),g.createElement("h3",{style:{fontStyle:"italic"}},t),n?g.createElement("pre",{style:o},n):null,i)}var Ga=g.createElement(qa,null),Ka=class extends g.Component{constructor(e){super(e),this.state={location:e.location,revalidation:e.revalidation,error:e.error}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,t){return t.location!==e.location||t.revalidation!=="idle"&&e.revalidation==="idle"?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:e.error!==void 0?e.error:t.error,location:t.location,revalidation:e.revalidation||t.revalidation}}componentDidCatch(e,t){this.props.onError?this.props.onError(e,t):console.error("React Router caught the following error during render",e)}render(){return this.state.error!==void 0?g.createElement(Ae.Provider,{value:this.props.routeContext},g.createElement(ar.Provider,{value:this.state.error,children:this.props.component})):this.props.children}};function Ya({routeContext:e,match:t,children:n}){let r=g.useContext(it);return r&&r.static&&r.staticContext&&(t.route.errorElement||t.route.ErrorBoundary)&&(r.staticContext._deepestRenderedBoundaryId=t.route.id),g.createElement(Ae.Provider,{value:e},n)}function Za(e,t=[],n=null,r=null,o=null){if(e==null){if(!n)return null;if(n.errors)e=n.matches;else if(t.length===0&&!n.initialized&&n.matches.length>0)e=n.matches;else return null}let l=e,i=n?.errors;if(i!=null){let c=l.findIndex(d=>d.route.id&&i?.[d.route.id]!==void 0);G(c>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(i).join(",")}`),l=l.slice(0,Math.min(l.length,c+1))}let a=!1,s=-1;if(n)for(let c=0;c<l.length;c++){let d=l[c];if((d.route.HydrateFallback||d.route.hydrateFallbackElement)&&(s=c),d.route.id){let{loaderData:m,errors:f}=n,h=d.route.loader&&!m.hasOwnProperty(d.route.id)&&(!f||f[d.route.id]===void 0);if(d.route.lazy||h){a=!0,s>=0?l=l.slice(0,s+1):l=[l[0]];break}}}let u=n&&r?(c,d)=>{r(c,{location:n.location,params:n.matches?.[0]?.params??{},unstable_pattern:Da(n.matches),errorInfo:d})}:void 0;return l.reduceRight((c,d,m)=>{let f,h=!1,v=null,b=null;n&&(f=i&&d.route.id?i[d.route.id]:void 0,v=d.route.errorElement||Ga,a&&(s<0&&m===0?(tl("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),h=!0,b=null):s===m&&(h=!0,b=d.route.hydrateFallbackElement||null)));let x=t.concat(l.slice(0,m+1)),y=()=>{let w;return f?w=v:h?w=b:d.route.Component?w=g.createElement(d.route.Component,null):d.route.element?w=d.route.element:w=c,g.createElement(Ya,{match:d,routeContext:{outlet:c,matches:x,isDataRoute:n!=null},children:w})};return n&&(d.route.ErrorBoundary||d.route.errorElement||m===0)?g.createElement(Ka,{location:n.location,revalidation:n.revalidation,component:v,error:f,children:y(),routeContext:{outlet:null,matches:x,isDataRoute:!0},onError:u}):y()},null)}function sr(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function Xa(e){let t=g.useContext(it);return G(t,sr(e)),t}function Ja(e){let t=g.useContext(ln);return G(t,sr(e)),t}function Qa(e){let t=g.useContext(Ae);return G(t,sr(e)),t}function ur(e){let t=Qa(e),n=t.matches[t.matches.length-1];return G(n.route.id,`${e} can only be used on routes that contain a unique "id"`),n.route.id}function es(){return ur("useRouteId")}function ts(){let e=g.useContext(ar),t=Ja("useRouteError"),n=ur("useRouteError");return e!==void 0?e:t.errors?.[n]}function ns(){let{router:e}=Xa("useNavigate"),t=ur("useNavigate"),n=g.useRef(!1);return Jo(()=>{n.current=!0}),g.useCallback(async(o,l={})=>{we(n.current,Xo),n.current&&(typeof o=="number"?await e.navigate(o):await e.navigate(o,{fromRouteId:t,...l}))},[e,t])}var Ur={};function tl(e,t,n){!t&&!Ur[e]&&(Ur[e]=!0,we(!1,n))}g.memo(rs);function rs({routes:e,future:t,state:n,unstable_onError:r}){return el(e,void 0,n,r,t)}function nl(e){G(!1,"A <Route> is only ever to be used as the child of <Routes> element, never rendered directly. Please wrap your <Route> in a <Routes>.")}function os({basename:e="/",children:t=null,location:n,navigationType:r="POP",navigator:o,static:l=!1,unstable_useTransitions:i}){G(!at(),"You cannot render a <Router> inside another <Router>. You should never have more than one in your app.");let a=e.replace(/^\/*/,"/"),s=g.useMemo(()=>({basename:a,navigator:o,static:l,unstable_useTransitions:i,future:{}}),[a,o,l,i]);typeof n=="string"&&(n=lt(n));let{pathname:u="/",search:c="",hash:d="",state:m=null,key:f="default"}=n,h=g.useMemo(()=>{let v=Le(u,a);return v==null?null:{location:{pathname:v,search:c,hash:d,state:m,key:f},navigationType:r}},[a,u,c,d,m,f,r]);return we(h!=null,`<Router basename="${a}"> is not able to match the URL "${u}${c}${d}" because it does not start with the basename, so the <Router> won't render anything.`),h==null?null:g.createElement(Ee.Provider,{value:s},g.createElement(kt.Provider,{children:t,value:h}))}function ls({children:e,location:t}){return Ua(zn(e),t)}function zn(e,t=[]){let n=[];return g.Children.forEach(e,(r,o)=>{if(!g.isValidElement(r))return;let l=[...t,o];if(r.type===g.Fragment){n.push.apply(n,zn(r.props.children,l));return}G(r.type===nl,`[${typeof r.type=="string"?r.type:r.type.name}] is not a <Route> component. All component children of <Routes> must be a <Route> or <React.Fragment>`),G(!r.props.index||!r.props.children,"An index route cannot have child routes.");let i={id:r.props.id||l.join("-"),caseSensitive:r.props.caseSensitive,element:r.props.element,Component:r.props.Component,index:r.props.index,path:r.props.path,middleware:r.props.middleware,loader:r.props.loader,action:r.props.action,hydrateFallbackElement:r.props.hydrateFallbackElement,HydrateFallback:r.props.HydrateFallback,errorElement:r.props.errorElement,ErrorBoundary:r.props.ErrorBoundary,hasErrorBoundary:r.props.hasErrorBoundary===!0||r.props.ErrorBoundary!=null||r.props.errorElement!=null,shouldRevalidate:r.props.shouldRevalidate,handle:r.props.handle,lazy:r.props.lazy};r.props.children&&(i.children=zn(r.props.children,l)),n.push(i)}),n}var Ut="get",qt="application/x-www-form-urlencoded";function an(e){return typeof HTMLElement<"u"&&e instanceof HTMLElement}function is(e){return an(e)&&e.tagName.toLowerCase()==="button"}function as(e){return an(e)&&e.tagName.toLowerCase()==="form"}function ss(e){return an(e)&&e.tagName.toLowerCase()==="input"}function us(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function cs(e,t){return e.button===0&&(!t||t==="_self")&&!us(e)}var It=null;function ds(){if(It===null)try{new FormData(document.createElement("form"),0),It=!1}catch{It=!0}return It}var fs=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function $n(e){return e!=null&&!fs.has(e)?(we(!1,`"${e}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${qt}"`),null):e}function ps(e,t){let n,r,o,l,i;if(as(e)){let a=e.getAttribute("action");r=a?Le(a,t):null,n=e.getAttribute("method")||Ut,o=$n(e.getAttribute("enctype"))||qt,l=new FormData(e)}else if(is(e)||ss(e)&&(e.type==="submit"||e.type==="image")){let a=e.form;if(a==null)throw new Error('Cannot submit a <button> or <input type="submit"> without a <form>');let s=e.getAttribute("formaction")||a.getAttribute("action");if(r=s?Le(s,t):null,n=e.getAttribute("formmethod")||a.getAttribute("method")||Ut,o=$n(e.getAttribute("formenctype"))||$n(a.getAttribute("enctype"))||qt,l=new FormData(a,e),!ds()){let{name:u,type:c,value:d}=e;if(c==="image"){let m=u?`${u}.`:"";l.append(`${m}x`,"0"),l.append(`${m}y`,"0")}else u&&l.append(u,d)}}else{if(an(e))throw new Error('Cannot submit element that is not <form>, <button>, or <input type="submit|image">');n=Ut,r=null,o=qt,i=e}return l&&o==="text/plain"&&(i=l,l=void 0),{action:r,method:n.toLowerCase(),encType:o,formData:l,body:i}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");function cr(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function ms(e,t,n){let r=typeof e=="string"?new URL(e,typeof window>"u"?"server://singlefetch/":window.location.origin):e;return r.pathname==="/"?r.pathname=`_root.${n}`:t&&Le(r.pathname,t)==="/"?r.pathname=`${t.replace(/\/$/,"")}/_root.${n}`:r.pathname=`${r.pathname.replace(/\/$/,"")}.${n}`,r}async function hs(e,t){if(e.id in t)return t[e.id];try{let n=await import(e.module);return t[e.id]=n,n}catch(n){return console.error(`Error loading route module \`${e.module}\`, reloading page...`),console.error(n),window.__reactRouterContext&&window.__reactRouterContext.isSpaMode,window.location.reload(),new Promise(()=>{})}}function gs(e){return e==null?!1:e.href==null?e.rel==="preload"&&typeof e.imageSrcSet=="string"&&typeof e.imageSizes=="string":typeof e.rel=="string"&&typeof e.href=="string"}async function vs(e,t,n){let r=await Promise.all(e.map(async o=>{let l=t.routes[o.route.id];if(l){let i=await hs(l,n);return i.links?i.links():[]}return[]}));return ys(r.flat(1).filter(gs).filter(o=>o.rel==="stylesheet"||o.rel==="preload").map(o=>o.rel==="stylesheet"?{...o,rel:"prefetch",as:"style"}:{...o,rel:"prefetch"}))}function qr(e,t,n,r,o,l){let i=(s,u)=>n[u]?s.route.id!==n[u].route.id:!0,a=(s,u)=>n[u].pathname!==s.pathname||n[u].route.path?.endsWith("*")&&n[u].params["*"]!==s.params["*"];return l==="assets"?t.filter((s,u)=>i(s,u)||a(s,u)):l==="data"?t.filter((s,u)=>{let c=r.routes[s.route.id];if(!c||!c.hasLoader)return!1;if(i(s,u)||a(s,u))return!0;if(s.route.shouldRevalidate){let d=s.route.shouldRevalidate({currentUrl:new URL(o.pathname+o.search+o.hash,window.origin),currentParams:n[0]?.params||{},nextUrl:new URL(e,window.origin),nextParams:s.params,defaultShouldRevalidate:!0});if(typeof d=="boolean")return d}return!0}):[]}function bs(e,t,{includeHydrateFallback:n}={}){return xs(e.map(r=>{let o=t.routes[r.route.id];if(!o)return[];let l=[o.module];return o.clientActionModule&&(l=l.concat(o.clientActionModule)),o.clientLoaderModule&&(l=l.concat(o.clientLoaderModule)),n&&o.hydrateFallbackModule&&(l=l.concat(o.hydrateFallbackModule)),o.imports&&(l=l.concat(o.imports)),l}).flat(1))}function xs(e){return[...new Set(e)]}function ws(e){let t={},n=Object.keys(e).sort();for(let r of n)t[r]=e[r];return t}function ys(e,t){let n=new Set;return new Set(t),e.reduce((r,o)=>{let l=JSON.stringify(ws(o));return n.has(l)||(n.add(l),r.push({key:l,link:o})),r},[])}function rl(){let e=g.useContext(it);return cr(e,"You must render this element inside a <DataRouterContext.Provider> element"),e}function Es(){let e=g.useContext(ln);return cr(e,"You must render this element inside a <DataRouterStateContext.Provider> element"),e}var dr=g.createContext(void 0);dr.displayName="FrameworkContext";function ol(){let e=g.useContext(dr);return cr(e,"You must render this element inside a <HydratedRouter> element"),e}function Cs(e,t){let n=g.useContext(dr),[r,o]=g.useState(!1),[l,i]=g.useState(!1),{onFocus:a,onBlur:s,onMouseEnter:u,onMouseLeave:c,onTouchStart:d}=t,m=g.useRef(null);g.useEffect(()=>{if(e==="render"&&i(!0),e==="viewport"){let v=x=>{x.forEach(y=>{i(y.isIntersecting)})},b=new IntersectionObserver(v,{threshold:.5});return m.current&&b.observe(m.current),()=>{b.disconnect()}}},[e]),g.useEffect(()=>{if(r){let v=setTimeout(()=>{i(!0)},100);return()=>{clearTimeout(v)}}},[r]);let f=()=>{o(!0)},h=()=>{o(!1),i(!1)};return n?e!=="intent"?[l,m,{}]:[l,m,{onFocus:pt(a,f),onBlur:pt(s,h),onMouseEnter:pt(u,f),onMouseLeave:pt(c,h),onTouchStart:pt(d,f)}]:[!1,m,{}]}function pt(e,t){return n=>{e&&e(n),n.defaultPrevented||t(n)}}function Ss({page:e,...t}){let{router:n}=rl(),r=g.useMemo(()=>zo(n.routes,e,n.basename),[n.routes,e,n.basename]);return r?g.createElement(ks,{page:e,matches:r,...t}):null}function $s(e){let{manifest:t,routeModules:n}=ol(),[r,o]=g.useState([]);return g.useEffect(()=>{let l=!1;return vs(e,t,n).then(i=>{l||o(i)}),()=>{l=!0}},[e,t,n]),r}function ks({page:e,matches:t,...n}){let r=Fe(),{manifest:o,routeModules:l}=ol(),{basename:i}=rl(),{loaderData:a,matches:s}=Es(),u=g.useMemo(()=>qr(e,t,s,o,r,"data"),[e,t,s,o,r]),c=g.useMemo(()=>qr(e,t,s,o,r,"assets"),[e,t,s,o,r]),d=g.useMemo(()=>{if(e===r.pathname+r.search+r.hash)return[];let h=new Set,v=!1;if(t.forEach(x=>{let y=o.routes[x.route.id];!y||!y.hasLoader||(!u.some(w=>w.route.id===x.route.id)&&x.route.id in a&&l[x.route.id]?.shouldRevalidate||y.hasClientLoader?v=!0:h.add(x.route.id))}),h.size===0)return[];let b=ms(e,i,"data");return v&&h.size>0&&b.searchParams.set("_routes",t.filter(x=>h.has(x.route.id)).map(x=>x.route.id).join(",")),[b.pathname+b.search]},[i,a,r,o,u,t,e,l]),m=g.useMemo(()=>bs(c,o),[c,o]),f=$s(c);return g.createElement(g.Fragment,null,d.map(h=>g.createElement("link",{key:h,rel:"prefetch",as:"fetch",href:h,...n})),m.map(h=>g.createElement("link",{key:h,rel:"modulepreload",href:h,...n})),f.map(({key:h,link:v})=>g.createElement("link",{key:h,nonce:n.nonce,...v})))}function Rs(...e){return t=>{e.forEach(n=>{typeof n=="function"?n(t):n!=null&&(n.current=t)})}}var ll=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";try{ll&&(window.__reactRouterVersion="7.10.1")}catch{}function Os({basename:e,children:t,unstable_useTransitions:n,window:r}){let o=g.useRef();o.current==null&&(o.current=ma({window:r,v5Compat:!0}));let l=o.current,[i,a]=g.useState({action:l.action,location:l.location}),s=g.useCallback(u=>{n===!1?a(u):g.startTransition(()=>a(u))},[n]);return g.useLayoutEffect(()=>l.listen(s),[l,s]),g.createElement(os,{basename:e,children:t,location:i.location,navigationType:i.action,navigator:l,unstable_useTransitions:n===!0})}var il=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,al=g.forwardRef(function({onClick:t,discover:n="render",prefetch:r="none",relative:o,reloadDocument:l,replace:i,state:a,target:s,to:u,preventScrollReset:c,viewTransition:d,...m},f){let{basename:h,unstable_useTransitions:v}=g.useContext(Ee),b=typeof u=="string"&&il.test(u),x,y=!1;if(typeof u=="string"&&b&&(x=u,ll))try{let R=new URL(window.location.href),M=u.startsWith("//")?new URL(R.protocol+u):new URL(u),H=Le(M.pathname,h);M.origin===R.origin&&H!=null?u=H+M.search+M.hash:y=!0}catch{we(!1,`<Link to="${u}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}let w=Va(u,{relative:o}),[S,C,T]=Cs(r,m),O=As(u,{replace:i,state:a,target:s,preventScrollReset:c,relative:o,viewTransition:d,unstable_useTransitions:v});function k(R){t&&t(R),R.defaultPrevented||O(R)}let A=g.createElement("a",{...m,...T,href:x||w,onClick:y||l?t:k,ref:Rs(f,C),target:s,"data-discover":!b&&n==="render"?"true":void 0});return S&&!b?g.createElement(g.Fragment,null,A,g.createElement(Ss,{page:w})):A});al.displayName="Link";var Ts=g.forwardRef(function({"aria-current":t="page",caseSensitive:n=!1,className:r="",end:o=!1,style:l,to:i,viewTransition:a,children:s,...u},c){let d=Rt(i,{relative:u.relative}),m=Fe(),f=g.useContext(ln),{navigator:h,basename:v}=g.useContext(Ee),b=f!=null&&js(d)&&a===!0,x=h.encodeLocation?h.encodeLocation(d).pathname:d.pathname,y=m.pathname,w=f&&f.navigation&&f.navigation.location?f.navigation.location.pathname:null;n||(y=y.toLowerCase(),w=w?w.toLowerCase():null,x=x.toLowerCase()),w&&v&&(w=Le(w,v)||w);const S=x!=="/"&&x.endsWith("/")?x.length-1:x.length;let C=y===x||!o&&y.startsWith(x)&&y.charAt(S)==="/",T=w!=null&&(w===x||!o&&w.startsWith(x)&&w.charAt(x.length)==="/"),O={isActive:C,isPending:T,isTransitioning:b},k=C?t:void 0,A;typeof r=="function"?A=r(O):A=[r,C?"active":null,T?"pending":null,b?"transitioning":null].filter(Boolean).join(" ");let R=typeof l=="function"?l(O):l;return g.createElement(al,{...u,"aria-current":k,className:A,ref:c,style:R,to:i,viewTransition:a},typeof s=="function"?s(O):s)});Ts.displayName="NavLink";var Ps=g.forwardRef(({discover:e="render",fetcherKey:t,navigate:n,reloadDocument:r,replace:o,state:l,method:i=Ut,action:a,onSubmit:s,relative:u,preventScrollReset:c,viewTransition:d,...m},f)=>{let{unstable_useTransitions:h}=g.useContext(Ee),v=Ns(),b=Is(a,{relative:u}),x=i.toLowerCase()==="get"?"get":"post",y=typeof a=="string"&&il.test(a),w=S=>{if(s&&s(S),S.defaultPrevented)return;S.preventDefault();let C=S.nativeEvent.submitter,T=C?.getAttribute("formmethod")||i,O=()=>v(C||S.currentTarget,{fetcherKey:t,method:T,navigate:n,replace:o,state:l,relative:u,preventScrollReset:c,viewTransition:d});h&&n!==!1?g.startTransition(()=>O()):O()};return g.createElement("form",{ref:f,method:x,action:b,onSubmit:r?s:w,...m,"data-discover":!y&&e==="render"?"true":void 0})});Ps.displayName="Form";function Ls(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function sl(e){let t=g.useContext(it);return G(t,Ls(e)),t}function As(e,{target:t,replace:n,state:r,preventScrollReset:o,relative:l,viewTransition:i,unstable_useTransitions:a}={}){let s=Qo(),u=Fe(),c=Rt(e,{relative:l});return g.useCallback(d=>{if(cs(d,t)){d.preventDefault();let m=n!==void 0?n:xt(u)===xt(c),f=()=>s(e,{replace:m,state:r,preventScrollReset:o,relative:l,viewTransition:i});a?g.startTransition(()=>f()):f()}},[u,s,c,n,r,t,e,o,l,i,a])}var Fs=0,Ms=()=>`__${String(++Fs)}__`;function Ns(){let{router:e}=sl("useSubmit"),{basename:t}=g.useContext(Ee),n=es(),r=e.fetch,o=e.navigate;return g.useCallback(async(l,i={})=>{let{action:a,method:s,encType:u,formData:c,body:d}=ps(l,t);if(i.navigate===!1){let m=i.fetcherKey||Ms();await r(m,n,i.action||a,{preventScrollReset:i.preventScrollReset,formData:c,body:d,formMethod:i.method||s,formEncType:i.encType||u,flushSync:i.flushSync})}else await o(i.action||a,{preventScrollReset:i.preventScrollReset,formData:c,body:d,formMethod:i.method||s,formEncType:i.encType||u,replace:i.replace,state:i.state,fromRouteId:n,flushSync:i.flushSync,viewTransition:i.viewTransition})},[r,o,t,n])}function Is(e,{relative:t}={}){let{basename:n}=g.useContext(Ee),r=g.useContext(Ae);G(r,"useFormAction must be used inside a RouteContext");let[o]=r.matches.slice(-1),l={...Rt(e||".",{relative:t})},i=Fe();if(e==null){l.search=i.search;let a=new URLSearchParams(l.search),s=a.getAll("index");if(s.some(c=>c==="")){a.delete("index"),s.filter(d=>d).forEach(d=>a.append("index",d));let c=a.toString();l.search=c?`?${c}`:""}}return(!e||e===".")&&o.route.index&&(l.search=l.search?l.search.replace(/^\?/,"?index&"):"?index"),n!=="/"&&(l.pathname=l.pathname==="/"?n:Pe([n,l.pathname])),xt(l)}function js(e,{relative:t}={}){let n=g.useContext(Zo);G(n!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:r}=sl("useViewTransitionState"),o=Rt(e,{relative:t});if(!n.isTransitioning)return!1;let l=Le(n.currentLocation.pathname,r)||n.currentLocation.pathname,i=Le(n.nextLocation.pathname,r)||n.nextLocation.pathname;return wt(o.pathname,i)!=null||wt(o.pathname,l)!=null}const Ds=e=>g.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:16,height:16,fill:"currentColor",className:"bi bi-github",viewBox:"0 0 16 16",...e},g.createElement("path",{d:"M8 0C3.58 0 0 3.58 0 8c0 3.54 2.29 6.53 5.47 7.59.4.07.55-.17.55-.38 0-.19-.01-.82-.01-1.49-2.01.37-2.53-.49-2.69-.94-.09-.23-.48-.94-.82-1.13-.28-.15-.68-.52-.01-.53.63-.01 1.08.58 1.23.82.72 1.21 1.87.87 2.33.66.07-.52.28-.87.51-1.07-1.78-.2-3.64-.89-3.64-3.95 0-.87.31-1.59.82-2.15-.08-.2-.36-1.02.08-2.12 0 0 .67-.21 2.2.82.64-.18 1.32-.27 2-.27s1.36.09 2 .27c1.53-1.04 2.2-.82 2.2-.82.44 1.1.16 1.92.08 2.12.51.56.82 1.27.82 2.15 0 3.07-1.87 3.75-3.65 3.95.29.25.54.73.54 1.48 0 1.07-.01 1.93-.01 2.2 0 .21.15.46.55.38A8.01 8.01 0 0 0 16 8c0-4.42-3.58-8-8-8"})),_s=e=>g.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 128 128",...e},g.createElement("path",{fill:"currentColor",d:"M2 38.5h124v43.71H64v7.29H36.44v-7.29H2zm6.89 36.43h13.78V53.07h6.89v21.86h6.89V45.79H8.89zm34.44-29.14v36.42h13.78v-7.28h13.78V45.79zm13.78 7.29H64v14.56h-6.89zm20.67-7.29v29.14h13.78V53.07h6.89v21.86h6.89V53.07h6.89v21.86h6.89V45.79z"})),Bs=e=>g.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",height:"24px",viewBox:"0 0 640 640",width:"24px",fill:"currentColor",...e},g.createElement("path",{d:"M433.2 103.1L581.4 253.4C609.1 281.5 609.1 326.5 581.4 354.6L425 512.9C415.7 522.3 400.5 522.4 391.1 513.1C381.7 503.8 381.6 488.6 390.9 479.2L547.3 320.8C556.5 311.5 556.5 296.4 547.3 287.1L399 136.9C389.7 127.5 389.8 112.3 399.2 103C408.6 93.7 423.8 93.8 433.1 103.2zM64.1 293.5L64.1 160C64.1 124.7 92.8 96 128.1 96L261.6 96C278.6 96 294.9 102.7 306.9 114.7L450.9 258.7C475.9 283.7 475.9 324.2 450.9 349.2L317.4 482.7C292.4 507.7 251.9 507.7 226.9 482.7L82.9 338.7C70.9 326.7 64.2 310.4 64.2 293.4zM208.1 208C208.1 190.3 193.8 176 176.1 176C158.4 176 144.1 190.3 144.1 208C144.1 225.7 158.4 240 176.1 240C193.8 240 208.1 225.7 208.1 208z"})),ul=p.createContext(null),Gr=e=>{let t;const n=new Set,r=(u,c)=>{const d=typeof u=="function"?u(t):u;if(!Object.is(d,t)){const m=t;t=c??(typeof d!="object"||d===null)?d:Object.assign({},t,d),n.forEach(f=>f(t,m))}},o=()=>t,a={setState:r,getState:o,getInitialState:()=>s,subscribe:u=>(n.add(u),()=>n.delete(u))},s=t=e(r,o,a);return a},Hs=(e=>e?Gr(e):Gr),Vs=e=>e;function zs(e,t=Vs){const n=p.useSyncExternalStore(e.subscribe,p.useCallback(()=>t(e.getState()),[e,t]),p.useCallback(()=>t(e.getInitialState()),[e,t]));return p.useDebugValue(n),n}const Kr=e=>{const t=Hs(e),n=r=>zs(t,r);return Object.assign(n,t),n},Ws=(e=>e?Kr(e):Kr),cl=Ws(e=>({visible:!1,hide:()=>e({visible:!1}),show:()=>e({visible:!0}),toggle:()=>e(t=>({visible:!t.visible}))}));function dl(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(n=dl(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function Us(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=dl(e))&&(r&&(r+=" "),r+=t);return r}const qs=(e,t)=>{const n=new Array(e.length+t.length);for(let r=0;r<e.length;r++)n[r]=e[r];for(let r=0;r<t.length;r++)n[e.length+r]=t[r];return n},Gs=(e,t)=>({classGroupId:e,validator:t}),fl=(e=new Map,t=null,n)=>({nextPart:e,validators:t,classGroupId:n}),Xt="-",Yr=[],Ks="arbitrary..",Ys=e=>{const t=Xs(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:i=>{if(i.startsWith("[")&&i.endsWith("]"))return Zs(i);const a=i.split(Xt),s=a[0]===""&&a.length>1?1:0;return pl(a,s,t)},getConflictingClassGroupIds:(i,a)=>{if(a){const s=r[i],u=n[i];return s?u?qs(u,s):s:u||Yr}return n[i]||Yr}}},pl=(e,t,n)=>{if(e.length-t===0)return n.classGroupId;const o=e[t],l=n.nextPart.get(o);if(l){const u=pl(e,t+1,l);if(u)return u}const i=n.validators;if(i===null)return;const a=t===0?e.join(Xt):e.slice(t).join(Xt),s=i.length;for(let u=0;u<s;u++){const c=i[u];if(c.validator(a))return c.classGroupId}},Zs=e=>e.slice(1,-1).indexOf(":")===-1?void 0:(()=>{const t=e.slice(1,-1),n=t.indexOf(":"),r=t.slice(0,n);return r?Ks+r:void 0})(),Xs=e=>{const{theme:t,classGroups:n}=e;return Js(n,t)},Js=(e,t)=>{const n=fl();for(const r in e){const o=e[r];fr(o,n,r,t)}return n},fr=(e,t,n,r)=>{const o=e.length;for(let l=0;l<o;l++){const i=e[l];Qs(i,t,n,r)}},Qs=(e,t,n,r)=>{if(typeof e=="string"){eu(e,t,n);return}if(typeof e=="function"){tu(e,t,n,r);return}nu(e,t,n,r)},eu=(e,t,n)=>{const r=e===""?t:ml(t,e);r.classGroupId=n},tu=(e,t,n,r)=>{if(ru(e)){fr(e(r),t,n,r);return}t.validators===null&&(t.validators=[]),t.validators.push(Gs(n,e))},nu=(e,t,n,r)=>{const o=Object.entries(e),l=o.length;for(let i=0;i<l;i++){const[a,s]=o[i];fr(s,ml(t,a),n,r)}},ml=(e,t)=>{let n=e;const r=t.split(Xt),o=r.length;for(let l=0;l<o;l++){const i=r[l];let a=n.nextPart.get(i);a||(a=fl(),n.nextPart.set(i,a)),n=a}return n},ru=e=>"isThemeGetter"in e&&e.isThemeGetter===!0,ou=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=Object.create(null),r=Object.create(null);const o=(l,i)=>{n[l]=i,t++,t>e&&(t=0,r=n,n=Object.create(null))};return{get(l){let i=n[l];if(i!==void 0)return i;if((i=r[l])!==void 0)return o(l,i),i},set(l,i){l in n?n[l]=i:o(l,i)}}},Wn="!",Zr=":",lu=[],Xr=(e,t,n,r,o)=>({modifiers:e,hasImportantModifier:t,baseClassName:n,maybePostfixModifierPosition:r,isExternal:o}),iu=e=>{const{prefix:t,experimentalParseClassName:n}=e;let r=o=>{const l=[];let i=0,a=0,s=0,u;const c=o.length;for(let v=0;v<c;v++){const b=o[v];if(i===0&&a===0){if(b===Zr){l.push(o.slice(s,v)),s=v+1;continue}if(b==="/"){u=v;continue}}b==="["?i++:b==="]"?i--:b==="("?a++:b===")"&&a--}const d=l.length===0?o:o.slice(s);let m=d,f=!1;d.endsWith(Wn)?(m=d.slice(0,-1),f=!0):d.startsWith(Wn)&&(m=d.slice(1),f=!0);const h=u&&u>s?u-s:void 0;return Xr(l,f,m,h)};if(t){const o=t+Zr,l=r;r=i=>i.startsWith(o)?l(i.slice(o.length)):Xr(lu,!1,i,void 0,!0)}if(n){const o=r;r=l=>n({className:l,parseClassName:o})}return r},au=e=>{const t=new Map;return e.orderSensitiveModifiers.forEach((n,r)=>{t.set(n,1e6+r)}),n=>{const r=[];let o=[];for(let l=0;l<n.length;l++){const i=n[l],a=i[0]==="[",s=t.has(i);a||s?(o.length>0&&(o.sort(),r.push(...o),o=[]),r.push(i)):o.push(i)}return o.length>0&&(o.sort(),r.push(...o)),r}},su=e=>({cache:ou(e.cacheSize),parseClassName:iu(e),sortModifiers:au(e),...Ys(e)}),uu=/\s+/,cu=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:o,sortModifiers:l}=t,i=[],a=e.trim().split(uu);let s="";for(let u=a.length-1;u>=0;u-=1){const c=a[u],{isExternal:d,modifiers:m,hasImportantModifier:f,baseClassName:h,maybePostfixModifierPosition:v}=n(c);if(d){s=c+(s.length>0?" "+s:s);continue}let b=!!v,x=r(b?h.substring(0,v):h);if(!x){if(!b){s=c+(s.length>0?" "+s:s);continue}if(x=r(h),!x){s=c+(s.length>0?" "+s:s);continue}b=!1}const y=m.length===0?"":m.length===1?m[0]:l(m).join(":"),w=f?y+Wn:y,S=w+x;if(i.indexOf(S)>-1)continue;i.push(S);const C=o(x,b);for(let T=0;T<C.length;++T){const O=C[T];i.push(w+O)}s=c+(s.length>0?" "+s:s)}return s},du=(...e)=>{let t=0,n,r,o="";for(;t<e.length;)(n=e[t++])&&(r=hl(n))&&(o&&(o+=" "),o+=r);return o},hl=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=hl(e[r]))&&(n&&(n+=" "),n+=t);return n},fu=(e,...t)=>{let n,r,o,l;const i=s=>{const u=t.reduce((c,d)=>d(c),e());return n=su(u),r=n.cache.get,o=n.cache.set,l=a,a(s)},a=s=>{const u=r(s);if(u)return u;const c=cu(s,n);return o(s,c),c};return l=i,(...s)=>l(du(...s))},pu=[],J=e=>{const t=n=>n[e]||pu;return t.isThemeGetter=!0,t},gl=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,vl=/^\((?:(\w[\w-]*):)?(.+)\)$/i,mu=/^\d+\/\d+$/,hu=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,gu=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,vu=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,bu=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,xu=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Qe=e=>mu.test(e),j=e=>!!e&&!Number.isNaN(Number(e)),Ie=e=>!!e&&Number.isInteger(Number(e)),kn=e=>e.endsWith("%")&&j(e.slice(0,-1)),Oe=e=>hu.test(e),wu=()=>!0,yu=e=>gu.test(e)&&!vu.test(e),bl=()=>!1,Eu=e=>bu.test(e),Cu=e=>xu.test(e),Su=e=>!P(e)&&!L(e),$u=e=>st(e,yl,bl),P=e=>gl.test(e),We=e=>st(e,El,yu),Rn=e=>st(e,Pu,j),Jr=e=>st(e,xl,bl),ku=e=>st(e,wl,Cu),jt=e=>st(e,Cl,Eu),L=e=>vl.test(e),mt=e=>ut(e,El),Ru=e=>ut(e,Lu),Qr=e=>ut(e,xl),Ou=e=>ut(e,yl),Tu=e=>ut(e,wl),Dt=e=>ut(e,Cl,!0),st=(e,t,n)=>{const r=gl.exec(e);return r?r[1]?t(r[1]):n(r[2]):!1},ut=(e,t,n=!1)=>{const r=vl.exec(e);return r?r[1]?t(r[1]):n:!1},xl=e=>e==="position"||e==="percentage",wl=e=>e==="image"||e==="url",yl=e=>e==="length"||e==="size"||e==="bg-size",El=e=>e==="length",Pu=e=>e==="number",Lu=e=>e==="family-name",Cl=e=>e==="shadow",Au=()=>{const e=J("color"),t=J("font"),n=J("text"),r=J("font-weight"),o=J("tracking"),l=J("leading"),i=J("breakpoint"),a=J("container"),s=J("spacing"),u=J("radius"),c=J("shadow"),d=J("inset-shadow"),m=J("text-shadow"),f=J("drop-shadow"),h=J("blur"),v=J("perspective"),b=J("aspect"),x=J("ease"),y=J("animate"),w=()=>["auto","avoid","all","avoid-page","page","left","right","column"],S=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],C=()=>[...S(),L,P],T=()=>["auto","hidden","clip","visible","scroll"],O=()=>["auto","contain","none"],k=()=>[L,P,s],A=()=>[Qe,"full","auto",...k()],R=()=>[Ie,"none","subgrid",L,P],M=()=>["auto",{span:["full",Ie,L,P]},Ie,L,P],H=()=>[Ie,"auto",L,P],z=()=>["auto","min","max","fr",L,P],B=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],F=()=>["start","end","center","stretch","center-safe","end-safe"],I=()=>["auto",...k()],U=()=>[Qe,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...k()],$=()=>[e,L,P],V=()=>[...S(),Qr,Jr,{position:[L,P]}],q=()=>["no-repeat",{repeat:["","x","y","space","round"]}],pe=()=>["auto","cover","contain",Ou,$u,{size:[L,P]}],K=()=>[kn,mt,We],_=()=>["","none","full",u,L,P],ee=()=>["",j,mt,We],me=()=>["solid","dashed","dotted","double"],N=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],W=()=>[j,kn,Qr,Jr],xe=()=>["","none",h,L,P],he=()=>["none",j,L,P],Mt=()=>["none",j,L,P],Cn=()=>[j,L,P],Nt=()=>[Qe,"full",...k()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[Oe],breakpoint:[Oe],color:[wu],container:[Oe],"drop-shadow":[Oe],ease:["in","out","in-out"],font:[Su],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[Oe],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[Oe],shadow:[Oe],spacing:["px",j],text:[Oe],"text-shadow":[Oe],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",Qe,P,L,b]}],container:["container"],columns:[{columns:[j,P,L,a]}],"break-after":[{"break-after":w()}],"break-before":[{"break-before":w()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:C()}],overflow:[{overflow:T()}],"overflow-x":[{"overflow-x":T()}],"overflow-y":[{"overflow-y":T()}],overscroll:[{overscroll:O()}],"overscroll-x":[{"overscroll-x":O()}],"overscroll-y":[{"overscroll-y":O()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:A()}],"inset-x":[{"inset-x":A()}],"inset-y":[{"inset-y":A()}],start:[{start:A()}],end:[{end:A()}],top:[{top:A()}],right:[{right:A()}],bottom:[{bottom:A()}],left:[{left:A()}],visibility:["visible","invisible","collapse"],z:[{z:[Ie,"auto",L,P]}],basis:[{basis:[Qe,"full","auto",a,...k()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[j,Qe,"auto","initial","none",P]}],grow:[{grow:["",j,L,P]}],shrink:[{shrink:["",j,L,P]}],order:[{order:[Ie,"first","last","none",L,P]}],"grid-cols":[{"grid-cols":R()}],"col-start-end":[{col:M()}],"col-start":[{"col-start":H()}],"col-end":[{"col-end":H()}],"grid-rows":[{"grid-rows":R()}],"row-start-end":[{row:M()}],"row-start":[{"row-start":H()}],"row-end":[{"row-end":H()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":z()}],"auto-rows":[{"auto-rows":z()}],gap:[{gap:k()}],"gap-x":[{"gap-x":k()}],"gap-y":[{"gap-y":k()}],"justify-content":[{justify:[...B(),"normal"]}],"justify-items":[{"justify-items":[...F(),"normal"]}],"justify-self":[{"justify-self":["auto",...F()]}],"align-content":[{content:["normal",...B()]}],"align-items":[{items:[...F(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...F(),{baseline:["","last"]}]}],"place-content":[{"place-content":B()}],"place-items":[{"place-items":[...F(),"baseline"]}],"place-self":[{"place-self":["auto",...F()]}],p:[{p:k()}],px:[{px:k()}],py:[{py:k()}],ps:[{ps:k()}],pe:[{pe:k()}],pt:[{pt:k()}],pr:[{pr:k()}],pb:[{pb:k()}],pl:[{pl:k()}],m:[{m:I()}],mx:[{mx:I()}],my:[{my:I()}],ms:[{ms:I()}],me:[{me:I()}],mt:[{mt:I()}],mr:[{mr:I()}],mb:[{mb:I()}],ml:[{ml:I()}],"space-x":[{"space-x":k()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":k()}],"space-y-reverse":["space-y-reverse"],size:[{size:U()}],w:[{w:[a,"screen",...U()]}],"min-w":[{"min-w":[a,"screen","none",...U()]}],"max-w":[{"max-w":[a,"screen","none","prose",{screen:[i]},...U()]}],h:[{h:["screen","lh",...U()]}],"min-h":[{"min-h":["screen","lh","none",...U()]}],"max-h":[{"max-h":["screen","lh",...U()]}],"font-size":[{text:["base",n,mt,We]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[r,L,Rn]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",kn,P]}],"font-family":[{font:[Ru,P,t]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:[o,L,P]}],"line-clamp":[{"line-clamp":[j,"none",L,Rn]}],leading:[{leading:[l,...k()]}],"list-image":[{"list-image":["none",L,P]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",L,P]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:$()}],"text-color":[{text:$()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...me(),"wavy"]}],"text-decoration-thickness":[{decoration:[j,"from-font","auto",L,We]}],"text-decoration-color":[{decoration:$()}],"underline-offset":[{"underline-offset":[j,"auto",L,P]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:k()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",L,P]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",L,P]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:V()}],"bg-repeat":[{bg:q()}],"bg-size":[{bg:pe()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},Ie,L,P],radial:["",L,P],conic:[Ie,L,P]},Tu,ku]}],"bg-color":[{bg:$()}],"gradient-from-pos":[{from:K()}],"gradient-via-pos":[{via:K()}],"gradient-to-pos":[{to:K()}],"gradient-from":[{from:$()}],"gradient-via":[{via:$()}],"gradient-to":[{to:$()}],rounded:[{rounded:_()}],"rounded-s":[{"rounded-s":_()}],"rounded-e":[{"rounded-e":_()}],"rounded-t":[{"rounded-t":_()}],"rounded-r":[{"rounded-r":_()}],"rounded-b":[{"rounded-b":_()}],"rounded-l":[{"rounded-l":_()}],"rounded-ss":[{"rounded-ss":_()}],"rounded-se":[{"rounded-se":_()}],"rounded-ee":[{"rounded-ee":_()}],"rounded-es":[{"rounded-es":_()}],"rounded-tl":[{"rounded-tl":_()}],"rounded-tr":[{"rounded-tr":_()}],"rounded-br":[{"rounded-br":_()}],"rounded-bl":[{"rounded-bl":_()}],"border-w":[{border:ee()}],"border-w-x":[{"border-x":ee()}],"border-w-y":[{"border-y":ee()}],"border-w-s":[{"border-s":ee()}],"border-w-e":[{"border-e":ee()}],"border-w-t":[{"border-t":ee()}],"border-w-r":[{"border-r":ee()}],"border-w-b":[{"border-b":ee()}],"border-w-l":[{"border-l":ee()}],"divide-x":[{"divide-x":ee()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":ee()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...me(),"hidden","none"]}],"divide-style":[{divide:[...me(),"hidden","none"]}],"border-color":[{border:$()}],"border-color-x":[{"border-x":$()}],"border-color-y":[{"border-y":$()}],"border-color-s":[{"border-s":$()}],"border-color-e":[{"border-e":$()}],"border-color-t":[{"border-t":$()}],"border-color-r":[{"border-r":$()}],"border-color-b":[{"border-b":$()}],"border-color-l":[{"border-l":$()}],"divide-color":[{divide:$()}],"outline-style":[{outline:[...me(),"none","hidden"]}],"outline-offset":[{"outline-offset":[j,L,P]}],"outline-w":[{outline:["",j,mt,We]}],"outline-color":[{outline:$()}],shadow:[{shadow:["","none",c,Dt,jt]}],"shadow-color":[{shadow:$()}],"inset-shadow":[{"inset-shadow":["none",d,Dt,jt]}],"inset-shadow-color":[{"inset-shadow":$()}],"ring-w":[{ring:ee()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:$()}],"ring-offset-w":[{"ring-offset":[j,We]}],"ring-offset-color":[{"ring-offset":$()}],"inset-ring-w":[{"inset-ring":ee()}],"inset-ring-color":[{"inset-ring":$()}],"text-shadow":[{"text-shadow":["none",m,Dt,jt]}],"text-shadow-color":[{"text-shadow":$()}],opacity:[{opacity:[j,L,P]}],"mix-blend":[{"mix-blend":[...N(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":N()}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[j]}],"mask-image-linear-from-pos":[{"mask-linear-from":W()}],"mask-image-linear-to-pos":[{"mask-linear-to":W()}],"mask-image-linear-from-color":[{"mask-linear-from":$()}],"mask-image-linear-to-color":[{"mask-linear-to":$()}],"mask-image-t-from-pos":[{"mask-t-from":W()}],"mask-image-t-to-pos":[{"mask-t-to":W()}],"mask-image-t-from-color":[{"mask-t-from":$()}],"mask-image-t-to-color":[{"mask-t-to":$()}],"mask-image-r-from-pos":[{"mask-r-from":W()}],"mask-image-r-to-pos":[{"mask-r-to":W()}],"mask-image-r-from-color":[{"mask-r-from":$()}],"mask-image-r-to-color":[{"mask-r-to":$()}],"mask-image-b-from-pos":[{"mask-b-from":W()}],"mask-image-b-to-pos":[{"mask-b-to":W()}],"mask-image-b-from-color":[{"mask-b-from":$()}],"mask-image-b-to-color":[{"mask-b-to":$()}],"mask-image-l-from-pos":[{"mask-l-from":W()}],"mask-image-l-to-pos":[{"mask-l-to":W()}],"mask-image-l-from-color":[{"mask-l-from":$()}],"mask-image-l-to-color":[{"mask-l-to":$()}],"mask-image-x-from-pos":[{"mask-x-from":W()}],"mask-image-x-to-pos":[{"mask-x-to":W()}],"mask-image-x-from-color":[{"mask-x-from":$()}],"mask-image-x-to-color":[{"mask-x-to":$()}],"mask-image-y-from-pos":[{"mask-y-from":W()}],"mask-image-y-to-pos":[{"mask-y-to":W()}],"mask-image-y-from-color":[{"mask-y-from":$()}],"mask-image-y-to-color":[{"mask-y-to":$()}],"mask-image-radial":[{"mask-radial":[L,P]}],"mask-image-radial-from-pos":[{"mask-radial-from":W()}],"mask-image-radial-to-pos":[{"mask-radial-to":W()}],"mask-image-radial-from-color":[{"mask-radial-from":$()}],"mask-image-radial-to-color":[{"mask-radial-to":$()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":S()}],"mask-image-conic-pos":[{"mask-conic":[j]}],"mask-image-conic-from-pos":[{"mask-conic-from":W()}],"mask-image-conic-to-pos":[{"mask-conic-to":W()}],"mask-image-conic-from-color":[{"mask-conic-from":$()}],"mask-image-conic-to-color":[{"mask-conic-to":$()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:V()}],"mask-repeat":[{mask:q()}],"mask-size":[{mask:pe()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",L,P]}],filter:[{filter:["","none",L,P]}],blur:[{blur:xe()}],brightness:[{brightness:[j,L,P]}],contrast:[{contrast:[j,L,P]}],"drop-shadow":[{"drop-shadow":["","none",f,Dt,jt]}],"drop-shadow-color":[{"drop-shadow":$()}],grayscale:[{grayscale:["",j,L,P]}],"hue-rotate":[{"hue-rotate":[j,L,P]}],invert:[{invert:["",j,L,P]}],saturate:[{saturate:[j,L,P]}],sepia:[{sepia:["",j,L,P]}],"backdrop-filter":[{"backdrop-filter":["","none",L,P]}],"backdrop-blur":[{"backdrop-blur":xe()}],"backdrop-brightness":[{"backdrop-brightness":[j,L,P]}],"backdrop-contrast":[{"backdrop-contrast":[j,L,P]}],"backdrop-grayscale":[{"backdrop-grayscale":["",j,L,P]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[j,L,P]}],"backdrop-invert":[{"backdrop-invert":["",j,L,P]}],"backdrop-opacity":[{"backdrop-opacity":[j,L,P]}],"backdrop-saturate":[{"backdrop-saturate":[j,L,P]}],"backdrop-sepia":[{"backdrop-sepia":["",j,L,P]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":k()}],"border-spacing-x":[{"border-spacing-x":k()}],"border-spacing-y":[{"border-spacing-y":k()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",L,P]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[j,"initial",L,P]}],ease:[{ease:["linear","initial",x,L,P]}],delay:[{delay:[j,L,P]}],animate:[{animate:["none",y,L,P]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[v,L,P]}],"perspective-origin":[{"perspective-origin":C()}],rotate:[{rotate:he()}],"rotate-x":[{"rotate-x":he()}],"rotate-y":[{"rotate-y":he()}],"rotate-z":[{"rotate-z":he()}],scale:[{scale:Mt()}],"scale-x":[{"scale-x":Mt()}],"scale-y":[{"scale-y":Mt()}],"scale-z":[{"scale-z":Mt()}],"scale-3d":["scale-3d"],skew:[{skew:Cn()}],"skew-x":[{"skew-x":Cn()}],"skew-y":[{"skew-y":Cn()}],transform:[{transform:[L,P,"","none","gpu","cpu"]}],"transform-origin":[{origin:C()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:Nt()}],"translate-x":[{"translate-x":Nt()}],"translate-y":[{"translate-y":Nt()}],"translate-z":[{"translate-z":Nt()}],"translate-none":["translate-none"],accent:[{accent:$()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:$()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",L,P]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":k()}],"scroll-mx":[{"scroll-mx":k()}],"scroll-my":[{"scroll-my":k()}],"scroll-ms":[{"scroll-ms":k()}],"scroll-me":[{"scroll-me":k()}],"scroll-mt":[{"scroll-mt":k()}],"scroll-mr":[{"scroll-mr":k()}],"scroll-mb":[{"scroll-mb":k()}],"scroll-ml":[{"scroll-ml":k()}],"scroll-p":[{"scroll-p":k()}],"scroll-px":[{"scroll-px":k()}],"scroll-py":[{"scroll-py":k()}],"scroll-ps":[{"scroll-ps":k()}],"scroll-pe":[{"scroll-pe":k()}],"scroll-pt":[{"scroll-pt":k()}],"scroll-pr":[{"scroll-pr":k()}],"scroll-pb":[{"scroll-pb":k()}],"scroll-pl":[{"scroll-pl":k()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",L,P]}],fill:[{fill:["none",...$()]}],"stroke-w":[{stroke:[j,mt,We,Rn]}],stroke:[{stroke:["none",...$()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-x","border-w-y","border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-x","border-color-y","border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]},orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}},Fu=fu(Au);function ie(...e){return Fu(Us(e))}function le({align:e,children:t,className:n,direction:r,gap:o=0,grow:l,justify:i,shrink:a,style:s,wrap:u,...c}){return E.jsx("div",{className:ie("flex",{"items-center":e==="center","items-end":e==="end","items-start":e==="start","items-stretch":e==="stretch","flex-col":r==="column","flex-row":r==="row","gap-1":o===1,"gap-2":o===2,"gap-3":o===3,"gap-4":o===4,"gap-5":o===5,"gap-6":o===6,"gap-7":o===7,"gap-8":o===8,"grow-0":l===0,"grow-1":l===1,"justify-around":i==="around","justify-between":i==="between","justify-center":i==="center","justify-end":i==="end","justify-start":i==="start","justify-stretch":i==="stretch","shrink-0":a===0,"shrink-1":a===1,"flex-wrap":u},n),style:s,...c,children:t})}const Mu=p.createContext(null),On={didCatch:!1,error:null};let Nu=class extends p.Component{constructor(t){super(t),this.resetErrorBoundary=this.resetErrorBoundary.bind(this),this.state=On}static getDerivedStateFromError(t){return{didCatch:!0,error:t}}resetErrorBoundary(){const{error:t}=this.state;if(t!==null){for(var n,r,o=arguments.length,l=new Array(o),i=0;i<o;i++)l[i]=arguments[i];(n=(r=this.props).onReset)===null||n===void 0||n.call(r,{args:l,reason:"imperative-api"}),this.setState(On)}}componentDidCatch(t,n){var r,o;(r=(o=this.props).onError)===null||r===void 0||r.call(o,t,n)}componentDidUpdate(t,n){const{didCatch:r}=this.state,{resetKeys:o}=this.props;if(r&&n.error!==null&&Iu(t.resetKeys,o)){var l,i;(l=(i=this.props).onReset)===null||l===void 0||l.call(i,{next:o,prev:t.resetKeys,reason:"keys"}),this.setState(On)}}render(){const{children:t,fallbackRender:n,FallbackComponent:r,fallback:o}=this.props,{didCatch:l,error:i}=this.state;let a=t;if(l){const s={error:i,resetErrorBoundary:this.resetErrorBoundary};if(typeof n=="function")a=n(s);else if(r)a=p.createElement(r,s);else if(o!==void 0)a=o;else throw i}return p.createElement(Mu.Provider,{value:{didCatch:l,error:i,resetErrorBoundary:this.resetErrorBoundary}},a)}};function Iu(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[];return e.length!==t.length||e.some((n,r)=>!Object.is(n,t[r]))}function pr({children:e,className:t,html:n=!1,inline:r=!1,intent:o="none",minimal:l,...i}){let a=ua;switch(o){case"none":case"primary":{a=da;break}case"success":{a=oa;break}}return E.jsx("div",{className:`${r?"w-fit":"w-full"} rounded-md p-2 px-3 ${ju(o,!!l)} ${t}`,role:"alert",...i,children:E.jsxs("div",{className:"flex flex-row gap-2",children:[E.jsx(a,{className:"w-6 h-6 shrink-0"}),n?E.jsx("div",{dangerouslySetInnerHTML:{__html:e}}):E.jsx("div",{children:e})]})})}function ju(e,t){switch(e){case"danger":return t?"bg-red-950 text-red-300 [&_svg]:text-red-500":"bg-black/10 bg-border border-2 border-red-500 text-white [&_svg]:text-red-500 [&_a]:text-red-400!";case"none":return t?"bg-white/10 text-slate-300 [&_svg]:text-slate-400":"bg-black/10 bg-border border-2 border-white/40 text-white [&_svg]:text-white/60";case"primary":return t?"bg-sky-950 text-sky-300 [&_svg]:text-sky-400":"bg-black/10 bg-border border-2 border-sky-400 text-white [&_svg]:text-sky-400";case"success":return t?"bg-emerald-950 text-emerald-300 [&_svg]:text-emerald-400":"bg-black/10 bg-border border-2 border-emerald-400 text-white [&_svg]:text-emerald-400";case"warning":return t?"bg-amber-950/65 text-amber-200 [&_svg]:text-amber-300":"bg-black/10 bg-border border-2 border-amber-400 text-white [&_svg]:text-amber-400 [&_a]:text-amber-400!"}}const Sl=typeof document<"u"?p.useLayoutEffect:()=>{};var Tn;const Du=(Tn=p.useInsertionEffect)!==null&&Tn!==void 0?Tn:Sl;function _u(e){const t=p.useRef(null);return Du(()=>{t.current=e},[e]),p.useCallback((...n)=>{const r=t.current;return r?.(...n)},[])}const ze=e=>{var t;return(t=e?.ownerDocument)!==null&&t!==void 0?t:document},Ue=e=>e&&"window"in e&&e.window===e?e:ze(e).defaultView||window;function Bu(e){return e!==null&&typeof e=="object"&&"nodeType"in e&&typeof e.nodeType=="number"}function Hu(e){return Bu(e)&&e.nodeType===Node.DOCUMENT_FRAGMENT_NODE&&"host"in e}let Vu=!1;function mr(){return Vu}function $l(e,t){if(!mr())return t&&e?e.contains(t):!1;if(!e||!t)return!1;let n=t;for(;n!==null;){if(n===e)return!0;n.tagName==="SLOT"&&n.assignedSlot?n=n.assignedSlot.parentNode:Hu(n)?n=n.host:n=n.parentNode}return!1}const Un=(e=document)=>{var t;if(!mr())return e.activeElement;let n=e.activeElement;for(;n&&"shadowRoot"in n&&(!((t=n.shadowRoot)===null||t===void 0)&&t.activeElement);)n=n.shadowRoot.activeElement;return n};function kl(e){return mr()&&e.target.shadowRoot&&e.composedPath?e.composedPath()[0]:e.target}function sn(e){var t;if(typeof window>"u"||window.navigator==null)return!1;let n=(t=window.navigator.userAgentData)===null||t===void 0?void 0:t.brands;return Array.isArray(n)&&n.some(r=>e.test(r.brand))||e.test(window.navigator.userAgent)}function hr(e){var t;return typeof window<"u"&&window.navigator!=null?e.test(((t=window.navigator.userAgentData)===null||t===void 0?void 0:t.platform)||window.navigator.platform):!1}function Me(e){if(process.env.NODE_ENV==="test")return e;let t=null;return()=>(t==null&&(t=e()),t)}const gr=Me(function(){return hr(/^Mac/i)}),zu=Me(function(){return hr(/^iPhone/i)}),Wu=Me(function(){return hr(/^iPad/i)||gr()&&navigator.maxTouchPoints>1}),Uu=Me(function(){return zu()||Wu()});Me(function(){return gr()||Uu()});Me(function(){return sn(/AppleWebKit/i)&&!qu()});const qu=Me(function(){return sn(/Chrome/i)}),Gu=Me(function(){return sn(/Android/i)});Me(function(){return sn(/Firefox/i)});function Rl(){let e=p.useRef(new Map),t=p.useCallback((o,l,i,a)=>{let s=a?.once?(...u)=>{e.current.delete(i),i(...u)}:i;e.current.set(i,{type:l,eventTarget:o,fn:s,options:a}),o.addEventListener(l,s,a)},[]),n=p.useCallback((o,l,i,a)=>{var s;let u=((s=e.current.get(i))===null||s===void 0?void 0:s.fn)||i;o.removeEventListener(l,u,a),e.current.delete(i)},[]),r=p.useCallback(()=>{e.current.forEach((o,l)=>{n(o.eventTarget,o.type,l,o.options)})},[n]);return p.useEffect(()=>r,[r]),{addGlobalListener:t,removeGlobalListener:n,removeAllGlobalListeners:r}}function Ku(e){return e.pointerType===""&&e.isTrusted?!0:Gu()&&e.pointerType?e.type==="click"&&e.buttons===1:e.detail===0&&!e.pointerType}function Ol(e){let t=e;return t.nativeEvent=e,t.isDefaultPrevented=()=>t.defaultPrevented,t.isPropagationStopped=()=>t.cancelBubble,t.persist=()=>{},t}function Yu(e,t){Object.defineProperty(e,"target",{value:t}),Object.defineProperty(e,"currentTarget",{value:t})}function Tl(e){let t=p.useRef({isFocused:!1,observer:null});Sl(()=>{const r=t.current;return()=>{r.observer&&(r.observer.disconnect(),r.observer=null)}},[]);let n=_u(r=>{e?.(r)});return p.useCallback(r=>{if(r.target instanceof HTMLButtonElement||r.target instanceof HTMLInputElement||r.target instanceof HTMLTextAreaElement||r.target instanceof HTMLSelectElement){t.current.isFocused=!0;let o=r.target,l=i=>{if(t.current.isFocused=!1,o.disabled){let a=Ol(i);n(a)}t.current.observer&&(t.current.observer.disconnect(),t.current.observer=null)};o.addEventListener("focusout",l,{once:!0}),t.current.observer=new MutationObserver(()=>{if(t.current.isFocused&&o.disabled){var i;(i=t.current.observer)===null||i===void 0||i.disconnect();let a=o===document.activeElement?null:document.activeElement;o.dispatchEvent(new FocusEvent("blur",{relatedTarget:a})),o.dispatchEvent(new FocusEvent("focusout",{bubbles:!0,relatedTarget:a}))}}),t.current.observer.observe(o,{attributes:!0,attributeFilter:["disabled"]})}},[n])}let Zu=!1,Ot=null,qn=new Set,vt=new Map,Ke=!1,Gn=!1;const Xu={Tab:!0,Escape:!0};function vr(e,t){for(let n of qn)n(e,t)}function Ju(e){return!(e.metaKey||!gr()&&e.altKey||e.ctrlKey||e.key==="Control"||e.key==="Shift"||e.key==="Meta")}function Jt(e){Ke=!0,Ju(e)&&(Ot="keyboard",vr("keyboard",e))}function ve(e){Ot="pointer",(e.type==="mousedown"||e.type==="pointerdown")&&(Ke=!0,vr("pointer",e))}function Pl(e){Ku(e)&&(Ke=!0,Ot="virtual")}function Ll(e){e.target===window||e.target===document||Zu||!e.isTrusted||(!Ke&&!Gn&&(Ot="virtual",vr("virtual",e)),Ke=!1,Gn=!1)}function Al(){Ke=!1,Gn=!0}function Kn(e){if(typeof window>"u"||typeof document>"u"||vt.get(Ue(e)))return;const t=Ue(e),n=ze(e);let r=t.HTMLElement.prototype.focus;t.HTMLElement.prototype.focus=function(){Ke=!0,r.apply(this,arguments)},n.addEventListener("keydown",Jt,!0),n.addEventListener("keyup",Jt,!0),n.addEventListener("click",Pl,!0),t.addEventListener("focus",Ll,!0),t.addEventListener("blur",Al,!1),typeof PointerEvent<"u"?(n.addEventListener("pointerdown",ve,!0),n.addEventListener("pointermove",ve,!0),n.addEventListener("pointerup",ve,!0)):process.env.NODE_ENV==="test"&&(n.addEventListener("mousedown",ve,!0),n.addEventListener("mousemove",ve,!0),n.addEventListener("mouseup",ve,!0)),t.addEventListener("beforeunload",()=>{Fl(e)},{once:!0}),vt.set(t,{focus:r})}const Fl=(e,t)=>{const n=Ue(e),r=ze(e);t&&r.removeEventListener("DOMContentLoaded",t),vt.has(n)&&(n.HTMLElement.prototype.focus=vt.get(n).focus,r.removeEventListener("keydown",Jt,!0),r.removeEventListener("keyup",Jt,!0),r.removeEventListener("click",Pl,!0),n.removeEventListener("focus",Ll,!0),n.removeEventListener("blur",Al,!1),typeof PointerEvent<"u"?(r.removeEventListener("pointerdown",ve,!0),r.removeEventListener("pointermove",ve,!0),r.removeEventListener("pointerup",ve,!0)):process.env.NODE_ENV==="test"&&(r.removeEventListener("mousedown",ve,!0),r.removeEventListener("mousemove",ve,!0),r.removeEventListener("mouseup",ve,!0)),vt.delete(n))};function Qu(e){const t=ze(e);let n;return t.readyState!=="loading"?Kn(e):(n=()=>{Kn(e)},t.addEventListener("DOMContentLoaded",n)),()=>Fl(e,n)}typeof document<"u"&&Qu();function Ml(){return Ot!=="pointer"}const ec=new Set(["checkbox","radio","range","color","file","image","button","submit","reset"]);function tc(e,t,n){let r=ze(n?.target);const o=typeof window<"u"?Ue(n?.target).HTMLInputElement:HTMLInputElement,l=typeof window<"u"?Ue(n?.target).HTMLTextAreaElement:HTMLTextAreaElement,i=typeof window<"u"?Ue(n?.target).HTMLElement:HTMLElement,a=typeof window<"u"?Ue(n?.target).KeyboardEvent:KeyboardEvent;return e=e||r.activeElement instanceof o&&!ec.has(r.activeElement.type)||r.activeElement instanceof l||r.activeElement instanceof i&&r.activeElement.isContentEditable,!(e&&t==="keyboard"&&n instanceof a&&!Xu[n.key])}function nc(e,t,n){Kn(),p.useEffect(()=>{let r=(o,l)=>{tc(!!n?.isTextInput,o,l)&&e(Ml())};return qn.add(r),()=>{qn.delete(r)}},t)}function rc(e){let{isDisabled:t,onFocus:n,onBlur:r,onFocusChange:o}=e;const l=p.useCallback(s=>{if(s.target===s.currentTarget)return r&&r(s),o&&o(!1),!0},[r,o]),i=Tl(l),a=p.useCallback(s=>{const u=ze(s.target),c=u?Un(u):Un();s.target===s.currentTarget&&c===kl(s.nativeEvent)&&(n&&n(s),o&&o(!0),i(s))},[o,n,i]);return{focusProps:{onFocus:!t&&(n||o||r)?a:void 0,onBlur:!t&&(r||o)?l:void 0}}}function oc(e){let{isDisabled:t,onBlurWithin:n,onFocusWithin:r,onFocusWithinChange:o}=e,l=p.useRef({isFocusWithin:!1}),{addGlobalListener:i,removeAllGlobalListeners:a}=Rl(),s=p.useCallback(d=>{d.currentTarget.contains(d.target)&&l.current.isFocusWithin&&!d.currentTarget.contains(d.relatedTarget)&&(l.current.isFocusWithin=!1,a(),n&&n(d),o&&o(!1))},[n,o,l,a]),u=Tl(s),c=p.useCallback(d=>{if(!d.currentTarget.contains(d.target))return;const m=ze(d.target),f=Un(m);if(!l.current.isFocusWithin&&f===kl(d.nativeEvent)){r&&r(d),o&&o(!0),l.current.isFocusWithin=!0,u(d);let h=d.currentTarget;i(m,"focus",v=>{if(l.current.isFocusWithin&&!$l(h,v.target)){let b=new m.defaultView.FocusEvent("blur",{relatedTarget:v.target});Yu(b,h);let x=Ol(b);s(x)}},{capture:!0})}},[r,o,u,i,s]);return t?{focusWithinProps:{onFocus:void 0,onBlur:void 0}}:{focusWithinProps:{onFocus:c,onBlur:s}}}let Qt=!1,_t=0;function Yn(){Qt=!0,setTimeout(()=>{Qt=!1},50)}function eo(e){e.pointerType==="touch"&&Yn()}function lc(){if(!(typeof document>"u"))return _t===0&&(typeof PointerEvent<"u"?document.addEventListener("pointerup",eo):process.env.NODE_ENV==="test"&&document.addEventListener("touchend",Yn)),_t++,()=>{_t--,!(_t>0)&&(typeof PointerEvent<"u"?document.removeEventListener("pointerup",eo):process.env.NODE_ENV==="test"&&document.removeEventListener("touchend",Yn))}}function br(e){let{onHoverStart:t,onHoverChange:n,onHoverEnd:r,isDisabled:o}=e,[l,i]=p.useState(!1),a=p.useRef({isHovered:!1,ignoreEmulatedMouseEvents:!1,pointerType:"",target:null}).current;p.useEffect(lc,[]);let{addGlobalListener:s,removeAllGlobalListeners:u}=Rl(),{hoverProps:c,triggerHoverEnd:d}=p.useMemo(()=>{let m=(v,b)=>{if(a.pointerType=b,o||b==="touch"||a.isHovered||!v.currentTarget.contains(v.target))return;a.isHovered=!0;let x=v.currentTarget;a.target=x,s(ze(v.target),"pointerover",y=>{a.isHovered&&a.target&&!$l(a.target,y.target)&&f(y,y.pointerType)},{capture:!0}),t&&t({type:"hoverstart",target:x,pointerType:b}),n&&n(!0),i(!0)},f=(v,b)=>{let x=a.target;a.pointerType="",a.target=null,!(b==="touch"||!a.isHovered||!x)&&(a.isHovered=!1,u(),r&&r({type:"hoverend",target:x,pointerType:b}),n&&n(!1),i(!1))},h={};return typeof PointerEvent<"u"?(h.onPointerEnter=v=>{Qt&&v.pointerType==="mouse"||m(v,v.pointerType)},h.onPointerLeave=v=>{!o&&v.currentTarget.contains(v.target)&&f(v,v.pointerType)}):process.env.NODE_ENV==="test"&&(h.onTouchStart=()=>{a.ignoreEmulatedMouseEvents=!0},h.onMouseEnter=v=>{!a.ignoreEmulatedMouseEvents&&!Qt&&m(v,"mouse"),a.ignoreEmulatedMouseEvents=!1},h.onMouseLeave=v=>{!o&&v.currentTarget.contains(v.target)&&f(v,"mouse")}),{hoverProps:h,triggerHoverEnd:f}},[t,n,r,o,a,s,u]);return p.useEffect(()=>{o&&d({currentTarget:a.target},a.pointerType)},[o]),{hoverProps:c,isHovered:l}}function xr(e={}){let{autoFocus:t=!1,isTextInput:n,within:r}=e,o=p.useRef({isFocused:!1,isFocusVisible:t||Ml()}),[l,i]=p.useState(!1),[a,s]=p.useState(()=>o.current.isFocused&&o.current.isFocusVisible),u=p.useCallback(()=>s(o.current.isFocused&&o.current.isFocusVisible),[]),c=p.useCallback(f=>{o.current.isFocused=f,i(f),u()},[u]);nc(f=>{o.current.isFocusVisible=f,u()},[],{isTextInput:n});let{focusProps:d}=rc({isDisabled:r,onFocusChange:c}),{focusWithinProps:m}=oc({isDisabled:!r,onFocusWithinChange:c});return{isFocused:l,isFocusVisible:a,focusProps:r?m:d}}var ic=Object.defineProperty,ac=(e,t,n)=>t in e?ic(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Pn=(e,t,n)=>(ac(e,typeof t!="symbol"?t+"":t,n),n);let sc=class{constructor(){Pn(this,"current",this.detect()),Pn(this,"handoffState","pending"),Pn(this,"currentId",0)}set(t){this.current!==t&&(this.handoffState="pending",this.currentId=0,this.current=t)}reset(){this.set(this.detect())}nextId(){return++this.currentId}get isServer(){return this.current==="server"}get isClient(){return this.current==="client"}detect(){return typeof window>"u"||typeof document>"u"?"server":"client"}handoff(){this.handoffState==="pending"&&(this.handoffState="complete")}get isHandoffComplete(){return this.handoffState==="complete"}},Se=new sc;function Tt(e){var t;return Se.isServer?null:e==null?document:(t=e?.ownerDocument)!=null?t:document}function en(e){var t,n;return Se.isServer?null:e==null?document:(n=(t=e?.getRootNode)==null?void 0:t.call(e))!=null?n:document}function Nl(e){var t,n;return(n=(t=en(e))==null?void 0:t.activeElement)!=null?n:null}function uc(e){return Nl(e)===e}function Il(e){typeof queueMicrotask=="function"?queueMicrotask(e):Promise.resolve().then(e).catch(t=>setTimeout(()=>{throw t}))}function fe(){let e=[],t={addEventListener(n,r,o,l){return n.addEventListener(r,o,l),t.add(()=>n.removeEventListener(r,o,l))},requestAnimationFrame(...n){let r=requestAnimationFrame(...n);return t.add(()=>cancelAnimationFrame(r))},nextFrame(...n){return t.requestAnimationFrame(()=>t.requestAnimationFrame(...n))},setTimeout(...n){let r=setTimeout(...n);return t.add(()=>clearTimeout(r))},microTask(...n){let r={current:!0};return Il(()=>{r.current&&n[0]()}),t.add(()=>{r.current=!1})},style(n,r,o){let l=n.style.getPropertyValue(r);return Object.assign(n.style,{[r]:o}),this.add(()=>{Object.assign(n.style,{[r]:l})})},group(n){let r=fe();return n(r),this.add(()=>r.dispose())},add(n){return e.includes(n)||e.push(n),()=>{let r=e.indexOf(n);if(r>=0)for(let o of e.splice(r,1))o()}},dispose(){for(let n of e.splice(0))n()}};return t}function Xe(){let[e]=p.useState(fe);return p.useEffect(()=>()=>e.dispose(),[e]),e}let X=(e,t)=>{Se.isServer?p.useEffect(e,t):p.useLayoutEffect(e,t)};function Je(e){let t=p.useRef(e);return X(()=>{t.current=e},[e]),t}let D=function(e){let t=Je(e);return p.useCallback((...n)=>t.current(...n),[t])};function cc(e){let t=e.width/2,n=e.height/2;return{top:e.clientY-n,right:e.clientX+t,bottom:e.clientY+n,left:e.clientX-t}}function dc(e,t){return!(!e||!t||e.right<t.left||e.left>t.right||e.bottom<t.top||e.top>t.bottom)}function wr({disabled:e=!1}={}){let t=p.useRef(null),[n,r]=p.useState(!1),o=Xe(),l=D(()=>{t.current=null,r(!1),o.dispose()}),i=D(a=>{if(o.dispose(),t.current===null){t.current=a.currentTarget,r(!0);{let s=Tt(a.currentTarget);o.addEventListener(s,"pointerup",l,!1),o.addEventListener(s,"pointermove",u=>{if(t.current){let c=cc(u);r(dc(c,t.current.getBoundingClientRect()))}},!1),o.addEventListener(s,"pointercancel",l,!1)}}});return{pressed:n,pressProps:e?{}:{onPointerDown:i,onPointerUp:l,onClick:l}}}function be(e){return p.useMemo(()=>e,Object.values(e))}let fc=p.createContext(void 0);function un(){return p.useContext(fc)}function Zn(...e){return Array.from(new Set(e.flatMap(t=>typeof t=="string"?t.split(" "):[]))).filter(Boolean).join(" ")}function se(e,t,...n){if(e in t){let o=t[e];return typeof o=="function"?o(...n):o}let r=new Error(`Tried to handle "${e}" but there is no handler defined. Only defined handlers are: ${Object.keys(t).map(o=>`"${o}"`).join(", ")}.`);throw Error.captureStackTrace&&Error.captureStackTrace(r,se),r}var rt=(e=>(e[e.None=0]="None",e[e.RenderStrategy=1]="RenderStrategy",e[e.Static=2]="Static",e))(rt||{}),De=(e=>(e[e.Unmount=0]="Unmount",e[e.Hidden=1]="Hidden",e))(De||{});function te(){let e=mc();return p.useCallback(t=>pc({mergeRefs:e,...t}),[e])}function pc({ourProps:e,theirProps:t,slot:n,defaultTag:r,features:o,visible:l=!0,name:i,mergeRefs:a}){a=a??hc;let s=jl(t,e);if(l)return Bt(s,n,r,i,a);let u=o??0;if(u&2){let{static:c=!1,...d}=s;if(c)return Bt(d,n,r,i,a)}if(u&1){let{unmount:c=!0,...d}=s;return se(c?0:1,{0(){return null},1(){return Bt({...d,hidden:!0,style:{display:"none"}},n,r,i,a)}})}return Bt(s,n,r,i,a)}function Bt(e,t={},n,r,o){let{as:l=n,children:i,refName:a="ref",...s}=Ln(e,["unmount","static"]),u=e.ref!==void 0?{[a]:e.ref}:{},c=typeof i=="function"?i(t):i;"className"in s&&s.className&&typeof s.className=="function"&&(s.className=s.className(t)),s["aria-labelledby"]&&s["aria-labelledby"]===s.id&&(s["aria-labelledby"]=void 0);let d={};if(t){let m=!1,f=[];for(let[h,v]of Object.entries(t))typeof v=="boolean"&&(m=!0),v===!0&&f.push(h.replace(/([A-Z])/g,b=>`-${b.toLowerCase()}`));if(m){d["data-headlessui-state"]=f.join(" ");for(let h of f)d[`data-${h}`]=""}}if(tt(l)&&(Object.keys(je(s)).length>0||Object.keys(je(d)).length>0))if(!p.isValidElement(c)||Array.isArray(c)&&c.length>1||vc(c)){if(Object.keys(je(s)).length>0)throw new Error(['Passing props on "Fragment"!',"",`The current component <${r} /> is rendering a "Fragment".`,"However we need to passthrough the following props:",Object.keys(je(s)).concat(Object.keys(je(d))).map(m=>` - ${m}`).join(`
|
|
3
|
+
Please change the parent <Route path="${y}"> to <Route path="${y==="/"?"*":`${y}/*`}">.`)}let m=Fe(),f;if(t){let y=typeof t=="string"?lt(t):t;G(c==="/"||y.pathname?.startsWith(c),`When overriding the location using \`<Routes location>\` or \`useRoutes(routes, location)\`, the location pathname must begin with the portion of the URL pathname that was matched by all parent routes. The current pathname base is "${c}" but pathname "${y.pathname}" was given in the \`location\` prop.`),f=y}else f=m;let h=f.pathname||"/",v=h;if(c!=="/"){let y=c.replace(/^\//,"").split("/");v="/"+h.replace(/^\//,"").split("/").slice(y.length).join("/")}let b=zo(e,{pathname:v});we(d||b!=null,`No routes matched location "${f.pathname}${f.search}${f.hash}" `),we(b==null||b[b.length-1].route.element!==void 0||b[b.length-1].route.Component!==void 0||b[b.length-1].route.lazy!==void 0,`Matched leaf route at location "${f.pathname}${f.search}${f.hash}" does not have an element or Component. This means it will render an <Outlet /> with a null value by default resulting in an "empty" page.`);let x=Xa(b&&b.map(y=>Object.assign({},y,{params:Object.assign({},s,y.params),pathname:Pe([c,l.encodeLocation?l.encodeLocation(y.pathname.replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:y.pathname]),pathnameBase:y.pathnameBase==="/"?c:Pe([c,l.encodeLocation?l.encodeLocation(y.pathnameBase.replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:y.pathnameBase])})),i,n,r,o);return t&&x?g.createElement(kt.Provider,{value:{location:{pathname:"/",search:"",hash:"",state:null,key:"default",...f},navigationType:"POP"}},x):x}function Ga(){let e=ns(),t=Da(e)?`${e.status} ${e.statusText}`:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,r="rgba(200,200,200, 0.5)",o={padding:"0.5rem",backgroundColor:r},l={padding:"2px 4px",backgroundColor:r},i=null;return console.error("Error handled by React Router default ErrorBoundary:",e),i=g.createElement(g.Fragment,null,g.createElement("p",null,"💿 Hey developer 👋"),g.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",g.createElement("code",{style:l},"ErrorBoundary")," or"," ",g.createElement("code",{style:l},"errorElement")," prop on your route.")),g.createElement(g.Fragment,null,g.createElement("h2",null,"Unexpected Application Error!"),g.createElement("h3",{style:{fontStyle:"italic"}},t),n?g.createElement("pre",{style:o},n):null,i)}var Ka=g.createElement(Ga,null),Ya=class extends g.Component{constructor(e){super(e),this.state={location:e.location,revalidation:e.revalidation,error:e.error}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,t){return t.location!==e.location||t.revalidation!=="idle"&&e.revalidation==="idle"?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:e.error!==void 0?e.error:t.error,location:t.location,revalidation:e.revalidation||t.revalidation}}componentDidCatch(e,t){this.props.onError?this.props.onError(e,t):console.error("React Router caught the following error during render",e)}render(){return this.state.error!==void 0?g.createElement(Ae.Provider,{value:this.props.routeContext},g.createElement(ar.Provider,{value:this.state.error,children:this.props.component})):this.props.children}};function Za({routeContext:e,match:t,children:n}){let r=g.useContext(it);return r&&r.static&&r.staticContext&&(t.route.errorElement||t.route.ErrorBoundary)&&(r.staticContext._deepestRenderedBoundaryId=t.route.id),g.createElement(Ae.Provider,{value:e},n)}function Xa(e,t=[],n=null,r=null,o=null){if(e==null){if(!n)return null;if(n.errors)e=n.matches;else if(t.length===0&&!n.initialized&&n.matches.length>0)e=n.matches;else return null}let l=e,i=n?.errors;if(i!=null){let c=l.findIndex(d=>d.route.id&&i?.[d.route.id]!==void 0);G(c>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(i).join(",")}`),l=l.slice(0,Math.min(l.length,c+1))}let a=!1,s=-1;if(n)for(let c=0;c<l.length;c++){let d=l[c];if((d.route.HydrateFallback||d.route.hydrateFallbackElement)&&(s=c),d.route.id){let{loaderData:m,errors:f}=n,h=d.route.loader&&!m.hasOwnProperty(d.route.id)&&(!f||f[d.route.id]===void 0);if(d.route.lazy||h){a=!0,s>=0?l=l.slice(0,s+1):l=[l[0]];break}}}let u=n&&r?(c,d)=>{r(c,{location:n.location,params:n.matches?.[0]?.params??{},unstable_pattern:_a(n.matches),errorInfo:d})}:void 0;return l.reduceRight((c,d,m)=>{let f,h=!1,v=null,b=null;n&&(f=i&&d.route.id?i[d.route.id]:void 0,v=d.route.errorElement||Ka,a&&(s<0&&m===0?(tl("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),h=!0,b=null):s===m&&(h=!0,b=d.route.hydrateFallbackElement||null)));let x=t.concat(l.slice(0,m+1)),y=()=>{let w;return f?w=v:h?w=b:d.route.Component?w=g.createElement(d.route.Component,null):d.route.element?w=d.route.element:w=c,g.createElement(Za,{match:d,routeContext:{outlet:c,matches:x,isDataRoute:n!=null},children:w})};return n&&(d.route.ErrorBoundary||d.route.errorElement||m===0)?g.createElement(Ya,{location:n.location,revalidation:n.revalidation,component:v,error:f,children:y(),routeContext:{outlet:null,matches:x,isDataRoute:!0},onError:u}):y()},null)}function sr(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function Ja(e){let t=g.useContext(it);return G(t,sr(e)),t}function Qa(e){let t=g.useContext(ln);return G(t,sr(e)),t}function es(e){let t=g.useContext(Ae);return G(t,sr(e)),t}function ur(e){let t=es(e),n=t.matches[t.matches.length-1];return G(n.route.id,`${e} can only be used on routes that contain a unique "id"`),n.route.id}function ts(){return ur("useRouteId")}function ns(){let e=g.useContext(ar),t=Qa("useRouteError"),n=ur("useRouteError");return e!==void 0?e:t.errors?.[n]}function rs(){let{router:e}=Ja("useNavigate"),t=ur("useNavigate"),n=g.useRef(!1);return Jo(()=>{n.current=!0}),g.useCallback(async(o,l={})=>{we(n.current,Xo),n.current&&(typeof o=="number"?await e.navigate(o):await e.navigate(o,{fromRouteId:t,...l}))},[e,t])}var Ur={};function tl(e,t,n){!t&&!Ur[e]&&(Ur[e]=!0,we(!1,n))}g.memo(os);function os({routes:e,future:t,state:n,unstable_onError:r}){return el(e,void 0,n,r,t)}function nl(e){G(!1,"A <Route> is only ever to be used as the child of <Routes> element, never rendered directly. Please wrap your <Route> in a <Routes>.")}function ls({basename:e="/",children:t=null,location:n,navigationType:r="POP",navigator:o,static:l=!1,unstable_useTransitions:i}){G(!at(),"You cannot render a <Router> inside another <Router>. You should never have more than one in your app.");let a=e.replace(/^\/*/,"/"),s=g.useMemo(()=>({basename:a,navigator:o,static:l,unstable_useTransitions:i,future:{}}),[a,o,l,i]);typeof n=="string"&&(n=lt(n));let{pathname:u="/",search:c="",hash:d="",state:m=null,key:f="default"}=n,h=g.useMemo(()=>{let v=Le(u,a);return v==null?null:{location:{pathname:v,search:c,hash:d,state:m,key:f},navigationType:r}},[a,u,c,d,m,f,r]);return we(h!=null,`<Router basename="${a}"> is not able to match the URL "${u}${c}${d}" because it does not start with the basename, so the <Router> won't render anything.`),h==null?null:g.createElement(Ee.Provider,{value:s},g.createElement(kt.Provider,{children:t,value:h}))}function is({children:e,location:t}){return qa(zn(e),t)}function zn(e,t=[]){let n=[];return g.Children.forEach(e,(r,o)=>{if(!g.isValidElement(r))return;let l=[...t,o];if(r.type===g.Fragment){n.push.apply(n,zn(r.props.children,l));return}G(r.type===nl,`[${typeof r.type=="string"?r.type:r.type.name}] is not a <Route> component. All component children of <Routes> must be a <Route> or <React.Fragment>`),G(!r.props.index||!r.props.children,"An index route cannot have child routes.");let i={id:r.props.id||l.join("-"),caseSensitive:r.props.caseSensitive,element:r.props.element,Component:r.props.Component,index:r.props.index,path:r.props.path,middleware:r.props.middleware,loader:r.props.loader,action:r.props.action,hydrateFallbackElement:r.props.hydrateFallbackElement,HydrateFallback:r.props.HydrateFallback,errorElement:r.props.errorElement,ErrorBoundary:r.props.ErrorBoundary,hasErrorBoundary:r.props.hasErrorBoundary===!0||r.props.ErrorBoundary!=null||r.props.errorElement!=null,shouldRevalidate:r.props.shouldRevalidate,handle:r.props.handle,lazy:r.props.lazy};r.props.children&&(i.children=zn(r.props.children,l)),n.push(i)}),n}var Ut="get",qt="application/x-www-form-urlencoded";function an(e){return typeof HTMLElement<"u"&&e instanceof HTMLElement}function as(e){return an(e)&&e.tagName.toLowerCase()==="button"}function ss(e){return an(e)&&e.tagName.toLowerCase()==="form"}function us(e){return an(e)&&e.tagName.toLowerCase()==="input"}function cs(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function ds(e,t){return e.button===0&&(!t||t==="_self")&&!cs(e)}var It=null;function fs(){if(It===null)try{new FormData(document.createElement("form"),0),It=!1}catch{It=!0}return It}var ps=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function $n(e){return e!=null&&!ps.has(e)?(we(!1,`"${e}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${qt}"`),null):e}function ms(e,t){let n,r,o,l,i;if(ss(e)){let a=e.getAttribute("action");r=a?Le(a,t):null,n=e.getAttribute("method")||Ut,o=$n(e.getAttribute("enctype"))||qt,l=new FormData(e)}else if(as(e)||us(e)&&(e.type==="submit"||e.type==="image")){let a=e.form;if(a==null)throw new Error('Cannot submit a <button> or <input type="submit"> without a <form>');let s=e.getAttribute("formaction")||a.getAttribute("action");if(r=s?Le(s,t):null,n=e.getAttribute("formmethod")||a.getAttribute("method")||Ut,o=$n(e.getAttribute("formenctype"))||$n(a.getAttribute("enctype"))||qt,l=new FormData(a,e),!fs()){let{name:u,type:c,value:d}=e;if(c==="image"){let m=u?`${u}.`:"";l.append(`${m}x`,"0"),l.append(`${m}y`,"0")}else u&&l.append(u,d)}}else{if(an(e))throw new Error('Cannot submit element that is not <form>, <button>, or <input type="submit|image">');n=Ut,r=null,o=qt,i=e}return l&&o==="text/plain"&&(i=l,l=void 0),{action:r,method:n.toLowerCase(),encType:o,formData:l,body:i}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");function cr(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function hs(e,t,n){let r=typeof e=="string"?new URL(e,typeof window>"u"?"server://singlefetch/":window.location.origin):e;return r.pathname==="/"?r.pathname=`_root.${n}`:t&&Le(r.pathname,t)==="/"?r.pathname=`${t.replace(/\/$/,"")}/_root.${n}`:r.pathname=`${r.pathname.replace(/\/$/,"")}.${n}`,r}async function gs(e,t){if(e.id in t)return t[e.id];try{let n=await import(e.module);return t[e.id]=n,n}catch(n){return console.error(`Error loading route module \`${e.module}\`, reloading page...`),console.error(n),window.__reactRouterContext&&window.__reactRouterContext.isSpaMode,window.location.reload(),new Promise(()=>{})}}function vs(e){return e==null?!1:e.href==null?e.rel==="preload"&&typeof e.imageSrcSet=="string"&&typeof e.imageSizes=="string":typeof e.rel=="string"&&typeof e.href=="string"}async function bs(e,t,n){let r=await Promise.all(e.map(async o=>{let l=t.routes[o.route.id];if(l){let i=await gs(l,n);return i.links?i.links():[]}return[]}));return Es(r.flat(1).filter(vs).filter(o=>o.rel==="stylesheet"||o.rel==="preload").map(o=>o.rel==="stylesheet"?{...o,rel:"prefetch",as:"style"}:{...o,rel:"prefetch"}))}function qr(e,t,n,r,o,l){let i=(s,u)=>n[u]?s.route.id!==n[u].route.id:!0,a=(s,u)=>n[u].pathname!==s.pathname||n[u].route.path?.endsWith("*")&&n[u].params["*"]!==s.params["*"];return l==="assets"?t.filter((s,u)=>i(s,u)||a(s,u)):l==="data"?t.filter((s,u)=>{let c=r.routes[s.route.id];if(!c||!c.hasLoader)return!1;if(i(s,u)||a(s,u))return!0;if(s.route.shouldRevalidate){let d=s.route.shouldRevalidate({currentUrl:new URL(o.pathname+o.search+o.hash,window.origin),currentParams:n[0]?.params||{},nextUrl:new URL(e,window.origin),nextParams:s.params,defaultShouldRevalidate:!0});if(typeof d=="boolean")return d}return!0}):[]}function xs(e,t,{includeHydrateFallback:n}={}){return ws(e.map(r=>{let o=t.routes[r.route.id];if(!o)return[];let l=[o.module];return o.clientActionModule&&(l=l.concat(o.clientActionModule)),o.clientLoaderModule&&(l=l.concat(o.clientLoaderModule)),n&&o.hydrateFallbackModule&&(l=l.concat(o.hydrateFallbackModule)),o.imports&&(l=l.concat(o.imports)),l}).flat(1))}function ws(e){return[...new Set(e)]}function ys(e){let t={},n=Object.keys(e).sort();for(let r of n)t[r]=e[r];return t}function Es(e,t){let n=new Set;return new Set(t),e.reduce((r,o)=>{let l=JSON.stringify(ys(o));return n.has(l)||(n.add(l),r.push({key:l,link:o})),r},[])}function rl(){let e=g.useContext(it);return cr(e,"You must render this element inside a <DataRouterContext.Provider> element"),e}function Cs(){let e=g.useContext(ln);return cr(e,"You must render this element inside a <DataRouterStateContext.Provider> element"),e}var dr=g.createContext(void 0);dr.displayName="FrameworkContext";function ol(){let e=g.useContext(dr);return cr(e,"You must render this element inside a <HydratedRouter> element"),e}function Ss(e,t){let n=g.useContext(dr),[r,o]=g.useState(!1),[l,i]=g.useState(!1),{onFocus:a,onBlur:s,onMouseEnter:u,onMouseLeave:c,onTouchStart:d}=t,m=g.useRef(null);g.useEffect(()=>{if(e==="render"&&i(!0),e==="viewport"){let v=x=>{x.forEach(y=>{i(y.isIntersecting)})},b=new IntersectionObserver(v,{threshold:.5});return m.current&&b.observe(m.current),()=>{b.disconnect()}}},[e]),g.useEffect(()=>{if(r){let v=setTimeout(()=>{i(!0)},100);return()=>{clearTimeout(v)}}},[r]);let f=()=>{o(!0)},h=()=>{o(!1),i(!1)};return n?e!=="intent"?[l,m,{}]:[l,m,{onFocus:pt(a,f),onBlur:pt(s,h),onMouseEnter:pt(u,f),onMouseLeave:pt(c,h),onTouchStart:pt(d,f)}]:[!1,m,{}]}function pt(e,t){return n=>{e&&e(n),n.defaultPrevented||t(n)}}function $s({page:e,...t}){let{router:n}=rl(),r=g.useMemo(()=>zo(n.routes,e,n.basename),[n.routes,e,n.basename]);return r?g.createElement(Rs,{page:e,matches:r,...t}):null}function ks(e){let{manifest:t,routeModules:n}=ol(),[r,o]=g.useState([]);return g.useEffect(()=>{let l=!1;return bs(e,t,n).then(i=>{l||o(i)}),()=>{l=!0}},[e,t,n]),r}function Rs({page:e,matches:t,...n}){let r=Fe(),{manifest:o,routeModules:l}=ol(),{basename:i}=rl(),{loaderData:a,matches:s}=Cs(),u=g.useMemo(()=>qr(e,t,s,o,r,"data"),[e,t,s,o,r]),c=g.useMemo(()=>qr(e,t,s,o,r,"assets"),[e,t,s,o,r]),d=g.useMemo(()=>{if(e===r.pathname+r.search+r.hash)return[];let h=new Set,v=!1;if(t.forEach(x=>{let y=o.routes[x.route.id];!y||!y.hasLoader||(!u.some(w=>w.route.id===x.route.id)&&x.route.id in a&&l[x.route.id]?.shouldRevalidate||y.hasClientLoader?v=!0:h.add(x.route.id))}),h.size===0)return[];let b=hs(e,i,"data");return v&&h.size>0&&b.searchParams.set("_routes",t.filter(x=>h.has(x.route.id)).map(x=>x.route.id).join(",")),[b.pathname+b.search]},[i,a,r,o,u,t,e,l]),m=g.useMemo(()=>xs(c,o),[c,o]),f=ks(c);return g.createElement(g.Fragment,null,d.map(h=>g.createElement("link",{key:h,rel:"prefetch",as:"fetch",href:h,...n})),m.map(h=>g.createElement("link",{key:h,rel:"modulepreload",href:h,...n})),f.map(({key:h,link:v})=>g.createElement("link",{key:h,nonce:n.nonce,...v})))}function Os(...e){return t=>{e.forEach(n=>{typeof n=="function"?n(t):n!=null&&(n.current=t)})}}var ll=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";try{ll&&(window.__reactRouterVersion="7.10.1")}catch{}function Ts({basename:e,children:t,unstable_useTransitions:n,window:r}){let o=g.useRef();o.current==null&&(o.current=ha({window:r,v5Compat:!0}));let l=o.current,[i,a]=g.useState({action:l.action,location:l.location}),s=g.useCallback(u=>{n===!1?a(u):g.startTransition(()=>a(u))},[n]);return g.useLayoutEffect(()=>l.listen(s),[l,s]),g.createElement(ls,{basename:e,children:t,location:i.location,navigationType:i.action,navigator:l,unstable_useTransitions:n===!0})}var il=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,al=g.forwardRef(function({onClick:t,discover:n="render",prefetch:r="none",relative:o,reloadDocument:l,replace:i,state:a,target:s,to:u,preventScrollReset:c,viewTransition:d,...m},f){let{basename:h,unstable_useTransitions:v}=g.useContext(Ee),b=typeof u=="string"&&il.test(u),x,y=!1;if(typeof u=="string"&&b&&(x=u,ll))try{let R=new URL(window.location.href),M=u.startsWith("//")?new URL(R.protocol+u):new URL(u),H=Le(M.pathname,h);M.origin===R.origin&&H!=null?u=H+M.search+M.hash:y=!0}catch{we(!1,`<Link to="${u}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}let w=za(u,{relative:o}),[S,C,T]=Ss(r,m),O=Fs(u,{replace:i,state:a,target:s,preventScrollReset:c,relative:o,viewTransition:d,unstable_useTransitions:v});function k(R){t&&t(R),R.defaultPrevented||O(R)}let A=g.createElement("a",{...m,...T,href:x||w,onClick:y||l?t:k,ref:Os(f,C),target:s,"data-discover":!b&&n==="render"?"true":void 0});return S&&!b?g.createElement(g.Fragment,null,A,g.createElement($s,{page:w})):A});al.displayName="Link";var Ps=g.forwardRef(function({"aria-current":t="page",caseSensitive:n=!1,className:r="",end:o=!1,style:l,to:i,viewTransition:a,children:s,...u},c){let d=Rt(i,{relative:u.relative}),m=Fe(),f=g.useContext(ln),{navigator:h,basename:v}=g.useContext(Ee),b=f!=null&&Ds(d)&&a===!0,x=h.encodeLocation?h.encodeLocation(d).pathname:d.pathname,y=m.pathname,w=f&&f.navigation&&f.navigation.location?f.navigation.location.pathname:null;n||(y=y.toLowerCase(),w=w?w.toLowerCase():null,x=x.toLowerCase()),w&&v&&(w=Le(w,v)||w);const S=x!=="/"&&x.endsWith("/")?x.length-1:x.length;let C=y===x||!o&&y.startsWith(x)&&y.charAt(S)==="/",T=w!=null&&(w===x||!o&&w.startsWith(x)&&w.charAt(x.length)==="/"),O={isActive:C,isPending:T,isTransitioning:b},k=C?t:void 0,A;typeof r=="function"?A=r(O):A=[r,C?"active":null,T?"pending":null,b?"transitioning":null].filter(Boolean).join(" ");let R=typeof l=="function"?l(O):l;return g.createElement(al,{...u,"aria-current":k,className:A,ref:c,style:R,to:i,viewTransition:a},typeof s=="function"?s(O):s)});Ps.displayName="NavLink";var Ls=g.forwardRef(({discover:e="render",fetcherKey:t,navigate:n,reloadDocument:r,replace:o,state:l,method:i=Ut,action:a,onSubmit:s,relative:u,preventScrollReset:c,viewTransition:d,...m},f)=>{let{unstable_useTransitions:h}=g.useContext(Ee),v=Is(),b=js(a,{relative:u}),x=i.toLowerCase()==="get"?"get":"post",y=typeof a=="string"&&il.test(a),w=S=>{if(s&&s(S),S.defaultPrevented)return;S.preventDefault();let C=S.nativeEvent.submitter,T=C?.getAttribute("formmethod")||i,O=()=>v(C||S.currentTarget,{fetcherKey:t,method:T,navigate:n,replace:o,state:l,relative:u,preventScrollReset:c,viewTransition:d});h&&n!==!1?g.startTransition(()=>O()):O()};return g.createElement("form",{ref:f,method:x,action:b,onSubmit:r?s:w,...m,"data-discover":!y&&e==="render"?"true":void 0})});Ls.displayName="Form";function As(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function sl(e){let t=g.useContext(it);return G(t,As(e)),t}function Fs(e,{target:t,replace:n,state:r,preventScrollReset:o,relative:l,viewTransition:i,unstable_useTransitions:a}={}){let s=Qo(),u=Fe(),c=Rt(e,{relative:l});return g.useCallback(d=>{if(ds(d,t)){d.preventDefault();let m=n!==void 0?n:xt(u)===xt(c),f=()=>s(e,{replace:m,state:r,preventScrollReset:o,relative:l,viewTransition:i});a?g.startTransition(()=>f()):f()}},[u,s,c,n,r,t,e,o,l,i,a])}var Ms=0,Ns=()=>`__${String(++Ms)}__`;function Is(){let{router:e}=sl("useSubmit"),{basename:t}=g.useContext(Ee),n=ts(),r=e.fetch,o=e.navigate;return g.useCallback(async(l,i={})=>{let{action:a,method:s,encType:u,formData:c,body:d}=ms(l,t);if(i.navigate===!1){let m=i.fetcherKey||Ns();await r(m,n,i.action||a,{preventScrollReset:i.preventScrollReset,formData:c,body:d,formMethod:i.method||s,formEncType:i.encType||u,flushSync:i.flushSync})}else await o(i.action||a,{preventScrollReset:i.preventScrollReset,formData:c,body:d,formMethod:i.method||s,formEncType:i.encType||u,replace:i.replace,state:i.state,fromRouteId:n,flushSync:i.flushSync,viewTransition:i.viewTransition})},[r,o,t,n])}function js(e,{relative:t}={}){let{basename:n}=g.useContext(Ee),r=g.useContext(Ae);G(r,"useFormAction must be used inside a RouteContext");let[o]=r.matches.slice(-1),l={...Rt(e||".",{relative:t})},i=Fe();if(e==null){l.search=i.search;let a=new URLSearchParams(l.search),s=a.getAll("index");if(s.some(c=>c==="")){a.delete("index"),s.filter(d=>d).forEach(d=>a.append("index",d));let c=a.toString();l.search=c?`?${c}`:""}}return(!e||e===".")&&o.route.index&&(l.search=l.search?l.search.replace(/^\?/,"?index&"):"?index"),n!=="/"&&(l.pathname=l.pathname==="/"?n:Pe([n,l.pathname])),xt(l)}function Ds(e,{relative:t}={}){let n=g.useContext(Zo);G(n!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:r}=sl("useViewTransitionState"),o=Rt(e,{relative:t});if(!n.isTransitioning)return!1;let l=Le(n.currentLocation.pathname,r)||n.currentLocation.pathname,i=Le(n.nextLocation.pathname,r)||n.nextLocation.pathname;return wt(o.pathname,i)!=null||wt(o.pathname,l)!=null}const _s=e=>g.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:16,height:16,fill:"currentColor",className:"bi bi-github",viewBox:"0 0 16 16",...e},g.createElement("path",{d:"M8 0C3.58 0 0 3.58 0 8c0 3.54 2.29 6.53 5.47 7.59.4.07.55-.17.55-.38 0-.19-.01-.82-.01-1.49-2.01.37-2.53-.49-2.69-.94-.09-.23-.48-.94-.82-1.13-.28-.15-.68-.52-.01-.53.63-.01 1.08.58 1.23.82.72 1.21 1.87.87 2.33.66.07-.52.28-.87.51-1.07-1.78-.2-3.64-.89-3.64-3.95 0-.87.31-1.59.82-2.15-.08-.2-.36-1.02.08-2.12 0 0 .67-.21 2.2.82.64-.18 1.32-.27 2-.27s1.36.09 2 .27c1.53-1.04 2.2-.82 2.2-.82.44 1.1.16 1.92.08 2.12.51.56.82 1.27.82 2.15 0 3.07-1.87 3.75-3.65 3.95.29.25.54.73.54 1.48 0 1.07-.01 1.93-.01 2.2 0 .21.15.46.55.38A8.01 8.01 0 0 0 16 8c0-4.42-3.58-8-8-8"})),Bs=e=>g.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 128 128",...e},g.createElement("path",{fill:"currentColor",d:"M2 38.5h124v43.71H64v7.29H36.44v-7.29H2zm6.89 36.43h13.78V53.07h6.89v21.86h6.89V45.79H8.89zm34.44-29.14v36.42h13.78v-7.28h13.78V45.79zm13.78 7.29H64v14.56h-6.89zm20.67-7.29v29.14h13.78V53.07h6.89v21.86h6.89V53.07h6.89v21.86h6.89V45.79z"})),ul=e=>g.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",height:"24px",viewBox:"0 0 640 640",width:"24px",fill:"currentColor",...e},g.createElement("path",{d:"M433.2 103.1L581.4 253.4C609.1 281.5 609.1 326.5 581.4 354.6L425 512.9C415.7 522.3 400.5 522.4 391.1 513.1C381.7 503.8 381.6 488.6 390.9 479.2L547.3 320.8C556.5 311.5 556.5 296.4 547.3 287.1L399 136.9C389.7 127.5 389.8 112.3 399.2 103C408.6 93.7 423.8 93.8 433.1 103.2zM64.1 293.5L64.1 160C64.1 124.7 92.8 96 128.1 96L261.6 96C278.6 96 294.9 102.7 306.9 114.7L450.9 258.7C475.9 283.7 475.9 324.2 450.9 349.2L317.4 482.7C292.4 507.7 251.9 507.7 226.9 482.7L82.9 338.7C70.9 326.7 64.2 310.4 64.2 293.4zM208.1 208C208.1 190.3 193.8 176 176.1 176C158.4 176 144.1 190.3 144.1 208C144.1 225.7 158.4 240 176.1 240C193.8 240 208.1 225.7 208.1 208z"})),cl=p.createContext(null),Gr=e=>{let t;const n=new Set,r=(u,c)=>{const d=typeof u=="function"?u(t):u;if(!Object.is(d,t)){const m=t;t=c??(typeof d!="object"||d===null)?d:Object.assign({},t,d),n.forEach(f=>f(t,m))}},o=()=>t,a={setState:r,getState:o,getInitialState:()=>s,subscribe:u=>(n.add(u),()=>n.delete(u))},s=t=e(r,o,a);return a},Hs=(e=>e?Gr(e):Gr),Vs=e=>e;function zs(e,t=Vs){const n=p.useSyncExternalStore(e.subscribe,p.useCallback(()=>t(e.getState()),[e,t]),p.useCallback(()=>t(e.getInitialState()),[e,t]));return p.useDebugValue(n),n}const Kr=e=>{const t=Hs(e),n=r=>zs(t,r);return Object.assign(n,t),n},Ws=(e=>e?Kr(e):Kr),dl=Ws(e=>({visible:!1,hide:()=>e({visible:!1}),show:()=>e({visible:!0}),toggle:()=>e(t=>({visible:!t.visible}))}));function fl(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(n=fl(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function Us(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=fl(e))&&(r&&(r+=" "),r+=t);return r}const qs=(e,t)=>{const n=new Array(e.length+t.length);for(let r=0;r<e.length;r++)n[r]=e[r];for(let r=0;r<t.length;r++)n[e.length+r]=t[r];return n},Gs=(e,t)=>({classGroupId:e,validator:t}),pl=(e=new Map,t=null,n)=>({nextPart:e,validators:t,classGroupId:n}),Xt="-",Yr=[],Ks="arbitrary..",Ys=e=>{const t=Xs(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:i=>{if(i.startsWith("[")&&i.endsWith("]"))return Zs(i);const a=i.split(Xt),s=a[0]===""&&a.length>1?1:0;return ml(a,s,t)},getConflictingClassGroupIds:(i,a)=>{if(a){const s=r[i],u=n[i];return s?u?qs(u,s):s:u||Yr}return n[i]||Yr}}},ml=(e,t,n)=>{if(e.length-t===0)return n.classGroupId;const o=e[t],l=n.nextPart.get(o);if(l){const u=ml(e,t+1,l);if(u)return u}const i=n.validators;if(i===null)return;const a=t===0?e.join(Xt):e.slice(t).join(Xt),s=i.length;for(let u=0;u<s;u++){const c=i[u];if(c.validator(a))return c.classGroupId}},Zs=e=>e.slice(1,-1).indexOf(":")===-1?void 0:(()=>{const t=e.slice(1,-1),n=t.indexOf(":"),r=t.slice(0,n);return r?Ks+r:void 0})(),Xs=e=>{const{theme:t,classGroups:n}=e;return Js(n,t)},Js=(e,t)=>{const n=pl();for(const r in e){const o=e[r];fr(o,n,r,t)}return n},fr=(e,t,n,r)=>{const o=e.length;for(let l=0;l<o;l++){const i=e[l];Qs(i,t,n,r)}},Qs=(e,t,n,r)=>{if(typeof e=="string"){eu(e,t,n);return}if(typeof e=="function"){tu(e,t,n,r);return}nu(e,t,n,r)},eu=(e,t,n)=>{const r=e===""?t:hl(t,e);r.classGroupId=n},tu=(e,t,n,r)=>{if(ru(e)){fr(e(r),t,n,r);return}t.validators===null&&(t.validators=[]),t.validators.push(Gs(n,e))},nu=(e,t,n,r)=>{const o=Object.entries(e),l=o.length;for(let i=0;i<l;i++){const[a,s]=o[i];fr(s,hl(t,a),n,r)}},hl=(e,t)=>{let n=e;const r=t.split(Xt),o=r.length;for(let l=0;l<o;l++){const i=r[l];let a=n.nextPart.get(i);a||(a=pl(),n.nextPart.set(i,a)),n=a}return n},ru=e=>"isThemeGetter"in e&&e.isThemeGetter===!0,ou=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=Object.create(null),r=Object.create(null);const o=(l,i)=>{n[l]=i,t++,t>e&&(t=0,r=n,n=Object.create(null))};return{get(l){let i=n[l];if(i!==void 0)return i;if((i=r[l])!==void 0)return o(l,i),i},set(l,i){l in n?n[l]=i:o(l,i)}}},Wn="!",Zr=":",lu=[],Xr=(e,t,n,r,o)=>({modifiers:e,hasImportantModifier:t,baseClassName:n,maybePostfixModifierPosition:r,isExternal:o}),iu=e=>{const{prefix:t,experimentalParseClassName:n}=e;let r=o=>{const l=[];let i=0,a=0,s=0,u;const c=o.length;for(let v=0;v<c;v++){const b=o[v];if(i===0&&a===0){if(b===Zr){l.push(o.slice(s,v)),s=v+1;continue}if(b==="/"){u=v;continue}}b==="["?i++:b==="]"?i--:b==="("?a++:b===")"&&a--}const d=l.length===0?o:o.slice(s);let m=d,f=!1;d.endsWith(Wn)?(m=d.slice(0,-1),f=!0):d.startsWith(Wn)&&(m=d.slice(1),f=!0);const h=u&&u>s?u-s:void 0;return Xr(l,f,m,h)};if(t){const o=t+Zr,l=r;r=i=>i.startsWith(o)?l(i.slice(o.length)):Xr(lu,!1,i,void 0,!0)}if(n){const o=r;r=l=>n({className:l,parseClassName:o})}return r},au=e=>{const t=new Map;return e.orderSensitiveModifiers.forEach((n,r)=>{t.set(n,1e6+r)}),n=>{const r=[];let o=[];for(let l=0;l<n.length;l++){const i=n[l],a=i[0]==="[",s=t.has(i);a||s?(o.length>0&&(o.sort(),r.push(...o),o=[]),r.push(i)):o.push(i)}return o.length>0&&(o.sort(),r.push(...o)),r}},su=e=>({cache:ou(e.cacheSize),parseClassName:iu(e),sortModifiers:au(e),...Ys(e)}),uu=/\s+/,cu=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:o,sortModifiers:l}=t,i=[],a=e.trim().split(uu);let s="";for(let u=a.length-1;u>=0;u-=1){const c=a[u],{isExternal:d,modifiers:m,hasImportantModifier:f,baseClassName:h,maybePostfixModifierPosition:v}=n(c);if(d){s=c+(s.length>0?" "+s:s);continue}let b=!!v,x=r(b?h.substring(0,v):h);if(!x){if(!b){s=c+(s.length>0?" "+s:s);continue}if(x=r(h),!x){s=c+(s.length>0?" "+s:s);continue}b=!1}const y=m.length===0?"":m.length===1?m[0]:l(m).join(":"),w=f?y+Wn:y,S=w+x;if(i.indexOf(S)>-1)continue;i.push(S);const C=o(x,b);for(let T=0;T<C.length;++T){const O=C[T];i.push(w+O)}s=c+(s.length>0?" "+s:s)}return s},du=(...e)=>{let t=0,n,r,o="";for(;t<e.length;)(n=e[t++])&&(r=gl(n))&&(o&&(o+=" "),o+=r);return o},gl=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=gl(e[r]))&&(n&&(n+=" "),n+=t);return n},fu=(e,...t)=>{let n,r,o,l;const i=s=>{const u=t.reduce((c,d)=>d(c),e());return n=su(u),r=n.cache.get,o=n.cache.set,l=a,a(s)},a=s=>{const u=r(s);if(u)return u;const c=cu(s,n);return o(s,c),c};return l=i,(...s)=>l(du(...s))},pu=[],J=e=>{const t=n=>n[e]||pu;return t.isThemeGetter=!0,t},vl=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,bl=/^\((?:(\w[\w-]*):)?(.+)\)$/i,mu=/^\d+\/\d+$/,hu=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,gu=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,vu=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,bu=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,xu=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Qe=e=>mu.test(e),j=e=>!!e&&!Number.isNaN(Number(e)),Ie=e=>!!e&&Number.isInteger(Number(e)),kn=e=>e.endsWith("%")&&j(e.slice(0,-1)),Oe=e=>hu.test(e),wu=()=>!0,yu=e=>gu.test(e)&&!vu.test(e),xl=()=>!1,Eu=e=>bu.test(e),Cu=e=>xu.test(e),Su=e=>!P(e)&&!L(e),$u=e=>st(e,El,xl),P=e=>vl.test(e),We=e=>st(e,Cl,yu),Rn=e=>st(e,Pu,j),Jr=e=>st(e,wl,xl),ku=e=>st(e,yl,Cu),jt=e=>st(e,Sl,Eu),L=e=>bl.test(e),mt=e=>ut(e,Cl),Ru=e=>ut(e,Lu),Qr=e=>ut(e,wl),Ou=e=>ut(e,El),Tu=e=>ut(e,yl),Dt=e=>ut(e,Sl,!0),st=(e,t,n)=>{const r=vl.exec(e);return r?r[1]?t(r[1]):n(r[2]):!1},ut=(e,t,n=!1)=>{const r=bl.exec(e);return r?r[1]?t(r[1]):n:!1},wl=e=>e==="position"||e==="percentage",yl=e=>e==="image"||e==="url",El=e=>e==="length"||e==="size"||e==="bg-size",Cl=e=>e==="length",Pu=e=>e==="number",Lu=e=>e==="family-name",Sl=e=>e==="shadow",Au=()=>{const e=J("color"),t=J("font"),n=J("text"),r=J("font-weight"),o=J("tracking"),l=J("leading"),i=J("breakpoint"),a=J("container"),s=J("spacing"),u=J("radius"),c=J("shadow"),d=J("inset-shadow"),m=J("text-shadow"),f=J("drop-shadow"),h=J("blur"),v=J("perspective"),b=J("aspect"),x=J("ease"),y=J("animate"),w=()=>["auto","avoid","all","avoid-page","page","left","right","column"],S=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],C=()=>[...S(),L,P],T=()=>["auto","hidden","clip","visible","scroll"],O=()=>["auto","contain","none"],k=()=>[L,P,s],A=()=>[Qe,"full","auto",...k()],R=()=>[Ie,"none","subgrid",L,P],M=()=>["auto",{span:["full",Ie,L,P]},Ie,L,P],H=()=>[Ie,"auto",L,P],z=()=>["auto","min","max","fr",L,P],B=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],F=()=>["start","end","center","stretch","center-safe","end-safe"],I=()=>["auto",...k()],U=()=>[Qe,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...k()],$=()=>[e,L,P],V=()=>[...S(),Qr,Jr,{position:[L,P]}],q=()=>["no-repeat",{repeat:["","x","y","space","round"]}],pe=()=>["auto","cover","contain",Ou,$u,{size:[L,P]}],K=()=>[kn,mt,We],_=()=>["","none","full",u,L,P],ee=()=>["",j,mt,We],me=()=>["solid","dashed","dotted","double"],N=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],W=()=>[j,kn,Qr,Jr],xe=()=>["","none",h,L,P],he=()=>["none",j,L,P],Mt=()=>["none",j,L,P],Cn=()=>[j,L,P],Nt=()=>[Qe,"full",...k()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[Oe],breakpoint:[Oe],color:[wu],container:[Oe],"drop-shadow":[Oe],ease:["in","out","in-out"],font:[Su],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[Oe],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[Oe],shadow:[Oe],spacing:["px",j],text:[Oe],"text-shadow":[Oe],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",Qe,P,L,b]}],container:["container"],columns:[{columns:[j,P,L,a]}],"break-after":[{"break-after":w()}],"break-before":[{"break-before":w()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:C()}],overflow:[{overflow:T()}],"overflow-x":[{"overflow-x":T()}],"overflow-y":[{"overflow-y":T()}],overscroll:[{overscroll:O()}],"overscroll-x":[{"overscroll-x":O()}],"overscroll-y":[{"overscroll-y":O()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:A()}],"inset-x":[{"inset-x":A()}],"inset-y":[{"inset-y":A()}],start:[{start:A()}],end:[{end:A()}],top:[{top:A()}],right:[{right:A()}],bottom:[{bottom:A()}],left:[{left:A()}],visibility:["visible","invisible","collapse"],z:[{z:[Ie,"auto",L,P]}],basis:[{basis:[Qe,"full","auto",a,...k()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[j,Qe,"auto","initial","none",P]}],grow:[{grow:["",j,L,P]}],shrink:[{shrink:["",j,L,P]}],order:[{order:[Ie,"first","last","none",L,P]}],"grid-cols":[{"grid-cols":R()}],"col-start-end":[{col:M()}],"col-start":[{"col-start":H()}],"col-end":[{"col-end":H()}],"grid-rows":[{"grid-rows":R()}],"row-start-end":[{row:M()}],"row-start":[{"row-start":H()}],"row-end":[{"row-end":H()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":z()}],"auto-rows":[{"auto-rows":z()}],gap:[{gap:k()}],"gap-x":[{"gap-x":k()}],"gap-y":[{"gap-y":k()}],"justify-content":[{justify:[...B(),"normal"]}],"justify-items":[{"justify-items":[...F(),"normal"]}],"justify-self":[{"justify-self":["auto",...F()]}],"align-content":[{content:["normal",...B()]}],"align-items":[{items:[...F(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...F(),{baseline:["","last"]}]}],"place-content":[{"place-content":B()}],"place-items":[{"place-items":[...F(),"baseline"]}],"place-self":[{"place-self":["auto",...F()]}],p:[{p:k()}],px:[{px:k()}],py:[{py:k()}],ps:[{ps:k()}],pe:[{pe:k()}],pt:[{pt:k()}],pr:[{pr:k()}],pb:[{pb:k()}],pl:[{pl:k()}],m:[{m:I()}],mx:[{mx:I()}],my:[{my:I()}],ms:[{ms:I()}],me:[{me:I()}],mt:[{mt:I()}],mr:[{mr:I()}],mb:[{mb:I()}],ml:[{ml:I()}],"space-x":[{"space-x":k()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":k()}],"space-y-reverse":["space-y-reverse"],size:[{size:U()}],w:[{w:[a,"screen",...U()]}],"min-w":[{"min-w":[a,"screen","none",...U()]}],"max-w":[{"max-w":[a,"screen","none","prose",{screen:[i]},...U()]}],h:[{h:["screen","lh",...U()]}],"min-h":[{"min-h":["screen","lh","none",...U()]}],"max-h":[{"max-h":["screen","lh",...U()]}],"font-size":[{text:["base",n,mt,We]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[r,L,Rn]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",kn,P]}],"font-family":[{font:[Ru,P,t]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:[o,L,P]}],"line-clamp":[{"line-clamp":[j,"none",L,Rn]}],leading:[{leading:[l,...k()]}],"list-image":[{"list-image":["none",L,P]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",L,P]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:$()}],"text-color":[{text:$()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...me(),"wavy"]}],"text-decoration-thickness":[{decoration:[j,"from-font","auto",L,We]}],"text-decoration-color":[{decoration:$()}],"underline-offset":[{"underline-offset":[j,"auto",L,P]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:k()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",L,P]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",L,P]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:V()}],"bg-repeat":[{bg:q()}],"bg-size":[{bg:pe()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},Ie,L,P],radial:["",L,P],conic:[Ie,L,P]},Tu,ku]}],"bg-color":[{bg:$()}],"gradient-from-pos":[{from:K()}],"gradient-via-pos":[{via:K()}],"gradient-to-pos":[{to:K()}],"gradient-from":[{from:$()}],"gradient-via":[{via:$()}],"gradient-to":[{to:$()}],rounded:[{rounded:_()}],"rounded-s":[{"rounded-s":_()}],"rounded-e":[{"rounded-e":_()}],"rounded-t":[{"rounded-t":_()}],"rounded-r":[{"rounded-r":_()}],"rounded-b":[{"rounded-b":_()}],"rounded-l":[{"rounded-l":_()}],"rounded-ss":[{"rounded-ss":_()}],"rounded-se":[{"rounded-se":_()}],"rounded-ee":[{"rounded-ee":_()}],"rounded-es":[{"rounded-es":_()}],"rounded-tl":[{"rounded-tl":_()}],"rounded-tr":[{"rounded-tr":_()}],"rounded-br":[{"rounded-br":_()}],"rounded-bl":[{"rounded-bl":_()}],"border-w":[{border:ee()}],"border-w-x":[{"border-x":ee()}],"border-w-y":[{"border-y":ee()}],"border-w-s":[{"border-s":ee()}],"border-w-e":[{"border-e":ee()}],"border-w-t":[{"border-t":ee()}],"border-w-r":[{"border-r":ee()}],"border-w-b":[{"border-b":ee()}],"border-w-l":[{"border-l":ee()}],"divide-x":[{"divide-x":ee()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":ee()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...me(),"hidden","none"]}],"divide-style":[{divide:[...me(),"hidden","none"]}],"border-color":[{border:$()}],"border-color-x":[{"border-x":$()}],"border-color-y":[{"border-y":$()}],"border-color-s":[{"border-s":$()}],"border-color-e":[{"border-e":$()}],"border-color-t":[{"border-t":$()}],"border-color-r":[{"border-r":$()}],"border-color-b":[{"border-b":$()}],"border-color-l":[{"border-l":$()}],"divide-color":[{divide:$()}],"outline-style":[{outline:[...me(),"none","hidden"]}],"outline-offset":[{"outline-offset":[j,L,P]}],"outline-w":[{outline:["",j,mt,We]}],"outline-color":[{outline:$()}],shadow:[{shadow:["","none",c,Dt,jt]}],"shadow-color":[{shadow:$()}],"inset-shadow":[{"inset-shadow":["none",d,Dt,jt]}],"inset-shadow-color":[{"inset-shadow":$()}],"ring-w":[{ring:ee()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:$()}],"ring-offset-w":[{"ring-offset":[j,We]}],"ring-offset-color":[{"ring-offset":$()}],"inset-ring-w":[{"inset-ring":ee()}],"inset-ring-color":[{"inset-ring":$()}],"text-shadow":[{"text-shadow":["none",m,Dt,jt]}],"text-shadow-color":[{"text-shadow":$()}],opacity:[{opacity:[j,L,P]}],"mix-blend":[{"mix-blend":[...N(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":N()}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[j]}],"mask-image-linear-from-pos":[{"mask-linear-from":W()}],"mask-image-linear-to-pos":[{"mask-linear-to":W()}],"mask-image-linear-from-color":[{"mask-linear-from":$()}],"mask-image-linear-to-color":[{"mask-linear-to":$()}],"mask-image-t-from-pos":[{"mask-t-from":W()}],"mask-image-t-to-pos":[{"mask-t-to":W()}],"mask-image-t-from-color":[{"mask-t-from":$()}],"mask-image-t-to-color":[{"mask-t-to":$()}],"mask-image-r-from-pos":[{"mask-r-from":W()}],"mask-image-r-to-pos":[{"mask-r-to":W()}],"mask-image-r-from-color":[{"mask-r-from":$()}],"mask-image-r-to-color":[{"mask-r-to":$()}],"mask-image-b-from-pos":[{"mask-b-from":W()}],"mask-image-b-to-pos":[{"mask-b-to":W()}],"mask-image-b-from-color":[{"mask-b-from":$()}],"mask-image-b-to-color":[{"mask-b-to":$()}],"mask-image-l-from-pos":[{"mask-l-from":W()}],"mask-image-l-to-pos":[{"mask-l-to":W()}],"mask-image-l-from-color":[{"mask-l-from":$()}],"mask-image-l-to-color":[{"mask-l-to":$()}],"mask-image-x-from-pos":[{"mask-x-from":W()}],"mask-image-x-to-pos":[{"mask-x-to":W()}],"mask-image-x-from-color":[{"mask-x-from":$()}],"mask-image-x-to-color":[{"mask-x-to":$()}],"mask-image-y-from-pos":[{"mask-y-from":W()}],"mask-image-y-to-pos":[{"mask-y-to":W()}],"mask-image-y-from-color":[{"mask-y-from":$()}],"mask-image-y-to-color":[{"mask-y-to":$()}],"mask-image-radial":[{"mask-radial":[L,P]}],"mask-image-radial-from-pos":[{"mask-radial-from":W()}],"mask-image-radial-to-pos":[{"mask-radial-to":W()}],"mask-image-radial-from-color":[{"mask-radial-from":$()}],"mask-image-radial-to-color":[{"mask-radial-to":$()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":S()}],"mask-image-conic-pos":[{"mask-conic":[j]}],"mask-image-conic-from-pos":[{"mask-conic-from":W()}],"mask-image-conic-to-pos":[{"mask-conic-to":W()}],"mask-image-conic-from-color":[{"mask-conic-from":$()}],"mask-image-conic-to-color":[{"mask-conic-to":$()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:V()}],"mask-repeat":[{mask:q()}],"mask-size":[{mask:pe()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",L,P]}],filter:[{filter:["","none",L,P]}],blur:[{blur:xe()}],brightness:[{brightness:[j,L,P]}],contrast:[{contrast:[j,L,P]}],"drop-shadow":[{"drop-shadow":["","none",f,Dt,jt]}],"drop-shadow-color":[{"drop-shadow":$()}],grayscale:[{grayscale:["",j,L,P]}],"hue-rotate":[{"hue-rotate":[j,L,P]}],invert:[{invert:["",j,L,P]}],saturate:[{saturate:[j,L,P]}],sepia:[{sepia:["",j,L,P]}],"backdrop-filter":[{"backdrop-filter":["","none",L,P]}],"backdrop-blur":[{"backdrop-blur":xe()}],"backdrop-brightness":[{"backdrop-brightness":[j,L,P]}],"backdrop-contrast":[{"backdrop-contrast":[j,L,P]}],"backdrop-grayscale":[{"backdrop-grayscale":["",j,L,P]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[j,L,P]}],"backdrop-invert":[{"backdrop-invert":["",j,L,P]}],"backdrop-opacity":[{"backdrop-opacity":[j,L,P]}],"backdrop-saturate":[{"backdrop-saturate":[j,L,P]}],"backdrop-sepia":[{"backdrop-sepia":["",j,L,P]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":k()}],"border-spacing-x":[{"border-spacing-x":k()}],"border-spacing-y":[{"border-spacing-y":k()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",L,P]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[j,"initial",L,P]}],ease:[{ease:["linear","initial",x,L,P]}],delay:[{delay:[j,L,P]}],animate:[{animate:["none",y,L,P]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[v,L,P]}],"perspective-origin":[{"perspective-origin":C()}],rotate:[{rotate:he()}],"rotate-x":[{"rotate-x":he()}],"rotate-y":[{"rotate-y":he()}],"rotate-z":[{"rotate-z":he()}],scale:[{scale:Mt()}],"scale-x":[{"scale-x":Mt()}],"scale-y":[{"scale-y":Mt()}],"scale-z":[{"scale-z":Mt()}],"scale-3d":["scale-3d"],skew:[{skew:Cn()}],"skew-x":[{"skew-x":Cn()}],"skew-y":[{"skew-y":Cn()}],transform:[{transform:[L,P,"","none","gpu","cpu"]}],"transform-origin":[{origin:C()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:Nt()}],"translate-x":[{"translate-x":Nt()}],"translate-y":[{"translate-y":Nt()}],"translate-z":[{"translate-z":Nt()}],"translate-none":["translate-none"],accent:[{accent:$()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:$()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",L,P]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":k()}],"scroll-mx":[{"scroll-mx":k()}],"scroll-my":[{"scroll-my":k()}],"scroll-ms":[{"scroll-ms":k()}],"scroll-me":[{"scroll-me":k()}],"scroll-mt":[{"scroll-mt":k()}],"scroll-mr":[{"scroll-mr":k()}],"scroll-mb":[{"scroll-mb":k()}],"scroll-ml":[{"scroll-ml":k()}],"scroll-p":[{"scroll-p":k()}],"scroll-px":[{"scroll-px":k()}],"scroll-py":[{"scroll-py":k()}],"scroll-ps":[{"scroll-ps":k()}],"scroll-pe":[{"scroll-pe":k()}],"scroll-pt":[{"scroll-pt":k()}],"scroll-pr":[{"scroll-pr":k()}],"scroll-pb":[{"scroll-pb":k()}],"scroll-pl":[{"scroll-pl":k()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",L,P]}],fill:[{fill:["none",...$()]}],"stroke-w":[{stroke:[j,mt,We,Rn]}],stroke:[{stroke:["none",...$()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-x","border-w-y","border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-x","border-color-y","border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]},orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}},Fu=fu(Au);function ie(...e){return Fu(Us(e))}function le({align:e,children:t,className:n,direction:r,gap:o=0,grow:l,justify:i,shrink:a,style:s,wrap:u,...c}){return E.jsx("div",{className:ie("flex",{"items-center":e==="center","items-end":e==="end","items-start":e==="start","items-stretch":e==="stretch","flex-col":r==="column","flex-row":r==="row","gap-1":o===1,"gap-2":o===2,"gap-3":o===3,"gap-4":o===4,"gap-5":o===5,"gap-6":o===6,"gap-7":o===7,"gap-8":o===8,"grow-0":l===0,"grow-1":l===1,"justify-around":i==="around","justify-between":i==="between","justify-center":i==="center","justify-end":i==="end","justify-start":i==="start","justify-stretch":i==="stretch","shrink-0":a===0,"shrink-1":a===1,"flex-wrap":u},n),style:s,...c,children:t})}const Mu=p.createContext(null),On={didCatch:!1,error:null};let Nu=class extends p.Component{constructor(t){super(t),this.resetErrorBoundary=this.resetErrorBoundary.bind(this),this.state=On}static getDerivedStateFromError(t){return{didCatch:!0,error:t}}resetErrorBoundary(){const{error:t}=this.state;if(t!==null){for(var n,r,o=arguments.length,l=new Array(o),i=0;i<o;i++)l[i]=arguments[i];(n=(r=this.props).onReset)===null||n===void 0||n.call(r,{args:l,reason:"imperative-api"}),this.setState(On)}}componentDidCatch(t,n){var r,o;(r=(o=this.props).onError)===null||r===void 0||r.call(o,t,n)}componentDidUpdate(t,n){const{didCatch:r}=this.state,{resetKeys:o}=this.props;if(r&&n.error!==null&&Iu(t.resetKeys,o)){var l,i;(l=(i=this.props).onReset)===null||l===void 0||l.call(i,{next:o,prev:t.resetKeys,reason:"keys"}),this.setState(On)}}render(){const{children:t,fallbackRender:n,FallbackComponent:r,fallback:o}=this.props,{didCatch:l,error:i}=this.state;let a=t;if(l){const s={error:i,resetErrorBoundary:this.resetErrorBoundary};if(typeof n=="function")a=n(s);else if(r)a=p.createElement(r,s);else if(o!==void 0)a=o;else throw i}return p.createElement(Mu.Provider,{value:{didCatch:l,error:i,resetErrorBoundary:this.resetErrorBoundary}},a)}};function Iu(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[];return e.length!==t.length||e.some((n,r)=>!Object.is(n,t[r]))}function pr({children:e,className:t,html:n=!1,inline:r=!1,intent:o="none",minimal:l,...i}){let a=ca;switch(o){case"none":case"primary":{a=fa;break}case"success":{a=la;break}}return E.jsx("div",{className:`${r?"w-fit":"w-full"} rounded-md p-2 px-3 ${ju(o,!!l)} ${t}`,role:"alert",...i,children:E.jsxs("div",{className:"flex flex-row gap-2",children:[E.jsx(a,{className:"w-6 h-6 shrink-0"}),n?E.jsx("div",{dangerouslySetInnerHTML:{__html:e}}):E.jsx("div",{children:e})]})})}function ju(e,t){switch(e){case"danger":return t?"bg-red-950 text-red-300 [&_svg]:text-red-500":"bg-black/10 bg-border border-2 border-red-500 text-white [&_svg]:text-red-500 [&_a]:text-red-400!";case"none":return t?"bg-white/10 text-slate-300 [&_svg]:text-slate-400":"bg-black/10 bg-border border-2 border-white/40 text-white [&_svg]:text-white/60";case"primary":return t?"bg-sky-950 text-sky-300 [&_svg]:text-sky-400":"bg-black/10 bg-border border-2 border-sky-400 text-white [&_svg]:text-sky-400";case"success":return t?"bg-emerald-950 text-emerald-300 [&_svg]:text-emerald-400":"bg-black/10 bg-border border-2 border-emerald-400 text-white [&_svg]:text-emerald-400";case"warning":return t?"bg-amber-950/65 text-amber-200 [&_svg]:text-amber-300":"bg-black/10 bg-border border-2 border-amber-400 text-white [&_svg]:text-amber-400 [&_a]:text-amber-400!"}}const $l=typeof document<"u"?p.useLayoutEffect:()=>{};var Tn;const Du=(Tn=p.useInsertionEffect)!==null&&Tn!==void 0?Tn:$l;function _u(e){const t=p.useRef(null);return Du(()=>{t.current=e},[e]),p.useCallback((...n)=>{const r=t.current;return r?.(...n)},[])}const ze=e=>{var t;return(t=e?.ownerDocument)!==null&&t!==void 0?t:document},Ue=e=>e&&"window"in e&&e.window===e?e:ze(e).defaultView||window;function Bu(e){return e!==null&&typeof e=="object"&&"nodeType"in e&&typeof e.nodeType=="number"}function Hu(e){return Bu(e)&&e.nodeType===Node.DOCUMENT_FRAGMENT_NODE&&"host"in e}let Vu=!1;function mr(){return Vu}function kl(e,t){if(!mr())return t&&e?e.contains(t):!1;if(!e||!t)return!1;let n=t;for(;n!==null;){if(n===e)return!0;n.tagName==="SLOT"&&n.assignedSlot?n=n.assignedSlot.parentNode:Hu(n)?n=n.host:n=n.parentNode}return!1}const Un=(e=document)=>{var t;if(!mr())return e.activeElement;let n=e.activeElement;for(;n&&"shadowRoot"in n&&(!((t=n.shadowRoot)===null||t===void 0)&&t.activeElement);)n=n.shadowRoot.activeElement;return n};function Rl(e){return mr()&&e.target.shadowRoot&&e.composedPath?e.composedPath()[0]:e.target}function sn(e){var t;if(typeof window>"u"||window.navigator==null)return!1;let n=(t=window.navigator.userAgentData)===null||t===void 0?void 0:t.brands;return Array.isArray(n)&&n.some(r=>e.test(r.brand))||e.test(window.navigator.userAgent)}function hr(e){var t;return typeof window<"u"&&window.navigator!=null?e.test(((t=window.navigator.userAgentData)===null||t===void 0?void 0:t.platform)||window.navigator.platform):!1}function Me(e){if(process.env.NODE_ENV==="test")return e;let t=null;return()=>(t==null&&(t=e()),t)}const gr=Me(function(){return hr(/^Mac/i)}),zu=Me(function(){return hr(/^iPhone/i)}),Wu=Me(function(){return hr(/^iPad/i)||gr()&&navigator.maxTouchPoints>1}),Uu=Me(function(){return zu()||Wu()});Me(function(){return gr()||Uu()});Me(function(){return sn(/AppleWebKit/i)&&!qu()});const qu=Me(function(){return sn(/Chrome/i)}),Gu=Me(function(){return sn(/Android/i)});Me(function(){return sn(/Firefox/i)});function Ol(){let e=p.useRef(new Map),t=p.useCallback((o,l,i,a)=>{let s=a?.once?(...u)=>{e.current.delete(i),i(...u)}:i;e.current.set(i,{type:l,eventTarget:o,fn:s,options:a}),o.addEventListener(l,s,a)},[]),n=p.useCallback((o,l,i,a)=>{var s;let u=((s=e.current.get(i))===null||s===void 0?void 0:s.fn)||i;o.removeEventListener(l,u,a),e.current.delete(i)},[]),r=p.useCallback(()=>{e.current.forEach((o,l)=>{n(o.eventTarget,o.type,l,o.options)})},[n]);return p.useEffect(()=>r,[r]),{addGlobalListener:t,removeGlobalListener:n,removeAllGlobalListeners:r}}function Ku(e){return e.pointerType===""&&e.isTrusted?!0:Gu()&&e.pointerType?e.type==="click"&&e.buttons===1:e.detail===0&&!e.pointerType}function Tl(e){let t=e;return t.nativeEvent=e,t.isDefaultPrevented=()=>t.defaultPrevented,t.isPropagationStopped=()=>t.cancelBubble,t.persist=()=>{},t}function Yu(e,t){Object.defineProperty(e,"target",{value:t}),Object.defineProperty(e,"currentTarget",{value:t})}function Pl(e){let t=p.useRef({isFocused:!1,observer:null});$l(()=>{const r=t.current;return()=>{r.observer&&(r.observer.disconnect(),r.observer=null)}},[]);let n=_u(r=>{e?.(r)});return p.useCallback(r=>{if(r.target instanceof HTMLButtonElement||r.target instanceof HTMLInputElement||r.target instanceof HTMLTextAreaElement||r.target instanceof HTMLSelectElement){t.current.isFocused=!0;let o=r.target,l=i=>{if(t.current.isFocused=!1,o.disabled){let a=Tl(i);n(a)}t.current.observer&&(t.current.observer.disconnect(),t.current.observer=null)};o.addEventListener("focusout",l,{once:!0}),t.current.observer=new MutationObserver(()=>{if(t.current.isFocused&&o.disabled){var i;(i=t.current.observer)===null||i===void 0||i.disconnect();let a=o===document.activeElement?null:document.activeElement;o.dispatchEvent(new FocusEvent("blur",{relatedTarget:a})),o.dispatchEvent(new FocusEvent("focusout",{bubbles:!0,relatedTarget:a}))}}),t.current.observer.observe(o,{attributes:!0,attributeFilter:["disabled"]})}},[n])}let Zu=!1,Ot=null,qn=new Set,vt=new Map,Ke=!1,Gn=!1;const Xu={Tab:!0,Escape:!0};function vr(e,t){for(let n of qn)n(e,t)}function Ju(e){return!(e.metaKey||!gr()&&e.altKey||e.ctrlKey||e.key==="Control"||e.key==="Shift"||e.key==="Meta")}function Jt(e){Ke=!0,Ju(e)&&(Ot="keyboard",vr("keyboard",e))}function ve(e){Ot="pointer",(e.type==="mousedown"||e.type==="pointerdown")&&(Ke=!0,vr("pointer",e))}function Ll(e){Ku(e)&&(Ke=!0,Ot="virtual")}function Al(e){e.target===window||e.target===document||Zu||!e.isTrusted||(!Ke&&!Gn&&(Ot="virtual",vr("virtual",e)),Ke=!1,Gn=!1)}function Fl(){Ke=!1,Gn=!0}function Kn(e){if(typeof window>"u"||typeof document>"u"||vt.get(Ue(e)))return;const t=Ue(e),n=ze(e);let r=t.HTMLElement.prototype.focus;t.HTMLElement.prototype.focus=function(){Ke=!0,r.apply(this,arguments)},n.addEventListener("keydown",Jt,!0),n.addEventListener("keyup",Jt,!0),n.addEventListener("click",Ll,!0),t.addEventListener("focus",Al,!0),t.addEventListener("blur",Fl,!1),typeof PointerEvent<"u"?(n.addEventListener("pointerdown",ve,!0),n.addEventListener("pointermove",ve,!0),n.addEventListener("pointerup",ve,!0)):process.env.NODE_ENV==="test"&&(n.addEventListener("mousedown",ve,!0),n.addEventListener("mousemove",ve,!0),n.addEventListener("mouseup",ve,!0)),t.addEventListener("beforeunload",()=>{Ml(e)},{once:!0}),vt.set(t,{focus:r})}const Ml=(e,t)=>{const n=Ue(e),r=ze(e);t&&r.removeEventListener("DOMContentLoaded",t),vt.has(n)&&(n.HTMLElement.prototype.focus=vt.get(n).focus,r.removeEventListener("keydown",Jt,!0),r.removeEventListener("keyup",Jt,!0),r.removeEventListener("click",Ll,!0),n.removeEventListener("focus",Al,!0),n.removeEventListener("blur",Fl,!1),typeof PointerEvent<"u"?(r.removeEventListener("pointerdown",ve,!0),r.removeEventListener("pointermove",ve,!0),r.removeEventListener("pointerup",ve,!0)):process.env.NODE_ENV==="test"&&(r.removeEventListener("mousedown",ve,!0),r.removeEventListener("mousemove",ve,!0),r.removeEventListener("mouseup",ve,!0)),vt.delete(n))};function Qu(e){const t=ze(e);let n;return t.readyState!=="loading"?Kn(e):(n=()=>{Kn(e)},t.addEventListener("DOMContentLoaded",n)),()=>Ml(e,n)}typeof document<"u"&&Qu();function Nl(){return Ot!=="pointer"}const ec=new Set(["checkbox","radio","range","color","file","image","button","submit","reset"]);function tc(e,t,n){let r=ze(n?.target);const o=typeof window<"u"?Ue(n?.target).HTMLInputElement:HTMLInputElement,l=typeof window<"u"?Ue(n?.target).HTMLTextAreaElement:HTMLTextAreaElement,i=typeof window<"u"?Ue(n?.target).HTMLElement:HTMLElement,a=typeof window<"u"?Ue(n?.target).KeyboardEvent:KeyboardEvent;return e=e||r.activeElement instanceof o&&!ec.has(r.activeElement.type)||r.activeElement instanceof l||r.activeElement instanceof i&&r.activeElement.isContentEditable,!(e&&t==="keyboard"&&n instanceof a&&!Xu[n.key])}function nc(e,t,n){Kn(),p.useEffect(()=>{let r=(o,l)=>{tc(!!n?.isTextInput,o,l)&&e(Nl())};return qn.add(r),()=>{qn.delete(r)}},t)}function rc(e){let{isDisabled:t,onFocus:n,onBlur:r,onFocusChange:o}=e;const l=p.useCallback(s=>{if(s.target===s.currentTarget)return r&&r(s),o&&o(!1),!0},[r,o]),i=Pl(l),a=p.useCallback(s=>{const u=ze(s.target),c=u?Un(u):Un();s.target===s.currentTarget&&c===Rl(s.nativeEvent)&&(n&&n(s),o&&o(!0),i(s))},[o,n,i]);return{focusProps:{onFocus:!t&&(n||o||r)?a:void 0,onBlur:!t&&(r||o)?l:void 0}}}function oc(e){let{isDisabled:t,onBlurWithin:n,onFocusWithin:r,onFocusWithinChange:o}=e,l=p.useRef({isFocusWithin:!1}),{addGlobalListener:i,removeAllGlobalListeners:a}=Ol(),s=p.useCallback(d=>{d.currentTarget.contains(d.target)&&l.current.isFocusWithin&&!d.currentTarget.contains(d.relatedTarget)&&(l.current.isFocusWithin=!1,a(),n&&n(d),o&&o(!1))},[n,o,l,a]),u=Pl(s),c=p.useCallback(d=>{if(!d.currentTarget.contains(d.target))return;const m=ze(d.target),f=Un(m);if(!l.current.isFocusWithin&&f===Rl(d.nativeEvent)){r&&r(d),o&&o(!0),l.current.isFocusWithin=!0,u(d);let h=d.currentTarget;i(m,"focus",v=>{if(l.current.isFocusWithin&&!kl(h,v.target)){let b=new m.defaultView.FocusEvent("blur",{relatedTarget:v.target});Yu(b,h);let x=Tl(b);s(x)}},{capture:!0})}},[r,o,u,i,s]);return t?{focusWithinProps:{onFocus:void 0,onBlur:void 0}}:{focusWithinProps:{onFocus:c,onBlur:s}}}let Qt=!1,_t=0;function Yn(){Qt=!0,setTimeout(()=>{Qt=!1},50)}function eo(e){e.pointerType==="touch"&&Yn()}function lc(){if(!(typeof document>"u"))return _t===0&&(typeof PointerEvent<"u"?document.addEventListener("pointerup",eo):process.env.NODE_ENV==="test"&&document.addEventListener("touchend",Yn)),_t++,()=>{_t--,!(_t>0)&&(typeof PointerEvent<"u"?document.removeEventListener("pointerup",eo):process.env.NODE_ENV==="test"&&document.removeEventListener("touchend",Yn))}}function br(e){let{onHoverStart:t,onHoverChange:n,onHoverEnd:r,isDisabled:o}=e,[l,i]=p.useState(!1),a=p.useRef({isHovered:!1,ignoreEmulatedMouseEvents:!1,pointerType:"",target:null}).current;p.useEffect(lc,[]);let{addGlobalListener:s,removeAllGlobalListeners:u}=Ol(),{hoverProps:c,triggerHoverEnd:d}=p.useMemo(()=>{let m=(v,b)=>{if(a.pointerType=b,o||b==="touch"||a.isHovered||!v.currentTarget.contains(v.target))return;a.isHovered=!0;let x=v.currentTarget;a.target=x,s(ze(v.target),"pointerover",y=>{a.isHovered&&a.target&&!kl(a.target,y.target)&&f(y,y.pointerType)},{capture:!0}),t&&t({type:"hoverstart",target:x,pointerType:b}),n&&n(!0),i(!0)},f=(v,b)=>{let x=a.target;a.pointerType="",a.target=null,!(b==="touch"||!a.isHovered||!x)&&(a.isHovered=!1,u(),r&&r({type:"hoverend",target:x,pointerType:b}),n&&n(!1),i(!1))},h={};return typeof PointerEvent<"u"?(h.onPointerEnter=v=>{Qt&&v.pointerType==="mouse"||m(v,v.pointerType)},h.onPointerLeave=v=>{!o&&v.currentTarget.contains(v.target)&&f(v,v.pointerType)}):process.env.NODE_ENV==="test"&&(h.onTouchStart=()=>{a.ignoreEmulatedMouseEvents=!0},h.onMouseEnter=v=>{!a.ignoreEmulatedMouseEvents&&!Qt&&m(v,"mouse"),a.ignoreEmulatedMouseEvents=!1},h.onMouseLeave=v=>{!o&&v.currentTarget.contains(v.target)&&f(v,"mouse")}),{hoverProps:h,triggerHoverEnd:f}},[t,n,r,o,a,s,u]);return p.useEffect(()=>{o&&d({currentTarget:a.target},a.pointerType)},[o]),{hoverProps:c,isHovered:l}}function xr(e={}){let{autoFocus:t=!1,isTextInput:n,within:r}=e,o=p.useRef({isFocused:!1,isFocusVisible:t||Nl()}),[l,i]=p.useState(!1),[a,s]=p.useState(()=>o.current.isFocused&&o.current.isFocusVisible),u=p.useCallback(()=>s(o.current.isFocused&&o.current.isFocusVisible),[]),c=p.useCallback(f=>{o.current.isFocused=f,i(f),u()},[u]);nc(f=>{o.current.isFocusVisible=f,u()},[],{isTextInput:n});let{focusProps:d}=rc({isDisabled:r,onFocusChange:c}),{focusWithinProps:m}=oc({isDisabled:!r,onFocusWithinChange:c});return{isFocused:l,isFocusVisible:a,focusProps:r?m:d}}var ic=Object.defineProperty,ac=(e,t,n)=>t in e?ic(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Pn=(e,t,n)=>(ac(e,typeof t!="symbol"?t+"":t,n),n);let sc=class{constructor(){Pn(this,"current",this.detect()),Pn(this,"handoffState","pending"),Pn(this,"currentId",0)}set(t){this.current!==t&&(this.handoffState="pending",this.currentId=0,this.current=t)}reset(){this.set(this.detect())}nextId(){return++this.currentId}get isServer(){return this.current==="server"}get isClient(){return this.current==="client"}detect(){return typeof window>"u"||typeof document>"u"?"server":"client"}handoff(){this.handoffState==="pending"&&(this.handoffState="complete")}get isHandoffComplete(){return this.handoffState==="complete"}},Se=new sc;function Tt(e){var t;return Se.isServer?null:e==null?document:(t=e?.ownerDocument)!=null?t:document}function en(e){var t,n;return Se.isServer?null:e==null?document:(n=(t=e?.getRootNode)==null?void 0:t.call(e))!=null?n:document}function Il(e){var t,n;return(n=(t=en(e))==null?void 0:t.activeElement)!=null?n:null}function uc(e){return Il(e)===e}function jl(e){typeof queueMicrotask=="function"?queueMicrotask(e):Promise.resolve().then(e).catch(t=>setTimeout(()=>{throw t}))}function fe(){let e=[],t={addEventListener(n,r,o,l){return n.addEventListener(r,o,l),t.add(()=>n.removeEventListener(r,o,l))},requestAnimationFrame(...n){let r=requestAnimationFrame(...n);return t.add(()=>cancelAnimationFrame(r))},nextFrame(...n){return t.requestAnimationFrame(()=>t.requestAnimationFrame(...n))},setTimeout(...n){let r=setTimeout(...n);return t.add(()=>clearTimeout(r))},microTask(...n){let r={current:!0};return jl(()=>{r.current&&n[0]()}),t.add(()=>{r.current=!1})},style(n,r,o){let l=n.style.getPropertyValue(r);return Object.assign(n.style,{[r]:o}),this.add(()=>{Object.assign(n.style,{[r]:l})})},group(n){let r=fe();return n(r),this.add(()=>r.dispose())},add(n){return e.includes(n)||e.push(n),()=>{let r=e.indexOf(n);if(r>=0)for(let o of e.splice(r,1))o()}},dispose(){for(let n of e.splice(0))n()}};return t}function Xe(){let[e]=p.useState(fe);return p.useEffect(()=>()=>e.dispose(),[e]),e}let X=(e,t)=>{Se.isServer?p.useEffect(e,t):p.useLayoutEffect(e,t)};function Je(e){let t=p.useRef(e);return X(()=>{t.current=e},[e]),t}let D=function(e){let t=Je(e);return p.useCallback((...n)=>t.current(...n),[t])};function cc(e){let t=e.width/2,n=e.height/2;return{top:e.clientY-n,right:e.clientX+t,bottom:e.clientY+n,left:e.clientX-t}}function dc(e,t){return!(!e||!t||e.right<t.left||e.left>t.right||e.bottom<t.top||e.top>t.bottom)}function wr({disabled:e=!1}={}){let t=p.useRef(null),[n,r]=p.useState(!1),o=Xe(),l=D(()=>{t.current=null,r(!1),o.dispose()}),i=D(a=>{if(o.dispose(),t.current===null){t.current=a.currentTarget,r(!0);{let s=Tt(a.currentTarget);o.addEventListener(s,"pointerup",l,!1),o.addEventListener(s,"pointermove",u=>{if(t.current){let c=cc(u);r(dc(c,t.current.getBoundingClientRect()))}},!1),o.addEventListener(s,"pointercancel",l,!1)}}});return{pressed:n,pressProps:e?{}:{onPointerDown:i,onPointerUp:l,onClick:l}}}function be(e){return p.useMemo(()=>e,Object.values(e))}let fc=p.createContext(void 0);function un(){return p.useContext(fc)}function Zn(...e){return Array.from(new Set(e.flatMap(t=>typeof t=="string"?t.split(" "):[]))).filter(Boolean).join(" ")}function se(e,t,...n){if(e in t){let o=t[e];return typeof o=="function"?o(...n):o}let r=new Error(`Tried to handle "${e}" but there is no handler defined. Only defined handlers are: ${Object.keys(t).map(o=>`"${o}"`).join(", ")}.`);throw Error.captureStackTrace&&Error.captureStackTrace(r,se),r}var rt=(e=>(e[e.None=0]="None",e[e.RenderStrategy=1]="RenderStrategy",e[e.Static=2]="Static",e))(rt||{}),De=(e=>(e[e.Unmount=0]="Unmount",e[e.Hidden=1]="Hidden",e))(De||{});function te(){let e=mc();return p.useCallback(t=>pc({mergeRefs:e,...t}),[e])}function pc({ourProps:e,theirProps:t,slot:n,defaultTag:r,features:o,visible:l=!0,name:i,mergeRefs:a}){a=a??hc;let s=Dl(t,e);if(l)return Bt(s,n,r,i,a);let u=o??0;if(u&2){let{static:c=!1,...d}=s;if(c)return Bt(d,n,r,i,a)}if(u&1){let{unmount:c=!0,...d}=s;return se(c?0:1,{0(){return null},1(){return Bt({...d,hidden:!0,style:{display:"none"}},n,r,i,a)}})}return Bt(s,n,r,i,a)}function Bt(e,t={},n,r,o){let{as:l=n,children:i,refName:a="ref",...s}=Ln(e,["unmount","static"]),u=e.ref!==void 0?{[a]:e.ref}:{},c=typeof i=="function"?i(t):i;"className"in s&&s.className&&typeof s.className=="function"&&(s.className=s.className(t)),s["aria-labelledby"]&&s["aria-labelledby"]===s.id&&(s["aria-labelledby"]=void 0);let d={};if(t){let m=!1,f=[];for(let[h,v]of Object.entries(t))typeof v=="boolean"&&(m=!0),v===!0&&f.push(h.replace(/([A-Z])/g,b=>`-${b.toLowerCase()}`));if(m){d["data-headlessui-state"]=f.join(" ");for(let h of f)d[`data-${h}`]=""}}if(tt(l)&&(Object.keys(je(s)).length>0||Object.keys(je(d)).length>0))if(!p.isValidElement(c)||Array.isArray(c)&&c.length>1||vc(c)){if(Object.keys(je(s)).length>0)throw new Error(['Passing props on "Fragment"!',"",`The current component <${r} /> is rendering a "Fragment".`,"However we need to passthrough the following props:",Object.keys(je(s)).concat(Object.keys(je(d))).map(m=>` - ${m}`).join(`
|
|
4
4
|
`),"","You can apply a few solutions:",['Add an `as="..."` prop, to ensure that we render an actual element instead of a "Fragment".',"Render a single element as the child so that we can forward the props onto that element."].map(m=>` - ${m}`).join(`
|
|
5
5
|
`)].join(`
|
|
6
|
-
`))}else{let m=c.props,f=m?.className,h=typeof f=="function"?(...x)=>Zn(f(...x),s.className):Zn(f,s.className),v=h?{className:h}:{},b=jl(c.props,je(Ln(s,["ref"])));for(let x in d)x in b&&delete d[x];return p.cloneElement(c,Object.assign({},b,d,u,{ref:o(gc(c),u.ref)},v))}return p.createElement(l,Object.assign({},Ln(s,["ref"]),!tt(l)&&u,!tt(l)&&d),c)}function mc(){let e=p.useRef([]),t=p.useCallback(n=>{for(let r of e.current)r!=null&&(typeof r=="function"?r(n):r.current=n)},[]);return(...n)=>{if(!n.every(r=>r==null))return e.current=n,t}}function hc(...e){return e.every(t=>t==null)?void 0:t=>{for(let n of e)n!=null&&(typeof n=="function"?n(t):n.current=t)}}function jl(...e){if(e.length===0)return{};if(e.length===1)return e[0];let t={},n={};for(let r of e)for(let o in r)o.startsWith("on")&&typeof r[o]=="function"?(n[o]!=null||(n[o]=[]),n[o].push(r[o])):t[o]=r[o];if(t.disabled||t["aria-disabled"])for(let r in n)/^(on(?:Click|Pointer|Mouse|Key)(?:Down|Up|Press)?)$/.test(r)&&(n[r]=[o=>{var l;return(l=o?.preventDefault)==null?void 0:l.call(o)}]);for(let r in n)Object.assign(t,{[r](o,...l){let i=n[r];for(let a of i){if((o instanceof Event||o?.nativeEvent instanceof Event)&&o.defaultPrevented)return;a(o,...l)}}});return t}function yt(...e){if(e.length===0)return{};if(e.length===1)return e[0];let t={},n={};for(let r of e)for(let o in r)o.startsWith("on")&&typeof r[o]=="function"?(n[o]!=null||(n[o]=[]),n[o].push(r[o])):t[o]=r[o];for(let r in n)Object.assign(t,{[r](...o){let l=n[r];for(let i of l)i?.(...o)}});return t}function Q(e){var t;return Object.assign(p.forwardRef(e),{displayName:(t=e.displayName)!=null?t:e.name})}function je(e){let t=Object.assign({},e);for(let n in t)t[n]===void 0&&delete t[n];return t}function Ln(e,t=[]){let n=Object.assign({},e);for(let r of t)r in n&&delete n[r];return n}function gc(e){return p.version.split(".")[0]>="19"?e.props.ref:e.ref}function tt(e){return e===p.Fragment||e===Symbol.for("react.fragment")}function vc(e){return tt(e.type)}let bc="button";function xc(e,t){var n;let r=un(),{disabled:o=r||!1,autoFocus:l=!1,...i}=e,{isFocusVisible:a,focusProps:s}=xr({autoFocus:l}),{isHovered:u,hoverProps:c}=br({isDisabled:o}),{pressed:d,pressProps:m}=wr({disabled:o}),f=yt({ref:t,type:(n=i.type)!=null?n:"button",disabled:o||void 0,autoFocus:l},s,c,m),h=be({disabled:o,hover:u,focus:a,active:d,autofocus:l});return te()({ourProps:f,theirProps:i,slot:h,defaultTag:bc,name:"Button"})}let wc=Q(xc);function yc(e,t,n){let[r,o]=p.useState(n),l=e!==void 0,i=p.useRef(l),a=p.useRef(!1),s=p.useRef(!1);return l&&!i.current&&!a.current?(a.current=!0,i.current=l,console.error("A component is changing from uncontrolled to controlled. This may be caused by the value changing from undefined to a defined value, which should not happen.")):!l&&i.current&&!s.current&&(s.current=!0,i.current=l,console.error("A component is changing from controlled to uncontrolled. This may be caused by the value changing from a defined value to undefined, which should not happen.")),[l?e:r,D(u=>(l||Ge.flushSync(()=>o(u)),t?.(u)))]}function Ec(e){let[t]=p.useState(e);return t}function Dl(e={},t=null,n=[]){for(let[r,o]of Object.entries(e))Bl(n,_l(t,r),o);return n}function _l(e,t){return e?e+"["+t+"]":t}function Bl(e,t,n){if(Array.isArray(n))for(let[r,o]of n.entries())Bl(e,_l(t,r.toString()),o);else n instanceof Date?e.push([t,n.toISOString()]):typeof n=="boolean"?e.push([t,n?"1":"0"]):typeof n=="string"?e.push([t,n]):typeof n=="number"?e.push([t,`${n}`]):n==null?e.push([t,""]):Sc(n)&&!p.isValidElement(n)&&Dl(n,t,e)}function Cc(e){var t,n;let r=(t=e?.form)!=null?t:e.closest("form");if(r){for(let o of r.elements)if(o!==e&&(o.tagName==="INPUT"&&o.type==="submit"||o.tagName==="BUTTON"&&o.type==="submit"||o.nodeName==="INPUT"&&o.type==="image")){o.click();return}(n=r.requestSubmit)==null||n.call(r)}}function Sc(e){if(Object.prototype.toString.call(e)!=="[object Object]")return!1;let t=Object.getPrototypeOf(e);return t===null||Object.getPrototypeOf(t)===null}let $c="span";var yr=(e=>(e[e.None=1]="None",e[e.Focusable=2]="Focusable",e[e.Hidden=4]="Hidden",e))(yr||{});function kc(e,t){var n;let{features:r=1,...o}=e,l={ref:t,"aria-hidden":(r&2)===2?!0:(n=o["aria-hidden"])!=null?n:void 0,hidden:(r&4)===4?!0:void 0,style:{position:"fixed",top:1,left:1,width:1,height:0,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0",...(r&4)===4&&(r&2)!==2&&{display:"none"}}};return te()({ourProps:l,theirProps:o,slot:{},defaultTag:$c,name:"Hidden"})}let Hl=Q(kc),Rc=p.createContext(null);function Oc({children:e}){let t=p.useContext(Rc);if(!t)return p.createElement(p.Fragment,null,e);let{target:n}=t;return n?Ge.createPortal(p.createElement(p.Fragment,null,e),n):null}function Tc({data:e,form:t,disabled:n,onReset:r,overrides:o}){let[l,i]=p.useState(null),a=Xe();return p.useEffect(()=>{if(r&&l)return a.addEventListener(l,"reset",r)},[l,t,r]),p.createElement(Oc,null,p.createElement(Pc,{setForm:i,formId:t}),Dl(e).map(([s,u])=>p.createElement(Hl,{features:yr.Hidden,...je({key:s,as:"input",type:"hidden",hidden:!0,readOnly:!0,form:t,disabled:n,name:s,value:u,...o})})))}function Pc({setForm:e,formId:t}){return p.useEffect(()=>{if(t){let n=document.getElementById(t);n&&e(n)}},[e,t]),t?null:p.createElement(Hl,{features:yr.Hidden,as:"input",type:"hidden",hidden:!0,readOnly:!0,ref:n=>{if(!n)return;let r=n.closest("form");r&&e(r)}})}let Lc=p.createContext(void 0);function Vl(){return p.useContext(Lc)}function zl(e){return typeof e!="object"||e===null?!1:"nodeType"in e}function cn(e){return zl(e)&&"tagName"in e}function Ne(e){return cn(e)&&"accessKey"in e}function _e(e){return cn(e)&&"tabIndex"in e}function Ac(e){return cn(e)&&"style"in e}function Fc(e){return Ne(e)&&e.nodeName==="IFRAME"}function Wl(e){return Ne(e)&&e.nodeName==="INPUT"}function to(e){return Ne(e)&&e.nodeName==="LABEL"}function Mc(e){return Ne(e)&&e.nodeName==="FIELDSET"}function Ul(e){return Ne(e)&&e.nodeName==="LEGEND"}function Nc(e){return cn(e)?e.matches('a[href],audio[controls],button,details,embed,iframe,img[usemap],input:not([type="hidden"]),label,select,textarea,video[controls]'):!1}function Xn(e){let t=e.parentElement,n=null;for(;t&&!Mc(t);)Ul(t)&&(n=t),t=t.parentElement;let r=t?.getAttribute("disabled")==="";return r&&Ic(n)?!1:r}function Ic(e){if(!e)return!1;let t=e.previousElementSibling;for(;t!==null;){if(Ul(t))return!1;t=t.previousElementSibling}return!0}let ql=Symbol();function Gl(e,t=!0){return Object.assign(e,{[ql]:t})}function ue(...e){let t=p.useRef(e);p.useEffect(()=>{t.current=e},[e]);let n=D(r=>{for(let o of t.current)o!=null&&(typeof o=="function"?o(r):o.current=r)});return e.every(r=>r==null||r?.[ql])?void 0:n}let Er=p.createContext(null);Er.displayName="DescriptionContext";function Kl(){let e=p.useContext(Er);if(e===null){let t=new Error("You used a <Description /> component, but it is not inside a relevant parent.");throw Error.captureStackTrace&&Error.captureStackTrace(t,Kl),t}return e}function jc(){var e,t;return(t=(e=p.useContext(Er))==null?void 0:e.value)!=null?t:void 0}let Dc="p";function _c(e,t){let n=p.useId(),r=un(),{id:o=`headlessui-description-${n}`,...l}=e,i=Kl(),a=ue(t);X(()=>i.register(o),[o,i.register]);let s=be({...i.slot,disabled:r||!1}),u={ref:a,...i.props,id:o};return te()({ourProps:u,theirProps:l,slot:s,defaultTag:Dc,name:i.name||"Description"})}let Bc=Q(_c);Object.assign(Bc,{});var Y=(e=>(e.Space=" ",e.Enter="Enter",e.Escape="Escape",e.Backspace="Backspace",e.Delete="Delete",e.ArrowLeft="ArrowLeft",e.ArrowUp="ArrowUp",e.ArrowRight="ArrowRight",e.ArrowDown="ArrowDown",e.Home="Home",e.End="End",e.PageUp="PageUp",e.PageDown="PageDown",e.Tab="Tab",e))(Y||{});let dn=p.createContext(null);dn.displayName="LabelContext";function Yl(){let e=p.useContext(dn);if(e===null){let t=new Error("You used a <Label /> component, but it is not inside a relevant parent.");throw Error.captureStackTrace&&Error.captureStackTrace(t,Yl),t}return e}function Zl(e){var t,n,r;let o=(n=(t=p.useContext(dn))==null?void 0:t.value)!=null?n:void 0;return((r=e?.length)!=null?r:0)>0?[o,...e].filter(Boolean).join(" "):o}function Hc({inherit:e=!1}={}){let t=Zl(),[n,r]=p.useState([]),o=e?[t,...n].filter(Boolean):n;return[o.length>0?o.join(" "):void 0,p.useMemo(()=>function(l){let i=D(s=>(r(u=>[...u,s]),()=>r(u=>{let c=u.slice(),d=c.indexOf(s);return d!==-1&&c.splice(d,1),c}))),a=p.useMemo(()=>({register:i,slot:l.slot,name:l.name,props:l.props,value:l.value}),[i,l.slot,l.name,l.props,l.value]);return p.createElement(dn.Provider,{value:a},l.children)},[r])]}let Vc="label";function zc(e,t){var n;let r=p.useId(),o=Yl(),l=Vl(),i=un(),{id:a=`headlessui-label-${r}`,htmlFor:s=l??((n=o.props)==null?void 0:n.htmlFor),passive:u=!1,...c}=e,d=ue(t);X(()=>o.register(a),[a,o.register]);let m=D(v=>{let b=v.currentTarget;if(!(v.target!==v.currentTarget&&Nc(v.target))&&(to(b)&&v.preventDefault(),o.props&&"onClick"in o.props&&typeof o.props.onClick=="function"&&o.props.onClick(v),to(b))){let x=document.getElementById(b.htmlFor);if(x){let y=x.getAttribute("disabled");if(y==="true"||y==="")return;let w=x.getAttribute("aria-disabled");if(w==="true"||w==="")return;(Wl(x)&&(x.type==="file"||x.type==="radio"||x.type==="checkbox")||x.role==="radio"||x.role==="checkbox"||x.role==="switch")&&x.click(),x.focus({preventScroll:!0})}}}),f=be({...o.slot,disabled:i||!1}),h={ref:d,...o.props,id:a,htmlFor:s,onClick:m};return u&&("onClick"in h&&(delete h.htmlFor,delete h.onClick),"onClick"in c&&delete c.onClick),te()({ourProps:h,theirProps:c,slot:f,defaultTag:s?Vc:"div",name:o.name||"Label"})}let Wc=Q(zc),Uc=Object.assign(Wc,{}),qc=p.createContext(()=>{});function Gc({value:e,children:t}){return p.createElement(qc.Provider,{value:e},t)}function Kc(e,t){return e!==null&&t!==null&&typeof e=="object"&&typeof t=="object"&&"id"in e&&"id"in t?e.id===t.id:e===t}function Yc(e=Kc){return p.useCallback((t,n)=>{if(typeof e=="string"){let r=e;return t?.[r]===n?.[r]}return e(t,n)},[e])}function no(e){if(e===null)return{width:0,height:0};let{width:t,height:n}=e.getBoundingClientRect();return{width:t,height:n}}function Zc(e,t,n=!1){let[r,o]=p.useState(()=>no(t));return X(()=>{if(!t||!e)return;let l=fe();return l.requestAnimationFrame(function i(){l.requestAnimationFrame(i),o(a=>{let s=no(t);return s.width===a.width&&s.height===a.height?a:s})}),()=>{l.dispose()}},[t,e]),n?{width:`${r.width}px`,height:`${r.height}px`}:r}var Xl=(e=>(e[e.Left=0]="Left",e[e.Right=2]="Right",e))(Xl||{});function Xc(e){let t=p.useRef(null),n=D(o=>{t.current=o.pointerType,!Xn(o.currentTarget)&&o.pointerType==="mouse"&&o.button===Xl.Left&&(o.preventDefault(),e(o))}),r=D(o=>{t.current!=="mouse"&&(Xn(o.currentTarget)||e(o))});return{onPointerDown:n,onClick:r}}let Jl=class extends Map{constructor(t){super(),this.factory=t}get(t){let n=super.get(t);return n===void 0&&(n=this.factory(t),this.set(t,n)),n}};var Jc=Object.defineProperty,Qc=(e,t,n)=>t in e?Jc(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ed=(e,t,n)=>(Qc(e,t+"",n),n),Ql=(e,t,n)=>{if(!t.has(e))throw TypeError("Cannot "+n)},ge=(e,t,n)=>(Ql(e,t,"read from private field"),n?n.call(e):t.get(e)),An=(e,t,n)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,n)},ro=(e,t,n,r)=>(Ql(e,t,"write to private field"),t.set(e,n),n),Ce,ht,gt;let ei=class{constructor(t){An(this,Ce,{}),An(this,ht,new Jl(()=>new Set)),An(this,gt,new Set),ed(this,"disposables",fe()),ro(this,Ce,t),Se.isServer&&this.disposables.microTask(()=>{this.dispose()})}dispose(){this.disposables.dispose()}get state(){return ge(this,Ce)}subscribe(t,n){if(Se.isServer)return()=>{};let r={selector:t,callback:n,current:t(ge(this,Ce))};return ge(this,gt).add(r),this.disposables.add(()=>{ge(this,gt).delete(r)})}on(t,n){return Se.isServer?()=>{}:(ge(this,ht).get(t).add(n),this.disposables.add(()=>{ge(this,ht).get(t).delete(n)}))}send(t){let n=this.reduce(ge(this,Ce),t);if(n!==ge(this,Ce)){ro(this,Ce,n);for(let r of ge(this,gt)){let o=r.selector(ge(this,Ce));ti(r.current,o)||(r.current=o,r.callback(o))}for(let r of ge(this,ht).get(t.type))r(ge(this,Ce),t)}}};Ce=new WeakMap,ht=new WeakMap,gt=new WeakMap;function ti(e,t){return Object.is(e,t)?!0:typeof e!="object"||e===null||typeof t!="object"||t===null?!1:Array.isArray(e)&&Array.isArray(t)?e.length!==t.length?!1:Fn(e[Symbol.iterator](),t[Symbol.iterator]()):e instanceof Map&&t instanceof Map||e instanceof Set&&t instanceof Set?e.size!==t.size?!1:Fn(e.entries(),t.entries()):oo(e)&&oo(t)?Fn(Object.entries(e)[Symbol.iterator](),Object.entries(t)[Symbol.iterator]()):!1}function Fn(e,t){do{let n=e.next(),r=t.next();if(n.done&&r.done)return!0;if(n.done||r.done||!Object.is(n.value,r.value))return!1}while(!0)}function oo(e){if(Object.prototype.toString.call(e)!=="[object Object]")return!1;let t=Object.getPrototypeOf(e);return t===null||Object.getPrototypeOf(t)===null}function Mn(e){let[t,n]=e(),r=fe();return(...o)=>{t(...o),r.dispose(),r.microTask(n)}}var td=Object.defineProperty,nd=(e,t,n)=>t in e?td(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,lo=(e,t,n)=>(nd(e,typeof t!="symbol"?t+"":t,n),n),ni=(e=>(e[e.Push=0]="Push",e[e.Pop=1]="Pop",e))(ni||{});let rd={0(e,t){let n=t.id,r=e.stack,o=e.stack.indexOf(n);if(o!==-1){let l=e.stack.slice();return l.splice(o,1),l.push(n),r=l,{...e,stack:r}}return{...e,stack:[...e.stack,n]}},1(e,t){let n=t.id,r=e.stack.indexOf(n);if(r===-1)return e;let o=e.stack.slice();return o.splice(r,1),{...e,stack:o}}},od=class ri extends ei{constructor(){super(...arguments),lo(this,"actions",{push:t=>this.send({type:0,id:t}),pop:t=>this.send({type:1,id:t})}),lo(this,"selectors",{isTop:(t,n)=>t.stack[t.stack.length-1]===n,inStack:(t,n)=>t.stack.includes(n)})}static new(){return new ri({stack:[]})}reduce(t,n){return se(n.type,rd,t,n)}};const Cr=new Jl(()=>od.new());var Ht={exports:{}},Nn={};var io;function ld(){if(io)return Nn;io=1;var e=p;function t(s,u){return s===u&&(s!==0||1/s===1/u)||s!==s&&u!==u}var n=typeof Object.is=="function"?Object.is:t,r=e.useSyncExternalStore,o=e.useRef,l=e.useEffect,i=e.useMemo,a=e.useDebugValue;return Nn.useSyncExternalStoreWithSelector=function(s,u,c,d,m){var f=o(null);if(f.current===null){var h={hasValue:!1,value:null};f.current=h}else h=f.current;f=i(function(){function b(C){if(!x){if(x=!0,y=C,C=d(C),m!==void 0&&h.hasValue){var T=h.value;if(m(T,C))return w=T}return w=C}if(T=w,n(y,C))return T;var O=d(C);return m!==void 0&&m(T,O)?(y=C,T):(y=C,w=O)}var x=!1,y,w,S=c===void 0?null:c;return[function(){return b(u())},S===null?void 0:function(){return b(S())}]},[u,c,d,m]);var v=r(s,f[0],f[1]);return l(function(){h.hasValue=!0,h.value=v},[v]),a(v),v},Nn}var In={};var ao;function id(){return ao||(ao=1,process.env.NODE_ENV!=="production"&&(function(){function e(s,u){return s===u&&(s!==0||1/s===1/u)||s!==s&&u!==u}typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var t=p,n=typeof Object.is=="function"?Object.is:e,r=t.useSyncExternalStore,o=t.useRef,l=t.useEffect,i=t.useMemo,a=t.useDebugValue;In.useSyncExternalStoreWithSelector=function(s,u,c,d,m){var f=o(null);if(f.current===null){var h={hasValue:!1,value:null};f.current=h}else h=f.current;f=i(function(){function b(C){if(!x){if(x=!0,y=C,C=d(C),m!==void 0&&h.hasValue){var T=h.value;if(m(T,C))return w=T}return w=C}if(T=w,n(y,C))return T;var O=d(C);return m!==void 0&&m(T,O)?(y=C,T):(y=C,w=O)}var x=!1,y,w,S=c===void 0?null:c;return[function(){return b(u())},S===null?void 0:function(){return b(S())}]},[u,c,d,m]);var v=r(s,f[0],f[1]);return l(function(){h.hasValue=!0,h.value=v},[v]),a(v),v},typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())})()),In}var so;function ad(){return so||(so=1,process.env.NODE_ENV==="production"?Ht.exports=ld():Ht.exports=id()),Ht.exports}var sd=ad();function ce(e,t,n=ti){return sd.useSyncExternalStoreWithSelector(D(r=>e.subscribe(ud,r)),D(()=>e.state),D(()=>e.state),D(t),n)}function ud(e){return e}function oi(e,t){let n=p.useId(),r=Cr.get(t),[o,l]=ce(r,p.useCallback(i=>[r.selectors.isTop(i,n),r.selectors.inStack(i,n)],[r,n]));return X(()=>{if(e)return r.actions.push(n),()=>r.actions.pop(n)},[r,e,n]),e?l?o:!0:!1}let Jn=new Map,bt=new Map;function uo(e){var t;let n=(t=bt.get(e))!=null?t:0;return bt.set(e,n+1),n!==0?()=>co(e):(Jn.set(e,{"aria-hidden":e.getAttribute("aria-hidden"),inert:e.inert}),e.setAttribute("aria-hidden","true"),e.inert=!0,()=>co(e))}function co(e){var t;let n=(t=bt.get(e))!=null?t:1;if(n===1?bt.delete(e):bt.set(e,n-1),n!==1)return;let r=Jn.get(e);r&&(r["aria-hidden"]===null?e.removeAttribute("aria-hidden"):e.setAttribute("aria-hidden",r["aria-hidden"]),e.inert=r.inert,Jn.delete(e))}function cd(e,{allowed:t,disallowed:n}={}){let r=oi(e,"inert-others");X(()=>{var o,l;if(!r)return;let i=fe();for(let s of(o=n?.())!=null?o:[])s&&i.add(uo(s));let a=(l=t?.())!=null?l:[];for(let s of a){if(!s)continue;let u=Tt(s);if(!u)continue;let c=s.parentElement;for(;c&&c!==u.body;){for(let d of c.children)a.some(m=>d.contains(m))||i.add(uo(d));c=c.parentElement}}return i.dispose},[r,t,n])}function dd(e,t,n){let r=Je(o=>{let l=o.getBoundingClientRect();l.x===0&&l.y===0&&l.width===0&&l.height===0&&n()});p.useEffect(()=>{if(!e)return;let o=t===null?null:Ne(t)?t:t.current;if(!o)return;let l=fe();if(typeof ResizeObserver<"u"){let i=new ResizeObserver(()=>r.current(o));i.observe(o),l.add(()=>i.disconnect())}if(typeof IntersectionObserver<"u"){let i=new IntersectionObserver(()=>r.current(o));i.observe(o),l.add(()=>i.disconnect())}return()=>l.dispose()},[t,r,e])}let Qn=["[contentEditable=true]","[tabindex]","a[href]","area[href]","button:not([disabled])","iframe","input:not([disabled])","select:not([disabled])","details>summary","textarea:not([disabled])"].map(e=>`${e}:not([tabindex='-1'])`).join(","),fd=["[data-autofocus]"].map(e=>`${e}:not([tabindex='-1'])`).join(",");var er=(e=>(e[e.First=1]="First",e[e.Previous=2]="Previous",e[e.Next=4]="Next",e[e.Last=8]="Last",e[e.WrapAround=16]="WrapAround",e[e.NoScroll=32]="NoScroll",e[e.AutoFocus=64]="AutoFocus",e))(er||{}),pd=(e=>(e[e.Error=0]="Error",e[e.Overflow=1]="Overflow",e[e.Success=2]="Success",e[e.Underflow=3]="Underflow",e))(pd||{}),md=(e=>(e[e.Previous=-1]="Previous",e[e.Next=1]="Next",e))(md||{});function li(e=document.body){return e==null?[]:Array.from(e.querySelectorAll(Qn)).sort((t,n)=>Math.sign((t.tabIndex||Number.MAX_SAFE_INTEGER)-(n.tabIndex||Number.MAX_SAFE_INTEGER)))}function hd(e=document.body){return e==null?[]:Array.from(e.querySelectorAll(fd)).sort((t,n)=>Math.sign((t.tabIndex||Number.MAX_SAFE_INTEGER)-(n.tabIndex||Number.MAX_SAFE_INTEGER)))}var Sr=(e=>(e[e.Strict=0]="Strict",e[e.Loose=1]="Loose",e))(Sr||{});function ii(e,t=0){var n;return e===((n=Tt(e))==null?void 0:n.body)?!1:se(t,{0(){return e.matches(Qn)},1(){let r=e;for(;r!==null;){if(r.matches(Qn))return!0;r=r.parentElement}return!1}})}var gd=(e=>(e[e.Keyboard=0]="Keyboard",e[e.Mouse=1]="Mouse",e))(gd||{});typeof window<"u"&&typeof document<"u"&&(document.addEventListener("keydown",e=>{e.metaKey||e.altKey||e.ctrlKey||(document.documentElement.dataset.headlessuiFocusVisible="")},!0),document.addEventListener("click",e=>{e.detail===1?delete document.documentElement.dataset.headlessuiFocusVisible:e.detail===0&&(document.documentElement.dataset.headlessuiFocusVisible="")},!0));let vd=["textarea","input"].join(",");function bd(e){var t,n;return(n=(t=e?.matches)==null?void 0:t.call(e,vd))!=null?n:!1}function ai(e,t=n=>n){return e.slice().sort((n,r)=>{let o=t(n),l=t(r);if(o===null||l===null)return 0;let i=o.compareDocumentPosition(l);return i&Node.DOCUMENT_POSITION_FOLLOWING?-1:i&Node.DOCUMENT_POSITION_PRECEDING?1:0})}function xd(e,t,n=e===null?document.body:en(e)){return wd(li(n),t,{relativeTo:e})}function wd(e,t,{sorted:n=!0,relativeTo:r=null,skipElements:o=[]}={}){let l=Array.isArray(e)?e.length>0?en(e[0]):document:en(e),i=Array.isArray(e)?n?ai(e):e:t&64?hd(e):li(e);o.length>0&&i.length>1&&(i=i.filter(f=>!o.some(h=>h!=null&&"current"in h?h?.current===f:h===f))),r=r??l?.activeElement;let a=(()=>{if(t&5)return 1;if(t&10)return-1;throw new Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),s=(()=>{if(t&1)return 0;if(t&2)return Math.max(0,i.indexOf(r))-1;if(t&4)return Math.max(0,i.indexOf(r))+1;if(t&8)return i.length-1;throw new Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),u=t&32?{preventScroll:!0}:{},c=0,d=i.length,m;do{if(c>=d||c+d<=0)return 0;let f=s+c;if(t&16)f=(f+d)%d;else{if(f<0)return 3;if(f>=d)return 1}m=i[f],m?.focus(u),c+=a}while(m!==Nl(m));return t&6&&bd(m)&&m.select(),2}function si(){return/iPhone/gi.test(window.navigator.platform)||/Mac/gi.test(window.navigator.platform)&&window.navigator.maxTouchPoints>0}function yd(){return/Android/gi.test(window.navigator.userAgent)}function fo(){return si()||yd()}function et(e,t,n,r){let o=Je(n);p.useEffect(()=>{if(!e)return;function l(i){o.current(i)}return document.addEventListener(t,l,r),()=>document.removeEventListener(t,l,r)},[e,t,r])}function Ed(e,t,n,r){let o=Je(n);p.useEffect(()=>{if(!e)return;function l(i){o.current(i)}return window.addEventListener(t,l,r),()=>window.removeEventListener(t,l,r)},[e,t,r])}const po=30;function Cd(e,t,n){let r=Je(n),o=p.useCallback(function(a,s){if(a.defaultPrevented)return;let u=s(a);if(u===null||!u.getRootNode().contains(u)||!u.isConnected)return;let c=(function d(m){return typeof m=="function"?d(m()):Array.isArray(m)||m instanceof Set?m:[m]})(t);for(let d of c)if(d!==null&&(d.contains(u)||a.composed&&a.composedPath().includes(d)))return;return!ii(u,Sr.Loose)&&u.tabIndex!==-1&&a.preventDefault(),r.current(a,u)},[r,t]),l=p.useRef(null);et(e,"pointerdown",a=>{var s,u;fo()||(l.current=((u=(s=a.composedPath)==null?void 0:s.call(a))==null?void 0:u[0])||a.target)},!0),et(e,"pointerup",a=>{if(fo()||!l.current)return;let s=l.current;return l.current=null,o(a,()=>s)},!0);let i=p.useRef({x:0,y:0});et(e,"touchstart",a=>{i.current.x=a.touches[0].clientX,i.current.y=a.touches[0].clientY},!0),et(e,"touchend",a=>{let s={x:a.changedTouches[0].clientX,y:a.changedTouches[0].clientY};if(!(Math.abs(s.x-i.current.x)>=po||Math.abs(s.y-i.current.y)>=po))return o(a,()=>_e(a.target)?a.target:null)},!0),Ed(e,"blur",a=>o(a,()=>Fc(window.document.activeElement)?window.document.activeElement:null),!0)}function tr(...e){return p.useMemo(()=>Tt(...e),[...e])}var Sd=(e=>(e[e.Ignore=0]="Ignore",e[e.Select=1]="Select",e[e.Close=2]="Close",e))(Sd||{});const Vt={Ignore:{kind:0},Select:e=>({kind:1,target:e}),Close:{kind:2}},$d=200,mo=5;function kd(e,{trigger:t,action:n,close:r,select:o}){let l=p.useRef(null),i=p.useRef(null),a=p.useRef(null);et(e&&t!==null,"pointerdown",s=>{zl(s?.target)&&t!=null&&t.contains(s.target)&&(i.current=s.x,a.current=s.y,l.current=s.timeStamp)}),et(e&&t!==null,"pointerup",s=>{var u,c;let d=l.current;if(d===null||(l.current=null,!_e(s.target))||Math.abs(s.x-((u=i.current)!=null?u:s.x))<mo&&Math.abs(s.y-((c=a.current)!=null?c:s.y))<mo)return;let m=n(s);switch(m.kind){case 0:return;case 1:{s.timeStamp-d>$d&&(o(m.target),r());break}case 2:{r();break}}},{capture:!0})}function ui(e,t){return p.useMemo(()=>{var n;if(e.type)return e.type;let r=(n=e.as)!=null?n:"button";if(typeof r=="string"&&r.toLowerCase()==="button"||t?.tagName==="BUTTON"&&!t.hasAttribute("type"))return"button"},[e.type,e.as,t])}function Rd(e){return p.useSyncExternalStore(e.subscribe,e.getSnapshot,e.getSnapshot)}function Od(e,t){let n=e(),r=new Set;return{getSnapshot(){return n},subscribe(o){return r.add(o),()=>r.delete(o)},dispatch(o,...l){let i=t[o].call(n,...l);i&&(n=i,r.forEach(a=>a()))}}}function Td(){let e;return{before({doc:t}){var n;let r=t.documentElement,o=(n=t.defaultView)!=null?n:window;e=Math.max(0,o.innerWidth-r.clientWidth)},after({doc:t,d:n}){let r=t.documentElement,o=Math.max(0,r.clientWidth-r.offsetWidth),l=Math.max(0,e-o);n.style(r,"paddingRight",`${l}px`)}}}function Pd(){return si()?{before({doc:e,d:t,meta:n}){function r(o){for(let l of n().containers)for(let i of l())if(i.contains(o))return!0;return!1}t.microTask(()=>{var o;if(window.getComputedStyle(e.documentElement).scrollBehavior!=="auto"){let a=fe();a.style(e.documentElement,"scrollBehavior","auto"),t.add(()=>t.microTask(()=>a.dispose()))}let l=(o=window.scrollY)!=null?o:window.pageYOffset,i=null;t.addEventListener(e,"click",a=>{if(_e(a.target))try{let s=a.target.closest("a");if(!s)return;let{hash:u}=new URL(s.href),c=e.querySelector(u);_e(c)&&!r(c)&&(i=c)}catch{}},!0),t.group(a=>{t.addEventListener(e,"touchstart",s=>{if(a.dispose(),_e(s.target)&&Ac(s.target))if(r(s.target)){let u=s.target;for(;u.parentElement&&r(u.parentElement);)u=u.parentElement;a.style(u,"overscrollBehavior","contain")}else a.style(s.target,"touchAction","none")})}),t.addEventListener(e,"touchmove",a=>{if(_e(a.target)){if(Wl(a.target))return;if(r(a.target)){let s=a.target;for(;s.parentElement&&s.dataset.headlessuiPortal!==""&&!(s.scrollHeight>s.clientHeight||s.scrollWidth>s.clientWidth);)s=s.parentElement;s.dataset.headlessuiPortal===""&&a.preventDefault()}else a.preventDefault()}},{passive:!1}),t.add(()=>{var a;let s=(a=window.scrollY)!=null?a:window.pageYOffset;l!==s&&window.scrollTo(0,l),i&&i.isConnected&&(i.scrollIntoView({block:"nearest"}),i=null)})})}}:{}}function Ld(){return{before({doc:e,d:t}){t.style(e.documentElement,"overflow","hidden")}}}function ho(e){let t={};for(let n of e)Object.assign(t,n(t));return t}let qe=Od(()=>new Map,{PUSH(e,t){var n;let r=(n=this.get(e))!=null?n:{doc:e,count:0,d:fe(),meta:new Set,computedMeta:{}};return r.count++,r.meta.add(t),r.computedMeta=ho(r.meta),this.set(e,r),this},POP(e,t){let n=this.get(e);return n&&(n.count--,n.meta.delete(t),n.computedMeta=ho(n.meta)),this},SCROLL_PREVENT(e){let t={doc:e.doc,d:e.d,meta(){return e.computedMeta}},n=[Pd(),Td(),Ld()];n.forEach(({before:r})=>r?.(t)),n.forEach(({after:r})=>r?.(t))},SCROLL_ALLOW({d:e}){e.dispose()},TEARDOWN({doc:e}){this.delete(e)}});qe.subscribe(()=>{let e=qe.getSnapshot(),t=new Map;for(let[n]of e)t.set(n,n.documentElement.style.overflow);for(let n of e.values()){let r=t.get(n.doc)==="hidden",o=n.count!==0;(o&&!r||!o&&r)&&qe.dispatch(n.count>0?"SCROLL_PREVENT":"SCROLL_ALLOW",n),n.count===0&&qe.dispatch("TEARDOWN",n)}});function Ad(e,t,n=()=>({containers:[]})){let r=Rd(qe),o=t?r.get(t):void 0,l=o?o.count>0:!1;return X(()=>{if(!(!t||!e))return qe.dispatch("PUSH",t,n),()=>qe.dispatch("POP",t,n)},[e,t]),l}function Fd(e,t,n=()=>[document.body]){let r=oi(e,"scroll-lock");Ad(r,t,o=>{var l;return{containers:[...(l=o.containers)!=null?l:[],n]}})}function go(e){return[e.screenX,e.screenY]}function Md(){let e=p.useRef([-1,-1]);return{wasMoved(t){let n=go(t);return e.current[0]===n[0]&&e.current[1]===n[1]?!1:(e.current=n,!0)},update(t){e.current=go(t)}}}function Nd(e=0){let[t,n]=p.useState(e),r=p.useCallback(s=>n(s),[]),o=p.useCallback(s=>n(u=>u|s),[]),l=p.useCallback(s=>(t&s)===s,[t]),i=p.useCallback(s=>n(u=>u&~s),[]),a=p.useCallback(s=>n(u=>u^s),[]);return{flags:t,setFlag:r,addFlag:o,hasFlag:l,removeFlag:i,toggleFlag:a}}var vo,bo;typeof process<"u"&&typeof globalThis<"u"&&typeof Element<"u"&&((vo=process==null?void 0:process.env)==null?void 0:vo.NODE_ENV)==="test"&&typeof((bo=Element?.prototype)==null?void 0:bo.getAnimations)>"u"&&(Element.prototype.getAnimations=function(){return console.warn(["Headless UI has polyfilled `Element.prototype.getAnimations` for your tests.","Please install a proper polyfill e.g. `jsdom-testing-mocks`, to silence these warnings.","","Example usage:","```js","import { mockAnimationsApi } from 'jsdom-testing-mocks'","mockAnimationsApi()","```"].join(`
|
|
7
|
-
`)),[]});var Id=(e=>(e[e.None=0]="None",e[e.Closed=1]="Closed",e[e.Enter=2]="Enter",e[e.Leave=4]="Leave",e))(Id||{});function $r(e){let t={};for(let n in e)e[n]===!0&&(t[`data-${n}`]="");return t}function kr(e,t,n,r){let[o,l]=p.useState(n),{hasFlag:i,addFlag:a,removeFlag:s}=Nd(e&&o?3:0),u=p.useRef(!1),c=p.useRef(!1),d=Xe();return X(()=>{var m;if(e){if(n&&l(!0),!t){n&&a(3);return}return(m=r?.start)==null||m.call(r,n),jd(t,{inFlight:u,prepare(){c.current?c.current=!1:c.current=u.current,u.current=!0,!c.current&&(n?(a(3),s(4)):(a(4),s(2)))},run(){c.current?n?(s(3),a(4)):(s(4),a(3)):n?s(1):a(1)},done(){var f;c.current&&Bd(t)||(u.current=!1,s(7),n||l(!1),(f=r?.end)==null||f.call(r,n))}})}},[e,n,t,d]),e?[o,{closed:i(1),enter:i(2),leave:i(4),transition:i(2)||i(4)}]:[n,{closed:void 0,enter:void 0,leave:void 0,transition:void 0}]}function jd(e,{prepare:t,run:n,done:r,inFlight:o}){let l=fe();return _d(e,{prepare:t,inFlight:o}),l.nextFrame(()=>{n(),l.requestAnimationFrame(()=>{l.add(Dd(e,r))})}),l.dispose}function Dd(e,t){var n,r;let o=fe();if(!e)return o.dispose;let l=!1;o.add(()=>{l=!0});let i=(r=(n=e.getAnimations)==null?void 0:n.call(e).filter(a=>a instanceof CSSTransition))!=null?r:[];return i.length===0?(t(),o.dispose):(Promise.allSettled(i.map(a=>a.finished)).then(()=>{l||t()}),o.dispose)}function _d(e,{inFlight:t,prepare:n}){if(t!=null&&t.current){n();return}let r=e.style.transition;e.style.transition="none",n(),e.offsetHeight,e.style.transition=r}function Bd(e){var t,n;return((n=(t=e.getAnimations)==null?void 0:t.call(e))!=null?n:[]).some(r=>r instanceof CSSTransition&&r.playState!=="finished")}function fn(){return typeof window<"u"}function ct(e){return ci(e)?(e.nodeName||"").toLowerCase():"#document"}function de(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Re(e){var t;return(t=(ci(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function ci(e){return fn()?e instanceof Node||e instanceof de(e).Node:!1}function oe(e){return fn()?e instanceof Element||e instanceof de(e).Element:!1}function ke(e){return fn()?e instanceof HTMLElement||e instanceof de(e).HTMLElement:!1}function xo(e){return!fn()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof de(e).ShadowRoot}const Hd=new Set(["inline","contents"]);function Pt(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=ye(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!Hd.has(o)}const Vd=new Set(["table","td","th"]);function zd(e){return Vd.has(ct(e))}const Wd=[":popover-open",":modal"];function pn(e){return Wd.some(t=>{try{return e.matches(t)}catch{return!1}})}const Ud=["transform","translate","scale","rotate","perspective"],qd=["transform","translate","scale","rotate","perspective","filter"],Gd=["paint","layout","strict","content"];function Rr(e){const t=Or(),n=oe(e)?ye(e):e;return Ud.some(r=>n[r]?n[r]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||qd.some(r=>(n.willChange||"").includes(r))||Gd.some(r=>(n.contain||"").includes(r))}function Kd(e){let t=He(e);for(;ke(t)&&!ot(t);){if(Rr(t))return t;if(pn(t))return null;t=He(t)}return null}function Or(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const Yd=new Set(["html","body","#document"]);function ot(e){return Yd.has(ct(e))}function ye(e){return de(e).getComputedStyle(e)}function mn(e){return oe(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function He(e){if(ct(e)==="html")return e;const t=e.assignedSlot||e.parentNode||xo(e)&&e.host||Re(e);return xo(t)?t.host:t}function di(e){const t=He(e);return ot(t)?e.ownerDocument?e.ownerDocument.body:e.body:ke(t)&&Pt(t)?t:di(t)}function Et(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=di(e),l=o===((r=e.ownerDocument)==null?void 0:r.body),i=de(o);if(l){const a=nr(i);return t.concat(i,i.visualViewport||[],Pt(o)?o:[],a&&n?Et(a):[])}return t.concat(o,Et(o,[],n))}function nr(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Zd(){const e=navigator.userAgentData;return e&&Array.isArray(e.brands)?e.brands.map(t=>{let{brand:n,version:r}=t;return n+"/"+r}).join(" "):navigator.userAgent}const Ye=Math.min,ne=Math.max,Ct=Math.round,zt=Math.floor,$e=e=>({x:e,y:e}),Xd={left:"right",right:"left",bottom:"top",top:"bottom"},Jd={start:"end",end:"start"};function wo(e,t,n){return ne(e,Ye(t,n))}function dt(e,t){return typeof e=="function"?e(t):e}function Ve(e){return e.split("-")[0]}function Lt(e){return e.split("-")[1]}function fi(e){return e==="x"?"y":"x"}function pi(e){return e==="y"?"height":"width"}const Qd=new Set(["top","bottom"]);function Te(e){return Qd.has(Ve(e))?"y":"x"}function mi(e){return fi(Te(e))}function ef(e,t,n){n===void 0&&(n=!1);const r=Lt(e),o=mi(e),l=pi(o);let i=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[l]>t.floating[l]&&(i=tn(i)),[i,tn(i)]}function tf(e){const t=tn(e);return[rr(e),t,rr(t)]}function rr(e){return e.replace(/start|end/g,t=>Jd[t])}const yo=["left","right"],Eo=["right","left"],nf=["top","bottom"],rf=["bottom","top"];function of(e,t,n){switch(e){case"top":case"bottom":return n?t?Eo:yo:t?yo:Eo;case"left":case"right":return t?nf:rf;default:return[]}}function lf(e,t,n,r){const o=Lt(e);let l=of(Ve(e),n==="start",r);return o&&(l=l.map(i=>i+"-"+o),t&&(l=l.concat(l.map(rr)))),l}function tn(e){return e.replace(/left|right|bottom|top/g,t=>Xd[t])}function af(e){return{top:0,right:0,bottom:0,left:0,...e}}function sf(e){return typeof e!="number"?af(e):{top:e,right:e,bottom:e,left:e}}function nn(e){const{x:t,y:n,width:r,height:o}=e;return{width:r,height:o,top:n,left:t,right:t+r,bottom:n+o,x:t,y:n}}function Co(e,t,n){let{reference:r,floating:o}=e;const l=Te(t),i=mi(t),a=pi(i),s=Ve(t),u=l==="y",c=r.x+r.width/2-o.width/2,d=r.y+r.height/2-o.height/2,m=r[a]/2-o[a]/2;let f;switch(s){case"top":f={x:c,y:r.y-o.height};break;case"bottom":f={x:c,y:r.y+r.height};break;case"right":f={x:r.x+r.width,y:d};break;case"left":f={x:r.x-o.width,y:d};break;default:f={x:r.x,y:r.y}}switch(Lt(t)){case"start":f[i]-=m*(n&&u?-1:1);break;case"end":f[i]+=m*(n&&u?-1:1);break}return f}const uf=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:l=[],platform:i}=n,a=l.filter(Boolean),s=await(i.isRTL==null?void 0:i.isRTL(t));let u=await i.getElementRects({reference:e,floating:t,strategy:o}),{x:c,y:d}=Co(u,r,s),m=r,f={},h=0;for(let v=0;v<a.length;v++){const{name:b,fn:x}=a[v],{x:y,y:w,data:S,reset:C}=await x({x:c,y:d,initialPlacement:r,placement:m,strategy:o,middlewareData:f,rects:u,platform:i,elements:{reference:e,floating:t}});c=y??c,d=w??d,f={...f,[b]:{...f[b],...S}},C&&h<=50&&(h++,typeof C=="object"&&(C.placement&&(m=C.placement),C.rects&&(u=C.rects===!0?await i.getElementRects({reference:e,floating:t,strategy:o}):C.rects),{x:c,y:d}=Co(u,m,s)),v=-1)}return{x:c,y:d,placement:m,strategy:o,middlewareData:f}};async function hn(e,t){var n;t===void 0&&(t={});const{x:r,y:o,platform:l,rects:i,elements:a,strategy:s}=e,{boundary:u="clippingAncestors",rootBoundary:c="viewport",elementContext:d="floating",altBoundary:m=!1,padding:f=0}=dt(t,e),h=sf(f),b=a[m?d==="floating"?"reference":"floating":d],x=nn(await l.getClippingRect({element:(n=await(l.isElement==null?void 0:l.isElement(b)))==null||n?b:b.contextElement||await(l.getDocumentElement==null?void 0:l.getDocumentElement(a.floating)),boundary:u,rootBoundary:c,strategy:s})),y=d==="floating"?{x:r,y:o,width:i.floating.width,height:i.floating.height}:i.reference,w=await(l.getOffsetParent==null?void 0:l.getOffsetParent(a.floating)),S=await(l.isElement==null?void 0:l.isElement(w))?await(l.getScale==null?void 0:l.getScale(w))||{x:1,y:1}:{x:1,y:1},C=nn(l.convertOffsetParentRelativeRectToViewportRelativeRect?await l.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:y,offsetParent:w,strategy:s}):y);return{top:(x.top-C.top+h.top)/S.y,bottom:(C.bottom-x.bottom+h.bottom)/S.y,left:(x.left-C.left+h.left)/S.x,right:(C.right-x.right+h.right)/S.x}}const cf=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:o,middlewareData:l,rects:i,initialPlacement:a,platform:s,elements:u}=t,{mainAxis:c=!0,crossAxis:d=!0,fallbackPlacements:m,fallbackStrategy:f="bestFit",fallbackAxisSideDirection:h="none",flipAlignment:v=!0,...b}=dt(e,t);if((n=l.arrow)!=null&&n.alignmentOffset)return{};const x=Ve(o),y=Te(a),w=Ve(a)===a,S=await(s.isRTL==null?void 0:s.isRTL(u.floating)),C=m||(w||!v?[tn(a)]:tf(a)),T=h!=="none";!m&&T&&C.push(...lf(a,v,h,S));const O=[a,...C],k=await hn(t,b),A=[];let R=((r=l.flip)==null?void 0:r.overflows)||[];if(c&&A.push(k[x]),d){const B=ef(o,i,S);A.push(k[B[0]],k[B[1]])}if(R=[...R,{placement:o,overflows:A}],!A.every(B=>B<=0)){var M,H;const B=(((M=l.flip)==null?void 0:M.index)||0)+1,F=O[B];if(F&&(!(d==="alignment"?y!==Te(F):!1)||R.every($=>Te($.placement)===y?$.overflows[0]>0:!0)))return{data:{index:B,overflows:R},reset:{placement:F}};let I=(H=R.filter(U=>U.overflows[0]<=0).sort((U,$)=>U.overflows[1]-$.overflows[1])[0])==null?void 0:H.placement;if(!I)switch(f){case"bestFit":{var z;const U=(z=R.filter($=>{if(T){const V=Te($.placement);return V===y||V==="y"}return!0}).map($=>[$.placement,$.overflows.filter(V=>V>0).reduce((V,q)=>V+q,0)]).sort(($,V)=>$[1]-V[1])[0])==null?void 0:z[0];U&&(I=U);break}case"initialPlacement":I=a;break}if(o!==I)return{reset:{placement:I}}}return{}}}},df=new Set(["left","top"]);async function ff(e,t){const{placement:n,platform:r,elements:o}=e,l=await(r.isRTL==null?void 0:r.isRTL(o.floating)),i=Ve(n),a=Lt(n),s=Te(n)==="y",u=df.has(i)?-1:1,c=l&&s?-1:1,d=dt(t,e);let{mainAxis:m,crossAxis:f,alignmentAxis:h}=typeof d=="number"?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return a&&typeof h=="number"&&(f=a==="end"?h*-1:h),s?{x:f*c,y:m*u}:{x:m*u,y:f*c}}const pf=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:o,y:l,placement:i,middlewareData:a}=t,s=await ff(t,e);return i===((n=a.offset)==null?void 0:n.placement)&&(r=a.arrow)!=null&&r.alignmentOffset?{}:{x:o+s.x,y:l+s.y,data:{...s,placement:i}}}}},mf=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:l=!0,crossAxis:i=!1,limiter:a={fn:b=>{let{x,y}=b;return{x,y}}},...s}=dt(e,t),u={x:n,y:r},c=await hn(t,s),d=Te(Ve(o)),m=fi(d);let f=u[m],h=u[d];if(l){const b=m==="y"?"top":"left",x=m==="y"?"bottom":"right",y=f+c[b],w=f-c[x];f=wo(y,f,w)}if(i){const b=d==="y"?"top":"left",x=d==="y"?"bottom":"right",y=h+c[b],w=h-c[x];h=wo(y,h,w)}const v=a.fn({...t,[m]:f,[d]:h});return{...v,data:{x:v.x-n,y:v.y-r,enabled:{[m]:l,[d]:i}}}}}},hf=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:o,rects:l,platform:i,elements:a}=t,{apply:s=()=>{},...u}=dt(e,t),c=await hn(t,u),d=Ve(o),m=Lt(o),f=Te(o)==="y",{width:h,height:v}=l.floating;let b,x;d==="top"||d==="bottom"?(b=d,x=m===(await(i.isRTL==null?void 0:i.isRTL(a.floating))?"start":"end")?"left":"right"):(x=d,b=m==="end"?"top":"bottom");const y=v-c.top-c.bottom,w=h-c.left-c.right,S=Ye(v-c[b],y),C=Ye(h-c[x],w),T=!t.middlewareData.shift;let O=S,k=C;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(k=w),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(O=y),T&&!m){const R=ne(c.left,0),M=ne(c.right,0),H=ne(c.top,0),z=ne(c.bottom,0);f?k=h-2*(R!==0||M!==0?R+M:ne(c.left,c.right)):O=v-2*(H!==0||z!==0?H+z:ne(c.top,c.bottom))}await s({...t,availableWidth:k,availableHeight:O});const A=await i.getDimensions(a.floating);return h!==A.width||v!==A.height?{reset:{rects:!0}}:{}}}};function hi(e){const t=ye(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=ke(e),l=o?e.offsetWidth:n,i=o?e.offsetHeight:r,a=Ct(n)!==l||Ct(r)!==i;return a&&(n=l,r=i),{width:n,height:r,$:a}}function Tr(e){return oe(e)?e:e.contextElement}function nt(e){const t=Tr(e);if(!ke(t))return $e(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:l}=hi(t);let i=(l?Ct(n.width):n.width)/r,a=(l?Ct(n.height):n.height)/o;return(!i||!Number.isFinite(i))&&(i=1),(!a||!Number.isFinite(a))&&(a=1),{x:i,y:a}}const gf=$e(0);function gi(e){const t=de(e);return!Or()||!t.visualViewport?gf:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function vf(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==de(e)?!1:t}function Ze(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),l=Tr(e);let i=$e(1);t&&(r?oe(r)&&(i=nt(r)):i=nt(e));const a=vf(l,n,r)?gi(l):$e(0);let s=(o.left+a.x)/i.x,u=(o.top+a.y)/i.y,c=o.width/i.x,d=o.height/i.y;if(l){const m=de(l),f=r&&oe(r)?de(r):r;let h=m,v=nr(h);for(;v&&r&&f!==h;){const b=nt(v),x=v.getBoundingClientRect(),y=ye(v),w=x.left+(v.clientLeft+parseFloat(y.paddingLeft))*b.x,S=x.top+(v.clientTop+parseFloat(y.paddingTop))*b.y;s*=b.x,u*=b.y,c*=b.x,d*=b.y,s+=w,u+=S,h=de(v),v=nr(h)}}return nn({width:c,height:d,x:s,y:u})}function gn(e,t){const n=mn(e).scrollLeft;return t?t.left+n:Ze(Re(e)).left+n}function vi(e,t){const n=e.getBoundingClientRect(),r=n.left+t.scrollLeft-gn(e,n),o=n.top+t.scrollTop;return{x:r,y:o}}function bf(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const l=o==="fixed",i=Re(r),a=t?pn(t.floating):!1;if(r===i||a&&l)return n;let s={scrollLeft:0,scrollTop:0},u=$e(1);const c=$e(0),d=ke(r);if((d||!d&&!l)&&((ct(r)!=="body"||Pt(i))&&(s=mn(r)),ke(r))){const f=Ze(r);u=nt(r),c.x=f.x+r.clientLeft,c.y=f.y+r.clientTop}const m=i&&!d&&!l?vi(i,s):$e(0);return{width:n.width*u.x,height:n.height*u.y,x:n.x*u.x-s.scrollLeft*u.x+c.x+m.x,y:n.y*u.y-s.scrollTop*u.y+c.y+m.y}}function xf(e){return Array.from(e.getClientRects())}function wf(e){const t=Re(e),n=mn(e),r=e.ownerDocument.body,o=ne(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),l=ne(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let i=-n.scrollLeft+gn(e);const a=-n.scrollTop;return ye(r).direction==="rtl"&&(i+=ne(t.clientWidth,r.clientWidth)-o),{width:o,height:l,x:i,y:a}}const So=25;function yf(e,t){const n=de(e),r=Re(e),o=n.visualViewport;let l=r.clientWidth,i=r.clientHeight,a=0,s=0;if(o){l=o.width,i=o.height;const c=Or();(!c||c&&t==="fixed")&&(a=o.offsetLeft,s=o.offsetTop)}const u=gn(r);if(u<=0){const c=r.ownerDocument,d=c.body,m=getComputedStyle(d),f=c.compatMode==="CSS1Compat"&&parseFloat(m.marginLeft)+parseFloat(m.marginRight)||0,h=Math.abs(r.clientWidth-d.clientWidth-f);h<=So&&(l-=h)}else u<=So&&(l+=u);return{width:l,height:i,x:a,y:s}}const Ef=new Set(["absolute","fixed"]);function Cf(e,t){const n=Ze(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,l=ke(e)?nt(e):$e(1),i=e.clientWidth*l.x,a=e.clientHeight*l.y,s=o*l.x,u=r*l.y;return{width:i,height:a,x:s,y:u}}function $o(e,t,n){let r;if(t==="viewport")r=yf(e,n);else if(t==="document")r=wf(Re(e));else if(oe(t))r=Cf(t,n);else{const o=gi(e);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return nn(r)}function bi(e,t){const n=He(e);return n===t||!oe(n)||ot(n)?!1:ye(n).position==="fixed"||bi(n,t)}function Sf(e,t){const n=t.get(e);if(n)return n;let r=Et(e,[],!1).filter(a=>oe(a)&&ct(a)!=="body"),o=null;const l=ye(e).position==="fixed";let i=l?He(e):e;for(;oe(i)&&!ot(i);){const a=ye(i),s=Rr(i);!s&&a.position==="fixed"&&(o=null),(l?!s&&!o:!s&&a.position==="static"&&!!o&&Ef.has(o.position)||Pt(i)&&!s&&bi(e,i))?r=r.filter(c=>c!==i):o=a,i=He(i)}return t.set(e,r),r}function $f(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const i=[...n==="clippingAncestors"?pn(t)?[]:Sf(t,this._c):[].concat(n),r],a=i[0],s=i.reduce((u,c)=>{const d=$o(t,c,o);return u.top=ne(d.top,u.top),u.right=Ye(d.right,u.right),u.bottom=Ye(d.bottom,u.bottom),u.left=ne(d.left,u.left),u},$o(t,a,o));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}}function kf(e){const{width:t,height:n}=hi(e);return{width:t,height:n}}function Rf(e,t,n){const r=ke(t),o=Re(t),l=n==="fixed",i=Ze(e,!0,l,t);let a={scrollLeft:0,scrollTop:0};const s=$e(0);function u(){s.x=gn(o)}if(r||!r&&!l)if((ct(t)!=="body"||Pt(o))&&(a=mn(t)),r){const f=Ze(t,!0,l,t);s.x=f.x+t.clientLeft,s.y=f.y+t.clientTop}else o&&u();l&&!r&&o&&u();const c=o&&!r&&!l?vi(o,a):$e(0),d=i.left+a.scrollLeft-s.x-c.x,m=i.top+a.scrollTop-s.y-c.y;return{x:d,y:m,width:i.width,height:i.height}}function jn(e){return ye(e).position==="static"}function ko(e,t){if(!ke(e)||ye(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return Re(e)===n&&(n=n.ownerDocument.body),n}function xi(e,t){const n=de(e);if(pn(e))return n;if(!ke(e)){let o=He(e);for(;o&&!ot(o);){if(oe(o)&&!jn(o))return o;o=He(o)}return n}let r=ko(e,t);for(;r&&zd(r)&&jn(r);)r=ko(r,t);return r&&ot(r)&&jn(r)&&!Rr(r)?n:r||Kd(e)||n}const Of=async function(e){const t=this.getOffsetParent||xi,n=this.getDimensions,r=await n(e.floating);return{reference:Rf(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function Tf(e){return ye(e).direction==="rtl"}const Pf={convertOffsetParentRelativeRectToViewportRelativeRect:bf,getDocumentElement:Re,getClippingRect:$f,getOffsetParent:xi,getElementRects:Of,getClientRects:xf,getDimensions:kf,getScale:nt,isElement:oe,isRTL:Tf};function wi(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function Lf(e,t){let n=null,r;const o=Re(e);function l(){var a;clearTimeout(r),(a=n)==null||a.disconnect(),n=null}function i(a,s){a===void 0&&(a=!1),s===void 0&&(s=1),l();const u=e.getBoundingClientRect(),{left:c,top:d,width:m,height:f}=u;if(a||t(),!m||!f)return;const h=zt(d),v=zt(o.clientWidth-(c+m)),b=zt(o.clientHeight-(d+f)),x=zt(c),w={rootMargin:-h+"px "+-v+"px "+-b+"px "+-x+"px",threshold:ne(0,Ye(1,s))||1};let S=!0;function C(T){const O=T[0].intersectionRatio;if(O!==s){if(!S)return i();O?i(!1,O):r=setTimeout(()=>{i(!1,1e-7)},1e3)}O===1&&!wi(u,e.getBoundingClientRect())&&i(),S=!1}try{n=new IntersectionObserver(C,{...w,root:o.ownerDocument})}catch{n=new IntersectionObserver(C,w)}n.observe(e)}return i(!0),l}function Af(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:o=!0,ancestorResize:l=!0,elementResize:i=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:s=!1}=r,u=Tr(e),c=o||l?[...u?Et(u):[],...Et(t)]:[];c.forEach(x=>{o&&x.addEventListener("scroll",n,{passive:!0}),l&&x.addEventListener("resize",n)});const d=u&&a?Lf(u,n):null;let m=-1,f=null;i&&(f=new ResizeObserver(x=>{let[y]=x;y&&y.target===u&&f&&(f.unobserve(t),cancelAnimationFrame(m),m=requestAnimationFrame(()=>{var w;(w=f)==null||w.observe(t)})),n()}),u&&!s&&f.observe(u),f.observe(t));let h,v=s?Ze(e):null;s&&b();function b(){const x=Ze(e);v&&!wi(v,x)&&n(),v=x,h=requestAnimationFrame(b)}return n(),()=>{var x;c.forEach(y=>{o&&y.removeEventListener("scroll",n),l&&y.removeEventListener("resize",n)}),d?.(),(x=f)==null||x.disconnect(),f=null,s&&cancelAnimationFrame(h)}}const Dn=hn,Ff=pf,Mf=mf,Nf=cf,If=hf,jf=(e,t,n)=>{const r=new Map,o={platform:Pf,...n},l={...o.platform,_c:r};return uf(e,t,{...o,platform:l})};var Df=typeof document<"u",_f=function(){},Gt=Df?p.useLayoutEffect:_f;function rn(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,o;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!rn(e[r],t[r]))return!1;return!0}if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,o[r]))return!1;for(r=n;r--!==0;){const l=o[r];if(!(l==="_owner"&&e.$$typeof)&&!rn(e[l],t[l]))return!1}return!0}return e!==e&&t!==t}function yi(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Ro(e,t){const n=yi(e);return Math.round(t*n)/n}function _n(e){const t=g.useRef(e);return Gt(()=>{t.current=e}),t}function Bf(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:o,elements:{reference:l,floating:i}={},transform:a=!0,whileElementsMounted:s,open:u}=e,[c,d]=g.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[m,f]=g.useState(r);rn(m,r)||f(r);const[h,v]=g.useState(null),[b,x]=g.useState(null),y=g.useCallback($=>{$!==T.current&&(T.current=$,v($))},[]),w=g.useCallback($=>{$!==O.current&&(O.current=$,x($))},[]),S=l||h,C=i||b,T=g.useRef(null),O=g.useRef(null),k=g.useRef(c),A=s!=null,R=_n(s),M=_n(o),H=_n(u),z=g.useCallback(()=>{if(!T.current||!O.current)return;const $={placement:t,strategy:n,middleware:m};M.current&&($.platform=M.current),jf(T.current,O.current,$).then(V=>{const q={...V,isPositioned:H.current!==!1};B.current&&!rn(k.current,q)&&(k.current=q,Zt.flushSync(()=>{d(q)}))})},[m,t,n,M,H]);Gt(()=>{u===!1&&k.current.isPositioned&&(k.current.isPositioned=!1,d($=>({...$,isPositioned:!1})))},[u]);const B=g.useRef(!1);Gt(()=>(B.current=!0,()=>{B.current=!1}),[]),Gt(()=>{if(S&&(T.current=S),C&&(O.current=C),S&&C){if(R.current)return R.current(S,C,z);z()}},[S,C,z,R,A]);const F=g.useMemo(()=>({reference:T,floating:O,setReference:y,setFloating:w}),[y,w]),I=g.useMemo(()=>({reference:S,floating:C}),[S,C]),U=g.useMemo(()=>{const $={position:n,left:0,top:0};if(!I.floating)return $;const V=Ro(I.floating,c.x),q=Ro(I.floating,c.y);return a?{...$,transform:"translate("+V+"px, "+q+"px)",...yi(I.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:V,top:q}},[n,a,I.floating,c.x,c.y]);return g.useMemo(()=>({...c,update:z,refs:F,elements:I,floatingStyles:U}),[c,z,F,I,U])}const Ei=(e,t)=>({...Ff(e),options:[e,t]}),Hf=(e,t)=>({...Mf(e),options:[e,t]}),Vf=(e,t)=>({...Nf(e),options:[e,t]}),zf=(e,t)=>({...If(e),options:[e,t]}),Ci={...g},Wf=Ci.useInsertionEffect,Uf=Wf||(e=>e());function Si(e){const t=g.useRef(()=>{if(process.env.NODE_ENV!=="production")throw new Error("Cannot call an event handler while rendering.")});return Uf(()=>{t.current=e}),g.useCallback(function(){for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];return t.current==null?void 0:t.current(...r)},[])}var or=typeof document<"u"?p.useLayoutEffect:p.useEffect;let Oo=!1,qf=0;const To=()=>"floating-ui-"+Math.random().toString(36).slice(2,6)+qf++;function Gf(){const[e,t]=g.useState(()=>Oo?To():void 0);return or(()=>{e==null&&t(To())},[]),g.useEffect(()=>{Oo=!0},[]),e}const Kf=Ci.useId,Yf=Kf||Gf;let St;process.env.NODE_ENV!=="production"&&(St=new Set);function Zf(){for(var e,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];const o="Floating UI: "+n.join(" ");if(!((e=St)!=null&&e.has(o))){var l;(l=St)==null||l.add(o),console.warn(o)}}function Xf(){for(var e,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];const o="Floating UI: "+n.join(" ");if(!((e=St)!=null&&e.has(o))){var l;(l=St)==null||l.add(o),console.error(o)}}function Jf(){const e=new Map;return{emit(t,n){var r;(r=e.get(t))==null||r.forEach(o=>o(n))},on(t,n){e.set(t,[...e.get(t)||[],n])},off(t,n){var r;e.set(t,((r=e.get(t))==null?void 0:r.filter(o=>o!==n))||[])}}}const Qf=g.createContext(null),ep=g.createContext(null),tp=()=>{var e;return((e=g.useContext(Qf))==null?void 0:e.id)||null},np=()=>g.useContext(ep),rp="data-floating-ui-focusable";function op(e){const{open:t=!1,onOpenChange:n,elements:r}=e,o=Yf(),l=g.useRef({}),[i]=g.useState(()=>Jf()),a=tp()!=null;if(process.env.NODE_ENV!=="production"){const f=r.reference;f&&!oe(f)&&Xf("Cannot pass a virtual element to the `elements.reference` option,","as it must be a real DOM element. Use `refs.setPositionReference()`","instead.")}const[s,u]=g.useState(r.reference),c=Si((f,h,v)=>{l.current.openEvent=f?h:void 0,i.emit("openchange",{open:f,event:h,reason:v,nested:a}),n?.(f,h,v)}),d=g.useMemo(()=>({setPositionReference:u}),[]),m=g.useMemo(()=>({reference:s||r.reference||null,floating:r.floating||null,domReference:r.reference}),[s,r.reference,r.floating]);return g.useMemo(()=>({dataRef:l,open:t,onOpenChange:c,elements:m,events:i,floatingId:o,refs:d}),[t,c,m,i,o,d])}function lp(e){e===void 0&&(e={});const{nodeId:t}=e,n=op({...e,elements:{reference:null,floating:null,...e.elements}}),r=e.rootContext||n,o=r.elements,[l,i]=g.useState(null),[a,s]=g.useState(null),c=o?.domReference||l,d=g.useRef(null),m=np();or(()=>{c&&(d.current=c)},[c]);const f=Bf({...e,elements:{...o,...a&&{reference:a}}}),h=g.useCallback(w=>{const S=oe(w)?{getBoundingClientRect:()=>w.getBoundingClientRect(),contextElement:w}:w;s(S),f.refs.setReference(S)},[f.refs]),v=g.useCallback(w=>{(oe(w)||w===null)&&(d.current=w,i(w)),(oe(f.refs.reference.current)||f.refs.reference.current===null||w!==null&&!oe(w))&&f.refs.setReference(w)},[f.refs]),b=g.useMemo(()=>({...f.refs,setReference:v,setPositionReference:h,domReference:d}),[f.refs,v,h]),x=g.useMemo(()=>({...f.elements,domReference:c}),[f.elements,c]),y=g.useMemo(()=>({...f,...r,refs:b,elements:x,nodeId:t}),[f,b,x,t,r]);return or(()=>{r.dataRef.current.floatingContext=y;const w=m?.nodesRef.current.find(S=>S.id===t);w&&(w.context=y)}),g.useMemo(()=>({...f,context:y,refs:b,elements:x}),[f,b,x,y])}const Po="active",Lo="selected";function Bn(e,t,n){const r=new Map,o=n==="item";let l=e;if(o&&e){const{[Po]:i,[Lo]:a,...s}=e;l=s}return{...n==="floating"&&{tabIndex:-1,[rp]:""},...l,...t.map(i=>{const a=i?i[n]:null;return typeof a=="function"?e?a(e):null:a}).concat(e).reduce((i,a)=>(a&&Object.entries(a).forEach(s=>{let[u,c]=s;if(!(o&&[Po,Lo].includes(u)))if(u.indexOf("on")===0){if(r.has(u)||r.set(u,[]),typeof c=="function"){var d;(d=r.get(u))==null||d.push(c),i[u]=function(){for(var m,f=arguments.length,h=new Array(f),v=0;v<f;v++)h[v]=arguments[v];return(m=r.get(u))==null?void 0:m.map(b=>b(...h)).find(b=>b!==void 0)}}}else i[u]=c}),i),{})}}function ip(e){e===void 0&&(e=[]);const t=e.map(a=>a?.reference),n=e.map(a=>a?.floating),r=e.map(a=>a?.item),o=g.useCallback(a=>Bn(a,e,"reference"),t),l=g.useCallback(a=>Bn(a,e,"floating"),n),i=g.useCallback(a=>Bn(a,e,"item"),r);return g.useMemo(()=>({getReferenceProps:o,getFloatingProps:l,getItemProps:i}),[o,l,i])}function Ao(e,t){return{...e,rects:{...e.rects,floating:{...e.rects.floating,height:t}}}}const ap=e=>({name:"inner",options:e,async fn(t){const{listRef:n,overflowRef:r,onFallbackChange:o,offset:l=0,index:i=0,minItemsVisible:a=4,referenceOverflowThreshold:s=0,scrollRef:u,...c}=dt(e,t),{rects:d,elements:{floating:m}}=t,f=n.current[i],h=u?.current||m,v=m.clientTop||h.clientTop,b=m.clientTop!==0,x=h.clientTop!==0,y=m===h;if(process.env.NODE_ENV!=="production"&&(t.placement.startsWith("bottom")||Zf('`placement` side must be "bottom" when using the `inner`',"middleware.")),!f)return{};const w={...t,...await Ei(-f.offsetTop-m.clientTop-d.reference.height/2-f.offsetHeight/2-l).fn(t)},S=await Dn(Ao(w,h.scrollHeight+v+m.clientTop),c),C=await Dn(w,{...c,elementContext:"reference"}),T=ne(0,S.top),O=w.y+T,R=(h.scrollHeight>h.clientHeight?M=>M:Ct)(ne(0,h.scrollHeight+(b&&y||x?v*2:0)-T-ne(0,S.bottom)));if(h.style.maxHeight=R+"px",h.scrollTop=T,o){const M=h.offsetHeight<f.offsetHeight*Ye(a,n.current.length)-1||C.top>=-s||C.bottom>=-s;Zt.flushSync(()=>o(M))}return r&&(r.current=await Dn(Ao({...w,y:O},h.offsetHeight+v+m.clientTop),c)),{y:O}}});function sp(e,t){const{open:n,elements:r}=e,{enabled:o=!0,overflowRef:l,scrollRef:i,onChange:a}=t,s=Si(a),u=g.useRef(!1),c=g.useRef(null),d=g.useRef(null);g.useEffect(()=>{if(!o)return;function f(v){if(v.ctrlKey||!h||l.current==null)return;const b=v.deltaY,x=l.current.top>=-.5,y=l.current.bottom>=-.5,w=h.scrollHeight-h.clientHeight,S=b<0?-1:1,C=b<0?"max":"min";h.scrollHeight<=h.clientHeight||(!x&&b>0||!y&&b<0?(v.preventDefault(),Zt.flushSync(()=>{s(T=>T+Math[C](b,w*S))})):/firefox/i.test(Zd())&&(h.scrollTop+=b))}const h=i?.current||r.floating;if(n&&h)return h.addEventListener("wheel",f),requestAnimationFrame(()=>{c.current=h.scrollTop,l.current!=null&&(d.current={...l.current})}),()=>{c.current=null,d.current=null,h.removeEventListener("wheel",f)}},[o,n,r.floating,l,i,s]);const m=g.useMemo(()=>({onKeyDown(){u.current=!0},onWheel(){u.current=!1},onPointerMove(){u.current=!1},onScroll(){const f=i?.current||r.floating;if(!(!l.current||!f||!u.current)){if(c.current!==null){const h=f.scrollTop-c.current;(l.current.bottom<-.5&&h<-1||l.current.top<-.5&&h>1)&&Zt.flushSync(()=>s(v=>v+h))}requestAnimationFrame(()=>{c.current=f.scrollTop})}}}),[r.floating,s,l,i]);return g.useMemo(()=>o?{floating:m}:{},[o,m])}let ft=p.createContext({styles:void 0,setReference:()=>{},setFloating:()=>{},getReferenceProps:()=>({}),getFloatingProps:()=>({}),slot:{}});ft.displayName="FloatingContext";let Pr=p.createContext(null);Pr.displayName="PlacementContext";function up(e){return p.useMemo(()=>e?typeof e=="string"?{to:e}:e:null,[e])}function cp(){return p.useContext(ft).setReference}function dp(){return p.useContext(ft).getReferenceProps}function fp(){let{getFloatingProps:e,slot:t}=p.useContext(ft);return p.useCallback((...n)=>Object.assign({},e(...n),{"data-anchor":t.anchor}),[e,t])}function pp(e=null){e===!1&&(e=null),typeof e=="string"&&(e={to:e});let t=p.useContext(Pr),n=p.useMemo(()=>e,[JSON.stringify(e,(o,l)=>{var i;return(i=l?.outerHTML)!=null?i:l})]);X(()=>{t?.(n??null)},[t,n]);let r=p.useContext(ft);return p.useMemo(()=>[r.setFloating,e?r.styles:{}],[r.setFloating,e,r.styles])}let Fo=4;function mp({children:e,enabled:t=!0}){let[n,r]=p.useState(null),[o,l]=p.useState(0),i=p.useRef(null),[a,s]=p.useState(null);hp(a);let u=t&&n!==null&&a!==null,{to:c="bottom",gap:d=0,offset:m=0,padding:f=0,inner:h}=gp(n,a),[v,b="center"]=c.split(" ");X(()=>{u&&l(0)},[u]);let{refs:x,floatingStyles:y,context:w}=lp({open:u,placement:v==="selection"?b==="center"?"bottom":`bottom-${b}`:b==="center"?`${v}`:`${v}-${b}`,strategy:"absolute",transform:!1,middleware:[Ei({mainAxis:v==="selection"?0:d,crossAxis:m}),Hf({padding:f}),v!=="selection"&&Vf({padding:f}),v==="selection"&&h?ap({...h,padding:f,overflowRef:i,offset:o,minItemsVisible:Fo,referenceOverflowThreshold:f,onFallbackChange(M){var H,z;if(!M)return;let B=w.elements.floating;if(!B)return;let F=parseFloat(getComputedStyle(B).scrollPaddingBottom)||0,I=Math.min(Fo,B.childElementCount),U=0,$=0;for(let V of(z=(H=w.elements.floating)==null?void 0:H.childNodes)!=null?z:[])if(Ne(V)){let q=V.offsetTop,pe=q+V.clientHeight+F,K=B.scrollTop,_=K+B.clientHeight;if(q>=K&&pe<=_)I--;else{$=Math.max(0,Math.min(pe,_)-Math.max(q,K)),U=V.clientHeight;break}}I>=1&&l(V=>{let q=U*I-$+F;return V>=q?V:q})}}):null,zf({padding:f,apply({availableWidth:M,availableHeight:H,elements:z}){Object.assign(z.floating.style,{overflow:"auto",maxWidth:`${M}px`,maxHeight:`min(var(--anchor-max-height, 100vh), ${H}px)`})}})].filter(Boolean),whileElementsMounted:Af}),[S=v,C=b]=w.placement.split("-");v==="selection"&&(S="selection");let T=p.useMemo(()=>({anchor:[S,C].filter(Boolean).join(" ")}),[S,C]),O=sp(w,{overflowRef:i,onChange:l}),{getReferenceProps:k,getFloatingProps:A}=ip([O]),R=D(M=>{s(M),x.setFloating(M)});return g.createElement(Pr.Provider,{value:r},g.createElement(ft.Provider,{value:{setFloating:R,setReference:x.setReference,styles:y,getReferenceProps:k,getFloatingProps:A,slot:T}},e))}function hp(e){X(()=>{if(!e)return;let t=new MutationObserver(()=>{let n=window.getComputedStyle(e).maxHeight,r=parseFloat(n);if(isNaN(r))return;let o=parseInt(n);isNaN(o)||r!==o&&(e.style.maxHeight=`${Math.ceil(r)}px`)});return t.observe(e,{attributes:!0,attributeFilter:["style"]}),()=>{t.disconnect()}},[e])}function gp(e,t){var n,r,o;let l=Hn((n=e?.gap)!=null?n:"var(--anchor-gap, 0)",t),i=Hn((r=e?.offset)!=null?r:"var(--anchor-offset, 0)",t),a=Hn((o=e?.padding)!=null?o:"var(--anchor-padding, 0)",t);return{...e,gap:l,offset:i,padding:a}}function Hn(e,t,n=void 0){let r=Xe(),o=D((s,u)=>{if(s==null)return[n,null];if(typeof s=="number")return[s,null];if(typeof s=="string"){if(!u)return[n,null];let c=Mo(s,u);return[c,d=>{let m=$i(s);{let f=m.map(h=>window.getComputedStyle(u).getPropertyValue(h));r.requestAnimationFrame(function h(){r.nextFrame(h);let v=!1;for(let[x,y]of m.entries()){let w=window.getComputedStyle(u).getPropertyValue(y);if(f[x]!==w){f[x]=w,v=!0;break}}if(!v)return;let b=Mo(s,u);c!==b&&(d(b),c=b)})}return r.dispose}]}return[n,null]}),l=p.useMemo(()=>o(e,t)[0],[e,t]),[i=l,a]=p.useState();return X(()=>{let[s,u]=o(e,t);if(a(s),!!u)return u(a)},[e,t]),i}function $i(e){let t=/var\((.*)\)/.exec(e);if(t){let n=t[1].indexOf(",");if(n===-1)return[t[1]];let r=t[1].slice(0,n).trim(),o=t[1].slice(n+1).trim();return o?[r,...$i(o)]:[r]}return[]}function Mo(e,t){let n=document.createElement("div");t.appendChild(n),n.style.setProperty("margin-top","0px","important"),n.style.setProperty("margin-top",e,"important");let r=parseFloat(window.getComputedStyle(n).marginTop)||0;return t.removeChild(n),r}function vp({children:e,freeze:t},n){let r=ki(t,e);return p.isValidElement(r)?p.cloneElement(r,{ref:n}):p.createElement(p.Fragment,null,r)}p.forwardRef(vp);function ki(e,t){let[n,r]=p.useState(t);return!e&&n!==t&&r(t),e?n:t}let vn=p.createContext(null);vn.displayName="OpenClosedContext";var ae=(e=>(e[e.Open=1]="Open",e[e.Closed=2]="Closed",e[e.Closing=4]="Closing",e[e.Opening=8]="Opening",e))(ae||{});function bn(){return p.useContext(vn)}function Lr({value:e,children:t}){return p.createElement(vn.Provider,{value:e},t)}function bp({children:e}){return p.createElement(vn.Provider,{value:null},e)}function xp(e){throw new Error("Unexpected object: "+e)}var Z=(e=>(e[e.First=0]="First",e[e.Previous=1]="Previous",e[e.Next=2]="Next",e[e.Last=3]="Last",e[e.Specific=4]="Specific",e[e.Nothing=5]="Nothing",e))(Z||{});function Wt(e,t){let n=t.resolveItems();if(n.length<=0)return null;let r=t.resolveActiveIndex(),o=r??-1;switch(e.focus){case 0:{for(let l=0;l<n.length;++l)if(!t.resolveDisabled(n[l],l,n))return l;return r}case 1:{o===-1&&(o=n.length);for(let l=o-1;l>=0;--l)if(!t.resolveDisabled(n[l],l,n))return l;return r}case 2:{for(let l=o+1;l<n.length;++l)if(!t.resolveDisabled(n[l],l,n))return l;return r}case 3:{for(let l=n.length-1;l>=0;--l)if(!t.resolveDisabled(n[l],l,n))return l;return r}case 4:{for(let l=0;l<n.length;++l)if(t.resolveId(n[l],l,n)===e.id)return l;return r}case 5:return null;default:xp(e)}}function Ri(e){let t=D(e),n=p.useRef(!1);p.useEffect(()=>(n.current=!1,()=>{n.current=!0,Il(()=>{n.current&&t()})}),[t])}let wp=p.createContext(!1);function yp(){return p.useContext(wp)}function Ep(e){let t=yp(),n=p.useContext(Ti),[r,o]=p.useState(()=>{var l;if(!t&&n!==null)return(l=n.current)!=null?l:null;if(Se.isServer)return null;let i=e?.getElementById("headlessui-portal-root");if(i)return i;if(e===null)return null;let a=e.createElement("div");return a.setAttribute("id","headlessui-portal-root"),e.body.appendChild(a)});return p.useEffect(()=>{r!==null&&(e!=null&&e.body.contains(r)||e==null||e.body.appendChild(r))},[r,e]),p.useEffect(()=>{t||n!==null&&o(n.current)},[n,o,t]),r}let Oi=p.Fragment,Cp=Q(function(e,t){let{ownerDocument:n=null,...r}=e,o=p.useRef(null),l=ue(Gl(m=>{o.current=m}),t),i=tr(o.current),a=n??i,s=Ep(a),u=p.useContext(Rp),c=Xe(),d=te();return Ri(()=>{var m;s&&s.childNodes.length<=0&&((m=s.parentElement)==null||m.removeChild(s))}),s?Ge.createPortal(p.createElement("div",{"data-headlessui-portal":"",ref:m=>{c.dispose(),u&&m&&c.add(u.register(m))}},d({ourProps:{ref:l},theirProps:r,slot:{},defaultTag:Oi,name:"Portal"})),s):null});function Sp(e,t){let n=ue(t),{enabled:r=!0,ownerDocument:o,...l}=e,i=te();return r?p.createElement(Cp,{...l,ownerDocument:o,ref:n}):i({ourProps:{ref:n},theirProps:l,slot:{},defaultTag:Oi,name:"Portal"})}let $p=p.Fragment,Ti=p.createContext(null);function kp(e,t){let{target:n,...r}=e,o={ref:ue(t)},l=te();return p.createElement(Ti.Provider,{value:n},l({ourProps:o,theirProps:r,defaultTag:$p,name:"Popover.Group"}))}let Rp=p.createContext(null),Op=Q(Sp),Tp=Q(kp),Pp=Object.assign(Op,{Group:Tp});const Kt={Idle:{kind:"Idle"},Tracked:e=>({kind:"Tracked",position:e}),Moved:{kind:"Moved"}};function Pi(e){let t=e.getBoundingClientRect();return`${t.x},${t.y}`}function Lp(e,t,n){let r=fe();if(t.kind==="Tracked"){let o=function(){l!==Pi(e)&&(r.dispose(),n())},{position:l}=t,i=new ResizeObserver(o);i.observe(e),r.add(()=>i.disconnect()),r.addEventListener(window,"scroll",o,{passive:!0}),r.addEventListener(window,"resize",o)}return()=>r.dispose()}function Ap(){let e=typeof document>"u";return"useSyncExternalStore"in g?(t=>t.useSyncExternalStore)(g)(()=>()=>{},()=>!1,()=>!e):!1}function Li(){let e=Ap(),[t,n]=g.useState(Se.isHandoffComplete);return t&&Se.isHandoffComplete===!1&&n(!1),g.useEffect(()=>{t!==!0&&n(!0)},[t]),g.useEffect(()=>Se.handoff(),[]),e?!1:t}function Fp(){let e=p.useRef(!1);return X(()=>(e.current=!0,()=>{e.current=!1}),[]),e}function Ai(e){var t;return!!(e.enter||e.enterFrom||e.enterTo||e.leave||e.leaveFrom||e.leaveTo)||!tt((t=e.as)!=null?t:Mi)||p.Children.count(e.children)===1}let xn=p.createContext(null);xn.displayName="TransitionContext";var Mp=(e=>(e.Visible="visible",e.Hidden="hidden",e))(Mp||{});function Np(){let e=p.useContext(xn);if(e===null)throw new Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return e}function Ip(){let e=p.useContext(wn);if(e===null)throw new Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return e}let wn=p.createContext(null);wn.displayName="NestingContext";function yn(e){return"children"in e?yn(e.children):e.current.filter(({el:t})=>t.current!==null).filter(({state:t})=>t==="visible").length>0}function Fi(e,t){let n=Je(e),r=p.useRef([]),o=Fp(),l=Xe(),i=D((f,h=De.Hidden)=>{let v=r.current.findIndex(({el:b})=>b===f);v!==-1&&(se(h,{[De.Unmount](){r.current.splice(v,1)},[De.Hidden](){r.current[v].state="hidden"}}),l.microTask(()=>{var b;!yn(r)&&o.current&&((b=n.current)==null||b.call(n))}))}),a=D(f=>{let h=r.current.find(({el:v})=>v===f);return h?h.state!=="visible"&&(h.state="visible"):r.current.push({el:f,state:"visible"}),()=>i(f,De.Unmount)}),s=p.useRef([]),u=p.useRef(Promise.resolve()),c=p.useRef({enter:[],leave:[]}),d=D((f,h,v)=>{s.current.splice(0),t&&(t.chains.current[h]=t.chains.current[h].filter(([b])=>b!==f)),t?.chains.current[h].push([f,new Promise(b=>{s.current.push(b)})]),t?.chains.current[h].push([f,new Promise(b=>{Promise.all(c.current[h].map(([x,y])=>y)).then(()=>b())})]),h==="enter"?u.current=u.current.then(()=>t?.wait.current).then(()=>v(h)):v(h)}),m=D((f,h,v)=>{Promise.all(c.current[h].splice(0).map(([b,x])=>x)).then(()=>{var b;(b=s.current.shift())==null||b()}).then(()=>v(h))});return p.useMemo(()=>({children:r,register:a,unregister:i,onStart:d,onStop:m,wait:u,chains:c}),[a,i,r,d,m,c,u])}let Mi=p.Fragment,Ni=rt.RenderStrategy;function jp(e,t){var n,r;let{transition:o=!0,beforeEnter:l,afterEnter:i,beforeLeave:a,afterLeave:s,enter:u,enterFrom:c,enterTo:d,entered:m,leave:f,leaveFrom:h,leaveTo:v,...b}=e,[x,y]=p.useState(null),w=p.useRef(null),S=Ai(e),C=ue(...S?[w,t,y]:t===null?[]:[t]),T=(n=b.unmount)==null||n?De.Unmount:De.Hidden,{show:O,appear:k,initial:A}=Np(),[R,M]=p.useState(O?"visible":"hidden"),H=Ip(),{register:z,unregister:B}=H;X(()=>z(w),[z,w]),X(()=>{if(T===De.Hidden&&w.current){if(O&&R!=="visible"){M("visible");return}return se(R,{hidden:()=>B(w),visible:()=>z(w)})}},[R,w,z,B,O,T]);let F=Li();X(()=>{if(S&&F&&R==="visible"&&w.current===null)throw new Error("Did you forget to passthrough the `ref` to the actual DOM node?")},[w,R,F,S]);let I=A&&!k,U=k&&O&&A,$=p.useRef(!1),V=Fi(()=>{$.current||(M("hidden"),B(w))},H),q=D(W=>{$.current=!0;let xe=W?"enter":"leave";V.onStart(w,xe,he=>{he==="enter"?l?.():he==="leave"&&a?.()})}),pe=D(W=>{let xe=W?"enter":"leave";$.current=!1,V.onStop(w,xe,he=>{he==="enter"?i?.():he==="leave"&&s?.()}),xe==="leave"&&!yn(V)&&(M("hidden"),B(w))});p.useEffect(()=>{S&&o||(q(O),pe(O))},[O,S,o]);let K=!(!o||!S||!F||I),[,_]=kr(K,x,O,{start:q,end:pe}),ee=je({ref:C,className:((r=Zn(b.className,U&&u,U&&c,_.enter&&u,_.enter&&_.closed&&c,_.enter&&!_.closed&&d,_.leave&&f,_.leave&&!_.closed&&h,_.leave&&_.closed&&v,!_.transition&&O&&m))==null?void 0:r.trim())||void 0,...$r(_)}),me=0;R==="visible"&&(me|=ae.Open),R==="hidden"&&(me|=ae.Closed),O&&R==="hidden"&&(me|=ae.Opening),!O&&R==="visible"&&(me|=ae.Closing);let N=te();return p.createElement(wn.Provider,{value:V},p.createElement(Lr,{value:me},N({ourProps:ee,theirProps:b,defaultTag:Mi,features:Ni,visible:R==="visible",name:"Transition.Child"})))}function Dp(e,t){let{show:n,appear:r=!1,unmount:o=!0,...l}=e,i=p.useRef(null),a=Ai(e),s=ue(...a?[i,t]:t===null?[]:[t]);Li();let u=bn();if(n===void 0&&u!==null&&(n=(u&ae.Open)===ae.Open),n===void 0)throw new Error("A <Transition /> is used but it is missing a `show={true | false}` prop.");let[c,d]=p.useState(n?"visible":"hidden"),m=Fi(()=>{n||d("hidden")}),[f,h]=p.useState(!0),v=p.useRef([n]);X(()=>{f!==!1&&v.current[v.current.length-1]!==n&&(v.current.push(n),h(!1))},[v,n]);let b=p.useMemo(()=>({show:n,appear:r,initial:f}),[n,r,f]);X(()=>{n?d("visible"):!yn(m)&&i.current!==null&&d("hidden")},[n,m]);let x={unmount:o},y=D(()=>{var C;f&&h(!1),(C=e.beforeEnter)==null||C.call(e)}),w=D(()=>{var C;f&&h(!1),(C=e.beforeLeave)==null||C.call(e)}),S=te();return p.createElement(wn.Provider,{value:m},p.createElement(xn.Provider,{value:b},S({ourProps:{...x,as:p.Fragment,children:p.createElement(Ii,{ref:s,...x,...l,beforeEnter:y,beforeLeave:w})},theirProps:{},defaultTag:p.Fragment,features:Ni,visible:c==="visible",name:"Transition"})))}function _p(e,t){let n=p.useContext(xn)!==null,r=bn()!==null;return p.createElement(p.Fragment,null,!n&&r?p.createElement(lr,{ref:t,...e}):p.createElement(Ii,{ref:t,...e}))}let lr=Q(Dp),Ii=Q(jp),Bp=Q(_p),Hp=Object.assign(lr,{Child:Bp,Root:lr});var No;let Vp=(No=p.startTransition)!=null?No:function(e){e()};var zp=(e=>(e[e.Open=0]="Open",e[e.Closed=1]="Closed",e))(zp||{}),Wp=(e=>(e[e.ToggleDisclosure=0]="ToggleDisclosure",e[e.CloseDisclosure=1]="CloseDisclosure",e[e.SetButtonId=2]="SetButtonId",e[e.SetPanelId=3]="SetPanelId",e[e.SetButtonElement=4]="SetButtonElement",e[e.SetPanelElement=5]="SetPanelElement",e))(Wp||{});let Up={0:e=>({...e,disclosureState:se(e.disclosureState,{0:1,1:0})}),1:e=>e.disclosureState===1?e:{...e,disclosureState:1},2(e,t){return e.buttonId===t.buttonId?e:{...e,buttonId:t.buttonId}},3(e,t){return e.panelId===t.panelId?e:{...e,panelId:t.panelId}},4(e,t){return e.buttonElement===t.element?e:{...e,buttonElement:t.element}},5(e,t){return e.panelElement===t.element?e:{...e,panelElement:t.element}}},Ar=p.createContext(null);Ar.displayName="DisclosureContext";function Fr(e){let t=p.useContext(Ar);if(t===null){let n=new Error(`<${e} /> is missing a parent <Disclosure /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,Fr),n}return t}let Mr=p.createContext(null);Mr.displayName="DisclosureAPIContext";function ji(e){let t=p.useContext(Mr);if(t===null){let n=new Error(`<${e} /> is missing a parent <Disclosure /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,ji),n}return t}let Nr=p.createContext(null);Nr.displayName="DisclosurePanelContext";function qp(){return p.useContext(Nr)}function Gp(e,t){return se(t.type,Up,e,t)}let Kp=p.Fragment;function Yp(e,t){let{defaultOpen:n=!1,...r}=e,o=p.useRef(null),l=ue(t,Gl(v=>{o.current=v},e.as===void 0||tt(e.as))),i=p.useReducer(Gp,{disclosureState:n?0:1,buttonElement:null,panelElement:null,buttonId:null,panelId:null}),[{disclosureState:a,buttonId:s},u]=i,c=D(v=>{u({type:1});let b=Tt(o.current);if(!b||!s)return;let x=v?_e(v)?v:"current"in v&&_e(v.current)?v.current:b.getElementById(s):b.getElementById(s);x?.focus()}),d=p.useMemo(()=>({close:c}),[c]),m=be({open:a===0,close:c}),f={ref:l},h=te();return p.createElement(Ar.Provider,{value:i},p.createElement(Mr.Provider,{value:d},p.createElement(Gc,{value:c},p.createElement(Lr,{value:se(a,{0:ae.Open,1:ae.Closed})},h({ourProps:f,theirProps:r,slot:m,defaultTag:Kp,name:"Disclosure"})))))}let Zp="button";function Xp(e,t){let n=p.useId(),{id:r=`headlessui-disclosure-button-${n}`,disabled:o=!1,autoFocus:l=!1,...i}=e,[a,s]=Fr("Disclosure.Button"),u=qp(),c=u===null?!1:u===a.panelId,d=p.useRef(null),m=ue(d,t,D(A=>{if(!c)return s({type:4,element:A})}));p.useEffect(()=>{if(!c)return s({type:2,buttonId:r}),()=>{s({type:2,buttonId:null})}},[r,s,c]);let f=D(A=>{var R;if(c){if(a.disclosureState===1)return;switch(A.key){case Y.Space:case Y.Enter:A.preventDefault(),A.stopPropagation(),s({type:0}),(R=a.buttonElement)==null||R.focus();break}}else switch(A.key){case Y.Space:case Y.Enter:A.preventDefault(),A.stopPropagation(),s({type:0});break}}),h=D(A=>{A.key===Y.Space&&A.preventDefault()}),v=D(A=>{var R;Xn(A.currentTarget)||o||(c?(s({type:0}),(R=a.buttonElement)==null||R.focus()):s({type:0}))}),{isFocusVisible:b,focusProps:x}=xr({autoFocus:l}),{isHovered:y,hoverProps:w}=br({isDisabled:o}),{pressed:S,pressProps:C}=wr({disabled:o}),T=be({open:a.disclosureState===0,hover:y,active:S,disabled:o,focus:b,autofocus:l}),O=ui(e,a.buttonElement),k=yt(c?{ref:m,type:O,disabled:o||void 0,autoFocus:l,onKeyDown:f,onClick:v}:{ref:m,id:r,type:O,"aria-expanded":a.disclosureState===0,"aria-controls":a.panelElement?a.panelId:void 0,disabled:o||void 0,autoFocus:l,onKeyDown:f,onKeyUp:h,onClick:v},x,w,C);return te()({ourProps:k,theirProps:i,slot:T,defaultTag:Zp,name:"Disclosure.Button"})}let Jp="div",Qp=rt.RenderStrategy|rt.Static;function em(e,t){let n=p.useId(),{id:r=`headlessui-disclosure-panel-${n}`,transition:o=!1,...l}=e,[i,a]=Fr("Disclosure.Panel"),{close:s}=ji("Disclosure.Panel"),[u,c]=p.useState(null),d=ue(t,D(y=>{Vp(()=>a({type:5,element:y}))}),c);p.useEffect(()=>(a({type:3,panelId:r}),()=>{a({type:3,panelId:null})}),[r,a]);let m=bn(),[f,h]=kr(o,u,m!==null?(m&ae.Open)===ae.Open:i.disclosureState===0),v=be({open:i.disclosureState===0,close:s}),b={ref:d,id:r,...$r(h)},x=te();return p.createElement(bp,null,p.createElement(Nr.Provider,{value:i.panelId},x({ourProps:b,theirProps:l,slot:v,defaultTag:Jp,features:Qp,visible:f,name:"Disclosure.Panel"})))}let tm=Q(Yp),Di=Q(Xp),_i=Q(em),nm=Object.assign(tm,{Button:Di,Panel:_i}),Io=/([\u2700-\u27BF]|[\uE000-\uF8FF]|\uD83C[\uDC00-\uDFFF]|\uD83D[\uDC00-\uDFFF]|[\u2011-\u26FF]|\uD83E[\uDD10-\uDDFF])/g;function jo(e){var t,n;let r=(t=e.innerText)!=null?t:"",o=e.cloneNode(!0);if(!Ne(o))return r;let l=!1;for(let a of o.querySelectorAll('[hidden],[aria-hidden],[role="img"]'))a.remove(),l=!0;let i=l?(n=o.innerText)!=null?n:"":r;return Io.test(i)&&(i=i.replace(Io,"")),i}function rm(e){let t=e.getAttribute("aria-label");if(typeof t=="string")return t.trim();let n=e.getAttribute("aria-labelledby");if(n){let r=n.split(" ").map(o=>{let l=document.getElementById(o);if(l){let i=l.getAttribute("aria-label");return typeof i=="string"?i.trim():jo(l).trim()}return null}).filter(Boolean);if(r.length>0)return r.join(", ")}return jo(e).trim()}function om(e){let t=p.useRef(""),n=p.useRef("");return D(()=>{let r=e.current;if(!r)return"";let o=r.innerText;if(t.current===o)return n.current;let l=rm(r).trim().toLowerCase();return t.current=o,n.current=l,l})}var lm=Object.defineProperty,im=(e,t,n)=>t in e?lm(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Do=(e,t,n)=>(im(e,typeof t!="symbol"?t+"":t,n),n),re=(e=>(e[e.Open=0]="Open",e[e.Closed=1]="Closed",e))(re||{}),Be=(e=>(e[e.Single=0]="Single",e[e.Multi=1]="Multi",e))(Be||{}),Yt=(e=>(e[e.Pointer=0]="Pointer",e[e.Other=1]="Other",e))(Yt||{}),Bi=(e=>(e[e.OpenListbox=0]="OpenListbox",e[e.CloseListbox=1]="CloseListbox",e[e.GoToOption=2]="GoToOption",e[e.Search=3]="Search",e[e.ClearSearch=4]="ClearSearch",e[e.SelectOption=5]="SelectOption",e[e.RegisterOptions=6]="RegisterOptions",e[e.UnregisterOptions=7]="UnregisterOptions",e[e.SetButtonElement=8]="SetButtonElement",e[e.SetOptionsElement=9]="SetOptionsElement",e[e.SortOptions=10]="SortOptions",e[e.MarkButtonAsMoved=11]="MarkButtonAsMoved",e))(Bi||{});function _o(e,t=n=>n){let n=e.activeOptionIndex!==null?e.options[e.activeOptionIndex]:null,r=ai(t(e.options.slice()),l=>l.dataRef.current.domRef.current),o=n?r.indexOf(n):null;return o===-1&&(o=null),{options:r,activeOptionIndex:o}}let am={1(e){if(e.dataRef.current.disabled||e.listboxState===1)return e;let t=e.buttonElement?Kt.Tracked(Pi(e.buttonElement)):e.buttonPositionState;return{...e,activeOptionIndex:null,pendingFocus:{focus:Z.Nothing},listboxState:1,__demoMode:!1,buttonPositionState:t}},0(e,t){if(e.dataRef.current.disabled||e.listboxState===0)return e;let n=e.activeOptionIndex,{isSelected:r}=e.dataRef.current,o=e.options.findIndex(l=>r(l.dataRef.current.value));return o!==-1&&(n=o),{...e,frozenValue:!1,pendingFocus:t.focus,listboxState:0,activeOptionIndex:n,__demoMode:!1,buttonPositionState:Kt.Idle}},2(e,t){var n,r,o,l,i;if(e.dataRef.current.disabled||e.listboxState===1)return e;let a={...e,searchQuery:"",activationTrigger:(n=t.trigger)!=null?n:1,__demoMode:!1};if(t.focus===Z.Nothing)return{...a,activeOptionIndex:null};if(t.focus===Z.Specific)return{...a,activeOptionIndex:e.options.findIndex(c=>c.id===t.id)};if(t.focus===Z.Previous){let c=e.activeOptionIndex;if(c!==null){let d=e.options[c].dataRef.current.domRef,m=Wt(t,{resolveItems:()=>e.options,resolveActiveIndex:()=>e.activeOptionIndex,resolveId:f=>f.id,resolveDisabled:f=>f.dataRef.current.disabled});if(m!==null){let f=e.options[m].dataRef.current.domRef;if(((r=d.current)==null?void 0:r.previousElementSibling)===f.current||((o=f.current)==null?void 0:o.previousElementSibling)===null)return{...a,activeOptionIndex:m}}}}else if(t.focus===Z.Next){let c=e.activeOptionIndex;if(c!==null){let d=e.options[c].dataRef.current.domRef,m=Wt(t,{resolveItems:()=>e.options,resolveActiveIndex:()=>e.activeOptionIndex,resolveId:f=>f.id,resolveDisabled:f=>f.dataRef.current.disabled});if(m!==null){let f=e.options[m].dataRef.current.domRef;if(((l=d.current)==null?void 0:l.nextElementSibling)===f.current||((i=f.current)==null?void 0:i.nextElementSibling)===null)return{...a,activeOptionIndex:m}}}}let s=_o(e),u=Wt(t,{resolveItems:()=>s.options,resolveActiveIndex:()=>s.activeOptionIndex,resolveId:c=>c.id,resolveDisabled:c=>c.dataRef.current.disabled});return{...a,...s,activeOptionIndex:u}},3:(e,t)=>{if(e.dataRef.current.disabled||e.listboxState===1)return e;let n=e.searchQuery!==""?0:1,r=e.searchQuery+t.value.toLowerCase(),o=(e.activeOptionIndex!==null?e.options.slice(e.activeOptionIndex+n).concat(e.options.slice(0,e.activeOptionIndex+n)):e.options).find(i=>{var a;return!i.dataRef.current.disabled&&((a=i.dataRef.current.textValue)==null?void 0:a.startsWith(r))}),l=o?e.options.indexOf(o):-1;return l===-1||l===e.activeOptionIndex?{...e,searchQuery:r}:{...e,searchQuery:r,activeOptionIndex:l,activationTrigger:1}},4(e){return e.dataRef.current.disabled||e.listboxState===1||e.searchQuery===""?e:{...e,searchQuery:""}},5(e){return e.dataRef.current.mode===0?{...e,frozenValue:!0}:{...e}},6:(e,t)=>{let n=e.options.concat(t.options),r=e.activeOptionIndex;if(e.pendingFocus.focus!==Z.Nothing&&(r=Wt(e.pendingFocus,{resolveItems:()=>n,resolveActiveIndex:()=>e.activeOptionIndex,resolveId:o=>o.id,resolveDisabled:o=>o.dataRef.current.disabled})),e.activeOptionIndex===null){let{isSelected:o}=e.dataRef.current;if(o){let l=n.findIndex(i=>o?.(i.dataRef.current.value));l!==-1&&(r=l)}}return{...e,options:n,activeOptionIndex:r,pendingFocus:{focus:Z.Nothing},pendingShouldSort:!0}},7:(e,t)=>{let n=e.options,r=[],o=new Set(t.options);for(let[l,i]of n.entries())if(o.has(i.id)&&(r.push(l),o.delete(i.id),o.size===0))break;if(r.length>0){n=n.slice();for(let l of r.reverse())n.splice(l,1)}return{...e,options:n,activationTrigger:1}},8:(e,t)=>e.buttonElement===t.element?e:{...e,buttonElement:t.element},9:(e,t)=>e.optionsElement===t.element?e:{...e,optionsElement:t.element},10:e=>e.pendingShouldSort?{...e,..._o(e),pendingShouldSort:!1}:e,11(e){return e.buttonPositionState.kind!=="Tracked"?e:{...e,buttonPositionState:Kt.Moved}}};class Ir extends ei{constructor(t){super(t),Do(this,"actions",{onChange:n=>{let{onChange:r,compare:o,mode:l,value:i}=this.state.dataRef.current;return se(l,{0:()=>r?.(n),1:()=>{let a=i.slice(),s=a.findIndex(u=>o(u,n));return s===-1?a.push(n):a.splice(s,1),r?.(a)}})},registerOption:Mn(()=>{let n=[],r=new Set;return[(o,l)=>{r.has(l)||(r.add(l),n.push({id:o,dataRef:l}))},()=>(r.clear(),this.send({type:6,options:n.splice(0)}))]}),unregisterOption:Mn(()=>{let n=[];return[r=>n.push(r),()=>{this.send({type:7,options:n.splice(0)})}]}),goToOption:Mn(()=>{let n=null;return[(r,o)=>{n={type:2,...r,trigger:o}},()=>n&&this.send(n)]}),closeListbox:()=>{this.send({type:1})},openListbox:n=>{this.send({type:0,focus:n})},selectActiveOption:()=>{var n;if(this.state.activeOptionIndex!==null){let{dataRef:r}=this.state.options[this.state.activeOptionIndex];this.actions.selectOption(r.current.value)}else this.state.dataRef.current.mode===0&&(this.actions.closeListbox(),(n=this.state.buttonElement)==null||n.focus({preventScroll:!0}))},selectOption:n=>{this.send({type:5,value:n})},search:n=>{this.send({type:3,value:n})},clearSearch:()=>{this.send({type:4})},setButtonElement:n=>{this.send({type:8,element:n})},setOptionsElement:n=>{this.send({type:9,element:n})}}),Do(this,"selectors",{activeDescendantId(n){var r;let o=n.activeOptionIndex,l=n.options;return o===null||(r=l[o])==null?void 0:r.id},isActive(n,r){var o;let l=n.activeOptionIndex,i=n.options;return l!==null?((o=i[l])==null?void 0:o.id)===r:!1},hasFrozenValue(n){return n.frozenValue},shouldScrollIntoView(n,r){return n.__demoMode||n.listboxState!==0||n.activationTrigger===0?!1:this.isActive(n,r)},didButtonMove(n){return n.buttonPositionState.kind==="Moved"}}),this.on(6,()=>{requestAnimationFrame(()=>{this.send({type:10})})});{let n=this.state.id,r=Cr.get(null);this.disposables.add(r.on(ni.Push,o=>{!r.selectors.isTop(o,n)&&this.state.listboxState===0&&this.actions.closeListbox()})),this.on(0,()=>r.actions.push(n)),this.on(1,()=>r.actions.pop(n))}this.disposables.group(n=>{this.on(1,r=>{r.buttonElement&&(n.dispose(),n.add(Lp(r.buttonElement,r.buttonPositionState,()=>{this.send({type:11})})))})}),this.on(5,(n,r)=>{var o;this.actions.onChange(r.value),this.state.dataRef.current.mode===0&&(this.actions.closeListbox(),(o=this.state.buttonElement)==null||o.focus({preventScroll:!0}))})}static new({id:t,__demoMode:n=!1}){return new Ir({id:t,dataRef:{current:{}},listboxState:n?0:1,options:[],searchQuery:"",activeOptionIndex:null,activationTrigger:1,buttonElement:null,optionsElement:null,pendingShouldSort:!1,pendingFocus:{focus:Z.Nothing},frozenValue:!1,__demoMode:n,buttonPositionState:Kt.Idle})}reduce(t,n){return se(n.type,am,t,n)}}const Hi=p.createContext(null);function jr(e){let t=p.useContext(Hi);if(t===null){let n=new Error(`<${e} /> is missing a parent <Listbox /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,Vi),n}return t}function Vi({id:e,__demoMode:t=!1}){let n=p.useMemo(()=>Ir.new({id:e,__demoMode:t}),[]);return Ri(()=>n.dispose()),n}let En=p.createContext(null);En.displayName="ListboxDataContext";function At(e){let t=p.useContext(En);if(t===null){let n=new Error(`<${e} /> is missing a parent <Listbox /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,At),n}return t}let sm=p.Fragment;function um(e,t){let n=p.useId(),r=un(),{value:o,defaultValue:l,form:i,name:a,onChange:s,by:u,invalid:c=!1,disabled:d=r||!1,horizontal:m=!1,multiple:f=!1,__demoMode:h=!1,...v}=e;const b=m?"horizontal":"vertical";let x=ue(t),y=Ec(l),[w=f?[]:void 0,S]=yc(o,s,y),C=Vi({id:n,__demoMode:h}),T=p.useRef({static:!1,hold:!1}),O=p.useRef(new Map),k=Yc(u),A=p.useCallback(K=>se(R.mode,{[Be.Multi]:()=>w.some(_=>k(_,K)),[Be.Single]:()=>k(w,K)}),[w]),R=be({value:w,disabled:d,invalid:c,mode:f?Be.Multi:Be.Single,orientation:b,onChange:S,compare:k,isSelected:A,optionsPropsRef:T,listRef:O});X(()=>{C.state.dataRef.current=R},[R]);let M=ce(C,K=>K.listboxState),H=Cr.get(null),z=ce(H,p.useCallback(K=>H.selectors.isTop(K,n),[H,n])),[B,F]=ce(C,K=>[K.buttonElement,K.optionsElement]);Cd(z,[B,F],(K,_)=>{C.send({type:Bi.CloseListbox}),ii(_,Sr.Loose)||(K.preventDefault(),B?.focus())});let I=be({open:M===re.Open,disabled:d,invalid:c,value:w}),[U,$]=Hc({inherit:!0}),V={ref:x},q=p.useCallback(()=>{if(y!==void 0)return S?.(y)},[S,y]),pe=te();return p.createElement($,{value:U,props:{htmlFor:B?.id},slot:{open:M===re.Open,disabled:d}},p.createElement(mp,null,p.createElement(Hi.Provider,{value:C},p.createElement(En.Provider,{value:R},p.createElement(Lr,{value:se(M,{[re.Open]:ae.Open,[re.Closed]:ae.Closed})},a!=null&&w!=null&&p.createElement(Tc,{disabled:d,data:{[a]:w},form:i,onReset:q}),pe({ourProps:V,theirProps:v,slot:I,defaultTag:sm,name:"Listbox"}))))))}let cm="button";function dm(e,t){let n=p.useId(),r=Vl(),o=At("Listbox.Button"),l=jr("Listbox.Button"),{id:i=r||`headlessui-listbox-button-${n}`,disabled:a=o.disabled||!1,autoFocus:s=!1,...u}=e,c=ue(t,cp(),l.actions.setButtonElement),d=dp(),[m,f,h]=ce(l,F=>[F.listboxState,F.buttonElement,F.optionsElement]),v=m===re.Open;kd(v,{trigger:f,action:p.useCallback(F=>{if(f!=null&&f.contains(F.target))return Vt.Ignore;let I=F.target.closest('[role="option"]:not([data-disabled])');return Ne(I)?Vt.Select(I):h!=null&&h.contains(F.target)?Vt.Ignore:Vt.Close},[f,h]),close:l.actions.closeListbox,select:l.actions.selectActiveOption});let b=D(F=>{switch(F.key){case Y.Enter:Cc(F.currentTarget);break;case Y.Space:case Y.ArrowDown:F.preventDefault(),l.actions.openListbox({focus:o.value?Z.Nothing:Z.First});break;case Y.ArrowUp:F.preventDefault(),l.actions.openListbox({focus:o.value?Z.Nothing:Z.Last});break}}),x=D(F=>{F.key===Y.Space&&F.preventDefault()}),y=Xc(F=>{var I;l.state.listboxState===re.Open?(Ge.flushSync(()=>l.actions.closeListbox()),(I=l.state.buttonElement)==null||I.focus({preventScroll:!0})):(F.preventDefault(),l.actions.openListbox({focus:Z.Nothing}))}),w=D(F=>F.preventDefault()),S=Zl([i]),C=jc(),{isFocusVisible:T,focusProps:O}=xr({autoFocus:s}),{isHovered:k,hoverProps:A}=br({isDisabled:a}),{pressed:R,pressProps:M}=wr({disabled:a}),H=be({open:m===re.Open,active:R||m===re.Open,disabled:a,invalid:o.invalid,value:o.value,hover:k,focus:T,autofocus:s}),z=ce(l,F=>F.listboxState===re.Open),B=yt(d(),{ref:c,id:i,type:ui(e,f),"aria-haspopup":"listbox","aria-controls":h?.id,"aria-expanded":z,"aria-labelledby":S,"aria-describedby":C,disabled:a||void 0,autoFocus:s,onKeyDown:b,onKeyUp:x,onKeyPress:w},y,O,A,M);return te()({ourProps:B,theirProps:u,slot:H,defaultTag:cm,name:"Listbox.Button"})}let zi=p.createContext(!1),fm="div",pm=rt.RenderStrategy|rt.Static;function mm(e,t){let n=p.useId(),{id:r=`headlessui-listbox-options-${n}`,anchor:o,portal:l=!1,modal:i=!0,transition:a=!1,...s}=e,u=up(o),[c,d]=p.useState(null);u&&(l=!0);let m=At("Listbox.Options"),f=jr("Listbox.Options"),[h,v,b,x]=ce(f,N=>[N.listboxState,N.buttonElement,N.optionsElement,N.__demoMode]),y=tr(v),w=tr(b),S=bn(),[C,T]=kr(a,c,S!==null?(S&ae.Open)===ae.Open:h===re.Open);dd(C,v,f.actions.closeListbox);let O=x?!1:i&&h===re.Open;Fd(O,w);let k=x?!1:i&&h===re.Open;cd(k,{allowed:p.useCallback(()=>[v,b],[v,b])});let A=ce(f,f.selectors.didButtonMove)?!1:C,R=ce(f,f.selectors.hasFrozenValue)&&!e.static,M=ki(R,m.value),H=p.useCallback(N=>m.compare(M,N),[m.compare,M]),z=ce(f,N=>{var W;if(u==null||!((W=u?.to)!=null&&W.includes("selection")))return null;let xe=N.options.findIndex(he=>H(he.dataRef.current.value));return xe===-1&&(xe=0),xe}),B=(()=>{if(u==null)return;if(z===null)return{...u,inner:void 0};let N=Array.from(m.listRef.current.values());return{...u,inner:{listRef:{current:N},index:z}}})(),[F,I]=pp(B),U=fp(),$=ue(t,u?F:null,f.actions.setOptionsElement,d),V=Xe();p.useEffect(()=>{let N=b;N&&h===re.Open&&(uc(N)||N==null||N.focus({preventScroll:!0}))},[h,b]);let q=D(N=>{var W;switch(V.dispose(),N.key){case Y.Space:if(f.state.searchQuery!=="")return N.preventDefault(),N.stopPropagation(),f.actions.search(N.key);case Y.Enter:N.preventDefault(),N.stopPropagation(),f.actions.selectActiveOption();break;case se(m.orientation,{vertical:Y.ArrowDown,horizontal:Y.ArrowRight}):return N.preventDefault(),N.stopPropagation(),f.actions.goToOption({focus:Z.Next});case se(m.orientation,{vertical:Y.ArrowUp,horizontal:Y.ArrowLeft}):return N.preventDefault(),N.stopPropagation(),f.actions.goToOption({focus:Z.Previous});case Y.Home:case Y.PageUp:return N.preventDefault(),N.stopPropagation(),f.actions.goToOption({focus:Z.First});case Y.End:case Y.PageDown:return N.preventDefault(),N.stopPropagation(),f.actions.goToOption({focus:Z.Last});case Y.Escape:N.preventDefault(),N.stopPropagation(),Ge.flushSync(()=>f.actions.closeListbox()),(W=f.state.buttonElement)==null||W.focus({preventScroll:!0});return;case Y.Tab:N.preventDefault(),N.stopPropagation(),Ge.flushSync(()=>f.actions.closeListbox()),xd(f.state.buttonElement,N.shiftKey?er.Previous:er.Next);break;default:N.key.length===1&&(f.actions.search(N.key),V.setTimeout(()=>f.actions.clearSearch(),350));break}}),pe=ce(f,N=>{var W;return(W=N.buttonElement)==null?void 0:W.id}),K=be({open:h===re.Open}),_=yt(u?U():{},{id:r,ref:$,"aria-activedescendant":ce(f,f.selectors.activeDescendantId),"aria-multiselectable":m.mode===Be.Multi?!0:void 0,"aria-labelledby":pe,"aria-orientation":m.orientation,onKeyDown:q,role:"listbox",tabIndex:h===re.Open?0:void 0,style:{...s.style,...I,"--button-width":Zc(C,v,!0).width},...$r(T)}),ee=te(),me=p.useMemo(()=>m.mode===Be.Multi?m:{...m,isSelected:H},[m,H]);return p.createElement(Pp,{enabled:l?e.static||C:!1,ownerDocument:y},p.createElement(En.Provider,{value:me},ee({ourProps:_,theirProps:s,slot:K,defaultTag:fm,features:pm,visible:A,name:"Listbox.Options"})))}let hm="div";function gm(e,t){let n=p.useId(),{id:r=`headlessui-listbox-option-${n}`,disabled:o=!1,value:l,...i}=e,a=p.useContext(zi)===!0,s=At("Listbox.Option"),u=jr("Listbox.Option"),c=ce(u,R=>u.selectors.isActive(R,r)),d=s.isSelected(l),m=p.useRef(null),f=om(m),h=Je({disabled:o,value:l,domRef:m,get textValue(){return f()}}),v=ue(t,m,R=>{R?s.listRef.current.set(r,R):s.listRef.current.delete(r)}),b=ce(u,R=>u.selectors.shouldScrollIntoView(R,r));X(()=>{if(b)return fe().requestAnimationFrame(()=>{var R,M;(M=(R=m.current)==null?void 0:R.scrollIntoView)==null||M.call(R,{block:"nearest"})})},[b,m]),X(()=>{if(!a)return u.actions.registerOption(r,h),()=>u.actions.unregisterOption(r)},[h,r,a]);let x=D(R=>{if(o)return R.preventDefault();u.actions.selectOption(l)}),y=D(()=>{if(o)return u.actions.goToOption({focus:Z.Nothing});u.actions.goToOption({focus:Z.Specific,id:r})}),w=Md(),S=D(R=>w.update(R)),C=D(R=>{w.wasMoved(R)&&(o||c&&u.state.activationTrigger===Yt.Pointer||u.actions.goToOption({focus:Z.Specific,id:r},Yt.Pointer))}),T=D(R=>{w.wasMoved(R)&&(o||c&&u.state.activationTrigger===Yt.Pointer&&u.actions.goToOption({focus:Z.Nothing}))}),O=be({active:c,focus:c,selected:d,disabled:o,selectedOption:d&&a}),k=a?{}:{id:r,ref:v,role:"option",tabIndex:o===!0?void 0:-1,"aria-disabled":o===!0?!0:void 0,"aria-selected":d,disabled:void 0,onClick:x,onFocus:y,onPointerEnter:S,onMouseEnter:S,onPointerMove:C,onMouseMove:C,onPointerLeave:T,onMouseLeave:T},A=te();return!d&&a?null:A({ourProps:k,theirProps:i,slot:O,defaultTag:hm,name:"Listbox.Option"})}let vm=p.Fragment;function bm(e,t){let{options:n,placeholder:r,...o}=e,l={ref:ue(t)},i=At("ListboxSelectedOption"),a=be({}),s=i.value===void 0||i.value===null||i.mode===Be.Multi&&Array.isArray(i.value)&&i.value.length===0,u=te();return p.createElement(zi.Provider,{value:!0},u({ourProps:l,theirProps:{...o,children:p.createElement(p.Fragment,null,r&&s?r:n)},slot:a,defaultTag:vm,name:"ListboxSelectedOption"}))}let xm=Q(um),Wi=Q(dm),wm=Uc,Ui=Q(mm),qi=Q(gm),ym=Q(bm),Em=Object.assign(xm,{Button:Wi,Label:wm,Options:Ui,Option:qi,SelectedOption:ym});function Gi({children:e,className:t,disabled:n=!1,intent:r="primary",...o}){return E.jsx(wc,{className:ie("rounded-md font-bold cursor-pointer px-2",Cm(r,!!n),{"opacity-50 cursor-default":n},t),"data-focus":!0,disabled:n,...o,children:e})}function Cm(e,t){switch(e){case"danger":return ie("bg-red-400 text-red-950 focus:text-black",{"hover:bg-red-500 focus:text-black":!t});case"none":return ie("bg-white/20 text-slate-300 focus:text-white",{"hover:bg-white/10 focus:text-white":!t});case"success":return ie("bg-emerald-400 text-emerald-950 focus:text-black",{"hover:bg-emerald-500 focus:text-black":!t});case"primary":return ie("bg-sky-400 text-sky-950 focus:text-black",{"hover:bg-sky-500 focus:text-black":!t});case"warning":return ie("bg-amber-400 text-amber-950 focus:text-black",{"hover:bg-amber-500 focus:text-black":!t})}}function Dr({children:e}){return E.jsx(Nu,{FallbackComponent:Sm,children:e})}function Sm({error:e,resetErrorBoundary:t}){return E.jsx(pr,{intent:"danger",children:E.jsxs(le,{align:"start",direction:"column",gap:2,children:[E.jsx("div",{className:"font-bold",children:"Something went wrong!"}),E.jsx("pre",{className:"text-sm font-monospace text-red-300",children:e.message}),E.jsx(Gi,{intent:"danger",onClick:t,children:"Retry"})]})})}function $t({children:e,className:t,href:n,target:r="_blank",...o}){return E.jsx("a",{className:t,href:n,target:r,rel:"noopener noreferrer",...o,children:e})}function on({children:e,onClick:t,to:n,...r}){const o=!!za(n),[l,i]=p.useTransition(),a=Qo();return E.jsx("span",{children:typeof e=="function"?e({isActive:o,isPending:l}):e,"data-link":!0,onClick:s=>{t?.(s),i(()=>{a(n)})},...r})}function $m({children:e}){return E.jsx("div",{className:"w-full shrink-0 flex flex-col gap-4 py-4 overflow-y-auto",children:e})}function km(){const{hide:e}=cl(),{pathname:t}=Fe();return p.useLayoutEffect(()=>{e();const n=document.body.querySelector("[data-main-scrollable]");if(n){const r=setTimeout(()=>{n.scrollTo(0,0)},1);return()=>{clearTimeout(r)}}},[e,t]),null}const Rm={"*":p.lazy(()=>Promise.resolve().then(()=>require("./PageNotFound-CrHjMQNv.cjs"))),"/":p.lazy(()=>Promise.resolve().then(()=>require("./GettingStartedRoute-BJh6Q9Fv.cjs"))),"/support":p.lazy(()=>Promise.resolve().then(()=>require("./SupportRoute-Bww0QSix.cjs")))};function Om({hideVersions:e=!1,navLinks:t,overview:n,packageDescription:r,packageName:o,routes:l,showOpenCollectLink:i=!1}){const{toggle:a,visible:s}=cl(),u=p.useMemo(()=>({overview:n,packageName:o,showOpenCollectLink:i}),[n,o,i]);return E.jsx(ul.Provider,{value:u,children:E.jsxs(Os,{children:[E.jsx(km,{}),E.jsxs("div",{className:"h-full w-full max-w-350 mx-auto flex flex-col",children:[E.jsxs(le,{align:"center",className:"h-12 w-full p-4",direction:"row",justify:"between",gap:4,children:[E.jsxs(le,{className:"overflow-hidden",align:"center",direction:"row",gap:4,children:[E.jsx(on,{children:o,className:"text-xl text-white! text-shadow-black/80 text-shadow-xs font-bold cursor-pointer truncate",to:"/"}),E.jsx("div",{className:"hidden md:block text-black text-shadow-white/50 text-shadow-xs",children:r})]}),E.jsxs(le,{align:"center",direction:"row",gap:4,children:[e||E.jsx(on,{"aria-label":"Documentation for other versions",className:"text-xs font-bold text-white! drop-shadow-black/20 drop-shadow-sm cursor-pointer",title:"Past releases",to:"/versions",children:E.jsx(Bs,{className:"w-6 h-6"})}),E.jsx($t,{"aria-label":"NPM project page",className:"text-white! drop-shadow-black/20 drop-shadow-sm",href:`https://www.npmjs.com/package/${o}`,title:"NPM package",children:E.jsx(_s,{className:"w-8 h-8"})}),E.jsx($t,{"aria-label":"GitHub project page",className:"text-white! drop-shadow-black/20 drop-shadow-sm",href:`https://github.com/bvaughn/${o}`,title:"Source code",children:E.jsx(Ds,{className:"w-6 h-6"})}),E.jsx("button",{"aria-label":"Site navigation menu",className:ie("block md:hidden cursor-pointer rounded-lg p-1",{"bg-black/40":!s,"bg-black/50 text-white":s}),onClick:a,children:s?E.jsx(pa,{className:"w-6 h-6 fill-current drop-shadow-black/20 drop-shadow-xs"}):E.jsx(na,{className:"w-6 h-6 fill-current drop-shadow-black/20 drop-shadow-xs"})})]})]}),E.jsxs("div",{className:"grow shrink flex flex-row shadow-lg mx-2 rounded-t-3xl overflow-hidden",children:[E.jsx("section",{className:ie("w-full bg-black/90 md:block md:w-80 md:bg-black/80 overflow-auto",{hidden:!s}),children:E.jsx($m,{children:t})}),E.jsx("main",{className:ie("w-full bg-black/90 relative overflow-auto",{hidden:s}),children:E.jsx("div",{className:"h-full p-4 py-4 overflow-auto [mask-image:linear-gradient(to_bottom,transparent,black_1.5rem)]","data-main-scrollable":!0,children:E.jsx(ls,{children:Object.entries({...Rm,...l}).map(([c,d])=>E.jsx(nl,{element:E.jsx(Dr,{children:E.jsx(d,{})},c),path:c},c))})})})]})]})]})})}function Tm({children:e,className:t,...n}){return E.jsx(Dr,{children:E.jsx("div",{className:`border-lg bg-black/30 text-slate-300 rounded-lg p-2 ${t}`,...n,children:e})})}const Pm=e=>g.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",height:"24px",viewBox:"0 -960 960 960",width:"24px",fill:"currentColor",...e},g.createElement("path",{d:"m424-424-86-86q-11-11-28-11t-28 11q-11 11-11 28t11 28l114 114q12 12 28 12t28-12l226-226q11-11 11-28t-11-28q-11-11-28-11t-28 11L424-424ZM200-120q-33 0-56.5-23.5T120-200v-560q0-33 23.5-56.5T200-840h560q33 0 56.5 23.5T840-760v560q0 33-23.5 56.5T760-120H200Z"})),Lm=e=>g.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",height:"24px",viewBox:"0 -960 960 960",width:"24px",fill:"currentColor",...e},g.createElement("path",{d:"M320-440h320q17 0 28.5-11.5T680-480q0-17-11.5-28.5T640-520H320q-17 0-28.5 11.5T280-480q0 17 11.5 28.5T320-440ZM200-120q-33 0-56.5-23.5T120-200v-560q0-33 23.5-56.5T200-840h560q33 0 56.5 23.5T840-760v560q0 33-23.5 56.5T760-120H200Z"})),Am=e=>g.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",height:"24px",viewBox:"0 -960 960 960",width:"24px",fill:"currentColor",...e},g.createElement("path",{d:"M200-120q-33 0-56.5-23.5T120-200v-560q0-33 23.5-56.5T200-840h560q33 0 56.5 23.5T840-760v560q0 33-23.5 56.5T760-120H200Z"}));function Fm({checked:e,children:t,className:n,indeterminate:r,onChange:o,...l}){let i,a;return r?(i=Lm,a="fill-white"):e?(i=Pm,a="fill-blue-600"):(i=Am,a="fill-slate-600"),E.jsxs("label",{className:`cursor-pointer rounded-lg flex flex-row items-center outline-none group ${n}`,"data-focus-within":!0,...l,children:[E.jsx("input",{checked:e,className:"w-0 h-0",onChange:s=>{o(s.currentTarget.checked)},type:"checkbox"}),E.jsx(i,{className:a}),t&&E.jsxs(E.Fragment,{children:[" ",t]})]})}function _r({className:e="",html:t}){return E.jsx("div",{className:"relative",children:E.jsx("code",{className:ie("text-sm md:text-base block text-left whitespace-pre-wrap break-normal text-white! rounded-md p-3 bg-black","flex flex-col",e),dangerouslySetInnerHTML:{__html:t}})})}function Ft({className:e,sections:t}){return E.jsx(le,{className:e,direction:"column",gap:2,children:t.map(({content:n,intent:r},o)=>r?E.jsx(pr,{html:!0,inline:!0,intent:r,minimal:!0,children:n},o):E.jsx("div",{dangerouslySetInnerHTML:{__html:n.replaceAll("<ul>",'<ul class="list-disc pl-4">')}},o))})}const Ki={url:"https://github.com/bvaughn/react-lib-tools.git"};function Yi(e,t="Assertion error"){if(!e)throw Error(t)}function Zi(){const e=p.useContext(ul);return Yi(e,"App must be rendered within a LibraryContextProvider"),e}function Br({section:e,title:t}){const{packageName:n}=Zi();return p.useEffect(()=>{const r=document.title;return document.title=`${n}: ${e?`${e}: ${t}`:t}`,()=>{document.title=r}}),E.jsxs(le,{align:"center",direction:"row",gap:2,wrap:!0,children:[e&&E.jsxs(E.Fragment,{children:[E.jsx("div",{className:"text-xl whitespace-nowrap",children:e}),E.jsx(Vo,{className:"size-4 text-slate-400"})]}),E.jsx("div",{className:"text-xl whitespace-nowrap",children:t})]})}function Mm({method:e}){return E.jsxs(E.Fragment,{children:[E.jsx("dd",{className:"[&_code]:text-sky-300 text-lg font-bold",children:e.name}),E.jsxs("dt",{className:"mt-2",children:[E.jsx(Ft,{sections:e.description}),E.jsx(_r,{className:"mt-2 p-2 flex flex-col",html:e.html})]})]})}function Nm({json:e,section:t}){return E.jsxs(le,{direction:"column",gap:4,children:[E.jsxs(le,{align:"center",direction:"row",gap:2,wrap:!0,children:[E.jsx(Br,{section:t,title:`${e.name}`}),E.jsx($t,{className:"text-sm text-emerald-300 hover:text-white",href:`${Ki.url.replace(".git","")}/blob/main/${e.filePath}`,children:E.jsx(Ho,{className:"inline-block size-4 fill-current"})})]}),E.jsx(Ft,{sections:e.description}),E.jsx(le,{direction:"column",children:E.jsx("dl",{className:"flex flex-col gap-2",children:e.methods.map((n,r)=>E.jsx(Mm,{method:n},r))})})]})}function Im({children:e,className:t,onChange:n,value:r,...o}){return E.jsx("input",{className:`rounded-md bg-black/30 border border-2 border-transparent py-1 px-2 outline-none focus:border-emerald-300 ${t}`,"data-focus":!0,onChange:l=>{n(l.currentTarget.value)},value:r,...o,children:e})}function jm(){return E.jsxs(le,{align:"center",className:"text-slate-300",direction:"row",gap:2,children:[E.jsx(Qi,{className:"size-4 animate-spin"}),"Loading..."]})}function Xi({children:e,className:t,disabled:n}){return E.jsx(le,{align:"center",className:ie("px-4 h-8 cursor-pointer text-white/90 hover:text-white focus:bg-white/10 focus-within:bg-white/10",{"pointer-events-none text-white/50":n},t),direction:"row",gap:1,children:e})}function Dm({children:e,className:t,path:n}){return E.jsx(on,{to:n,children:({isActive:r,isPending:o})=>E.jsx(Xi,{className:ie("px-4 cursor-pointer",{"font-bold text-nav-active hover:text-nav-hover":r,"opacity-50 pointer-events-none":o},t),children:E.jsx(le,{align:"center",direction:"row",gap:2,children:e})})})}function _m({children:e,label:t}){return E.jsxs(nm,{as:"section",defaultOpen:!0,children:[E.jsx(Di,{className:"w-full group border-none! data-focus:bg-white/10",children:E.jsxs(Xi,{children:[E.jsx("div",{className:"uppercase text-sm font-bold text-white/50",children:t}),E.jsx("div",{className:"grow"}),E.jsx(Vo,{className:"size-4 fill-white/60 group-data-hover:fill-white/50 group-data-open:rotate-90"})]})}),E.jsx(_i,{className:"pl-4",children:e})]})}function Bm(e){const t=[],n=[];return Object.values(e.props).forEach(r=>{r.required?n.push(r):t.push(r)}),t.sort((r,o)=>r.name.localeCompare(o.name)),n.sort((r,o)=>r.name.localeCompare(o.name)),{optionalProps:t,requiredProps:n}}function Hm({prop:e}){return E.jsxs(E.Fragment,{children:[E.jsx("dt",{className:"mt-6 pl-8 indent-[-1rem]",children:E.jsx(_r,{className:"bg-transparent inline-flex flex-col p-0",html:e.html})}),E.jsx("dd",{className:"mt-2 pl-4 [&_code]:text-sky-300",children:E.jsx(Ft,{sections:e.description})})]})}function ir({header:e,props:t}){return t.length===0?null:E.jsxs(le,{direction:"column",children:[E.jsx("div",{className:"text-lg font-bold",children:e}),E.jsx("dl",{children:t.map(n=>E.jsx(Hm,{prop:n},n.name))})]})}function Vm({json:e,section:t}){const{optionalProps:n,requiredProps:r}=p.useMemo(()=>Bm(e),[e]);return E.jsxs(le,{direction:"column",gap:4,children:[E.jsxs(le,{align:"center",direction:"row",gap:2,wrap:!0,children:[E.jsx(Br,{section:t,title:`${e.name} component`}),E.jsx($t,{className:"text-sm text-emerald-300 hover:text-white",href:`${Ki.url.replace(".git","")}/blob/main/${e.filePath}`,children:E.jsx(Ho,{className:"inline-block size-4 fill-current"})})]}),E.jsx(Ft,{sections:e.description}),E.jsx(ir,{header:"Required props",props:r}),E.jsx(ir,{header:"Optional props",props:n})]})}const zm=e=>g.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",height:"24px",viewBox:"0 -960 960 960",width:"24px",fill:"currentColor",...e},g.createElement("path",{d:"m424-408-86-86q-11-11-28-11t-28 11q-11 11-11 28t11 28l114 114q12 12 28 12t28-12l226-226q11-11 11-28t-11-28q-11-11-28-11t-28 11L424-408Zm56 328q-83 0-156-31.5T197-197q-54-54-85.5-127T80-480q0-83 31.5-156T197-763q54-54 127-85.5T480-880q83 0 156 31.5T763-763q54 54 85.5 127T880-480q0 83-31.5 156T763-197q-54 54-127 85.5T480-80Z"})),Wm=e=>g.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",height:"24px",viewBox:"0 -960 960 960",width:"24px",fill:"currentColor",...e},g.createElement("path",{d:"M480-80q-83 0-156-31.5T197-197q-54-54-85.5-127T80-480q0-83 31.5-156T197-763q54-54 127-85.5T480-880q83 0 156 31.5T763-763q54 54 85.5 127T880-480q0 83-31.5 156T763-197q-54 54-127 85.5T480-80Z"}));function Um({checked:e,children:t,className:n,name:r,onChange:o,value:l,...i}){let a,s;return e?(a=zm,s="fill-blue-600"):(a=Wm,s="fill-slate-600"),E.jsxs("label",{className:`cursor-pointer rounded-full flex flex-row items-center outline-none group ${n}`,"data-focus-within":!0,...i,children:[E.jsx("input",{checked:e,className:"w-0 h-0",name:r,onChange:()=>{o(l)},type:"radio",value:l}),E.jsx(a,{className:s}),t&&E.jsxs(E.Fragment,{children:[" ",t]})]})}function qm({className:e,defaultValue:t,onChange:n,options:r,placeholder:o="",value:l}){return E.jsx(Em,{value:l??t,onChange:n,children:E.jsxs("div",{className:`relative ${e}`,children:[E.jsxs(Wi,{className:"w-full h-9 text-left rounded-md bg-black/30 border border-2 border-transparent py-1 px-2 outline-none focus:border-teal-300","data-focus":!0,children:[l?.label?E.jsx("span",{className:"block truncate",children:l.label}):E.jsx("span",{className:"block truncate text-slate-500",children:o}),E.jsx("span",{className:"pointer-events-none absolute inset-y-0 right-0 flex items-center pr-2",children:E.jsx(aa,{className:"h-4 w-4 text-gray-400","aria-hidden":"true"})})]}),E.jsx(Hp,{as:p.Fragment,leave:"transition ease-in duration-100",leaveFrom:"opacity-100",leaveTo:"opacity-0",children:E.jsx(Ui,{className:"absolute z-10 mt-1 max-h-50 w-full overflow-auto rounded-md py-1 bg-black/90","data-focus":!0,children:r.map((i,a)=>E.jsx(qi,{className:ie("relative cursor-pointer select-none h-7 py-1 px-2 text-slate-300 border-none!","data-focus:text-teal-300 data-focus:bg-black","data-active:text-teal-300 data-active:bg-black","data-selected:text-teal-300 data-selected:font-bold"),value:i,children:i.label},a))})})]})})}function Gm(e,t){switch(e){case"danger":return t?"bg-red-950 text-red-300 [&_svg]:text-red-500":"bg-black/10 bg-border border-2 border-red-500 text-white [&_svg]:text-red-500 [&_a]:text-red-400!";case"none":return t?"bg-white/10 text-slate-300 [&_svg]:text-slate-400":"bg-black/10 bg-border border-2 border-white/40 text-white [&_svg]:text-white/60";case"primary":return t?"bg-sky-950 text-sky-300 [&_svg]:text-sky-400":"bg-black/10 bg-border border-2 border-sky-400 text-white [&_svg]:text-sky-400";case"success":return t?"bg-emerald-950 text-emerald-300 [&_svg]:text-emerald-400":"bg-black/10 bg-border border-2 border-emerald-400 text-white [&_svg]:text-emerald-400";case"warning":return t?"bg-amber-950/65 text-amber-200 [&_svg]:text-amber-300":"bg-black/10 bg-border border-2 border-amber-400 text-white [&_svg]:text-amber-400 [&_a]:text-amber-400!"}}exports.AppRoot=Om;exports.Block=Tm;exports.Box=le;exports.Button=Gi;exports.Callout=pr;exports.Checkbox=Fm;exports.Code=_r;exports.ComponentProps=Vm;exports.ComponentPropsSection=ir;exports.DocsSection=Ft;exports.ErrorBoundary=Dr;exports.ExternalLink=$t;exports.Header=Br;exports.ImperativeHandle=Nm;exports.Input=Im;exports.Link=on;exports.LoadingSpinner=jm;exports.NavLink=Dm;exports.NavSection=_m;exports.Radio=Um;exports.Select=qm;exports.assert=Yi;exports.cn=ie;exports.getIntentClassNames=Gm;exports.useLibraryContext=Zi;
|
|
8
|
-
//# sourceMappingURL=index-
|
|
6
|
+
`))}else{let m=c.props,f=m?.className,h=typeof f=="function"?(...x)=>Zn(f(...x),s.className):Zn(f,s.className),v=h?{className:h}:{},b=Dl(c.props,je(Ln(s,["ref"])));for(let x in d)x in b&&delete d[x];return p.cloneElement(c,Object.assign({},b,d,u,{ref:o(gc(c),u.ref)},v))}return p.createElement(l,Object.assign({},Ln(s,["ref"]),!tt(l)&&u,!tt(l)&&d),c)}function mc(){let e=p.useRef([]),t=p.useCallback(n=>{for(let r of e.current)r!=null&&(typeof r=="function"?r(n):r.current=n)},[]);return(...n)=>{if(!n.every(r=>r==null))return e.current=n,t}}function hc(...e){return e.every(t=>t==null)?void 0:t=>{for(let n of e)n!=null&&(typeof n=="function"?n(t):n.current=t)}}function Dl(...e){if(e.length===0)return{};if(e.length===1)return e[0];let t={},n={};for(let r of e)for(let o in r)o.startsWith("on")&&typeof r[o]=="function"?(n[o]!=null||(n[o]=[]),n[o].push(r[o])):t[o]=r[o];if(t.disabled||t["aria-disabled"])for(let r in n)/^(on(?:Click|Pointer|Mouse|Key)(?:Down|Up|Press)?)$/.test(r)&&(n[r]=[o=>{var l;return(l=o?.preventDefault)==null?void 0:l.call(o)}]);for(let r in n)Object.assign(t,{[r](o,...l){let i=n[r];for(let a of i){if((o instanceof Event||o?.nativeEvent instanceof Event)&&o.defaultPrevented)return;a(o,...l)}}});return t}function yt(...e){if(e.length===0)return{};if(e.length===1)return e[0];let t={},n={};for(let r of e)for(let o in r)o.startsWith("on")&&typeof r[o]=="function"?(n[o]!=null||(n[o]=[]),n[o].push(r[o])):t[o]=r[o];for(let r in n)Object.assign(t,{[r](...o){let l=n[r];for(let i of l)i?.(...o)}});return t}function Q(e){var t;return Object.assign(p.forwardRef(e),{displayName:(t=e.displayName)!=null?t:e.name})}function je(e){let t=Object.assign({},e);for(let n in t)t[n]===void 0&&delete t[n];return t}function Ln(e,t=[]){let n=Object.assign({},e);for(let r of t)r in n&&delete n[r];return n}function gc(e){return p.version.split(".")[0]>="19"?e.props.ref:e.ref}function tt(e){return e===p.Fragment||e===Symbol.for("react.fragment")}function vc(e){return tt(e.type)}let bc="button";function xc(e,t){var n;let r=un(),{disabled:o=r||!1,autoFocus:l=!1,...i}=e,{isFocusVisible:a,focusProps:s}=xr({autoFocus:l}),{isHovered:u,hoverProps:c}=br({isDisabled:o}),{pressed:d,pressProps:m}=wr({disabled:o}),f=yt({ref:t,type:(n=i.type)!=null?n:"button",disabled:o||void 0,autoFocus:l},s,c,m),h=be({disabled:o,hover:u,focus:a,active:d,autofocus:l});return te()({ourProps:f,theirProps:i,slot:h,defaultTag:bc,name:"Button"})}let wc=Q(xc);function yc(e,t,n){let[r,o]=p.useState(n),l=e!==void 0,i=p.useRef(l),a=p.useRef(!1),s=p.useRef(!1);return l&&!i.current&&!a.current?(a.current=!0,i.current=l,console.error("A component is changing from uncontrolled to controlled. This may be caused by the value changing from undefined to a defined value, which should not happen.")):!l&&i.current&&!s.current&&(s.current=!0,i.current=l,console.error("A component is changing from controlled to uncontrolled. This may be caused by the value changing from a defined value to undefined, which should not happen.")),[l?e:r,D(u=>(l||Ge.flushSync(()=>o(u)),t?.(u)))]}function Ec(e){let[t]=p.useState(e);return t}function _l(e={},t=null,n=[]){for(let[r,o]of Object.entries(e))Hl(n,Bl(t,r),o);return n}function Bl(e,t){return e?e+"["+t+"]":t}function Hl(e,t,n){if(Array.isArray(n))for(let[r,o]of n.entries())Hl(e,Bl(t,r.toString()),o);else n instanceof Date?e.push([t,n.toISOString()]):typeof n=="boolean"?e.push([t,n?"1":"0"]):typeof n=="string"?e.push([t,n]):typeof n=="number"?e.push([t,`${n}`]):n==null?e.push([t,""]):Sc(n)&&!p.isValidElement(n)&&_l(n,t,e)}function Cc(e){var t,n;let r=(t=e?.form)!=null?t:e.closest("form");if(r){for(let o of r.elements)if(o!==e&&(o.tagName==="INPUT"&&o.type==="submit"||o.tagName==="BUTTON"&&o.type==="submit"||o.nodeName==="INPUT"&&o.type==="image")){o.click();return}(n=r.requestSubmit)==null||n.call(r)}}function Sc(e){if(Object.prototype.toString.call(e)!=="[object Object]")return!1;let t=Object.getPrototypeOf(e);return t===null||Object.getPrototypeOf(t)===null}let $c="span";var yr=(e=>(e[e.None=1]="None",e[e.Focusable=2]="Focusable",e[e.Hidden=4]="Hidden",e))(yr||{});function kc(e,t){var n;let{features:r=1,...o}=e,l={ref:t,"aria-hidden":(r&2)===2?!0:(n=o["aria-hidden"])!=null?n:void 0,hidden:(r&4)===4?!0:void 0,style:{position:"fixed",top:1,left:1,width:1,height:0,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0",...(r&4)===4&&(r&2)!==2&&{display:"none"}}};return te()({ourProps:l,theirProps:o,slot:{},defaultTag:$c,name:"Hidden"})}let Vl=Q(kc),Rc=p.createContext(null);function Oc({children:e}){let t=p.useContext(Rc);if(!t)return p.createElement(p.Fragment,null,e);let{target:n}=t;return n?Ge.createPortal(p.createElement(p.Fragment,null,e),n):null}function Tc({data:e,form:t,disabled:n,onReset:r,overrides:o}){let[l,i]=p.useState(null),a=Xe();return p.useEffect(()=>{if(r&&l)return a.addEventListener(l,"reset",r)},[l,t,r]),p.createElement(Oc,null,p.createElement(Pc,{setForm:i,formId:t}),_l(e).map(([s,u])=>p.createElement(Vl,{features:yr.Hidden,...je({key:s,as:"input",type:"hidden",hidden:!0,readOnly:!0,form:t,disabled:n,name:s,value:u,...o})})))}function Pc({setForm:e,formId:t}){return p.useEffect(()=>{if(t){let n=document.getElementById(t);n&&e(n)}},[e,t]),t?null:p.createElement(Vl,{features:yr.Hidden,as:"input",type:"hidden",hidden:!0,readOnly:!0,ref:n=>{if(!n)return;let r=n.closest("form");r&&e(r)}})}let Lc=p.createContext(void 0);function zl(){return p.useContext(Lc)}function Wl(e){return typeof e!="object"||e===null?!1:"nodeType"in e}function cn(e){return Wl(e)&&"tagName"in e}function Ne(e){return cn(e)&&"accessKey"in e}function _e(e){return cn(e)&&"tabIndex"in e}function Ac(e){return cn(e)&&"style"in e}function Fc(e){return Ne(e)&&e.nodeName==="IFRAME"}function Ul(e){return Ne(e)&&e.nodeName==="INPUT"}function to(e){return Ne(e)&&e.nodeName==="LABEL"}function Mc(e){return Ne(e)&&e.nodeName==="FIELDSET"}function ql(e){return Ne(e)&&e.nodeName==="LEGEND"}function Nc(e){return cn(e)?e.matches('a[href],audio[controls],button,details,embed,iframe,img[usemap],input:not([type="hidden"]),label,select,textarea,video[controls]'):!1}function Xn(e){let t=e.parentElement,n=null;for(;t&&!Mc(t);)ql(t)&&(n=t),t=t.parentElement;let r=t?.getAttribute("disabled")==="";return r&&Ic(n)?!1:r}function Ic(e){if(!e)return!1;let t=e.previousElementSibling;for(;t!==null;){if(ql(t))return!1;t=t.previousElementSibling}return!0}let Gl=Symbol();function Kl(e,t=!0){return Object.assign(e,{[Gl]:t})}function ue(...e){let t=p.useRef(e);p.useEffect(()=>{t.current=e},[e]);let n=D(r=>{for(let o of t.current)o!=null&&(typeof o=="function"?o(r):o.current=r)});return e.every(r=>r==null||r?.[Gl])?void 0:n}let Er=p.createContext(null);Er.displayName="DescriptionContext";function Yl(){let e=p.useContext(Er);if(e===null){let t=new Error("You used a <Description /> component, but it is not inside a relevant parent.");throw Error.captureStackTrace&&Error.captureStackTrace(t,Yl),t}return e}function jc(){var e,t;return(t=(e=p.useContext(Er))==null?void 0:e.value)!=null?t:void 0}let Dc="p";function _c(e,t){let n=p.useId(),r=un(),{id:o=`headlessui-description-${n}`,...l}=e,i=Yl(),a=ue(t);X(()=>i.register(o),[o,i.register]);let s=be({...i.slot,disabled:r||!1}),u={ref:a,...i.props,id:o};return te()({ourProps:u,theirProps:l,slot:s,defaultTag:Dc,name:i.name||"Description"})}let Bc=Q(_c);Object.assign(Bc,{});var Y=(e=>(e.Space=" ",e.Enter="Enter",e.Escape="Escape",e.Backspace="Backspace",e.Delete="Delete",e.ArrowLeft="ArrowLeft",e.ArrowUp="ArrowUp",e.ArrowRight="ArrowRight",e.ArrowDown="ArrowDown",e.Home="Home",e.End="End",e.PageUp="PageUp",e.PageDown="PageDown",e.Tab="Tab",e))(Y||{});let dn=p.createContext(null);dn.displayName="LabelContext";function Zl(){let e=p.useContext(dn);if(e===null){let t=new Error("You used a <Label /> component, but it is not inside a relevant parent.");throw Error.captureStackTrace&&Error.captureStackTrace(t,Zl),t}return e}function Xl(e){var t,n,r;let o=(n=(t=p.useContext(dn))==null?void 0:t.value)!=null?n:void 0;return((r=e?.length)!=null?r:0)>0?[o,...e].filter(Boolean).join(" "):o}function Hc({inherit:e=!1}={}){let t=Xl(),[n,r]=p.useState([]),o=e?[t,...n].filter(Boolean):n;return[o.length>0?o.join(" "):void 0,p.useMemo(()=>function(l){let i=D(s=>(r(u=>[...u,s]),()=>r(u=>{let c=u.slice(),d=c.indexOf(s);return d!==-1&&c.splice(d,1),c}))),a=p.useMemo(()=>({register:i,slot:l.slot,name:l.name,props:l.props,value:l.value}),[i,l.slot,l.name,l.props,l.value]);return p.createElement(dn.Provider,{value:a},l.children)},[r])]}let Vc="label";function zc(e,t){var n;let r=p.useId(),o=Zl(),l=zl(),i=un(),{id:a=`headlessui-label-${r}`,htmlFor:s=l??((n=o.props)==null?void 0:n.htmlFor),passive:u=!1,...c}=e,d=ue(t);X(()=>o.register(a),[a,o.register]);let m=D(v=>{let b=v.currentTarget;if(!(v.target!==v.currentTarget&&Nc(v.target))&&(to(b)&&v.preventDefault(),o.props&&"onClick"in o.props&&typeof o.props.onClick=="function"&&o.props.onClick(v),to(b))){let x=document.getElementById(b.htmlFor);if(x){let y=x.getAttribute("disabled");if(y==="true"||y==="")return;let w=x.getAttribute("aria-disabled");if(w==="true"||w==="")return;(Ul(x)&&(x.type==="file"||x.type==="radio"||x.type==="checkbox")||x.role==="radio"||x.role==="checkbox"||x.role==="switch")&&x.click(),x.focus({preventScroll:!0})}}}),f=be({...o.slot,disabled:i||!1}),h={ref:d,...o.props,id:a,htmlFor:s,onClick:m};return u&&("onClick"in h&&(delete h.htmlFor,delete h.onClick),"onClick"in c&&delete c.onClick),te()({ourProps:h,theirProps:c,slot:f,defaultTag:s?Vc:"div",name:o.name||"Label"})}let Wc=Q(zc),Uc=Object.assign(Wc,{}),qc=p.createContext(()=>{});function Gc({value:e,children:t}){return p.createElement(qc.Provider,{value:e},t)}function Kc(e,t){return e!==null&&t!==null&&typeof e=="object"&&typeof t=="object"&&"id"in e&&"id"in t?e.id===t.id:e===t}function Yc(e=Kc){return p.useCallback((t,n)=>{if(typeof e=="string"){let r=e;return t?.[r]===n?.[r]}return e(t,n)},[e])}function no(e){if(e===null)return{width:0,height:0};let{width:t,height:n}=e.getBoundingClientRect();return{width:t,height:n}}function Zc(e,t,n=!1){let[r,o]=p.useState(()=>no(t));return X(()=>{if(!t||!e)return;let l=fe();return l.requestAnimationFrame(function i(){l.requestAnimationFrame(i),o(a=>{let s=no(t);return s.width===a.width&&s.height===a.height?a:s})}),()=>{l.dispose()}},[t,e]),n?{width:`${r.width}px`,height:`${r.height}px`}:r}var Jl=(e=>(e[e.Left=0]="Left",e[e.Right=2]="Right",e))(Jl||{});function Xc(e){let t=p.useRef(null),n=D(o=>{t.current=o.pointerType,!Xn(o.currentTarget)&&o.pointerType==="mouse"&&o.button===Jl.Left&&(o.preventDefault(),e(o))}),r=D(o=>{t.current!=="mouse"&&(Xn(o.currentTarget)||e(o))});return{onPointerDown:n,onClick:r}}let Ql=class extends Map{constructor(t){super(),this.factory=t}get(t){let n=super.get(t);return n===void 0&&(n=this.factory(t),this.set(t,n)),n}};var Jc=Object.defineProperty,Qc=(e,t,n)=>t in e?Jc(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ed=(e,t,n)=>(Qc(e,t+"",n),n),ei=(e,t,n)=>{if(!t.has(e))throw TypeError("Cannot "+n)},ge=(e,t,n)=>(ei(e,t,"read from private field"),n?n.call(e):t.get(e)),An=(e,t,n)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,n)},ro=(e,t,n,r)=>(ei(e,t,"write to private field"),t.set(e,n),n),Ce,ht,gt;let ti=class{constructor(t){An(this,Ce,{}),An(this,ht,new Ql(()=>new Set)),An(this,gt,new Set),ed(this,"disposables",fe()),ro(this,Ce,t),Se.isServer&&this.disposables.microTask(()=>{this.dispose()})}dispose(){this.disposables.dispose()}get state(){return ge(this,Ce)}subscribe(t,n){if(Se.isServer)return()=>{};let r={selector:t,callback:n,current:t(ge(this,Ce))};return ge(this,gt).add(r),this.disposables.add(()=>{ge(this,gt).delete(r)})}on(t,n){return Se.isServer?()=>{}:(ge(this,ht).get(t).add(n),this.disposables.add(()=>{ge(this,ht).get(t).delete(n)}))}send(t){let n=this.reduce(ge(this,Ce),t);if(n!==ge(this,Ce)){ro(this,Ce,n);for(let r of ge(this,gt)){let o=r.selector(ge(this,Ce));ni(r.current,o)||(r.current=o,r.callback(o))}for(let r of ge(this,ht).get(t.type))r(ge(this,Ce),t)}}};Ce=new WeakMap,ht=new WeakMap,gt=new WeakMap;function ni(e,t){return Object.is(e,t)?!0:typeof e!="object"||e===null||typeof t!="object"||t===null?!1:Array.isArray(e)&&Array.isArray(t)?e.length!==t.length?!1:Fn(e[Symbol.iterator](),t[Symbol.iterator]()):e instanceof Map&&t instanceof Map||e instanceof Set&&t instanceof Set?e.size!==t.size?!1:Fn(e.entries(),t.entries()):oo(e)&&oo(t)?Fn(Object.entries(e)[Symbol.iterator](),Object.entries(t)[Symbol.iterator]()):!1}function Fn(e,t){do{let n=e.next(),r=t.next();if(n.done&&r.done)return!0;if(n.done||r.done||!Object.is(n.value,r.value))return!1}while(!0)}function oo(e){if(Object.prototype.toString.call(e)!=="[object Object]")return!1;let t=Object.getPrototypeOf(e);return t===null||Object.getPrototypeOf(t)===null}function Mn(e){let[t,n]=e(),r=fe();return(...o)=>{t(...o),r.dispose(),r.microTask(n)}}var td=Object.defineProperty,nd=(e,t,n)=>t in e?td(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,lo=(e,t,n)=>(nd(e,typeof t!="symbol"?t+"":t,n),n),ri=(e=>(e[e.Push=0]="Push",e[e.Pop=1]="Pop",e))(ri||{});let rd={0(e,t){let n=t.id,r=e.stack,o=e.stack.indexOf(n);if(o!==-1){let l=e.stack.slice();return l.splice(o,1),l.push(n),r=l,{...e,stack:r}}return{...e,stack:[...e.stack,n]}},1(e,t){let n=t.id,r=e.stack.indexOf(n);if(r===-1)return e;let o=e.stack.slice();return o.splice(r,1),{...e,stack:o}}},od=class oi extends ti{constructor(){super(...arguments),lo(this,"actions",{push:t=>this.send({type:0,id:t}),pop:t=>this.send({type:1,id:t})}),lo(this,"selectors",{isTop:(t,n)=>t.stack[t.stack.length-1]===n,inStack:(t,n)=>t.stack.includes(n)})}static new(){return new oi({stack:[]})}reduce(t,n){return se(n.type,rd,t,n)}};const Cr=new Ql(()=>od.new());var Ht={exports:{}},Nn={};var io;function ld(){if(io)return Nn;io=1;var e=p;function t(s,u){return s===u&&(s!==0||1/s===1/u)||s!==s&&u!==u}var n=typeof Object.is=="function"?Object.is:t,r=e.useSyncExternalStore,o=e.useRef,l=e.useEffect,i=e.useMemo,a=e.useDebugValue;return Nn.useSyncExternalStoreWithSelector=function(s,u,c,d,m){var f=o(null);if(f.current===null){var h={hasValue:!1,value:null};f.current=h}else h=f.current;f=i(function(){function b(C){if(!x){if(x=!0,y=C,C=d(C),m!==void 0&&h.hasValue){var T=h.value;if(m(T,C))return w=T}return w=C}if(T=w,n(y,C))return T;var O=d(C);return m!==void 0&&m(T,O)?(y=C,T):(y=C,w=O)}var x=!1,y,w,S=c===void 0?null:c;return[function(){return b(u())},S===null?void 0:function(){return b(S())}]},[u,c,d,m]);var v=r(s,f[0],f[1]);return l(function(){h.hasValue=!0,h.value=v},[v]),a(v),v},Nn}var In={};var ao;function id(){return ao||(ao=1,process.env.NODE_ENV!=="production"&&(function(){function e(s,u){return s===u&&(s!==0||1/s===1/u)||s!==s&&u!==u}typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var t=p,n=typeof Object.is=="function"?Object.is:e,r=t.useSyncExternalStore,o=t.useRef,l=t.useEffect,i=t.useMemo,a=t.useDebugValue;In.useSyncExternalStoreWithSelector=function(s,u,c,d,m){var f=o(null);if(f.current===null){var h={hasValue:!1,value:null};f.current=h}else h=f.current;f=i(function(){function b(C){if(!x){if(x=!0,y=C,C=d(C),m!==void 0&&h.hasValue){var T=h.value;if(m(T,C))return w=T}return w=C}if(T=w,n(y,C))return T;var O=d(C);return m!==void 0&&m(T,O)?(y=C,T):(y=C,w=O)}var x=!1,y,w,S=c===void 0?null:c;return[function(){return b(u())},S===null?void 0:function(){return b(S())}]},[u,c,d,m]);var v=r(s,f[0],f[1]);return l(function(){h.hasValue=!0,h.value=v},[v]),a(v),v},typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())})()),In}var so;function ad(){return so||(so=1,process.env.NODE_ENV==="production"?Ht.exports=ld():Ht.exports=id()),Ht.exports}var sd=ad();function ce(e,t,n=ni){return sd.useSyncExternalStoreWithSelector(D(r=>e.subscribe(ud,r)),D(()=>e.state),D(()=>e.state),D(t),n)}function ud(e){return e}function li(e,t){let n=p.useId(),r=Cr.get(t),[o,l]=ce(r,p.useCallback(i=>[r.selectors.isTop(i,n),r.selectors.inStack(i,n)],[r,n]));return X(()=>{if(e)return r.actions.push(n),()=>r.actions.pop(n)},[r,e,n]),e?l?o:!0:!1}let Jn=new Map,bt=new Map;function uo(e){var t;let n=(t=bt.get(e))!=null?t:0;return bt.set(e,n+1),n!==0?()=>co(e):(Jn.set(e,{"aria-hidden":e.getAttribute("aria-hidden"),inert:e.inert}),e.setAttribute("aria-hidden","true"),e.inert=!0,()=>co(e))}function co(e){var t;let n=(t=bt.get(e))!=null?t:1;if(n===1?bt.delete(e):bt.set(e,n-1),n!==1)return;let r=Jn.get(e);r&&(r["aria-hidden"]===null?e.removeAttribute("aria-hidden"):e.setAttribute("aria-hidden",r["aria-hidden"]),e.inert=r.inert,Jn.delete(e))}function cd(e,{allowed:t,disallowed:n}={}){let r=li(e,"inert-others");X(()=>{var o,l;if(!r)return;let i=fe();for(let s of(o=n?.())!=null?o:[])s&&i.add(uo(s));let a=(l=t?.())!=null?l:[];for(let s of a){if(!s)continue;let u=Tt(s);if(!u)continue;let c=s.parentElement;for(;c&&c!==u.body;){for(let d of c.children)a.some(m=>d.contains(m))||i.add(uo(d));c=c.parentElement}}return i.dispose},[r,t,n])}function dd(e,t,n){let r=Je(o=>{let l=o.getBoundingClientRect();l.x===0&&l.y===0&&l.width===0&&l.height===0&&n()});p.useEffect(()=>{if(!e)return;let o=t===null?null:Ne(t)?t:t.current;if(!o)return;let l=fe();if(typeof ResizeObserver<"u"){let i=new ResizeObserver(()=>r.current(o));i.observe(o),l.add(()=>i.disconnect())}if(typeof IntersectionObserver<"u"){let i=new IntersectionObserver(()=>r.current(o));i.observe(o),l.add(()=>i.disconnect())}return()=>l.dispose()},[t,r,e])}let Qn=["[contentEditable=true]","[tabindex]","a[href]","area[href]","button:not([disabled])","iframe","input:not([disabled])","select:not([disabled])","details>summary","textarea:not([disabled])"].map(e=>`${e}:not([tabindex='-1'])`).join(","),fd=["[data-autofocus]"].map(e=>`${e}:not([tabindex='-1'])`).join(",");var er=(e=>(e[e.First=1]="First",e[e.Previous=2]="Previous",e[e.Next=4]="Next",e[e.Last=8]="Last",e[e.WrapAround=16]="WrapAround",e[e.NoScroll=32]="NoScroll",e[e.AutoFocus=64]="AutoFocus",e))(er||{}),pd=(e=>(e[e.Error=0]="Error",e[e.Overflow=1]="Overflow",e[e.Success=2]="Success",e[e.Underflow=3]="Underflow",e))(pd||{}),md=(e=>(e[e.Previous=-1]="Previous",e[e.Next=1]="Next",e))(md||{});function ii(e=document.body){return e==null?[]:Array.from(e.querySelectorAll(Qn)).sort((t,n)=>Math.sign((t.tabIndex||Number.MAX_SAFE_INTEGER)-(n.tabIndex||Number.MAX_SAFE_INTEGER)))}function hd(e=document.body){return e==null?[]:Array.from(e.querySelectorAll(fd)).sort((t,n)=>Math.sign((t.tabIndex||Number.MAX_SAFE_INTEGER)-(n.tabIndex||Number.MAX_SAFE_INTEGER)))}var Sr=(e=>(e[e.Strict=0]="Strict",e[e.Loose=1]="Loose",e))(Sr||{});function ai(e,t=0){var n;return e===((n=Tt(e))==null?void 0:n.body)?!1:se(t,{0(){return e.matches(Qn)},1(){let r=e;for(;r!==null;){if(r.matches(Qn))return!0;r=r.parentElement}return!1}})}var gd=(e=>(e[e.Keyboard=0]="Keyboard",e[e.Mouse=1]="Mouse",e))(gd||{});typeof window<"u"&&typeof document<"u"&&(document.addEventListener("keydown",e=>{e.metaKey||e.altKey||e.ctrlKey||(document.documentElement.dataset.headlessuiFocusVisible="")},!0),document.addEventListener("click",e=>{e.detail===1?delete document.documentElement.dataset.headlessuiFocusVisible:e.detail===0&&(document.documentElement.dataset.headlessuiFocusVisible="")},!0));let vd=["textarea","input"].join(",");function bd(e){var t,n;return(n=(t=e?.matches)==null?void 0:t.call(e,vd))!=null?n:!1}function si(e,t=n=>n){return e.slice().sort((n,r)=>{let o=t(n),l=t(r);if(o===null||l===null)return 0;let i=o.compareDocumentPosition(l);return i&Node.DOCUMENT_POSITION_FOLLOWING?-1:i&Node.DOCUMENT_POSITION_PRECEDING?1:0})}function xd(e,t,n=e===null?document.body:en(e)){return wd(ii(n),t,{relativeTo:e})}function wd(e,t,{sorted:n=!0,relativeTo:r=null,skipElements:o=[]}={}){let l=Array.isArray(e)?e.length>0?en(e[0]):document:en(e),i=Array.isArray(e)?n?si(e):e:t&64?hd(e):ii(e);o.length>0&&i.length>1&&(i=i.filter(f=>!o.some(h=>h!=null&&"current"in h?h?.current===f:h===f))),r=r??l?.activeElement;let a=(()=>{if(t&5)return 1;if(t&10)return-1;throw new Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),s=(()=>{if(t&1)return 0;if(t&2)return Math.max(0,i.indexOf(r))-1;if(t&4)return Math.max(0,i.indexOf(r))+1;if(t&8)return i.length-1;throw new Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),u=t&32?{preventScroll:!0}:{},c=0,d=i.length,m;do{if(c>=d||c+d<=0)return 0;let f=s+c;if(t&16)f=(f+d)%d;else{if(f<0)return 3;if(f>=d)return 1}m=i[f],m?.focus(u),c+=a}while(m!==Il(m));return t&6&&bd(m)&&m.select(),2}function ui(){return/iPhone/gi.test(window.navigator.platform)||/Mac/gi.test(window.navigator.platform)&&window.navigator.maxTouchPoints>0}function yd(){return/Android/gi.test(window.navigator.userAgent)}function fo(){return ui()||yd()}function et(e,t,n,r){let o=Je(n);p.useEffect(()=>{if(!e)return;function l(i){o.current(i)}return document.addEventListener(t,l,r),()=>document.removeEventListener(t,l,r)},[e,t,r])}function Ed(e,t,n,r){let o=Je(n);p.useEffect(()=>{if(!e)return;function l(i){o.current(i)}return window.addEventListener(t,l,r),()=>window.removeEventListener(t,l,r)},[e,t,r])}const po=30;function Cd(e,t,n){let r=Je(n),o=p.useCallback(function(a,s){if(a.defaultPrevented)return;let u=s(a);if(u===null||!u.getRootNode().contains(u)||!u.isConnected)return;let c=(function d(m){return typeof m=="function"?d(m()):Array.isArray(m)||m instanceof Set?m:[m]})(t);for(let d of c)if(d!==null&&(d.contains(u)||a.composed&&a.composedPath().includes(d)))return;return!ai(u,Sr.Loose)&&u.tabIndex!==-1&&a.preventDefault(),r.current(a,u)},[r,t]),l=p.useRef(null);et(e,"pointerdown",a=>{var s,u;fo()||(l.current=((u=(s=a.composedPath)==null?void 0:s.call(a))==null?void 0:u[0])||a.target)},!0),et(e,"pointerup",a=>{if(fo()||!l.current)return;let s=l.current;return l.current=null,o(a,()=>s)},!0);let i=p.useRef({x:0,y:0});et(e,"touchstart",a=>{i.current.x=a.touches[0].clientX,i.current.y=a.touches[0].clientY},!0),et(e,"touchend",a=>{let s={x:a.changedTouches[0].clientX,y:a.changedTouches[0].clientY};if(!(Math.abs(s.x-i.current.x)>=po||Math.abs(s.y-i.current.y)>=po))return o(a,()=>_e(a.target)?a.target:null)},!0),Ed(e,"blur",a=>o(a,()=>Fc(window.document.activeElement)?window.document.activeElement:null),!0)}function tr(...e){return p.useMemo(()=>Tt(...e),[...e])}var Sd=(e=>(e[e.Ignore=0]="Ignore",e[e.Select=1]="Select",e[e.Close=2]="Close",e))(Sd||{});const Vt={Ignore:{kind:0},Select:e=>({kind:1,target:e}),Close:{kind:2}},$d=200,mo=5;function kd(e,{trigger:t,action:n,close:r,select:o}){let l=p.useRef(null),i=p.useRef(null),a=p.useRef(null);et(e&&t!==null,"pointerdown",s=>{Wl(s?.target)&&t!=null&&t.contains(s.target)&&(i.current=s.x,a.current=s.y,l.current=s.timeStamp)}),et(e&&t!==null,"pointerup",s=>{var u,c;let d=l.current;if(d===null||(l.current=null,!_e(s.target))||Math.abs(s.x-((u=i.current)!=null?u:s.x))<mo&&Math.abs(s.y-((c=a.current)!=null?c:s.y))<mo)return;let m=n(s);switch(m.kind){case 0:return;case 1:{s.timeStamp-d>$d&&(o(m.target),r());break}case 2:{r();break}}},{capture:!0})}function ci(e,t){return p.useMemo(()=>{var n;if(e.type)return e.type;let r=(n=e.as)!=null?n:"button";if(typeof r=="string"&&r.toLowerCase()==="button"||t?.tagName==="BUTTON"&&!t.hasAttribute("type"))return"button"},[e.type,e.as,t])}function Rd(e){return p.useSyncExternalStore(e.subscribe,e.getSnapshot,e.getSnapshot)}function Od(e,t){let n=e(),r=new Set;return{getSnapshot(){return n},subscribe(o){return r.add(o),()=>r.delete(o)},dispatch(o,...l){let i=t[o].call(n,...l);i&&(n=i,r.forEach(a=>a()))}}}function Td(){let e;return{before({doc:t}){var n;let r=t.documentElement,o=(n=t.defaultView)!=null?n:window;e=Math.max(0,o.innerWidth-r.clientWidth)},after({doc:t,d:n}){let r=t.documentElement,o=Math.max(0,r.clientWidth-r.offsetWidth),l=Math.max(0,e-o);n.style(r,"paddingRight",`${l}px`)}}}function Pd(){return ui()?{before({doc:e,d:t,meta:n}){function r(o){for(let l of n().containers)for(let i of l())if(i.contains(o))return!0;return!1}t.microTask(()=>{var o;if(window.getComputedStyle(e.documentElement).scrollBehavior!=="auto"){let a=fe();a.style(e.documentElement,"scrollBehavior","auto"),t.add(()=>t.microTask(()=>a.dispose()))}let l=(o=window.scrollY)!=null?o:window.pageYOffset,i=null;t.addEventListener(e,"click",a=>{if(_e(a.target))try{let s=a.target.closest("a");if(!s)return;let{hash:u}=new URL(s.href),c=e.querySelector(u);_e(c)&&!r(c)&&(i=c)}catch{}},!0),t.group(a=>{t.addEventListener(e,"touchstart",s=>{if(a.dispose(),_e(s.target)&&Ac(s.target))if(r(s.target)){let u=s.target;for(;u.parentElement&&r(u.parentElement);)u=u.parentElement;a.style(u,"overscrollBehavior","contain")}else a.style(s.target,"touchAction","none")})}),t.addEventListener(e,"touchmove",a=>{if(_e(a.target)){if(Ul(a.target))return;if(r(a.target)){let s=a.target;for(;s.parentElement&&s.dataset.headlessuiPortal!==""&&!(s.scrollHeight>s.clientHeight||s.scrollWidth>s.clientWidth);)s=s.parentElement;s.dataset.headlessuiPortal===""&&a.preventDefault()}else a.preventDefault()}},{passive:!1}),t.add(()=>{var a;let s=(a=window.scrollY)!=null?a:window.pageYOffset;l!==s&&window.scrollTo(0,l),i&&i.isConnected&&(i.scrollIntoView({block:"nearest"}),i=null)})})}}:{}}function Ld(){return{before({doc:e,d:t}){t.style(e.documentElement,"overflow","hidden")}}}function ho(e){let t={};for(let n of e)Object.assign(t,n(t));return t}let qe=Od(()=>new Map,{PUSH(e,t){var n;let r=(n=this.get(e))!=null?n:{doc:e,count:0,d:fe(),meta:new Set,computedMeta:{}};return r.count++,r.meta.add(t),r.computedMeta=ho(r.meta),this.set(e,r),this},POP(e,t){let n=this.get(e);return n&&(n.count--,n.meta.delete(t),n.computedMeta=ho(n.meta)),this},SCROLL_PREVENT(e){let t={doc:e.doc,d:e.d,meta(){return e.computedMeta}},n=[Pd(),Td(),Ld()];n.forEach(({before:r})=>r?.(t)),n.forEach(({after:r})=>r?.(t))},SCROLL_ALLOW({d:e}){e.dispose()},TEARDOWN({doc:e}){this.delete(e)}});qe.subscribe(()=>{let e=qe.getSnapshot(),t=new Map;for(let[n]of e)t.set(n,n.documentElement.style.overflow);for(let n of e.values()){let r=t.get(n.doc)==="hidden",o=n.count!==0;(o&&!r||!o&&r)&&qe.dispatch(n.count>0?"SCROLL_PREVENT":"SCROLL_ALLOW",n),n.count===0&&qe.dispatch("TEARDOWN",n)}});function Ad(e,t,n=()=>({containers:[]})){let r=Rd(qe),o=t?r.get(t):void 0,l=o?o.count>0:!1;return X(()=>{if(!(!t||!e))return qe.dispatch("PUSH",t,n),()=>qe.dispatch("POP",t,n)},[e,t]),l}function Fd(e,t,n=()=>[document.body]){let r=li(e,"scroll-lock");Ad(r,t,o=>{var l;return{containers:[...(l=o.containers)!=null?l:[],n]}})}function go(e){return[e.screenX,e.screenY]}function Md(){let e=p.useRef([-1,-1]);return{wasMoved(t){let n=go(t);return e.current[0]===n[0]&&e.current[1]===n[1]?!1:(e.current=n,!0)},update(t){e.current=go(t)}}}function Nd(e=0){let[t,n]=p.useState(e),r=p.useCallback(s=>n(s),[]),o=p.useCallback(s=>n(u=>u|s),[]),l=p.useCallback(s=>(t&s)===s,[t]),i=p.useCallback(s=>n(u=>u&~s),[]),a=p.useCallback(s=>n(u=>u^s),[]);return{flags:t,setFlag:r,addFlag:o,hasFlag:l,removeFlag:i,toggleFlag:a}}var vo,bo;typeof process<"u"&&typeof globalThis<"u"&&typeof Element<"u"&&((vo=process==null?void 0:process.env)==null?void 0:vo.NODE_ENV)==="test"&&typeof((bo=Element?.prototype)==null?void 0:bo.getAnimations)>"u"&&(Element.prototype.getAnimations=function(){return console.warn(["Headless UI has polyfilled `Element.prototype.getAnimations` for your tests.","Please install a proper polyfill e.g. `jsdom-testing-mocks`, to silence these warnings.","","Example usage:","```js","import { mockAnimationsApi } from 'jsdom-testing-mocks'","mockAnimationsApi()","```"].join(`
|
|
7
|
+
`)),[]});var Id=(e=>(e[e.None=0]="None",e[e.Closed=1]="Closed",e[e.Enter=2]="Enter",e[e.Leave=4]="Leave",e))(Id||{});function $r(e){let t={};for(let n in e)e[n]===!0&&(t[`data-${n}`]="");return t}function kr(e,t,n,r){let[o,l]=p.useState(n),{hasFlag:i,addFlag:a,removeFlag:s}=Nd(e&&o?3:0),u=p.useRef(!1),c=p.useRef(!1),d=Xe();return X(()=>{var m;if(e){if(n&&l(!0),!t){n&&a(3);return}return(m=r?.start)==null||m.call(r,n),jd(t,{inFlight:u,prepare(){c.current?c.current=!1:c.current=u.current,u.current=!0,!c.current&&(n?(a(3),s(4)):(a(4),s(2)))},run(){c.current?n?(s(3),a(4)):(s(4),a(3)):n?s(1):a(1)},done(){var f;c.current&&Bd(t)||(u.current=!1,s(7),n||l(!1),(f=r?.end)==null||f.call(r,n))}})}},[e,n,t,d]),e?[o,{closed:i(1),enter:i(2),leave:i(4),transition:i(2)||i(4)}]:[n,{closed:void 0,enter:void 0,leave:void 0,transition:void 0}]}function jd(e,{prepare:t,run:n,done:r,inFlight:o}){let l=fe();return _d(e,{prepare:t,inFlight:o}),l.nextFrame(()=>{n(),l.requestAnimationFrame(()=>{l.add(Dd(e,r))})}),l.dispose}function Dd(e,t){var n,r;let o=fe();if(!e)return o.dispose;let l=!1;o.add(()=>{l=!0});let i=(r=(n=e.getAnimations)==null?void 0:n.call(e).filter(a=>a instanceof CSSTransition))!=null?r:[];return i.length===0?(t(),o.dispose):(Promise.allSettled(i.map(a=>a.finished)).then(()=>{l||t()}),o.dispose)}function _d(e,{inFlight:t,prepare:n}){if(t!=null&&t.current){n();return}let r=e.style.transition;e.style.transition="none",n(),e.offsetHeight,e.style.transition=r}function Bd(e){var t,n;return((n=(t=e.getAnimations)==null?void 0:t.call(e))!=null?n:[]).some(r=>r instanceof CSSTransition&&r.playState!=="finished")}function fn(){return typeof window<"u"}function ct(e){return di(e)?(e.nodeName||"").toLowerCase():"#document"}function de(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Re(e){var t;return(t=(di(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function di(e){return fn()?e instanceof Node||e instanceof de(e).Node:!1}function oe(e){return fn()?e instanceof Element||e instanceof de(e).Element:!1}function ke(e){return fn()?e instanceof HTMLElement||e instanceof de(e).HTMLElement:!1}function xo(e){return!fn()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof de(e).ShadowRoot}const Hd=new Set(["inline","contents"]);function Pt(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=ye(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!Hd.has(o)}const Vd=new Set(["table","td","th"]);function zd(e){return Vd.has(ct(e))}const Wd=[":popover-open",":modal"];function pn(e){return Wd.some(t=>{try{return e.matches(t)}catch{return!1}})}const Ud=["transform","translate","scale","rotate","perspective"],qd=["transform","translate","scale","rotate","perspective","filter"],Gd=["paint","layout","strict","content"];function Rr(e){const t=Or(),n=oe(e)?ye(e):e;return Ud.some(r=>n[r]?n[r]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||qd.some(r=>(n.willChange||"").includes(r))||Gd.some(r=>(n.contain||"").includes(r))}function Kd(e){let t=He(e);for(;ke(t)&&!ot(t);){if(Rr(t))return t;if(pn(t))return null;t=He(t)}return null}function Or(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const Yd=new Set(["html","body","#document"]);function ot(e){return Yd.has(ct(e))}function ye(e){return de(e).getComputedStyle(e)}function mn(e){return oe(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function He(e){if(ct(e)==="html")return e;const t=e.assignedSlot||e.parentNode||xo(e)&&e.host||Re(e);return xo(t)?t.host:t}function fi(e){const t=He(e);return ot(t)?e.ownerDocument?e.ownerDocument.body:e.body:ke(t)&&Pt(t)?t:fi(t)}function Et(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=fi(e),l=o===((r=e.ownerDocument)==null?void 0:r.body),i=de(o);if(l){const a=nr(i);return t.concat(i,i.visualViewport||[],Pt(o)?o:[],a&&n?Et(a):[])}return t.concat(o,Et(o,[],n))}function nr(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Zd(){const e=navigator.userAgentData;return e&&Array.isArray(e.brands)?e.brands.map(t=>{let{brand:n,version:r}=t;return n+"/"+r}).join(" "):navigator.userAgent}const Ye=Math.min,ne=Math.max,Ct=Math.round,zt=Math.floor,$e=e=>({x:e,y:e}),Xd={left:"right",right:"left",bottom:"top",top:"bottom"},Jd={start:"end",end:"start"};function wo(e,t,n){return ne(e,Ye(t,n))}function dt(e,t){return typeof e=="function"?e(t):e}function Ve(e){return e.split("-")[0]}function Lt(e){return e.split("-")[1]}function pi(e){return e==="x"?"y":"x"}function mi(e){return e==="y"?"height":"width"}const Qd=new Set(["top","bottom"]);function Te(e){return Qd.has(Ve(e))?"y":"x"}function hi(e){return pi(Te(e))}function ef(e,t,n){n===void 0&&(n=!1);const r=Lt(e),o=hi(e),l=mi(o);let i=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[l]>t.floating[l]&&(i=tn(i)),[i,tn(i)]}function tf(e){const t=tn(e);return[rr(e),t,rr(t)]}function rr(e){return e.replace(/start|end/g,t=>Jd[t])}const yo=["left","right"],Eo=["right","left"],nf=["top","bottom"],rf=["bottom","top"];function of(e,t,n){switch(e){case"top":case"bottom":return n?t?Eo:yo:t?yo:Eo;case"left":case"right":return t?nf:rf;default:return[]}}function lf(e,t,n,r){const o=Lt(e);let l=of(Ve(e),n==="start",r);return o&&(l=l.map(i=>i+"-"+o),t&&(l=l.concat(l.map(rr)))),l}function tn(e){return e.replace(/left|right|bottom|top/g,t=>Xd[t])}function af(e){return{top:0,right:0,bottom:0,left:0,...e}}function sf(e){return typeof e!="number"?af(e):{top:e,right:e,bottom:e,left:e}}function nn(e){const{x:t,y:n,width:r,height:o}=e;return{width:r,height:o,top:n,left:t,right:t+r,bottom:n+o,x:t,y:n}}function Co(e,t,n){let{reference:r,floating:o}=e;const l=Te(t),i=hi(t),a=mi(i),s=Ve(t),u=l==="y",c=r.x+r.width/2-o.width/2,d=r.y+r.height/2-o.height/2,m=r[a]/2-o[a]/2;let f;switch(s){case"top":f={x:c,y:r.y-o.height};break;case"bottom":f={x:c,y:r.y+r.height};break;case"right":f={x:r.x+r.width,y:d};break;case"left":f={x:r.x-o.width,y:d};break;default:f={x:r.x,y:r.y}}switch(Lt(t)){case"start":f[i]-=m*(n&&u?-1:1);break;case"end":f[i]+=m*(n&&u?-1:1);break}return f}const uf=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:l=[],platform:i}=n,a=l.filter(Boolean),s=await(i.isRTL==null?void 0:i.isRTL(t));let u=await i.getElementRects({reference:e,floating:t,strategy:o}),{x:c,y:d}=Co(u,r,s),m=r,f={},h=0;for(let v=0;v<a.length;v++){const{name:b,fn:x}=a[v],{x:y,y:w,data:S,reset:C}=await x({x:c,y:d,initialPlacement:r,placement:m,strategy:o,middlewareData:f,rects:u,platform:i,elements:{reference:e,floating:t}});c=y??c,d=w??d,f={...f,[b]:{...f[b],...S}},C&&h<=50&&(h++,typeof C=="object"&&(C.placement&&(m=C.placement),C.rects&&(u=C.rects===!0?await i.getElementRects({reference:e,floating:t,strategy:o}):C.rects),{x:c,y:d}=Co(u,m,s)),v=-1)}return{x:c,y:d,placement:m,strategy:o,middlewareData:f}};async function hn(e,t){var n;t===void 0&&(t={});const{x:r,y:o,platform:l,rects:i,elements:a,strategy:s}=e,{boundary:u="clippingAncestors",rootBoundary:c="viewport",elementContext:d="floating",altBoundary:m=!1,padding:f=0}=dt(t,e),h=sf(f),b=a[m?d==="floating"?"reference":"floating":d],x=nn(await l.getClippingRect({element:(n=await(l.isElement==null?void 0:l.isElement(b)))==null||n?b:b.contextElement||await(l.getDocumentElement==null?void 0:l.getDocumentElement(a.floating)),boundary:u,rootBoundary:c,strategy:s})),y=d==="floating"?{x:r,y:o,width:i.floating.width,height:i.floating.height}:i.reference,w=await(l.getOffsetParent==null?void 0:l.getOffsetParent(a.floating)),S=await(l.isElement==null?void 0:l.isElement(w))?await(l.getScale==null?void 0:l.getScale(w))||{x:1,y:1}:{x:1,y:1},C=nn(l.convertOffsetParentRelativeRectToViewportRelativeRect?await l.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:y,offsetParent:w,strategy:s}):y);return{top:(x.top-C.top+h.top)/S.y,bottom:(C.bottom-x.bottom+h.bottom)/S.y,left:(x.left-C.left+h.left)/S.x,right:(C.right-x.right+h.right)/S.x}}const cf=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:o,middlewareData:l,rects:i,initialPlacement:a,platform:s,elements:u}=t,{mainAxis:c=!0,crossAxis:d=!0,fallbackPlacements:m,fallbackStrategy:f="bestFit",fallbackAxisSideDirection:h="none",flipAlignment:v=!0,...b}=dt(e,t);if((n=l.arrow)!=null&&n.alignmentOffset)return{};const x=Ve(o),y=Te(a),w=Ve(a)===a,S=await(s.isRTL==null?void 0:s.isRTL(u.floating)),C=m||(w||!v?[tn(a)]:tf(a)),T=h!=="none";!m&&T&&C.push(...lf(a,v,h,S));const O=[a,...C],k=await hn(t,b),A=[];let R=((r=l.flip)==null?void 0:r.overflows)||[];if(c&&A.push(k[x]),d){const B=ef(o,i,S);A.push(k[B[0]],k[B[1]])}if(R=[...R,{placement:o,overflows:A}],!A.every(B=>B<=0)){var M,H;const B=(((M=l.flip)==null?void 0:M.index)||0)+1,F=O[B];if(F&&(!(d==="alignment"?y!==Te(F):!1)||R.every($=>Te($.placement)===y?$.overflows[0]>0:!0)))return{data:{index:B,overflows:R},reset:{placement:F}};let I=(H=R.filter(U=>U.overflows[0]<=0).sort((U,$)=>U.overflows[1]-$.overflows[1])[0])==null?void 0:H.placement;if(!I)switch(f){case"bestFit":{var z;const U=(z=R.filter($=>{if(T){const V=Te($.placement);return V===y||V==="y"}return!0}).map($=>[$.placement,$.overflows.filter(V=>V>0).reduce((V,q)=>V+q,0)]).sort(($,V)=>$[1]-V[1])[0])==null?void 0:z[0];U&&(I=U);break}case"initialPlacement":I=a;break}if(o!==I)return{reset:{placement:I}}}return{}}}},df=new Set(["left","top"]);async function ff(e,t){const{placement:n,platform:r,elements:o}=e,l=await(r.isRTL==null?void 0:r.isRTL(o.floating)),i=Ve(n),a=Lt(n),s=Te(n)==="y",u=df.has(i)?-1:1,c=l&&s?-1:1,d=dt(t,e);let{mainAxis:m,crossAxis:f,alignmentAxis:h}=typeof d=="number"?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return a&&typeof h=="number"&&(f=a==="end"?h*-1:h),s?{x:f*c,y:m*u}:{x:m*u,y:f*c}}const pf=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:o,y:l,placement:i,middlewareData:a}=t,s=await ff(t,e);return i===((n=a.offset)==null?void 0:n.placement)&&(r=a.arrow)!=null&&r.alignmentOffset?{}:{x:o+s.x,y:l+s.y,data:{...s,placement:i}}}}},mf=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:l=!0,crossAxis:i=!1,limiter:a={fn:b=>{let{x,y}=b;return{x,y}}},...s}=dt(e,t),u={x:n,y:r},c=await hn(t,s),d=Te(Ve(o)),m=pi(d);let f=u[m],h=u[d];if(l){const b=m==="y"?"top":"left",x=m==="y"?"bottom":"right",y=f+c[b],w=f-c[x];f=wo(y,f,w)}if(i){const b=d==="y"?"top":"left",x=d==="y"?"bottom":"right",y=h+c[b],w=h-c[x];h=wo(y,h,w)}const v=a.fn({...t,[m]:f,[d]:h});return{...v,data:{x:v.x-n,y:v.y-r,enabled:{[m]:l,[d]:i}}}}}},hf=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:o,rects:l,platform:i,elements:a}=t,{apply:s=()=>{},...u}=dt(e,t),c=await hn(t,u),d=Ve(o),m=Lt(o),f=Te(o)==="y",{width:h,height:v}=l.floating;let b,x;d==="top"||d==="bottom"?(b=d,x=m===(await(i.isRTL==null?void 0:i.isRTL(a.floating))?"start":"end")?"left":"right"):(x=d,b=m==="end"?"top":"bottom");const y=v-c.top-c.bottom,w=h-c.left-c.right,S=Ye(v-c[b],y),C=Ye(h-c[x],w),T=!t.middlewareData.shift;let O=S,k=C;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(k=w),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(O=y),T&&!m){const R=ne(c.left,0),M=ne(c.right,0),H=ne(c.top,0),z=ne(c.bottom,0);f?k=h-2*(R!==0||M!==0?R+M:ne(c.left,c.right)):O=v-2*(H!==0||z!==0?H+z:ne(c.top,c.bottom))}await s({...t,availableWidth:k,availableHeight:O});const A=await i.getDimensions(a.floating);return h!==A.width||v!==A.height?{reset:{rects:!0}}:{}}}};function gi(e){const t=ye(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=ke(e),l=o?e.offsetWidth:n,i=o?e.offsetHeight:r,a=Ct(n)!==l||Ct(r)!==i;return a&&(n=l,r=i),{width:n,height:r,$:a}}function Tr(e){return oe(e)?e:e.contextElement}function nt(e){const t=Tr(e);if(!ke(t))return $e(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:l}=gi(t);let i=(l?Ct(n.width):n.width)/r,a=(l?Ct(n.height):n.height)/o;return(!i||!Number.isFinite(i))&&(i=1),(!a||!Number.isFinite(a))&&(a=1),{x:i,y:a}}const gf=$e(0);function vi(e){const t=de(e);return!Or()||!t.visualViewport?gf:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function vf(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==de(e)?!1:t}function Ze(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),l=Tr(e);let i=$e(1);t&&(r?oe(r)&&(i=nt(r)):i=nt(e));const a=vf(l,n,r)?vi(l):$e(0);let s=(o.left+a.x)/i.x,u=(o.top+a.y)/i.y,c=o.width/i.x,d=o.height/i.y;if(l){const m=de(l),f=r&&oe(r)?de(r):r;let h=m,v=nr(h);for(;v&&r&&f!==h;){const b=nt(v),x=v.getBoundingClientRect(),y=ye(v),w=x.left+(v.clientLeft+parseFloat(y.paddingLeft))*b.x,S=x.top+(v.clientTop+parseFloat(y.paddingTop))*b.y;s*=b.x,u*=b.y,c*=b.x,d*=b.y,s+=w,u+=S,h=de(v),v=nr(h)}}return nn({width:c,height:d,x:s,y:u})}function gn(e,t){const n=mn(e).scrollLeft;return t?t.left+n:Ze(Re(e)).left+n}function bi(e,t){const n=e.getBoundingClientRect(),r=n.left+t.scrollLeft-gn(e,n),o=n.top+t.scrollTop;return{x:r,y:o}}function bf(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const l=o==="fixed",i=Re(r),a=t?pn(t.floating):!1;if(r===i||a&&l)return n;let s={scrollLeft:0,scrollTop:0},u=$e(1);const c=$e(0),d=ke(r);if((d||!d&&!l)&&((ct(r)!=="body"||Pt(i))&&(s=mn(r)),ke(r))){const f=Ze(r);u=nt(r),c.x=f.x+r.clientLeft,c.y=f.y+r.clientTop}const m=i&&!d&&!l?bi(i,s):$e(0);return{width:n.width*u.x,height:n.height*u.y,x:n.x*u.x-s.scrollLeft*u.x+c.x+m.x,y:n.y*u.y-s.scrollTop*u.y+c.y+m.y}}function xf(e){return Array.from(e.getClientRects())}function wf(e){const t=Re(e),n=mn(e),r=e.ownerDocument.body,o=ne(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),l=ne(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let i=-n.scrollLeft+gn(e);const a=-n.scrollTop;return ye(r).direction==="rtl"&&(i+=ne(t.clientWidth,r.clientWidth)-o),{width:o,height:l,x:i,y:a}}const So=25;function yf(e,t){const n=de(e),r=Re(e),o=n.visualViewport;let l=r.clientWidth,i=r.clientHeight,a=0,s=0;if(o){l=o.width,i=o.height;const c=Or();(!c||c&&t==="fixed")&&(a=o.offsetLeft,s=o.offsetTop)}const u=gn(r);if(u<=0){const c=r.ownerDocument,d=c.body,m=getComputedStyle(d),f=c.compatMode==="CSS1Compat"&&parseFloat(m.marginLeft)+parseFloat(m.marginRight)||0,h=Math.abs(r.clientWidth-d.clientWidth-f);h<=So&&(l-=h)}else u<=So&&(l+=u);return{width:l,height:i,x:a,y:s}}const Ef=new Set(["absolute","fixed"]);function Cf(e,t){const n=Ze(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,l=ke(e)?nt(e):$e(1),i=e.clientWidth*l.x,a=e.clientHeight*l.y,s=o*l.x,u=r*l.y;return{width:i,height:a,x:s,y:u}}function $o(e,t,n){let r;if(t==="viewport")r=yf(e,n);else if(t==="document")r=wf(Re(e));else if(oe(t))r=Cf(t,n);else{const o=vi(e);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return nn(r)}function xi(e,t){const n=He(e);return n===t||!oe(n)||ot(n)?!1:ye(n).position==="fixed"||xi(n,t)}function Sf(e,t){const n=t.get(e);if(n)return n;let r=Et(e,[],!1).filter(a=>oe(a)&&ct(a)!=="body"),o=null;const l=ye(e).position==="fixed";let i=l?He(e):e;for(;oe(i)&&!ot(i);){const a=ye(i),s=Rr(i);!s&&a.position==="fixed"&&(o=null),(l?!s&&!o:!s&&a.position==="static"&&!!o&&Ef.has(o.position)||Pt(i)&&!s&&xi(e,i))?r=r.filter(c=>c!==i):o=a,i=He(i)}return t.set(e,r),r}function $f(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const i=[...n==="clippingAncestors"?pn(t)?[]:Sf(t,this._c):[].concat(n),r],a=i[0],s=i.reduce((u,c)=>{const d=$o(t,c,o);return u.top=ne(d.top,u.top),u.right=Ye(d.right,u.right),u.bottom=Ye(d.bottom,u.bottom),u.left=ne(d.left,u.left),u},$o(t,a,o));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}}function kf(e){const{width:t,height:n}=gi(e);return{width:t,height:n}}function Rf(e,t,n){const r=ke(t),o=Re(t),l=n==="fixed",i=Ze(e,!0,l,t);let a={scrollLeft:0,scrollTop:0};const s=$e(0);function u(){s.x=gn(o)}if(r||!r&&!l)if((ct(t)!=="body"||Pt(o))&&(a=mn(t)),r){const f=Ze(t,!0,l,t);s.x=f.x+t.clientLeft,s.y=f.y+t.clientTop}else o&&u();l&&!r&&o&&u();const c=o&&!r&&!l?bi(o,a):$e(0),d=i.left+a.scrollLeft-s.x-c.x,m=i.top+a.scrollTop-s.y-c.y;return{x:d,y:m,width:i.width,height:i.height}}function jn(e){return ye(e).position==="static"}function ko(e,t){if(!ke(e)||ye(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return Re(e)===n&&(n=n.ownerDocument.body),n}function wi(e,t){const n=de(e);if(pn(e))return n;if(!ke(e)){let o=He(e);for(;o&&!ot(o);){if(oe(o)&&!jn(o))return o;o=He(o)}return n}let r=ko(e,t);for(;r&&zd(r)&&jn(r);)r=ko(r,t);return r&&ot(r)&&jn(r)&&!Rr(r)?n:r||Kd(e)||n}const Of=async function(e){const t=this.getOffsetParent||wi,n=this.getDimensions,r=await n(e.floating);return{reference:Rf(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function Tf(e){return ye(e).direction==="rtl"}const Pf={convertOffsetParentRelativeRectToViewportRelativeRect:bf,getDocumentElement:Re,getClippingRect:$f,getOffsetParent:wi,getElementRects:Of,getClientRects:xf,getDimensions:kf,getScale:nt,isElement:oe,isRTL:Tf};function yi(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function Lf(e,t){let n=null,r;const o=Re(e);function l(){var a;clearTimeout(r),(a=n)==null||a.disconnect(),n=null}function i(a,s){a===void 0&&(a=!1),s===void 0&&(s=1),l();const u=e.getBoundingClientRect(),{left:c,top:d,width:m,height:f}=u;if(a||t(),!m||!f)return;const h=zt(d),v=zt(o.clientWidth-(c+m)),b=zt(o.clientHeight-(d+f)),x=zt(c),w={rootMargin:-h+"px "+-v+"px "+-b+"px "+-x+"px",threshold:ne(0,Ye(1,s))||1};let S=!0;function C(T){const O=T[0].intersectionRatio;if(O!==s){if(!S)return i();O?i(!1,O):r=setTimeout(()=>{i(!1,1e-7)},1e3)}O===1&&!yi(u,e.getBoundingClientRect())&&i(),S=!1}try{n=new IntersectionObserver(C,{...w,root:o.ownerDocument})}catch{n=new IntersectionObserver(C,w)}n.observe(e)}return i(!0),l}function Af(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:o=!0,ancestorResize:l=!0,elementResize:i=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:s=!1}=r,u=Tr(e),c=o||l?[...u?Et(u):[],...Et(t)]:[];c.forEach(x=>{o&&x.addEventListener("scroll",n,{passive:!0}),l&&x.addEventListener("resize",n)});const d=u&&a?Lf(u,n):null;let m=-1,f=null;i&&(f=new ResizeObserver(x=>{let[y]=x;y&&y.target===u&&f&&(f.unobserve(t),cancelAnimationFrame(m),m=requestAnimationFrame(()=>{var w;(w=f)==null||w.observe(t)})),n()}),u&&!s&&f.observe(u),f.observe(t));let h,v=s?Ze(e):null;s&&b();function b(){const x=Ze(e);v&&!yi(v,x)&&n(),v=x,h=requestAnimationFrame(b)}return n(),()=>{var x;c.forEach(y=>{o&&y.removeEventListener("scroll",n),l&&y.removeEventListener("resize",n)}),d?.(),(x=f)==null||x.disconnect(),f=null,s&&cancelAnimationFrame(h)}}const Dn=hn,Ff=pf,Mf=mf,Nf=cf,If=hf,jf=(e,t,n)=>{const r=new Map,o={platform:Pf,...n},l={...o.platform,_c:r};return uf(e,t,{...o,platform:l})};var Df=typeof document<"u",_f=function(){},Gt=Df?p.useLayoutEffect:_f;function rn(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,o;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!rn(e[r],t[r]))return!1;return!0}if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,o[r]))return!1;for(r=n;r--!==0;){const l=o[r];if(!(l==="_owner"&&e.$$typeof)&&!rn(e[l],t[l]))return!1}return!0}return e!==e&&t!==t}function Ei(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Ro(e,t){const n=Ei(e);return Math.round(t*n)/n}function _n(e){const t=g.useRef(e);return Gt(()=>{t.current=e}),t}function Bf(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:o,elements:{reference:l,floating:i}={},transform:a=!0,whileElementsMounted:s,open:u}=e,[c,d]=g.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[m,f]=g.useState(r);rn(m,r)||f(r);const[h,v]=g.useState(null),[b,x]=g.useState(null),y=g.useCallback($=>{$!==T.current&&(T.current=$,v($))},[]),w=g.useCallback($=>{$!==O.current&&(O.current=$,x($))},[]),S=l||h,C=i||b,T=g.useRef(null),O=g.useRef(null),k=g.useRef(c),A=s!=null,R=_n(s),M=_n(o),H=_n(u),z=g.useCallback(()=>{if(!T.current||!O.current)return;const $={placement:t,strategy:n,middleware:m};M.current&&($.platform=M.current),jf(T.current,O.current,$).then(V=>{const q={...V,isPositioned:H.current!==!1};B.current&&!rn(k.current,q)&&(k.current=q,Zt.flushSync(()=>{d(q)}))})},[m,t,n,M,H]);Gt(()=>{u===!1&&k.current.isPositioned&&(k.current.isPositioned=!1,d($=>({...$,isPositioned:!1})))},[u]);const B=g.useRef(!1);Gt(()=>(B.current=!0,()=>{B.current=!1}),[]),Gt(()=>{if(S&&(T.current=S),C&&(O.current=C),S&&C){if(R.current)return R.current(S,C,z);z()}},[S,C,z,R,A]);const F=g.useMemo(()=>({reference:T,floating:O,setReference:y,setFloating:w}),[y,w]),I=g.useMemo(()=>({reference:S,floating:C}),[S,C]),U=g.useMemo(()=>{const $={position:n,left:0,top:0};if(!I.floating)return $;const V=Ro(I.floating,c.x),q=Ro(I.floating,c.y);return a?{...$,transform:"translate("+V+"px, "+q+"px)",...Ei(I.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:V,top:q}},[n,a,I.floating,c.x,c.y]);return g.useMemo(()=>({...c,update:z,refs:F,elements:I,floatingStyles:U}),[c,z,F,I,U])}const Ci=(e,t)=>({...Ff(e),options:[e,t]}),Hf=(e,t)=>({...Mf(e),options:[e,t]}),Vf=(e,t)=>({...Nf(e),options:[e,t]}),zf=(e,t)=>({...If(e),options:[e,t]}),Si={...g},Wf=Si.useInsertionEffect,Uf=Wf||(e=>e());function $i(e){const t=g.useRef(()=>{if(process.env.NODE_ENV!=="production")throw new Error("Cannot call an event handler while rendering.")});return Uf(()=>{t.current=e}),g.useCallback(function(){for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];return t.current==null?void 0:t.current(...r)},[])}var or=typeof document<"u"?p.useLayoutEffect:p.useEffect;let Oo=!1,qf=0;const To=()=>"floating-ui-"+Math.random().toString(36).slice(2,6)+qf++;function Gf(){const[e,t]=g.useState(()=>Oo?To():void 0);return or(()=>{e==null&&t(To())},[]),g.useEffect(()=>{Oo=!0},[]),e}const Kf=Si.useId,Yf=Kf||Gf;let St;process.env.NODE_ENV!=="production"&&(St=new Set);function Zf(){for(var e,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];const o="Floating UI: "+n.join(" ");if(!((e=St)!=null&&e.has(o))){var l;(l=St)==null||l.add(o),console.warn(o)}}function Xf(){for(var e,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];const o="Floating UI: "+n.join(" ");if(!((e=St)!=null&&e.has(o))){var l;(l=St)==null||l.add(o),console.error(o)}}function Jf(){const e=new Map;return{emit(t,n){var r;(r=e.get(t))==null||r.forEach(o=>o(n))},on(t,n){e.set(t,[...e.get(t)||[],n])},off(t,n){var r;e.set(t,((r=e.get(t))==null?void 0:r.filter(o=>o!==n))||[])}}}const Qf=g.createContext(null),ep=g.createContext(null),tp=()=>{var e;return((e=g.useContext(Qf))==null?void 0:e.id)||null},np=()=>g.useContext(ep),rp="data-floating-ui-focusable";function op(e){const{open:t=!1,onOpenChange:n,elements:r}=e,o=Yf(),l=g.useRef({}),[i]=g.useState(()=>Jf()),a=tp()!=null;if(process.env.NODE_ENV!=="production"){const f=r.reference;f&&!oe(f)&&Xf("Cannot pass a virtual element to the `elements.reference` option,","as it must be a real DOM element. Use `refs.setPositionReference()`","instead.")}const[s,u]=g.useState(r.reference),c=$i((f,h,v)=>{l.current.openEvent=f?h:void 0,i.emit("openchange",{open:f,event:h,reason:v,nested:a}),n?.(f,h,v)}),d=g.useMemo(()=>({setPositionReference:u}),[]),m=g.useMemo(()=>({reference:s||r.reference||null,floating:r.floating||null,domReference:r.reference}),[s,r.reference,r.floating]);return g.useMemo(()=>({dataRef:l,open:t,onOpenChange:c,elements:m,events:i,floatingId:o,refs:d}),[t,c,m,i,o,d])}function lp(e){e===void 0&&(e={});const{nodeId:t}=e,n=op({...e,elements:{reference:null,floating:null,...e.elements}}),r=e.rootContext||n,o=r.elements,[l,i]=g.useState(null),[a,s]=g.useState(null),c=o?.domReference||l,d=g.useRef(null),m=np();or(()=>{c&&(d.current=c)},[c]);const f=Bf({...e,elements:{...o,...a&&{reference:a}}}),h=g.useCallback(w=>{const S=oe(w)?{getBoundingClientRect:()=>w.getBoundingClientRect(),contextElement:w}:w;s(S),f.refs.setReference(S)},[f.refs]),v=g.useCallback(w=>{(oe(w)||w===null)&&(d.current=w,i(w)),(oe(f.refs.reference.current)||f.refs.reference.current===null||w!==null&&!oe(w))&&f.refs.setReference(w)},[f.refs]),b=g.useMemo(()=>({...f.refs,setReference:v,setPositionReference:h,domReference:d}),[f.refs,v,h]),x=g.useMemo(()=>({...f.elements,domReference:c}),[f.elements,c]),y=g.useMemo(()=>({...f,...r,refs:b,elements:x,nodeId:t}),[f,b,x,t,r]);return or(()=>{r.dataRef.current.floatingContext=y;const w=m?.nodesRef.current.find(S=>S.id===t);w&&(w.context=y)}),g.useMemo(()=>({...f,context:y,refs:b,elements:x}),[f,b,x,y])}const Po="active",Lo="selected";function Bn(e,t,n){const r=new Map,o=n==="item";let l=e;if(o&&e){const{[Po]:i,[Lo]:a,...s}=e;l=s}return{...n==="floating"&&{tabIndex:-1,[rp]:""},...l,...t.map(i=>{const a=i?i[n]:null;return typeof a=="function"?e?a(e):null:a}).concat(e).reduce((i,a)=>(a&&Object.entries(a).forEach(s=>{let[u,c]=s;if(!(o&&[Po,Lo].includes(u)))if(u.indexOf("on")===0){if(r.has(u)||r.set(u,[]),typeof c=="function"){var d;(d=r.get(u))==null||d.push(c),i[u]=function(){for(var m,f=arguments.length,h=new Array(f),v=0;v<f;v++)h[v]=arguments[v];return(m=r.get(u))==null?void 0:m.map(b=>b(...h)).find(b=>b!==void 0)}}}else i[u]=c}),i),{})}}function ip(e){e===void 0&&(e=[]);const t=e.map(a=>a?.reference),n=e.map(a=>a?.floating),r=e.map(a=>a?.item),o=g.useCallback(a=>Bn(a,e,"reference"),t),l=g.useCallback(a=>Bn(a,e,"floating"),n),i=g.useCallback(a=>Bn(a,e,"item"),r);return g.useMemo(()=>({getReferenceProps:o,getFloatingProps:l,getItemProps:i}),[o,l,i])}function Ao(e,t){return{...e,rects:{...e.rects,floating:{...e.rects.floating,height:t}}}}const ap=e=>({name:"inner",options:e,async fn(t){const{listRef:n,overflowRef:r,onFallbackChange:o,offset:l=0,index:i=0,minItemsVisible:a=4,referenceOverflowThreshold:s=0,scrollRef:u,...c}=dt(e,t),{rects:d,elements:{floating:m}}=t,f=n.current[i],h=u?.current||m,v=m.clientTop||h.clientTop,b=m.clientTop!==0,x=h.clientTop!==0,y=m===h;if(process.env.NODE_ENV!=="production"&&(t.placement.startsWith("bottom")||Zf('`placement` side must be "bottom" when using the `inner`',"middleware.")),!f)return{};const w={...t,...await Ci(-f.offsetTop-m.clientTop-d.reference.height/2-f.offsetHeight/2-l).fn(t)},S=await Dn(Ao(w,h.scrollHeight+v+m.clientTop),c),C=await Dn(w,{...c,elementContext:"reference"}),T=ne(0,S.top),O=w.y+T,R=(h.scrollHeight>h.clientHeight?M=>M:Ct)(ne(0,h.scrollHeight+(b&&y||x?v*2:0)-T-ne(0,S.bottom)));if(h.style.maxHeight=R+"px",h.scrollTop=T,o){const M=h.offsetHeight<f.offsetHeight*Ye(a,n.current.length)-1||C.top>=-s||C.bottom>=-s;Zt.flushSync(()=>o(M))}return r&&(r.current=await Dn(Ao({...w,y:O},h.offsetHeight+v+m.clientTop),c)),{y:O}}});function sp(e,t){const{open:n,elements:r}=e,{enabled:o=!0,overflowRef:l,scrollRef:i,onChange:a}=t,s=$i(a),u=g.useRef(!1),c=g.useRef(null),d=g.useRef(null);g.useEffect(()=>{if(!o)return;function f(v){if(v.ctrlKey||!h||l.current==null)return;const b=v.deltaY,x=l.current.top>=-.5,y=l.current.bottom>=-.5,w=h.scrollHeight-h.clientHeight,S=b<0?-1:1,C=b<0?"max":"min";h.scrollHeight<=h.clientHeight||(!x&&b>0||!y&&b<0?(v.preventDefault(),Zt.flushSync(()=>{s(T=>T+Math[C](b,w*S))})):/firefox/i.test(Zd())&&(h.scrollTop+=b))}const h=i?.current||r.floating;if(n&&h)return h.addEventListener("wheel",f),requestAnimationFrame(()=>{c.current=h.scrollTop,l.current!=null&&(d.current={...l.current})}),()=>{c.current=null,d.current=null,h.removeEventListener("wheel",f)}},[o,n,r.floating,l,i,s]);const m=g.useMemo(()=>({onKeyDown(){u.current=!0},onWheel(){u.current=!1},onPointerMove(){u.current=!1},onScroll(){const f=i?.current||r.floating;if(!(!l.current||!f||!u.current)){if(c.current!==null){const h=f.scrollTop-c.current;(l.current.bottom<-.5&&h<-1||l.current.top<-.5&&h>1)&&Zt.flushSync(()=>s(v=>v+h))}requestAnimationFrame(()=>{c.current=f.scrollTop})}}}),[r.floating,s,l,i]);return g.useMemo(()=>o?{floating:m}:{},[o,m])}let ft=p.createContext({styles:void 0,setReference:()=>{},setFloating:()=>{},getReferenceProps:()=>({}),getFloatingProps:()=>({}),slot:{}});ft.displayName="FloatingContext";let Pr=p.createContext(null);Pr.displayName="PlacementContext";function up(e){return p.useMemo(()=>e?typeof e=="string"?{to:e}:e:null,[e])}function cp(){return p.useContext(ft).setReference}function dp(){return p.useContext(ft).getReferenceProps}function fp(){let{getFloatingProps:e,slot:t}=p.useContext(ft);return p.useCallback((...n)=>Object.assign({},e(...n),{"data-anchor":t.anchor}),[e,t])}function pp(e=null){e===!1&&(e=null),typeof e=="string"&&(e={to:e});let t=p.useContext(Pr),n=p.useMemo(()=>e,[JSON.stringify(e,(o,l)=>{var i;return(i=l?.outerHTML)!=null?i:l})]);X(()=>{t?.(n??null)},[t,n]);let r=p.useContext(ft);return p.useMemo(()=>[r.setFloating,e?r.styles:{}],[r.setFloating,e,r.styles])}let Fo=4;function mp({children:e,enabled:t=!0}){let[n,r]=p.useState(null),[o,l]=p.useState(0),i=p.useRef(null),[a,s]=p.useState(null);hp(a);let u=t&&n!==null&&a!==null,{to:c="bottom",gap:d=0,offset:m=0,padding:f=0,inner:h}=gp(n,a),[v,b="center"]=c.split(" ");X(()=>{u&&l(0)},[u]);let{refs:x,floatingStyles:y,context:w}=lp({open:u,placement:v==="selection"?b==="center"?"bottom":`bottom-${b}`:b==="center"?`${v}`:`${v}-${b}`,strategy:"absolute",transform:!1,middleware:[Ci({mainAxis:v==="selection"?0:d,crossAxis:m}),Hf({padding:f}),v!=="selection"&&Vf({padding:f}),v==="selection"&&h?ap({...h,padding:f,overflowRef:i,offset:o,minItemsVisible:Fo,referenceOverflowThreshold:f,onFallbackChange(M){var H,z;if(!M)return;let B=w.elements.floating;if(!B)return;let F=parseFloat(getComputedStyle(B).scrollPaddingBottom)||0,I=Math.min(Fo,B.childElementCount),U=0,$=0;for(let V of(z=(H=w.elements.floating)==null?void 0:H.childNodes)!=null?z:[])if(Ne(V)){let q=V.offsetTop,pe=q+V.clientHeight+F,K=B.scrollTop,_=K+B.clientHeight;if(q>=K&&pe<=_)I--;else{$=Math.max(0,Math.min(pe,_)-Math.max(q,K)),U=V.clientHeight;break}}I>=1&&l(V=>{let q=U*I-$+F;return V>=q?V:q})}}):null,zf({padding:f,apply({availableWidth:M,availableHeight:H,elements:z}){Object.assign(z.floating.style,{overflow:"auto",maxWidth:`${M}px`,maxHeight:`min(var(--anchor-max-height, 100vh), ${H}px)`})}})].filter(Boolean),whileElementsMounted:Af}),[S=v,C=b]=w.placement.split("-");v==="selection"&&(S="selection");let T=p.useMemo(()=>({anchor:[S,C].filter(Boolean).join(" ")}),[S,C]),O=sp(w,{overflowRef:i,onChange:l}),{getReferenceProps:k,getFloatingProps:A}=ip([O]),R=D(M=>{s(M),x.setFloating(M)});return g.createElement(Pr.Provider,{value:r},g.createElement(ft.Provider,{value:{setFloating:R,setReference:x.setReference,styles:y,getReferenceProps:k,getFloatingProps:A,slot:T}},e))}function hp(e){X(()=>{if(!e)return;let t=new MutationObserver(()=>{let n=window.getComputedStyle(e).maxHeight,r=parseFloat(n);if(isNaN(r))return;let o=parseInt(n);isNaN(o)||r!==o&&(e.style.maxHeight=`${Math.ceil(r)}px`)});return t.observe(e,{attributes:!0,attributeFilter:["style"]}),()=>{t.disconnect()}},[e])}function gp(e,t){var n,r,o;let l=Hn((n=e?.gap)!=null?n:"var(--anchor-gap, 0)",t),i=Hn((r=e?.offset)!=null?r:"var(--anchor-offset, 0)",t),a=Hn((o=e?.padding)!=null?o:"var(--anchor-padding, 0)",t);return{...e,gap:l,offset:i,padding:a}}function Hn(e,t,n=void 0){let r=Xe(),o=D((s,u)=>{if(s==null)return[n,null];if(typeof s=="number")return[s,null];if(typeof s=="string"){if(!u)return[n,null];let c=Mo(s,u);return[c,d=>{let m=ki(s);{let f=m.map(h=>window.getComputedStyle(u).getPropertyValue(h));r.requestAnimationFrame(function h(){r.nextFrame(h);let v=!1;for(let[x,y]of m.entries()){let w=window.getComputedStyle(u).getPropertyValue(y);if(f[x]!==w){f[x]=w,v=!0;break}}if(!v)return;let b=Mo(s,u);c!==b&&(d(b),c=b)})}return r.dispose}]}return[n,null]}),l=p.useMemo(()=>o(e,t)[0],[e,t]),[i=l,a]=p.useState();return X(()=>{let[s,u]=o(e,t);if(a(s),!!u)return u(a)},[e,t]),i}function ki(e){let t=/var\((.*)\)/.exec(e);if(t){let n=t[1].indexOf(",");if(n===-1)return[t[1]];let r=t[1].slice(0,n).trim(),o=t[1].slice(n+1).trim();return o?[r,...ki(o)]:[r]}return[]}function Mo(e,t){let n=document.createElement("div");t.appendChild(n),n.style.setProperty("margin-top","0px","important"),n.style.setProperty("margin-top",e,"important");let r=parseFloat(window.getComputedStyle(n).marginTop)||0;return t.removeChild(n),r}function vp({children:e,freeze:t},n){let r=Ri(t,e);return p.isValidElement(r)?p.cloneElement(r,{ref:n}):p.createElement(p.Fragment,null,r)}p.forwardRef(vp);function Ri(e,t){let[n,r]=p.useState(t);return!e&&n!==t&&r(t),e?n:t}let vn=p.createContext(null);vn.displayName="OpenClosedContext";var ae=(e=>(e[e.Open=1]="Open",e[e.Closed=2]="Closed",e[e.Closing=4]="Closing",e[e.Opening=8]="Opening",e))(ae||{});function bn(){return p.useContext(vn)}function Lr({value:e,children:t}){return p.createElement(vn.Provider,{value:e},t)}function bp({children:e}){return p.createElement(vn.Provider,{value:null},e)}function xp(e){throw new Error("Unexpected object: "+e)}var Z=(e=>(e[e.First=0]="First",e[e.Previous=1]="Previous",e[e.Next=2]="Next",e[e.Last=3]="Last",e[e.Specific=4]="Specific",e[e.Nothing=5]="Nothing",e))(Z||{});function Wt(e,t){let n=t.resolveItems();if(n.length<=0)return null;let r=t.resolveActiveIndex(),o=r??-1;switch(e.focus){case 0:{for(let l=0;l<n.length;++l)if(!t.resolveDisabled(n[l],l,n))return l;return r}case 1:{o===-1&&(o=n.length);for(let l=o-1;l>=0;--l)if(!t.resolveDisabled(n[l],l,n))return l;return r}case 2:{for(let l=o+1;l<n.length;++l)if(!t.resolveDisabled(n[l],l,n))return l;return r}case 3:{for(let l=n.length-1;l>=0;--l)if(!t.resolveDisabled(n[l],l,n))return l;return r}case 4:{for(let l=0;l<n.length;++l)if(t.resolveId(n[l],l,n)===e.id)return l;return r}case 5:return null;default:xp(e)}}function Oi(e){let t=D(e),n=p.useRef(!1);p.useEffect(()=>(n.current=!1,()=>{n.current=!0,jl(()=>{n.current&&t()})}),[t])}let wp=p.createContext(!1);function yp(){return p.useContext(wp)}function Ep(e){let t=yp(),n=p.useContext(Pi),[r,o]=p.useState(()=>{var l;if(!t&&n!==null)return(l=n.current)!=null?l:null;if(Se.isServer)return null;let i=e?.getElementById("headlessui-portal-root");if(i)return i;if(e===null)return null;let a=e.createElement("div");return a.setAttribute("id","headlessui-portal-root"),e.body.appendChild(a)});return p.useEffect(()=>{r!==null&&(e!=null&&e.body.contains(r)||e==null||e.body.appendChild(r))},[r,e]),p.useEffect(()=>{t||n!==null&&o(n.current)},[n,o,t]),r}let Ti=p.Fragment,Cp=Q(function(e,t){let{ownerDocument:n=null,...r}=e,o=p.useRef(null),l=ue(Kl(m=>{o.current=m}),t),i=tr(o.current),a=n??i,s=Ep(a),u=p.useContext(Rp),c=Xe(),d=te();return Oi(()=>{var m;s&&s.childNodes.length<=0&&((m=s.parentElement)==null||m.removeChild(s))}),s?Ge.createPortal(p.createElement("div",{"data-headlessui-portal":"",ref:m=>{c.dispose(),u&&m&&c.add(u.register(m))}},d({ourProps:{ref:l},theirProps:r,slot:{},defaultTag:Ti,name:"Portal"})),s):null});function Sp(e,t){let n=ue(t),{enabled:r=!0,ownerDocument:o,...l}=e,i=te();return r?p.createElement(Cp,{...l,ownerDocument:o,ref:n}):i({ourProps:{ref:n},theirProps:l,slot:{},defaultTag:Ti,name:"Portal"})}let $p=p.Fragment,Pi=p.createContext(null);function kp(e,t){let{target:n,...r}=e,o={ref:ue(t)},l=te();return p.createElement(Pi.Provider,{value:n},l({ourProps:o,theirProps:r,defaultTag:$p,name:"Popover.Group"}))}let Rp=p.createContext(null),Op=Q(Sp),Tp=Q(kp),Pp=Object.assign(Op,{Group:Tp});const Kt={Idle:{kind:"Idle"},Tracked:e=>({kind:"Tracked",position:e}),Moved:{kind:"Moved"}};function Li(e){let t=e.getBoundingClientRect();return`${t.x},${t.y}`}function Lp(e,t,n){let r=fe();if(t.kind==="Tracked"){let o=function(){l!==Li(e)&&(r.dispose(),n())},{position:l}=t,i=new ResizeObserver(o);i.observe(e),r.add(()=>i.disconnect()),r.addEventListener(window,"scroll",o,{passive:!0}),r.addEventListener(window,"resize",o)}return()=>r.dispose()}function Ap(){let e=typeof document>"u";return"useSyncExternalStore"in g?(t=>t.useSyncExternalStore)(g)(()=>()=>{},()=>!1,()=>!e):!1}function Ai(){let e=Ap(),[t,n]=g.useState(Se.isHandoffComplete);return t&&Se.isHandoffComplete===!1&&n(!1),g.useEffect(()=>{t!==!0&&n(!0)},[t]),g.useEffect(()=>Se.handoff(),[]),e?!1:t}function Fp(){let e=p.useRef(!1);return X(()=>(e.current=!0,()=>{e.current=!1}),[]),e}function Fi(e){var t;return!!(e.enter||e.enterFrom||e.enterTo||e.leave||e.leaveFrom||e.leaveTo)||!tt((t=e.as)!=null?t:Ni)||p.Children.count(e.children)===1}let xn=p.createContext(null);xn.displayName="TransitionContext";var Mp=(e=>(e.Visible="visible",e.Hidden="hidden",e))(Mp||{});function Np(){let e=p.useContext(xn);if(e===null)throw new Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return e}function Ip(){let e=p.useContext(wn);if(e===null)throw new Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return e}let wn=p.createContext(null);wn.displayName="NestingContext";function yn(e){return"children"in e?yn(e.children):e.current.filter(({el:t})=>t.current!==null).filter(({state:t})=>t==="visible").length>0}function Mi(e,t){let n=Je(e),r=p.useRef([]),o=Fp(),l=Xe(),i=D((f,h=De.Hidden)=>{let v=r.current.findIndex(({el:b})=>b===f);v!==-1&&(se(h,{[De.Unmount](){r.current.splice(v,1)},[De.Hidden](){r.current[v].state="hidden"}}),l.microTask(()=>{var b;!yn(r)&&o.current&&((b=n.current)==null||b.call(n))}))}),a=D(f=>{let h=r.current.find(({el:v})=>v===f);return h?h.state!=="visible"&&(h.state="visible"):r.current.push({el:f,state:"visible"}),()=>i(f,De.Unmount)}),s=p.useRef([]),u=p.useRef(Promise.resolve()),c=p.useRef({enter:[],leave:[]}),d=D((f,h,v)=>{s.current.splice(0),t&&(t.chains.current[h]=t.chains.current[h].filter(([b])=>b!==f)),t?.chains.current[h].push([f,new Promise(b=>{s.current.push(b)})]),t?.chains.current[h].push([f,new Promise(b=>{Promise.all(c.current[h].map(([x,y])=>y)).then(()=>b())})]),h==="enter"?u.current=u.current.then(()=>t?.wait.current).then(()=>v(h)):v(h)}),m=D((f,h,v)=>{Promise.all(c.current[h].splice(0).map(([b,x])=>x)).then(()=>{var b;(b=s.current.shift())==null||b()}).then(()=>v(h))});return p.useMemo(()=>({children:r,register:a,unregister:i,onStart:d,onStop:m,wait:u,chains:c}),[a,i,r,d,m,c,u])}let Ni=p.Fragment,Ii=rt.RenderStrategy;function jp(e,t){var n,r;let{transition:o=!0,beforeEnter:l,afterEnter:i,beforeLeave:a,afterLeave:s,enter:u,enterFrom:c,enterTo:d,entered:m,leave:f,leaveFrom:h,leaveTo:v,...b}=e,[x,y]=p.useState(null),w=p.useRef(null),S=Fi(e),C=ue(...S?[w,t,y]:t===null?[]:[t]),T=(n=b.unmount)==null||n?De.Unmount:De.Hidden,{show:O,appear:k,initial:A}=Np(),[R,M]=p.useState(O?"visible":"hidden"),H=Ip(),{register:z,unregister:B}=H;X(()=>z(w),[z,w]),X(()=>{if(T===De.Hidden&&w.current){if(O&&R!=="visible"){M("visible");return}return se(R,{hidden:()=>B(w),visible:()=>z(w)})}},[R,w,z,B,O,T]);let F=Ai();X(()=>{if(S&&F&&R==="visible"&&w.current===null)throw new Error("Did you forget to passthrough the `ref` to the actual DOM node?")},[w,R,F,S]);let I=A&&!k,U=k&&O&&A,$=p.useRef(!1),V=Mi(()=>{$.current||(M("hidden"),B(w))},H),q=D(W=>{$.current=!0;let xe=W?"enter":"leave";V.onStart(w,xe,he=>{he==="enter"?l?.():he==="leave"&&a?.()})}),pe=D(W=>{let xe=W?"enter":"leave";$.current=!1,V.onStop(w,xe,he=>{he==="enter"?i?.():he==="leave"&&s?.()}),xe==="leave"&&!yn(V)&&(M("hidden"),B(w))});p.useEffect(()=>{S&&o||(q(O),pe(O))},[O,S,o]);let K=!(!o||!S||!F||I),[,_]=kr(K,x,O,{start:q,end:pe}),ee=je({ref:C,className:((r=Zn(b.className,U&&u,U&&c,_.enter&&u,_.enter&&_.closed&&c,_.enter&&!_.closed&&d,_.leave&&f,_.leave&&!_.closed&&h,_.leave&&_.closed&&v,!_.transition&&O&&m))==null?void 0:r.trim())||void 0,...$r(_)}),me=0;R==="visible"&&(me|=ae.Open),R==="hidden"&&(me|=ae.Closed),O&&R==="hidden"&&(me|=ae.Opening),!O&&R==="visible"&&(me|=ae.Closing);let N=te();return p.createElement(wn.Provider,{value:V},p.createElement(Lr,{value:me},N({ourProps:ee,theirProps:b,defaultTag:Ni,features:Ii,visible:R==="visible",name:"Transition.Child"})))}function Dp(e,t){let{show:n,appear:r=!1,unmount:o=!0,...l}=e,i=p.useRef(null),a=Fi(e),s=ue(...a?[i,t]:t===null?[]:[t]);Ai();let u=bn();if(n===void 0&&u!==null&&(n=(u&ae.Open)===ae.Open),n===void 0)throw new Error("A <Transition /> is used but it is missing a `show={true | false}` prop.");let[c,d]=p.useState(n?"visible":"hidden"),m=Mi(()=>{n||d("hidden")}),[f,h]=p.useState(!0),v=p.useRef([n]);X(()=>{f!==!1&&v.current[v.current.length-1]!==n&&(v.current.push(n),h(!1))},[v,n]);let b=p.useMemo(()=>({show:n,appear:r,initial:f}),[n,r,f]);X(()=>{n?d("visible"):!yn(m)&&i.current!==null&&d("hidden")},[n,m]);let x={unmount:o},y=D(()=>{var C;f&&h(!1),(C=e.beforeEnter)==null||C.call(e)}),w=D(()=>{var C;f&&h(!1),(C=e.beforeLeave)==null||C.call(e)}),S=te();return p.createElement(wn.Provider,{value:m},p.createElement(xn.Provider,{value:b},S({ourProps:{...x,as:p.Fragment,children:p.createElement(ji,{ref:s,...x,...l,beforeEnter:y,beforeLeave:w})},theirProps:{},defaultTag:p.Fragment,features:Ii,visible:c==="visible",name:"Transition"})))}function _p(e,t){let n=p.useContext(xn)!==null,r=bn()!==null;return p.createElement(p.Fragment,null,!n&&r?p.createElement(lr,{ref:t,...e}):p.createElement(ji,{ref:t,...e}))}let lr=Q(Dp),ji=Q(jp),Bp=Q(_p),Hp=Object.assign(lr,{Child:Bp,Root:lr});var No;let Vp=(No=p.startTransition)!=null?No:function(e){e()};var zp=(e=>(e[e.Open=0]="Open",e[e.Closed=1]="Closed",e))(zp||{}),Wp=(e=>(e[e.ToggleDisclosure=0]="ToggleDisclosure",e[e.CloseDisclosure=1]="CloseDisclosure",e[e.SetButtonId=2]="SetButtonId",e[e.SetPanelId=3]="SetPanelId",e[e.SetButtonElement=4]="SetButtonElement",e[e.SetPanelElement=5]="SetPanelElement",e))(Wp||{});let Up={0:e=>({...e,disclosureState:se(e.disclosureState,{0:1,1:0})}),1:e=>e.disclosureState===1?e:{...e,disclosureState:1},2(e,t){return e.buttonId===t.buttonId?e:{...e,buttonId:t.buttonId}},3(e,t){return e.panelId===t.panelId?e:{...e,panelId:t.panelId}},4(e,t){return e.buttonElement===t.element?e:{...e,buttonElement:t.element}},5(e,t){return e.panelElement===t.element?e:{...e,panelElement:t.element}}},Ar=p.createContext(null);Ar.displayName="DisclosureContext";function Fr(e){let t=p.useContext(Ar);if(t===null){let n=new Error(`<${e} /> is missing a parent <Disclosure /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,Fr),n}return t}let Mr=p.createContext(null);Mr.displayName="DisclosureAPIContext";function Di(e){let t=p.useContext(Mr);if(t===null){let n=new Error(`<${e} /> is missing a parent <Disclosure /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,Di),n}return t}let Nr=p.createContext(null);Nr.displayName="DisclosurePanelContext";function qp(){return p.useContext(Nr)}function Gp(e,t){return se(t.type,Up,e,t)}let Kp=p.Fragment;function Yp(e,t){let{defaultOpen:n=!1,...r}=e,o=p.useRef(null),l=ue(t,Kl(v=>{o.current=v},e.as===void 0||tt(e.as))),i=p.useReducer(Gp,{disclosureState:n?0:1,buttonElement:null,panelElement:null,buttonId:null,panelId:null}),[{disclosureState:a,buttonId:s},u]=i,c=D(v=>{u({type:1});let b=Tt(o.current);if(!b||!s)return;let x=v?_e(v)?v:"current"in v&&_e(v.current)?v.current:b.getElementById(s):b.getElementById(s);x?.focus()}),d=p.useMemo(()=>({close:c}),[c]),m=be({open:a===0,close:c}),f={ref:l},h=te();return p.createElement(Ar.Provider,{value:i},p.createElement(Mr.Provider,{value:d},p.createElement(Gc,{value:c},p.createElement(Lr,{value:se(a,{0:ae.Open,1:ae.Closed})},h({ourProps:f,theirProps:r,slot:m,defaultTag:Kp,name:"Disclosure"})))))}let Zp="button";function Xp(e,t){let n=p.useId(),{id:r=`headlessui-disclosure-button-${n}`,disabled:o=!1,autoFocus:l=!1,...i}=e,[a,s]=Fr("Disclosure.Button"),u=qp(),c=u===null?!1:u===a.panelId,d=p.useRef(null),m=ue(d,t,D(A=>{if(!c)return s({type:4,element:A})}));p.useEffect(()=>{if(!c)return s({type:2,buttonId:r}),()=>{s({type:2,buttonId:null})}},[r,s,c]);let f=D(A=>{var R;if(c){if(a.disclosureState===1)return;switch(A.key){case Y.Space:case Y.Enter:A.preventDefault(),A.stopPropagation(),s({type:0}),(R=a.buttonElement)==null||R.focus();break}}else switch(A.key){case Y.Space:case Y.Enter:A.preventDefault(),A.stopPropagation(),s({type:0});break}}),h=D(A=>{A.key===Y.Space&&A.preventDefault()}),v=D(A=>{var R;Xn(A.currentTarget)||o||(c?(s({type:0}),(R=a.buttonElement)==null||R.focus()):s({type:0}))}),{isFocusVisible:b,focusProps:x}=xr({autoFocus:l}),{isHovered:y,hoverProps:w}=br({isDisabled:o}),{pressed:S,pressProps:C}=wr({disabled:o}),T=be({open:a.disclosureState===0,hover:y,active:S,disabled:o,focus:b,autofocus:l}),O=ci(e,a.buttonElement),k=yt(c?{ref:m,type:O,disabled:o||void 0,autoFocus:l,onKeyDown:f,onClick:v}:{ref:m,id:r,type:O,"aria-expanded":a.disclosureState===0,"aria-controls":a.panelElement?a.panelId:void 0,disabled:o||void 0,autoFocus:l,onKeyDown:f,onKeyUp:h,onClick:v},x,w,C);return te()({ourProps:k,theirProps:i,slot:T,defaultTag:Zp,name:"Disclosure.Button"})}let Jp="div",Qp=rt.RenderStrategy|rt.Static;function em(e,t){let n=p.useId(),{id:r=`headlessui-disclosure-panel-${n}`,transition:o=!1,...l}=e,[i,a]=Fr("Disclosure.Panel"),{close:s}=Di("Disclosure.Panel"),[u,c]=p.useState(null),d=ue(t,D(y=>{Vp(()=>a({type:5,element:y}))}),c);p.useEffect(()=>(a({type:3,panelId:r}),()=>{a({type:3,panelId:null})}),[r,a]);let m=bn(),[f,h]=kr(o,u,m!==null?(m&ae.Open)===ae.Open:i.disclosureState===0),v=be({open:i.disclosureState===0,close:s}),b={ref:d,id:r,...$r(h)},x=te();return p.createElement(bp,null,p.createElement(Nr.Provider,{value:i.panelId},x({ourProps:b,theirProps:l,slot:v,defaultTag:Jp,features:Qp,visible:f,name:"Disclosure.Panel"})))}let tm=Q(Yp),_i=Q(Xp),Bi=Q(em),nm=Object.assign(tm,{Button:_i,Panel:Bi}),Io=/([\u2700-\u27BF]|[\uE000-\uF8FF]|\uD83C[\uDC00-\uDFFF]|\uD83D[\uDC00-\uDFFF]|[\u2011-\u26FF]|\uD83E[\uDD10-\uDDFF])/g;function jo(e){var t,n;let r=(t=e.innerText)!=null?t:"",o=e.cloneNode(!0);if(!Ne(o))return r;let l=!1;for(let a of o.querySelectorAll('[hidden],[aria-hidden],[role="img"]'))a.remove(),l=!0;let i=l?(n=o.innerText)!=null?n:"":r;return Io.test(i)&&(i=i.replace(Io,"")),i}function rm(e){let t=e.getAttribute("aria-label");if(typeof t=="string")return t.trim();let n=e.getAttribute("aria-labelledby");if(n){let r=n.split(" ").map(o=>{let l=document.getElementById(o);if(l){let i=l.getAttribute("aria-label");return typeof i=="string"?i.trim():jo(l).trim()}return null}).filter(Boolean);if(r.length>0)return r.join(", ")}return jo(e).trim()}function om(e){let t=p.useRef(""),n=p.useRef("");return D(()=>{let r=e.current;if(!r)return"";let o=r.innerText;if(t.current===o)return n.current;let l=rm(r).trim().toLowerCase();return t.current=o,n.current=l,l})}var lm=Object.defineProperty,im=(e,t,n)=>t in e?lm(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Do=(e,t,n)=>(im(e,typeof t!="symbol"?t+"":t,n),n),re=(e=>(e[e.Open=0]="Open",e[e.Closed=1]="Closed",e))(re||{}),Be=(e=>(e[e.Single=0]="Single",e[e.Multi=1]="Multi",e))(Be||{}),Yt=(e=>(e[e.Pointer=0]="Pointer",e[e.Other=1]="Other",e))(Yt||{}),Hi=(e=>(e[e.OpenListbox=0]="OpenListbox",e[e.CloseListbox=1]="CloseListbox",e[e.GoToOption=2]="GoToOption",e[e.Search=3]="Search",e[e.ClearSearch=4]="ClearSearch",e[e.SelectOption=5]="SelectOption",e[e.RegisterOptions=6]="RegisterOptions",e[e.UnregisterOptions=7]="UnregisterOptions",e[e.SetButtonElement=8]="SetButtonElement",e[e.SetOptionsElement=9]="SetOptionsElement",e[e.SortOptions=10]="SortOptions",e[e.MarkButtonAsMoved=11]="MarkButtonAsMoved",e))(Hi||{});function _o(e,t=n=>n){let n=e.activeOptionIndex!==null?e.options[e.activeOptionIndex]:null,r=si(t(e.options.slice()),l=>l.dataRef.current.domRef.current),o=n?r.indexOf(n):null;return o===-1&&(o=null),{options:r,activeOptionIndex:o}}let am={1(e){if(e.dataRef.current.disabled||e.listboxState===1)return e;let t=e.buttonElement?Kt.Tracked(Li(e.buttonElement)):e.buttonPositionState;return{...e,activeOptionIndex:null,pendingFocus:{focus:Z.Nothing},listboxState:1,__demoMode:!1,buttonPositionState:t}},0(e,t){if(e.dataRef.current.disabled||e.listboxState===0)return e;let n=e.activeOptionIndex,{isSelected:r}=e.dataRef.current,o=e.options.findIndex(l=>r(l.dataRef.current.value));return o!==-1&&(n=o),{...e,frozenValue:!1,pendingFocus:t.focus,listboxState:0,activeOptionIndex:n,__demoMode:!1,buttonPositionState:Kt.Idle}},2(e,t){var n,r,o,l,i;if(e.dataRef.current.disabled||e.listboxState===1)return e;let a={...e,searchQuery:"",activationTrigger:(n=t.trigger)!=null?n:1,__demoMode:!1};if(t.focus===Z.Nothing)return{...a,activeOptionIndex:null};if(t.focus===Z.Specific)return{...a,activeOptionIndex:e.options.findIndex(c=>c.id===t.id)};if(t.focus===Z.Previous){let c=e.activeOptionIndex;if(c!==null){let d=e.options[c].dataRef.current.domRef,m=Wt(t,{resolveItems:()=>e.options,resolveActiveIndex:()=>e.activeOptionIndex,resolveId:f=>f.id,resolveDisabled:f=>f.dataRef.current.disabled});if(m!==null){let f=e.options[m].dataRef.current.domRef;if(((r=d.current)==null?void 0:r.previousElementSibling)===f.current||((o=f.current)==null?void 0:o.previousElementSibling)===null)return{...a,activeOptionIndex:m}}}}else if(t.focus===Z.Next){let c=e.activeOptionIndex;if(c!==null){let d=e.options[c].dataRef.current.domRef,m=Wt(t,{resolveItems:()=>e.options,resolveActiveIndex:()=>e.activeOptionIndex,resolveId:f=>f.id,resolveDisabled:f=>f.dataRef.current.disabled});if(m!==null){let f=e.options[m].dataRef.current.domRef;if(((l=d.current)==null?void 0:l.nextElementSibling)===f.current||((i=f.current)==null?void 0:i.nextElementSibling)===null)return{...a,activeOptionIndex:m}}}}let s=_o(e),u=Wt(t,{resolveItems:()=>s.options,resolveActiveIndex:()=>s.activeOptionIndex,resolveId:c=>c.id,resolveDisabled:c=>c.dataRef.current.disabled});return{...a,...s,activeOptionIndex:u}},3:(e,t)=>{if(e.dataRef.current.disabled||e.listboxState===1)return e;let n=e.searchQuery!==""?0:1,r=e.searchQuery+t.value.toLowerCase(),o=(e.activeOptionIndex!==null?e.options.slice(e.activeOptionIndex+n).concat(e.options.slice(0,e.activeOptionIndex+n)):e.options).find(i=>{var a;return!i.dataRef.current.disabled&&((a=i.dataRef.current.textValue)==null?void 0:a.startsWith(r))}),l=o?e.options.indexOf(o):-1;return l===-1||l===e.activeOptionIndex?{...e,searchQuery:r}:{...e,searchQuery:r,activeOptionIndex:l,activationTrigger:1}},4(e){return e.dataRef.current.disabled||e.listboxState===1||e.searchQuery===""?e:{...e,searchQuery:""}},5(e){return e.dataRef.current.mode===0?{...e,frozenValue:!0}:{...e}},6:(e,t)=>{let n=e.options.concat(t.options),r=e.activeOptionIndex;if(e.pendingFocus.focus!==Z.Nothing&&(r=Wt(e.pendingFocus,{resolveItems:()=>n,resolveActiveIndex:()=>e.activeOptionIndex,resolveId:o=>o.id,resolveDisabled:o=>o.dataRef.current.disabled})),e.activeOptionIndex===null){let{isSelected:o}=e.dataRef.current;if(o){let l=n.findIndex(i=>o?.(i.dataRef.current.value));l!==-1&&(r=l)}}return{...e,options:n,activeOptionIndex:r,pendingFocus:{focus:Z.Nothing},pendingShouldSort:!0}},7:(e,t)=>{let n=e.options,r=[],o=new Set(t.options);for(let[l,i]of n.entries())if(o.has(i.id)&&(r.push(l),o.delete(i.id),o.size===0))break;if(r.length>0){n=n.slice();for(let l of r.reverse())n.splice(l,1)}return{...e,options:n,activationTrigger:1}},8:(e,t)=>e.buttonElement===t.element?e:{...e,buttonElement:t.element},9:(e,t)=>e.optionsElement===t.element?e:{...e,optionsElement:t.element},10:e=>e.pendingShouldSort?{...e,..._o(e),pendingShouldSort:!1}:e,11(e){return e.buttonPositionState.kind!=="Tracked"?e:{...e,buttonPositionState:Kt.Moved}}};class Ir extends ti{constructor(t){super(t),Do(this,"actions",{onChange:n=>{let{onChange:r,compare:o,mode:l,value:i}=this.state.dataRef.current;return se(l,{0:()=>r?.(n),1:()=>{let a=i.slice(),s=a.findIndex(u=>o(u,n));return s===-1?a.push(n):a.splice(s,1),r?.(a)}})},registerOption:Mn(()=>{let n=[],r=new Set;return[(o,l)=>{r.has(l)||(r.add(l),n.push({id:o,dataRef:l}))},()=>(r.clear(),this.send({type:6,options:n.splice(0)}))]}),unregisterOption:Mn(()=>{let n=[];return[r=>n.push(r),()=>{this.send({type:7,options:n.splice(0)})}]}),goToOption:Mn(()=>{let n=null;return[(r,o)=>{n={type:2,...r,trigger:o}},()=>n&&this.send(n)]}),closeListbox:()=>{this.send({type:1})},openListbox:n=>{this.send({type:0,focus:n})},selectActiveOption:()=>{var n;if(this.state.activeOptionIndex!==null){let{dataRef:r}=this.state.options[this.state.activeOptionIndex];this.actions.selectOption(r.current.value)}else this.state.dataRef.current.mode===0&&(this.actions.closeListbox(),(n=this.state.buttonElement)==null||n.focus({preventScroll:!0}))},selectOption:n=>{this.send({type:5,value:n})},search:n=>{this.send({type:3,value:n})},clearSearch:()=>{this.send({type:4})},setButtonElement:n=>{this.send({type:8,element:n})},setOptionsElement:n=>{this.send({type:9,element:n})}}),Do(this,"selectors",{activeDescendantId(n){var r;let o=n.activeOptionIndex,l=n.options;return o===null||(r=l[o])==null?void 0:r.id},isActive(n,r){var o;let l=n.activeOptionIndex,i=n.options;return l!==null?((o=i[l])==null?void 0:o.id)===r:!1},hasFrozenValue(n){return n.frozenValue},shouldScrollIntoView(n,r){return n.__demoMode||n.listboxState!==0||n.activationTrigger===0?!1:this.isActive(n,r)},didButtonMove(n){return n.buttonPositionState.kind==="Moved"}}),this.on(6,()=>{requestAnimationFrame(()=>{this.send({type:10})})});{let n=this.state.id,r=Cr.get(null);this.disposables.add(r.on(ri.Push,o=>{!r.selectors.isTop(o,n)&&this.state.listboxState===0&&this.actions.closeListbox()})),this.on(0,()=>r.actions.push(n)),this.on(1,()=>r.actions.pop(n))}this.disposables.group(n=>{this.on(1,r=>{r.buttonElement&&(n.dispose(),n.add(Lp(r.buttonElement,r.buttonPositionState,()=>{this.send({type:11})})))})}),this.on(5,(n,r)=>{var o;this.actions.onChange(r.value),this.state.dataRef.current.mode===0&&(this.actions.closeListbox(),(o=this.state.buttonElement)==null||o.focus({preventScroll:!0}))})}static new({id:t,__demoMode:n=!1}){return new Ir({id:t,dataRef:{current:{}},listboxState:n?0:1,options:[],searchQuery:"",activeOptionIndex:null,activationTrigger:1,buttonElement:null,optionsElement:null,pendingShouldSort:!1,pendingFocus:{focus:Z.Nothing},frozenValue:!1,__demoMode:n,buttonPositionState:Kt.Idle})}reduce(t,n){return se(n.type,am,t,n)}}const Vi=p.createContext(null);function jr(e){let t=p.useContext(Vi);if(t===null){let n=new Error(`<${e} /> is missing a parent <Listbox /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,zi),n}return t}function zi({id:e,__demoMode:t=!1}){let n=p.useMemo(()=>Ir.new({id:e,__demoMode:t}),[]);return Oi(()=>n.dispose()),n}let En=p.createContext(null);En.displayName="ListboxDataContext";function At(e){let t=p.useContext(En);if(t===null){let n=new Error(`<${e} /> is missing a parent <Listbox /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,At),n}return t}let sm=p.Fragment;function um(e,t){let n=p.useId(),r=un(),{value:o,defaultValue:l,form:i,name:a,onChange:s,by:u,invalid:c=!1,disabled:d=r||!1,horizontal:m=!1,multiple:f=!1,__demoMode:h=!1,...v}=e;const b=m?"horizontal":"vertical";let x=ue(t),y=Ec(l),[w=f?[]:void 0,S]=yc(o,s,y),C=zi({id:n,__demoMode:h}),T=p.useRef({static:!1,hold:!1}),O=p.useRef(new Map),k=Yc(u),A=p.useCallback(K=>se(R.mode,{[Be.Multi]:()=>w.some(_=>k(_,K)),[Be.Single]:()=>k(w,K)}),[w]),R=be({value:w,disabled:d,invalid:c,mode:f?Be.Multi:Be.Single,orientation:b,onChange:S,compare:k,isSelected:A,optionsPropsRef:T,listRef:O});X(()=>{C.state.dataRef.current=R},[R]);let M=ce(C,K=>K.listboxState),H=Cr.get(null),z=ce(H,p.useCallback(K=>H.selectors.isTop(K,n),[H,n])),[B,F]=ce(C,K=>[K.buttonElement,K.optionsElement]);Cd(z,[B,F],(K,_)=>{C.send({type:Hi.CloseListbox}),ai(_,Sr.Loose)||(K.preventDefault(),B?.focus())});let I=be({open:M===re.Open,disabled:d,invalid:c,value:w}),[U,$]=Hc({inherit:!0}),V={ref:x},q=p.useCallback(()=>{if(y!==void 0)return S?.(y)},[S,y]),pe=te();return p.createElement($,{value:U,props:{htmlFor:B?.id},slot:{open:M===re.Open,disabled:d}},p.createElement(mp,null,p.createElement(Vi.Provider,{value:C},p.createElement(En.Provider,{value:R},p.createElement(Lr,{value:se(M,{[re.Open]:ae.Open,[re.Closed]:ae.Closed})},a!=null&&w!=null&&p.createElement(Tc,{disabled:d,data:{[a]:w},form:i,onReset:q}),pe({ourProps:V,theirProps:v,slot:I,defaultTag:sm,name:"Listbox"}))))))}let cm="button";function dm(e,t){let n=p.useId(),r=zl(),o=At("Listbox.Button"),l=jr("Listbox.Button"),{id:i=r||`headlessui-listbox-button-${n}`,disabled:a=o.disabled||!1,autoFocus:s=!1,...u}=e,c=ue(t,cp(),l.actions.setButtonElement),d=dp(),[m,f,h]=ce(l,F=>[F.listboxState,F.buttonElement,F.optionsElement]),v=m===re.Open;kd(v,{trigger:f,action:p.useCallback(F=>{if(f!=null&&f.contains(F.target))return Vt.Ignore;let I=F.target.closest('[role="option"]:not([data-disabled])');return Ne(I)?Vt.Select(I):h!=null&&h.contains(F.target)?Vt.Ignore:Vt.Close},[f,h]),close:l.actions.closeListbox,select:l.actions.selectActiveOption});let b=D(F=>{switch(F.key){case Y.Enter:Cc(F.currentTarget);break;case Y.Space:case Y.ArrowDown:F.preventDefault(),l.actions.openListbox({focus:o.value?Z.Nothing:Z.First});break;case Y.ArrowUp:F.preventDefault(),l.actions.openListbox({focus:o.value?Z.Nothing:Z.Last});break}}),x=D(F=>{F.key===Y.Space&&F.preventDefault()}),y=Xc(F=>{var I;l.state.listboxState===re.Open?(Ge.flushSync(()=>l.actions.closeListbox()),(I=l.state.buttonElement)==null||I.focus({preventScroll:!0})):(F.preventDefault(),l.actions.openListbox({focus:Z.Nothing}))}),w=D(F=>F.preventDefault()),S=Xl([i]),C=jc(),{isFocusVisible:T,focusProps:O}=xr({autoFocus:s}),{isHovered:k,hoverProps:A}=br({isDisabled:a}),{pressed:R,pressProps:M}=wr({disabled:a}),H=be({open:m===re.Open,active:R||m===re.Open,disabled:a,invalid:o.invalid,value:o.value,hover:k,focus:T,autofocus:s}),z=ce(l,F=>F.listboxState===re.Open),B=yt(d(),{ref:c,id:i,type:ci(e,f),"aria-haspopup":"listbox","aria-controls":h?.id,"aria-expanded":z,"aria-labelledby":S,"aria-describedby":C,disabled:a||void 0,autoFocus:s,onKeyDown:b,onKeyUp:x,onKeyPress:w},y,O,A,M);return te()({ourProps:B,theirProps:u,slot:H,defaultTag:cm,name:"Listbox.Button"})}let Wi=p.createContext(!1),fm="div",pm=rt.RenderStrategy|rt.Static;function mm(e,t){let n=p.useId(),{id:r=`headlessui-listbox-options-${n}`,anchor:o,portal:l=!1,modal:i=!0,transition:a=!1,...s}=e,u=up(o),[c,d]=p.useState(null);u&&(l=!0);let m=At("Listbox.Options"),f=jr("Listbox.Options"),[h,v,b,x]=ce(f,N=>[N.listboxState,N.buttonElement,N.optionsElement,N.__demoMode]),y=tr(v),w=tr(b),S=bn(),[C,T]=kr(a,c,S!==null?(S&ae.Open)===ae.Open:h===re.Open);dd(C,v,f.actions.closeListbox);let O=x?!1:i&&h===re.Open;Fd(O,w);let k=x?!1:i&&h===re.Open;cd(k,{allowed:p.useCallback(()=>[v,b],[v,b])});let A=ce(f,f.selectors.didButtonMove)?!1:C,R=ce(f,f.selectors.hasFrozenValue)&&!e.static,M=Ri(R,m.value),H=p.useCallback(N=>m.compare(M,N),[m.compare,M]),z=ce(f,N=>{var W;if(u==null||!((W=u?.to)!=null&&W.includes("selection")))return null;let xe=N.options.findIndex(he=>H(he.dataRef.current.value));return xe===-1&&(xe=0),xe}),B=(()=>{if(u==null)return;if(z===null)return{...u,inner:void 0};let N=Array.from(m.listRef.current.values());return{...u,inner:{listRef:{current:N},index:z}}})(),[F,I]=pp(B),U=fp(),$=ue(t,u?F:null,f.actions.setOptionsElement,d),V=Xe();p.useEffect(()=>{let N=b;N&&h===re.Open&&(uc(N)||N==null||N.focus({preventScroll:!0}))},[h,b]);let q=D(N=>{var W;switch(V.dispose(),N.key){case Y.Space:if(f.state.searchQuery!=="")return N.preventDefault(),N.stopPropagation(),f.actions.search(N.key);case Y.Enter:N.preventDefault(),N.stopPropagation(),f.actions.selectActiveOption();break;case se(m.orientation,{vertical:Y.ArrowDown,horizontal:Y.ArrowRight}):return N.preventDefault(),N.stopPropagation(),f.actions.goToOption({focus:Z.Next});case se(m.orientation,{vertical:Y.ArrowUp,horizontal:Y.ArrowLeft}):return N.preventDefault(),N.stopPropagation(),f.actions.goToOption({focus:Z.Previous});case Y.Home:case Y.PageUp:return N.preventDefault(),N.stopPropagation(),f.actions.goToOption({focus:Z.First});case Y.End:case Y.PageDown:return N.preventDefault(),N.stopPropagation(),f.actions.goToOption({focus:Z.Last});case Y.Escape:N.preventDefault(),N.stopPropagation(),Ge.flushSync(()=>f.actions.closeListbox()),(W=f.state.buttonElement)==null||W.focus({preventScroll:!0});return;case Y.Tab:N.preventDefault(),N.stopPropagation(),Ge.flushSync(()=>f.actions.closeListbox()),xd(f.state.buttonElement,N.shiftKey?er.Previous:er.Next);break;default:N.key.length===1&&(f.actions.search(N.key),V.setTimeout(()=>f.actions.clearSearch(),350));break}}),pe=ce(f,N=>{var W;return(W=N.buttonElement)==null?void 0:W.id}),K=be({open:h===re.Open}),_=yt(u?U():{},{id:r,ref:$,"aria-activedescendant":ce(f,f.selectors.activeDescendantId),"aria-multiselectable":m.mode===Be.Multi?!0:void 0,"aria-labelledby":pe,"aria-orientation":m.orientation,onKeyDown:q,role:"listbox",tabIndex:h===re.Open?0:void 0,style:{...s.style,...I,"--button-width":Zc(C,v,!0).width},...$r(T)}),ee=te(),me=p.useMemo(()=>m.mode===Be.Multi?m:{...m,isSelected:H},[m,H]);return p.createElement(Pp,{enabled:l?e.static||C:!1,ownerDocument:y},p.createElement(En.Provider,{value:me},ee({ourProps:_,theirProps:s,slot:K,defaultTag:fm,features:pm,visible:A,name:"Listbox.Options"})))}let hm="div";function gm(e,t){let n=p.useId(),{id:r=`headlessui-listbox-option-${n}`,disabled:o=!1,value:l,...i}=e,a=p.useContext(Wi)===!0,s=At("Listbox.Option"),u=jr("Listbox.Option"),c=ce(u,R=>u.selectors.isActive(R,r)),d=s.isSelected(l),m=p.useRef(null),f=om(m),h=Je({disabled:o,value:l,domRef:m,get textValue(){return f()}}),v=ue(t,m,R=>{R?s.listRef.current.set(r,R):s.listRef.current.delete(r)}),b=ce(u,R=>u.selectors.shouldScrollIntoView(R,r));X(()=>{if(b)return fe().requestAnimationFrame(()=>{var R,M;(M=(R=m.current)==null?void 0:R.scrollIntoView)==null||M.call(R,{block:"nearest"})})},[b,m]),X(()=>{if(!a)return u.actions.registerOption(r,h),()=>u.actions.unregisterOption(r)},[h,r,a]);let x=D(R=>{if(o)return R.preventDefault();u.actions.selectOption(l)}),y=D(()=>{if(o)return u.actions.goToOption({focus:Z.Nothing});u.actions.goToOption({focus:Z.Specific,id:r})}),w=Md(),S=D(R=>w.update(R)),C=D(R=>{w.wasMoved(R)&&(o||c&&u.state.activationTrigger===Yt.Pointer||u.actions.goToOption({focus:Z.Specific,id:r},Yt.Pointer))}),T=D(R=>{w.wasMoved(R)&&(o||c&&u.state.activationTrigger===Yt.Pointer&&u.actions.goToOption({focus:Z.Nothing}))}),O=be({active:c,focus:c,selected:d,disabled:o,selectedOption:d&&a}),k=a?{}:{id:r,ref:v,role:"option",tabIndex:o===!0?void 0:-1,"aria-disabled":o===!0?!0:void 0,"aria-selected":d,disabled:void 0,onClick:x,onFocus:y,onPointerEnter:S,onMouseEnter:S,onPointerMove:C,onMouseMove:C,onPointerLeave:T,onMouseLeave:T},A=te();return!d&&a?null:A({ourProps:k,theirProps:i,slot:O,defaultTag:hm,name:"Listbox.Option"})}let vm=p.Fragment;function bm(e,t){let{options:n,placeholder:r,...o}=e,l={ref:ue(t)},i=At("ListboxSelectedOption"),a=be({}),s=i.value===void 0||i.value===null||i.mode===Be.Multi&&Array.isArray(i.value)&&i.value.length===0,u=te();return p.createElement(Wi.Provider,{value:!0},u({ourProps:l,theirProps:{...o,children:p.createElement(p.Fragment,null,r&&s?r:n)},slot:a,defaultTag:vm,name:"ListboxSelectedOption"}))}let xm=Q(um),Ui=Q(dm),wm=Uc,qi=Q(mm),Gi=Q(gm),ym=Q(bm),Em=Object.assign(xm,{Button:Ui,Label:wm,Options:qi,Option:Gi,SelectedOption:ym});function Ki({children:e,className:t,disabled:n=!1,intent:r="primary",...o}){return E.jsx(wc,{className:ie("rounded-md font-bold cursor-pointer px-2",Cm(r,!!n),{"opacity-50 cursor-default":n},t),"data-focus":!0,disabled:n,...o,children:e})}function Cm(e,t){switch(e){case"danger":return ie("bg-red-400 text-red-950 focus:text-black",{"hover:bg-red-500 focus:text-black":!t});case"none":return ie("bg-white/20 text-slate-300 focus:text-white",{"hover:bg-white/10 focus:text-white":!t});case"success":return ie("bg-emerald-400 text-emerald-950 focus:text-black",{"hover:bg-emerald-500 focus:text-black":!t});case"primary":return ie("bg-sky-400 text-sky-950 focus:text-black",{"hover:bg-sky-500 focus:text-black":!t});case"warning":return ie("bg-amber-400 text-amber-950 focus:text-black",{"hover:bg-amber-500 focus:text-black":!t})}}function Dr({children:e}){return E.jsx(Nu,{FallbackComponent:Sm,children:e})}function Sm({error:e,resetErrorBoundary:t}){return E.jsx(pr,{intent:"danger",children:E.jsxs(le,{align:"start",direction:"column",gap:2,children:[E.jsx("div",{className:"font-bold",children:"Something went wrong!"}),E.jsx("pre",{className:"text-sm font-monospace text-red-300",children:e.message}),E.jsx(Ki,{intent:"danger",onClick:t,children:"Retry"})]})})}function $t({children:e,className:t,href:n,target:r="_blank",...o}){return E.jsx("a",{className:t,href:n,target:r,rel:"noopener noreferrer",...o,children:e})}function on({children:e,onClick:t,to:n,...r}){const o=!!Wa(n),[l,i]=p.useTransition(),a=Qo();return E.jsx("span",{children:typeof e=="function"?e({isActive:o,isPending:l}):e,"data-link":!0,onClick:s=>{t?.(s),i(()=>{a(n)})},...r})}function $m({children:e}){return E.jsx("div",{className:"w-full shrink-0 flex flex-col gap-4 py-4 overflow-y-auto",children:e})}function km(){const{hide:e}=dl(),{pathname:t}=Fe();return p.useLayoutEffect(()=>{e();const n=document.body.querySelector("[data-main-scrollable]");if(n){const r=setTimeout(()=>{n.scrollTo(0,0)},1);return()=>{clearTimeout(r)}}},[e,t]),null}const Rm={"*":p.lazy(()=>Promise.resolve().then(()=>require("./PageNotFound-DIt5wQ4x.cjs"))),"/":p.lazy(()=>Promise.resolve().then(()=>require("./GettingStartedRoute-LGDNviy5.cjs"))),"/support":p.lazy(()=>Promise.resolve().then(()=>require("./SupportRoute-DWEe-0A7.cjs"))),"/versions":p.lazy(()=>Promise.resolve().then(()=>require("./VersionsRoute-Br6RZivR.cjs")))};function Om({navLinks:e,overview:t,packageDescription:n,packageName:r,routes:o,showOpenCollectLink:l=!1,versions:i}){const{toggle:a,visible:s}=dl(),u=p.useMemo(()=>({overview:t,packageName:r,showOpenCollectLink:l,versions:i}),[t,r,l,i]);return E.jsx(cl.Provider,{value:u,children:E.jsxs(Ts,{children:[E.jsx(km,{}),E.jsxs("div",{className:"h-full w-full max-w-350 mx-auto flex flex-col",children:[E.jsxs(le,{align:"center",className:"h-12 w-full p-4",direction:"row",justify:"between",gap:4,children:[E.jsxs(le,{className:"overflow-hidden",align:"center",direction:"row",gap:4,children:[E.jsx(on,{children:r,className:"text-xl text-white! text-shadow-black/80 text-shadow-xs font-bold cursor-pointer truncate",to:"/"}),E.jsx("div",{className:"hidden md:block text-black text-shadow-white/50 text-shadow-xs",children:n})]}),E.jsxs(le,{align:"center",direction:"row",gap:4,children:[i!==void 0&&E.jsx(on,{"aria-label":"Documentation for other versions",className:"text-xs font-bold text-white! drop-shadow-black/20 drop-shadow-sm cursor-pointer",title:"Past releases",to:"/versions",children:E.jsx(ul,{className:"w-6 h-6"})}),E.jsx($t,{"aria-label":"NPM project page",className:"text-white! drop-shadow-black/20 drop-shadow-sm",href:`https://www.npmjs.com/package/${r}`,title:"NPM package",children:E.jsx(Bs,{className:"w-8 h-8"})}),E.jsx($t,{"aria-label":"GitHub project page",className:"text-white! drop-shadow-black/20 drop-shadow-sm",href:`https://github.com/bvaughn/${r}`,title:"Source code",children:E.jsx(_s,{className:"w-6 h-6"})}),E.jsx("button",{"aria-label":"Site navigation menu",className:ie("block md:hidden cursor-pointer rounded-lg p-1",{"bg-black/40":!s,"bg-black/50 text-white":s}),onClick:a,children:s?E.jsx(ma,{className:"w-6 h-6 fill-current drop-shadow-black/20 drop-shadow-xs"}):E.jsx(ra,{className:"w-6 h-6 fill-current drop-shadow-black/20 drop-shadow-xs"})})]})]}),E.jsxs("div",{className:"grow shrink flex flex-row shadow-lg mx-2 rounded-t-3xl overflow-hidden",children:[E.jsx("section",{className:ie("w-full bg-black/90 md:block md:w-80 md:bg-black/80 overflow-auto",{hidden:!s}),children:E.jsx($m,{children:e})}),E.jsx("main",{className:ie("w-full bg-black/90 relative overflow-auto",{hidden:s}),children:E.jsx("div",{className:"h-full p-4 py-4 overflow-auto [mask-image:linear-gradient(to_bottom,transparent,black_1.5rem)]","data-main-scrollable":!0,children:E.jsx(is,{children:Object.entries({...Rm,...o}).map(([c,d])=>E.jsx(nl,{element:E.jsx(Dr,{children:E.jsx(d,{})},c),path:c},c))})})})]})]})]})})}function Tm({children:e,className:t,...n}){return E.jsx(Dr,{children:E.jsx("div",{className:`border-lg bg-black/30 text-slate-300 rounded-lg p-2 ${t}`,...n,children:e})})}const Pm=e=>g.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",height:"24px",viewBox:"0 -960 960 960",width:"24px",fill:"currentColor",...e},g.createElement("path",{d:"m424-424-86-86q-11-11-28-11t-28 11q-11 11-11 28t11 28l114 114q12 12 28 12t28-12l226-226q11-11 11-28t-11-28q-11-11-28-11t-28 11L424-424ZM200-120q-33 0-56.5-23.5T120-200v-560q0-33 23.5-56.5T200-840h560q33 0 56.5 23.5T840-760v560q0 33-23.5 56.5T760-120H200Z"})),Lm=e=>g.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",height:"24px",viewBox:"0 -960 960 960",width:"24px",fill:"currentColor",...e},g.createElement("path",{d:"M320-440h320q17 0 28.5-11.5T680-480q0-17-11.5-28.5T640-520H320q-17 0-28.5 11.5T280-480q0 17 11.5 28.5T320-440ZM200-120q-33 0-56.5-23.5T120-200v-560q0-33 23.5-56.5T200-840h560q33 0 56.5 23.5T840-760v560q0 33-23.5 56.5T760-120H200Z"})),Am=e=>g.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",height:"24px",viewBox:"0 -960 960 960",width:"24px",fill:"currentColor",...e},g.createElement("path",{d:"M200-120q-33 0-56.5-23.5T120-200v-560q0-33 23.5-56.5T200-840h560q33 0 56.5 23.5T840-760v560q0 33-23.5 56.5T760-120H200Z"}));function Fm({checked:e,children:t,className:n,indeterminate:r,onChange:o,...l}){let i,a;return r?(i=Lm,a="fill-white"):e?(i=Pm,a="fill-blue-600"):(i=Am,a="fill-slate-600"),E.jsxs("label",{className:`cursor-pointer rounded-lg flex flex-row items-center outline-none group ${n}`,"data-focus-within":!0,...l,children:[E.jsx("input",{checked:e,className:"w-0 h-0",onChange:s=>{o(s.currentTarget.checked)},type:"checkbox"}),E.jsx(i,{className:a}),t&&E.jsxs(E.Fragment,{children:[" ",t]})]})}function _r({className:e="",html:t}){return E.jsx("div",{className:"relative",children:E.jsx("code",{className:ie("text-sm md:text-base block text-left whitespace-pre-wrap break-normal text-white! rounded-md p-3 bg-black","flex flex-col",e),dangerouslySetInnerHTML:{__html:t}})})}function Ft({className:e,sections:t}){return E.jsx(le,{className:e,direction:"column",gap:2,children:t.map(({content:n,intent:r},o)=>r?E.jsx(pr,{html:!0,inline:!0,intent:r,minimal:!0,children:n},o):E.jsx("div",{dangerouslySetInnerHTML:{__html:n.replaceAll("<ul>",'<ul class="list-disc pl-4">')}},o))})}const Yi={url:"https://github.com/bvaughn/react-lib-tools.git"};function Zi(e,t="Assertion error"){if(!e)throw Error(t)}function Xi(){const e=p.useContext(cl);return Zi(e,"App must be rendered within a LibraryContextProvider"),e}function Br({section:e,title:t}){const{packageName:n}=Xi();return p.useEffect(()=>{const r=document.title;return document.title=`${n}: ${e?`${e}: ${t}`:t}`,()=>{document.title=r}}),E.jsxs(le,{align:"center",direction:"row",gap:2,wrap:!0,children:[e&&E.jsxs(E.Fragment,{children:[E.jsx("div",{className:"text-xl whitespace-nowrap",children:e}),E.jsx(Vo,{className:"size-4 text-slate-400"})]}),E.jsx("div",{className:"text-xl whitespace-nowrap",children:t})]})}function Mm({method:e}){return E.jsxs(E.Fragment,{children:[E.jsx("dd",{className:"[&_code]:text-sky-300 text-lg font-bold",children:e.name}),E.jsxs("dt",{className:"mt-2",children:[E.jsx(Ft,{sections:e.description}),E.jsx(_r,{className:"mt-2 p-2 flex flex-col",html:e.html})]})]})}function Nm({json:e,section:t}){return E.jsxs(le,{direction:"column",gap:4,children:[E.jsxs(le,{align:"center",direction:"row",gap:2,wrap:!0,children:[E.jsx(Br,{section:t,title:`${e.name}`}),E.jsx($t,{className:"text-sm text-emerald-300 hover:text-white",href:`${Yi.url.replace(".git","")}/blob/main/${e.filePath}`,children:E.jsx(Ho,{className:"inline-block size-4 fill-current"})})]}),E.jsx(Ft,{sections:e.description}),E.jsx(le,{direction:"column",children:E.jsx("dl",{className:"flex flex-col gap-2",children:e.methods.map((n,r)=>E.jsx(Mm,{method:n},r))})})]})}function Im({children:e,className:t,onChange:n,value:r,...o}){return E.jsx("input",{className:`rounded-md bg-black/30 border border-2 border-transparent py-1 px-2 outline-none focus:border-emerald-300 ${t}`,"data-focus":!0,onChange:l=>{n(l.currentTarget.value)},value:r,...o,children:e})}function jm(){return E.jsxs(le,{align:"center",className:"text-slate-300",direction:"row",gap:2,children:[E.jsx(ea,{className:"size-4 animate-spin"}),"Loading..."]})}function Ji({children:e,className:t,disabled:n}){return E.jsx(le,{align:"center",className:ie("px-4 h-8 cursor-pointer text-white/90 hover:text-white focus:bg-white/10 focus-within:bg-white/10",{"pointer-events-none text-white/50":n},t),direction:"row",gap:1,children:e})}function Dm({children:e,className:t,path:n}){return E.jsx(on,{to:n,children:({isActive:r,isPending:o})=>E.jsx(Ji,{className:ie("px-4 cursor-pointer",{"font-bold text-nav-active hover:text-nav-hover":r,"opacity-50 pointer-events-none":o},t),children:E.jsx(le,{align:"center",direction:"row",gap:2,children:e})})})}function _m({children:e,label:t}){return E.jsxs(nm,{as:"section",defaultOpen:!0,children:[E.jsx(_i,{className:"w-full group border-none! data-focus:bg-white/10",children:E.jsxs(Ji,{children:[E.jsx("div",{className:"uppercase text-sm font-bold text-white/50",children:t}),E.jsx("div",{className:"grow"}),E.jsx(Vo,{className:"size-4 fill-white/60 group-data-hover:fill-white/50 group-data-open:rotate-90"})]})}),E.jsx(Bi,{className:"pl-4",children:e})]})}function Bm(e){const t=[],n=[];return Object.values(e.props).forEach(r=>{r.required?n.push(r):t.push(r)}),t.sort((r,o)=>r.name.localeCompare(o.name)),n.sort((r,o)=>r.name.localeCompare(o.name)),{optionalProps:t,requiredProps:n}}function Hm({prop:e}){return E.jsxs(E.Fragment,{children:[E.jsx("dt",{className:"mt-6 pl-8 indent-[-1rem]",children:E.jsx(_r,{className:"bg-transparent inline-flex flex-col p-0",html:e.html})}),E.jsx("dd",{className:"mt-2 pl-4 [&_code]:text-sky-300",children:E.jsx(Ft,{sections:e.description})})]})}function ir({header:e,props:t}){return t.length===0?null:E.jsxs(le,{direction:"column",children:[E.jsx("div",{className:"text-lg font-bold",children:e}),E.jsx("dl",{children:t.map(n=>E.jsx(Hm,{prop:n},n.name))})]})}function Vm({json:e,section:t}){const{optionalProps:n,requiredProps:r}=p.useMemo(()=>Bm(e),[e]);return E.jsxs(le,{direction:"column",gap:4,children:[E.jsxs(le,{align:"center",direction:"row",gap:2,wrap:!0,children:[E.jsx(Br,{section:t,title:`${e.name} component`}),E.jsx($t,{className:"text-sm text-emerald-300 hover:text-white",href:`${Yi.url.replace(".git","")}/blob/main/${e.filePath}`,children:E.jsx(Ho,{className:"inline-block size-4 fill-current"})})]}),E.jsx(Ft,{sections:e.description}),E.jsx(ir,{header:"Required props",props:r}),E.jsx(ir,{header:"Optional props",props:n})]})}const zm=e=>g.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",height:"24px",viewBox:"0 -960 960 960",width:"24px",fill:"currentColor",...e},g.createElement("path",{d:"m424-408-86-86q-11-11-28-11t-28 11q-11 11-11 28t11 28l114 114q12 12 28 12t28-12l226-226q11-11 11-28t-11-28q-11-11-28-11t-28 11L424-408Zm56 328q-83 0-156-31.5T197-197q-54-54-85.5-127T80-480q0-83 31.5-156T197-763q54-54 127-85.5T480-880q83 0 156 31.5T763-763q54 54 85.5 127T880-480q0 83-31.5 156T763-197q-54 54-127 85.5T480-80Z"})),Wm=e=>g.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",height:"24px",viewBox:"0 -960 960 960",width:"24px",fill:"currentColor",...e},g.createElement("path",{d:"M480-80q-83 0-156-31.5T197-197q-54-54-85.5-127T80-480q0-83 31.5-156T197-763q54-54 127-85.5T480-880q83 0 156 31.5T763-763q54 54 85.5 127T880-480q0 83-31.5 156T763-197q-54 54-127 85.5T480-80Z"}));function Um({checked:e,children:t,className:n,name:r,onChange:o,value:l,...i}){let a,s;return e?(a=zm,s="fill-blue-600"):(a=Wm,s="fill-slate-600"),E.jsxs("label",{className:`cursor-pointer rounded-full flex flex-row items-center outline-none group ${n}`,"data-focus-within":!0,...i,children:[E.jsx("input",{checked:e,className:"w-0 h-0",name:r,onChange:()=>{o(l)},type:"radio",value:l}),E.jsx(a,{className:s}),t&&E.jsxs(E.Fragment,{children:[" ",t]})]})}function qm({className:e,defaultValue:t,onChange:n,options:r,placeholder:o="",value:l}){return E.jsx(Em,{value:l??t,onChange:n,children:E.jsxs("div",{className:`relative ${e}`,children:[E.jsxs(Ui,{className:"w-full h-9 text-left rounded-md bg-black/30 border border-2 border-transparent py-1 px-2 outline-none focus:border-teal-300","data-focus":!0,children:[l?.label?E.jsx("span",{className:"block truncate",children:l.label}):E.jsx("span",{className:"block truncate text-slate-500",children:o}),E.jsx("span",{className:"pointer-events-none absolute inset-y-0 right-0 flex items-center pr-2",children:E.jsx(sa,{className:"h-4 w-4 text-gray-400","aria-hidden":"true"})})]}),E.jsx(Hp,{as:p.Fragment,leave:"transition ease-in duration-100",leaveFrom:"opacity-100",leaveTo:"opacity-0",children:E.jsx(qi,{className:"absolute z-10 mt-1 max-h-50 w-full overflow-auto rounded-md py-1 bg-black/90","data-focus":!0,children:r.map((i,a)=>E.jsx(Gi,{className:ie("relative cursor-pointer select-none h-7 py-1 px-2 text-slate-300 border-none!","data-focus:text-teal-300 data-focus:bg-black","data-active:text-teal-300 data-active:bg-black","data-selected:text-teal-300 data-selected:font-bold"),value:i,children:i.label},a))})})]})})}function Gm(e,t){switch(e){case"danger":return t?"bg-red-950 text-red-300 [&_svg]:text-red-500":"bg-black/10 bg-border border-2 border-red-500 text-white [&_svg]:text-red-500 [&_a]:text-red-400!";case"none":return t?"bg-white/10 text-slate-300 [&_svg]:text-slate-400":"bg-black/10 bg-border border-2 border-white/40 text-white [&_svg]:text-white/60";case"primary":return t?"bg-sky-950 text-sky-300 [&_svg]:text-sky-400":"bg-black/10 bg-border border-2 border-sky-400 text-white [&_svg]:text-sky-400";case"success":return t?"bg-emerald-950 text-emerald-300 [&_svg]:text-emerald-400":"bg-black/10 bg-border border-2 border-emerald-400 text-white [&_svg]:text-emerald-400";case"warning":return t?"bg-amber-950/65 text-amber-200 [&_svg]:text-amber-300":"bg-black/10 bg-border border-2 border-amber-400 text-white [&_svg]:text-amber-400 [&_a]:text-amber-400!"}}exports.AppRoot=Om;exports.Block=Tm;exports.Box=le;exports.Button=Ki;exports.Callout=pr;exports.Checkbox=Fm;exports.Code=_r;exports.ComponentProps=Vm;exports.ComponentPropsSection=ir;exports.DocsSection=Ft;exports.ErrorBoundary=Dr;exports.ExternalLink=$t;exports.Header=Br;exports.ImperativeHandle=Nm;exports.Input=Im;exports.Link=on;exports.LoadingSpinner=jm;exports.NavLink=Dm;exports.NavSection=_m;exports.Radio=Um;exports.Select=qm;exports.SvgTags=ul;exports.assert=Zi;exports.cn=ie;exports.getIntentClassNames=Gm;exports.useLibraryContext=Xi;
|
|
8
|
+
//# sourceMappingURL=index-DleNtYr0.cjs.map
|