a(l,n))ua(c,l)?(e[r]=c,e[u]=n,r=u):(e[r]=l,e[s]=n,r=s);else{if(!(ua(c,n)))break e;e[r]=c,e[u]=n,r=u}}}return t}function a(e,t){var n=e.sortIndex-t.sortIndex;return 0!==n?n:e.id-t.id}if("object"===typeof performance&&"function"===typeof performance.now){var o=performance;t.unstable_now=function(){return o.now()}}else{var s=Date,l=s.now();t.unstable_now=function(){return s.now()-l}}var u=[],c=[],d=1,h=null,f=3,p=!1,m=!1,g=!1,v="function"===typeof setTimeout?setTimeout:null,y="function"===typeof clearTimeout?clearTimeout:null,b="undefined"!==typeof setImmediate?setImmediate:null;function w(e){for(var t=r(c);null!==t;){if(null===t.callback)i(c);else{if(!(t.startTime<=e))break;i(c),t.sortIndex=t.expirationTime,n(u,t)}t=r(c)}}function x(e){if(g=!1,w(e),!m)if(null!==r(u))m=!0,M(S);else{var t=r(c);null!==t&&D(x,t.startTime-e)}}function S(e,n){m=!1,g&&(g=!1,y(E),E=-1),p=!0;var a=f;try{for(w(n),h=r(u);null!==h&&(!(h.expirationTime>n)||e&&!T());){var o=h.callback;if("function"===typeof o){h.callback=null,f=h.priorityLevel;var s=o(h.expirationTime<=n);n=t.unstable_now(),"function"===typeof s?h.callback=s:h===r(u)&&i(u),w(n)}else i(u);h=r(u)}if(null!==h)var l=!0;else{var d=r(c);null!==d&&D(x,d.startTime-n),l=!1}return l}finally{h=null,f=a,p=!1}}"undefined"!==typeof navigator&&void 0!==navigator.scheduling&&void 0!==navigator.scheduling.isInputPending&&navigator.scheduling.isInputPending.bind(navigator.scheduling);var k,_=!1,C=null,E=-1,P=5,L=-1;function T(){return!(t.unstable_now()-Le||125o?(e.sortIndex=a,n(c,e),null===r(u)&&e===r(c)&&(g?(y(E),E=-1):g=!0,D(x,a-o))):(e.sortIndex=s,n(u,e),m||p||(m=!0,M(S))),e},t.unstable_shouldYield=T,t.unstable_wrapCallback=function(e){var t=f;return function(){var n=f;f=t;try{return e.apply(this,arguments)}finally{f=n}}}},797:()=>{!function(){"use strict";if("object"===typeof window)if("IntersectionObserver"in window&&"IntersectionObserverEntry"in window&&"intersectionRatio"in window.IntersectionObserverEntry.prototype)"isIntersecting"in window.IntersectionObserverEntry.prototype||Object.defineProperty(window.IntersectionObserverEntry.prototype,"isIntersecting",{get:function(){return this.intersectionRatio>0}});else{var e=function(){for(var e=window.document,t=i(e);t;)t=i(e=t.ownerDocument);return e}(),t=[],n=null,r=null;o.prototype.THROTTLE_TIMEOUT=100,o.prototype.POLL_INTERVAL=null,o.prototype.USE_MUTATION_OBSERVER=!0,o._setupCrossOriginUpdater=function(){return n||(n=function(e,n){r=e&&n?h(e,n):{top:0,bottom:0,left:0,right:0,width:0,height:0},t.forEach((function(e){e._checkForIntersections()}))}),n},o._resetCrossOriginUpdater=function(){n=null,r=null},o.prototype.observe=function(e){if(!this._observationTargets.some((function(t){return t.element==e}))){if(!e||1!=e.nodeType)throw new Error("target must be an Element");this._registerInstance(),this._observationTargets.push({element:e,entry:null}),this._monitorIntersections(e.ownerDocument),this._checkForIntersections()}},o.prototype.unobserve=function(e){this._observationTargets=this._observationTargets.filter((function(t){return t.element!=e})),this._unmonitorIntersections(e.ownerDocument),0==this._observationTargets.length&&this._unregisterInstance()},o.prototype.disconnect=function(){this._observationTargets=[],this._unmonitorAllIntersections(),this._unregisterInstance()},o.prototype.takeRecords=function(){var e=this._queuedEntries.slice();return this._queuedEntries=[],e},o.prototype._initThresholds=function(e){var t=e||[0];return Array.isArray(t)||(t=[t]),t.sort().filter((function(e,t,n){if("number"!=typeof e||isNaN(e)||e<0||e>1)throw new Error("threshold must be a number between 0 and 1 inclusively");return e!==n[t-1]}))},o.prototype._parseRootMargin=function(e){var t=(e||"0px").split(/\s+/).map((function(e){var t=/^(-?\d*\.?\d+)(px|%)$/.exec(e);if(!t)throw new Error("rootMargin must be specified in pixels or percent");return{value:parseFloat(t[1]),unit:t[2]}}));return t[1]=t[1]||t[0],t[2]=t[2]||t[0],t[3]=t[3]||t[1],t},o.prototype._monitorIntersections=function(t){var n=t.defaultView;if(n&&-1==this._monitoringDocuments.indexOf(t)){var r=this._checkForIntersections,a=null,o=null;this.POLL_INTERVAL?a=n.setInterval(r,this.POLL_INTERVAL):(s(n,"resize",r,!0),s(t,"scroll",r,!0),this.USE_MUTATION_OBSERVER&&"MutationObserver"in n&&(o=new n.MutationObserver(r)).observe(t,{attributes:!0,childList:!0,characterData:!0,subtree:!0})),this._monitoringDocuments.push(t),this._monitoringUnsubscribes.push((function(){var e=t.defaultView;e&&(a&&e.clearInterval(a),l(e,"resize",r,!0)),l(t,"scroll",r,!0),o&&o.disconnect()}));var u=this.root&&(this.root.ownerDocument||this.root)||e;if(t!=u){var c=i(t);c&&this._monitorIntersections(c.ownerDocument)}}},o.prototype._unmonitorIntersections=function(t){var n=this._monitoringDocuments.indexOf(t);if(-1!=n){var r=this.root&&(this.root.ownerDocument||this.root)||e,a=this._observationTargets.some((function(e){var n=e.element.ownerDocument;if(n==t)return!0;for(;n&&n!=r;){var a=i(n);if((n=a&&a.ownerDocument)==t)return!0}return!1}));if(!a){var o=this._monitoringUnsubscribes[n];if(this._monitoringDocuments.splice(n,1),this._monitoringUnsubscribes.splice(n,1),o(),t!=r){var s=i(t);s&&this._unmonitorIntersections(s.ownerDocument)}}}},o.prototype._unmonitorAllIntersections=function(){var e=this._monitoringUnsubscribes.slice(0);this._monitoringDocuments.length=0,this._monitoringUnsubscribes.length=0;for(var t=0;t=0&&s>=0&&{top:n,bottom:r,left:i,right:a,width:o,height:s}||null}function c(e){var t;try{t=e.getBoundingClientRect()}catch(n){}return t?(t.width&&t.height||(t={top:t.top,right:t.right,bottom:t.bottom,left:t.left,width:t.right-t.left,height:t.bottom-t.top}),t):{top:0,bottom:0,left:0,right:0,width:0,height:0}}function d(e){return!e||"x"in e?e:{top:e.top,y:e.top,bottom:e.bottom,left:e.left,x:e.left,right:e.right,width:e.width,height:e.height}}function h(e,t){var n=t.top-e.top,r=t.left-e.left;return{top:n,left:r,height:t.height,width:t.width,bottom:n+t.height,right:r+t.width}}function f(e,t){for(var n=t;n;){if(n==e)return!0;n=p(n)}return!1}function p(t){var n=t.parentNode;return 9==t.nodeType&&t!=e?i(t):(n&&n.assignedSlot&&(n=n.assignedSlot.parentNode),n&&11==n.nodeType&&n.host?n.host:n)}function m(e){return e&&9===e.nodeType}}()},798:e=>{var t=/\s/;e.exports=function(e){for(var n=e.length;n--&&t.test(e.charAt(n)););return n}},878:(e,t,n)=>{"use strict";e.exports=n(153)},901:e=>{var t="undefined"!==typeof Element,n="function"===typeof Map,r="function"===typeof Set,i="function"===typeof ArrayBuffer&&!!ArrayBuffer.isView;function a(e,o){if(e===o)return!0;if(e&&o&&"object"==typeof e&&"object"==typeof o){if(e.constructor!==o.constructor)return!1;var s,l,u,c;if(Array.isArray(e)){if((s=e.length)!=o.length)return!1;for(l=s;0!==l--;)if(!a(e[l],o[l]))return!1;return!0}if(n&&e instanceof Map&&o instanceof Map){if(e.size!==o.size)return!1;for(c=e.entries();!(l=c.next()).done;)if(!o.has(l.value[0]))return!1;for(c=e.entries();!(l=c.next()).done;)if(!a(l.value[1],o.get(l.value[0])))return!1;return!0}if(r&&e instanceof Set&&o instanceof Set){if(e.size!==o.size)return!1;for(c=e.entries();!(l=c.next()).done;)if(!o.has(l.value[0]))return!1;return!0}if(i&&ArrayBuffer.isView(e)&&ArrayBuffer.isView(o)){if((s=e.length)!=o.length)return!1;for(l=s;0!==l--;)if(e[l]!==o[l])return!1;return!0}if(e.constructor===RegExp)return e.source===o.source&&e.flags===o.flags;if(e.valueOf!==Object.prototype.valueOf&&"function"===typeof e.valueOf&&"function"===typeof o.valueOf)return e.valueOf()===o.valueOf();if(e.toString!==Object.prototype.toString&&"function"===typeof e.toString&&"function"===typeof o.toString)return e.toString()===o.toString();if((s=(u=Object.keys(e)).length)!==Object.keys(o).length)return!1;for(l=s;0!==l--;)if(!Object.prototype.hasOwnProperty.call(o,u[l]))return!1;if(t&&e instanceof Element)return!1;for(l=s;0!==l--;)if(("_owner"!==u[l]&&"__v"!==u[l]&&"__o"!==u[l]||!e.$$typeof)&&!a(e[u[l]],o[u[l]]))return!1;return!0}return e!==e&&o!==o}e.exports=function(e,t){try{return a(e,t)}catch(n){if((n.message||"").match(/stack|recursion/i))return console.warn("react-fast-compare cannot handle circular refs"),!1;throw n}}},914:(e,t,n)=>{var r=n(798),i=/^\s+/;e.exports=function(e){return e?e.slice(0,r(e)+1).replace(i,""):e}},950:(e,t,n)=>{"use strict";e.exports=n(49)}},t={};function n(r){var i=t[r];if(void 0!==i)return i.exports;var a=t[r]={exports:{}};return e[r].call(a.exports,a,a.exports,n),a.exports}n.m=e,n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},(()=>{var e,t=Object.getPrototypeOf?e=>Object.getPrototypeOf(e):e=>e.__proto__;n.t=function(r,i){if(1&i&&(r=this(r)),8&i)return r;if("object"===typeof r&&r){if(4&i&&r.__esModule)return r;if(16&i&&"function"===typeof r.then)return r}var a=Object.create(null);n.r(a);var o={};e=e||[null,t({}),t([]),t(t)];for(var s=2&i&&r;"object"==typeof s&&!~e.indexOf(s);s=t(s))Object.getOwnPropertyNames(s).forEach((e=>o[e]=()=>r[e]));return o.default=()=>r,n.d(a,o),a}})(),n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.f={},n.e=e=>Promise.all(Object.keys(n.f).reduce(((t,r)=>(n.f[r](e,t),t)),[])),n.u=e=>"static/js/"+e+".d71bd05f.chunk.js",n.miniCssF=e=>{},n.g=function(){if("object"===typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"===typeof window)return window}}(),n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{var e={},t="outline-mobile:";n.l=(r,i,a,o)=>{if(e[r])e[r].push(i);else{var s,l;if(void 0!==a)for(var u=document.getElementsByTagName("script"),c=0;c{s.onerror=s.onload=null,clearTimeout(f);var i=e[r];if(delete e[r],s.parentNode&&s.parentNode.removeChild(s),i&&i.forEach((e=>e(n))),t)return t(n)},f=setTimeout(h.bind(null,void 0,{type:"timeout",target:s}),12e4);s.onerror=h.bind(null,s.onerror),s.onload=h.bind(null,s.onload),l&&document.head.appendChild(s)}}})(),n.r=e=>{"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.p="./",(()=>{var e={792:0};n.f.j=(t,r)=>{var i=n.o(e,t)?e[t]:void 0;if(0!==i)if(i)r.push(i[2]);else{var a=new Promise(((n,r)=>i=e[t]=[n,r]));r.push(i[2]=a);var o=n.p+n.u(t),s=new Error;n.l(o,(r=>{if(n.o(e,t)&&(0!==(i=e[t])&&(e[t]=void 0),i)){var a=r&&("load"===r.type?"missing":r.type),o=r&&r.target&&r.target.src;s.message="Loading chunk "+t+" failed.\n("+a+": "+o+")",s.name="ChunkLoadError",s.type=a,s.request=o,i[1](s)}}),"chunk-"+t,t)}};var t=(t,r)=>{var i,a,o=r[0],s=r[1],l=r[2],u=0;if(o.some((t=>0!==e[t]))){for(i in s)n.o(s,i)&&(n.m[i]=s[i]);if(l)l(n)}for(t&&t(r);u{"use strict";var e={};n.r(e),n.d(e,{appendChild:()=>jv,appendChildToContainer:()=>zv,appendInitialChild:()=>vv,cancelTimeout:()=>Rv,clearContainer:()=>qv,commitMount:()=>Wv,commitTextUpdate:()=>Uv,commitUpdate:()=>$v,createInstance:()=>yv,createTextInstance:()=>bv,detachDeletedInstance:()=>Qv,finalizeInitialChildren:()=>wv,getChildHostContext:()=>Tv,getCurrentEventPriority:()=>Kv,getPublicInstance:()=>xv,getRootHostContext:()=>Lv,hideInstance:()=>Xv,hideTextInstance:()=>Yv,idlePriority:()=>pv.unstable_IdlePriority,insertBefore:()=>Fv,insertInContainerBefore:()=>Gv,isPrimaryRenderer:()=>Dv,noTimeout:()=>Nv,now:()=>pv.unstable_now,prepareForCommit:()=>Sv,preparePortalMount:()=>kv,prepareUpdate:()=>_v,removeChild:()=>Bv,removeChildFromContainer:()=>Hv,resetAfterCommit:()=>Cv,resetTextContent:()=>Ev,run:()=>pv.unstable_runWithPriority,scheduleTimeout:()=>Ov,shouldDeprioritizeSubtree:()=>Pv,shouldSetTextContent:()=>Mv,supportsMutation:()=>Iv,unhideInstance:()=>Vv,unhideTextInstance:()=>Jv,warnsIfNotActing:()=>Av});var t,r=n(950),i=n.t(r,2),a=n(352);function o(){return o=Object.assign?Object.assign.bind():function(e){for(var t=1;t=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}function p(e,n,r,i){void 0===i&&(i={});let{window:a=document.defaultView,v5Compat:u=!1}=i,f=a.history,p=t.Pop,m=null,g=v();function v(){return(f.state||{idx:null}).idx}function y(){p=t.Pop;let e=v(),n=null==e?null:e-g;g=e,m&&m({action:p,location:w.location,delta:n})}function b(e){let t="null"!==a.location.origin?a.location.origin:a.location.href,n="string"===typeof e?e:h(e);return n=n.replace(/ $/,"%20"),l(t,"No window.location.(origin|href) available to create URL for href: "+n),new URL(n,t)}null==g&&(g=0,f.replaceState(o({},f.state,{idx:g}),""));let w={get action(){return p},get location(){return e(a,f)},listen(e){if(m)throw new Error("A history only accepts one active listener");return a.addEventListener(s,y),m=e,()=>{a.removeEventListener(s,y),m=null}},createHref:e=>n(a,e),createURL:b,encodeLocation(e){let t=b(e);return{pathname:t.pathname,search:t.search,hash:t.hash}},push:function(e,n){p=t.Push;let i=d(w.location,e,n);r&&r(i,e),g=v()+1;let o=c(i,g),s=w.createHref(i);try{f.pushState(o,"",s)}catch(dy){if(dy instanceof DOMException&&"DataCloneError"===dy.name)throw dy;a.location.assign(s)}u&&m&&m({action:p,location:w.location,delta:1})},replace:function(e,n){p=t.Replace;let i=d(w.location,e,n);r&&r(i,e),g=v();let a=c(i,g),o=w.createHref(i);f.replaceState(a,"",o),u&&m&&m({action:p,location:w.location,delta:0})},go:e=>f.go(e)};return w}var m;!function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"}(m||(m={}));const g=new Set(["lazy","caseSensitive","path","id","index","children"]);function v(e,t,n,r){return void 0===n&&(n=[]),void 0===r&&(r={}),e.map(((e,i)=>{let a=[...n,String(i)],s="string"===typeof e.id?e.id:a.join("-");if(l(!0!==e.index||!e.children,"Cannot specify children on an index route"),l(!r[s],'Found a route id collision on id "'+s+"\". Route id's must be globally unique within Data Router usages"),function(e){return!0===e.index}(e)){let n=o({},e,t(e),{id:s});return r[s]=n,n}{let n=o({},e,t(e),{id:s,children:void 0});return r[s]=n,e.children&&(n.children=v(e.children,t,a,r)),n}}))}function y(e,t,n){return void 0===n&&(n="/"),b(e,t,n,!1)}function b(e,t,n,r){let i=M(("string"===typeof t?f(t):t).pathname||"/",n);if(null==i)return null;let a=w(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)))))}(a);let o=null;for(let s=0;null==o&&s{let o={relativePath:void 0===a?e.path||"":a,caseSensitive:!0===e.caseSensitive,childrenIndex:i,route:e};o.relativePath.startsWith("/")&&(l(o.relativePath.startsWith(r),'Absolute route path "'+o.relativePath+'" nested under path "'+r+'" is not valid. An absolute child route path must start with the combined path of all its parent routes.'),o.relativePath=o.relativePath.slice(r.length));let s=z([r,o.relativePath]),u=n.concat(o);e.children&&e.children.length>0&&(l(!0!==e.index,'Index routes must not have child routes. Please remove all child routes from route path "'+s+'".'),w(e.children,t,u,s)),(null!=e.path||e.index)&&t.push({path:s,score:T(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 x(e.path))i(e,t,r);else i(e,t)})),t}function x(e){let t=e.split("/");if(0===t.length)return[];let[n,...r]=t,i=n.endsWith("?"),a=n.replace(/\?$/,"");if(0===r.length)return i?[a,""]:[a];let o=x(r.join("/")),s=[];return s.push(...o.map((e=>""===e?a:[a,e].join("/")))),i&&s.push(...o),s.map((t=>e.startsWith("/")&&""===t?"/":t))}const S=/^:[\w-]+$/,k=3,_=2,C=1,E=10,P=-2,L=e=>"*"===e;function T(e,t){let n=e.split("/"),r=n.length;return n.some(L)&&(r+=P),t&&(r+=_),n.filter((e=>!L(e))).reduce(((e,t)=>e+(S.test(t)?k:""===t?C:E)),r)}function O(e,t,n){void 0===n&&(n=!1);let{routesMeta:r}=e,i={},a="/",o=[];for(let s=0;s(r.push({paramName:t,isOptional:null!=n}),n?"/?([^\\/]+)?":"/([^\\/]+)")));e.endsWith("*")?(r.push({paramName:"*"}),i+="*"===e||"/*"===e?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?i+="\\/*$":""!==e&&"/"!==e&&(i+="(?:(?=\\/|$))");let a=new RegExp(i,t?void 0:"i");return[a,r]}(e.path,e.caseSensitive,e.end),i=t.match(n);if(!i)return null;let a=i[0],o=a.replace(/(.)\/+$/,"$1"),s=i.slice(1);return{params:r.reduce(((e,t,n)=>{let{paramName:r,isOptional:i}=t;if("*"===r){let e=s[n]||"";o=a.slice(0,a.length-e.length).replace(/(.)\/+$/,"$1")}const l=s[n];return e[r]=i&&!l?void 0:(l||"").replace(/%2F/g,"/"),e}),{}),pathname:a,pathnameBase:o,pattern:e}}function N(e){try{return e.split("/").map((e=>decodeURIComponent(e).replace(/\//g,"%2F"))).join("/")}catch(dy){return u(!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 ('+dy+")."),e}}function M(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)||"/"}function D(e,t,n,r){return"Cannot include a '"+e+"' character in a manually specified `to."+t+"` field ["+JSON.stringify(r)+"]. Please separate it out to the `to."+n+'` field. Alternatively you may provide the full path as a string in and the router will parse it for you.'}function A(e){return e.filter(((e,t)=>0===t||e.route.path&&e.route.path.length>0))}function I(e,t){let n=A(e);return t?n.map(((e,t)=>t===n.length-1?e.pathname:e.pathnameBase)):n.map((e=>e.pathnameBase))}function j(e,t,n,r){let i;void 0===r&&(r=!1),"string"===typeof e?i=f(e):(i=o({},e),l(!i.pathname||!i.pathname.includes("?"),D("?","pathname","search",i)),l(!i.pathname||!i.pathname.includes("#"),D("#","pathname","hash",i)),l(!i.search||!i.search.includes("#"),D("#","search","hash",i)));let a,s=""===e||""===i.pathname,u=s?"/":i.pathname;if(null==u)a=n;else{let e=t.length-1;if(!r&&u.startsWith("..")){let t=u.split("/");for(;".."===t[0];)t.shift(),e-=1;i.pathname=t.join("/")}a=e>=0?t[e]:"/"}let c=function(e,t){void 0===t&&(t="/");let{pathname:n,search:r="",hash:i=""}="string"===typeof e?f(e):e,a=n?n.startsWith("/")?n:function(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("/"):"/"}(n,t):t;return{pathname:a,search:G(r),hash:B(i)}}(i,a),d=u&&"/"!==u&&u.endsWith("/"),h=(s||"."===u)&&n.endsWith("/");return c.pathname.endsWith("/")||!d&&!h||(c.pathname+="/"),c}const z=e=>e.join("/").replace(/\/\/+/g,"/"),F=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),G=e=>e&&"?"!==e?e.startsWith("?")?e:"?"+e:"",B=e=>e&&"#"!==e?e.startsWith("#")?e:"#"+e:"";Error;class H{constructor(e,t,n,r){void 0===r&&(r=!1),this.status=e,this.statusText=t||"",this.internal=r,n instanceof Error?(this.data=n.toString(),this.error=n):this.data=n}}function U(e){return null!=e&&"number"===typeof e.status&&"string"===typeof e.statusText&&"boolean"===typeof e.internal&&"data"in e}const W=["post","put","patch","delete"],$=new Set(W),X=["get",...W],Y=new Set(X),V=new Set([301,302,303,307,308]),J=new Set([307,308]),q={state:"idle",location:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},Q={state:"idle",data:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},K={state:"unblocked",proceed:void 0,reset:void 0,location:void 0},Z=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,ee=e=>({hasErrorBoundary:Boolean(e.hasErrorBoundary)}),te="remix-router-transitions";function ne(e){const n=e.window?e.window:"undefined"!==typeof window?window:void 0,r="undefined"!==typeof n&&"undefined"!==typeof n.document&&"undefined"!==typeof n.document.createElement,i=!r;let a;if(l(e.routes.length>0,"You must provide a non-empty routes array to createRouter"),e.mapRouteProperties)a=e.mapRouteProperties;else if(e.detectErrorBoundary){let t=e.detectErrorBoundary;a=e=>({hasErrorBoundary:t(e)})}else a=ee;let s,c,h,f={},p=v(e.routes,a,void 0,f),g=e.basename||"/",w=e.dataStrategy||he,x=e.patchRoutesOnNavigation,S=o({v7_fetcherPersist:!1,v7_normalizeFormMethod:!1,v7_partialHydration:!1,v7_prependBasename:!1,v7_relativeSplatPath:!1,v7_skipActionErrorRevalidation:!1},e.future),k=null,_=new Set,C=null,E=null,P=null,L=null!=e.hydrationData,T=y(p,e.history.location,g),O=!1,R=null;if(null==T&&!x){let t=Ee(404,{pathname:e.history.location.pathname}),{matches:n,route:r}=Ce(p);T=n,R={[r.id]:t}}if(T&&!e.hydrationData){ut(T,p,e.history.location.pathname).active&&(T=null)}if(T)if(T.some((e=>e.route.lazy)))c=!1;else if(T.some((e=>e.route.loader)))if(S.v7_partialHydration){let t=e.hydrationData?e.hydrationData.loaderData:null,n=e.hydrationData?e.hydrationData.errors:null;if(n){let e=T.findIndex((e=>void 0!==n[e.route.id]));c=T.slice(0,e+1).every((e=>!se(e.route,t,n)))}else c=T.every((e=>!se(e.route,t,n)))}else c=null!=e.hydrationData;else c=!0;else if(c=!1,T=[],S.v7_partialHydration){let t=ut(null,p,e.history.location.pathname);t.active&&t.matches&&(O=!0,T=t.matches)}let N,D,A={historyAction:e.history.action,location:e.history.location,matches:T,initialized:c,navigation:q,restoreScrollPosition:null==e.hydrationData&&null,preventScrollReset:!1,revalidation:"idle",loaderData:e.hydrationData&&e.hydrationData.loaderData||{},actionData:e.hydrationData&&e.hydrationData.actionData||null,errors:e.hydrationData&&e.hydrationData.errors||R,fetchers:new Map,blockers:new Map},I=t.Pop,j=!1,z=!1,F=new Map,G=null,B=!1,H=!1,W=[],$=new Set,X=new Map,Y=0,V=-1,ne=new Map,ae=new Set,le=new Map,ue=new Map,de=new Set,ye=new Map,be=new Map;function we(e,t){void 0===t&&(t={}),A=o({},A,e);let n=[],r=[];S.v7_fetcherPersist&&A.fetchers.forEach(((e,t)=>{"idle"===e.state&&(de.has(t)?r.push(t):n.push(t))})),de.forEach((e=>{A.fetchers.has(e)||X.has(e)||r.push(e)})),[..._].forEach((e=>e(A,{deletedFetchers:r,viewTransitionOpts:t.viewTransitionOpts,flushSync:!0===t.flushSync}))),S.v7_fetcherPersist?(n.forEach((e=>A.fetchers.delete(e))),r.forEach((e=>Qe(e)))):r.forEach((e=>de.delete(e)))}function Le(n,r,i){var a,l;let u,{flushSync:c}=void 0===i?{}:i,d=null!=A.actionData&&null!=A.navigation.formMethod&&Ie(A.navigation.formMethod)&&"loading"===A.navigation.state&&!0!==(null==(a=n.state)?void 0:a._isRedirect);u=r.actionData?Object.keys(r.actionData).length>0?r.actionData:null:d?A.actionData:null;let h=r.loaderData?Se(A.loaderData,r.loaderData,r.matches||[],r.errors):A.loaderData,f=A.blockers;f.size>0&&(f=new Map(f),f.forEach(((e,t)=>f.set(t,K))));let m,g=!0===j||null!=A.navigation.formMethod&&Ie(A.navigation.formMethod)&&!0!==(null==(l=n.state)?void 0:l._isRedirect);if(s&&(p=s,s=void 0),B||I===t.Pop||(I===t.Push?e.history.push(n,n.state):I===t.Replace&&e.history.replace(n,n.state)),I===t.Pop){let e=F.get(A.location.pathname);e&&e.has(n.pathname)?m={currentLocation:A.location,nextLocation:n}:F.has(n.pathname)&&(m={currentLocation:n,nextLocation:A.location})}else if(z){let e=F.get(A.location.pathname);e?e.add(n.pathname):(e=new Set([n.pathname]),F.set(A.location.pathname,e)),m={currentLocation:A.location,nextLocation:n}}we(o({},r,{actionData:u,loaderData:h,historyAction:I,location:n,initialized:!0,navigation:q,revalidation:"idle",restoreScrollPosition:lt(n,r.matches||A.matches),preventScrollReset:g,blockers:f}),{viewTransitionOpts:m,flushSync:!0===c}),I=t.Pop,j=!1,z=!1,B=!1,H=!1,W=[]}async function Me(n,r,i){N&&N.abort(),N=null,I=n,B=!0===(i&&i.startUninterruptedRevalidation),function(e,t){if(C&&P){let n=st(e,t);C[n]=P()}}(A.location,A.matches),j=!0===(i&&i.preventScrollReset),z=!0===(i&&i.enableViewTransition);let a=s||p,l=i&&i.overrideNavigation,u=null!=i&&i.initialHydration&&A.matches&&A.matches.length>0&&!O?A.matches:y(a,r,g),c=!0===(i&&i.flushSync);if(u&&A.initialized&&!H&&function(e,t){if(e.pathname!==t.pathname||e.search!==t.search)return!1;if(""===e.hash)return""!==t.hash;if(e.hash===t.hash)return!0;if(""!==t.hash)return!0;return!1}(A.location,r)&&!(i&&i.submission&&Ie(i.submission.formMethod)))return void Le(r,{matches:u},{flushSync:c});let d=ut(u,a,r.pathname);if(d.active&&d.matches&&(u=d.matches),!u){let{error:e,notFoundMatches:t,route:n}=at(r.pathname);return void Le(r,{matches:t,loaderData:{},errors:{[n.id]:e}},{flushSync:c})}N=new AbortController;let h,f=ve(e.history,r,N.signal,i&&i.submission);if(i&&i.pendingError)h=[_e(u).route.id,{type:m.error,error:i.pendingError}];else if(i&&i.submission&&Ie(i.submission.formMethod)){let n=await async function(e,n,r,i,a,o){void 0===o&&(o={});Ye();let s,l=function(e,t){let n={state:"submitting",location:e,formMethod:t.formMethod,formAction:t.formAction,formEncType:t.formEncType,formData:t.formData,json:t.json,text:t.text};return n}(n,r);if(we({navigation:l},{flushSync:!0===o.flushSync}),a){let t=await ct(i,n.pathname,e.signal);if("aborted"===t.type)return{shortCircuited:!0};if("error"===t.type){let e=_e(t.partialMatches).route.id;return{matches:t.partialMatches,pendingActionResult:[e,{type:m.error,error:t.error}]}}if(!t.matches){let{notFoundMatches:e,error:t,route:r}=at(n.pathname);return{matches:e,pendingActionResult:[r.id,{type:m.error,error:t}]}}i=t.matches}let u=Be(i,n);if(u.route.action||u.route.lazy){if(s=(await Ge("action",A,e,[u],i,null))[u.route.id],e.signal.aborted)return{shortCircuited:!0}}else s={type:m.error,error:Ee(405,{method:e.method,pathname:n.pathname,routeId:u.route.id})};if(Ne(s)){let t;if(o&&null!=o.replace)t=o.replace;else{t=ge(s.response.headers.get("Location"),new URL(e.url),g)===A.location.pathname+A.location.search}return await Ae(e,s,!0,{submission:r,replace:t}),{shortCircuited:!0}}if(Oe(s))throw Ee(400,{type:"defer-action"});if(Re(s)){let e=_e(i,u.route.id);return!0!==(o&&o.replace)&&(I=t.Push),{matches:i,pendingActionResult:[e.route.id,s]}}return{matches:i,pendingActionResult:[u.route.id,s]}}(f,r,i.submission,u,d.active,{replace:i.replace,flushSync:c});if(n.shortCircuited)return;if(n.pendingActionResult){let[e,t]=n.pendingActionResult;if(Re(t)&&U(t.error)&&404===t.error.status)return N=null,void Le(r,{matches:n.matches,loaderData:{},errors:{[e]:t.error}})}u=n.matches||u,h=n.pendingActionResult,l=Ue(r,i.submission),c=!1,d.active=!1,f=ve(e.history,f.url,f.signal)}let{shortCircuited:v,matches:b,loaderData:w,errors:x}=await async function(t,n,r,i,a,l,u,c,d,h,f){let m=a||Ue(n,l),v=l||u||He(m),y=!B&&(!S.v7_partialHydration||!d);if(i){if(y){let e=De(f);we(o({navigation:m},void 0!==e?{actionData:e}:{}),{flushSync:h})}let e=await ct(r,n.pathname,t.signal);if("aborted"===e.type)return{shortCircuited:!0};if("error"===e.type){let t=_e(e.partialMatches).route.id;return{matches:e.partialMatches,loaderData:{},errors:{[t]:e.error}}}if(!e.matches){let{error:e,notFoundMatches:t,route:r}=at(n.pathname);return{matches:t,loaderData:{},errors:{[r.id]:e}}}r=e.matches}let b=s||p,[w,x]=oe(e.history,A,r,v,n,S.v7_partialHydration&&!0===d,S.v7_skipActionErrorRevalidation,H,W,$,de,le,ae,b,g,f);if(ot((e=>!(r&&r.some((t=>t.route.id===e)))||w&&w.some((t=>t.route.id===e)))),V=++Y,0===w.length&&0===x.length){let e=et();return Le(n,o({matches:r,loaderData:{},errors:f&&Re(f[1])?{[f[0]]:f[1].error}:null},ke(f),e?{fetchers:new Map(A.fetchers)}:{}),{flushSync:h}),{shortCircuited:!0}}if(y){let e={};if(!i){e.navigation=m;let t=De(f);void 0!==t&&(e.actionData=t)}x.length>0&&(e.fetchers=function(e){return e.forEach((e=>{let t=A.fetchers.get(e.key),n=We(void 0,t?t.data:void 0);A.fetchers.set(e.key,n)})),new Map(A.fetchers)}(x)),we(e,{flushSync:h})}x.forEach((e=>{Ke(e.key),e.controller&&X.set(e.key,e.controller)}));let k=()=>x.forEach((e=>Ke(e.key)));N&&N.signal.addEventListener("abort",k);let{loaderResults:_,fetcherResults:C}=await Xe(A,r,w,x,t);if(t.signal.aborted)return{shortCircuited:!0};N&&N.signal.removeEventListener("abort",k);x.forEach((e=>X.delete(e.key)));let E=Pe(_);if(E)return await Ae(t,E.result,!0,{replace:c}),{shortCircuited:!0};if(E=Pe(C),E)return ae.add(E.key),await Ae(t,E.result,!0,{replace:c}),{shortCircuited:!0};let{loaderData:P,errors:L}=xe(A,r,_,f,x,C,ye);ye.forEach(((e,t)=>{e.subscribe((n=>{(n||e.done)&&ye.delete(t)}))})),S.v7_partialHydration&&d&&A.errors&&(L=o({},A.errors,L));let T=et(),O=tt(V),R=T||O||x.length>0;return o({matches:r,loaderData:P,errors:L},R?{fetchers:new Map(A.fetchers)}:{})}(f,r,u,d.active,l,i&&i.submission,i&&i.fetcherSubmission,i&&i.replace,i&&!0===i.initialHydration,c,h);v||(N=null,Le(r,o({matches:b||u},ke(h),{loaderData:w,errors:x})))}function De(e){return e&&!Re(e[1])?{[e[0]]:e[1].data}:A.actionData?0===Object.keys(A.actionData).length?null:A.actionData:void 0}async function Ae(i,a,s,u){let{submission:c,fetcherSubmission:h,preventScrollReset:f,replace:p}=void 0===u?{}:u;a.response.headers.has("X-Remix-Revalidate")&&(H=!0);let m=a.response.headers.get("Location");l(m,"Expected a Location header on the redirect Response"),m=ge(m,new URL(i.url),g);let v=d(A.location,m,{_isRedirect:!0});if(r){let t=!1;if(a.response.headers.has("X-Remix-Reload-Document"))t=!0;else if(Z.test(m)){const r=e.history.createURL(m);t=r.origin!==n.location.origin||null==M(r.pathname,g)}if(t)return void(p?n.location.replace(m):n.location.assign(m))}N=null;let y=!0===p||a.response.headers.has("X-Remix-Replace")?t.Replace:t.Push,{formMethod:b,formAction:w,formEncType:x}=A.navigation;!c&&!h&&b&&w&&x&&(c=He(A.navigation));let S=c||h;if(J.has(a.response.status)&&S&&Ie(S.formMethod))await Me(y,v,{submission:o({},S,{formAction:m}),preventScrollReset:f||j,enableViewTransition:s?z:void 0});else{let e=Ue(v,c);await Me(y,v,{overrideNavigation:e,fetcherSubmission:h,preventScrollReset:f||j,enableViewTransition:s?z:void 0})}}async function Ge(e,t,n,r,i,o){let s,l={};try{s=await fe(w,e,t,n,r,i,o,f,a)}catch(u){return r.forEach((e=>{l[e.route.id]={type:m.error,error:u}})),l}for(let[a,c]of Object.entries(s))if(Te(c)){let e=c.result;l[a]={type:m.redirect,response:me(e,n,a,i,g,S.v7_relativeSplatPath)}}else l[a]=await pe(c);return l}async function Xe(t,n,r,i,a){let o=t.matches,s=Ge("loader",t,a,r,n,null),l=Promise.all(i.map((async n=>{if(n.matches&&n.match&&n.controller){let r=(await Ge("loader",t,ve(e.history,n.path,n.controller.signal),[n.match],n.matches,n.key))[n.match.route.id];return{[n.key]:r}}return Promise.resolve({[n.key]:{type:m.error,error:Ee(404,{pathname:n.path})}})}))),u=await s,c=(await l).reduce(((e,t)=>Object.assign(e,t)),{});return await Promise.all([je(n,u,a.signal,o,t.loaderData),ze(n,c,i)]),{loaderResults:u,fetcherResults:c}}function Ye(){H=!0,W.push(...ot()),le.forEach(((e,t)=>{X.has(t)&&$.add(t),Ke(t)}))}function Ve(e,t,n){void 0===n&&(n={}),A.fetchers.set(e,t),we({fetchers:new Map(A.fetchers)},{flushSync:!0===(n&&n.flushSync)})}function Je(e,t,n,r){void 0===r&&(r={});let i=_e(A.matches,t);Qe(e),we({errors:{[i.route.id]:n},fetchers:new Map(A.fetchers)},{flushSync:!0===(r&&r.flushSync)})}function qe(e){return ue.set(e,(ue.get(e)||0)+1),de.has(e)&&de.delete(e),A.fetchers.get(e)||Q}function Qe(e){let t=A.fetchers.get(e);!X.has(e)||t&&"loading"===t.state&&ne.has(e)||Ke(e),le.delete(e),ne.delete(e),ae.delete(e),S.v7_fetcherPersist&&de.delete(e),$.delete(e),A.fetchers.delete(e)}function Ke(e){let t=X.get(e);t&&(t.abort(),X.delete(e))}function Ze(e){for(let t of e){let e=$e(qe(t).data);A.fetchers.set(t,e)}}function et(){let e=[],t=!1;for(let n of ae){let r=A.fetchers.get(n);l(r,"Expected fetcher: "+n),"loading"===r.state&&(ae.delete(n),e.push(n),t=!0)}return Ze(e),t}function tt(e){let t=[];for(let[n,r]of ne)if(r0}function nt(e){A.blockers.delete(e),be.delete(e)}function rt(e,t){let n=A.blockers.get(e)||K;l("unblocked"===n.state&&"blocked"===t.state||"blocked"===n.state&&"blocked"===t.state||"blocked"===n.state&&"proceeding"===t.state||"blocked"===n.state&&"unblocked"===t.state||"proceeding"===n.state&&"unblocked"===t.state,"Invalid blocker state transition: "+n.state+" -> "+t.state);let r=new Map(A.blockers);r.set(e,t),we({blockers:r})}function it(e){let{currentLocation:t,nextLocation:n,historyAction:r}=e;if(0===be.size)return;be.size>1&&u(!1,"A router only supports one blocker at a time");let i=Array.from(be.entries()),[a,o]=i[i.length-1],s=A.blockers.get(a);return s&&"proceeding"===s.state?void 0:o({currentLocation:t,nextLocation:n,historyAction:r})?a:void 0}function at(e){let t=Ee(404,{pathname:e}),n=s||p,{matches:r,route:i}=Ce(n);return ot(),{notFoundMatches:r,route:i,error:t}}function ot(e){let t=[];return ye.forEach(((n,r)=>{e&&!e(r)||(n.cancel(),t.push(r),ye.delete(r))})),t}function st(e,t){if(E){return E(e,t.map((e=>function(e,t){let{route:n,pathname:r,params:i}=e;return{id:n.id,pathname:r,params:i,data:t[n.id],handle:n.handle}}(e,A.loaderData))))||e.key}return e.key}function lt(e,t){if(C){let n=st(e,t),r=C[n];if("number"===typeof r)return r}return null}function ut(e,t,n){if(x){if(!e){return{active:!0,matches:b(t,n,g,!0)||[]}}if(Object.keys(e[0].params).length>0){return{active:!0,matches:b(t,n,g,!0)}}}return{active:!1,matches:null}}async function ct(e,t,n,r){if(!x)return{type:"success",matches:e};let i=e;for(;;){let e=null==s,l=s||p,u=f;try{await x({signal:n,path:t,matches:i,fetcherKey:r,patch:(e,t)=>{n.aborted||ce(e,t,l,u,a)}})}catch(o){return{type:"error",error:o,partialMatches:i}}finally{e&&!n.aborted&&(p=[...p])}if(n.aborted)return{type:"aborted"};let c=y(l,t,g);if(c)return{type:"success",matches:c};let d=b(l,t,g,!0);if(!d||i.length===d.length&&i.every(((e,t)=>e.route.id===d[t].route.id)))return{type:"success",matches:null};i=d}}return h={get basename(){return g},get future(){return S},get state(){return A},get routes(){return p},get window(){return n},initialize:function(){if(k=e.history.listen((t=>{let{action:n,location:r,delta:i}=t;if(D)return D(),void(D=void 0);u(0===be.size||null!=i,"You are trying to use a blocker on a POP navigation to a location that was not created by @remix-run/router. This will fail silently in production. This can happen if you are navigating outside the router via `window.history.pushState`/`window.location.hash` instead of using router navigation APIs. This can also happen if you are using createHashRouter and the user manually changes the URL.");let a=it({currentLocation:A.location,nextLocation:r,historyAction:n});if(a&&null!=i){let t=new Promise((e=>{D=e}));return e.history.go(-1*i),void rt(a,{state:"blocked",location:r,proceed(){rt(a,{state:"proceeding",proceed:void 0,reset:void 0,location:r}),t.then((()=>e.history.go(i)))},reset(){let e=new Map(A.blockers);e.set(a,K),we({blockers:e})}})}return Me(n,r)})),r){!function(e,t){try{let n=e.sessionStorage.getItem(te);if(n){let e=JSON.parse(n);for(let[n,r]of Object.entries(e||{}))r&&Array.isArray(r)&&t.set(n,new Set(r||[]))}}catch(n){}}(n,F);let e=()=>function(e,t){if(t.size>0){let n={};for(let[e,r]of t)n[e]=[...r];try{e.sessionStorage.setItem(te,JSON.stringify(n))}catch(dy){u(!1,"Failed to save applied view transitions in sessionStorage ("+dy+").")}}}(n,F);n.addEventListener("pagehide",e),G=()=>n.removeEventListener("pagehide",e)}return A.initialized||Me(t.Pop,A.location,{initialHydration:!0}),h},subscribe:function(e){return _.add(e),()=>_.delete(e)},enableScrollRestoration:function(e,t,n){if(C=e,P=t,E=n||null,!L&&A.navigation===q){L=!0;let e=lt(A.location,A.matches);null!=e&&we({restoreScrollPosition:e})}return()=>{C=null,P=null,E=null}},navigate:async function n(r,i){if("number"===typeof r)return void e.history.go(r);let a=re(A.location,A.matches,g,S.v7_prependBasename,r,S.v7_relativeSplatPath,null==i?void 0:i.fromRouteId,null==i?void 0:i.relative),{path:s,submission:l,error:u}=ie(S.v7_normalizeFormMethod,!1,a,i),c=A.location,h=d(A.location,s,i&&i.state);h=o({},h,e.history.encodeLocation(h));let f=i&&null!=i.replace?i.replace:void 0,p=t.Push;!0===f?p=t.Replace:!1===f||null!=l&&Ie(l.formMethod)&&l.formAction===A.location.pathname+A.location.search&&(p=t.Replace);let m=i&&"preventScrollReset"in i?!0===i.preventScrollReset:void 0,v=!0===(i&&i.flushSync),y=it({currentLocation:c,nextLocation:h,historyAction:p});if(!y)return await Me(p,h,{submission:l,pendingError:u,preventScrollReset:m,replace:i&&i.replace,enableViewTransition:i&&i.viewTransition,flushSync:v});rt(y,{state:"blocked",location:h,proceed(){rt(y,{state:"proceeding",proceed:void 0,reset:void 0,location:h}),n(r,i)},reset(){let e=new Map(A.blockers);e.set(y,K),we({blockers:e})}})},fetch:function(t,n,r,a){if(i)throw new Error("router.fetch() was called during the server render, but it shouldn't be. You are likely calling a useFetcher() method in the body of your component. Try moving it to a useEffect or a callback.");Ke(t);let o=!0===(a&&a.flushSync),u=s||p,c=re(A.location,A.matches,g,S.v7_prependBasename,r,S.v7_relativeSplatPath,n,null==a?void 0:a.relative),d=y(u,c,g),h=ut(d,u,c);if(h.active&&h.matches&&(d=h.matches),!d)return void Je(t,n,Ee(404,{pathname:c}),{flushSync:o});let{path:f,submission:m,error:v}=ie(S.v7_normalizeFormMethod,!0,c,a);if(v)return void Je(t,n,v,{flushSync:o});let b=Be(d,f),w=!0===(a&&a.preventScrollReset);m&&Ie(m.formMethod)?async function(t,n,r,i,a,o,u,c,d){function h(e){if(!e.route.action&&!e.route.lazy){let e=Ee(405,{method:d.formMethod,pathname:r,routeId:n});return Je(t,n,e,{flushSync:u}),!0}return!1}if(Ye(),le.delete(t),!o&&h(i))return;let f=A.fetchers.get(t);Ve(t,function(e,t){let n={state:"submitting",formMethod:e.formMethod,formAction:e.formAction,formEncType:e.formEncType,formData:e.formData,json:e.json,text:e.text,data:t?t.data:void 0};return n}(d,f),{flushSync:u});let m=new AbortController,v=ve(e.history,r,m.signal,d);if(o){let e=await ct(a,new URL(v.url).pathname,v.signal,t);if("aborted"===e.type)return;if("error"===e.type)return void Je(t,n,e.error,{flushSync:u});if(!e.matches)return void Je(t,n,Ee(404,{pathname:r}),{flushSync:u});if(h(i=Be(a=e.matches,r)))return}X.set(t,m);let b=Y,w=await Ge("action",A,v,[i],a,t),x=w[i.route.id];if(v.signal.aborted)return void(X.get(t)===m&&X.delete(t));if(S.v7_fetcherPersist&&de.has(t)){if(Ne(x)||Re(x))return void Ve(t,$e(void 0))}else{if(Ne(x))return X.delete(t),V>b?void Ve(t,$e(void 0)):(ae.add(t),Ve(t,We(d)),Ae(v,x,!1,{fetcherSubmission:d,preventScrollReset:c}));if(Re(x))return void Je(t,n,x.error)}if(Oe(x))throw Ee(400,{type:"defer-action"});let k=A.navigation.location||A.location,_=ve(e.history,k,m.signal),C=s||p,E="idle"!==A.navigation.state?y(C,A.navigation.location,g):A.matches;l(E,"Didn't find any matches after fetcher action");let P=++Y;ne.set(t,P);let L=We(d,x.data);A.fetchers.set(t,L);let[T,O]=oe(e.history,A,E,d,k,!1,S.v7_skipActionErrorRevalidation,H,W,$,de,le,ae,C,g,[i.route.id,x]);O.filter((e=>e.key!==t)).forEach((e=>{let t=e.key,n=A.fetchers.get(t),r=We(void 0,n?n.data:void 0);A.fetchers.set(t,r),Ke(t),e.controller&&X.set(t,e.controller)})),we({fetchers:new Map(A.fetchers)});let R=()=>O.forEach((e=>Ke(e.key)));m.signal.addEventListener("abort",R);let{loaderResults:M,fetcherResults:D}=await Xe(A,E,T,O,_);if(m.signal.aborted)return;m.signal.removeEventListener("abort",R),ne.delete(t),X.delete(t),O.forEach((e=>X.delete(e.key)));let j=Pe(M);if(j)return Ae(_,j.result,!1,{preventScrollReset:c});if(j=Pe(D),j)return ae.add(j.key),Ae(_,j.result,!1,{preventScrollReset:c});let{loaderData:z,errors:F}=xe(A,E,M,void 0,O,D,ye);if(A.fetchers.has(t)){let e=$e(x.data);A.fetchers.set(t,e)}tt(P),"loading"===A.navigation.state&&P>V?(l(I,"Expected pending action"),N&&N.abort(),Le(A.navigation.location,{matches:E,loaderData:z,errors:F,fetchers:new Map(A.fetchers)})):(we({errors:F,loaderData:Se(A.loaderData,z,E,F),fetchers:new Map(A.fetchers)}),H=!1)}(t,n,f,b,d,h.active,o,w,m):(le.set(t,{routeId:n,path:f}),async function(t,n,r,i,a,o,s,u,c){let d=A.fetchers.get(t);Ve(t,We(c,d?d.data:void 0),{flushSync:s});let h=new AbortController,f=ve(e.history,r,h.signal);if(o){let e=await ct(a,new URL(f.url).pathname,f.signal,t);if("aborted"===e.type)return;if("error"===e.type)return void Je(t,n,e.error,{flushSync:s});if(!e.matches)return void Je(t,n,Ee(404,{pathname:r}),{flushSync:s});i=Be(a=e.matches,r)}X.set(t,h);let p=Y,m=await Ge("loader",A,f,[i],a,t),g=m[i.route.id];Oe(g)&&(g=await Fe(g,f.signal,!0)||g);X.get(t)===h&&X.delete(t);if(f.signal.aborted)return;if(de.has(t))return void Ve(t,$e(void 0));if(Ne(g))return V>p?void Ve(t,$e(void 0)):(ae.add(t),void await Ae(f,g,!1,{preventScrollReset:u}));if(Re(g))return void Je(t,n,g.error);l(!Oe(g),"Unhandled fetcher deferred data"),Ve(t,$e(g.data))}(t,n,f,b,d,h.active,o,w,m))},revalidate:function(){Ye(),we({revalidation:"loading"}),"submitting"!==A.navigation.state&&("idle"!==A.navigation.state?Me(I||A.historyAction,A.navigation.location,{overrideNavigation:A.navigation,enableViewTransition:!0===z}):Me(A.historyAction,A.location,{startUninterruptedRevalidation:!0}))},createHref:t=>e.history.createHref(t),encodeLocation:t=>e.history.encodeLocation(t),getFetcher:qe,deleteFetcher:function(e){let t=(ue.get(e)||0)-1;t<=0?(ue.delete(e),de.add(e),S.v7_fetcherPersist||Qe(e)):ue.set(e,t),we({fetchers:new Map(A.fetchers)})},dispose:function(){k&&k(),G&&G(),_.clear(),N&&N.abort(),A.fetchers.forEach(((e,t)=>Qe(t))),A.blockers.forEach(((e,t)=>nt(t)))},getBlocker:function(e,t){let n=A.blockers.get(e)||K;return be.get(e)!==t&&be.set(e,t),n},deleteBlocker:nt,patchRoutes:function(e,t){let n=null==s;ce(e,t,s||p,f,a),n&&(p=[...p],we({}))},_internalFetchControllers:X,_internalActiveDeferreds:ye,_internalSetRoutes:function(e){f={},s=v(e,a,void 0,f)}},h}Symbol("deferred");function re(e,t,n,r,i,a,o,s){let l,u;if(o){l=[];for(let e of t)if(l.push(e),e.route.id===o){u=e;break}}else l=t,u=t[t.length-1];let c=j(i||".",I(l,a),M(e.pathname,n)||e.pathname,"path"===s);if(null==i&&(c.search=e.search,c.hash=e.hash),(null==i||""===i||"."===i)&&u){let e=Ge(c.search);if(u.route.index&&!e)c.search=c.search?c.search.replace(/^\?/,"?index&"):"?index";else if(!u.route.index&&e){let e=new URLSearchParams(c.search),t=e.getAll("index");e.delete("index"),t.filter((e=>e)).forEach((t=>e.append("index",t)));let n=e.toString();c.search=n?"?"+n:""}}return r&&"/"!==n&&(c.pathname="/"===c.pathname?n:z([n,c.pathname])),h(c)}function ie(e,t,n,r){if(!r||!function(e){return null!=e&&("formData"in e&&null!=e.formData||"body"in e&&void 0!==e.body)}(r))return{path:n};if(r.formMethod&&!Ae(r.formMethod))return{path:n,error:Ee(405,{method:r.formMethod})};let i,a,o=()=>({path:n,error:Ee(400,{type:"invalid-body"})}),s=r.formMethod||"get",u=e?s.toUpperCase():s.toLowerCase(),c=Le(n);if(void 0!==r.body){if("text/plain"===r.formEncType){if(!Ie(u))return o();let e="string"===typeof r.body?r.body:r.body instanceof FormData||r.body instanceof URLSearchParams?Array.from(r.body.entries()).reduce(((e,t)=>{let[n,r]=t;return""+e+n+"="+r+"\n"}),""):String(r.body);return{path:n,submission:{formMethod:u,formAction:c,formEncType:r.formEncType,formData:void 0,json:void 0,text:e}}}if("application/json"===r.formEncType){if(!Ie(u))return o();try{let e="string"===typeof r.body?JSON.parse(r.body):r.body;return{path:n,submission:{formMethod:u,formAction:c,formEncType:r.formEncType,formData:void 0,json:e,text:void 0}}}catch(m){return o()}}}if(l("function"===typeof FormData,"FormData is not available in this environment"),r.formData)i=ye(r.formData),a=r.formData;else if(r.body instanceof FormData)i=ye(r.body),a=r.body;else if(r.body instanceof URLSearchParams)i=r.body,a=be(i);else if(null==r.body)i=new URLSearchParams,a=new FormData;else try{i=new URLSearchParams(r.body),a=be(i)}catch(m){return o()}let d={formMethod:u,formAction:c,formEncType:r&&r.formEncType||"application/x-www-form-urlencoded",formData:a,json:void 0,text:void 0};if(Ie(d.formMethod))return{path:n,submission:d};let p=f(n);return t&&p.search&&Ge(p.search)&&i.append("index",""),p.search="?"+i,{path:h(p),submission:d}}function ae(e,t,n){void 0===n&&(n=!1);let r=e.findIndex((e=>e.route.id===t));return r>=0?e.slice(0,n?r+1:r):e}function oe(e,t,n,r,i,a,s,l,u,c,d,h,f,p,m,g){let v=g?Re(g[1])?g[1].error:g[1].data:void 0,b=e.createURL(t.location),w=e.createURL(i),x=n;a&&t.errors?x=ae(n,Object.keys(t.errors)[0],!0):g&&Re(g[1])&&(x=ae(n,g[0]));let S=g?g[1].statusCode:void 0,k=s&&S&&S>=400,_=x.filter(((e,n)=>{let{route:i}=e;if(i.lazy)return!0;if(null==i.loader)return!1;if(a)return se(i,t.loaderData,t.errors);if(function(e,t,n){let r=!t||n.route.id!==t.route.id,i=void 0===e[n.route.id];return r||i}(t.loaderData,t.matches[n],e)||u.some((t=>t===e.route.id)))return!0;let s=t.matches[n],c=e;return ue(e,o({currentUrl:b,currentParams:s.params,nextUrl:w,nextParams:c.params},r,{actionResult:v,actionStatus:S,defaultShouldRevalidate:!k&&(l||b.pathname+b.search===w.pathname+w.search||b.search!==w.search||le(s,c))}))})),C=[];return h.forEach(((e,i)=>{if(a||!n.some((t=>t.route.id===e.routeId))||d.has(i))return;let s=y(p,e.path,m);if(!s)return void C.push({key:i,routeId:e.routeId,path:e.path,matches:null,match:null,controller:null});let u=t.fetchers.get(i),h=Be(s,e.path),g=!1;f.has(i)?g=!1:c.has(i)?(c.delete(i),g=!0):g=u&&"idle"!==u.state&&void 0===u.data?l:ue(h,o({currentUrl:b,currentParams:t.matches[t.matches.length-1].params,nextUrl:w,nextParams:n[n.length-1].params},r,{actionResult:v,actionStatus:S,defaultShouldRevalidate:!k&&l})),g&&C.push({key:i,routeId:e.routeId,path:e.path,matches:s,match:h,controller:new AbortController})})),[_,C]}function se(e,t,n){if(e.lazy)return!0;if(!e.loader)return!1;let r=null!=t&&void 0!==t[e.id],i=null!=n&&void 0!==n[e.id];return!(!r&&i)&&("function"===typeof e.loader&&!0===e.loader.hydrate||!r&&!i)}function le(e,t){let n=e.route.path;return e.pathname!==t.pathname||null!=n&&n.endsWith("*")&&e.params["*"]!==t.params["*"]}function ue(e,t){if(e.route.shouldRevalidate){let n=e.route.shouldRevalidate(t);if("boolean"===typeof n)return n}return t.defaultShouldRevalidate}function ce(e,t,n,r,i){var a;let o;if(e){let t=r[e];l(t,"No route found to patch children into: routeId = "+e),t.children||(t.children=[]),o=t.children}else o=n;let s=v(t.filter((e=>!o.some((t=>de(e,t))))),i,[e||"_","patch",String((null==(a=o)?void 0:a.length)||"0")],r);o.push(...s)}function de(e,t){return"id"in e&&"id"in t&&e.id===t.id||e.index===t.index&&e.path===t.path&&e.caseSensitive===t.caseSensitive&&(!(e.children&&0!==e.children.length||t.children&&0!==t.children.length)||e.children.every(((e,n)=>{var r;return null==(r=t.children)?void 0:r.some((t=>de(e,t)))})))}async function he(e){let{matches:t}=e,n=t.filter((e=>e.shouldLoad));return(await Promise.all(n.map((e=>e.resolve())))).reduce(((e,t,r)=>Object.assign(e,{[n[r].route.id]:t})),{})}async function fe(e,t,n,r,i,a,s,c,d,h){let f=a.map((e=>e.route.lazy?async function(e,t,n){if(!e.lazy)return;let r=await e.lazy();if(!e.lazy)return;let i=n[e.id];l(i,"No route found in manifest");let a={};for(let o in r){let e=void 0!==i[o]&&"hasErrorBoundary"!==o;u(!e,'Route "'+i.id+'" has a static property "'+o+'" defined but its lazy function is also returning a value for this property. The lazy route property "'+o+'" will be ignored.'),e||g.has(o)||(a[o]=r[o])}Object.assign(i,a),Object.assign(i,o({},t(i),{lazy:void 0}))}(e.route,d,c):void 0)),p=a.map(((e,n)=>{let a=f[n],s=i.some((t=>t.route.id===e.route.id));return o({},e,{shouldLoad:s,resolve:async n=>(n&&"GET"===r.method&&(e.route.lazy||e.route.loader)&&(s=!0),s?async function(e,t,n,r,i,a){let o,s,u=r=>{let o,l=new Promise(((e,t)=>o=t));s=()=>o(),t.signal.addEventListener("abort",s);let u=i=>"function"!==typeof r?Promise.reject(new Error('You cannot call the handler for a route which defines a boolean "'+e+'" [routeId: '+n.route.id+"]")):r({request:t,params:n.params,context:a},...void 0!==i?[i]:[]),c=(async()=>{try{let e=await(i?i((e=>u(e))):u());return{type:"data",result:e}}catch(e){return{type:"error",result:e}}})();return Promise.race([c,l])};try{let i=n.route[e];if(r)if(i){let e,[t]=await Promise.all([u(i).catch((t=>{e=t})),r]);if(void 0!==e)throw e;o=t}else{if(await r,i=n.route[e],!i){if("action"===e){let e=new URL(t.url),r=e.pathname+e.search;throw Ee(405,{method:t.method,pathname:r,routeId:n.route.id})}return{type:m.data,result:void 0}}o=await u(i)}else{if(!i){let e=new URL(t.url);throw Ee(404,{pathname:e.pathname+e.search})}o=await u(i)}l(void 0!==o.result,"You defined "+("action"===e?"an action":"a loader")+' for route "'+n.route.id+"\" but didn't return anything from your `"+e+"` function. Please return a value or `null`.")}catch(c){return{type:m.error,result:c}}finally{s&&t.signal.removeEventListener("abort",s)}return o}(t,r,e,a,n,h):Promise.resolve({type:m.data,result:void 0}))})})),v=await e({matches:p,request:r,params:a[0].params,fetcherKey:s,context:h});try{await Promise.all(f)}catch(y){}return v}async function pe(e){let{result:t,type:n}=e;if(De(t)){let e;try{let n=t.headers.get("Content-Type");e=n&&/\bapplication\/json\b/.test(n)?null==t.body?null:await t.json():await t.text()}catch(d){return{type:m.error,error:d}}return n===m.error?{type:m.error,error:new H(t.status,t.statusText,e),statusCode:t.status,headers:t.headers}:{type:m.data,data:e,statusCode:t.status,headers:t.headers}}var r,i,a,o,s,l,u,c;return n===m.error?Me(t)?t.data instanceof Error?{type:m.error,error:t.data,statusCode:null==(a=t.init)?void 0:a.status,headers:null!=(o=t.init)&&o.headers?new Headers(t.init.headers):void 0}:{type:m.error,error:new H((null==(r=t.init)?void 0:r.status)||500,void 0,t.data),statusCode:U(t)?t.status:void 0,headers:null!=(i=t.init)&&i.headers?new Headers(t.init.headers):void 0}:{type:m.error,error:t,statusCode:U(t)?t.status:void 0}:function(e){let t=e;return t&&"object"===typeof t&&"object"===typeof t.data&&"function"===typeof t.subscribe&&"function"===typeof t.cancel&&"function"===typeof t.resolveData}(t)?{type:m.deferred,deferredData:t,statusCode:null==(s=t.init)?void 0:s.status,headers:(null==(l=t.init)?void 0:l.headers)&&new Headers(t.init.headers)}:Me(t)?{type:m.data,data:t.data,statusCode:null==(u=t.init)?void 0:u.status,headers:null!=(c=t.init)&&c.headers?new Headers(t.init.headers):void 0}:{type:m.data,data:t}}function me(e,t,n,r,i,a){let o=e.headers.get("Location");if(l(o,"Redirects returned/thrown from loaders/actions must have a Location header"),!Z.test(o)){let s=r.slice(0,r.findIndex((e=>e.route.id===n))+1);o=re(new URL(t.url),s,i,!0,o,a),e.headers.set("Location",o)}return e}function ge(e,t,n){if(Z.test(e)){let r=e,i=r.startsWith("//")?new URL(t.protocol+r):new URL(r),a=null!=M(i.pathname,n);if(i.origin===t.origin&&a)return i.pathname+i.search+i.hash}return e}function ve(e,t,n,r){let i=e.createURL(Le(t)).toString(),a={signal:n};if(r&&Ie(r.formMethod)){let{formMethod:e,formEncType:t}=r;a.method=e.toUpperCase(),"application/json"===t?(a.headers=new Headers({"Content-Type":t}),a.body=JSON.stringify(r.json)):"text/plain"===t?a.body=r.text:"application/x-www-form-urlencoded"===t&&r.formData?a.body=ye(r.formData):a.body=r.formData}return new Request(i,a)}function ye(e){let t=new URLSearchParams;for(let[n,r]of e.entries())t.append(n,"string"===typeof r?r:r.name);return t}function be(e){let t=new FormData;for(let[n,r]of e.entries())t.append(n,r);return t}function we(e,t,n,r,i){let a,o={},s=null,u=!1,c={},d=n&&Re(n[1])?n[1].error:void 0;return e.forEach((n=>{if(!(n.route.id in t))return;let h=n.route.id,f=t[h];if(l(!Ne(f),"Cannot handle redirect results in processLoaderData"),Re(f)){let t=f.error;if(void 0!==d&&(t=d,d=void 0),s=s||{},i)s[h]=t;else{let n=_e(e,h);null==s[n.route.id]&&(s[n.route.id]=t)}o[h]=void 0,u||(u=!0,a=U(f.error)?f.error.status:500),f.headers&&(c[h]=f.headers)}else Oe(f)?(r.set(h,f.deferredData),o[h]=f.deferredData.data,null==f.statusCode||200===f.statusCode||u||(a=f.statusCode),f.headers&&(c[h]=f.headers)):(o[h]=f.data,f.statusCode&&200!==f.statusCode&&!u&&(a=f.statusCode),f.headers&&(c[h]=f.headers))})),void 0!==d&&n&&(s={[n[0]]:d},o[n[0]]=void 0),{loaderData:o,errors:s,statusCode:a||200,loaderHeaders:c}}function xe(e,t,n,r,i,a,s){let{loaderData:u,errors:c}=we(t,n,r,s,!1);return i.forEach((t=>{let{key:n,match:r,controller:i}=t,s=a[n];if(l(s,"Did not find corresponding fetcher result"),!i||!i.signal.aborted)if(Re(s)){let t=_e(e.matches,null==r?void 0:r.route.id);c&&c[t.route.id]||(c=o({},c,{[t.route.id]:s.error})),e.fetchers.delete(n)}else if(Ne(s))l(!1,"Unhandled fetcher revalidation redirect");else if(Oe(s))l(!1,"Unhandled fetcher deferred data");else{let t=$e(s.data);e.fetchers.set(n,t)}})),{loaderData:u,errors:c}}function Se(e,t,n,r){let i=o({},t);for(let a of n){let n=a.route.id;if(t.hasOwnProperty(n)?void 0!==t[n]&&(i[n]=t[n]):void 0!==e[n]&&a.route.loader&&(i[n]=e[n]),r&&r.hasOwnProperty(n))break}return i}function ke(e){return e?Re(e[1])?{actionData:{}}:{actionData:{[e[0]]:e[1].data}}:{}}function _e(e,t){return(t?e.slice(0,e.findIndex((e=>e.route.id===t))+1):[...e]).reverse().find((e=>!0===e.route.hasErrorBoundary))||e[0]}function Ce(e){let t=1===e.length?e[0]:e.find((e=>e.index||!e.path||"/"===e.path))||{id:"__shim-error-route__"};return{matches:[{params:{},pathname:"",pathnameBase:"",route:t}],route:t}}function Ee(e,t){let{pathname:n,routeId:r,method:i,type:a,message:o}=void 0===t?{}:t,s="Unknown Server Error",l="Unknown @remix-run/router error";return 400===e?(s="Bad Request",i&&n&&r?l="You made a "+i+' request to "'+n+'" but did not provide a `loader` for route "'+r+'", so there is no way to handle the request.':"defer-action"===a?l="defer() is not supported in actions":"invalid-body"===a&&(l="Unable to encode submission body")):403===e?(s="Forbidden",l='Route "'+r+'" does not match URL "'+n+'"'):404===e?(s="Not Found",l='No route matches URL "'+n+'"'):405===e&&(s="Method Not Allowed",i&&n&&r?l="You made a "+i.toUpperCase()+' request to "'+n+'" but did not provide an `action` for route "'+r+'", so there is no way to handle the request.':i&&(l='Invalid request method "'+i.toUpperCase()+'"')),new H(e||500,s,new Error(l),!0)}function Pe(e){let t=Object.entries(e);for(let n=t.length-1;n>=0;n--){let[e,r]=t[n];if(Ne(r))return{key:e,result:r}}}function Le(e){return h(o({},"string"===typeof e?f(e):e,{hash:""}))}function Te(e){return De(e.result)&&V.has(e.result.status)}function Oe(e){return e.type===m.deferred}function Re(e){return e.type===m.error}function Ne(e){return(e&&e.type)===m.redirect}function Me(e){return"object"===typeof e&&null!=e&&"type"in e&&"data"in e&&"init"in e&&"DataWithResponseInit"===e.type}function De(e){return null!=e&&"number"===typeof e.status&&"string"===typeof e.statusText&&"object"===typeof e.headers&&"undefined"!==typeof e.body}function Ae(e){return Y.has(e.toLowerCase())}function Ie(e){return $.has(e.toLowerCase())}async function je(e,t,n,r,i){let a=Object.entries(t);for(let o=0;o(null==e?void 0:e.route.id)===s));if(!u)continue;let c=r.find((e=>e.route.id===u.route.id)),d=null!=c&&!le(c,u)&&void 0!==(i&&i[u.route.id]);Oe(l)&&d&&await Fe(l,n,!1).then((e=>{e&&(t[s]=e)}))}}async function ze(e,t,n){for(let r=0;r(null==e?void 0:e.route.id)===a))&&(Oe(s)&&(l(o,"Expected an AbortController for revalidating fetcher deferred result"),await Fe(s,o.signal,!0).then((e=>{e&&(t[i]=e)}))))}}async function Fe(e,t,n){if(void 0===n&&(n=!1),!await e.deferredData.resolveData(t)){if(n)try{return{type:m.data,data:e.deferredData.unwrappedData}}catch(r){return{type:m.error,error:r}}return{type:m.data,data:e.deferredData.data}}}function Ge(e){return new URLSearchParams(e).getAll("index").some((e=>""===e))}function Be(e,t){let n="string"===typeof t?f(t).search:t.search;if(e[e.length-1].route.index&&Ge(n||""))return e[e.length-1];let r=A(e);return r[r.length-1]}function He(e){let{formMethod:t,formAction:n,formEncType:r,text:i,formData:a,json:o}=e;if(t&&n&&r)return null!=i?{formMethod:t,formAction:n,formEncType:r,formData:void 0,json:void 0,text:i}:null!=a?{formMethod:t,formAction:n,formEncType:r,formData:a,json:void 0,text:void 0}:void 0!==o?{formMethod:t,formAction:n,formEncType:r,formData:void 0,json:o,text:void 0}:void 0}function Ue(e,t){if(t){return{state:"loading",location:e,formMethod:t.formMethod,formAction:t.formAction,formEncType:t.formEncType,formData:t.formData,json:t.json,text:t.text}}return{state:"loading",location:e,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0}}function We(e,t){if(e){return{state:"loading",formMethod:e.formMethod,formAction:e.formAction,formEncType:e.formEncType,formData:e.formData,json:e.json,text:e.text,data:t}}return{state:"loading",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:t}}function $e(e){return{state:"idle",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:e}}function Xe(){return Xe=Object.assign?Object.assign.bind():function(e){for(var t=1;t{n.current=!0}));let i=r.useCallback((function(r,i){void 0===i&&(i={}),n.current&&("number"===typeof r?e.navigate(r):e.navigate(r,Xe({fromRouteId:t},i)))}),[e,t]);return i}():function(){Ze()||l(!1);let e=r.useContext(Ye),{basename:t,future:n,navigator:i}=r.useContext(Je),{matches:a}=r.useContext(Qe),{pathname:o}=et(),s=JSON.stringify(I(a,n.v7_relativeSplatPath)),u=r.useRef(!1);tt((()=>{u.current=!0}));let c=r.useCallback((function(n,r){if(void 0===r&&(r={}),!u.current)return;if("number"===typeof n)return void i.go(n);let a=j(n,JSON.parse(s),o,"path"===r.relative);null==e&&"/"!==t&&(a.pathname="/"===a.pathname?t:z([t,a.pathname])),(r.replace?i.replace:i.push)(a,r.state,r)}),[t,i,s,o,e]);return c}()}const rt=r.createContext(null);function it(e,n,i,a){Ze()||l(!1);let{navigator:o,static:s}=r.useContext(Je),{matches:u}=r.useContext(Qe),c=u[u.length-1],d=c?c.params:{},h=(c&&c.pathname,c?c.pathnameBase:"/");c&&c.route;let p,m=et();if(n){var g;let e="string"===typeof n?f(n):n;"/"===h||(null==(g=e.pathname)?void 0:g.startsWith(h))||l(!1),p=e}else p=m;let v=p.pathname||"/",b=v;if("/"!==h){let e=h.replace(/^\//,"").split("/");b="/"+v.replace(/^\//,"").split("/").slice(e.length).join("/")}let w=!s&&i&&i.matches&&i.matches.length>0?i.matches:y(e,{pathname:b});let x=ut(w&&w.map((e=>Object.assign({},e,{params:Object.assign({},d,e.params),pathname:z([h,o.encodeLocation?o.encodeLocation(e.pathname).pathname:e.pathname]),pathnameBase:"/"===e.pathnameBase?h:z([h,o.encodeLocation?o.encodeLocation(e.pathnameBase).pathname:e.pathnameBase])}))),u,i,a);return n&&x?r.createElement(qe.Provider,{value:{location:Xe({pathname:"/",search:"",hash:"",state:null,key:"default"},p),navigationType:t.Pop}},x):x}function at(){let e=function(){var e;let t=r.useContext(Ke),n=ft(dt.UseRouteError),i=pt(dt.UseRouteError);if(void 0!==t)return t;return null==(e=n.errors)?void 0:e[i]}(),t=U(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,i="rgba(200,200,200, 0.5)",a={padding:"0.5rem",backgroundColor:i};return r.createElement(r.Fragment,null,r.createElement("h2",null,"Unexpected Application Error!"),r.createElement("h3",{style:{fontStyle:"italic"}},t),n?r.createElement("pre",{style:a},n):null,null)}const ot=r.createElement(at,null);class st extends r.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?r.createElement(Qe.Provider,{value:this.props.routeContext},r.createElement(Ke.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function lt(e){let{routeContext:t,match:n,children:i}=e,a=r.useContext(Ye);return a&&a.static&&a.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(a.staticContext._deepestRenderedBoundaryId=n.route.id),r.createElement(Qe.Provider,{value:t},i)}function ut(e,t,n,i){var a;if(void 0===t&&(t=[]),void 0===n&&(n=null),void 0===i&&(i=null),null==e){var o;if(!n)return null;if(n.errors)e=n.matches;else{if(!(null!=(o=i)&&o.v7_partialHydration&&0===t.length&&!n.initialized&&n.matches.length>0))return null;e=n.matches}}let s=e,u=null==(a=n)?void 0:a.errors;if(null!=u){let e=s.findIndex((e=>e.route.id&&void 0!==(null==u?void 0:u[e.route.id])));e>=0||l(!1),s=s.slice(0,Math.min(s.length,e+1))}let c=!1,d=-1;if(n&&i&&i.v7_partialHydration)for(let r=0;r=0?s.slice(0,d+1):[s[0]];break}}}return s.reduceRight(((e,i,a)=>{let o,l=!1,h=null,f=null;var p;n&&(o=u&&i.route.id?u[i.route.id]:void 0,h=i.route.errorElement||ot,c&&(d<0&&0===a?(p="route-fallback",!1||mt[p]||(mt[p]=!0),l=!0,f=null):d===a&&(l=!0,f=i.route.hydrateFallbackElement||null)));let m=t.concat(s.slice(0,a+1)),g=()=>{let t;return t=o?h:l?f:i.route.Component?r.createElement(i.route.Component,null):i.route.element?i.route.element:e,r.createElement(lt,{match:i,routeContext:{outlet:e,matches:m,isDataRoute:null!=n},children:t})};return n&&(i.route.ErrorBoundary||i.route.errorElement||0===a)?r.createElement(st,{location:n.location,revalidation:n.revalidation,component:h,error:o,children:g(),routeContext:{outlet:null,matches:m,isDataRoute:!0}}):g()}),null)}var ct=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(ct||{}),dt=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}(dt||{});function ht(e){let t=r.useContext(Ye);return t||l(!1),t}function ft(e){let t=r.useContext(Ve);return t||l(!1),t}function pt(e){let t=function(){let e=r.useContext(Qe);return e||l(!1),e}(),n=t.matches[t.matches.length-1];return n.route.id||l(!1),n.route.id}const mt={};function gt(e,t){null==e||e.v7_startTransition,void 0===(null==e?void 0:e.v7_relativeSplatPath)&&(!t||t.v7_relativeSplatPath),t&&(t.v7_fetcherPersist,t.v7_normalizeFormMethod,t.v7_partialHydration,t.v7_skipActionErrorRevalidation)}i.startTransition;function vt(e){let{to:t,replace:n,state:i,relative:a}=e;Ze()||l(!1);let{future:o,static:s}=r.useContext(Je),{matches:u}=r.useContext(Qe),{pathname:c}=et(),d=nt(),h=j(t,I(u,o.v7_relativeSplatPath),c,"path"===a),f=JSON.stringify(h);return r.useEffect((()=>d(JSON.parse(f),{replace:n,state:i,relative:a})),[d,f,a,n,i]),null}function yt(e){return function(e){let t=r.useContext(Qe).outlet;return t?r.createElement(rt.Provider,{value:e},t):t}(e.context)}function bt(e){l(!1)}function wt(e){let{basename:n="/",children:i=null,location:a,navigationType:o=t.Pop,navigator:s,static:u=!1,future:c}=e;Ze()&&l(!1);let d=n.replace(/^\/*/,"/"),h=r.useMemo((()=>({basename:d,navigator:s,static:u,future:Xe({v7_relativeSplatPath:!1},c)})),[d,c,s,u]);"string"===typeof a&&(a=f(a));let{pathname:p="/",search:m="",hash:g="",state:v=null,key:y="default"}=a,b=r.useMemo((()=>{let e=M(p,d);return null==e?null:{location:{pathname:e,search:m,hash:g,state:v,key:y},navigationType:o}}),[d,p,m,g,v,y,o]);return null==b?null:r.createElement(Je.Provider,{value:h},r.createElement(qe.Provider,{children:i,value:b}))}new Promise((()=>{}));r.Component;function xt(e,t){void 0===t&&(t=[]);let n=[];return r.Children.forEach(e,((e,i)=>{if(!r.isValidElement(e))return;let a=[...t,i];if(e.type===r.Fragment)return void n.push.apply(n,xt(e.props.children,a));e.type!==bt&&l(!1),e.props.index&&e.props.children&&l(!1);let o={id:e.props.id||a.join("-"),caseSensitive:e.props.caseSensitive,element:e.props.element,Component:e.props.Component,index:e.props.index,path:e.props.path,loader:e.props.loader,action:e.props.action,errorElement:e.props.errorElement,ErrorBoundary:e.props.ErrorBoundary,hasErrorBoundary:null!=e.props.ErrorBoundary||null!=e.props.errorElement,shouldRevalidate:e.props.shouldRevalidate,handle:e.props.handle,lazy:e.props.lazy};e.props.children&&(o.children=xt(e.props.children,a)),n.push(o)})),n}function St(e){let t={hasErrorBoundary:null!=e.ErrorBoundary||null!=e.errorElement};return e.Component&&Object.assign(t,{element:r.createElement(e.Component),Component:void 0}),e.HydrateFallback&&Object.assign(t,{hydrateFallbackElement:r.createElement(e.HydrateFallback),HydrateFallback:void 0}),e.ErrorBoundary&&Object.assign(t,{errorElement:r.createElement(e.ErrorBoundary),ErrorBoundary:void 0}),t}const kt=!("undefined"===typeof window||"undefined"===typeof document||!window.document||!window.document.createElement);function _t(e,t){const n=e;for(const r in t)t.hasOwnProperty(r)&&(n[r]=t[r]);return n}kt&&document.addEventListener("touchstart",(()=>{}),!0);var Ct=n(738),Et=n.n(Ct);function Pt(e,t){const n=Object.assign({},t.props);e.className&&(n.className=Et()(t.props.className,e.className)),e.style&&(n.style=Object.assign(Object.assign({},n.style),e.style)),void 0!==e.tabIndex&&(n.tabIndex=e.tabIndex);for(const r in e)e.hasOwnProperty(r)&&(r.startsWith("data-")||r.startsWith("aria-"))&&(n[r]=e[r]);return r.cloneElement(t,n)}function Lt(){const e={};for(var t=arguments.length,n=new Array(t),r=0;r{t&&Object.keys(t).forEach((n=>{void 0!==t[n]&&(e[n]=t[n])}))})),e}function Tt(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r=0;i-=1)if(void 0!==n[i])return n[i];return e}const Ot=!("undefined"===typeof window||!window.document||!window.document.createElement);const Rt=Ot?r.useLayoutEffect:r.useEffect;const Nt=function(){var e=(0,r.useRef)(!1);return(0,r.useEffect)((function(){return e.current=!1,function(){e.current=!0}}),[]),e};const Mt=kt?window:void 0,Dt=["scroll","auto","overlay"];function At(e){return 1===e.nodeType}function It(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Mt,n=e;for(;n&&n!==t&&At(n);){if(n===document.body)return t;const{overflowY:e}=window.getComputedStyle(n);if(Dt.includes(e)&&n.scrollHeight>n.clientHeight)return n;n=n.parentNode}return t}let jt=!1;if(kt)try{const e={};Object.defineProperty(e,"passive",{get(){jt=!0}}),window.addEventListener("test-passive",null,e)}catch(rw){}let zt=0;const Ft="adm-overflow-hidden";function Gt(e,t){const n=function(){const e=(0,r.useRef)(0),t=(0,r.useRef)(0),n=(0,r.useRef)(0),i=(0,r.useRef)(0),a=(0,r.useRef)(0),o=(0,r.useRef)(0),s=(0,r.useRef)(""),l=()=>{n.current=0,i.current=0,a.current=0,o.current=0,s.current=""};return{move:r=>{const l=r.touches[0];var u,c;n.current=l.clientX<0?0:l.clientX-e.current,i.current=l.clientY-t.current,a.current=Math.abs(n.current),o.current=Math.abs(i.current),s.current||(s.current=(u=a.current)>(c=o.current)&&u>10?"horizontal":c>u&&c>10?"vertical":"")},start:n=>{l(),e.current=n.touches[0].clientX,t.current=n.touches[0].clientY},reset:l,startX:e,startY:t,deltaX:n,deltaY:i,offsetX:a,offsetY:o,direction:s,isVertical:()=>"vertical"===s.current,isHorizontal:()=>"horizontal"===s.current}}(),i=r=>{n.move(r);const i=n.deltaY.current>0?"10":"01",a=It(r.target,e.current);if(!a)return;if("strict"===t){const e=function(e){let t=null===e||void 0===e?void 0:e.parentElement;for(;t;){if(t.clientHeight=o?"00":"01":o<=Math.round(u+l)&&(c="10"),"11"===c||!n.isVertical()||parseInt(c,2)&parseInt(i,2)||r.cancelable&&jt&&r.preventDefault()};(0,r.useEffect)((()=>{if(t)return document.addEventListener("touchstart",n.start),document.addEventListener("touchmove",i,!!jt&&{passive:!1}),zt||document.body.classList.add(Ft),zt++,()=>{zt&&(document.removeEventListener("touchstart",n.start),document.removeEventListener("touchmove",i),zt--,zt||document.body.classList.remove(Ft))}}),[t])}let Bt=rn();const Ht=e=>Zt(e,Bt);let Ut=rn();Ht.write=e=>Zt(e,Ut);let Wt=rn();Ht.onStart=e=>Zt(e,Wt);let $t=rn();Ht.onFrame=e=>Zt(e,$t);let Xt=rn();Ht.onFinish=e=>Zt(e,Xt);let Yt=[];Ht.setTimeout=(e,t)=>{let n=Ht.now()+t,r=()=>{let e=Yt.findIndex((e=>e.cancel==r));~e&&Yt.splice(e,1),Qt-=~e?1:0},i={time:n,handler:e,cancel:r};return Yt.splice(Vt(n),0,i),Qt+=1,en(),i};let Vt=e=>~(~Yt.findIndex((t=>t.time>e))||~Yt.length);Ht.cancel=e=>{Wt.delete(e),$t.delete(e),Xt.delete(e),Bt.delete(e),Ut.delete(e)},Ht.sync=e=>{Kt=!0,Ht.batchedUpdates(e),Kt=!1},Ht.throttle=e=>{let t;function n(){try{e(...t)}finally{t=null}}function r(){for(var e=arguments.length,r=new Array(e),i=0;i{Wt.delete(n),t=null},r};let Jt="undefined"!=typeof window?window.requestAnimationFrame:()=>{};Ht.use=e=>Jt=e,Ht.now="undefined"!=typeof performance?()=>performance.now():Date.now,Ht.batchedUpdates=e=>e(),Ht.catch=console.error,Ht.frameLoop="always",Ht.advance=()=>{"demand"!==Ht.frameLoop?console.warn("Cannot call the manual advancement of rafz whilst frameLoop is not set as demand"):nn()};let qt=-1,Qt=0,Kt=!1;function Zt(e,t){Kt?(t.delete(e),e(0)):(t.add(e),en())}function en(){qt<0&&(qt=0,"demand"!==Ht.frameLoop&&Jt(tn))}function tn(){~qt&&(Jt(tn),Ht.batchedUpdates(nn))}function nn(){let e=qt;qt=Ht.now();let t=Vt(qt);t&&(an(Yt.splice(0,t),(e=>e.handler())),Qt-=t),Qt?(Wt.flush(),Bt.flush(e?Math.min(64,qt-e):16.667),$t.flush(),Ut.flush(),Xt.flush()):qt=-1}function rn(){let e=new Set,t=e;return{add(n){Qt+=t!=e||e.has(n)?0:1,e.add(n)},delete:n=>(Qt-=t==e&&e.has(n)?1:0,e.delete(n)),flush(n){t.size&&(e=new Set,Qt-=t.size,an(t,(t=>t(n)&&e.add(t))),Qt+=e.size,t=e)}}}function an(e,t){e.forEach((e=>{try{t(e)}catch(rw){Ht.catch(rw)}}))}function on(){}const sn={arr:Array.isArray,obj:e=>!!e&&"Object"===e.constructor.name,fun:e=>"function"===typeof e,str:e=>"string"===typeof e,num:e=>"number"===typeof e,und:e=>void 0===e};function ln(e,t){if(sn.arr(e)){if(!sn.arr(t)||e.length!==t.length)return!1;for(let n=0;n