1import{r as e,g as t}from"./react-vendor-UuX_HcZN.js";var n=e();const r=t(n); 2/** 3 * react-router v7.9.6 4 * 5 * Copyright (c) Remix Software Inc. 6 * 7 * This source code is licensed under the MIT license found in the 8 * LICENSE.md file in the root directory of this source tree. 9 * 10 * @license MIT 11 */var a="popstate";function o(e={}){return function(e,t,n,r={}){let{window:o=document.defaultView,v5Compat:l=!1}=r,h=o.history,p="POP",d=null,m=f();null==m&&(m=0,h.replaceState({...h.state,idx:m},""));function f(){return(h.state||{idx:null}).idx}function v(){p="POP";let e=f(),t=null==e?null:e-m;m=e,d&&d({action:p,location:b.location,delta:t})}function y(e,t){p="PUSH";let n=s(b.location,e,t);m=f()+1;let r=u(n,m),a=b.createHref(n);try{h.pushState(r,"",a)}catch(i){if(i instanceof DOMException&&"DataCloneError"===i.name)throw i;o.location.assign(a)}l&&d&&d({action:p,location:b.location,delta:1})}function g(e,t){p="REPLACE";let n=s(b.location,e,t);m=f();let r=u(n,m),a=b.createHref(n);h.replaceState(r,"",a),l&&d&&d({action:p,location:b.location,delta:0})}function w(e){return function(e,t=!1){let n="http://localhost";"undefined"!=typeof window&&(n="null"!==window.location.origin?window.location.origin:window.location.href);i(n,"No window.location.(origin|href) available to create URL");let r="string"==typeof e?e:c(e);r=r.replace(/ $/,"%20"),!t&&r.startsWith("//")&&(r=n+r);return new URL(r,n)}(e)}let b={get action(){return p},get location(){return e(o,h)},listen(e){if(d)throw new Error("A history only accepts one active listener");return o.addEventListener(a,v),d=e,()=>{o.removeEventListener(a,v),d=null}},createHref:e=>t(o,e),createURL:w,encodeLocation(e){let t=w(e);return{pathname:t.pathname,search:t.search,hash:t.hash}},push:y,replace:g,go:e=>h.go(e)};return b}(function(e,t){let{pathname:n,search:r,hash:a}=e.location;return s("",{pathname:n,search:r,hash:a},t.state&&t.state.usr||null,t.state&&t.state.key||"default")},function(e,t){return"string"==typeof t?t:c(t)},0,e)}function i(e,t){if(!1===e||null==e)throw new Error(t)}function l(e,t){if(!e)try{throw new Error(t)}catch(n){}}function u(e,t){return{usr:e.state,key:e.key,idx:t}}function s(e,t,n=null,r){return{pathname:"string"==typeof e?e:e.pathname,search:"",hash:"",..."string"==typeof t?h(t):t,state:n,key:t&&t.key||r||Math.random().toString(36).substring(2,10)}}function c({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 h(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 p(e,t,n="/"){return function(e,t,n,r){let a="string"==typeof t?h(t):t,o=$(a.pathname||"/",n);if(null==o)return null;let i=d(e);!function(e){e.sort((e,t)=>e.score!==t.score?t.score-e.score:function(e,t){let n=e.length===t.length&&e.slice(0,-1).every((e,n)=>e===t[n]);return n?e[e.length-1]-t[t.length-1]:0}(e.routesMeta.map(e=>e.childrenIndex),t.routesMeta.map(e=>e.childrenIndex)))}(i);let l=null;for(let u=0;null==l&&u<i.length;++u){let e=S(o);l=R(i[u],e,r)}return l}(e,t,n,!1)}function d(e,t=[],n=[],r="",a=!1){let o=(e,o,l=a,u)=>{let s={relativePath:void 0===u?e.path||"":u,caseSensitive:!0===e.caseSensitive,childrenIndex:o,route:e};if(s.relativePath.startsWith("/")){if(!s.relativePath.startsWith(r)&&l)return;i(s.relativePath.startsWith(r),`Absolute route path "${s.relativePath}" nested under path "${r}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),s.relativePath=s.relativePath.slice(r.length)}let c=F([r,s.relativePath]),h=n.concat(s);e.children&&e.children.length>0&&(i(!0!==e.index,`Index routes must not have child routes. Please remove all child routes from route path "${c}".`),d(e.children,t,h,c,l)),(null!=e.path||e.index)&&t.push({path:c,score:x(c,e.index),routesMeta:h})};return e.forEach((e,t)=>{if(""!==e.path&&e.path?.includes("?"))for(let n of m(e.path))o(e,t,!0,n);else o(e,t)}),t}function m(e){let t=e.split("/");if(0===t.length)return[];let[n,...r]=t,a=n.endsWith("?"),o=n.replace(/\?$/,"");if(0===r.length)return a?[o,""]:[o];let i=m(r.join("/")),l=[];return l.push(...i.map(e=>""===e?o:[o,e].join("/"))),a&&l.push(...i),l.map(t=>e.startsWith("/")&&""===t?"/":t)}var f=/^:[\w-]+$/,v=3,y=2,g=1,w=10,b=-2,E=e=>"*"===e;function x(e,t){let n=e.split("/"),r=n.length;return n.some(E)&&(r+=b),t&&(r+=y),n.filter(e=>!E(e)).reduce((e,t)=>
11e+(f.test(t)?v:""===t?g:w),r)}function R(e,t,n=!1){let{routesMeta:r}=e,a={},o="/",i=[];for(let l=0;l<r.length;++l){let e=r[l],u=l===r.length-1,s="/"===o?t:t.slice(o.length)||"/",c=C({path:e.relativePath,caseSensitive:e.caseSensitive,end:u},s),h=e.route;if(!c&&u&&n&&!r[r.length-1].route.index&&(c=C({path:e.relativePath,caseSensitive:e.caseSensitive,end:!1},s)),!c)return null;Object.assign(a,c.params),i.push({params:a,pathname:F([o,c.pathname]),pathnameBase:M(F([o,c.pathnameBase])),route:h}),"/"!==c.pathnameBase&&(o=F([o,c.pathnameBase]))}return i}function C(e,t){"string"==typeof e&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=function(e,t=!1,n=!0){l("*"===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,(e,t,n)=>(r.push({paramName:t,isOptional:null!=n}),n?"/?([^\\/]+)?":"/([^\\/]+)")).replace(/\/([\w-]+)\?(\/|$)/g,"(/$1)?$2");e.endsWith("*")?(r.push({paramName:"*"}),a+="*"===e||"/*"===e?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?a+="\\/*$":""!==e&&"/"!==e&&(a+="(?:(?=\\/|$))");let o=new RegExp(a,t?void 0:"i");return[o,r]}(e.path,e.caseSensitive,e.end),a=t.match(n);if(!a)return null;let o=a[0],i=o.replace(/(.)\/+$/,"$1"),u=a.slice(1);return{params:r.reduce((e,{paramName:t,isOptional:n},r)=>{if("*"===t){let e=u[r]||"";i=o.slice(0,o.length-e.length).replace(/(.)\/+$/,"$1")}const a=u[r];return e[t]=n&&!a?void 0:(a||"").replace(/%2F/g,"/"),e},{}),pathname:o,pathnameBase:i,pattern:e}}function S(e){try{return e.split("/").map(e=>decodeURIComponent(e).replace(/\//g,"%2F")).join("/")}catch(t){return l(!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 $(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 L=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i;function P(e,t="/"){let n,{pathname:r,search:a="",hash:o=""}="string"==typeof e?h(e):e;if(r)if(i=r,L.test(i))n=r;else{if(r.includes("//")){let e=r;r=r.replace(/\/\/+/g,"/"),l(!1,`Pathnames cannot have embedded double slashes - normalizing ${e} -> ${r}`)}n=r.startsWith("/")?k(r.substring(1),"/"):k(r,t)}else n=t;var i;return{pathname:n,search:O(a),hash:D(o)}}function k(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(e=>{".."===e?n.length>1&&n.pop():"."!==e&&n.push(e)}),n.length>1?n.join("/"):"/"}function T(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 N(e){let t=function(e){return e.filter((e,t)=>0===t||e.route.path&&e.route.path.length>0)}(e);return t.map((e,n)=>n===t.length-1?e.pathname:e.pathnameBase)}function A(e,t,n,r=!1){let a;"string"==typeof e?a=h(e):(a={...e},i(!a.pathname||!a.pathname.includes("?"),T("?","pathname","search",a)),i(!a.pathname||!a.pathname.includes("#"),T("#","pathname","hash",a)),i(!a.search||!a.search.includes("#"),T("#","search","hash",a)));let o,l=""===e||""===a.pathname,u=l?"/":a.pathname;if(null==u)o=n;else{let e=t.length-1;if(!r&&u.startsWith("..")){let t=u.split("/");for(;".."===t[0];)t.shift(),e-=1;a.pathname=t.join("/")}o=e>=0?t[e]:"/"}let s=P(a,o),c=u&&"/"!==u&&u.endsWith("/"),p=(l||"."===u)&&n.endsWith("/");return s.pathname.endsWith("/")||!c&&!p||(s.pathname+="/"),s}var F=e=>e.join("/").replace(/\/\/+/g,"/"),M=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),O=e=>e&&"?"!==e?e.startsWith("?")?e:"?"+e:"",D=e=>e&&"#"!==e?e.startsWith("#")?e:"#"+e:"";Object.getOwnPropertyNames(Object.prototype).sort().join("\0");var U=["POST","PUT","PATCH","DELETE"];new Set(U);var W=["GET",...U];new Set(W);var j=n.createContext(null);j.displayName="DataRouter";var B=n.createContext(null);B.displayName="DataRouterState",n.createContext(!1);var I=n.createContext({isTransitioning:!1});I.displayName="ViewTransition",n.createContext(new Map).displayName="Fetchers",n.createContext(null).displayName="Await";var _=n.createContext(null);_.displayName="Navigation";var H=n.createContext(null);H.displayName="Location";var z=n.createContext({outlet:null,matches:[],isDataRoute:!1});z.displayName="Route";var Y=n.createContext(null);function J(){return null!=n.useContext(H)}function K(){return i(J(),"useLocation() may be used only in the context of a <Router> component."),n.useContext(H).location}Y.displayName="RouteError";var V="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function q(e){n.useContext(_).static||n.useLayoutEffect(e)}function G(){let{isDataRoute:e}=n.useContext(z);return e?function(){let{router:e}=function(e){let t=n.useContext(j);return i(t,re(e)),t}("useNavigate"),t=ae("useNavigate"),r=n.useRef(!1);return q(()=>{r.current=!0}),n.useCallback(async(n,a={})=>
11{l(r.current,V),r.current&&("number"==typeof n?e.navigate(n):await e.navigate(n,{fromRouteId:t,...a}))},[e,t])}():function(){i(J(),"useNavigate() may be used only in the context of a <Router> component.");let e=n.useContext(j),{basename:t,navigator:r}=n.useContext(_),{matches:a}=n.useContext(z),{pathname:o}=K(),u=JSON.stringify(N(a)),s=n.useRef(!1);return q(()=>{s.current=!0}),n.useCallback((n,a={})=>{if(l(s.current,V),!s.current)return;if("number"==typeof n)return void r.go(n);let i=A(n,JSON.parse(u),o,"path"===a.relative);null==e&&"/"!==t&&(i.pathname="/"===i.pathname?t:F([t,i.pathname])),(a.replace?r.replace:r.push)(i,a.state,a)},[t,r,u,o,e])}()}function X(e,{relative:t}={}){let{matches:r}=n.useContext(z),{pathname:a}=K(),o=JSON.stringify(N(r));return n.useMemo(()=>A(e,JSON.parse(o),a,"path"===t),[e,o,a,t])}function Q(e,t,r,a,o){i(J(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:u}=n.useContext(_),{matches:s}=n.useContext(z),c=s[s.length-1],d=c?c.params:{},m=c?c.pathname:"/",f=c?c.pathnameBase:"/",v=c&&c.route;{let e=v&&v.path||"";ie(m,!v||e.endsWith("*")||e.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${m}" (under <Route path="${e}">) 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.\n\nPlease change the parent <Route path="${e}"> to <Route path="${"/"===e?"*":`${e}/*`}">.`)}let y,g=K();if(t){let e="string"==typeof t?h(t):t;i("/"===f||e.pathname?.startsWith(f),`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 "${f}" but pathname "${e.pathname}" was given in the \`location\` prop.`),y=e}else y=g;let w=y.pathname||"/",b=w;if("/"!==f){let e=f.replace(/^\//,"").split("/");b="/"+w.replace(/^\//,"").split("/").slice(e.length).join("/")}let E=p(e,{pathname:b});l(v||null!=E,`No routes matched location "${y.pathname}${y.search}${y.hash}" `),l(null==E||void 0!==E[E.length-1].route.element||void 0!==E[E.length-1].route.Component||void 0!==E[E.length-1].route.lazy,`Matched leaf route at location "${y.pathname}${y.search}${y.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=function(e,t=[],r=null,a=null){if(null==e){if(!r)return null;if(r.errors)e=r.matches;else{if(0!==t.length||r.initialized||!(r.matches.length>0))return null;e=r.matches}}let o=e,l=r?.errors;if(null!=l){let e=o.findIndex(e=>e.route.id&&void 0!==l?.[e.route.id]);i(e>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(l).join(",")}`),o=o.slice(0,Math.min(o.length,e+1))}let u=!1,s=-1;if(r)for(let n=0;n<o.length;n++){let e=o[n];if((e.route.HydrateFallback||e.route.hydrateFallbackElement)&&(s=n),e.route.id){let{loaderData:t,errors:n}=r,a=e.route.loader&&!t.hasOwnProperty(e.route.id)&&(!n||void 0===n[e.route.id]);if(e.route.lazy||a){u=!0,o=s>=0?o.slice(0,s+1):[o[0]];break}}}let c=r&&a?(e,t)=>{a(e,{location:r.location,params:r.matches?.[0]?.params??{},errorInfo:t})}:void 0;return o.reduceRight((e,a,i)=>{let h,p=!1,d=null,m=null;r&&(h=l&&a.route.id?l[a.route.id]:void 0,d=a.route.errorElement||ee,u&&(s<0&&0===i?(ie("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),p=!0,m=null):s===i&&(p=!0,m=a.route.hydrateFallbackElement||null)));let f=t.concat(o.slice(0,i+1)),v=()=>{let t;return t=h?d:p?m:a.route.Component?n.createElement(a.route.Component,null):a.route.element?a.route.element:e,n.createElement(ne,{match:a,routeContext:{outlet:e,matches:f,isDataRoute:null!=r},children:t})};return r&&(a.route.ErrorBoundary||a.route.errorElement||0===i)?n.createElement(te,{location:r.location,revalidation:r.revalidation,component:d,error:h,children:v(),routeContext:{outlet:null,matches:f,isDataRoute:!0},onError:c}):v()},null)}(E&&E.map(e=>Object.assign({},e,{params:Object.assign({},d,e.params),pathname:F([f,u.encodeLocation?u.encodeLocation(e.pathname.replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:e.pathname]),pathnameBase:"/"===e.pathnameBase?f:F([f,u.encodeLocation?u.encodeLocation(e.pathnameBase.replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:e.pathnameBase])})),s,r,a,o);return t&&x?n.createElement(H.Provider,{value:{location:{pathname:"/",search:"",hash:"",state:null,key:"default",...y},navigationType:"POP"}},x):x}function Z(){let e=function(){let e=n.useContext(Y),t=function(e){let t=n.useContext(B);return i(t,re(e)),t}("useRouteError"),r=ae("useRouteError");
11if(void 0!==e)return e;return t.errors?.[r]}(),t=function(e){return null!=e&&"number"==typeof e.status&&"string"==typeof e.statusText&&"boolean"==typeof e.internal&&"data"in e}(e)?`${e.status} ${e.statusText}`:e instanceof Error?e.message:JSON.stringify(e),r=e instanceof Error?e.stack:null,a="rgba(200,200,200, 0.5)",o={padding:"0.5rem",backgroundColor:a},l={padding:"2px 4px",backgroundColor:a},u=null;return u=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:l},"ErrorBoundary")," or"," ",n.createElement("code",{style:l},"errorElement")," prop on your route.")),n.createElement(n.Fragment,null,n.createElement("h2",null,"Unexpected Application Error!"),n.createElement("h3",{style:{fontStyle:"italic"}},t),r?n.createElement("pre",{style:o},r):null,u)}n.createContext(null);var ee=n.createElement(Z,null),te=class extends n.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||"idle"!==t.revalidation&&"idle"===e.revalidation?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:void 0!==e.error?e.error:t.error,location:t.location,revalidation:e.revalidation||t.revalidation}}componentDidCatch(e,t){this.props.onError&&this.props.onError(e,t)}render(){return void 0!==this.state.error?n.createElement(z.Provider,{value:this.props.routeContext},n.createElement(Y.Provider,{value:this.state.error,children:this.props.component})):this.props.children}};function ne({routeContext:e,match:t,children:r}){let a=n.useContext(j);return a&&a.static&&a.staticContext&&(t.route.errorElement||t.route.ErrorBoundary)&&(a.staticContext._deepestRenderedBoundaryId=t.route.id),n.createElement(z.Provider,{value:e},r)}function re(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function ae(e){let t=function(e){let t=n.useContext(z);return i(t,re(e)),t}(e),r=t.matches[t.matches.length-1];return i(r.route.id,`${e} can only be used on routes that contain a unique "id"`),r.route.id}var oe={};function ie(e,t,n){t||oe[e]||(oe[e]=!0,l(!1,n))}function le(e){i(!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 ue({basename:e="/",children:t=null,location:r,navigationType:a="POP",navigator:o,static:u=!1}){i(!J(),"You cannot render a <Router> inside another <Router>. You should never have more than one in your app.");let s=e.replace(/^\/*/,"/"),c=n.useMemo(()=>({basename:s,navigator:o,static:u,future:{}}),[s,o,u]);"string"==typeof r&&(r=h(r));let{pathname:p="/",search:d="",hash:m="",state:f=null,key:v="default"}=r,y=n.useMemo(()=>{let e=$(p,s);return null==e?null:{location:{pathname:e,search:d,hash:m,state:f,key:v},navigationType:a}},[s,p,d,m,f,v,a]);return l(null!=y,`<Router basename="${s}"> is not able to match the URL "${p}${d}${m}" because it does not start with the basename, so the <Router> won't render anything.`),null==y?null:n.createElement(_.Provider,{value:c},n.createElement(H.Provider,{children:t,value:y}))}function se({children:e,location:t}){return Q(ce(e),t)}function ce(e,t=[]){let r=[];return n.Children.forEach(e,(e,a)=>{if(!n.isValidElement(e))return;let o=[...t,a];if(e.type===n.Fragment)return void r.push.apply(r,ce(e.props.children,o));i(e.type===le,`[${"string"==typeof e.type?e.type:e.type.name}] is not a <Route> component. All component children of <Routes> must be a <Route> or <React.Fragment>`),i(!e.props.index||!e.props.children,"An index route cannot have child routes.");let l={id:e.props.id||o.join("-"),caseSensitive:e.props.caseSensitive,element:e.props.element,Component:e.props.Component,index:e.props.index,path:e.props.path,middleware:e.props.middleware,loader:e.props.loader,action:e.props.action,hydrateFallbackElement:e.props.hydrateFallbackElement,HydrateFallback:e.props.HydrateFallback,errorElement:e.props.errorElement,ErrorBoundary:e.props.ErrorBoundary,hasErrorBoundary:!0===e.props.hasErrorBoundary||null!=e.props.ErrorBoundary||null!=e.props.errorElement,shouldRevalidate:e.props.shouldRevalidate,handle:e.props.handle,lazy:e.props.lazy};e.props.children&&(l.children=ce(e.props.children,o)),r.push(l)}),r}n.memo(function({routes:e,future:t,state:n,unstable_onError:r}){return Q(e,void 0,n,r,t)});var he="get",pe="application/x-www-form-urlencoded";function de(e){return null!=e&&"string"==typeof e.tagName}function me(e=""){return new URLSearchParams("string"==typeof e||Array.isArray(e)||e instanceof URLSearchParams?e:Object.keys(e).reduce((t,n)=>{let r=e[n];return t.concat(Array.isArray(r)?r.map(e=>[n,e]):[[n,r]])},[]))}var fe=null;var ve=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function ye(e){return null==e||ve.has(e)?e:(l(!1,`"${e}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${pe}"`),null)}function ge(e,t){let n,r,a,o,i;if(de(l=e)&&"form"===l.tagName.toLowerCase()){let i=e.getAttribute("action");r=i?$(i,t):null,n=e.getAttribute("method")||he,a=ye(e.getAttribute("enctype"))||pe,o=new FormData(e)}else if(function(e){return de(e)&&"button"===e.tagName.toLowerCase()}(e)||function(e){return de(e)&&"input"===e.tagName.toLowerCase()}(e)&&("submit"===e.type||"image"===e.type)){let i=e.form;if(null==i)throw new Error('Cannot submit a <button> or <input type="submit"> without a <form>');let l=e.getAttribute("formaction")||i.getAttribute("action");if(r=l?$(l,t):null,n=e.getAttribute("formmethod")||i.getAttribute("method")||he,a=ye(e.getAttribute("formenctype"))||ye(i.getAttribute("enctype"))||pe,o=new FormData(i,e),!function(){if(null===fe)try{new FormData(document.createElement("form"),0),fe=!1}catch(e){fe=!0}return fe}()){let{name:t,type:n,value:r}=e;if("image"===n){let e=t?`${t}.`:"";o.append(`${e}x`,"0"),o.append(`${e}y`,"0")}
11else t&&o.append(t,r)}}else{if(de(e))throw new Error('Cannot submit element that is not <form>, <button>, or <input type="submit|image">');n=he,r=null,a=pe,i=e}var l;return o&&"text/plain"===a&&(i=o,o=void 0),{action:r,method:n.toLowerCase(),encType:a,formData:o,body:i}}function we(e,t){if(!1===e||null==e)throw new Error(t)}function be(e){return null!=e&&(null==e.href?"preload"===e.rel&&"string"==typeof e.imageSrcSet&&"string"==typeof e.imageSizes:"string"==typeof e.rel&&"string"==typeof e.href)}async function Ee(e,t,n){return function(e,t){let n=new Set;return new Set(t),e.reduce((e,t)=>{let r=JSON.stringify(function(e){let t={},n=Object.keys(e).sort();for(let r of n)t[r]=e[r];return t}(t));return n.has(r)||(n.add(r),e.push({key:r,link:t})),e},[])}((await Promise.all(e.map(async e=>{let r=t.routes[e.route.id];if(r){let e=await async function(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 window.__reactRouterContext&&window.__reactRouterContext.isSpaMode,window.location.reload(),new Promise(()=>{})}}(r,n);return e.links?e.links():[]}return[]}))).flat(1).filter(be).filter(e=>"stylesheet"===e.rel||"preload"===e.rel).map(e=>"stylesheet"===e.rel?{...e,rel:"prefetch",as:"style"}:{...e,rel:"prefetch"}))}function xe(e,t,n,r,a,o){let i=(e,t)=>!n[t]||e.route.id!==n[t].route.id,l=(e,t)=>
11n[t].pathname!==e.pathname||n[t].route.path?.endsWith("*")&&n[t].params["*"]!==e.params["*"];return"assets"===o?t.filter((e,t)=>i(e,t)||l(e,t)):"data"===o?t.filter((t,o)=>{let u=r.routes[t.route.id];if(!u||!u.hasLoader)return!1;if(i(t,o)||l(t,o))return!0;if(t.route.shouldRevalidate){let r=t.route.shouldRevalidate({currentUrl:new URL(a.pathname+a.search+a.hash,window.origin),currentParams:n[0]?.params||{},nextUrl:new URL(e,window.origin),nextParams:t.params,defaultShouldRevalidate:!0});if("boolean"==typeof r)return r}return!0}):[]}function Re(e,t,{includeHydrateFallback:n}={}){return r=e.map(e=>{let r=t.routes[e.route.id];if(!r)return[];let a=[r.module];return r.clientActionModule&&(a=a.concat(r.clientActionModule)),r.clientLoaderModule&&(a=a.concat(r.clientLoaderModule)),n&&r.hydrateFallbackModule&&(a=a.concat(r.hydrateFallbackModule)),r.imports&&(a=a.concat(r.imports)),a}).flat(1),[...new Set(r)];var r}function Ce(){let e=n.useContext(j);return we(e,"You must render this element inside a <DataRouterContext.Provider> element"),e}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");var Se=n.createContext(void 0);function $e(){let e=n.useContext(Se);return we(e,"You must render this element inside a <HydratedRouter> element"),e}function Le(e,t){return n=>{e&&e(n),n.defaultPrevented||t(n)}}function Pe({page:e,...t}){let{router:r}=Ce(),a=n.useMemo(()=>p(r.routes,e,r.basename),[r.routes,e,r.basename]);return a?n.createElement(ke,{page:e,matches:a,...t}):null}function ke({page:e,matches:t,...r}){let a=K(),{manifest:o,routeModules:i}=$e(),{basename:l}=Ce(),{loaderData:u,matches:s}=function(){let e=n.useContext(B);return we(e,"You must render this element inside a <DataRouterStateContext.Provider> element"),e}(),c=n.useMemo(()=>xe(e,t,s,o,a,"data"),[e,t,s,o,a]),h=n.useMemo(()=>xe(e,t,s,o,a,"assets"),[e,t,s,o,a]),p=n.useMemo(()=>{if(e===a.pathname+a.search+a.hash)return[];let n=new Set,r=!1;if(t.forEach(e=>{let t=o.routes[e.route.id];t&&t.hasLoader&&(!c.some(t=>t.route.id===e.route.id)&&e.route.id in u&&i[e.route.id]?.shouldRevalidate||t.hasClientLoader?r=!0:n.add(e.route.id))}),0===n.size)return[];let s=function(e,t,n){let r="string"==typeof e?new URL(e,"undefined"==typeof window?"server://singlefetch/":window.location.origin):e;return"/"===r.pathname?r.pathname=`_root.${n}`:t&&"/"===$(r.pathname,t)?r.pathname=`${t.replace(/\/$/,"")}/_root.${n}`:r.pathname=`${r.pathname.replace(/\/$/,"")}.${n}`,r}(e,l,"data");return r&&n.size>0&&s.searchParams.set("_routes",t.filter(e=>n.has(e.route.id)).map(e=>e.route.id).join(",")),[s.pathname+s.search]},[l,u,a,o,c,t,e,i]),d=n.useMemo(()=>Re(h,o),[h,o]),m=function(e){let{manifest:t,routeModules:r}=$e(),[a,o]=n.useState([]);return n.useEffect(()=>{let n=!1;return Ee(e,t,r).then(e=>{n||o(e)}),()=>{n=!0}},[e,t,r]),a}(h);return n.createElement(n.Fragment,null,p.map(e=>n.createElement("link",{key:e,rel:"prefetch",as:"fetch",href:e,...r})),d.map(e=>n.createElement("link",{key:e,rel:"modulepreload",href:e,...r})),m.map(({key:e,link:t})=>n.createElement("link",{key:e,nonce:r.nonce,...t})))}function Te(...e){return t=>{e.forEach(e=>{"function"==typeof e?e(t):null!=e&&(e.current=t)})}}Se.displayName="FrameworkContext";var Ne="undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement;try{Ne&&(window.__reactRouterVersion="7.9.6")}catch(je){}function Ae({basename:e,children:t,window:r}){let a=n.useRef();null==a.current&&(a.current=o({window:r,v5Compat:!0}));let i=a.current,[l,u]=n.useState({action:i.action,location:i.location}),s=n.useCallback(e=>{n.startTransition(()=>u(e))},[u]);return n.useLayoutEffect(()=>i.listen(s),[i,s]),n.createElement(ue,{basename:e,children:t,location:l.location,navigationType:l.action,navigator:i})}var Fe=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Me=n.forwardRef(function({onClick:e,discover:t="render",prefetch:r="none",relative:a,reloadDocument:o,replace:u,state:s,target:h,to:p,preventScrollReset:d,viewTransition:m,...f},v){let y,{basename:g}=n.useContext(_),w="string"==typeof p&&Fe.test(p),b=!1;if("string"==typeof p&&w&&(y=p,Ne))try{let e=new URL(window.location.href),t=p.startsWith("//")?new URL(e.protocol+p):new URL(p),n=$(t.pathname,g);t.origin===e.origin&&null!=n?p=n+t.search+t.hash:b=!0}catch(je){l(!1,`<Link to="${p}">
11 contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}let E=function(e,{relative:t}={}){i(J(),"useHref() may be used only in the context of a <Router> component.");let{basename:r,navigator:a}=n.useContext(_),{hash:o,pathname:l,search:u}=X(e,{relative:t}),s=l;return"/"!==r&&(s="/"===l?r:F([r,l])),a.createHref({pathname:s,search:u,hash:o})}(p,{relative:a}),[x,R,C]=function(e,t){let r=n.useContext(Se),[a,o]=n.useState(!1),[i,l]=n.useState(!1),{onFocus:u,onBlur:s,onMouseEnter:c,onMouseLeave:h,onTouchStart:p}=t,d=n.useRef(null);n.useEffect(()=>{if("render"===e&&l(!0),"viewport"===e){let e=new IntersectionObserver(e=>{e.forEach(e=>{l(e.isIntersecting)})},{threshold:.5});return d.current&&e.observe(d.current),()=>{e.disconnect()}}},[e]),n.useEffect(()=>{if(a){let e=setTimeout(()=>{l(!0)},100);return()=>{clearTimeout(e)}}},[a]);let m=()=>{o(!0)},f=()=>{o(!1),l(!1)};return r?"intent"!==e?[i,d,{}]:[i,d,{onFocus:Le(u,m),onBlur:Le(s,f),onMouseEnter:Le(c,m),onMouseLeave:Le(h,f),onTouchStart:Le(p,m)}]:[!1,d,{}]}(r,f),S=function(e,{target:t,replace:r,state:a,preventScrollReset:o,relative:i,viewTransition:l}={}){let u=G(),s=K(),h=X(e,{relative:i});return n.useCallback(n=>{if(function(e,t){return!(0!==e.button||t&&"_self"!==t||function(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}(e))}(n,t)){n.preventDefault();let t=void 0!==r?r:c(s)===c(h);u(e,{replace:t,state:a,preventScrollReset:o,relative:i,viewTransition:l})}},[s,u,h,r,a,t,e,o,i,l])}(p,{replace:u,state:s,target:h,preventScrollReset:d,relative:a,viewTransition:m});let L=n.createElement("a",{...f,...C,href:y||E,onClick:b||o?e:function(t){e&&e(t),t.defaultPrevented||S(t)},ref:Te(v,R),target:h,"data-discover":w||"render"!==t?void 0:"true"});return x&&!w?n.createElement(n.Fragment,null,L,n.createElement(Pe,{page:E})):L});function Oe(e){let t=n.useContext(j);return i(t,function(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}(e)),t}function De(e){l("undefined"!=typeof URLSearchParams,"You cannot use the `useSearchParams` hook in a browser that does not support the URLSearchParams API. If you need to support Internet Explorer 11, we recommend you load a polyfill such as https://github.com/ungap/url-search-params.");let t=n.useRef(me(e)),r=n.useRef(!1),a=K(),o=n.useMemo(()=>function(e,t){let n=me(e);return t&&t.forEach((e,r)=>{n.has(r)||t.getAll(r).forEach(e=>{n.append(r,e)})}),n}(a.search,r.current?null:t.current),[a.search]),i=G(),u=n.useCallback((e,t)=>{const n=me("function"==typeof e?e(new URLSearchParams(o)):e);r.current=!0,i("?"+n,t)},[i,o]);return[o,u]}Me.displayName="Link",n.forwardRef(function({"aria-current":e="page",caseSensitive:t=!1,className:r="",end:a=!1,style:o,to:l,viewTransition:u,children:s,...c},h){let p=X(l,{relative:c.relative}),d=K(),m=n.useContext(B),{navigator:f,basename:v}=n.useContext(_),y=null!=m&&function(e,{relative:t}={}){let r=n.useContext(I);i(null!=r,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:a}=Oe("useViewTransitionState"),o=X(e,{relative:t});if(!r.isTransitioning)return!1;let l=$(r.currentLocation.pathname,a)||r.currentLocation.pathname,u=$(r.nextLocation.pathname,a)||r.nextLocation.pathname;return null!=C(o.pathname,u)||null!=C(o.pathname,l)}(p)&&!0===u,g=f.encodeLocation?f.encodeLocation(p).pathname:p.pathname,w=d.pathname,b=m&&m.navigation&&m.navigation.location?m.navigation.location.pathname:null;t||(w=w.toLowerCase(),b=b?b.toLowerCase():null,g=g.toLowerCase()),b&&v&&(b=$(b,v)||b);const E="/"!==g&&g.endsWith("/")?g.length-1:g.length;let x,R=w===g||!a&&w.startsWith(g)&&"/"===w.charAt(E),S=null!=b&&(b===g||!a&&b.startsWith(g)&&"/"===b.charAt(g.length)),L={isActive:R,isPending:S,isTransitioning:y},P=R?e:void 0;x="function"==typeof r?r(L):[r,R?"active":null,S?"pending":null,y?"transitioning":null].filter(Boolean).join(" ");let k="function"==typeof o?o(L):o;return n.createElement(Me,{...c,"aria-current":P,className:x,ref:h,style:k,to:l,viewTransition:u},"function"==typeof s?s(L):s)}).displayName="NavLink",n.forwardRef(({discover:e="render",fetcherKey:t,navigate:r,reloadDocument:a,replace:o,state:l,method:u=he,action:s,onSubmit:h,relative:p,preventScrollReset:d,viewTransition:m,...f},v)=>{let y=function(){let{router:e}=Oe("useSubmit"),{basename:t}=n.useContext(_),r=ae("useRouteId");return n.useCallback(async(n,a={})=>{let{action:o,method:i,encType:l,formData:u,body:s}=ge(n,t);if(!1===a.navigate){let t=a.fetcherKey||We();await e.fetch(t,r,a.action||o,{preventScrollReset:a.preventScrollReset,formData:u,body:s,formMethod:a.method||i,formEncType:a.encType||l,flushSync:a.flushSync})}else await e.navigate(a.action||o,{preventScrollReset:a.preventScrollReset,formData:u,body:s,formMethod:a.method||i,formEncType:a.encType||l,replace:a.replace,state:a.state,fromRouteId:r,flushSync:a.flushSync,viewTransition:a.viewTransition})},[e,t,r])}(),g=function(e,{relative:t}={}){let{basename:r}=n.useContext(_),a=n.useContext(z);i(a,"useFormAction must be used inside a RouteContext");let[o]=a.matches.slice(-1),l={...X(e||".",{relative:t})},u=K();if(null==e){l.search=u.search;let e=new URLSearchParams(l.search),t=e.getAll("index");if(t.some(e=>""===e)){e.delete("index"),t.filter(e=>e).forEach(t=>e.append("index",t));let n=e.toString();l.search=n?`?${n}`:""}}e&&"."!==e||!o.route.index||(l.search=l.search?l.search.replace(/^\?/,"?index&"):"?index");"/"!==r&&(l.pathname="/"===l.pathname?r:F([r,l.pathname]));return c(l)}(s,{relative:p}),w="get"===u.toLowerCase()?"get":"post",b="string"==typeof s&&Fe.test(s);return n.createElement("form",{ref:v,method:w,action:g,onSubmit:a?h:e=>{if(h&&h(e),e.defaultPrevented)return;e.preventDefault();let n=e.nativeEvent.submitter,a=n?.getAttribute("formmethod")||u;y(n||e.currentTarget,{fetcherKey:t,method:a,navigate:r,replace:o,state:l,relative:p,preventScrollReset:d,viewTransition:m})},...f,"data-discover":b||"render"!==e?void 0:"true"})}).displayName="Form";var Ue=0,We=()=>`__${String(++Ue)}__`;export{Ae as B,Me as L,r as R,se as a,le as b,G as c,n as r,De as u};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.