const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/stegaEncodeSourceMap-BheWRINd.js","assets/stegaClean-BGs5fC09.js","assets/browser-C0hijO98.js","assets/chunk-B3K2TuZy.js"])))=>i.map(i=>d[i]);
import{n as e,t}from"./chunk-B3K2TuZy.js";import{n,t as r}from"./stegaClean-BGs5fC09.js";(function(){let e=document.createElement(`link`).relList;if(e&&e.supports&&e.supports(`modulepreload`))return;for(let e of document.querySelectorAll(`link[rel="modulepreload"]`))n(e);new MutationObserver(e=>{for(let t of e)if(t.type===`childList`)for(let e of t.addedNodes)e.tagName===`LINK`&&e.rel===`modulepreload`&&n(e)}).observe(document,{childList:!0,subtree:!0});function t(e){let t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),e.crossOrigin===`use-credentials`?t.credentials=`include`:e.crossOrigin===`anonymous`?t.credentials=`omit`:t.credentials=`same-origin`,t}function n(e){if(e.ep)return;e.ep=!0;let n=t(e);fetch(e.href,n)}})();var i=t((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.portal`),r=Symbol.for(`react.fragment`),i=Symbol.for(`react.strict_mode`),a=Symbol.for(`react.profiler`),o=Symbol.for(`react.consumer`),s=Symbol.for(`react.context`),c=Symbol.for(`react.forward_ref`),l=Symbol.for(`react.suspense`),u=Symbol.for(`react.memo`),d=Symbol.for(`react.lazy`),f=Symbol.for(`react.activity`),p=Symbol.iterator;function m(e){return typeof e!=`object`||!e?null:(e=p&&e[p]||e[`@@iterator`],typeof e==`function`?e:null)}var h={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},g=Object.assign,_={};function v(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}v.prototype.isReactComponent={},v.prototype.setState=function(e,t){if(typeof e!=`object`&&typeof e!=`function`&&e!=null)throw Error(`takes an object of state variables to update or a function which returns an object of state variables.`);this.updater.enqueueSetState(this,e,t,`setState`)},v.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,`forceUpdate`)};function y(){}y.prototype=v.prototype;function b(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}var x=b.prototype=new y;x.constructor=b,g(x,v.prototype),x.isPureReactComponent=!0;var S=Array.isArray;function C(){}var w={H:null,A:null,T:null,S:null},T=Object.prototype.hasOwnProperty;function E(e,n,r){var i=r.ref;return{$$typeof:t,type:e,key:n,ref:i===void 0?null:i,props:r}}function D(e,t){return E(e.type,t,e.props)}function O(e){return typeof e==`object`&&!!e&&e.$$typeof===t}function ee(e){var t={"=":`=0`,":":`=2`};return`$`+e.replace(/[=:]/g,function(e){return t[e]})}var te=/\/+/g;function ne(e,t){return typeof e==`object`&&e&&e.key!=null?ee(``+e.key):t.toString(36)}function re(e){switch(e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason;default:switch(typeof e.status==`string`?e.then(C,C):(e.status=`pending`,e.then(function(t){e.status===`pending`&&(e.status=`fulfilled`,e.value=t)},function(t){e.status===`pending`&&(e.status=`rejected`,e.reason=t)})),e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason}}throw e}function ie(e,r,i,a,o){var s=typeof e;(s===`undefined`||s===`boolean`)&&(e=null);var c=!1;if(e===null)c=!0;else switch(s){case`bigint`:case`string`:case`number`:c=!0;break;case`object`:switch(e.$$typeof){case t:case n:c=!0;break;case d:return c=e._init,ie(c(e._payload),r,i,a,o)}}if(c)return o=o(e),c=a===``?`.`+ne(e,0):a,S(o)?(i=``,c!=null&&(i=c.replace(te,`$&/`)+`/`),ie(o,r,i,``,function(e){return e})):o!=null&&(O(o)&&(o=D(o,i+(o.key==null||e&&e.key===o.key?``:(``+o.key).replace(te,`$&/`)+`/`)+c)),r.push(o)),1;c=0;var l=a===``?`.`:a+`:`;if(S(e))for(var u=0;u<e.length;u++)a=e[u],s=l+ne(a,u),c+=ie(a,r,i,s,o);else if(u=m(e),typeof u==`function`)for(e=u.call(e),u=0;!(a=e.next()).done;)a=a.value,s=l+ne(a,u++),c+=ie(a,r,i,s,o);else if(s===`object`){if(typeof e.then==`function`)return ie(re(e),r,i,a,o);throw r=String(e),Error(`Objects are not valid as a React child (found: `+(r===`[object Object]`?`object with keys {`+Object.keys(e).join(`, `)+`}`:r)+`). If you meant to render a collection of children, use an array instead.`)}return c}function k(e,t,n){if(e==null)return e;var r=[],i=0;return ie(e,r,``,``,function(e){return t.call(n,e,i++)}),r}function ae(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(t){(e._status===0||e._status===-1)&&(e._status=1,e._result=t)},function(t){(e._status===0||e._status===-1)&&(e._status=2,e._result=t)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var A=typeof reportError==`function`?reportError:function(e){if(typeof window==`object`&&typeof window.ErrorEvent==`function`){var t=new window.ErrorEvent(`error`,{bubbles:!0,cancelable:!0,message:typeof e==`object`&&e&&typeof e.message==`string`?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process==`object`&&typeof process.emit==`function`){process.emit(`uncaughtException`,e);return}console.error(e)},j={map:k,forEach:function(e,t,n){k(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return k(e,function(){t++}),t},toArray:function(e){return k(e,function(e){return e})||[]},only:function(e){if(!O(e))throw Error(`React.Children.only expected to receive a single React element child.`);return e}};e.Activity=f,e.Children=j,e.Component=v,e.Fragment=r,e.Profiler=a,e.PureComponent=b,e.StrictMode=i,e.Suspense=l,e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=w,e.__COMPILER_RUNTIME={__proto__:null,c:function(e){return w.H.useMemoCache(e)}},e.cache=function(e){return function(){return e.apply(null,arguments)}},e.cacheSignal=function(){return null},e.cloneElement=function(e,t,n){if(e==null)throw Error(`The argument must be a React element, but you passed `+e+`.`);var r=g({},e.props),i=e.key;if(t!=null)for(a in t.key!==void 0&&(i=``+t.key),t)!T.call(t,a)||a===`key`||a===`__self`||a===`__source`||a===`ref`&&t.ref===void 0||(r[a]=t[a]);var a=arguments.length-2;if(a===1)r.children=n;else if(1<a){for(var o=Array(a),s=0;s<a;s++)o[s]=arguments[s+2];r.children=o}return E(e.type,i,r)},e.createContext=function(e){return e={$$typeof:s,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null},e.Provider=e,e.Consumer={$$typeof:o,_context:e},e},e.createElement=function(e,t,n){var r,i={},a=null;if(t!=null)for(r in t.key!==void 0&&(a=``+t.key),t)T.call(t,r)&&r!==`key`&&r!==`__self`&&r!==`__source`&&(i[r]=t[r]);var o=arguments.length-2;if(o===1)i.children=n;else if(1<o){for(var s=Array(o),c=0;c<o;c++)s[c]=arguments[c+2];i.children=s}if(e&&e.defaultProps)for(r in o=e.defaultProps,o)i[r]===void 0&&(i[r]=o[r]);return E(e,a,i)},e.createRef=function(){return{current:null}},e.forwardRef=function(e){return{$$typeof:c,render:e}},e.isValidElement=O,e.lazy=function(e){return{$$typeof:d,_payload:{_status:-1,_result:e},_init:ae}},e.memo=function(e,t){return{$$typeof:u,type:e,compare:t===void 0?null:t}},e.startTransition=function(e){var t=w.T,n={};w.T=n;try{var r=e(),i=w.S;i!==null&&i(n,r),typeof r==`object`&&r&&typeof r.then==`function`&&r.then(C,A)}catch(e){A(e)}finally{t!==null&&n.types!==null&&(t.types=n.types),w.T=t}},e.unstable_useCacheRefresh=function(){return w.H.useCacheRefresh()},e.use=function(e){return w.H.use(e)},e.useActionState=function(e,t,n){return w.H.useActionState(e,t,n)},e.useCallback=function(e,t){return w.H.useCallback(e,t)},e.useContext=function(e){return w.H.useContext(e)},e.useDebugValue=function(){},e.useDeferredValue=function(e,t){return w.H.useDeferredValue(e,t)},e.useEffect=function(e,t){return w.H.useEffect(e,t)},e.useEffectEvent=function(e){return w.H.useEffectEvent(e)},e.useId=function(){return w.H.useId()},e.useImperativeHandle=function(e,t,n){return w.H.useImperativeHandle(e,t,n)},e.useInsertionEffect=function(e,t){return w.H.useInsertionEffect(e,t)},e.useLayoutEffect=function(e,t){return w.H.useLayoutEffect(e,t)},e.useMemo=function(e,t){return w.H.useMemo(e,t)},e.useOptimistic=function(e,t){return w.H.useOptimistic(e,t)},e.useReducer=function(e,t,n){return w.H.useReducer(e,t,n)},e.useRef=function(e){return w.H.useRef(e)},e.useState=function(e){return w.H.useState(e)},e.useSyncExternalStore=function(e,t,n){return w.H.useSyncExternalStore(e,t,n)},e.useTransition=function(){return w.H.useTransition()},e.version=`19.2.5`})),a=t(((e,t)=>{t.exports=i()})),o=t((e=>{function t(e,t){var n=e.length;e.push(t);a:for(;0<n;){var r=n-1>>>1,a=e[r];if(0<i(a,t))e[r]=t,e[n]=a,n=r;else break a}}function n(e){return e.length===0?null:e[0]}function r(e){if(e.length===0)return null;var t=e[0],n=e.pop();if(n!==t){e[0]=n;a:for(var r=0,a=e.length,o=a>>>1;r<o;){var s=2*(r+1)-1,c=e[s],l=s+1,u=e[l];if(0>i(c,n))l<a&&0>i(u,c)?(e[r]=u,e[l]=n,r=l):(e[r]=c,e[s]=n,r=s);else if(l<a&&0>i(u,n))e[r]=u,e[l]=n,r=l;else break a}}return t}function i(e,t){var n=e.sortIndex-t.sortIndex;return n===0?e.id-t.id:n}if(e.unstable_now=void 0,typeof performance==`object`&&typeof performance.now==`function`){var a=performance;e.unstable_now=function(){return a.now()}}else{var o=Date,s=o.now();e.unstable_now=function(){return o.now()-s}}var c=[],l=[],u=1,d=null,f=3,p=!1,m=!1,h=!1,g=!1,_=typeof setTimeout==`function`?setTimeout:null,v=typeof clearTimeout==`function`?clearTimeout:null,y=typeof setImmediate<`u`?setImmediate:null;function b(e){for(var i=n(l);i!==null;){if(i.callback===null)r(l);else if(i.startTime<=e)r(l),i.sortIndex=i.expirationTime,t(c,i);else break;i=n(l)}}function x(e){if(h=!1,b(e),!m)if(n(c)!==null)m=!0,S||(S=!0,O());else{var t=n(l);t!==null&&ne(x,t.startTime-e)}}var S=!1,C=-1,w=5,T=-1;function E(){return g?!0:!(e.unstable_now()-T<w)}function D(){if(g=!1,S){var t=e.unstable_now();T=t;var i=!0;try{a:{m=!1,h&&(h=!1,v(C),C=-1),p=!0;var a=f;try{b:{for(b(t),d=n(c);d!==null&&!(d.expirationTime>t&&E());){var o=d.callback;if(typeof o==`function`){d.callback=null,f=d.priorityLevel;var s=o(d.expirationTime<=t);if(t=e.unstable_now(),typeof s==`function`){d.callback=s,b(t),i=!0;break b}d===n(c)&&r(c),b(t)}else r(c);d=n(c)}if(d!==null)i=!0;else{var u=n(l);u!==null&&ne(x,u.startTime-t),i=!1}}break a}finally{d=null,f=a,p=!1}i=void 0}}finally{i?O():S=!1}}}var O;if(typeof y==`function`)O=function(){y(D)};else if(typeof MessageChannel<`u`){var ee=new MessageChannel,te=ee.port2;ee.port1.onmessage=D,O=function(){te.postMessage(null)}}else O=function(){_(D,0)};function ne(t,n){C=_(function(){t(e.unstable_now())},n)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(e){e.callback=null},e.unstable_forceFrameRate=function(e){0>e||125<e?console.error(`forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported`):w=0<e?Math.floor(1e3/e):5},e.unstable_getCurrentPriorityLevel=function(){return f},e.unstable_next=function(e){switch(f){case 1:case 2:case 3:var t=3;break;default:t=f}var n=f;f=t;try{return e()}finally{f=n}},e.unstable_requestPaint=function(){g=!0},e.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var n=f;f=e;try{return t()}finally{f=n}},e.unstable_scheduleCallback=function(r,i,a){var o=e.unstable_now();switch(typeof a==`object`&&a?(a=a.delay,a=typeof a==`number`&&0<a?o+a:o):a=o,r){case 1:var s=-1;break;case 2:s=250;break;case 5:s=1073741823;break;case 4:s=1e4;break;default:s=5e3}return s=a+s,r={id:u++,callback:i,priorityLevel:r,startTime:a,expirationTime:s,sortIndex:-1},a>o?(r.sortIndex=a,t(l,r),n(c)===null&&r===n(l)&&(h?(v(C),C=-1):h=!0,ne(x,a-o))):(r.sortIndex=s,t(c,r),m||p||(m=!0,S||(S=!0,O()))),r},e.unstable_shouldYield=E,e.unstable_wrapCallback=function(e){var t=f;return function(){var n=f;f=t;try{return e.apply(this,arguments)}finally{f=n}}}})),s=t(((e,t)=>{t.exports=o()})),c=t((e=>{var t=a();function n(e){var t=`https://react.dev/errors/`+e;if(1<arguments.length){t+=`?args[]=`+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+=`&args[]=`+encodeURIComponent(arguments[n])}return`Minified React error #`+e+`; visit `+t+` for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`}function r(){}var i={d:{f:r,r:function(){throw Error(n(522))},D:r,C:r,L:r,m:r,X:r,S:r,M:r},p:0,findDOMNode:null},o=Symbol.for(`react.portal`);function s(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:o,key:r==null?null:``+r,children:e,containerInfo:t,implementation:n}}var c=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function l(e,t){if(e===`font`)return``;if(typeof t==`string`)return t===`use-credentials`?t:``}e.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=i,e.createPortal=function(e,t){var r=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)throw Error(n(299));return s(e,t,null,r)},e.flushSync=function(e){var t=c.T,n=i.p;try{if(c.T=null,i.p=2,e)return e()}finally{c.T=t,i.p=n,i.d.f()}},e.preconnect=function(e,t){typeof e==`string`&&(t?(t=t.crossOrigin,t=typeof t==`string`?t===`use-credentials`?t:``:void 0):t=null,i.d.C(e,t))},e.prefetchDNS=function(e){typeof e==`string`&&i.d.D(e)},e.preinit=function(e,t){if(typeof e==`string`&&t&&typeof t.as==`string`){var n=t.as,r=l(n,t.crossOrigin),a=typeof t.integrity==`string`?t.integrity:void 0,o=typeof t.fetchPriority==`string`?t.fetchPriority:void 0;n===`style`?i.d.S(e,typeof t.precedence==`string`?t.precedence:void 0,{crossOrigin:r,integrity:a,fetchPriority:o}):n===`script`&&i.d.X(e,{crossOrigin:r,integrity:a,fetchPriority:o,nonce:typeof t.nonce==`string`?t.nonce:void 0})}},e.preinitModule=function(e,t){if(typeof e==`string`)if(typeof t==`object`&&t){if(t.as==null||t.as===`script`){var n=l(t.as,t.crossOrigin);i.d.M(e,{crossOrigin:n,integrity:typeof t.integrity==`string`?t.integrity:void 0,nonce:typeof t.nonce==`string`?t.nonce:void 0})}}else t??i.d.M(e)},e.preload=function(e,t){if(typeof e==`string`&&typeof t==`object`&&t&&typeof t.as==`string`){var n=t.as,r=l(n,t.crossOrigin);i.d.L(e,n,{crossOrigin:r,integrity:typeof t.integrity==`string`?t.integrity:void 0,nonce:typeof t.nonce==`string`?t.nonce:void 0,type:typeof t.type==`string`?t.type:void 0,fetchPriority:typeof t.fetchPriority==`string`?t.fetchPriority:void 0,referrerPolicy:typeof t.referrerPolicy==`string`?t.referrerPolicy:void 0,imageSrcSet:typeof t.imageSrcSet==`string`?t.imageSrcSet:void 0,imageSizes:typeof t.imageSizes==`string`?t.imageSizes:void 0,media:typeof t.media==`string`?t.media:void 0})}},e.preloadModule=function(e,t){if(typeof e==`string`)if(t){var n=l(t.as,t.crossOrigin);i.d.m(e,{as:typeof t.as==`string`&&t.as!==`script`?t.as:void 0,crossOrigin:n,integrity:typeof t.integrity==`string`?t.integrity:void 0})}else i.d.m(e)},e.requestFormReset=function(e){i.d.r(e)},e.unstable_batchedUpdates=function(e,t){return e(t)},e.useFormState=function(e,t,n){return c.H.useFormState(e,t,n)},e.useFormStatus=function(){return c.H.useHostTransitionStatus()},e.version=`19.2.5`})),l=t(((e,t)=>{function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>`u`||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!=`function`))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=c()})),u=t((e=>{var t=s(),n=a(),r=l();function i(e){var t=`https://react.dev/errors/`+e;if(1<arguments.length){t+=`?args[]=`+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+=`&args[]=`+encodeURIComponent(arguments[n])}return`Minified React error #`+e+`; visit `+t+` for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`}function o(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function c(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,t.flags&4098&&(n=t.return),e=t.return;while(e)}return t.tag===3?n:null}function u(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function d(e){if(e.tag===31){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function f(e){if(c(e)!==e)throw Error(i(188))}function p(e){var t=e.alternate;if(!t){if(t=c(e),t===null)throw Error(i(188));return t===e?e:null}for(var n=e,r=t;;){var a=n.return;if(a===null)break;var o=a.alternate;if(o===null){if(r=a.return,r!==null){n=r;continue}break}if(a.child===o.child){for(o=a.child;o;){if(o===n)return f(a),e;if(o===r)return f(a),t;o=o.sibling}throw Error(i(188))}if(n.return!==r.return)n=a,r=o;else{for(var s=!1,l=a.child;l;){if(l===n){s=!0,n=a,r=o;break}if(l===r){s=!0,r=a,n=o;break}l=l.sibling}if(!s){for(l=o.child;l;){if(l===n){s=!0,n=o,r=a;break}if(l===r){s=!0,r=o,n=a;break}l=l.sibling}if(!s)throw Error(i(189))}}if(n.alternate!==r)throw Error(i(190))}if(n.tag!==3)throw Error(i(188));return n.stateNode.current===n?e:t}function m(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=m(e),t!==null)return t;e=e.sibling}return null}var h=Object.assign,g=Symbol.for(`react.element`),_=Symbol.for(`react.transitional.element`),v=Symbol.for(`react.portal`),y=Symbol.for(`react.fragment`),b=Symbol.for(`react.strict_mode`),x=Symbol.for(`react.profiler`),S=Symbol.for(`react.consumer`),C=Symbol.for(`react.context`),w=Symbol.for(`react.forward_ref`),T=Symbol.for(`react.suspense`),E=Symbol.for(`react.suspense_list`),D=Symbol.for(`react.memo`),O=Symbol.for(`react.lazy`),ee=Symbol.for(`react.activity`),te=Symbol.for(`react.memo_cache_sentinel`),ne=Symbol.iterator;function re(e){return typeof e!=`object`||!e?null:(e=ne&&e[ne]||e[`@@iterator`],typeof e==`function`?e:null)}var ie=Symbol.for(`react.client.reference`);function k(e){if(e==null)return null;if(typeof e==`function`)return e.$$typeof===ie?null:e.displayName||e.name||null;if(typeof e==`string`)return e;switch(e){case y:return`Fragment`;case x:return`Profiler`;case b:return`StrictMode`;case T:return`Suspense`;case E:return`SuspenseList`;case ee:return`Activity`}if(typeof e==`object`)switch(e.$$typeof){case v:return`Portal`;case C:return e.displayName||`Context`;case S:return(e._context.displayName||`Context`)+`.Consumer`;case w:var t=e.render;return e=e.displayName,e||=(e=t.displayName||t.name||``,e===``?`ForwardRef`:`ForwardRef(`+e+`)`),e;case D:return t=e.displayName||null,t===null?k(e.type)||`Memo`:t;case O:t=e._payload,e=e._init;try{return k(e(t))}catch{}}return null}var ae=Array.isArray,A=n.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,j=r.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,oe={pending:!1,data:null,method:null,action:null},se=[],ce=-1;function le(e){return{current:e}}function M(e){0>ce||(e.current=se[ce],se[ce]=null,ce--)}function N(e,t){ce++,se[ce]=e.current,e.current=t}var ue=le(null),de=le(null),fe=le(null),pe=le(null);function me(e,t){switch(N(fe,t),N(de,e),N(ue,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?qd(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=qd(t),e=Jd(t,e);else switch(e){case`svg`:e=1;break;case`math`:e=2;break;default:e=0}}M(ue),N(ue,e)}function he(){M(ue),M(de),M(fe)}function ge(e){e.memoizedState!==null&&N(pe,e);var t=ue.current,n=Jd(t,e.type);t!==n&&(N(de,e),N(ue,n))}function _e(e){de.current===e&&(M(ue),M(de)),pe.current===e&&(M(pe),np._currentValue=oe)}var ve,ye;function be(e){if(ve===void 0)try{throw Error()}catch(e){var t=e.stack.trim().match(/\n( *(at )?)/);ve=t&&t[1]||``,ye=-1<e.stack.indexOf(`
    at`)?` (<anonymous>)`:-1<e.stack.indexOf(`@`)?`@unknown:0:0`:``}return`
`+ve+e+ye}var xe=!1;function Se(e,t){if(!e||xe)return``;xe=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var r={DetermineComponentFrameRoot:function(){try{if(t){var n=function(){throw Error()};if(Object.defineProperty(n.prototype,`props`,{set:function(){throw Error()}}),typeof Reflect==`object`&&Reflect.construct){try{Reflect.construct(n,[])}catch(e){var r=e}Reflect.construct(e,[],n)}else{try{n.call()}catch(e){r=e}e.call(n.prototype)}}else{try{throw Error()}catch(e){r=e}(n=e())&&typeof n.catch==`function`&&n.catch(function(){})}}catch(e){if(e&&r&&typeof e.stack==`string`)return[e.stack,r.stack]}return[null,null]}};r.DetermineComponentFrameRoot.displayName=`DetermineComponentFrameRoot`;var i=Object.getOwnPropertyDescriptor(r.DetermineComponentFrameRoot,`name`);i&&i.configurable&&Object.defineProperty(r.DetermineComponentFrameRoot,`name`,{value:`DetermineComponentFrameRoot`});var a=r.DetermineComponentFrameRoot(),o=a[0],s=a[1];if(o&&s){var c=o.split(`
`),l=s.split(`
`);for(i=r=0;r<c.length&&!c[r].includes(`DetermineComponentFrameRoot`);)r++;for(;i<l.length&&!l[i].includes(`DetermineComponentFrameRoot`);)i++;if(r===c.length||i===l.length)for(r=c.length-1,i=l.length-1;1<=r&&0<=i&&c[r]!==l[i];)i--;for(;1<=r&&0<=i;r--,i--)if(c[r]!==l[i]){if(r!==1||i!==1)do if(r--,i--,0>i||c[r]!==l[i]){var u=`
`+c[r].replace(` at new `,` at `);return e.displayName&&u.includes(`<anonymous>`)&&(u=u.replace(`<anonymous>`,e.displayName)),u}while(1<=r&&0<=i);break}}}finally{xe=!1,Error.prepareStackTrace=n}return(n=e?e.displayName||e.name:``)?be(n):``}function Ce(e,t){switch(e.tag){case 26:case 27:case 5:return be(e.type);case 16:return be(`Lazy`);case 13:return e.child!==t&&t!==null?be(`Suspense Fallback`):be(`Suspense`);case 19:return be(`SuspenseList`);case 0:case 15:return Se(e.type,!1);case 11:return Se(e.type.render,!1);case 1:return Se(e.type,!0);case 31:return be(`Activity`);default:return``}}function we(e){try{var t=``,n=null;do t+=Ce(e,n),n=e,e=e.return;while(e);return t}catch(e){return`
Error generating stack: `+e.message+`
`+e.stack}}var Te=Object.prototype.hasOwnProperty,Ee=t.unstable_scheduleCallback,De=t.unstable_cancelCallback,Oe=t.unstable_shouldYield,ke=t.unstable_requestPaint,Ae=t.unstable_now,je=t.unstable_getCurrentPriorityLevel,Me=t.unstable_ImmediatePriority,Ne=t.unstable_UserBlockingPriority,Pe=t.unstable_NormalPriority,Fe=t.unstable_LowPriority,Ie=t.unstable_IdlePriority,Le=t.log,Re=t.unstable_setDisableYieldValue,ze=null,P=null;function Be(e){if(typeof Le==`function`&&Re(e),P&&typeof P.setStrictMode==`function`)try{P.setStrictMode(ze,e)}catch{}}var Ve=Math.clz32?Math.clz32:We,He=Math.log,Ue=Math.LN2;function We(e){return e>>>=0,e===0?32:31-(He(e)/Ue|0)|0}var Ge=256,Ke=262144,qe=4194304;function Je(e){var t=e&42;if(t!==0)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function Ye(e,t,n){var r=e.pendingLanes;if(r===0)return 0;var i=0,a=e.suspendedLanes,o=e.pingedLanes;e=e.warmLanes;var s=r&134217727;return s===0?(s=r&~a,s===0?o===0?n||(n=r&~e,n!==0&&(i=Je(n))):i=Je(o):i=Je(s)):(r=s&~a,r===0?(o&=s,o===0?n||(n=s&~e,n!==0&&(i=Je(n))):i=Je(o)):i=Je(r)),i===0?0:t!==0&&t!==i&&(t&a)===0&&(a=i&-i,n=t&-t,a>=n||a===32&&n&4194048)?t:i}function Xe(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function F(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function Ze(){var e=qe;return qe<<=1,!(qe&62914560)&&(qe=4194304),e}function Qe(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function $e(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function et(e,t,n,r,i,a){var o=e.pendingLanes;e.pendingLanes=n,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=n,e.entangledLanes&=n,e.errorRecoveryDisabledLanes&=n,e.shellSuspendCounter=0;var s=e.entanglements,c=e.expirationTimes,l=e.hiddenUpdates;for(n=o&~n;0<n;){var u=31-Ve(n),d=1<<u;s[u]=0,c[u]=-1;var f=l[u];if(f!==null)for(l[u]=null,u=0;u<f.length;u++){var p=f[u];p!==null&&(p.lane&=-536870913)}n&=~d}r!==0&&tt(e,r,0),a!==0&&i===0&&e.tag!==0&&(e.suspendedLanes|=a&~(o&~t))}function tt(e,t,n){e.pendingLanes|=t,e.suspendedLanes&=~t;var r=31-Ve(t);e.entangledLanes|=t,e.entanglements[r]=e.entanglements[r]|1073741824|n&261930}function nt(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-Ve(n),i=1<<r;i&t|e[r]&t&&(e[r]|=t),n&=~i}}function rt(e,t){var n=t&-t;return n=n&42?1:it(n),(n&(e.suspendedLanes|t))===0?n:0}function it(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function at(e){return e&=-e,2<e?8<e?e&134217727?32:268435456:8:2}function ot(){var e=j.p;return e===0?(e=window.event,e===void 0?32:vp(e.type)):e}function st(e,t){var n=j.p;try{return j.p=e,t()}finally{j.p=n}}var ct=Math.random().toString(36).slice(2),lt=`__reactFiber$`+ct,ut=`__reactProps$`+ct,dt=`__reactContainer$`+ct,ft=`__reactEvents$`+ct,pt=`__reactListeners$`+ct,mt=`__reactHandles$`+ct,ht=`__reactResources$`+ct,gt=`__reactMarker$`+ct;function _t(e){delete e[lt],delete e[ut],delete e[ft],delete e[pt],delete e[mt]}function vt(e){var t=e[lt];if(t)return t;for(var n=e.parentNode;n;){if(t=n[dt]||n[lt]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=gf(e);e!==null;){if(n=e[lt])return n;e=gf(e)}return t}e=n,n=e.parentNode}return null}function yt(e){if(e=e[lt]||e[dt]){var t=e.tag;if(t===5||t===6||t===13||t===31||t===26||t===27||t===3)return e}return null}function bt(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(i(33))}function xt(e){var t=e[ht];return t||=e[ht]={hoistableStyles:new Map,hoistableScripts:new Map},t}function St(e){e[gt]=!0}var Ct=new Set,wt={};function Tt(e,t){Et(e,t),Et(e+`Capture`,t)}function Et(e,t){for(wt[e]=t,e=0;e<t.length;e++)Ct.add(t[e])}var Dt=RegExp(`^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$`),Ot={},kt={};function At(e){return Te.call(kt,e)?!0:Te.call(Ot,e)?!1:Dt.test(e)?kt[e]=!0:(Ot[e]=!0,!1)}function jt(e,t,n){if(At(t))if(n===null)e.removeAttribute(t);else{switch(typeof n){case`undefined`:case`function`:case`symbol`:e.removeAttribute(t);return;case`boolean`:var r=t.toLowerCase().slice(0,5);if(r!==`data-`&&r!==`aria-`){e.removeAttribute(t);return}}e.setAttribute(t,``+n)}}function Mt(e,t,n){if(n===null)e.removeAttribute(t);else{switch(typeof n){case`undefined`:case`function`:case`symbol`:case`boolean`:e.removeAttribute(t);return}e.setAttribute(t,``+n)}}function Nt(e,t,n,r){if(r===null)e.removeAttribute(n);else{switch(typeof r){case`undefined`:case`function`:case`symbol`:case`boolean`:e.removeAttribute(n);return}e.setAttributeNS(t,n,``+r)}}function Pt(e){switch(typeof e){case`bigint`:case`boolean`:case`number`:case`string`:case`undefined`:return e;case`object`:return e;default:return``}}function Ft(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()===`input`&&(t===`checkbox`||t===`radio`)}function It(e,t,n){var r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t);if(!e.hasOwnProperty(t)&&r!==void 0&&typeof r.get==`function`&&typeof r.set==`function`){var i=r.get,a=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(e){n=``+e,a.call(this,e)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return n},setValue:function(e){n=``+e},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Lt(e){if(!e._valueTracker){var t=Ft(e)?`checked`:`value`;e._valueTracker=It(e,t,``+e[t])}}function Rt(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r=``;return e&&(r=Ft(e)?e.checked?`true`:`false`:e.value),e=r,e===n?!1:(t.setValue(e),!0)}function zt(e){if(e||=typeof document<`u`?document:void 0,e===void 0)return null;try{return e.activeElement||e.body}catch{return e.body}}var Bt=/[\n"\\]/g;function Vt(e){return e.replace(Bt,function(e){return`\\`+e.charCodeAt(0).toString(16)+` `})}function Ht(e,t,n,r,i,a,o,s){e.name=``,o!=null&&typeof o!=`function`&&typeof o!=`symbol`&&typeof o!=`boolean`?e.type=o:e.removeAttribute(`type`),t==null?o!==`submit`&&o!==`reset`||e.removeAttribute(`value`):o===`number`?(t===0&&e.value===``||e.value!=t)&&(e.value=``+Pt(t)):e.value!==``+Pt(t)&&(e.value=``+Pt(t)),t==null?n==null?r!=null&&e.removeAttribute(`value`):Wt(e,o,Pt(n)):Wt(e,o,Pt(t)),i==null&&a!=null&&(e.defaultChecked=!!a),i!=null&&(e.checked=i&&typeof i!=`function`&&typeof i!=`symbol`),s!=null&&typeof s!=`function`&&typeof s!=`symbol`&&typeof s!=`boolean`?e.name=``+Pt(s):e.removeAttribute(`name`)}function Ut(e,t,n,r,i,a,o,s){if(a!=null&&typeof a!=`function`&&typeof a!=`symbol`&&typeof a!=`boolean`&&(e.type=a),t!=null||n!=null){if(!(a!==`submit`&&a!==`reset`||t!=null)){Lt(e);return}n=n==null?``:``+Pt(n),t=t==null?n:``+Pt(t),s||t===e.value||(e.value=t),e.defaultValue=t}r??=i,r=typeof r!=`function`&&typeof r!=`symbol`&&!!r,e.checked=s?e.checked:!!r,e.defaultChecked=!!r,o!=null&&typeof o!=`function`&&typeof o!=`symbol`&&typeof o!=`boolean`&&(e.name=o),Lt(e)}function Wt(e,t,n){t===`number`&&zt(e.ownerDocument)===e||e.defaultValue===``+n||(e.defaultValue=``+n)}function Gt(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i<n.length;i++)t[`$`+n[i]]=!0;for(n=0;n<e.length;n++)i=t.hasOwnProperty(`$`+e[n].value),e[n].selected!==i&&(e[n].selected=i),i&&r&&(e[n].defaultSelected=!0)}else{for(n=``+Pt(n),t=null,i=0;i<e.length;i++){if(e[i].value===n){e[i].selected=!0,r&&(e[i].defaultSelected=!0);return}t!==null||e[i].disabled||(t=e[i])}t!==null&&(t.selected=!0)}}function Kt(e,t,n){if(t!=null&&(t=``+Pt(t),t!==e.value&&(e.value=t),n==null)){e.defaultValue!==t&&(e.defaultValue=t);return}e.defaultValue=n==null?``:``+Pt(n)}function qt(e,t,n,r){if(t==null){if(r!=null){if(n!=null)throw Error(i(92));if(ae(r)){if(1<r.length)throw Error(i(93));r=r[0]}n=r}n??=``,t=n}n=Pt(t),e.defaultValue=n,r=e.textContent,r===n&&r!==``&&r!==null&&(e.value=r),Lt(e)}function Jt(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Yt=new Set(`animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp`.split(` `));function Xt(e,t,n){var r=t.indexOf(`--`)===0;n==null||typeof n==`boolean`||n===``?r?e.setProperty(t,``):t===`float`?e.cssFloat=``:e[t]=``:r?e.setProperty(t,n):typeof n!=`number`||n===0||Yt.has(t)?t===`float`?e.cssFloat=n:e[t]=(``+n).trim():e[t]=n+`px`}function Zt(e,t,n){if(t!=null&&typeof t!=`object`)throw Error(i(62));if(e=e.style,n!=null){for(var r in n)!n.hasOwnProperty(r)||t!=null&&t.hasOwnProperty(r)||(r.indexOf(`--`)===0?e.setProperty(r,``):r===`float`?e.cssFloat=``:e[r]=``);for(var a in t)r=t[a],t.hasOwnProperty(a)&&n[a]!==r&&Xt(e,a,r)}else for(var o in t)t.hasOwnProperty(o)&&Xt(e,o,t[o])}function Qt(e){if(e.indexOf(`-`)===-1)return!1;switch(e){case`annotation-xml`:case`color-profile`:case`font-face`:case`font-face-src`:case`font-face-uri`:case`font-face-format`:case`font-face-name`:case`missing-glyph`:return!1;default:return!0}}var $t=new Map([[`acceptCharset`,`accept-charset`],[`htmlFor`,`for`],[`httpEquiv`,`http-equiv`],[`crossOrigin`,`crossorigin`],[`accentHeight`,`accent-height`],[`alignmentBaseline`,`alignment-baseline`],[`arabicForm`,`arabic-form`],[`baselineShift`,`baseline-shift`],[`capHeight`,`cap-height`],[`clipPath`,`clip-path`],[`clipRule`,`clip-rule`],[`colorInterpolation`,`color-interpolation`],[`colorInterpolationFilters`,`color-interpolation-filters`],[`colorProfile`,`color-profile`],[`colorRendering`,`color-rendering`],[`dominantBaseline`,`dominant-baseline`],[`enableBackground`,`enable-background`],[`fillOpacity`,`fill-opacity`],[`fillRule`,`fill-rule`],[`floodColor`,`flood-color`],[`floodOpacity`,`flood-opacity`],[`fontFamily`,`font-family`],[`fontSize`,`font-size`],[`fontSizeAdjust`,`font-size-adjust`],[`fontStretch`,`font-stretch`],[`fontStyle`,`font-style`],[`fontVariant`,`font-variant`],[`fontWeight`,`font-weight`],[`glyphName`,`glyph-name`],[`glyphOrientationHorizontal`,`glyph-orientation-horizontal`],[`glyphOrientationVertical`,`glyph-orientation-vertical`],[`horizAdvX`,`horiz-adv-x`],[`horizOriginX`,`horiz-origin-x`],[`imageRendering`,`image-rendering`],[`letterSpacing`,`letter-spacing`],[`lightingColor`,`lighting-color`],[`markerEnd`,`marker-end`],[`markerMid`,`marker-mid`],[`markerStart`,`marker-start`],[`overlinePosition`,`overline-position`],[`overlineThickness`,`overline-thickness`],[`paintOrder`,`paint-order`],[`panose-1`,`panose-1`],[`pointerEvents`,`pointer-events`],[`renderingIntent`,`rendering-intent`],[`shapeRendering`,`shape-rendering`],[`stopColor`,`stop-color`],[`stopOpacity`,`stop-opacity`],[`strikethroughPosition`,`strikethrough-position`],[`strikethroughThickness`,`strikethrough-thickness`],[`strokeDasharray`,`stroke-dasharray`],[`strokeDashoffset`,`stroke-dashoffset`],[`strokeLinecap`,`stroke-linecap`],[`strokeLinejoin`,`stroke-linejoin`],[`strokeMiterlimit`,`stroke-miterlimit`],[`strokeOpacity`,`stroke-opacity`],[`strokeWidth`,`stroke-width`],[`textAnchor`,`text-anchor`],[`textDecoration`,`text-decoration`],[`textRendering`,`text-rendering`],[`transformOrigin`,`transform-origin`],[`underlinePosition`,`underline-position`],[`underlineThickness`,`underline-thickness`],[`unicodeBidi`,`unicode-bidi`],[`unicodeRange`,`unicode-range`],[`unitsPerEm`,`units-per-em`],[`vAlphabetic`,`v-alphabetic`],[`vHanging`,`v-hanging`],[`vIdeographic`,`v-ideographic`],[`vMathematical`,`v-mathematical`],[`vectorEffect`,`vector-effect`],[`vertAdvY`,`vert-adv-y`],[`vertOriginX`,`vert-origin-x`],[`vertOriginY`,`vert-origin-y`],[`wordSpacing`,`word-spacing`],[`writingMode`,`writing-mode`],[`xmlnsXlink`,`xmlns:xlink`],[`xHeight`,`x-height`]]),en=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function tn(e){return en.test(``+e)?`javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')`:e}function nn(){}var rn=null;function an(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var on=null,sn=null;function cn(e){var t=yt(e);if(t&&(e=t.stateNode)){var n=e[ut]||null;a:switch(e=t.stateNode,t.type){case`input`:if(Ht(e,n.value,n.defaultValue,n.defaultValue,n.checked,n.defaultChecked,n.type,n.name),t=n.name,n.type===`radio`&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll(`input[name="`+Vt(``+t)+`"][type="radio"]`),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var a=r[ut]||null;if(!a)throw Error(i(90));Ht(r,a.value,a.defaultValue,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name)}}for(t=0;t<n.length;t++)r=n[t],r.form===e.form&&Rt(r)}break a;case`textarea`:Kt(e,n.value,n.defaultValue);break a;case`select`:t=n.value,t!=null&&Gt(e,!!n.multiple,t,!1)}}}var ln=!1;function un(e,t,n){if(ln)return e(t,n);ln=!0;try{return e(t)}finally{if(ln=!1,(on!==null||sn!==null)&&(Eu(),on&&(t=on,e=sn,sn=on=null,cn(t),e)))for(t=0;t<e.length;t++)cn(e[t])}}function dn(e,t){var n=e.stateNode;if(n===null)return null;var r=n[ut]||null;if(r===null)return null;n=r[t];a:switch(t){case`onClick`:case`onClickCapture`:case`onDoubleClick`:case`onDoubleClickCapture`:case`onMouseDown`:case`onMouseDownCapture`:case`onMouseMove`:case`onMouseMoveCapture`:case`onMouseUp`:case`onMouseUpCapture`:case`onMouseEnter`:(r=!r.disabled)||(e=e.type,r=!(e===`button`||e===`input`||e===`select`||e===`textarea`)),e=!r;break a;default:e=!1}if(e)return null;if(n&&typeof n!=`function`)throw Error(i(231,t,typeof n));return n}var fn=!(typeof window>`u`||window.document===void 0||window.document.createElement===void 0),pn=!1;if(fn)try{var mn={};Object.defineProperty(mn,`passive`,{get:function(){pn=!0}}),window.addEventListener(`test`,mn,mn),window.removeEventListener(`test`,mn,mn)}catch{pn=!1}var hn=null,gn=null,_n=null;function vn(){if(_n)return _n;var e,t=gn,n=t.length,r,i=`value`in hn?hn.value:hn.textContent,a=i.length;for(e=0;e<n&&t[e]===i[e];e++);var o=n-e;for(r=1;r<=o&&t[n-r]===i[a-r];r++);return _n=i.slice(e,1<r?1-r:void 0)}function yn(e){var t=e.keyCode;return`charCode`in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function bn(){return!0}function xn(){return!1}function Sn(e){function t(t,n,r,i,a){for(var o in this._reactName=t,this._targetInst=r,this.type=n,this.nativeEvent=i,this.target=a,this.currentTarget=null,e)e.hasOwnProperty(o)&&(t=e[o],this[o]=t?t(i):i[o]);return this.isDefaultPrevented=(i.defaultPrevented==null?!1===i.returnValue:i.defaultPrevented)?bn:xn,this.isPropagationStopped=xn,this}return h(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var e=this.nativeEvent;e&&(e.preventDefault?e.preventDefault():typeof e.returnValue!=`unknown`&&(e.returnValue=!1),this.isDefaultPrevented=bn)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():typeof e.cancelBubble!=`unknown`&&(e.cancelBubble=!0),this.isPropagationStopped=bn)},persist:function(){},isPersistent:bn}),t}var Cn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},wn=Sn(Cn),Tn=h({},Cn,{view:0,detail:0}),En=Sn(Tn),Dn,On,kn,An=h({},Tn,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Vn,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return`movementX`in e?e.movementX:(e!==kn&&(kn&&e.type===`mousemove`?(Dn=e.screenX-kn.screenX,On=e.screenY-kn.screenY):On=Dn=0,kn=e),Dn)},movementY:function(e){return`movementY`in e?e.movementY:On}}),jn=Sn(An),Mn=Sn(h({},An,{dataTransfer:0})),Nn=Sn(h({},Tn,{relatedTarget:0})),Pn=Sn(h({},Cn,{animationName:0,elapsedTime:0,pseudoElement:0})),Fn=Sn(h({},Cn,{clipboardData:function(e){return`clipboardData`in e?e.clipboardData:window.clipboardData}})),In=Sn(h({},Cn,{data:0})),Ln={Esc:`Escape`,Spacebar:` `,Left:`ArrowLeft`,Up:`ArrowUp`,Right:`ArrowRight`,Down:`ArrowDown`,Del:`Delete`,Win:`OS`,Menu:`ContextMenu`,Apps:`ContextMenu`,Scroll:`ScrollLock`,MozPrintableKey:`Unidentified`},Rn={8:`Backspace`,9:`Tab`,12:`Clear`,13:`Enter`,16:`Shift`,17:`Control`,18:`Alt`,19:`Pause`,20:`CapsLock`,27:`Escape`,32:` `,33:`PageUp`,34:`PageDown`,35:`End`,36:`Home`,37:`ArrowLeft`,38:`ArrowUp`,39:`ArrowRight`,40:`ArrowDown`,45:`Insert`,46:`Delete`,112:`F1`,113:`F2`,114:`F3`,115:`F4`,116:`F5`,117:`F6`,118:`F7`,119:`F8`,120:`F9`,121:`F10`,122:`F11`,123:`F12`,144:`NumLock`,145:`ScrollLock`,224:`Meta`},zn={Alt:`altKey`,Control:`ctrlKey`,Meta:`metaKey`,Shift:`shiftKey`};function Bn(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=zn[e])?!!t[e]:!1}function Vn(){return Bn}var Hn=Sn(h({},Tn,{key:function(e){if(e.key){var t=Ln[e.key]||e.key;if(t!==`Unidentified`)return t}return e.type===`keypress`?(e=yn(e),e===13?`Enter`:String.fromCharCode(e)):e.type===`keydown`||e.type===`keyup`?Rn[e.keyCode]||`Unidentified`:``},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Vn,charCode:function(e){return e.type===`keypress`?yn(e):0},keyCode:function(e){return e.type===`keydown`||e.type===`keyup`?e.keyCode:0},which:function(e){return e.type===`keypress`?yn(e):e.type===`keydown`||e.type===`keyup`?e.keyCode:0}})),Un=Sn(h({},An,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0})),Wn=Sn(h({},Tn,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Vn})),Gn=Sn(h({},Cn,{propertyName:0,elapsedTime:0,pseudoElement:0})),Kn=Sn(h({},An,{deltaX:function(e){return`deltaX`in e?e.deltaX:`wheelDeltaX`in e?-e.wheelDeltaX:0},deltaY:function(e){return`deltaY`in e?e.deltaY:`wheelDeltaY`in e?-e.wheelDeltaY:`wheelDelta`in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0})),qn=Sn(h({},Cn,{newState:0,oldState:0})),Jn=[9,13,27,32],Yn=fn&&`CompositionEvent`in window,Xn=null;fn&&`documentMode`in document&&(Xn=document.documentMode);var Zn=fn&&`TextEvent`in window&&!Xn,Qn=fn&&(!Yn||Xn&&8<Xn&&11>=Xn),$n=` `,er=!1;function tr(e,t){switch(e){case`keyup`:return Jn.indexOf(t.keyCode)!==-1;case`keydown`:return t.keyCode!==229;case`keypress`:case`mousedown`:case`focusout`:return!0;default:return!1}}function nr(e){return e=e.detail,typeof e==`object`&&`data`in e?e.data:null}var rr=!1;function ir(e,t){switch(e){case`compositionend`:return nr(t);case`keypress`:return t.which===32?(er=!0,$n):null;case`textInput`:return e=t.data,e===$n&&er?null:e;default:return null}}function ar(e,t){if(rr)return e===`compositionend`||!Yn&&tr(e,t)?(e=vn(),_n=gn=hn=null,rr=!1,e):null;switch(e){case`paste`:return null;case`keypress`:if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case`compositionend`:return Qn&&t.locale!==`ko`?null:t.data;default:return null}}var or={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function sr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t===`input`?!!or[e.type]:t===`textarea`}function cr(e,t,n,r){on?sn?sn.push(r):sn=[r]:on=r,t=jd(t,`onChange`),0<t.length&&(n=new wn(`onChange`,`change`,null,n,r),e.push({event:n,listeners:t}))}var lr=null,ur=null;function dr(e){Td(e,0)}function fr(e){if(Rt(bt(e)))return e}function pr(e,t){if(e===`change`)return t}var mr=!1;if(fn){var hr;if(fn){var gr=`oninput`in document;if(!gr){var _r=document.createElement(`div`);_r.setAttribute(`oninput`,`return;`),gr=typeof _r.oninput==`function`}hr=gr}else hr=!1;mr=hr&&(!document.documentMode||9<document.documentMode)}function vr(){lr&&(lr.detachEvent(`onpropertychange`,yr),ur=lr=null)}function yr(e){if(e.propertyName===`value`&&fr(ur)){var t=[];cr(t,ur,e,an(e)),un(dr,t)}}function br(e,t,n){e===`focusin`?(vr(),lr=t,ur=n,lr.attachEvent(`onpropertychange`,yr)):e===`focusout`&&vr()}function xr(e){if(e===`selectionchange`||e===`keyup`||e===`keydown`)return fr(ur)}function Sr(e,t){if(e===`click`)return fr(t)}function Cr(e,t){if(e===`input`||e===`change`)return fr(t)}function wr(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}var Tr=typeof Object.is==`function`?Object.is:wr;function Er(e,t){if(Tr(e,t))return!0;if(typeof e!=`object`||!e||typeof t!=`object`||!t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var i=n[r];if(!Te.call(t,i)||!Tr(e[i],t[i]))return!1}return!0}function Dr(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Or(e,t){var n=Dr(e);e=0;for(var r;n;){if(n.nodeType===3){if(r=e+n.textContent.length,e<=t&&r>=t)return{node:n,offset:t-e};e=r}a:{for(;n;){if(n.nextSibling){n=n.nextSibling;break a}n=n.parentNode}n=void 0}n=Dr(n)}}function kr(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?kr(e,t.parentNode):`contains`in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Ar(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=zt(e.document);t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href==`string`}catch{n=!1}if(n)e=t.contentWindow;else break;t=zt(e.document)}return t}function jr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t===`input`&&(e.type===`text`||e.type===`search`||e.type===`tel`||e.type===`url`||e.type===`password`)||t===`textarea`||e.contentEditable===`true`)}var Mr=fn&&`documentMode`in document&&11>=document.documentMode,Nr=null,Pr=null,Fr=null,Ir=!1;function Lr(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Ir||Nr==null||Nr!==zt(r)||(r=Nr,`selectionStart`in r&&jr(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Fr&&Er(Fr,r)||(Fr=r,r=jd(Pr,`onSelect`),0<r.length&&(t=new wn(`onSelect`,`select`,null,t,n),e.push({event:t,listeners:r}),t.target=Nr)))}function Rr(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n[`Webkit`+e]=`webkit`+t,n[`Moz`+e]=`moz`+t,n}var zr={animationend:Rr(`Animation`,`AnimationEnd`),animationiteration:Rr(`Animation`,`AnimationIteration`),animationstart:Rr(`Animation`,`AnimationStart`),transitionrun:Rr(`Transition`,`TransitionRun`),transitionstart:Rr(`Transition`,`TransitionStart`),transitioncancel:Rr(`Transition`,`TransitionCancel`),transitionend:Rr(`Transition`,`TransitionEnd`)},Br={},Vr={};fn&&(Vr=document.createElement(`div`).style,`AnimationEvent`in window||(delete zr.animationend.animation,delete zr.animationiteration.animation,delete zr.animationstart.animation),`TransitionEvent`in window||delete zr.transitionend.transition);function Hr(e){if(Br[e])return Br[e];if(!zr[e])return e;var t=zr[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in Vr)return Br[e]=t[n];return e}var Ur=Hr(`animationend`),Wr=Hr(`animationiteration`),Gr=Hr(`animationstart`),Kr=Hr(`transitionrun`),qr=Hr(`transitionstart`),Jr=Hr(`transitioncancel`),Yr=Hr(`transitionend`),Xr=new Map,Zr=`abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel`.split(` `);Zr.push(`scrollEnd`);function Qr(e,t){Xr.set(e,t),Tt(t,[e])}var $r=typeof reportError==`function`?reportError:function(e){if(typeof window==`object`&&typeof window.ErrorEvent==`function`){var t=new window.ErrorEvent(`error`,{bubbles:!0,cancelable:!0,message:typeof e==`object`&&e&&typeof e.message==`string`?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process==`object`&&typeof process.emit==`function`){process.emit(`uncaughtException`,e);return}console.error(e)},ei=[],ti=0,ni=0;function ri(){for(var e=ti,t=ni=ti=0;t<e;){var n=ei[t];ei[t++]=null;var r=ei[t];ei[t++]=null;var i=ei[t];ei[t++]=null;var a=ei[t];if(ei[t++]=null,r!==null&&i!==null){var o=r.pending;o===null?i.next=i:(i.next=o.next,o.next=i),r.pending=i}a!==0&&si(n,i,a)}}function ii(e,t,n,r){ei[ti++]=e,ei[ti++]=t,ei[ti++]=n,ei[ti++]=r,ni|=r,e.lanes|=r,e=e.alternate,e!==null&&(e.lanes|=r)}function ai(e,t,n,r){return ii(e,t,n,r),ci(e)}function oi(e,t){return ii(e,null,null,t),ci(e)}function si(e,t,n){e.lanes|=n;var r=e.alternate;r!==null&&(r.lanes|=n);for(var i=!1,a=e.return;a!==null;)a.childLanes|=n,r=a.alternate,r!==null&&(r.childLanes|=n),a.tag===22&&(e=a.stateNode,e===null||e._visibility&1||(i=!0)),e=a,a=a.return;return e.tag===3?(a=e.stateNode,i&&t!==null&&(i=31-Ve(n),e=a.hiddenUpdates,r=e[i],r===null?e[i]=[t]:r.push(t),t.lane=n|536870912),a):null}function ci(e){if(50<_u)throw _u=0,vu=null,Error(i(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}var li={};function ui(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function di(e,t,n,r){return new ui(e,t,n,r)}function fi(e){return e=e.prototype,!(!e||!e.isReactComponent)}function pi(e,t){var n=e.alternate;return n===null?(n=di(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&65011712,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n.refCleanup=e.refCleanup,n}function mi(e,t){e.flags&=65011714;var n=e.alternate;return n===null?(e.childLanes=0,e.lanes=t,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=n.childLanes,e.lanes=n.lanes,e.child=n.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=n.memoizedProps,e.memoizedState=n.memoizedState,e.updateQueue=n.updateQueue,e.type=n.type,t=n.dependencies,e.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function hi(e,t,n,r,a,o){var s=0;if(r=e,typeof e==`function`)fi(e)&&(s=1);else if(typeof e==`string`)s=qf(e,n,ue.current)?26:e===`html`||e===`head`||e===`body`?27:5;else a:switch(e){case ee:return e=di(31,n,t,a),e.elementType=ee,e.lanes=o,e;case y:return gi(n.children,a,o,t);case b:s=8,a|=24;break;case x:return e=di(12,n,t,a|2),e.elementType=x,e.lanes=o,e;case T:return e=di(13,n,t,a),e.elementType=T,e.lanes=o,e;case E:return e=di(19,n,t,a),e.elementType=E,e.lanes=o,e;default:if(typeof e==`object`&&e)switch(e.$$typeof){case C:s=10;break a;case S:s=9;break a;case w:s=11;break a;case D:s=14;break a;case O:s=16,r=null;break a}s=29,n=Error(i(130,e===null?`null`:typeof e,``)),r=null}return t=di(s,n,t,a),t.elementType=e,t.type=r,t.lanes=o,t}function gi(e,t,n,r){return e=di(7,e,r,t),e.lanes=n,e}function _i(e,t,n){return e=di(6,e,null,t),e.lanes=n,e}function vi(e){var t=di(18,null,null,0);return t.stateNode=e,t}function yi(e,t,n){return t=di(4,e.children===null?[]:e.children,e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var bi=new WeakMap;function xi(e,t){if(typeof e==`object`&&e){var n=bi.get(e);return n===void 0?(t={value:e,source:t,stack:we(t)},bi.set(e,t),t):n}return{value:e,source:t,stack:we(t)}}var Si=[],Ci=0,wi=null,Ti=0,Ei=[],Di=0,Oi=null,ki=1,Ai=``;function ji(e,t){Si[Ci++]=Ti,Si[Ci++]=wi,wi=e,Ti=t}function Mi(e,t,n){Ei[Di++]=ki,Ei[Di++]=Ai,Ei[Di++]=Oi,Oi=e;var r=ki;e=Ai;var i=32-Ve(r)-1;r&=~(1<<i),n+=1;var a=32-Ve(t)+i;if(30<a){var o=i-i%5;a=(r&(1<<o)-1).toString(32),r>>=o,i-=o,ki=1<<32-Ve(t)+i|n<<i|r,Ai=a+e}else ki=1<<a|n<<i|r,Ai=e}function Ni(e){e.return!==null&&(ji(e,1),Mi(e,1,0))}function Pi(e){for(;e===wi;)wi=Si[--Ci],Si[Ci]=null,Ti=Si[--Ci],Si[Ci]=null;for(;e===Oi;)Oi=Ei[--Di],Ei[Di]=null,Ai=Ei[--Di],Ei[Di]=null,ki=Ei[--Di],Ei[Di]=null}function Fi(e,t){Ei[Di++]=ki,Ei[Di++]=Ai,Ei[Di++]=Oi,ki=t.id,Ai=t.overflow,Oi=e}var Ii=null,Li=null,I=!1,Ri=null,zi=!1,Bi=Error(i(519));function Vi(e){throw qi(xi(Error(i(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?`text`:`HTML`,``)),e)),Bi}function Hi(e){var t=e.stateNode,n=e.type,r=e.memoizedProps;switch(t[lt]=e,t[ut]=r,n){case`dialog`:K(`cancel`,t),K(`close`,t);break;case`iframe`:case`object`:case`embed`:K(`load`,t);break;case`video`:case`audio`:for(n=0;n<Cd.length;n++)K(Cd[n],t);break;case`source`:K(`error`,t);break;case`img`:case`image`:case`link`:K(`error`,t),K(`load`,t);break;case`details`:K(`toggle`,t);break;case`input`:K(`invalid`,t),Ut(t,r.value,r.defaultValue,r.checked,r.defaultChecked,r.type,r.name,!0);break;case`select`:K(`invalid`,t);break;case`textarea`:K(`invalid`,t),qt(t,r.value,r.defaultValue,r.children)}n=r.children,typeof n!=`string`&&typeof n!=`number`&&typeof n!=`bigint`||t.textContent===``+n||!0===r.suppressHydrationWarning||Ld(t.textContent,n)?(r.popover!=null&&(K(`beforetoggle`,t),K(`toggle`,t)),r.onScroll!=null&&K(`scroll`,t),r.onScrollEnd!=null&&K(`scrollend`,t),r.onClick!=null&&(t.onclick=nn),t=!0):t=!1,t||Vi(e,!0)}function Ui(e){for(Ii=e.return;Ii;)switch(Ii.tag){case 5:case 31:case 13:zi=!1;return;case 27:case 3:zi=!0;return;default:Ii=Ii.return}}function Wi(e){if(e!==Ii)return!1;if(!I)return Ui(e),I=!0,!1;var t=e.tag,n;if((n=t!==3&&t!==27)&&((n=t===5)&&(n=e.type,n=!(n!==`form`&&n!==`button`)||Yd(e.type,e.memoizedProps)),n=!n),n&&Li&&Vi(e),Ui(e),t===13){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(317));Li=hf(e)}else if(t===31){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(317));Li=hf(e)}else t===27?(t=Li,rf(e.type)?(e=mf,mf=null,Li=e):Li=t):Li=Ii?J(e.stateNode.nextSibling):null;return!0}function Gi(){Li=Ii=null,I=!1}function Ki(){var e=Ri;return e!==null&&(iu===null?iu=e:iu.push.apply(iu,e),Ri=null),e}function qi(e){Ri===null?Ri=[e]:Ri.push(e)}var Ji=le(null),Yi=null,Xi=null;function Zi(e,t,n){N(Ji,t._currentValue),t._currentValue=n}function Qi(e){e._currentValue=Ji.current,M(Ji)}function $i(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)===t?r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t):(e.childLanes|=t,r!==null&&(r.childLanes|=t)),e===n)break;e=e.return}}function ea(e,t,n,r){var a=e.child;for(a!==null&&(a.return=e);a!==null;){var o=a.dependencies;if(o!==null){var s=a.child;o=o.firstContext;a:for(;o!==null;){var c=o;o=a;for(var l=0;l<t.length;l++)if(c.context===t[l]){o.lanes|=n,c=o.alternate,c!==null&&(c.lanes|=n),$i(o.return,n,e),r||(s=null);break a}o=c.next}}else if(a.tag===18){if(s=a.return,s===null)throw Error(i(341));s.lanes|=n,o=s.alternate,o!==null&&(o.lanes|=n),$i(s,n,e),s=null}else s=a.child;if(s!==null)s.return=a;else for(s=a;s!==null;){if(s===e){s=null;break}if(a=s.sibling,a!==null){a.return=s.return,s=a;break}s=s.return}a=s}}function ta(e,t,n,r){e=null;for(var a=t,o=!1;a!==null;){if(!o){if(a.flags&524288)o=!0;else if(a.flags&262144)break}if(a.tag===10){var s=a.alternate;if(s===null)throw Error(i(387));if(s=s.memoizedProps,s!==null){var c=a.type;Tr(a.pendingProps.value,s.value)||(e===null?e=[c]:e.push(c))}}else if(a===pe.current){if(s=a.alternate,s===null)throw Error(i(387));s.memoizedState.memoizedState!==a.memoizedState.memoizedState&&(e===null?e=[np]:e.push(np))}a=a.return}e!==null&&ea(t,e,n,r),t.flags|=262144}function na(e){for(e=e.firstContext;e!==null;){if(!Tr(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function ra(e){Yi=e,Xi=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function ia(e){return oa(Yi,e)}function aa(e,t){return Yi===null&&ra(e),oa(e,t)}function oa(e,t){var n=t._currentValue;if(t={context:t,memoizedValue:n,next:null},Xi===null){if(e===null)throw Error(i(308));Xi=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else Xi=Xi.next=t;return n}var sa=typeof AbortController<`u`?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(t,n){e.push(n)}};this.abort=function(){t.aborted=!0,e.forEach(function(e){return e()})}},ca=t.unstable_scheduleCallback,la=t.unstable_NormalPriority,ua={$$typeof:C,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function da(){return{controller:new sa,data:new Map,refCount:0}}function fa(e){e.refCount--,e.refCount===0&&ca(la,function(){e.controller.abort()})}var pa=null,ma=0,ha=0,ga=null;function _a(e,t){if(pa===null){var n=pa=[];ma=0,ha=_d(),ga={status:`pending`,value:void 0,then:function(e){n.push(e)}}}return ma++,t.then(va,va),t}function va(){if(--ma===0&&pa!==null){ga!==null&&(ga.status=`fulfilled`);var e=pa;pa=null,ha=0,ga=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function ya(e,t){var n=[],r={status:`pending`,value:null,reason:null,then:function(e){n.push(e)}};return e.then(function(){r.status=`fulfilled`,r.value=t;for(var e=0;e<n.length;e++)(0,n[e])(t)},function(e){for(r.status=`rejected`,r.reason=e,e=0;e<n.length;e++)(0,n[e])(void 0)}),r}var ba=A.S;A.S=function(e,t){su=Ae(),typeof t==`object`&&t&&typeof t.then==`function`&&_a(e,t),ba!==null&&ba(e,t)};var xa=le(null);function Sa(){var e=xa.current;return e===null?Gl.pooledCache:e}function Ca(e,t){t===null?N(xa,xa.current):N(xa,t.pool)}function wa(){var e=Sa();return e===null?null:{parent:ua._currentValue,pool:e}}var Ta=Error(i(460)),Ea=Error(i(474)),Da=Error(i(542)),Oa={then:function(){}};function ka(e){return e=e.status,e===`fulfilled`||e===`rejected`}function Aa(e,t,n){switch(n=e[n],n===void 0?e.push(t):n!==t&&(t.then(nn,nn),t=n),t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,Pa(e),e;default:if(typeof t.status==`string`)t.then(nn,nn);else{if(e=Gl,e!==null&&100<e.shellSuspendCounter)throw Error(i(482));e=t,e.status=`pending`,e.then(function(e){if(t.status===`pending`){var n=t;n.status=`fulfilled`,n.value=e}},function(e){if(t.status===`pending`){var n=t;n.status=`rejected`,n.reason=e}})}switch(t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,Pa(e),e}throw Ma=t,Ta}}function ja(e){try{var t=e._init;return t(e._payload)}catch(e){throw typeof e==`object`&&e&&typeof e.then==`function`?(Ma=e,Ta):e}}var Ma=null;function Na(){if(Ma===null)throw Error(i(459));var e=Ma;return Ma=null,e}function Pa(e){if(e===Ta||e===Da)throw Error(i(483))}var Fa=null,Ia=0;function La(e){var t=Ia;return Ia+=1,Fa===null&&(Fa=[]),Aa(Fa,e,t)}function Ra(e,t){t=t.props.ref,e.ref=t===void 0?null:t}function za(e,t){throw t.$$typeof===g?Error(i(525)):(e=Object.prototype.toString.call(t),Error(i(31,e===`[object Object]`?`object with keys {`+Object.keys(t).join(`, `)+`}`:e)))}function Ba(e){function t(t,n){if(e){var r=t.deletions;r===null?(t.deletions=[n],t.flags|=16):r.push(n)}}function n(n,r){if(!e)return null;for(;r!==null;)t(n,r),r=r.sibling;return null}function r(e){for(var t=new Map;e!==null;)e.key===null?t.set(e.index,e):t.set(e.key,e),e=e.sibling;return t}function a(e,t){return e=pi(e,t),e.index=0,e.sibling=null,e}function o(t,n,r){return t.index=r,e?(r=t.alternate,r===null?(t.flags|=67108866,n):(r=r.index,r<n?(t.flags|=67108866,n):r)):(t.flags|=1048576,n)}function s(t){return e&&t.alternate===null&&(t.flags|=67108866),t}function c(e,t,n,r){return t===null||t.tag!==6?(t=_i(n,e.mode,r),t.return=e,t):(t=a(t,n),t.return=e,t)}function l(e,t,n,r){var i=n.type;return i===y?d(e,t,n.props.children,r,n.key):t!==null&&(t.elementType===i||typeof i==`object`&&i&&i.$$typeof===O&&ja(i)===t.type)?(t=a(t,n.props),Ra(t,n),t.return=e,t):(t=hi(n.type,n.key,n.props,null,e.mode,r),Ra(t,n),t.return=e,t)}function u(e,t,n,r){return t===null||t.tag!==4||t.stateNode.containerInfo!==n.containerInfo||t.stateNode.implementation!==n.implementation?(t=yi(n,e.mode,r),t.return=e,t):(t=a(t,n.children||[]),t.return=e,t)}function d(e,t,n,r,i){return t===null||t.tag!==7?(t=gi(n,e.mode,r,i),t.return=e,t):(t=a(t,n),t.return=e,t)}function f(e,t,n){if(typeof t==`string`&&t!==``||typeof t==`number`||typeof t==`bigint`)return t=_i(``+t,e.mode,n),t.return=e,t;if(typeof t==`object`&&t){switch(t.$$typeof){case _:return n=hi(t.type,t.key,t.props,null,e.mode,n),Ra(n,t),n.return=e,n;case v:return t=yi(t,e.mode,n),t.return=e,t;case O:return t=ja(t),f(e,t,n)}if(ae(t)||re(t))return t=gi(t,e.mode,n,null),t.return=e,t;if(typeof t.then==`function`)return f(e,La(t),n);if(t.$$typeof===C)return f(e,aa(e,t),n);za(e,t)}return null}function p(e,t,n,r){var i=t===null?null:t.key;if(typeof n==`string`&&n!==``||typeof n==`number`||typeof n==`bigint`)return i===null?c(e,t,``+n,r):null;if(typeof n==`object`&&n){switch(n.$$typeof){case _:return n.key===i?l(e,t,n,r):null;case v:return n.key===i?u(e,t,n,r):null;case O:return n=ja(n),p(e,t,n,r)}if(ae(n)||re(n))return i===null?d(e,t,n,r,null):null;if(typeof n.then==`function`)return p(e,t,La(n),r);if(n.$$typeof===C)return p(e,t,aa(e,n),r);za(e,n)}return null}function m(e,t,n,r,i){if(typeof r==`string`&&r!==``||typeof r==`number`||typeof r==`bigint`)return e=e.get(n)||null,c(t,e,``+r,i);if(typeof r==`object`&&r){switch(r.$$typeof){case _:return e=e.get(r.key===null?n:r.key)||null,l(t,e,r,i);case v:return e=e.get(r.key===null?n:r.key)||null,u(t,e,r,i);case O:return r=ja(r),m(e,t,n,r,i)}if(ae(r)||re(r))return e=e.get(n)||null,d(t,e,r,i,null);if(typeof r.then==`function`)return m(e,t,n,La(r),i);if(r.$$typeof===C)return m(e,t,n,aa(t,r),i);za(t,r)}return null}function h(i,a,s,c){for(var l=null,u=null,d=a,h=a=0,g=null;d!==null&&h<s.length;h++){d.index>h?(g=d,d=null):g=d.sibling;var _=p(i,d,s[h],c);if(_===null){d===null&&(d=g);break}e&&d&&_.alternate===null&&t(i,d),a=o(_,a,h),u===null?l=_:u.sibling=_,u=_,d=g}if(h===s.length)return n(i,d),I&&ji(i,h),l;if(d===null){for(;h<s.length;h++)d=f(i,s[h],c),d!==null&&(a=o(d,a,h),u===null?l=d:u.sibling=d,u=d);return I&&ji(i,h),l}for(d=r(d);h<s.length;h++)g=m(d,i,h,s[h],c),g!==null&&(e&&g.alternate!==null&&d.delete(g.key===null?h:g.key),a=o(g,a,h),u===null?l=g:u.sibling=g,u=g);return e&&d.forEach(function(e){return t(i,e)}),I&&ji(i,h),l}function g(a,s,c,l){if(c==null)throw Error(i(151));for(var u=null,d=null,h=s,g=s=0,_=null,v=c.next();h!==null&&!v.done;g++,v=c.next()){h.index>g?(_=h,h=null):_=h.sibling;var y=p(a,h,v.value,l);if(y===null){h===null&&(h=_);break}e&&h&&y.alternate===null&&t(a,h),s=o(y,s,g),d===null?u=y:d.sibling=y,d=y,h=_}if(v.done)return n(a,h),I&&ji(a,g),u;if(h===null){for(;!v.done;g++,v=c.next())v=f(a,v.value,l),v!==null&&(s=o(v,s,g),d===null?u=v:d.sibling=v,d=v);return I&&ji(a,g),u}for(h=r(h);!v.done;g++,v=c.next())v=m(h,a,g,v.value,l),v!==null&&(e&&v.alternate!==null&&h.delete(v.key===null?g:v.key),s=o(v,s,g),d===null?u=v:d.sibling=v,d=v);return e&&h.forEach(function(e){return t(a,e)}),I&&ji(a,g),u}function b(e,r,o,c){if(typeof o==`object`&&o&&o.type===y&&o.key===null&&(o=o.props.children),typeof o==`object`&&o){switch(o.$$typeof){case _:a:{for(var l=o.key;r!==null;){if(r.key===l){if(l=o.type,l===y){if(r.tag===7){n(e,r.sibling),c=a(r,o.props.children),c.return=e,e=c;break a}}else if(r.elementType===l||typeof l==`object`&&l&&l.$$typeof===O&&ja(l)===r.type){n(e,r.sibling),c=a(r,o.props),Ra(c,o),c.return=e,e=c;break a}n(e,r);break}else t(e,r);r=r.sibling}o.type===y?(c=gi(o.props.children,e.mode,c,o.key),c.return=e,e=c):(c=hi(o.type,o.key,o.props,null,e.mode,c),Ra(c,o),c.return=e,e=c)}return s(e);case v:a:{for(l=o.key;r!==null;){if(r.key===l)if(r.tag===4&&r.stateNode.containerInfo===o.containerInfo&&r.stateNode.implementation===o.implementation){n(e,r.sibling),c=a(r,o.children||[]),c.return=e,e=c;break a}else{n(e,r);break}else t(e,r);r=r.sibling}c=yi(o,e.mode,c),c.return=e,e=c}return s(e);case O:return o=ja(o),b(e,r,o,c)}if(ae(o))return h(e,r,o,c);if(re(o)){if(l=re(o),typeof l!=`function`)throw Error(i(150));return o=l.call(o),g(e,r,o,c)}if(typeof o.then==`function`)return b(e,r,La(o),c);if(o.$$typeof===C)return b(e,r,aa(e,o),c);za(e,o)}return typeof o==`string`&&o!==``||typeof o==`number`||typeof o==`bigint`?(o=``+o,r!==null&&r.tag===6?(n(e,r.sibling),c=a(r,o),c.return=e,e=c):(n(e,r),c=_i(o,e.mode,c),c.return=e,e=c),s(e)):n(e,r)}return function(e,t,n,r){try{Ia=0;var i=b(e,t,n,r);return Fa=null,i}catch(t){if(t===Ta||t===Da)throw t;var a=di(29,t,null,e.mode);return a.lanes=r,a.return=e,a}}}var Va=Ba(!0),Ha=Ba(!1),Ua=!1;function Wa(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Ga(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function Ka(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function qa(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,B&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,t=ci(e),si(e,null,n),t}return ii(e,r,t,n),ci(e)}function Ja(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,n&4194048)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,nt(e,n)}}function Ya(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,a=null;if(n=n.firstBaseUpdate,n!==null){do{var o={lane:n.lane,tag:n.tag,payload:n.payload,callback:null,next:null};a===null?i=a=o:a=a.next=o,n=n.next}while(n!==null);a===null?i=a=t:a=a.next=t}else i=a=t;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:a,shared:r.shared,callbacks:r.callbacks},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}var Xa=!1;function Za(){if(Xa){var e=ga;if(e!==null)throw e}}function Qa(e,t,n,r){Xa=!1;var i=e.updateQueue;Ua=!1;var a=i.firstBaseUpdate,o=i.lastBaseUpdate,s=i.shared.pending;if(s!==null){i.shared.pending=null;var c=s,l=c.next;c.next=null,o===null?a=l:o.next=l,o=c;var u=e.alternate;u!==null&&(u=u.updateQueue,s=u.lastBaseUpdate,s!==o&&(s===null?u.firstBaseUpdate=l:s.next=l,u.lastBaseUpdate=c))}if(a!==null){var d=i.baseState;o=0,u=l=c=null,s=a;do{var f=s.lane&-536870913,p=f!==s.lane;if(p?(H&f)===f:(r&f)===f){f!==0&&f===ha&&(Xa=!0),u!==null&&(u=u.next={lane:0,tag:s.tag,payload:s.payload,callback:null,next:null});a:{var m=e,g=s;f=t;var _=n;switch(g.tag){case 1:if(m=g.payload,typeof m==`function`){d=m.call(_,d,f);break a}d=m;break a;case 3:m.flags=m.flags&-65537|128;case 0:if(m=g.payload,f=typeof m==`function`?m.call(_,d,f):m,f==null)break a;d=h({},d,f);break a;case 2:Ua=!0}}f=s.callback,f!==null&&(e.flags|=64,p&&(e.flags|=8192),p=i.callbacks,p===null?i.callbacks=[f]:p.push(f))}else p={lane:f,tag:s.tag,payload:s.payload,callback:s.callback,next:null},u===null?(l=u=p,c=d):u=u.next=p,o|=f;if(s=s.next,s===null){if(s=i.shared.pending,s===null)break;p=s,s=p.next,p.next=null,i.lastBaseUpdate=p,i.shared.pending=null}}while(1);u===null&&(c=d),i.baseState=c,i.firstBaseUpdate=l,i.lastBaseUpdate=u,a===null&&(i.shared.lanes=0),Ql|=o,e.lanes=o,e.memoizedState=d}}function $a(e,t){if(typeof e!=`function`)throw Error(i(191,e));e.call(t)}function eo(e,t){var n=e.callbacks;if(n!==null)for(e.callbacks=null,e=0;e<n.length;e++)$a(n[e],t)}var to=le(null),no=le(0);function ro(e,t){e=Xl,N(no,e),N(to,t),Xl=e|t.baseLanes}function io(){N(no,Xl),N(to,to.current)}function ao(){Xl=no.current,M(to),M(no)}var oo=le(null),so=null;function co(e){var t=e.alternate;N(mo,mo.current&1),N(oo,e),so===null&&(t===null||to.current!==null||t.memoizedState!==null)&&(so=e)}function lo(e){N(mo,mo.current),N(oo,e),so===null&&(so=e)}function uo(e){e.tag===22?(N(mo,mo.current),N(oo,e),so===null&&(so=e)):fo(e)}function fo(){N(mo,mo.current),N(oo,oo.current)}function po(e){M(oo),so===e&&(so=null),M(mo)}var mo=le(0);function ho(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||df(n)||ff(n)))return t}else if(t.tag===19&&(t.memoizedProps.revealOrder===`forwards`||t.memoizedProps.revealOrder===`backwards`||t.memoizedProps.revealOrder===`unstable_legacy-backwards`||t.memoizedProps.revealOrder===`together`)){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var go=0,L=null,_o=null,vo=null,yo=!1,bo=!1,xo=!1,So=0,Co=0,wo=null,To=0;function Eo(){throw Error(i(321))}function Do(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!Tr(e[n],t[n]))return!1;return!0}function Oo(e,t,n,r,i,a){return go=a,L=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,A.H=e===null||e.memoizedState===null?Gs:Ks,xo=!1,a=n(r,i),xo=!1,bo&&(a=Ao(t,n,r,i)),ko(e),a}function ko(e){A.H=Ws;var t=_o!==null&&_o.next!==null;if(go=0,vo=_o=L=null,yo=!1,Co=0,wo=null,t)throw Error(i(300));e===null||lc||(e=e.dependencies,e!==null&&na(e)&&(lc=!0))}function Ao(e,t,n,r){L=e;var a=0;do{if(bo&&(wo=null),Co=0,bo=!1,25<=a)throw Error(i(301));if(a+=1,vo=_o=null,e.updateQueue!=null){var o=e.updateQueue;o.lastEffect=null,o.events=null,o.stores=null,o.memoCache!=null&&(o.memoCache.index=0)}A.H=qs,o=t(n,r)}while(bo);return o}function jo(){var e=A.H,t=e.useState()[0];return t=typeof t.then==`function`?Ro(t):t,e=e.useState()[0],(_o===null?null:_o.memoizedState)!==e&&(L.flags|=1024),t}function Mo(){var e=So!==0;return So=0,e}function No(e,t,n){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~n}function Po(e){if(yo){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}yo=!1}go=0,vo=_o=L=null,bo=!1,Co=So=0,wo=null}function Fo(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return vo===null?L.memoizedState=vo=e:vo=vo.next=e,vo}function Io(){if(_o===null){var e=L.alternate;e=e===null?null:e.memoizedState}else e=_o.next;var t=vo===null?L.memoizedState:vo.next;if(t!==null)vo=t,_o=e;else{if(e===null)throw L.alternate===null?Error(i(467)):Error(i(310));_o=e,e={memoizedState:_o.memoizedState,baseState:_o.baseState,baseQueue:_o.baseQueue,queue:_o.queue,next:null},vo===null?L.memoizedState=vo=e:vo=vo.next=e}return vo}function Lo(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Ro(e){var t=Co;return Co+=1,wo===null&&(wo=[]),e=Aa(wo,e,t),t=L,(vo===null?t.memoizedState:vo.next)===null&&(t=t.alternate,A.H=t===null||t.memoizedState===null?Gs:Ks),e}function zo(e){if(typeof e==`object`&&e){if(typeof e.then==`function`)return Ro(e);if(e.$$typeof===C)return ia(e)}throw Error(i(438,String(e)))}function Bo(e){var t=null,n=L.updateQueue;if(n!==null&&(t=n.memoCache),t==null){var r=L.alternate;r!==null&&(r=r.updateQueue,r!==null&&(r=r.memoCache,r!=null&&(t={data:r.data.map(function(e){return e.slice()}),index:0})))}if(t??={data:[],index:0},n===null&&(n=Lo(),L.updateQueue=n),n.memoCache=t,n=t.data[t.index],n===void 0)for(n=t.data[t.index]=Array(e),r=0;r<e;r++)n[r]=te;return t.index++,n}function Vo(e,t){return typeof t==`function`?t(e):t}function Ho(e){return Uo(Io(),_o,e)}function Uo(e,t,n){var r=e.queue;if(r===null)throw Error(i(311));r.lastRenderedReducer=n;var a=e.baseQueue,o=r.pending;if(o!==null){if(a!==null){var s=a.next;a.next=o.next,o.next=s}t.baseQueue=a=o,r.pending=null}if(o=e.baseState,a===null)e.memoizedState=o;else{t=a.next;var c=s=null,l=null,u=t,d=!1;do{var f=u.lane&-536870913;if(f===u.lane?(go&f)===f:(H&f)===f){var p=u.revertLane;if(p===0)l!==null&&(l=l.next={lane:0,revertLane:0,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),f===ha&&(d=!0);else if((go&p)===p){u=u.next,p===ha&&(d=!0);continue}else f={lane:0,revertLane:u.revertLane,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(c=l=f,s=o):l=l.next=f,L.lanes|=p,Ql|=p;f=u.action,xo&&n(o,f),o=u.hasEagerState?u.eagerState:n(o,f)}else p={lane:f,revertLane:u.revertLane,gesture:u.gesture,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(c=l=p,s=o):l=l.next=p,L.lanes|=f,Ql|=f;u=u.next}while(u!==null&&u!==t);if(l===null?s=o:l.next=c,!Tr(o,e.memoizedState)&&(lc=!0,d&&(n=ga,n!==null)))throw n;e.memoizedState=o,e.baseState=s,e.baseQueue=l,r.lastRenderedState=o}return a===null&&(r.lanes=0),[e.memoizedState,r.dispatch]}function Wo(e){var t=Io(),n=t.queue;if(n===null)throw Error(i(311));n.lastRenderedReducer=e;var r=n.dispatch,a=n.pending,o=t.memoizedState;if(a!==null){n.pending=null;var s=a=a.next;do o=e(o,s.action),s=s.next;while(s!==a);Tr(o,t.memoizedState)||(lc=!0),t.memoizedState=o,t.baseQueue===null&&(t.baseState=o),n.lastRenderedState=o}return[o,r]}function Go(e,t,n){var r=L,a=Io(),o=I;if(o){if(n===void 0)throw Error(i(407));n=n()}else n=t();var s=!Tr((_o||a).memoizedState,n);if(s&&(a.memoizedState=n,lc=!0),a=a.queue,gs(Jo.bind(null,r,a,e),[e]),a.getSnapshot!==t||s||vo!==null&&vo.memoizedState.tag&1){if(r.flags|=2048,ds(9,{destroy:void 0},qo.bind(null,r,a,n,t),null),Gl===null)throw Error(i(349));o||go&127||Ko(r,t,n)}return n}function Ko(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=L.updateQueue,t===null?(t=Lo(),L.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function qo(e,t,n,r){t.value=n,t.getSnapshot=r,Yo(t)&&Xo(e)}function Jo(e,t,n){return n(function(){Yo(t)&&Xo(e)})}function Yo(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!Tr(e,n)}catch{return!0}}function Xo(e){var t=oi(e,2);t!==null&&xu(t,e,2)}function Zo(e){var t=Fo();if(typeof e==`function`){var n=e;if(e=n(),xo){Be(!0);try{n()}finally{Be(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Vo,lastRenderedState:e},t}function Qo(e,t,n,r){return e.baseState=n,Uo(e,_o,typeof r==`function`?r:Vo)}function $o(e,t,n,r,a){if(Vs(e))throw Error(i(485));if(e=t.action,e!==null){var o={payload:a,action:e,next:null,isTransition:!0,status:`pending`,value:null,reason:null,listeners:[],then:function(e){o.listeners.push(e)}};A.T===null?o.isTransition=!1:n(!0),r(o),n=t.pending,n===null?(o.next=t.pending=o,es(t,o)):(o.next=n.next,t.pending=n.next=o)}}function es(e,t){var n=t.action,r=t.payload,i=e.state;if(t.isTransition){var a=A.T,o={};A.T=o;try{var s=n(i,r),c=A.S;c!==null&&c(o,s),ts(e,t,s)}catch(n){rs(e,t,n)}finally{a!==null&&o.types!==null&&(a.types=o.types),A.T=a}}else try{a=n(i,r),ts(e,t,a)}catch(n){rs(e,t,n)}}function ts(e,t,n){typeof n==`object`&&n&&typeof n.then==`function`?n.then(function(n){ns(e,t,n)},function(n){return rs(e,t,n)}):ns(e,t,n)}function ns(e,t,n){t.status=`fulfilled`,t.value=n,is(t),e.state=n,t=e.pending,t!==null&&(n=t.next,n===t?e.pending=null:(n=n.next,t.next=n,es(e,n)))}function rs(e,t,n){var r=e.pending;if(e.pending=null,r!==null){r=r.next;do t.status=`rejected`,t.reason=n,is(t),t=t.next;while(t!==r)}e.action=null}function is(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function as(e,t){return t}function os(e,t){if(I){var n=Gl.formState;if(n!==null){a:{var r=L;if(I){if(Li){b:{for(var i=Li,a=zi;i.nodeType!==8;){if(!a){i=null;break b}if(i=J(i.nextSibling),i===null){i=null;break b}}a=i.data,i=a===`F!`||a===`F`?i:null}if(i){Li=J(i.nextSibling),r=i.data===`F!`;break a}}Vi(r)}r=!1}r&&(t=n[0])}}return n=Fo(),n.memoizedState=n.baseState=t,r={pending:null,lanes:0,dispatch:null,lastRenderedReducer:as,lastRenderedState:t},n.queue=r,n=Rs.bind(null,L,r),r.dispatch=n,r=Zo(!1),a=Bs.bind(null,L,!1,r.queue),r=Fo(),i={state:t,dispatch:null,action:e,pending:null},r.queue=i,n=$o.bind(null,L,i,a,n),i.dispatch=n,r.memoizedState=e,[t,n,!1]}function ss(e){return cs(Io(),_o,e)}function cs(e,t,n){if(t=Uo(e,t,as)[0],e=Ho(Vo)[0],typeof t==`object`&&t&&typeof t.then==`function`)try{var r=Ro(t)}catch(e){throw e===Ta?Da:e}else r=t;t=Io();var i=t.queue,a=i.dispatch;return n!==t.memoizedState&&(L.flags|=2048,ds(9,{destroy:void 0},ls.bind(null,i,n),null)),[r,a,e]}function ls(e,t){e.action=t}function us(e){var t=Io(),n=_o;if(n!==null)return cs(t,n,e);Io(),t=t.memoizedState,n=Io();var r=n.queue.dispatch;return n.memoizedState=e,[t,r,!1]}function ds(e,t,n,r){return e={tag:e,create:n,deps:r,inst:t,next:null},t=L.updateQueue,t===null&&(t=Lo(),L.updateQueue=t),n=t.lastEffect,n===null?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e),e}function fs(){return Io().memoizedState}function ps(e,t,n,r){var i=Fo();L.flags|=e,i.memoizedState=ds(1|t,{destroy:void 0},n,r===void 0?null:r)}function ms(e,t,n,r){var i=Io();r=r===void 0?null:r;var a=i.memoizedState.inst;_o!==null&&r!==null&&Do(r,_o.memoizedState.deps)?i.memoizedState=ds(t,a,n,r):(L.flags|=e,i.memoizedState=ds(1|t,a,n,r))}function hs(e,t){ps(8390656,8,e,t)}function gs(e,t){ms(2048,8,e,t)}function _s(e){L.flags|=4;var t=L.updateQueue;if(t===null)t=Lo(),L.updateQueue=t,t.events=[e];else{var n=t.events;n===null?t.events=[e]:n.push(e)}}function vs(e){var t=Io().memoizedState;return _s({ref:t,nextImpl:e}),function(){if(B&2)throw Error(i(440));return t.impl.apply(void 0,arguments)}}function ys(e,t){return ms(4,2,e,t)}function bs(e,t){return ms(4,4,e,t)}function xs(e,t){if(typeof t==`function`){e=e();var n=t(e);return function(){typeof n==`function`?n():t(null)}}if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function Ss(e,t,n){n=n==null?null:n.concat([e]),ms(4,4,xs.bind(null,t,e),n)}function Cs(){}function ws(e,t){var n=Io();t=t===void 0?null:t;var r=n.memoizedState;return t!==null&&Do(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function Ts(e,t){var n=Io();t=t===void 0?null:t;var r=n.memoizedState;if(t!==null&&Do(t,r[1]))return r[0];if(r=e(),xo){Be(!0);try{e()}finally{Be(!1)}}return n.memoizedState=[r,t],r}function Es(e,t,n){return n===void 0||go&1073741824&&!(H&261930)?e.memoizedState=t:(e.memoizedState=n,e=bu(),L.lanes|=e,Ql|=e,n)}function Ds(e,t,n,r){return Tr(n,t)?n:to.current===null?!(go&42)||go&1073741824&&!(H&261930)?(lc=!0,e.memoizedState=n):(e=bu(),L.lanes|=e,Ql|=e,t):(e=Es(e,n,r),Tr(e,t)||(lc=!0),e)}function Os(e,t,n,r,i){var a=j.p;j.p=a!==0&&8>a?a:8;var o=A.T,s={};A.T=s,Bs(e,!1,t,n);try{var c=i(),l=A.S;l!==null&&l(s,c),typeof c==`object`&&c&&typeof c.then==`function`?zs(e,t,ya(c,r),yu(e)):zs(e,t,r,yu(e))}catch(n){zs(e,t,{then:function(){},status:`rejected`,reason:n},yu())}finally{j.p=a,o!==null&&s.types!==null&&(o.types=s.types),A.T=o}}function ks(){}function As(e,t,n,r){if(e.tag!==5)throw Error(i(476));var a=js(e).queue;Os(e,a,t,oe,n===null?ks:function(){return Ms(e),n(r)})}function js(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:oe,baseState:oe,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Vo,lastRenderedState:oe},next:null};var n={};return t.next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Vo,lastRenderedState:n},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function Ms(e){var t=js(e);t.next===null&&(t=e.alternate.memoizedState),zs(e,t.next.queue,{},yu())}function Ns(){return ia(np)}function Ps(){return Io().memoizedState}function Fs(){return Io().memoizedState}function Is(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var n=yu();e=Ka(n);var r=qa(t,e,n);r!==null&&(xu(r,t,n),Ja(r,t,n)),t={cache:da()},e.payload=t;return}t=t.return}}function Ls(e,t,n){var r=yu();n={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},Vs(e)?Hs(t,n):(n=ai(e,t,n,r),n!==null&&(xu(n,e,r),Us(n,t,r)))}function Rs(e,t,n){zs(e,t,n,yu())}function zs(e,t,n,r){var i={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(Vs(e))Hs(t,i);else{var a=e.alternate;if(e.lanes===0&&(a===null||a.lanes===0)&&(a=t.lastRenderedReducer,a!==null))try{var o=t.lastRenderedState,s=a(o,n);if(i.hasEagerState=!0,i.eagerState=s,Tr(s,o))return ii(e,t,i,0),Gl===null&&ri(),!1}catch{}if(n=ai(e,t,i,r),n!==null)return xu(n,e,r),Us(n,t,r),!0}return!1}function Bs(e,t,n,r){if(r={lane:2,revertLane:_d(),gesture:null,action:r,hasEagerState:!1,eagerState:null,next:null},Vs(e)){if(t)throw Error(i(479))}else t=ai(e,n,r,2),t!==null&&xu(t,e,2)}function Vs(e){var t=e.alternate;return e===L||t!==null&&t===L}function Hs(e,t){bo=yo=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Us(e,t,n){if(n&4194048){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,nt(e,n)}}var Ws={readContext:ia,use:zo,useCallback:Eo,useContext:Eo,useEffect:Eo,useImperativeHandle:Eo,useLayoutEffect:Eo,useInsertionEffect:Eo,useMemo:Eo,useReducer:Eo,useRef:Eo,useState:Eo,useDebugValue:Eo,useDeferredValue:Eo,useTransition:Eo,useSyncExternalStore:Eo,useId:Eo,useHostTransitionStatus:Eo,useFormState:Eo,useActionState:Eo,useOptimistic:Eo,useMemoCache:Eo,useCacheRefresh:Eo};Ws.useEffectEvent=Eo;var Gs={readContext:ia,use:zo,useCallback:function(e,t){return Fo().memoizedState=[e,t===void 0?null:t],e},useContext:ia,useEffect:hs,useImperativeHandle:function(e,t,n){n=n==null?null:n.concat([e]),ps(4194308,4,xs.bind(null,t,e),n)},useLayoutEffect:function(e,t){return ps(4194308,4,e,t)},useInsertionEffect:function(e,t){ps(4,2,e,t)},useMemo:function(e,t){var n=Fo();t=t===void 0?null:t;var r=e();if(xo){Be(!0);try{e()}finally{Be(!1)}}return n.memoizedState=[r,t],r},useReducer:function(e,t,n){var r=Fo();if(n!==void 0){var i=n(t);if(xo){Be(!0);try{n(t)}finally{Be(!1)}}}else i=t;return r.memoizedState=r.baseState=i,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:i},r.queue=e,e=e.dispatch=Ls.bind(null,L,e),[r.memoizedState,e]},useRef:function(e){var t=Fo();return e={current:e},t.memoizedState=e},useState:function(e){e=Zo(e);var t=e.queue,n=Rs.bind(null,L,t);return t.dispatch=n,[e.memoizedState,n]},useDebugValue:Cs,useDeferredValue:function(e,t){return Es(Fo(),e,t)},useTransition:function(){var e=Zo(!1);return e=Os.bind(null,L,e.queue,!0,!1),Fo().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,n){var r=L,a=Fo();if(I){if(n===void 0)throw Error(i(407));n=n()}else{if(n=t(),Gl===null)throw Error(i(349));H&127||Ko(r,t,n)}a.memoizedState=n;var o={value:n,getSnapshot:t};return a.queue=o,hs(Jo.bind(null,r,o,e),[e]),r.flags|=2048,ds(9,{destroy:void 0},qo.bind(null,r,o,n,t),null),n},useId:function(){var e=Fo(),t=Gl.identifierPrefix;if(I){var n=Ai,r=ki;n=(r&~(1<<32-Ve(r)-1)).toString(32)+n,t=`_`+t+`R_`+n,n=So++,0<n&&(t+=`H`+n.toString(32)),t+=`_`}else n=To++,t=`_`+t+`r_`+n.toString(32)+`_`;return e.memoizedState=t},useHostTransitionStatus:Ns,useFormState:os,useActionState:os,useOptimistic:function(e){var t=Fo();t.memoizedState=t.baseState=e;var n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=n,t=Bs.bind(null,L,!0,n),n.dispatch=t,[e,t]},useMemoCache:Bo,useCacheRefresh:function(){return Fo().memoizedState=Is.bind(null,L)},useEffectEvent:function(e){var t=Fo(),n={impl:e};return t.memoizedState=n,function(){if(B&2)throw Error(i(440));return n.impl.apply(void 0,arguments)}}},Ks={readContext:ia,use:zo,useCallback:ws,useContext:ia,useEffect:gs,useImperativeHandle:Ss,useInsertionEffect:ys,useLayoutEffect:bs,useMemo:Ts,useReducer:Ho,useRef:fs,useState:function(){return Ho(Vo)},useDebugValue:Cs,useDeferredValue:function(e,t){return Ds(Io(),_o.memoizedState,e,t)},useTransition:function(){var e=Ho(Vo)[0],t=Io().memoizedState;return[typeof e==`boolean`?e:Ro(e),t]},useSyncExternalStore:Go,useId:Ps,useHostTransitionStatus:Ns,useFormState:ss,useActionState:ss,useOptimistic:function(e,t){return Qo(Io(),_o,e,t)},useMemoCache:Bo,useCacheRefresh:Fs};Ks.useEffectEvent=vs;var qs={readContext:ia,use:zo,useCallback:ws,useContext:ia,useEffect:gs,useImperativeHandle:Ss,useInsertionEffect:ys,useLayoutEffect:bs,useMemo:Ts,useReducer:Wo,useRef:fs,useState:function(){return Wo(Vo)},useDebugValue:Cs,useDeferredValue:function(e,t){var n=Io();return _o===null?Es(n,e,t):Ds(n,_o.memoizedState,e,t)},useTransition:function(){var e=Wo(Vo)[0],t=Io().memoizedState;return[typeof e==`boolean`?e:Ro(e),t]},useSyncExternalStore:Go,useId:Ps,useHostTransitionStatus:Ns,useFormState:us,useActionState:us,useOptimistic:function(e,t){var n=Io();return _o===null?(n.baseState=e,[e,n.queue.dispatch]):Qo(n,_o,e,t)},useMemoCache:Bo,useCacheRefresh:Fs};qs.useEffectEvent=vs;function Js(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:h({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var Ys={enqueueSetState:function(e,t,n){e=e._reactInternals;var r=yu(),i=Ka(r);i.payload=t,n!=null&&(i.callback=n),t=qa(e,i,r),t!==null&&(xu(t,e,r),Ja(t,e,r))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=yu(),i=Ka(r);i.tag=1,i.payload=t,n!=null&&(i.callback=n),t=qa(e,i,r),t!==null&&(xu(t,e,r),Ja(t,e,r))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=yu(),r=Ka(n);r.tag=2,t!=null&&(r.callback=t),t=qa(e,r,n),t!==null&&(xu(t,e,n),Ja(t,e,n))}};function Xs(e,t,n,r,i,a,o){return e=e.stateNode,typeof e.shouldComponentUpdate==`function`?e.shouldComponentUpdate(r,a,o):t.prototype&&t.prototype.isPureReactComponent?!Er(n,r)||!Er(i,a):!0}function Zs(e,t,n,r){e=t.state,typeof t.componentWillReceiveProps==`function`&&t.componentWillReceiveProps(n,r),typeof t.UNSAFE_componentWillReceiveProps==`function`&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&Ys.enqueueReplaceState(t,t.state,null)}function Qs(e,t){var n=t;if(`ref`in t)for(var r in n={},t)r!==`ref`&&(n[r]=t[r]);if(e=e.defaultProps)for(var i in n===t&&(n=h({},n)),e)n[i]===void 0&&(n[i]=e[i]);return n}function $s(e){$r(e)}function ec(e){console.error(e)}function tc(e){$r(e)}function nc(e,t){try{var n=e.onUncaughtError;n(t.value,{componentStack:t.stack})}catch(e){setTimeout(function(){throw e})}}function rc(e,t,n){try{var r=e.onCaughtError;r(n.value,{componentStack:n.stack,errorBoundary:t.tag===1?t.stateNode:null})}catch(e){setTimeout(function(){throw e})}}function ic(e,t,n){return n=Ka(n),n.tag=3,n.payload={element:null},n.callback=function(){nc(e,t)},n}function ac(e){return e=Ka(e),e.tag=3,e}function oc(e,t,n,r){var i=n.type.getDerivedStateFromError;if(typeof i==`function`){var a=r.value;e.payload=function(){return i(a)},e.callback=function(){rc(t,n,r)}}var o=n.stateNode;o!==null&&typeof o.componentDidCatch==`function`&&(e.callback=function(){rc(t,n,r),typeof i!=`function`&&(lu===null?lu=new Set([this]):lu.add(this));var e=r.stack;this.componentDidCatch(r.value,{componentStack:e===null?``:e})})}function sc(e,t,n,r,a){if(n.flags|=32768,typeof r==`object`&&r&&typeof r.then==`function`){if(t=n.alternate,t!==null&&ta(t,n,a,!0),n=oo.current,n!==null){switch(n.tag){case 31:case 13:return so===null?Nu():n.alternate===null&&Zl===0&&(Zl=3),n.flags&=-257,n.flags|=65536,n.lanes=a,r===Oa?n.flags|=16384:(t=n.updateQueue,t===null?n.updateQueue=new Set([r]):t.add(r),Zu(e,r,a)),!1;case 22:return n.flags|=65536,r===Oa?n.flags|=16384:(t=n.updateQueue,t===null?(t={transitions:null,markerInstances:null,retryQueue:new Set([r])},n.updateQueue=t):(n=t.retryQueue,n===null?t.retryQueue=new Set([r]):n.add(r)),Zu(e,r,a)),!1}throw Error(i(435,n.tag))}return Zu(e,r,a),Nu(),!1}if(I)return t=oo.current,t===null?(r!==Bi&&(t=Error(i(423),{cause:r}),qi(xi(t,n))),e=e.current.alternate,e.flags|=65536,a&=-a,e.lanes|=a,r=xi(r,n),a=ic(e.stateNode,r,a),Ya(e,a),Zl!==4&&(Zl=2)):(!(t.flags&65536)&&(t.flags|=256),t.flags|=65536,t.lanes=a,r!==Bi&&(e=Error(i(422),{cause:r}),qi(xi(e,n)))),!1;var o=Error(i(520),{cause:r});if(o=xi(o,n),ru===null?ru=[o]:ru.push(o),Zl!==4&&(Zl=2),t===null)return!0;r=xi(r,n),n=t;do{switch(n.tag){case 3:return n.flags|=65536,e=a&-a,n.lanes|=e,e=ic(n.stateNode,r,e),Ya(n,e),!1;case 1:if(t=n.type,o=n.stateNode,!(n.flags&128)&&(typeof t.getDerivedStateFromError==`function`||o!==null&&typeof o.componentDidCatch==`function`&&(lu===null||!lu.has(o))))return n.flags|=65536,a&=-a,n.lanes|=a,a=ac(a),oc(a,e,n,r),Ya(n,a),!1}n=n.return}while(n!==null);return!1}var cc=Error(i(461)),lc=!1;function uc(e,t,n,r){t.child=e===null?Ha(t,null,n,r):Va(t,e.child,n,r)}function dc(e,t,n,r,i){n=n.render;var a=t.ref;if(`ref`in r){var o={};for(var s in r)s!==`ref`&&(o[s]=r[s])}else o=r;return ra(t),r=Oo(e,t,n,o,a,i),s=Mo(),e!==null&&!lc?(No(e,t,i),Fc(e,t,i)):(I&&s&&Ni(t),t.flags|=1,uc(e,t,r,i),t.child)}function fc(e,t,n,r,i){if(e===null){var a=n.type;return typeof a==`function`&&!fi(a)&&a.defaultProps===void 0&&n.compare===null?(t.tag=15,t.type=a,pc(e,t,a,r,i)):(e=hi(n.type,null,r,t,t.mode,i),e.ref=t.ref,e.return=t,t.child=e)}if(a=e.child,!Ic(e,i)){var o=a.memoizedProps;if(n=n.compare,n=n===null?Er:n,n(o,r)&&e.ref===t.ref)return Fc(e,t,i)}return t.flags|=1,e=pi(a,r),e.ref=t.ref,e.return=t,t.child=e}function pc(e,t,n,r,i){if(e!==null){var a=e.memoizedProps;if(Er(a,r)&&e.ref===t.ref)if(lc=!1,t.pendingProps=r=a,Ic(e,i))e.flags&131072&&(lc=!0);else return t.lanes=e.lanes,Fc(e,t,i)}return xc(e,t,n,r,i)}function mc(e,t,n,r){var i=r.children,a=e===null?null:e.memoizedState;if(e===null&&t.stateNode===null&&(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),r.mode===`hidden`){if(t.flags&128){if(a=a===null?n:a.baseLanes|n,e!==null){for(r=t.child=e.child,i=0;r!==null;)i=i|r.lanes|r.childLanes,r=r.sibling;r=i&~a}else r=0,t.child=null;return gc(e,t,a,n,r)}if(n&536870912)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&Ca(t,a===null?null:a.cachePool),a===null?io():ro(t,a),uo(t);else return r=t.lanes=536870912,gc(e,t,a===null?n:a.baseLanes|n,n,r)}else a===null?(e!==null&&Ca(t,null),io(),fo(t)):(Ca(t,a.cachePool),ro(t,a),fo(t),t.memoizedState=null);return uc(e,t,i,n),t.child}function hc(e,t){return e!==null&&e.tag===22||t.stateNode!==null||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function gc(e,t,n,r,i){var a=Sa();return a=a===null?null:{parent:ua._currentValue,pool:a},t.memoizedState={baseLanes:n,cachePool:a},e!==null&&Ca(t,null),io(),uo(t),e!==null&&ta(e,t,r,!0),t.childLanes=i,null}function _c(e,t){return t=Ac({mode:t.mode,children:t.children},e.mode),t.ref=e.ref,e.child=t,t.return=e,t}function vc(e,t,n){return Va(t,e.child,null,n),e=_c(t,t.pendingProps),e.flags|=2,po(t),t.memoizedState=null,e}function yc(e,t,n){var r=t.pendingProps,a=(t.flags&128)!=0;if(t.flags&=-129,e===null){if(I){if(r.mode===`hidden`)return e=_c(t,r),t.lanes=536870912,hc(null,e);if(lo(t),(e=Li)?(e=uf(e,zi),e=e!==null&&e.data===`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:Oi===null?null:{id:ki,overflow:Ai},retryLane:536870912,hydrationErrors:null},n=vi(e),n.return=t,t.child=n,Ii=t,Li=null)):e=null,e===null)throw Vi(t);return t.lanes=536870912,null}return _c(t,r)}var o=e.memoizedState;if(o!==null){var s=o.dehydrated;if(lo(t),a)if(t.flags&256)t.flags&=-257,t=vc(e,t,n);else if(t.memoizedState!==null)t.child=e.child,t.flags|=128,t=null;else throw Error(i(558));else if(lc||ta(e,t,n,!1),a=(n&e.childLanes)!==0,lc||a){if(r=Gl,r!==null&&(s=rt(r,n),s!==0&&s!==o.retryLane))throw o.retryLane=s,oi(e,s),xu(r,e,s),cc;Nu(),t=vc(e,t,n)}else e=o.treeContext,Li=J(s.nextSibling),Ii=t,I=!0,Ri=null,zi=!1,e!==null&&Fi(t,e),t=_c(t,r),t.flags|=4096;return t}return e=pi(e.child,{mode:r.mode,children:r.children}),e.ref=t.ref,t.child=e,e.return=t,e}function bc(e,t){var n=t.ref;if(n===null)e!==null&&e.ref!==null&&(t.flags|=4194816);else{if(typeof n!=`function`&&typeof n!=`object`)throw Error(i(284));(e===null||e.ref!==n)&&(t.flags|=4194816)}}function xc(e,t,n,r,i){return ra(t),n=Oo(e,t,n,r,void 0,i),r=Mo(),e!==null&&!lc?(No(e,t,i),Fc(e,t,i)):(I&&r&&Ni(t),t.flags|=1,uc(e,t,n,i),t.child)}function Sc(e,t,n,r,i,a){return ra(t),t.updateQueue=null,n=Ao(t,r,n,i),ko(e),r=Mo(),e!==null&&!lc?(No(e,t,a),Fc(e,t,a)):(I&&r&&Ni(t),t.flags|=1,uc(e,t,n,a),t.child)}function Cc(e,t,n,r,i){if(ra(t),t.stateNode===null){var a=li,o=n.contextType;typeof o==`object`&&o&&(a=ia(o)),a=new n(r,a),t.memoizedState=a.state!==null&&a.state!==void 0?a.state:null,a.updater=Ys,t.stateNode=a,a._reactInternals=t,a=t.stateNode,a.props=r,a.state=t.memoizedState,a.refs={},Wa(t),o=n.contextType,a.context=typeof o==`object`&&o?ia(o):li,a.state=t.memoizedState,o=n.getDerivedStateFromProps,typeof o==`function`&&(Js(t,n,o,r),a.state=t.memoizedState),typeof n.getDerivedStateFromProps==`function`||typeof a.getSnapshotBeforeUpdate==`function`||typeof a.UNSAFE_componentWillMount!=`function`&&typeof a.componentWillMount!=`function`||(o=a.state,typeof a.componentWillMount==`function`&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount==`function`&&a.UNSAFE_componentWillMount(),o!==a.state&&Ys.enqueueReplaceState(a,a.state,null),Qa(t,r,a,i),Za(),a.state=t.memoizedState),typeof a.componentDidMount==`function`&&(t.flags|=4194308),r=!0}else if(e===null){a=t.stateNode;var s=t.memoizedProps,c=Qs(n,s);a.props=c;var l=a.context,u=n.contextType;o=li,typeof u==`object`&&u&&(o=ia(u));var d=n.getDerivedStateFromProps;u=typeof d==`function`||typeof a.getSnapshotBeforeUpdate==`function`,s=t.pendingProps!==s,u||typeof a.UNSAFE_componentWillReceiveProps!=`function`&&typeof a.componentWillReceiveProps!=`function`||(s||l!==o)&&Zs(t,a,r,o),Ua=!1;var f=t.memoizedState;a.state=f,Qa(t,r,a,i),Za(),l=t.memoizedState,s||f!==l||Ua?(typeof d==`function`&&(Js(t,n,d,r),l=t.memoizedState),(c=Ua||Xs(t,n,c,r,f,l,o))?(u||typeof a.UNSAFE_componentWillMount!=`function`&&typeof a.componentWillMount!=`function`||(typeof a.componentWillMount==`function`&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount==`function`&&a.UNSAFE_componentWillMount()),typeof a.componentDidMount==`function`&&(t.flags|=4194308)):(typeof a.componentDidMount==`function`&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=l),a.props=r,a.state=l,a.context=o,r=c):(typeof a.componentDidMount==`function`&&(t.flags|=4194308),r=!1)}else{a=t.stateNode,Ga(e,t),o=t.memoizedProps,u=Qs(n,o),a.props=u,d=t.pendingProps,f=a.context,l=n.contextType,c=li,typeof l==`object`&&l&&(c=ia(l)),s=n.getDerivedStateFromProps,(l=typeof s==`function`||typeof a.getSnapshotBeforeUpdate==`function`)||typeof a.UNSAFE_componentWillReceiveProps!=`function`&&typeof a.componentWillReceiveProps!=`function`||(o!==d||f!==c)&&Zs(t,a,r,c),Ua=!1,f=t.memoizedState,a.state=f,Qa(t,r,a,i),Za();var p=t.memoizedState;o!==d||f!==p||Ua||e!==null&&e.dependencies!==null&&na(e.dependencies)?(typeof s==`function`&&(Js(t,n,s,r),p=t.memoizedState),(u=Ua||Xs(t,n,u,r,f,p,c)||e!==null&&e.dependencies!==null&&na(e.dependencies))?(l||typeof a.UNSAFE_componentWillUpdate!=`function`&&typeof a.componentWillUpdate!=`function`||(typeof a.componentWillUpdate==`function`&&a.componentWillUpdate(r,p,c),typeof a.UNSAFE_componentWillUpdate==`function`&&a.UNSAFE_componentWillUpdate(r,p,c)),typeof a.componentDidUpdate==`function`&&(t.flags|=4),typeof a.getSnapshotBeforeUpdate==`function`&&(t.flags|=1024)):(typeof a.componentDidUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=p),a.props=r,a.state=p,a.context=c,r=u):(typeof a.componentDidUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),r=!1)}return a=r,bc(e,t),r=(t.flags&128)!=0,a||r?(a=t.stateNode,n=r&&typeof n.getDerivedStateFromError!=`function`?null:a.render(),t.flags|=1,e!==null&&r?(t.child=Va(t,e.child,null,i),t.child=Va(t,null,n,i)):uc(e,t,n,i),t.memoizedState=a.state,e=t.child):e=Fc(e,t,i),e}function wc(e,t,n,r){return Gi(),t.flags|=256,uc(e,t,n,r),t.child}var Tc={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function Ec(e){return{baseLanes:e,cachePool:wa()}}function Dc(e,t,n){return e=e===null?0:e.childLanes&~n,t&&(e|=tu),e}function Oc(e,t,n){var r=t.pendingProps,a=!1,o=(t.flags&128)!=0,s;if((s=o)||(s=e!==null&&e.memoizedState===null?!1:(mo.current&2)!=0),s&&(a=!0,t.flags&=-129),s=(t.flags&32)!=0,t.flags&=-33,e===null){if(I){if(a?co(t):fo(t),(e=Li)?(e=uf(e,zi),e=e!==null&&e.data!==`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:Oi===null?null:{id:ki,overflow:Ai},retryLane:536870912,hydrationErrors:null},n=vi(e),n.return=t,t.child=n,Ii=t,Li=null)):e=null,e===null)throw Vi(t);return ff(e)?t.lanes=32:t.lanes=536870912,null}var c=r.children;return r=r.fallback,a?(fo(t),a=t.mode,c=Ac({mode:`hidden`,children:c},a),r=gi(r,a,n,null),c.return=t,r.return=t,c.sibling=r,t.child=c,r=t.child,r.memoizedState=Ec(n),r.childLanes=Dc(e,s,n),t.memoizedState=Tc,hc(null,r)):(co(t),kc(t,c))}var l=e.memoizedState;if(l!==null&&(c=l.dehydrated,c!==null)){if(o)t.flags&256?(co(t),t.flags&=-257,t=jc(e,t,n)):t.memoizedState===null?(fo(t),c=r.fallback,a=t.mode,r=Ac({mode:`visible`,children:r.children},a),c=gi(c,a,n,null),c.flags|=2,r.return=t,c.return=t,r.sibling=c,t.child=r,Va(t,e.child,null,n),r=t.child,r.memoizedState=Ec(n),r.childLanes=Dc(e,s,n),t.memoizedState=Tc,t=hc(null,r)):(fo(t),t.child=e.child,t.flags|=128,t=null);else if(co(t),ff(c)){if(s=c.nextSibling&&c.nextSibling.dataset,s)var u=s.dgst;s=u,r=Error(i(419)),r.stack=``,r.digest=s,qi({value:r,source:null,stack:null}),t=jc(e,t,n)}else if(lc||ta(e,t,n,!1),s=(n&e.childLanes)!==0,lc||s){if(s=Gl,s!==null&&(r=rt(s,n),r!==0&&r!==l.retryLane))throw l.retryLane=r,oi(e,r),xu(s,e,r),cc;df(c)||Nu(),t=jc(e,t,n)}else df(c)?(t.flags|=192,t.child=e.child,t=null):(e=l.treeContext,Li=J(c.nextSibling),Ii=t,I=!0,Ri=null,zi=!1,e!==null&&Fi(t,e),t=kc(t,r.children),t.flags|=4096);return t}return a?(fo(t),c=r.fallback,a=t.mode,l=e.child,u=l.sibling,r=pi(l,{mode:`hidden`,children:r.children}),r.subtreeFlags=l.subtreeFlags&65011712,u===null?(c=gi(c,a,n,null),c.flags|=2):c=pi(u,c),c.return=t,r.return=t,r.sibling=c,t.child=r,hc(null,r),r=t.child,c=e.child.memoizedState,c===null?c=Ec(n):(a=c.cachePool,a===null?a=wa():(l=ua._currentValue,a=a.parent===l?a:{parent:l,pool:l}),c={baseLanes:c.baseLanes|n,cachePool:a}),r.memoizedState=c,r.childLanes=Dc(e,s,n),t.memoizedState=Tc,hc(e.child,r)):(co(t),n=e.child,e=n.sibling,n=pi(n,{mode:`visible`,children:r.children}),n.return=t,n.sibling=null,e!==null&&(s=t.deletions,s===null?(t.deletions=[e],t.flags|=16):s.push(e)),t.child=n,t.memoizedState=null,n)}function kc(e,t){return t=Ac({mode:`visible`,children:t},e.mode),t.return=e,e.child=t}function Ac(e,t){return e=di(22,e,null,t),e.lanes=0,e}function jc(e,t,n){return Va(t,e.child,null,n),e=kc(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function Mc(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),$i(e.return,t,n)}function Nc(e,t,n,r,i,a){var o=e.memoizedState;o===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:i,treeForkCount:a}:(o.isBackwards=t,o.rendering=null,o.renderingStartTime=0,o.last=r,o.tail=n,o.tailMode=i,o.treeForkCount=a)}function Pc(e,t,n){var r=t.pendingProps,i=r.revealOrder,a=r.tail;r=r.children;var o=mo.current,s=(o&2)!=0;if(s?(o=o&1|2,t.flags|=128):o&=1,N(mo,o),uc(e,t,r,n),r=I?Ti:0,!s&&e!==null&&e.flags&128)a:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&Mc(e,n,t);else if(e.tag===19)Mc(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break a;for(;e.sibling===null;){if(e.return===null||e.return===t)break a;e=e.return}e.sibling.return=e.return,e=e.sibling}switch(i){case`forwards`:for(n=t.child,i=null;n!==null;)e=n.alternate,e!==null&&ho(e)===null&&(i=n),n=n.sibling;n=i,n===null?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),Nc(t,!1,i,n,a,r);break;case`backwards`:case`unstable_legacy-backwards`:for(n=null,i=t.child,t.child=null;i!==null;){if(e=i.alternate,e!==null&&ho(e)===null){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}Nc(t,!0,n,null,a,r);break;case`together`:Nc(t,!1,null,null,void 0,r);break;default:t.memoizedState=null}return t.child}function Fc(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),Ql|=t.lanes,(n&t.childLanes)===0)if(e!==null){if(ta(e,t,n,!1),(n&t.childLanes)===0)return null}else return null;if(e!==null&&t.child!==e.child)throw Error(i(153));if(t.child!==null){for(e=t.child,n=pi(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=pi(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function Ic(e,t){return(e.lanes&t)===0?(e=e.dependencies,!!(e!==null&&na(e))):!0}function Lc(e,t,n){switch(t.tag){case 3:me(t,t.stateNode.containerInfo),Zi(t,ua,e.memoizedState.cache),Gi();break;case 27:case 5:ge(t);break;case 4:me(t,t.stateNode.containerInfo);break;case 10:Zi(t,t.type,t.memoizedProps.value);break;case 31:if(t.memoizedState!==null)return t.flags|=128,lo(t),null;break;case 13:var r=t.memoizedState;if(r!==null)return r.dehydrated===null?(n&t.child.childLanes)===0?(co(t),e=Fc(e,t,n),e===null?null:e.sibling):Oc(e,t,n):(co(t),t.flags|=128,null);co(t);break;case 19:var i=(e.flags&128)!=0;if(r=(n&t.childLanes)!==0,r||=(ta(e,t,n,!1),(n&t.childLanes)!==0),i){if(r)return Pc(e,t,n);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),N(mo,mo.current),r)break;return null;case 22:return t.lanes=0,mc(e,t,n,t.pendingProps);case 24:Zi(t,ua,e.memoizedState.cache)}return Fc(e,t,n)}function Rc(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps)lc=!0;else{if(!Ic(e,n)&&!(t.flags&128))return lc=!1,Lc(e,t,n);lc=!!(e.flags&131072)}else lc=!1,I&&t.flags&1048576&&Mi(t,Ti,t.index);switch(t.lanes=0,t.tag){case 16:a:{var r=t.pendingProps;if(e=ja(t.elementType),t.type=e,typeof e==`function`)fi(e)?(r=Qs(e,r),t.tag=1,t=Cc(null,t,e,r,n)):(t.tag=0,t=xc(null,t,e,r,n));else{if(e!=null){var a=e.$$typeof;if(a===w){t.tag=11,t=dc(null,t,e,r,n);break a}else if(a===D){t.tag=14,t=fc(null,t,e,r,n);break a}}throw t=k(e)||e,Error(i(306,t,``))}}return t;case 0:return xc(e,t,t.type,t.pendingProps,n);case 1:return r=t.type,a=Qs(r,t.pendingProps),Cc(e,t,r,a,n);case 3:a:{if(me(t,t.stateNode.containerInfo),e===null)throw Error(i(387));r=t.pendingProps;var o=t.memoizedState;a=o.element,Ga(e,t),Qa(t,r,null,n);var s=t.memoizedState;if(r=s.cache,Zi(t,ua,r),r!==o.cache&&ea(t,[ua],n,!0),Za(),r=s.element,o.isDehydrated)if(o={element:r,isDehydrated:!1,cache:s.cache},t.updateQueue.baseState=o,t.memoizedState=o,t.flags&256){t=wc(e,t,r,n);break a}else if(r!==a){a=xi(Error(i(424)),t),qi(a),t=wc(e,t,r,n);break a}else{switch(e=t.stateNode.containerInfo,e.nodeType){case 9:e=e.body;break;default:e=e.nodeName===`HTML`?e.ownerDocument.body:e}for(Li=J(e.firstChild),Ii=t,I=!0,Ri=null,zi=!0,n=Ha(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling}else{if(Gi(),r===a){t=Fc(e,t,n);break a}uc(e,t,r,n)}t=t.child}return t;case 26:return bc(e,t),e===null?(n=Nf(t.type,null,t.pendingProps,null))?t.memoizedState=n:I||(n=t.type,e=t.pendingProps,r=Kd(fe.current).createElement(n),r[lt]=t,r[ut]=e,Bd(r,n,e),St(r),t.stateNode=r):t.memoizedState=Nf(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return ge(t),e===null&&I&&(r=t.stateNode=_f(t.type,t.pendingProps,fe.current),Ii=t,zi=!0,a=Li,rf(t.type)?(mf=a,Li=J(r.firstChild)):Li=a),uc(e,t,t.pendingProps.children,n),bc(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&I&&((a=r=Li)&&(r=cf(r,t.type,t.pendingProps,zi),r===null?a=!1:(t.stateNode=r,Ii=t,Li=J(r.firstChild),zi=!1,a=!0)),a||Vi(t)),ge(t),a=t.type,o=t.pendingProps,s=e===null?null:e.memoizedProps,r=o.children,Yd(a,o)?r=null:s!==null&&Yd(a,s)&&(t.flags|=32),t.memoizedState!==null&&(a=Oo(e,t,jo,null,null,n),np._currentValue=a),bc(e,t),uc(e,t,r,n),t.child;case 6:return e===null&&I&&((e=n=Li)&&(n=lf(n,t.pendingProps,zi),n===null?e=!1:(t.stateNode=n,Ii=t,Li=null,e=!0)),e||Vi(t)),null;case 13:return Oc(e,t,n);case 4:return me(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Va(t,null,r,n):uc(e,t,r,n),t.child;case 11:return dc(e,t,t.type,t.pendingProps,n);case 7:return uc(e,t,t.pendingProps,n),t.child;case 8:return uc(e,t,t.pendingProps.children,n),t.child;case 12:return uc(e,t,t.pendingProps.children,n),t.child;case 10:return r=t.pendingProps,Zi(t,t.type,r.value),uc(e,t,r.children,n),t.child;case 9:return a=t.type._context,r=t.pendingProps.children,ra(t),a=ia(a),r=r(a),t.flags|=1,uc(e,t,r,n),t.child;case 14:return fc(e,t,t.type,t.pendingProps,n);case 15:return pc(e,t,t.type,t.pendingProps,n);case 19:return Pc(e,t,n);case 31:return yc(e,t,n);case 22:return mc(e,t,n,t.pendingProps);case 24:return ra(t),r=ia(ua),e===null?(a=Sa(),a===null&&(a=Gl,o=da(),a.pooledCache=o,o.refCount++,o!==null&&(a.pooledCacheLanes|=n),a=o),t.memoizedState={parent:r,cache:a},Wa(t),Zi(t,ua,a)):((e.lanes&n)!==0&&(Ga(e,t),Qa(t,null,null,n),Za()),a=e.memoizedState,o=t.memoizedState,a.parent===r?(r=o.cache,Zi(t,ua,r),r!==a.cache&&ea(t,[ua],n,!0)):(a={parent:r,cache:r},t.memoizedState=a,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=a),Zi(t,ua,r))),uc(e,t,t.pendingProps.children,n),t.child;case 29:throw t.pendingProps}throw Error(i(156,t.tag))}function zc(e){e.flags|=4}function Bc(e,t,n,r,i){if((t=(e.mode&32)!=0)&&(t=!1),t){if(e.flags|=16777216,(i&335544128)===i)if(e.stateNode.complete)e.flags|=8192;else if(Au())e.flags|=8192;else throw Ma=Oa,Ea}else e.flags&=-16777217}function Vc(e,t){if(t.type!==`stylesheet`||t.state.loading&4)e.flags&=-16777217;else if(e.flags|=16777216,!Jf(t))if(Au())e.flags|=8192;else throw Ma=Oa,Ea}function Hc(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag===22?536870912:Ze(),e.lanes|=t,nu|=t)}function Uc(e,t){if(!I)switch(e.tailMode){case`hidden`:t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case`collapsed`:n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function R(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags&65011712,r|=i.flags&65011712,i.return=e,i=i.sibling;else for(i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags,r|=i.flags,i.return=e,i=i.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function Wc(e,t,n){var r=t.pendingProps;switch(Pi(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return R(t),null;case 1:return R(t),null;case 3:return n=t.stateNode,r=null,e!==null&&(r=e.memoizedState.cache),t.memoizedState.cache!==r&&(t.flags|=2048),Qi(ua),he(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),(e===null||e.child===null)&&(Wi(t)?zc(t):e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Ki())),R(t),null;case 26:var a=t.type,o=t.memoizedState;return e===null?(zc(t),o===null?(R(t),Bc(t,a,null,r,n)):(R(t),Vc(t,o))):o?o===e.memoizedState?(R(t),t.flags&=-16777217):(zc(t),R(t),Vc(t,o)):(e=e.memoizedProps,e!==r&&zc(t),R(t),Bc(t,a,e,r,n)),null;case 27:if(_e(t),n=fe.current,a=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&zc(t);else{if(!r){if(t.stateNode===null)throw Error(i(166));return R(t),null}e=ue.current,Wi(t)?Hi(t,e):(e=_f(a,r,n),t.stateNode=e,zc(t))}return R(t),null;case 5:if(_e(t),a=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&zc(t);else{if(!r){if(t.stateNode===null)throw Error(i(166));return R(t),null}if(o=ue.current,Wi(t))Hi(t,o);else{var s=Kd(fe.current);switch(o){case 1:o=s.createElementNS(`http://www.w3.org/2000/svg`,a);break;case 2:o=s.createElementNS(`http://www.w3.org/1998/Math/MathML`,a);break;default:switch(a){case`svg`:o=s.createElementNS(`http://www.w3.org/2000/svg`,a);break;case`math`:o=s.createElementNS(`http://www.w3.org/1998/Math/MathML`,a);break;case`script`:o=s.createElement(`div`),o.innerHTML=`<script><\/script>`,o=o.removeChild(o.firstChild);break;case`select`:o=typeof r.is==`string`?s.createElement(`select`,{is:r.is}):s.createElement(`select`),r.multiple?o.multiple=!0:r.size&&(o.size=r.size);break;default:o=typeof r.is==`string`?s.createElement(a,{is:r.is}):s.createElement(a)}}o[lt]=t,o[ut]=r;a:for(s=t.child;s!==null;){if(s.tag===5||s.tag===6)o.appendChild(s.stateNode);else if(s.tag!==4&&s.tag!==27&&s.child!==null){s.child.return=s,s=s.child;continue}if(s===t)break a;for(;s.sibling===null;){if(s.return===null||s.return===t)break a;s=s.return}s.sibling.return=s.return,s=s.sibling}t.stateNode=o;a:switch(Bd(o,a,r),a){case`button`:case`input`:case`select`:case`textarea`:r=!!r.autoFocus;break a;case`img`:r=!0;break a;default:r=!1}r&&zc(t)}}return R(t),Bc(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,n),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==r&&zc(t);else{if(typeof r!=`string`&&t.stateNode===null)throw Error(i(166));if(e=fe.current,Wi(t)){if(e=t.stateNode,n=t.memoizedProps,r=null,a=Ii,a!==null)switch(a.tag){case 27:case 5:r=a.memoizedProps}e[lt]=t,e=!!(e.nodeValue===n||r!==null&&!0===r.suppressHydrationWarning||Ld(e.nodeValue,n)),e||Vi(t,!0)}else e=Kd(e).createTextNode(r),e[lt]=t,t.stateNode=e}return R(t),null;case 31:if(n=t.memoizedState,e===null||e.memoizedState!==null){if(r=Wi(t),n!==null){if(e===null){if(!r)throw Error(i(318));if(e=t.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(557));e[lt]=t}else Gi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;R(t),e=!1}else n=Ki(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=n),e=!0;if(!e)return t.flags&256?(po(t),t):(po(t),null);if(t.flags&128)throw Error(i(558))}return R(t),null;case 13:if(r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(a=Wi(t),r!==null&&r.dehydrated!==null){if(e===null){if(!a)throw Error(i(318));if(a=t.memoizedState,a=a===null?null:a.dehydrated,!a)throw Error(i(317));a[lt]=t}else Gi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;R(t),a=!1}else a=Ki(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=a),a=!0;if(!a)return t.flags&256?(po(t),t):(po(t),null)}return po(t),t.flags&128?(t.lanes=n,t):(n=r!==null,e=e!==null&&e.memoizedState!==null,n&&(r=t.child,a=null,r.alternate!==null&&r.alternate.memoizedState!==null&&r.alternate.memoizedState.cachePool!==null&&(a=r.alternate.memoizedState.cachePool.pool),o=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(o=r.memoizedState.cachePool.pool),o!==a&&(r.flags|=2048)),n!==e&&n&&(t.child.flags|=8192),Hc(t,t.updateQueue),R(t),null);case 4:return he(),e===null&&Od(t.stateNode.containerInfo),R(t),null;case 10:return Qi(t.type),R(t),null;case 19:if(M(mo),r=t.memoizedState,r===null)return R(t),null;if(a=(t.flags&128)!=0,o=r.rendering,o===null)if(a)Uc(r,!1);else{if(Zl!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=ho(e),o!==null){for(t.flags|=128,Uc(r,!1),e=o.updateQueue,t.updateQueue=e,Hc(t,e),t.subtreeFlags=0,e=n,n=t.child;n!==null;)mi(n,e),n=n.sibling;return N(mo,mo.current&1|2),I&&ji(t,r.treeForkCount),t.child}e=e.sibling}r.tail!==null&&Ae()>W&&(t.flags|=128,a=!0,Uc(r,!1),t.lanes=4194304)}else{if(!a)if(e=ho(o),e!==null){if(t.flags|=128,a=!0,e=e.updateQueue,t.updateQueue=e,Hc(t,e),Uc(r,!0),r.tail===null&&r.tailMode===`hidden`&&!o.alternate&&!I)return R(t),null}else 2*Ae()-r.renderingStartTime>W&&n!==536870912&&(t.flags|=128,a=!0,Uc(r,!1),t.lanes=4194304);r.isBackwards?(o.sibling=t.child,t.child=o):(e=r.last,e===null?t.child=o:e.sibling=o,r.last=o)}return r.tail===null?(R(t),null):(e=r.tail,r.rendering=e,r.tail=e.sibling,r.renderingStartTime=Ae(),e.sibling=null,n=mo.current,N(mo,a?n&1|2:n&1),I&&ji(t,r.treeForkCount),e);case 22:case 23:return po(t),ao(),r=t.memoizedState!==null,e===null?r&&(t.flags|=8192):e.memoizedState!==null!==r&&(t.flags|=8192),r?n&536870912&&!(t.flags&128)&&(R(t),t.subtreeFlags&6&&(t.flags|=8192)):R(t),n=t.updateQueue,n!==null&&Hc(t,n.retryQueue),n=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),r=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(r=t.memoizedState.cachePool.pool),r!==n&&(t.flags|=2048),e!==null&&M(xa),null;case 24:return n=null,e!==null&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),Qi(ua),R(t),null;case 25:return null;case 30:return null}throw Error(i(156,t.tag))}function Gc(e,t){switch(Pi(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Qi(ua),he(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return _e(t),null;case 31:if(t.memoizedState!==null){if(po(t),t.alternate===null)throw Error(i(340));Gi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(po(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(i(340));Gi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return M(mo),null;case 4:return he(),null;case 10:return Qi(t.type),null;case 22:case 23:return po(t),ao(),e!==null&&M(xa),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return Qi(ua),null;case 25:return null;default:return null}}function Kc(e,t){switch(Pi(t),t.tag){case 3:Qi(ua),he();break;case 26:case 27:case 5:_e(t);break;case 4:he();break;case 31:t.memoizedState!==null&&po(t);break;case 13:po(t);break;case 19:M(mo);break;case 10:Qi(t.type);break;case 22:case 23:po(t),ao(),e!==null&&M(xa);break;case 24:Qi(ua)}}function qc(e,t){try{var n=t.updateQueue,r=n===null?null:n.lastEffect;if(r!==null){var i=r.next;n=i;do{if((n.tag&e)===e){r=void 0;var a=n.create,o=n.inst;r=a(),o.destroy=r}n=n.next}while(n!==i)}}catch(e){G(t,t.return,e)}}function Jc(e,t,n){try{var r=t.updateQueue,i=r===null?null:r.lastEffect;if(i!==null){var a=i.next;r=a;do{if((r.tag&e)===e){var o=r.inst,s=o.destroy;if(s!==void 0){o.destroy=void 0,i=t;var c=n,l=s;try{l()}catch(e){G(i,c,e)}}}r=r.next}while(r!==a)}}catch(e){G(t,t.return,e)}}function Yc(e){var t=e.updateQueue;if(t!==null){var n=e.stateNode;try{eo(t,n)}catch(t){G(e,e.return,t)}}}function Xc(e,t,n){n.props=Qs(e.type,e.memoizedProps),n.state=e.memoizedState;try{n.componentWillUnmount()}catch(n){G(e,t,n)}}function Zc(e,t){try{var n=e.ref;if(n!==null){switch(e.tag){case 26:case 27:case 5:var r=e.stateNode;break;case 30:r=e.stateNode;break;default:r=e.stateNode}typeof n==`function`?e.refCleanup=n(r):n.current=r}}catch(n){G(e,t,n)}}function Qc(e,t){var n=e.ref,r=e.refCleanup;if(n!==null)if(typeof r==`function`)try{r()}catch(n){G(e,t,n)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof n==`function`)try{n(null)}catch(n){G(e,t,n)}else n.current=null}function $c(e){var t=e.type,n=e.memoizedProps,r=e.stateNode;try{a:switch(t){case`button`:case`input`:case`select`:case`textarea`:n.autoFocus&&r.focus();break a;case`img`:n.src?r.src=n.src:n.srcSet&&(r.srcset=n.srcSet)}}catch(t){G(e,e.return,t)}}function el(e,t,n){try{var r=e.stateNode;Vd(r,e.type,n,t),r[ut]=t}catch(t){G(e,e.return,t)}}function tl(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&rf(e.type)||e.tag===4}function nl(e){a:for(;;){for(;e.sibling===null;){if(e.return===null||tl(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&rf(e.type)||e.flags&2||e.child===null||e.tag===4)continue a;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function rl(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?(n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n).insertBefore(e,t):(t=n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n,t.appendChild(e),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=nn));else if(r!==4&&(r===27&&rf(e.type)&&(n=e.stateNode,t=null),e=e.child,e!==null))for(rl(e,t,n),e=e.sibling;e!==null;)rl(e,t,n),e=e.sibling}function il(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(r===27&&rf(e.type)&&(n=e.stateNode),e=e.child,e!==null))for(il(e,t,n),e=e.sibling;e!==null;)il(e,t,n),e=e.sibling}function al(e){var t=e.stateNode,n=e.memoizedProps;try{for(var r=e.type,i=t.attributes;i.length;)t.removeAttributeNode(i[0]);Bd(t,r,n),t[lt]=e,t[ut]=n}catch(t){G(e,e.return,t)}}var ol=!1,sl=!1,cl=!1,ll=typeof WeakSet==`function`?WeakSet:Set,ul=null;function dl(e,t){if(e=e.containerInfo,Wd=dp,e=Ar(e),jr(e)){if(`selectionStart`in e)var n={start:e.selectionStart,end:e.selectionEnd};else a:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var a=r.anchorOffset,o=r.focusNode;r=r.focusOffset;try{n.nodeType,o.nodeType}catch{n=null;break a}var s=0,c=-1,l=-1,u=0,d=0,f=e,p=null;b:for(;;){for(var m;f!==n||a!==0&&f.nodeType!==3||(c=s+a),f!==o||r!==0&&f.nodeType!==3||(l=s+r),f.nodeType===3&&(s+=f.nodeValue.length),(m=f.firstChild)!==null;)p=f,f=m;for(;;){if(f===e)break b;if(p===n&&++u===a&&(c=s),p===o&&++d===r&&(l=s),(m=f.nextSibling)!==null)break;f=p,p=f.parentNode}f=m}n=c===-1||l===-1?null:{start:c,end:l}}else n=null}n||={start:0,end:0}}else n=null;for(Gd={focusedElem:e,selectionRange:n},dp=!1,ul=t;ul!==null;)if(t=ul,e=t.child,t.subtreeFlags&1028&&e!==null)e.return=t,ul=e;else for(;ul!==null;){switch(t=ul,o=t.alternate,e=t.flags,t.tag){case 0:if(e&4&&(e=t.updateQueue,e=e===null?null:e.events,e!==null))for(n=0;n<e.length;n++)a=e[n],a.ref.impl=a.nextImpl;break;case 11:case 15:break;case 1:if(e&1024&&o!==null){e=void 0,n=t,a=o.memoizedProps,o=o.memoizedState,r=n.stateNode;try{var h=Qs(n.type,a);e=r.getSnapshotBeforeUpdate(h,o),r.__reactInternalSnapshotBeforeUpdate=e}catch(e){G(n,n.return,e)}}break;case 3:if(e&1024){if(e=t.stateNode.containerInfo,n=e.nodeType,n===9)sf(e);else if(n===1)switch(e.nodeName){case`HEAD`:case`HTML`:case`BODY`:sf(e);break;default:e.textContent=``}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if(e&1024)throw Error(i(163))}if(e=t.sibling,e!==null){e.return=t.return,ul=e;break}ul=t.return}}function fl(e,t,n){var r=n.flags;switch(n.tag){case 0:case 11:case 15:Dl(e,n),r&4&&qc(5,n);break;case 1:if(Dl(e,n),r&4)if(e=n.stateNode,t===null)try{e.componentDidMount()}catch(e){G(n,n.return,e)}else{var i=Qs(n.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(i,t,e.__reactInternalSnapshotBeforeUpdate)}catch(e){G(n,n.return,e)}}r&64&&Yc(n),r&512&&Zc(n,n.return);break;case 3:if(Dl(e,n),r&64&&(e=n.updateQueue,e!==null)){if(t=null,n.child!==null)switch(n.child.tag){case 27:case 5:t=n.child.stateNode;break;case 1:t=n.child.stateNode}try{eo(e,t)}catch(e){G(n,n.return,e)}}break;case 27:t===null&&r&4&&al(n);case 26:case 5:Dl(e,n),t===null&&r&4&&$c(n),r&512&&Zc(n,n.return);break;case 12:Dl(e,n);break;case 31:Dl(e,n),r&4&&vl(e,n);break;case 13:Dl(e,n),r&4&&yl(e,n),r&64&&(e=n.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(n=ed.bind(null,n),pf(e,n))));break;case 22:if(r=n.memoizedState!==null||ol,!r){t=t!==null&&t.memoizedState!==null||sl,i=ol;var a=sl;ol=r,(sl=t)&&!a?kl(e,n,(n.subtreeFlags&8772)!=0):Dl(e,n),ol=i,sl=a}break;case 30:break;default:Dl(e,n)}}function pl(e){var t=e.alternate;t!==null&&(e.alternate=null,pl(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&_t(t)),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}var ml=null,hl=!1;function gl(e,t,n){for(n=n.child;n!==null;)_l(e,t,n),n=n.sibling}function _l(e,t,n){if(P&&typeof P.onCommitFiberUnmount==`function`)try{P.onCommitFiberUnmount(ze,n)}catch{}switch(n.tag){case 26:sl||Qc(n,t),gl(e,t,n),n.memoizedState?n.memoizedState.count--:n.stateNode&&(n=n.stateNode,n.parentNode.removeChild(n));break;case 27:sl||Qc(n,t);var r=ml,i=hl;rf(n.type)&&(ml=n.stateNode,hl=!1),gl(e,t,n),vf(n.stateNode),ml=r,hl=i;break;case 5:sl||Qc(n,t);case 6:if(r=ml,i=hl,ml=null,gl(e,t,n),ml=r,hl=i,ml!==null)if(hl)try{(ml.nodeType===9?ml.body:ml.nodeName===`HTML`?ml.ownerDocument.body:ml).removeChild(n.stateNode)}catch(e){G(n,t,e)}else try{ml.removeChild(n.stateNode)}catch(e){G(n,t,e)}break;case 18:ml!==null&&(hl?(e=ml,af(e.nodeType===9?e.body:e.nodeName===`HTML`?e.ownerDocument.body:e,n.stateNode),Lp(e)):af(ml,n.stateNode));break;case 4:r=ml,i=hl,ml=n.stateNode.containerInfo,hl=!0,gl(e,t,n),ml=r,hl=i;break;case 0:case 11:case 14:case 15:Jc(2,n,t),sl||Jc(4,n,t),gl(e,t,n);break;case 1:sl||(Qc(n,t),r=n.stateNode,typeof r.componentWillUnmount==`function`&&Xc(n,t,r)),gl(e,t,n);break;case 21:gl(e,t,n);break;case 22:sl=(r=sl)||n.memoizedState!==null,gl(e,t,n),sl=r;break;default:gl(e,t,n)}}function vl(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{Lp(e)}catch(e){G(t,t.return,e)}}}function yl(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Lp(e)}catch(e){G(t,t.return,e)}}function bl(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new ll),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new ll),t;default:throw Error(i(435,e.tag))}}function xl(e,t){var n=bl(e);t.forEach(function(t){if(!n.has(t)){n.add(t);var r=td.bind(null,e,t);t.then(r,r)}})}function Sl(e,t){var n=t.deletions;if(n!==null)for(var r=0;r<n.length;r++){var a=n[r],o=e,s=t,c=s;a:for(;c!==null;){switch(c.tag){case 27:if(rf(c.type)){ml=c.stateNode,hl=!1;break a}break;case 5:ml=c.stateNode,hl=!1;break a;case 3:case 4:ml=c.stateNode.containerInfo,hl=!0;break a}c=c.return}if(ml===null)throw Error(i(160));_l(o,s,a),ml=null,hl=!1,o=a.alternate,o!==null&&(o.return=null),a.return=null}if(t.subtreeFlags&13886)for(t=t.child;t!==null;)wl(t,e),t=t.sibling}var Cl=null;function wl(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:Sl(t,e),Tl(e),r&4&&(Jc(3,e,e.return),qc(3,e),Jc(5,e,e.return));break;case 1:Sl(t,e),Tl(e),r&512&&(sl||n===null||Qc(n,n.return)),r&64&&ol&&(e=e.updateQueue,e!==null&&(r=e.callbacks,r!==null&&(n=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=n===null?r:n.concat(r))));break;case 26:var a=Cl;if(Sl(t,e),Tl(e),r&512&&(sl||n===null||Qc(n,n.return)),r&4){var o=n===null?null:n.memoizedState;if(r=e.memoizedState,n===null)if(r===null)if(e.stateNode===null){a:{r=e.type,n=e.memoizedProps,a=a.ownerDocument||a;b:switch(r){case`title`:o=a.getElementsByTagName(`title`)[0],(!o||o[gt]||o[lt]||o.namespaceURI===`http://www.w3.org/2000/svg`||o.hasAttribute(`itemprop`))&&(o=a.createElement(r),a.head.insertBefore(o,a.querySelector(`head > title`))),Bd(o,r,n),o[lt]=e,St(o),r=o;break a;case`link`:var s=Gf(`link`,`href`,a).get(r+(n.href||``));if(s){for(var c=0;c<s.length;c++)if(o=s[c],o.getAttribute(`href`)===(n.href==null||n.href===``?null:n.href)&&o.getAttribute(`rel`)===(n.rel==null?null:n.rel)&&o.getAttribute(`title`)===(n.title==null?null:n.title)&&o.getAttribute(`crossorigin`)===(n.crossOrigin==null?null:n.crossOrigin)){s.splice(c,1);break b}}o=a.createElement(r),Bd(o,r,n),a.head.appendChild(o);break;case`meta`:if(s=Gf(`meta`,`content`,a).get(r+(n.content||``))){for(c=0;c<s.length;c++)if(o=s[c],o.getAttribute(`content`)===(n.content==null?null:``+n.content)&&o.getAttribute(`name`)===(n.name==null?null:n.name)&&o.getAttribute(`property`)===(n.property==null?null:n.property)&&o.getAttribute(`http-equiv`)===(n.httpEquiv==null?null:n.httpEquiv)&&o.getAttribute(`charset`)===(n.charSet==null?null:n.charSet)){s.splice(c,1);break b}}o=a.createElement(r),Bd(o,r,n),a.head.appendChild(o);break;default:throw Error(i(468,r))}o[lt]=e,St(o),r=o}e.stateNode=r}else Kf(a,e.type,e.stateNode);else e.stateNode=Bf(a,r,e.memoizedProps);else o===r?r===null&&e.stateNode!==null&&el(e,e.memoizedProps,n.memoizedProps):(o===null?n.stateNode!==null&&(n=n.stateNode,n.parentNode.removeChild(n)):o.count--,r===null?Kf(a,e.type,e.stateNode):Bf(a,r,e.memoizedProps))}break;case 27:Sl(t,e),Tl(e),r&512&&(sl||n===null||Qc(n,n.return)),n!==null&&r&4&&el(e,e.memoizedProps,n.memoizedProps);break;case 5:if(Sl(t,e),Tl(e),r&512&&(sl||n===null||Qc(n,n.return)),e.flags&32){a=e.stateNode;try{Jt(a,``)}catch(t){G(e,e.return,t)}}r&4&&e.stateNode!=null&&(a=e.memoizedProps,el(e,a,n===null?a:n.memoizedProps)),r&1024&&(cl=!0);break;case 6:if(Sl(t,e),Tl(e),r&4){if(e.stateNode===null)throw Error(i(162));r=e.memoizedProps,n=e.stateNode;try{n.nodeValue=r}catch(t){G(e,e.return,t)}}break;case 3:if(Wf=null,a=Cl,Cl=Y(t.containerInfo),Sl(t,e),Cl=a,Tl(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{Lp(t.containerInfo)}catch(t){G(e,e.return,t)}cl&&(cl=!1,El(e));break;case 4:r=Cl,Cl=Y(e.stateNode.containerInfo),Sl(t,e),Tl(e),Cl=r;break;case 12:Sl(t,e),Tl(e);break;case 31:Sl(t,e),Tl(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,xl(e,r)));break;case 13:Sl(t,e),Tl(e),e.child.flags&8192&&e.memoizedState!==null!=(n!==null&&n.memoizedState!==null)&&(ou=Ae()),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,xl(e,r)));break;case 22:a=e.memoizedState!==null;var l=n!==null&&n.memoizedState!==null,u=ol,d=sl;if(ol=u||a,sl=d||l,Sl(t,e),sl=d,ol=u,Tl(e),r&8192)a:for(t=e.stateNode,t._visibility=a?t._visibility&-2:t._visibility|1,a&&(n===null||l||ol||sl||Ol(e)),n=null,t=e;;){if(t.tag===5||t.tag===26){if(n===null){l=n=t;try{if(o=l.stateNode,a)s=o.style,typeof s.setProperty==`function`?s.setProperty(`display`,`none`,`important`):s.display=`none`;else{c=l.stateNode;var f=l.memoizedProps.style,p=f!=null&&f.hasOwnProperty(`display`)?f.display:null;c.style.display=p==null||typeof p==`boolean`?``:(``+p).trim()}}catch(e){G(l,l.return,e)}}}else if(t.tag===6){if(n===null){l=t;try{l.stateNode.nodeValue=a?``:l.memoizedProps}catch(e){G(l,l.return,e)}}}else if(t.tag===18){if(n===null){l=t;try{var m=l.stateNode;a?of(m,!0):of(l.stateNode,!1)}catch(e){G(l,l.return,e)}}}else if((t.tag!==22&&t.tag!==23||t.memoizedState===null||t===e)&&t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break a;for(;t.sibling===null;){if(t.return===null||t.return===e)break a;n===t&&(n=null),t=t.return}n===t&&(n=null),t.sibling.return=t.return,t=t.sibling}r&4&&(r=e.updateQueue,r!==null&&(n=r.retryQueue,n!==null&&(r.retryQueue=null,xl(e,n))));break;case 19:Sl(t,e),Tl(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,xl(e,r)));break;case 30:break;case 21:break;default:Sl(t,e),Tl(e)}}function Tl(e){var t=e.flags;if(t&2){try{for(var n,r=e.return;r!==null;){if(tl(r)){n=r;break}r=r.return}if(n==null)throw Error(i(160));switch(n.tag){case 27:var a=n.stateNode;il(e,nl(e),a);break;case 5:var o=n.stateNode;n.flags&32&&(Jt(o,``),n.flags&=-33),il(e,nl(e),o);break;case 3:case 4:var s=n.stateNode.containerInfo;rl(e,nl(e),s);break;default:throw Error(i(161))}}catch(t){G(e,e.return,t)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function El(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;El(t),t.tag===5&&t.flags&1024&&t.stateNode.reset(),e=e.sibling}}function Dl(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)fl(e,t.alternate,t),t=t.sibling}function Ol(e){for(e=e.child;e!==null;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:Jc(4,t,t.return),Ol(t);break;case 1:Qc(t,t.return);var n=t.stateNode;typeof n.componentWillUnmount==`function`&&Xc(t,t.return,n),Ol(t);break;case 27:vf(t.stateNode);case 26:case 5:Qc(t,t.return),Ol(t);break;case 22:t.memoizedState===null&&Ol(t);break;case 30:Ol(t);break;default:Ol(t)}e=e.sibling}}function kl(e,t,n){for(n&&=(t.subtreeFlags&8772)!=0,t=t.child;t!==null;){var r=t.alternate,i=e,a=t,o=a.flags;switch(a.tag){case 0:case 11:case 15:kl(i,a,n),qc(4,a);break;case 1:if(kl(i,a,n),r=a,i=r.stateNode,typeof i.componentDidMount==`function`)try{i.componentDidMount()}catch(e){G(r,r.return,e)}if(r=a,i=r.updateQueue,i!==null){var s=r.stateNode;try{var c=i.shared.hiddenCallbacks;if(c!==null)for(i.shared.hiddenCallbacks=null,i=0;i<c.length;i++)$a(c[i],s)}catch(e){G(r,r.return,e)}}n&&o&64&&Yc(a),Zc(a,a.return);break;case 27:al(a);case 26:case 5:kl(i,a,n),n&&r===null&&o&4&&$c(a),Zc(a,a.return);break;case 12:kl(i,a,n);break;case 31:kl(i,a,n),n&&o&4&&vl(i,a);break;case 13:kl(i,a,n),n&&o&4&&yl(i,a);break;case 22:a.memoizedState===null&&kl(i,a,n),Zc(a,a.return);break;case 30:break;default:kl(i,a,n)}t=t.sibling}}function Al(e,t){var n=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),e=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(e=t.memoizedState.cachePool.pool),e!==n&&(e!=null&&e.refCount++,n!=null&&fa(n))}function jl(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&fa(e))}function Ml(e,t,n,r){if(t.subtreeFlags&10256)for(t=t.child;t!==null;)Nl(e,t,n,r),t=t.sibling}function Nl(e,t,n,r){var i=t.flags;switch(t.tag){case 0:case 11:case 15:Ml(e,t,n,r),i&2048&&qc(9,t);break;case 1:Ml(e,t,n,r);break;case 3:Ml(e,t,n,r),i&2048&&(e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&fa(e)));break;case 12:if(i&2048){Ml(e,t,n,r),e=t.stateNode;try{var a=t.memoizedProps,o=a.id,s=a.onPostCommit;typeof s==`function`&&s(o,t.alternate===null?`mount`:`update`,e.passiveEffectDuration,-0)}catch(e){G(t,t.return,e)}}else Ml(e,t,n,r);break;case 31:Ml(e,t,n,r);break;case 13:Ml(e,t,n,r);break;case 23:break;case 22:a=t.stateNode,o=t.alternate,t.memoizedState===null?a._visibility&2?Ml(e,t,n,r):(a._visibility|=2,Pl(e,t,n,r,(t.subtreeFlags&10256)!=0||!1)):a._visibility&2?Ml(e,t,n,r):Fl(e,t),i&2048&&Al(o,t);break;case 24:Ml(e,t,n,r),i&2048&&jl(t.alternate,t);break;default:Ml(e,t,n,r)}}function Pl(e,t,n,r,i){for(i&&=(t.subtreeFlags&10256)!=0||!1,t=t.child;t!==null;){var a=e,o=t,s=n,c=r,l=o.flags;switch(o.tag){case 0:case 11:case 15:Pl(a,o,s,c,i),qc(8,o);break;case 23:break;case 22:var u=o.stateNode;o.memoizedState===null?(u._visibility|=2,Pl(a,o,s,c,i)):u._visibility&2?Pl(a,o,s,c,i):Fl(a,o),i&&l&2048&&Al(o.alternate,o);break;case 24:Pl(a,o,s,c,i),i&&l&2048&&jl(o.alternate,o);break;default:Pl(a,o,s,c,i)}t=t.sibling}}function Fl(e,t){if(t.subtreeFlags&10256)for(t=t.child;t!==null;){var n=e,r=t,i=r.flags;switch(r.tag){case 22:Fl(n,r),i&2048&&Al(r.alternate,r);break;case 24:Fl(n,r),i&2048&&jl(r.alternate,r);break;default:Fl(n,r)}t=t.sibling}}var Il=8192;function Ll(e,t,n){if(e.subtreeFlags&Il)for(e=e.child;e!==null;)z(e,t,n),e=e.sibling}function z(e,t,n){switch(e.tag){case 26:Ll(e,t,n),e.flags&Il&&e.memoizedState!==null&&Yf(n,Cl,e.memoizedState,e.memoizedProps);break;case 5:Ll(e,t,n);break;case 3:case 4:var r=Cl;Cl=Y(e.stateNode.containerInfo),Ll(e,t,n),Cl=r;break;case 22:e.memoizedState===null&&(r=e.alternate,r!==null&&r.memoizedState!==null?(r=Il,Il=16777216,Ll(e,t,n),Il=r):Ll(e,t,n));break;default:Ll(e,t,n)}}function Rl(e){var t=e.alternate;if(t!==null&&(e=t.child,e!==null)){t.child=null;do t=e.sibling,e.sibling=null,e=t;while(e!==null)}}function zl(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];ul=r,Hl(r,e)}Rl(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)Bl(e),e=e.sibling}function Bl(e){switch(e.tag){case 0:case 11:case 15:zl(e),e.flags&2048&&Jc(9,e,e.return);break;case 3:zl(e);break;case 12:zl(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,Vl(e)):zl(e);break;default:zl(e)}}function Vl(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];ul=r,Hl(r,e)}Rl(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:Jc(8,t,t.return),Vl(t);break;case 22:n=t.stateNode,n._visibility&2&&(n._visibility&=-3,Vl(t));break;default:Vl(t)}e=e.sibling}}function Hl(e,t){for(;ul!==null;){var n=ul;switch(n.tag){case 0:case 11:case 15:Jc(8,n,t);break;case 23:case 22:if(n.memoizedState!==null&&n.memoizedState.cachePool!==null){var r=n.memoizedState.cachePool.pool;r!=null&&r.refCount++}break;case 24:fa(n.memoizedState.cache)}if(r=n.child,r!==null)r.return=n,ul=r;else a:for(n=e;ul!==null;){r=ul;var i=r.sibling,a=r.return;if(pl(r),r===n){ul=null;break a}if(i!==null){i.return=a,ul=i;break a}ul=a}}}var Ul={getCacheForType:function(e){var t=ia(ua),n=t.data.get(e);return n===void 0&&(n=e(),t.data.set(e,n)),n},cacheSignal:function(){return ia(ua).controller.signal}},Wl=typeof WeakMap==`function`?WeakMap:Map,B=0,Gl=null,V=null,H=0,U=0,Kl=null,ql=!1,Jl=!1,Yl=!1,Xl=0,Zl=0,Ql=0,$l=0,eu=0,tu=0,nu=0,ru=null,iu=null,au=!1,ou=0,su=0,W=1/0,cu=null,lu=null,uu=0,du=null,fu=null,pu=0,mu=0,hu=null,gu=null,_u=0,vu=null;function yu(){return B&2&&H!==0?H&-H:A.T===null?ot():_d()}function bu(){if(tu===0)if(!(H&536870912)||I){var e=Ke;Ke<<=1,!(Ke&3932160)&&(Ke=262144),tu=e}else tu=536870912;return e=oo.current,e!==null&&(e.flags|=32),tu}function xu(e,t,n){(e===Gl&&(U===2||U===9)||e.cancelPendingCommit!==null)&&(Ou(e,0),Tu(e,H,tu,!1)),$e(e,n),(!(B&2)||e!==Gl)&&(e===Gl&&(!(B&2)&&($l|=n),Zl===4&&Tu(e,H,tu,!1)),ld(e))}function Su(e,t,n){if(B&6)throw Error(i(327));var r=!n&&(t&127)==0&&(t&e.expiredLanes)===0||Xe(e,t),a=r?Iu(e,t):Pu(e,t,!0),o=r;do{if(a===0){Jl&&!r&&Tu(e,t,0,!1);break}else{if(n=e.current.alternate,o&&!wu(n)){a=Pu(e,t,!1),o=!1;continue}if(a===2){if(o=t,e.errorRecoveryDisabledLanes&o)var s=0;else s=e.pendingLanes&-536870913,s=s===0?s&536870912?536870912:0:s;if(s!==0){t=s;a:{var c=e;a=ru;var l=c.current.memoizedState.isDehydrated;if(l&&(Ou(c,s).flags|=256),s=Pu(c,s,!1),s!==2){if(Yl&&!l){c.errorRecoveryDisabledLanes|=o,$l|=o,a=4;break a}o=iu,iu=a,o!==null&&(iu===null?iu=o:iu.push.apply(iu,o))}a=s}if(o=!1,a!==2)continue}}if(a===1){Ou(e,0),Tu(e,t,0,!0);break}a:{switch(r=e,o=a,o){case 0:case 1:throw Error(i(345));case 4:if((t&4194048)!==t)break;case 6:Tu(r,t,tu,!ql);break a;case 2:iu=null;break;case 3:case 5:break;default:throw Error(i(329))}if((t&62914560)===t&&(a=ou+300-Ae(),10<a)){if(Tu(r,t,tu,!ql),Ye(r,0,!0)!==0)break a;pu=t,r.timeoutHandle=Qd(Cu.bind(null,r,n,iu,cu,au,t,tu,$l,nu,ql,o,`Throttled`,-0,0),a);break a}Cu(r,n,iu,cu,au,t,tu,$l,nu,ql,o,null,-0,0)}}break}while(1);ld(e)}function Cu(e,t,n,r,i,a,o,s,c,l,u,d,f,p){if(e.timeoutHandle=-1,d=t.subtreeFlags,d&8192||(d&16785408)==16785408){d={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:nn},z(t,a,d);var m=(a&62914560)===a?ou-Ae():(a&4194048)===a?su-Ae():0;if(m=Zf(d,m),m!==null){pu=a,e.cancelPendingCommit=m(Uu.bind(null,e,t,a,n,r,i,o,s,c,u,d,null,f,p)),Tu(e,a,o,!l);return}}Uu(e,t,a,n,r,i,o,s,c)}function wu(e){for(var t=e;;){var n=t.tag;if((n===0||n===11||n===15)&&t.flags&16384&&(n=t.updateQueue,n!==null&&(n=n.stores,n!==null)))for(var r=0;r<n.length;r++){var i=n[r],a=i.getSnapshot;i=i.value;try{if(!Tr(a(),i))return!1}catch{return!1}}if(n=t.child,t.subtreeFlags&16384&&n!==null)n.return=t,t=n;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function Tu(e,t,n,r){t&=~eu,t&=~$l,e.suspendedLanes|=t,e.pingedLanes&=~t,r&&(e.warmLanes|=t),r=e.expirationTimes;for(var i=t;0<i;){var a=31-Ve(i),o=1<<a;r[a]=-1,i&=~o}n!==0&&tt(e,n,t)}function Eu(){return B&6?!0:(ud(0,!1),!1)}function Du(){if(V!==null){if(U===0)var e=V.return;else e=V,Xi=Yi=null,Po(e),Fa=null,Ia=0,e=V;for(;e!==null;)Kc(e.alternate,e),e=e.return;V=null}}function Ou(e,t){var n=e.timeoutHandle;n!==-1&&(e.timeoutHandle=-1,$d(n)),n=e.cancelPendingCommit,n!==null&&(e.cancelPendingCommit=null,n()),pu=0,Du(),Gl=e,V=n=pi(e.current,null),H=t,U=0,Kl=null,ql=!1,Jl=Xe(e,t),Yl=!1,nu=tu=eu=$l=Ql=Zl=0,iu=ru=null,au=!1,t&8&&(t|=t&32);var r=e.entangledLanes;if(r!==0)for(e=e.entanglements,r&=t;0<r;){var i=31-Ve(r),a=1<<i;t|=e[i],r&=~a}return Xl=t,ri(),n}function ku(e,t){L=null,A.H=Ws,t===Ta||t===Da?(t=Na(),U=3):t===Ea?(t=Na(),U=4):U=t===cc?8:typeof t==`object`&&t&&typeof t.then==`function`?6:1,Kl=t,V===null&&(Zl=1,nc(e,xi(t,e.current)))}function Au(){var e=oo.current;return e===null?!0:(H&4194048)===H?so===null:(H&62914560)===H||H&536870912?e===so:!1}function ju(){var e=A.H;return A.H=Ws,e===null?Ws:e}function Mu(){var e=A.A;return A.A=Ul,e}function Nu(){Zl=4,ql||(H&4194048)!==H&&oo.current!==null||(Jl=!0),!(Ql&134217727)&&!($l&134217727)||Gl===null||Tu(Gl,H,tu,!1)}function Pu(e,t,n){var r=B;B|=2;var i=ju(),a=Mu();(Gl!==e||H!==t)&&(cu=null,Ou(e,t)),t=!1;var o=Zl;a:do try{if(U!==0&&V!==null){var s=V,c=Kl;switch(U){case 8:Du(),o=6;break a;case 3:case 2:case 9:case 6:oo.current===null&&(t=!0);var l=U;if(U=0,Kl=null,Bu(e,s,c,l),n&&Jl){o=0;break a}break;default:l=U,U=0,Kl=null,Bu(e,s,c,l)}}Fu(),o=Zl;break}catch(t){ku(e,t)}while(1);return t&&e.shellSuspendCounter++,Xi=Yi=null,B=r,A.H=i,A.A=a,V===null&&(Gl=null,H=0,ri()),o}function Fu(){for(;V!==null;)Ru(V)}function Iu(e,t){var n=B;B|=2;var r=ju(),a=Mu();Gl!==e||H!==t?(cu=null,W=Ae()+500,Ou(e,t)):Jl=Xe(e,t);a:do try{if(U!==0&&V!==null){t=V;var o=Kl;b:switch(U){case 1:U=0,Kl=null,Bu(e,t,o,1);break;case 2:case 9:if(ka(o)){U=0,Kl=null,zu(t);break}t=function(){U!==2&&U!==9||Gl!==e||(U=7),ld(e)},o.then(t,t);break a;case 3:U=7;break a;case 4:U=5;break a;case 7:ka(o)?(U=0,Kl=null,zu(t)):(U=0,Kl=null,Bu(e,t,o,7));break;case 5:var s=null;switch(V.tag){case 26:s=V.memoizedState;case 5:case 27:var c=V;if(s?Jf(s):c.stateNode.complete){U=0,Kl=null;var l=c.sibling;if(l!==null)V=l;else{var u=c.return;u===null?V=null:(V=u,Vu(u))}break b}}U=0,Kl=null,Bu(e,t,o,5);break;case 6:U=0,Kl=null,Bu(e,t,o,6);break;case 8:Du(),Zl=6;break a;default:throw Error(i(462))}}Lu();break}catch(t){ku(e,t)}while(1);return Xi=Yi=null,A.H=r,A.A=a,B=n,V===null?(Gl=null,H=0,ri(),Zl):0}function Lu(){for(;V!==null&&!Oe();)Ru(V)}function Ru(e){var t=Rc(e.alternate,e,Xl);e.memoizedProps=e.pendingProps,t===null?Vu(e):V=t}function zu(e){var t=e,n=t.alternate;switch(t.tag){case 15:case 0:t=Sc(n,t,t.pendingProps,t.type,void 0,H);break;case 11:t=Sc(n,t,t.pendingProps,t.type.render,t.ref,H);break;case 5:Po(t);default:Kc(n,t),t=V=mi(t,Xl),t=Rc(n,t,Xl)}e.memoizedProps=e.pendingProps,t===null?Vu(e):V=t}function Bu(e,t,n,r){Xi=Yi=null,Po(t),Fa=null,Ia=0;var i=t.return;try{if(sc(e,i,t,n,H)){Zl=1,nc(e,xi(n,e.current)),V=null;return}}catch(t){if(i!==null)throw V=i,t;Zl=1,nc(e,xi(n,e.current)),V=null;return}t.flags&32768?(I||r===1?e=!0:Jl||H&536870912?e=!1:(ql=e=!0,(r===2||r===9||r===3||r===6)&&(r=oo.current,r!==null&&r.tag===13&&(r.flags|=16384))),Hu(t,e)):Vu(t)}function Vu(e){var t=e;do{if(t.flags&32768){Hu(t,ql);return}e=t.return;var n=Wc(t.alternate,t,Xl);if(n!==null){V=n;return}if(t=t.sibling,t!==null){V=t;return}V=t=e}while(t!==null);Zl===0&&(Zl=5)}function Hu(e,t){do{var n=Gc(e.alternate,e);if(n!==null){n.flags&=32767,V=n;return}if(n=e.return,n!==null&&(n.flags|=32768,n.subtreeFlags=0,n.deletions=null),!t&&(e=e.sibling,e!==null)){V=e;return}V=e=n}while(e!==null);Zl=6,V=null}function Uu(e,t,n,r,a,o,s,c,l){e.cancelPendingCommit=null;do Ju();while(uu!==0);if(B&6)throw Error(i(327));if(t!==null){if(t===e.current)throw Error(i(177));if(o=t.lanes|t.childLanes,o|=ni,et(e,n,o,s,c,l),e===Gl&&(V=Gl=null,H=0),fu=t,du=e,pu=n,mu=o,hu=a,gu=r,t.subtreeFlags&10256||t.flags&10256?(e.callbackNode=null,e.callbackPriority=0,nd(Pe,function(){return Yu(),null})):(e.callbackNode=null,e.callbackPriority=0),r=(t.flags&13878)!=0,t.subtreeFlags&13878||r){r=A.T,A.T=null,a=j.p,j.p=2,s=B,B|=4;try{dl(e,t,n)}finally{B=s,j.p=a,A.T=r}}uu=1,Wu(),Gu(),Ku()}}function Wu(){if(uu===1){uu=0;var e=du,t=fu,n=(t.flags&13878)!=0;if(t.subtreeFlags&13878||n){n=A.T,A.T=null;var r=j.p;j.p=2;var i=B;B|=4;try{wl(t,e);var a=Gd,o=Ar(e.containerInfo),s=a.focusedElem,c=a.selectionRange;if(o!==s&&s&&s.ownerDocument&&kr(s.ownerDocument.documentElement,s)){if(c!==null&&jr(s)){var l=c.start,u=c.end;if(u===void 0&&(u=l),`selectionStart`in s)s.selectionStart=l,s.selectionEnd=Math.min(u,s.value.length);else{var d=s.ownerDocument||document,f=d&&d.defaultView||window;if(f.getSelection){var p=f.getSelection(),m=s.textContent.length,h=Math.min(c.start,m),g=c.end===void 0?h:Math.min(c.end,m);!p.extend&&h>g&&(o=g,g=h,h=o);var _=Or(s,h),v=Or(s,g);if(_&&v&&(p.rangeCount!==1||p.anchorNode!==_.node||p.anchorOffset!==_.offset||p.focusNode!==v.node||p.focusOffset!==v.offset)){var y=d.createRange();y.setStart(_.node,_.offset),p.removeAllRanges(),h>g?(p.addRange(y),p.extend(v.node,v.offset)):(y.setEnd(v.node,v.offset),p.addRange(y))}}}}for(d=[],p=s;p=p.parentNode;)p.nodeType===1&&d.push({element:p,left:p.scrollLeft,top:p.scrollTop});for(typeof s.focus==`function`&&s.focus(),s=0;s<d.length;s++){var b=d[s];b.element.scrollLeft=b.left,b.element.scrollTop=b.top}}dp=!!Wd,Gd=Wd=null}finally{B=i,j.p=r,A.T=n}}e.current=t,uu=2}}function Gu(){if(uu===2){uu=0;var e=du,t=fu,n=(t.flags&8772)!=0;if(t.subtreeFlags&8772||n){n=A.T,A.T=null;var r=j.p;j.p=2;var i=B;B|=4;try{fl(e,t.alternate,t)}finally{B=i,j.p=r,A.T=n}}uu=3}}function Ku(){if(uu===4||uu===3){uu=0,ke();var e=du,t=fu,n=pu,r=gu;t.subtreeFlags&10256||t.flags&10256?uu=5:(uu=0,fu=du=null,qu(e,e.pendingLanes));var i=e.pendingLanes;if(i===0&&(lu=null),at(n),t=t.stateNode,P&&typeof P.onCommitFiberRoot==`function`)try{P.onCommitFiberRoot(ze,t,void 0,(t.current.flags&128)==128)}catch{}if(r!==null){t=A.T,i=j.p,j.p=2,A.T=null;try{for(var a=e.onRecoverableError,o=0;o<r.length;o++){var s=r[o];a(s.value,{componentStack:s.stack})}}finally{A.T=t,j.p=i}}pu&3&&Ju(),ld(e),i=e.pendingLanes,n&261930&&i&42?e===vu?_u++:(_u=0,vu=e):_u=0,ud(0,!1)}}function qu(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,fa(t)))}function Ju(){return Wu(),Gu(),Ku(),Yu()}function Yu(){if(uu!==5)return!1;var e=du,t=mu;mu=0;var n=at(pu),r=A.T,a=j.p;try{j.p=32>n?32:n,A.T=null,n=hu,hu=null;var o=du,s=pu;if(uu=0,fu=du=null,pu=0,B&6)throw Error(i(331));var c=B;if(B|=4,Bl(o.current),Nl(o,o.current,s,n),B=c,ud(0,!1),P&&typeof P.onPostCommitFiberRoot==`function`)try{P.onPostCommitFiberRoot(ze,o)}catch{}return!0}finally{j.p=a,A.T=r,qu(e,t)}}function Xu(e,t,n){t=xi(n,t),t=ic(e.stateNode,t,2),e=qa(e,t,2),e!==null&&($e(e,2),ld(e))}function G(e,t,n){if(e.tag===3)Xu(e,e,n);else for(;t!==null;){if(t.tag===3){Xu(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError==`function`||typeof r.componentDidCatch==`function`&&(lu===null||!lu.has(r))){e=xi(n,e),n=ac(2),r=qa(t,n,2),r!==null&&(oc(n,r,t,e),$e(r,2),ld(r));break}}t=t.return}}function Zu(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new Wl;var i=new Set;r.set(t,i)}else i=r.get(t),i===void 0&&(i=new Set,r.set(t,i));i.has(n)||(Yl=!0,i.add(n),e=Qu.bind(null,e,t,n),t.then(e,e))}function Qu(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),e.pingedLanes|=e.suspendedLanes&n,e.warmLanes&=~n,Gl===e&&(H&n)===n&&(Zl===4||Zl===3&&(H&62914560)===H&&300>Ae()-ou?!(B&2)&&Ou(e,0):eu|=n,nu===H&&(nu=0)),ld(e)}function $u(e,t){t===0&&(t=Ze()),e=oi(e,t),e!==null&&($e(e,t),ld(e))}function ed(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),$u(e,n)}function td(e,t){var n=0;switch(e.tag){case 31:case 13:var r=e.stateNode,a=e.memoizedState;a!==null&&(n=a.retryLane);break;case 19:r=e.stateNode;break;case 22:r=e.stateNode._retryCache;break;default:throw Error(i(314))}r!==null&&r.delete(t),$u(e,n)}function nd(e,t){return Ee(e,t)}var rd=null,id=null,ad=!1,od=!1,sd=!1,cd=0;function ld(e){e!==id&&e.next===null&&(id===null?rd=id=e:id=id.next=e),od=!0,ad||(ad=!0,gd())}function ud(e,t){if(!sd&&od){sd=!0;do for(var n=!1,r=rd;r!==null;){if(!t)if(e!==0){var i=r.pendingLanes;if(i===0)var a=0;else{var o=r.suspendedLanes,s=r.pingedLanes;a=(1<<31-Ve(42|e)+1)-1,a&=i&~(o&~s),a=a&201326741?a&201326741|1:a?a|2:0}a!==0&&(n=!0,hd(r,a))}else a=H,a=Ye(r,r===Gl?a:0,r.cancelPendingCommit!==null||r.timeoutHandle!==-1),!(a&3)||Xe(r,a)||(n=!0,hd(r,a));r=r.next}while(n);sd=!1}}function dd(){fd()}function fd(){od=ad=!1;var e=0;cd!==0&&Zd()&&(e=cd);for(var t=Ae(),n=null,r=rd;r!==null;){var i=r.next,a=pd(r,t);a===0?(r.next=null,n===null?rd=i:n.next=i,i===null&&(id=n)):(n=r,(e!==0||a&3)&&(od=!0)),r=i}uu!==0&&uu!==5||ud(e,!1),cd!==0&&(cd=0)}function pd(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,i=e.expirationTimes,a=e.pendingLanes&-62914561;0<a;){var o=31-Ve(a),s=1<<o,c=i[o];c===-1?((s&n)===0||(s&r)!==0)&&(i[o]=F(s,t)):c<=t&&(e.expiredLanes|=s),a&=~s}if(t=Gl,n=H,n=Ye(e,e===t?n:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r=e.callbackNode,n===0||e===t&&(U===2||U===9)||e.cancelPendingCommit!==null)return r!==null&&r!==null&&De(r),e.callbackNode=null,e.callbackPriority=0;if(!(n&3)||Xe(e,n)){if(t=n&-n,t===e.callbackPriority)return t;switch(r!==null&&De(r),at(n)){case 2:case 8:n=Ne;break;case 32:n=Pe;break;case 268435456:n=Ie;break;default:n=Pe}return r=md.bind(null,e),n=Ee(n,r),e.callbackPriority=t,e.callbackNode=n,t}return r!==null&&r!==null&&De(r),e.callbackPriority=2,e.callbackNode=null,2}function md(e,t){if(uu!==0&&uu!==5)return e.callbackNode=null,e.callbackPriority=0,null;var n=e.callbackNode;if(Ju()&&e.callbackNode!==n)return null;var r=H;return r=Ye(e,e===Gl?r:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r===0?null:(Su(e,r,t),pd(e,Ae()),e.callbackNode!=null&&e.callbackNode===n?md.bind(null,e):null)}function hd(e,t){if(Ju())return null;Su(e,t,!0)}function gd(){tf(function(){B&6?Ee(Me,dd):fd()})}function _d(){if(cd===0){var e=ha;e===0&&(e=Ge,Ge<<=1,!(Ge&261888)&&(Ge=256)),cd=e}return cd}function vd(e){return e==null||typeof e==`symbol`||typeof e==`boolean`?null:typeof e==`function`?e:tn(``+e)}function yd(e,t){var n=t.ownerDocument.createElement(`input`);return n.name=t.name,n.value=t.value,e.id&&n.setAttribute(`form`,e.id),t.parentNode.insertBefore(n,t),e=new FormData(e),n.parentNode.removeChild(n),e}function bd(e,t,n,r,i){if(t===`submit`&&n&&n.stateNode===i){var a=vd((i[ut]||null).action),o=r.submitter;o&&(t=(t=o[ut]||null)?vd(t.formAction):o.getAttribute(`formAction`),t!==null&&(a=t,o=null));var s=new wn(`action`,`action`,null,r,i);e.push({event:s,listeners:[{instance:null,listener:function(){if(r.defaultPrevented){if(cd!==0){var e=o?yd(i,o):new FormData(i);As(n,{pending:!0,data:e,method:i.method,action:a},null,e)}}else typeof a==`function`&&(s.preventDefault(),e=o?yd(i,o):new FormData(i),As(n,{pending:!0,data:e,method:i.method,action:a},a,e))},currentTarget:i}]})}}for(var xd=0;xd<Zr.length;xd++){var Sd=Zr[xd];Qr(Sd.toLowerCase(),`on`+(Sd[0].toUpperCase()+Sd.slice(1)))}Qr(Ur,`onAnimationEnd`),Qr(Wr,`onAnimationIteration`),Qr(Gr,`onAnimationStart`),Qr(`dblclick`,`onDoubleClick`),Qr(`focusin`,`onFocus`),Qr(`focusout`,`onBlur`),Qr(Kr,`onTransitionRun`),Qr(qr,`onTransitionStart`),Qr(Jr,`onTransitionCancel`),Qr(Yr,`onTransitionEnd`),Et(`onMouseEnter`,[`mouseout`,`mouseover`]),Et(`onMouseLeave`,[`mouseout`,`mouseover`]),Et(`onPointerEnter`,[`pointerout`,`pointerover`]),Et(`onPointerLeave`,[`pointerout`,`pointerover`]),Tt(`onChange`,`change click focusin focusout input keydown keyup selectionchange`.split(` `)),Tt(`onSelect`,`focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange`.split(` `)),Tt(`onBeforeInput`,[`compositionend`,`keypress`,`textInput`,`paste`]),Tt(`onCompositionEnd`,`compositionend focusout keydown keypress keyup mousedown`.split(` `)),Tt(`onCompositionStart`,`compositionstart focusout keydown keypress keyup mousedown`.split(` `)),Tt(`onCompositionUpdate`,`compositionupdate focusout keydown keypress keyup mousedown`.split(` `));var Cd=`abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting`.split(` `),wd=new Set(`beforetoggle cancel close invalid load scroll scrollend toggle`.split(` `).concat(Cd));function Td(e,t){t=(t&4)!=0;for(var n=0;n<e.length;n++){var r=e[n],i=r.event;r=r.listeners;a:{var a=void 0;if(t)for(var o=r.length-1;0<=o;o--){var s=r[o],c=s.instance,l=s.currentTarget;if(s=s.listener,c!==a&&i.isPropagationStopped())break a;a=s,i.currentTarget=l;try{a(i)}catch(e){$r(e)}i.currentTarget=null,a=c}else for(o=0;o<r.length;o++){if(s=r[o],c=s.instance,l=s.currentTarget,s=s.listener,c!==a&&i.isPropagationStopped())break a;a=s,i.currentTarget=l;try{a(i)}catch(e){$r(e)}i.currentTarget=null,a=c}}}}function K(e,t){var n=t[ft];n===void 0&&(n=t[ft]=new Set);var r=e+`__bubble`;n.has(r)||(q(t,e,2,!1),n.add(r))}function Ed(e,t,n){var r=0;t&&(r|=4),q(n,e,r,t)}var Dd=`_reactListening`+Math.random().toString(36).slice(2);function Od(e){if(!e[Dd]){e[Dd]=!0,Ct.forEach(function(t){t!==`selectionchange`&&(wd.has(t)||Ed(t,!1,e),Ed(t,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Dd]||(t[Dd]=!0,Ed(`selectionchange`,!1,t))}}function q(e,t,n,r){switch(vp(t)){case 2:var i=fp;break;case 8:i=pp;break;default:i=mp}n=i.bind(null,t,n,e),i=void 0,!pn||t!==`touchstart`&&t!==`touchmove`&&t!==`wheel`||(i=!0),r?i===void 0?e.addEventListener(t,n,!0):e.addEventListener(t,n,{capture:!0,passive:i}):i===void 0?e.addEventListener(t,n,!1):e.addEventListener(t,n,{passive:i})}function kd(e,t,n,r,i){var a=r;if(!(t&1)&&!(t&2)&&r!==null)a:for(;;){if(r===null)return;var o=r.tag;if(o===3||o===4){var s=r.stateNode.containerInfo;if(s===i)break;if(o===4)for(o=r.return;o!==null;){var l=o.tag;if((l===3||l===4)&&o.stateNode.containerInfo===i)return;o=o.return}for(;s!==null;){if(o=vt(s),o===null)return;if(l=o.tag,l===5||l===6||l===26||l===27){r=a=o;continue a}s=s.parentNode}}r=r.return}un(function(){var r=a,i=an(n),o=[];a:{var s=Xr.get(e);if(s!==void 0){var l=wn,u=e;switch(e){case`keypress`:if(yn(n)===0)break a;case`keydown`:case`keyup`:l=Hn;break;case`focusin`:u=`focus`,l=Nn;break;case`focusout`:u=`blur`,l=Nn;break;case`beforeblur`:case`afterblur`:l=Nn;break;case`click`:if(n.button===2)break a;case`auxclick`:case`dblclick`:case`mousedown`:case`mousemove`:case`mouseup`:case`mouseout`:case`mouseover`:case`contextmenu`:l=jn;break;case`drag`:case`dragend`:case`dragenter`:case`dragexit`:case`dragleave`:case`dragover`:case`dragstart`:case`drop`:l=Mn;break;case`touchcancel`:case`touchend`:case`touchmove`:case`touchstart`:l=Wn;break;case Ur:case Wr:case Gr:l=Pn;break;case Yr:l=Gn;break;case`scroll`:case`scrollend`:l=En;break;case`wheel`:l=Kn;break;case`copy`:case`cut`:case`paste`:l=Fn;break;case`gotpointercapture`:case`lostpointercapture`:case`pointercancel`:case`pointerdown`:case`pointermove`:case`pointerout`:case`pointerover`:case`pointerup`:l=Un;break;case`toggle`:case`beforetoggle`:l=qn}var d=(t&4)!=0,f=!d&&(e===`scroll`||e===`scrollend`),p=d?s===null?null:s+`Capture`:s;d=[];for(var m=r,h;m!==null;){var g=m;if(h=g.stateNode,g=g.tag,g!==5&&g!==26&&g!==27||h===null||p===null||(g=dn(m,p),g!=null&&d.push(Ad(m,g,h))),f)break;m=m.return}0<d.length&&(s=new l(s,u,null,n,i),o.push({event:s,listeners:d}))}}if(!(t&7)){a:{if(s=e===`mouseover`||e===`pointerover`,l=e===`mouseout`||e===`pointerout`,s&&n!==rn&&(u=n.relatedTarget||n.fromElement)&&(vt(u)||u[dt]))break a;if((l||s)&&(s=i.window===i?i:(s=i.ownerDocument)?s.defaultView||s.parentWindow:window,l?(u=n.relatedTarget||n.toElement,l=r,u=u?vt(u):null,u!==null&&(f=c(u),d=u.tag,u!==f||d!==5&&d!==27&&d!==6)&&(u=null)):(l=null,u=r),l!==u)){if(d=jn,g=`onMouseLeave`,p=`onMouseEnter`,m=`mouse`,(e===`pointerout`||e===`pointerover`)&&(d=Un,g=`onPointerLeave`,p=`onPointerEnter`,m=`pointer`),f=l==null?s:bt(l),h=u==null?s:bt(u),s=new d(g,m+`leave`,l,n,i),s.target=f,s.relatedTarget=h,g=null,vt(i)===r&&(d=new d(p,m+`enter`,u,n,i),d.target=h,d.relatedTarget=f,g=d),f=g,l&&u)b:{for(d=Md,p=l,m=u,h=0,g=p;g;g=d(g))h++;g=0;for(var _=m;_;_=d(_))g++;for(;0<h-g;)p=d(p),h--;for(;0<g-h;)m=d(m),g--;for(;h--;){if(p===m||m!==null&&p===m.alternate){d=p;break b}p=d(p),m=d(m)}d=null}else d=null;l!==null&&Nd(o,s,l,d,!1),u!==null&&f!==null&&Nd(o,f,u,d,!0)}}a:{if(s=r?bt(r):window,l=s.nodeName&&s.nodeName.toLowerCase(),l===`select`||l===`input`&&s.type===`file`)var v=pr;else if(sr(s))if(mr)v=Cr;else{v=xr;var y=br}else l=s.nodeName,!l||l.toLowerCase()!==`input`||s.type!==`checkbox`&&s.type!==`radio`?r&&Qt(r.elementType)&&(v=pr):v=Sr;if(v&&=v(e,r)){cr(o,v,n,i);break a}y&&y(e,s,r),e===`focusout`&&r&&s.type===`number`&&r.memoizedProps.value!=null&&Wt(s,`number`,s.value)}switch(y=r?bt(r):window,e){case`focusin`:(sr(y)||y.contentEditable===`true`)&&(Nr=y,Pr=r,Fr=null);break;case`focusout`:Fr=Pr=Nr=null;break;case`mousedown`:Ir=!0;break;case`contextmenu`:case`mouseup`:case`dragend`:Ir=!1,Lr(o,n,i);break;case`selectionchange`:if(Mr)break;case`keydown`:case`keyup`:Lr(o,n,i)}var b;if(Yn)b:{switch(e){case`compositionstart`:var x=`onCompositionStart`;break b;case`compositionend`:x=`onCompositionEnd`;break b;case`compositionupdate`:x=`onCompositionUpdate`;break b}x=void 0}else rr?tr(e,n)&&(x=`onCompositionEnd`):e===`keydown`&&n.keyCode===229&&(x=`onCompositionStart`);x&&(Qn&&n.locale!==`ko`&&(rr||x!==`onCompositionStart`?x===`onCompositionEnd`&&rr&&(b=vn()):(hn=i,gn=`value`in hn?hn.value:hn.textContent,rr=!0)),y=jd(r,x),0<y.length&&(x=new In(x,e,null,n,i),o.push({event:x,listeners:y}),b?x.data=b:(b=nr(n),b!==null&&(x.data=b)))),(b=Zn?ir(e,n):ar(e,n))&&(x=jd(r,`onBeforeInput`),0<x.length&&(y=new In(`onBeforeInput`,`beforeinput`,null,n,i),o.push({event:y,listeners:x}),y.data=b)),bd(o,e,r,n,i)}Td(o,t)})}function Ad(e,t,n){return{instance:e,listener:t,currentTarget:n}}function jd(e,t){for(var n=t+`Capture`,r=[];e!==null;){var i=e,a=i.stateNode;if(i=i.tag,i!==5&&i!==26&&i!==27||a===null||(i=dn(e,n),i!=null&&r.unshift(Ad(e,i,a)),i=dn(e,t),i!=null&&r.push(Ad(e,i,a))),e.tag===3)return r;e=e.return}return[]}function Md(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function Nd(e,t,n,r,i){for(var a=t._reactName,o=[];n!==null&&n!==r;){var s=n,c=s.alternate,l=s.stateNode;if(s=s.tag,c!==null&&c===r)break;s!==5&&s!==26&&s!==27||l===null||(c=l,i?(l=dn(n,a),l!=null&&o.unshift(Ad(n,l,c))):i||(l=dn(n,a),l!=null&&o.push(Ad(n,l,c)))),n=n.return}o.length!==0&&e.push({event:t,listeners:o})}var Pd=/\r\n?/g,Fd=/\u0000|\uFFFD/g;function Id(e){return(typeof e==`string`?e:``+e).replace(Pd,`
`).replace(Fd,``)}function Ld(e,t){return t=Id(t),Id(e)===t}function Rd(e,t,n,r,a,o){switch(n){case`children`:typeof r==`string`?t===`body`||t===`textarea`&&r===``||Jt(e,r):(typeof r==`number`||typeof r==`bigint`)&&t!==`body`&&Jt(e,``+r);break;case`className`:Mt(e,`class`,r);break;case`tabIndex`:Mt(e,`tabindex`,r);break;case`dir`:case`role`:case`viewBox`:case`width`:case`height`:Mt(e,n,r);break;case`style`:Zt(e,r,o);break;case`data`:if(t!==`object`){Mt(e,`data`,r);break}case`src`:case`href`:if(r===``&&(t!==`a`||n!==`href`)){e.removeAttribute(n);break}if(r==null||typeof r==`function`||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=tn(``+r),e.setAttribute(n,r);break;case`action`:case`formAction`:if(typeof r==`function`){e.setAttribute(n,`javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')`);break}else typeof o==`function`&&(n===`formAction`?(t!==`input`&&Rd(e,t,`name`,a.name,a,null),Rd(e,t,`formEncType`,a.formEncType,a,null),Rd(e,t,`formMethod`,a.formMethod,a,null),Rd(e,t,`formTarget`,a.formTarget,a,null)):(Rd(e,t,`encType`,a.encType,a,null),Rd(e,t,`method`,a.method,a,null),Rd(e,t,`target`,a.target,a,null)));if(r==null||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=tn(``+r),e.setAttribute(n,r);break;case`onClick`:r!=null&&(e.onclick=nn);break;case`onScroll`:r!=null&&K(`scroll`,e);break;case`onScrollEnd`:r!=null&&K(`scrollend`,e);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(i(61));if(n=r.__html,n!=null){if(a.children!=null)throw Error(i(60));e.innerHTML=n}}break;case`multiple`:e.multiple=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`muted`:e.muted=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`defaultValue`:case`defaultChecked`:case`innerHTML`:case`ref`:break;case`autoFocus`:break;case`xlinkHref`:if(r==null||typeof r==`function`||typeof r==`boolean`||typeof r==`symbol`){e.removeAttribute(`xlink:href`);break}n=tn(``+r),e.setAttributeNS(`http://www.w3.org/1999/xlink`,`xlink:href`,n);break;case`contentEditable`:case`spellCheck`:case`draggable`:case`value`:case`autoReverse`:case`externalResourcesRequired`:case`focusable`:case`preserveAlpha`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``+r):e.removeAttribute(n);break;case`inert`:case`allowFullScreen`:case`async`:case`autoPlay`:case`controls`:case`default`:case`defer`:case`disabled`:case`disablePictureInPicture`:case`disableRemotePlayback`:case`formNoValidate`:case`hidden`:case`loop`:case`noModule`:case`noValidate`:case`open`:case`playsInline`:case`readOnly`:case`required`:case`reversed`:case`scoped`:case`seamless`:case`itemScope`:r&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``):e.removeAttribute(n);break;case`capture`:case`download`:!0===r?e.setAttribute(n,``):!1!==r&&r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,r):e.removeAttribute(n);break;case`cols`:case`rows`:case`size`:case`span`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`&&!isNaN(r)&&1<=r?e.setAttribute(n,r):e.removeAttribute(n);break;case`rowSpan`:case`start`:r==null||typeof r==`function`||typeof r==`symbol`||isNaN(r)?e.removeAttribute(n):e.setAttribute(n,r);break;case`popover`:K(`beforetoggle`,e),K(`toggle`,e),jt(e,`popover`,r);break;case`xlinkActuate`:Nt(e,`http://www.w3.org/1999/xlink`,`xlink:actuate`,r);break;case`xlinkArcrole`:Nt(e,`http://www.w3.org/1999/xlink`,`xlink:arcrole`,r);break;case`xlinkRole`:Nt(e,`http://www.w3.org/1999/xlink`,`xlink:role`,r);break;case`xlinkShow`:Nt(e,`http://www.w3.org/1999/xlink`,`xlink:show`,r);break;case`xlinkTitle`:Nt(e,`http://www.w3.org/1999/xlink`,`xlink:title`,r);break;case`xlinkType`:Nt(e,`http://www.w3.org/1999/xlink`,`xlink:type`,r);break;case`xmlBase`:Nt(e,`http://www.w3.org/XML/1998/namespace`,`xml:base`,r);break;case`xmlLang`:Nt(e,`http://www.w3.org/XML/1998/namespace`,`xml:lang`,r);break;case`xmlSpace`:Nt(e,`http://www.w3.org/XML/1998/namespace`,`xml:space`,r);break;case`is`:jt(e,`is`,r);break;case`innerText`:case`textContent`:break;default:(!(2<n.length)||n[0]!==`o`&&n[0]!==`O`||n[1]!==`n`&&n[1]!==`N`)&&(n=$t.get(n)||n,jt(e,n,r))}}function zd(e,t,n,r,a,o){switch(n){case`style`:Zt(e,r,o);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(i(61));if(n=r.__html,n!=null){if(a.children!=null)throw Error(i(60));e.innerHTML=n}}break;case`children`:typeof r==`string`?Jt(e,r):(typeof r==`number`||typeof r==`bigint`)&&Jt(e,``+r);break;case`onScroll`:r!=null&&K(`scroll`,e);break;case`onScrollEnd`:r!=null&&K(`scrollend`,e);break;case`onClick`:r!=null&&(e.onclick=nn);break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`innerHTML`:case`ref`:break;case`innerText`:case`textContent`:break;default:if(!wt.hasOwnProperty(n))a:{if(n[0]===`o`&&n[1]===`n`&&(a=n.endsWith(`Capture`),t=n.slice(2,a?n.length-7:void 0),o=e[ut]||null,o=o==null?null:o[n],typeof o==`function`&&e.removeEventListener(t,o,a),typeof r==`function`)){typeof o!=`function`&&o!==null&&(n in e?e[n]=null:e.hasAttribute(n)&&e.removeAttribute(n)),e.addEventListener(t,r,a);break a}n in e?e[n]=r:!0===r?e.setAttribute(n,``):jt(e,n,r)}}}function Bd(e,t,n){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`img`:K(`error`,e),K(`load`,e);var r=!1,a=!1,o;for(o in n)if(n.hasOwnProperty(o)){var s=n[o];if(s!=null)switch(o){case`src`:r=!0;break;case`srcSet`:a=!0;break;case`children`:case`dangerouslySetInnerHTML`:throw Error(i(137,t));default:Rd(e,t,o,s,n,null)}}a&&Rd(e,t,`srcSet`,n.srcSet,n,null),r&&Rd(e,t,`src`,n.src,n,null);return;case`input`:K(`invalid`,e);var c=o=s=a=null,l=null,u=null;for(r in n)if(n.hasOwnProperty(r)){var d=n[r];if(d!=null)switch(r){case`name`:a=d;break;case`type`:s=d;break;case`checked`:l=d;break;case`defaultChecked`:u=d;break;case`value`:o=d;break;case`defaultValue`:c=d;break;case`children`:case`dangerouslySetInnerHTML`:if(d!=null)throw Error(i(137,t));break;default:Rd(e,t,r,d,n,null)}}Ut(e,o,c,l,u,s,a,!1);return;case`select`:for(a in K(`invalid`,e),r=s=o=null,n)if(n.hasOwnProperty(a)&&(c=n[a],c!=null))switch(a){case`value`:o=c;break;case`defaultValue`:s=c;break;case`multiple`:r=c;default:Rd(e,t,a,c,n,null)}t=o,n=s,e.multiple=!!r,t==null?n!=null&&Gt(e,!!r,n,!0):Gt(e,!!r,t,!1);return;case`textarea`:for(s in K(`invalid`,e),o=a=r=null,n)if(n.hasOwnProperty(s)&&(c=n[s],c!=null))switch(s){case`value`:r=c;break;case`defaultValue`:a=c;break;case`children`:o=c;break;case`dangerouslySetInnerHTML`:if(c!=null)throw Error(i(91));break;default:Rd(e,t,s,c,n,null)}qt(e,r,a,o);return;case`option`:for(l in n)if(n.hasOwnProperty(l)&&(r=n[l],r!=null))switch(l){case`selected`:e.selected=r&&typeof r!=`function`&&typeof r!=`symbol`;break;default:Rd(e,t,l,r,n,null)}return;case`dialog`:K(`beforetoggle`,e),K(`toggle`,e),K(`cancel`,e),K(`close`,e);break;case`iframe`:case`object`:K(`load`,e);break;case`video`:case`audio`:for(r=0;r<Cd.length;r++)K(Cd[r],e);break;case`image`:K(`error`,e),K(`load`,e);break;case`details`:K(`toggle`,e);break;case`embed`:case`source`:case`link`:K(`error`,e),K(`load`,e);case`area`:case`base`:case`br`:case`col`:case`hr`:case`keygen`:case`meta`:case`param`:case`track`:case`wbr`:case`menuitem`:for(u in n)if(n.hasOwnProperty(u)&&(r=n[u],r!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:throw Error(i(137,t));default:Rd(e,t,u,r,n,null)}return;default:if(Qt(t)){for(d in n)n.hasOwnProperty(d)&&(r=n[d],r!==void 0&&zd(e,t,d,r,n,void 0));return}}for(c in n)n.hasOwnProperty(c)&&(r=n[c],r!=null&&Rd(e,t,c,r,n,null))}function Vd(e,t,n,r){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`input`:var a=null,o=null,s=null,c=null,l=null,u=null,d=null;for(m in n){var f=n[m];if(n.hasOwnProperty(m)&&f!=null)switch(m){case`checked`:break;case`value`:break;case`defaultValue`:l=f;default:r.hasOwnProperty(m)||Rd(e,t,m,null,r,f)}}for(var p in r){var m=r[p];if(f=n[p],r.hasOwnProperty(p)&&(m!=null||f!=null))switch(p){case`type`:o=m;break;case`name`:a=m;break;case`checked`:u=m;break;case`defaultChecked`:d=m;break;case`value`:s=m;break;case`defaultValue`:c=m;break;case`children`:case`dangerouslySetInnerHTML`:if(m!=null)throw Error(i(137,t));break;default:m!==f&&Rd(e,t,p,m,r,f)}}Ht(e,s,c,l,u,d,o,a);return;case`select`:for(o in m=s=c=p=null,n)if(l=n[o],n.hasOwnProperty(o)&&l!=null)switch(o){case`value`:break;case`multiple`:m=l;default:r.hasOwnProperty(o)||Rd(e,t,o,null,r,l)}for(a in r)if(o=r[a],l=n[a],r.hasOwnProperty(a)&&(o!=null||l!=null))switch(a){case`value`:p=o;break;case`defaultValue`:c=o;break;case`multiple`:s=o;default:o!==l&&Rd(e,t,a,o,r,l)}t=c,n=s,r=m,p==null?!!r!=!!n&&(t==null?Gt(e,!!n,n?[]:``,!1):Gt(e,!!n,t,!0)):Gt(e,!!n,p,!1);return;case`textarea`:for(c in m=p=null,n)if(a=n[c],n.hasOwnProperty(c)&&a!=null&&!r.hasOwnProperty(c))switch(c){case`value`:break;case`children`:break;default:Rd(e,t,c,null,r,a)}for(s in r)if(a=r[s],o=n[s],r.hasOwnProperty(s)&&(a!=null||o!=null))switch(s){case`value`:p=a;break;case`defaultValue`:m=a;break;case`children`:break;case`dangerouslySetInnerHTML`:if(a!=null)throw Error(i(91));break;default:a!==o&&Rd(e,t,s,a,r,o)}Kt(e,p,m);return;case`option`:for(var h in n)if(p=n[h],n.hasOwnProperty(h)&&p!=null&&!r.hasOwnProperty(h))switch(h){case`selected`:e.selected=!1;break;default:Rd(e,t,h,null,r,p)}for(l in r)if(p=r[l],m=n[l],r.hasOwnProperty(l)&&p!==m&&(p!=null||m!=null))switch(l){case`selected`:e.selected=p&&typeof p!=`function`&&typeof p!=`symbol`;break;default:Rd(e,t,l,p,r,m)}return;case`img`:case`link`:case`area`:case`base`:case`br`:case`col`:case`embed`:case`hr`:case`keygen`:case`meta`:case`param`:case`source`:case`track`:case`wbr`:case`menuitem`:for(var g in n)p=n[g],n.hasOwnProperty(g)&&p!=null&&!r.hasOwnProperty(g)&&Rd(e,t,g,null,r,p);for(u in r)if(p=r[u],m=n[u],r.hasOwnProperty(u)&&p!==m&&(p!=null||m!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:if(p!=null)throw Error(i(137,t));break;default:Rd(e,t,u,p,r,m)}return;default:if(Qt(t)){for(var _ in n)p=n[_],n.hasOwnProperty(_)&&p!==void 0&&!r.hasOwnProperty(_)&&zd(e,t,_,void 0,r,p);for(d in r)p=r[d],m=n[d],!r.hasOwnProperty(d)||p===m||p===void 0&&m===void 0||zd(e,t,d,p,r,m);return}}for(var v in n)p=n[v],n.hasOwnProperty(v)&&p!=null&&!r.hasOwnProperty(v)&&Rd(e,t,v,null,r,p);for(f in r)p=r[f],m=n[f],!r.hasOwnProperty(f)||p===m||p==null&&m==null||Rd(e,t,f,p,r,m)}function Hd(e){switch(e){case`css`:case`script`:case`font`:case`img`:case`image`:case`input`:case`link`:return!0;default:return!1}}function Ud(){if(typeof performance.getEntriesByType==`function`){for(var e=0,t=0,n=performance.getEntriesByType(`resource`),r=0;r<n.length;r++){var i=n[r],a=i.transferSize,o=i.initiatorType,s=i.duration;if(a&&s&&Hd(o)){for(o=0,s=i.responseEnd,r+=1;r<n.length;r++){var c=n[r],l=c.startTime;if(l>s)break;var u=c.transferSize,d=c.initiatorType;u&&Hd(d)&&(c=c.responseEnd,o+=u*(c<s?1:(s-l)/(c-l)))}if(--r,t+=8*(a+o)/(i.duration/1e3),e++,10<e)break}}if(0<e)return t/e/1e6}return navigator.connection&&(e=navigator.connection.downlink,typeof e==`number`)?e:5}var Wd=null,Gd=null;function Kd(e){return e.nodeType===9?e:e.ownerDocument}function qd(e){switch(e){case`http://www.w3.org/2000/svg`:return 1;case`http://www.w3.org/1998/Math/MathML`:return 2;default:return 0}}function Jd(e,t){if(e===0)switch(t){case`svg`:return 1;case`math`:return 2;default:return 0}return e===1&&t===`foreignObject`?0:e}function Yd(e,t){return e===`textarea`||e===`noscript`||typeof t.children==`string`||typeof t.children==`number`||typeof t.children==`bigint`||typeof t.dangerouslySetInnerHTML==`object`&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var Xd=null;function Zd(){var e=window.event;return e&&e.type===`popstate`?e===Xd?!1:(Xd=e,!0):(Xd=null,!1)}var Qd=typeof setTimeout==`function`?setTimeout:void 0,$d=typeof clearTimeout==`function`?clearTimeout:void 0,ef=typeof Promise==`function`?Promise:void 0,tf=typeof queueMicrotask==`function`?queueMicrotask:ef===void 0?Qd:function(e){return ef.resolve(null).then(e).catch(nf)};function nf(e){setTimeout(function(){throw e})}function rf(e){return e===`head`}function af(e,t){var n=t,r=0;do{var i=n.nextSibling;if(e.removeChild(n),i&&i.nodeType===8)if(n=i.data,n===`/$`||n===`/&`){if(r===0){e.removeChild(i),Lp(t);return}r--}else if(n===`$`||n===`$?`||n===`$~`||n===`$!`||n===`&`)r++;else if(n===`html`)vf(e.ownerDocument.documentElement);else if(n===`head`){n=e.ownerDocument.head,vf(n);for(var a=n.firstChild;a;){var o=a.nextSibling,s=a.nodeName;a[gt]||s===`SCRIPT`||s===`STYLE`||s===`LINK`&&a.rel.toLowerCase()===`stylesheet`||n.removeChild(a),a=o}}else n===`body`&&vf(e.ownerDocument.body);n=i}while(n);Lp(t)}function of(e,t){var n=e;e=0;do{var r=n.nextSibling;if(n.nodeType===1?t?(n._stashedDisplay=n.style.display,n.style.display=`none`):(n.style.display=n._stashedDisplay||``,n.getAttribute(`style`)===``&&n.removeAttribute(`style`)):n.nodeType===3&&(t?(n._stashedText=n.nodeValue,n.nodeValue=``):n.nodeValue=n._stashedText||``),r&&r.nodeType===8)if(n=r.data,n===`/$`){if(e===0)break;e--}else n!==`$`&&n!==`$?`&&n!==`$~`&&n!==`$!`||e++;n=r}while(n)}function sf(e){var t=e.firstChild;for(t&&t.nodeType===10&&(t=t.nextSibling);t;){var n=t;switch(t=t.nextSibling,n.nodeName){case`HTML`:case`HEAD`:case`BODY`:sf(n),_t(n);continue;case`SCRIPT`:case`STYLE`:continue;case`LINK`:if(n.rel.toLowerCase()===`stylesheet`)continue}e.removeChild(n)}}function cf(e,t,n,r){for(;e.nodeType===1;){var i=n;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!r&&(e.nodeName!==`INPUT`||e.type!==`hidden`))break}else if(!r)if(t===`input`&&e.type===`hidden`){var a=i.name==null?null:``+i.name;if(i.type===`hidden`&&e.getAttribute(`name`)===a)return e}else return e;else if(!e[gt])switch(t){case`meta`:if(!e.hasAttribute(`itemprop`))break;return e;case`link`:if(a=e.getAttribute(`rel`),a===`stylesheet`&&e.hasAttribute(`data-precedence`)||a!==i.rel||e.getAttribute(`href`)!==(i.href==null||i.href===``?null:i.href)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin)||e.getAttribute(`title`)!==(i.title==null?null:i.title))break;return e;case`style`:if(e.hasAttribute(`data-precedence`))break;return e;case`script`:if(a=e.getAttribute(`src`),(a!==(i.src==null?null:i.src)||e.getAttribute(`type`)!==(i.type==null?null:i.type)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin))&&a&&e.hasAttribute(`async`)&&!e.hasAttribute(`itemprop`))break;return e;default:return e}if(e=J(e.nextSibling),e===null)break}return null}function lf(e,t,n){if(t===``)return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!n||(e=J(e.nextSibling),e===null))return null;return e}function uf(e,t){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!t||(e=J(e.nextSibling),e===null))return null;return e}function df(e){return e.data===`$?`||e.data===`$~`}function ff(e){return e.data===`$!`||e.data===`$?`&&e.ownerDocument.readyState!==`loading`}function pf(e,t){var n=e.ownerDocument;if(e.data===`$~`)e._reactRetry=t;else if(e.data!==`$?`||n.readyState!==`loading`)t();else{var r=function(){t(),n.removeEventListener(`DOMContentLoaded`,r)};n.addEventListener(`DOMContentLoaded`,r),e._reactRetry=r}}function J(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t===`$`||t===`$!`||t===`$?`||t===`$~`||t===`&`||t===`F!`||t===`F`)break;if(t===`/$`||t===`/&`)return null}}return e}var mf=null;function hf(e){e=e.nextSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`/$`||n===`/&`){if(t===0)return J(e.nextSibling);t--}else n!==`$`&&n!==`$!`&&n!==`$?`&&n!==`$~`&&n!==`&`||t++}e=e.nextSibling}return null}function gf(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`$`||n===`$!`||n===`$?`||n===`$~`||n===`&`){if(t===0)return e;t--}else n!==`/$`&&n!==`/&`||t++}e=e.previousSibling}return null}function _f(e,t,n){switch(t=Kd(n),e){case`html`:if(e=t.documentElement,!e)throw Error(i(452));return e;case`head`:if(e=t.head,!e)throw Error(i(453));return e;case`body`:if(e=t.body,!e)throw Error(i(454));return e;default:throw Error(i(451))}}function vf(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);_t(e)}var yf=new Map,bf=new Set;function Y(e){return typeof e.getRootNode==`function`?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var xf=j.d;j.d={f:Sf,r:Cf,D:Ef,C:Df,L:Of,m:kf,X:jf,S:Af,M:Mf};function Sf(){var e=xf.f(),t=Eu();return e||t}function Cf(e){var t=yt(e);t!==null&&t.tag===5&&t.type===`form`?Ms(t):xf.r(e)}var wf=typeof document>`u`?null:document;function Tf(e,t,n){var r=wf;if(r&&typeof t==`string`&&t){var i=Vt(t);i=`link[rel="`+e+`"][href="`+i+`"]`,typeof n==`string`&&(i+=`[crossorigin="`+n+`"]`),bf.has(i)||(bf.add(i),e={rel:e,crossOrigin:n,href:t},r.querySelector(i)===null&&(t=r.createElement(`link`),Bd(t,`link`,e),St(t),r.head.appendChild(t)))}}function Ef(e){xf.D(e),Tf(`dns-prefetch`,e,null)}function Df(e,t){xf.C(e,t),Tf(`preconnect`,e,t)}function Of(e,t,n){xf.L(e,t,n);var r=wf;if(r&&e&&t){var i=`link[rel="preload"][as="`+Vt(t)+`"]`;t===`image`&&n&&n.imageSrcSet?(i+=`[imagesrcset="`+Vt(n.imageSrcSet)+`"]`,typeof n.imageSizes==`string`&&(i+=`[imagesizes="`+Vt(n.imageSizes)+`"]`)):i+=`[href="`+Vt(e)+`"]`;var a=i;switch(t){case`style`:a=Pf(e);break;case`script`:a=Rf(e)}yf.has(a)||(e=h({rel:`preload`,href:t===`image`&&n&&n.imageSrcSet?void 0:e,as:t},n),yf.set(a,e),r.querySelector(i)!==null||t===`style`&&r.querySelector(Ff(a))||t===`script`&&r.querySelector(zf(a))||(t=r.createElement(`link`),Bd(t,`link`,e),St(t),r.head.appendChild(t)))}}function kf(e,t){xf.m(e,t);var n=wf;if(n&&e){var r=t&&typeof t.as==`string`?t.as:`script`,i=`link[rel="modulepreload"][as="`+Vt(r)+`"][href="`+Vt(e)+`"]`,a=i;switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:a=Rf(e)}if(!yf.has(a)&&(e=h({rel:`modulepreload`,href:e},t),yf.set(a,e),n.querySelector(i)===null)){switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:if(n.querySelector(zf(a)))return}r=n.createElement(`link`),Bd(r,`link`,e),St(r),n.head.appendChild(r)}}}function Af(e,t,n){xf.S(e,t,n);var r=wf;if(r&&e){var i=xt(r).hoistableStyles,a=Pf(e);t||=`default`;var o=i.get(a);if(!o){var s={loading:0,preload:null};if(o=r.querySelector(Ff(a)))s.loading=5;else{e=h({rel:`stylesheet`,href:e,"data-precedence":t},n),(n=yf.get(a))&&Hf(e,n);var c=o=r.createElement(`link`);St(c),Bd(c,`link`,e),c._p=new Promise(function(e,t){c.onload=e,c.onerror=t}),c.addEventListener(`load`,function(){s.loading|=1}),c.addEventListener(`error`,function(){s.loading|=2}),s.loading|=4,Vf(o,t,r)}o={type:`stylesheet`,instance:o,count:1,state:s},i.set(a,o)}}}function jf(e,t){xf.X(e,t);var n=wf;if(n&&e){var r=xt(n).hoistableScripts,i=Rf(e),a=r.get(i);a||(a=n.querySelector(zf(i)),a||(e=h({src:e,async:!0},t),(t=yf.get(i))&&Uf(e,t),a=n.createElement(`script`),St(a),Bd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Mf(e,t){xf.M(e,t);var n=wf;if(n&&e){var r=xt(n).hoistableScripts,i=Rf(e),a=r.get(i);a||(a=n.querySelector(zf(i)),a||(e=h({src:e,async:!0,type:`module`},t),(t=yf.get(i))&&Uf(e,t),a=n.createElement(`script`),St(a),Bd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Nf(e,t,n,r){var a=(a=fe.current)?Y(a):null;if(!a)throw Error(i(446));switch(e){case`meta`:case`title`:return null;case`style`:return typeof n.precedence==`string`&&typeof n.href==`string`?(t=Pf(n.href),n=xt(a).hoistableStyles,r=n.get(t),r||(r={type:`style`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};case`link`:if(n.rel===`stylesheet`&&typeof n.href==`string`&&typeof n.precedence==`string`){e=Pf(n.href);var o=xt(a).hoistableStyles,s=o.get(e);if(s||(a=a.ownerDocument||a,s={type:`stylesheet`,instance:null,count:0,state:{loading:0,preload:null}},o.set(e,s),(o=a.querySelector(Ff(e)))&&!o._p&&(s.instance=o,s.state.loading=5),yf.has(e)||(n={rel:`preload`,as:`style`,href:n.href,crossOrigin:n.crossOrigin,integrity:n.integrity,media:n.media,hrefLang:n.hrefLang,referrerPolicy:n.referrerPolicy},yf.set(e,n),o||Lf(a,e,n,s.state))),t&&r===null)throw Error(i(528,``));return s}if(t&&r!==null)throw Error(i(529,``));return null;case`script`:return t=n.async,n=n.src,typeof n==`string`&&t&&typeof t!=`function`&&typeof t!=`symbol`?(t=Rf(n),n=xt(a).hoistableScripts,r=n.get(t),r||(r={type:`script`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};default:throw Error(i(444,e))}}function Pf(e){return`href="`+Vt(e)+`"`}function Ff(e){return`link[rel="stylesheet"][`+e+`]`}function If(e){return h({},e,{"data-precedence":e.precedence,precedence:null})}function Lf(e,t,n,r){e.querySelector(`link[rel="preload"][as="style"][`+t+`]`)?r.loading=1:(t=e.createElement(`link`),r.preload=t,t.addEventListener(`load`,function(){return r.loading|=1}),t.addEventListener(`error`,function(){return r.loading|=2}),Bd(t,`link`,n),St(t),e.head.appendChild(t))}function Rf(e){return`[src="`+Vt(e)+`"]`}function zf(e){return`script[async]`+e}function Bf(e,t,n){if(t.count++,t.instance===null)switch(t.type){case`style`:var r=e.querySelector(`style[data-href~="`+Vt(n.href)+`"]`);if(r)return t.instance=r,St(r),r;var a=h({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return r=(e.ownerDocument||e).createElement(`style`),St(r),Bd(r,`style`,a),Vf(r,n.precedence,e),t.instance=r;case`stylesheet`:a=Pf(n.href);var o=e.querySelector(Ff(a));if(o)return t.state.loading|=4,t.instance=o,St(o),o;r=If(n),(a=yf.get(a))&&Hf(r,a),o=(e.ownerDocument||e).createElement(`link`),St(o);var s=o;return s._p=new Promise(function(e,t){s.onload=e,s.onerror=t}),Bd(o,`link`,r),t.state.loading|=4,Vf(o,n.precedence,e),t.instance=o;case`script`:return o=Rf(n.src),(a=e.querySelector(zf(o)))?(t.instance=a,St(a),a):(r=n,(a=yf.get(o))&&(r=h({},n),Uf(r,a)),e=e.ownerDocument||e,a=e.createElement(`script`),St(a),Bd(a,`link`,r),e.head.appendChild(a),t.instance=a);case`void`:return null;default:throw Error(i(443,t.type))}else t.type===`stylesheet`&&!(t.state.loading&4)&&(r=t.instance,t.state.loading|=4,Vf(r,n.precedence,e));return t.instance}function Vf(e,t,n){for(var r=n.querySelectorAll(`link[rel="stylesheet"][data-precedence],style[data-precedence]`),i=r.length?r[r.length-1]:null,a=i,o=0;o<r.length;o++){var s=r[o];if(s.dataset.precedence===t)a=s;else if(a!==i)break}a?a.parentNode.insertBefore(e,a.nextSibling):(t=n.nodeType===9?n.head:n,t.insertBefore(e,t.firstChild))}function Hf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.title??=t.title}function Uf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.integrity??=t.integrity}var Wf=null;function Gf(e,t,n){if(Wf===null){var r=new Map,i=Wf=new Map;i.set(n,r)}else i=Wf,r=i.get(n),r||(r=new Map,i.set(n,r));if(r.has(e))return r;for(r.set(e,null),n=n.getElementsByTagName(e),i=0;i<n.length;i++){var a=n[i];if(!(a[gt]||a[lt]||e===`link`&&a.getAttribute(`rel`)===`stylesheet`)&&a.namespaceURI!==`http://www.w3.org/2000/svg`){var o=a.getAttribute(t)||``;o=e+o;var s=r.get(o);s?s.push(a):r.set(o,[a])}}return r}function Kf(e,t,n){e=e.ownerDocument||e,e.head.insertBefore(n,t===`title`?e.querySelector(`head > title`):null)}function qf(e,t,n){if(n===1||t.itemProp!=null)return!1;switch(e){case`meta`:case`title`:return!0;case`style`:if(typeof t.precedence!=`string`||typeof t.href!=`string`||t.href===``)break;return!0;case`link`:if(typeof t.rel!=`string`||typeof t.href!=`string`||t.href===``||t.onLoad||t.onError)break;switch(t.rel){case`stylesheet`:return e=t.disabled,typeof t.precedence==`string`&&e==null;default:return!0}case`script`:if(t.async&&typeof t.async!=`function`&&typeof t.async!=`symbol`&&!t.onLoad&&!t.onError&&t.src&&typeof t.src==`string`)return!0}return!1}function Jf(e){return!(e.type===`stylesheet`&&!(e.state.loading&3))}function Yf(e,t,n,r){if(n.type===`stylesheet`&&(typeof r.media!=`string`||!1!==matchMedia(r.media).matches)&&!(n.state.loading&4)){if(n.instance===null){var i=Pf(r.href),a=t.querySelector(Ff(i));if(a){t=a._p,typeof t==`object`&&t&&typeof t.then==`function`&&(e.count++,e=Qf.bind(e),t.then(e,e)),n.state.loading|=4,n.instance=a,St(a);return}a=t.ownerDocument||t,r=If(r),(i=yf.get(i))&&Hf(r,i),a=a.createElement(`link`),St(a);var o=a;o._p=new Promise(function(e,t){o.onload=e,o.onerror=t}),Bd(a,`link`,r),n.instance=a}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(n,t),(t=n.state.preload)&&!(n.state.loading&3)&&(e.count++,n=Qf.bind(e),t.addEventListener(`load`,n),t.addEventListener(`error`,n))}}var Xf=0;function Zf(e,t){return e.stylesheets&&e.count===0&&ep(e,e.stylesheets),0<e.count||0<e.imgCount?function(n){var r=setTimeout(function(){if(e.stylesheets&&ep(e,e.stylesheets),e.unsuspend){var t=e.unsuspend;e.unsuspend=null,t()}},6e4+t);0<e.imgBytes&&Xf===0&&(Xf=62500*Ud());var i=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&ep(e,e.stylesheets),e.unsuspend)){var t=e.unsuspend;e.unsuspend=null,t()}},(e.imgBytes>Xf?50:800)+t);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(r),clearTimeout(i)}}:null}function Qf(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)ep(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var $f=null;function ep(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,$f=new Map,t.forEach(tp,e),$f=null,Qf.call(e))}function tp(e,t){if(!(t.state.loading&4)){var n=$f.get(e);if(n)var r=n.get(null);else{n=new Map,$f.set(e,n);for(var i=e.querySelectorAll(`link[data-precedence],style[data-precedence]`),a=0;a<i.length;a++){var o=i[a];(o.nodeName===`LINK`||o.getAttribute(`media`)!==`not all`)&&(n.set(o.dataset.precedence,o),r=o)}r&&n.set(null,r)}i=t.instance,o=i.getAttribute(`data-precedence`),a=n.get(o)||r,a===r&&n.set(null,i),n.set(o,i),this.count++,r=Qf.bind(this),i.addEventListener(`load`,r),i.addEventListener(`error`,r),a?a.parentNode.insertBefore(i,a.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(i,e.firstChild)),t.state.loading|=4}}var np={$$typeof:C,Provider:null,Consumer:null,_currentValue:oe,_currentValue2:oe,_threadCount:0};function rp(e,t,n,r,i,a,o,s,c){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=Qe(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Qe(0),this.hiddenUpdates=Qe(null),this.identifierPrefix=r,this.onUncaughtError=i,this.onCaughtError=a,this.onRecoverableError=o,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=c,this.incompleteTransitions=new Map}function ip(e,t,n,r,i,a,o,s,c,l,u,d){return e=new rp(e,t,n,o,c,l,u,d,s),t=1,!0===a&&(t|=24),a=di(3,null,null,t),e.current=a,a.stateNode=e,t=da(),t.refCount++,e.pooledCache=t,t.refCount++,a.memoizedState={element:r,isDehydrated:n,cache:t},Wa(a),e}function ap(e){return e?(e=li,e):li}function op(e,t,n,r,i,a){i=ap(i),r.context===null?r.context=i:r.pendingContext=i,r=Ka(t),r.payload={element:n},a=a===void 0?null:a,a!==null&&(r.callback=a),n=qa(e,r,t),n!==null&&(xu(n,e,t),Ja(n,e,t))}function sp(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function cp(e,t){sp(e,t),(e=e.alternate)&&sp(e,t)}function lp(e){if(e.tag===13||e.tag===31){var t=oi(e,67108864);t!==null&&xu(t,e,67108864),cp(e,67108864)}}function up(e){if(e.tag===13||e.tag===31){var t=yu();t=it(t);var n=oi(e,t);n!==null&&xu(n,e,t),cp(e,t)}}var dp=!0;function fp(e,t,n,r){var i=A.T;A.T=null;var a=j.p;try{j.p=2,mp(e,t,n,r)}finally{j.p=a,A.T=i}}function pp(e,t,n,r){var i=A.T;A.T=null;var a=j.p;try{j.p=8,mp(e,t,n,r)}finally{j.p=a,A.T=i}}function mp(e,t,n,r){if(dp){var i=hp(r);if(i===null)kd(e,t,r,gp,n),Dp(e,r);else if(kp(i,e,t,n,r))r.stopPropagation();else if(Dp(e,r),t&4&&-1<Ep.indexOf(e)){for(;i!==null;){var a=yt(i);if(a!==null)switch(a.tag){case 3:if(a=a.stateNode,a.current.memoizedState.isDehydrated){var o=Je(a.pendingLanes);if(o!==0){var s=a;for(s.pendingLanes|=2,s.entangledLanes|=2;o;){var c=1<<31-Ve(o);s.entanglements[1]|=c,o&=~c}ld(a),!(B&6)&&(W=Ae()+500,ud(0,!1))}}break;case 31:case 13:s=oi(a,2),s!==null&&xu(s,a,2),Eu(),cp(a,2)}if(a=hp(r),a===null&&kd(e,t,r,gp,n),a===i)break;i=a}i!==null&&r.stopPropagation()}else kd(e,t,r,null,n)}}function hp(e){return e=an(e),_p(e)}var gp=null;function _p(e){if(gp=null,e=vt(e),e!==null){var t=c(e);if(t===null)e=null;else{var n=t.tag;if(n===13){if(e=u(t),e!==null)return e;e=null}else if(n===31){if(e=d(t),e!==null)return e;e=null}else if(n===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return gp=e,null}function vp(e){switch(e){case`beforetoggle`:case`cancel`:case`click`:case`close`:case`contextmenu`:case`copy`:case`cut`:case`auxclick`:case`dblclick`:case`dragend`:case`dragstart`:case`drop`:case`focusin`:case`focusout`:case`input`:case`invalid`:case`keydown`:case`keypress`:case`keyup`:case`mousedown`:case`mouseup`:case`paste`:case`pause`:case`play`:case`pointercancel`:case`pointerdown`:case`pointerup`:case`ratechange`:case`reset`:case`resize`:case`seeked`:case`submit`:case`toggle`:case`touchcancel`:case`touchend`:case`touchstart`:case`volumechange`:case`change`:case`selectionchange`:case`textInput`:case`compositionstart`:case`compositionend`:case`compositionupdate`:case`beforeblur`:case`afterblur`:case`beforeinput`:case`blur`:case`fullscreenchange`:case`focus`:case`hashchange`:case`popstate`:case`select`:case`selectstart`:return 2;case`drag`:case`dragenter`:case`dragexit`:case`dragleave`:case`dragover`:case`mousemove`:case`mouseout`:case`mouseover`:case`pointermove`:case`pointerout`:case`pointerover`:case`scroll`:case`touchmove`:case`wheel`:case`mouseenter`:case`mouseleave`:case`pointerenter`:case`pointerleave`:return 8;case`message`:switch(je()){case Me:return 2;case Ne:return 8;case Pe:case Fe:return 32;case Ie:return 268435456;default:return 32}default:return 32}}var yp=!1,bp=null,xp=null,Sp=null,Cp=new Map,wp=new Map,Tp=[],Ep=`mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset`.split(` `);function Dp(e,t){switch(e){case`focusin`:case`focusout`:bp=null;break;case`dragenter`:case`dragleave`:xp=null;break;case`mouseover`:case`mouseout`:Sp=null;break;case`pointerover`:case`pointerout`:Cp.delete(t.pointerId);break;case`gotpointercapture`:case`lostpointercapture`:wp.delete(t.pointerId)}}function Op(e,t,n,r,i,a){return e===null||e.nativeEvent!==a?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:a,targetContainers:[i]},t!==null&&(t=yt(t),t!==null&&lp(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,i!==null&&t.indexOf(i)===-1&&t.push(i),e)}function kp(e,t,n,r,i){switch(t){case`focusin`:return bp=Op(bp,e,t,n,r,i),!0;case`dragenter`:return xp=Op(xp,e,t,n,r,i),!0;case`mouseover`:return Sp=Op(Sp,e,t,n,r,i),!0;case`pointerover`:var a=i.pointerId;return Cp.set(a,Op(Cp.get(a)||null,e,t,n,r,i)),!0;case`gotpointercapture`:return a=i.pointerId,wp.set(a,Op(wp.get(a)||null,e,t,n,r,i)),!0}return!1}function Ap(e){var t=vt(e.target);if(t!==null){var n=c(t);if(n!==null){if(t=n.tag,t===13){if(t=u(n),t!==null){e.blockedOn=t,st(e.priority,function(){up(n)});return}}else if(t===31){if(t=d(n),t!==null){e.blockedOn=t,st(e.priority,function(){up(n)});return}}else if(t===3&&n.stateNode.current.memoizedState.isDehydrated){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function jp(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=hp(e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);rn=r,n.target.dispatchEvent(r),rn=null}else return t=yt(n),t!==null&&lp(t),e.blockedOn=n,!1;t.shift()}return!0}function Mp(e,t,n){jp(e)&&n.delete(t)}function Np(){yp=!1,bp!==null&&jp(bp)&&(bp=null),xp!==null&&jp(xp)&&(xp=null),Sp!==null&&jp(Sp)&&(Sp=null),Cp.forEach(Mp),wp.forEach(Mp)}function Pp(e,n){e.blockedOn===n&&(e.blockedOn=null,yp||(yp=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,Np)))}var Fp=null;function Ip(e){Fp!==e&&(Fp=e,t.unstable_scheduleCallback(t.unstable_NormalPriority,function(){Fp===e&&(Fp=null);for(var t=0;t<e.length;t+=3){var n=e[t],r=e[t+1],i=e[t+2];if(typeof r!=`function`){if(_p(r||n)===null)continue;break}var a=yt(n);a!==null&&(e.splice(t,3),t-=3,As(a,{pending:!0,data:i,method:n.method,action:r},r,i))}}))}function Lp(e){function t(t){return Pp(t,e)}bp!==null&&Pp(bp,e),xp!==null&&Pp(xp,e),Sp!==null&&Pp(Sp,e),Cp.forEach(t),wp.forEach(t);for(var n=0;n<Tp.length;n++){var r=Tp[n];r.blockedOn===e&&(r.blockedOn=null)}for(;0<Tp.length&&(n=Tp[0],n.blockedOn===null);)Ap(n),n.blockedOn===null&&Tp.shift();if(n=(e.ownerDocument||e).$$reactFormReplay,n!=null)for(r=0;r<n.length;r+=3){var i=n[r],a=n[r+1],o=i[ut]||null;if(typeof a==`function`)o||Ip(n);else if(o){var s=null;if(a&&a.hasAttribute(`formAction`)){if(i=a,o=a[ut]||null)s=o.formAction;else if(_p(i)!==null)continue}else s=o.action;typeof s==`function`?n[r+1]=s:(n.splice(r,3),r-=3),Ip(n)}}}function Rp(){function e(e){e.canIntercept&&e.info===`react-transition`&&e.intercept({handler:function(){return new Promise(function(e){return i=e})},focusReset:`manual`,scroll:`manual`})}function t(){i!==null&&(i(),i=null),r||setTimeout(n,20)}function n(){if(!r&&!navigation.transition){var e=navigation.currentEntry;e&&e.url!=null&&navigation.navigate(e.url,{state:e.getState(),info:`react-transition`,history:`replace`})}}if(typeof navigation==`object`){var r=!1,i=null;return navigation.addEventListener(`navigate`,e),navigation.addEventListener(`navigatesuccess`,t),navigation.addEventListener(`navigateerror`,t),setTimeout(n,100),function(){r=!0,navigation.removeEventListener(`navigate`,e),navigation.removeEventListener(`navigatesuccess`,t),navigation.removeEventListener(`navigateerror`,t),i!==null&&(i(),i=null)}}}function zp(e){this._internalRoot=e}Bp.prototype.render=zp.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(i(409));var n=t.current;op(n,yu(),e,t,null,null)},Bp.prototype.unmount=zp.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;op(e.current,2,null,e,null,null),Eu(),t[dt]=null}};function Bp(e){this._internalRoot=e}Bp.prototype.unstable_scheduleHydration=function(e){if(e){var t=ot();e={blockedOn:null,target:e,priority:t};for(var n=0;n<Tp.length&&t!==0&&t<Tp[n].priority;n++);Tp.splice(n,0,e),n===0&&Ap(e)}};var Vp=n.version;if(Vp!==`19.2.5`)throw Error(i(527,Vp,`19.2.5`));j.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render==`function`?Error(i(188)):(e=Object.keys(e).join(`,`),Error(i(268,e)));return e=p(t),e=e===null?null:m(e),e=e===null?null:e.stateNode,e};var Hp={bundleType:0,version:`19.2.5`,rendererPackageName:`react-dom`,currentDispatcherRef:A,reconcilerVersion:`19.2.5`};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<`u`){var Up=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Up.isDisabled&&Up.supportsFiber)try{ze=Up.inject(Hp),P=Up}catch{}}e.createRoot=function(e,t){if(!o(e))throw Error(i(299));var n=!1,r=``,a=$s,s=ec,c=tc;return t!=null&&(!0===t.unstable_strictMode&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onUncaughtError!==void 0&&(a=t.onUncaughtError),t.onCaughtError!==void 0&&(s=t.onCaughtError),t.onRecoverableError!==void 0&&(c=t.onRecoverableError)),t=ip(e,1,!1,null,null,n,r,null,a,s,c,Rp),e[dt]=t.current,Od(e),new zp(t)},e.hydrateRoot=function(e,t,n){if(!o(e))throw Error(i(299));var r=!1,a=``,s=$s,c=ec,l=tc,u=null;return n!=null&&(!0===n.unstable_strictMode&&(r=!0),n.identifierPrefix!==void 0&&(a=n.identifierPrefix),n.onUncaughtError!==void 0&&(s=n.onUncaughtError),n.onCaughtError!==void 0&&(c=n.onCaughtError),n.onRecoverableError!==void 0&&(l=n.onRecoverableError),n.formState!==void 0&&(u=n.formState)),t=ip(e,1,!0,t,n??null,r,a,u,s,c,l,Rp),t.context=ap(null),n=t.current,r=yu(),r=it(r),a=Ka(r),a.callback=null,qa(n,a,r),n=r,t.current.lanes=n,$e(t,n),ld(t),e[dt]=t.current,Od(e),new Bp(t)},e.version=`19.2.5`})),d=t(((e,t)=>{function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>`u`||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!=`function`))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=u()})),f=t(((e,t)=>{var n=typeof Element<`u`,r=typeof Map==`function`,i=typeof Set==`function`,a=typeof ArrayBuffer==`function`&&!!ArrayBuffer.isView;function o(e,t){if(e===t)return!0;if(e&&t&&typeof e==`object`&&typeof t==`object`){if(e.constructor!==t.constructor)return!1;var s,c,l;if(Array.isArray(e)){if(s=e.length,s!=t.length)return!1;for(c=s;c--!==0;)if(!o(e[c],t[c]))return!1;return!0}var u;if(r&&e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;for(u=e.entries();!(c=u.next()).done;)if(!t.has(c.value[0]))return!1;for(u=e.entries();!(c=u.next()).done;)if(!o(c.value[1],t.get(c.value[0])))return!1;return!0}if(i&&e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;for(u=e.entries();!(c=u.next()).done;)if(!t.has(c.value[0]))return!1;return!0}if(a&&ArrayBuffer.isView(e)&&ArrayBuffer.isView(t)){if(s=e.length,s!=t.length)return!1;for(c=s;c--!==0;)if(e[c]!==t[c])return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf&&typeof e.valueOf==`function`&&typeof t.valueOf==`function`)return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString&&typeof e.toString==`function`&&typeof t.toString==`function`)return e.toString()===t.toString();if(l=Object.keys(e),s=l.length,s!==Object.keys(t).length)return!1;for(c=s;c--!==0;)if(!Object.prototype.hasOwnProperty.call(t,l[c]))return!1;if(n&&e instanceof Element)return!1;for(c=s;c--!==0;)if(!((l[c]===`_owner`||l[c]===`__v`||l[c]===`__o`)&&e.$$typeof)&&!o(e[l[c]],t[l[c]]))return!1;return!0}return e!==e&&t!==t}t.exports=function(e,t){try{return o(e,t)}catch(e){if((e.message||``).match(/stack|recursion/i))return console.warn(`react-fast-compare cannot handle circular refs`),!1;throw e}}})),p=t(((e,t)=>{t.exports=function(e,t,n,r,i,a,o,s){if(!e){var c;if(t===void 0)c=Error(`Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.`);else{var l=[n,r,i,a,o,s],u=0;c=Error(t.replace(/%s/g,function(){return l[u++]})),c.name=`Invariant Violation`}throw c.framesToPop=1,c}}})),m=t(((e,t)=>{t.exports=function(e,t,n,r){var i=n?n.call(r,e,t):void 0;if(i!==void 0)return!!i;if(e===t)return!0;if(typeof e!=`object`||!e||typeof t!=`object`||!t)return!1;var a=Object.keys(e),o=Object.keys(t);if(a.length!==o.length)return!1;for(var s=Object.prototype.hasOwnProperty.bind(t),c=0;c<a.length;c++){var l=a[c];if(!s(l))return!1;var u=e[l],d=t[l];if(i=n?n.call(r,u,d,l):void 0,i===!1||i===void 0&&u!==d)return!1}return!0}})),h=e(d(),1),g=e(a()),_=e(f()),v=e(p()),y=e(m()),b=(e=>(e.BASE=`base`,e.BODY=`body`,e.HEAD=`head`,e.HTML=`html`,e.LINK=`link`,e.META=`meta`,e.NOSCRIPT=`noscript`,e.SCRIPT=`script`,e.STYLE=`style`,e.TITLE=`title`,e.FRAGMENT=`Symbol(react.fragment)`,e))(b||{}),x={link:{rel:[`amphtml`,`canonical`,`alternate`]},script:{type:[`application/ld+json`]},meta:{charset:``,name:[`generator`,`robots`,`description`],property:[`og:type`,`og:title`,`og:url`,`og:image`,`og:image:alt`,`og:description`,`twitter:url`,`twitter:title`,`twitter:description`,`twitter:image`,`twitter:image:alt`,`twitter:card`,`twitter:site`]}},S=Object.values(b),C={accesskey:`accessKey`,charset:`charSet`,class:`className`,contenteditable:`contentEditable`,contextmenu:`contextMenu`,"http-equiv":`httpEquiv`,itemprop:`itemProp`,tabindex:`tabIndex`},w=Object.entries(C).reduce((e,[t,n])=>(e[n]=t,e),{}),T=`data-rh`,E={DEFAULT_TITLE:`defaultTitle`,DEFER:`defer`,ENCODE_SPECIAL_CHARACTERS:`encodeSpecialCharacters`,ON_CHANGE_CLIENT_STATE:`onChangeClientState`,TITLE_TEMPLATE:`titleTemplate`,PRIORITIZE_SEO_TAGS:`prioritizeSeoTags`},D=(e,t)=>{for(let n=e.length-1;n>=0;--n){let r=e[n];if(Object.prototype.hasOwnProperty.call(r,t))return r[t]}return null},O=e=>{let t=D(e,`title`),n=D(e,E.TITLE_TEMPLATE);if(Array.isArray(t)&&(t=t.join(``)),n&&t)return n.replace(/%s/g,()=>t);let r=D(e,E.DEFAULT_TITLE);return t||r||void 0},ee=e=>D(e,E.ON_CHANGE_CLIENT_STATE)||(()=>{}),te=(e,t)=>t.filter(t=>t[e]!==void 0).map(t=>t[e]).reduce((e,t)=>({...e,...t}),{}),ne=(e,t)=>t.filter(e=>e.base!==void 0).map(e=>e.base).reverse().reduce((t,n)=>{if(!t.length){let r=Object.keys(n);for(let i=0;i<r.length;i+=1){let a=r[i].toLowerCase();if(e.indexOf(a)!==-1&&n[a])return t.concat(n)}}return t},[]),re=e=>console&&typeof console.warn==`function`&&console.warn(e),ie=(e,t,n)=>{let r={};return n.filter(t=>Array.isArray(t[e])?!0:(t[e]!==void 0&&re(`Helmet: ${e} should be of type "Array". Instead found type "${typeof t[e]}"`),!1)).map(t=>t[e]).reverse().reduce((e,n)=>{let i={};n.filter(e=>{let n,a=Object.keys(e);for(let r=0;r<a.length;r+=1){let i=a[r],o=i.toLowerCase();t.indexOf(o)!==-1&&!(n===`rel`&&e[n].toLowerCase()===`canonical`)&&!(o===`rel`&&e[o].toLowerCase()===`stylesheet`)&&(n=o),t.indexOf(i)!==-1&&(i===`innerHTML`||i===`cssText`||i===`itemprop`)&&(n=i)}if(!n||!e[n])return!1;let o=e[n].toLowerCase();return r[n]||(r[n]={}),i[n]||(i[n]={}),r[n][o]?!1:(i[n][o]=!0,!0)}).reverse().forEach(t=>e.push(t));let a=Object.keys(i);for(let e=0;e<a.length;e+=1){let t=a[e];r[t]={...r[t],...i[t]}}return e},[]).reverse()},k=(e,t)=>{if(Array.isArray(e)&&e.length){for(let n=0;n<e.length;n+=1)if(e[n][t])return!0}return!1},ae=e=>({baseTag:ne([`href`],e),bodyAttributes:te(`bodyAttributes`,e),defer:D(e,E.DEFER),encode:D(e,E.ENCODE_SPECIAL_CHARACTERS),htmlAttributes:te(`htmlAttributes`,e),linkTags:ie(`link`,[`rel`,`href`],e),metaTags:ie(`meta`,[`name`,`charset`,`http-equiv`,`property`,`itemprop`],e),noscriptTags:ie(`noscript`,[`innerHTML`],e),onChangeClientState:ee(e),scriptTags:ie(`script`,[`src`,`innerHTML`],e),styleTags:ie(`style`,[`cssText`],e),title:O(e),titleAttributes:te(`titleAttributes`,e),prioritizeSeoTags:k(e,E.PRIORITIZE_SEO_TAGS)}),A=e=>Array.isArray(e)?e.join(``):e,j=(e,t)=>{let n=Object.keys(e);for(let r=0;r<n.length;r+=1)if(t[n[r]]&&t[n[r]].includes(e[n[r]]))return!0;return!1},oe=(e,t)=>Array.isArray(e)?e.reduce((e,n)=>(j(n,t)?e.priority.push(n):e.default.push(n),e),{priority:[],default:[]}):{default:e,priority:[]},se=(e,t)=>({...e,[t]:void 0}),ce=[`noscript`,`script`,`style`],le=(e,t=!0)=>t===!1?String(e):String(e).replace(/&/g,`&amp;`).replace(/</g,`&lt;`).replace(/>/g,`&gt;`).replace(/"/g,`&quot;`).replace(/'/g,`&#x27;`),M=e=>Object.keys(e).reduce((t,n)=>{let r=e[n]===void 0?`${n}`:`${n}="${e[n]}"`;return t?`${t} ${r}`:r},``),N=(e,t,n,r)=>{let i=M(n),a=A(t);return i?`<${e} ${T}="true" ${i}>${le(a,r)}</${e}>`:`<${e} ${T}="true">${le(a,r)}</${e}>`},ue=(e,t,n=!0)=>t.reduce((t,r)=>{let i=r,a=Object.keys(i).filter(e=>!(e===`innerHTML`||e===`cssText`)).reduce((e,t)=>{let r=i[t]===void 0?t:`${t}="${le(i[t],n)}"`;return e?`${e} ${r}`:r},``),o=i.innerHTML||i.cssText||``;return`${t}<${e} ${T}="true" ${a}${ce.indexOf(e)===-1?`/>`:`>${o}</${e}>`}`},``),de=(e,t={})=>Object.keys(e).reduce((t,n)=>{let r=C[n];return t[r||n]=e[n],t},t),fe=(e,t,n)=>{let r=de(n,{key:t,[T]:!0});return[g.createElement(`title`,r,t)]},pe=(e,t)=>t.map((t,n)=>{let r={key:n,[T]:!0};return Object.keys(t).forEach(e=>{let n=C[e]||e;n===`innerHTML`||n===`cssText`?r.dangerouslySetInnerHTML={__html:t.innerHTML||t.cssText}:r[n]=t[e]}),g.createElement(e,r)}),me=(e,t,n=!0)=>{switch(e){case`title`:return{toComponent:()=>fe(e,t.title,t.titleAttributes),toString:()=>N(e,t.title,t.titleAttributes,n)};case`bodyAttributes`:case`htmlAttributes`:return{toComponent:()=>de(t),toString:()=>M(t)};default:return{toComponent:()=>pe(e,t),toString:()=>ue(e,t,n)}}},he=({metaTags:e,linkTags:t,scriptTags:n,encode:r})=>{let i=oe(e,x.meta),a=oe(t,x.link),o=oe(n,x.script);return{priorityMethods:{toComponent:()=>[...pe(`meta`,i.priority),...pe(`link`,a.priority),...pe(`script`,o.priority)],toString:()=>`${me(`meta`,i.priority,r)} ${me(`link`,a.priority,r)} ${me(`script`,o.priority,r)}`},metaTags:i.default,linkTags:a.default,scriptTags:o.default}},ge=e=>{let{baseTag:t,bodyAttributes:n,encode:r=!0,htmlAttributes:i,noscriptTags:a,styleTags:o,title:s=``,titleAttributes:c,prioritizeSeoTags:l}=e,{linkTags:u,metaTags:d,scriptTags:f}=e,p={toComponent:()=>[],toString:()=>``};return l&&({priorityMethods:p,linkTags:u,metaTags:d,scriptTags:f}=he(e)),{priority:p,base:me(`base`,t,r),bodyAttributes:me(`bodyAttributes`,n,r),htmlAttributes:me(`htmlAttributes`,i,r),link:me(`link`,u,r),meta:me(`meta`,d,r),noscript:me(`noscript`,a,r),script:me(`script`,f,r),style:me(`style`,o,r),title:me(`title`,{title:s,titleAttributes:c},r)}},_e=[],ve=!!(typeof window<`u`&&window.document&&window.document.createElement),ye=class{instances=[];canUseDOM=ve;context;value={setHelmet:e=>{this.context.helmet=e},helmetInstances:{get:()=>this.canUseDOM?_e:this.instances,add:e=>{(this.canUseDOM?_e:this.instances).push(e)},remove:e=>{let t=(this.canUseDOM?_e:this.instances).indexOf(e);(this.canUseDOM?_e:this.instances).splice(t,1)}}};constructor(e,t){this.context=e,this.canUseDOM=t||!1,t||(e.helmet=ge({baseTag:[],bodyAttributes:{},encodeSpecialCharacters:!0,htmlAttributes:{},linkTags:[],metaTags:[],noscriptTags:[],scriptTags:[],styleTags:[],title:``,titleAttributes:{}}))}},be=parseInt(`19.2.5`.split(`.`)[0],10)>=19,xe=g.createContext({}),Se=class e extends g.Component{static canUseDOM=ve;helmetData;constructor(t){super(t),be?this.helmetData=null:this.helmetData=new ye(this.props.context||{},e.canUseDOM)}render(){return be?g.createElement(g.Fragment,null,this.props.children):g.createElement(xe.Provider,{value:this.helmetData.value},this.props.children)}},Ce=(e,t)=>{let n=document.head||document.querySelector(`head`),r=n.querySelectorAll(`${e}[${T}]`),i=[].slice.call(r),a=[],o;return t&&t.length&&t.forEach(t=>{let n=document.createElement(e);for(let e in t)if(Object.prototype.hasOwnProperty.call(t,e))if(e===`innerHTML`)n.innerHTML=t.innerHTML;else if(e===`cssText`){let e=t.cssText;n.appendChild(document.createTextNode(e))}else{let r=e,i=t[r]===void 0?``:t[r];n.setAttribute(e,i)}n.setAttribute(T,`true`),i.some((e,t)=>(o=t,n.isEqualNode(e)))?i.splice(o,1):a.push(n)}),i.forEach(e=>e.parentNode?.removeChild(e)),a.forEach(e=>n.appendChild(e)),{oldTags:i,newTags:a}},we=(e,t)=>{let n=document.getElementsByTagName(e)[0];if(!n)return;let r=n.getAttribute(T),i=r?r.split(`,`):[],a=[...i],o=Object.keys(t);for(let e of o){let r=t[e]||``;n.getAttribute(e)!==r&&n.setAttribute(e,r),i.indexOf(e)===-1&&i.push(e);let o=a.indexOf(e);o!==-1&&a.splice(o,1)}for(let e=a.length-1;e>=0;--e)n.removeAttribute(a[e]);i.length===a.length?n.removeAttribute(T):n.getAttribute(T)!==o.join(`,`)&&n.setAttribute(T,o.join(`,`))},Te=(e,t)=>{e!==void 0&&document.title!==e&&(document.title=A(e)),we(`title`,t)},Ee=(e,t)=>{let{baseTag:n,bodyAttributes:r,htmlAttributes:i,linkTags:a,metaTags:o,noscriptTags:s,onChangeClientState:c,scriptTags:l,styleTags:u,title:d,titleAttributes:f}=e;we(`body`,r),we(`html`,i),Te(d,f);let p={baseTag:Ce(`base`,n),linkTags:Ce(`link`,a),metaTags:Ce(`meta`,o),noscriptTags:Ce(`noscript`,s),scriptTags:Ce(`script`,l),styleTags:Ce(`style`,u)},m={},h={};Object.keys(p).forEach(e=>{let{newTags:t,oldTags:n}=p[e];t.length&&(m[e]=t),n.length&&(h[e]=p[e].oldTags)}),t&&t(),c(e,m,h)},De=null,Oe=e=>{De&&cancelAnimationFrame(De),e.defer?De=requestAnimationFrame(()=>{Ee(e,()=>{De=null})}):(Ee(e),De=null)},ke=class extends g.Component{rendered=!1;shouldComponentUpdate(e){return!(0,y.default)(e,this.props)}componentDidUpdate(){this.emitChange()}componentWillUnmount(){let{helmetInstances:e}=this.props.context;e.remove(this),this.emitChange()}emitChange(){let{helmetInstances:e,setHelmet:t}=this.props.context,n=null,r=ae(e.get().map(e=>{let{context:t,...n}=e.props;return n}));Se.canUseDOM?Oe(r):ge&&(n=ge(r)),t(n)}init(){if(this.rendered)return;this.rendered=!0;let{helmetInstances:e}=this.props.context;e.add(this),this.emitChange()}render(){return this.init(),null}},Ae=[],je=e=>{let t={};for(let n of Object.keys(e))t[w[n]||n]=e[n];return t},Me=e=>{let t={};for(let n of Object.keys(e)){let r=C[n];t[r||n]=e[n]}return t},Ne=(e,t)=>{if(!ve)return;let n=document.getElementsByTagName(e)[0];if(!n)return;let r=`data-rh-managed`,i=n.getAttribute(r),a=i?i.split(`,`):[],o=Object.keys(t);for(let e of a)o.includes(e)||n.removeAttribute(e);for(let e of o){let r=t[e];r==null||r===!1?n.removeAttribute(e):r===!0?n.setAttribute(e,``):n.setAttribute(e,String(r))}o.length>0?n.setAttribute(r,o.join(`,`)):n.removeAttribute(r)},Pe=()=>{let e={},t={};for(let n of Ae){let{htmlAttributes:r,bodyAttributes:i}=n.props;r&&Object.assign(e,je(r)),i&&Object.assign(t,je(i))}Ne(`html`,e),Ne(`body`,t)},Fe=class extends g.Component{componentDidMount(){Ae.push(this),Pe()}componentDidUpdate(){Pe()}componentWillUnmount(){let e=Ae.indexOf(this);e!==-1&&Ae.splice(e,1),Pe()}resolveTitle(){let{title:e,titleTemplate:t,defaultTitle:n}=this.props;return e&&t?t.replace(/%s/g,()=>Array.isArray(e)?e.join(``):e):e||n||void 0}renderTitle(){let e=this.resolveTitle();if(e===void 0)return null;let t=this.props.titleAttributes||{};return g.createElement(`title`,Me(t),e)}renderBase(){let{base:e}=this.props;return e?g.createElement(`base`,Me(e)):null}renderMeta(){let{meta:e}=this.props;return!e||!Array.isArray(e)?null:e.map((e,t)=>g.createElement(`meta`,{key:t,...Me(e)}))}renderLink(){let{link:e}=this.props;return!e||!Array.isArray(e)?null:e.map((e,t)=>g.createElement(`link`,{key:t,...Me(e)}))}renderScript(){let{script:e}=this.props;return!e||!Array.isArray(e)?null:e.map((e,t)=>{let{innerHTML:n,...r}=e,i=Me(r);return n&&(i.dangerouslySetInnerHTML={__html:n}),g.createElement(`script`,{key:t,...i})})}renderStyle(){let{style:e}=this.props;return!e||!Array.isArray(e)?null:e.map((e,t)=>{let{cssText:n,...r}=e,i=Me(r);return n&&(i.dangerouslySetInnerHTML={__html:n}),g.createElement(`style`,{key:t,...i})})}renderNoscript(){let{noscript:e}=this.props;return!e||!Array.isArray(e)?null:e.map((e,t)=>{let{innerHTML:n,...r}=e,i=Me(r);return n&&(i.dangerouslySetInnerHTML={__html:n}),g.createElement(`noscript`,{key:t,...i})})}render(){return g.createElement(g.Fragment,null,this.renderTitle(),this.renderBase(),this.renderMeta(),this.renderLink(),this.renderScript(),this.renderStyle(),this.renderNoscript())}},Ie=class extends g.Component{static defaultProps={defer:!0,encodeSpecialCharacters:!0,prioritizeSeoTags:!1};shouldComponentUpdate(e){return!(0,_.default)(se(this.props,`helmetData`),se(e,`helmetData`))}mapNestedChildrenToProps(e,t){if(!t)return null;switch(e.type){case`script`:case`noscript`:return{innerHTML:t};case`style`:return{cssText:t};default:throw Error(`<${e.type} /> elements are self-closing and can not contain children. Refer to our API for more information.`)}}flattenArrayTypeChildren(e,t,n,r){return{...t,[e.type]:[...t[e.type]||[],{...n,...this.mapNestedChildrenToProps(e,r)}]}}mapObjectTypeChildren(e,t,n,r){switch(e.type){case`title`:return{...t,[e.type]:r,titleAttributes:{...n}};case`body`:return{...t,bodyAttributes:{...n}};case`html`:return{...t,htmlAttributes:{...n}};default:return{...t,[e.type]:{...n}}}}mapArrayTypeChildrenToProps(e,t){let n={...t};return Object.keys(e).forEach(t=>{n={...n,[t]:e[t]}}),n}warnOnInvalidChildren(e,t){return(0,v.default)(S.some(t=>e.type===t),typeof e.type==`function`?`You may be attempting to nest <Helmet> components within each other, which is not allowed. Refer to our API for more information.`:`Only elements types ${S.join(`, `)} are allowed. Helmet does not support rendering <${e.type}> elements. Refer to our API for more information.`),(0,v.default)(!t||typeof t==`string`||Array.isArray(t)&&!t.some(e=>typeof e!=`string`),`Helmet expects a string as a child of <${e.type}>. Did you forget to wrap your children in braces? ( <${e.type}>{\`\`}</${e.type}> ) Refer to our API for more information.`),!0}mapChildrenToProps(e,t){let n={};return g.Children.forEach(e,e=>{if(!e||!e.props)return;let{children:r,...i}=e.props,a=Object.keys(i).reduce((e,t)=>(e[w[t]||t]=i[t],e),{}),{type:o}=e;switch(typeof o==`symbol`?o=o.toString():this.warnOnInvalidChildren(e,r),o){case`Symbol(react.fragment)`:t=this.mapChildrenToProps(r,t);break;case`link`:case`meta`:case`noscript`:case`script`:case`style`:n=this.flattenArrayTypeChildren(e,n,a,r);break;default:t=this.mapObjectTypeChildren(e,t,a,r);break}}),this.mapArrayTypeChildrenToProps(n,t)}render(){let{children:e,...t}=this.props,n={...t},{helmetData:r}=t;return e&&(n=this.mapChildrenToProps(e,n)),r&&!(r instanceof ye)&&(r=new ye(r.context,!0),delete n.helmetData),be?g.createElement(Fe,{...n}):r?g.createElement(ke,{...n,context:r.value}):g.createElement(xe.Consumer,null,e=>g.createElement(ke,{...n,context:e}))}},Le=t((e=>{var t=a().__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;e.c=function(e){return t.H.useMemoCache(e)}})),Re=t(((e,t)=>{t.exports=Le()})),ze=e(l(),1),P=Re(),Be=`modulepreload`,Ve=function(e){return`/`+e},He={},Ue=function(e,t,n){let r=Promise.resolve();if(t&&t.length>0){let e=document.getElementsByTagName(`link`),i=document.querySelector(`meta[property=csp-nonce]`),a=i?.nonce||i?.getAttribute(`nonce`);function o(e){return Promise.all(e.map(e=>Promise.resolve(e).then(e=>({status:`fulfilled`,value:e}),e=>({status:`rejected`,reason:e}))))}r=o(t.map(t=>{if(t=Ve(t,n),t in He)return;He[t]=!0;let r=t.endsWith(`.css`),i=r?`[rel="stylesheet"]`:``;if(n)for(let n=e.length-1;n>=0;n--){let i=e[n];if(i.href===t&&(!r||i.rel===`stylesheet`))return}else if(document.querySelector(`link[href="${t}"]${i}`))return;let o=document.createElement(`link`);if(o.rel=r?`stylesheet`:Be,r||(o.as=`script`),o.crossOrigin=``,o.href=t,a&&o.setAttribute(`nonce`,a),document.head.appendChild(o),r)return new Promise((e,n)=>{o.addEventListener(`load`,e),o.addEventListener(`error`,()=>n(Error(`Unable to preload CSS for ${t}`)))})}))}function i(e){let t=new Event(`vite:preloadError`,{cancelable:!0});if(t.payload=e,window.dispatchEvent(t),!t.defaultPrevented)throw e}return r.then(t=>{for(let e of t||[])e.status===`rejected`&&i(e.reason);return e().catch(i)})},We=e=>{throw TypeError(e)},Ge=(e,t,n)=>t.has(e)||We(`Cannot `+n),Ke=(e,t,n)=>(Ge(e,t,`read from private field`),n?n.call(e):t.get(e)),qe=(e,t,n)=>t.has(e)?We(`Cannot add the same private member more than once`):t instanceof WeakSet?t.add(e):t.set(e,n),Je=`popstate`;function Ye(e){return typeof e==`object`&&!!e&&`pathname`in e&&`search`in e&&`hash`in e&&`state`in e&&`key`in e}function Xe(e={}){function t(e,t){let n=t.state?.masked,{pathname:r,search:i,hash:a}=n||e.location;return et(``,{pathname:r,search:i,hash:a},t.state&&t.state.usr||null,t.state&&t.state.key||`default`,n?{pathname:e.location.pathname,search:e.location.search,hash:e.location.hash}:void 0)}function n(e,t){return typeof t==`string`?t:tt(t)}return rt(t,n,null,e)}function F(e,t){if(e===!1||e==null)throw Error(t)}function Ze(e,t){if(!e){typeof console<`u`&&console.warn(t);try{throw Error(t)}catch{}}}function Qe(){return Math.random().toString(36).substring(2,10)}function $e(e,t){return{usr:e.state,key:e.key,idx:t,masked:e.unstable_mask?{pathname:e.pathname,search:e.search,hash:e.hash}:void 0}}function et(e,t,n=null,r,i){return{pathname:typeof e==`string`?e:e.pathname,search:``,hash:``,...typeof t==`string`?nt(t):t,state:n,key:t&&t.key||r||Qe(),unstable_mask:i}}function tt({pathname:e=`/`,search:t=``,hash:n=``}){return t&&t!==`?`&&(e+=t.charAt(0)===`?`?t:`?`+t),n&&n!==`#`&&(e+=n.charAt(0)===`#`?n:`#`+n),e}function nt(e){let t={};if(e){let n=e.indexOf(`#`);n>=0&&(t.hash=e.substring(n),e=e.substring(0,n));let r=e.indexOf(`?`);r>=0&&(t.search=e.substring(r),e=e.substring(0,r)),e&&(t.pathname=e)}return t}function rt(e,t,n,r={}){let{window:i=document.defaultView,v5Compat:a=!1}=r,o=i.history,s=`POP`,c=null,l=u();l??(l=0,o.replaceState({...o.state,idx:l},``));function u(){return(o.state||{idx:null}).idx}function d(){s=`POP`;let e=u(),t=e==null?null:e-l;l=e,c&&c({action:s,location:h.location,delta:t})}function f(e,t){s=`PUSH`;let r=Ye(e)?e:et(h.location,e,t);n&&n(r,e),l=u()+1;let d=$e(r,l),f=h.createHref(r.unstable_mask||r);try{o.pushState(d,``,f)}catch(e){if(e instanceof DOMException&&e.name===`DataCloneError`)throw e;i.location.assign(f)}a&&c&&c({action:s,location:h.location,delta:1})}function p(e,t){s=`REPLACE`;let r=Ye(e)?e:et(h.location,e,t);n&&n(r,e),l=u();let i=$e(r,l),d=h.createHref(r.unstable_mask||r);o.replaceState(i,``,d),a&&c&&c({action:s,location:h.location,delta:0})}function m(e){return it(e)}let h={get action(){return s},get location(){return e(i,o)},listen(e){if(c)throw Error(`A history only accepts one active listener`);return i.addEventListener(Je,d),c=e,()=>{i.removeEventListener(Je,d),c=null}},createHref(e){return t(i,e)},createURL:m,encodeLocation(e){let t=m(e);return{pathname:t.pathname,search:t.search,hash:t.hash}},push:f,replace:p,go(e){return o.go(e)}};return h}function it(e,t=!1){let n=`http://localhost`;typeof window<`u`&&(n=window.location.origin===`null`?window.location.href:window.location.origin),F(n,`No window.location.(origin|href) available to create URL`);let r=typeof e==`string`?e:tt(e);return r=r.replace(/ $/,`%20`),!t&&r.startsWith(`//`)&&(r=n+r),new URL(r,n)}var at,ot=class{constructor(e){if(qe(this,at,new Map),e)for(let[t,n]of e)this.set(t,n)}get(e){if(Ke(this,at).has(e))return Ke(this,at).get(e);if(e.defaultValue!==void 0)return e.defaultValue;throw Error(`No value found for context`)}set(e,t){Ke(this,at).set(e,t)}};at=new WeakMap;var st=new Set([`lazy`,`caseSensitive`,`path`,`id`,`index`,`children`]);function ct(e){return st.has(e)}var lt=new Set([`lazy`,`caseSensitive`,`path`,`id`,`index`,`middleware`,`children`]);function ut(e){return lt.has(e)}function dt(e){return e.index===!0}function ft(e,t,n=[],r={},i=!1){return e.map((e,a)=>{let o=[...n,String(a)],s=typeof e.id==`string`?e.id:o.join(`-`);if(F(e.index!==!0||!e.children,`Cannot specify children on an index route`),F(i||!r[s],`Found a route id collision on id "${s}".  Route id's must be globally unique within Data Router usages`),dt(e)){let n={...e,id:s};return r[s]=pt(n,t(n)),n}else{let n={...e,id:s,children:void 0};return r[s]=pt(n,t(n)),e.children&&(n.children=ft(e.children,t,o,r,i)),n}})}function pt(e,t){return Object.assign(e,{...t,...typeof t.lazy==`object`&&t.lazy!=null?{lazy:{...e.lazy,...t.lazy}}:{}})}function mt(e,t,n=`/`){return ht(e,t,n,!1)}function ht(e,t,n,r){let i=Nt((typeof t==`string`?nt(t):t).pathname||`/`,n);if(i==null)return null;let a=_t(e);yt(a);let o=null;for(let e=0;o==null&&e<a.length;++e){let t=Mt(i);o=kt(a[e],t,r)}return o}function gt(e,t){let{route:n,pathname:r,params:i}=e;return{id:n.id,pathname:r,params:i,data:t[n.id],loaderData:t[n.id],handle:n.handle}}function _t(e,t=[],n=[],r=``,i=!1){let a=(e,a,o=i,s)=>{let c={relativePath:s===void 0?e.path||``:s,caseSensitive:e.caseSensitive===!0,childrenIndex:a,route:e};if(c.relativePath.startsWith(`/`)){if(!c.relativePath.startsWith(r)&&o)return;F(c.relativePath.startsWith(r),`Absolute route path "${c.relativePath}" nested under path "${r}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),c.relativePath=c.relativePath.slice(r.length)}let l=Wt([r,c.relativePath]),u=n.concat(c);e.children&&e.children.length>0&&(F(e.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${l}".`),_t(e.children,t,u,l,o)),!(e.path==null&&!e.index)&&t.push({path:l,score:Dt(l,e.index),routesMeta:u})};return e.forEach((e,t)=>{if(e.path===``||!e.path?.includes(`?`))a(e,t);else for(let n of vt(e.path))a(e,t,!0,n)}),t}function vt(e){let t=e.split(`/`);if(t.length===0)return[];let[n,...r]=t,i=n.endsWith(`?`),a=n.replace(/\?$/,``);if(r.length===0)return i?[a,``]:[a];let o=vt(r.join(`/`)),s=[];return s.push(...o.map(e=>e===``?a:[a,e].join(`/`))),i&&s.push(...o),s.map(t=>e.startsWith(`/`)&&t===``?`/`:t)}function yt(e){e.sort((e,t)=>e.score===t.score?Ot(e.routesMeta.map(e=>e.childrenIndex),t.routesMeta.map(e=>e.childrenIndex)):t.score-e.score)}var bt=/^:[\w-]+$/,xt=3,St=2,Ct=1,wt=10,Tt=-2,Et=e=>e===`*`;function Dt(e,t){let n=e.split(`/`),r=n.length;return n.some(Et)&&(r+=Tt),t&&(r+=St),n.filter(e=>!Et(e)).reduce((e,t)=>e+(bt.test(t)?xt:t===``?Ct:wt),r)}function Ot(e,t){return e.length===t.length&&e.slice(0,-1).every((e,n)=>e===t[n])?e[e.length-1]-t[t.length-1]:0}function kt(e,t,n=!1){let{routesMeta:r}=e,i={},a=`/`,o=[];for(let e=0;e<r.length;++e){let s=r[e],c=e===r.length-1,l=a===`/`?t:t.slice(a.length)||`/`,u=At({path:s.relativePath,caseSensitive:s.caseSensitive,end:c},l),d=s.route;if(!u&&c&&n&&!r[r.length-1].route.index&&(u=At({path:s.relativePath,caseSensitive:s.caseSensitive,end:!1},l)),!u)return null;Object.assign(i,u.params),o.push({params:i,pathname:Wt([a,u.pathname]),pathnameBase:Kt(Wt([a,u.pathnameBase])),route:d}),u.pathnameBase!==`/`&&(a=Wt([a,u.pathnameBase]))}return o}function At(e,t){typeof e==`string`&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=jt(e.path,e.caseSensitive,e.end),i=t.match(n);if(!i)return null;let a=i[0],o=a.replace(/(.)\/+$/,`$1`),s=i.slice(1);return{params:r.reduce((e,{paramName:t,isOptional:n},r)=>{if(t===`*`){let e=s[r]||``;o=a.slice(0,a.length-e.length).replace(/(.)\/+$/,`$1`)}let i=s[r];return n&&!i?e[t]=void 0:e[t]=(i||``).replace(/%2F/g,`/`),e},{}),pathname:a,pathnameBase:o,pattern:e}}function jt(e,t=!1,n=!0){Ze(e===`*`||!e.endsWith(`*`)||e.endsWith(`/*`),`Route path "${e}" will be treated as if it were "${e.replace(/\*$/,`/*`)}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${e.replace(/\*$/,`/*`)}".`);let r=[],i=`^`+e.replace(/\/*\*?$/,``).replace(/^\/*/,`/`).replace(/[\\.*+^${}|()[\]]/g,`\\$&`).replace(/\/:([\w-]+)(\?)?/g,(e,t,n,i,a)=>{if(r.push({paramName:t,isOptional:n!=null}),n){let t=a.charAt(i+e.length);return t&&t!==`/`?`/([^\\/]*)`:`(?:/([^\\/]*))?`}return`/([^\\/]+)`}).replace(/\/([\w-]+)\?(\/|$)/g,`(/$1)?$2`);return e.endsWith(`*`)?(r.push({paramName:`*`}),i+=e===`*`||e===`/*`?`(.*)$`:`(?:\\/(.+)|\\/*)$`):n?i+=`\\/*$`:e!==``&&e!==`/`&&(i+=`(?:(?=\\/|$))`),[new RegExp(i,t?void 0:`i`),r]}function Mt(e){try{return e.split(`/`).map(e=>decodeURIComponent(e).replace(/\//g,`%2F`)).join(`/`)}catch(t){return Ze(!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 Nt(e,t){if(t===`/`)return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith(`/`)?t.length-1:t.length,r=e.charAt(n);return r&&r!==`/`?null:e.slice(n)||`/`}function Pt({basename:e,pathname:t}){return t===`/`?e:Wt([e,t])}var Ft=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,It=e=>Ft.test(e);function Lt(e,t=`/`){let{pathname:n,search:r=``,hash:i=``}=typeof e==`string`?nt(e):e,a;return n?(n=Ut(n),a=n.startsWith(`/`)?Rt(n.substring(1),`/`):Rt(n,t)):a=t,{pathname:a,search:qt(r),hash:Jt(i)}}function Rt(e,t){let n=Gt(t).split(`/`);return e.split(`/`).forEach(e=>{e===`..`?n.length>1&&n.pop():e!==`.`&&n.push(e)}),n.length>1?n.join(`/`):`/`}function zt(e,t,n,r){return`Cannot include a '${e}' character in a manually specified \`to.${t}\` field [${JSON.stringify(r)}].  Please separate it out to the \`to.${n}\` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.`}function Bt(e){return e.filter((e,t)=>t===0||e.route.path&&e.route.path.length>0)}function Vt(e){let t=Bt(e);return t.map((e,n)=>n===t.length-1?e.pathname:e.pathnameBase)}function Ht(e,t,n,r=!1){let i;typeof e==`string`?i=nt(e):(i={...e},F(!i.pathname||!i.pathname.includes(`?`),zt(`?`,`pathname`,`search`,i)),F(!i.pathname||!i.pathname.includes(`#`),zt(`#`,`pathname`,`hash`,i)),F(!i.search||!i.search.includes(`#`),zt(`#`,`search`,`hash`,i)));let a=e===``||i.pathname===``,o=a?`/`:i.pathname,s;if(o==null)s=n;else{let e=t.length-1;if(!r&&o.startsWith(`..`)){let t=o.split(`/`);for(;t[0]===`..`;)t.shift(),--e;i.pathname=t.join(`/`)}s=e>=0?t[e]:`/`}let c=Lt(i,s),l=o&&o!==`/`&&o.endsWith(`/`),u=(a||o===`.`)&&n.endsWith(`/`);return!c.pathname.endsWith(`/`)&&(l||u)&&(c.pathname+=`/`),c}var Ut=e=>e.replace(/\/\/+/g,`/`),Wt=e=>Ut(e.join(`/`)),Gt=e=>e.replace(/\/+$/,``),Kt=e=>Gt(e).replace(/^\/*/,`/`),qt=e=>!e||e===`?`?``:e.startsWith(`?`)?e:`?`+e,Jt=e=>!e||e===`#`?``:e.startsWith(`#`)?e:`#`+e,Yt=class{constructor(e,t,n,r=!1){this.status=e,this.statusText=t||``,this.internal=r,n instanceof Error?(this.data=n.toString(),this.error=n):this.data=n}};function Xt(e){return e!=null&&typeof e.status==`number`&&typeof e.statusText==`string`&&typeof e.internal==`boolean`&&`data`in e}function Zt(e){return Wt(e.map(e=>e.route.path).filter(Boolean))||`/`}var Qt=typeof window<`u`&&window.document!==void 0&&window.document.createElement!==void 0;function $t(e,t){let n=e;if(typeof n!=`string`||!Ft.test(n))return{absoluteURL:void 0,isExternal:!1,to:n};let r=n,i=!1;if(Qt)try{let e=new URL(window.location.href),r=n.startsWith(`//`)?new URL(e.protocol+n):new URL(n),a=Nt(r.pathname,t);r.origin===e.origin&&a!=null?n=a+r.search+r.hash:i=!0}catch{Ze(!1,`<Link to="${n}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}return{absoluteURL:r,isExternal:i,to:n}}var en=Symbol(`Uninstrumented`);function tn(e,t){let n={lazy:[],"lazy.loader":[],"lazy.action":[],"lazy.middleware":[],middleware:[],loader:[],action:[]};e.forEach(e=>e({id:t.id,index:t.index,path:t.path,instrument(e){let t=Object.keys(n);for(let r of t)e[r]&&n[r].push(e[r])}}));let r={};if(typeof t.lazy==`function`&&n.lazy.length>0){let e=rn(n.lazy,t.lazy,()=>void 0);e&&(r.lazy=e)}if(typeof t.lazy==`object`){let e=t.lazy;[`middleware`,`loader`,`action`].forEach(t=>{let i=e[t],a=n[`lazy.${t}`];if(typeof i==`function`&&a.length>0){let e=rn(a,i,()=>void 0);e&&(r.lazy=Object.assign(r.lazy||{},{[t]:e}))}})}return[`loader`,`action`].forEach(e=>{let i=t[e];if(typeof i==`function`&&n[e].length>0){let t=i[en]??i,a=rn(n[e],t,(...e)=>on(e[0]));a&&(e===`loader`&&t.hydrate===!0&&(a.hydrate=!0),a[en]=t,r[e]=a)}}),t.middleware&&t.middleware.length>0&&n.middleware.length>0&&(r.middleware=t.middleware.map(e=>{let t=e[en]??e,r=rn(n.middleware,t,(...e)=>on(e[0]));return r?(r[en]=t,r):e})),r}function nn(e,t){let n={navigate:[],fetch:[]};if(t.forEach(e=>e({instrument(e){let t=Object.keys(e);for(let r of t)e[r]&&n[r].push(e[r])}})),n.navigate.length>0){let t=e.navigate[en]??e.navigate,r=rn(n.navigate,t,(...t)=>{let[n,r]=t;return{to:typeof n==`number`||typeof n==`string`?n:n?tt(n):`.`,...sn(e,r??{})}});r&&(r[en]=t,e.navigate=r)}if(n.fetch.length>0){let t=e.fetch[en]??e.fetch,r=rn(n.fetch,t,(...t)=>{let[n,,r,i]=t;return{href:r??`.`,fetcherKey:n,...sn(e,i??{})}});r&&(r[en]=t,e.fetch=r)}return e}function rn(e,t,n){return e.length===0?null:async(...r)=>{let i=await an(e,n(...r),()=>t(...r),e.length-1);if(i.type===`error`)throw i.value;return i.value}}async function an(e,t,n,r){let i=e[r],a;if(i){let o,s=async()=>(o?console.error(`You cannot call instrumented handlers more than once`):o=an(e,t,n,r-1),a=await o,F(a,`Expected a result`),a.type===`error`&&a.value instanceof Error?{status:`error`,error:a.value}:{status:`success`,error:void 0});try{await i(s,t)}catch(e){console.error(`An instrumentation function threw an error:`,e)}o||await s(),await o}else try{a={type:`success`,value:await n()}}catch(e){a={type:`error`,value:e}}return a||{type:`error`,value:Error(`No result assigned in instrumentation chain.`)}}function on(e){let{request:t,context:n,params:r,unstable_pattern:i}=e;return{request:cn(t),params:{...r},unstable_pattern:i,context:ln(n)}}function sn(e,t){return{currentUrl:tt(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 cn(e){return{method:e.method,url:e.url,headers:{get:(...t)=>e.headers.get(...t)}}}function ln(e){if(dn(e)){let t={...e};return Object.freeze(t),t}else return{get:t=>e.get(t)}}var un=Object.getOwnPropertyNames(Object.prototype).sort().join(`\0`);function dn(e){if(typeof e!=`object`||!e)return!1;let t=Object.getPrototypeOf(e);return t===Object.prototype||t===null||Object.getOwnPropertyNames(t).sort().join(`\0`)===un}var fn=[`POST`,`PUT`,`PATCH`,`DELETE`],pn=new Set(fn),mn=[`GET`,...fn],hn=new Set(mn),gn=new Set([301,302,303,307,308]),_n=new Set([307,308]),vn={state:`idle`,location:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},yn={state:`idle`,data:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},bn={state:`unblocked`,proceed:void 0,reset:void 0,location:void 0},xn=e=>({hasErrorBoundary:!!e.hasErrorBoundary}),Sn=`remix-router-transitions`,Cn=Symbol(`ResetLoaderData`);function wn(e){let t=e.window?e.window:typeof window<`u`?window:void 0,n=t!==void 0&&t.document!==void 0&&t.document.createElement!==void 0;F(e.routes.length>0,`You must provide a non-empty routes array to createRouter`);let r=e.hydrationRouteProperties||[],i=e.mapRouteProperties||xn,a=i;if(e.unstable_instrumentations){let t=e.unstable_instrumentations;a=e=>({...i(e),...tn(t.map(e=>e.route).filter(Boolean),e)})}let o={},s=ft(e.routes,a,void 0,o),c,l=e.basename||`/`;l.startsWith(`/`)||(l=`/${l}`);let u=e.dataStrategy||Vn,d={unstable_passThroughRequests:!1,...e.future},f=null,p=new Set,m=null,h=null,g=null,_=e.hydrationData!=null,v=mt(s,e.history.location,l),y=!1,b=null,x,S;if(v==null&&!e.patchRoutesOnNavigation){let t=dr(404,{pathname:e.history.location.pathname}),{matches:n,route:r}=ur(s);x=!0,S=!x,v=n,b={[r.id]:t}}else if(v&&!e.hydrationData&&Ye(v,s,e.history.location.pathname).active&&(v=null),!v){x=!1,S=!x,v=[];let t=Ye(null,s,e.history.location.pathname);t.active&&t.matches&&(y=!0,v=t.matches)}else if(v.some(e=>e.route.lazy))x=!1,S=!x;else if(!v.some(e=>kn(e.route)))x=!0,S=!x;else{let t=e.hydrationData?e.hydrationData.loaderData:null,n=e.hydrationData?e.hydrationData.errors:null,r=v;if(n){let e=v.findIndex(e=>n[e.route.id]!==void 0);r=r.slice(0,e+1)}S=!1,x=!0,r.forEach(e=>{let r=An(e.route,t,n);S||=r.renderFallback,x&&=!r.shouldLoad})}let C,w={historyAction:e.history.action,location:e.history.location,matches:v,initialized:x,renderFallback:S,navigation:vn,restoreScrollPosition:e.hydrationData==null?null:!1,preventScrollReset:!1,revalidation:`idle`,loaderData:e.hydrationData&&e.hydrationData.loaderData||{},actionData:e.hydrationData&&e.hydrationData.actionData||null,errors:e.hydrationData&&e.hydrationData.errors||b,fetchers:new Map,blockers:new Map},T=`POP`,E=null,D=!1,O,ee=!1,te=new Map,ne=null,re=!1,ie=!1,k=new Set,ae=new Map,A=0,j=-1,oe=new Map,se=new Set,ce=new Map,le=new Map,M=new Set,N=new Map,ue,de=null;function fe(){if(f=e.history.listen(({action:t,location:n,delta:r})=>{if(ue){ue(),ue=void 0;return}Ze(N.size===0||r!=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 i=Ue({currentLocation:w.location,nextLocation:n,historyAction:t});if(i&&r!=null){let t=new Promise(e=>{ue=e});e.history.go(r*-1),He(i,{state:`blocked`,location:n,proceed(){He(i,{state:`proceeding`,proceed:void 0,reset:void 0,location:n}),t.then(()=>e.history.go(r))},reset(){let e=new Map(w.blockers);e.set(i,bn),he({blockers:e})}}),E?.resolve(),E=null;return}return ye(t,n)}),n){Fr(t,te);let e=()=>Ir(t,te);t.addEventListener(`pagehide`,e),ne=()=>t.removeEventListener(`pagehide`,e)}return w.initialized||ye(`POP`,w.location,{initialHydration:!0}),C}function pe(){f&&f(),ne&&ne(),p.clear(),O&&O.abort(),w.fetchers.forEach((e,t)=>Fe(t)),w.blockers.forEach((e,t)=>Ve(t))}function me(e){return p.add(e),()=>p.delete(e)}function he(e,t={}){e.matches&&=e.matches.map(e=>{let t=o[e.route.id],n=e.route;return n.element!==t.element||n.errorElement!==t.errorElement||n.hydrateFallbackElement!==t.hydrateFallbackElement?{...e,route:t}:e}),w={...w,...e};let n=[],r=[];w.fetchers.forEach((e,t)=>{e.state===`idle`&&(M.has(t)?n.push(t):r.push(t))}),M.forEach(e=>{!w.fetchers.has(e)&&!ae.has(e)&&n.push(e)}),[...p].forEach(r=>r(w,{deletedFetchers:n,newErrors:e.errors??null,viewTransitionOpts:t.viewTransitionOpts,flushSync:t.flushSync===!0})),n.forEach(e=>Fe(e)),r.forEach(e=>w.fetchers.delete(e))}function ge(t,n,{flushSync:r}={}){let i=w.actionData!=null&&w.navigation.formMethod!=null&&Er(w.navigation.formMethod)&&w.navigation.state===`loading`&&t.state?._isRedirect!==!0,a;a=n.actionData?Object.keys(n.actionData).length>0?n.actionData:null:i?w.actionData:null;let o=n.loaderData?sr(w.loaderData,n.loaderData,n.matches||[],n.errors):w.loaderData,l=w.blockers;l.size>0&&(l=new Map(l),l.forEach((e,t)=>l.set(t,bn)));let u=re?!1:Je(t,n.matches||w.matches),d=D===!0||w.navigation.formMethod!=null&&Er(w.navigation.formMethod)&&t.state?._isRedirect!==!0;c&&=(s=c,void 0),re||T===`POP`||(T===`PUSH`?e.history.push(t,t.state):T===`REPLACE`&&e.history.replace(t,t.state));let f;if(T===`POP`){let e=te.get(w.location.pathname);e&&e.has(t.pathname)?f={currentLocation:w.location,nextLocation:t}:te.has(t.pathname)&&(f={currentLocation:t,nextLocation:w.location})}else if(ee){let e=te.get(w.location.pathname);e?e.add(t.pathname):(e=new Set([t.pathname]),te.set(w.location.pathname,e)),f={currentLocation:w.location,nextLocation:t}}he({...n,actionData:a,loaderData:o,historyAction:T,location:t,initialized:!0,renderFallback:!1,navigation:vn,revalidation:`idle`,restoreScrollPosition:u,preventScrollReset:d,blockers:l},{viewTransitionOpts:f,flushSync:r===!0}),T=`POP`,D=!1,ee=!1,re=!1,ie=!1,E?.resolve(),E=null,de?.resolve(),de=null}async function _e(t,n){if(E?.resolve(),E=null,typeof t==`number`){E||=Lr();let n=E.promise;return e.history.go(t),n}let{path:r,submission:i,error:a}=Dn(!1,En(w.location,w.matches,l,t,n?.fromRouteId,n?.relative),n),o;n?.unstable_mask&&(o={pathname:``,search:``,hash:``,...typeof n.unstable_mask==`string`?nt(n.unstable_mask):{...w.location.unstable_mask,...n.unstable_mask}});let s=w.location,c=et(s,r,n&&n.state,void 0,o);c={...c,...e.history.encodeLocation(c)};let u=n&&n.replace!=null?n.replace:void 0,d=`PUSH`;u===!0?d=`REPLACE`:u===!1||i!=null&&Er(i.formMethod)&&i.formAction===w.location.pathname+w.location.search&&(d=`REPLACE`);let f=n&&`preventScrollReset`in n?n.preventScrollReset===!0:void 0,p=(n&&n.flushSync)===!0,m=Ue({currentLocation:s,nextLocation:c,historyAction:d});if(m){He(m,{state:`blocked`,location:c,proceed(){He(m,{state:`proceeding`,proceed:void 0,reset:void 0,location:c}),_e(t,n)},reset(){let e=new Map(w.blockers);e.set(m,bn),he({blockers:e})}});return}await ye(d,c,{submission:i,pendingError:a,preventScrollReset:f,replace:n&&n.replace,enableViewTransition:n&&n.viewTransition,flushSync:p,callSiteDefaultShouldRevalidate:n&&n.unstable_defaultShouldRevalidate})}function ve(){de||=Lr(),Ae(),he({revalidation:`loading`});let e=de.promise;return w.navigation.state===`submitting`?e:w.navigation.state===`idle`?(ye(w.historyAction,w.location,{startUninterruptedRevalidation:!0}),e):(ye(T||w.historyAction,w.navigation.location,{overrideNavigation:w.navigation,enableViewTransition:ee===!0}),e)}async function ye(t,n,r){O&&O.abort(),O=null,T=t,re=(r&&r.startUninterruptedRevalidation)===!0,qe(w.location,w.matches),D=(r&&r.preventScrollReset)===!0,ee=(r&&r.enableViewTransition)===!0;let i=c||s,a=r&&r.overrideNavigation,o=r?.initialHydration&&w.matches&&w.matches.length>0&&!y?w.matches:mt(i,n,l),u=(r&&r.flushSync)===!0;if(o&&w.initialized&&!ie&&mr(w.location,n)&&!(r&&r.submission&&Er(r.submission.formMethod))){ge(n,{matches:o},{flushSync:u});return}let d=Ye(o,i,n.pathname);if(d.active&&d.matches&&(o=d.matches),!o){let{error:e,notFoundMatches:t,route:r}=We(n.pathname);ge(n,{matches:t,loaderData:{},errors:{[r.id]:e}},{flushSync:u});return}O=new AbortController;let f=tr(e.history,n,O.signal,r&&r.submission),p=e.getContext?await e.getContext():new ot,m;if(r&&r.pendingError)m=[lr(o).route.id,{type:`error`,error:r.pendingError}];else if(r&&r.submission&&Er(r.submission.formMethod)){let t=await be(f,n,r.submission,o,p,d.active,r&&r.initialHydration===!0,{replace:r.replace,flushSync:u});if(t.shortCircuited)return;if(t.pendingActionResult){let[e,r]=t.pendingActionResult;if(yr(r)&&Xt(r.error)&&r.error.status===404){O=null,ge(n,{matches:t.matches,loaderData:{},errors:{[e]:r.error}});return}}o=t.matches||o,m=t.pendingActionResult,a=Ar(n,r.submission),u=!1,d.active=!1,f=tr(e.history,f.url,f.signal)}let{shortCircuited:h,matches:g,loaderData:_,errors:v}=await xe(f,n,o,p,d.active,a,r&&r.submission,r&&r.fetcherSubmission,r&&r.replace,r&&r.initialHydration===!0,u,m,r&&r.callSiteDefaultShouldRevalidate);h||(O=null,ge(n,{matches:g||o,...cr(m),loaderData:_,errors:v}))}async function be(t,n,i,c,u,d,f,p={}){if(Ae(),he({navigation:jr(n,i)},{flushSync:p.flushSync===!0}),d){let e=await Xe(c,n.pathname,t.signal);if(e.type===`aborted`)return{shortCircuited:!0};if(e.type===`error`){if(e.partialMatches.length===0){let{matches:t,route:n}=ur(s);return{matches:t,pendingActionResult:[n.id,{type:`error`,error:e.error}]}}let t=lr(e.partialMatches).route.id;return{matches:e.partialMatches,pendingActionResult:[t,{type:`error`,error:e.error}]}}else if(e.matches)c=e.matches;else{let{notFoundMatches:e,error:t,route:r}=We(n.pathname);return{matches:e,pendingActionResult:[r.id,{type:`error`,error:t}]}}}let m,h=Or(c,n);if(!h.route.action&&!h.route.lazy)m={type:`error`,error:dr(405,{method:t.method,pathname:n.pathname,routeId:h.route.id})};else{let e=await Oe(t,n,qn(a,o,t,n,c,h,f?[]:r,u),u,null);if(m=e[h.route.id],!m){for(let t of c)if(e[t.route.id]){m=e[t.route.id];break}}if(t.signal.aborted)return{shortCircuited:!0}}if(br(m)){let n;return n=p&&p.replace!=null?p.replace:er(m.response.headers.get(`Location`),new URL(t.url),l,e.history)===w.location.pathname+w.location.search,await De(t,m,!0,{submission:i,replace:n}),{shortCircuited:!0}}if(yr(m)){let e=lr(c,h.route.id);return(p&&p.replace)!==!0&&(T=`PUSH`),{matches:c,pendingActionResult:[e.route.id,m,h.route.id]}}return{matches:c,pendingActionResult:[h.route.id,m]}}async function xe(t,n,i,u,d,f,p,m,h,g,_,v,y){let b=f||Ar(n,p),x=p||m||kr(b),S=!re&&!g;if(d){if(S){let e=Se(v);he({navigation:b,...e===void 0?{}:{actionData:e}},{flushSync:_})}let e=await Xe(i,n.pathname,t.signal);if(e.type===`aborted`)return{shortCircuited:!0};if(e.type===`error`){if(e.partialMatches.length===0){let{matches:t,route:n}=ur(s);return{matches:t,loaderData:{},errors:{[n.id]:e.error}}}let t=lr(e.partialMatches).route.id;return{matches:e.partialMatches,loaderData:{},errors:{[t]:e.error}}}else if(e.matches)i=e.matches;else{let{error:e,notFoundMatches:t,route:r}=We(n.pathname);return{matches:t,loaderData:{},errors:{[r.id]:e}}}}let C=c||s,{dsMatches:T,revalidatingFetchers:E}=On(t,u,a,o,e.history,w,i,x,n,g?[]:r,g===!0,ie,k,M,ce,se,C,l,e.patchRoutesOnNavigation!=null,v,y);if(j=++A,!e.dataStrategy&&!T.some(e=>e.shouldLoad)&&!T.some(e=>e.route.middleware&&e.route.middleware.length>0)&&E.length===0){let e=ze();return ge(n,{matches:i,loaderData:{},errors:v&&yr(v[1])?{[v[0]]:v[1].error}:null,...cr(v),...e?{fetchers:new Map(w.fetchers)}:{}},{flushSync:_}),{shortCircuited:!0}}if(S){let e={};if(!d){e.navigation=b;let t=Se(v);t!==void 0&&(e.actionData=t)}E.length>0&&(e.fetchers=Ce(E)),he(e,{flushSync:_})}E.forEach(e=>{Le(e.key),e.controller&&ae.set(e.key,e.controller)});let D=()=>E.forEach(e=>Le(e.key));O&&O.signal.addEventListener(`abort`,D);let{loaderResults:ee,fetcherResults:te}=await ke(T,E,t,n,u);if(t.signal.aborted)return{shortCircuited:!0};O&&O.signal.removeEventListener(`abort`,D),E.forEach(e=>ae.delete(e.key));let ne=fr(ee);if(ne)return await De(t,ne.result,!0,{replace:h}),{shortCircuited:!0};if(ne=fr(te),ne)return se.add(ne.key),await De(t,ne.result,!0,{replace:h}),{shortCircuited:!0};let{loaderData:oe,errors:le}=or(w,i,ee,v,E,te);g&&w.errors&&(le={...w.errors,...le});let N=ze(),ue=P(j),de=N||ue||E.length>0;return{matches:i,loaderData:oe,errors:le,...de?{fetchers:new Map(w.fetchers)}:{}}}function Se(e){if(e&&!yr(e[1]))return{[e[0]]:e[1].data};if(w.actionData)return Object.keys(w.actionData).length===0?null:w.actionData}function Ce(e){return e.forEach(e=>{let t=w.fetchers.get(e.key),n=Mr(void 0,t?t.data:void 0);w.fetchers.set(e.key,n)}),new Map(w.fetchers)}async function we(t,n,r,i){Le(t);let a=(i&&i.flushSync)===!0,o=c||s,u=En(w.location,w.matches,l,r,n,i?.relative),d=mt(o,u,l),f=Ye(d,o,u);if(f.active&&f.matches&&(d=f.matches),!d){Me(t,n,dr(404,{pathname:u}),{flushSync:a});return}let{path:p,submission:m,error:h}=Dn(!0,u,i);if(h){Me(t,n,h,{flushSync:a});return}let g=e.getContext?await e.getContext():new ot,_=(i&&i.preventScrollReset)===!0;if(m&&Er(m.formMethod)){await Te(t,n,p,d,g,f.active,a,_,m,i&&i.unstable_defaultShouldRevalidate);return}ce.set(t,{routeId:n,path:p}),await Ee(t,n,p,d,g,f.active,a,_,m)}async function Te(t,n,i,u,d,f,p,m,h,g){Ae(),ce.delete(t),je(t,Nr(h,w.fetchers.get(t)),{flushSync:p});let _=new AbortController,v=tr(e.history,i,_.signal,h);if(f){let e=await Xe(u,new URL(v.url).pathname,v.signal,t);if(e.type===`aborted`)return;if(e.type===`error`){Me(t,n,e.error,{flushSync:p});return}else if(e.matches)u=e.matches;else{Me(t,n,dr(404,{pathname:i}),{flushSync:p});return}}let y=Or(u,i);if(!y.route.action&&!y.route.lazy){Me(t,n,dr(405,{method:h.formMethod,pathname:i,routeId:n}),{flushSync:p});return}ae.set(t,_);let b=A,x=qn(a,o,v,i,u,y,r,d),S=await Oe(v,i,x,d,t),C=S[y.route.id];if(!C){for(let e of x)if(S[e.route.id]){C=S[e.route.id];break}}if(v.signal.aborted){ae.get(t)===_&&ae.delete(t);return}if(M.has(t)){if(br(C)||yr(C)){je(t,Pr(void 0));return}}else{if(br(C))if(ae.delete(t),j>b){je(t,Pr(void 0));return}else return se.add(t),je(t,Mr(h)),De(v,C,!1,{fetcherSubmission:h,preventScrollReset:m});if(yr(C)){Me(t,n,C.error);return}}let E=w.navigation.location||w.location,D=tr(e.history,E,_.signal),ee=c||s,te=w.navigation.state===`idle`?w.matches:mt(ee,w.navigation.location,l);F(te,`Didn't find any matches after fetcher action`);let ne=++A;oe.set(t,ne);let re=Mr(h,C.data);w.fetchers.set(t,re);let{dsMatches:le,revalidatingFetchers:N}=On(D,d,a,o,e.history,w,te,h,E,r,!1,ie,k,M,ce,se,ee,l,e.patchRoutesOnNavigation!=null,[y.route.id,C],g);N.filter(e=>e.key!==t).forEach(e=>{let t=e.key,n=w.fetchers.get(t),r=Mr(void 0,n?n.data:void 0);w.fetchers.set(t,r),Le(t),e.controller&&ae.set(t,e.controller)}),he({fetchers:new Map(w.fetchers)});let ue=()=>N.forEach(e=>Le(e.key));_.signal.addEventListener(`abort`,ue);let{loaderResults:de,fetcherResults:fe}=await ke(le,N,D,E,d);if(_.signal.aborted)return;if(_.signal.removeEventListener(`abort`,ue),oe.delete(t),ae.delete(t),N.forEach(e=>ae.delete(e.key)),w.fetchers.has(t)){let e=Pr(C.data);w.fetchers.set(t,e)}let pe=fr(de);if(pe)return De(D,pe.result,!1,{preventScrollReset:m});if(pe=fr(fe),pe)return se.add(pe.key),De(D,pe.result,!1,{preventScrollReset:m});let{loaderData:me,errors:_e}=or(w,te,de,void 0,N,fe);P(ne),w.navigation.state===`loading`&&ne>j?(F(T,`Expected pending action`),O&&O.abort(),ge(w.navigation.location,{matches:te,loaderData:me,errors:_e,fetchers:new Map(w.fetchers)})):(he({errors:_e,loaderData:sr(w.loaderData,me,te,_e),fetchers:new Map(w.fetchers)}),ie=!1)}async function Ee(t,n,i,s,c,l,u,d,f){let p=w.fetchers.get(t);je(t,Mr(f,p?p.data:void 0),{flushSync:u});let m=new AbortController,h=tr(e.history,i,m.signal);if(l){let e=await Xe(s,new URL(h.url).pathname,h.signal,t);if(e.type===`aborted`)return;if(e.type===`error`){Me(t,n,e.error,{flushSync:u});return}else if(e.matches)s=e.matches;else{Me(t,n,dr(404,{pathname:i}),{flushSync:u});return}}let g=Or(s,i);ae.set(t,m);let _=A,v=(await Oe(h,i,qn(a,o,h,i,s,g,r,c),c,t))[g.route.id];if(ae.get(t)===m&&ae.delete(t),!h.signal.aborted){if(M.has(t)){je(t,Pr(void 0));return}if(br(v))if(j>_){je(t,Pr(void 0));return}else{se.add(t),await De(h,v,!1,{preventScrollReset:d});return}if(yr(v)){Me(t,n,v.error);return}je(t,Pr(v.data))}}async function De(r,i,a,{submission:o,fetcherSubmission:s,preventScrollReset:c,replace:u}={}){a||(E?.resolve(),E=null),i.response.headers.has(`X-Remix-Revalidate`)&&(ie=!0);let d=i.response.headers.get(`Location`);F(d,`Expected a Location header on the redirect Response`),d=er(d,new URL(r.url),l,e.history);let f=et(w.location,d,{_isRedirect:!0});if(n){let e=!1;if(i.response.headers.has(`X-Remix-Reload-Document`))e=!0;else if(It(d)){let n=it(d,!0);e=n.origin!==t.location.origin||Nt(n.pathname,l)==null}if(e){u?t.location.replace(d):t.location.assign(d);return}}O=null;let p=u===!0||i.response.headers.has(`X-Remix-Replace`)?`REPLACE`:`PUSH`,{formMethod:m,formAction:h,formEncType:g}=w.navigation;!o&&!s&&m&&h&&g&&(o=kr(w.navigation));let _=o||s;_n.has(i.response.status)&&_&&Er(_.formMethod)?await ye(p,f,{submission:{..._,formAction:d},preventScrollReset:c||D,enableViewTransition:a?ee:void 0}):await ye(p,f,{overrideNavigation:Ar(f,o),fetcherSubmission:s,preventScrollReset:c||D,enableViewTransition:a?ee:void 0})}async function Oe(e,t,n,r,i){let a,o={};try{a=await Jn(u,e,t,n,i,r,!1)}catch(e){return n.filter(e=>e.shouldLoad).forEach(t=>{o[t.route.id]={type:`error`,error:e}}),o}if(e.signal.aborted)return o;if(!Er(e.method))for(let e of n){if(a[e.route.id]?.type===`error`)break;!a.hasOwnProperty(e.route.id)&&!w.loaderData.hasOwnProperty(e.route.id)&&(!w.errors||!w.errors.hasOwnProperty(e.route.id))&&e.shouldCallHandler()&&(a[e.route.id]={type:`error`,result:Error(`No result returned from dataStrategy for route ${e.route.id}`)})}for(let[t,r]of Object.entries(a))if(vr(r)){let i=r.result;o[t]={type:`redirect`,response:Qn(i,e,t,n,l)}}else o[t]=await Zn(r);return o}async function ke(e,t,n,r,i){let a=Oe(n,r,e,i,null),o=Promise.all(t.map(async e=>{if(e.matches&&e.match&&e.request&&e.controller){let t=(await Oe(e.request,e.path,e.matches,i,e.key))[e.match.route.id];return{[e.key]:t}}else return Promise.resolve({[e.key]:{type:`error`,error:dr(404,{pathname:e.path})}})}));return{loaderResults:await a,fetcherResults:(await o).reduce((e,t)=>Object.assign(e,t),{})}}function Ae(){ie=!0,ce.forEach((e,t)=>{ae.has(t)&&k.add(t),Le(t)})}function je(e,t,n={}){w.fetchers.set(e,t),he({fetchers:new Map(w.fetchers)},{flushSync:(n&&n.flushSync)===!0})}function Me(e,t,n,r={}){let i=lr(w.matches,t);Fe(e),he({errors:{[i.route.id]:n},fetchers:new Map(w.fetchers)},{flushSync:(r&&r.flushSync)===!0})}function Ne(e){return le.set(e,(le.get(e)||0)+1),M.has(e)&&M.delete(e),w.fetchers.get(e)||yn}function Pe(e,t){Le(e,t?.reason),je(e,Pr(null))}function Fe(e){let t=w.fetchers.get(e);ae.has(e)&&!(t&&t.state===`loading`&&oe.has(e))&&Le(e),ce.delete(e),oe.delete(e),se.delete(e),M.delete(e),k.delete(e),w.fetchers.delete(e)}function Ie(e){let t=(le.get(e)||0)-1;t<=0?(le.delete(e),M.add(e)):le.set(e,t),he({fetchers:new Map(w.fetchers)})}function Le(e,t){let n=ae.get(e);n&&(n.abort(t),ae.delete(e))}function Re(e){for(let t of e){let e=Pr(Ne(t).data);w.fetchers.set(t,e)}}function ze(){let e=[],t=!1;for(let n of se){let r=w.fetchers.get(n);F(r,`Expected fetcher: ${n}`),r.state===`loading`&&(se.delete(n),e.push(n),t=!0)}return Re(e),t}function P(e){let t=[];for(let[n,r]of oe)if(r<e){let e=w.fetchers.get(n);F(e,`Expected fetcher: ${n}`),e.state===`loading`&&(Le(n),oe.delete(n),t.push(n))}return Re(t),t.length>0}function Be(e,t){let n=w.blockers.get(e)||bn;return N.get(e)!==t&&N.set(e,t),n}function Ve(e){w.blockers.delete(e),N.delete(e)}function He(e,t){let n=w.blockers.get(e)||bn;F(n.state===`unblocked`&&t.state===`blocked`||n.state===`blocked`&&t.state===`blocked`||n.state===`blocked`&&t.state===`proceeding`||n.state===`blocked`&&t.state===`unblocked`||n.state===`proceeding`&&t.state===`unblocked`,`Invalid blocker state transition: ${n.state} -> ${t.state}`);let r=new Map(w.blockers);r.set(e,t),he({blockers:r})}function Ue({currentLocation:e,nextLocation:t,historyAction:n}){if(N.size===0)return;N.size>1&&Ze(!1,`A router only supports one blocker at a time`);let r=Array.from(N.entries()),[i,a]=r[r.length-1],o=w.blockers.get(i);if(!(o&&o.state===`proceeding`)&&a({currentLocation:e,nextLocation:t,historyAction:n}))return i}function We(e){let t=dr(404,{pathname:e}),{matches:n,route:r}=ur(c||s);return{notFoundMatches:n,route:r,error:t}}function Ge(e,t,n){if(m=e,g=t,h=n||null,!_&&w.navigation===vn){_=!0;let e=Je(w.location,w.matches);e!=null&&he({restoreScrollPosition:e})}return()=>{m=null,g=null,h=null}}function Ke(e,t){return h&&h(e,t.map(e=>gt(e,w.loaderData)))||e.key}function qe(e,t){if(m&&g){let n=Ke(e,t);m[n]=g()}}function Je(e,t){if(m){let n=Ke(e,t),r=m[n];if(typeof r==`number`)return r}return null}function Ye(t,n,r){if(e.patchRoutesOnNavigation){if(!t)return{active:!0,matches:ht(n,r,l,!0)||[]};if(Object.keys(t[0].params).length>0)return{active:!0,matches:ht(n,r,l,!0)}}return{active:!1,matches:null}}async function Xe(t,n,r,i){if(!e.patchRoutesOnNavigation)return{type:`success`,matches:t};let u=t;for(;;){let t=c==null,d=c||s,f=o;try{await e.patchRoutesOnNavigation({signal:r,path:n,matches:u,fetcherKey:i,patch:(e,t)=>{r.aborted||Pn(e,t,d,f,a,!1)}})}catch(e){return{type:`error`,error:e,partialMatches:u}}finally{t&&!r.aborted&&(s=[...s])}if(r.aborted)return{type:`aborted`};let p=mt(d,n,l),m=null;if(p&&(Object.keys(p[0].params).length===0||(m=ht(d,n,l,!0),!(m&&u.length<m.length&&Qe(u,m.slice(0,u.length))))))return{type:`success`,matches:p};if(m||=ht(d,n,l,!0),!m||Qe(u,m))return{type:`success`,matches:null};u=m}}function Qe(e,t){return e.length===t.length&&e.every((e,n)=>e.route.id===t[n].route.id)}function $e(e){o={},c=ft(e,a,void 0,o)}function tt(e,t,n=!1){let r=c==null;Pn(e,t,c||s,o,a,n),r&&(s=[...s],he({}))}return C={get basename(){return l},get future(){return d},get state(){return w},get routes(){return s},get window(){return t},initialize:fe,subscribe:me,enableScrollRestoration:Ge,navigate:_e,fetch:we,revalidate:ve,createHref:t=>e.history.createHref(t),encodeLocation:t=>e.history.encodeLocation(t),getFetcher:Ne,resetFetcher:Pe,deleteFetcher:Ie,dispose:pe,getBlocker:Be,deleteBlocker:Ve,patchRoutes:tt,_internalFetchControllers:ae,_internalSetRoutes:$e,_internalSetStateDoNotUseOrYouWillBreakYourApp(e){he(e)}},e.unstable_instrumentations&&(C=nn(C,e.unstable_instrumentations.map(e=>e.router).filter(Boolean))),C}function Tn(e){return e!=null&&(`formData`in e&&e.formData!=null||`body`in e&&e.body!==void 0)}function En(e,t,n,r,i,a){let o,s;if(i){o=[];for(let e of t)if(o.push(e),e.route.id===i){s=e;break}}else o=t,s=t[t.length-1];let c=Ht(r||`.`,Vt(o),Nt(e.pathname,n)||e.pathname,a===`path`);if(r??(c.search=e.search,c.hash=e.hash),(r==null||r===``||r===`.`)&&s){let e=Dr(c.search);if(s.route.index&&!e)c.search=c.search?c.search.replace(/^\?/,`?index&`):`?index`;else if(!s.route.index&&e){let e=new URLSearchParams(c.search),t=e.getAll(`index`);e.delete(`index`),t.filter(e=>e).forEach(t=>e.append(`index`,t));let n=e.toString();c.search=n?`?${n}`:``}}return n!==`/`&&(c.pathname=Pt({basename:n,pathname:c.pathname})),tt(c)}function Dn(e,t,n){if(!n||!Tn(n))return{path:t};if(n.formMethod&&!Tr(n.formMethod))return{path:t,error:dr(405,{method:n.formMethod})};let r=()=>({path:t,error:dr(400,{type:`invalid-body`})}),i=(n.formMethod||`get`).toUpperCase(),a=pr(t);if(n.body!==void 0){if(n.formEncType===`text/plain`){if(!Er(i))return r();let e=typeof n.body==`string`?n.body:n.body instanceof FormData||n.body instanceof URLSearchParams?Array.from(n.body.entries()).reduce((e,[t,n])=>`${e}${t}=${n}
`,``):String(n.body);return{path:t,submission:{formMethod:i,formAction:a,formEncType:n.formEncType,formData:void 0,json:void 0,text:e}}}else if(n.formEncType===`application/json`){if(!Er(i))return r();try{let e=typeof n.body==`string`?JSON.parse(n.body):n.body;return{path:t,submission:{formMethod:i,formAction:a,formEncType:n.formEncType,formData:void 0,json:e,text:void 0}}}catch{return r()}}}F(typeof FormData==`function`,`FormData is not available in this environment`);let o,s;if(n.formData)o=rr(n.formData),s=n.formData;else if(n.body instanceof FormData)o=rr(n.body),s=n.body;else if(n.body instanceof URLSearchParams)o=n.body,s=ir(o);else if(n.body==null)o=new URLSearchParams,s=new FormData;else try{o=new URLSearchParams(n.body),s=ir(o)}catch{return r()}let c={formMethod:i,formAction:a,formEncType:n&&n.formEncType||`application/x-www-form-urlencoded`,formData:s,json:void 0,text:void 0};if(Er(c.formMethod))return{path:t,submission:c};let l=nt(t);return e&&l.search&&Dr(l.search)&&o.append(`index`,``),l.search=`?${o}`,{path:tt(l),submission:c}}function On(e,t,n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b){let x=y?yr(y[1])?y[1].error:y[1].data:void 0,S=i.createURL(a.location),C=i.createURL(c),w;if(u&&a.errors){let e=Object.keys(a.errors)[0];w=o.findIndex(t=>t.route.id===e)}else if(y&&yr(y[1])){let e=y[0];w=o.findIndex(t=>t.route.id===e)-1}let T=y?y[1].statusCode:void 0,E=T&&T>=400,D={currentUrl:S,currentParams:a.matches[0]?.params||{},nextUrl:C,nextParams:o[0].params,...s,actionResult:x,actionStatus:T},O=Zt(o),ee=o.map((i,o)=>{let{route:s}=i,f=null;if(w!=null&&o>w)f=!1;else if(s.lazy)f=!0;else if(!kn(s))f=!1;else if(u){let{shouldLoad:e}=An(s,a.loaderData,a.errors);f=e}else jn(a.loaderData,a.matches[o],i)&&(f=!0);if(f!==null)return Kn(n,r,e,c,O,i,l,t,f);let p=!1;typeof b==`boolean`?p=b:E?p=!1:d||S.pathname+S.search===C.pathname+C.search?p=!0:S.search===C.search?Mn(a.matches[o],i)&&(p=!0):p=!0;let m={...D,defaultShouldRevalidate:p};return Kn(n,r,e,c,O,i,l,t,Nn(i,m),m,b)}),te=[];return m.forEach((e,s)=>{if(u||!o.some(t=>t.route.id===e.routeId)||p.has(s))return;let c=a.fetchers.get(s),m=c&&c.state!==`idle`&&c.data===void 0,y=mt(g,e.path,_);if(!y){if(v&&m)return;te.push({key:s,routeId:e.routeId,path:e.path,matches:null,match:null,request:null,controller:null});return}if(h.has(s))return;let x=Or(y,e.path),S=new AbortController,C=tr(i,e.path,S.signal),w=null;if(f.has(s))f.delete(s),w=qn(n,r,C,e.path,y,x,l,t);else if(m)d&&(w=qn(n,r,C,e.path,y,x,l,t));else{let i;i=typeof b==`boolean`?b:E?!1:d;let a={...D,defaultShouldRevalidate:i};Nn(x,a)&&(w=qn(n,r,C,e.path,y,x,l,t,a))}w&&te.push({key:s,routeId:e.routeId,path:e.path,matches:w,match:x,request:C,controller:S})}),{dsMatches:ee,revalidatingFetchers:te}}function kn(e){return e.loader!=null||e.middleware!=null&&e.middleware.length>0}function An(e,t,n){if(e.lazy)return{shouldLoad:!0,renderFallback:!0};if(!kn(e))return{shouldLoad:!1,renderFallback:!1};let r=t!=null&&e.id in t,i=n!=null&&n[e.id]!==void 0;if(!r&&i)return{shouldLoad:!1,renderFallback:!1};if(typeof e.loader==`function`&&e.loader.hydrate===!0)return{shouldLoad:!0,renderFallback:!r};let a=!r&&!i;return{shouldLoad:a,renderFallback:a}}function jn(e,t,n){let r=!t||n.route.id!==t.route.id,i=!e.hasOwnProperty(n.route.id);return r||i}function Mn(e,t){let n=e.route.path;return e.pathname!==t.pathname||n!=null&&n.endsWith(`*`)&&e.params[`*`]!==t.params[`*`]}function Nn(e,t){if(e.route.shouldRevalidate){let n=e.route.shouldRevalidate(t);if(typeof n==`boolean`)return n}return t.defaultShouldRevalidate}function Pn(e,t,n,r,i,a){let o;if(e){let t=r[e];F(t,`No route found to patch children into: routeId = ${e}`),t.children||=[],o=t.children}else o=n;let s=[],c=[];if(t.forEach(e=>{let t=o.find(t=>Fn(e,t));t?c.push({existingRoute:t,newRoute:e}):s.push(e)}),s.length>0){let t=ft(s,i,[e||`_`,`patch`,String(o?.length||`0`)],r);o.push(...t)}if(a&&c.length>0)for(let e=0;e<c.length;e++){let{existingRoute:t,newRoute:n}=c[e],r=t,[a]=ft([n],i,[],{},!0);Object.assign(r,{element:a.element?a.element:r.element,errorElement:a.errorElement?a.errorElement:r.errorElement,hydrateFallbackElement:a.hydrateFallbackElement?a.hydrateFallbackElement:r.hydrateFallbackElement})}}function Fn(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((e,n)=>t.children?.some(t=>Fn(e,t)))??!1:!1}var In=new WeakMap,Ln=({key:e,route:t,manifest:n,mapRouteProperties:r})=>{let i=n[t.id];if(F(i,`No route found in manifest`),!i.lazy||typeof i.lazy!=`object`)return;let a=i.lazy[e];if(!a)return;let o=In.get(i);o||(o={},In.set(i,o));let s=o[e];if(s)return s;let c=(async()=>{let t=ct(e),n=i[e]!==void 0&&e!==`hasErrorBoundary`;if(t)Ze(!t,`Route property `+e+` is not a supported lazy route property. This property will be ignored.`),o[e]=Promise.resolve();else if(n)Ze(!1,`Route "${i.id}" has a static property "${e}" defined. The lazy property will be ignored.`);else{let t=await a();t!=null&&(Object.assign(i,{[e]:t}),Object.assign(i,r(i)))}typeof i.lazy==`object`&&(i.lazy[e]=void 0,Object.values(i.lazy).every(e=>e===void 0)&&(i.lazy=void 0))})();return o[e]=c,c},Rn=new WeakMap;function zn(e,t,n,r,i){let a=n[e.id];if(F(a,`No route found in manifest`),!e.lazy)return{lazyRoutePromise:void 0,lazyHandlerPromise:void 0};if(typeof e.lazy==`function`){let t=Rn.get(a);if(t)return{lazyRoutePromise:t,lazyHandlerPromise:t};let n=(async()=>{F(typeof e.lazy==`function`,`No lazy route function found`);let t=await e.lazy(),n={};for(let e in t){let r=t[e];if(r===void 0)continue;let i=ut(e),o=a[e]!==void 0&&e!==`hasErrorBoundary`;i?Ze(!i,`Route property `+e+` is not a supported property to be returned from a lazy route function. This property will be ignored.`):o?Ze(!o,`Route "${a.id}" has a static property "${e}" defined but its lazy function is also returning a value for this property. The lazy route property "${e}" will be ignored.`):n[e]=r}Object.assign(a,n),Object.assign(a,{...r(a),lazy:void 0})})();return Rn.set(a,n),n.catch(()=>{}),{lazyRoutePromise:n,lazyHandlerPromise:n}}let o=Object.keys(e.lazy),s=[],c;for(let a of o){if(i&&i.includes(a))continue;let o=Ln({key:a,route:e,manifest:n,mapRouteProperties:r});o&&(s.push(o),a===t&&(c=o))}let l=s.length>0?Promise.all(s).then(()=>{}):void 0;return l?.catch(()=>{}),c?.catch(()=>{}),{lazyRoutePromise:l,lazyHandlerPromise:c}}async function Bn(e){let t=e.matches.filter(e=>e.shouldLoad),n={};return(await Promise.all(t.map(e=>e.resolve()))).forEach((e,r)=>{n[t[r].route.id]=e}),n}async function Vn(e){return e.matches.some(e=>e.route.middleware)?Hn(e,()=>Bn(e)):Bn(e)}function Hn(e,t){return Un(e,t,e=>{if(wr(e))throw e;return e},gr,n);function n(t,n,r){if(r)return Promise.resolve(Object.assign(r.value,{[n]:{type:`error`,result:t}}));{let{matches:r}=e,i=lr(r,r[Math.min(Math.max(r.findIndex(e=>e.route.id===n),0),Math.max(r.findIndex(e=>e.shouldCallHandler()),0))].route.id).route.id;return Promise.resolve({[i]:{type:`error`,result:t}})}}}async function Un(e,t,n,r,i){let{matches:a,...o}=e;return await Wn(o,a.flatMap(e=>e.route.middleware?e.route.middleware.map(t=>[e.route.id,t]):[]),t,n,r,i)}async function Wn(e,t,n,r,i,a,o=0){let{request:s}=e;if(s.signal.aborted)throw s.signal.reason??Error(`Request aborted: ${s.method} ${s.url}`);let c=t[o];if(!c)return await n();let[l,u]=c,d,f=async()=>{if(d)throw Error("You may only call `next()` once per middleware");try{return d={value:await Wn(e,t,n,r,i,a,o+1)},d.value}catch(e){return d={value:await a(e,l,d)},d.value}};try{let t=await u(e,f),n=t==null?void 0:r(t);return i(n)?n:d?n??d.value:(d={value:await f()},d.value)}catch(e){return await a(e,l,d)}}function Gn(e,t,n,r,i){let a=Ln({key:`middleware`,route:r.route,manifest:t,mapRouteProperties:e}),o=zn(r.route,Er(n.method)?`action`:`loader`,t,e,i);return{middleware:a,route:o.lazyRoutePromise,handler:o.lazyHandlerPromise}}function Kn(e,t,n,r,i,a,o,s,c,l=null,u){let d=!1,f=Gn(e,t,n,a,o);return{...a,_lazyPromises:f,shouldLoad:c,shouldRevalidateArgs:l,shouldCallHandler(e){return d=!0,l?typeof u==`boolean`?Nn(a,{...l,defaultShouldRevalidate:u}):typeof e==`boolean`?Nn(a,{...l,defaultShouldRevalidate:e}):Nn(a,l):c},resolve(e){let{lazy:t,loader:o,middleware:l}=a.route,u=d||c||e&&!Er(n.method)&&(t||o),p=l&&l.length>0&&!o&&!t;return u&&(Er(n.method)||!p)?Yn({request:n,path:r,unstable_pattern:i,match:a,lazyHandlerPromise:f?.handler,lazyRoutePromise:f?.route,handlerOverride:e,scopedContext:s}):Promise.resolve({type:`data`,result:void 0})}}}function qn(e,t,n,r,i,a,o,s,c=null){return i.map(l=>l.route.id===a.route.id?Kn(e,t,n,r,Zt(i),l,o,s,!0,c):{...l,shouldLoad:!1,shouldRevalidateArgs:c,shouldCallHandler:()=>!1,_lazyPromises:Gn(e,t,n,l,o),resolve:()=>Promise.resolve({type:`data`,result:void 0})})}async function Jn(e,t,n,r,i,a,o){r.some(e=>e._lazyPromises?.middleware)&&await Promise.all(r.map(e=>e._lazyPromises?.middleware));let s={request:t,unstable_url:nr(t,n),unstable_pattern:Zt(r),params:r[0].params,context:a,matches:r},c=o?()=>{throw 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`")}:e=>{let t=s;return Hn(t,()=>e({...t,fetcherKey:i,runClientMiddleware:()=>{throw Error("Cannot call `runClientMiddleware()` from within an `runClientMiddleware` handler")}}))},l=await e({...s,fetcherKey:i,runClientMiddleware:c});try{await Promise.all(r.flatMap(e=>[e._lazyPromises?.handler,e._lazyPromises?.route]))}catch{}return l}async function Yn({request:e,path:t,unstable_pattern:n,match:r,lazyHandlerPromise:i,lazyRoutePromise:a,handlerOverride:o,scopedContext:s}){let c,l,u=Er(e.method),d=u?`action`:`loader`,f=i=>{let a,c=new Promise((e,t)=>a=t);l=()=>a(),e.signal.addEventListener(`abort`,l);let u=a=>typeof i==`function`?i({request:e,unstable_url:nr(e,t),unstable_pattern:n,params:r.params,context:s},...a===void 0?[]:[a]):Promise.reject(Error(`You cannot call the handler for a route which defines a boolean "${d}" [routeId: ${r.route.id}]`)),f=(async()=>{try{return{type:`data`,result:await(o?o(e=>u(e)):u())}}catch(e){return{type:`error`,result:e}}})();return Promise.race([f,c])};try{let t=u?r.route.action:r.route.loader;if(i||a)if(t){let e,[n]=await Promise.all([f(t).catch(t=>{e=t}),i,a]);if(e!==void 0)throw e;c=n}else{await i;let t=u?r.route.action:r.route.loader;if(t)[c]=await Promise.all([f(t),a]);else if(d===`action`){let t=new URL(e.url),n=t.pathname+t.search;throw dr(405,{method:e.method,pathname:n,routeId:r.route.id})}else return{type:`data`,result:void 0}}else if(t)c=await f(t);else{let t=new URL(e.url);throw dr(404,{pathname:t.pathname+t.search})}}catch(e){return{type:`error`,result:e}}finally{l&&e.signal.removeEventListener(`abort`,l)}return c}async function Xn(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 Zn(e){let{result:t,type:n}=e;if(Sr(t)){let e;try{e=await Xn(t)}catch(e){return{type:`error`,error:e}}return n===`error`?{type:`error`,error:new Yt(t.status,t.statusText,e),statusCode:t.status,headers:t.headers}:{type:`data`,data:e,statusCode:t.status,headers:t.headers}}return n===`error`?xr(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:hr(t),statusCode:Xt(t)?t.status:void 0,headers:t.init?.headers?new Headers(t.init.headers):void 0}:{type:`error`,error:t,statusCode:Xt(t)?t.status:void 0}:xr(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 Qn(e,t,n,r,i){let a=e.headers.get(`Location`);if(F(a,`Redirects returned/thrown from loaders/actions must have a Location header`),!It(a)){let o=r.slice(0,r.findIndex(e=>e.route.id===n)+1);a=En(new URL(t.url),o,i,a),e.headers.set(`Location`,a)}return e}var $n=[`about:`,`blob:`,`chrome:`,`chrome-untrusted:`,`content:`,`data:`,`devtools:`,`file:`,`filesystem:`,`javascript:`];function er(e,t,n,r){if(It(e)){let r=e,i=r.startsWith(`//`)?new URL(t.protocol+r):new URL(r);if($n.includes(i.protocol))throw Error(`Invalid redirect location`);let a=Nt(i.pathname,n)!=null;if(i.origin===t.origin&&a)return Ut(i.pathname)+i.search+i.hash}try{let t=r.createURL(e);if($n.includes(t.protocol))throw Error(`Invalid redirect location`)}catch{}return e}function tr(e,t,n,r){let i=e.createURL(pr(t)).toString(),a={signal:n};if(r&&Er(r.formMethod)){let{formMethod:e,formEncType:t}=r;a.method=e.toUpperCase(),t===`application/json`?(a.headers=new Headers({"Content-Type":t}),a.body=JSON.stringify(r.json)):t===`text/plain`?a.body=r.text:t===`application/x-www-form-urlencoded`&&r.formData?a.body=rr(r.formData):a.body=r.formData}return new Request(i,a)}function nr(e,t){let n=new URL(e.url),r=typeof t==`string`?nt(t):t;if(n.pathname=r.pathname||`/`,r.search){let e=new URLSearchParams(r.search),t=e.getAll(`index`);e.delete(`index`);for(let n of t.filter(Boolean))e.append(`index`,n);n.search=e.size?`?${e.toString()}`:``}else n.search=``;return n.hash=r.hash||``,n}function rr(e){let t=new URLSearchParams;for(let[n,r]of e.entries())t.append(n,typeof r==`string`?r:r.name);return t}function ir(e){let t=new FormData;for(let[n,r]of e.entries())t.append(n,r);return t}function ar(e,t,n,r=!1,i=!1){let a={},o=null,s,c=!1,l={},u=n&&yr(n[1])?n[1].error:void 0;return e.forEach(n=>{if(!(n.route.id in t))return;let d=n.route.id,f=t[d];if(F(!br(f),`Cannot handle redirect results in processLoaderData`),yr(f)){let t=f.error;if(u!==void 0&&(t=u,u=void 0),o||={},i)o[d]=t;else{let n=lr(e,d);o[n.route.id]??(o[n.route.id]=t)}r||(a[d]=Cn),c||(c=!0,s=Xt(f.error)?f.error.status:500),f.headers&&(l[d]=f.headers)}else a[d]=f.data,f.statusCode&&f.statusCode!==200&&!c&&(s=f.statusCode),f.headers&&(l[d]=f.headers)}),u!==void 0&&n&&(o={[n[0]]:u},n[2]&&(a[n[2]]=void 0)),{loaderData:a,errors:o,statusCode:s||200,loaderHeaders:l}}function or(e,t,n,r,i,a){let{loaderData:o,errors:s}=ar(t,n,r);return i.filter(e=>!e.matches||e.matches.some(e=>e.shouldLoad)).forEach(t=>{let{key:n,match:r,controller:i}=t;if(i&&i.signal.aborted)return;let o=a[n];if(F(o,`Did not find corresponding fetcher result`),yr(o)){let t=lr(e.matches,r?.route.id);s&&s[t.route.id]||(s={...s,[t.route.id]:o.error}),e.fetchers.delete(n)}else if(br(o))F(!1,`Unhandled fetcher revalidation redirect`);else{let t=Pr(o.data);e.fetchers.set(n,t)}}),{loaderData:o,errors:s}}function sr(e,t,n,r){let i=Object.entries(t).filter(([,e])=>e!==Cn).reduce((e,[t,n])=>(e[t]=n,e),{});for(let a of n){let n=a.route.id;if(!t.hasOwnProperty(n)&&e.hasOwnProperty(n)&&a.route.loader&&(i[n]=e[n]),r&&r.hasOwnProperty(n))break}return i}function cr(e){return e?yr(e[1])?{actionData:{}}:{actionData:{[e[0]]:e[1].data}}:{}}function lr(e,t){return(t?e.slice(0,e.findIndex(e=>e.route.id===t)+1):[...e]).reverse().find(e=>e.route.hasErrorBoundary===!0)||e[0]}function ur(e){let t=e.length===1?e[0]:e.find(e=>e.index||!e.path||e.path===`/`)||{id:`__shim-error-route__`};return{matches:[{params:{},pathname:``,pathnameBase:``,route:t}],route:t}}function dr(e,{pathname:t,routeId:n,method:r,type:i,message:a}={}){let o=`Unknown Server Error`,s=`Unknown @remix-run/router error`;return e===400?(o=`Bad Request`,r&&t&&n?s=`You made a ${r} request to "${t}" but did not provide a \`loader\` for route "${n}", so there is no way to handle the request.`:i===`invalid-body`&&(s=`Unable to encode submission body`)):e===403?(o=`Forbidden`,s=`Route "${n}" does not match URL "${t}"`):e===404?(o=`Not Found`,s=`No route matches URL "${t}"`):e===405&&(o=`Method Not Allowed`,r&&t&&n?s=`You made a ${r.toUpperCase()} request to "${t}" but did not provide an \`action\` for route "${n}", so there is no way to handle the request.`:r&&(s=`Invalid request method "${r.toUpperCase()}"`)),new Yt(e||500,o,Error(s),!0)}function fr(e){let t=Object.entries(e);for(let e=t.length-1;e>=0;e--){let[n,r]=t[e];if(br(r))return{key:n,result:r}}}function pr(e){return tt({...typeof e==`string`?nt(e):e,hash:``})}function mr(e,t){return e.pathname!==t.pathname||e.search!==t.search?!1:e.hash===``?t.hash!==``:e.hash===t.hash?!0:t.hash!==``}function hr(e){return new Yt(e.init?.status??500,e.init?.statusText??`Internal Server Error`,e.data)}function gr(e){return typeof e==`object`&&!!e&&Object.entries(e).every(([e,t])=>typeof e==`string`&&_r(t))}function _r(e){return typeof e==`object`&&!!e&&`type`in e&&`result`in e&&(e.type===`data`||e.type===`error`)}function vr(e){return Sr(e.result)&&gn.has(e.result.status)}function yr(e){return e.type===`error`}function br(e){return(e&&e.type)===`redirect`}function xr(e){return typeof e==`object`&&!!e&&`type`in e&&`data`in e&&`init`in e&&e.type===`DataWithResponseInit`}function Sr(e){return e!=null&&typeof e.status==`number`&&typeof e.statusText==`string`&&typeof e.headers==`object`&&e.body!==void 0}function Cr(e){return gn.has(e)}function wr(e){return Sr(e)&&Cr(e.status)&&e.headers.has(`Location`)}function Tr(e){return hn.has(e.toUpperCase())}function Er(e){return pn.has(e.toUpperCase())}function Dr(e){return new URLSearchParams(e).getAll(`index`).some(e=>e===``)}function Or(e,t){let n=typeof t==`string`?nt(t).search:t.search;if(e[e.length-1].route.index&&Dr(n||``))return e[e.length-1];let r=Bt(e);return r[r.length-1]}function kr(e){let{formMethod:t,formAction:n,formEncType:r,text:i,formData:a,json:o}=e;if(!(!t||!n||!r)){if(i!=null)return{formMethod:t,formAction:n,formEncType:r,formData:void 0,json:void 0,text:i};if(a!=null)return{formMethod:t,formAction:n,formEncType:r,formData:a,json:void 0,text:void 0};if(o!==void 0)return{formMethod:t,formAction:n,formEncType:r,formData:void 0,json:o,text:void 0}}}function Ar(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 jr(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 Mr(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 Nr(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 Pr(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 Fr(e,t){try{let n=e.sessionStorage.getItem(Sn);if(n){let e=JSON.parse(n);for(let[n,r]of Object.entries(e||{}))r&&Array.isArray(r)&&t.set(n,new Set(r||[]))}}catch{}}function Ir(e,t){if(t.size>0){let n={};for(let[e,r]of t)n[e]=[...r];try{e.sessionStorage.setItem(Sn,JSON.stringify(n))}catch(e){Ze(!1,`Failed to save applied view transitions in sessionStorage (${e}).`)}}}function Lr(){let e,t,n=new Promise((r,i)=>{e=async e=>{r(e);try{await n}catch{}},t=async e=>{i(e);try{await n}catch{}}});return{promise:n,resolve:e,reject:t}}var Rr=g.createContext(null);Rr.displayName=`DataRouter`;var zr=g.createContext(null);zr.displayName=`DataRouterState`;var Br=g.createContext(!1);function Vr(){return g.useContext(Br)}var Hr=g.createContext({isTransitioning:!1});Hr.displayName=`ViewTransition`;var Ur=g.createContext(new Map);Ur.displayName=`Fetchers`;var Wr=g.createContext(null);Wr.displayName=`Await`;var Gr=g.createContext(null);Gr.displayName=`Navigation`;var Kr=g.createContext(null);Kr.displayName=`Location`;var qr=g.createContext({outlet:null,matches:[],isDataRoute:!1});qr.displayName=`Route`;var Jr=g.createContext(null);Jr.displayName=`RouteError`;var Yr=`REACT_ROUTER_ERROR`,Xr=`REDIRECT`,Zr=`ROUTE_ERROR_RESPONSE`;function Qr(e){if(e.startsWith(`${Yr}:${Xr}:{`))try{let t=JSON.parse(e.slice(28));if(typeof t==`object`&&t&&typeof t.status==`number`&&typeof t.statusText==`string`&&typeof t.location==`string`&&typeof t.reloadDocument==`boolean`&&typeof t.replace==`boolean`)return t}catch{}}function $r(e){if(e.startsWith(`${Yr}:${Zr}:{`))try{let t=JSON.parse(e.slice(40));if(typeof t==`object`&&t&&typeof t.status==`number`&&typeof t.statusText==`string`)return new Yt(t.status,t.statusText,t.data)}catch{}}function ei(e,{relative:t}={}){F(ti(),`useHref() may be used only in the context of a <Router> component.`);let{basename:n,navigator:r}=g.useContext(Gr),{hash:i,pathname:a,search:o}=ui(e,{relative:t}),s=a;return n!==`/`&&(s=a===`/`?n:Wt([n,a])),r.createHref({pathname:s,search:o,hash:i})}function ti(){return g.useContext(Kr)!=null}function ni(){return F(ti(),`useLocation() may be used only in the context of a <Router> component.`),g.useContext(Kr).location}var ri=`You should call navigate() in a React.useEffect(), not when your component is first rendered.`;function ii(e){g.useContext(Gr).static||g.useLayoutEffect(e)}function ai(){let{isDataRoute:e}=g.useContext(qr);return e?Oi():oi()}function oi(){F(ti(),`useNavigate() may be used only in the context of a <Router> component.`);let e=g.useContext(Rr),{basename:t,navigator:n}=g.useContext(Gr),{matches:r}=g.useContext(qr),{pathname:i}=ni(),a=JSON.stringify(Vt(r)),o=g.useRef(!1);return ii(()=>{o.current=!0}),g.useCallback((r,s={})=>{if(Ze(o.current,ri),!o.current)return;if(typeof r==`number`){n.go(r);return}let c=Ht(r,JSON.parse(a),i,s.relative===`path`);e==null&&t!==`/`&&(c.pathname=c.pathname===`/`?t:Wt([t,c.pathname])),(s.replace?n.replace:n.push)(c,s.state,s)},[t,n,a,i,e])}var si=g.createContext(null);function ci(e){let t=g.useContext(qr).outlet;return g.useMemo(()=>t&&g.createElement(si.Provider,{value:e},t),[t,e])}function li(){let{matches:e}=g.useContext(qr),t=e[e.length-1];return t?t.params:{}}function ui(e,{relative:t}={}){let{matches:n}=g.useContext(qr),{pathname:r}=ni(),i=JSON.stringify(Vt(n));return g.useMemo(()=>Ht(e,JSON.parse(i),r,t===`path`),[e,i,r,t])}function di(e,t,n){F(ti(),`useRoutes() may be used only in the context of a <Router> component.`);let{navigator:r}=g.useContext(Gr),{matches:i}=g.useContext(qr),a=i[i.length-1],o=a?a.params:{},s=a?a.pathname:`/`,c=a?a.pathnameBase:`/`,l=a&&a.route;{let e=l&&l.path||``;Ai(s,!l||e.endsWith(`*`)||e.endsWith(`*?`),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${s}" (under <Route path="${e}">) 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 <Route path="${e}"> to <Route path="${e===`/`?`*`:`${e}/*`}">.`)}let u=ni(),d;if(t){let e=typeof t==`string`?nt(t):t;F(c===`/`||e.pathname?.startsWith(c),`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 "${c}" but pathname "${e.pathname}" was given in the \`location\` prop.`),d=e}else d=u;let f=d.pathname||`/`,p=f;if(c!==`/`){let e=c.replace(/^\//,``).split(`/`);p=`/`+f.replace(/^\//,``).split(`/`).slice(e.length).join(`/`)}let m=mt(e,{pathname:p});Ze(l||m!=null,`No routes matched location "${d.pathname}${d.search}${d.hash}" `),Ze(m==null||m[m.length-1].route.element!==void 0||m[m.length-1].route.Component!==void 0||m[m.length-1].route.lazy!==void 0,`Matched leaf route at location "${d.pathname}${d.search}${d.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 h=vi(m&&m.map(e=>Object.assign({},e,{params:Object.assign({},o,e.params),pathname:Wt([c,r.encodeLocation?r.encodeLocation(e.pathname.replace(/%/g,`%25`).replace(/\?/g,`%3F`).replace(/#/g,`%23`)).pathname:e.pathname]),pathnameBase:e.pathnameBase===`/`?c:Wt([c,r.encodeLocation?r.encodeLocation(e.pathnameBase.replace(/%/g,`%25`).replace(/\?/g,`%3F`).replace(/#/g,`%23`)).pathname:e.pathnameBase])})),i,n);return t&&h?g.createElement(Kr.Provider,{value:{location:{pathname:`/`,search:``,hash:``,state:null,key:`default`,unstable_mask:void 0,...d},navigationType:`POP`}},h):h}function fi(){let e=Di(),t=Xt(e)?`${e.status} ${e.statusText}`:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,r=`rgba(200,200,200, 0.5)`,i={padding:`0.5rem`,backgroundColor:r},a={padding:`2px 4px`,backgroundColor:r},o=null;return console.error(`Error handled by React Router default ErrorBoundary:`,e),o=g.createElement(g.Fragment,null,g.createElement(`p`,null,`💿 Hey developer 👋`),g.createElement(`p`,null,`You can provide a way better UX than this when your app throws errors by providing your own `,g.createElement(`code`,{style:a},`ErrorBoundary`),` or`,` `,g.createElement(`code`,{style:a},`errorElement`),` prop on your route.`)),g.createElement(g.Fragment,null,g.createElement(`h2`,null,`Unexpected Application Error!`),g.createElement(`h3`,{style:{fontStyle:`italic`}},t),n?g.createElement(`pre`,{style:i},n):null,o)}var pi=g.createElement(fi,null),mi=class extends g.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?t.error:e.error,location:t.location,revalidation:e.revalidation||t.revalidation}}componentDidCatch(e,t){this.props.onError?this.props.onError(e,t):console.error(`React Router caught the following error during render`,e)}render(){let e=this.state.error;if(this.context&&typeof e==`object`&&e&&`digest`in e&&typeof e.digest==`string`){let t=$r(e.digest);t&&(e=t)}let t=e===void 0?this.props.children:g.createElement(qr.Provider,{value:this.props.routeContext},g.createElement(Jr.Provider,{value:e,children:this.props.component}));return this.context?g.createElement(gi,{error:e},t):t}};mi.contextType=Br;var hi=new WeakMap;function gi({children:e,error:t}){let{basename:n}=g.useContext(Gr);if(typeof t==`object`&&t&&`digest`in t&&typeof t.digest==`string`){let e=Qr(t.digest);if(e){let r=hi.get(t);if(r)throw r;let i=$t(e.location,n);if(Qt&&!hi.get(t))if(i.isExternal||e.reloadDocument)window.location.href=i.absoluteURL||i.to;else{let n=Promise.resolve().then(()=>window.__reactRouterDataRouter.navigate(i.to,{replace:e.replace}));throw hi.set(t,n),n}return g.createElement(`meta`,{httpEquiv:`refresh`,content:`0;url=${i.absoluteURL||i.to}`})}}return e}function _i({routeContext:e,match:t,children:n}){let r=g.useContext(Rr);return r&&r.static&&r.staticContext&&(t.route.errorElement||t.route.ErrorBoundary)&&(r.staticContext._deepestRenderedBoundaryId=t.route.id),g.createElement(qr.Provider,{value:e},n)}function vi(e,t=[],n){let r=n?.state;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 i=e,a=r?.errors;if(a!=null){let e=i.findIndex(e=>e.route.id&&a?.[e.route.id]!==void 0);F(e>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(a).join(`,`)}`),i=i.slice(0,Math.min(i.length,e+1))}let o=!1,s=-1;if(n&&r){o=r.renderFallback;for(let e=0;e<i.length;e++){let t=i[e];if((t.route.HydrateFallback||t.route.hydrateFallbackElement)&&(s=e),t.route.id){let{loaderData:e,errors:a}=r,c=t.route.loader&&!e.hasOwnProperty(t.route.id)&&(!a||a[t.route.id]===void 0);if(t.route.lazy||c){n.isStatic&&(o=!0),i=s>=0?i.slice(0,s+1):[i[0]];break}}}}let c=n?.onError,l=r&&c?(e,t)=>{c(e,{location:r.location,params:r.matches?.[0]?.params??{},unstable_pattern:Zt(r.matches),errorInfo:t})}:void 0;return i.reduceRight((e,n,c)=>{let u,d=!1,f=null,p=null;r&&(u=a&&n.route.id?a[n.route.id]:void 0,f=n.route.errorElement||pi,o&&(s<0&&c===0?(Ai(`route-fallback`,!1,"No `HydrateFallback` element provided to render during initial hydration"),d=!0,p=null):s===c&&(d=!0,p=n.route.hydrateFallbackElement||null)));let m=t.concat(i.slice(0,c+1)),h=()=>{let t;return t=u?f:d?p:n.route.Component?g.createElement(n.route.Component,null):n.route.element?n.route.element:e,g.createElement(_i,{match:n,routeContext:{outlet:e,matches:m,isDataRoute:r!=null},children:t})};return r&&(n.route.ErrorBoundary||n.route.errorElement||c===0)?g.createElement(mi,{location:r.location,revalidation:r.revalidation,component:f,error:u,children:h(),routeContext:{outlet:null,matches:m,isDataRoute:!0},onError:l}):h()},null)}function yi(e){return`${e} must be used within a data router.  See https://reactrouter.com/en/main/routers/picking-a-router.`}function bi(e){let t=g.useContext(Rr);return F(t,yi(e)),t}function xi(e){let t=g.useContext(zr);return F(t,yi(e)),t}function Si(e){let t=g.useContext(qr);return F(t,yi(e)),t}function Ci(e){let t=Si(e),n=t.matches[t.matches.length-1];return F(n.route.id,`${e} can only be used on routes that contain a unique "id"`),n.route.id}function wi(){return Ci(`useRouteId`)}function Ti(){return xi(`useNavigation`).navigation}function Ei(){let{matches:e,loaderData:t}=xi(`useMatches`);return g.useMemo(()=>e.map(e=>gt(e,t)),[e,t])}function Di(){let e=g.useContext(Jr),t=xi(`useRouteError`),n=Ci(`useRouteError`);return e===void 0?t.errors?.[n]:e}function Oi(){let{router:e}=bi(`useNavigate`),t=Ci(`useNavigate`),n=g.useRef(!1);return ii(()=>{n.current=!0}),g.useCallback(async(r,i={})=>{Ze(n.current,ri),n.current&&(typeof r==`number`?await e.navigate(r):await e.navigate(r,{fromRouteId:t,...i}))},[e,t])}var ki={};function Ai(e,t,n){!t&&!ki[e]&&(ki[e]=!0,Ze(!1,n))}var ji={};function Mi(e,t){!e&&!ji[t]&&(ji[t]=!0,console.warn(t))}var Ni=g.useOptimistic,Pi=()=>void 0;function Fi(e){return Ni?Ni(e):[e,Pi]}function Ii(e){let t={hasErrorBoundary:e.hasErrorBoundary||e.ErrorBoundary!=null||e.errorElement!=null};return e.Component&&(e.element&&Ze(!1,"You should not include both `Component` and `element` on your route - `Component` will be used."),Object.assign(t,{element:g.createElement(e.Component),Component:void 0})),e.HydrateFallback&&(e.hydrateFallbackElement&&Ze(!1,"You should not include both `HydrateFallback` and `hydrateFallbackElement` on your route - `HydrateFallback` will be used."),Object.assign(t,{hydrateFallbackElement:g.createElement(e.HydrateFallback),HydrateFallback:void 0})),e.ErrorBoundary&&(e.errorElement&&Ze(!1,"You should not include both `ErrorBoundary` and `errorElement` on your route - `ErrorBoundary` will be used."),Object.assign(t,{errorElement:g.createElement(e.ErrorBoundary),ErrorBoundary:void 0})),t}var Li=[`HydrateFallback`,`hydrateFallbackElement`],I=class{constructor(){this.status=`pending`,this.promise=new Promise((e,t)=>{this.resolve=t=>{this.status===`pending`&&(this.status=`resolved`,e(t))},this.reject=e=>{this.status===`pending`&&(this.status=`rejected`,t(e))}})}};function Ri({router:e,flushSync:t,onError:n,unstable_useTransitions:r}){r=Vr()||r;let[i,a]=g.useState(e.state),[o,s]=Fi(i),[c,l]=g.useState(),[u,d]=g.useState({isTransitioning:!1}),[f,p]=g.useState(),[m,h]=g.useState(),[_,v]=g.useState(),y=g.useRef(new Map),b=g.useCallback((i,{deletedFetchers:o,newErrors:c,flushSync:u,viewTransitionOpts:_})=>{c&&n&&Object.values(c).forEach(e=>n(e,{location:i.location,params:i.matches[0]?.params??{},unstable_pattern:Zt(i.matches)})),i.fetchers.forEach((e,t)=>{e.data!==void 0&&y.current.set(t,e.data)}),o.forEach(e=>y.current.delete(e)),Mi(u===!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 b=e.window!=null&&e.window.document!=null&&typeof e.window.document.startViewTransition==`function`;if(Mi(_==null||b,"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."),!_||!b){t&&u?t(()=>a(i)):r===!1?a(i):g.startTransition(()=>{r===!0&&s(e=>zi(e,i)),a(i)});return}if(t&&u){t(()=>{m&&(f?.resolve(),m.skipTransition()),d({isTransitioning:!0,flushSync:!0,currentLocation:_.currentLocation,nextLocation:_.nextLocation})});let n=e.window.document.startViewTransition(()=>{t(()=>a(i))});n.finished.finally(()=>{t(()=>{p(void 0),h(void 0),l(void 0),d({isTransitioning:!1})})}),t(()=>h(n));return}m?(f?.resolve(),m.skipTransition(),v({state:i,currentLocation:_.currentLocation,nextLocation:_.nextLocation})):(l(i),d({isTransitioning:!0,flushSync:!1,currentLocation:_.currentLocation,nextLocation:_.nextLocation}))},[e.window,t,m,f,r,s,n]);g.useLayoutEffect(()=>e.subscribe(b),[e,b]);let x=o.initialized;g.useLayoutEffect(()=>{!x&&e.state.initialized&&b(e.state,{deletedFetchers:[],flushSync:!1,newErrors:null})},[x,b,e.state]),g.useEffect(()=>{u.isTransitioning&&!u.flushSync&&p(new I)},[u]),g.useEffect(()=>{if(f&&c&&e.window){let t=c,n=f.promise,i=e.window.document.startViewTransition(async()=>{r===!1?a(t):g.startTransition(()=>{r===!0&&s(e=>zi(e,t)),a(t)}),await n});i.finished.finally(()=>{p(void 0),h(void 0),l(void 0),d({isTransitioning:!1})}),h(i)}},[c,f,e.window,r,s]),g.useEffect(()=>{f&&c&&o.location.key===c.location.key&&f.resolve()},[f,m,o.location,c]),g.useEffect(()=>{!u.isTransitioning&&_&&(l(_.state),d({isTransitioning:!0,flushSync:!1,currentLocation:_.currentLocation,nextLocation:_.nextLocation}),v(void 0))},[u.isTransitioning,_]);let S=g.useMemo(()=>({createHref:e.createHref,encodeLocation:e.encodeLocation,go:t=>e.navigate(t),push:(t,n,r)=>e.navigate(t,{state:n,preventScrollReset:r?.preventScrollReset}),replace:(t,n,r)=>e.navigate(t,{replace:!0,state:n,preventScrollReset:r?.preventScrollReset})}),[e]),C=e.basename||`/`,w=g.useMemo(()=>({router:e,navigator:S,static:!1,basename:C,onError:n}),[e,S,C,n]);return g.createElement(g.Fragment,null,g.createElement(Rr.Provider,{value:w},g.createElement(zr.Provider,{value:o},g.createElement(Ur.Provider,{value:y.current},g.createElement(Hr.Provider,{value:u},g.createElement(Ui,{basename:C,location:o.location,navigationType:o.historyAction,navigator:S,unstable_useTransitions:r},g.createElement(Bi,{routes:e.routes,future:e.future,state:o,isStatic:!1,onError:n})))))),null)}function zi(e,t){return{...e,navigation:t.navigation.state===`idle`?e.navigation:t.navigation,revalidation:t.revalidation===`idle`?e.revalidation:t.revalidation,actionData:t.navigation.state===`submitting`?e.actionData:t.actionData,fetchers:t.fetchers}}var Bi=g.memo(Vi);function Vi({routes:e,future:t,state:n,isStatic:r,onError:i}){return di(e,void 0,{state:n,isStatic:r,onError:i,future:t})}function Hi(e){return ci(e.context)}function Ui({basename:e=`/`,children:t=null,location:n,navigationType:r=`POP`,navigator:i,static:a=!1,unstable_useTransitions:o}){F(!ti(),`You cannot render a <Router> inside another <Router>. You should never have more than one in your app.`);let s=e.replace(/^\/*/,`/`),c=g.useMemo(()=>({basename:s,navigator:i,static:a,unstable_useTransitions:o,future:{}}),[s,i,a,o]);typeof n==`string`&&(n=nt(n));let{pathname:l=`/`,search:u=``,hash:d=``,state:f=null,key:p=`default`,unstable_mask:m}=n,h=g.useMemo(()=>{let e=Nt(l,s);return e==null?null:{location:{pathname:e,search:u,hash:d,state:f,key:p,unstable_mask:m},navigationType:r}},[s,l,u,d,f,p,r,m]);return Ze(h!=null,`<Router basename="${s}"> is not able to match the URL "${l}${u}${d}" because it does not start with the basename, so the <Router> won't render anything.`),h==null?null:g.createElement(Gr.Provider,{value:c},g.createElement(Kr.Provider,{children:t,value:h}))}g.Component;var Wi=`get`,Gi=`application/x-www-form-urlencoded`;function Ki(e){return typeof HTMLElement<`u`&&e instanceof HTMLElement}function qi(e){return Ki(e)&&e.tagName.toLowerCase()===`button`}function Ji(e){return Ki(e)&&e.tagName.toLowerCase()===`form`}function Yi(e){return Ki(e)&&e.tagName.toLowerCase()===`input`}function Xi(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function Zi(e,t){return e.button===0&&(!t||t===`_self`)&&!Xi(e)}var Qi=null;function $i(){if(Qi===null)try{new FormData(document.createElement(`form`),0),Qi=!1}catch{Qi=!0}return Qi}var ea=new Set([`application/x-www-form-urlencoded`,`multipart/form-data`,`text/plain`]);function ta(e){return e!=null&&!ea.has(e)?(Ze(!1,`"${e}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${Gi}"`),null):e}function na(e,t){let n,r,i,a,o;if(Ji(e)){let o=e.getAttribute(`action`);r=o?Nt(o,t):null,n=e.getAttribute(`method`)||Wi,i=ta(e.getAttribute(`enctype`))||Gi,a=new FormData(e)}else if(qi(e)||Yi(e)&&(e.type===`submit`||e.type===`image`)){let o=e.form;if(o==null)throw Error(`Cannot submit a <button> or <input type="submit"> without a <form>`);let s=e.getAttribute(`formaction`)||o.getAttribute(`action`);if(r=s?Nt(s,t):null,n=e.getAttribute(`formmethod`)||o.getAttribute(`method`)||Wi,i=ta(e.getAttribute(`formenctype`))||ta(o.getAttribute(`enctype`))||Gi,a=new FormData(o,e),!$i()){let{name:t,type:n,value:r}=e;if(n===`image`){let e=t?`${t}.`:``;a.append(`${e}x`,`0`),a.append(`${e}y`,`0`)}else t&&a.append(t,r)}}else if(Ki(e))throw Error(`Cannot submit element that is not <form>, <button>, or <input type="submit|image">`);else n=Wi,r=null,i=Gi,o=e;return a&&i===`text/plain`&&(o=a,a=void 0),{action:r,method:n.toLowerCase(),encType:i,formData:a,body:o}}Object.getOwnPropertyNames(Object.prototype).sort().join(`\0`);var ra={"&":`\\u0026`,">":`\\u003e`,"<":`\\u003c`,"\u2028":`\\u2028`,"\u2029":`\\u2029`},ia=/[&><\u2028\u2029]/g;function aa(e){return e.replace(ia,e=>ra[e])}function oa(e,t){if(e===!1||e==null)throw Error(t)}function sa(e,t,n,r){let i=typeof e==`string`?new URL(e,typeof window>`u`?`server://singlefetch/`:window.location.origin):e;return n?i.pathname.endsWith(`/`)?i.pathname=`${i.pathname}_.${r}`:i.pathname=`${i.pathname}.${r}`:i.pathname===`/`?i.pathname=`_root.${r}`:t&&Nt(i.pathname,t)===`/`?i.pathname=`${Gt(t)}/_root.${r}`:i.pathname=`${Gt(i.pathname)}.${r}`,i}async function ca(e,t){if(e.id in t)return t[e.id];try{let n=await Ue(()=>import(e.module),[]);return t[e.id]=n,n}catch(t){return console.error(`Error loading route module \`${e.module}\`, reloading page...`),console.error(t),window.__reactRouterContext&&window.__reactRouterContext.isSpaMode,window.location.reload(),new Promise(()=>{})}}function la(e){return e!=null&&typeof e.page==`string`}function ua(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 da(e,t,n){return ga((await Promise.all(e.map(async e=>{let r=t.routes[e.route.id];if(r){let e=await ca(r,n);return e.links?e.links():[]}return[]}))).flat(1).filter(ua).filter(e=>e.rel===`stylesheet`||e.rel===`preload`).map(e=>e.rel===`stylesheet`?{...e,rel:`prefetch`,as:`style`}:{...e,rel:`prefetch`}))}function fa(e,t,n,r,i,a){let o=(e,t)=>n[t]?e.route.id!==n[t].route.id:!0,s=(e,t)=>n[t].pathname!==e.pathname||n[t].route.path?.endsWith(`*`)&&n[t].params[`*`]!==e.params[`*`];return a===`assets`?t.filter((e,t)=>o(e,t)||s(e,t)):a===`data`?t.filter((t,a)=>{let c=r.routes[t.route.id];if(!c||!c.hasLoader)return!1;if(o(t,a)||s(t,a))return!0;if(t.route.shouldRevalidate){let r=t.route.shouldRevalidate({currentUrl:new URL(i.pathname+i.search+i.hash,window.origin),currentParams:n[0]?.params||{},nextUrl:new URL(e,window.origin),nextParams:t.params,defaultShouldRevalidate:!0});if(typeof r==`boolean`)return r}return!0}):[]}function pa(e,t,{includeHydrateFallback:n}={}){return ma(e.map(e=>{let r=t.routes[e.route.id];if(!r)return[];let i=[r.module];return r.clientActionModule&&(i=i.concat(r.clientActionModule)),r.clientLoaderModule&&(i=i.concat(r.clientLoaderModule)),n&&r.hydrateFallbackModule&&(i=i.concat(r.hydrateFallbackModule)),r.imports&&(i=i.concat(r.imports)),i}).flat(1))}function ma(e){return[...new Set(e)]}function ha(e){let t={},n=Object.keys(e).sort();for(let r of n)t[r]=e[r];return t}function ga(e,t){let n=new Set,r=new Set(t);return e.reduce((e,i)=>{if(t&&!la(i)&&i.as===`script`&&i.href&&r.has(i.href))return e;let a=JSON.stringify(ha(i));return n.has(a)||(n.add(a),e.push({key:a,link:i})),e},[])}function _a(){let e=g.useContext(Rr);return oa(e,`You must render this element inside a <DataRouterContext.Provider> element`),e}function va(){let e=g.useContext(zr);return oa(e,`You must render this element inside a <DataRouterStateContext.Provider> element`),e}var ya=g.createContext(void 0);ya.displayName=`FrameworkContext`;function ba(){let e=g.useContext(ya);return oa(e,`You must render this element inside a <HydratedRouter> element`),e}function xa(e,t){let n=g.useContext(ya),[r,i]=g.useState(!1),[a,o]=g.useState(!1),{onFocus:s,onBlur:c,onMouseEnter:l,onMouseLeave:u,onTouchStart:d}=t,f=g.useRef(null);g.useEffect(()=>{if(e===`render`&&o(!0),e===`viewport`){let e=new IntersectionObserver(e=>{e.forEach(e=>{o(e.isIntersecting)})},{threshold:.5});return f.current&&e.observe(f.current),()=>{e.disconnect()}}},[e]),g.useEffect(()=>{if(r){let e=setTimeout(()=>{o(!0)},100);return()=>{clearTimeout(e)}}},[r]);let p=()=>{i(!0)},m=()=>{i(!1),o(!1)};return n?e===`intent`?[a,f,{onFocus:Sa(s,p),onBlur:Sa(c,m),onMouseEnter:Sa(l,p),onMouseLeave:Sa(u,m),onTouchStart:Sa(d,p)}]:[a,f,{}]:[!1,f,{}]}function Sa(e,t){return n=>{e&&e(n),n.defaultPrevented||t(n)}}function Ca({page:e,...t}){let n=Vr(),{router:r}=_a(),i=g.useMemo(()=>mt(r.routes,e,r.basename),[r.routes,e,r.basename]);return i?n?g.createElement(Ta,{page:e,matches:i,...t}):g.createElement(Ea,{page:e,matches:i,...t}):null}function wa(e){let{manifest:t,routeModules:n}=ba(),[r,i]=g.useState([]);return g.useEffect(()=>{let r=!1;return da(e,t,n).then(e=>{r||i(e)}),()=>{r=!0}},[e,t,n]),r}function Ta({page:e,matches:t,...n}){let r=ni(),{future:i}=ba(),{basename:a}=_a(),o=g.useMemo(()=>{if(e===r.pathname+r.search+r.hash)return[];let n=sa(e,a,i.unstable_trailingSlashAwareDataRequests,`rsc`),o=!1,s=[];for(let e of t)typeof e.route.shouldRevalidate==`function`?o=!0:s.push(e.route.id);return o&&s.length>0&&n.searchParams.set(`_routes`,s.join(`,`)),[n.pathname+n.search]},[a,i.unstable_trailingSlashAwareDataRequests,e,r,t]);return g.createElement(g.Fragment,null,o.map(e=>g.createElement(`link`,{key:e,rel:`prefetch`,as:`fetch`,href:e,...n})))}function Ea({page:e,matches:t,...n}){let r=ni(),{future:i,manifest:a,routeModules:o}=ba(),{basename:s}=_a(),{loaderData:c,matches:l}=va(),u=g.useMemo(()=>fa(e,t,l,a,r,`data`),[e,t,l,a,r]),d=g.useMemo(()=>fa(e,t,l,a,r,`assets`),[e,t,l,a,r]),f=g.useMemo(()=>{if(e===r.pathname+r.search+r.hash)return[];let n=new Set,l=!1;if(t.forEach(e=>{let t=a.routes[e.route.id];!t||!t.hasLoader||(!u.some(t=>t.route.id===e.route.id)&&e.route.id in c&&o[e.route.id]?.shouldRevalidate||t.hasClientLoader?l=!0:n.add(e.route.id))}),n.size===0)return[];let d=sa(e,s,i.unstable_trailingSlashAwareDataRequests,`data`);return l&&n.size>0&&d.searchParams.set(`_routes`,t.filter(e=>n.has(e.route.id)).map(e=>e.route.id).join(`,`)),[d.pathname+d.search]},[s,i.unstable_trailingSlashAwareDataRequests,c,r,a,u,t,e,o]),p=g.useMemo(()=>pa(d,a),[d,a]),m=wa(d);return g.createElement(g.Fragment,null,f.map(e=>g.createElement(`link`,{key:e,rel:`prefetch`,as:`fetch`,href:e,...n})),p.map(e=>g.createElement(`link`,{key:e,rel:`modulepreload`,href:e,...n})),m.map(({key:e,link:t})=>g.createElement(`link`,{key:e,nonce:n.nonce,...t,crossOrigin:t.crossOrigin??n.crossOrigin})))}function Da(...e){return t=>{e.forEach(e=>{typeof e==`function`?e(t):e!=null&&(e.current=t)})}}g.Component;var Oa=typeof window<`u`&&window.document!==void 0&&window.document.createElement!==void 0;try{Oa&&(window.__reactRouterVersion=`7.14.1`)}catch{}function ka(e,t){return wn({basename:t?.basename,getContext:t?.getContext,future:t?.future,history:Xe({window:t?.window}),hydrationData:t?.hydrationData||Aa(),routes:e,mapRouteProperties:Ii,hydrationRouteProperties:Li,dataStrategy:t?.dataStrategy,patchRoutesOnNavigation:t?.patchRoutesOnNavigation,window:t?.window,unstable_instrumentations:t?.unstable_instrumentations}).initialize()}function Aa(){let e=window?.__staticRouterHydrationData;return e&&e.errors&&(e={...e,errors:ja(e.errors)}),e}function ja(e){if(!e)return null;let t=Object.entries(e),n={};for(let[e,r]of t)if(r&&r.__type===`RouteErrorResponse`)n[e]=new Yt(r.status,r.statusText,r.data,r.internal===!0);else if(r&&r.__type===`Error`){if(r.__subType){let t=window[r.__subType];if(typeof t==`function`)try{let i=new t(r.message);i.stack=``,n[e]=i}catch{}}if(n[e]==null){let t=Error(r.message);t.stack=``,n[e]=t}}else n[e]=r;return n}function Ma({basename:e,children:t,history:n,unstable_useTransitions:r}){let[i,a]=g.useState({action:n.action,location:n.location}),o=g.useCallback(e=>{r===!1?a(e):g.startTransition(()=>a(e))},[r]);return g.useLayoutEffect(()=>n.listen(o),[n,o]),g.createElement(Ui,{basename:e,children:t,location:i.location,navigationType:i.action,navigator:n,unstable_useTransitions:r})}Ma.displayName=`unstable_HistoryRouter`;var Na=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Pa=g.forwardRef(function({onClick:e,discover:t=`render`,prefetch:n=`none`,relative:r,reloadDocument:i,replace:a,unstable_mask:o,state:s,target:c,to:l,preventScrollReset:u,viewTransition:d,unstable_defaultShouldRevalidate:f,...p},m){let{basename:h,navigator:_,unstable_useTransitions:v}=g.useContext(Gr),y=typeof l==`string`&&Na.test(l),b=$t(l,h);l=b.to;let x=ei(l,{relative:r}),S=ni(),C=null;if(o){let e=Ht(o,[],S.unstable_mask?S.unstable_mask.pathname:`/`,!0);h!==`/`&&(e.pathname=e.pathname===`/`?h:Wt([h,e.pathname])),C=_.createHref(e)}let[w,T,E]=xa(n,p),D=Va(l,{replace:a,unstable_mask:o,state:s,target:c,preventScrollReset:u,relative:r,viewTransition:d,unstable_defaultShouldRevalidate:f,unstable_useTransitions:v});function O(t){e&&e(t),t.defaultPrevented||D(t)}let ee=!(b.isExternal||i),te=g.createElement(`a`,{...p,...E,href:(ee?C:void 0)||b.absoluteURL||x,onClick:ee?O:e,ref:Da(m,T),target:c,"data-discover":!y&&t===`render`?`true`:void 0});return w&&!y?g.createElement(g.Fragment,null,te,g.createElement(Ca,{page:x})):te});Pa.displayName=`Link`;var Fa=g.forwardRef(function({"aria-current":e=`page`,caseSensitive:t=!1,className:n=``,end:r=!1,style:i,to:a,viewTransition:o,children:s,...c},l){let u=ui(a,{relative:c.relative}),d=ni(),f=g.useContext(zr),{navigator:p,basename:m}=g.useContext(Gr),h=f!=null&&Za(u)&&o===!0,_=p.encodeLocation?p.encodeLocation(u).pathname:u.pathname,v=d.pathname,y=f&&f.navigation&&f.navigation.location?f.navigation.location.pathname:null;t||(v=v.toLowerCase(),y=y?y.toLowerCase():null,_=_.toLowerCase()),y&&m&&(y=Nt(y,m)||y);let b=_!==`/`&&_.endsWith(`/`)?_.length-1:_.length,x=v===_||!r&&v.startsWith(_)&&v.charAt(b)===`/`,S=y!=null&&(y===_||!r&&y.startsWith(_)&&y.charAt(_.length)===`/`),C={isActive:x,isPending:S,isTransitioning:h},w=x?e:void 0,T;T=typeof n==`function`?n(C):[n,x?`active`:null,S?`pending`:null,h?`transitioning`:null].filter(Boolean).join(` `);let E=typeof i==`function`?i(C):i;return g.createElement(Pa,{...c,"aria-current":w,className:T,ref:l,style:E,to:a,viewTransition:o},typeof s==`function`?s(C):s)});Fa.displayName=`NavLink`;var Ia=g.forwardRef(({discover:e=`render`,fetcherKey:t,navigate:n,reloadDocument:r,replace:i,state:a,method:o=Wi,action:s,onSubmit:c,relative:l,preventScrollReset:u,viewTransition:d,unstable_defaultShouldRevalidate:f,...p},m)=>{let{unstable_useTransitions:h}=g.useContext(Gr),_=Wa(),v=Ga(s,{relative:l}),y=o.toLowerCase()===`get`?`get`:`post`,b=typeof s==`string`&&Na.test(s);return g.createElement(`form`,{ref:m,method:y,action:v,onSubmit:r?c:e=>{if(c&&c(e),e.defaultPrevented)return;e.preventDefault();let r=e.nativeEvent.submitter,s=r?.getAttribute(`formmethod`)||o,p=()=>_(r||e.currentTarget,{fetcherKey:t,method:s,navigate:n,replace:i,state:a,relative:l,preventScrollReset:u,viewTransition:d,unstable_defaultShouldRevalidate:f});h&&n!==!1?g.startTransition(()=>p()):p()},...p,"data-discover":!b&&e===`render`?`true`:void 0})});Ia.displayName=`Form`;function La({getKey:e,storageKey:t,...n}){let r=g.useContext(ya),{basename:i}=g.useContext(Gr),a=ni(),o=Ei();Ya({getKey:e,storageKey:t});let s=g.useMemo(()=>{if(!r||!e)return null;let t=Ja(a,o,i,e);return t===a.key?null:t},[]);if(!r||r.isSpaMode)return null;let c=((e,t)=>{if(!window.history.state||!window.history.state.key){let e=Math.random().toString(32).slice(2);window.history.replaceState({key:e},``)}try{let n=JSON.parse(sessionStorage.getItem(e)||`{}`)[t||window.history.state.key];typeof n==`number`&&window.scrollTo(0,n)}catch(t){console.error(t),sessionStorage.removeItem(e)}}).toString();return g.createElement(`script`,{...n,suppressHydrationWarning:!0,dangerouslySetInnerHTML:{__html:`(${c})(${aa(JSON.stringify(t||Ka))}, ${aa(JSON.stringify(s))})`}})}La.displayName=`ScrollRestoration`;function Ra(e){return`${e} must be used within a data router.  See https://reactrouter.com/en/main/routers/picking-a-router.`}function za(e){let t=g.useContext(Rr);return F(t,Ra(e)),t}function Ba(e){let t=g.useContext(zr);return F(t,Ra(e)),t}function Va(e,{target:t,replace:n,unstable_mask:r,state:i,preventScrollReset:a,relative:o,viewTransition:s,unstable_defaultShouldRevalidate:c,unstable_useTransitions:l}={}){let u=ai(),d=ni(),f=ui(e,{relative:o});return g.useCallback(p=>{if(Zi(p,t)){p.preventDefault();let t=n===void 0?tt(d)===tt(f):n,m=()=>u(e,{replace:t,unstable_mask:r,state:i,preventScrollReset:a,relative:o,viewTransition:s,unstable_defaultShouldRevalidate:c});l?g.startTransition(()=>m()):m()}},[d,u,f,n,r,i,t,e,a,o,s,c,l])}var Ha=0,Ua=()=>`__${String(++Ha)}__`;function Wa(){let{router:e}=za(`useSubmit`),{basename:t}=g.useContext(Gr),n=wi(),r=e.fetch,i=e.navigate;return g.useCallback(async(e,a={})=>{let{action:o,method:s,encType:c,formData:l,body:u}=na(e,t);a.navigate===!1?await r(a.fetcherKey||Ua(),n,a.action||o,{unstable_defaultShouldRevalidate:a.unstable_defaultShouldRevalidate,preventScrollReset:a.preventScrollReset,formData:l,body:u,formMethod:a.method||s,formEncType:a.encType||c,flushSync:a.flushSync}):await i(a.action||o,{unstable_defaultShouldRevalidate:a.unstable_defaultShouldRevalidate,preventScrollReset:a.preventScrollReset,formData:l,body:u,formMethod:a.method||s,formEncType:a.encType||c,replace:a.replace,state:a.state,fromRouteId:n,flushSync:a.flushSync,viewTransition:a.viewTransition})},[r,i,t,n])}function Ga(e,{relative:t}={}){let{basename:n}=g.useContext(Gr),r=g.useContext(qr);F(r,`useFormAction must be used inside a RouteContext`);let[i]=r.matches.slice(-1),a={...ui(e||`.`,{relative:t})},o=ni();if(e==null){a.search=o.search;let e=new URLSearchParams(a.search),t=e.getAll(`index`);if(t.some(e=>e===``)){e.delete(`index`),t.filter(e=>e).forEach(t=>e.append(`index`,t));let n=e.toString();a.search=n?`?${n}`:``}}return(!e||e===`.`)&&i.route.index&&(a.search=a.search?a.search.replace(/^\?/,`?index&`):`?index`),n!==`/`&&(a.pathname=a.pathname===`/`?n:Wt([n,a.pathname])),tt(a)}var Ka=`react-router-scroll-positions`,qa={};function Ja(e,t,n,r){let i=null;return r&&(i=r(n===`/`?e:{...e,pathname:Nt(e.pathname,n)||e.pathname},t)),i??=e.key,i}function Ya({getKey:e,storageKey:t}={}){let{router:n}=za(`useScrollRestoration`),{restoreScrollPosition:r,preventScrollReset:i}=Ba(`useScrollRestoration`),{basename:a}=g.useContext(Gr),o=ni(),s=Ei(),c=Ti();g.useEffect(()=>(window.history.scrollRestoration=`manual`,()=>{window.history.scrollRestoration=`auto`}),[]),Xa(g.useCallback(()=>{if(c.state===`idle`){let t=Ja(o,s,a,e);qa[t]=window.scrollY}try{sessionStorage.setItem(t||Ka,JSON.stringify(qa))}catch(e){Ze(!1,`Failed to save scroll positions in sessionStorage, <ScrollRestoration /> will not work properly (${e}).`)}window.history.scrollRestoration=`auto`},[c.state,e,a,o,s,t])),typeof document<`u`&&(g.useLayoutEffect(()=>{try{let e=sessionStorage.getItem(t||Ka);e&&(qa=JSON.parse(e))}catch{}},[t]),g.useLayoutEffect(()=>{let t=n?.enableScrollRestoration(qa,()=>window.scrollY,e?(t,n)=>Ja(t,n,a,e):void 0);return()=>t&&t()},[n,a,e]),g.useLayoutEffect(()=>{if(r!==!1){if(typeof r==`number`){window.scrollTo(0,r);return}try{if(o.hash){let e=document.getElementById(decodeURIComponent(o.hash.slice(1)));if(e){e.scrollIntoView();return}}}catch{Ze(!1,`"${o.hash.slice(1)}" is not a decodable element ID. The view will not scroll to it.`)}i!==!0&&window.scrollTo(0,0)}},[o,r,i]))}function Xa(e,t){let{capture:n}=t||{};g.useEffect(()=>{let t=n==null?void 0:{capture:n};return window.addEventListener(`pagehide`,e,t),()=>{window.removeEventListener(`pagehide`,e,t)}},[e,n])}function Za(e,{relative:t}={}){let n=g.useContext(Hr);F(n!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`.  Did you accidentally import `RouterProvider` from `react-router`?");let{basename:r}=za(`useViewTransitionState`),i=ui(e,{relative:t});if(!n.isTransitioning)return!1;let a=Nt(n.currentLocation.pathname,r)||n.currentLocation.pathname,o=Nt(n.nextLocation.pathname,r)||n.nextLocation.pathname;return At(i.pathname,o)!=null||At(i.pathname,a)!=null}function Qa(e){return g.createElement(Ri,{flushSync:ze.flushSync,...e})}var $a=class e extends Error{static kind=`ClerkError`;clerkError=!0;code;longMessage;docsUrl;cause;get name(){return this.constructor.name}constructor(t){super(new.target.formatMessage(new.target.kind,t.message,t.code,t.docsUrl),{cause:t.cause}),Object.setPrototypeOf(this,e.prototype),this.code=t.code,this.docsUrl=t.docsUrl,this.longMessage=t.longMessage,this.cause=t.cause}toString(){return`[${this.name}]\nMessage:${this.message}`}static formatMessage(e,t,n,r){let i=`Clerk:`,a=new RegExp(i.replace(` `,`\\s*`),`i`);return t=t.replace(a,``),t=`${i} ${t.trim()}\n\n(code="${n}")\n\n`,r&&(t+=`\n\nDocs: ${r}`),t}},eo=class e extends $a{static kind=`ClerkRuntimeError`;clerkRuntimeError=!0;constructor(t,n){super({...n,message:t}),Object.setPrototypeOf(this,e.prototype)}},to=Object.freeze({InvalidProxyUrlErrorMessage:`The proxyUrl passed to Clerk is invalid. The expected value for proxyUrl is an absolute URL or a relative path with a leading '/'. (key={{url}})`,InvalidPublishableKeyErrorMessage:`The publishableKey passed to Clerk is invalid. You can get your Publishable key at https://dashboard.clerk.com/last-active?path=api-keys. (key={{key}})`,MissingPublishableKeyErrorMessage:`Missing publishableKey. You can get your key at https://dashboard.clerk.com/last-active?path=api-keys.`,MissingSecretKeyErrorMessage:`Missing secretKey. You can get your key at https://dashboard.clerk.com/last-active?path=api-keys.`,MissingClerkProvider:`{{source}} can only be used within the <ClerkProvider /> component. Learn more: https://clerk.com/docs/components/clerk-provider`});function no({packageName:e,customMessages:t}){let n=e;function r(e,t){if(!t)return`${n}: ${e}`;let r=e,i=e.matchAll(/{{([a-zA-Z0-9-_]+)}}/g);for(let e of i){let n=(t[e[1]]||``).toString();r=r.replace(`{{${e[1]}}}`,n)}return`${n}: ${r}`}let i={...to,...t};return{setPackageName({packageName:e}){return typeof e==`string`&&(n=e),this},setMessages({customMessages:e}){return Object.assign(i,e||{}),this},throwInvalidPublishableKeyError(e){throw Error(r(i.InvalidPublishableKeyErrorMessage,e))},throwInvalidProxyUrl(e){throw Error(r(i.InvalidProxyUrlErrorMessage,e))},throwMissingPublishableKeyError(){throw Error(r(i.MissingPublishableKeyErrorMessage))},throwMissingSecretKeyError(){throw Error(r(i.MissingSecretKeyErrorMessage))},throwMissingClerkProviderError(e){throw Error(r(i.MissingClerkProvider,e))},throw(e){throw Error(r(e))}}}var ro=[`.lcl.dev`,`.stg.dev`,`.lclstage.dev`,`.stgstage.dev`,`.dev.lclclerk.com`,`.stg.lclclerk.com`,`.accounts.lclclerk.com`,`accountsstage.dev`,`accounts.dev`],io=e=>typeof atob<`u`&&typeof atob==`function`?atob(e):globalThis.Buffer===void 0?e:globalThis.Buffer.from(e,`base64`).toString(),ao=`pk_live_`,oo=`pk_test_`;function so(e){if(!e.endsWith(`$`))return!1;let t=e.slice(0,-1);return t.includes(`$`)?!1:t.includes(`.`)}function co(e,t={}){if(e||=``,!e||!lo(e)){if(t.fatal&&!e)throw Error(`Publishable key is missing. Ensure that your publishable key is correctly configured. Double-check your environment configuration for your keys, or access them here: https://dashboard.clerk.com/last-active?path=api-keys`);if(t.fatal&&!lo(e))throw Error(`Publishable key not valid.`);return null}let n=e.startsWith(ao)?`production`:`development`,r;try{r=io(e.split(`_`)[2])}catch{if(t.fatal)throw Error(`Publishable key not valid: Failed to decode key.`);return null}if(!so(r)){if(t.fatal)throw Error(`Publishable key not valid: Decoded key has invalid format.`);return null}let i=r.slice(0,-1);return t.proxyUrl?i=t.proxyUrl:n!==`development`&&t.domain&&t.isSatellite&&(i=`clerk.${t.domain}`),{instanceType:n,frontendApi:i}}function lo(e=``){try{if(!(e.startsWith(ao)||e.startsWith(oo)))return!1;let t=e.split(`_`);if(t.length!==3)return!1;let n=t[2];return n?so(io(n)):!1}catch{return!1}}function uo(){let e=new Map;return{isDevOrStagingUrl:t=>{if(!t)return!1;let n=typeof t==`string`?t:t.hostname,r=e.get(n);return r===void 0&&(r=ro.some(e=>n.endsWith(e)),e.set(n,r)),r}}}var fo={strict_mfa:{afterMinutes:10,level:`multi_factor`},strict:{afterMinutes:10,level:`second_factor`},moderate:{afterMinutes:60,level:`second_factor`},lax:{afterMinutes:1440,level:`second_factor`}},po=new Set([`first_factor`,`second_factor`,`multi_factor`]),mo=new Set([`strict_mfa`,`strict`,`moderate`,`lax`]),ho=new Set([`o`,`org`,`organization`]),go=new Set([`u`,`user`]),L=e=>typeof e==`number`&&e>0,_o=e=>po.has(e),vo=e=>mo.has(e),yo=e=>e.replace(/^(org:)*/,`org:`),bo=(e,t)=>{let{orgId:n,orgRole:r,orgPermissions:i}=t;return!e.role&&!e.permission||!n||!r||!i?null:e.permission?i.includes(yo(e.permission)):e.role?yo(r)===yo(e.role):null},xo=(e,t)=>{let{org:n,user:r}=Co(e),[i,a]=t.split(`:`),o=a!==void 0,s=i,c=a||i;if(o&&!ho.has(s)&&!go.has(s))throw Error(`Invalid scope: ${s}`);if(o){if(ho.has(s))return n.includes(c);if(go.has(s))return r.includes(c)}return[...n,...r].includes(c)},So=(e,t)=>{let{features:n,plans:r}=t;return e.feature&&n?xo(n,e.feature):e.plan&&r?xo(r,e.plan):null},Co=e=>{let t=[],n=[];if(!e)return{org:t,user:n};let r=e.split(`,`);for(let e=0;e<r.length;e++){let i=r[e].trim(),a=i.indexOf(`:`);if(a===-1)throw Error(`Invalid claim element (missing colon): ${i}`);let o=i.slice(0,a),s=i.slice(a+1);o===`o`?t.push(s):o===`u`?n.push(s):(o===`ou`||o===`uo`)&&(t.push(s),n.push(s))}return{org:t,user:n}},wo=e=>{if(!e)return!1;let t=e=>typeof e==`string`?fo[e]:e,n=typeof e==`string`&&vo(e),r=typeof e==`object`&&_o(e.level)&&L(e.afterMinutes);return n||r?t.bind(null,e):!1},To=(e,{factorVerificationAge:t})=>{if(!e.reverification||!t)return null;let n=wo(e.reverification);if(!n)return null;let{level:r,afterMinutes:i}=n(),[a,o]=t,s=a===-1?null:i>a,c=o===-1?null:i>o;switch(r){case`first_factor`:return s;case`second_factor`:return o===-1?s:c;case`multi_factor`:return o===-1?s:s&&c}},Eo=e=>t=>{if(!e.userId)return!1;let n=So(t,e),r=bo(t,e),i=To(t,e);return[n||r,i].some(e=>e===null)?[n||r,i].some(e=>e===!0):[n||r,i].every(e=>e===!0)},Do=({authObject:{sessionId:e,sessionStatus:t,userId:n,actor:r,orgId:i,orgRole:a,orgSlug:o,signOut:s,getToken:c,has:l,sessionClaims:u},options:{treatPendingAsSignedOut:d=!0}})=>{if(e===void 0&&n===void 0)return{actor:void 0,getToken:c,has:()=>!1,isLoaded:!1,isSignedIn:void 0,orgId:void 0,orgRole:void 0,orgSlug:void 0,sessionClaims:void 0,sessionId:e,signOut:s,userId:n};if(e===null&&n===null)return{actor:null,getToken:c,has:()=>!1,isLoaded:!0,isSignedIn:!1,orgId:null,orgRole:null,orgSlug:null,sessionClaims:null,sessionId:e,signOut:s,userId:n};if(d&&t===`pending`)return{actor:null,getToken:c,has:()=>!1,isLoaded:!0,isSignedIn:!1,orgId:null,orgRole:null,orgSlug:null,sessionClaims:null,sessionId:null,signOut:s,userId:null};if(e&&u&&n&&i&&a)return{actor:r||null,getToken:c,has:l,isLoaded:!0,isSignedIn:!0,orgId:i,orgRole:a,orgSlug:o||null,sessionClaims:u,sessionId:e,signOut:s,userId:n};if(e&&u&&n&&!i)return{actor:r||null,getToken:c,has:l,isLoaded:!0,isSignedIn:!0,orgId:null,orgRole:null,orgSlug:null,sessionClaims:u,sessionId:e,signOut:s,userId:n}},Oo=(e,t,n)=>!e&&n?ko(n):Ao(t),ko=e=>{let t=e.userId,n=e.user,r=e.sessionId,i=e.sessionStatus,a=e.sessionClaims;return{userId:t,user:n,sessionId:r,session:e.session,sessionStatus:i,sessionClaims:a,organization:e.organization,orgId:e.orgId,orgRole:e.orgRole,orgPermissions:e.orgPermissions,orgSlug:e.orgSlug,actor:e.actor,factorVerificationAge:e.factorVerificationAge}},Ao=e=>{let t=e.user?e.user.id:e.user,n=e.user,r=e.session?e.session.id:e.session,i=e.session,a=e.session?.status,o=e.session?e.session.lastActiveToken?.jwt?.claims:null,s=e.session?e.session.factorVerificationAge:null,c=i?.actor,l=e.organization,u=e.organization?e.organization.id:e.organization,d=l?.slug,f=l&&n?.organizationMemberships?.find(e=>e.organization.id===u),p=f&&f.permissions;return{userId:t,user:n,sessionId:r,session:i,sessionStatus:a,sessionClaims:o,organization:l,orgId:u,orgRole:f&&f.role,orgSlug:d,orgPermissions:p,actor:c,factorVerificationAge:s}},jo=`METHOD_CALLED`,Mo=.1;function No(e,t){return{event:jo,eventSamplingRate:Mo,payload:{method:e,...t}}}var Po=`ClerkJS:`;function Fo(){throw Error(`${Po} Clerk instance not found. Make sure Clerk is initialized before using any Clerk components.`)}var Io=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},Lo={setTimeout:(e,t)=>setTimeout(e,t),clearTimeout:e=>clearTimeout(e),setInterval:(e,t)=>setInterval(e,t),clearInterval:e=>clearInterval(e)},Ro=new class{#e=Lo;setTimeoutProvider(e){this.#e=e}setTimeout(e,t){return this.#e.setTimeout(e,t)}clearTimeout(e){this.#e.clearTimeout(e)}setInterval(e,t){return this.#e.setInterval(e,t)}clearInterval(e){this.#e.clearInterval(e)}};function zo(e){setTimeout(e,0)}var Bo=typeof window>`u`||`Deno`in globalThis;function Vo(){}function Ho(e){return typeof e==`number`&&e>=0&&e!==1/0}function Uo(e,t){return Math.max(e+(t||0)-Date.now(),0)}function Wo(e,t){return typeof e==`function`?e(t):e}function Go(e,t){return typeof e==`function`?e(t):e}var Ko=Object.prototype.hasOwnProperty;function qo(e,t){if(e===t)return e;let n=Yo(e)&&Yo(t);if(!n&&!(Xo(e)&&Xo(t)))return t;let r=(n?e:Object.keys(e)).length,i=n?t:Object.keys(t),a=i.length,o=n?Array(a):{},s=0;for(let c=0;c<a;c++){let a=n?c:i[c],l=e[a],u=t[a];if(l===u){o[a]=l,(n?c<r:Ko.call(e,a))&&s++;continue}if(l===null||u===null||typeof l!=`object`||typeof u!=`object`){o[a]=u;continue}let d=qo(l,u);o[a]=d,d===l&&s++}return r===a&&s===r?e:o}function Jo(e,t){if(!t||Object.keys(e).length!==Object.keys(t).length)return!1;for(let n in e)if(e[n]!==t[n])return!1;return!0}function Yo(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function Xo(e){if(!Zo(e))return!1;let t=e.constructor;if(t===void 0)return!0;let n=t.prototype;return!(!Zo(n)||!n.hasOwnProperty(`isPrototypeOf`)||Object.getPrototypeOf(e)!==Object.prototype)}function Zo(e){return Object.prototype.toString.call(e)===`[object Object]`}function Qo(e,t,n){return typeof n.structuralSharing==`function`?n.structuralSharing(e,t):n.structuralSharing===!1?t:qo(e,t)}function $o(e,t,n=0){let r=[...e,t];return n&&r.length>n?r.slice(1):r}function es(e,t,n=0){let r=[t,...e];return n&&r.length>n?r.slice(0,-1):r}var ts=Symbol();function ns(e,t){return!e.queryFn&&t?.initialPromise?()=>t.initialPromise:!e.queryFn||e.queryFn===ts?()=>Promise.reject(Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}function rs(e,t,n){let r=!1,i;return Object.defineProperty(e,`signal`,{enumerable:!0,get:()=>(i??=t(),r?i:(r=!0,i.aborted?n():i.addEventListener(`abort`,n,{once:!0}),i))}),e}var is=new class extends Io{#e;#t;#n;constructor(){super(),this.#n=e=>{if(!Bo&&window.addEventListener){let t=()=>e();return window.addEventListener(`visibilitychange`,t,!1),()=>{window.removeEventListener(`visibilitychange`,t)}}}}onSubscribe(){this.#t||this.setEventListener(this.#n)}onUnsubscribe(){this.hasListeners()||(this.#t?.(),this.#t=void 0)}setEventListener(e){this.#n=e,this.#t?.(),this.#t=e(e=>{typeof e==`boolean`?this.setFocused(e):this.onFocus()})}setFocused(e){this.#e!==e&&(this.#e=e,this.onFocus())}onFocus(){let e=this.isFocused();this.listeners.forEach(t=>{t(e)})}isFocused(){return typeof this.#e==`boolean`?this.#e:globalThis.document?.visibilityState!==`hidden`}};function as(){let e,t,n=new Promise((n,r)=>{e=n,t=r});n.status=`pending`,n.catch(()=>{});function r(e){Object.assign(n,e),delete n.resolve,delete n.reject}return n.resolve=t=>{r({status:`fulfilled`,value:t}),e(t)},n.reject=e=>{r({status:`rejected`,reason:e}),t(e)},n}var os=zo;function ss(){let e=[],t=0,n=e=>{e()},r=e=>{e()},i=os,a=r=>{t?e.push(r):i(()=>{n(r)})},o=()=>{let t=e;e=[],t.length&&i(()=>{r(()=>{t.forEach(e=>{n(e)})})})};return{batch:e=>{let n;t++;try{n=e()}finally{t--,t||o()}return n},batchCalls:e=>(...t)=>{a(()=>{e(...t)})},schedule:a,setNotifyFunction:e=>{n=e},setBatchNotifyFunction:e=>{r=e},setScheduler:e=>{i=e}}}var cs=ss(),ls=new class extends Io{#e=!0;#t;#n;constructor(){super(),this.#n=e=>{if(!Bo&&window.addEventListener){let t=()=>e(!0),n=()=>e(!1);return window.addEventListener(`online`,t,!1),window.addEventListener(`offline`,n,!1),()=>{window.removeEventListener(`online`,t),window.removeEventListener(`offline`,n)}}}}onSubscribe(){this.#t||this.setEventListener(this.#n)}onUnsubscribe(){this.hasListeners()||(this.#t?.(),this.#t=void 0)}setEventListener(e){this.#n=e,this.#t?.(),this.#t=e(this.setOnline.bind(this))}setOnline(e){this.#e!==e&&(this.#e=e,this.listeners.forEach(t=>{t(e)}))}isOnline(){return this.#e}};function us(e){return(e??`online`)===`online`?ls.isOnline():!0}function ds(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:us(t.networkMode)?`fetching`:`paused`,...e===void 0&&{error:null,status:`pending`}}}var fs=class extends Io{constructor(e,t){super(),this.options=t,this.#e=e,this.#s=null,this.#o=as(),this.bindMethods(),this.setOptions(t)}#e;#t=void 0;#n=void 0;#r=void 0;#i;#a;#o;#s;#c;#l;#u;#d;#f;#p;#m=new Set;bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(this.#t.addObserver(this),ms(this.#t,this.options)?this.#h():this.updateResult(),this.#y())}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return hs(this.#t,this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return hs(this.#t,this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,this.#b(),this.#x(),this.#t.removeObserver(this)}setOptions(e){let t=this.options,n=this.#t;if(this.options=this.#e.defaultQueryOptions(e),this.options.enabled!==void 0&&typeof this.options.enabled!=`boolean`&&typeof this.options.enabled!=`function`&&typeof Go(this.options.enabled,this.#t)!=`boolean`)throw Error(`Expected enabled to be a boolean or a callback that returns a boolean`);this.#S(),this.#t.setOptions(this.options),t._defaulted&&!Jo(this.options,t)&&this.#e.getQueryCache().notify({type:`observerOptionsUpdated`,query:this.#t,observer:this});let r=this.hasListeners();r&&gs(this.#t,n,this.options,t)&&this.#h(),this.updateResult(),r&&(this.#t!==n||Go(this.options.enabled,this.#t)!==Go(t.enabled,this.#t)||Wo(this.options.staleTime,this.#t)!==Wo(t.staleTime,this.#t))&&this.#g();let i=this.#_();r&&(this.#t!==n||Go(this.options.enabled,this.#t)!==Go(t.enabled,this.#t)||i!==this.#p)&&this.#v(i)}getOptimisticResult(e){let t=this.#e.getQueryCache().build(this.#e,e),n=this.createResult(t,e);return vs(this,n)&&(this.#r=n,this.#a=this.options,this.#i=this.#t.state),n}getCurrentResult(){return this.#r}trackResult(e,t){return new Proxy(e,{get:(e,n)=>(this.trackProp(n),t?.(n),n===`promise`&&(this.trackProp(`data`),!this.options.experimental_prefetchInRender&&this.#o.status===`pending`&&this.#o.reject(Error(`experimental_prefetchInRender feature flag is not enabled`))),Reflect.get(e,n))})}trackProp(e){this.#m.add(e)}getCurrentQuery(){return this.#t}refetch({...e}={}){return this.fetch({...e})}fetchOptimistic(e){let t=this.#e.defaultQueryOptions(e),n=this.#e.getQueryCache().build(this.#e,t);return n.fetch().then(()=>this.createResult(n,t))}fetch(e){return this.#h({...e,cancelRefetch:e.cancelRefetch??!0}).then(()=>(this.updateResult(),this.#r))}#h(e){this.#S();let t=this.#t.fetch(this.options,e);return e?.throwOnError||(t=t.catch(Vo)),t}#g(){this.#b();let e=Wo(this.options.staleTime,this.#t);if(Bo||this.#r.isStale||!Ho(e))return;let t=Uo(this.#r.dataUpdatedAt,e)+1;this.#d=Ro.setTimeout(()=>{this.#r.isStale||this.updateResult()},t)}#_(){return(typeof this.options.refetchInterval==`function`?this.options.refetchInterval(this.#t):this.options.refetchInterval)??!1}#v(e){this.#x(),this.#p=e,!(Bo||Go(this.options.enabled,this.#t)===!1||!Ho(this.#p)||this.#p===0)&&(this.#f=Ro.setInterval(()=>{(this.options.refetchIntervalInBackground||is.isFocused())&&this.#h()},this.#p))}#y(){this.#g(),this.#v(this.#_())}#b(){this.#d&&=(Ro.clearTimeout(this.#d),void 0)}#x(){this.#f&&=(Ro.clearInterval(this.#f),void 0)}createResult(e,t){let n=this.#t,r=this.options,i=this.#r,a=this.#i,o=this.#a,s=e===n?this.#n:e.state,{state:c}=e,l={...c},u=!1,d;if(t._optimisticResults){let i=this.hasListeners(),a=!i&&ms(e,t),o=i&&gs(e,n,t,r);(a||o)&&(l={...l,...ds(c.data,e.options)}),t._optimisticResults===`isRestoring`&&(l.fetchStatus=`idle`)}let{error:f,errorUpdatedAt:p,status:m}=l;d=l.data;let h=!1;if(t.placeholderData!==void 0&&d===void 0&&m===`pending`){let e;i?.isPlaceholderData&&t.placeholderData===o?.placeholderData?(e=i.data,h=!0):e=typeof t.placeholderData==`function`?t.placeholderData(this.#u?.state.data,this.#u):t.placeholderData,e!==void 0&&(m=`success`,d=Qo(i?.data,e,t),u=!0)}if(t.select&&d!==void 0&&!h)if(i&&d===a?.data&&t.select===this.#c)d=this.#l;else try{this.#c=t.select,d=t.select(d),d=Qo(i?.data,d,t),this.#l=d,this.#s=null}catch(e){this.#s=e}this.#s&&(f=this.#s,d=this.#l,p=Date.now(),m=`error`);let g=l.fetchStatus===`fetching`,_=m===`pending`,v=m===`error`,y=_&&g,b=d!==void 0,x={status:m,fetchStatus:l.fetchStatus,isPending:_,isSuccess:m===`success`,isError:v,isInitialLoading:y,isLoading:y,data:d,dataUpdatedAt:l.dataUpdatedAt,error:f,errorUpdatedAt:p,failureCount:l.fetchFailureCount,failureReason:l.fetchFailureReason,errorUpdateCount:l.errorUpdateCount,isFetched:l.dataUpdateCount>0||l.errorUpdateCount>0,isFetchedAfterMount:l.dataUpdateCount>s.dataUpdateCount||l.errorUpdateCount>s.errorUpdateCount,isFetching:g,isRefetching:g&&!_,isLoadingError:v&&!b,isPaused:l.fetchStatus===`paused`,isPlaceholderData:u,isRefetchError:v&&b,isStale:_s(e,t),refetch:this.refetch,promise:this.#o,isEnabled:Go(t.enabled,e)!==!1};if(this.options.experimental_prefetchInRender){let t=e=>{x.status===`error`?e.reject(x.error):x.data!==void 0&&e.resolve(x.data)},r=()=>{t(this.#o=x.promise=as())},i=this.#o;switch(i.status){case`pending`:e.queryHash===n.queryHash&&t(i);break;case`fulfilled`:(x.status===`error`||x.data!==i.value)&&r();break;case`rejected`:(x.status!==`error`||x.error!==i.reason)&&r();break}}return x}updateResult(){let e=this.#r,t=this.createResult(this.#t,this.options);this.#i=this.#t.state,this.#a=this.options,this.#i.data!==void 0&&(this.#u=this.#t),!Jo(t,e)&&(this.#r=t,this.#C({listeners:(()=>{if(!e)return!0;let{notifyOnChangeProps:t}=this.options,n=typeof t==`function`?t():t;if(n===`all`||!n&&!this.#m.size)return!0;let r=new Set(n??this.#m);return this.options.throwOnError&&r.add(`error`),Object.keys(this.#r).some(t=>{let n=t;return this.#r[n]!==e[n]&&r.has(n)})})()}))}#S(){let e=this.#e.getQueryCache().build(this.#e,this.options);if(e===this.#t)return;let t=this.#t;this.#t=e,this.#n=e.state,this.hasListeners()&&(t?.removeObserver(this),e.addObserver(this))}onQueryUpdate(){this.updateResult(),this.hasListeners()&&this.#y()}#C(e){cs.batch(()=>{e.listeners&&this.listeners.forEach(e=>{e(this.#r)}),this.#e.getQueryCache().notify({query:this.#t,type:`observerResultsUpdated`})})}};function ps(e,t){return Go(t.enabled,e)!==!1&&e.state.data===void 0&&!(e.state.status===`error`&&t.retryOnMount===!1)}function ms(e,t){return ps(e,t)||e.state.data!==void 0&&hs(e,t,t.refetchOnMount)}function hs(e,t,n){if(Go(t.enabled,e)!==!1&&Wo(t.staleTime,e)!==`static`){let r=typeof n==`function`?n(e):n;return r===`always`||r!==!1&&_s(e,t)}return!1}function gs(e,t,n,r){return(e!==t||Go(r.enabled,e)===!1)&&(!n.suspense||e.state.status!==`error`)&&_s(e,n)}function _s(e,t){return Go(t.enabled,e)!==!1&&e.isStaleByTime(Wo(t.staleTime,e))}function vs(e,t){return!Jo(e.getCurrentResult(),t)}function ys(e){return{onFetch:(t,n)=>{let r=t.options,i=t.fetchOptions?.meta?.fetchMore?.direction,a=t.state.data?.pages||[],o=t.state.data?.pageParams||[],s={pages:[],pageParams:[]},c=0,l=async()=>{let n=!1,l=e=>{rs(e,()=>t.signal,()=>n=!0)},u=ns(t.options,t.fetchOptions),d=async(e,r,i)=>{if(n)return Promise.reject();if(r==null&&e.pages.length)return Promise.resolve(e);let a=await u((()=>{let e={client:t.client,queryKey:t.queryKey,pageParam:r,direction:i?`backward`:`forward`,meta:t.options.meta};return l(e),e})()),{maxPages:o}=t.options,s=i?es:$o;return{pages:s(e.pages,a,o),pageParams:s(e.pageParams,r,o)}};if(i&&a.length){let e=i===`backward`,t=e?xs:bs,n={pages:a,pageParams:o};s=await d(n,t(r,n),e)}else{let t=e??a.length;do{let e=c===0?o[0]??r.initialPageParam:bs(r,s);if(c>0&&e==null)break;s=await d(s,e),c++}while(c<t)}return s};t.options.persister?t.fetchFn=()=>t.options.persister?.(l,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},n):t.fetchFn=l}}}function bs(e,{pages:t,pageParams:n}){let r=t.length-1;return t.length>0?e.getNextPageParam(t[r],t,n[r],n):void 0}function xs(e,{pages:t,pageParams:n}){return t.length>0?e.getPreviousPageParam?.(t[0],t,n[0],n):void 0}function Ss(e,t){return t?bs(e,t)!=null:!1}function Cs(e,t){return!t||!e.getPreviousPageParam?!1:xs(e,t)!=null}var ws=class extends fs{constructor(e,t){super(e,t)}bindMethods(){super.bindMethods(),this.fetchNextPage=this.fetchNextPage.bind(this),this.fetchPreviousPage=this.fetchPreviousPage.bind(this)}setOptions(e){super.setOptions({...e,behavior:ys()})}getOptimisticResult(e){return e.behavior=ys(),super.getOptimisticResult(e)}fetchNextPage(e){return this.fetch({...e,meta:{fetchMore:{direction:`forward`}}})}fetchPreviousPage(e){return this.fetch({...e,meta:{fetchMore:{direction:`backward`}}})}createResult(e,t){let{state:n}=e,r=super.createResult(e,t),{isFetching:i,isRefetching:a,isError:o,isRefetchError:s}=r,c=n.fetchMeta?.fetchMore?.direction,l=o&&c===`forward`,u=i&&c===`forward`,d=o&&c===`backward`,f=i&&c===`backward`;return{...r,fetchNextPage:this.fetchNextPage,fetchPreviousPage:this.fetchPreviousPage,hasNextPage:Ss(t,n.data),hasPreviousPage:Cs(t,n.data),isFetchNextPageError:l,isFetchingNextPage:u,isFetchPreviousPageError:d,isFetchingPreviousPage:f,isRefetchError:s&&!l&&!d,isRefetching:a&&!u&&!f}}},Ts=Object.prototype.hasOwnProperty;function Es(e,t,n){for(n of e.keys())if(Ds(n,t))return n}function Ds(e,t){var n,r,i;if(e===t)return!0;if(e&&t&&(n=e.constructor)===t.constructor){if(n===Date)return e.getTime()===t.getTime();if(n===RegExp)return e.toString()===t.toString();if(n===Array){if((r=e.length)===t.length)for(;r--&&Ds(e[r],t[r]););return r===-1}if(n===Set){if(e.size!==t.size)return!1;for(r of e)if(i=r,i&&typeof i==`object`&&(i=Es(t,i),!i)||!t.has(i))return!1;return!0}if(n===Map){if(e.size!==t.size)return!1;for(r of e)if(i=r[0],i&&typeof i==`object`&&(i=Es(t,i),!i)||!Ds(r[1],t.get(i)))return!1;return!0}if(n===ArrayBuffer)e=new Uint8Array(e),t=new Uint8Array(t);else if(n===DataView){if((r=e.byteLength)===t.byteLength)for(;r--&&e.getInt8(r)===t.getInt8(r););return r===-1}if(ArrayBuffer.isView(e)){if((r=e.byteLength)===t.byteLength)for(;r--&&e[r]===t[r];);return r===-1}if(!n||typeof e==`object`){for(n in r=0,e)if(Ts.call(e,n)&&++r&&!Ts.call(t,n)||!(n in t)||!Ds(e[n],t[n]))return!1;return Object.keys(t).length===r}}return e!==e&&t!==t}function Os(e,t){if(!e)throw Error(typeof t==`string`?t:`${t.displayName} not found`)}var ks=(e,t)=>{let{assertCtxFn:n=Os}=t||{},r=g.createContext(void 0);return r.displayName=e,[r,()=>{let t=g.useContext(r);return n(t,`${e} not found`),t.value},()=>{let e=g.useContext(r);return e?e.value:{}}]},[As,js]=ks(`ClerkInstanceContext`),[Ms,Ns]=ks(`InitialStateContext`);function Ps({children:e,initialState:t}){let[n]=(0,g.useState)(t),r=g.useMemo(()=>({value:n}),[n]);return g.createElement(Ms.Provider,{value:r},e)}function Fs(){let e=Ns();if(e instanceof Promise){if(`use`in g.default&&typeof g.use==`function`)return g.use(e);throw Error(`initialState cannot be a promise if React version is less than 19`)}return e}g.createContext({});var[Is,Ls]=ks(`CheckoutContext`),Rs=({children:e,...t})=>g.createElement(Is.Provider,{value:{value:t}},e);function zs(e){if(!g.useContext(As)){if(typeof e==`function`){e();return}throw Error(`${e} can only be used within the <ClerkProvider /> component.

Possible fixes:
1. Ensure that the <ClerkProvider /> is correctly wrapping your application where this component is used.
2. Check for multiple versions of the \`@clerk/shared\` package in your project. Use a tool like \`npm ls @clerk/shared\` to identify multiple versions, and update your dependencies to only rely on one.

Learn more: https://clerk.com/docs/components/clerk-provider`.trim())}}var Bs={USER_MEMBERSHIPS_KEY:`userMemberships`,USER_INVITATIONS_KEY:`userInvitations`,USER_SUGGESTIONS_KEY:`userSuggestions`,DOMAINS_KEY:`domains`,MEMBERSHIP_REQUESTS_KEY:`membershipRequests`,MEMBERSHIPS_KEY:`memberships`,INVITATIONS_KEY:`invitations`,PLANS_KEY:`billing-plans`,SUBSCRIPTION_KEY:`billing-subscription`,PAYMENT_METHODS_KEY:`billing-payment-methods`,PAYMENT_ATTEMPTS_KEY:`billing-payment-attempts`,STATEMENTS_KEY:`billing-statements`,API_KEYS_KEY:`apiKeys`,ORGANIZATION_CREATION_DEFAULTS_KEY:`organizationCreationDefaults`,OAUTH_CONSENT_INFO_KEY:`oauthConsentInfo`};function Vs(e){return{queryKey:[e.stablePrefix,e.authenticated,e.tracked,e.untracked],invalidationKey:[e.stablePrefix,e.authenticated,e.tracked],stableKey:e.stablePrefix,authenticated:e.authenticated}}function Hs(e){if(e)return function(e){return e}}function Us(e){let t=function(){},n;return n=new Proxy(t,{get(t,r){if(r!==`then`)return r===`toString`?()=>`[${e}]`:r===Symbol.toPrimitive?()=>0:n},apply(){return n},construct(){return n},has(){return!1},set(){return!1}}),n}var Ws=Us(`ClerkMockQueryClient`),Gs=()=>{let e=js(),t=e.__internal_queryClient,[,n]=(0,g.useState)(typeof t==`object`&&`__tag`in t&&t.__tag===`clerk-rq-client`);(0,g.useEffect)(()=>{let t=()=>n(!0);return e.on(`queryClientStatus`,t),()=>{e.off(`queryClientStatus`,t)}},[e,n]);let r=typeof t==`object`&&`__tag`in t&&t.__tag===`clerk-rq-client`;return[t?.client||Ws,r]};function Ks(e,t){let[n,r]=Gs(),i=r?n.defaultQueryOptions(e):e;i._optimisticResults=`optimistic`;let a=g.useMemo(()=>new t(n,i),[n]),o=a.getOptimisticResult(i),s=e.subscribed!==!1;return g.useSyncExternalStore(g.useCallback(e=>{let t=s?a.subscribe(cs.batchCalls(e)):Vo;return a.updateResult(),t},[a,s]),()=>a.getCurrentResult(),()=>a.getCurrentResult()),g.useEffect(()=>{a.setOptions(i)},[i,a]),r?i.notifyOnChangeProps?o:a.trackResult(o):{data:void 0,error:null,isLoading:!1,isFetching:!1,status:`pending`}}function qs(e){return Ks(e,ws)}function Js(e){return Ks(e,fs)}function Ys(e){let t=(0,g.useRef)(e),n=(0,g.useRef)(null);return t.current!==e&&(n.current=t.current,t.current=e),n.current}var Xs=e=>[e,`${e}-inf`];function Zs(e){let{isSignedOut:t,stableKeys:n,authenticated:r=!0,onCleanup:i}=e,a=(0,g.useRef)(n),[o]=Gs(),s=Ys(!t);(0,g.useEffect)(()=>{r===!0&&s&&t===!0&&(o.removeQueries({predicate:e=>{let[t,n]=e.queryKey;return n===!0&&typeof t==`string`&&(Array.isArray(a.current)?a.current.includes(t):a.current===t)}}),i?.())},[r,t,s,o])}var Qs=(e,t)=>{let n=typeof e==`boolean`&&e,r=(0,g.useRef)(n?t.initialPage:e?.initialPage??t.initialPage),i=(0,g.useRef)(n?t.pageSize:e?.pageSize??t.pageSize),a={};for(let r of Object.keys(t))a[r]=n?t[r]:e?.[r]??t[r];return{...a,initialPage:r.current,pageSize:i.current}};function $s(e,t){return(e-1)*t}function ec(e,t,n){return Math.ceil((e-t)/n)}function tc(e,t,n,r){return e-t>n*r}function nc(e,t,n){return(e-1)*t>n}var rc=e=>{let{fetcher:t,config:n,keys:r}=e,[i,a]=(0,g.useState)(n.initialPage??1),o=(0,g.useRef)(n.initialPage??1),s=(0,g.useRef)(n.pageSize??10),c=n.enabled??!0,l=n.isSignedIn,u=n.infinite??!1,d=n.__experimental_mode===`cache`,f=n.keepPreviousData??!1,[p]=Gs(),m=c&&!!t&&!d&&l!==!1,[h,_]=(0,g.useState)(0),v=(0,g.useCallback)(e=>{_(e)},[]),y=(0,g.useMemo)(()=>{let[e,t,n,a]=r.queryKey;return[e,t,n,{...a,args:{...a.args,initialPage:i,pageSize:s.current}}]},[r.queryKey,i]),b=Js({queryKey:y,queryFn:({queryKey:e})=>{let{args:n}=e[3];if(t)return t(n)},staleTime:6e4,enabled:m&&!u,placeholderData:Hs(f)}),x=(0,g.useMemo)(()=>{let[e,t,n,i]=r.queryKey;return[e+`-inf`,t,n,i]},[r.queryKey]),S=qs({queryKey:x,initialPageParam:n.initialPage??1,getNextPageParam:(e,t,r)=>{let i=e?.total_count??0;return(t.length+(n.initialPage?n.initialPage-1:0))*(n.pageSize??10)<i?r+1:void 0},queryFn:({pageParam:e,queryKey:n})=>{let{args:r}=n[3];if(t)return t({...r,initialPage:e,pageSize:s.current})},staleTime:6e4,enabled:m&&u});Zs({isSignedOut:l===!1,authenticated:r.authenticated,stableKeys:Xs(r.stableKey),onCleanup:()=>{a(o.current),Promise.resolve().then(()=>v(e=>e+1))}});let{data:C,count:w,page:T}=(0,g.useMemo)(()=>{if(u){let e=p.getQueryData(x),t=m?S.data?.pages??e?.pages??[]:e?.pages??[],n=Array.isArray(t)?t.filter(Boolean):[];return{data:n.map(e=>e?.data).flat().filter(Boolean)??[],count:n[n.length-1]?.total_count??0,page:n.length>0?n.length:o.current}}let e=m?b.data??p.getQueryData(y):p.getQueryData(y);return{data:Array.isArray(e?.data)?e.data:[],count:typeof e?.total_count==`number`?e.total_count:0,page:i}},[m,h,u,S.data?.pages,b.data,p,x,y,i]),E=(0,g.useCallback)(e=>{if(u){let t=typeof e==`function`?e(T):e,n=Math.max(0,t),r=p.getQueryData(x);n-(S.data?.pages??r?.pages??[]).length>0&&S.fetchNextPage({cancelRefetch:!1});return}return a(e)},[S,T,u,p,x]),D=u?S.isLoading:b.isLoading,O=u?S.isFetching:b.isFetching,ee=(u?S.error:b.error)??null,te=!!ee,ne=(0,g.useCallback)(()=>{if(u){S.fetchNextPage({cancelRefetch:!1});return}a(e=>Math.max(0,e+1))},[S,u]),re=(0,g.useCallback)(()=>{u||a(e=>Math.max(0,e-1))},[u]),ie=$s(o.current,s.current);return{data:C,count:w,error:ee,isLoading:D,isFetching:O,isError:te,page:T,pageCount:ec(w,ie,s.current),fetchPage:E,fetchNext:ne,fetchPrevious:re,hasNextPage:u?!!S.hasNextPage:tc(w,ie,T,s.current),hasPreviousPage:u?!!S.hasPreviousPage:nc(T,s.current,ie),revalidate:async()=>{await p.invalidateQueries({queryKey:r.invalidationKey});let[e,...t]=r.invalidationKey;return p.invalidateQueries({queryKey:[e+`-inf`,...t]})},setData:e=>u?(p.setQueryData(x,(t={})=>{let n=Array.isArray(t?.pages)?t.pages:[],r=typeof e==`function`?e(n):e;return{...t,pages:r}}),v(e=>e+1),Promise.resolve()):(p.setQueryData(y,(t={data:[],total_count:0})=>typeof e==`function`?e(t):e),v(e=>e+1),Promise.resolve())}};function ic(){let e=js(),t=Fs(),n=(0,g.useCallback)(()=>t?.user,[t?.user]);return(0,g.useSyncExternalStore)((0,g.useCallback)(t=>e.addListener(t,{skipInitialEmit:!0}),[e]),(0,g.useCallback)(()=>!e.loaded||!e.__internal_lastEmittedResources?n():e.__internal_lastEmittedResources.user,[e,n]),n)}function ac(){let e=js(),t=Fs(),n=(0,g.useCallback)(()=>t?.organization,[t?.organization]);return(0,g.useSyncExternalStore)((0,g.useCallback)(t=>e.addListener(t,{skipInitialEmit:!0}),[e]),(0,g.useCallback)(()=>!e.loaded||!e.__internal_lastEmittedResources?n():e.__internal_lastEmittedResources.organization,[e,n]),n)}typeof window<`u`?g.useLayoutEffect:g.useEffect;var oc=`useUser`;function sc(){zs(oc);let e=ic();return js().telemetry?.record(No(oc)),e===void 0?{isLoaded:!1,isSignedIn:void 0,user:void 0}:e===null?{isLoaded:!0,isSignedIn:!1,user:null}:{isLoaded:!0,isSignedIn:!0,user:e}}var cc=Ds;function lc(e){let t=js(),n=e?.enabled??!0,r=t.__internal_environment,i=ic(),a=ac(),o=r?.commerceSettings.billing.user.enabled,s=r?.commerceSettings.billing.organization.enabled,c=e?.for===`organization`?s:e?.for===`user`?o:o||s,l=e?.for===`organization`,u=e?.authenticated??!0?(l?!!a?.id:!0)&&!!i?.id:!0;return c&&n&&t.loaded&&u}function uc({hookName:e,resourceType:t,useFetcher:n,options:r}){return function(i){let{for:a,enabled:o,...s}=i||{},c=a||`user`;zs(e);let l=n(c),u=Qs(s,{initialPage:1,pageSize:10,keepPreviousData:!1,infinite:!1,__experimental_mode:void 0}),d=js(),f=ic(),p=ac();d.telemetry?.record(No(e));let m=c===`organization`,h=lc({for:c,enabled:o,authenticated:!r?.unauthenticated}),g=s===void 0?void 0:{initialPage:u.initialPage,pageSize:u.pageSize,...r?.unauthenticated?{}:m?{orgId:p?.id}:{}},_=!!g&&d.loaded&&!!h;return rc({fetcher:l,config:{keepPreviousData:u.keepPreviousData,infinite:u.infinite,enabled:_,...r?.unauthenticated?{}:{isSignedIn:f!==null},__experimental_mode:u.__experimental_mode,initialPage:u.initialPage,pageSize:u.pageSize},keys:Vs({stablePrefix:t,authenticated:!r?.unauthenticated,tracked:r?.unauthenticated?{for:c}:{userId:f?.id,...m?{orgId:p?.id}:{}},untracked:{args:g}})})}}uc({hookName:`useStatements`,resourceType:Bs.STATEMENTS_KEY,useFetcher:()=>{let e=js();if(e.loaded)return e.billing.getStatements}}),uc({hookName:`usePaymentAttempts`,resourceType:Bs.PAYMENT_ATTEMPTS_KEY,useFetcher:()=>{let e=js();if(e.loaded)return e.billing.getPaymentAttempts}}),uc({hookName:`usePaymentMethods`,resourceType:Bs.PAYMENT_METHODS_KEY,useFetcher:e=>{let t=ac(),n=ic();return e===`organization`?t?.getPaymentMethods:n?.getPaymentMethods}}),uc({hookName:`usePlans`,resourceType:Bs.PLANS_KEY,useFetcher:e=>{let t=js();if(t.loaded)return n=>t.billing.getPlans({...n,for:e})},options:{unauthenticated:!0}});function dc(e){e||Fo()}function fc(e){let t=e.clerk;if(dc(t),e.initialState instanceof Promise&&!(`use`in g.default&&typeof g.use==`function`))throw Error(`initialState cannot be a promise if React version is less than 19`);let n=g.useMemo(()=>({value:t}),[e.clerkStatus]);return g.createElement(Ps,{initialState:e.initialState},g.createElement(As.Provider,{value:n},g.createElement(Rs,{value:void 0},e.children)))}var pc=e=>{let t=(0,g.useRef)(e);return(0,g.useEffect)(()=>{t.current=e},[e]),t.current},mc=(e,t,n)=>{let r=!!n,i=(0,g.useRef)(n);(0,g.useEffect)(()=>{i.current=n},[n]),(0,g.useEffect)(()=>{if(!r||!e)return()=>{};let n=(...e)=>{i.current&&i.current(...e)};return e.on(t,n),()=>{e.off(t,n)}},[r,t,e,i])},hc=g.createContext(null);hc.displayName=`ElementsContext`;var gc=(e,t)=>{if(!e)throw Error(`Could not find Elements context; You need to wrap the part of your app that ${t} in an <Elements> provider.`);return e},_c=e=>typeof e==`object`&&!!e,vc=(e,t,n)=>_c(e)?Object.keys(e).reduce((r,i)=>{let a=!_c(t)||!bc(e[i],t[i]);return n.includes(i)?(a&&console.warn(`Unsupported prop change: options.${i} is not a mutable property.`),r):a?{...r||{},[i]:e[i]}:r},null):null,yc=`[object Object]`,bc=(e,t)=>{if(!_c(e)||!_c(t))return e===t;let n=Array.isArray(e);if(n!==Array.isArray(t))return!1;let r=Object.prototype.toString.call(e)===yc;if(r!==(Object.prototype.toString.call(t)===yc))return!1;if(!r&&!n)return e===t;let i=Object.keys(e),a=Object.keys(t);if(i.length!==a.length)return!1;let o={};for(let e=0;e<i.length;e+=1)o[i[e]]=!0;for(let e=0;e<a.length;e+=1)o[a[e]]=!0;let s=Object.keys(o);if(s.length!==i.length)return!1;let c=e,l=t;return s.every(e=>bc(c[e],l[e]))},xc=e=>gc(g.useContext(hc),e),Sc=e=>e.charAt(0).toUpperCase()+e.slice(1);((e,t)=>{let n=`${Sc(e)}Element`,r=t?e=>{xc(`mounts <${n}>`);let{id:t,className:r}=e;return g.createElement(`div`,{id:t,className:r})}:({id:t,className:r,fallback:i,options:a={},onBlur:o,onFocus:s,onReady:c,onChange:l,onEscape:u,onClick:d,onLoadError:f,onLoaderStart:p,onNetworksChange:m,onConfirm:h,onCancel:_,onShippingAddressChange:v,onShippingRateChange:y})=>{let b=xc(`mounts <${n}>`),x=`elements`in b?b.elements:null,[S,C]=g.useState(null),w=g.useRef(null),T=g.useRef(null),[E,D]=(0,g.useState)(!1);mc(S,`blur`,o),mc(S,`focus`,s),mc(S,`escape`,u),mc(S,`click`,d),mc(S,`loaderror`,f),mc(S,`loaderstart`,p),mc(S,`networkschange`,m),mc(S,`confirm`,h),mc(S,`cancel`,_),mc(S,`shippingaddresschange`,v),mc(S,`shippingratechange`,y),mc(S,`change`,l);let O;c&&(O=()=>{D(!0),c(S)}),mc(S,`ready`,O),g.useLayoutEffect(()=>{if(w.current===null&&T.current!==null&&x){let t=null;x&&(t=x.create(e,a)),w.current=t,C(t),t&&t.mount(T.current)}},[x,a]);let ee=pc(a);return g.useEffect(()=>{if(!w.current)return;let e=vc(a,ee,[`paymentRequest`]);e&&`update`in w.current&&w.current.update(e)},[a,ee]),g.useLayoutEffect(()=>()=>{if(w.current&&typeof w.current.destroy==`function`)try{w.current.destroy(),w.current=null}catch{}},[]),g.createElement(g.Fragment,null,!E&&i,g.createElement(`div`,{id:t,style:{height:E?`unset`:`0px`,visibility:E?`visible`:`hidden`},className:r,ref:T}))};return r.displayName=n,r.__elementType=e,r})(`payment`,typeof window>`u`);var[Cc,wc]=ks(`PaymentElementContext`),[Tc,Ec]=ks(`StripeUtilsContext`),[Dc,,Oc]=ks(`PortalProvider`),kc=({children:e,getContainer:t})=>{let n=g.useMemo(()=>({value:{getContainer:t}}),[t]);return g.createElement(Dc.Provider,{value:n},e)};kc.displayName=`UNSAFE_PortalProvider`;var Ac=()=>{let e=Oc();return e&&`getContainer`in e&&e.getContainer?e.getContainer:()=>null},jc=no({packageName:`@clerk/react`});function Mc(e){jc.setMessages(e).setPackageName(e)}var Nc=js,Pc=e=>{zs(()=>{jc.throwMissingClerkProviderError({source:e})})},Fc=()=>{try{return!1}catch{}return!1},Ic=()=>{try{return!1}catch{}return!1},Lc=()=>{try{return!0}catch{}return!1};function Rc(e,t,n){if(typeof e==`function`)return e(t);if(e!==void 0)return e;if(n!==void 0)return n}var zc=e=>{Fc()&&console.error(`Clerk: ${e}`)},Bc=e=>!!e?.cloudflare?.env,Vc=e=>!!e?.env,Hc=(e,t)=>{if(typeof process<`u`&&typeof{}[e]==`string`)return{}[e];if(typeof{BASE_URL:`/`,DEV:!1,MODE:`production`,PROD:!0,SSR:!1,VITE_CLERK_PUBLISHABLE_KEY:`pk_live_Y2xlcmsuY2F1dGlvbmxhYnMuY29tJA`,VITE_SANITY_DATASET:`production`,VITE_SANITY_PROJECT_ID:`f1tnubeb`}[e]==`string`)return{BASE_URL:`/`,DEV:!1,MODE:`production`,PROD:!0,SSR:!1,VITE_CLERK_PUBLISHABLE_KEY:`pk_live_Y2xlcmsuY2F1dGlvbmxhYnMuY29tJA`,VITE_SANITY_DATASET:`production`,VITE_SANITY_PROJECT_ID:`f1tnubeb`}[e];if(Bc(t))return t.cloudflare.env[e]||``;if(Vc(t))return t.env[e]||``;if(t&&typeof t[e]==`string`)return t[e];try{return globalThis[e]}catch{}return``},Uc=(e,...t)=>{let n={...e};for(let e of t)delete n[e];return n};function R(){return typeof window<`u`}new RegExp(`bot.spider.crawl.APIs-Google.AdsBot.Googlebot.mediapartners.Google Favicon.FeedFetcher.Google-Read-Aloud.DuplexWeb-Google.googleweblight.bing.yandex.baidu.duckduck.yahoo.ecosia.ia_archiver.facebook.instagram.pinterest.reddit.slack.twitter.whatsapp.youtube.semrush`.split(`.`).join(`|`),`i`);var Wc=`You've added multiple <ClerkProvider> components in your React component tree. Wrap your components in a single <ClerkProvider>.`,Gc=e=>`You've passed multiple children components to <${e}/>. You can only pass a single child component or text.`,Kc=`Invalid state. Feel free to submit a bug or reach out to support here: https://clerk.com/support`,qc=`Unsupported usage of isSatellite, domain or proxyUrl. The usage of isSatellite, domain or proxyUrl as function is not supported in non-browser environments.`,Jc="<UserProfile.Page /> component needs to be a direct child of `<UserProfile />` or `<UserButton />`.",Yc="<UserProfile.Link /> component needs to be a direct child of `<UserProfile />` or `<UserButton />`.",Xc="<OrganizationProfile.Page /> component needs to be a direct child of `<OrganizationProfile />` or `<OrganizationSwitcher />`.",Zc="<OrganizationProfile.Link /> component needs to be a direct child of `<OrganizationProfile />` or `<OrganizationSwitcher />`.",Qc=e=>`<${e} /> can only accept <${e}.Page /> and <${e}.Link /> as its children. Any other provided component will be ignored. Additionally, please ensure that the component is rendered in a client component.`,$c=e=>`Missing props. <${e}.Page /> component requires the following props: url, label, labelIcon, alongside with children to be rendered inside the page.`,el=e=>`Missing props. <${e}.Link /> component requires the following props: url, label and labelIcon.`,tl=`<UserButton /> can only accept <UserButton.UserProfilePage />, <UserButton.UserProfileLink /> and <UserButton.MenuItems /> as its children. Any other provided component will be ignored. Additionally, please ensure that the component is rendered in a client component.`,nl=`<UserButton.MenuItems /> component can only accept <UserButton.Action /> and <UserButton.Link /> as its children. Any other provided component will be ignored. Additionally, please ensure that the component is rendered in a client component.`,rl="<UserButton.MenuItems /> component needs to be a direct child of `<UserButton />`.",il="<UserButton.Action /> component needs to be a direct child of `<UserButton.MenuItems />`.",al="<UserButton.Link /> component needs to be a direct child of `<UserButton.MenuItems />`.",ol=`Missing props. <UserButton.Link /> component requires the following props: href, label and labelIcon.`,sl=`Missing props. <UserButton.Action /> component requires the following props: label.`,cl=e=>t=>{try{return g.Children.only(e)}catch{return jc.throw(Gc(t))}},ll=(e,t)=>(e||=t,typeof e==`string`&&(e=g.createElement(`button`,null,e)),e),ul=e=>(...t)=>{if(e&&typeof e==`function`)return e(...t)},dl=e=>Hc(`VITE_${e}`)||Hc(e),fl=(e,t)=>e===void 0?dl(t)||void 0:e,pl=e=>{let t=fl(e.publishableKey,`CLERK_PUBLISHABLE_KEY`);return{...e,...t!==void 0&&{publishableKey:t}}};function ml(e){return typeof e==`function`}var hl=new Map;function gl(e,t,n=1){g.useEffect(()=>{let r=hl.get(e)||0;return r==n?jc.throw(t):(hl.set(e,r+1),()=>{hl.set(e,(hl.get(e)||1)-1)})},[])}function _l(e,t,n){let r=e.displayName||e.name||t||`Component`,i=r=>(gl(t,n),g.createElement(e,{...r}));return i.displayName=`withMaxAllowedInstancesGuard(${r})`,i}var vl=e=>{let[t,n]=(0,g.useState)(new Map);return e.map(e=>({id:e.id,mount:t=>n(n=>new Map(n).set(String(e.id),t)),unmount:()=>n(t=>{let n=new Map(t);return n.set(String(e.id),null),n}),portal:()=>{let n=t.get(String(e.id));return n?(0,ze.createPortal)(e.component,n):null}}))},yl=(e,t)=>!!e&&g.isValidElement(e)&&e?.type===t,bl=(e,t)=>Cl({children:e,reorderItemsLabels:[`account`,`security`,`billing`,`apiKeys`],LinkComponent:Bl,PageComponent:zl,MenuItemsComponent:Wl,componentName:`UserProfile`},t),xl=(e,t)=>Cl({children:e,reorderItemsLabels:[`general`,`members`,`billing`,`apiKeys`],LinkComponent:Kl,PageComponent:U,componentName:`OrganizationProfile`},t),Sl=e=>{let t=[],n=[Kl,U,Wl,zl,Bl];return g.Children.forEach(e,e=>{n.some(t=>yl(e,t))||t.push(e)}),t},Cl=(e,t)=>{let{children:n,LinkComponent:r,PageComponent:i,MenuItemsComponent:a,reorderItemsLabels:o,componentName:s}=e,{allowForAnyChildren:c=!1}=t||{},l=[];g.Children.forEach(n,e=>{if(!yl(e,i)&&!yl(e,r)&&!yl(e,a)){e&&!c&&zc(Qc(s));return}let{props:t}=e,{children:n,label:u,url:d,labelIcon:f}=t;if(yl(e,i))if(wl(t,o))l.push({label:u});else if(Tl(t))l.push({label:u,labelIcon:f,children:n,url:d});else{zc($c(s));return}if(yl(e,r))if(El(t))l.push({label:u,labelIcon:f,url:d});else{zc(el(s));return}});let u=[],d=[],f=[];l.forEach((e,t)=>{if(Tl(e)){u.push({component:e.children,id:t}),d.push({component:e.labelIcon,id:t});return}El(e)&&f.push({component:e.labelIcon,id:t})});let p=vl(u),m=vl(d),h=vl(f),_=[],v=[];return l.forEach((e,t)=>{if(wl(e,o)){_.push({label:e.label});return}if(Tl(e)){let{portal:n,mount:r,unmount:i}=p.find(e=>e.id===t),{portal:a,mount:o,unmount:s}=m.find(e=>e.id===t);_.push({label:e.label,url:e.url,mount:r,unmount:i,mountIcon:o,unmountIcon:s}),v.push(n),v.push(a);return}if(El(e)){let{portal:n,mount:r,unmount:i}=h.find(e=>e.id===t);_.push({label:e.label,url:e.url,mountIcon:r,unmountIcon:i}),v.push(n);return}}),{customPages:_,customPagesPortals:v}},wl=(e,t)=>{let{children:n,label:r,url:i,labelIcon:a}=e;return!n&&!i&&!a&&t.some(e=>e===r)},Tl=e=>{let{children:t,label:n,url:r,labelIcon:i}=e;return!!t&&!!r&&!!i&&!!n},El=e=>{let{children:t,label:n,url:r,labelIcon:i}=e;return!t&&!!r&&!!i&&!!n},Dl=(e,t)=>Ol({children:e,reorderItemsLabels:[`manageAccount`,`signOut`],MenuItemsComponent:Wl,MenuActionComponent:B,MenuLinkComponent:Gl,UserProfileLinkComponent:Bl,UserProfilePageComponent:zl,allowForAnyChildren:t?.allowForAnyChildren??!1}),Ol=({children:e,MenuItemsComponent:t,MenuActionComponent:n,MenuLinkComponent:r,UserProfileLinkComponent:i,UserProfilePageComponent:a,reorderItemsLabels:o,allowForAnyChildren:s=!1})=>{let c=[],l=[],u=[];g.Children.forEach(e,e=>{if(!yl(e,t)&&!yl(e,i)&&!yl(e,a)){e&&!s&&zc(tl);return}if(yl(e,i)||yl(e,a))return;let{props:l}=e;g.Children.forEach(l.children,e=>{if(!yl(e,n)&&!yl(e,r)){e&&zc(nl);return}let{props:t}=e,{label:i,labelIcon:a,href:s,onClick:l,open:u}=t;if(yl(e,n))if(kl(t,o))c.push({label:i});else if(Al(t)){let e={label:i,labelIcon:a};if(l!==void 0)c.push({...e,onClick:l});else if(u!==void 0)c.push({...e,open:u.startsWith(`/`)?u:`/${u}`});else{zc(`Custom menu item must have either onClick or open property`);return}}else{zc(sl);return}if(yl(e,r))if(jl(t))c.push({label:i,labelIcon:a,href:s});else{zc(ol);return}})});let d=[],f=[];c.forEach((e,t)=>{Al(e)&&d.push({component:e.labelIcon,id:t}),jl(e)&&f.push({component:e.labelIcon,id:t})});let p=vl(d),m=vl(f);return c.forEach((e,t)=>{if(kl(e,o)&&l.push({label:e.label}),Al(e)){let{portal:n,mount:r,unmount:i}=p.find(e=>e.id===t),a={label:e.label,mountIcon:r,unmountIcon:i};`onClick`in e?a.onClick=e.onClick:`open`in e&&(a.open=e.open),l.push(a),u.push(n)}if(jl(e)){let{portal:n,mount:r,unmount:i}=m.find(e=>e.id===t);l.push({label:e.label,href:e.href,mountIcon:r,unmountIcon:i}),u.push(n)}}),{customMenuItems:l,customMenuItemsPortals:u}},kl=(e,t)=>{let{children:n,label:r,onClick:i,labelIcon:a}=e;return!n&&!i&&!a&&t.some(e=>e===r)},Al=e=>{let{label:t,labelIcon:n,onClick:r,open:i}=e;return!!n&&!!t&&(typeof r==`function`||typeof i==`string`)},jl=e=>{let{label:t,href:n,labelIcon:r}=e;return!!n&&!!r&&!!t},Ml=(e=>{let t=e?.isReady;return n=>new Promise((r,i)=>{let{root:a=document==null?void 0:document.body,selector:o,timeout:s=0}=n;if(!a){i(Error(`No root element provided`));return}let c=a;if(o&&(c=a?.querySelector(o)),t(c,o)){r();return}let l=new MutationObserver(n=>{for(let i of n)if(!c&&o&&(c=a?.querySelector(o)),(e.childList&&i.type===`childList`||e.attributes&&i.type===`attributes`)&&t(c,o)){l.disconnect(),r();return}});l.observe(a,e),s>0&&setTimeout(()=>{l.disconnect(),i(Error(`Timeout waiting for ${o}`))},s)})})({childList:!0,subtree:!0,isReady:(e,t)=>!!e?.childElementCount&&(e?.matches)?.call(e,t)&&e.childElementCount>0});function Nl(e,t){let n=(0,g.useRef)(),[r,i]=(0,g.useState)(`rendering`);return(0,g.useEffect)(()=>{if(!e)throw Error(`Clerk: no component name provided, unable to detect mount.`);if(typeof window<`u`&&!n.current){let r=`[data-clerk-component="${e}"]`,a=t?.selector;n.current=Ml({selector:a?r+a:r}).then(()=>{i(`rendered`)}).catch(()=>{i(`error`)})}},[e,t?.selector]),r}var Pl=e=>`mount`in e,Fl=e=>`open`in e,Il=e=>e?.map(({mountIcon:e,unmountIcon:t,...n})=>n),Ll=class extends g.PureComponent{constructor(){super(...arguments),this.rootRef=g.createRef()}componentDidUpdate(e){if(!Pl(e)||!Pl(this.props))return;let t=Uc(e.props,`customPages`,`customMenuItems`,`children`),n=Uc(this.props.props,`customPages`,`customMenuItems`,`children`),r=t.customPages?.length!==n.customPages?.length,i=t.customMenuItems?.length!==n.customMenuItems?.length,a=Il(e.props.customMenuItems),o=Il(this.props.props.customMenuItems);(!cc(t,n)||!cc(a,o)||r||i)&&this.rootRef.current&&this.props.updateProps({node:this.rootRef.current,props:this.props.props})}componentDidMount(){this.rootRef.current&&(Pl(this.props)&&this.props.mount(this.rootRef.current,this.props.props),Fl(this.props)&&this.props.open(this.props.props))}componentWillUnmount(){this.rootRef.current&&(Pl(this.props)&&this.props.unmount(this.rootRef.current),Fl(this.props)&&this.props.close())}render(){let{hideRootHtmlElement:e=!1}=this.props,t={ref:this.rootRef,...this.props.rootProps,...this.props.component&&{"data-clerk-component":this.props.component}};return g.createElement(g.Fragment,null,!e&&g.createElement(`div`,{...t}),this.props.children)}},z=(e,t)=>{let n=(typeof t==`string`?t:t?.component)||e.displayName||e.name||`Component`;e.displayName=n;let r=typeof t==`string`?void 0:t,i=t=>{Pc(n||`withClerk`);let i=Nc(),a=Ac();return!i.loaded&&!r?.renderWhileLoading?null:g.createElement(e,{getContainer:a,...t,component:n,clerk:i})};return i.displayName=`withClerk(${n})`,i},Rl=e=>g.createElement(g.Fragment,null,(e?.customPagesPortals)?.map((e,t)=>(0,g.createElement)(e,{key:t})),(e?.customMenuItemsPortals)?.map((e,t)=>(0,g.createElement)(e,{key:t})));z(({clerk:e,component:t,fallback:n,...r})=>{let i=Nl(t)===`rendering`||!e.loaded,a={...i&&n&&{style:{display:`none`}}};return g.createElement(g.Fragment,null,i&&n,e.loaded&&g.createElement(Ll,{component:t,mount:e.mountSignIn,unmount:e.unmountSignIn,updateProps:e.__internal_updateProps,props:r,rootProps:a}))},{component:`SignIn`,renderWhileLoading:!0}),z(({clerk:e,component:t,fallback:n,...r})=>{let i=Nl(t)===`rendering`||!e.loaded,a={...i&&n&&{style:{display:`none`}}};return g.createElement(g.Fragment,null,i&&n,e.loaded&&g.createElement(Ll,{component:t,mount:e.mountSignUp,unmount:e.unmountSignUp,updateProps:e.__internal_updateProps,props:r,rootProps:a}))},{component:`SignUp`,renderWhileLoading:!0});function zl({children:e}){return zc(Jc),g.createElement(g.Fragment,null,e)}function Bl({children:e}){return zc(Yc),g.createElement(g.Fragment,null,e)}var Vl=z(({clerk:e,component:t,fallback:n,...r})=>{let i=Nl(t)===`rendering`||!e.loaded,a={...i&&n&&{style:{display:`none`}}},{customPages:o,customPagesPortals:s}=bl(r.children);return g.createElement(g.Fragment,null,i&&n,g.createElement(Ll,{component:t,mount:e.mountUserProfile,unmount:e.unmountUserProfile,updateProps:e.__internal_updateProps,props:{...r,customPages:o},rootProps:a},g.createElement(Rl,{customPagesPortals:s})))},{component:`UserProfile`,renderWhileLoading:!0});Object.assign(Vl,{Page:zl,Link:Bl});var Hl=(0,g.createContext)({mount:()=>{},unmount:()=>{},updateProps:()=>{}}),Ul=z(({clerk:e,component:t,fallback:n,...r})=>{let i=Nl(t)===`rendering`||!e.loaded,a={...i&&n&&{style:{display:`none`}}},{customPages:o,customPagesPortals:s}=bl(r.children,{allowForAnyChildren:!!r.__experimental_asProvider}),c={...r.userProfileProps,customPages:o},{customMenuItems:l,customMenuItemsPortals:u}=Dl(r.children,{allowForAnyChildren:!!r.__experimental_asProvider}),d=Sl(r.children),f={mount:e.mountUserButton,unmount:e.unmountUserButton,updateProps:e.__internal_updateProps,props:{...r,userProfileProps:c,customMenuItems:l}},p={customPagesPortals:s,customMenuItemsPortals:u};return g.createElement(Hl.Provider,{value:f},i&&n,e.loaded&&g.createElement(Ll,{component:t,...f,hideRootHtmlElement:!!r.__experimental_asProvider,rootProps:a},r.__experimental_asProvider?d:null,g.createElement(Rl,{...p})))},{component:`UserButton`,renderWhileLoading:!0});function Wl({children:e}){return zc(rl),g.createElement(g.Fragment,null,e)}function B({children:e}){return zc(il),g.createElement(g.Fragment,null,e)}function Gl({children:e}){return zc(al),g.createElement(g.Fragment,null,e)}function V(e){let t=(0,g.useContext)(Hl),n={...t,props:{...t.props,...e}};return g.createElement(Ll,{...n})}var H=Object.assign(Ul,{UserProfilePage:zl,UserProfileLink:Bl,MenuItems:Wl,Action:B,Link:Gl,__experimental_Outlet:V});function U({children:e}){return zc(Xc),g.createElement(g.Fragment,null,e)}function Kl({children:e}){return zc(Zc),g.createElement(g.Fragment,null,e)}var ql=z(({clerk:e,component:t,fallback:n,...r})=>{let i=Nl(t)===`rendering`||!e.loaded,a={...i&&n&&{style:{display:`none`}}},{customPages:o,customPagesPortals:s}=xl(r.children);return g.createElement(g.Fragment,null,i&&n,e.loaded&&g.createElement(Ll,{component:t,mount:e.mountOrganizationProfile,unmount:e.unmountOrganizationProfile,updateProps:e.__internal_updateProps,props:{...r,customPages:o},rootProps:a},g.createElement(Rl,{customPagesPortals:s})))},{component:`OrganizationProfile`,renderWhileLoading:!0});Object.assign(ql,{Page:U,Link:Kl}),z(({clerk:e,component:t,fallback:n,...r})=>{let i=Nl(t)===`rendering`||!e.loaded,a={...i&&n&&{style:{display:`none`}}};return g.createElement(g.Fragment,null,i&&n,e.loaded&&g.createElement(Ll,{component:t,mount:e.mountCreateOrganization,unmount:e.unmountCreateOrganization,updateProps:e.__internal_updateProps,props:r,rootProps:a}))},{component:`CreateOrganization`,renderWhileLoading:!0});var Jl=(0,g.createContext)({mount:()=>{},unmount:()=>{},updateProps:()=>{}}),Yl=z(({clerk:e,component:t,fallback:n,...r})=>{let i=Nl(t)===`rendering`||!e.loaded,a={...i&&n&&{style:{display:`none`}}},{customPages:o,customPagesPortals:s}=xl(r.children,{allowForAnyChildren:!!r.__experimental_asProvider}),c={...r.organizationProfileProps,customPages:o},l=Sl(r.children),u={mount:e.mountOrganizationSwitcher,unmount:e.unmountOrganizationSwitcher,updateProps:e.__internal_updateProps,props:{...r,organizationProfileProps:c},rootProps:a,component:t};return e.__experimental_prefetchOrganizationSwitcher(),g.createElement(Jl.Provider,{value:u},g.createElement(g.Fragment,null,i&&n,e.loaded&&g.createElement(Ll,{...u,hideRootHtmlElement:!!r.__experimental_asProvider},r.__experimental_asProvider?l:null,g.createElement(Rl,{customPagesPortals:s}))))},{component:`OrganizationSwitcher`,renderWhileLoading:!0});function Xl(e){let t=(0,g.useContext)(Jl),n={...t,props:{...t.props,...e}};return g.createElement(Ll,{...n})}Object.assign(Yl,{OrganizationProfilePage:U,OrganizationProfileLink:Kl,__experimental_Outlet:Xl}),z(({clerk:e,component:t,fallback:n,...r})=>{let i=Nl(t)===`rendering`||!e.loaded,a={...i&&n&&{style:{display:`none`}}};return g.createElement(g.Fragment,null,i&&n,e.loaded&&g.createElement(Ll,{component:t,mount:e.mountOrganizationList,unmount:e.unmountOrganizationList,updateProps:e.__internal_updateProps,props:r,rootProps:a}))},{component:`OrganizationList`,renderWhileLoading:!0}),z(({clerk:e,component:t,fallback:n,...r})=>{let i=Nl(t)===`rendering`||!e.loaded,a={...i&&n&&{style:{display:`none`}}};return g.createElement(g.Fragment,null,i&&n,e.loaded&&g.createElement(Ll,{component:t,open:e.openGoogleOneTap,close:e.closeGoogleOneTap,updateProps:e.__internal_updateProps,props:r,rootProps:a}))},{component:`GoogleOneTap`,renderWhileLoading:!0}),z(({clerk:e,component:t,fallback:n,...r})=>{let i=Nl(t)===`rendering`||!e.loaded,a={...i&&n&&{style:{display:`none`}}};return g.createElement(g.Fragment,null,i&&n,e.loaded&&g.createElement(Ll,{component:t,mount:e.mountWaitlist,unmount:e.unmountWaitlist,updateProps:e.__internal_updateProps,props:r,rootProps:a}))},{component:`Waitlist`,renderWhileLoading:!0}),z(({clerk:e,component:t,fallback:n,...r})=>{let i=Nl(t,{selector:`[data-component-status="ready"]`})===`rendering`||!e.loaded,a={...i&&n&&{style:{display:`none`}}};return g.createElement(g.Fragment,null,i&&n,e.loaded&&g.createElement(Ll,{component:t,mount:e.mountPricingTable,unmount:e.unmountPricingTable,updateProps:e.__internal_updateProps,props:r,rootProps:a}))},{component:`PricingTable`,renderWhileLoading:!0}),z(({clerk:e,component:t,fallback:n,...r})=>{let i=Nl(t)===`rendering`||!e.loaded,a={...i&&n&&{style:{display:`none`}}};return g.createElement(g.Fragment,null,i&&n,e.loaded&&g.createElement(Ll,{component:t,mount:e.mountAPIKeys,unmount:e.unmountAPIKeys,updateProps:e.__internal_updateProps,props:r,rootProps:a}))},{component:`ApiKeys`,renderWhileLoading:!0}),z(({clerk:e,component:t,fallback:n,...r})=>{let i=Nl(t)===`rendering`||!e.loaded,a={...i&&n&&{style:{display:`none`}}};return g.createElement(g.Fragment,null,i&&n,e.loaded&&g.createElement(Ll,{component:t,mount:e.__internal_mountOAuthConsent,unmount:e.__internal_unmountOAuthConsent,updateProps:e.__internal_updateProps,props:r,rootProps:a}))},{component:`OAuthConsent`,renderWhileLoading:!0}),z(({clerk:e,component:t,fallback:n,...r})=>{let i=Nl(t)===`rendering`||!e.loaded,a={...i&&n&&{style:{display:`none`}}};return g.createElement(g.Fragment,null,i&&n,e.loaded&&g.createElement(Ll,{component:t,mount:e.mountUserAvatar,unmount:e.unmountUserAvatar,updateProps:e.__internal_updateProps,props:r,rootProps:a}))},{component:`UserAvatar`,renderWhileLoading:!0}),z(({clerk:e,component:t,fallback:n,...r})=>{let i=Nl(t)===`rendering`||!e.loaded,a={...i&&n&&{style:{display:`none`}}};return g.createElement(g.Fragment,null,i&&n,e.loaded&&g.createElement(Ll,{component:t,mount:e.mountTaskChooseOrganization,unmount:e.unmountTaskChooseOrganization,updateProps:e.__internal_updateProps,props:r,rootProps:a}))},{component:`TaskChooseOrganization`,renderWhileLoading:!0}),z(({clerk:e,component:t,fallback:n,...r})=>{let i=Nl(t)===`rendering`||!e.loaded,a={...i&&n&&{style:{display:`none`}}};return g.createElement(g.Fragment,null,i&&n,e.loaded&&g.createElement(Ll,{component:t,mount:e.mountTaskResetPassword,unmount:e.unmountTaskResetPassword,updateProps:e.__internal_updateProps,props:r,rootProps:a}))},{component:`TaskResetPassword`,renderWhileLoading:!0}),z(({clerk:e,component:t,fallback:n,...r})=>{let i=Nl(t)===`rendering`||!e.loaded,a={...i&&n&&{style:{display:`none`}}};return g.createElement(g.Fragment,null,i&&n,e.loaded&&g.createElement(Ll,{component:t,mount:e.mountTaskSetupMFA,unmount:e.unmountTaskSetupMFA,updateProps:e.__internal_updateProps,props:r,rootProps:a}))},{component:`TaskSetupMFA`,renderWhileLoading:!0});var Zl={actor:void 0,factorVerificationAge:null,orgId:void 0,orgPermissions:void 0,orgRole:void 0,orgSlug:void 0,sessionClaims:void 0,sessionId:void 0,sessionStatus:void 0,userId:void 0};function Ql(){let e=js(),t=Fs(),n=(0,g.useCallback)(()=>t,[t]),r=(0,g.useSyncExternalStore)((0,g.useCallback)(t=>e.addListener(t,{skipInitialEmit:!0}),[e]),(0,g.useCallback)(()=>!e.loaded||!e.__internal_lastEmittedResources?n():e.__internal_lastEmittedResources,[e,n]),n);return(0,g.useMemo)(()=>r?$l(eu(r)?Oo(!1,{},r):Oo(!0,r,void 0)):Zl,[r])}function $l(e){return{sessionId:e.sessionId,sessionStatus:e.sessionStatus,sessionClaims:e.sessionClaims,userId:e.userId,actor:e.actor,orgId:e.orgId,orgRole:e.orgRole,orgSlug:e.orgSlug,orgPermissions:e.orgPermissions,factorVerificationAge:e.factorVerificationAge}}function eu(e){return!(`client`in e)}var tu=e=>new Promise(t=>{let n=r=>{[`ready`,`degraded`].includes(r)&&(t(),e.off(`status`,n))};e.on(`status`,n,{notify:!0})}),nu=e=>async t=>{if(!R())throw new eo(`useAuth().getToken() can only be used in browser environments. To access auth data server-side, see the Auth object reference doc: https://clerk.com/docs/reference/backend/types/auth-object`,{code:`clerk_runtime_not_browser`});return await tu(e),e.session?e.session.getToken(t):null},ru=e=>async(...t)=>(await tu(e),e.signOut(...t)),iu=(e={})=>{var t;Pc(`useAuth`);let{treatPendingAsSignedOut:n}=e??{},r=Ql(),i=Nc(),a=(0,g.useCallback)(nu(i),[i]),o=(0,g.useCallback)(ru(i),[i]);return(t=i.telemetry)==null||t.record(No(`useAuth`,{treatPendingAsSignedOut:n})),au({...r,getToken:a,signOut:o},{treatPendingAsSignedOut:n})};function au(e,{treatPendingAsSignedOut:t=!0}={}){let{userId:n,orgId:r,orgRole:i,has:a,signOut:o,getToken:s,orgPermissions:c,factorVerificationAge:l,sessionClaims:u}=e??{},d=(0,g.useCallback)(e=>a?a(e):Eo({userId:n,orgId:r,orgRole:i,orgPermissions:c,factorVerificationAge:l,features:u?.fea||``,plans:u?.pla||``})(e),[a,n,r,i,c,l,u]);return Do({authObject:{...e,getToken:s,signOut:o,has:d},options:{treatPendingAsSignedOut:t}})||jc.throw(Kc)}var ou=e=>{throw TypeError(e)},su=(e,t,n)=>t.has(e)||ou(`Cannot `+n),W=(e,t,n)=>(su(e,t,`read from private field`),n?n.call(e):t.get(e)),cu=(e,t,n)=>t.has(e)?ou(`Cannot add the same private member more than once`):t instanceof WeakSet?t.add(e):t.set(e,n),lu=(e,t,n,r)=>(su(e,t,`write to private field`),r?r.call(e,n):t.set(e,n),n),uu=(e,t,n)=>(su(e,t,`access private method`),n),du=[[18,0,-1,0],[19,0,0,3],[19,1,1,4],[19,2,2,3],[19,3,3,0]],fu=new Set,pu=(e,t,n)=>{let r=Ic()||Lc(),i=n??e;fu.has(i)||r||(fu.add(i),console.warn(`Clerk - DEPRECATION WARNING: "${e}" is deprecated and will be removed in the next major release.\n${t}`))};function mu(e){let t=e.match(/^(\d+)\.(\d+)\.(\d+)/);if(!t)return null;let[,n,r,i]=t;return{major:parseInt(n,10),minor:parseInt(r,10),patch:parseInt(i,10)}}function hu(e,t){let{major:n,minor:r,patch:i}=e;return t.some(([e,t,a,o])=>n===e?a===-1?r>t||r===t&&i>=o:r===a&&i>=o:!1)}function gu(e,t){let n=mu(e);return n?hu(n,t):!1}var _u=(e,t,n,r,i)=>{let{notify:a}=i||{},o=e.get(n);o||(o=[],e.set(n,o)),o.push(r),a&&t.has(n)&&r(t.get(n))},vu=(e,t,n)=>(e.get(t)||[]).map(e=>e(n)),yu=(e,t,n)=>{let r=e.get(t);r&&(n?r.splice(r.indexOf(n)>>>0,1):e.set(t,[]))},bu=()=>{let e=new Map,t=new Map,n=new Map;return{on:(...n)=>_u(e,t,...n),prioritizedOn:(...e)=>_u(n,t,...e),emit:(r,i)=>{t.set(r,i),vu(n,r,i),vu(e,r,i)},off:(...t)=>yu(e,...t),prioritizedOff:(...e)=>yu(n,...e),internal:{retrieveListeners:t=>e.get(t)||[]}}},xu={Status:`status`},Su=()=>bu(),Cu={initialDelay:125,maxDelayBetweenRetries:0,factor:2,shouldRetry:(e,t)=>t<5,retryImmediately:!1,jitter:!0},wu=100,Tu=async e=>new Promise(t=>setTimeout(t,e)),Eu=(e,t)=>t?e*(1+Math.random()):e,Du=e=>{let t=0,n=()=>{let n=e.initialDelay*e.factor**+t;return n=Eu(n,e.jitter),Math.min(e.maxDelayBetweenRetries||n,n)};return async()=>{await Tu(n()),t++}},Ou=async(e,t={})=>{let n=0,{shouldRetry:r,initialDelay:i,maxDelayBetweenRetries:a,factor:o,retryImmediately:s,jitter:c,onBeforeRetry:l}={...Cu,...t},u=Du({initialDelay:i,maxDelayBetweenRetries:a,factor:o,jitter:c});for(;;)try{return await e()}catch(e){if(n++,!r(e,n))throw e;l&&await l(n),s&&n===1?await Tu(Eu(wu,c)):await u()}},ku=`loadScript cannot be called when document does not exist`,Au=`loadScript cannot be called without a src`;async function ju(e=``,t){let{async:n,defer:r,beforeLoad:i,crossOrigin:a,nonce:o}=t||{};return Ou(()=>new Promise((t,s)=>{e||s(Error(Au)),(!document||!document.body)&&s(Error(ku));let c=document.createElement(`script`);a&&c.setAttribute(`crossorigin`,a),c.async=n||!1,c.defer=r||!1,c.addEventListener(`load`,()=>{c.remove(),t(c)}),c.addEventListener(`error`,t=>{c.remove(),s(t.error??Error(`failed to load script: ${e}`))}),c.src=e,c.nonce=o,i?.(c),document.body.appendChild(c)}),{shouldRetry:(e,t)=>t<=5})}function Mu(e){return e?Nu(e)||Pu(e):!0}function Nu(e){return/^http(s)?:\/\//.test(e||``)}function Pu(e){return e.startsWith(`/`)}function Fu(e){return e?Pu(e)?new URL(e,window.location.origin).toString():e:``}function Iu(e){if(!e)return``;let t;if(e.match(/^(clerk\.)+\w*$/))t=/(clerk\.)*(?=clerk\.)/;else if(e.match(/\.clerk.accounts/))return e;else t=/^(clerk\.)*/gi;return`clerk.${e.replace(t,``)}`}var Lu=(e,t=`6.7.3`)=>{if(e)return e;let n=Ru(t);return n?n===`snapshot`?t:n:zu(t)},Ru=e=>e.trim().replace(/^v/,``).match(/-(.+?)(\.|$)/)?.[1],zu=e=>e.trim().replace(/^v/,``).split(`.`)[0],{isDevOrStagingUrl:Bu}=uo(),Vu=no({packageName:`@clerk/shared`});function Hu(e){return typeof window>`u`||!window[e]?!1:!!window[e]}var Uu=()=>Hu(`Clerk`),Wu=()=>Hu(`__internal_ClerkUICtor`);function Gu(e){if(typeof window>`u`||!window.performance)return!1;let t=performance.getEntriesByName(e,`resource`);if(t.length===0)return!1;let n=t[t.length-1];return n.transferSize===0&&n.decodedBodySize===0&&(n.responseEnd===0||n.responseEnd>0&&n.responseStart>0||`responseStatus`in n&&(n.responseStatus>=400||n.responseStatus===0))}var Ku=async e=>{let t=e?.scriptLoadTimeout??15e3,n=e=>new eo(`Failed to load Clerk JS`+(e?.message?`, ${e.message}`:``),{code:`failed_to_load_clerk_js`,cause:e});if(Uu())return null;if(!e?.publishableKey)return Vu.throwMissingPublishableKeyError(),null;let r=Ju(e),i=document.querySelector(`script[data-clerk-js-script]`);if(i)if(Gu(r))i.remove();else try{return await $u(t,Uu,n(),i),null}catch{i.remove()}let a=$u(t,Uu,n());return ju(r,{async:!0,crossOrigin:`anonymous`,nonce:e.nonce,beforeLoad:Zu(Xu(e))}).catch(e=>{throw n(e)}),a},qu=async e=>{let t=e?.scriptLoadTimeout??15e3,n=e=>new eo(`Failed to load Clerk UI`+(e?.message?`, ${e.message}`:``),{code:`failed_to_load_clerk_ui`,cause:e});if(Wu())return null;if(!e?.publishableKey)return Vu.throwMissingPublishableKeyError(),null;let r=Yu(e),i=document.querySelector(`script[data-clerk-ui-script]`);if(i)if(Gu(r))i.remove();else try{return await $u(t,Wu,n(),i),null}catch{i.remove()}let a=$u(t,Wu,n());return ju(r,{async:!0,crossOrigin:`anonymous`,nonce:e.nonce,beforeLoad:Zu(G(e))}).catch(e=>{throw n(e)}),a},Ju=e=>{let{__internal_clerkJSUrl:t,__internal_clerkJSVersion:n,proxyUrl:r,domain:i,publishableKey:a}=e;return t||`https://${Qu({publishableKey:a,proxyUrl:r,domain:i})}/npm/@clerk/clerk-js@${Lu(n)}/dist/clerk.browser.js`},Yu=e=>{let{__internal_clerkUIUrl:t,__internal_clerkUIVersion:n,proxyUrl:r,domain:i,publishableKey:a}=e;return t||`https://${Qu({publishableKey:a,proxyUrl:r,domain:i})}/npm/@clerk/ui@${Lu(n,`1.6.2`)}/dist/ui.browser.js`},Xu=e=>{let t={};return e.publishableKey&&(t[`data-clerk-publishable-key`]=e.publishableKey),e.proxyUrl&&(t[`data-clerk-proxy-url`]=e.proxyUrl),e.domain&&(t[`data-clerk-domain`]=e.domain),e.nonce&&(t.nonce=e.nonce),t},G=e=>Xu(e),Zu=e=>t=>{for(let n in e)t.setAttribute(n,e[n])},Qu=e=>{let{proxyUrl:t,domain:n,publishableKey:r}=e;return t&&Mu(t)?Fu(t).replace(/http(s)?:\/\//,``):n&&!Bu(co(r)?.frontendApi||``)?Iu(n):co(r)?.frontendApi||``};function $u(e,t,n,r){return new Promise((i,a)=>{let o=!1,s=(e,t)=>{clearTimeout(e),clearInterval(t)};r?.addEventListener(`error`,()=>{s(l,u),a(n)});let c=()=>{o||t()&&(o=!0,s(l,u),i(null))},l=setTimeout(()=>{o||(o=!0,s(l,u),t()?i(null):a(n))},e);c();let u=setInterval(()=>{if(o){clearInterval(u);return}c()},100)})}function ed(e){Vu.setPackageName({packageName:e})}var td=({children:e})=>(Pc(`ClerkLoaded`),Nc().loaded?e:null),nd=({children:e})=>(Pc(`ClerkLoading`),Nc().status===`loading`?e:null),rd=({children:e,fallback:t,treatPendingAsSignedOut:n,when:r})=>{Pc(`Show`);let{has:i,isLoaded:a,userId:o}=iu({treatPendingAsSignedOut:n});if(!a)return null;let s=r,c=e,l=t??null;return s===`signed-out`?o?l:c:o&&(s===`signed-in`||id(s,i))?c:l};function id(e,t){return typeof e==`function`?e(t):t(e)}z(({clerk:e,...t})=>{let{client:n,session:r}=e,i=(n.signedInSessions?.length??0)>0;return g.useEffect(()=>{r===null&&i?e.redirectToAfterSignOut():e.redirectToSignIn(t)},[]),null},`RedirectToSignIn`),z(({clerk:e,...t})=>(g.useEffect(()=>{e.redirectToSignUp(t)},[]),null),`RedirectToSignUp`),z(({clerk:e,...t})=>(g.useEffect(()=>{e.redirectToTasks(t)},[]),null),`RedirectToTasks`),z(({clerk:e})=>(g.useEffect(()=>{pu(`RedirectToUserProfile`,"Use the `redirectToUserProfile()` method instead."),e.redirectToUserProfile()},[]),null),`RedirectToUserProfile`),z(({clerk:e})=>(g.useEffect(()=>{pu(`RedirectToOrganizationProfile`,"Use the `redirectToOrganizationProfile()` method instead."),e.redirectToOrganizationProfile()},[]),null),`RedirectToOrganizationProfile`),z(({clerk:e})=>(g.useEffect(()=>{pu(`RedirectToCreateOrganization`,"Use the `redirectToCreateOrganization()` method instead."),e.redirectToCreateOrganization()},[]),null),`RedirectToCreateOrganization`),z(({clerk:e,...t})=>(g.useEffect(()=>{e.handleRedirectCallback(t)},[]),null),`AuthenticateWithRedirectCallback`);function ad(){try{return gu(`19.2.5`,du)}catch{return!1}}var od=ad(),sd=()=>({fields:{identifier:null,password:null,code:null},raw:null,global:null}),cd=()=>({fields:{firstName:null,lastName:null,emailAddress:null,phoneNumber:null,password:null,username:null,code:null,captcha:null,legalAccepted:null},raw:null,global:null}),ld=()=>({fields:{emailAddress:null},raw:null,global:null}),ud=()=>({pathRoot:``,attempts:null,error:null,expireAt:null,externalVerificationRedirectURL:null,nonce:null,message:null,status:null,strategy:null,verifiedAtClient:null,verifiedFromTheSameClient(){return!1},reload(){throw Error(`reload() called before Clerk is loaded`)},__internal_toSnapshot(){return{object:`verification`,id:``,attempts:null,error:{code:``,message:``},expire_at:null,externalVerificationRedirectURL:null,nonce:null,message:null,status:null,strategy:null,verified_at_client:null}}}),dd=()=>({...ud(),supportedStrategies:[],nextAction:``,reload(){throw Error(`reload() called before Clerk is loaded`)},__internal_toSnapshot(){return{...ud().__internal_toSnapshot(),next_action:this.nextAction,supported_strategies:this.supportedStrategies}}}),fd=class{constructor(e){this.isomorphicClerk=e,this.signInSignalProxy=this.buildSignInProxy(),this.signUpSignalProxy=this.buildSignUpProxy(),this.waitlistSignalProxy=this.buildWaitlistProxy()}signInSignal(){return this.signInSignalProxy}signUpSignal(){return this.signUpSignalProxy}waitlistSignal(){return this.waitlistSignalProxy}get __internal_waitlist(){return this.state.__internal_waitlist}checkoutSignal(e){return this.buildCheckoutProxy(e)}buildSignInProxy(){let e=this.gateProperty.bind(this),t=()=>this.client.signIn.__internal_future;return{errors:sd(),fetchStatus:`idle`,signIn:{status:`needs_identifier`,availableStrategies:[],get isTransferable(){return e(t,`isTransferable`,!1)},get id(){return e(t,`id`,void 0)},get supportedFirstFactors(){return e(t,`supportedFirstFactors`,[])},get supportedSecondFactors(){return e(t,`supportedSecondFactors`,[])},get secondFactorVerification(){return e(t,`secondFactorVerification`,{status:null,error:null,expireAt:null,externalVerificationRedirectURL:null,nonce:null,attempts:null,message:null,strategy:null,verifiedAtClient:null,verifiedFromTheSameClient:()=>!1,__internal_toSnapshot:()=>{throw Error(`__internal_toSnapshot called before Clerk is loaded`)},pathRoot:``,reload:()=>{throw Error(`__internal_toSnapshot called before Clerk is loaded`)}})},get identifier(){return e(t,`identifier`,null)},get createdSessionId(){return e(t,`createdSessionId`,null)},get userData(){return e(t,`userData`,{})},get firstFactorVerification(){return e(t,`firstFactorVerification`,{status:null,error:null,expireAt:null,externalVerificationRedirectURL:null,nonce:null,attempts:null,message:null,strategy:null,verifiedAtClient:null,verifiedFromTheSameClient:()=>!1,__internal_toSnapshot:()=>{throw Error(`__internal_toSnapshot called before Clerk is loaded`)},pathRoot:``,reload:()=>{throw Error(`__internal_toSnapshot called before Clerk is loaded`)}})},get canBeDiscarded(){return e(t,`canBeDiscarded`,!1)},create:this.gateMethod(t,`create`),password:this.gateMethod(t,`password`),sso:this.gateMethod(t,`sso`),finalize:this.gateMethod(t,`finalize`),reset:this.gateMethod(t,`reset`),emailCode:this.wrapMethods(()=>t().emailCode,[`sendCode`,`verifyCode`]),emailLink:this.wrapStruct(()=>t().emailLink,[`sendLink`,`waitForVerification`],[`verification`],{verification:null}),resetPasswordEmailCode:this.wrapMethods(()=>t().resetPasswordEmailCode,[`sendCode`,`verifyCode`,`submitPassword`]),resetPasswordPhoneCode:this.wrapMethods(()=>t().resetPasswordPhoneCode,[`sendCode`,`verifyCode`,`submitPassword`]),phoneCode:this.wrapMethods(()=>t().phoneCode,[`sendCode`,`verifyCode`]),mfa:this.wrapMethods(()=>t().mfa,[`sendPhoneCode`,`verifyPhoneCode`,`sendEmailCode`,`verifyEmailCode`,`verifyTOTP`,`verifyBackupCode`]),ticket:this.gateMethod(t,`ticket`),passkey:this.gateMethod(t,`passkey`),web3:this.gateMethod(t,`web3`)}}}buildSignUpProxy(){let e=this.gateProperty.bind(this),t=this.gateMethod.bind(this),n=()=>this.client.signUp.__internal_future;return{errors:cd(),fetchStatus:`idle`,signUp:{get id(){return e(n,`id`,void 0)},get requiredFields(){return e(n,`requiredFields`,[])},get optionalFields(){return e(n,`optionalFields`,[])},get missingFields(){return e(n,`missingFields`,[])},get username(){return e(n,`username`,null)},get firstName(){return e(n,`firstName`,null)},get lastName(){return e(n,`lastName`,null)},get emailAddress(){return e(n,`emailAddress`,null)},get phoneNumber(){return e(n,`phoneNumber`,null)},get web3Wallet(){return e(n,`web3Wallet`,null)},get hasPassword(){return e(n,`hasPassword`,!1)},get unsafeMetadata(){return e(n,`unsafeMetadata`,{})},get createdSessionId(){return e(n,`createdSessionId`,null)},get createdUserId(){return e(n,`createdUserId`,null)},get abandonAt(){return e(n,`abandonAt`,null)},get legalAcceptedAt(){return e(n,`legalAcceptedAt`,null)},get locale(){return e(n,`locale`,null)},get status(){return e(n,`status`,`missing_requirements`)},get unverifiedFields(){return e(n,`unverifiedFields`,[])},get isTransferable(){return e(n,`isTransferable`,!1)},get canBeDiscarded(){return e(n,`canBeDiscarded`,!1)},create:t(n,`create`),update:t(n,`update`),sso:t(n,`sso`),password:t(n,`password`),ticket:t(n,`ticket`),web3:t(n,`web3`),finalize:t(n,`finalize`),reset:t(n,`reset`),verifications:this.wrapStruct(()=>n().verifications,[`sendEmailCode`,`verifyEmailCode`,`sendEmailLink`,`waitForEmailLinkVerification`,`sendPhoneCode`,`verifyPhoneCode`],[`emailAddress`,`phoneNumber`,`web3Wallet`,`externalAccount`,`emailLinkVerification`],{emailAddress:dd(),phoneNumber:dd(),web3Wallet:dd(),externalAccount:dd(),emailLinkVerification:null})}}}buildWaitlistProxy(){let e=this.gateProperty.bind(this),t=this.gateMethod.bind(this),n=()=>this.state.__internal_waitlist;return{errors:ld(),fetchStatus:`idle`,waitlist:{pathRoot:`/waitlist`,get id(){return e(n,`id`,``)},get createdAt(){return e(n,`createdAt`,null)},get updatedAt(){return e(n,`updatedAt`,null)},join:t(n,`join`),reload:t(n,`reload`)}}}buildCheckoutProxy(e){let t=this.gateProperty.bind(this),n=()=>this.checkout(e),r=()=>n().checkout;return{errors:{raw:null,global:null},fetchStatus:`idle`,checkout:{get status(){return t(r,`status`,`needs_initialization`)},get externalClientSecret(){return t(r,`externalClientSecret`,null)},get externalGatewayId(){return t(r,`externalGatewayId`,null)},get paymentMethod(){return t(r,`paymentMethod`,null)},get plan(){return t(r,`plan`,null)},get planPeriod(){return t(r,`planPeriod`,null)},get totals(){return t(r,`totals`,null)},get isImmediatePlanChange(){return t(r,`isImmediatePlanChange`,!1)},get freeTrialEndsAt(){return t(r,`freeTrialEndsAt`,null)},get payer(){return t(r,`payer`,null)},get planPeriodStart(){return t(r,`planPeriodStart`,null)},get needsPaymentMethod(){return t(r,`needsPaymentMethod`,null)},start:this.gateMethod(r,`start`),confirm:this.gateMethod(r,`confirm`),finalize:this.gateMethod(r,`finalize`)}}}__internal_effect(e){throw Error(`__internal_effect called before Clerk is loaded`)}__internal_computed(e){throw Error(`__internal_computed called before Clerk is loaded`)}get state(){let e=this.isomorphicClerk.__internal_state;if(!e)throw Error(`Clerk state not ready`);return e}get client(){let e=this.isomorphicClerk.client;if(!e)throw Error(`Clerk client not ready`);return e}get checkout(){let e=this.isomorphicClerk.__experimental_checkout;if(!e)throw Error(`Clerk checkout not ready`);return e}gateProperty(e,t,n){return!R()||!this.isomorphicClerk.loaded?n:e()[t]}gateMethod(e,t){return(async(...n)=>{if(!R())return jc.throw(`Attempted to call a method (${t}) that is not supported on the server.`);this.isomorphicClerk.loaded||await new Promise(e=>this.isomorphicClerk.addOnLoaded(e));let r=e();return r[t].apply(r,n)})}wrapMethods(e,t){return Object.fromEntries(t.map(t=>[t,this.gateMethod(e,t)]))}wrapStruct(e,t,n,r){let i={};for(let n of t)i[n]=this.gateMethod(e,n);for(let t of n)Object.defineProperty(i,t,{get:()=>this.gateProperty(e,t,r[t]),enumerable:!0});return i}};globalThis.__BUILD_DISABLE_RHC__===void 0&&(globalThis.__BUILD_DISABLE_RHC__=!1);var pd={name:`@clerk/react`,version:`6.4.2`,environment:`production`},md,hd,gd,_d,vd,yd,bd,xd,Sd,Cd=class e{constructor(e){cu(this,xd),this.clerkjs=null,this.preopenOneTap=null,this.preopenUserVerification=null,this.preopenEnableOrganizationsPrompt=null,this.preopenSignIn=null,this.preopenCheckout=null,this.preopenPlanDetails=null,this.preopenSubscriptionDetails=null,this.preopenSignUp=null,this.preopenUserProfile=null,this.preopenOrganizationProfile=null,this.preopenCreateOrganization=null,this.preOpenWaitlist=null,this.premountSignInNodes=new Map,this.premountSignUpNodes=new Map,this.premountUserAvatarNodes=new Map,this.premountUserProfileNodes=new Map,this.premountUserButtonNodes=new Map,this.premountOrganizationProfileNodes=new Map,this.premountCreateOrganizationNodes=new Map,this.premountOrganizationSwitcherNodes=new Map,this.premountOrganizationListNodes=new Map,this.premountMethodCalls=new Map,this.premountWaitlistNodes=new Map,this.premountPricingTableNodes=new Map,this.premountAPIKeysNodes=new Map,this.premountOAuthConsentNodes=new Map,this.premountTaskChooseOrganizationNodes=new Map,this.premountTaskResetPasswordNodes=new Map,this.premountTaskSetupMFANodes=new Map,this.premountAddListenerCalls=new Map,this.loadedListeners=[],cu(this,md,`loading`),cu(this,hd),cu(this,gd),cu(this,_d),cu(this,vd,Su()),cu(this,yd),this.buildSignInUrl=e=>{let t=()=>this.clerkjs?.buildSignInUrl(e)||``;if(this.clerkjs&&this.loaded)return t();this.premountMethodCalls.set(`buildSignInUrl`,t)},this.buildSignUpUrl=e=>{let t=()=>this.clerkjs?.buildSignUpUrl(e)||``;if(this.clerkjs&&this.loaded)return t();this.premountMethodCalls.set(`buildSignUpUrl`,t)},this.buildAfterSignInUrl=(...e)=>{let t=()=>this.clerkjs?.buildAfterSignInUrl(...e)||``;if(this.clerkjs&&this.loaded)return t();this.premountMethodCalls.set(`buildAfterSignInUrl`,t)},this.buildAfterSignUpUrl=(...e)=>{let t=()=>this.clerkjs?.buildAfterSignUpUrl(...e)||``;if(this.clerkjs&&this.loaded)return t();this.premountMethodCalls.set(`buildAfterSignUpUrl`,t)},this.buildAfterSignOutUrl=()=>{let e=()=>this.clerkjs?.buildAfterSignOutUrl()||``;if(this.clerkjs&&this.loaded)return e();this.premountMethodCalls.set(`buildAfterSignOutUrl`,e)},this.buildNewSubscriptionRedirectUrl=()=>{let e=()=>this.clerkjs?.buildNewSubscriptionRedirectUrl()||``;if(this.clerkjs&&this.loaded)return e();this.premountMethodCalls.set(`buildNewSubscriptionRedirectUrl`,e)},this.buildAfterMultiSessionSingleSignOutUrl=()=>{let e=()=>this.clerkjs?.buildAfterMultiSessionSingleSignOutUrl()||``;if(this.clerkjs&&this.loaded)return e();this.premountMethodCalls.set(`buildAfterMultiSessionSingleSignOutUrl`,e)},this.buildUserProfileUrl=()=>{let e=()=>this.clerkjs?.buildUserProfileUrl()||``;if(this.clerkjs&&this.loaded)return e();this.premountMethodCalls.set(`buildUserProfileUrl`,e)},this.buildCreateOrganizationUrl=()=>{let e=()=>this.clerkjs?.buildCreateOrganizationUrl()||``;if(this.clerkjs&&this.loaded)return e();this.premountMethodCalls.set(`buildCreateOrganizationUrl`,e)},this.buildOrganizationProfileUrl=()=>{let e=()=>this.clerkjs?.buildOrganizationProfileUrl()||``;if(this.clerkjs&&this.loaded)return e();this.premountMethodCalls.set(`buildOrganizationProfileUrl`,e)},this.buildWaitlistUrl=()=>{let e=()=>this.clerkjs?.buildWaitlistUrl()||``;if(this.clerkjs&&this.loaded)return e();this.premountMethodCalls.set(`buildWaitlistUrl`,e)},this.buildTasksUrl=()=>{let e=()=>this.clerkjs?.buildTasksUrl()||``;if(this.clerkjs&&this.loaded)return e();this.premountMethodCalls.set(`buildTasksUrl`,e)},this.buildUrlWithAuth=e=>{let t=()=>this.clerkjs?.buildUrlWithAuth(e)||``;if(this.clerkjs&&this.loaded)return t();this.premountMethodCalls.set(`buildUrlWithAuth`,t)},this.handleUnauthenticated=async()=>{let e=()=>this.clerkjs?.handleUnauthenticated();this.clerkjs&&this.loaded?e():this.premountMethodCalls.set(`handleUnauthenticated`,e)},this.on=(...e)=>{if(this.clerkjs?.on)return this.clerkjs.on(...e);W(this,vd).on(...e)},this.off=(...e)=>{if(this.clerkjs?.off)return this.clerkjs.off(...e);W(this,vd).off(...e)},this.addOnLoaded=e=>{this.loadedListeners.push(e),this.loaded&&this.emitLoaded()},this.emitLoaded=()=>{this.loadedListeners.forEach(e=>e()),this.loadedListeners=[]},this.beforeLoad=e=>{if(!e)throw Error(`Failed to hydrate latest Clerk JS`)},this.replayInterceptedInvocations=e=>{var t,n;if(!e)throw Error(`Failed to hydrate latest Clerk JS`);return this.clerkjs=e,this.premountMethodCalls.forEach(e=>e()),this.premountAddListenerCalls.forEach((t,n)=>{t.handlers.nativeUnsubscribe=e.addListener(n,t.options)}),(t=W(this,vd).internal.retrieveListeners(`status`))==null||t.forEach(e=>{this.on(`status`,e,{notify:!0})}),(n=W(this,vd).internal.retrieveListeners(`queryClientStatus`))==null||n.forEach(e=>{this.on(`queryClientStatus`,e,{notify:!0})}),this.preopenSignIn!==null&&e.openSignIn(this.preopenSignIn),this.preopenCheckout!==null&&e.__internal_openCheckout(this.preopenCheckout),this.preopenPlanDetails!==null&&e.__internal_openPlanDetails(this.preopenPlanDetails),this.preopenSubscriptionDetails!==null&&e.__internal_openSubscriptionDetails(this.preopenSubscriptionDetails),this.preopenSignUp!==null&&e.openSignUp(this.preopenSignUp),this.preopenUserProfile!==null&&e.openUserProfile(this.preopenUserProfile),this.preopenUserVerification!==null&&e.__internal_openReverification(this.preopenUserVerification),this.preopenOneTap!==null&&e.openGoogleOneTap(this.preopenOneTap),this.preopenOrganizationProfile!==null&&e.openOrganizationProfile(this.preopenOrganizationProfile),this.preopenCreateOrganization!==null&&e.openCreateOrganization(this.preopenCreateOrganization),this.preOpenWaitlist!==null&&e.openWaitlist(this.preOpenWaitlist),this.preopenEnableOrganizationsPrompt&&e.__internal_openEnableOrganizationsPrompt(this.preopenEnableOrganizationsPrompt),this.premountSignInNodes.forEach((t,n)=>{e.mountSignIn(n,t)}),this.premountSignUpNodes.forEach((t,n)=>{e.mountSignUp(n,t)}),this.premountUserProfileNodes.forEach((t,n)=>{e.mountUserProfile(n,t)}),this.premountUserAvatarNodes.forEach((t,n)=>{e.mountUserAvatar(n,t)}),this.premountUserButtonNodes.forEach((t,n)=>{e.mountUserButton(n,t)}),this.premountOrganizationListNodes.forEach((t,n)=>{e.mountOrganizationList(n,t)}),this.premountWaitlistNodes.forEach((t,n)=>{e.mountWaitlist(n,t)}),this.premountPricingTableNodes.forEach((t,n)=>{e.mountPricingTable(n,t)}),this.premountAPIKeysNodes.forEach((t,n)=>{e.mountAPIKeys(n,t)}),this.premountOAuthConsentNodes.forEach((t,n)=>{e.__internal_mountOAuthConsent(n,t)}),this.premountTaskChooseOrganizationNodes.forEach((t,n)=>{e.mountTaskChooseOrganization(n,t)}),this.premountTaskResetPasswordNodes.forEach((t,n)=>{e.mountTaskResetPassword(n,t)}),this.premountTaskSetupMFANodes.forEach((t,n)=>{e.mountTaskSetupMFA(n,t)}),this.clerkjs.status===void 0&&W(this,vd).emit(xu.Status,`ready`),this.emitLoaded(),this.clerkjs},this.__experimental_checkout=(...e)=>this.loaded&&this.clerkjs?this.clerkjs.__experimental_checkout(...e):W(this,yd).checkoutSignal(...e),this.__internal_updateProps=async e=>{let t=await uu(this,xd,Sd).call(this);if(t&&`__internal_updateProps`in t)return t.__internal_updateProps(e)},this.setActive=e=>this.clerkjs?this.clerkjs.setActive(e):Promise.reject(),this.openSignIn=e=>{this.clerkjs&&this.loaded?this.clerkjs.openSignIn(e):this.preopenSignIn=e},this.closeSignIn=()=>{this.clerkjs&&this.loaded?this.clerkjs.closeSignIn():this.preopenSignIn=null},this.__internal_openCheckout=e=>{this.clerkjs&&this.loaded?this.clerkjs.__internal_openCheckout(e):this.preopenCheckout=e},this.__internal_closeCheckout=()=>{this.clerkjs&&this.loaded?this.clerkjs.__internal_closeCheckout():this.preopenCheckout=null},this.__internal_openPlanDetails=e=>{this.clerkjs&&this.loaded?this.clerkjs.__internal_openPlanDetails(e):this.preopenPlanDetails=e},this.__internal_closePlanDetails=()=>{this.clerkjs&&this.loaded?this.clerkjs.__internal_closePlanDetails():this.preopenPlanDetails=null},this.__internal_openSubscriptionDetails=e=>{this.clerkjs&&this.loaded?this.clerkjs.__internal_openSubscriptionDetails(e):this.preopenSubscriptionDetails=e??null},this.__internal_closeSubscriptionDetails=()=>{this.clerkjs&&this.loaded?this.clerkjs.__internal_closeSubscriptionDetails():this.preopenSubscriptionDetails=null},this.__internal_openReverification=e=>{this.clerkjs&&this.loaded?this.clerkjs.__internal_openReverification(e):this.preopenUserVerification=e},this.__internal_closeReverification=()=>{this.clerkjs&&this.loaded?this.clerkjs.__internal_closeReverification():this.preopenUserVerification=null},this.__internal_openEnableOrganizationsPrompt=e=>{this.clerkjs&&this.loaded?this.clerkjs.__internal_openEnableOrganizationsPrompt(e):this.preopenEnableOrganizationsPrompt=e},this.__internal_closeEnableOrganizationsPrompt=()=>{this.clerkjs&&this.loaded?this.clerkjs.__internal_closeEnableOrganizationsPrompt():this.preopenEnableOrganizationsPrompt=null},this.openGoogleOneTap=e=>{this.clerkjs&&this.loaded?this.clerkjs.openGoogleOneTap(e):this.preopenOneTap=e},this.closeGoogleOneTap=()=>{this.clerkjs&&this.loaded?this.clerkjs.closeGoogleOneTap():this.preopenOneTap=null},this.openUserProfile=e=>{this.clerkjs&&this.loaded?this.clerkjs.openUserProfile(e):this.preopenUserProfile=e},this.closeUserProfile=()=>{this.clerkjs&&this.loaded?this.clerkjs.closeUserProfile():this.preopenUserProfile=null},this.openOrganizationProfile=e=>{this.clerkjs&&this.loaded?this.clerkjs.openOrganizationProfile(e):this.preopenOrganizationProfile=e},this.closeOrganizationProfile=()=>{this.clerkjs&&this.loaded?this.clerkjs.closeOrganizationProfile():this.preopenOrganizationProfile=null},this.openCreateOrganization=e=>{this.clerkjs&&this.loaded?this.clerkjs.openCreateOrganization(e):this.preopenCreateOrganization=e},this.closeCreateOrganization=()=>{this.clerkjs&&this.loaded?this.clerkjs.closeCreateOrganization():this.preopenCreateOrganization=null},this.openWaitlist=e=>{this.clerkjs&&this.loaded?this.clerkjs.openWaitlist(e):this.preOpenWaitlist=e},this.closeWaitlist=()=>{this.clerkjs&&this.loaded?this.clerkjs.closeWaitlist():this.preOpenWaitlist=null},this.openSignUp=e=>{this.clerkjs&&this.loaded?this.clerkjs.openSignUp(e):this.preopenSignUp=e},this.closeSignUp=()=>{this.clerkjs&&this.loaded?this.clerkjs.closeSignUp():this.preopenSignUp=null},this.mountSignIn=(e,t)=>{this.clerkjs&&this.loaded?this.clerkjs.mountSignIn(e,t):this.premountSignInNodes.set(e,t)},this.unmountSignIn=e=>{this.clerkjs&&this.loaded?this.clerkjs.unmountSignIn(e):this.premountSignInNodes.delete(e)},this.mountSignUp=(e,t)=>{this.clerkjs&&this.loaded?this.clerkjs.mountSignUp(e,t):this.premountSignUpNodes.set(e,t)},this.unmountSignUp=e=>{this.clerkjs&&this.loaded?this.clerkjs.unmountSignUp(e):this.premountSignUpNodes.delete(e)},this.mountUserAvatar=(e,t)=>{this.clerkjs&&this.loaded?this.clerkjs.mountUserAvatar(e,t):this.premountUserAvatarNodes.set(e,t)},this.unmountUserAvatar=e=>{this.clerkjs&&this.loaded?this.clerkjs.unmountUserAvatar(e):this.premountUserAvatarNodes.delete(e)},this.mountUserProfile=(e,t)=>{this.clerkjs&&this.loaded?this.clerkjs.mountUserProfile(e,t):this.premountUserProfileNodes.set(e,t)},this.unmountUserProfile=e=>{this.clerkjs&&this.loaded?this.clerkjs.unmountUserProfile(e):this.premountUserProfileNodes.delete(e)},this.mountOrganizationProfile=(e,t)=>{this.clerkjs&&this.loaded?this.clerkjs.mountOrganizationProfile(e,t):this.premountOrganizationProfileNodes.set(e,t)},this.unmountOrganizationProfile=e=>{this.clerkjs&&this.loaded?this.clerkjs.unmountOrganizationProfile(e):this.premountOrganizationProfileNodes.delete(e)},this.mountCreateOrganization=(e,t)=>{this.clerkjs&&this.loaded?this.clerkjs.mountCreateOrganization(e,t):this.premountCreateOrganizationNodes.set(e,t)},this.unmountCreateOrganization=e=>{this.clerkjs&&this.loaded?this.clerkjs.unmountCreateOrganization(e):this.premountCreateOrganizationNodes.delete(e)},this.mountOrganizationSwitcher=(e,t)=>{this.clerkjs&&this.loaded?this.clerkjs.mountOrganizationSwitcher(e,t):this.premountOrganizationSwitcherNodes.set(e,t)},this.unmountOrganizationSwitcher=e=>{this.clerkjs&&this.loaded?this.clerkjs.unmountOrganizationSwitcher(e):this.premountOrganizationSwitcherNodes.delete(e)},this.__experimental_prefetchOrganizationSwitcher=()=>{let e=()=>this.clerkjs?.__experimental_prefetchOrganizationSwitcher();this.clerkjs&&this.loaded?e():this.premountMethodCalls.set(`__experimental_prefetchOrganizationSwitcher`,e)},this.mountOrganizationList=(e,t)=>{this.clerkjs&&this.loaded?this.clerkjs.mountOrganizationList(e,t):this.premountOrganizationListNodes.set(e,t)},this.unmountOrganizationList=e=>{this.clerkjs&&this.loaded?this.clerkjs.unmountOrganizationList(e):this.premountOrganizationListNodes.delete(e)},this.mountUserButton=(e,t)=>{this.clerkjs&&this.loaded?this.clerkjs.mountUserButton(e,t):this.premountUserButtonNodes.set(e,t)},this.unmountUserButton=e=>{this.clerkjs&&this.loaded?this.clerkjs.unmountUserButton(e):this.premountUserButtonNodes.delete(e)},this.mountWaitlist=(e,t)=>{this.clerkjs&&this.loaded?this.clerkjs.mountWaitlist(e,t):this.premountWaitlistNodes.set(e,t)},this.unmountWaitlist=e=>{this.clerkjs&&this.loaded?this.clerkjs.unmountWaitlist(e):this.premountWaitlistNodes.delete(e)},this.mountPricingTable=(e,t)=>{this.clerkjs&&this.loaded?this.clerkjs.mountPricingTable(e,t):this.premountPricingTableNodes.set(e,t)},this.unmountPricingTable=e=>{this.clerkjs&&this.loaded?this.clerkjs.unmountPricingTable(e):this.premountPricingTableNodes.delete(e)},this.mountAPIKeys=(e,t)=>{this.clerkjs&&this.loaded?this.clerkjs.mountAPIKeys(e,t):this.premountAPIKeysNodes.set(e,t)},this.unmountAPIKeys=e=>{this.clerkjs&&this.loaded?this.clerkjs.unmountAPIKeys(e):this.premountAPIKeysNodes.delete(e)},this.__internal_mountOAuthConsent=(e,t)=>{this.clerkjs&&this.loaded?this.clerkjs.__internal_mountOAuthConsent(e,t):this.premountOAuthConsentNodes.set(e,t)},this.__internal_unmountOAuthConsent=e=>{this.clerkjs&&this.loaded?this.clerkjs.__internal_unmountOAuthConsent(e):this.premountOAuthConsentNodes.delete(e)},this.mountTaskChooseOrganization=(e,t)=>{this.clerkjs&&this.loaded?this.clerkjs.mountTaskChooseOrganization(e,t):this.premountTaskChooseOrganizationNodes.set(e,t)},this.unmountTaskChooseOrganization=e=>{this.clerkjs&&this.loaded?this.clerkjs.unmountTaskChooseOrganization(e):this.premountTaskChooseOrganizationNodes.delete(e)},this.mountTaskResetPassword=(e,t)=>{this.clerkjs&&this.loaded?this.clerkjs.mountTaskResetPassword(e,t):this.premountTaskResetPasswordNodes.set(e,t)},this.unmountTaskResetPassword=e=>{this.clerkjs&&this.loaded?this.clerkjs.unmountTaskResetPassword(e):this.premountTaskResetPasswordNodes.delete(e)},this.mountTaskSetupMFA=(e,t)=>{this.clerkjs&&this.loaded?this.clerkjs.mountTaskSetupMFA(e,t):this.premountTaskSetupMFANodes.set(e,t)},this.unmountTaskSetupMFA=e=>{this.clerkjs&&this.loaded?this.clerkjs.unmountTaskSetupMFA(e):this.premountTaskSetupMFANodes.delete(e)},this.addListener=(e,t)=>{if(this.clerkjs)return this.clerkjs.addListener(e,t);{let n=()=>{var t,n;let r=this.premountAddListenerCalls.get(e);r?.handlers&&((n=r==null?void 0:(t=r.handlers).nativeUnsubscribe)==null||n.call(t),this.premountAddListenerCalls.delete(e))};return this.premountAddListenerCalls.set(e,{options:t,handlers:{unsubscribe:n,nativeUnsubscribe:void 0}}),n}},this.navigate=e=>{let t=()=>this.clerkjs?.navigate(e);this.clerkjs&&this.loaded?t():this.premountMethodCalls.set(`navigate`,t)},this.redirectWithAuth=async(...e)=>{let t=()=>this.clerkjs?.redirectWithAuth(...e);if(this.clerkjs&&this.loaded)return t();this.premountMethodCalls.set(`redirectWithAuth`,t)},this.redirectToSignIn=async e=>{let t=()=>this.clerkjs?.redirectToSignIn(e);if(this.clerkjs&&this.loaded)return t();this.premountMethodCalls.set(`redirectToSignIn`,t)},this.redirectToSignUp=async e=>{let t=()=>this.clerkjs?.redirectToSignUp(e);if(this.clerkjs&&this.loaded)return t();this.premountMethodCalls.set(`redirectToSignUp`,t)},this.redirectToUserProfile=async()=>{let e=()=>this.clerkjs?.redirectToUserProfile();if(this.clerkjs&&this.loaded)return e();this.premountMethodCalls.set(`redirectToUserProfile`,e)},this.redirectToAfterSignUp=()=>{let e=()=>this.clerkjs?.redirectToAfterSignUp();if(this.clerkjs&&this.loaded)return e();this.premountMethodCalls.set(`redirectToAfterSignUp`,e)},this.redirectToAfterSignIn=()=>{let e=()=>this.clerkjs?.redirectToAfterSignIn();this.clerkjs&&this.loaded?e():this.premountMethodCalls.set(`redirectToAfterSignIn`,e)},this.redirectToAfterSignOut=()=>{let e=()=>this.clerkjs?.redirectToAfterSignOut();this.clerkjs&&this.loaded?e():this.premountMethodCalls.set(`redirectToAfterSignOut`,e)},this.redirectToOrganizationProfile=async()=>{let e=()=>this.clerkjs?.redirectToOrganizationProfile();if(this.clerkjs&&this.loaded)return e();this.premountMethodCalls.set(`redirectToOrganizationProfile`,e)},this.redirectToCreateOrganization=async()=>{let e=()=>this.clerkjs?.redirectToCreateOrganization();if(this.clerkjs&&this.loaded)return e();this.premountMethodCalls.set(`redirectToCreateOrganization`,e)},this.redirectToWaitlist=async()=>{let e=()=>this.clerkjs?.redirectToWaitlist();if(this.clerkjs&&this.loaded)return e();this.premountMethodCalls.set(`redirectToWaitlist`,e)},this.redirectToTasks=async e=>{let t=()=>this.clerkjs?.redirectToTasks(e);if(this.clerkjs&&this.loaded)return t();this.premountMethodCalls.set(`redirectToTasks`,t)},this.handleRedirectCallback=async e=>{var t;let n=()=>this.clerkjs?.handleRedirectCallback(e);this.clerkjs&&this.loaded?(t=n())==null||t.catch(()=>{}):this.premountMethodCalls.set(`handleRedirectCallback`,n)},this.handleGoogleOneTapCallback=async(e,t)=>{var n;let r=()=>this.clerkjs?.handleGoogleOneTapCallback(e,t);this.clerkjs&&this.loaded?(n=r())==null||n.catch(()=>{}):this.premountMethodCalls.set(`handleGoogleOneTapCallback`,r)},this.handleEmailLinkVerification=async e=>{let t=()=>this.clerkjs?.handleEmailLinkVerification(e);if(this.clerkjs&&this.loaded)return t();this.premountMethodCalls.set(`handleEmailLinkVerification`,t)},this.authenticateWithMetamask=async e=>{let t=()=>this.clerkjs?.authenticateWithMetamask(e);if(this.clerkjs&&this.loaded)return t();this.premountMethodCalls.set(`authenticateWithMetamask`,t)},this.authenticateWithCoinbaseWallet=async e=>{let t=()=>this.clerkjs?.authenticateWithCoinbaseWallet(e);if(this.clerkjs&&this.loaded)return t();this.premountMethodCalls.set(`authenticateWithCoinbaseWallet`,t)},this.authenticateWithBase=async e=>{let t=()=>this.clerkjs?.authenticateWithBase(e);if(this.clerkjs&&this.loaded)return t();this.premountMethodCalls.set(`authenticateWithBase`,t)},this.authenticateWithOKXWallet=async e=>{let t=()=>this.clerkjs?.authenticateWithOKXWallet(e);if(this.clerkjs&&this.loaded)return t();this.premountMethodCalls.set(`authenticateWithOKXWallet`,t)},this.authenticateWithSolana=async e=>{let t=()=>this.clerkjs?.authenticateWithSolana(e);if(this.clerkjs&&this.loaded)return t();this.premountMethodCalls.set(`authenticateWithSolana`,t)},this.authenticateWithWeb3=async e=>{let t=()=>this.clerkjs?.authenticateWithWeb3(e);if(this.clerkjs&&this.loaded)return t();this.premountMethodCalls.set(`authenticateWithWeb3`,t)},this.authenticateWithGoogleOneTap=async e=>(await uu(this,xd,Sd).call(this)).authenticateWithGoogleOneTap(e),this.__internal_loadStripeJs=async()=>(await uu(this,xd,Sd).call(this)).__internal_loadStripeJs(),this.createOrganization=async e=>{let t=()=>this.clerkjs?.createOrganization(e);if(this.clerkjs&&this.loaded)return t();this.premountMethodCalls.set(`createOrganization`,t)},this.getOrganization=async e=>{let t=()=>this.clerkjs?.getOrganization(e);if(this.clerkjs&&this.loaded)return t();this.premountMethodCalls.set(`getOrganization`,t)},this.joinWaitlist=async e=>{let t=()=>this.clerkjs?.joinWaitlist(e);if(this.clerkjs&&this.loaded)return t();this.premountMethodCalls.set(`joinWaitlist`,t)},this.signOut=async(...e)=>{let t=()=>this.clerkjs?.signOut(...e);if(this.clerkjs&&this.loaded)return t();this.premountMethodCalls.set(`signOut`,t)},this.__internal_attemptToEnableEnvironmentSetting=e=>{let t=()=>this.clerkjs?.__internal_attemptToEnableEnvironmentSetting(e);if(this.clerkjs&&this.loaded)return t();this.premountMethodCalls.set(`__internal_attemptToEnableEnvironmentSetting`,t)},lu(this,_d,e?.publishableKey),lu(this,gd,e?.proxyUrl),lu(this,hd,e?.domain),this.options=e,this.Clerk=e?.Clerk||null,this.mode=R()?`browser`:`server`,lu(this,yd,new fd(this)),this.options.sdkMetadata||(this.options.sdkMetadata=pd),W(this,vd).emit(xu.Status,`loading`),W(this,vd).prioritizedOn(xu.Status,e=>lu(this,md,e)),W(this,_d)&&this.options.experimental?.runtimeEnvironment===`headless`&&this.options.Clerk?this.loadHeadlessClerk():W(this,_d)&&this.getEntryChunks()}get publishableKey(){return W(this,_d)}get loaded(){return this.clerkjs?.loaded||!1}get status(){return this.clerkjs?this.clerkjs?.status||(this.clerkjs.loaded?`ready`:`loading`):W(this,md)}static getOrCreateInstance(t){return(!R()||!W(this,bd)||t.Clerk&&W(this,bd).Clerk!==t.Clerk||W(this,bd).publishableKey!==t.publishableKey)&&lu(this,bd,new e(t)),W(this,bd)}static clearInstance(){lu(this,bd,null)}get domain(){return typeof window<`u`&&window.location?Rc(W(this,hd),new URL(window.location.href),``):typeof W(this,hd)==`function`?jc.throw(qc):W(this,hd)||``}get proxyUrl(){return typeof window<`u`&&window.location?Rc(W(this,gd),new URL(window.location.href),``):typeof W(this,gd)==`function`?jc.throw(qc):W(this,gd)||``}__internal_getOption(e){return this.clerkjs?.__internal_getOption?this.clerkjs?.__internal_getOption(e):this.options[e]}loadHeadlessClerk(){let e=ml(this.options.Clerk)?new this.options.Clerk(W(this,_d),{proxyUrl:this.proxyUrl,domain:this.domain}):this.options.Clerk;if(!e){W(this,vd).emit(xu.Status,`error`);return}let t=()=>{this.replayInterceptedInvocations(e)};e.loaded?t():e.load(this.options).then(()=>t()).catch(e=>{W(this,vd).emit(xu.Status,`error`),this.emitLoaded()})}get sdkMetadata(){return this.clerkjs?.sdkMetadata||this.options.sdkMetadata||void 0}get instanceType(){return this.clerkjs?.instanceType}get frontendApi(){return this.clerkjs?.frontendApi||``}get isStandardBrowser(){return this.clerkjs?.isStandardBrowser||this.options.standardBrowser||!1}get __internal_queryClient(){return this.clerkjs?.__internal_queryClient}get isSatellite(){return typeof window<`u`&&window.location?Rc(this.options.isSatellite,new URL(window.location.href),!1):typeof this.options.isSatellite==`function`?jc.throw(qc):!1}async getEntryChunks(){if(!(this.mode!==`browser`||this.loaded)){typeof window<`u`&&(window.__clerk_publishable_key=W(this,_d),window.__clerk_proxy_url=this.proxyUrl,window.__clerk_domain=this.domain);try{let e=await this.getClerkJsEntryChunk();if(!e.loaded){this.beforeLoad(e);let t=this.options.standardBrowser!==!1&&!this.options.Clerk||this.options.ui?.ClerkUI?await this.getClerkUIEntryChunk():void 0;await e.load({...this.options,ui:{...this.options.ui,ClerkUI:t}})}e.loaded&&this.replayInterceptedInvocations(e)}catch(e){let t=e;W(this,vd).emit(xu.Status,`error`),console.error(t.stack||t.message||t);return}}}async getClerkJsEntryChunk(){if((!this.options.Clerk||this.options.__internal_clerkJSUrl)&&!__BUILD_DISABLE_RHC__&&await Ku({...this.options,publishableKey:W(this,_d),proxyUrl:this.proxyUrl,domain:this.domain,nonce:this.options.nonce}),this.options.Clerk&&!this.options.__internal_clerkJSUrl&&(global.Clerk=ml(this.options.Clerk)?new this.options.Clerk(W(this,_d),{proxyUrl:this.proxyUrl,domain:this.domain}):this.options.Clerk),!global.Clerk)throw Error(`Failed to download latest ClerkJS. Contact support@clerk.com.`);return global.Clerk}async getClerkUIEntryChunk(){let e=this.options.ui,t=!!this.options.__internal_clerkUIUrl;if(e?.ClerkUI&&!t)return e.ClerkUI;if(!((e||this.options.prefetchUI===!1)&&!t)){if(await qu({...this.options,publishableKey:W(this,_d),proxyUrl:this.proxyUrl,domain:this.domain,nonce:this.options.nonce}),!global.__internal_ClerkUICtor)throw Error(`Failed to download latest Clerk UI. Contact support@clerk.com.`);return global.__internal_ClerkUICtor}}get version(){return this.clerkjs?.version}get client(){if(this.clerkjs)return this.clerkjs.client}get session(){if(this.clerkjs)return this.clerkjs.session}get user(){if(this.clerkjs)return this.clerkjs.user}get organization(){if(this.clerkjs)return this.clerkjs.organization}get telemetry(){if(this.clerkjs)return this.clerkjs.telemetry}get __internal_environment(){if(this.clerkjs)return this.clerkjs.__internal_environment}get isSignedIn(){return this.clerkjs?this.clerkjs.isSignedIn:!1}get billing(){return this.clerkjs?.billing}get __internal_state(){return this.loaded&&this.clerkjs?this.clerkjs.__internal_state:W(this,yd)}get apiKeys(){return this.clerkjs?.apiKeys}get oauthApplication(){return this.clerkjs?.oauthApplication}__internal_setEnvironment(...e){if(this.clerkjs&&`__internal_setEnvironment`in this.clerkjs)this.clerkjs.__internal_setEnvironment(e);else return}get __internal_lastEmittedResources(){return this.clerkjs?.__internal_lastEmittedResources}};md=new WeakMap,hd=new WeakMap,gd=new WeakMap,_d=new WeakMap,vd=new WeakMap,yd=new WeakMap,bd=new WeakMap,xd=new WeakSet,Sd=function(){return new Promise(e=>{this.addOnLoaded(()=>e(this.clerkjs))})},cu(Cd,bd);var wd=Cd;function Td(e){let{initialState:t,children:n,...r}=e,{isomorphicClerk:i,clerkStatus:a}=Dd(pl(r));return g.createElement(fc,{initialState:t,clerk:i,clerkStatus:a},n)}var K=_l(Td,`ClerkProvider`,Wc);K.displayName=`ClerkProvider`;var Ed=od?`shared`:``,Dd=e=>{let t=g.useMemo(()=>({clerkUIVariant:Ed,...e}),[e]),n=g.useRef(wd.getOrCreateInstance(t)),[r,i]=g.useState(n.current.status);return g.useEffect(()=>{n.current.__internal_updateProps({appearance:e.appearance})},[e.appearance]),g.useEffect(()=>{n.current.__internal_updateProps({options:e})},[e.localization]),g.useEffect(()=>(n.current.on(`status`,i),()=>{n.current&&n.current.off(`status`,i),wd.clearInstance()}),[]),{isomorphicClerk:n.current,clerkStatus:r}},Od=t((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.fragment`);function r(e,n,r){var i=null;if(r!==void 0&&(i=``+r),n.key!==void 0&&(i=``+n.key),`key`in n)for(var a in r={},n)a!==`key`&&(r[a]=n[a]);else r=n;return n=r.ref,{$$typeof:t,type:e,key:i,ref:n===void 0?null:n,props:r}}e.Fragment=n,e.jsx=r,e.jsxs=r})),q=e(t(((e,t)=>{t.exports=Od()}))(),1);if(typeof window<`u`&&!window.global&&(window.global=typeof global>`u`?window:global),globalThis.__clerkSharedModules){let e=globalThis.__clerkSharedModules.react?.version;e&&e!==`19.2.5`&&console.warn(`[@clerk/ui/register] React version mismatch detected. Already registered: ${e}, current import: 19.2.5. This may cause issues with the shared @clerk/ui variant.`)}else globalThis.__clerkSharedModules={react:g,"react-dom":ze,"react-dom/client":h,"react/jsx-runtime":q};var kd=z(({clerk:e,children:t,...n})=>{let{appearance:r,getContainer:i,component:a,signUpFallbackRedirectUrl:o,forceRedirectUrl:s,fallbackRedirectUrl:c,signUpForceRedirectUrl:l,mode:u,initialValues:d,withSignUp:f,oauthFlow:p,...m}=n;t=ll(t,`Sign in`);let h=cl(t)(`SignInButton`),_=()=>{let t={forceRedirectUrl:s,fallbackRedirectUrl:c,signUpFallbackRedirectUrl:o,signUpForceRedirectUrl:l,initialValues:d,withSignUp:f,oauthFlow:p};return u===`modal`?e.openSignIn({...t,appearance:r,getContainer:i}):e.redirectToSignIn({...t,signInFallbackRedirectUrl:c,signInForceRedirectUrl:s})},v=async e=>(h&&typeof h==`object`&&`props`in h&&await ul(h.props.onClick)(e),_()),y={...m,onClick:v};return g.cloneElement(h,y)},{component:`SignInButton`,renderWhileLoading:!0});z(({clerk:e,children:t,...n})=>{let{redirectUrl:r,getContainer:i,component:a,...o}=n;t=ll(t,`Sign in with Metamask`);let s=cl(t)(`SignInWithMetamaskButton`),c=async()=>{async function t(){await e.authenticateWithMetamask({redirectUrl:r||void 0})}t()},l=async e=>(await ul(s.props.onClick)(e),c()),u={...o,onClick:l};return g.cloneElement(s,u)},{component:`SignInWithMetamask`,renderWhileLoading:!0}),z(({clerk:e,children:t,...n})=>{let{redirectUrl:r=`/`,sessionId:i,signOutOptions:a,getContainer:o,component:s,...c}=n;a&&pu("SignOutButton `signOutOptions`","Use the `redirectUrl` and `sessionId` props directly instead."),t=ll(t,`Sign out`);let l=cl(t)(`SignOutButton`),u=()=>e.signOut({redirectUrl:r,...i!==void 0&&{sessionId:i},...a}),d=async e=>(await ul(l.props.onClick)(e),u()),f={...c,onClick:d};return g.cloneElement(l,f)},{component:`SignOutButton`,renderWhileLoading:!0});var Ad=z(({clerk:e,children:t,...n})=>{let{appearance:r,unsafeMetadata:i,getContainer:a,component:o,fallbackRedirectUrl:s,forceRedirectUrl:c,signInFallbackRedirectUrl:l,signInForceRedirectUrl:u,mode:d,initialValues:f,oauthFlow:p,...m}=n;t=ll(t,`Sign up`);let h=cl(t)(`SignUpButton`),_=()=>{let t={fallbackRedirectUrl:s,forceRedirectUrl:c,signInFallbackRedirectUrl:l,signInForceRedirectUrl:u,initialValues:f,oauthFlow:p};return d===`modal`?e.openSignUp({...t,appearance:r,unsafeMetadata:i,getContainer:a}):e.redirectToSignUp({...t,signUpFallbackRedirectUrl:s,signUpForceRedirectUrl:c})},v=async e=>(h&&typeof h==`object`&&`props`in h&&await ul(h.props.onClick)(e),_()),y={...m,onClick:v};return g.cloneElement(h,y)},{component:`SignUpButton`,renderWhileLoading:!0});Mc({packageName:`@clerk/react`}),ed(`@clerk/react`);function jd(e){if(typeof window>`u`||window.navigator==null)return!1;let t=window.navigator.userAgentData?.brands;return Array.isArray(t)&&t.some(t=>e.test(t.brand))||e.test(window.navigator.userAgent)}function Md(e){return typeof window<`u`&&window.navigator!=null?e.test(window.navigator.userAgentData?.platform||window.navigator.platform):!1}function Nd(e){let t=null;return()=>(t??=e(),t)}var Pd=Nd(function(){return Md(/^Mac/i)}),Fd=Nd(function(){return Md(/^iPhone/i)}),Id=Nd(function(){return Md(/^iPad/i)||Pd()&&navigator.maxTouchPoints>1}),Ld=Nd(function(){return Fd()||Id()}),Rd=Nd(function(){return jd(/AppleWebKit/i)&&!zd()}),zd=Nd(function(){return jd(/Chrome/i)}),Bd=Nd(function(){return jd(/Android/i)}),Vd=Nd(function(){return jd(/Firefox/i)});function Hd(e){if(Wd())e.focus({preventScroll:!0});else{let t=Gd(e);e.focus(),Kd(t)}}var Ud=null;function Wd(){if(Ud==null){Ud=!1;try{document.createElement(`div`).focus({get preventScroll(){return Ud=!0,!0}})}catch{}}return Ud}function Gd(e){let t=e.parentNode,n=[],r=document.scrollingElement||document.documentElement;for(;t instanceof HTMLElement&&t!==r;)(t.offsetHeight<t.scrollHeight||t.offsetWidth<t.scrollWidth)&&n.push({element:t,scrollTop:t.scrollTop,scrollLeft:t.scrollLeft}),t=t.parentNode;return r instanceof HTMLElement&&n.push({element:r,scrollTop:r.scrollTop,scrollLeft:r.scrollLeft}),n}function Kd(e){for(let{element:t,scrollTop:n,scrollLeft:r}of e)t.scrollTop=n,t.scrollLeft=r}function qd(e,t,n=!0){let{metaKey:r,ctrlKey:i,altKey:a,shiftKey:o}=t;Vd()&&window.event?.type?.startsWith(`key`)&&e.target===`_blank`&&(Pd()?r=!0:i=!0);let s=Rd()&&Pd()&&!Id()?new KeyboardEvent(`keydown`,{keyIdentifier:`Enter`,metaKey:r,ctrlKey:i,altKey:a,shiftKey:o}):new MouseEvent(`click`,{metaKey:r,ctrlKey:i,altKey:a,shiftKey:o,detail:1,bubbles:!0,cancelable:!0});qd.isOpening=n,Hd(e),e.dispatchEvent(s),qd.isOpening=!1}qd.isOpening=!1;var Jd=typeof document<`u`?g.useLayoutEffect:()=>{},Yd={prefix:String(Math.round(Math.random()*1e10)),current:0},Xd=g.createContext(Yd),Zd=g.createContext(!1);typeof window<`u`&&window.document&&window.document.createElement;var Qd=new WeakMap;function $d(e=!1){let t=(0,g.useContext)(Xd),n=(0,g.useRef)(null);if(n.current===null&&!e){let e=g.default.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED?.ReactCurrentOwner?.current;if(e){let n=Qd.get(e);n==null?Qd.set(e,{id:t.current,state:e.memoizedState}):e.memoizedState!==n.state&&(t.current=n.id,Qd.delete(e))}n.current=++t.current}return n.current}function ef(e){let t=(0,g.useContext)(Xd),n=$d(!!e),r=`react-aria${t.prefix}`;return e||`${r}-${n}`}function tf(e){let t=g.useId(),[n]=(0,g.useState)(sf()),r=n?`react-aria`:`react-aria${Yd.prefix}`;return e||`${r}-${t}`}var nf=typeof g.useId==`function`?tf:ef;function rf(){return!1}function af(){return!0}function of(e){return()=>{}}function sf(){return typeof g.useSyncExternalStore==`function`?g.useSyncExternalStore(of,rf,af):(0,g.useContext)(Zd)}var cf=!!(typeof window<`u`&&window.document&&window.document.createElement),lf=new Map,uf;typeof FinalizationRegistry<`u`&&(uf=new FinalizationRegistry(e=>{lf.delete(e)}));function df(e){let[t,n]=(0,g.useState)(e),r=(0,g.useRef)(null),i=nf(t),a=(0,g.useRef)(null);if(uf&&uf.register(a,i),cf){let e=lf.get(i);e&&!e.includes(r)?e.push(r):lf.set(i,[r])}return Jd(()=>{let e=i;return()=>{uf&&uf.unregister(a),lf.delete(e)}},[i]),(0,g.useEffect)(()=>{let e=r.current;return e&&n(e),()=>{e&&(r.current=null)}}),i}function ff(e,t){if(e===t)return e;let n=lf.get(e);if(n)return n.forEach(e=>e.current=t),t;let r=lf.get(t);return r?(r.forEach(t=>t.current=e),e):t}function pf(...e){return(...t)=>{for(let n of e)typeof n==`function`&&n(...t)}}var J=e=>e?.ownerDocument??document,mf=e=>e&&`window`in e&&e.window===e?e:J(e).defaultView||window;function hf(e){return typeof e==`object`&&!!e&&`nodeType`in e&&typeof e.nodeType==`number`}function gf(e){return hf(e)&&e.nodeType===Node.DOCUMENT_FRAGMENT_NODE&&`host`in e}var _f=!1;function vf(){return _f}function yf(e,t){if(!vf())return t&&e?e.contains(t):!1;if(!e||!t)return!1;let n=t;for(;n!==null;){if(n===e)return!0;n=n.tagName===`SLOT`&&n.assignedSlot?n.assignedSlot.parentNode:gf(n)?n.host:n.parentNode}return!1}var bf=(e=document)=>{if(!vf())return e.activeElement;let t=e.activeElement;for(;t&&`shadowRoot`in t&&t.shadowRoot?.activeElement;)t=t.shadowRoot.activeElement;return t};function Y(e){if(vf()&&e.target instanceof Element&&e.target.shadowRoot){if(`composedPath`in e)return e.composedPath()[0]??null;if(`composedPath`in e.nativeEvent)return e.nativeEvent.composedPath()[0]??null}return e.target}function xf(...e){return e.length===1&&e[0]?e[0]:t=>{let n=!1,r=e.map(e=>{let r=Sf(e,t);return n||=typeof r==`function`,r});if(n)return()=>{r.forEach((t,n)=>{typeof t==`function`?t():Sf(e[n],null)})}}}function Sf(e,t){if(typeof e==`function`)return e(t);e!=null&&(e.current=t)}function Cf(e){var t,n,r=``;if(typeof e==`string`||typeof e==`number`)r+=e;else if(typeof e==`object`)if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(n=Cf(e[t]))&&(r&&(r+=` `),r+=n)}else for(n in e)e[n]&&(r&&(r+=` `),r+=n);return r}function wf(){for(var e,t,n=0,r=``,i=arguments.length;n<i;n++)(e=arguments[n])&&(t=Cf(e))&&(r&&(r+=` `),r+=t);return r}function Tf(...e){let t={...e[0]};for(let n=1;n<e.length;n++){let r=e[n];for(let e in r){let n=t[e],i=r[e];typeof n==`function`&&typeof i==`function`&&e[0]===`o`&&e[1]===`n`&&e.charCodeAt(2)>=65&&e.charCodeAt(2)<=90?t[e]=pf(n,i):(e===`className`||e===`UNSAFE_className`)&&typeof n==`string`&&typeof i==`string`?t[e]=wf(n,i):e===`id`&&n&&i?t.id=ff(n,i):e===`ref`&&n&&i?t.ref=xf(n,i):t[e]=i===void 0?n:i}}return t}var Ef=new Set([`id`]),Df=new Set([`aria-label`,`aria-labelledby`,`aria-describedby`,`aria-details`]),Of=new Set([`href`,`hrefLang`,`target`,`rel`,`download`,`ping`,`referrerPolicy`]),kf=new Set([`dir`,`lang`,`hidden`,`inert`,`translate`]),Af=new Set(`onClick.onAuxClick.onContextMenu.onDoubleClick.onMouseDown.onMouseEnter.onMouseLeave.onMouseMove.onMouseOut.onMouseOver.onMouseUp.onTouchCancel.onTouchEnd.onTouchMove.onTouchStart.onPointerDown.onPointerMove.onPointerUp.onPointerCancel.onPointerEnter.onPointerLeave.onPointerOver.onPointerOut.onGotPointerCapture.onLostPointerCapture.onScroll.onWheel.onAnimationStart.onAnimationEnd.onAnimationIteration.onTransitionCancel.onTransitionEnd.onTransitionRun.onTransitionStart`.split(`.`)),jf=/^(data-.*)$/;function Mf(e,t={}){let{labelable:n,isLink:r,global:i,events:a=i,propNames:o}=t,s={};for(let t in e)Object.prototype.hasOwnProperty.call(e,t)&&(Ef.has(t)||n&&Df.has(t)||r&&Of.has(t)||i&&kf.has(t)||a&&(Af.has(t)||t.endsWith(`Capture`)&&Af.has(t.slice(0,-7)))||o?.has(t)||jf.test(t))&&(s[t]=e[t]);return s}var Nf=new Map,Pf=new Set;function Ff(){if(typeof window>`u`)return;function e(e){return`propertyName`in e}let t=t=>{let r=Y(t);if(!e(t)||!r)return;let i=Nf.get(r);i||(i=new Set,Nf.set(r,i),r.addEventListener(`transitioncancel`,n,{once:!0})),i.add(t.propertyName)},n=t=>{let r=Y(t);if(!e(t)||!r)return;let i=Nf.get(r);if(i&&(i.delete(t.propertyName),i.size===0&&(r.removeEventListener(`transitioncancel`,n),Nf.delete(r)),Nf.size===0)){for(let e of Pf)e();Pf.clear()}};document.body.addEventListener(`transitionrun`,t),document.body.addEventListener(`transitionend`,n)}typeof document<`u`&&(document.readyState===`loading`?document.addEventListener(`DOMContentLoaded`,Ff):Ff());function If(){for(let[e]of Nf)`isConnected`in e&&!e.isConnected&&Nf.delete(e)}function Lf(e){requestAnimationFrame(()=>{If(),Nf.size===0?e():Pf.add(e)})}function Rf(){let e=(0,g.useRef)(new Map),t=(0,g.useCallback)((t,n,r,i)=>{let a=i?.once?(...t)=>{e.current.delete(r),r(...t)}:r;e.current.set(r,{type:n,eventTarget:t,fn:a,options:i}),t.addEventListener(n,a,i)},[]),n=(0,g.useCallback)((t,n,r,i)=>{let a=e.current.get(r)?.fn||r;t.removeEventListener(n,a,i),e.current.delete(r)},[]),r=(0,g.useCallback)(()=>{e.current.forEach((e,t)=>{n(e.eventTarget,e.type,t,e.options)})},[n]);return(0,g.useEffect)(()=>r,[r]),{addGlobalListener:t,removeGlobalListener:n,removeAllGlobalListeners:r}}function zf(e){let t=(0,g.useRef)(null),n=(0,g.useRef)(void 0),r=(0,g.useCallback)(t=>{if(typeof e==`function`){let n=e,r=n(t);return()=>{typeof r==`function`?r():n(null)}}else if(e)return e.current=t,()=>{e.current=null}},[e]);return(0,g.useMemo)(()=>({get current(){return t.current},set current(e){t.current=e,n.current&&=(n.current(),void 0),e!=null&&(n.current=r(e))}}),[r])}var Bf=g.useInsertionEffect??Jd;function Vf(e){let t=(0,g.useRef)(null);return Bf(()=>{t.current=e},[e]),(0,g.useCallback)((...e)=>{let n=t.current;return n?.(...e)},[])}function Hf(e,t){Jd(()=>{if(e&&e.ref&&t)return e.ref.current=t.current,()=>{e.ref&&(e.ref.current=null)}})}function Uf(e){return e.pointerType===``&&e.isTrusted?!0:Bd()&&e.pointerType?e.type===`click`&&e.buttons===1:e.detail===0&&!e.pointerType}function Wf(e){return!Bd()&&e.width===0&&e.height===0||e.width===1&&e.height===1&&e.pressure===0&&e.detail===0&&e.pointerType===`mouse`}var Gf=typeof Element<`u`&&`checkVisibility`in Element.prototype;function Kf(e){let t=mf(e);if(!(e instanceof t.HTMLElement)&&!(e instanceof t.SVGElement))return!1;let{display:n,visibility:r}=e.style,i=n!==`none`&&r!==`hidden`&&r!==`collapse`;if(i){let{getComputedStyle:t}=e.ownerDocument.defaultView,{display:n,visibility:r}=t(e);i=n!==`none`&&r!==`hidden`&&r!==`collapse`}return i}function qf(e,t){return!e.hasAttribute(`hidden`)&&!e.hasAttribute(`data-react-aria-prevent-focus`)&&(e.nodeName===`DETAILS`&&t&&t.nodeName!==`SUMMARY`?e.hasAttribute(`open`):!0)}function Jf(e,t){return Gf?e.checkVisibility({visibilityProperty:!0})&&!e.closest(`[data-react-aria-prevent-focus]`):e.nodeName!==`#comment`&&Kf(e)&&qf(e,t)&&(!e.parentElement||Jf(e.parentElement,e))}var Yf=[`input:not([disabled]):not([type=hidden])`,`select:not([disabled])`,`textarea:not([disabled])`,`button:not([disabled])`,`a[href]`,`area[href]`,`summary`,`iframe`,`object`,`embed`,`audio[controls]`,`video[controls]`,`[contenteditable]:not([contenteditable^="false"])`,`permission`],Xf=Yf.join(`:not([hidden]),`)+`,[tabindex]:not([disabled]):not([hidden])`;Yf.push(`[tabindex]:not([tabindex="-1"]):not([disabled])`),Yf.join(`:not([hidden]):not([tabindex="-1"]),`);function Zf(e,t){return e.matches(Xf)&&!Qf(e)&&(t?.skipVisibilityCheck||Jf(e))}function Qf(e){let t=e;for(;t!=null;){if(t instanceof t.ownerDocument.defaultView.HTMLElement&&t.inert)return!0;t=t.parentElement}return!1}function $f(e){return e?.defaultView?.__webpack_nonce__||globalThis.__webpack_nonce__||void 0}var ep=new WeakMap;function tp(e){let t=e??(typeof document<`u`?document:void 0);if(!t)return $f(t);if(ep.has(t))return ep.get(t);let n=t.querySelector(`meta[property="csp-nonce"]`),r=n&&n instanceof mf(n).HTMLMetaElement&&(n.nonce||n.content)||$f(t)||void 0;return r!==void 0&&ep.set(t,r),r}var np=/\s+/g,rp=e=>typeof e!=`string`||!e?e:e.replace(np,` `).trim(),ip=(...e)=>{let t=[],n=e=>{if(!e&&e!==0&&e!==0n)return;if(Array.isArray(e)){for(let t=0,r=e.length;t<r;t++)n(e[t]);return}let r=typeof e;if(r===`string`||r===`number`||r===`bigint`){if(r===`number`&&e!==e)return;t.push(String(e))}else if(r===`object`){let n=Object.keys(e);for(let r=0,i=n.length;r<i;r++){let i=n[r];e[i]&&t.push(i)}}};for(let t=0,r=e.length;t<r;t++){let r=e[t];r!=null&&n(r)}return t.length>0?rp(t.join(` `)):void 0},ap=e=>e===!1?`false`:e===!0?`true`:e===0?`0`:e,op=e=>{if(!e||typeof e!=`object`)return!0;for(let t in e)return!1;return!0},sp=(e,t)=>{if(e===t)return!0;if(!e||!t)return!1;let n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(let i=0;i<n.length;i++){let a=n[i];if(!r.includes(a)||e[a]!==t[a])return!1}return!0},cp=(e,t)=>{for(let n in t)if(Object.prototype.hasOwnProperty.call(t,n)){let r=t[n];n in e?e[n]=ip(e[n],r):e[n]=r}return e},lp=(e,t)=>{for(let n=0;n<e.length;n++){let r=e[n];Array.isArray(r)?lp(r,t):r&&t.push(r)}},up=(...e)=>{let t=[];lp(e,t);let n=[];for(let e=0;e<t.length;e++)t[e]&&n.push(t[e]);return n},dp=(e,t)=>{let n={};for(let r in e){let i=e[r];if(r in t){let e=t[r];Array.isArray(i)||Array.isArray(e)?n[r]=up(e,i):typeof i==`object`&&typeof e==`object`&&i&&e?n[r]=dp(i,e):n[r]=e+` `+i}else n[r]=i}for(let r in t)r in e||(n[r]=t[r]);return n},fp={twMerge:!0,twMergeConfig:{}};function pp(){let e=null,t={},n=!1;return{get cachedTwMerge(){return e},set cachedTwMerge(t){e=t},get cachedTwMergeConfig(){return t},set cachedTwMergeConfig(e){t=e},get didTwMergeConfigChange(){return n},set didTwMergeConfigChange(e){n=e},reset(){e=null,t={},n=!1}}}var mp=pp(),hp=e=>{let t=(t,n)=>{let{extend:r=null,slots:i={},variants:a={},compoundVariants:o=[],compoundSlots:s=[],defaultVariants:c={}}=t,l={...fp,...n},u=r?.base?ip(r.base,t?.base):t?.base,d=r?.variants&&!op(r.variants)?dp(a,r.variants):a,f=r?.defaultVariants&&!op(r.defaultVariants)?{...r.defaultVariants,...c}:c;!op(l.twMergeConfig)&&!sp(l.twMergeConfig,mp.cachedTwMergeConfig)&&(mp.didTwMergeConfigChange=!0,mp.cachedTwMergeConfig=l.twMergeConfig);let p=op(r?.slots),m=op(i)?{}:{base:ip(t?.base,p&&r?.base),...i},h=p?m:cp({...r?.slots},op(m)?{base:t?.base}:m),g=op(r?.compoundVariants)?o:up(r?.compoundVariants,o),_=t=>{if(op(d)&&op(i)&&p)return e(u,t?.class,t?.className)(l);if(g&&!Array.isArray(g))throw TypeError(`The "compoundVariants" prop must be an array. Received: ${typeof g}`);if(s&&!Array.isArray(s))throw TypeError(`The "compoundSlots" prop must be an array. Received: ${typeof s}`);let n=(e,n=d,r=null,i=null)=>{let a=n[e];if(!a||op(a))return null;let o=i?.[e]??t?.[e];if(o===null)return null;let s=ap(o);if(typeof s==`object`)return null;let c=f?.[e];return a[(s??ap(c))||`false`]},r=()=>{if(!d)return null;let e=Object.keys(d),t=[];for(let r=0;r<e.length;r++){let i=n(e[r],d);i&&t.push(i)}return t},a=(e,t)=>{if(!d||typeof d!=`object`)return null;let r=[];for(let i in d){let a=n(i,d,e,t),o=e===`base`&&typeof a==`string`?a:a&&a[e];o&&r.push(o)}return r},o={};for(let e in t){let n=t[e];n!==void 0&&(o[e]=n)}let c=(e,n)=>{let r=typeof t?.[e]==`object`?{[e]:t[e]?.initial}:{};return{...f,...o,...r,...n}},m=(e=[],t)=>{let n=[],r=e.length;for(let i=0;i<r;i++){let{class:r,className:a,...o}=e[i],s=!0,l=c(null,t);for(let e in o){let t=o[e],n=l[e];if(Array.isArray(t)){if(!t.includes(n)){s=!1;break}}else{if((t==null||t===!1)&&(n==null||n===!1))continue;if(n!==t){s=!1;break}}}s&&(r&&n.push(r),a&&n.push(a))}return n},_=t=>{let n=m(g,t);if(!Array.isArray(n))return n;let r={},i=e;for(let e=0;e<n.length;e++){let t=n[e];if(typeof t==`string`)r.base=i(r.base,t)(l);else if(typeof t==`object`)for(let e in t)r[e]=i(r[e],t[e])(l)}return r},v=e=>{if(s.length<1)return null;let t={},n=c(null,e);for(let e=0;e<s.length;e++){let{slots:r=[],class:i,className:a,...o}=s[e];if(!op(o)){let e=!0;for(let t in o){let r=n[t],i=o[t];if(r===void 0||(Array.isArray(i)?!i.includes(r):i!==r)){e=!1;break}}if(!e)continue}for(let e=0;e<r.length;e++){let n=r[e];t[n]||(t[n]=[]),t[n].push([i,a])}}return t};if(!op(i)||!p){let t={};if(typeof h==`object`&&!op(h)){let n=e;for(let e in h)t[e]=t=>{let r=_(t),i=v(t);return n(h[e],a(e,t),r?r[e]:void 0,i?i[e]:void 0,t?.class,t?.className)(l)}}return t}return e(u,r(),m(g),t?.class,t?.className)(l)};return _.variantKeys=(()=>{if(!(!d||typeof d!=`object`))return Object.keys(d)})(),_.extend=r,_.base=u,_.slots=h,_.variants=d,_.defaultVariants=f,_.compoundSlots=s,_.compoundVariants=g,_};return{tv:t,createTV:e=>(n,r)=>t(n,r?dp(e,r):e)}},gp=(e,t)=>{let n=Array(e.length+t.length);for(let t=0;t<e.length;t++)n[t]=e[t];for(let r=0;r<t.length;r++)n[e.length+r]=t[r];return n},_p=(e,t)=>({classGroupId:e,validator:t}),vp=(e=new Map,t=null,n)=>({nextPart:e,validators:t,classGroupId:n}),yp=`-`,bp=[],xp=`arbitrary..`,Sp=e=>{let t=Tp(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:e=>{if(e.startsWith(`[`)&&e.endsWith(`]`))return wp(e);let n=e.split(yp);return Cp(n,+(n[0]===``&&n.length>1),t)},getConflictingClassGroupIds:(e,t)=>{if(t){let t=r[e],i=n[e];return t?i?gp(i,t):t:i||bp}return n[e]||bp}}},Cp=(e,t,n)=>{if(e.length-t===0)return n.classGroupId;let r=e[t],i=n.nextPart.get(r);if(i){let n=Cp(e,t+1,i);if(n)return n}let a=n.validators;if(a===null)return;let o=t===0?e.join(yp):e.slice(t).join(yp),s=a.length;for(let e=0;e<s;e++){let t=a[e];if(t.validator(o))return t.classGroupId}},wp=e=>e.slice(1,-1).indexOf(`:`)===-1?void 0:(()=>{let t=e.slice(1,-1),n=t.indexOf(`:`),r=t.slice(0,n);return r?xp+r:void 0})(),Tp=e=>{let{theme:t,classGroups:n}=e;return Ep(n,t)},Ep=(e,t)=>{let n=vp();for(let r in e){let i=e[r];Dp(i,n,r,t)}return n},Dp=(e,t,n,r)=>{let i=e.length;for(let a=0;a<i;a++){let i=e[a];Op(i,t,n,r)}},Op=(e,t,n,r)=>{if(typeof e==`string`){kp(e,t,n);return}if(typeof e==`function`){Ap(e,t,n,r);return}jp(e,t,n,r)},kp=(e,t,n)=>{let r=e===``?t:Mp(t,e);r.classGroupId=n},Ap=(e,t,n,r)=>{if(Np(e)){Dp(e(r),t,n,r);return}t.validators===null&&(t.validators=[]),t.validators.push(_p(n,e))},jp=(e,t,n,r)=>{let i=Object.entries(e),a=i.length;for(let e=0;e<a;e++){let[a,o]=i[e];Dp(o,Mp(t,a),n,r)}},Mp=(e,t)=>{let n=e,r=t.split(yp),i=r.length;for(let e=0;e<i;e++){let t=r[e],i=n.nextPart.get(t);i||(i=vp(),n.nextPart.set(t,i)),n=i}return n},Np=e=>`isThemeGetter`in e&&e.isThemeGetter===!0,Pp=e=>{if(e<1)return{get:()=>void 0,set:()=>{}};let t=0,n=Object.create(null),r=Object.create(null),i=(i,a)=>{n[i]=a,t++,t>e&&(t=0,r=n,n=Object.create(null))};return{get(e){let t=n[e];if(t!==void 0)return t;if((t=r[e])!==void 0)return i(e,t),t},set(e,t){e in n?n[e]=t:i(e,t)}}},Fp=`!`,Ip=`:`,Lp=[],Rp=(e,t,n,r,i)=>({modifiers:e,hasImportantModifier:t,baseClassName:n,maybePostfixModifierPosition:r,isExternal:i}),zp=e=>{let{prefix:t,experimentalParseClassName:n}=e,r=e=>{let t=[],n=0,r=0,i=0,a,o=e.length;for(let s=0;s<o;s++){let o=e[s];if(n===0&&r===0){if(o===Ip){t.push(e.slice(i,s)),i=s+1;continue}if(o===`/`){a=s;continue}}o===`[`?n++:o===`]`?n--:o===`(`?r++:o===`)`&&r--}let s=t.length===0?e:e.slice(i),c=s,l=!1;s.endsWith(Fp)?(c=s.slice(0,-1),l=!0):s.startsWith(Fp)&&(c=s.slice(1),l=!0);let u=a&&a>i?a-i:void 0;return Rp(t,l,c,u)};if(t){let e=t+Ip,n=r;r=t=>t.startsWith(e)?n(t.slice(e.length)):Rp(Lp,!1,t,void 0,!0)}if(n){let e=r;r=t=>n({className:t,parseClassName:e})}return r},Bp=e=>{let t=new Map;return e.orderSensitiveModifiers.forEach((e,n)=>{t.set(e,1e6+n)}),e=>{let n=[],r=[];for(let i=0;i<e.length;i++){let a=e[i],o=a[0]===`[`,s=t.has(a);o||s?(r.length>0&&(r.sort(),n.push(...r),r=[]),n.push(a)):r.push(a)}return r.length>0&&(r.sort(),n.push(...r)),n}},Vp=e=>({cache:Pp(e.cacheSize),parseClassName:zp(e),sortModifiers:Bp(e),...Sp(e)}),Hp=/\s+/,Up=(e,t)=>{let{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:i,sortModifiers:a}=t,o=[],s=e.trim().split(Hp),c=``;for(let e=s.length-1;e>=0;--e){let t=s[e],{isExternal:l,modifiers:u,hasImportantModifier:d,baseClassName:f,maybePostfixModifierPosition:p}=n(t);if(l){c=t+(c.length>0?` `+c:c);continue}let m=!!p,h=r(m?f.substring(0,p):f);if(!h){if(!m){c=t+(c.length>0?` `+c:c);continue}if(h=r(f),!h){c=t+(c.length>0?` `+c:c);continue}m=!1}let g=u.length===0?``:u.length===1?u[0]:a(u).join(`:`),_=d?g+Fp:g,v=_+h;if(o.indexOf(v)>-1)continue;o.push(v);let y=i(h,m);for(let e=0;e<y.length;++e){let t=y[e];o.push(_+t)}c=t+(c.length>0?` `+c:c)}return c},Wp=(...e)=>{let t=0,n,r,i=``;for(;t<e.length;)(n=e[t++])&&(r=Gp(n))&&(i&&(i+=` `),i+=r);return i},Gp=e=>{if(typeof e==`string`)return e;let t,n=``;for(let r=0;r<e.length;r++)e[r]&&(t=Gp(e[r]))&&(n&&(n+=` `),n+=t);return n},Kp=(e,...t)=>{let n,r,i,a,o=o=>(n=Vp(t.reduce((e,t)=>t(e),e())),r=n.cache.get,i=n.cache.set,a=s,s(o)),s=e=>{let t=r(e);if(t)return t;let a=Up(e,n);return i(e,a),a};return a=o,(...e)=>a(Wp(...e))},qp=[],Jp=e=>{let t=t=>t[e]||qp;return t.isThemeGetter=!0,t},Yp=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,Xp=/^\((?:(\w[\w-]*):)?(.+)\)$/i,Zp=/^\d+\/\d+$/,Qp=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,$p=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,em=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,tm=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,nm=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,rm=e=>Zp.test(e),X=e=>!!e&&!Number.isNaN(Number(e)),im=e=>!!e&&Number.isInteger(Number(e)),am=e=>e.endsWith(`%`)&&X(e.slice(0,-1)),om=e=>Qp.test(e),sm=()=>!0,cm=e=>$p.test(e)&&!em.test(e),lm=()=>!1,um=e=>tm.test(e),dm=e=>nm.test(e),fm=e=>!Z(e)&&!Q(e),pm=e=>Tm(e,km,lm),Z=e=>Yp.test(e),mm=e=>Tm(e,Am,cm),hm=e=>Tm(e,jm,X),gm=e=>Tm(e,Dm,lm),_m=e=>Tm(e,Om,dm),vm=e=>Tm(e,Nm,um),Q=e=>Xp.test(e),ym=e=>Em(e,Am),bm=e=>Em(e,Mm),xm=e=>Em(e,Dm),Sm=e=>Em(e,km),Cm=e=>Em(e,Om),wm=e=>Em(e,Nm,!0),Tm=(e,t,n)=>{let r=Yp.exec(e);return r?r[1]?t(r[1]):n(r[2]):!1},Em=(e,t,n=!1)=>{let r=Xp.exec(e);return r?r[1]?t(r[1]):n:!1},Dm=e=>e===`position`||e===`percentage`,Om=e=>e===`image`||e===`url`,km=e=>e===`length`||e===`size`||e===`bg-size`,Am=e=>e===`length`,jm=e=>e===`number`,Mm=e=>e===`family-name`,Nm=e=>e===`shadow`,Pm=()=>{let e=Jp(`color`),t=Jp(`font`),n=Jp(`text`),r=Jp(`font-weight`),i=Jp(`tracking`),a=Jp(`leading`),o=Jp(`breakpoint`),s=Jp(`container`),c=Jp(`spacing`),l=Jp(`radius`),u=Jp(`shadow`),d=Jp(`inset-shadow`),f=Jp(`text-shadow`),p=Jp(`drop-shadow`),m=Jp(`blur`),h=Jp(`perspective`),g=Jp(`aspect`),_=Jp(`ease`),v=Jp(`animate`),y=()=>[`auto`,`avoid`,`all`,`avoid-page`,`page`,`left`,`right`,`column`],b=()=>[`center`,`top`,`bottom`,`left`,`right`,`top-left`,`left-top`,`top-right`,`right-top`,`bottom-right`,`right-bottom`,`bottom-left`,`left-bottom`],x=()=>[...b(),Q,Z],S=()=>[`auto`,`hidden`,`clip`,`visible`,`scroll`],C=()=>[`auto`,`contain`,`none`],w=()=>[Q,Z,c],T=()=>[rm,`full`,`auto`,...w()],E=()=>[im,`none`,`subgrid`,Q,Z],D=()=>[`auto`,{span:[`full`,im,Q,Z]},im,Q,Z],O=()=>[im,`auto`,Q,Z],ee=()=>[`auto`,`min`,`max`,`fr`,Q,Z],te=()=>[`start`,`end`,`center`,`between`,`around`,`evenly`,`stretch`,`baseline`,`center-safe`,`end-safe`],ne=()=>[`start`,`end`,`center`,`stretch`,`center-safe`,`end-safe`],re=()=>[`auto`,...w()],ie=()=>[rm,`auto`,`full`,`dvw`,`dvh`,`lvw`,`lvh`,`svw`,`svh`,`min`,`max`,`fit`,...w()],k=()=>[e,Q,Z],ae=()=>[...b(),xm,gm,{position:[Q,Z]}],A=()=>[`no-repeat`,{repeat:[``,`x`,`y`,`space`,`round`]}],j=()=>[`auto`,`cover`,`contain`,Sm,pm,{size:[Q,Z]}],oe=()=>[am,ym,mm],se=()=>[``,`none`,`full`,l,Q,Z],ce=()=>[``,X,ym,mm],le=()=>[`solid`,`dashed`,`dotted`,`double`],M=()=>[`normal`,`multiply`,`screen`,`overlay`,`darken`,`lighten`,`color-dodge`,`color-burn`,`hard-light`,`soft-light`,`difference`,`exclusion`,`hue`,`saturation`,`color`,`luminosity`],N=()=>[X,am,xm,gm],ue=()=>[``,`none`,m,Q,Z],de=()=>[`none`,X,Q,Z],fe=()=>[`none`,X,Q,Z],pe=()=>[X,Q,Z],me=()=>[rm,`full`,...w()];return{cacheSize:500,theme:{animate:[`spin`,`ping`,`pulse`,`bounce`],aspect:[`video`],blur:[om],breakpoint:[om],color:[sm],container:[om],"drop-shadow":[om],ease:[`in`,`out`,`in-out`],font:[fm],"font-weight":[`thin`,`extralight`,`light`,`normal`,`medium`,`semibold`,`bold`,`extrabold`,`black`],"inset-shadow":[om],leading:[`none`,`tight`,`snug`,`normal`,`relaxed`,`loose`],perspective:[`dramatic`,`near`,`normal`,`midrange`,`distant`,`none`],radius:[om],shadow:[om],spacing:[`px`,X],text:[om],"text-shadow":[om],tracking:[`tighter`,`tight`,`normal`,`wide`,`wider`,`widest`]},classGroups:{aspect:[{aspect:[`auto`,`square`,rm,Z,Q,g]}],container:[`container`],columns:[{columns:[X,Z,Q,s]}],"break-after":[{"break-after":y()}],"break-before":[{"break-before":y()}],"break-inside":[{"break-inside":[`auto`,`avoid`,`avoid-page`,`avoid-column`]}],"box-decoration":[{"box-decoration":[`slice`,`clone`]}],box:[{box:[`border`,`content`]}],display:[`block`,`inline-block`,`inline`,`flex`,`inline-flex`,`table`,`inline-table`,`table-caption`,`table-cell`,`table-column`,`table-column-group`,`table-footer-group`,`table-header-group`,`table-row-group`,`table-row`,`flow-root`,`grid`,`inline-grid`,`contents`,`list-item`,`hidden`],sr:[`sr-only`,`not-sr-only`],float:[{float:[`right`,`left`,`none`,`start`,`end`]}],clear:[{clear:[`left`,`right`,`both`,`none`,`start`,`end`]}],isolation:[`isolate`,`isolation-auto`],"object-fit":[{object:[`contain`,`cover`,`fill`,`none`,`scale-down`]}],"object-position":[{object:x()}],overflow:[{overflow:S()}],"overflow-x":[{"overflow-x":S()}],"overflow-y":[{"overflow-y":S()}],overscroll:[{overscroll:C()}],"overscroll-x":[{"overscroll-x":C()}],"overscroll-y":[{"overscroll-y":C()}],position:[`static`,`fixed`,`absolute`,`relative`,`sticky`],inset:[{inset:T()}],"inset-x":[{"inset-x":T()}],"inset-y":[{"inset-y":T()}],start:[{start:T()}],end:[{end:T()}],top:[{top:T()}],right:[{right:T()}],bottom:[{bottom:T()}],left:[{left:T()}],visibility:[`visible`,`invisible`,`collapse`],z:[{z:[im,`auto`,Q,Z]}],basis:[{basis:[rm,`full`,`auto`,s,...w()]}],"flex-direction":[{flex:[`row`,`row-reverse`,`col`,`col-reverse`]}],"flex-wrap":[{flex:[`nowrap`,`wrap`,`wrap-reverse`]}],flex:[{flex:[X,rm,`auto`,`initial`,`none`,Z]}],grow:[{grow:[``,X,Q,Z]}],shrink:[{shrink:[``,X,Q,Z]}],order:[{order:[im,`first`,`last`,`none`,Q,Z]}],"grid-cols":[{"grid-cols":E()}],"col-start-end":[{col:D()}],"col-start":[{"col-start":O()}],"col-end":[{"col-end":O()}],"grid-rows":[{"grid-rows":E()}],"row-start-end":[{row:D()}],"row-start":[{"row-start":O()}],"row-end":[{"row-end":O()}],"grid-flow":[{"grid-flow":[`row`,`col`,`dense`,`row-dense`,`col-dense`]}],"auto-cols":[{"auto-cols":ee()}],"auto-rows":[{"auto-rows":ee()}],gap:[{gap:w()}],"gap-x":[{"gap-x":w()}],"gap-y":[{"gap-y":w()}],"justify-content":[{justify:[...te(),`normal`]}],"justify-items":[{"justify-items":[...ne(),`normal`]}],"justify-self":[{"justify-self":[`auto`,...ne()]}],"align-content":[{content:[`normal`,...te()]}],"align-items":[{items:[...ne(),{baseline:[``,`last`]}]}],"align-self":[{self:[`auto`,...ne(),{baseline:[``,`last`]}]}],"place-content":[{"place-content":te()}],"place-items":[{"place-items":[...ne(),`baseline`]}],"place-self":[{"place-self":[`auto`,...ne()]}],p:[{p:w()}],px:[{px:w()}],py:[{py:w()}],ps:[{ps:w()}],pe:[{pe:w()}],pt:[{pt:w()}],pr:[{pr:w()}],pb:[{pb:w()}],pl:[{pl:w()}],m:[{m:re()}],mx:[{mx:re()}],my:[{my:re()}],ms:[{ms:re()}],me:[{me:re()}],mt:[{mt:re()}],mr:[{mr:re()}],mb:[{mb:re()}],ml:[{ml:re()}],"space-x":[{"space-x":w()}],"space-x-reverse":[`space-x-reverse`],"space-y":[{"space-y":w()}],"space-y-reverse":[`space-y-reverse`],size:[{size:ie()}],w:[{w:[s,`screen`,...ie()]}],"min-w":[{"min-w":[s,`screen`,`none`,...ie()]}],"max-w":[{"max-w":[s,`screen`,`none`,`prose`,{screen:[o]},...ie()]}],h:[{h:[`screen`,`lh`,...ie()]}],"min-h":[{"min-h":[`screen`,`lh`,`none`,...ie()]}],"max-h":[{"max-h":[`screen`,`lh`,...ie()]}],"font-size":[{text:[`base`,n,ym,mm]}],"font-smoothing":[`antialiased`,`subpixel-antialiased`],"font-style":[`italic`,`not-italic`],"font-weight":[{font:[r,Q,hm]}],"font-stretch":[{"font-stretch":[`ultra-condensed`,`extra-condensed`,`condensed`,`semi-condensed`,`normal`,`semi-expanded`,`expanded`,`extra-expanded`,`ultra-expanded`,am,Z]}],"font-family":[{font:[bm,Z,t]}],"fvn-normal":[`normal-nums`],"fvn-ordinal":[`ordinal`],"fvn-slashed-zero":[`slashed-zero`],"fvn-figure":[`lining-nums`,`oldstyle-nums`],"fvn-spacing":[`proportional-nums`,`tabular-nums`],"fvn-fraction":[`diagonal-fractions`,`stacked-fractions`],tracking:[{tracking:[i,Q,Z]}],"line-clamp":[{"line-clamp":[X,`none`,Q,hm]}],leading:[{leading:[a,...w()]}],"list-image":[{"list-image":[`none`,Q,Z]}],"list-style-position":[{list:[`inside`,`outside`]}],"list-style-type":[{list:[`disc`,`decimal`,`none`,Q,Z]}],"text-alignment":[{text:[`left`,`center`,`right`,`justify`,`start`,`end`]}],"placeholder-color":[{placeholder:k()}],"text-color":[{text:k()}],"text-decoration":[`underline`,`overline`,`line-through`,`no-underline`],"text-decoration-style":[{decoration:[...le(),`wavy`]}],"text-decoration-thickness":[{decoration:[X,`from-font`,`auto`,Q,mm]}],"text-decoration-color":[{decoration:k()}],"underline-offset":[{"underline-offset":[X,`auto`,Q,Z]}],"text-transform":[`uppercase`,`lowercase`,`capitalize`,`normal-case`],"text-overflow":[`truncate`,`text-ellipsis`,`text-clip`],"text-wrap":[{text:[`wrap`,`nowrap`,`balance`,`pretty`]}],indent:[{indent:w()}],"vertical-align":[{align:[`baseline`,`top`,`middle`,`bottom`,`text-top`,`text-bottom`,`sub`,`super`,Q,Z]}],whitespace:[{whitespace:[`normal`,`nowrap`,`pre`,`pre-line`,`pre-wrap`,`break-spaces`]}],break:[{break:[`normal`,`words`,`all`,`keep`]}],wrap:[{wrap:[`break-word`,`anywhere`,`normal`]}],hyphens:[{hyphens:[`none`,`manual`,`auto`]}],content:[{content:[`none`,Q,Z]}],"bg-attachment":[{bg:[`fixed`,`local`,`scroll`]}],"bg-clip":[{"bg-clip":[`border`,`padding`,`content`,`text`]}],"bg-origin":[{"bg-origin":[`border`,`padding`,`content`]}],"bg-position":[{bg:ae()}],"bg-repeat":[{bg:A()}],"bg-size":[{bg:j()}],"bg-image":[{bg:[`none`,{linear:[{to:[`t`,`tr`,`r`,`br`,`b`,`bl`,`l`,`tl`]},im,Q,Z],radial:[``,Q,Z],conic:[im,Q,Z]},Cm,_m]}],"bg-color":[{bg:k()}],"gradient-from-pos":[{from:oe()}],"gradient-via-pos":[{via:oe()}],"gradient-to-pos":[{to:oe()}],"gradient-from":[{from:k()}],"gradient-via":[{via:k()}],"gradient-to":[{to:k()}],rounded:[{rounded:se()}],"rounded-s":[{"rounded-s":se()}],"rounded-e":[{"rounded-e":se()}],"rounded-t":[{"rounded-t":se()}],"rounded-r":[{"rounded-r":se()}],"rounded-b":[{"rounded-b":se()}],"rounded-l":[{"rounded-l":se()}],"rounded-ss":[{"rounded-ss":se()}],"rounded-se":[{"rounded-se":se()}],"rounded-ee":[{"rounded-ee":se()}],"rounded-es":[{"rounded-es":se()}],"rounded-tl":[{"rounded-tl":se()}],"rounded-tr":[{"rounded-tr":se()}],"rounded-br":[{"rounded-br":se()}],"rounded-bl":[{"rounded-bl":se()}],"border-w":[{border:ce()}],"border-w-x":[{"border-x":ce()}],"border-w-y":[{"border-y":ce()}],"border-w-s":[{"border-s":ce()}],"border-w-e":[{"border-e":ce()}],"border-w-t":[{"border-t":ce()}],"border-w-r":[{"border-r":ce()}],"border-w-b":[{"border-b":ce()}],"border-w-l":[{"border-l":ce()}],"divide-x":[{"divide-x":ce()}],"divide-x-reverse":[`divide-x-reverse`],"divide-y":[{"divide-y":ce()}],"divide-y-reverse":[`divide-y-reverse`],"border-style":[{border:[...le(),`hidden`,`none`]}],"divide-style":[{divide:[...le(),`hidden`,`none`]}],"border-color":[{border:k()}],"border-color-x":[{"border-x":k()}],"border-color-y":[{"border-y":k()}],"border-color-s":[{"border-s":k()}],"border-color-e":[{"border-e":k()}],"border-color-t":[{"border-t":k()}],"border-color-r":[{"border-r":k()}],"border-color-b":[{"border-b":k()}],"border-color-l":[{"border-l":k()}],"divide-color":[{divide:k()}],"outline-style":[{outline:[...le(),`none`,`hidden`]}],"outline-offset":[{"outline-offset":[X,Q,Z]}],"outline-w":[{outline:[``,X,ym,mm]}],"outline-color":[{outline:k()}],shadow:[{shadow:[``,`none`,u,wm,vm]}],"shadow-color":[{shadow:k()}],"inset-shadow":[{"inset-shadow":[`none`,d,wm,vm]}],"inset-shadow-color":[{"inset-shadow":k()}],"ring-w":[{ring:ce()}],"ring-w-inset":[`ring-inset`],"ring-color":[{ring:k()}],"ring-offset-w":[{"ring-offset":[X,mm]}],"ring-offset-color":[{"ring-offset":k()}],"inset-ring-w":[{"inset-ring":ce()}],"inset-ring-color":[{"inset-ring":k()}],"text-shadow":[{"text-shadow":[`none`,f,wm,vm]}],"text-shadow-color":[{"text-shadow":k()}],opacity:[{opacity:[X,Q,Z]}],"mix-blend":[{"mix-blend":[...M(),`plus-darker`,`plus-lighter`]}],"bg-blend":[{"bg-blend":M()}],"mask-clip":[{"mask-clip":[`border`,`padding`,`content`,`fill`,`stroke`,`view`]},`mask-no-clip`],"mask-composite":[{mask:[`add`,`subtract`,`intersect`,`exclude`]}],"mask-image-linear-pos":[{"mask-linear":[X]}],"mask-image-linear-from-pos":[{"mask-linear-from":N()}],"mask-image-linear-to-pos":[{"mask-linear-to":N()}],"mask-image-linear-from-color":[{"mask-linear-from":k()}],"mask-image-linear-to-color":[{"mask-linear-to":k()}],"mask-image-t-from-pos":[{"mask-t-from":N()}],"mask-image-t-to-pos":[{"mask-t-to":N()}],"mask-image-t-from-color":[{"mask-t-from":k()}],"mask-image-t-to-color":[{"mask-t-to":k()}],"mask-image-r-from-pos":[{"mask-r-from":N()}],"mask-image-r-to-pos":[{"mask-r-to":N()}],"mask-image-r-from-color":[{"mask-r-from":k()}],"mask-image-r-to-color":[{"mask-r-to":k()}],"mask-image-b-from-pos":[{"mask-b-from":N()}],"mask-image-b-to-pos":[{"mask-b-to":N()}],"mask-image-b-from-color":[{"mask-b-from":k()}],"mask-image-b-to-color":[{"mask-b-to":k()}],"mask-image-l-from-pos":[{"mask-l-from":N()}],"mask-image-l-to-pos":[{"mask-l-to":N()}],"mask-image-l-from-color":[{"mask-l-from":k()}],"mask-image-l-to-color":[{"mask-l-to":k()}],"mask-image-x-from-pos":[{"mask-x-from":N()}],"mask-image-x-to-pos":[{"mask-x-to":N()}],"mask-image-x-from-color":[{"mask-x-from":k()}],"mask-image-x-to-color":[{"mask-x-to":k()}],"mask-image-y-from-pos":[{"mask-y-from":N()}],"mask-image-y-to-pos":[{"mask-y-to":N()}],"mask-image-y-from-color":[{"mask-y-from":k()}],"mask-image-y-to-color":[{"mask-y-to":k()}],"mask-image-radial":[{"mask-radial":[Q,Z]}],"mask-image-radial-from-pos":[{"mask-radial-from":N()}],"mask-image-radial-to-pos":[{"mask-radial-to":N()}],"mask-image-radial-from-color":[{"mask-radial-from":k()}],"mask-image-radial-to-color":[{"mask-radial-to":k()}],"mask-image-radial-shape":[{"mask-radial":[`circle`,`ellipse`]}],"mask-image-radial-size":[{"mask-radial":[{closest:[`side`,`corner`],farthest:[`side`,`corner`]}]}],"mask-image-radial-pos":[{"mask-radial-at":b()}],"mask-image-conic-pos":[{"mask-conic":[X]}],"mask-image-conic-from-pos":[{"mask-conic-from":N()}],"mask-image-conic-to-pos":[{"mask-conic-to":N()}],"mask-image-conic-from-color":[{"mask-conic-from":k()}],"mask-image-conic-to-color":[{"mask-conic-to":k()}],"mask-mode":[{mask:[`alpha`,`luminance`,`match`]}],"mask-origin":[{"mask-origin":[`border`,`padding`,`content`,`fill`,`stroke`,`view`]}],"mask-position":[{mask:ae()}],"mask-repeat":[{mask:A()}],"mask-size":[{mask:j()}],"mask-type":[{"mask-type":[`alpha`,`luminance`]}],"mask-image":[{mask:[`none`,Q,Z]}],filter:[{filter:[``,`none`,Q,Z]}],blur:[{blur:ue()}],brightness:[{brightness:[X,Q,Z]}],contrast:[{contrast:[X,Q,Z]}],"drop-shadow":[{"drop-shadow":[``,`none`,p,wm,vm]}],"drop-shadow-color":[{"drop-shadow":k()}],grayscale:[{grayscale:[``,X,Q,Z]}],"hue-rotate":[{"hue-rotate":[X,Q,Z]}],invert:[{invert:[``,X,Q,Z]}],saturate:[{saturate:[X,Q,Z]}],sepia:[{sepia:[``,X,Q,Z]}],"backdrop-filter":[{"backdrop-filter":[``,`none`,Q,Z]}],"backdrop-blur":[{"backdrop-blur":ue()}],"backdrop-brightness":[{"backdrop-brightness":[X,Q,Z]}],"backdrop-contrast":[{"backdrop-contrast":[X,Q,Z]}],"backdrop-grayscale":[{"backdrop-grayscale":[``,X,Q,Z]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[X,Q,Z]}],"backdrop-invert":[{"backdrop-invert":[``,X,Q,Z]}],"backdrop-opacity":[{"backdrop-opacity":[X,Q,Z]}],"backdrop-saturate":[{"backdrop-saturate":[X,Q,Z]}],"backdrop-sepia":[{"backdrop-sepia":[``,X,Q,Z]}],"border-collapse":[{border:[`collapse`,`separate`]}],"border-spacing":[{"border-spacing":w()}],"border-spacing-x":[{"border-spacing-x":w()}],"border-spacing-y":[{"border-spacing-y":w()}],"table-layout":[{table:[`auto`,`fixed`]}],caption:[{caption:[`top`,`bottom`]}],transition:[{transition:[``,`all`,`colors`,`opacity`,`shadow`,`transform`,`none`,Q,Z]}],"transition-behavior":[{transition:[`normal`,`discrete`]}],duration:[{duration:[X,`initial`,Q,Z]}],ease:[{ease:[`linear`,`initial`,_,Q,Z]}],delay:[{delay:[X,Q,Z]}],animate:[{animate:[`none`,v,Q,Z]}],backface:[{backface:[`hidden`,`visible`]}],perspective:[{perspective:[h,Q,Z]}],"perspective-origin":[{"perspective-origin":x()}],rotate:[{rotate:de()}],"rotate-x":[{"rotate-x":de()}],"rotate-y":[{"rotate-y":de()}],"rotate-z":[{"rotate-z":de()}],scale:[{scale:fe()}],"scale-x":[{"scale-x":fe()}],"scale-y":[{"scale-y":fe()}],"scale-z":[{"scale-z":fe()}],"scale-3d":[`scale-3d`],skew:[{skew:pe()}],"skew-x":[{"skew-x":pe()}],"skew-y":[{"skew-y":pe()}],transform:[{transform:[Q,Z,``,`none`,`gpu`,`cpu`]}],"transform-origin":[{origin:x()}],"transform-style":[{transform:[`3d`,`flat`]}],translate:[{translate:me()}],"translate-x":[{"translate-x":me()}],"translate-y":[{"translate-y":me()}],"translate-z":[{"translate-z":me()}],"translate-none":[`translate-none`],accent:[{accent:k()}],appearance:[{appearance:[`none`,`auto`]}],"caret-color":[{caret:k()}],"color-scheme":[{scheme:[`normal`,`dark`,`light`,`light-dark`,`only-dark`,`only-light`]}],cursor:[{cursor:[`auto`,`default`,`pointer`,`wait`,`text`,`move`,`help`,`not-allowed`,`none`,`context-menu`,`progress`,`cell`,`crosshair`,`vertical-text`,`alias`,`copy`,`no-drop`,`grab`,`grabbing`,`all-scroll`,`col-resize`,`row-resize`,`n-resize`,`e-resize`,`s-resize`,`w-resize`,`ne-resize`,`nw-resize`,`se-resize`,`sw-resize`,`ew-resize`,`ns-resize`,`nesw-resize`,`nwse-resize`,`zoom-in`,`zoom-out`,Q,Z]}],"field-sizing":[{"field-sizing":[`fixed`,`content`]}],"pointer-events":[{"pointer-events":[`auto`,`none`]}],resize:[{resize:[`none`,``,`y`,`x`]}],"scroll-behavior":[{scroll:[`auto`,`smooth`]}],"scroll-m":[{"scroll-m":w()}],"scroll-mx":[{"scroll-mx":w()}],"scroll-my":[{"scroll-my":w()}],"scroll-ms":[{"scroll-ms":w()}],"scroll-me":[{"scroll-me":w()}],"scroll-mt":[{"scroll-mt":w()}],"scroll-mr":[{"scroll-mr":w()}],"scroll-mb":[{"scroll-mb":w()}],"scroll-ml":[{"scroll-ml":w()}],"scroll-p":[{"scroll-p":w()}],"scroll-px":[{"scroll-px":w()}],"scroll-py":[{"scroll-py":w()}],"scroll-ps":[{"scroll-ps":w()}],"scroll-pe":[{"scroll-pe":w()}],"scroll-pt":[{"scroll-pt":w()}],"scroll-pr":[{"scroll-pr":w()}],"scroll-pb":[{"scroll-pb":w()}],"scroll-pl":[{"scroll-pl":w()}],"snap-align":[{snap:[`start`,`end`,`center`,`align-none`]}],"snap-stop":[{snap:[`normal`,`always`]}],"snap-type":[{snap:[`none`,`x`,`y`,`both`]}],"snap-strictness":[{snap:[`mandatory`,`proximity`]}],touch:[{touch:[`auto`,`none`,`manipulation`]}],"touch-x":[{"touch-pan":[`x`,`left`,`right`]}],"touch-y":[{"touch-pan":[`y`,`up`,`down`]}],"touch-pz":[`touch-pinch-zoom`],select:[{select:[`none`,`text`,`all`,`auto`]}],"will-change":[{"will-change":[`auto`,`scroll`,`contents`,`transform`,Q,Z]}],fill:[{fill:[`none`,...k()]}],"stroke-w":[{stroke:[X,ym,mm,hm]}],stroke:[{stroke:[`none`,...k()]}],"forced-color-adjust":[{"forced-color-adjust":[`auto`,`none`]}]},conflictingClassGroups:{overflow:[`overflow-x`,`overflow-y`],overscroll:[`overscroll-x`,`overscroll-y`],inset:[`inset-x`,`inset-y`,`start`,`end`,`top`,`right`,`bottom`,`left`],"inset-x":[`right`,`left`],"inset-y":[`top`,`bottom`],flex:[`basis`,`grow`,`shrink`],gap:[`gap-x`,`gap-y`],p:[`px`,`py`,`ps`,`pe`,`pt`,`pr`,`pb`,`pl`],px:[`pr`,`pl`],py:[`pt`,`pb`],m:[`mx`,`my`,`ms`,`me`,`mt`,`mr`,`mb`,`ml`],mx:[`mr`,`ml`],my:[`mt`,`mb`],size:[`w`,`h`],"font-size":[`leading`],"fvn-normal":[`fvn-ordinal`,`fvn-slashed-zero`,`fvn-figure`,`fvn-spacing`,`fvn-fraction`],"fvn-ordinal":[`fvn-normal`],"fvn-slashed-zero":[`fvn-normal`],"fvn-figure":[`fvn-normal`],"fvn-spacing":[`fvn-normal`],"fvn-fraction":[`fvn-normal`],"line-clamp":[`display`,`overflow`],rounded:[`rounded-s`,`rounded-e`,`rounded-t`,`rounded-r`,`rounded-b`,`rounded-l`,`rounded-ss`,`rounded-se`,`rounded-ee`,`rounded-es`,`rounded-tl`,`rounded-tr`,`rounded-br`,`rounded-bl`],"rounded-s":[`rounded-ss`,`rounded-es`],"rounded-e":[`rounded-se`,`rounded-ee`],"rounded-t":[`rounded-tl`,`rounded-tr`],"rounded-r":[`rounded-tr`,`rounded-br`],"rounded-b":[`rounded-br`,`rounded-bl`],"rounded-l":[`rounded-tl`,`rounded-bl`],"border-spacing":[`border-spacing-x`,`border-spacing-y`],"border-w":[`border-w-x`,`border-w-y`,`border-w-s`,`border-w-e`,`border-w-t`,`border-w-r`,`border-w-b`,`border-w-l`],"border-w-x":[`border-w-r`,`border-w-l`],"border-w-y":[`border-w-t`,`border-w-b`],"border-color":[`border-color-x`,`border-color-y`,`border-color-s`,`border-color-e`,`border-color-t`,`border-color-r`,`border-color-b`,`border-color-l`],"border-color-x":[`border-color-r`,`border-color-l`],"border-color-y":[`border-color-t`,`border-color-b`],translate:[`translate-x`,`translate-y`,`translate-none`],"translate-none":[`translate`,`translate-x`,`translate-y`,`translate-z`],"scroll-m":[`scroll-mx`,`scroll-my`,`scroll-ms`,`scroll-me`,`scroll-mt`,`scroll-mr`,`scroll-mb`,`scroll-ml`],"scroll-mx":[`scroll-mr`,`scroll-ml`],"scroll-my":[`scroll-mt`,`scroll-mb`],"scroll-p":[`scroll-px`,`scroll-py`,`scroll-ps`,`scroll-pe`,`scroll-pt`,`scroll-pr`,`scroll-pb`,`scroll-pl`],"scroll-px":[`scroll-pr`,`scroll-pl`],"scroll-py":[`scroll-pt`,`scroll-pb`],touch:[`touch-x`,`touch-y`,`touch-pz`],"touch-x":[`touch`],"touch-y":[`touch`],"touch-pz":[`touch`]},conflictingClassGroupModifiers:{"font-size":[`leading`]},orderSensitiveModifiers:[`*`,`**`,`after`,`backdrop`,`before`,`details-content`,`file`,`first-letter`,`first-line`,`marker`,`placeholder`,`selection`]}},Fm=(e,{cacheSize:t,prefix:n,experimentalParseClassName:r,extend:i={},override:a={}})=>(Im(e,`cacheSize`,t),Im(e,`prefix`,n),Im(e,`experimentalParseClassName`,r),Lm(e.theme,a.theme),Lm(e.classGroups,a.classGroups),Lm(e.conflictingClassGroups,a.conflictingClassGroups),Lm(e.conflictingClassGroupModifiers,a.conflictingClassGroupModifiers),Im(e,`orderSensitiveModifiers`,a.orderSensitiveModifiers),Rm(e.theme,i.theme),Rm(e.classGroups,i.classGroups),Rm(e.conflictingClassGroups,i.conflictingClassGroups),Rm(e.conflictingClassGroupModifiers,i.conflictingClassGroupModifiers),zm(e,i,`orderSensitiveModifiers`),e),Im=(e,t,n)=>{n!==void 0&&(e[t]=n)},Lm=(e,t)=>{if(t)for(let n in t)Im(e,n,t[n])},Rm=(e,t)=>{if(t)for(let n in t)zm(e,t,n)},zm=(e,t,n)=>{let r=t[n];r!==void 0&&(e[n]=e[n]?e[n].concat(r):r)},Bm=(e,...t)=>typeof e==`function`?Kp(Pm,e,...t):Kp(()=>Fm(Pm(),e),...t),Vm=Kp(Pm),Hm=e=>op(e)?Vm:Bm({...e,extend:{theme:e.theme,classGroups:e.classGroups,conflictingClassGroupModifiers:e.conflictingClassGroupModifiers,conflictingClassGroups:e.conflictingClassGroups,...e.extend}}),Um=(e,t)=>{let n=ip(e);return!n||!(t?.twMerge??!0)?n:((!mp.cachedTwMerge||mp.didTwMergeConfigChange)&&(mp.didTwMergeConfigChange=!1,mp.cachedTwMerge=Hm(mp.cachedTwMergeConfig)),mp.cachedTwMerge(n)||void 0)},{createTV:Wm,tv:Gm}=hp((...e)=>t=>Um(e,t)),Km=Gm({base:`button`,defaultVariants:{fullWidth:!1,isIconOnly:!1,size:`md`,variant:`primary`},variants:{fullWidth:{false:``,true:`button--full-width`},isIconOnly:{true:`button--icon-only`},size:{lg:`button--lg`,md:`button--md`,sm:`button--sm`},variant:{danger:`button--danger`,"danger-soft":`button--danger-soft`,ghost:`button--ghost`,outline:`button--outline`,primary:`button--primary`,secondary:`button--secondary`,tertiary:`button--tertiary`}}}),qm=Symbol(`default`);function Jm(e){let{className:t,style:n,children:r,defaultClassName:i,defaultChildren:a,defaultStyle:o,values:s,render:c}=e;return(0,g.useMemo)(()=>{let e,l,u;return e=typeof t==`function`?t({...s,defaultClassName:i}):t,l=typeof n==`function`?n({...s,defaultStyle:o||{}}):n,u=typeof r==`function`?r({...s,defaultChildren:a}):r??a,{className:e??i,style:l||o?{...o,...l}:void 0,children:u??a,"data-rac":``,render:c?e=>c(e,s):void 0}},[t,n,r,i,a,o,s,c])}function Ym(e,t){return n=>t(typeof e==`function`?e(n):e,n)}function Xm(e,t){let n=(0,g.useContext)(e);if(t===null)return null;if(n&&typeof n==`object`&&`slots`in n&&n.slots){let e=t||qm;if(!n.slots[e]){let e=new Intl.ListFormat().format(Object.keys(n.slots).map(e=>`"${e}"`)),r=t?`Invalid slot "${t}".`:`A slot prop is required.`;throw Error(`${r} Valid slot names are ${e}.`)}return n.slots[e]}return n}function Zm(e,t,n){let{ref:r,...i}=Xm(n,e.slot)||{},a=zf((0,g.useMemo)(()=>xf(t,r),[t,r])),o=Tf(i,e);return`style`in i&&i.style&&`style`in e&&e.style&&(typeof i.style==`function`||typeof e.style==`function`?o.style=t=>{let n=typeof i.style==`function`?i.style(t):i.style,r={...t.defaultStyle,...n},a=typeof e.style==`function`?e.style({...t,defaultStyle:r}):e.style;return{...r,...a}}:o.style={...i.style,...e.style}),[o,a]}function Qm(e,t,n){let{render:r,...i}=t,a=(0,g.useRef)(null),o=(0,g.useMemo)(()=>xf(n,a),[n,a]);Jd(()=>{},[e,r]);let s={...i,ref:o};return r?r(s,void 0):g.createElement(e,s)}var $m={},eh=new Proxy({},{get(e,t){if(typeof t!=`string`)return;let n=$m[t];return n||(n=(0,g.forwardRef)(Qm.bind(null,t)),$m[t]=n),n}});typeof HTMLTemplateElement<`u`&&(Object.defineProperty(HTMLTemplateElement.prototype,`firstChild`,{configurable:!0,enumerable:!0,get:function(){return this.content.firstChild}}),Object.defineProperty(HTMLTemplateElement.prototype,`appendChild`,{configurable:!0,enumerable:!0,value:function(e){return this.content.appendChild(e)}}),Object.defineProperty(HTMLTemplateElement.prototype,`removeChild`,{configurable:!0,enumerable:!0,value:function(e){return this.content.removeChild(e)}}),Object.defineProperty(HTMLTemplateElement.prototype,`insertBefore`,{configurable:!0,enumerable:!0,value:function(e,t){return this.content.insertBefore(e,t)}}));var th=(0,g.createContext)(!1);function nh(e){let t=(t,n)=>(0,g.useContext)(th)?null:e(t,n);return t.displayName=e.displayName||e.name,(0,g.forwardRef)(t)}var rh=(0,g.createContext)(null),ih=7e3,ah=null;function oh(e,t=`assertive`,n=ih){ah?ah.announce(e,t,n):(ah=new sh,(typeof IS_REACT_ACT_ENVIRONMENT==`boolean`?IS_REACT_ACT_ENVIRONMENT:typeof jest<`u`)?ah.announce(e,t,n):setTimeout(()=>{ah?.isAttached()&&ah?.announce(e,t,n)},100))}var sh=class{constructor(){this.node=null,this.assertiveLog=null,this.politeLog=null,typeof document<`u`&&(this.node=document.createElement(`div`),this.node.dataset.liveAnnouncer=`true`,Object.assign(this.node.style,{border:0,clip:`rect(0 0 0 0)`,clipPath:`inset(50%)`,height:`1px`,margin:`-1px`,overflow:`hidden`,padding:0,position:`absolute`,width:`1px`,whiteSpace:`nowrap`}),this.assertiveLog=this.createLog(`assertive`),this.node.appendChild(this.assertiveLog),this.politeLog=this.createLog(`polite`),this.node.appendChild(this.politeLog),document.body.prepend(this.node))}isAttached(){return this.node?.isConnected}createLog(e){let t=document.createElement(`div`);return t.setAttribute(`role`,`log`),t.setAttribute(`aria-live`,e),t.setAttribute(`aria-relevant`,`additions`),t}destroy(){this.node&&=(document.body.removeChild(this.node),null)}announce(e,t=`assertive`,n=ih){if(!this.node)return;let r=document.createElement(`div`);typeof e==`object`?(r.setAttribute(`role`,`img`),r.setAttribute(`aria-labelledby`,e[`aria-labelledby`])):r.textContent=e,t===`assertive`?this.assertiveLog?.appendChild(r):this.politeLog?.appendChild(r),e!==``&&setTimeout(()=>{r.remove()},n)}clear(e){this.node&&((!e||e===`assertive`)&&this.assertiveLog&&(this.assertiveLog.innerHTML=``),(!e||e===`polite`)&&this.politeLog&&(this.politeLog.innerHTML=``))}};function ch(e){let t=e;return t.nativeEvent=e,t.isDefaultPrevented=()=>t.defaultPrevented,t.isPropagationStopped=()=>t.cancelBubble,t.persist=()=>{},t}function lh(e,t){Object.defineProperty(e,`target`,{value:t}),Object.defineProperty(e,`currentTarget`,{value:t})}function uh(e){let t=(0,g.useRef)({isFocused:!1,observer:null});return Jd(()=>{let e=t.current;return()=>{e.observer&&=(e.observer.disconnect(),null)}},[]),(0,g.useCallback)(n=>{let r=Y(n);if(r instanceof HTMLButtonElement||r instanceof HTMLInputElement||r instanceof HTMLTextAreaElement||r instanceof HTMLSelectElement){t.current.isFocused=!0;let n=r;n.addEventListener(`focusout`,r=>{if(t.current.isFocused=!1,n.disabled){let t=ch(r);e?.(t)}t.current.observer&&(t.current.observer.disconnect(),t.current.observer=null)},{once:!0}),t.current.observer=new MutationObserver(()=>{if(t.current.isFocused&&n.disabled){t.current.observer?.disconnect();let e=n===bf()?null:bf();n.dispatchEvent(new FocusEvent(`blur`,{relatedTarget:e})),n.dispatchEvent(new FocusEvent(`focusout`,{bubbles:!0,relatedTarget:e}))}}),t.current.observer.observe(n,{attributes:!0,attributeFilter:[`disabled`]})}},[e])}var dh=!1;function fh(e){for(;e&&!Zf(e,{skipVisibilityCheck:!0});)e=e.parentElement;let t=mf(e),n=t.document.activeElement;if(!n||n===e)return;dh=!0;let r=!1,i=e=>{(Y(e)===n||r)&&e.stopImmediatePropagation()},a=t=>{(Y(t)===n||r)&&(t.stopImmediatePropagation(),!e&&!r&&(r=!0,Hd(n),c()))},o=t=>{(Y(t)===e||r)&&t.stopImmediatePropagation()},s=t=>{(Y(t)===e||r)&&(t.stopImmediatePropagation(),r||(r=!0,Hd(n),c()))};t.addEventListener(`blur`,i,!0),t.addEventListener(`focusout`,a,!0),t.addEventListener(`focusin`,s,!0),t.addEventListener(`focus`,o,!0);let c=()=>{cancelAnimationFrame(l),t.removeEventListener(`blur`,i,!0),t.removeEventListener(`focusout`,a,!0),t.removeEventListener(`focusin`,s,!0),t.removeEventListener(`focus`,o,!0),dh=!1,r=!1},l=requestAnimationFrame(c);return c}var ph=null,mh=new Set,hh=new Map,gh=!1,_h=!1,vh={Tab:!0,Escape:!0};function yh(e,t){for(let n of mh)n(e,t)}function bh(e){return!(e.metaKey||!Pd()&&e.altKey||e.ctrlKey||e.key===`Control`||e.key===`Shift`||e.key===`Meta`)}function xh(e){gh=!0,!qd.isOpening&&bh(e)&&(ph=`keyboard`,yh(`keyboard`,e))}function Sh(e){ph=`pointer`,`pointerType`in e&&e.pointerType,(e.type===`mousedown`||e.type===`pointerdown`)&&(gh=!0,yh(`pointer`,e))}function Ch(e){!qd.isOpening&&Uf(e)&&(gh=!0,ph=`virtual`)}function wh(e){let t=mf(Y(e)),n=J(Y(e));Y(e)===t||Y(e)===n||dh||!e.isTrusted||(!gh&&!_h&&(ph=`virtual`,yh(`virtual`,e)),gh=!1,_h=!1)}function Th(){dh||(gh=!1,_h=!0)}function Eh(e){if(typeof window>`u`||typeof document>`u`)return;let t=mf(e),n=J(e);if(hh.get(t))return;let r=t.HTMLElement.prototype.focus;t.HTMLElement.prototype.focus=function(){gh=!0,r.apply(this,arguments)},n.addEventListener(`keydown`,xh,!0),n.addEventListener(`keyup`,xh,!0),n.addEventListener(`click`,Ch,!0),t.addEventListener(`focus`,wh,!0),t.addEventListener(`blur`,Th,!1),typeof PointerEvent<`u`&&(n.addEventListener(`pointerdown`,Sh,!0),n.addEventListener(`pointermove`,Sh,!0),n.addEventListener(`pointerup`,Sh,!0)),t.addEventListener(`beforeunload`,()=>{Dh(e)},{once:!0}),hh.set(t,{focus:r})}var Dh=(e,t)=>{let n=mf(e),r=J(e);t&&r.removeEventListener(`DOMContentLoaded`,t),hh.has(n)&&(n.HTMLElement.prototype.focus=hh.get(n).focus,r.removeEventListener(`keydown`,xh,!0),r.removeEventListener(`keyup`,xh,!0),r.removeEventListener(`click`,Ch,!0),n.removeEventListener(`focus`,wh,!0),n.removeEventListener(`blur`,Th,!1),typeof PointerEvent<`u`&&(r.removeEventListener(`pointerdown`,Sh,!0),r.removeEventListener(`pointermove`,Sh,!0),r.removeEventListener(`pointerup`,Sh,!0)),hh.delete(n))};function Oh(e){let t=J(e),n;return t.readyState===`loading`?(n=()=>{Eh(e)},t.addEventListener(`DOMContentLoaded`,n)):Eh(e),()=>Dh(e,n)}typeof document<`u`&&Oh();function kh(){return ph!==`pointer`}function Ah(){return ph}var jh=new Set([`checkbox`,`radio`,`range`,`color`,`file`,`image`,`button`,`submit`,`reset`]);function Mh(e,t,n){let r=n?Y(n):void 0,i=J(r),a=mf(r),o=a===void 0?HTMLInputElement:a.HTMLInputElement,s=a===void 0?HTMLTextAreaElement:a.HTMLTextAreaElement,c=a===void 0?HTMLElement:a.HTMLElement,l=a===void 0?KeyboardEvent:a.KeyboardEvent,u=bf(i);return e=e||u instanceof o&&!jh.has(u.type)||u instanceof s||u instanceof c&&u.isContentEditable,!(e&&t===`keyboard`&&n instanceof l&&!vh[n.key])}function Nh(e,t,n){Eh(),(0,g.useEffect)(()=>{if(n?.enabled===!1)return;let t=(t,r)=>{Mh(!!n?.isTextInput,t,r)&&e(kh())};return mh.add(t),()=>{mh.delete(t)}},t)}function Ph(e){if(!e.isConnected)return;let t=J(e);if(Ah()===`virtual`){let n=bf(t);Lf(()=>{let r=bf(t);(r===n||r===t.body)&&e.isConnected&&Hd(e)})}else Hd(e)}function Fh(e){let{isDisabled:t,onFocus:n,onBlur:r,onFocusChange:i}=e,a=(0,g.useCallback)(e=>{if(Y(e)===e.currentTarget)return r&&r(e),i&&i(!1),!0},[r,i]),o=uh(a),s=(0,g.useCallback)(e=>{let t=Y(e),r=J(t),a=r?bf(r):bf();t===e.currentTarget&&t===a&&(n&&n(e),i&&i(!0),o(e))},[i,n,o]);return{focusProps:{onFocus:!t&&(n||i||r)?s:void 0,onBlur:!t&&(r||i)?a:void 0}}}function Ih(e){if(!e)return;let t=!0;return n=>{e({...n,preventDefault(){n.preventDefault()},isDefaultPrevented(){return n.isDefaultPrevented()},stopPropagation(){t=!0},continuePropagation(){t=!1},isPropagationStopped(){return t}}),t&&n.stopPropagation()}}function Lh(e){return{keyboardProps:e.isDisabled?{}:{onKeyDown:Ih(e.onKeyDown),onKeyUp:Ih(e.onKeyUp)}}}var Rh=g.createContext(null);function zh(e){let t=(0,g.useContext)(Rh)||{};Hf(t,e);let{ref:n,...r}=t;return r}function Bh(e,t){let{focusProps:n}=Fh(e),{keyboardProps:r}=Lh(e),i=Tf(n,r),a=zh(t),o=e.isDisabled?{}:a,s=(0,g.useRef)(e.autoFocus);(0,g.useEffect)(()=>{s.current&&t.current&&Ph(t.current),s.current=!1},[t]);let c=e.excludeFromTabOrder?-1:0;return e.isDisabled&&(c=void 0),{focusableProps:Tf({...i,tabIndex:c},o)}}var Vh=`default`,Hh=``,Uh=new WeakMap;function Wh(e){if(Ld()){if(Vh===`default`){let t=J(e);Hh=t.documentElement.style.webkitUserSelect,t.documentElement.style.webkitUserSelect=`none`}Vh=`disabled`}else if(e instanceof HTMLElement||e instanceof SVGElement){let t=`userSelect`in e.style?`userSelect`:`webkitUserSelect`;Uh.set(e,e.style[t]),e.style[t]=`none`}}function Gh(e){if(Ld()){if(Vh!==`disabled`)return;Vh=`restoring`,setTimeout(()=>{Lf(()=>{if(Vh===`restoring`){let t=J(e);t.documentElement.style.webkitUserSelect===`none`&&(t.documentElement.style.webkitUserSelect=Hh||``),Hh=``,Vh=`default`}})},300)}else if((e instanceof HTMLElement||e instanceof SVGElement)&&e&&Uh.has(e)){let t=Uh.get(e),n=`userSelect`in e.style?`userSelect`:`webkitUserSelect`;e.style[n]===`none`&&(e.style[n]=t),e.getAttribute(`style`)===``&&e.removeAttribute(`style`),Uh.delete(e)}}var Kh=g.createContext({register:()=>{}});Kh.displayName=`PressResponderContext`;function qh(e){let t=(0,g.useContext)(Kh);if(t){let{register:n,ref:r,...i}=t;e=Tf(i,e),n()}return Hf(t,e.ref),e}var Jh=class{#e;constructor(e,t,n,r){this.#e=!0;let i=(r?.target??n.currentTarget)?.getBoundingClientRect(),a,o=0,s,c=null;n.clientX!=null&&n.clientY!=null&&(s=n.clientX,c=n.clientY),i&&(s!=null&&c!=null?(a=s-i.left,o=c-i.top):(a=i.width/2,o=i.height/2)),this.type=e,this.pointerType=t,this.target=n.currentTarget,this.shiftKey=n.shiftKey,this.metaKey=n.metaKey,this.ctrlKey=n.ctrlKey,this.altKey=n.altKey,this.x=a,this.y=o,this.key=n.key}continuePropagation(){this.#e=!1}get shouldStopPropagation(){return this.#e}},Yh=Symbol(`linkClicked`),Xh=`react-aria-pressable-style`,Zh=`data-react-aria-pressable`;function Qh(e){let{onPress:t,onPressChange:n,onPressStart:r,onPressEnd:i,onPressUp:a,onClick:o,isDisabled:s,isPressed:c,preventFocusOnPress:l,shouldCancelOnPointerExit:u,allowTextSelectionOnPress:d,ref:f,...p}=qh(e),[m,h]=(0,g.useState)(!1),_=(0,g.useRef)({isPressed:!1,ignoreEmulatedMouseEvents:!1,didFirePressStart:!1,isTriggeringEvent:!1,activePointerId:null,target:null,isOverTarget:!1,pointerType:null,disposables:[]}),{addGlobalListener:v,removeAllGlobalListeners:y}=Rf(),b=(0,g.useCallback)((e,t)=>{let i=_.current;if(s||i.didFirePressStart)return!1;let a=!0;if(i.isTriggeringEvent=!0,r){let n=new Jh(`pressstart`,t,e);r(n),a=n.shouldStopPropagation}return n&&n(!0),i.isTriggeringEvent=!1,i.didFirePressStart=!0,h(!0),a},[s,r,n]),x=(0,g.useCallback)((e,r,a=!0)=>{let o=_.current;if(!o.didFirePressStart)return!1;o.didFirePressStart=!1,o.isTriggeringEvent=!0;let c=!0;if(i){let t=new Jh(`pressend`,r,e);i(t),c=t.shouldStopPropagation}if(n&&n(!1),h(!1),t&&a&&!s){let n=new Jh(`press`,r,e);t(n),c&&=n.shouldStopPropagation}return o.isTriggeringEvent=!1,c},[s,i,n,t]),S=Vf(x),C=Vf((0,g.useCallback)((e,t)=>{let n=_.current;if(s)return!1;if(a){n.isTriggeringEvent=!0;let r=new Jh(`pressup`,t,e);return a(r),n.isTriggeringEvent=!1,r.shouldStopPropagation}return!0},[s,a])),w=(0,g.useCallback)(e=>{let t=_.current;if(t.isPressed&&t.target){t.didFirePressStart&&t.pointerType!=null&&x(tg(t.target,e),t.pointerType,!1),t.isPressed=!1,t.isOverTarget=!1,t.activePointerId=null,t.pointerType=null,y(),d||Gh(t.target);for(let e of t.disposables)e();t.disposables=[]}},[d,y,x]),T=Vf(w),E=(0,g.useCallback)(e=>{u&&w(e)},[u,w]),D=(0,g.useCallback)(e=>{s||o?.(e)},[s,o]),O=(0,g.useCallback)((e,t)=>{if(!s&&o){let n=new MouseEvent(`click`,e);lh(n,t),o(ch(n))}},[s,o]),ee=(0,g.useMemo)(()=>{let e=_.current,t={onKeyDown(t){if(eg(t.nativeEvent,t.currentTarget)&&yf(t.currentTarget,Y(t))){rg(Y(t),t.key)&&t.preventDefault();let r=!0;!e.isPressed&&!t.repeat&&(e.target=t.currentTarget,e.isPressed=!0,e.pointerType=`keyboard`,r=b(t,`keyboard`));let i=t.currentTarget;v(J(t.currentTarget),`keyup`,pf(t=>{eg(t,i)&&!t.repeat&&yf(i,Y(t))&&e.target&&C(tg(e.target,t),`keyboard`)},n),!0),r&&t.stopPropagation(),t.metaKey&&Pd()&&e.metaKeyEvents?.set(t.key,t.nativeEvent)}else t.key===`Meta`&&(e.metaKeyEvents=new Map)},onClick(t){if(!(t&&!yf(t.currentTarget,Y(t)))&&t&&t.button===0&&!e.isTriggeringEvent&&!qd.isOpening){let n=!0;if(s&&t.preventDefault(),!e.ignoreEmulatedMouseEvents&&!e.isPressed&&(e.pointerType===`virtual`||Uf(t.nativeEvent))){let e=b(t,`virtual`),r=C(t,`virtual`),i=S(t,`virtual`);D(t),n=e&&r&&i}else if(e.isPressed&&e.pointerType!==`keyboard`){let r=e.pointerType||t.nativeEvent.pointerType||`virtual`,i=C(tg(t.currentTarget,t),r),a=S(tg(t.currentTarget,t),r,!0);n=i&&a,e.isOverTarget=!1,D(t),T(t)}e.ignoreEmulatedMouseEvents=!1,n&&t.stopPropagation()}}},n=t=>{if(e.isPressed&&e.target&&eg(t,e.target)){rg(Y(t),t.key)&&t.preventDefault();let n=Y(t),r=yf(e.target,n);S(tg(e.target,t),`keyboard`,r),r&&O(t,e.target),y(),t.key!==`Enter`&&$h(e.target)&&yf(e.target,n)&&!t[Yh]&&(t[Yh]=!0,qd(e.target,t,!1)),e.isPressed=!1,e.metaKeyEvents?.delete(t.key)}else if(t.key===`Meta`&&e.metaKeyEvents?.size){let t=e.metaKeyEvents;e.metaKeyEvents=void 0;for(let n of t.values())e.target?.dispatchEvent(new KeyboardEvent(`keyup`,n))}};if(typeof PointerEvent<`u`){t.onPointerDown=t=>{if(t.button!==0||!yf(t.currentTarget,Y(t)))return;if(Wf(t.nativeEvent)){e.pointerType=`virtual`;return}e.pointerType=t.pointerType;let i=!0;if(!e.isPressed){e.isPressed=!0,e.isOverTarget=!0,e.activePointerId=t.pointerId,e.target=t.currentTarget,d||Wh(e.target),i=b(t,e.pointerType);let a=Y(t);`releasePointerCapture`in a&&(`hasPointerCapture`in a?a.hasPointerCapture(t.pointerId)&&a.releasePointerCapture(t.pointerId):a.releasePointerCapture(t.pointerId)),v(J(t.currentTarget),`pointerup`,n,!1),v(J(t.currentTarget),`pointercancel`,r,!1)}i&&t.stopPropagation()},t.onMouseDown=t=>{if(yf(t.currentTarget,Y(t))&&t.button===0){if(l){let n=fh(t.target);n&&e.disposables.push(n)}t.stopPropagation()}},t.onPointerUp=t=>{!yf(t.currentTarget,Y(t))||e.pointerType===`virtual`||t.button===0&&!e.isPressed&&C(t,e.pointerType||t.pointerType)},t.onPointerEnter=t=>{t.pointerId===e.activePointerId&&e.target&&!e.isOverTarget&&e.pointerType!=null&&(e.isOverTarget=!0,b(tg(e.target,t),e.pointerType))},t.onPointerLeave=t=>{t.pointerId===e.activePointerId&&e.target&&e.isOverTarget&&e.pointerType!=null&&(e.isOverTarget=!1,S(tg(e.target,t),e.pointerType,!1),E(t))};let n=t=>{if(t.pointerId===e.activePointerId&&e.isPressed&&t.button===0&&e.target){if(yf(e.target,Y(t))&&e.pointerType!=null){let n=!1,r=setTimeout(()=>{e.isPressed&&e.target instanceof HTMLElement&&(n?T(t):(Hd(e.target),e.target.click()))},80);v(t.currentTarget,`click`,()=>n=!0,!0),e.disposables.push(()=>clearTimeout(r))}else T(t);e.isOverTarget=!1}},r=e=>{T(e)};t.onDragStart=e=>{yf(e.currentTarget,Y(e))&&T(e)}}return t},[v,s,l,y,d,E,b,D,O]);return(0,g.useEffect)(()=>{if(!f)return;let e=J(f.current);if(!e||!e.head||e.getElementById(Xh))return;let t=e.createElement(`style`);t.id=Xh;let n=tp(e);n&&(t.nonce=n),t.textContent=`
@layer {
  [${Zh}] {
    touch-action: pan-x pan-y pinch-zoom;
  }
}
    `.trim(),e.head.prepend(t)},[f]),(0,g.useEffect)(()=>{let e=_.current;return()=>{d||Gh(e.target??void 0);for(let t of e.disposables)t();e.disposables=[]}},[d]),{isPressed:c||m,pressProps:Tf(p,ee,{[Zh]:!0})}}function $h(e){return e.tagName===`A`&&e.hasAttribute(`href`)}function eg(e,t){let{key:n,code:r}=e,i=t,a=i.getAttribute(`role`);return(n===`Enter`||n===` `||n===`Spacebar`||r===`Space`)&&!(i instanceof mf(i).HTMLInputElement&&!ag(i,n)||i instanceof mf(i).HTMLTextAreaElement||i.isContentEditable)&&!((a===`link`||!a&&$h(i))&&n!==`Enter`)}function tg(e,t){let n=t.clientX,r=t.clientY;return{currentTarget:e,shiftKey:t.shiftKey,ctrlKey:t.ctrlKey,metaKey:t.metaKey,altKey:t.altKey,clientX:n,clientY:r,key:t.key}}function ng(e){return e instanceof HTMLInputElement?!1:e instanceof HTMLButtonElement?e.type!==`submit`&&e.type!==`reset`:!$h(e)}function rg(e,t){return e instanceof HTMLInputElement?!ag(e,t):ng(e)}var ig=new Set([`checkbox`,`radio`,`range`,`color`,`file`,`image`,`button`,`submit`,`reset`]);function ag(e,t){return e.type===`checkbox`||e.type===`radio`?t===` `:ig.has(e.type)}function og(e,t){let{elementType:n=`button`,isDisabled:r,onPress:i,onPressStart:a,onPressEnd:o,onPressUp:s,onPressChange:c,preventFocusOnPress:l,allowFocusWhenDisabled:u,onClick:d,href:f,target:p,rel:m,type:h=`button`}=e,g;g=n===`button`?{type:h,disabled:r,form:e.form,formAction:e.formAction,formEncType:e.formEncType,formMethod:e.formMethod,formNoValidate:e.formNoValidate,formTarget:e.formTarget,name:e.name,value:e.value}:{role:`button`,href:n===`a`&&!r?f:void 0,target:n===`a`?p:void 0,type:n===`input`?h:void 0,disabled:n===`input`?r:void 0,"aria-disabled":!r||n===`input`?void 0:r,rel:n===`a`?m:void 0};let{pressProps:_,isPressed:v}=Qh({onPressStart:a,onPressEnd:o,onPressChange:c,onPress:i,onPressUp:s,onClick:d,isDisabled:r,preventFocusOnPress:l,ref:t}),{focusableProps:y}=Bh(e,t);u&&(y.tabIndex=r?-1:y.tabIndex);let b=Tf(y,_,Mf(e,{labelable:!0}));return{isPressed:v,buttonProps:Tf(g,b,{"aria-haspopup":e[`aria-haspopup`],"aria-expanded":e[`aria-expanded`],"aria-controls":e[`aria-controls`],"aria-pressed":e[`aria-pressed`],"aria-current":e[`aria-current`],"aria-disabled":e[`aria-disabled`]})}}function sg(e){let{isDisabled:t,onBlurWithin:n,onFocusWithin:r,onFocusWithinChange:i}=e,a=(0,g.useRef)({isFocusWithin:!1}),{addGlobalListener:o,removeAllGlobalListeners:s}=Rf(),c=(0,g.useCallback)(e=>{yf(e.currentTarget,Y(e))&&a.current.isFocusWithin&&!yf(e.currentTarget,e.relatedTarget)&&(a.current.isFocusWithin=!1,s(),n&&n(e),i&&i(!1))},[n,i,a,s]),l=uh(c),u=(0,g.useCallback)(e=>{if(!yf(e.currentTarget,Y(e)))return;let t=Y(e),n=J(t),s=bf(n);if(!a.current.isFocusWithin&&s===t){r&&r(e),i&&i(!0),a.current.isFocusWithin=!0,l(e);let t=e.currentTarget;o(n,`focus`,e=>{let r=Y(e);if(a.current.isFocusWithin&&!yf(t,r)){let e=new n.defaultView.FocusEvent(`blur`,{relatedTarget:r});lh(e,t),c(ch(e))}},{capture:!0})}},[r,i,l,o,c]);return t?{focusWithinProps:{onFocus:void 0,onBlur:void 0}}:{focusWithinProps:{onFocus:u,onBlur:c}}}function cg(e={}){let{autoFocus:t=!1,isTextInput:n,within:r}=e,i=(0,g.useRef)({isFocused:!1,isFocusVisible:t||kh()}),[a,o]=(0,g.useState)(!1),[s,c]=(0,g.useState)(()=>i.current.isFocused&&i.current.isFocusVisible),l=(0,g.useCallback)(()=>c(i.current.isFocused&&i.current.isFocusVisible),[]),u=(0,g.useCallback)(e=>{i.current.isFocused=e,i.current.isFocusVisible=kh(),o(e),l()},[l]);Nh(e=>{i.current.isFocusVisible=e,l()},[n,a],{enabled:a,isTextInput:n});let{focusProps:d}=Fh({isDisabled:r,onFocusChange:u}),{focusWithinProps:f}=sg({isDisabled:!r,onFocusWithinChange:u});return{isFocused:a,isFocusVisible:s,focusProps:r?f:d}}var lg=!1,ug=0;function dg(){lg=!0,setTimeout(()=>{lg=!1},500)}function fg(e){e.pointerType===`touch`&&dg()}function pg(){let e=J(null);if(e!==void 0)return ug===0&&typeof PointerEvent<`u`&&e.addEventListener(`pointerup`,fg),ug++,()=>{ug--,!(ug>0)&&typeof PointerEvent<`u`&&e.removeEventListener(`pointerup`,fg)}}function mg(e){let{onHoverStart:t,onHoverChange:n,onHoverEnd:r,isDisabled:i}=e,[a,o]=(0,g.useState)(!1),s=(0,g.useRef)({isHovered:!1,ignoreEmulatedMouseEvents:!1,pointerType:``,target:null}).current;(0,g.useEffect)(pg,[]);let{addGlobalListener:c,removeAllGlobalListeners:l}=Rf(),{hoverProps:u,triggerHoverEnd:d}=(0,g.useMemo)(()=>{let e=(e,r)=>{if(s.pointerType=r,i||r===`touch`||s.isHovered||!yf(e.currentTarget,Y(e)))return;s.isHovered=!0;let l=e.currentTarget;s.target=l,c(J(Y(e)),`pointerover`,e=>{s.isHovered&&s.target&&!yf(s.target,Y(e))&&a(e,e.pointerType)},{capture:!0}),t&&t({type:`hoverstart`,target:l,pointerType:r}),n&&n(!0),o(!0)},a=(e,t)=>{let i=s.target;s.pointerType=``,s.target=null,!(t===`touch`||!s.isHovered||!i)&&(s.isHovered=!1,l(),r&&r({type:`hoverend`,target:i,pointerType:t}),n&&n(!1),o(!1))},u={};return typeof PointerEvent<`u`&&(u.onPointerEnter=t=>{lg&&t.pointerType===`mouse`||e(t,t.pointerType)},u.onPointerLeave=e=>{!i&&yf(e.currentTarget,Y(e))&&a(e,e.pointerType)}),{hoverProps:u,triggerHoverEnd:a}},[t,n,r,i,s,c,l]);return(0,g.useEffect)(()=>{i&&d({currentTarget:s.target},s.pointerType)},[i]),{hoverProps:u,isHovered:a}}var hg=(0,g.createContext)({}),gg=nh(function(e,t){[e,t]=Zm(e,t,hg);let n=e,{isPending:r}=n,{buttonProps:i,isPressed:a}=og(e,t);i=vg(i,r);let{focusProps:o,isFocused:s,isFocusVisible:c}=cg(e),{hoverProps:l,isHovered:u}=mg({...e,isDisabled:e.isDisabled||r}),d={isHovered:u,isPressed:(n.isPressed||a)&&!r,isFocused:s,isFocusVisible:c,isDisabled:e.isDisabled||!1,isPending:r??!1},f=Jm({...e,values:d,defaultClassName:`react-aria-Button`}),p=df(i.id),m=df(),h=i[`aria-labelledby`];r&&(h?h=`${h} ${m}`:i[`aria-label`]&&(h=`${p} ${m}`));let _=(0,g.useRef)(r);(0,g.useEffect)(()=>{let e={"aria-labelledby":h||p};(!_.current&&s&&r||_.current&&s&&!r)&&oh(e,`assertive`),_.current=r},[r,s,h,p]);let v=Mf(e,{global:!0});return delete v.onClick,g.createElement(eh.button,{...Tf(v,f,i,o,l),type:i.type===`submit`&&r?`button`:i.type,id:p,ref:t,"aria-labelledby":h,slot:e.slot||void 0,"aria-disabled":r?`true`:i[`aria-disabled`],"data-disabled":e.isDisabled||void 0,"data-pressed":d.isPressed||void 0,"data-hovered":u||void 0,"data-focused":s||void 0,"data-pending":r||void 0,"data-focus-visible":c||void 0},g.createElement(rh.Provider,{value:{id:m}},f.children))}),_g=/Focus|Blur|Hover|Pointer(Enter|Leave|Over|Out)|Mouse(Enter|Leave|Over|Out)/;function vg(e,t){if(t){for(let t in e)t.startsWith(`on`)&&!_g.test(t)&&(e[t]=void 0);e.href=void 0,e.target=void 0}return e}function yg(e,t){return Ym(e,(e,n)=>ip(typeof t==`function`?t(n)??``:t??``,e??``)??``)}var bg=(0,g.createContext)({}),xg=`__button_group_child`,Sg=({children:e,className:t,fullWidth:n,isDisabled:r,isIconOnly:i,size:a,slot:o,style:s,variant:c,[xg]:l,...u})=>{let d=(0,g.useContext)(bg),f=l===!0,p=a??(f?d?.size:void 0),m=c??(f?d?.variant:void 0),h=r??(f?d?.isDisabled:void 0);return(0,q.jsx)(gg,{className:yg(t,Km({fullWidth:n??(f?d?.fullWidth:void 0),isIconOnly:i,size:p,variant:m})),"data-slot":`button`,isDisabled:h,slot:o,style:s,...u,children:t=>typeof e==`function`?e(t):e})},Cg=Object.assign(Sg,{Root:Sg}),wg=function(e,t){return wg=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},wg(e,t)};function Tg(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Class extends value `+String(t)+` is not a constructor or null`);wg(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}function Eg(e,t,n,r){function i(e){return e instanceof n?e:new n(function(t){t(e)})}return new(n||=Promise)(function(n,a){function o(e){try{c(r.next(e))}catch(e){a(e)}}function s(e){try{c(r.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):i(e.value).then(o,s)}c((r=r.apply(e,t||[])).next())})}function Dg(e,t){var n={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},r,i,a,o=Object.create((typeof Iterator==`function`?Iterator:Object).prototype);return o.next=s(0),o.throw=s(1),o.return=s(2),typeof Symbol==`function`&&(o[Symbol.iterator]=function(){return this}),o;function s(e){return function(t){return c([e,t])}}function c(s){if(r)throw TypeError(`Generator is already executing.`);for(;o&&(o=0,s[0]&&(n=0)),n;)try{if(r=1,i&&(a=s[0]&2?i.return:s[0]?i.throw||((a=i.return)&&a.call(i),0):i.next)&&!(a=a.call(i,s[1])).done)return a;switch(i=0,a&&(s=[s[0]&2,a.value]),s[0]){case 0:case 1:a=s;break;case 4:return n.label++,{value:s[1],done:!1};case 5:n.label++,i=s[1],s=[0];continue;case 7:s=n.ops.pop(),n.trys.pop();continue;default:if((a=n.trys,!(a=a.length>0&&a[a.length-1]))&&(s[0]===6||s[0]===2)){n=0;continue}if(s[0]===3&&(!a||s[1]>a[0]&&s[1]<a[3])){n.label=s[1];break}if(s[0]===6&&n.label<a[1]){n.label=a[1],a=s;break}if(a&&n.label<a[2]){n.label=a[2],n.ops.push(s);break}a[2]&&n.ops.pop(),n.trys.pop();continue}s=t.call(e,n)}catch(e){s=[6,e],i=0}finally{r=a=0}if(s[0]&5)throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}}function Og(e){var t=typeof Symbol==`function`&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&typeof e.length==`number`)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw TypeError(t?`Object is not iterable.`:`Symbol.iterator is not defined.`)}function kg(e,t){var n=typeof Symbol==`function`&&e[Symbol.iterator];if(!n)return e;var r=n.call(e),i,a=[],o;try{for(;(t===void 0||t-- >0)&&!(i=r.next()).done;)a.push(i.value)}catch(e){o={error:e}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(o)throw o.error}}return a}function Ag(e,t,n){if(n||arguments.length===2)for(var r=0,i=t.length,a;r<i;r++)(a||!(r in t))&&(a||=Array.prototype.slice.call(t,0,r),a[r]=t[r]);return e.concat(a||Array.prototype.slice.call(t))}function jg(e){return this instanceof jg?(this.v=e,this):new jg(e)}function Mg(e,t,n){if(!Symbol.asyncIterator)throw TypeError(`Symbol.asyncIterator is not defined.`);var r=n.apply(e,t||[]),i,a=[];return i=Object.create((typeof AsyncIterator==`function`?AsyncIterator:Object).prototype),s(`next`),s(`throw`),s(`return`,o),i[Symbol.asyncIterator]=function(){return this},i;function o(e){return function(t){return Promise.resolve(t).then(e,d)}}function s(e,t){r[e]&&(i[e]=function(t){return new Promise(function(n,r){a.push([e,t,n,r])>1||c(e,t)})},t&&(i[e]=t(i[e])))}function c(e,t){try{l(r[e](t))}catch(e){f(a[0][3],e)}}function l(e){e.value instanceof jg?Promise.resolve(e.value.v).then(u,d):f(a[0][2],e)}function u(e){c(`next`,e)}function d(e){c(`throw`,e)}function f(e,t){e(t),a.shift(),a.length&&c(a[0][0],a[0][1])}}function Ng(e){if(!Symbol.asyncIterator)throw TypeError(`Symbol.asyncIterator is not defined.`);var t=e[Symbol.asyncIterator],n;return t?t.call(e):(e=typeof Og==`function`?Og(e):e[Symbol.iterator](),n={},r(`next`),r(`throw`),r(`return`),n[Symbol.asyncIterator]=function(){return this},n);function r(t){n[t]=e[t]&&function(n){return new Promise(function(r,a){n=e[t](n),i(r,a,n.done,n.value)})}}function i(e,t,n,r){Promise.resolve(r).then(function(t){e({value:t,done:n})},t)}}var Pg=function(e){return e.PRIMARY=`primary`,e.SECONDARY=`secondary`,e.FLAT=`flat`,e}({}),Fg=e=>{let t=(0,P.c)(16),{text:n,leftIcon:r,rightIcon:i,onPress:a,variant:o,className:s,size:c,onClick:l,ref:u}=e,d=o===void 0?Pg.PRIMARY:o,f=s===void 0?``:s,p;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(p={[Pg.PRIMARY]:`bg-black text-white hover:bg-zinc-800`,[Pg.SECONDARY]:`bg-transparent border-2 border-black text-black hover:bg-black hover:text-white`,[Pg.FLAT]:`bg-zinc-100 text-black hover:bg-zinc-200`},t[0]=p):p=t[0];let m=`font-medium transition-all duration-200 ${p[d]||``} ${f}`,h;t[1]===a?h=t[2]:(h=e=>{a?.(e)},t[1]=a,t[2]=h);let g;t[3]===r?g=t[4]:(g=r&&(0,q.jsx)(`span`,{className:`mr-2`,children:r}),t[3]=r,t[4]=g);let _;t[5]===i?_=t[6]:(_=i&&(0,q.jsx)(`span`,{className:`ml-2`,children:i}),t[5]=i,t[6]=_);let v;return t[7]!==l||t[8]!==u||t[9]!==c||t[10]!==m||t[11]!==h||t[12]!==g||t[13]!==_||t[14]!==n?(v=(0,q.jsxs)(Cg,{className:m,size:c,onPress:h,onClick:l,ref:u,children:[g,n,_]}),t[7]=l,t[8]=u,t[9]=c,t[10]=m,t[11]=h,t[12]=g,t[13]=_,t[14]=n,t[15]=v):v=t[15],v},Ig=()=>({logEvent:(e,t)=>{typeof window<`u`&&window.gtag&&window.gtag(`event`,e,t)}}),Lg=function(e){return e.REDIRECT_TO_DASHBOARD=`redirect_to_dashboard`,e.SIMPLE_LOGIN=`simple_login`,e.INDIRECT_LOGIN=`indirect_login`,e}({}),Rg=()=>{let e=(0,P.c)(31),{logEvent:t}=Ig(),n;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(n=(0,q.jsx)(Pa,{to:`/`,className:`flex items-center cursor-pointer`,children:(0,q.jsx)(`span`,{className:`text-xl font-black tracking-tighter uppercase text-black`,children:`CautionLabs`})}),e[0]=n):n=e[0];let r;e[1]===Symbol.for(`react.memo_cache_sentinel`)?(r=(0,q.jsxs)(Pa,{to:`/solutions`,className:`hidden md:inline-block relative py-1 text-[10px] font-bold uppercase tracking-[0.1em] text-zinc-600 hover:text-black transition-colors group`,children:[`Solutions`,(0,q.jsx)(`span`,{className:`absolute bottom-0 left-0 w-0 h-[1.5px] bg-black transition-all duration-300 group-hover:w-full`})]}),e[1]=r):r=e[1];let i;e[2]===Symbol.for(`react.memo_cache_sentinel`)?(i=(0,q.jsxs)(Pa,{to:`/blogs`,className:`hidden md:inline-block relative py-1 text-[10px] font-bold uppercase tracking-[0.1em] text-zinc-600 hover:text-black transition-colors group`,children:[`Blogs`,(0,q.jsx)(`span`,{className:`absolute bottom-0 left-0 w-0 h-[1.5px] bg-black transition-all duration-300 group-hover:w-full`})]}),e[2]=i):i=e[2];let a;e[3]===Symbol.for(`react.memo_cache_sentinel`)?(a=(0,q.jsx)(nd,{children:(0,q.jsx)(`div`,{className:`h-8 w-8 animate-pulse bg-zinc-100 rounded-full`})}),e[3]=a):a=e[3];let o;e[4]===t?o=e[5]:(o=()=>{t(Lg.SIMPLE_LOGIN)},e[4]=t,e[5]=o);let s;e[6]===Symbol.for(`react.memo_cache_sentinel`)?(s=(0,q.jsx)(kd,{mode:`modal`,children:(0,q.jsx)(Fg,{text:`Login`,variant:Pg.FLAT,size:`lg`})}),e[6]=s):s=e[6];let c;e[7]===o?c=e[8]:(c=(0,q.jsx)(`span`,{onClickCapture:o,children:s}),e[7]=o,e[8]=c);let l;e[9]===t?l=e[10]:(l=()=>{t(Lg.SIMPLE_LOGIN)},e[9]=t,e[10]=l);let u;e[11]===Symbol.for(`react.memo_cache_sentinel`)?(u=(0,q.jsx)(Ad,{mode:`modal`,children:(0,q.jsx)(Fg,{text:`Sign Up`,variant:Pg.PRIMARY,size:`lg`})}),e[11]=u):u=e[11];let d;e[12]===l?d=e[13]:(d=(0,q.jsx)(`span`,{onClickCapture:l,children:u}),e[12]=l,e[13]=d);let f;e[14]!==c||e[15]!==d?(f=(0,q.jsx)(rd,{when:`signed-out`,children:(0,q.jsxs)(`div`,{className:`flex items-center gap-3`,children:[c,d]})}),e[14]=c,e[15]=d,e[16]=f):f=e[16];let p;e[17]===t?p=e[18]:(p=()=>{t(Lg.REDIRECT_TO_DASHBOARD,{source:`navbar`})},e[17]=t,e[18]=p);let m;e[19]===Symbol.for(`react.memo_cache_sentinel`)?(m=(0,q.jsx)(`span`,{className:`absolute bottom-0 left-0 w-0 h-[1.5px] bg-black transition-all duration-300 group-hover:w-full`}),e[19]=m):m=e[19];let h;e[20]===p?h=e[21]:(h=(0,q.jsxs)(Pa,{to:`/api-keys`,onClick:p,className:`relative py-1 text-[10px] font-bold uppercase tracking-[0.1em] text-zinc-600 hover:text-black transition-colors group`,children:[`API Keys`,m]}),e[20]=p,e[21]=h);let g;e[22]===Symbol.for(`react.memo_cache_sentinel`)?(g=(0,q.jsx)(H,{}),e[22]=g):g=e[22];let _;e[23]===h?_=e[24]:(_=(0,q.jsx)(rd,{when:`signed-in`,children:(0,q.jsxs)(`div`,{className:`flex items-center gap-6`,children:[h,g]})}),e[23]=h,e[24]=_);let v;e[25]!==f||e[26]!==_?(v=(0,q.jsxs)(`div`,{className:`flex items-center gap-4 md:gap-8`,children:[r,i,a,(0,q.jsxs)(td,{children:[f,_]})]}),e[25]=f,e[26]=_,e[27]=v):v=e[27];let y;e[28]===Symbol.for(`react.memo_cache_sentinel`)?(y=(0,q.jsx)(`div`,{className:`md:hidden`,children:(0,q.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:`24`,height:`24`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,q.jsx)(`line`,{x1:`4`,x2:`20`,y1:`12`,y2:`12`}),(0,q.jsx)(`line`,{x1:`4`,x2:`20`,y1:`6`,y2:`6`}),(0,q.jsx)(`line`,{x1:`4`,x2:`20`,y1:`18`,y2:`18`})]})}),e[28]=y):y=e[28];let b;return e[29]===v?b=e[30]:(b=(0,q.jsx)(`nav`,{className:`fixed top-0 left-0 right-0 z-50 bg-white/80 backdrop-blur-md border-b border-zinc-100`,children:(0,q.jsxs)(`div`,{className:`max-w-7xl mx-auto px-6 h-20 flex items-center justify-between`,children:[n,v,y]})}),e[29]=v,e[30]=b),b},zg=()=>{let e=(0,P.c)(2),t;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(t=(0,q.jsx)(`div`,{className:`text-xl font-black uppercase tracking-tighter text-black`,children:`CautionLabs`}),e[0]=t):t=e[0];let n;return e[1]===Symbol.for(`react.memo_cache_sentinel`)?(n=(0,q.jsx)(`footer`,{className:`py-12 px-6 border-t border-zinc-100 bg-white mt-auto`,children:(0,q.jsx)(`div`,{className:`max-w-7xl mx-auto flex flex-col md:flex-row justify-between items-center gap-8`,children:(0,q.jsxs)(`div`,{className:`flex flex-col items-center md:items-start space-y-2`,children:[t,(0,q.jsxs)(`div`,{className:`text-xs text-zinc-400 font-medium`,children:[`© `,new Date().getFullYear(),` CautionLabs. All rights reserved.`]})]})})}),e[1]=n):n=e[1],n},Bg=void 0,Vg=()=>{let e=(0,P.c)(12),{getToken:t}=iu(),n;e[0]===t?n=e[1]:(n=async(e,n)=>{let r=n===void 0?{}:n,i=await t(),a={"Content-Type":`application/json`,...i?{Authorization:`Bearer ${i}`}:{},...r.headers},o=await fetch(`${Bg}${e}`,{...r,headers:a});if(!o.ok){let e=await o.json().catch(Hg);throw Error(e.message||`API Request failed with status ${o.status}`)}return o.json()},e[0]=t,e[1]=n);let r=n,i;e[2]===r?i=e[3]:(i=async e=>r(`/users/create`,{method:`POST`,body:JSON.stringify({email:e})}),e[2]=r,e[3]=i);let a=i,o;e[4]===r?o=e[5]:(o=async()=>r(`/api-keys`,{method:`GET`}),e[4]=r,e[5]=o);let s=o,c;e[6]===r?c=e[7]:(c=async()=>r(`/api-keys/roll`,{method:`POST`}),e[6]=r,e[7]=c);let l=c,u;return e[8]!==a||e[9]!==s||e[10]!==l?(u={createUser:a,getApiKey:s,rollApiKey:l},e[8]=a,e[9]=s,e[10]=l,e[11]=u):u=e[11],u};function Hg(){return{}}var Ug=()=>{let{isSignedIn:e,user:t}=sc(),{createUser:n}=Vg();return(0,g.useEffect)(()=>{(async()=>{if(e)try{let e=t.primaryEmailAddress?.emailAddress;e&&await n(e)}catch(e){console.error(`Failed to sync user with backend:`,e)}})()},[e,t,n]),null},Wg=()=>{let e=(0,P.c)(3),t,n;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(t=(0,q.jsx)(Ug,{}),n=(0,q.jsx)(Rg,{}),e[0]=t,e[1]=n):(t=e[0],n=e[1]);let r;return e[2]===Symbol.for(`react.memo_cache_sentinel`)?(r=(0,q.jsxs)(`div`,{className:`flex flex-col min-h-screen bg-white`,children:[t,n,(0,q.jsx)(`main`,{className:`flex-grow pt-20`,children:(0,q.jsx)(Hi,{})}),(0,q.jsx)(zg,{})]}),e[2]=r):r=e[2],r},Gg=()=>{let e=(0,P.c)(7),t;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(t=(0,q.jsx)(`div`,{className:`absolute top-0 left-1/2 -translate-x-1/2 w-[1000px] h-[600px] bg-zinc-50 rounded-full blur-[120px] -z-10 opacity-50`}),e[0]=t):t=e[0];let n;e[1]===Symbol.for(`react.memo_cache_sentinel`)?(n=(0,q.jsx)(`div`,{className:`inline-block py-1 px-3 border border-black/10 bg-zinc-50 text-[10px] sm:text-xs font-bold tracking-[0.2em] uppercase text-black mb-4`,children:`Advanced Text Moderation`}),e[1]=n):n=e[1];let r,i,a;e[2]===Symbol.for(`react.memo_cache_sentinel`)?(r=(0,q.jsxs)(`h1`,{className:`text-5xl md:text-7xl font-black tracking-tight leading-[1.1] text-black`,children:[`Safeguard your `,(0,q.jsx)(`br`,{}),(0,q.jsx)(`span`,{className:`text-zinc-400`,children:`digital space.`})]}),i=(0,q.jsx)(`p`,{className:`text-xl md:text-2xl text-zinc-500 max-w-2xl mx-auto font-medium`,children:`Powerful, AI-driven text moderation built for modern internet. Detect and categorize risks in content in real-time.`}),a=(0,q.jsx)(`div`,{className:`flex flex-col sm:flex-row items-center justify-center gap-4 pt-4`}),e[2]=r,e[3]=i,e[4]=a):(r=e[2],i=e[3],a=e[4]);let o;e[5]===Symbol.for(`react.memo_cache_sentinel`)?(o=(0,q.jsxs)(`div`,{className:`max-w-4xl mx-auto space-y-8 animate-in fade-in slide-in-from-bottom-8 duration-1000`,children:[n,r,i,a,(0,q.jsx)(`div`,{className:`pt-20 opacity-20`,children:(0,q.jsxs)(`svg`,{width:`100%`,height:`40`,viewBox:`0 0 1200 40`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,className:`w-full max-w-3xl mx-auto`,children:[(0,q.jsx)(`path`,{d:`M0 20H1200`,stroke:`black`,strokeWidth:`0.5`,strokeDasharray:`10 10`}),(0,q.jsx)(`circle`,{cx:`600`,cy:`20`,r:`4`,fill:`black`})]})})]}),e[5]=o):o=e[5];let s;return e[6]===Symbol.for(`react.memo_cache_sentinel`)?(s=(0,q.jsxs)(`section`,{className:`relative py-24 px-6 flex flex-col items-center justify-center text-center bg-white border-b border-zinc-100 overflow-hidden`,children:[t,o,(0,q.jsxs)(`div`,{className:`absolute bottom-12 left-1/2 -translate-x-1/2 flex flex-col items-center gap-3`,children:[(0,q.jsx)(`div`,{className:`w-[30px] h-[50px] border-2 border-black/10 rounded-full flex justify-center p-2 bg-white/50 backdrop-blur-sm`,children:(0,q.jsx)(`div`,{className:`w-1.5 h-1.5 bg-black rounded-full animate-bounce-slow`})}),(0,q.jsx)(`span`,{className:`text-[10px] uppercase tracking-[0.4em] font-black text-black/20`,children:`Scroll`})]})]}),e[6]=s):s=e[6],s},Kg=e=>{let t=(0,P.c)(11),{title:n,description:r,icon:i,className:a}=e,o=`
      p-12 bg-white border border-zinc-200 
      hover:border-black transition-colors duration-300
      group flex flex-col items-center text-center
      ${a===void 0?``:a}
    `,s;t[0]===i?s=t[1]:(s=i&&(0,q.jsx)(`div`,{className:`mb-8 text-black group-hover:scale-110 transition-transform duration-500`,children:i}),t[0]=i,t[1]=s);let c;t[2]===n?c=t[3]:(c=(0,q.jsx)(`h3`,{className:`text-3xl font-black mb-6 text-black tracking-tight uppercase italic underline decoration-1 underline-offset-8`,children:n}),t[2]=n,t[3]=c);let l;t[4]===r?l=t[5]:(l=(0,q.jsx)(`p`,{className:`text-lg text-zinc-500 leading-relaxed max-w-sm`,children:r}),t[4]=r,t[5]=l);let u;return t[6]!==o||t[7]!==s||t[8]!==c||t[9]!==l?(u=(0,q.jsxs)(`div`,{className:o,children:[s,c,l]}),t[6]=o,t[7]=s,t[8]=c,t[9]=l,t[10]=u):u=t[10],u},qg=()=>{let e=(0,P.c)(3),t;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(t={title:`Text Moderation`,description:`Sophisticated AI detection and categorization for toxicity, high risks and harmful content across multiple languages.`,icon:(0,q.jsx)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:`48`,height:`48`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`1`,strokeLinecap:`round`,strokeLinejoin:`round`,children:(0,q.jsx)(`path`,{d:`M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10`})}),link:`/solutions/toxicity-detection`},e[0]=t):t=e[0];let n;e[1]===Symbol.for(`react.memo_cache_sentinel`)?(n=[t,{title:`Real-time API`,description:`Ultra-low latency API designed for high-throughput communities and seamless integration.`,icon:(0,q.jsx)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:`48`,height:`48`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`1`,strokeLinecap:`round`,strokeLinejoin:`round`,children:(0,q.jsx)(`path`,{d:`M13 2L3 14h9l-1 8 10-12h-9l1-8z`})}),link:`/solutions/spam-detection`}],e[1]=n):n=e[1];let r=n,i;return e[2]===Symbol.for(`react.memo_cache_sentinel`)?(i=(0,q.jsx)(`section`,{className:`py-24 px-6 bg-white max-w-7xl mx-auto`,children:(0,q.jsx)(`div`,{className:`grid grid-cols-1 md:grid-cols-2 gap-12`,children:r.map(Jg)})}),e[2]=i):i=e[2],i};function Jg(e,t){return(0,q.jsx)(Pa,{to:e.link,className:`no-underline`,children:(0,q.jsx)(Kg,{title:e.title,description:e.description,icon:e.icon})},t)}var Yg=`CautionLabs`,Xg=`https://cautionlabs.com`,Zg=`CautionLabs - Advanced AI Moderation API`,Qg=`Safeguard your digital space with CautionLabs. Powerful AI moderation built for the modern internet. Detect and categorize risks, toxicity, and harmful content in real-time.`,$g=`https://cdn.cautionlabs.com/transparentlabicon.webp`,e_=()=>{let e=(0,P.c)(22),t,n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(t=(0,q.jsx)(`html`,{lang:`en`}),n=(0,q.jsx)(`title`,{children:Zg}),p=(0,q.jsx)(`meta`,{name:`description`,content:Qg}),m=(0,q.jsx)(`meta`,{name:`keywords`,content:`AI moderation API, AI content moderation, real-time moderation, toxicity detection, online community safety, CautionLabs`}),h=(0,q.jsx)(`meta`,{name:`robots`,content:`index, follow`}),g=(0,q.jsx)(`link`,{rel:`canonical`,href:Xg}),_=(0,q.jsx)(`meta`,{property:`og:locale`,content:`en_US`}),v=(0,q.jsx)(`meta`,{property:`og:site_name`,content:Yg}),y=(0,q.jsx)(`meta`,{property:`og:type`,content:`website`}),b=(0,q.jsx)(`meta`,{property:`og:url`,content:Xg}),r=(0,q.jsx)(`meta`,{property:`og:title`,content:Zg}),i=(0,q.jsx)(`meta`,{property:`og:description`,content:Qg}),a=(0,q.jsx)(`meta`,{property:`og:image`,content:$g}),o=(0,q.jsx)(`meta`,{property:`og:image:alt`,content:`CautionLabs`}),s=(0,q.jsx)(`meta`,{name:`twitter:card`,content:`summary_large_image`}),c=(0,q.jsx)(`meta`,{name:`twitter:url`,content:Xg}),l=(0,q.jsx)(`meta`,{name:`twitter:title`,content:Zg}),u=(0,q.jsx)(`meta`,{name:`twitter:description`,content:Qg}),d=(0,q.jsx)(`meta`,{name:`twitter:image`,content:$g}),f=(0,q.jsx)(`meta`,{name:`theme-color`,content:`#ffffff`}),e[0]=t,e[1]=n,e[2]=r,e[3]=i,e[4]=a,e[5]=o,e[6]=s,e[7]=c,e[8]=l,e[9]=u,e[10]=d,e[11]=f,e[12]=p,e[13]=m,e[14]=h,e[15]=g,e[16]=_,e[17]=v,e[18]=y,e[19]=b):(t=e[0],n=e[1],r=e[2],i=e[3],a=e[4],o=e[5],s=e[6],c=e[7],l=e[8],u=e[9],d=e[10],f=e[11],p=e[12],m=e[13],h=e[14],g=e[15],_=e[16],v=e[17],y=e[18],b=e[19]);let x;e[20]===Symbol.for(`react.memo_cache_sentinel`)?(x=(0,q.jsx)(`script`,{type:`application/ld+json`,children:JSON.stringify({"@context":`https://schema.org`,"@type":`WebSite`,name:Yg,url:Xg,description:Qg,publisher:{"@type":`Organization`,name:Yg,logo:{"@type":`ImageObject`,url:$g}}})}),e[20]=x):x=e[20];let S;return e[21]===Symbol.for(`react.memo_cache_sentinel`)?(S=(0,q.jsxs)(Ie,{prioritizeSeoTags:!0,children:[t,n,p,m,h,g,_,v,y,b,r,i,a,o,s,c,l,u,d,f,x,(0,q.jsx)(`script`,{type:`application/ld+json`,children:JSON.stringify({"@context":`https://schema.org`,"@type":`Organization`,name:Yg,url:Xg,logo:$g,description:`Advanced AI moderation for modern communities and platforms.`})})]}),e[21]=S):S=e[21],S},t_=()=>{let e=(0,P.c)(1),t;return e[0]===Symbol.for(`react.memo_cache_sentinel`)?(t=(0,q.jsxs)(q.Fragment,{children:[(0,q.jsx)(e_,{}),(0,q.jsx)(Gg,{}),(0,q.jsx)(qg,{})]}),e[0]=t):t=e[0],t},n_=[{slug:`toxicity-detection`,name:`Toxicity`,tagline:`Toxicity Detection`,headline:`Detect Toxic Content`,headlineAccent:`Before It Spreads.`,description:`Identify abusive, hostile, and toxic language in real-time. Protect your community from harmful interactions with AI-powered toxicity scoring.`,metaTitle:`Toxicity Detection API — AI Content Moderation | CautionLabs`,metaDescription:`Detect toxic and abusive language in real-time with CautionLabs AI. Score content on a 0-1 toxicity scale. Start free.`,keywords:`toxicity detection API, toxic content filter, AI toxicity scoring, abusive language detection, online safety`,icon:`🛡️`,color:`#ef4444`,problemTitle:`Toxic Content Destroys Communities`,problemDescription:`Unchecked toxicity drives away users, increases churn, and creates hostile environments. Users abandon platforms after encountering toxic behavior. Manual moderation cannot keep up with the scale of modern digital platforms.`,features:[{title:`Multi-layered Detection`,description:`Goes beyond keyword matching to understand context, sarcasm, and coded language.`},{title:`Continuous Scoring`,description:`Returns a 0–1 confidence score, letting you set your own thresholds for different contexts.`},{title:`Context-Aware`,description:`Understands conversational context to distinguish between genuine toxicity and casual speech.`}],useCases:[{industry:`Social Media`,example:`Filter toxic comments and replies in real-time feeds`},{industry:`Gaming`,example:`Moderate in-game chat to maintain fair play environments`},{industry:`Forums`,example:`Auto-flag toxic posts before they escalate into flame wars`}],apiField:`toxic`,apiDescription:`General toxicity score from 0 (safe) to 1 (highly toxic)`},{slug:`profanity-detection`,name:`Profanity`,tagline:`Profanity Filter`,headline:`Filter Explicit Language`,headlineAccent:`Instantly.`,description:`Catch profanity, slurs, and vulgar expressions across languages. Keep your platform clean with intelligent, context-aware profanity filtering.`,metaTitle:`Profanity Filter API — AI Profanity Detection | CautionLabs`,metaDescription:`Intelligent profanity detection API that catches explicit language, slurs, and vulgar expressions. Context-aware, multi-language. Start free.`,keywords:`profanity filter API, bad word filter, explicit language detection, swear word filter, content moderation`,icon:`🚫`,color:`#f97316`,problemTitle:`Profanity Undermines Brand Safety`,problemDescription:`Explicit language in user-generated content can damage your brand reputation and alienate advertisers. Simple word lists fail to catch creative misspellings, unicode tricks, and contextual profanity.`,features:[{title:`Beyond Word Lists`,description:`AI-powered detection catches creative misspellings, leetspeak, and unicode obfuscation.`},{title:`Multi-Language Support`,description:`Detects profanity across multiple languages and cultural contexts.`},{title:`Contextual Awareness`,description:`Distinguishes between profanity used aggressively vs. casual slang to reduce false positives.`}],useCases:[{industry:`E-commerce`,example:`Clean product reviews and Q&A sections automatically`},{industry:`Education`,example:`Maintain safe language in student collaboration platforms`},{industry:`Streaming`,example:`Filter live chat profanity during broadcasts in real-time`}],apiField:`profanity`,apiDescription:`Profanity confidence score from 0 (clean) to 1 (highly explicit)`},{slug:`hate-speech-detection`,name:`Hate Speech`,tagline:`Hate Speech Detection`,headline:`Eliminate Hate Speech`,headlineAccent:`At Scale.`,description:`Detect hateful content targeting identity groups based on race, religion, gender, and more. Build inclusive communities with precision hate speech analysis.`,metaTitle:`Hate Speech Detection API — AI-Powered Analysis | CautionLabs`,metaDescription:`Detect hate speech targeting identity groups with CautionLabs AI API. Real-time analysis for race, religion, gender-based hatred. Start free.`,keywords:`hate speech detection API, hate content filter, racist content detection, anti-hate AI, content safety`,icon:`⚖️`,color:`#dc2626`,problemTitle:`Hate Speech Has No Place Online`,problemDescription:`Hateful content creates hostile environments and can have real-world consequences. Platforms face regulatory pressure to remove hate speech quickly. Manual review is too slow — automated detection is essential.`,features:[{title:`Identity-Aware`,description:`Detects hate targeting race, ethnicity, religion, gender, sexual orientation, and disability.`},{title:`Implicit Hate Detection`,description:`Catches coded language, dog whistles, and veiled hate that keyword filters miss.`},{title:`Regulatory Compliance`,description:`Helps meet requirements under the Digital Services Act, NetzDG, and similar legislation.`}],useCases:[{industry:`Social Platforms`,example:`Auto-remove hateful posts before they go viral`},{industry:`News Sites`,example:`Moderate comment sections to maintain civil discourse`},{industry:`Enterprise`,example:`Monitor internal communications for workplace hate speech`}],apiField:`hate`,apiDescription:`Hate speech score from 0 (no hate) to 1 (strong hate)`},{slug:`harassment-detection`,name:`Harassment`,tagline:`Harassment Detection`,headline:`Stop Online Harassment`,headlineAccent:`In Real-Time.`,description:`Identify bullying, intimidation, and targeted attacks before they escalate. Protect your users with intelligent harassment detection powered by AI.`,metaTitle:`Harassment Detection API — AI Anti-Bullying Filter | CautionLabs`,metaDescription:`Detect online harassment, bullying, and targeted attacks in real-time. AI-powered API with 0-1 scoring. Protect your users. Start free.`,keywords:`harassment detection API, cyberbullying detection, anti-bullying filter, online harassment AI, targeted attack detection`,icon:`🎯`,color:`#e11d48`,problemTitle:`Harassment Silences Your Users`,problemDescription:`Online harassment causes real psychological harm. Many internet users have experienced harassment, and they leave platforms permanently. Proactive detection is the only way to protect your community at scale.`,features:[{title:`Pattern Recognition`,description:`Identifies repeated targeting, pile-on attacks, and coordinated harassment campaigns.`},{title:`Severity Grading`,description:`Grades harassment from mild teasing to severe threats, so you can respond proportionally.`},{title:`Direct & Indirect`,description:`Catches both overt attacks and subtle, indirect harassment like passive-aggressive undermining.`}],useCases:[{industry:`Gaming`,example:`Detect toxic player behavior and griefing in chat`},{industry:`Social Media`,example:`Identify and flag coordinated pile-on harassment campaigns`},{industry:`Workplace Tools`,example:`Monitor for workplace bullying in messaging platforms`}],apiField:`harassment`,apiDescription:`Harassment score from 0 (safe) to 1 (severe harassment)`},{slug:`self-harm-detection`,name:`Self-Harm`,tagline:`Self-Harm Detection`,headline:`Detect Self-Harm Content`,headlineAccent:`Save Lives.`,description:`Identify content promoting or describing self-injury and suicidal ideation. Enable early intervention with sensitive, accurate AI detection.`,metaTitle:`Self-Harm Detection API — Content Safety | CautionLabs`,metaDescription:`Detect self-harm and suicidal content with CautionLabs AI API. Sensitive, accurate detection enables early intervention. Protect vulnerable users.`,keywords:`self-harm detection API, suicide prevention content filter, self-injury detection, content safety AI, mental health moderation`,icon:`💜`,color:`#a855f7`,problemTitle:`Self-Harm Content Requires Immediate Action`,problemDescription:`Content glorifying or instructing self-harm can trigger vulnerable individuals. Platforms have a duty of care to detect and respond to such content immediately. Every minute matters.`,features:[{title:`Sensitive Detection`,description:`Trained to distinguish between harm promotion and recovery/support discussions.`},{title:`Urgency Scoring`,description:`Flags imminent-risk content differently from general mentions, enabling priority response.`},{title:`Crisis Integration`,description:`Pair with crisis hotline resources to provide immediate support to at-risk users.`}],useCases:[{industry:`Social Media`,example:`Flag at-risk posts and surface crisis resources to the user`},{industry:`Healthcare`,example:`Monitor patient forums for signs of self-harm ideation`},{industry:`Education`,example:`Protect student platforms with early warning detection`}],apiField:`self_harm`,apiDescription:`Self-harm content score from 0 (safe) to 1 (high risk)`},{slug:`adult-content-detection`,name:`Adult Content`,tagline:`Adult Content Detection`,headline:`Filter Adult Content`,headlineAccent:`Automatically.`,description:`Detect sexually explicit and suggestive material in user text. Maintain platform standards and advertiser confidence with precise adult content scoring.`,metaTitle:`Adult Content Detection API — NSFW Text Filter | CautionLabs`,metaDescription:`Detect NSFW and sexually explicit text content with CautionLabs AI API. Protect minors, maintain brand safety, and comply with regulations.`,keywords:`NSFW detection API, adult content filter, explicit text detection, sexual content moderation, brand safety API`,icon:`🔞`,color:`#ec4899`,problemTitle:`Adult Content Risks Brand Safety & Compliance`,problemDescription:`Unfiltered adult content damages brand reputation, drives away advertisers, and creates legal liability. Age-gating alone is insufficient — you need proactive detection at the content level.`,features:[{title:`Nuanced Detection`,description:`Distinguishes between clinical/educational content and genuinely explicit material.`},{title:`Suggestive vs. Explicit`,description:`Graduated scoring lets you set different thresholds for suggestive and explicitly sexual content.`},{title:`Advertiser Safe`,description:`Keep ad-supported content in brand-safe zones with configurable sensitivity levels.`}],useCases:[{industry:`UGC Platforms`,example:`Auto-filter explicit text in posts, bios, and messages`},{industry:`Dating Apps`,example:`Enforce community guidelines while allowing appropriate content`},{industry:`Ad Tech`,example:`Ensure ad placements never appear near explicit content`}],apiField:`adult`,apiDescription:`Adult content score from 0 (safe) to 1 (highly explicit)`},{slug:`violence-detection`,name:`Violence`,tagline:`Violence Detection`,headline:`Detect Violent Content`,headlineAccent:`Proactively.`,description:`Identify graphic violence, threats of physical harm, and glorification of violence. Keep your platform safe with real-time violence detection.`,metaTitle:`Violence Detection API — Threat & Violence Filter | CautionLabs`,metaDescription:`Detect violent content, graphic descriptions, and physical threats in text with CautionLabs AI. Real-time 0-1 scoring. Start free.`,keywords:`violence detection API, violent content filter, threat detection, graphic violence AI, content safety`,icon:`⚔️`,color:`#b91c1c`,problemTitle:`Violent Content Creates Real-World Harm`,problemDescription:`Violent content can incite real-world violence, traumatize users, and expose platforms to legal liability. From graphic descriptions to veiled threats, AI detection catches what manual review misses.`,features:[{title:`Threat Detection`,description:`Identifies direct threats, indirect threats, and conditional threats of physical harm.`},{title:`Graphic Content Scoring`,description:`Scores graphic descriptions of violence separately from threats, enabling nuanced policies.`},{title:`Glorification Detection`,description:`Catches content that celebrates or glorifies violence, even without explicit descriptions.`}],useCases:[{industry:`News Platforms`,example:`Filter graphic user comments on sensitive stories`},{industry:`Social Media`,example:`Detect and remove threats before they become incidents`},{industry:`Gaming`,example:`Moderate player threats that cross the line from gameplay to real harm`}],apiField:`violence`,apiDescription:`Violence score from 0 (non-violent) to 1 (graphic/threatening)`},{slug:`drug-content-detection`,name:`Drug Content`,tagline:`Drug Content Detection`,headline:`Detect Drug-Related Content`,headlineAccent:`With Precision.`,description:`Identify content promoting, glorifying, or facilitating illegal drug use. Maintain compliance and community safety with AI-powered drug content analysis.`,metaTitle:`Drug Content Detection API — Substance Abuse Filter | CautionLabs`,metaDescription:`Detect drug-related content, substance promotion, and illegal drug discussions with CautionLabs AI API. Maintain compliance effortlessly.`,keywords:`drug content detection API, substance abuse filter, drug promotion detection, content compliance, illegal drug content AI`,icon:`💊`,color:`#16a34a`,problemTitle:`Drug Content Creates Compliance Risk`,problemDescription:`Content promoting illegal substances violates platform policies and regulatory requirements. From casual drug glorification to outright sales solicitation, platforms need proactive detection to stay compliant.`,features:[{title:`Promotion vs. Discussion`,description:`Distinguishes between drug promotion/glorification and educational or harm-reduction content.`},{title:`Sales Detection`,description:`Catches coded language used in drug solicitation and marketplace activity.`},{title:`Substance Classification`,description:`Identifies references to specific substance categories for granular policy enforcement.`}],useCases:[{industry:`Social Media`,example:`Detect and remove drug promotion and sales solicitation`},{industry:`Marketplaces`,example:`Catch coded drug listings that evade keyword filters`},{industry:`Youth Platforms`,example:`Protect minors from drug-related content and solicitation`}],apiField:`drugs`,apiDescription:`Drug content score from 0 (safe) to 1 (drug-related)`},{slug:`weapons-detection`,name:`Weapons`,tagline:`Weapons Content Detection`,headline:`Detect Weapons Content`,headlineAccent:`Protect Your Platform.`,description:`Identify content promoting dangerous weapons, illegal sales, and weapons-related threats. Safeguard your community with real-time weapons content detection.`,metaTitle:`Weapons Content Detection API — AI Safety Filter | CautionLabs`,metaDescription:`Detect weapons-related content, illegal sales, and dangerous weapons promotion with CautionLabs AI. Real-time detection API. Start free.`,keywords:`weapons detection API, gun content filter, weapons content moderation, illegal weapons detection, firearms content AI`,icon:`🔫`,color:`#78716c`,problemTitle:`Weapons Content Requires Vigilant Moderation`,problemDescription:`Content promoting weapons sales, manufacturing, or use poses serious safety and legal risks. Platforms must detect weapons-related content proactively to prevent harm and maintain community trust.`,features:[{title:`Sales Detection`,description:`Catches illegal weapons sales, trades, and solicitation across text content.`},{title:`Manufacturing Content`,description:`Detects instructions for weapons manufacturing and modification, including 3D printing.`},{title:`Threat Context`,description:`Identifies when weapons mentions escalate to genuine threats requiring immediate action.`}],useCases:[{industry:`Marketplaces`,example:`Prevent illegal weapons listings and coded sales posts`},{industry:`Social Media`,example:`Flag weapons-related threats for law enforcement review`},{industry:`Forums`,example:`Moderate weapons discussions to separate legal hobby content from dangerous posts`}],apiField:`weapons`,apiDescription:`Weapons content score from 0 (safe) to 1 (weapons-related)`},{slug:`pii-detection`,name:`PII Detection`,tagline:`PII Detection`,headline:`Detect Personal Information`,headlineAccent:`Prevent Data Leaks.`,description:`Identify exposed personal information like emails, phone numbers, SSNs, and addresses in user content. Prevent data leaks and ensure privacy compliance.`,metaTitle:`PII Detection API — Personal Data Protection | CautionLabs`,metaDescription:`Detect PII like emails, phone numbers, SSNs, and addresses in text with CautionLabs AI. Real-time scanning for GDPR/CCPA compliance.`,keywords:`PII detection API, personal data detection, GDPR compliance, email detection, SSN detection, data leak prevention`,icon:`🔒`,color:`#2563eb`,problemTitle:`Leaked PII Means Regulatory Fines & Lost Trust`,problemDescription:`Users accidentally share personal data in public posts, chats, and forums. Under GDPR, CCPA, and other regulations, platforms face massive fines for failing to protect personal information. Proactive detection is essential.`,features:[{title:`Multi-Type Detection`,description:`Catches emails, phone numbers, SSNs, addresses, credit card numbers, and more.`},{title:`Compliance Ready`,description:`Designed for GDPR, CCPA, HIPAA, and other privacy regulation compliance workflows.`},{title:`Auto-Redaction Ready`,description:`Pair with your redaction pipeline to automatically mask detected PII before it goes public.`}],useCases:[{industry:`Healthcare`,example:`Prevent patient data leakage in support forums and chat`},{industry:`Finance`,example:`Detect account numbers and SSNs shared in customer communications`},{industry:`Social Media`,example:`Auto-detect and warn users before they post personal information publicly`}],apiField:`pii`,apiDescription:`PII presence score from 0 (clean) to 1 (contains PII)`},{slug:`spam-detection`,name:`Spam`,tagline:`Spam Detection`,headline:`Eliminate Spam`,headlineAccent:`Effortlessly.`,description:`Detect unsolicited promotional content, repetitive messages, and bot-generated spam. Keep your platform clean and your signal-to-noise ratio high.`,metaTitle:`Spam Detection API — AI Anti-Spam Filter | CautionLabs`,metaDescription:`Detect and filter spam, promotional content, and bot messages with CautionLabs AI API. Real-time scoring. Start free.`,keywords:`spam detection API, anti-spam filter, bot detection, promotional content filter, content quality AI`,icon:`📧`,color:`#eab308`,problemTitle:`Spam Drowns Out Real Conversations`,problemDescription:`Spam floods platforms with noise — promotional links, bot-generated content, and repetitive messages degrade user experience. Users leave platforms where spam overwhelms genuine interaction.`,features:[{title:`Bot Detection`,description:`Identifies bot-generated content patterns including template spam and auto-generated messages.`},{title:`Promotional Scoring`,description:`Detects unsolicited promotional content disguised as genuine posts or reviews.`},{title:`Duplicate Detection`,description:`Catches repetitive content across multiple users or accounts, typical of spam campaigns.`}],useCases:[{industry:`Forums`,example:`Auto-filter spam posts and bot accounts in real-time`},{industry:`E-commerce`,example:`Detect fake reviews and promotional spam in ratings`},{industry:`Messaging`,example:`Block spam messages before they reach users in chat applications`}],apiField:`spam`,apiDescription:`Spam confidence score from 0 (genuine) to 1 (definite spam)`},{slug:`minor-safety-detection`,name:`Minor Safety`,tagline:`Minor Safety Detection`,headline:`Protect Minors`,headlineAccent:`Zero Compromise.`,description:`Detect content that endangers children and minors. From predatory behavior to exploitative material — safeguard the most vulnerable with critical-priority detection.`,metaTitle:`Minor Safety Detection API — Child Protection | CautionLabs`,metaDescription:`Detect content endangering minors with CautionLabs AI API. Identify predatory behavior, grooming, and exploitative content. Zero tolerance.`,keywords:`child safety API, minor protection, CSAM detection, grooming detection, child exploitation filter, online child safety`,icon:`👶`,color:`#0ea5e9`,problemTitle:`Protecting Minors Is Non-Negotiable`,problemDescription:`Content endangering children is the highest-priority moderation challenge. Platforms face criminal liability, regulatory action, and irreparable brand damage for failure to detect and remove exploitative content targeting minors.`,features:[{title:`Grooming Detection`,description:`Identifies predatory communication patterns and grooming behavior in conversations.`},{title:`Age-Inappropriate Content`,description:`Flags content inappropriate for minor audiences, even if not technically illegal.`},{title:`Critical Priority`,description:`Highest-priority flagging with immediate alert capabilities for emergency response teams.`}],useCases:[{industry:`Social Media`,example:`Detect grooming patterns in DMs and comments targeting young users`},{industry:`Gaming`,example:`Monitor in-game chat for predatory behavior toward minor players`},{industry:`Education`,example:`Ensure student platforms remain safe from exploitative content`}],apiField:`minor`,apiDescription:`Minor safety risk score from 0 (safe) to 1 (critical risk)`}],r_=e=>n_.find(t=>t.slug===e),i_=e=>{let t=(0,P.c)(20),{field:n,description:r}=e,i;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(i=(0,q.jsxs)(`div`,{className:`flex items-center gap-2 mb-4 pb-4 border-b border-zinc-800`,children:[(0,q.jsx)(`div`,{className:`w-3 h-3 rounded-full bg-red-500/80`}),(0,q.jsx)(`div`,{className:`w-3 h-3 rounded-full bg-yellow-500/80`}),(0,q.jsx)(`div`,{className:`w-3 h-3 rounded-full bg-green-500/80`}),(0,q.jsx)(`span`,{className:`ml-2 text-zinc-500 text-xs`,children:`api-request.sh`})]}),t[0]=i):i=t[0];let a=`# Analyze text for `+n+` content`,o;t[1]===a?o=t[2]:(o=(0,q.jsx)(`span`,{className:`code-comment`,children:a}),t[1]=a,t[2]=o);let s;t[3]===Symbol.for(`react.memo_cache_sentinel`)?(s=(0,q.jsx)(`span`,{className:`code-keyword`,children:`curl`}),t[3]=s):s=t[3];let c;t[4]===Symbol.for(`react.memo_cache_sentinel`)?(c=(0,q.jsx)(`span`,{className:`code-string`,children:`POST`}),t[4]=c):c=t[4];let l;t[5]===Symbol.for(`react.memo_cache_sentinel`)?(l=(0,q.jsx)(`span`,{className:`code-url`,children:`https://api.cautionlabs.com/v1/moderate`}),t[5]=l):l=t[5];let u;t[6]===Symbol.for(`react.memo_cache_sentinel`)?(u=(0,q.jsx)(`span`,{className:`code-string`,children:`"Authorization: Bearer YOUR_API_KEY"`}),t[6]=u):u=t[6];let d;t[7]===Symbol.for(`react.memo_cache_sentinel`)?(d=(0,q.jsx)(`span`,{className:`code-string`,children:`"Content-Type: application/json"`}),t[7]=d):d=t[7];let f;t[8]===Symbol.for(`react.memo_cache_sentinel`)?(f=(0,q.jsx)(`span`,{className:`code-string`,children:`'{"text": "Your content to analyze"}'`}),t[8]=f):f=t[8];let p;t[9]===Symbol.for(`react.memo_cache_sentinel`)?(p=(0,q.jsx)(`span`,{className:`code-comment`,children:`// Response`}),t[9]=p):p=t[9];let m;t[10]===n?m=t[11]:(m=(0,q.jsxs)(`span`,{className:`code-key`,children:[`"`,n,`"`]}),t[10]=n,t[11]=m);let h;t[12]===Symbol.for(`react.memo_cache_sentinel`)?(h=(0,q.jsx)(`span`,{className:`code-number`,children:`0.87`}),t[12]=h):h=t[12];let g=`// `+r,_;t[13]===g?_=t[14]:(_=(0,q.jsx)(`span`,{className:`code-comment`,children:g}),t[13]=g,t[14]=_);let v;t[15]===Symbol.for(`react.memo_cache_sentinel`)?(v=(0,q.jsx)(`span`,{className:`code-comment`,children:`// ... other category scores`}),t[15]=v):v=t[15];let y;return t[16]!==m||t[17]!==_||t[18]!==o?(y=(0,q.jsxs)(`div`,{className:`solution-code-block p-6 md:p-8`,children:[i,(0,q.jsxs)(`pre`,{className:`whitespace-pre-wrap`,children:[o,`
`,s,` -X `,c,` `,l,` \\
  -H `,u,` \\
  -H `,d,` \\
  -d `,f,`

`,p,`
`,`{
`,`  `,m,`: `,h,`  `,_,`
  `,v,`
}`]})]}),t[16]=m,t[17]=_,t[18]=o,t[19]=y):y=t[19],y},a_=()=>{let{slug:e}=li(),t=r_(e??``),{logEvent:n}=Ig();if(!t)return(0,q.jsx)(`div`,{className:`min-h-[60vh] flex items-center justify-center`,children:(0,q.jsxs)(`div`,{className:`text-center`,children:[(0,q.jsx)(`h1`,{className:`text-4xl font-black text-black mb-4`,children:`Page Not Found`}),(0,q.jsx)(`p`,{className:`text-zinc-500 mb-8`,children:`This solution page doesn't exist.`}),(0,q.jsx)(Pa,{to:`/`,className:`text-sm font-bold uppercase tracking-widest text-black border-b-2 border-black pb-1 hover:opacity-60 transition-opacity`,children:`Go Home`})]})});let r={"@context":`https://schema.org`,"@type":`SoftwareApplication`,name:`CautionLabs ${t.name} Detection`,applicationCategory:`DeveloperApplication`,operatingSystem:`Web API`,description:t.description,url:`https://cautionlabs.com/solutions/${t.slug}`,offers:{"@type":`Offer`,price:`0`,priceCurrency:`USD`,description:`Free tier available`},provider:{"@type":`Organization`,name:`CautionLabs`,url:`https://cautionlabs.com`}},i=n_.filter(e=>e.slug!==t.slug);return(0,q.jsxs)(`article`,{children:[(0,q.jsxs)(Ie,{children:[(0,q.jsx)(`title`,{children:t.metaTitle}),(0,q.jsx)(`meta`,{name:`description`,content:t.metaDescription}),(0,q.jsx)(`meta`,{name:`keywords`,content:t.keywords}),(0,q.jsx)(`link`,{rel:`canonical`,href:`https://cautionlabs.com/solutions/${t.slug}`}),(0,q.jsx)(`meta`,{property:`og:type`,content:`website`}),(0,q.jsx)(`meta`,{property:`og:url`,content:`https://cautionlabs.com/solutions/${t.slug}`}),(0,q.jsx)(`meta`,{property:`og:title`,content:t.metaTitle}),(0,q.jsx)(`meta`,{property:`og:description`,content:t.metaDescription}),(0,q.jsx)(`meta`,{property:`og:image`,content:`https://cdn.cautionlabs.com/transparentlabicon.webp`}),(0,q.jsx)(`meta`,{property:`og:site_name`,content:`CautionLabs`}),(0,q.jsx)(`meta`,{name:`twitter:card`,content:`summary_large_image`}),(0,q.jsx)(`meta`,{name:`twitter:title`,content:t.metaTitle}),(0,q.jsx)(`meta`,{name:`twitter:description`,content:t.metaDescription}),(0,q.jsx)(`meta`,{name:`twitter:image`,content:`https://cdn.cautionlabs.com/transparentlabicon.webp`}),(0,q.jsx)(`script`,{type:`application/ld+json`,children:JSON.stringify(r)})]}),(0,q.jsxs)(`section`,{id:`hero`,className:`relative py-28 md:py-36 px-6 flex flex-col items-center justify-center text-center bg-white border-b border-zinc-100 overflow-hidden`,children:[(0,q.jsx)(`div`,{className:`solution-hero-orb absolute top-0 left-1/2 w-[800px] h-[500px] rounded-full blur-[120px] -z-10`,style:{background:`radial-gradient(circle, ${t.color}15 0%, transparent 70%)`}}),(0,q.jsxs)(`div`,{className:`max-w-4xl mx-auto space-y-8`,children:[(0,q.jsx)(`div`,{className:`inline-block py-1.5 px-4 border border-black/10 bg-zinc-50 text-[10px] sm:text-xs font-bold tracking-[0.2em] uppercase text-black mb-2`,children:t.tagline}),(0,q.jsxs)(`h1`,{className:`text-5xl md:text-7xl lg:text-8xl font-black tracking-tight leading-[1.05] text-black`,children:[t.headline,` `,(0,q.jsx)(`br`,{}),(0,q.jsx)(`span`,{className:`text-zinc-400`,children:t.headlineAccent})]}),(0,q.jsx)(`p`,{className:`text-lg md:text-xl text-zinc-500 max-w-2xl mx-auto font-medium leading-relaxed`,children:t.description}),(0,q.jsxs)(`div`,{className:`flex flex-col sm:flex-row items-center justify-center gap-4 pt-4`,children:[(0,q.jsx)(rd,{when:`signed-out`,children:(0,q.jsx)(`span`,{onClickCapture:()=>{n(Lg.INDIRECT_LOGIN,{source:`category_page_hero`,slug:e})},children:(0,q.jsx)(Ad,{mode:`modal`,children:(0,q.jsx)(Fg,{text:`Get Started Free`,variant:Pg.PRIMARY,size:`lg`})})})}),(0,q.jsx)(rd,{when:`signed-in`,children:(0,q.jsx)(Pa,{to:`/api-keys`,onClick:()=>{n(Lg.REDIRECT_TO_DASHBOARD,{source:`category_page`,slug:e})},children:(0,q.jsx)(Fg,{text:`Go to Dashboard`,variant:Pg.PRIMARY,size:`lg`})})})]})]}),(0,q.jsx)(`div`,{className:`absolute bottom-8 left-1/2 -translate-x-1/2 flex flex-col items-center gap-3`,children:(0,q.jsx)(`div`,{className:`w-[28px] h-[44px] border-2 border-black/10 rounded-full flex justify-center p-2 bg-white/50 backdrop-blur-sm`,children:(0,q.jsx)(`div`,{className:`w-1.5 h-1.5 bg-black rounded-full animate-bounce-slow`})})})]}),(0,q.jsx)(`section`,{id:`problem`,className:`py-20 md:py-28 px-6 bg-white`,children:(0,q.jsxs)(`div`,{className:`max-w-4xl mx-auto text-center space-y-6`,children:[(0,q.jsx)(`h2`,{className:`text-3xl md:text-5xl font-black tracking-tight text-black`,children:t.problemTitle}),(0,q.jsx)(`p`,{className:`text-lg md:text-xl text-zinc-500 max-w-3xl mx-auto leading-relaxed`,children:t.problemDescription})]})}),(0,q.jsx)(`section`,{id:`features`,className:`py-20 md:py-28 px-6 bg-white`,children:(0,q.jsxs)(`div`,{className:`max-w-6xl mx-auto`,children:[(0,q.jsxs)(`div`,{className:`text-center mb-16`,children:[(0,q.jsx)(`div`,{className:`inline-block py-1 px-3 border border-black/10 bg-zinc-50 text-[10px] font-bold tracking-[0.2em] uppercase text-black mb-4`,children:`Capabilities`}),(0,q.jsx)(`h2`,{className:`text-3xl md:text-5xl font-black tracking-tight text-black`,children:`How It Works`})]}),(0,q.jsx)(`div`,{className:`grid grid-cols-1 md:grid-cols-3 gap-8`,children:t.features.map((e,n)=>(0,q.jsxs)(`div`,{className:`solution-feature-card solution-fade-up solution-delay-${n%3+1} p-8 md:p-10 bg-white border border-zinc-200 flex flex-col`,children:[(0,q.jsx)(`div`,{className:`text-3xl mb-6`,children:t.icon}),(0,q.jsx)(`h3`,{className:`text-xl font-black text-black tracking-tight mb-3 uppercase`,children:e.title}),(0,q.jsx)(`p`,{className:`text-base text-zinc-500 leading-relaxed`,children:e.description})]},n))})]})}),(0,q.jsx)(`section`,{id:`api`,className:`py-20 md:py-28 px-6 bg-zinc-50 border-y border-zinc-100`,children:(0,q.jsx)(`div`,{className:`max-w-5xl mx-auto`,children:(0,q.jsxs)(`div`,{className:`grid grid-cols-1 lg:grid-cols-2 gap-12 items-center`,children:[(0,q.jsxs)(`div`,{className:`space-y-6`,children:[(0,q.jsx)(`div`,{className:`inline-block py-1 px-3 border border-black/10 bg-white text-[10px] font-bold tracking-[0.2em] uppercase text-black`,children:`Integration`}),(0,q.jsxs)(`h2`,{className:`text-3xl md:text-4xl font-black tracking-tight text-black`,children:[`One API Call. `,(0,q.jsx)(`br`,{}),(0,q.jsx)(`span`,{className:`text-zinc-400`,children:`Instant Results.`})]}),(0,q.jsxs)(`p`,{className:`text-lg text-zinc-500 leading-relaxed`,children:[`Integrate `,t.name.toLowerCase(),` detection in minutes. Send text, get a 0–1 confidence score for `,(0,q.jsx)(`strong`,{className:`text-black`,children:t.apiField}),` `,`along with all 12 moderation categories in a single response.`]}),(0,q.jsxs)(`div`,{className:`flex gap-4 pt-2`,children:[(0,q.jsx)(rd,{when:`signed-out`,children:(0,q.jsx)(`span`,{onClickCapture:()=>{n(Lg.INDIRECT_LOGIN,{source:`category_page_api_section`,slug:e})},children:(0,q.jsx)(Ad,{mode:`modal`,children:(0,q.jsx)(Fg,{text:`Get API Key`,variant:Pg.PRIMARY,size:`lg`})})})}),(0,q.jsx)(rd,{when:`signed-in`,children:(0,q.jsx)(Pa,{to:`/api-keys`,onClick:()=>{n(Lg.REDIRECT_TO_DASHBOARD,{source:`category_page`,slug:e})},children:(0,q.jsx)(Fg,{text:`Get API Key`,variant:Pg.PRIMARY,size:`lg`})})})]})]}),(0,q.jsx)(i_,{field:t.apiField,description:t.apiDescription})]})})}),(0,q.jsx)(`section`,{id:`use-cases`,className:`py-20 md:py-28 px-6 bg-white`,children:(0,q.jsxs)(`div`,{className:`max-w-5xl mx-auto`,children:[(0,q.jsxs)(`div`,{className:`text-center mb-16`,children:[(0,q.jsx)(`div`,{className:`inline-block py-1 px-3 border border-black/10 bg-zinc-50 text-[10px] font-bold tracking-[0.2em] uppercase text-black mb-4`,children:`Use Cases`}),(0,q.jsx)(`h2`,{className:`text-3xl md:text-5xl font-black tracking-tight text-black`,children:`Built for Every Platform`})]}),(0,q.jsx)(`div`,{className:`grid grid-cols-1 md:grid-cols-3 gap-8`,children:t.useCases.map((e,t)=>(0,q.jsxs)(`div`,{className:`solution-fade-up solution-delay-${t%3+1} p-8 border border-zinc-200 bg-white hover:border-black transition-colors duration-300`,children:[(0,q.jsx)(`div`,{className:`inline-block py-1.5 px-4 bg-black text-white text-[10px] font-bold tracking-[0.2em] uppercase mb-6`,children:e.industry}),(0,q.jsx)(`p`,{className:`text-base text-zinc-600 leading-relaxed`,children:e.example})]},t))})]})}),(0,q.jsx)(`section`,{id:`related`,className:`py-16 md:py-20 px-6 bg-zinc-50 border-t border-zinc-100`,children:(0,q.jsxs)(`div`,{className:`max-w-6xl mx-auto`,children:[(0,q.jsxs)(`div`,{className:`flex items-center justify-between mb-8`,children:[(0,q.jsx)(`h2`,{className:`text-xl font-black tracking-tight text-black uppercase`,children:`Explore All Solutions`}),(0,q.jsx)(Pa,{to:`/solutions`,className:`text-[10px] font-bold uppercase tracking-[0.2em] text-zinc-400 hover:text-black transition-colors`,children:`View All →`})]}),(0,q.jsx)(`div`,{className:`grid grid-cols-2 sm:grid-cols-3 md:grid-cols-4 gap-4`,children:i.map(e=>(0,q.jsxs)(Pa,{to:`/solutions/${e.slug}`,className:`group p-5 border border-zinc-200 bg-white hover:border-black transition-all duration-300 flex items-center gap-3`,children:[(0,q.jsx)(`span`,{className:`text-2xl`,children:e.icon}),(0,q.jsx)(`span`,{className:`text-sm font-bold text-black group-hover:underline underline-offset-4`,children:e.name})]},e.slug))})]})}),(0,q.jsx)(`section`,{id:`cta`,className:`solution-cta-banner py-20 md:py-28 px-6`,children:(0,q.jsxs)(`div`,{className:`max-w-3xl mx-auto text-center space-y-6 relative z-10`,children:[(0,q.jsx)(`h2`,{className:`text-3xl md:text-5xl font-black tracking-tight`,style:{color:`#ffffff`},children:`Start Moderating in Minutes`}),(0,q.jsxs)(`p`,{className:`text-lg text-zinc-400 max-w-xl mx-auto`,children:[`Get your API key and integrate `,t.name.toLowerCase(),` detection into your platform today. Free tier included.`]}),(0,q.jsxs)(`div`,{className:`flex flex-col sm:flex-row items-center justify-center gap-4 pt-4`,children:[(0,q.jsx)(rd,{when:`signed-out`,children:(0,q.jsx)(`span`,{onClickCapture:()=>{n(Lg.INDIRECT_LOGIN,{source:`category_page_cta`,slug:e})},children:(0,q.jsx)(Ad,{mode:`modal`,children:(0,q.jsx)(`button`,{className:`px-10 py-4 bg-white text-black font-bold text-sm uppercase tracking-widest hover:bg-zinc-100 transition-colors cursor-pointer`,children:`Get Started Free`})})})}),(0,q.jsx)(rd,{when:`signed-in`,children:(0,q.jsx)(Pa,{to:`/api-keys`,onClick:()=>{n(Lg.REDIRECT_TO_DASHBOARD,{source:`category_page`,slug:e})},className:`px-10 py-4 bg-white text-black font-bold text-sm uppercase tracking-widest hover:bg-zinc-100 transition-colors`,children:`Go to Dashboard`})})]})]})})]})},o_=()=>{let e=(0,P.c)(6),t;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(t=(0,q.jsxs)(Ie,{children:[(0,q.jsx)(`title`,{children:`AI Content Moderation Solutions — CautionLabs`}),(0,q.jsx)(`meta`,{name:`description`,content:`Explore CautionLabs' 12 AI-powered content moderation solutions. From toxicity and hate speech to PII detection and minor safety — one API, total coverage.`}),(0,q.jsx)(`meta`,{name:`keywords`,content:`AI content moderation, moderation API, toxicity detection, hate speech filter, PII detection, content safety solutions`}),(0,q.jsx)(`link`,{rel:`canonical`,href:`https://cautionlabs.com/solutions`}),(0,q.jsx)(`meta`,{property:`og:type`,content:`website`}),(0,q.jsx)(`meta`,{property:`og:url`,content:`https://cautionlabs.com/solutions`}),(0,q.jsx)(`meta`,{property:`og:title`,content:`AI Content Moderation Solutions — CautionLabs`}),(0,q.jsx)(`meta`,{property:`og:description`,content:`Explore CautionLabs' 12 AI-powered content moderation solutions. One API, total coverage.`}),(0,q.jsx)(`meta`,{property:`og:image`,content:`https://cdn.cautionlabs.com/transparentlabicon.webp`}),(0,q.jsx)(`meta`,{property:`og:site_name`,content:`CautionLabs`})]}),e[0]=t):t=e[0];let n;e[1]===Symbol.for(`react.memo_cache_sentinel`)?(n=(0,q.jsx)(`div`,{className:`absolute top-0 left-1/2 -translate-x-1/2 w-[1000px] h-[600px] bg-zinc-50 rounded-full blur-[120px] -z-10 opacity-50`}),e[1]=n):n=e[1];let r;e[2]===Symbol.for(`react.memo_cache_sentinel`)?(r=(0,q.jsx)(`div`,{className:`inline-block py-1.5 px-4 border border-black/10 bg-zinc-50 text-[10px] sm:text-xs font-bold tracking-[0.2em] uppercase text-black mb-2`,children:`Solutions`}),e[2]=r):r=e[2];let i;e[3]===Symbol.for(`react.memo_cache_sentinel`)?(i=(0,q.jsxs)(`div`,{className:`max-w-4xl mx-auto space-y-8`,children:[r,(0,q.jsxs)(`h1`,{className:`text-5xl md:text-7xl font-black tracking-tight leading-[1.05] text-black`,children:[`12 Risk Categories. `,(0,q.jsx)(`br`,{}),(0,q.jsx)(`span`,{className:`text-zinc-400`,children:`One API Call.`})]}),(0,q.jsx)(`p`,{className:`text-lg md:text-xl text-zinc-500 max-w-2xl mx-auto font-medium leading-relaxed`,children:`Comprehensive AI-powered content moderation covering every dimension of online safety. Explore each solution below.`})]}),e[3]=i):i=e[3];let a;e[4]===Symbol.for(`react.memo_cache_sentinel`)?(a=(0,q.jsxs)(`section`,{className:`relative py-28 md:py-36 px-6 flex flex-col items-center justify-center text-center bg-white border-b border-zinc-100 overflow-hidden`,children:[n,i,(0,q.jsx)(`div`,{className:`absolute bottom-8 left-1/2 -translate-x-1/2 flex flex-col items-center gap-3`,children:(0,q.jsx)(`div`,{className:`w-[28px] h-[44px] border-2 border-black/10 rounded-full flex justify-center p-2 bg-white/50 backdrop-blur-sm`,children:(0,q.jsx)(`div`,{className:`w-1.5 h-1.5 bg-black rounded-full animate-bounce-slow`})})})]}),e[4]=a):a=e[4];let o;return e[5]===Symbol.for(`react.memo_cache_sentinel`)?(o=(0,q.jsxs)(q.Fragment,{children:[t,a,(0,q.jsx)(`section`,{className:`py-20 md:py-28 px-6 bg-white`,children:(0,q.jsx)(`div`,{className:`max-w-6xl mx-auto`,children:(0,q.jsx)(`div`,{className:`grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-6`,children:n_.map(s_)})})})]}),e[5]=o):o=e[5],o};function s_(e,t){return(0,q.jsxs)(Pa,{to:`/solutions/${e.slug}`,className:`solution-feature-card solution-fade-up solution-delay-${t%3+1} group p-8 md:p-10 border border-zinc-200 bg-white flex flex-col no-underline`,children:[(0,q.jsxs)(`div`,{className:`flex items-center gap-4 mb-6`,children:[(0,q.jsx)(`span`,{className:`text-3xl`,children:e.icon}),(0,q.jsx)(`div`,{className:`w-2 h-2 rounded-full`,style:{backgroundColor:e.color}})]}),(0,q.jsx)(`h2`,{className:`text-xl font-black text-black tracking-tight mb-3 uppercase group-hover:underline underline-offset-8 decoration-1`,children:e.name}),(0,q.jsx)(`p`,{className:`text-sm text-zinc-500 leading-relaxed flex-grow`,children:e.description}),(0,q.jsx)(`div`,{className:`mt-6 text-[10px] font-bold uppercase tracking-[0.2em] text-zinc-400 group-hover:text-black transition-colors`,children:`Learn more →`})]},e.slug)}var c_=()=>{let e=(0,P.c)(1),t;return e[0]===Symbol.for(`react.memo_cache_sentinel`)?(t=(0,q.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:`18`,height:`18`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,q.jsx)(`path`,{d:`M2 12s3-7 10-7 10 7 10 7-3 7-10 7-10-7-10-7Z`}),(0,q.jsx)(`circle`,{cx:`12`,cy:`12`,r:`3`})]}),e[0]=t):t=e[0],t},l_=()=>{let e=(0,P.c)(1),t;return e[0]===Symbol.for(`react.memo_cache_sentinel`)?(t=(0,q.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:`18`,height:`18`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,q.jsx)(`path`,{d:`M9.88 9.88a3 3 0 1 0 4.24 4.24`}),(0,q.jsx)(`path`,{d:`M10.73 5.08A10.43 10.43 0 0 1 12 5c7 0 10 7 10 7a13.16 13.16 0 0 1-1.67 2.68`}),(0,q.jsx)(`path`,{d:`M6.61 6.61A13.52 13.52 0 0 0 2 12s3 7 10 7a9.74 9.74 0 0 0 5.39-1.61`}),(0,q.jsx)(`line`,{x1:`2`,x2:`22`,y1:`2`,y2:`22`})]}),e[0]=t):t=e[0],t},u_=e=>{let t=(0,P.c)(4),n,r;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(n=(0,q.jsx)(`rect`,{width:`14`,height:`14`,x:`8`,y:`8`,rx:`2`,ry:`2`}),r=(0,q.jsx)(`path`,{d:`M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2`}),t[0]=n,t[1]=r):(n=t[0],r=t[1]);let i;return t[2]===e?i=t[3]:(i=(0,q.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:`18`,height:`18`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...e,children:[n,r]}),t[2]=e,t[3]=i),i},d_=e=>{let t=(0,P.c)(3),n;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(n=(0,q.jsx)(`polyline`,{points:`20 6 9 17 4 12`}),t[0]=n):n=t[0];let r;return t[1]===e?r=t[2]:(r=(0,q.jsx)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:`18`,height:`18`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,...e,children:n}),t[1]=e,t[2]=r),r},f_=e=>{let t=(0,P.c)(6),{className:n}=e,r,i,a,o;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(r=(0,q.jsx)(`path`,{d:`M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8`}),i=(0,q.jsx)(`path`,{d:`M21 3v5h-5`}),a=(0,q.jsx)(`path`,{d:`M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16`}),o=(0,q.jsx)(`path`,{d:`M8 16H3v5`}),t[0]=r,t[1]=i,t[2]=a,t[3]=o):(r=t[0],i=t[1],a=t[2],o=t[3]);let s;return t[4]===n?s=t[5]:(s=(0,q.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:`16`,height:`16`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,className:n,children:[r,i,a,o]}),t[4]=n,t[5]=s),s},p_=()=>{let{getApiKey:e,rollApiKey:t}=Vg(),[n,r]=(0,g.useState)(null),[i,a]=(0,g.useState)(!1),[o,s]=(0,g.useState)(!0),[c,l]=(0,g.useState)(!1),[u,d]=(0,g.useState)(!1);return(0,g.useEffect)(()=>{(async()=>{s(!0);try{r((await e()).apiKey)}catch(e){console.error(`Failed to fetch API key:`,e)}finally{s(!1)}})()},[]),(0,q.jsxs)(`div`,{className:`min-h-screen pt-32 pb-24 px-6 relative overflow-hidden bg-white text-black`,children:[(0,q.jsx)(`div`,{className:`absolute top-0 left-1/2 -translate-x-1/2 w-[1000px] h-[600px] bg-zinc-50 rounded-full blur-[120px] -z-10 opacity-60`}),(0,q.jsxs)(`div`,{className:`max-w-3xl mx-auto space-y-12 animate-in fade-in slide-in-from-bottom-8 duration-1000`,children:[(0,q.jsxs)(`div`,{className:`space-y-4`,children:[(0,q.jsx)(`div`,{className:`inline-block py-1 px-3 border border-black/10 bg-zinc-50 text-[10px] font-bold tracking-[0.2em] uppercase text-black`,children:`Developer Console`}),(0,q.jsxs)(`h2`,{className:`text-5xl md:text-6xl font-black tracking-tight leading-tight`,children:[`API Key `,(0,q.jsx)(`br`,{}),(0,q.jsx)(`span`,{className:`text-zinc-400`,children:`Management.`})]}),(0,q.jsx)(`p`,{className:`text-lg text-zinc-500 max-w-xl font-medium leading-relaxed`,children:`Manage your secret keys and authenticate your requests to the CautionLabs API.`})]}),(0,q.jsxs)(`div`,{className:`bg-white border border-zinc-100 p-10 rounded-3xl transition-all duration-500 group relative overflow-hidden`,children:[(0,q.jsx)(`div`,{className:`absolute top-0 left-0 w-1.5 h-full bg-black`}),(0,q.jsxs)(`div`,{className:`flex flex-col gap-10`,children:[(0,q.jsxs)(`div`,{className:`space-y-3`,children:[(0,q.jsxs)(`div`,{className:`flex items-center gap-3`,children:[(0,q.jsx)(`h3`,{className:`text-xl font-bold tracking-tight`,children:`Secret API Key`}),(0,q.jsx)(`span`,{className:`text-[9px] bg-emerald-50 text-emerald-600 border border-emerald-100 px-2.5 py-0.5 rounded-full font-black tracking-widest uppercase`,children:`Active`})]}),(0,q.jsx)(`p`,{className:`text-sm text-zinc-400 max-w-md`,children:`This key grants full access to your content moderation features. Never share it.`})]}),(0,q.jsx)(`div`,{className:`relative group/key`,children:(0,q.jsxs)(`div`,{className:`w-full h-20 bg-zinc-50/50 rounded-2xl flex items-center px-8 gap-6 border border-zinc-200 transition-all duration-500 group-hover/key:border-black group-hover/key:bg-white overflow-hidden`,children:[(0,q.jsx)(`div`,{className:`flex-1 font-mono text-xl tracking-tight overflow-hidden`,children:o?(0,q.jsx)(`span`,{className:`text-zinc-300 animate-pulse`,children:`Initializing...`}):n?(0,q.jsx)(`div`,{className:`flex flex-col gap-1`,children:(0,q.jsx)(`span`,{className:`transition-all duration-500 select-none ${i?`text-black font-bold`:`text-zinc-200 tracking-[0.5em] select-none`}`,children:i?n:`••••••••••••••••••••••••••••••••`})}):(0,q.jsx)(`span`,{className:`text-zinc-400 italic`,children:`No key registered`})}),!o&&n&&(0,q.jsxs)(`div`,{className:`flex items-center gap-1`,children:[(0,q.jsx)(`button`,{onClick:()=>{a(!i)},className:`p-3 rounded-xl text-zinc-400 hover:text-black hover:bg-zinc-100 transition-all duration-300 active:scale-95`,title:i?`Hide Key`:`View Key`,children:i?(0,q.jsx)(l_,{}):(0,q.jsx)(c_,{})}),(0,q.jsx)(`button`,{onClick:()=>{n&&(navigator.clipboard.writeText(n),d(!0),setTimeout(()=>{d(!1)},2e3))},className:`p-3 rounded-xl text-zinc-400 hover:text-black hover:bg-zinc-100 transition-all duration-300 active:scale-95`,title:`Copy to Clipboard`,children:u?(0,q.jsx)(d_,{className:`text-emerald-500`}):(0,q.jsx)(u_,{})})]})]})}),(0,q.jsx)(`div`,{className:`flex items-center pt-2`,children:(0,q.jsx)(Fg,{text:n?`Roll Secret Key`:`Generate Secret Key`,variant:Pg.PRIMARY,leftIcon:(0,q.jsx)(f_,{className:c?`animate-spin`:``}),onPress:async()=>{if(!(n&&!confirm(`Are you sure you want to roll your API key? This action cannot be undone and will break existing integrations.`))){l(!0);try{r((await t()).apiKey),a(!0)}catch(e){console.error(`Failed to roll API key:`,e)}finally{l(!1)}}},size:`lg`,className:`px-12 h-16 text-sm font-black tracking-[0.1em] uppercase rounded-2xl`})})]})]})]})]})},m_=e=>{let t=(0,P.c)(4),{children:n}=e,{isSignedIn:r,isLoaded:i}=iu();if(!i)return null;if(!r){let e;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,q.jsx)(`div`,{className:`inline-block py-1 px-3 bg-zinc-50 text-[10px] font-bold tracking-[0.2em] uppercase text-black`,children:`Access Restricted`}),t[0]=e):e=t[0];let n;return t[1]===Symbol.for(`react.memo_cache_sentinel`)?(n=(0,q.jsx)(`div`,{className:`min-h-screen flex flex-col items-center justify-center p-6 text-center bg-white`,children:(0,q.jsxs)(`div`,{className:`max-w-md space-y-6 animate-in fade-in slide-in-from-bottom-4 duration-1000`,children:[e,(0,q.jsxs)(`h2`,{className:`text-4xl font-black tracking-tight text-black`,children:[`Please sign in to `,(0,q.jsx)(`br`,{}),(0,q.jsx)(`span`,{className:`text-zinc-400`,children:`continue.`})]}),(0,q.jsxs)(`p`,{className:`text-zinc-500 font-medium`,children:[`You need to be authenticated to access this page.`,` `]})]})}),t[1]=n):n=t[1],n}let a;return t[2]===n?a=t[3]:(a=(0,q.jsx)(q.Fragment,{children:n}),t[2]=n,t[3]=a),a},h_=!(typeof navigator>`u`)&&navigator.product===`ReactNative`,g_={timeout:h_?6e4:12e4},__=function(e){let t={...g_,...typeof e==`string`?{url:e}:e};if(t.timeout=y_(t.timeout),t.query){let{url:e,searchParams:n}=function(e){let t=e.indexOf(`?`);if(t===-1)return{url:e,searchParams:new URLSearchParams};let n=e.slice(0,t),r=e.slice(t+1);if(!h_)return{url:n,searchParams:new URLSearchParams(r)};if(typeof decodeURIComponent!=`function`)throw Error("Broken `URLSearchParams` implementation, and `decodeURIComponent` is not defined");let i=new URLSearchParams;for(let e of r.split(`&`)){let[t,n]=e.split(`=`);t&&i.append(v_(t),v_(n||``))}return{url:n,searchParams:i}}(t.url);for(let[r,i]of Object.entries(t.query)){if(i!==void 0)if(Array.isArray(i))for(let e of i)n.append(r,e);else n.append(r,i);let a=n.toString();a&&(t.url=`${e}?${a}`)}}return t.method=t.body&&!t.method?`POST`:(t.method||`GET`).toUpperCase(),t};function v_(e){return decodeURIComponent(e.replace(/\+/g,` `))}function y_(e){if(!1===e||e===0)return!1;if(e.connect||e.socket)return e;let t=Number(e);return isNaN(t)?y_(g_.timeout):{connect:t,socket:t}}var b_=/^https?:\/\//i,x_=function(e){if(!b_.test(e.url))throw Error(`"${e.url}" is not a valid URL`)};function S_(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,`default`)?e.default:e}var C_=[`request`,`response`,`progress`,`error`,`abort`],w_=[`processOptions`,`validateOptions`,`interceptRequest`,`finalizeOptions`,`onRequest`,`onResponse`,`onError`,`onReturn`,`onHeaders`];function T_(e,t){let n=[],r=w_.reduce((e,t)=>(e[t]=e[t]||[],e),{processOptions:[__],validateOptions:[x_]});function i(e){let n=C_.reduce((e,t)=>(e[t]=function(){let e=Object.create(null),t=0;return{publish:function(t){for(let n in e)e[n](t)},subscribe:function(n){let r=t++;return e[r]=n,function(){delete e[r]}}}}(),e),{}),i=(e=>function(t,n,...r){let i=t===`onError`,a=n;for(let n=0;n<e[t].length&&(a=(0,e[t][n])(a,...r),!i||a);n++);return a})(r),a=i(`processOptions`,e);i(`validateOptions`,a);let o={options:a,channels:n,applyMiddleware:i},s,c=n.request.subscribe(e=>{s=t(e,(t,r)=>((e,t,r)=>{let a=e,o=t;if(!a)try{o=i(`onResponse`,t,r)}catch(e){o=null,a=e}a&&=i(`onError`,a,r),a?n.error.publish(a):o&&n.response.publish(o)})(t,r,e))});n.abort.subscribe(()=>{c(),s&&s.abort()});let l=i(`onReturn`,n,o);return l===n&&n.request.publish(o),l}return i.use=function(e){if(!e)throw Error(`Tried to add middleware that resolved to falsey value`);if(typeof e==`function`)throw Error(`Tried to add middleware that was a function. It probably expects you to pass options to it.`);if(e.onReturn&&r.onReturn.length>0)throw Error("Tried to add new middleware with `onReturn` handler, but another handler has already been registered for this event");return w_.forEach(t=>{e[t]&&r[t].push(e[t])}),n.push(e),i},i.clone=()=>T_(n,t),e.forEach(i.use),i}var E_,D_,O_=S_(function(){if(D_)return E_;D_=1;var e=function(e){return e.replace(/^\s+|\s+$/g,``)},t=function(e){return Object.prototype.toString.call(e)===`[object Array]`};return E_=function(n){if(!n)return{};for(var r=Object.create(null),i=e(n).split(`
`),a=0;a<i.length;a++){var o=i[a],s=o.indexOf(`:`),c=e(o.slice(0,s)).toLowerCase(),l=e(o.slice(s+1));typeof r[c]>`u`?r[c]=l:t(r[c])?r[c].push(l):r[c]=[r[c],l]}return r}}()),k_=class{onabort;onerror;onreadystatechange;ontimeout;readyState=0;response;responseText=``;responseType=``;status;statusText;withCredentials;#e;#t;#n;#r={};#i;#a={};#o;open(e,t,n){this.#e=e,this.#t=t,this.#n=``,this.readyState=1,this.onreadystatechange?.(),this.#i=void 0}abort(){this.#i&&this.#i.abort()}getAllResponseHeaders(){return this.#n}setRequestHeader(e,t){this.#r[e]=t}setInit(e,t=!0){this.#a=e,this.#o=t}send(e){let t=this.responseType!==`arraybuffer`,n={...this.#a,method:this.#e,headers:this.#r,body:e};typeof AbortController==`function`&&this.#o&&(this.#i=new AbortController,typeof EventTarget<`u`&&this.#i.signal instanceof EventTarget&&(n.signal=this.#i.signal)),typeof document<`u`&&(n.credentials=this.withCredentials?`include`:`omit`),fetch(this.#t,n).then(e=>(e.headers.forEach((e,t)=>{this.#n+=`${t}: ${e}\r\n`}),this.status=e.status,this.statusText=e.statusText,this.readyState=3,this.onreadystatechange?.(),t?e.text():e.arrayBuffer())).then(e=>{typeof e==`string`?this.responseText=e:this.response=e,this.readyState=4,this.onreadystatechange?.()}).catch(e=>{e.name===`AbortError`?this.onabort?.():this.onerror?.(e)})}},A_=typeof XMLHttpRequest==`function`?`xhr`:`fetch`,j_=A_===`xhr`?XMLHttpRequest:k_,M_=(e,t)=>{let n=e.options,r=e.applyMiddleware(`finalizeOptions`,n),i={},a=e.applyMiddleware(`interceptRequest`,void 0,{adapter:A_,context:e});if(a){let e=setTimeout(t,0,null,a);return{abort:()=>clearTimeout(e)}}let o=new j_;o instanceof k_&&typeof r.fetch==`object`&&o.setInit(r.fetch,r.useAbortSignal??!0);let s=r.headers,c=r.timeout,l=!1,u=!1,d=!1;if(o.onerror=e=>{m(o instanceof k_?e instanceof Error?e:Error(`Request error while attempting to reach is ${r.url}`,{cause:e}):Error(`Request error while attempting to reach is ${r.url}${e.lengthComputable?`(${e.loaded} of ${e.total} bytes transferred)`:``}`))},o.ontimeout=e=>{m(Error(`Request timeout while attempting to reach ${r.url}${e.lengthComputable?`(${e.loaded} of ${e.total} bytes transferred)`:``}`))},o.onabort=()=>{p(!0),l=!0},o.onreadystatechange=function(){c&&(p(),i.socket=setTimeout(()=>f(`ESOCKETTIMEDOUT`),c.socket)),!l&&o&&o.readyState===4&&o.status!==0&&function(){if(!(l||u||d)){if(o.status===0)return void m(Error(`Unknown XHR error`));p(),u=!0,t(null,{body:o.response||(o.responseType===``||o.responseType===`text`?o.responseText:``),url:r.url,method:r.method,headers:O_(o.getAllResponseHeaders()),statusCode:o.status,statusMessage:o.statusText})}}()},o.open(r.method,r.url,!0),o.withCredentials=!!r.withCredentials,s&&o.setRequestHeader)for(let e in s)s.hasOwnProperty(e)&&o.setRequestHeader(e,s[e]);return r.rawBody&&(o.responseType=`arraybuffer`),e.applyMiddleware(`onRequest`,{options:r,adapter:A_,request:o,context:e}),o.send(r.body||null),c&&(i.connect=setTimeout(()=>f(`ETIMEDOUT`),c.connect)),{abort:function(){l=!0,o&&o.abort()}};function f(t){d=!0,o.abort();let n=Error(t===`ESOCKETTIMEDOUT`?`Socket timed out on request to ${r.url}`:`Connection timed out on request to ${r.url}`);n.code=t,e.channels.error.publish(n)}function p(e){(e||l||o&&o.readyState>=2&&i.connect)&&clearTimeout(i.connect),i.socket&&clearTimeout(i.socket)}function m(e){if(u)return;p(!0),u=!0,o=null;let n=e||Error(`Network error while attempting to reach ${r.url}`);n.isNetworkError=!0,n.request=r,t(n)}},N_=(e=[],t=M_)=>T_(e,t);function P_(e){return{}}var F_,I_,L_,R_,z_,B_={exports:{}};z_||(z_=1,function(e,t){t.formatArgs=function(t){if(t[0]=(this.useColors?`%c`:``)+this.namespace+(this.useColors?` %c`:` `)+t[0]+(this.useColors?`%c `:` `)+`+`+e.exports.humanize(this.diff),!this.useColors)return;let n=`color: `+this.color;t.splice(1,0,n,`color: inherit`);let r=0,i=0;t[0].replace(/%[a-zA-Z%]/g,e=>{e!==`%%`&&(r++,e===`%c`&&(i=r))}),t.splice(i,0,n)},t.save=function(e){try{e?t.storage.setItem(`debug`,e):t.storage.removeItem(`debug`)}catch{}},t.load=function(){let e;try{e=t.storage.getItem(`debug`)||t.storage.getItem(`DEBUG`)}catch{}return!e&&typeof process<`u`&&`env`in process&&(e={}.DEBUG),e},t.useColors=function(){if(typeof window<`u`&&window.process&&(window.process.type===`renderer`||window.process.__nwjs))return!0;if(typeof navigator<`u`&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;let e;return typeof document<`u`&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window<`u`&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator<`u`&&navigator.userAgent&&(e=navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/))&&parseInt(e[1],10)>=31||typeof navigator<`u`&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage=function(){try{return localStorage}catch{}}(),t.destroy=(()=>{let e=!1;return()=>{e||(e=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})(),t.colors=`#0000CC.#0000FF.#0033CC.#0033FF.#0066CC.#0066FF.#0099CC.#0099FF.#00CC00.#00CC33.#00CC66.#00CC99.#00CCCC.#00CCFF.#3300CC.#3300FF.#3333CC.#3333FF.#3366CC.#3366FF.#3399CC.#3399FF.#33CC00.#33CC33.#33CC66.#33CC99.#33CCCC.#33CCFF.#6600CC.#6600FF.#6633CC.#6633FF.#66CC00.#66CC33.#9900CC.#9900FF.#9933CC.#9933FF.#99CC00.#99CC33.#CC0000.#CC0033.#CC0066.#CC0099.#CC00CC.#CC00FF.#CC3300.#CC3333.#CC3366.#CC3399.#CC33CC.#CC33FF.#CC6600.#CC6633.#CC9900.#CC9933.#CCCC00.#CCCC33.#FF0000.#FF0033.#FF0066.#FF0099.#FF00CC.#FF00FF.#FF3300.#FF3333.#FF3366.#FF3399.#FF33CC.#FF33FF.#FF6600.#FF6633.#FF9900.#FF9933.#FFCC00.#FFCC33`.split(`.`),t.log=console.debug||console.log||(()=>{}),e.exports=(R_?L_:(R_=1,L_=function(e){function t(e){let r,i,a,o=null;function s(...e){if(!s.enabled)return;let n=s,i=Number(new Date);n.diff=i-(r||i),n.prev=r,n.curr=i,r=i,e[0]=t.coerce(e[0]),typeof e[0]!=`string`&&e.unshift(`%O`);let a=0;e[0]=e[0].replace(/%([a-zA-Z%])/g,(r,i)=>{if(r===`%%`)return`%`;a++;let o=t.formatters[i];if(typeof o==`function`){let t=e[a];r=o.call(n,t),e.splice(a,1),a--}return r}),t.formatArgs.call(n,e),(n.log||t.log).apply(n,e)}return s.namespace=e,s.useColors=t.useColors(),s.color=t.selectColor(e),s.extend=n,s.destroy=t.destroy,Object.defineProperty(s,`enabled`,{enumerable:!0,configurable:!1,get:()=>o===null?(i!==t.namespaces&&(i=t.namespaces,a=t.enabled(e)),a):o,set:e=>{o=e}}),typeof t.init==`function`&&t.init(s),s}function n(e,n){let r=t(this.namespace+(typeof n>`u`?`:`:n)+e);return r.log=this.log,r}function r(e,t){let n=0,r=0,i=-1,a=0;for(;n<e.length;)if(r<t.length&&(t[r]===e[n]||t[r]===`*`))t[r]===`*`?(i=r,a=n,r++):(n++,r++);else{if(i===-1)return!1;r=i+1,a++,n=a}for(;r<t.length&&t[r]===`*`;)r++;return r===t.length}return t.debug=t,t.default=t,t.coerce=function(e){return e instanceof Error?e.stack||e.message:e},t.disable=function(){let e=[...t.names,...t.skips.map(e=>`-`+e)].join(`,`);return t.enable(``),e},t.enable=function(e){t.save(e),t.namespaces=e,t.names=[],t.skips=[];let n=(typeof e==`string`?e:``).trim().replace(/\s+/g,`,`).split(`,`).filter(Boolean);for(let e of n)e[0]===`-`?t.skips.push(e.slice(1)):t.names.push(e)},t.enabled=function(e){for(let n of t.skips)if(r(e,n))return!1;for(let n of t.names)if(r(e,n))return!0;return!1},t.humanize=function(){if(I_)return F_;I_=1;var e=1e3,t=60*e,n=60*t,r=24*n,i=7*r;function a(e,t,n,r){var i=t>=1.5*n;return Math.round(e/n)+` `+r+(i?`s`:``)}return F_=function(o,s){s||={};var c,l,u=typeof o;if(u===`string`&&o.length>0)return function(a){if(!((a=String(a)).length>100)){var o=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(a);if(o){var s=parseFloat(o[1]);switch((o[2]||`ms`).toLowerCase()){case`years`:case`year`:case`yrs`:case`yr`:case`y`:return 315576e5*s;case`weeks`:case`week`:case`w`:return s*i;case`days`:case`day`:case`d`:return s*r;case`hours`:case`hour`:case`hrs`:case`hr`:case`h`:return s*n;case`minutes`:case`minute`:case`mins`:case`min`:case`m`:return s*t;case`seconds`:case`second`:case`secs`:case`sec`:case`s`:return s*e;case`milliseconds`:case`millisecond`:case`msecs`:case`msec`:case`ms`:return s;default:return}}}}(o);if(u===`number`&&isFinite(o))return s.long?(c=o,(l=Math.abs(c))>=r?a(c,l,r,`day`):l>=n?a(c,l,n,`hour`):l>=t?a(c,l,t,`minute`):l>=e?a(c,l,e,`second`):c+` ms`):function(i){var a=Math.abs(i);return a>=r?Math.round(i/r)+`d`:a>=n?Math.round(i/n)+`h`:a>=t?Math.round(i/t)+`m`:a>=e?Math.round(i/e)+`s`:i+`ms`}(o);throw Error(`val is not a non-empty string or a valid number. val=`+JSON.stringify(o))}}(),t.destroy=function(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")},Object.keys(e).forEach(n=>{t[n]=e[n]}),t.names=[],t.skips=[],t.formatters={},t.selectColor=function(e){let n=0;for(let t=0;t<e.length;t++)n=(n<<5)-n+e.charCodeAt(t),n|=0;return t.colors[Math.abs(n)%t.colors.length]},t.enable(t.load()),t}))(t);let{formatters:n}=e.exports;n.j=function(e){try{return JSON.stringify(e)}catch(e){return`[UnexpectedJSONParseError]: `+e.message}}}(B_,B_.exports)),B_.exports;var V_=typeof Buffer>`u`?()=>!1:e=>Buffer.isBuffer(e);function H_(e){return Object.prototype.toString.call(e)===`[object Object]`}function U_(e){if(!1===H_(e))return!1;let t=e.constructor;if(t===void 0)return!0;let n=t.prototype;return!(!1===H_(n)||!1===n.hasOwnProperty(`isPrototypeOf`))}var W_=[`boolean`,`string`,`number`];function G_(){return{processOptions:e=>{let t=e.body;return!t||typeof t.pipe==`function`||V_(t)||W_.indexOf(typeof t)===-1&&!Array.isArray(t)&&!U_(t)?e:Object.assign({},e,{body:JSON.stringify(e.body),headers:Object.assign({},e.headers,{"Content-Type":`application/json`})})}}}function K_(e){return{onResponse:n=>{let r=n.headers[`content-type`]||``,i=e&&e.force||r.indexOf(`application/json`)!==-1;return n.body&&r&&i?Object.assign({},n,{body:t(n.body)}):n},processOptions:e=>Object.assign({},e,{headers:Object.assign({Accept:`application/json`},e.headers)})};function t(e){try{return JSON.parse(e)}catch(e){throw e.message=`Failed to parsed response body as JSON: ${e.message}`,e}}}var q_={};typeof globalThis<`u`?q_=globalThis:typeof window<`u`?q_=window:typeof global<`u`?q_=global:typeof self<`u`&&(q_=self);var J_=q_;function Y_(e={}){let t=e.implementation||J_.Observable;if(!t)throw Error("`Observable` is not available in global scope, and no implementation was passed");return{onReturn:(e,n)=>new t(t=>(e.error.subscribe(e=>t.error(e)),e.progress.subscribe(e=>t.next(Object.assign({type:`progress`},e))),e.response.subscribe(e=>{t.next(Object.assign({type:`response`},e)),t.complete()}),e.request.publish(n),()=>e.abort.publish()))}}function X_(){return{onRequest:e=>{if(e.adapter!==`xhr`)return;let t=e.request,n=e.context;function r(e){return t=>{let r=t.lengthComputable?t.loaded/t.total*100:-1;n.channels.progress.publish({stage:e,percent:r,total:t.total,loaded:t.loaded,lengthComputable:t.lengthComputable})}}`upload`in t&&`onprogress`in t.upload&&(t.upload.onprogress=r(`upload`)),`onprogress`in t&&(t.onprogress=r(`download`))}}}var Z_=(e={})=>{let t=e.implementation||Promise;if(!t)throw Error("`Promise` is not available in global scope, and no implementation was passed");return{onReturn:(n,r)=>new t((t,i)=>{let a=r.options.cancelToken;a&&a.promise.then(e=>{n.abort.publish(e),i(e)}),n.error.subscribe(i),n.response.subscribe(n=>{t(e.onlyBody?n.body:n)}),setTimeout(()=>{try{n.request.publish(r)}catch(e){i(e)}},0)})}},Q_=class{__CANCEL__=!0;message;constructor(e){this.message=e}toString(){return`Cancel`+(this.message?`: ${this.message}`:``)}},$_=class e{promise;reason;constructor(e){if(typeof e!=`function`)throw TypeError(`executor must be a function.`);let t=null;this.promise=new Promise(e=>{t=e}),e(e=>{this.reason||(this.reason=new Q_(e),t(this.reason))})}static source=()=>{let t;return{token:new e(e=>{t=e}),cancel:t}}};Z_.Cancel=Q_,Z_.CancelToken=$_,Z_.isCancel=e=>!(!e||!e?.__CANCEL__);var ev=(e,t,n)=>(n.method===`GET`||n.method===`HEAD`)&&(e.isNetworkError||!1);function tv(e){return 100*2**e+100*Math.random()}var nv=(e={})=>(e=>{let t=e.maxRetries||5,n=e.retryDelay||tv,r=e.shouldRetry;return{onError:(e,i)=>{let a=i.options,o=a.maxRetries||t,s=a.retryDelay||n,c=a.shouldRetry||r,l=a.attemptNumber||0;if((u=a.body)!==null&&typeof u==`object`&&typeof u.pipe==`function`||!c(e,l,a)||l>=o)return e;var u;let d=Object.assign({},i,{options:Object.assign({},a,{attemptNumber:l+1})});return setTimeout(()=>i.channels.request.publish(d),s(l)),null}}})({shouldRetry:ev,...e});nv.shouldRetry=ev,rv=P_;var rv;function iv(e){return typeof e==`function`}function av(e){var t=e(function(e){Error.call(e),e.stack=Error().stack});return t.prototype=Object.create(Error.prototype),t.prototype.constructor=t,t}var ov=av(function(e){return function(t){e(this),this.message=t?t.length+` errors occurred during unsubscription:
`+t.map(function(e,t){return t+1+`) `+e.toString()}).join(`
  `):``,this.name=`UnsubscriptionError`,this.errors=t}});function sv(e,t){if(e){var n=e.indexOf(t);0<=n&&e.splice(n,1)}}var cv=function(){function e(e){this.initialTeardown=e,this.closed=!1,this._parentage=null,this._finalizers=null}return e.prototype.unsubscribe=function(){var e,t,n,r,i;if(!this.closed){this.closed=!0;var a=this._parentage;if(a)if(this._parentage=null,Array.isArray(a))try{for(var o=Og(a),s=o.next();!s.done;s=o.next())s.value.remove(this)}catch(t){e={error:t}}finally{try{s&&!s.done&&(t=o.return)&&t.call(o)}finally{if(e)throw e.error}}else a.remove(this);var c=this.initialTeardown;if(iv(c))try{c()}catch(e){i=e instanceof ov?e.errors:[e]}var l=this._finalizers;if(l){this._finalizers=null;try{for(var u=Og(l),d=u.next();!d.done;d=u.next()){var f=d.value;try{dv(f)}catch(e){i??=[],e instanceof ov?i=Ag(Ag([],kg(i)),kg(e.errors)):i.push(e)}}}catch(e){n={error:e}}finally{try{d&&!d.done&&(r=u.return)&&r.call(u)}finally{if(n)throw n.error}}}if(i)throw new ov(i)}},e.prototype.add=function(t){if(t&&t!==this)if(this.closed)dv(t);else{if(t instanceof e){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=this._finalizers??[]).push(t)}},e.prototype._hasParent=function(e){var t=this._parentage;return t===e||Array.isArray(t)&&t.includes(e)},e.prototype._addParent=function(e){var t=this._parentage;this._parentage=Array.isArray(t)?(t.push(e),t):t?[t,e]:e},e.prototype._removeParent=function(e){var t=this._parentage;t===e?this._parentage=null:Array.isArray(t)&&sv(t,e)},e.prototype.remove=function(t){var n=this._finalizers;n&&sv(n,t),t instanceof e&&t._removeParent(this)},e.EMPTY=(function(){var t=new e;return t.closed=!0,t})(),e}(),lv=cv.EMPTY;function uv(e){return e instanceof cv||e&&`closed`in e&&iv(e.remove)&&iv(e.add)&&iv(e.unsubscribe)}function dv(e){iv(e)?e():e.unsubscribe()}var fv={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},pv={setTimeout:function(e,t){var n=[...arguments].slice(2),r=pv.delegate;return r?.setTimeout?r.setTimeout.apply(r,Ag([e,t],kg(n))):setTimeout.apply(void 0,Ag([e,t],kg(n)))},clearTimeout:function(e){return(pv.delegate?.clearTimeout||clearTimeout)(e)},delegate:void 0};function mv(e){pv.setTimeout(function(){var t=fv.onUnhandledError;if(t)t(e);else throw e})}function hv(){}var gv=(function(){return yv(`C`,void 0,void 0)})();function _v(e){return yv(`E`,void 0,e)}function vv(e){return yv(`N`,e,void 0)}function yv(e,t,n){return{kind:e,value:t,error:n}}var bv=null;function xv(e){if(fv.useDeprecatedSynchronousErrorHandling){var t=!bv;if(t&&(bv={errorThrown:!1,error:null}),e(),t){var n=bv,r=n.errorThrown,i=n.error;if(bv=null,r)throw i}}else e()}function Sv(e){fv.useDeprecatedSynchronousErrorHandling&&bv&&(bv.errorThrown=!0,bv.error=e)}var Cv=function(e){Tg(t,e);function t(t){var n=e.call(this)||this;return n.isStopped=!1,t?(n.destination=t,uv(t)&&t.add(n)):n.destination=jv,n}return t.create=function(e,t,n){return new Dv(e,t,n)},t.prototype.next=function(e){this.isStopped?Av(vv(e),this):this._next(e)},t.prototype.error=function(e){this.isStopped?Av(_v(e),this):(this.isStopped=!0,this._error(e))},t.prototype.complete=function(){this.isStopped?Av(gv,this):(this.isStopped=!0,this._complete())},t.prototype.unsubscribe=function(){this.closed||(this.isStopped=!0,e.prototype.unsubscribe.call(this),this.destination=null)},t.prototype._next=function(e){this.destination.next(e)},t.prototype._error=function(e){try{this.destination.error(e)}finally{this.unsubscribe()}},t.prototype._complete=function(){try{this.destination.complete()}finally{this.unsubscribe()}},t}(cv),wv=Function.prototype.bind;function Tv(e,t){return wv.call(e,t)}var Ev=function(){function e(e){this.partialObserver=e}return e.prototype.next=function(e){var t=this.partialObserver;if(t.next)try{t.next(e)}catch(e){Ov(e)}},e.prototype.error=function(e){var t=this.partialObserver;if(t.error)try{t.error(e)}catch(e){Ov(e)}else Ov(e)},e.prototype.complete=function(){var e=this.partialObserver;if(e.complete)try{e.complete()}catch(e){Ov(e)}},e}(),Dv=function(e){Tg(t,e);function t(t,n,r){var i=e.call(this)||this,a;if(iv(t)||!t)a={next:t??void 0,error:n??void 0,complete:r??void 0};else{var o;i&&fv.useDeprecatedNextContext?(o=Object.create(t),o.unsubscribe=function(){return i.unsubscribe()},a={next:t.next&&Tv(t.next,o),error:t.error&&Tv(t.error,o),complete:t.complete&&Tv(t.complete,o)}):a=t}return i.destination=new Ev(a),i}return t}(Cv);function Ov(e){fv.useDeprecatedSynchronousErrorHandling?Sv(e):mv(e)}function kv(e){throw e}function Av(e,t){var n=fv.onStoppedNotification;n&&pv.setTimeout(function(){return n(e,t)})}var jv={closed:!0,next:hv,error:kv,complete:hv},Mv=(function(){return typeof Symbol==`function`&&Symbol.observable||`@@observable`})();function Nv(e){return e}function Pv(){return Fv([...arguments])}function Fv(e){return e.length===0?Nv:e.length===1?e[0]:function(t){return e.reduce(function(e,t){return t(e)},t)}}var Iv=function(){function e(e){e&&(this._subscribe=e)}return e.prototype.lift=function(t){var n=new e;return n.source=this,n.operator=t,n},e.prototype.subscribe=function(e,t,n){var r=this,i=zv(e)?e:new Dv(e,t,n);return xv(function(){var e=r,t=e.operator,n=e.source;i.add(t?t.call(i,n):n?r._subscribe(i):r._trySubscribe(i))}),i},e.prototype._trySubscribe=function(e){try{return this._subscribe(e)}catch(t){e.error(t)}},e.prototype.forEach=function(e,t){var n=this;return t=Lv(t),new t(function(t,r){var i=new Dv({next:function(t){try{e(t)}catch(e){r(e),i.unsubscribe()}},error:r,complete:t});n.subscribe(i)})},e.prototype._subscribe=function(e){return this.source?.subscribe(e)},e.prototype[Mv]=function(){return this},e.prototype.pipe=function(){return Fv([...arguments])(this)},e.prototype.toPromise=function(e){var t=this;return e=Lv(e),new e(function(e,n){var r;t.subscribe(function(e){return r=e},function(e){return n(e)},function(){return e(r)})})},e.create=function(t){return new e(t)},e}();function Lv(e){return e??fv.Promise??Promise}function Rv(e){return e&&iv(e.next)&&iv(e.error)&&iv(e.complete)}function zv(e){return e&&e instanceof Cv||Rv(e)&&uv(e)}function Bv(e){return iv(e?.lift)}function Vv(e){return function(t){if(Bv(t))return t.lift(function(t){try{return e(t,this)}catch(e){this.error(e)}});throw TypeError(`Unable to lift unknown Observable type`)}}function Hv(e,t,n,r,i){return new Uv(e,t,n,r,i)}var Uv=function(e){Tg(t,e);function t(t,n,r,i,a,o){var s=e.call(this,t)||this;return s.onFinalize=a,s.shouldUnsubscribe=o,s._next=n?function(e){try{n(e)}catch(e){t.error(e)}}:e.prototype._next,s._error=i?function(e){try{i(e)}catch(e){t.error(e)}finally{this.unsubscribe()}}:e.prototype._error,s._complete=r?function(){try{r()}catch(e){t.error(e)}finally{this.unsubscribe()}}:e.prototype._complete,s}return t.prototype.unsubscribe=function(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){var n=this.closed;e.prototype.unsubscribe.call(this),!n&&((t=this.onFinalize)==null||t.call(this))}},t}(Cv),Wv=av(function(e){return function(){e(this),this.name=`ObjectUnsubscribedError`,this.message=`object unsubscribed`}}),Gv=function(e){Tg(t,e);function t(){var t=e.call(this)||this;return t.closed=!1,t.currentObservers=null,t.observers=[],t.isStopped=!1,t.hasError=!1,t.thrownError=null,t}return t.prototype.lift=function(e){var t=new Kv(this,this);return t.operator=e,t},t.prototype._throwIfClosed=function(){if(this.closed)throw new Wv},t.prototype.next=function(e){var t=this;xv(function(){var n,r;if(t._throwIfClosed(),!t.isStopped){t.currentObservers||=Array.from(t.observers);try{for(var i=Og(t.currentObservers),a=i.next();!a.done;a=i.next())a.value.next(e)}catch(e){n={error:e}}finally{try{a&&!a.done&&(r=i.return)&&r.call(i)}finally{if(n)throw n.error}}}})},t.prototype.error=function(e){var t=this;xv(function(){if(t._throwIfClosed(),!t.isStopped){t.hasError=t.isStopped=!0,t.thrownError=e;for(var n=t.observers;n.length;)n.shift().error(e)}})},t.prototype.complete=function(){var e=this;xv(function(){if(e._throwIfClosed(),!e.isStopped){e.isStopped=!0;for(var t=e.observers;t.length;)t.shift().complete()}})},t.prototype.unsubscribe=function(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null},Object.defineProperty(t.prototype,`observed`,{get:function(){return this.observers?.length>0},enumerable:!1,configurable:!0}),t.prototype._trySubscribe=function(t){return this._throwIfClosed(),e.prototype._trySubscribe.call(this,t)},t.prototype._subscribe=function(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)},t.prototype._innerSubscribe=function(e){var t=this,n=this,r=n.hasError,i=n.isStopped,a=n.observers;return r||i?lv:(this.currentObservers=null,a.push(e),new cv(function(){t.currentObservers=null,sv(a,e)}))},t.prototype._checkFinalizedStatuses=function(e){var t=this,n=t.hasError,r=t.thrownError,i=t.isStopped;n?e.error(r):i&&e.complete()},t.prototype.asObservable=function(){var e=new Iv;return e.source=this,e},t.create=function(e,t){return new Kv(e,t)},t}(Iv),Kv=function(e){Tg(t,e);function t(t,n){var r=e.call(this)||this;return r.destination=t,r.source=n,r}return t.prototype.next=function(e){var t,n;(n=(t=this.destination)?.next)==null||n.call(t,e)},t.prototype.error=function(e){var t,n;(n=(t=this.destination)?.error)==null||n.call(t,e)},t.prototype.complete=function(){var e,t;(t=(e=this.destination)?.complete)==null||t.call(e)},t.prototype._subscribe=function(e){return this.source?.subscribe(e)??lv},t}(Gv),qv={now:function(){return(qv.delegate||Date).now()},delegate:void 0},Jv=function(e){Tg(t,e);function t(t,n,r){t===void 0&&(t=1/0),n===void 0&&(n=1/0),r===void 0&&(r=qv);var i=e.call(this)||this;return i._bufferSize=t,i._windowTime=n,i._timestampProvider=r,i._buffer=[],i._infiniteTimeWindow=!0,i._infiniteTimeWindow=n===1/0,i._bufferSize=Math.max(1,t),i._windowTime=Math.max(1,n),i}return t.prototype.next=function(t){var n=this,r=n.isStopped,i=n._buffer,a=n._infiniteTimeWindow,o=n._timestampProvider,s=n._windowTime;r||(i.push(t),!a&&i.push(o.now()+s)),this._trimBuffer(),e.prototype.next.call(this,t)},t.prototype._subscribe=function(e){this._throwIfClosed(),this._trimBuffer();for(var t=this._innerSubscribe(e),n=this,r=n._infiniteTimeWindow,i=n._buffer.slice(),a=0;a<i.length&&!e.closed;a+=r?1:2)e.next(i[a]);return this._checkFinalizedStatuses(e),t},t.prototype._trimBuffer=function(){var e=this,t=e._bufferSize,n=e._timestampProvider,r=e._buffer,i=e._infiniteTimeWindow,a=(i?1:2)*t;if(t<1/0&&a<r.length&&r.splice(0,r.length-a),!i){for(var o=n.now(),s=0,c=1;c<r.length&&r[c]<=o;c+=2)s=c;s&&r.splice(0,s+1)}},t}(Gv),Yv=function(e){Tg(t,e);function t(t,n){return e.call(this)||this}return t.prototype.schedule=function(e,t){return t===void 0&&(t=0),this},t}(cv),Xv={setInterval:function(e,t){var n=[...arguments].slice(2),r=Xv.delegate;return r?.setInterval?r.setInterval.apply(r,Ag([e,t],kg(n))):setInterval.apply(void 0,Ag([e,t],kg(n)))},clearInterval:function(e){return(Xv.delegate?.clearInterval||clearInterval)(e)},delegate:void 0},Zv=function(e){Tg(t,e);function t(t,n){var r=e.call(this,t,n)||this;return r.scheduler=t,r.work=n,r.pending=!1,r}return t.prototype.schedule=function(e,t){if(t===void 0&&(t=0),this.closed)return this;this.state=e;var n=this.id,r=this.scheduler;return n!=null&&(this.id=this.recycleAsyncId(r,n,t)),this.pending=!0,this.delay=t,this.id=this.id??this.requestAsyncId(r,this.id,t),this},t.prototype.requestAsyncId=function(e,t,n){return n===void 0&&(n=0),Xv.setInterval(e.flush.bind(e,this),n)},t.prototype.recycleAsyncId=function(e,t,n){if(n===void 0&&(n=0),n!=null&&this.delay===n&&this.pending===!1)return t;t!=null&&Xv.clearInterval(t)},t.prototype.execute=function(e,t){if(this.closed)return Error(`executing a cancelled action`);this.pending=!1;var n=this._execute(e,t);if(n)return n;this.pending===!1&&this.id!=null&&(this.id=this.recycleAsyncId(this.scheduler,this.id,null))},t.prototype._execute=function(e,t){var n=!1,r;try{this.work(e)}catch(e){n=!0,r=e||Error(`Scheduled action threw falsy error`)}if(n)return this.unsubscribe(),r},t.prototype.unsubscribe=function(){if(!this.closed){var t=this,n=t.id,r=t.scheduler,i=r.actions;this.work=this.state=this.scheduler=null,this.pending=!1,sv(i,this),n!=null&&(this.id=this.recycleAsyncId(r,n,null)),this.delay=null,e.prototype.unsubscribe.call(this)}},t}(Yv),Qv=function(){function e(t,n){n===void 0&&(n=e.now),this.schedulerActionCtor=t,this.now=n}return e.prototype.schedule=function(e,t,n){return t===void 0&&(t=0),new this.schedulerActionCtor(this,e).schedule(n,t)},e.now=qv.now,e}(),$v=new(function(e){Tg(t,e);function t(t,n){n===void 0&&(n=Qv.now);var r=e.call(this,t,n)||this;return r.actions=[],r._active=!1,r}return t.prototype.flush=function(e){var t=this.actions;if(this._active){t.push(e);return}var n;this._active=!0;do if(n=e.execute(e.state,e.delay))break;while(e=t.shift());if(this._active=!1,n){for(;e=t.shift();)e.unsubscribe();throw n}},t}(Qv))(Zv),ey=new Iv(function(e){return e.complete()});function ty(e){return e&&iv(e.schedule)}function ny(e){return e[e.length-1]}function ry(e){return iv(ny(e))?e.pop():void 0}function iy(e){return ty(ny(e))?e.pop():void 0}function ay(e,t){return typeof ny(e)==`number`?e.pop():t}var oy=(function(e){return e&&typeof e.length==`number`&&typeof e!=`function`});function sy(e){return iv(e?.then)}function cy(e){return iv(e[Mv])}function ly(e){return Symbol.asyncIterator&&iv(e?.[Symbol.asyncIterator])}function uy(e){return TypeError(`You provided `+(typeof e==`object`&&e?`an invalid object`:`'`+e+`'`)+` where a stream was expected. You can provide an Observable, Promise, ReadableStream, Array, AsyncIterable, or Iterable.`)}function dy(){return typeof Symbol!=`function`||!Symbol.iterator?`@@iterator`:Symbol.iterator}var fy=dy();function py(e){return iv(e?.[fy])}function my(e){return Mg(this,arguments,function(){var t,n,r,i;return Dg(this,function(a){switch(a.label){case 0:t=e.getReader(),a.label=1;case 1:a.trys.push([1,,9,10]),a.label=2;case 2:return[4,jg(t.read())];case 3:return n=a.sent(),r=n.value,i=n.done,i?[4,jg(void 0)]:[3,5];case 4:return[2,a.sent()];case 5:return[4,jg(r)];case 6:return[4,a.sent()];case 7:return a.sent(),[3,2];case 8:return[3,10];case 9:return t.releaseLock(),[7];case 10:return[2]}})})}function hy(e){return iv(e?.getReader)}function gy(e){if(e instanceof Iv)return e;if(e!=null){if(cy(e))return _y(e);if(oy(e))return vy(e);if(sy(e))return yy(e);if(ly(e))return xy(e);if(py(e))return by(e);if(hy(e))return Sy(e)}throw uy(e)}function _y(e){return new Iv(function(t){var n=e[Mv]();if(iv(n.subscribe))return n.subscribe(t);throw TypeError(`Provided object does not correctly implement Symbol.observable`)})}function vy(e){return new Iv(function(t){for(var n=0;n<e.length&&!t.closed;n++)t.next(e[n]);t.complete()})}function yy(e){return new Iv(function(t){e.then(function(e){t.closed||(t.next(e),t.complete())},function(e){return t.error(e)}).then(null,mv)})}function by(e){return new Iv(function(t){var n,r;try{for(var i=Og(e),a=i.next();!a.done;a=i.next()){var o=a.value;if(t.next(o),t.closed)return}}catch(e){n={error:e}}finally{try{a&&!a.done&&(r=i.return)&&r.call(i)}finally{if(n)throw n.error}}t.complete()})}function xy(e){return new Iv(function(t){Cy(e,t).catch(function(e){return t.error(e)})})}function Sy(e){return xy(my(e))}function Cy(e,t){var n,r,i,a;return Eg(this,void 0,void 0,function(){var o,s;return Dg(this,function(c){switch(c.label){case 0:c.trys.push([0,5,6,11]),n=Ng(e),c.label=1;case 1:return[4,n.next()];case 2:if(r=c.sent(),r.done)return[3,4];if(o=r.value,t.next(o),t.closed)return[2];c.label=3;case 3:return[3,1];case 4:return[3,11];case 5:return s=c.sent(),i={error:s},[3,11];case 6:return c.trys.push([6,,9,10]),r&&!r.done&&(a=n.return)?[4,a.call(n)]:[3,8];case 7:c.sent(),c.label=8;case 8:return[3,10];case 9:if(i)throw i.error;return[7];case 10:return[7];case 11:return t.complete(),[2]}})})}function wy(e,t,n,r,i){r===void 0&&(r=0),i===void 0&&(i=!1);var a=t.schedule(function(){n(),i?e.add(this.schedule(null,r)):this.unsubscribe()},r);if(e.add(a),!i)return a}function Ty(e,t){return t===void 0&&(t=0),Vv(function(n,r){n.subscribe(Hv(r,function(n){return wy(r,e,function(){return r.next(n)},t)},function(){return wy(r,e,function(){return r.complete()},t)},function(n){return wy(r,e,function(){return r.error(n)},t)}))})}function Ey(e,t){return t===void 0&&(t=0),Vv(function(n,r){r.add(e.schedule(function(){return n.subscribe(r)},t))})}function Dy(e,t){return gy(e).pipe(Ey(t),Ty(t))}function Oy(e,t){return gy(e).pipe(Ey(t),Ty(t))}function ky(e,t){return new Iv(function(n){var r=0;return t.schedule(function(){r===e.length?n.complete():(n.next(e[r++]),n.closed||this.schedule())})})}function Ay(e,t){return new Iv(function(n){var r;return wy(n,t,function(){r=e[fy](),wy(n,t,function(){var e,t,i;try{e=r.next(),t=e.value,i=e.done}catch(e){n.error(e);return}i?n.complete():n.next(t)},0,!0)}),function(){return iv(r?.return)&&r.return()}})}function jy(e,t){if(!e)throw Error(`Iterable cannot be null`);return new Iv(function(n){wy(n,t,function(){var r=e[Symbol.asyncIterator]();wy(n,t,function(){r.next().then(function(e){e.done?n.complete():n.next(e.value)})},0,!0)})})}function My(e,t){return jy(my(e),t)}function Ny(e,t){if(e!=null){if(cy(e))return Dy(e,t);if(oy(e))return ky(e,t);if(sy(e))return Oy(e,t);if(ly(e))return jy(e,t);if(py(e))return Ay(e,t);if(hy(e))return My(e,t)}throw uy(e)}function Py(e,t){return t?Ny(e,t):gy(e)}function Fy(){var e=[...arguments];return Py(e,iy(e))}function Iy(e,t){var n=iv(e)?e:function(){return e},r=function(e){return e.error(n())};return new Iv(t?function(e){return t.schedule(r,0,e)}:r)}function Ly(e){return!!e&&(e instanceof Iv||iv(e.lift)&&iv(e.subscribe))}var Ry=av(function(e){return function(){e(this),this.name=`EmptyError`,this.message=`no elements in sequence`}});function $(e,t){var n=typeof t==`object`;return new Promise(function(r,i){var a=!1,o;e.subscribe({next:function(e){o=e,a=!0},error:i,complete:function(){a?r(o):n?r(t.defaultValue):i(new Ry)}})})}function zy(e,t){var n=typeof t==`object`;return new Promise(function(r,i){var a=new Dv({next:function(e){r(e),a.unsubscribe()},error:i,complete:function(){n?r(t.defaultValue):i(new Ry)}});e.subscribe(a)})}function By(e){return e instanceof Date&&!isNaN(e)}function Vy(e,t){return Vv(function(n,r){var i=0;n.subscribe(Hv(r,function(n){r.next(e.call(t,n,i++))}))})}var Hy=Array.isArray;function Uy(e,t){return Hy(t)?e.apply(void 0,Ag([],kg(t))):e(t)}function Wy(e){return Vy(function(t){return Uy(e,t)})}function Gy(e,t,n){return n===void 0&&(n=Nv),function(r){Ky(t,function(){for(var i=e.length,a=Array(i),o=i,s=i,c=function(i){Ky(t,function(){var c=Py(e[i],t),l=!1;c.subscribe(Hv(r,function(e){a[i]=e,l||(l=!0,s--),s||r.next(n(a.slice()))},function(){--o||r.complete()}))},r)},l=0;l<i;l++)c(l)},r)}}function Ky(e,t,n){e?wy(n,e,t):t()}function qy(e,t,n,r,i,a,o,s){var c=[],l=0,u=0,d=!1,f=function(){d&&!c.length&&!l&&t.complete()},p=function(e){return l<r?m(e):c.push(e)},m=function(e){a&&t.next(e),l++;var s=!1;gy(n(e,u++)).subscribe(Hv(t,function(e){i?.(e),a?p(e):t.next(e)},function(){s=!0},void 0,function(){if(s)try{l--;for(var e=function(){var e=c.shift();o?wy(t,o,function(){return m(e)}):m(e)};c.length&&l<r;)e();f()}catch(e){t.error(e)}}))};return e.subscribe(Hv(t,p,function(){d=!0,f()})),function(){s?.()}}function Jy(e,t,n){return n===void 0&&(n=1/0),iv(t)?Jy(function(n,r){return Vy(function(e,i){return t(n,e,r,i)})(gy(e(n,r)))},n):(typeof t==`number`&&(n=t),Vv(function(t,r){return qy(t,r,e,n)}))}function Yy(e){return e===void 0&&(e=1/0),Jy(Nv,e)}function Xy(){return Yy(1)}function Zy(){var e=[...arguments];return Xy()(Py(e,iy(e)))}function Qy(e){return new Iv(function(t){gy(e()).subscribe(t)})}function $y(e,t,n){e===void 0&&(e=0),n===void 0&&(n=$v);var r=-1;return t!=null&&(ty(t)?n=t:r=t),new Iv(function(t){var i=By(e)?+e-n.now():e;i<0&&(i=0);var a=0;return n.schedule(function(){t.closed||(t.next(a++),0<=r?this.schedule(void 0,r):t.complete())},i)})}function eb(){var e=[...arguments],t=iy(e),n=ay(e,1/0),r=e;return r.length?r.length===1?gy(r[0]):Yy(n)(Py(r,t)):ey}var tb=Array.isArray;function nb(e){return e.length===1&&tb(e[0])?e[0]:e}function rb(e,t){return Vv(function(n,r){var i=0;n.subscribe(Hv(r,function(n){return e.call(t,n,i++)&&r.next(n)}))})}function ib(e){return Vv(function(t,n){var r=null,i=!1,a;r=t.subscribe(Hv(n,void 0,void 0,function(o){a=gy(e(o,ib(e)(t))),r?(r.unsubscribe(),r=null,a.subscribe(n)):i=!0})),i&&(r.unsubscribe(),r=null,a.subscribe(n))})}function ab(){var e=[...arguments],t=ry(e);return t?Pv(ab.apply(void 0,Ag([],kg(e))),Wy(t)):Vv(function(t,n){Gy(Ag([t],kg(nb(e))))(n)})}function ob(){var e=[...arguments];return ab.apply(void 0,Ag([],kg(e)))}function sb(e){return Vv(function(t,n){try{t.subscribe(n)}finally{n.add(e)}})}function cb(e){e===void 0&&(e={});var t=e.connector,n=t===void 0?function(){return new Gv}:t,r=e.resetOnError,i=r===void 0?!0:r,a=e.resetOnComplete,o=a===void 0?!0:a,s=e.resetOnRefCountZero,c=s===void 0?!0:s;return function(e){var t,r,a,s=0,l=!1,u=!1,d=function(){r?.unsubscribe(),r=void 0},f=function(){d(),t=a=void 0,l=u=!1},p=function(){var e=t;f(),e?.unsubscribe()};return Vv(function(e,m){s++,!u&&!l&&d();var h=a??=n();m.add(function(){s--,s===0&&!u&&!l&&(r=lb(p,c))}),h.subscribe(m),!t&&s>0&&(t=new Dv({next:function(e){return h.next(e)},error:function(e){u=!0,d(),r=lb(f,i,e),h.error(e)},complete:function(){l=!0,d(),r=lb(f,o),h.complete()}}),gy(e).subscribe(t))})(e)}}function lb(e,t){var n=[...arguments].slice(2);if(t===!0){e();return}if(t!==!1){var r=new Dv({next:function(){r.unsubscribe(),e()}});return gy(t.apply(void 0,Ag([],kg(n)))).subscribe(r)}}function ub(e,t,n){var r,i,a,o,s=!1;return e&&typeof e==`object`?(r=e.bufferSize,o=r===void 0?1/0:r,i=e.windowTime,t=i===void 0?1/0:i,a=e.refCount,s=a===void 0?!1:a,n=e.scheduler):o=e??1/0,cb({connector:function(){return new Jv(o,t,n)},resetOnError:!0,resetOnComplete:!1,resetOnRefCountZero:s})}function db(e,t,n){var r=iv(e)||t||n?{next:e,error:t,complete:n}:e;return r?Vv(function(e,t){var n;(n=r.subscribe)==null||n.call(r);var i=!0;e.subscribe(Hv(t,function(e){var n;(n=r.next)==null||n.call(r,e),t.next(e)},function(){var e;i=!1,(e=r.complete)==null||e.call(r),t.complete()},function(e){var n;i=!1,(n=r.error)==null||n.call(r,e),t.error(e)},function(){var e,t;i&&((e=r.unsubscribe)==null||e.call(r)),(t=r.finalize)==null||t.call(r)}))}):Nv}var fb=`drafts`,pb=`versions`,mb=`.`,hb=`${fb}${mb}`,gb=`${pb}${mb}`;function _b(e){return e.startsWith(hb)}function vb(e){return e.startsWith(gb)}function yb(e){return vb(e)?hb+Sb(e):_b(e)?e:hb+e}function bb(e,t){if(t===`drafts`||t===`published`)throw Error(`Version can not be "published" or "drafts"`);return`${gb}${t}${mb}${Sb(e)}`}function xb(e){if(!vb(e))return;let[t,n]=e.split(mb);return n}function Sb(e){return vb(e)?e.split(mb).slice(2).join(mb):_b(e)?e.slice(hb.length):e}var Cb=e=>crypto.getRandomValues(new Uint8Array(e)),wb=(e,t,n)=>{let r=(2<<Math.log(e.length-1)/Math.LN2)-1,i=-~(1.6*r*t/e.length);return(a=t)=>{let o=``;for(;;){let t=n(i),s=i|0;for(;s--;)if(o+=e[t[s]&r]||``,o.length===a)return o}}},Tb=(e,t=21)=>wb(e,t,Cb),Eb=/\r\n|[\n\r\u2028\u2029]/;function Db(e,t,n){let r=e.split(Eb),{start:i,end:a,markerLines:o}=Ob({start:kb(t.start,r),end:t.end?kb(t.end,r):void 0},r),s=`${a}`.length;return e.split(Eb,a).slice(i,a).map((e,t)=>{let r=i+1+t,a=` ${` ${r}`.slice(-s)} |`,c=o[r],l=!o[r+1];if(!c)return` ${a}${e.length>0?` ${e}`:``}`;let u=``;if(Array.isArray(c)){let t=e.slice(0,Math.max(c[0]-1,0)).replace(/[^\t]/g,` `),r=c[1]||1;u=[`
 `,a.replace(/\d/g,` `),` `,t,`^`.repeat(r)].join(``),l&&n&&(u+=` `+n)}return[`>`,a,e.length>0?` ${e}`:``,u].join(``)}).join(`
`)}function Ob(e,t){let n={...e.start},r={...n,...e.end},i=n.line??-1,a=n.column??0,o=r.line,s=r.column,c=Math.max(i-3,0),l=Math.min(t.length,o+3);i===-1&&(c=0),o===-1&&(l=t.length);let u=o-i,d={};if(u)for(let e=0;e<=u;e++){let n=e+i;a?e===0?d[n]=[a,t[n-1].length-a+1]:e===u?d[n]=[0,s]:d[n]=[0,t[n-e].length]:d[n]=!0}else a===s?a?d[i]=[a,0]:d[i]=!0:d[i]=[a,s-a];return{start:c,end:l,markerLines:d}}function kb(e,t){let n=0;for(let r=0;r<t.length;r++){let i=t[r].length+1;if(n+i>e)return{line:r+1,column:e-n};n+=i}return{line:t.length,column:t[t.length-1]?.length??0}}var Ab=5,jb=class extends Error{response;statusCode=400;responseBody;traceId;details;constructor(e,t){let n=Nb(e,t);super(n.message),Object.assign(this,n)}},Mb=class extends Error{response;statusCode=500;responseBody;traceId;details;constructor(e){let t=Nb(e);super(t.message),Object.assign(this,t)}};function Nb(e,t){let n=e.body,i={response:e,statusCode:e.statusCode,responseBody:Bb(n,e),traceId:zb(e),message:``,details:void 0};if(!r(n))return i.message=`${Rb(e,n)}${Vb(i.traceId)}`,i;let a=n.error;if(typeof a==`string`&&typeof n.message==`string`)return i.message=`${a} - ${n.message}${Vb(i.traceId)}`,i;if(typeof a!=`object`||!a)return typeof a==`string`?i.message=`${a}${Vb(i.traceId)}`:typeof n.message==`string`?i.message=`${n.message}${Vb(i.traceId)}`:i.message=`${Rb(e,n)}${Vb(i.traceId)}`,i;if(Pb(a)||Fb(a)){let e=a.items||[],t=e.slice(0,Ab).map(e=>e.error?.description).filter(Boolean),r=t.length?`:
- ${t.join(`
- `)}`:``;return e.length>Ab&&(r+=`
...and ${e.length-Ab} more`),i.message=`${a.description}${Vb(i.traceId)}${r}`,i.details=n.error,i}if(Ib(a)){let e=t?.options?.query?.tag;return i.message=Lb(a,e,i.traceId),i.details=n.error,i}return`description`in a&&typeof a.description==`string`?(i.message=`${a.description}${Vb(i.traceId)}`,i.details=a,i):(i.message=`${Rb(e,n)}${Vb(i.traceId)}`,i)}function Pb(e){return`type`in e&&e.type===`mutationError`&&`description`in e&&typeof e.description==`string`}function Fb(e){return`type`in e&&e.type===`actionError`&&`description`in e&&typeof e.description==`string`}function Ib(e){return r(e)&&e.type===`queryParseError`&&typeof e.query==`string`&&typeof e.start==`number`&&typeof e.end==`number`}function Lb(e,t,n){let{query:r,start:i,end:a,description:o}=e,s=n?`
(traceId: ${n})`:``;if(!r||typeof i>`u`)return`GROQ query parse error: ${o}${s}`;let c=t?`

Tag: ${t}`:``;return`GROQ query parse error:
${Db(r,{start:i,end:a},o)}${c}${s}`}function Rb(e,t){let n=typeof t==`string`?` (${Hb(t,100)})`:``,r=e.statusMessage?` ${e.statusMessage}`:``;return`${e.method}-request to ${e.url} resulted in HTTP ${e.statusCode}${r}${n}`}function zb(e){let t=e?.headers?.traceparent;if(t)return t.split(`-`)[1]}function Bb(e,t){return(t.headers[`content-type`]||``).toLowerCase().indexOf(`application/json`)===-1?e:JSON.stringify(e,null,2)}function Vb(e){return e?` (traceId: ${e})`:``}function Hb(e,t){return e.length>t?`${e.slice(0,t)}\u2026`:e}var Ub=class extends Error{projectId;addOriginUrl;constructor({projectId:e}){super(`CorsOriginError`),this.name=`CorsOriginError`,this.projectId=e;let t=new URL(`https://sanity.io/manage/project/${e}/api`);if(typeof location<`u`){let{origin:e}=location;t.searchParams.set(`cors`,`add`),t.searchParams.set(`origin`,e),this.addOriginUrl=t,this.message=`The current origin is not allowed to connect to the Live Content API. Add it here: ${t}`}else this.message=`The current origin is not allowed to connect to the Live Content API. Change your configuration here: ${t}`}},Wb={onResponse:(e,t)=>{if(e.statusCode>=500)throw new Mb(e);if(e.statusCode>=400)throw new jb(e,t);return e}};function Gb(e={}){let t={},n=t=>e.ignoreWarnings===void 0?!1:(Array.isArray(e.ignoreWarnings)?e.ignoreWarnings:[e.ignoreWarnings]).some(e=>typeof e==`string`?t.includes(e):e instanceof RegExp?e.test(t):!1);return{onResponse:e=>{let r=e.headers[`x-sanity-warning`],i=Array.isArray(r)?r:[r];for(let e of i)!e||t[e]||n(e)||(t[e]=!0,console.warn(e));return e}}}function Kb(e,t={}){return N_([nv({shouldRetry:qb}),...e,Gb(t),G_(),K_(),X_(),Wb,Y_({implementation:Iv})])}function qb(e,t,n){if(n.maxRetries===0)return!1;let r=n.method===`GET`||n.method===`HEAD`,i=(n.uri||n.url).startsWith(`/data/query`),a=e.response&&(e.response.statusCode===429||e.response.statusCode===502||e.response.statusCode===503);return(r||i)&&a?!0:nv.shouldRetry(e,t,n)}var Jb=`https://www.sanity.io/help/`;function Yb(e){return Jb+e}var Xb=[`image`,`file`],Zb=[`before`,`after`,`replace`],Qb=e=>{if(!/^(~[a-z0-9]{1}[-\w]{0,63}|[a-z0-9]{1}[-\w]{0,63})$/.test(e))throw Error(`Datasets can only contain lowercase characters, numbers, underscores and dashes, and start with tilde, and be maximum 64 characters`)},$b=e=>{if(!/^[-a-z0-9]+$/i.test(e))throw Error("`projectId` can only contain only a-z, 0-9 and dashes")},ex=e=>{if(Xb.indexOf(e)===-1)throw Error(`Invalid asset type: ${e}. Must be one of ${Xb.join(`, `)}`)},tx=(e,t)=>{if(typeof t!=`object`||!t||Array.isArray(t))throw Error(`${e}() takes an object of properties`)},nx=(e,t)=>{if(typeof t!=`string`||!/^[a-z0-9_][a-z0-9_.-]{0,127}$/i.test(t)||t.includes(`..`))throw Error(`${e}(): "${t}" is not a valid document ID`)},rx=(e,t)=>{if(!t._id)throw Error(`${e}() requires that the document contains an ID ("_id" property)`);nx(e,t._id)},ix=(e,t)=>{if(typeof t!=`string`)throw Error(`\`${e}()\`: \`${t}\` is not a valid document type`)},ax=(e,t)=>{if(!t._type)throw Error(`\`${e}()\` requires that the document contains a type (\`_type\` property)`);ix(e,t._type)},ox=(e,t)=>{if(t._id&&t._id!==e)throw Error(`The provided document ID (\`${t._id}\`) does not match the generated version ID (\`${e}\`)`)},sx=(e,t,n)=>{let r=`insert(at, selector, items)`;if(Zb.indexOf(e)===-1){let e=Zb.map(e=>`"${e}"`).join(`, `);throw Error(`${r} takes an "at"-argument which is one of: ${e}`)}if(typeof t!=`string`)throw Error(`${r} takes a "selector"-argument which must be a string`);if(!Array.isArray(n))throw Error(`${r} takes an "items"-argument which must be an array`)},cx=e=>{if(e.dataset)return e.dataset;let t=e.resource;if(t&&t.type===`dataset`){let e=t.id.split(`.`);if(e.length!==2)throw Error(`Dataset resource ID must be in the format "project.dataset"`);return e[1]}throw Error("`dataset` must be provided to perform queries")},lx=e=>{if(typeof e!=`string`||!/^[a-z0-9._-]{1,75}$/i.test(e))throw Error(`Tag can only contain alphanumeric characters, underscores, dashes and dots, and be between one and 75 characters long.`);return e},ux=e=>{let t=e.resource;if(!t)throw Error("`resource` must be provided to perform resource queries");let{type:n,id:r}=t;switch(n){case`dataset`:if(r.split(`.`).length!==2)throw Error(`Dataset resource ID must be in the format "project.dataset"`);return;case`dashboard`:case`media-library`:case`canvas`:return;default:throw Error(`Unsupported resource type: ${n.toString()}`)}},dx=(e,t)=>{if(t.resource)throw Error(`\`${e}\` does not support resource-based operations`)};function fx(e){let t=!1,n;return(...r)=>(t||=(n=e(...r),!0),n)}var px=e=>fx((...t)=>console.warn(e.join(` `),...t)),mx=px(["Because you set `withCredentials` to true, we will override your `useCdn`",`setting to be false since (cookie-based) credentials are never set on the CDN`]),hx=px(["Since you haven't set a value for `useCdn`, we will deliver content using our",`global, edge-cached API-CDN. If you wish to have content delivered faster, set`,"`useCdn: false` to use the Live API. Note: You may incur higher costs using the live API."]),gx=px(["The Sanity client is configured with the `perspective` set to `drafts` or `previewDrafts`, which doesn't support the API-CDN.","The Live API will be used instead. Set `useCdn: false` in your configuration to hide this warning."]),_x=px(["The `previewDrafts` perspective has been renamed to  `drafts` and will be removed in a future API version"]),vx=px([`You have configured Sanity client to use a token in the browser. This may cause unintentional security issues.`,`See ${Yb(`js-client-browser-token`)} for more information and how to hide this warning.`]),yx=px(["You have configured Sanity client to use a token, but also provided `withCredentials: true`.","This is no longer supported - only token will be used - remove `withCredentials: true`."]),bx=px([`Using the Sanity client without specifying an API version is deprecated.`,`See ${Yb(`js-client-api-version`)}`]);px(["The default export of @sanity/client has been deprecated. Use the named export `createClient` instead."]);var xx=px(["You have called `createVersion()` with a defined `document`. The recommended approach is to provide a `baseId` and `releaseId` instead."]),Sx=px(["The `~experimental_resource` configuration property has been renamed to `resource`.","Please update your client configuration to use `resource` instead. Support for `~experimental_resource` will be removed in a future version."]),Cx=`apicdn.sanity.io`,wx={apiHost:`https://api.sanity.io`,apiVersion:`1`,useProjectHostname:!0,stega:{enabled:!1}},Tx=[`localhost`,`127.0.0.1`,`0.0.0.0`],Ex=e=>Tx.indexOf(e)!==-1;function Dx(e){if(e===`1`||e===`X`)return;let t=new Date(e);if(!(/^\d{4}-\d{2}-\d{2}$/.test(e)&&t instanceof Date&&t.getTime()>0))throw Error("Invalid API version string, expected `1` or date in format `YYYY-MM-DD`")}function Ox(e){if(Array.isArray(e)&&e.length>1&&e.includes(`raw`))throw TypeError(`Invalid API perspective value: "raw". The raw-perspective can not be combined with other perspectives`)}var kx=(e,t)=>{let n={...t,...e,stega:{...typeof t.stega==`boolean`?{enabled:t.stega}:t.stega||wx.stega,...typeof e.stega==`boolean`?{enabled:e.stega}:e.stega||{}}};n.apiVersion||bx();let r={...wx,...n};r[`~experimental_resource`]&&!r.resource&&(Sx(),r.resource=r[`~experimental_resource`]);let i=r.resource,a=r.useProjectHostname&&!i;if(typeof Promise>`u`){let e=Yb(`js-client-promise-polyfill`);throw Error(`No native Promise-implementation found, polyfill needed - see ${e}`)}if(a&&!r.projectId)throw Error("Configuration must contain `projectId`");if(i&&ux(r),typeof r.perspective<`u`&&Ox(r.perspective),`encodeSourceMap`in r)throw Error(`It looks like you're using options meant for '@sanity/preview-kit/client'. 'encodeSourceMap' is not supported in '@sanity/client'. Did you mean 'stega.enabled'?`);if(`encodeSourceMapAtPath`in r)throw Error(`It looks like you're using options meant for '@sanity/preview-kit/client'. 'encodeSourceMapAtPath' is not supported in '@sanity/client'. Did you mean 'stega.filter'?`);if(typeof r.stega.enabled!=`boolean`)throw Error(`stega.enabled must be a boolean, received ${r.stega.enabled}`);if(r.stega.enabled&&r.stega.studioUrl===void 0)throw Error(`stega.studioUrl must be defined when stega.enabled is true`);if(r.stega.enabled&&typeof r.stega.studioUrl!=`string`&&typeof r.stega.studioUrl!=`function`)throw Error(`stega.studioUrl must be a string or a function, received ${r.stega.studioUrl}`);let o=typeof window<`u`&&window.location&&window.location.hostname,s=o&&Ex(window.location.hostname),c=!!r.token;r.withCredentials&&c&&(yx(),r.withCredentials=!1),o&&s&&c&&r.ignoreBrowserTokenWarning!==!0?vx():typeof r.useCdn>`u`&&hx(),a&&$b(r.projectId),r.dataset&&Qb(r.dataset),`requestTagPrefix`in r&&(r.requestTagPrefix=r.requestTagPrefix?lx(r.requestTagPrefix).replace(/\.+$/,``):void 0),r.apiVersion=`${r.apiVersion}`.replace(/^v/,``),r.isDefaultApi=r.apiHost===wx.apiHost,r.useCdn===!0&&r.withCredentials&&mx(),r.useCdn=r.useCdn!==!1&&!r.withCredentials,Dx(r.apiVersion);let l=r.apiHost.split(`://`,2),u=l[0],d=l[1],f=r.isDefaultApi?Cx:d;return a?(r.url=`${u}://${r.projectId}.${d}/v${r.apiVersion}`,r.cdnUrl=`${u}://${r.projectId}.${f}/v${r.apiVersion}`):(r.url=`${r.apiHost}/v${r.apiVersion}`,r.cdnUrl=r.url),r},Ax=class extends Error{name=`ConnectionFailedError`},jx=class extends Error{name=`DisconnectError`;reason;constructor(e,t,n={}){super(e,n),this.reason=t}},Mx=class extends Error{name=`ChannelError`;data;constructor(e,t){super(e),this.data=t}},Nx=class extends Error{name=`MessageError`;data;constructor(e,t,n={}){super(e,n),this.data=t}},Px=class extends Error{name=`MessageParseError`},Fx=[`channelError`,`disconnect`];function Ix(e,t){return Qy(()=>{let t=e();return Ly(t)?t:Fy(t)}).pipe(Jy(e=>Lx(e,t)))}function Lx(e,t){return new Iv(n=>{let r=t.includes(`open`),i=t.includes(`reconnect`);function a(t){if(`data`in t){let[e,r]=Rx(t);n.error(e?new Px(`Unable to parse EventSource error message`,{cause:r}):new Nx((r?.data).message,r));return}e.readyState===e.CLOSED?n.error(new Ax(`EventSource connection failed`)):i&&n.next({type:`reconnect`})}function o(){n.next({type:`open`})}function s(t){let[r,i]=Rx(t);if(r){n.error(new Px(`Unable to parse EventSource message`,{cause:r}));return}if(t.type===`channelError`){let t=new URL(e.url).searchParams.get(`tag`);n.error(new Mx(zx(i?.data,t),i.data));return}if(t.type===`disconnect`){n.error(new jx(`Server disconnected client: ${i.data?.reason||`unknown error`}`));return}n.next({type:t.type,id:t.lastEventId,...i.data?{data:i.data}:{}})}e.addEventListener(`error`,a),r&&e.addEventListener(`open`,o);let c=[...new Set([...Fx,...t])].filter(e=>e!==`error`&&e!==`open`&&e!==`reconnect`);return c.forEach(t=>e.addEventListener(t,s)),()=>{e.removeEventListener(`error`,a),r&&e.removeEventListener(`open`,o),c.forEach(t=>e.removeEventListener(t,s)),e.close()}})}function Rx(e){try{let t=typeof e.data==`string`&&JSON.parse(e.data);return[null,{type:e.type,id:e.lastEventId,...Bx(t)?{}:{data:t}}]}catch(e){return[e,null]}}function zx(e,t){let n=e.error;return n?Ib(n)?Lb(n,t):n.description?n.description:typeof n==`string`?n:JSON.stringify(n,null,2):e.message||`Unknown listener error`}function Bx(e){for(let t in e)return!1;return!0}function Vx(e){if(typeof e==`string`)return{id:e};if(Array.isArray(e))return{query:`*[_id in $ids]`,params:{ids:e}};if(typeof e==`object`&&e&&`query`in e&&typeof e.query==`string`)return`params`in e&&typeof e.params==`object`&&e.params!==null?{query:e.query,params:e.params}:{query:e.query};let t=[`* Document ID (<docId>)`,`* Array of document IDs`,"* Object containing `query`"].join(`
`);throw Error(`Unknown selection - must be one of:

${t}`)}var Hx=class{selection;operations;constructor(e,t={}){this.selection=e,this.operations=t}set(e){return this._assign(`set`,e)}setIfMissing(e){return this._assign(`setIfMissing`,e)}diffMatchPatch(e){return tx(`diffMatchPatch`,e),this._assign(`diffMatchPatch`,e)}unset(e){if(!Array.isArray(e))throw Error(`unset(attrs) takes an array of attributes to unset, non-array given`);return this.operations=Object.assign({},this.operations,{unset:e}),this}inc(e){return this._assign(`inc`,e)}dec(e){return this._assign(`dec`,e)}insert(e,t,n){return sx(e,t,n),this._assign(`insert`,{[e]:t,items:n})}append(e,t){return this.insert(`after`,`${e}[-1]`,t)}prepend(e,t){return this.insert(`before`,`${e}[0]`,t)}splice(e,t,n,r){let i=typeof n>`u`||n===-1,a=t<0?t-1:t,o=i?-1:Math.max(0,t+n),s=`${e}[${a}:${a<0&&o>=0?``:o}]`;return this.insert(`replace`,s,r||[])}ifRevisionId(e){return this.operations.ifRevisionID=e,this}serialize(){return{...Vx(this.selection),...this.operations}}toJSON(){return this.serialize()}reset(){return this.operations={},this}_assign(e,t,n=!0){return tx(e,t),this.operations=Object.assign({},this.operations,{[e]:Object.assign({},n&&this.operations[e]||{},t)}),this}_set(e,t){return this._assign(e,t,!1)}},Ux=class e extends Hx{#e;constructor(e,t,n){super(e,t),this.#e=n}clone(){return new e(this.selection,{...this.operations},this.#e)}commit(e){if(!this.#e)throw Error("No `client` passed to patch, either provide one or pass the patch to a clients `mutate()` method");let t=typeof this.selection==`string`,n=Object.assign({returnFirst:t,returnDocuments:!0},e);return this.#e.mutate({patch:this.serialize()},n)}},Wx=class e extends Hx{#e;constructor(e,t,n){super(e,t),this.#e=n}clone(){return new e(this.selection,{...this.operations},this.#e)}commit(e){if(!this.#e)throw Error("No `client` passed to patch, either provide one or pass the patch to a clients `mutate()` method");let t=typeof this.selection==`string`,n=Object.assign({returnFirst:t,returnDocuments:!0},e);return this.#e.mutate({patch:this.serialize()},n)}},Gx={returnDocuments:!1},Kx=class{operations;trxId;constructor(e=[],t){this.operations=e,this.trxId=t}create(e){return tx(`create`,e),this._add({create:e})}createIfNotExists(e){let t=`createIfNotExists`;return tx(t,e),rx(t,e),this._add({[t]:e})}createOrReplace(e){let t=`createOrReplace`;return tx(t,e),rx(t,e),this._add({[t]:e})}delete(e){return nx(`delete`,e),this._add({delete:{id:e}})}transactionId(e){return e?(this.trxId=e,this):this.trxId}serialize(){return[...this.operations]}toJSON(){return this.serialize()}reset(){return this.operations=[],this}_add(e){return this.operations.push(e),this}},qx=class e extends Kx{#e;constructor(e,t,n){super(e,n),this.#e=t}clone(){return new e([...this.operations],this.#e,this.trxId)}commit(e){if(!this.#e)throw Error("No `client` passed to transaction, either provide one or pass the transaction to a clients `mutate()` method");return this.#e.mutate(this.serialize(),Object.assign({transactionId:this.trxId},Gx,e||{}))}patch(e,t){let n=typeof t==`function`,r=typeof e!=`string`&&e instanceof Wx,i=typeof e==`object`&&(`query`in e||`id`in e);if(r)return this._add({patch:e.serialize()});if(n){let n=t(new Wx(e,{},this.#e));if(!(n instanceof Wx))throw Error("function passed to `patch()` must return the patch");return this._add({patch:n.serialize()})}if(i){let n=new Wx(e,t||{},this.#e);return this._add({patch:n.serialize()})}return this._add({patch:{id:e,...t}})}},Jx=class e extends Kx{#e;constructor(e,t,n){super(e,n),this.#e=t}clone(){return new e([...this.operations],this.#e,this.trxId)}commit(e){if(!this.#e)throw Error("No `client` passed to transaction, either provide one or pass the transaction to a clients `mutate()` method");return this.#e.mutate(this.serialize(),Object.assign({transactionId:this.trxId},Gx,e||{}))}patch(e,t){let n=typeof t==`function`;if(typeof e!=`string`&&e instanceof Ux)return this._add({patch:e.serialize()});if(n){let n=t(new Ux(e,{},this.#e));if(!(n instanceof Ux))throw Error("function passed to `patch()` must return the patch");return this._add({patch:n.serialize()})}return this._add({patch:{id:e,...t}})}},Yx=`X-Sanity-Project-ID`;function Xx(e,t={}){let n={};e.headers&&Object.assign(n,e.headers);let r=t.token||e.token;r&&(n.Authorization=`Bearer ${r}`),!t.useGlobalApi&&!e.useProjectHostname&&e.projectId&&(n[Yx]=e.projectId);let i=!!(typeof t.withCredentials>`u`?e.withCredentials:t.withCredentials),a=typeof t.timeout>`u`?e.timeout:t.timeout;return Object.assign({},t,{headers:Object.assign({},n,t.headers||{}),timeout:typeof a>`u`?300*1e3:a,proxy:t.proxy||e.proxy,json:!0,withCredentials:i,fetch:typeof t.fetch==`object`&&typeof e.fetch==`object`?{...e.fetch,...t.fetch}:t.fetch||e.fetch})}var Zx=({query:e,params:t={},options:n={}})=>{let r=new URLSearchParams,{tag:i,includeMutations:a,returnQuery:o,...s}=n;i&&r.append(`tag`,i),r.append(`query`,e);for(let[e,n]of Object.entries(t))n!==void 0&&r.append(`$${e}`,JSON.stringify(n));for(let[e,t]of Object.entries(s))t&&r.append(e,`${t}`);return o===!1&&r.append(`returnQuery`,`false`),a===!1&&r.append(`includeMutations`,`false`),`?${r}`},Qx=(e,t)=>e===!1?void 0:typeof e>`u`?t:e,$x=(e={})=>({dryRun:e.dryRun,returnIds:!0,returnDocuments:Qx(e.returnDocuments,!0),visibility:e.visibility||`sync`,autoGenerateArrayKeys:e.autoGenerateArrayKeys,skipCrossDatasetReferenceValidation:e.skipCrossDatasetReferenceValidation}),eS=e=>e.type===`response`,tS=e=>e.body,nS=(e,t)=>e.reduce((e,n)=>(e[t(n)]=n,e),Object.create(null)),rS=11264;function iS(e,t,r,i,a={},o={}){let s=`stega`in o?{...r||{},...typeof o.stega==`boolean`?{enabled:o.stega}:o.stega||{}}:r,c=s.enabled?n(a):a,l=o.filterResponse===!1?e=>e:e=>e.result,{cache:u,next:d,...f}={useAbortSignal:typeof o.signal<`u`,resultSourceMap:s.enabled?`withKeyArraySelector`:o.resultSourceMap,...o,returnQuery:o.filterResponse===!1&&o.returnQuery!==!1},p=typeof u<`u`||typeof d<`u`?{...f,fetch:{cache:u,next:d}}:f,m=vS(e,t,`query`,{query:i,params:c},p);return s.enabled?m.pipe(ob(Py(Ue(()=>import(`./stegaEncodeSourceMap-BheWRINd.js`).then(function(e){return e.stegaEncodeSourceMap$1}),__vite__mapDeps([0,1])).then(({stegaEncodeSourceMap:e})=>e))),Vy(([e,t])=>{let n=t(e.result,e.resultSourceMap,s);return l({...e,result:n})})):m.pipe(Vy(l))}function aS(e,t,n,r={}){return DS(e,t,{uri:kS(e,`doc`,(()=>{if(!r.releaseId)return n;let e=xb(n);if(!e){if(_b(n))throw Error(`The document ID (\`${n}\`) is a draft, but \`options.releaseId\` is set as \`${r.releaseId}\``);return bb(n,r.releaseId)}if(e!==r.releaseId)throw Error(`The document ID (\`${n}\`) is already a version of \`${e}\` release, but this does not match the provided \`options.releaseId\` (\`${r.releaseId}\`)`);return n})()),json:!0,tag:r.tag,signal:r.signal,query:r.includeAllVersions===void 0?void 0:{includeAllVersions:r.includeAllVersions}}).pipe(rb(eS),Vy(e=>{let t=e.body.documents;return t?r.includeAllVersions?t:t[0]:r.includeAllVersions?[]:void 0}))}function oS(e,t,n,r={}){return DS(e,t,{uri:kS(e,`doc`,n.join(`,`)),json:!0,tag:r.tag,signal:r.signal}).pipe(rb(eS),Vy(e=>{let t=nS(e.body.documents||[],e=>e._id);return n.map(e=>t[e]||null)}))}function sS(e,t,n,r={}){return vS(e,t,`query`,{query:`*[sanity::partOfRelease($releaseId)]`,params:{releaseId:n}},r)}function cS(e,t,n,r){return rx(`createIfNotExists`,n),yS(e,t,n,`createIfNotExists`,r)}function lS(e,t,n,r){return rx(`createOrReplace`,n),yS(e,t,n,`createOrReplace`,r)}function uS(e,t,n,r,i){return rx(`createVersion`,n),ax(`createVersion`,n),xx(),_S(e,t,{actionType:`sanity.action.document.version.create`,publishedId:r,document:n},i)}function dS(e,t,n,r,i,a,o){if(!r)throw Error("`createVersion()` requires `baseId` when no `document` is provided");if(!n)throw Error("`createVersion()` requires `publishedId` when `baseId` is provided");return nx(`createVersion`,r),nx(`createVersion`,n),_S(e,t,{actionType:`sanity.action.document.version.create`,publishedId:n,baseId:r,versionId:i?bb(n,i):yb(n),ifBaseRevisionId:a},o)}function fS(e,t,n,r){return vS(e,t,`mutate`,{mutations:[{delete:Vx(n)}]},r)}function pS(e,t,n,r=!1,i){return _S(e,t,{actionType:`sanity.action.document.version.discard`,versionId:n,purge:r},i)}function mS(e,t,n,r){return rx(`replaceVersion`,n),ax(`replaceVersion`,n),_S(e,t,{actionType:`sanity.action.document.version.replace`,document:n},r)}function hS(e,t,n,r,i){return _S(e,t,{actionType:`sanity.action.document.version.unpublish`,versionId:n,publishedId:r},i)}function gS(e,t,n,r){let i;return i=n instanceof Wx||n instanceof Ux?{patch:n.serialize()}:n instanceof qx||n instanceof Jx?n.serialize():n,vS(e,t,`mutate`,{mutations:Array.isArray(i)?i:[i],transactionId:r&&r.transactionId||void 0},r)}function _S(e,t,n,r){return vS(e,t,`actions`,{actions:Array.isArray(n)?n:[n],transactionId:r&&r.transactionId||void 0,skipCrossDatasetReferenceValidation:r&&r.skipCrossDatasetReferenceValidation||void 0,dryRun:r&&r.dryRun||void 0},r)}function vS(e,t,n,r,i={}){let a=n===`mutate`,o=n===`actions`,s=n===`query`,c=a||o?``:Zx(r),l=!a&&!o&&c.length<rS,u=l?c:``,d=i.returnFirst,{timeout:f,token:p,tag:m,headers:h,returnQuery:g,lastLiveEventId:_,cacheMode:v}=i,y=kS(e,n,u);return DS(e,t,{method:l?`GET`:`POST`,uri:y,json:!0,body:l?void 0:r,query:a&&$x(i),timeout:f,headers:h,token:p,tag:m,returnQuery:g,perspective:i.perspective,resultSourceMap:i.resultSourceMap,lastLiveEventId:Array.isArray(_)?_[0]:_,cacheMode:v,canUseCdn:s,signal:i.signal,fetch:i.fetch,useAbortSignal:i.useAbortSignal,useCdn:i.useCdn}).pipe(rb(eS),Vy(tS),Vy(e=>{if(!a)return e;let t=e.results||[];if(i.returnDocuments)return d?t[0]&&t[0].document:t.map(e=>e.document);let n=d?`documentId`:`documentIds`,r=d?t[0]&&t[0].id:t.map(e=>e.id);return{transactionId:e.transactionId,results:t,[n]:r}}))}function yS(e,t,n,r,i={}){let a={[r]:n},o=Object.assign({returnFirst:!0,returnDocuments:!0},i);return vS(e,t,`mutate`,{mutations:[a]},o)}var bS=e=>{let t=e.config();return t.dataset!==void 0&&t.projectId!==void 0||t.resource!==void 0},xS=(e,t)=>bS(e)&&t.startsWith(kS(e,`query`)),SS=(e,t)=>bS(e)&&t.startsWith(kS(e,`mutate`)),CS=(e,t)=>bS(e)&&t.startsWith(kS(e,`doc`,``)),wS=(e,t)=>bS(e)&&t.startsWith(kS(e,`listen`)),TS=(e,t)=>bS(e)&&t.startsWith(kS(e,`history`,``)),ES=(e,t)=>t.startsWith(`/data/`)||xS(e,t)||SS(e,t)||CS(e,t)||wS(e,t)||TS(e,t);function DS(e,t,n){let r=n.url||n.uri,i=e.config(),a=typeof n.canUseCdn>`u`?[`GET`,`HEAD`].indexOf(n.method||`GET`)>=0&&ES(e,r):n.canUseCdn,o=(n.useCdn??i.useCdn)&&a,s=n.tag&&i.requestTagPrefix?[i.requestTagPrefix,n.tag].join(`.`):n.tag||i.requestTagPrefix;if(s&&n.tag!==null&&(n.query={tag:lx(s),...n.query}),[`GET`,`HEAD`,`POST`].indexOf(n.method||`GET`)>=0&&xS(e,r)){let e=n.resultSourceMap??i.resultSourceMap;e!==void 0&&e!==!1&&(n.query={resultSourceMap:e,...n.query});let t=n.perspective||i.perspective;typeof t<`u`&&(t===`previewDrafts`&&_x(),Ox(t),n.query={perspective:Array.isArray(t)?t.join(`,`):t,...n.query},(Array.isArray(t)&&t.length>0||t===`previewDrafts`||t===`drafts`)&&o&&(o=!1,gx())),n.lastLiveEventId&&(n.query={...n.query,lastLiveEventId:n.lastLiveEventId}),n.returnQuery===!1&&(n.query={returnQuery:`false`,...n.query}),o&&n.cacheMode==`noStale`&&(n.query={cacheMode:`noStale`,...n.query})}let c=Xx(i,Object.assign({},n,{url:AS(e,r,o)})),l=new Iv(e=>t(c,i.requester).subscribe(e));return n.signal?l.pipe(jS(n.signal)):l}function OS(e,t,n){return DS(e,t,n).pipe(rb(e=>e.type===`response`),Vy(e=>e.body))}function kS(e,t,n){let r=e.config();if(r.resource)return ux(r),`${PS(r)}/${n===void 0?t:`${t}/${n}`}`.replace(/\/($|\?)/,`$1`);let i=`/${t}/${cx(r)}`;return`/data${n===void 0?i:`${i}/${n}`}`.replace(/\/($|\?)/,`$1`)}function AS(e,t,n=!1){let{url:r,cdnUrl:i}=e.config();return`${n?i:r}/${t.replace(/^\//,``)}`}function jS(e){return t=>new Iv(n=>{let r=()=>n.error(NS(e));if(e&&e.aborted){r();return}let i=t.subscribe(n);return e.addEventListener(`abort`,r),()=>{e.removeEventListener(`abort`,r),i.unsubscribe()}})}var MS=!!globalThis.DOMException;function NS(e){if(MS)return new DOMException(e?.reason??`The operation was aborted.`,`AbortError`);let t=Error(e?.reason??`The operation was aborted.`);return t.name=`AbortError`,t}var PS=e=>{let t=e.resource;if(!t)throw Error("`resource` must be provided to perform resource queries");let{type:n,id:r}=t;switch(n){case`dataset`:{let e=r.split(`.`);if(e.length!==2)throw Error(`Dataset ID must be in the format "project.dataset"`);return`/projects/${e[0]}/datasets/${e[1]}`}case`canvas`:return`/canvases/${r}`;case`media-library`:return`/media-libraries/${r}`;case`dashboard`:return`/dashboards/${r}`;default:throw Error(`Unsupported resource type: ${n.toString()}`)}};function FS(e,t,n){return OS(e,t,{method:`POST`,uri:`/agent/action/generate/${cx(e.config())}`,body:n})}function IS(e,t,n){return OS(e,t,{method:`POST`,uri:`/agent/action/patch/${cx(e.config())}`,body:n})}function LS(e,t,n){return OS(e,t,{method:`POST`,uri:`/agent/action/prompt/${cx(e.config())}`,body:n})}function RS(e,t,n){return OS(e,t,{method:`POST`,uri:`/agent/action/transform/${cx(e.config())}`,body:n})}function zS(e,t,n){return OS(e,t,{method:`POST`,uri:`/agent/action/translate/${cx(e.config())}`,body:n})}var BS=class{#e;#t;constructor(e,t){this.#e=e,this.#t=t}generate(e){return FS(this.#e,this.#t,e)}transform(e){return RS(this.#e,this.#t,e)}translate(e){return zS(this.#e,this.#t,e)}},VS=class{#e;#t;constructor(e,t){this.#e=e,this.#t=t}generate(e){return $(FS(this.#e,this.#t,e))}transform(e){return $(RS(this.#e,this.#t,e))}translate(e){return $(zS(this.#e,this.#t,e))}prompt(e){return $(LS(this.#e,this.#t,e))}patch(e){return $(IS(this.#e,this.#t,e))}},HS=class{#e;#t;constructor(e,t){this.#e=e,this.#t=t}upload(e,t,n){return WS(this.#e,this.#t,e,t,n)}},US=class{#e;#t;constructor(e,t){this.#e=e,this.#t=t}upload(e,t,n){return $(WS(this.#e,this.#t,e,t,n).pipe(rb(e=>e.type===`response`),Vy(e=>e.body.document)))}};function WS(e,t,n,r,i={}){ex(n);let a=i.extract||void 0;a&&!a.length&&(a=[`none`]);let o=e.config(),s=KS(i,r),{tag:c,label:l,title:u,description:d,creditLine:f,filename:p,source:m}=s,h=o.resource?.type===`media-library`,g=h?{title:u,filename:p}:{label:l,title:u,description:d,filename:p,meta:a,creditLine:f};return m&&!h&&(g.sourceId=m.id,g.sourceName=m.name,g.sourceUrl=m.url),DS(e,t,{tag:c,method:`POST`,timeout:s.timeout||0,uri:GS(o,n),headers:s.contentType?{"Content-Type":s.contentType}:{},query:g,body:r})}function GS(e,t){let n=t===`image`?`images`:`files`,r=e.resource;if(r){let{type:e,id:t}=r;switch(e){case`dataset`:throw Error("Assets are not supported for dataset resources, yet. Configure the client with `{projectId: <projectId>, dataset: <datasetId>}` instead.");case`canvas`:return`/canvases/${t}/assets/${n}`;case`media-library`:return`/media-libraries/${t}/upload`;case`dashboard`:return`/dashboards/${t}/assets/${n}`;default:throw Error(`Unsupported resource type: ${e.toString()}`)}}return`assets/${n}/${cx(e)}`}function KS(e,t){return typeof File>`u`||!(t instanceof File)?e:Object.assign({filename:e.preserveFilename===!1?void 0:t.name,contentType:t.type},e)}var qS=(e,t)=>Object.keys(t).concat(Object.keys(e)).reduce((n,r)=>(n[r]=typeof e[r]>`u`?t[r]:e[r],n),{}),JS=(e,t)=>t.reduce((t,n)=>(typeof e[n]>`u`||(t[n]=e[n]),t),{}),YS=Qy(()=>Ue(()=>import(`./browser-C0hijO98.js`).then(t=>e(t.default,1)),__vite__mapDeps([2,3]))).pipe(Vy(({default:e})=>e),ub(1));function XS(){return function(e){return e.pipe(ib((e,t)=>e instanceof Ax?Zy(Fy({type:`reconnect`}),$y(1e3).pipe(Jy(()=>t))):Iy(()=>e)))}}var ZS=14800,QS=[`includePreviousRevision`,`includeResult`,`includeMutations`,`includeAllVersions`,`visibility`,`effectFormat`,`enableResume`,`tag`],$S={includeResult:!0};function eC(e,t,n={}){let{url:r,token:i,withCredentials:a,requestTagPrefix:o,headers:s}=this.config(),c=n.tag&&o?[o,n.tag].join(`.`):n.tag,l={...qS(n,$S),tag:c},u=Zx({query:e,params:t,options:{tag:c,...JS(l,QS)}}),d=`${r}${kS(this,`listen`,u)}`;if(d.length>ZS)return Iy(()=>Error(`Query too large for listener`));let f=l.events?l.events:[`mutation`],p={};return a&&(p.withCredentials=!0),(i||s)&&(p.headers={},i&&(p.headers.Authorization=`Bearer ${i}`),s&&Object.assign(p.headers,s)),Ix(()=>(typeof EventSource>`u`||p.headers?YS:Fy(EventSource)).pipe(Vy(e=>new e(d,p))),f).pipe(XS(),rb(e=>f.includes(e.type)),Vy(e=>({type:e.type,...`data`in e?e.data:{}})))}function tC(e,t){return nC(typeof e==`function`?{predicate:e,...t}:e)}function nC(e){return t=>{let n,r=!1,{predicate:i,...a}=e;return eb(t.pipe(db(t=>{e.predicate(t)&&(r=!0,n=t)}),sb(()=>{r=!1,n=void 0}),cb(a)),new Iv(e=>{r&&e.next(n),e.complete()}))}}var rC=`2021-03-25`,iC=class{#e;constructor(e){this.#e=e}events({includeDrafts:e=!1,tag:t,waitFor:n}={}){let{projectId:r,apiVersion:i,token:a,withCredentials:o,requestTagPrefix:s,headers:c}=this.#e.config(),l=i.replace(/^v/,``);if(l!==`X`&&l<rC)throw Error(`The live events API requires API version ${rC} or later. The current API version is ${l}. Please update your API version to use this feature.`);if(e&&!a&&!o)throw Error(`The live events API requires a token or withCredentials when 'includeDrafts: true'. Please update your client configuration. The token should have the lowest possible access role.`);let u=kS(this.#e,`live/events`),d=new URL(this.#e.getUrl(u,!1)),f=t&&s?[s,t].join(`.`):t;f&&d.searchParams.set(`tag`,f),e&&d.searchParams.set(`includeDrafts`,`true`),n&&d.searchParams.set(`waitFor`,n);let p={};e&&o&&(p.withCredentials=!0),(e&&a||c)&&(p.headers={},e&&a&&(p.headers.Authorization=`Bearer ${a}`),c&&Object.assign(p.headers,c));let m=`${d.href}::${JSON.stringify(p)}`,h=oC.get(m);if(h)return h;let g=Ix(()=>(typeof EventSource>`u`||p.headers?YS:Fy(EventSource)).pipe(Vy(e=>new e(d.href,p))),[`message`,`restart`,`welcome`,`reconnect`,`goaway`]),_=aC(d,{method:`OPTIONS`,mode:`cors`,credentials:p.withCredentials?`include`:`omit`,headers:p.headers}).pipe(ib(()=>{throw new Ub({projectId:r})})),v=g.pipe(XS(),Jy(e=>e.type===`reconnect`?_.pipe(Jy(()=>Fy(e))):Fy(e)),ib(e=>_.pipe(Jy(()=>{throw e}))),Vy(e=>{if(e.type===`message`){let{data:t,...n}=e;return{...n,tags:t.tags}}return e})).pipe(sb(()=>oC.delete(m)),tC({predicate:e=>e.type===`welcome`}));return oC.set(m,v),v}};function aC(e,t){return new Iv(n=>{let r=new AbortController,i=r.signal;return fetch(e,{...t,signal:r.signal}).then(e=>{n.next(e),n.complete()},e=>{i.aborted||n.error(e)}),()=>r.abort()})}var oC=new Map,sC=class{#e;#t;constructor(e,t){this.#e=e,this.#t=t}create(e,t){return uC(this.#e,this.#t,`PUT`,e,t)}edit(e,t){return uC(this.#e,this.#t,`PATCH`,e,t)}delete(e){return uC(this.#e,this.#t,`DELETE`,e)}list(){dx(`dataset`,this.#e.config());let e=this.#e.config(),t=e.projectId,n=`/datasets`;return e.useProjectHostname===!1&&(n=`/projects/${t}/datasets`),OS(this.#e,this.#t,{uri:n,tag:null})}getEmbeddingsSettings(e){return dx(`dataset`,this.#e.config()),Qb(e),OS(this.#e,this.#t,{uri:lC(this.#e,e),tag:null})}editEmbeddingsSettings(e,t){return dx(`dataset`,this.#e.config()),Qb(e),OS(this.#e,this.#t,{method:`PUT`,uri:lC(this.#e,e),body:t,tag:null})}},cC=class{#e;#t;constructor(e,t){this.#e=e,this.#t=t}create(e,t){return dx(`dataset`,this.#e.config()),$(uC(this.#e,this.#t,`PUT`,e,t))}edit(e,t){return dx(`dataset`,this.#e.config()),$(uC(this.#e,this.#t,`PATCH`,e,t))}delete(e){return dx(`dataset`,this.#e.config()),$(uC(this.#e,this.#t,`DELETE`,e))}list(){dx(`dataset`,this.#e.config());let e=this.#e.config(),t=e.projectId,n=`/datasets`;return e.useProjectHostname===!1&&(n=`/projects/${t}/datasets`),$(OS(this.#e,this.#t,{uri:n,tag:null}))}getEmbeddingsSettings(e){return dx(`dataset`,this.#e.config()),Qb(e),$(OS(this.#e,this.#t,{uri:lC(this.#e,e),tag:null}))}editEmbeddingsSettings(e,t){return dx(`dataset`,this.#e.config()),Qb(e),$(OS(this.#e,this.#t,{method:`PUT`,uri:lC(this.#e,e),body:t,tag:null}))}};function lC(e,t){let n=e.config();return n.useProjectHostname===!1?`/projects/${n.projectId}/datasets/${t}/settings/embeddings`:`/datasets/${t}/settings/embeddings`}function uC(e,t,n,r,i){return dx(`dataset`,e.config()),Qb(r),OS(e,t,{method:n,uri:`/datasets/${r}`,body:i,tag:null})}var dC=class{#e;#t;constructor(e,t){this.#e=e,this.#t=t}getPlaybackInfo(e,t={}){let n=this.#e.config(),r=(n.resource||n[`~experimental_resource`])?.id,{instanceId:i,libraryId:a}=hC(e),o=a||r;if(!o)throw Error(`Could not determine Media Library ID - you need to provide a valid Media Library ID in the client config or a Media Library GDR`);let s=gC(i,o),c=_C(t);return OS(this.#e,this.#t,{method:`GET`,uri:s,query:c})}},fC=class{#e;#t;constructor(e,t){this.#e=e,this.#t=t}getPlaybackInfo(e,t={}){return $(new dC(this.#e.observable,this.#t).getPlaybackInfo(e,t))}},pC=/^media-library:(ml[^:]+):([^:]+)$/;function mC(e){return typeof e==`object`&&`_ref`in e}function hC(e){let t=mC(e)?e._ref:e,n=pC.exec(t);if(n){let[,e,t]=n;return{libraryId:e,instanceId:t}}if(typeof e==`string`&&e.startsWith(`video-`))return{instanceId:e};throw Error(`Invalid video asset instance identifier "${t}": must be a valid video instance id or a Global Dataset Reference (GDR) to the video asset in the Media Library`)}function gC(e,t){return`/media-libraries/${t}/video/${e}/playback-info`}function _C(e){let t={};if(e.transformations){let{thumbnail:n,animated:r,storyboard:i}=e.transformations;n&&(n.width&&(t.thumbnailWidth=n.width),n.height&&(t.thumbnailHeight=n.height),n.time!==void 0&&(t.thumbnailTime=n.time),n.fit&&(t.thumbnailFit=n.fit),n.format&&(t.thumbnailFormat=n.format)),r&&(r.width&&(t.animatedWidth=r.width),r.height&&(t.animatedHeight=r.height),r.start!==void 0&&(t.animatedStart=r.start),r.end!==void 0&&(t.animatedEnd=r.end),r.fps&&(t.animatedFps=r.fps),r.format&&(t.animatedFormat=r.format)),i&&i.format&&(t.storyboardFormat=i.format)}return e.expiration&&(t.expiration=e.expiration),t}var vC=class{#e;#t;constructor(e,t){this.#e=e,this.#t=t}list(e){let t={};return e?.includeMembers===!1&&(t.includeMembers=`false`),e?.includeFeatures===!1&&(t.includeFeatures=`false`),e?.organizationId&&(t.organizationId=e.organizationId),e?.onlyExplicitMembership&&(t.onlyExplicitMembership=`true`),OS(this.#e,this.#t,{uri:`/projects`,query:t})}getById(e){return OS(this.#e,this.#t,{uri:`/projects/${e}`})}},yC=class{#e;#t;constructor(e,t){this.#e=e,this.#t=t}list(e){let t={};return e?.includeMembers===!1&&(t.includeMembers=`false`),e?.includeFeatures===!1&&(t.includeFeatures=`false`),e?.organizationId&&(t.organizationId=e.organizationId),e?.onlyExplicitMembership&&(t.onlyExplicitMembership=`true`),$(OS(this.#e,this.#t,{uri:`/projects`,query:t}))}getById(e){return $(OS(this.#e,this.#t,{uri:`/projects/${e}`}))}},bC=Tb(`abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789`,8),xC=(e,t)=>t?bb(e,t):yb(e);function SC(e,{releaseId:t,publishedId:n,document:r}){if(n&&r._id){let e=xC(n,t);return ox(e,r),e}if(r._id){let n=_b(r._id),i=vb(r._id);if(!n&&!i)throw Error(`\`${e}()\` requires a document with an \`_id\` that is a version or draft ID`);if(t){if(n)throw Error(`\`${e}()\` was called with a document ID (\`${r._id}\`) that is a draft ID, but a release ID (\`${t}\`) was also provided.`);let i=xb(r._id);if(i!==t)throw Error(`\`${e}()\` was called with a document ID (\`${r._id}\`) that is a version ID, but the release ID (\`${t}\`) does not match the document's version ID (\`${i}\`).`)}return r._id}if(n)return xC(n,t);throw Error(`\`${e}()\` requires either a publishedId or a document with an \`_id\``)}var CC=(e,t)=>{if(typeof e==`object`&&e&&(`releaseId`in e||`metadata`in e)){let{releaseId:n=bC(),metadata:r={}}=e;return[n,r,t]}return[bC(),{},e]},wC=(e,t)=>{let[n,r,i]=CC(e,t);return{action:{actionType:`sanity.action.release.create`,releaseId:n,metadata:{...r,releaseType:r.releaseType||`undecided`}},options:i}},TC=class{#e;#t;constructor(e,t){this.#e=e,this.#t=t}get({releaseId:e},t){return aS(this.#e,this.#t,`_.releases.${e}`,t)}create(e,t){let{action:n,options:r}=wC(e,t),{releaseId:i,metadata:a}=n;return _S(this.#e,this.#t,n,r).pipe(Vy(e=>({...e,releaseId:i,metadata:a})))}edit({releaseId:e,patch:t},n){let r={actionType:`sanity.action.release.edit`,releaseId:e,patch:t};return _S(this.#e,this.#t,r,n)}publish({releaseId:e},t){let n={actionType:`sanity.action.release.publish`,releaseId:e};return _S(this.#e,this.#t,n,t)}archive({releaseId:e},t){let n={actionType:`sanity.action.release.archive`,releaseId:e};return _S(this.#e,this.#t,n,t)}unarchive({releaseId:e},t){let n={actionType:`sanity.action.release.unarchive`,releaseId:e};return _S(this.#e,this.#t,n,t)}schedule({releaseId:e,publishAt:t},n){let r={actionType:`sanity.action.release.schedule`,releaseId:e,publishAt:t};return _S(this.#e,this.#t,r,n)}unschedule({releaseId:e},t){let n={actionType:`sanity.action.release.unschedule`,releaseId:e};return _S(this.#e,this.#t,n,t)}delete({releaseId:e},t){let n={actionType:`sanity.action.release.delete`,releaseId:e};return _S(this.#e,this.#t,n,t)}fetchDocuments({releaseId:e},t){return sS(this.#e,this.#t,e,t)}},EC=class{#e;#t;constructor(e,t){this.#e=e,this.#t=t}get({releaseId:e},t){return $(aS(this.#e,this.#t,`_.releases.${e}`,t))}async create(e,t){let{action:n,options:r}=wC(e,t),{releaseId:i,metadata:a}=n;return{...await $(_S(this.#e,this.#t,n,r)),releaseId:i,metadata:a}}edit({releaseId:e,patch:t},n){let r={actionType:`sanity.action.release.edit`,releaseId:e,patch:t};return $(_S(this.#e,this.#t,r,n))}publish({releaseId:e},t){let n={actionType:`sanity.action.release.publish`,releaseId:e};return $(_S(this.#e,this.#t,n,t))}archive({releaseId:e},t){let n={actionType:`sanity.action.release.archive`,releaseId:e};return $(_S(this.#e,this.#t,n,t))}unarchive({releaseId:e},t){let n={actionType:`sanity.action.release.unarchive`,releaseId:e};return $(_S(this.#e,this.#t,n,t))}schedule({releaseId:e,publishAt:t},n){let r={actionType:`sanity.action.release.schedule`,releaseId:e,publishAt:t};return $(_S(this.#e,this.#t,r,n))}unschedule({releaseId:e},t){let n={actionType:`sanity.action.release.unschedule`,releaseId:e};return $(_S(this.#e,this.#t,n,t))}delete({releaseId:e},t){let n={actionType:`sanity.action.release.delete`,releaseId:e};return $(_S(this.#e,this.#t,n,t))}fetchDocuments({releaseId:e},t){return $(sS(this.#e,this.#t,e,t))}},DC=class{#e;#t;constructor(e,t){this.#e=e,this.#t=t}getById(e){return OS(this.#e,this.#t,{uri:`/users/${e}`})}},OC=class{#e;#t;constructor(e,t){this.#e=e,this.#t=t}getById(e){return $(OS(this.#e,this.#t,{uri:`/users/${e}`}))}},kC=class e{assets;datasets;live;mediaLibrary;projects;users;agent;releases;#e;#t;#n;listen=eC;constructor(e,t=wx){this.config(t),this.#t=e;let n=t._requestHandler;this.#n=n?(()=>{let r;return(i,a)=>{let o=i;return r||=new AC(e,{...t,_requestHandler:void 0}),n(o,t=>e(t,a),r)}})():e,this.assets=new HS(this,this.#n),this.datasets=new sC(this,this.#n),this.live=new iC(this),this.mediaLibrary={video:new dC(this,this.#n)},this.projects=new vC(this,this.#n),this.users=new DC(this,this.#n),this.agent={action:new BS(this,this.#n)},this.releases=new TC(this,this.#n)}clone(){return new e(this.#t,this.config())}config(e){if(e===void 0)return{...this.#e};if(this.#e&&this.#e.allowReconfigure===!1)throw Error("Existing client instance cannot be reconfigured - use `withConfig(newConfig)` to return a new client");return this.#e=kx(e,this.#e||{}),this}withConfig(t){let n=this.config();return new e(this.#t,{...n,...t,stega:{...n.stega||{},...typeof t?.stega==`boolean`?{enabled:t.stega}:t?.stega||{}}})}fetch(e,t,n){return iS(this,this.#n,this.#e.stega,e,t,n)}getDocument(e,t){if(t?.includeAllVersions===!0)return aS(this,this.#n,e,{...t,includeAllVersions:!0});let n={signal:t?.signal,tag:t?.tag,releaseId:t?.releaseId,...t&&`includeAllVersions`in t?{includeAllVersions:!1}:{}};return aS(this,this.#n,e,n)}getDocuments(e,t){return oS(this,this.#n,e,t)}create(e,t){return yS(this,this.#n,e,`create`,t)}createIfNotExists(e,t){return cS(this,this.#n,e,t)}createOrReplace(e,t){return lS(this,this.#n,e,t)}createVersion({document:e,publishedId:t,releaseId:n,baseId:r,ifBaseRevisionId:i},a){if(!e)return dS(this,this.#n,t,r,n,i,a);let o=SC(`createVersion`,{document:e,publishedId:t,releaseId:n}),s={...e,_id:o},c=t||Sb(e._id);return uS(this,this.#n,s,c,a)}delete(e,t){return fS(this,this.#n,e,t)}discardVersion({releaseId:e,publishedId:t},n,r){let i=xC(t,e);return pS(this,this.#n,i,n,r)}replaceVersion({document:e,publishedId:t,releaseId:n},r){let i=SC(`replaceVersion`,{document:e,publishedId:t,releaseId:n}),a={...e,_id:i};return mS(this,this.#n,a,r)}unpublishVersion({releaseId:e,publishedId:t},n){let r=bb(t,e);return hS(this,this.#n,r,t,n)}mutate(e,t){return gS(this,this.#n,e,t)}patch(e,t){return new Ux(e,t,this)}transaction(e){return new Jx(e,this)}action(e,t){return _S(this,this.#n,e,t)}request(e){return OS(this,this.#n,e)}getUrl(e,t){return AS(this,e,t)}getDataUrl(e,t){return kS(this,e,t)}},AC=class e{assets;datasets;live;mediaLibrary;projects;users;agent;releases;observable;#e;#t;#n;listen=eC;constructor(t,n=wx){this.config(n),this.#t=t;let r=n._requestHandler;this.#n=r?(()=>{let i;return(a,o)=>{let s=a;return i||=new e(t,{...n,_requestHandler:void 0}),r(s,e=>t(e,o),i)}})():t,this.assets=new US(this,this.#n),this.datasets=new cC(this,this.#n),this.live=new iC(this),this.mediaLibrary={video:new fC(this,this.#n)},this.projects=new yC(this,this.#n),this.users=new OC(this,this.#n),this.agent={action:new VS(this,this.#n)},this.releases=new EC(this,this.#n),this.observable=new kC(t,n)}clone(){return new e(this.#t,this.config())}config(e){if(e===void 0)return{...this.#e};if(this.#e&&this.#e.allowReconfigure===!1)throw Error("Existing client instance cannot be reconfigured - use `withConfig(newConfig)` to return a new client");return this.observable&&this.observable.config(e),this.#e=kx(e,this.#e||{}),this}withConfig(t){let n=this.config();return new e(this.#t,{...n,...t,stega:{...n.stega||{},...typeof t?.stega==`boolean`?{enabled:t.stega}:t?.stega||{}}})}fetch(e,t,n){return $(iS(this,this.#n,this.#e.stega,e,t,n))}getDocument(e,t){if(t?.includeAllVersions===!0)return $(aS(this,this.#n,e,{...t,includeAllVersions:!0}));let n={signal:t?.signal,tag:t?.tag,releaseId:t?.releaseId,...t&&`includeAllVersions`in t?{includeAllVersions:!1}:{}};return $(aS(this,this.#n,e,n))}getDocuments(e,t){return $(oS(this,this.#n,e,t))}create(e,t){return $(yS(this,this.#n,e,`create`,t))}createIfNotExists(e,t){return $(cS(this,this.#n,e,t))}createOrReplace(e,t){return $(lS(this,this.#n,e,t))}createVersion({document:e,publishedId:t,releaseId:n,baseId:r,ifBaseRevisionId:i},a){if(!e)return zy(dS(this,this.#n,t,r,n,i,a));let o=SC(`createVersion`,{document:e,publishedId:t,releaseId:n}),s={...e,_id:o},c=t||Sb(e._id);return zy(uS(this,this.#n,s,c,a))}delete(e,t){return $(fS(this,this.#n,e,t))}discardVersion({releaseId:e,publishedId:t},n,r){let i=xC(t,e);return $(pS(this,this.#n,i,n,r))}replaceVersion({document:e,publishedId:t,releaseId:n},r){let i=SC(`replaceVersion`,{document:e,publishedId:t,releaseId:n}),a={...e,_id:i};return zy(mS(this,this.#n,a,r))}unpublishVersion({releaseId:e,publishedId:t},n){let r=bb(t,e);return $(hS(this,this.#n,r,t,n))}mutate(e,t){return $(gS(this,this.#n,e,t))}patch(e,t){return new Wx(e,t,this)}transaction(e){return new qx(e,this)}action(e,t){return $(_S(this,this.#n,e,t))}request(e){return $(OS(this,this.#n,e))}dataRequest(e,t,n){return $(vS(this,this.#n,e,t,n))}getUrl(e,t){return AS(this,e,t)}getDataUrl(e,t){return kS(this,e,t)}};function jC(e,t){return{requester:Kb(e),createClient:n=>{let r=Kb(e,{ignoreWarnings:n.ignoreWarnings});return new t((e,t)=>(t||r)({maxRedirects:0,maxRetries:n.maxRetries,retryDelay:n.retryDelay,lineage:n.lineage,...e}),n)}}}var MC=jC([],AC);MC.requester;var NC=MC.createClient,PC=`image-Tb9Ew8CXIwaY6R1kjMvI0uRR-2000x3000-jpg`;function FC(e){let[,t,n,r]=e.split(`-`);if(!t||!n||!r)throw Error(`Malformed asset _ref '${e}'. Expected an id like "${PC}".`);let[i,a]=n.split(`x`),o=+i,s=+a;if(!(isFinite(o)&&isFinite(s)))throw Error(`Malformed asset _ref '${e}'. Expected an id like "${PC}".`);return{id:t,width:o,height:s,format:r}}var IC=e=>{let t=e;return t?typeof t._ref==`string`:!1},LC=e=>{let t=e;return t?typeof t._id==`string`:!1},RC=e=>{let t=e;return t&&t.asset?typeof t.asset.url==`string`:!1},zC=e=>{if(typeof e==`object`&&e){let t=e;return t._upload&&(!t.asset||!t.asset._ref)}return!1};function BC(e){if(!e)return null;let t;if(typeof e==`string`&&VC(e))t={asset:{_ref:HC(e)}};else if(typeof e==`string`)t={asset:{_ref:e}};else if(IC(e))t={asset:e};else if(LC(e))t={asset:{_ref:e._id||``}};else if(RC(e))t={asset:{_ref:HC(e.asset.url)}};else if(typeof e.asset==`object`)t={...e};else return null;let n=e;return n.crop&&(t.crop=n.crop),n.hotspot&&(t.hotspot=n.hotspot),UC(t)}function VC(e){return/^https?:\/\//.test(`${e}`)}function HC(e){return`image-${e.split(`/`).slice(-1)[0]}`.replace(/\.([a-z]+)$/,`-$1`)}function UC(e){if(e.crop&&e.hotspot)return e;let t={...e};return t.crop||={left:0,top:0,bottom:0,right:0},t.hotspot||={x:.5,y:.5,height:1,width:1},t}var WC=[[`width`,`w`],[`height`,`h`],[`format`,`fm`],[`download`,`dl`],[`blur`,`blur`],[`sharpen`,`sharp`],[`invert`,`invert`],[`orientation`,`or`],[`minHeight`,`min-h`],[`maxHeight`,`max-h`],[`minWidth`,`min-w`],[`maxWidth`,`max-w`],[`quality`,`q`],[`fit`,`fit`],[`crop`,`crop`],[`saturation`,`sat`],[`auto`,`auto`],[`dpr`,`dpr`],[`pad`,`pad`],[`frame`,`frame`]];function GC(e){let t={...e||{}},n=t.source;delete t.source;let r=BC(n);if(!r){if(n&&zC(n))return`data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAQAAAC1HAwCAAAAC0lEQVR42mP8HwQACfsD/QNViZkAAAAASUVORK5CYII=`;throw Error(`Unable to resolve image URL from source (${JSON.stringify(n)})`)}let i=FC(r.asset._ref||r.asset._id||``),a=Math.round(r.crop.left*i.width),o=Math.round(r.crop.top*i.height),s={left:a,top:o,width:Math.round(i.width-r.crop.right*i.width-a),height:Math.round(i.height-r.crop.bottom*i.height-o)},c=r.hotspot.height*i.height/2,l=r.hotspot.width*i.width/2,u=r.hotspot.x*i.width,d=r.hotspot.y*i.height,f={left:u-l,top:d-c,right:u+l,bottom:d+c};return t.rect||t.focalPoint||t.ignoreImageParams||t.crop||(t={...t,...qC({crop:s,hotspot:f},t)}),KC({...t,asset:i})}function KC(e){let t=(e.baseUrl||`https://cdn.sanity.io`).replace(/\/+$/,``),n=e.vanityName?`/${e.vanityName}`:``,r=`${e.asset.id}-${e.asset.width}x${e.asset.height}.${e.asset.format}${n}`,i;i=e.mediaLibraryId?`${t}/media-libraries/${e.mediaLibraryId}/images/${r}`:e.canvasId?`${t}/images/canvases/${e.canvasId}/${r}`:`${t}/images/${e.projectId}/${e.dataset}/${r}`;let a=[];if(e.rect){let{left:t,top:n,width:r,height:i}=e.rect;(t!==0||n!==0||i!==e.asset.height||r!==e.asset.width)&&a.push(`rect=${t},${n},${r},${i}`)}e.bg&&a.push(`bg=${e.bg}`),e.focalPoint&&(a.push(`fp-x=${e.focalPoint.x}`),a.push(`fp-y=${e.focalPoint.y}`));let o=[e.flipHorizontal&&`h`,e.flipVertical&&`v`].filter(Boolean).join(``);return o&&a.push(`flip=${o}`),WC.forEach(t=>{let[n,r]=t;typeof e[n]<`u`?a.push(`${r}=${encodeURIComponent(e[n])}`):typeof e[r]<`u`&&a.push(`${r}=${encodeURIComponent(e[r])}`)}),a.length===0?i:`${i}?${a.join(`&`)}`}function qC(e,t){let n,r=t.width,i=t.height;if(!(r&&i))return{width:r,height:i,rect:e.crop};let a=e.crop,o=e.hotspot,s=r/i;if(a.width/a.height>s){let e=Math.round(a.height),t=Math.round(e*s),r=Math.max(0,Math.round(a.top)),i=Math.round((o.right-o.left)/2+o.left),c=Math.max(0,Math.round(i-t/2));c<a.left?c=a.left:c+t>a.left+a.width&&(c=a.left+a.width-t),n={left:c,top:r,width:t,height:e}}else{let e=a.width,t=Math.round(e/s),r=Math.max(0,Math.round(a.left)),i=Math.round((o.bottom-o.top)/2+o.top),c=Math.max(0,Math.round(i-t/2));c<a.top?c=a.top:c+t>a.top+a.height&&(c=a.top+a.height-t),n={left:r,top:c,width:e,height:t}}return{width:r,height:i,rect:n}}var JC=[`clip`,`crop`,`fill`,`fillmax`,`max`,`scale`,`min`],YC=[`top`,`bottom`,`left`,`right`,`center`,`focalpoint`,`entropy`],XC=[`format`];function ZC(e){return e&&`config`in e?typeof e.config==`function`:!1}function QC(e){return e&&`clientConfig`in e?typeof e.clientConfig==`object`:!1}function $C(e){let{apiHost:t,projectId:n,dataset:r}=e,i={baseUrl:(t||`https://api.sanity.io`).replace(/^https:\/\/api\./,`https://cdn.`)},a=e.resource??e[`~experimental_resource`];if(a?.type===`media-library`){if(typeof a.id!=`string`||a.id.length===0)throw Error(`Media library clients must include an id in "resource"`);return{...i,mediaLibraryId:a.id}}if(a?.type===`canvas`){if(typeof a.id!=`string`||a.id.length===0)throw Error(`Canvas clients must include an id in "resource"`);return{...i,canvasId:a.id}}if(a?.type===`dataset`){if(typeof a.id!=`string`||a.id.length===0)throw Error(`Dataset clients must include an id in "resource"`);let[e,t]=a.id.split(`.`);if(!e||!t)throw Error(`Dataset resource id must be in the format "projectId.dataset", got: `+a.id);return{...i,projectId:e,dataset:t}}return{...i,projectId:n,dataset:r}}function ew(e){let t=WC;for(let n of t){let[t,r]=n;if(e===t||e===r)return t}return e}function tw(e){let t={};return t=ZC(e)?$C(e.config()):QC(e)?$C(e.clientConfig):e||{},t}function nw(e,t){return new e(null,tw(t))}function rw(e){return nw(aw,e)}function iw(e,t){let n=t.baseUrl||e.baseUrl,r={baseUrl:n};for(let e in t)if(t.hasOwnProperty(e)){let n=ew(e);r[n]=t[e]}return{baseUrl:n,...r}}var aw=class e{options;constructor(e,t){this.options=e?{...e.options||{},...t||{}}:{...t||{}}}withOptions(t){let n=iw(this.options,t);return new e(this,n)}image(e){return this.withOptions({source:e})}dataset(e){return this.withOptions({dataset:e})}projectId(e){return this.withOptions({projectId:e})}withClient(t){let n=tw(t),r={...this.options};return delete r.baseUrl,delete r.projectId,delete r.dataset,delete r.mediaLibraryId,delete r.canvasId,new e(null,{...n,...r})}bg(e){return this.withOptions({bg:e})}dpr(e){return this.withOptions(e&&e!==1?{dpr:e}:{})}width(e){return this.withOptions({width:e})}height(e){return this.withOptions({height:e})}focalPoint(e,t){return this.withOptions({focalPoint:{x:e,y:t}})}maxWidth(e){return this.withOptions({maxWidth:e})}minWidth(e){return this.withOptions({minWidth:e})}maxHeight(e){return this.withOptions({maxHeight:e})}minHeight(e){return this.withOptions({minHeight:e})}size(e,t){return this.withOptions({width:e,height:t})}blur(e){return this.withOptions({blur:e})}sharpen(e){return this.withOptions({sharpen:e})}rect(e,t,n,r){return this.withOptions({rect:{left:e,top:t,width:n,height:r}})}format(e){return this.withOptions({format:e})}invert(e){return this.withOptions({invert:e})}orientation(e){return this.withOptions({orientation:e})}quality(e){return this.withOptions({quality:e})}forceDownload(e){return this.withOptions({download:e})}flipHorizontal(){return this.withOptions({flipHorizontal:!0})}flipVertical(){return this.withOptions({flipVertical:!0})}ignoreImageParams(){return this.withOptions({ignoreImageParams:!0})}fit(e){if(JC.indexOf(e)===-1)throw Error(`Invalid fit mode "${e}"`);return this.withOptions({fit:e})}crop(e){if(YC.indexOf(e)===-1)throw Error(`Invalid crop mode "${e}"`);return this.withOptions({crop:e})}saturation(e){return this.withOptions({saturation:e})}auto(e){if(XC.indexOf(e)===-1)throw Error(`Invalid auto mode "${e}"`);return this.withOptions({auto:e})}pad(e){return this.withOptions({pad:e})}vanityName(e){return this.withOptions({vanityName:e})}frame(e){if(e!==1)throw Error(`Invalid frame value "${e}"`);return this.withOptions({frame:e})}url(){return GC(this.options)}toString(){return this.url()}};function ow(e){let t=!1,n;return(...r)=>(t||=(n=e(...r),!0),n)}(e=>ow((...t)=>{console.warn(e.join(` `),...t)}))(["The default export of @sanity/image-url has been deprecated. Use the named export `createImageUrlBuilder` instead."]);var sw=NC({projectId:`f1tnubeb`,dataset:`production`,useCdn:!0,apiVersion:`2024-03-01`}),cw=rw(sw);function lw(e){return cw.image(e)}async function uw(){return sw.fetch(`*[_type == "post"] | order(publishedAt desc) {
    _id,
    title,
    slug,
    author->{name},
    mainImage,
    publishedAt,
    "categories": categories[]->{title},
    body,
    seo
  }`)}async function dw(e){return sw.fetch(`*[_type == "post" && slug.current == $slug][0] {
    _id,
    title,
    slug,
    author->{name},
    mainImage,
    publishedAt,
    "categories": categories[]->{title},
    body,
    seo
  }`,{slug:e})}var fw=e=>{let t=(0,P.c)(35),{post:n}=e,r;t[0]===n.mainImage?r=t[1]:(r=n.mainImage?lw(n.mainImage).width(800).height(500).url():``,t[0]=n.mainImage,t[1]=r);let i=r,a=`/blogs/${n.slug.current}`,o;t[2]!==i||t[3]!==n.title?(o=(0,q.jsx)(`div`,{className:`relative w-full aspect-[16/10] overflow-hidden bg-zinc-50`,children:i?(0,q.jsx)(`img`,{src:i,alt:n.title,className:`absolute inset-0 w-full h-full object-cover transition-transform duration-700 group-hover:scale-105`}):(0,q.jsx)(`div`,{className:`absolute inset-0 bg-gradient-to-br from-zinc-100 to-zinc-200`})}),t[2]=i,t[3]=n.title,t[4]=o):o=t[4];let s=n.categories?.[0]?.title??`Engineering`,c;t[5]===s?c=t[6]:(c=(0,q.jsx)(`span`,{className:`text-xs font-bold uppercase tracking-widest text-indigo-600`,children:s}),t[5]=s,t[6]=c);let l;t[7]===Symbol.for(`react.memo_cache_sentinel`)?(l=(0,q.jsx)(`span`,{className:`w-1 h-1 rounded-full bg-zinc-300`}),t[7]=l):l=t[7];let u=n.publishedAt,d;t[8]===n.publishedAt?d=t[9]:(d=new Date(n.publishedAt).toLocaleDateString(`en-US`,{month:`short`,day:`numeric`,year:`numeric`}),t[8]=n.publishedAt,t[9]=d);let f;t[10]!==n.publishedAt||t[11]!==d?(f=(0,q.jsx)(`time`,{className:`text-xs font-medium text-zinc-500`,dateTime:u,children:d}),t[10]=n.publishedAt,t[11]=d,t[12]=f):f=t[12];let p;t[13]!==c||t[14]!==f?(p=(0,q.jsxs)(`div`,{className:`flex items-center gap-2 mb-4`,children:[c,l,f]}),t[13]=c,t[14]=f,t[15]=p):p=t[15];let m;t[16]===n.title?m=t[17]:(m=(0,q.jsx)(`h3`,{className:`text-xl md:text-2xl font-black tracking-tight text-zinc-900 leading-tight mb-4 group-hover:text-indigo-600 transition-colors`,children:n.title}),t[16]=n.title,t[17]=m);let h=n.author?.name?n.author.name[0]:`C`,g;t[18]===h?g=t[19]:(g=(0,q.jsx)(`div`,{className:`w-8 h-8 rounded-full bg-gradient-to-tr from-indigo-500 to-purple-500 flex items-center justify-center text-white font-bold text-xs`,children:h}),t[18]=h,t[19]=g);let _=n.author?.name??`CautionLabs Team`,v;t[20]===_?v=t[21]:(v=(0,q.jsx)(`span`,{className:`text-sm font-semibold text-zinc-700`,children:_}),t[20]=_,t[21]=v);let y;t[22]!==g||t[23]!==v?(y=(0,q.jsxs)(`div`,{className:`mt-auto flex items-center gap-3`,children:[g,v]}),t[22]=g,t[23]=v,t[24]=y):y=t[24];let b;t[25]!==p||t[26]!==m||t[27]!==y?(b=(0,q.jsxs)(`div`,{className:`flex flex-col flex-grow p-6 md:p-8`,children:[p,m,y]}),t[25]=p,t[26]=m,t[27]=y,t[28]=b):b=t[28];let x;t[29]!==b||t[30]!==o?(x=(0,q.jsxs)(`article`,{className:`flex flex-col h-full bg-white rounded-2xl border border-zinc-100 overflow-hidden hover:shadow-2xl hover:shadow-black/5 transition-all duration-300 transform group-hover:-translate-y-2`,children:[o,b]}),t[29]=b,t[30]=o,t[31]=x):x=t[31];let S;return t[32]!==x||t[33]!==a?(S=(0,q.jsx)(Pa,{to:a,className:`group block focus:outline-none focus:ring-4 focus:ring-indigo-500/20 rounded-2xl`,children:x}),t[32]=x,t[33]=a,t[34]=S):S=t[34],S},pw=()=>{let[e,t]=(0,g.useState)([]),[n,r]=(0,g.useState)(!0);return(0,g.useEffect)(()=>{(async()=>{try{t(await uw())}catch(e){console.error(`Failed to fetch blogs:`,e)}finally{r(!1)}})()},[]),(0,q.jsxs)(`div`,{className:`min-h-[calc(100vh-80px)] bg-white text-black py-16 md:py-24`,children:[(0,q.jsxs)(Ie,{children:[(0,q.jsx)(`title`,{children:`Insights & Engineering | CautionLabs`}),(0,q.jsx)(`meta`,{name:`description`,content:`Deep dives into AI moderation, product strategy, and engineering practices by the CautionLabs team.`}),(0,q.jsx)(`link`,{rel:`canonical`,href:`https://cautionlabs.com/blogs`}),(0,q.jsx)(`meta`,{property:`og:type`,content:`website`}),(0,q.jsx)(`meta`,{property:`og:url`,content:`https://cautionlabs.com/blogs`}),(0,q.jsx)(`meta`,{property:`og:title`,content:`Insights & Engineering | CautionLabs`}),(0,q.jsx)(`meta`,{property:`og:description`,content:`Deep dives into AI moderation, product strategy, and engineering practices by the CautionLabs team.`}),(0,q.jsx)(`meta`,{property:`og:image`,content:`https://cautionlabs.com/og-image.png`}),(0,q.jsx)(`meta`,{name:`twitter:card`,content:`summary_large_image`}),(0,q.jsx)(`meta`,{name:`twitter:title`,content:`Insights & Engineering | CautionLabs`}),(0,q.jsx)(`meta`,{name:`twitter:description`,content:`Deep dives into AI moderation, product strategy, and engineering practices by the CautionLabs team.`}),(0,q.jsx)(`meta`,{name:`twitter:image`,content:`https://cautionlabs.com/og-image.png`})]}),(0,q.jsxs)(`div`,{className:`max-w-7xl mx-auto px-6`,children:[(0,q.jsxs)(`div`,{className:`mb-16 md:mb-24 text-center max-w-3xl mx-auto`,children:[(0,q.jsxs)(`h1`,{className:`text-5xl md:text-7xl font-black tracking-tighter mb-6 leading-none`,children:[`Insights & `,(0,q.jsx)(`br`,{className:`hidden md:block`}),` Engineering`]}),(0,q.jsx)(`p`,{className:`text-lg md:text-xl text-zinc-500 font-medium leading-relaxed`,children:`Thoughts on building scalable moderation systems, AI safety, and modern software architecture.`})]}),n?(0,q.jsx)(`div`,{className:`grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-8 md:gap-12 animate-pulse`,children:[1,2,3,4,5,6].map(e=>(0,q.jsx)(`div`,{className:`aspect-[3/4] bg-zinc-100 rounded-2xl`},e))}):(0,q.jsx)(`div`,{className:`grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-8 md:gap-12`,children:e.map(e=>(0,q.jsx)(fw,{post:e},e._id))}),!n&&e.length===0&&(0,q.jsx)(`div`,{className:`text-center py-20`,children:(0,q.jsx)(`h3`,{className:`text-2xl font-bold text-zinc-400`,children:`No blogs found.`})})]})]})};function mw(e){return e._type===`span`&&`text`in e&&typeof e.text==`string`&&(e.marks===void 0||Array.isArray(e.marks)&&e.marks.every(e=>typeof e==`string`))}function hw(e){return typeof e._type==`string`&&e._type[0]!==`@`&&(!(`markDefs`in e)||!e.markDefs||Array.isArray(e.markDefs)&&e.markDefs.every(e=>typeof e._key==`string`))&&`children`in e&&Array.isArray(e.children)&&e.children.every(e=>typeof e==`object`&&`_type`in e)}function gw(e){return hw(e)&&`listItem`in e&&typeof e.listItem==`string`&&(e.level===void 0||typeof e.level==`number`)}function _w(e){return e._type===`@list`}function vw(e){return e._type===`@span`}function yw(e){return e._type===`@text`}var bw=[`strong`,`em`,`code`,`underline`,`strike-through`];function xw(e,t,n){if(!mw(e)||!e.marks||!e.marks.length)return[];let r=e.marks.slice(),i={};return r.forEach(e=>{i[e]=1;for(let r=t+1;r<n.length;r++){let t=n[r];if(t&&mw(t)&&Array.isArray(t.marks)&&t.marks.indexOf(e)!==-1)i[e]++;else break}}),r.sort((e,t)=>Sw(i,e,t))}function Sw(e,t,n){let r=e[t],i=e[n];if(r!==i)return i-r;let a=bw.indexOf(t),o=bw.indexOf(n);return a===o?t.localeCompare(n):a-o}function Cw(e){let{children:t}=e,n=e.markDefs??[];if(!t||!t.length)return[];let r=t.map(xw),i={_type:`@span`,children:[],markType:`<unknown>`},a=[i];for(let e=0;e<t.length;e++){let i=t[e];if(!i)continue;let o=r[e]||[],s=1;if(a.length>1)for(;s<a.length;s++){let e=a[s]?.markKey||``,t=o.indexOf(e);if(t===-1)break;o.splice(t,1)}a=a.slice(0,s);let c=a[a.length-1];if(c){for(let e of o){let t=n?.find(t=>t._key===e),r={_type:`@span`,_key:i._key,children:[],markDef:t,markType:t?t._type:e,markKey:e};c.children.push(r),a.push(r),c=r}if(mw(i)){let e=i.text.split(`
`);for(let t=e.length;t-- >1;)e.splice(t,0,`
`);c.children=c.children.concat(e.map(e=>({_type:`@text`,text:e})))}else c.children=c.children.concat(i)}}return i.children}function ww(e,t){let n=[],r;for(let i=0;i<e.length;i++){let a=e[i];if(a){if(!gw(a)){n.push(a),r=void 0;continue}if(!r){r=Ew(a,i,t),n.push(r);continue}if(Tw(a,r)){r.children.push(a);continue}if((a.level||1)>r.level){let e=Ew(a,i,t);if(t===`html`){let t=r.children[r.children.length-1],n={...t,children:[...t.children,e]};r.children[r.children.length-1]=n}else r.children.push(e);r=e;continue}if((a.level||1)<r.level){let e=n[n.length-1],o=e&&Dw(e,a);if(o){r=o,r.children.push(a);continue}r=Ew(a,i,t),n.push(r);continue}if(a.listItem!==r.listItem){let e=n[n.length-1],o=e&&Dw(e,{level:a.level||1});if(o&&o.listItem===a.listItem){r=o,r.children.push(a);continue}else{r=Ew(a,i,t),n.push(r);continue}}console.warn(`Unknown state encountered for block`,a),n.push(a)}}return n}function Tw(e,t){return(e.level||1)===t.level&&e.listItem===t.listItem}function Ew(e,t,n){return{_type:`@list`,_key:`${e._key||`${t}`}-parent`,mode:n,level:e.level||1,listItem:e.listItem,children:[e]}}function Dw(e,t){let n=t.level||1,r=t.listItem||`normal`,i=typeof t.listItem==`string`;if(_w(e)&&(e.level||1)===n&&i&&(e.listItem||`normal`)===r)return e;if(!(`children`in e))return;let a=e.children[e.children.length-1];return a&&!mw(a)?Dw(a,t):void 0}function Ow(e){let t=``;return e.children.forEach(e=>{yw(e)?t+=e.text:vw(e)&&(t+=Ow(e))}),t}var kw={number:({children:e})=>(0,q.jsx)(`ol`,{children:e}),bullet:({children:e})=>(0,q.jsx)(`ul`,{children:e})},Aw=({children:e})=>(0,q.jsx)(`li`,{children:e}),jw=({children:e,value:t})=>(0,q.jsx)(`a`,{href:t?.href,children:e}),Mw={textDecoration:`underline`},Nw={em:({children:e})=>(0,q.jsx)(`em`,{children:e}),strong:({children:e})=>(0,q.jsx)(`strong`,{children:e}),code:({children:e})=>(0,q.jsx)(`code`,{children:e}),underline:({children:e})=>(0,q.jsx)(`span`,{style:Mw,children:e}),"strike-through":({children:e})=>(0,q.jsx)(`del`,{children:e}),link:jw},Pw=(e,t)=>`[@portabletext/react] Unknown ${e}, specify a component for it in the \`components.${t}\` prop`,Fw=e=>Pw(`block type "${e}"`,`types`),Iw=e=>Pw(`mark type "${e}"`,`marks`),Lw=e=>Pw(`block style "${e}"`,`block`),Rw=e=>Pw(`list style "${e}"`,`list`),zw=e=>Pw(`list item style "${e}"`,`listItem`);function Bw(e){console.warn(e)}var Vw={display:`none`},Hw={types:{},block:{normal:({children:e})=>(0,q.jsx)(`p`,{children:e}),blockquote:({children:e})=>(0,q.jsx)(`blockquote`,{children:e}),h1:({children:e})=>(0,q.jsx)(`h1`,{children:e}),h2:({children:e})=>(0,q.jsx)(`h2`,{children:e}),h3:({children:e})=>(0,q.jsx)(`h3`,{children:e}),h4:({children:e})=>(0,q.jsx)(`h4`,{children:e}),h5:({children:e})=>(0,q.jsx)(`h5`,{children:e}),h6:({children:e})=>(0,q.jsx)(`h6`,{children:e})},marks:Nw,list:kw,listItem:Aw,hardBreak:()=>(0,q.jsx)(`br`,{}),unknownType:({value:e,isInline:t})=>{let n=Fw(e._type);return(0,q.jsx)(t?`span`:`div`,{style:Vw,children:n})},unknownMark:({markType:e,children:t})=>(0,q.jsx)(`span`,{className:`unknown__pt__mark__${e}`,children:t}),unknownList:({children:e})=>(0,q.jsx)(`ul`,{children:e}),unknownListItem:({children:e})=>(0,q.jsx)(`li`,{children:e}),unknownBlockStyle:({children:e})=>(0,q.jsx)(`p`,{children:e})};function Uw(e,t){let{block:n,list:r,listItem:i,marks:a,types:o,...s}=t;return{...e,block:Ww(e,t,`block`),list:Ww(e,t,`list`),listItem:Ww(e,t,`listItem`),marks:Ww(e,t,`marks`),types:Ww(e,t,`types`),...s}}function Ww(e,t,n){let r=t[n],i=e[n];return typeof r==`function`||r&&typeof i==`function`?r:r?{...i,...r}:i}function Gw({value:e,components:t,listNestingMode:n,onMissingComponent:r=Bw}){let i=r||Jw,a;a=Array.isArray(e)?e:e==null?[]:[e];let o=ww(a,n||`html`),s=(0,g.useMemo)(()=>t?Uw(Hw,t):Hw,[t]),c=(0,g.useMemo)(()=>Kw(s,i),[s,i]);return(0,q.jsx)(q.Fragment,{children:o.map((e,t)=>c({node:e,index:t,isInline:!1,renderNode:c}))})}var Kw=(e,t)=>{function n(e){let{node:t,index:n,isInline:d}=e,f=t._key||`node-${n}`;return _w(t)?a(t,n,f):gw(t)?i(t,n,f):vw(t)?o(t,n,f):r(t)?u(t,n,f,d):hw(t)?s(t,n,f,d):yw(t)?c(t,f):l(t,n,f,d)}function r(t){return t._type in e.types}function i(r,i,a){let o=qw({node:r,index:i,isInline:!1,renderNode:n}),s=e.listItem,c=(typeof s==`function`?s:s[r.listItem])||e.unknownListItem;if(c===e.unknownListItem){let e=r.listItem||`bullet`;t(zw(e),{type:e,nodeType:`listItemStyle`})}let l=o.children;if(r.style&&r.style!==`normal`){let{listItem:e,...t}=r;l=n({node:t,index:i,isInline:!1,renderNode:n})}return(0,q.jsx)(c,{value:r,index:i,isInline:!1,renderNode:n,children:l},a)}function a(r,i,a){let o=r.children.map((e,t)=>n({node:e._key?e:{...e,_key:`li-${i}-${t}`},index:t,isInline:!1,renderNode:n})),s=e.list,c=(typeof s==`function`?s:s[r.listItem])||e.unknownList;if(c===e.unknownList){let e=r.listItem||`bullet`;t(Rw(e),{nodeType:`listStyle`,type:e})}return(0,q.jsx)(c,{value:r,index:i,isInline:!1,renderNode:n,children:o},a)}function o(r,i,a){let{markDef:o,markType:s,markKey:c}=r,l=e.marks[s]||e.unknownMark,u=r.children.map((e,t)=>n({node:e,index:t,isInline:!0,renderNode:n}));return l===e.unknownMark&&t(Iw(s),{nodeType:`mark`,type:s}),(0,q.jsx)(l,{text:Ow(r),value:o,markType:s,markKey:c,renderNode:n,children:u},a)}function s(r,i,a,o){let{_key:s,...c}=qw({node:r,index:i,isInline:o,renderNode:n}),l=c.node.style||`normal`,u=(typeof e.block==`function`?e.block:e.block[l])||e.unknownBlockStyle;return u===e.unknownBlockStyle&&t(Lw(l),{nodeType:`blockStyle`,type:l}),(0,q.jsx)(u,{...c,value:c.node,renderNode:n},a)}function c(t,n){if(t.text===`
`){let t=e.hardBreak;return t?(0,q.jsx)(t,{},n):`
`}return t.text}function l(r,i,a,o){let s={value:r,isInline:o,index:i,renderNode:n};t(Fw(r._type),{nodeType:`block`,type:r._type});let c=e.unknownType;return(0,q.jsx)(c,{...s},a)}function u(t,r,i,a){let o={value:t,isInline:a,index:r,renderNode:n},s=e.types[t._type];return s?(0,q.jsx)(s,{...o},i):null}return n};function qw(e){let{node:t,index:n,isInline:r,renderNode:i}=e,a=Cw(t).map((e,t)=>i({node:e,isInline:!0,index:t,renderNode:i}));return{_key:t._key||`block-${n}`,children:a,index:n,isInline:r,node:t}}function Jw(){}var Yw=ka([{path:`/`,element:(0,q.jsx)(()=>{let e=(0,P.c)(8),t=ai(),n,r;e[0]===t?(n=e[1],r=e[2]):(n=e=>t(e),r=e=>t(e,{replace:!0}),e[0]=t,e[1]=n,e[2]=r);let i,a;e[3]===Symbol.for(`react.memo_cache_sentinel`)?(i=(0,q.jsx)(Ug,{}),a=(0,q.jsx)(Hi,{}),e[3]=i,e[4]=a):(i=e[3],a=e[4]);let o;return e[5]!==n||e[6]!==r?(o=(0,q.jsxs)(K,{publishableKey:`pk_live_Y2xlcmsuY2F1dGlvbmxhYnMuY29tJA`,afterSignOutUrl:`/`,routerPush:n,routerReplace:r,children:[i,a]}),e[5]=n,e[6]=r,e[7]=o):o=e[7],o},{}),children:[{element:(0,q.jsx)(Wg,{}),children:[{path:`/`,element:(0,q.jsx)(t_,{})},{path:`/solutions`,element:(0,q.jsx)(o_,{})},{path:`/solutions/:slug`,element:(0,q.jsx)(a_,{})},{path:`/blogs`,element:(0,q.jsx)(pw,{})},{path:`/blogs/:slug`,element:(0,q.jsx)(()=>{let{slug:e}=li(),[t,n]=(0,g.useState)(null),[r,i]=(0,g.useState)(!0);return(0,g.useEffect)(()=>{(async()=>{if(e)try{n(await dw(e))}catch(e){console.error(`Failed to fetch post:`,e)}finally{i(!1)}})()},[e]),r?(0,q.jsx)(`div`,{className:`min-h screen bg-white py-24 flex items-center justify-center`,children:(0,q.jsx)(`div`,{className:`w-12 h-12 border-4 border-zinc-100 border-t-indigo-600 rounded-full animate-spin`})}):t?(0,q.jsxs)(`article`,{className:`min-h-screen bg-white py-16 md:py-24`,children:[(0,q.jsxs)(Ie,{children:[(0,q.jsx)(`title`,{children:t.title}),(0,q.jsx)(`meta`,{name:`description`,content:t.seo?.metaDescription??t.title}),t.seo?.keywords&&t.seo.keywords.length>0&&(0,q.jsx)(`meta`,{name:`keywords`,content:t.seo.keywords.join(`, `)}),(0,q.jsx)(`link`,{rel:`canonical`,href:`https://cautionlabs.com/blogs/${t.slug.current}`}),(0,q.jsx)(`meta`,{property:`og:type`,content:`article`}),(0,q.jsx)(`meta`,{property:`og:url`,content:`https://cautionlabs.com/blogs/${t.slug.current}`}),(0,q.jsx)(`meta`,{property:`og:title`,content:t.title}),(0,q.jsx)(`meta`,{property:`og:description`,content:t.seo?.metaDescription??t.title}),t.seo?.seoImage?(0,q.jsx)(`meta`,{property:`og:image`,content:lw(t.seo.seoImage).width(1200).url()}):t.mainImage&&(0,q.jsx)(`meta`,{property:`og:image`,content:lw(t.mainImage).width(1200).url()}),(0,q.jsx)(`meta`,{name:`twitter:card`,content:`summary_large_image`}),(0,q.jsx)(`meta`,{name:`twitter:title`,content:t.title}),(0,q.jsx)(`meta`,{name:`twitter:description`,content:t.seo?.metaDescription??t.title}),t.seo?.seoImage?(0,q.jsx)(`meta`,{name:`twitter:image`,content:lw(t.seo.seoImage).width(1200).url()}):t.mainImage&&(0,q.jsx)(`meta`,{name:`twitter:image`,content:lw(t.mainImage).width(1200).url()}),(0,q.jsx)(`script`,{type:`application/ld+json`,children:JSON.stringify({"@context":`https://schema.org`,"@type":`BlogPosting`,headline:t.title,description:t.seo?.metaDescription??t.title,author:{"@type":`Person`,name:t.author?.name??`CautionLabs Team`},publisher:{"@type":`Organization`,name:`Caution Labs`,logo:{"@type":`ImageObject`,url:`https://cautionlabs.com/logo.png`}},datePublished:t.publishedAt,dateModified:t.publishedAt,mainEntityOfPage:{"@type":`WebPage`,"@id":`https://cautionlabs.com/blogs/${t.slug.current}`},keywords:t.seo?.keywords??[],image:t.seo?.seoImage?lw(t.seo.seoImage).width(1200).url():t.mainImage?lw(t.mainImage).width(1200).url():`https://cautionlabs.com/og-image.png`})})]}),(0,q.jsxs)(`div`,{className:`max-w-3xl mx-auto px-6`,children:[(0,q.jsxs)(Pa,{to:`/blogs`,className:`inline-flex items-center gap-2 text-sm font-bold text-zinc-400 hover:text-black transition-colors mb-12 group`,children:[(0,q.jsx)(`span`,{className:`transform group-hover:-translate-x-1 transition-transform`,children:`←`}),`Back to Insights`]}),(0,q.jsxs)(`header`,{className:`mb-12`,children:[(0,q.jsxs)(`div`,{className:`flex items-center gap-3 mb-6`,children:[(0,q.jsx)(`span`,{className:`px-3 py-1 bg-indigo-50 text-indigo-600 text-[10px] font-bold uppercase tracking-widest rounded-full`,children:t.categories?.[0]?.title??`Engineering`}),(0,q.jsx)(`span`,{className:`text-zinc-300 text-xs`,children:`•`}),(0,q.jsx)(`time`,{className:`text-zinc-500 text-xs font-semibold uppercase tracking-wider`,children:new Date(t.publishedAt).toLocaleDateString(`en-US`,{month:`long`,day:`numeric`,year:`numeric`})})]}),(0,q.jsx)(`h1`,{className:`text-4xl md:text-6xl font-black tracking-tighter text-zinc-900 leading-[1.1] mb-8`,children:t.title}),(0,q.jsxs)(`div`,{className:`flex items-center gap-4`,children:[(0,q.jsx)(`div`,{className:`w-12 h-12 rounded-full bg-gradient-to-tr from-indigo-500 to-purple-500 flex items-center justify-center text-white font-bold text-lg`,children:t.author?.name?t.author.name[0]:`C`}),(0,q.jsxs)(`div`,{children:[(0,q.jsx)(`div`,{className:`text-zinc-900 font-bold`,children:t.author?.name??`CautionLabs Team`}),(0,q.jsx)(`div`,{className:`text-zinc-500 text-sm font-medium`,children:`Core Contributor`})]})]})]}),t.mainImage&&(0,q.jsx)(`div`,{className:`relative aspect-[16/9] mb-12 rounded-3xl overflow-hidden shadow-2xl shadow-indigo-500/10`,children:(0,q.jsx)(`img`,{src:lw(t.mainImage).width(1200).url(),alt:t.title,className:`absolute inset-0 w-full h-full object-cover`})}),(0,q.jsx)(`div`,{className:`prose prose-lg prose-zinc max-w-none`,children:(0,q.jsx)(Gw,{value:t.body,components:{block:{h2:({children:e})=>(0,q.jsx)(`h2`,{className:`text-3xl font-black tracking-tight text-zinc-900 mt-16 mb-6`,children:e}),h3:({children:e})=>(0,q.jsx)(`h3`,{className:`text-2xl font-black tracking-tight text-zinc-900 mt-12 mb-4`,children:e}),normal:({children:e})=>(0,q.jsx)(`p`,{className:`text-zinc-600 leading-relaxed mb-6 font-medium`,children:e})},list:{bullet:({children:e})=>(0,q.jsx)(`ul`,{className:`list-disc list-inside mb-8 space-y-3 text-zinc-600 font-medium ml-4`,children:e})}}})}),(0,q.jsx)(`footer`,{className:`mt-24 pt-12 border-t border-zinc-100`,children:(0,q.jsxs)(`div`,{className:`bg-zinc-50 rounded-3xl p-8 md:p-12 text-center`,children:[(0,q.jsx)(`h3`,{className:`text-2xl font-black mb-4`,children:`Want more insights?`}),(0,q.jsx)(`p`,{className:`text-zinc-500 font-medium mb-8`,children:`Stay updated with the latest in AI moderation and platform safety.`}),(0,q.jsx)(Pa,{to:`/blogs`,className:`inline-flex h-14 items-center px-8 bg-black text-white font-bold rounded-full hover:scale-105 transition-transform`,children:`Back to Overview`})]})})]})]}):(0,q.jsxs)(`div`,{className:`min-h-screen bg-white py-24 px-6 text-center`,children:[(0,q.jsx)(`h1`,{className:`text-4xl font-black mb-6`,children:`Post Not Found`}),(0,q.jsx)(Pa,{to:`/blogs`,className:`text-indigo-600 font-bold hover:underline`,children:`← Back to all blogs`})]})},{})},{path:`/api-keys`,element:(0,q.jsx)(m_,{children:(0,q.jsx)(p_,{})})},{path:`*`,element:(0,q.jsx)(()=>{let e=(0,P.c)(7),t;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(t=(0,q.jsxs)(Ie,{children:[(0,q.jsx)(`title`,{children:`404 - Page Not Found | CautionLabs`}),(0,q.jsx)(`meta`,{name:`robots`,content:`noindex, follow`})]}),e[0]=t):t=e[0];let n;e[1]===Symbol.for(`react.memo_cache_sentinel`)?(n=(0,q.jsx)(`div`,{className:`absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2 w-[600px] h-[600px] rounded-full blur-[120px] -z-10`,style:{background:`radial-gradient(circle, rgba(0,0,0,0.03) 0%, transparent 70%)`}}),e[1]=n):n=e[1];let r;e[2]===Symbol.for(`react.memo_cache_sentinel`)?(r=(0,q.jsx)(`div`,{className:`inline-block py-1.5 px-4 border border-black/10 bg-zinc-50 text-[10px] sm:text-xs font-bold tracking-[0.2em] uppercase text-black mb-2 shadow-sm rounded-full`,children:`Error 404`}),e[2]=r):r=e[2];let i,a;e[3]===Symbol.for(`react.memo_cache_sentinel`)?(i=(0,q.jsxs)(`h1`,{className:`text-6xl md:text-8xl lg:text-9xl font-black tracking-tight leading-[1.05] text-black`,children:[`Page Not Found`,(0,q.jsx)(`span`,{className:`text-red-500`,children:`.`})]}),a=(0,q.jsx)(`p`,{className:`text-lg md:text-xl text-zinc-500 max-w-lg mx-auto font-medium leading-relaxed`,children:`The page you are looking for doesn't exist, has been moved, or is temporarily unavailable. Let's get you back on track.`}),e[3]=i,e[4]=a):(i=e[3],a=e[4]);let o;e[5]===Symbol.for(`react.memo_cache_sentinel`)?(o=(0,q.jsx)(Pa,{to:`/`,children:(0,q.jsx)(Fg,{text:`Return to Homepage`,variant:Pg.PRIMARY,size:`lg`})}),e[5]=o):o=e[5];let s;return e[6]===Symbol.for(`react.memo_cache_sentinel`)?(s=(0,q.jsxs)(q.Fragment,{children:[t,(0,q.jsxs)(`section`,{className:`min-h-[80vh] flex flex-col items-center justify-center text-center px-6 bg-white overflow-hidden relative border-b border-zinc-100`,children:[n,(0,q.jsxs)(`div`,{className:`space-y-8 animate-fade-up`,children:[r,i,a,(0,q.jsxs)(`div`,{className:`flex flex-col sm:flex-row items-center justify-center gap-4 pt-8`,children:[o,(0,q.jsx)(Pa,{to:`/solutions`,children:(0,q.jsx)(Fg,{text:`Explore Solutions`,variant:Pg.SECONDARY,size:`lg`})})]})]})]})]}),e[6]=s):s=e[6],s},{})}]}]}]);function Xw(){let e=(0,P.c)(1),t;return e[0]===Symbol.for(`react.memo_cache_sentinel`)?(t=(0,q.jsx)(Qa,{router:Yw}),e[0]=t):t=e[0],t}var Zw=document.getElementById(`root`);if(!Zw)throw Error(`Failed to find the root element`);(0,h.createRoot)(Zw).render((0,q.jsx)(g.StrictMode,{children:(0,q.jsx)(Se,{children:(0,q.jsx)(Xw,{})})}));