import{r as l,j as i,c as dn}from"./client-DS0SU7Jy.js";/** * react-router v7.15.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 Et="popstate";function Rt(e){return typeof e=="object"&&e!=null&&"pathname"in e&&"search"in e&&"hash"in e&&"state"in e&&"key"in e}function hn(e={}){function t(r,a){var u;let s=(u=a.state)==null?void 0:u.masked,{pathname:o,search:c,hash:d}=s||r.location;return et("",{pathname:o,search:c,hash:d},a.state&&a.state.usr||null,a.state&&a.state.key||"default",s?{pathname:r.location.pathname,search:r.location.search,hash:r.location.hash}:void 0)}function n(r,a){return typeof a=="string"?a:Re(a)}return mn(t,n,null,e)}function M(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function q(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function fn(){return Math.random().toString(36).substring(2,10)}function kt(e,t){return{usr:e.state,key:e.key,idx:t,masked:e.mask?{pathname:e.pathname,search:e.search,hash:e.hash}:void 0}}function et(e,t,n=null,r,a){return{pathname:typeof e=="string"?e:e.pathname,search:"",hash:"",...typeof t=="string"?he(t):t,state:n,key:t&&t.key||r||fn(),mask:a}}function Re({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 he(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 mn(e,t,n,r={}){let{window:a=document.defaultView,v5Compat:s=!1}=r,o=a.history,c="POP",d=null,u=f();u==null&&(u=0,o.replaceState({...o.state,idx:u},""));function f(){return(o.state||{idx:null}).idx}function h(){c="POP";let m=f(),g=m==null?null:m-u;u=m,d&&d({action:c,location:v.location,delta:g})}function p(m,g){c="PUSH";let x=Rt(m)?m:et(v.location,m,g);u=f()+1;let w=kt(x,u),$=v.createHref(x.mask||x);try{o.pushState(w,"",$)}catch(R){if(R instanceof DOMException&&R.name==="DataCloneError")throw R;a.location.assign($)}s&&d&&d({action:c,location:v.location,delta:1})}function b(m,g){c="REPLACE";let x=Rt(m)?m:et(v.location,m,g);u=f();let w=kt(x,u),$=v.createHref(x.mask||x);o.replaceState(w,"",$),s&&d&&d({action:c,location:v.location,delta:0})}function y(m){return pn(m)}let v={get action(){return c},get location(){return e(a,o)},listen(m){if(d)throw new Error("A history only accepts one active listener");return a.addEventListener(Et,h),d=m,()=>{a.removeEventListener(Et,h),d=null}},createHref(m){return t(a,m)},createURL:y,encodeLocation(m){let g=y(m);return{pathname:g.pathname,search:g.search,hash:g.hash}},push:p,replace:b,go(m){return o.go(m)}};return v}function pn(e,t=!1){let n="http://localhost";typeof window<"u"&&(n=window.location.origin!=="null"?window.location.origin:window.location.href),M(n,"No window.location.(origin|href) available to create URL");let r=typeof e=="string"?e:Re(e);return r=r.replace(/ $/,"%20"),!t&&r.startsWith("//")&&(r=n+r),new URL(r,n)}function Bt(e,t,n="/"){return gn(e,t,n,!1)}function gn(e,t,n,r,a){let s=typeof t=="string"?he(t):t,o=te(s.pathname||"/",n);if(o==null)return null;let c=yn(e),d=null,u=Tn(o);for(let f=0;d==null&&f{let f={relativePath:u===void 0?o.path||"":u,caseSensitive:o.caseSensitive===!0,childrenIndex:c,route:o};if(f.relativePath.startsWith("/")){if(!f.relativePath.startsWith(r)&&d)return;M(f.relativePath.startsWith(r),`Absolute route path "${f.relativePath}" nested under path "${r}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),f.relativePath=f.relativePath.slice(r.length)}let h=W([r,f.relativePath]),p=n.concat(f);o.children&&o.children.length>0&&(M(o.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${h}".`),Ft(o.children,t,p,h,d)),!(o.path==null&&!o.index)&&t.push({path:h,score:Sn(h,o.index),routesMeta:p})};return e.forEach((o,c)=>{var d;if(o.path===""||!((d=o.path)!=null&&d.includes("?")))s(o,c);else for(let u of Ot(o.path))s(o,c,!0,u)}),t}function Ot(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,a=n.endsWith("?"),s=n.replace(/\?$/,"");if(r.length===0)return a?[s,""]:[s];let o=Ot(r.join("/")),c=[];return c.push(...o.map(d=>d===""?s:[s,d].join("/"))),a&&c.push(...o),c.map(d=>e.startsWith("/")&&d===""?"/":d)}function bn(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:jn(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}var vn=/^:[\w-]+$/,wn=3,xn=2,En=1,Rn=10,kn=-2,St=e=>e==="*";function Sn(e,t){let n=e.split("/"),r=n.length;return n.some(St)&&(r+=kn),t&&(r+=xn),n.filter(a=>!St(a)).reduce((a,s)=>a+(vn.test(s)?wn:s===""?En:Rn),r)}function jn(e,t){return e.length===t.length&&e.slice(0,-1).every((r,a)=>r===t[a])?e[e.length-1]-t[t.length-1]:0}function Nn(e,t,n=!1){let{routesMeta:r}=e,a={},s="/",o=[];for(let c=0;c{if(f==="*"){let y=c[p]||"";o=s.slice(0,s.length-y.length).replace(/(.)\/+$/,"$1")}const b=c[p];return h&&!b?u[f]=void 0:u[f]=(b||"").replace(/%2F/g,"/"),u},{}),pathname:s,pathnameBase:o,pattern:e}}function Cn(e,t=!1,n=!0){q(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=[],a="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(o,c,d,u,f)=>{if(r.push({paramName:c,isOptional:d!=null}),d){let h=f.charAt(u+o.length);return h&&h!=="/"?"/([^\\/]*)":"(?:/([^\\/]*))?"}return"/([^\\/]+)"}).replace(/\/([\w-]+)\?(\/|$)/g,"(/$1)?$2");return e.endsWith("*")?(r.push({paramName:"*"}),a+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?a+="\\/*$":e!==""&&e!=="/"&&(a+="(?:(?=\\/|$))"),[new RegExp(a,t?void 0:"i"),r]}function Tn(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return q(!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 te(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 Mn=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i;function An(e,t="/"){let{pathname:n,search:r="",hash:a=""}=typeof e=="string"?he(e):e,s;return n?(n=Ut(n),n.startsWith("/")?s=jt(n.substring(1),"/"):s=jt(n,t)):s=t,{pathname:s,search:In(r),hash:Pn(a)}}function jt(e,t){let n=Ue(t).split("/");return e.split("/").forEach(a=>{a===".."?n.length>1&&n.pop():a!=="."&&n.push(a)}),n.length>1?n.join("/"):"/"}function Ye(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 and the router will parse it for you.`}function $n(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function Dt(e){let t=$n(e);return t.map((n,r)=>r===t.length-1?n.pathname:n.pathnameBase)}function ot(e,t,n,r=!1){let a;typeof e=="string"?a=he(e):(a={...e},M(!a.pathname||!a.pathname.includes("?"),Ye("?","pathname","search",a)),M(!a.pathname||!a.pathname.includes("#"),Ye("#","pathname","hash",a)),M(!a.search||!a.search.includes("#"),Ye("#","search","hash",a)));let s=e===""||a.pathname==="",o=s?"/":a.pathname,c;if(o==null)c=n;else{let h=t.length-1;if(!r&&o.startsWith("..")){let p=o.split("/");for(;p[0]==="..";)p.shift(),h-=1;a.pathname=p.join("/")}c=h>=0?t[h]:"/"}let d=An(a,c),u=o&&o!=="/"&&o.endsWith("/"),f=(s||o===".")&&n.endsWith("/");return!d.pathname.endsWith("/")&&(u||f)&&(d.pathname+="/"),d}var Ut=e=>e.replace(/\/\/+/g,"/"),W=e=>Ut(e.join("/")),Ue=e=>e.replace(/\/+$/,""),_n=e=>Ue(e).replace(/^\/*/,"/"),In=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,Pn=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e,Ln=class{constructor(e,t,n,r=!1){this.status=e,this.statusText=t||"",this.internal=r,n instanceof Error?(this.data=n.toString(),this.error=n):this.data=n}};function Bn(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}function Fn(e){let t=e.map(n=>n.route.path).filter(Boolean);return W(t)||"/"}var Ht=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function zt(e,t){let n=e;if(typeof n!="string"||!Mn.test(n))return{absoluteURL:void 0,isExternal:!1,to:n};let r=n,a=!1;if(Ht)try{let s=new URL(window.location.href),o=n.startsWith("//")?new URL(s.protocol+n):new URL(n),c=te(o.pathname,t);o.origin===s.origin&&c!=null?n=c+o.search+o.hash:a=!0}catch{q(!1,` contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}return{absoluteURL:r,isExternal:a,to:n}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");var Wt=["POST","PUT","PATCH","DELETE"];new Set(Wt);var On=["GET",...Wt];new Set(On);var fe=l.createContext(null);fe.displayName="DataRouter";var ze=l.createContext(null);ze.displayName="DataRouterState";var Vt=l.createContext(!1);function Dn(){return l.useContext(Vt)}var Kt=l.createContext({isTransitioning:!1});Kt.displayName="ViewTransition";var Un=l.createContext(new Map);Un.displayName="Fetchers";var Hn=l.createContext(null);Hn.displayName="Await";var z=l.createContext(null);z.displayName="Navigation";var Se=l.createContext(null);Se.displayName="Location";var ne=l.createContext({outlet:null,matches:[],isDataRoute:!1});ne.displayName="Route";var it=l.createContext(null);it.displayName="RouteError";var Jt="REACT_ROUTER_ERROR",zn="REDIRECT",Wn="ROUTE_ERROR_RESPONSE";function Vn(e){if(e.startsWith(`${Jt}:${zn}:{`))try{let t=JSON.parse(e.slice(28));if(typeof t=="object"&&t&&typeof t.status=="number"&&typeof t.statusText=="string"&&typeof t.location=="string"&&typeof t.reloadDocument=="boolean"&&typeof t.replace=="boolean")return t}catch{}}function Kn(e){if(e.startsWith(`${Jt}:${Wn}:{`))try{let t=JSON.parse(e.slice(40));if(typeof t=="object"&&t&&typeof t.status=="number"&&typeof t.statusText=="string")return new Ln(t.status,t.statusText,t.data)}catch{}}function Jn(e,{relative:t}={}){M(je(),"useHref() may be used only in the context of a component.");let{basename:n,navigator:r}=l.useContext(z),{hash:a,pathname:s,search:o}=Ce(e,{relative:t}),c=s;return n!=="/"&&(c=s==="/"?n:W([n,s])),r.createHref({pathname:c,search:o,hash:a})}function je(){return l.useContext(Se)!=null}function re(){return M(je(),"useLocation() may be used only in the context of a component."),l.useContext(Se).location}var qt="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function Gt(e){l.useContext(z).static||l.useLayoutEffect(e)}function Ne(){let{isDataRoute:e}=l.useContext(ne);return e?or():qn()}function qn(){M(je(),"useNavigate() may be used only in the context of a component.");let e=l.useContext(fe),{basename:t,navigator:n}=l.useContext(z),{matches:r}=l.useContext(ne),{pathname:a}=re(),s=JSON.stringify(Dt(r)),o=l.useRef(!1);return Gt(()=>{o.current=!0}),l.useCallback((d,u={})=>{if(q(o.current,qt),!o.current)return;if(typeof d=="number"){n.go(d);return}let f=ot(d,JSON.parse(s),a,u.relative==="path");e==null&&t!=="/"&&(f.pathname=f.pathname==="/"?t:W([t,f.pathname])),(u.replace?n.replace:n.push)(f,u.state,u)},[t,n,s,a,e])}l.createContext(null);function Ce(e,{relative:t}={}){let{matches:n}=l.useContext(ne),{pathname:r}=re(),a=JSON.stringify(Dt(n));return l.useMemo(()=>ot(e,JSON.parse(a),r,t==="path"),[e,a,r,t])}function Gn(e,t){return Yt(e,t)}function Yt(e,t,n){var m;M(je(),"useRoutes() may be used only in the context of a component.");let{navigator:r}=l.useContext(z),{matches:a}=l.useContext(ne),s=a[a.length-1],o=s?s.params:{},c=s?s.pathname:"/",d=s?s.pathnameBase:"/",u=s&&s.route;{let g=u&&u.path||"";Qt(c,!u||g.endsWith("*")||g.endsWith("*?"),`You rendered descendant (or called \`useRoutes()\`) at "${c}" (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 f=re(),h;if(t){let g=typeof t=="string"?he(t):t;M(d==="/"||((m=g.pathname)==null?void 0:m.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 "${g.pathname}" was given in the \`location\` prop.`),h=g}else h=f;let p=h.pathname||"/",b=p;if(d!=="/"){let g=d.replace(/^\//,"").split("/");b="/"+p.replace(/^\//,"").split("/").slice(g.length).join("/")}let y=n&&n.state.matches.length?n.state.matches.map(g=>Object.assign(g,{route:n.manifest[g.route.id]||g.route})):Bt(e,{pathname:b});q(u||y!=null,`No routes matched location "${h.pathname}${h.search}${h.hash}" `),q(y==null||y[y.length-1].route.element!==void 0||y[y.length-1].route.Component!==void 0||y[y.length-1].route.lazy!==void 0,`Matched leaf route at location "${h.pathname}${h.search}${h.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 v=er(y&&y.map(g=>Object.assign({},g,{params:Object.assign({},o,g.params),pathname:W([d,r.encodeLocation?r.encodeLocation(g.pathname.replace(/%/g,"%25").replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:g.pathname]),pathnameBase:g.pathnameBase==="/"?d:W([d,r.encodeLocation?r.encodeLocation(g.pathnameBase.replace(/%/g,"%25").replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:g.pathnameBase])})),a,n);return t&&v?l.createElement(Se.Provider,{value:{location:{pathname:"/",search:"",hash:"",state:null,key:"default",mask:void 0,...h},navigationType:"POP"}},v):v}function Yn(){let e=sr(),t=Bn(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)",a={padding:"0.5rem",backgroundColor:r},s={padding:"2px 4px",backgroundColor:r},o=null;return console.error("Error handled by React Router default ErrorBoundary:",e),o=l.createElement(l.Fragment,null,l.createElement("p",null,"💿 Hey developer 👋"),l.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",l.createElement("code",{style:s},"ErrorBoundary")," or"," ",l.createElement("code",{style:s},"errorElement")," prop on your route.")),l.createElement(l.Fragment,null,l.createElement("h2",null,"Unexpected Application Error!"),l.createElement("h3",{style:{fontStyle:"italic"}},t),n?l.createElement("pre",{style:a},n):null,o)}var Xn=l.createElement(Yn,null),Xt=class extends l.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(){let e=this.state.error;if(this.context&&typeof e=="object"&&e&&"digest"in e&&typeof e.digest=="string"){const n=Kn(e.digest);n&&(e=n)}let t=e!==void 0?l.createElement(ne.Provider,{value:this.props.routeContext},l.createElement(it.Provider,{value:e,children:this.props.component})):this.props.children;return this.context?l.createElement(Qn,{error:e},t):t}};Xt.contextType=Vt;var Xe=new WeakMap;function Qn({children:e,error:t}){let{basename:n}=l.useContext(z);if(typeof t=="object"&&t&&"digest"in t&&typeof t.digest=="string"){let r=Vn(t.digest);if(r){let a=Xe.get(t);if(a)throw a;let s=zt(r.location,n);if(Ht&&!Xe.get(t))if(s.isExternal||r.reloadDocument)window.location.href=s.absoluteURL||s.to;else{const o=Promise.resolve().then(()=>window.__reactRouterDataRouter.navigate(s.to,{replace:r.replace}));throw Xe.set(t,o),o}return l.createElement("meta",{httpEquiv:"refresh",content:`0;url=${s.absoluteURL||s.to}`})}}return e}function Zn({routeContext:e,match:t,children:n}){let r=l.useContext(fe);return r&&r.static&&r.staticContext&&(t.route.errorElement||t.route.ErrorBoundary)&&(r.staticContext._deepestRenderedBoundaryId=t.route.id),l.createElement(ne.Provider,{value:e},n)}function er(e,t=[],n){let r=n==null?void 0:n.state;if(e==null){if(!r)return null;if(r.errors)e=r.matches;else if(t.length===0&&!r.initialized&&r.matches.length>0)e=r.matches;else return null}let a=e,s=r==null?void 0:r.errors;if(s!=null){let f=a.findIndex(h=>h.route.id&&(s==null?void 0:s[h.route.id])!==void 0);M(f>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(s).join(",")}`),a=a.slice(0,Math.min(a.length,f+1))}let o=!1,c=-1;if(n&&r){o=r.renderFallback;for(let f=0;f=0?a=a.slice(0,c+1):a=[a[0]];break}}}}let d=n==null?void 0:n.onError,u=r&&d?(f,h)=>{var p,b;d(f,{location:r.location,params:((b=(p=r.matches)==null?void 0:p[0])==null?void 0:b.params)??{},pattern:Fn(r.matches),errorInfo:h})}:void 0;return a.reduceRight((f,h,p)=>{let b,y=!1,v=null,m=null;r&&(b=s&&h.route.id?s[h.route.id]:void 0,v=h.route.errorElement||Xn,o&&(c<0&&p===0?(Qt("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),y=!0,m=null):c===p&&(y=!0,m=h.route.hydrateFallbackElement||null)));let g=t.concat(a.slice(0,p+1)),x=()=>{let w;return b?w=v:y?w=m:h.route.Component?w=l.createElement(h.route.Component,null):h.route.element?w=h.route.element:w=f,l.createElement(Zn,{match:h,routeContext:{outlet:f,matches:g,isDataRoute:r!=null},children:w})};return r&&(h.route.ErrorBoundary||h.route.errorElement||p===0)?l.createElement(Xt,{location:r.location,revalidation:r.revalidation,component:v,error:b,children:x(),routeContext:{outlet:null,matches:g,isDataRoute:!0},onError:u}):x()},null)}function lt(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function tr(e){let t=l.useContext(fe);return M(t,lt(e)),t}function nr(e){let t=l.useContext(ze);return M(t,lt(e)),t}function rr(e){let t=l.useContext(ne);return M(t,lt(e)),t}function ct(e){let t=rr(e),n=t.matches[t.matches.length-1];return M(n.route.id,`${e} can only be used on routes that contain a unique "id"`),n.route.id}function ar(){return ct("useRouteId")}function sr(){var r;let e=l.useContext(it),t=nr("useRouteError"),n=ct("useRouteError");return e!==void 0?e:(r=t.errors)==null?void 0:r[n]}function or(){let{router:e}=tr("useNavigate"),t=ct("useNavigate"),n=l.useRef(!1);return Gt(()=>{n.current=!0}),l.useCallback(async(a,s={})=>{q(n.current,qt),n.current&&(typeof a=="number"?await e.navigate(a):await e.navigate(a,{fromRouteId:t,...s}))},[e,t])}var Nt={};function Qt(e,t,n){!t&&!Nt[e]&&(Nt[e]=!0,q(!1,n))}l.memo(ir);function ir({routes:e,manifest:t,future:n,state:r,isStatic:a,onError:s}){return Yt(e,void 0,{manifest:t,state:r,isStatic:a,onError:s})}function Be(e){M(!1,"A is only ever to be used as the child of element, never rendered directly. Please wrap your in a .")}function lr({basename:e="/",children:t=null,location:n,navigationType:r="POP",navigator:a,static:s=!1,useTransitions:o}){M(!je(),"You cannot render a inside another . You should never have more than one in your app.");let c=e.replace(/^\/*/,"/"),d=l.useMemo(()=>({basename:c,navigator:a,static:s,useTransitions:o,future:{}}),[c,a,s,o]);typeof n=="string"&&(n=he(n));let{pathname:u="/",search:f="",hash:h="",state:p=null,key:b="default",mask:y}=n,v=l.useMemo(()=>{let m=te(u,c);return m==null?null:{location:{pathname:m,search:f,hash:h,state:p,key:b,mask:y},navigationType:r}},[c,u,f,h,p,b,r,y]);return q(v!=null,` is not able to match the URL "${u}${f}${h}" because it does not start with the basename, so the won't render anything.`),v==null?null:l.createElement(z.Provider,{value:d},l.createElement(Se.Provider,{children:t,value:v}))}function cr({children:e,location:t}){return Gn(tt(e),t)}function tt(e,t=[]){let n=[];return l.Children.forEach(e,(r,a)=>{if(!l.isValidElement(r))return;let s=[...t,a];if(r.type===l.Fragment){n.push.apply(n,tt(r.props.children,s));return}M(r.type===Be,`[${typeof r.type=="string"?r.type:r.type.name}] is not a component. All component children of must be a or `),M(!r.props.index||!r.props.children,"An index route cannot have child routes.");let o={id:r.props.id||s.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&&(o.children=tt(r.props.children,s)),n.push(o)}),n}var Fe="get",Oe="application/x-www-form-urlencoded";function We(e){return typeof HTMLElement<"u"&&e instanceof HTMLElement}function ur(e){return We(e)&&e.tagName.toLowerCase()==="button"}function dr(e){return We(e)&&e.tagName.toLowerCase()==="form"}function hr(e){return We(e)&&e.tagName.toLowerCase()==="input"}function fr(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function mr(e,t){return e.button===0&&(!t||t==="_self")&&!fr(e)}var _e=null;function pr(){if(_e===null)try{new FormData(document.createElement("form"),0),_e=!1}catch{_e=!0}return _e}var gr=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function Qe(e){return e!=null&&!gr.has(e)?(q(!1,`"${e}" is not a valid \`encType\` for \`
\`/\`\` and will default to "${Oe}"`),null):e}function yr(e,t){let n,r,a,s,o;if(dr(e)){let c=e.getAttribute("action");r=c?te(c,t):null,n=e.getAttribute("method")||Fe,a=Qe(e.getAttribute("enctype"))||Oe,s=new FormData(e)}else if(ur(e)||hr(e)&&(e.type==="submit"||e.type==="image")){let c=e.form;if(c==null)throw new Error('Cannot submit a