import{r as e,R as t}from"./vendor-1f283eff.js";
/**
 * @remix-run/router v1.23.2
 *
 * 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
 */function n(){return n=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},n.apply(this,arguments)}var r,a;(a=r||(r={})).Pop="POP",a.Push="PUSH",a.Replace="REPLACE";const o="popstate";function l(e){return void 0===e&&(e={}),function(e,t,a,l){void 0===l&&(l={});let{window:s=document.defaultView,v5Compat:p=!1}=l,d=s.history,f=r.Pop,v=null,m=g();null==m&&(m=0,d.replaceState(n({},d.state,{idx:m}),""));function g(){return(d.state||{idx:null}).idx}function y(){f=r.Pop;let e=g(),t=null==e?null:e-m;m=e,v&&v({action:f,location:w.location,delta:t})}function b(e,t){f=r.Push;let n=c(w.location,e,t);a&&a(n,e),m=g()+1;let o=u(n,m),l=w.createHref(n);try{d.pushState(o,"",l)}catch(i){if(i instanceof DOMException&&"DataCloneError"===i.name)throw i;s.location.assign(l)}p&&v&&v({action:f,location:w.location,delta:1})}function x(e,t){f=r.Replace;let n=c(w.location,e,t);a&&a(n,e),m=g();let o=u(n,m),l=w.createHref(n);d.replaceState(o,"",l),p&&v&&v({action:f,location:w.location,delta:0})}function E(e){let t="null"!==s.location.origin?s.location.origin:s.location.href,n="string"==typeof e?e:h(e);return n=n.replace(/ $/,"%20"),i(t,"No window.location.(origin|href) available to create URL for href: "+n),new URL(n,t)}let w={get action(){return f},get location(){return e(s,d)},listen(e){if(v)throw new Error("A history only accepts one active listener");return s.addEventListener(o,y),v=e,()=>{s.removeEventListener(o,y),v=null}},createHref:e=>t(s,e),createURL:E,encodeLocation(e){let t=E(e);return{pathname:t.pathname,search:t.search,hash:t.hash}},push:b,replace:x,go:e=>d.go(e)};return w}(function(e,t){let{pathname:n,search:r,hash:a}=e.location;return c("",{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:h(t)},null,e)}function i(e,t){if(!1===e||null==e)throw new Error(t)}function s(e,t){if(!e){"undefined"!=typeof console&&console.warn(t);try{throw new Error(t)}catch(n){}}}function u(e,t){return{usr:e.state,key:e.key,idx:t}}function c(e,t,r,a){return void 0===r&&(r=null),n({pathname:"string"==typeof e?e:e.pathname,search:"",hash:""},"string"==typeof t?p(t):t,{state:r,key:t&&t.key||a||Math.random().toString(36).substr(2,8)})}function h(e){let{pathname:t="/",search:n="",hash:r=""}=e;return n&&"?"!==n&&(t+="?"===n.charAt(0)?n:"?"+n),r&&"#"!==r&&(t+="#"===r.charAt(0)?r:"#"+r),t}function p(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substr(n),e=e.substr(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substr(r),e=e.substr(0,r)),e&&(t.pathname=e)}return t}var d,f;function v(e,t,n){return void 0===n&&(n="/"),function(e,t,n,r){let a="string"==typeof t?p(t):t,o=k(a.pathname||"/",n);if(null==o)return null;let l=m(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)))}(l);let i=null;for(let s=0;null==i&&s<l.length;++s){let e=O(o);i=P(l[s],e,r)}return i}(e,t,n,!1)}function m(e,t,n,r){void 0===t&&(t=[]),void 0===n&&(n=[]),void 0===r&&(r="");let a=(e,a,o)=>{let l={relativePath:void 0===o?e.path||"":o,caseSensitive:!0===e.caseSensitive,childrenIndex:a,route:e};l.relativePath.startsWith("/")&&(i(l.relativePath.startsWith(r),'Absolute route path "'+l.relativePath+'" nested under path "'+r+'" is not valid. An absolute child route path must start with the combined path of all its parent routes.'),l.relativePath=l.relativePath.slice(r.length));let s=F([r,l.relativePath]),u=n.concat(l);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 "'+s+'".'),m(e.children,t,u,s)),(null!=e.path||e.index)&&t.push({path:s,score:S(s,e.index),routesMeta:u})};return e.forEach((e,t)=>{var n;if(""!==e.path&&null!=(n=e.path)&&n.includes("?"))for(let r of g(e.path))a(e,t,r);else a(e,t)}),t}function g(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 l=g(r.join("/")),i=[];return i.push(...l.map(e=>""===e?o:[o,e].join("/"))),a&&i.push(...l),i.map(t=>e.startsWith("/")&&""===t?"/":t)}(f=d||(d={})).data="data",f.deferred="deferred",f.redirect="redirect",f.error="error";const y=/^:[\w-]+$/,b=3,x=2,E=1,w=10,C=-2,R=e=>"*"===e;function S(e,t){let n=e.split("/"),r=n.length;return n.some(R)&&(r+=C),t&&(r+=x),n.filter(e=>!R(e)).reduce((e,t)=>e+(y.test(t)?b:""===t?E:w),r)}function P(e,t,n){void 0===n&&(n=!1);let{routesMeta:r}=e,a={},o="/",l=[];for(let i=0;i<r.length;++i){let e=r[i],s=i===r.length-1,u="/"===o?t:t.slice(o.length)||"/",c=U({path:e.relativePath,caseSensitive:e.caseSensitive,end:s},u),h=e.route;if(!c&&s&&n&&!r[r.length-1].route.index&&(c=U({path:e.relativePath,caseSensitive:e.caseSensitive,end:!1},u)),!c)return null;Object.assign(a,c.params),l.push({params:a,pathname:F([o,c.pathname]),pathnameBase:W(F([o,c.pathnameBase])),route:h}),"/"!==c.pathnameBase&&(o=F([o,c.pathnameBase]))}return l}function U(e,t){"string"==typeof e&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=function(e,t,n){void 0===t&&(t=!1);void 0===n&&(n=!0);s("*"===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?"/?([^\\/]+)?":"/([^\\/]+)"));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],l=o.replace(/(.)\/+$/,"$1"),i=a.slice(1);return{params:r.reduce((e,t,n)=>{let{paramName:r,isOptional:a}=t;if("*"===r){let e=i[n]||"";l=o.slice(0,o.length-e.length).replace(/(.)\/+$/,"$1")}const s=i[n];return e[r]=a&&!s?void 0:(s||"").replace(/%2F/g,"/"),e},{}),pathname:o,pathnameBase:l,pattern:e}}function O(e){try{return e.split("/").map(e=>decodeURIComponent(e).replace(/\//g,"%2F")).join("/")}catch(t){return s(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent encoding ('+t+")."),e}}function k(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)||"/"}const L=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i;function B(e,t){void 0===t&&(t="/");let n,{pathname:r,search:a="",hash:o=""}="string"==typeof e?p(e):e;if(r)if(l=r,L.test(l))n=r;else{if(r.includes("//")){let e=r;r=r.replace(/\/\/+/g,"/"),s(!1,"Pathnames cannot have embedded double slashes - normalizing "+e+" -> "+r)}n=r.startsWith("/")?j(r.substring(1),"/"):j(r,t)}else n=t;var l;return{pathname:n,search:$(a),hash:_(o)}}function j(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 N(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 D(e,t){let n=function(e){return e.filter((e,t)=>0===t||e.route.path&&e.route.path.length>0)}(e);return t?n.map((e,t)=>t===n.length-1?e.pathname:e.pathnameBase):n.map(e=>e.pathnameBase)}function T(e,t,r,a){let o;void 0===a&&(a=!1),"string"==typeof e?o=p(e):(o=n({},e),i(!o.pathname||!o.pathname.includes("?"),N("?","pathname","search",o)),i(!o.pathname||!o.pathname.includes("#"),N("#","pathname","hash",o)),i(!o.search||!o.search.includes("#"),N("#","search","hash",o)));let l,s=""===e||""===o.pathname,u=s?"/":o.pathname;if(null==u)l=r;else{let e=t.length-1;if(!a&&u.startsWith("..")){let t=u.split("/");for(;".."===t[0];)t.shift(),e-=1;o.pathname=t.join("/")}l=e>=0?t[e]:"/"}let c=B(o,l),h=u&&"/"!==u&&u.endsWith("/"),d=(s||"."===u)&&r.endsWith("/");return c.pathname.endsWith("/")||!h&&!d||(c.pathname+="/"),c}const F=e=>e.join("/").replace(/\/\/+/g,"/"),W=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),$=e=>e&&"?"!==e?e.startsWith("?")?e:"?"+e:"",_=e=>e&&"#"!==e?e.startsWith("#")?e:"#"+e:"";const M=["post","put","patch","delete"];new Set(M);const A=["get",...M];
/**
 * React Router v6.30.3
 *
 * 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
 */
function z(){return z=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},z.apply(this,arguments)}new Set(A);const I=e.createContext(null),H=e.createContext(null),J=e.createContext(null),V=e.createContext(null),K=e.createContext({outlet:null,matches:[],isDataRoute:!1}),q=e.createContext(null);function G(){return null!=e.useContext(V)}function Q(){return G()||i(!1),e.useContext(V).location}function X(t){e.useContext(J).static||e.useLayoutEffect(t)}function Y(){let{isDataRoute:t}=e.useContext(K);return t?function(){let{router:t}=function(){let t=e.useContext(I);return t||i(!1),t}(le.UseNavigateStable),n=se(ie.UseNavigateStable),r=e.useRef(!1);return X(()=>{r.current=!0}),e.useCallback(function(e,a){void 0===a&&(a={}),r.current&&("number"==typeof e?t.navigate(e):t.navigate(e,z({fromRouteId:n},a)))},[t,n])}():function(){G()||i(!1);let t=e.useContext(I),{basename:n,future:r,navigator:a}=e.useContext(J),{matches:o}=e.useContext(K),{pathname:l}=Q(),s=JSON.stringify(D(o,r.v7_relativeSplatPath)),u=e.useRef(!1);return X(()=>{u.current=!0}),e.useCallback(function(e,r){if(void 0===r&&(r={}),!u.current)return;if("number"==typeof e)return void a.go(e);let o=T(e,JSON.parse(s),l,"path"===r.relative);null==t&&"/"!==n&&(o.pathname="/"===o.pathname?n:F([n,o.pathname])),(r.replace?a.replace:a.push)(o,r.state,r)},[n,a,s,l,t])}()}const Z=e.createContext(null);function ee(t,n){let{relative:r}=void 0===n?{}:n,{future:a}=e.useContext(J),{matches:o}=e.useContext(K),{pathname:l}=Q(),i=JSON.stringify(D(o,a.v7_relativeSplatPath));return e.useMemo(()=>T(t,JSON.parse(i),l,"path"===r),[t,i,l,r])}function te(t,n){return function(t,n,a,o){G()||i(!1);let{navigator:l}=e.useContext(J),{matches:s}=e.useContext(K),u=s[s.length-1],c=u?u.params:{};!u||u.pathname;let h=u?u.pathnameBase:"/";u&&u.route;let d,f=Q();if(n){var m;let e="string"==typeof n?p(n):n;"/"===h||(null==(m=e.pathname)?void 0:m.startsWith(h))||i(!1),d=e}else d=f;let g=d.pathname||"/",y=g;if("/"!==h){let e=h.replace(/^\//,"").split("/");y="/"+g.replace(/^\//,"").split("/").slice(e.length).join("/")}let b=v(t,{pathname:y}),x=function(t,n,r,a){var o;void 0===n&&(n=[]);void 0===r&&(r=null);void 0===a&&(a=null);if(null==t){var l;if(!r)return null;if(r.errors)t=r.matches;else{if(!(null!=(l=a)&&l.v7_partialHydration&&0===n.length&&!r.initialized&&r.matches.length>0))return null;t=r.matches}}let s=t,u=null==(o=r)?void 0:o.errors;if(null!=u){let e=s.findIndex(e=>e.route.id&&void 0!==(null==u?void 0:u[e.route.id]));e>=0||i(!1),s=s.slice(0,Math.min(s.length,e+1))}let c=!1,h=-1;if(r&&a&&a.v7_partialHydration)for(let e=0;e<s.length;e++){let t=s[e];if((t.route.HydrateFallback||t.route.hydrateFallbackElement)&&(h=e),t.route.id){let{loaderData:e,errors:n}=r,a=t.route.loader&&void 0===e[t.route.id]&&(!n||void 0===n[t.route.id]);if(t.route.lazy||a){c=!0,s=h>=0?s.slice(0,h+1):[s[0]];break}}}return s.reduceRight((t,a,o)=>{let l,i=!1,p=null,d=null;var f;r&&(l=u&&a.route.id?u[a.route.id]:void 0,p=a.route.errorElement||re,c&&(h<0&&0===o?(f="route-fallback",!1||ue[f]||(ue[f]=!0),i=!0,d=null):h===o&&(i=!0,d=a.route.hydrateFallbackElement||null)));let v=n.concat(s.slice(0,o+1)),m=()=>{let n;return n=l?p:i?d:a.route.Component?e.createElement(a.route.Component,null):a.route.element?a.route.element:t,e.createElement(oe,{match:a,routeContext:{outlet:t,matches:v,isDataRoute:null!=r},children:n})};return r&&(a.route.ErrorBoundary||a.route.errorElement||0===o)?e.createElement(ae,{location:r.location,revalidation:r.revalidation,component:p,error:l,children:m(),routeContext:{outlet:null,matches:v,isDataRoute:!0}}):m()},null)}(b&&b.map(e=>Object.assign({},e,{params:Object.assign({},c,e.params),pathname:F([h,l.encodeLocation?l.encodeLocation(e.pathname).pathname:e.pathname]),pathnameBase:"/"===e.pathnameBase?h:F([h,l.encodeLocation?l.encodeLocation(e.pathnameBase).pathname:e.pathnameBase])})),s,a,o);if(n&&x)return e.createElement(V.Provider,{value:{location:z({pathname:"/",search:"",hash:"",state:null,key:"default"},d),navigationType:r.Pop}},x);return x}(t,n)}function ne(){let t=function(){var t;let n=e.useContext(q),r=function(){let t=e.useContext(H);return t||i(!1),t}(ie.UseRouteError),a=se(ie.UseRouteError);if(void 0!==n)return n;return null==(t=r.errors)?void 0:t[a]}(),n=function(e){return null!=e&&"number"==typeof e.status&&"string"==typeof e.statusText&&"boolean"==typeof e.internal&&"data"in e}(t)?t.status+" "+t.statusText:t instanceof Error?t.message:JSON.stringify(t),r=t instanceof Error?t.stack:null,a={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"};return e.createElement(e.Fragment,null,e.createElement("h2",null,"Unexpected Application Error!"),e.createElement("h3",{style:{fontStyle:"italic"}},n),r?e.createElement("pre",{style:a},r):null,null)}const re=e.createElement(ne,null);class ae extends e.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){console.error("React Router caught the following error during render",e,t)}render(){return void 0!==this.state.error?e.createElement(K.Provider,{value:this.props.routeContext},e.createElement(q.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function oe(t){let{routeContext:n,match:r,children:a}=t,o=e.useContext(I);return o&&o.static&&o.staticContext&&(r.route.errorElement||r.route.ErrorBoundary)&&(o.staticContext._deepestRenderedBoundaryId=r.route.id),e.createElement(K.Provider,{value:n},a)}var le=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(le||{}),ie=function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e}(ie||{});function se(t){let n=function(){let t=e.useContext(K);return t||i(!1),t}(),r=n.matches[n.matches.length-1];return r.route.id||i(!1),r.route.id}const ue={};function ce(t){let{to:n,replace:r,state:a,relative:o}=t;G()||i(!1);let{future:l,static:s}=e.useContext(J),{matches:u}=e.useContext(K),{pathname:c}=Q(),h=Y(),p=T(n,D(u,l.v7_relativeSplatPath),c,"path"===o),d=JSON.stringify(p);return e.useEffect(()=>h(JSON.parse(d),{replace:r,state:a,relative:o}),[h,d,o,r,a]),null}function he(t){return function(t){let n=e.useContext(K).outlet;return n?e.createElement(Z.Provider,{value:t},n):n}(t.context)}function pe(e){i(!1)}function de(t){let{basename:n="/",children:a=null,location:o,navigationType:l=r.Pop,navigator:s,static:u=!1,future:c}=t;G()&&i(!1);let h=n.replace(/^\/*/,"/"),d=e.useMemo(()=>({basename:h,navigator:s,static:u,future:z({v7_relativeSplatPath:!1},c)}),[h,c,s,u]);"string"==typeof o&&(o=p(o));let{pathname:f="/",search:v="",hash:m="",state:g=null,key:y="default"}=o,b=e.useMemo(()=>{let e=k(f,h);return null==e?null:{location:{pathname:e,search:v,hash:m,state:g,key:y},navigationType:l}},[h,f,v,m,g,y,l]);return null==b?null:e.createElement(J.Provider,{value:d},e.createElement(V.Provider,{children:a,value:b}))}function fe(e){let{children:t,location:n}=e;return te(ve(t),n)}function ve(t,n){void 0===n&&(n=[]);let r=[];return e.Children.forEach(t,(t,a)=>{if(!e.isValidElement(t))return;let o=[...n,a];if(t.type===e.Fragment)return void r.push.apply(r,ve(t.props.children,o));t.type!==pe&&i(!1),t.props.index&&t.props.children&&i(!1);let l={id:t.props.id||o.join("-"),caseSensitive:t.props.caseSensitive,element:t.props.element,Component:t.props.Component,index:t.props.index,path:t.props.path,loader:t.props.loader,action:t.props.action,errorElement:t.props.errorElement,ErrorBoundary:t.props.ErrorBoundary,hasErrorBoundary:null!=t.props.ErrorBoundary||null!=t.props.errorElement,shouldRevalidate:t.props.shouldRevalidate,handle:t.props.handle,lazy:t.props.lazy};t.props.children&&(l.children=ve(t.props.children,o)),r.push(l)}),r}
/**
 * React Router DOM v6.30.3
 *
 * 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
 */function me(){return me=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},me.apply(this,arguments)}new Promise(()=>{});const ge=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset","viewTransition"];try{window.__reactRouterVersion="6"}catch(Ue){}const ye=t.startTransition;function be(t){let{basename:n,children:r,future:a,window:o}=t,i=e.useRef();null==i.current&&(i.current=l({window:o,v5Compat:!0}));let s=i.current,[u,c]=e.useState({action:s.action,location:s.location}),{v7_startTransition:h}=a||{},p=e.useCallback(e=>{h&&ye?ye(()=>c(e)):c(e)},[c,h]);return e.useLayoutEffect(()=>s.listen(p),[s,p]),e.useEffect(()=>{return null==(e=a)||e.v7_startTransition,void 0===(null==e?void 0:e.v7_relativeSplatPath)&&(!t||t.v7_relativeSplatPath),void(t&&(t.v7_fetcherPersist,t.v7_normalizeFormMethod,t.v7_partialHydration,t.v7_skipActionErrorRevalidation));var e,t},[a]),e.createElement(de,{basename:n,children:r,location:u.location,navigationType:u.action,navigator:s,future:a})}const xe="undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement,Ee=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,we=e.forwardRef(function(t,n){let r,{onClick:a,relative:o,reloadDocument:l,replace:s,state:u,target:c,to:p,preventScrollReset:d,viewTransition:f}=t,v=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(t,ge),{basename:m}=e.useContext(J),g=!1;if("string"==typeof p&&Ee.test(p)&&(r=p,xe))try{let e=new URL(window.location.href),t=p.startsWith("//")?new URL(e.protocol+p):new URL(p),n=k(t.pathname,m);t.origin===e.origin&&null!=n?p=n+t.search+t.hash:g=!0}catch(Ue){}let y=function(t,n){let{relative:r}=void 0===n?{}:n;G()||i(!1);let{basename:a,navigator:o}=e.useContext(J),{hash:l,pathname:s,search:u}=ee(t,{relative:r}),c=s;return"/"!==a&&(c="/"===s?a:F([a,s])),o.createHref({pathname:c,search:u,hash:l})}(p,{relative:o}),b=function(t,n){let{target:r,replace:a,state:o,preventScrollReset:l,relative:i,viewTransition:s}=void 0===n?{}:n,u=Y(),c=Q(),p=ee(t,{relative:i});return e.useCallback(e=>{if(function(e,t){return!(0!==e.button||t&&"_self"!==t||function(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}(e))}(e,r)){e.preventDefault();let n=void 0!==a?a:h(c)===h(p);u(t,{replace:n,state:o,preventScrollReset:l,relative:i,viewTransition:s})}},[c,u,p,a,o,r,t,l,i,s])}(p,{replace:s,state:u,target:c,preventScrollReset:d,relative:o,viewTransition:f});return e.createElement("a",me({},v,{href:r||y,onClick:g||l?a:function(e){a&&a(e),e.defaultPrevented||b(e)},ref:n,target:c}))});var Ce,Re,Se,Pe;(Re=Ce||(Ce={})).UseScrollRestoration="useScrollRestoration",Re.UseSubmit="useSubmit",Re.UseSubmitFetcher="useSubmitFetcher",Re.UseFetcher="useFetcher",Re.useViewTransitionState="useViewTransitionState",(Pe=Se||(Se={})).UseFetcher="useFetcher",Pe.UseFetchers="useFetchers",Pe.UseScrollRestoration="useScrollRestoration";export{be as B,we as L,ce as N,he as O,fe as R,pe as a,Q as b,Y as u};
