var mr=Object.defineProperty;var gr=(t,a,r)=>a in t?mr(t,a,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[a]=r;var ke=(t,a,r)=>gr(t,typeof a!="symbol"?a+"":a,r);import{r as n,a as xr,j as e,g as Pt,R as je,c as hr}from"./client-Cv0X-2PX.js";/** * react-router v7.13.1 * * Copyright (c) Remix Software Inc. * * This source code is licensed under the MIT license found in the * LICENSE.md file in the root directory of this source tree. * * @license MIT */var Qt="popstate";function Yt(t){return typeof t=="object"&&t!=null&&"pathname"in t&&"search"in t&&"hash"in t&&"state"in t&&"key"in t}function pr(t={}){function a(l,s){var c;let i=(c=s.state)==null?void 0:c.masked,{pathname:o,search:u,hash:d}=i||l.location;return St("",{pathname:o,search:u,hash:d},s.state&&s.state.usr||null,s.state&&s.state.key||"default",i?{pathname:l.location.pathname,search:l.location.search,hash:l.location.hash}:void 0)}function r(l,s){return typeof s=="string"?s:Be(s)}return yr(a,r,null,t)}function ee(t,a){if(t===!1||t===null||typeof t>"u")throw new Error(a)}function xe(t,a){if(!t){typeof console<"u"&&console.warn(a);try{throw new Error(a)}catch{}}}function br(){return Math.random().toString(36).substring(2,10)}function Xt(t,a){return{usr:t.state,key:t.key,idx:a,masked:t.unstable_mask?{pathname:t.pathname,search:t.search,hash:t.hash}:void 0}}function St(t,a,r=null,l,s){return{pathname:typeof t=="string"?t:t.pathname,search:"",hash:"",...typeof a=="string"?Ie(a):a,state:r,key:a&&a.key||l||br(),unstable_mask:s}}function Be({pathname:t="/",search:a="",hash:r=""}){return a&&a!=="?"&&(t+=a.charAt(0)==="?"?a:"?"+a),r&&r!=="#"&&(t+=r.charAt(0)==="#"?r:"#"+r),t}function Ie(t){let a={};if(t){let r=t.indexOf("#");r>=0&&(a.hash=t.substring(r),t=t.substring(0,r));let l=t.indexOf("?");l>=0&&(a.search=t.substring(l),t=t.substring(0,l)),t&&(a.pathname=t)}return a}function yr(t,a,r,l={}){let{window:s=document.defaultView,v5Compat:i=!1}=l,o=s.history,u="POP",d=null,c=m();c==null&&(c=0,o.replaceState({...o.state,idx:c},""));function m(){return(o.state||{idx:null}).idx}function g(){u="POP";let j=m(),x=j==null?null:j-c;c=j,d&&d({action:u,location:R.location,delta:x})}function h(j,x){u="PUSH";let k=Yt(j)?j:St(R.location,j,x);c=m()+1;let D=Xt(k,c),E=R.createHref(k.unstable_mask||k);try{o.pushState(D,"",E)}catch(T){if(T instanceof DOMException&&T.name==="DataCloneError")throw T;s.location.assign(E)}i&&d&&d({action:u,location:R.location,delta:1})}function y(j,x){u="REPLACE";let k=Yt(j)?j:St(R.location,j,x);c=m();let D=Xt(k,c),E=R.createHref(k.unstable_mask||k);o.replaceState(D,"",E),i&&d&&d({action:u,location:R.location,delta:0})}function _(j){return fr(j)}let R={get action(){return u},get location(){return t(s,o)},listen(j){if(d)throw new Error("A history only accepts one active listener");return s.addEventListener(Qt,g),d=j,()=>{s.removeEventListener(Qt,g),d=null}},createHref(j){return a(s,j)},createURL:_,encodeLocation(j){let x=_(j);return{pathname:x.pathname,search:x.search,hash:x.hash}},push:h,replace:y,go(j){return o.go(j)}};return R}function fr(t,a=!1){let r="http://localhost";typeof window<"u"&&(r=window.location.origin!=="null"?window.location.origin:window.location.href),ee(r,"No window.location.(origin|href) available to create URL");let l=typeof t=="string"?t:Be(t);return l=l.replace(/ $/,"%20"),!a&&l.startsWith("//")&&(l=r+l),new URL(l,r)}function fa(t,a,r="/"){return kr(t,a,r,!1)}function kr(t,a,r,l){let s=typeof a=="string"?Ie(a):a,i=ve(s.pathname||"/",r);if(i==null)return null;let o=ka(t);jr(o);let u=null;for(let d=0;u==null&&d{let m={relativePath:c===void 0?o.path||"":c,caseSensitive:o.caseSensitive===!0,childrenIndex:u,route:o};if(m.relativePath.startsWith("/")){if(!m.relativePath.startsWith(l)&&d)return;ee(m.relativePath.startsWith(l),`Absolute route path "${m.relativePath}" nested under path "${l}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),m.relativePath=m.relativePath.slice(l.length)}let g=ge([l,m.relativePath]),h=r.concat(m);o.children&&o.children.length>0&&(ee(o.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${g}".`),ka(o.children,a,h,g,d)),!(o.path==null&&!o.index)&&a.push({path:g,score:Er(g,o.index),routesMeta:h})};return t.forEach((o,u)=>{var d;if(o.path===""||!((d=o.path)!=null&&d.includes("?")))i(o,u);else for(let c of ja(o.path))i(o,u,!0,c)}),a}function ja(t){let a=t.split("/");if(a.length===0)return[];let[r,...l]=a,s=r.endsWith("?"),i=r.replace(/\?$/,"");if(l.length===0)return s?[i,""]:[i];let o=ja(l.join("/")),u=[];return u.push(...o.map(d=>d===""?i:[i,d].join("/"))),s&&u.push(...o),u.map(d=>t.startsWith("/")&&d===""?"/":d)}function jr(t){t.sort((a,r)=>a.score!==r.score?r.score-a.score:Rr(a.routesMeta.map(l=>l.childrenIndex),r.routesMeta.map(l=>l.childrenIndex)))}var vr=/^:[\w-]+$/,wr=3,Nr=2,Cr=1,Sr=10,_r=-2,ea=t=>t==="*";function Er(t,a){let r=t.split("/"),l=r.length;return r.some(ea)&&(l+=_r),a&&(l+=Nr),r.filter(s=>!ea(s)).reduce((s,i)=>s+(vr.test(i)?wr:i===""?Cr:Sr),l)}function Rr(t,a){return t.length===a.length&&t.slice(0,-1).every((l,s)=>l===a[s])?t[t.length-1]-a[a.length-1]:0}function Tr(t,a,r=!1){let{routesMeta:l}=t,s={},i="/",o=[];for(let u=0;u{if(m==="*"){let _=u[h]||"";o=i.slice(0,i.length-_.length).replace(/(.)\/+$/,"$1")}const y=u[h];return g&&!y?c[m]=void 0:c[m]=(y||"").replace(/%2F/g,"/"),c},{}),pathname:i,pathnameBase:o,pattern:t}}function Lr(t,a=!1,r=!0){xe(t==="*"||!t.endsWith("*")||t.endsWith("/*"),`Route path "${t}" will be treated as if it were "${t.replace(/\*$/,"/*")}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${t.replace(/\*$/,"/*")}".`);let l=[],s="^"+t.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(o,u,d,c,m)=>{if(l.push({paramName:u,isOptional:d!=null}),d){let g=m.charAt(c+o.length);return g&&g!=="/"?"/([^\\/]*)":"(?:/([^\\/]*))?"}return"/([^\\/]+)"}).replace(/\/([\w-]+)\?(\/|$)/g,"(/$1)?$2");return t.endsWith("*")?(l.push({paramName:"*"}),s+=t==="*"||t==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):r?s+="\\/*$":t!==""&&t!=="/"&&(s+="(?:(?=\\/|$))"),[new RegExp(s,a?void 0:"i"),l]}function Pr(t){try{return t.split("/").map(a=>decodeURIComponent(a).replace(/\//g,"%2F")).join("/")}catch(a){return xe(!1,`The URL path "${t}" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (${a}).`),t}}function ve(t,a){if(a==="/")return t;if(!t.toLowerCase().startsWith(a.toLowerCase()))return null;let r=a.endsWith("/")?a.length-1:a.length,l=t.charAt(r);return l&&l!=="/"?null:t.slice(r)||"/"}var Mr=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i;function $r(t,a="/"){let{pathname:r,search:l="",hash:s=""}=typeof t=="string"?Ie(t):t,i;return r?(r=r.replace(/\/\/+/g,"/"),r.startsWith("/")?i=ta(r.substring(1),"/"):i=ta(r,a)):i=a,{pathname:i,search:Ar(l),hash:Hr(s)}}function ta(t,a){let r=a.replace(/\/+$/,"").split("/");return t.split("/").forEach(s=>{s===".."?r.length>1&&r.pop():s!=="."&&r.push(s)}),r.length>1?r.join("/"):"/"}function ht(t,a,r,l){return`Cannot include a '${t}' character in a manually specified \`to.${a}\` field [${JSON.stringify(l)}]. Please separate it out to the \`to.${r}\` field. Alternatively you may provide the full path as a string in and the router will parse it for you.`}function Ir(t){return t.filter((a,r)=>r===0||a.route.path&&a.route.path.length>0)}function va(t){let a=Ir(t);return a.map((r,l)=>l===a.length-1?r.pathname:r.pathnameBase)}function Mt(t,a,r,l=!1){let s;typeof t=="string"?s=Ie(t):(s={...t},ee(!s.pathname||!s.pathname.includes("?"),ht("?","pathname","search",s)),ee(!s.pathname||!s.pathname.includes("#"),ht("#","pathname","hash",s)),ee(!s.search||!s.search.includes("#"),ht("#","search","hash",s)));let i=t===""||s.pathname==="",o=i?"/":s.pathname,u;if(o==null)u=r;else{let g=a.length-1;if(!l&&o.startsWith("..")){let h=o.split("/");for(;h[0]==="..";)h.shift(),g-=1;s.pathname=h.join("/")}u=g>=0?a[g]:"/"}let d=$r(s,u),c=o&&o!=="/"&&o.endsWith("/"),m=(i||o===".")&&r.endsWith("/");return!d.pathname.endsWith("/")&&(c||m)&&(d.pathname+="/"),d}var ge=t=>t.join("/").replace(/\/\/+/g,"/"),Dr=t=>t.replace(/\/+$/,"").replace(/^\/*/,"/"),Ar=t=>!t||t==="?"?"":t.startsWith("?")?t:"?"+t,Hr=t=>!t||t==="#"?"":t.startsWith("#")?t:"#"+t,Or=class{constructor(t,a,r,l=!1){this.status=t,this.statusText=a||"",this.internal=l,r instanceof Error?(this.data=r.toString(),this.error=r):this.data=r}};function Ur(t){return t!=null&&typeof t.status=="number"&&typeof t.statusText=="string"&&typeof t.internal=="boolean"&&"data"in t}function Vr(t){return t.map(a=>a.route.path).filter(Boolean).join("/").replace(/\/\/*/g,"/")||"/"}var wa=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function Na(t,a){let r=t;if(typeof r!="string"||!Mr.test(r))return{absoluteURL:void 0,isExternal:!1,to:r};let l=r,s=!1;if(wa)try{let i=new URL(window.location.href),o=r.startsWith("//")?new URL(i.protocol+r):new URL(r),u=ve(o.pathname,a);o.origin===i.origin&&u!=null?r=u+o.search+o.hash:s=!0}catch{xe(!1,` contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}return{absoluteURL:l,isExternal:s,to:r}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");var Ca=["POST","PUT","PATCH","DELETE"];new Set(Ca);var Fr=["GET",...Ca];new Set(Fr);var De=n.createContext(null);De.displayName="DataRouter";var at=n.createContext(null);at.displayName="DataRouterState";var Br=n.createContext(!1),Sa=n.createContext({isTransitioning:!1});Sa.displayName="ViewTransition";var Gr=n.createContext(new Map);Gr.displayName="Fetchers";var Kr=n.createContext(null);Kr.displayName="Await";var de=n.createContext(null);de.displayName="Navigation";var Ge=n.createContext(null);Ge.displayName="Location";var be=n.createContext({outlet:null,matches:[],isDataRoute:!1});be.displayName="Route";var $t=n.createContext(null);$t.displayName="RouteError";var _a="REACT_ROUTER_ERROR",qr="REDIRECT",Zr="ROUTE_ERROR_RESPONSE";function zr(t){if(t.startsWith(`${_a}:${qr}:{`))try{let a=JSON.parse(t.slice(28));if(typeof a=="object"&&a&&typeof a.status=="number"&&typeof a.statusText=="string"&&typeof a.location=="string"&&typeof a.reloadDocument=="boolean"&&typeof a.replace=="boolean")return a}catch{}}function Wr(t){if(t.startsWith(`${_a}:${Zr}:{`))try{let a=JSON.parse(t.slice(40));if(typeof a=="object"&&a&&typeof a.status=="number"&&typeof a.statusText=="string")return new Or(a.status,a.statusText,a.data)}catch{}}function Jr(t,{relative:a}={}){ee(Ke(),"useHref() may be used only in the context of a component.");let{basename:r,navigator:l}=n.useContext(de),{hash:s,pathname:i,search:o}=qe(t,{relative:a}),u=i;return r!=="/"&&(u=i==="/"?r:ge([r,i])),l.createHref({pathname:u,search:o,hash:s})}function Ke(){return n.useContext(Ge)!=null}function ye(){return ee(Ke(),"useLocation() may be used only in the context of a component."),n.useContext(Ge).location}var Ea="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function Ra(t){n.useContext(de).static||n.useLayoutEffect(t)}function Qr(){let{isDataRoute:t}=n.useContext(be);return t?ms():Yr()}function Yr(){ee(Ke(),"useNavigate() may be used only in the context of a component.");let t=n.useContext(De),{basename:a,navigator:r}=n.useContext(de),{matches:l}=n.useContext(be),{pathname:s}=ye(),i=JSON.stringify(va(l)),o=n.useRef(!1);return Ra(()=>{o.current=!0}),n.useCallback((d,c={})=>{if(xe(o.current,Ea),!o.current)return;if(typeof d=="number"){r.go(d);return}let m=Mt(d,JSON.parse(i),s,c.relative==="path");t==null&&a!=="/"&&(m.pathname=m.pathname==="/"?a:ge([a,m.pathname])),(c.replace?r.replace:r.push)(m,c.state,c)},[a,r,i,s,t])}var Xr=n.createContext(null);function es(t){let a=n.useContext(be).outlet;return n.useMemo(()=>a&&n.createElement(Xr.Provider,{value:t},a),[a,t])}function qe(t,{relative:a}={}){let{matches:r}=n.useContext(be),{pathname:l}=ye(),s=JSON.stringify(va(r));return n.useMemo(()=>Mt(t,JSON.parse(s),l,a==="path"),[t,s,l,a])}function ts(t,a){return Ta(t,a)}function Ta(t,a,r){var j;ee(Ke(),"useRoutes() may be used only in the context of a component.");let{navigator:l}=n.useContext(de),{matches:s}=n.useContext(be),i=s[s.length-1],o=i?i.params:{},u=i?i.pathname:"/",d=i?i.pathnameBase:"/",c=i&&i.route;{let x=c&&c.path||"";Pa(u,!c||x.endsWith("*")||x.endsWith("*?"),`You rendered descendant (or called \`useRoutes()\`) at "${u}" (under ) 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. Please change the parent to .`)}let m=ye(),g;if(a){let x=typeof a=="string"?Ie(a):a;ee(d==="/"||((j=x.pathname)==null?void 0:j.startsWith(d)),`When overriding the location using \`\` 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 "${d}" but pathname "${x.pathname}" was given in the \`location\` prop.`),g=x}else g=m;let h=g.pathname||"/",y=h;if(d!=="/"){let x=d.replace(/^\//,"").split("/");y="/"+h.replace(/^\//,"").split("/").slice(x.length).join("/")}let _=fa(t,{pathname:y});xe(c||_!=null,`No routes matched location "${g.pathname}${g.search}${g.hash}" `),xe(_==null||_[_.length-1].route.element!==void 0||_[_.length-1].route.Component!==void 0||_[_.length-1].route.lazy!==void 0,`Matched leaf route at location "${g.pathname}${g.search}${g.hash}" does not have an element or Component. This means it will render an with a null value by default resulting in an "empty" page.`);let R=ls(_&&_.map(x=>Object.assign({},x,{params:Object.assign({},o,x.params),pathname:ge([d,l.encodeLocation?l.encodeLocation(x.pathname.replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:x.pathname]),pathnameBase:x.pathnameBase==="/"?d:ge([d,l.encodeLocation?l.encodeLocation(x.pathnameBase.replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:x.pathnameBase])})),s,r);return a&&R?n.createElement(Ge.Provider,{value:{location:{pathname:"/",search:"",hash:"",state:null,key:"default",unstable_mask:void 0,...g},navigationType:"POP"}},R):R}function as(){let t=us(),a=Ur(t)?`${t.status} ${t.statusText}`:t instanceof Error?t.message:JSON.stringify(t),r=t instanceof Error?t.stack:null,l="rgba(200,200,200, 0.5)",s={padding:"0.5rem",backgroundColor:l},i={padding:"2px 4px",backgroundColor:l},o=null;return console.error("Error handled by React Router default ErrorBoundary:",t),o=n.createElement(n.Fragment,null,n.createElement("p",null,"💿 Hey developer 👋"),n.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",n.createElement("code",{style:i},"ErrorBoundary")," or"," ",n.createElement("code",{style:i},"errorElement")," prop on your route.")),n.createElement(n.Fragment,null,n.createElement("h2",null,"Unexpected Application Error!"),n.createElement("h3",{style:{fontStyle:"italic"}},a),r?n.createElement("pre",{style:s},r):null,o)}var rs=n.createElement(as,null),La=class extends n.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,a){return a.location!==t.location||a.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:a.error,location:a.location,revalidation:t.revalidation||a.revalidation}}componentDidCatch(t,a){this.props.onError?this.props.onError(t,a):console.error("React Router caught the following error during render",t)}render(){let t=this.state.error;if(this.context&&typeof t=="object"&&t&&"digest"in t&&typeof t.digest=="string"){const r=Wr(t.digest);r&&(t=r)}let a=t!==void 0?n.createElement(be.Provider,{value:this.props.routeContext},n.createElement($t.Provider,{value:t,children:this.props.component})):this.props.children;return this.context?n.createElement(ss,{error:t},a):a}};La.contextType=Br;var pt=new WeakMap;function ss({children:t,error:a}){let{basename:r}=n.useContext(de);if(typeof a=="object"&&a&&"digest"in a&&typeof a.digest=="string"){let l=zr(a.digest);if(l){let s=pt.get(a);if(s)throw s;let i=Na(l.location,r);if(wa&&!pt.get(a))if(i.isExternal||l.reloadDocument)window.location.href=i.absoluteURL||i.to;else{const o=Promise.resolve().then(()=>window.__reactRouterDataRouter.navigate(i.to,{replace:l.replace}));throw pt.set(a,o),o}return n.createElement("meta",{httpEquiv:"refresh",content:`0;url=${i.absoluteURL||i.to}`})}}return t}function ns({routeContext:t,match:a,children:r}){let l=n.useContext(De);return l&&l.static&&l.staticContext&&(a.route.errorElement||a.route.ErrorBoundary)&&(l.staticContext._deepestRenderedBoundaryId=a.route.id),n.createElement(be.Provider,{value:t},r)}function ls(t,a=[],r){let l=r==null?void 0:r.state;if(t==null){if(!l)return null;if(l.errors)t=l.matches;else if(a.length===0&&!l.initialized&&l.matches.length>0)t=l.matches;else return null}let s=t,i=l==null?void 0:l.errors;if(i!=null){let m=s.findIndex(g=>g.route.id&&(i==null?void 0:i[g.route.id])!==void 0);ee(m>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(i).join(",")}`),s=s.slice(0,Math.min(s.length,m+1))}let o=!1,u=-1;if(r&&l){o=l.renderFallback;for(let m=0;m=0?s=s.slice(0,u+1):s=[s[0]];break}}}}let d=r==null?void 0:r.onError,c=l&&d?(m,g)=>{var h,y;d(m,{location:l.location,params:((y=(h=l.matches)==null?void 0:h[0])==null?void 0:y.params)??{},unstable_pattern:Vr(l.matches),errorInfo:g})}:void 0;return s.reduceRight((m,g,h)=>{let y,_=!1,R=null,j=null;l&&(y=i&&g.route.id?i[g.route.id]:void 0,R=g.route.errorElement||rs,o&&(u<0&&h===0?(Pa("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),_=!0,j=null):u===h&&(_=!0,j=g.route.hydrateFallbackElement||null)));let x=a.concat(s.slice(0,h+1)),k=()=>{let D;return y?D=R:_?D=j:g.route.Component?D=n.createElement(g.route.Component,null):g.route.element?D=g.route.element:D=m,n.createElement(ns,{match:g,routeContext:{outlet:m,matches:x,isDataRoute:l!=null},children:D})};return l&&(g.route.ErrorBoundary||g.route.errorElement||h===0)?n.createElement(La,{location:l.location,revalidation:l.revalidation,component:R,error:y,children:k(),routeContext:{outlet:null,matches:x,isDataRoute:!0},onError:c}):k()},null)}function It(t){return`${t} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function is(t){let a=n.useContext(De);return ee(a,It(t)),a}function os(t){let a=n.useContext(at);return ee(a,It(t)),a}function ds(t){let a=n.useContext(be);return ee(a,It(t)),a}function Dt(t){let a=ds(t),r=a.matches[a.matches.length-1];return ee(r.route.id,`${t} can only be used on routes that contain a unique "id"`),r.route.id}function cs(){return Dt("useRouteId")}function us(){var l;let t=n.useContext($t),a=os("useRouteError"),r=Dt("useRouteError");return t!==void 0?t:(l=a.errors)==null?void 0:l[r]}function ms(){let{router:t}=is("useNavigate"),a=Dt("useNavigate"),r=n.useRef(!1);return Ra(()=>{r.current=!0}),n.useCallback(async(s,i={})=>{xe(r.current,Ea),r.current&&(typeof s=="number"?await t.navigate(s):await t.navigate(s,{fromRouteId:a,...i}))},[t,a])}var aa={};function Pa(t,a,r){!a&&!aa[t]&&(aa[t]=!0,xe(!1,r))}n.memo(gs);function gs({routes:t,future:a,state:r,isStatic:l,onError:s}){return Ta(t,void 0,{state:r,isStatic:l,onError:s})}function xs(t){return es(t.context)}function te(t){ee(!1,"A is only ever to be used as the child of element, never rendered directly. Please wrap your in a .")}function hs({basename:t="/",children:a=null,location:r,navigationType:l="POP",navigator:s,static:i=!1,unstable_useTransitions:o}){ee(!Ke(),"You cannot render a inside another . You should never have more than one in your app.");let u=t.replace(/^\/*/,"/"),d=n.useMemo(()=>({basename:u,navigator:s,static:i,unstable_useTransitions:o,future:{}}),[u,s,i,o]);typeof r=="string"&&(r=Ie(r));let{pathname:c="/",search:m="",hash:g="",state:h=null,key:y="default",unstable_mask:_}=r,R=n.useMemo(()=>{let j=ve(c,u);return j==null?null:{location:{pathname:j,search:m,hash:g,state:h,key:y,unstable_mask:_},navigationType:l}},[u,c,m,g,h,y,l,_]);return xe(R!=null,` is not able to match the URL "${c}${m}${g}" because it does not start with the basename, so the won't render anything.`),R==null?null:n.createElement(de.Provider,{value:d},n.createElement(Ge.Provider,{children:a,value:R}))}function ps({children:t,location:a}){return ts(_t(t),a)}function _t(t,a=[]){let r=[];return n.Children.forEach(t,(l,s)=>{if(!n.isValidElement(l))return;let i=[...a,s];if(l.type===n.Fragment){r.push.apply(r,_t(l.props.children,i));return}ee(l.type===te,`[${typeof l.type=="string"?l.type:l.type.name}] is not a component. All component children of must be a or `),ee(!l.props.index||!l.props.children,"An index route cannot have child routes.");let o={id:l.props.id||i.join("-"),caseSensitive:l.props.caseSensitive,element:l.props.element,Component:l.props.Component,index:l.props.index,path:l.props.path,middleware:l.props.middleware,loader:l.props.loader,action:l.props.action,hydrateFallbackElement:l.props.hydrateFallbackElement,HydrateFallback:l.props.HydrateFallback,errorElement:l.props.errorElement,ErrorBoundary:l.props.ErrorBoundary,hasErrorBoundary:l.props.hasErrorBoundary===!0||l.props.ErrorBoundary!=null||l.props.errorElement!=null,shouldRevalidate:l.props.shouldRevalidate,handle:l.props.handle,lazy:l.props.lazy};l.props.children&&(o.children=_t(l.props.children,i)),r.push(o)}),r}var Ye="get",Xe="application/x-www-form-urlencoded";function rt(t){return typeof HTMLElement<"u"&&t instanceof HTMLElement}function bs(t){return rt(t)&&t.tagName.toLowerCase()==="button"}function ys(t){return rt(t)&&t.tagName.toLowerCase()==="form"}function fs(t){return rt(t)&&t.tagName.toLowerCase()==="input"}function ks(t){return!!(t.metaKey||t.altKey||t.ctrlKey||t.shiftKey)}function js(t,a){return t.button===0&&(!a||a==="_self")&&!ks(t)}var We=null;function vs(){if(We===null)try{new FormData(document.createElement("form"),0),We=!1}catch{We=!0}return We}var ws=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function bt(t){return t!=null&&!ws.has(t)?(xe(!1,`"${t}" is not a valid \`encType\` for \`
\`/\`\` and will default to "${Xe}"`),null):t}function Ns(t,a){let r,l,s,i,o;if(ys(t)){let u=t.getAttribute("action");l=u?ve(u,a):null,r=t.getAttribute("method")||Ye,s=bt(t.getAttribute("enctype"))||Xe,i=new FormData(t)}else if(bs(t)||fs(t)&&(t.type==="submit"||t.type==="image")){let u=t.form;if(u==null)throw new Error('Cannot submit a