diff --git a/go.mod b/go.mod index 69e2820b..4fcd5af2 100644 --- a/go.mod +++ b/go.mod @@ -5,11 +5,11 @@ go 1.22.0 toolchain go1.23.2 require ( - github.com/alibabacloud-go/cas-20200407/v2 v2.3.0 github.com/alibabacloud-go/cdn-20180510/v5 v5.0.0 github.com/alibabacloud-go/darabonba-openapi/v2 v2.0.9 github.com/alibabacloud-go/tea v1.2.2 github.com/alibabacloud-go/tea-utils/v2 v2.0.6 + github.com/aliyun/aliyun-oss-go-sdk v3.0.2+incompatible github.com/go-acme/lego/v4 v4.19.2 github.com/gojek/heimdall/v7 v7.0.3 github.com/labstack/echo/v5 v5.0.0-20230722203903-ec5b858dab61 diff --git a/go.sum b/go.sum index 2cf2f9fc..71279e5c 100644 --- a/go.sum +++ b/go.sum @@ -31,12 +31,9 @@ github.com/ajstarks/svgo v0.0.0-20180226025133-644b8db467af/go.mod h1:K08gAheRH3 github.com/alex-ant/gomath v0.0.0-20160516115720-89013a210a82/go.mod h1:nLnM0KdK1CmygvjpDUO6m1TjSsiQtL61juhNsvV/JVI= github.com/alibabacloud-go/alibabacloud-gateway-spi v0.0.4 h1:iC9YFYKDGEy3n/FtqJnOkZsene9olVspKmkX5A2YBEo= github.com/alibabacloud-go/alibabacloud-gateway-spi v0.0.4/go.mod h1:sCavSAvdzOjul4cEqeVtvlSaSScfNsTQ+46HwlTL1hc= -github.com/alibabacloud-go/cas-20200407/v2 v2.3.0 h1:nOrp0n2nFZiYN0wIG7S26YVVaMMzOBkX9GJqUvYnGeE= -github.com/alibabacloud-go/cas-20200407/v2 v2.3.0/go.mod h1:yzkgdLANANu/v56k0ptslGl++JJL4Op1V09HTavfoCo= github.com/alibabacloud-go/cdn-20180510/v5 v5.0.0 h1:yTKngw4rBR3hdpoo/uCyBffYXfPfjNjlaDL8nTYUIds= github.com/alibabacloud-go/cdn-20180510/v5 v5.0.0/go.mod h1:HxQrwVKBx3/6bIwmdDcpqBpSQt2tpi/j4LfEhl+QFPk= github.com/alibabacloud-go/darabonba-openapi/v2 v2.0.0/go.mod h1:5JHVmnHvGzR2wNdgaW1zDLQG8kOC4Uec8ubkMogW7OQ= -github.com/alibabacloud-go/darabonba-openapi/v2 v2.0.6/go.mod h1:CzQnh+94WDnJOnKZH5YRyouL+OOcdBnXY5VWAf0McgI= github.com/alibabacloud-go/darabonba-openapi/v2 v2.0.8/go.mod h1:CzQnh+94WDnJOnKZH5YRyouL+OOcdBnXY5VWAf0McgI= github.com/alibabacloud-go/darabonba-openapi/v2 v2.0.9 h1:fxMCrZatZfXq5nLcgkmWBXmU3FLC1OR+m/SqVtMqflk= github.com/alibabacloud-go/darabonba-openapi/v2 v2.0.9/go.mod h1:bb+Io8Sn2RuM3/Rpme6ll86jMyFSrD1bxeV/+v61KeU= @@ -82,6 +79,8 @@ github.com/alibabacloud-go/tea-xml v1.1.3 h1:7LYnm+JbOq2B+T/B0fHC4Ies4/FofC4zHzY github.com/alibabacloud-go/tea-xml v1.1.3/go.mod h1:Rq08vgCcCAjHyRi/M7xlHKUykZCEtyBy9+DPF6GgEu8= github.com/aliyun/alibaba-cloud-sdk-go v1.63.15 h1:r2uwBUQhLhcPzaWz9tRJqc8MjYwHb+oF2+Q6467BF14= github.com/aliyun/alibaba-cloud-sdk-go v1.63.15/go.mod h1:SOSDHfe1kX91v3W5QiBsWSLqeLxImobbMX1mxrFHsVQ= +github.com/aliyun/aliyun-oss-go-sdk v3.0.2+incompatible h1:8psS8a+wKfiLt1iVDX79F7Y6wUM49Lcha2FMXt4UM8g= +github.com/aliyun/aliyun-oss-go-sdk v3.0.2+incompatible/go.mod h1:T/Aws4fEfogEE9v+HPhhw+CntffsBHJ8nXQCwKr0/g8= github.com/aliyun/credentials-go v1.1.2/go.mod h1:ozcZaMR5kLM7pwtCMEpVmQ242suV6qTJya2bDq4X1Tw= github.com/aliyun/credentials-go v1.3.1 h1:uq/0v7kWrxmoLGpqjx7vtQ/s03f0zR//0br/xWDTE28= github.com/aliyun/credentials-go v1.3.1/go.mod h1:8jKYhQuDawt8x2+fusqa1Y6mPxemTsBEN04dgcAcYz0= diff --git a/internal/deployer/aliyun.go b/internal/deployer/aliyun.go index 52bd6707..ce8f0a2d 100644 --- a/internal/deployer/aliyun.go +++ b/internal/deployer/aliyun.go @@ -1,23 +1,16 @@ package deployer import ( - "certimate/internal/applicant" "certimate/internal/domain" - "certimate/internal/utils/rand" "context" "encoding/json" - "errors" "fmt" - "strings" - cas20200407 "github.com/alibabacloud-go/cas-20200407/v2/client" - openapi "github.com/alibabacloud-go/darabonba-openapi/v2/client" - util "github.com/alibabacloud-go/tea-utils/v2/service" - "github.com/alibabacloud-go/tea/tea" + "github.com/aliyun/aliyun-oss-go-sdk/oss" ) type aliyun struct { - client *cas20200407.Client + client *oss.Client option *DeployerOption infos []string } @@ -47,160 +40,31 @@ func (a *aliyun) GetInfo() []string { } func (a *aliyun) Deploy(ctx context.Context) error { - - // 查询有没有对应的资源 - resource, err := a.resource() - if err != nil { - return err - } - - a.infos = append(a.infos, toStr("查询对应的资源", resource)) - - // 查询有没有对应的联系人 - contacts, err := a.contacts() - if err != nil { - return err - } - - a.infos = append(a.infos, toStr("查询联系人", contacts)) - - // 上传证书 - certId, err := a.uploadCert(&a.option.Certificate) - if err != nil { - return err - } - - a.infos = append(a.infos, toStr("上传证书", certId)) - - // 部署证书 - jobId, err := a.deploy(resource, certId, contacts) - if err != nil { - return err - } - - a.infos = append(a.infos, toStr("创建部署证书任务", jobId)) - - // 等待部署成功 - err = a.updateDeployStatus(*jobId) - if err != nil { - return err - } - - // 部署成功后删除旧的证书 - a.deleteCert(resource) - - return nil -} - -func (a *aliyun) updateDeployStatus(jobId int64) error { - // 查询部署状态 - req := &cas20200407.UpdateDeploymentJobStatusRequest{ - JobId: tea.Int64(jobId), - } - - resp, err := a.client.UpdateDeploymentJobStatus(req) - if err != nil { - return err - } - a.infos = append(a.infos, toStr("查询对应的资源", resp)) - return nil -} - -func (a *aliyun) deleteCert(resource *cas20200407.ListCloudResourcesResponseBodyData) error { - // 查询有没有对应的资源 - if resource.CertId == nil { - return nil - } - - // 删除证书 - _, err := a.client.DeleteUserCertificate(&cas20200407.DeleteUserCertificateRequest{ - CertId: resource.CertId, + err := a.client.PutBucketCnameWithCertificate(getDeployString(a.option.DeployConfig, "bucket"), oss.PutBucketCname{ + Cname: getDeployString(a.option.DeployConfig, "domain"), + CertificateConfiguration: &oss.CertificateConfiguration{ + Certificate: a.option.Certificate.Certificate, + PrivateKey: a.option.Certificate.PrivateKey, + Force: true, + }, }) + if err != nil { - return err + return fmt.Errorf("deploy aliyun oss error: %w", err) } + return nil + } -func (a *aliyun) contacts() ([]*cas20200407.ListContactResponseBodyContactList, error) { - listContactRequest := &cas20200407.ListContactRequest{} - runtime := &util.RuntimeOptions{} - - resp, err := a.client.ListContactWithOptions(listContactRequest, runtime) +func (a *aliyun) createClient(accessKeyId, accessKeySecret string) (*oss.Client, error) { + client, err := oss.New( + getDeployString(a.option.DeployConfig, "endpoint"), + accessKeyId, + accessKeySecret, + ) if err != nil { - return nil, err + return nil, fmt.Errorf("create aliyun client error: %w", err) } - if resp.Body.TotalCount == nil { - return nil, errors.New("no contact found") - } - - return resp.Body.ContactList, nil -} - -func (a *aliyun) deploy(resource *cas20200407.ListCloudResourcesResponseBodyData, certId int64, contacts []*cas20200407.ListContactResponseBodyContactList) (*int64, error) { - contactIds := make([]string, 0, len(contacts)) - for _, contact := range contacts { - contactIds = append(contactIds, fmt.Sprintf("%d", *contact.ContactId)) - } - // 部署证书 - createCloudResourceRequest := &cas20200407.CreateDeploymentJobRequest{ - CertIds: tea.String(fmt.Sprintf("%d", certId)), - Name: tea.String(a.option.Domain + rand.RandStr(6)), - JobType: tea.String("user"), - ResourceIds: tea.String(fmt.Sprintf("%d", *resource.Id)), - ContactIds: tea.String(strings.Join(contactIds, ",")), - } - runtime := &util.RuntimeOptions{} - - resp, err := a.client.CreateDeploymentJobWithOptions(createCloudResourceRequest, runtime) - if err != nil { - return nil, err - } - return resp.Body.JobId, nil -} - -func (a *aliyun) uploadCert(cert *applicant.Certificate) (int64, error) { - uploadUserCertificateRequest := &cas20200407.UploadUserCertificateRequest{ - Cert: &cert.Certificate, - Key: &cert.PrivateKey, - Name: tea.String(a.option.Domain + rand.RandStr(6)), - } - runtime := &util.RuntimeOptions{} - - resp, err := a.client.UploadUserCertificateWithOptions(uploadUserCertificateRequest, runtime) - if err != nil { - return 0, err - } - - return *resp.Body.CertId, nil -} - -func (a *aliyun) createClient(accessKeyId, accessKeySecret string) (_result *cas20200407.Client, _err error) { - config := &openapi.Config{ - AccessKeyId: tea.String(accessKeyId), - AccessKeySecret: tea.String(accessKeySecret), - } - config.Endpoint = tea.String("cas.aliyuncs.com") - _result = &cas20200407.Client{} - _result, _err = cas20200407.NewClient(config) - return _result, _err -} - -func (a *aliyun) resource() (*cas20200407.ListCloudResourcesResponseBodyData, error) { - - listCloudResourcesRequest := &cas20200407.ListCloudResourcesRequest{ - CloudProduct: tea.String(a.option.Product), - Keyword: tea.String(getDeployString(a.option.DeployConfig, "domain")), - } - - resp, err := a.client.ListCloudResources(listCloudResourcesRequest) - if err != nil { - return nil, err - } - - if *resp.Body.Total == 0 { - return nil, errors.New("no resource found") - } - - return resp.Body.Data[0], nil + return client, nil } diff --git a/ui/dist/assets/index-DbwFzZm1.js b/ui/dist/assets/index-DvxNVikK.js similarity index 72% rename from ui/dist/assets/index-DbwFzZm1.js rename to ui/dist/assets/index-DvxNVikK.js index b4503f7f..0159b396 100644 --- a/ui/dist/assets/index-DbwFzZm1.js +++ b/ui/dist/assets/index-DvxNVikK.js @@ -1,4 +1,4 @@ -var vP=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var eY=vP((pY,Td)=>{function yb(e,t){for(var n=0;nr[s]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const s of document.querySelectorAll('link[rel="modulepreload"]'))r(s);new MutationObserver(s=>{for(const i of s)if(i.type==="childList")for(const o of i.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&r(o)}).observe(document,{childList:!0,subtree:!0});function n(s){const i={};return s.integrity&&(i.integrity=s.integrity),s.referrerPolicy&&(i.referrerPolicy=s.referrerPolicy),s.crossOrigin==="use-credentials"?i.credentials="include":s.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function r(s){if(s.ep)return;s.ep=!0;const i=n(s);fetch(s.href,i)}})();var ju=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Bf(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var vb={exports:{}},Wf={},xb={exports:{}},nt={};/** +var vP=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var tY=vP((mY,Nd)=>{function yb(e,t){for(var n=0;nr[s]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const s of document.querySelectorAll('link[rel="modulepreload"]'))r(s);new MutationObserver(s=>{for(const i of s)if(i.type==="childList")for(const o of i.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&r(o)}).observe(document,{childList:!0,subtree:!0});function n(s){const i={};return s.integrity&&(i.integrity=s.integrity),s.referrerPolicy&&(i.referrerPolicy=s.referrerPolicy),s.crossOrigin==="use-credentials"?i.credentials="include":s.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function r(s){if(s.ep)return;s.ep=!0;const i=n(s);fetch(s.href,i)}})();var ju=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Vf(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var vb={exports:{}},Bf={},xb={exports:{}},nt={};/** * @license React * react.production.min.js * @@ -6,7 +6,7 @@ var vP=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var eY=vP((pY,Td) * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var Zc=Symbol.for("react.element"),xP=Symbol.for("react.portal"),wP=Symbol.for("react.fragment"),bP=Symbol.for("react.strict_mode"),_P=Symbol.for("react.profiler"),SP=Symbol.for("react.provider"),kP=Symbol.for("react.context"),CP=Symbol.for("react.forward_ref"),jP=Symbol.for("react.suspense"),EP=Symbol.for("react.memo"),NP=Symbol.for("react.lazy"),c0=Symbol.iterator;function TP(e){return e===null||typeof e!="object"?null:(e=c0&&e[c0]||e["@@iterator"],typeof e=="function"?e:null)}var wb={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},bb=Object.assign,_b={};function Ya(e,t,n){this.props=e,this.context=t,this.refs=_b,this.updater=n||wb}Ya.prototype.isReactComponent={};Ya.prototype.setState=function(e,t){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,t,"setState")};Ya.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function Sb(){}Sb.prototype=Ya.prototype;function sy(e,t,n){this.props=e,this.context=t,this.refs=_b,this.updater=n||wb}var iy=sy.prototype=new Sb;iy.constructor=sy;bb(iy,Ya.prototype);iy.isPureReactComponent=!0;var u0=Array.isArray,kb=Object.prototype.hasOwnProperty,oy={current:null},Cb={key:!0,ref:!0,__self:!0,__source:!0};function jb(e,t,n){var r,s={},i=null,o=null;if(t!=null)for(r in t.ref!==void 0&&(o=t.ref),t.key!==void 0&&(i=""+t.key),t)kb.call(t,r)&&!Cb.hasOwnProperty(r)&&(s[r]=t[r]);var a=arguments.length-2;if(a===1)s.children=n;else if(1()=>(t||e((t={exports:{}}).exports,t),t.exports);var eY=vP((pY,Td) * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var DP=g,IP=Symbol.for("react.element"),MP=Symbol.for("react.fragment"),LP=Object.prototype.hasOwnProperty,FP=DP.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,zP={key:!0,ref:!0,__self:!0,__source:!0};function Tb(e,t,n){var r,s={},i=null,o=null;n!==void 0&&(i=""+n),t.key!==void 0&&(i=""+t.key),t.ref!==void 0&&(o=t.ref);for(r in t)LP.call(t,r)&&!zP.hasOwnProperty(r)&&(s[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps,t)s[r]===void 0&&(s[r]=t[r]);return{$$typeof:IP,type:e,key:i,ref:o,props:s,_owner:FP.current}}Wf.Fragment=MP;Wf.jsx=Tb;Wf.jsxs=Tb;vb.exports=Wf;var l=vb.exports,vm={},Pb={exports:{}},Qn={},Rb={exports:{}},Ab={};/** + */var DP=g,IP=Symbol.for("react.element"),MP=Symbol.for("react.fragment"),LP=Object.prototype.hasOwnProperty,FP=DP.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,zP={key:!0,ref:!0,__self:!0,__source:!0};function Tb(e,t,n){var r,s={},i=null,o=null;n!==void 0&&(i=""+n),t.key!==void 0&&(i=""+t.key),t.ref!==void 0&&(o=t.ref);for(r in t)LP.call(t,r)&&!zP.hasOwnProperty(r)&&(s[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps,t)s[r]===void 0&&(s[r]=t[r]);return{$$typeof:IP,type:e,key:i,ref:o,props:s,_owner:FP.current}}Bf.Fragment=MP;Bf.jsx=Tb;Bf.jsxs=Tb;vb.exports=Bf;var l=vb.exports,vm={},Pb={exports:{}},Qn={},Rb={exports:{}},Ab={};/** * @license React * scheduler.production.min.js * @@ -30,14 +30,14 @@ var vP=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var eY=vP((pY,Td) * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var UP=g,Gn=$P;function oe(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"),xm=Object.prototype.hasOwnProperty,VP=/^[: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]*$/,f0={},h0={};function BP(e){return xm.call(h0,e)?!0:xm.call(f0,e)?!1:VP.test(e)?h0[e]=!0:(f0[e]=!0,!1)}function WP(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 HP(e,t,n,r){if(t===null||typeof t>"u"||WP(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 En(e,t,n,r,s,i,o){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=s,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=i,this.removeEmptyString=o}var on={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){on[e]=new En(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];on[t]=new En(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){on[e]=new En(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){on[e]=new En(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){on[e]=new En(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){on[e]=new En(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){on[e]=new En(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){on[e]=new En(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){on[e]=new En(e,5,!1,e.toLowerCase(),null,!1,!1)});var ly=/[\-:]([a-z])/g;function cy(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(ly,cy);on[t]=new En(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(ly,cy);on[t]=new En(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(ly,cy);on[t]=new En(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){on[e]=new En(e,1,!1,e.toLowerCase(),null,!1,!1)});on.xlinkHref=new En("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){on[e]=new En(e,1,!1,e.toLowerCase(),null,!0,!0)});function uy(e,t,n,r){var s=on.hasOwnProperty(t)?on[t]:null;(s!==null?s.type!==0:r||!(2"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),xm=Object.prototype.hasOwnProperty,VP=/^[: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]*$/,f0={},h0={};function BP(e){return xm.call(h0,e)?!0:xm.call(f0,e)?!1:VP.test(e)?h0[e]=!0:(f0[e]=!0,!1)}function WP(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 HP(e,t,n,r){if(t===null||typeof t>"u"||WP(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 En(e,t,n,r,s,i,o){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=s,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=i,this.removeEmptyString=o}var on={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){on[e]=new En(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];on[t]=new En(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){on[e]=new En(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){on[e]=new En(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){on[e]=new En(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){on[e]=new En(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){on[e]=new En(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){on[e]=new En(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){on[e]=new En(e,5,!1,e.toLowerCase(),null,!1,!1)});var ly=/[\-:]([a-z])/g;function cy(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(ly,cy);on[t]=new En(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(ly,cy);on[t]=new En(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(ly,cy);on[t]=new En(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){on[e]=new En(e,1,!1,e.toLowerCase(),null,!1,!1)});on.xlinkHref=new En("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){on[e]=new En(e,1,!1,e.toLowerCase(),null,!0,!0)});function uy(e,t,n,r){var s=on.hasOwnProperty(t)?on[t]:null;(s!==null?s.type!==0:r||!(2a||s[o]!==i[a]){var c=` -`+s[o].replace(" at new "," at ");return e.displayName&&c.includes("")&&(c=c.replace("",e.displayName)),c}while(1<=o&&0<=a);break}}}finally{gp=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?Pl(e):""}function YP(e){switch(e.tag){case 5:return Pl(e.type);case 16:return Pl("Lazy");case 13:return Pl("Suspense");case 19:return Pl("SuspenseList");case 0:case 2:case 15:return e=yp(e.type,!1),e;case 11:return e=yp(e.type.render,!1),e;case 1:return e=yp(e.type,!0),e;default:return""}}function Sm(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 Zo:return"Fragment";case Go:return"Portal";case wm:return"Profiler";case dy:return"StrictMode";case bm:return"Suspense";case _m:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Ib:return(e.displayName||"Context")+".Consumer";case Db:return(e._context.displayName||"Context")+".Provider";case fy:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case hy:return t=e.displayName||null,t!==null?t:Sm(e.type)||"Memo";case ri:t=e._payload,e=e._init;try{return Sm(e(t))}catch{}}return null}function KP(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 Sm(t);case 8:return t===dy?"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 _i(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Lb(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function GP(e){var t=Lb(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 s=n.get,i=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return s.call(this)},set:function(o){r=""+o,i.call(this,o)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(o){r=""+o},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Tu(e){e._valueTracker||(e._valueTracker=GP(e))}function Fb(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=Lb(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function Pd(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 km(e,t){var n=t.checked;return Lt({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function m0(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=_i(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 zb(e,t){t=t.checked,t!=null&&uy(e,"checked",t,!1)}function Cm(e,t){zb(e,t);var n=_i(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")?jm(e,t.type,n):t.hasOwnProperty("defaultValue")&&jm(e,t.type,_i(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function g0(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 jm(e,t,n){(t!=="number"||Pd(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var Rl=Array.isArray;function ha(e,t,n,r){if(e=e.options,t){t={};for(var s=0;s"+t.valueOf().toString()+"",t=Pu.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function rc(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Vl={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},ZP=["Webkit","ms","Moz","O"];Object.keys(Vl).forEach(function(e){ZP.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Vl[t]=Vl[e]})});function Bb(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||Vl.hasOwnProperty(e)&&Vl[e]?(""+t).trim():t+"px"}function Wb(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,s=Bb(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,s):e[n]=s}}var qP=Lt({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 Tm(e,t){if(t){if(qP[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(oe(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(oe(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(oe(61))}if(t.style!=null&&typeof t.style!="object")throw Error(oe(62))}}function Pm(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 Rm=null;function py(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Am=null,pa=null,ma=null;function x0(e){if(e=Qc(e)){if(typeof Am!="function")throw Error(oe(280));var t=e.stateNode;t&&(t=Zf(t),Am(e.stateNode,e.type,t))}}function Hb(e){pa?ma?ma.push(e):ma=[e]:pa=e}function Yb(){if(pa){var e=pa,t=ma;if(ma=pa=null,x0(e),t)for(e=0;e>>=0,e===0?32:31-(aR(e)/lR|0)|0}var Ru=64,Au=4194304;function Al(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 Dd(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,s=e.suspendedLanes,i=e.pingedLanes,o=n&268435455;if(o!==0){var a=o&~s;a!==0?r=Al(a):(i&=o,i!==0&&(r=Al(i)))}else o=n&~s,o!==0?r=Al(o):i!==0&&(r=Al(i));if(r===0)return 0;if(t!==0&&t!==r&&!(t&s)&&(s=r&-r,i=t&-t,s>=i||s===16&&(i&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 qc(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-Er(t),e[t]=n}function fR(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=Wl),N0=" ",T0=!1;function f_(e,t){switch(e){case"keyup":return $R.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function h_(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var qo=!1;function VR(e,t){switch(e){case"compositionend":return h_(t);case"keypress":return t.which!==32?null:(T0=!0,N0);case"textInput":return e=t.data,e===N0&&T0?null:e;default:return null}}function BR(e,t){if(qo)return e==="compositionend"||!_y&&f_(e,t)?(e=u_(),cd=xy=li=null,qo=!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=O0(n)}}function y_(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?y_(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function v_(){for(var e=window,t=Pd();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=Pd(e.document)}return t}function Sy(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 QR(e){var t=v_(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&y_(n.ownerDocument.documentElement,n)){if(r!==null&&Sy(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 s=n.textContent.length,i=Math.min(r.start,s);r=r.end===void 0?i:Math.min(r.end,s),!e.extend&&i>r&&(s=r,r=i,i=s),s=D0(n,i);var o=D0(n,r);s&&o&&(e.rangeCount!==1||e.anchorNode!==s.node||e.anchorOffset!==s.offset||e.focusNode!==o.node||e.focusOffset!==o.offset)&&(t=t.createRange(),t.setStart(s.node,s.offset),e.removeAllRanges(),i>r?(e.addRange(t),e.extend(o.node,o.offset)):(t.setEnd(o.node,o.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,Xo=null,Fm=null,Yl=null,zm=!1;function I0(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;zm||Xo==null||Xo!==Pd(r)||(r=Xo,"selectionStart"in r&&Sy(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}),Yl&&cc(Yl,r)||(Yl=r,r=Ld(Fm,"onSelect"),0ea||(e.current=Hm[ea],Hm[ea]=null,ea--)}function bt(e,t){ea++,Hm[ea]=e.current,e.current=t}var Si={},yn=Oi(Si),On=Oi(!1),so=Si;function Na(e,t){var n=e.type.contextTypes;if(!n)return Si;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var s={},i;for(i in n)s[i]=t[i];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=s),s}function Dn(e){return e=e.childContextTypes,e!=null}function zd(){kt(On),kt(yn)}function V0(e,t,n){if(yn.current!==Si)throw Error(oe(168));bt(yn,t),bt(On,n)}function E_(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var s in r)if(!(s in t))throw Error(oe(108,KP(e)||"Unknown",s));return Lt({},n,r)}function $d(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Si,so=yn.current,bt(yn,e),bt(On,On.current),!0}function B0(e,t,n){var r=e.stateNode;if(!r)throw Error(oe(169));n?(e=E_(e,t,so),r.__reactInternalMemoizedMergedChildContext=e,kt(On),kt(yn),bt(yn,e)):kt(On),bt(On,n)}var _s=null,qf=!1,Rp=!1;function N_(e){_s===null?_s=[e]:_s.push(e)}function uA(e){qf=!0,N_(e)}function Di(){if(!Rp&&_s!==null){Rp=!0;var e=0,t=gt;try{var n=_s;for(gt=1;e>=o,s-=o,Ss=1<<32-Er(t)+s|n<R?(A=T,T=null):A=T.sibling;var D=h(y,T,b[R],_);if(D===null){T===null&&(T=A);break}e&&T&&D.alternate===null&&t(y,T),v=i(D,v,R),j===null?C=D:j.sibling=D,j=D,T=A}if(R===b.length)return n(y,T),Pt&&zi(y,R),C;if(T===null){for(;RR?(A=T,T=null):A=T.sibling;var G=h(y,T,D.value,_);if(G===null){T===null&&(T=A);break}e&&T&&G.alternate===null&&t(y,T),v=i(G,v,R),j===null?C=G:j.sibling=G,j=G,T=A}if(D.done)return n(y,T),Pt&&zi(y,R),C;if(T===null){for(;!D.done;R++,D=b.next())D=f(y,D.value,_),D!==null&&(v=i(D,v,R),j===null?C=D:j.sibling=D,j=D);return Pt&&zi(y,R),C}for(T=r(y,T);!D.done;R++,D=b.next())D=p(T,y,R,D.value,_),D!==null&&(e&&D.alternate!==null&&T.delete(D.key===null?R:D.key),v=i(D,v,R),j===null?C=D:j.sibling=D,j=D);return e&&T.forEach(function(N){return t(y,N)}),Pt&&zi(y,R),C}function w(y,v,b,_){if(typeof b=="object"&&b!==null&&b.type===Zo&&b.key===null&&(b=b.props.children),typeof b=="object"&&b!==null){switch(b.$$typeof){case Nu:e:{for(var C=b.key,j=v;j!==null;){if(j.key===C){if(C=b.type,C===Zo){if(j.tag===7){n(y,j.sibling),v=s(j,b.props.children),v.return=y,y=v;break e}}else if(j.elementType===C||typeof C=="object"&&C!==null&&C.$$typeof===ri&&Y0(C)===j.type){n(y,j.sibling),v=s(j,b.props),v.ref=gl(y,j,b),v.return=y,y=v;break e}n(y,j);break}else t(y,j);j=j.sibling}b.type===Zo?(v=eo(b.props.children,y.mode,_,b.key),v.return=y,y=v):(_=yd(b.type,b.key,b.props,null,y.mode,_),_.ref=gl(y,v,b),_.return=y,y=_)}return o(y);case Go:e:{for(j=b.key;v!==null;){if(v.key===j)if(v.tag===4&&v.stateNode.containerInfo===b.containerInfo&&v.stateNode.implementation===b.implementation){n(y,v.sibling),v=s(v,b.children||[]),v.return=y,y=v;break e}else{n(y,v);break}else t(y,v);v=v.sibling}v=zp(b,y.mode,_),v.return=y,y=v}return o(y);case ri:return j=b._init,w(y,v,j(b._payload),_)}if(Rl(b))return x(y,v,b,_);if(dl(b))return m(y,v,b,_);zu(y,b)}return typeof b=="string"&&b!==""||typeof b=="number"?(b=""+b,v!==null&&v.tag===6?(n(y,v.sibling),v=s(v,b),v.return=y,y=v):(n(y,v),v=Fp(b,y.mode,_),v.return=y,y=v),o(y)):n(y,v)}return w}var Pa=A_(!0),O_=A_(!1),Bd=Oi(null),Wd=null,ra=null,Ey=null;function Ny(){Ey=ra=Wd=null}function Ty(e){var t=Bd.current;kt(Bd),e._currentValue=t}function Gm(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 ya(e,t){Wd=e,Ey=ra=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(An=!0),e.firstContext=null)}function fr(e){var t=e._currentValue;if(Ey!==e)if(e={context:e,memoizedValue:t,next:null},ra===null){if(Wd===null)throw Error(oe(308));ra=e,Wd.dependencies={lanes:0,firstContext:e}}else ra=ra.next=e;return t}var Wi=null;function Py(e){Wi===null?Wi=[e]:Wi.push(e)}function D_(e,t,n,r){var s=t.interleaved;return s===null?(n.next=n,Py(t)):(n.next=s.next,s.next=n),t.interleaved=n,Ds(e,r)}function Ds(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 si=!1;function Ry(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function I_(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 Es(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function yi(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,ct&2){var s=r.pending;return s===null?t.next=t:(t.next=s.next,s.next=t),r.pending=t,Ds(e,n)}return s=r.interleaved,s===null?(t.next=t,Py(r)):(t.next=s.next,s.next=t),r.interleaved=t,Ds(e,n)}function dd(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,gy(e,n)}}function K0(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var s=null,i=null;if(n=n.firstBaseUpdate,n!==null){do{var o={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};i===null?s=i=o:i=i.next=o,n=n.next}while(n!==null);i===null?s=i=t:i=i.next=t}else s=i=t;n={baseState:r.baseState,firstBaseUpdate:s,lastBaseUpdate:i,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 Hd(e,t,n,r){var s=e.updateQueue;si=!1;var i=s.firstBaseUpdate,o=s.lastBaseUpdate,a=s.shared.pending;if(a!==null){s.shared.pending=null;var c=a,u=c.next;c.next=null,o===null?i=u:o.next=u,o=c;var d=e.alternate;d!==null&&(d=d.updateQueue,a=d.lastBaseUpdate,a!==o&&(a===null?d.firstBaseUpdate=u:a.next=u,d.lastBaseUpdate=c))}if(i!==null){var f=s.baseState;o=0,d=u=c=null,a=i;do{var h=a.lane,p=a.eventTime;if((r&h)===h){d!==null&&(d=d.next={eventTime:p,lane:0,tag:a.tag,payload:a.payload,callback:a.callback,next:null});e:{var x=e,m=a;switch(h=t,p=n,m.tag){case 1:if(x=m.payload,typeof x=="function"){f=x.call(p,f,h);break e}f=x;break e;case 3:x.flags=x.flags&-65537|128;case 0:if(x=m.payload,h=typeof x=="function"?x.call(p,f,h):x,h==null)break e;f=Lt({},f,h);break e;case 2:si=!0}}a.callback!==null&&a.lane!==0&&(e.flags|=64,h=s.effects,h===null?s.effects=[a]:h.push(a))}else p={eventTime:p,lane:h,tag:a.tag,payload:a.payload,callback:a.callback,next:null},d===null?(u=d=p,c=f):d=d.next=p,o|=h;if(a=a.next,a===null){if(a=s.shared.pending,a===null)break;h=a,a=h.next,h.next=null,s.lastBaseUpdate=h,s.shared.pending=null}}while(!0);if(d===null&&(c=f),s.baseState=c,s.firstBaseUpdate=u,s.lastBaseUpdate=d,t=s.shared.interleaved,t!==null){s=t;do o|=s.lane,s=s.next;while(s!==t)}else i===null&&(s.shared.lanes=0);ao|=o,e.lanes=o,e.memoizedState=f}}function G0(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;tn?n:4,e(!0);var r=Op.transition;Op.transition={};try{e(!1),t()}finally{gt=n,Op.transition=r}}function Q_(){return hr().memoizedState}function pA(e,t,n){var r=xi(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},J_(e))eS(t,n);else if(n=D_(e,t,n,r),n!==null){var s=kn();Nr(n,e,r,s),tS(n,t,r)}}function mA(e,t,n){var r=xi(e),s={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(J_(e))eS(t,s);else{var i=e.alternate;if(e.lanes===0&&(i===null||i.lanes===0)&&(i=t.lastRenderedReducer,i!==null))try{var o=t.lastRenderedState,a=i(o,n);if(s.hasEagerState=!0,s.eagerState=a,Pr(a,o)){var c=t.interleaved;c===null?(s.next=s,Py(t)):(s.next=c.next,c.next=s),t.interleaved=s;return}}catch{}finally{}n=D_(e,t,s,r),n!==null&&(s=kn(),Nr(n,e,r,s),tS(n,t,r))}}function J_(e){var t=e.alternate;return e===Mt||t!==null&&t===Mt}function eS(e,t){Kl=Kd=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function tS(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,gy(e,n)}}var Gd={readContext:fr,useCallback:hn,useContext:hn,useEffect:hn,useImperativeHandle:hn,useInsertionEffect:hn,useLayoutEffect:hn,useMemo:hn,useReducer:hn,useRef:hn,useState:hn,useDebugValue:hn,useDeferredValue:hn,useTransition:hn,useMutableSource:hn,useSyncExternalStore:hn,useId:hn,unstable_isNewReconciler:!1},gA={readContext:fr,useCallback:function(e,t){return Br().memoizedState=[e,t===void 0?null:t],e},useContext:fr,useEffect:q0,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,hd(4194308,4,K_.bind(null,t,e),n)},useLayoutEffect:function(e,t){return hd(4194308,4,e,t)},useInsertionEffect:function(e,t){return hd(4,2,e,t)},useMemo:function(e,t){var n=Br();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=Br();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=pA.bind(null,Mt,e),[r.memoizedState,e]},useRef:function(e){var t=Br();return e={current:e},t.memoizedState=e},useState:Z0,useDebugValue:zy,useDeferredValue:function(e){return Br().memoizedState=e},useTransition:function(){var e=Z0(!1),t=e[0];return e=hA.bind(null,e[1]),Br().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=Mt,s=Br();if(Pt){if(n===void 0)throw Error(oe(407));n=n()}else{if(n=t(),en===null)throw Error(oe(349));oo&30||z_(r,t,n)}s.memoizedState=n;var i={value:n,getSnapshot:t};return s.queue=i,q0(U_.bind(null,r,i,e),[e]),r.flags|=2048,yc(9,$_.bind(null,r,i,n,t),void 0,null),n},useId:function(){var e=Br(),t=en.identifierPrefix;if(Pt){var n=ks,r=Ss;n=(r&~(1<<32-Er(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=mc++,0")&&(c=c.replace("",e.displayName)),c}while(1<=o&&0<=a);break}}}finally{mp=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?Rl(e):""}function YP(e){switch(e.tag){case 5:return Rl(e.type);case 16:return Rl("Lazy");case 13:return Rl("Suspense");case 19:return Rl("SuspenseList");case 0:case 2:case 15:return e=gp(e.type,!1),e;case 11:return e=gp(e.type.render,!1),e;case 1:return e=gp(e.type,!0),e;default:return""}}function Sm(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 Zo:return"Fragment";case Go:return"Portal";case wm:return"Profiler";case dy:return"StrictMode";case bm:return"Suspense";case _m:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Ib:return(e.displayName||"Context")+".Consumer";case Db:return(e._context.displayName||"Context")+".Provider";case fy:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case hy:return t=e.displayName||null,t!==null?t:Sm(e.type)||"Memo";case si:t=e._payload,e=e._init;try{return Sm(e(t))}catch{}}return null}function KP(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 Sm(t);case 8:return t===dy?"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 Si(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Lb(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function GP(e){var t=Lb(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 s=n.get,i=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return s.call(this)},set:function(o){r=""+o,i.call(this,o)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(o){r=""+o},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Tu(e){e._valueTracker||(e._valueTracker=GP(e))}function Fb(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=Lb(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function Td(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 km(e,t){var n=t.checked;return Lt({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function m0(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=Si(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 zb(e,t){t=t.checked,t!=null&&uy(e,"checked",t,!1)}function Cm(e,t){zb(e,t);var n=Si(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")?jm(e,t.type,n):t.hasOwnProperty("defaultValue")&&jm(e,t.type,Si(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function g0(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 jm(e,t,n){(t!=="number"||Td(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var Al=Array.isArray;function ha(e,t,n,r){if(e=e.options,t){t={};for(var s=0;s"+t.valueOf().toString()+"",t=Pu.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function sc(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Bl={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},ZP=["Webkit","ms","Moz","O"];Object.keys(Bl).forEach(function(e){ZP.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Bl[t]=Bl[e]})});function Bb(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||Bl.hasOwnProperty(e)&&Bl[e]?(""+t).trim():t+"px"}function Wb(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,s=Bb(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,s):e[n]=s}}var qP=Lt({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 Tm(e,t){if(t){if(qP[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(oe(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(oe(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(oe(61))}if(t.style!=null&&typeof t.style!="object")throw Error(oe(62))}}function Pm(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 Rm=null;function py(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Am=null,pa=null,ma=null;function x0(e){if(e=Qc(e)){if(typeof Am!="function")throw Error(oe(280));var t=e.stateNode;t&&(t=Gf(t),Am(e.stateNode,e.type,t))}}function Hb(e){pa?ma?ma.push(e):ma=[e]:pa=e}function Yb(){if(pa){var e=pa,t=ma;if(ma=pa=null,x0(e),t)for(e=0;e>>=0,e===0?32:31-(aR(e)/lR|0)|0}var Ru=64,Au=4194304;function Ol(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 Od(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,s=e.suspendedLanes,i=e.pingedLanes,o=n&268435455;if(o!==0){var a=o&~s;a!==0?r=Ol(a):(i&=o,i!==0&&(r=Ol(i)))}else o=n&~s,o!==0?r=Ol(o):i!==0&&(r=Ol(i));if(r===0)return 0;if(t!==0&&t!==r&&!(t&s)&&(s=r&-r,i=t&-t,s>=i||s===16&&(i&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 qc(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-Er(t),e[t]=n}function fR(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=Hl),N0=" ",T0=!1;function f_(e,t){switch(e){case"keyup":return $R.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function h_(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var qo=!1;function VR(e,t){switch(e){case"compositionend":return h_(t);case"keypress":return t.which!==32?null:(T0=!0,N0);case"textInput":return e=t.data,e===N0&&T0?null:e;default:return null}}function BR(e,t){if(qo)return e==="compositionend"||!_y&&f_(e,t)?(e=u_(),ld=xy=ci=null,qo=!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=O0(n)}}function y_(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?y_(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function v_(){for(var e=window,t=Td();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=Td(e.document)}return t}function Sy(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 QR(e){var t=v_(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&y_(n.ownerDocument.documentElement,n)){if(r!==null&&Sy(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 s=n.textContent.length,i=Math.min(r.start,s);r=r.end===void 0?i:Math.min(r.end,s),!e.extend&&i>r&&(s=r,r=i,i=s),s=D0(n,i);var o=D0(n,r);s&&o&&(e.rangeCount!==1||e.anchorNode!==s.node||e.anchorOffset!==s.offset||e.focusNode!==o.node||e.focusOffset!==o.offset)&&(t=t.createRange(),t.setStart(s.node,s.offset),e.removeAllRanges(),i>r?(e.addRange(t),e.extend(o.node,o.offset)):(t.setEnd(o.node,o.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,Xo=null,Fm=null,Kl=null,zm=!1;function I0(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;zm||Xo==null||Xo!==Td(r)||(r=Xo,"selectionStart"in r&&Sy(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}),Kl&&uc(Kl,r)||(Kl=r,r=Md(Fm,"onSelect"),0ea||(e.current=Hm[ea],Hm[ea]=null,ea--)}function bt(e,t){ea++,Hm[ea]=e.current,e.current=t}var ki={},yn=Di(ki),On=Di(!1),so=ki;function Na(e,t){var n=e.type.contextTypes;if(!n)return ki;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var s={},i;for(i in n)s[i]=t[i];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=s),s}function Dn(e){return e=e.childContextTypes,e!=null}function Fd(){kt(On),kt(yn)}function V0(e,t,n){if(yn.current!==ki)throw Error(oe(168));bt(yn,t),bt(On,n)}function E_(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var s in r)if(!(s in t))throw Error(oe(108,KP(e)||"Unknown",s));return Lt({},n,r)}function zd(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||ki,so=yn.current,bt(yn,e),bt(On,On.current),!0}function B0(e,t,n){var r=e.stateNode;if(!r)throw Error(oe(169));n?(e=E_(e,t,so),r.__reactInternalMemoizedMergedChildContext=e,kt(On),kt(yn),bt(yn,e)):kt(On),bt(On,n)}var Ss=null,Zf=!1,Pp=!1;function N_(e){Ss===null?Ss=[e]:Ss.push(e)}function uA(e){Zf=!0,N_(e)}function Ii(){if(!Pp&&Ss!==null){Pp=!0;var e=0,t=gt;try{var n=Ss;for(gt=1;e>=o,s-=o,ks=1<<32-Er(t)+s|n<R?(A=T,T=null):A=T.sibling;var D=h(y,T,b[R],_);if(D===null){T===null&&(T=A);break}e&&T&&D.alternate===null&&t(y,T),v=i(D,v,R),j===null?C=D:j.sibling=D,j=D,T=A}if(R===b.length)return n(y,T),Pt&&$i(y,R),C;if(T===null){for(;RR?(A=T,T=null):A=T.sibling;var G=h(y,T,D.value,_);if(G===null){T===null&&(T=A);break}e&&T&&G.alternate===null&&t(y,T),v=i(G,v,R),j===null?C=G:j.sibling=G,j=G,T=A}if(D.done)return n(y,T),Pt&&$i(y,R),C;if(T===null){for(;!D.done;R++,D=b.next())D=f(y,D.value,_),D!==null&&(v=i(D,v,R),j===null?C=D:j.sibling=D,j=D);return Pt&&$i(y,R),C}for(T=r(y,T);!D.done;R++,D=b.next())D=p(T,y,R,D.value,_),D!==null&&(e&&D.alternate!==null&&T.delete(D.key===null?R:D.key),v=i(D,v,R),j===null?C=D:j.sibling=D,j=D);return e&&T.forEach(function(N){return t(y,N)}),Pt&&$i(y,R),C}function w(y,v,b,_){if(typeof b=="object"&&b!==null&&b.type===Zo&&b.key===null&&(b=b.props.children),typeof b=="object"&&b!==null){switch(b.$$typeof){case Nu:e:{for(var C=b.key,j=v;j!==null;){if(j.key===C){if(C=b.type,C===Zo){if(j.tag===7){n(y,j.sibling),v=s(j,b.props.children),v.return=y,y=v;break e}}else if(j.elementType===C||typeof C=="object"&&C!==null&&C.$$typeof===si&&Y0(C)===j.type){n(y,j.sibling),v=s(j,b.props),v.ref=yl(y,j,b),v.return=y,y=v;break e}n(y,j);break}else t(y,j);j=j.sibling}b.type===Zo?(v=eo(b.props.children,y.mode,_,b.key),v.return=y,y=v):(_=gd(b.type,b.key,b.props,null,y.mode,_),_.ref=yl(y,v,b),_.return=y,y=_)}return o(y);case Go:e:{for(j=b.key;v!==null;){if(v.key===j)if(v.tag===4&&v.stateNode.containerInfo===b.containerInfo&&v.stateNode.implementation===b.implementation){n(y,v.sibling),v=s(v,b.children||[]),v.return=y,y=v;break e}else{n(y,v);break}else t(y,v);v=v.sibling}v=Fp(b,y.mode,_),v.return=y,y=v}return o(y);case si:return j=b._init,w(y,v,j(b._payload),_)}if(Al(b))return x(y,v,b,_);if(fl(b))return m(y,v,b,_);zu(y,b)}return typeof b=="string"&&b!==""||typeof b=="number"?(b=""+b,v!==null&&v.tag===6?(n(y,v.sibling),v=s(v,b),v.return=y,y=v):(n(y,v),v=Lp(b,y.mode,_),v.return=y,y=v),o(y)):n(y,v)}return w}var Pa=A_(!0),O_=A_(!1),Vd=Di(null),Bd=null,ra=null,Ey=null;function Ny(){Ey=ra=Bd=null}function Ty(e){var t=Vd.current;kt(Vd),e._currentValue=t}function Gm(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 ya(e,t){Bd=e,Ey=ra=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(An=!0),e.firstContext=null)}function fr(e){var t=e._currentValue;if(Ey!==e)if(e={context:e,memoizedValue:t,next:null},ra===null){if(Bd===null)throw Error(oe(308));ra=e,Bd.dependencies={lanes:0,firstContext:e}}else ra=ra.next=e;return t}var Hi=null;function Py(e){Hi===null?Hi=[e]:Hi.push(e)}function D_(e,t,n,r){var s=t.interleaved;return s===null?(n.next=n,Py(t)):(n.next=s.next,s.next=n),t.interleaved=n,Is(e,r)}function Is(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 ii=!1;function Ry(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function I_(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 Ns(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function vi(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,ct&2){var s=r.pending;return s===null?t.next=t:(t.next=s.next,s.next=t),r.pending=t,Is(e,n)}return s=r.interleaved,s===null?(t.next=t,Py(r)):(t.next=s.next,s.next=t),r.interleaved=t,Is(e,n)}function ud(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,gy(e,n)}}function K0(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var s=null,i=null;if(n=n.firstBaseUpdate,n!==null){do{var o={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};i===null?s=i=o:i=i.next=o,n=n.next}while(n!==null);i===null?s=i=t:i=i.next=t}else s=i=t;n={baseState:r.baseState,firstBaseUpdate:s,lastBaseUpdate:i,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 Wd(e,t,n,r){var s=e.updateQueue;ii=!1;var i=s.firstBaseUpdate,o=s.lastBaseUpdate,a=s.shared.pending;if(a!==null){s.shared.pending=null;var c=a,u=c.next;c.next=null,o===null?i=u:o.next=u,o=c;var d=e.alternate;d!==null&&(d=d.updateQueue,a=d.lastBaseUpdate,a!==o&&(a===null?d.firstBaseUpdate=u:a.next=u,d.lastBaseUpdate=c))}if(i!==null){var f=s.baseState;o=0,d=u=c=null,a=i;do{var h=a.lane,p=a.eventTime;if((r&h)===h){d!==null&&(d=d.next={eventTime:p,lane:0,tag:a.tag,payload:a.payload,callback:a.callback,next:null});e:{var x=e,m=a;switch(h=t,p=n,m.tag){case 1:if(x=m.payload,typeof x=="function"){f=x.call(p,f,h);break e}f=x;break e;case 3:x.flags=x.flags&-65537|128;case 0:if(x=m.payload,h=typeof x=="function"?x.call(p,f,h):x,h==null)break e;f=Lt({},f,h);break e;case 2:ii=!0}}a.callback!==null&&a.lane!==0&&(e.flags|=64,h=s.effects,h===null?s.effects=[a]:h.push(a))}else p={eventTime:p,lane:h,tag:a.tag,payload:a.payload,callback:a.callback,next:null},d===null?(u=d=p,c=f):d=d.next=p,o|=h;if(a=a.next,a===null){if(a=s.shared.pending,a===null)break;h=a,a=h.next,h.next=null,s.lastBaseUpdate=h,s.shared.pending=null}}while(!0);if(d===null&&(c=f),s.baseState=c,s.firstBaseUpdate=u,s.lastBaseUpdate=d,t=s.shared.interleaved,t!==null){s=t;do o|=s.lane,s=s.next;while(s!==t)}else i===null&&(s.shared.lanes=0);ao|=o,e.lanes=o,e.memoizedState=f}}function G0(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;tn?n:4,e(!0);var r=Ap.transition;Ap.transition={};try{e(!1),t()}finally{gt=n,Ap.transition=r}}function Q_(){return hr().memoizedState}function pA(e,t,n){var r=wi(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},J_(e))eS(t,n);else if(n=D_(e,t,n,r),n!==null){var s=kn();Nr(n,e,r,s),tS(n,t,r)}}function mA(e,t,n){var r=wi(e),s={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(J_(e))eS(t,s);else{var i=e.alternate;if(e.lanes===0&&(i===null||i.lanes===0)&&(i=t.lastRenderedReducer,i!==null))try{var o=t.lastRenderedState,a=i(o,n);if(s.hasEagerState=!0,s.eagerState=a,Pr(a,o)){var c=t.interleaved;c===null?(s.next=s,Py(t)):(s.next=c.next,c.next=s),t.interleaved=s;return}}catch{}finally{}n=D_(e,t,s,r),n!==null&&(s=kn(),Nr(n,e,r,s),tS(n,t,r))}}function J_(e){var t=e.alternate;return e===Mt||t!==null&&t===Mt}function eS(e,t){Gl=Yd=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function tS(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,gy(e,n)}}var Kd={readContext:fr,useCallback:hn,useContext:hn,useEffect:hn,useImperativeHandle:hn,useInsertionEffect:hn,useLayoutEffect:hn,useMemo:hn,useReducer:hn,useRef:hn,useState:hn,useDebugValue:hn,useDeferredValue:hn,useTransition:hn,useMutableSource:hn,useSyncExternalStore:hn,useId:hn,unstable_isNewReconciler:!1},gA={readContext:fr,useCallback:function(e,t){return Br().memoizedState=[e,t===void 0?null:t],e},useContext:fr,useEffect:q0,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,fd(4194308,4,K_.bind(null,t,e),n)},useLayoutEffect:function(e,t){return fd(4194308,4,e,t)},useInsertionEffect:function(e,t){return fd(4,2,e,t)},useMemo:function(e,t){var n=Br();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=Br();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=pA.bind(null,Mt,e),[r.memoizedState,e]},useRef:function(e){var t=Br();return e={current:e},t.memoizedState=e},useState:Z0,useDebugValue:zy,useDeferredValue:function(e){return Br().memoizedState=e},useTransition:function(){var e=Z0(!1),t=e[0];return e=hA.bind(null,e[1]),Br().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=Mt,s=Br();if(Pt){if(n===void 0)throw Error(oe(407));n=n()}else{if(n=t(),en===null)throw Error(oe(349));oo&30||z_(r,t,n)}s.memoizedState=n;var i={value:n,getSnapshot:t};return s.queue=i,q0(U_.bind(null,r,i,e),[e]),r.flags|=2048,vc(9,$_.bind(null,r,i,n,t),void 0,null),n},useId:function(){var e=Br(),t=en.identifierPrefix;if(Pt){var n=Cs,r=ks;n=(r&~(1<<32-Er(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=gc++,0<\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=o.createElement(n,{is:r.is}):(e=o.createElement(n),n==="select"&&(o=e,r.multiple?o.multiple=!0:r.size&&(o.size=r.size))):e=o.createElementNS(e,n),e[Wr]=t,e[fc]=r,dS(e,t,!1,!1),t.stateNode=e;e:{switch(o=Pm(n,r),n){case"dialog":St("cancel",e),St("close",e),s=r;break;case"iframe":case"object":case"embed":St("load",e),s=r;break;case"video":case"audio":for(s=0;sOa&&(t.flags|=128,r=!0,yl(i,!1),t.lanes=4194304)}else{if(!r)if(e=Yd(o),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),yl(i,!0),i.tail===null&&i.tailMode==="hidden"&&!o.alternate&&!Pt)return pn(t),null}else 2*Vt()-i.renderingStartTime>Oa&&n!==1073741824&&(t.flags|=128,r=!0,yl(i,!1),t.lanes=4194304);i.isBackwards?(o.sibling=t.child,t.child=o):(n=i.last,n!==null?n.sibling=o:t.child=o,i.last=o)}return i.tail!==null?(t=i.tail,i.rendering=t,i.tail=t.sibling,i.renderingStartTime=Vt(),t.sibling=null,n=Dt.current,bt(Dt,r?n&1|2:n&1),t):(pn(t),null);case 22:case 23:return Hy(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?zn&1073741824&&(pn(t),t.subtreeFlags&6&&(t.flags|=8192)):pn(t),null;case 24:return null;case 25:return null}throw Error(oe(156,t.tag))}function kA(e,t){switch(Cy(t),t.tag){case 1:return Dn(t.type)&&zd(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Ra(),kt(On),kt(yn),Dy(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return Oy(t),null;case 13:if(kt(Dt),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(oe(340));Ta()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return kt(Dt),null;case 4:return Ra(),null;case 10:return Ty(t.type._context),null;case 22:case 23:return Hy(),null;case 24:return null;default:return null}}var Uu=!1,mn=!1,CA=typeof WeakSet=="function"?WeakSet:Set,Ne=null;function sa(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){zt(e,t,r)}else n.current=null}function rg(e,t,n){try{n()}catch(r){zt(e,t,r)}}var aw=!1;function jA(e,t){if($m=Id,e=v_(),Sy(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 s=r.anchorOffset,i=r.focusNode;r=r.focusOffset;try{n.nodeType,i.nodeType}catch{n=null;break e}var o=0,a=-1,c=-1,u=0,d=0,f=e,h=null;t:for(;;){for(var p;f!==n||s!==0&&f.nodeType!==3||(a=o+s),f!==i||r!==0&&f.nodeType!==3||(c=o+r),f.nodeType===3&&(o+=f.nodeValue.length),(p=f.firstChild)!==null;)h=f,f=p;for(;;){if(f===e)break t;if(h===n&&++u===s&&(a=o),h===i&&++d===r&&(c=o),(p=f.nextSibling)!==null)break;f=h,h=f.parentNode}f=p}n=a===-1||c===-1?null:{start:a,end:c}}else n=null}n=n||{start:0,end:0}}else n=null;for(Um={focusedElem:e,selectionRange:n},Id=!1,Ne=t;Ne!==null;)if(t=Ne,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,Ne=e;else for(;Ne!==null;){t=Ne;try{var x=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(x!==null){var m=x.memoizedProps,w=x.memoizedState,y=t.stateNode,v=y.getSnapshotBeforeUpdate(t.elementType===t.type?m:vr(t.type,m),w);y.__reactInternalSnapshotBeforeUpdate=v}break;case 3:var b=t.stateNode.containerInfo;b.nodeType===1?b.textContent="":b.nodeType===9&&b.documentElement&&b.removeChild(b.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(oe(163))}}catch(_){zt(t,t.return,_)}if(e=t.sibling,e!==null){e.return=t.return,Ne=e;break}Ne=t.return}return x=aw,aw=!1,x}function Gl(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var s=r=r.next;do{if((s.tag&e)===e){var i=s.destroy;s.destroy=void 0,i!==void 0&&rg(t,n,i)}s=s.next}while(s!==r)}}function Jf(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 sg(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 pS(e){var t=e.alternate;t!==null&&(e.alternate=null,pS(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[Wr],delete t[fc],delete t[Wm],delete t[lA],delete t[cA])),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 mS(e){return e.tag===5||e.tag===3||e.tag===4}function lw(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||mS(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 ig(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=Fd));else if(r!==4&&(e=e.child,e!==null))for(ig(e,t,n),e=e.sibling;e!==null;)ig(e,t,n),e=e.sibling}function og(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(og(e,t,n),e=e.sibling;e!==null;)og(e,t,n),e=e.sibling}var rn=null,xr=!1;function Qs(e,t,n){for(n=n.child;n!==null;)gS(e,t,n),n=n.sibling}function gS(e,t,n){if(Xr&&typeof Xr.onCommitFiberUnmount=="function")try{Xr.onCommitFiberUnmount(Hf,n)}catch{}switch(n.tag){case 5:mn||sa(n,t);case 6:var r=rn,s=xr;rn=null,Qs(e,t,n),rn=r,xr=s,rn!==null&&(xr?(e=rn,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):rn.removeChild(n.stateNode));break;case 18:rn!==null&&(xr?(e=rn,n=n.stateNode,e.nodeType===8?Pp(e.parentNode,n):e.nodeType===1&&Pp(e,n),ac(e)):Pp(rn,n.stateNode));break;case 4:r=rn,s=xr,rn=n.stateNode.containerInfo,xr=!0,Qs(e,t,n),rn=r,xr=s;break;case 0:case 11:case 14:case 15:if(!mn&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){s=r=r.next;do{var i=s,o=i.destroy;i=i.tag,o!==void 0&&(i&2||i&4)&&rg(n,t,o),s=s.next}while(s!==r)}Qs(e,t,n);break;case 1:if(!mn&&(sa(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(a){zt(n,t,a)}Qs(e,t,n);break;case 21:Qs(e,t,n);break;case 22:n.mode&1?(mn=(r=mn)||n.memoizedState!==null,Qs(e,t,n),mn=r):Qs(e,t,n);break;default:Qs(e,t,n)}}function cw(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new CA),t.forEach(function(r){var s=IA.bind(null,e,r);n.has(r)||(n.add(r),r.then(s,s))})}}function yr(e,t){var n=t.deletions;if(n!==null)for(var r=0;rs&&(s=o),r&=~i}if(r=s,r=Vt()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*NA(r/1960))-r,10e?16:e,ci===null)var r=!1;else{if(e=ci,ci=null,Xd=0,ct&6)throw Error(oe(331));var s=ct;for(ct|=4,Ne=e.current;Ne!==null;){var i=Ne,o=i.child;if(Ne.flags&16){var a=i.deletions;if(a!==null){for(var c=0;cVt()-By?Ji(e,0):Vy|=n),In(e,t)}function kS(e,t){t===0&&(e.mode&1?(t=Au,Au<<=1,!(Au&130023424)&&(Au=4194304)):t=1);var n=kn();e=Ds(e,t),e!==null&&(qc(e,t,n),In(e,n))}function DA(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),kS(e,n)}function IA(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,s=e.memoizedState;s!==null&&(n=s.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(oe(314))}r!==null&&r.delete(t),kS(e,n)}var CS;CS=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||On.current)An=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return An=!1,_A(e,t,n);An=!!(e.flags&131072)}else An=!1,Pt&&t.flags&1048576&&T_(t,Vd,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;pd(e,t),e=t.pendingProps;var s=Na(t,yn.current);ya(t,n),s=My(null,t,r,e,s,n);var i=Ly();return t.flags|=1,typeof s=="object"&&s!==null&&typeof s.render=="function"&&s.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,Dn(r)?(i=!0,$d(t)):i=!1,t.memoizedState=s.state!==null&&s.state!==void 0?s.state:null,Ry(t),s.updater=Qf,t.stateNode=s,s._reactInternals=t,qm(t,r,e,n),t=Jm(null,t,r,!0,i,n)):(t.tag=0,Pt&&i&&ky(t),_n(null,t,s,n),t=t.child),t;case 16:r=t.elementType;e:{switch(pd(e,t),e=t.pendingProps,s=r._init,r=s(r._payload),t.type=r,s=t.tag=LA(r),e=vr(r,e),s){case 0:t=Qm(null,t,r,e,n);break e;case 1:t=sw(null,t,r,e,n);break e;case 11:t=nw(null,t,r,e,n);break e;case 14:t=rw(null,t,r,vr(r.type,e),n);break e}throw Error(oe(306,r,""))}return t;case 0:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:vr(r,s),Qm(e,t,r,s,n);case 1:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:vr(r,s),sw(e,t,r,s,n);case 3:e:{if(lS(t),e===null)throw Error(oe(387));r=t.pendingProps,i=t.memoizedState,s=i.element,I_(e,t),Hd(t,r,null,n);var o=t.memoizedState;if(r=o.element,i.isDehydrated)if(i={element:r,isDehydrated:!1,cache:o.cache,pendingSuspenseBoundaries:o.pendingSuspenseBoundaries,transitions:o.transitions},t.updateQueue.baseState=i,t.memoizedState=i,t.flags&256){s=Aa(Error(oe(423)),t),t=iw(e,t,r,n,s);break e}else if(r!==s){s=Aa(Error(oe(424)),t),t=iw(e,t,r,n,s);break e}else for(Vn=gi(t.stateNode.containerInfo.firstChild),Bn=t,Pt=!0,br=null,n=O_(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Ta(),r===s){t=Is(e,t,n);break e}_n(e,t,r,n)}t=t.child}return t;case 5:return M_(t),e===null&&Km(t),r=t.type,s=t.pendingProps,i=e!==null?e.memoizedProps:null,o=s.children,Vm(r,s)?o=null:i!==null&&Vm(r,i)&&(t.flags|=32),aS(e,t),_n(e,t,o,n),t.child;case 6:return e===null&&Km(t),null;case 13:return cS(e,t,n);case 4:return Ay(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Pa(t,null,r,n):_n(e,t,r,n),t.child;case 11:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:vr(r,s),nw(e,t,r,s,n);case 7:return _n(e,t,t.pendingProps,n),t.child;case 8:return _n(e,t,t.pendingProps.children,n),t.child;case 12:return _n(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,s=t.pendingProps,i=t.memoizedProps,o=s.value,bt(Bd,r._currentValue),r._currentValue=o,i!==null)if(Pr(i.value,o)){if(i.children===s.children&&!On.current){t=Is(e,t,n);break e}}else for(i=t.child,i!==null&&(i.return=t);i!==null;){var a=i.dependencies;if(a!==null){o=i.child;for(var c=a.firstContext;c!==null;){if(c.context===r){if(i.tag===1){c=Es(-1,n&-n),c.tag=2;var u=i.updateQueue;if(u!==null){u=u.shared;var d=u.pending;d===null?c.next=c:(c.next=d.next,d.next=c),u.pending=c}}i.lanes|=n,c=i.alternate,c!==null&&(c.lanes|=n),Gm(i.return,n,t),a.lanes|=n;break}c=c.next}}else if(i.tag===10)o=i.type===t.type?null:i.child;else if(i.tag===18){if(o=i.return,o===null)throw Error(oe(341));o.lanes|=n,a=o.alternate,a!==null&&(a.lanes|=n),Gm(o,n,t),o=i.sibling}else o=i.child;if(o!==null)o.return=i;else for(o=i;o!==null;){if(o===t){o=null;break}if(i=o.sibling,i!==null){i.return=o.return,o=i;break}o=o.return}i=o}_n(e,t,s.children,n),t=t.child}return t;case 9:return s=t.type,r=t.pendingProps.children,ya(t,n),s=fr(s),r=r(s),t.flags|=1,_n(e,t,r,n),t.child;case 14:return r=t.type,s=vr(r,t.pendingProps),s=vr(r.type,s),rw(e,t,r,s,n);case 15:return iS(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:vr(r,s),pd(e,t),t.tag=1,Dn(r)?(e=!0,$d(t)):e=!1,ya(t,n),nS(t,r,s),qm(t,r,s,n),Jm(null,t,r,!0,e,n);case 19:return uS(e,t,n);case 22:return oS(e,t,n)}throw Error(oe(156,t.tag))};function jS(e,t){return Jb(e,t)}function MA(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 ar(e,t,n,r){return new MA(e,t,n,r)}function Ky(e){return e=e.prototype,!(!e||!e.isReactComponent)}function LA(e){if(typeof e=="function")return Ky(e)?1:0;if(e!=null){if(e=e.$$typeof,e===fy)return 11;if(e===hy)return 14}return 2}function wi(e,t){var n=e.alternate;return n===null?(n=ar(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 yd(e,t,n,r,s,i){var o=2;if(r=e,typeof e=="function")Ky(e)&&(o=1);else if(typeof e=="string")o=5;else e:switch(e){case Zo:return eo(n.children,s,i,t);case dy:o=8,s|=8;break;case wm:return e=ar(12,n,t,s|2),e.elementType=wm,e.lanes=i,e;case bm:return e=ar(13,n,t,s),e.elementType=bm,e.lanes=i,e;case _m:return e=ar(19,n,t,s),e.elementType=_m,e.lanes=i,e;case Mb:return th(n,s,i,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Db:o=10;break e;case Ib:o=9;break e;case fy:o=11;break e;case hy:o=14;break e;case ri:o=16,r=null;break e}throw Error(oe(130,e==null?e:typeof e,""))}return t=ar(o,n,t,s),t.elementType=e,t.type=r,t.lanes=i,t}function eo(e,t,n,r){return e=ar(7,e,r,t),e.lanes=n,e}function th(e,t,n,r){return e=ar(22,e,r,t),e.elementType=Mb,e.lanes=n,e.stateNode={isHidden:!1},e}function Fp(e,t,n){return e=ar(6,e,null,t),e.lanes=n,e}function zp(e,t,n){return t=ar(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function FA(e,t,n,r,s){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=xp(0),this.expirationTimes=xp(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=xp(0),this.identifierPrefix=r,this.onRecoverableError=s,this.mutableSourceEagerHydrationData=null}function Gy(e,t,n,r,s,i,o,a,c){return e=new FA(e,t,n,a,c),t===1?(t=1,i===!0&&(t|=8)):t=0,i=ar(3,null,null,t),e.current=i,i.stateNode=e,i.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},Ry(i),e}function zA(e,t,n){var r=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(PS)}catch(e){console.error(e)}}PS(),Pb.exports=Qn;var Vs=Pb.exports;const RS=Bf(Vs),WA=yb({__proto__:null,default:RS},[Vs]);var yw=Vs;vm.createRoot=yw.createRoot,vm.hydrateRoot=yw.hydrateRoot;/** +`+i.stack}return{value:e,source:t,stack:s,digest:null}}function Ip(e,t,n){return{value:e,source:null,stack:n??null,digest:t??null}}function Xm(e,t){try{console.error(t.value)}catch(n){setTimeout(function(){throw n})}}var xA=typeof WeakMap=="function"?WeakMap:Map;function rS(e,t,n){n=Ns(-1,n),n.tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){Zd||(Zd=!0,ag=r),Xm(e,t)},n}function sS(e,t,n){n=Ns(-1,n),n.tag=3;var r=e.type.getDerivedStateFromError;if(typeof r=="function"){var s=t.value;n.payload=function(){return r(s)},n.callback=function(){Xm(e,t)}}var i=e.stateNode;return i!==null&&typeof i.componentDidCatch=="function"&&(n.callback=function(){Xm(e,t),typeof r!="function"&&(xi===null?xi=new Set([this]):xi.add(this));var o=t.stack;this.componentDidCatch(t.value,{componentStack:o!==null?o:""})}),n}function J0(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new xA;var s=new Set;r.set(t,s)}else s=r.get(t),s===void 0&&(s=new Set,r.set(t,s));s.has(n)||(s.add(n),e=OA.bind(null,e,t,n),t.then(e,e))}function ew(e){do{var t;if((t=e.tag===13)&&(t=e.memoizedState,t=t!==null?t.dehydrated!==null:!0),t)return e;e=e.return}while(e!==null);return null}function tw(e,t,n,r,s){return e.mode&1?(e.flags|=65536,e.lanes=s,e):(e===t?e.flags|=65536:(e.flags|=128,n.flags|=131072,n.flags&=-52805,n.tag===1&&(n.alternate===null?n.tag=17:(t=Ns(-1,1),t.tag=2,vi(n,t,1))),n.lanes|=1),e)}var wA=Vs.ReactCurrentOwner,An=!1;function _n(e,t,n,r){t.child=e===null?O_(t,null,n,r):Pa(t,e.child,n,r)}function nw(e,t,n,r,s){n=n.render;var i=t.ref;return ya(t,s),r=My(e,t,n,r,i,s),n=Ly(),e!==null&&!An?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~s,Ms(e,t,s)):(Pt&&n&&ky(t),t.flags|=1,_n(e,t,r,s),t.child)}function rw(e,t,n,r,s){if(e===null){var i=n.type;return typeof i=="function"&&!Ky(i)&&i.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(t.tag=15,t.type=i,iS(e,t,i,r,s)):(e=gd(n.type,null,r,t,t.mode,s),e.ref=t.ref,e.return=t,t.child=e)}if(i=e.child,!(e.lanes&s)){var o=i.memoizedProps;if(n=n.compare,n=n!==null?n:uc,n(o,r)&&e.ref===t.ref)return Ms(e,t,s)}return t.flags|=1,e=bi(i,r),e.ref=t.ref,e.return=t,t.child=e}function iS(e,t,n,r,s){if(e!==null){var i=e.memoizedProps;if(uc(i,r)&&e.ref===t.ref)if(An=!1,t.pendingProps=r=i,(e.lanes&s)!==0)e.flags&131072&&(An=!0);else return t.lanes=e.lanes,Ms(e,t,s)}return Qm(e,t,n,r,s)}function oS(e,t,n){var r=t.pendingProps,s=r.children,i=e!==null?e.memoizedState:null;if(r.mode==="hidden")if(!(t.mode&1))t.memoizedState={baseLanes:0,cachePool:null,transitions:null},bt(ia,zn),zn|=n;else{if(!(n&1073741824))return e=i!==null?i.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,bt(ia,zn),zn|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=i!==null?i.baseLanes:n,bt(ia,zn),zn|=r}else i!==null?(r=i.baseLanes|n,t.memoizedState=null):r=n,bt(ia,zn),zn|=r;return _n(e,t,s,n),t.child}function aS(e,t){var n=t.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(t.flags|=512,t.flags|=2097152)}function Qm(e,t,n,r,s){var i=Dn(n)?so:yn.current;return i=Na(t,i),ya(t,s),n=My(e,t,n,r,i,s),r=Ly(),e!==null&&!An?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~s,Ms(e,t,s)):(Pt&&r&&ky(t),t.flags|=1,_n(e,t,n,s),t.child)}function sw(e,t,n,r,s){if(Dn(n)){var i=!0;zd(t)}else i=!1;if(ya(t,s),t.stateNode===null)hd(e,t),nS(t,n,r),qm(t,n,r,s),r=!0;else if(e===null){var o=t.stateNode,a=t.memoizedProps;o.props=a;var c=o.context,u=n.contextType;typeof u=="object"&&u!==null?u=fr(u):(u=Dn(n)?so:yn.current,u=Na(t,u));var d=n.getDerivedStateFromProps,f=typeof d=="function"||typeof o.getSnapshotBeforeUpdate=="function";f||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(a!==r||c!==u)&&Q0(t,o,r,u),ii=!1;var h=t.memoizedState;o.state=h,Wd(t,r,o,s),c=t.memoizedState,a!==r||h!==c||On.current||ii?(typeof d=="function"&&(Zm(t,n,d,r),c=t.memoizedState),(a=ii||X0(t,n,a,r,h,c,u))?(f||typeof o.UNSAFE_componentWillMount!="function"&&typeof o.componentWillMount!="function"||(typeof o.componentWillMount=="function"&&o.componentWillMount(),typeof o.UNSAFE_componentWillMount=="function"&&o.UNSAFE_componentWillMount()),typeof o.componentDidMount=="function"&&(t.flags|=4194308)):(typeof o.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=c),o.props=r,o.state=c,o.context=u,r=a):(typeof o.componentDidMount=="function"&&(t.flags|=4194308),r=!1)}else{o=t.stateNode,I_(e,t),a=t.memoizedProps,u=t.type===t.elementType?a:vr(t.type,a),o.props=u,f=t.pendingProps,h=o.context,c=n.contextType,typeof c=="object"&&c!==null?c=fr(c):(c=Dn(n)?so:yn.current,c=Na(t,c));var p=n.getDerivedStateFromProps;(d=typeof p=="function"||typeof o.getSnapshotBeforeUpdate=="function")||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(a!==f||h!==c)&&Q0(t,o,r,c),ii=!1,h=t.memoizedState,o.state=h,Wd(t,r,o,s);var x=t.memoizedState;a!==f||h!==x||On.current||ii?(typeof p=="function"&&(Zm(t,n,p,r),x=t.memoizedState),(u=ii||X0(t,n,u,r,h,x,c)||!1)?(d||typeof o.UNSAFE_componentWillUpdate!="function"&&typeof o.componentWillUpdate!="function"||(typeof o.componentWillUpdate=="function"&&o.componentWillUpdate(r,x,c),typeof o.UNSAFE_componentWillUpdate=="function"&&o.UNSAFE_componentWillUpdate(r,x,c)),typeof o.componentDidUpdate=="function"&&(t.flags|=4),typeof o.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof o.componentDidUpdate!="function"||a===e.memoizedProps&&h===e.memoizedState||(t.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||a===e.memoizedProps&&h===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=x),o.props=r,o.state=x,o.context=c,r=u):(typeof o.componentDidUpdate!="function"||a===e.memoizedProps&&h===e.memoizedState||(t.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||a===e.memoizedProps&&h===e.memoizedState||(t.flags|=1024),r=!1)}return Jm(e,t,n,r,i,s)}function Jm(e,t,n,r,s,i){aS(e,t);var o=(t.flags&128)!==0;if(!r&&!o)return s&&B0(t,n,!1),Ms(e,t,i);r=t.stateNode,wA.current=t;var a=o&&typeof n.getDerivedStateFromError!="function"?null:r.render();return t.flags|=1,e!==null&&o?(t.child=Pa(t,e.child,null,i),t.child=Pa(t,null,a,i)):_n(e,t,a,i),t.memoizedState=r.state,s&&B0(t,n,!0),t.child}function lS(e){var t=e.stateNode;t.pendingContext?V0(e,t.pendingContext,t.pendingContext!==t.context):t.context&&V0(e,t.context,!1),Ay(e,t.containerInfo)}function iw(e,t,n,r,s){return Ta(),jy(s),t.flags|=256,_n(e,t,n,r),t.child}var eg={dehydrated:null,treeContext:null,retryLane:0};function tg(e){return{baseLanes:e,cachePool:null,transitions:null}}function cS(e,t,n){var r=t.pendingProps,s=Dt.current,i=!1,o=(t.flags&128)!==0,a;if((a=o)||(a=e!==null&&e.memoizedState===null?!1:(s&2)!==0),a?(i=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(s|=1),bt(Dt,s&1),e===null)return Km(t),e=t.memoizedState,e!==null&&(e=e.dehydrated,e!==null)?(t.mode&1?e.data==="$!"?t.lanes=8:t.lanes=1073741824:t.lanes=1,null):(o=r.children,e=r.fallback,i?(r=t.mode,i=t.child,o={mode:"hidden",children:o},!(r&1)&&i!==null?(i.childLanes=0,i.pendingProps=o):i=eh(o,r,0,null),e=eo(e,r,n,null),i.return=t,e.return=t,i.sibling=e,t.child=i,t.child.memoizedState=tg(n),t.memoizedState=eg,e):$y(t,o));if(s=e.memoizedState,s!==null&&(a=s.dehydrated,a!==null))return bA(e,t,o,r,a,s,n);if(i){i=r.fallback,o=t.mode,s=e.child,a=s.sibling;var c={mode:"hidden",children:r.children};return!(o&1)&&t.child!==s?(r=t.child,r.childLanes=0,r.pendingProps=c,t.deletions=null):(r=bi(s,c),r.subtreeFlags=s.subtreeFlags&14680064),a!==null?i=bi(a,i):(i=eo(i,o,n,null),i.flags|=2),i.return=t,r.return=t,r.sibling=i,t.child=r,r=i,i=t.child,o=e.child.memoizedState,o=o===null?tg(n):{baseLanes:o.baseLanes|n,cachePool:null,transitions:o.transitions},i.memoizedState=o,i.childLanes=e.childLanes&~n,t.memoizedState=eg,r}return i=e.child,e=i.sibling,r=bi(i,{mode:"visible",children:r.children}),!(t.mode&1)&&(r.lanes=n),r.return=t,r.sibling=null,e!==null&&(n=t.deletions,n===null?(t.deletions=[e],t.flags|=16):n.push(e)),t.child=r,t.memoizedState=null,r}function $y(e,t){return t=eh({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function $u(e,t,n,r){return r!==null&&jy(r),Pa(t,e.child,null,n),e=$y(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function bA(e,t,n,r,s,i,o){if(n)return t.flags&256?(t.flags&=-257,r=Ip(Error(oe(422))),$u(e,t,o,r)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(i=r.fallback,s=t.mode,r=eh({mode:"visible",children:r.children},s,0,null),i=eo(i,s,o,null),i.flags|=2,r.return=t,i.return=t,r.sibling=i,t.child=r,t.mode&1&&Pa(t,e.child,null,o),t.child.memoizedState=tg(o),t.memoizedState=eg,i);if(!(t.mode&1))return $u(e,t,o,null);if(s.data==="$!"){if(r=s.nextSibling&&s.nextSibling.dataset,r)var a=r.dgst;return r=a,i=Error(oe(419)),r=Ip(i,r,void 0),$u(e,t,o,r)}if(a=(o&e.childLanes)!==0,An||a){if(r=en,r!==null){switch(o&-o){case 4:s=2;break;case 16:s=8;break;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:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:s=32;break;case 536870912:s=268435456;break;default:s=0}s=s&(r.suspendedLanes|o)?0:s,s!==0&&s!==i.retryLane&&(i.retryLane=s,Is(e,s),Nr(r,e,s,-1))}return Yy(),r=Ip(Error(oe(421))),$u(e,t,o,r)}return s.data==="$?"?(t.flags|=128,t.child=e.child,t=DA.bind(null,e),s._reactRetry=t,null):(e=i.treeContext,Vn=yi(s.nextSibling),Bn=t,Pt=!0,br=null,e!==null&&(sr[ir++]=ks,sr[ir++]=Cs,sr[ir++]=io,ks=e.id,Cs=e.overflow,io=t),t=$y(t,r.children),t.flags|=4096,t)}function ow(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),Gm(e.return,t,n)}function Mp(e,t,n,r,s){var i=e.memoizedState;i===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:s}:(i.isBackwards=t,i.rendering=null,i.renderingStartTime=0,i.last=r,i.tail=n,i.tailMode=s)}function uS(e,t,n){var r=t.pendingProps,s=r.revealOrder,i=r.tail;if(_n(e,t,r.children,n),r=Dt.current,r&2)r=r&1|2,t.flags|=128;else{if(e!==null&&e.flags&128)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&ow(e,n,t);else if(e.tag===19)ow(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}r&=1}if(bt(Dt,r),!(t.mode&1))t.memoizedState=null;else switch(s){case"forwards":for(n=t.child,s=null;n!==null;)e=n.alternate,e!==null&&Hd(e)===null&&(s=n),n=n.sibling;n=s,n===null?(s=t.child,t.child=null):(s=n.sibling,n.sibling=null),Mp(t,!1,s,n,i);break;case"backwards":for(n=null,s=t.child,t.child=null;s!==null;){if(e=s.alternate,e!==null&&Hd(e)===null){t.child=s;break}e=s.sibling,s.sibling=n,n=s,s=e}Mp(t,!0,n,null,i);break;case"together":Mp(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function hd(e,t){!(t.mode&1)&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function Ms(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),ao|=t.lanes,!(n&t.childLanes))return null;if(e!==null&&t.child!==e.child)throw Error(oe(153));if(t.child!==null){for(e=t.child,n=bi(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=bi(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function _A(e,t,n){switch(t.tag){case 3:lS(t),Ta();break;case 5:M_(t);break;case 1:Dn(t.type)&&zd(t);break;case 4:Ay(t,t.stateNode.containerInfo);break;case 10:var r=t.type._context,s=t.memoizedProps.value;bt(Vd,r._currentValue),r._currentValue=s;break;case 13:if(r=t.memoizedState,r!==null)return r.dehydrated!==null?(bt(Dt,Dt.current&1),t.flags|=128,null):n&t.child.childLanes?cS(e,t,n):(bt(Dt,Dt.current&1),e=Ms(e,t,n),e!==null?e.sibling:null);bt(Dt,Dt.current&1);break;case 19:if(r=(n&t.childLanes)!==0,e.flags&128){if(r)return uS(e,t,n);t.flags|=128}if(s=t.memoizedState,s!==null&&(s.rendering=null,s.tail=null,s.lastEffect=null),bt(Dt,Dt.current),r)break;return null;case 22:case 23:return t.lanes=0,oS(e,t,n)}return Ms(e,t,n)}var dS,ng,fS,hS;dS=function(e,t){for(var n=t.child;n!==null;){if(n.tag===5||n.tag===6)e.appendChild(n.stateNode);else if(n.tag!==4&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return;n=n.return}n.sibling.return=n.return,n=n.sibling}};ng=function(){};fS=function(e,t,n,r){var s=e.memoizedProps;if(s!==r){e=t.stateNode,Yi(Jr.current);var i=null;switch(n){case"input":s=km(e,s),r=km(e,r),i=[];break;case"select":s=Lt({},s,{value:void 0}),r=Lt({},r,{value:void 0}),i=[];break;case"textarea":s=Em(e,s),r=Em(e,r),i=[];break;default:typeof s.onClick!="function"&&typeof r.onClick=="function"&&(e.onclick=Ld)}Tm(n,r);var o;n=null;for(u in s)if(!r.hasOwnProperty(u)&&s.hasOwnProperty(u)&&s[u]!=null)if(u==="style"){var a=s[u];for(o in a)a.hasOwnProperty(o)&&(n||(n={}),n[o]="")}else u!=="dangerouslySetInnerHTML"&&u!=="children"&&u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&u!=="autoFocus"&&(rc.hasOwnProperty(u)?i||(i=[]):(i=i||[]).push(u,null));for(u in r){var c=r[u];if(a=s!=null?s[u]:void 0,r.hasOwnProperty(u)&&c!==a&&(c!=null||a!=null))if(u==="style")if(a){for(o in a)!a.hasOwnProperty(o)||c&&c.hasOwnProperty(o)||(n||(n={}),n[o]="");for(o in c)c.hasOwnProperty(o)&&a[o]!==c[o]&&(n||(n={}),n[o]=c[o])}else n||(i||(i=[]),i.push(u,n)),n=c;else u==="dangerouslySetInnerHTML"?(c=c?c.__html:void 0,a=a?a.__html:void 0,c!=null&&a!==c&&(i=i||[]).push(u,c)):u==="children"?typeof c!="string"&&typeof c!="number"||(i=i||[]).push(u,""+c):u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&(rc.hasOwnProperty(u)?(c!=null&&u==="onScroll"&&St("scroll",e),i||a===c||(i=[])):(i=i||[]).push(u,c))}n&&(i=i||[]).push("style",n);var u=i;(t.updateQueue=u)&&(t.flags|=4)}};hS=function(e,t,n,r){n!==r&&(t.flags|=4)};function vl(e,t){if(!Pt)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function pn(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var s=e.child;s!==null;)n|=s.lanes|s.childLanes,r|=s.subtreeFlags&14680064,r|=s.flags&14680064,s.return=e,s=s.sibling;else for(s=e.child;s!==null;)n|=s.lanes|s.childLanes,r|=s.subtreeFlags,r|=s.flags,s.return=e,s=s.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function SA(e,t,n){var r=t.pendingProps;switch(Cy(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return pn(t),null;case 1:return Dn(t.type)&&Fd(),pn(t),null;case 3:return r=t.stateNode,Ra(),kt(On),kt(yn),Dy(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(Fu(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,br!==null&&(ug(br),br=null))),ng(e,t),pn(t),null;case 5:Oy(t);var s=Yi(mc.current);if(n=t.type,e!==null&&t.stateNode!=null)fS(e,t,n,r,s),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!r){if(t.stateNode===null)throw Error(oe(166));return pn(t),null}if(e=Yi(Jr.current),Fu(t)){r=t.stateNode,n=t.type;var i=t.memoizedProps;switch(r[Wr]=t,r[hc]=i,e=(t.mode&1)!==0,n){case"dialog":St("cancel",r),St("close",r);break;case"iframe":case"object":case"embed":St("load",r);break;case"video":case"audio":for(s=0;s<\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=o.createElement(n,{is:r.is}):(e=o.createElement(n),n==="select"&&(o=e,r.multiple?o.multiple=!0:r.size&&(o.size=r.size))):e=o.createElementNS(e,n),e[Wr]=t,e[hc]=r,dS(e,t,!1,!1),t.stateNode=e;e:{switch(o=Pm(n,r),n){case"dialog":St("cancel",e),St("close",e),s=r;break;case"iframe":case"object":case"embed":St("load",e),s=r;break;case"video":case"audio":for(s=0;sOa&&(t.flags|=128,r=!0,vl(i,!1),t.lanes=4194304)}else{if(!r)if(e=Hd(o),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),vl(i,!0),i.tail===null&&i.tailMode==="hidden"&&!o.alternate&&!Pt)return pn(t),null}else 2*Vt()-i.renderingStartTime>Oa&&n!==1073741824&&(t.flags|=128,r=!0,vl(i,!1),t.lanes=4194304);i.isBackwards?(o.sibling=t.child,t.child=o):(n=i.last,n!==null?n.sibling=o:t.child=o,i.last=o)}return i.tail!==null?(t=i.tail,i.rendering=t,i.tail=t.sibling,i.renderingStartTime=Vt(),t.sibling=null,n=Dt.current,bt(Dt,r?n&1|2:n&1),t):(pn(t),null);case 22:case 23:return Hy(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?zn&1073741824&&(pn(t),t.subtreeFlags&6&&(t.flags|=8192)):pn(t),null;case 24:return null;case 25:return null}throw Error(oe(156,t.tag))}function kA(e,t){switch(Cy(t),t.tag){case 1:return Dn(t.type)&&Fd(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Ra(),kt(On),kt(yn),Dy(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return Oy(t),null;case 13:if(kt(Dt),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(oe(340));Ta()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return kt(Dt),null;case 4:return Ra(),null;case 10:return Ty(t.type._context),null;case 22:case 23:return Hy(),null;case 24:return null;default:return null}}var Uu=!1,mn=!1,CA=typeof WeakSet=="function"?WeakSet:Set,Ne=null;function sa(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){zt(e,t,r)}else n.current=null}function rg(e,t,n){try{n()}catch(r){zt(e,t,r)}}var aw=!1;function jA(e,t){if($m=Dd,e=v_(),Sy(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 s=r.anchorOffset,i=r.focusNode;r=r.focusOffset;try{n.nodeType,i.nodeType}catch{n=null;break e}var o=0,a=-1,c=-1,u=0,d=0,f=e,h=null;t:for(;;){for(var p;f!==n||s!==0&&f.nodeType!==3||(a=o+s),f!==i||r!==0&&f.nodeType!==3||(c=o+r),f.nodeType===3&&(o+=f.nodeValue.length),(p=f.firstChild)!==null;)h=f,f=p;for(;;){if(f===e)break t;if(h===n&&++u===s&&(a=o),h===i&&++d===r&&(c=o),(p=f.nextSibling)!==null)break;f=h,h=f.parentNode}f=p}n=a===-1||c===-1?null:{start:a,end:c}}else n=null}n=n||{start:0,end:0}}else n=null;for(Um={focusedElem:e,selectionRange:n},Dd=!1,Ne=t;Ne!==null;)if(t=Ne,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,Ne=e;else for(;Ne!==null;){t=Ne;try{var x=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(x!==null){var m=x.memoizedProps,w=x.memoizedState,y=t.stateNode,v=y.getSnapshotBeforeUpdate(t.elementType===t.type?m:vr(t.type,m),w);y.__reactInternalSnapshotBeforeUpdate=v}break;case 3:var b=t.stateNode.containerInfo;b.nodeType===1?b.textContent="":b.nodeType===9&&b.documentElement&&b.removeChild(b.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(oe(163))}}catch(_){zt(t,t.return,_)}if(e=t.sibling,e!==null){e.return=t.return,Ne=e;break}Ne=t.return}return x=aw,aw=!1,x}function Zl(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var s=r=r.next;do{if((s.tag&e)===e){var i=s.destroy;s.destroy=void 0,i!==void 0&&rg(t,n,i)}s=s.next}while(s!==r)}}function Qf(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 sg(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 pS(e){var t=e.alternate;t!==null&&(e.alternate=null,pS(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[Wr],delete t[hc],delete t[Wm],delete t[lA],delete t[cA])),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 mS(e){return e.tag===5||e.tag===3||e.tag===4}function lw(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||mS(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 ig(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=Ld));else if(r!==4&&(e=e.child,e!==null))for(ig(e,t,n),e=e.sibling;e!==null;)ig(e,t,n),e=e.sibling}function og(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(og(e,t,n),e=e.sibling;e!==null;)og(e,t,n),e=e.sibling}var rn=null,xr=!1;function Js(e,t,n){for(n=n.child;n!==null;)gS(e,t,n),n=n.sibling}function gS(e,t,n){if(Qr&&typeof Qr.onCommitFiberUnmount=="function")try{Qr.onCommitFiberUnmount(Wf,n)}catch{}switch(n.tag){case 5:mn||sa(n,t);case 6:var r=rn,s=xr;rn=null,Js(e,t,n),rn=r,xr=s,rn!==null&&(xr?(e=rn,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):rn.removeChild(n.stateNode));break;case 18:rn!==null&&(xr?(e=rn,n=n.stateNode,e.nodeType===8?Tp(e.parentNode,n):e.nodeType===1&&Tp(e,n),lc(e)):Tp(rn,n.stateNode));break;case 4:r=rn,s=xr,rn=n.stateNode.containerInfo,xr=!0,Js(e,t,n),rn=r,xr=s;break;case 0:case 11:case 14:case 15:if(!mn&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){s=r=r.next;do{var i=s,o=i.destroy;i=i.tag,o!==void 0&&(i&2||i&4)&&rg(n,t,o),s=s.next}while(s!==r)}Js(e,t,n);break;case 1:if(!mn&&(sa(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(a){zt(n,t,a)}Js(e,t,n);break;case 21:Js(e,t,n);break;case 22:n.mode&1?(mn=(r=mn)||n.memoizedState!==null,Js(e,t,n),mn=r):Js(e,t,n);break;default:Js(e,t,n)}}function cw(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new CA),t.forEach(function(r){var s=IA.bind(null,e,r);n.has(r)||(n.add(r),r.then(s,s))})}}function yr(e,t){var n=t.deletions;if(n!==null)for(var r=0;rs&&(s=o),r&=~i}if(r=s,r=Vt()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*NA(r/1960))-r,10e?16:e,ui===null)var r=!1;else{if(e=ui,ui=null,qd=0,ct&6)throw Error(oe(331));var s=ct;for(ct|=4,Ne=e.current;Ne!==null;){var i=Ne,o=i.child;if(Ne.flags&16){var a=i.deletions;if(a!==null){for(var c=0;cVt()-By?Ji(e,0):Vy|=n),In(e,t)}function kS(e,t){t===0&&(e.mode&1?(t=Au,Au<<=1,!(Au&130023424)&&(Au=4194304)):t=1);var n=kn();e=Is(e,t),e!==null&&(qc(e,t,n),In(e,n))}function DA(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),kS(e,n)}function IA(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,s=e.memoizedState;s!==null&&(n=s.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(oe(314))}r!==null&&r.delete(t),kS(e,n)}var CS;CS=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||On.current)An=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return An=!1,_A(e,t,n);An=!!(e.flags&131072)}else An=!1,Pt&&t.flags&1048576&&T_(t,Ud,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;hd(e,t),e=t.pendingProps;var s=Na(t,yn.current);ya(t,n),s=My(null,t,r,e,s,n);var i=Ly();return t.flags|=1,typeof s=="object"&&s!==null&&typeof s.render=="function"&&s.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,Dn(r)?(i=!0,zd(t)):i=!1,t.memoizedState=s.state!==null&&s.state!==void 0?s.state:null,Ry(t),s.updater=Xf,t.stateNode=s,s._reactInternals=t,qm(t,r,e,n),t=Jm(null,t,r,!0,i,n)):(t.tag=0,Pt&&i&&ky(t),_n(null,t,s,n),t=t.child),t;case 16:r=t.elementType;e:{switch(hd(e,t),e=t.pendingProps,s=r._init,r=s(r._payload),t.type=r,s=t.tag=LA(r),e=vr(r,e),s){case 0:t=Qm(null,t,r,e,n);break e;case 1:t=sw(null,t,r,e,n);break e;case 11:t=nw(null,t,r,e,n);break e;case 14:t=rw(null,t,r,vr(r.type,e),n);break e}throw Error(oe(306,r,""))}return t;case 0:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:vr(r,s),Qm(e,t,r,s,n);case 1:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:vr(r,s),sw(e,t,r,s,n);case 3:e:{if(lS(t),e===null)throw Error(oe(387));r=t.pendingProps,i=t.memoizedState,s=i.element,I_(e,t),Wd(t,r,null,n);var o=t.memoizedState;if(r=o.element,i.isDehydrated)if(i={element:r,isDehydrated:!1,cache:o.cache,pendingSuspenseBoundaries:o.pendingSuspenseBoundaries,transitions:o.transitions},t.updateQueue.baseState=i,t.memoizedState=i,t.flags&256){s=Aa(Error(oe(423)),t),t=iw(e,t,r,n,s);break e}else if(r!==s){s=Aa(Error(oe(424)),t),t=iw(e,t,r,n,s);break e}else for(Vn=yi(t.stateNode.containerInfo.firstChild),Bn=t,Pt=!0,br=null,n=O_(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Ta(),r===s){t=Ms(e,t,n);break e}_n(e,t,r,n)}t=t.child}return t;case 5:return M_(t),e===null&&Km(t),r=t.type,s=t.pendingProps,i=e!==null?e.memoizedProps:null,o=s.children,Vm(r,s)?o=null:i!==null&&Vm(r,i)&&(t.flags|=32),aS(e,t),_n(e,t,o,n),t.child;case 6:return e===null&&Km(t),null;case 13:return cS(e,t,n);case 4:return Ay(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Pa(t,null,r,n):_n(e,t,r,n),t.child;case 11:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:vr(r,s),nw(e,t,r,s,n);case 7:return _n(e,t,t.pendingProps,n),t.child;case 8:return _n(e,t,t.pendingProps.children,n),t.child;case 12:return _n(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,s=t.pendingProps,i=t.memoizedProps,o=s.value,bt(Vd,r._currentValue),r._currentValue=o,i!==null)if(Pr(i.value,o)){if(i.children===s.children&&!On.current){t=Ms(e,t,n);break e}}else for(i=t.child,i!==null&&(i.return=t);i!==null;){var a=i.dependencies;if(a!==null){o=i.child;for(var c=a.firstContext;c!==null;){if(c.context===r){if(i.tag===1){c=Ns(-1,n&-n),c.tag=2;var u=i.updateQueue;if(u!==null){u=u.shared;var d=u.pending;d===null?c.next=c:(c.next=d.next,d.next=c),u.pending=c}}i.lanes|=n,c=i.alternate,c!==null&&(c.lanes|=n),Gm(i.return,n,t),a.lanes|=n;break}c=c.next}}else if(i.tag===10)o=i.type===t.type?null:i.child;else if(i.tag===18){if(o=i.return,o===null)throw Error(oe(341));o.lanes|=n,a=o.alternate,a!==null&&(a.lanes|=n),Gm(o,n,t),o=i.sibling}else o=i.child;if(o!==null)o.return=i;else for(o=i;o!==null;){if(o===t){o=null;break}if(i=o.sibling,i!==null){i.return=o.return,o=i;break}o=o.return}i=o}_n(e,t,s.children,n),t=t.child}return t;case 9:return s=t.type,r=t.pendingProps.children,ya(t,n),s=fr(s),r=r(s),t.flags|=1,_n(e,t,r,n),t.child;case 14:return r=t.type,s=vr(r,t.pendingProps),s=vr(r.type,s),rw(e,t,r,s,n);case 15:return iS(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:vr(r,s),hd(e,t),t.tag=1,Dn(r)?(e=!0,zd(t)):e=!1,ya(t,n),nS(t,r,s),qm(t,r,s,n),Jm(null,t,r,!0,e,n);case 19:return uS(e,t,n);case 22:return oS(e,t,n)}throw Error(oe(156,t.tag))};function jS(e,t){return Jb(e,t)}function MA(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 ar(e,t,n,r){return new MA(e,t,n,r)}function Ky(e){return e=e.prototype,!(!e||!e.isReactComponent)}function LA(e){if(typeof e=="function")return Ky(e)?1:0;if(e!=null){if(e=e.$$typeof,e===fy)return 11;if(e===hy)return 14}return 2}function bi(e,t){var n=e.alternate;return n===null?(n=ar(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 gd(e,t,n,r,s,i){var o=2;if(r=e,typeof e=="function")Ky(e)&&(o=1);else if(typeof e=="string")o=5;else e:switch(e){case Zo:return eo(n.children,s,i,t);case dy:o=8,s|=8;break;case wm:return e=ar(12,n,t,s|2),e.elementType=wm,e.lanes=i,e;case bm:return e=ar(13,n,t,s),e.elementType=bm,e.lanes=i,e;case _m:return e=ar(19,n,t,s),e.elementType=_m,e.lanes=i,e;case Mb:return eh(n,s,i,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Db:o=10;break e;case Ib:o=9;break e;case fy:o=11;break e;case hy:o=14;break e;case si:o=16,r=null;break e}throw Error(oe(130,e==null?e:typeof e,""))}return t=ar(o,n,t,s),t.elementType=e,t.type=r,t.lanes=i,t}function eo(e,t,n,r){return e=ar(7,e,r,t),e.lanes=n,e}function eh(e,t,n,r){return e=ar(22,e,r,t),e.elementType=Mb,e.lanes=n,e.stateNode={isHidden:!1},e}function Lp(e,t,n){return e=ar(6,e,null,t),e.lanes=n,e}function Fp(e,t,n){return t=ar(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function FA(e,t,n,r,s){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=vp(0),this.expirationTimes=vp(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=vp(0),this.identifierPrefix=r,this.onRecoverableError=s,this.mutableSourceEagerHydrationData=null}function Gy(e,t,n,r,s,i,o,a,c){return e=new FA(e,t,n,a,c),t===1?(t=1,i===!0&&(t|=8)):t=0,i=ar(3,null,null,t),e.current=i,i.stateNode=e,i.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},Ry(i),e}function zA(e,t,n){var r=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(PS)}catch(e){console.error(e)}}PS(),Pb.exports=Qn;var Bs=Pb.exports;const RS=Vf(Bs),WA=yb({__proto__:null,default:RS},[Bs]);var yw=Bs;vm.createRoot=yw.createRoot,vm.hydrateRoot=yw.hydrateRoot;/** * @remix-run/router v1.18.0 * * Copyright (c) Remix Software Inc. @@ -46,9 +46,9 @@ Error generating stack: `+i.message+` * LICENSE.md file in the root directory of this source tree. * * @license MIT - */function Ot(){return Ot=Object.assign?Object.assign.bind():function(e){for(var t=1;t"u")throw new Error(t)}function co(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function YA(){return Math.random().toString(36).substr(2,8)}function xw(e,t){return{usr:e.state,key:e.key,idx:t}}function xc(e,t,n,r){return n===void 0&&(n=null),Ot({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?Bs(t):t,{state:n,key:t&&t.key||r||YA()})}function uo(e){let{pathname:t="/",search:n="",hash:r=""}=e;return n&&n!=="?"&&(t+=n.charAt(0)==="?"?n:"?"+n),r&&r!=="#"&&(t+=r.charAt(0)==="#"?r:"#"+r),t}function Bs(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substr(n),e=e.substr(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substr(r),e=e.substr(0,r)),e&&(t.pathname=e)}return t}function KA(e,t,n,r){r===void 0&&(r={});let{window:s=document.defaultView,v5Compat:i=!1}=r,o=s.history,a=Wt.Pop,c=null,u=d();u==null&&(u=0,o.replaceState(Ot({},o.state,{idx:u}),""));function d(){return(o.state||{idx:null}).idx}function f(){a=Wt.Pop;let w=d(),y=w==null?null:w-u;u=w,c&&c({action:a,location:m.location,delta:y})}function h(w,y){a=Wt.Push;let v=xc(m.location,w,y);n&&n(v,w),u=d()+1;let b=xw(v,u),_=m.createHref(v);try{o.pushState(b,"",_)}catch(C){if(C instanceof DOMException&&C.name==="DataCloneError")throw C;s.location.assign(_)}i&&c&&c({action:a,location:m.location,delta:1})}function p(w,y){a=Wt.Replace;let v=xc(m.location,w,y);n&&n(v,w),u=d();let b=xw(v,u),_=m.createHref(v);o.replaceState(b,"",_),i&&c&&c({action:a,location:m.location,delta:0})}function x(w){let y=s.location.origin!=="null"?s.location.origin:s.location.href,v=typeof w=="string"?w:uo(w);return v=v.replace(/ $/,"%20"),tt(y,"No window.location.(origin|href) available to create URL for href: "+v),new URL(v,y)}let m={get action(){return a},get location(){return e(s,o)},listen(w){if(c)throw new Error("A history only accepts one active listener");return s.addEventListener(vw,f),c=w,()=>{s.removeEventListener(vw,f),c=null}},createHref(w){return t(s,w)},createURL:x,encodeLocation(w){let y=x(w);return{pathname:y.pathname,search:y.search,hash:y.hash}},push:h,replace:p,go(w){return o.go(w)}};return m}var wt;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(wt||(wt={}));const GA=new Set(["lazy","caseSensitive","path","id","index","children"]);function ZA(e){return e.index===!0}function wc(e,t,n,r){return n===void 0&&(n=[]),r===void 0&&(r={}),e.map((s,i)=>{let o=[...n,String(i)],a=typeof s.id=="string"?s.id:o.join("-");if(tt(s.index!==!0||!s.children,"Cannot specify children on an index route"),tt(!r[a],'Found a route id collision on id "'+a+`". Route id's must be globally unique within Data Router usages`),ZA(s)){let c=Ot({},s,t(s),{id:a});return r[a]=c,c}else{let c=Ot({},s,t(s),{id:a,children:void 0});return r[a]=c,s.children&&(c.children=wc(s.children,t,o,r)),c}})}function Vi(e,t,n){return n===void 0&&(n="/"),vd(e,t,n,!1)}function vd(e,t,n,r){let s=typeof t=="string"?Bs(t):t,i=Za(s.pathname||"/",n);if(i==null)return null;let o=AS(e);XA(o);let a=null;for(let c=0;a==null&&c{let c={relativePath:a===void 0?i.path||"":a,caseSensitive:i.caseSensitive===!0,childrenIndex:o,route:i};c.relativePath.startsWith("/")&&(tt(c.relativePath.startsWith(r),'Absolute route path "'+c.relativePath+'" nested under path '+('"'+r+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),c.relativePath=c.relativePath.slice(r.length));let u=Ns([r,c.relativePath]),d=n.concat(c);i.children&&i.children.length>0&&(tt(i.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+u+'".')),AS(i.children,t,d,u)),!(i.path==null&&!i.index)&&t.push({path:u,score:sO(u,i.index),routesMeta:d})};return e.forEach((i,o)=>{var a;if(i.path===""||!((a=i.path)!=null&&a.includes("?")))s(i,o);else for(let c of OS(i.path))s(i,o,c)}),t}function OS(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,s=n.endsWith("?"),i=n.replace(/\?$/,"");if(r.length===0)return s?[i,""]:[i];let o=OS(r.join("/")),a=[];return a.push(...o.map(c=>c===""?i:[i,c].join("/"))),s&&a.push(...o),a.map(c=>e.startsWith("/")&&c===""?"/":c)}function XA(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:iO(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}const QA=/^:[\w-]+$/,JA=3,eO=2,tO=1,nO=10,rO=-2,ww=e=>e==="*";function sO(e,t){let n=e.split("/"),r=n.length;return n.some(ww)&&(r+=rO),t&&(r+=eO),n.filter(s=>!ww(s)).reduce((s,i)=>s+(QA.test(i)?JA:i===""?tO:nO),r)}function iO(e,t){return e.length===t.length&&e.slice(0,-1).every((r,s)=>r===t[s])?e[e.length-1]-t[t.length-1]:0}function oO(e,t,n){n===void 0&&(n=!1);let{routesMeta:r}=e,s={},i="/",o=[];for(let a=0;a{let{paramName:h,isOptional:p}=d;if(h==="*"){let m=a[f]||"";o=i.slice(0,i.length-m.length).replace(/(.)\/+$/,"$1")}const x=a[f];return p&&!x?u[h]=void 0:u[h]=(x||"").replace(/%2F/g,"/"),u},{}),pathname:i,pathnameBase:o,pattern:e}}function aO(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!0),co(e==="*"||!e.endsWith("*")||e.endsWith("/*"),'Route path "'+e+'" will be treated as if it were '+('"'+e.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+e.replace(/\*$/,"/*")+'".'));let r=[],s="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(o,a,c)=>(r.push({paramName:a,isOptional:c!=null}),c?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(r.push({paramName:"*"}),s+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?s+="\\/*$":e!==""&&e!=="/"&&(s+="(?:(?=\\/|$))"),[new RegExp(s,t?void 0:"i"),r]}function lO(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return co(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+t+").")),e}}function Za(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,r=e.charAt(n);return r&&r!=="/"?null:e.slice(n)||"/"}function cO(e,t){t===void 0&&(t="/");let{pathname:n,search:r="",hash:s=""}=typeof e=="string"?Bs(e):e;return{pathname:n?n.startsWith("/")?n:uO(n,t):t,search:fO(r),hash:hO(s)}}function uO(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(s=>{s===".."?n.length>1&&n.pop():s!=="."&&n.push(s)}),n.length>1?n.join("/"):"/"}function $p(e,t,n,r){return"Cannot include a '"+e+"' character in a manually specified "+("`to."+t+"` field ["+JSON.stringify(r)+"]. Please separate it out to the ")+("`to."+n+"` field. Alternatively you may provide the full path as ")+'a string in and the router will parse it for you.'}function DS(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function oh(e,t){let n=DS(e);return t?n.map((r,s)=>s===n.length-1?r.pathname:r.pathnameBase):n.map(r=>r.pathnameBase)}function ah(e,t,n,r){r===void 0&&(r=!1);let s;typeof e=="string"?s=Bs(e):(s=Ot({},e),tt(!s.pathname||!s.pathname.includes("?"),$p("?","pathname","search",s)),tt(!s.pathname||!s.pathname.includes("#"),$p("#","pathname","hash",s)),tt(!s.search||!s.search.includes("#"),$p("#","search","hash",s)));let i=e===""||s.pathname==="",o=i?"/":s.pathname,a;if(o==null)a=n;else{let f=t.length-1;if(!r&&o.startsWith("..")){let h=o.split("/");for(;h[0]==="..";)h.shift(),f-=1;s.pathname=h.join("/")}a=f>=0?t[f]:"/"}let c=cO(s,a),u=o&&o!=="/"&&o.endsWith("/"),d=(i||o===".")&&n.endsWith("/");return!c.pathname.endsWith("/")&&(u||d)&&(c.pathname+="/"),c}const Ns=e=>e.join("/").replace(/\/\/+/g,"/"),dO=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),fO=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,hO=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;class Qy{constructor(t,n,r,s){s===void 0&&(s=!1),this.status=t,this.statusText=n||"",this.internal=s,r instanceof Error?(this.data=r.toString(),this.error=r):this.data=r}}function lh(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const IS=["post","put","patch","delete"],pO=new Set(IS),mO=["get",...IS],gO=new Set(mO),yO=new Set([301,302,303,307,308]),vO=new Set([307,308]),Up={state:"idle",location:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},xO={state:"idle",data:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},xl={state:"unblocked",proceed:void 0,reset:void 0,location:void 0},Jy=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,wO=e=>({hasErrorBoundary:!!e.hasErrorBoundary}),MS="remix-router-transitions";function bO(e){const t=e.window?e.window:typeof window<"u"?window:void 0,n=typeof t<"u"&&typeof t.document<"u"&&typeof t.document.createElement<"u",r=!n;tt(e.routes.length>0,"You must provide a non-empty routes array to createRouter");let s;if(e.mapRouteProperties)s=e.mapRouteProperties;else if(e.detectErrorBoundary){let V=e.detectErrorBoundary;s=H=>({hasErrorBoundary:V(H)})}else s=wO;let i={},o=wc(e.routes,s,void 0,i),a,c=e.basename||"/",u=e.unstable_dataStrategy||jO,d=e.unstable_patchRoutesOnMiss,f=Ot({v7_fetcherPersist:!1,v7_normalizeFormMethod:!1,v7_partialHydration:!1,v7_prependBasename:!1,v7_relativeSplatPath:!1,v7_skipActionErrorRevalidation:!1},e.future),h=null,p=new Set,x=null,m=null,w=null,y=e.hydrationData!=null,v=Vi(o,e.history.location,c),b=null;if(v==null&&!d){let V=wn(404,{pathname:e.history.location.pathname}),{matches:H,route:q}=Rw(o);v=H,b={[q.id]:V}}v&&d&&!e.hydrationData&&hp(v,o,e.history.location.pathname).active&&(v=null);let _;if(!v)_=!1,v=[];else if(v.some(V=>V.route.lazy))_=!1;else if(!v.some(V=>V.route.loader))_=!0;else if(f.v7_partialHydration){let V=e.hydrationData?e.hydrationData.loaderData:null,H=e.hydrationData?e.hydrationData.errors:null,q=ne=>ne.route.loader?typeof ne.route.loader=="function"&&ne.route.loader.hydrate===!0?!1:V&&V[ne.route.id]!==void 0||H&&H[ne.route.id]!==void 0:!0;if(H){let ne=v.findIndex(be=>H[be.route.id]!==void 0);_=v.slice(0,ne+1).every(q)}else _=v.every(q)}else _=e.hydrationData!=null;let C,j={historyAction:e.history.action,location:e.history.location,matches:v,initialized:_,navigation:Up,restoreScrollPosition:e.hydrationData!=null?!1:null,preventScrollReset:!1,revalidation:"idle",loaderData:e.hydrationData&&e.hydrationData.loaderData||{},actionData:e.hydrationData&&e.hydrationData.actionData||null,errors:e.hydrationData&&e.hydrationData.errors||b,fetchers:new Map,blockers:new Map},T=Wt.Pop,R=!1,A,D=!1,G=new Map,N=null,F=!1,S=!1,U=[],J=[],z=new Map,W=0,I=-1,X=new Map,$=new Set,B=new Map,he=new Map,se=new Set,ie=new Map,De=new Map,pe=new Map,we=!1;function Te(){if(h=e.history.listen(V=>{let{action:H,location:q,delta:ne}=V;if(we){we=!1;return}co(De.size===0||ne!=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 be=bu({currentLocation:j.location,nextLocation:q,historyAction:H});if(be&&ne!=null){we=!0,e.history.go(ne*-1),Ao(be,{state:"blocked",location:q,proceed(){Ao(be,{state:"proceeding",proceed:void 0,reset:void 0,location:q}),e.history.go(ne)},reset(){let Ae=new Map(j.blockers);Ae.set(be,xl),Re({blockers:Ae})}});return}return Z(H,q)}),n){zO(t,G);let V=()=>$O(t,G);t.addEventListener("pagehide",V),N=()=>t.removeEventListener("pagehide",V)}return j.initialized||Z(Wt.Pop,j.location,{initialHydration:!0}),C}function ze(){h&&h(),N&&N(),p.clear(),A&&A.abort(),j.fetchers.forEach((V,H)=>Yt(H)),j.blockers.forEach((V,H)=>wu(H))}function Ie(V){return p.add(V),()=>p.delete(V)}function Re(V,H){H===void 0&&(H={}),j=Ot({},j,V);let q=[],ne=[];f.v7_fetcherPersist&&j.fetchers.forEach((be,Ae)=>{be.state==="idle"&&(se.has(Ae)?ne.push(Ae):q.push(Ae))}),[...p].forEach(be=>be(j,{deletedFetchers:ne,unstable_viewTransitionOpts:H.viewTransitionOpts,unstable_flushSync:H.flushSync===!0})),f.v7_fetcherPersist&&(q.forEach(be=>j.fetchers.delete(be)),ne.forEach(be=>Yt(be)))}function st(V,H,q){var ne,be;let{flushSync:Ae}=q===void 0?{}:q,Be=j.actionData!=null&&j.navigation.formMethod!=null&&wr(j.navigation.formMethod)&&j.navigation.state==="loading"&&((ne=V.state)==null?void 0:ne._isRedirect)!==!0,fe;H.actionData?Object.keys(H.actionData).length>0?fe=H.actionData:fe=null:Be?fe=j.actionData:fe=null;let qe=H.loaderData?Tw(j.loaderData,H.loaderData,H.matches||[],H.errors):j.loaderData,Fe=j.blockers;Fe.size>0&&(Fe=new Map(Fe),Fe.forEach((mt,xt)=>Fe.set(xt,xl)));let $e=R===!0||j.navigation.formMethod!=null&&wr(j.navigation.formMethod)&&((be=V.state)==null?void 0:be._isRedirect)!==!0;a&&(o=a,a=void 0),F||T===Wt.Pop||(T===Wt.Push?e.history.push(V,V.state):T===Wt.Replace&&e.history.replace(V,V.state));let yt;if(T===Wt.Pop){let mt=G.get(j.location.pathname);mt&&mt.has(V.pathname)?yt={currentLocation:j.location,nextLocation:V}:G.has(V.pathname)&&(yt={currentLocation:V,nextLocation:j.location})}else if(D){let mt=G.get(j.location.pathname);mt?mt.add(V.pathname):(mt=new Set([V.pathname]),G.set(j.location.pathname,mt)),yt={currentLocation:j.location,nextLocation:V}}Re(Ot({},H,{actionData:fe,loaderData:qe,historyAction:T,location:V,initialized:!0,navigation:Up,revalidation:"idle",restoreScrollPosition:a0(V,H.matches||j.matches),preventScrollReset:$e,blockers:Fe}),{viewTransitionOpts:yt,flushSync:Ae===!0}),T=Wt.Pop,R=!1,D=!1,F=!1,S=!1,U=[],J=[]}async function E(V,H){if(typeof V=="number"){e.history.go(V);return}let q=dg(j.location,j.matches,c,f.v7_prependBasename,V,f.v7_relativeSplatPath,H==null?void 0:H.fromRouteId,H==null?void 0:H.relative),{path:ne,submission:be,error:Ae}=_w(f.v7_normalizeFormMethod,!1,q,H),Be=j.location,fe=xc(j.location,ne,H&&H.state);fe=Ot({},fe,e.history.encodeLocation(fe));let qe=H&&H.replace!=null?H.replace:void 0,Fe=Wt.Push;qe===!0?Fe=Wt.Replace:qe===!1||be!=null&&wr(be.formMethod)&&be.formAction===j.location.pathname+j.location.search&&(Fe=Wt.Replace);let $e=H&&"preventScrollReset"in H?H.preventScrollReset===!0:void 0,yt=(H&&H.unstable_flushSync)===!0,mt=bu({currentLocation:Be,nextLocation:fe,historyAction:Fe});if(mt){Ao(mt,{state:"blocked",location:fe,proceed(){Ao(mt,{state:"proceeding",proceed:void 0,reset:void 0,location:fe}),E(V,H)},reset(){let xt=new Map(j.blockers);xt.set(mt,xl),Re({blockers:xt})}});return}return await Z(Fe,fe,{submission:be,pendingError:Ae,preventScrollReset:$e,replace:H&&H.replace,enableViewTransition:H&&H.unstable_viewTransition,flushSync:yt})}function ee(){if(Ye(),Re({revalidation:"loading"}),j.navigation.state!=="submitting"){if(j.navigation.state==="idle"){Z(j.historyAction,j.location,{startUninterruptedRevalidation:!0});return}Z(T||j.historyAction,j.navigation.location,{overrideNavigation:j.navigation})}}async function Z(V,H,q){A&&A.abort(),A=null,T=V,F=(q&&q.startUninterruptedRevalidation)===!0,pP(j.location,j.matches),R=(q&&q.preventScrollReset)===!0,D=(q&&q.enableViewTransition)===!0;let ne=a||o,be=q&&q.overrideNavigation,Ae=Vi(ne,H,c),Be=(q&&q.flushSync)===!0,fe=hp(Ae,ne,H.pathname);if(fe.active&&fe.matches&&(Ae=fe.matches),!Ae){let{error:ht,notFoundMatches:nn,route:Bt}=Oo(H.pathname);st(H,{matches:nn,loaderData:{},errors:{[Bt.id]:ht}},{flushSync:Be});return}if(j.initialized&&!S&&AO(j.location,H)&&!(q&&q.submission&&wr(q.submission.formMethod))){st(H,{matches:Ae},{flushSync:Be});return}A=new AbortController;let qe=Fo(e.history,H,A.signal,q&&q.submission),Fe;if(q&&q.pendingError)Fe=[oa(Ae).route.id,{type:wt.error,error:q.pendingError}];else if(q&&q.submission&&wr(q.submission.formMethod)){let ht=await O(qe,H,q.submission,Ae,fe.active,{replace:q.replace,flushSync:Be});if(ht.shortCircuited)return;if(ht.pendingActionResult){let[nn,Bt]=ht.pendingActionResult;if($n(Bt)&&lh(Bt.error)&&Bt.error.status===404){A=null,st(H,{matches:ht.matches,loaderData:{},errors:{[nn]:Bt.error}});return}}Ae=ht.matches||Ae,Fe=ht.pendingActionResult,be=Vp(H,q.submission),Be=!1,fe.active=!1,qe=Fo(e.history,qe.url,qe.signal)}let{shortCircuited:$e,matches:yt,loaderData:mt,errors:xt}=await k(qe,H,Ae,fe.active,be,q&&q.submission,q&&q.fetcherSubmission,q&&q.replace,q&&q.initialHydration===!0,Be,Fe);$e||(A=null,st(H,Ot({matches:yt||Ae},Pw(Fe),{loaderData:mt,errors:xt})))}async function O(V,H,q,ne,be,Ae){Ae===void 0&&(Ae={}),Ye();let Be=LO(H,q);if(Re({navigation:Be},{flushSync:Ae.flushSync===!0}),be){let Fe=await _u(ne,H.pathname,V.signal);if(Fe.type==="aborted")return{shortCircuited:!0};if(Fe.type==="error"){let{boundaryId:$e,error:yt}=$r(H.pathname,Fe);return{matches:Fe.partialMatches,pendingActionResult:[$e,{type:wt.error,error:yt}]}}else if(Fe.matches)ne=Fe.matches;else{let{notFoundMatches:$e,error:yt,route:mt}=Oo(H.pathname);return{matches:$e,pendingActionResult:[mt.id,{type:wt.error,error:yt}]}}}let fe,qe=Dl(ne,H);if(!qe.route.action&&!qe.route.lazy)fe={type:wt.error,error:wn(405,{method:V.method,pathname:H.pathname,routeId:qe.route.id})};else if(fe=(await te("action",V,[qe],ne))[0],V.signal.aborted)return{shortCircuited:!0};if(Ki(fe)){let Fe;return Ae&&Ae.replace!=null?Fe=Ae.replace:Fe=jw(fe.response.headers.get("Location"),new URL(V.url),c)===j.location.pathname+j.location.search,await Q(V,fe,{submission:q,replace:Fe}),{shortCircuited:!0}}if(Yi(fe))throw wn(400,{type:"defer-action"});if($n(fe)){let Fe=oa(ne,qe.route.id);return(Ae&&Ae.replace)!==!0&&(T=Wt.Push),{matches:ne,pendingActionResult:[Fe.route.id,fe]}}return{matches:ne,pendingActionResult:[qe.route.id,fe]}}async function k(V,H,q,ne,be,Ae,Be,fe,qe,Fe,$e){let yt=be||Vp(H,Ae),mt=Ae||Be||Dw(yt),xt=!F&&(!f.v7_partialHydration||!qe);if(ne){if(xt){let Ft=P($e);Re(Ot({navigation:yt},Ft!==void 0?{actionData:Ft}:{}),{flushSync:Fe})}let Je=await _u(q,H.pathname,V.signal);if(Je.type==="aborted")return{shortCircuited:!0};if(Je.type==="error"){let{boundaryId:Ft,error:Mn}=$r(H.pathname,Je);return{matches:Je.partialMatches,loaderData:{},errors:{[Ft]:Mn}}}else if(Je.matches)q=Je.matches;else{let{error:Ft,notFoundMatches:Mn,route:Nt}=Oo(H.pathname);return{matches:Mn,loaderData:{},errors:{[Nt.id]:Ft}}}}let ht=a||o,[nn,Bt]=Sw(e.history,j,q,mt,H,f.v7_partialHydration&&qe===!0,f.v7_skipActionErrorRevalidation,S,U,J,se,B,$,ht,c,$e);if(qs(Je=>!(q&&q.some(Ft=>Ft.route.id===Je))||nn&&nn.some(Ft=>Ft.route.id===Je)),I=++W,nn.length===0&&Bt.length===0){let Je=hs();return st(H,Ot({matches:q,loaderData:{},errors:$e&&$n($e[1])?{[$e[0]]:$e[1].error}:null},Pw($e),Je?{fetchers:new Map(j.fetchers)}:{}),{flushSync:Fe}),{shortCircuited:!0}}if(xt){let Je={};if(!ne){Je.navigation=yt;let Ft=P($e);Ft!==void 0&&(Je.actionData=Ft)}Bt.length>0&&(Je.fetchers=M(Bt)),Re(Je,{flushSync:Fe})}Bt.forEach(Je=>{z.has(Je.key)&<(Je.key),Je.controller&&z.set(Je.key,Je.controller)});let ul=()=>Bt.forEach(Je=>lt(Je.key));A&&A.signal.addEventListener("abort",ul);let{loaderResults:Xs,fetcherResults:Do}=await me(j.matches,q,nn,Bt,V);if(V.signal.aborted)return{shortCircuited:!0};A&&A.signal.removeEventListener("abort",ul),Bt.forEach(Je=>z.delete(Je.key));let Io=Aw([...Xs,...Do]);if(Io){if(Io.idx>=nn.length){let Je=Bt[Io.idx-nn.length].key;$.add(Je)}return await Q(V,Io.result,{replace:fe}),{shortCircuited:!0}}let{loaderData:Mo,errors:Ur}=Nw(j,q,nn,Xs,$e,Bt,Do,ie);ie.forEach((Je,Ft)=>{Je.subscribe(Mn=>{(Mn||Je.done)&&ie.delete(Ft)})}),f.v7_partialHydration&&qe&&j.errors&&Object.entries(j.errors).filter(Je=>{let[Ft]=Je;return!nn.some(Mn=>Mn.route.id===Ft)}).forEach(Je=>{let[Ft,Mn]=Je;Ur=Object.assign(Ur||{},{[Ft]:Mn})});let Su=hs(),ku=rr(I),Cu=Su||ku||Bt.length>0;return Ot({matches:q,loaderData:Mo,errors:Ur},Cu?{fetchers:new Map(j.fetchers)}:{})}function P(V){if(V&&!$n(V[1]))return{[V[0]]:V[1].data};if(j.actionData)return Object.keys(j.actionData).length===0?null:j.actionData}function M(V){return V.forEach(H=>{let q=j.fetchers.get(H.key),ne=wl(void 0,q?q.data:void 0);j.fetchers.set(H.key,ne)}),new Map(j.fetchers)}function K(V,H,q,ne){if(r)throw new Error("router.fetch() was called during the server render, but it shouldn't be. You are likely calling a useFetcher() method in the body of your component. Try moving it to a useEffect or a callback.");z.has(V)&<(V);let be=(ne&&ne.unstable_flushSync)===!0,Ae=a||o,Be=dg(j.location,j.matches,c,f.v7_prependBasename,q,f.v7_relativeSplatPath,H,ne==null?void 0:ne.relative),fe=Vi(Ae,Be,c),qe=hp(fe,Ae,Be);if(qe.active&&qe.matches&&(fe=qe.matches),!fe){Et(V,H,wn(404,{pathname:Be}),{flushSync:be});return}let{path:Fe,submission:$e,error:yt}=_w(f.v7_normalizeFormMethod,!0,Be,ne);if(yt){Et(V,H,yt,{flushSync:be});return}let mt=Dl(fe,Fe);if(R=(ne&&ne.preventScrollReset)===!0,$e&&wr($e.formMethod)){L(V,H,Fe,mt,fe,qe.active,be,$e);return}B.set(V,{routeId:H,path:Fe}),Y(V,H,Fe,mt,fe,qe.active,be,$e)}async function L(V,H,q,ne,be,Ae,Be,fe){Ye(),B.delete(V);function qe(Nt){if(!Nt.route.action&&!Nt.route.lazy){let ps=wn(405,{method:fe.formMethod,pathname:q,routeId:H});return Et(V,H,ps,{flushSync:Be}),!0}return!1}if(!Ae&&qe(ne))return;let Fe=j.fetchers.get(V);Ue(V,FO(fe,Fe),{flushSync:Be});let $e=new AbortController,yt=Fo(e.history,q,$e.signal,fe);if(Ae){let Nt=await _u(be,q,yt.signal);if(Nt.type==="aborted")return;if(Nt.type==="error"){let{error:ps}=$r(q,Nt);Et(V,H,ps,{flushSync:Be});return}else if(Nt.matches){if(be=Nt.matches,ne=Dl(be,q),qe(ne))return}else{Et(V,H,wn(404,{pathname:q}),{flushSync:Be});return}}z.set(V,$e);let mt=W,ht=(await te("action",yt,[ne],be))[0];if(yt.signal.aborted){z.get(V)===$e&&z.delete(V);return}if(f.v7_fetcherPersist&&se.has(V)){if(Ki(ht)||$n(ht)){Ue(V,ti(void 0));return}}else{if(Ki(ht))if(z.delete(V),I>mt){Ue(V,ti(void 0));return}else return $.add(V),Ue(V,wl(fe)),Q(yt,ht,{fetcherSubmission:fe});if($n(ht)){Et(V,H,ht.error);return}}if(Yi(ht))throw wn(400,{type:"defer-action"});let nn=j.navigation.location||j.location,Bt=Fo(e.history,nn,$e.signal),ul=a||o,Xs=j.navigation.state!=="idle"?Vi(ul,j.navigation.location,c):j.matches;tt(Xs,"Didn't find any matches after fetcher action");let Do=++W;X.set(V,Do);let Io=wl(fe,ht.data);j.fetchers.set(V,Io);let[Mo,Ur]=Sw(e.history,j,Xs,fe,nn,!1,f.v7_skipActionErrorRevalidation,S,U,J,se,B,$,ul,c,[ne.route.id,ht]);Ur.filter(Nt=>Nt.key!==V).forEach(Nt=>{let ps=Nt.key,l0=j.fetchers.get(ps),yP=wl(void 0,l0?l0.data:void 0);j.fetchers.set(ps,yP),z.has(ps)&<(ps),Nt.controller&&z.set(ps,Nt.controller)}),Re({fetchers:new Map(j.fetchers)});let Su=()=>Ur.forEach(Nt=>lt(Nt.key));$e.signal.addEventListener("abort",Su);let{loaderResults:ku,fetcherResults:Cu}=await me(j.matches,Xs,Mo,Ur,Bt);if($e.signal.aborted)return;$e.signal.removeEventListener("abort",Su),X.delete(V),z.delete(V),Ur.forEach(Nt=>z.delete(Nt.key));let Je=Aw([...ku,...Cu]);if(Je){if(Je.idx>=Mo.length){let Nt=Ur[Je.idx-Mo.length].key;$.add(Nt)}return Q(Bt,Je.result)}let{loaderData:Ft,errors:Mn}=Nw(j,j.matches,Mo,ku,void 0,Ur,Cu,ie);if(j.fetchers.has(V)){let Nt=ti(ht.data);j.fetchers.set(V,Nt)}rr(Do),j.navigation.state==="loading"&&Do>I?(tt(T,"Expected pending action"),A&&A.abort(),st(j.navigation.location,{matches:Xs,loaderData:Ft,errors:Mn,fetchers:new Map(j.fetchers)})):(Re({errors:Mn,loaderData:Tw(j.loaderData,Ft,Xs,Mn),fetchers:new Map(j.fetchers)}),S=!1)}async function Y(V,H,q,ne,be,Ae,Be,fe){let qe=j.fetchers.get(V);Ue(V,wl(fe,qe?qe.data:void 0),{flushSync:Be});let Fe=new AbortController,$e=Fo(e.history,q,Fe.signal);if(Ae){let ht=await _u(be,q,$e.signal);if(ht.type==="aborted")return;if(ht.type==="error"){let{error:nn}=$r(q,ht);Et(V,H,nn,{flushSync:Be});return}else if(ht.matches)be=ht.matches,ne=Dl(be,q);else{Et(V,H,wn(404,{pathname:q}),{flushSync:Be});return}}z.set(V,Fe);let yt=W,xt=(await te("loader",$e,[ne],be))[0];if(Yi(xt)&&(xt=await US(xt,$e.signal,!0)||xt),z.get(V)===Fe&&z.delete(V),!$e.signal.aborted){if(se.has(V)){Ue(V,ti(void 0));return}if(Ki(xt))if(I>yt){Ue(V,ti(void 0));return}else{$.add(V),await Q($e,xt);return}if($n(xt)){Et(V,H,xt.error);return}tt(!Yi(xt),"Unhandled fetcher deferred data"),Ue(V,ti(xt.data))}}async function Q(V,H,q){let{submission:ne,fetcherSubmission:be,replace:Ae}=q===void 0?{}:q;H.response.headers.has("X-Remix-Revalidate")&&(S=!0);let Be=H.response.headers.get("Location");tt(Be,"Expected a Location header on the redirect Response"),Be=jw(Be,new URL(V.url),c);let fe=xc(j.location,Be,{_isRedirect:!0});if(n){let xt=!1;if(H.response.headers.has("X-Remix-Reload-Document"))xt=!0;else if(Jy.test(Be)){const ht=e.history.createURL(Be);xt=ht.origin!==t.location.origin||Za(ht.pathname,c)==null}if(xt){Ae?t.location.replace(Be):t.location.assign(Be);return}}A=null;let qe=Ae===!0?Wt.Replace:Wt.Push,{formMethod:Fe,formAction:$e,formEncType:yt}=j.navigation;!ne&&!be&&Fe&&$e&&yt&&(ne=Dw(j.navigation));let mt=ne||be;if(vO.has(H.response.status)&&mt&&wr(mt.formMethod))await Z(qe,fe,{submission:Ot({},mt,{formAction:Be}),preventScrollReset:R});else{let xt=Vp(fe,ne);await Z(qe,fe,{overrideNavigation:xt,fetcherSubmission:be,preventScrollReset:R})}}async function te(V,H,q,ne){try{let be=await EO(u,V,H,q,ne,i,s);return await Promise.all(be.map((Ae,Be)=>{if(DO(Ae)){let fe=Ae.result;return{type:wt.redirect,response:PO(fe,H,q[Be].route.id,ne,c,f.v7_relativeSplatPath)}}return TO(Ae)}))}catch(be){return q.map(()=>({type:wt.error,error:be}))}}async function me(V,H,q,ne,be){let[Ae,...Be]=await Promise.all([q.length?te("loader",be,q,H):[],...ne.map(fe=>{if(fe.matches&&fe.match&&fe.controller){let qe=Fo(e.history,fe.path,fe.controller.signal);return te("loader",qe,[fe.match],fe.matches).then(Fe=>Fe[0])}else return Promise.resolve({type:wt.error,error:wn(404,{pathname:fe.path})})})]);return await Promise.all([Ow(V,q,Ae,Ae.map(()=>be.signal),!1,j.loaderData),Ow(V,ne.map(fe=>fe.match),Be,ne.map(fe=>fe.controller?fe.controller.signal:null),!0)]),{loaderResults:Ae,fetcherResults:Be}}function Ye(){S=!0,U.push(...qs()),B.forEach((V,H)=>{z.has(H)&&(J.push(H),lt(H))})}function Ue(V,H,q){q===void 0&&(q={}),j.fetchers.set(V,H),Re({fetchers:new Map(j.fetchers)},{flushSync:(q&&q.flushSync)===!0})}function Et(V,H,q,ne){ne===void 0&&(ne={});let be=oa(j.matches,H);Yt(V),Re({errors:{[be.route.id]:q},fetchers:new Map(j.fetchers)},{flushSync:(ne&&ne.flushSync)===!0})}function nr(V){return f.v7_fetcherPersist&&(he.set(V,(he.get(V)||0)+1),se.has(V)&&se.delete(V)),j.fetchers.get(V)||xO}function Yt(V){let H=j.fetchers.get(V);z.has(V)&&!(H&&H.state==="loading"&&X.has(V))&<(V),B.delete(V),X.delete(V),$.delete(V),se.delete(V),j.fetchers.delete(V)}function ds(V){if(f.v7_fetcherPersist){let H=(he.get(V)||0)-1;H<=0?(he.delete(V),se.add(V)):he.set(V,H)}else Yt(V);Re({fetchers:new Map(j.fetchers)})}function lt(V){let H=z.get(V);tt(H,"Expected fetch controller: "+V),H.abort(),z.delete(V)}function fs(V){for(let H of V){let q=nr(H),ne=ti(q.data);j.fetchers.set(H,ne)}}function hs(){let V=[],H=!1;for(let q of $){let ne=j.fetchers.get(q);tt(ne,"Expected fetcher: "+q),ne.state==="loading"&&($.delete(q),V.push(q),H=!0)}return fs(V),H}function rr(V){let H=[];for(let[q,ne]of X)if(ne0}function xu(V,H){let q=j.blockers.get(V)||xl;return De.get(V)!==H&&De.set(V,H),q}function wu(V){j.blockers.delete(V),De.delete(V)}function Ao(V,H){let q=j.blockers.get(V)||xl;tt(q.state==="unblocked"&&H.state==="blocked"||q.state==="blocked"&&H.state==="blocked"||q.state==="blocked"&&H.state==="proceeding"||q.state==="blocked"&&H.state==="unblocked"||q.state==="proceeding"&&H.state==="unblocked","Invalid blocker state transition: "+q.state+" -> "+H.state);let ne=new Map(j.blockers);ne.set(V,H),Re({blockers:ne})}function bu(V){let{currentLocation:H,nextLocation:q,historyAction:ne}=V;if(De.size===0)return;De.size>1&&co(!1,"A router only supports one blocker at a time");let be=Array.from(De.entries()),[Ae,Be]=be[be.length-1],fe=j.blockers.get(Ae);if(!(fe&&fe.state==="proceeding")&&Be({currentLocation:H,nextLocation:q,historyAction:ne}))return Ae}function Oo(V){let H=wn(404,{pathname:V}),q=a||o,{matches:ne,route:be}=Rw(q);return qs(),{notFoundMatches:ne,route:be,error:H}}function $r(V,H){return{boundaryId:oa(H.partialMatches).route.id,error:wn(400,{type:"route-discovery",pathname:V,message:H.error!=null&&"message"in H.error?H.error:String(H.error)})}}function qs(V){let H=[];return ie.forEach((q,ne)=>{(!V||V(ne))&&(q.cancel(),H.push(ne),ie.delete(ne))}),H}function hP(V,H,q){if(x=V,w=H,m=q||null,!y&&j.navigation===Up){y=!0;let ne=a0(j.location,j.matches);ne!=null&&Re({restoreScrollPosition:ne})}return()=>{x=null,w=null,m=null}}function o0(V,H){return m&&m(V,H.map(ne=>qA(ne,j.loaderData)))||V.key}function pP(V,H){if(x&&w){let q=o0(V,H);x[q]=w()}}function a0(V,H){if(x){let q=o0(V,H),ne=x[q];if(typeof ne=="number")return ne}return null}function hp(V,H,q){if(d)if(V){let ne=V[V.length-1].route;if(ne.path&&(ne.path==="*"||ne.path.endsWith("/*")))return{active:!0,matches:vd(H,q,c,!0)}}else return{active:!0,matches:vd(H,q,c,!0)||[]};return{active:!1,matches:null}}async function _u(V,H,q){let ne=V,be=ne.length>0?ne[ne.length-1].route:null;for(;;){let Ae=a==null,Be=a||o;try{await CO(d,H,ne,Be,i,s,pe,q)}catch($e){return{type:"error",error:$e,partialMatches:ne}}finally{Ae&&(o=[...o])}if(q.aborted)return{type:"aborted"};let fe=Vi(Be,H,c),qe=!1;if(fe){let $e=fe[fe.length-1].route;if($e.index)return{type:"success",matches:fe};if($e.path&&$e.path.length>0)if($e.path==="*")qe=!0;else return{type:"success",matches:fe}}let Fe=vd(Be,H,c,!0);if(!Fe||ne.map($e=>$e.route.id).join("-")===Fe.map($e=>$e.route.id).join("-"))return{type:"success",matches:qe?fe:null};if(ne=Fe,be=ne[ne.length-1].route,be.path==="*")return{type:"success",matches:ne}}}function mP(V){i={},a=wc(V,s,void 0,i)}function gP(V,H){let q=a==null;FS(V,H,a||o,i,s),q&&(o=[...o],Re({}))}return C={get basename(){return c},get future(){return f},get state(){return j},get routes(){return o},get window(){return t},initialize:Te,subscribe:Ie,enableScrollRestoration:hP,navigate:E,fetch:K,revalidate:ee,createHref:V=>e.history.createHref(V),encodeLocation:V=>e.history.encodeLocation(V),getFetcher:nr,deleteFetcher:ds,dispose:ze,getBlocker:xu,deleteBlocker:wu,patchRoutes:gP,_internalFetchControllers:z,_internalActiveDeferreds:ie,_internalSetRoutes:mP},C}function _O(e){return e!=null&&("formData"in e&&e.formData!=null||"body"in e&&e.body!==void 0)}function dg(e,t,n,r,s,i,o,a){let c,u;if(o){c=[];for(let f of t)if(c.push(f),f.route.id===o){u=f;break}}else c=t,u=t[t.length-1];let d=ah(s||".",oh(c,i),Za(e.pathname,n)||e.pathname,a==="path");return s==null&&(d.search=e.search,d.hash=e.hash),(s==null||s===""||s===".")&&u&&u.route.index&&!ev(d.search)&&(d.search=d.search?d.search.replace(/^\?/,"?index&"):"?index"),r&&n!=="/"&&(d.pathname=d.pathname==="/"?n:Ns([n,d.pathname])),uo(d)}function _w(e,t,n,r){if(!r||!_O(r))return{path:n};if(r.formMethod&&!MO(r.formMethod))return{path:n,error:wn(405,{method:r.formMethod})};let s=()=>({path:n,error:wn(400,{type:"invalid-body"})}),i=r.formMethod||"get",o=e?i.toUpperCase():i.toLowerCase(),a=zS(n);if(r.body!==void 0){if(r.formEncType==="text/plain"){if(!wr(o))return s();let h=typeof r.body=="string"?r.body:r.body instanceof FormData||r.body instanceof URLSearchParams?Array.from(r.body.entries()).reduce((p,x)=>{let[m,w]=x;return""+p+m+"="+w+` -`},""):String(r.body);return{path:n,submission:{formMethod:o,formAction:a,formEncType:r.formEncType,formData:void 0,json:void 0,text:h}}}else if(r.formEncType==="application/json"){if(!wr(o))return s();try{let h=typeof r.body=="string"?JSON.parse(r.body):r.body;return{path:n,submission:{formMethod:o,formAction:a,formEncType:r.formEncType,formData:void 0,json:h,text:void 0}}}catch{return s()}}}tt(typeof FormData=="function","FormData is not available in this environment");let c,u;if(r.formData)c=fg(r.formData),u=r.formData;else if(r.body instanceof FormData)c=fg(r.body),u=r.body;else if(r.body instanceof URLSearchParams)c=r.body,u=Ew(c);else if(r.body==null)c=new URLSearchParams,u=new FormData;else try{c=new URLSearchParams(r.body),u=Ew(c)}catch{return s()}let d={formMethod:o,formAction:a,formEncType:r&&r.formEncType||"application/x-www-form-urlencoded",formData:u,json:void 0,text:void 0};if(wr(d.formMethod))return{path:n,submission:d};let f=Bs(n);return t&&f.search&&ev(f.search)&&c.append("index",""),f.search="?"+c,{path:uo(f),submission:d}}function SO(e,t){let n=e;if(t){let r=e.findIndex(s=>s.route.id===t);r>=0&&(n=e.slice(0,r))}return n}function Sw(e,t,n,r,s,i,o,a,c,u,d,f,h,p,x,m){let w=m?$n(m[1])?m[1].error:m[1].data:void 0,y=e.createURL(t.location),v=e.createURL(s),b=m&&$n(m[1])?m[0]:void 0,_=b?SO(n,b):n,C=m?m[1].statusCode:void 0,j=o&&C&&C>=400,T=_.filter((A,D)=>{let{route:G}=A;if(G.lazy)return!0;if(G.loader==null)return!1;if(i)return typeof G.loader!="function"||G.loader.hydrate?!0:t.loaderData[G.id]===void 0&&(!t.errors||t.errors[G.id]===void 0);if(kO(t.loaderData,t.matches[D],A)||c.some(S=>S===A.route.id))return!0;let N=t.matches[D],F=A;return kw(A,Ot({currentUrl:y,currentParams:N.params,nextUrl:v,nextParams:F.params},r,{actionResult:w,actionStatus:C,defaultShouldRevalidate:j?!1:a||y.pathname+y.search===v.pathname+v.search||y.search!==v.search||LS(N,F)}))}),R=[];return f.forEach((A,D)=>{if(i||!n.some(U=>U.route.id===A.routeId)||d.has(D))return;let G=Vi(p,A.path,x);if(!G){R.push({key:D,routeId:A.routeId,path:A.path,matches:null,match:null,controller:null});return}let N=t.fetchers.get(D),F=Dl(G,A.path),S=!1;h.has(D)?S=!1:u.includes(D)?S=!0:N&&N.state!=="idle"&&N.data===void 0?S=a:S=kw(F,Ot({currentUrl:y,currentParams:t.matches[t.matches.length-1].params,nextUrl:v,nextParams:n[n.length-1].params},r,{actionResult:w,actionStatus:C,defaultShouldRevalidate:j?!1:a})),S&&R.push({key:D,routeId:A.routeId,path:A.path,matches:G,match:F,controller:new AbortController})}),[T,R]}function kO(e,t,n){let r=!t||n.route.id!==t.route.id,s=e[n.route.id]===void 0;return r||s}function LS(e,t){let n=e.route.path;return e.pathname!==t.pathname||n!=null&&n.endsWith("*")&&e.params["*"]!==t.params["*"]}function kw(e,t){if(e.route.shouldRevalidate){let n=e.route.shouldRevalidate(t);if(typeof n=="boolean")return n}return t.defaultShouldRevalidate}async function CO(e,t,n,r,s,i,o,a){let c=[t,...n.map(u=>u.route.id)].join("-");try{let u=o.get(c);u||(u=e({path:t,matches:n,patch:(d,f)=>{a.aborted||FS(d,f,r,s,i)}}),o.set(c,u)),u&&OO(u)&&await u}finally{o.delete(c)}}function FS(e,t,n,r,s){if(e){var i;let o=r[e];tt(o,"No route found to patch children into: routeId = "+e);let a=wc(t,s,[e,"patch",String(((i=o.children)==null?void 0:i.length)||"0")],r);o.children?o.children.push(...a):o.children=a}else{let o=wc(t,s,["patch",String(n.length||"0")],r);n.push(...o)}}async function Cw(e,t,n){if(!e.lazy)return;let r=await e.lazy();if(!e.lazy)return;let s=n[e.id];tt(s,"No route found in manifest");let i={};for(let o in r){let c=s[o]!==void 0&&o!=="hasErrorBoundary";co(!c,'Route "'+s.id+'" has a static property "'+o+'" defined but its lazy function is also returning a value for this property. '+('The lazy route property "'+o+'" will be ignored.')),!c&&!GA.has(o)&&(i[o]=r[o])}Object.assign(s,i),Object.assign(s,Ot({},t(s),{lazy:void 0}))}function jO(e){return Promise.all(e.matches.map(t=>t.resolve()))}async function EO(e,t,n,r,s,i,o,a){let c=r.reduce((f,h)=>f.add(h.route.id),new Set),u=new Set,d=await e({matches:s.map(f=>{let h=c.has(f.route.id);return Ot({},f,{shouldLoad:h,resolve:x=>(u.add(f.route.id),h?NO(t,n,f,i,o,x,a):Promise.resolve({type:wt.data,result:void 0}))})}),request:n,params:s[0].params,context:a});return s.forEach(f=>tt(u.has(f.route.id),'`match.resolve()` was not called for route id "'+f.route.id+'". You must call `match.resolve()` on every match passed to `dataStrategy` to ensure all routes are properly loaded.')),d.filter((f,h)=>c.has(s[h].route.id))}async function NO(e,t,n,r,s,i,o){let a,c,u=d=>{let f,h=new Promise((m,w)=>f=w);c=()=>f(),t.signal.addEventListener("abort",c);let p=m=>typeof d!="function"?Promise.reject(new Error("You cannot call the handler for a route which defines a boolean "+('"'+e+'" [routeId: '+n.route.id+"]"))):d({request:t,params:n.params,context:o},...m!==void 0?[m]:[]),x;return i?x=i(m=>p(m)):x=(async()=>{try{return{type:"data",result:await p()}}catch(m){return{type:"error",result:m}}})(),Promise.race([x,h])};try{let d=n.route[e];if(n.route.lazy)if(d){let f,[h]=await Promise.all([u(d).catch(p=>{f=p}),Cw(n.route,s,r)]);if(f!==void 0)throw f;a=h}else if(await Cw(n.route,s,r),d=n.route[e],d)a=await u(d);else if(e==="action"){let f=new URL(t.url),h=f.pathname+f.search;throw wn(405,{method:t.method,pathname:h,routeId:n.route.id})}else return{type:wt.data,result:void 0};else if(d)a=await u(d);else{let f=new URL(t.url),h=f.pathname+f.search;throw wn(404,{pathname:h})}tt(a.result!==void 0,"You defined "+(e==="action"?"an action":"a loader")+" for route "+('"'+n.route.id+"\" but didn't return anything from your `"+e+"` ")+"function. Please return a value or `null`.")}catch(d){return{type:wt.error,result:d}}finally{c&&t.signal.removeEventListener("abort",c)}return a}async function TO(e){let{result:t,type:n,status:r}=e;if($S(t)){let o;try{let a=t.headers.get("Content-Type");a&&/\bapplication\/json\b/.test(a)?t.body==null?o=null:o=await t.json():o=await t.text()}catch(a){return{type:wt.error,error:a}}return n===wt.error?{type:wt.error,error:new Qy(t.status,t.statusText,o),statusCode:t.status,headers:t.headers}:{type:wt.data,data:o,statusCode:t.status,headers:t.headers}}if(n===wt.error)return{type:wt.error,error:t,statusCode:lh(t)?t.status:r};if(IO(t)){var s,i;return{type:wt.deferred,deferredData:t,statusCode:(s=t.init)==null?void 0:s.status,headers:((i=t.init)==null?void 0:i.headers)&&new Headers(t.init.headers)}}return{type:wt.data,data:t,statusCode:r}}function PO(e,t,n,r,s,i){let o=e.headers.get("Location");if(tt(o,"Redirects returned/thrown from loaders/actions must have a Location header"),!Jy.test(o)){let a=r.slice(0,r.findIndex(c=>c.route.id===n)+1);o=dg(new URL(t.url),a,s,!0,o,i),e.headers.set("Location",o)}return e}function jw(e,t,n){if(Jy.test(e)){let r=e,s=r.startsWith("//")?new URL(t.protocol+r):new URL(r),i=Za(s.pathname,n)!=null;if(s.origin===t.origin&&i)return s.pathname+s.search+s.hash}return e}function Fo(e,t,n,r){let s=e.createURL(zS(t)).toString(),i={signal:n};if(r&&wr(r.formMethod)){let{formMethod:o,formEncType:a}=r;i.method=o.toUpperCase(),a==="application/json"?(i.headers=new Headers({"Content-Type":a}),i.body=JSON.stringify(r.json)):a==="text/plain"?i.body=r.text:a==="application/x-www-form-urlencoded"&&r.formData?i.body=fg(r.formData):i.body=r.formData}return new Request(s,i)}function fg(e){let t=new URLSearchParams;for(let[n,r]of e.entries())t.append(n,typeof r=="string"?r:r.name);return t}function Ew(e){let t=new FormData;for(let[n,r]of e.entries())t.append(n,r);return t}function RO(e,t,n,r,s,i){let o={},a=null,c,u=!1,d={},f=r&&$n(r[1])?r[1].error:void 0;return n.forEach((h,p)=>{let x=t[p].route.id;if(tt(!Ki(h),"Cannot handle redirect results in processLoaderData"),$n(h)){let m=h.error;f!==void 0&&(m=f,f=void 0),a=a||{};{let w=oa(e,x);a[w.route.id]==null&&(a[w.route.id]=m)}o[x]=void 0,u||(u=!0,c=lh(h.error)?h.error.status:500),h.headers&&(d[x]=h.headers)}else Yi(h)?(s.set(x,h.deferredData),o[x]=h.deferredData.data,h.statusCode!=null&&h.statusCode!==200&&!u&&(c=h.statusCode),h.headers&&(d[x]=h.headers)):(o[x]=h.data,h.statusCode&&h.statusCode!==200&&!u&&(c=h.statusCode),h.headers&&(d[x]=h.headers))}),f!==void 0&&r&&(a={[r[0]]:f},o[r[0]]=void 0),{loaderData:o,errors:a,statusCode:c||200,loaderHeaders:d}}function Nw(e,t,n,r,s,i,o,a){let{loaderData:c,errors:u}=RO(t,n,r,s,a);for(let d=0;dr.route.id===t)+1):[...e]).reverse().find(r=>r.route.hasErrorBoundary===!0)||e[0]}function Rw(e){let t=e.length===1?e[0]:e.find(n=>n.index||!n.path||n.path==="/")||{id:"__shim-error-route__"};return{matches:[{params:{},pathname:"",pathnameBase:"",route:t}],route:t}}function wn(e,t){let{pathname:n,routeId:r,method:s,type:i,message:o}=t===void 0?{}:t,a="Unknown Server Error",c="Unknown @remix-run/router error";return e===400?(a="Bad Request",i==="route-discovery"?c='Unable to match URL "'+n+'" - the `unstable_patchRoutesOnMiss()` '+(`function threw the following error: -`+o):s&&n&&r?c="You made a "+s+' request to "'+n+'" but '+('did not provide a `loader` for route "'+r+'", ')+"so there is no way to handle the request.":i==="defer-action"?c="defer() is not supported in actions":i==="invalid-body"&&(c="Unable to encode submission body")):e===403?(a="Forbidden",c='Route "'+r+'" does not match URL "'+n+'"'):e===404?(a="Not Found",c='No route matches URL "'+n+'"'):e===405&&(a="Method Not Allowed",s&&n&&r?c="You made a "+s.toUpperCase()+' request to "'+n+'" but '+('did not provide an `action` for route "'+r+'", ')+"so there is no way to handle the request.":s&&(c='Invalid request method "'+s.toUpperCase()+'"')),new Qy(e||500,a,new Error(c),!0)}function Aw(e){for(let t=e.length-1;t>=0;t--){let n=e[t];if(Ki(n))return{result:n,idx:t}}}function zS(e){let t=typeof e=="string"?Bs(e):e;return uo(Ot({},t,{hash:""}))}function AO(e,t){return e.pathname!==t.pathname||e.search!==t.search?!1:e.hash===""?t.hash!=="":e.hash===t.hash?!0:t.hash!==""}function OO(e){return typeof e=="object"&&e!=null&&"then"in e}function DO(e){return $S(e.result)&&yO.has(e.result.status)}function Yi(e){return e.type===wt.deferred}function $n(e){return e.type===wt.error}function Ki(e){return(e&&e.type)===wt.redirect}function IO(e){let t=e;return t&&typeof t=="object"&&typeof t.data=="object"&&typeof t.subscribe=="function"&&typeof t.cancel=="function"&&typeof t.resolveData=="function"}function $S(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.headers=="object"&&typeof e.body<"u"}function MO(e){return gO.has(e.toLowerCase())}function wr(e){return pO.has(e.toLowerCase())}async function Ow(e,t,n,r,s,i){for(let o=0;of.route.id===c.route.id),d=u!=null&&!LS(u,c)&&(i&&i[c.route.id])!==void 0;if(Yi(a)&&(s||d)){let f=r[o];tt(f,"Expected an AbortSignal for revalidating fetcher deferred result"),await US(a,f,s).then(h=>{h&&(n[o]=h||n[o])})}}}async function US(e,t,n){if(n===void 0&&(n=!1),!await e.deferredData.resolveData(t)){if(n)try{return{type:wt.data,data:e.deferredData.unwrappedData}}catch(s){return{type:wt.error,error:s}}return{type:wt.data,data:e.deferredData.data}}}function ev(e){return new URLSearchParams(e).getAll("index").some(t=>t==="")}function Dl(e,t){let n=typeof t=="string"?Bs(t).search:t.search;if(e[e.length-1].route.index&&ev(n||""))return e[e.length-1];let r=DS(e);return r[r.length-1]}function Dw(e){let{formMethod:t,formAction:n,formEncType:r,text:s,formData:i,json:o}=e;if(!(!t||!n||!r)){if(s!=null)return{formMethod:t,formAction:n,formEncType:r,formData:void 0,json:void 0,text:s};if(i!=null)return{formMethod:t,formAction:n,formEncType:r,formData:i,json:void 0,text:void 0};if(o!==void 0)return{formMethod:t,formAction:n,formEncType:r,formData:void 0,json:o,text:void 0}}}function Vp(e,t){return t?{state:"loading",location:e,formMethod:t.formMethod,formAction:t.formAction,formEncType:t.formEncType,formData:t.formData,json:t.json,text:t.text}:{state:"loading",location:e,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0}}function LO(e,t){return{state:"submitting",location:e,formMethod:t.formMethod,formAction:t.formAction,formEncType:t.formEncType,formData:t.formData,json:t.json,text:t.text}}function wl(e,t){return e?{state:"loading",formMethod:e.formMethod,formAction:e.formAction,formEncType:e.formEncType,formData:e.formData,json:e.json,text:e.text,data:t}:{state:"loading",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:t}}function FO(e,t){return{state:"submitting",formMethod:e.formMethod,formAction:e.formAction,formEncType:e.formEncType,formData:e.formData,json:e.json,text:e.text,data:t?t.data:void 0}}function ti(e){return{state:"idle",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:e}}function zO(e,t){try{let n=e.sessionStorage.getItem(MS);if(n){let r=JSON.parse(n);for(let[s,i]of Object.entries(r||{}))i&&Array.isArray(i)&&t.set(s,new Set(i||[]))}}catch{}}function $O(e,t){if(t.size>0){let n={};for(let[r,s]of t)n[r]=[...s];try{e.sessionStorage.setItem(MS,JSON.stringify(n))}catch(r){co(!1,"Failed to save applied view transitions in sessionStorage ("+r+").")}}}/** + */function Ot(){return Ot=Object.assign?Object.assign.bind():function(e){for(var t=1;t"u")throw new Error(t)}function co(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function YA(){return Math.random().toString(36).substr(2,8)}function xw(e,t){return{usr:e.state,key:e.key,idx:t}}function wc(e,t,n,r){return n===void 0&&(n=null),Ot({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?Ws(t):t,{state:n,key:t&&t.key||r||YA()})}function uo(e){let{pathname:t="/",search:n="",hash:r=""}=e;return n&&n!=="?"&&(t+=n.charAt(0)==="?"?n:"?"+n),r&&r!=="#"&&(t+=r.charAt(0)==="#"?r:"#"+r),t}function Ws(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substr(n),e=e.substr(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substr(r),e=e.substr(0,r)),e&&(t.pathname=e)}return t}function KA(e,t,n,r){r===void 0&&(r={});let{window:s=document.defaultView,v5Compat:i=!1}=r,o=s.history,a=Ht.Pop,c=null,u=d();u==null&&(u=0,o.replaceState(Ot({},o.state,{idx:u}),""));function d(){return(o.state||{idx:null}).idx}function f(){a=Ht.Pop;let w=d(),y=w==null?null:w-u;u=w,c&&c({action:a,location:m.location,delta:y})}function h(w,y){a=Ht.Push;let v=wc(m.location,w,y);n&&n(v,w),u=d()+1;let b=xw(v,u),_=m.createHref(v);try{o.pushState(b,"",_)}catch(C){if(C instanceof DOMException&&C.name==="DataCloneError")throw C;s.location.assign(_)}i&&c&&c({action:a,location:m.location,delta:1})}function p(w,y){a=Ht.Replace;let v=wc(m.location,w,y);n&&n(v,w),u=d();let b=xw(v,u),_=m.createHref(v);o.replaceState(b,"",_),i&&c&&c({action:a,location:m.location,delta:0})}function x(w){let y=s.location.origin!=="null"?s.location.origin:s.location.href,v=typeof w=="string"?w:uo(w);return v=v.replace(/ $/,"%20"),tt(y,"No window.location.(origin|href) available to create URL for href: "+v),new URL(v,y)}let m={get action(){return a},get location(){return e(s,o)},listen(w){if(c)throw new Error("A history only accepts one active listener");return s.addEventListener(vw,f),c=w,()=>{s.removeEventListener(vw,f),c=null}},createHref(w){return t(s,w)},createURL:x,encodeLocation(w){let y=x(w);return{pathname:y.pathname,search:y.search,hash:y.hash}},push:h,replace:p,go(w){return o.go(w)}};return m}var wt;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(wt||(wt={}));const GA=new Set(["lazy","caseSensitive","path","id","index","children"]);function ZA(e){return e.index===!0}function bc(e,t,n,r){return n===void 0&&(n=[]),r===void 0&&(r={}),e.map((s,i)=>{let o=[...n,String(i)],a=typeof s.id=="string"?s.id:o.join("-");if(tt(s.index!==!0||!s.children,"Cannot specify children on an index route"),tt(!r[a],'Found a route id collision on id "'+a+`". Route id's must be globally unique within Data Router usages`),ZA(s)){let c=Ot({},s,t(s),{id:a});return r[a]=c,c}else{let c=Ot({},s,t(s),{id:a,children:void 0});return r[a]=c,s.children&&(c.children=bc(s.children,t,o,r)),c}})}function Bi(e,t,n){return n===void 0&&(n="/"),yd(e,t,n,!1)}function yd(e,t,n,r){let s=typeof t=="string"?Ws(t):t,i=qa(s.pathname||"/",n);if(i==null)return null;let o=AS(e);XA(o);let a=null;for(let c=0;a==null&&c{let c={relativePath:a===void 0?i.path||"":a,caseSensitive:i.caseSensitive===!0,childrenIndex:o,route:i};c.relativePath.startsWith("/")&&(tt(c.relativePath.startsWith(r),'Absolute route path "'+c.relativePath+'" nested under path '+('"'+r+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),c.relativePath=c.relativePath.slice(r.length));let u=Ts([r,c.relativePath]),d=n.concat(c);i.children&&i.children.length>0&&(tt(i.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+u+'".')),AS(i.children,t,d,u)),!(i.path==null&&!i.index)&&t.push({path:u,score:sO(u,i.index),routesMeta:d})};return e.forEach((i,o)=>{var a;if(i.path===""||!((a=i.path)!=null&&a.includes("?")))s(i,o);else for(let c of OS(i.path))s(i,o,c)}),t}function OS(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,s=n.endsWith("?"),i=n.replace(/\?$/,"");if(r.length===0)return s?[i,""]:[i];let o=OS(r.join("/")),a=[];return a.push(...o.map(c=>c===""?i:[i,c].join("/"))),s&&a.push(...o),a.map(c=>e.startsWith("/")&&c===""?"/":c)}function XA(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:iO(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}const QA=/^:[\w-]+$/,JA=3,eO=2,tO=1,nO=10,rO=-2,ww=e=>e==="*";function sO(e,t){let n=e.split("/"),r=n.length;return n.some(ww)&&(r+=rO),t&&(r+=eO),n.filter(s=>!ww(s)).reduce((s,i)=>s+(QA.test(i)?JA:i===""?tO:nO),r)}function iO(e,t){return e.length===t.length&&e.slice(0,-1).every((r,s)=>r===t[s])?e[e.length-1]-t[t.length-1]:0}function oO(e,t,n){n===void 0&&(n=!1);let{routesMeta:r}=e,s={},i="/",o=[];for(let a=0;a{let{paramName:h,isOptional:p}=d;if(h==="*"){let m=a[f]||"";o=i.slice(0,i.length-m.length).replace(/(.)\/+$/,"$1")}const x=a[f];return p&&!x?u[h]=void 0:u[h]=(x||"").replace(/%2F/g,"/"),u},{}),pathname:i,pathnameBase:o,pattern:e}}function aO(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!0),co(e==="*"||!e.endsWith("*")||e.endsWith("/*"),'Route path "'+e+'" will be treated as if it were '+('"'+e.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+e.replace(/\*$/,"/*")+'".'));let r=[],s="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(o,a,c)=>(r.push({paramName:a,isOptional:c!=null}),c?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(r.push({paramName:"*"}),s+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?s+="\\/*$":e!==""&&e!=="/"&&(s+="(?:(?=\\/|$))"),[new RegExp(s,t?void 0:"i"),r]}function lO(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return co(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+t+").")),e}}function qa(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,r=e.charAt(n);return r&&r!=="/"?null:e.slice(n)||"/"}function cO(e,t){t===void 0&&(t="/");let{pathname:n,search:r="",hash:s=""}=typeof e=="string"?Ws(e):e;return{pathname:n?n.startsWith("/")?n:uO(n,t):t,search:fO(r),hash:hO(s)}}function uO(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(s=>{s===".."?n.length>1&&n.pop():s!=="."&&n.push(s)}),n.length>1?n.join("/"):"/"}function zp(e,t,n,r){return"Cannot include a '"+e+"' character in a manually specified "+("`to."+t+"` field ["+JSON.stringify(r)+"]. Please separate it out to the ")+("`to."+n+"` field. Alternatively you may provide the full path as ")+'a string in and the router will parse it for you.'}function DS(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function ih(e,t){let n=DS(e);return t?n.map((r,s)=>s===n.length-1?r.pathname:r.pathnameBase):n.map(r=>r.pathnameBase)}function oh(e,t,n,r){r===void 0&&(r=!1);let s;typeof e=="string"?s=Ws(e):(s=Ot({},e),tt(!s.pathname||!s.pathname.includes("?"),zp("?","pathname","search",s)),tt(!s.pathname||!s.pathname.includes("#"),zp("#","pathname","hash",s)),tt(!s.search||!s.search.includes("#"),zp("#","search","hash",s)));let i=e===""||s.pathname==="",o=i?"/":s.pathname,a;if(o==null)a=n;else{let f=t.length-1;if(!r&&o.startsWith("..")){let h=o.split("/");for(;h[0]==="..";)h.shift(),f-=1;s.pathname=h.join("/")}a=f>=0?t[f]:"/"}let c=cO(s,a),u=o&&o!=="/"&&o.endsWith("/"),d=(i||o===".")&&n.endsWith("/");return!c.pathname.endsWith("/")&&(u||d)&&(c.pathname+="/"),c}const Ts=e=>e.join("/").replace(/\/\/+/g,"/"),dO=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),fO=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,hO=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;class Qy{constructor(t,n,r,s){s===void 0&&(s=!1),this.status=t,this.statusText=n||"",this.internal=s,r instanceof Error?(this.data=r.toString(),this.error=r):this.data=r}}function ah(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const IS=["post","put","patch","delete"],pO=new Set(IS),mO=["get",...IS],gO=new Set(mO),yO=new Set([301,302,303,307,308]),vO=new Set([307,308]),$p={state:"idle",location:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},xO={state:"idle",data:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},wl={state:"unblocked",proceed:void 0,reset:void 0,location:void 0},Jy=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,wO=e=>({hasErrorBoundary:!!e.hasErrorBoundary}),MS="remix-router-transitions";function bO(e){const t=e.window?e.window:typeof window<"u"?window:void 0,n=typeof t<"u"&&typeof t.document<"u"&&typeof t.document.createElement<"u",r=!n;tt(e.routes.length>0,"You must provide a non-empty routes array to createRouter");let s;if(e.mapRouteProperties)s=e.mapRouteProperties;else if(e.detectErrorBoundary){let V=e.detectErrorBoundary;s=H=>({hasErrorBoundary:V(H)})}else s=wO;let i={},o=bc(e.routes,s,void 0,i),a,c=e.basename||"/",u=e.unstable_dataStrategy||jO,d=e.unstable_patchRoutesOnMiss,f=Ot({v7_fetcherPersist:!1,v7_normalizeFormMethod:!1,v7_partialHydration:!1,v7_prependBasename:!1,v7_relativeSplatPath:!1,v7_skipActionErrorRevalidation:!1},e.future),h=null,p=new Set,x=null,m=null,w=null,y=e.hydrationData!=null,v=Bi(o,e.history.location,c),b=null;if(v==null&&!d){let V=wn(404,{pathname:e.history.location.pathname}),{matches:H,route:q}=Rw(o);v=H,b={[q.id]:V}}v&&d&&!e.hydrationData&&fp(v,o,e.history.location.pathname).active&&(v=null);let _;if(!v)_=!1,v=[];else if(v.some(V=>V.route.lazy))_=!1;else if(!v.some(V=>V.route.loader))_=!0;else if(f.v7_partialHydration){let V=e.hydrationData?e.hydrationData.loaderData:null,H=e.hydrationData?e.hydrationData.errors:null,q=ne=>ne.route.loader?typeof ne.route.loader=="function"&&ne.route.loader.hydrate===!0?!1:V&&V[ne.route.id]!==void 0||H&&H[ne.route.id]!==void 0:!0;if(H){let ne=v.findIndex(be=>H[be.route.id]!==void 0);_=v.slice(0,ne+1).every(q)}else _=v.every(q)}else _=e.hydrationData!=null;let C,j={historyAction:e.history.action,location:e.history.location,matches:v,initialized:_,navigation:$p,restoreScrollPosition:e.hydrationData!=null?!1:null,preventScrollReset:!1,revalidation:"idle",loaderData:e.hydrationData&&e.hydrationData.loaderData||{},actionData:e.hydrationData&&e.hydrationData.actionData||null,errors:e.hydrationData&&e.hydrationData.errors||b,fetchers:new Map,blockers:new Map},T=Ht.Pop,R=!1,A,D=!1,G=new Map,N=null,F=!1,S=!1,U=[],J=[],z=new Map,W=0,I=-1,X=new Map,$=new Set,B=new Map,he=new Map,se=new Set,ie=new Map,De=new Map,pe=new Map,we=!1;function Te(){if(h=e.history.listen(V=>{let{action:H,location:q,delta:ne}=V;if(we){we=!1;return}co(De.size===0||ne!=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 be=bu({currentLocation:j.location,nextLocation:q,historyAction:H});if(be&&ne!=null){we=!0,e.history.go(ne*-1),Ao(be,{state:"blocked",location:q,proceed(){Ao(be,{state:"proceeding",proceed:void 0,reset:void 0,location:q}),e.history.go(ne)},reset(){let Ae=new Map(j.blockers);Ae.set(be,wl),Re({blockers:Ae})}});return}return Z(H,q)}),n){zO(t,G);let V=()=>$O(t,G);t.addEventListener("pagehide",V),N=()=>t.removeEventListener("pagehide",V)}return j.initialized||Z(Ht.Pop,j.location,{initialHydration:!0}),C}function ze(){h&&h(),N&&N(),p.clear(),A&&A.abort(),j.fetchers.forEach((V,H)=>Kt(H)),j.blockers.forEach((V,H)=>wu(H))}function Ie(V){return p.add(V),()=>p.delete(V)}function Re(V,H){H===void 0&&(H={}),j=Ot({},j,V);let q=[],ne=[];f.v7_fetcherPersist&&j.fetchers.forEach((be,Ae)=>{be.state==="idle"&&(se.has(Ae)?ne.push(Ae):q.push(Ae))}),[...p].forEach(be=>be(j,{deletedFetchers:ne,unstable_viewTransitionOpts:H.viewTransitionOpts,unstable_flushSync:H.flushSync===!0})),f.v7_fetcherPersist&&(q.forEach(be=>j.fetchers.delete(be)),ne.forEach(be=>Kt(be)))}function st(V,H,q){var ne,be;let{flushSync:Ae}=q===void 0?{}:q,Be=j.actionData!=null&&j.navigation.formMethod!=null&&wr(j.navigation.formMethod)&&j.navigation.state==="loading"&&((ne=V.state)==null?void 0:ne._isRedirect)!==!0,fe;H.actionData?Object.keys(H.actionData).length>0?fe=H.actionData:fe=null:Be?fe=j.actionData:fe=null;let qe=H.loaderData?Tw(j.loaderData,H.loaderData,H.matches||[],H.errors):j.loaderData,Fe=j.blockers;Fe.size>0&&(Fe=new Map(Fe),Fe.forEach((mt,xt)=>Fe.set(xt,wl)));let $e=R===!0||j.navigation.formMethod!=null&&wr(j.navigation.formMethod)&&((be=V.state)==null?void 0:be._isRedirect)!==!0;a&&(o=a,a=void 0),F||T===Ht.Pop||(T===Ht.Push?e.history.push(V,V.state):T===Ht.Replace&&e.history.replace(V,V.state));let yt;if(T===Ht.Pop){let mt=G.get(j.location.pathname);mt&&mt.has(V.pathname)?yt={currentLocation:j.location,nextLocation:V}:G.has(V.pathname)&&(yt={currentLocation:V,nextLocation:j.location})}else if(D){let mt=G.get(j.location.pathname);mt?mt.add(V.pathname):(mt=new Set([V.pathname]),G.set(j.location.pathname,mt)),yt={currentLocation:j.location,nextLocation:V}}Re(Ot({},H,{actionData:fe,loaderData:qe,historyAction:T,location:V,initialized:!0,navigation:$p,revalidation:"idle",restoreScrollPosition:a0(V,H.matches||j.matches),preventScrollReset:$e,blockers:Fe}),{viewTransitionOpts:yt,flushSync:Ae===!0}),T=Ht.Pop,R=!1,D=!1,F=!1,S=!1,U=[],J=[]}async function E(V,H){if(typeof V=="number"){e.history.go(V);return}let q=dg(j.location,j.matches,c,f.v7_prependBasename,V,f.v7_relativeSplatPath,H==null?void 0:H.fromRouteId,H==null?void 0:H.relative),{path:ne,submission:be,error:Ae}=_w(f.v7_normalizeFormMethod,!1,q,H),Be=j.location,fe=wc(j.location,ne,H&&H.state);fe=Ot({},fe,e.history.encodeLocation(fe));let qe=H&&H.replace!=null?H.replace:void 0,Fe=Ht.Push;qe===!0?Fe=Ht.Replace:qe===!1||be!=null&&wr(be.formMethod)&&be.formAction===j.location.pathname+j.location.search&&(Fe=Ht.Replace);let $e=H&&"preventScrollReset"in H?H.preventScrollReset===!0:void 0,yt=(H&&H.unstable_flushSync)===!0,mt=bu({currentLocation:Be,nextLocation:fe,historyAction:Fe});if(mt){Ao(mt,{state:"blocked",location:fe,proceed(){Ao(mt,{state:"proceeding",proceed:void 0,reset:void 0,location:fe}),E(V,H)},reset(){let xt=new Map(j.blockers);xt.set(mt,wl),Re({blockers:xt})}});return}return await Z(Fe,fe,{submission:be,pendingError:Ae,preventScrollReset:$e,replace:H&&H.replace,enableViewTransition:H&&H.unstable_viewTransition,flushSync:yt})}function ee(){if(Ye(),Re({revalidation:"loading"}),j.navigation.state!=="submitting"){if(j.navigation.state==="idle"){Z(j.historyAction,j.location,{startUninterruptedRevalidation:!0});return}Z(T||j.historyAction,j.navigation.location,{overrideNavigation:j.navigation})}}async function Z(V,H,q){A&&A.abort(),A=null,T=V,F=(q&&q.startUninterruptedRevalidation)===!0,pP(j.location,j.matches),R=(q&&q.preventScrollReset)===!0,D=(q&&q.enableViewTransition)===!0;let ne=a||o,be=q&&q.overrideNavigation,Ae=Bi(ne,H,c),Be=(q&&q.flushSync)===!0,fe=fp(Ae,ne,H.pathname);if(fe.active&&fe.matches&&(Ae=fe.matches),!Ae){let{error:ht,notFoundMatches:nn,route:Wt}=Oo(H.pathname);st(H,{matches:nn,loaderData:{},errors:{[Wt.id]:ht}},{flushSync:Be});return}if(j.initialized&&!S&&AO(j.location,H)&&!(q&&q.submission&&wr(q.submission.formMethod))){st(H,{matches:Ae},{flushSync:Be});return}A=new AbortController;let qe=Fo(e.history,H,A.signal,q&&q.submission),Fe;if(q&&q.pendingError)Fe=[oa(Ae).route.id,{type:wt.error,error:q.pendingError}];else if(q&&q.submission&&wr(q.submission.formMethod)){let ht=await O(qe,H,q.submission,Ae,fe.active,{replace:q.replace,flushSync:Be});if(ht.shortCircuited)return;if(ht.pendingActionResult){let[nn,Wt]=ht.pendingActionResult;if($n(Wt)&&ah(Wt.error)&&Wt.error.status===404){A=null,st(H,{matches:ht.matches,loaderData:{},errors:{[nn]:Wt.error}});return}}Ae=ht.matches||Ae,Fe=ht.pendingActionResult,be=Up(H,q.submission),Be=!1,fe.active=!1,qe=Fo(e.history,qe.url,qe.signal)}let{shortCircuited:$e,matches:yt,loaderData:mt,errors:xt}=await k(qe,H,Ae,fe.active,be,q&&q.submission,q&&q.fetcherSubmission,q&&q.replace,q&&q.initialHydration===!0,Be,Fe);$e||(A=null,st(H,Ot({matches:yt||Ae},Pw(Fe),{loaderData:mt,errors:xt})))}async function O(V,H,q,ne,be,Ae){Ae===void 0&&(Ae={}),Ye();let Be=LO(H,q);if(Re({navigation:Be},{flushSync:Ae.flushSync===!0}),be){let Fe=await _u(ne,H.pathname,V.signal);if(Fe.type==="aborted")return{shortCircuited:!0};if(Fe.type==="error"){let{boundaryId:$e,error:yt}=$r(H.pathname,Fe);return{matches:Fe.partialMatches,pendingActionResult:[$e,{type:wt.error,error:yt}]}}else if(Fe.matches)ne=Fe.matches;else{let{notFoundMatches:$e,error:yt,route:mt}=Oo(H.pathname);return{matches:$e,pendingActionResult:[mt.id,{type:wt.error,error:yt}]}}}let fe,qe=Il(ne,H);if(!qe.route.action&&!qe.route.lazy)fe={type:wt.error,error:wn(405,{method:V.method,pathname:H.pathname,routeId:qe.route.id})};else if(fe=(await te("action",V,[qe],ne))[0],V.signal.aborted)return{shortCircuited:!0};if(Gi(fe)){let Fe;return Ae&&Ae.replace!=null?Fe=Ae.replace:Fe=jw(fe.response.headers.get("Location"),new URL(V.url),c)===j.location.pathname+j.location.search,await Q(V,fe,{submission:q,replace:Fe}),{shortCircuited:!0}}if(Ki(fe))throw wn(400,{type:"defer-action"});if($n(fe)){let Fe=oa(ne,qe.route.id);return(Ae&&Ae.replace)!==!0&&(T=Ht.Push),{matches:ne,pendingActionResult:[Fe.route.id,fe]}}return{matches:ne,pendingActionResult:[qe.route.id,fe]}}async function k(V,H,q,ne,be,Ae,Be,fe,qe,Fe,$e){let yt=be||Up(H,Ae),mt=Ae||Be||Dw(yt),xt=!F&&(!f.v7_partialHydration||!qe);if(ne){if(xt){let Ft=P($e);Re(Ot({navigation:yt},Ft!==void 0?{actionData:Ft}:{}),{flushSync:Fe})}let Je=await _u(q,H.pathname,V.signal);if(Je.type==="aborted")return{shortCircuited:!0};if(Je.type==="error"){let{boundaryId:Ft,error:Mn}=$r(H.pathname,Je);return{matches:Je.partialMatches,loaderData:{},errors:{[Ft]:Mn}}}else if(Je.matches)q=Je.matches;else{let{error:Ft,notFoundMatches:Mn,route:Nt}=Oo(H.pathname);return{matches:Mn,loaderData:{},errors:{[Nt.id]:Ft}}}}let ht=a||o,[nn,Wt]=Sw(e.history,j,q,mt,H,f.v7_partialHydration&&qe===!0,f.v7_skipActionErrorRevalidation,S,U,J,se,B,$,ht,c,$e);if(Xs(Je=>!(q&&q.some(Ft=>Ft.route.id===Je))||nn&&nn.some(Ft=>Ft.route.id===Je)),I=++W,nn.length===0&&Wt.length===0){let Je=ps();return st(H,Ot({matches:q,loaderData:{},errors:$e&&$n($e[1])?{[$e[0]]:$e[1].error}:null},Pw($e),Je?{fetchers:new Map(j.fetchers)}:{}),{flushSync:Fe}),{shortCircuited:!0}}if(xt){let Je={};if(!ne){Je.navigation=yt;let Ft=P($e);Ft!==void 0&&(Je.actionData=Ft)}Wt.length>0&&(Je.fetchers=M(Wt)),Re(Je,{flushSync:Fe})}Wt.forEach(Je=>{z.has(Je.key)&<(Je.key),Je.controller&&z.set(Je.key,Je.controller)});let dl=()=>Wt.forEach(Je=>lt(Je.key));A&&A.signal.addEventListener("abort",dl);let{loaderResults:Qs,fetcherResults:Do}=await ge(j.matches,q,nn,Wt,V);if(V.signal.aborted)return{shortCircuited:!0};A&&A.signal.removeEventListener("abort",dl),Wt.forEach(Je=>z.delete(Je.key));let Io=Aw([...Qs,...Do]);if(Io){if(Io.idx>=nn.length){let Je=Wt[Io.idx-nn.length].key;$.add(Je)}return await Q(V,Io.result,{replace:fe}),{shortCircuited:!0}}let{loaderData:Mo,errors:Ur}=Nw(j,q,nn,Qs,$e,Wt,Do,ie);ie.forEach((Je,Ft)=>{Je.subscribe(Mn=>{(Mn||Je.done)&&ie.delete(Ft)})}),f.v7_partialHydration&&qe&&j.errors&&Object.entries(j.errors).filter(Je=>{let[Ft]=Je;return!nn.some(Mn=>Mn.route.id===Ft)}).forEach(Je=>{let[Ft,Mn]=Je;Ur=Object.assign(Ur||{},{[Ft]:Mn})});let Su=ps(),ku=rr(I),Cu=Su||ku||Wt.length>0;return Ot({matches:q,loaderData:Mo,errors:Ur},Cu?{fetchers:new Map(j.fetchers)}:{})}function P(V){if(V&&!$n(V[1]))return{[V[0]]:V[1].data};if(j.actionData)return Object.keys(j.actionData).length===0?null:j.actionData}function M(V){return V.forEach(H=>{let q=j.fetchers.get(H.key),ne=bl(void 0,q?q.data:void 0);j.fetchers.set(H.key,ne)}),new Map(j.fetchers)}function K(V,H,q,ne){if(r)throw new Error("router.fetch() was called during the server render, but it shouldn't be. You are likely calling a useFetcher() method in the body of your component. Try moving it to a useEffect or a callback.");z.has(V)&<(V);let be=(ne&&ne.unstable_flushSync)===!0,Ae=a||o,Be=dg(j.location,j.matches,c,f.v7_prependBasename,q,f.v7_relativeSplatPath,H,ne==null?void 0:ne.relative),fe=Bi(Ae,Be,c),qe=fp(fe,Ae,Be);if(qe.active&&qe.matches&&(fe=qe.matches),!fe){Et(V,H,wn(404,{pathname:Be}),{flushSync:be});return}let{path:Fe,submission:$e,error:yt}=_w(f.v7_normalizeFormMethod,!0,Be,ne);if(yt){Et(V,H,yt,{flushSync:be});return}let mt=Il(fe,Fe);if(R=(ne&&ne.preventScrollReset)===!0,$e&&wr($e.formMethod)){L(V,H,Fe,mt,fe,qe.active,be,$e);return}B.set(V,{routeId:H,path:Fe}),Y(V,H,Fe,mt,fe,qe.active,be,$e)}async function L(V,H,q,ne,be,Ae,Be,fe){Ye(),B.delete(V);function qe(Nt){if(!Nt.route.action&&!Nt.route.lazy){let ms=wn(405,{method:fe.formMethod,pathname:q,routeId:H});return Et(V,H,ms,{flushSync:Be}),!0}return!1}if(!Ae&&qe(ne))return;let Fe=j.fetchers.get(V);Ue(V,FO(fe,Fe),{flushSync:Be});let $e=new AbortController,yt=Fo(e.history,q,$e.signal,fe);if(Ae){let Nt=await _u(be,q,yt.signal);if(Nt.type==="aborted")return;if(Nt.type==="error"){let{error:ms}=$r(q,Nt);Et(V,H,ms,{flushSync:Be});return}else if(Nt.matches){if(be=Nt.matches,ne=Il(be,q),qe(ne))return}else{Et(V,H,wn(404,{pathname:q}),{flushSync:Be});return}}z.set(V,$e);let mt=W,ht=(await te("action",yt,[ne],be))[0];if(yt.signal.aborted){z.get(V)===$e&&z.delete(V);return}if(f.v7_fetcherPersist&&se.has(V)){if(Gi(ht)||$n(ht)){Ue(V,ni(void 0));return}}else{if(Gi(ht))if(z.delete(V),I>mt){Ue(V,ni(void 0));return}else return $.add(V),Ue(V,bl(fe)),Q(yt,ht,{fetcherSubmission:fe});if($n(ht)){Et(V,H,ht.error);return}}if(Ki(ht))throw wn(400,{type:"defer-action"});let nn=j.navigation.location||j.location,Wt=Fo(e.history,nn,$e.signal),dl=a||o,Qs=j.navigation.state!=="idle"?Bi(dl,j.navigation.location,c):j.matches;tt(Qs,"Didn't find any matches after fetcher action");let Do=++W;X.set(V,Do);let Io=bl(fe,ht.data);j.fetchers.set(V,Io);let[Mo,Ur]=Sw(e.history,j,Qs,fe,nn,!1,f.v7_skipActionErrorRevalidation,S,U,J,se,B,$,dl,c,[ne.route.id,ht]);Ur.filter(Nt=>Nt.key!==V).forEach(Nt=>{let ms=Nt.key,l0=j.fetchers.get(ms),yP=bl(void 0,l0?l0.data:void 0);j.fetchers.set(ms,yP),z.has(ms)&<(ms),Nt.controller&&z.set(ms,Nt.controller)}),Re({fetchers:new Map(j.fetchers)});let Su=()=>Ur.forEach(Nt=>lt(Nt.key));$e.signal.addEventListener("abort",Su);let{loaderResults:ku,fetcherResults:Cu}=await ge(j.matches,Qs,Mo,Ur,Wt);if($e.signal.aborted)return;$e.signal.removeEventListener("abort",Su),X.delete(V),z.delete(V),Ur.forEach(Nt=>z.delete(Nt.key));let Je=Aw([...ku,...Cu]);if(Je){if(Je.idx>=Mo.length){let Nt=Ur[Je.idx-Mo.length].key;$.add(Nt)}return Q(Wt,Je.result)}let{loaderData:Ft,errors:Mn}=Nw(j,j.matches,Mo,ku,void 0,Ur,Cu,ie);if(j.fetchers.has(V)){let Nt=ni(ht.data);j.fetchers.set(V,Nt)}rr(Do),j.navigation.state==="loading"&&Do>I?(tt(T,"Expected pending action"),A&&A.abort(),st(j.navigation.location,{matches:Qs,loaderData:Ft,errors:Mn,fetchers:new Map(j.fetchers)})):(Re({errors:Mn,loaderData:Tw(j.loaderData,Ft,Qs,Mn),fetchers:new Map(j.fetchers)}),S=!1)}async function Y(V,H,q,ne,be,Ae,Be,fe){let qe=j.fetchers.get(V);Ue(V,bl(fe,qe?qe.data:void 0),{flushSync:Be});let Fe=new AbortController,$e=Fo(e.history,q,Fe.signal);if(Ae){let ht=await _u(be,q,$e.signal);if(ht.type==="aborted")return;if(ht.type==="error"){let{error:nn}=$r(q,ht);Et(V,H,nn,{flushSync:Be});return}else if(ht.matches)be=ht.matches,ne=Il(be,q);else{Et(V,H,wn(404,{pathname:q}),{flushSync:Be});return}}z.set(V,Fe);let yt=W,xt=(await te("loader",$e,[ne],be))[0];if(Ki(xt)&&(xt=await US(xt,$e.signal,!0)||xt),z.get(V)===Fe&&z.delete(V),!$e.signal.aborted){if(se.has(V)){Ue(V,ni(void 0));return}if(Gi(xt))if(I>yt){Ue(V,ni(void 0));return}else{$.add(V),await Q($e,xt);return}if($n(xt)){Et(V,H,xt.error);return}tt(!Ki(xt),"Unhandled fetcher deferred data"),Ue(V,ni(xt.data))}}async function Q(V,H,q){let{submission:ne,fetcherSubmission:be,replace:Ae}=q===void 0?{}:q;H.response.headers.has("X-Remix-Revalidate")&&(S=!0);let Be=H.response.headers.get("Location");tt(Be,"Expected a Location header on the redirect Response"),Be=jw(Be,new URL(V.url),c);let fe=wc(j.location,Be,{_isRedirect:!0});if(n){let xt=!1;if(H.response.headers.has("X-Remix-Reload-Document"))xt=!0;else if(Jy.test(Be)){const ht=e.history.createURL(Be);xt=ht.origin!==t.location.origin||qa(ht.pathname,c)==null}if(xt){Ae?t.location.replace(Be):t.location.assign(Be);return}}A=null;let qe=Ae===!0?Ht.Replace:Ht.Push,{formMethod:Fe,formAction:$e,formEncType:yt}=j.navigation;!ne&&!be&&Fe&&$e&&yt&&(ne=Dw(j.navigation));let mt=ne||be;if(vO.has(H.response.status)&&mt&&wr(mt.formMethod))await Z(qe,fe,{submission:Ot({},mt,{formAction:Be}),preventScrollReset:R});else{let xt=Up(fe,ne);await Z(qe,fe,{overrideNavigation:xt,fetcherSubmission:be,preventScrollReset:R})}}async function te(V,H,q,ne){try{let be=await EO(u,V,H,q,ne,i,s);return await Promise.all(be.map((Ae,Be)=>{if(DO(Ae)){let fe=Ae.result;return{type:wt.redirect,response:PO(fe,H,q[Be].route.id,ne,c,f.v7_relativeSplatPath)}}return TO(Ae)}))}catch(be){return q.map(()=>({type:wt.error,error:be}))}}async function ge(V,H,q,ne,be){let[Ae,...Be]=await Promise.all([q.length?te("loader",be,q,H):[],...ne.map(fe=>{if(fe.matches&&fe.match&&fe.controller){let qe=Fo(e.history,fe.path,fe.controller.signal);return te("loader",qe,[fe.match],fe.matches).then(Fe=>Fe[0])}else return Promise.resolve({type:wt.error,error:wn(404,{pathname:fe.path})})})]);return await Promise.all([Ow(V,q,Ae,Ae.map(()=>be.signal),!1,j.loaderData),Ow(V,ne.map(fe=>fe.match),Be,ne.map(fe=>fe.controller?fe.controller.signal:null),!0)]),{loaderResults:Ae,fetcherResults:Be}}function Ye(){S=!0,U.push(...Xs()),B.forEach((V,H)=>{z.has(H)&&(J.push(H),lt(H))})}function Ue(V,H,q){q===void 0&&(q={}),j.fetchers.set(V,H),Re({fetchers:new Map(j.fetchers)},{flushSync:(q&&q.flushSync)===!0})}function Et(V,H,q,ne){ne===void 0&&(ne={});let be=oa(j.matches,H);Kt(V),Re({errors:{[be.route.id]:q},fetchers:new Map(j.fetchers)},{flushSync:(ne&&ne.flushSync)===!0})}function nr(V){return f.v7_fetcherPersist&&(he.set(V,(he.get(V)||0)+1),se.has(V)&&se.delete(V)),j.fetchers.get(V)||xO}function Kt(V){let H=j.fetchers.get(V);z.has(V)&&!(H&&H.state==="loading"&&X.has(V))&<(V),B.delete(V),X.delete(V),$.delete(V),se.delete(V),j.fetchers.delete(V)}function fs(V){if(f.v7_fetcherPersist){let H=(he.get(V)||0)-1;H<=0?(he.delete(V),se.add(V)):he.set(V,H)}else Kt(V);Re({fetchers:new Map(j.fetchers)})}function lt(V){let H=z.get(V);tt(H,"Expected fetch controller: "+V),H.abort(),z.delete(V)}function hs(V){for(let H of V){let q=nr(H),ne=ni(q.data);j.fetchers.set(H,ne)}}function ps(){let V=[],H=!1;for(let q of $){let ne=j.fetchers.get(q);tt(ne,"Expected fetcher: "+q),ne.state==="loading"&&($.delete(q),V.push(q),H=!0)}return hs(V),H}function rr(V){let H=[];for(let[q,ne]of X)if(ne0}function xu(V,H){let q=j.blockers.get(V)||wl;return De.get(V)!==H&&De.set(V,H),q}function wu(V){j.blockers.delete(V),De.delete(V)}function Ao(V,H){let q=j.blockers.get(V)||wl;tt(q.state==="unblocked"&&H.state==="blocked"||q.state==="blocked"&&H.state==="blocked"||q.state==="blocked"&&H.state==="proceeding"||q.state==="blocked"&&H.state==="unblocked"||q.state==="proceeding"&&H.state==="unblocked","Invalid blocker state transition: "+q.state+" -> "+H.state);let ne=new Map(j.blockers);ne.set(V,H),Re({blockers:ne})}function bu(V){let{currentLocation:H,nextLocation:q,historyAction:ne}=V;if(De.size===0)return;De.size>1&&co(!1,"A router only supports one blocker at a time");let be=Array.from(De.entries()),[Ae,Be]=be[be.length-1],fe=j.blockers.get(Ae);if(!(fe&&fe.state==="proceeding")&&Be({currentLocation:H,nextLocation:q,historyAction:ne}))return Ae}function Oo(V){let H=wn(404,{pathname:V}),q=a||o,{matches:ne,route:be}=Rw(q);return Xs(),{notFoundMatches:ne,route:be,error:H}}function $r(V,H){return{boundaryId:oa(H.partialMatches).route.id,error:wn(400,{type:"route-discovery",pathname:V,message:H.error!=null&&"message"in H.error?H.error:String(H.error)})}}function Xs(V){let H=[];return ie.forEach((q,ne)=>{(!V||V(ne))&&(q.cancel(),H.push(ne),ie.delete(ne))}),H}function hP(V,H,q){if(x=V,w=H,m=q||null,!y&&j.navigation===$p){y=!0;let ne=a0(j.location,j.matches);ne!=null&&Re({restoreScrollPosition:ne})}return()=>{x=null,w=null,m=null}}function o0(V,H){return m&&m(V,H.map(ne=>qA(ne,j.loaderData)))||V.key}function pP(V,H){if(x&&w){let q=o0(V,H);x[q]=w()}}function a0(V,H){if(x){let q=o0(V,H),ne=x[q];if(typeof ne=="number")return ne}return null}function fp(V,H,q){if(d)if(V){let ne=V[V.length-1].route;if(ne.path&&(ne.path==="*"||ne.path.endsWith("/*")))return{active:!0,matches:yd(H,q,c,!0)}}else return{active:!0,matches:yd(H,q,c,!0)||[]};return{active:!1,matches:null}}async function _u(V,H,q){let ne=V,be=ne.length>0?ne[ne.length-1].route:null;for(;;){let Ae=a==null,Be=a||o;try{await CO(d,H,ne,Be,i,s,pe,q)}catch($e){return{type:"error",error:$e,partialMatches:ne}}finally{Ae&&(o=[...o])}if(q.aborted)return{type:"aborted"};let fe=Bi(Be,H,c),qe=!1;if(fe){let $e=fe[fe.length-1].route;if($e.index)return{type:"success",matches:fe};if($e.path&&$e.path.length>0)if($e.path==="*")qe=!0;else return{type:"success",matches:fe}}let Fe=yd(Be,H,c,!0);if(!Fe||ne.map($e=>$e.route.id).join("-")===Fe.map($e=>$e.route.id).join("-"))return{type:"success",matches:qe?fe:null};if(ne=Fe,be=ne[ne.length-1].route,be.path==="*")return{type:"success",matches:ne}}}function mP(V){i={},a=bc(V,s,void 0,i)}function gP(V,H){let q=a==null;FS(V,H,a||o,i,s),q&&(o=[...o],Re({}))}return C={get basename(){return c},get future(){return f},get state(){return j},get routes(){return o},get window(){return t},initialize:Te,subscribe:Ie,enableScrollRestoration:hP,navigate:E,fetch:K,revalidate:ee,createHref:V=>e.history.createHref(V),encodeLocation:V=>e.history.encodeLocation(V),getFetcher:nr,deleteFetcher:fs,dispose:ze,getBlocker:xu,deleteBlocker:wu,patchRoutes:gP,_internalFetchControllers:z,_internalActiveDeferreds:ie,_internalSetRoutes:mP},C}function _O(e){return e!=null&&("formData"in e&&e.formData!=null||"body"in e&&e.body!==void 0)}function dg(e,t,n,r,s,i,o,a){let c,u;if(o){c=[];for(let f of t)if(c.push(f),f.route.id===o){u=f;break}}else c=t,u=t[t.length-1];let d=oh(s||".",ih(c,i),qa(e.pathname,n)||e.pathname,a==="path");return s==null&&(d.search=e.search,d.hash=e.hash),(s==null||s===""||s===".")&&u&&u.route.index&&!ev(d.search)&&(d.search=d.search?d.search.replace(/^\?/,"?index&"):"?index"),r&&n!=="/"&&(d.pathname=d.pathname==="/"?n:Ts([n,d.pathname])),uo(d)}function _w(e,t,n,r){if(!r||!_O(r))return{path:n};if(r.formMethod&&!MO(r.formMethod))return{path:n,error:wn(405,{method:r.formMethod})};let s=()=>({path:n,error:wn(400,{type:"invalid-body"})}),i=r.formMethod||"get",o=e?i.toUpperCase():i.toLowerCase(),a=zS(n);if(r.body!==void 0){if(r.formEncType==="text/plain"){if(!wr(o))return s();let h=typeof r.body=="string"?r.body:r.body instanceof FormData||r.body instanceof URLSearchParams?Array.from(r.body.entries()).reduce((p,x)=>{let[m,w]=x;return""+p+m+"="+w+` +`},""):String(r.body);return{path:n,submission:{formMethod:o,formAction:a,formEncType:r.formEncType,formData:void 0,json:void 0,text:h}}}else if(r.formEncType==="application/json"){if(!wr(o))return s();try{let h=typeof r.body=="string"?JSON.parse(r.body):r.body;return{path:n,submission:{formMethod:o,formAction:a,formEncType:r.formEncType,formData:void 0,json:h,text:void 0}}}catch{return s()}}}tt(typeof FormData=="function","FormData is not available in this environment");let c,u;if(r.formData)c=fg(r.formData),u=r.formData;else if(r.body instanceof FormData)c=fg(r.body),u=r.body;else if(r.body instanceof URLSearchParams)c=r.body,u=Ew(c);else if(r.body==null)c=new URLSearchParams,u=new FormData;else try{c=new URLSearchParams(r.body),u=Ew(c)}catch{return s()}let d={formMethod:o,formAction:a,formEncType:r&&r.formEncType||"application/x-www-form-urlencoded",formData:u,json:void 0,text:void 0};if(wr(d.formMethod))return{path:n,submission:d};let f=Ws(n);return t&&f.search&&ev(f.search)&&c.append("index",""),f.search="?"+c,{path:uo(f),submission:d}}function SO(e,t){let n=e;if(t){let r=e.findIndex(s=>s.route.id===t);r>=0&&(n=e.slice(0,r))}return n}function Sw(e,t,n,r,s,i,o,a,c,u,d,f,h,p,x,m){let w=m?$n(m[1])?m[1].error:m[1].data:void 0,y=e.createURL(t.location),v=e.createURL(s),b=m&&$n(m[1])?m[0]:void 0,_=b?SO(n,b):n,C=m?m[1].statusCode:void 0,j=o&&C&&C>=400,T=_.filter((A,D)=>{let{route:G}=A;if(G.lazy)return!0;if(G.loader==null)return!1;if(i)return typeof G.loader!="function"||G.loader.hydrate?!0:t.loaderData[G.id]===void 0&&(!t.errors||t.errors[G.id]===void 0);if(kO(t.loaderData,t.matches[D],A)||c.some(S=>S===A.route.id))return!0;let N=t.matches[D],F=A;return kw(A,Ot({currentUrl:y,currentParams:N.params,nextUrl:v,nextParams:F.params},r,{actionResult:w,actionStatus:C,defaultShouldRevalidate:j?!1:a||y.pathname+y.search===v.pathname+v.search||y.search!==v.search||LS(N,F)}))}),R=[];return f.forEach((A,D)=>{if(i||!n.some(U=>U.route.id===A.routeId)||d.has(D))return;let G=Bi(p,A.path,x);if(!G){R.push({key:D,routeId:A.routeId,path:A.path,matches:null,match:null,controller:null});return}let N=t.fetchers.get(D),F=Il(G,A.path),S=!1;h.has(D)?S=!1:u.includes(D)?S=!0:N&&N.state!=="idle"&&N.data===void 0?S=a:S=kw(F,Ot({currentUrl:y,currentParams:t.matches[t.matches.length-1].params,nextUrl:v,nextParams:n[n.length-1].params},r,{actionResult:w,actionStatus:C,defaultShouldRevalidate:j?!1:a})),S&&R.push({key:D,routeId:A.routeId,path:A.path,matches:G,match:F,controller:new AbortController})}),[T,R]}function kO(e,t,n){let r=!t||n.route.id!==t.route.id,s=e[n.route.id]===void 0;return r||s}function LS(e,t){let n=e.route.path;return e.pathname!==t.pathname||n!=null&&n.endsWith("*")&&e.params["*"]!==t.params["*"]}function kw(e,t){if(e.route.shouldRevalidate){let n=e.route.shouldRevalidate(t);if(typeof n=="boolean")return n}return t.defaultShouldRevalidate}async function CO(e,t,n,r,s,i,o,a){let c=[t,...n.map(u=>u.route.id)].join("-");try{let u=o.get(c);u||(u=e({path:t,matches:n,patch:(d,f)=>{a.aborted||FS(d,f,r,s,i)}}),o.set(c,u)),u&&OO(u)&&await u}finally{o.delete(c)}}function FS(e,t,n,r,s){if(e){var i;let o=r[e];tt(o,"No route found to patch children into: routeId = "+e);let a=bc(t,s,[e,"patch",String(((i=o.children)==null?void 0:i.length)||"0")],r);o.children?o.children.push(...a):o.children=a}else{let o=bc(t,s,["patch",String(n.length||"0")],r);n.push(...o)}}async function Cw(e,t,n){if(!e.lazy)return;let r=await e.lazy();if(!e.lazy)return;let s=n[e.id];tt(s,"No route found in manifest");let i={};for(let o in r){let c=s[o]!==void 0&&o!=="hasErrorBoundary";co(!c,'Route "'+s.id+'" has a static property "'+o+'" defined but its lazy function is also returning a value for this property. '+('The lazy route property "'+o+'" will be ignored.')),!c&&!GA.has(o)&&(i[o]=r[o])}Object.assign(s,i),Object.assign(s,Ot({},t(s),{lazy:void 0}))}function jO(e){return Promise.all(e.matches.map(t=>t.resolve()))}async function EO(e,t,n,r,s,i,o,a){let c=r.reduce((f,h)=>f.add(h.route.id),new Set),u=new Set,d=await e({matches:s.map(f=>{let h=c.has(f.route.id);return Ot({},f,{shouldLoad:h,resolve:x=>(u.add(f.route.id),h?NO(t,n,f,i,o,x,a):Promise.resolve({type:wt.data,result:void 0}))})}),request:n,params:s[0].params,context:a});return s.forEach(f=>tt(u.has(f.route.id),'`match.resolve()` was not called for route id "'+f.route.id+'". You must call `match.resolve()` on every match passed to `dataStrategy` to ensure all routes are properly loaded.')),d.filter((f,h)=>c.has(s[h].route.id))}async function NO(e,t,n,r,s,i,o){let a,c,u=d=>{let f,h=new Promise((m,w)=>f=w);c=()=>f(),t.signal.addEventListener("abort",c);let p=m=>typeof d!="function"?Promise.reject(new Error("You cannot call the handler for a route which defines a boolean "+('"'+e+'" [routeId: '+n.route.id+"]"))):d({request:t,params:n.params,context:o},...m!==void 0?[m]:[]),x;return i?x=i(m=>p(m)):x=(async()=>{try{return{type:"data",result:await p()}}catch(m){return{type:"error",result:m}}})(),Promise.race([x,h])};try{let d=n.route[e];if(n.route.lazy)if(d){let f,[h]=await Promise.all([u(d).catch(p=>{f=p}),Cw(n.route,s,r)]);if(f!==void 0)throw f;a=h}else if(await Cw(n.route,s,r),d=n.route[e],d)a=await u(d);else if(e==="action"){let f=new URL(t.url),h=f.pathname+f.search;throw wn(405,{method:t.method,pathname:h,routeId:n.route.id})}else return{type:wt.data,result:void 0};else if(d)a=await u(d);else{let f=new URL(t.url),h=f.pathname+f.search;throw wn(404,{pathname:h})}tt(a.result!==void 0,"You defined "+(e==="action"?"an action":"a loader")+" for route "+('"'+n.route.id+"\" but didn't return anything from your `"+e+"` ")+"function. Please return a value or `null`.")}catch(d){return{type:wt.error,result:d}}finally{c&&t.signal.removeEventListener("abort",c)}return a}async function TO(e){let{result:t,type:n,status:r}=e;if($S(t)){let o;try{let a=t.headers.get("Content-Type");a&&/\bapplication\/json\b/.test(a)?t.body==null?o=null:o=await t.json():o=await t.text()}catch(a){return{type:wt.error,error:a}}return n===wt.error?{type:wt.error,error:new Qy(t.status,t.statusText,o),statusCode:t.status,headers:t.headers}:{type:wt.data,data:o,statusCode:t.status,headers:t.headers}}if(n===wt.error)return{type:wt.error,error:t,statusCode:ah(t)?t.status:r};if(IO(t)){var s,i;return{type:wt.deferred,deferredData:t,statusCode:(s=t.init)==null?void 0:s.status,headers:((i=t.init)==null?void 0:i.headers)&&new Headers(t.init.headers)}}return{type:wt.data,data:t,statusCode:r}}function PO(e,t,n,r,s,i){let o=e.headers.get("Location");if(tt(o,"Redirects returned/thrown from loaders/actions must have a Location header"),!Jy.test(o)){let a=r.slice(0,r.findIndex(c=>c.route.id===n)+1);o=dg(new URL(t.url),a,s,!0,o,i),e.headers.set("Location",o)}return e}function jw(e,t,n){if(Jy.test(e)){let r=e,s=r.startsWith("//")?new URL(t.protocol+r):new URL(r),i=qa(s.pathname,n)!=null;if(s.origin===t.origin&&i)return s.pathname+s.search+s.hash}return e}function Fo(e,t,n,r){let s=e.createURL(zS(t)).toString(),i={signal:n};if(r&&wr(r.formMethod)){let{formMethod:o,formEncType:a}=r;i.method=o.toUpperCase(),a==="application/json"?(i.headers=new Headers({"Content-Type":a}),i.body=JSON.stringify(r.json)):a==="text/plain"?i.body=r.text:a==="application/x-www-form-urlencoded"&&r.formData?i.body=fg(r.formData):i.body=r.formData}return new Request(s,i)}function fg(e){let t=new URLSearchParams;for(let[n,r]of e.entries())t.append(n,typeof r=="string"?r:r.name);return t}function Ew(e){let t=new FormData;for(let[n,r]of e.entries())t.append(n,r);return t}function RO(e,t,n,r,s,i){let o={},a=null,c,u=!1,d={},f=r&&$n(r[1])?r[1].error:void 0;return n.forEach((h,p)=>{let x=t[p].route.id;if(tt(!Gi(h),"Cannot handle redirect results in processLoaderData"),$n(h)){let m=h.error;f!==void 0&&(m=f,f=void 0),a=a||{};{let w=oa(e,x);a[w.route.id]==null&&(a[w.route.id]=m)}o[x]=void 0,u||(u=!0,c=ah(h.error)?h.error.status:500),h.headers&&(d[x]=h.headers)}else Ki(h)?(s.set(x,h.deferredData),o[x]=h.deferredData.data,h.statusCode!=null&&h.statusCode!==200&&!u&&(c=h.statusCode),h.headers&&(d[x]=h.headers)):(o[x]=h.data,h.statusCode&&h.statusCode!==200&&!u&&(c=h.statusCode),h.headers&&(d[x]=h.headers))}),f!==void 0&&r&&(a={[r[0]]:f},o[r[0]]=void 0),{loaderData:o,errors:a,statusCode:c||200,loaderHeaders:d}}function Nw(e,t,n,r,s,i,o,a){let{loaderData:c,errors:u}=RO(t,n,r,s,a);for(let d=0;dr.route.id===t)+1):[...e]).reverse().find(r=>r.route.hasErrorBoundary===!0)||e[0]}function Rw(e){let t=e.length===1?e[0]:e.find(n=>n.index||!n.path||n.path==="/")||{id:"__shim-error-route__"};return{matches:[{params:{},pathname:"",pathnameBase:"",route:t}],route:t}}function wn(e,t){let{pathname:n,routeId:r,method:s,type:i,message:o}=t===void 0?{}:t,a="Unknown Server Error",c="Unknown @remix-run/router error";return e===400?(a="Bad Request",i==="route-discovery"?c='Unable to match URL "'+n+'" - the `unstable_patchRoutesOnMiss()` '+(`function threw the following error: +`+o):s&&n&&r?c="You made a "+s+' request to "'+n+'" but '+('did not provide a `loader` for route "'+r+'", ')+"so there is no way to handle the request.":i==="defer-action"?c="defer() is not supported in actions":i==="invalid-body"&&(c="Unable to encode submission body")):e===403?(a="Forbidden",c='Route "'+r+'" does not match URL "'+n+'"'):e===404?(a="Not Found",c='No route matches URL "'+n+'"'):e===405&&(a="Method Not Allowed",s&&n&&r?c="You made a "+s.toUpperCase()+' request to "'+n+'" but '+('did not provide an `action` for route "'+r+'", ')+"so there is no way to handle the request.":s&&(c='Invalid request method "'+s.toUpperCase()+'"')),new Qy(e||500,a,new Error(c),!0)}function Aw(e){for(let t=e.length-1;t>=0;t--){let n=e[t];if(Gi(n))return{result:n,idx:t}}}function zS(e){let t=typeof e=="string"?Ws(e):e;return uo(Ot({},t,{hash:""}))}function AO(e,t){return e.pathname!==t.pathname||e.search!==t.search?!1:e.hash===""?t.hash!=="":e.hash===t.hash?!0:t.hash!==""}function OO(e){return typeof e=="object"&&e!=null&&"then"in e}function DO(e){return $S(e.result)&&yO.has(e.result.status)}function Ki(e){return e.type===wt.deferred}function $n(e){return e.type===wt.error}function Gi(e){return(e&&e.type)===wt.redirect}function IO(e){let t=e;return t&&typeof t=="object"&&typeof t.data=="object"&&typeof t.subscribe=="function"&&typeof t.cancel=="function"&&typeof t.resolveData=="function"}function $S(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.headers=="object"&&typeof e.body<"u"}function MO(e){return gO.has(e.toLowerCase())}function wr(e){return pO.has(e.toLowerCase())}async function Ow(e,t,n,r,s,i){for(let o=0;of.route.id===c.route.id),d=u!=null&&!LS(u,c)&&(i&&i[c.route.id])!==void 0;if(Ki(a)&&(s||d)){let f=r[o];tt(f,"Expected an AbortSignal for revalidating fetcher deferred result"),await US(a,f,s).then(h=>{h&&(n[o]=h||n[o])})}}}async function US(e,t,n){if(n===void 0&&(n=!1),!await e.deferredData.resolveData(t)){if(n)try{return{type:wt.data,data:e.deferredData.unwrappedData}}catch(s){return{type:wt.error,error:s}}return{type:wt.data,data:e.deferredData.data}}}function ev(e){return new URLSearchParams(e).getAll("index").some(t=>t==="")}function Il(e,t){let n=typeof t=="string"?Ws(t).search:t.search;if(e[e.length-1].route.index&&ev(n||""))return e[e.length-1];let r=DS(e);return r[r.length-1]}function Dw(e){let{formMethod:t,formAction:n,formEncType:r,text:s,formData:i,json:o}=e;if(!(!t||!n||!r)){if(s!=null)return{formMethod:t,formAction:n,formEncType:r,formData:void 0,json:void 0,text:s};if(i!=null)return{formMethod:t,formAction:n,formEncType:r,formData:i,json:void 0,text:void 0};if(o!==void 0)return{formMethod:t,formAction:n,formEncType:r,formData:void 0,json:o,text:void 0}}}function Up(e,t){return t?{state:"loading",location:e,formMethod:t.formMethod,formAction:t.formAction,formEncType:t.formEncType,formData:t.formData,json:t.json,text:t.text}:{state:"loading",location:e,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0}}function LO(e,t){return{state:"submitting",location:e,formMethod:t.formMethod,formAction:t.formAction,formEncType:t.formEncType,formData:t.formData,json:t.json,text:t.text}}function bl(e,t){return e?{state:"loading",formMethod:e.formMethod,formAction:e.formAction,formEncType:e.formEncType,formData:e.formData,json:e.json,text:e.text,data:t}:{state:"loading",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:t}}function FO(e,t){return{state:"submitting",formMethod:e.formMethod,formAction:e.formAction,formEncType:e.formEncType,formData:e.formData,json:e.json,text:e.text,data:t?t.data:void 0}}function ni(e){return{state:"idle",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:e}}function zO(e,t){try{let n=e.sessionStorage.getItem(MS);if(n){let r=JSON.parse(n);for(let[s,i]of Object.entries(r||{}))i&&Array.isArray(i)&&t.set(s,new Set(i||[]))}}catch{}}function $O(e,t){if(t.size>0){let n={};for(let[r,s]of t)n[r]=[...s];try{e.sessionStorage.setItem(MS,JSON.stringify(n))}catch(r){co(!1,"Failed to save applied view transitions in sessionStorage ("+r+").")}}}/** * React Router v6.25.1 * * Copyright (c) Remix Software Inc. @@ -57,7 +57,7 @@ Error generating stack: `+i.message+` * LICENSE.md file in the root directory of this source tree. * * @license MIT - */function ef(){return ef=Object.assign?Object.assign.bind():function(e){for(var t=1;t{a.current=!0}),g.useCallback(function(u,d){if(d===void 0&&(d={}),!a.current)return;if(typeof u=="number"){r.go(u);return}let f=ah(u,JSON.parse(o),i,d.relative==="path");e==null&&t!=="/"&&(f.pathname=f.pathname==="/"?t:Ns([t,f.pathname])),(d.replace?r.replace:r.push)(f,d.state,d)},[t,r,o,i,e])}const BO=g.createContext(null);function WO(e){let t=g.useContext(Ws).outlet;return t&&g.createElement(BO.Provider,{value:e},t)}function HS(e,t){let{relative:n}=t===void 0?{}:t,{future:r}=g.useContext(Ii),{matches:s}=g.useContext(Ws),{pathname:i}=Mr(),o=JSON.stringify(oh(s,r.v7_relativeSplatPath));return g.useMemo(()=>ah(e,JSON.parse(o),i,n==="path"),[e,o,i,n])}function HO(e,t,n,r){qa()||tt(!1);let{navigator:s}=g.useContext(Ii),{matches:i}=g.useContext(Ws),o=i[i.length-1],a=o?o.params:{};o&&o.pathname;let c=o?o.pathnameBase:"/";o&&o.route;let u=Mr(),d;d=u;let f=d.pathname||"/",h=f;if(c!=="/"){let m=c.replace(/^\//,"").split("/");h="/"+f.replace(/^\//,"").split("/").slice(m.length).join("/")}let p=Vi(e,{pathname:h});return qO(p&&p.map(m=>Object.assign({},m,{params:Object.assign({},a,m.params),pathname:Ns([c,s.encodeLocation?s.encodeLocation(m.pathname).pathname:m.pathname]),pathnameBase:m.pathnameBase==="/"?c:Ns([c,s.encodeLocation?s.encodeLocation(m.pathnameBase).pathname:m.pathnameBase])})),i,n,r)}function YO(){let e=eD(),t=lh(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,s={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"};return g.createElement(g.Fragment,null,g.createElement("h2",null,"Unexpected Application Error!"),g.createElement("h3",{style:{fontStyle:"italic"}},t),n?g.createElement("pre",{style:s},n):null,null)}const KO=g.createElement(YO,null);class GO extends g.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,n){return n.location!==t.location||n.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:n.error,location:n.location,revalidation:t.revalidation||n.revalidation}}componentDidCatch(t,n){console.error("React Router caught the following error during render",t,n)}render(){return this.state.error!==void 0?g.createElement(Ws.Provider,{value:this.props.routeContext},g.createElement(BS.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function ZO(e){let{routeContext:t,match:n,children:r}=e,s=g.useContext(ch);return s&&s.static&&s.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(s.staticContext._deepestRenderedBoundaryId=n.route.id),g.createElement(Ws.Provider,{value:t},r)}function qO(e,t,n,r){var s;if(t===void 0&&(t=[]),n===void 0&&(n=null),r===void 0&&(r=null),e==null){var i;if((i=n)!=null&&i.errors)e=n.matches;else return null}let o=e,a=(s=n)==null?void 0:s.errors;if(a!=null){let d=o.findIndex(f=>f.route.id&&(a==null?void 0:a[f.route.id])!==void 0);d>=0||tt(!1),o=o.slice(0,Math.min(o.length,d+1))}let c=!1,u=-1;if(n&&r&&r.v7_partialHydration)for(let d=0;d=0?o=o.slice(0,u+1):o=[o[0]];break}}}return o.reduceRight((d,f,h)=>{let p,x=!1,m=null,w=null;n&&(p=a&&f.route.id?a[f.route.id]:void 0,m=f.route.errorElement||KO,c&&(u<0&&h===0?(nD("route-fallback"),x=!0,w=null):u===h&&(x=!0,w=f.route.hydrateFallbackElement||null)));let y=t.concat(o.slice(0,h+1)),v=()=>{let b;return p?b=m:x?b=w:f.route.Component?b=g.createElement(f.route.Component,null):f.route.element?b=f.route.element:b=d,g.createElement(ZO,{match:f,routeContext:{outlet:d,matches:y,isDataRoute:n!=null},children:b})};return n&&(f.route.ErrorBoundary||f.route.errorElement||h===0)?g.createElement(GO,{location:n.location,revalidation:n.revalidation,component:m,error:p,children:v(),routeContext:{outlet:null,matches:y,isDataRoute:!0}}):v()},null)}var YS=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(YS||{}),tf=function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e}(tf||{});function XO(e){let t=g.useContext(ch);return t||tt(!1),t}function QO(e){let t=g.useContext(VS);return t||tt(!1),t}function JO(e){let t=g.useContext(Ws);return t||tt(!1),t}function KS(e){let t=JO(),n=t.matches[t.matches.length-1];return n.route.id||tt(!1),n.route.id}function eD(){var e;let t=g.useContext(BS),n=QO(tf.UseRouteError),r=KS(tf.UseRouteError);return t!==void 0?t:(e=n.errors)==null?void 0:e[r]}function tD(){let{router:e}=XO(YS.UseNavigateStable),t=KS(tf.UseNavigateStable),n=g.useRef(!1);return WS(()=>{n.current=!0}),g.useCallback(function(s,i){i===void 0&&(i={}),n.current&&(typeof s=="number"?e.navigate(s):e.navigate(s,ef({fromRouteId:t},i)))},[e,t])}const Iw={};function nD(e,t,n){Iw[e]||(Iw[e]=!0)}function GS(e){let{to:t,replace:n,state:r,relative:s}=e;qa()||tt(!1);let{future:i,static:o}=g.useContext(Ii),{matches:a}=g.useContext(Ws),{pathname:c}=Mr(),u=er(),d=ah(t,oh(a,i.v7_relativeSplatPath),c,s==="path"),f=JSON.stringify(d);return g.useEffect(()=>u(JSON.parse(f),{replace:n,state:r,relative:s}),[u,f,s,n,r]),null}function nv(e){return WO(e.context)}function rD(e){let{basename:t="/",children:n=null,location:r,navigationType:s=Wt.Pop,navigator:i,static:o=!1,future:a}=e;qa()&&tt(!1);let c=t.replace(/^\/*/,"/"),u=g.useMemo(()=>({basename:c,navigator:i,static:o,future:ef({v7_relativeSplatPath:!1},a)}),[c,a,i,o]);typeof r=="string"&&(r=Bs(r));let{pathname:d="/",search:f="",hash:h="",state:p=null,key:x="default"}=r,m=g.useMemo(()=>{let w=Za(d,c);return w==null?null:{location:{pathname:w,search:f,hash:h,state:p,key:x},navigationType:s}},[c,d,f,h,p,x,s]);return m==null?null:g.createElement(Ii.Provider,{value:u},g.createElement(tv.Provider,{children:n,value:m}))}new Promise(()=>{});function sD(e){let t={hasErrorBoundary:e.ErrorBoundary!=null||e.errorElement!=null};return e.Component&&Object.assign(t,{element:g.createElement(e.Component),Component:void 0}),e.HydrateFallback&&Object.assign(t,{hydrateFallbackElement:g.createElement(e.HydrateFallback),HydrateFallback:void 0}),e.ErrorBoundary&&Object.assign(t,{errorElement:g.createElement(e.ErrorBoundary),ErrorBoundary:void 0}),t}/** + */function Jd(){return Jd=Object.assign?Object.assign.bind():function(e){for(var t=1;t{a.current=!0}),g.useCallback(function(u,d){if(d===void 0&&(d={}),!a.current)return;if(typeof u=="number"){r.go(u);return}let f=oh(u,JSON.parse(o),i,d.relative==="path");e==null&&t!=="/"&&(f.pathname=f.pathname==="/"?t:Ts([t,f.pathname])),(d.replace?r.replace:r.push)(f,d.state,d)},[t,r,o,i,e])}const BO=g.createContext(null);function WO(e){let t=g.useContext(Hs).outlet;return t&&g.createElement(BO.Provider,{value:e},t)}function HS(e,t){let{relative:n}=t===void 0?{}:t,{future:r}=g.useContext(Mi),{matches:s}=g.useContext(Hs),{pathname:i}=Mr(),o=JSON.stringify(ih(s,r.v7_relativeSplatPath));return g.useMemo(()=>oh(e,JSON.parse(o),i,n==="path"),[e,o,i,n])}function HO(e,t,n,r){Xa()||tt(!1);let{navigator:s}=g.useContext(Mi),{matches:i}=g.useContext(Hs),o=i[i.length-1],a=o?o.params:{};o&&o.pathname;let c=o?o.pathnameBase:"/";o&&o.route;let u=Mr(),d;d=u;let f=d.pathname||"/",h=f;if(c!=="/"){let m=c.replace(/^\//,"").split("/");h="/"+f.replace(/^\//,"").split("/").slice(m.length).join("/")}let p=Bi(e,{pathname:h});return qO(p&&p.map(m=>Object.assign({},m,{params:Object.assign({},a,m.params),pathname:Ts([c,s.encodeLocation?s.encodeLocation(m.pathname).pathname:m.pathname]),pathnameBase:m.pathnameBase==="/"?c:Ts([c,s.encodeLocation?s.encodeLocation(m.pathnameBase).pathname:m.pathnameBase])})),i,n,r)}function YO(){let e=eD(),t=ah(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,s={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"};return g.createElement(g.Fragment,null,g.createElement("h2",null,"Unexpected Application Error!"),g.createElement("h3",{style:{fontStyle:"italic"}},t),n?g.createElement("pre",{style:s},n):null,null)}const KO=g.createElement(YO,null);class GO extends g.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,n){return n.location!==t.location||n.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:n.error,location:n.location,revalidation:t.revalidation||n.revalidation}}componentDidCatch(t,n){console.error("React Router caught the following error during render",t,n)}render(){return this.state.error!==void 0?g.createElement(Hs.Provider,{value:this.props.routeContext},g.createElement(BS.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function ZO(e){let{routeContext:t,match:n,children:r}=e,s=g.useContext(lh);return s&&s.static&&s.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(s.staticContext._deepestRenderedBoundaryId=n.route.id),g.createElement(Hs.Provider,{value:t},r)}function qO(e,t,n,r){var s;if(t===void 0&&(t=[]),n===void 0&&(n=null),r===void 0&&(r=null),e==null){var i;if((i=n)!=null&&i.errors)e=n.matches;else return null}let o=e,a=(s=n)==null?void 0:s.errors;if(a!=null){let d=o.findIndex(f=>f.route.id&&(a==null?void 0:a[f.route.id])!==void 0);d>=0||tt(!1),o=o.slice(0,Math.min(o.length,d+1))}let c=!1,u=-1;if(n&&r&&r.v7_partialHydration)for(let d=0;d=0?o=o.slice(0,u+1):o=[o[0]];break}}}return o.reduceRight((d,f,h)=>{let p,x=!1,m=null,w=null;n&&(p=a&&f.route.id?a[f.route.id]:void 0,m=f.route.errorElement||KO,c&&(u<0&&h===0?(nD("route-fallback"),x=!0,w=null):u===h&&(x=!0,w=f.route.hydrateFallbackElement||null)));let y=t.concat(o.slice(0,h+1)),v=()=>{let b;return p?b=m:x?b=w:f.route.Component?b=g.createElement(f.route.Component,null):f.route.element?b=f.route.element:b=d,g.createElement(ZO,{match:f,routeContext:{outlet:d,matches:y,isDataRoute:n!=null},children:b})};return n&&(f.route.ErrorBoundary||f.route.errorElement||h===0)?g.createElement(GO,{location:n.location,revalidation:n.revalidation,component:m,error:p,children:v(),routeContext:{outlet:null,matches:y,isDataRoute:!0}}):v()},null)}var YS=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(YS||{}),ef=function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e}(ef||{});function XO(e){let t=g.useContext(lh);return t||tt(!1),t}function QO(e){let t=g.useContext(VS);return t||tt(!1),t}function JO(e){let t=g.useContext(Hs);return t||tt(!1),t}function KS(e){let t=JO(),n=t.matches[t.matches.length-1];return n.route.id||tt(!1),n.route.id}function eD(){var e;let t=g.useContext(BS),n=QO(ef.UseRouteError),r=KS(ef.UseRouteError);return t!==void 0?t:(e=n.errors)==null?void 0:e[r]}function tD(){let{router:e}=XO(YS.UseNavigateStable),t=KS(ef.UseNavigateStable),n=g.useRef(!1);return WS(()=>{n.current=!0}),g.useCallback(function(s,i){i===void 0&&(i={}),n.current&&(typeof s=="number"?e.navigate(s):e.navigate(s,Jd({fromRouteId:t},i)))},[e,t])}const Iw={};function nD(e,t,n){Iw[e]||(Iw[e]=!0)}function GS(e){let{to:t,replace:n,state:r,relative:s}=e;Xa()||tt(!1);let{future:i,static:o}=g.useContext(Mi),{matches:a}=g.useContext(Hs),{pathname:c}=Mr(),u=er(),d=oh(t,ih(a,i.v7_relativeSplatPath),c,s==="path"),f=JSON.stringify(d);return g.useEffect(()=>u(JSON.parse(f),{replace:n,state:r,relative:s}),[u,f,s,n,r]),null}function nv(e){return WO(e.context)}function rD(e){let{basename:t="/",children:n=null,location:r,navigationType:s=Ht.Pop,navigator:i,static:o=!1,future:a}=e;Xa()&&tt(!1);let c=t.replace(/^\/*/,"/"),u=g.useMemo(()=>({basename:c,navigator:i,static:o,future:Jd({v7_relativeSplatPath:!1},a)}),[c,a,i,o]);typeof r=="string"&&(r=Ws(r));let{pathname:d="/",search:f="",hash:h="",state:p=null,key:x="default"}=r,m=g.useMemo(()=>{let w=qa(d,c);return w==null?null:{location:{pathname:w,search:f,hash:h,state:p,key:x},navigationType:s}},[c,d,f,h,p,x,s]);return m==null?null:g.createElement(Mi.Provider,{value:u},g.createElement(tv.Provider,{children:n,value:m}))}new Promise(()=>{});function sD(e){let t={hasErrorBoundary:e.ErrorBoundary!=null||e.errorElement!=null};return e.Component&&Object.assign(t,{element:g.createElement(e.Component),Component:void 0}),e.HydrateFallback&&Object.assign(t,{hydrateFallbackElement:g.createElement(e.HydrateFallback),HydrateFallback:void 0}),e.ErrorBoundary&&Object.assign(t,{errorElement:g.createElement(e.ErrorBoundary),ErrorBoundary:void 0}),t}/** * React Router DOM v6.25.1 * * Copyright (c) Remix Software Inc. @@ -66,7 +66,7 @@ Error generating stack: `+i.message+` * LICENSE.md file in the root directory of this source tree. * * @license MIT - */function bc(){return bc=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&(n[s]=e[s]);return n}function oD(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function aD(e,t){return e.button===0&&(!t||t==="_self")&&!oD(e)}function hg(e){return e===void 0&&(e=""),new URLSearchParams(typeof e=="string"||Array.isArray(e)||e instanceof URLSearchParams?e:Object.keys(e).reduce((t,n)=>{let r=e[n];return t.concat(Array.isArray(r)?r.map(s=>[n,s]):[[n,r]])},[]))}function lD(e,t){let n=hg(e);return t&&t.forEach((r,s)=>{n.has(s)||t.getAll(s).forEach(i=>{n.append(s,i)})}),n}const cD=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset","unstable_viewTransition"],uD="6";try{window.__reactRouterVersion=uD}catch{}function dD(e,t){return bO({basename:void 0,future:bc({},void 0,{v7_prependBasename:!0}),history:HA({window:void 0}),hydrationData:fD(),routes:e,mapRouteProperties:sD,unstable_dataStrategy:void 0,unstable_patchRoutesOnMiss:void 0,window:void 0}).initialize()}function fD(){var e;let t=(e=window)==null?void 0:e.__staticRouterHydrationData;return t&&t.errors&&(t=bc({},t,{errors:hD(t.errors)})),t}function hD(e){if(!e)return null;let t=Object.entries(e),n={};for(let[r,s]of t)if(s&&s.__type==="RouteErrorResponse")n[r]=new Qy(s.status,s.statusText,s.data,s.internal===!0);else if(s&&s.__type==="Error"){if(s.__subType){let i=window[s.__subType];if(typeof i=="function")try{let o=new i(s.message);o.stack="",n[r]=o}catch{}}if(n[r]==null){let i=new Error(s.message);i.stack="",n[r]=i}}else n[r]=s;return n}const pD=g.createContext({isTransitioning:!1}),mD=g.createContext(new Map),gD="startTransition",Mw=Nb[gD],yD="flushSync",Lw=WA[yD];function vD(e){Mw?Mw(e):e()}function bl(e){Lw?Lw(e):e()}class xD{constructor(){this.status="pending",this.promise=new Promise((t,n)=>{this.resolve=r=>{this.status==="pending"&&(this.status="resolved",t(r))},this.reject=r=>{this.status==="pending"&&(this.status="rejected",n(r))}})}}function wD(e){let{fallbackElement:t,router:n,future:r}=e,[s,i]=g.useState(n.state),[o,a]=g.useState(),[c,u]=g.useState({isTransitioning:!1}),[d,f]=g.useState(),[h,p]=g.useState(),[x,m]=g.useState(),w=g.useRef(new Map),{v7_startTransition:y}=r||{},v=g.useCallback(R=>{y?vD(R):R()},[y]),b=g.useCallback((R,A)=>{let{deletedFetchers:D,unstable_flushSync:G,unstable_viewTransitionOpts:N}=A;D.forEach(S=>w.current.delete(S)),R.fetchers.forEach((S,U)=>{S.data!==void 0&&w.current.set(U,S.data)});let F=n.window==null||n.window.document==null||typeof n.window.document.startViewTransition!="function";if(!N||F){G?bl(()=>i(R)):v(()=>i(R));return}if(G){bl(()=>{h&&(d&&d.resolve(),h.skipTransition()),u({isTransitioning:!0,flushSync:!0,currentLocation:N.currentLocation,nextLocation:N.nextLocation})});let S=n.window.document.startViewTransition(()=>{bl(()=>i(R))});S.finished.finally(()=>{bl(()=>{f(void 0),p(void 0),a(void 0),u({isTransitioning:!1})})}),bl(()=>p(S));return}h?(d&&d.resolve(),h.skipTransition(),m({state:R,currentLocation:N.currentLocation,nextLocation:N.nextLocation})):(a(R),u({isTransitioning:!0,flushSync:!1,currentLocation:N.currentLocation,nextLocation:N.nextLocation}))},[n.window,h,d,w,v]);g.useLayoutEffect(()=>n.subscribe(b),[n,b]),g.useEffect(()=>{c.isTransitioning&&!c.flushSync&&f(new xD)},[c]),g.useEffect(()=>{if(d&&o&&n.window){let R=o,A=d.promise,D=n.window.document.startViewTransition(async()=>{v(()=>i(R)),await A});D.finished.finally(()=>{f(void 0),p(void 0),a(void 0),u({isTransitioning:!1})}),p(D)}},[v,o,d,n.window]),g.useEffect(()=>{d&&o&&s.location.key===o.location.key&&d.resolve()},[d,h,s.location,o]),g.useEffect(()=>{!c.isTransitioning&&x&&(a(x.state),u({isTransitioning:!0,flushSync:!1,currentLocation:x.currentLocation,nextLocation:x.nextLocation}),m(void 0))},[c.isTransitioning,x]),g.useEffect(()=>{},[]);let _=g.useMemo(()=>({createHref:n.createHref,encodeLocation:n.encodeLocation,go:R=>n.navigate(R),push:(R,A,D)=>n.navigate(R,{state:A,preventScrollReset:D==null?void 0:D.preventScrollReset}),replace:(R,A,D)=>n.navigate(R,{replace:!0,state:A,preventScrollReset:D==null?void 0:D.preventScrollReset})}),[n]),C=n.basename||"/",j=g.useMemo(()=>({router:n,navigator:_,static:!1,basename:C}),[n,_,C]),T=g.useMemo(()=>({v7_relativeSplatPath:n.future.v7_relativeSplatPath}),[n.future.v7_relativeSplatPath]);return g.createElement(g.Fragment,null,g.createElement(ch.Provider,{value:j},g.createElement(VS.Provider,{value:s},g.createElement(mD.Provider,{value:w.current},g.createElement(pD.Provider,{value:c},g.createElement(rD,{basename:C,location:s.location,navigationType:s.historyAction,navigator:_,future:T},s.initialized||n.future.v7_partialHydration?g.createElement(bD,{routes:n.routes,future:n.future,state:s}):t))))),null)}const bD=g.memo(_D);function _D(e){let{routes:t,future:n,state:r}=e;return HO(t,void 0,r,n)}const SD=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",kD=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,bn=g.forwardRef(function(t,n){let{onClick:r,relative:s,reloadDocument:i,replace:o,state:a,target:c,to:u,preventScrollReset:d,unstable_viewTransition:f}=t,h=iD(t,cD),{basename:p}=g.useContext(Ii),x,m=!1;if(typeof u=="string"&&kD.test(u)&&(x=u,SD))try{let b=new URL(window.location.href),_=u.startsWith("//")?new URL(b.protocol+u):new URL(u),C=Za(_.pathname,p);_.origin===b.origin&&C!=null?u=C+_.search+_.hash:m=!0}catch{}let w=UO(u,{relative:s}),y=CD(u,{replace:o,state:a,target:c,preventScrollReset:d,relative:s,unstable_viewTransition:f});function v(b){r&&r(b),b.defaultPrevented||y(b)}return g.createElement("a",bc({},h,{href:x||w,onClick:m||i?r:v,ref:n,target:c}))});var Fw;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(Fw||(Fw={}));var zw;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(zw||(zw={}));function CD(e,t){let{target:n,replace:r,state:s,preventScrollReset:i,relative:o,unstable_viewTransition:a}=t===void 0?{}:t,c=er(),u=Mr(),d=HS(e,{relative:o});return g.useCallback(f=>{if(aD(f,n)){f.preventDefault();let h=r!==void 0?r:uo(u)===uo(d);c(e,{replace:h,state:s,preventScrollReset:i,relative:o,unstable_viewTransition:a})}},[u,c,d,r,s,n,e,i,o,a])}function jD(e){let t=g.useRef(hg(e)),n=g.useRef(!1),r=Mr(),s=g.useMemo(()=>lD(r.search,n.current?null:t.current),[r.search]),i=er(),o=g.useCallback((a,c)=>{const u=hg(typeof a=="function"?a(s):a);n.current=!0,i("?"+u,c)},[i,s]);return[s,o]}/** + */function _c(){return _c=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&(n[s]=e[s]);return n}function oD(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function aD(e,t){return e.button===0&&(!t||t==="_self")&&!oD(e)}function hg(e){return e===void 0&&(e=""),new URLSearchParams(typeof e=="string"||Array.isArray(e)||e instanceof URLSearchParams?e:Object.keys(e).reduce((t,n)=>{let r=e[n];return t.concat(Array.isArray(r)?r.map(s=>[n,s]):[[n,r]])},[]))}function lD(e,t){let n=hg(e);return t&&t.forEach((r,s)=>{n.has(s)||t.getAll(s).forEach(i=>{n.append(s,i)})}),n}const cD=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset","unstable_viewTransition"],uD="6";try{window.__reactRouterVersion=uD}catch{}function dD(e,t){return bO({basename:void 0,future:_c({},void 0,{v7_prependBasename:!0}),history:HA({window:void 0}),hydrationData:fD(),routes:e,mapRouteProperties:sD,unstable_dataStrategy:void 0,unstable_patchRoutesOnMiss:void 0,window:void 0}).initialize()}function fD(){var e;let t=(e=window)==null?void 0:e.__staticRouterHydrationData;return t&&t.errors&&(t=_c({},t,{errors:hD(t.errors)})),t}function hD(e){if(!e)return null;let t=Object.entries(e),n={};for(let[r,s]of t)if(s&&s.__type==="RouteErrorResponse")n[r]=new Qy(s.status,s.statusText,s.data,s.internal===!0);else if(s&&s.__type==="Error"){if(s.__subType){let i=window[s.__subType];if(typeof i=="function")try{let o=new i(s.message);o.stack="",n[r]=o}catch{}}if(n[r]==null){let i=new Error(s.message);i.stack="",n[r]=i}}else n[r]=s;return n}const pD=g.createContext({isTransitioning:!1}),mD=g.createContext(new Map),gD="startTransition",Mw=Nb[gD],yD="flushSync",Lw=WA[yD];function vD(e){Mw?Mw(e):e()}function _l(e){Lw?Lw(e):e()}class xD{constructor(){this.status="pending",this.promise=new Promise((t,n)=>{this.resolve=r=>{this.status==="pending"&&(this.status="resolved",t(r))},this.reject=r=>{this.status==="pending"&&(this.status="rejected",n(r))}})}}function wD(e){let{fallbackElement:t,router:n,future:r}=e,[s,i]=g.useState(n.state),[o,a]=g.useState(),[c,u]=g.useState({isTransitioning:!1}),[d,f]=g.useState(),[h,p]=g.useState(),[x,m]=g.useState(),w=g.useRef(new Map),{v7_startTransition:y}=r||{},v=g.useCallback(R=>{y?vD(R):R()},[y]),b=g.useCallback((R,A)=>{let{deletedFetchers:D,unstable_flushSync:G,unstable_viewTransitionOpts:N}=A;D.forEach(S=>w.current.delete(S)),R.fetchers.forEach((S,U)=>{S.data!==void 0&&w.current.set(U,S.data)});let F=n.window==null||n.window.document==null||typeof n.window.document.startViewTransition!="function";if(!N||F){G?_l(()=>i(R)):v(()=>i(R));return}if(G){_l(()=>{h&&(d&&d.resolve(),h.skipTransition()),u({isTransitioning:!0,flushSync:!0,currentLocation:N.currentLocation,nextLocation:N.nextLocation})});let S=n.window.document.startViewTransition(()=>{_l(()=>i(R))});S.finished.finally(()=>{_l(()=>{f(void 0),p(void 0),a(void 0),u({isTransitioning:!1})})}),_l(()=>p(S));return}h?(d&&d.resolve(),h.skipTransition(),m({state:R,currentLocation:N.currentLocation,nextLocation:N.nextLocation})):(a(R),u({isTransitioning:!0,flushSync:!1,currentLocation:N.currentLocation,nextLocation:N.nextLocation}))},[n.window,h,d,w,v]);g.useLayoutEffect(()=>n.subscribe(b),[n,b]),g.useEffect(()=>{c.isTransitioning&&!c.flushSync&&f(new xD)},[c]),g.useEffect(()=>{if(d&&o&&n.window){let R=o,A=d.promise,D=n.window.document.startViewTransition(async()=>{v(()=>i(R)),await A});D.finished.finally(()=>{f(void 0),p(void 0),a(void 0),u({isTransitioning:!1})}),p(D)}},[v,o,d,n.window]),g.useEffect(()=>{d&&o&&s.location.key===o.location.key&&d.resolve()},[d,h,s.location,o]),g.useEffect(()=>{!c.isTransitioning&&x&&(a(x.state),u({isTransitioning:!0,flushSync:!1,currentLocation:x.currentLocation,nextLocation:x.nextLocation}),m(void 0))},[c.isTransitioning,x]),g.useEffect(()=>{},[]);let _=g.useMemo(()=>({createHref:n.createHref,encodeLocation:n.encodeLocation,go:R=>n.navigate(R),push:(R,A,D)=>n.navigate(R,{state:A,preventScrollReset:D==null?void 0:D.preventScrollReset}),replace:(R,A,D)=>n.navigate(R,{replace:!0,state:A,preventScrollReset:D==null?void 0:D.preventScrollReset})}),[n]),C=n.basename||"/",j=g.useMemo(()=>({router:n,navigator:_,static:!1,basename:C}),[n,_,C]),T=g.useMemo(()=>({v7_relativeSplatPath:n.future.v7_relativeSplatPath}),[n.future.v7_relativeSplatPath]);return g.createElement(g.Fragment,null,g.createElement(lh.Provider,{value:j},g.createElement(VS.Provider,{value:s},g.createElement(mD.Provider,{value:w.current},g.createElement(pD.Provider,{value:c},g.createElement(rD,{basename:C,location:s.location,navigationType:s.historyAction,navigator:_,future:T},s.initialized||n.future.v7_partialHydration?g.createElement(bD,{routes:n.routes,future:n.future,state:s}):t))))),null)}const bD=g.memo(_D);function _D(e){let{routes:t,future:n,state:r}=e;return HO(t,void 0,r,n)}const SD=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",kD=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,bn=g.forwardRef(function(t,n){let{onClick:r,relative:s,reloadDocument:i,replace:o,state:a,target:c,to:u,preventScrollReset:d,unstable_viewTransition:f}=t,h=iD(t,cD),{basename:p}=g.useContext(Mi),x,m=!1;if(typeof u=="string"&&kD.test(u)&&(x=u,SD))try{let b=new URL(window.location.href),_=u.startsWith("//")?new URL(b.protocol+u):new URL(u),C=qa(_.pathname,p);_.origin===b.origin&&C!=null?u=C+_.search+_.hash:m=!0}catch{}let w=UO(u,{relative:s}),y=CD(u,{replace:o,state:a,target:c,preventScrollReset:d,relative:s,unstable_viewTransition:f});function v(b){r&&r(b),b.defaultPrevented||y(b)}return g.createElement("a",_c({},h,{href:x||w,onClick:m||i?r:v,ref:n,target:c}))});var Fw;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(Fw||(Fw={}));var zw;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(zw||(zw={}));function CD(e,t){let{target:n,replace:r,state:s,preventScrollReset:i,relative:o,unstable_viewTransition:a}=t===void 0?{}:t,c=er(),u=Mr(),d=HS(e,{relative:o});return g.useCallback(f=>{if(aD(f,n)){f.preventDefault();let h=r!==void 0?r:uo(u)===uo(d);c(e,{replace:h,state:s,preventScrollReset:i,relative:o,unstable_viewTransition:a})}},[u,c,d,r,s,n,e,i,o,a])}function jD(e){let t=g.useRef(hg(e)),n=g.useRef(!1),r=Mr(),s=g.useMemo(()=>lD(r.search,n.current?null:t.current),[r.search]),i=er(),o=g.useCallback((a,c)=>{const u=hg(typeof a=="function"?a(s):a);n.current=!0,i("?"+u,c)},[i,s]);return[s,o]}/** * @license lucide-react v0.417.0 - ISC * * This source code is licensed under the ISC license. @@ -251,7 +251,7 @@ Error generating stack: `+i.message+` * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. - */const ov=ut("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]);var GD={area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0};const ZD=Bf(GD);var qD=/\s([^'"/\s><]+?)[\s/>]|([^\s=]+)=\s?(".*?"|'.*?')/g;function Hw(e){var t={type:"tag",name:"",voidElement:!1,attrs:{},children:[]},n=e.match(/<\/?([^\s]+?)[/\s>]/);if(n&&(t.name=n[1],(ZD[n[1]]||e.charAt(e.length-2)==="/")&&(t.voidElement=!0),t.name.startsWith("!--"))){var r=e.indexOf("-->");return{type:"comment",comment:r!==-1?e.slice(4,r):""}}for(var s=new RegExp(qD),i=null;(i=s.exec(e))!==null;)if(i[0].trim())if(i[1]){var o=i[1].trim(),a=[o,""];o.indexOf("=")>-1&&(a=o.split("=")),t.attrs[a[0]]=a[1],s.lastIndex--}else i[2]&&(t.attrs[i[2]]=i[3].trim().substring(1,i[3].length-1));return t}var XD=/<[a-zA-Z0-9\-\!\/](?:"[^"]*"|'[^']*'|[^'">])*>/g,QD=/^\s*$/,JD=Object.create(null);function ek(e,t){switch(t.type){case"text":return e+t.content;case"tag":return e+="<"+t.name+(t.attrs?function(n){var r=[];for(var s in n)r.push(s+'="'+n[s]+'"');return r.length?" "+r.join(" "):""}(t.attrs):"")+(t.voidElement?"/>":">"),t.voidElement?e:e+t.children.reduce(ek,"")+"";case"comment":return e+""}}var eI={parse:function(e,t){t||(t={}),t.components||(t.components=JD);var n,r=[],s=[],i=-1,o=!1;if(e.indexOf("<")!==0){var a=e.indexOf("<");r.push({type:"text",content:a===-1?e:e.substring(0,a)})}return e.replace(XD,function(c,u){if(o){if(c!=="")return;o=!1}var d,f=c.charAt(1)!=="/",h=c.startsWith("");return{type:"comment",comment:r!==-1?e.slice(4,r):""}}for(var s=new RegExp(qD),i=null;(i=s.exec(e))!==null;)if(i[0].trim())if(i[1]){var o=i[1].trim(),a=[o,""];o.indexOf("=")>-1&&(a=o.split("=")),t.attrs[a[0]]=a[1],s.lastIndex--}else i[2]&&(t.attrs[i[2]]=i[3].trim().substring(1,i[3].length-1));return t}var XD=/<[a-zA-Z0-9\-\!\/](?:"[^"]*"|'[^']*'|[^'">])*>/g,QD=/^\s*$/,JD=Object.create(null);function ek(e,t){switch(t.type){case"text":return e+t.content;case"tag":return e+="<"+t.name+(t.attrs?function(n){var r=[];for(var s in n)r.push(s+'="'+n[s]+'"');return r.length?" "+r.join(" "):""}(t.attrs):"")+(t.voidElement?"/>":">"),t.voidElement?e:e+t.children.reduce(ek,"")+"";case"comment":return e+""}}var eI={parse:function(e,t){t||(t={}),t.components||(t.components=JD);var n,r=[],s=[],i=-1,o=!1;if(e.indexOf("<")!==0){var a=e.indexOf("<");r.push({type:"text",content:a===-1?e:e.substring(0,a)})}return e.replace(XD,function(c,u){if(o){if(c!=="")return;o=!1}var d,f=c.charAt(1)!=="/",h=c.startsWith("