function fp(i,u){for(var a=0;ac[f]})}}}return Object.freeze(Object.defineProperty(i,Symbol.toStringTag,{value:"Module"}))}var vm=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function oc(i){return i&&i.__esModule&&Object.prototype.hasOwnProperty.call(i,"default")?i.default:i}var Bu={exports:{}},we={};/** * @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 zf;function cp(){if(zf)return we;zf=1;var i=Symbol.for("react.element"),u=Symbol.for("react.portal"),a=Symbol.for("react.fragment"),c=Symbol.for("react.strict_mode"),f=Symbol.for("react.profiler"),d=Symbol.for("react.provider"),h=Symbol.for("react.context"),v=Symbol.for("react.forward_ref"),g=Symbol.for("react.suspense"),S=Symbol.for("react.memo"),D=Symbol.for("react.lazy"),O=Symbol.iterator;function L(E){return E===null||typeof E!="object"?null:(E=O&&E[O]||E["@@iterator"],typeof E=="function"?E:null)}var N={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},z=Object.assign,$={};function H(E,F,se){this.props=E,this.context=F,this.refs=$,this.updater=se||N}H.prototype.isReactComponent={},H.prototype.setState=function(E,F){if(typeof E!="object"&&typeof E!="function"&&E!=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,E,F,"setState")},H.prototype.forceUpdate=function(E){this.updater.enqueueForceUpdate(this,E,"forceUpdate")};function M(){}M.prototype=H.prototype;function b(E,F,se){this.props=E,this.context=F,this.refs=$,this.updater=se||N}var J=b.prototype=new M;J.constructor=b,z(J,H.prototype),J.isPureReactComponent=!0;var ae=Array.isArray,C=Object.prototype.hasOwnProperty,le={current:null},pe={key:!0,ref:!0,__self:!0,__source:!0};function ie(E,F,se){var he,me={},Ee=null,De=null;if(F!=null)for(he in F.ref!==void 0&&(De=F.ref),F.key!==void 0&&(Ee=""+F.key),F)C.call(F,he)&&!pe.hasOwnProperty(he)&&(me[he]=F[he]);var Re=arguments.length-2;if(Re===1)me.children=se;else if(1>>1,F=V[E];if(0>>1;Ef(me,Q))Eef(De,me)?(V[E]=De,V[Ee]=Q,E=Ee):(V[E]=me,V[he]=Q,E=he);else if(Eef(De,Q))V[E]=De,V[Ee]=Q,E=Ee;else break e}}return re}function f(V,re){var Q=V.sortIndex-re.sortIndex;return Q!==0?Q:V.id-re.id}if(typeof performance=="object"&&typeof performance.now=="function"){var d=performance;i.unstable_now=function(){return d.now()}}else{var h=Date,v=h.now();i.unstable_now=function(){return h.now()-v}}var g=[],S=[],D=1,O=null,L=3,N=!1,z=!1,$=!1,H=typeof setTimeout=="function"?setTimeout:null,M=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 J(V){for(var re=a(S);re!==null;){if(re.callback===null)c(S);else if(re.startTime<=V)c(S),re.sortIndex=re.expirationTime,u(g,re);else break;re=a(S)}}function ae(V){if($=!1,J(V),!z)if(a(g)!==null)z=!0,Ge(C);else{var re=a(S);re!==null&&Ne(ae,re.startTime-V)}}function C(V,re){z=!1,$&&($=!1,M(ie),ie=-1),N=!0;var Q=L;try{for(J(re),O=a(g);O!==null&&(!(O.expirationTime>re)||V&&!Ke());){var E=O.callback;if(typeof E=="function"){O.callback=null,L=O.priorityLevel;var F=E(O.expirationTime<=re);re=i.unstable_now(),typeof F=="function"?O.callback=F:O===a(g)&&c(g),J(re)}else c(g);O=a(g)}if(O!==null)var se=!0;else{var he=a(S);he!==null&&Ne(ae,he.startTime-re),se=!1}return se}finally{O=null,L=Q,N=!1}}var le=!1,pe=null,ie=-1,ge=5,Ce=-1;function Ke(){return!(i.unstable_now()-CeV||125E?(V.sortIndex=Q,u(S,V),a(g)===null&&V===a(S)&&($?(M(ie),ie=-1):$=!0,Ne(ae,Q-E))):(V.sortIndex=F,u(g,V),z||N||(z=!0,Ge(C))),V},i.unstable_shouldYield=Ke,i.unstable_wrapCallback=function(V){var re=L;return function(){var Q=L;L=re;try{return V.apply(this,arguments)}finally{L=Q}}}}(Qu)),Qu}var If;function hp(){return If||(If=1,Wu.exports=pp()),Wu.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 Uf;function mp(){if(Uf)return Et;Uf=1;var i=uc(),u=hp();function a(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),g=Object.prototype.hasOwnProperty,S=/^[: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]*$/,D={},O={};function L(e){return g.call(O,e)?!0:g.call(D,e)?!1:S.test(e)?O[e]=!0:(D[e]=!0,!1)}function N(e,t,n,r){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function z(e,t,n,r){if(t===null||typeof t>"u"||N(e,t,n,r))return!0;if(r)return!1;if(n!==null)switch(n.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 $(e,t,n,r,l,o,s){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=l,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=o,this.removeEmptyString=s}var H={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){H[e]=new $(e,0,!1,e,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];H[t]=new $(t,1,!1,e[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(e){H[e]=new $(e,2,!1,e.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){H[e]=new $(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){H[e]=new $(e,3,!1,e.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(e){H[e]=new $(e,3,!0,e,null,!1,!1)}),["capture","download"].forEach(function(e){H[e]=new $(e,4,!1,e,null,!1,!1)}),["cols","rows","size","span"].forEach(function(e){H[e]=new $(e,6,!1,e,null,!1,!1)}),["rowSpan","start"].forEach(function(e){H[e]=new $(e,5,!1,e.toLowerCase(),null,!1,!1)});var M=/[\-:]([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(M,b);H[t]=new $(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(M,b);H[t]=new $(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(M,b);H[t]=new $(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(e){H[e]=new $(e,1,!1,e.toLowerCase(),null,!1,!1)}),H.xlinkHref=new $("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(e){H[e]=new $(e,1,!1,e.toLowerCase(),null,!0,!0)});function J(e,t,n,r){var l=H.hasOwnProperty(t)?H[t]:null;(l!==null?l.type!==0:r||!(2p||l[s]!==o[p]){var m=` `+l[s].replace(" at new "," at ");return e.displayName&&m.includes("")&&(m=m.replace("",e.displayName)),m}while(1<=s&&0<=p);break}}}finally{se=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?F(e):""}function me(e){switch(e.tag){case 5:return F(e.type);case 16:return F("Lazy");case 13:return F("Suspense");case 19:return F("SuspenseList");case 0:case 2:case 15:return e=he(e.type,!1),e;case 11:return e=he(e.type.render,!1),e;case 1:return e=he(e.type,!0),e;default:return""}}function Ee(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 pe:return"Fragment";case le:return"Portal";case ge:return"Profiler";case ie:return"StrictMode";case We:return"Suspense";case ut:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Ke:return(e.displayName||"Context")+".Consumer";case Ce:return(e._context.displayName||"Context")+".Provider";case rt:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case _e:return t=e.displayName||null,t!==null?t:Ee(e.type)||"Memo";case Ge:t=e._payload,e=e._init;try{return Ee(e(t))}catch{}}return null}function De(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 Ee(t);case 8:return t===ie?"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 Re(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function ye(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function Ye(e){var t=ye(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var l=n.get,o=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return l.call(this)},set:function(s){r=""+s,o.call(this,s)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(s){r=""+s},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Qn(e){e._valueTracker||(e._valueTracker=Ye(e))}function jl(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=ye(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function Tt(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 Vr(e,t){var n=t.checked;return Q({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function $l(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=Re(t.value!=null?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function Wr(e,t){t=t.checked,t!=null&&J(e,"checked",t,!1)}function Qr(e,t){Wr(e,t);var n=Re(t.value),r=t.type;if(n!=null)r==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?Kr(e,t.type,n):t.hasOwnProperty("defaultValue")&&Kr(e,t.type,Re(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function Al(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!(r!=="submit"&&r!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}function Kr(e,t,n){(t!=="number"||Tt(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var Kn=Array.isArray;function ht(e,t,n,r){if(e=e.options,t){t={};for(var l=0;l"+t.valueOf().toString()+"",t=yn.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function mt(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var vn={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},Bl=["Webkit","ms","Moz","O"];Object.keys(vn).forEach(function(e){Bl.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),vn[t]=vn[e]})});function Xr(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||vn.hasOwnProperty(e)&&vn[e]?(""+t).trim():t+"px"}function Vl(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,l=Xr(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,l):e[n]=l}}var Wl=Q({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 gn(e,t){if(t){if(Wl[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(a(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(a(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(a(61))}if(t.style!=null&&typeof t.style!="object")throw Error(a(62))}}function yr(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 Yn=null;function Gr(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var vr=null,wn=null,ln=null;function Xn(e){if(e=hl(e)){if(typeof vr!="function")throw Error(a(280));var t=e.stateNode;t&&(t=ci(t),vr(e.stateNode,e.type,t))}}function Gn(e){wn?ln?ln.push(e):ln=[e]:wn=e}function Ql(){if(wn){var e=wn,t=ln;if(ln=wn=null,Xn(e),t)for(e=0;e>>=0,e===0?32:31-(Lc(e)/_c|0)|0}var Yl=64,Xl=4194304;function Jr(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 Gl(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,l=e.suspendedLanes,o=e.pingedLanes,s=n&268435455;if(s!==0){var p=s&~l;p!==0?r=Jr(p):(o&=s,o!==0&&(r=Jr(o)))}else s=n&~l,s!==0?r=Jr(s):o!==0&&(r=Jr(o));if(r===0)return 0;if(t!==0&&t!==r&&!(t&l)&&(l=r&-r,o=t&-t,l>=o||l===16&&(o&4194240)!==0))return t;if(r&4&&(r|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0n;n++)t.push(e);return t}function Zr(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-Ht(t),e[t]=n}function Mc(e,t){var n=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 r=e.eventTimes;for(e=e.expirationTimes;0=il),Ra=" ",Pa=!1;function La(e,t){switch(e){case"keyup":return od.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function _a(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var kr=!1;function ad(e,t){switch(e){case"compositionend":return _a(t);case"keypress":return t.which!==32?null:(Pa=!0,Ra);case"textInput":return e=t.data,e===Ra&&Pa?null:e;default:return null}}function sd(e,t){if(kr)return e==="compositionend"||!ko&&La(e,t)?(e=wa(),ei=yo=Pn=null,kr=!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:n,offset:t-e};e=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=Oa(n)}}function Ua(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Ua(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function ja(){for(var e=window,t=Tt();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=Tt(e.document)}return t}function Ro(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 gd(e){var t=ja(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&Ua(n.ownerDocument.documentElement,n)){if(r!==null&&Ro(n)){if(t=r.start,e=r.end,e===void 0&&(e=t),"selectionStart"in n)n.selectionStart=t,n.selectionEnd=Math.min(e,n.value.length);else if(e=(t=n.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var l=n.textContent.length,o=Math.min(r.start,l);r=r.end===void 0?o:Math.min(r.end,l),!e.extend&&o>r&&(l=r,r=o,o=l),l=Ia(n,o);var s=Ia(n,r);l&&s&&(e.rangeCount!==1||e.anchorNode!==l.node||e.anchorOffset!==l.offset||e.focusNode!==s.node||e.focusOffset!==s.offset)&&(t=t.createRange(),t.setStart(l.node,l.offset),e.removeAllRanges(),o>r?(e.addRange(t),e.extend(s.node,s.offset)):(t.setEnd(s.node,s.offset),e.addRange(t)))}}for(t=[],e=n;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n=document.documentMode,xr=null,Po=null,sl=null,Lo=!1;function $a(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Lo||xr==null||xr!==Tt(r)||(r=xr,"selectionStart"in r&&Ro(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),sl&&al(sl,r)||(sl=r,r=ai(Po,"onSelect"),0_r||(e.current=$o[_r],$o[_r]=null,_r--)}function Oe(e,t){_r++,$o[_r]=e.current,e.current=t}var Nn={},at=Tn(Nn),yt=Tn(!1),bn=Nn;function Tr(e,t){var n=e.type.contextTypes;if(!n)return Nn;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var l={},o;for(o in n)l[o]=t[o];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=l),l}function vt(e){return e=e.childContextTypes,e!=null}function di(){Ue(yt),Ue(at)}function es(e,t,n){if(at.current!==Nn)throw Error(a(168));Oe(at,t),Oe(yt,n)}function ts(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var l in r)if(!(l in t))throw Error(a(108,De(e)||"Unknown",l));return Q({},n,r)}function pi(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Nn,bn=at.current,Oe(at,e),Oe(yt,yt.current),!0}function ns(e,t,n){var r=e.stateNode;if(!r)throw Error(a(169));n?(e=ts(e,t,bn),r.__reactInternalMemoizedMergedChildContext=e,Ue(yt),Ue(at),Oe(at,e)):Ue(yt),Oe(yt,n)}var sn=null,hi=!1,Ao=!1;function rs(e){sn===null?sn=[e]:sn.push(e)}function Nd(e){hi=!0,rs(e)}function Dn(){if(!Ao&&sn!==null){Ao=!0;var e=0,t=Te;try{var n=sn;for(Te=1;e>=s,l-=s,fn=1<<32-Ht(t)+l|n<de?(nt=ue,ue=null):nt=ue.sibling;var xe=I(x,ue,R[de],B);if(xe===null){ue===null&&(ue=nt);break}e&&ue&&xe.alternate===null&&t(x,ue),w=o(xe,w,de),oe===null?ne=xe:oe.sibling=xe,oe=xe,ue=nt}if(de===R.length)return n(x,ue),je&&tr(x,de),ne;if(ue===null){for(;dede?(nt=ue,ue=null):nt=ue.sibling;var An=I(x,ue,xe.value,B);if(An===null){ue===null&&(ue=nt);break}e&&ue&&An.alternate===null&&t(x,ue),w=o(An,w,de),oe===null?ne=An:oe.sibling=An,oe=An,ue=nt}if(xe.done)return n(x,ue),je&&tr(x,de),ne;if(ue===null){for(;!xe.done;de++,xe=R.next())xe=A(x,xe.value,B),xe!==null&&(w=o(xe,w,de),oe===null?ne=xe:oe.sibling=xe,oe=xe);return je&&tr(x,de),ne}for(ue=r(x,ue);!xe.done;de++,xe=R.next())xe=Y(ue,x,de,xe.value,B),xe!==null&&(e&&xe.alternate!==null&&ue.delete(xe.key===null?de:xe.key),w=o(xe,w,de),oe===null?ne=xe:oe.sibling=xe,oe=xe);return e&&ue.forEach(function(sp){return t(x,sp)}),je&&tr(x,de),ne}function Qe(x,w,R,B){if(typeof R=="object"&&R!==null&&R.type===pe&&R.key===null&&(R=R.props.children),typeof R=="object"&&R!==null){switch(R.$$typeof){case C:e:{for(var ne=R.key,oe=w;oe!==null;){if(oe.key===ne){if(ne=R.type,ne===pe){if(oe.tag===7){n(x,oe.sibling),w=l(oe,R.props.children),w.return=x,x=w;break e}}else if(oe.elementType===ne||typeof ne=="object"&&ne!==null&&ne.$$typeof===Ge&&ss(ne)===oe.type){n(x,oe.sibling),w=l(oe,R.props),w.ref=ml(x,oe,R),w.return=x,x=w;break e}n(x,oe);break}else t(x,oe);oe=oe.sibling}R.type===pe?(w=sr(R.props.children,x.mode,B,R.key),w.return=x,x=w):(B=Bi(R.type,R.key,R.props,null,x.mode,B),B.ref=ml(x,w,R),B.return=x,x=B)}return s(x);case le:e:{for(oe=R.key;w!==null;){if(w.key===oe)if(w.tag===4&&w.stateNode.containerInfo===R.containerInfo&&w.stateNode.implementation===R.implementation){n(x,w.sibling),w=l(w,R.children||[]),w.return=x,x=w;break e}else{n(x,w);break}else t(x,w);w=w.sibling}w=Uu(R,x.mode,B),w.return=x,x=w}return s(x);case Ge:return oe=R._init,Qe(x,w,oe(R._payload),B)}if(Kn(R))return Z(x,w,R,B);if(re(R))return ee(x,w,R,B);gi(x,R)}return typeof R=="string"&&R!==""||typeof R=="number"?(R=""+R,w!==null&&w.tag===6?(n(x,w.sibling),w=l(w,R),w.return=x,x=w):(n(x,w),w=Iu(R,x.mode,B),w.return=x,x=w),s(x)):n(x,w)}return Qe}var zr=fs(!0),cs=fs(!1),wi=Tn(null),Si=null,Fr=null,Ko=null;function Yo(){Ko=Fr=Si=null}function Xo(e){var t=wi.current;Ue(wi),e._currentValue=t}function Go(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,r!==null&&(r.childLanes|=t)):r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t),e===n)break;e=e.return}}function Or(e,t){Si=e,Ko=Fr=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(gt=!0),e.firstContext=null)}function Ft(e){var t=e._currentValue;if(Ko!==e)if(e={context:e,memoizedValue:t,next:null},Fr===null){if(Si===null)throw Error(a(308));Fr=e,Si.dependencies={lanes:0,firstContext:e}}else Fr=Fr.next=e;return t}var nr=null;function Jo(e){nr===null?nr=[e]:nr.push(e)}function ds(e,t,n,r){var l=t.interleaved;return l===null?(n.next=n,Jo(t)):(n.next=l.next,l.next=n),t.interleaved=n,dn(e,r)}function dn(e,t){e.lanes|=t;var n=e.alternate;for(n!==null&&(n.lanes|=t),n=e,e=e.return;e!==null;)e.childLanes|=t,n=e.alternate,n!==null&&(n.childLanes|=t),n=e,e=e.return;return n.tag===3?n.stateNode:null}var Mn=!1;function Zo(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function ps(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 pn(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function zn(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,ke&2){var l=r.pending;return l===null?t.next=t:(t.next=l.next,l.next=t),r.pending=t,dn(e,n)}return l=r.interleaved,l===null?(t.next=t,Jo(r)):(t.next=l.next,l.next=t),r.interleaved=t,dn(e,n)}function Ei(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,(n&4194240)!==0)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,fo(e,n)}}function hs(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var l=null,o=null;if(n=n.firstBaseUpdate,n!==null){do{var s={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};o===null?l=o=s:o=o.next=s,n=n.next}while(n!==null);o===null?l=o=t:o=o.next=t}else l=o=t;n={baseState:r.baseState,firstBaseUpdate:l,lastBaseUpdate:o,shared:r.shared,effects:r.effects},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function ki(e,t,n,r){var l=e.updateQueue;Mn=!1;var o=l.firstBaseUpdate,s=l.lastBaseUpdate,p=l.shared.pending;if(p!==null){l.shared.pending=null;var m=p,P=m.next;m.next=null,s===null?o=P:s.next=P,s=m;var j=e.alternate;j!==null&&(j=j.updateQueue,p=j.lastBaseUpdate,p!==s&&(p===null?j.firstBaseUpdate=P:p.next=P,j.lastBaseUpdate=m))}if(o!==null){var A=l.baseState;s=0,j=P=m=null,p=o;do{var I=p.lane,Y=p.eventTime;if((r&I)===I){j!==null&&(j=j.next={eventTime:Y,lane:0,tag:p.tag,payload:p.payload,callback:p.callback,next:null});e:{var Z=e,ee=p;switch(I=t,Y=n,ee.tag){case 1:if(Z=ee.payload,typeof Z=="function"){A=Z.call(Y,A,I);break e}A=Z;break e;case 3:Z.flags=Z.flags&-65537|128;case 0:if(Z=ee.payload,I=typeof Z=="function"?Z.call(Y,A,I):Z,I==null)break e;A=Q({},A,I);break e;case 2:Mn=!0}}p.callback!==null&&p.lane!==0&&(e.flags|=64,I=l.effects,I===null?l.effects=[p]:I.push(p))}else Y={eventTime:Y,lane:I,tag:p.tag,payload:p.payload,callback:p.callback,next:null},j===null?(P=j=Y,m=A):j=j.next=Y,s|=I;if(p=p.next,p===null){if(p=l.shared.pending,p===null)break;I=p,p=I.next,I.next=null,l.lastBaseUpdate=I,l.shared.pending=null}}while(!0);if(j===null&&(m=A),l.baseState=m,l.firstBaseUpdate=P,l.lastBaseUpdate=j,t=l.shared.interleaved,t!==null){l=t;do s|=l.lane,l=l.next;while(l!==t)}else o===null&&(l.shared.lanes=0);ir|=s,e.lanes=s,e.memoizedState=A}}function ms(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;tn?n:4,e(!0);var r=nu.transition;nu.transition={};try{e(!1),t()}finally{Te=n,nu.transition=r}}function Fs(){return Ot().memoizedState}function Fd(e,t,n){var r=Un(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},Os(e))Is(t,n);else if(n=ds(e,t,n,r),n!==null){var l=pt();Yt(n,e,r,l),Us(n,t,r)}}function Od(e,t,n){var r=Un(e),l={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(Os(e))Is(t,l);else{var o=e.alternate;if(e.lanes===0&&(o===null||o.lanes===0)&&(o=t.lastRenderedReducer,o!==null))try{var s=t.lastRenderedState,p=o(s,n);if(l.hasEagerState=!0,l.eagerState=p,Bt(p,s)){var m=t.interleaved;m===null?(l.next=l,Jo(t)):(l.next=m.next,m.next=l),t.interleaved=l;return}}catch{}finally{}n=ds(e,t,l,r),n!==null&&(l=pt(),Yt(n,e,r,l),Us(n,t,r))}}function Os(e){var t=e.alternate;return e===He||t!==null&&t===He}function Is(e,t){wl=Ri=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Us(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,fo(e,n)}}var _i={readContext:Ft,useCallback:st,useContext:st,useEffect:st,useImperativeHandle:st,useInsertionEffect:st,useLayoutEffect:st,useMemo:st,useReducer:st,useRef:st,useState:st,useDebugValue:st,useDeferredValue:st,useTransition:st,useMutableSource:st,useSyncExternalStore:st,useId:st,unstable_isNewReconciler:!1},Id={readContext:Ft,useCallback:function(e,t){return bt().memoizedState=[e,t===void 0?null:t],e},useContext:Ft,useEffect:Ps,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,Pi(4194308,4,Ts.bind(null,t,e),n)},useLayoutEffect:function(e,t){return Pi(4194308,4,e,t)},useInsertionEffect:function(e,t){return Pi(4,2,e,t)},useMemo:function(e,t){var n=bt();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=bt();return t=n!==void 0?n(t):t,r.memoizedState=r.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},r.queue=e,e=e.dispatch=Fd.bind(null,He,e),[r.memoizedState,e]},useRef:function(e){var t=bt();return e={current:e},t.memoizedState=e},useState:Cs,useDebugValue:su,useDeferredValue:function(e){return bt().memoizedState=e},useTransition:function(){var e=Cs(!1),t=e[0];return e=zd.bind(null,e[1]),bt().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=He,l=bt();if(je){if(n===void 0)throw Error(a(407));n=n()}else{if(n=t(),tt===null)throw Error(a(349));lr&30||ws(r,t,n)}l.memoizedState=n;var o={value:n,getSnapshot:t};return l.queue=o,Ps(Es.bind(null,r,o,e),[e]),r.flags|=2048,kl(9,Ss.bind(null,r,o,n,t),void 0,null),n},useId:function(){var e=bt(),t=tt.identifierPrefix;if(je){var n=cn,r=fn;n=(r&~(1<<32-Ht(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=Sl++,0<\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=s.createElement(n,{is:r.is}):(e=s.createElement(n),n==="select"&&(s=e,r.multiple?s.multiple=!0:r.size&&(s.size=r.size))):e=s.createElementNS(e,n),e[Zt]=t,e[pl]=r,rf(e,t,!1,!1),t.stateNode=e;e:{switch(s=yr(n,r),n){case"dialog":Ie("cancel",e),Ie("close",e),l=r;break;case"iframe":case"object":case"embed":Ie("load",e),l=r;break;case"video":case"audio":for(l=0;lAr&&(t.flags|=128,r=!0,xl(o,!1),t.lanes=4194304)}else{if(!r)if(e=xi(s),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),xl(o,!0),o.tail===null&&o.tailMode==="hidden"&&!s.alternate&&!je)return ft(t),null}else 2*Fe()-o.renderingStartTime>Ar&&n!==1073741824&&(t.flags|=128,r=!0,xl(o,!1),t.lanes=4194304);o.isBackwards?(s.sibling=t.child,t.child=s):(n=o.last,n!==null?n.sibling=s:t.child=s,o.last=s)}return o.tail!==null?(t=o.tail,o.rendering=t,o.tail=t.sibling,o.renderingStartTime=Fe(),t.sibling=null,n=Ae.current,Oe(Ae,r?n&1|2:n&1),t):(ft(t),null);case 22:case 23:return zu(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?Lt&1073741824&&(ft(t),t.subtreeFlags&6&&(t.flags|=8192)):ft(t),null;case 24:return null;case 25:return null}throw Error(a(156,t.tag))}function Wd(e,t){switch(Bo(t),t.tag){case 1:return vt(t.type)&&di(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Ir(),Ue(yt),Ue(at),tu(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return bo(t),null;case 13:if(Ue(Ae),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(a(340));Mr()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return Ue(Ae),null;case 4:return Ir(),null;case 10:return Xo(t.type._context),null;case 22:case 23:return zu(),null;case 24:return null;default:return null}}var Mi=!1,ct=!1,Qd=typeof WeakSet=="function"?WeakSet:Set,G=null;function jr(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){Ve(e,t,r)}else n.current=null}function Eu(e,t,n){try{n()}catch(r){Ve(e,t,r)}}var uf=!1;function Kd(e,t){if(zo=ql,e=ja(),Ro(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var l=r.anchorOffset,o=r.focusNode;r=r.focusOffset;try{n.nodeType,o.nodeType}catch{n=null;break e}var s=0,p=-1,m=-1,P=0,j=0,A=e,I=null;t:for(;;){for(var Y;A!==n||l!==0&&A.nodeType!==3||(p=s+l),A!==o||r!==0&&A.nodeType!==3||(m=s+r),A.nodeType===3&&(s+=A.nodeValue.length),(Y=A.firstChild)!==null;)I=A,A=Y;for(;;){if(A===e)break t;if(I===n&&++P===l&&(p=s),I===o&&++j===r&&(m=s),(Y=A.nextSibling)!==null)break;A=I,I=A.parentNode}A=Y}n=p===-1||m===-1?null:{start:p,end:m}}else n=null}n=n||{start:0,end:0}}else n=null;for(Fo={focusedElem:e,selectionRange:n},ql=!1,G=t;G!==null;)if(t=G,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,G=e;else for(;G!==null;){t=G;try{var Z=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(Z!==null){var ee=Z.memoizedProps,Qe=Z.memoizedState,x=t.stateNode,w=x.getSnapshotBeforeUpdate(t.elementType===t.type?ee:Wt(t.type,ee),Qe);x.__reactInternalSnapshotBeforeUpdate=w}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(a(163))}}catch(B){Ve(t,t.return,B)}if(e=t.sibling,e!==null){e.return=t.return,G=e;break}G=t.return}return Z=uf,uf=!1,Z}function Cl(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var l=r=r.next;do{if((l.tag&e)===e){var o=l.destroy;l.destroy=void 0,o!==void 0&&Eu(t,n,o)}l=l.next}while(l!==r)}}function zi(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var n=t=t.next;do{if((n.tag&e)===e){var r=n.create;n.destroy=r()}n=n.next}while(n!==t)}}function ku(e){var t=e.ref;if(t!==null){var n=e.stateNode;switch(e.tag){case 5:e=n;break;default:e=n}typeof t=="function"?t(e):t.current=e}}function af(e){var t=e.alternate;t!==null&&(e.alternate=null,af(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[Zt],delete t[pl],delete t[jo],delete t[_d],delete t[Td])),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 sf(e){return e.tag===5||e.tag===3||e.tag===4}function ff(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||sf(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 xu(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=fi));else if(r!==4&&(e=e.child,e!==null))for(xu(e,t,n),e=e.sibling;e!==null;)xu(e,t,n),e=e.sibling}function Cu(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(e=e.child,e!==null))for(Cu(e,t,n),e=e.sibling;e!==null;)Cu(e,t,n),e=e.sibling}var lt=null,Qt=!1;function Fn(e,t,n){for(n=n.child;n!==null;)cf(e,t,n),n=n.sibling}function cf(e,t,n){if(xt&&typeof xt.onCommitFiberUnmount=="function")try{xt.onCommitFiberUnmount(At,n)}catch{}switch(n.tag){case 5:ct||jr(n,t);case 6:var r=lt,l=Qt;lt=null,Fn(e,t,n),lt=r,Qt=l,lt!==null&&(Qt?(e=lt,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):lt.removeChild(n.stateNode));break;case 18:lt!==null&&(Qt?(e=lt,n=n.stateNode,e.nodeType===8?Uo(e.parentNode,n):e.nodeType===1&&Uo(e,n),nl(e)):Uo(lt,n.stateNode));break;case 4:r=lt,l=Qt,lt=n.stateNode.containerInfo,Qt=!0,Fn(e,t,n),lt=r,Qt=l;break;case 0:case 11:case 14:case 15:if(!ct&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){l=r=r.next;do{var o=l,s=o.destroy;o=o.tag,s!==void 0&&(o&2||o&4)&&Eu(n,t,s),l=l.next}while(l!==r)}Fn(e,t,n);break;case 1:if(!ct&&(jr(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(p){Ve(n,t,p)}Fn(e,t,n);break;case 21:Fn(e,t,n);break;case 22:n.mode&1?(ct=(r=ct)||n.memoizedState!==null,Fn(e,t,n),ct=r):Fn(e,t,n);break;default:Fn(e,t,n)}}function df(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new Qd),t.forEach(function(r){var l=tp.bind(null,e,r);n.has(r)||(n.add(r),r.then(l,l))})}}function Kt(e,t){var n=t.deletions;if(n!==null)for(var r=0;rl&&(l=s),r&=~o}if(r=l,r=Fe()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*Xd(r/1960))-r,10e?16:e,In===null)var r=!1;else{if(e=In,In=null,ji=0,ke&6)throw Error(a(331));var l=ke;for(ke|=4,G=e.current;G!==null;){var o=G,s=o.child;if(G.flags&16){var p=o.deletions;if(p!==null){for(var m=0;mFe()-Lu?ur(e,0):Pu|=n),St(e,t)}function Rf(e,t){t===0&&(e.mode&1?(t=Xl,Xl<<=1,!(Xl&130023424)&&(Xl=4194304)):t=1);var n=pt();e=dn(e,t),e!==null&&(Zr(e,t,n),St(e,n))}function ep(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Rf(e,n)}function tp(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,l=e.memoizedState;l!==null&&(n=l.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(a(314))}r!==null&&r.delete(t),Rf(e,n)}var Pf;Pf=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||yt.current)gt=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return gt=!1,Bd(e,t,n);gt=!!(e.flags&131072)}else gt=!1,je&&t.flags&1048576&&ls(t,yi,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;Di(e,t),e=t.pendingProps;var l=Tr(t,at.current);Or(t,n),l=lu(null,t,r,e,l,n);var o=iu();return t.flags|=1,typeof l=="object"&&l!==null&&typeof l.render=="function"&&l.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,vt(r)?(o=!0,pi(t)):o=!1,t.memoizedState=l.state!==null&&l.state!==void 0?l.state:null,Zo(t),l.updater=Ti,t.stateNode=l,l._reactInternals=t,cu(t,r,e,n),t=mu(null,t,r,!0,o,n)):(t.tag=0,je&&o&&Ho(t),dt(null,t,l,n),t=t.child),t;case 16:r=t.elementType;e:{switch(Di(e,t),e=t.pendingProps,l=r._init,r=l(r._payload),t.type=r,l=t.tag=rp(r),e=Wt(r,e),l){case 0:t=hu(null,t,r,e,n);break e;case 1:t=Zs(null,t,r,e,n);break e;case 11:t=Ks(null,t,r,e,n);break e;case 14:t=Ys(null,t,r,Wt(r.type,e),n);break e}throw Error(a(306,r,""))}return t;case 0:return r=t.type,l=t.pendingProps,l=t.elementType===r?l:Wt(r,l),hu(e,t,r,l,n);case 1:return r=t.type,l=t.pendingProps,l=t.elementType===r?l:Wt(r,l),Zs(e,t,r,l,n);case 3:e:{if(qs(t),e===null)throw Error(a(387));r=t.pendingProps,o=t.memoizedState,l=o.element,ps(e,t),ki(t,r,null,n);var s=t.memoizedState;if(r=s.element,o.isDehydrated)if(o={element:r,isDehydrated:!1,cache:s.cache,pendingSuspenseBoundaries:s.pendingSuspenseBoundaries,transitions:s.transitions},t.updateQueue.baseState=o,t.memoizedState=o,t.flags&256){l=Ur(Error(a(423)),t),t=bs(e,t,r,n,l);break e}else if(r!==l){l=Ur(Error(a(424)),t),t=bs(e,t,r,n,l);break e}else for(Pt=_n(t.stateNode.containerInfo.firstChild),Rt=t,je=!0,Vt=null,n=cs(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Mr(),r===l){t=hn(e,t,n);break e}dt(e,t,r,n)}t=t.child}return t;case 5:return ys(t),e===null&&Wo(t),r=t.type,l=t.pendingProps,o=e!==null?e.memoizedProps:null,s=l.children,Oo(r,l)?s=null:o!==null&&Oo(r,o)&&(t.flags|=32),Js(e,t),dt(e,t,s,n),t.child;case 6:return e===null&&Wo(t),null;case 13:return ef(e,t,n);case 4:return qo(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=zr(t,null,r,n):dt(e,t,r,n),t.child;case 11:return r=t.type,l=t.pendingProps,l=t.elementType===r?l:Wt(r,l),Ks(e,t,r,l,n);case 7:return dt(e,t,t.pendingProps,n),t.child;case 8:return dt(e,t,t.pendingProps.children,n),t.child;case 12:return dt(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,l=t.pendingProps,o=t.memoizedProps,s=l.value,Oe(wi,r._currentValue),r._currentValue=s,o!==null)if(Bt(o.value,s)){if(o.children===l.children&&!yt.current){t=hn(e,t,n);break e}}else for(o=t.child,o!==null&&(o.return=t);o!==null;){var p=o.dependencies;if(p!==null){s=o.child;for(var m=p.firstContext;m!==null;){if(m.context===r){if(o.tag===1){m=pn(-1,n&-n),m.tag=2;var P=o.updateQueue;if(P!==null){P=P.shared;var j=P.pending;j===null?m.next=m:(m.next=j.next,j.next=m),P.pending=m}}o.lanes|=n,m=o.alternate,m!==null&&(m.lanes|=n),Go(o.return,n,t),p.lanes|=n;break}m=m.next}}else if(o.tag===10)s=o.type===t.type?null:o.child;else if(o.tag===18){if(s=o.return,s===null)throw Error(a(341));s.lanes|=n,p=s.alternate,p!==null&&(p.lanes|=n),Go(s,n,t),s=o.sibling}else s=o.child;if(s!==null)s.return=o;else for(s=o;s!==null;){if(s===t){s=null;break}if(o=s.sibling,o!==null){o.return=s.return,s=o;break}s=s.return}o=s}dt(e,t,l.children,n),t=t.child}return t;case 9:return l=t.type,r=t.pendingProps.children,Or(t,n),l=Ft(l),r=r(l),t.flags|=1,dt(e,t,r,n),t.child;case 14:return r=t.type,l=Wt(r,t.pendingProps),l=Wt(r.type,l),Ys(e,t,r,l,n);case 15:return Xs(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,l=t.pendingProps,l=t.elementType===r?l:Wt(r,l),Di(e,t),t.tag=1,vt(r)?(e=!0,pi(t)):e=!1,Or(t,n),$s(t,r,l),cu(t,r,l,n),mu(null,t,r,!0,e,n);case 19:return nf(e,t,n);case 22:return Gs(e,t,n)}throw Error(a(156,t.tag))};function Lf(e,t){return kt(e,t)}function np(e,t,n,r){this.tag=e,this.key=n,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=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Ut(e,t,n,r){return new np(e,t,n,r)}function Ou(e){return e=e.prototype,!(!e||!e.isReactComponent)}function rp(e){if(typeof e=="function")return Ou(e)?1:0;if(e!=null){if(e=e.$$typeof,e===rt)return 11;if(e===_e)return 14}return 2}function $n(e,t){var n=e.alternate;return n===null?(n=Ut(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&14680064,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function Bi(e,t,n,r,l,o){var s=2;if(r=e,typeof e=="function")Ou(e)&&(s=1);else if(typeof e=="string")s=5;else e:switch(e){case pe:return sr(n.children,l,o,t);case ie:s=8,l|=8;break;case ge:return e=Ut(12,n,t,l|2),e.elementType=ge,e.lanes=o,e;case We:return e=Ut(13,n,t,l),e.elementType=We,e.lanes=o,e;case ut:return e=Ut(19,n,t,l),e.elementType=ut,e.lanes=o,e;case Ne:return Vi(n,l,o,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Ce:s=10;break e;case Ke:s=9;break e;case rt:s=11;break e;case _e:s=14;break e;case Ge:s=16,r=null;break e}throw Error(a(130,e==null?e:typeof e,""))}return t=Ut(s,n,t,l),t.elementType=e,t.type=r,t.lanes=o,t}function sr(e,t,n,r){return e=Ut(7,e,r,t),e.lanes=n,e}function Vi(e,t,n,r){return e=Ut(22,e,r,t),e.elementType=Ne,e.lanes=n,e.stateNode={isHidden:!1},e}function Iu(e,t,n){return e=Ut(6,e,null,t),e.lanes=n,e}function Uu(e,t,n){return t=Ut(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function lp(e,t,n,r,l){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=so(0),this.expirationTimes=so(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=so(0),this.identifierPrefix=r,this.onRecoverableError=l,this.mutableSourceEagerHydrationData=null}function ju(e,t,n,r,l,o,s,p,m){return e=new lp(e,t,n,p,m),t===1?(t=1,o===!0&&(t|=8)):t=0,o=Ut(3,null,null,t),e.current=o,o.stateNode=e,o.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},Zo(o),e}function ip(e,t,n){var r=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(i)}catch(u){console.error(u)}}return i(),Vu.exports=mp(),Vu.exports}var Tl={},$f;function vp(){if($f)return Tl;$f=1,Object.defineProperty(Tl,"__esModule",{value:!0}),Tl.parse=h,Tl.serialize=S;const i=/^[\u0021-\u003A\u003C\u003E-\u007E]+$/,u=/^[\u0021-\u003A\u003C-\u007E]*$/,a=/^([.]?[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)([.][a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)*$/i,c=/^[\u0020-\u003A\u003D-\u007E]*$/,f=Object.prototype.toString,d=(()=>{const L=function(){};return L.prototype=Object.create(null),L})();function h(L,N){const z=new d,$=L.length;if($<2)return z;const H=(N==null?void 0:N.decode)||D;let M=0;do{const b=L.indexOf("=",M);if(b===-1)break;const J=L.indexOf(";",M),ae=J===-1?$:J;if(b>ae){M=L.lastIndexOf(";",b-1)+1;continue}const C=v(L,M,b),le=g(L,b,C),pe=L.slice(C,le);if(z[pe]===void 0){let ie=v(L,b+1,ae),ge=g(L,ae,ie);const Ce=H(L.slice(ie,ge));z[pe]=Ce}M=ae+1}while(M<$);return z}function v(L,N,z){do{const $=L.charCodeAt(N);if($!==32&&$!==9)return N}while(++Nz;){const $=L.charCodeAt(--N);if($!==32&&$!==9)return N+1}return z}function S(L,N,z){const $=(z==null?void 0:z.encode)||encodeURIComponent;if(!i.test(L))throw new TypeError(`argument name is invalid: ${L}`);const H=$(N);if(!u.test(H))throw new TypeError(`argument val is invalid: ${N}`);let M=L+"="+H;if(!z)return M;if(z.maxAge!==void 0){if(!Number.isInteger(z.maxAge))throw new TypeError(`option maxAge is invalid: ${z.maxAge}`);M+="; Max-Age="+z.maxAge}if(z.domain){if(!a.test(z.domain))throw new TypeError(`option domain is invalid: ${z.domain}`);M+="; Domain="+z.domain}if(z.path){if(!c.test(z.path))throw new TypeError(`option path is invalid: ${z.path}`);M+="; Path="+z.path}if(z.expires){if(!O(z.expires)||!Number.isFinite(z.expires.valueOf()))throw new TypeError(`option expires is invalid: ${z.expires}`);M+="; Expires="+z.expires.toUTCString()}if(z.httpOnly&&(M+="; HttpOnly"),z.secure&&(M+="; Secure"),z.partitioned&&(M+="; Partitioned"),z.priority)switch(typeof z.priority=="string"?z.priority.toLowerCase():void 0){case"low":M+="; Priority=Low";break;case"medium":M+="; Priority=Medium";break;case"high":M+="; Priority=High";break;default:throw new TypeError(`option priority is invalid: ${z.priority}`)}if(z.sameSite)switch(typeof z.sameSite=="string"?z.sameSite.toLowerCase():z.sameSite){case!0:case"strict":M+="; SameSite=Strict";break;case"lax":M+="; SameSite=Lax";break;case"none":M+="; SameSite=None";break;default:throw new TypeError(`option sameSite is invalid: ${z.sameSite}`)}return M}function D(L){if(L.indexOf("%")===-1)return L;try{return decodeURIComponent(L)}catch{return L}}function O(L){return f.call(L)==="[object Date]"}return Tl}vp();/** * react-router v7.1.3 * * Copyright (c) Remix Software Inc. * * This source code is licensed under the MIT license found in the * LICENSE.md file in the root directory of this source tree. * * @license MIT */var Af="popstate";function gp(i={}){function u(c,f){let{pathname:d,search:h,hash:v}=c.location;return Fl("",{pathname:d,search:h,hash:v},f.state&&f.state.usr||null,f.state&&f.state.key||"default")}function a(c,f){return typeof f=="string"?f:Vn(f)}return Sp(u,a,null,i)}function Se(i,u){if(i===!1||i===null||typeof i>"u")throw new Error(u)}function ot(i,u){if(!i){typeof console<"u"&&console.warn(u);try{throw new Error(u)}catch{}}}function wp(){return Math.random().toString(36).substring(2,10)}function Hf(i,u){return{usr:i.state,key:i.key,idx:u}}function Fl(i,u,a=null,c){return{pathname:typeof i=="string"?i:i.pathname,search:"",hash:"",...typeof u=="string"?Wn(u):u,state:a,key:u&&u.key||c||wp()}}function Vn({pathname:i="/",search:u="",hash:a=""}){return u&&u!=="?"&&(i+=u.charAt(0)==="?"?u:"?"+u),a&&a!=="#"&&(i+=a.charAt(0)==="#"?a:"#"+a),i}function Wn(i){let u={};if(i){let a=i.indexOf("#");a>=0&&(u.hash=i.substring(a),i=i.substring(0,a));let c=i.indexOf("?");c>=0&&(u.search=i.substring(c),i=i.substring(0,c)),i&&(u.pathname=i)}return u}function Sp(i,u,a,c={}){let{window:f=document.defaultView,v5Compat:d=!1}=c,h=f.history,v="POP",g=null,S=D();S==null&&(S=0,h.replaceState({...h.state,idx:S},""));function D(){return(h.state||{idx:null}).idx}function O(){v="POP";let H=D(),M=H==null?null:H-S;S=H,g&&g({action:v,location:$.location,delta:M})}function L(H,M){v="PUSH";let b=Fl($.location,H,M);S=D()+1;let J=Hf(b,S),ae=$.createHref(b);try{h.pushState(J,"",ae)}catch(C){if(C instanceof DOMException&&C.name==="DataCloneError")throw C;f.location.assign(ae)}d&&g&&g({action:v,location:$.location,delta:1})}function N(H,M){v="REPLACE";let b=Fl($.location,H,M);S=D();let J=Hf(b,S),ae=$.createHref(b);h.replaceState(J,"",ae),d&&g&&g({action:v,location:$.location,delta:0})}function z(H){let M=f.location.origin!=="null"?f.location.origin:f.location.href,b=typeof H=="string"?H:Vn(H);return b=b.replace(/ $/,"%20"),Se(M,`No window.location.(origin|href) available to create URL for href: ${b}`),new URL(b,M)}let $={get action(){return v},get location(){return i(f,h)},listen(H){if(g)throw new Error("A history only accepts one active listener");return f.addEventListener(Af,O),g=H,()=>{f.removeEventListener(Af,O),g=null}},createHref(H){return u(f,H)},createURL:z,encodeLocation(H){let M=z(H);return{pathname:M.pathname,search:M.search,hash:M.hash}},push:L,replace:N,go(H){return h.go(H)}};return $}var Ep=new Set(["lazy","caseSensitive","path","id","index","children"]);function kp(i){return i.index===!0}function to(i,u,a=[],c={}){return i.map((f,d)=>{let h=[...a,String(d)],v=typeof f.id=="string"?f.id:h.join("-");if(Se(f.index!==!0||!f.children,"Cannot specify children on an index route"),Se(!c[v],`Found a route id collision on id "${v}". Route id's must be globally unique within Data Router usages`),kp(f)){let g={...f,...u(f),id:v};return c[v]=g,g}else{let g={...f,...u(f),id:v,children:void 0};return c[v]=g,f.children&&(g.children=to(f.children,u,h,c)),g}})}function Bn(i,u,a="/"){return qi(i,u,a,!1)}function qi(i,u,a,c){let f=typeof u=="string"?Wn(u):u,d=Gt(f.pathname||"/",a);if(d==null)return null;let h=ac(i);Cp(h);let v=null;for(let g=0;v==null&&g{let g={relativePath:v===void 0?d.path||"":v,caseSensitive:d.caseSensitive===!0,childrenIndex:h,route:d};g.relativePath.startsWith("/")&&(Se(g.relativePath.startsWith(c),`Absolute route path "${g.relativePath}" nested under path "${c}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),g.relativePath=g.relativePath.slice(c.length));let S=tn([c,g.relativePath]),D=a.concat(g);d.children&&d.children.length>0&&(Se(d.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${S}".`),ac(d.children,u,D,S)),!(d.path==null&&!d.index)&&u.push({path:S,score:Dp(S,d.index),routesMeta:D})};return i.forEach((d,h)=>{var v;if(d.path===""||!((v=d.path)!=null&&v.includes("?")))f(d,h);else for(let g of sc(d.path))f(d,h,g)}),u}function sc(i){let u=i.split("/");if(u.length===0)return[];let[a,...c]=u,f=a.endsWith("?"),d=a.replace(/\?$/,"");if(c.length===0)return f?[d,""]:[d];let h=sc(c.join("/")),v=[];return v.push(...h.map(g=>g===""?d:[d,g].join("/"))),f&&v.push(...h),v.map(g=>i.startsWith("/")&&g===""?"/":g)}function Cp(i){i.sort((u,a)=>u.score!==a.score?a.score-u.score:Mp(u.routesMeta.map(c=>c.childrenIndex),a.routesMeta.map(c=>c.childrenIndex)))}var Rp=/^:[\w-]+$/,Pp=3,Lp=2,_p=1,Tp=10,Np=-2,Bf=i=>i==="*";function Dp(i,u){let a=i.split("/"),c=a.length;return a.some(Bf)&&(c+=Np),u&&(c+=Lp),a.filter(f=>!Bf(f)).reduce((f,d)=>f+(Rp.test(d)?Pp:d===""?_p:Tp),c)}function Mp(i,u){return i.length===u.length&&i.slice(0,-1).every((c,f)=>c===u[f])?i[i.length-1]-u[u.length-1]:0}function zp(i,u,a=!1){let{routesMeta:c}=i,f={},d="/",h=[];for(let v=0;v{if(D==="*"){let z=v[L]||"";h=d.slice(0,d.length-z.length).replace(/(.)\/+$/,"$1")}const N=v[L];return O&&!N?S[D]=void 0:S[D]=(N||"").replace(/%2F/g,"/"),S},{}),pathname:d,pathnameBase:h,pattern:i}}function Fp(i,u=!1,a=!0){ot(i==="*"||!i.endsWith("*")||i.endsWith("/*"),`Route path "${i}" will be treated as if it were "${i.replace(/\*$/,"/*")}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${i.replace(/\*$/,"/*")}".`);let c=[],f="^"+i.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(h,v,g)=>(c.push({paramName:v,isOptional:g!=null}),g?"/?([^\\/]+)?":"/([^\\/]+)"));return i.endsWith("*")?(c.push({paramName:"*"}),f+=i==="*"||i==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):a?f+="\\/*$":i!==""&&i!=="/"&&(f+="(?:(?=\\/|$))"),[new RegExp(f,u?void 0:"i"),c]}function Op(i){try{return i.split("/").map(u=>decodeURIComponent(u).replace(/\//g,"%2F")).join("/")}catch(u){return ot(!1,`The URL path "${i}" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (${u}).`),i}}function Gt(i,u){if(u==="/")return i;if(!i.toLowerCase().startsWith(u.toLowerCase()))return null;let a=u.endsWith("/")?u.length-1:u.length,c=i.charAt(a);return c&&c!=="/"?null:i.slice(a)||"/"}function Ip(i,u="/"){let{pathname:a,search:c="",hash:f=""}=typeof i=="string"?Wn(i):i;return{pathname:a?a.startsWith("/")?a:Up(a,u):u,search:$p(c),hash:Ap(f)}}function Up(i,u){let a=u.replace(/\/+$/,"").split("/");return i.split("/").forEach(f=>{f===".."?a.length>1&&a.pop():f!=="."&&a.push(f)}),a.length>1?a.join("/"):"/"}function Ku(i,u,a,c){return`Cannot include a '${i}' character in a manually specified \`to.${u}\` field [${JSON.stringify(c)}]. Please separate it out to the \`to.${a}\` field. Alternatively you may provide the full path as a string in and the router will parse it for you.`}function fc(i){return i.filter((u,a)=>a===0||u.route.path&&u.route.path.length>0)}function bu(i){let u=fc(i);return u.map((a,c)=>c===u.length-1?a.pathname:a.pathnameBase)}function ea(i,u,a,c=!1){let f;typeof i=="string"?f=Wn(i):(f={...i},Se(!f.pathname||!f.pathname.includes("?"),Ku("?","pathname","search",f)),Se(!f.pathname||!f.pathname.includes("#"),Ku("#","pathname","hash",f)),Se(!f.search||!f.search.includes("#"),Ku("#","search","hash",f)));let d=i===""||f.pathname==="",h=d?"/":f.pathname,v;if(h==null)v=a;else{let O=u.length-1;if(!c&&h.startsWith("..")){let L=h.split("/");for(;L[0]==="..";)L.shift(),O-=1;f.pathname=L.join("/")}v=O>=0?u[O]:"/"}let g=Ip(f,v),S=h&&h!=="/"&&h.endsWith("/"),D=(d||h===".")&&a.endsWith("/");return!g.pathname.endsWith("/")&&(S||D)&&(g.pathname+="/"),g}var tn=i=>i.join("/").replace(/\/\/+/g,"/"),jp=i=>i.replace(/\/+$/,"").replace(/^\/*/,"/"),$p=i=>!i||i==="?"?"":i.startsWith("?")?i:"?"+i,Ap=i=>!i||i==="#"?"":i.startsWith("#")?i:"#"+i,ro=class{constructor(i,u,a,c=!1){this.status=i,this.statusText=u||"",this.internal=c,a instanceof Error?(this.data=a.toString(),this.error=a):this.data=a}};function lo(i){return i!=null&&typeof i.status=="number"&&typeof i.statusText=="string"&&typeof i.internal=="boolean"&&"data"in i}var cc=["POST","PUT","PATCH","DELETE"],Hp=new Set(cc),Bp=["GET",...cc],Vp=new Set(Bp),Wp=new Set([301,302,303,307,308]),Qp=new Set([307,308]),Yu={state:"idle",location:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},Kp={state:"idle",data:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},Nl={state:"unblocked",proceed:void 0,reset:void 0,location:void 0},ta=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Yp=i=>({hasErrorBoundary:!!i.hasErrorBoundary}),dc="remix-router-transitions",pc=Symbol("ResetLoaderData");function Xp(i){const u=i.window?i.window:typeof window<"u"?window:void 0,a=typeof u<"u"&&typeof u.document<"u"&&typeof u.document.createElement<"u";Se(i.routes.length>0,"You must provide a non-empty routes array to createRouter");let c=i.mapRouteProperties||Yp,f={},d=to(i.routes,c,void 0,f),h,v=i.basename||"/",g=i.dataStrategy||bp,S=i.patchRoutesOnNavigation,D={...i.future},O=null,L=new Set,N=null,z=null,$=null,H=i.hydrationData!=null,M=Bn(d,i.history.location,v),b=null;if(M==null&&!S){let y=jt(404,{pathname:i.history.location.pathname}),{matches:k,route:_}=bf(d);M=k,b={[_.id]:y}}M&&!i.hydrationData&&Xn(M,d,i.history.location.pathname).active&&(M=null);let J;if(M)if(M.some(y=>y.route.lazy))J=!1;else if(!M.some(y=>y.route.loader))J=!0;else{let y=i.hydrationData?i.hydrationData.loaderData:null,k=i.hydrationData?i.hydrationData.errors:null;if(k){let _=M.findIndex(U=>k[U.route.id]!==void 0);J=M.slice(0,_+1).every(U=>!Zu(U.route,y,k))}else J=M.every(_=>!Zu(_.route,y,k))}else{J=!1,M=[];let y=Xn(null,d,i.history.location.pathname);y.active&&y.matches&&(M=y.matches)}let ae,C={historyAction:i.history.action,location:i.history.location,matches:M,initialized:J,navigation:Yu,restoreScrollPosition:i.hydrationData!=null?!1:null,preventScrollReset:!1,revalidation:"idle",loaderData:i.hydrationData&&i.hydrationData.loaderData||{},actionData:i.hydrationData&&i.hydrationData.actionData||null,errors:i.hydrationData&&i.hydrationData.errors||b,fetchers:new Map,blockers:new Map},le="POP",pe=!1,ie,ge=!1,Ce=new Map,Ke=null,rt=!1,We=!1,ut=new Set,_e=new Map,Ge=0,Ne=-1,V=new Map,re=new Set,Q=new Map,E=new Map,F=new Set,se=new Map,he,me=null;function Ee(){if(O=i.history.listen(({action:y,location:k,delta:_})=>{if(he){he(),he=void 0;return}ot(se.size===0||_!=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 U=yr({currentLocation:C.location,nextLocation:k,historyAction:y});if(U&&_!=null){let K=new Promise(te=>{he=te});i.history.go(_*-1),gn(U,{state:"blocked",location:k,proceed(){gn(U,{state:"proceeding",proceed:void 0,reset:void 0,location:k}),K.then(()=>i.history.go(_))},reset(){let te=new Map(C.blockers);te.set(U,Nl),ye({blockers:te})}});return}return Tt(y,k)}),a){fh(u,Ce);let y=()=>ch(u,Ce);u.addEventListener("pagehide",y),Ke=()=>u.removeEventListener("pagehide",y)}return C.initialized||Tt("POP",C.location,{initialHydration:!0}),ae}function De(){O&&O(),Ke&&Ke(),L.clear(),ie&&ie.abort(),C.fetchers.forEach((y,k)=>yn(k)),C.blockers.forEach((y,k)=>Wl(k))}function Re(y){return L.add(y),()=>L.delete(y)}function ye(y,k={}){C={...C,...y};let _=[],U=[];C.fetchers.forEach((K,te)=>{K.state==="idle"&&(F.has(te)?_.push(te):U.push(te))}),F.forEach(K=>{!C.fetchers.has(K)&&!_e.has(K)&&_.push(K)}),[...L].forEach(K=>K(C,{deletedFetchers:_,viewTransitionOpts:k.viewTransitionOpts,flushSync:k.flushSync===!0})),_.forEach(K=>yn(K)),U.forEach(K=>C.fetchers.delete(K))}function Ye(y,k,{flushSync:_}={}){var W,ce;let U=C.actionData!=null&&C.navigation.formMethod!=null&&Xt(C.navigation.formMethod)&&C.navigation.state==="loading"&&((W=y.state)==null?void 0:W._isRedirect)!==!0,K;k.actionData?Object.keys(k.actionData).length>0?K=k.actionData:K=null:U?K=C.actionData:K=null;let te=k.loaderData?Zf(C.loaderData,k.loaderData,k.matches||[],k.errors):C.loaderData,fe=C.blockers;fe.size>0&&(fe=new Map(fe),fe.forEach((ve,ze)=>fe.set(ze,Nl)));let X=pe===!0||C.navigation.formMethod!=null&&Xt(C.navigation.formMethod)&&((ce=y.state)==null?void 0:ce._isRedirect)!==!0;h&&(d=h,h=void 0),rt||le==="POP"||(le==="PUSH"?i.history.push(y,y.state):le==="REPLACE"&&i.history.replace(y,y.state));let q;if(le==="POP"){let ve=Ce.get(C.location.pathname);ve&&ve.has(y.pathname)?q={currentLocation:C.location,nextLocation:y}:Ce.has(y.pathname)&&(q={currentLocation:y,nextLocation:C.location})}else if(ge){let ve=Ce.get(C.location.pathname);ve?ve.add(y.pathname):(ve=new Set([y.pathname]),Ce.set(C.location.pathname,ve)),q={currentLocation:C.location,nextLocation:y}}ye({...k,actionData:K,loaderData:te,historyAction:le,location:y,initialized:!0,navigation:Yu,revalidation:"idle",restoreScrollPosition:ln(y,k.matches||C.matches),preventScrollReset:X,blockers:fe},{viewTransitionOpts:q,flushSync:_===!0}),le="POP",pe=!1,ge=!1,rt=!1,We=!1,me==null||me.resolve(),me=null}async function Qn(y,k){if(typeof y=="number"){i.history.go(y);return}let _=Ju(C.location,C.matches,v,y,k==null?void 0:k.fromRouteId,k==null?void 0:k.relative),{path:U,submission:K,error:te}=Vf(!1,_,k),fe=C.location,X=Fl(C.location,U,k&&k.state);X={...X,...i.history.encodeLocation(X)};let q=k&&k.replace!=null?k.replace:void 0,W="PUSH";q===!0?W="REPLACE":q===!1||K!=null&&Xt(K.formMethod)&&K.formAction===C.location.pathname+C.location.search&&(W="REPLACE");let ce=k&&"preventScrollReset"in k?k.preventScrollReset===!0:void 0,ve=(k&&k.flushSync)===!0,ze=yr({currentLocation:fe,nextLocation:X,historyAction:W});if(ze){gn(ze,{state:"blocked",location:X,proceed(){gn(ze,{state:"proceeding",proceed:void 0,reset:void 0,location:X}),Qn(y,k)},reset(){let Je=new Map(C.blockers);Je.set(ze,Nl),ye({blockers:Je})}});return}await Tt(W,X,{submission:K,pendingError:te,preventScrollReset:ce,replace:k&&k.replace,enableViewTransition:k&&k.viewTransition,flushSync:ve})}function jl(){me||(me=dh()),hr(),ye({revalidation:"loading"});let y=me.promise;return C.navigation.state==="submitting"?y:C.navigation.state==="idle"?(Tt(C.historyAction,C.location,{startUninterruptedRevalidation:!0}),y):(Tt(le||C.historyAction,C.navigation.location,{overrideNavigation:C.navigation,enableViewTransition:ge===!0}),y)}async function Tt(y,k,_){ie&&ie.abort(),ie=null,le=y,rt=(_&&_.startUninterruptedRevalidation)===!0,wn(C.location,C.matches),pe=(_&&_.preventScrollReset)===!0,ge=(_&&_.enableViewTransition)===!0;let U=h||d,K=_&&_.overrideNavigation,te=Bn(U,k,v),fe=(_&&_.flushSync)===!0,X=Xn(te,U,k.pathname);if(X.active&&X.matches&&(te=X.matches),!te){let{error:Pe,notFoundMatches:Me,route:Be}=Yn(k.pathname);Ye(k,{matches:Me,loaderData:{},errors:{[Be.id]:Pe}},{flushSync:fe});return}if(C.initialized&&!We&&ih(C.location,k)&&!(_&&_.submission&&Xt(_.submission.formMethod))){Ye(k,{matches:te},{flushSync:fe});return}ie=new AbortController;let q=Br(i.history,k,ie.signal,_&&_.submission),W;if(_&&_.pendingError)W=[fr(te).route.id,{type:"error",error:_.pendingError}];else if(_&&_.submission&&Xt(_.submission.formMethod)){let Pe=await Vr(q,k,_.submission,te,X.active,{replace:_.replace,flushSync:fe});if(Pe.shortCircuited)return;if(Pe.pendingActionResult){let[Me,Be]=Pe.pendingActionResult;if(_t(Be)&&lo(Be.error)&&Be.error.status===404){ie=null,Ye(k,{matches:Pe.matches,loaderData:{},errors:{[Me]:Be.error}});return}}te=Pe.matches||te,W=Pe.pendingActionResult,K=Xu(k,_.submission),fe=!1,X.active=!1,q=Br(i.history,q.url,q.signal)}let{shortCircuited:ce,matches:ve,loaderData:ze,errors:Je}=await $l(q,k,te,X.active,K,_&&_.submission,_&&_.fetcherSubmission,_&&_.replace,_&&_.initialHydration===!0,fe,W);ce||(ie=null,Ye(k,{matches:ve||te,...qf(W),loaderData:ze,errors:Je}))}async function Vr(y,k,_,U,K,te={}){hr();let fe=ah(k,_);if(ye({navigation:fe},{flushSync:te.flushSync===!0}),K){let W=await Gn(U,k.pathname,y.signal);if(W.type==="aborted")return{shortCircuited:!0};if(W.type==="error"){let ce=fr(W.partialMatches).route.id;return{matches:W.partialMatches,pendingActionResult:[ce,{type:"error",error:W.error}]}}else if(W.matches)U=W.matches;else{let{notFoundMatches:ce,error:ve,route:ze}=Yn(k.pathname);return{matches:ce,pendingActionResult:[ze.id,{type:"error",error:ve}]}}}let X,q=zl(U,k);if(!q.route.action&&!q.route.lazy)X={type:"error",error:jt(405,{method:y.method,pathname:k.pathname,routeId:q.route.id})};else if(X=(await rn("action",C,y,[q],U,null))[q.route.id],y.signal.aborted)return{shortCircuited:!0};if(cr(X)){let W;return te&&te.replace!=null?W=te.replace:W=Xf(X.response.headers.get("Location"),new URL(y.url),v)===C.location.pathname+C.location.search,await ht(y,X,!0,{submission:_,replace:W}),{shortCircuited:!0}}if(_t(X)){let W=fr(U,q.route.id);return(te&&te.replace)!==!0&&(le="PUSH"),{matches:U,pendingActionResult:[W.route.id,X]}}return{matches:U,pendingActionResult:[q.route.id,X]}}async function $l(y,k,_,U,K,te,fe,X,q,W,ce){let ve=K||Xu(k,te),ze=te||fe||tc(ve),Je=!rt&&!q;if(U){if(Je){let Ze=Wr(ce);ye({navigation:ve,...Ze!==void 0?{actionData:Ze}:{}},{flushSync:W})}let Le=await Gn(_,k.pathname,y.signal);if(Le.type==="aborted")return{shortCircuited:!0};if(Le.type==="error"){let Ze=fr(Le.partialMatches).route.id;return{matches:Le.partialMatches,loaderData:{},errors:{[Ze]:Le.error}}}else if(Le.matches)_=Le.matches;else{let{error:Ze,notFoundMatches:un,route:Zn}=Yn(k.pathname);return{matches:un,loaderData:{},errors:{[Zn.id]:Ze}}}}let Pe=h||d,[Me,Be]=Qf(i.history,C,_,ze,k,q===!0,We,ut,F,Q,re,Pe,v,ce);if(Ne=++Ge,Me.length===0&&Be.length===0){let Le=Bl();return Ye(k,{matches:_,loaderData:{},errors:ce&&_t(ce[1])?{[ce[0]]:ce[1].error}:null,...qf(ce),...Le?{fetchers:new Map(C.fetchers)}:{}},{flushSync:W}),{shortCircuited:!0}}if(Je){let Le={};if(!U){Le.navigation=ve;let Ze=Wr(ce);Ze!==void 0&&(Le.actionData=Ze)}Be.length>0&&(Le.fetchers=Qr(Be)),ye(Le,{flushSync:W})}Be.forEach(Le=>{mt(Le.key),Le.controller&&_e.set(Le.key,Le.controller)});let Sn=()=>Be.forEach(Le=>mt(Le.key));ie&&ie.signal.addEventListener("abort",Sn);let{loaderResults:En,fetcherResults:Dt}=await Yr(C,_,Me,Be,y);if(y.signal.aborted)return{shortCircuited:!0};ie&&ie.signal.removeEventListener("abort",Sn),Be.forEach(Le=>_e.delete(Le.key));let kt=Ji(En);if(kt)return await ht(y,kt.result,!0,{replace:X}),{shortCircuited:!0};if(kt=Ji(Dt),kt)return re.add(kt.key),await ht(y,kt.result,!0,{replace:X}),{shortCircuited:!0};let{loaderData:gr,errors:Jn}=Jf(C,_,En,ce,Be,Dt);q&&C.errors&&(Jn={...C.errors,...Jn});let on=Bl(),Fe=Xr(Ne),wr=on||Fe||Be.length>0;return{matches:_,loaderData:gr,errors:Jn,...wr?{fetchers:new Map(C.fetchers)}:{}}}function Wr(y){if(y&&!_t(y[1]))return{[y[0]]:y[1].data};if(C.actionData)return Object.keys(C.actionData).length===0?null:C.actionData}function Qr(y){return y.forEach(k=>{let _=C.fetchers.get(k.key),U=Dl(void 0,_?_.data:void 0);C.fetchers.set(k.key,U)}),new Map(C.fetchers)}async function Al(y,k,_,U){mt(y);let K=(U&&U.flushSync)===!0,te=h||d,fe=Ju(C.location,C.matches,v,_,k,U==null?void 0:U.relative),X=Bn(te,fe,v),q=Xn(X,te,fe);if(q.active&&q.matches&&(X=q.matches),!X){Nt(y,k,jt(404,{pathname:fe}),{flushSync:K});return}let{path:W,submission:ce,error:ve}=Vf(!0,fe,U);if(ve){Nt(y,k,ve,{flushSync:K});return}let ze=zl(X,W),Je=(U&&U.preventScrollReset)===!0;if(ce&&Xt(ce.formMethod)){await Kr(y,k,W,ze,X,q.active,K,Je,ce);return}Q.set(y,{routeId:k,path:W}),await Kn(y,k,W,ze,X,q.active,K,Je,ce)}async function Kr(y,k,_,U,K,te,fe,X,q){hr(),Q.delete(y);function W($e){if(!$e.route.action&&!$e.route.lazy){let At=jt(405,{method:q.formMethod,pathname:_,routeId:k});return Nt(y,k,At,{flushSync:fe}),!0}return!1}if(!te&&W(U))return;let ce=C.fetchers.get(y);$t(y,sh(q,ce),{flushSync:fe});let ve=new AbortController,ze=Br(i.history,_,ve.signal,q);if(te){let $e=await Gn(K,_,ze.signal);if($e.type==="aborted")return;if($e.type==="error"){Nt(y,k,$e.error,{flushSync:fe});return}else if($e.matches){if(K=$e.matches,U=zl(K,_),W(U))return}else{Nt(y,k,jt(404,{pathname:_}),{flushSync:fe});return}}_e.set(y,ve);let Je=Ge,Me=(await rn("action",C,ze,[U],K,y))[U.route.id];if(ze.signal.aborted){_e.get(y)===ve&&_e.delete(y);return}if(F.has(y)){if(cr(Me)||_t(Me)){$t(y,Hn(void 0));return}}else{if(cr(Me))if(_e.delete(y),Ne>Je){$t(y,Hn(void 0));return}else return re.add(y),$t(y,Dl(q)),ht(ze,Me,!1,{fetcherSubmission:q,preventScrollReset:X});if(_t(Me)){Nt(y,k,Me.error);return}}let Be=C.navigation.location||C.location,Sn=Br(i.history,Be,ve.signal),En=h||d,Dt=C.navigation.state!=="idle"?Bn(En,C.navigation.location,v):C.matches;Se(Dt,"Didn't find any matches after fetcher action");let kt=++Ge;V.set(y,kt);let gr=Dl(q,Me.data);C.fetchers.set(y,gr);let[Jn,on]=Qf(i.history,C,Dt,q,Be,!1,We,ut,F,Q,re,En,v,[U.route.id,Me]);on.filter($e=>$e.key!==y).forEach($e=>{let At=$e.key,xt=C.fetchers.get(At),uo=Dl(void 0,xt?xt.data:void 0);C.fetchers.set(At,uo),mt(At),$e.controller&&_e.set(At,$e.controller)}),ye({fetchers:new Map(C.fetchers)});let Fe=()=>on.forEach($e=>mt($e.key));ve.signal.addEventListener("abort",Fe);let{loaderResults:wr,fetcherResults:Le}=await Yr(C,Dt,Jn,on,Sn);if(ve.signal.aborted)return;ve.signal.removeEventListener("abort",Fe),V.delete(y),_e.delete(y),on.forEach($e=>_e.delete($e.key));let Ze=Ji(wr);if(Ze)return ht(Sn,Ze.result,!1,{preventScrollReset:X});if(Ze=Ji(Le),Ze)return re.add(Ze.key),ht(Sn,Ze.result,!1,{preventScrollReset:X});let{loaderData:un,errors:Zn}=Jf(C,Dt,wr,void 0,on,Le);if(C.fetchers.has(y)){let $e=Hn(Me.data);C.fetchers.set(y,$e)}Xr(kt),C.navigation.state==="loading"&&kt>Ne?(Se(le,"Expected pending action"),ie&&ie.abort(),Ye(C.navigation.location,{matches:Dt,loaderData:un,errors:Zn,fetchers:new Map(C.fetchers)})):(ye({errors:Zn,loaderData:Zf(C.loaderData,un,Dt,Zn),fetchers:new Map(C.fetchers)}),We=!1)}async function Kn(y,k,_,U,K,te,fe,X,q){let W=C.fetchers.get(y);$t(y,Dl(q,W?W.data:void 0),{flushSync:fe});let ce=new AbortController,ve=Br(i.history,_,ce.signal);if(te){let Me=await Gn(K,_,ve.signal);if(Me.type==="aborted")return;if(Me.type==="error"){Nt(y,k,Me.error,{flushSync:fe});return}else if(Me.matches)K=Me.matches,U=zl(K,_);else{Nt(y,k,jt(404,{pathname:_}),{flushSync:fe});return}}_e.set(y,ce);let ze=Ge,Pe=(await rn("loader",C,ve,[U],K,y))[U.route.id];if(_e.get(y)===ce&&_e.delete(y),!ve.signal.aborted){if(F.has(y)){$t(y,Hn(void 0));return}if(cr(Pe))if(Ne>ze){$t(y,Hn(void 0));return}else{re.add(y),await ht(ve,Pe,!1,{preventScrollReset:X});return}if(_t(Pe)){Nt(y,k,Pe.error);return}$t(y,Hn(Pe.data))}}async function ht(y,k,_,{submission:U,fetcherSubmission:K,preventScrollReset:te,replace:fe}={}){k.response.headers.has("X-Remix-Revalidate")&&(We=!0);let X=k.response.headers.get("Location");Se(X,"Expected a Location header on the redirect Response"),X=Xf(X,new URL(y.url),v);let q=Fl(C.location,X,{_isRedirect:!0});if(a){let Pe=!1;if(k.response.headers.has("X-Remix-Reload-Document"))Pe=!0;else if(ta.test(X)){const Me=i.history.createURL(X);Pe=Me.origin!==u.location.origin||Gt(Me.pathname,v)==null}if(Pe){fe?u.location.replace(X):u.location.assign(X);return}}ie=null;let W=fe===!0||k.response.headers.has("X-Remix-Replace")?"REPLACE":"PUSH",{formMethod:ce,formAction:ve,formEncType:ze}=C.navigation;!U&&!K&&ce&&ve&&ze&&(U=tc(C.navigation));let Je=U||K;if(Qp.has(k.response.status)&&Je&&Xt(Je.formMethod))await Tt(W,q,{submission:{...Je,formAction:X},preventScrollReset:te||pe,enableViewTransition:_?ge:void 0});else{let Pe=Xu(q,U);await Tt(W,q,{overrideNavigation:Pe,fetcherSubmission:K,preventScrollReset:te||pe,enableViewTransition:_?ge:void 0})}}async function rn(y,k,_,U,K,te){let fe,X={};try{fe=await eh(g,y,k,_,U,K,te,f,c)}catch(q){return U.forEach(W=>{X[W.route.id]={type:"error",error:q}}),X}for(let[q,W]of Object.entries(fe))if(oh(W)){let ce=W.result;X[q]={type:"redirect",response:rh(ce,_,q,K,v)}}else X[q]=await nh(W);return X}async function Yr(y,k,_,U,K){let te=rn("loader",y,K,_,k,null),fe=Promise.all(U.map(async W=>{if(W.matches&&W.match&&W.controller){let ve=(await rn("loader",y,Br(i.history,W.path,W.controller.signal),[W.match],W.matches,W.key))[W.match.route.id];return{[W.key]:ve}}else return Promise.resolve({[W.key]:{type:"error",error:jt(404,{pathname:W.path})}})})),X=await te,q=(await fe).reduce((W,ce)=>Object.assign(W,ce),{});return{loaderResults:X,fetcherResults:q}}function hr(){We=!0,Q.forEach((y,k)=>{_e.has(k)&&ut.add(k),mt(k)})}function $t(y,k,_={}){C.fetchers.set(y,k),ye({fetchers:new Map(C.fetchers)},{flushSync:(_&&_.flushSync)===!0})}function Nt(y,k,_,U={}){let K=fr(C.matches,k);yn(y),ye({errors:{[K.route.id]:_},fetchers:new Map(C.fetchers)},{flushSync:(U&&U.flushSync)===!0})}function mr(y){return E.set(y,(E.get(y)||0)+1),F.has(y)&&F.delete(y),C.fetchers.get(y)||Kp}function yn(y){let k=C.fetchers.get(y);_e.has(y)&&!(k&&k.state==="loading"&&V.has(y))&&mt(y),Q.delete(y),V.delete(y),re.delete(y),F.delete(y),ut.delete(y),C.fetchers.delete(y)}function Hl(y){let k=(E.get(y)||0)-1;k<=0?(E.delete(y),F.add(y)):E.set(y,k),ye({fetchers:new Map(C.fetchers)})}function mt(y){let k=_e.get(y);k&&(k.abort(),_e.delete(y))}function vn(y){for(let k of y){let _=mr(k),U=Hn(_.data);C.fetchers.set(k,U)}}function Bl(){let y=[],k=!1;for(let _ of re){let U=C.fetchers.get(_);Se(U,`Expected fetcher: ${_}`),U.state==="loading"&&(re.delete(_),y.push(_),k=!0)}return vn(y),k}function Xr(y){let k=[];for(let[_,U]of V)if(U0}function Vl(y,k){let _=C.blockers.get(y)||Nl;return se.get(y)!==k&&se.set(y,k),_}function Wl(y){C.blockers.delete(y),se.delete(y)}function gn(y,k){let _=C.blockers.get(y)||Nl;Se(_.state==="unblocked"&&k.state==="blocked"||_.state==="blocked"&&k.state==="blocked"||_.state==="blocked"&&k.state==="proceeding"||_.state==="blocked"&&k.state==="unblocked"||_.state==="proceeding"&&k.state==="unblocked",`Invalid blocker state transition: ${_.state} -> ${k.state}`);let U=new Map(C.blockers);U.set(y,k),ye({blockers:U})}function yr({currentLocation:y,nextLocation:k,historyAction:_}){if(se.size===0)return;se.size>1&&ot(!1,"A router only supports one blocker at a time");let U=Array.from(se.entries()),[K,te]=U[U.length-1],fe=C.blockers.get(K);if(!(fe&&fe.state==="proceeding")&&te({currentLocation:y,nextLocation:k,historyAction:_}))return K}function Yn(y){let k=jt(404,{pathname:y}),_=h||d,{matches:U,route:K}=bf(_);return{notFoundMatches:U,route:K,error:k}}function Gr(y,k,_){if(N=y,$=k,z=_||null,!H&&C.navigation===Yu){H=!0;let U=ln(C.location,C.matches);U!=null&&ye({restoreScrollPosition:U})}return()=>{N=null,$=null,z=null}}function vr(y,k){return z&&z(y,k.map(U=>xp(U,C.loaderData)))||y.key}function wn(y,k){if(N&&$){let _=vr(y,k);N[_]=$()}}function ln(y,k){if(N){let _=vr(y,k),U=N[_];if(typeof U=="number")return U}return null}function Xn(y,k,_){if(S)if(y){if(Object.keys(y[0].params).length>0)return{active:!0,matches:qi(k,_,v,!0)}}else return{active:!0,matches:qi(k,_,v,!0)||[]};return{active:!1,matches:null}}async function Gn(y,k,_){if(!S)return{type:"success",matches:y};let U=y;for(;;){let K=h==null,te=h||d,fe=f;try{await S({path:k,matches:U,patch:(W,ce)=>{_.aborted||Yf(W,ce,te,fe,c)}})}catch(W){return{type:"error",error:W,partialMatches:U}}finally{K&&!_.aborted&&(d=[...d])}if(_.aborted)return{type:"aborted"};let X=Bn(te,k,v);if(X)return{type:"success",matches:X};let q=qi(te,k,v,!0);if(!q||U.length===q.length&&U.every((W,ce)=>W.route.id===q[ce].route.id))return{type:"success",matches:null};U=q}}function Ql(y){f={},h=to(y,c,void 0,f)}function Kl(y,k){let _=h==null;Yf(y,k,h||d,f,c),_&&(d=[...d],ye({}))}return ae={get basename(){return v},get future(){return D},get state(){return C},get routes(){return d},get window(){return u},initialize:Ee,subscribe:Re,enableScrollRestoration:Gr,navigate:Qn,fetch:Al,revalidate:jl,createHref:y=>i.history.createHref(y),encodeLocation:y=>i.history.encodeLocation(y),getFetcher:mr,deleteFetcher:Hl,dispose:De,getBlocker:Vl,deleteBlocker:Wl,patchRoutes:Kl,_internalFetchControllers:_e,_internalSetRoutes:Ql},ae}function Gp(i){return i!=null&&("formData"in i&&i.formData!=null||"body"in i&&i.body!==void 0)}function Ju(i,u,a,c,f,d){let h,v;if(f){h=[];for(let S of u)if(h.push(S),S.route.id===f){v=S;break}}else h=u,v=u[u.length-1];let g=ea(c||".",bu(h),Gt(i.pathname,a)||i.pathname,d==="path");if(c==null&&(g.search=i.search,g.hash=i.hash),(c==null||c===""||c===".")&&v){let S=na(g.search);if(v.route.index&&!S)g.search=g.search?g.search.replace(/^\?/,"?index&"):"?index";else if(!v.route.index&&S){let D=new URLSearchParams(g.search),O=D.getAll("index");D.delete("index"),O.filter(N=>N).forEach(N=>D.append("index",N));let L=D.toString();g.search=L?`?${L}`:""}}return a!=="/"&&(g.pathname=g.pathname==="/"?a:tn([a,g.pathname])),Vn(g)}function Vf(i,u,a){if(!a||!Gp(a))return{path:u};if(a.formMethod&&!uh(a.formMethod))return{path:u,error:jt(405,{method:a.formMethod})};let c=()=>({path:u,error:jt(400,{type:"invalid-body"})}),d=(a.formMethod||"get").toUpperCase(),h=mc(u);if(a.body!==void 0){if(a.formEncType==="text/plain"){if(!Xt(d))return c();let O=typeof a.body=="string"?a.body:a.body instanceof FormData||a.body instanceof URLSearchParams?Array.from(a.body.entries()).reduce((L,[N,z])=>`${L}${N}=${z} `,""):String(a.body);return{path:u,submission:{formMethod:d,formAction:h,formEncType:a.formEncType,formData:void 0,json:void 0,text:O}}}else if(a.formEncType==="application/json"){if(!Xt(d))return c();try{let O=typeof a.body=="string"?JSON.parse(a.body):a.body;return{path:u,submission:{formMethod:d,formAction:h,formEncType:a.formEncType,formData:void 0,json:O,text:void 0}}}catch{return c()}}}Se(typeof FormData=="function","FormData is not available in this environment");let v,g;if(a.formData)v=qu(a.formData),g=a.formData;else if(a.body instanceof FormData)v=qu(a.body),g=a.body;else if(a.body instanceof URLSearchParams)v=a.body,g=Gf(v);else if(a.body==null)v=new URLSearchParams,g=new FormData;else try{v=new URLSearchParams(a.body),g=Gf(v)}catch{return c()}let S={formMethod:d,formAction:h,formEncType:a&&a.formEncType||"application/x-www-form-urlencoded",formData:g,json:void 0,text:void 0};if(Xt(S.formMethod))return{path:u,submission:S};let D=Wn(u);return i&&D.search&&na(D.search)&&v.append("index",""),D.search=`?${v}`,{path:Vn(D),submission:S}}function Wf(i,u,a=!1){let c=i.findIndex(f=>f.route.id===u);return c>=0?i.slice(0,a?c+1:c):i}function Qf(i,u,a,c,f,d,h,v,g,S,D,O,L,N){let z=N?_t(N[1])?N[1].error:N[1].data:void 0,$=i.createURL(u.location),H=i.createURL(f),M=a;d&&u.errors?M=Wf(a,Object.keys(u.errors)[0],!0):N&&_t(N[1])&&(M=Wf(a,N[0]));let b=N?N[1].statusCode:void 0,J=b&&b>=400,ae=M.filter((le,pe)=>{let{route:ie}=le;if(ie.lazy)return!0;if(ie.loader==null)return!1;if(d)return Zu(ie,u.loaderData,u.errors);if(Jp(u.loaderData,u.matches[pe],le))return!0;let ge=u.matches[pe],Ce=le;return Kf(le,{currentUrl:$,currentParams:ge.params,nextUrl:H,nextParams:Ce.params,...c,actionResult:z,actionStatus:b,defaultShouldRevalidate:J?!1:h||$.pathname+$.search===H.pathname+H.search||$.search!==H.search||Zp(ge,Ce)})}),C=[];return S.forEach((le,pe)=>{if(d||!a.some(rt=>rt.route.id===le.routeId)||g.has(pe))return;let ie=Bn(O,le.path,L);if(!ie){C.push({key:pe,routeId:le.routeId,path:le.path,matches:null,match:null,controller:null});return}let ge=u.fetchers.get(pe),Ce=zl(ie,le.path),Ke=!1;D.has(pe)?Ke=!1:v.has(pe)?(v.delete(pe),Ke=!0):ge&&ge.state!=="idle"&&ge.data===void 0?Ke=h:Ke=Kf(Ce,{currentUrl:$,currentParams:u.matches[u.matches.length-1].params,nextUrl:H,nextParams:a[a.length-1].params,...c,actionResult:z,actionStatus:b,defaultShouldRevalidate:J?!1:h}),Ke&&C.push({key:pe,routeId:le.routeId,path:le.path,matches:ie,match:Ce,controller:new AbortController})}),[ae,C]}function Zu(i,u,a){if(i.lazy)return!0;if(!i.loader)return!1;let c=u!=null&&u[i.id]!==void 0,f=a!=null&&a[i.id]!==void 0;return!c&&f?!1:typeof i.loader=="function"&&i.loader.hydrate===!0?!0:!c&&!f}function Jp(i,u,a){let c=!u||a.route.id!==u.route.id,f=!i.hasOwnProperty(a.route.id);return c||f}function Zp(i,u){let a=i.route.path;return i.pathname!==u.pathname||a!=null&&a.endsWith("*")&&i.params["*"]!==u.params["*"]}function Kf(i,u){if(i.route.shouldRevalidate){let a=i.route.shouldRevalidate(u);if(typeof a=="boolean")return a}return u.defaultShouldRevalidate}function Yf(i,u,a,c,f){let d;if(i){let g=c[i];Se(g,`No route found to patch children into: routeId = ${i}`),g.children||(g.children=[]),d=g.children}else d=a;let h=u.filter(g=>!d.some(S=>hc(g,S))),v=to(h,f,[i||"_","patch",String((d==null?void 0:d.length)||"0")],c);d.push(...v)}function hc(i,u){return"id"in i&&"id"in u&&i.id===u.id?!0:i.index===u.index&&i.path===u.path&&i.caseSensitive===u.caseSensitive?(!i.children||i.children.length===0)&&(!u.children||u.children.length===0)?!0:i.children.every((a,c)=>{var f;return(f=u.children)==null?void 0:f.some(d=>hc(a,d))}):!1}async function qp(i,u,a){if(!i.lazy)return;let c=await i.lazy();if(!i.lazy)return;let f=a[i.id];Se(f,"No route found in manifest");let d={};for(let h in c){let g=f[h]!==void 0&&h!=="hasErrorBoundary";ot(!g,`Route "${f.id}" has a static property "${h}" defined but its lazy function is also returning a value for this property. The lazy route property "${h}" will be ignored.`),!g&&!Ep.has(h)&&(d[h]=c[h])}Object.assign(f,d),Object.assign(f,{...u(f),lazy:void 0})}async function bp({matches:i}){let u=i.filter(c=>c.shouldLoad);return(await Promise.all(u.map(c=>c.resolve()))).reduce((c,f,d)=>Object.assign(c,{[u[d].route.id]:f}),{})}async function eh(i,u,a,c,f,d,h,v,g,S){let D=d.map(N=>N.route.lazy?qp(N.route,g,v):void 0),O=d.map((N,z)=>{let $=D[z],H=f.some(b=>b.route.id===N.route.id);return{...N,shouldLoad:H,resolve:async b=>(b&&c.method==="GET"&&(N.route.lazy||N.route.loader)&&(H=!0),H?th(u,c,N,$,b,S):Promise.resolve({type:"data",result:void 0}))}}),L=await i({matches:O,request:c,params:d[0].params,fetcherKey:h,context:S});try{await Promise.all(D)}catch{}return L}async function th(i,u,a,c,f,d){let h,v,g=S=>{let D,O=new Promise((z,$)=>D=$);v=()=>D(),u.signal.addEventListener("abort",v);let L=z=>typeof S!="function"?Promise.reject(new Error(`You cannot call the handler for a route which defines a boolean "${i}" [routeId: ${a.route.id}]`)):S({request:u,params:a.params,context:d},...z!==void 0?[z]:[]),N=(async()=>{try{return{type:"data",result:await(f?f($=>L($)):L())}}catch(z){return{type:"error",result:z}}})();return Promise.race([N,O])};try{let S=a.route[i];if(c)if(S){let D,[O]=await Promise.all([g(S).catch(L=>{D=L}),c]);if(D!==void 0)throw D;h=O}else if(await c,S=a.route[i],S)h=await g(S);else if(i==="action"){let D=new URL(u.url),O=D.pathname+D.search;throw jt(405,{method:u.method,pathname:O,routeId:a.route.id})}else return{type:"data",result:void 0};else if(S)h=await g(S);else{let D=new URL(u.url),O=D.pathname+D.search;throw jt(404,{pathname:O})}}catch(S){return{type:"error",result:S}}finally{v&&u.signal.removeEventListener("abort",v)}return h}async function nh(i){var c,f,d,h;let{result:u,type:a}=i;if(yc(u)){let v;try{let g=u.headers.get("Content-Type");g&&/\bapplication\/json\b/.test(g)?u.body==null?v=null:v=await u.json():v=await u.text()}catch(g){return{type:"error",error:g}}return a==="error"?{type:"error",error:new ro(u.status,u.statusText,v),statusCode:u.status,headers:u.headers}:{type:"data",data:v,statusCode:u.status,headers:u.headers}}if(a==="error"){if(ec(u)){if(u.data instanceof Error)return{type:"error",error:u.data,statusCode:(c=u.init)==null?void 0:c.status};u=new ro(((f=u.init)==null?void 0:f.status)||500,void 0,u.data)}return{type:"error",error:u,statusCode:lo(u)?u.status:void 0}}return ec(u)?{type:"data",data:u.data,statusCode:(d=u.init)==null?void 0:d.status,headers:(h=u.init)!=null&&h.headers?new Headers(u.init.headers):void 0}:{type:"data",data:u}}function rh(i,u,a,c,f){let d=i.headers.get("Location");if(Se(d,"Redirects returned/thrown from loaders/actions must have a Location header"),!ta.test(d)){let h=c.slice(0,c.findIndex(v=>v.route.id===a)+1);d=Ju(new URL(u.url),h,f,d),i.headers.set("Location",d)}return i}function Xf(i,u,a){if(ta.test(i)){let c=i,f=c.startsWith("//")?new URL(u.protocol+c):new URL(c),d=Gt(f.pathname,a)!=null;if(f.origin===u.origin&&d)return f.pathname+f.search+f.hash}return i}function Br(i,u,a,c){let f=i.createURL(mc(u)).toString(),d={signal:a};if(c&&Xt(c.formMethod)){let{formMethod:h,formEncType:v}=c;d.method=h.toUpperCase(),v==="application/json"?(d.headers=new Headers({"Content-Type":v}),d.body=JSON.stringify(c.json)):v==="text/plain"?d.body=c.text:v==="application/x-www-form-urlencoded"&&c.formData?d.body=qu(c.formData):d.body=c.formData}return new Request(f,d)}function qu(i){let u=new URLSearchParams;for(let[a,c]of i.entries())u.append(a,typeof c=="string"?c:c.name);return u}function Gf(i){let u=new FormData;for(let[a,c]of i.entries())u.append(a,c);return u}function lh(i,u,a,c=!1,f=!1){let d={},h=null,v,g=!1,S={},D=a&&_t(a[1])?a[1].error:void 0;return i.forEach(O=>{if(!(O.route.id in u))return;let L=O.route.id,N=u[L];if(Se(!cr(N),"Cannot handle redirect results in processLoaderData"),_t(N)){let z=N.error;if(D!==void 0&&(z=D,D=void 0),h=h||{},f)h[L]=z;else{let $=fr(i,L);h[$.route.id]==null&&(h[$.route.id]=z)}c||(d[L]=pc),g||(g=!0,v=lo(N.error)?N.error.status:500),N.headers&&(S[L]=N.headers)}else d[L]=N.data,N.statusCode&&N.statusCode!==200&&!g&&(v=N.statusCode),N.headers&&(S[L]=N.headers)}),D!==void 0&&a&&(h={[a[0]]:D},d[a[0]]=void 0),{loaderData:d,errors:h,statusCode:v||200,loaderHeaders:S}}function Jf(i,u,a,c,f,d){let{loaderData:h,errors:v}=lh(u,a,c);return f.forEach(g=>{let{key:S,match:D,controller:O}=g,L=d[S];if(Se(L,"Did not find corresponding fetcher result"),!(O&&O.signal.aborted))if(_t(L)){let N=fr(i.matches,D==null?void 0:D.route.id);v&&v[N.route.id]||(v={...v,[N.route.id]:L.error}),i.fetchers.delete(S)}else if(cr(L))Se(!1,"Unhandled fetcher revalidation redirect");else{let N=Hn(L.data);i.fetchers.set(S,N)}}),{loaderData:h,errors:v}}function Zf(i,u,a,c){let f=Object.entries(u).filter(([,d])=>d!==pc).reduce((d,[h,v])=>(d[h]=v,d),{});for(let d of a){let h=d.route.id;if(!u.hasOwnProperty(h)&&i.hasOwnProperty(h)&&d.route.loader&&(f[h]=i[h]),c&&c.hasOwnProperty(h))break}return f}function qf(i){return i?_t(i[1])?{actionData:{}}:{actionData:{[i[0]]:i[1].data}}:{}}function fr(i,u){return(u?i.slice(0,i.findIndex(c=>c.route.id===u)+1):[...i]).reverse().find(c=>c.route.hasErrorBoundary===!0)||i[0]}function bf(i){let u=i.length===1?i[0]:i.find(a=>a.index||!a.path||a.path==="/")||{id:"__shim-error-route__"};return{matches:[{params:{},pathname:"",pathnameBase:"",route:u}],route:u}}function jt(i,{pathname:u,routeId:a,method:c,type:f,message:d}={}){let h="Unknown Server Error",v="Unknown @remix-run/router error";return i===400?(h="Bad Request",c&&u&&a?v=`You made a ${c} request to "${u}" but did not provide a \`loader\` for route "${a}", so there is no way to handle the request.`:f==="invalid-body"&&(v="Unable to encode submission body")):i===403?(h="Forbidden",v=`Route "${a}" does not match URL "${u}"`):i===404?(h="Not Found",v=`No route matches URL "${u}"`):i===405&&(h="Method Not Allowed",c&&u&&a?v=`You made a ${c.toUpperCase()} request to "${u}" but did not provide an \`action\` for route "${a}", so there is no way to handle the request.`:c&&(v=`Invalid request method "${c.toUpperCase()}"`)),new ro(i||500,h,new Error(v),!0)}function Ji(i){let u=Object.entries(i);for(let a=u.length-1;a>=0;a--){let[c,f]=u[a];if(cr(f))return{key:c,result:f}}}function mc(i){let u=typeof i=="string"?Wn(i):i;return Vn({...u,hash:""})}function ih(i,u){return i.pathname!==u.pathname||i.search!==u.search?!1:i.hash===""?u.hash!=="":i.hash===u.hash?!0:u.hash!==""}function oh(i){return yc(i.result)&&Wp.has(i.result.status)}function _t(i){return i.type==="error"}function cr(i){return(i&&i.type)==="redirect"}function ec(i){return typeof i=="object"&&i!=null&&"type"in i&&"data"in i&&"init"in i&&i.type==="DataWithResponseInit"}function yc(i){return i!=null&&typeof i.status=="number"&&typeof i.statusText=="string"&&typeof i.headers=="object"&&typeof i.body<"u"}function uh(i){return Vp.has(i.toUpperCase())}function Xt(i){return Hp.has(i.toUpperCase())}function na(i){return new URLSearchParams(i).getAll("index").some(u=>u==="")}function zl(i,u){let a=typeof u=="string"?Wn(u).search:u.search;if(i[i.length-1].route.index&&na(a||""))return i[i.length-1];let c=fc(i);return c[c.length-1]}function tc(i){let{formMethod:u,formAction:a,formEncType:c,text:f,formData:d,json:h}=i;if(!(!u||!a||!c)){if(f!=null)return{formMethod:u,formAction:a,formEncType:c,formData:void 0,json:void 0,text:f};if(d!=null)return{formMethod:u,formAction:a,formEncType:c,formData:d,json:void 0,text:void 0};if(h!==void 0)return{formMethod:u,formAction:a,formEncType:c,formData:void 0,json:h,text:void 0}}}function Xu(i,u){return u?{state:"loading",location:i,formMethod:u.formMethod,formAction:u.formAction,formEncType:u.formEncType,formData:u.formData,json:u.json,text:u.text}:{state:"loading",location:i,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0}}function ah(i,u){return{state:"submitting",location:i,formMethod:u.formMethod,formAction:u.formAction,formEncType:u.formEncType,formData:u.formData,json:u.json,text:u.text}}function Dl(i,u){return i?{state:"loading",formMethod:i.formMethod,formAction:i.formAction,formEncType:i.formEncType,formData:i.formData,json:i.json,text:i.text,data:u}:{state:"loading",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:u}}function sh(i,u){return{state:"submitting",formMethod:i.formMethod,formAction:i.formAction,formEncType:i.formEncType,formData:i.formData,json:i.json,text:i.text,data:u?u.data:void 0}}function Hn(i){return{state:"idle",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:i}}function fh(i,u){try{let a=i.sessionStorage.getItem(dc);if(a){let c=JSON.parse(a);for(let[f,d]of Object.entries(c||{}))d&&Array.isArray(d)&&u.set(f,new Set(d||[]))}}catch{}}function ch(i,u){if(u.size>0){let a={};for(let[c,f]of u)a[c]=[...f];try{i.sessionStorage.setItem(dc,JSON.stringify(a))}catch(c){ot(!1,`Failed to save applied view transitions in sessionStorage (${c}).`)}}}function dh(){let i,u,a=new Promise((c,f)=>{i=async d=>{c(d);try{await a}catch{}},u=async d=>{f(d);try{await a}catch{}}});return{promise:a,resolve:i,reject:u}}var dr=T.createContext(null);dr.displayName="DataRouter";var Ol=T.createContext(null);Ol.displayName="DataRouterState";var ra=T.createContext({isTransitioning:!1});ra.displayName="ViewTransition";var vc=T.createContext(new Map);vc.displayName="Fetchers";var ph=T.createContext(null);ph.displayName="Await";var nn=T.createContext(null);nn.displayName="Navigation";var io=T.createContext(null);io.displayName="Location";var Jt=T.createContext({outlet:null,matches:[],isDataRoute:!1});Jt.displayName="Route";var la=T.createContext(null);la.displayName="RouteError";function hh(i,{relative:u}={}){Se(Il(),"useHref() may be used only in the context of a component.");let{basename:a,navigator:c}=T.useContext(nn),{hash:f,pathname:d,search:h}=Ul(i,{relative:u}),v=d;return a!=="/"&&(v=d==="/"?a:tn([a,d])),c.createHref({pathname:v,search:h,hash:f})}function Il(){return T.useContext(io)!=null}function pr(){return Se(Il(),"useLocation() may be used only in the context of a component."),T.useContext(io).location}var gc="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function wc(i){T.useContext(nn).static||T.useLayoutEffect(i)}function mh(){let{isDataRoute:i}=T.useContext(Jt);return i?Nh():yh()}function yh(){Se(Il(),"useNavigate() may be used only in the context of a component.");let i=T.useContext(dr),{basename:u,navigator:a}=T.useContext(nn),{matches:c}=T.useContext(Jt),{pathname:f}=pr(),d=JSON.stringify(bu(c)),h=T.useRef(!1);return wc(()=>{h.current=!0}),T.useCallback((g,S={})=>{if(ot(h.current,gc),!h.current)return;if(typeof g=="number"){a.go(g);return}let D=ea(g,JSON.parse(d),f,S.relative==="path");i==null&&u!=="/"&&(D.pathname=D.pathname==="/"?u:tn([u,D.pathname])),(S.replace?a.replace:a.push)(D,S.state,S)},[u,a,d,f,i])}var vh=T.createContext(null);function gh(i){let u=T.useContext(Jt).outlet;return u&&T.createElement(vh.Provider,{value:i},u)}function wm(){let{matches:i}=T.useContext(Jt),u=i[i.length-1];return u?u.params:{}}function Ul(i,{relative:u}={}){let{matches:a}=T.useContext(Jt),{pathname:c}=pr(),f=JSON.stringify(bu(a));return T.useMemo(()=>ea(i,JSON.parse(f),c,u==="path"),[i,f,c,u])}function wh(i,u,a,c){Se(Il(),"useRoutes() may be used only in the context of a component.");let{navigator:f}=T.useContext(nn),{matches:d}=T.useContext(Jt),h=d[d.length-1],v=h?h.params:{},g=h?h.pathname:"/",S=h?h.pathnameBase:"/",D=h&&h.route;{let M=D&&D.path||"";Sc(g,!D||M.endsWith("*")||M.endsWith("*?"),`You rendered descendant (or called \`useRoutes()\`) at "${g}" (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 O=pr(),L;L=O;let N=L.pathname||"/",z=N;if(S!=="/"){let M=S.replace(/^\//,"").split("/");z="/"+N.replace(/^\//,"").split("/").slice(M.length).join("/")}let $=Bn(i,{pathname:z});return ot(D||$!=null,`No routes matched location "${L.pathname}${L.search}${L.hash}" `),ot($==null||$[$.length-1].route.element!==void 0||$[$.length-1].route.Component!==void 0||$[$.length-1].route.lazy!==void 0,`Matched leaf route at location "${L.pathname}${L.search}${L.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.`),Ch($&&$.map(M=>Object.assign({},M,{params:Object.assign({},v,M.params),pathname:tn([S,f.encodeLocation?f.encodeLocation(M.pathname).pathname:M.pathname]),pathnameBase:M.pathnameBase==="/"?S:tn([S,f.encodeLocation?f.encodeLocation(M.pathnameBase).pathname:M.pathnameBase])})),d,a,c)}function Sh(){let i=Th(),u=lo(i)?`${i.status} ${i.statusText}`:i instanceof Error?i.message:JSON.stringify(i),a=i instanceof Error?i.stack:null,c="rgba(200,200,200, 0.5)",f={padding:"0.5rem",backgroundColor:c},d={padding:"2px 4px",backgroundColor:c},h=null;return console.error("Error handled by React Router default ErrorBoundary:",i),h=T.createElement(T.Fragment,null,T.createElement("p",null,"💿 Hey developer 👋"),T.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",T.createElement("code",{style:d},"ErrorBoundary")," or"," ",T.createElement("code",{style:d},"errorElement")," prop on your route.")),T.createElement(T.Fragment,null,T.createElement("h2",null,"Unexpected Application Error!"),T.createElement("h3",{style:{fontStyle:"italic"}},u),a?T.createElement("pre",{style:f},a):null,h)}var Eh=T.createElement(Sh,null),kh=class extends T.Component{constructor(i){super(i),this.state={location:i.location,revalidation:i.revalidation,error:i.error}}static getDerivedStateFromError(i){return{error:i}}static getDerivedStateFromProps(i,u){return u.location!==i.location||u.revalidation!=="idle"&&i.revalidation==="idle"?{error:i.error,location:i.location,revalidation:i.revalidation}:{error:i.error!==void 0?i.error:u.error,location:u.location,revalidation:i.revalidation||u.revalidation}}componentDidCatch(i,u){console.error("React Router caught the following error during render",i,u)}render(){return this.state.error!==void 0?T.createElement(Jt.Provider,{value:this.props.routeContext},T.createElement(la.Provider,{value:this.state.error,children:this.props.component})):this.props.children}};function xh({routeContext:i,match:u,children:a}){let c=T.useContext(dr);return c&&c.static&&c.staticContext&&(u.route.errorElement||u.route.ErrorBoundary)&&(c.staticContext._deepestRenderedBoundaryId=u.route.id),T.createElement(Jt.Provider,{value:i},a)}function Ch(i,u=[],a=null,c=null){if(i==null){if(!a)return null;if(a.errors)i=a.matches;else if(u.length===0&&!a.initialized&&a.matches.length>0)i=a.matches;else return null}let f=i,d=a==null?void 0:a.errors;if(d!=null){let g=f.findIndex(S=>S.route.id&&(d==null?void 0:d[S.route.id])!==void 0);Se(g>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(d).join(",")}`),f=f.slice(0,Math.min(f.length,g+1))}let h=!1,v=-1;if(a)for(let g=0;g=0?f=f.slice(0,v+1):f=[f[0]];break}}}return f.reduceRight((g,S,D)=>{let O,L=!1,N=null,z=null;a&&(O=d&&S.route.id?d[S.route.id]:void 0,N=S.route.errorElement||Eh,h&&(v<0&&D===0?(Sc("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),L=!0,z=null):v===D&&(L=!0,z=S.route.hydrateFallbackElement||null)));let $=u.concat(f.slice(0,D+1)),H=()=>{let M;return O?M=N:L?M=z:S.route.Component?M=T.createElement(S.route.Component,null):S.route.element?M=S.route.element:M=g,T.createElement(xh,{match:S,routeContext:{outlet:g,matches:$,isDataRoute:a!=null},children:M})};return a&&(S.route.ErrorBoundary||S.route.errorElement||D===0)?T.createElement(kh,{location:a.location,revalidation:a.revalidation,component:N,error:O,children:H(),routeContext:{outlet:null,matches:$,isDataRoute:!0}}):H()},null)}function ia(i){return`${i} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function Rh(i){let u=T.useContext(dr);return Se(u,ia(i)),u}function Ph(i){let u=T.useContext(Ol);return Se(u,ia(i)),u}function Lh(i){let u=T.useContext(Jt);return Se(u,ia(i)),u}function oa(i){let u=Lh(i),a=u.matches[u.matches.length-1];return Se(a.route.id,`${i} can only be used on routes that contain a unique "id"`),a.route.id}function _h(){return oa("useRouteId")}function Th(){var c;let i=T.useContext(la),u=Ph("useRouteError"),a=oa("useRouteError");return i!==void 0?i:(c=u.errors)==null?void 0:c[a]}function Nh(){let{router:i}=Rh("useNavigate"),u=oa("useNavigate"),a=T.useRef(!1);return wc(()=>{a.current=!0}),T.useCallback(async(f,d={})=>{ot(a.current,gc),a.current&&(typeof f=="number"?i.navigate(f):await i.navigate(f,{fromRouteId:u,...d}))},[i,u])}var nc={};function Sc(i,u,a){!u&&!nc[i]&&(nc[i]=!0,ot(!1,a))}var rc={};function lc(i,u){!i&&!rc[u]&&(rc[u]=!0,console.warn(u))}function Dh(i){let u={hasErrorBoundary:i.hasErrorBoundary||i.ErrorBoundary!=null||i.errorElement!=null};return i.Component&&(i.element&&ot(!1,"You should not include both `Component` and `element` on your route - `Component` will be used."),Object.assign(u,{element:T.createElement(i.Component),Component:void 0})),i.HydrateFallback&&(i.hydrateFallbackElement&&ot(!1,"You should not include both `HydrateFallback` and `hydrateFallbackElement` on your route - `HydrateFallback` will be used."),Object.assign(u,{hydrateFallbackElement:T.createElement(i.HydrateFallback),HydrateFallback:void 0})),i.ErrorBoundary&&(i.errorElement&&ot(!1,"You should not include both `ErrorBoundary` and `errorElement` on your route - `ErrorBoundary` will be used."),Object.assign(u,{errorElement:T.createElement(i.ErrorBoundary),ErrorBoundary:void 0})),u}var Mh=class{constructor(){this.status="pending",this.promise=new Promise((i,u)=>{this.resolve=a=>{this.status==="pending"&&(this.status="resolved",i(a))},this.reject=a=>{this.status==="pending"&&(this.status="rejected",u(a))}})}};function zh({router:i,flushSync:u}){let[a,c]=T.useState(i.state),[f,d]=T.useState(),[h,v]=T.useState({isTransitioning:!1}),[g,S]=T.useState(),[D,O]=T.useState(),[L,N]=T.useState(),z=T.useRef(new Map),$=T.useCallback((J,{deletedFetchers:ae,flushSync:C,viewTransitionOpts:le})=>{J.fetchers.forEach((ie,ge)=>{ie.data!==void 0&&z.current.set(ge,ie.data)}),ae.forEach(ie=>z.current.delete(ie)),lc(C===!1||u!=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 pe=i.window!=null&&i.window.document!=null&&typeof i.window.document.startViewTransition=="function";if(lc(le==null||pe,"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."),!le||!pe){u&&C?u(()=>c(J)):T.startTransition(()=>c(J));return}if(u&&C){u(()=>{D&&(g&&g.resolve(),D.skipTransition()),v({isTransitioning:!0,flushSync:!0,currentLocation:le.currentLocation,nextLocation:le.nextLocation})});let ie=i.window.document.startViewTransition(()=>{u(()=>c(J))});ie.finished.finally(()=>{u(()=>{S(void 0),O(void 0),d(void 0),v({isTransitioning:!1})})}),u(()=>O(ie));return}D?(g&&g.resolve(),D.skipTransition(),N({state:J,currentLocation:le.currentLocation,nextLocation:le.nextLocation})):(d(J),v({isTransitioning:!0,flushSync:!1,currentLocation:le.currentLocation,nextLocation:le.nextLocation}))},[i.window,u,D,g]);T.useLayoutEffect(()=>i.subscribe($),[i,$]),T.useEffect(()=>{h.isTransitioning&&!h.flushSync&&S(new Mh)},[h]),T.useEffect(()=>{if(g&&f&&i.window){let J=f,ae=g.promise,C=i.window.document.startViewTransition(async()=>{T.startTransition(()=>c(J)),await ae});C.finished.finally(()=>{S(void 0),O(void 0),d(void 0),v({isTransitioning:!1})}),O(C)}},[f,g,i.window]),T.useEffect(()=>{g&&f&&a.location.key===f.location.key&&g.resolve()},[g,D,a.location,f]),T.useEffect(()=>{!h.isTransitioning&&L&&(d(L.state),v({isTransitioning:!0,flushSync:!1,currentLocation:L.currentLocation,nextLocation:L.nextLocation}),N(void 0))},[h.isTransitioning,L]);let H=T.useMemo(()=>({createHref:i.createHref,encodeLocation:i.encodeLocation,go:J=>i.navigate(J),push:(J,ae,C)=>i.navigate(J,{state:ae,preventScrollReset:C==null?void 0:C.preventScrollReset}),replace:(J,ae,C)=>i.navigate(J,{replace:!0,state:ae,preventScrollReset:C==null?void 0:C.preventScrollReset})}),[i]),M=i.basename||"/",b=T.useMemo(()=>({router:i,navigator:H,static:!1,basename:M}),[i,H,M]);return T.createElement(T.Fragment,null,T.createElement(dr.Provider,{value:b},T.createElement(Ol.Provider,{value:a},T.createElement(vc.Provider,{value:z.current},T.createElement(ra.Provider,{value:h},T.createElement(Ih,{basename:M,location:a.location,navigationType:a.historyAction,navigator:H},T.createElement(Fh,{routes:i.routes,future:i.future,state:a})))))),null)}var Fh=T.memo(Oh);function Oh({routes:i,future:u,state:a}){return wh(i,void 0,a,u)}function Sm(i){return gh(i.context)}function Ih({basename:i="/",children:u=null,location:a,navigationType:c="POP",navigator:f,static:d=!1}){Se(!Il(),"You cannot render a inside another . You should never have more than one in your app.");let h=i.replace(/^\/*/,"/"),v=T.useMemo(()=>({basename:h,navigator:f,static:d,future:{}}),[h,f,d]);typeof a=="string"&&(a=Wn(a));let{pathname:g="/",search:S="",hash:D="",state:O=null,key:L="default"}=a,N=T.useMemo(()=>{let z=Gt(g,h);return z==null?null:{location:{pathname:z,search:S,hash:D,state:O,key:L},navigationType:c}},[h,g,S,D,O,L,c]);return ot(N!=null,` is not able to match the URL "${g}${S}${D}" because it does not start with the basename, so the won't render anything.`),N==null?null:T.createElement(nn.Provider,{value:v},T.createElement(io.Provider,{children:u,value:N}))}var bi="get",eo="application/x-www-form-urlencoded";function oo(i){return i!=null&&typeof i.tagName=="string"}function Uh(i){return oo(i)&&i.tagName.toLowerCase()==="button"}function jh(i){return oo(i)&&i.tagName.toLowerCase()==="form"}function $h(i){return oo(i)&&i.tagName.toLowerCase()==="input"}function Ah(i){return!!(i.metaKey||i.altKey||i.ctrlKey||i.shiftKey)}function Hh(i,u){return i.button===0&&(!u||u==="_self")&&!Ah(i)}var Zi=null;function Bh(){if(Zi===null)try{new FormData(document.createElement("form"),0),Zi=!1}catch{Zi=!0}return Zi}var Vh=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function Gu(i){return i!=null&&!Vh.has(i)?(ot(!1,`"${i}" is not a valid \`encType\` for \`
\`/\`\` and will default to "${eo}"`),null):i}function Wh(i,u){let a,c,f,d,h;if(jh(i)){let v=i.getAttribute("action");c=v?Gt(v,u):null,a=i.getAttribute("method")||bi,f=Gu(i.getAttribute("enctype"))||eo,d=new FormData(i)}else if(Uh(i)||$h(i)&&(i.type==="submit"||i.type==="image")){let v=i.form;if(v==null)throw new Error('Cannot submit a