From ed45396862f976c502145daa445d4735199568b2 Mon Sep 17 00:00:00 2001 From: Jordan Date: Tue, 21 Jan 2025 21:47:31 +1300 Subject: [PATCH] Updates --- assets/{index-C5YetHr4.js => index-DxHu7VXM.js} | 2 +- index.html | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) rename assets/{index-C5YetHr4.js => index-DxHu7VXM.js} (93%) diff --git a/assets/index-C5YetHr4.js b/assets/index-DxHu7VXM.js similarity index 93% rename from assets/index-C5YetHr4.js rename to assets/index-DxHu7VXM.js index 7902995..1d7b943 100644 --- a/assets/index-C5YetHr4.js +++ b/assets/index-DxHu7VXM.js @@ -193,7 +193,7 @@ To suppress this warning, you need to explicitly provide the \`palette.${e}Chann * @license MIT */var NN="popstate";function Hne(t={}){function e(r,i){let{pathname:o,search:s,hash:a}=r.location;return EI("",{pathname:o,search:s,hash:a},i.state&&i.state.usr||null,i.state&&i.state.key||"default")}function n(r,i){return typeof i=="string"?i:Qx(i)}return Vne(e,n,null,t)}function Fr(t,e){if(t===!1||t===null||typeof t>"u")throw new Error(e)}function tc(t,e){if(!t){typeof console<"u"&&console.warn(e);try{throw new Error(e)}catch{}}}function Gne(){return Math.random().toString(36).substring(2,10)}function FN(t,e){return{usr:t.state,key:t.key,idx:e}}function EI(t,e,n=null,r){return{pathname:typeof t=="string"?t:t.pathname,search:"",hash:"",...typeof e=="string"?Tv(e):e,state:n,key:e&&e.key||r||Gne()}}function Qx({pathname:t="/",search:e="",hash:n=""}){return e&&e!=="?"&&(t+=e.charAt(0)==="?"?e:"?"+e),n&&n!=="#"&&(t+=n.charAt(0)==="#"?n:"#"+n),t}function Tv(t){let e={};if(t){let n=t.indexOf("#");n>=0&&(e.hash=t.substring(n),t=t.substring(0,n));let r=t.indexOf("?");r>=0&&(e.search=t.substring(r),t=t.substring(0,r)),t&&(e.pathname=t)}return e}function Vne(t,e,n,r={}){let{window:i=document.defaultView,v5Compat:o=!1}=r,s=i.history,a="POP",l=null,c=u();c==null&&(c=0,s.replaceState({...s.state,idx:c},""));function u(){return(s.state||{idx:null}).idx}function d(){a="POP";let x=u(),g=x==null?null:x-c;c=x,l&&l({action:a,location:y.location,delta:g})}function f(x,g){a="PUSH";let b=EI(y.location,x,g);c=u()+1;let _=FN(b,c),C=y.createHref(b);try{s.pushState(_,"",C)}catch(T){if(T instanceof DOMException&&T.name==="DataCloneError")throw T;i.location.assign(C)}o&&l&&l({action:a,location:y.location,delta:1})}function p(x,g){a="REPLACE";let b=EI(y.location,x,g);c=u();let _=FN(b,c),C=y.createHref(b);s.replaceState(_,"",C),o&&l&&l({action:a,location:y.location,delta:0})}function v(x){let g=i.location.origin!=="null"?i.location.origin:i.location.href,b=typeof x=="string"?x:Qx(x);return b=b.replace(/ $/,"%20"),Fr(g,`No window.location.(origin|href) available to create URL for href: ${b}`),new URL(b,g)}let y={get action(){return a},get location(){return t(i,s)},listen(x){if(l)throw new Error("A history only accepts one active listener");return i.addEventListener(NN,d),l=x,()=>{i.removeEventListener(NN,d),l=null}},createHref(x){return e(i,x)},createURL:v,encodeLocation(x){let g=v(x);return{pathname:g.pathname,search:g.search,hash:g.hash}},push:f,replace:p,go(x){return s.go(x)}};return y}function UH(t,e,n="/"){return Wne(t,e,n,!1)}function Wne(t,e,n,r){let i=typeof e=="string"?Tv(e):e,o=zd(i.pathname||"/",n);if(o==null)return null;let s=zH(t);jne(s);let a=null;for(let l=0;a==null&&l{let l={relativePath:a===void 0?o.path||"":a,caseSensitive:o.caseSensitive===!0,childrenIndex:s,route:o};l.relativePath.startsWith("/")&&(Fr(l.relativePath.startsWith(r),`Absolute route path "${l.relativePath}" nested under path "${r}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),l.relativePath=l.relativePath.slice(r.length));let c=iu([r,l.relativePath]),u=n.concat(l);o.children&&o.children.length>0&&(Fr(o.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${c}".`),zH(o.children,e,u,c)),!(o.path==null&&!o.index)&&e.push({path:c,score:Zne(c,o.index),routesMeta:u})};return t.forEach((o,s)=>{var a;if(o.path===""||!((a=o.path)!=null&&a.includes("?")))i(o,s);else for(let l of $H(o.path))i(o,s,l)}),e}function $H(t){let e=t.split("/");if(e.length===0)return[];let[n,...r]=e,i=n.endsWith("?"),o=n.replace(/\?$/,"");if(r.length===0)return i?[o,""]:[o];let s=$H(r.join("/")),a=[];return a.push(...s.map(l=>l===""?o:[o,l].join("/"))),i&&a.push(...s),a.map(l=>t.startsWith("/")&&l===""?"/":l)}function jne(t){t.sort((e,n)=>e.score!==n.score?n.score-e.score:ere(e.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}var Xne=/^:[\w-]+$/,Kne=3,Yne=2,Jne=1,qne=10,Qne=-2,UN=t=>t==="*";function Zne(t,e){let n=t.split("/"),r=n.length;return n.some(UN)&&(r+=Qne),e&&(r+=Yne),n.filter(i=>!UN(i)).reduce((i,o)=>i+(Xne.test(o)?Kne:o===""?Jne:qne),r)}function ere(t,e){return t.length===e.length&&t.slice(0,-1).every((r,i)=>r===e[i])?t[t.length-1]-e[e.length-1]:0}function tre(t,e,n=!1){let{routesMeta:r}=t,i={},o="/",s=[];for(let a=0;a{if(u==="*"){let v=a[f]||"";s=o.slice(0,o.length-v.length).replace(/(.)\/+$/,"$1")}const p=a[f];return d&&!p?c[u]=void 0:c[u]=(p||"").replace(/%2F/g,"/"),c},{}),pathname:o,pathnameBase:s,pattern:t}}function nre(t,e=!1,n=!0){tc(t==="*"||!t.endsWith("*")||t.endsWith("/*"),`Route path "${t}" will be treated as if it were "${t.replace(/\*$/,"/*")}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${t.replace(/\*$/,"/*")}".`);let r=[],i="^"+t.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(s,a,l)=>(r.push({paramName:a,isOptional:l!=null}),l?"/?([^\\/]+)?":"/([^\\/]+)"));return t.endsWith("*")?(r.push({paramName:"*"}),i+=t==="*"||t==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?i+="\\/*$":t!==""&&t!=="/"&&(i+="(?:(?=\\/|$))"),[new RegExp(i,e?void 0:"i"),r]}function rre(t){try{return t.split("/").map(e=>decodeURIComponent(e).replace(/\//g,"%2F")).join("/")}catch(e){return tc(!1,`The URL path "${t}" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (${e}).`),t}}function zd(t,e){if(e==="/")return t;if(!t.toLowerCase().startsWith(e.toLowerCase()))return null;let n=e.endsWith("/")?e.length-1:e.length,r=t.charAt(n);return r&&r!=="/"?null:t.slice(n)||"/"}function ire(t,e="/"){let{pathname:n,search:r="",hash:i=""}=typeof t=="string"?Tv(t):t;return{pathname:n?n.startsWith("/")?n:ore(n,e):e,search:lre(r),hash:cre(i)}}function ore(t,e){let n=e.replace(/\/+$/,"").split("/");return t.split("/").forEach(i=>{i===".."?n.length>1&&n.pop():i!=="."&&n.push(i)}),n.length>1?n.join("/"):"/"}function LT(t,e,n,r){return`Cannot include a '${t}' character in a manually specified \`to.${e}\` field [${JSON.stringify(r)}]. Please separate it out to the \`to.${n}\` field. Alternatively you may provide the full path as a string in and the router will parse it for you.`}function sre(t){return t.filter((e,n)=>n===0||e.route.path&&e.route.path.length>0)}function HH(t){let e=sre(t);return e.map((n,r)=>r===e.length-1?n.pathname:n.pathnameBase)}function GH(t,e,n,r=!1){let i;typeof t=="string"?i=Tv(t):(i={...t},Fr(!i.pathname||!i.pathname.includes("?"),LT("?","pathname","search",i)),Fr(!i.pathname||!i.pathname.includes("#"),LT("#","pathname","hash",i)),Fr(!i.search||!i.search.includes("#"),LT("#","search","hash",i)));let o=t===""||i.pathname==="",s=o?"/":i.pathname,a;if(s==null)a=n;else{let d=e.length-1;if(!r&&s.startsWith("..")){let f=s.split("/");for(;f[0]==="..";)f.shift(),d-=1;i.pathname=f.join("/")}a=d>=0?e[d]:"/"}let l=ire(i,a),c=s&&s!=="/"&&s.endsWith("/"),u=(o||s===".")&&n.endsWith("/");return!l.pathname.endsWith("/")&&(c||u)&&(l.pathname+="/"),l}var iu=t=>t.join("/").replace(/\/\/+/g,"/"),are=t=>t.replace(/\/+$/,"").replace(/^\/*/,"/"),lre=t=>!t||t==="?"?"":t.startsWith("?")?t:"?"+t,cre=t=>!t||t==="#"?"":t.startsWith("#")?t:"#"+t;function ure(t){return t!=null&&typeof t.status=="number"&&typeof t.statusText=="string"&&typeof t.internal=="boolean"&&"data"in t}var VH=["POST","PUT","PATCH","DELETE"];new Set(VH);var dre=["GET",...VH];new Set(dre);var Rv=P.createContext(null);Rv.displayName="DataRouter";var uw=P.createContext(null);uw.displayName="DataRouterState";var WH=P.createContext({isTransitioning:!1});WH.displayName="ViewTransition";var fre=P.createContext(new Map);fre.displayName="Fetchers";var pre=P.createContext(null);pre.displayName="Await";var oc=P.createContext(null);oc.displayName="Navigation";var Lb=P.createContext(null);Lb.displayName="Location";var Su=P.createContext({outlet:null,matches:[],isDataRoute:!1});Su.displayName="Route";var gL=P.createContext(null);gL.displayName="RouteError";function hre(t,{relative:e}={}){Fr(Db(),"useHref() may be used only in the context of a component.");let{basename:n,navigator:r}=P.useContext(oc),{hash:i,pathname:o,search:s}=kb(t,{relative:e}),a=o;return n!=="/"&&(a=o==="/"?n:iu([n,o])),r.createHref({pathname:a,search:s,hash:i})}function Db(){return P.useContext(Lb)!=null}function mh(){return Fr(Db(),"useLocation() may be used only in the context of a component."),P.useContext(Lb).location}var jH="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function XH(t){P.useContext(oc).static||P.useLayoutEffect(t)}function mre(){let{isDataRoute:t}=P.useContext(Su);return t?Tre():gre()}function gre(){Fr(Db(),"useNavigate() may be used only in the context of a component.");let t=P.useContext(Rv),{basename:e,navigator:n}=P.useContext(oc),{matches:r}=P.useContext(Su),{pathname:i}=mh(),o=JSON.stringify(HH(r)),s=P.useRef(!1);return XH(()=>{s.current=!0}),P.useCallback((l,c={})=>{if(tc(s.current,jH),!s.current)return;if(typeof l=="number"){n.go(l);return}let u=GH(l,JSON.parse(o),i,c.relative==="path");t==null&&e!=="/"&&(u.pathname=u.pathname==="/"?e:iu([e,u.pathname])),(c.replace?n.replace:n.push)(u,c.state,c)},[e,n,o,i,t])}P.createContext(null);function kb(t,{relative:e}={}){let{matches:n}=P.useContext(Su),{pathname:r}=mh(),i=JSON.stringify(HH(n));return P.useMemo(()=>GH(t,JSON.parse(i),r,e==="path"),[t,i,r,e])}function vre(t,e){return KH(t,e)}function KH(t,e,n,r){var g;Fr(Db(),"useRoutes() may be used only in the context of a component.");let{navigator:i}=P.useContext(oc),{matches:o}=P.useContext(Su),s=o[o.length-1],a=s?s.params:{},l=s?s.pathname:"/",c=s?s.pathnameBase:"/",u=s&&s.route;{let b=u&&u.path||"";YH(l,!u||b.endsWith("*")||b.endsWith("*?"),`You rendered descendant (or called \`useRoutes()\`) at "${l}" (under ) but the parent route path has no trailing "*". This means if you navigate deeper, the parent won't match anymore and therefore the child routes will never render. -Please change the parent to .`)}let d=mh(),f;if(e){let b=typeof e=="string"?Tv(e):e;Fr(c==="/"||((g=b.pathname)==null?void 0:g.startsWith(c)),`When overriding the location using \`\` or \`useRoutes(routes, location)\`, the location pathname must begin with the portion of the URL pathname that was matched by all parent routes. The current pathname base is "${c}" but pathname "${b.pathname}" was given in the \`location\` prop.`),f=b}else f=d;let p=f.pathname||"/",v=p;if(c!=="/"){let b=c.replace(/^\//,"").split("/");v="/"+p.replace(/^\//,"").split("/").slice(b.length).join("/")}let y=UH(t,{pathname:v});tc(u||y!=null,`No routes matched location "${f.pathname}${f.search}${f.hash}" `),tc(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 with a null value by default resulting in an "empty" page.`);let x=Sre(y&&y.map(b=>Object.assign({},b,{params:Object.assign({},a,b.params),pathname:iu([c,i.encodeLocation?i.encodeLocation(b.pathname).pathname:b.pathname]),pathnameBase:b.pathnameBase==="/"?c:iu([c,i.encodeLocation?i.encodeLocation(b.pathnameBase).pathname:b.pathnameBase])})),o,n,r);return e&&x?P.createElement(Lb.Provider,{value:{location:{pathname:"/",search:"",hash:"",state:null,key:"default",...f},navigationType:"POP"}},x):x}function yre(){let t=Ere(),e=ure(t)?`${t.status} ${t.statusText}`:t instanceof Error?t.message:JSON.stringify(t),n=t instanceof Error?t.stack:null,r="rgba(200,200,200, 0.5)",i={padding:"0.5rem",backgroundColor:r},o={padding:"2px 4px",backgroundColor:r},s=null;return console.error("Error handled by React Router default ErrorBoundary:",t),s=P.createElement(P.Fragment,null,P.createElement("p",null,"💿 Hey developer 👋"),P.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",P.createElement("code",{style:o},"ErrorBoundary")," or"," ",P.createElement("code",{style:o},"errorElement")," prop on your route.")),P.createElement(P.Fragment,null,P.createElement("h2",null,"Unexpected Application Error!"),P.createElement("h3",{style:{fontStyle:"italic"}},e),n?P.createElement("pre",{style:i},n):null,s)}var xre=P.createElement(yre,null),bre=class extends P.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,e){return e.location!==t.location||e.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:e.error,location:e.location,revalidation:t.revalidation||e.revalidation}}componentDidCatch(t,e){console.error("React Router caught the following error during render",t,e)}render(){return this.state.error!==void 0?P.createElement(Su.Provider,{value:this.props.routeContext},P.createElement(gL.Provider,{value:this.state.error,children:this.props.component})):this.props.children}};function _re({routeContext:t,match:e,children:n}){let r=P.useContext(Rv);return r&&r.static&&r.staticContext&&(e.route.errorElement||e.route.ErrorBoundary)&&(r.staticContext._deepestRenderedBoundaryId=e.route.id),P.createElement(Su.Provider,{value:t},n)}function Sre(t,e=[],n=null,r=null){if(t==null){if(!n)return null;if(n.errors)t=n.matches;else if(e.length===0&&!n.initialized&&n.matches.length>0)t=n.matches;else return null}let i=t,o=n==null?void 0:n.errors;if(o!=null){let l=i.findIndex(c=>c.route.id&&(o==null?void 0:o[c.route.id])!==void 0);Fr(l>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(o).join(",")}`),i=i.slice(0,Math.min(i.length,l+1))}let s=!1,a=-1;if(n)for(let l=0;l=0?i=i.slice(0,a+1):i=[i[0]];break}}}return i.reduceRight((l,c,u)=>{let d,f=!1,p=null,v=null;n&&(d=o&&c.route.id?o[c.route.id]:void 0,p=c.route.errorElement||xre,s&&(a<0&&u===0?(YH("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),f=!0,v=null):a===u&&(f=!0,v=c.route.hydrateFallbackElement||null)));let y=e.concat(i.slice(0,u+1)),x=()=>{let g;return d?g=p:f?g=v:c.route.Component?g=P.createElement(c.route.Component,null):c.route.element?g=c.route.element:g=l,P.createElement(_re,{match:c,routeContext:{outlet:l,matches:y,isDataRoute:n!=null},children:g})};return n&&(c.route.ErrorBoundary||c.route.errorElement||u===0)?P.createElement(bre,{location:n.location,revalidation:n.revalidation,component:p,error:d,children:x(),routeContext:{outlet:null,matches:y,isDataRoute:!0}}):x()},null)}function vL(t){return`${t} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function Cre(t){let e=P.useContext(Rv);return Fr(e,vL(t)),e}function Are(t){let e=P.useContext(uw);return Fr(e,vL(t)),e}function Mre(t){let e=P.useContext(Su);return Fr(e,vL(t)),e}function yL(t){let e=Mre(t),n=e.matches[e.matches.length-1];return Fr(n.route.id,`${t} can only be used on routes that contain a unique "id"`),n.route.id}function wre(){return yL("useRouteId")}function Ere(){var r;let t=P.useContext(gL),e=Are("useRouteError"),n=yL("useRouteError");return t!==void 0?t:(r=e.errors)==null?void 0:r[n]}function Tre(){let{router:t}=Cre("useNavigate"),e=yL("useNavigate"),n=P.useRef(!1);return XH(()=>{n.current=!0}),P.useCallback(async(i,o={})=>{tc(n.current,jH),n.current&&(typeof i=="number"?t.navigate(i):await t.navigate(i,{fromRouteId:e,...o}))},[t,e])}var zN={};function YH(t,e,n){!e&&!zN[t]&&(zN[t]=!0,tc(!1,n))}P.memo(Rre);function Rre({routes:t,future:e,state:n}){return KH(t,void 0,n,e)}function tp(t){Fr(!1,"A is only ever to be used as the child of element, never rendered directly. Please wrap your in a .")}function Pre({basename:t="/",children:e=null,location:n,navigationType:r="POP",navigator:i,static:o=!1}){Fr(!Db(),"You cannot render a inside another . You should never have more than one in your app.");let s=t.replace(/^\/*/,"/"),a=P.useMemo(()=>({basename:s,navigator:i,static:o,future:{}}),[s,i,o]);typeof n=="string"&&(n=Tv(n));let{pathname:l="/",search:c="",hash:u="",state:d=null,key:f="default"}=n,p=P.useMemo(()=>{let v=zd(l,s);return v==null?null:{location:{pathname:v,search:c,hash:u,state:d,key:f},navigationType:r}},[s,l,c,u,d,f,r]);return tc(p!=null,` is not able to match the URL "${l}${c}${u}" because it does not start with the basename, so the won't render anything.`),p==null?null:P.createElement(oc.Provider,{value:a},P.createElement(Lb.Provider,{children:e,value:p}))}function Ire({children:t,location:e}){return vre(TI(t),e)}function TI(t,e=[]){let n=[];return P.Children.forEach(t,(r,i)=>{if(!P.isValidElement(r))return;let o=[...e,i];if(r.type===P.Fragment){n.push.apply(n,TI(r.props.children,o));return}Fr(r.type===tp,`[${typeof r.type=="string"?r.type:r.type.name}] is not a component. All component children of must be a or `),Fr(!r.props.index||!r.props.children,"An index route cannot have child routes.");let s={id:r.props.id||o.join("-"),caseSensitive:r.props.caseSensitive,element:r.props.element,Component:r.props.Component,index:r.props.index,path:r.props.path,loader:r.props.loader,action:r.props.action,hydrateFallbackElement:r.props.hydrateFallbackElement,HydrateFallback:r.props.HydrateFallback,errorElement:r.props.errorElement,ErrorBoundary:r.props.ErrorBoundary,hasErrorBoundary:r.props.hasErrorBoundary===!0||r.props.ErrorBoundary!=null||r.props.errorElement!=null,shouldRevalidate:r.props.shouldRevalidate,handle:r.props.handle,lazy:r.props.lazy};r.props.children&&(s.children=TI(r.props.children,o)),n.push(s)}),n}var pC="get",hC="application/x-www-form-urlencoded";function dw(t){return t!=null&&typeof t.tagName=="string"}function Bre(t){return dw(t)&&t.tagName.toLowerCase()==="button"}function Lre(t){return dw(t)&&t.tagName.toLowerCase()==="form"}function Dre(t){return dw(t)&&t.tagName.toLowerCase()==="input"}function kre(t){return!!(t.metaKey||t.altKey||t.ctrlKey||t.shiftKey)}function Ore(t,e){return t.button===0&&(!e||e==="_self")&&!kre(t)}var P1=null;function Nre(){if(P1===null)try{new FormData(document.createElement("form"),0),P1=!1}catch{P1=!0}return P1}var Fre=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function DT(t){return t!=null&&!Fre.has(t)?(tc(!1,`"${t}" is not a valid \`encType\` for \`
\`/\`\` and will default to "${hC}"`),null):t}function Ure(t,e){let n,r,i,o,s;if(Lre(t)){let a=t.getAttribute("action");r=a?zd(a,e):null,n=t.getAttribute("method")||pC,i=DT(t.getAttribute("enctype"))||hC,o=new FormData(t)}else if(Bre(t)||Dre(t)&&(t.type==="submit"||t.type==="image")){let a=t.form;if(a==null)throw new Error('Cannot submit a