diff --git a/CHANGELOG.md b/CHANGELOG.md index 02a32e3265..5ee0b59a58 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [3.20.1](https://github.com/Parsely/wp-parsely/compare/3.20.0...3.20.1) - 2025-06-19 + +### Fixed + +- Fix outbound link highlights in Traffic Boost ([#3469](https://github.com/Parsely/wp-parsely/pull/3469)) + ## [3.20.0](https://github.com/Parsely/wp-parsely/compare/3.19.3...3.20.0) - 2025-06-18 ### Changed diff --git a/README.md b/README.md index c48b47ff0a..d1568b01df 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Parse.ly -Stable tag: 3.20.0 +Stable tag: 3.20.1 Requires at least: 6.0 Tested up to: 6.8 Requires PHP: 7.4 diff --git a/build/content-helper/dashboard-page.asset.php b/build/content-helper/dashboard-page.asset.php index 482edca409..46c8a6329b 100644 --- a/build/content-helper/dashboard-page.asset.php +++ b/build/content-helper/dashboard-page.asset.php @@ -1 +1 @@ - array('react', 'wp-api-fetch', 'wp-components', 'wp-compose', 'wp-data', 'wp-dom-ready', 'wp-element', 'wp-escape-html', 'wp-i18n', 'wp-notices', 'wp-primitives', 'wp-url'), 'version' => 'd32bef74f4fde0b9ec6b'); + array('react', 'wp-api-fetch', 'wp-components', 'wp-compose', 'wp-data', 'wp-dom-ready', 'wp-element', 'wp-escape-html', 'wp-i18n', 'wp-notices', 'wp-primitives', 'wp-url'), 'version' => '1584528d4b5b04a117a7'); diff --git a/build/content-helper/dashboard-page.js b/build/content-helper/dashboard-page.js index d7f578db96..fc5385364d 100644 --- a/build/content-helper/dashboard-page.js +++ b/build/content-helper/dashboard-page.js @@ -1,9 +1,9 @@ -!function(){"use strict";var t={69:function(t,e){Object.prototype.toString},20:function(t,e,n){var r=n(609),o=Symbol.for("react.element"),i=Symbol.for("react.fragment"),a=Object.prototype.hasOwnProperty,s=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,l={key:!0,ref:!0,__self:!0,__source:!0};function c(t,e,n){var r,i={},c=null,u=null;for(r in void 0!==n&&(c=""+n),void 0!==e.key&&(c=""+e.key),void 0!==e.ref&&(u=e.ref),e)a.call(e,r)&&!l.hasOwnProperty(r)&&(i[r]=e[r]);if(t&&t.defaultProps)for(r in e=t.defaultProps)void 0===i[r]&&(i[r]=e[r]);return{$$typeof:o,type:t,key:c,ref:u,props:i,_owner:s.current}}e.Fragment=i,e.jsx=c,e.jsxs=c},848:function(t,e,n){t.exports=n(20)},609:function(t){t.exports=window.React}},e={};function n(r){var o=e[r];if(void 0!==o)return o.exports;var i=e[r]={exports:{}};return t[r](i,i.exports,n),i.exports}n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,{a:e}),e},n.d=function(t,e){for(var r in e)n.o(e,r)&&!n.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},function(){var t=n(848),e=n(609),r=(n(69),"popstate");function o(t={}){return function(t,e,n,o={}){let{window:a=document.defaultView,v5Compat:u=!1}=o,d=a.history,p="POP",f=null,h=g();function g(){return(d.state||{idx:null}).idx}function v(){p="POP";let t=g(),e=null==t?null:t-h;h=t,f&&f({action:p,location:y.location,delta:e})}function m(t){return function(t,e=!1){let n="http://localhost";"undefined"!=typeof window&&(n="null"!==window.location.origin?window.location.origin:window.location.href),i(n,"No window.location.(origin|href) available to create URL");let r="string"==typeof t?t:c(t);return r=r.replace(/ $/,"%20"),!e&&r.startsWith("//")&&(r=n+r),new URL(r,n)}(t)}null==h&&(h=0,d.replaceState({...d.state,idx:h},""));let y={get action(){return p},get location(){return t(a,d)},listen(t){if(f)throw new Error("A history only accepts one active listener");return a.addEventListener(r,v),f=t,()=>{a.removeEventListener(r,v),f=null}},createHref(t){return e(a,t)},createURL:m,encodeLocation(t){let e=m(t);return{pathname:e.pathname,search:e.search,hash:e.hash}},push:function(t,e){p="PUSH";let r=l(y.location,t,e);n&&n(r,t),h=g()+1;let o=s(r,h),i=y.createHref(r);try{d.pushState(o,"",i)}catch(t){if(t instanceof DOMException&&"DataCloneError"===t.name)throw t;a.location.assign(i)}u&&f&&f({action:p,location:y.location,delta:1})},replace:function(t,e){p="REPLACE";let r=l(y.location,t,e);n&&n(r,t),h=g();let o=s(r,h),i=y.createHref(r);d.replaceState(o,"",i),u&&f&&f({action:p,location:y.location,delta:0})},go(t){return d.go(t)}};return y}((function(t,e){let{pathname:n="/",search:r="",hash:o=""}=u(t.location.hash.substring(1));return n.startsWith("/")||n.startsWith(".")||(n="/"+n),l("",{pathname:n,search:r,hash:o},e.state&&e.state.usr||null,e.state&&e.state.key||"default")}),(function(t,e){let n=t.document.querySelector("base"),r="";if(n&&n.getAttribute("href")){let e=t.location.href,n=e.indexOf("#");r=-1===n?e:e.slice(0,n)}return r+"#"+("string"==typeof e?e:c(e))}),(function(t,e){a("/"===t.pathname.charAt(0),`relative pathnames are not supported in hash history.push(${JSON.stringify(e)})`)}),t)}function i(t,e){if(!1===t||null==t)throw new Error(e)}function a(t,e){if(!t){"undefined"!=typeof console&&console.warn(e);try{throw new Error(e)}catch(t){}}}function s(t,e){return{usr:t.state,key:t.key,idx:e}}function l(t,e,n=null,r){return{pathname:"string"==typeof t?t:t.pathname,search:"",hash:"",..."string"==typeof e?u(e):e,state:n,key:e&&e.key||r||Math.random().toString(36).substring(2,10)}}function c({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 u(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 d(t,e,n="/"){return function(t,e,n,r){let o=E(("string"==typeof e?u(e):e).pathname||"/",n);if(null==o)return null;let i=p(t);!function(t){t.sort(((t,e)=>t.score!==e.score?e.score-t.score:function(t,e){return t.length===e.length&&t.slice(0,-1).every(((t,n)=>t===e[n]))?t[t.length-1]-e[e.length-1]:0}(t.routesMeta.map((t=>t.childrenIndex)),e.routesMeta.map((t=>t.childrenIndex)))))}(i);let a=null;for(let t=0;null==a&&t{let s={relativePath:void 0===a?t.path||"":a,caseSensitive:!0===t.caseSensitive,childrenIndex:o,route:t};s.relativePath.startsWith("/")&&(i(s.relativePath.startsWith(r),`Absolute route path "${s.relativePath}" nested under path "${r}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),s.relativePath=s.relativePath.slice(r.length));let l=T([r,s.relativePath]),c=n.concat(s);t.children&&t.children.length>0&&(i(!0!==t.index,`Index routes must not have child routes. Please remove all child routes from route path "${l}".`),p(t.children,e,c,l)),(null!=t.path||t.index)&&e.push({path:l,score:x(l,t.index),routesMeta:c})};return t.forEach(((t,e)=>{if(""!==t.path&&t.path?.includes("?"))for(let n of f(t.path))o(t,e,n);else o(t,e)})),e}function f(t){let e=t.split("/");if(0===e.length)return[];let[n,...r]=e,o=n.endsWith("?"),i=n.replace(/\?$/,"");if(0===r.length)return o?[i,""]:[i];let a=f(r.join("/")),s=[];return s.push(...a.map((t=>""===t?i:[i,t].join("/")))),o&&s.push(...a),s.map((e=>t.startsWith("/")&&""===e?"/":e))}new WeakMap;var h=/^:[\w-]+$/,g=3,v=2,m=1,y=10,w=-2,b=t=>"*"===t;function x(t,e){let n=t.split("/"),r=n.length;return n.some(b)&&(r+=w),e&&(r+=v),n.filter((t=>!b(t))).reduce(((t,e)=>t+(h.test(e)?g:""===e?m:y)),r)}function k(t,e,n=!1){let{routesMeta:r}=t,o={},i="/",a=[];for(let t=0;t(r.push({paramName:e,isOptional:null!=n}),n?"/?([^\\/]+)?":"/([^\\/]+)")));return t.endsWith("*")?(r.push({paramName:"*"}),o+="*"===t||"/*"===t?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?o+="\\/*$":""!==t&&"/"!==t&&(o+="(?:(?=\\/|$))"),[new RegExp(o,e?void 0:"i"),r]}(t.path,t.caseSensitive,t.end),o=e.match(n);if(!o)return null;let i=o[0],s=i.replace(/(.)\/+$/,"$1"),l=o.slice(1);return{params:r.reduce(((t,{paramName:e,isOptional:n},r)=>{if("*"===e){let t=l[r]||"";s=i.slice(0,i.length-t.length).replace(/(.)\/+$/,"$1")}const o=l[r];return t[e]=n&&!o?void 0:(o||"").replace(/%2F/g,"/"),t}),{}),pathname:i,pathnameBase:s,pattern:t}}function S(t){try{return t.split("/").map((t=>decodeURIComponent(t).replace(/\//g,"%2F"))).join("/")}catch(e){return a(!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 E(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 P(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 L(t){let e=function(t){return t.filter(((t,e)=>0===e||t.route.path&&t.route.path.length>0))}(t);return e.map(((t,n)=>n===e.length-1?t.pathname:t.pathnameBase))}function j(t,e,n,r=!1){let o;"string"==typeof t?o=u(t):(o={...t},i(!o.pathname||!o.pathname.includes("?"),P("?","pathname","search",o)),i(!o.pathname||!o.pathname.includes("#"),P("#","pathname","hash",o)),i(!o.search||!o.search.includes("#"),P("#","search","hash",o)));let a,s=""===t||""===o.pathname,l=s?"/":o.pathname;if(null==l)a=n;else{let t=e.length-1;if(!r&&l.startsWith("..")){let e=l.split("/");for(;".."===e[0];)e.shift(),t-=1;o.pathname=e.join("/")}a=t>=0?e[t]:"/"}let c=function(t,e="/"){let{pathname:n,search:r="",hash:o=""}="string"==typeof t?u(t):t,i=n?n.startsWith("/")?n:function(t,e){let n=e.replace(/\/+$/,"").split("/");return t.split("/").forEach((t=>{".."===t?n.length>1&&n.pop():"."!==t&&n.push(t)})),n.length>1?n.join("/"):"/"}(n,e):e;return{pathname:i,search:C(r),hash:I(o)}}(o,a),d=l&&"/"!==l&&l.endsWith("/"),p=(s||"."===l)&&n.endsWith("/");return c.pathname.endsWith("/")||!d&&!p||(c.pathname+="/"),c}var T=t=>t.join("/").replace(/\/\/+/g,"/"),N=t=>t.replace(/\/+$/,"").replace(/^\/*/,"/"),C=t=>t&&"?"!==t?t.startsWith("?")?t:"?"+t:"",I=t=>t&&"#"!==t?t.startsWith("#")?t:"#"+t:"";function R(t){return null!=t&&"number"==typeof t.status&&"string"==typeof t.statusText&&"boolean"==typeof t.internal&&"data"in t}var A=["POST","PUT","PATCH","DELETE"],O=(new Set(A),["GET",...A]);new Set(O),Symbol("ResetLoaderData");var D=e.createContext(null);D.displayName="DataRouter";var B=e.createContext(null);B.displayName="DataRouterState";var M=e.createContext({isTransitioning:!1});M.displayName="ViewTransition",e.createContext(new Map).displayName="Fetchers",e.createContext(null).displayName="Await";var G=e.createContext(null);G.displayName="Navigation";var F=e.createContext(null);F.displayName="Location";var U=e.createContext({outlet:null,matches:[],isDataRoute:!1});U.displayName="Route";var H=e.createContext(null);function V(){return null!=e.useContext(F)}function $(){return i(V(),"useLocation() may be used only in the context of a component."),e.useContext(F).location}H.displayName="RouteError";var W="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function z(t){e.useContext(G).static||e.useLayoutEffect(t)}function q(){let{isDataRoute:t}=e.useContext(U);return t?function(){let{router:t}=function(t){let n=e.useContext(D);return i(n,tt(t)),n}("useNavigate"),n=et("useNavigate"),r=e.useRef(!1);return z((()=>{r.current=!0})),e.useCallback((async(e,o={})=>{a(r.current,W),r.current&&("number"==typeof e?t.navigate(e):await t.navigate(e,{fromRouteId:n,...o}))}),[t,n])}():function(){i(V(),"useNavigate() may be used only in the context of a component.");let t=e.useContext(D),{basename:n,navigator:r}=e.useContext(G),{matches:o}=e.useContext(U),{pathname:s}=$(),l=JSON.stringify(L(o)),c=e.useRef(!1);return z((()=>{c.current=!0})),e.useCallback(((e,o={})=>{if(a(c.current,W),!c.current)return;if("number"==typeof e)return void r.go(e);let i=j(e,JSON.parse(l),s,"path"===o.relative);null==t&&"/"!==n&&(i.pathname="/"===i.pathname?n:T([n,i.pathname])),(o.replace?r.replace:r.push)(i,o.state,o)}),[n,r,l,s,t])}()}function Z(t,{relative:n}={}){let{matches:r}=e.useContext(U),{pathname:o}=$(),i=JSON.stringify(L(r));return e.useMemo((()=>j(t,JSON.parse(i),o,"path"===n)),[t,i,o,n])}function K(t,n,r,o){i(V(),"useRoutes() may be used only in the context of a component.");let{navigator:s}=e.useContext(G),{matches:l}=e.useContext(U),c=l[l.length-1],p=c?c.params:{},f=c?c.pathname:"/",h=c?c.pathnameBase:"/",g=c&&c.route;{let t=g&&g.path||"";rt(f,!g||t.endsWith("*")||t.endsWith("*?"),`You rendered descendant (or called \`useRoutes()\`) at "${f}" (under ) but the parent route path has no trailing "*". This means if you navigate deeper, the parent won't match anymore and therefore the child routes will never render.\n\nPlease change the parent to .`)}let v,m=$();if(n){let t="string"==typeof n?u(n):n;i("/"===h||t.pathname?.startsWith(h),`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 "${h}" but pathname "${t.pathname}" was given in the \`location\` prop.`),v=t}else v=m;let y=v.pathname||"/",w=y;if("/"!==h){let t=h.replace(/^\//,"").split("/");w="/"+y.replace(/^\//,"").split("/").slice(t.length).join("/")}let b=d(t,{pathname:w});a(g||null!=b,`No routes matched location "${v.pathname}${v.search}${v.hash}" `),a(null==b||void 0!==b[b.length-1].route.element||void 0!==b[b.length-1].route.Component||void 0!==b[b.length-1].route.lazy,`Matched leaf route at location "${v.pathname}${v.search}${v.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=function(t,n=[],r=null){if(null==t){if(!r)return null;if(r.errors)t=r.matches;else{if(0!==n.length||r.initialized||!(r.matches.length>0))return null;t=r.matches}}let o=t,a=r?.errors;if(null!=a){let t=o.findIndex((t=>t.route.id&&void 0!==a?.[t.route.id]));i(t>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(a).join(",")}`),o=o.slice(0,Math.min(o.length,t+1))}let s=!1,l=-1;if(r)for(let t=0;t=0?o.slice(0,l+1):[o[0]];break}}}return o.reduceRight(((t,i,c)=>{let u,d=!1,p=null,f=null;r&&(u=a&&i.route.id?a[i.route.id]:void 0,p=i.route.errorElement||J,s&&(l<0&&0===c?(rt("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),d=!0,f=null):l===c&&(d=!0,f=i.route.hydrateFallbackElement||null)));let h=n.concat(o.slice(0,c+1)),g=()=>{let n;return n=u?p:d?f:i.route.Component?e.createElement(i.route.Component,null):i.route.element?i.route.element:t,e.createElement(Q,{match:i,routeContext:{outlet:t,matches:h,isDataRoute:null!=r},children:n})};return r&&(i.route.ErrorBoundary||i.route.errorElement||0===c)?e.createElement(X,{location:r.location,revalidation:r.revalidation,component:p,error:u,children:g(),routeContext:{outlet:null,matches:h,isDataRoute:!0}}):g()}),null)}(b&&b.map((t=>Object.assign({},t,{params:Object.assign({},p,t.params),pathname:T([h,s.encodeLocation?s.encodeLocation(t.pathname).pathname:t.pathname]),pathnameBase:"/"===t.pathnameBase?h:T([h,s.encodeLocation?s.encodeLocation(t.pathnameBase).pathname:t.pathnameBase])}))),l,r,o);return n&&x?e.createElement(F.Provider,{value:{location:{pathname:"/",search:"",hash:"",state:null,key:"default",...v},navigationType:"POP"}},x):x}function Y(){let t=function(){let t=e.useContext(H),n=function(t){let n=e.useContext(B);return i(n,tt(t)),n}("useRouteError"),r=et("useRouteError");return void 0!==t?t:n.errors?.[r]}(),n=R(t)?`${t.status} ${t.statusText}`:t instanceof Error?t.message:JSON.stringify(t),r=t instanceof Error?t.stack:null,o="rgba(200,200,200, 0.5)",a={padding:"0.5rem",backgroundColor:o},s={padding:"2px 4px",backgroundColor:o},l=null;return console.error("Error handled by React Router default ErrorBoundary:",t),l=e.createElement(e.Fragment,null,e.createElement("p",null,"đź’ż Hey developer đź‘‹"),e.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",e.createElement("code",{style:s},"ErrorBoundary")," or"," ",e.createElement("code",{style:s},"errorElement")," prop on your route.")),e.createElement(e.Fragment,null,e.createElement("h2",null,"Unexpected Application Error!"),e.createElement("h3",{style:{fontStyle:"italic"}},n),r?e.createElement("pre",{style:a},r):null,l)}e.createContext(null);var J=e.createElement(Y,null),X=class extends e.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||"idle"!==e.revalidation&&"idle"===t.revalidation?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:void 0!==t.error?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 void 0!==this.state.error?e.createElement(U.Provider,{value:this.props.routeContext},e.createElement(H.Provider,{value:this.state.error,children:this.props.component})):this.props.children}};function Q({routeContext:t,match:n,children:r}){let o=e.useContext(D);return o&&o.static&&o.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(o.staticContext._deepestRenderedBoundaryId=n.route.id),e.createElement(U.Provider,{value:t},r)}function tt(t){return`${t} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function et(t){let n=function(t){let n=e.useContext(U);return i(n,tt(t)),n}(t),r=n.matches[n.matches.length-1];return i(r.route.id,`${t} can only be used on routes that contain a unique "id"`),r.route.id}var nt={};function rt(t,e,n){e||nt[t]||(nt[t]=!0,a(!1,n))}function ot({to:t,replace:n,state:r,relative:o}){i(V()," may be used only in the context of a component.");let{static:s}=e.useContext(G);a(!s," must not be used on the initial render in a . This is a no-op, but you should modify your code so the is only ever rendered in response to some user interaction or state change.");let{matches:l}=e.useContext(U),{pathname:c}=$(),u=q(),d=j(t,L(l),c,"path"===o),p=JSON.stringify(d);return e.useEffect((()=>{u(JSON.parse(p),{replace:n,state:r,relative:o})}),[u,p,o,n,r]),null}function it(t){i(!1,"A is only ever to be used as the child of element, never rendered directly. Please wrap your in a .")}function at({basename:t="/",children:n=null,location:r,navigationType:o="POP",navigator:s,static:l=!1}){i(!V(),"You cannot render a inside another . You should never have more than one in your app.");let c=t.replace(/^\/*/,"/"),d=e.useMemo((()=>({basename:c,navigator:s,static:l,future:{}})),[c,s,l]);"string"==typeof r&&(r=u(r));let{pathname:p="/",search:f="",hash:h="",state:g=null,key:v="default"}=r,m=e.useMemo((()=>{let t=E(p,c);return null==t?null:{location:{pathname:t,search:f,hash:h,state:g,key:v},navigationType:o}}),[c,p,f,h,g,v,o]);return a(null!=m,` is not able to match the URL "${p}${f}${h}" because it does not start with the basename, so the won't render anything.`),null==m?null:e.createElement(G.Provider,{value:d},e.createElement(F.Provider,{children:n,value:m}))}function st({children:t,location:e}){return K(lt(t),e)}function lt(t,n=[]){let r=[];return e.Children.forEach(t,((t,o)=>{if(!e.isValidElement(t))return;let a=[...n,o];if(t.type===e.Fragment)return void r.push.apply(r,lt(t.props.children,a));i(t.type===it,`[${"string"==typeof t.type?t.type:t.type.name}] is not a component. All component children of must be a or `),i(!t.props.index||!t.props.children,"An index route cannot have child routes.");let s={id:t.props.id||a.join("-"),caseSensitive:t.props.caseSensitive,element:t.props.element,Component:t.props.Component,index:t.props.index,path:t.props.path,loader:t.props.loader,action:t.props.action,hydrateFallbackElement:t.props.hydrateFallbackElement,HydrateFallback:t.props.HydrateFallback,errorElement:t.props.errorElement,ErrorBoundary:t.props.ErrorBoundary,hasErrorBoundary:!0===t.props.hasErrorBoundary||null!=t.props.ErrorBoundary||null!=t.props.errorElement,shouldRevalidate:t.props.shouldRevalidate,handle:t.props.handle,lazy:t.props.lazy};t.props.children&&(s.children=lt(t.props.children,a)),r.push(s)})),r}e.memo((function({routes:t,future:e,state:n}){return K(t,void 0,n,e)})),e.Component;var ct="get",ut="application/x-www-form-urlencoded";function dt(t){return null!=t&&"string"==typeof t.tagName}var pt=null,ft=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function ht(t){return null==t||ft.has(t)?t:(a(!1,`"${t}" is not a valid \`encType\` for \`
\`/\`\` and will default to "${ut}"`),null)}function gt(t,e){if(!1===t||null==t)throw new Error(e)}function vt(t){return null!=t&&(null==t.href?"preload"===t.rel&&"string"==typeof t.imageSrcSet&&"string"==typeof t.imageSizes:"string"==typeof t.rel&&"string"==typeof t.href)}function mt(t,e,n,r,o,i){let a=(t,e)=>!n[e]||t.route.id!==n[e].route.id,s=(t,e)=>n[e].pathname!==t.pathname||n[e].route.path?.endsWith("*")&&n[e].params["*"]!==t.params["*"];return"assets"===i?e.filter(((t,e)=>a(t,e)||s(t,e))):"data"===i?e.filter(((e,i)=>{let l=r.routes[e.route.id];if(!l||!l.hasLoader)return!1;if(a(e,i)||s(e,i))return!0;if(e.route.shouldRevalidate){let r=e.route.shouldRevalidate({currentUrl:new URL(o.pathname+o.search+o.hash,window.origin),currentParams:n[0]?.params||{},nextUrl:new URL(t,window.origin),nextParams:e.params,defaultShouldRevalidate:!0});if("boolean"==typeof r)return r}return!0})):[]}function yt(t,e,{includeHydrateFallback:n}={}){return r=t.map((t=>{let r=e.routes[t.route.id];if(!r)return[];let o=[r.module];return r.clientActionModule&&(o=o.concat(r.clientActionModule)),r.clientLoaderModule&&(o=o.concat(r.clientLoaderModule)),n&&r.hydrateFallbackModule&&(o=o.concat(r.hydrateFallbackModule)),r.imports&&(o=o.concat(r.imports)),o})).flat(1),[...new Set(r)];var r}Object.getOwnPropertyNames(Object.prototype).sort().join("\0"),"undefined"!=typeof window?window:"undefined"!=typeof globalThis&&globalThis,Symbol("SingleFetchRedirect");function wt(){let t=e.useContext(D);return gt(t,"You must render this element inside a element"),t}function bt(){let t=e.useContext(B);return gt(t,"You must render this element inside a element"),t}e.Component;var xt=e.createContext(void 0);function kt(){let t=e.useContext(xt);return gt(t,"You must render this element inside a element"),t}function _t(t,e){return n=>{t&&t(n),n.defaultPrevented||e(n)}}function St({page:t,...n}){let{router:r}=wt(),o=e.useMemo((()=>d(r.routes,t,r.basename)),[r.routes,t,r.basename]);return o?e.createElement(Pt,{page:t,matches:o,...n}):null}function Et(t){let{manifest:n,routeModules:r}=kt(),[o,i]=e.useState([]);return e.useEffect((()=>{let e=!1;return async function(t,e,n){return function(t,e){let n=new Set,r=new Set(e);return t.reduce(((t,o)=>{if(e&&(null==(i=o)||"string"!=typeof i.page)&&"script"===o.as&&o.href&&r.has(o.href))return t;var i;let a=JSON.stringify(function(t){let e={},n=Object.keys(t).sort();for(let r of n)e[r]=t[r];return e}(o));return n.has(a)||(n.add(a),t.push({key:a,link:o})),t}),[])}((await Promise.all(t.map((async t=>{let r=e.routes[t.route.id];if(r){let t=await async function(t,e){if(t.id in e)return e[t.id];try{let n=await import(t.module);return e[t.id]=n,n}catch(e){return console.error(`Error loading route module \`${t.module}\`, reloading page...`),console.error(e),window.__reactRouterContext&&window.__reactRouterContext.isSpaMode,window.location.reload(),new Promise((()=>{}))}}(r,n);return t.links?t.links():[]}return[]})))).flat(1).filter(vt).filter((t=>"stylesheet"===t.rel||"preload"===t.rel)).map((t=>"stylesheet"===t.rel?{...t,rel:"prefetch",as:"style"}:{...t,rel:"prefetch"})))}(t,n,r).then((t=>{e||i(t)})),()=>{e=!0}}),[t,n,r]),o}function Pt({page:t,matches:n,...r}){let o=$(),{manifest:i,routeModules:a}=kt(),{basename:s}=wt(),{loaderData:l,matches:c}=bt(),u=e.useMemo((()=>mt(t,n,c,i,o,"data")),[t,n,c,i,o]),d=e.useMemo((()=>mt(t,n,c,i,o,"assets")),[t,n,c,i,o]),p=e.useMemo((()=>{if(t===o.pathname+o.search+o.hash)return[];let e=new Set,r=!1;if(n.forEach((t=>{let n=i.routes[t.route.id];n&&n.hasLoader&&(!u.some((e=>e.route.id===t.route.id))&&t.route.id in l&&a[t.route.id]?.shouldRevalidate||n.hasClientLoader?r=!0:e.add(t.route.id))})),0===e.size)return[];let c=function(t,e){let n="string"==typeof t?new URL(t,"undefined"==typeof window?"server://singlefetch/":window.location.origin):t;return"/"===n.pathname?n.pathname="_root.data":e&&"/"===E(n.pathname,e)?n.pathname=`${e.replace(/\/$/,"")}/_root.data`:n.pathname=`${n.pathname.replace(/\/$/,"")}.data`,n}(t,s);return r&&e.size>0&&c.searchParams.set("_routes",n.filter((t=>e.has(t.route.id))).map((t=>t.route.id)).join(",")),[c.pathname+c.search]}),[s,l,o,i,u,n,t,a]),f=e.useMemo((()=>yt(d,i)),[d,i]),h=Et(d);return e.createElement(e.Fragment,null,p.map((t=>e.createElement("link",{key:t,rel:"prefetch",as:"fetch",href:t,...r}))),f.map((t=>e.createElement("link",{key:t,rel:"modulepreload",href:t,...r}))),h.map((({key:t,link:n})=>e.createElement("link",{key:t,...n}))))}xt.displayName="FrameworkContext";function Lt(...t){return e=>{t.forEach((t=>{"function"==typeof t?t(e):null!=t&&(t.current=e)}))}}var jt="undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement;try{jt&&(window.__reactRouterVersion="7.6.2")}catch(t){}function Tt({basename:t,children:n,window:r}){let i=e.useRef();null==i.current&&(i.current=o({window:r,v5Compat:!0}));let a=i.current,[s,l]=e.useState({action:a.action,location:a.location}),c=e.useCallback((t=>{e.startTransition((()=>l(t)))}),[l]);return e.useLayoutEffect((()=>a.listen(c)),[a,c]),e.createElement(at,{basename:t,children:n,location:s.location,navigationType:s.action,navigator:a})}var Nt=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Ct=e.forwardRef((function({onClick:t,discover:n="render",prefetch:r="none",relative:o,reloadDocument:s,replace:l,state:u,target:d,to:p,preventScrollReset:f,viewTransition:h,...g},v){let m,{basename:y}=e.useContext(G),w="string"==typeof p&&Nt.test(p),b=!1;if("string"==typeof p&&w&&(m=p,jt))try{let t=new URL(window.location.href),e=p.startsWith("//")?new URL(t.protocol+p):new URL(p),n=E(e.pathname,y);e.origin===t.origin&&null!=n?p=n+e.search+e.hash:b=!0}catch(t){a(!1,` contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}let x=function(t,{relative:n}={}){i(V(),"useHref() may be used only in the context of a component.");let{basename:r,navigator:o}=e.useContext(G),{hash:a,pathname:s,search:l}=Z(t,{relative:n}),c=s;return"/"!==r&&(c="/"===s?r:T([r,s])),o.createHref({pathname:c,search:l,hash:a})}(p,{relative:o}),[k,_,S]=function(t,n){let r=e.useContext(xt),[o,i]=e.useState(!1),[a,s]=e.useState(!1),{onFocus:l,onBlur:c,onMouseEnter:u,onMouseLeave:d,onTouchStart:p}=n,f=e.useRef(null);e.useEffect((()=>{if("render"===t&&s(!0),"viewport"===t){let t=new IntersectionObserver((t=>{t.forEach((t=>{s(t.isIntersecting)}))}),{threshold:.5});return f.current&&t.observe(f.current),()=>{t.disconnect()}}}),[t]),e.useEffect((()=>{if(o){let t=setTimeout((()=>{s(!0)}),100);return()=>{clearTimeout(t)}}}),[o]);let h=()=>{i(!0)},g=()=>{i(!1),s(!1)};return r?"intent"!==t?[a,f,{}]:[a,f,{onFocus:_t(l,h),onBlur:_t(c,g),onMouseEnter:_t(u,h),onMouseLeave:_t(d,g),onTouchStart:_t(p,h)}]:[!1,f,{}]}(r,g),P=function(t,{target:n,replace:r,state:o,preventScrollReset:i,relative:a,viewTransition:s}={}){let l=q(),u=$(),d=Z(t,{relative:a});return e.useCallback((e=>{if(function(t,e){return!(0!==t.button||e&&"_self"!==e||function(t){return!!(t.metaKey||t.altKey||t.ctrlKey||t.shiftKey)}(t))}(e,n)){e.preventDefault();let n=void 0!==r?r:c(u)===c(d);l(t,{replace:n,state:o,preventScrollReset:i,relative:a,viewTransition:s})}}),[u,l,d,r,o,n,t,i,a,s])}(p,{replace:l,state:u,target:d,preventScrollReset:f,relative:o,viewTransition:h}),L=e.createElement("a",{...g,...S,href:m||x,onClick:b||s?t:function(e){t&&t(e),e.defaultPrevented||P(e)},ref:Lt(v,_),target:d,"data-discover":w||"render"!==n?void 0:"true"});return k&&!w?e.createElement(e.Fragment,null,L,e.createElement(St,{page:x})):L}));function It(t){let n=e.useContext(D);return i(n,function(t){return`${t} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}(t)),n}Ct.displayName="Link",e.forwardRef((function({"aria-current":t="page",caseSensitive:n=!1,className:r="",end:o=!1,style:a,to:s,viewTransition:l,children:c,...u},d){let p=Z(s,{relative:u.relative}),f=$(),h=e.useContext(B),{navigator:g,basename:v}=e.useContext(G),m=null!=h&&function(t,n={}){let r=e.useContext(M);i(null!=r,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:o}=It("useViewTransitionState"),a=Z(t,{relative:n.relative});if(!r.isTransitioning)return!1;let s=E(r.currentLocation.pathname,o)||r.currentLocation.pathname,l=E(r.nextLocation.pathname,o)||r.nextLocation.pathname;return null!=_(a.pathname,l)||null!=_(a.pathname,s)}(p)&&!0===l,y=g.encodeLocation?g.encodeLocation(p).pathname:p.pathname,w=f.pathname,b=h&&h.navigation&&h.navigation.location?h.navigation.location.pathname:null;n||(w=w.toLowerCase(),b=b?b.toLowerCase():null,y=y.toLowerCase()),b&&v&&(b=E(b,v)||b);const x="/"!==y&&y.endsWith("/")?y.length-1:y.length;let k,S=w===y||!o&&w.startsWith(y)&&"/"===w.charAt(x),P=null!=b&&(b===y||!o&&b.startsWith(y)&&"/"===b.charAt(y.length)),L={isActive:S,isPending:P,isTransitioning:m},j=S?t:void 0;k="function"==typeof r?r(L):[r,S?"active":null,P?"pending":null,m?"transitioning":null].filter(Boolean).join(" ");let T="function"==typeof a?a(L):a;return e.createElement(Ct,{...u,"aria-current":j,className:k,ref:d,style:T,to:s,viewTransition:l},"function"==typeof c?c(L):c)})).displayName="NavLink",e.forwardRef((({discover:t="render",fetcherKey:n,navigate:r,reloadDocument:o,replace:a,state:s,method:l=ct,action:u,onSubmit:d,relative:p,preventScrollReset:f,viewTransition:h,...g},v)=>{let m=function(){let{router:t}=It("useSubmit"),{basename:n}=e.useContext(G),r=et("useRouteId");return e.useCallback((async(e,o={})=>{let{action:i,method:a,encType:s,formData:l,body:c}=function(t,e){let n,r,o,i,a;if(dt(s=t)&&"form"===s.tagName.toLowerCase()){let a=t.getAttribute("action");r=a?E(a,e):null,n=t.getAttribute("method")||ct,o=ht(t.getAttribute("enctype"))||ut,i=new FormData(t)}else if(function(t){return dt(t)&&"button"===t.tagName.toLowerCase()}(t)||function(t){return dt(t)&&"input"===t.tagName.toLowerCase()}(t)&&("submit"===t.type||"image"===t.type)){let a=t.form;if(null==a)throw new Error('Cannot submit a