/*! For license information please see main.2282de24.js.LICENSE.txt */ (()=>{var e={739(e,t,r){"use strict";var n={};r.r(n),r.d(n,{scaleBand:()=>HE,scaleDiverging:()=>GD,scaleDivergingLog:()=>YD,scaleDivergingPow:()=>QD,scaleDivergingSqrt:()=>XD,scaleDivergingSymlog:()=>$D,scaleIdentity:()=>UO,scaleImplicit:()=>UE,scaleLinear:()=>BO,scaleLog:()=>QO,scaleOrdinal:()=>VE,scalePoint:()=>qE,scalePow:()=>oA,scaleQuantile:()=>gA,scaleQuantize:()=>xA,scaleRadial:()=>lA,scaleSequential:()=>BD,scaleSequentialLog:()=>UD,scaleSequentialPow:()=>HD,scaleSequentialQuantile:()=>qD,scaleSequentialSqrt:()=>WD,scaleSequentialSymlog:()=>VD,scaleSqrt:()=>iA,scaleSymlog:()=>eA,scaleThreshold:()=>bA,scaleTime:()=>ID,scaleUtc:()=>zD,tickFormat:()=>LO});var a=r(43),o=r.t(a,2),i=r(391);function s(e){return s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},s(e)}function l(e){var t=function(e,t){if("object"!=s(e)||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,t||"default");if("object"!=s(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==s(t)?t:t+""}function c(e,t,r){return(t=l(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function d(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function u(e){for(var t=1;tC(t)?Object.keys(t).sort().reduce((e,r)=>(e[r]=t[r],e),{}):t)}function k(e,t){return e===t||typeof e===typeof t&&(!(!e||!t||"object"!==typeof e||"object"!==typeof t)&&!Object.keys(t).some(r=>!k(e[r],t[r])))}function S(e,t){if(e===t)return e;const r=P(e)&&P(t);if(r||C(e)&&C(t)){const n=r?e:Object.keys(e),a=n.length,o=r?t:Object.keys(t),i=o.length,s=r?[]:{};let l=0;for(let c=0;c2&&void 0!==arguments[2]?arguments[2]:0;const n=[...e,t];return r&&n.length>r?n.slice(1):n}function A(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;const n=[t,...e];return r&&n.length>r?n.slice(0,-1):n}var M=Symbol();function D(e,t){return!e.queryFn&&null!==t&&void 0!==t&&t.initialPromise?()=>t.initialPromise:e.queryFn&&e.queryFn!==M?e.queryFn:()=>Promise.reject(new Error("Missing queryFn: '".concat(e.queryHash,"'")))}function T(e,t){m(e,t),t.add(e)}var R,I,z,L,F,B,U=function(){let e=[],t=0,r=e=>{e()},n=e=>{e()},a=e=>setTimeout(e,0);const o=n=>{t?e.push(n):a(()=>{r(n)})};return{batch:o=>{let i;t++;try{i=o()}finally{t--,t||(()=>{const t=e;e=[],t.length&&a(()=>{n(()=>{t.forEach(e=>{r(e)})})})})()}return i},batchCalls:e=>function(){for(var t=arguments.length,r=new Array(t),n=0;n{e(...r)})},schedule:o,setNotifyFunction:e=>{r=e},setBatchNotifyFunction:e=>{n=e},setScheduler:e=>{a=e}}}(),V=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},H=(R=new WeakMap,I=new WeakMap,z=new WeakMap,class extends V{constructor(){super(),f(this,R,void 0),f(this,I,void 0),f(this,z,void 0),v(z,this,e=>{if(!g&&window.addEventListener){const t=()=>e();return window.addEventListener("visibilitychange",t,!1),()=>{window.removeEventListener("visibilitychange",t)}}})}onSubscribe(){h(I,this)||this.setEventListener(h(z,this))}onUnsubscribe(){var e;this.hasListeners()||(null===(e=h(I,this))||void 0===e||e.call(this),v(I,this,void 0))}setEventListener(e){var t;v(z,this,e),null===(t=h(I,this))||void 0===t||t.call(this),v(I,this,e(e=>{"boolean"===typeof e?this.setFocused(e):this.onFocus()}))}setFocused(e){h(R,this)!==e&&(v(R,this,e),this.onFocus())}onFocus(){const e=this.isFocused();this.listeners.forEach(t=>{t(e)})}isFocused(){var e;return"boolean"===typeof h(R,this)?h(R,this):"hidden"!==(null===(e=globalThis.document)||void 0===e?void 0:e.visibilityState)}}),W=new H,q=(L=new WeakMap,F=new WeakMap,B=new WeakMap,class extends V{constructor(){super(),f(this,L,!0),f(this,F,void 0),f(this,B,void 0),v(B,this,e=>{if(!g&&window.addEventListener){const t=()=>e(!0),r=()=>e(!1);return window.addEventListener("online",t,!1),window.addEventListener("offline",r,!1),()=>{window.removeEventListener("online",t),window.removeEventListener("offline",r)}}})}onSubscribe(){h(F,this)||this.setEventListener(h(B,this))}onUnsubscribe(){var e;this.hasListeners()||(null===(e=h(F,this))||void 0===e||e.call(this),v(F,this,void 0))}setEventListener(e){var t;v(B,this,e),null===(t=h(F,this))||void 0===t||t.call(this),v(F,this,e(this.setOnline.bind(this)))}setOnline(e){h(L,this)!==e&&(v(L,this,e),this.listeners.forEach(t=>{t(e)}))}isOnline(){return h(L,this)}}),K=new q;function G(e){return Math.min(1e3*2**e,3e4)}function Y(e){return"online"!==(null!==e&&void 0!==e?e:"online")||K.isOnline()}var $,Q=class extends Error{constructor(e){super("CancelledError"),this.revert=null===e||void 0===e?void 0:e.revert,this.silent=null===e||void 0===e?void 0:e.silent}};function X(e){return e instanceof Q}function J(e){let t,r,n,a=!1,o=0,i=!1;const s=new Promise((e,t)=>{r=e,n=t}),l=()=>W.isFocused()&&("always"===e.networkMode||K.isOnline())&&e.canRun(),c=()=>Y(e.networkMode)&&e.canRun(),d=n=>{var a,o;i||(i=!0,null===(a=e.onSuccess)||void 0===a||a.call(e,n),null===(o=t)||void 0===o||o(),r(n))},u=r=>{var a,o;i||(i=!0,null===(a=e.onError)||void 0===a||a.call(e,r),null===(o=t)||void 0===o||o(),n(r))},m=()=>new Promise(r=>{var n;t=e=>{(i||l())&&r(e)},null===(n=e.onPause)||void 0===n||n.call(e)}).then(()=>{var r;(t=void 0,i)||(null===(r=e.onContinue)||void 0===r||r.call(e))}),f=()=>{if(i)return;let t;const r=0===o?e.initialPromise:void 0;try{t=null!==r&&void 0!==r?r:e.fn()}catch(n){t=Promise.reject(n)}Promise.resolve(t).then(d).catch(t=>{var r,n,s;if(i)return;const c=null!==(r=e.retry)&&void 0!==r?r:g?0:3,d=null!==(n=e.retryDelay)&&void 0!==n?n:G,p="function"===typeof d?d(o,t):d,h=!0===c||"number"===typeof c&&o{setTimeout(e,v)})).then(()=>l()?void 0:m()).then(()=>{a?u(t):f()})):u(t)})};return{promise:s,cancel:t=>{var r;i||(u(new Q(t)),null===(r=e.abort)||void 0===r||r.call(e))},continue:()=>{var e;return null===(e=t)||void 0===e||e(),s},cancelRetry:()=>{a=!0},continueRetry:()=>{a=!1},canStart:c,start:()=>(c()?f():m().then(f),s)}}var Z,ee,te,re,ne,ae,oe,ie,se=($=new WeakMap,class{constructor(){f(this,$,void 0)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),function(e){return"number"===typeof e&&e>=0&&e!==1/0}(this.gcTime)&&v($,this,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,null!==e&&void 0!==e?e:g?1/0:3e5)}clearGcTimeout(){h($,this)&&(clearTimeout(h($,this)),v($,this,void 0))}}),le=(Z=new WeakMap,ee=new WeakMap,te=new WeakMap,re=new WeakMap,ne=new WeakMap,ae=new WeakMap,oe=new WeakSet,class extends se{constructor(e){var t;super(),T(this,oe),f(this,Z,void 0),f(this,ee,void 0),f(this,te,void 0),f(this,re,void 0),f(this,ne,void 0),f(this,ae,void 0),v(ae,this,!1),v(ne,this,e.defaultOptions),this.setOptions(e.options),this.observers=[],v(te,this,e.cache),this.queryKey=e.queryKey,this.queryHash=e.queryHash,v(Z,this,function(e){const t="function"===typeof e.initialData?e.initialData():e.initialData,r=void 0!==t,n=r?"function"===typeof e.initialDataUpdatedAt?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:r?null!==n&&void 0!==n?n:Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:r?"success":"pending",fetchStatus:"idle"}}(this.options)),this.state=null!==(t=e.state)&&void 0!==t?t:h(Z,this),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var e;return null===(e=h(re,this))||void 0===e?void 0:e.promise}setOptions(e){this.options=u(u({},h(ne,this)),e),this.updateGcTime(this.options.gcTime)}optionalRemove(){this.observers.length||"idle"!==this.state.fetchStatus||h(te,this).remove(this)}setData(e,t){const r=_(this.state.data,e,this.options);return p(oe,this,ce).call(this,{data:r,type:"success",dataUpdatedAt:null===t||void 0===t?void 0:t.updatedAt,manual:null===t||void 0===t?void 0:t.manual}),r}setState(e,t){p(oe,this,ce).call(this,{type:"setState",state:e,setStateOptions:t})}cancel(e){var t,r;const n=null===(t=h(re,this))||void 0===t?void 0:t.promise;return null===(r=h(re,this))||void 0===r||r.cancel(e),n?n.then(x).catch(x):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(h(Z,this))}isActive(){return this.observers.some(e=>{return!1!==(t=e.options.enabled,r=this,"function"===typeof t?t(r):t);var t,r})}isDisabled(){return this.getObserversCount()>0&&!this.isActive()}isStale(){return!!this.state.isInvalidated||(this.getObserversCount()>0?this.observers.some(e=>e.getCurrentResult().isStale):void 0===this.state.data)}isStaleByTime(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;return this.state.isInvalidated||void 0===this.state.data||!function(e,t){return Math.max(e+(t||0)-Date.now(),0)}(this.state.dataUpdatedAt,e)}onFocus(){var e;const t=this.observers.find(e=>e.shouldFetchOnWindowFocus());null===t||void 0===t||t.refetch({cancelRefetch:!1}),null===(e=h(re,this))||void 0===e||e.continue()}onOnline(){var e;const t=this.observers.find(e=>e.shouldFetchOnReconnect());null===t||void 0===t||t.refetch({cancelRefetch:!1}),null===(e=h(re,this))||void 0===e||e.continue()}addObserver(e){this.observers.includes(e)||(this.observers.push(e),this.clearGcTimeout(),h(te,this).notify({type:"observerAdded",query:this,observer:e}))}removeObserver(e){this.observers.includes(e)&&(this.observers=this.observers.filter(t=>t!==e),this.observers.length||(h(re,this)&&(h(ae,this)?h(re,this).cancel({revert:!0}):h(re,this).cancelRetry()),this.scheduleGc()),h(te,this).notify({type:"observerRemoved",query:this,observer:e}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||p(oe,this,ce).call(this,{type:"invalidate"})}fetch(e,t){var r,n;if("idle"!==this.state.fetchStatus)if(void 0!==this.state.data&&null!==t&&void 0!==t&&t.cancelRefetch)this.cancel({silent:!0});else if(h(re,this))return h(re,this).continueRetry(),h(re,this).promise;if(e&&this.setOptions(e),!this.options.queryFn){const e=this.observers.find(e=>e.options.queryFn);e&&this.setOptions(e.options)}const a=new AbortController,o=e=>{Object.defineProperty(e,"signal",{enumerable:!0,get:()=>(v(ae,this,!0),a.signal)})},i={fetchOptions:t,options:this.options,queryKey:this.queryKey,state:this.state,fetchFn:()=>{const e=D(this.options,t),r={queryKey:this.queryKey,meta:this.meta};return o(r),v(ae,this,!1),this.options.persister?this.options.persister(e,r,this):e(r)}};var s;(o(i),null===(r=this.options.behavior)||void 0===r||r.onFetch(i,this),v(ee,this,this.state),"idle"===this.state.fetchStatus||this.state.fetchMeta!==(null===(n=i.fetchOptions)||void 0===n?void 0:n.meta))&&p(oe,this,ce).call(this,{type:"fetch",meta:null===(s=i.fetchOptions)||void 0===s?void 0:s.meta});const l=e=>{var t,r,n,a;(X(e)&&e.silent||p(oe,this,ce).call(this,{type:"error",error:e}),X(e))||(null===(t=(r=h(te,this).config).onError)||void 0===t||t.call(r,e,this),null===(n=(a=h(te,this).config).onSettled)||void 0===n||n.call(a,this.state.data,e,this));this.isFetchingOptimistic||this.scheduleGc(),this.isFetchingOptimistic=!1};return v(re,this,J({initialPromise:null===t||void 0===t?void 0:t.initialPromise,fn:i.fetchFn,abort:a.abort.bind(a),onSuccess:e=>{var t,r,n,a;if(void 0!==e){try{this.setData(e)}catch(o){return void l(o)}null===(t=(r=h(te,this).config).onSuccess)||void 0===t||t.call(r,e,this),null===(n=(a=h(te,this).config).onSettled)||void 0===n||n.call(a,e,this.state.error,this),this.isFetchingOptimistic||this.scheduleGc(),this.isFetchingOptimistic=!1}else l(new Error("".concat(this.queryHash," data is undefined")))},onError:l,onFail:(e,t)=>{p(oe,this,ce).call(this,{type:"failed",failureCount:e,error:t})},onPause:()=>{p(oe,this,ce).call(this,{type:"pause"})},onContinue:()=>{p(oe,this,ce).call(this,{type:"continue"})},retry:i.options.retry,retryDelay:i.options.retryDelay,networkMode:i.options.networkMode,canRun:()=>!0})),h(re,this).start()}});function ce(e){this.state=(t=>{var r,n;switch(e.type){case"failed":return u(u({},t),{},{fetchFailureCount:e.failureCount,fetchFailureReason:e.error});case"pause":return u(u({},t),{},{fetchStatus:"paused"});case"continue":return u(u({},t),{},{fetchStatus:"fetching"});case"fetch":return u(u(u({},t),function(e,t){return u({fetchFailureCount:0,fetchFailureReason:null,fetchStatus:Y(t.networkMode)?"fetching":"paused"},void 0===e&&{error:null,status:"pending"})}(t.data,this.options)),{},{fetchMeta:null!==(r=e.meta)&&void 0!==r?r:null});case"success":return u(u({},t),{},{data:e.data,dataUpdateCount:t.dataUpdateCount+1,dataUpdatedAt:null!==(n=e.dataUpdatedAt)&&void 0!==n?n:Date.now(),error:null,isInvalidated:!1,status:"success"},!e.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null});case"error":const a=e.error;return X(a)&&a.revert&&h(ee,this)?u(u({},h(ee,this)),{},{fetchStatus:"idle"}):u(u({},t),{},{error:a,errorUpdateCount:t.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:t.fetchFailureCount+1,fetchFailureReason:a,fetchStatus:"idle",status:"error"});case"invalidate":return u(u({},t),{},{isInvalidated:!0});case"setState":return u(u({},t),e.state)}})(this.state),U.batch(()=>{this.observers.forEach(e=>{e.onQueryUpdate()}),h(te,this).notify({query:this,type:"updated",action:e})})}var de,ue,me,fe,pe,he,ve=(ie=new WeakMap,class extends V{constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};super(),f(this,ie,void 0),this.config=e,v(ie,this,new Map)}build(e,t,r){var n;const a=t.queryKey,o=null!==(n=t.queryHash)&&void 0!==n?n:j(a,t);let i=this.get(o);return i||(i=new le({cache:this,queryKey:a,queryHash:o,options:e.defaultQueryOptions(t),state:r,defaultOptions:e.getQueryDefaults(a)}),this.add(i)),i}add(e){h(ie,this).has(e.queryHash)||(h(ie,this).set(e.queryHash,e),this.notify({type:"added",query:e}))}remove(e){const t=h(ie,this).get(e.queryHash);t&&(e.destroy(),t===e&&h(ie,this).delete(e.queryHash),this.notify({type:"removed",query:e}))}clear(){U.batch(()=>{this.getAll().forEach(e=>{this.remove(e)})})}get(e){return h(ie,this).get(e)}getAll(){return[...h(ie,this).values()]}find(e){const t=u({exact:!0},e);return this.getAll().find(e=>y(t,e))}findAll(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const t=this.getAll();return Object.keys(e).length>0?t.filter(t=>y(e,t)):t}notify(e){U.batch(()=>{this.listeners.forEach(t=>{t(e)})})}onFocus(){U.batch(()=>{this.getAll().forEach(e=>{e.onFocus()})})}onOnline(){U.batch(()=>{this.getAll().forEach(e=>{e.onOnline()})})}}),ge=(de=new WeakMap,ue=new WeakMap,me=new WeakMap,fe=new WeakSet,class extends se{constructor(e){super(),T(this,fe),f(this,de,void 0),f(this,ue,void 0),f(this,me,void 0),this.mutationId=e.mutationId,v(ue,this,e.mutationCache),v(de,this,[]),this.state=e.state||{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0},this.setOptions(e.options),this.scheduleGc()}setOptions(e){this.options=e,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(e){h(de,this).includes(e)||(h(de,this).push(e),this.clearGcTimeout(),h(ue,this).notify({type:"observerAdded",mutation:this,observer:e}))}removeObserver(e){v(de,this,h(de,this).filter(t=>t!==e)),this.scheduleGc(),h(ue,this).notify({type:"observerRemoved",mutation:this,observer:e})}optionalRemove(){h(de,this).length||("pending"===this.state.status?this.scheduleGc():h(ue,this).remove(this))}continue(){var e,t;return null!==(e=null===(t=h(me,this))||void 0===t?void 0:t.continue())&&void 0!==e?e:this.execute(this.state.variables)}async execute(e){var t;v(me,this,J({fn:()=>this.options.mutationFn?this.options.mutationFn(e):Promise.reject(new Error("No mutationFn found")),onFail:(e,t)=>{p(fe,this,xe).call(this,{type:"failed",failureCount:e,error:t})},onPause:()=>{p(fe,this,xe).call(this,{type:"pause"})},onContinue:()=>{p(fe,this,xe).call(this,{type:"continue"})},retry:null!==(t=this.options.retry)&&void 0!==t?t:0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>h(ue,this).canRun(this)}));const r="pending"===this.state.status,n=!h(me,this).canStart();try{var a,o,i,s,l,c,d,u;if(!r){var m,f,g,x;p(fe,this,xe).call(this,{type:"pending",variables:e,isPaused:n}),await(null===(m=(f=h(ue,this).config).onMutate)||void 0===m?void 0:m.call(f,e,this));const t=await(null===(g=(x=this.options).onMutate)||void 0===g?void 0:g.call(x,e));t!==this.state.context&&p(fe,this,xe).call(this,{type:"pending",context:t,variables:e,isPaused:n})}const t=await h(me,this).start();return await(null===(a=(o=h(ue,this).config).onSuccess)||void 0===a?void 0:a.call(o,t,e,this.state.context,this)),await(null===(i=(s=this.options).onSuccess)||void 0===i?void 0:i.call(s,t,e,this.state.context)),await(null===(l=(c=h(ue,this).config).onSettled)||void 0===l?void 0:l.call(c,t,null,this.state.variables,this.state.context,this)),await(null===(d=(u=this.options).onSettled)||void 0===d?void 0:d.call(u,t,null,e,this.state.context)),p(fe,this,xe).call(this,{type:"success",data:t}),t}catch(C){try{var b,y,w,j,N,k,S,P;throw await(null===(b=(y=h(ue,this).config).onError)||void 0===b?void 0:b.call(y,C,e,this.state.context,this)),await(null===(w=(j=this.options).onError)||void 0===w?void 0:w.call(j,C,e,this.state.context)),await(null===(N=(k=h(ue,this).config).onSettled)||void 0===N?void 0:N.call(k,void 0,C,this.state.variables,this.state.context,this)),await(null===(S=(P=this.options).onSettled)||void 0===S?void 0:S.call(P,void 0,C,e,this.state.context)),C}finally{p(fe,this,xe).call(this,{type:"error",error:C})}}finally{h(ue,this).runNext(this)}}});function xe(e){this.state=(t=>{switch(e.type){case"failed":return u(u({},t),{},{failureCount:e.failureCount,failureReason:e.error});case"pause":return u(u({},t),{},{isPaused:!0});case"continue":return u(u({},t),{},{isPaused:!1});case"pending":return u(u({},t),{},{context:e.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:e.isPaused,status:"pending",variables:e.variables,submittedAt:Date.now()});case"success":return u(u({},t),{},{data:e.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1});case"error":return u(u({},t),{},{data:void 0,error:e.error,failureCount:t.failureCount+1,failureReason:e.error,isPaused:!1,status:"error"})}})(this.state),U.batch(()=>{h(de,this).forEach(t=>{t.onMutationUpdate(e)}),h(ue,this).notify({mutation:this,type:"updated",action:e})})}var be,ye,we,je,Ne,ke,Se,Pe,Ce=(pe=new WeakMap,he=new WeakMap,class extends V{constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};super(),f(this,pe,void 0),f(this,he,void 0),this.config=e,v(pe,this,new Map),v(he,this,Date.now())}build(e,t,r){var n;const a=new ge({mutationCache:this,mutationId:v(he,this,(n=h(he,this),++n)),options:e.defaultMutationOptions(t),state:r});return this.add(a),a}add(e){var t;const r=Ee(e),n=null!==(t=h(pe,this).get(r))&&void 0!==t?t:[];n.push(e),h(pe,this).set(r,n),this.notify({type:"added",mutation:e})}remove(e){const t=Ee(e);if(h(pe,this).has(t)){var r;const n=null===(r=h(pe,this).get(t))||void 0===r?void 0:r.filter(t=>t!==e);n&&(0===n.length?h(pe,this).delete(t):h(pe,this).set(t,n))}this.notify({type:"removed",mutation:e})}canRun(e){var t;const r=null===(t=h(pe,this).get(Ee(e)))||void 0===t?void 0:t.find(e=>"pending"===e.state.status);return!r||r===e}runNext(e){var t,r;const n=null===(t=h(pe,this).get(Ee(e)))||void 0===t?void 0:t.find(t=>t!==e&&t.state.isPaused);return null!==(r=null===n||void 0===n?void 0:n.continue())&&void 0!==r?r:Promise.resolve()}clear(){U.batch(()=>{this.getAll().forEach(e=>{this.remove(e)})})}getAll(){return[...h(pe,this).values()].flat()}find(e){const t=u({exact:!0},e);return this.getAll().find(e=>w(t,e))}findAll(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return this.getAll().filter(t=>w(e,t))}notify(e){U.batch(()=>{this.listeners.forEach(t=>{t(e)})})}resumePausedMutations(){const e=this.getAll().filter(e=>e.state.isPaused);return U.batch(()=>Promise.all(e.map(e=>e.continue().catch(x))))}});function Ee(e){var t,r;return null!==(t=null===(r=e.options.scope)||void 0===r?void 0:r.id)&&void 0!==t?t:String(e.mutationId)}function _e(e){return{onFetch:(t,r)=>{var n,a,o;const i=t.options,s=null===(n=t.fetchOptions)||void 0===n||null===(n=n.meta)||void 0===n||null===(n=n.fetchMore)||void 0===n?void 0:n.direction,l=(null===(a=t.state.data)||void 0===a?void 0:a.pages)||[],c=(null===(o=t.state.data)||void 0===o?void 0:o.pageParams)||[];let d={pages:[],pageParams:[]},u=0;const m=async()=>{let r=!1;const n=D(t.options,t.fetchOptions),a=async(e,a,o)=>{if(r)return Promise.reject();if(null==a&&e.pages.length)return Promise.resolve(e);const i={queryKey:t.queryKey,pageParam:a,direction:o?"backward":"forward",meta:t.options.meta};(e=>{Object.defineProperty(e,"signal",{enumerable:!0,get:()=>(t.signal.aborted?r=!0:t.signal.addEventListener("abort",()=>{r=!0}),t.signal)})})(i);const s=await n(i),l=t.options.maxPages,c=o?A:O;return{pages:c(e.pages,s,l),pageParams:c(e.pageParams,a,l)}};if(s&&l.length){const e="backward"===s,t={pages:l,pageParams:c},r=(e?Ae:Oe)(i,t);d=await a(t,r,e)}else{const t=null!==e&&void 0!==e?e:l.length;do{var o;const e=0===u?null!==(o=c[0])&&void 0!==o?o:i.initialPageParam:Oe(i,d);if(u>0&&null==e)break;d=await a(d,e),u++}while(u{var e,n;return null===(e=(n=t.options).persister)||void 0===e?void 0:e.call(n,m,{queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},r)}:t.fetchFn=m}}}function Oe(e,t){let r=t.pages,n=t.pageParams;const a=r.length-1;return r.length>0?e.getNextPageParam(r[a],r,n[a],n):void 0}function Ae(e,t){var r;let n=t.pages,a=t.pageParams;return n.length>0?null===(r=e.getPreviousPageParam)||void 0===r?void 0:r.call(e,n[0],n,a[0],a):void 0}var Me=(be=new WeakMap,ye=new WeakMap,we=new WeakMap,je=new WeakMap,Ne=new WeakMap,ke=new WeakMap,Se=new WeakMap,Pe=new WeakMap,class{constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};f(this,be,void 0),f(this,ye,void 0),f(this,we,void 0),f(this,je,void 0),f(this,Ne,void 0),f(this,ke,void 0),f(this,Se,void 0),f(this,Pe,void 0),v(be,this,e.queryCache||new ve),v(ye,this,e.mutationCache||new Ce),v(we,this,e.defaultOptions||{}),v(je,this,new Map),v(Ne,this,new Map),v(ke,this,0)}mount(){var e;v(ke,this,(e=h(ke,this),e++,e)),1===h(ke,this)&&(v(Se,this,W.subscribe(async e=>{e&&(await this.resumePausedMutations(),h(be,this).onFocus())})),v(Pe,this,K.subscribe(async e=>{e&&(await this.resumePausedMutations(),h(be,this).onOnline())})))}unmount(){var e,t,r;v(ke,this,(e=h(ke,this),e--,e)),0===h(ke,this)&&(null===(t=h(Se,this))||void 0===t||t.call(this),v(Se,this,void 0),null===(r=h(Pe,this))||void 0===r||r.call(this),v(Pe,this,void 0))}isFetching(e){return h(be,this).findAll(u(u({},e),{},{fetchStatus:"fetching"})).length}isMutating(e){return h(ye,this).findAll(u(u({},e),{},{status:"pending"})).length}getQueryData(e){var t;const r=this.defaultQueryOptions({queryKey:e});return null===(t=h(be,this).get(r.queryHash))||void 0===t?void 0:t.state.data}ensureQueryData(e){const t=this.getQueryData(e.queryKey);if(void 0===t)return this.fetchQuery(e);{const r=this.defaultQueryOptions(e),n=h(be,this).build(this,r);return e.revalidateIfStale&&n.isStaleByTime(b(r.staleTime,n))&&this.prefetchQuery(r),Promise.resolve(t)}}getQueriesData(e){return h(be,this).findAll(e).map(e=>[e.queryKey,e.state.data])}setQueryData(e,t,r){const n=this.defaultQueryOptions({queryKey:e}),a=h(be,this).get(n.queryHash),o=function(e,t){return"function"===typeof e?e(t):e}(t,null===a||void 0===a?void 0:a.state.data);if(void 0!==o)return h(be,this).build(this,n).setData(o,u(u({},r),{},{manual:!0}))}setQueriesData(e,t,r){return U.batch(()=>h(be,this).findAll(e).map(e=>{let n=e.queryKey;return[n,this.setQueryData(n,t,r)]}))}getQueryState(e){var t;const r=this.defaultQueryOptions({queryKey:e});return null===(t=h(be,this).get(r.queryHash))||void 0===t?void 0:t.state}removeQueries(e){const t=h(be,this);U.batch(()=>{t.findAll(e).forEach(e=>{t.remove(e)})})}resetQueries(e,t){const r=h(be,this),n=u({type:"active"},e);return U.batch(()=>(r.findAll(e).forEach(e=>{e.reset()}),this.refetchQueries(n,t)))}cancelQueries(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const t=u({revert:!0},arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}),r=U.batch(()=>h(be,this).findAll(e).map(e=>e.cancel(t)));return Promise.all(r).then(x).catch(x)}invalidateQueries(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return U.batch(()=>{var r,n;if(h(be,this).findAll(e).forEach(e=>{e.invalidate()}),"none"===e.refetchType)return Promise.resolve();const a=u(u({},e),{},{type:null!==(r=null!==(n=e.refetchType)&&void 0!==n?n:e.type)&&void 0!==r?r:"active"});return this.refetchQueries(a,t)})}refetchQueries(){var e;let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},r=arguments.length>1?arguments[1]:void 0;const n=u(u({},r),{},{cancelRefetch:null===(e=null===r||void 0===r?void 0:r.cancelRefetch)||void 0===e||e}),a=U.batch(()=>h(be,this).findAll(t).filter(e=>!e.isDisabled()).map(e=>{let t=e.fetch(void 0,n);return n.throwOnError||(t=t.catch(x)),"paused"===e.state.fetchStatus?Promise.resolve():t}));return Promise.all(a).then(x)}fetchQuery(e){const t=this.defaultQueryOptions(e);void 0===t.retry&&(t.retry=!1);const r=h(be,this).build(this,t);return r.isStaleByTime(b(t.staleTime,r))?r.fetch(t):Promise.resolve(r.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(x).catch(x)}fetchInfiniteQuery(e){return e.behavior=_e(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(x).catch(x)}ensureInfiniteQueryData(e){return e.behavior=_e(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return K.isOnline()?h(ye,this).resumePausedMutations():Promise.resolve()}getQueryCache(){return h(be,this)}getMutationCache(){return h(ye,this)}getDefaultOptions(){return h(we,this)}setDefaultOptions(e){v(we,this,e)}setQueryDefaults(e,t){h(je,this).set(N(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...h(je,this).values()];let r={};return t.forEach(t=>{k(e,t.queryKey)&&(r=u(u({},r),t.defaultOptions))}),r}setMutationDefaults(e,t){h(Ne,this).set(N(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...h(Ne,this).values()];let r={};return t.forEach(t=>{k(e,t.mutationKey)&&(r=u(u({},r),t.defaultOptions))}),r}defaultQueryOptions(e){if(e._defaulted)return e;const t=u(u(u(u({},h(we,this).queries),this.getQueryDefaults(e.queryKey)),e),{},{_defaulted:!0});return t.queryHash||(t.queryHash=j(t.queryKey,t)),void 0===t.refetchOnReconnect&&(t.refetchOnReconnect="always"!==t.networkMode),void 0===t.throwOnError&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode="offlineFirst"),!0!==t.enabled&&t.queryFn===M&&(t.enabled=!1),t}defaultMutationOptions(e){return null!==e&&void 0!==e&&e._defaulted?e:u(u(u(u({},h(we,this).mutations),(null===e||void 0===e?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey)),e),{},{_defaulted:!0})}clear(){h(be,this).clear(),h(ye,this).clear()}}),De=r(579),Te=a.createContext(void 0),Re=e=>{let t=e.client,r=e.children;return a.useEffect(()=>(t.mount(),()=>{t.unmount()}),[t]),(0,De.jsx)(Te.Provider,{value:t,children:r})};function Ie(e,t){if(null==e)return{};var r,n,a=function(e,t){if(null==e)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(-1!==t.indexOf(n))continue;r[n]=e[n]}return r}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;ne.length)&&(t=e.length);for(var r=0,n=Array(t);r0&&void 0!==arguments[0]?arguments[0]:{})}function Ze(e,t){if(!1===e||null===e||"undefined"===typeof e)throw new Error(t)}function et(e,t){if(!e){"undefined"!==typeof console&&console.warn(t);try{throw new Error(t)}catch(r){}}}function tt(e,t){return{usr:e.state,key:e.key,idx:t,masked:e.mask?{pathname:e.pathname,search:e.search,hash:e.hash}:void 0}}function rt(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,n=arguments.length>3?arguments[3]:void 0,a=arguments.length>4?arguments[4]:void 0;return u(u({pathname:"string"===typeof e?e:e.pathname,search:"",hash:""},"string"===typeof t?at(t):t),{},{state:r,key:t&&t.key||n||Math.random().toString(36).substring(2,10),mask:a})}function nt(e){let t=e.pathname,r=void 0===t?"/":t,n=e.search,a=void 0===n?"":n,o=e.hash,i=void 0===o?"":o;return a&&"?"!==a&&(r+="?"===a.charAt(0)?a:"?"+a),i&&"#"!==i&&(r+="#"===i.charAt(0)?i:"#"+i),r}function at(e){let t={};if(e){let r=e.indexOf("#");r>=0&&(t.hash=e.substring(r),e=e.substring(0,r));let n=e.indexOf("?");n>=0&&(t.search=e.substring(n),e=e.substring(0,n)),e&&(t.pathname=e)}return t}function ot(e,t,r){let n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},a=n.window,o=void 0===a?document.defaultView:a,i=n.v5Compat,s=void 0!==i&&i,l=o.history,c="POP",d=null,m=f();function f(){return(l.state||{idx:null}).idx}function p(){c="POP";let e=f(),t=null==e?null:e-m;m=e,d&&d({action:c,location:v.location,delta:t})}function h(e){return it(e)}null==m&&(m=0,l.replaceState(u(u({},l.state),{},{idx:m}),""));let v={get action(){return c},get location(){return e(o,l)},listen(e){if(d)throw new Error("A history only accepts one active listener");return o.addEventListener(Qe,p),d=e,()=>{o.removeEventListener(Qe,p),d=null}},createHref:e=>t(o,e),createURL:h,encodeLocation(e){let t=h(e);return{pathname:t.pathname,search:t.search,hash:t.hash}},push:function(e,t){c="PUSH";let n=Xe(e)?e:rt(v.location,e,t);r&&r(n,e),m=f()+1;let a=tt(n,m),i=v.createHref(n.mask||n);try{l.pushState(a,"",i)}catch(u){if(u instanceof DOMException&&"DataCloneError"===u.name)throw u;o.location.assign(i)}s&&d&&d({action:c,location:v.location,delta:1})},replace:function(e,t){c="REPLACE";let n=Xe(e)?e:rt(v.location,e,t);r&&r(n,e),m=f();let a=tt(n,m),o=v.createHref(n.mask||n);l.replaceState(a,"",o),s&&d&&d({action:c,location:v.location,delta:0})},go:e=>l.go(e)};return v}function it(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r="http://localhost";"undefined"!==typeof window&&(r="null"!==window.location.origin?window.location.origin:window.location.href),Ze(r,"No window.location.(origin|href) available to create URL");let n="string"===typeof e?e:nt(e);return n=n.replace(/ $/,"%20"),!t&&n.startsWith("//")&&(n=r+n),new URL(n,r)}new WeakMap;function st(e,t){return lt(e,t,arguments.length>2&&void 0!==arguments[2]?arguments[2]:"/",!1)}function lt(e,t,r,n,a){let o=bt(("string"===typeof t?at(t):t).pathname||"/",r);if(null==o)return null;let i=null!==a&&void 0!==a?a:ct(e),s=null,l=xt(o);for(let c=0;null==s&&ce.score!==t.score?t.score-e.score:function(e,t){let r=e.length===t.length&&e.slice(0,-1).every((e,r)=>e===t[r]);return r?e[e.length-1]-t[t.length-1]:0}(e.routesMeta.map(e=>e.childrenIndex),t.routesMeta.map(e=>e.childrenIndex)))}(t),t}function dt(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"",a=arguments.length>4&&void 0!==arguments[4]&&arguments[4],o=function(e,o){let i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:a,s=arguments.length>3?arguments[3]:void 0,l={relativePath:void 0===s?e.path||"":s,caseSensitive:!0===e.caseSensitive,childrenIndex:o,route:e};if(l.relativePath.startsWith("/")){if(!l.relativePath.startsWith(n)&&i)return;Ze(l.relativePath.startsWith(n),'Absolute route path "'.concat(l.relativePath,'" nested under path "').concat(n,'" is not valid. An absolute child route path must start with the combined path of all its parent routes.')),l.relativePath=l.relativePath.slice(n.length)}let c=Ct([n,l.relativePath]),d=r.concat(l);e.children&&e.children.length>0&&(Ze(!0!==e.index,'Index routes must not have child routes. Please remove all child routes from route path "'.concat(c,'".')),dt(e.children,t,d,c,i)),(null!=e.path||e.index)&&t.push({path:c,score:pt(c,e.index),routesMeta:d})};return e.forEach((e,t)=>{var r;if(""!==e.path&&null!==(r=e.path)&&void 0!==r&&r.includes("?"))for(let n of ut(e.path))o(e,t,!0,n);else o(e,t)}),t}function ut(e){let t=e.split("/");if(0===t.length)return[];let r=Ue(t),n=r[0],a=ze(r).slice(1),o=n.endsWith("?"),i=n.replace(/\?$/,"");if(0===a.length)return o?[i,""]:[i];let s=ut(a.join("/")),l=[];return l.push(...s.map(e=>""===e?i:[i,e].join("/"))),o&&l.push(...s),l.map(t=>e.startsWith("/")&&""===t?"/":t)}var mt=/^:[\w-]+$/,ft=e=>"*"===e;function pt(e,t){let r=e.split("/"),n=r.length;return r.some(ft)&&(n+=-2),t&&(n+=2),r.filter(e=>!ft(e)).reduce((e,t)=>e+(mt.test(t)?3:""===t?1:10),n)}function ht(e,t){let r=arguments.length>2&&void 0!==arguments[2]&&arguments[2],n=e.routesMeta,a={},o="/",i=[];for(let s=0;s{let n=t.paramName,a=t.isOptional;if("*"===n){let e=l[r]||"";s=i.slice(0,i.length-e.length).replace(/(.)\/+$/,"$1")}const o=l[r];return e[n]=a&&!o?void 0:(o||"").replace(/%2F/g,"/"),e},{});return{params:c,pathname:i,pathnameBase:s,pattern:e}}function gt(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];et("*"===e||!e.endsWith("*")||e.endsWith("/*"),'Route path "'.concat(e,'" will be treated as if it were "').concat(e.replace(/\*$/,"/*"),'" because the `*` character must always follow a `/` in the pattern. To get rid of this warning, please change the route path to "').concat(e.replace(/\*$/,"/*"),'".'));let n=[],a="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(e,t,r,a,o)=>{if(n.push({paramName:t,isOptional:null!=r}),r){let t=o.charAt(a+e.length);return t&&"/"!==t?"/([^\\/]*)":"(?:/([^\\/]*))?"}return"/([^\\/]+)"}).replace(/\/([\w-]+)\?(\/|$)/g,"(/$1)?$2");return e.endsWith("*")?(n.push({paramName:"*"}),a+="*"===e||"/*"===e?"(.*)$":"(?:\\/(.+)|\\/*)$"):r?a+="\\/*$":""!==e&&"/"!==e&&(a+="(?:(?=\\/|$))"),[new RegExp(a,t?void 0:"i"),n]}function xt(e){try{return e.split("/").map(e=>decodeURIComponent(e).replace(/\//g,"%2F")).join("/")}catch(t){return et(!1,'The URL path "'.concat(e,'" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (').concat(t,").")),e}}function bt(e,t){if("/"===t)return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let r=t.endsWith("/")?t.length-1:t.length,n=e.charAt(r);return n&&"/"!==n?null:e.slice(r)||"/"}var yt=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i;function wt(e,t){let r=Et(t).split("/");return e.split("/").forEach(e=>{".."===e?r.length>1&&r.pop():"."!==e&&r.push(e)}),r.length>1?r.join("/"):"/"}function jt(e,t,r,n){return"Cannot include a '".concat(e,"' character in a manually specified `to.").concat(t,"` field [").concat(JSON.stringify(n),"]. Please separate it out to the `to.").concat(r,'` field. Alternatively you may provide the full path as a string in and the router will parse it for you.')}function Nt(e){return e.filter((e,t)=>0===t||e.route.path&&e.route.path.length>0)}function kt(e){let t=Nt(e);return t.map((e,r)=>r===t.length-1?e.pathname:e.pathnameBase)}function St(e,t,r){let n,a=arguments.length>3&&void 0!==arguments[3]&&arguments[3];"string"===typeof e?n=at(e):(n=u({},e),Ze(!n.pathname||!n.pathname.includes("?"),jt("?","pathname","search",n)),Ze(!n.pathname||!n.pathname.includes("#"),jt("#","pathname","hash",n)),Ze(!n.search||!n.search.includes("#"),jt("#","search","hash",n)));let o,i=""===e||""===n.pathname,s=i?"/":n.pathname;if(null==s)o=r;else{let e=t.length-1;if(!a&&s.startsWith("..")){let t=s.split("/");for(;".."===t[0];)t.shift(),e-=1;n.pathname=t.join("/")}o=e>=0?t[e]:"/"}let l=function(e){let t,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"/",n="string"===typeof e?at(e):e,a=n.pathname,o=n.search,i=void 0===o?"":o,s=n.hash,l=void 0===s?"":s;return a?(a=Pt(a),t=a.startsWith("/")?wt(a.substring(1),"/"):wt(a,r)):t=r,{pathname:t,search:Ot(i),hash:At(l)}}(n,o),c=s&&"/"!==s&&s.endsWith("/"),d=(i||"."===s)&&r.endsWith("/");return l.pathname.endsWith("/")||!c&&!d||(l.pathname+="/"),l}var Pt=e=>e.replace(/\/\/+/g,"/"),Ct=e=>Pt(e.join("/")),Et=e=>e.replace(/\/+$/,""),_t=e=>Et(e).replace(/^\/*/,"/"),Ot=e=>e&&"?"!==e?e.startsWith("?")?e:"?"+e:"",At=e=>e&&"#"!==e?e.startsWith("#")?e:"#"+e:"";var Mt=class{constructor(e,t,r){let n=arguments.length>3&&void 0!==arguments[3]&&arguments[3];this.status=e,this.statusText=t||"",this.internal=n,r instanceof Error?(this.data=r.toString(),this.error=r):this.data=r}};function Dt(e){return null!=e&&"number"===typeof e.status&&"string"===typeof e.statusText&&"boolean"===typeof e.internal&&"data"in e}function Tt(e){let t=e.map(e=>e.route.path).filter(Boolean);return Ct(t)||"/"}var Rt="undefined"!==typeof window&&"undefined"!==typeof window.document&&"undefined"!==typeof window.document.createElement;function It(e,t){let r=e;if("string"!==typeof r||!yt.test(r))return{absoluteURL:void 0,isExternal:!1,to:r};let n=r,a=!1;if(Rt)try{let e=new URL(window.location.href),n=r.startsWith("//")?new URL(e.protocol+r):new URL(r),o=bt(n.pathname,t);n.origin===e.origin&&null!=o?r=o+n.search+n.hash:a=!0}catch(o){et(!1,' contains an invalid URL which will probably break when clicked - please update to a valid URL path.'))}return{absoluteURL:n,isExternal:a,to:r}}Symbol("Uninstrumented");Object.getOwnPropertyNames(Object.prototype).sort().join("\0");var zt=["POST","PUT","PATCH","DELETE"],Lt=(new Set(zt),["GET",...zt]);new Set(Lt),Symbol("ResetLoaderData");new WeakMap,new WeakMap,new WeakMap,new WeakMap;var Ft=a.createContext(null);Ft.displayName="DataRouter";var Bt=a.createContext(null);Bt.displayName="DataRouterState";var Ut=a.createContext(!1);function Vt(){return a.useContext(Ut)}var Ht=a.createContext({isTransitioning:!1});Ht.displayName="ViewTransition";var Wt=a.createContext(new Map);Wt.displayName="Fetchers";var qt=a.createContext(null);qt.displayName="Await";var Kt=a.createContext(null);Kt.displayName="Navigation";var Gt=a.createContext(null);Gt.displayName="Location";var Yt=a.createContext({outlet:null,matches:[],isDataRoute:!1});Yt.displayName="Route";var $t=a.createContext(null);$t.displayName="RouteError";var Qt="REACT_ROUTER_ERROR";function Xt(){return null!=a.useContext(Gt)}function Jt(){return Ze(Xt(),"useLocation() may be used only in the context of a component."),a.useContext(Gt).location}var Zt="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function er(e){a.useContext(Kt).static||a.useLayoutEffect(e)}function tr(){return a.useContext(Yt).isDataRoute?function(){let e=fr("useNavigate").router,t=hr("useNavigate"),r=a.useRef(!1);er(()=>{r.current=!0});let n=a.useCallback(async function(n){let a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};et(r.current,Zt),r.current&&("number"===typeof n?await e.navigate(n):await e.navigate(n,u({fromRouteId:t},a)))},[e,t]);return n}():function(){Ze(Xt(),"useNavigate() may be used only in the context of a component.");let e=a.useContext(Ft),t=a.useContext(Kt),r=t.basename,n=t.navigator,o=a.useContext(Yt).matches,i=Jt().pathname,s=JSON.stringify(kt(o)),l=a.useRef(!1);er(()=>{l.current=!0});let c=a.useCallback(function(t){let a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(et(l.current,Zt),!l.current)return;if("number"===typeof t)return void n.go(t);let o=St(t,JSON.parse(s),i,"path"===a.relative);null==e&&"/"!==r&&(o.pathname="/"===o.pathname?r:Ct([r,o.pathname])),(a.replace?n.replace:n.push)(o,a.state,a)},[r,n,s,i,e]);return c}()}var rr=a.createContext(null);function nr(e){let t=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).relative,r=a.useContext(Yt).matches,n=Jt().pathname,o=JSON.stringify(kt(r));return a.useMemo(()=>St(e,JSON.parse(o),n,"path"===t),[e,o,n,t])}function ar(e,t,r){Ze(Xt(),"useRoutes() may be used only in the context of a component.");let n=a.useContext(Kt).navigator,o=a.useContext(Yt).matches,i=o[o.length-1],s=i?i.params:{},l=i?i.pathname:"/",c=i?i.pathnameBase:"/",d=i&&i.route;{let e=d&&d.path||"";xr(l,!d||e.endsWith("*")||e.endsWith("*?"),'You rendered descendant (or called `useRoutes()`) at "'.concat(l,'" (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.\n\nPlease change the parent to .'))}let m,f=Jt();if(t){var p;let e="string"===typeof t?at(t):t;Ze("/"===c||(null===(p=e.pathname)||void 0===p?void 0:p.startsWith(c)),'When overriding the location using `` or `useRoutes(routes, location)`, the location pathname must begin with the portion of the URL pathname that was matched by all parent routes. The current pathname base is "'.concat(c,'" but pathname "').concat(e.pathname,'" was given in the `location` prop.')),m=e}else m=f;let h=m.pathname||"/",v=h;if("/"!==c){let e=c.replace(/^\//,"").split("/");v="/"+h.replace(/^\//,"").split("/").slice(e.length).join("/")}let g=r&&r.state.matches.length?r.state.matches.map(e=>Object.assign(e,{route:r.manifest[e.route.id]||e.route})):st(e,{pathname:v});et(d||null!=g,'No routes matched location "'.concat(m.pathname).concat(m.search).concat(m.hash,'" ')),et(null==g||void 0!==g[g.length-1].route.element||void 0!==g[g.length-1].route.Component||void 0!==g[g.length-1].route.lazy,'Matched leaf route at location "'.concat(m.pathname).concat(m.search).concat(m.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.'));let x=ur(g&&g.map(e=>Object.assign({},e,{params:Object.assign({},s,e.params),pathname:Ct([c,n.encodeLocation?n.encodeLocation(e.pathname.replace(/%/g,"%25").replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:e.pathname]),pathnameBase:"/"===e.pathnameBase?c:Ct([c,n.encodeLocation?n.encodeLocation(e.pathnameBase.replace(/%/g,"%25").replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:e.pathnameBase])})),o,r);return t&&x?a.createElement(Gt.Provider,{value:{location:u({pathname:"/",search:"",hash:"",state:null,key:"default",mask:void 0},m),navigationType:"POP"}},x):x}function or(){let e=vr(),t=Dt(e)?"".concat(e.status," ").concat(e.statusText):e instanceof Error?e.message:JSON.stringify(e),r=e instanceof Error?e.stack:null,n="rgba(200,200,200, 0.5)",o={padding:"0.5rem",backgroundColor:n},i={padding:"2px 4px",backgroundColor:n},s=null;return console.error("Error handled by React Router default ErrorBoundary:",e),s=a.createElement(a.Fragment,null,a.createElement("p",null,"\ud83d\udcbf Hey developer \ud83d\udc4b"),a.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",a.createElement("code",{style:i},"ErrorBoundary")," or"," ",a.createElement("code",{style:i},"errorElement")," prop on your route.")),a.createElement(a.Fragment,null,a.createElement("h2",null,"Unexpected Application Error!"),a.createElement("h3",{style:{fontStyle:"italic"}},t),r?a.createElement("pre",{style:o},r):null,s)}var ir=a.createElement(or,null),sr=class extends a.Component{constructor(e){super(e),this.state={location:e.location,revalidation:e.revalidation,error:e.error}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,t){return t.location!==e.location||"idle"!==t.revalidation&&"idle"===e.revalidation?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:void 0!==e.error?e.error:t.error,location:t.location,revalidation:e.revalidation||t.revalidation}}componentDidCatch(e,t){this.props.onError?this.props.onError(e,t):console.error("React Router caught the following error during render",e)}render(){let e=this.state.error;if(this.context&&"object"===typeof e&&e&&"digest"in e&&"string"===typeof e.digest){const t=function(e){if(e.startsWith("".concat(Qt,":").concat("ROUTE_ERROR_RESPONSE",":{")))try{let t=JSON.parse(e.slice(40));if("object"===typeof t&&t&&"number"===typeof t.status&&"string"===typeof t.statusText)return new Mt(t.status,t.statusText,t.data)}catch(t){}}(e.digest);t&&(e=t)}let t=void 0!==e?a.createElement(Yt.Provider,{value:this.props.routeContext},a.createElement($t.Provider,{value:e,children:this.props.component})):this.props.children;return this.context?a.createElement(cr,{error:e},t):t}};sr.contextType=Ut;var lr=new WeakMap;function cr(e){let t=e.children,r=e.error,n=a.useContext(Kt).basename;if("object"===typeof r&&r&&"digest"in r&&"string"===typeof r.digest){let e=function(e){if(e.startsWith("".concat(Qt,":").concat("REDIRECT",":{")))try{let t=JSON.parse(e.slice(28));if("object"===typeof t&&t&&"number"===typeof t.status&&"string"===typeof t.statusText&&"string"===typeof t.location&&"boolean"===typeof t.reloadDocument&&"boolean"===typeof t.replace)return t}catch(t){}}(r.digest);if(e){let t=lr.get(r);if(t)throw t;let o=It(e.location,n);if(Rt&&!lr.get(r)){if(!o.isExternal&&!e.reloadDocument){const t=Promise.resolve().then(()=>window.__reactRouterDataRouter.navigate(o.to,{replace:e.replace}));throw lr.set(r,t),t}window.location.href=o.absoluteURL||o.to}return a.createElement("meta",{httpEquiv:"refresh",content:"0;url=".concat(o.absoluteURL||o.to)})}}return t}function dr(e){let t=e.routeContext,r=e.match,n=e.children,o=a.useContext(Ft);return o&&o.static&&o.staticContext&&(r.route.errorElement||r.route.ErrorBoundary)&&(o.staticContext._deepestRenderedBoundaryId=r.route.id),a.createElement(Yt.Provider,{value:t},n)}function ur(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],r=arguments.length>2?arguments[2]:void 0,n=null===r||void 0===r?void 0:r.state;if(null==e){if(!n)return null;if(n.errors)e=n.matches;else{if(0!==t.length||n.initialized||!(n.matches.length>0))return null;e=n.matches}}let o=e,i=null===n||void 0===n?void 0:n.errors;if(null!=i){let e=o.findIndex(e=>e.route.id&&void 0!==(null===i||void 0===i?void 0:i[e.route.id]));Ze(e>=0,"Could not find a matching route for errors on route IDs: ".concat(Object.keys(i).join(","))),o=o.slice(0,Math.min(o.length,e+1))}let s=!1,l=-1;if(r&&n){s=n.renderFallback;for(let e=0;e=0?o.slice(0,l+1):[o[0]];break}}}}let c=null===r||void 0===r?void 0:r.onError,d=n&&c?(e,t)=>{var r,a;c(e,{location:n.location,params:null!==(r=null===(a=n.matches)||void 0===a||null===(a=a[0])||void 0===a?void 0:a.params)&&void 0!==r?r:{},pattern:Tt(n.matches),errorInfo:t})}:void 0;return o.reduceRight((e,r,c)=>{let u,m=!1,f=null,p=null;n&&(u=i&&r.route.id?i[r.route.id]:void 0,f=r.route.errorElement||ir,s&&(l<0&&0===c?(xr("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),m=!0,p=null):l===c&&(m=!0,p=r.route.hydrateFallbackElement||null)));let h=t.concat(o.slice(0,c+1)),v=()=>{let t;return t=u?f:m?p:r.route.Component?a.createElement(r.route.Component,null):r.route.element?r.route.element:e,a.createElement(dr,{match:r,routeContext:{outlet:e,matches:h,isDataRoute:null!=n},children:t})};return n&&(r.route.ErrorBoundary||r.route.errorElement||0===c)?a.createElement(sr,{location:n.location,revalidation:n.revalidation,component:f,error:u,children:v(),routeContext:{outlet:null,matches:h,isDataRoute:!0},onError:d}):v()},null)}function mr(e){return"".concat(e," must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.")}function fr(e){let t=a.useContext(Ft);return Ze(t,mr(e)),t}function pr(e){let t=a.useContext(Bt);return Ze(t,mr(e)),t}function hr(e){let t=function(e){let t=a.useContext(Yt);return Ze(t,mr(e)),t}(e),r=t.matches[t.matches.length-1];return Ze(r.route.id,"".concat(e,' can only be used on routes that contain a unique "id"')),r.route.id}function vr(){var e;let t=a.useContext($t),r=pr("useRouteError"),n=hr("useRouteError");return void 0!==t?t:null===(e=r.errors)||void 0===e?void 0:e[n]}var gr={};function xr(e,t,r){t||gr[e]||(gr[e]=!0,et(!1,r))}var br={};function yr(e,t){e||br[t]||(br[t]=!0,console.warn(t))}o.useOptimistic;a.memo(wr);function wr(e){let t=e.routes,r=e.manifest,n=e.future;return ar(t,void 0,{manifest:r,state:e.state,isStatic:e.isStatic,onError:e.onError,future:n})}function jr(e){let t=e.to,r=e.replace,n=e.state,o=e.relative;Ze(Xt()," may be used only in the context of a component."),et(!a.useContext(Kt).static," must not be used on the initial render in a . This is a no-op, but you should modify your code so the is only ever rendered in response to some user interaction or state change.");let i=a.useContext(Yt).matches,s=Jt().pathname,l=tr(),c=St(t,kt(i),s,"path"===o),d=JSON.stringify(c);return a.useEffect(()=>{l(JSON.parse(d),{replace:r,state:n,relative:o})},[l,d,o,r,n]),null}function Nr(e){return function(e){let t=a.useContext(Yt).outlet;return a.useMemo(()=>t&&a.createElement(rr.Provider,{value:e},t),[t,e])}(e.context)}function kr(e){Ze(!1,"A is only ever to be used as the child of element, never rendered directly. Please wrap your in a .")}function Sr(e){let t=e.basename,r=void 0===t?"/":t,n=e.children,o=void 0===n?null:n,i=e.location,s=e.navigationType,l=void 0===s?"POP":s,c=e.navigator,d=e.static,u=void 0!==d&&d,m=e.useTransitions;Ze(!Xt(),"You cannot render a inside another . You should never have more than one in your app.");let f=r.replace(/^\/*/,"/"),p=a.useMemo(()=>({basename:f,navigator:c,static:u,useTransitions:m,future:{}}),[f,c,u,m]);"string"===typeof i&&(i=at(i));let h=i,v=h.pathname,g=void 0===v?"/":v,x=h.search,b=void 0===x?"":x,y=h.hash,w=void 0===y?"":y,j=h.state,N=void 0===j?null:j,k=h.key,S=void 0===k?"default":k,P=h.mask,C=a.useMemo(()=>{let e=bt(g,f);return null==e?null:{location:{pathname:e,search:b,hash:w,state:N,key:S,mask:P},navigationType:l}},[f,g,b,w,N,S,l,P]);return et(null!=C,' is not able to match the URL "').concat(g).concat(b).concat(w,"\" because it does not start with the basename, so the won't render anything.")),null==C?null:a.createElement(Kt.Provider,{value:p},a.createElement(Gt.Provider,{children:o,value:C}))}function Pr(e){let t=e.children,r=e.location;return ar(Cr(t),r)}a.Component;function Cr(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],r=[];return a.Children.forEach(e,(e,n)=>{if(!a.isValidElement(e))return;let o=[...t,n];if(e.type===a.Fragment)return void r.push.apply(r,Cr(e.props.children,o));Ze(e.type===kr,"[".concat("string"===typeof e.type?e.type:e.type.name,"] is not a component. All component children of must be a or ")),Ze(!e.props.index||!e.props.children,"An index route cannot have child routes.");let i={id:e.props.id||o.join("-"),caseSensitive:e.props.caseSensitive,element:e.props.element,Component:e.props.Component,index:e.props.index,path:e.props.path,middleware:e.props.middleware,loader:e.props.loader,action:e.props.action,hydrateFallbackElement:e.props.hydrateFallbackElement,HydrateFallback:e.props.HydrateFallback,errorElement:e.props.errorElement,ErrorBoundary:e.props.ErrorBoundary,hasErrorBoundary:!0===e.props.hasErrorBoundary||null!=e.props.ErrorBoundary||null!=e.props.errorElement,shouldRevalidate:e.props.shouldRevalidate,handle:e.props.handle,lazy:e.props.lazy};e.props.children&&(i.children=Cr(e.props.children,o)),r.push(i)}),r}var Er="get",_r="application/x-www-form-urlencoded";function Or(e){return"undefined"!==typeof HTMLElement&&e instanceof HTMLElement}var Ar=null;var Mr=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function Dr(e){return null==e||Mr.has(e)?e:(et(!1,'"'.concat(e,'" is not a valid `encType` for `
`/`` and will default to "').concat(_r,'"')),null)}function Tr(e,t){let r,n,a,o,i;if(function(e){return Or(e)&&"form"===e.tagName.toLowerCase()}(e)){let i=e.getAttribute("action");n=i?bt(i,t):null,r=e.getAttribute("method")||Er,a=Dr(e.getAttribute("enctype"))||_r,o=new FormData(e)}else if(function(e){return Or(e)&&"button"===e.tagName.toLowerCase()}(e)||function(e){return Or(e)&&"input"===e.tagName.toLowerCase()}(e)&&("submit"===e.type||"image"===e.type)){let i=e.form;if(null==i)throw new Error('Cannot submit a