@dcl/explore-site 0.0.1-24479882284.commit-3ded912 → 0.0.1-24485660213.commit-845d396
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/HomePage-DaVJoZZr.js +5 -0
- package/assets/{QueryClientProvider-DtuAN_aC.js → QueryClientProvider-BhyaIKiR.js} +1 -1
- package/assets/{SensorsRounded-CbCf33Qs.js → SensorsRounded-nieimCS8.js} +1 -1
- package/assets/{__federation_expose_App-B8UXjREq.js → __federation_expose_App-B0aY7Py4.js} +1 -1
- package/assets/{__federation_fn_import-DQ8TJylT.js → __federation_fn_import-ByLP531e.js} +1 -1
- package/assets/__federation_shared_@dcl/{hooks-Ds1r2BiA.js → hooks-DYeUnvq5.js} +3 -3
- package/assets/__federation_shared_@emotion/react-DXkJ7VYj.js +1 -0
- package/assets/__federation_shared_@emotion/{styled-BsQqOIiw.js → styled-nUAfJU1w.js} +1 -1
- package/assets/__federation_shared_@reduxjs/toolkit-CslZ4BOy.js +1 -0
- package/assets/{__federation_shared_decentraland-ui2-Dj-RcRSx.js → __federation_shared_decentraland-ui2-36oVv_RF.js} +4 -4
- package/assets/{__federation_shared_react-redux-BqucL7tQ.js → __federation_shared_react-redux-vH9OOcWA.js} +1 -1
- package/assets/__federation_shared_react-router-dom-C_SAlhzM.js +49 -0
- package/assets/{__federation_shared_viem-BhUxxutV.js → __federation_shared_viem-ByQOwPXq.js} +1 -1
- package/assets/{__federation_shared_wagmi-BdKginVA.js → __federation_shared_wagmi-BOAmcXMK.js} +1 -1
- package/assets/{add-CYGhLDbR.js → add-CLk7XVew.js} +1 -1
- package/assets/{all-wallets-BThDqsD4.js → all-wallets-IYtg-tji.js} +1 -1
- package/assets/{app-store-DO4omH1U.js → app-store-DtfBDopi.js} +1 -1
- package/assets/{apple-C_iYRVIN.js → apple-m6Hn-bqE.js} +1 -1
- package/assets/{arrow-bottom-BFW-exRM.js → arrow-bottom-1yzKjtqK.js} +1 -1
- package/assets/{arrow-bottom-circle-DOCwyinz.js → arrow-bottom-circle-Dls6gSE9.js} +1 -1
- package/assets/{arrow-left-DrdKkUS2.js → arrow-left-CNsu18Pl.js} +1 -1
- package/assets/{arrow-right-Poiwpg7z.js → arrow-right-hIOHlL0D.js} +1 -1
- package/assets/{arrow-top-DHgISQmq.js → arrow-top-DUg6_QYs.js} +1 -1
- package/assets/{auto-track-BZHaXK7v.js → auto-track-C6pjzgJ-.js} +1 -1
- package/assets/{bank-BUCwu8W8.js → bank-DXwLc29q.js} +1 -1
- package/assets/{basic-dy6ovDQ1.js → basic-Bh_d1NCq.js} +1 -1
- package/assets/{browser-XcBJkPyy.js → browser-CCDvSEkj.js} +1 -1
- package/assets/{card-BckA_YDl.js → card-91-oSUdO.js} +1 -1
- package/assets/{ccip-CrlE081z.js → ccip-CXCqTMSW.js} +1 -1
- package/assets/{checkmark-BnlFl6-K.js → checkmark-Dktdi58s.js} +1 -1
- package/assets/{checkmark-bold-DAYFe1Fl.js → checkmark-bold-BYVU6esV.js} +1 -1
- package/assets/{chevron-bottom-D1CHGlUQ.js → chevron-bottom-COQTP5Ac.js} +1 -1
- package/assets/{chevron-left-CDjel7fL.js → chevron-left-xduigmQe.js} +1 -1
- package/assets/{chevron-right-CSdh1WpN.js → chevron-right-Da2gsK2R.js} +1 -1
- package/assets/{chevron-top-Dedd44b5.js → chevron-top-CEwq_-CY.js} +1 -1
- package/assets/{chrome-store-BMzup5mn.js → chrome-store-DqiiVTtW.js} +1 -1
- package/assets/{clock-o3xoMHef.js → clock-387PxsmY.js} +1 -1
- package/assets/{close-_ZZkeF0S.js → close-D0LMm88M.js} +1 -1
- package/assets/{coinPlaceholder-D3gak2mr.js → coinPlaceholder-Cdiy7WQ9.js} +1 -1
- package/assets/{compass-DnpLuwqg.js → compass-xvmPd5Bk.js} +1 -1
- package/assets/{copy-CD2gscLI.js → copy-tEDMw0ts.js} +1 -1
- package/assets/{core-BBzSuqAq.js → core-DZHcmbWo.js} +3 -3
- package/assets/{createClient-CD06vUaF.js → createClient-BO3IrJpf.js} +1 -1
- package/assets/{cursor-C28MPU68.js → cursor-BpAKVyKK.js} +1 -1
- package/assets/{cursor-transparent-DEfupAsA.js → cursor-transparent-B1Td-8Bz.js} +1 -1
- package/assets/{desktop-BCo-N93j.js → desktop-S18Xoso6.js} +1 -1
- package/assets/{disconnect-CfuPYBHO.js → disconnect-C3xgypr6.js} +1 -1
- package/assets/{discord-N7ni0tI8.js → discord-CRIf-UbF.js} +1 -1
- package/assets/{emotion-react.browser.esm-DBrV0HIX.js → emotion-react.browser.esm-DjDb7r_w.js} +1 -1
- package/assets/{emotion-use-insertion-effect-with-fallbacks.browser.esm-Caa8P_j3.js → emotion-use-insertion-effect-with-fallbacks.browser.esm-DBmkeYb9.js} +1 -1
- package/assets/{etherscan-ChpXkGDj.js → etherscan-mm8HK-MJ.js} +1 -1
- package/assets/{exclamation-triangle-CqbfbUu7.js → exclamation-triangle-UYV6Y1Va.js} +1 -1
- package/assets/{extension-BUg43LJ7.js → extension-CTdGtFN8.js} +1 -1
- package/assets/{external-link-DihOMRrk.js → external-link-BIdf4QIt.js} +1 -1
- package/assets/{facebook-CEJGiy4z.js → facebook-KLMkQcpc.js} +1 -1
- package/assets/{farcaster-CIBBzFzg.js → farcaster-k2jIQRW1.js} +1 -1
- package/assets/{filters-lWAb8k9r.js → filters-tFXMsiT4.js} +1 -1
- package/assets/{github-BlqpNMuT.js → github-B8LffamD.js} +1 -1
- package/assets/{google-D1QAEKXR.js → google-CQkBuKjh.js} +1 -1
- package/assets/{help-circle-CNl45Fm3.js → help-circle-BDk2gtpm.js} +1 -1
- package/assets/{id-DhmD5hsD.js → id-J2WK83st.js} +1 -1
- package/assets/{image-DOBqcTez.js → image-uj79OUC9.js} +1 -1
- package/assets/{index-DoHw1OJA.js → index-B8mcfIAz.js} +1 -1
- package/assets/{index-DHcMla0b.js → index-B9CwQqDx.js} +3 -3
- package/assets/{index-BHbKU7xE.js → index-BCaUC5CZ.js} +1 -1
- package/assets/{index-S2uTJhci.js → index-CzkFy2Dd.js} +1 -1
- package/assets/{index-BrAzaiH0.js → index-D5kgbiM5.js} +1 -1
- package/assets/{index-DvGjWAV5.js → index-DDOU1_kc.js} +1 -1
- package/assets/{index-BBB4Ypgz.js → index-DcV4ewib.js} +2 -2
- package/assets/index-Dy0yjznp.js +1 -1
- package/assets/{index-3a69uS-z.js → index-QHEbtwDk.js} +1 -1
- package/assets/index-VfkM29PH.js +1 -1
- package/assets/{index.es-mUvw0iTX.js → index.es-rd6wvRni.js} +3 -3
- package/assets/{info-Cb7C5HJP.js → info-DlG8nlHJ.js} +1 -1
- package/assets/{info-circle-BPAnPqF0.js → info-circle-nOJvVDoQ.js} +1 -1
- package/assets/jsx-runtime-B1l0k91v.js +1 -1
- package/assets/{lightbulb-BVA2sKov.js → lightbulb-d7WoN-_f.js} +1 -1
- package/assets/{localBatchGatewayRequest-DBXEm-Wm.js → localBatchGatewayRequest-BiFOXYYk.js} +1 -1
- package/assets/{mail-Bvh22_Y-.js → mail-BiX38EUR.js} +1 -1
- package/assets/{mobile-BduNO5cQ.js → mobile-Dd4yjObG.js} +1 -1
- package/assets/{more-BkVsWU9E.js → more-MSuARi2_.js} +1 -1
- package/assets/{network-placeholder-CRIoi-jm.js → network-placeholder-CA53BZgJ.js} +1 -1
- package/assets/{nftPlaceholder-DdAjMmea.js → nftPlaceholder-C8C2MjcU.js} +1 -1
- package/assets/{off-CTKmW52V.js → off-rI9hn05x.js} +1 -1
- package/assets/{play-store-Dq6fjK22.js → play-store-Cl7i6QvB.js} +1 -1
- package/assets/{plus-B_EY5A71.js → plus-DXNu4d9m.js} +1 -1
- package/assets/{preload-helper-BG_A5WRU.js → preload-helper-CsJwBEeH.js} +1 -1
- package/assets/{qr-code-Cwsh0rem.js → qr-code-AZHpyffw.js} +1 -1
- package/assets/{recycle-horizontal-BUVylaYp.js → recycle-horizontal-B-EVv56M.js} +1 -1
- package/assets/{refresh-peODRwwV.js → refresh-CK9su4gs.js} +1 -1
- package/assets/remoteEntry.js +1 -1
- package/assets/{reown-logo-DYsfzQCb.js → reown-logo-DrNPGmcL.js} +1 -1
- package/assets/{reselect-BfUrOuXx.js → reselect-qCf8eESi.js} +1 -1
- package/assets/{search-CXibLn6y.js → search-C0MAQCQX.js} +1 -1
- package/assets/{secp256k1-Dllol_EX.js → secp256k1-BatDCt6g.js} +1 -1
- package/assets/{send-tRVUXnOv.js → send-BeCh-jZD.js} +1 -1
- package/assets/{swapHorizontal-DR8kn2mz.js → swapHorizontal-BrsSL8Ld.js} +1 -1
- package/assets/{swapHorizontalBold-t7j1yU-K.js → swapHorizontalBold-DBS1FVZI.js} +1 -1
- package/assets/{swapHorizontalMedium-C-kFwJIt.js → swapHorizontalMedium-1i9enUmE.js} +1 -1
- package/assets/{swapHorizontalRoundedBold-GyiV8Ilf.js → swapHorizontalRoundedBold-BMH9pzxi.js} +1 -1
- package/assets/{swapVertical-BvzVakf4.js → swapVertical-Dgw1BOWx.js} +1 -1
- package/assets/{telegram-CNPetEqU.js → telegram-07bF-nB-.js} +1 -1
- package/assets/{three-dots-C41YDf_O.js → three-dots-D_lkLtfC.js} +1 -1
- package/assets/{twitch-YpaUNiHz.js → twitch-CG0BG2ER.js} +1 -1
- package/assets/{twitterIcon-BDQUr-nc.js → twitterIcon-Dq725p1a.js} +1 -1
- package/assets/{uid-PBwcgiZ7.js → uid-CAnWNnor.js} +3 -3
- package/assets/{verify-oFTjDDKT.js → verify-DHvvOemC.js} +1 -1
- package/assets/{verify-filled-CARvxl5C.js → verify-filled-B2XNpSdi.js} +1 -1
- package/assets/{w3m-modal-DWP1TvRy.js → w3m-modal-DWn7s7sC.js} +1 -1
- package/assets/{wallet-CiUD0MIO.js → wallet-Dt-34u8V.js} +1 -1
- package/assets/{wallet-placeholder-C6U5iVmN.js → wallet-placeholder-BR8VWAZR.js} +1 -1
- package/assets/{walletconnect--oRmSwoR.js → walletconnect-1Pf--7yk.js} +1 -1
- package/assets/{warning-circle-BeNl0Kbh.js → warning-circle-BuF5lEt2.js} +1 -1
- package/assets/{webSocket-ihtpI-EL.js → webSocket-aolSHvA1.js} +1 -1
- package/assets/{x-vQNfm7Mt.js → x-DiShiu0v.js} +1 -1
- package/index.html +17 -17
- package/package.json +3 -3
- package/assets/HomePage-Vk8ma2WV.js +0 -5
- package/assets/__federation_shared_@emotion/react-i_Tya_pH.js +0 -1
- package/assets/__federation_shared_@reduxjs/toolkit-R1Ell7gI.js +0 -1
- package/assets/__federation_shared_react-router-dom-pF1jf6Nn.js +0 -49
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{importShared as Pe}from"./__federation_fn_import-
|
|
1
|
+
import{importShared as Pe}from"./__federation_fn_import-ByLP531e.js";import{r as he}from"./index-Dy0yjznp.js";var ie={exports:{}},le={};/**
|
|
2
2
|
* @license React
|
|
3
3
|
* use-sync-external-store-with-selector.production.js
|
|
4
4
|
*
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import{importShared as le}from"./__federation_fn_import-ByLP531e.js";/**
|
|
2
|
+
* react-router v7.9.6
|
|
3
|
+
*
|
|
4
|
+
* Copyright (c) Remix Software Inc.
|
|
5
|
+
*
|
|
6
|
+
* This source code is licensed under the MIT license found in the
|
|
7
|
+
* LICENSE.md file in the root directory of this source tree.
|
|
8
|
+
*
|
|
9
|
+
* @license MIT
|
|
10
|
+
*/var Kn=e=>{throw TypeError(e)},fl=(e,t,r)=>t.has(e)||Kn("Cannot "+r),zr=(e,t,r)=>(fl(e,t,"read from private field"),r?r.call(e):t.get(e)),hl=(e,t,r)=>t.has(e)?Kn("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,r),ml=(e=>(e.Pop="POP",e.Push="PUSH",e.Replace="REPLACE",e))(ml||{}),sn="popstate";function Xn(e={}){let{initialEntries:t=["/"],initialIndex:r,v5Compat:a=!1}=e,n;n=t.map((f,h)=>d(f,typeof f=="string"?null:f.state,h===0?"default":void 0));let o=s(r??n.length-1),i="POP",l=null;function s(f){return Math.min(Math.max(f,0),n.length-1)}function u(){return n[o]}function d(f,h=null,v){let y=Ye(n?u().pathname:"/",f,h,v);return Z(y.pathname.charAt(0)==="/",`relative pathnames are not supported in memory history: ${JSON.stringify(f)}`),y}function c(f){return typeof f=="string"?f:we(f)}return{get index(){return o},get action(){return i},get location(){return u()},createHref:c,createURL(f){return new URL(c(f),"http://localhost")},encodeLocation(f){let h=typeof f=="string"?Me(f):f;return{pathname:h.pathname||"",search:h.search||"",hash:h.hash||""}},push(f,h){i="PUSH";let v=d(f,h);o+=1,n.splice(o,n.length,v),a&&l&&l({action:i,location:v,delta:1})},replace(f,h){i="REPLACE";let v=d(f,h);n[o]=v,a&&l&&l({action:i,location:v,delta:0})},go(f){i="POP";let h=s(o+f),v=n[h];o=h,l&&l({action:i,location:v,delta:f})},listen(f){return l=f,()=>{l=null}}}}function Ea(e={}){function t(a,n){let{pathname:o,search:i,hash:l}=a.location;return Ye("",{pathname:o,search:i,hash:l},n.state&&n.state.usr||null,n.state&&n.state.key||"default")}function r(a,n){return typeof n=="string"?n:we(n)}return Qn(t,r,null,e)}function Gn(e={}){function t(n,o){let{pathname:i="/",search:l="",hash:s=""}=Me(n.location.hash.substring(1));return!i.startsWith("/")&&!i.startsWith(".")&&(i="/"+i),Ye("",{pathname:i,search:l,hash:s},o.state&&o.state.usr||null,o.state&&o.state.key||"default")}function r(n,o){let i=n.document.querySelector("base"),l="";if(i&&i.getAttribute("href")){let s=n.location.href,u=s.indexOf("#");l=u===-1?s:s.slice(0,u)}return l+"#"+(typeof o=="string"?o:we(o))}function a(n,o){Z(n.pathname.charAt(0)==="/",`relative pathnames are not supported in hash history.push(${JSON.stringify(o)})`)}return Qn(t,r,a,e)}function I(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function Z(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function pl(){return Math.random().toString(36).substring(2,10)}function un(e,t){return{usr:e.state,key:e.key,idx:t}}function Ye(e,t,r=null,a){return{pathname:typeof e=="string"?e:e.pathname,search:"",hash:"",...typeof t=="string"?Me(t):t,state:r,key:t&&t.key||a||pl()}}function we({pathname:e="/",search:t="",hash:r=""}){return t&&t!=="?"&&(e+=t.charAt(0)==="?"?t:"?"+t),r&&r!=="#"&&(e+=r.charAt(0)==="#"?r:"#"+r),e}function Me(e){let t={};if(e){let r=e.indexOf("#");r>=0&&(t.hash=e.substring(r),e=e.substring(0,r));let a=e.indexOf("?");a>=0&&(t.search=e.substring(a),e=e.substring(0,a)),e&&(t.pathname=e)}return t}function Qn(e,t,r,a={}){let{window:n=document.defaultView,v5Compat:o=!1}=a,i=n.history,l="POP",s=null,u=d();u==null&&(u=0,i.replaceState({...i.state,idx:u},""));function d(){return(i.state||{idx:null}).idx}function c(){l="POP";let y=d(),R=y==null?null:y-u;u=y,s&&s({action:l,location:v.location,delta:R})}function m(y,R){l="PUSH";let w=Ye(v.location,y,R);r&&r(w,y),u=d()+1;let S=un(w,u),P=v.createHref(w);try{i.pushState(S,"",P)}catch(C){if(C instanceof DOMException&&C.name==="DataCloneError")throw C;n.location.assign(P)}o&&s&&s({action:l,location:v.location,delta:1})}function f(y,R){l="REPLACE";let w=Ye(v.location,y,R);r&&r(w,y),u=d();let S=un(w,u),P=v.createHref(w);i.replaceState(S,"",P),o&&s&&s({action:l,location:v.location,delta:0})}function h(y){return Zn(y)}let v={get action(){return l},get location(){return e(n,i)},listen(y){if(s)throw new Error("A history only accepts one active listener");return n.addEventListener(sn,c),s=y,()=>{n.removeEventListener(sn,c),s=null}},createHref(y){return t(n,y)},createURL:h,encodeLocation(y){let R=h(y);return{pathname:R.pathname,search:R.search,hash:R.hash}},push:m,replace:f,go(y){return i.go(y)}};return v}function Zn(e,t=!1){let r="http://localhost";typeof window<"u"&&(r=window.location.origin!=="null"?window.location.origin:window.location.href),I(r,"No window.location.(origin|href) available to create URL");let a=typeof e=="string"?e:we(e);return a=a.replace(/ $/,"%20"),!t&&a.startsWith("//")&&(a=r+a),new URL(a,r)}function nd(e){return{defaultValue:e}}var Ht,Ve=class{constructor(e){if(hl(this,Ht,new Map),e)for(let[t,r]of e)this.set(t,r)}get(e){if(zr(this,Ht).has(e))return zr(this,Ht).get(e);if(e.defaultValue!==void 0)return e.defaultValue;throw new Error("No value found for context")}set(e,t){zr(this,Ht).set(e,t)}};Ht=new WeakMap;var yl=new Set(["lazy","caseSensitive","path","id","index","children"]);function vl(e){return yl.has(e)}var gl=new Set(["lazy","caseSensitive","path","id","index","middleware","children"]);function wl(e){return gl.has(e)}function Rl(e){return e.index===!0}function at(e,t,r=[],a={},n=!1){return e.map((o,i)=>{let l=[...r,String(i)],s=typeof o.id=="string"?o.id:l.join("-");if(I(o.index!==!0||!o.children,"Cannot specify children on an index route"),I(n||!a[s],`Found a route id collision on id "${s}". Route id's must be globally unique within Data Router usages`),Rl(o)){let u={...o,id:s};return a[s]=cn(u,t(u)),u}else{let u={...o,id:s,children:void 0};return a[s]=cn(u,t(u)),o.children&&(u.children=at(o.children,t,l,a,n)),u}})}function cn(e,t){return Object.assign(e,{...t,...typeof t.lazy=="object"&&t.lazy!=null?{lazy:{...e.lazy,...t.lazy}}:{}})}function Ce(e,t,r="/"){return jt(e,t,r,!1)}function jt(e,t,r,a){let n=typeof t=="string"?Me(t):t,o=ue(n.pathname||"/",r);if(o==null)return null;let i=eo(e);El(i);let l=null;for(let s=0;l==null&&s<i.length;++s){let u=ao(o);l=kl(i[s],u,a)}return l}function qn(e,t){let{route:r,pathname:a,params:n}=e;return{id:r.id,pathname:a,params:n,data:t[r.id],loaderData:t[r.id],handle:r.handle}}function eo(e,t=[],r=[],a="",n=!1){let o=(i,l,s=n,u)=>{let d={relativePath:u===void 0?i.path||"":u,caseSensitive:i.caseSensitive===!0,childrenIndex:l,route:i};if(d.relativePath.startsWith("/")){if(!d.relativePath.startsWith(a)&&s)return;I(d.relativePath.startsWith(a),`Absolute route path "${d.relativePath}" nested under path "${a}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),d.relativePath=d.relativePath.slice(a.length)}let c=He([a,d.relativePath]),m=r.concat(d);i.children&&i.children.length>0&&(I(i.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${c}".`),eo(i.children,t,m,c,s)),!(i.path==null&&!i.index)&&t.push({path:c,score:Ll(c,i.index),routesMeta:m})};return e.forEach((i,l)=>{if(i.path===""||!i.path?.includes("?"))o(i,l);else for(let s of to(i.path))o(i,l,!0,s)}),t}function to(e){let t=e.split("/");if(t.length===0)return[];let[r,...a]=t,n=r.endsWith("?"),o=r.replace(/\?$/,"");if(a.length===0)return n?[o,""]:[o];let i=to(a.join("/")),l=[];return l.push(...i.map(s=>s===""?o:[o,s].join("/"))),n&&l.push(...i),l.map(s=>e.startsWith("/")&&s===""?"/":s)}function El(e){e.sort((t,r)=>t.score!==r.score?r.score-t.score:_l(t.routesMeta.map(a=>a.childrenIndex),r.routesMeta.map(a=>a.childrenIndex)))}var bl=/^:[\w-]+$/,Sl=3,Cl=2,xl=1,Pl=10,Dl=-2,dn=e=>e==="*";function Ll(e,t){let r=e.split("/"),a=r.length;return r.some(dn)&&(a+=Dl),t&&(a+=Cl),r.filter(n=>!dn(n)).reduce((n,o)=>n+(bl.test(o)?Sl:o===""?xl:Pl),a)}function _l(e,t){return e.length===t.length&&e.slice(0,-1).every((a,n)=>a===t[n])?e[e.length-1]-t[t.length-1]:0}function kl(e,t,r=!1){let{routesMeta:a}=e,n={},o="/",i=[];for(let l=0;l<a.length;++l){let s=a[l],u=l===a.length-1,d=o==="/"?t:t.slice(o.length)||"/",c=zt({path:s.relativePath,caseSensitive:s.caseSensitive,end:u},d),m=s.route;if(!c&&u&&r&&!a[a.length-1].route.index&&(c=zt({path:s.relativePath,caseSensitive:s.caseSensitive,end:!1},d)),!c)return null;Object.assign(n,c.params),i.push({params:n,pathname:He([o,c.pathname]),pathnameBase:Fl(He([o,c.pathnameBase])),route:m}),c.pathnameBase!=="/"&&(o=He([o,c.pathnameBase]))}return i}function od(e,t={}){let r=e;r.endsWith("*")&&r!=="*"&&!r.endsWith("/*")&&(Z(!1,`Route path "${r}" will be treated as if it were "${r.replace(/\*$/,"/*")}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${r.replace(/\*$/,"/*")}".`),r=r.replace(/\*$/,"/*"));const a=r.startsWith("/")?"/":"",n=i=>i==null?"":typeof i=="string"?i:String(i),o=r.split(/\/+/).map((i,l,s)=>{if(l===s.length-1&&i==="*")return n(t["*"]);const d=i.match(/^:([\w-]+)(\??)$/);if(d){const[,c,m]=d;let f=t[c];return I(m==="?"||f!=null,`Missing ":${c}" param`),encodeURIComponent(n(f))}return i.replace(/\?$/g,"")}).filter(i=>!!i);return a+o.join("/")}function zt(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[r,a]=ro(e.path,e.caseSensitive,e.end),n=t.match(r);if(!n)return null;let o=n[0],i=o.replace(/(.)\/+$/,"$1"),l=n.slice(1);return{params:a.reduce((u,{paramName:d,isOptional:c},m)=>{if(d==="*"){let h=l[m]||"";i=o.slice(0,o.length-h.length).replace(/(.)\/+$/,"$1")}const f=l[m];return c&&!f?u[d]=void 0:u[d]=(f||"").replace(/%2F/g,"/"),u},{}),pathname:o,pathnameBase:i,pattern:e}}function ro(e,t=!1,r=!0){Z(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 a=[],n="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(i,l,s)=>(a.push({paramName:l,isOptional:s!=null}),s?"/?([^\\/]+)?":"/([^\\/]+)")).replace(/\/([\w-]+)\?(\/|$)/g,"(/$1)?$2");return e.endsWith("*")?(a.push({paramName:"*"}),n+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):r?n+="\\/*$":e!==""&&e!=="/"&&(n+="(?:(?=\\/|$))"),[new RegExp(n,t?void 0:"i"),a]}function ao(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return Z(!1,`The URL path "${e}" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (${t}).`),e}}function ue(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let r=t.endsWith("/")?t.length-1:t.length,a=e.charAt(r);return a&&a!=="/"?null:e.slice(r)||"/"}function Tl({basename:e,pathname:t}){return t==="/"?e:He([e,t])}var Ml=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Rr=e=>Ml.test(e);function Ol(e,t="/"){let{pathname:r,search:a="",hash:n=""}=typeof e=="string"?Me(e):e,o;if(r)if(Rr(r))o=r;else{if(r.includes("//")){let i=r;r=r.replace(/\/\/+/g,"/"),Z(!1,`Pathnames cannot have embedded double slashes - normalizing ${i} -> ${r}`)}r.startsWith("/")?o=fn(r.substring(1),"/"):o=fn(r,t)}else o=t;return{pathname:o,search:Nl(a),hash:Al(n)}}function fn(e,t){let r=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(n=>{n===".."?r.length>1&&r.pop():n!=="."&&r.push(n)}),r.length>1?r.join("/"):"/"}function Br(e,t,r,a){return`Cannot include a '${e}' character in a manually specified \`to.${t}\` field [${JSON.stringify(a)}]. Please separate it out to the \`to.${r}\` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.`}function no(e){return e.filter((t,r)=>r===0||t.route.path&&t.route.path.length>0)}function Er(e){let t=no(e);return t.map((r,a)=>a===t.length-1?r.pathname:r.pathnameBase)}function br(e,t,r,a=!1){let n;typeof e=="string"?n=Me(e):(n={...e},I(!n.pathname||!n.pathname.includes("?"),Br("?","pathname","search",n)),I(!n.pathname||!n.pathname.includes("#"),Br("#","pathname","hash",n)),I(!n.search||!n.search.includes("#"),Br("#","search","hash",n)));let o=e===""||n.pathname==="",i=o?"/":n.pathname,l;if(i==null)l=r;else{let c=t.length-1;if(!a&&i.startsWith("..")){let m=i.split("/");for(;m[0]==="..";)m.shift(),c-=1;n.pathname=m.join("/")}l=c>=0?t[c]:"/"}let s=Ol(n,l),u=i&&i!=="/"&&i.endsWith("/"),d=(o||i===".")&&r.endsWith("/");return!s.pathname.endsWith("/")&&(u||d)&&(s.pathname+="/"),s}var He=e=>e.join("/").replace(/\/\/+/g,"/"),Fl=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),Nl=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,Al=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e,$l=class{constructor(e,t){this.type="DataWithResponseInit",this.data=e,this.init=t||null}};function Il(e,t){return new $l(e,typeof t=="number"?{status:t}:t)}var Sr=(e,t=302)=>{let r=t;typeof r=="number"?r={status:r}:typeof r.status>"u"&&(r.status=302);let a=new Headers(r.headers);return a.set("Location",e),new Response(null,{...r,headers:a})},Hl=(e,t)=>{let r=Sr(e,t);return r.headers.set("X-Remix-Reload-Document","true"),r},jl=(e,t)=>{let r=Sr(e,t);return r.headers.set("X-Remix-Replace","true"),r},Re=class{constructor(e,t,r,a=!1){this.status=e,this.statusText=t||"",this.internal=a,r instanceof Error?(this.data=r.toString(),this.error=r):this.data=r}};function ie(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}function St(e){return e.filter(Boolean).join("/").replace(/\/\/*/g,"/")||"/"}var qe=Symbol("Uninstrumented");function oo(e,t){let r={lazy:[],"lazy.loader":[],"lazy.action":[],"lazy.middleware":[],middleware:[],loader:[],action:[]};e.forEach(n=>n({id:t.id,index:t.index,path:t.path,instrument(o){let i=Object.keys(r);for(let l of i)o[l]&&r[l].push(o[l])}}));let a={};if(typeof t.lazy=="function"&&r.lazy.length>0){let n=yt(r.lazy,t.lazy,()=>{});n&&(a.lazy=n)}if(typeof t.lazy=="object"){let n=t.lazy;["middleware","loader","action"].forEach(o=>{let i=n[o],l=r[`lazy.${o}`];if(typeof i=="function"&&l.length>0){let s=yt(l,i,()=>{});s&&(a.lazy=Object.assign(a.lazy||{},{[o]:s}))}})}return["loader","action"].forEach(n=>{let o=t[n];if(typeof o=="function"&&r[n].length>0){let i=o[qe]??o,l=yt(r[n],i,(...s)=>hn(s[0]));l&&(l[qe]=i,a[n]=l)}}),t.middleware&&t.middleware.length>0&&r.middleware.length>0&&(a.middleware=t.middleware.map(n=>{let o=n[qe]??n,i=yt(r.middleware,o,(...l)=>hn(l[0]));return i?(i[qe]=o,i):n})),a}function Ul(e,t){let r={navigate:[],fetch:[]};if(t.forEach(a=>a({instrument(n){let o=Object.keys(n);for(let i of o)n[i]&&r[i].push(n[i])}})),r.navigate.length>0){let a=e.navigate[qe]??e.navigate,n=yt(r.navigate,a,(...o)=>{let[i,l]=o;return{to:typeof i=="number"||typeof i=="string"?i:i?we(i):".",...mn(e,l??{})}});n&&(n[qe]=a,e.navigate=n)}if(r.fetch.length>0){let a=e.fetch[qe]??e.fetch,n=yt(r.fetch,a,(...o)=>{let[i,,l,s]=o;return{href:l??".",fetcherKey:i,...mn(e,s??{})}});n&&(n[qe]=a,e.fetch=n)}return e}function zl(e,t){let r={request:[]};t.forEach(n=>n({instrument(o){let i=Object.keys(o);for(let l of i)o[l]&&r[l].push(o[l])}}));let a=e;return r.request.length>0&&(a=yt(r.request,e,(...n)=>{let[o,i]=n;return{request:lo(o),context:i!=null?so(i):i}})),a}function yt(e,t,r){return e.length===0?null:async(...a)=>{let n=await io(e,r(...a),()=>t(...a),e.length-1);if(n.type==="error")throw n.value;return n.value}}async function io(e,t,r,a){let n=e[a],o;if(n){let i,l=async()=>(i?console.error("You cannot call instrumented handlers more than once"):i=io(e,t,r,a-1),o=await i,I(o,"Expected a result"),o.type==="error"&&o.value instanceof Error?{status:"error",error:o.value}:{status:"success",error:void 0});try{await n(l,t)}catch(s){console.error("An instrumentation function threw an error:",s)}i||await l(),await i}else try{o={type:"success",value:await r()}}catch(i){o={type:"error",value:i}}return o||{type:"error",value:new Error("No result assigned in instrumentation chain.")}}function hn(e){let{request:t,context:r,params:a,unstable_pattern:n}=e;return{request:lo(t),params:{...a},unstable_pattern:n,context:so(r)}}function mn(e,t){return{currentUrl:we(e.state.location),..."formMethod"in t?{formMethod:t.formMethod}:{},..."formEncType"in t?{formEncType:t.formEncType}:{},..."formData"in t?{formData:t.formData}:{},..."body"in t?{body:t.body}:{}}}function lo(e){return{method:e.method,url:e.url,headers:{get:(...t)=>e.headers.get(...t)}}}function so(e){if(Wl(e)){let t={...e};return Object.freeze(t),t}else return{get:t=>e.get(t)}}var Bl=Object.getOwnPropertyNames(Object.prototype).sort().join("\0");function Wl(e){if(e===null||typeof e!="object")return!1;const t=Object.getPrototypeOf(e);return t===Object.prototype||t===null||Object.getOwnPropertyNames(t).sort().join("\0")===Bl}var uo=["POST","PUT","PATCH","DELETE"],Vl=new Set(uo),Yl=["GET",...uo],Jl=new Set(Yl),co=new Set([301,302,303,307,308]),Kl=new Set([307,308]),lr={state:"idle",location:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},ba={state:"idle",data:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},pt={state:"unblocked",proceed:void 0,reset:void 0,location:void 0},fo=e=>({hasErrorBoundary:!!e.hasErrorBoundary}),ho="remix-router-transitions",mo=Symbol("ResetLoaderData");function Cr(e){const t=e.window?e.window:typeof window<"u"?window:void 0,r=typeof t<"u"&&typeof t.document<"u"&&typeof t.document.createElement<"u";I(e.routes.length>0,"You must provide a non-empty routes array to createRouter");let a=e.hydrationRouteProperties||[],n=e.mapRouteProperties||fo,o=n;if(e.unstable_instrumentations){let p=e.unstable_instrumentations;o=E=>({...n(E),...oo(p.map(b=>b.route).filter(Boolean),E)})}let i={},l=at(e.routes,o,void 0,i),s,u=e.basename||"/";u.startsWith("/")||(u=`/${u}`);let d=e.dataStrategy||es,c={...e.future},m=null,f=new Set,h=null,v=null,y=null,R=e.hydrationData!=null,w=Ce(l,e.history.location,u),S=!1,P=null,C;if(w==null&&!e.patchRoutesOnNavigation){let p=oe(404,{pathname:e.history.location.pathname}),{matches:E,route:b}=bt(l);C=!0,w=E,P={[b.id]:p}}else if(w&&!e.hydrationData&&Gt(w,l,e.history.location.pathname).active&&(w=null),w)if(w.some(p=>p.route.lazy))C=!1;else if(!w.some(p=>Sa(p.route)))C=!0;else{let p=e.hydrationData?e.hydrationData.loaderData:null,E=e.hydrationData?e.hydrationData.errors:null;if(E){let b=w.findIndex(D=>E[D.route.id]!==void 0);C=w.slice(0,b+1).every(D=>!qr(D.route,p,E))}else C=w.every(b=>!qr(b.route,p,E))}else{C=!1,w=[];let p=Gt(null,l,e.history.location.pathname);p.active&&p.matches&&(S=!0,w=p.matches)}let x,g={historyAction:e.history.action,location:e.history.location,matches:w,initialized:C,navigation:lr,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||P,fetchers:new Map,blockers:new Map},O="POP",_=!1,T,$=!1,X=new Map,q=null,Y=!1,Q=!1,fe=new Set,G=new Map,Le=0,Ee=-1,Fe=new Map,be=new Set,_e=new Map,Ne=new Map,Ae=new Set,lt=new Map,Kt,Mt=null;function Ki(){if(m=e.history.listen(({action:p,location:E,delta:b})=>{if(Kt){Kt(),Kt=void 0;return}Z(lt.size===0||b!=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 D=rn({currentLocation:g.location,nextLocation:E,historyAction:p});if(D&&b!=null){let L=new Promise(H=>{Kt=H});e.history.go(b*-1),Xt(D,{state:"blocked",location:E,proceed(){Xt(D,{state:"proceeding",proceed:void 0,reset:void 0,location:E}),L.then(()=>e.history.go(b))},reset(){let H=new Map(g.blockers);H.set(D,pt),he({blockers:H})}});return}return st(p,E)}),r){ls(t,X);let p=()=>ss(t,X);t.addEventListener("pagehide",p),q=()=>t.removeEventListener("pagehide",p)}return g.initialized||st("POP",g.location,{initialHydration:!0}),x}function Xi(){m&&m(),q&&q(),f.clear(),T&&T.abort(),g.fetchers.forEach((p,E)=>Hr(E)),g.blockers.forEach((p,E)=>tn(E))}function Gi(p){return f.add(p),()=>f.delete(p)}function he(p,E={}){p.matches&&(p.matches=p.matches.map(L=>{let H=i[L.route.id],j=L.route;return j.element!==H.element||j.errorElement!==H.errorElement||j.hydrateFallbackElement!==H.hydrateFallbackElement?{...L,route:H}:L})),g={...g,...p};let b=[],D=[];g.fetchers.forEach((L,H)=>{L.state==="idle"&&(Ae.has(H)?b.push(H):D.push(H))}),Ae.forEach(L=>{!g.fetchers.has(L)&&!G.has(L)&&b.push(L)}),[...f].forEach(L=>L(g,{deletedFetchers:b,viewTransitionOpts:E.viewTransitionOpts,flushSync:E.flushSync===!0})),b.forEach(L=>Hr(L)),D.forEach(L=>g.fetchers.delete(L))}function wt(p,E,{flushSync:b}={}){let D=g.actionData!=null&&g.navigation.formMethod!=null&&ye(g.navigation.formMethod)&&g.navigation.state==="loading"&&p.state?._isRedirect!==!0,L;E.actionData?Object.keys(E.actionData).length>0?L=E.actionData:L=null:D?L=g.actionData:L=null;let H=E.loaderData?Pn(g.loaderData,E.loaderData,E.matches||[],E.errors):g.loaderData,j=g.blockers;j.size>0&&(j=new Map(j),j.forEach((z,B)=>j.set(B,pt)));let N=Y?!1:nn(p,E.matches||g.matches),U=_===!0||g.navigation.formMethod!=null&&ye(g.navigation.formMethod)&&p.state?._isRedirect!==!0;s&&(l=s,s=void 0),Y||O==="POP"||(O==="PUSH"?e.history.push(p,p.state):O==="REPLACE"&&e.history.replace(p,p.state));let W;if(O==="POP"){let z=X.get(g.location.pathname);z&&z.has(p.pathname)?W={currentLocation:g.location,nextLocation:p}:X.has(p.pathname)&&(W={currentLocation:p,nextLocation:g.location})}else if($){let z=X.get(g.location.pathname);z?z.add(p.pathname):(z=new Set([p.pathname]),X.set(g.location.pathname,z)),W={currentLocation:g.location,nextLocation:p}}he({...E,actionData:L,loaderData:H,historyAction:O,location:p,initialized:!0,navigation:lr,revalidation:"idle",restoreScrollPosition:N,preventScrollReset:U,blockers:j},{viewTransitionOpts:W,flushSync:b===!0}),O="POP",_=!1,$=!1,Y=!1,Q=!1,Mt?.resolve(),Mt=null}async function Ka(p,E){if(typeof p=="number"){e.history.go(p);return}let b=Zr(g.location,g.matches,u,p,E?.fromRouteId,E?.relative),{path:D,submission:L,error:H}=yn(!1,b,E),j=g.location,N=Ye(g.location,D,E&&E.state);N={...N,...e.history.encodeLocation(N)};let U=E&&E.replace!=null?E.replace:void 0,W="PUSH";U===!0?W="REPLACE":U===!1||L!=null&&ye(L.formMethod)&&L.formAction===g.location.pathname+g.location.search&&(W="REPLACE");let z=E&&"preventScrollReset"in E?E.preventScrollReset===!0:void 0,B=(E&&E.flushSync)===!0,J=rn({currentLocation:j,nextLocation:N,historyAction:W});if(J){Xt(J,{state:"blocked",location:N,proceed(){Xt(J,{state:"proceeding",proceed:void 0,reset:void 0,location:N}),Ka(p,E)},reset(){let re=new Map(g.blockers);re.set(J,pt),he({blockers:re})}});return}await st(W,N,{submission:L,pendingError:H,preventScrollReset:z,replace:E&&E.replace,enableViewTransition:E&&E.viewTransition,flushSync:B})}function Qi(){Mt||(Mt=us()),Ir(),he({revalidation:"loading"});let p=Mt.promise;return g.navigation.state==="submitting"?p:g.navigation.state==="idle"?(st(g.historyAction,g.location,{startUninterruptedRevalidation:!0}),p):(st(O||g.historyAction,g.navigation.location,{overrideNavigation:g.navigation,enableViewTransition:$===!0}),p)}async function st(p,E,b){T&&T.abort(),T=null,O=p,Y=(b&&b.startUninterruptedRevalidation)===!0,sl(g.location,g.matches),_=(b&&b.preventScrollReset)===!0,$=(b&&b.enableViewTransition)===!0;let D=s||l,L=b&&b.overrideNavigation,H=b?.initialHydration&&g.matches&&g.matches.length>0&&!S?g.matches:Ce(D,E,u),j=(b&&b.flushSync)===!0;if(H&&g.initialized&&!Q&&rs(g.location,E)&&!(b&&b.submission&&ye(b.submission.formMethod))){wt(E,{matches:H},{flushSync:j});return}let N=Gt(H,D,E.pathname);if(N.active&&N.matches&&(H=N.matches),!H){let{error:ce,notFoundMatches:ee,route:te}=jr(E.pathname);wt(E,{matches:ee,loaderData:{},errors:{[te.id]:ce}},{flushSync:j});return}T=new AbortController;let U=Et(e.history,E,T.signal,b&&b.submission),W=e.getContext?await e.getContext():new Ve,z;if(b&&b.pendingError)z=[Te(H).route.id,{type:"error",error:b.pendingError}];else if(b&&b.submission&&ye(b.submission.formMethod)){let ce=await Zi(U,E,b.submission,H,W,N.active,b&&b.initialHydration===!0,{replace:b.replace,flushSync:j});if(ce.shortCircuited)return;if(ce.pendingActionResult){let[ee,te]=ce.pendingActionResult;if(de(te)&&ie(te.error)&&te.error.status===404){T=null,wt(E,{matches:ce.matches,loaderData:{},errors:{[ee]:te.error}});return}}H=ce.matches||H,z=ce.pendingActionResult,L=Wr(E,b.submission),j=!1,N.active=!1,U=Et(e.history,U.url,U.signal)}let{shortCircuited:B,matches:J,loaderData:re,errors:se}=await qi(U,E,H,W,N.active,L,b&&b.submission,b&&b.fetcherSubmission,b&&b.replace,b&&b.initialHydration===!0,j,z);B||(T=null,wt(E,{matches:J||H,...Dn(z),loaderData:re,errors:se}))}async function Zi(p,E,b,D,L,H,j,N={}){Ir();let U=os(E,b);if(he({navigation:U},{flushSync:N.flushSync===!0}),H){let B=await Qt(D,E.pathname,p.signal);if(B.type==="aborted")return{shortCircuited:!0};if(B.type==="error"){if(B.partialMatches.length===0){let{matches:re,route:se}=bt(l);return{matches:re,pendingActionResult:[se.id,{type:"error",error:B.error}]}}let J=Te(B.partialMatches).route.id;return{matches:B.partialMatches,pendingActionResult:[J,{type:"error",error:B.error}]}}else if(B.matches)D=B.matches;else{let{notFoundMatches:J,error:re,route:se}=jr(E.pathname);return{matches:J,pendingActionResult:[se.id,{type:"error",error:re}]}}}let W,z=Ct(D,E);if(!z.route.action&&!z.route.lazy)W={type:"error",error:oe(405,{method:p.method,pathname:E.pathname,routeId:z.route.id})};else{let B=tt(o,i,p,D,z,j?[]:a,L),J=await Ot(p,B,L,null);if(W=J[z.route.id],!W){for(let re of D)if(J[re.route.id]){W=J[re.route.id];break}}if(p.signal.aborted)return{shortCircuited:!0}}if(et(W)){let B;return N&&N.replace!=null?B=N.replace:B=Sn(W.response.headers.get("Location"),new URL(p.url),u)===g.location.pathname+g.location.search,await ut(p,W,!0,{submission:b,replace:B}),{shortCircuited:!0}}if(de(W)){let B=Te(D,z.route.id);return(N&&N.replace)!==!0&&(O="PUSH"),{matches:D,pendingActionResult:[B.route.id,W,z.route.id]}}return{matches:D,pendingActionResult:[z.route.id,W]}}async function qi(p,E,b,D,L,H,j,N,U,W,z,B){let J=H||Wr(E,j),re=j||N||Ln(J),se=!Y&&!W;if(L){if(se){let me=Xa(B);he({navigation:J,...me!==void 0?{actionData:me}:{}},{flushSync:z})}let K=await Qt(b,E.pathname,p.signal);if(K.type==="aborted")return{shortCircuited:!0};if(K.type==="error"){if(K.partialMatches.length===0){let{matches:Rt,route:ft}=bt(l);return{matches:Rt,loaderData:{},errors:{[ft.id]:K.error}}}let me=Te(K.partialMatches).route.id;return{matches:K.partialMatches,loaderData:{},errors:{[me]:K.error}}}else if(K.matches)b=K.matches;else{let{error:me,notFoundMatches:Rt,route:ft}=jr(E.pathname);return{matches:Rt,loaderData:{},errors:{[ft.id]:me}}}}let ce=s||l,{dsMatches:ee,revalidatingFetchers:te}=vn(p,D,o,i,e.history,g,b,re,E,W?[]:a,W===!0,Q,fe,Ae,_e,be,ce,u,e.patchRoutesOnNavigation!=null,B);if(Ee=++Le,!e.dataStrategy&&!ee.some(K=>K.shouldLoad)&&!ee.some(K=>K.route.middleware&&K.route.middleware.length>0)&&te.length===0){let K=qa();return wt(E,{matches:b,loaderData:{},errors:B&&de(B[1])?{[B[0]]:B[1].error}:null,...Dn(B),...K?{fetchers:new Map(g.fetchers)}:{}},{flushSync:z}),{shortCircuited:!0}}if(se){let K={};if(!L){K.navigation=J;let me=Xa(B);me!==void 0&&(K.actionData=me)}te.length>0&&(K.fetchers=el(te)),he(K,{flushSync:z})}te.forEach(K=>{ze(K.key),K.controller&&G.set(K.key,K.controller)});let ct=()=>te.forEach(K=>ze(K.key));T&&T.signal.addEventListener("abort",ct);let{loaderResults:Ft,fetcherResults:Ge}=await Ga(ee,te,p,D);if(p.signal.aborted)return{shortCircuited:!0};T&&T.signal.removeEventListener("abort",ct),te.forEach(K=>G.delete(K.key));let $e=tr(Ft);if($e)return await ut(p,$e.result,!0,{replace:U}),{shortCircuited:!0};if($e=tr(Ge),$e)return be.add($e.key),await ut(p,$e.result,!0,{replace:U}),{shortCircuited:!0};let{loaderData:Ur,errors:Nt}=xn(g,b,Ft,B,te,Ge);W&&g.errors&&(Nt={...g.errors,...Nt});let dt=qa(),Zt=en(Ee),qt=dt||Zt||te.length>0;return{matches:b,loaderData:Ur,errors:Nt,...qt?{fetchers:new Map(g.fetchers)}:{}}}function Xa(p){if(p&&!de(p[1]))return{[p[0]]:p[1].data};if(g.actionData)return Object.keys(g.actionData).length===0?null:g.actionData}function el(p){return p.forEach(E=>{let b=g.fetchers.get(E.key),D=At(void 0,b?b.data:void 0);g.fetchers.set(E.key,D)}),new Map(g.fetchers)}async function tl(p,E,b,D){ze(p);let L=(D&&D.flushSync)===!0,H=s||l,j=Zr(g.location,g.matches,u,b,E,D?.relative),N=Ce(H,j,u),U=Gt(N,H,j);if(U.active&&U.matches&&(N=U.matches),!N){Ue(p,E,oe(404,{pathname:j}),{flushSync:L});return}let{path:W,submission:z,error:B}=yn(!0,j,D);if(B){Ue(p,E,B,{flushSync:L});return}let J=e.getContext?await e.getContext():new Ve,re=(D&&D.preventScrollReset)===!0;if(z&&ye(z.formMethod)){await rl(p,E,W,N,J,U.active,L,re,z);return}_e.set(p,{routeId:E,path:W}),await al(p,E,W,N,J,U.active,L,re,z)}async function rl(p,E,b,D,L,H,j,N,U){Ir(),_e.delete(p);let W=g.fetchers.get(p);je(p,is(U,W),{flushSync:j});let z=new AbortController,B=Et(e.history,b,z.signal,U);if(H){let ne=await Qt(D,new URL(B.url).pathname,B.signal,p);if(ne.type==="aborted")return;if(ne.type==="error"){Ue(p,E,ne.error,{flushSync:j});return}else if(ne.matches)D=ne.matches;else{Ue(p,E,oe(404,{pathname:b}),{flushSync:j});return}}let J=Ct(D,b);if(!J.route.action&&!J.route.lazy){let ne=oe(405,{method:U.formMethod,pathname:b,routeId:E});Ue(p,E,ne,{flushSync:j});return}G.set(p,z);let re=Le,se=tt(o,i,B,D,J,a,L),ce=await Ot(B,se,L,p),ee=ce[J.route.id];if(!ee){for(let ne of se)if(ce[ne.route.id]){ee=ce[ne.route.id];break}}if(B.signal.aborted){G.get(p)===z&&G.delete(p);return}if(Ae.has(p)){if(et(ee)||de(ee)){je(p,We(void 0));return}}else{if(et(ee))if(G.delete(p),Ee>re){je(p,We(void 0));return}else return be.add(p),je(p,At(U)),ut(B,ee,!1,{fetcherSubmission:U,preventScrollReset:N});if(de(ee)){Ue(p,E,ee.error);return}}let te=g.navigation.location||g.location,ct=Et(e.history,te,z.signal),Ft=s||l,Ge=g.navigation.state!=="idle"?Ce(Ft,g.navigation.location,u):g.matches;I(Ge,"Didn't find any matches after fetcher action");let $e=++Le;Fe.set(p,$e);let Ur=At(U,ee.data);g.fetchers.set(p,Ur);let{dsMatches:Nt,revalidatingFetchers:dt}=vn(ct,L,o,i,e.history,g,Ge,U,te,a,!1,Q,fe,Ae,_e,be,Ft,u,e.patchRoutesOnNavigation!=null,[J.route.id,ee]);dt.filter(ne=>ne.key!==p).forEach(ne=>{let er=ne.key,ln=g.fetchers.get(er),dl=At(void 0,ln?ln.data:void 0);g.fetchers.set(er,dl),ze(er),ne.controller&&G.set(er,ne.controller)}),he({fetchers:new Map(g.fetchers)});let Zt=()=>dt.forEach(ne=>ze(ne.key));z.signal.addEventListener("abort",Zt);let{loaderResults:qt,fetcherResults:K}=await Ga(Nt,dt,ct,L);if(z.signal.aborted)return;if(z.signal.removeEventListener("abort",Zt),Fe.delete(p),G.delete(p),dt.forEach(ne=>G.delete(ne.key)),g.fetchers.has(p)){let ne=We(ee.data);g.fetchers.set(p,ne)}let me=tr(qt);if(me)return ut(ct,me.result,!1,{preventScrollReset:N});if(me=tr(K),me)return be.add(me.key),ut(ct,me.result,!1,{preventScrollReset:N});let{loaderData:Rt,errors:ft}=xn(g,Ge,qt,void 0,dt,K);en($e),g.navigation.state==="loading"&&$e>Ee?(I(O,"Expected pending action"),T&&T.abort(),wt(g.navigation.location,{matches:Ge,loaderData:Rt,errors:ft,fetchers:new Map(g.fetchers)})):(he({errors:ft,loaderData:Pn(g.loaderData,Rt,Ge,ft),fetchers:new Map(g.fetchers)}),Q=!1)}async function al(p,E,b,D,L,H,j,N,U){let W=g.fetchers.get(p);je(p,At(U,W?W.data:void 0),{flushSync:j});let z=new AbortController,B=Et(e.history,b,z.signal);if(H){let te=await Qt(D,new URL(B.url).pathname,B.signal,p);if(te.type==="aborted")return;if(te.type==="error"){Ue(p,E,te.error,{flushSync:j});return}else if(te.matches)D=te.matches;else{Ue(p,E,oe(404,{pathname:b}),{flushSync:j});return}}let J=Ct(D,b);G.set(p,z);let re=Le,se=tt(o,i,B,D,J,a,L),ee=(await Ot(B,se,L,p))[J.route.id];if(G.get(p)===z&&G.delete(p),!B.signal.aborted){if(Ae.has(p)){je(p,We(void 0));return}if(et(ee))if(Ee>re){je(p,We(void 0));return}else{be.add(p),await ut(B,ee,!1,{preventScrollReset:N});return}if(de(ee)){Ue(p,E,ee.error);return}je(p,We(ee.data))}}async function ut(p,E,b,{submission:D,fetcherSubmission:L,preventScrollReset:H,replace:j}={}){E.response.headers.has("X-Remix-Revalidate")&&(Q=!0);let N=E.response.headers.get("Location");I(N,"Expected a Location header on the redirect Response"),N=Sn(N,new URL(p.url),u);let U=Ye(g.location,N,{_isRedirect:!0});if(r){let se=!1;if(E.response.headers.has("X-Remix-Reload-Document"))se=!0;else if(Rr(N)){const ce=Zn(N,!0);se=ce.origin!==t.location.origin||ue(ce.pathname,u)==null}if(se){j?t.location.replace(N):t.location.assign(N);return}}T=null;let W=j===!0||E.response.headers.has("X-Remix-Replace")?"REPLACE":"PUSH",{formMethod:z,formAction:B,formEncType:J}=g.navigation;!D&&!L&&z&&B&&J&&(D=Ln(g.navigation));let re=D||L;if(Kl.has(E.response.status)&&re&&ye(re.formMethod))await st(W,U,{submission:{...re,formAction:N},preventScrollReset:H||_,enableViewTransition:b?$:void 0});else{let se=Wr(U,D);await st(W,U,{overrideNavigation:se,fetcherSubmission:L,preventScrollReset:H||_,enableViewTransition:b?$:void 0})}}async function Ot(p,E,b,D){let L,H={};try{L=await bo(d,p,E,D,b,!1)}catch(j){return E.filter(N=>N.shouldLoad).forEach(N=>{H[N.route.id]={type:"error",error:j}}),H}if(p.signal.aborted)return H;for(let[j,N]of Object.entries(L))if(_o(N)){let U=N.result;H[j]={type:"redirect",response:xo(U,p,j,E,u)}}else H[j]=await Co(N);return H}async function Ga(p,E,b,D){let L=Ot(b,p,D,null),H=Promise.all(E.map(async U=>{if(U.matches&&U.match&&U.request&&U.controller){let z=(await Ot(U.request,U.matches,D,U.key))[U.match.route.id];return{[U.key]:z}}else return Promise.resolve({[U.key]:{type:"error",error:oe(404,{pathname:U.path})}})})),j=await L,N=(await H).reduce((U,W)=>Object.assign(U,W),{});return{loaderResults:j,fetcherResults:N}}function Ir(){Q=!0,_e.forEach((p,E)=>{G.has(E)&&fe.add(E),ze(E)})}function je(p,E,b={}){g.fetchers.set(p,E),he({fetchers:new Map(g.fetchers)},{flushSync:(b&&b.flushSync)===!0})}function Ue(p,E,b,D={}){let L=Te(g.matches,E);Hr(p),he({errors:{[L.route.id]:b},fetchers:new Map(g.fetchers)},{flushSync:(D&&D.flushSync)===!0})}function Qa(p){return Ne.set(p,(Ne.get(p)||0)+1),Ae.has(p)&&Ae.delete(p),g.fetchers.get(p)||ba}function nl(p,E){ze(p,E?.reason),je(p,We(null))}function Hr(p){let E=g.fetchers.get(p);G.has(p)&&!(E&&E.state==="loading"&&Fe.has(p))&&ze(p),_e.delete(p),Fe.delete(p),be.delete(p),Ae.delete(p),fe.delete(p),g.fetchers.delete(p)}function ol(p){let E=(Ne.get(p)||0)-1;E<=0?(Ne.delete(p),Ae.add(p)):Ne.set(p,E),he({fetchers:new Map(g.fetchers)})}function ze(p,E){let b=G.get(p);b&&(b.abort(E),G.delete(p))}function Za(p){for(let E of p){let b=Qa(E),D=We(b.data);g.fetchers.set(E,D)}}function qa(){let p=[],E=!1;for(let b of be){let D=g.fetchers.get(b);I(D,`Expected fetcher: ${b}`),D.state==="loading"&&(be.delete(b),p.push(b),E=!0)}return Za(p),E}function en(p){let E=[];for(let[b,D]of Fe)if(D<p){let L=g.fetchers.get(b);I(L,`Expected fetcher: ${b}`),L.state==="loading"&&(ze(b),Fe.delete(b),E.push(b))}return Za(E),E.length>0}function il(p,E){let b=g.blockers.get(p)||pt;return lt.get(p)!==E&<.set(p,E),b}function tn(p){g.blockers.delete(p),lt.delete(p)}function Xt(p,E){let b=g.blockers.get(p)||pt;I(b.state==="unblocked"&&E.state==="blocked"||b.state==="blocked"&&E.state==="blocked"||b.state==="blocked"&&E.state==="proceeding"||b.state==="blocked"&&E.state==="unblocked"||b.state==="proceeding"&&E.state==="unblocked",`Invalid blocker state transition: ${b.state} -> ${E.state}`);let D=new Map(g.blockers);D.set(p,E),he({blockers:D})}function rn({currentLocation:p,nextLocation:E,historyAction:b}){if(lt.size===0)return;lt.size>1&&Z(!1,"A router only supports one blocker at a time");let D=Array.from(lt.entries()),[L,H]=D[D.length-1],j=g.blockers.get(L);if(!(j&&j.state==="proceeding")&&H({currentLocation:p,nextLocation:E,historyAction:b}))return L}function jr(p){let E=oe(404,{pathname:p}),b=s||l,{matches:D,route:L}=bt(b);return{notFoundMatches:D,route:L,error:E}}function ll(p,E,b){if(h=p,y=E,v=b||null,!R&&g.navigation===lr){R=!0;let D=nn(g.location,g.matches);D!=null&&he({restoreScrollPosition:D})}return()=>{h=null,y=null,v=null}}function an(p,E){return v&&v(p,E.map(D=>qn(D,g.loaderData)))||p.key}function sl(p,E){if(h&&y){let b=an(p,E);h[b]=y()}}function nn(p,E){if(h){let b=an(p,E),D=h[b];if(typeof D=="number")return D}return null}function Gt(p,E,b){if(e.patchRoutesOnNavigation)if(p){if(Object.keys(p[0].params).length>0)return{active:!0,matches:jt(E,b,u,!0)}}else return{active:!0,matches:jt(E,b,u,!0)||[]};return{active:!1,matches:null}}async function Qt(p,E,b,D){if(!e.patchRoutesOnNavigation)return{type:"success",matches:p};let L=p;for(;;){let H=s==null,j=s||l,N=i;try{await e.patchRoutesOnNavigation({signal:b,path:E,matches:L,fetcherKey:D,patch:(z,B)=>{b.aborted||gn(z,B,j,N,o,!1)}})}catch(z){return{type:"error",error:z,partialMatches:L}}finally{H&&!b.aborted&&(l=[...l])}if(b.aborted)return{type:"aborted"};let U=Ce(j,E,u),W=null;if(U){if(Object.keys(U[0].params).length===0)return{type:"success",matches:U};if(W=jt(j,E,u,!0),!(W&&L.length<W.length&&on(L,W.slice(0,L.length))))return{type:"success",matches:U}}if(W||(W=jt(j,E,u,!0)),!W||on(L,W))return{type:"success",matches:null};L=W}}function on(p,E){return p.length===E.length&&p.every((b,D)=>b.route.id===E[D].route.id)}function ul(p){i={},s=at(p,o,void 0,i)}function cl(p,E,b=!1){let D=s==null;gn(p,E,s||l,i,o,b),D&&(l=[...l],he({}))}return x={get basename(){return u},get future(){return c},get state(){return g},get routes(){return l},get window(){return t},initialize:Ki,subscribe:Gi,enableScrollRestoration:ll,navigate:Ka,fetch:tl,revalidate:Qi,createHref:p=>e.history.createHref(p),encodeLocation:p=>e.history.encodeLocation(p),getFetcher:Qa,resetFetcher:nl,deleteFetcher:ol,dispose:Xi,getBlocker:il,deleteBlocker:tn,patchRoutes:cl,_internalFetchControllers:G,_internalSetRoutes:ul,_internalSetStateDoNotUseOrYouWillBreakYourApp(p){he(p)}},e.unstable_instrumentations&&(x=Ul(x,e.unstable_instrumentations.map(p=>p.router).filter(Boolean))),x}function po(e,t){I(e.length>0,"You must provide a non-empty routes array to createStaticHandler");let r={},a=(t?t.basename:null)||"/",n=t?.mapRouteProperties||fo,o=n;if(t?.unstable_instrumentations){let f=t.unstable_instrumentations;o=h=>({...n(h),...oo(f.map(v=>v.route).filter(Boolean),h)})}let i=at(e,o,void 0,r);async function l(f,{requestContext:h,filterMatchesToLoad:v,skipLoaderErrorBubbling:y,skipRevalidation:R,dataStrategy:w,generateMiddlewareResponse:S}={}){let P=new URL(f.url),C=f.method,x=Ye("",we(P),null,"default"),g=Ce(i,x,a);if(h=h??new Ve,!aa(C)&&C!=="HEAD"){let _=oe(405,{method:C}),{matches:T,route:$}=bt(i),X={basename:a,location:x,matches:T,loaderData:{},actionData:null,errors:{[$.id]:_},statusCode:_.status,loaderHeaders:{},actionHeaders:{}};return S?S(()=>Promise.resolve(X)):X}else if(!g){let _=oe(404,{pathname:x.pathname}),{matches:T,route:$}=bt(i),X={basename:a,location:x,matches:T,loaderData:{},actionData:null,errors:{[$.id]:_},statusCode:_.status,loaderHeaders:{},actionHeaders:{}};return S?S(()=>Promise.resolve(X)):X}if(S){I(h instanceof Ve,"When using middleware in `staticHandler.query()`, any provided `requestContext` must be an instance of `RouterContextProvider`");try{await En(g,r,o);let _,T=await bn({request:f,unstable_pattern:St(g.map($=>$.route.path)),matches:g,params:g[0].params,context:h},async()=>await S(async(X,q={})=>{let Y=await u(X,x,g,h,w||null,y===!0,null,"filterMatchesToLoad"in q?q.filterMatchesToLoad??null:v??null,R===!0);return ae(Y)?Y:(_={location:x,basename:a,...Y},_)}),async($,X)=>{if(hr($))return $;if(ae($))try{$=new Re($.status,$.statusText,await So($))}catch(q){$=q}if(rt($)&&($=as($)),_){X in _.loaderData&&(_.loaderData[X]=void 0);let q=yo(i,_,$,y?X:Te(g,X).route.id);return S(()=>Promise.resolve(q))}else{let q=y?X:Te(g,g.find(Q=>Q.route.id===X||Q.route.loader)?.route.id||X).route.id,Y={matches:g,location:x,basename:a,loaderData:{},actionData:null,errors:{[q]:$},statusCode:ie($)?$.status:500,actionHeaders:{},loaderHeaders:{}};return S(()=>Promise.resolve(Y))}});return I(ae(T),"Expected a response in query()"),T}catch(_){if(ae(_))return _;throw _}}let O=await u(f,x,g,h,w||null,y===!0,null,v||null,R===!0);return ae(O)?O:{location:x,basename:a,...O}}async function s(f,{routeId:h,requestContext:v,dataStrategy:y,generateMiddlewareResponse:R}={}){let w=new URL(f.url),S=f.method,P=Ye("",we(w),null,"default"),C=Ce(i,P,a);if(v=v??new Ve,!aa(S)&&S!=="HEAD"&&S!=="OPTIONS")throw oe(405,{method:S});if(!C)throw oe(404,{pathname:P.pathname});let x=h?C.find(_=>_.route.id===h):Ct(C,P);if(h&&!x)throw oe(403,{pathname:P.pathname,routeId:h});if(!x)throw oe(404,{pathname:P.pathname});if(R)return I(v instanceof Ve,"When using middleware in `staticHandler.queryRoute()`, any provided `requestContext` must be an instance of `RouterContextProvider`"),await En(C,r,o),await bn({request:f,unstable_pattern:St(C.map(T=>T.route.path)),matches:C,params:C[0].params,context:v},async()=>await R(async $=>{let X=await u($,P,C,v,y||null,!1,x,null,!1),q=O(X);return ae(q)?q:typeof q=="string"?new Response(q):Response.json(q)}),T=>{if(rt(T))return Promise.resolve(ra(T));if(ae(T))return Promise.resolve(T);throw T});let g=await u(f,P,C,v,y||null,!1,x,null,!1);return O(g);function O(_){if(ae(_))return _;let T=_.errors?Object.values(_.errors)[0]:void 0;if(T!==void 0)throw T;if(_.actionData)return Object.values(_.actionData)[0];if(_.loaderData)return Object.values(_.loaderData)[0]}}async function u(f,h,v,y,R,w,S,P,C){I(f.signal,"query()/queryRoute() requests must contain an AbortController signal");try{if(ye(f.method))return await d(f,v,S||Ct(v,h),y,R,w,S!=null,P,C);let x=await c(f,v,y,R,w,S,P);return ae(x)?x:{...x,actionData:null,actionHeaders:{}}}catch(x){if(Lo(x)&&ae(x.result)){if(x.type==="error")throw x.result;return x.result}if(hr(x))return x;throw x}}async function d(f,h,v,y,R,w,S,P,C){let x;if(!v.route.action&&!v.route.lazy){let _=oe(405,{method:f.method,pathname:new URL(f.url).pathname,routeId:v.route.id});if(S)throw _;x={type:"error",error:_}}else{let _=tt(o,r,f,h,v,[],y);x=(await m(f,_,S,y,R))[v.route.id],f.signal.aborted&&pn(f,S)}if(et(x))throw new Response(null,{status:x.response.status,headers:{Location:x.response.headers.get("Location")}});if(S){if(de(x))throw x.error;return{matches:[v],loaderData:{},actionData:{[v.route.id]:x.data},errors:null,statusCode:200,loaderHeaders:{},actionHeaders:{}}}if(C)if(de(x)){let _=w?v:Te(h,v.route.id);return{statusCode:ie(x.error)?x.error.status:x.statusCode!=null?x.statusCode:500,actionData:null,actionHeaders:{...x.headers?{[v.route.id]:x.headers}:{}},matches:h,loaderData:{},errors:{[_.route.id]:x.error},loaderHeaders:{}}}else return{actionData:{[v.route.id]:x.data},actionHeaders:x.headers?{[v.route.id]:x.headers}:{},matches:h,loaderData:{},errors:null,statusCode:x.statusCode||200,loaderHeaders:{}};let g=new Request(f.url,{headers:f.headers,redirect:f.redirect,signal:f.signal});if(de(x)){let _=w?v:Te(h,v.route.id);return{...await c(g,h,y,R,w,null,P,[_.route.id,x]),statusCode:ie(x.error)?x.error.status:x.statusCode!=null?x.statusCode:500,actionData:null,actionHeaders:{...x.headers?{[v.route.id]:x.headers}:{}}}}return{...await c(g,h,y,R,w,null,P),actionData:{[v.route.id]:x.data},...x.statusCode?{statusCode:x.statusCode}:{},actionHeaders:x.headers?{[v.route.id]:x.headers}:{}}}async function c(f,h,v,y,R,w,S,P){let C=w!=null;if(C&&!w?.route.loader&&!w?.route.lazy)throw oe(400,{method:f.method,pathname:new URL(f.url).pathname,routeId:w?.route.id});let x;if(w)x=tt(o,r,f,h,w,[],v);else{let _=P&&de(P[1])?h.findIndex($=>$.route.id===P[0])-1:void 0,T=St(h.map($=>$.route.path));x=h.map(($,X)=>_!=null&&X>_?Bt(o,r,f,T,$,[],v,!1):Bt(o,r,f,T,$,[],v,($.route.loader||$.route.lazy)!=null&&(!S||S($))))}if(!y&&!x.some(_=>_.shouldLoad))return{matches:h,loaderData:{},errors:P&&de(P[1])?{[P[0]]:P[1].error}:null,statusCode:200,loaderHeaders:{}};let g=await m(f,x,C,v,y);return f.signal.aborted&&pn(f,C),{...Po(h,g,P,!0,R),matches:h}}async function m(f,h,v,y,R){let w=await bo(R||ea,f,h,null,y,!0),S={};return await Promise.all(h.map(async P=>{if(!(P.route.id in w))return;let C=w[P.route.id];if(_o(C)){let x=C.result;throw xo(x,f,P.route.id,h,a)}if(v){if(ae(C.result))throw C;if(rt(C.result))throw ra(C.result)}S[P.route.id]=await Co(C)})),S}return{dataRoutes:i,query:l,queryRoute:s}}function yo(e,t,r,a){let n=a||t._deepestRenderedBoundaryId||e[0].id;return{...t,statusCode:ie(r)?r.status:500,errors:{[n]:r}}}function pn(e,t){if(e.signal.reason!==void 0)throw e.signal.reason;let r=t?"queryRoute":"query";throw new Error(`${r}() call aborted without an \`AbortSignal.reason\`: ${e.method} ${e.url}`)}function Xl(e){return e!=null&&("formData"in e&&e.formData!=null||"body"in e&&e.body!==void 0)}function Zr(e,t,r,a,n,o){let i,l;if(n){i=[];for(let u of t)if(i.push(u),u.route.id===n){l=u;break}}else i=t,l=t[t.length-1];let s=br(a||".",Er(i),ue(e.pathname,r)||e.pathname,o==="path");if(a==null&&(s.search=e.search,s.hash=e.hash),(a==null||a===""||a===".")&&l){let u=xa(s.search);if(l.route.index&&!u)s.search=s.search?s.search.replace(/^\?/,"?index&"):"?index";else if(!l.route.index&&u){let d=new URLSearchParams(s.search),c=d.getAll("index");d.delete("index"),c.filter(f=>f).forEach(f=>d.append("index",f));let m=d.toString();s.search=m?`?${m}`:""}}return r!=="/"&&(s.pathname=Tl({basename:r,pathname:s.pathname})),we(s)}function yn(e,t,r){if(!r||!Xl(r))return{path:t};if(r.formMethod&&!aa(r.formMethod))return{path:t,error:oe(405,{method:r.formMethod})};let a=()=>({path:t,error:oe(400,{type:"invalid-body"})}),o=(r.formMethod||"get").toUpperCase(),i=Do(t);if(r.body!==void 0){if(r.formEncType==="text/plain"){if(!ye(o))return a();let c=typeof r.body=="string"?r.body:r.body instanceof FormData||r.body instanceof URLSearchParams?Array.from(r.body.entries()).reduce((m,[f,h])=>`${m}${f}=${h}
|
|
11
|
+
`,""):String(r.body);return{path:t,submission:{formMethod:o,formAction:i,formEncType:r.formEncType,formData:void 0,json:void 0,text:c}}}else if(r.formEncType==="application/json"){if(!ye(o))return a();try{let c=typeof r.body=="string"?JSON.parse(r.body):r.body;return{path:t,submission:{formMethod:o,formAction:i,formEncType:r.formEncType,formData:void 0,json:c,text:void 0}}}catch{return a()}}}I(typeof FormData=="function","FormData is not available in this environment");let l,s;if(r.formData)l=ta(r.formData),s=r.formData;else if(r.body instanceof FormData)l=ta(r.body),s=r.body;else if(r.body instanceof URLSearchParams)l=r.body,s=Cn(l);else if(r.body==null)l=new URLSearchParams,s=new FormData;else try{l=new URLSearchParams(r.body),s=Cn(l)}catch{return a()}let u={formMethod:o,formAction:i,formEncType:r&&r.formEncType||"application/x-www-form-urlencoded",formData:s,json:void 0,text:void 0};if(ye(u.formMethod))return{path:t,submission:u};let d=Me(t);return e&&d.search&&xa(d.search)&&l.append("index",""),d.search=`?${l}`,{path:we(d),submission:u}}function vn(e,t,r,a,n,o,i,l,s,u,d,c,m,f,h,v,y,R,w,S){let P=S?de(S[1])?S[1].error:S[1].data:void 0,C=n.createURL(o.location),x=n.createURL(s),g;if(d&&o.errors){let Y=Object.keys(o.errors)[0];g=i.findIndex(Q=>Q.route.id===Y)}else if(S&&de(S[1])){let Y=S[0];g=i.findIndex(Q=>Q.route.id===Y)-1}let O=S?S[1].statusCode:void 0,_=O&&O>=400,T={currentUrl:C,currentParams:o.matches[0]?.params||{},nextUrl:x,nextParams:i[0].params,...l,actionResult:P,actionStatus:O},$=St(i.map(Y=>Y.route.path)),X=i.map((Y,Q)=>{let{route:fe}=Y,G=null;if(g!=null&&Q>g?G=!1:fe.lazy?G=!0:Sa(fe)?d?G=qr(fe,o.loaderData,o.errors):Gl(o.loaderData,o.matches[Q],Y)&&(G=!0):G=!1,G!==null)return Bt(r,a,e,$,Y,u,t,G);let Le=_?!1:c||C.pathname+C.search===x.pathname+x.search||C.search!==x.search||Ql(o.matches[Q],Y),Ee={...T,defaultShouldRevalidate:Le},Fe=fr(Y,Ee);return Bt(r,a,e,$,Y,u,t,Fe,Ee)}),q=[];return h.forEach((Y,Q)=>{if(d||!i.some(Ne=>Ne.route.id===Y.routeId)||f.has(Q))return;let fe=o.fetchers.get(Q),G=fe&&fe.state!=="idle"&&fe.data===void 0,Le=Ce(y,Y.path,R);if(!Le){if(w&&G)return;q.push({key:Q,routeId:Y.routeId,path:Y.path,matches:null,match:null,request:null,controller:null});return}if(v.has(Q))return;let Ee=Ct(Le,Y.path),Fe=new AbortController,be=Et(n,Y.path,Fe.signal),_e=null;if(m.has(Q))m.delete(Q),_e=tt(r,a,be,Le,Ee,u,t);else if(G)c&&(_e=tt(r,a,be,Le,Ee,u,t));else{let Ne={...T,defaultShouldRevalidate:_?!1:c};fr(Ee,Ne)&&(_e=tt(r,a,be,Le,Ee,u,t,Ne))}_e&&q.push({key:Q,routeId:Y.routeId,path:Y.path,matches:_e,match:Ee,request:be,controller:Fe})}),{dsMatches:X,revalidatingFetchers:q}}function Sa(e){return e.loader!=null||e.middleware!=null&&e.middleware.length>0}function qr(e,t,r){if(e.lazy)return!0;if(!Sa(e))return!1;let a=t!=null&&e.id in t,n=r!=null&&r[e.id]!==void 0;return!a&&n?!1:typeof e.loader=="function"&&e.loader.hydrate===!0?!0:!a&&!n}function Gl(e,t,r){let a=!t||r.route.id!==t.route.id,n=!e.hasOwnProperty(r.route.id);return a||n}function Ql(e,t){let r=e.route.path;return e.pathname!==t.pathname||r!=null&&r.endsWith("*")&&e.params["*"]!==t.params["*"]}function fr(e,t){if(e.route.shouldRevalidate){let r=e.route.shouldRevalidate(t);if(typeof r=="boolean")return r}return t.defaultShouldRevalidate}function gn(e,t,r,a,n,o){let i;if(e){let u=a[e];I(u,`No route found to patch children into: routeId = ${e}`),u.children||(u.children=[]),i=u.children}else i=r;let l=[],s=[];if(t.forEach(u=>{let d=i.find(c=>vo(u,c));d?s.push({existingRoute:d,newRoute:u}):l.push(u)}),l.length>0){let u=at(l,n,[e||"_","patch",String(i?.length||"0")],a);i.push(...u)}if(o&&s.length>0)for(let u=0;u<s.length;u++){let{existingRoute:d,newRoute:c}=s[u],m=d,[f]=at([c],n,[],{},!0);Object.assign(m,{element:f.element?f.element:m.element,errorElement:f.errorElement?f.errorElement:m.errorElement,hydrateFallbackElement:f.hydrateFallbackElement?f.hydrateFallbackElement:m.hydrateFallbackElement})}}function vo(e,t){return"id"in e&&"id"in t&&e.id===t.id?!0:e.index===t.index&&e.path===t.path&&e.caseSensitive===t.caseSensitive?(!e.children||e.children.length===0)&&(!t.children||t.children.length===0)?!0:e.children.every((r,a)=>t.children?.some(n=>vo(r,n))):!1}var wn=new WeakMap,Ca=({key:e,route:t,manifest:r,mapRouteProperties:a})=>{let n=r[t.id];if(I(n,"No route found in manifest"),!n.lazy||typeof n.lazy!="object")return;let o=n.lazy[e];if(!o)return;let i=wn.get(n);i||(i={},wn.set(n,i));let l=i[e];if(l)return l;let s=(async()=>{let u=vl(e),c=n[e]!==void 0&&e!=="hasErrorBoundary";if(u)Z(!u,"Route property "+e+" is not a supported lazy route property. This property will be ignored."),i[e]=Promise.resolve();else if(c)Z(!1,`Route "${n.id}" has a static property "${e}" defined. The lazy property will be ignored.`);else{let m=await o();m!=null&&(Object.assign(n,{[e]:m}),Object.assign(n,a(n)))}typeof n.lazy=="object"&&(n.lazy[e]=void 0,Object.values(n.lazy).every(m=>m===void 0)&&(n.lazy=void 0))})();return i[e]=s,s},Rn=new WeakMap;function Zl(e,t,r,a,n){let o=r[e.id];if(I(o,"No route found in manifest"),!e.lazy)return{lazyRoutePromise:void 0,lazyHandlerPromise:void 0};if(typeof e.lazy=="function"){let d=Rn.get(o);if(d)return{lazyRoutePromise:d,lazyHandlerPromise:d};let c=(async()=>{I(typeof e.lazy=="function","No lazy route function found");let m=await e.lazy(),f={};for(let h in m){let v=m[h];if(v===void 0)continue;let y=wl(h),w=o[h]!==void 0&&h!=="hasErrorBoundary";y?Z(!y,"Route property "+h+" is not a supported property to be returned from a lazy route function. This property will be ignored."):w?Z(!w,`Route "${o.id}" has a static property "${h}" defined but its lazy function is also returning a value for this property. The lazy route property "${h}" will be ignored.`):f[h]=v}Object.assign(o,f),Object.assign(o,{...a(o),lazy:void 0})})();return Rn.set(o,c),c.catch(()=>{}),{lazyRoutePromise:c,lazyHandlerPromise:c}}let i=Object.keys(e.lazy),l=[],s;for(let d of i){if(n&&n.includes(d))continue;let c=Ca({key:d,route:e,manifest:r,mapRouteProperties:a});c&&(l.push(c),d===t&&(s=c))}let u=l.length>0?Promise.all(l).then(()=>{}):void 0;return u?.catch(()=>{}),s?.catch(()=>{}),{lazyRoutePromise:u,lazyHandlerPromise:s}}function ql(e){return e!==void 0}function En(e,t,r){let a=e.map(({route:n})=>{if(!(typeof n.lazy!="object"||!n.lazy.middleware))return Ca({key:"middleware",route:n,manifest:t,mapRouteProperties:r})}).filter(ql);return a.length>0?Promise.all(a):void 0}async function ea(e){let t=e.matches.filter(n=>n.shouldLoad),r={};return(await Promise.all(t.map(n=>n.resolve()))).forEach((n,o)=>{r[t[o].route.id]=n}),r}async function es(e){return e.matches.some(t=>t.route.middleware)?go(e,()=>ea(e)):ea(e)}function bn(e,t,r){return wo(e,t,a,ae,r);function a(n){return rt(n)?ra(n):n}}function go(e,t){return wo(e,t,a=>a,ns,r);function r(a,n,o){if(o)return Promise.resolve(Object.assign(o.value,{[n]:{type:"error",result:a}}));{let{matches:i}=e,l=Math.min(Math.max(i.findIndex(u=>u.route.id===n),0),Math.max(i.findIndex(u=>u.unstable_shouldCallHandler()),0)),s=Te(i,i[l].route.id).route.id;return Promise.resolve({[s]:{type:"error",result:a}})}}}async function wo(e,t,r,a,n){let{matches:o,request:i,params:l,context:s,unstable_pattern:u}=e,d=o.flatMap(m=>m.route.middleware?m.route.middleware.map(f=>[m.route.id,f]):[]);return await Ro({request:i,params:l,context:s,unstable_pattern:u},d,t,r,a,n)}async function Ro(e,t,r,a,n,o,i=0){let{request:l}=e;if(l.signal.aborted)throw l.signal.reason??new Error(`Request aborted: ${l.method} ${l.url}`);let s=t[i];if(!s)return await r();let[u,d]=s,c,m=async()=>{if(c)throw new Error("You may only call `next()` once per middleware");try{return c={value:await Ro(e,t,r,a,n,o,i+1)},c.value}catch(f){return c={value:await o(f,u,c)},c.value}};try{let f=await d(e,m),h=f!=null?a(f):void 0;return n(h)?h:c?h??c.value:(c={value:await m()},c.value)}catch(f){return await o(f,u,c)}}function Eo(e,t,r,a,n){let o=Ca({key:"middleware",route:a.route,manifest:t,mapRouteProperties:e}),i=Zl(a.route,ye(r.method)?"action":"loader",t,e,n);return{middleware:o,route:i.lazyRoutePromise,handler:i.lazyHandlerPromise}}function Bt(e,t,r,a,n,o,i,l,s=null){let u=!1,d=Eo(e,t,r,n,o);return{...n,_lazyPromises:d,shouldLoad:l,unstable_shouldRevalidateArgs:s,unstable_shouldCallHandler(c){return u=!0,s?typeof c=="boolean"?fr(n,{...s,defaultShouldRevalidate:c}):fr(n,s):l},resolve(c){let{lazy:m,loader:f,middleware:h}=n.route,v=u||l||c&&!ye(r.method)&&(m||f),y=h&&h.length>0&&!f&&!m;return v&&(ye(r.method)||!y)?ts({request:r,unstable_pattern:a,match:n,lazyHandlerPromise:d?.handler,lazyRoutePromise:d?.route,handlerOverride:c,scopedContext:i}):Promise.resolve({type:"data",result:void 0})}}}function tt(e,t,r,a,n,o,i,l=null){return a.map(s=>s.route.id!==n.route.id?{...s,shouldLoad:!1,unstable_shouldRevalidateArgs:l,unstable_shouldCallHandler:()=>!1,_lazyPromises:Eo(e,t,r,s,o),resolve:()=>Promise.resolve({type:"data",result:void 0})}:Bt(e,t,r,St(a.map(u=>u.route.path)),s,o,i,!0,l))}async function bo(e,t,r,a,n,o){r.some(u=>u._lazyPromises?.middleware)&&await Promise.all(r.map(u=>u._lazyPromises?.middleware));let i={request:t,unstable_pattern:St(r.map(u=>u.route.path)),params:r[0].params,context:n,matches:r},s=await e({...i,fetcherKey:a,runClientMiddleware:o?()=>{throw new Error("You cannot call `runClientMiddleware()` from a static handler `dataStrategy`. Middleware is run outside of `dataStrategy` during SSR in order to bubble up the Response. You can enable middleware via the `respond` API in `query`/`queryRoute`")}:u=>{let d=i;return go(d,()=>u({...d,fetcherKey:a,runClientMiddleware:()=>{throw new Error("Cannot call `runClientMiddleware()` from within an `runClientMiddleware` handler")}}))}});try{await Promise.all(r.flatMap(u=>[u._lazyPromises?.handler,u._lazyPromises?.route]))}catch{}return s}async function ts({request:e,unstable_pattern:t,match:r,lazyHandlerPromise:a,lazyRoutePromise:n,handlerOverride:o,scopedContext:i}){let l,s,u=ye(e.method),d=u?"action":"loader",c=m=>{let f,h=new Promise((R,w)=>f=w);s=()=>f(),e.signal.addEventListener("abort",s);let v=R=>typeof m!="function"?Promise.reject(new Error(`You cannot call the handler for a route which defines a boolean "${d}" [routeId: ${r.route.id}]`)):m({request:e,unstable_pattern:t,params:r.params,context:i},...R!==void 0?[R]:[]),y=(async()=>{try{return{type:"data",result:await(o?o(w=>v(w)):v())}}catch(R){return{type:"error",result:R}}})();return Promise.race([y,h])};try{let m=u?r.route.action:r.route.loader;if(a||n)if(m){let f,[h]=await Promise.all([c(m).catch(v=>{f=v}),a,n]);if(f!==void 0)throw f;l=h}else{await a;let f=u?r.route.action:r.route.loader;if(f)[l]=await Promise.all([c(f),n]);else if(d==="action"){let h=new URL(e.url),v=h.pathname+h.search;throw oe(405,{method:e.method,pathname:v,routeId:r.route.id})}else return{type:"data",result:void 0}}else if(m)l=await c(m);else{let f=new URL(e.url),h=f.pathname+f.search;throw oe(404,{pathname:h})}}catch(m){return{type:"error",result:m}}finally{s&&e.signal.removeEventListener("abort",s)}return l}async function So(e){let t=e.headers.get("Content-Type");return t&&/\bapplication\/json\b/.test(t)?e.body==null?null:e.json():e.text()}async function Co(e){let{result:t,type:r}=e;if(ae(t)){let a;try{a=await So(t)}catch(n){return{type:"error",error:n}}return r==="error"?{type:"error",error:new Re(t.status,t.statusText,a),statusCode:t.status,headers:t.headers}:{type:"data",data:a,statusCode:t.status,headers:t.headers}}return r==="error"?rt(t)?t.data instanceof Error?{type:"error",error:t.data,statusCode:t.init?.status,headers:t.init?.headers?new Headers(t.init.headers):void 0}:{type:"error",error:new Re(t.init?.status||500,void 0,t.data),statusCode:ie(t)?t.status:void 0,headers:t.init?.headers?new Headers(t.init.headers):void 0}:{type:"error",error:t,statusCode:ie(t)?t.status:void 0}:rt(t)?{type:"data",data:t.data,statusCode:t.init?.status,headers:t.init?.headers?new Headers(t.init.headers):void 0}:{type:"data",data:t}}function xo(e,t,r,a,n){let o=e.headers.get("Location");if(I(o,"Redirects returned/thrown from loaders/actions must have a Location header"),!Rr(o)){let i=a.slice(0,a.findIndex(l=>l.route.id===r)+1);o=Zr(new URL(t.url),i,n,o),e.headers.set("Location",o)}return e}function Sn(e,t,r){if(Rr(e)){let a=e,n=a.startsWith("//")?new URL(t.protocol+a):new URL(a),o=ue(n.pathname,r)!=null;if(n.origin===t.origin&&o)return n.pathname+n.search+n.hash}return e}function Et(e,t,r,a){let n=e.createURL(Do(t)).toString(),o={signal:r};if(a&&ye(a.formMethod)){let{formMethod:i,formEncType:l}=a;o.method=i.toUpperCase(),l==="application/json"?(o.headers=new Headers({"Content-Type":l}),o.body=JSON.stringify(a.json)):l==="text/plain"?o.body=a.text:l==="application/x-www-form-urlencoded"&&a.formData?o.body=ta(a.formData):o.body=a.formData}return new Request(n,o)}function ta(e){let t=new URLSearchParams;for(let[r,a]of e.entries())t.append(r,typeof a=="string"?a:a.name);return t}function Cn(e){let t=new FormData;for(let[r,a]of e.entries())t.append(r,a);return t}function Po(e,t,r,a=!1,n=!1){let o={},i=null,l,s=!1,u={},d=r&&de(r[1])?r[1].error:void 0;return e.forEach(c=>{if(!(c.route.id in t))return;let m=c.route.id,f=t[m];if(I(!et(f),"Cannot handle redirect results in processLoaderData"),de(f)){let h=f.error;if(d!==void 0&&(h=d,d=void 0),i=i||{},n)i[m]=h;else{let v=Te(e,m);i[v.route.id]==null&&(i[v.route.id]=h)}a||(o[m]=mo),s||(s=!0,l=ie(f.error)?f.error.status:500),f.headers&&(u[m]=f.headers)}else o[m]=f.data,f.statusCode&&f.statusCode!==200&&!s&&(l=f.statusCode),f.headers&&(u[m]=f.headers)}),d!==void 0&&r&&(i={[r[0]]:d},r[2]&&(o[r[2]]=void 0)),{loaderData:o,errors:i,statusCode:l||200,loaderHeaders:u}}function xn(e,t,r,a,n,o){let{loaderData:i,errors:l}=Po(t,r,a);return n.filter(s=>!s.matches||s.matches.some(u=>u.shouldLoad)).forEach(s=>{let{key:u,match:d,controller:c}=s;if(c&&c.signal.aborted)return;let m=o[u];if(I(m,"Did not find corresponding fetcher result"),de(m)){let f=Te(e.matches,d?.route.id);l&&l[f.route.id]||(l={...l,[f.route.id]:m.error}),e.fetchers.delete(u)}else if(et(m))I(!1,"Unhandled fetcher revalidation redirect");else{let f=We(m.data);e.fetchers.set(u,f)}}),{loaderData:i,errors:l}}function Pn(e,t,r,a){let n=Object.entries(t).filter(([,o])=>o!==mo).reduce((o,[i,l])=>(o[i]=l,o),{});for(let o of r){let i=o.route.id;if(!t.hasOwnProperty(i)&&e.hasOwnProperty(i)&&o.route.loader&&(n[i]=e[i]),a&&a.hasOwnProperty(i))break}return n}function Dn(e){return e?de(e[1])?{actionData:{}}:{actionData:{[e[0]]:e[1].data}}:{}}function Te(e,t){return(t?e.slice(0,e.findIndex(a=>a.route.id===t)+1):[...e]).reverse().find(a=>a.route.hasErrorBoundary===!0)||e[0]}function bt(e){let t=e.length===1?e[0]:e.find(r=>r.index||!r.path||r.path==="/")||{id:"__shim-error-route__"};return{matches:[{params:{},pathname:"",pathnameBase:"",route:t}],route:t}}function oe(e,{pathname:t,routeId:r,method:a,type:n,message:o}={}){let i="Unknown Server Error",l="Unknown @remix-run/router error";return e===400?(i="Bad Request",a&&t&&r?l=`You made a ${a} request to "${t}" but did not provide a \`loader\` for route "${r}", so there is no way to handle the request.`:n==="invalid-body"&&(l="Unable to encode submission body")):e===403?(i="Forbidden",l=`Route "${r}" does not match URL "${t}"`):e===404?(i="Not Found",l=`No route matches URL "${t}"`):e===405&&(i="Method Not Allowed",a&&t&&r?l=`You made a ${a.toUpperCase()} request to "${t}" but did not provide an \`action\` for route "${r}", so there is no way to handle the request.`:a&&(l=`Invalid request method "${a.toUpperCase()}"`)),new Re(e||500,i,new Error(l),!0)}function tr(e){let t=Object.entries(e);for(let r=t.length-1;r>=0;r--){let[a,n]=t[r];if(et(n))return{key:a,result:n}}}function Do(e){let t=typeof e=="string"?Me(e):e;return we({...t,hash:""})}function rs(e,t){return e.pathname!==t.pathname||e.search!==t.search?!1:e.hash===""?t.hash!=="":e.hash===t.hash?!0:t.hash!==""}function ra(e){return Response.json(e.data,e.init??void 0)}function as(e){return new Re(e.init?.status??500,e.init?.statusText??"Internal Server Error",e.data)}function ns(e){return e!=null&&typeof e=="object"&&Object.entries(e).every(([t,r])=>typeof t=="string"&&Lo(r))}function Lo(e){return e!=null&&typeof e=="object"&&"type"in e&&"result"in e&&(e.type==="data"||e.type==="error")}function _o(e){return ae(e.result)&&co.has(e.result.status)}function de(e){return e.type==="error"}function et(e){return(e&&e.type)==="redirect"}function rt(e){return typeof e=="object"&&e!=null&&"type"in e&&"data"in e&&"init"in e&&e.type==="DataWithResponseInit"}function ae(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.headers=="object"&&typeof e.body<"u"}function xr(e){return co.has(e)}function hr(e){return ae(e)&&xr(e.status)&&e.headers.has("Location")}function aa(e){return Jl.has(e.toUpperCase())}function ye(e){return Vl.has(e.toUpperCase())}function xa(e){return new URLSearchParams(e).getAll("index").some(t=>t==="")}function Ct(e,t){let r=typeof t=="string"?Me(t).search:t.search;if(e[e.length-1].route.index&&xa(r||""))return e[e.length-1];let a=no(e);return a[a.length-1]}function Ln(e){let{formMethod:t,formAction:r,formEncType:a,text:n,formData:o,json:i}=e;if(!(!t||!r||!a)){if(n!=null)return{formMethod:t,formAction:r,formEncType:a,formData:void 0,json:void 0,text:n};if(o!=null)return{formMethod:t,formAction:r,formEncType:a,formData:o,json:void 0,text:void 0};if(i!==void 0)return{formMethod:t,formAction:r,formEncType:a,formData:void 0,json:i,text:void 0}}}function Wr(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 os(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 At(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 is(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 We(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 ls(e,t){try{let r=e.sessionStorage.getItem(ho);if(r){let a=JSON.parse(r);for(let[n,o]of Object.entries(a||{}))o&&Array.isArray(o)&&t.set(n,new Set(o||[]))}}catch{}}function ss(e,t){if(t.size>0){let r={};for(let[a,n]of t)r[a]=[...n];try{e.sessionStorage.setItem(ho,JSON.stringify(r))}catch(a){Z(!1,`Failed to save applied view transitions in sessionStorage (${a}).`)}}}function us(){let e,t,r=new Promise((a,n)=>{e=async o=>{a(o);try{await r}catch{}},t=async o=>{n(o);try{await r}catch{}}});return{promise:r,resolve:e,reject:t}}const Oe=await le("react");var Je=Oe.createContext(null);Je.displayName="DataRouter";var ot=Oe.createContext(null);ot.displayName="DataRouterState";var ko=Oe.createContext(!1);function cs(){return Oe.useContext(ko)}var Pr=Oe.createContext({isTransitioning:!1});Pr.displayName="ViewTransition";var Dr=Oe.createContext(new Map);Dr.displayName="Fetchers";var Dt=Oe.createContext(null);Dt.displayName="Await";var id=e=>Oe.createElement(Dt.Provider,e),xe=Oe.createContext(null);xe.displayName="Navigation";var Lt=Oe.createContext(null);Lt.displayName="Location";var Pe=Oe.createContext({outlet:null,matches:[],isDataRoute:!1});Pe.displayName="Route";var Pa=Oe.createContext(null);Pa.displayName="RouteError";const A=await le("react");function ds(e,{relative:t}={}){I(vt(),"useHref() may be used only in the context of a <Router> component.");let{basename:r,navigator:a}=A.useContext(xe),{hash:n,pathname:o,search:i}=Jt(e,{relative:t}),l=o;return r!=="/"&&(l=o==="/"?r:He([r,o])),a.createHref({pathname:l,search:i,hash:n})}function vt(){return A.useContext(Lt)!=null}function De(){return I(vt(),"useLocation() may be used only in the context of a <Router> component."),A.useContext(Lt).location}function ld(){return A.useContext(Lt).navigationType}function sd(e){I(vt(),"useMatch() may be used only in the context of a <Router> component.");let{pathname:t}=De();return A.useMemo(()=>zt(e,ao(t)),[t,e])}var To="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function Mo(e){A.useContext(xe).static||A.useLayoutEffect(e)}function Da(){let{isDataRoute:e}=A.useContext(Pe);return e?xs():fs()}function fs(){I(vt(),"useNavigate() may be used only in the context of a <Router> component.");let e=A.useContext(Je),{basename:t,navigator:r}=A.useContext(xe),{matches:a}=A.useContext(Pe),{pathname:n}=De(),o=JSON.stringify(Er(a)),i=A.useRef(!1);return Mo(()=>{i.current=!0}),A.useCallback((s,u={})=>{if(Z(i.current,To),!i.current)return;if(typeof s=="number"){r.go(s);return}let d=br(s,JSON.parse(o),n,u.relative==="path");e==null&&t!=="/"&&(d.pathname=d.pathname==="/"?t:He([t,d.pathname])),(u.replace?r.replace:r.push)(d,u.state,u)},[t,r,o,n,e])}var Oo=A.createContext(null);function ud(){return A.useContext(Oo)}function hs(e){let t=A.useContext(Pe).outlet;return A.useMemo(()=>t&&A.createElement(Oo.Provider,{value:e},t),[t,e])}function La(){let{matches:e}=A.useContext(Pe),t=e[e.length-1];return t?t.params:{}}function Jt(e,{relative:t}={}){let{matches:r}=A.useContext(Pe),{pathname:a}=De(),n=JSON.stringify(Er(r));return A.useMemo(()=>br(e,JSON.parse(n),a,t==="path"),[e,n,a,t])}function ms(e,t){return _a(e,t)}function _a(e,t,r,a,n){I(vt(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:o}=A.useContext(xe),{matches:i}=A.useContext(Pe),l=i[i.length-1],s=l?l.params:{},u=l?l.pathname:"/",d=l?l.pathnameBase:"/",c=l&&l.route;{let w=c&&c.path||"";No(u,!c||w.endsWith("*")||w.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${u}" (under <Route path="${w}">) but the parent route path has no trailing "*". This means if you navigate deeper, the parent won't match anymore and therefore the child routes will never render.
|
|
12
|
+
|
|
13
|
+
Please change the parent <Route path="${w}"> to <Route path="${w==="/"?"*":`${w}/*`}">.`)}let m=De(),f;if(t){let w=typeof t=="string"?Me(t):t;I(d==="/"||w.pathname?.startsWith(d),`When overriding the location using \`<Routes location>\` or \`useRoutes(routes, location)\`, the location pathname must begin with the portion of the URL pathname that was matched by all parent routes. The current pathname base is "${d}" but pathname "${w.pathname}" was given in the \`location\` prop.`),f=w}else f=m;let h=f.pathname||"/",v=h;if(d!=="/"){let w=d.replace(/^\//,"").split("/");v="/"+h.replace(/^\//,"").split("/").slice(w.length).join("/")}let y=Ce(e,{pathname:v});Z(c||y!=null,`No routes matched location "${f.pathname}${f.search}${f.hash}" `),Z(y==null||y[y.length-1].route.element!==void 0||y[y.length-1].route.Component!==void 0||y[y.length-1].route.lazy!==void 0,`Matched leaf route at location "${f.pathname}${f.search}${f.hash}" does not have an element or Component. This means it will render an <Outlet /> with a null value by default resulting in an "empty" page.`);let R=Fo(y&&y.map(w=>Object.assign({},w,{params:Object.assign({},s,w.params),pathname:He([d,o.encodeLocation?o.encodeLocation(w.pathname.replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:w.pathname]),pathnameBase:w.pathnameBase==="/"?d:He([d,o.encodeLocation?o.encodeLocation(w.pathnameBase.replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:w.pathnameBase])})),i,r,a,n);return t&&R?A.createElement(Lt.Provider,{value:{location:{pathname:"/",search:"",hash:"",state:null,key:"default",...f},navigationType:"POP"}},R):R}function ps(){let e=Lr(),t=ie(e)?`${e.status} ${e.statusText}`:e instanceof Error?e.message:JSON.stringify(e),r=e instanceof Error?e.stack:null,a="rgba(200,200,200, 0.5)",n={padding:"0.5rem",backgroundColor:a},o={padding:"2px 4px",backgroundColor:a},i=null;return console.error("Error handled by React Router default ErrorBoundary:",e),i=A.createElement(A.Fragment,null,A.createElement("p",null,"💿 Hey developer 👋"),A.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",A.createElement("code",{style:o},"ErrorBoundary")," or"," ",A.createElement("code",{style:o},"errorElement")," prop on your route.")),A.createElement(A.Fragment,null,A.createElement("h2",null,"Unexpected Application Error!"),A.createElement("h3",{style:{fontStyle:"italic"}},t),r?A.createElement("pre",{style:n},r):null,i)}var ys=A.createElement(ps,null),vs=class extends A.Component{constructor(e){super(e),this.state={location:e.location,revalidation:e.revalidation,error:e.error}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,t){return t.location!==e.location||t.revalidation!=="idle"&&e.revalidation==="idle"?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:e.error!==void 0?e.error:t.error,location:t.location,revalidation:e.revalidation||t.revalidation}}componentDidCatch(e,t){this.props.onError?this.props.onError(e,t):console.error("React Router caught the following error during render",e)}render(){return this.state.error!==void 0?A.createElement(Pe.Provider,{value:this.props.routeContext},A.createElement(Pa.Provider,{value:this.state.error,children:this.props.component})):this.props.children}};function gs({routeContext:e,match:t,children:r}){let a=A.useContext(Je);return a&&a.static&&a.staticContext&&(t.route.errorElement||t.route.ErrorBoundary)&&(a.staticContext._deepestRenderedBoundaryId=t.route.id),A.createElement(Pe.Provider,{value:e},r)}function Fo(e,t=[],r=null,a=null,n=null){if(e==null){if(!r)return null;if(r.errors)e=r.matches;else if(t.length===0&&!r.initialized&&r.matches.length>0)e=r.matches;else return null}let o=e,i=r?.errors;if(i!=null){let d=o.findIndex(c=>c.route.id&&i?.[c.route.id]!==void 0);I(d>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(i).join(",")}`),o=o.slice(0,Math.min(o.length,d+1))}let l=!1,s=-1;if(r)for(let d=0;d<o.length;d++){let c=o[d];if((c.route.HydrateFallback||c.route.hydrateFallbackElement)&&(s=d),c.route.id){let{loaderData:m,errors:f}=r,h=c.route.loader&&!m.hasOwnProperty(c.route.id)&&(!f||f[c.route.id]===void 0);if(c.route.lazy||h){l=!0,s>=0?o=o.slice(0,s+1):o=[o[0]];break}}}let u=r&&a?(d,c)=>{a(d,{location:r.location,params:r.matches?.[0]?.params??{},errorInfo:c})}:void 0;return o.reduceRight((d,c,m)=>{let f,h=!1,v=null,y=null;r&&(f=i&&c.route.id?i[c.route.id]:void 0,v=c.route.errorElement||ys,l&&(s<0&&m===0?(No("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),h=!0,y=null):s===m&&(h=!0,y=c.route.hydrateFallbackElement||null)));let R=t.concat(o.slice(0,m+1)),w=()=>{let S;return f?S=v:h?S=y:c.route.Component?S=A.createElement(c.route.Component,null):c.route.element?S=c.route.element:S=d,A.createElement(gs,{match:c,routeContext:{outlet:d,matches:R,isDataRoute:r!=null},children:S})};return r&&(c.route.ErrorBoundary||c.route.errorElement||m===0)?A.createElement(vs,{location:r.location,revalidation:r.revalidation,component:v,error:f,children:w(),routeContext:{outlet:null,matches:R,isDataRoute:!0},onError:u}):w()},null)}function ka(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function Ta(e){let t=A.useContext(Je);return I(t,ka(e)),t}function Ke(e){let t=A.useContext(ot);return I(t,ka(e)),t}function ws(e){let t=A.useContext(Pe);return I(t,ka(e)),t}function _t(e){let t=ws(e),r=t.matches[t.matches.length-1];return I(r.route.id,`${e} can only be used on routes that contain a unique "id"`),r.route.id}function Rs(){return _t("useRouteId")}function Es(){return Ke("useNavigation").navigation}function cd(){let e=Ta("useRevalidator"),t=Ke("useRevalidator"),r=A.useCallback(async()=>{await e.router.revalidate()},[e.router]);return A.useMemo(()=>({revalidate:r,state:t.revalidation}),[r,t.revalidation])}function Ma(){let{matches:e,loaderData:t}=Ke("useMatches");return A.useMemo(()=>e.map(r=>qn(r,t)),[e,t])}function Oa(){let e=Ke("useLoaderData"),t=_t("useLoaderData");return e.loaderData[t]}function dd(e){return Ke("useRouteLoaderData").loaderData[e]}function Fa(){let e=Ke("useActionData"),t=_t("useLoaderData");return e.actionData?e.actionData[t]:void 0}function Lr(){let e=A.useContext(Pa),t=Ke("useRouteError"),r=_t("useRouteError");return e!==void 0?e:t.errors?.[r]}function bs(){return A.useContext(Dt)?._data}function fd(){return A.useContext(Dt)?._error}var Ss=0;function Cs(e){let{router:t,basename:r}=Ta("useBlocker"),a=Ke("useBlocker"),[n,o]=A.useState(""),i=A.useCallback(l=>{if(typeof e!="function")return!!e;if(r==="/")return e(l);let{currentLocation:s,nextLocation:u,historyAction:d}=l;return e({currentLocation:{...s,pathname:ue(s.pathname,r)||s.pathname},nextLocation:{...u,pathname:ue(u.pathname,r)||u.pathname},historyAction:d})},[r,e]);return A.useEffect(()=>{let l=String(++Ss);return o(l),()=>t.deleteBlocker(l)},[t]),A.useEffect(()=>{n!==""&&t.getBlocker(n,i)},[t,n,i]),n&&a.blockers.has(n)?a.blockers.get(n):pt}function xs(){let{router:e}=Ta("useNavigate"),t=_t("useNavigate"),r=A.useRef(!1);return Mo(()=>{r.current=!0}),A.useCallback(async(n,o={})=>{Z(r.current,To),r.current&&(typeof n=="number"?e.navigate(n):await e.navigate(n,{fromRouteId:t,...o}))},[e,t])}var _n={};function No(e,t,r){!t&&!_n[e]&&(_n[e]=!0,Z(!1,r))}function hd(...e){const t=_t("useRoute"),r=e[0]??t,a=Ke("useRoute"),n=a.matches.find(({route:o})=>o.id===r);if(n!==void 0)return{handle:n.route.handle,loaderData:a.loaderData[r],actionData:a.actionData?.[r]}}const M=await le("react");var kn={};function Wt(e,t){!e&&!kn[t]&&(kn[t]=!0,console.warn(t))}function kt(e){let t={hasErrorBoundary:e.hasErrorBoundary||e.ErrorBoundary!=null||e.errorElement!=null};return e.Component&&(e.element&&Z(!1,"You should not include both `Component` and `element` on your route - `Component` will be used."),Object.assign(t,{element:M.createElement(e.Component),Component:void 0})),e.HydrateFallback&&(e.hydrateFallbackElement&&Z(!1,"You should not include both `HydrateFallback` and `hydrateFallbackElement` on your route - `HydrateFallback` will be used."),Object.assign(t,{hydrateFallbackElement:M.createElement(e.HydrateFallback),HydrateFallback:void 0})),e.ErrorBoundary&&(e.errorElement&&Z(!1,"You should not include both `ErrorBoundary` and `errorElement` on your route - `ErrorBoundary` will be used."),Object.assign(t,{errorElement:M.createElement(e.ErrorBoundary),ErrorBoundary:void 0})),t}var _r=["HydrateFallback","hydrateFallbackElement"];function Ps(e,t){return Cr({basename:t?.basename,getContext:t?.getContext,future:t?.future,history:Xn({initialEntries:t?.initialEntries,initialIndex:t?.initialIndex}),hydrationData:t?.hydrationData,routes:e,hydrationRouteProperties:_r,mapRouteProperties:kt,dataStrategy:t?.dataStrategy,patchRoutesOnNavigation:t?.patchRoutesOnNavigation,unstable_instrumentations:t?.unstable_instrumentations}).initialize()}var Ds=class{constructor(){this.status="pending",this.promise=new Promise((e,t)=>{this.resolve=r=>{this.status==="pending"&&(this.status="resolved",e(r))},this.reject=r=>{this.status==="pending"&&(this.status="rejected",t(r))}})}};function Ao({router:e,flushSync:t,unstable_onError:r}){let[a,n]=M.useState(e.state),[o,i]=M.useState(),[l,s]=M.useState({isTransitioning:!1}),[u,d]=M.useState(),[c,m]=M.useState(),[f,h]=M.useState(),v=M.useRef(new Map),y=M.useCallback(C=>{n(x=>(C.errors&&r&&Object.entries(C.errors).forEach(([g,O])=>{x.errors?.[g]!==O&&r(O,{location:C.location,params:C.matches[0]?.params??{}})}),C))},[r]),R=M.useCallback((C,{deletedFetchers:x,flushSync:g,viewTransitionOpts:O})=>{C.fetchers.forEach((T,$)=>{T.data!==void 0&&v.current.set($,T.data)}),x.forEach(T=>v.current.delete(T)),Wt(g===!1||t!=null,'You provided the `flushSync` option to a router update, but you are not using the `<RouterProvider>` from `react-router/dom` so `ReactDOM.flushSync()` is unavailable. Please update your app to `import { RouterProvider } from "react-router/dom"` and ensure you have `react-dom` installed as a dependency to use the `flushSync` option.');let _=e.window!=null&&e.window.document!=null&&typeof e.window.document.startViewTransition=="function";if(Wt(O==null||_,"You provided the `viewTransition` option to a router update, but you do not appear to be running in a DOM environment as `window.startViewTransition` is not available."),!O||!_){t&&g?t(()=>y(C)):M.startTransition(()=>y(C));return}if(t&&g){t(()=>{c&&(u&&u.resolve(),c.skipTransition()),s({isTransitioning:!0,flushSync:!0,currentLocation:O.currentLocation,nextLocation:O.nextLocation})});let T=e.window.document.startViewTransition(()=>{t(()=>y(C))});T.finished.finally(()=>{t(()=>{d(void 0),m(void 0),i(void 0),s({isTransitioning:!1})})}),t(()=>m(T));return}c?(u&&u.resolve(),c.skipTransition(),h({state:C,currentLocation:O.currentLocation,nextLocation:O.nextLocation})):(i(C),s({isTransitioning:!0,flushSync:!1,currentLocation:O.currentLocation,nextLocation:O.nextLocation}))},[e.window,t,c,u,y]);M.useLayoutEffect(()=>e.subscribe(R),[e,R]),M.useEffect(()=>{l.isTransitioning&&!l.flushSync&&d(new Ds)},[l]),M.useEffect(()=>{if(u&&o&&e.window){let C=o,x=u.promise,g=e.window.document.startViewTransition(async()=>{M.startTransition(()=>y(C)),await x});g.finished.finally(()=>{d(void 0),m(void 0),i(void 0),s({isTransitioning:!1})}),m(g)}},[o,u,e.window,y]),M.useEffect(()=>{u&&o&&a.location.key===o.location.key&&u.resolve()},[u,c,a.location,o]),M.useEffect(()=>{!l.isTransitioning&&f&&(i(f.state),s({isTransitioning:!0,flushSync:!1,currentLocation:f.currentLocation,nextLocation:f.nextLocation}),h(void 0))},[l.isTransitioning,f]);let w=M.useMemo(()=>({createHref:e.createHref,encodeLocation:e.encodeLocation,go:C=>e.navigate(C),push:(C,x,g)=>e.navigate(C,{state:x,preventScrollReset:g?.preventScrollReset}),replace:(C,x,g)=>e.navigate(C,{replace:!0,state:x,preventScrollReset:g?.preventScrollReset})}),[e]),S=e.basename||"/",P=M.useMemo(()=>({router:e,navigator:w,static:!1,basename:S,unstable_onError:r}),[e,w,S,r]);return M.createElement(M.Fragment,null,M.createElement(Je.Provider,{value:P},M.createElement(ot.Provider,{value:a},M.createElement(Dr.Provider,{value:v.current},M.createElement(Pr.Provider,{value:l},M.createElement(gt,{basename:S,location:a.location,navigationType:a.historyAction,navigator:w},M.createElement(Ls,{routes:e.routes,future:e.future,state:a,unstable_onError:r})))))),null)}var Ls=M.memo(_s);function _s({routes:e,future:t,state:r,unstable_onError:a}){return _a(e,void 0,r,a,t)}function md({basename:e,children:t,initialEntries:r,initialIndex:a}){let n=M.useRef();n.current==null&&(n.current=Xn({initialEntries:r,initialIndex:a,v5Compat:!0}));let o=n.current,[i,l]=M.useState({action:o.action,location:o.location}),s=M.useCallback(u=>{M.startTransition(()=>l(u))},[l]);return M.useLayoutEffect(()=>o.listen(s),[o,s]),M.createElement(gt,{basename:e,children:t,location:i.location,navigationType:i.action,navigator:o})}function pd({to:e,replace:t,state:r,relative:a}){I(vt(),"<Navigate> may be used only in the context of a <Router> component.");let{static:n}=M.useContext(xe);Z(!n,"<Navigate> must not be used on the initial render in a <StaticRouter>. This is a no-op, but you should modify your code so the <Navigate> is only ever rendered in response to some user interaction or state change.");let{matches:o}=M.useContext(Pe),{pathname:i}=De(),l=Da(),s=br(e,Er(o),i,a==="path"),u=JSON.stringify(s);return M.useEffect(()=>{l(JSON.parse(u),{replace:t,state:r,relative:a})},[l,u,a,t,r]),null}function ks(e){return hs(e.context)}function Ts(e){I(!1,"A <Route> is only ever to be used as the child of <Routes> element, never rendered directly. Please wrap your <Route> in a <Routes>.")}function gt({basename:e="/",children:t=null,location:r,navigationType:a="POP",navigator:n,static:o=!1}){I(!vt(),"You cannot render a <Router> inside another <Router>. You should never have more than one in your app.");let i=e.replace(/^\/*/,"/"),l=M.useMemo(()=>({basename:i,navigator:n,static:o,future:{}}),[i,n,o]);typeof r=="string"&&(r=Me(r));let{pathname:s="/",search:u="",hash:d="",state:c=null,key:m="default"}=r,f=M.useMemo(()=>{let h=ue(s,i);return h==null?null:{location:{pathname:h,search:u,hash:d,state:c,key:m},navigationType:a}},[i,s,u,d,c,m,a]);return Z(f!=null,`<Router basename="${i}"> is not able to match the URL "${s}${u}${d}" because it does not start with the basename, so the <Router> won't render anything.`),f==null?null:M.createElement(xe.Provider,{value:l},M.createElement(Lt.Provider,{children:t,value:f}))}function yd({children:e,location:t}){return ms(mr(e),t)}function vd({children:e,errorElement:t,resolve:r}){let a=M.useContext(Je),n=M.useContext(ot),o=M.useCallback((i,l)=>{a&&a.unstable_onError&&n&&a.unstable_onError(i,{location:n.location,params:n.matches?.[0]?.params||{},errorInfo:l})},[a,n]);return M.createElement(Ms,{resolve:r,errorElement:t,onError:o},M.createElement(Os,null,e))}var Ms=class extends M.Component{constructor(e){super(e),this.state={error:null}}static getDerivedStateFromError(e){return{error:e}}componentDidCatch(e,t){this.props.onError?this.props.onError(e,t):console.error("<Await> caught the following error during render",e,t)}render(){let{children:e,errorElement:t,resolve:r}=this.props,a=null,n=0;if(!(r instanceof Promise))n=1,a=Promise.resolve(),Object.defineProperty(a,"_tracked",{get:()=>!0}),Object.defineProperty(a,"_data",{get:()=>r});else if(this.state.error){n=2;let o=this.state.error;a=Promise.reject().catch(()=>{}),Object.defineProperty(a,"_tracked",{get:()=>!0}),Object.defineProperty(a,"_error",{get:()=>o})}else r._tracked?(a=r,n="_error"in a?2:"_data"in a?1:0):(n=0,Object.defineProperty(r,"_tracked",{get:()=>!0}),a=r.then(o=>Object.defineProperty(r,"_data",{get:()=>o}),o=>{this.props.onError?.(o),Object.defineProperty(r,"_error",{get:()=>o})}));if(n===2&&!t)throw a._error;if(n===2)return M.createElement(Dt.Provider,{value:a,children:t});if(n===1)return M.createElement(Dt.Provider,{value:a,children:e});throw a}};function Os({children:e}){let t=bs(),r=typeof e=="function"?e(t):e;return M.createElement(M.Fragment,null,r)}function mr(e,t=[]){let r=[];return M.Children.forEach(e,(a,n)=>{if(!M.isValidElement(a))return;let o=[...t,n];if(a.type===M.Fragment){r.push.apply(r,mr(a.props.children,o));return}I(a.type===Ts,`[${typeof a.type=="string"?a.type:a.type.name}] is not a <Route> component. All component children of <Routes> must be a <Route> or <React.Fragment>`),I(!a.props.index||!a.props.children,"An index route cannot have child routes.");let i={id:a.props.id||o.join("-"),caseSensitive:a.props.caseSensitive,element:a.props.element,Component:a.props.Component,index:a.props.index,path:a.props.path,middleware:a.props.middleware,loader:a.props.loader,action:a.props.action,hydrateFallbackElement:a.props.hydrateFallbackElement,HydrateFallback:a.props.HydrateFallback,errorElement:a.props.errorElement,ErrorBoundary:a.props.ErrorBoundary,hasErrorBoundary:a.props.hasErrorBoundary===!0||a.props.ErrorBoundary!=null||a.props.errorElement!=null,shouldRevalidate:a.props.shouldRevalidate,handle:a.props.handle,lazy:a.props.lazy};a.props.children&&(i.children=mr(a.props.children,o)),r.push(i)}),r}var gd=mr;function wd(e){return Fo(e)}function $o(){return{params:La(),loaderData:Oa(),actionData:Fa(),matches:Ma()}}function Rd({children:e}){const t=$o();return M.cloneElement(e,t)}function Fs(e){return function(){const r=$o();return M.createElement(e,r)}}function Io(){return{params:La(),loaderData:Oa(),actionData:Fa()}}function Ed({children:e}){const t=Io();return M.cloneElement(e,t)}function Ns(e){return function(){const r=Io();return M.createElement(e,r)}}function Ho(){return{params:La(),loaderData:Oa(),actionData:Fa(),error:Lr()}}function bd({children:e}){const t=Ho();return M.cloneElement(e,t)}function As(e){return function(){const r=Ho();return M.createElement(e,r)}}var sr="get",ur="application/x-www-form-urlencoded";function kr(e){return e!=null&&typeof e.tagName=="string"}function $s(e){return kr(e)&&e.tagName.toLowerCase()==="button"}function Is(e){return kr(e)&&e.tagName.toLowerCase()==="form"}function Hs(e){return kr(e)&&e.tagName.toLowerCase()==="input"}function js(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function Us(e,t){return e.button===0&&(!t||t==="_self")&&!js(e)}function na(e=""){return new URLSearchParams(typeof e=="string"||Array.isArray(e)||e instanceof URLSearchParams?e:Object.keys(e).reduce((t,r)=>{let a=e[r];return t.concat(Array.isArray(a)?a.map(n=>[r,n]):[[r,a]])},[]))}function zs(e,t){let r=na(e);return t&&t.forEach((a,n)=>{r.has(n)||t.getAll(n).forEach(o=>{r.append(n,o)})}),r}var rr=null;function Bs(){if(rr===null)try{new FormData(document.createElement("form"),0),rr=!1}catch{rr=!0}return rr}var Ws=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function Vr(e){return e!=null&&!Ws.has(e)?(Z(!1,`"${e}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${ur}"`),null):e}function Vs(e,t){let r,a,n,o,i;if(Is(e)){let l=e.getAttribute("action");a=l?ue(l,t):null,r=e.getAttribute("method")||sr,n=Vr(e.getAttribute("enctype"))||ur,o=new FormData(e)}else if($s(e)||Hs(e)&&(e.type==="submit"||e.type==="image")){let l=e.form;if(l==null)throw new Error('Cannot submit a <button> or <input type="submit"> without a <form>');let s=e.getAttribute("formaction")||l.getAttribute("action");if(a=s?ue(s,t):null,r=e.getAttribute("formmethod")||l.getAttribute("method")||sr,n=Vr(e.getAttribute("formenctype"))||Vr(l.getAttribute("enctype"))||ur,o=new FormData(l,e),!Bs()){let{name:u,type:d,value:c}=e;if(d==="image"){let m=u?`${u}.`:"";o.append(`${m}x`,"0"),o.append(`${m}y`,"0")}else u&&o.append(u,c)}}else{if(kr(e))throw new Error('Cannot submit element that is not <form>, <button>, or <input type="submit|image">');r=sr,a=null,n=ur,i=e}return o&&n==="text/plain"&&(i=o,o=void 0),{action:a,method:r.toLowerCase(),encType:n,formData:o,body:i}}const Be=await le("react");var jo=-1,Uo=-2,zo=-3,Bo=-4,Na=-5,Wo=-6,Vo=-7,Yo="B",Jo="D",xt="E",oa="M",Ko="N",Pt="P",Xo="R",ia="S",Go="Y",Qo="U",la="Z",Zo=class{constructor(){this.promise=new Promise((e,t)=>{this.resolve=e,this.reject=t})}};function Ys(){const e=new TextDecoder;let t="";return new TransformStream({transform(r,a){const n=e.decode(r,{stream:!0}),o=(t+n).split(`
|
|
14
|
+
`);t=o.pop()||"";for(const i of o)a.enqueue(i)},flush(r){t&&r.enqueue(t)}})}function ke(e){const{indices:t}=this,r=t.get(e);if(r)return[r];if(e===void 0)return Vo;if(e===null)return Na;if(Number.isNaN(e))return Uo;if(e===Number.POSITIVE_INFINITY)return Wo;if(e===Number.NEGATIVE_INFINITY)return zo;if(e===0&&1/e<0)return Bo;const a=this.index++;return t.set(e,a),Js.call(this,e,a),a}function Js(e,t){const{deferred:r,plugins:a,postPlugins:n}=this,o=this.stringified,i=[[e,t]];for(;i.length>0;){const[l,s]=i.pop(),u=c=>Object.keys(c).map(m=>`"_${ke.call(this,m)}":${ke.call(this,c[m])}`).join(",");let d=null;switch(typeof l){case"boolean":case"number":case"string":o[s]=JSON.stringify(l);break;case"bigint":o[s]=`["${Yo}","${l}"]`;break;case"symbol":{const c=Symbol.keyFor(l);c?o[s]=`["${Go}",${JSON.stringify(c)}]`:d=new Error("Cannot encode symbol unless created with Symbol.for()");break}case"object":{if(!l){o[s]=`${Na}`;break}const c=Array.isArray(l);let m=!1;if(!c&&a)for(const f of a){const h=f(l);if(Array.isArray(h)){m=!0;const[v,...y]=h;o[s]=`[${JSON.stringify(v)}`,y.length>0&&(o[s]+=`,${y.map(R=>ke.call(this,R)).join(",")}`),o[s]+="]";break}}if(!m){let f=c?"[":"{";if(c){for(let h=0;h<l.length;h++)f+=(h?",":"")+(h in l?ke.call(this,l[h]):jo);o[s]=`${f}]`}else if(l instanceof Date){const h=l.getTime();o[s]=`["${Jo}",${Number.isNaN(h)?JSON.stringify("invalid"):h}]`}else l instanceof URL?o[s]=`["${Qo}",${JSON.stringify(l.href)}]`:l instanceof RegExp?o[s]=`["${Xo}",${JSON.stringify(l.source)},${JSON.stringify(l.flags)}]`:l instanceof Set?l.size>0?o[s]=`["${ia}",${[...l].map(h=>ke.call(this,h)).join(",")}]`:o[s]=`["${ia}"]`:l instanceof Map?l.size>0?o[s]=`["${oa}",${[...l].flatMap(([h,v])=>[ke.call(this,h),ke.call(this,v)]).join(",")}]`:o[s]=`["${oa}"]`:l instanceof Promise?(o[s]=`["${Pt}",${s}]`,r[s]=l):l instanceof Error?(o[s]=`["${xt}",${JSON.stringify(l.message)}`,l.name!=="Error"&&(o[s]+=`,${JSON.stringify(l.name)}`),o[s]+="]"):Object.getPrototypeOf(l)===null?o[s]=`["${Ko}",{${u(l)}}]`:Xs(l)?o[s]=`{${u(l)}}`:d=new Error("Cannot encode object with prototype")}break}default:{const c=Array.isArray(l);let m=!1;if(!c&&a)for(const f of a){const h=f(l);if(Array.isArray(h)){m=!0;const[v,...y]=h;o[s]=`[${JSON.stringify(v)}`,y.length>0&&(o[s]+=`,${y.map(R=>ke.call(this,R)).join(",")}`),o[s]+="]";break}}m||(d=new Error("Cannot encode function or unexpected type"))}}if(d){let c=!1;if(n)for(const m of n){const f=m(l);if(Array.isArray(f)){c=!0;const[h,...v]=f;o[s]=`[${JSON.stringify(h)}`,v.length>0&&(o[s]+=`,${v.map(y=>ke.call(this,y)).join(",")}`),o[s]+="]";break}}if(!c)throw d}}}var Ks=Object.getOwnPropertyNames(Object.prototype).sort().join("\0");function Xs(e){const t=Object.getPrototypeOf(e);return t===Object.prototype||t===null||Object.getOwnPropertyNames(t).sort().join("\0")===Ks}var Yr=typeof window<"u"?window:typeof globalThis<"u"?globalThis:void 0;function sa(e){const{hydrated:t,values:r}=this;if(typeof e=="number")return Tn.call(this,e);if(!Array.isArray(e)||!e.length)throw new SyntaxError;const a=r.length;for(const n of e)r.push(n);return t.length=r.length,Tn.call(this,a)}function Tn(e){const{hydrated:t,values:r,deferred:a,plugins:n}=this;let o;const i=[[e,s=>{o=s}]];let l=[];for(;i.length>0;){const[s,u]=i.pop();switch(s){case Vo:u(void 0);continue;case Na:u(null);continue;case Uo:u(NaN);continue;case Wo:u(1/0);continue;case zo:u(-1/0);continue;case Bo:u(-0);continue}if(t[s]){u(t[s]);continue}const d=r[s];if(!d||typeof d!="object"){t[s]=d,u(d);continue}if(Array.isArray(d))if(typeof d[0]=="string"){const[c,m,f]=d;switch(c){case Jo:u(t[s]=new Date(m));continue;case Qo:u(t[s]=new URL(m));continue;case Yo:u(t[s]=BigInt(m));continue;case Xo:u(t[s]=new RegExp(m,f));continue;case Go:u(t[s]=Symbol.for(m));continue;case ia:const h=new Set;t[s]=h;for(let P=d.length-1;P>0;P--)i.push([d[P],C=>{h.add(C)}]);u(h);continue;case oa:const v=new Map;t[s]=v;for(let P=d.length-2;P>0;P-=2){const C=[];i.push([d[P+1],x=>{C[1]=x}]),i.push([d[P],x=>{C[0]=x}]),l.push(()=>{v.set(C[0],C[1])})}u(v);continue;case Ko:const y=Object.create(null);t[s]=y;for(const P of Object.keys(m).reverse()){const C=[];i.push([m[P],x=>{C[1]=x}]),i.push([Number(P.slice(1)),x=>{C[0]=x}]),l.push(()=>{y[C[0]]=C[1]})}u(y);continue;case Pt:if(t[m])u(t[s]=t[m]);else{const P=new Zo;a[m]=P,u(t[s]=P.promise)}continue;case xt:const[,R,w]=d;let S=w&&Yr&&Yr[w]?new Yr[w](R):new Error(R);t[s]=S,u(S);continue;case la:u(t[s]=t[m]);continue;default:if(Array.isArray(n)){const P=[],C=d.slice(1);for(let x=0;x<C.length;x++){const g=C[x];i.push([g,O=>{P[x]=O}])}l.push(()=>{for(const x of n){const g=x(d[0],...P);if(g){u(t[s]=g.value);return}}throw new SyntaxError});continue}throw new SyntaxError}}else{const c=[];t[s]=c;for(let m=0;m<d.length;m++){const f=d[m];f!==jo&&i.push([f,h=>{c[m]=h}])}u(c);continue}else{const c={};t[s]=c;for(const m of Object.keys(d).reverse()){const f=[];i.push([d[m],h=>{f[1]=h}]),i.push([Number(m.slice(1)),h=>{f[0]=h}]),l.push(()=>{c[f[0]]=f[1]})}u(c);continue}}for(;l.length>0;)l.pop()();return o}async function Gs(e,t){const{plugins:r}=t??{},a=new Zo,n=e.pipeThrough(Ys()).getReader(),o={values:[],hydrated:[],deferred:{},plugins:r},i=await Qs.call(o,n);let l=a.promise;return i.done?a.resolve():l=Zs.call(o,n).then(a.resolve).catch(s=>{for(const u of Object.values(o.deferred))u.reject(s);a.reject(s)}),{done:l.then(()=>n.closed),value:i.value}}async function Qs(e){const t=await e.read();if(!t.value)throw new SyntaxError;let r;try{r=JSON.parse(t.value)}catch{throw new SyntaxError}return{done:t.done,value:sa.call(this,r)}}async function Zs(e){let t=await e.read();for(;!t.done;){if(!t.value)continue;const r=t.value;switch(r[0]){case Pt:{const a=r.indexOf(":"),n=Number(r.slice(1,a)),o=this.deferred[n];if(!o)throw new Error(`Deferred ID ${n} not found in stream`);const i=r.slice(a+1);let l;try{l=JSON.parse(i)}catch{throw new SyntaxError}const s=sa.call(this,l);o.resolve(s);break}case xt:{const a=r.indexOf(":"),n=Number(r.slice(1,a)),o=this.deferred[n];if(!o)throw new Error(`Deferred ID ${n} not found in stream`);const i=r.slice(a+1);let l;try{l=JSON.parse(i)}catch{throw new SyntaxError}const s=sa.call(this,l);o.reject(s);break}default:throw new SyntaxError}t=await e.read()}}function qs(e,t){const{plugins:r,postPlugins:a,signal:n}=t??{},o={deferred:{},index:0,indices:new Map,stringified:[],plugins:r,postPlugins:a,signal:n},i=new TextEncoder;let l=0;return new ReadableStream({async start(u){const d=ke.call(o,e);if(Array.isArray(d))throw new Error("This should never happen");d<0?u.enqueue(i.encode(`${d}
|
|
15
|
+
`)):(u.enqueue(i.encode(`[${o.stringified.join(",")}]
|
|
16
|
+
`)),l=o.stringified.length-1);const c=new WeakSet;if(Object.keys(o.deferred).length){let m;const f=new Promise((h,v)=>{if(m=h,n){const y=()=>v(n.reason||new Error("Signal was aborted."));n.aborted?y():n.addEventListener("abort",R=>{y()})}});for(;Object.keys(o.deferred).length>0;){for(const[h,v]of Object.entries(o.deferred))c.has(v)||c.add(o.deferred[Number(h)]=Promise.race([f,v]).then(y=>{const R=ke.call(o,y);if(Array.isArray(R))u.enqueue(i.encode(`${Pt}${h}:[["${la}",${R[0]}]]
|
|
17
|
+
`)),o.index++,l++;else if(R<0)u.enqueue(i.encode(`${Pt}${h}:${R}
|
|
18
|
+
`));else{const w=o.stringified.slice(l+1).join(",");u.enqueue(i.encode(`${Pt}${h}:[${w}]
|
|
19
|
+
`)),l=o.stringified.length-1}},y=>{(!y||typeof y!="object"||!(y instanceof Error))&&(y=new Error("An unknown error occurred"));const R=ke.call(o,y);if(Array.isArray(R))u.enqueue(i.encode(`${xt}${h}:[["${la}",${R[0]}]]
|
|
20
|
+
`)),o.index++,l++;else if(R<0)u.enqueue(i.encode(`${xt}${h}:${R}
|
|
21
|
+
`));else{const w=o.stringified.slice(l+1).join(",");u.enqueue(i.encode(`${xt}${h}:[${w}]
|
|
22
|
+
`)),l=o.stringified.length-1}}).finally(()=>{delete o.deferred[Number(h)]}));await Promise.race(Object.values(o.deferred))}m()}await Promise.all(Object.values(o.deferred)),u.close()}})}async function eu(e){let t={signal:e.signal};if(e.method!=="GET"){t.method=e.method;let r=e.headers.get("Content-Type");r&&/\bapplication\/json\b/.test(r)?(t.headers={"Content-Type":r},t.body=JSON.stringify(await e.json())):r&&/\btext\/plain\b/.test(r)?(t.headers={"Content-Type":r},t.body=await e.text()):r&&/\bapplication\/x-www-form-urlencoded\b/.test(r)?t.body=new URLSearchParams(await e.text()):t.body=await e.formData()}return t}var tu={"&":"\\u0026",">":"\\u003e","<":"\\u003c","\u2028":"\\u2028","\u2029":"\\u2029"},ru=/[&><\u2028\u2029]/g;function Aa(e){return e.replace(ru,t=>tu[t])}function ge(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}var nt=Symbol("SingleFetchRedirect"),qo=class extends Error{},$a=202,ei=new Set([100,101,204,205]);function ti({context:e,identifier:t,reader:r,textDecoder:a,nonce:n}){if(!e.renderMeta||!e.renderMeta.didRenderScripts)return null;e.renderMeta.streamCache||(e.renderMeta.streamCache={});let{streamCache:o}=e.renderMeta,i=o[t];if(i||(i=o[t]=r.read().then(d=>{o[t].result={done:d.done,value:a.decode(d.value,{stream:!0})}}).catch(d=>{o[t].error=d})),i.error)throw i.error;if(i.result===void 0)throw i;let{done:l,value:s}=i.result,u=s?Be.createElement("script",{nonce:n,dangerouslySetInnerHTML:{__html:`window.__reactRouterContext.streamController.enqueue(${Aa(JSON.stringify(s))});`}}):null;return l?Be.createElement(Be.Fragment,null,u,Be.createElement("script",{nonce:n,dangerouslySetInnerHTML:{__html:"window.__reactRouterContext.streamController.close();"}})):Be.createElement(Be.Fragment,null,u,Be.createElement(Be.Suspense,null,Be.createElement(ti,{context:e,identifier:t+1,reader:r,textDecoder:a,nonce:n})))}function au(e,t,r,a,n){let o=nu(e,i=>{let l=t.routes[i.route.id];ge(l,"Route not found in manifest");let s=r[i.route.id];return{hasLoader:l.hasLoader,hasClientLoader:l.hasClientLoader,hasShouldRevalidate:!!s?.shouldRevalidate}},du,a,n);return async i=>i.runClientMiddleware(o)}function nu(e,t,r,a,n,o=()=>!0){return async i=>{let{request:l,matches:s,fetcherKey:u}=i,d=e();if(l.method!=="GET")return ou(i,r,n);let c=s.some(m=>{let{hasLoader:f,hasClientLoader:h}=t(m);return m.unstable_shouldCallHandler()&&f&&!h});return!a&&!c?iu(i,t,r,n):u?uu(i,r,n):lu(i,d,t,r,a,n,o)}}async function ou(e,t,r){let a=e.matches.find(i=>i.unstable_shouldCallHandler());ge(a,"No action match found");let n,o=await a.resolve(async i=>await i(async()=>{let{data:s,status:u}=await t(e,r,[a.route.id]);return n=u,Vt(s,a.route.id)}));return ae(o.result)||ie(o.result)||rt(o.result)?{[a.route.id]:o}:{[a.route.id]:{type:o.type,result:Il(o.result,n)}}}async function iu(e,t,r,a){let n=e.matches.filter(i=>i.unstable_shouldCallHandler()),o={};return await Promise.all(n.map(i=>i.resolve(async l=>{try{let{hasClientLoader:s}=t(i),u=i.route.id,d=s?await l(async()=>{let{data:c}=await r(e,a,[u]);return Vt(c,u)}):await l();o[i.route.id]={type:"data",result:d}}catch(s){o[i.route.id]={type:"error",result:s}}}))),o}async function lu(e,t,r,a,n,o,i=()=>!0){let l=new Set,s=!1,u=e.matches.map(()=>Mn()),d=Mn(),c={},m=Promise.all(e.matches.map(async(h,v)=>h.resolve(async y=>{u[v].resolve();let R=h.route.id,{hasLoader:w,hasClientLoader:S,hasShouldRevalidate:P}=r(h),C=!h.unstable_shouldRevalidateArgs||h.unstable_shouldRevalidateArgs.actionStatus==null||h.unstable_shouldRevalidateArgs.actionStatus<400;if(!h.unstable_shouldCallHandler(C)){s||(s=h.unstable_shouldRevalidateArgs!=null&&w&&P===!0);return}if(i(h)&&S){w&&(s=!0);try{let g=await y(async()=>{let{data:O}=await a(e,o,[R]);return Vt(O,R)});c[R]={type:"data",result:g}}catch(g){c[R]={type:"error",result:g}}return}w&&l.add(R);try{let g=await y(async()=>{let O=await d.promise;return Vt(O,R)});c[R]={type:"data",result:g}}catch(g){c[R]={type:"error",result:g}}})));if(await Promise.all(u.map(h=>h.promise)),(!t.state.initialized&&t.state.navigation.state==="idle"||l.size===0)&&!window.__reactRouterHdrActive)d.resolve({routes:{}});else{let h=n&&s&&l.size>0?[...l.keys()]:void 0;try{let v=await a(e,o,h);d.resolve(v.data)}catch(v){d.reject(v)}}return await m,await su(d.promise,e.matches,l,c),c}async function su(e,t,r,a){try{let n,o=await e;if("routes"in o){for(let i of t)if(i.route.id in o.routes){let l=o.routes[i.route.id];if("error"in l){n=l.error,a[i.route.id]?.result==null&&(a[i.route.id]={type:"error",result:n});break}}}n!==void 0&&Array.from(r.values()).forEach(i=>{a[i].result instanceof qo&&(a[i].result=n)})}catch{}}async function uu(e,t,r){let a=e.matches.find(i=>i.unstable_shouldCallHandler());ge(a,"No fetcher match found");let n=a.route.id,o=await a.resolve(async i=>i(async()=>{let{data:l}=await t(e,r,[n]);return Vt(l,n)}));return{[a.route.id]:o}}function cu(e){let t=e.searchParams.getAll("index");e.searchParams.delete("index");let r=[];for(let a of t)a&&r.push(a);for(let a of r)e.searchParams.append("index",a);return e}function ri(e,t,r){let a=typeof e=="string"?new URL(e,typeof window>"u"?"server://singlefetch/":window.location.origin):e;return a.pathname==="/"?a.pathname=`_root.${r}`:t&&ue(a.pathname,t)==="/"?a.pathname=`${t.replace(/\/$/,"")}/_root.${r}`:a.pathname=`${a.pathname.replace(/\/$/,"")}.${r}`,a}async function du(e,t,r){let{request:a}=e,n=ri(a.url,t,"data");a.method==="GET"&&(n=cu(n),r&&n.searchParams.set("_routes",r.join(",")));let o=await fetch(n,await eu(a));if(o.status>=400&&!o.headers.has("X-Remix-Response"))throw new Re(o.status,o.statusText,await o.text());if(o.status===204&&o.headers.has("X-Remix-Redirect"))return{status:$a,data:{redirect:{redirect:o.headers.get("X-Remix-Redirect"),status:Number(o.headers.get("X-Remix-Status")||"302"),revalidate:o.headers.get("X-Remix-Revalidate")==="true",reload:o.headers.get("X-Remix-Reload-Document")==="true",replace:o.headers.get("X-Remix-Replace")==="true"}}};if(ei.has(o.status)){let i={};return r&&a.method!=="GET"&&(i[r[0]]={data:void 0}),{status:o.status,data:{routes:i}}}ge(o.body,"No response body to decode");try{let i=await Ia(o.body,window),l;if(a.method==="GET"){let s=i.value;nt in s?l={redirect:s[nt]}:l={routes:s}}else{let s=i.value,u=r?.[0];ge(u,"No routeId found for single fetch call decoding"),"redirect"in s?l={redirect:s}:l={routes:{[u]:s}}}return{status:o.status,data:l}}catch{throw new Error("Unable to decode turbo-stream response")}}function Ia(e,t){return Gs(e,{plugins:[(r,...a)=>{if(r==="SanitizedError"){let[n,o,i]=a,l=Error;n&&n in t&&typeof t[n]=="function"&&(l=t[n]);let s=new l(o);return s.stack=i,{value:s}}if(r==="ErrorResponse"){let[n,o,i]=a;return{value:new Re(o,i,n)}}if(r==="SingleFetchRedirect")return{value:{[nt]:a[0]}};if(r==="SingleFetchClassInstance")return{value:a[0]};if(r==="SingleFetchFallback")return{value:void 0}}]})}function Vt(e,t){if("redirect"in e){let{redirect:a,revalidate:n,reload:o,replace:i,status:l}=e.redirect;throw Sr(a,{status:l,headers:{...n?{"X-Remix-Revalidate":"yes"}:null,...o?{"X-Remix-Reload-Document":"yes"}:null,...i?{"X-Remix-Replace":"yes"}:null}})}let r=e.routes[t];if(r==null)throw new qo(`No result found for routeId "${t}"`);if("error"in r)throw r.error;if("data"in r)return r.data;throw new Error(`Invalid response found for routeId "${t}"`)}function Mn(){let e,t,r=new Promise((a,n)=>{e=async o=>{a(o);try{await r}catch{}},t=async o=>{n(o);try{await r}catch{}}});return{promise:r,resolve:e,reject:t}}const pe=await le("react"),V=await le("react");async function ai(e,t){if(e.id in t)return t[e.id];try{let r=await import(e.module);return t[e.id]=r,r}catch(r){return console.error(`Error loading route module \`${e.module}\`, reloading page...`),console.error(r),window.__reactRouterContext&&window.__reactRouterContext.isSpaMode,window.location.reload(),new Promise(()=>{})}}function fu(e,t,r){let a=e.map(o=>{let i=t[o.route.id],l=r.routes[o.route.id];return[l&&l.css?l.css.map(s=>({rel:"stylesheet",href:s})):[],i?.links?.()||[]]}).flat(2),n=ja(e,r);return li(a,n)}function ni(e){return e.css?e.css.map(t=>({rel:"stylesheet",href:t})):[]}async function hu(e){if(!e.css)return;let t=ni(e);await Promise.all(t.map(ii))}async function oi(e,t){if(!e.css&&!t.links||!gu())return;let r=[];if(e.css&&r.push(...ni(e)),t.links&&r.push(...t.links()),r.length===0)return;let a=[];for(let n of r)!Ha(n)&&n.rel==="stylesheet"&&a.push({...n,rel:"preload",as:"style"});await Promise.all(a.map(ii))}async function ii(e){return new Promise(t=>{if(e.media&&!window.matchMedia(e.media).matches||document.querySelector(`link[rel="stylesheet"][href="${e.href}"]`))return t();let r=document.createElement("link");Object.assign(r,e);function a(){document.head.contains(r)&&document.head.removeChild(r)}r.onload=()=>{a(),t()},r.onerror=()=>{a(),t()},document.head.appendChild(r)})}function Ha(e){return e!=null&&typeof e.page=="string"}function mu(e){return e==null?!1:e.href==null?e.rel==="preload"&&typeof e.imageSrcSet=="string"&&typeof e.imageSizes=="string":typeof e.rel=="string"&&typeof e.href=="string"}async function pu(e,t,r){let a=await Promise.all(e.map(async n=>{let o=t.routes[n.route.id];if(o){let i=await ai(o,r);return i.links?i.links():[]}return[]}));return li(a.flat(1).filter(mu).filter(n=>n.rel==="stylesheet"||n.rel==="preload").map(n=>n.rel==="stylesheet"?{...n,rel:"prefetch",as:"style"}:{...n,rel:"prefetch"}))}function On(e,t,r,a,n,o){let i=(s,u)=>r[u]?s.route.id!==r[u].route.id:!0,l=(s,u)=>r[u].pathname!==s.pathname||r[u].route.path?.endsWith("*")&&r[u].params["*"]!==s.params["*"];return o==="assets"?t.filter((s,u)=>i(s,u)||l(s,u)):o==="data"?t.filter((s,u)=>{let d=a.routes[s.route.id];if(!d||!d.hasLoader)return!1;if(i(s,u)||l(s,u))return!0;if(s.route.shouldRevalidate){let c=s.route.shouldRevalidate({currentUrl:new URL(n.pathname+n.search+n.hash,window.origin),currentParams:r[0]?.params||{},nextUrl:new URL(e,window.origin),nextParams:s.params,defaultShouldRevalidate:!0});if(typeof c=="boolean")return c}return!0}):[]}function ja(e,t,{includeHydrateFallback:r}={}){return yu(e.map(a=>{let n=t.routes[a.route.id];if(!n)return[];let o=[n.module];return n.clientActionModule&&(o=o.concat(n.clientActionModule)),n.clientLoaderModule&&(o=o.concat(n.clientLoaderModule)),r&&n.hydrateFallbackModule&&(o=o.concat(n.hydrateFallbackModule)),n.imports&&(o=o.concat(n.imports)),o}).flat(1))}function yu(e){return[...new Set(e)]}function vu(e){let t={},r=Object.keys(e).sort();for(let a of r)t[a]=e[a];return t}function li(e,t){let r=new Set,a=new Set(t);return e.reduce((n,o)=>{if(t&&!Ha(o)&&o.as==="script"&&o.href&&a.has(o.href))return n;let l=JSON.stringify(vu(o));return r.has(l)||(r.add(l),n.push({key:l,link:o})),n},[])}var ar;function gu(){if(ar!==void 0)return ar;let e=document.createElement("link");return ar=e.relList.supports("preload"),e=null,ar}const wu=await le("react"),ht=await le("react"),Fn=await le("react");function Ru(){return Fn.createElement(ua,{title:"Loading...",renderScripts:!0},Fn.createElement("script",{dangerouslySetInnerHTML:{__html:`
|
|
23
|
+
console.log(
|
|
24
|
+
"💿 Hey developer 👋. You can provide a way better UX than this " +
|
|
25
|
+
"when your app is loading JS modules and/or running \`clientLoader\` " +
|
|
26
|
+
"functions. Check out https://reactrouter.com/start/framework/route-module#hydratefallback " +
|
|
27
|
+
"for more information."
|
|
28
|
+
);
|
|
29
|
+
`}}))}function Ua(e){let t={};return Object.values(e).forEach(r=>{if(r){let a=r.parentId||"";t[a]||(t[a]=[]),t[a].push(r)}}),t}function si(e,t,r){let a=ci(t),n=t.HydrateFallback&&(!r||e.id==="root")?t.HydrateFallback:e.id==="root"?Ru:void 0,o=t.ErrorBoundary?t.ErrorBoundary:e.id==="root"?()=>ht.createElement(pi,{error:Lr()}):void 0;return e.id==="root"&&t.Layout?{...a?{element:ht.createElement(t.Layout,null,ht.createElement(a,null))}:{Component:a},...o?{errorElement:ht.createElement(t.Layout,null,ht.createElement(o,null))}:{ErrorBoundary:o},...n?{hydrateFallbackElement:ht.createElement(t.Layout,null,ht.createElement(n,null))}:{HydrateFallback:n}}:{Component:a,ErrorBoundary:o,HydrateFallback:n}}function ui(e,t,r,a,n="",o=Ua(e),i=Promise.resolve({Component:()=>null})){return(o[n]||[]).map(l=>{let s=t[l.id];ge(s,"No `routeModule` available to create server routes");let u={...si(l,s,a),caseSensitive:l.caseSensitive,id:l.id,index:l.index,path:l.path,handle:s.handle,lazy:a?()=>i:void 0,loader:l.hasLoader||l.hasClientLoader?()=>null:void 0},d=ui(e,t,r,a,l.id,o,i);return d.length>0&&(u.children=d),u})}function Eu(e,t,r,a,n,o){return Tr(t,r,a,n,o,"",Ua(t),e)}function nr(e,t){if(e==="loader"&&!t.hasLoader||e==="action"&&!t.hasAction){let a=`You are trying to call ${e==="action"?"serverAction()":"serverLoader()"} on a route that does not have a server ${e} (routeId: "${t.id}")`;throw console.error(a),new Re(400,"Bad Request",new Error(a),!0)}}function Jr(e,t){let r=e==="clientAction"?"a":"an",a=`Route "${t}" does not have ${r} ${e}, but you are trying to submit to it. To fix this, please add ${r} \`${e}\` function to the route`;throw console.error(a),new Re(405,"Method Not Allowed",new Error(a),!0)}function Tr(e,t,r,a,n,o="",i=Ua(e),l){return(i[o]||[]).map(s=>{let u=t[s.id];function d(w){return ge(typeof w=="function","No single fetch function available for route handler"),w()}function c(w){return s.hasLoader?d(w):Promise.resolve(null)}function m(w){if(!s.hasAction)throw Jr("action",s.id);return d(w)}function f(w){import(w)}function h(w){w.clientActionModule&&f(w.clientActionModule),w.clientLoaderModule&&f(w.clientLoaderModule)}async function v(w){let S=t[s.id],P=S?oi(s,S):Promise.resolve();try{return w()}finally{await P}}let y={id:s.id,index:s.index,path:s.path};if(u){Object.assign(y,{...y,...si(s,u,n),middleware:u.clientMiddleware,handle:u.handle,shouldRevalidate:Nn(y.path,u,s,a,l)});let w=r&&r.loaderData&&s.id in r.loaderData,S=w?r?.loaderData?.[s.id]:void 0,P=r&&r.errors&&s.id in r.errors,C=P?r?.errors?.[s.id]:void 0,x=l==null&&(u.clientLoader?.hydrate===!0||!s.hasLoader);y.loader=async({request:g,params:O,context:_,unstable_pattern:T},$)=>{try{return await v(async()=>(ge(u,"No `routeModule` available for critical-route loader"),u.clientLoader?u.clientLoader({request:g,params:O,context:_,unstable_pattern:T,async serverLoader(){if(nr("loader",s),x){if(w)return S;if(P)throw C}return c($)}}):c($)))}finally{x=!1}},y.loader.hydrate=Mr(s.id,u.clientLoader,s.hasLoader,n),y.action=({request:g,params:O,context:_,unstable_pattern:T},$)=>v(async()=>{if(ge(u,"No `routeModule` available for critical-route action"),!u.clientAction){if(n)throw Jr("clientAction",s.id);return m($)}return u.clientAction({request:g,params:O,context:_,unstable_pattern:T,async serverAction(){return nr("action",s),m($)}})})}else{s.hasClientLoader||(y.loader=(P,C)=>v(()=>c(C))),s.hasClientAction||(y.action=(P,C)=>v(()=>{if(n)throw Jr("clientAction",s.id);return m(C)}));let w;async function S(){return w?await w:(w=(async()=>{(s.clientLoaderModule||s.clientActionModule)&&await new Promise(C=>setTimeout(C,0));let P=Su(s,t);return h(s),await P})(),await w)}y.lazy={loader:s.hasClientLoader?async()=>{let{clientLoader:P}=s.clientLoaderModule?await import(s.clientLoaderModule):await S();return ge(P,"No `clientLoader` export found"),(C,x)=>P({...C,async serverLoader(){return nr("loader",s),c(x)}})}:void 0,action:s.hasClientAction?async()=>{let P=s.clientActionModule?import(s.clientActionModule):S();h(s);let{clientAction:C}=await P;return ge(C,"No `clientAction` export found"),(x,g)=>C({...x,async serverAction(){return nr("action",s),m(g)}})}:void 0,middleware:s.hasClientMiddleware?async()=>{let{clientMiddleware:P}=s.clientMiddlewareModule?await import(s.clientMiddlewareModule):await S();return ge(P,"No `clientMiddleware` export found"),P}:void 0,shouldRevalidate:async()=>{let P=await S();return Nn(y.path,P,s,a,l)},handle:async()=>(await S()).handle,Component:async()=>(await S()).Component,ErrorBoundary:s.hasErrorBoundary?async()=>(await S()).ErrorBoundary:void 0}}let R=Tr(e,t,r,a,n,s.id,i,l);return R.length>0&&(y.children=R),y})}function Nn(e,t,r,a,n){if(n)return bu(r.id,t.shouldRevalidate,n);if(!a&&r.hasLoader&&!r.hasClientLoader){let o=e?ro(e)[1].map(l=>l.paramName):[];const i=l=>o.some(s=>l.currentParams[s]!==l.nextParams[s]);if(t.shouldRevalidate){let l=t.shouldRevalidate;return s=>l({...s,defaultShouldRevalidate:i(s)})}else return l=>i(l)}if(a&&t.shouldRevalidate){let o=t.shouldRevalidate;return i=>o({...i,defaultShouldRevalidate:!0})}return t.shouldRevalidate}function bu(e,t,r){let a=!1;return n=>a?t?t(n):n.defaultShouldRevalidate:(a=!0,r.has(e))}async function Su(e,t){let r=ai(e,t),a=hu(e),n=await r;return await Promise.all([a,oi(e,n)]),{Component:ci(n),ErrorBoundary:n.ErrorBoundary,clientMiddleware:n.clientMiddleware,clientAction:n.clientAction,clientLoader:n.clientLoader,handle:n.handle,links:n.links,meta:n.meta,shouldRevalidate:n.shouldRevalidate}}function ci(e){if(e.default==null)return;if(!(typeof e.default=="object"&&Object.keys(e.default).length===0))return e.default}function Mr(e,t,r,a){return a&&e!=="root"||t!=null&&(t.hydrate===!0||r!==!0)}var cr=new Set,Cu=1e3,pr=new Set,xu=7680;function za(e,t){return e.mode==="lazy"&&t===!0}function Pu({sri:e,...t},r){let a=new Set(r.state.matches.map(l=>l.route.id)),n=r.state.location.pathname.split("/").filter(Boolean),o=["/"];for(n.pop();n.length>0;)o.push(`/${n.join("/")}`),n.pop();o.forEach(l=>{let s=Ce(r.routes,l,r.basename);s&&s.forEach(u=>a.add(u.route.id))});let i=[...a].reduce((l,s)=>Object.assign(l,{[s]:t.routes[s]}),{});return{...t,routes:i,sri:e?!0:void 0}}function Du(e,t,r,a,n,o){if(za(a,r))return async({path:i,patch:l,signal:s,fetcherKey:u})=>{pr.has(i)||await fi([i],u?window.location.href:i,e,t,r,n,o,a.manifestPath,l,s)}}function Lu(e,t,r,a,n,o){wu.useEffect(()=>{if(!za(n,a)||window.navigator?.connection?.saveData===!0)return;function i(d){let c=d.tagName==="FORM"?d.getAttribute("action"):d.getAttribute("href");if(!c)return;let m=d.tagName==="A"?d.pathname:new URL(c,window.location.origin).pathname;pr.has(m)||cr.add(m)}async function l(){document.querySelectorAll("a[data-discover], form[data-discover]").forEach(i);let d=Array.from(cr.keys()).filter(c=>pr.has(c)?(cr.delete(c),!1):!0);if(d.length!==0)try{await fi(d,null,t,r,a,o,e.basename,n.manifestPath,e.patchRoutes)}catch(c){console.error("Failed to fetch manifest patches",c)}}let s=ku(l,100);l();let u=new MutationObserver(()=>s());return u.observe(document.documentElement,{subtree:!0,childList:!0,attributes:!0,attributeFilter:["data-discover","href","action"]}),()=>u.disconnect()},[a,o,t,r,e,n])}function di(e,t){let r=e||"/__manifest";return t==null?r:`${t}${r}`.replace(/\/+/g,"/")}var Kr="react-router-manifest-version";async function fi(e,t,r,a,n,o,i,l,s,u){const d=new URLSearchParams;d.set("paths",e.sort().join(",")),d.set("version",r.version);let c=new URL(di(l,i),window.location.origin);if(c.search=d.toString(),c.toString().length>xu){cr.clear();return}let m;try{let y=await fetch(c,{signal:u});if(y.ok){if(y.status===204&&y.headers.has("X-Remix-Reload-Document")){if(!t){console.warn("Detected a manifest version mismatch during eager route discovery. The next navigation/fetch to an undiscovered route will result in a new document navigation to sync up with the latest manifest.");return}try{if(sessionStorage.getItem(Kr)===r.version){console.error("Unable to discover routes due to manifest version mismatch.");return}sessionStorage.setItem(Kr,r.version)}catch{}window.location.href=t,console.warn("Detected manifest version mismatch, reloading..."),await new Promise(()=>{})}else if(y.status>=400)throw new Error(await y.text())}else throw new Error(`${y.status} ${y.statusText}`);try{sessionStorage.removeItem(Kr)}catch{}m=await y.json()}catch(y){if(u?.aborted)return;throw y}let f=new Set(Object.keys(r.routes)),h=Object.values(m).reduce((y,R)=>(R&&!f.has(R.id)&&(y[R.id]=R),y),{});Object.assign(r.routes,h),e.forEach(y=>_u(y,pr));let v=new Set;Object.values(h).forEach(y=>{y&&(!y.parentId||!h[y.parentId])&&v.add(y.parentId)}),v.forEach(y=>s(y||null,Tr(h,a,null,n,o,y)))}function _u(e,t){if(t.size>=Cu){let r=t.values().next().value;t.delete(r)}t.add(e)}function ku(e,t){let r;return(...a)=>{window.clearTimeout(r),r=window.setTimeout(()=>e(...a),t)}}function Ba(){let e=V.useContext(Je);return ge(e,"You must render this element inside a <DataRouterContext.Provider> element"),e}function Or(){let e=V.useContext(ot);return ge(e,"You must render this element inside a <DataRouterStateContext.Provider> element"),e}var it=V.createContext(void 0);it.displayName="FrameworkContext";function Tt(){let e=V.useContext(it);return ge(e,"You must render this element inside a <HydratedRouter> element"),e}function Tu(e,t){let r=V.useContext(it),[a,n]=V.useState(!1),[o,i]=V.useState(!1),{onFocus:l,onBlur:s,onMouseEnter:u,onMouseLeave:d,onTouchStart:c}=t,m=V.useRef(null);V.useEffect(()=>{if(e==="render"&&i(!0),e==="viewport"){let v=R=>{R.forEach(w=>{i(w.isIntersecting)})},y=new IntersectionObserver(v,{threshold:.5});return m.current&&y.observe(m.current),()=>{y.disconnect()}}},[e]),V.useEffect(()=>{if(a){let v=setTimeout(()=>{i(!0)},100);return()=>{clearTimeout(v)}}},[a]);let f=()=>{n(!0)},h=()=>{n(!1),i(!1)};return r?e!=="intent"?[o,m,{}]:[o,m,{onFocus:$t(l,f),onBlur:$t(s,h),onMouseEnter:$t(u,f),onMouseLeave:$t(d,h),onTouchStart:$t(c,f)}]:[!1,m,{}]}function $t(e,t){return r=>{e&&e(r),r.defaultPrevented||t(r)}}function Wa(e,t,r){if(r&&!yr)return[e[0]];if(t){let a=e.findIndex(n=>t[n.route.id]!==void 0);return e.slice(0,a+1)}return e}var An="data-react-router-critical-css";function Sd({nonce:e}){let{isSpaMode:t,manifest:r,routeModules:a,criticalCss:n}=Tt(),{errors:o,matches:i}=Or(),l=Wa(i,o,t),s=V.useMemo(()=>fu(l,a,r),[l,a,r]);return V.createElement(V.Fragment,null,typeof n=="string"?V.createElement("style",{[An]:"",dangerouslySetInnerHTML:{__html:n}}):null,typeof n=="object"?V.createElement("link",{[An]:"",rel:"stylesheet",href:n.href,nonce:e}):null,s.map(({key:u,link:d})=>Ha(d)?V.createElement(hi,{key:u,nonce:e,...d}):V.createElement("link",{key:u,nonce:e,...d})))}function hi({page:e,...t}){let{router:r}=Ba(),a=V.useMemo(()=>Ce(r.routes,e,r.basename),[r.routes,e,r.basename]);return a?V.createElement(Ou,{page:e,matches:a,...t}):null}function Mu(e){let{manifest:t,routeModules:r}=Tt(),[a,n]=V.useState([]);return V.useEffect(()=>{let o=!1;return pu(e,t,r).then(i=>{o||n(i)}),()=>{o=!0}},[e,t,r]),a}function Ou({page:e,matches:t,...r}){let a=De(),{manifest:n,routeModules:o}=Tt(),{basename:i}=Ba(),{loaderData:l,matches:s}=Or(),u=V.useMemo(()=>On(e,t,s,n,a,"data"),[e,t,s,n,a]),d=V.useMemo(()=>On(e,t,s,n,a,"assets"),[e,t,s,n,a]),c=V.useMemo(()=>{if(e===a.pathname+a.search+a.hash)return[];let h=new Set,v=!1;if(t.forEach(R=>{let w=n.routes[R.route.id];!w||!w.hasLoader||(!u.some(S=>S.route.id===R.route.id)&&R.route.id in l&&o[R.route.id]?.shouldRevalidate||w.hasClientLoader?v=!0:h.add(R.route.id))}),h.size===0)return[];let y=ri(e,i,"data");return v&&h.size>0&&y.searchParams.set("_routes",t.filter(R=>h.has(R.route.id)).map(R=>R.route.id).join(",")),[y.pathname+y.search]},[i,l,a,n,u,t,e,o]),m=V.useMemo(()=>ja(d,n),[d,n]),f=Mu(d);return V.createElement(V.Fragment,null,c.map(h=>V.createElement("link",{key:h,rel:"prefetch",as:"fetch",href:h,...r})),m.map(h=>V.createElement("link",{key:h,rel:"modulepreload",href:h,...r})),f.map(({key:h,link:v})=>V.createElement("link",{key:h,nonce:r.nonce,...v})))}function Cd(){let{isSpaMode:e,routeModules:t}=Tt(),{errors:r,matches:a,loaderData:n}=Or(),o=De(),i=Wa(a,r,e),l=null;r&&(l=r[i[i.length-1].route.id]);let s=[],u=null,d=[];for(let c=0;c<i.length;c++){let m=i[c],f=m.route.id,h=n[f],v=m.params,y=t[f],R=[],w={id:f,data:h,loaderData:h,meta:[],params:m.params,pathname:m.pathname,handle:m.route.handle,error:l};if(d[c]=w,y?.meta?R=typeof y.meta=="function"?y.meta({data:h,loaderData:h,params:v,location:o,matches:d,error:l}):Array.isArray(y.meta)?[...y.meta]:y.meta:u&&(R=[...u]),R=R||[],!Array.isArray(R))throw new Error("The route at "+m.route.path+` returns an invalid value. All route meta functions must return an array of meta objects.
|
|
30
|
+
|
|
31
|
+
To reference the meta function API, see https://remix.run/route/meta`);w.meta=R,d[c]=w,s=[...R],u=s}return V.createElement(V.Fragment,null,s.flat().map(c=>{if(!c)return null;if("tagName"in c){let{tagName:m,...f}=c;if(!Fu(m))return console.warn(`A meta object uses an invalid tagName: ${m}. Expected either 'link' or 'meta'`),null;let h=m;return V.createElement(h,{key:JSON.stringify(f),...f})}if("title"in c)return V.createElement("title",{key:"title"},String(c.title));if("charset"in c&&(c.charSet??(c.charSet=c.charset),delete c.charset),"charSet"in c&&c.charSet!=null)return typeof c.charSet=="string"?V.createElement("meta",{key:"charSet",charSet:c.charSet}):null;if("script:ld+json"in c)try{let m=JSON.stringify(c["script:ld+json"]);return V.createElement("script",{key:`script:ld+json:${m}`,type:"application/ld+json",dangerouslySetInnerHTML:{__html:Aa(m)}})}catch{return null}return V.createElement("meta",{key:JSON.stringify(c),...c})}))}function Fu(e){return typeof e=="string"&&/^(meta|link)$/.test(e)}var yr=!1;function Nu(){yr=!0}function Au(e){let{manifest:t,serverHandoffString:r,isSpaMode:a,renderMeta:n,routeDiscovery:o,ssr:i}=Tt(),{router:l,static:s,staticContext:u}=Ba(),{matches:d}=Or(),c=cs(),m=za(o,i);n&&(n.didRenderScripts=!0);let f=Wa(d,null,a);V.useEffect(()=>{Nu()},[]);let h=V.useMemo(()=>{if(c)return null;let w=u?`window.__reactRouterContext = ${r};window.__reactRouterContext.stream = new ReadableStream({start(controller){window.__reactRouterContext.streamController = controller;}}).pipeThrough(new TextEncoderStream());`:" ",S=s?`${t.hmr?.runtime?`import ${JSON.stringify(t.hmr.runtime)};`:""}${m?"":`import ${JSON.stringify(t.url)}`};
|
|
32
|
+
${f.map((P,C)=>{let x=`route${C}`,g=t.routes[P.route.id];ge(g,`Route ${P.route.id} not found in manifest`);let{clientActionModule:O,clientLoaderModule:_,clientMiddlewareModule:T,hydrateFallbackModule:$,module:X}=g,q=[...O?[{module:O,varName:`${x}_clientAction`}]:[],..._?[{module:_,varName:`${x}_clientLoader`}]:[],...T?[{module:T,varName:`${x}_clientMiddleware`}]:[],...$?[{module:$,varName:`${x}_HydrateFallback`}]:[],{module:X,varName:`${x}_main`}];if(q.length===1)return`import * as ${x} from ${JSON.stringify(X)};`;let Y=q.map(fe=>`import * as ${fe.varName} from "${fe.module}";`).join(`
|
|
33
|
+
`),Q=`const ${x} = {${q.map(fe=>`...${fe.varName}`).join(",")}};`;return[Y,Q].join(`
|
|
34
|
+
`)}).join(`
|
|
35
|
+
`)}
|
|
36
|
+
${m?`window.__reactRouterManifest = ${JSON.stringify(Pu(t,l),null,2)};`:""}
|
|
37
|
+
window.__reactRouterRouteModules = {${f.map((P,C)=>`${JSON.stringify(P.route.id)}:route${C}`).join(",")}};
|
|
38
|
+
|
|
39
|
+
import(${JSON.stringify(t.entry.module)});`:" ";return V.createElement(V.Fragment,null,V.createElement("script",{...e,suppressHydrationWarning:!0,dangerouslySetInnerHTML:{__html:w},type:void 0}),V.createElement("script",{...e,suppressHydrationWarning:!0,dangerouslySetInnerHTML:{__html:S},type:"module",async:!0}))},[]),v=yr||c?[]:$u(t.entry.imports.concat(ja(f,t,{includeHydrateFallback:!0}))),y=typeof t.sri=="object"?t.sri:{};return Wt(!c,"The <Scripts /> element is a no-op when using RSC and can be safely removed."),yr||c?null:V.createElement(V.Fragment,null,typeof t.sri=="object"?V.createElement("script",{"rr-importmap":"",type:"importmap",suppressHydrationWarning:!0,dangerouslySetInnerHTML:{__html:JSON.stringify({integrity:y})}}):null,m?null:V.createElement("link",{rel:"modulepreload",href:t.url,crossOrigin:e.crossOrigin,integrity:y[t.url],suppressHydrationWarning:!0}),V.createElement("link",{rel:"modulepreload",href:t.entry.module,crossOrigin:e.crossOrigin,integrity:y[t.entry.module],suppressHydrationWarning:!0}),v.map(R=>V.createElement("link",{key:R,rel:"modulepreload",href:R,crossOrigin:e.crossOrigin,integrity:y[R],suppressHydrationWarning:!0})),h)}function $u(e){return[...new Set(e)]}function Iu(...e){return t=>{e.forEach(r=>{typeof r=="function"?r(t):r!=null&&(r.current=t)})}}var mi=class extends pe.Component{constructor(e){super(e),this.state={error:e.error||null,location:e.location}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,t){return t.location!==e.location?{error:e.error||null,location:e.location}:{error:e.error||t.error,location:t.location}}render(){return this.state.error?pe.createElement(pi,{error:this.state.error,isOutsideRemixApp:!0}):this.props.children}};function pi({error:e,isOutsideRemixApp:t}){console.error(e);let r=pe.createElement("script",{dangerouslySetInnerHTML:{__html:`
|
|
40
|
+
console.log(
|
|
41
|
+
"💿 Hey developer 👋. You can provide a way better UX than this when your app throws errors. Check out https://reactrouter.com/how-to/error-boundary for more information."
|
|
42
|
+
);
|
|
43
|
+
`}});if(ie(e))return pe.createElement(ua,{title:"Unhandled Thrown Response!"},pe.createElement("h1",{style:{fontSize:"24px"}},e.status," ",e.statusText),r);let a;if(e instanceof Error)a=e;else{let n=e==null?"Unknown Error":typeof e=="object"&&"toString"in e?e.toString():JSON.stringify(e);a=new Error(n)}return pe.createElement(ua,{title:"Application Error!",isOutsideRemixApp:t},pe.createElement("h1",{style:{fontSize:"24px"}},"Application Error"),pe.createElement("pre",{style:{padding:"2rem",background:"hsla(10, 50%, 50%, 0.1)",color:"red",overflow:"auto"}},a.stack),r)}function ua({title:e,renderScripts:t,isOutsideRemixApp:r,children:a}){let{routeModules:n}=Tt();return n.root?.Layout&&!r?a:pe.createElement("html",{lang:"en"},pe.createElement("head",null,pe.createElement("meta",{charSet:"utf-8"}),pe.createElement("meta",{name:"viewport",content:"width=device-width,initial-scale=1,viewport-fit=cover"}),pe.createElement("title",null,e)),pe.createElement("body",null,pe.createElement("main",{style:{fontFamily:"system-ui, sans-serif",padding:"2rem"}},a,t?pe.createElement(Au,null):null)))}const k=await le("react");var yi=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";try{yi&&(window.__reactRouterVersion="7.9.6")}catch{}function xd(e,t){return Cr({basename:t?.basename,getContext:t?.getContext,future:t?.future,history:Ea({window:t?.window}),hydrationData:t?.hydrationData||vi(),routes:e,mapRouteProperties:kt,hydrationRouteProperties:_r,dataStrategy:t?.dataStrategy,patchRoutesOnNavigation:t?.patchRoutesOnNavigation,window:t?.window,unstable_instrumentations:t?.unstable_instrumentations}).initialize()}function Pd(e,t){return Cr({basename:t?.basename,getContext:t?.getContext,future:t?.future,history:Gn({window:t?.window}),hydrationData:t?.hydrationData||vi(),routes:e,mapRouteProperties:kt,hydrationRouteProperties:_r,dataStrategy:t?.dataStrategy,patchRoutesOnNavigation:t?.patchRoutesOnNavigation,window:t?.window,unstable_instrumentations:t?.unstable_instrumentations}).initialize()}function vi(){let e=window?.__staticRouterHydrationData;return e&&e.errors&&(e={...e,errors:Hu(e.errors)}),e}function Hu(e){if(!e)return null;let t=Object.entries(e),r={};for(let[a,n]of t)if(n&&n.__type==="RouteErrorResponse")r[a]=new Re(n.status,n.statusText,n.data,n.internal===!0);else if(n&&n.__type==="Error"){if(n.__subType){let o=window[n.__subType];if(typeof o=="function")try{let i=new o(n.message);i.stack="",r[a]=i}catch{}}if(r[a]==null){let o=new Error(n.message);o.stack="",r[a]=o}}else r[a]=n;return r}function Dd({basename:e,children:t,window:r}){let a=k.useRef();a.current==null&&(a.current=Ea({window:r,v5Compat:!0}));let n=a.current,[o,i]=k.useState({action:n.action,location:n.location}),l=k.useCallback(s=>{k.startTransition(()=>i(s))},[i]);return k.useLayoutEffect(()=>n.listen(l),[n,l]),k.createElement(gt,{basename:e,children:t,location:o.location,navigationType:o.action,navigator:n})}function Ld({basename:e,children:t,window:r}){let a=k.useRef();a.current==null&&(a.current=Gn({window:r,v5Compat:!0}));let n=a.current,[o,i]=k.useState({action:n.action,location:n.location}),l=k.useCallback(s=>{k.startTransition(()=>i(s))},[i]);return k.useLayoutEffect(()=>n.listen(l),[n,l]),k.createElement(gt,{basename:e,children:t,location:o.location,navigationType:o.action,navigator:n})}function ju({basename:e,children:t,history:r}){let[a,n]=k.useState({action:r.action,location:r.location}),o=k.useCallback(i=>{k.startTransition(()=>n(i))},[n]);return k.useLayoutEffect(()=>r.listen(o),[r,o]),k.createElement(gt,{basename:e,children:t,location:a.location,navigationType:a.action,navigator:r})}ju.displayName="unstable_HistoryRouter";var gi=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,wi=k.forwardRef(function({onClick:t,discover:r="render",prefetch:a="none",relative:n,reloadDocument:o,replace:i,state:l,target:s,to:u,preventScrollReset:d,viewTransition:c,...m},f){let{basename:h}=k.useContext(xe),v=typeof u=="string"&&gi.test(u),y,R=!1;if(typeof u=="string"&&v&&(y=u,yi))try{let _=new URL(window.location.href),T=u.startsWith("//")?new URL(_.protocol+u):new URL(u),$=ue(T.pathname,h);T.origin===_.origin&&$!=null?u=$+T.search+T.hash:R=!0}catch{Z(!1,`<Link to="${u}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}let w=ds(u,{relative:n}),[S,P,C]=Tu(a,m),x=Bu(u,{replace:i,state:l,target:s,preventScrollReset:d,relative:n,viewTransition:c});function g(_){t&&t(_),_.defaultPrevented||x(_)}let O=k.createElement("a",{...m,...C,href:y||w,onClick:R||o?t:g,ref:Iu(f,P),target:s,"data-discover":!v&&r==="render"?"true":void 0});return S&&!v?k.createElement(k.Fragment,null,O,k.createElement(hi,{page:w})):O});wi.displayName="Link";var Uu=k.forwardRef(function({"aria-current":t="page",caseSensitive:r=!1,className:a="",end:n=!1,style:o,to:i,viewTransition:l,children:s,...u},d){let c=Jt(i,{relative:u.relative}),m=De(),f=k.useContext(ot),{navigator:h,basename:v}=k.useContext(xe),y=f!=null&&Xu(c)&&l===!0,R=h.encodeLocation?h.encodeLocation(c).pathname:c.pathname,w=m.pathname,S=f&&f.navigation&&f.navigation.location?f.navigation.location.pathname:null;r||(w=w.toLowerCase(),S=S?S.toLowerCase():null,R=R.toLowerCase()),S&&v&&(S=ue(S,v)||S);const P=R!=="/"&&R.endsWith("/")?R.length-1:R.length;let C=w===R||!n&&w.startsWith(R)&&w.charAt(P)==="/",x=S!=null&&(S===R||!n&&S.startsWith(R)&&S.charAt(R.length)==="/"),g={isActive:C,isPending:x,isTransitioning:y},O=C?t:void 0,_;typeof a=="function"?_=a(g):_=[a,C?"active":null,x?"pending":null,y?"transitioning":null].filter(Boolean).join(" ");let T=typeof o=="function"?o(g):o;return k.createElement(wi,{...u,"aria-current":O,className:_,ref:d,style:T,to:i,viewTransition:l},typeof s=="function"?s(g):s)});Uu.displayName="NavLink";var Ri=k.forwardRef(({discover:e="render",fetcherKey:t,navigate:r,reloadDocument:a,replace:n,state:o,method:i=sr,action:l,onSubmit:s,relative:u,preventScrollReset:d,viewTransition:c,...m},f)=>{let h=bi(),v=Yu(l,{relative:u}),y=i.toLowerCase()==="get"?"get":"post",R=typeof l=="string"&&gi.test(l),w=S=>{if(s&&s(S),S.defaultPrevented)return;S.preventDefault();let P=S.nativeEvent.submitter,C=P?.getAttribute("formmethod")||i;h(P||S.currentTarget,{fetcherKey:t,method:C,navigate:r,replace:n,state:o,relative:u,preventScrollReset:d,viewTransition:c})};return k.createElement("form",{ref:f,method:y,action:v,onSubmit:a?s:w,...m,"data-discover":!R&&e==="render"?"true":void 0})});Ri.displayName="Form";function zu({getKey:e,storageKey:t,...r}){let a=k.useContext(it),{basename:n}=k.useContext(xe),o=De(),i=Ma();Ju({getKey:e,storageKey:t});let l=k.useMemo(()=>{if(!a||!e)return null;let u=da(o,i,n,e);return u!==o.key?u:null},[]);if(!a||a.isSpaMode)return null;let s=((u,d)=>{if(!window.history.state||!window.history.state.key){let c=Math.random().toString(32).slice(2);window.history.replaceState({key:c},"")}try{let m=JSON.parse(sessionStorage.getItem(u)||"{}")[d||window.history.state.key];typeof m=="number"&&window.scrollTo(0,m)}catch(c){console.error(c),sessionStorage.removeItem(u)}}).toString();return k.createElement("script",{...r,suppressHydrationWarning:!0,dangerouslySetInnerHTML:{__html:`(${s})(${JSON.stringify(t||ca)}, ${JSON.stringify(l)})`}})}zu.displayName="ScrollRestoration";function Ei(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function Fr(e){let t=k.useContext(Je);return I(t,Ei(e)),t}function Va(e){let t=k.useContext(ot);return I(t,Ei(e)),t}function Bu(e,{target:t,replace:r,state:a,preventScrollReset:n,relative:o,viewTransition:i}={}){let l=Da(),s=De(),u=Jt(e,{relative:o});return k.useCallback(d=>{if(Us(d,t)){d.preventDefault();let c=r!==void 0?r:we(s)===we(u);l(e,{replace:c,state:a,preventScrollReset:n,relative:o,viewTransition:i})}},[s,l,u,r,a,t,e,n,o,i])}function _d(e){Z(typeof URLSearchParams<"u","You cannot use the `useSearchParams` hook in a browser that does not support the URLSearchParams API. If you need to support Internet Explorer 11, we recommend you load a polyfill such as https://github.com/ungap/url-search-params.");let t=k.useRef(na(e)),r=k.useRef(!1),a=De(),n=k.useMemo(()=>zs(a.search,r.current?null:t.current),[a.search]),o=Da(),i=k.useCallback((l,s)=>{const u=na(typeof l=="function"?l(new URLSearchParams(n)):l);r.current=!0,o("?"+u,s)},[o,n]);return[n,i]}var Wu=0,Vu=()=>`__${String(++Wu)}__`;function bi(){let{router:e}=Fr("useSubmit"),{basename:t}=k.useContext(xe),r=Rs();return k.useCallback(async(a,n={})=>{let{action:o,method:i,encType:l,formData:s,body:u}=Vs(a,t);if(n.navigate===!1){let d=n.fetcherKey||Vu();await e.fetch(d,r,n.action||o,{preventScrollReset:n.preventScrollReset,formData:s,body:u,formMethod:n.method||i,formEncType:n.encType||l,flushSync:n.flushSync})}else await e.navigate(n.action||o,{preventScrollReset:n.preventScrollReset,formData:s,body:u,formMethod:n.method||i,formEncType:n.encType||l,replace:n.replace,state:n.state,fromRouteId:r,flushSync:n.flushSync,viewTransition:n.viewTransition})},[e,t,r])}function Yu(e,{relative:t}={}){let{basename:r}=k.useContext(xe),a=k.useContext(Pe);I(a,"useFormAction must be used inside a RouteContext");let[n]=a.matches.slice(-1),o={...Jt(e||".",{relative:t})},i=De();if(e==null){o.search=i.search;let l=new URLSearchParams(o.search),s=l.getAll("index");if(s.some(d=>d==="")){l.delete("index"),s.filter(c=>c).forEach(c=>l.append("index",c));let d=l.toString();o.search=d?`?${d}`:""}}return(!e||e===".")&&n.route.index&&(o.search=o.search?o.search.replace(/^\?/,"?index&"):"?index"),r!=="/"&&(o.pathname=o.pathname==="/"?r:He([r,o.pathname])),we(o)}function kd({key:e}={}){let{router:t}=Fr("useFetcher"),r=Va("useFetcher"),a=k.useContext(Dr),n=k.useContext(Pe),o=n.matches[n.matches.length-1]?.route.id;I(a,"useFetcher must be used inside a FetchersContext"),I(n,"useFetcher must be used inside a RouteContext"),I(o!=null,'useFetcher can only be used on routes that contain a unique "id"');let i=k.useId(),[l,s]=k.useState(e||i);e&&e!==l&&s(e),k.useEffect(()=>(t.getFetcher(l),()=>t.deleteFetcher(l)),[t,l]);let u=k.useCallback(async(R,w)=>{I(o,"No routeId available for fetcher.load()"),await t.fetch(l,o,R,w)},[l,o,t]),d=bi(),c=k.useCallback(async(R,w)=>{await d(R,{...w,navigate:!1,fetcherKey:l})},[l,d]),m=k.useCallback(R=>t.resetFetcher(l,R),[t,l]),f=k.useMemo(()=>{let R=k.forwardRef((w,S)=>k.createElement(Ri,{...w,navigate:!1,fetcherKey:l,ref:S}));return R.displayName="fetcher.Form",R},[l]),h=r.fetchers.get(l)||ba,v=a.get(l);return k.useMemo(()=>({Form:f,submit:c,load:u,unstable_reset:m,...h,data:v}),[f,c,u,m,h,v])}function Td(){let e=Va("useFetchers");return Array.from(e.fetchers.entries()).map(([t,r])=>({...r,key:t}))}var ca="react-router-scroll-positions",or={};function da(e,t,r,a){let n=null;return a&&(r!=="/"?n=a({...e,pathname:ue(e.pathname,r)||e.pathname},t):n=a(e,t)),n==null&&(n=e.key),n}function Ju({getKey:e,storageKey:t}={}){let{router:r}=Fr("useScrollRestoration"),{restoreScrollPosition:a,preventScrollReset:n}=Va("useScrollRestoration"),{basename:o}=k.useContext(xe),i=De(),l=Ma(),s=Es();k.useEffect(()=>(window.history.scrollRestoration="manual",()=>{window.history.scrollRestoration="auto"}),[]),Ku(k.useCallback(()=>{if(s.state==="idle"){let u=da(i,l,o,e);or[u]=window.scrollY}try{sessionStorage.setItem(t||ca,JSON.stringify(or))}catch(u){Z(!1,`Failed to save scroll positions in sessionStorage, <ScrollRestoration /> will not work properly (${u}).`)}window.history.scrollRestoration="auto"},[s.state,e,o,i,l,t])),typeof document<"u"&&(k.useLayoutEffect(()=>{try{let u=sessionStorage.getItem(t||ca);u&&(or=JSON.parse(u))}catch{}},[t]),k.useLayoutEffect(()=>{let u=r?.enableScrollRestoration(or,()=>window.scrollY,e?(d,c)=>da(d,c,o,e):void 0);return()=>u&&u()},[r,o,e]),k.useLayoutEffect(()=>{if(a!==!1){if(typeof a=="number"){window.scrollTo(0,a);return}try{if(i.hash){let u=document.getElementById(decodeURIComponent(i.hash.slice(1)));if(u){u.scrollIntoView();return}}}catch{Z(!1,`"${i.hash.slice(1)}" is not a decodable element ID. The view will not scroll to it.`)}n!==!0&&window.scrollTo(0,0)}},[i,a,n]))}function Md(e,t){let{capture:r}=t||{};k.useEffect(()=>{let a=r!=null?{capture:r}:void 0;return window.addEventListener("beforeunload",e,a),()=>{window.removeEventListener("beforeunload",e,a)}},[e,r])}function Ku(e,t){let{capture:r}={};k.useEffect(()=>{let a=r!=null?{capture:r}:void 0;return window.addEventListener("pagehide",e,a),()=>{window.removeEventListener("pagehide",e,a)}},[e,r])}function Od({when:e,message:t}){let r=Cs(e);k.useEffect(()=>{r.state==="blocked"&&(window.confirm(t)?setTimeout(r.proceed,0):r.reset())},[r,t]),k.useEffect(()=>{r.state==="blocked"&&!e&&r.reset()},[r,e])}function Xu(e,{relative:t}={}){let r=k.useContext(Pr);I(r!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:a}=Fr("useViewTransitionState"),n=Jt(e,{relative:t});if(!r.isTransitioning)return!1;let o=ue(r.currentLocation.pathname,a)||r.currentLocation.pathname,i=ue(r.nextLocation.pathname,a)||r.nextLocation.pathname;return zt(n.pathname,i)!=null||zt(n.pathname,o)!=null}const Ie=await le("react");function Fd({basename:e,children:t,location:r="/"}){typeof r=="string"&&(r=Me(r));let a="POP",n={pathname:r.pathname||"/",search:r.search||"",hash:r.hash||"",state:r.state!=null?r.state:null,key:r.key||"default"},o=Ci();return Ie.createElement(gt,{basename:e,children:t,location:n,navigationType:a,navigator:o,static:!0})}function Si({context:e,router:t,hydrate:r=!0,nonce:a}){I(t&&e,"You must provide `router` and `context` to <StaticRouterProvider>");let n={router:t,navigator:Ci(),static:!0,staticContext:e,basename:e.basename||"/"},o=new Map,i="";if(r!==!1){let s={loaderData:e.loaderData,actionData:e.actionData,errors:Qu(e.errors)};i=`window.__staticRouterHydrationData = JSON.parse(${tc(JSON.stringify(JSON.stringify(s)))});`}let{state:l}=n.router;return Ie.createElement(Ie.Fragment,null,Ie.createElement(Je.Provider,{value:n},Ie.createElement(ot.Provider,{value:l},Ie.createElement(Dr.Provider,{value:o},Ie.createElement(Pr.Provider,{value:{isTransitioning:!1}},Ie.createElement(gt,{basename:n.basename,location:l.location,navigationType:l.historyAction,navigator:n.navigator,static:n.static},Ie.createElement(Gu,{routes:t.routes,future:t.future,state:l})))))),i?Ie.createElement("script",{suppressHydrationWarning:!0,nonce:a,dangerouslySetInnerHTML:{__html:i}}):null)}function Gu({routes:e,future:t,state:r}){return _a(e,void 0,r,void 0,t)}function Qu(e){if(!e)return null;let t=Object.entries(e),r={};for(let[a,n]of t)ie(n)?r[a]={...n,__type:"RouteErrorResponse"}:n instanceof Error?r[a]={message:n.message,__type:"Error",...n.name!=="Error"?{__subType:n.name}:{}}:r[a]=n;return r}function Ci(){return{createHref:Pi,encodeLocation:Di,push(e){throw new Error(`You cannot use navigator.push() on the server because it is a stateless environment. This error was probably triggered when you did a \`navigate(${JSON.stringify(e)})\` somewhere in your app.`)},replace(e){throw new Error(`You cannot use navigator.replace() on the server because it is a stateless environment. This error was probably triggered when you did a \`navigate(${JSON.stringify(e)}, { replace: true })\` somewhere in your app.`)},go(e){throw new Error(`You cannot use navigator.go() on the server because it is a stateless environment. This error was probably triggered when you did a \`navigate(${e})\` somewhere in your app.`)},back(){throw new Error("You cannot use navigator.back() on the server because it is a stateless environment.")},forward(){throw new Error("You cannot use navigator.forward() on the server because it is a stateless environment.")}}}function Nd(e,t){return po(e,{...t,mapRouteProperties:kt})}function xi(e,t,r={}){let a={},n=at(e,kt,void 0,a),o=t.matches.map(l=>{let s=a[l.route.id]||l.route;return{...l,route:s}}),i=l=>`You cannot use router.${l}() on the server because it is a stateless environment`;return{get basename(){return t.basename},get future(){return{v8_middleware:!1,...r?.future}},get state(){return{historyAction:"POP",location:t.location,matches:o,loaderData:t.loaderData,actionData:t.actionData,errors:t.errors,initialized:!0,navigation:lr,restoreScrollPosition:null,preventScrollReset:!1,revalidation:"idle",fetchers:new Map,blockers:new Map}},get routes(){return n},get window(){},initialize(){throw i("initialize")},subscribe(){throw i("subscribe")},enableScrollRestoration(){throw i("enableScrollRestoration")},navigate(){throw i("navigate")},fetch(){throw i("fetch")},revalidate(){throw i("revalidate")},createHref:Pi,encodeLocation:Di,getFetcher(){return ba},deleteFetcher(){throw i("deleteFetcher")},resetFetcher(){throw i("resetFetcher")},dispose(){throw i("dispose")},getBlocker(){return pt},deleteBlocker(){throw i("deleteBlocker")},patchRoutes(){throw i("patchRoutes")},_internalFetchControllers:new Map,_internalSetRoutes(){throw i("_internalSetRoutes")},_internalSetStateDoNotUseOrYouWillBreakYourApp(){throw i("_internalSetStateDoNotUseOrYouWillBreakYourApp")}}}function Pi(e){return typeof e=="string"?e:we(e)}function Di(e){let t=typeof e=="string"?e:we(e);t=t.replace(/ $/,"%20");let r=Zu.test(t)?new URL(t):new URL(t,"http://localhost");return{pathname:r.pathname,search:r.search,hash:r.hash}}var Zu=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,qu={"&":"\\u0026",">":"\\u003e","<":"\\u003c","\u2028":"\\u2028","\u2029":"\\u2029"},ec=/[&><\u2028\u2029]/g;function tc(e){return e.replace(ec,t=>qu[t])}var Xe={};Object.defineProperty(Xe,"__esModule",{value:!0});Xe.parseCookie=Ti;var rc=Xe.parse=Ti;Xe.stringifyCookie=sc;Xe.stringifySetCookie=Nr;var Li=Xe.serialize=Nr;Xe.parseSetCookie=uc;Xe.stringifySetCookie=Nr;Li=Xe.serialize=Nr;const _i=/^[\u0021-\u003A\u003C\u003E-\u007E]+$/,ki=/^[\u0021-\u003A\u003C-\u007E]*$/,ac=/^([.]?[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)([.][a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)*$/i,nc=/^[\u0020-\u003A\u003D-\u007E]*$/,oc=/^-?\d+$/,ic=Object.prototype.toString,lc=(()=>{const e=function(){};return e.prototype=Object.create(null),e})();function Ti(e,t){const r=new lc,a=e.length;if(a<2)return r;const n=t?.decode||Mi;let o=0;do{const i=ha(e,o,a);if(i===-1)break;const l=fa(e,o,a);if(i>l){o=e.lastIndexOf(";",i-1)+1;continue}const s=Ze(e,o,i);r[s]===void 0&&(r[s]=n(Ze(e,i+1,l))),o=l+1}while(o<a);return r}function sc(e,t){const r=t?.encode||encodeURIComponent,a=[];for(const n of Object.keys(e)){const o=e[n];if(o===void 0)continue;if(!_i.test(n))throw new TypeError(`cookie name is invalid: ${n}`);const i=r(o);if(!ki.test(i))throw new TypeError(`cookie val is invalid: ${o}`);a.push(`${n}=${i}`)}return a.join("; ")}function Nr(e,t,r){const a=typeof e=="object"?e:{...r,name:e,value:String(t)},o=(typeof t=="object"?t:r)?.encode||encodeURIComponent;if(!_i.test(a.name))throw new TypeError(`argument name is invalid: ${a.name}`);const i=a.value?o(a.value):"";if(!ki.test(i))throw new TypeError(`argument val is invalid: ${a.value}`);let l=a.name+"="+i;if(a.maxAge!==void 0){if(!Number.isInteger(a.maxAge))throw new TypeError(`option maxAge is invalid: ${a.maxAge}`);l+="; Max-Age="+a.maxAge}if(a.domain){if(!ac.test(a.domain))throw new TypeError(`option domain is invalid: ${a.domain}`);l+="; Domain="+a.domain}if(a.path){if(!nc.test(a.path))throw new TypeError(`option path is invalid: ${a.path}`);l+="; Path="+a.path}if(a.expires){if(!cc(a.expires)||!Number.isFinite(a.expires.valueOf()))throw new TypeError(`option expires is invalid: ${a.expires}`);l+="; Expires="+a.expires.toUTCString()}if(a.httpOnly&&(l+="; HttpOnly"),a.secure&&(l+="; Secure"),a.partitioned&&(l+="; Partitioned"),a.priority)switch(typeof a.priority=="string"?a.priority.toLowerCase():void 0){case"low":l+="; Priority=Low";break;case"medium":l+="; Priority=Medium";break;case"high":l+="; Priority=High";break;default:throw new TypeError(`option priority is invalid: ${a.priority}`)}if(a.sameSite)switch(typeof a.sameSite=="string"?a.sameSite.toLowerCase():a.sameSite){case!0:case"strict":l+="; SameSite=Strict";break;case"lax":l+="; SameSite=Lax";break;case"none":l+="; SameSite=None";break;default:throw new TypeError(`option sameSite is invalid: ${a.sameSite}`)}return l}function uc(e,t){const r=t?.decode||Mi,a=e.length,n=fa(e,0,a),o=ha(e,0,n),i=o===-1?{name:"",value:r(Ze(e,0,n))}:{name:Ze(e,0,o),value:r(Ze(e,o+1,n))};let l=n+1;for(;l<a;){const s=fa(e,l,a),u=ha(e,l,s),d=u===-1?Ze(e,l,s):Ze(e,l,u),c=u===-1?void 0:Ze(e,u+1,s);switch(d.toLowerCase()){case"httponly":i.httpOnly=!0;break;case"secure":i.secure=!0;break;case"partitioned":i.partitioned=!0;break;case"domain":i.domain=c;break;case"path":i.path=c;break;case"max-age":c&&oc.test(c)&&(i.maxAge=Number(c));break;case"expires":if(!c)break;const m=new Date(c);Number.isFinite(m.valueOf())&&(i.expires=m);break;case"priority":if(!c)break;const f=c.toLowerCase();(f==="low"||f==="medium"||f==="high")&&(i.priority=f);break;case"samesite":if(!c)break;const h=c.toLowerCase();(h==="lax"||h==="strict"||h==="none")&&(i.sameSite=h);break}l=s+1}return i}function fa(e,t,r){const a=e.indexOf(";",t);return a===-1?r:a}function ha(e,t,r){const a=e.indexOf("=",t);return a<r?a:-1}function Ze(e,t,r){let a=t,n=r;do{const o=e.charCodeAt(a);if(o!==32&&o!==9)break}while(++a<n);for(;n>a;){const o=e.charCodeAt(n-1);if(o!==32&&o!==9)break;n--}return e.slice(a,n)}function Mi(e){if(e.indexOf("%")===-1)return e;try{return decodeURIComponent(e)}catch{return e}}function cc(e){return ic.call(e)==="[object Date]"}var Ar={exports:{}},vr={decodeValues:!0,map:!1,silent:!1};function ma(e){return typeof e!="string"||e in{}}function pa(){return Object.create(null)}function ya(e){return typeof e=="string"&&!!e.trim()}function va(e,t){var r=e.split(";").filter(ya),a=r.shift(),n=dc(a),o=n.name,i=n.value;if(t=t?Object.assign({},vr,t):vr,ma(o))return null;try{i=t.decodeValues?decodeURIComponent(i):i}catch(s){console.error("set-cookie-parser: failed to decode cookie value. Set options.decodeValues=false to disable decoding.",s)}var l=pa();return l.name=o,l.value=i,r.forEach(function(s){var u=s.split("="),d=u.shift().trimLeft().toLowerCase();if(!ma(d)){var c=u.join("=");if(d==="expires")l.expires=new Date(c);else if(d==="max-age"){var m=parseInt(c,10);Number.isNaN(m)||(l.maxAge=m)}else d==="secure"?l.secure=!0:d==="httponly"?l.httpOnly=!0:d==="samesite"?l.sameSite=c:d==="partitioned"?l.partitioned=!0:d&&(l[d]=c)}}),l}function dc(e){var t="",r="",a=e.split("=");return a.length>1?(t=a.shift(),r=a.join("=")):r=e,{name:t,value:r}}function Oi(e,t){if(t=t?Object.assign({},vr,t):vr,!e)return t.map?pa():[];if(e.headers)if(typeof e.headers.getSetCookie=="function")e=e.headers.getSetCookie();else if(e.headers["set-cookie"])e=e.headers["set-cookie"];else{var r=e.headers[Object.keys(e.headers).find(function(n){return n.toLowerCase()==="set-cookie"})];!r&&e.headers.cookie&&!t.silent&&console.warn("Warning: set-cookie-parser appears to have been called on a request object. It is designed to parse Set-Cookie headers from responses, not Cookie headers from requests. Set the option {silent: true} to suppress this warning."),e=r}if(Array.isArray(e)||(e=[e]),t.map){var a=pa();return e.filter(ya).reduce(function(n,o){var i=va(o,t);return i&&!ma(i.name)&&(n[i.name]=i),n},a)}else return e.filter(ya).map(function(n){return va(n,t)}).filter(Boolean)}function fc(e){if(Array.isArray(e))return e;if(typeof e!="string")return[];var t=[],r=0,a,n,o,i,l;function s(){for(;r<e.length&&/\s/.test(e.charAt(r));)r+=1;return r<e.length}function u(){return n=e.charAt(r),n!=="="&&n!==";"&&n!==","}for(;r<e.length;){for(a=r,l=!1;s();)if(n=e.charAt(r),n===","){for(o=r,r+=1,s(),i=r;r<e.length&&u();)r+=1;r<e.length&&e.charAt(r)==="="?(l=!0,r=i,t.push(e.substring(a,o)),a=r):r=o+1}else r+=1;(!l||r>=e.length)&&t.push(e.substring(a,e.length))}return t}Ar.exports=Oi;Ar.exports.parse=Oi;Ar.exports.parseString=va;var hc=Ar.exports.splitCookiesString=fc,mc={};const Qe=await le("react");function Ad({context:e,url:t,nonce:r}){typeof t=="string"&&(t=new URL(t));let{manifest:a,routeModules:n,criticalCss:o,serverHandoffString:i}=e,l=ui(a.routes,n,e.future,e.isSpaMode);e.staticHandlerContext.loaderData={...e.staticHandlerContext.loaderData};for(let u of e.staticHandlerContext.matches){let d=u.route.id,c=n[d],m=e.manifest.routes[d];c&&m&&Mr(d,c.clientLoader,m.hasLoader,e.isSpaMode)&&(c.HydrateFallback||!m.hasLoader)&&delete e.staticHandlerContext.loaderData[d]}let s=xi(l,e.staticHandlerContext);return Qe.createElement(Qe.Fragment,null,Qe.createElement(it.Provider,{value:{manifest:a,routeModules:n,criticalCss:o,serverHandoffString:i,future:e.future,ssr:e.ssr,isSpaMode:e.isSpaMode,routeDiscovery:e.routeDiscovery,serializeError:e.serializeError,renderMeta:e.renderMeta}},Qe.createElement(mi,{location:s.state.location},Qe.createElement(Si,{router:s,context:e.staticHandlerContext,hydrate:!1}))),e.serverHandoffStream?Qe.createElement(Qe.Suspense,null,Qe.createElement(ti,{context:e,identifier:0,reader:e.serverHandoffStream.getReader(),textDecoder:new TextDecoder,nonce:r})):null)}const ir=await le("react");function $d(e,t){return function({initialEntries:a,initialIndex:n,hydrationData:o,future:i}){let l=ir.useRef(),s=ir.useRef();if(l.current==null){s.current={future:{unstable_subResourceIntegrity:i?.unstable_subResourceIntegrity===!0,v8_middleware:i?.v8_middleware===!0},manifest:{routes:{},entry:{imports:[],module:""},url:"",version:""},routeModules:{},ssr:!1,isSpaMode:!1,routeDiscovery:{mode:"lazy",manifestPath:"/__manifest"}};let u=Fi(at(e,d=>d),t!==void 0?t:i?.v8_middleware?new Ve:{},s.current.manifest,s.current.routeModules);l.current=Ps(u,{initialEntries:a,initialIndex:n,hydrationData:o})}return ir.createElement(it.Provider,{value:s.current},ir.createElement(Ao,{router:l.current}))}}function Fi(e,t,r,a,n){return e.map(o=>{if(!o.id)throw new Error("Expected a route.id in react-router processRoutes() function");let i={id:o.id,path:o.path,index:o.index,Component:o.Component?Fs(o.Component):void 0,HydrateFallback:o.HydrateFallback?Ns(o.HydrateFallback):void 0,ErrorBoundary:o.ErrorBoundary?As(o.ErrorBoundary):void 0,action:o.action?s=>o.action({...s,context:t}):void 0,loader:o.loader?s=>o.loader({...s,context:t}):void 0,middleware:o.middleware?o.middleware.map(s=>(...u)=>s({...u[0],context:t},u[1])):void 0,handle:o.handle,shouldRevalidate:o.shouldRevalidate},l={id:o.id,path:o.path,index:o.index,parentId:n,hasAction:o.action!=null,hasLoader:o.loader!=null,hasClientAction:!1,hasClientLoader:!1,hasClientMiddleware:!1,hasErrorBoundary:o.ErrorBoundary!=null,module:"build/stub-path-to-module.js",clientActionModule:void 0,clientLoaderModule:void 0,clientMiddlewareModule:void 0,hydrateFallbackModule:void 0};return r.routes[i.id]=l,a[o.id]={default:i.Component||ks,ErrorBoundary:i.ErrorBoundary||void 0,handle:o.handle,links:o.links,meta:o.meta,shouldRevalidate:o.shouldRevalidate},o.children&&(i.children=Fi(o.children,t,r,a,i.id)),i})}var Ya=new TextEncoder,pc=async(e,t)=>{let r=Ya.encode(e),a=await Ni(t,["sign"]),n=await crypto.subtle.sign("HMAC",a,r),o=btoa(String.fromCharCode(...new Uint8Array(n))).replace(/=+$/,"");return e+"."+o},yc=async(e,t)=>{let r=e.lastIndexOf("."),a=e.slice(0,r),n=e.slice(r+1),o=Ya.encode(a),i=await Ni(t,["verify"]);try{let l=vc(atob(n));return await crypto.subtle.verify("HMAC",i,l,o)?a:!1}catch{return!1}},Ni=async(e,t)=>crypto.subtle.importKey("raw",Ya.encode(e),{name:"HMAC",hash:"SHA-256"},!1,t);function vc(e){let t=new Uint8Array(e.length);for(let r=0;r<e.length;r++)t[r]=e.charCodeAt(r);return t}var Ai=(e,t={})=>{let{secrets:r=[],...a}={path:"/",sameSite:"lax",...t};return Sc(e,a.expires),{get name(){return e},get isSigned(){return r.length>0},get expires(){return typeof a.maxAge<"u"?new Date(Date.now()+a.maxAge*1e3):a.expires},async parse(n,o){if(!n)return null;let i=rc(n,{...a,...o});if(e in i){let l=i[e];return typeof l=="string"&&l!==""?await wc(l,r):""}else return null},async serialize(n,o){return Li(e,n===""?"":await gc(n,r),{...a,...o})}}},$i=e=>e!=null&&typeof e.name=="string"&&typeof e.isSigned=="boolean"&&typeof e.parse=="function"&&typeof e.serialize=="function";async function gc(e,t){let r=Rc(e);return t.length>0&&(r=await pc(r,t[0])),r}async function wc(e,t){if(t.length>0){for(let r of t){let a=await yc(e,r);if(a!==!1)return $n(a)}return null}return $n(e)}function Rc(e){return btoa(bc(encodeURIComponent(JSON.stringify(e))))}function $n(e){try{return JSON.parse(decodeURIComponent(Ec(atob(e))))}catch{return{}}}function Ec(e){let t=e.toString(),r="",a=0,n,o;for(;a<t.length;)n=t.charAt(a++),/[\w*+\-./@]/.exec(n)?r+=n:(o=n.charCodeAt(0),o<256?r+="%"+In(o,2):r+="%u"+In(o,4).toUpperCase());return r}function In(e,t){let r=e.toString(16);for(;r.length<t;)r="0"+r;return r}function bc(e){let t=e.toString(),r="",a=0,n,o;for(;a<t.length;){if(n=t.charAt(a++),n==="%"){if(t.charAt(a)==="u"){if(o=t.slice(a+1,a+5),/^[\da-f]{4}$/i.exec(o)){r+=String.fromCharCode(parseInt(o,16)),a+=5;continue}}else if(o=t.slice(a,a+2),/^[\da-f]{2}$/i.exec(o)){r+=String.fromCharCode(parseInt(o,16)),a+=2;continue}}r+=n}return r}function Sc(e,t){Wt(!t,`The "${e}" cookie has an "expires" property set. This will cause the expires value to not be updated when the session is committed. Instead, you should set the expires value when serializing the cookie. You can use \`commitSession(session, { expires })\` if using a session storage object, or \`cookie.serialize("value", { expires })\` if you're using the cookie directly.`)}function Cc(e){return Object.keys(e).reduce((t,r)=>{let a=e[r];return a&&(t[r]=a.module),t},{})}var xc=(e=>(e.Development="development",e.Production="production",e.Test="test",e))(xc||{});function Pc(e){return e==="development"||e==="production"||e==="test"}function $r(e,t){if(e instanceof Error&&t!=="development"){let r=new Error("Unexpected Server Error");return r.stack=void 0,r}return e}function gr(e,t){return Object.entries(e).reduce((r,[a,n])=>Object.assign(r,{[a]:$r(n,t)}),{})}function Ii(e,t){let r=$r(e,t);return{message:r.message,stack:r.stack}}function Hn(e,t){if(!e)return null;let r=Object.entries(e),a={};for(let[n,o]of r)if(ie(o))a[n]={...o,__type:"RouteErrorResponse"};else if(o instanceof Error){let i=$r(o,t);a[n]={message:i.message,stack:i.stack,__type:"Error",...i.name!=="Error"?{__subType:i.name}:{}}}else a[n]=o;return a}function ga(e,t,r){let a=Ce(e,t,r);return a?a.map(n=>({params:n.params,pathname:n.pathname,route:n.route})):null}async function jn(e,t){let r=await e({request:Lc(Dc(t.request)),params:t.params,context:t.context,unstable_pattern:t.unstable_pattern});if(rt(r)&&r.init&&r.init.status&&xr(r.init.status))throw new Response(null,r.init);return r}function Dc(e){let t=new URL(e.url),r=t.searchParams.getAll("index");t.searchParams.delete("index");let a=[];for(let o of r)o&&a.push(o);for(let o of a)t.searchParams.append("index",o);let n={method:e.method,body:e.body,headers:e.headers,signal:e.signal};return n.body&&(n.duplex="half"),new Request(t.href,n)}function Lc(e){let t=new URL(e.url);t.searchParams.delete("_routes");let r={method:e.method,body:e.body,headers:e.headers,signal:e.signal};return r.body&&(r.duplex="half"),new Request(t.href,r)}function dr(e,t){if(e===!1||e===null||typeof e>"u")throw console.error("The following error is a bug in React Router; please open an issue! https://github.com/remix-run/react-router/issues/new/choose"),new Error(t)}var Hi="__reactRouterDevServerHooks";function Id(e){globalThis[Hi]=e}function Xr(){return globalThis[Hi]}function ji(e,t){if(typeof process<"u")try{if(mc?.IS_RR_BUILD_REQUEST==="yes")return e.headers.get(t)}catch{}return null}function Ui(e){let t={};return Object.values(e).forEach(r=>{if(r){let a=r.parentId||"";t[a]||(t[a]=[]),t[a].push(r)}}),t}function zi(e,t="",r=Ui(e)){return(r[t]||[]).map(a=>({...a,children:zi(e,a.id,r)}))}function Bi(e,t,r="",a=Ui(e)){return(a[r]||[]).map(n=>{let o={hasErrorBoundary:n.id==="root"||n.module.ErrorBoundary!=null,id:n.id,path:n.path,middleware:n.module.middleware,loader:n.module.loader?async i=>{let l=ji(i.request,"X-React-Router-Prerender-Data");if(l!=null){let u=l&&decodeURI(l);dr(u,"Missing prerendered data for route");let d=new TextEncoder().encode(u),c=new ReadableStream({start(h){h.enqueue(d),h.close()}}),f=(await Ia(c,global)).value;if(f&&nt in f){let h=f[nt],v={status:h.status};throw h.reload?Hl(h.redirect,v):h.replace?jl(h.redirect,v):Sr(h.redirect,v)}else{dr(f&&n.id in f,"Unable to decode prerendered data");let h=f[n.id];return dr("data"in h,"Unable to process prerendered data"),h.data}}return await jn(n.module.loader,i)}:void 0,action:n.module.action?i=>jn(n.module.action,i):void 0,handle:n.module.handle};return n.index?{index:!0,...o}:{caseSensitive:n.caseSensitive,children:Bi(e,t,n.id,a),...o}})}function Un(e){return Aa(JSON.stringify(e))}function Ja(e,t){return _c(e,r=>{let a=t.routes[r.route.id];return dr(a,`Route with id "${r.route.id}" not found in build`),a.module.headers})}function _c(e,t,r){let a=e.errors?e.matches.findIndex(l=>e.errors[l.route.id]):-1,n=a>=0?e.matches.slice(0,a+1):e.matches,o;if(a>=0){let{actionHeaders:l,actionData:s,loaderHeaders:u,loaderData:d}=e;e.matches.slice(a).some(c=>{let m=c.route.id;return l[m]&&(!s||!s.hasOwnProperty(m))?o=l[m]:u[m]&&!d.hasOwnProperty(m)&&(o=u[m]),o!=null})}const i=new Headers(r);return n.reduce((l,s,u)=>{let{id:d}=s.route,c=e.loaderHeaders[d]||new Headers,m=e.actionHeaders[d]||new Headers,f=o!=null&&u===n.length-1,h=f&&o!==c&&o!==m,v=t(s);if(v==null){let R=new Headers(l);return h&&mt(o,R),mt(m,R),mt(c,R),R}let y=new Headers(typeof v=="function"?v({loaderHeaders:c,parentHeaders:l,actionHeaders:m,errorHeaders:f?o:void 0}):v);return h&&mt(o,y),mt(m,y),mt(c,y),mt(l,y),y},new Headers(i))}function mt(e,t){let r=e.get("Set-Cookie");if(r){let a=hc(r),n=new Set(t.getSetCookie());a.forEach(o=>{n.has(o)||t.append("Set-Cookie",o)})}}var Wi=new Set([...ei,304]);async function kc(e,t,r,a,n,o,i){try{let d=new Request(n,{method:a.method,body:a.body,headers:a.headers,signal:a.signal,...a.body?{duplex:"half"}:void 0}),c=await r.query(d,{requestContext:o,skipLoaderErrorBubbling:!0,skipRevalidation:!0,generateMiddlewareResponse:e.future.v8_middleware?async m=>{try{let f=await m(d);return l(f)}catch(f){return s(f)}}:void 0});return l(c)}catch(d){return s(d)}function l(d){return ae(d)?d:u(d)}function s(d){return i(d),Yt(a,e,t,{result:{error:d},headers:new Headers,status:500})}function u(d){let c=Ja(d,e);if(xr(d.statusCode)&&c.has("Location"))return new Response(null,{status:d.statusCode,headers:c});d.errors&&(Object.values(d.errors).forEach(f=>{(!ie(f)||f.error)&&i(f)}),d.errors=gr(d.errors,t));let m;return d.errors?m={error:Object.values(d.errors)[0]}:m={data:Object.values(d.actionData||{})[0]},Yt(a,e,t,{result:m,headers:c,status:d.statusCode})}}async function Tc(e,t,r,a,n,o,i){let l=new URL(a.url).searchParams.get("_routes"),s=l?new Set(l.split(",")):null;try{let m=new Request(n,{headers:a.headers,signal:a.signal}),f=await r.query(m,{requestContext:o,filterMatchesToLoad:h=>!s||s.has(h.route.id),skipLoaderErrorBubbling:!0,generateMiddlewareResponse:e.future.v8_middleware?async h=>{try{let v=await h(m);return u(v)}catch(v){return d(v)}}:void 0});return u(f)}catch(m){return d(m)}function u(m){return ae(m)?m:c(m)}function d(m){return i(m),Yt(a,e,t,{result:{error:m},headers:new Headers,status:500})}function c(m){let f=Ja(m,e);if(xr(m.statusCode)&&f.has("Location"))return new Response(null,{status:m.statusCode,headers:f});m.errors&&(Object.values(m.errors).forEach(y=>{(!ie(y)||y.error)&&i(y)}),m.errors=gr(m.errors,t));let h={},v=new Set(m.matches.filter(y=>s?s.has(y.route.id):y.route.loader!=null).map(y=>y.route.id));if(m.errors)for(let[y,R]of Object.entries(m.errors))h[y]={error:R};for(let[y,R]of Object.entries(m.loaderData))!(y in h)&&v.has(y)&&(h[y]={data:R});return Yt(a,e,t,{result:h,headers:f,status:m.statusCode})}}function Yt(e,t,r,{result:a,headers:n,status:o}){let i=new Headers(n);return i.set("X-Remix-Response","yes"),Wi.has(o)?new Response(null,{status:o,headers:i}):(i.set("Content-Type","text/x-script"),i.delete("Content-Length"),new Response(wa(a,e.signal,t.entry.module.streamTimeout,r),{status:o||200,headers:i}))}function zn(e,t,r,a){let n=Mc(e.status,e.headers,r.basename),o=new Headers(e.headers);return o.delete("Location"),o.set("Content-Type","text/x-script"),Yt(t,r,a,{result:t.method==="GET"?{[nt]:n}:n,headers:o,status:$a})}function Mc(e,t,r){let a=t.get("Location");return r&&(a=ue(a,r)||a),{redirect:a,status:e,revalidate:t.has("X-Remix-Revalidate")||t.has("Set-Cookie"),reload:t.has("X-Remix-Reload-Document"),replace:t.has("X-Remix-Replace")}}function wa(e,t,r,a){let n=new AbortController,o=setTimeout(()=>n.abort(new Error("Server Timeout")),typeof r=="number"?r:4950);return t.addEventListener("abort",()=>clearTimeout(o)),qs(e,{signal:n.signal,plugins:[i=>{if(i instanceof Error){let{name:l,message:s,stack:u}=a==="production"?$r(i,a):i;return["SanitizedError",l,s,u]}if(i instanceof Re){let{data:l,status:s,statusText:u}=i;return["ErrorResponse",l,s,u]}if(i&&typeof i=="object"&&nt in i)return["SingleFetchRedirect",i[nt]]}],postPlugins:[i=>{if(i&&typeof i=="object")return["SingleFetchClassInstance",Object.fromEntries(Object.entries(i))]},()=>["SingleFetchFallback"]]})}function Bn(e,t){let r=zi(e.routes),a=Bi(e.routes,e.future),n=Pc(t)?t:"production",o=po(a,{basename:e.basename,unstable_instrumentations:e.entry.module.unstable_instrumentations}),i=e.entry.module.handleError||((s,{request:u})=>{n!=="test"&&!u.signal.aborted&&console.error(ie(s)&&s.error?s.error:s)}),l=async(s,u)=>{let d={},c,m=P=>{t==="development"&&Xr()?.processRequestError?.(P),i(P,{context:c,params:d,request:s})};if(e.future.v8_middleware){if(u&&!(u instanceof Ve)){let P=new Error("Invalid `context` value provided to `handleRequest`. When middleware is enabled you must return an instance of `RouterContextProvider` from your `getLoadContext` function.");return m(P),wr(P,n)}c=u||new Ve}else c=u||{};let f=new URL(s.url),h=e.basename||"/",v=f.pathname;ue(v,h)==="/_root.data"?v=h:v.endsWith(".data")&&(v=v.replace(/\.data$/,"")),ue(v,h)!=="/"&&v.endsWith("/")&&(v=v.slice(0,-1));let y=ji(s,"X-React-Router-SPA-Mode")==="yes";if(!e.ssr){let P=decodeURI(v);if(h!=="/"){let C=ue(P,h);if(C==null)return i(new Re(404,"Not Found",`Refusing to prerender the \`${P}\` path because it does not start with the basename \`${h}\``),{context:c,params:d,request:s}),new Response("Not Found",{status:404,statusText:"Not Found"});P=C}if(e.prerender.length===0)y=!0;else if(!e.prerender.includes(P)&&!e.prerender.includes(P+"/")){if(f.pathname.endsWith(".data"))return i(new Re(404,"Not Found",`Refusing to SSR the path \`${P}\` because \`ssr:false\` is set and the path is not included in the \`prerender\` config, so in production the path will be a 404.`),{context:c,params:d,request:s}),new Response("Not Found",{status:404,statusText:"Not Found"});y=!0}}let R=di(e.routeDiscovery.manifestPath,h);if(f.pathname===R)try{return await Oc(e,r,f)}catch(P){return m(P),new Response("Unknown Server Error",{status:500})}let w=ga(r,v,e.basename);w&&w.length>0&&Object.assign(d,w[0].params);let S;if(f.pathname.endsWith(".data")){let P=new URL(s.url);P.pathname=v;let C=ga(r,P.pathname,e.basename);S=await Fc(n,e,o,s,P,c,m),hr(S)&&(S=zn(S,s,e,n)),e.entry.module.handleDataRequest&&(S=await e.entry.module.handleDataRequest(S,{context:c,params:C?C[0].params:{},request:s}),hr(S)&&(S=zn(S,s,e,n)))}else if(!y&&w&&w[w.length-1].route.module.default==null&&w[w.length-1].route.module.ErrorBoundary==null)S=await Ac(n,e,o,w.slice(-1)[0].route.id,s,c,m);else{let{pathname:P}=f,C;e.unstable_getCriticalCss?C=await e.unstable_getCriticalCss({pathname:P}):t==="development"&&Xr()?.getCriticalCss&&(C=await Xr()?.getCriticalCss?.(P)),S=await Nc(n,e,o,s,c,m,y,C)}return s.method==="HEAD"?new Response(null,{headers:S.headers,status:S.status,statusText:S.statusText}):S};return e.entry.module.unstable_instrumentations&&(l=zl(l,e.entry.module.unstable_instrumentations.map(s=>s.handler).filter(Boolean))),{routes:r,dataRoutes:a,serverMode:n,staticHandler:o,errorHandler:i,requestHandler:l}}var Hd=(e,t)=>{let r,a,n,o,i,l;return async function(u,d){if(r=typeof e=="function"?await e():e,typeof e=="function"){let c=Bn(r,t);a=c.routes,n=c.serverMode,o=c.staticHandler,i=c.errorHandler,l=c.requestHandler}else if(!a||!n||!o||!i||!l){let c=Bn(r,t);a=c.routes,n=c.serverMode,o=c.staticHandler,i=c.errorHandler,l=c.requestHandler}return l(u,d)}};async function Oc(e,t,r){if(e.assets.version!==r.searchParams.get("version"))return new Response(null,{status:204,headers:{"X-Remix-Reload-Document":"true"}});let a={};if(r.searchParams.has("paths")){let n=new Set;(r.searchParams.get("paths")||"").split(",").filter(Boolean).forEach(l=>{l.startsWith("/")||(l=`/${l}`);let s=l.split("/").slice(1);s.forEach((u,d)=>{let c=s.slice(0,d+1).join("/");n.add(`/${c}`)})});for(let l of n){let s=ga(t,l,e.basename);if(s)for(let u of s){let d=u.route.id,c=e.assets.routes[d];c&&(a[d]=c)}}return Response.json(a,{headers:{"Cache-Control":"public, max-age=31536000, immutable"}})}return new Response("Invalid Request",{status:400})}async function Fc(e,t,r,a,n,o,i){return a.method!=="GET"?await kc(t,e,r,a,n,o,i):await Tc(t,e,r,a,n,o,i)}async function Nc(e,t,r,a,n,o,i,l){try{let u=await r.query(a,{requestContext:n,generateMiddlewareResponse:t.future.v8_middleware?async d=>{try{let c=await d(a);return ae(c)||(c=await s(c,i)),c}catch(c){return o(c),new Response(null,{status:500})}}:void 0});return ae(u)||(u=await s(u,i)),u}catch(u){return o(u),new Response(null,{status:500})}async function s(u,d){let c=Ja(u,t);if(Wi.has(u.statusCode))return new Response(null,{status:u.statusCode,headers:c});u.errors&&(Object.values(u.errors).forEach(y=>{(!ie(y)||y.error)&&o(y)}),u.errors=gr(u.errors,e));let m={loaderData:u.loaderData,actionData:u.actionData,errors:Hn(u.errors,e)},f={basename:t.basename,future:t.future,routeDiscovery:t.routeDiscovery,ssr:t.ssr,isSpaMode:d},h={manifest:t.assets,routeModules:Cc(t.routes),staticHandlerContext:u,criticalCss:l,serverHandoffString:Un({...f,criticalCss:l}),serverHandoffStream:wa(m,a.signal,t.entry.module.streamTimeout,e),renderMeta:{},future:t.future,ssr:t.ssr,routeDiscovery:t.routeDiscovery,isSpaMode:d,serializeError:y=>Ii(y,e)},v=t.entry.module.default;try{return await v(a,u.statusCode,c,h,n)}catch(y){o(y);let R=y;if(ae(y))try{let S=await Ic(y);R=new Re(y.status,y.statusText,S)}catch{}u=yo(r.dataRoutes,u,R),u.errors&&(u.errors=gr(u.errors,e));let w={loaderData:u.loaderData,actionData:u.actionData,errors:Hn(u.errors,e)};h={...h,staticHandlerContext:u,serverHandoffString:Un(f),serverHandoffStream:wa(w,a.signal,t.entry.module.streamTimeout,e),renderMeta:{}};try{return await v(a,u.statusCode,c,h,n)}catch(S){return o(S),wr(S,e)}}}}async function Ac(e,t,r,a,n,o,i){try{let u=await r.queryRoute(n,{routeId:a,requestContext:o,generateMiddlewareResponse:t.future.v8_middleware?async d=>{try{let c=await d(n);return l(c)}catch(c){return s(c)}}:void 0});return l(u)}catch(u){return s(u)}function l(u){return ae(u)?u:typeof u=="string"?new Response(u):Response.json(u)}function s(u){if(ae(u))return u;if(ie(u))return i(u),$c(u,e);if(u instanceof Error&&u.message==="Expected a response from queryRoute"){let d=new Error("Expected a Response to be returned from resource route handler");return i(d),wr(d,e)}return i(u),wr(u,e)}}function $c(e,t){return Response.json(Ii(e.error||new Error("Unexpected Server Error"),t),{status:e.status,statusText:e.statusText})}function wr(e,t){let r="Unexpected Server Error";return t!=="production"&&(r+=`
|
|
44
|
+
|
|
45
|
+
${String(e)}`),new Response(r,{status:500,headers:{"Content-Type":"text/plain"}})}function Ic(e){let t=e.headers.get("Content-Type");return t&&/\bapplication\/json\b/.test(t)?e.body==null?null:e.json():e.text()}function Gr(e){return`__flash_${e}__`}var Vi=(e={},t="")=>{let r=new Map(Object.entries(e));return{get id(){return t},get data(){return Object.fromEntries(r)},has(a){return r.has(a)||r.has(Gr(a))},get(a){if(r.has(a))return r.get(a);let n=Gr(a);if(r.has(n)){let o=r.get(n);return r.delete(n),o}},set(a,n){r.set(a,n)},flash(a,n){r.set(Gr(a),n)},unset(a){r.delete(a)}}},jd=e=>e!=null&&typeof e.id=="string"&&typeof e.data<"u"&&typeof e.has=="function"&&typeof e.get=="function"&&typeof e.set=="function"&&typeof e.flash=="function"&&typeof e.unset=="function";function Hc({cookie:e,createData:t,readData:r,updateData:a,deleteData:n}){let o=$i(e)?e:Ai(e?.name||"__session",e);return Yi(o),{async getSession(i,l){let s=i&&await o.parse(i,l),u=s&&await r(s);return Vi(u||{},s||"")},async commitSession(i,l){let{id:s,data:u}=i,d=l?.maxAge!=null?new Date(Date.now()+l.maxAge*1e3):l?.expires!=null?l.expires:o.expires;return s?await a(s,u,d):s=await t(u,d),o.serialize(s,l)},async destroySession(i,l){return await n(i.id),o.serialize("",{...l,maxAge:void 0,expires:new Date(0)})}}}function Yi(e){Wt(e.isSigned,`The "${e.name}" cookie is not signed, but session cookies should be signed to prevent tampering on the client before they are sent back to the server. See https://reactrouter.com/explanation/sessions-and-cookies#signing-cookies for more information.`)}function Ud({cookie:e}={}){let t=$i(e)?e:Ai(e?.name||"__session",e);return Yi(t),{async getSession(r,a){return Vi(r&&await t.parse(r,a)||{})},async commitSession(r,a){let n=await t.serialize(r.data,a);if(n.length>4096)throw new Error("Cookie length will exceed browser maximum. Length: "+n.length);return n},async destroySession(r,a){return t.serialize("",{...a,maxAge:void 0,expires:new Date(0)})}}}function zd({cookie:e}={}){let t=new Map;return Hc({cookie:e,async createData(r,a){let n=Math.random().toString(36).substring(2,10);return t.set(n,{data:r,expires:a}),n},async readData(r){if(t.has(r)){let{data:a,expires:n}=t.get(r);if(!n||n>new Date)return a;n&&t.delete(r)}return null},async updateData(r,a,n){t.set(r,{data:a,expires:n})},async deleteData(r){t.delete(r)}})}function Bd(e,...t){let r=t[0],a=e.replace(/\/*\*?$/,"").replace(/\/:([\w-]+)(\?)?/g,(n,o,i)=>{const l=i===void 0,s=r?r[o]:void 0;if(l&&s===void 0)throw new Error(`Path '${e}' requires param '${o}' but it was not provided`);return s===void 0?"":"/"+s});if(e.endsWith("*")){const n=r?r["*"]:void 0;n!==void 0&&(a+="/"+n)}return a||"/"}const Ut=await le("react");var Ra=new TextEncoder,Wn="</body></html>";function Vn(e){let t=new TextDecoder,r,a=new Promise(s=>r=s),n=!1,o=[],i=null;function l(s){for(let u of o){let d=t.decode(u,{stream:!0});d.endsWith(Wn)&&(d=d.slice(0,-Wn.length)),s.enqueue(Ra.encode(d))}o.length=0,i=null}return new TransformStream({transform(s,u){o.push(s),!i&&(i=setTimeout(async()=>{l(u),n||(n=!0,jc(e,u).catch(d=>u.error(d)).then(r))},0))},async flush(s){await a,i&&(clearTimeout(i),l(s)),s.enqueue(Ra.encode("</body></html>"))}})}async function jc(e,t){let r=new TextDecoder("utf-8",{fatal:!0});const a=e.getReader();try{let o;for(;(o=await a.read())&&!o.done;){const i=o.value;try{Qr(JSON.stringify(r.decode(i,{stream:!0})),t)}catch{let s=JSON.stringify(btoa(String.fromCodePoint(...i)));Qr(`Uint8Array.from(atob(${s}), m => m.codePointAt(0))`,t)}}}finally{a.releaseLock()}let n=r.decode();n.length&&Qr(JSON.stringify(n),t)}function Qr(e,t){t.enqueue(Ra.encode(`<script>${Uc(`(self.__FLIGHT_DATA||=[]).push(${e})`)}<\/script>`))}function Uc(e){return e.replace(/<!--/g,"<\\!--").replace(/<\/(script)/gi,"</\\$1")}const ve=await le("react");var zc=class extends ve.Component{constructor(e){super(e),this.state={error:null,location:e.location}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,t){return t.location!==e.location?{error:null,location:e.location}:{error:t.error,location:t.location}}render(){return this.state.error?ve.createElement(Ji,{error:this.state.error,renderAppShell:!0}):this.props.children}};function Yn({renderAppShell:e,title:t,children:r}){return e?ve.createElement("html",{lang:"en"},ve.createElement("head",null,ve.createElement("meta",{charSet:"utf-8"}),ve.createElement("meta",{name:"viewport",content:"width=device-width,initial-scale=1,viewport-fit=cover"}),ve.createElement("title",null,t)),ve.createElement("body",null,ve.createElement("main",{style:{fontFamily:"system-ui, sans-serif",padding:"2rem"}},r))):r}function Ji({error:e,renderAppShell:t}){console.error(e);let r=ve.createElement("script",{dangerouslySetInnerHTML:{__html:`
|
|
46
|
+
console.log(
|
|
47
|
+
"💿 Hey developer 👋. You can provide a way better UX than this when your app throws errors. Check out https://reactrouter.com/how-to/error-boundary for more information."
|
|
48
|
+
);
|
|
49
|
+
`}});if(ie(e))return ve.createElement(Yn,{renderAppShell:t,title:"Unhandled Thrown Response!"},ve.createElement("h1",{style:{fontSize:"24px"}},e.status," ",e.statusText),r);let a;if(e instanceof Error)a=e;else{let n=e==null?"Unknown Error":typeof e=="object"&&"toString"in e?e.toString():JSON.stringify(e);a=new Error(n)}return ve.createElement(Yn,{renderAppShell:t,title:"Application Error!"},ve.createElement("h1",{style:{fontSize:"24px"}},"Application Error"),ve.createElement("pre",{style:{padding:"2rem",background:"hsla(10, 50%, 50%, 0.1)",color:"red",overflow:"auto"}},a.stack),r)}function Wd({hasRootLayout:e}){let t=Lr();if(e===void 0)throw new Error("Missing 'hasRootLayout' prop");return ve.createElement(Ji,{renderAppShell:!e,error:t})}function Bc(e){const t={};for(const r of e.matches)Wc(t,r);return t}function Wc(e,t){t=Array.isArray(t)?t:[t];for(const r of t)e[r.id]={links:r.links,meta:r.meta,default:Vc}}var Vc=()=>null,Yc="use",Jn=Ut[Yc];function Jc(e){if(Jn)return Jn(e);throw new Error("React Router v7 requires React 19+ for RSC features.")}async function Vd({request:e,fetchServer:t,createFromReadableStream:r,renderHTML:a,hydrate:n=!0}){const o=new URL(e.url),l=Kc(o)||Xc(o)||e.headers.has("rsc-action-id"),s=await t(e);if(l||s.headers.get("React-Router-Resource")==="true")return s;if(!s.body)throw new Error("Missing body in server response");const u=s.clone();let d=null;n&&(d=s.clone());const c=s.body;let m,f=[];const h=()=>m?new ReadableStream({start(R){m.forEach(w=>R.enqueue(w)),f.push(R)}}):(m=[],c.pipeThrough(new TransformStream({transform(R,w){m.push(R),w.enqueue(R),f.forEach(S=>S.enqueue(R))},flush(){f.forEach(R=>R.close()),f=[]}})));let v=null;const y=()=>{const R=Promise.resolve(r(h()));return Object.defineProperties(R,{_deepestRenderedBoundaryId:{get(){return v},set(w){v=w}},formState:{get(){return R.then(w=>w.type==="render"?w.formState:void 0)}}})};try{if(!u.body)throw new Error("Failed to clone server response");const R=await r(u.body);if(s.status===$a&&R.type==="redirect"){const C=new Headers(s.headers);return C.delete("Content-Encoding"),C.delete("Content-Length"),C.delete("Content-Type"),C.delete("X-Remix-Response"),C.set("Location",R.location),new Response(d?.body||"",{headers:C,status:R.status,statusText:s.statusText})}const w=await a(y),S=new Headers(s.headers);if(S.set("Content-Type","text/html; charset=utf-8"),!n)return new Response(w,{status:s.status,headers:S});if(!d?.body)throw new Error("Failed to clone server response");const P=w.pipeThrough(Vn(d.body));return new Response(P,{status:s.status,headers:S})}catch(R){if(R instanceof Response)return R;try{const w=ie(R)?R.status:500,S=await a(()=>{const g=Promise.resolve(r(h())).then(O=>Object.assign(O,{status:w,errors:v?{[v]:R}:{}}));return Object.defineProperties(g,{_deepestRenderedBoundaryId:{get(){return v},set(O){v=O}},formState:{get(){return g.then(O=>O.type==="render"?O.formState:void 0)}}})}),P=new Headers(s.headers);if(P.set("Content-Type","text/html"),!n)return new Response(S,{status:w,headers:P});if(!d?.body)throw new Error("Failed to clone server response");const C=S.pipeThrough(Vn(d.body));return new Response(C,{status:w,headers:P})}catch{}throw R}}function Yd({getPayload:e}){const t=e(),r=Jc(t);if(r.type==="redirect")throw new Response(null,{status:r.status,headers:{Location:r.location}});if(r.type!=="render")return null;let a={...r.loaderData};for(const l of r.matches)Mr(l.id,l.clientLoader,l.hasLoader,!1)&&(l.hydrateFallbackElement||!l.hasLoader)&&delete a[l.id];const n={get _deepestRenderedBoundaryId(){return t._deepestRenderedBoundaryId??null},set _deepestRenderedBoundaryId(l){t._deepestRenderedBoundaryId=l},actionData:r.actionData,actionHeaders:{},basename:r.basename,errors:r.errors,loaderData:a,loaderHeaders:{},location:r.location,statusCode:200,matches:r.matches.map(l=>({params:l.params,pathname:l.pathname,pathnameBase:l.pathnameBase,route:{id:l.id,action:l.hasAction||!!l.clientAction,handle:l.handle,hasErrorBoundary:l.hasErrorBoundary,loader:l.hasLoader||!!l.clientLoader,index:l.index,path:l.path,shouldRevalidate:l.shouldRevalidate}}))},o=xi(r.matches.reduceRight((l,s)=>{const u={id:s.id,action:s.hasAction||!!s.clientAction,element:s.element,errorElement:s.errorElement,handle:s.handle,hasErrorBoundary:!!s.errorElement,hydrateFallbackElement:s.hydrateFallbackElement,index:s.index,loader:s.hasLoader||!!s.clientLoader,path:s.path,shouldRevalidate:s.shouldRevalidate};return l.length>0&&(u.children=l),[u]},[]),n),i={future:{v8_middleware:!1,unstable_subResourceIntegrity:!1},isSpaMode:!1,ssr:!0,criticalCss:"",manifest:{routes:{},version:"1",url:"",entry:{module:"",imports:[]}},routeDiscovery:{mode:"lazy",manifestPath:"/__manifest"},routeModules:Bc(r)};return Ut.createElement(ko.Provider,{value:!0},Ut.createElement(zc,{location:r.location},Ut.createElement(it.Provider,{value:i},Ut.createElement(Si,{context:n,router:o,hydrate:!1,nonce:r.nonce}))))}function Kc(e){return e.pathname.endsWith(".rsc")}function Xc(e){return e.pathname.endsWith(".manifest")}function Gc(e){if(!e)return null;let t=Object.entries(e),r={};for(let[a,n]of t)if(n&&n.__type==="RouteErrorResponse")r[a]=new Re(n.status,n.statusText,n.data,n.internal===!0);else if(n&&n.__type==="Error"){if(n.__subType){let o=window[n.__subType];if(typeof o=="function")try{let i=new o(n.message);i.stack=n.stack,r[a]=i}catch{}}if(r[a]==null){let o=new Error(n.message);o.stack=n.stack,r[a]=o}}else r[a]=n;return r}function Qc({state:e,routes:t,getRouteInfo:r,location:a,basename:n,isSpaMode:o}){let i={...e,loaderData:{...e.loaderData}},l=Ce(t,a,n);if(l)for(let s of l){let u=s.route.id,d=r(u);Mr(u,d.clientLoader,d.hasLoader,o)&&(d.hasHydrateFallback||!d.hasLoader)?delete i.loaderData[u]:d.hasLoader||(i.loaderData[u]=null)}return i}const Zc=await le("react"),qc=await le("react-dom");function ed(e){return Zc.createElement(Ao,{flushSync:qc.flushSync,...e})}const Se=await le("react");var F=null,It=null;function td(){if(!F&&window.__reactRouterContext&&window.__reactRouterManifest&&window.__reactRouterRouteModules){if(window.__reactRouterManifest.sri===!0){const e=document.querySelector("script[rr-importmap]");if(e?.textContent)try{window.__reactRouterManifest.sri=JSON.parse(e.textContent).integrity}catch(t){console.error("Failed to parse import map",t)}}F={context:window.__reactRouterContext,manifest:window.__reactRouterManifest,routeModules:window.__reactRouterRouteModules,stateDecodingPromise:void 0,router:void 0,routerInitialized:!1}}}function rd({getContext:e,unstable_instrumentations:t}){if(td(),!F)throw new Error("You must be using the SSR features of React Router in order to skip passing a `router` prop to `<RouterProvider>`");let r=F;if(!F.stateDecodingPromise){let i=F.context.stream;I(i,"No stream found for single fetch decoding"),F.context.stream=void 0,F.stateDecodingPromise=Ia(i,window).then(l=>{F.context.state=l.value,r.stateDecodingPromise.value=!0}).catch(l=>{r.stateDecodingPromise.error=l})}if(F.stateDecodingPromise.error)throw F.stateDecodingPromise.error;if(!F.stateDecodingPromise.value)throw F.stateDecodingPromise;let a=Tr(F.manifest.routes,F.routeModules,F.context.state,F.context.ssr,F.context.isSpaMode),n;if(F.context.isSpaMode){let{loaderData:i}=F.context.state;F.manifest.routes.root?.hasLoader&&i&&"root"in i&&(n={loaderData:{root:i.root}})}else n=Qc({state:F.context.state,routes:a,getRouteInfo:i=>({clientLoader:F.routeModules[i]?.clientLoader,hasLoader:F.manifest.routes[i]?.hasLoader===!0,hasHydrateFallback:F.routeModules[i]?.HydrateFallback!=null}),location:window.location,basename:window.__reactRouterContext?.basename,isSpaMode:F.context.isSpaMode}),n&&n.errors&&(n.errors=Gc(n.errors));let o=Cr({routes:a,history:Ea(),basename:F.context.basename,getContext:e,hydrationData:n,hydrationRouteProperties:_r,unstable_instrumentations:t,mapRouteProperties:kt,future:{middleware:F.context.future.v8_middleware},dataStrategy:au(()=>o,F.manifest,F.routeModules,F.context.ssr,F.context.basename),patchRoutesOnNavigation:Du(F.manifest,F.routeModules,F.context.ssr,F.context.routeDiscovery,F.context.isSpaMode,F.context.basename)});return F.router=o,o.state.initialized&&(F.routerInitialized=!0,o.initialize()),o.createRoutesForHMR=Eu,window.__reactRouterDataRouter=o,o}function Jd(e){It||(It=rd({getContext:e.getContext,unstable_instrumentations:e.unstable_instrumentations}));let[t,r]=Se.useState(void 0);Se.useEffect(()=>{},[]),Se.useEffect(()=>{},[t]);let[a,n]=Se.useState(It.state.location);return Se.useLayoutEffect(()=>{F&&F.router&&!F.routerInitialized&&(F.routerInitialized=!0,F.router.initialize())},[]),Se.useLayoutEffect(()=>{if(F&&F.router)return F.router.subscribe(o=>{o.location!==a&&n(o.location)})},[a]),I(F,"ssrInfo unavailable for HydratedRouter"),Lu(It,F.manifest,F.routeModules,F.context.ssr,F.context.routeDiscovery,F.context.isSpaMode),Se.createElement(Se.Fragment,null,Se.createElement(it.Provider,{value:{manifest:F.manifest,routeModules:F.routeModules,future:F.context.future,criticalCss:t,ssr:F.context.ssr,isSpaMode:F.context.isSpaMode,routeDiscovery:F.context.routeDiscovery}},Se.createElement(mi,{location:a},Se.createElement(ed,{router:It,unstable_onError:e.unstable_onError}))),Se.createElement(Se.Fragment,null))}await le("react");await le("react-dom");export{vd as Await,Dd as BrowserRouter,Ri as Form,Ld as HashRouter,Jd as HydratedRouter,pt as IDLE_BLOCKER,ba as IDLE_FETCHER,lr as IDLE_NAVIGATION,wi as Link,Sd as Links,md as MemoryRouter,Cd as Meta,Uu as NavLink,pd as Navigate,ml as NavigationType,ks as Outlet,hi as PrefetchPageLinks,Ts as Route,gt as Router,Ve as RouterContextProvider,ed as RouterProvider,yd as Routes,Au as Scripts,zu as ScrollRestoration,Ad as ServerRouter,Fd as StaticRouter,Si as StaticRouterProvider,id as UNSAFE_AwaitContextProvider,Je as UNSAFE_DataRouterContext,ot as UNSAFE_DataRouterStateContext,Re as UNSAFE_ErrorResponseImpl,Dr as UNSAFE_FetchersContext,it as UNSAFE_FrameworkContext,Lt as UNSAFE_LocationContext,xe as UNSAFE_NavigationContext,Wd as UNSAFE_RSCDefaultRootErrorBoundary,mi as UNSAFE_RemixErrorBoundary,Pe as UNSAFE_RouteContext,xc as UNSAFE_ServerMode,nt as UNSAFE_SingleFetchRedirectSymbol,Pr as UNSAFE_ViewTransitionContext,Rd as UNSAFE_WithComponentProps,bd as UNSAFE_WithErrorBoundaryProps,Ed as UNSAFE_WithHydrateFallbackProps,Ea as UNSAFE_createBrowserHistory,Tr as UNSAFE_createClientRoutes,Eu as UNSAFE_createClientRoutesWithHMRRevalidationOptOut,Cr as UNSAFE_createRouter,Ia as UNSAFE_decodeViaTurboStream,Gc as UNSAFE_deserializeErrors,Qc as UNSAFE_getHydrationData,Du as UNSAFE_getPatchRoutesOnNavigationFunction,au as UNSAFE_getTurboStreamSingleFetchDataStrategy,_r as UNSAFE_hydrationRouteProperties,I as UNSAFE_invariant,kt as UNSAFE_mapRouteProperties,Mr as UNSAFE_shouldHydrateRouteLoader,Lu as UNSAFE_useFogOFWarDiscovery,Ju as UNSAFE_useScrollRestoration,Fs as UNSAFE_withComponentProps,As as UNSAFE_withErrorBoundaryProps,Ns as UNSAFE_withHydrateFallbackProps,xd as createBrowserRouter,nd as createContext,Ai as createCookie,Ud as createCookieSessionStorage,Pd as createHashRouter,Ps as createMemoryRouter,zd as createMemorySessionStorage,we as createPath,Hd as createRequestHandler,mr as createRoutesFromChildren,gd as createRoutesFromElements,$d as createRoutesStub,na as createSearchParams,Vi as createSession,Hc as createSessionStorage,Nd as createStaticHandler,xi as createStaticRouter,Il as data,od as generatePath,Bd as href,$i as isCookie,ie as isRouteErrorResponse,jd as isSession,zt as matchPath,Ce as matchRoutes,Me as parsePath,Sr as redirect,Hl as redirectDocument,wd as renderMatches,jl as replace,Ol as resolvePath,ju as unstable_HistoryRouter,Yd as unstable_RSCStaticRouter,Vd as unstable_routeRSCServerRequest,Id as unstable_setDevServerHooks,Od as unstable_usePrompt,hd as unstable_useRoute,Fa as useActionData,fd as useAsyncError,bs as useAsyncValue,Md as useBeforeUnload,Cs as useBlocker,kd as useFetcher,Td as useFetchers,Yu as useFormAction,ds as useHref,vt as useInRouterContext,Bu as useLinkClickHandler,Oa as useLoaderData,De as useLocation,sd as useMatch,Ma as useMatches,Da as useNavigate,Es as useNavigation,ld as useNavigationType,hs as useOutlet,ud as useOutletContext,La as useParams,Jt as useResolvedPath,cd as useRevalidator,Lr as useRouteError,dd as useRouteLoaderData,ms as useRoutes,_d as useSearchParams,bi as useSubmit,Xu as useViewTransitionState};
|