diff --git a/README.md b/README.md index f6f1ef7..d21960e 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ # Handyman Service App Design - This is a code bundle for Handyman Service App Design. The original project is available at https://www.figma.com/design/2MbddGTyLvqoOQ5CFN4poP/Handyman-Service-App-Design. + This is a code bundle for Handyman Service App Design. The main idea is to create a figma website and deploy it in a few hours. ## Running the code diff --git a/dist/assets/index-Bj-KDMGO.js b/dist/assets/index-Bj-KDMGO.js new file mode 100644 index 0000000..2e0b797 --- /dev/null +++ b/dist/assets/index-Bj-KDMGO.js @@ -0,0 +1,182 @@ +function ap(l,a){for(var o=0;ou[c]})}}}return Object.freeze(Object.defineProperty(l,Symbol.toStringTag,{value:"Module"}))}(function(){const a=document.createElement("link").relList;if(a&&a.supports&&a.supports("modulepreload"))return;for(const c of document.querySelectorAll('link[rel="modulepreload"]'))u(c);new MutationObserver(c=>{for(const d of c)if(d.type==="childList")for(const p of d.addedNodes)p.tagName==="LINK"&&p.rel==="modulepreload"&&u(p)}).observe(document,{childList:!0,subtree:!0});function o(c){const d={};return c.integrity&&(d.integrity=c.integrity),c.referrerPolicy&&(d.referrerPolicy=c.referrerPolicy),c.crossOrigin==="use-credentials"?d.credentials="include":c.crossOrigin==="anonymous"?d.credentials="omit":d.credentials="same-origin",d}function u(c){if(c.ep)return;c.ep=!0;const d=o(c);fetch(c.href,d)}})();function op(l){return l&&l.__esModule&&Object.prototype.hasOwnProperty.call(l,"default")?l.default:l}var as={exports:{}},Vl={},os={exports:{}},Ee={};/** + * @license React + * react.production.min.js + * + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */var ld;function sp(){if(ld)return Ee;ld=1;var l=Symbol.for("react.element"),a=Symbol.for("react.portal"),o=Symbol.for("react.fragment"),u=Symbol.for("react.strict_mode"),c=Symbol.for("react.profiler"),d=Symbol.for("react.provider"),p=Symbol.for("react.context"),m=Symbol.for("react.forward_ref"),y=Symbol.for("react.suspense"),x=Symbol.for("react.memo"),j=Symbol.for("react.lazy"),E=Symbol.iterator;function M(N){return N===null||typeof N!="object"?null:(N=E&&N[E]||N["@@iterator"],typeof N=="function"?N:null)}var T={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},b=Object.assign,U={};function A(N,D,ce){this.props=N,this.context=D,this.refs=U,this.updater=ce||T}A.prototype.isReactComponent={},A.prototype.setState=function(N,D){if(typeof N!="object"&&typeof N!="function"&&N!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,N,D,"setState")},A.prototype.forceUpdate=function(N){this.updater.enqueueForceUpdate(this,N,"forceUpdate")};function G(){}G.prototype=A.prototype;function B(N,D,ce){this.props=N,this.context=D,this.refs=U,this.updater=ce||T}var re=B.prototype=new G;re.constructor=B,b(re,A.prototype),re.isPureReactComponent=!0;var we=Array.isArray,ge=Object.prototype.hasOwnProperty,Ne={current:null},z={key:!0,ref:!0,__self:!0,__source:!0};function ae(N,D,ce){var fe,de={},ve=null,Te=null;if(D!=null)for(fe in D.ref!==void 0&&(Te=D.ref),D.key!==void 0&&(ve=""+D.key),D)ge.call(D,fe)&&!z.hasOwnProperty(fe)&&(de[fe]=D[fe]);var Ce=arguments.length-2;if(Ce===1)de.children=ce;else if(1>>1,D=H[N];if(0>>1;Nc(de,Y))vec(Te,de)?(H[N]=Te,H[ve]=Y,N=ve):(H[N]=de,H[fe]=Y,N=fe);else if(vec(Te,Y))H[N]=Te,H[ve]=Y,N=ve;else break e}}return X}function c(H,X){var Y=H.sortIndex-X.sortIndex;return Y!==0?Y:H.id-X.id}if(typeof performance=="object"&&typeof performance.now=="function"){var d=performance;l.unstable_now=function(){return d.now()}}else{var p=Date,m=p.now();l.unstable_now=function(){return p.now()-m}}var y=[],x=[],j=1,E=null,M=3,T=!1,b=!1,U=!1,A=typeof setTimeout=="function"?setTimeout:null,G=typeof clearTimeout=="function"?clearTimeout:null,B=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function re(H){for(var X=o(x);X!==null;){if(X.callback===null)u(x);else if(X.startTime<=H)u(x),X.sortIndex=X.expirationTime,a(y,X);else break;X=o(x)}}function we(H){if(U=!1,re(H),!b)if(o(y)!==null)b=!0,Se(ge);else{var X=o(x);X!==null&&ye(we,X.startTime-H)}}function ge(H,X){b=!1,U&&(U=!1,G(ae),ae=-1),T=!0;var Y=M;try{for(re(X),E=o(y);E!==null&&(!(E.expirationTime>X)||H&&!_e());){var N=E.callback;if(typeof N=="function"){E.callback=null,M=E.priorityLevel;var D=N(E.expirationTime<=X);X=l.unstable_now(),typeof D=="function"?E.callback=D:E===o(y)&&u(y),re(X)}else u(y);E=o(y)}if(E!==null)var ce=!0;else{var fe=o(x);fe!==null&&ye(we,fe.startTime-X),ce=!1}return ce}finally{E=null,M=Y,T=!1}}var Ne=!1,z=null,ae=-1,he=5,ke=-1;function _e(){return!(l.unstable_now()-keH||125N?(H.sortIndex=Y,a(x,H),o(y)===null&&H===o(x)&&(U?(G(ae),ae=-1):U=!0,ye(we,Y-N))):(H.sortIndex=D,a(y,H),b||T||(b=!0,Se(ge))),H},l.unstable_shouldYield=_e,l.unstable_wrapCallback=function(H){var X=M;return function(){var Y=M;M=X;try{return H.apply(this,arguments)}finally{M=Y}}}})(cs)),cs}var ud;function fp(){return ud||(ud=1,us.exports=dp()),us.exports}/** + * @license React + * react-dom.production.min.js + * + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */var cd;function hp(){if(cd)return Pt;cd=1;var l=Ss(),a=fp();function o(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,r=1;r"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),y=Object.prototype.hasOwnProperty,x=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,j={},E={};function M(e){return y.call(E,e)?!0:y.call(j,e)?!1:x.test(e)?E[e]=!0:(j[e]=!0,!1)}function T(e,t,r,n){if(r!==null&&r.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return n?!1:r!==null?!r.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function b(e,t,r,n){if(t===null||typeof t>"u"||T(e,t,r,n))return!0;if(n)return!1;if(r!==null)switch(r.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function U(e,t,r,n,i,s,f){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=n,this.attributeNamespace=i,this.mustUseProperty=r,this.propertyName=e,this.type=t,this.sanitizeURL=s,this.removeEmptyString=f}var A={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){A[e]=new U(e,0,!1,e,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];A[t]=new U(t,1,!1,e[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(e){A[e]=new U(e,2,!1,e.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){A[e]=new U(e,2,!1,e,null,!1,!1)}),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){A[e]=new U(e,3,!1,e.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(e){A[e]=new U(e,3,!0,e,null,!1,!1)}),["capture","download"].forEach(function(e){A[e]=new U(e,4,!1,e,null,!1,!1)}),["cols","rows","size","span"].forEach(function(e){A[e]=new U(e,6,!1,e,null,!1,!1)}),["rowSpan","start"].forEach(function(e){A[e]=new U(e,5,!1,e.toLowerCase(),null,!1,!1)});var G=/[\-:]([a-z])/g;function B(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(G,B);A[t]=new U(t,1,!1,e,null,!1,!1)}),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(G,B);A[t]=new U(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(G,B);A[t]=new U(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(e){A[e]=new U(e,1,!1,e.toLowerCase(),null,!1,!1)}),A.xlinkHref=new U("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(e){A[e]=new U(e,1,!1,e.toLowerCase(),null,!0,!0)});function re(e,t,r,n){var i=A.hasOwnProperty(t)?A[t]:null;(i!==null?i.type!==0:n||!(2g||i[f]!==s[g]){var w=` +`+i[f].replace(" at new "," at ");return e.displayName&&w.includes("")&&(w=w.replace("",e.displayName)),w}while(1<=f&&0<=g);break}}}finally{ce=!1,Error.prepareStackTrace=r}return(e=e?e.displayName||e.name:"")?D(e):""}function de(e){switch(e.tag){case 5:return D(e.type);case 16:return D("Lazy");case 13:return D("Suspense");case 19:return D("SuspenseList");case 0:case 2:case 15:return e=fe(e.type,!1),e;case 11:return e=fe(e.type.render,!1),e;case 1:return e=fe(e.type,!0),e;default:return""}}function ve(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case z:return"Fragment";case Ne:return"Portal";case he:return"Profiler";case ae:return"StrictMode";case $e:return"Suspense";case ze:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case _e:return(e.displayName||"Context")+".Consumer";case ke:return(e._context.displayName||"Context")+".Provider";case Oe:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case Be:return t=e.displayName||null,t!==null?t:ve(e.type)||"Memo";case Se:t=e._payload,e=e._init;try{return ve(e(t))}catch{}}return null}function Te(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return ve(t);case 8:return t===ae?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function Ce(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Ue(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function yt(e){var t=Ue(e)?"checked":"value",r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),n=""+e[t];if(!e.hasOwnProperty(t)&&typeof r<"u"&&typeof r.get=="function"&&typeof r.set=="function"){var i=r.get,s=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(f){n=""+f,s.call(this,f)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return n},setValue:function(f){n=""+f},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Cn(e){e._valueTracker||(e._valueTracker=yt(e))}function rt(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var r=t.getValue(),n="";return e&&(n=Ue(e)?e.checked?"true":"false":e.value),e=n,e!==r?(t.setValue(e),!0):!1}function Qt(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function Rn(e,t){var r=t.checked;return Y({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:r??e._wrapperState.initialChecked})}function oi(e,t){var r=t.defaultValue==null?"":t.defaultValue,n=t.checked!=null?t.checked:t.defaultChecked;r=Ce(t.value!=null?t.value:r),e._wrapperState={initialChecked:n,initialValue:r,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function er(e,t){t=t.checked,t!=null&&re(e,"checked",t,!1)}function ll(e,t){er(e,t);var r=Ce(t.value),n=t.type;if(r!=null)n==="number"?(r===0&&e.value===""||e.value!=r)&&(e.value=""+r):e.value!==""+r&&(e.value=""+r);else if(n==="submit"||n==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?Pn(e,t.type,r):t.hasOwnProperty("defaultValue")&&Pn(e,t.type,Ce(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function si(e,t,r){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var n=t.type;if(!(n!=="submit"&&n!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,r||t===e.value||(e.value=t),e.defaultValue=t}r=e.name,r!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,r!==""&&(e.name=r)}function Pn(e,t,r){(t!=="number"||Qt(e.ownerDocument)!==e)&&(r==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+r&&(e.defaultValue=""+r))}var tn=Array.isArray;function Er(e,t,r,n){if(e=e.options,t){t={};for(var i=0;i"+t.valueOf().toString()+"",t=St.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function Cr(e,t){if(t){var r=e.firstChild;if(r&&r===e.lastChild&&r.nodeType===3){r.nodeValue=t;return}}e.textContent=t}var nn={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},ol=["Webkit","ms","Moz","O"];Object.keys(nn).forEach(function(e){ol.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),nn[t]=nn[e]})});function ci(e,t,r){return t==null||typeof t=="boolean"||t===""?"":r||typeof t!="number"||t===0||nn.hasOwnProperty(e)&&nn[e]?(""+t).trim():t+"px"}function Ft(e,t){e=e.style;for(var r in t)if(t.hasOwnProperty(r)){var n=r.indexOf("--")===0,i=ci(r,t[r],n);r==="float"&&(r="cssFloat"),n?e.setProperty(r,i):e[r]=i}}var di=Y({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function _n(e,t){if(t){if(di[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(o(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(o(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(o(61))}if(t.style!=null&&typeof t.style!="object")throw Error(o(62))}}function Mn(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var sl=null;function Ln(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Rr=null,dr=null,rr=null;function fi(e){if(e=Ml(e)){if(typeof Rr!="function")throw Error(o(280));var t=e.stateNode;t&&(t=Mi(t),Rr(e.stateNode,e.type,t))}}function ul(e){dr?rr?rr.push(e):rr=[e]:dr=e}function hi(){if(dr){var e=dr,t=rr;if(rr=dr=null,fi(e),t)for(e=0;e>>=0,e===0?32:31-(Mr(e)/hr|0)|0}var pr=64,un=4194304;function cn(e){switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function pi(e,t){var r=e.pendingLanes;if(r===0)return 0;var n=0,i=e.suspendedLanes,s=e.pingedLanes,f=r&268435455;if(f!==0){var g=f&~i;g!==0?n=cn(g):(s&=f,s!==0&&(n=cn(s)))}else f=r&~i,f!==0?n=cn(f):s!==0&&(n=cn(s));if(n===0)return 0;if(t!==0&&t!==n&&(t&i)===0&&(i=n&-n,s=t&-t,i>=s||i===16&&(s&4194240)!==0))return t;if((n&4)!==0&&(n|=r&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=n;0r;r++)t.push(e);return t}function hl(e,t,r){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-He(t),e[t]=r}function Rf(e,t){var r=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var n=e.eventTimes;for(e=e.expirationTimes;0=Sl),Xs=" ",Zs=!1;function qs(e,t){switch(e){case"keyup":return th.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function eu(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Dn=!1;function nh(e,t){switch(e){case"compositionend":return eu(t);case"keypress":return t.which!==32?null:(Zs=!0,Xs);case"textInput":return e=t.data,e===Xs&&Zs?null:e;default:return null}}function lh(e,t){if(Dn)return e==="compositionend"||!Ua&&qs(e,t)?(e=Vs(),xi=Ta=Or=null,Dn=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1=t)return{node:r,offset:t-e};e=n}e:{for(;r;){if(r.nextSibling){r=r.nextSibling;break e}r=r.parentNode}r=void 0}r=ou(r)}}function uu(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?uu(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function cu(){for(var e=window,t=Qt();t instanceof e.HTMLIFrameElement;){try{var r=typeof t.contentWindow.location.href=="string"}catch{r=!1}if(r)e=t.contentWindow;else break;t=Qt(e.document)}return t}function ba(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}function hh(e){var t=cu(),r=e.focusedElem,n=e.selectionRange;if(t!==r&&r&&r.ownerDocument&&uu(r.ownerDocument.documentElement,r)){if(n!==null&&ba(r)){if(t=n.start,e=n.end,e===void 0&&(e=t),"selectionStart"in r)r.selectionStart=t,r.selectionEnd=Math.min(e,r.value.length);else if(e=(t=r.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var i=r.textContent.length,s=Math.min(n.start,i);n=n.end===void 0?s:Math.min(n.end,i),!e.extend&&s>n&&(i=n,n=s,s=i),i=su(r,s);var f=su(r,n);i&&f&&(e.rangeCount!==1||e.anchorNode!==i.node||e.anchorOffset!==i.offset||e.focusNode!==f.node||e.focusOffset!==f.offset)&&(t=t.createRange(),t.setStart(i.node,i.offset),e.removeAllRanges(),s>n?(e.addRange(t),e.extend(f.node,f.offset)):(t.setEnd(f.node,f.offset),e.addRange(t)))}}for(t=[],e=r;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof r.focus=="function"&&r.focus(),r=0;r=document.documentMode,On=null,Wa=null,jl=null,Ba=!1;function du(e,t,r){var n=r.window===r?r.document:r.nodeType===9?r:r.ownerDocument;Ba||On==null||On!==Qt(n)||(n=On,"selectionStart"in n&&ba(n)?n={start:n.selectionStart,end:n.selectionEnd}:(n=(n.ownerDocument&&n.ownerDocument.defaultView||window).getSelection(),n={anchorNode:n.anchorNode,anchorOffset:n.anchorOffset,focusNode:n.focusNode,focusOffset:n.focusOffset}),jl&&El(jl,n)||(jl=n,n=Ri(Wa,"onSelect"),0An||(e.current=ro[An],ro[An]=null,An--)}function Ae(e,t){An++,ro[An]=e.current,e.current=t}var Ur={},ft=Hr(Ur),kt=Hr(!1),fn=Ur;function $n(e,t){var r=e.type.contextTypes;if(!r)return Ur;var n=e.stateNode;if(n&&n.__reactInternalMemoizedUnmaskedChildContext===t)return n.__reactInternalMemoizedMaskedChildContext;var i={},s;for(s in r)i[s]=t[s];return n&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=i),i}function Et(e){return e=e.childContextTypes,e!=null}function Li(){We(kt),We(ft)}function Cu(e,t,r){if(ft.current!==Ur)throw Error(o(168));Ae(ft,t),Ae(kt,r)}function Ru(e,t,r){var n=e.stateNode;if(t=t.childContextTypes,typeof n.getChildContext!="function")return r;n=n.getChildContext();for(var i in n)if(!(i in t))throw Error(o(108,Te(e)||"Unknown",i));return Y({},r,n)}function zi(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Ur,fn=ft.current,Ae(ft,e),Ae(kt,kt.current),!0}function Pu(e,t,r){var n=e.stateNode;if(!n)throw Error(o(169));r?(e=Ru(e,t,fn),n.__reactInternalMemoizedMergedChildContext=e,We(kt),We(ft),Ae(ft,e)):We(kt),Ae(kt,r)}var gr=null,Ti=!1,no=!1;function _u(e){gr===null?gr=[e]:gr.push(e)}function jh(e){Ti=!0,_u(e)}function Ar(){if(!no&&gr!==null){no=!0;var e=0,t=Ie;try{var r=gr;for(Ie=1;e>=f,i-=f,yr=1<<32-He(t)+i|r<pe?(st=ue,ue=null):st=ue.sibling;var Le=O(C,ue,R[pe],W);if(Le===null){ue===null&&(ue=st);break}e&&ue&&Le.alternate===null&&t(C,ue),S=s(Le,S,pe),se===null?le=Le:se.sibling=Le,se=Le,ue=st}if(pe===R.length)return r(C,ue),Ye&&pn(C,pe),le;if(ue===null){for(;pepe?(st=ue,ue=null):st=ue.sibling;var Kr=O(C,ue,Le.value,W);if(Kr===null){ue===null&&(ue=st);break}e&&ue&&Kr.alternate===null&&t(C,ue),S=s(Kr,S,pe),se===null?le=Kr:se.sibling=Kr,se=Kr,ue=st}if(Le.done)return r(C,ue),Ye&&pn(C,pe),le;if(ue===null){for(;!Le.done;pe++,Le=R.next())Le=$(C,Le.value,W),Le!==null&&(S=s(Le,S,pe),se===null?le=Le:se.sibling=Le,se=Le);return Ye&&pn(C,pe),le}for(ue=n(C,ue);!Le.done;pe++,Le=R.next())Le=Q(ue,C,pe,Le.value,W),Le!==null&&(e&&Le.alternate!==null&&ue.delete(Le.key===null?pe:Le.key),S=s(Le,S,pe),se===null?le=Le:se.sibling=Le,se=Le);return e&&ue.forEach(function(ip){return t(C,ip)}),Ye&&pn(C,pe),le}function Ze(C,S,R,W){if(typeof R=="object"&&R!==null&&R.type===z&&R.key===null&&(R=R.props.children),typeof R=="object"&&R!==null){switch(R.$$typeof){case ge:e:{for(var le=R.key,se=S;se!==null;){if(se.key===le){if(le=R.type,le===z){if(se.tag===7){r(C,se.sibling),S=i(se,R.props.children),S.return=C,C=S;break e}}else if(se.elementType===le||typeof le=="object"&&le!==null&&le.$$typeof===Se&&Ou(le)===se.type){r(C,se.sibling),S=i(se,R.props),S.ref=Ll(C,se,R),S.return=C,C=S;break e}r(C,se);break}else t(C,se);se=se.sibling}R.type===z?(S=Nn(R.props.children,C.mode,W,R.key),S.return=C,C=S):(W=oa(R.type,R.key,R.props,null,C.mode,W),W.ref=Ll(C,S,R),W.return=C,C=W)}return f(C);case Ne:e:{for(se=R.key;S!==null;){if(S.key===se)if(S.tag===4&&S.stateNode.containerInfo===R.containerInfo&&S.stateNode.implementation===R.implementation){r(C,S.sibling),S=i(S,R.children||[]),S.return=C,C=S;break e}else{r(C,S);break}else t(C,S);S=S.sibling}S=ts(R,C.mode,W),S.return=C,C=S}return f(C);case Se:return se=R._init,Ze(C,S,se(R._payload),W)}if(tn(R))return q(C,S,R,W);if(X(R))return te(C,S,R,W);Ii(C,R)}return typeof R=="string"&&R!==""||typeof R=="number"?(R=""+R,S!==null&&S.tag===6?(r(C,S.sibling),S=i(S,R),S.return=C,C=S):(r(C,S),S=es(R,C.mode,W),S.return=C,C=S),f(C)):r(C,S)}return Ze}var Vn=Fu(!0),Iu=Fu(!1),Hi=Hr(null),Ui=null,Yn=null,uo=null;function co(){uo=Yn=Ui=null}function fo(e){var t=Hi.current;We(Hi),e._currentValue=t}function ho(e,t,r){for(;e!==null;){var n=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,n!==null&&(n.childLanes|=t)):n!==null&&(n.childLanes&t)!==t&&(n.childLanes|=t),e===r)break;e=e.return}}function Qn(e,t){Ui=e,uo=Yn=null,e=e.dependencies,e!==null&&e.firstContext!==null&&((e.lanes&t)!==0&&(jt=!0),e.firstContext=null)}function At(e){var t=e._currentValue;if(uo!==e)if(e={context:e,memoizedValue:t,next:null},Yn===null){if(Ui===null)throw Error(o(308));Yn=e,Ui.dependencies={lanes:0,firstContext:e}}else Yn=Yn.next=e;return t}var mn=null;function po(e){mn===null?mn=[e]:mn.push(e)}function Hu(e,t,r,n){var i=t.interleaved;return i===null?(r.next=r,po(t)):(r.next=i.next,i.next=r),t.interleaved=r,xr(e,n)}function xr(e,t){e.lanes|=t;var r=e.alternate;for(r!==null&&(r.lanes|=t),r=e,e=e.return;e!==null;)e.childLanes|=t,r=e.alternate,r!==null&&(r.childLanes|=t),r=e,e=e.return;return r.tag===3?r.stateNode:null}var $r=!1;function mo(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function Uu(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function wr(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function br(e,t,r){var n=e.updateQueue;if(n===null)return null;if(n=n.shared,(Me&2)!==0){var i=n.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),n.pending=t,xr(e,r)}return i=n.interleaved,i===null?(t.next=t,po(n)):(t.next=i.next,i.next=t),n.interleaved=t,xr(e,r)}function Ai(e,t,r){if(t=t.updateQueue,t!==null&&(t=t.shared,(r&4194240)!==0)){var n=t.lanes;n&=e.pendingLanes,r|=n,t.lanes=r,Pa(e,r)}}function Au(e,t){var r=e.updateQueue,n=e.alternate;if(n!==null&&(n=n.updateQueue,r===n)){var i=null,s=null;if(r=r.firstBaseUpdate,r!==null){do{var f={eventTime:r.eventTime,lane:r.lane,tag:r.tag,payload:r.payload,callback:r.callback,next:null};s===null?i=s=f:s=s.next=f,r=r.next}while(r!==null);s===null?i=s=t:s=s.next=t}else i=s=t;r={baseState:n.baseState,firstBaseUpdate:i,lastBaseUpdate:s,shared:n.shared,effects:n.effects},e.updateQueue=r;return}e=r.lastBaseUpdate,e===null?r.firstBaseUpdate=t:e.next=t,r.lastBaseUpdate=t}function $i(e,t,r,n){var i=e.updateQueue;$r=!1;var s=i.firstBaseUpdate,f=i.lastBaseUpdate,g=i.shared.pending;if(g!==null){i.shared.pending=null;var w=g,L=w.next;w.next=null,f===null?s=L:f.next=L,f=w;var I=e.alternate;I!==null&&(I=I.updateQueue,g=I.lastBaseUpdate,g!==f&&(g===null?I.firstBaseUpdate=L:g.next=L,I.lastBaseUpdate=w))}if(s!==null){var $=i.baseState;f=0,I=L=w=null,g=s;do{var O=g.lane,Q=g.eventTime;if((n&O)===O){I!==null&&(I=I.next={eventTime:Q,lane:0,tag:g.tag,payload:g.payload,callback:g.callback,next:null});e:{var q=e,te=g;switch(O=t,Q=r,te.tag){case 1:if(q=te.payload,typeof q=="function"){$=q.call(Q,$,O);break e}$=q;break e;case 3:q.flags=q.flags&-65537|128;case 0:if(q=te.payload,O=typeof q=="function"?q.call(Q,$,O):q,O==null)break e;$=Y({},$,O);break e;case 2:$r=!0}}g.callback!==null&&g.lane!==0&&(e.flags|=64,O=i.effects,O===null?i.effects=[g]:O.push(g))}else Q={eventTime:Q,lane:O,tag:g.tag,payload:g.payload,callback:g.callback,next:null},I===null?(L=I=Q,w=$):I=I.next=Q,f|=O;if(g=g.next,g===null){if(g=i.shared.pending,g===null)break;O=g,g=O.next,O.next=null,i.lastBaseUpdate=O,i.shared.pending=null}}while(!0);if(I===null&&(w=$),i.baseState=w,i.firstBaseUpdate=L,i.lastBaseUpdate=I,t=i.shared.interleaved,t!==null){i=t;do f|=i.lane,i=i.next;while(i!==t)}else s===null&&(i.shared.lanes=0);vn|=f,e.lanes=f,e.memoizedState=$}}function $u(e,t,r){if(e=t.effects,t.effects=null,e!==null)for(t=0;tr?r:4,e(!0);var n=wo.transition;wo.transition={};try{e(!1),t()}finally{Ie=r,wo.transition=n}}function ac(){return $t().memoizedState}function _h(e,t,r){var n=Yr(e);if(r={lane:n,action:r,hasEagerState:!1,eagerState:null,next:null},oc(e))sc(t,r);else if(r=Hu(e,t,r,n),r!==null){var i=wt();qt(r,e,n,i),uc(r,t,n)}}function Mh(e,t,r){var n=Yr(e),i={lane:n,action:r,hasEagerState:!1,eagerState:null,next:null};if(oc(e))sc(t,i);else{var s=e.alternate;if(e.lanes===0&&(s===null||s.lanes===0)&&(s=t.lastRenderedReducer,s!==null))try{var f=t.lastRenderedState,g=s(f,r);if(i.hasEagerState=!0,i.eagerState=g,Gt(g,f)){var w=t.interleaved;w===null?(i.next=i,po(t)):(i.next=w.next,w.next=i),t.interleaved=i;return}}catch{}finally{}r=Hu(e,t,i,n),r!==null&&(i=wt(),qt(r,e,n,i),uc(r,t,n))}}function oc(e){var t=e.alternate;return e===Ge||t!==null&&t===Ge}function sc(e,t){Ol=Bi=!0;var r=e.pending;r===null?t.next=t:(t.next=r.next,r.next=t),e.pending=t}function uc(e,t,r){if((r&4194240)!==0){var n=t.lanes;n&=e.pendingLanes,r|=n,t.lanes=r,Pa(e,r)}}var Qi={readContext:At,useCallback:ht,useContext:ht,useEffect:ht,useImperativeHandle:ht,useInsertionEffect:ht,useLayoutEffect:ht,useMemo:ht,useReducer:ht,useRef:ht,useState:ht,useDebugValue:ht,useDeferredValue:ht,useTransition:ht,useMutableSource:ht,useSyncExternalStore:ht,useId:ht,unstable_isNewReconciler:!1},Lh={readContext:At,useCallback:function(e,t){return ar().memoizedState=[e,t===void 0?null:t],e},useContext:At,useEffect:Zu,useImperativeHandle:function(e,t,r){return r=r!=null?r.concat([e]):null,Vi(4194308,4,tc.bind(null,t,e),r)},useLayoutEffect:function(e,t){return Vi(4194308,4,e,t)},useInsertionEffect:function(e,t){return Vi(4,2,e,t)},useMemo:function(e,t){var r=ar();return t=t===void 0?null:t,e=e(),r.memoizedState=[e,t],e},useReducer:function(e,t,r){var n=ar();return t=r!==void 0?r(t):t,n.memoizedState=n.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},n.queue=e,e=e.dispatch=_h.bind(null,Ge,e),[n.memoizedState,e]},useRef:function(e){var t=ar();return e={current:e},t.memoizedState=e},useState:Ju,useDebugValue:Ro,useDeferredValue:function(e){return ar().memoizedState=e},useTransition:function(){var e=Ju(!1),t=e[0];return e=Ph.bind(null,e[1]),ar().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,r){var n=Ge,i=ar();if(Ye){if(r===void 0)throw Error(o(407));r=r()}else{if(r=t(),ot===null)throw Error(o(349));(yn&30)!==0||Vu(n,t,r)}i.memoizedState=r;var s={value:r,getSnapshot:t};return i.queue=s,Zu(Qu.bind(null,n,s,e),[e]),n.flags|=2048,Hl(9,Yu.bind(null,n,s,r,t),void 0,null),r},useId:function(){var e=ar(),t=ot.identifierPrefix;if(Ye){var r=vr,n=yr;r=(n&~(1<<32-He(n)-1)).toString(32)+r,t=":"+t+"R"+r,r=Fl++,0<\/script>",e=e.removeChild(e.firstChild)):typeof n.is=="string"?e=f.createElement(r,{is:n.is}):(e=f.createElement(r),r==="select"&&(f=e,n.multiple?f.multiple=!0:n.size&&(f.size=n.size))):e=f.createElementNS(e,r),e[lr]=t,e[_l]=n,_c(e,t,!1,!1),t.stateNode=e;e:{switch(f=Mn(r,n),r){case"dialog":be("cancel",e),be("close",e),i=n;break;case"iframe":case"object":case"embed":be("load",e),i=n;break;case"video":case"audio":for(i=0;iZn&&(t.flags|=128,n=!0,Ul(s,!1),t.lanes=4194304)}else{if(!n)if(e=bi(f),e!==null){if(t.flags|=128,n=!0,r=e.updateQueue,r!==null&&(t.updateQueue=r,t.flags|=4),Ul(s,!0),s.tail===null&&s.tailMode==="hidden"&&!f.alternate&&!Ye)return pt(t),null}else 2*Fe()-s.renderingStartTime>Zn&&r!==1073741824&&(t.flags|=128,n=!0,Ul(s,!1),t.lanes=4194304);s.isBackwards?(f.sibling=t.child,t.child=f):(r=s.last,r!==null?r.sibling=f:t.child=f,s.last=f)}return s.tail!==null?(t=s.tail,s.rendering=t,s.tail=t.sibling,s.renderingStartTime=Fe(),t.sibling=null,r=Qe.current,Ae(Qe,n?r&1|2:r&1),t):(pt(t),null);case 22:case 23:return Xo(),n=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==n&&(t.flags|=8192),n&&(t.mode&1)!==0?(Tt&1073741824)!==0&&(pt(t),t.subtreeFlags&6&&(t.flags|=8192)):pt(t),null;case 24:return null;case 25:return null}throw Error(o(156,t.tag))}function Uh(e,t){switch(io(t),t.tag){case 1:return Et(t.type)&&Li(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Gn(),We(kt),We(ft),xo(),e=t.flags,(e&65536)!==0&&(e&128)===0?(t.flags=e&-65537|128,t):null;case 5:return yo(t),null;case 13:if(We(Qe),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(o(340));Bn()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return We(Qe),null;case 4:return Gn(),null;case 10:return fo(t.type._context),null;case 22:case 23:return Xo(),null;case 24:return null;default:return null}}var Xi=!1,mt=!1,Ah=typeof WeakSet=="function"?WeakSet:Set,J=null;function Jn(e,t){var r=e.ref;if(r!==null)if(typeof r=="function")try{r(null)}catch(n){Ke(e,t,n)}else r.current=null}function Uo(e,t,r){try{r()}catch(n){Ke(e,t,n)}}var zc=!1;function $h(e,t){if(Ja=yi,e=cu(),ba(e)){if("selectionStart"in e)var r={start:e.selectionStart,end:e.selectionEnd};else e:{r=(r=e.ownerDocument)&&r.defaultView||window;var n=r.getSelection&&r.getSelection();if(n&&n.rangeCount!==0){r=n.anchorNode;var i=n.anchorOffset,s=n.focusNode;n=n.focusOffset;try{r.nodeType,s.nodeType}catch{r=null;break e}var f=0,g=-1,w=-1,L=0,I=0,$=e,O=null;t:for(;;){for(var Q;$!==r||i!==0&&$.nodeType!==3||(g=f+i),$!==s||n!==0&&$.nodeType!==3||(w=f+n),$.nodeType===3&&(f+=$.nodeValue.length),(Q=$.firstChild)!==null;)O=$,$=Q;for(;;){if($===e)break t;if(O===r&&++L===i&&(g=f),O===s&&++I===n&&(w=f),(Q=$.nextSibling)!==null)break;$=O,O=$.parentNode}$=Q}r=g===-1||w===-1?null:{start:g,end:w}}else r=null}r=r||{start:0,end:0}}else r=null;for(Xa={focusedElem:e,selectionRange:r},yi=!1,J=t;J!==null;)if(t=J,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,J=e;else for(;J!==null;){t=J;try{var q=t.alternate;if((t.flags&1024)!==0)switch(t.tag){case 0:case 11:case 15:break;case 1:if(q!==null){var te=q.memoizedProps,Ze=q.memoizedState,C=t.stateNode,S=C.getSnapshotBeforeUpdate(t.elementType===t.type?te:Jt(t.type,te),Ze);C.__reactInternalSnapshotBeforeUpdate=S}break;case 3:var R=t.stateNode.containerInfo;R.nodeType===1?R.textContent="":R.nodeType===9&&R.documentElement&&R.removeChild(R.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(o(163))}}catch(W){Ke(t,t.return,W)}if(e=t.sibling,e!==null){e.return=t.return,J=e;break}J=t.return}return q=zc,zc=!1,q}function Al(e,t,r){var n=t.updateQueue;if(n=n!==null?n.lastEffect:null,n!==null){var i=n=n.next;do{if((i.tag&e)===e){var s=i.destroy;i.destroy=void 0,s!==void 0&&Uo(t,r,s)}i=i.next}while(i!==n)}}function Zi(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var r=t=t.next;do{if((r.tag&e)===e){var n=r.create;r.destroy=n()}r=r.next}while(r!==t)}}function Ao(e){var t=e.ref;if(t!==null){var r=e.stateNode;switch(e.tag){case 5:e=r;break;default:e=r}typeof t=="function"?t(e):t.current=e}}function Tc(e){var t=e.alternate;t!==null&&(e.alternate=null,Tc(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[lr],delete t[_l],delete t[to],delete t[kh],delete t[Eh])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function Dc(e){return e.tag===5||e.tag===3||e.tag===4}function Oc(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Dc(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function $o(e,t,r){var n=e.tag;if(n===5||n===6)e=e.stateNode,t?r.nodeType===8?r.parentNode.insertBefore(e,t):r.insertBefore(e,t):(r.nodeType===8?(t=r.parentNode,t.insertBefore(e,r)):(t=r,t.appendChild(e)),r=r._reactRootContainer,r!=null||t.onclick!==null||(t.onclick=_i));else if(n!==4&&(e=e.child,e!==null))for($o(e,t,r),e=e.sibling;e!==null;)$o(e,t,r),e=e.sibling}function bo(e,t,r){var n=e.tag;if(n===5||n===6)e=e.stateNode,t?r.insertBefore(e,t):r.appendChild(e);else if(n!==4&&(e=e.child,e!==null))for(bo(e,t,r),e=e.sibling;e!==null;)bo(e,t,r),e=e.sibling}var ct=null,Xt=!1;function Wr(e,t,r){for(r=r.child;r!==null;)Fc(e,t,r),r=r.sibling}function Fc(e,t,r){if(vt&&typeof vt.onCommitFiberUnmount=="function")try{vt.onCommitFiberUnmount(fr,r)}catch{}switch(r.tag){case 5:mt||Jn(r,t);case 6:var n=ct,i=Xt;ct=null,Wr(e,t,r),ct=n,Xt=i,ct!==null&&(Xt?(e=ct,r=r.stateNode,e.nodeType===8?e.parentNode.removeChild(r):e.removeChild(r)):ct.removeChild(r.stateNode));break;case 18:ct!==null&&(Xt?(e=ct,r=r.stateNode,e.nodeType===8?eo(e.parentNode,r):e.nodeType===1&&eo(e,r),vl(e)):eo(ct,r.stateNode));break;case 4:n=ct,i=Xt,ct=r.stateNode.containerInfo,Xt=!0,Wr(e,t,r),ct=n,Xt=i;break;case 0:case 11:case 14:case 15:if(!mt&&(n=r.updateQueue,n!==null&&(n=n.lastEffect,n!==null))){i=n=n.next;do{var s=i,f=s.destroy;s=s.tag,f!==void 0&&((s&2)!==0||(s&4)!==0)&&Uo(r,t,f),i=i.next}while(i!==n)}Wr(e,t,r);break;case 1:if(!mt&&(Jn(r,t),n=r.stateNode,typeof n.componentWillUnmount=="function"))try{n.props=r.memoizedProps,n.state=r.memoizedState,n.componentWillUnmount()}catch(g){Ke(r,t,g)}Wr(e,t,r);break;case 21:Wr(e,t,r);break;case 22:r.mode&1?(mt=(n=mt)||r.memoizedState!==null,Wr(e,t,r),mt=n):Wr(e,t,r);break;default:Wr(e,t,r)}}function Ic(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var r=e.stateNode;r===null&&(r=e.stateNode=new Ah),t.forEach(function(n){var i=Jh.bind(null,e,n);r.has(n)||(r.add(n),n.then(i,i))})}}function Zt(e,t){var r=t.deletions;if(r!==null)for(var n=0;ni&&(i=f),n&=~s}if(n=i,n=Fe()-n,n=(120>n?120:480>n?480:1080>n?1080:1920>n?1920:3e3>n?3e3:4320>n?4320:1960*Wh(n/1960))-n,10e?16:e,Vr===null)var n=!1;else{if(e=Vr,Vr=null,na=0,(Me&6)!==0)throw Error(o(331));var i=Me;for(Me|=4,J=e.current;J!==null;){var s=J,f=s.child;if((J.flags&16)!==0){var g=s.deletions;if(g!==null){for(var w=0;wFe()-Vo?wn(e,0):Bo|=r),Rt(e,t)}function Jc(e,t){t===0&&((e.mode&1)===0?t=1:(t=un,un<<=1,(un&130023424)===0&&(un=4194304)));var r=wt();e=xr(e,t),e!==null&&(hl(e,t,r),Rt(e,r))}function Kh(e){var t=e.memoizedState,r=0;t!==null&&(r=t.retryLane),Jc(e,r)}function Jh(e,t){var r=0;switch(e.tag){case 13:var n=e.stateNode,i=e.memoizedState;i!==null&&(r=i.retryLane);break;case 19:n=e.stateNode;break;default:throw Error(o(314))}n!==null&&n.delete(t),Jc(e,r)}var Xc;Xc=function(e,t,r){if(e!==null)if(e.memoizedProps!==t.pendingProps||kt.current)jt=!0;else{if((e.lanes&r)===0&&(t.flags&128)===0)return jt=!1,Ih(e,t,r);jt=(e.flags&131072)!==0}else jt=!1,Ye&&(t.flags&1048576)!==0&&Mu(t,Oi,t.index);switch(t.lanes=0,t.tag){case 2:var n=t.type;Ji(e,t),e=t.pendingProps;var i=$n(t,ft.current);Qn(t,r),i=No(null,t,n,e,i,r);var s=ko();return t.flags|=1,typeof i=="object"&&i!==null&&typeof i.render=="function"&&i.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,Et(n)?(s=!0,zi(t)):s=!1,t.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,mo(t),i.updater=Gi,t.stateNode=i,i._reactInternals=t,_o(t,n,e,r),t=To(null,t,n,!0,s,r)):(t.tag=0,Ye&&s&&lo(t),xt(null,t,i,r),t=t.child),t;case 16:n=t.elementType;e:{switch(Ji(e,t),e=t.pendingProps,i=n._init,n=i(n._payload),t.type=n,i=t.tag=Zh(n),e=Jt(n,e),i){case 0:t=zo(null,t,n,e,r);break e;case 1:t=kc(null,t,n,e,r);break e;case 11:t=vc(null,t,n,e,r);break e;case 14:t=xc(null,t,n,Jt(n.type,e),r);break e}throw Error(o(306,n,""))}return t;case 0:return n=t.type,i=t.pendingProps,i=t.elementType===n?i:Jt(n,i),zo(e,t,n,i,r);case 1:return n=t.type,i=t.pendingProps,i=t.elementType===n?i:Jt(n,i),kc(e,t,n,i,r);case 3:e:{if(Ec(t),e===null)throw Error(o(387));n=t.pendingProps,s=t.memoizedState,i=s.element,Uu(e,t),$i(t,n,null,r);var f=t.memoizedState;if(n=f.element,s.isDehydrated)if(s={element:n,isDehydrated:!1,cache:f.cache,pendingSuspenseBoundaries:f.pendingSuspenseBoundaries,transitions:f.transitions},t.updateQueue.baseState=s,t.memoizedState=s,t.flags&256){i=Kn(Error(o(423)),t),t=jc(e,t,n,r,i);break e}else if(n!==i){i=Kn(Error(o(424)),t),t=jc(e,t,n,r,i);break e}else for(zt=Ir(t.stateNode.containerInfo.firstChild),Lt=t,Ye=!0,Kt=null,r=Iu(t,null,n,r),t.child=r;r;)r.flags=r.flags&-3|4096,r=r.sibling;else{if(Bn(),n===i){t=Sr(e,t,r);break e}xt(e,t,n,r)}t=t.child}return t;case 5:return bu(t),e===null&&oo(t),n=t.type,i=t.pendingProps,s=e!==null?e.memoizedProps:null,f=i.children,Za(n,i)?f=null:s!==null&&Za(n,s)&&(t.flags|=32),Nc(e,t),xt(e,t,f,r),t.child;case 6:return e===null&&oo(t),null;case 13:return Cc(e,t,r);case 4:return go(t,t.stateNode.containerInfo),n=t.pendingProps,e===null?t.child=Vn(t,null,n,r):xt(e,t,n,r),t.child;case 11:return n=t.type,i=t.pendingProps,i=t.elementType===n?i:Jt(n,i),vc(e,t,n,i,r);case 7:return xt(e,t,t.pendingProps,r),t.child;case 8:return xt(e,t,t.pendingProps.children,r),t.child;case 12:return xt(e,t,t.pendingProps.children,r),t.child;case 10:e:{if(n=t.type._context,i=t.pendingProps,s=t.memoizedProps,f=i.value,Ae(Hi,n._currentValue),n._currentValue=f,s!==null)if(Gt(s.value,f)){if(s.children===i.children&&!kt.current){t=Sr(e,t,r);break e}}else for(s=t.child,s!==null&&(s.return=t);s!==null;){var g=s.dependencies;if(g!==null){f=s.child;for(var w=g.firstContext;w!==null;){if(w.context===n){if(s.tag===1){w=wr(-1,r&-r),w.tag=2;var L=s.updateQueue;if(L!==null){L=L.shared;var I=L.pending;I===null?w.next=w:(w.next=I.next,I.next=w),L.pending=w}}s.lanes|=r,w=s.alternate,w!==null&&(w.lanes|=r),ho(s.return,r,t),g.lanes|=r;break}w=w.next}}else if(s.tag===10)f=s.type===t.type?null:s.child;else if(s.tag===18){if(f=s.return,f===null)throw Error(o(341));f.lanes|=r,g=f.alternate,g!==null&&(g.lanes|=r),ho(f,r,t),f=s.sibling}else f=s.child;if(f!==null)f.return=s;else for(f=s;f!==null;){if(f===t){f=null;break}if(s=f.sibling,s!==null){s.return=f.return,f=s;break}f=f.return}s=f}xt(e,t,i.children,r),t=t.child}return t;case 9:return i=t.type,n=t.pendingProps.children,Qn(t,r),i=At(i),n=n(i),t.flags|=1,xt(e,t,n,r),t.child;case 14:return n=t.type,i=Jt(n,t.pendingProps),i=Jt(n.type,i),xc(e,t,n,i,r);case 15:return wc(e,t,t.type,t.pendingProps,r);case 17:return n=t.type,i=t.pendingProps,i=t.elementType===n?i:Jt(n,i),Ji(e,t),t.tag=1,Et(n)?(e=!0,zi(t)):e=!1,Qn(t,r),dc(t,n,i),_o(t,n,i,r),To(null,t,n,!0,e,r);case 19:return Pc(e,t,r);case 22:return Sc(e,t,r)}throw Error(o(156,t.tag))};function Zc(e,t){return Xe(e,t)}function Xh(e,t,r,n){this.tag=e,this.key=r,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=n,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Wt(e,t,r,n){return new Xh(e,t,r,n)}function qo(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Zh(e){if(typeof e=="function")return qo(e)?1:0;if(e!=null){if(e=e.$$typeof,e===Oe)return 11;if(e===Be)return 14}return 2}function Gr(e,t){var r=e.alternate;return r===null?(r=Wt(e.tag,t,e.key,e.mode),r.elementType=e.elementType,r.type=e.type,r.stateNode=e.stateNode,r.alternate=e,e.alternate=r):(r.pendingProps=t,r.type=e.type,r.flags=0,r.subtreeFlags=0,r.deletions=null),r.flags=e.flags&14680064,r.childLanes=e.childLanes,r.lanes=e.lanes,r.child=e.child,r.memoizedProps=e.memoizedProps,r.memoizedState=e.memoizedState,r.updateQueue=e.updateQueue,t=e.dependencies,r.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},r.sibling=e.sibling,r.index=e.index,r.ref=e.ref,r}function oa(e,t,r,n,i,s){var f=2;if(n=e,typeof e=="function")qo(e)&&(f=1);else if(typeof e=="string")f=5;else e:switch(e){case z:return Nn(r.children,i,s,t);case ae:f=8,i|=8;break;case he:return e=Wt(12,r,t,i|2),e.elementType=he,e.lanes=s,e;case $e:return e=Wt(13,r,t,i),e.elementType=$e,e.lanes=s,e;case ze:return e=Wt(19,r,t,i),e.elementType=ze,e.lanes=s,e;case ye:return sa(r,i,s,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case ke:f=10;break e;case _e:f=9;break e;case Oe:f=11;break e;case Be:f=14;break e;case Se:f=16,n=null;break e}throw Error(o(130,e==null?e:typeof e,""))}return t=Wt(f,r,t,i),t.elementType=e,t.type=n,t.lanes=s,t}function Nn(e,t,r,n){return e=Wt(7,e,n,t),e.lanes=r,e}function sa(e,t,r,n){return e=Wt(22,e,n,t),e.elementType=ye,e.lanes=r,e.stateNode={isHidden:!1},e}function es(e,t,r){return e=Wt(6,e,null,t),e.lanes=r,e}function ts(e,t,r){return t=Wt(4,e.children!==null?e.children:[],e.key,t),t.lanes=r,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function qh(e,t,r,n,i){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Ra(0),this.expirationTimes=Ra(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Ra(0),this.identifierPrefix=n,this.onRecoverableError=i,this.mutableSourceEagerHydrationData=null}function rs(e,t,r,n,i,s,f,g,w){return e=new qh(e,t,r,g,w),t===1?(t=1,s===!0&&(t|=8)):t=0,s=Wt(3,null,null,t),e.current=s,s.stateNode=e,s.memoizedState={element:n,isDehydrated:r,cache:null,transitions:null,pendingSuspenseBoundaries:null},mo(s),e}function ep(e,t,r){var n=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(l)}catch(a){console.error(a)}}return l(),ss.exports=hp(),ss.exports}var fd;function mp(){if(fd)return ma;fd=1;var l=pp();return ma.createRoot=l.createRoot,ma.hydrateRoot=l.hydrateRoot,ma}var gp=mp(),_=Ss();const yp=op(_),vp=ap({__proto__:null,default:yp},[_]);/** + * react-router v7.13.0 + * + * Copyright (c) Remix Software Inc. + * + * This source code is licensed under the MIT license found in the + * LICENSE.md file in the root directory of this source tree. + * + * @license MIT + */var Bd=l=>{throw TypeError(l)},xp=(l,a,o)=>a.has(l)||Bd("Cannot "+o),ds=(l,a,o)=>(xp(l,a,"read from private field"),o?o.call(l):a.get(l)),wp=(l,a,o)=>a.has(l)?Bd("Cannot add the same private member more than once"):a instanceof WeakSet?a.add(l):a.set(l,o),hd="popstate";function Sp(l={}){function a(u,c){let{pathname:d,search:p,hash:m}=u.location;return ql("",{pathname:d,search:p,hash:m},c.state&&c.state.usr||null,c.state&&c.state.key||"default")}function o(u,c){return typeof c=="string"?c:ur(c)}return kp(a,o,null,l)}function je(l,a){if(l===!1||l===null||typeof l>"u")throw new Error(a)}function tt(l,a){if(!l){typeof console<"u"&&console.warn(a);try{throw new Error(a)}catch{}}}function Np(){return Math.random().toString(36).substring(2,10)}function pd(l,a){return{usr:l.state,key:l.key,idx:a}}function ql(l,a,o=null,u){return{pathname:typeof l=="string"?l:l.pathname,search:"",hash:"",...typeof a=="string"?qr(a):a,state:o,key:a&&a.key||u||Np()}}function ur({pathname:l="/",search:a="",hash:o=""}){return a&&a!=="?"&&(l+=a.charAt(0)==="?"?a:"?"+a),o&&o!=="#"&&(l+=o.charAt(0)==="#"?o:"#"+o),l}function qr(l){let a={};if(l){let o=l.indexOf("#");o>=0&&(a.hash=l.substring(o),l=l.substring(0,o));let u=l.indexOf("?");u>=0&&(a.search=l.substring(u),l=l.substring(0,u)),l&&(a.pathname=l)}return a}function kp(l,a,o,u={}){let{window:c=document.defaultView,v5Compat:d=!1}=u,p=c.history,m="POP",y=null,x=j();x==null&&(x=0,p.replaceState({...p.state,idx:x},""));function j(){return(p.state||{idx:null}).idx}function E(){m="POP";let A=j(),G=A==null?null:A-x;x=A,y&&y({action:m,location:U.location,delta:G})}function M(A,G){m="PUSH";let B=ql(U.location,A,G);x=j()+1;let re=pd(B,x),we=U.createHref(B);try{p.pushState(re,"",we)}catch(ge){if(ge instanceof DOMException&&ge.name==="DataCloneError")throw ge;c.location.assign(we)}d&&y&&y({action:m,location:U.location,delta:1})}function T(A,G){m="REPLACE";let B=ql(U.location,A,G);x=j();let re=pd(B,x),we=U.createHref(B);p.replaceState(re,"",we),d&&y&&y({action:m,location:U.location,delta:0})}function b(A){return Vd(A)}let U={get action(){return m},get location(){return l(c,p)},listen(A){if(y)throw new Error("A history only accepts one active listener");return c.addEventListener(hd,E),y=A,()=>{c.removeEventListener(hd,E),y=null}},createHref(A){return a(c,A)},createURL:b,encodeLocation(A){let G=b(A);return{pathname:G.pathname,search:G.search,hash:G.hash}},push:M,replace:T,go(A){return p.go(A)}};return U}function Vd(l,a=!1){let o="http://localhost";typeof window<"u"&&(o=window.location.origin!=="null"?window.location.origin:window.location.href),je(o,"No window.location.(origin|href) available to create URL");let u=typeof l=="string"?l:ur(l);return u=u.replace(/ $/,"%20"),!a&&u.startsWith("//")&&(u=o+u),new URL(u,o)}var Kl,md=class{constructor(l){if(wp(this,Kl,new Map),l)for(let[a,o]of l)this.set(a,o)}get(l){if(ds(this,Kl).has(l))return ds(this,Kl).get(l);if(l.defaultValue!==void 0)return l.defaultValue;throw new Error("No value found for context")}set(l,a){ds(this,Kl).set(l,a)}};Kl=new WeakMap;var Ep=new Set(["lazy","caseSensitive","path","id","index","children"]);function jp(l){return Ep.has(l)}var Cp=new Set(["lazy","caseSensitive","path","id","index","middleware","children"]);function Rp(l){return Cp.has(l)}function Pp(l){return l.index===!0}function ei(l,a,o=[],u={},c=!1){return l.map((d,p)=>{let m=[...o,String(p)],y=typeof d.id=="string"?d.id:m.join("-");if(je(d.index!==!0||!d.children,"Cannot specify children on an index route"),je(c||!u[y],`Found a route id collision on id "${y}". Route id's must be globally unique within Data Router usages`),Pp(d)){let x={...d,id:y};return u[y]=gd(x,a(x)),x}else{let x={...d,id:y,children:void 0};return u[y]=gd(x,a(x)),d.children&&(x.children=ei(d.children,a,m,u,c)),x}})}function gd(l,a){return Object.assign(l,{...a,...typeof a.lazy=="object"&&a.lazy!=null?{lazy:{...l.lazy,...a.lazy}}:{}})}function Jr(l,a,o="/"){return Jl(l,a,o,!1)}function Jl(l,a,o,u){let c=typeof a=="string"?qr(a):a,d=Vt(c.pathname||"/",o);if(d==null)return null;let p=Yd(l);Mp(p);let m=null;for(let y=0;m==null&&y{let j={relativePath:x===void 0?p.path||"":x,caseSensitive:p.caseSensitive===!0,childrenIndex:m,route:p};if(j.relativePath.startsWith("/")){if(!j.relativePath.startsWith(u)&&y)return;je(j.relativePath.startsWith(u),`Absolute route path "${j.relativePath}" nested under path "${u}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),j.relativePath=j.relativePath.slice(u.length)}let E=sr([u,j.relativePath]),M=o.concat(j);p.children&&p.children.length>0&&(je(p.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${E}".`),Yd(p.children,a,M,E,y)),!(p.path==null&&!p.index)&&a.push({path:E,score:Ip(E,p.index),routesMeta:M})};return l.forEach((p,m)=>{var y;if(p.path===""||!((y=p.path)!=null&&y.includes("?")))d(p,m);else for(let x of Qd(p.path))d(p,m,!0,x)}),a}function Qd(l){let a=l.split("/");if(a.length===0)return[];let[o,...u]=a,c=o.endsWith("?"),d=o.replace(/\?$/,"");if(u.length===0)return c?[d,""]:[d];let p=Qd(u.join("/")),m=[];return m.push(...p.map(y=>y===""?d:[d,y].join("/"))),c&&m.push(...p),m.map(y=>l.startsWith("/")&&y===""?"/":y)}function Mp(l){l.sort((a,o)=>a.score!==o.score?o.score-a.score:Hp(a.routesMeta.map(u=>u.childrenIndex),o.routesMeta.map(u=>u.childrenIndex)))}var Lp=/^:[\w-]+$/,zp=3,Tp=2,Dp=1,Op=10,Fp=-2,yd=l=>l==="*";function Ip(l,a){let o=l.split("/"),u=o.length;return o.some(yd)&&(u+=Fp),a&&(u+=Tp),o.filter(c=>!yd(c)).reduce((c,d)=>c+(Lp.test(d)?zp:d===""?Dp:Op),u)}function Hp(l,a){return l.length===a.length&&l.slice(0,-1).every((u,c)=>u===a[c])?l[l.length-1]-a[a.length-1]:0}function Up(l,a,o=!1){let{routesMeta:u}=l,c={},d="/",p=[];for(let m=0;m{if(j==="*"){let b=m[M]||"";p=d.slice(0,d.length-b.length).replace(/(.)\/+$/,"$1")}const T=m[M];return E&&!T?x[j]=void 0:x[j]=(T||"").replace(/%2F/g,"/"),x},{}),pathname:d,pathnameBase:p,pattern:l}}function Ap(l,a=!1,o=!0){tt(l==="*"||!l.endsWith("*")||l.endsWith("/*"),`Route path "${l}" will be treated as if it were "${l.replace(/\*$/,"/*")}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${l.replace(/\*$/,"/*")}".`);let u=[],c="^"+l.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(p,m,y)=>(u.push({paramName:m,isOptional:y!=null}),y?"/?([^\\/]+)?":"/([^\\/]+)")).replace(/\/([\w-]+)\?(\/|$)/g,"(/$1)?$2");return l.endsWith("*")?(u.push({paramName:"*"}),c+=l==="*"||l==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):o?c+="\\/*$":l!==""&&l!=="/"&&(c+="(?:(?=\\/|$))"),[new RegExp(c,a?void 0:"i"),u]}function $p(l){try{return l.split("/").map(a=>decodeURIComponent(a).replace(/\//g,"%2F")).join("/")}catch(a){return tt(!1,`The URL path "${l}" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (${a}).`),l}}function Vt(l,a){if(a==="/")return l;if(!l.toLowerCase().startsWith(a.toLowerCase()))return null;let o=a.endsWith("/")?a.length-1:a.length,u=l.charAt(o);return u&&u!=="/"?null:l.slice(o)||"/"}function bp({basename:l,pathname:a}){return a==="/"?l:sr([l,a])}var Gd=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Ns=l=>Gd.test(l);function Wp(l,a="/"){let{pathname:o,search:u="",hash:c=""}=typeof l=="string"?qr(l):l,d;return o?(o=o.replace(/\/\/+/g,"/"),o.startsWith("/")?d=vd(o.substring(1),"/"):d=vd(o,a)):d=a,{pathname:d,search:Vp(u),hash:Yp(c)}}function vd(l,a){let o=a.replace(/\/+$/,"").split("/");return l.split("/").forEach(c=>{c===".."?o.length>1&&o.pop():c!=="."&&o.push(c)}),o.length>1?o.join("/"):"/"}function fs(l,a,o,u){return`Cannot include a '${l}' character in a manually specified \`to.${a}\` field [${JSON.stringify(u)}]. Please separate it out to the \`to.${o}\` field. Alternatively you may provide the full path as a string in and the router will parse it for you.`}function Kd(l){return l.filter((a,o)=>o===0||a.route.path&&a.route.path.length>0)}function ks(l){let a=Kd(l);return a.map((o,u)=>u===a.length-1?o.pathname:o.pathnameBase)}function Es(l,a,o,u=!1){let c;typeof l=="string"?c=qr(l):(c={...l},je(!c.pathname||!c.pathname.includes("?"),fs("?","pathname","search",c)),je(!c.pathname||!c.pathname.includes("#"),fs("#","pathname","hash",c)),je(!c.search||!c.search.includes("#"),fs("#","search","hash",c)));let d=l===""||c.pathname==="",p=d?"/":c.pathname,m;if(p==null)m=o;else{let E=a.length-1;if(!u&&p.startsWith("..")){let M=p.split("/");for(;M[0]==="..";)M.shift(),E-=1;c.pathname=M.join("/")}m=E>=0?a[E]:"/"}let y=Wp(c,m),x=p&&p!=="/"&&p.endsWith("/"),j=(d||p===".")&&o.endsWith("/");return!y.pathname.endsWith("/")&&(x||j)&&(y.pathname+="/"),y}var sr=l=>l.join("/").replace(/\/\/+/g,"/"),Bp=l=>l.replace(/\/+$/,"").replace(/^\/*/,"/"),Vp=l=>!l||l==="?"?"":l.startsWith("?")?l:"?"+l,Yp=l=>!l||l==="#"?"":l.startsWith("#")?l:"#"+l,ri=class{constructor(l,a,o,u=!1){this.status=l,this.statusText=a||"",this.internal=u,o instanceof Error?(this.data=o.toString(),this.error=o):this.data=o}};function ti(l){return l!=null&&typeof l.status=="number"&&typeof l.statusText=="string"&&typeof l.internal=="boolean"&&"data"in l}function ni(l){return l.map(a=>a.route.path).filter(Boolean).join("/").replace(/\/\/*/g,"/")||"/"}var Jd=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function Xd(l,a){let o=l;if(typeof o!="string"||!Gd.test(o))return{absoluteURL:void 0,isExternal:!1,to:o};let u=o,c=!1;if(Jd)try{let d=new URL(window.location.href),p=o.startsWith("//")?new URL(d.protocol+o):new URL(o),m=Vt(p.pathname,a);p.origin===d.origin&&m!=null?o=m+p.search+p.hash:c=!0}catch{tt(!1,` contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}return{absoluteURL:u,isExternal:c,to:o}}var Zr=Symbol("Uninstrumented");function Qp(l,a){let o={lazy:[],"lazy.loader":[],"lazy.action":[],"lazy.middleware":[],middleware:[],loader:[],action:[]};l.forEach(c=>c({id:a.id,index:a.index,path:a.path,instrument(d){let p=Object.keys(o);for(let m of p)d[m]&&o[m].push(d[m])}}));let u={};if(typeof a.lazy=="function"&&o.lazy.length>0){let c=rl(o.lazy,a.lazy,()=>{});c&&(u.lazy=c)}if(typeof a.lazy=="object"){let c=a.lazy;["middleware","loader","action"].forEach(d=>{let p=c[d],m=o[`lazy.${d}`];if(typeof p=="function"&&m.length>0){let y=rl(m,p,()=>{});y&&(u.lazy=Object.assign(u.lazy||{},{[d]:y}))}})}return["loader","action"].forEach(c=>{let d=a[c];if(typeof d=="function"&&o[c].length>0){let p=d[Zr]??d,m=rl(o[c],p,(...y)=>xd(y[0]));m&&(c==="loader"&&p.hydrate===!0&&(m.hydrate=!0),m[Zr]=p,u[c]=m)}}),a.middleware&&a.middleware.length>0&&o.middleware.length>0&&(u.middleware=a.middleware.map(c=>{let d=c[Zr]??c,p=rl(o.middleware,d,(...m)=>xd(m[0]));return p?(p[Zr]=d,p):c})),u}function Gp(l,a){let o={navigate:[],fetch:[]};if(a.forEach(u=>u({instrument(c){let d=Object.keys(c);for(let p of d)c[p]&&o[p].push(c[p])}})),o.navigate.length>0){let u=l.navigate[Zr]??l.navigate,c=rl(o.navigate,u,(...d)=>{let[p,m]=d;return{to:typeof p=="number"||typeof p=="string"?p:p?ur(p):".",...wd(l,m??{})}});c&&(c[Zr]=u,l.navigate=c)}if(o.fetch.length>0){let u=l.fetch[Zr]??l.fetch,c=rl(o.fetch,u,(...d)=>{let[p,,m,y]=d;return{href:m??".",fetcherKey:p,...wd(l,y??{})}});c&&(c[Zr]=u,l.fetch=c)}return l}function rl(l,a,o){return l.length===0?null:async(...u)=>{let c=await Zd(l,o(...u),()=>a(...u),l.length-1);if(c.type==="error")throw c.value;return c.value}}async function Zd(l,a,o,u){let c=l[u],d;if(c){let p,m=async()=>(p?console.error("You cannot call instrumented handlers more than once"):p=Zd(l,a,o,u-1),d=await p,je(d,"Expected a result"),d.type==="error"&&d.value instanceof Error?{status:"error",error:d.value}:{status:"success",error:void 0});try{await c(m,a)}catch(y){console.error("An instrumentation function threw an error:",y)}p||await m(),await p}else try{d={type:"success",value:await o()}}catch(p){d={type:"error",value:p}}return d||{type:"error",value:new Error("No result assigned in instrumentation chain.")}}function xd(l){let{request:a,context:o,params:u,unstable_pattern:c}=l;return{request:Kp(a),params:{...u},unstable_pattern:c,context:Jp(o)}}function wd(l,a){return{currentUrl:ur(l.state.location),..."formMethod"in a?{formMethod:a.formMethod}:{},..."formEncType"in a?{formEncType:a.formEncType}:{},..."formData"in a?{formData:a.formData}:{},..."body"in a?{body:a.body}:{}}}function Kp(l){return{method:l.method,url:l.url,headers:{get:(...a)=>l.headers.get(...a)}}}function Jp(l){if(Zp(l)){let a={...l};return Object.freeze(a),a}else return{get:a=>l.get(a)}}var Xp=Object.getOwnPropertyNames(Object.prototype).sort().join("\0");function Zp(l){if(l===null||typeof l!="object")return!1;const a=Object.getPrototypeOf(l);return a===Object.prototype||a===null||Object.getOwnPropertyNames(a).sort().join("\0")===Xp}var qd=["POST","PUT","PATCH","DELETE"],qp=new Set(qd),em=["GET",...qd],tm=new Set(em),ef=new Set([301,302,303,307,308]),rm=new Set([307,308]),hs={state:"idle",location:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},nm={state:"idle",data:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},Yl={state:"unblocked",proceed:void 0,reset:void 0,location:void 0},lm=l=>({hasErrorBoundary:!!l.hasErrorBoundary}),tf="remix-router-transitions",rf=Symbol("ResetLoaderData");function im(l){const a=l.window?l.window:typeof window<"u"?window:void 0,o=typeof a<"u"&&typeof a.document<"u"&&typeof a.document.createElement<"u";je(l.routes.length>0,"You must provide a non-empty routes array to createRouter");let u=l.hydrationRouteProperties||[],c=l.mapRouteProperties||lm,d=c;if(l.unstable_instrumentations){let v=l.unstable_instrumentations;d=k=>({...c(k),...Qp(v.map(P=>P.route).filter(Boolean),k)})}let p={},m=ei(l.routes,d,void 0,p),y,x=l.basename||"/";x.startsWith("/")||(x=`/${x}`);let j=l.dataStrategy||cm,E={...l.future},M=null,T=new Set,b=null,U=null,A=null,G=l.hydrationData!=null,B=Jr(m,l.history.location,x),re=!1,we=null,ge;if(B==null&&!l.patchRoutesOnNavigation){let v=Bt(404,{pathname:l.history.location.pathname}),{matches:k,route:P}=ga(m);ge=!0,B=k,we={[P.id]:v}}else if(B&&!l.hydrationData&&ln(B,m,l.history.location.pathname).active&&(B=null),B)if(B.some(v=>v.route.lazy))ge=!1;else if(!B.some(v=>js(v.route)))ge=!0;else{let v=l.hydrationData?l.hydrationData.loaderData:null,k=l.hydrationData?l.hydrationData.errors:null;if(k){let P=B.findIndex(F=>k[F.route.id]!==void 0);ge=B.slice(0,P+1).every(F=>!vs(F.route,v,k))}else ge=B.every(P=>!vs(P.route,v,k))}else{ge=!1,B=[];let v=ln(null,m,l.history.location.pathname);v.active&&v.matches&&(re=!0,B=v.matches)}let Ne,z={historyAction:l.history.action,location:l.history.location,matches:B,initialized:ge,navigation:hs,restoreScrollPosition:l.hydrationData!=null?!1:null,preventScrollReset:!1,revalidation:"idle",loaderData:l.hydrationData&&l.hydrationData.loaderData||{},actionData:l.hydrationData&&l.hydrationData.actionData||null,errors:l.hydrationData&&l.hydrationData.errors||we,fetchers:new Map,blockers:new Map},ae="POP",he=null,ke=!1,_e,Oe=!1,$e=new Map,ze=null,Be=!1,Se=!1,ye=new Set,H=new Map,X=0,Y=-1,N=new Map,D=new Set,ce=new Map,fe=new Map,de=new Set,ve=new Map,Te,Ce=null;function Ue(){if(M=l.history.listen(({action:v,location:k,delta:P})=>{if(Te){Te(),Te=void 0;return}tt(ve.size===0||P!=null,"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 F=dr({currentLocation:z.location,nextLocation:k,historyAction:v});if(F&&P!=null){let V=new Promise(ne=>{Te=ne});l.history.go(P*-1),Rr(F,{state:"blocked",location:k,proceed(){Rr(F,{state:"proceeding",proceed:void 0,reset:void 0,location:k}),V.then(()=>l.history.go(P))},reset(){let ne=new Map(z.blockers);ne.set(F,Yl),rt({blockers:ne})}}),he==null||he.resolve(),he=null;return}return er(v,k)}),o){Pm(a,$e);let v=()=>_m(a,$e);a.addEventListener("pagehide",v),ze=()=>a.removeEventListener("pagehide",v)}return z.initialized||er("POP",z.location,{initialHydration:!0}),Ne}function yt(){M&&M(),ze&&ze(),T.clear(),_e&&_e.abort(),z.fetchers.forEach((v,k)=>ol(k)),z.blockers.forEach((v,k)=>Ln(k))}function Cn(v){return T.add(v),()=>T.delete(v)}function rt(v,k={}){v.matches&&(v.matches=v.matches.map(V=>{let ne=p[V.route.id],oe=V.route;return oe.element!==ne.element||oe.errorElement!==ne.errorElement||oe.hydrateFallbackElement!==ne.hydrateFallbackElement?{...V,route:ne}:V})),z={...z,...v};let P=[],F=[];z.fetchers.forEach((V,ne)=>{V.state==="idle"&&(de.has(ne)?P.push(ne):F.push(ne))}),de.forEach(V=>{!z.fetchers.has(V)&&!H.has(V)&&P.push(V)}),[...T].forEach(V=>V(z,{deletedFetchers:P,newErrors:v.errors??null,viewTransitionOpts:k.viewTransitionOpts,flushSync:k.flushSync===!0})),P.forEach(V=>ol(V)),F.forEach(V=>z.fetchers.delete(V))}function Qt(v,k,{flushSync:P}={}){var me,ie;let F=z.actionData!=null&&z.navigation.formMethod!=null&>(z.navigation.formMethod)&&z.navigation.state==="loading"&&((me=v.state)==null?void 0:me._isRedirect)!==!0,V;k.actionData?Object.keys(k.actionData).length>0?V=k.actionData:V=null:F?V=z.actionData:V=null;let ne=k.loaderData?Md(z.loaderData,k.loaderData,k.matches||[],k.errors):z.loaderData,oe=z.blockers;oe.size>0&&(oe=new Map(oe),oe.forEach((xe,Re)=>oe.set(Re,Yl)));let K=Be?!1:cl(v,k.matches||z.matches),Z=ke===!0||z.navigation.formMethod!=null&>(z.navigation.formMethod)&&((ie=v.state)==null?void 0:ie._isRedirect)!==!0;y&&(m=y,y=void 0),Be||ae==="POP"||(ae==="PUSH"?l.history.push(v,v.state):ae==="REPLACE"&&l.history.replace(v,v.state));let ee;if(ae==="POP"){let xe=$e.get(z.location.pathname);xe&&xe.has(v.pathname)?ee={currentLocation:z.location,nextLocation:v}:$e.has(v.pathname)&&(ee={currentLocation:v,nextLocation:z.location})}else if(Oe){let xe=$e.get(z.location.pathname);xe?xe.add(v.pathname):(xe=new Set([v.pathname]),$e.set(z.location.pathname,xe)),ee={currentLocation:z.location,nextLocation:v}}rt({...k,actionData:V,loaderData:ne,historyAction:ae,location:v,initialized:!0,navigation:hs,revalidation:"idle",restoreScrollPosition:K,preventScrollReset:Z,blockers:oe},{viewTransitionOpts:ee,flushSync:P===!0}),ae="POP",ke=!1,Oe=!1,Be=!1,Se=!1,he==null||he.resolve(),he=null,Ce==null||Ce.resolve(),Ce=null}async function Rn(v,k){if(he==null||he.resolve(),he=null,typeof v=="number"){he||(he=Dd());let Re=he.promise;return l.history.go(v),Re}let P=ys(z.location,z.matches,x,v,k==null?void 0:k.fromRouteId,k==null?void 0:k.relative),{path:F,submission:V,error:ne}=Sd(!1,P,k),oe=z.location,K=ql(z.location,F,k&&k.state);K={...K,...l.history.encodeLocation(K)};let Z=k&&k.replace!=null?k.replace:void 0,ee="PUSH";Z===!0?ee="REPLACE":Z===!1||V!=null&>(V.formMethod)&&V.formAction===z.location.pathname+z.location.search&&(ee="REPLACE");let me=k&&"preventScrollReset"in k?k.preventScrollReset===!0:void 0,ie=(k&&k.flushSync)===!0,xe=dr({currentLocation:oe,nextLocation:K,historyAction:ee});if(xe){Rr(xe,{state:"blocked",location:K,proceed(){Rr(xe,{state:"proceeding",proceed:void 0,reset:void 0,location:K}),Rn(v,k)},reset(){let Re=new Map(z.blockers);Re.set(xe,Yl),rt({blockers:Re})}});return}await er(ee,K,{submission:V,pendingError:ne,preventScrollReset:me,replace:k&&k.replace,enableViewTransition:k&&k.viewTransition,flushSync:ie,callSiteDefaultShouldRevalidate:k&&k.unstable_defaultShouldRevalidate})}function oi(){Ce||(Ce=Dd()),rn(),rt({revalidation:"loading"});let v=Ce.promise;return z.navigation.state==="submitting"?v:z.navigation.state==="idle"?(er(z.historyAction,z.location,{startUninterruptedRevalidation:!0}),v):(er(ae||z.historyAction,z.navigation.location,{overrideNavigation:z.navigation,enableViewTransition:Oe===!0}),v)}async function er(v,k,P){_e&&_e.abort(),_e=null,ae=v,Be=(P&&P.startUninterruptedRevalidation)===!0,hi(z.location,z.matches),ke=(P&&P.preventScrollReset)===!0,Oe=(P&&P.enableViewTransition)===!0;let F=y||m,V=P&&P.overrideNavigation,ne=P!=null&&P.initialHydration&&z.matches&&z.matches.length>0&&!re?z.matches:Jr(F,k,x),oe=(P&&P.flushSync)===!0;if(ne&&z.initialized&&!Se&&vm(z.location,k)&&!(P&&P.submission&>(P.submission.formMethod))){Qt(k,{matches:ne},{flushSync:oe});return}let K=ln(ne,F,k.pathname);if(K.active&&K.matches&&(ne=K.matches),!ne){let{error:Xe,notFoundMatches:it,route:De}=rr(k.pathname);Qt(k,{matches:it,loaderData:{},errors:{[De.id]:Xe}},{flushSync:oe});return}_e=new AbortController;let Z=el(l.history,k,_e.signal,P&&P.submission),ee=l.getContext?await l.getContext():new md,me;if(P&&P.pendingError)me=[Xr(ne).route.id,{type:"error",error:P.pendingError}];else if(P&&P.submission&>(P.submission.formMethod)){let Xe=await ll(Z,k,P.submission,ne,ee,K.active,P&&P.initialHydration===!0,{replace:P.replace,flushSync:oe});if(Xe.shortCircuited)return;if(Xe.pendingActionResult){let[it,De]=Xe.pendingActionResult;if(Dt(De)&&ti(De.error)&&De.error.status===404){_e=null,Qt(k,{matches:Xe.matches,loaderData:{},errors:{[it]:De.error}});return}}ne=Xe.matches||ne,me=Xe.pendingActionResult,V=ps(k,P.submission),oe=!1,K.active=!1,Z=el(l.history,Z.url,Z.signal)}let{shortCircuited:ie,matches:xe,loaderData:Re,errors:qe}=await si(Z,k,ne,ee,K.active,V,P&&P.submission,P&&P.fetcherSubmission,P&&P.replace,P&&P.initialHydration===!0,oe,me,P&&P.callSiteDefaultShouldRevalidate);ie||(_e=null,Qt(k,{matches:xe||ne,...Ld(me),loaderData:Re,errors:qe}))}async function ll(v,k,P,F,V,ne,oe,K={}){rn();let Z=Cm(k,P);if(rt({navigation:Z},{flushSync:K.flushSync===!0}),ne){let ie=await Pr(F,k.pathname,v.signal);if(ie.type==="aborted")return{shortCircuited:!0};if(ie.type==="error"){if(ie.partialMatches.length===0){let{matches:Re,route:qe}=ga(m);return{matches:Re,pendingActionResult:[qe.id,{type:"error",error:ie.error}]}}let xe=Xr(ie.partialMatches).route.id;return{matches:ie.partialMatches,pendingActionResult:[xe,{type:"error",error:ie.error}]}}else if(ie.matches)F=ie.matches;else{let{notFoundMatches:xe,error:Re,route:qe}=rr(k.pathname);return{matches:xe,pendingActionResult:[qe.id,{type:"error",error:Re}]}}}let ee,me=xa(F,k);if(!me.route.action&&!me.route.lazy)ee={type:"error",error:Bt(405,{method:v.method,pathname:k.pathname,routeId:me.route.id})};else{let ie=nl(d,p,v,F,me,oe?[]:u,V),xe=await jr(v,ie,V,null);if(ee=xe[me.route.id],!ee){for(let Re of F)if(xe[Re.route.id]){ee=xe[Re.route.id];break}}if(v.signal.aborted)return{shortCircuited:!0}}if(kn(ee)){let ie;return K&&K.replace!=null?ie=K.replace:ie=Rd(ee.response.headers.get("Location"),new URL(v.url),x,l.history)===z.location.pathname+z.location.search,await tr(v,ee,!0,{submission:P,replace:ie}),{shortCircuited:!0}}if(Dt(ee)){let ie=Xr(F,me.route.id);return(K&&K.replace)!==!0&&(ae="PUSH"),{matches:F,pendingActionResult:[ie.route.id,ee,me.route.id]}}return{matches:F,pendingActionResult:[me.route.id,ee]}}async function si(v,k,P,F,V,ne,oe,K,Z,ee,me,ie,xe){let Re=ne||ps(k,oe),qe=oe||K||Td(Re),Xe=!Be&&!ee;if(V){if(Xe){let He=Pn(ie);rt({navigation:Re,...He!==void 0?{actionData:He}:{}},{flushSync:me})}let Pe=await Pr(P,k.pathname,v.signal);if(Pe.type==="aborted")return{shortCircuited:!0};if(Pe.type==="error"){if(Pe.partialMatches.length===0){let{matches:Mr,route:hr}=ga(m);return{matches:Mr,loaderData:{},errors:{[hr.id]:Pe.error}}}let He=Xr(Pe.partialMatches).route.id;return{matches:Pe.partialMatches,loaderData:{},errors:{[He]:Pe.error}}}else if(Pe.matches)P=Pe.matches;else{let{error:He,notFoundMatches:Mr,route:hr}=rr(k.pathname);return{matches:Mr,loaderData:{},errors:{[hr.id]:He}}}}let it=y||m,{dsMatches:De,revalidatingFetchers:Nt}=Nd(v,F,d,p,l.history,z,P,qe,k,ee?[]:u,ee===!0,Se,ye,de,ce,D,it,x,l.patchRoutesOnNavigation!=null,ie,xe);if(Y=++X,!l.dataStrategy&&!De.some(Pe=>Pe.shouldLoad)&&!De.some(Pe=>Pe.route.middleware&&Pe.route.middleware.length>0)&&Nt.length===0){let Pe=_n();return Qt(k,{matches:P,loaderData:{},errors:ie&&Dt(ie[1])?{[ie[0]]:ie[1].error}:null,...Ld(ie),...Pe?{fetchers:new Map(z.fetchers)}:{}},{flushSync:me}),{shortCircuited:!0}}if(Xe){let Pe={};if(!V){Pe.navigation=Re;let He=Pn(ie);He!==void 0&&(Pe.actionData=He)}Nt.length>0&&(Pe.fetchers=tn(Nt)),rt(Pe,{flushSync:me})}Nt.forEach(Pe=>{Ft(Pe.key),Pe.controller&&H.set(Pe.key,Pe.controller)});let Fe=()=>Nt.forEach(Pe=>Ft(Pe.key));_e&&_e.signal.addEventListener("abort",Fe);let{loaderResults:on,fetcherResults:It}=await al(De,Nt,v,F);if(v.signal.aborted)return{shortCircuited:!0};_e&&_e.signal.removeEventListener("abort",Fe),Nt.forEach(Pe=>H.delete(Pe.key));let _t=ya(on);if(_t)return await tr(v,_t.result,!0,{replace:Z}),{shortCircuited:!0};if(_t=ya(It),_t)return D.add(_t.key),await tr(v,_t.result,!0,{replace:Z}),{shortCircuited:!0};let{loaderData:_r,errors:sn}=_d(z,P,on,ie,Nt,It);ee&&z.errors&&(sn={...z.errors,...sn});let nr=_n(),fr=Mn(Y),vt=nr||fr||Nt.length>0;return{matches:P,loaderData:_r,errors:sn,...vt?{fetchers:new Map(z.fetchers)}:{}}}function Pn(v){if(v&&!Dt(v[1]))return{[v[0]]:v[1].data};if(z.actionData)return Object.keys(z.actionData).length===0?null:z.actionData}function tn(v){return v.forEach(k=>{let P=z.fetchers.get(k.key),F=Ql(void 0,P?P.data:void 0);z.fetchers.set(k.key,F)}),new Map(z.fetchers)}async function Er(v,k,P,F){Ft(v);let V=(F&&F.flushSync)===!0,ne=y||m,oe=ys(z.location,z.matches,x,P,k,F==null?void 0:F.relative),K=Jr(ne,oe,x),Z=ln(K,ne,oe);if(Z.active&&Z.matches&&(K=Z.matches),!K){Ot(v,k,Bt(404,{pathname:oe}),{flushSync:V});return}let{path:ee,submission:me,error:ie}=Sd(!0,oe,F);if(ie){Ot(v,k,ie,{flushSync:V});return}let xe=l.getContext?await l.getContext():new md,Re=(F&&F.preventScrollReset)===!0;if(me&>(me.formMethod)){await il(v,k,ee,K,xe,Z.active,V,Re,me,F&&F.unstable_defaultShouldRevalidate);return}ce.set(v,{routeId:k,path:ee}),await ui(v,k,ee,K,xe,Z.active,V,Re,me)}async function il(v,k,P,F,V,ne,oe,K,Z,ee){rn(),ce.delete(v);let me=z.fetchers.get(v);St(v,Rm(Z,me),{flushSync:oe});let ie=new AbortController,xe=el(l.history,P,ie.signal,Z);if(ne){let Ve=await Pr(F,new URL(xe.url).pathname,xe.signal,v);if(Ve.type==="aborted")return;if(Ve.type==="error"){Ot(v,k,Ve.error,{flushSync:oe});return}else if(Ve.matches)F=Ve.matches;else{Ot(v,k,Bt(404,{pathname:P}),{flushSync:oe});return}}let Re=xa(F,P);if(!Re.route.action&&!Re.route.lazy){let Ve=Bt(405,{method:Z.formMethod,pathname:P,routeId:k});Ot(v,k,Ve,{flushSync:oe});return}H.set(v,ie);let qe=X,Xe=nl(d,p,xe,F,Re,u,V),it=await jr(xe,Xe,V,v),De=it[Re.route.id];if(!De){for(let Ve of Xe)if(it[Ve.route.id]){De=it[Ve.route.id];break}}if(xe.signal.aborted){H.get(v)===ie&&H.delete(v);return}if(de.has(v)){if(kn(De)||Dt(De)){St(v,kr(void 0));return}}else{if(kn(De))if(H.delete(v),Y>qe){St(v,kr(void 0));return}else return D.add(v),St(v,Ql(Z)),tr(xe,De,!1,{fetcherSubmission:Z,preventScrollReset:K});if(Dt(De)){Ot(v,k,De.error);return}}let Nt=z.navigation.location||z.location,Fe=el(l.history,Nt,ie.signal),on=y||m,It=z.navigation.state!=="idle"?Jr(on,z.navigation.location,x):z.matches;je(It,"Didn't find any matches after fetcher action");let _t=++X;N.set(v,_t);let _r=Ql(Z,De.data);z.fetchers.set(v,_r);let{dsMatches:sn,revalidatingFetchers:nr}=Nd(Fe,V,d,p,l.history,z,It,Z,Nt,u,!1,Se,ye,de,ce,D,on,x,l.patchRoutesOnNavigation!=null,[Re.route.id,De],ee);nr.filter(Ve=>Ve.key!==v).forEach(Ve=>{let pr=Ve.key,un=z.fetchers.get(pr),cn=Ql(void 0,un?un.data:void 0);z.fetchers.set(pr,cn),Ft(pr),Ve.controller&&H.set(pr,Ve.controller)}),rt({fetchers:new Map(z.fetchers)});let fr=()=>nr.forEach(Ve=>Ft(Ve.key));ie.signal.addEventListener("abort",fr);let{loaderResults:vt,fetcherResults:Pe}=await al(sn,nr,Fe,V);if(ie.signal.aborted)return;if(ie.signal.removeEventListener("abort",fr),N.delete(v),H.delete(v),nr.forEach(Ve=>H.delete(Ve.key)),z.fetchers.has(v)){let Ve=kr(De.data);z.fetchers.set(v,Ve)}let He=ya(vt);if(He)return tr(Fe,He.result,!1,{preventScrollReset:K});if(He=ya(Pe),He)return D.add(He.key),tr(Fe,He.result,!1,{preventScrollReset:K});let{loaderData:Mr,errors:hr}=_d(z,It,vt,void 0,nr,Pe);Mn(_t),z.navigation.state==="loading"&&_t>Y?(je(ae,"Expected pending action"),_e&&_e.abort(),Qt(z.navigation.location,{matches:It,loaderData:Mr,errors:hr,fetchers:new Map(z.fetchers)})):(rt({errors:hr,loaderData:Md(z.loaderData,Mr,It,hr),fetchers:new Map(z.fetchers)}),Se=!1)}async function ui(v,k,P,F,V,ne,oe,K,Z){let ee=z.fetchers.get(v);St(v,Ql(Z,ee?ee.data:void 0),{flushSync:oe});let me=new AbortController,ie=el(l.history,P,me.signal);if(ne){let De=await Pr(F,new URL(ie.url).pathname,ie.signal,v);if(De.type==="aborted")return;if(De.type==="error"){Ot(v,k,De.error,{flushSync:oe});return}else if(De.matches)F=De.matches;else{Ot(v,k,Bt(404,{pathname:P}),{flushSync:oe});return}}let xe=xa(F,P);H.set(v,me);let Re=X,qe=nl(d,p,ie,F,xe,u,V),it=(await jr(ie,qe,V,v))[xe.route.id];if(H.get(v)===me&&H.delete(v),!ie.signal.aborted){if(de.has(v)){St(v,kr(void 0));return}if(kn(it))if(Y>Re){St(v,kr(void 0));return}else{D.add(v),await tr(ie,it,!1,{preventScrollReset:K});return}if(Dt(it)){Ot(v,k,it.error);return}St(v,kr(it.data))}}async function tr(v,k,P,{submission:F,fetcherSubmission:V,preventScrollReset:ne,replace:oe}={}){P||(he==null||he.resolve(),he=null),k.response.headers.has("X-Remix-Revalidate")&&(Se=!0);let K=k.response.headers.get("Location");je(K,"Expected a Location header on the redirect Response"),K=Rd(K,new URL(v.url),x,l.history);let Z=ql(z.location,K,{_isRedirect:!0});if(o){let qe=!1;if(k.response.headers.has("X-Remix-Reload-Document"))qe=!0;else if(Ns(K)){const Xe=Vd(K,!0);qe=Xe.origin!==a.location.origin||Vt(Xe.pathname,x)==null}if(qe){oe?a.location.replace(K):a.location.assign(K);return}}_e=null;let ee=oe===!0||k.response.headers.has("X-Remix-Replace")?"REPLACE":"PUSH",{formMethod:me,formAction:ie,formEncType:xe}=z.navigation;!F&&!V&&me&&ie&&xe&&(F=Td(z.navigation));let Re=F||V;if(rm.has(k.response.status)&&Re&>(Re.formMethod))await er(ee,Z,{submission:{...Re,formAction:K},preventScrollReset:ne||ke,enableViewTransition:P?Oe:void 0});else{let qe=ps(Z,F);await er(ee,Z,{overrideNavigation:qe,fetcherSubmission:V,preventScrollReset:ne||ke,enableViewTransition:P?Oe:void 0})}}async function jr(v,k,P,F){var oe;let V,ne={};try{V=await fm(j,v,k,F,P,!1)}catch(K){return k.filter(Z=>Z.shouldLoad).forEach(Z=>{ne[Z.route.id]={type:"error",error:K}}),ne}if(v.signal.aborted)return ne;if(!gt(v.method))for(let K of k){if(((oe=V[K.route.id])==null?void 0:oe.type)==="error")break;!V.hasOwnProperty(K.route.id)&&!z.loaderData.hasOwnProperty(K.route.id)&&(!z.errors||!z.errors.hasOwnProperty(K.route.id))&&K.shouldCallHandler()&&(V[K.route.id]={type:"error",result:new Error(`No result returned from dataStrategy for route ${K.route.id}`)})}for(let[K,Z]of Object.entries(V))if(Nm(Z)){let ee=Z.result;ne[K]={type:"redirect",response:gm(ee,v,K,k,x)}}else ne[K]=await mm(Z);return ne}async function al(v,k,P,F){let V=jr(P,v,F,null),ne=Promise.all(k.map(async Z=>{if(Z.matches&&Z.match&&Z.request&&Z.controller){let me=(await jr(Z.request,Z.matches,F,Z.key))[Z.match.route.id];return{[Z.key]:me}}else return Promise.resolve({[Z.key]:{type:"error",error:Bt(404,{pathname:Z.path})}})})),oe=await V,K=(await ne).reduce((Z,ee)=>Object.assign(Z,ee),{});return{loaderResults:oe,fetcherResults:K}}function rn(){Se=!0,ce.forEach((v,k)=>{H.has(k)&&ye.add(k),Ft(k)})}function St(v,k,P={}){z.fetchers.set(v,k),rt({fetchers:new Map(z.fetchers)},{flushSync:(P&&P.flushSync)===!0})}function Ot(v,k,P,F={}){let V=Xr(z.matches,k);ol(v),rt({errors:{[V.route.id]:P},fetchers:new Map(z.fetchers)},{flushSync:(F&&F.flushSync)===!0})}function Cr(v){return fe.set(v,(fe.get(v)||0)+1),de.has(v)&&de.delete(v),z.fetchers.get(v)||nm}function nn(v,k){Ft(v,k==null?void 0:k.reason),St(v,kr(null))}function ol(v){let k=z.fetchers.get(v);H.has(v)&&!(k&&k.state==="loading"&&N.has(v))&&Ft(v),ce.delete(v),N.delete(v),D.delete(v),de.delete(v),ye.delete(v),z.fetchers.delete(v)}function ci(v){let k=(fe.get(v)||0)-1;k<=0?(fe.delete(v),de.add(v)):fe.set(v,k),rt({fetchers:new Map(z.fetchers)})}function Ft(v,k){let P=H.get(v);P&&(P.abort(k),H.delete(v))}function di(v){for(let k of v){let P=Cr(k),F=kr(P.data);z.fetchers.set(k,F)}}function _n(){let v=[],k=!1;for(let P of D){let F=z.fetchers.get(P);je(F,`Expected fetcher: ${P}`),F.state==="loading"&&(D.delete(P),v.push(P),k=!0)}return di(v),k}function Mn(v){let k=[];for(let[P,F]of N)if(F0}function sl(v,k){let P=z.blockers.get(v)||Yl;return ve.get(v)!==k&&ve.set(v,k),P}function Ln(v){z.blockers.delete(v),ve.delete(v)}function Rr(v,k){let P=z.blockers.get(v)||Yl;je(P.state==="unblocked"&&k.state==="blocked"||P.state==="blocked"&&k.state==="blocked"||P.state==="blocked"&&k.state==="proceeding"||P.state==="blocked"&&k.state==="unblocked"||P.state==="proceeding"&&k.state==="unblocked",`Invalid blocker state transition: ${P.state} -> ${k.state}`);let F=new Map(z.blockers);F.set(v,k),rt({blockers:F})}function dr({currentLocation:v,nextLocation:k,historyAction:P}){if(ve.size===0)return;ve.size>1&&tt(!1,"A router only supports one blocker at a time");let F=Array.from(ve.entries()),[V,ne]=F[F.length-1],oe=z.blockers.get(V);if(!(oe&&oe.state==="proceeding")&&ne({currentLocation:v,nextLocation:k,historyAction:P}))return V}function rr(v){let k=Bt(404,{pathname:v}),P=y||m,{matches:F,route:V}=ga(P);return{notFoundMatches:F,route:V,error:k}}function fi(v,k,P){if(b=v,A=k,U=P||null,!G&&z.navigation===hs){G=!0;let F=cl(z.location,z.matches);F!=null&&rt({restoreScrollPosition:F})}return()=>{b=null,A=null,U=null}}function ul(v,k){return U&&U(v,k.map(F=>_p(F,z.loaderData)))||v.key}function hi(v,k){if(b&&A){let P=ul(v,k);b[P]=A()}}function cl(v,k){if(b){let P=ul(v,k),F=b[P];if(typeof F=="number")return F}return null}function ln(v,k,P){if(l.patchRoutesOnNavigation)if(v){if(Object.keys(v[0].params).length>0)return{active:!0,matches:Jl(k,P,x,!0)}}else return{active:!0,matches:Jl(k,P,x,!0)||[]};return{active:!1,matches:null}}async function Pr(v,k,P,F){if(!l.patchRoutesOnNavigation)return{type:"success",matches:v};let V=v;for(;;){let ne=y==null,oe=y||m,K=p;try{await l.patchRoutesOnNavigation({signal:P,path:k,matches:V,fetcherKey:F,patch:(me,ie)=>{P.aborted||kd(me,ie,oe,K,d,!1)}})}catch(me){return{type:"error",error:me,partialMatches:V}}finally{ne&&!P.aborted&&(m=[...m])}if(P.aborted)return{type:"aborted"};let Z=Jr(oe,k,x),ee=null;if(Z){if(Object.keys(Z[0].params).length===0)return{type:"success",matches:Z};if(ee=Jl(oe,k,x,!0),!(ee&&V.lengthP.route.id===k[F].route.id)}function an(v){p={},y=ei(v,d,void 0,p)}function fl(v,k,P=!1){let F=y==null;kd(v,k,y||m,p,d,P),F&&(m=[...m],rt({}))}return Ne={get basename(){return x},get future(){return E},get state(){return z},get routes(){return m},get window(){return a},initialize:Ue,subscribe:Cn,enableScrollRestoration:fi,navigate:Rn,fetch:Er,revalidate:oi,createHref:v=>l.history.createHref(v),encodeLocation:v=>l.history.encodeLocation(v),getFetcher:Cr,resetFetcher:nn,deleteFetcher:ci,dispose:yt,getBlocker:sl,deleteBlocker:Ln,patchRoutes:fl,_internalFetchControllers:H,_internalSetRoutes:an,_internalSetStateDoNotUseOrYouWillBreakYourApp(v){rt(v)}},l.unstable_instrumentations&&(Ne=Gp(Ne,l.unstable_instrumentations.map(v=>v.router).filter(Boolean))),Ne}function am(l){return l!=null&&("formData"in l&&l.formData!=null||"body"in l&&l.body!==void 0)}function ys(l,a,o,u,c,d){let p,m;if(c){p=[];for(let x of a)if(p.push(x),x.route.id===c){m=x;break}}else p=a,m=a[a.length-1];let y=Es(u||".",ks(p),Vt(l.pathname,o)||l.pathname,d==="path");if(u==null&&(y.search=l.search,y.hash=l.hash),(u==null||u===""||u===".")&&m){let x=Rs(y.search);if(m.route.index&&!x)y.search=y.search?y.search.replace(/^\?/,"?index&"):"?index";else if(!m.route.index&&x){let j=new URLSearchParams(y.search),E=j.getAll("index");j.delete("index"),E.filter(T=>T).forEach(T=>j.append("index",T));let M=j.toString();y.search=M?`?${M}`:""}}return o!=="/"&&(y.pathname=bp({basename:o,pathname:y.pathname})),ur(y)}function Sd(l,a,o){if(!o||!am(o))return{path:a};if(o.formMethod&&!jm(o.formMethod))return{path:a,error:Bt(405,{method:o.formMethod})};let u=()=>({path:a,error:Bt(400,{type:"invalid-body"})}),d=(o.formMethod||"get").toUpperCase(),p=uf(a);if(o.body!==void 0){if(o.formEncType==="text/plain"){if(!gt(d))return u();let E=typeof o.body=="string"?o.body:o.body instanceof FormData||o.body instanceof URLSearchParams?Array.from(o.body.entries()).reduce((M,[T,b])=>`${M}${T}=${b} +`,""):String(o.body);return{path:a,submission:{formMethod:d,formAction:p,formEncType:o.formEncType,formData:void 0,json:void 0,text:E}}}else if(o.formEncType==="application/json"){if(!gt(d))return u();try{let E=typeof o.body=="string"?JSON.parse(o.body):o.body;return{path:a,submission:{formMethod:d,formAction:p,formEncType:o.formEncType,formData:void 0,json:E,text:void 0}}}catch{return u()}}}je(typeof FormData=="function","FormData is not available in this environment");let m,y;if(o.formData)m=ws(o.formData),y=o.formData;else if(o.body instanceof FormData)m=ws(o.body),y=o.body;else if(o.body instanceof URLSearchParams)m=o.body,y=Pd(m);else if(o.body==null)m=new URLSearchParams,y=new FormData;else try{m=new URLSearchParams(o.body),y=Pd(m)}catch{return u()}let x={formMethod:d,formAction:p,formEncType:o&&o.formEncType||"application/x-www-form-urlencoded",formData:y,json:void 0,text:void 0};if(gt(x.formMethod))return{path:a,submission:x};let j=qr(a);return l&&j.search&&Rs(j.search)&&m.append("index",""),j.search=`?${m}`,{path:ur(j),submission:x}}function Nd(l,a,o,u,c,d,p,m,y,x,j,E,M,T,b,U,A,G,B,re,we){var Be;let ge=re?Dt(re[1])?re[1].error:re[1].data:void 0,Ne=c.createURL(d.location),z=c.createURL(y),ae;if(j&&d.errors){let Se=Object.keys(d.errors)[0];ae=p.findIndex(ye=>ye.route.id===Se)}else if(re&&Dt(re[1])){let Se=re[0];ae=p.findIndex(ye=>ye.route.id===Se)-1}let he=re?re[1].statusCode:void 0,ke=he&&he>=400,_e={currentUrl:Ne,currentParams:((Be=d.matches[0])==null?void 0:Be.params)||{},nextUrl:z,nextParams:p[0].params,...m,actionResult:ge,actionStatus:he},Oe=ni(p),$e=p.map((Se,ye)=>{let{route:H}=Se,X=null;if(ae!=null&&ye>ae?X=!1:H.lazy?X=!0:js(H)?j?X=vs(H,d.loaderData,d.errors):om(d.loaderData,d.matches[ye],Se)&&(X=!0):X=!1,X!==null)return xs(o,u,l,Oe,Se,x,a,X);let Y=!1;typeof we=="boolean"?Y=we:ke?Y=!1:(E||Ne.pathname+Ne.search===z.pathname+z.search||Ne.search!==z.search||sm(d.matches[ye],Se))&&(Y=!0);let N={..._e,defaultShouldRevalidate:Y},D=Xl(Se,N);return xs(o,u,l,Oe,Se,x,a,D,N,we)}),ze=[];return b.forEach((Se,ye)=>{if(j||!p.some(de=>de.route.id===Se.routeId)||T.has(ye))return;let H=d.fetchers.get(ye),X=H&&H.state!=="idle"&&H.data===void 0,Y=Jr(A,Se.path,G);if(!Y){if(B&&X)return;ze.push({key:ye,routeId:Se.routeId,path:Se.path,matches:null,match:null,request:null,controller:null});return}if(U.has(ye))return;let N=xa(Y,Se.path),D=new AbortController,ce=el(c,Se.path,D.signal),fe=null;if(M.has(ye))M.delete(ye),fe=nl(o,u,ce,Y,N,x,a);else if(X)E&&(fe=nl(o,u,ce,Y,N,x,a));else{let de;typeof we=="boolean"?de=we:ke?de=!1:de=E;let ve={..._e,defaultShouldRevalidate:de};Xl(N,ve)&&(fe=nl(o,u,ce,Y,N,x,a,ve))}fe&&ze.push({key:ye,routeId:Se.routeId,path:Se.path,matches:fe,match:N,request:ce,controller:D})}),{dsMatches:$e,revalidatingFetchers:ze}}function js(l){return l.loader!=null||l.middleware!=null&&l.middleware.length>0}function vs(l,a,o){if(l.lazy)return!0;if(!js(l))return!1;let u=a!=null&&l.id in a,c=o!=null&&o[l.id]!==void 0;return!u&&c?!1:typeof l.loader=="function"&&l.loader.hydrate===!0?!0:!u&&!c}function om(l,a,o){let u=!a||o.route.id!==a.route.id,c=!l.hasOwnProperty(o.route.id);return u||c}function sm(l,a){let o=l.route.path;return l.pathname!==a.pathname||o!=null&&o.endsWith("*")&&l.params["*"]!==a.params["*"]}function Xl(l,a){if(l.route.shouldRevalidate){let o=l.route.shouldRevalidate(a);if(typeof o=="boolean")return o}return a.defaultShouldRevalidate}function kd(l,a,o,u,c,d){let p;if(l){let x=u[l];je(x,`No route found to patch children into: routeId = ${l}`),x.children||(x.children=[]),p=x.children}else p=o;let m=[],y=[];if(a.forEach(x=>{let j=p.find(E=>nf(x,E));j?y.push({existingRoute:j,newRoute:x}):m.push(x)}),m.length>0){let x=ei(m,c,[l||"_","patch",String((p==null?void 0:p.length)||"0")],u);p.push(...x)}if(d&&y.length>0)for(let x=0;x{var c;return(c=a.children)==null?void 0:c.some(d=>nf(o,d))}):!1}var Ed=new WeakMap,lf=({key:l,route:a,manifest:o,mapRouteProperties:u})=>{let c=o[a.id];if(je(c,"No route found in manifest"),!c.lazy||typeof c.lazy!="object")return;let d=c.lazy[l];if(!d)return;let p=Ed.get(c);p||(p={},Ed.set(c,p));let m=p[l];if(m)return m;let y=(async()=>{let x=jp(l),E=c[l]!==void 0&&l!=="hasErrorBoundary";if(x)tt(!x,"Route property "+l+" is not a supported lazy route property. This property will be ignored."),p[l]=Promise.resolve();else if(E)tt(!1,`Route "${c.id}" has a static property "${l}" defined. The lazy property will be ignored.`);else{let M=await d();M!=null&&(Object.assign(c,{[l]:M}),Object.assign(c,u(c)))}typeof c.lazy=="object"&&(c.lazy[l]=void 0,Object.values(c.lazy).every(M=>M===void 0)&&(c.lazy=void 0))})();return p[l]=y,y},jd=new WeakMap;function um(l,a,o,u,c){let d=o[l.id];if(je(d,"No route found in manifest"),!l.lazy)return{lazyRoutePromise:void 0,lazyHandlerPromise:void 0};if(typeof l.lazy=="function"){let j=jd.get(d);if(j)return{lazyRoutePromise:j,lazyHandlerPromise:j};let E=(async()=>{je(typeof l.lazy=="function","No lazy route function found");let M=await l.lazy(),T={};for(let b in M){let U=M[b];if(U===void 0)continue;let A=Rp(b),B=d[b]!==void 0&&b!=="hasErrorBoundary";A?tt(!A,"Route property "+b+" is not a supported property to be returned from a lazy route function. This property will be ignored."):B?tt(!B,`Route "${d.id}" has a static property "${b}" defined but its lazy function is also returning a value for this property. The lazy route property "${b}" will be ignored.`):T[b]=U}Object.assign(d,T),Object.assign(d,{...u(d),lazy:void 0})})();return jd.set(d,E),E.catch(()=>{}),{lazyRoutePromise:E,lazyHandlerPromise:E}}let p=Object.keys(l.lazy),m=[],y;for(let j of p){if(c&&c.includes(j))continue;let E=lf({key:j,route:l,manifest:o,mapRouteProperties:u});E&&(m.push(E),j===a&&(y=E))}let x=m.length>0?Promise.all(m).then(()=>{}):void 0;return x==null||x.catch(()=>{}),y==null||y.catch(()=>{}),{lazyRoutePromise:x,lazyHandlerPromise:y}}async function Cd(l){let a=l.matches.filter(c=>c.shouldLoad),o={};return(await Promise.all(a.map(c=>c.resolve()))).forEach((c,d)=>{o[a[d].route.id]=c}),o}async function cm(l){return l.matches.some(a=>a.route.middleware)?af(l,()=>Cd(l)):Cd(l)}function af(l,a){return dm(l,a,u=>{if(Em(u))throw u;return u},wm,o);function o(u,c,d){if(d)return Promise.resolve(Object.assign(d.value,{[c]:{type:"error",result:u}}));{let{matches:p}=l,m=Math.min(Math.max(p.findIndex(x=>x.route.id===c),0),Math.max(p.findIndex(x=>x.shouldCallHandler()),0)),y=Xr(p,p[m].route.id).route.id;return Promise.resolve({[y]:{type:"error",result:u}})}}}async function dm(l,a,o,u,c){let{matches:d,request:p,params:m,context:y,unstable_pattern:x}=l,j=d.flatMap(M=>M.route.middleware?M.route.middleware.map(T=>[M.route.id,T]):[]);return await of({request:p,params:m,context:y,unstable_pattern:x},j,a,o,u,c)}async function of(l,a,o,u,c,d,p=0){let{request:m}=l;if(m.signal.aborted)throw m.signal.reason??new Error(`Request aborted: ${m.method} ${m.url}`);let y=a[p];if(!y)return await o();let[x,j]=y,E,M=async()=>{if(E)throw new Error("You may only call `next()` once per middleware");try{return E={value:await of(l,a,o,u,c,d,p+1)},E.value}catch(T){return E={value:await d(T,x,E)},E.value}};try{let T=await j(l,M),b=T!=null?u(T):void 0;return c(b)?b:E?b??E.value:(E={value:await M()},E.value)}catch(T){return await d(T,x,E)}}function sf(l,a,o,u,c){let d=lf({key:"middleware",route:u.route,manifest:a,mapRouteProperties:l}),p=um(u.route,gt(o.method)?"action":"loader",a,l,c);return{middleware:d,route:p.lazyRoutePromise,handler:p.lazyHandlerPromise}}function xs(l,a,o,u,c,d,p,m,y=null,x){let j=!1,E=sf(l,a,o,c,d);return{...c,_lazyPromises:E,shouldLoad:m,shouldRevalidateArgs:y,shouldCallHandler(M){return j=!0,y?typeof x=="boolean"?Xl(c,{...y,defaultShouldRevalidate:x}):typeof M=="boolean"?Xl(c,{...y,defaultShouldRevalidate:M}):Xl(c,y):m},resolve(M){let{lazy:T,loader:b,middleware:U}=c.route,A=j||m||M&&!gt(o.method)&&(T||b),G=U&&U.length>0&&!b&&!T;return A&&(gt(o.method)||!G)?hm({request:o,unstable_pattern:u,match:c,lazyHandlerPromise:E==null?void 0:E.handler,lazyRoutePromise:E==null?void 0:E.route,handlerOverride:M,scopedContext:p}):Promise.resolve({type:"data",result:void 0})}}}function nl(l,a,o,u,c,d,p,m=null){return u.map(y=>y.route.id!==c.route.id?{...y,shouldLoad:!1,shouldRevalidateArgs:m,shouldCallHandler:()=>!1,_lazyPromises:sf(l,a,o,y,d),resolve:()=>Promise.resolve({type:"data",result:void 0})}:xs(l,a,o,ni(u),y,d,p,!0,m))}async function fm(l,a,o,u,c,d){o.some(x=>{var j;return(j=x._lazyPromises)==null?void 0:j.middleware})&&await Promise.all(o.map(x=>{var j;return(j=x._lazyPromises)==null?void 0:j.middleware}));let p={request:a,unstable_pattern:ni(o),params:o[0].params,context:c,matches:o},y=await l({...p,fetcherKey:u,runClientMiddleware:x=>{let j=p;return af(j,()=>x({...j,fetcherKey:u,runClientMiddleware:()=>{throw new Error("Cannot call `runClientMiddleware()` from within an `runClientMiddleware` handler")}}))}});try{await Promise.all(o.flatMap(x=>{var j,E;return[(j=x._lazyPromises)==null?void 0:j.handler,(E=x._lazyPromises)==null?void 0:E.route]}))}catch{}return y}async function hm({request:l,unstable_pattern:a,match:o,lazyHandlerPromise:u,lazyRoutePromise:c,handlerOverride:d,scopedContext:p}){let m,y,x=gt(l.method),j=x?"action":"loader",E=M=>{let T,b=new Promise((G,B)=>T=B);y=()=>T(),l.signal.addEventListener("abort",y);let U=G=>typeof M!="function"?Promise.reject(new Error(`You cannot call the handler for a route which defines a boolean "${j}" [routeId: ${o.route.id}]`)):M({request:l,unstable_pattern:a,params:o.params,context:p},...G!==void 0?[G]:[]),A=(async()=>{try{return{type:"data",result:await(d?d(B=>U(B)):U())}}catch(G){return{type:"error",result:G}}})();return Promise.race([A,b])};try{let M=x?o.route.action:o.route.loader;if(u||c)if(M){let T,[b]=await Promise.all([E(M).catch(U=>{T=U}),u,c]);if(T!==void 0)throw T;m=b}else{await u;let T=x?o.route.action:o.route.loader;if(T)[m]=await Promise.all([E(T),c]);else if(j==="action"){let b=new URL(l.url),U=b.pathname+b.search;throw Bt(405,{method:l.method,pathname:U,routeId:o.route.id})}else return{type:"data",result:void 0}}else if(M)m=await E(M);else{let T=new URL(l.url),b=T.pathname+T.search;throw Bt(404,{pathname:b})}}catch(M){return{type:"error",result:M}}finally{y&&l.signal.removeEventListener("abort",y)}return m}async function pm(l){let a=l.headers.get("Content-Type");return a&&/\bapplication\/json\b/.test(a)?l.body==null?null:l.json():l.text()}async function mm(l){var u,c,d,p,m;let{result:a,type:o}=l;if(Cs(a)){let y;try{y=await pm(a)}catch(x){return{type:"error",error:x}}return o==="error"?{type:"error",error:new ri(a.status,a.statusText,y),statusCode:a.status,headers:a.headers}:{type:"data",data:y,statusCode:a.status,headers:a.headers}}return o==="error"?zd(a)?a.data instanceof Error?{type:"error",error:a.data,statusCode:(u=a.init)==null?void 0:u.status,headers:(c=a.init)!=null&&c.headers?new Headers(a.init.headers):void 0}:{type:"error",error:xm(a),statusCode:ti(a)?a.status:void 0,headers:(d=a.init)!=null&&d.headers?new Headers(a.init.headers):void 0}:{type:"error",error:a,statusCode:ti(a)?a.status:void 0}:zd(a)?{type:"data",data:a.data,statusCode:(p=a.init)==null?void 0:p.status,headers:(m=a.init)!=null&&m.headers?new Headers(a.init.headers):void 0}:{type:"data",data:a}}function gm(l,a,o,u,c){let d=l.headers.get("Location");if(je(d,"Redirects returned/thrown from loaders/actions must have a Location header"),!Ns(d)){let p=u.slice(0,u.findIndex(m=>m.route.id===o)+1);d=ys(new URL(a.url),p,c,d),l.headers.set("Location",d)}return l}function Rd(l,a,o,u){let c=["about:","blob:","chrome:","chrome-untrusted:","content:","data:","devtools:","file:","filesystem:","javascript:"];if(Ns(l)){let d=l,p=d.startsWith("//")?new URL(a.protocol+d):new URL(d);if(c.includes(p.protocol))throw new Error("Invalid redirect location");let m=Vt(p.pathname,o)!=null;if(p.origin===a.origin&&m)return p.pathname+p.search+p.hash}try{let d=u.createURL(l);if(c.includes(d.protocol))throw new Error("Invalid redirect location")}catch{}return l}function el(l,a,o,u){let c=l.createURL(uf(a)).toString(),d={signal:o};if(u&>(u.formMethod)){let{formMethod:p,formEncType:m}=u;d.method=p.toUpperCase(),m==="application/json"?(d.headers=new Headers({"Content-Type":m}),d.body=JSON.stringify(u.json)):m==="text/plain"?d.body=u.text:m==="application/x-www-form-urlencoded"&&u.formData?d.body=ws(u.formData):d.body=u.formData}return new Request(c,d)}function ws(l){let a=new URLSearchParams;for(let[o,u]of l.entries())a.append(o,typeof u=="string"?u:u.name);return a}function Pd(l){let a=new FormData;for(let[o,u]of l.entries())a.append(o,u);return a}function ym(l,a,o,u=!1,c=!1){let d={},p=null,m,y=!1,x={},j=o&&Dt(o[1])?o[1].error:void 0;return l.forEach(E=>{if(!(E.route.id in a))return;let M=E.route.id,T=a[M];if(je(!kn(T),"Cannot handle redirect results in processLoaderData"),Dt(T)){let b=T.error;if(j!==void 0&&(b=j,j=void 0),p=p||{},c)p[M]=b;else{let U=Xr(l,M);p[U.route.id]==null&&(p[U.route.id]=b)}u||(d[M]=rf),y||(y=!0,m=ti(T.error)?T.error.status:500),T.headers&&(x[M]=T.headers)}else d[M]=T.data,T.statusCode&&T.statusCode!==200&&!y&&(m=T.statusCode),T.headers&&(x[M]=T.headers)}),j!==void 0&&o&&(p={[o[0]]:j},o[2]&&(d[o[2]]=void 0)),{loaderData:d,errors:p,statusCode:m||200,loaderHeaders:x}}function _d(l,a,o,u,c,d){let{loaderData:p,errors:m}=ym(a,o,u);return c.filter(y=>!y.matches||y.matches.some(x=>x.shouldLoad)).forEach(y=>{let{key:x,match:j,controller:E}=y;if(E&&E.signal.aborted)return;let M=d[x];if(je(M,"Did not find corresponding fetcher result"),Dt(M)){let T=Xr(l.matches,j==null?void 0:j.route.id);m&&m[T.route.id]||(m={...m,[T.route.id]:M.error}),l.fetchers.delete(x)}else if(kn(M))je(!1,"Unhandled fetcher revalidation redirect");else{let T=kr(M.data);l.fetchers.set(x,T)}}),{loaderData:p,errors:m}}function Md(l,a,o,u){let c=Object.entries(a).filter(([,d])=>d!==rf).reduce((d,[p,m])=>(d[p]=m,d),{});for(let d of o){let p=d.route.id;if(!a.hasOwnProperty(p)&&l.hasOwnProperty(p)&&d.route.loader&&(c[p]=l[p]),u&&u.hasOwnProperty(p))break}return c}function Ld(l){return l?Dt(l[1])?{actionData:{}}:{actionData:{[l[0]]:l[1].data}}:{}}function Xr(l,a){return(a?l.slice(0,l.findIndex(u=>u.route.id===a)+1):[...l]).reverse().find(u=>u.route.hasErrorBoundary===!0)||l[0]}function ga(l){let a=l.length===1?l[0]:l.find(o=>o.index||!o.path||o.path==="/")||{id:"__shim-error-route__"};return{matches:[{params:{},pathname:"",pathnameBase:"",route:a}],route:a}}function Bt(l,{pathname:a,routeId:o,method:u,type:c,message:d}={}){let p="Unknown Server Error",m="Unknown @remix-run/router error";return l===400?(p="Bad Request",u&&a&&o?m=`You made a ${u} request to "${a}" but did not provide a \`loader\` for route "${o}", so there is no way to handle the request.`:c==="invalid-body"&&(m="Unable to encode submission body")):l===403?(p="Forbidden",m=`Route "${o}" does not match URL "${a}"`):l===404?(p="Not Found",m=`No route matches URL "${a}"`):l===405&&(p="Method Not Allowed",u&&a&&o?m=`You made a ${u.toUpperCase()} request to "${a}" but did not provide an \`action\` for route "${o}", so there is no way to handle the request.`:u&&(m=`Invalid request method "${u.toUpperCase()}"`)),new ri(l||500,p,new Error(m),!0)}function ya(l){let a=Object.entries(l);for(let o=a.length-1;o>=0;o--){let[u,c]=a[o];if(kn(c))return{key:u,result:c}}}function uf(l){let a=typeof l=="string"?qr(l):l;return ur({...a,hash:""})}function vm(l,a){return l.pathname!==a.pathname||l.search!==a.search?!1:l.hash===""?a.hash!=="":l.hash===a.hash?!0:a.hash!==""}function xm(l){var a,o;return new ri(((a=l.init)==null?void 0:a.status)??500,((o=l.init)==null?void 0:o.statusText)??"Internal Server Error",l.data)}function wm(l){return l!=null&&typeof l=="object"&&Object.entries(l).every(([a,o])=>typeof a=="string"&&Sm(o))}function Sm(l){return l!=null&&typeof l=="object"&&"type"in l&&"result"in l&&(l.type==="data"||l.type==="error")}function Nm(l){return Cs(l.result)&&ef.has(l.result.status)}function Dt(l){return l.type==="error"}function kn(l){return(l&&l.type)==="redirect"}function zd(l){return typeof l=="object"&&l!=null&&"type"in l&&"data"in l&&"init"in l&&l.type==="DataWithResponseInit"}function Cs(l){return l!=null&&typeof l.status=="number"&&typeof l.statusText=="string"&&typeof l.headers=="object"&&typeof l.body<"u"}function km(l){return ef.has(l)}function Em(l){return Cs(l)&&km(l.status)&&l.headers.has("Location")}function jm(l){return tm.has(l.toUpperCase())}function gt(l){return qp.has(l.toUpperCase())}function Rs(l){return new URLSearchParams(l).getAll("index").some(a=>a==="")}function xa(l,a){let o=typeof a=="string"?qr(a).search:a.search;if(l[l.length-1].route.index&&Rs(o||""))return l[l.length-1];let u=Kd(l);return u[u.length-1]}function Td(l){let{formMethod:a,formAction:o,formEncType:u,text:c,formData:d,json:p}=l;if(!(!a||!o||!u)){if(c!=null)return{formMethod:a,formAction:o,formEncType:u,formData:void 0,json:void 0,text:c};if(d!=null)return{formMethod:a,formAction:o,formEncType:u,formData:d,json:void 0,text:void 0};if(p!==void 0)return{formMethod:a,formAction:o,formEncType:u,formData:void 0,json:p,text:void 0}}}function ps(l,a){return a?{state:"loading",location:l,formMethod:a.formMethod,formAction:a.formAction,formEncType:a.formEncType,formData:a.formData,json:a.json,text:a.text}:{state:"loading",location:l,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0}}function Cm(l,a){return{state:"submitting",location:l,formMethod:a.formMethod,formAction:a.formAction,formEncType:a.formEncType,formData:a.formData,json:a.json,text:a.text}}function Ql(l,a){return l?{state:"loading",formMethod:l.formMethod,formAction:l.formAction,formEncType:l.formEncType,formData:l.formData,json:l.json,text:l.text,data:a}:{state:"loading",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:a}}function Rm(l,a){return{state:"submitting",formMethod:l.formMethod,formAction:l.formAction,formEncType:l.formEncType,formData:l.formData,json:l.json,text:l.text,data:a?a.data:void 0}}function kr(l){return{state:"idle",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:l}}function Pm(l,a){try{let o=l.sessionStorage.getItem(tf);if(o){let u=JSON.parse(o);for(let[c,d]of Object.entries(u||{}))d&&Array.isArray(d)&&a.set(c,new Set(d||[]))}}catch{}}function _m(l,a){if(a.size>0){let o={};for(let[u,c]of a)o[u]=[...c];try{l.sessionStorage.setItem(tf,JSON.stringify(o))}catch(u){tt(!1,`Failed to save applied view transitions in sessionStorage (${u}).`)}}}function Dd(){let l,a,o=new Promise((u,c)=>{l=async d=>{u(d);try{await o}catch{}},a=async d=>{c(d);try{await o}catch{}}});return{promise:o,resolve:l,reject:a}}var jn=_.createContext(null);jn.displayName="DataRouter";var li=_.createContext(null);li.displayName="DataRouterState";var cf=_.createContext(!1);function Mm(){return _.useContext(cf)}var Ps=_.createContext({isTransitioning:!1});Ps.displayName="ViewTransition";var df=_.createContext(new Map);df.displayName="Fetchers";var Lm=_.createContext(null);Lm.displayName="Await";var Yt=_.createContext(null);Yt.displayName="Navigation";var Ea=_.createContext(null);Ea.displayName="Location";var cr=_.createContext({outlet:null,matches:[],isDataRoute:!1});cr.displayName="Route";var _s=_.createContext(null);_s.displayName="RouteError";var ff="REACT_ROUTER_ERROR",zm="REDIRECT",Tm="ROUTE_ERROR_RESPONSE";function Dm(l){if(l.startsWith(`${ff}:${zm}:{`))try{let a=JSON.parse(l.slice(28));if(typeof a=="object"&&a&&typeof a.status=="number"&&typeof a.statusText=="string"&&typeof a.location=="string"&&typeof a.reloadDocument=="boolean"&&typeof a.replace=="boolean")return a}catch{}}function Om(l){if(l.startsWith(`${ff}:${Tm}:{`))try{let a=JSON.parse(l.slice(40));if(typeof a=="object"&&a&&typeof a.status=="number"&&typeof a.statusText=="string")return new ri(a.status,a.statusText,a.data)}catch{}}function Fm(l,{relative:a}={}){je(ii(),"useHref() may be used only in the context of a component.");let{basename:o,navigator:u}=_.useContext(Yt),{hash:c,pathname:d,search:p}=ai(l,{relative:a}),m=d;return o!=="/"&&(m=d==="/"?o:sr([o,d])),u.createHref({pathname:m,search:p,hash:c})}function ii(){return _.useContext(Ea)!=null}function en(){return je(ii(),"useLocation() may be used only in the context of a component."),_.useContext(Ea).location}var hf="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function pf(l){_.useContext(Yt).static||_.useLayoutEffect(l)}function Im(){let{isDataRoute:l}=_.useContext(cr);return l?Zm():Hm()}function Hm(){je(ii(),"useNavigate() may be used only in the context of a component.");let l=_.useContext(jn),{basename:a,navigator:o}=_.useContext(Yt),{matches:u}=_.useContext(cr),{pathname:c}=en(),d=JSON.stringify(ks(u)),p=_.useRef(!1);return pf(()=>{p.current=!0}),_.useCallback((y,x={})=>{if(tt(p.current,hf),!p.current)return;if(typeof y=="number"){o.go(y);return}let j=Es(y,JSON.parse(d),c,x.relative==="path");l==null&&a!=="/"&&(j.pathname=j.pathname==="/"?a:sr([a,j.pathname])),(x.replace?o.replace:o.push)(j,x.state,x)},[a,o,d,c,l])}var Um=_.createContext(null);function Am(l){let a=_.useContext(cr).outlet;return _.useMemo(()=>a&&_.createElement(Um.Provider,{value:l},a),[a,l])}function ai(l,{relative:a}={}){let{matches:o}=_.useContext(cr),{pathname:u}=en(),c=JSON.stringify(ks(o));return _.useMemo(()=>Es(l,JSON.parse(c),u,a==="path"),[l,c,u,a])}function $m(l,a,o,u,c){je(ii(),"useRoutes() may be used only in the context of a component.");let{navigator:d}=_.useContext(Yt),{matches:p}=_.useContext(cr),m=p[p.length-1],y=m?m.params:{},x=m?m.pathname:"/",j=m?m.pathnameBase:"/",E=m&&m.route;{let B=E&&E.path||"";gf(x,!E||B.endsWith("*")||B.endsWith("*?"),`You rendered descendant (or called \`useRoutes()\`) at "${x}" (under ) but the parent route path has no trailing "*". This means if you navigate deeper, the parent won't match anymore and therefore the child routes will never render. + +Please change the parent to .`)}let M=en(),T;T=M;let b=T.pathname||"/",U=b;if(j!=="/"){let B=j.replace(/^\//,"").split("/");U="/"+b.replace(/^\//,"").split("/").slice(B.length).join("/")}let A=Jr(l,{pathname:U});return tt(E||A!=null,`No routes matched location "${T.pathname}${T.search}${T.hash}" `),tt(A==null||A[A.length-1].route.element!==void 0||A[A.length-1].route.Component!==void 0||A[A.length-1].route.lazy!==void 0,`Matched leaf route at location "${T.pathname}${T.search}${T.hash}" does not have an element or Component. This means it will render an with a null value by default resulting in an "empty" page.`),Ym(A&&A.map(B=>Object.assign({},B,{params:Object.assign({},y,B.params),pathname:sr([j,d.encodeLocation?d.encodeLocation(B.pathname.replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:B.pathname]),pathnameBase:B.pathnameBase==="/"?j:sr([j,d.encodeLocation?d.encodeLocation(B.pathnameBase.replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:B.pathnameBase])})),p,o,u,c)}function bm(){let l=Xm(),a=ti(l)?`${l.status} ${l.statusText}`:l instanceof Error?l.message:JSON.stringify(l),o=l instanceof Error?l.stack:null,u="rgba(200,200,200, 0.5)",c={padding:"0.5rem",backgroundColor:u},d={padding:"2px 4px",backgroundColor:u},p=null;return console.error("Error handled by React Router default ErrorBoundary:",l),p=_.createElement(_.Fragment,null,_.createElement("p",null,"💿 Hey developer 👋"),_.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",_.createElement("code",{style:d},"ErrorBoundary")," or"," ",_.createElement("code",{style:d},"errorElement")," prop on your route.")),_.createElement(_.Fragment,null,_.createElement("h2",null,"Unexpected Application Error!"),_.createElement("h3",{style:{fontStyle:"italic"}},a),o?_.createElement("pre",{style:c},o):null,p)}var Wm=_.createElement(bm,null),mf=class extends _.Component{constructor(l){super(l),this.state={location:l.location,revalidation:l.revalidation,error:l.error}}static getDerivedStateFromError(l){return{error:l}}static getDerivedStateFromProps(l,a){return a.location!==l.location||a.revalidation!=="idle"&&l.revalidation==="idle"?{error:l.error,location:l.location,revalidation:l.revalidation}:{error:l.error!==void 0?l.error:a.error,location:a.location,revalidation:l.revalidation||a.revalidation}}componentDidCatch(l,a){this.props.onError?this.props.onError(l,a):console.error("React Router caught the following error during render",l)}render(){let l=this.state.error;if(this.context&&typeof l=="object"&&l&&"digest"in l&&typeof l.digest=="string"){const o=Om(l.digest);o&&(l=o)}let a=l!==void 0?_.createElement(cr.Provider,{value:this.props.routeContext},_.createElement(_s.Provider,{value:l,children:this.props.component})):this.props.children;return this.context?_.createElement(Bm,{error:l},a):a}};mf.contextType=cf;var ms=new WeakMap;function Bm({children:l,error:a}){let{basename:o}=_.useContext(Yt);if(typeof a=="object"&&a&&"digest"in a&&typeof a.digest=="string"){let u=Dm(a.digest);if(u){let c=ms.get(a);if(c)throw c;let d=Xd(u.location,o);if(Jd&&!ms.get(a))if(d.isExternal||u.reloadDocument)window.location.href=d.absoluteURL||d.to;else{const p=Promise.resolve().then(()=>window.__reactRouterDataRouter.navigate(d.to,{replace:u.replace}));throw ms.set(a,p),p}return _.createElement("meta",{httpEquiv:"refresh",content:`0;url=${d.absoluteURL||d.to}`})}}return l}function Vm({routeContext:l,match:a,children:o}){let u=_.useContext(jn);return u&&u.static&&u.staticContext&&(a.route.errorElement||a.route.ErrorBoundary)&&(u.staticContext._deepestRenderedBoundaryId=a.route.id),_.createElement(cr.Provider,{value:l},o)}function Ym(l,a=[],o=null,u=null,c=null){if(l==null){if(!o)return null;if(o.errors)l=o.matches;else if(a.length===0&&!o.initialized&&o.matches.length>0)l=o.matches;else return null}let d=l,p=o==null?void 0:o.errors;if(p!=null){let j=d.findIndex(E=>E.route.id&&(p==null?void 0:p[E.route.id])!==void 0);je(j>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(p).join(",")}`),d=d.slice(0,Math.min(d.length,j+1))}let m=!1,y=-1;if(o)for(let j=0;j=0?d=d.slice(0,y+1):d=[d[0]];break}}}let x=o&&u?(j,E)=>{var M,T;u(j,{location:o.location,params:((T=(M=o.matches)==null?void 0:M[0])==null?void 0:T.params)??{},unstable_pattern:ni(o.matches),errorInfo:E})}:void 0;return d.reduceRight((j,E,M)=>{let T,b=!1,U=null,A=null;o&&(T=p&&E.route.id?p[E.route.id]:void 0,U=E.route.errorElement||Wm,m&&(y<0&&M===0?(gf("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),b=!0,A=null):y===M&&(b=!0,A=E.route.hydrateFallbackElement||null)));let G=a.concat(d.slice(0,M+1)),B=()=>{let re;return T?re=U:b?re=A:E.route.Component?re=_.createElement(E.route.Component,null):E.route.element?re=E.route.element:re=j,_.createElement(Vm,{match:E,routeContext:{outlet:j,matches:G,isDataRoute:o!=null},children:re})};return o&&(E.route.ErrorBoundary||E.route.errorElement||M===0)?_.createElement(mf,{location:o.location,revalidation:o.revalidation,component:U,error:T,children:B(),routeContext:{outlet:null,matches:G,isDataRoute:!0},onError:x}):B()},null)}function Ms(l){return`${l} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function Qm(l){let a=_.useContext(jn);return je(a,Ms(l)),a}function Gm(l){let a=_.useContext(li);return je(a,Ms(l)),a}function Km(l){let a=_.useContext(cr);return je(a,Ms(l)),a}function Ls(l){let a=Km(l),o=a.matches[a.matches.length-1];return je(o.route.id,`${l} can only be used on routes that contain a unique "id"`),o.route.id}function Jm(){return Ls("useRouteId")}function Xm(){var u;let l=_.useContext(_s),a=Gm("useRouteError"),o=Ls("useRouteError");return l!==void 0?l:(u=a.errors)==null?void 0:u[o]}function Zm(){let{router:l}=Qm("useNavigate"),a=Ls("useNavigate"),o=_.useRef(!1);return pf(()=>{o.current=!0}),_.useCallback(async(c,d={})=>{tt(o.current,hf),o.current&&(typeof c=="number"?await l.navigate(c):await l.navigate(c,{fromRouteId:a,...d}))},[l,a])}var Od={};function gf(l,a,o){!a&&!Od[l]&&(Od[l]=!0,tt(!1,o))}var Fd={};function Id(l,a){!l&&!Fd[a]&&(Fd[a]=!0,console.warn(a))}var qm="useOptimistic",Hd=vp[qm],eg=()=>{};function tg(l){return Hd?Hd(l):[l,eg]}function rg(l){let a={hasErrorBoundary:l.hasErrorBoundary||l.ErrorBoundary!=null||l.errorElement!=null};return l.Component&&(l.element&&tt(!1,"You should not include both `Component` and `element` on your route - `Component` will be used."),Object.assign(a,{element:_.createElement(l.Component),Component:void 0})),l.HydrateFallback&&(l.hydrateFallbackElement&&tt(!1,"You should not include both `HydrateFallback` and `hydrateFallbackElement` on your route - `HydrateFallback` will be used."),Object.assign(a,{hydrateFallbackElement:_.createElement(l.HydrateFallback),HydrateFallback:void 0})),l.ErrorBoundary&&(l.errorElement&&tt(!1,"You should not include both `ErrorBoundary` and `errorElement` on your route - `ErrorBoundary` will be used."),Object.assign(a,{errorElement:_.createElement(l.ErrorBoundary),ErrorBoundary:void 0})),a}var ng=["HydrateFallback","hydrateFallbackElement"],lg=class{constructor(){this.status="pending",this.promise=new Promise((l,a)=>{this.resolve=o=>{this.status==="pending"&&(this.status="resolved",l(o))},this.reject=o=>{this.status==="pending"&&(this.status="rejected",a(o))}})}};function ig({router:l,flushSync:a,onError:o,unstable_useTransitions:u}){u=Mm()||u;let[d,p]=_.useState(l.state),[m,y]=tg(d),[x,j]=_.useState(),[E,M]=_.useState({isTransitioning:!1}),[T,b]=_.useState(),[U,A]=_.useState(),[G,B]=_.useState(),re=_.useRef(new Map),we=_.useCallback((ae,{deletedFetchers:he,newErrors:ke,flushSync:_e,viewTransitionOpts:Oe})=>{ke&&o&&Object.values(ke).forEach(ze=>{var Be;return o(ze,{location:ae.location,params:((Be=ae.matches[0])==null?void 0:Be.params)??{},unstable_pattern:ni(ae.matches)})}),ae.fetchers.forEach((ze,Be)=>{ze.data!==void 0&&re.current.set(Be,ze.data)}),he.forEach(ze=>re.current.delete(ze)),Id(_e===!1||a!=null,'You provided the `flushSync` option to a router update, but you are not using the `` from `react-router/dom` so `ReactDOM.flushSync()` is unavailable. Please update your app to `import { RouterProvider } from "react-router/dom"` and ensure you have `react-dom` installed as a dependency to use the `flushSync` option.');let $e=l.window!=null&&l.window.document!=null&&typeof l.window.document.startViewTransition=="function";if(Id(Oe==null||$e,"You provided the `viewTransition` option to a router update, but you do not appear to be running in a DOM environment as `window.startViewTransition` is not available."),!Oe||!$e){a&&_e?a(()=>p(ae)):u===!1?p(ae):_.startTransition(()=>{u===!0&&y(ze=>Ud(ze,ae)),p(ae)});return}if(a&&_e){a(()=>{U&&(T==null||T.resolve(),U.skipTransition()),M({isTransitioning:!0,flushSync:!0,currentLocation:Oe.currentLocation,nextLocation:Oe.nextLocation})});let ze=l.window.document.startViewTransition(()=>{a(()=>p(ae))});ze.finished.finally(()=>{a(()=>{b(void 0),A(void 0),j(void 0),M({isTransitioning:!1})})}),a(()=>A(ze));return}U?(T==null||T.resolve(),U.skipTransition(),B({state:ae,currentLocation:Oe.currentLocation,nextLocation:Oe.nextLocation})):(j(ae),M({isTransitioning:!0,flushSync:!1,currentLocation:Oe.currentLocation,nextLocation:Oe.nextLocation}))},[l.window,a,U,T,u,y,o]);_.useLayoutEffect(()=>l.subscribe(we),[l,we]),_.useEffect(()=>{E.isTransitioning&&!E.flushSync&&b(new lg)},[E]),_.useEffect(()=>{if(T&&x&&l.window){let ae=x,he=T.promise,ke=l.window.document.startViewTransition(async()=>{u===!1?p(ae):_.startTransition(()=>{u===!0&&y(_e=>Ud(_e,ae)),p(ae)}),await he});ke.finished.finally(()=>{b(void 0),A(void 0),j(void 0),M({isTransitioning:!1})}),A(ke)}},[x,T,l.window,u,y]),_.useEffect(()=>{T&&x&&m.location.key===x.location.key&&T.resolve()},[T,U,m.location,x]),_.useEffect(()=>{!E.isTransitioning&&G&&(j(G.state),M({isTransitioning:!0,flushSync:!1,currentLocation:G.currentLocation,nextLocation:G.nextLocation}),B(void 0))},[E.isTransitioning,G]);let ge=_.useMemo(()=>({createHref:l.createHref,encodeLocation:l.encodeLocation,go:ae=>l.navigate(ae),push:(ae,he,ke)=>l.navigate(ae,{state:he,preventScrollReset:ke==null?void 0:ke.preventScrollReset}),replace:(ae,he,ke)=>l.navigate(ae,{replace:!0,state:he,preventScrollReset:ke==null?void 0:ke.preventScrollReset})}),[l]),Ne=l.basename||"/",z=_.useMemo(()=>({router:l,navigator:ge,static:!1,basename:Ne,onError:o}),[l,ge,Ne,o]);return _.createElement(_.Fragment,null,_.createElement(jn.Provider,{value:z},_.createElement(li.Provider,{value:m},_.createElement(df.Provider,{value:re.current},_.createElement(Ps.Provider,{value:E},_.createElement(ug,{basename:Ne,location:m.location,navigationType:m.historyAction,navigator:ge,unstable_useTransitions:u},_.createElement(ag,{routes:l.routes,future:l.future,state:m,onError:o})))))),null)}function Ud(l,a){return{...l,navigation:a.navigation.state!=="idle"?a.navigation:l.navigation,revalidation:a.revalidation!=="idle"?a.revalidation:l.revalidation,actionData:a.navigation.state!=="submitting"?a.actionData:l.actionData,fetchers:a.fetchers}}var ag=_.memo(og);function og({routes:l,future:a,state:o,onError:u}){return $m(l,void 0,o,u,a)}function sg(l){return Am(l.context)}function ug({basename:l="/",children:a=null,location:o,navigationType:u="POP",navigator:c,static:d=!1,unstable_useTransitions:p}){je(!ii(),"You cannot render a inside another . You should never have more than one in your app.");let m=l.replace(/^\/*/,"/"),y=_.useMemo(()=>({basename:m,navigator:c,static:d,unstable_useTransitions:p,future:{}}),[m,c,d,p]);typeof o=="string"&&(o=qr(o));let{pathname:x="/",search:j="",hash:E="",state:M=null,key:T="default"}=o,b=_.useMemo(()=>{let U=Vt(x,m);return U==null?null:{location:{pathname:U,search:j,hash:E,state:M,key:T},navigationType:u}},[m,x,j,E,M,T,u]);return tt(b!=null,` is not able to match the URL "${x}${j}${E}" because it does not start with the basename, so the won't render anything.`),b==null?null:_.createElement(Yt.Provider,{value:y},_.createElement(Ea.Provider,{children:a,value:b}))}var wa="get",Sa="application/x-www-form-urlencoded";function ja(l){return typeof HTMLElement<"u"&&l instanceof HTMLElement}function cg(l){return ja(l)&&l.tagName.toLowerCase()==="button"}function dg(l){return ja(l)&&l.tagName.toLowerCase()==="form"}function fg(l){return ja(l)&&l.tagName.toLowerCase()==="input"}function hg(l){return!!(l.metaKey||l.altKey||l.ctrlKey||l.shiftKey)}function pg(l,a){return l.button===0&&(!a||a==="_self")&&!hg(l)}var va=null;function mg(){if(va===null)try{new FormData(document.createElement("form"),0),va=!1}catch{va=!0}return va}var gg=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function gs(l){return l!=null&&!gg.has(l)?(tt(!1,`"${l}" is not a valid \`encType\` for \`
\`/\`\` and will default to "${Sa}"`),null):l}function yg(l,a){let o,u,c,d,p;if(dg(l)){let m=l.getAttribute("action");u=m?Vt(m,a):null,o=l.getAttribute("method")||wa,c=gs(l.getAttribute("enctype"))||Sa,d=new FormData(l)}else if(cg(l)||fg(l)&&(l.type==="submit"||l.type==="image")){let m=l.form;if(m==null)throw new Error('Cannot submit a