PageSourceSearch

https://cybershoke.net/assets/vendor-router-CYD8mbvC.js

js cybershoke.net collected 2026-10-04 05:21:31 UTC 38,108 bytes, 3 lines download raw bytes

1import{r as i}from"./vendor-react-BGN68_Lp.js";var ae=/^(?:[a-z][a-z0-9+.-]*:|[\\/]{2})/i,Se=/^[\\/]{2}/;function qe(e,t){return t+e.replace(/\\/g,"/")}var ge="popstate";function ye(e){return typeof e=="object"&&e!=null&&"pathname"in e&&"search"in e&&"hash"in e&&"state"in e&&"key"in e}function Ge(e={}){function t(n,a){let o=a.state?.masked,{pathname:l,search:u,hash:s}=o||n.location;return re("",{pathname:l,search:u,hash:s},a.state&&a.state.usr||null,a.state&&a.state.key||"default",o?{pathname:n.location.pathname,search:n.location.search,hash:n.location.hash}:void 0)}function r(n,a){return typeof a=="string"?a:F(a)}return Xe(t,r,null,e)}function w(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function L(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function Ye(){return Math.random().toString(36).substring(2,10)}function ve(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 re(e,t,r=null,n,a){return{pathname:typeof e=="string"?e:e.pathname,search:"",hash:"",...typeof t=="string"?U(t):t,state:r,key:t&&t.key||n||Ye(),mask:a}}function F({pathname:e="/",search:t="",hash:r=""}){return t&&t!=="?"&&(e+=t.charAt(0)==="?"?t:"?"+t),r&&r!=="#"&&(e+=r.charAt(0)==="#"?r:"#"+r),e}function U(e){let t={};if(e){let r=e.indexOf("#");r>=0&&(t.hash=e.substring(r),e=e.substring(0,r));let n=e.indexOf("?");n>=0&&(t.search=e.substring(n),e=e.substring(0,n)),e&&(t.pathname=e)}return t}function Xe(e,t,r,n={}){let{window:a=document.defaultView,v5Compat:o=!1}=n,l=a.history,u="POP",s=null,c=f();c==null&&(c=0,l.replaceState({...l.state,idx:c},""));function f(){return(l.state||{idx:null}).idx}function h(){u="POP";let d=f(),v=d==null?null:d-c;c=d,s&&s({action:u,location:p.location,delta:v})}function m(d,v){u="PUSH";let R=ye(d)?d:re(p.location,d,v);c=f()+1;let E=ve(R,c),C=p.createHref(R.mask||R);try{l.pushState(E,"",C)}catch(x){if(x instanceof DOMException&&x.name==="DataCloneError")throw x;a.location.assign(C)}o&&s&&s({action:u,location:p.location,delta:1})}function g(d,v){u="REPLACE";let R=ye(d)?d:re(p.location,d,v);c=f();let E=ve(R,c),C=p.createHref(R.mask||R);l.replaceState(E,"",C),o&&s&&s({action:u,location:p.location,delta:0})}function y(d){return Qe(a,d)}let p={get action(){return u},get location(){return e(a,l)},listen(d){if(s)throw new Error("A history only accepts one active listener");return a.addEventListener(ge,h),s=d,()=>{a.removeEventListener(ge,h),s=null}},createHref(d){return t(a,d)},createURL:y,encodeLocation(d){let v=y(d);return{pathname:v.pathname,search:v.search,hash:v.hash}},push:m,replace:g,go(d){return l.go(d)}};return p}function Qe(e,t,r=!1){let n="http://localhost";e&&(n=e.location.origin!=="null"?e.location.origin:e.location.href),w(n,"No window.location.(origin|href) available to create URL");let a=typeof t=="string"?t:F(t);return a=a.replace(/ $/,"%20"),!r&&Se.test(a)&&(a=n+a),new URL(a,n)}function be(e,t,r="/"){return Ze(e,t,r,!1)}function Ze(e,t,r,n,a){let o=typeof t=="string"?U(t):t,l=$(o.pathname||"/",r);if(l==null)return null;let u=et(e),s=null,c=ft(l);for(let f=0;s==null&&f<u.length;++f)s=ct(u[f],c,n);return s}function et(e){let t=Le(e);return tt(t),t}function Le(e,t=[],r=[],n="",a=!1){let o=(l,u,s=a,c)=>{let f={relativePath:c===void 0?l.path||"":c,caseSensitive:l.caseSensitive===!0,childrenIndex:u,route:l};if(f.relativePath.startsWith("/")){if(!f.relativePath.startsWith(n)&&s)return;w(f.relativePath.startsWith(n),`Absolute route path "${f.relativePath}" nested under path "${n}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),f.relativePath=f.relativePath.slice(n.length)}let h=b([n,f.relativePath]),m=r.concat(f);l.children&&l.children.length>0&&(w(l.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${h}".`),Le(l.children,t,m,h,s)),!(l.path==null&&!l.index)&&t.push({path:h,score:st(h,l.index),routesMeta:m.map((g,y)=>{let[p,d]=$e(g.relativePath,g.caseSensitive,y===m.length-1);return{...g,matcher:p,compiledParams:d}})})};return e.forEach((l,u)=>{if(l.path===""||!l.path?.includes("?"))o(l,u);else for(let s of Pe(l.path))o(l,u,!0,s)}),t}function Pe(e){let t=e.split("/");if(t.length===0)return[];let[r,...n]=t,a=r.endsWith("?"),o=r.replace(/\?$/,"");if(n.length===0)return a?[o,""]:[o];let l=Pe(n.join("/")),u=[];return u.push(...l.map(s=>s===""?o:[o,s].join("/"))),a&&u.push(...l),u.map(s=>e.startsWith("/")&&s===""?"/":s)}function tt(e){e.sort((t,r)=>t.score!==r.score?r.score-t.score:ut(t.routesMeta.map(n=>n.childrenIndex),r.routesMeta.map(n=>n.childrenIndex)))}var rt=/^:[\w-]+$/,nt=3,at=2,ot=1,lt=10,it=-2,Re=e=>e==="*";function st(e,t){let r=e.split("/"),n=r.length;return r.some(Re)&&(n+=it),t&&(n+=at),r.filter(a=>!Re(a)).reduce((a,o)=>a+(rt.test(o)?nt:o===""?ot:lt),n)}function ut(e,t){return e.length===t.length&&e.slice(0,-1).every((n,a)=>n===t[a])?e[e.length-1]-t[t.length-1]:0}function ct(e,t,r=!1){let{routesMeta:n}=e,a={},o="/",l=[];for(let u=0;u<n.length;++u){let s=n[u],c=u===n.length-1,f=o==="/"?t:t.slice(o.length)||"/",h={path:s.relativePath,caseSensitive:s.caseSensitive,end:c},m=s.matcher&&s.compiledParams?ke(h,f,s.matcher,s.compiledParams):J(h,f),g=s.route;if(!m&&c&&r&&!n[n.length-1].route.index&&(m=J({path:s.relativePath,caseSensitive:s.caseSensitive,end:!1},f)),!m)return null;
1Object.assign(a,m.params),l.push({params:a,pathname:b([o,m.pathname]),pathnameBase:mt(b([o,m.pathnameBase])),route:g}),m.pathnameBase!=="/"&&(o=b([o,m.pathnameBase]))}return l}function J(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[r,n]=$e(e.path,e.caseSensitive,e.end);return ke(e,t,r,n)}function ke(e,t,r,n){let a=t.match(r);if(!a)return null;let o=a[0],l=O(o,1),u=a.slice(1);return{params:n.reduce((c,{paramName:f,isOptional:h},m)=>{if(f==="*"){let y=u[m]||"";l=O(o.slice(0,o.length-y.length),1)}const g=u[m];return h&&!g?c[f]=void 0:c[f]=(g||"").replace(/%2F/g,"/"),c},{}),pathname:o,pathnameBase:l,pattern:e}}function $e(e,t=!1,r=!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 n=[],a="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(l,u,s,c,f)=>{if(n.push({paramName:u,isOptional:s!=null}),s){let h=f.charAt(c+l.length);return h&&h!=="/"?"/([^\\/]*)":"(?:/([^\\/]*))?"}return"/([^\\/]+)"}).replace(/\/([\w-]+)\?(\/|$)/g,"(/$1)?$2");return e.endsWith("*")?(n.push({paramName:"*"}),a+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):r?a+="\\/*$":e!==""&&e!=="/"&&(a+="(?:(?=\\/|$))"),[new RegExp(a,t?void 0:"i"),n]}function ft(e){try{return e.split("/").map(t=>decodeURIComponent(t).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 r=t.endsWith("/")?t.length-1:t.length,n=e.charAt(r);return n&&n!=="/"?null:e.slice(r)||"/"}function ht(e,t="/"){let{pathname:r,search:n="",hash:a=""}=typeof e=="string"?U(e):e,o;return r?(r=Te(r),r.startsWith("/")||r.startsWith("\\")?o=Ee(r.substring(1),"/"):o=Ee(r,t)):o=t,{pathname:o,search:pt(n),hash:gt(a)}}function Ee(e,t){let r=O(t).split("/");return e.split("/").forEach(a=>{a===".."?r.length>1&&r.pop():a!=="."&&r.push(a)}),r.length>1?r.join("/"):"/"}function Q(e,t,r,n){return`Cannot include a '${e}' character in a manually specified \`to.${t}\` field [${JSON.stringify(n)}].  Please separate it out to the \`to.${r}\` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.`}function dt(e){return e.filter((t,r)=>r===0||t.route.path&&t.route.path.length>0)}function oe(e){let t=dt(e);return t.map((r,n)=>n===t.length-1?r.pathname:r.pathnameBase)}function K(e,t,r,n=!1){let a;typeof e=="string"?a=U(e):(a={...e},w(!a.pathname||!a.pathname.includes("?"),Q("?","pathname","search",a)),w(!a.pathname||!a.pathname.includes("#"),Q("#","pathname","hash",a)),w(!a.search||!a.search.includes("#"),Q("#","search","hash",a)));let o=e===""||a.pathname==="",l=o?"/":a.pathname,u;if(l==null)u=r;else{let h=t.length-1;if(!n&&l.startsWith("..")){let m=l.split("/");for(;m[0]==="..";)m.shift(),h-=1;a.pathname=m.join("/")}u=h>=0?t[h]:"/"}let s=ht(a,u),c=l&&l!=="/"&&l.endsWith("/"),f=(o||l===".")&&r.endsWith("/");return!s.pathname.endsWith("/")&&(c||f)&&(s.pathname+="/"),s}var Te=e=>e.replace(/[\\/]{2,}/g,"/"),b=e=>Te(e.join("/"));function O(e,t=0){let r=e.length;for(;r>t&&e.charCodeAt(r-1)===47;)r--;return r===e.length?e:e.slice(0,r)}var mt=e=>O(e).replace(/^\/*/,"/"),pt=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,gt=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e,yt=class{constructor(e,t,r,n=!1){this.status=e,this.statusText=t||"",this.internal=n,r instanceof Error?(this.data=r.toString(),this.error=r):this.data=r}};function vt(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}function Rt(e){let t=e.map(r=>r.route.path).filter(Boolean);return b(t)||"/"}var Ne=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function De(e,t){let r=e;if(typeof r!="string"||!ae.test(r))return{absoluteURL:void 0,isExternal:!1,to:r};let n=r,a=!1;if(Ne)try{let o=new URL(window.location.href),l=Se.test(r)?new URL(qe(r,o.protocol)):new URL(r),u=$(l.pathname,t);l.origin===o.origin&&u!=null?r=u+l.search+l.hash:a=!0}catch{L(!1,`<Link to="${r}">
1 contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}return{absoluteURL:n,isExternal:a,to:r}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");var we=new URL("http://localhost");function le(e){if(e.createURL)return e.createURL("/");try{return new URL(e.createHref("/"),we)}catch{return we}}function Z(e,t){return e.origin===t.origin&&(e.origin!=="null"||e.protocol===t.protocol&&e.host===t.host)}function Et(e,t){if(e.startsWith("//"))return!0;let r=t.protocol.toLowerCase();return e.toLowerCase().startsWith(r)?t.host===""||e.slice(r.length).startsWith("//"):!1}function ie(e,t,r,n){let a=null;try{a=e==null?null:new URL(e,r)}catch{}let o=new URL(t,r),l=a!=null&&!Z(a,r),u=!Z(o,r);if(n==="reject"){if(l||u)throw new Error("External navigation is not allowed")}else if(u&&(a==null||!Et(e,a)||!Z(a,o)))throw new Error("External navigation is not allowed")}var Fe=["POST","PUT","PATCH","DELETE"];new Set(Fe);var wt=["GET",...Fe];new Set(wt);var xt=["about:","blob:","chrome:","chrome-untrusted:","content:","data:","devtools:","file:","filesystem:","javascript:"];function Ct(e){try{return xt.includes(new URL(e).protocol)}catch{return!1}}var M=i.createContext(null);M.displayName="DataRouter";var q=i.createContext(null);q.displayName="DataRouterState";var Ie=i.createContext(!1);function St(){return i.useContext(Ie)}var Oe=i.createContext({isTransitioning:!1});Oe.displayName="ViewTransition";var bt=i.createContext(new Map);bt.displayName="Fetchers";var Lt=i.createContext(null);Lt.displayName="Await";var S=i.createContext(null);S.displayName="Navigation";var W=i.createContext(null);W.displayName="Location";var P=i.createContext({outlet:null,matches:[],isDataRoute:!1});P.displayName="Route";var se=i.createContext(null);se.displayName="RouteError";var Ue="REACT_ROUTER_ERROR",Pt="REDIRECT",kt="ROUTE_ERROR_RESPONSE";function $t(e){if(e.startsWith(`${Ue}:${Pt}:{`))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 Tt(e){if(e.startsWith(`${Ue}:${kt}:{`))try{let t=JSON.parse(e.slice(40));if(typeof t=="object"&&t&&typeof t.status=="number"&&typeof t.statusText=="string")return new yt(t.status,t.statusText,t.data)}catch{}}function Nt(e,{relative:t}={}){w(A(),"useHref() may be used only in the context of a <Router> component.");let{basename:r,navigator:n}=i.useContext(S),{hash:a,pathname:o,search:l}=H(e,{relative:t}),u=o;return r!=="/"&&(u=o==="/"?r:b([r,o])),n.createHref({pathname:u,search:l,hash:a})}function A(){return i.useContext(W)!=null}function k(){return w(A(),"useLocation() may be used only in the context of a <Router> component."),i.useContext(W).location}var Me="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function Ae(e){i.useContext(S).static||i.useLayoutEffect(e)}function Be(){let{isDataRoute:e}=i.useContext(P);return e?Vt():Dt()}function Dt(){w(A(),"useNavigate() may be used only in the context of a <Router> component.");let e=i.useContext(M),{basename:t,navigator:r}=i.useContext(S),{matches:n}=i.useContext(P),{pathname:a}=k(),o=JSON.stringify(oe(n)),l=i.useRef(!1);return Ae(()=>{l.current=!0}),i.useCallback((s,c={})=>{if(L(l.current,Me),!l.current)return;if(typeof s=="number"){r.go(s);return}let f=K(s,JSON.parse(o),a,c.relative==="path");e==null&&t!=="/"&&(f.pathname=f.pathname==="/"?t:b([t,f.pathname])),ie(typeof s=="string"?s:F(s),r.createHref(f),le(r),"reject"),(c.replace?r.replace:r.push)(f,c.state,c)},[t,r,o,a,e])}i.createContext(null);function Pr(){let{matches:e}=i.useContext(P);return e[e.length-1]?.params??{}}function H(e,{relative:t}={}){let{matches:r}=i.useContext(P),{pathname:n}=k(),a=JSON.stringify(oe(r));return i.useMemo(()=>K(e,JSON.parse(a),n,t==="path"),[e,a,n,t])}function Ft(e,t){return _e(e,t)}function _e(e,t,r){w(A(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:n}=i.useContext(S),{matches:a}=i.useContext(P),o=a[a.length-1],l=o?o.params:{},u=o?o.pathname:"/",s=o?o.pathnameBase:"/",c=o&&o.route;{let d=c&&c.path||"";He(u,!c||d.endsWith("*")||d.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${u}" (under <Route path="${d}">) 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
3Please change the parent <Route path="${d}"> to <Route path="${d==="/"?"*":`${d}/*`}">.`)}let f=k(),h;if(t){let d=typeof t=="string"?U(t):t;w(s==="/"||d.pathname?.startsWith(s),`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 "${s}" but pathname "${d.pathname}" was given in the \`location\` prop.`),h=d}else h=f;let m=h.pathname||"/",g=m;if(s!=="/"){let d=s.replace(/^\//,"").split("/");g="/"+m.replace(/^\//,"").split("/").slice(d.length).join("/")}let y=r&&r.state.matches.length?r.state.matches.map(d=>Object.assign(d,{route:r.manifest[d.route.id]||d.route})):be(e,{pathname:g});L(c||y!=null,`No routes matched location "${h.pathname}${h.search}${h.hash}" `),L(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 <Outlet /> with a null value by default resulting in an "empty" page.`);let p=At(y&&y.map(d=>Object.assign({},d,{params:Object.assign({},l,d.params),pathname:b([s,n.encodeLocation?n.encodeLocation(d.pathname.replace(/%/g,"%25").replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:d.pathname]),pathnameBase:d.pathnameBase==="/"?s:b([s,n.encodeLocation?n.encodeLocation(d.pathnameBase.replace(/%/g,"%25").replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:d.pathnameBase])})),a,r);return t&&p?i.createElement(W.Provider,{value:{location:{pathname:"/",search:"",hash:"",state:null,key:"default",mask:void 0,...h},navigationType:"POP"}},p):p}function It(){let e=jt(),t=vt(e)?`${e.status} ${e.statusText}`:e instanceof Error?e.message:JSON.stringify(e),r=e instanceof Error?e.stack:null,n="rgba(200,200,200, 0.5)",a={padding:"0.5rem",backgroundColor:n},o={padding:"2px 4px",backgroundColor:n},l=null;return console.error("Error handled by React Router default ErrorBoundary:",e),l=i.createElement(i.Fragment,null,i.createElement("p",null,"💿 Hey developer 👋"),i.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",i.createElement("code",{style:o},"ErrorBoundary")," or"," ",i.createElement("code",{style:o},"errorElement")," prop on your route.")),i.createElement(i.Fragment,null,i.createElement("h2",null,"Unexpected Application 
3Error!"),i.createElement("h3",{style:{fontStyle:"italic"}},t),r?i.createElement("pre",{style:a},r):null,l)}var Ot=i.createElement(It,null),We=class extends i.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 r=Tt(e.digest);r&&(e=r)}let t=e!==void 0?i.createElement(P.Provider,{value:this.props.routeContext},i.createElement(se.Provider,{value:e,children:this.props.component})):this.props.children;return this.context?i.createElement(Ut,{error:e},t):t}};We.contextType=Ie;var ee=new WeakMap;function Ut({children:e,error:t}){let{basename:r,navigator:n}=i.useContext(S);if(typeof t=="object"&&t&&"digest"in t&&typeof t.digest=="string"){let a=$t(t.digest);if(a){let o=ee.get(t);if(o)throw o;let l=De(a.location,r),u=l.absoluteURL||l.to;if(ie(a.location,u,le(n),"allow-explicit"),Ct(u))throw new Error("Invalid redirect location");if(Ne&&!ee.get(t))if(l.isExternal||a.reloadDocument)window.location.href=u;else{const s=Promise.resolve().then(()=>window.__reactRouterDataRouter.navigate(l.to,{replace:a.replace}));throw ee.set(t,s),s}return i.createElement("meta",{httpEquiv:"refresh",content:`0;url=${u}`})}}return e}function Mt({routeContext:e,match:t,children:r}){let n=i.useContext(M);return n&&n.static&&n.staticContext&&(t.route.errorElement||t.route.ErrorBoundary)&&(n.staticContext._deepestRenderedBoundaryId=t.route.id),i.createElement(P.Provider,{value:e},r)}function At(e,t=[],r){let n=r?.state;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 a=e,o=n?.errors;if(o!=null){let f=a.findIndex(h=>h.route.id&&o?.[h.route.id]!==void 0);w(f>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(o).join(",")}`),a=a.slice(0,Math.min(a.length,f+1))}let l=!1,u=-1;if(r&&n){l=n.renderFallback;for(let f=0;f<a.length;f++){let h=a[f];if((h.route.HydrateFallback||h.route.hydrateFallbackElement)&&(u=f),h.route.id){let{loaderData:m,errors:g}=n,y=h.route.loader&&!m.hasOwnProperty(h.route.id)&&(!g||g[h.route.id]===void 0);if(h.route.lazy||y){r.isStatic&&(l=!0),u>=0?a=a.slice(0,u+1):a=[a[0]];break}}}}let s=r?.onError,c=n&&s?(f,h)=>{s(f,{location:n.location,params:n.matches?.[0]?.params??{},pattern:Rt(n.matches),errorInfo:h})}:void 0;return a.reduceRight((f,h,m)=>{let g,y=!1,p=null,d=null;n&&(g=o&&h.route.id?o[h.route.id]:void 0,p=h.route.errorElement||Ot,l&&(u<0&&m===0?(He("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),y=!0,d=null):u===m&&(y=!0,d=h.route.hydrateFallbackElement||null)));let v=t.concat(a.slice(0,m+1)),R=()=>{let E;
3return g?E=p:y?E=d:h.route.Component?E=i.createElement(h.route.Component,null):h.route.element?E=h.route.element:E=f,i.createElement(Mt,{match:h,routeContext:{outlet:f,matches:v,isDataRoute:n!=null},children:E})};return n&&(h.route.ErrorBoundary||h.route.errorElement||m===0)?i.createElement(We,{location:n.location,revalidation:n.revalidation,component:p,error:g,children:R(),routeContext:{outlet:null,matches:v,isDataRoute:!0},onError:c}):R()},null)}function ue(e){return`${e} must be used within a data router.  See https://reactrouter.com/en/main/routers/picking-a-router.`}function Bt(e){let t=i.useContext(M);return w(t,ue(e)),t}function _t(e){let t=i.useContext(q);return w(t,ue(e)),t}function Wt(e){let t=i.useContext(P);return w(t,ue(e)),t}function ce(e){let t=Wt(e),r=t.matches[t.matches.length-1];return w(r.route.id,`${e} can only be used on routes that contain a unique "id"`),r.route.id}function Ht(){return ce("useRouteId")}function jt(){let e=i.useContext(se),t=_t("useRouteError"),r=ce("useRouteError");return e!==void 0?e:t.errors?.[r]}function Vt(){let{router:e}=Bt("useNavigate"),t=ce("useNavigate"),r=i.useRef(!1);return Ae(()=>{r.current=!0}),i.useCallback(async(a,o={})=>{L(r.current,Me),r.current&&(typeof a=="number"?await e.navigate(a):await e.navigate(a,{fromRouteId:t,...o}))},[e,t])}var xe={};function He(e,t,r){!t&&!xe[e]&&(xe[e]=!0,L(!1,r))}i.memo(zt);function zt({routes:e,manifest:t,future:r,state:n,isStatic:a,onError:o}){return _e(e,void 0,{manifest:t,state:n,isStatic:a,onError:o})}function kr({to:e,replace:t,state:r,relative:n}){w(A(),"<Navigate> may be used only in the context of a <Router> component.");let{static:a,navigator:o}=i.useContext(S);L(!a,"<Navigate> must not be used on the initial render in a <StaticRouter>. This is a no-op, but you should modify your code so the <Navigate> is only ever rendered in response to some user interaction or state change.");let{matches:l}=i.useContext(P),{pathname:u}=k(),s=Be(),c=K(e,oe(l),u,n==="path");ie(typeof e=="string"?e:F(e),o.createHref(c),le(o),"reject");let f=JSON.stringify(c);return i.useEffect(()=>{s(JSON.parse(f),{replace:t,state:r,relative:n})},[s,f,n,t,r]),null}function Jt(e){w(!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 Kt({basename:e="/",children:t=null,location:r,navigationType:n="POP",navigator:a,static:o=!1,useTransitions:l}){w(!A(),"You cannot render a <Router> inside another <Router>. You should never have more than one in your app.");let u=e.replace(/^\/*/,"/"),s=i.useMemo(()=>({basename:u,navigator:a,static:o,useTransitions:l,future:{}}),[u,a,o,l]);typeof r=="string"&&(r=U(r));let{pathname:c="/",search:f="",hash:h="",state:m=null,key:g="default",mask:y}=r,p=i.useMemo(()=>{let d=$(c,u);return d==null?null:{location:{pathname:d,search:f,hash:h,state:m,key:g,mask:y},navigationType:n}},[u,c,f,h,m,g,n,y]);return L(p!=null,`<Router basename="${u}"> is not able to match the URL "${c}${f}${h}" because it does not start with the basename, so the <Router> won't render anything.`),p==null?null:i.createElement(S.Provider,{value:s},i.createElement(W.Provider,{children:t,value:p}))}function $r({children:e,location:t}){return Ft(ne(e),t)}function ne(e,t=[]){let r=[];return i.Children.forEach(e,(n,a)=>{if(!i.isValidElement(n))return;let o=[...t,a];if(n.type===i.Fragment){r.push.apply(r,ne(n.props.children,o));return}w(n.type===Jt,`[${typeof n.type=="string"?n.type:n.type.name}] is not a <Route> component. All component children of <Routes> must be a <Route> or <React.Fragment>`),w(!n.props.index||!n.props.children,"An index route cannot have child routes.");let l={id:n.props.id||o.join("-"),caseSensitive:n.props.caseSensitive,element:n.props.element,Component:n.props.Component,index:n.props.index,path:n.props.path,middleware:n.props.middleware,loader:n.props.loader,action:n.props.action,hydrateFallbackElement:n.props.hydrateFallbackElement,HydrateFallback:n.props.HydrateFallback,errorElement:n.props.errorElement,ErrorBoundary:n.props.ErrorBoundary,hasErrorBoundary:n.props.hasErrorBoundary===!0||n.props.ErrorBoundary!=null||n.props.errorElement!=null,
3shouldRevalidate:n.props.shouldRevalidate,handle:n.props.handle,lazy:n.props.lazy};n.props.children&&(l.children=ne(n.props.children,o)),r.push(l)}),r}var V="get",z="application/x-www-form-urlencoded";function G(e){return typeof HTMLElement<"u"&&e instanceof HTMLElement}function qt(e){return G(e)&&e.tagName.toLowerCase()==="button"}function Gt(e){return G(e)&&e.tagName.toLowerCase()==="form"}function Yt(e){return G(e)&&e.tagName.toLowerCase()==="input"}function Xt(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function Qt(e,t){return e.button===0&&(!t||t==="_self")&&!Xt(e)}var j=null;function Zt(){if(j===null)try{new FormData(document.createElement("form"),0),j=!1}catch{j=!0}return j}var er=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function te(e){return e!=null&&!er.has(e)?(L(!1,`"${e}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${z}"`),null):e}function tr(e,t){let r,n,a,o,l;if(Gt(e)){let u=e.getAttribute("action");n=u?$(u,t):null,r=e.getAttribute("method")||V,a=te(e.getAttribute("enctype"))||z,o=new FormData(e)}else if(qt(e)||Yt(e)&&(e.type==="submit"||e.type==="image")){let u=e.form;if(u==null)throw new Error('Cannot submit a <button> or <input type="submit"> without a <form>');let s=e.getAttribute("formaction")||u.getAttribute("action");if(n=s?$(s,t):null,r=e.getAttribute("formmethod")||u.getAttribute("method")||V,a=te(e.getAttribute("formenctype"))||te(u.getAttribute("enctype"))||z,o=new FormData(u,e),!Zt()){let{name:c,type:f,value:h}=e;if(f==="image"){let m=c?`${c}.`:"";o.append(`${m}x`,"0"),o.append(`${m}y`,"0")}else c&&o.append(c,h)}}else{if(G(e))throw new Error('Cannot submit element that is not <form>, <button>, or <input type="submit|image">');r=V,n=null,a=z,l=e}return o&&a==="text/plain"&&(l=o,o=void 0),{action:n,method:r.toLowerCase(),encType:a,formData:o,body:l}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");function fe(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function je(e,t,r,n){let a=typeof e=="string"?new URL(e,typeof window>"u"?"server://singlefetch/":window.location.origin):e;return r?a.pathname.endsWith("/")?a.pathname=`${a.pathname}_.${n}`:a.pathname=`${a.pathname}.${n}`:a.pathname==="/"?a.pathname=`_root.${n}`:t&&$(a.pathname,t)==="/"?a.pathname=`${O(t)}/_root.${n}`:a.pathname=`${O(a.pathname)}.${n}`,a}async function rr(e,t){if(e.id in t)return t[e.id];try{let r=await import(e.module);return t[e.id]=r,r}catch(r){return console.error(`Error loading route module \`${e.module}\`, reloading page...`),console.error(r),window.__reactRouterContext&&window.__reactRouterContext.isSpaMode,window.location.reload(),new Promise(()=>{})}}function nr(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 ar(e,t,r){let n=await Promise.all(e.map(async a=>{let o=t.routes[a.route.id];if(o){let l=await rr(o,r);return l.links?l.links():[]}return[]}));return sr(n.flat(1).filter(nr).filter(a=>a.rel==="stylesheet"||a.rel==="preload").map(a=>a.rel==="stylesheet"?{...a,rel:"prefetch",as:"style"}:{...a,rel:"prefetch"}))}function Ce(e,t,r,n,a,o){let l=(s,c)=>r[c]?s.route.id!==r[c].route.id:!0,u=(s,c)=>r[c].pathname!==s.pathname||r[c].route.path?.endsWith("*")&&r[c].params["*"]!==s.params["*"];return o==="assets"?t.filter((s,c)=>l(s,c)||u(s,c)):o==="data"?t.filter((s,c)=>{let f=n.routes[s.route.id];if(!f||!f.hasLoader)return!1;if(l(s,c)||u(s,c))return!0;if(s.route.shouldRevalidate){let h=s.route.shouldRevalidate({currentUrl:new URL(a.pathname+a.search+a.hash,window.origin),currentParams:r[0]?.params||{},nextUrl:new URL(e,window.origin),nextParams:s.params,defaultShouldRevalidate:!0});if(typeof h=="boolean")return h}return!0}):[]}function or(e,t,{includeHydrateFallback:r}={}){return lr(e.map(n=>{let a=t.routes[n.route.id];if(!a)return[];let o=[a.module];return a.clientActionModule&&(o=o.concat(a.clientActionModule)),a.clientLoaderModule&&(o=o.concat(a.clientLoaderModule)),r&&a.hydrateFallbackModule&&(o=o.concat(a.hydrateFallbackModule)),a.imports&&(o=o.c
3oncat(a.imports)),o}).flat(1))}function lr(e){return[...new Set(e)]}function ir(e){let t={},r=Object.keys(e).sort();for(let n of r)t[n]=e[n];return t}function sr(e,t){let r=new Set;return new Set(t),e.reduce((n,a)=>{let o=JSON.stringify(ir(a));return r.has(o)||(r.add(o),n.push({key:o,link:a})),n},[])}function he(){let e=i.useContext(M);return fe(e,"You must render this element inside a <DataRouterContext.Provider> element"),e}function ur(){let e=i.useContext(q);return fe(e,"You must render this element inside a <DataRouterStateContext.Provider> element"),e}var de=i.createContext(void 0);de.displayName="FrameworkContext";function Y(){let e=i.useContext(de);return fe(e,"You must render this element inside a <HydratedRouter> element"),e}function cr(e,t){let r=i.useContext(de),[n,a]=i.useState(!1),[o,l]=i.useState(!1),{onFocus:u,onBlur:s,onMouseEnter:c,onMouseLeave:f,onTouchStart:h}=t,m=i.useRef(null);i.useEffect(()=>{if(e==="render"&&l(!0),e==="viewport"){let p=v=>{v.forEach(R=>{l(R.isIntersecting)})},d=new IntersectionObserver(p,{threshold:.5});return m.current&&d.observe(m.current),()=>{d.disconnect()}}},[e]),i.useEffect(()=>{if(n){let p=setTimeout(()=>{l(!0)},100);return()=>{clearTimeout(p)}}},[n]);let g=()=>{a(!0)},y=()=>{a(!1),l(!1)};return r?e!=="intent"?[o,m,{}]:[o,m,{onFocus:_(u,g),onBlur:_(s,y),onMouseEnter:_(c,g),onMouseLeave:_(f,y),onTouchStart:_(h,g)}]:[!1,m,{}]}function _(e,t){return r=>{e&&e(r),r.defaultPrevented||t(r)}}function fr({page:e,...t}){let r=St(),{nonce:n}=Y(),{router:a}=he(),o=i.useMemo(()=>be(a.routes,e,a.basename),[a.routes,e,a.basename]);return o?(t.nonce==null&&n&&(t={...t,nonce:n}),r?i.createElement(dr,{page:e,matches:o,...t}):i.createElement(mr,{page:e,matches:o,...t})):null}function hr(e){let{manifest:t,routeModules:r}=Y(),[n,a]=i.useState([]);return i.useEffect(()=>{let o=!1;return ar(e,t,r).then(l=>{o||a(l)}),()=>{o=!0}},[e,t,r]),n}function dr({page:e,matches:t,...r}){let n=k(),{future:a}=Y(),{basename:o}=he(),l=i.useMemo(()=>{if(e===n.pathname+n.search+n.hash)return[];let u=je(e,o,a.v8_trailingSlashAwareDataRequests,"rsc"),s=!1,c=[];for(let f of t)typeof f.route.shouldRevalidate=="function"?s=!0:c.push(f.route.id);return s&&c.length>0&&u.searchParams.set("_routes",c.join(",")),[u.pathname+u.search]},[o,a.v8_trailingSlashAwareDataRequests,e,n,t]);return i.createElement(i.Fragment,null,l.map(u=>i.createElement("link",{key:u,rel:"prefetch",as:"fetch",href:u,...r})))}function mr({page:e,matches:t,...r}){let n=k(),{future:a,manifest:o,routeModules:l}=Y(),{basename:u}=he(),{loaderData:s,matches:c}=ur(),f=i.useMemo(()=>Ce(e,t,c,o,n,"data"),[e,t,c,o,n]),h=i.useMemo(()=>Ce(e,t,c,o,n,"assets"),[e,t,c,o,n]),m=i.useMemo(()=>{if(e===n.pathname+n.search+n.hash)return[];let p=new Set,d=!1;if(t.forEach(R=>{let E=o.routes[R.route.id];!E||!E.hasLoader||(!f.some(C=>C.route.id===R.route.id)&&R.route.id in s&&l[R.route.id]?.shouldRevalidate||E.hasClientLoader?d=!0:p.add(R.route.id))}),p.size===0)return[];let v=je(e,u,a.v8_trailingSlashAwareDataRequests,"data");return d&&p.size>0&&v.searchParams.set("_routes",t.filter(R=>p.has(R.route.id)).map(R=>R.route.id).join(",")),[v.pathname+v.search]},[u,a.v8_trailingSlashAwareDataRequests,s,n,o,f,t,e,l]),g=i.useMemo(()=>or(h,o),[h,o]),y=hr(h);return i.createElement(i.Fragment,null,m.map(p=>i.createElement("link",{key:p,rel:"prefetch",as:"fetch",href:p,...r})),g.map(p=>i.createElement("link",{key:p,rel:"modulepreload",href:p,...r})),y.map(({key:p,link:d})=>i.createElement("link",{key:p,nonce:r.nonce,...d,crossOrigin:d.crossOrigin??r.crossOrigin})))}function pr(...e){return t=>{e.forEach(r=>{typeof r=="function"?r(t):r!=null&&(r.current=t)})}}var gr=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";try{gr&&(window.__reactRouterVersion="7.18.3")}catch{}function Tr({basename:e,children:t,useTransitions:r,window:n}){let a=i.useRef();a.current==null&&(a.current=Ge({window:n,v5Compat:!0}));let o=a.current,[l,u]=i.useState({action:o.action,location:o.location}),s=i.useCallback(c=>{r===!1?u(c):i.startTransition(()=>u(c))},[r]);return i.useLayoutEffect(()=>o.listen(s),[o,s]),i.createElement(Kt,{basename:e,children:t,location:l.location,navigationType:l.action,navigator:o,useTransitions:r})}var Ve=i.forwardRef(function({onClick:t,discover:r="render",prefetch:n="none",relative:a,reloadDocument:o,replace:l,mask:u,state:s,target:c,to:f,preventScrollReset:h,viewTransition:m,defaultShouldRevalidate:g,...y},p){let{basename:d,navigator:v,useTransitions:R}=i.useContext(S),E=typeof f=="string"&&ae.test(f),C=De(f,d);f=C.to;let x=Nt(f,{relative:a}),T=k(),N=null;if(u){let D=K(u,[],T.mask?T.mask.pathname:"/",!0);d!=="/"&&(D.pathname=D.pathname==="/"?d:b([d,D.pathname])),N=v.createHref(
vendor: 1,818 bytes, line 3
3D)}let[I,B,X]=cr(n,y),Je=Er(f,{replace:l,mask:u,state:s,target:c,preventScrollReset:h,relative:a,viewTransition:m,defaultShouldRevalidate:g,useTransitions:R});function Ke(D){t&&t(D),D.defaultPrevented||Je(D)}let me=!(C.isExternal||o),pe=i.createElement("a",{...y,...X,href:(me?N:void 0)||C.absoluteURL||x,onClick:me?Ke:t,ref:pr(p,B),target:c,"data-discover":!E&&r==="render"?"true":void 0});return I&&!E?i.createElement(i.Fragment,null,pe,i.createElement(fr,{page:x})):pe});Ve.displayName="Link";var yr=i.forwardRef(function({"aria-current":t="page",caseSensitive:r=!1,className:n="",end:a=!1,style:o,to:l,viewTransition:u,children:s,...c},f){let h=H(l,{relative:c.relative}),m=k(),g=i.useContext(q),{navigator:y,basename:p}=i.useContext(S),d=g!=null&&br(h)&&u===!0,v=y.encodeLocation?y.encodeLocation(h).pathname:h.pathname,R=m.pathname,E=g&&g.navigation&&g.navigation.location?g.navigation.location.pathname:null;r||(R=R.toLowerCase(),E=E?E.toLowerCase():null,v=v.toLowerCase()),E&&p&&(E=$(E,p)||E);const C=v!=="/"&&v.endsWith("/")?v.length-1:v.length;let x=R===v||!a&&R.startsWith(v)&&R.charAt(C)==="/",T=E!=null&&(E===v||!a&&E.startsWith(v)&&E.charAt(v.length)==="/"),N={isActive:x,isPending:T,isTransitioning:d},I=x?t:void 0,B;typeof n=="function"?B=n(N):B=[n,x?"active":null,T?"pending":null,d?"transitioning":null].filter(Boolean).join(" ");let X=typeof o=="function"?o(N):o;return i.createElement(Ve,{...c,"aria-current":I,className:B,ref:f,style:X,to:l,viewTransition:u},typeof s=="function"?s(N):s)});yr.displayName="NavLink";var vr=i.forwardRef(({discover:e="render",fetcherKey:t,navigate:r,reloadDocument:n,replace:a,state:o,method:l=V,action:u,onSubmit:s,relative:c,preventScrollReset:f,viewTransition:h,defaultShouldRevalidate:m,...g},y)=>{let{useTransitions:p}=i.useContext(S),d=Cr(),v=Sr(u,{relative:c}
3),R=l.toLowerCase()==="get"?"get":"post",E=typeof u=="string"&&ae.test(u),C=x=>{if(s&&s(x),x.defaultPrevented)return;x.preventDefault();let T=x.nativeEvent.submitter,N=T?.getAttribute("formmethod")||l,I=()=>d(T||x.currentTarget,{fetcherKey:t,method:N,navigate:r,replace:a,state:o,relative:c,preventScrollReset:f,viewTransition:h,defaultShouldRevalidate:m});p&&r!==!1?i.startTransition(()=>I()):I()};return i.createElement("form",{ref:y,method:R,action:v,onSubmit:n?s:C,...g,"data-discover":!E&&e==="render"?"true":void 0})});vr.displayName="Form";function Rr(e){return`${e} must be used within a data router.  See https://reactrouter.com/en/main/routers/picking-a-router.`}function ze(e){let t=i.useContext(M);return w(t,Rr(e)),t}function Er(e,{target:t,replace:r,mask:n,state:a,preventScrollReset:o,relative:l,viewTransition:u,defaultShouldRevalidate:s,useTransitions:c}={}){let f=Be(),h=k(),m=H(e,{relative:l});return i.useCallback(g=>{if(Qt(g,t)){g.preventDefault();let y=r!==void 0?r:F(h)===F(m),p=()=>f(e,{replace:y,mask:n,state:a,preventScrollReset:o,relative:l,viewTransition:u,defaultShouldRevalidate:s});c?i.startTransition(()=>p()):p()}},[h,f,m,r,n,a,t,e,o,l,u,s,c])}var wr=0,xr=()=>`__${String(++wr)}__`;function Cr(){let{router:e}=ze("useSubmit"),{basename:t}=i.useContext(S),r=Ht(),n=e.fetch,a=e.navigate;return i.useCallback(async(o,l={})=>{let{action:u,method:s,encType:c,formData:f,body:h}=tr(o,t);if(l.navigate===!1){let m=l.fetcherKey||xr();await n(m,r,l.action||u,{defaultShouldRevalidate:l.defaultShouldRevalidate,preventScrollReset:l.preventScrollReset,formData:f,body:h,formMethod:l.method||s,formEncType:l.encType||c,flushSync:l.flushSync})}else await a(l.action||u,{defaultShouldRevalidate:l.defaultShouldRevalidate,preventScrollReset:l.preventScrollReset,formData:f,body:h,formMethod:l.method||s,formEncType:l.encType||c,replace:l.replace,state:l.state,fromRouteId:r,flushSync:l.flushSync,viewTransition:l.viewTransition})},[n,a,t,r])}function Sr(e,{relative:t}={}){let{basename:r}=i.useContext(S),n=i.useContext(P);w(n,"useFormAction must be used inside a RouteContext");let[a]=n.matches.slice(-1),o={...H(e||".",{relative:t})},l=k();if(e==null){o.search=l.search;let u=new URLSearchParams(o.search),s=u.getAll("index");if(s.some(f=>f==="")){u.delete("index"),s.filter(h=>h).forEach(h=>u.append("index",h));let f=u.toString();o.search=f?`?${f}`:""}}return(!e||e===".")&&a.route.index&&(o.search=o.search?o.search.replace(/^\?/,"?index&"):"?index"),r!=="/"&&(o.pathname=o.pathname==="/"?r:b([r,o.pathname])),F(o)}function br(e,{relative:t}={}){let r=i.useContext(Oe);w(r!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`.  Did you accidentally import `RouterProvider` from `react-router`?");let{basename:n}=ze("useViewTransitionState"),a=H(e,{relative:t});if(!r.isTransitioning)return!1;let o=$(r.currentLocation.pathname,n)||r.currentLocation.pathname,l=$(r.nextLocation.pathname,n)||r.nextLocation.pathname;return J(a.pathname,l)!=null||J(a.pathname,o)!=null}export{Tr as B,Ve as L,yr as N,$r as R,k as a,Pr as b,kr as c,Jt as d,Be 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.