78b57273e2
- Add password hashing with bcrypt - Add AuthService with proper login - Add password strength validation - Add RBAC middleware (AdminOnly, ManagerOrAdmin) - Add tenant isolation middleware - Update CRM handler with tenant filtering - Add JWT fallback for development mode - Add user context helpers - Build successful
576 lines
1.0 MiB
Plaintext
576 lines
1.0 MiB
Plaintext
(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))r(i);new MutationObserver(i=>{for(const o of i)if(o.type==="childList")for(const c of o.addedNodes)c.tagName==="LINK"&&c.rel==="modulepreload"&&r(c)}).observe(document,{childList:!0,subtree:!0});function n(i){const o={};return i.integrity&&(o.integrity=i.integrity),i.referrerPolicy&&(o.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?o.credentials="include":i.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function r(i){if(i.ep)return;i.ep=!0;const o=n(i);fetch(i.href,o)}})();var Od=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function at(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var kx={exports:{}},Sc={};/**
|
||
* @license React
|
||
* react-jsx-runtime.production.js
|
||
*
|
||
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
||
*
|
||
* This source code is licensed under the MIT license found in the
|
||
* LICENSE file in the root directory of this source tree.
|
||
*/var i_;function vB(){if(i_)return Sc;i_=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.fragment");function n(r,i,o){var c=null;if(o!==void 0&&(c=""+o),i.key!==void 0&&(c=""+i.key),"key"in i){o={};for(var f in i)f!=="key"&&(o[f]=i[f])}else o=i;return i=o.ref,{$$typeof:e,type:r,key:c,ref:i!==void 0?i:null,props:o}}return Sc.Fragment=t,Sc.jsx=n,Sc.jsxs=n,Sc}var s_;function bB(){return s_||(s_=1,kx.exports=vB()),kx.exports}var l=bB(),Dx={exports:{}},Pe={};/**
|
||
* @license React
|
||
* react.production.js
|
||
*
|
||
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
||
*
|
||
* This source code is licensed under the MIT license found in the
|
||
* LICENSE file in the root directory of this source tree.
|
||
*/var o_;function jB(){if(o_)return Pe;o_=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),o=Symbol.for("react.consumer"),c=Symbol.for("react.context"),f=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),h=Symbol.for("react.memo"),p=Symbol.for("react.lazy"),y=Symbol.for("react.activity"),x=Symbol.iterator;function j(L){return L===null||typeof L!="object"?null:(L=x&&L[x]||L["@@iterator"],typeof L=="function"?L:null)}var w={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},S=Object.assign,b={};function A(L,F,ae){this.props=L,this.context=F,this.refs=b,this.updater=ae||w}A.prototype.isReactComponent={},A.prototype.setState=function(L,F){if(typeof L!="object"&&typeof L!="function"&&L!=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,L,F,"setState")},A.prototype.forceUpdate=function(L){this.updater.enqueueForceUpdate(this,L,"forceUpdate")};function _(){}_.prototype=A.prototype;function O(L,F,ae){this.props=L,this.context=F,this.refs=b,this.updater=ae||w}var T=O.prototype=new _;T.constructor=O,S(T,A.prototype),T.isPureReactComponent=!0;var N=Array.isArray;function E(){}var M={H:null,A:null,T:null,S:null},D=Object.prototype.hasOwnProperty;function R(L,F,ae){var fe=ae.ref;return{$$typeof:e,type:L,key:F,ref:fe!==void 0?fe:null,props:ae}}function B(L,F){return R(L.type,F,L.props)}function q(L){return typeof L=="object"&&L!==null&&L.$$typeof===e}function z(L){var F={"=":"=0",":":"=2"};return"$"+L.replace(/[=:]/g,function(ae){return F[ae]})}var H=/\/+/g;function X(L,F){return typeof L=="object"&&L!==null&&L.key!=null?z(""+L.key):F.toString(36)}function Y(L){switch(L.status){case"fulfilled":return L.value;case"rejected":throw L.reason;default:switch(typeof L.status=="string"?L.then(E,E):(L.status="pending",L.then(function(F){L.status==="pending"&&(L.status="fulfilled",L.value=F)},function(F){L.status==="pending"&&(L.status="rejected",L.reason=F)})),L.status){case"fulfilled":return L.value;case"rejected":throw L.reason}}throw L}function $(L,F,ae,fe,xe){var Ae=typeof L;(Ae==="undefined"||Ae==="boolean")&&(L=null);var qe=!1;if(L===null)qe=!0;else switch(Ae){case"bigint":case"string":case"number":qe=!0;break;case"object":switch(L.$$typeof){case e:case t:qe=!0;break;case p:return qe=L._init,$(qe(L._payload),F,ae,fe,xe)}}if(qe)return xe=xe(L),qe=fe===""?"."+X(L,0):fe,N(xe)?(ae="",qe!=null&&(ae=qe.replace(H,"$&/")+"/"),$(xe,F,ae,"",function(Ee){return Ee})):xe!=null&&(q(xe)&&(xe=B(xe,ae+(xe.key==null||L&&L.key===xe.key?"":(""+xe.key).replace(H,"$&/")+"/")+qe)),F.push(xe)),1;qe=0;var Qe=fe===""?".":fe+":";if(N(L))for(var ue=0;ue<L.length;ue++)fe=L[ue],Ae=Qe+X(fe,ue),qe+=$(fe,F,ae,Ae,xe);else if(ue=j(L),typeof ue=="function")for(L=ue.call(L),ue=0;!(fe=L.next()).done;)fe=fe.value,Ae=Qe+X(fe,ue++),qe+=$(fe,F,ae,Ae,xe);else if(Ae==="object"){if(typeof L.then=="function")return $(Y(L),F,ae,fe,xe);throw F=String(L),Error("Objects are not valid as a React child (found: "+(F==="[object Object]"?"object with keys {"+Object.keys(L).join(", ")+"}":F)+"). If you meant to render a collection of children, use an array instead.")}return qe}function G(L,F,ae){if(L==null)return L;var fe=[],xe=0;return $(L,fe,"","",function(Ae){return F.call(ae,Ae,xe++)}),fe}function Q(L){if(L._status===-1){var F=L._result;F=F(),F.then(function(ae){(L._status===0||L._status===-1)&&(L._status=1,L._result=ae)},function(ae){(L._status===0||L._status===-1)&&(L._status=2,L._result=ae)}),L._status===-1&&(L._status=0,L._result=F)}if(L._status===1)return L._result.default;throw L._result}var ie=typeof reportError=="function"?reportError:function(L){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var F=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof L=="object"&&L!==null&&typeof L.message=="string"?String(L.message):String(L),error:L});if(!window.dispatchEvent(F))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",L);return}console.error(L)},le={map:G,forEach:function(L,F,ae){G(L,function(){F.apply(this,arguments)},ae)},count:function(L){var F=0;return G(L,function(){F++}),F},toArray:function(L){return G(L,function(F){return F})||[]},only:function(L){if(!q(L))throw Error("React.Children.only expected to receive a single React element child.");return L}};return Pe.Activity=y,Pe.Children=le,Pe.Component=A,Pe.Fragment=n,Pe.Profiler=i,Pe.PureComponent=O,Pe.StrictMode=r,Pe.Suspense=d,Pe.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=M,Pe.__COMPILER_RUNTIME={__proto__:null,c:function(L){return M.H.useMemoCache(L)}},Pe.cache=function(L){return function(){return L.apply(null,arguments)}},Pe.cacheSignal=function(){return null},Pe.cloneElement=function(L,F,ae){if(L==null)throw Error("The argument must be a React element, but you passed "+L+".");var fe=S({},L.props),xe=L.key;if(F!=null)for(Ae in F.key!==void 0&&(xe=""+F.key),F)!D.call(F,Ae)||Ae==="key"||Ae==="__self"||Ae==="__source"||Ae==="ref"&&F.ref===void 0||(fe[Ae]=F[Ae]);var Ae=arguments.length-2;if(Ae===1)fe.children=ae;else if(1<Ae){for(var qe=Array(Ae),Qe=0;Qe<Ae;Qe++)qe[Qe]=arguments[Qe+2];fe.children=qe}return R(L.type,xe,fe)},Pe.createContext=function(L){return L={$$typeof:c,_currentValue:L,_currentValue2:L,_threadCount:0,Provider:null,Consumer:null},L.Provider=L,L.Consumer={$$typeof:o,_context:L},L},Pe.createElement=function(L,F,ae){var fe,xe={},Ae=null;if(F!=null)for(fe in F.key!==void 0&&(Ae=""+F.key),F)D.call(F,fe)&&fe!=="key"&&fe!=="__self"&&fe!=="__source"&&(xe[fe]=F[fe]);var qe=arguments.length-2;if(qe===1)xe.children=ae;else if(1<qe){for(var Qe=Array(qe),ue=0;ue<qe;ue++)Qe[ue]=arguments[ue+2];xe.children=Qe}if(L&&L.defaultProps)for(fe in qe=L.defaultProps,qe)xe[fe]===void 0&&(xe[fe]=qe[fe]);return R(L,Ae,xe)},Pe.createRef=function(){return{current:null}},Pe.forwardRef=function(L){return{$$typeof:f,render:L}},Pe.isValidElement=q,Pe.lazy=function(L){return{$$typeof:p,_payload:{_status:-1,_result:L},_init:Q}},Pe.memo=function(L,F){return{$$typeof:h,type:L,compare:F===void 0?null:F}},Pe.startTransition=function(L){var F=M.T,ae={};M.T=ae;try{var fe=L(),xe=M.S;xe!==null&&xe(ae,fe),typeof fe=="object"&&fe!==null&&typeof fe.then=="function"&&fe.then(E,ie)}catch(Ae){ie(Ae)}finally{F!==null&&ae.types!==null&&(F.types=ae.types),M.T=F}},Pe.unstable_useCacheRefresh=function(){return M.H.useCacheRefresh()},Pe.use=function(L){return M.H.use(L)},Pe.useActionState=function(L,F,ae){return M.H.useActionState(L,F,ae)},Pe.useCallback=function(L,F){return M.H.useCallback(L,F)},Pe.useContext=function(L){return M.H.useContext(L)},Pe.useDebugValue=function(){},Pe.useDeferredValue=function(L,F){return M.H.useDeferredValue(L,F)},Pe.useEffect=function(L,F){return M.H.useEffect(L,F)},Pe.useEffectEvent=function(L){return M.H.useEffectEvent(L)},Pe.useId=function(){return M.H.useId()},Pe.useImperativeHandle=function(L,F,ae){return M.H.useImperativeHandle(L,F,ae)},Pe.useInsertionEffect=function(L,F){return M.H.useInsertionEffect(L,F)},Pe.useLayoutEffect=function(L,F){return M.H.useLayoutEffect(L,F)},Pe.useMemo=function(L,F){return M.H.useMemo(L,F)},Pe.useOptimistic=function(L,F){return M.H.useOptimistic(L,F)},Pe.useReducer=function(L,F,ae){return M.H.useReducer(L,F,ae)},Pe.useRef=function(L){return M.H.useRef(L)},Pe.useState=function(L){return M.H.useState(L)},Pe.useSyncExternalStore=function(L,F,ae){return M.H.useSyncExternalStore(L,F,ae)},Pe.useTransition=function(){return M.H.useTransition()},Pe.version="19.2.7",Pe}var l_;function mw(){return l_||(l_=1,Dx.exports=jB()),Dx.exports}var P=mw();const U=at(P);var zx={exports:{}},Nc={},Lx={exports:{}},$x={};/**
|
||
* @license React
|
||
* scheduler.production.js
|
||
*
|
||
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
||
*
|
||
* This source code is licensed under the MIT license found in the
|
||
* LICENSE file in the root directory of this source tree.
|
||
*/var c_;function wB(){return c_||(c_=1,(function(e){function t($,G){var Q=$.length;$.push(G);e:for(;0<Q;){var ie=Q-1>>>1,le=$[ie];if(0<i(le,G))$[ie]=G,$[Q]=le,Q=ie;else break e}}function n($){return $.length===0?null:$[0]}function r($){if($.length===0)return null;var G=$[0],Q=$.pop();if(Q!==G){$[0]=Q;e:for(var ie=0,le=$.length,L=le>>>1;ie<L;){var F=2*(ie+1)-1,ae=$[F],fe=F+1,xe=$[fe];if(0>i(ae,Q))fe<le&&0>i(xe,ae)?($[ie]=xe,$[fe]=Q,ie=fe):($[ie]=ae,$[F]=Q,ie=F);else if(fe<le&&0>i(xe,Q))$[ie]=xe,$[fe]=Q,ie=fe;else break e}}return G}function i($,G){var Q=$.sortIndex-G.sortIndex;return Q!==0?Q:$.id-G.id}if(e.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var o=performance;e.unstable_now=function(){return o.now()}}else{var c=Date,f=c.now();e.unstable_now=function(){return c.now()-f}}var d=[],h=[],p=1,y=null,x=3,j=!1,w=!1,S=!1,b=!1,A=typeof setTimeout=="function"?setTimeout:null,_=typeof clearTimeout=="function"?clearTimeout:null,O=typeof setImmediate<"u"?setImmediate:null;function T($){for(var G=n(h);G!==null;){if(G.callback===null)r(h);else if(G.startTime<=$)r(h),G.sortIndex=G.expirationTime,t(d,G);else break;G=n(h)}}function N($){if(S=!1,T($),!w)if(n(d)!==null)w=!0,E||(E=!0,z());else{var G=n(h);G!==null&&Y(N,G.startTime-$)}}var E=!1,M=-1,D=5,R=-1;function B(){return b?!0:!(e.unstable_now()-R<D)}function q(){if(b=!1,E){var $=e.unstable_now();R=$;var G=!0;try{e:{w=!1,S&&(S=!1,_(M),M=-1),j=!0;var Q=x;try{t:{for(T($),y=n(d);y!==null&&!(y.expirationTime>$&&B());){var ie=y.callback;if(typeof ie=="function"){y.callback=null,x=y.priorityLevel;var le=ie(y.expirationTime<=$);if($=e.unstable_now(),typeof le=="function"){y.callback=le,T($),G=!0;break t}y===n(d)&&r(d),T($)}else r(d);y=n(d)}if(y!==null)G=!0;else{var L=n(h);L!==null&&Y(N,L.startTime-$),G=!1}}break e}finally{y=null,x=Q,j=!1}G=void 0}}finally{G?z():E=!1}}}var z;if(typeof O=="function")z=function(){O(q)};else if(typeof MessageChannel<"u"){var H=new MessageChannel,X=H.port2;H.port1.onmessage=q,z=function(){X.postMessage(null)}}else z=function(){A(q,0)};function Y($,G){M=A(function(){$(e.unstable_now())},G)}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($){$.callback=null},e.unstable_forceFrameRate=function($){0>$||125<$?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):D=0<$?Math.floor(1e3/$):5},e.unstable_getCurrentPriorityLevel=function(){return x},e.unstable_next=function($){switch(x){case 1:case 2:case 3:var G=3;break;default:G=x}var Q=x;x=G;try{return $()}finally{x=Q}},e.unstable_requestPaint=function(){b=!0},e.unstable_runWithPriority=function($,G){switch($){case 1:case 2:case 3:case 4:case 5:break;default:$=3}var Q=x;x=$;try{return G()}finally{x=Q}},e.unstable_scheduleCallback=function($,G,Q){var ie=e.unstable_now();switch(typeof Q=="object"&&Q!==null?(Q=Q.delay,Q=typeof Q=="number"&&0<Q?ie+Q:ie):Q=ie,$){case 1:var le=-1;break;case 2:le=250;break;case 5:le=1073741823;break;case 4:le=1e4;break;default:le=5e3}return le=Q+le,$={id:p++,callback:G,priorityLevel:$,startTime:Q,expirationTime:le,sortIndex:-1},Q>ie?($.sortIndex=Q,t(h,$),n(d)===null&&$===n(h)&&(S?(_(M),M=-1):S=!0,Y(N,Q-ie))):($.sortIndex=le,t(d,$),w||j||(w=!0,E||(E=!0,z()))),$},e.unstable_shouldYield=B,e.unstable_wrapCallback=function($){var G=x;return function(){var Q=x;x=G;try{return $.apply(this,arguments)}finally{x=Q}}}})($x)),$x}var u_;function SB(){return u_||(u_=1,Lx.exports=wB()),Lx.exports}var Bx={exports:{}},hn={};/**
|
||
* @license React
|
||
* react-dom.production.js
|
||
*
|
||
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
||
*
|
||
* This source code is licensed under the MIT license found in the
|
||
* LICENSE file in the root directory of this source tree.
|
||
*/var f_;function NB(){if(f_)return hn;f_=1;var e=mw();function t(d){var h="https://react.dev/errors/"+d;if(1<arguments.length){h+="?args[]="+encodeURIComponent(arguments[1]);for(var p=2;p<arguments.length;p++)h+="&args[]="+encodeURIComponent(arguments[p])}return"Minified React error #"+d+"; visit "+h+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function n(){}var r={d:{f:n,r:function(){throw Error(t(522))},D:n,C:n,L:n,m:n,X:n,S:n,M:n},p:0,findDOMNode:null},i=Symbol.for("react.portal");function o(d,h,p){var y=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:i,key:y==null?null:""+y,children:d,containerInfo:h,implementation:p}}var c=e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function f(d,h){if(d==="font")return"";if(typeof h=="string")return h==="use-credentials"?h:""}return hn.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=r,hn.createPortal=function(d,h){var p=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!h||h.nodeType!==1&&h.nodeType!==9&&h.nodeType!==11)throw Error(t(299));return o(d,h,null,p)},hn.flushSync=function(d){var h=c.T,p=r.p;try{if(c.T=null,r.p=2,d)return d()}finally{c.T=h,r.p=p,r.d.f()}},hn.preconnect=function(d,h){typeof d=="string"&&(h?(h=h.crossOrigin,h=typeof h=="string"?h==="use-credentials"?h:"":void 0):h=null,r.d.C(d,h))},hn.prefetchDNS=function(d){typeof d=="string"&&r.d.D(d)},hn.preinit=function(d,h){if(typeof d=="string"&&h&&typeof h.as=="string"){var p=h.as,y=f(p,h.crossOrigin),x=typeof h.integrity=="string"?h.integrity:void 0,j=typeof h.fetchPriority=="string"?h.fetchPriority:void 0;p==="style"?r.d.S(d,typeof h.precedence=="string"?h.precedence:void 0,{crossOrigin:y,integrity:x,fetchPriority:j}):p==="script"&&r.d.X(d,{crossOrigin:y,integrity:x,fetchPriority:j,nonce:typeof h.nonce=="string"?h.nonce:void 0})}},hn.preinitModule=function(d,h){if(typeof d=="string")if(typeof h=="object"&&h!==null){if(h.as==null||h.as==="script"){var p=f(h.as,h.crossOrigin);r.d.M(d,{crossOrigin:p,integrity:typeof h.integrity=="string"?h.integrity:void 0,nonce:typeof h.nonce=="string"?h.nonce:void 0})}}else h==null&&r.d.M(d)},hn.preload=function(d,h){if(typeof d=="string"&&typeof h=="object"&&h!==null&&typeof h.as=="string"){var p=h.as,y=f(p,h.crossOrigin);r.d.L(d,p,{crossOrigin:y,integrity:typeof h.integrity=="string"?h.integrity:void 0,nonce:typeof h.nonce=="string"?h.nonce:void 0,type:typeof h.type=="string"?h.type:void 0,fetchPriority:typeof h.fetchPriority=="string"?h.fetchPriority:void 0,referrerPolicy:typeof h.referrerPolicy=="string"?h.referrerPolicy:void 0,imageSrcSet:typeof h.imageSrcSet=="string"?h.imageSrcSet:void 0,imageSizes:typeof h.imageSizes=="string"?h.imageSizes:void 0,media:typeof h.media=="string"?h.media:void 0})}},hn.preloadModule=function(d,h){if(typeof d=="string")if(h){var p=f(h.as,h.crossOrigin);r.d.m(d,{as:typeof h.as=="string"&&h.as!=="script"?h.as:void 0,crossOrigin:p,integrity:typeof h.integrity=="string"?h.integrity:void 0})}else r.d.m(d)},hn.requestFormReset=function(d){r.d.r(d)},hn.unstable_batchedUpdates=function(d,h){return d(h)},hn.useFormState=function(d,h,p){return c.H.useFormState(d,h,p)},hn.useFormStatus=function(){return c.H.useHostTransitionStatus()},hn.version="19.2.7",hn}var d_;function AB(){if(d_)return Bx.exports;d_=1;function e(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}return e(),Bx.exports=NB(),Bx.exports}/**
|
||
* @license React
|
||
* react-dom-client.production.js
|
||
*
|
||
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
||
*
|
||
* This source code is licensed under the MIT license found in the
|
||
* LICENSE file in the root directory of this source tree.
|
||
*/var h_;function OB(){if(h_)return Nc;h_=1;var e=SB(),t=mw(),n=AB();function r(a){var s="https://react.dev/errors/"+a;if(1<arguments.length){s+="?args[]="+encodeURIComponent(arguments[1]);for(var u=2;u<arguments.length;u++)s+="&args[]="+encodeURIComponent(arguments[u])}return"Minified React error #"+a+"; visit "+s+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function i(a){return!(!a||a.nodeType!==1&&a.nodeType!==9&&a.nodeType!==11)}function o(a){var s=a,u=a;if(a.alternate)for(;s.return;)s=s.return;else{a=s;do s=a,(s.flags&4098)!==0&&(u=s.return),a=s.return;while(a)}return s.tag===3?u:null}function c(a){if(a.tag===13){var s=a.memoizedState;if(s===null&&(a=a.alternate,a!==null&&(s=a.memoizedState)),s!==null)return s.dehydrated}return null}function f(a){if(a.tag===31){var s=a.memoizedState;if(s===null&&(a=a.alternate,a!==null&&(s=a.memoizedState)),s!==null)return s.dehydrated}return null}function d(a){if(o(a)!==a)throw Error(r(188))}function h(a){var s=a.alternate;if(!s){if(s=o(a),s===null)throw Error(r(188));return s!==a?null:a}for(var u=a,m=s;;){var g=u.return;if(g===null)break;var v=g.alternate;if(v===null){if(m=g.return,m!==null){u=m;continue}break}if(g.child===v.child){for(v=g.child;v;){if(v===u)return d(g),a;if(v===m)return d(g),s;v=v.sibling}throw Error(r(188))}if(u.return!==m.return)u=g,m=v;else{for(var C=!1,k=g.child;k;){if(k===u){C=!0,u=g,m=v;break}if(k===m){C=!0,m=g,u=v;break}k=k.sibling}if(!C){for(k=v.child;k;){if(k===u){C=!0,u=v,m=g;break}if(k===m){C=!0,m=v,u=g;break}k=k.sibling}if(!C)throw Error(r(189))}}if(u.alternate!==m)throw Error(r(190))}if(u.tag!==3)throw Error(r(188));return u.stateNode.current===u?a:s}function p(a){var s=a.tag;if(s===5||s===26||s===27||s===6)return a;for(a=a.child;a!==null;){if(s=p(a),s!==null)return s;a=a.sibling}return null}var y=Object.assign,x=Symbol.for("react.element"),j=Symbol.for("react.transitional.element"),w=Symbol.for("react.portal"),S=Symbol.for("react.fragment"),b=Symbol.for("react.strict_mode"),A=Symbol.for("react.profiler"),_=Symbol.for("react.consumer"),O=Symbol.for("react.context"),T=Symbol.for("react.forward_ref"),N=Symbol.for("react.suspense"),E=Symbol.for("react.suspense_list"),M=Symbol.for("react.memo"),D=Symbol.for("react.lazy"),R=Symbol.for("react.activity"),B=Symbol.for("react.memo_cache_sentinel"),q=Symbol.iterator;function z(a){return a===null||typeof a!="object"?null:(a=q&&a[q]||a["@@iterator"],typeof a=="function"?a:null)}var H=Symbol.for("react.client.reference");function X(a){if(a==null)return null;if(typeof a=="function")return a.$$typeof===H?null:a.displayName||a.name||null;if(typeof a=="string")return a;switch(a){case S:return"Fragment";case A:return"Profiler";case b:return"StrictMode";case N:return"Suspense";case E:return"SuspenseList";case R:return"Activity"}if(typeof a=="object")switch(a.$$typeof){case w:return"Portal";case O:return a.displayName||"Context";case _:return(a._context.displayName||"Context")+".Consumer";case T:var s=a.render;return a=a.displayName,a||(a=s.displayName||s.name||"",a=a!==""?"ForwardRef("+a+")":"ForwardRef"),a;case M:return s=a.displayName||null,s!==null?s:X(a.type)||"Memo";case D:s=a._payload,a=a._init;try{return X(a(s))}catch{}}return null}var Y=Array.isArray,$=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,G=n.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Q={pending:!1,data:null,method:null,action:null},ie=[],le=-1;function L(a){return{current:a}}function F(a){0>le||(a.current=ie[le],ie[le]=null,le--)}function ae(a,s){le++,ie[le]=a.current,a.current=s}var fe=L(null),xe=L(null),Ae=L(null),qe=L(null);function Qe(a,s){switch(ae(Ae,s),ae(xe,a),ae(fe,null),s.nodeType){case 9:case 11:a=(a=s.documentElement)&&(a=a.namespaceURI)?TO(a):0;break;default:if(a=s.tagName,s=s.namespaceURI)s=TO(s),a=EO(s,a);else switch(a){case"svg":a=1;break;case"math":a=2;break;default:a=0}}F(fe),ae(fe,a)}function ue(){F(fe),F(xe),F(Ae)}function Ee(a){a.memoizedState!==null&&ae(qe,a);var s=fe.current,u=EO(s,a.type);s!==u&&(ae(xe,a),ae(fe,u))}function Me(a){xe.current===a&&(F(fe),F(xe)),qe.current===a&&(F(qe),vc._currentValue=Q)}var ce,xt;function Le(a){if(ce===void 0)try{throw Error()}catch(u){var s=u.stack.trim().match(/\n( *(at )?)/);ce=s&&s[1]||"",xt=-1<u.stack.indexOf(`
|
||
at`)?" (<anonymous>)":-1<u.stack.indexOf("@")?"@unknown:0:0":""}return`
|
||
`+ce+a+xt}var _t=!1;function Tt(a,s){if(!a||_t)return"";_t=!0;var u=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var m={DetermineComponentFrameRoot:function(){try{if(s){var oe=function(){throw Error()};if(Object.defineProperty(oe.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(oe,[])}catch(te){var J=te}Reflect.construct(a,[],oe)}else{try{oe.call()}catch(te){J=te}a.call(oe.prototype)}}else{try{throw Error()}catch(te){J=te}(oe=a())&&typeof oe.catch=="function"&&oe.catch(function(){})}}catch(te){if(te&&J&&typeof te.stack=="string")return[te.stack,J.stack]}return[null,null]}};m.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var g=Object.getOwnPropertyDescriptor(m.DetermineComponentFrameRoot,"name");g&&g.configurable&&Object.defineProperty(m.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var v=m.DetermineComponentFrameRoot(),C=v[0],k=v[1];if(C&&k){var I=C.split(`
|
||
`),Z=k.split(`
|
||
`);for(g=m=0;m<I.length&&!I[m].includes("DetermineComponentFrameRoot");)m++;for(;g<Z.length&&!Z[g].includes("DetermineComponentFrameRoot");)g++;if(m===I.length||g===Z.length)for(m=I.length-1,g=Z.length-1;1<=m&&0<=g&&I[m]!==Z[g];)g--;for(;1<=m&&0<=g;m--,g--)if(I[m]!==Z[g]){if(m!==1||g!==1)do if(m--,g--,0>g||I[m]!==Z[g]){var ne=`
|
||
`+I[m].replace(" at new "," at ");return a.displayName&&ne.includes("<anonymous>")&&(ne=ne.replace("<anonymous>",a.displayName)),ne}while(1<=m&&0<=g);break}}}finally{_t=!1,Error.prepareStackTrace=u}return(u=a?a.displayName||a.name:"")?Le(u):""}function fn(a,s){switch(a.tag){case 26:case 27:case 5:return Le(a.type);case 16:return Le("Lazy");case 13:return a.child!==s&&s!==null?Le("Suspense Fallback"):Le("Suspense");case 19:return Le("SuspenseList");case 0:case 15:return Tt(a.type,!1);case 11:return Tt(a.type.render,!1);case 1:return Tt(a.type,!0);case 31:return Le("Activity");default:return""}}function wr(a){try{var s="",u=null;do s+=fn(a,u),u=a,a=a.return;while(a);return s}catch(m){return`
|
||
Error generating stack: `+m.message+`
|
||
`+m.stack}}var qr=Object.prototype.hasOwnProperty,Ya=e.unstable_scheduleCallback,Sr=e.unstable_cancelCallback,ia=e.unstable_shouldYield,Cl=e.unstable_requestPaint,dn=e.unstable_now,lf=e.unstable_getCurrentPriorityLevel,sN=e.unstable_ImmediatePriority,oN=e.unstable_UserBlockingPriority,cf=e.unstable_NormalPriority,e8=e.unstable_LowPriority,lN=e.unstable_IdlePriority,t8=e.log,n8=e.unstable_setDisableYieldValue,Ml=null,kn=null;function Xa(a){if(typeof t8=="function"&&n8(a),kn&&typeof kn.setStrictMode=="function")try{kn.setStrictMode(Ml,a)}catch{}}var Dn=Math.clz32?Math.clz32:i8,r8=Math.log,a8=Math.LN2;function i8(a){return a>>>=0,a===0?32:31-(r8(a)/a8|0)|0}var uf=256,ff=262144,df=4194304;function $i(a){var s=a&42;if(s!==0)return s;switch(a&-a){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 a&261888;case 262144:case 524288:case 1048576:case 2097152:return a&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return a&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return a}}function hf(a,s,u){var m=a.pendingLanes;if(m===0)return 0;var g=0,v=a.suspendedLanes,C=a.pingedLanes;a=a.warmLanes;var k=m&134217727;return k!==0?(m=k&~v,m!==0?g=$i(m):(C&=k,C!==0?g=$i(C):u||(u=k&~a,u!==0&&(g=$i(u))))):(k=m&~v,k!==0?g=$i(k):C!==0?g=$i(C):u||(u=m&~a,u!==0&&(g=$i(u)))),g===0?0:s!==0&&s!==g&&(s&v)===0&&(v=g&-g,u=s&-s,v>=u||v===32&&(u&4194048)!==0)?s:g}function Pl(a,s){return(a.pendingLanes&~(a.suspendedLanes&~a.pingedLanes)&s)===0}function s8(a,s){switch(a){case 1:case 2:case 4:case 8:case 64:return s+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 s+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 cN(){var a=df;return df<<=1,(df&62914560)===0&&(df=4194304),a}function wp(a){for(var s=[],u=0;31>u;u++)s.push(a);return s}function Rl(a,s){a.pendingLanes|=s,s!==268435456&&(a.suspendedLanes=0,a.pingedLanes=0,a.warmLanes=0)}function o8(a,s,u,m,g,v){var C=a.pendingLanes;a.pendingLanes=u,a.suspendedLanes=0,a.pingedLanes=0,a.warmLanes=0,a.expiredLanes&=u,a.entangledLanes&=u,a.errorRecoveryDisabledLanes&=u,a.shellSuspendCounter=0;var k=a.entanglements,I=a.expirationTimes,Z=a.hiddenUpdates;for(u=C&~u;0<u;){var ne=31-Dn(u),oe=1<<ne;k[ne]=0,I[ne]=-1;var J=Z[ne];if(J!==null)for(Z[ne]=null,ne=0;ne<J.length;ne++){var te=J[ne];te!==null&&(te.lane&=-536870913)}u&=~oe}m!==0&&uN(a,m,0),v!==0&&g===0&&a.tag!==0&&(a.suspendedLanes|=v&~(C&~s))}function uN(a,s,u){a.pendingLanes|=s,a.suspendedLanes&=~s;var m=31-Dn(s);a.entangledLanes|=s,a.entanglements[m]=a.entanglements[m]|1073741824|u&261930}function fN(a,s){var u=a.entangledLanes|=s;for(a=a.entanglements;u;){var m=31-Dn(u),g=1<<m;g&s|a[m]&s&&(a[m]|=s),u&=~g}}function dN(a,s){var u=s&-s;return u=(u&42)!==0?1:Sp(u),(u&(a.suspendedLanes|s))!==0?0:u}function Sp(a){switch(a){case 2:a=1;break;case 8:a=4;break;case 32:a=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:a=128;break;case 268435456:a=134217728;break;default:a=0}return a}function Np(a){return a&=-a,2<a?8<a?(a&134217727)!==0?32:268435456:8:2}function hN(){var a=G.p;return a!==0?a:(a=window.event,a===void 0?32:QO(a.type))}function mN(a,s){var u=G.p;try{return G.p=a,s()}finally{G.p=u}}var Wa=Math.random().toString(36).slice(2),nn="__reactFiber$"+Wa,Nn="__reactProps$"+Wa,ks="__reactContainer$"+Wa,Ap="__reactEvents$"+Wa,l8="__reactListeners$"+Wa,c8="__reactHandles$"+Wa,pN="__reactResources$"+Wa,kl="__reactMarker$"+Wa;function Op(a){delete a[nn],delete a[Nn],delete a[Ap],delete a[l8],delete a[c8]}function Ds(a){var s=a[nn];if(s)return s;for(var u=a.parentNode;u;){if(s=u[ks]||u[nn]){if(u=s.alternate,s.child!==null||u!==null&&u.child!==null)for(a=zO(a);a!==null;){if(u=a[nn])return u;a=zO(a)}return s}a=u,u=a.parentNode}return null}function zs(a){if(a=a[nn]||a[ks]){var s=a.tag;if(s===5||s===6||s===13||s===31||s===26||s===27||s===3)return a}return null}function Dl(a){var s=a.tag;if(s===5||s===26||s===27||s===6)return a.stateNode;throw Error(r(33))}function Ls(a){var s=a[pN];return s||(s=a[pN]={hoistableStyles:new Map,hoistableScripts:new Map}),s}function Zt(a){a[kl]=!0}var yN=new Set,xN={};function Bi(a,s){$s(a,s),$s(a+"Capture",s)}function $s(a,s){for(xN[a]=s,a=0;a<s.length;a++)yN.add(s[a])}var u8=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]*$"),gN={},vN={};function f8(a){return qr.call(vN,a)?!0:qr.call(gN,a)?!1:u8.test(a)?vN[a]=!0:(gN[a]=!0,!1)}function mf(a,s,u){if(f8(s))if(u===null)a.removeAttribute(s);else{switch(typeof u){case"undefined":case"function":case"symbol":a.removeAttribute(s);return;case"boolean":var m=s.toLowerCase().slice(0,5);if(m!=="data-"&&m!=="aria-"){a.removeAttribute(s);return}}a.setAttribute(s,""+u)}}function pf(a,s,u){if(u===null)a.removeAttribute(s);else{switch(typeof u){case"undefined":case"function":case"symbol":case"boolean":a.removeAttribute(s);return}a.setAttribute(s,""+u)}}function sa(a,s,u,m){if(m===null)a.removeAttribute(u);else{switch(typeof m){case"undefined":case"function":case"symbol":case"boolean":a.removeAttribute(u);return}a.setAttributeNS(s,u,""+m)}}function er(a){switch(typeof a){case"bigint":case"boolean":case"number":case"string":case"undefined":return a;case"object":return a;default:return""}}function bN(a){var s=a.type;return(a=a.nodeName)&&a.toLowerCase()==="input"&&(s==="checkbox"||s==="radio")}function d8(a,s,u){var m=Object.getOwnPropertyDescriptor(a.constructor.prototype,s);if(!a.hasOwnProperty(s)&&typeof m<"u"&&typeof m.get=="function"&&typeof m.set=="function"){var g=m.get,v=m.set;return Object.defineProperty(a,s,{configurable:!0,get:function(){return g.call(this)},set:function(C){u=""+C,v.call(this,C)}}),Object.defineProperty(a,s,{enumerable:m.enumerable}),{getValue:function(){return u},setValue:function(C){u=""+C},stopTracking:function(){a._valueTracker=null,delete a[s]}}}}function _p(a){if(!a._valueTracker){var s=bN(a)?"checked":"value";a._valueTracker=d8(a,s,""+a[s])}}function jN(a){if(!a)return!1;var s=a._valueTracker;if(!s)return!0;var u=s.getValue(),m="";return a&&(m=bN(a)?a.checked?"true":"false":a.value),a=m,a!==u?(s.setValue(a),!0):!1}function yf(a){if(a=a||(typeof document<"u"?document:void 0),typeof a>"u")return null;try{return a.activeElement||a.body}catch{return a.body}}var h8=/[\n"\\]/g;function tr(a){return a.replace(h8,function(s){return"\\"+s.charCodeAt(0).toString(16)+" "})}function Tp(a,s,u,m,g,v,C,k){a.name="",C!=null&&typeof C!="function"&&typeof C!="symbol"&&typeof C!="boolean"?a.type=C:a.removeAttribute("type"),s!=null?C==="number"?(s===0&&a.value===""||a.value!=s)&&(a.value=""+er(s)):a.value!==""+er(s)&&(a.value=""+er(s)):C!=="submit"&&C!=="reset"||a.removeAttribute("value"),s!=null?Ep(a,C,er(s)):u!=null?Ep(a,C,er(u)):m!=null&&a.removeAttribute("value"),g==null&&v!=null&&(a.defaultChecked=!!v),g!=null&&(a.checked=g&&typeof g!="function"&&typeof g!="symbol"),k!=null&&typeof k!="function"&&typeof k!="symbol"&&typeof k!="boolean"?a.name=""+er(k):a.removeAttribute("name")}function wN(a,s,u,m,g,v,C,k){if(v!=null&&typeof v!="function"&&typeof v!="symbol"&&typeof v!="boolean"&&(a.type=v),s!=null||u!=null){if(!(v!=="submit"&&v!=="reset"||s!=null)){_p(a);return}u=u!=null?""+er(u):"",s=s!=null?""+er(s):u,k||s===a.value||(a.value=s),a.defaultValue=s}m=m??g,m=typeof m!="function"&&typeof m!="symbol"&&!!m,a.checked=k?a.checked:!!m,a.defaultChecked=!!m,C!=null&&typeof C!="function"&&typeof C!="symbol"&&typeof C!="boolean"&&(a.name=C),_p(a)}function Ep(a,s,u){s==="number"&&yf(a.ownerDocument)===a||a.defaultValue===""+u||(a.defaultValue=""+u)}function Bs(a,s,u,m){if(a=a.options,s){s={};for(var g=0;g<u.length;g++)s["$"+u[g]]=!0;for(u=0;u<a.length;u++)g=s.hasOwnProperty("$"+a[u].value),a[u].selected!==g&&(a[u].selected=g),g&&m&&(a[u].defaultSelected=!0)}else{for(u=""+er(u),s=null,g=0;g<a.length;g++){if(a[g].value===u){a[g].selected=!0,m&&(a[g].defaultSelected=!0);return}s!==null||a[g].disabled||(s=a[g])}s!==null&&(s.selected=!0)}}function SN(a,s,u){if(s!=null&&(s=""+er(s),s!==a.value&&(a.value=s),u==null)){a.defaultValue!==s&&(a.defaultValue=s);return}a.defaultValue=u!=null?""+er(u):""}function NN(a,s,u,m){if(s==null){if(m!=null){if(u!=null)throw Error(r(92));if(Y(m)){if(1<m.length)throw Error(r(93));m=m[0]}u=m}u==null&&(u=""),s=u}u=er(s),a.defaultValue=u,m=a.textContent,m===u&&m!==""&&m!==null&&(a.value=m),_p(a)}function qs(a,s){if(s){var u=a.firstChild;if(u&&u===a.lastChild&&u.nodeType===3){u.nodeValue=s;return}}a.textContent=s}var m8=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 AN(a,s,u){var m=s.indexOf("--")===0;u==null||typeof u=="boolean"||u===""?m?a.setProperty(s,""):s==="float"?a.cssFloat="":a[s]="":m?a.setProperty(s,u):typeof u!="number"||u===0||m8.has(s)?s==="float"?a.cssFloat=u:a[s]=(""+u).trim():a[s]=u+"px"}function ON(a,s,u){if(s!=null&&typeof s!="object")throw Error(r(62));if(a=a.style,u!=null){for(var m in u)!u.hasOwnProperty(m)||s!=null&&s.hasOwnProperty(m)||(m.indexOf("--")===0?a.setProperty(m,""):m==="float"?a.cssFloat="":a[m]="");for(var g in s)m=s[g],s.hasOwnProperty(g)&&u[g]!==m&&AN(a,g,m)}else for(var v in s)s.hasOwnProperty(v)&&AN(a,v,s[v])}function Cp(a){if(a.indexOf("-")===-1)return!1;switch(a){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 p8=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"]]),y8=/^[\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 xf(a){return y8.test(""+a)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":a}function oa(){}var Mp=null;function Pp(a){return a=a.target||a.srcElement||window,a.correspondingUseElement&&(a=a.correspondingUseElement),a.nodeType===3?a.parentNode:a}var Is=null,Us=null;function _N(a){var s=zs(a);if(s&&(a=s.stateNode)){var u=a[Nn]||null;e:switch(a=s.stateNode,s.type){case"input":if(Tp(a,u.value,u.defaultValue,u.defaultValue,u.checked,u.defaultChecked,u.type,u.name),s=u.name,u.type==="radio"&&s!=null){for(u=a;u.parentNode;)u=u.parentNode;for(u=u.querySelectorAll('input[name="'+tr(""+s)+'"][type="radio"]'),s=0;s<u.length;s++){var m=u[s];if(m!==a&&m.form===a.form){var g=m[Nn]||null;if(!g)throw Error(r(90));Tp(m,g.value,g.defaultValue,g.defaultValue,g.checked,g.defaultChecked,g.type,g.name)}}for(s=0;s<u.length;s++)m=u[s],m.form===a.form&&jN(m)}break e;case"textarea":SN(a,u.value,u.defaultValue);break e;case"select":s=u.value,s!=null&&Bs(a,!!u.multiple,s,!1)}}}var Rp=!1;function TN(a,s,u){if(Rp)return a(s,u);Rp=!0;try{var m=a(s);return m}finally{if(Rp=!1,(Is!==null||Us!==null)&&(ad(),Is&&(s=Is,a=Us,Us=Is=null,_N(s),a)))for(s=0;s<a.length;s++)_N(a[s])}}function zl(a,s){var u=a.stateNode;if(u===null)return null;var m=u[Nn]||null;if(m===null)return null;u=m[s];e:switch(s){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(m=!m.disabled)||(a=a.type,m=!(a==="button"||a==="input"||a==="select"||a==="textarea")),a=!m;break e;default:a=!1}if(a)return null;if(u&&typeof u!="function")throw Error(r(231,s,typeof u));return u}var la=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),kp=!1;if(la)try{var Ll={};Object.defineProperty(Ll,"passive",{get:function(){kp=!0}}),window.addEventListener("test",Ll,Ll),window.removeEventListener("test",Ll,Ll)}catch{kp=!1}var Za=null,Dp=null,gf=null;function EN(){if(gf)return gf;var a,s=Dp,u=s.length,m,g="value"in Za?Za.value:Za.textContent,v=g.length;for(a=0;a<u&&s[a]===g[a];a++);var C=u-a;for(m=1;m<=C&&s[u-m]===g[v-m];m++);return gf=g.slice(a,1<m?1-m:void 0)}function vf(a){var s=a.keyCode;return"charCode"in a?(a=a.charCode,a===0&&s===13&&(a=13)):a=s,a===10&&(a=13),32<=a||a===13?a:0}function bf(){return!0}function CN(){return!1}function An(a){function s(u,m,g,v,C){this._reactName=u,this._targetInst=g,this.type=m,this.nativeEvent=v,this.target=C,this.currentTarget=null;for(var k in a)a.hasOwnProperty(k)&&(u=a[k],this[k]=u?u(v):v[k]);return this.isDefaultPrevented=(v.defaultPrevented!=null?v.defaultPrevented:v.returnValue===!1)?bf:CN,this.isPropagationStopped=CN,this}return y(s.prototype,{preventDefault:function(){this.defaultPrevented=!0;var u=this.nativeEvent;u&&(u.preventDefault?u.preventDefault():typeof u.returnValue!="unknown"&&(u.returnValue=!1),this.isDefaultPrevented=bf)},stopPropagation:function(){var u=this.nativeEvent;u&&(u.stopPropagation?u.stopPropagation():typeof u.cancelBubble!="unknown"&&(u.cancelBubble=!0),this.isPropagationStopped=bf)},persist:function(){},isPersistent:bf}),s}var qi={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(a){return a.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},jf=An(qi),$l=y({},qi,{view:0,detail:0}),x8=An($l),zp,Lp,Bl,wf=y({},$l,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Bp,button:0,buttons:0,relatedTarget:function(a){return a.relatedTarget===void 0?a.fromElement===a.srcElement?a.toElement:a.fromElement:a.relatedTarget},movementX:function(a){return"movementX"in a?a.movementX:(a!==Bl&&(Bl&&a.type==="mousemove"?(zp=a.screenX-Bl.screenX,Lp=a.screenY-Bl.screenY):Lp=zp=0,Bl=a),zp)},movementY:function(a){return"movementY"in a?a.movementY:Lp}}),MN=An(wf),g8=y({},wf,{dataTransfer:0}),v8=An(g8),b8=y({},$l,{relatedTarget:0}),$p=An(b8),j8=y({},qi,{animationName:0,elapsedTime:0,pseudoElement:0}),w8=An(j8),S8=y({},qi,{clipboardData:function(a){return"clipboardData"in a?a.clipboardData:window.clipboardData}}),N8=An(S8),A8=y({},qi,{data:0}),PN=An(A8),O8={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},_8={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"},T8={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function E8(a){var s=this.nativeEvent;return s.getModifierState?s.getModifierState(a):(a=T8[a])?!!s[a]:!1}function Bp(){return E8}var C8=y({},$l,{key:function(a){if(a.key){var s=O8[a.key]||a.key;if(s!=="Unidentified")return s}return a.type==="keypress"?(a=vf(a),a===13?"Enter":String.fromCharCode(a)):a.type==="keydown"||a.type==="keyup"?_8[a.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Bp,charCode:function(a){return a.type==="keypress"?vf(a):0},keyCode:function(a){return a.type==="keydown"||a.type==="keyup"?a.keyCode:0},which:function(a){return a.type==="keypress"?vf(a):a.type==="keydown"||a.type==="keyup"?a.keyCode:0}}),M8=An(C8),P8=y({},wf,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),RN=An(P8),R8=y({},$l,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Bp}),k8=An(R8),D8=y({},qi,{propertyName:0,elapsedTime:0,pseudoElement:0}),z8=An(D8),L8=y({},wf,{deltaX:function(a){return"deltaX"in a?a.deltaX:"wheelDeltaX"in a?-a.wheelDeltaX:0},deltaY:function(a){return"deltaY"in a?a.deltaY:"wheelDeltaY"in a?-a.wheelDeltaY:"wheelDelta"in a?-a.wheelDelta:0},deltaZ:0,deltaMode:0}),$8=An(L8),B8=y({},qi,{newState:0,oldState:0}),q8=An(B8),I8=[9,13,27,32],qp=la&&"CompositionEvent"in window,ql=null;la&&"documentMode"in document&&(ql=document.documentMode);var U8=la&&"TextEvent"in window&&!ql,kN=la&&(!qp||ql&&8<ql&&11>=ql),DN=" ",zN=!1;function LN(a,s){switch(a){case"keyup":return I8.indexOf(s.keyCode)!==-1;case"keydown":return s.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function $N(a){return a=a.detail,typeof a=="object"&&"data"in a?a.data:null}var Vs=!1;function V8(a,s){switch(a){case"compositionend":return $N(s);case"keypress":return s.which!==32?null:(zN=!0,DN);case"textInput":return a=s.data,a===DN&&zN?null:a;default:return null}}function H8(a,s){if(Vs)return a==="compositionend"||!qp&&LN(a,s)?(a=EN(),gf=Dp=Za=null,Vs=!1,a):null;switch(a){case"paste":return null;case"keypress":if(!(s.ctrlKey||s.altKey||s.metaKey)||s.ctrlKey&&s.altKey){if(s.char&&1<s.char.length)return s.char;if(s.which)return String.fromCharCode(s.which)}return null;case"compositionend":return kN&&s.locale!=="ko"?null:s.data;default:return null}}var F8={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 BN(a){var s=a&&a.nodeName&&a.nodeName.toLowerCase();return s==="input"?!!F8[a.type]:s==="textarea"}function qN(a,s,u,m){Is?Us?Us.push(m):Us=[m]:Is=m,s=fd(s,"onChange"),0<s.length&&(u=new jf("onChange","change",null,u,m),a.push({event:u,listeners:s}))}var Il=null,Ul=null;function G8(a){wO(a,0)}function Sf(a){var s=Dl(a);if(jN(s))return a}function IN(a,s){if(a==="change")return s}var UN=!1;if(la){var Ip;if(la){var Up="oninput"in document;if(!Up){var VN=document.createElement("div");VN.setAttribute("oninput","return;"),Up=typeof VN.oninput=="function"}Ip=Up}else Ip=!1;UN=Ip&&(!document.documentMode||9<document.documentMode)}function HN(){Il&&(Il.detachEvent("onpropertychange",FN),Ul=Il=null)}function FN(a){if(a.propertyName==="value"&&Sf(Ul)){var s=[];qN(s,Ul,a,Pp(a)),TN(G8,s)}}function K8(a,s,u){a==="focusin"?(HN(),Il=s,Ul=u,Il.attachEvent("onpropertychange",FN)):a==="focusout"&&HN()}function Y8(a){if(a==="selectionchange"||a==="keyup"||a==="keydown")return Sf(Ul)}function X8(a,s){if(a==="click")return Sf(s)}function W8(a,s){if(a==="input"||a==="change")return Sf(s)}function Z8(a,s){return a===s&&(a!==0||1/a===1/s)||a!==a&&s!==s}var zn=typeof Object.is=="function"?Object.is:Z8;function Vl(a,s){if(zn(a,s))return!0;if(typeof a!="object"||a===null||typeof s!="object"||s===null)return!1;var u=Object.keys(a),m=Object.keys(s);if(u.length!==m.length)return!1;for(m=0;m<u.length;m++){var g=u[m];if(!qr.call(s,g)||!zn(a[g],s[g]))return!1}return!0}function GN(a){for(;a&&a.firstChild;)a=a.firstChild;return a}function KN(a,s){var u=GN(a);a=0;for(var m;u;){if(u.nodeType===3){if(m=a+u.textContent.length,a<=s&&m>=s)return{node:u,offset:s-a};a=m}e:{for(;u;){if(u.nextSibling){u=u.nextSibling;break e}u=u.parentNode}u=void 0}u=GN(u)}}function YN(a,s){return a&&s?a===s?!0:a&&a.nodeType===3?!1:s&&s.nodeType===3?YN(a,s.parentNode):"contains"in a?a.contains(s):a.compareDocumentPosition?!!(a.compareDocumentPosition(s)&16):!1:!1}function XN(a){a=a!=null&&a.ownerDocument!=null&&a.ownerDocument.defaultView!=null?a.ownerDocument.defaultView:window;for(var s=yf(a.document);s instanceof a.HTMLIFrameElement;){try{var u=typeof s.contentWindow.location.href=="string"}catch{u=!1}if(u)a=s.contentWindow;else break;s=yf(a.document)}return s}function Vp(a){var s=a&&a.nodeName&&a.nodeName.toLowerCase();return s&&(s==="input"&&(a.type==="text"||a.type==="search"||a.type==="tel"||a.type==="url"||a.type==="password")||s==="textarea"||a.contentEditable==="true")}var Q8=la&&"documentMode"in document&&11>=document.documentMode,Hs=null,Hp=null,Hl=null,Fp=!1;function WN(a,s,u){var m=u.window===u?u.document:u.nodeType===9?u:u.ownerDocument;Fp||Hs==null||Hs!==yf(m)||(m=Hs,"selectionStart"in m&&Vp(m)?m={start:m.selectionStart,end:m.selectionEnd}:(m=(m.ownerDocument&&m.ownerDocument.defaultView||window).getSelection(),m={anchorNode:m.anchorNode,anchorOffset:m.anchorOffset,focusNode:m.focusNode,focusOffset:m.focusOffset}),Hl&&Vl(Hl,m)||(Hl=m,m=fd(Hp,"onSelect"),0<m.length&&(s=new jf("onSelect","select",null,s,u),a.push({event:s,listeners:m}),s.target=Hs)))}function Ii(a,s){var u={};return u[a.toLowerCase()]=s.toLowerCase(),u["Webkit"+a]="webkit"+s,u["Moz"+a]="moz"+s,u}var Fs={animationend:Ii("Animation","AnimationEnd"),animationiteration:Ii("Animation","AnimationIteration"),animationstart:Ii("Animation","AnimationStart"),transitionrun:Ii("Transition","TransitionRun"),transitionstart:Ii("Transition","TransitionStart"),transitioncancel:Ii("Transition","TransitionCancel"),transitionend:Ii("Transition","TransitionEnd")},Gp={},ZN={};la&&(ZN=document.createElement("div").style,"AnimationEvent"in window||(delete Fs.animationend.animation,delete Fs.animationiteration.animation,delete Fs.animationstart.animation),"TransitionEvent"in window||delete Fs.transitionend.transition);function Ui(a){if(Gp[a])return Gp[a];if(!Fs[a])return a;var s=Fs[a],u;for(u in s)if(s.hasOwnProperty(u)&&u in ZN)return Gp[a]=s[u];return a}var QN=Ui("animationend"),JN=Ui("animationiteration"),eA=Ui("animationstart"),J8=Ui("transitionrun"),e$=Ui("transitionstart"),t$=Ui("transitioncancel"),tA=Ui("transitionend"),nA=new Map,Kp="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(" ");Kp.push("scrollEnd");function Nr(a,s){nA.set(a,s),Bi(s,[a])}var Nf=typeof reportError=="function"?reportError:function(a){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var s=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof a=="object"&&a!==null&&typeof a.message=="string"?String(a.message):String(a),error:a});if(!window.dispatchEvent(s))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",a);return}console.error(a)},nr=[],Gs=0,Yp=0;function Af(){for(var a=Gs,s=Yp=Gs=0;s<a;){var u=nr[s];nr[s++]=null;var m=nr[s];nr[s++]=null;var g=nr[s];nr[s++]=null;var v=nr[s];if(nr[s++]=null,m!==null&&g!==null){var C=m.pending;C===null?g.next=g:(g.next=C.next,C.next=g),m.pending=g}v!==0&&rA(u,g,v)}}function Of(a,s,u,m){nr[Gs++]=a,nr[Gs++]=s,nr[Gs++]=u,nr[Gs++]=m,Yp|=m,a.lanes|=m,a=a.alternate,a!==null&&(a.lanes|=m)}function Xp(a,s,u,m){return Of(a,s,u,m),_f(a)}function Vi(a,s){return Of(a,null,null,s),_f(a)}function rA(a,s,u){a.lanes|=u;var m=a.alternate;m!==null&&(m.lanes|=u);for(var g=!1,v=a.return;v!==null;)v.childLanes|=u,m=v.alternate,m!==null&&(m.childLanes|=u),v.tag===22&&(a=v.stateNode,a===null||a._visibility&1||(g=!0)),a=v,v=v.return;return a.tag===3?(v=a.stateNode,g&&s!==null&&(g=31-Dn(u),a=v.hiddenUpdates,m=a[g],m===null?a[g]=[s]:m.push(s),s.lane=u|536870912),v):null}function _f(a){if(50<dc)throw dc=0,ax=null,Error(r(185));for(var s=a.return;s!==null;)a=s,s=a.return;return a.tag===3?a.stateNode:null}var Ks={};function n$(a,s,u,m){this.tag=a,this.key=u,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=s,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=m,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Ln(a,s,u,m){return new n$(a,s,u,m)}function Wp(a){return a=a.prototype,!(!a||!a.isReactComponent)}function ca(a,s){var u=a.alternate;return u===null?(u=Ln(a.tag,s,a.key,a.mode),u.elementType=a.elementType,u.type=a.type,u.stateNode=a.stateNode,u.alternate=a,a.alternate=u):(u.pendingProps=s,u.type=a.type,u.flags=0,u.subtreeFlags=0,u.deletions=null),u.flags=a.flags&65011712,u.childLanes=a.childLanes,u.lanes=a.lanes,u.child=a.child,u.memoizedProps=a.memoizedProps,u.memoizedState=a.memoizedState,u.updateQueue=a.updateQueue,s=a.dependencies,u.dependencies=s===null?null:{lanes:s.lanes,firstContext:s.firstContext},u.sibling=a.sibling,u.index=a.index,u.ref=a.ref,u.refCleanup=a.refCleanup,u}function aA(a,s){a.flags&=65011714;var u=a.alternate;return u===null?(a.childLanes=0,a.lanes=s,a.child=null,a.subtreeFlags=0,a.memoizedProps=null,a.memoizedState=null,a.updateQueue=null,a.dependencies=null,a.stateNode=null):(a.childLanes=u.childLanes,a.lanes=u.lanes,a.child=u.child,a.subtreeFlags=0,a.deletions=null,a.memoizedProps=u.memoizedProps,a.memoizedState=u.memoizedState,a.updateQueue=u.updateQueue,a.type=u.type,s=u.dependencies,a.dependencies=s===null?null:{lanes:s.lanes,firstContext:s.firstContext}),a}function Tf(a,s,u,m,g,v){var C=0;if(m=a,typeof a=="function")Wp(a)&&(C=1);else if(typeof a=="string")C=oB(a,u,fe.current)?26:a==="html"||a==="head"||a==="body"?27:5;else e:switch(a){case R:return a=Ln(31,u,s,g),a.elementType=R,a.lanes=v,a;case S:return Hi(u.children,g,v,s);case b:C=8,g|=24;break;case A:return a=Ln(12,u,s,g|2),a.elementType=A,a.lanes=v,a;case N:return a=Ln(13,u,s,g),a.elementType=N,a.lanes=v,a;case E:return a=Ln(19,u,s,g),a.elementType=E,a.lanes=v,a;default:if(typeof a=="object"&&a!==null)switch(a.$$typeof){case O:C=10;break e;case _:C=9;break e;case T:C=11;break e;case M:C=14;break e;case D:C=16,m=null;break e}C=29,u=Error(r(130,a===null?"null":typeof a,"")),m=null}return s=Ln(C,u,s,g),s.elementType=a,s.type=m,s.lanes=v,s}function Hi(a,s,u,m){return a=Ln(7,a,m,s),a.lanes=u,a}function Zp(a,s,u){return a=Ln(6,a,null,s),a.lanes=u,a}function iA(a){var s=Ln(18,null,null,0);return s.stateNode=a,s}function Qp(a,s,u){return s=Ln(4,a.children!==null?a.children:[],a.key,s),s.lanes=u,s.stateNode={containerInfo:a.containerInfo,pendingChildren:null,implementation:a.implementation},s}var sA=new WeakMap;function rr(a,s){if(typeof a=="object"&&a!==null){var u=sA.get(a);return u!==void 0?u:(s={value:a,source:s,stack:wr(s)},sA.set(a,s),s)}return{value:a,source:s,stack:wr(s)}}var Ys=[],Xs=0,Ef=null,Fl=0,ar=[],ir=0,Qa=null,Ir=1,Ur="";function ua(a,s){Ys[Xs++]=Fl,Ys[Xs++]=Ef,Ef=a,Fl=s}function oA(a,s,u){ar[ir++]=Ir,ar[ir++]=Ur,ar[ir++]=Qa,Qa=a;var m=Ir;a=Ur;var g=32-Dn(m)-1;m&=~(1<<g),u+=1;var v=32-Dn(s)+g;if(30<v){var C=g-g%5;v=(m&(1<<C)-1).toString(32),m>>=C,g-=C,Ir=1<<32-Dn(s)+g|u<<g|m,Ur=v+a}else Ir=1<<v|u<<g|m,Ur=a}function Jp(a){a.return!==null&&(ua(a,1),oA(a,1,0))}function ey(a){for(;a===Ef;)Ef=Ys[--Xs],Ys[Xs]=null,Fl=Ys[--Xs],Ys[Xs]=null;for(;a===Qa;)Qa=ar[--ir],ar[ir]=null,Ur=ar[--ir],ar[ir]=null,Ir=ar[--ir],ar[ir]=null}function lA(a,s){ar[ir++]=Ir,ar[ir++]=Ur,ar[ir++]=Qa,Ir=s.id,Ur=s.overflow,Qa=a}var rn=null,gt=null,Ge=!1,Ja=null,sr=!1,ty=Error(r(519));function ei(a){var s=Error(r(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw Gl(rr(s,a)),ty}function cA(a){var s=a.stateNode,u=a.type,m=a.memoizedProps;switch(s[nn]=a,s[Nn]=m,u){case"dialog":Ve("cancel",s),Ve("close",s);break;case"iframe":case"object":case"embed":Ve("load",s);break;case"video":case"audio":for(u=0;u<mc.length;u++)Ve(mc[u],s);break;case"source":Ve("error",s);break;case"img":case"image":case"link":Ve("error",s),Ve("load",s);break;case"details":Ve("toggle",s);break;case"input":Ve("invalid",s),wN(s,m.value,m.defaultValue,m.checked,m.defaultChecked,m.type,m.name,!0);break;case"select":Ve("invalid",s);break;case"textarea":Ve("invalid",s),NN(s,m.value,m.defaultValue,m.children)}u=m.children,typeof u!="string"&&typeof u!="number"&&typeof u!="bigint"||s.textContent===""+u||m.suppressHydrationWarning===!0||OO(s.textContent,u)?(m.popover!=null&&(Ve("beforetoggle",s),Ve("toggle",s)),m.onScroll!=null&&Ve("scroll",s),m.onScrollEnd!=null&&Ve("scrollend",s),m.onClick!=null&&(s.onclick=oa),s=!0):s=!1,s||ei(a,!0)}function uA(a){for(rn=a.return;rn;)switch(rn.tag){case 5:case 31:case 13:sr=!1;return;case 27:case 3:sr=!0;return;default:rn=rn.return}}function Ws(a){if(a!==rn)return!1;if(!Ge)return uA(a),Ge=!0,!1;var s=a.tag,u;if((u=s!==3&&s!==27)&&((u=s===5)&&(u=a.type,u=!(u!=="form"&&u!=="button")||vx(a.type,a.memoizedProps)),u=!u),u&>&&ei(a),uA(a),s===13){if(a=a.memoizedState,a=a!==null?a.dehydrated:null,!a)throw Error(r(317));gt=DO(a)}else if(s===31){if(a=a.memoizedState,a=a!==null?a.dehydrated:null,!a)throw Error(r(317));gt=DO(a)}else s===27?(s=gt,mi(a.type)?(a=Nx,Nx=null,gt=a):gt=s):gt=rn?lr(a.stateNode.nextSibling):null;return!0}function Fi(){gt=rn=null,Ge=!1}function ny(){var a=Ja;return a!==null&&(En===null?En=a:En.push.apply(En,a),Ja=null),a}function Gl(a){Ja===null?Ja=[a]:Ja.push(a)}var ry=L(null),Gi=null,fa=null;function ti(a,s,u){ae(ry,s._currentValue),s._currentValue=u}function da(a){a._currentValue=ry.current,F(ry)}function ay(a,s,u){for(;a!==null;){var m=a.alternate;if((a.childLanes&s)!==s?(a.childLanes|=s,m!==null&&(m.childLanes|=s)):m!==null&&(m.childLanes&s)!==s&&(m.childLanes|=s),a===u)break;a=a.return}}function iy(a,s,u,m){var g=a.child;for(g!==null&&(g.return=a);g!==null;){var v=g.dependencies;if(v!==null){var C=g.child;v=v.firstContext;e:for(;v!==null;){var k=v;v=g;for(var I=0;I<s.length;I++)if(k.context===s[I]){v.lanes|=u,k=v.alternate,k!==null&&(k.lanes|=u),ay(v.return,u,a),m||(C=null);break e}v=k.next}}else if(g.tag===18){if(C=g.return,C===null)throw Error(r(341));C.lanes|=u,v=C.alternate,v!==null&&(v.lanes|=u),ay(C,u,a),C=null}else C=g.child;if(C!==null)C.return=g;else for(C=g;C!==null;){if(C===a){C=null;break}if(g=C.sibling,g!==null){g.return=C.return,C=g;break}C=C.return}g=C}}function Zs(a,s,u,m){a=null;for(var g=s,v=!1;g!==null;){if(!v){if((g.flags&524288)!==0)v=!0;else if((g.flags&262144)!==0)break}if(g.tag===10){var C=g.alternate;if(C===null)throw Error(r(387));if(C=C.memoizedProps,C!==null){var k=g.type;zn(g.pendingProps.value,C.value)||(a!==null?a.push(k):a=[k])}}else if(g===qe.current){if(C=g.alternate,C===null)throw Error(r(387));C.memoizedState.memoizedState!==g.memoizedState.memoizedState&&(a!==null?a.push(vc):a=[vc])}g=g.return}a!==null&&iy(s,a,u,m),s.flags|=262144}function Cf(a){for(a=a.firstContext;a!==null;){if(!zn(a.context._currentValue,a.memoizedValue))return!0;a=a.next}return!1}function Ki(a){Gi=a,fa=null,a=a.dependencies,a!==null&&(a.firstContext=null)}function an(a){return fA(Gi,a)}function Mf(a,s){return Gi===null&&Ki(a),fA(a,s)}function fA(a,s){var u=s._currentValue;if(s={context:s,memoizedValue:u,next:null},fa===null){if(a===null)throw Error(r(308));fa=s,a.dependencies={lanes:0,firstContext:s},a.flags|=524288}else fa=fa.next=s;return u}var r$=typeof AbortController<"u"?AbortController:function(){var a=[],s=this.signal={aborted:!1,addEventListener:function(u,m){a.push(m)}};this.abort=function(){s.aborted=!0,a.forEach(function(u){return u()})}},a$=e.unstable_scheduleCallback,i$=e.unstable_NormalPriority,zt={$$typeof:O,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function sy(){return{controller:new r$,data:new Map,refCount:0}}function Kl(a){a.refCount--,a.refCount===0&&a$(i$,function(){a.controller.abort()})}var Yl=null,oy=0,Qs=0,Js=null;function s$(a,s){if(Yl===null){var u=Yl=[];oy=0,Qs=ux(),Js={status:"pending",value:void 0,then:function(m){u.push(m)}}}return oy++,s.then(dA,dA),s}function dA(){if(--oy===0&&Yl!==null){Js!==null&&(Js.status="fulfilled");var a=Yl;Yl=null,Qs=0,Js=null;for(var s=0;s<a.length;s++)(0,a[s])()}}function o$(a,s){var u=[],m={status:"pending",value:null,reason:null,then:function(g){u.push(g)}};return a.then(function(){m.status="fulfilled",m.value=s;for(var g=0;g<u.length;g++)(0,u[g])(s)},function(g){for(m.status="rejected",m.reason=g,g=0;g<u.length;g++)(0,u[g])(void 0)}),m}var hA=$.S;$.S=function(a,s){W2=dn(),typeof s=="object"&&s!==null&&typeof s.then=="function"&&s$(a,s),hA!==null&&hA(a,s)};var Yi=L(null);function ly(){var a=Yi.current;return a!==null?a:ct.pooledCache}function Pf(a,s){s===null?ae(Yi,Yi.current):ae(Yi,s.pool)}function mA(){var a=ly();return a===null?null:{parent:zt._currentValue,pool:a}}var eo=Error(r(460)),cy=Error(r(474)),Rf=Error(r(542)),kf={then:function(){}};function pA(a){return a=a.status,a==="fulfilled"||a==="rejected"}function yA(a,s,u){switch(u=a[u],u===void 0?a.push(s):u!==s&&(s.then(oa,oa),s=u),s.status){case"fulfilled":return s.value;case"rejected":throw a=s.reason,gA(a),a;default:if(typeof s.status=="string")s.then(oa,oa);else{if(a=ct,a!==null&&100<a.shellSuspendCounter)throw Error(r(482));a=s,a.status="pending",a.then(function(m){if(s.status==="pending"){var g=s;g.status="fulfilled",g.value=m}},function(m){if(s.status==="pending"){var g=s;g.status="rejected",g.reason=m}})}switch(s.status){case"fulfilled":return s.value;case"rejected":throw a=s.reason,gA(a),a}throw Wi=s,eo}}function Xi(a){try{var s=a._init;return s(a._payload)}catch(u){throw u!==null&&typeof u=="object"&&typeof u.then=="function"?(Wi=u,eo):u}}var Wi=null;function xA(){if(Wi===null)throw Error(r(459));var a=Wi;return Wi=null,a}function gA(a){if(a===eo||a===Rf)throw Error(r(483))}var to=null,Xl=0;function Df(a){var s=Xl;return Xl+=1,to===null&&(to=[]),yA(to,a,s)}function Wl(a,s){s=s.props.ref,a.ref=s!==void 0?s:null}function zf(a,s){throw s.$$typeof===x?Error(r(525)):(a=Object.prototype.toString.call(s),Error(r(31,a==="[object Object]"?"object with keys {"+Object.keys(s).join(", ")+"}":a)))}function vA(a){function s(K,V){if(a){var W=K.deletions;W===null?(K.deletions=[V],K.flags|=16):W.push(V)}}function u(K,V){if(!a)return null;for(;V!==null;)s(K,V),V=V.sibling;return null}function m(K){for(var V=new Map;K!==null;)K.key!==null?V.set(K.key,K):V.set(K.index,K),K=K.sibling;return V}function g(K,V){return K=ca(K,V),K.index=0,K.sibling=null,K}function v(K,V,W){return K.index=W,a?(W=K.alternate,W!==null?(W=W.index,W<V?(K.flags|=67108866,V):W):(K.flags|=67108866,V)):(K.flags|=1048576,V)}function C(K){return a&&K.alternate===null&&(K.flags|=67108866),K}function k(K,V,W,se){return V===null||V.tag!==6?(V=Zp(W,K.mode,se),V.return=K,V):(V=g(V,W),V.return=K,V)}function I(K,V,W,se){var je=W.type;return je===S?ne(K,V,W.props.children,se,W.key):V!==null&&(V.elementType===je||typeof je=="object"&&je!==null&&je.$$typeof===D&&Xi(je)===V.type)?(V=g(V,W.props),Wl(V,W),V.return=K,V):(V=Tf(W.type,W.key,W.props,null,K.mode,se),Wl(V,W),V.return=K,V)}function Z(K,V,W,se){return V===null||V.tag!==4||V.stateNode.containerInfo!==W.containerInfo||V.stateNode.implementation!==W.implementation?(V=Qp(W,K.mode,se),V.return=K,V):(V=g(V,W.children||[]),V.return=K,V)}function ne(K,V,W,se,je){return V===null||V.tag!==7?(V=Hi(W,K.mode,se,je),V.return=K,V):(V=g(V,W),V.return=K,V)}function oe(K,V,W){if(typeof V=="string"&&V!==""||typeof V=="number"||typeof V=="bigint")return V=Zp(""+V,K.mode,W),V.return=K,V;if(typeof V=="object"&&V!==null){switch(V.$$typeof){case j:return W=Tf(V.type,V.key,V.props,null,K.mode,W),Wl(W,V),W.return=K,W;case w:return V=Qp(V,K.mode,W),V.return=K,V;case D:return V=Xi(V),oe(K,V,W)}if(Y(V)||z(V))return V=Hi(V,K.mode,W,null),V.return=K,V;if(typeof V.then=="function")return oe(K,Df(V),W);if(V.$$typeof===O)return oe(K,Mf(K,V),W);zf(K,V)}return null}function J(K,V,W,se){var je=V!==null?V.key:null;if(typeof W=="string"&&W!==""||typeof W=="number"||typeof W=="bigint")return je!==null?null:k(K,V,""+W,se);if(typeof W=="object"&&W!==null){switch(W.$$typeof){case j:return W.key===je?I(K,V,W,se):null;case w:return W.key===je?Z(K,V,W,se):null;case D:return W=Xi(W),J(K,V,W,se)}if(Y(W)||z(W))return je!==null?null:ne(K,V,W,se,null);if(typeof W.then=="function")return J(K,V,Df(W),se);if(W.$$typeof===O)return J(K,V,Mf(K,W),se);zf(K,W)}return null}function te(K,V,W,se,je){if(typeof se=="string"&&se!==""||typeof se=="number"||typeof se=="bigint")return K=K.get(W)||null,k(V,K,""+se,je);if(typeof se=="object"&&se!==null){switch(se.$$typeof){case j:return K=K.get(se.key===null?W:se.key)||null,I(V,K,se,je);case w:return K=K.get(se.key===null?W:se.key)||null,Z(V,K,se,je);case D:return se=Xi(se),te(K,V,W,se,je)}if(Y(se)||z(se))return K=K.get(W)||null,ne(V,K,se,je,null);if(typeof se.then=="function")return te(K,V,W,Df(se),je);if(se.$$typeof===O)return te(K,V,W,Mf(V,se),je);zf(V,se)}return null}function pe(K,V,W,se){for(var je=null,Ke=null,ve=V,$e=V=0,Fe=null;ve!==null&&$e<W.length;$e++){ve.index>$e?(Fe=ve,ve=null):Fe=ve.sibling;var Ye=J(K,ve,W[$e],se);if(Ye===null){ve===null&&(ve=Fe);break}a&&ve&&Ye.alternate===null&&s(K,ve),V=v(Ye,V,$e),Ke===null?je=Ye:Ke.sibling=Ye,Ke=Ye,ve=Fe}if($e===W.length)return u(K,ve),Ge&&ua(K,$e),je;if(ve===null){for(;$e<W.length;$e++)ve=oe(K,W[$e],se),ve!==null&&(V=v(ve,V,$e),Ke===null?je=ve:Ke.sibling=ve,Ke=ve);return Ge&&ua(K,$e),je}for(ve=m(ve);$e<W.length;$e++)Fe=te(ve,K,$e,W[$e],se),Fe!==null&&(a&&Fe.alternate!==null&&ve.delete(Fe.key===null?$e:Fe.key),V=v(Fe,V,$e),Ke===null?je=Fe:Ke.sibling=Fe,Ke=Fe);return a&&ve.forEach(function(vi){return s(K,vi)}),Ge&&ua(K,$e),je}function Oe(K,V,W,se){if(W==null)throw Error(r(151));for(var je=null,Ke=null,ve=V,$e=V=0,Fe=null,Ye=W.next();ve!==null&&!Ye.done;$e++,Ye=W.next()){ve.index>$e?(Fe=ve,ve=null):Fe=ve.sibling;var vi=J(K,ve,Ye.value,se);if(vi===null){ve===null&&(ve=Fe);break}a&&ve&&vi.alternate===null&&s(K,ve),V=v(vi,V,$e),Ke===null?je=vi:Ke.sibling=vi,Ke=vi,ve=Fe}if(Ye.done)return u(K,ve),Ge&&ua(K,$e),je;if(ve===null){for(;!Ye.done;$e++,Ye=W.next())Ye=oe(K,Ye.value,se),Ye!==null&&(V=v(Ye,V,$e),Ke===null?je=Ye:Ke.sibling=Ye,Ke=Ye);return Ge&&ua(K,$e),je}for(ve=m(ve);!Ye.done;$e++,Ye=W.next())Ye=te(ve,K,$e,Ye.value,se),Ye!==null&&(a&&Ye.alternate!==null&&ve.delete(Ye.key===null?$e:Ye.key),V=v(Ye,V,$e),Ke===null?je=Ye:Ke.sibling=Ye,Ke=Ye);return a&&ve.forEach(function(gB){return s(K,gB)}),Ge&&ua(K,$e),je}function ot(K,V,W,se){if(typeof W=="object"&&W!==null&&W.type===S&&W.key===null&&(W=W.props.children),typeof W=="object"&&W!==null){switch(W.$$typeof){case j:e:{for(var je=W.key;V!==null;){if(V.key===je){if(je=W.type,je===S){if(V.tag===7){u(K,V.sibling),se=g(V,W.props.children),se.return=K,K=se;break e}}else if(V.elementType===je||typeof je=="object"&&je!==null&&je.$$typeof===D&&Xi(je)===V.type){u(K,V.sibling),se=g(V,W.props),Wl(se,W),se.return=K,K=se;break e}u(K,V);break}else s(K,V);V=V.sibling}W.type===S?(se=Hi(W.props.children,K.mode,se,W.key),se.return=K,K=se):(se=Tf(W.type,W.key,W.props,null,K.mode,se),Wl(se,W),se.return=K,K=se)}return C(K);case w:e:{for(je=W.key;V!==null;){if(V.key===je)if(V.tag===4&&V.stateNode.containerInfo===W.containerInfo&&V.stateNode.implementation===W.implementation){u(K,V.sibling),se=g(V,W.children||[]),se.return=K,K=se;break e}else{u(K,V);break}else s(K,V);V=V.sibling}se=Qp(W,K.mode,se),se.return=K,K=se}return C(K);case D:return W=Xi(W),ot(K,V,W,se)}if(Y(W))return pe(K,V,W,se);if(z(W)){if(je=z(W),typeof je!="function")throw Error(r(150));return W=je.call(W),Oe(K,V,W,se)}if(typeof W.then=="function")return ot(K,V,Df(W),se);if(W.$$typeof===O)return ot(K,V,Mf(K,W),se);zf(K,W)}return typeof W=="string"&&W!==""||typeof W=="number"||typeof W=="bigint"?(W=""+W,V!==null&&V.tag===6?(u(K,V.sibling),se=g(V,W),se.return=K,K=se):(u(K,V),se=Zp(W,K.mode,se),se.return=K,K=se),C(K)):u(K,V)}return function(K,V,W,se){try{Xl=0;var je=ot(K,V,W,se);return to=null,je}catch(ve){if(ve===eo||ve===Rf)throw ve;var Ke=Ln(29,ve,null,K.mode);return Ke.lanes=se,Ke.return=K,Ke}finally{}}}var Zi=vA(!0),bA=vA(!1),ni=!1;function uy(a){a.updateQueue={baseState:a.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function fy(a,s){a=a.updateQueue,s.updateQueue===a&&(s.updateQueue={baseState:a.baseState,firstBaseUpdate:a.firstBaseUpdate,lastBaseUpdate:a.lastBaseUpdate,shared:a.shared,callbacks:null})}function ri(a){return{lane:a,tag:0,payload:null,callback:null,next:null}}function ai(a,s,u){var m=a.updateQueue;if(m===null)return null;if(m=m.shared,(Ze&2)!==0){var g=m.pending;return g===null?s.next=s:(s.next=g.next,g.next=s),m.pending=s,s=_f(a),rA(a,null,u),s}return Of(a,m,s,u),_f(a)}function Zl(a,s,u){if(s=s.updateQueue,s!==null&&(s=s.shared,(u&4194048)!==0)){var m=s.lanes;m&=a.pendingLanes,u|=m,s.lanes=u,fN(a,u)}}function dy(a,s){var u=a.updateQueue,m=a.alternate;if(m!==null&&(m=m.updateQueue,u===m)){var g=null,v=null;if(u=u.firstBaseUpdate,u!==null){do{var C={lane:u.lane,tag:u.tag,payload:u.payload,callback:null,next:null};v===null?g=v=C:v=v.next=C,u=u.next}while(u!==null);v===null?g=v=s:v=v.next=s}else g=v=s;u={baseState:m.baseState,firstBaseUpdate:g,lastBaseUpdate:v,shared:m.shared,callbacks:m.callbacks},a.updateQueue=u;return}a=u.lastBaseUpdate,a===null?u.firstBaseUpdate=s:a.next=s,u.lastBaseUpdate=s}var hy=!1;function Ql(){if(hy){var a=Js;if(a!==null)throw a}}function Jl(a,s,u,m){hy=!1;var g=a.updateQueue;ni=!1;var v=g.firstBaseUpdate,C=g.lastBaseUpdate,k=g.shared.pending;if(k!==null){g.shared.pending=null;var I=k,Z=I.next;I.next=null,C===null?v=Z:C.next=Z,C=I;var ne=a.alternate;ne!==null&&(ne=ne.updateQueue,k=ne.lastBaseUpdate,k!==C&&(k===null?ne.firstBaseUpdate=Z:k.next=Z,ne.lastBaseUpdate=I))}if(v!==null){var oe=g.baseState;C=0,ne=Z=I=null,k=v;do{var J=k.lane&-536870913,te=J!==k.lane;if(te?(He&J)===J:(m&J)===J){J!==0&&J===Qs&&(hy=!0),ne!==null&&(ne=ne.next={lane:0,tag:k.tag,payload:k.payload,callback:null,next:null});e:{var pe=a,Oe=k;J=s;var ot=u;switch(Oe.tag){case 1:if(pe=Oe.payload,typeof pe=="function"){oe=pe.call(ot,oe,J);break e}oe=pe;break e;case 3:pe.flags=pe.flags&-65537|128;case 0:if(pe=Oe.payload,J=typeof pe=="function"?pe.call(ot,oe,J):pe,J==null)break e;oe=y({},oe,J);break e;case 2:ni=!0}}J=k.callback,J!==null&&(a.flags|=64,te&&(a.flags|=8192),te=g.callbacks,te===null?g.callbacks=[J]:te.push(J))}else te={lane:J,tag:k.tag,payload:k.payload,callback:k.callback,next:null},ne===null?(Z=ne=te,I=oe):ne=ne.next=te,C|=J;if(k=k.next,k===null){if(k=g.shared.pending,k===null)break;te=k,k=te.next,te.next=null,g.lastBaseUpdate=te,g.shared.pending=null}}while(!0);ne===null&&(I=oe),g.baseState=I,g.firstBaseUpdate=Z,g.lastBaseUpdate=ne,v===null&&(g.shared.lanes=0),ci|=C,a.lanes=C,a.memoizedState=oe}}function jA(a,s){if(typeof a!="function")throw Error(r(191,a));a.call(s)}function wA(a,s){var u=a.callbacks;if(u!==null)for(a.callbacks=null,a=0;a<u.length;a++)jA(u[a],s)}var no=L(null),Lf=L(0);function SA(a,s){a=ja,ae(Lf,a),ae(no,s),ja=a|s.baseLanes}function my(){ae(Lf,ja),ae(no,no.current)}function py(){ja=Lf.current,F(no),F(Lf)}var $n=L(null),or=null;function ii(a){var s=a.alternate;ae(kt,kt.current&1),ae($n,a),or===null&&(s===null||no.current!==null||s.memoizedState!==null)&&(or=a)}function yy(a){ae(kt,kt.current),ae($n,a),or===null&&(or=a)}function NA(a){a.tag===22?(ae(kt,kt.current),ae($n,a),or===null&&(or=a)):si()}function si(){ae(kt,kt.current),ae($n,$n.current)}function Bn(a){F($n),or===a&&(or=null),F(kt)}var kt=L(0);function $f(a){for(var s=a;s!==null;){if(s.tag===13){var u=s.memoizedState;if(u!==null&&(u=u.dehydrated,u===null||wx(u)||Sx(u)))return s}else if(s.tag===19&&(s.memoizedProps.revealOrder==="forwards"||s.memoizedProps.revealOrder==="backwards"||s.memoizedProps.revealOrder==="unstable_legacy-backwards"||s.memoizedProps.revealOrder==="together")){if((s.flags&128)!==0)return s}else if(s.child!==null){s.child.return=s,s=s.child;continue}if(s===a)break;for(;s.sibling===null;){if(s.return===null||s.return===a)return null;s=s.return}s.sibling.return=s.return,s=s.sibling}return null}var ha=0,De=null,it=null,Lt=null,Bf=!1,ro=!1,Qi=!1,qf=0,ec=0,ao=null,l$=0;function Et(){throw Error(r(321))}function xy(a,s){if(s===null)return!1;for(var u=0;u<s.length&&u<a.length;u++)if(!zn(a[u],s[u]))return!1;return!0}function gy(a,s,u,m,g,v){return ha=v,De=s,s.memoizedState=null,s.updateQueue=null,s.lanes=0,$.H=a===null||a.memoizedState===null?o2:Ry,Qi=!1,v=u(m,g),Qi=!1,ro&&(v=OA(s,u,m,g)),AA(a),v}function AA(a){$.H=rc;var s=it!==null&&it.next!==null;if(ha=0,Lt=it=De=null,Bf=!1,ec=0,ao=null,s)throw Error(r(300));a===null||$t||(a=a.dependencies,a!==null&&Cf(a)&&($t=!0))}function OA(a,s,u,m){De=a;var g=0;do{if(ro&&(ao=null),ec=0,ro=!1,25<=g)throw Error(r(301));if(g+=1,Lt=it=null,a.updateQueue!=null){var v=a.updateQueue;v.lastEffect=null,v.events=null,v.stores=null,v.memoCache!=null&&(v.memoCache.index=0)}$.H=l2,v=s(u,m)}while(ro);return v}function c$(){var a=$.H,s=a.useState()[0];return s=typeof s.then=="function"?tc(s):s,a=a.useState()[0],(it!==null?it.memoizedState:null)!==a&&(De.flags|=1024),s}function vy(){var a=qf!==0;return qf=0,a}function by(a,s,u){s.updateQueue=a.updateQueue,s.flags&=-2053,a.lanes&=~u}function jy(a){if(Bf){for(a=a.memoizedState;a!==null;){var s=a.queue;s!==null&&(s.pending=null),a=a.next}Bf=!1}ha=0,Lt=it=De=null,ro=!1,ec=qf=0,ao=null}function xn(){var a={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Lt===null?De.memoizedState=Lt=a:Lt=Lt.next=a,Lt}function Dt(){if(it===null){var a=De.alternate;a=a!==null?a.memoizedState:null}else a=it.next;var s=Lt===null?De.memoizedState:Lt.next;if(s!==null)Lt=s,it=a;else{if(a===null)throw De.alternate===null?Error(r(467)):Error(r(310));it=a,a={memoizedState:it.memoizedState,baseState:it.baseState,baseQueue:it.baseQueue,queue:it.queue,next:null},Lt===null?De.memoizedState=Lt=a:Lt=Lt.next=a}return Lt}function If(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function tc(a){var s=ec;return ec+=1,ao===null&&(ao=[]),a=yA(ao,a,s),s=De,(Lt===null?s.memoizedState:Lt.next)===null&&(s=s.alternate,$.H=s===null||s.memoizedState===null?o2:Ry),a}function Uf(a){if(a!==null&&typeof a=="object"){if(typeof a.then=="function")return tc(a);if(a.$$typeof===O)return an(a)}throw Error(r(438,String(a)))}function wy(a){var s=null,u=De.updateQueue;if(u!==null&&(s=u.memoCache),s==null){var m=De.alternate;m!==null&&(m=m.updateQueue,m!==null&&(m=m.memoCache,m!=null&&(s={data:m.data.map(function(g){return g.slice()}),index:0})))}if(s==null&&(s={data:[],index:0}),u===null&&(u=If(),De.updateQueue=u),u.memoCache=s,u=s.data[s.index],u===void 0)for(u=s.data[s.index]=Array(a),m=0;m<a;m++)u[m]=B;return s.index++,u}function ma(a,s){return typeof s=="function"?s(a):s}function Vf(a){var s=Dt();return Sy(s,it,a)}function Sy(a,s,u){var m=a.queue;if(m===null)throw Error(r(311));m.lastRenderedReducer=u;var g=a.baseQueue,v=m.pending;if(v!==null){if(g!==null){var C=g.next;g.next=v.next,v.next=C}s.baseQueue=g=v,m.pending=null}if(v=a.baseState,g===null)a.memoizedState=v;else{s=g.next;var k=C=null,I=null,Z=s,ne=!1;do{var oe=Z.lane&-536870913;if(oe!==Z.lane?(He&oe)===oe:(ha&oe)===oe){var J=Z.revertLane;if(J===0)I!==null&&(I=I.next={lane:0,revertLane:0,gesture:null,action:Z.action,hasEagerState:Z.hasEagerState,eagerState:Z.eagerState,next:null}),oe===Qs&&(ne=!0);else if((ha&J)===J){Z=Z.next,J===Qs&&(ne=!0);continue}else oe={lane:0,revertLane:Z.revertLane,gesture:null,action:Z.action,hasEagerState:Z.hasEagerState,eagerState:Z.eagerState,next:null},I===null?(k=I=oe,C=v):I=I.next=oe,De.lanes|=J,ci|=J;oe=Z.action,Qi&&u(v,oe),v=Z.hasEagerState?Z.eagerState:u(v,oe)}else J={lane:oe,revertLane:Z.revertLane,gesture:Z.gesture,action:Z.action,hasEagerState:Z.hasEagerState,eagerState:Z.eagerState,next:null},I===null?(k=I=J,C=v):I=I.next=J,De.lanes|=oe,ci|=oe;Z=Z.next}while(Z!==null&&Z!==s);if(I===null?C=v:I.next=k,!zn(v,a.memoizedState)&&($t=!0,ne&&(u=Js,u!==null)))throw u;a.memoizedState=v,a.baseState=C,a.baseQueue=I,m.lastRenderedState=v}return g===null&&(m.lanes=0),[a.memoizedState,m.dispatch]}function Ny(a){var s=Dt(),u=s.queue;if(u===null)throw Error(r(311));u.lastRenderedReducer=a;var m=u.dispatch,g=u.pending,v=s.memoizedState;if(g!==null){u.pending=null;var C=g=g.next;do v=a(v,C.action),C=C.next;while(C!==g);zn(v,s.memoizedState)||($t=!0),s.memoizedState=v,s.baseQueue===null&&(s.baseState=v),u.lastRenderedState=v}return[v,m]}function _A(a,s,u){var m=De,g=Dt(),v=Ge;if(v){if(u===void 0)throw Error(r(407));u=u()}else u=s();var C=!zn((it||g).memoizedState,u);if(C&&(g.memoizedState=u,$t=!0),g=g.queue,_y(CA.bind(null,m,g,a),[a]),g.getSnapshot!==s||C||Lt!==null&&Lt.memoizedState.tag&1){if(m.flags|=2048,io(9,{destroy:void 0},EA.bind(null,m,g,u,s),null),ct===null)throw Error(r(349));v||(ha&127)!==0||TA(m,s,u)}return u}function TA(a,s,u){a.flags|=16384,a={getSnapshot:s,value:u},s=De.updateQueue,s===null?(s=If(),De.updateQueue=s,s.stores=[a]):(u=s.stores,u===null?s.stores=[a]:u.push(a))}function EA(a,s,u,m){s.value=u,s.getSnapshot=m,MA(s)&&PA(a)}function CA(a,s,u){return u(function(){MA(s)&&PA(a)})}function MA(a){var s=a.getSnapshot;a=a.value;try{var u=s();return!zn(a,u)}catch{return!0}}function PA(a){var s=Vi(a,2);s!==null&&Cn(s,a,2)}function Ay(a){var s=xn();if(typeof a=="function"){var u=a;if(a=u(),Qi){Xa(!0);try{u()}finally{Xa(!1)}}}return s.memoizedState=s.baseState=a,s.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:ma,lastRenderedState:a},s}function RA(a,s,u,m){return a.baseState=u,Sy(a,it,typeof m=="function"?m:ma)}function u$(a,s,u,m,g){if(Gf(a))throw Error(r(485));if(a=s.action,a!==null){var v={payload:g,action:a,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(C){v.listeners.push(C)}};$.T!==null?u(!0):v.isTransition=!1,m(v),u=s.pending,u===null?(v.next=s.pending=v,kA(s,v)):(v.next=u.next,s.pending=u.next=v)}}function kA(a,s){var u=s.action,m=s.payload,g=a.state;if(s.isTransition){var v=$.T,C={};$.T=C;try{var k=u(g,m),I=$.S;I!==null&&I(C,k),DA(a,s,k)}catch(Z){Oy(a,s,Z)}finally{v!==null&&C.types!==null&&(v.types=C.types),$.T=v}}else try{v=u(g,m),DA(a,s,v)}catch(Z){Oy(a,s,Z)}}function DA(a,s,u){u!==null&&typeof u=="object"&&typeof u.then=="function"?u.then(function(m){zA(a,s,m)},function(m){return Oy(a,s,m)}):zA(a,s,u)}function zA(a,s,u){s.status="fulfilled",s.value=u,LA(s),a.state=u,s=a.pending,s!==null&&(u=s.next,u===s?a.pending=null:(u=u.next,s.next=u,kA(a,u)))}function Oy(a,s,u){var m=a.pending;if(a.pending=null,m!==null){m=m.next;do s.status="rejected",s.reason=u,LA(s),s=s.next;while(s!==m)}a.action=null}function LA(a){a=a.listeners;for(var s=0;s<a.length;s++)(0,a[s])()}function $A(a,s){return s}function BA(a,s){if(Ge){var u=ct.formState;if(u!==null){e:{var m=De;if(Ge){if(gt){t:{for(var g=gt,v=sr;g.nodeType!==8;){if(!v){g=null;break t}if(g=lr(g.nextSibling),g===null){g=null;break t}}v=g.data,g=v==="F!"||v==="F"?g:null}if(g){gt=lr(g.nextSibling),m=g.data==="F!";break e}}ei(m)}m=!1}m&&(s=u[0])}}return u=xn(),u.memoizedState=u.baseState=s,m={pending:null,lanes:0,dispatch:null,lastRenderedReducer:$A,lastRenderedState:s},u.queue=m,u=a2.bind(null,De,m),m.dispatch=u,m=Ay(!1),v=Py.bind(null,De,!1,m.queue),m=xn(),g={state:s,dispatch:null,action:a,pending:null},m.queue=g,u=u$.bind(null,De,g,v,u),g.dispatch=u,m.memoizedState=a,[s,u,!1]}function qA(a){var s=Dt();return IA(s,it,a)}function IA(a,s,u){if(s=Sy(a,s,$A)[0],a=Vf(ma)[0],typeof s=="object"&&s!==null&&typeof s.then=="function")try{var m=tc(s)}catch(C){throw C===eo?Rf:C}else m=s;s=Dt();var g=s.queue,v=g.dispatch;return u!==s.memoizedState&&(De.flags|=2048,io(9,{destroy:void 0},f$.bind(null,g,u),null)),[m,v,a]}function f$(a,s){a.action=s}function UA(a){var s=Dt(),u=it;if(u!==null)return IA(s,u,a);Dt(),s=s.memoizedState,u=Dt();var m=u.queue.dispatch;return u.memoizedState=a,[s,m,!1]}function io(a,s,u,m){return a={tag:a,create:u,deps:m,inst:s,next:null},s=De.updateQueue,s===null&&(s=If(),De.updateQueue=s),u=s.lastEffect,u===null?s.lastEffect=a.next=a:(m=u.next,u.next=a,a.next=m,s.lastEffect=a),a}function VA(){return Dt().memoizedState}function Hf(a,s,u,m){var g=xn();De.flags|=a,g.memoizedState=io(1|s,{destroy:void 0},u,m===void 0?null:m)}function Ff(a,s,u,m){var g=Dt();m=m===void 0?null:m;var v=g.memoizedState.inst;it!==null&&m!==null&&xy(m,it.memoizedState.deps)?g.memoizedState=io(s,v,u,m):(De.flags|=a,g.memoizedState=io(1|s,v,u,m))}function HA(a,s){Hf(8390656,8,a,s)}function _y(a,s){Ff(2048,8,a,s)}function d$(a){De.flags|=4;var s=De.updateQueue;if(s===null)s=If(),De.updateQueue=s,s.events=[a];else{var u=s.events;u===null?s.events=[a]:u.push(a)}}function FA(a){var s=Dt().memoizedState;return d$({ref:s,nextImpl:a}),function(){if((Ze&2)!==0)throw Error(r(440));return s.impl.apply(void 0,arguments)}}function GA(a,s){return Ff(4,2,a,s)}function KA(a,s){return Ff(4,4,a,s)}function YA(a,s){if(typeof s=="function"){a=a();var u=s(a);return function(){typeof u=="function"?u():s(null)}}if(s!=null)return a=a(),s.current=a,function(){s.current=null}}function XA(a,s,u){u=u!=null?u.concat([a]):null,Ff(4,4,YA.bind(null,s,a),u)}function Ty(){}function WA(a,s){var u=Dt();s=s===void 0?null:s;var m=u.memoizedState;return s!==null&&xy(s,m[1])?m[0]:(u.memoizedState=[a,s],a)}function ZA(a,s){var u=Dt();s=s===void 0?null:s;var m=u.memoizedState;if(s!==null&&xy(s,m[1]))return m[0];if(m=a(),Qi){Xa(!0);try{a()}finally{Xa(!1)}}return u.memoizedState=[m,s],m}function Ey(a,s,u){return u===void 0||(ha&1073741824)!==0&&(He&261930)===0?a.memoizedState=s:(a.memoizedState=u,a=Q2(),De.lanes|=a,ci|=a,u)}function QA(a,s,u,m){return zn(u,s)?u:no.current!==null?(a=Ey(a,u,m),zn(a,s)||($t=!0),a):(ha&42)===0||(ha&1073741824)!==0&&(He&261930)===0?($t=!0,a.memoizedState=u):(a=Q2(),De.lanes|=a,ci|=a,s)}function JA(a,s,u,m,g){var v=G.p;G.p=v!==0&&8>v?v:8;var C=$.T,k={};$.T=k,Py(a,!1,s,u);try{var I=g(),Z=$.S;if(Z!==null&&Z(k,I),I!==null&&typeof I=="object"&&typeof I.then=="function"){var ne=o$(I,m);nc(a,s,ne,Un(a))}else nc(a,s,m,Un(a))}catch(oe){nc(a,s,{then:function(){},status:"rejected",reason:oe},Un())}finally{G.p=v,C!==null&&k.types!==null&&(C.types=k.types),$.T=C}}function h$(){}function Cy(a,s,u,m){if(a.tag!==5)throw Error(r(476));var g=e2(a).queue;JA(a,g,s,Q,u===null?h$:function(){return t2(a),u(m)})}function e2(a){var s=a.memoizedState;if(s!==null)return s;s={memoizedState:Q,baseState:Q,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:ma,lastRenderedState:Q},next:null};var u={};return s.next={memoizedState:u,baseState:u,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:ma,lastRenderedState:u},next:null},a.memoizedState=s,a=a.alternate,a!==null&&(a.memoizedState=s),s}function t2(a){var s=e2(a);s.next===null&&(s=a.alternate.memoizedState),nc(a,s.next.queue,{},Un())}function My(){return an(vc)}function n2(){return Dt().memoizedState}function r2(){return Dt().memoizedState}function m$(a){for(var s=a.return;s!==null;){switch(s.tag){case 24:case 3:var u=Un();a=ri(u);var m=ai(s,a,u);m!==null&&(Cn(m,s,u),Zl(m,s,u)),s={cache:sy()},a.payload=s;return}s=s.return}}function p$(a,s,u){var m=Un();u={lane:m,revertLane:0,gesture:null,action:u,hasEagerState:!1,eagerState:null,next:null},Gf(a)?i2(s,u):(u=Xp(a,s,u,m),u!==null&&(Cn(u,a,m),s2(u,s,m)))}function a2(a,s,u){var m=Un();nc(a,s,u,m)}function nc(a,s,u,m){var g={lane:m,revertLane:0,gesture:null,action:u,hasEagerState:!1,eagerState:null,next:null};if(Gf(a))i2(s,g);else{var v=a.alternate;if(a.lanes===0&&(v===null||v.lanes===0)&&(v=s.lastRenderedReducer,v!==null))try{var C=s.lastRenderedState,k=v(C,u);if(g.hasEagerState=!0,g.eagerState=k,zn(k,C))return Of(a,s,g,0),ct===null&&Af(),!1}catch{}finally{}if(u=Xp(a,s,g,m),u!==null)return Cn(u,a,m),s2(u,s,m),!0}return!1}function Py(a,s,u,m){if(m={lane:2,revertLane:ux(),gesture:null,action:m,hasEagerState:!1,eagerState:null,next:null},Gf(a)){if(s)throw Error(r(479))}else s=Xp(a,u,m,2),s!==null&&Cn(s,a,2)}function Gf(a){var s=a.alternate;return a===De||s!==null&&s===De}function i2(a,s){ro=Bf=!0;var u=a.pending;u===null?s.next=s:(s.next=u.next,u.next=s),a.pending=s}function s2(a,s,u){if((u&4194048)!==0){var m=s.lanes;m&=a.pendingLanes,u|=m,s.lanes=u,fN(a,u)}}var rc={readContext:an,use:Uf,useCallback:Et,useContext:Et,useEffect:Et,useImperativeHandle:Et,useLayoutEffect:Et,useInsertionEffect:Et,useMemo:Et,useReducer:Et,useRef:Et,useState:Et,useDebugValue:Et,useDeferredValue:Et,useTransition:Et,useSyncExternalStore:Et,useId:Et,useHostTransitionStatus:Et,useFormState:Et,useActionState:Et,useOptimistic:Et,useMemoCache:Et,useCacheRefresh:Et};rc.useEffectEvent=Et;var o2={readContext:an,use:Uf,useCallback:function(a,s){return xn().memoizedState=[a,s===void 0?null:s],a},useContext:an,useEffect:HA,useImperativeHandle:function(a,s,u){u=u!=null?u.concat([a]):null,Hf(4194308,4,YA.bind(null,s,a),u)},useLayoutEffect:function(a,s){return Hf(4194308,4,a,s)},useInsertionEffect:function(a,s){Hf(4,2,a,s)},useMemo:function(a,s){var u=xn();s=s===void 0?null:s;var m=a();if(Qi){Xa(!0);try{a()}finally{Xa(!1)}}return u.memoizedState=[m,s],m},useReducer:function(a,s,u){var m=xn();if(u!==void 0){var g=u(s);if(Qi){Xa(!0);try{u(s)}finally{Xa(!1)}}}else g=s;return m.memoizedState=m.baseState=g,a={pending:null,lanes:0,dispatch:null,lastRenderedReducer:a,lastRenderedState:g},m.queue=a,a=a.dispatch=p$.bind(null,De,a),[m.memoizedState,a]},useRef:function(a){var s=xn();return a={current:a},s.memoizedState=a},useState:function(a){a=Ay(a);var s=a.queue,u=a2.bind(null,De,s);return s.dispatch=u,[a.memoizedState,u]},useDebugValue:Ty,useDeferredValue:function(a,s){var u=xn();return Ey(u,a,s)},useTransition:function(){var a=Ay(!1);return a=JA.bind(null,De,a.queue,!0,!1),xn().memoizedState=a,[!1,a]},useSyncExternalStore:function(a,s,u){var m=De,g=xn();if(Ge){if(u===void 0)throw Error(r(407));u=u()}else{if(u=s(),ct===null)throw Error(r(349));(He&127)!==0||TA(m,s,u)}g.memoizedState=u;var v={value:u,getSnapshot:s};return g.queue=v,HA(CA.bind(null,m,v,a),[a]),m.flags|=2048,io(9,{destroy:void 0},EA.bind(null,m,v,u,s),null),u},useId:function(){var a=xn(),s=ct.identifierPrefix;if(Ge){var u=Ur,m=Ir;u=(m&~(1<<32-Dn(m)-1)).toString(32)+u,s="_"+s+"R_"+u,u=qf++,0<u&&(s+="H"+u.toString(32)),s+="_"}else u=l$++,s="_"+s+"r_"+u.toString(32)+"_";return a.memoizedState=s},useHostTransitionStatus:My,useFormState:BA,useActionState:BA,useOptimistic:function(a){var s=xn();s.memoizedState=s.baseState=a;var u={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return s.queue=u,s=Py.bind(null,De,!0,u),u.dispatch=s,[a,s]},useMemoCache:wy,useCacheRefresh:function(){return xn().memoizedState=m$.bind(null,De)},useEffectEvent:function(a){var s=xn(),u={impl:a};return s.memoizedState=u,function(){if((Ze&2)!==0)throw Error(r(440));return u.impl.apply(void 0,arguments)}}},Ry={readContext:an,use:Uf,useCallback:WA,useContext:an,useEffect:_y,useImperativeHandle:XA,useInsertionEffect:GA,useLayoutEffect:KA,useMemo:ZA,useReducer:Vf,useRef:VA,useState:function(){return Vf(ma)},useDebugValue:Ty,useDeferredValue:function(a,s){var u=Dt();return QA(u,it.memoizedState,a,s)},useTransition:function(){var a=Vf(ma)[0],s=Dt().memoizedState;return[typeof a=="boolean"?a:tc(a),s]},useSyncExternalStore:_A,useId:n2,useHostTransitionStatus:My,useFormState:qA,useActionState:qA,useOptimistic:function(a,s){var u=Dt();return RA(u,it,a,s)},useMemoCache:wy,useCacheRefresh:r2};Ry.useEffectEvent=FA;var l2={readContext:an,use:Uf,useCallback:WA,useContext:an,useEffect:_y,useImperativeHandle:XA,useInsertionEffect:GA,useLayoutEffect:KA,useMemo:ZA,useReducer:Ny,useRef:VA,useState:function(){return Ny(ma)},useDebugValue:Ty,useDeferredValue:function(a,s){var u=Dt();return it===null?Ey(u,a,s):QA(u,it.memoizedState,a,s)},useTransition:function(){var a=Ny(ma)[0],s=Dt().memoizedState;return[typeof a=="boolean"?a:tc(a),s]},useSyncExternalStore:_A,useId:n2,useHostTransitionStatus:My,useFormState:UA,useActionState:UA,useOptimistic:function(a,s){var u=Dt();return it!==null?RA(u,it,a,s):(u.baseState=a,[a,u.queue.dispatch])},useMemoCache:wy,useCacheRefresh:r2};l2.useEffectEvent=FA;function ky(a,s,u,m){s=a.memoizedState,u=u(m,s),u=u==null?s:y({},s,u),a.memoizedState=u,a.lanes===0&&(a.updateQueue.baseState=u)}var Dy={enqueueSetState:function(a,s,u){a=a._reactInternals;var m=Un(),g=ri(m);g.payload=s,u!=null&&(g.callback=u),s=ai(a,g,m),s!==null&&(Cn(s,a,m),Zl(s,a,m))},enqueueReplaceState:function(a,s,u){a=a._reactInternals;var m=Un(),g=ri(m);g.tag=1,g.payload=s,u!=null&&(g.callback=u),s=ai(a,g,m),s!==null&&(Cn(s,a,m),Zl(s,a,m))},enqueueForceUpdate:function(a,s){a=a._reactInternals;var u=Un(),m=ri(u);m.tag=2,s!=null&&(m.callback=s),s=ai(a,m,u),s!==null&&(Cn(s,a,u),Zl(s,a,u))}};function c2(a,s,u,m,g,v,C){return a=a.stateNode,typeof a.shouldComponentUpdate=="function"?a.shouldComponentUpdate(m,v,C):s.prototype&&s.prototype.isPureReactComponent?!Vl(u,m)||!Vl(g,v):!0}function u2(a,s,u,m){a=s.state,typeof s.componentWillReceiveProps=="function"&&s.componentWillReceiveProps(u,m),typeof s.UNSAFE_componentWillReceiveProps=="function"&&s.UNSAFE_componentWillReceiveProps(u,m),s.state!==a&&Dy.enqueueReplaceState(s,s.state,null)}function Ji(a,s){var u=s;if("ref"in s){u={};for(var m in s)m!=="ref"&&(u[m]=s[m])}if(a=a.defaultProps){u===s&&(u=y({},u));for(var g in a)u[g]===void 0&&(u[g]=a[g])}return u}function f2(a){Nf(a)}function d2(a){console.error(a)}function h2(a){Nf(a)}function Kf(a,s){try{var u=a.onUncaughtError;u(s.value,{componentStack:s.stack})}catch(m){setTimeout(function(){throw m})}}function m2(a,s,u){try{var m=a.onCaughtError;m(u.value,{componentStack:u.stack,errorBoundary:s.tag===1?s.stateNode:null})}catch(g){setTimeout(function(){throw g})}}function zy(a,s,u){return u=ri(u),u.tag=3,u.payload={element:null},u.callback=function(){Kf(a,s)},u}function p2(a){return a=ri(a),a.tag=3,a}function y2(a,s,u,m){var g=u.type.getDerivedStateFromError;if(typeof g=="function"){var v=m.value;a.payload=function(){return g(v)},a.callback=function(){m2(s,u,m)}}var C=u.stateNode;C!==null&&typeof C.componentDidCatch=="function"&&(a.callback=function(){m2(s,u,m),typeof g!="function"&&(ui===null?ui=new Set([this]):ui.add(this));var k=m.stack;this.componentDidCatch(m.value,{componentStack:k!==null?k:""})})}function y$(a,s,u,m,g){if(u.flags|=32768,m!==null&&typeof m=="object"&&typeof m.then=="function"){if(s=u.alternate,s!==null&&Zs(s,u,g,!0),u=$n.current,u!==null){switch(u.tag){case 31:case 13:return or===null?id():u.alternate===null&&Ct===0&&(Ct=3),u.flags&=-257,u.flags|=65536,u.lanes=g,m===kf?u.flags|=16384:(s=u.updateQueue,s===null?u.updateQueue=new Set([m]):s.add(m),ox(a,m,g)),!1;case 22:return u.flags|=65536,m===kf?u.flags|=16384:(s=u.updateQueue,s===null?(s={transitions:null,markerInstances:null,retryQueue:new Set([m])},u.updateQueue=s):(u=s.retryQueue,u===null?s.retryQueue=new Set([m]):u.add(m)),ox(a,m,g)),!1}throw Error(r(435,u.tag))}return ox(a,m,g),id(),!1}if(Ge)return s=$n.current,s!==null?((s.flags&65536)===0&&(s.flags|=256),s.flags|=65536,s.lanes=g,m!==ty&&(a=Error(r(422),{cause:m}),Gl(rr(a,u)))):(m!==ty&&(s=Error(r(423),{cause:m}),Gl(rr(s,u))),a=a.current.alternate,a.flags|=65536,g&=-g,a.lanes|=g,m=rr(m,u),g=zy(a.stateNode,m,g),dy(a,g),Ct!==4&&(Ct=2)),!1;var v=Error(r(520),{cause:m});if(v=rr(v,u),fc===null?fc=[v]:fc.push(v),Ct!==4&&(Ct=2),s===null)return!0;m=rr(m,u),u=s;do{switch(u.tag){case 3:return u.flags|=65536,a=g&-g,u.lanes|=a,a=zy(u.stateNode,m,a),dy(u,a),!1;case 1:if(s=u.type,v=u.stateNode,(u.flags&128)===0&&(typeof s.getDerivedStateFromError=="function"||v!==null&&typeof v.componentDidCatch=="function"&&(ui===null||!ui.has(v))))return u.flags|=65536,g&=-g,u.lanes|=g,g=p2(g),y2(g,a,u,m),dy(u,g),!1}u=u.return}while(u!==null);return!1}var Ly=Error(r(461)),$t=!1;function sn(a,s,u,m){s.child=a===null?bA(s,null,u,m):Zi(s,a.child,u,m)}function x2(a,s,u,m,g){u=u.render;var v=s.ref;if("ref"in m){var C={};for(var k in m)k!=="ref"&&(C[k]=m[k])}else C=m;return Ki(s),m=gy(a,s,u,C,v,g),k=vy(),a!==null&&!$t?(by(a,s,g),pa(a,s,g)):(Ge&&k&&Jp(s),s.flags|=1,sn(a,s,m,g),s.child)}function g2(a,s,u,m,g){if(a===null){var v=u.type;return typeof v=="function"&&!Wp(v)&&v.defaultProps===void 0&&u.compare===null?(s.tag=15,s.type=v,v2(a,s,v,m,g)):(a=Tf(u.type,null,m,s,s.mode,g),a.ref=s.ref,a.return=s,s.child=a)}if(v=a.child,!Fy(a,g)){var C=v.memoizedProps;if(u=u.compare,u=u!==null?u:Vl,u(C,m)&&a.ref===s.ref)return pa(a,s,g)}return s.flags|=1,a=ca(v,m),a.ref=s.ref,a.return=s,s.child=a}function v2(a,s,u,m,g){if(a!==null){var v=a.memoizedProps;if(Vl(v,m)&&a.ref===s.ref)if($t=!1,s.pendingProps=m=v,Fy(a,g))(a.flags&131072)!==0&&($t=!0);else return s.lanes=a.lanes,pa(a,s,g)}return $y(a,s,u,m,g)}function b2(a,s,u,m){var g=m.children,v=a!==null?a.memoizedState:null;if(a===null&&s.stateNode===null&&(s.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),m.mode==="hidden"){if((s.flags&128)!==0){if(v=v!==null?v.baseLanes|u:u,a!==null){for(m=s.child=a.child,g=0;m!==null;)g=g|m.lanes|m.childLanes,m=m.sibling;m=g&~v}else m=0,s.child=null;return j2(a,s,v,u,m)}if((u&536870912)!==0)s.memoizedState={baseLanes:0,cachePool:null},a!==null&&Pf(s,v!==null?v.cachePool:null),v!==null?SA(s,v):my(),NA(s);else return m=s.lanes=536870912,j2(a,s,v!==null?v.baseLanes|u:u,u,m)}else v!==null?(Pf(s,v.cachePool),SA(s,v),si(),s.memoizedState=null):(a!==null&&Pf(s,null),my(),si());return sn(a,s,g,u),s.child}function ac(a,s){return a!==null&&a.tag===22||s.stateNode!==null||(s.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),s.sibling}function j2(a,s,u,m,g){var v=ly();return v=v===null?null:{parent:zt._currentValue,pool:v},s.memoizedState={baseLanes:u,cachePool:v},a!==null&&Pf(s,null),my(),NA(s),a!==null&&Zs(a,s,m,!0),s.childLanes=g,null}function Yf(a,s){return s=Wf({mode:s.mode,children:s.children},a.mode),s.ref=a.ref,a.child=s,s.return=a,s}function w2(a,s,u){return Zi(s,a.child,null,u),a=Yf(s,s.pendingProps),a.flags|=2,Bn(s),s.memoizedState=null,a}function x$(a,s,u){var m=s.pendingProps,g=(s.flags&128)!==0;if(s.flags&=-129,a===null){if(Ge){if(m.mode==="hidden")return a=Yf(s,m),s.lanes=536870912,ac(null,a);if(yy(s),(a=gt)?(a=kO(a,sr),a=a!==null&&a.data==="&"?a:null,a!==null&&(s.memoizedState={dehydrated:a,treeContext:Qa!==null?{id:Ir,overflow:Ur}:null,retryLane:536870912,hydrationErrors:null},u=iA(a),u.return=s,s.child=u,rn=s,gt=null)):a=null,a===null)throw ei(s);return s.lanes=536870912,null}return Yf(s,m)}var v=a.memoizedState;if(v!==null){var C=v.dehydrated;if(yy(s),g)if(s.flags&256)s.flags&=-257,s=w2(a,s,u);else if(s.memoizedState!==null)s.child=a.child,s.flags|=128,s=null;else throw Error(r(558));else if($t||Zs(a,s,u,!1),g=(u&a.childLanes)!==0,$t||g){if(m=ct,m!==null&&(C=dN(m,u),C!==0&&C!==v.retryLane))throw v.retryLane=C,Vi(a,C),Cn(m,a,C),Ly;id(),s=w2(a,s,u)}else a=v.treeContext,gt=lr(C.nextSibling),rn=s,Ge=!0,Ja=null,sr=!1,a!==null&&lA(s,a),s=Yf(s,m),s.flags|=4096;return s}return a=ca(a.child,{mode:m.mode,children:m.children}),a.ref=s.ref,s.child=a,a.return=s,a}function Xf(a,s){var u=s.ref;if(u===null)a!==null&&a.ref!==null&&(s.flags|=4194816);else{if(typeof u!="function"&&typeof u!="object")throw Error(r(284));(a===null||a.ref!==u)&&(s.flags|=4194816)}}function $y(a,s,u,m,g){return Ki(s),u=gy(a,s,u,m,void 0,g),m=vy(),a!==null&&!$t?(by(a,s,g),pa(a,s,g)):(Ge&&m&&Jp(s),s.flags|=1,sn(a,s,u,g),s.child)}function S2(a,s,u,m,g,v){return Ki(s),s.updateQueue=null,u=OA(s,m,u,g),AA(a),m=vy(),a!==null&&!$t?(by(a,s,v),pa(a,s,v)):(Ge&&m&&Jp(s),s.flags|=1,sn(a,s,u,v),s.child)}function N2(a,s,u,m,g){if(Ki(s),s.stateNode===null){var v=Ks,C=u.contextType;typeof C=="object"&&C!==null&&(v=an(C)),v=new u(m,v),s.memoizedState=v.state!==null&&v.state!==void 0?v.state:null,v.updater=Dy,s.stateNode=v,v._reactInternals=s,v=s.stateNode,v.props=m,v.state=s.memoizedState,v.refs={},uy(s),C=u.contextType,v.context=typeof C=="object"&&C!==null?an(C):Ks,v.state=s.memoizedState,C=u.getDerivedStateFromProps,typeof C=="function"&&(ky(s,u,C,m),v.state=s.memoizedState),typeof u.getDerivedStateFromProps=="function"||typeof v.getSnapshotBeforeUpdate=="function"||typeof v.UNSAFE_componentWillMount!="function"&&typeof v.componentWillMount!="function"||(C=v.state,typeof v.componentWillMount=="function"&&v.componentWillMount(),typeof v.UNSAFE_componentWillMount=="function"&&v.UNSAFE_componentWillMount(),C!==v.state&&Dy.enqueueReplaceState(v,v.state,null),Jl(s,m,v,g),Ql(),v.state=s.memoizedState),typeof v.componentDidMount=="function"&&(s.flags|=4194308),m=!0}else if(a===null){v=s.stateNode;var k=s.memoizedProps,I=Ji(u,k);v.props=I;var Z=v.context,ne=u.contextType;C=Ks,typeof ne=="object"&&ne!==null&&(C=an(ne));var oe=u.getDerivedStateFromProps;ne=typeof oe=="function"||typeof v.getSnapshotBeforeUpdate=="function",k=s.pendingProps!==k,ne||typeof v.UNSAFE_componentWillReceiveProps!="function"&&typeof v.componentWillReceiveProps!="function"||(k||Z!==C)&&u2(s,v,m,C),ni=!1;var J=s.memoizedState;v.state=J,Jl(s,m,v,g),Ql(),Z=s.memoizedState,k||J!==Z||ni?(typeof oe=="function"&&(ky(s,u,oe,m),Z=s.memoizedState),(I=ni||c2(s,u,I,m,J,Z,C))?(ne||typeof v.UNSAFE_componentWillMount!="function"&&typeof v.componentWillMount!="function"||(typeof v.componentWillMount=="function"&&v.componentWillMount(),typeof v.UNSAFE_componentWillMount=="function"&&v.UNSAFE_componentWillMount()),typeof v.componentDidMount=="function"&&(s.flags|=4194308)):(typeof v.componentDidMount=="function"&&(s.flags|=4194308),s.memoizedProps=m,s.memoizedState=Z),v.props=m,v.state=Z,v.context=C,m=I):(typeof v.componentDidMount=="function"&&(s.flags|=4194308),m=!1)}else{v=s.stateNode,fy(a,s),C=s.memoizedProps,ne=Ji(u,C),v.props=ne,oe=s.pendingProps,J=v.context,Z=u.contextType,I=Ks,typeof Z=="object"&&Z!==null&&(I=an(Z)),k=u.getDerivedStateFromProps,(Z=typeof k=="function"||typeof v.getSnapshotBeforeUpdate=="function")||typeof v.UNSAFE_componentWillReceiveProps!="function"&&typeof v.componentWillReceiveProps!="function"||(C!==oe||J!==I)&&u2(s,v,m,I),ni=!1,J=s.memoizedState,v.state=J,Jl(s,m,v,g),Ql();var te=s.memoizedState;C!==oe||J!==te||ni||a!==null&&a.dependencies!==null&&Cf(a.dependencies)?(typeof k=="function"&&(ky(s,u,k,m),te=s.memoizedState),(ne=ni||c2(s,u,ne,m,J,te,I)||a!==null&&a.dependencies!==null&&Cf(a.dependencies))?(Z||typeof v.UNSAFE_componentWillUpdate!="function"&&typeof v.componentWillUpdate!="function"||(typeof v.componentWillUpdate=="function"&&v.componentWillUpdate(m,te,I),typeof v.UNSAFE_componentWillUpdate=="function"&&v.UNSAFE_componentWillUpdate(m,te,I)),typeof v.componentDidUpdate=="function"&&(s.flags|=4),typeof v.getSnapshotBeforeUpdate=="function"&&(s.flags|=1024)):(typeof v.componentDidUpdate!="function"||C===a.memoizedProps&&J===a.memoizedState||(s.flags|=4),typeof v.getSnapshotBeforeUpdate!="function"||C===a.memoizedProps&&J===a.memoizedState||(s.flags|=1024),s.memoizedProps=m,s.memoizedState=te),v.props=m,v.state=te,v.context=I,m=ne):(typeof v.componentDidUpdate!="function"||C===a.memoizedProps&&J===a.memoizedState||(s.flags|=4),typeof v.getSnapshotBeforeUpdate!="function"||C===a.memoizedProps&&J===a.memoizedState||(s.flags|=1024),m=!1)}return v=m,Xf(a,s),m=(s.flags&128)!==0,v||m?(v=s.stateNode,u=m&&typeof u.getDerivedStateFromError!="function"?null:v.render(),s.flags|=1,a!==null&&m?(s.child=Zi(s,a.child,null,g),s.child=Zi(s,null,u,g)):sn(a,s,u,g),s.memoizedState=v.state,a=s.child):a=pa(a,s,g),a}function A2(a,s,u,m){return Fi(),s.flags|=256,sn(a,s,u,m),s.child}var By={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function qy(a){return{baseLanes:a,cachePool:mA()}}function Iy(a,s,u){return a=a!==null?a.childLanes&~u:0,s&&(a|=In),a}function O2(a,s,u){var m=s.pendingProps,g=!1,v=(s.flags&128)!==0,C;if((C=v)||(C=a!==null&&a.memoizedState===null?!1:(kt.current&2)!==0),C&&(g=!0,s.flags&=-129),C=(s.flags&32)!==0,s.flags&=-33,a===null){if(Ge){if(g?ii(s):si(),(a=gt)?(a=kO(a,sr),a=a!==null&&a.data!=="&"?a:null,a!==null&&(s.memoizedState={dehydrated:a,treeContext:Qa!==null?{id:Ir,overflow:Ur}:null,retryLane:536870912,hydrationErrors:null},u=iA(a),u.return=s,s.child=u,rn=s,gt=null)):a=null,a===null)throw ei(s);return Sx(a)?s.lanes=32:s.lanes=536870912,null}var k=m.children;return m=m.fallback,g?(si(),g=s.mode,k=Wf({mode:"hidden",children:k},g),m=Hi(m,g,u,null),k.return=s,m.return=s,k.sibling=m,s.child=k,m=s.child,m.memoizedState=qy(u),m.childLanes=Iy(a,C,u),s.memoizedState=By,ac(null,m)):(ii(s),Uy(s,k))}var I=a.memoizedState;if(I!==null&&(k=I.dehydrated,k!==null)){if(v)s.flags&256?(ii(s),s.flags&=-257,s=Vy(a,s,u)):s.memoizedState!==null?(si(),s.child=a.child,s.flags|=128,s=null):(si(),k=m.fallback,g=s.mode,m=Wf({mode:"visible",children:m.children},g),k=Hi(k,g,u,null),k.flags|=2,m.return=s,k.return=s,m.sibling=k,s.child=m,Zi(s,a.child,null,u),m=s.child,m.memoizedState=qy(u),m.childLanes=Iy(a,C,u),s.memoizedState=By,s=ac(null,m));else if(ii(s),Sx(k)){if(C=k.nextSibling&&k.nextSibling.dataset,C)var Z=C.dgst;C=Z,m=Error(r(419)),m.stack="",m.digest=C,Gl({value:m,source:null,stack:null}),s=Vy(a,s,u)}else if($t||Zs(a,s,u,!1),C=(u&a.childLanes)!==0,$t||C){if(C=ct,C!==null&&(m=dN(C,u),m!==0&&m!==I.retryLane))throw I.retryLane=m,Vi(a,m),Cn(C,a,m),Ly;wx(k)||id(),s=Vy(a,s,u)}else wx(k)?(s.flags|=192,s.child=a.child,s=null):(a=I.treeContext,gt=lr(k.nextSibling),rn=s,Ge=!0,Ja=null,sr=!1,a!==null&&lA(s,a),s=Uy(s,m.children),s.flags|=4096);return s}return g?(si(),k=m.fallback,g=s.mode,I=a.child,Z=I.sibling,m=ca(I,{mode:"hidden",children:m.children}),m.subtreeFlags=I.subtreeFlags&65011712,Z!==null?k=ca(Z,k):(k=Hi(k,g,u,null),k.flags|=2),k.return=s,m.return=s,m.sibling=k,s.child=m,ac(null,m),m=s.child,k=a.child.memoizedState,k===null?k=qy(u):(g=k.cachePool,g!==null?(I=zt._currentValue,g=g.parent!==I?{parent:I,pool:I}:g):g=mA(),k={baseLanes:k.baseLanes|u,cachePool:g}),m.memoizedState=k,m.childLanes=Iy(a,C,u),s.memoizedState=By,ac(a.child,m)):(ii(s),u=a.child,a=u.sibling,u=ca(u,{mode:"visible",children:m.children}),u.return=s,u.sibling=null,a!==null&&(C=s.deletions,C===null?(s.deletions=[a],s.flags|=16):C.push(a)),s.child=u,s.memoizedState=null,u)}function Uy(a,s){return s=Wf({mode:"visible",children:s},a.mode),s.return=a,a.child=s}function Wf(a,s){return a=Ln(22,a,null,s),a.lanes=0,a}function Vy(a,s,u){return Zi(s,a.child,null,u),a=Uy(s,s.pendingProps.children),a.flags|=2,s.memoizedState=null,a}function _2(a,s,u){a.lanes|=s;var m=a.alternate;m!==null&&(m.lanes|=s),ay(a.return,s,u)}function Hy(a,s,u,m,g,v){var C=a.memoizedState;C===null?a.memoizedState={isBackwards:s,rendering:null,renderingStartTime:0,last:m,tail:u,tailMode:g,treeForkCount:v}:(C.isBackwards=s,C.rendering=null,C.renderingStartTime=0,C.last=m,C.tail=u,C.tailMode=g,C.treeForkCount=v)}function T2(a,s,u){var m=s.pendingProps,g=m.revealOrder,v=m.tail;m=m.children;var C=kt.current,k=(C&2)!==0;if(k?(C=C&1|2,s.flags|=128):C&=1,ae(kt,C),sn(a,s,m,u),m=Ge?Fl:0,!k&&a!==null&&(a.flags&128)!==0)e:for(a=s.child;a!==null;){if(a.tag===13)a.memoizedState!==null&&_2(a,u,s);else if(a.tag===19)_2(a,u,s);else if(a.child!==null){a.child.return=a,a=a.child;continue}if(a===s)break e;for(;a.sibling===null;){if(a.return===null||a.return===s)break e;a=a.return}a.sibling.return=a.return,a=a.sibling}switch(g){case"forwards":for(u=s.child,g=null;u!==null;)a=u.alternate,a!==null&&$f(a)===null&&(g=u),u=u.sibling;u=g,u===null?(g=s.child,s.child=null):(g=u.sibling,u.sibling=null),Hy(s,!1,g,u,v,m);break;case"backwards":case"unstable_legacy-backwards":for(u=null,g=s.child,s.child=null;g!==null;){if(a=g.alternate,a!==null&&$f(a)===null){s.child=g;break}a=g.sibling,g.sibling=u,u=g,g=a}Hy(s,!0,u,null,v,m);break;case"together":Hy(s,!1,null,null,void 0,m);break;default:s.memoizedState=null}return s.child}function pa(a,s,u){if(a!==null&&(s.dependencies=a.dependencies),ci|=s.lanes,(u&s.childLanes)===0)if(a!==null){if(Zs(a,s,u,!1),(u&s.childLanes)===0)return null}else return null;if(a!==null&&s.child!==a.child)throw Error(r(153));if(s.child!==null){for(a=s.child,u=ca(a,a.pendingProps),s.child=u,u.return=s;a.sibling!==null;)a=a.sibling,u=u.sibling=ca(a,a.pendingProps),u.return=s;u.sibling=null}return s.child}function Fy(a,s){return(a.lanes&s)!==0?!0:(a=a.dependencies,!!(a!==null&&Cf(a)))}function g$(a,s,u){switch(s.tag){case 3:Qe(s,s.stateNode.containerInfo),ti(s,zt,a.memoizedState.cache),Fi();break;case 27:case 5:Ee(s);break;case 4:Qe(s,s.stateNode.containerInfo);break;case 10:ti(s,s.type,s.memoizedProps.value);break;case 31:if(s.memoizedState!==null)return s.flags|=128,yy(s),null;break;case 13:var m=s.memoizedState;if(m!==null)return m.dehydrated!==null?(ii(s),s.flags|=128,null):(u&s.child.childLanes)!==0?O2(a,s,u):(ii(s),a=pa(a,s,u),a!==null?a.sibling:null);ii(s);break;case 19:var g=(a.flags&128)!==0;if(m=(u&s.childLanes)!==0,m||(Zs(a,s,u,!1),m=(u&s.childLanes)!==0),g){if(m)return T2(a,s,u);s.flags|=128}if(g=s.memoizedState,g!==null&&(g.rendering=null,g.tail=null,g.lastEffect=null),ae(kt,kt.current),m)break;return null;case 22:return s.lanes=0,b2(a,s,u,s.pendingProps);case 24:ti(s,zt,a.memoizedState.cache)}return pa(a,s,u)}function E2(a,s,u){if(a!==null)if(a.memoizedProps!==s.pendingProps)$t=!0;else{if(!Fy(a,u)&&(s.flags&128)===0)return $t=!1,g$(a,s,u);$t=(a.flags&131072)!==0}else $t=!1,Ge&&(s.flags&1048576)!==0&&oA(s,Fl,s.index);switch(s.lanes=0,s.tag){case 16:e:{var m=s.pendingProps;if(a=Xi(s.elementType),s.type=a,typeof a=="function")Wp(a)?(m=Ji(a,m),s.tag=1,s=N2(null,s,a,m,u)):(s.tag=0,s=$y(null,s,a,m,u));else{if(a!=null){var g=a.$$typeof;if(g===T){s.tag=11,s=x2(null,s,a,m,u);break e}else if(g===M){s.tag=14,s=g2(null,s,a,m,u);break e}}throw s=X(a)||a,Error(r(306,s,""))}}return s;case 0:return $y(a,s,s.type,s.pendingProps,u);case 1:return m=s.type,g=Ji(m,s.pendingProps),N2(a,s,m,g,u);case 3:e:{if(Qe(s,s.stateNode.containerInfo),a===null)throw Error(r(387));m=s.pendingProps;var v=s.memoizedState;g=v.element,fy(a,s),Jl(s,m,null,u);var C=s.memoizedState;if(m=C.cache,ti(s,zt,m),m!==v.cache&&iy(s,[zt],u,!0),Ql(),m=C.element,v.isDehydrated)if(v={element:m,isDehydrated:!1,cache:C.cache},s.updateQueue.baseState=v,s.memoizedState=v,s.flags&256){s=A2(a,s,m,u);break e}else if(m!==g){g=rr(Error(r(424)),s),Gl(g),s=A2(a,s,m,u);break e}else{switch(a=s.stateNode.containerInfo,a.nodeType){case 9:a=a.body;break;default:a=a.nodeName==="HTML"?a.ownerDocument.body:a}for(gt=lr(a.firstChild),rn=s,Ge=!0,Ja=null,sr=!0,u=bA(s,null,m,u),s.child=u;u;)u.flags=u.flags&-3|4096,u=u.sibling}else{if(Fi(),m===g){s=pa(a,s,u);break e}sn(a,s,m,u)}s=s.child}return s;case 26:return Xf(a,s),a===null?(u=qO(s.type,null,s.pendingProps,null))?s.memoizedState=u:Ge||(u=s.type,a=s.pendingProps,m=dd(Ae.current).createElement(u),m[nn]=s,m[Nn]=a,on(m,u,a),Zt(m),s.stateNode=m):s.memoizedState=qO(s.type,a.memoizedProps,s.pendingProps,a.memoizedState),null;case 27:return Ee(s),a===null&&Ge&&(m=s.stateNode=LO(s.type,s.pendingProps,Ae.current),rn=s,sr=!0,g=gt,mi(s.type)?(Nx=g,gt=lr(m.firstChild)):gt=g),sn(a,s,s.pendingProps.children,u),Xf(a,s),a===null&&(s.flags|=4194304),s.child;case 5:return a===null&&Ge&&((g=m=gt)&&(m=Y$(m,s.type,s.pendingProps,sr),m!==null?(s.stateNode=m,rn=s,gt=lr(m.firstChild),sr=!1,g=!0):g=!1),g||ei(s)),Ee(s),g=s.type,v=s.pendingProps,C=a!==null?a.memoizedProps:null,m=v.children,vx(g,v)?m=null:C!==null&&vx(g,C)&&(s.flags|=32),s.memoizedState!==null&&(g=gy(a,s,c$,null,null,u),vc._currentValue=g),Xf(a,s),sn(a,s,m,u),s.child;case 6:return a===null&&Ge&&((a=u=gt)&&(u=X$(u,s.pendingProps,sr),u!==null?(s.stateNode=u,rn=s,gt=null,a=!0):a=!1),a||ei(s)),null;case 13:return O2(a,s,u);case 4:return Qe(s,s.stateNode.containerInfo),m=s.pendingProps,a===null?s.child=Zi(s,null,m,u):sn(a,s,m,u),s.child;case 11:return x2(a,s,s.type,s.pendingProps,u);case 7:return sn(a,s,s.pendingProps,u),s.child;case 8:return sn(a,s,s.pendingProps.children,u),s.child;case 12:return sn(a,s,s.pendingProps.children,u),s.child;case 10:return m=s.pendingProps,ti(s,s.type,m.value),sn(a,s,m.children,u),s.child;case 9:return g=s.type._context,m=s.pendingProps.children,Ki(s),g=an(g),m=m(g),s.flags|=1,sn(a,s,m,u),s.child;case 14:return g2(a,s,s.type,s.pendingProps,u);case 15:return v2(a,s,s.type,s.pendingProps,u);case 19:return T2(a,s,u);case 31:return x$(a,s,u);case 22:return b2(a,s,u,s.pendingProps);case 24:return Ki(s),m=an(zt),a===null?(g=ly(),g===null&&(g=ct,v=sy(),g.pooledCache=v,v.refCount++,v!==null&&(g.pooledCacheLanes|=u),g=v),s.memoizedState={parent:m,cache:g},uy(s),ti(s,zt,g)):((a.lanes&u)!==0&&(fy(a,s),Jl(s,null,null,u),Ql()),g=a.memoizedState,v=s.memoizedState,g.parent!==m?(g={parent:m,cache:m},s.memoizedState=g,s.lanes===0&&(s.memoizedState=s.updateQueue.baseState=g),ti(s,zt,m)):(m=v.cache,ti(s,zt,m),m!==g.cache&&iy(s,[zt],u,!0))),sn(a,s,s.pendingProps.children,u),s.child;case 29:throw s.pendingProps}throw Error(r(156,s.tag))}function ya(a){a.flags|=4}function Gy(a,s,u,m,g){if((s=(a.mode&32)!==0)&&(s=!1),s){if(a.flags|=16777216,(g&335544128)===g)if(a.stateNode.complete)a.flags|=8192;else if(nO())a.flags|=8192;else throw Wi=kf,cy}else a.flags&=-16777217}function C2(a,s){if(s.type!=="stylesheet"||(s.state.loading&4)!==0)a.flags&=-16777217;else if(a.flags|=16777216,!FO(s))if(nO())a.flags|=8192;else throw Wi=kf,cy}function Zf(a,s){s!==null&&(a.flags|=4),a.flags&16384&&(s=a.tag!==22?cN():536870912,a.lanes|=s,co|=s)}function ic(a,s){if(!Ge)switch(a.tailMode){case"hidden":s=a.tail;for(var u=null;s!==null;)s.alternate!==null&&(u=s),s=s.sibling;u===null?a.tail=null:u.sibling=null;break;case"collapsed":u=a.tail;for(var m=null;u!==null;)u.alternate!==null&&(m=u),u=u.sibling;m===null?s||a.tail===null?a.tail=null:a.tail.sibling=null:m.sibling=null}}function vt(a){var s=a.alternate!==null&&a.alternate.child===a.child,u=0,m=0;if(s)for(var g=a.child;g!==null;)u|=g.lanes|g.childLanes,m|=g.subtreeFlags&65011712,m|=g.flags&65011712,g.return=a,g=g.sibling;else for(g=a.child;g!==null;)u|=g.lanes|g.childLanes,m|=g.subtreeFlags,m|=g.flags,g.return=a,g=g.sibling;return a.subtreeFlags|=m,a.childLanes=u,s}function v$(a,s,u){var m=s.pendingProps;switch(ey(s),s.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return vt(s),null;case 1:return vt(s),null;case 3:return u=s.stateNode,m=null,a!==null&&(m=a.memoizedState.cache),s.memoizedState.cache!==m&&(s.flags|=2048),da(zt),ue(),u.pendingContext&&(u.context=u.pendingContext,u.pendingContext=null),(a===null||a.child===null)&&(Ws(s)?ya(s):a===null||a.memoizedState.isDehydrated&&(s.flags&256)===0||(s.flags|=1024,ny())),vt(s),null;case 26:var g=s.type,v=s.memoizedState;return a===null?(ya(s),v!==null?(vt(s),C2(s,v)):(vt(s),Gy(s,g,null,m,u))):v?v!==a.memoizedState?(ya(s),vt(s),C2(s,v)):(vt(s),s.flags&=-16777217):(a=a.memoizedProps,a!==m&&ya(s),vt(s),Gy(s,g,a,m,u)),null;case 27:if(Me(s),u=Ae.current,g=s.type,a!==null&&s.stateNode!=null)a.memoizedProps!==m&&ya(s);else{if(!m){if(s.stateNode===null)throw Error(r(166));return vt(s),null}a=fe.current,Ws(s)?cA(s):(a=LO(g,m,u),s.stateNode=a,ya(s))}return vt(s),null;case 5:if(Me(s),g=s.type,a!==null&&s.stateNode!=null)a.memoizedProps!==m&&ya(s);else{if(!m){if(s.stateNode===null)throw Error(r(166));return vt(s),null}if(v=fe.current,Ws(s))cA(s);else{var C=dd(Ae.current);switch(v){case 1:v=C.createElementNS("http://www.w3.org/2000/svg",g);break;case 2:v=C.createElementNS("http://www.w3.org/1998/Math/MathML",g);break;default:switch(g){case"svg":v=C.createElementNS("http://www.w3.org/2000/svg",g);break;case"math":v=C.createElementNS("http://www.w3.org/1998/Math/MathML",g);break;case"script":v=C.createElement("div"),v.innerHTML="<script><\/script>",v=v.removeChild(v.firstChild);break;case"select":v=typeof m.is=="string"?C.createElement("select",{is:m.is}):C.createElement("select"),m.multiple?v.multiple=!0:m.size&&(v.size=m.size);break;default:v=typeof m.is=="string"?C.createElement(g,{is:m.is}):C.createElement(g)}}v[nn]=s,v[Nn]=m;e:for(C=s.child;C!==null;){if(C.tag===5||C.tag===6)v.appendChild(C.stateNode);else if(C.tag!==4&&C.tag!==27&&C.child!==null){C.child.return=C,C=C.child;continue}if(C===s)break e;for(;C.sibling===null;){if(C.return===null||C.return===s)break e;C=C.return}C.sibling.return=C.return,C=C.sibling}s.stateNode=v;e:switch(on(v,g,m),g){case"button":case"input":case"select":case"textarea":m=!!m.autoFocus;break e;case"img":m=!0;break e;default:m=!1}m&&ya(s)}}return vt(s),Gy(s,s.type,a===null?null:a.memoizedProps,s.pendingProps,u),null;case 6:if(a&&s.stateNode!=null)a.memoizedProps!==m&&ya(s);else{if(typeof m!="string"&&s.stateNode===null)throw Error(r(166));if(a=Ae.current,Ws(s)){if(a=s.stateNode,u=s.memoizedProps,m=null,g=rn,g!==null)switch(g.tag){case 27:case 5:m=g.memoizedProps}a[nn]=s,a=!!(a.nodeValue===u||m!==null&&m.suppressHydrationWarning===!0||OO(a.nodeValue,u)),a||ei(s,!0)}else a=dd(a).createTextNode(m),a[nn]=s,s.stateNode=a}return vt(s),null;case 31:if(u=s.memoizedState,a===null||a.memoizedState!==null){if(m=Ws(s),u!==null){if(a===null){if(!m)throw Error(r(318));if(a=s.memoizedState,a=a!==null?a.dehydrated:null,!a)throw Error(r(557));a[nn]=s}else Fi(),(s.flags&128)===0&&(s.memoizedState=null),s.flags|=4;vt(s),a=!1}else u=ny(),a!==null&&a.memoizedState!==null&&(a.memoizedState.hydrationErrors=u),a=!0;if(!a)return s.flags&256?(Bn(s),s):(Bn(s),null);if((s.flags&128)!==0)throw Error(r(558))}return vt(s),null;case 13:if(m=s.memoizedState,a===null||a.memoizedState!==null&&a.memoizedState.dehydrated!==null){if(g=Ws(s),m!==null&&m.dehydrated!==null){if(a===null){if(!g)throw Error(r(318));if(g=s.memoizedState,g=g!==null?g.dehydrated:null,!g)throw Error(r(317));g[nn]=s}else Fi(),(s.flags&128)===0&&(s.memoizedState=null),s.flags|=4;vt(s),g=!1}else g=ny(),a!==null&&a.memoizedState!==null&&(a.memoizedState.hydrationErrors=g),g=!0;if(!g)return s.flags&256?(Bn(s),s):(Bn(s),null)}return Bn(s),(s.flags&128)!==0?(s.lanes=u,s):(u=m!==null,a=a!==null&&a.memoizedState!==null,u&&(m=s.child,g=null,m.alternate!==null&&m.alternate.memoizedState!==null&&m.alternate.memoizedState.cachePool!==null&&(g=m.alternate.memoizedState.cachePool.pool),v=null,m.memoizedState!==null&&m.memoizedState.cachePool!==null&&(v=m.memoizedState.cachePool.pool),v!==g&&(m.flags|=2048)),u!==a&&u&&(s.child.flags|=8192),Zf(s,s.updateQueue),vt(s),null);case 4:return ue(),a===null&&mx(s.stateNode.containerInfo),vt(s),null;case 10:return da(s.type),vt(s),null;case 19:if(F(kt),m=s.memoizedState,m===null)return vt(s),null;if(g=(s.flags&128)!==0,v=m.rendering,v===null)if(g)ic(m,!1);else{if(Ct!==0||a!==null&&(a.flags&128)!==0)for(a=s.child;a!==null;){if(v=$f(a),v!==null){for(s.flags|=128,ic(m,!1),a=v.updateQueue,s.updateQueue=a,Zf(s,a),s.subtreeFlags=0,a=u,u=s.child;u!==null;)aA(u,a),u=u.sibling;return ae(kt,kt.current&1|2),Ge&&ua(s,m.treeForkCount),s.child}a=a.sibling}m.tail!==null&&dn()>nd&&(s.flags|=128,g=!0,ic(m,!1),s.lanes=4194304)}else{if(!g)if(a=$f(v),a!==null){if(s.flags|=128,g=!0,a=a.updateQueue,s.updateQueue=a,Zf(s,a),ic(m,!0),m.tail===null&&m.tailMode==="hidden"&&!v.alternate&&!Ge)return vt(s),null}else 2*dn()-m.renderingStartTime>nd&&u!==536870912&&(s.flags|=128,g=!0,ic(m,!1),s.lanes=4194304);m.isBackwards?(v.sibling=s.child,s.child=v):(a=m.last,a!==null?a.sibling=v:s.child=v,m.last=v)}return m.tail!==null?(a=m.tail,m.rendering=a,m.tail=a.sibling,m.renderingStartTime=dn(),a.sibling=null,u=kt.current,ae(kt,g?u&1|2:u&1),Ge&&ua(s,m.treeForkCount),a):(vt(s),null);case 22:case 23:return Bn(s),py(),m=s.memoizedState!==null,a!==null?a.memoizedState!==null!==m&&(s.flags|=8192):m&&(s.flags|=8192),m?(u&536870912)!==0&&(s.flags&128)===0&&(vt(s),s.subtreeFlags&6&&(s.flags|=8192)):vt(s),u=s.updateQueue,u!==null&&Zf(s,u.retryQueue),u=null,a!==null&&a.memoizedState!==null&&a.memoizedState.cachePool!==null&&(u=a.memoizedState.cachePool.pool),m=null,s.memoizedState!==null&&s.memoizedState.cachePool!==null&&(m=s.memoizedState.cachePool.pool),m!==u&&(s.flags|=2048),a!==null&&F(Yi),null;case 24:return u=null,a!==null&&(u=a.memoizedState.cache),s.memoizedState.cache!==u&&(s.flags|=2048),da(zt),vt(s),null;case 25:return null;case 30:return null}throw Error(r(156,s.tag))}function b$(a,s){switch(ey(s),s.tag){case 1:return a=s.flags,a&65536?(s.flags=a&-65537|128,s):null;case 3:return da(zt),ue(),a=s.flags,(a&65536)!==0&&(a&128)===0?(s.flags=a&-65537|128,s):null;case 26:case 27:case 5:return Me(s),null;case 31:if(s.memoizedState!==null){if(Bn(s),s.alternate===null)throw Error(r(340));Fi()}return a=s.flags,a&65536?(s.flags=a&-65537|128,s):null;case 13:if(Bn(s),a=s.memoizedState,a!==null&&a.dehydrated!==null){if(s.alternate===null)throw Error(r(340));Fi()}return a=s.flags,a&65536?(s.flags=a&-65537|128,s):null;case 19:return F(kt),null;case 4:return ue(),null;case 10:return da(s.type),null;case 22:case 23:return Bn(s),py(),a!==null&&F(Yi),a=s.flags,a&65536?(s.flags=a&-65537|128,s):null;case 24:return da(zt),null;case 25:return null;default:return null}}function M2(a,s){switch(ey(s),s.tag){case 3:da(zt),ue();break;case 26:case 27:case 5:Me(s);break;case 4:ue();break;case 31:s.memoizedState!==null&&Bn(s);break;case 13:Bn(s);break;case 19:F(kt);break;case 10:da(s.type);break;case 22:case 23:Bn(s),py(),a!==null&&F(Yi);break;case 24:da(zt)}}function sc(a,s){try{var u=s.updateQueue,m=u!==null?u.lastEffect:null;if(m!==null){var g=m.next;u=g;do{if((u.tag&a)===a){m=void 0;var v=u.create,C=u.inst;m=v(),C.destroy=m}u=u.next}while(u!==g)}}catch(k){rt(s,s.return,k)}}function oi(a,s,u){try{var m=s.updateQueue,g=m!==null?m.lastEffect:null;if(g!==null){var v=g.next;m=v;do{if((m.tag&a)===a){var C=m.inst,k=C.destroy;if(k!==void 0){C.destroy=void 0,g=s;var I=u,Z=k;try{Z()}catch(ne){rt(g,I,ne)}}}m=m.next}while(m!==v)}}catch(ne){rt(s,s.return,ne)}}function P2(a){var s=a.updateQueue;if(s!==null){var u=a.stateNode;try{wA(s,u)}catch(m){rt(a,a.return,m)}}}function R2(a,s,u){u.props=Ji(a.type,a.memoizedProps),u.state=a.memoizedState;try{u.componentWillUnmount()}catch(m){rt(a,s,m)}}function oc(a,s){try{var u=a.ref;if(u!==null){switch(a.tag){case 26:case 27:case 5:var m=a.stateNode;break;case 30:m=a.stateNode;break;default:m=a.stateNode}typeof u=="function"?a.refCleanup=u(m):u.current=m}}catch(g){rt(a,s,g)}}function Vr(a,s){var u=a.ref,m=a.refCleanup;if(u!==null)if(typeof m=="function")try{m()}catch(g){rt(a,s,g)}finally{a.refCleanup=null,a=a.alternate,a!=null&&(a.refCleanup=null)}else if(typeof u=="function")try{u(null)}catch(g){rt(a,s,g)}else u.current=null}function k2(a){var s=a.type,u=a.memoizedProps,m=a.stateNode;try{e:switch(s){case"button":case"input":case"select":case"textarea":u.autoFocus&&m.focus();break e;case"img":u.src?m.src=u.src:u.srcSet&&(m.srcset=u.srcSet)}}catch(g){rt(a,a.return,g)}}function Ky(a,s,u){try{var m=a.stateNode;U$(m,a.type,u,s),m[Nn]=s}catch(g){rt(a,a.return,g)}}function D2(a){return a.tag===5||a.tag===3||a.tag===26||a.tag===27&&mi(a.type)||a.tag===4}function Yy(a){e:for(;;){for(;a.sibling===null;){if(a.return===null||D2(a.return))return null;a=a.return}for(a.sibling.return=a.return,a=a.sibling;a.tag!==5&&a.tag!==6&&a.tag!==18;){if(a.tag===27&&mi(a.type)||a.flags&2||a.child===null||a.tag===4)continue e;a.child.return=a,a=a.child}if(!(a.flags&2))return a.stateNode}}function Xy(a,s,u){var m=a.tag;if(m===5||m===6)a=a.stateNode,s?(u.nodeType===9?u.body:u.nodeName==="HTML"?u.ownerDocument.body:u).insertBefore(a,s):(s=u.nodeType===9?u.body:u.nodeName==="HTML"?u.ownerDocument.body:u,s.appendChild(a),u=u._reactRootContainer,u!=null||s.onclick!==null||(s.onclick=oa));else if(m!==4&&(m===27&&mi(a.type)&&(u=a.stateNode,s=null),a=a.child,a!==null))for(Xy(a,s,u),a=a.sibling;a!==null;)Xy(a,s,u),a=a.sibling}function Qf(a,s,u){var m=a.tag;if(m===5||m===6)a=a.stateNode,s?u.insertBefore(a,s):u.appendChild(a);else if(m!==4&&(m===27&&mi(a.type)&&(u=a.stateNode),a=a.child,a!==null))for(Qf(a,s,u),a=a.sibling;a!==null;)Qf(a,s,u),a=a.sibling}function z2(a){var s=a.stateNode,u=a.memoizedProps;try{for(var m=a.type,g=s.attributes;g.length;)s.removeAttributeNode(g[0]);on(s,m,u),s[nn]=a,s[Nn]=u}catch(v){rt(a,a.return,v)}}var xa=!1,Bt=!1,Wy=!1,L2=typeof WeakSet=="function"?WeakSet:Set,Qt=null;function j$(a,s){if(a=a.containerInfo,xx=vd,a=XN(a),Vp(a)){if("selectionStart"in a)var u={start:a.selectionStart,end:a.selectionEnd};else e:{u=(u=a.ownerDocument)&&u.defaultView||window;var m=u.getSelection&&u.getSelection();if(m&&m.rangeCount!==0){u=m.anchorNode;var g=m.anchorOffset,v=m.focusNode;m=m.focusOffset;try{u.nodeType,v.nodeType}catch{u=null;break e}var C=0,k=-1,I=-1,Z=0,ne=0,oe=a,J=null;t:for(;;){for(var te;oe!==u||g!==0&&oe.nodeType!==3||(k=C+g),oe!==v||m!==0&&oe.nodeType!==3||(I=C+m),oe.nodeType===3&&(C+=oe.nodeValue.length),(te=oe.firstChild)!==null;)J=oe,oe=te;for(;;){if(oe===a)break t;if(J===u&&++Z===g&&(k=C),J===v&&++ne===m&&(I=C),(te=oe.nextSibling)!==null)break;oe=J,J=oe.parentNode}oe=te}u=k===-1||I===-1?null:{start:k,end:I}}else u=null}u=u||{start:0,end:0}}else u=null;for(gx={focusedElem:a,selectionRange:u},vd=!1,Qt=s;Qt!==null;)if(s=Qt,a=s.child,(s.subtreeFlags&1028)!==0&&a!==null)a.return=s,Qt=a;else for(;Qt!==null;){switch(s=Qt,v=s.alternate,a=s.flags,s.tag){case 0:if((a&4)!==0&&(a=s.updateQueue,a=a!==null?a.events:null,a!==null))for(u=0;u<a.length;u++)g=a[u],g.ref.impl=g.nextImpl;break;case 11:case 15:break;case 1:if((a&1024)!==0&&v!==null){a=void 0,u=s,g=v.memoizedProps,v=v.memoizedState,m=u.stateNode;try{var pe=Ji(u.type,g);a=m.getSnapshotBeforeUpdate(pe,v),m.__reactInternalSnapshotBeforeUpdate=a}catch(Oe){rt(u,u.return,Oe)}}break;case 3:if((a&1024)!==0){if(a=s.stateNode.containerInfo,u=a.nodeType,u===9)jx(a);else if(u===1)switch(a.nodeName){case"HEAD":case"HTML":case"BODY":jx(a);break;default:a.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((a&1024)!==0)throw Error(r(163))}if(a=s.sibling,a!==null){a.return=s.return,Qt=a;break}Qt=s.return}}function $2(a,s,u){var m=u.flags;switch(u.tag){case 0:case 11:case 15:va(a,u),m&4&&sc(5,u);break;case 1:if(va(a,u),m&4)if(a=u.stateNode,s===null)try{a.componentDidMount()}catch(C){rt(u,u.return,C)}else{var g=Ji(u.type,s.memoizedProps);s=s.memoizedState;try{a.componentDidUpdate(g,s,a.__reactInternalSnapshotBeforeUpdate)}catch(C){rt(u,u.return,C)}}m&64&&P2(u),m&512&&oc(u,u.return);break;case 3:if(va(a,u),m&64&&(a=u.updateQueue,a!==null)){if(s=null,u.child!==null)switch(u.child.tag){case 27:case 5:s=u.child.stateNode;break;case 1:s=u.child.stateNode}try{wA(a,s)}catch(C){rt(u,u.return,C)}}break;case 27:s===null&&m&4&&z2(u);case 26:case 5:va(a,u),s===null&&m&4&&k2(u),m&512&&oc(u,u.return);break;case 12:va(a,u);break;case 31:va(a,u),m&4&&I2(a,u);break;case 13:va(a,u),m&4&&U2(a,u),m&64&&(a=u.memoizedState,a!==null&&(a=a.dehydrated,a!==null&&(u=C$.bind(null,u),W$(a,u))));break;case 22:if(m=u.memoizedState!==null||xa,!m){s=s!==null&&s.memoizedState!==null||Bt,g=xa;var v=Bt;xa=m,(Bt=s)&&!v?ba(a,u,(u.subtreeFlags&8772)!==0):va(a,u),xa=g,Bt=v}break;case 30:break;default:va(a,u)}}function B2(a){var s=a.alternate;s!==null&&(a.alternate=null,B2(s)),a.child=null,a.deletions=null,a.sibling=null,a.tag===5&&(s=a.stateNode,s!==null&&Op(s)),a.stateNode=null,a.return=null,a.dependencies=null,a.memoizedProps=null,a.memoizedState=null,a.pendingProps=null,a.stateNode=null,a.updateQueue=null}var wt=null,On=!1;function ga(a,s,u){for(u=u.child;u!==null;)q2(a,s,u),u=u.sibling}function q2(a,s,u){if(kn&&typeof kn.onCommitFiberUnmount=="function")try{kn.onCommitFiberUnmount(Ml,u)}catch{}switch(u.tag){case 26:Bt||Vr(u,s),ga(a,s,u),u.memoizedState?u.memoizedState.count--:u.stateNode&&(u=u.stateNode,u.parentNode.removeChild(u));break;case 27:Bt||Vr(u,s);var m=wt,g=On;mi(u.type)&&(wt=u.stateNode,On=!1),ga(a,s,u),yc(u.stateNode),wt=m,On=g;break;case 5:Bt||Vr(u,s);case 6:if(m=wt,g=On,wt=null,ga(a,s,u),wt=m,On=g,wt!==null)if(On)try{(wt.nodeType===9?wt.body:wt.nodeName==="HTML"?wt.ownerDocument.body:wt).removeChild(u.stateNode)}catch(v){rt(u,s,v)}else try{wt.removeChild(u.stateNode)}catch(v){rt(u,s,v)}break;case 18:wt!==null&&(On?(a=wt,PO(a.nodeType===9?a.body:a.nodeName==="HTML"?a.ownerDocument.body:a,u.stateNode),go(a)):PO(wt,u.stateNode));break;case 4:m=wt,g=On,wt=u.stateNode.containerInfo,On=!0,ga(a,s,u),wt=m,On=g;break;case 0:case 11:case 14:case 15:oi(2,u,s),Bt||oi(4,u,s),ga(a,s,u);break;case 1:Bt||(Vr(u,s),m=u.stateNode,typeof m.componentWillUnmount=="function"&&R2(u,s,m)),ga(a,s,u);break;case 21:ga(a,s,u);break;case 22:Bt=(m=Bt)||u.memoizedState!==null,ga(a,s,u),Bt=m;break;default:ga(a,s,u)}}function I2(a,s){if(s.memoizedState===null&&(a=s.alternate,a!==null&&(a=a.memoizedState,a!==null))){a=a.dehydrated;try{go(a)}catch(u){rt(s,s.return,u)}}}function U2(a,s){if(s.memoizedState===null&&(a=s.alternate,a!==null&&(a=a.memoizedState,a!==null&&(a=a.dehydrated,a!==null))))try{go(a)}catch(u){rt(s,s.return,u)}}function w$(a){switch(a.tag){case 31:case 13:case 19:var s=a.stateNode;return s===null&&(s=a.stateNode=new L2),s;case 22:return a=a.stateNode,s=a._retryCache,s===null&&(s=a._retryCache=new L2),s;default:throw Error(r(435,a.tag))}}function Jf(a,s){var u=w$(a);s.forEach(function(m){if(!u.has(m)){u.add(m);var g=M$.bind(null,a,m);m.then(g,g)}})}function _n(a,s){var u=s.deletions;if(u!==null)for(var m=0;m<u.length;m++){var g=u[m],v=a,C=s,k=C;e:for(;k!==null;){switch(k.tag){case 27:if(mi(k.type)){wt=k.stateNode,On=!1;break e}break;case 5:wt=k.stateNode,On=!1;break e;case 3:case 4:wt=k.stateNode.containerInfo,On=!0;break e}k=k.return}if(wt===null)throw Error(r(160));q2(v,C,g),wt=null,On=!1,v=g.alternate,v!==null&&(v.return=null),g.return=null}if(s.subtreeFlags&13886)for(s=s.child;s!==null;)V2(s,a),s=s.sibling}var Ar=null;function V2(a,s){var u=a.alternate,m=a.flags;switch(a.tag){case 0:case 11:case 14:case 15:_n(s,a),Tn(a),m&4&&(oi(3,a,a.return),sc(3,a),oi(5,a,a.return));break;case 1:_n(s,a),Tn(a),m&512&&(Bt||u===null||Vr(u,u.return)),m&64&&xa&&(a=a.updateQueue,a!==null&&(m=a.callbacks,m!==null&&(u=a.shared.hiddenCallbacks,a.shared.hiddenCallbacks=u===null?m:u.concat(m))));break;case 26:var g=Ar;if(_n(s,a),Tn(a),m&512&&(Bt||u===null||Vr(u,u.return)),m&4){var v=u!==null?u.memoizedState:null;if(m=a.memoizedState,u===null)if(m===null)if(a.stateNode===null){e:{m=a.type,u=a.memoizedProps,g=g.ownerDocument||g;t:switch(m){case"title":v=g.getElementsByTagName("title")[0],(!v||v[kl]||v[nn]||v.namespaceURI==="http://www.w3.org/2000/svg"||v.hasAttribute("itemprop"))&&(v=g.createElement(m),g.head.insertBefore(v,g.querySelector("head > title"))),on(v,m,u),v[nn]=a,Zt(v),m=v;break e;case"link":var C=VO("link","href",g).get(m+(u.href||""));if(C){for(var k=0;k<C.length;k++)if(v=C[k],v.getAttribute("href")===(u.href==null||u.href===""?null:u.href)&&v.getAttribute("rel")===(u.rel==null?null:u.rel)&&v.getAttribute("title")===(u.title==null?null:u.title)&&v.getAttribute("crossorigin")===(u.crossOrigin==null?null:u.crossOrigin)){C.splice(k,1);break t}}v=g.createElement(m),on(v,m,u),g.head.appendChild(v);break;case"meta":if(C=VO("meta","content",g).get(m+(u.content||""))){for(k=0;k<C.length;k++)if(v=C[k],v.getAttribute("content")===(u.content==null?null:""+u.content)&&v.getAttribute("name")===(u.name==null?null:u.name)&&v.getAttribute("property")===(u.property==null?null:u.property)&&v.getAttribute("http-equiv")===(u.httpEquiv==null?null:u.httpEquiv)&&v.getAttribute("charset")===(u.charSet==null?null:u.charSet)){C.splice(k,1);break t}}v=g.createElement(m),on(v,m,u),g.head.appendChild(v);break;default:throw Error(r(468,m))}v[nn]=a,Zt(v),m=v}a.stateNode=m}else HO(g,a.type,a.stateNode);else a.stateNode=UO(g,m,a.memoizedProps);else v!==m?(v===null?u.stateNode!==null&&(u=u.stateNode,u.parentNode.removeChild(u)):v.count--,m===null?HO(g,a.type,a.stateNode):UO(g,m,a.memoizedProps)):m===null&&a.stateNode!==null&&Ky(a,a.memoizedProps,u.memoizedProps)}break;case 27:_n(s,a),Tn(a),m&512&&(Bt||u===null||Vr(u,u.return)),u!==null&&m&4&&Ky(a,a.memoizedProps,u.memoizedProps);break;case 5:if(_n(s,a),Tn(a),m&512&&(Bt||u===null||Vr(u,u.return)),a.flags&32){g=a.stateNode;try{qs(g,"")}catch(pe){rt(a,a.return,pe)}}m&4&&a.stateNode!=null&&(g=a.memoizedProps,Ky(a,g,u!==null?u.memoizedProps:g)),m&1024&&(Wy=!0);break;case 6:if(_n(s,a),Tn(a),m&4){if(a.stateNode===null)throw Error(r(162));m=a.memoizedProps,u=a.stateNode;try{u.nodeValue=m}catch(pe){rt(a,a.return,pe)}}break;case 3:if(pd=null,g=Ar,Ar=hd(s.containerInfo),_n(s,a),Ar=g,Tn(a),m&4&&u!==null&&u.memoizedState.isDehydrated)try{go(s.containerInfo)}catch(pe){rt(a,a.return,pe)}Wy&&(Wy=!1,H2(a));break;case 4:m=Ar,Ar=hd(a.stateNode.containerInfo),_n(s,a),Tn(a),Ar=m;break;case 12:_n(s,a),Tn(a);break;case 31:_n(s,a),Tn(a),m&4&&(m=a.updateQueue,m!==null&&(a.updateQueue=null,Jf(a,m)));break;case 13:_n(s,a),Tn(a),a.child.flags&8192&&a.memoizedState!==null!=(u!==null&&u.memoizedState!==null)&&(td=dn()),m&4&&(m=a.updateQueue,m!==null&&(a.updateQueue=null,Jf(a,m)));break;case 22:g=a.memoizedState!==null;var I=u!==null&&u.memoizedState!==null,Z=xa,ne=Bt;if(xa=Z||g,Bt=ne||I,_n(s,a),Bt=ne,xa=Z,Tn(a),m&8192)e:for(s=a.stateNode,s._visibility=g?s._visibility&-2:s._visibility|1,g&&(u===null||I||xa||Bt||es(a)),u=null,s=a;;){if(s.tag===5||s.tag===26){if(u===null){I=u=s;try{if(v=I.stateNode,g)C=v.style,typeof C.setProperty=="function"?C.setProperty("display","none","important"):C.display="none";else{k=I.stateNode;var oe=I.memoizedProps.style,J=oe!=null&&oe.hasOwnProperty("display")?oe.display:null;k.style.display=J==null||typeof J=="boolean"?"":(""+J).trim()}}catch(pe){rt(I,I.return,pe)}}}else if(s.tag===6){if(u===null){I=s;try{I.stateNode.nodeValue=g?"":I.memoizedProps}catch(pe){rt(I,I.return,pe)}}}else if(s.tag===18){if(u===null){I=s;try{var te=I.stateNode;g?RO(te,!0):RO(I.stateNode,!1)}catch(pe){rt(I,I.return,pe)}}}else if((s.tag!==22&&s.tag!==23||s.memoizedState===null||s===a)&&s.child!==null){s.child.return=s,s=s.child;continue}if(s===a)break e;for(;s.sibling===null;){if(s.return===null||s.return===a)break e;u===s&&(u=null),s=s.return}u===s&&(u=null),s.sibling.return=s.return,s=s.sibling}m&4&&(m=a.updateQueue,m!==null&&(u=m.retryQueue,u!==null&&(m.retryQueue=null,Jf(a,u))));break;case 19:_n(s,a),Tn(a),m&4&&(m=a.updateQueue,m!==null&&(a.updateQueue=null,Jf(a,m)));break;case 30:break;case 21:break;default:_n(s,a),Tn(a)}}function Tn(a){var s=a.flags;if(s&2){try{for(var u,m=a.return;m!==null;){if(D2(m)){u=m;break}m=m.return}if(u==null)throw Error(r(160));switch(u.tag){case 27:var g=u.stateNode,v=Yy(a);Qf(a,v,g);break;case 5:var C=u.stateNode;u.flags&32&&(qs(C,""),u.flags&=-33);var k=Yy(a);Qf(a,k,C);break;case 3:case 4:var I=u.stateNode.containerInfo,Z=Yy(a);Xy(a,Z,I);break;default:throw Error(r(161))}}catch(ne){rt(a,a.return,ne)}a.flags&=-3}s&4096&&(a.flags&=-4097)}function H2(a){if(a.subtreeFlags&1024)for(a=a.child;a!==null;){var s=a;H2(s),s.tag===5&&s.flags&1024&&s.stateNode.reset(),a=a.sibling}}function va(a,s){if(s.subtreeFlags&8772)for(s=s.child;s!==null;)$2(a,s.alternate,s),s=s.sibling}function es(a){for(a=a.child;a!==null;){var s=a;switch(s.tag){case 0:case 11:case 14:case 15:oi(4,s,s.return),es(s);break;case 1:Vr(s,s.return);var u=s.stateNode;typeof u.componentWillUnmount=="function"&&R2(s,s.return,u),es(s);break;case 27:yc(s.stateNode);case 26:case 5:Vr(s,s.return),es(s);break;case 22:s.memoizedState===null&&es(s);break;case 30:es(s);break;default:es(s)}a=a.sibling}}function ba(a,s,u){for(u=u&&(s.subtreeFlags&8772)!==0,s=s.child;s!==null;){var m=s.alternate,g=a,v=s,C=v.flags;switch(v.tag){case 0:case 11:case 15:ba(g,v,u),sc(4,v);break;case 1:if(ba(g,v,u),m=v,g=m.stateNode,typeof g.componentDidMount=="function")try{g.componentDidMount()}catch(Z){rt(m,m.return,Z)}if(m=v,g=m.updateQueue,g!==null){var k=m.stateNode;try{var I=g.shared.hiddenCallbacks;if(I!==null)for(g.shared.hiddenCallbacks=null,g=0;g<I.length;g++)jA(I[g],k)}catch(Z){rt(m,m.return,Z)}}u&&C&64&&P2(v),oc(v,v.return);break;case 27:z2(v);case 26:case 5:ba(g,v,u),u&&m===null&&C&4&&k2(v),oc(v,v.return);break;case 12:ba(g,v,u);break;case 31:ba(g,v,u),u&&C&4&&I2(g,v);break;case 13:ba(g,v,u),u&&C&4&&U2(g,v);break;case 22:v.memoizedState===null&&ba(g,v,u),oc(v,v.return);break;case 30:break;default:ba(g,v,u)}s=s.sibling}}function Zy(a,s){var u=null;a!==null&&a.memoizedState!==null&&a.memoizedState.cachePool!==null&&(u=a.memoizedState.cachePool.pool),a=null,s.memoizedState!==null&&s.memoizedState.cachePool!==null&&(a=s.memoizedState.cachePool.pool),a!==u&&(a!=null&&a.refCount++,u!=null&&Kl(u))}function Qy(a,s){a=null,s.alternate!==null&&(a=s.alternate.memoizedState.cache),s=s.memoizedState.cache,s!==a&&(s.refCount++,a!=null&&Kl(a))}function Or(a,s,u,m){if(s.subtreeFlags&10256)for(s=s.child;s!==null;)F2(a,s,u,m),s=s.sibling}function F2(a,s,u,m){var g=s.flags;switch(s.tag){case 0:case 11:case 15:Or(a,s,u,m),g&2048&&sc(9,s);break;case 1:Or(a,s,u,m);break;case 3:Or(a,s,u,m),g&2048&&(a=null,s.alternate!==null&&(a=s.alternate.memoizedState.cache),s=s.memoizedState.cache,s!==a&&(s.refCount++,a!=null&&Kl(a)));break;case 12:if(g&2048){Or(a,s,u,m),a=s.stateNode;try{var v=s.memoizedProps,C=v.id,k=v.onPostCommit;typeof k=="function"&&k(C,s.alternate===null?"mount":"update",a.passiveEffectDuration,-0)}catch(I){rt(s,s.return,I)}}else Or(a,s,u,m);break;case 31:Or(a,s,u,m);break;case 13:Or(a,s,u,m);break;case 23:break;case 22:v=s.stateNode,C=s.alternate,s.memoizedState!==null?v._visibility&2?Or(a,s,u,m):lc(a,s):v._visibility&2?Or(a,s,u,m):(v._visibility|=2,so(a,s,u,m,(s.subtreeFlags&10256)!==0||!1)),g&2048&&Zy(C,s);break;case 24:Or(a,s,u,m),g&2048&&Qy(s.alternate,s);break;default:Or(a,s,u,m)}}function so(a,s,u,m,g){for(g=g&&((s.subtreeFlags&10256)!==0||!1),s=s.child;s!==null;){var v=a,C=s,k=u,I=m,Z=C.flags;switch(C.tag){case 0:case 11:case 15:so(v,C,k,I,g),sc(8,C);break;case 23:break;case 22:var ne=C.stateNode;C.memoizedState!==null?ne._visibility&2?so(v,C,k,I,g):lc(v,C):(ne._visibility|=2,so(v,C,k,I,g)),g&&Z&2048&&Zy(C.alternate,C);break;case 24:so(v,C,k,I,g),g&&Z&2048&&Qy(C.alternate,C);break;default:so(v,C,k,I,g)}s=s.sibling}}function lc(a,s){if(s.subtreeFlags&10256)for(s=s.child;s!==null;){var u=a,m=s,g=m.flags;switch(m.tag){case 22:lc(u,m),g&2048&&Zy(m.alternate,m);break;case 24:lc(u,m),g&2048&&Qy(m.alternate,m);break;default:lc(u,m)}s=s.sibling}}var cc=8192;function oo(a,s,u){if(a.subtreeFlags&cc)for(a=a.child;a!==null;)G2(a,s,u),a=a.sibling}function G2(a,s,u){switch(a.tag){case 26:oo(a,s,u),a.flags&cc&&a.memoizedState!==null&&lB(u,Ar,a.memoizedState,a.memoizedProps);break;case 5:oo(a,s,u);break;case 3:case 4:var m=Ar;Ar=hd(a.stateNode.containerInfo),oo(a,s,u),Ar=m;break;case 22:a.memoizedState===null&&(m=a.alternate,m!==null&&m.memoizedState!==null?(m=cc,cc=16777216,oo(a,s,u),cc=m):oo(a,s,u));break;default:oo(a,s,u)}}function K2(a){var s=a.alternate;if(s!==null&&(a=s.child,a!==null)){s.child=null;do s=a.sibling,a.sibling=null,a=s;while(a!==null)}}function uc(a){var s=a.deletions;if((a.flags&16)!==0){if(s!==null)for(var u=0;u<s.length;u++){var m=s[u];Qt=m,X2(m,a)}K2(a)}if(a.subtreeFlags&10256)for(a=a.child;a!==null;)Y2(a),a=a.sibling}function Y2(a){switch(a.tag){case 0:case 11:case 15:uc(a),a.flags&2048&&oi(9,a,a.return);break;case 3:uc(a);break;case 12:uc(a);break;case 22:var s=a.stateNode;a.memoizedState!==null&&s._visibility&2&&(a.return===null||a.return.tag!==13)?(s._visibility&=-3,ed(a)):uc(a);break;default:uc(a)}}function ed(a){var s=a.deletions;if((a.flags&16)!==0){if(s!==null)for(var u=0;u<s.length;u++){var m=s[u];Qt=m,X2(m,a)}K2(a)}for(a=a.child;a!==null;){switch(s=a,s.tag){case 0:case 11:case 15:oi(8,s,s.return),ed(s);break;case 22:u=s.stateNode,u._visibility&2&&(u._visibility&=-3,ed(s));break;default:ed(s)}a=a.sibling}}function X2(a,s){for(;Qt!==null;){var u=Qt;switch(u.tag){case 0:case 11:case 15:oi(8,u,s);break;case 23:case 22:if(u.memoizedState!==null&&u.memoizedState.cachePool!==null){var m=u.memoizedState.cachePool.pool;m!=null&&m.refCount++}break;case 24:Kl(u.memoizedState.cache)}if(m=u.child,m!==null)m.return=u,Qt=m;else e:for(u=a;Qt!==null;){m=Qt;var g=m.sibling,v=m.return;if(B2(m),m===u){Qt=null;break e}if(g!==null){g.return=v,Qt=g;break e}Qt=v}}}var S$={getCacheForType:function(a){var s=an(zt),u=s.data.get(a);return u===void 0&&(u=a(),s.data.set(a,u)),u},cacheSignal:function(){return an(zt).controller.signal}},N$=typeof WeakMap=="function"?WeakMap:Map,Ze=0,ct=null,Ue=null,He=0,nt=0,qn=null,li=!1,lo=!1,Jy=!1,ja=0,Ct=0,ci=0,ts=0,ex=0,In=0,co=0,fc=null,En=null,tx=!1,td=0,W2=0,nd=1/0,rd=null,ui=null,Vt=0,fi=null,uo=null,wa=0,nx=0,rx=null,Z2=null,dc=0,ax=null;function Un(){return(Ze&2)!==0&&He!==0?He&-He:$.T!==null?ux():hN()}function Q2(){if(In===0)if((He&536870912)===0||Ge){var a=ff;ff<<=1,(ff&3932160)===0&&(ff=262144),In=a}else In=536870912;return a=$n.current,a!==null&&(a.flags|=32),In}function Cn(a,s,u){(a===ct&&(nt===2||nt===9)||a.cancelPendingCommit!==null)&&(fo(a,0),di(a,He,In,!1)),Rl(a,u),((Ze&2)===0||a!==ct)&&(a===ct&&((Ze&2)===0&&(ts|=u),Ct===4&&di(a,He,In,!1)),Hr(a))}function J2(a,s,u){if((Ze&6)!==0)throw Error(r(327));var m=!u&&(s&127)===0&&(s&a.expiredLanes)===0||Pl(a,s),g=m?_$(a,s):sx(a,s,!0),v=m;do{if(g===0){lo&&!m&&di(a,s,0,!1);break}else{if(u=a.current.alternate,v&&!A$(u)){g=sx(a,s,!1),v=!1;continue}if(g===2){if(v=s,a.errorRecoveryDisabledLanes&v)var C=0;else C=a.pendingLanes&-536870913,C=C!==0?C:C&536870912?536870912:0;if(C!==0){s=C;e:{var k=a;g=fc;var I=k.current.memoizedState.isDehydrated;if(I&&(fo(k,C).flags|=256),C=sx(k,C,!1),C!==2){if(Jy&&!I){k.errorRecoveryDisabledLanes|=v,ts|=v,g=4;break e}v=En,En=g,v!==null&&(En===null?En=v:En.push.apply(En,v))}g=C}if(v=!1,g!==2)continue}}if(g===1){fo(a,0),di(a,s,0,!0);break}e:{switch(m=a,v=g,v){case 0:case 1:throw Error(r(345));case 4:if((s&4194048)!==s)break;case 6:di(m,s,In,!li);break e;case 2:En=null;break;case 3:case 5:break;default:throw Error(r(329))}if((s&62914560)===s&&(g=td+300-dn(),10<g)){if(di(m,s,In,!li),hf(m,0,!0)!==0)break e;wa=s,m.timeoutHandle=CO(eO.bind(null,m,u,En,rd,tx,s,In,ts,co,li,v,"Throttled",-0,0),g);break e}eO(m,u,En,rd,tx,s,In,ts,co,li,v,null,-0,0)}}break}while(!0);Hr(a)}function eO(a,s,u,m,g,v,C,k,I,Z,ne,oe,J,te){if(a.timeoutHandle=-1,oe=s.subtreeFlags,oe&8192||(oe&16785408)===16785408){oe={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:oa},G2(s,v,oe);var pe=(v&62914560)===v?td-dn():(v&4194048)===v?W2-dn():0;if(pe=cB(oe,pe),pe!==null){wa=v,a.cancelPendingCommit=pe(lO.bind(null,a,s,v,u,m,g,C,k,I,ne,oe,null,J,te)),di(a,v,C,!Z);return}}lO(a,s,v,u,m,g,C,k,I)}function A$(a){for(var s=a;;){var u=s.tag;if((u===0||u===11||u===15)&&s.flags&16384&&(u=s.updateQueue,u!==null&&(u=u.stores,u!==null)))for(var m=0;m<u.length;m++){var g=u[m],v=g.getSnapshot;g=g.value;try{if(!zn(v(),g))return!1}catch{return!1}}if(u=s.child,s.subtreeFlags&16384&&u!==null)u.return=s,s=u;else{if(s===a)break;for(;s.sibling===null;){if(s.return===null||s.return===a)return!0;s=s.return}s.sibling.return=s.return,s=s.sibling}}return!0}function di(a,s,u,m){s&=~ex,s&=~ts,a.suspendedLanes|=s,a.pingedLanes&=~s,m&&(a.warmLanes|=s),m=a.expirationTimes;for(var g=s;0<g;){var v=31-Dn(g),C=1<<v;m[v]=-1,g&=~C}u!==0&&uN(a,u,s)}function ad(){return(Ze&6)===0?(hc(0),!1):!0}function ix(){if(Ue!==null){if(nt===0)var a=Ue.return;else a=Ue,fa=Gi=null,jy(a),to=null,Xl=0,a=Ue;for(;a!==null;)M2(a.alternate,a),a=a.return;Ue=null}}function fo(a,s){var u=a.timeoutHandle;u!==-1&&(a.timeoutHandle=-1,F$(u)),u=a.cancelPendingCommit,u!==null&&(a.cancelPendingCommit=null,u()),wa=0,ix(),ct=a,Ue=u=ca(a.current,null),He=s,nt=0,qn=null,li=!1,lo=Pl(a,s),Jy=!1,co=In=ex=ts=ci=Ct=0,En=fc=null,tx=!1,(s&8)!==0&&(s|=s&32);var m=a.entangledLanes;if(m!==0)for(a=a.entanglements,m&=s;0<m;){var g=31-Dn(m),v=1<<g;s|=a[g],m&=~v}return ja=s,Af(),u}function tO(a,s){De=null,$.H=rc,s===eo||s===Rf?(s=xA(),nt=3):s===cy?(s=xA(),nt=4):nt=s===Ly?8:s!==null&&typeof s=="object"&&typeof s.then=="function"?6:1,qn=s,Ue===null&&(Ct=1,Kf(a,rr(s,a.current)))}function nO(){var a=$n.current;return a===null?!0:(He&4194048)===He?or===null:(He&62914560)===He||(He&536870912)!==0?a===or:!1}function rO(){var a=$.H;return $.H=rc,a===null?rc:a}function aO(){var a=$.A;return $.A=S$,a}function id(){Ct=4,li||(He&4194048)!==He&&$n.current!==null||(lo=!0),(ci&134217727)===0&&(ts&134217727)===0||ct===null||di(ct,He,In,!1)}function sx(a,s,u){var m=Ze;Ze|=2;var g=rO(),v=aO();(ct!==a||He!==s)&&(rd=null,fo(a,s)),s=!1;var C=Ct;e:do try{if(nt!==0&&Ue!==null){var k=Ue,I=qn;switch(nt){case 8:ix(),C=6;break e;case 3:case 2:case 9:case 6:$n.current===null&&(s=!0);var Z=nt;if(nt=0,qn=null,ho(a,k,I,Z),u&&lo){C=0;break e}break;default:Z=nt,nt=0,qn=null,ho(a,k,I,Z)}}O$(),C=Ct;break}catch(ne){tO(a,ne)}while(!0);return s&&a.shellSuspendCounter++,fa=Gi=null,Ze=m,$.H=g,$.A=v,Ue===null&&(ct=null,He=0,Af()),C}function O$(){for(;Ue!==null;)iO(Ue)}function _$(a,s){var u=Ze;Ze|=2;var m=rO(),g=aO();ct!==a||He!==s?(rd=null,nd=dn()+500,fo(a,s)):lo=Pl(a,s);e:do try{if(nt!==0&&Ue!==null){s=Ue;var v=qn;t:switch(nt){case 1:nt=0,qn=null,ho(a,s,v,1);break;case 2:case 9:if(pA(v)){nt=0,qn=null,sO(s);break}s=function(){nt!==2&&nt!==9||ct!==a||(nt=7),Hr(a)},v.then(s,s);break e;case 3:nt=7;break e;case 4:nt=5;break e;case 7:pA(v)?(nt=0,qn=null,sO(s)):(nt=0,qn=null,ho(a,s,v,7));break;case 5:var C=null;switch(Ue.tag){case 26:C=Ue.memoizedState;case 5:case 27:var k=Ue;if(C?FO(C):k.stateNode.complete){nt=0,qn=null;var I=k.sibling;if(I!==null)Ue=I;else{var Z=k.return;Z!==null?(Ue=Z,sd(Z)):Ue=null}break t}}nt=0,qn=null,ho(a,s,v,5);break;case 6:nt=0,qn=null,ho(a,s,v,6);break;case 8:ix(),Ct=6;break e;default:throw Error(r(462))}}T$();break}catch(ne){tO(a,ne)}while(!0);return fa=Gi=null,$.H=m,$.A=g,Ze=u,Ue!==null?0:(ct=null,He=0,Af(),Ct)}function T$(){for(;Ue!==null&&!ia();)iO(Ue)}function iO(a){var s=E2(a.alternate,a,ja);a.memoizedProps=a.pendingProps,s===null?sd(a):Ue=s}function sO(a){var s=a,u=s.alternate;switch(s.tag){case 15:case 0:s=S2(u,s,s.pendingProps,s.type,void 0,He);break;case 11:s=S2(u,s,s.pendingProps,s.type.render,s.ref,He);break;case 5:jy(s);default:M2(u,s),s=Ue=aA(s,ja),s=E2(u,s,ja)}a.memoizedProps=a.pendingProps,s===null?sd(a):Ue=s}function ho(a,s,u,m){fa=Gi=null,jy(s),to=null,Xl=0;var g=s.return;try{if(y$(a,g,s,u,He)){Ct=1,Kf(a,rr(u,a.current)),Ue=null;return}}catch(v){if(g!==null)throw Ue=g,v;Ct=1,Kf(a,rr(u,a.current)),Ue=null;return}s.flags&32768?(Ge||m===1?a=!0:lo||(He&536870912)!==0?a=!1:(li=a=!0,(m===2||m===9||m===3||m===6)&&(m=$n.current,m!==null&&m.tag===13&&(m.flags|=16384))),oO(s,a)):sd(s)}function sd(a){var s=a;do{if((s.flags&32768)!==0){oO(s,li);return}a=s.return;var u=v$(s.alternate,s,ja);if(u!==null){Ue=u;return}if(s=s.sibling,s!==null){Ue=s;return}Ue=s=a}while(s!==null);Ct===0&&(Ct=5)}function oO(a,s){do{var u=b$(a.alternate,a);if(u!==null){u.flags&=32767,Ue=u;return}if(u=a.return,u!==null&&(u.flags|=32768,u.subtreeFlags=0,u.deletions=null),!s&&(a=a.sibling,a!==null)){Ue=a;return}Ue=a=u}while(a!==null);Ct=6,Ue=null}function lO(a,s,u,m,g,v,C,k,I){a.cancelPendingCommit=null;do od();while(Vt!==0);if((Ze&6)!==0)throw Error(r(327));if(s!==null){if(s===a.current)throw Error(r(177));if(v=s.lanes|s.childLanes,v|=Yp,o8(a,u,v,C,k,I),a===ct&&(Ue=ct=null,He=0),uo=s,fi=a,wa=u,nx=v,rx=g,Z2=m,(s.subtreeFlags&10256)!==0||(s.flags&10256)!==0?(a.callbackNode=null,a.callbackPriority=0,P$(cf,function(){return hO(),null})):(a.callbackNode=null,a.callbackPriority=0),m=(s.flags&13878)!==0,(s.subtreeFlags&13878)!==0||m){m=$.T,$.T=null,g=G.p,G.p=2,C=Ze,Ze|=4;try{j$(a,s,u)}finally{Ze=C,G.p=g,$.T=m}}Vt=1,cO(),uO(),fO()}}function cO(){if(Vt===1){Vt=0;var a=fi,s=uo,u=(s.flags&13878)!==0;if((s.subtreeFlags&13878)!==0||u){u=$.T,$.T=null;var m=G.p;G.p=2;var g=Ze;Ze|=4;try{V2(s,a);var v=gx,C=XN(a.containerInfo),k=v.focusedElem,I=v.selectionRange;if(C!==k&&k&&k.ownerDocument&&YN(k.ownerDocument.documentElement,k)){if(I!==null&&Vp(k)){var Z=I.start,ne=I.end;if(ne===void 0&&(ne=Z),"selectionStart"in k)k.selectionStart=Z,k.selectionEnd=Math.min(ne,k.value.length);else{var oe=k.ownerDocument||document,J=oe&&oe.defaultView||window;if(J.getSelection){var te=J.getSelection(),pe=k.textContent.length,Oe=Math.min(I.start,pe),ot=I.end===void 0?Oe:Math.min(I.end,pe);!te.extend&&Oe>ot&&(C=ot,ot=Oe,Oe=C);var K=KN(k,Oe),V=KN(k,ot);if(K&&V&&(te.rangeCount!==1||te.anchorNode!==K.node||te.anchorOffset!==K.offset||te.focusNode!==V.node||te.focusOffset!==V.offset)){var W=oe.createRange();W.setStart(K.node,K.offset),te.removeAllRanges(),Oe>ot?(te.addRange(W),te.extend(V.node,V.offset)):(W.setEnd(V.node,V.offset),te.addRange(W))}}}}for(oe=[],te=k;te=te.parentNode;)te.nodeType===1&&oe.push({element:te,left:te.scrollLeft,top:te.scrollTop});for(typeof k.focus=="function"&&k.focus(),k=0;k<oe.length;k++){var se=oe[k];se.element.scrollLeft=se.left,se.element.scrollTop=se.top}}vd=!!xx,gx=xx=null}finally{Ze=g,G.p=m,$.T=u}}a.current=s,Vt=2}}function uO(){if(Vt===2){Vt=0;var a=fi,s=uo,u=(s.flags&8772)!==0;if((s.subtreeFlags&8772)!==0||u){u=$.T,$.T=null;var m=G.p;G.p=2;var g=Ze;Ze|=4;try{$2(a,s.alternate,s)}finally{Ze=g,G.p=m,$.T=u}}Vt=3}}function fO(){if(Vt===4||Vt===3){Vt=0,Cl();var a=fi,s=uo,u=wa,m=Z2;(s.subtreeFlags&10256)!==0||(s.flags&10256)!==0?Vt=5:(Vt=0,uo=fi=null,dO(a,a.pendingLanes));var g=a.pendingLanes;if(g===0&&(ui=null),Np(u),s=s.stateNode,kn&&typeof kn.onCommitFiberRoot=="function")try{kn.onCommitFiberRoot(Ml,s,void 0,(s.current.flags&128)===128)}catch{}if(m!==null){s=$.T,g=G.p,G.p=2,$.T=null;try{for(var v=a.onRecoverableError,C=0;C<m.length;C++){var k=m[C];v(k.value,{componentStack:k.stack})}}finally{$.T=s,G.p=g}}(wa&3)!==0&&od(),Hr(a),g=a.pendingLanes,(u&261930)!==0&&(g&42)!==0?a===ax?dc++:(dc=0,ax=a):dc=0,hc(0)}}function dO(a,s){(a.pooledCacheLanes&=s)===0&&(s=a.pooledCache,s!=null&&(a.pooledCache=null,Kl(s)))}function od(){return cO(),uO(),fO(),hO()}function hO(){if(Vt!==5)return!1;var a=fi,s=nx;nx=0;var u=Np(wa),m=$.T,g=G.p;try{G.p=32>u?32:u,$.T=null,u=rx,rx=null;var v=fi,C=wa;if(Vt=0,uo=fi=null,wa=0,(Ze&6)!==0)throw Error(r(331));var k=Ze;if(Ze|=4,Y2(v.current),F2(v,v.current,C,u),Ze=k,hc(0,!1),kn&&typeof kn.onPostCommitFiberRoot=="function")try{kn.onPostCommitFiberRoot(Ml,v)}catch{}return!0}finally{G.p=g,$.T=m,dO(a,s)}}function mO(a,s,u){s=rr(u,s),s=zy(a.stateNode,s,2),a=ai(a,s,2),a!==null&&(Rl(a,2),Hr(a))}function rt(a,s,u){if(a.tag===3)mO(a,a,u);else for(;s!==null;){if(s.tag===3){mO(s,a,u);break}else if(s.tag===1){var m=s.stateNode;if(typeof s.type.getDerivedStateFromError=="function"||typeof m.componentDidCatch=="function"&&(ui===null||!ui.has(m))){a=rr(u,a),u=p2(2),m=ai(s,u,2),m!==null&&(y2(u,m,s,a),Rl(m,2),Hr(m));break}}s=s.return}}function ox(a,s,u){var m=a.pingCache;if(m===null){m=a.pingCache=new N$;var g=new Set;m.set(s,g)}else g=m.get(s),g===void 0&&(g=new Set,m.set(s,g));g.has(u)||(Jy=!0,g.add(u),a=E$.bind(null,a,s,u),s.then(a,a))}function E$(a,s,u){var m=a.pingCache;m!==null&&m.delete(s),a.pingedLanes|=a.suspendedLanes&u,a.warmLanes&=~u,ct===a&&(He&u)===u&&(Ct===4||Ct===3&&(He&62914560)===He&&300>dn()-td?(Ze&2)===0&&fo(a,0):ex|=u,co===He&&(co=0)),Hr(a)}function pO(a,s){s===0&&(s=cN()),a=Vi(a,s),a!==null&&(Rl(a,s),Hr(a))}function C$(a){var s=a.memoizedState,u=0;s!==null&&(u=s.retryLane),pO(a,u)}function M$(a,s){var u=0;switch(a.tag){case 31:case 13:var m=a.stateNode,g=a.memoizedState;g!==null&&(u=g.retryLane);break;case 19:m=a.stateNode;break;case 22:m=a.stateNode._retryCache;break;default:throw Error(r(314))}m!==null&&m.delete(s),pO(a,u)}function P$(a,s){return Ya(a,s)}var ld=null,mo=null,lx=!1,cd=!1,cx=!1,hi=0;function Hr(a){a!==mo&&a.next===null&&(mo===null?ld=mo=a:mo=mo.next=a),cd=!0,lx||(lx=!0,k$())}function hc(a,s){if(!cx&&cd){cx=!0;do for(var u=!1,m=ld;m!==null;){if(a!==0){var g=m.pendingLanes;if(g===0)var v=0;else{var C=m.suspendedLanes,k=m.pingedLanes;v=(1<<31-Dn(42|a)+1)-1,v&=g&~(C&~k),v=v&201326741?v&201326741|1:v?v|2:0}v!==0&&(u=!0,vO(m,v))}else v=He,v=hf(m,m===ct?v:0,m.cancelPendingCommit!==null||m.timeoutHandle!==-1),(v&3)===0||Pl(m,v)||(u=!0,vO(m,v));m=m.next}while(u);cx=!1}}function R$(){yO()}function yO(){cd=lx=!1;var a=0;hi!==0&&H$()&&(a=hi);for(var s=dn(),u=null,m=ld;m!==null;){var g=m.next,v=xO(m,s);v===0?(m.next=null,u===null?ld=g:u.next=g,g===null&&(mo=u)):(u=m,(a!==0||(v&3)!==0)&&(cd=!0)),m=g}Vt!==0&&Vt!==5||hc(a),hi!==0&&(hi=0)}function xO(a,s){for(var u=a.suspendedLanes,m=a.pingedLanes,g=a.expirationTimes,v=a.pendingLanes&-62914561;0<v;){var C=31-Dn(v),k=1<<C,I=g[C];I===-1?((k&u)===0||(k&m)!==0)&&(g[C]=s8(k,s)):I<=s&&(a.expiredLanes|=k),v&=~k}if(s=ct,u=He,u=hf(a,a===s?u:0,a.cancelPendingCommit!==null||a.timeoutHandle!==-1),m=a.callbackNode,u===0||a===s&&(nt===2||nt===9)||a.cancelPendingCommit!==null)return m!==null&&m!==null&&Sr(m),a.callbackNode=null,a.callbackPriority=0;if((u&3)===0||Pl(a,u)){if(s=u&-u,s===a.callbackPriority)return s;switch(m!==null&&Sr(m),Np(u)){case 2:case 8:u=oN;break;case 32:u=cf;break;case 268435456:u=lN;break;default:u=cf}return m=gO.bind(null,a),u=Ya(u,m),a.callbackPriority=s,a.callbackNode=u,s}return m!==null&&m!==null&&Sr(m),a.callbackPriority=2,a.callbackNode=null,2}function gO(a,s){if(Vt!==0&&Vt!==5)return a.callbackNode=null,a.callbackPriority=0,null;var u=a.callbackNode;if(od()&&a.callbackNode!==u)return null;var m=He;return m=hf(a,a===ct?m:0,a.cancelPendingCommit!==null||a.timeoutHandle!==-1),m===0?null:(J2(a,m,s),xO(a,dn()),a.callbackNode!=null&&a.callbackNode===u?gO.bind(null,a):null)}function vO(a,s){if(od())return null;J2(a,s,!0)}function k$(){G$(function(){(Ze&6)!==0?Ya(sN,R$):yO()})}function ux(){if(hi===0){var a=Qs;a===0&&(a=uf,uf<<=1,(uf&261888)===0&&(uf=256)),hi=a}return hi}function bO(a){return a==null||typeof a=="symbol"||typeof a=="boolean"?null:typeof a=="function"?a:xf(""+a)}function jO(a,s){var u=s.ownerDocument.createElement("input");return u.name=s.name,u.value=s.value,a.id&&u.setAttribute("form",a.id),s.parentNode.insertBefore(u,s),a=new FormData(a),u.parentNode.removeChild(u),a}function D$(a,s,u,m,g){if(s==="submit"&&u&&u.stateNode===g){var v=bO((g[Nn]||null).action),C=m.submitter;C&&(s=(s=C[Nn]||null)?bO(s.formAction):C.getAttribute("formAction"),s!==null&&(v=s,C=null));var k=new jf("action","action",null,m,g);a.push({event:k,listeners:[{instance:null,listener:function(){if(m.defaultPrevented){if(hi!==0){var I=C?jO(g,C):new FormData(g);Cy(u,{pending:!0,data:I,method:g.method,action:v},null,I)}}else typeof v=="function"&&(k.preventDefault(),I=C?jO(g,C):new FormData(g),Cy(u,{pending:!0,data:I,method:g.method,action:v},v,I))},currentTarget:g}]})}}for(var fx=0;fx<Kp.length;fx++){var dx=Kp[fx],z$=dx.toLowerCase(),L$=dx[0].toUpperCase()+dx.slice(1);Nr(z$,"on"+L$)}Nr(QN,"onAnimationEnd"),Nr(JN,"onAnimationIteration"),Nr(eA,"onAnimationStart"),Nr("dblclick","onDoubleClick"),Nr("focusin","onFocus"),Nr("focusout","onBlur"),Nr(J8,"onTransitionRun"),Nr(e$,"onTransitionStart"),Nr(t$,"onTransitionCancel"),Nr(tA,"onTransitionEnd"),$s("onMouseEnter",["mouseout","mouseover"]),$s("onMouseLeave",["mouseout","mouseover"]),$s("onPointerEnter",["pointerout","pointerover"]),$s("onPointerLeave",["pointerout","pointerover"]),Bi("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),Bi("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),Bi("onBeforeInput",["compositionend","keypress","textInput","paste"]),Bi("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),Bi("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),Bi("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var mc="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(" "),$$=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(mc));function wO(a,s){s=(s&4)!==0;for(var u=0;u<a.length;u++){var m=a[u],g=m.event;m=m.listeners;e:{var v=void 0;if(s)for(var C=m.length-1;0<=C;C--){var k=m[C],I=k.instance,Z=k.currentTarget;if(k=k.listener,I!==v&&g.isPropagationStopped())break e;v=k,g.currentTarget=Z;try{v(g)}catch(ne){Nf(ne)}g.currentTarget=null,v=I}else for(C=0;C<m.length;C++){if(k=m[C],I=k.instance,Z=k.currentTarget,k=k.listener,I!==v&&g.isPropagationStopped())break e;v=k,g.currentTarget=Z;try{v(g)}catch(ne){Nf(ne)}g.currentTarget=null,v=I}}}}function Ve(a,s){var u=s[Ap];u===void 0&&(u=s[Ap]=new Set);var m=a+"__bubble";u.has(m)||(SO(s,a,2,!1),u.add(m))}function hx(a,s,u){var m=0;s&&(m|=4),SO(u,a,m,s)}var ud="_reactListening"+Math.random().toString(36).slice(2);function mx(a){if(!a[ud]){a[ud]=!0,yN.forEach(function(u){u!=="selectionchange"&&($$.has(u)||hx(u,!1,a),hx(u,!0,a))});var s=a.nodeType===9?a:a.ownerDocument;s===null||s[ud]||(s[ud]=!0,hx("selectionchange",!1,s))}}function SO(a,s,u,m){switch(QO(s)){case 2:var g=dB;break;case 8:g=hB;break;default:g=Ex}u=g.bind(null,s,u,a),g=void 0,!kp||s!=="touchstart"&&s!=="touchmove"&&s!=="wheel"||(g=!0),m?g!==void 0?a.addEventListener(s,u,{capture:!0,passive:g}):a.addEventListener(s,u,!0):g!==void 0?a.addEventListener(s,u,{passive:g}):a.addEventListener(s,u,!1)}function px(a,s,u,m,g){var v=m;if((s&1)===0&&(s&2)===0&&m!==null)e:for(;;){if(m===null)return;var C=m.tag;if(C===3||C===4){var k=m.stateNode.containerInfo;if(k===g)break;if(C===4)for(C=m.return;C!==null;){var I=C.tag;if((I===3||I===4)&&C.stateNode.containerInfo===g)return;C=C.return}for(;k!==null;){if(C=Ds(k),C===null)return;if(I=C.tag,I===5||I===6||I===26||I===27){m=v=C;continue e}k=k.parentNode}}m=m.return}TN(function(){var Z=v,ne=Pp(u),oe=[];e:{var J=nA.get(a);if(J!==void 0){var te=jf,pe=a;switch(a){case"keypress":if(vf(u)===0)break e;case"keydown":case"keyup":te=M8;break;case"focusin":pe="focus",te=$p;break;case"focusout":pe="blur",te=$p;break;case"beforeblur":case"afterblur":te=$p;break;case"click":if(u.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":te=MN;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":te=v8;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":te=k8;break;case QN:case JN:case eA:te=w8;break;case tA:te=z8;break;case"scroll":case"scrollend":te=x8;break;case"wheel":te=$8;break;case"copy":case"cut":case"paste":te=N8;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":te=RN;break;case"toggle":case"beforetoggle":te=q8}var Oe=(s&4)!==0,ot=!Oe&&(a==="scroll"||a==="scrollend"),K=Oe?J!==null?J+"Capture":null:J;Oe=[];for(var V=Z,W;V!==null;){var se=V;if(W=se.stateNode,se=se.tag,se!==5&&se!==26&&se!==27||W===null||K===null||(se=zl(V,K),se!=null&&Oe.push(pc(V,se,W))),ot)break;V=V.return}0<Oe.length&&(J=new te(J,pe,null,u,ne),oe.push({event:J,listeners:Oe}))}}if((s&7)===0){e:{if(J=a==="mouseover"||a==="pointerover",te=a==="mouseout"||a==="pointerout",J&&u!==Mp&&(pe=u.relatedTarget||u.fromElement)&&(Ds(pe)||pe[ks]))break e;if((te||J)&&(J=ne.window===ne?ne:(J=ne.ownerDocument)?J.defaultView||J.parentWindow:window,te?(pe=u.relatedTarget||u.toElement,te=Z,pe=pe?Ds(pe):null,pe!==null&&(ot=o(pe),Oe=pe.tag,pe!==ot||Oe!==5&&Oe!==27&&Oe!==6)&&(pe=null)):(te=null,pe=Z),te!==pe)){if(Oe=MN,se="onMouseLeave",K="onMouseEnter",V="mouse",(a==="pointerout"||a==="pointerover")&&(Oe=RN,se="onPointerLeave",K="onPointerEnter",V="pointer"),ot=te==null?J:Dl(te),W=pe==null?J:Dl(pe),J=new Oe(se,V+"leave",te,u,ne),J.target=ot,J.relatedTarget=W,se=null,Ds(ne)===Z&&(Oe=new Oe(K,V+"enter",pe,u,ne),Oe.target=W,Oe.relatedTarget=ot,se=Oe),ot=se,te&&pe)t:{for(Oe=B$,K=te,V=pe,W=0,se=K;se;se=Oe(se))W++;se=0;for(var je=V;je;je=Oe(je))se++;for(;0<W-se;)K=Oe(K),W--;for(;0<se-W;)V=Oe(V),se--;for(;W--;){if(K===V||V!==null&&K===V.alternate){Oe=K;break t}K=Oe(K),V=Oe(V)}Oe=null}else Oe=null;te!==null&&NO(oe,J,te,Oe,!1),pe!==null&&ot!==null&&NO(oe,ot,pe,Oe,!0)}}e:{if(J=Z?Dl(Z):window,te=J.nodeName&&J.nodeName.toLowerCase(),te==="select"||te==="input"&&J.type==="file")var Ke=IN;else if(BN(J))if(UN)Ke=W8;else{Ke=Y8;var ve=K8}else te=J.nodeName,!te||te.toLowerCase()!=="input"||J.type!=="checkbox"&&J.type!=="radio"?Z&&Cp(Z.elementType)&&(Ke=IN):Ke=X8;if(Ke&&(Ke=Ke(a,Z))){qN(oe,Ke,u,ne);break e}ve&&ve(a,J,Z),a==="focusout"&&Z&&J.type==="number"&&Z.memoizedProps.value!=null&&Ep(J,"number",J.value)}switch(ve=Z?Dl(Z):window,a){case"focusin":(BN(ve)||ve.contentEditable==="true")&&(Hs=ve,Hp=Z,Hl=null);break;case"focusout":Hl=Hp=Hs=null;break;case"mousedown":Fp=!0;break;case"contextmenu":case"mouseup":case"dragend":Fp=!1,WN(oe,u,ne);break;case"selectionchange":if(Q8)break;case"keydown":case"keyup":WN(oe,u,ne)}var $e;if(qp)e:{switch(a){case"compositionstart":var Fe="onCompositionStart";break e;case"compositionend":Fe="onCompositionEnd";break e;case"compositionupdate":Fe="onCompositionUpdate";break e}Fe=void 0}else Vs?LN(a,u)&&(Fe="onCompositionEnd"):a==="keydown"&&u.keyCode===229&&(Fe="onCompositionStart");Fe&&(kN&&u.locale!=="ko"&&(Vs||Fe!=="onCompositionStart"?Fe==="onCompositionEnd"&&Vs&&($e=EN()):(Za=ne,Dp="value"in Za?Za.value:Za.textContent,Vs=!0)),ve=fd(Z,Fe),0<ve.length&&(Fe=new PN(Fe,a,null,u,ne),oe.push({event:Fe,listeners:ve}),$e?Fe.data=$e:($e=$N(u),$e!==null&&(Fe.data=$e)))),($e=U8?V8(a,u):H8(a,u))&&(Fe=fd(Z,"onBeforeInput"),0<Fe.length&&(ve=new PN("onBeforeInput","beforeinput",null,u,ne),oe.push({event:ve,listeners:Fe}),ve.data=$e)),D$(oe,a,Z,u,ne)}wO(oe,s)})}function pc(a,s,u){return{instance:a,listener:s,currentTarget:u}}function fd(a,s){for(var u=s+"Capture",m=[];a!==null;){var g=a,v=g.stateNode;if(g=g.tag,g!==5&&g!==26&&g!==27||v===null||(g=zl(a,u),g!=null&&m.unshift(pc(a,g,v)),g=zl(a,s),g!=null&&m.push(pc(a,g,v))),a.tag===3)return m;a=a.return}return[]}function B$(a){if(a===null)return null;do a=a.return;while(a&&a.tag!==5&&a.tag!==27);return a||null}function NO(a,s,u,m,g){for(var v=s._reactName,C=[];u!==null&&u!==m;){var k=u,I=k.alternate,Z=k.stateNode;if(k=k.tag,I!==null&&I===m)break;k!==5&&k!==26&&k!==27||Z===null||(I=Z,g?(Z=zl(u,v),Z!=null&&C.unshift(pc(u,Z,I))):g||(Z=zl(u,v),Z!=null&&C.push(pc(u,Z,I)))),u=u.return}C.length!==0&&a.push({event:s,listeners:C})}var q$=/\r\n?/g,I$=/\u0000|\uFFFD/g;function AO(a){return(typeof a=="string"?a:""+a).replace(q$,`
|
||
`).replace(I$,"")}function OO(a,s){return s=AO(s),AO(a)===s}function st(a,s,u,m,g,v){switch(u){case"children":typeof m=="string"?s==="body"||s==="textarea"&&m===""||qs(a,m):(typeof m=="number"||typeof m=="bigint")&&s!=="body"&&qs(a,""+m);break;case"className":pf(a,"class",m);break;case"tabIndex":pf(a,"tabindex",m);break;case"dir":case"role":case"viewBox":case"width":case"height":pf(a,u,m);break;case"style":ON(a,m,v);break;case"data":if(s!=="object"){pf(a,"data",m);break}case"src":case"href":if(m===""&&(s!=="a"||u!=="href")){a.removeAttribute(u);break}if(m==null||typeof m=="function"||typeof m=="symbol"||typeof m=="boolean"){a.removeAttribute(u);break}m=xf(""+m),a.setAttribute(u,m);break;case"action":case"formAction":if(typeof m=="function"){a.setAttribute(u,"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 v=="function"&&(u==="formAction"?(s!=="input"&&st(a,s,"name",g.name,g,null),st(a,s,"formEncType",g.formEncType,g,null),st(a,s,"formMethod",g.formMethod,g,null),st(a,s,"formTarget",g.formTarget,g,null)):(st(a,s,"encType",g.encType,g,null),st(a,s,"method",g.method,g,null),st(a,s,"target",g.target,g,null)));if(m==null||typeof m=="symbol"||typeof m=="boolean"){a.removeAttribute(u);break}m=xf(""+m),a.setAttribute(u,m);break;case"onClick":m!=null&&(a.onclick=oa);break;case"onScroll":m!=null&&Ve("scroll",a);break;case"onScrollEnd":m!=null&&Ve("scrollend",a);break;case"dangerouslySetInnerHTML":if(m!=null){if(typeof m!="object"||!("__html"in m))throw Error(r(61));if(u=m.__html,u!=null){if(g.children!=null)throw Error(r(60));a.innerHTML=u}}break;case"multiple":a.multiple=m&&typeof m!="function"&&typeof m!="symbol";break;case"muted":a.muted=m&&typeof m!="function"&&typeof m!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(m==null||typeof m=="function"||typeof m=="boolean"||typeof m=="symbol"){a.removeAttribute("xlink:href");break}u=xf(""+m),a.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",u);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":m!=null&&typeof m!="function"&&typeof m!="symbol"?a.setAttribute(u,""+m):a.removeAttribute(u);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":m&&typeof m!="function"&&typeof m!="symbol"?a.setAttribute(u,""):a.removeAttribute(u);break;case"capture":case"download":m===!0?a.setAttribute(u,""):m!==!1&&m!=null&&typeof m!="function"&&typeof m!="symbol"?a.setAttribute(u,m):a.removeAttribute(u);break;case"cols":case"rows":case"size":case"span":m!=null&&typeof m!="function"&&typeof m!="symbol"&&!isNaN(m)&&1<=m?a.setAttribute(u,m):a.removeAttribute(u);break;case"rowSpan":case"start":m==null||typeof m=="function"||typeof m=="symbol"||isNaN(m)?a.removeAttribute(u):a.setAttribute(u,m);break;case"popover":Ve("beforetoggle",a),Ve("toggle",a),mf(a,"popover",m);break;case"xlinkActuate":sa(a,"http://www.w3.org/1999/xlink","xlink:actuate",m);break;case"xlinkArcrole":sa(a,"http://www.w3.org/1999/xlink","xlink:arcrole",m);break;case"xlinkRole":sa(a,"http://www.w3.org/1999/xlink","xlink:role",m);break;case"xlinkShow":sa(a,"http://www.w3.org/1999/xlink","xlink:show",m);break;case"xlinkTitle":sa(a,"http://www.w3.org/1999/xlink","xlink:title",m);break;case"xlinkType":sa(a,"http://www.w3.org/1999/xlink","xlink:type",m);break;case"xmlBase":sa(a,"http://www.w3.org/XML/1998/namespace","xml:base",m);break;case"xmlLang":sa(a,"http://www.w3.org/XML/1998/namespace","xml:lang",m);break;case"xmlSpace":sa(a,"http://www.w3.org/XML/1998/namespace","xml:space",m);break;case"is":mf(a,"is",m);break;case"innerText":case"textContent":break;default:(!(2<u.length)||u[0]!=="o"&&u[0]!=="O"||u[1]!=="n"&&u[1]!=="N")&&(u=p8.get(u)||u,mf(a,u,m))}}function yx(a,s,u,m,g,v){switch(u){case"style":ON(a,m,v);break;case"dangerouslySetInnerHTML":if(m!=null){if(typeof m!="object"||!("__html"in m))throw Error(r(61));if(u=m.__html,u!=null){if(g.children!=null)throw Error(r(60));a.innerHTML=u}}break;case"children":typeof m=="string"?qs(a,m):(typeof m=="number"||typeof m=="bigint")&&qs(a,""+m);break;case"onScroll":m!=null&&Ve("scroll",a);break;case"onScrollEnd":m!=null&&Ve("scrollend",a);break;case"onClick":m!=null&&(a.onclick=oa);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!xN.hasOwnProperty(u))e:{if(u[0]==="o"&&u[1]==="n"&&(g=u.endsWith("Capture"),s=u.slice(2,g?u.length-7:void 0),v=a[Nn]||null,v=v!=null?v[u]:null,typeof v=="function"&&a.removeEventListener(s,v,g),typeof m=="function")){typeof v!="function"&&v!==null&&(u in a?a[u]=null:a.hasAttribute(u)&&a.removeAttribute(u)),a.addEventListener(s,m,g);break e}u in a?a[u]=m:m===!0?a.setAttribute(u,""):mf(a,u,m)}}}function on(a,s,u){switch(s){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":Ve("error",a),Ve("load",a);var m=!1,g=!1,v;for(v in u)if(u.hasOwnProperty(v)){var C=u[v];if(C!=null)switch(v){case"src":m=!0;break;case"srcSet":g=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(r(137,s));default:st(a,s,v,C,u,null)}}g&&st(a,s,"srcSet",u.srcSet,u,null),m&&st(a,s,"src",u.src,u,null);return;case"input":Ve("invalid",a);var k=v=C=g=null,I=null,Z=null;for(m in u)if(u.hasOwnProperty(m)){var ne=u[m];if(ne!=null)switch(m){case"name":g=ne;break;case"type":C=ne;break;case"checked":I=ne;break;case"defaultChecked":Z=ne;break;case"value":v=ne;break;case"defaultValue":k=ne;break;case"children":case"dangerouslySetInnerHTML":if(ne!=null)throw Error(r(137,s));break;default:st(a,s,m,ne,u,null)}}wN(a,v,k,I,Z,C,g,!1);return;case"select":Ve("invalid",a),m=C=v=null;for(g in u)if(u.hasOwnProperty(g)&&(k=u[g],k!=null))switch(g){case"value":v=k;break;case"defaultValue":C=k;break;case"multiple":m=k;default:st(a,s,g,k,u,null)}s=v,u=C,a.multiple=!!m,s!=null?Bs(a,!!m,s,!1):u!=null&&Bs(a,!!m,u,!0);return;case"textarea":Ve("invalid",a),v=g=m=null;for(C in u)if(u.hasOwnProperty(C)&&(k=u[C],k!=null))switch(C){case"value":m=k;break;case"defaultValue":g=k;break;case"children":v=k;break;case"dangerouslySetInnerHTML":if(k!=null)throw Error(r(91));break;default:st(a,s,C,k,u,null)}NN(a,m,g,v);return;case"option":for(I in u)if(u.hasOwnProperty(I)&&(m=u[I],m!=null))switch(I){case"selected":a.selected=m&&typeof m!="function"&&typeof m!="symbol";break;default:st(a,s,I,m,u,null)}return;case"dialog":Ve("beforetoggle",a),Ve("toggle",a),Ve("cancel",a),Ve("close",a);break;case"iframe":case"object":Ve("load",a);break;case"video":case"audio":for(m=0;m<mc.length;m++)Ve(mc[m],a);break;case"image":Ve("error",a),Ve("load",a);break;case"details":Ve("toggle",a);break;case"embed":case"source":case"link":Ve("error",a),Ve("load",a);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(Z in u)if(u.hasOwnProperty(Z)&&(m=u[Z],m!=null))switch(Z){case"children":case"dangerouslySetInnerHTML":throw Error(r(137,s));default:st(a,s,Z,m,u,null)}return;default:if(Cp(s)){for(ne in u)u.hasOwnProperty(ne)&&(m=u[ne],m!==void 0&&yx(a,s,ne,m,u,void 0));return}}for(k in u)u.hasOwnProperty(k)&&(m=u[k],m!=null&&st(a,s,k,m,u,null))}function U$(a,s,u,m){switch(s){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var g=null,v=null,C=null,k=null,I=null,Z=null,ne=null;for(te in u){var oe=u[te];if(u.hasOwnProperty(te)&&oe!=null)switch(te){case"checked":break;case"value":break;case"defaultValue":I=oe;default:m.hasOwnProperty(te)||st(a,s,te,null,m,oe)}}for(var J in m){var te=m[J];if(oe=u[J],m.hasOwnProperty(J)&&(te!=null||oe!=null))switch(J){case"type":v=te;break;case"name":g=te;break;case"checked":Z=te;break;case"defaultChecked":ne=te;break;case"value":C=te;break;case"defaultValue":k=te;break;case"children":case"dangerouslySetInnerHTML":if(te!=null)throw Error(r(137,s));break;default:te!==oe&&st(a,s,J,te,m,oe)}}Tp(a,C,k,I,Z,ne,v,g);return;case"select":te=C=k=J=null;for(v in u)if(I=u[v],u.hasOwnProperty(v)&&I!=null)switch(v){case"value":break;case"multiple":te=I;default:m.hasOwnProperty(v)||st(a,s,v,null,m,I)}for(g in m)if(v=m[g],I=u[g],m.hasOwnProperty(g)&&(v!=null||I!=null))switch(g){case"value":J=v;break;case"defaultValue":k=v;break;case"multiple":C=v;default:v!==I&&st(a,s,g,v,m,I)}s=k,u=C,m=te,J!=null?Bs(a,!!u,J,!1):!!m!=!!u&&(s!=null?Bs(a,!!u,s,!0):Bs(a,!!u,u?[]:"",!1));return;case"textarea":te=J=null;for(k in u)if(g=u[k],u.hasOwnProperty(k)&&g!=null&&!m.hasOwnProperty(k))switch(k){case"value":break;case"children":break;default:st(a,s,k,null,m,g)}for(C in m)if(g=m[C],v=u[C],m.hasOwnProperty(C)&&(g!=null||v!=null))switch(C){case"value":J=g;break;case"defaultValue":te=g;break;case"children":break;case"dangerouslySetInnerHTML":if(g!=null)throw Error(r(91));break;default:g!==v&&st(a,s,C,g,m,v)}SN(a,J,te);return;case"option":for(var pe in u)if(J=u[pe],u.hasOwnProperty(pe)&&J!=null&&!m.hasOwnProperty(pe))switch(pe){case"selected":a.selected=!1;break;default:st(a,s,pe,null,m,J)}for(I in m)if(J=m[I],te=u[I],m.hasOwnProperty(I)&&J!==te&&(J!=null||te!=null))switch(I){case"selected":a.selected=J&&typeof J!="function"&&typeof J!="symbol";break;default:st(a,s,I,J,m,te)}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 Oe in u)J=u[Oe],u.hasOwnProperty(Oe)&&J!=null&&!m.hasOwnProperty(Oe)&&st(a,s,Oe,null,m,J);for(Z in m)if(J=m[Z],te=u[Z],m.hasOwnProperty(Z)&&J!==te&&(J!=null||te!=null))switch(Z){case"children":case"dangerouslySetInnerHTML":if(J!=null)throw Error(r(137,s));break;default:st(a,s,Z,J,m,te)}return;default:if(Cp(s)){for(var ot in u)J=u[ot],u.hasOwnProperty(ot)&&J!==void 0&&!m.hasOwnProperty(ot)&&yx(a,s,ot,void 0,m,J);for(ne in m)J=m[ne],te=u[ne],!m.hasOwnProperty(ne)||J===te||J===void 0&&te===void 0||yx(a,s,ne,J,m,te);return}}for(var K in u)J=u[K],u.hasOwnProperty(K)&&J!=null&&!m.hasOwnProperty(K)&&st(a,s,K,null,m,J);for(oe in m)J=m[oe],te=u[oe],!m.hasOwnProperty(oe)||J===te||J==null&&te==null||st(a,s,oe,J,m,te)}function _O(a){switch(a){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function V$(){if(typeof performance.getEntriesByType=="function"){for(var a=0,s=0,u=performance.getEntriesByType("resource"),m=0;m<u.length;m++){var g=u[m],v=g.transferSize,C=g.initiatorType,k=g.duration;if(v&&k&&_O(C)){for(C=0,k=g.responseEnd,m+=1;m<u.length;m++){var I=u[m],Z=I.startTime;if(Z>k)break;var ne=I.transferSize,oe=I.initiatorType;ne&&_O(oe)&&(I=I.responseEnd,C+=ne*(I<k?1:(k-Z)/(I-Z)))}if(--m,s+=8*(v+C)/(g.duration/1e3),a++,10<a)break}}if(0<a)return s/a/1e6}return navigator.connection&&(a=navigator.connection.downlink,typeof a=="number")?a:5}var xx=null,gx=null;function dd(a){return a.nodeType===9?a:a.ownerDocument}function TO(a){switch(a){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function EO(a,s){if(a===0)switch(s){case"svg":return 1;case"math":return 2;default:return 0}return a===1&&s==="foreignObject"?0:a}function vx(a,s){return a==="textarea"||a==="noscript"||typeof s.children=="string"||typeof s.children=="number"||typeof s.children=="bigint"||typeof s.dangerouslySetInnerHTML=="object"&&s.dangerouslySetInnerHTML!==null&&s.dangerouslySetInnerHTML.__html!=null}var bx=null;function H$(){var a=window.event;return a&&a.type==="popstate"?a===bx?!1:(bx=a,!0):(bx=null,!1)}var CO=typeof setTimeout=="function"?setTimeout:void 0,F$=typeof clearTimeout=="function"?clearTimeout:void 0,MO=typeof Promise=="function"?Promise:void 0,G$=typeof queueMicrotask=="function"?queueMicrotask:typeof MO<"u"?function(a){return MO.resolve(null).then(a).catch(K$)}:CO;function K$(a){setTimeout(function(){throw a})}function mi(a){return a==="head"}function PO(a,s){var u=s,m=0;do{var g=u.nextSibling;if(a.removeChild(u),g&&g.nodeType===8)if(u=g.data,u==="/$"||u==="/&"){if(m===0){a.removeChild(g),go(s);return}m--}else if(u==="$"||u==="$?"||u==="$~"||u==="$!"||u==="&")m++;else if(u==="html")yc(a.ownerDocument.documentElement);else if(u==="head"){u=a.ownerDocument.head,yc(u);for(var v=u.firstChild;v;){var C=v.nextSibling,k=v.nodeName;v[kl]||k==="SCRIPT"||k==="STYLE"||k==="LINK"&&v.rel.toLowerCase()==="stylesheet"||u.removeChild(v),v=C}}else u==="body"&&yc(a.ownerDocument.body);u=g}while(u);go(s)}function RO(a,s){var u=a;a=0;do{var m=u.nextSibling;if(u.nodeType===1?s?(u._stashedDisplay=u.style.display,u.style.display="none"):(u.style.display=u._stashedDisplay||"",u.getAttribute("style")===""&&u.removeAttribute("style")):u.nodeType===3&&(s?(u._stashedText=u.nodeValue,u.nodeValue=""):u.nodeValue=u._stashedText||""),m&&m.nodeType===8)if(u=m.data,u==="/$"){if(a===0)break;a--}else u!=="$"&&u!=="$?"&&u!=="$~"&&u!=="$!"||a++;u=m}while(u)}function jx(a){var s=a.firstChild;for(s&&s.nodeType===10&&(s=s.nextSibling);s;){var u=s;switch(s=s.nextSibling,u.nodeName){case"HTML":case"HEAD":case"BODY":jx(u),Op(u);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(u.rel.toLowerCase()==="stylesheet")continue}a.removeChild(u)}}function Y$(a,s,u,m){for(;a.nodeType===1;){var g=u;if(a.nodeName.toLowerCase()!==s.toLowerCase()){if(!m&&(a.nodeName!=="INPUT"||a.type!=="hidden"))break}else if(m){if(!a[kl])switch(s){case"meta":if(!a.hasAttribute("itemprop"))break;return a;case"link":if(v=a.getAttribute("rel"),v==="stylesheet"&&a.hasAttribute("data-precedence"))break;if(v!==g.rel||a.getAttribute("href")!==(g.href==null||g.href===""?null:g.href)||a.getAttribute("crossorigin")!==(g.crossOrigin==null?null:g.crossOrigin)||a.getAttribute("title")!==(g.title==null?null:g.title))break;return a;case"style":if(a.hasAttribute("data-precedence"))break;return a;case"script":if(v=a.getAttribute("src"),(v!==(g.src==null?null:g.src)||a.getAttribute("type")!==(g.type==null?null:g.type)||a.getAttribute("crossorigin")!==(g.crossOrigin==null?null:g.crossOrigin))&&v&&a.hasAttribute("async")&&!a.hasAttribute("itemprop"))break;return a;default:return a}}else if(s==="input"&&a.type==="hidden"){var v=g.name==null?null:""+g.name;if(g.type==="hidden"&&a.getAttribute("name")===v)return a}else return a;if(a=lr(a.nextSibling),a===null)break}return null}function X$(a,s,u){if(s==="")return null;for(;a.nodeType!==3;)if((a.nodeType!==1||a.nodeName!=="INPUT"||a.type!=="hidden")&&!u||(a=lr(a.nextSibling),a===null))return null;return a}function kO(a,s){for(;a.nodeType!==8;)if((a.nodeType!==1||a.nodeName!=="INPUT"||a.type!=="hidden")&&!s||(a=lr(a.nextSibling),a===null))return null;return a}function wx(a){return a.data==="$?"||a.data==="$~"}function Sx(a){return a.data==="$!"||a.data==="$?"&&a.ownerDocument.readyState!=="loading"}function W$(a,s){var u=a.ownerDocument;if(a.data==="$~")a._reactRetry=s;else if(a.data!=="$?"||u.readyState!=="loading")s();else{var m=function(){s(),u.removeEventListener("DOMContentLoaded",m)};u.addEventListener("DOMContentLoaded",m),a._reactRetry=m}}function lr(a){for(;a!=null;a=a.nextSibling){var s=a.nodeType;if(s===1||s===3)break;if(s===8){if(s=a.data,s==="$"||s==="$!"||s==="$?"||s==="$~"||s==="&"||s==="F!"||s==="F")break;if(s==="/$"||s==="/&")return null}}return a}var Nx=null;function DO(a){a=a.nextSibling;for(var s=0;a;){if(a.nodeType===8){var u=a.data;if(u==="/$"||u==="/&"){if(s===0)return lr(a.nextSibling);s--}else u!=="$"&&u!=="$!"&&u!=="$?"&&u!=="$~"&&u!=="&"||s++}a=a.nextSibling}return null}function zO(a){a=a.previousSibling;for(var s=0;a;){if(a.nodeType===8){var u=a.data;if(u==="$"||u==="$!"||u==="$?"||u==="$~"||u==="&"){if(s===0)return a;s--}else u!=="/$"&&u!=="/&"||s++}a=a.previousSibling}return null}function LO(a,s,u){switch(s=dd(u),a){case"html":if(a=s.documentElement,!a)throw Error(r(452));return a;case"head":if(a=s.head,!a)throw Error(r(453));return a;case"body":if(a=s.body,!a)throw Error(r(454));return a;default:throw Error(r(451))}}function yc(a){for(var s=a.attributes;s.length;)a.removeAttributeNode(s[0]);Op(a)}var cr=new Map,$O=new Set;function hd(a){return typeof a.getRootNode=="function"?a.getRootNode():a.nodeType===9?a:a.ownerDocument}var Sa=G.d;G.d={f:Z$,r:Q$,D:J$,C:eB,L:tB,m:nB,X:aB,S:rB,M:iB};function Z$(){var a=Sa.f(),s=ad();return a||s}function Q$(a){var s=zs(a);s!==null&&s.tag===5&&s.type==="form"?t2(s):Sa.r(a)}var po=typeof document>"u"?null:document;function BO(a,s,u){var m=po;if(m&&typeof s=="string"&&s){var g=tr(s);g='link[rel="'+a+'"][href="'+g+'"]',typeof u=="string"&&(g+='[crossorigin="'+u+'"]'),$O.has(g)||($O.add(g),a={rel:a,crossOrigin:u,href:s},m.querySelector(g)===null&&(s=m.createElement("link"),on(s,"link",a),Zt(s),m.head.appendChild(s)))}}function J$(a){Sa.D(a),BO("dns-prefetch",a,null)}function eB(a,s){Sa.C(a,s),BO("preconnect",a,s)}function tB(a,s,u){Sa.L(a,s,u);var m=po;if(m&&a&&s){var g='link[rel="preload"][as="'+tr(s)+'"]';s==="image"&&u&&u.imageSrcSet?(g+='[imagesrcset="'+tr(u.imageSrcSet)+'"]',typeof u.imageSizes=="string"&&(g+='[imagesizes="'+tr(u.imageSizes)+'"]')):g+='[href="'+tr(a)+'"]';var v=g;switch(s){case"style":v=yo(a);break;case"script":v=xo(a)}cr.has(v)||(a=y({rel:"preload",href:s==="image"&&u&&u.imageSrcSet?void 0:a,as:s},u),cr.set(v,a),m.querySelector(g)!==null||s==="style"&&m.querySelector(xc(v))||s==="script"&&m.querySelector(gc(v))||(s=m.createElement("link"),on(s,"link",a),Zt(s),m.head.appendChild(s)))}}function nB(a,s){Sa.m(a,s);var u=po;if(u&&a){var m=s&&typeof s.as=="string"?s.as:"script",g='link[rel="modulepreload"][as="'+tr(m)+'"][href="'+tr(a)+'"]',v=g;switch(m){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":v=xo(a)}if(!cr.has(v)&&(a=y({rel:"modulepreload",href:a},s),cr.set(v,a),u.querySelector(g)===null)){switch(m){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(u.querySelector(gc(v)))return}m=u.createElement("link"),on(m,"link",a),Zt(m),u.head.appendChild(m)}}}function rB(a,s,u){Sa.S(a,s,u);var m=po;if(m&&a){var g=Ls(m).hoistableStyles,v=yo(a);s=s||"default";var C=g.get(v);if(!C){var k={loading:0,preload:null};if(C=m.querySelector(xc(v)))k.loading=5;else{a=y({rel:"stylesheet",href:a,"data-precedence":s},u),(u=cr.get(v))&&Ax(a,u);var I=C=m.createElement("link");Zt(I),on(I,"link",a),I._p=new Promise(function(Z,ne){I.onload=Z,I.onerror=ne}),I.addEventListener("load",function(){k.loading|=1}),I.addEventListener("error",function(){k.loading|=2}),k.loading|=4,md(C,s,m)}C={type:"stylesheet",instance:C,count:1,state:k},g.set(v,C)}}}function aB(a,s){Sa.X(a,s);var u=po;if(u&&a){var m=Ls(u).hoistableScripts,g=xo(a),v=m.get(g);v||(v=u.querySelector(gc(g)),v||(a=y({src:a,async:!0},s),(s=cr.get(g))&&Ox(a,s),v=u.createElement("script"),Zt(v),on(v,"link",a),u.head.appendChild(v)),v={type:"script",instance:v,count:1,state:null},m.set(g,v))}}function iB(a,s){Sa.M(a,s);var u=po;if(u&&a){var m=Ls(u).hoistableScripts,g=xo(a),v=m.get(g);v||(v=u.querySelector(gc(g)),v||(a=y({src:a,async:!0,type:"module"},s),(s=cr.get(g))&&Ox(a,s),v=u.createElement("script"),Zt(v),on(v,"link",a),u.head.appendChild(v)),v={type:"script",instance:v,count:1,state:null},m.set(g,v))}}function qO(a,s,u,m){var g=(g=Ae.current)?hd(g):null;if(!g)throw Error(r(446));switch(a){case"meta":case"title":return null;case"style":return typeof u.precedence=="string"&&typeof u.href=="string"?(s=yo(u.href),u=Ls(g).hoistableStyles,m=u.get(s),m||(m={type:"style",instance:null,count:0,state:null},u.set(s,m)),m):{type:"void",instance:null,count:0,state:null};case"link":if(u.rel==="stylesheet"&&typeof u.href=="string"&&typeof u.precedence=="string"){a=yo(u.href);var v=Ls(g).hoistableStyles,C=v.get(a);if(C||(g=g.ownerDocument||g,C={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},v.set(a,C),(v=g.querySelector(xc(a)))&&!v._p&&(C.instance=v,C.state.loading=5),cr.has(a)||(u={rel:"preload",as:"style",href:u.href,crossOrigin:u.crossOrigin,integrity:u.integrity,media:u.media,hrefLang:u.hrefLang,referrerPolicy:u.referrerPolicy},cr.set(a,u),v||sB(g,a,u,C.state))),s&&m===null)throw Error(r(528,""));return C}if(s&&m!==null)throw Error(r(529,""));return null;case"script":return s=u.async,u=u.src,typeof u=="string"&&s&&typeof s!="function"&&typeof s!="symbol"?(s=xo(u),u=Ls(g).hoistableScripts,m=u.get(s),m||(m={type:"script",instance:null,count:0,state:null},u.set(s,m)),m):{type:"void",instance:null,count:0,state:null};default:throw Error(r(444,a))}}function yo(a){return'href="'+tr(a)+'"'}function xc(a){return'link[rel="stylesheet"]['+a+"]"}function IO(a){return y({},a,{"data-precedence":a.precedence,precedence:null})}function sB(a,s,u,m){a.querySelector('link[rel="preload"][as="style"]['+s+"]")?m.loading=1:(s=a.createElement("link"),m.preload=s,s.addEventListener("load",function(){return m.loading|=1}),s.addEventListener("error",function(){return m.loading|=2}),on(s,"link",u),Zt(s),a.head.appendChild(s))}function xo(a){return'[src="'+tr(a)+'"]'}function gc(a){return"script[async]"+a}function UO(a,s,u){if(s.count++,s.instance===null)switch(s.type){case"style":var m=a.querySelector('style[data-href~="'+tr(u.href)+'"]');if(m)return s.instance=m,Zt(m),m;var g=y({},u,{"data-href":u.href,"data-precedence":u.precedence,href:null,precedence:null});return m=(a.ownerDocument||a).createElement("style"),Zt(m),on(m,"style",g),md(m,u.precedence,a),s.instance=m;case"stylesheet":g=yo(u.href);var v=a.querySelector(xc(g));if(v)return s.state.loading|=4,s.instance=v,Zt(v),v;m=IO(u),(g=cr.get(g))&&Ax(m,g),v=(a.ownerDocument||a).createElement("link"),Zt(v);var C=v;return C._p=new Promise(function(k,I){C.onload=k,C.onerror=I}),on(v,"link",m),s.state.loading|=4,md(v,u.precedence,a),s.instance=v;case"script":return v=xo(u.src),(g=a.querySelector(gc(v)))?(s.instance=g,Zt(g),g):(m=u,(g=cr.get(v))&&(m=y({},u),Ox(m,g)),a=a.ownerDocument||a,g=a.createElement("script"),Zt(g),on(g,"link",m),a.head.appendChild(g),s.instance=g);case"void":return null;default:throw Error(r(443,s.type))}else s.type==="stylesheet"&&(s.state.loading&4)===0&&(m=s.instance,s.state.loading|=4,md(m,u.precedence,a));return s.instance}function md(a,s,u){for(var m=u.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),g=m.length?m[m.length-1]:null,v=g,C=0;C<m.length;C++){var k=m[C];if(k.dataset.precedence===s)v=k;else if(v!==g)break}v?v.parentNode.insertBefore(a,v.nextSibling):(s=u.nodeType===9?u.head:u,s.insertBefore(a,s.firstChild))}function Ax(a,s){a.crossOrigin==null&&(a.crossOrigin=s.crossOrigin),a.referrerPolicy==null&&(a.referrerPolicy=s.referrerPolicy),a.title==null&&(a.title=s.title)}function Ox(a,s){a.crossOrigin==null&&(a.crossOrigin=s.crossOrigin),a.referrerPolicy==null&&(a.referrerPolicy=s.referrerPolicy),a.integrity==null&&(a.integrity=s.integrity)}var pd=null;function VO(a,s,u){if(pd===null){var m=new Map,g=pd=new Map;g.set(u,m)}else g=pd,m=g.get(u),m||(m=new Map,g.set(u,m));if(m.has(a))return m;for(m.set(a,null),u=u.getElementsByTagName(a),g=0;g<u.length;g++){var v=u[g];if(!(v[kl]||v[nn]||a==="link"&&v.getAttribute("rel")==="stylesheet")&&v.namespaceURI!=="http://www.w3.org/2000/svg"){var C=v.getAttribute(s)||"";C=a+C;var k=m.get(C);k?k.push(v):m.set(C,[v])}}return m}function HO(a,s,u){a=a.ownerDocument||a,a.head.insertBefore(u,s==="title"?a.querySelector("head > title"):null)}function oB(a,s,u){if(u===1||s.itemProp!=null)return!1;switch(a){case"meta":case"title":return!0;case"style":if(typeof s.precedence!="string"||typeof s.href!="string"||s.href==="")break;return!0;case"link":if(typeof s.rel!="string"||typeof s.href!="string"||s.href===""||s.onLoad||s.onError)break;switch(s.rel){case"stylesheet":return a=s.disabled,typeof s.precedence=="string"&&a==null;default:return!0}case"script":if(s.async&&typeof s.async!="function"&&typeof s.async!="symbol"&&!s.onLoad&&!s.onError&&s.src&&typeof s.src=="string")return!0}return!1}function FO(a){return!(a.type==="stylesheet"&&(a.state.loading&3)===0)}function lB(a,s,u,m){if(u.type==="stylesheet"&&(typeof m.media!="string"||matchMedia(m.media).matches!==!1)&&(u.state.loading&4)===0){if(u.instance===null){var g=yo(m.href),v=s.querySelector(xc(g));if(v){s=v._p,s!==null&&typeof s=="object"&&typeof s.then=="function"&&(a.count++,a=yd.bind(a),s.then(a,a)),u.state.loading|=4,u.instance=v,Zt(v);return}v=s.ownerDocument||s,m=IO(m),(g=cr.get(g))&&Ax(m,g),v=v.createElement("link"),Zt(v);var C=v;C._p=new Promise(function(k,I){C.onload=k,C.onerror=I}),on(v,"link",m),u.instance=v}a.stylesheets===null&&(a.stylesheets=new Map),a.stylesheets.set(u,s),(s=u.state.preload)&&(u.state.loading&3)===0&&(a.count++,u=yd.bind(a),s.addEventListener("load",u),s.addEventListener("error",u))}}var _x=0;function cB(a,s){return a.stylesheets&&a.count===0&&gd(a,a.stylesheets),0<a.count||0<a.imgCount?function(u){var m=setTimeout(function(){if(a.stylesheets&&gd(a,a.stylesheets),a.unsuspend){var v=a.unsuspend;a.unsuspend=null,v()}},6e4+s);0<a.imgBytes&&_x===0&&(_x=62500*V$());var g=setTimeout(function(){if(a.waitingForImages=!1,a.count===0&&(a.stylesheets&&gd(a,a.stylesheets),a.unsuspend)){var v=a.unsuspend;a.unsuspend=null,v()}},(a.imgBytes>_x?50:800)+s);return a.unsuspend=u,function(){a.unsuspend=null,clearTimeout(m),clearTimeout(g)}}:null}function yd(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)gd(this,this.stylesheets);else if(this.unsuspend){var a=this.unsuspend;this.unsuspend=null,a()}}}var xd=null;function gd(a,s){a.stylesheets=null,a.unsuspend!==null&&(a.count++,xd=new Map,s.forEach(uB,a),xd=null,yd.call(a))}function uB(a,s){if(!(s.state.loading&4)){var u=xd.get(a);if(u)var m=u.get(null);else{u=new Map,xd.set(a,u);for(var g=a.querySelectorAll("link[data-precedence],style[data-precedence]"),v=0;v<g.length;v++){var C=g[v];(C.nodeName==="LINK"||C.getAttribute("media")!=="not all")&&(u.set(C.dataset.precedence,C),m=C)}m&&u.set(null,m)}g=s.instance,C=g.getAttribute("data-precedence"),v=u.get(C)||m,v===m&&u.set(null,g),u.set(C,g),this.count++,m=yd.bind(this),g.addEventListener("load",m),g.addEventListener("error",m),v?v.parentNode.insertBefore(g,v.nextSibling):(a=a.nodeType===9?a.head:a,a.insertBefore(g,a.firstChild)),s.state.loading|=4}}var vc={$$typeof:O,Provider:null,Consumer:null,_currentValue:Q,_currentValue2:Q,_threadCount:0};function fB(a,s,u,m,g,v,C,k,I){this.tag=1,this.containerInfo=a,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=wp(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=wp(0),this.hiddenUpdates=wp(null),this.identifierPrefix=m,this.onUncaughtError=g,this.onCaughtError=v,this.onRecoverableError=C,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=I,this.incompleteTransitions=new Map}function GO(a,s,u,m,g,v,C,k,I,Z,ne,oe){return a=new fB(a,s,u,C,I,Z,ne,oe,k),s=1,v===!0&&(s|=24),v=Ln(3,null,null,s),a.current=v,v.stateNode=a,s=sy(),s.refCount++,a.pooledCache=s,s.refCount++,v.memoizedState={element:m,isDehydrated:u,cache:s},uy(v),a}function KO(a){return a?(a=Ks,a):Ks}function YO(a,s,u,m,g,v){g=KO(g),m.context===null?m.context=g:m.pendingContext=g,m=ri(s),m.payload={element:u},v=v===void 0?null:v,v!==null&&(m.callback=v),u=ai(a,m,s),u!==null&&(Cn(u,a,s),Zl(u,a,s))}function XO(a,s){if(a=a.memoizedState,a!==null&&a.dehydrated!==null){var u=a.retryLane;a.retryLane=u!==0&&u<s?u:s}}function Tx(a,s){XO(a,s),(a=a.alternate)&&XO(a,s)}function WO(a){if(a.tag===13||a.tag===31){var s=Vi(a,67108864);s!==null&&Cn(s,a,67108864),Tx(a,67108864)}}function ZO(a){if(a.tag===13||a.tag===31){var s=Un();s=Sp(s);var u=Vi(a,s);u!==null&&Cn(u,a,s),Tx(a,s)}}var vd=!0;function dB(a,s,u,m){var g=$.T;$.T=null;var v=G.p;try{G.p=2,Ex(a,s,u,m)}finally{G.p=v,$.T=g}}function hB(a,s,u,m){var g=$.T;$.T=null;var v=G.p;try{G.p=8,Ex(a,s,u,m)}finally{G.p=v,$.T=g}}function Ex(a,s,u,m){if(vd){var g=Cx(m);if(g===null)px(a,s,m,bd,u),JO(a,m);else if(pB(g,a,s,u,m))m.stopPropagation();else if(JO(a,m),s&4&&-1<mB.indexOf(a)){for(;g!==null;){var v=zs(g);if(v!==null)switch(v.tag){case 3:if(v=v.stateNode,v.current.memoizedState.isDehydrated){var C=$i(v.pendingLanes);if(C!==0){var k=v;for(k.pendingLanes|=2,k.entangledLanes|=2;C;){var I=1<<31-Dn(C);k.entanglements[1]|=I,C&=~I}Hr(v),(Ze&6)===0&&(nd=dn()+500,hc(0))}}break;case 31:case 13:k=Vi(v,2),k!==null&&Cn(k,v,2),ad(),Tx(v,2)}if(v=Cx(m),v===null&&px(a,s,m,bd,u),v===g)break;g=v}g!==null&&m.stopPropagation()}else px(a,s,m,null,u)}}function Cx(a){return a=Pp(a),Mx(a)}var bd=null;function Mx(a){if(bd=null,a=Ds(a),a!==null){var s=o(a);if(s===null)a=null;else{var u=s.tag;if(u===13){if(a=c(s),a!==null)return a;a=null}else if(u===31){if(a=f(s),a!==null)return a;a=null}else if(u===3){if(s.stateNode.current.memoizedState.isDehydrated)return s.tag===3?s.stateNode.containerInfo:null;a=null}else s!==a&&(a=null)}}return bd=a,null}function QO(a){switch(a){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(lf()){case sN:return 2;case oN:return 8;case cf:case e8:return 32;case lN:return 268435456;default:return 32}default:return 32}}var Px=!1,pi=null,yi=null,xi=null,bc=new Map,jc=new Map,gi=[],mB="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 JO(a,s){switch(a){case"focusin":case"focusout":pi=null;break;case"dragenter":case"dragleave":yi=null;break;case"mouseover":case"mouseout":xi=null;break;case"pointerover":case"pointerout":bc.delete(s.pointerId);break;case"gotpointercapture":case"lostpointercapture":jc.delete(s.pointerId)}}function wc(a,s,u,m,g,v){return a===null||a.nativeEvent!==v?(a={blockedOn:s,domEventName:u,eventSystemFlags:m,nativeEvent:v,targetContainers:[g]},s!==null&&(s=zs(s),s!==null&&WO(s)),a):(a.eventSystemFlags|=m,s=a.targetContainers,g!==null&&s.indexOf(g)===-1&&s.push(g),a)}function pB(a,s,u,m,g){switch(s){case"focusin":return pi=wc(pi,a,s,u,m,g),!0;case"dragenter":return yi=wc(yi,a,s,u,m,g),!0;case"mouseover":return xi=wc(xi,a,s,u,m,g),!0;case"pointerover":var v=g.pointerId;return bc.set(v,wc(bc.get(v)||null,a,s,u,m,g)),!0;case"gotpointercapture":return v=g.pointerId,jc.set(v,wc(jc.get(v)||null,a,s,u,m,g)),!0}return!1}function e_(a){var s=Ds(a.target);if(s!==null){var u=o(s);if(u!==null){if(s=u.tag,s===13){if(s=c(u),s!==null){a.blockedOn=s,mN(a.priority,function(){ZO(u)});return}}else if(s===31){if(s=f(u),s!==null){a.blockedOn=s,mN(a.priority,function(){ZO(u)});return}}else if(s===3&&u.stateNode.current.memoizedState.isDehydrated){a.blockedOn=u.tag===3?u.stateNode.containerInfo:null;return}}}a.blockedOn=null}function jd(a){if(a.blockedOn!==null)return!1;for(var s=a.targetContainers;0<s.length;){var u=Cx(a.nativeEvent);if(u===null){u=a.nativeEvent;var m=new u.constructor(u.type,u);Mp=m,u.target.dispatchEvent(m),Mp=null}else return s=zs(u),s!==null&&WO(s),a.blockedOn=u,!1;s.shift()}return!0}function t_(a,s,u){jd(a)&&u.delete(s)}function yB(){Px=!1,pi!==null&&jd(pi)&&(pi=null),yi!==null&&jd(yi)&&(yi=null),xi!==null&&jd(xi)&&(xi=null),bc.forEach(t_),jc.forEach(t_)}function wd(a,s){a.blockedOn===s&&(a.blockedOn=null,Px||(Px=!0,e.unstable_scheduleCallback(e.unstable_NormalPriority,yB)))}var Sd=null;function n_(a){Sd!==a&&(Sd=a,e.unstable_scheduleCallback(e.unstable_NormalPriority,function(){Sd===a&&(Sd=null);for(var s=0;s<a.length;s+=3){var u=a[s],m=a[s+1],g=a[s+2];if(typeof m!="function"){if(Mx(m||u)===null)continue;break}var v=zs(u);v!==null&&(a.splice(s,3),s-=3,Cy(v,{pending:!0,data:g,method:u.method,action:m},m,g))}}))}function go(a){function s(I){return wd(I,a)}pi!==null&&wd(pi,a),yi!==null&&wd(yi,a),xi!==null&&wd(xi,a),bc.forEach(s),jc.forEach(s);for(var u=0;u<gi.length;u++){var m=gi[u];m.blockedOn===a&&(m.blockedOn=null)}for(;0<gi.length&&(u=gi[0],u.blockedOn===null);)e_(u),u.blockedOn===null&&gi.shift();if(u=(a.ownerDocument||a).$$reactFormReplay,u!=null)for(m=0;m<u.length;m+=3){var g=u[m],v=u[m+1],C=g[Nn]||null;if(typeof v=="function")C||n_(u);else if(C){var k=null;if(v&&v.hasAttribute("formAction")){if(g=v,C=v[Nn]||null)k=C.formAction;else if(Mx(g)!==null)continue}else k=C.action;typeof k=="function"?u[m+1]=k:(u.splice(m,3),m-=3),n_(u)}}}function r_(){function a(v){v.canIntercept&&v.info==="react-transition"&&v.intercept({handler:function(){return new Promise(function(C){return g=C})},focusReset:"manual",scroll:"manual"})}function s(){g!==null&&(g(),g=null),m||setTimeout(u,20)}function u(){if(!m&&!navigation.transition){var v=navigation.currentEntry;v&&v.url!=null&&navigation.navigate(v.url,{state:v.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var m=!1,g=null;return navigation.addEventListener("navigate",a),navigation.addEventListener("navigatesuccess",s),navigation.addEventListener("navigateerror",s),setTimeout(u,100),function(){m=!0,navigation.removeEventListener("navigate",a),navigation.removeEventListener("navigatesuccess",s),navigation.removeEventListener("navigateerror",s),g!==null&&(g(),g=null)}}}function Rx(a){this._internalRoot=a}Nd.prototype.render=Rx.prototype.render=function(a){var s=this._internalRoot;if(s===null)throw Error(r(409));var u=s.current,m=Un();YO(u,m,a,s,null,null)},Nd.prototype.unmount=Rx.prototype.unmount=function(){var a=this._internalRoot;if(a!==null){this._internalRoot=null;var s=a.containerInfo;YO(a.current,2,null,a,null,null),ad(),s[ks]=null}};function Nd(a){this._internalRoot=a}Nd.prototype.unstable_scheduleHydration=function(a){if(a){var s=hN();a={blockedOn:null,target:a,priority:s};for(var u=0;u<gi.length&&s!==0&&s<gi[u].priority;u++);gi.splice(u,0,a),u===0&&e_(a)}};var a_=t.version;if(a_!=="19.2.7")throw Error(r(527,a_,"19.2.7"));G.findDOMNode=function(a){var s=a._reactInternals;if(s===void 0)throw typeof a.render=="function"?Error(r(188)):(a=Object.keys(a).join(","),Error(r(268,a)));return a=h(s),a=a!==null?p(a):null,a=a===null?null:a.stateNode,a};var xB={bundleType:0,version:"19.2.7",rendererPackageName:"react-dom",currentDispatcherRef:$,reconcilerVersion:"19.2.7"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Ad=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Ad.isDisabled&&Ad.supportsFiber)try{Ml=Ad.inject(xB),kn=Ad}catch{}}return Nc.createRoot=function(a,s){if(!i(a))throw Error(r(299));var u=!1,m="",g=f2,v=d2,C=h2;return s!=null&&(s.unstable_strictMode===!0&&(u=!0),s.identifierPrefix!==void 0&&(m=s.identifierPrefix),s.onUncaughtError!==void 0&&(g=s.onUncaughtError),s.onCaughtError!==void 0&&(v=s.onCaughtError),s.onRecoverableError!==void 0&&(C=s.onRecoverableError)),s=GO(a,1,!1,null,null,u,m,null,g,v,C,r_),a[ks]=s.current,mx(a),new Rx(s)},Nc.hydrateRoot=function(a,s,u){if(!i(a))throw Error(r(299));var m=!1,g="",v=f2,C=d2,k=h2,I=null;return u!=null&&(u.unstable_strictMode===!0&&(m=!0),u.identifierPrefix!==void 0&&(g=u.identifierPrefix),u.onUncaughtError!==void 0&&(v=u.onUncaughtError),u.onCaughtError!==void 0&&(C=u.onCaughtError),u.onRecoverableError!==void 0&&(k=u.onRecoverableError),u.formState!==void 0&&(I=u.formState)),s=GO(a,1,!0,s,u??null,m,g,I,v,C,k,r_),s.context=KO(null),u=s.current,m=Un(),m=Sp(m),g=ri(m),g.callback=null,ai(u,g,m),u=m,s.current.lanes=u,Rl(s,u),Hr(s),a[ks]=s.current,mx(a),new Nd(s)},Nc.version="19.2.7",Nc}var m_;function _B(){if(m_)return zx.exports;m_=1;function e(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}return e(),zx.exports=OB(),zx.exports}var TB=_B();/**
|
||
* react-router v7.18.1
|
||
*
|
||
* Copyright (c) Remix Software Inc.
|
||
*
|
||
* This source code is licensed under the MIT license found in the
|
||
* LICENSE.md file in the root directory of this source tree.
|
||
*
|
||
* @license MIT
|
||
*/var pw=/^(?:[a-z][a-z0-9+.-]*:|[\\/]{2})/i,sD=/^[\\/]{2}/;function EB(e,t){return t+e.replace(/\\/g,"/")}var p_="popstate";function y_(e){return typeof e=="object"&&e!=null&&"pathname"in e&&"search"in e&&"hash"in e&&"state"in e&&"key"in e}function CB(e={}){function t(r,i){var h;let o=(h=i.state)==null?void 0:h.masked,{pathname:c,search:f,hash:d}=o||r.location;return f1("",{pathname:c,search:f,hash:d},i.state&&i.state.usr||null,i.state&&i.state.key||"default",o?{pathname:r.location.pathname,search:r.location.search,hash:r.location.hash}:void 0)}function n(r,i){return typeof i=="string"?i:nu(i)}return PB(t,n,null,e)}function Ot(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function gr(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function MB(){return Math.random().toString(36).substring(2,10)}function x_(e,t){return{usr:e.state,key:e.key,idx:t,masked:e.mask?{pathname:e.pathname,search:e.search,hash:e.hash}:void 0}}function f1(e,t,n=null,r,i){return{pathname:typeof e=="string"?e:e.pathname,search:"",hash:"",...typeof t=="string"?pl(t):t,state:n,key:t&&t.key||r||MB(),mask:i}}function nu({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 pl(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 PB(e,t,n,r={}){let{window:i=document.defaultView,v5Compat:o=!1}=r,c=i.history,f="POP",d=null,h=p();h==null&&(h=0,c.replaceState({...c.state,idx:h},""));function p(){return(c.state||{idx:null}).idx}function y(){f="POP";let b=p(),A=b==null?null:b-h;h=b,d&&d({action:f,location:S.location,delta:A})}function x(b,A){f="PUSH";let _=y_(b)?b:f1(S.location,b,A);h=p()+1;let O=x_(_,h),T=S.createHref(_.mask||_);try{c.pushState(O,"",T)}catch(N){if(N instanceof DOMException&&N.name==="DataCloneError")throw N;i.location.assign(T)}o&&d&&d({action:f,location:S.location,delta:1})}function j(b,A){f="REPLACE";let _=y_(b)?b:f1(S.location,b,A);h=p();let O=x_(_,h),T=S.createHref(_.mask||_);c.replaceState(O,"",T),o&&d&&d({action:f,location:S.location,delta:0})}function w(b){return RB(i,b)}let S={get action(){return f},get location(){return e(i,c)},listen(b){if(d)throw new Error("A history only accepts one active listener");return i.addEventListener(p_,y),d=b,()=>{i.removeEventListener(p_,y),d=null}},createHref(b){return t(i,b)},createURL:w,encodeLocation(b){let A=w(b);return{pathname:A.pathname,search:A.search,hash:A.hash}},push:x,replace:j,go(b){return c.go(b)}};return S}function RB(e,t,n=!1){let r="http://localhost";e&&(r=e.location.origin!=="null"?e.location.origin:e.location.href),Ot(r,"No window.location.(origin|href) available to create URL");let i=typeof t=="string"?t:nu(t);return i=i.replace(/ $/,"%20"),!n&&sD.test(i)&&(i=r+i),new URL(i,r)}function oD(e,t,n="/"){return kB(e,t,n,!1)}function kB(e,t,n,r,i){let o=typeof t=="string"?pl(t):t,c=Da(o.pathname||"/",n);if(c==null)return null;let f=DB(e),d=null,h=GB(c);for(let p=0;d==null&&p<f.length;++p)d=FB(f[p],h,r);return d}function DB(e){let t=lD(e);return zB(t),t}function lD(e,t=[],n=[],r="",i=!1){let o=(c,f,d=i,h)=>{let p={relativePath:h===void 0?c.path||"":h,caseSensitive:c.caseSensitive===!0,childrenIndex:f,route:c};if(p.relativePath.startsWith("/")){if(!p.relativePath.startsWith(r)&&d)return;Ot(p.relativePath.startsWith(r),`Absolute route path "${p.relativePath}" nested under path "${r}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),p.relativePath=p.relativePath.slice(r.length)}let y=Rr([r,p.relativePath]),x=n.concat(p);c.children&&c.children.length>0&&(Ot(c.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${y}".`),lD(c.children,t,x,y,d)),!(c.path==null&&!c.index)&&t.push({path:y,score:VB(y,c.index),routesMeta:x.map((j,w)=>{let[S,b]=fD(j.relativePath,j.caseSensitive,w===x.length-1);return{...j,matcher:S,compiledParams:b}})})};return e.forEach((c,f)=>{var d;if(c.path===""||!((d=c.path)!=null&&d.includes("?")))o(c,f);else for(let h of cD(c.path))o(c,f,!0,h)}),t}function cD(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,i=n.endsWith("?"),o=n.replace(/\?$/,"");if(r.length===0)return i?[o,""]:[o];let c=cD(r.join("/")),f=[];return f.push(...c.map(d=>d===""?o:[o,d].join("/"))),i&&f.push(...c),f.map(d=>e.startsWith("/")&&d===""?"/":d)}function zB(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:HB(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}var LB=/^:[\w-]+$/,$B=3,BB=2,qB=1,IB=10,UB=-2,g_=e=>e==="*";function VB(e,t){let n=e.split("/"),r=n.length;return n.some(g_)&&(r+=UB),t&&(r+=BB),n.filter(i=>!g_(i)).reduce((i,o)=>i+(LB.test(o)?$B:o===""?qB:IB),r)}function HB(e,t){return e.length===t.length&&e.slice(0,-1).every((r,i)=>r===t[i])?e[e.length-1]-t[t.length-1]:0}function FB(e,t,n=!1){let{routesMeta:r}=e,i={},o="/",c=[];for(let f=0;f<r.length;++f){let d=r[f],h=f===r.length-1,p=o==="/"?t:t.slice(o.length)||"/",y={path:d.relativePath,caseSensitive:d.caseSensitive,end:h},x=d.matcher&&d.compiledParams?uD(y,p,d.matcher,d.compiledParams):hh(y,p),j=d.route;if(!x&&h&&n&&!r[r.length-1].route.index&&(x=hh({path:d.relativePath,caseSensitive:d.caseSensitive,end:!1},p)),!x)return null;Object.assign(i,x.params),c.push({params:i,pathname:Rr([o,x.pathname]),pathnameBase:XB(Rr([o,x.pathnameBase])),route:j}),x.pathnameBase!=="/"&&(o=Rr([o,x.pathnameBase]))}return c}function hh(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=fD(e.path,e.caseSensitive,e.end);return uD(e,t,n,r)}function uD(e,t,n,r){let i=t.match(n);if(!i)return null;let o=i[0],c=o.replace(/(.)\/+$/,"$1"),f=i.slice(1);return{params:r.reduce((h,{paramName:p,isOptional:y},x)=>{if(p==="*"){let w=f[x]||"";c=o.slice(0,o.length-w.length).replace(/(.)\/+$/,"$1")}const j=f[x];return y&&!j?h[p]=void 0:h[p]=(j||"").replace(/%2F/g,"/"),h},{}),pathname:o,pathnameBase:c,pattern:e}}function fD(e,t=!1,n=!0){gr(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,(c,f,d,h,p)=>{if(r.push({paramName:f,isOptional:d!=null}),d){let y=p.charAt(h+c.length);return y&&y!=="/"?"/([^\\/]*)":"(?:/([^\\/]*))?"}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 GB(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return gr(!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 Da(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 KB(e,t="/"){let{pathname:n,search:r="",hash:i=""}=typeof e=="string"?pl(e):e,o;return n?(n=dD(n),n.startsWith("/")?o=v_(n.substring(1),"/"):o=v_(n,t)):o=t,{pathname:o,search:WB(r),hash:ZB(i)}}function v_(e,t){let n=mh(t).split("/");return e.split("/").forEach(i=>{i===".."?n.length>1&&n.pop():i!=="."&&n.push(i)}),n.length>1?n.join("/"):"/"}function qx(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 YB(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function yw(e){let t=YB(e);return t.map((n,r)=>r===t.length-1?n.pathname:n.pathnameBase)}function _m(e,t,n,r=!1){let i;typeof e=="string"?i=pl(e):(i={...e},Ot(!i.pathname||!i.pathname.includes("?"),qx("?","pathname","search",i)),Ot(!i.pathname||!i.pathname.includes("#"),qx("#","pathname","hash",i)),Ot(!i.search||!i.search.includes("#"),qx("#","search","hash",i)));let o=e===""||i.pathname==="",c=o?"/":i.pathname,f;if(c==null)f=n;else{let y=t.length-1;if(!r&&c.startsWith("..")){let x=c.split("/");for(;x[0]==="..";)x.shift(),y-=1;i.pathname=x.join("/")}f=y>=0?t[y]:"/"}let d=KB(i,f),h=c&&c!=="/"&&c.endsWith("/"),p=(o||c===".")&&n.endsWith("/");return!d.pathname.endsWith("/")&&(h||p)&&(d.pathname+="/"),d}var dD=e=>e.replace(/[\\/]{2,}/g,"/"),Rr=e=>dD(e.join("/")),mh=e=>e.replace(/\/+$/,""),XB=e=>mh(e).replace(/^\/*/,"/"),WB=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,ZB=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e,QB=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 JB(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}function eq(e){let t=e.map(n=>n.route.path).filter(Boolean);return Rr(t)||"/"}var hD=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function mD(e,t){let n=e;if(typeof n!="string"||!pw.test(n))return{absoluteURL:void 0,isExternal:!1,to:n};let r=n,i=!1;if(hD)try{let o=new URL(window.location.href),c=sD.test(n)?new URL(EB(n,o.protocol)):new URL(n),f=Da(c.pathname,t);c.origin===o.origin&&f!=null?n=f+c.search+c.hash:i=!0}catch{gr(!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}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");var pD=["POST","PUT","PATCH","DELETE"];new Set(pD);var tq=["GET",...pD];new Set(tq);var nq=["about:","blob:","chrome:","chrome-untrusted:","content:","data:","devtools:","file:","filesystem:","javascript:"];function rq(e){try{return nq.includes(new URL(e).protocol)}catch{return!1}}var yl=P.createContext(null);yl.displayName="DataRouter";var Tm=P.createContext(null);Tm.displayName="DataRouterState";var yD=P.createContext(!1);function aq(){return P.useContext(yD)}var xD=P.createContext({isTransitioning:!1});xD.displayName="ViewTransition";var iq=P.createContext(new Map);iq.displayName="Fetchers";var sq=P.createContext(null);sq.displayName="Await";var Jn=P.createContext(null);Jn.displayName="Navigation";var Vu=P.createContext(null);Vu.displayName="Location";var $r=P.createContext({outlet:null,matches:[],isDataRoute:!1});$r.displayName="Route";var xw=P.createContext(null);xw.displayName="RouteError";var gD="REACT_ROUTER_ERROR",oq="REDIRECT",lq="ROUTE_ERROR_RESPONSE";function cq(e){if(e.startsWith(`${gD}:${oq}:{`))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 uq(e){if(e.startsWith(`${gD}:${lq}:{`))try{let t=JSON.parse(e.slice(40));if(typeof t=="object"&&t&&typeof t.status=="number"&&typeof t.statusText=="string")return new QB(t.status,t.statusText,t.data)}catch{}}function fq(e,{relative:t}={}){Ot(xl(),"useHref() may be used only in the context of a <Router> component.");let{basename:n,navigator:r}=P.useContext(Jn),{hash:i,pathname:o,search:c}=Hu(e,{relative:t}),f=o;return n!=="/"&&(f=o==="/"?n:Rr([n,o])),r.createHref({pathname:f,search:c,hash:i})}function xl(){return P.useContext(Vu)!=null}function Pn(){return Ot(xl(),"useLocation() may be used only in the context of a <Router> component."),P.useContext(Vu).location}var vD="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function bD(e){P.useContext(Jn).static||P.useLayoutEffect(e)}function Pi(){let{isDataRoute:e}=P.useContext($r);return e?Oq():dq()}function dq(){Ot(xl(),"useNavigate() may be used only in the context of a <Router> component.");let e=P.useContext(yl),{basename:t,navigator:n}=P.useContext(Jn),{matches:r}=P.useContext($r),{pathname:i}=Pn(),o=JSON.stringify(yw(r)),c=P.useRef(!1);return bD(()=>{c.current=!0}),P.useCallback((d,h={})=>{if(gr(c.current,vD),!c.current)return;if(typeof d=="number"){n.go(d);return}let p=_m(d,JSON.parse(o),i,h.relative==="path");e==null&&t!=="/"&&(p.pathname=p.pathname==="/"?t:Rr([t,p.pathname])),(h.replace?n.replace:n.push)(p,h.state,h)},[t,n,o,i,e])}var hq=P.createContext(null);function mq(e){let t=P.useContext($r).outlet;return P.useMemo(()=>t&&P.createElement(hq.Provider,{value:e},t),[t,e])}function Hu(e,{relative:t}={}){let{matches:n}=P.useContext($r),{pathname:r}=Pn(),i=JSON.stringify(yw(n));return P.useMemo(()=>_m(e,JSON.parse(i),r,t==="path"),[e,i,r,t])}function pq(e,t){return jD(e,t)}function jD(e,t,n){var b;Ot(xl(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:r}=P.useContext(Jn),{matches:i}=P.useContext($r),o=i[i.length-1],c=o?o.params:{},f=o?o.pathname:"/",d=o?o.pathnameBase:"/",h=o&&o.route;{let A=h&&h.path||"";SD(f,!h||A.endsWith("*")||A.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${f}" (under <Route path="${A}">) 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="${A}"> to <Route path="${A==="/"?"*":`${A}/*`}">.`)}let p=Pn(),y;if(t){let A=typeof t=="string"?pl(t):t;Ot(d==="/"||((b=A.pathname)==null?void 0:b.startsWith(d)),`When overriding the location using \`<Routes location>\` or \`useRoutes(routes, location)\`, the location pathname must begin with the portion of the URL pathname that was matched by all parent routes. The current pathname base is "${d}" but pathname "${A.pathname}" was given in the \`location\` prop.`),y=A}else y=p;let x=y.pathname||"/",j=x;if(d!=="/"){let A=d.replace(/^\//,"").split("/");j="/"+x.replace(/^\//,"").split("/").slice(A.length).join("/")}let w=n&&n.state.matches.length?n.state.matches.map(A=>Object.assign(A,{route:n.manifest[A.route.id]||A.route})):oD(e,{pathname:j});gr(h||w!=null,`No routes matched location "${y.pathname}${y.search}${y.hash}" `),gr(w==null||w[w.length-1].route.element!==void 0||w[w.length-1].route.Component!==void 0||w[w.length-1].route.lazy!==void 0,`Matched leaf route at location "${y.pathname}${y.search}${y.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 S=bq(w&&w.map(A=>Object.assign({},A,{params:Object.assign({},c,A.params),pathname:Rr([d,r.encodeLocation?r.encodeLocation(A.pathname.replace(/%/g,"%25").replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:A.pathname]),pathnameBase:A.pathnameBase==="/"?d:Rr([d,r.encodeLocation?r.encodeLocation(A.pathnameBase.replace(/%/g,"%25").replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:A.pathnameBase])})),i,n);return t&&S?P.createElement(Vu.Provider,{value:{location:{pathname:"/",search:"",hash:"",state:null,key:"default",mask:void 0,...y},navigationType:"POP"}},S):S}function yq(){let e=Aq(),t=JB(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},o={padding:"2px 4px",backgroundColor:r},c=null;return console.error("Error handled by React Router default ErrorBoundary:",e),c=P.createElement(P.Fragment,null,P.createElement("p",null,"💿 Hey developer 👋"),P.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",P.createElement("code",{style:o},"ErrorBoundary")," or"," ",P.createElement("code",{style:o},"errorElement")," prop on your route.")),P.createElement(P.Fragment,null,P.createElement("h2",null,"Unexpected Application Error!"),P.createElement("h3",{style:{fontStyle:"italic"}},t),n?P.createElement("pre",{style:i},n):null,c)}var xq=P.createElement(yq,null),wD=class extends P.Component{constructor(e){super(e),this.state={location:e.location,revalidation:e.revalidation,error:e.error}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,t){return t.location!==e.location||t.revalidation!=="idle"&&e.revalidation==="idle"?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:e.error!==void 0?e.error:t.error,location:t.location,revalidation:e.revalidation||t.revalidation}}componentDidCatch(e,t){this.props.onError?this.props.onError(e,t):console.error("React Router caught the following error during render",e)}render(){let e=this.state.error;if(this.context&&typeof e=="object"&&e&&"digest"in e&&typeof e.digest=="string"){const n=uq(e.digest);n&&(e=n)}let t=e!==void 0?P.createElement($r.Provider,{value:this.props.routeContext},P.createElement(xw.Provider,{value:e,children:this.props.component})):this.props.children;return this.context?P.createElement(gq,{error:e},t):t}};wD.contextType=yD;var Ix=new WeakMap;function gq({children:e,error:t}){let{basename:n}=P.useContext(Jn);if(typeof t=="object"&&t&&"digest"in t&&typeof t.digest=="string"){let r=cq(t.digest);if(r){let i=Ix.get(t);if(i)throw i;let o=mD(r.location,n),c=o.absoluteURL||o.to;if(rq(c))throw new Error("Invalid redirect location");if(hD&&!Ix.get(t))if(o.isExternal||r.reloadDocument)window.location.href=c;else{const f=Promise.resolve().then(()=>window.__reactRouterDataRouter.navigate(o.to,{replace:r.replace}));throw Ix.set(t,f),f}return P.createElement("meta",{httpEquiv:"refresh",content:`0;url=${c}`})}}return e}function vq({routeContext:e,match:t,children:n}){let r=P.useContext(yl);return r&&r.static&&r.staticContext&&(t.route.errorElement||t.route.ErrorBoundary)&&(r.staticContext._deepestRenderedBoundaryId=t.route.id),P.createElement($r.Provider,{value:e},n)}function bq(e,t=[],n){let r=n==null?void 0: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,o=r==null?void 0:r.errors;if(o!=null){let p=i.findIndex(y=>y.route.id&&(o==null?void 0:o[y.route.id])!==void 0);Ot(p>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(o).join(",")}`),i=i.slice(0,Math.min(i.length,p+1))}let c=!1,f=-1;if(n&&r){c=r.renderFallback;for(let p=0;p<i.length;p++){let y=i[p];if((y.route.HydrateFallback||y.route.hydrateFallbackElement)&&(f=p),y.route.id){let{loaderData:x,errors:j}=r,w=y.route.loader&&!x.hasOwnProperty(y.route.id)&&(!j||j[y.route.id]===void 0);if(y.route.lazy||w){n.isStatic&&(c=!0),f>=0?i=i.slice(0,f+1):i=[i[0]];break}}}}let d=n==null?void 0:n.onError,h=r&&d?(p,y)=>{var x,j;d(p,{location:r.location,params:((j=(x=r.matches)==null?void 0:x[0])==null?void 0:j.params)??{},pattern:eq(r.matches),errorInfo:y})}:void 0;return i.reduceRight((p,y,x)=>{let j,w=!1,S=null,b=null;r&&(j=o&&y.route.id?o[y.route.id]:void 0,S=y.route.errorElement||xq,c&&(f<0&&x===0?(SD("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),w=!0,b=null):f===x&&(w=!0,b=y.route.hydrateFallbackElement||null)));let A=t.concat(i.slice(0,x+1)),_=()=>{let O;return j?O=S:w?O=b:y.route.Component?O=P.createElement(y.route.Component,null):y.route.element?O=y.route.element:O=p,P.createElement(vq,{match:y,routeContext:{outlet:p,matches:A,isDataRoute:r!=null},children:O})};return r&&(y.route.ErrorBoundary||y.route.errorElement||x===0)?P.createElement(wD,{location:r.location,revalidation:r.revalidation,component:S,error:j,children:_(),routeContext:{outlet:null,matches:A,isDataRoute:!0},onError:h}):_()},null)}function gw(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function jq(e){let t=P.useContext(yl);return Ot(t,gw(e)),t}function wq(e){let t=P.useContext(Tm);return Ot(t,gw(e)),t}function Sq(e){let t=P.useContext($r);return Ot(t,gw(e)),t}function vw(e){let t=Sq(e),n=t.matches[t.matches.length-1];return Ot(n.route.id,`${e} can only be used on routes that contain a unique "id"`),n.route.id}function Nq(){return vw("useRouteId")}function Aq(){var r;let e=P.useContext(xw),t=wq("useRouteError"),n=vw("useRouteError");return e!==void 0?e:(r=t.errors)==null?void 0:r[n]}function Oq(){let{router:e}=jq("useNavigate"),t=vw("useNavigate"),n=P.useRef(!1);return bD(()=>{n.current=!0}),P.useCallback(async(i,o={})=>{gr(n.current,vD),n.current&&(typeof i=="number"?await e.navigate(i):await e.navigate(i,{fromRouteId:t,...o}))},[e,t])}var b_={};function SD(e,t,n){!t&&!b_[e]&&(b_[e]=!0,gr(!1,n))}P.memo(_q);function _q({routes:e,manifest:t,future:n,state:r,isStatic:i,onError:o}){return jD(e,void 0,{manifest:t,state:r,isStatic:i,onError:o})}function bw({to:e,replace:t,state:n,relative:r}){Ot(xl(),"<Navigate> may be used only in the context of a <Router> component.");let{static:i}=P.useContext(Jn);gr(!i,"<Navigate> must not be used on the initial render in a <StaticRouter>. This is a no-op, but you should modify your code so the <Navigate> is only ever rendered in response to some user interaction or state change.");let{matches:o}=P.useContext($r),{pathname:c}=Pn(),f=Pi(),d=_m(e,yw(o),c,r==="path"),h=JSON.stringify(d);return P.useEffect(()=>{f(JSON.parse(h),{replace:t,state:n,relative:r})},[f,h,r,t,n]),null}function Tq(e){return mq(e.context)}function St(e){Ot(!1,"A <Route> is only ever to be used as the child of <Routes> element, never rendered directly. Please wrap your <Route> in a <Routes>.")}function Eq({basename:e="/",children:t=null,location:n,navigationType:r="POP",navigator:i,static:o=!1,useTransitions:c}){Ot(!xl(),"You cannot render a <Router> inside another <Router>. You should never have more than one in your app.");let f=e.replace(/^\/*/,"/"),d=P.useMemo(()=>({basename:f,navigator:i,static:o,useTransitions:c,future:{}}),[f,i,o,c]);typeof n=="string"&&(n=pl(n));let{pathname:h="/",search:p="",hash:y="",state:x=null,key:j="default",mask:w}=n,S=P.useMemo(()=>{let b=Da(h,f);return b==null?null:{location:{pathname:b,search:p,hash:y,state:x,key:j,mask:w},navigationType:r}},[f,h,p,y,x,j,r,w]);return gr(S!=null,`<Router basename="${f}"> is not able to match the URL "${h}${p}${y}" because it does not start with the basename, so the <Router> won't render anything.`),S==null?null:P.createElement(Jn.Provider,{value:d},P.createElement(Vu.Provider,{children:t,value:S}))}function Cq({children:e,location:t}){return pq(d1(e),t)}function d1(e,t=[]){let n=[];return P.Children.forEach(e,(r,i)=>{if(!P.isValidElement(r))return;let o=[...t,i];if(r.type===P.Fragment){n.push.apply(n,d1(r.props.children,o));return}Ot(r.type===St,`[${typeof r.type=="string"?r.type:r.type.name}] is not a <Route> component. All component children of <Routes> must be a <Route> or <React.Fragment>`),Ot(!r.props.index||!r.props.children,"An index route cannot have child routes.");let c={id:r.props.id||o.join("-"),caseSensitive:r.props.caseSensitive,element:r.props.element,Component:r.props.Component,index:r.props.index,path:r.props.path,middleware:r.props.middleware,loader:r.props.loader,action:r.props.action,hydrateFallbackElement:r.props.hydrateFallbackElement,HydrateFallback:r.props.HydrateFallback,errorElement:r.props.errorElement,ErrorBoundary:r.props.ErrorBoundary,hasErrorBoundary:r.props.hasErrorBoundary===!0||r.props.ErrorBoundary!=null||r.props.errorElement!=null,shouldRevalidate:r.props.shouldRevalidate,handle:r.props.handle,lazy:r.props.lazy};r.props.children&&(c.children=d1(r.props.children,o)),n.push(c)}),n}var eh="get",th="application/x-www-form-urlencoded";function Em(e){return typeof HTMLElement<"u"&&e instanceof HTMLElement}function Mq(e){return Em(e)&&e.tagName.toLowerCase()==="button"}function Pq(e){return Em(e)&&e.tagName.toLowerCase()==="form"}function Rq(e){return Em(e)&&e.tagName.toLowerCase()==="input"}function kq(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function Dq(e,t){return e.button===0&&(!t||t==="_self")&&!kq(e)}function h1(e=""){return new URLSearchParams(typeof e=="string"||Array.isArray(e)||e instanceof URLSearchParams?e:Object.keys(e).reduce((t,n)=>{let r=e[n];return t.concat(Array.isArray(r)?r.map(i=>[n,i]):[[n,r]])},[]))}function zq(e,t){let n=h1(e);return t&&t.forEach((r,i)=>{n.has(i)||t.getAll(i).forEach(o=>{n.append(i,o)})}),n}var _d=null;function Lq(){if(_d===null)try{new FormData(document.createElement("form"),0),_d=!1}catch{_d=!0}return _d}var $q=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function Ux(e){return e!=null&&!$q.has(e)?(gr(!1,`"${e}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${th}"`),null):e}function Bq(e,t){let n,r,i,o,c;if(Pq(e)){let f=e.getAttribute("action");r=f?Da(f,t):null,n=e.getAttribute("method")||eh,i=Ux(e.getAttribute("enctype"))||th,o=new FormData(e)}else if(Mq(e)||Rq(e)&&(e.type==="submit"||e.type==="image")){let f=e.form;if(f==null)throw new Error('Cannot submit a <button> or <input type="submit"> without a <form>');let d=e.getAttribute("formaction")||f.getAttribute("action");if(r=d?Da(d,t):null,n=e.getAttribute("formmethod")||f.getAttribute("method")||eh,i=Ux(e.getAttribute("formenctype"))||Ux(f.getAttribute("enctype"))||th,o=new FormData(f,e),!Lq()){let{name:h,type:p,value:y}=e;if(p==="image"){let x=h?`${h}.`:"";o.append(`${x}x`,"0"),o.append(`${x}y`,"0")}else h&&o.append(h,y)}}else{if(Em(e))throw new Error('Cannot submit element that is not <form>, <button>, or <input type="submit|image">');n=eh,r=null,i=th,c=e}return o&&i==="text/plain"&&(c=o,o=void 0),{action:r,method:n.toLowerCase(),encType:i,formData:o,body:c}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");function jw(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function ND(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&&Da(i.pathname,t)==="/"?i.pathname=`${mh(t)}/_root.${r}`:i.pathname=`${mh(i.pathname)}.${r}`,i}async function qq(e,t){if(e.id in t)return t[e.id];try{let n=await import(e.module);return t[e.id]=n,n}catch(n){return console.error(`Error loading route module \`${e.module}\`, reloading page...`),console.error(n),window.__reactRouterContext&&window.__reactRouterContext.isSpaMode,window.location.reload(),new Promise(()=>{})}}function Iq(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 Uq(e,t,n){let r=await Promise.all(e.map(async i=>{let o=t.routes[i.route.id];if(o){let c=await qq(o,n);return c.links?c.links():[]}return[]}));return Gq(r.flat(1).filter(Iq).filter(i=>i.rel==="stylesheet"||i.rel==="preload").map(i=>i.rel==="stylesheet"?{...i,rel:"prefetch",as:"style"}:{...i,rel:"prefetch"}))}function j_(e,t,n,r,i,o){let c=(d,h)=>n[h]?d.route.id!==n[h].route.id:!0,f=(d,h)=>{var p;return n[h].pathname!==d.pathname||((p=n[h].route.path)==null?void 0:p.endsWith("*"))&&n[h].params["*"]!==d.params["*"]};return o==="assets"?t.filter((d,h)=>c(d,h)||f(d,h)):o==="data"?t.filter((d,h)=>{var y;let p=r.routes[d.route.id];if(!p||!p.hasLoader)return!1;if(c(d,h)||f(d,h))return!0;if(d.route.shouldRevalidate){let x=d.route.shouldRevalidate({currentUrl:new URL(i.pathname+i.search+i.hash,window.origin),currentParams:((y=n[0])==null?void 0:y.params)||{},nextUrl:new URL(e,window.origin),nextParams:d.params,defaultShouldRevalidate:!0});if(typeof x=="boolean")return x}return!0}):[]}function Vq(e,t,{includeHydrateFallback:n}={}){return Hq(e.map(r=>{let i=t.routes[r.route.id];if(!i)return[];let o=[i.module];return i.clientActionModule&&(o=o.concat(i.clientActionModule)),i.clientLoaderModule&&(o=o.concat(i.clientLoaderModule)),n&&i.hydrateFallbackModule&&(o=o.concat(i.hydrateFallbackModule)),i.imports&&(o=o.concat(i.imports)),o}).flat(1))}function Hq(e){return[...new Set(e)]}function Fq(e){let t={},n=Object.keys(e).sort();for(let r of n)t[r]=e[r];return t}function Gq(e,t){let n=new Set;return new Set(t),e.reduce((r,i)=>{let o=JSON.stringify(Fq(i));return n.has(o)||(n.add(o),r.push({key:o,link:i})),r},[])}function ww(){let e=P.useContext(yl);return jw(e,"You must render this element inside a <DataRouterContext.Provider> element"),e}function Kq(){let e=P.useContext(Tm);return jw(e,"You must render this element inside a <DataRouterStateContext.Provider> element"),e}var Sw=P.createContext(void 0);Sw.displayName="FrameworkContext";function Cm(){let e=P.useContext(Sw);return jw(e,"You must render this element inside a <HydratedRouter> element"),e}function Yq(e,t){let n=P.useContext(Sw),[r,i]=P.useState(!1),[o,c]=P.useState(!1),{onFocus:f,onBlur:d,onMouseEnter:h,onMouseLeave:p,onTouchStart:y}=t,x=P.useRef(null);P.useEffect(()=>{if(e==="render"&&c(!0),e==="viewport"){let S=A=>{A.forEach(_=>{c(_.isIntersecting)})},b=new IntersectionObserver(S,{threshold:.5});return x.current&&b.observe(x.current),()=>{b.disconnect()}}},[e]),P.useEffect(()=>{if(r){let S=setTimeout(()=>{c(!0)},100);return()=>{clearTimeout(S)}}},[r]);let j=()=>{i(!0)},w=()=>{i(!1),c(!1)};return n?e!=="intent"?[o,x,{}]:[o,x,{onFocus:Ac(f,j),onBlur:Ac(d,w),onMouseEnter:Ac(h,j),onMouseLeave:Ac(p,w),onTouchStart:Ac(y,j)}]:[!1,x,{}]}function Ac(e,t){return n=>{e&&e(n),n.defaultPrevented||t(n)}}function Xq({page:e,...t}){let n=aq(),{nonce:r}=Cm(),{router:i}=ww(),o=P.useMemo(()=>oD(i.routes,e,i.basename),[i.routes,e,i.basename]);return o?(t.nonce==null&&r&&(t={...t,nonce:r}),n?P.createElement(Zq,{page:e,matches:o,...t}):P.createElement(Qq,{page:e,matches:o,...t})):null}function Wq(e){let{manifest:t,routeModules:n}=Cm(),[r,i]=P.useState([]);return P.useEffect(()=>{let o=!1;return Uq(e,t,n).then(c=>{o||i(c)}),()=>{o=!0}},[e,t,n]),r}function Zq({page:e,matches:t,...n}){let r=Pn(),{future:i}=Cm(),{basename:o}=ww(),c=P.useMemo(()=>{if(e===r.pathname+r.search+r.hash)return[];let f=ND(e,o,i.v8_trailingSlashAwareDataRequests,"rsc"),d=!1,h=[];for(let p of t)typeof p.route.shouldRevalidate=="function"?d=!0:h.push(p.route.id);return d&&h.length>0&&f.searchParams.set("_routes",h.join(",")),[f.pathname+f.search]},[o,i.v8_trailingSlashAwareDataRequests,e,r,t]);return P.createElement(P.Fragment,null,c.map(f=>P.createElement("link",{key:f,rel:"prefetch",as:"fetch",href:f,...n})))}function Qq({page:e,matches:t,...n}){let r=Pn(),{future:i,manifest:o,routeModules:c}=Cm(),{basename:f}=ww(),{loaderData:d,matches:h}=Kq(),p=P.useMemo(()=>j_(e,t,h,o,r,"data"),[e,t,h,o,r]),y=P.useMemo(()=>j_(e,t,h,o,r,"assets"),[e,t,h,o,r]),x=P.useMemo(()=>{if(e===r.pathname+r.search+r.hash)return[];let S=new Set,b=!1;if(t.forEach(_=>{var T;let O=o.routes[_.route.id];!O||!O.hasLoader||(!p.some(N=>N.route.id===_.route.id)&&_.route.id in d&&((T=c[_.route.id])!=null&&T.shouldRevalidate)||O.hasClientLoader?b=!0:S.add(_.route.id))}),S.size===0)return[];let A=ND(e,f,i.v8_trailingSlashAwareDataRequests,"data");return b&&S.size>0&&A.searchParams.set("_routes",t.filter(_=>S.has(_.route.id)).map(_=>_.route.id).join(",")),[A.pathname+A.search]},[f,i.v8_trailingSlashAwareDataRequests,d,r,o,p,t,e,c]),j=P.useMemo(()=>Vq(y,o),[y,o]),w=Wq(y);return P.createElement(P.Fragment,null,x.map(S=>P.createElement("link",{key:S,rel:"prefetch",as:"fetch",href:S,...n})),j.map(S=>P.createElement("link",{key:S,rel:"modulepreload",href:S,...n})),w.map(({key:S,link:b})=>P.createElement("link",{key:S,nonce:n.nonce,...b,crossOrigin:b.crossOrigin??n.crossOrigin})))}function Jq(...e){return t=>{e.forEach(n=>{typeof n=="function"?n(t):n!=null&&(n.current=t)})}}var eI=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";try{eI&&(window.__reactRouterVersion="7.18.1")}catch{}function tI({basename:e,children:t,useTransitions:n,window:r}){let i=P.useRef();i.current==null&&(i.current=CB({window:r,v5Compat:!0}));let o=i.current,[c,f]=P.useState({action:o.action,location:o.location}),d=P.useCallback(h=>{n===!1?f(h):P.startTransition(()=>f(h))},[n]);return P.useLayoutEffect(()=>o.listen(d),[o,d]),P.createElement(Eq,{basename:e,children:t,location:c.location,navigationType:c.action,navigator:o,useTransitions:n})}var Ao=P.forwardRef(function({onClick:t,discover:n="render",prefetch:r="none",relative:i,reloadDocument:o,replace:c,mask:f,state:d,target:h,to:p,preventScrollReset:y,viewTransition:x,defaultShouldRevalidate:j,...w},S){let{basename:b,navigator:A,useTransitions:_}=P.useContext(Jn),O=typeof p=="string"&&pw.test(p),T=mD(p,b);p=T.to;let N=fq(p,{relative:i}),E=Pn(),M=null;if(f){let Y=_m(f,[],E.mask?E.mask.pathname:"/",!0);b!=="/"&&(Y.pathname=Y.pathname==="/"?b:Rr([b,Y.pathname])),M=A.createHref(Y)}let[D,R,B]=Yq(r,w),q=aI(p,{replace:c,mask:f,state:d,target:h,preventScrollReset:y,relative:i,viewTransition:x,defaultShouldRevalidate:j,useTransitions:_});function z(Y){t&&t(Y),Y.defaultPrevented||q(Y)}let H=!(T.isExternal||o),X=P.createElement("a",{...w,...B,href:(H?M:void 0)||T.absoluteURL||N,onClick:H?z:t,ref:Jq(S,R),target:h,"data-discover":!O&&n==="render"?"true":void 0});return D&&!O?P.createElement(P.Fragment,null,X,P.createElement(Xq,{page:N})):X});Ao.displayName="Link";var AD=P.forwardRef(function({"aria-current":t="page",caseSensitive:n=!1,className:r="",end:i=!1,style:o,to:c,viewTransition:f,children:d,...h},p){let y=Hu(c,{relative:h.relative}),x=Pn(),j=P.useContext(Tm),{navigator:w,basename:S}=P.useContext(Jn),b=j!=null&&uI(y)&&f===!0,A=w.encodeLocation?w.encodeLocation(y).pathname:y.pathname,_=x.pathname,O=j&&j.navigation&&j.navigation.location?j.navigation.location.pathname:null;n||(_=_.toLowerCase(),O=O?O.toLowerCase():null,A=A.toLowerCase()),O&&S&&(O=Da(O,S)||O);const T=A!=="/"&&A.endsWith("/")?A.length-1:A.length;let N=_===A||!i&&_.startsWith(A)&&_.charAt(T)==="/",E=O!=null&&(O===A||!i&&O.startsWith(A)&&O.charAt(A.length)==="/"),M={isActive:N,isPending:E,isTransitioning:b},D=N?t:void 0,R;typeof r=="function"?R=r(M):R=[r,N?"active":null,E?"pending":null,b?"transitioning":null].filter(Boolean).join(" ");let B=typeof o=="function"?o(M):o;return P.createElement(Ao,{...h,"aria-current":D,className:R,ref:p,style:B,to:c,viewTransition:f},typeof d=="function"?d(M):d)});AD.displayName="NavLink";var nI=P.forwardRef(({discover:e="render",fetcherKey:t,navigate:n,reloadDocument:r,replace:i,state:o,method:c=eh,action:f,onSubmit:d,relative:h,preventScrollReset:p,viewTransition:y,defaultShouldRevalidate:x,...j},w)=>{let{useTransitions:S}=P.useContext(Jn),b=lI(),A=cI(f,{relative:h}),_=c.toLowerCase()==="get"?"get":"post",O=typeof f=="string"&&pw.test(f),T=N=>{if(d&&d(N),N.defaultPrevented)return;N.preventDefault();let E=N.nativeEvent.submitter,M=(E==null?void 0:E.getAttribute("formmethod"))||c,D=()=>b(E||N.currentTarget,{fetcherKey:t,method:M,navigate:n,replace:i,state:o,relative:h,preventScrollReset:p,viewTransition:y,defaultShouldRevalidate:x});S&&n!==!1?P.startTransition(()=>D()):D()};return P.createElement("form",{ref:w,method:_,action:A,onSubmit:r?d:T,...j,"data-discover":!O&&e==="render"?"true":void 0})});nI.displayName="Form";function rI(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function OD(e){let t=P.useContext(yl);return Ot(t,rI(e)),t}function aI(e,{target:t,replace:n,mask:r,state:i,preventScrollReset:o,relative:c,viewTransition:f,defaultShouldRevalidate:d,useTransitions:h}={}){let p=Pi(),y=Pn(),x=Hu(e,{relative:c});return P.useCallback(j=>{if(Dq(j,t)){j.preventDefault();let w=n!==void 0?n:nu(y)===nu(x),S=()=>p(e,{replace:w,mask:r,state:i,preventScrollReset:o,relative:c,viewTransition:f,defaultShouldRevalidate:d});h?P.startTransition(()=>S()):S()}},[y,p,x,n,r,i,t,e,o,c,f,d,h])}function iI(e){gr(typeof URLSearchParams<"u","You cannot use the `useSearchParams` hook in a browser that does not support the URLSearchParams API. If you need to support Internet Explorer 11, we recommend you load a polyfill such as https://github.com/ungap/url-search-params.");let t=P.useRef(h1(e)),n=P.useRef(!1),r=Pn(),i=P.useMemo(()=>zq(r.search,n.current?null:t.current),[r.search]),o=Pi(),c=P.useCallback((f,d)=>{const h=h1(typeof f=="function"?f(new URLSearchParams(i)):f);n.current=!0,o("?"+h,d)},[o,i]);return[i,c]}var sI=0,oI=()=>`__${String(++sI)}__`;function lI(){let{router:e}=OD("useSubmit"),{basename:t}=P.useContext(Jn),n=Nq(),r=e.fetch,i=e.navigate;return P.useCallback(async(o,c={})=>{let{action:f,method:d,encType:h,formData:p,body:y}=Bq(o,t);if(c.navigate===!1){let x=c.fetcherKey||oI();await r(x,n,c.action||f,{defaultShouldRevalidate:c.defaultShouldRevalidate,preventScrollReset:c.preventScrollReset,formData:p,body:y,formMethod:c.method||d,formEncType:c.encType||h,flushSync:c.flushSync})}else await i(c.action||f,{defaultShouldRevalidate:c.defaultShouldRevalidate,preventScrollReset:c.preventScrollReset,formData:p,body:y,formMethod:c.method||d,formEncType:c.encType||h,replace:c.replace,state:c.state,fromRouteId:n,flushSync:c.flushSync,viewTransition:c.viewTransition})},[r,i,t,n])}function cI(e,{relative:t}={}){let{basename:n}=P.useContext(Jn),r=P.useContext($r);Ot(r,"useFormAction must be used inside a RouteContext");let[i]=r.matches.slice(-1),o={...Hu(e||".",{relative:t})},c=Pn();if(e==null){o.search=c.search;let f=new URLSearchParams(o.search),d=f.getAll("index");if(d.some(p=>p==="")){f.delete("index"),d.filter(y=>y).forEach(y=>f.append("index",y));let p=f.toString();o.search=p?`?${p}`:""}}return(!e||e===".")&&i.route.index&&(o.search=o.search?o.search.replace(/^\?/,"?index&"):"?index"),n!=="/"&&(o.pathname=o.pathname==="/"?n:Rr([n,o.pathname])),nu(o)}function uI(e,{relative:t}={}){let n=P.useContext(xD);Ot(n!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:r}=OD("useViewTransitionState"),i=Hu(e,{relative:t});if(!n.isTransitioning)return!1;let o=Da(n.currentLocation.pathname,r)||n.currentLocation.pathname,c=Da(n.nextLocation.pathname,r)||n.nextLocation.pathname;return hh(i.pathname,c)!=null||hh(i.pathname,o)!=null}const w_=e=>{let t;const n=new Set,r=(h,p)=>{const y=typeof h=="function"?h(t):h;if(!Object.is(y,t)){const x=t;t=p??(typeof y!="object"||y===null)?y:Object.assign({},t,y),n.forEach(j=>j(t,x))}},i=()=>t,f={setState:r,getState:i,getInitialState:()=>d,subscribe:h=>(n.add(h),()=>n.delete(h))},d=t=e(r,i,f);return f},fI=(e=>e?w_(e):w_),dI=e=>e;function hI(e,t=dI){const n=U.useSyncExternalStore(e.subscribe,U.useCallback(()=>t(e.getState()),[e,t]),U.useCallback(()=>t(e.getInitialState()),[e,t]));return U.useDebugValue(n),n}const S_=e=>{const t=fI(e),n=r=>hI(t,r);return Object.assign(n,t),n},_D=(e=>e?S_(e):S_);function mI(e,t){let n;try{n=e()}catch{return}return{getItem:i=>{var o;const c=d=>d===null?null:JSON.parse(d,void 0),f=(o=n.getItem(i))!=null?o:null;return f instanceof Promise?f.then(c):c(f)},setItem:(i,o)=>n.setItem(i,JSON.stringify(o,void 0)),removeItem:i=>n.removeItem(i)}}const m1=e=>t=>{try{const n=e(t);return n instanceof Promise?n:{then(r){return m1(r)(n)},catch(r){return this}}}catch(n){return{then(r){return this},catch(r){return m1(r)(n)}}}},pI=(e,t)=>(n,r,i)=>{let o={storage:mI(()=>window.localStorage),partialize:b=>b,version:0,merge:(b,A)=>({...A,...b}),...t},c=!1,f=0;const d=new Set,h=new Set;let p=o.storage;if(!p)return e((...b)=>{console.warn(`[zustand persist middleware] Unable to update item '${o.name}', the given storage is currently unavailable.`),n(...b)},r,i);const y=()=>{const b=o.partialize({...r()});return p.setItem(o.name,{state:b,version:o.version})},x=i.setState;i.setState=(b,A)=>(x(b,A),y());const j=e((...b)=>(n(...b),y()),r,i);i.getInitialState=()=>j;let w;const S=()=>{var b,A;if(!p)return;const _=++f;c=!1,d.forEach(T=>{var N;return T((N=r())!=null?N:j)});const O=((A=o.onRehydrateStorage)==null?void 0:A.call(o,(b=r())!=null?b:j))||void 0;return m1(p.getItem.bind(p))(o.name).then(T=>{if(T)if(typeof T.version=="number"&&T.version!==o.version){if(o.migrate){const N=o.migrate(T.state,T.version);return N instanceof Promise?N.then(E=>[!0,E]):[!0,N]}console.error("State loaded from storage couldn't be migrated since no migrate function was provided")}else return[!1,T.state];return[!1,void 0]}).then(T=>{var N;if(_!==f)return;const[E,M]=T;if(w=o.merge(M,(N=r())!=null?N:j),n(w,!0),E)return y()}).then(()=>{_===f&&(O==null||O(r(),void 0),w=r(),c=!0,h.forEach(T=>T(w)))}).catch(T=>{_===f&&(O==null||O(void 0,T))})};return i.persist={setOptions:b=>{o={...o,...b},b.storage&&(p=b.storage)},clearStorage:()=>{p==null||p.removeItem(o.name)},getOptions:()=>o,rehydrate:()=>S(),hasHydrated:()=>c,onHydrate:b=>(d.add(b),()=>{d.delete(b)}),onFinishHydration:b=>(h.add(b),()=>{h.delete(b)})},o.skipHydration||S(),w||j},yI=pI,za=_D()(yI(e=>({token:null,user:null,isAuthenticated:!1,isLoading:!1,login:(t,n)=>{localStorage.setItem("amos_token",t),e({token:t,user:n,isAuthenticated:!0})},logout:()=>{localStorage.removeItem("amos_token"),e({token:null,user:null,isAuthenticated:!1})},setUser:t=>e({user:t})}),{name:"amos-auth",partialize:e=>({token:e.token,user:e.user,isAuthenticated:e.isAuthenticated})})),Nw=P.createContext({});function Aw(e){const t=P.useRef(null);return t.current===null&&(t.current=e()),t.current}const xI=typeof window<"u",Ow=xI?P.useLayoutEffect:P.useEffect,Mm=P.createContext(null);function _w(e,t){e.indexOf(t)===-1&&e.push(t)}function ph(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}const Qr=(e,t,n)=>n>t?t:n<e?e:n;let Tw=()=>{};const Ei={},TD=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e),ED=e=>typeof e=="object"&&e!==null,CD=e=>/^0[^.\s]+$/u.test(e);function MD(e){let t;return()=>(t===void 0&&(t=e()),t)}const xr=e=>e,Fu=(...e)=>e.reduce((t,n)=>r=>n(t(r))),ru=(e,t,n)=>{const r=t-e;return r?(n-e)/r:1};class Ew{constructor(){this.subscriptions=[]}add(t){return _w(this.subscriptions,t),()=>ph(this.subscriptions,t)}notify(t,n,r){const i=this.subscriptions.length;if(i)if(i===1)this.subscriptions[0](t,n,r);else for(let o=0;o<i;o++){const c=this.subscriptions[o];c&&c(t,n,r)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const Xn=e=>e*1e3,pr=e=>e/1e3,PD=(e,t)=>t?e*(1e3/t):0,RD=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,gI=1e-7,vI=12;function bI(e,t,n,r,i){let o,c,f=0;do c=t+(n-t)/2,o=RD(c,r,i)-e,o>0?n=c:t=c;while(Math.abs(o)>gI&&++f<vI);return c}function Gu(e,t,n,r){if(e===t&&n===r)return xr;const i=o=>bI(o,0,1,e,n);return o=>o===0||o===1?o:RD(i(o),t,r)}const kD=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,DD=e=>t=>1-e(1-t),zD=Gu(.33,1.53,.69,.99),Cw=DD(zD),LD=kD(Cw),$D=e=>e>=1?1:(e*=2)<1?.5*Cw(e):.5*(2-Math.pow(2,-10*(e-1))),Mw=e=>1-Math.sin(Math.acos(e)),BD=DD(Mw),qD=kD(Mw),jI=Gu(.42,0,1,1),wI=Gu(0,0,.58,1),ID=Gu(.42,0,.58,1),SI=e=>Array.isArray(e)&&typeof e[0]!="number",UD=e=>Array.isArray(e)&&typeof e[0]=="number",NI={linear:xr,easeIn:jI,easeInOut:ID,easeOut:wI,circIn:Mw,circInOut:qD,circOut:BD,backIn:Cw,backInOut:LD,backOut:zD,anticipate:$D},AI=e=>typeof e=="string",N_=e=>{if(UD(e)){Tw(e.length===4);const[t,n,r,i]=e;return Gu(t,n,r,i)}else if(AI(e))return NI[e];return e},Td=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function OI(e){let t=new Set,n=new Set,r=!1,i=!1;const o=new WeakSet;let c={delta:0,timestamp:0,isProcessing:!1};function f(h){o.has(h)&&(d.schedule(h),e()),h(c)}const d={schedule:(h,p=!1,y=!1)=>{const j=y&&r?t:n;return p&&o.add(h),j.add(h),h},cancel:h=>{n.delete(h),o.delete(h)},process:h=>{if(c=h,r){i=!0;return}r=!0;const p=t;t=n,n=p,t.forEach(f),t.clear(),r=!1,i&&(i=!1,d.process(h))}};return d}const _I=40;function VD(e,t){let n=!1,r=!0;const i={delta:0,timestamp:0,isProcessing:!1},o=()=>n=!0,c=Td.reduce((O,T)=>(O[T]=OI(o),O),{}),{setup:f,read:d,resolveKeyframes:h,preUpdate:p,update:y,preRender:x,render:j,postRender:w}=c,S=()=>{const O=Ei.useManualTiming,T=O?i.timestamp:performance.now();n=!1,O||(i.delta=r?1e3/60:Math.max(Math.min(T-i.timestamp,_I),1)),i.timestamp=T,i.isProcessing=!0,f.process(i),d.process(i),h.process(i),p.process(i),y.process(i),x.process(i),j.process(i),w.process(i),i.isProcessing=!1,n&&t&&(r=!1,e(S))},b=()=>{n=!0,r=!0,i.isProcessing||e(S)};return{schedule:Td.reduce((O,T)=>{const N=c[T];return O[T]=(E,M=!1,D=!1)=>(n||b(),N.schedule(E,M,D)),O},{}),cancel:O=>{for(let T=0;T<Td.length;T++)c[Td[T]].cancel(O)},state:i,steps:c}}const{schedule:ft,cancel:Ci,state:cn,steps:Vx}=VD(typeof requestAnimationFrame<"u"?requestAnimationFrame:xr,!0);let nh;function TI(){nh=void 0}const gn={now:()=>(nh===void 0&&gn.set(cn.isProcessing||Ei.useManualTiming?cn.timestamp:performance.now()),nh),set:e=>{nh=e,queueMicrotask(TI)}},HD=e=>t=>typeof t=="string"&&t.startsWith(e),FD=HD("--"),EI=HD("var(--"),Pw=e=>EI(e)?CI.test(e.split("/*")[0].trim()):!1,CI=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function A_(e){return typeof e!="string"?!1:e.split("/*")[0].includes("var(--")}const gl={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},au={...gl,transform:e=>Qr(0,1,e)},Ed={...gl,default:1},Fc=e=>Math.round(e*1e5)/1e5,Rw=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function MI(e){return e==null}const PI=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,kw=(e,t)=>n=>!!(typeof n=="string"&&PI.test(n)&&n.startsWith(e)||t&&!MI(n)&&Object.prototype.hasOwnProperty.call(n,t)),GD=(e,t,n)=>r=>{if(typeof r!="string")return r;const[i,o,c,f]=r.match(Rw);return{[e]:parseFloat(i),[t]:parseFloat(o),[n]:parseFloat(c),alpha:f!==void 0?parseFloat(f):1}},RI=e=>Qr(0,255,e),Hx={...gl,transform:e=>Math.round(RI(e))},us={test:kw("rgb","red"),parse:GD("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+Hx.transform(e)+", "+Hx.transform(t)+", "+Hx.transform(n)+", "+Fc(au.transform(r))+")"};function kI(e){let t="",n="",r="",i="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),i=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),i=e.substring(4,5),t+=t,n+=n,r+=r,i+=i),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:i?parseInt(i,16)/255:1}}const p1={test:kw("#"),parse:kI,transform:us.transform},Ku=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),Oa=Ku("deg"),Yr=Ku("%"),ye=Ku("px"),DI=Ku("vh"),zI=Ku("vw"),O_={...Yr,parse:e=>Yr.parse(e)/100,transform:e=>Yr.transform(e*100)},Oo={test:kw("hsl","hue"),parse:GD("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+Yr.transform(Fc(t))+", "+Yr.transform(Fc(n))+", "+Fc(au.transform(r))+")"},It={test:e=>us.test(e)||p1.test(e)||Oo.test(e),parse:e=>us.test(e)?us.parse(e):Oo.test(e)?Oo.parse(e):p1.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?us.transform(e):Oo.transform(e),getAnimatableNone:e=>{const t=It.parse(e);return t.alpha=0,It.transform(t)}},LI=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function $I(e){var t,n;return isNaN(e)&&typeof e=="string"&&(((t=e.match(Rw))==null?void 0:t.length)||0)+(((n=e.match(LI))==null?void 0:n.length)||0)>0}const KD="number",YD="color",BI="var",qI="var(",__="${}",II=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function qo(e){const t=e.toString(),n=[],r={color:[],number:[],var:[]},i=[];let o=0;const f=t.replace(II,d=>(It.test(d)?(r.color.push(o),i.push(YD),n.push(It.parse(d))):d.startsWith(qI)?(r.var.push(o),i.push(BI),n.push(d)):(r.number.push(o),i.push(KD),n.push(parseFloat(d))),++o,__)).split(__);return{values:n,split:f,indexes:r,types:i}}function UI(e){return qo(e).values}function XD({split:e,types:t}){const n=e.length;return r=>{let i="";for(let o=0;o<n;o++)if(i+=e[o],r[o]!==void 0){const c=t[o];c===KD?i+=Fc(r[o]):c===YD?i+=It.transform(r[o]):i+=r[o]}return i}}function VI(e){return XD(qo(e))}const HI=e=>typeof e=="number"?0:It.test(e)?It.getAnimatableNone(e):e,FI=(e,t)=>typeof e=="number"?t!=null&&t.trim().endsWith("/")?e:0:HI(e);function GI(e){const t=qo(e);return XD(t)(t.values.map((r,i)=>FI(r,t.split[i])))}const kr={test:$I,parse:UI,createTransformer:VI,getAnimatableNone:GI};function Fx(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function KI({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let i=0,o=0,c=0;if(!t)i=o=c=n;else{const f=n<.5?n*(1+t):n+t-n*t,d=2*n-f;i=Fx(d,f,e+1/3),o=Fx(d,f,e),c=Fx(d,f,e-1/3)}return{red:Math.round(i*255),green:Math.round(o*255),blue:Math.round(c*255),alpha:r}}function yh(e,t){return n=>n>0?t:e}const ut=(e,t,n)=>e+(t-e)*n,Gx=(e,t,n)=>{const r=e*e,i=n*(t*t-r)+r;return i<0?0:Math.sqrt(i)},YI=[p1,us,Oo],XI=e=>YI.find(t=>t.test(e));function T_(e){const t=XI(e);if(!t)return!1;let n=t.parse(e);return t===Oo&&(n=KI(n)),n}const E_=(e,t)=>{const n=T_(e),r=T_(t);if(!n||!r)return yh(e,t);const i={...n};return o=>(i.red=Gx(n.red,r.red,o),i.green=Gx(n.green,r.green,o),i.blue=Gx(n.blue,r.blue,o),i.alpha=ut(n.alpha,r.alpha,o),us.transform(i))},y1=new Set(["none","hidden"]);function WI(e,t){return y1.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function ZI(e,t){return n=>ut(e,t,n)}function Dw(e){return typeof e=="number"?ZI:typeof e=="string"?Pw(e)?yh:It.test(e)?E_:eU:Array.isArray(e)?WD:typeof e=="object"?It.test(e)?E_:QI:yh}function WD(e,t){const n=[...e],r=n.length,i=e.map((o,c)=>Dw(o)(o,t[c]));return o=>{for(let c=0;c<r;c++)n[c]=i[c](o);return n}}function QI(e,t){const n={...e,...t},r={};for(const i in n)e[i]!==void 0&&t[i]!==void 0&&(r[i]=Dw(e[i])(e[i],t[i]));return i=>{for(const o in r)n[o]=r[o](i);return n}}function JI(e,t){const n=[],r={color:0,var:0,number:0};for(let i=0;i<t.values.length;i++){const o=t.types[i],c=e.indexes[o][r[o]],f=e.values[c]??0;n[i]=f,r[o]++}return n}const eU=(e,t)=>{const n=kr.createTransformer(t),r=qo(e),i=qo(t);return r.indexes.var.length===i.indexes.var.length&&r.indexes.color.length===i.indexes.color.length&&r.indexes.number.length>=i.indexes.number.length?y1.has(e)&&!i.values.length||y1.has(t)&&!r.values.length?WI(e,t):Fu(WD(JI(r,i),i.values),n):yh(e,t)};function ZD(e,t,n){return typeof e=="number"&&typeof t=="number"&&typeof n=="number"?ut(e,t,n):Dw(e)(e,t)}const tU=e=>{const t=({timestamp:n})=>e(n);return{start:(n=!0)=>ft.update(t,n),stop:()=>Ci(t),now:()=>cn.isProcessing?cn.timestamp:gn.now()}},QD=(e,t,n=10)=>{let r="";const i=Math.max(Math.round(t/n),2);for(let o=0;o<i;o++)r+=Math.round(e(o/(i-1))*1e4)/1e4+", ";return`linear(${r.substring(0,r.length-2)})`},xh=2e4;function zw(e){let t=0;const n=50;let r=e.next(t);for(;!r.done&&t<xh;)t+=n,r=e.next(t);return t>=xh?1/0:t}function nU(e,t=100,n){const r=n({...e,keyframes:[0,t]}),i=Math.min(zw(r),xh);return{type:"keyframes",ease:o=>r.next(i*o).value/t,duration:pr(i)}}const Mt={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1};function x1(e,t){return e*Math.sqrt(1-t*t)}const rU=12;function aU(e,t,n){let r=n;for(let i=1;i<rU;i++)r=r-e(r)/t(r);return r}const Kx=.001;function iU({duration:e=Mt.duration,bounce:t=Mt.bounce,velocity:n=Mt.velocity,mass:r=Mt.mass}){let i,o,c=1-t;c=Qr(Mt.minDamping,Mt.maxDamping,c),e=Qr(Mt.minDuration,Mt.maxDuration,pr(e)),c<1?(i=h=>{const p=h*c,y=p*e,x=p-n,j=x1(h,c),w=Math.exp(-y);return Kx-x/j*w},o=h=>{const y=h*c*e,x=y*n+n,j=Math.pow(c,2)*Math.pow(h,2)*e,w=Math.exp(-y),S=x1(Math.pow(h,2),c);return(-i(h)+Kx>0?-1:1)*((x-j)*w)/S}):(i=h=>{const p=Math.exp(-h*e),y=(h-n)*e+1;return-Kx+p*y},o=h=>{const p=Math.exp(-h*e),y=(n-h)*(e*e);return p*y});const f=5/e,d=aU(i,o,f);if(e=Xn(e),isNaN(d))return{stiffness:Mt.stiffness,damping:Mt.damping,duration:e};{const h=Math.pow(d,2)*r;return{stiffness:h,damping:c*2*Math.sqrt(r*h),duration:e}}}const sU=["duration","bounce"],oU=["stiffness","damping","mass"];function C_(e,t){return t.some(n=>e[n]!==void 0)}function lU(e){let t={velocity:Mt.velocity,stiffness:Mt.stiffness,damping:Mt.damping,mass:Mt.mass,isResolvedFromDuration:!1,...e};if(!C_(e,oU)&&C_(e,sU))if(t.velocity=0,e.visualDuration){const n=e.visualDuration,r=2*Math.PI/(n*1.2),i=r*r,o=2*Qr(.05,1,1-(e.bounce||0))*Math.sqrt(i);t={...t,mass:Mt.mass,stiffness:i,damping:o}}else{const n=iU({...e,velocity:0});t={...t,...n,mass:Mt.mass},t.isResolvedFromDuration=!0}return t}function gh(e=Mt.visualDuration,t=Mt.bounce){const n=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:r,restDelta:i}=n;const o=n.keyframes[0],c=n.keyframes[n.keyframes.length-1],f={done:!1,value:o},{stiffness:d,damping:h,mass:p,duration:y,velocity:x,isResolvedFromDuration:j}=lU({...n,velocity:-pr(n.velocity||0)}),w=x||0,S=h/(2*Math.sqrt(d*p)),b=c-o,A=pr(Math.sqrt(d/p)),_=Math.abs(b)<5;r||(r=_?Mt.restSpeed.granular:Mt.restSpeed.default),i||(i=_?Mt.restDelta.granular:Mt.restDelta.default);let O,T,N,E,M,D;if(S<1)N=x1(A,S),E=(w+S*A*b)/N,O=B=>{const q=Math.exp(-S*A*B);return c-q*(E*Math.sin(N*B)+b*Math.cos(N*B))},M=S*A*E+b*N,D=S*A*b-E*N,T=B=>Math.exp(-S*A*B)*(M*Math.sin(N*B)+D*Math.cos(N*B));else if(S===1){O=q=>c-Math.exp(-A*q)*(b+(w+A*b)*q);const B=w+A*b;T=q=>Math.exp(-A*q)*(A*B*q-w)}else{const B=A*Math.sqrt(S*S-1);O=X=>{const Y=Math.exp(-S*A*X),$=Math.min(B*X,300);return c-Y*((w+S*A*b)*Math.sinh($)+B*b*Math.cosh($))/B};const q=(w+S*A*b)/B,z=S*A*q-b*B,H=S*A*b-q*B;T=X=>{const Y=Math.exp(-S*A*X),$=Math.min(B*X,300);return Y*(z*Math.sinh($)+H*Math.cosh($))}}const R={calculatedDuration:j&&y||null,velocity:B=>Xn(T(B)),next:B=>{if(!j&&S<1){const z=Math.exp(-S*A*B),H=Math.sin(N*B),X=Math.cos(N*B),Y=c-z*(E*H+b*X),$=Xn(z*(M*H+D*X));return f.done=Math.abs($)<=r&&Math.abs(c-Y)<=i,f.value=f.done?c:Y,f}const q=O(B);if(j)f.done=B>=y;else{const z=Xn(T(B));f.done=Math.abs(z)<=r&&Math.abs(c-q)<=i}return f.value=f.done?c:q,f},toString:()=>{const B=Math.min(zw(R),xh),q=QD(z=>R.next(B*z).value,B,30);return B+"ms "+q},toTransition:()=>{}};return R}gh.applyToOptions=e=>{const t=nU(e,100,gh);return e.ease=t.ease,e.duration=Xn(t.duration),e.type="keyframes",e};const cU=5;function JD(e,t,n){const r=Math.max(t-cU,0);return PD(n-e(r),t-r)}function g1({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:i=10,bounceStiffness:o=500,modifyTarget:c,min:f,max:d,restDelta:h=.5,restSpeed:p}){const y=e[0],x={done:!1,value:y},j=D=>f!==void 0&&D<f||d!==void 0&&D>d,w=D=>f===void 0?d:d===void 0||Math.abs(f-D)<Math.abs(d-D)?f:d;let S=n*t;const b=y+S,A=c===void 0?b:c(b);A!==b&&(S=A-y);const _=D=>-S*Math.exp(-D/r),O=D=>A+_(D),T=D=>{const R=_(D),B=O(D);x.done=Math.abs(R)<=h,x.value=x.done?A:B};let N,E;const M=D=>{j(x.value)&&(N=D,E=gh({keyframes:[x.value,w(x.value)],velocity:JD(O,D,x.value),damping:i,stiffness:o,restDelta:h,restSpeed:p}))};return M(0),{calculatedDuration:null,next:D=>{let R=!1;return!E&&N===void 0&&(R=!0,T(D),M(D)),N!==void 0&&D>=N?E.next(D-N):(!R&&T(D),x)}}}function uU(e,t,n){const r=[],i=n||Ei.mix||ZD,o=e.length-1;for(let c=0;c<o;c++){let f=i(e[c],e[c+1]);if(t){const d=Array.isArray(t)?t[c]||xr:t;f=Fu(d,f)}r.push(f)}return r}function fU(e,t,{clamp:n=!0,ease:r,mixer:i}={}){const o=e.length;if(Tw(o===t.length),o===1)return()=>t[0];if(o===2&&t[0]===t[1])return()=>t[1];const c=e[0]===e[1];e[0]>e[o-1]&&(e=[...e].reverse(),t=[...t].reverse());const f=uU(t,r,i),d=f.length,h=p=>{if(c&&p<e[0])return t[0];let y=0;if(d>1)for(;y<e.length-2&&!(p<e[y+1]);y++);const x=ru(e[y],e[y+1],p);return f[y](x)};return n?p=>h(Qr(e[0],e[o-1],p)):h}function dU(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const i=ru(0,t,r);e.push(ut(n,1,i))}}function hU(e){const t=[0];return dU(t,e.length-1),t}function mU(e,t){return e.map(n=>n*t)}function pU(e,t){return e.map(()=>t||ID).splice(0,e.length-1)}function Gc({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const i=SI(r)?r.map(N_):N_(r),o={done:!1,value:t[0]},c=mU(n&&n.length===t.length?n:hU(t),e),f=fU(c,t,{ease:Array.isArray(i)?i:pU(t,i)});return{calculatedDuration:e,next:d=>(o.value=f(d),o.done=d>=e,o)}}const yU=e=>e!==null;function Pm(e,{repeat:t,repeatType:n="loop"},r,i=1){const o=e.filter(yU),f=i<0||t&&n!=="loop"&&t%2===1?0:o.length-1;return!f||r===void 0?o[f]:r}const xU={decay:g1,inertia:g1,tween:Gc,keyframes:Gc,spring:gh};function e4(e){typeof e.type=="string"&&(e.type=xU[e.type])}class Lw{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(t=>{this.resolve=t})}notifyFinished(){this.resolve()}then(t,n){return this.finished.then(t,n)}}const gU=e=>e/100;class vh extends Lw{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.delayState={done:!1,value:void 0},this.stop=()=>{var r,i;const{motionValue:n}=this.options;n&&n.updatedAt!==gn.now()&&this.tick(gn.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),(i=(r=this.options).onStop)==null||i.call(r))},this.options=t,this.initAnimation(),this.play(),t.autoplay===!1&&this.pause()}initAnimation(){const{options:t}=this;e4(t);const{type:n=Gc,repeat:r=0,repeatDelay:i=0,repeatType:o,velocity:c=0}=t;let{keyframes:f}=t;const d=n||Gc;d!==Gc&&typeof f[0]!="number"&&(this.mixKeyframes=Fu(gU,ZD(f[0],f[1])),f=[0,100]);const h=d({...t,keyframes:f});o==="mirror"&&(this.mirroredGenerator=d({...t,keyframes:[...f].reverse(),velocity:-c})),h.calculatedDuration===null&&(h.calculatedDuration=zw(h));const{calculatedDuration:p}=h;this.calculatedDuration=p,this.resolvedDuration=p+i,this.totalDuration=this.resolvedDuration*(r+1)-i,this.generator=h}updateTime(t){const n=Math.round(t-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=n}tick(t,n=!1){const{generator:r,totalDuration:i,mixKeyframes:o,mirroredGenerator:c,resolvedDuration:f,calculatedDuration:d}=this;if(this.startTime===null)return r.next(0);const{delay:h=0,keyframes:p,repeat:y,repeatType:x,repeatDelay:j,type:w,onUpdate:S,finalKeyframe:b}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-i/this.speed,this.startTime)),n?this.currentTime=t:this.updateTime(t);const A=this.currentTime-h*(this.playbackSpeed>=0?1:-1),_=this.playbackSpeed>=0?A<0:A>i;this.currentTime=Math.max(A,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=i);let O=this.currentTime,T=r;if(y){const D=Math.min(this.currentTime,i)/f;let R=Math.floor(D),B=D%1;!B&&D>=1&&(B=1),B===1&&R--,R=Math.min(R,y+1),!!(R%2)&&(x==="reverse"?(B=1-B,j&&(B-=j/f)):x==="mirror"&&(T=c)),O=Qr(0,1,B)*f}let N;_?(this.delayState.value=p[0],N=this.delayState):N=T.next(O),o&&!_&&(N.value=o(N.value));let{done:E}=N;!_&&d!==null&&(E=this.playbackSpeed>=0?this.currentTime>=i:this.currentTime<=0);const M=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&E);return M&&w!==g1&&(N.value=Pm(p,this.options,b,this.speed)),S&&S(N.value),M&&this.finish(),N}then(t,n){return this.finished.then(t,n)}get duration(){return pr(this.calculatedDuration)}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+pr(t)}get time(){return pr(this.currentTime)}set time(t){t=Xn(t),this.currentTime=t,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.playbackSpeed),this.driver?this.driver.start(!1):(this.startTime=0,this.state="paused",this.holdTime=t,this.tick(t))}getGeneratorVelocity(){const t=this.currentTime;if(t<=0)return this.options.velocity||0;if(this.generator.velocity)return this.generator.velocity(t);const n=this.generator.next(t).value;return JD(r=>this.generator.next(r).value,t,n)}get speed(){return this.playbackSpeed}set speed(t){const n=this.playbackSpeed!==t;n&&this.driver&&this.updateTime(gn.now()),this.playbackSpeed=t,n&&this.driver&&(this.time=pr(this.currentTime))}play(){var i,o;if(this.isStopped)return;const{driver:t=tU,startTime:n}=this.options;this.driver||(this.driver=t(c=>this.tick(c))),(o=(i=this.options).onPlay)==null||o.call(i);const r=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=r):this.holdTime!==null?this.startTime=r-this.holdTime:this.startTime||(this.startTime=n??r),this.state==="finished"&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime(gn.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){var t,n;this.notifyFinished(),this.teardown(),this.state="finished",(n=(t=this.options).onComplete)==null||n.call(t)}cancel(){var t,n;this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),(n=(t=this.options).onCancel)==null||n.call(t)}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}attachTimeline(t){var n;return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),(n=this.driver)==null||n.stop(),t.observe(this)}}function vU(e){for(let t=1;t<e.length;t++)e[t]??(e[t]=e[t-1])}const fs=e=>e*180/Math.PI,v1=e=>{const t=fs(Math.atan2(e[1],e[0]));return b1(t)},bU={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:v1,rotateZ:v1,skewX:e=>fs(Math.atan(e[1])),skewY:e=>fs(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},b1=e=>(e=e%360,e<0&&(e+=360),e),M_=v1,P_=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),R_=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),jU={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:P_,scaleY:R_,scale:e=>(P_(e)+R_(e))/2,rotateX:e=>b1(fs(Math.atan2(e[6],e[5]))),rotateY:e=>b1(fs(Math.atan2(-e[2],e[0]))),rotateZ:M_,rotate:M_,skewX:e=>fs(Math.atan(e[4])),skewY:e=>fs(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function j1(e){return e.includes("scale")?1:0}function w1(e,t){if(!e||e==="none")return j1(t);const n=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let r,i;if(n)r=jU,i=n;else{const f=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);r=bU,i=f}if(!i)return j1(t);const o=r[t],c=i[1].split(",").map(SU);return typeof o=="function"?o(c):c[o]}const wU=(e,t)=>{const{transform:n="none"}=getComputedStyle(e);return w1(n,t)};function SU(e){return parseFloat(e.trim())}const vl=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],bl=new Set([...vl,"pathRotation"]),k_=e=>e===gl||e===ye,NU=new Set(["x","y","z"]),AU=vl.filter(e=>!NU.has(e));function OU(e){const t=[];return AU.forEach(n=>{const r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t}const Ai={width:({x:e},{paddingLeft:t="0",paddingRight:n="0",boxSizing:r})=>{const i=e.max-e.min;return r==="border-box"?i:i-parseFloat(t)-parseFloat(n)},height:({y:e},{paddingTop:t="0",paddingBottom:n="0",boxSizing:r})=>{const i=e.max-e.min;return r==="border-box"?i:i-parseFloat(t)-parseFloat(n)},top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:(e,{transform:t})=>w1(t,"x"),y:(e,{transform:t})=>w1(t,"y")};Ai.translateX=Ai.x;Ai.translateY=Ai.y;const xs=new Set;let S1=!1,N1=!1,A1=!1;function t4(){if(N1){const e=Array.from(xs).filter(r=>r.needsMeasurement),t=new Set(e.map(r=>r.element)),n=new Map;t.forEach(r=>{const i=OU(r);i.length&&(n.set(r,i),r.render())}),e.forEach(r=>r.measureInitialState()),t.forEach(r=>{r.render();const i=n.get(r);i&&i.forEach(([o,c])=>{var f;(f=r.getValue(o))==null||f.set(c)})}),e.forEach(r=>r.measureEndState()),e.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY)})}N1=!1,S1=!1,xs.forEach(e=>e.complete(A1)),xs.clear()}function n4(){xs.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(N1=!0)})}function _U(){A1=!0,n4(),t4(),A1=!1}class $w{constructor(t,n,r,i,o,c=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=n,this.name=r,this.motionValue=i,this.element=o,this.isAsync=c}scheduleResolve(){this.state="scheduled",this.isAsync?(xs.add(this),S1||(S1=!0,ft.read(n4),ft.resolveKeyframes(t4))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:n,element:r,motionValue:i}=this;if(t[0]===null){const o=i==null?void 0:i.get(),c=t[t.length-1];if(o!==void 0)t[0]=o;else if(r&&n){const f=r.readValue(n,c);f!=null&&(t[0]=f)}t[0]===void 0&&(t[0]=c),i&&o===void 0&&i.set(t[0])}vU(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),xs.delete(this)}cancel(){this.state==="scheduled"&&(xs.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const TU=e=>e.startsWith("--");function r4(e,t,n){TU(t)?e.style.setProperty(t,n):e.style[t]=n}const EU={};function a4(e,t){const n=MD(e);return()=>EU[t]??n()}const CU=a4(()=>window.ScrollTimeline!==void 0,"scrollTimeline"),i4=a4(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),Ic=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,D_={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:Ic([0,.65,.55,1]),circOut:Ic([.55,0,1,.45]),backIn:Ic([.31,.01,.66,-.59]),backOut:Ic([.33,1.53,.69,.99])};function s4(e,t){if(e)return typeof e=="function"?i4()?QD(e,t):"ease-out":UD(e)?Ic(e):Array.isArray(e)?e.map(n=>s4(n,t)||D_.easeOut):D_[e]}function MU(e,t,n,{delay:r=0,duration:i=300,repeat:o=0,repeatType:c="loop",ease:f="easeOut",times:d}={},h=void 0){const p={[t]:n};d&&(p.offset=d);const y=s4(f,i);Array.isArray(y)&&(p.easing=y);const x={delay:r,duration:i,easing:Array.isArray(y)?"linear":y,fill:"both",iterations:o+1,direction:c==="reverse"?"alternate":"normal"};return h&&(x.pseudoElement=h),e.animate(p,x)}function o4(e){return typeof e=="function"&&"applyToOptions"in e}function PU({type:e,...t}){return o4(e)&&i4()?e.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}class l4 extends Lw{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,this.manualStartTime=null,!t)return;const{element:n,name:r,keyframes:i,pseudoElement:o,allowFlatten:c=!1,finalKeyframe:f,onComplete:d}=t;this.isPseudoElement=!!o,this.allowFlatten=c,this.options=t,Tw(typeof t.type!="string");const h=PU(t);this.animation=MU(n,r,i,h,o),h.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!o){const p=Pm(i,this.options,f,this.speed);this.updateMotionValue&&this.updateMotionValue(p),r4(n,r,p),this.animation.cancel()}d==null||d(),this.notifyFinished()}}play(){this.isStopped||(this.manualStartTime=null,this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){var t,n;(n=(t=this.animation).finish)==null||n.call(t)}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;const{state:t}=this;t==="idle"||t==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){var n,r,i;const t=(n=this.options)==null?void 0:n.element;!this.isPseudoElement&&(t!=null&&t.isConnected)&&((i=(r=this.animation).commitStyles)==null||i.call(r))}get duration(){var n,r;const t=((r=(n=this.animation.effect)==null?void 0:n.getComputedTiming)==null?void 0:r.call(n).duration)||0;return pr(Number(t))}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+pr(t)}get time(){return pr(Number(this.animation.currentTime)||0)}set time(t){const n=this.finishedTime!==null;this.manualStartTime=null,this.finishedTime=null,this.animation.currentTime=Xn(t),n&&this.animation.pause()}get speed(){return this.animation.playbackRate}set speed(t){t<0&&(this.finishedTime=null),this.animation.playbackRate=t}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return this.manualStartTime??Number(this.animation.startTime)}set startTime(t){this.manualStartTime=this.animation.startTime=t}attachTimeline({timeline:t,rangeStart:n,rangeEnd:r,observe:i}){var o;return this.allowFlatten&&((o=this.animation.effect)==null||o.updateTiming({easing:"linear"})),this.animation.onfinish=null,t&&CU()?(this.animation.timeline=t,n&&(this.animation.rangeStart=n),r&&(this.animation.rangeEnd=r),xr):i(this)}}const c4={anticipate:$D,backInOut:LD,circInOut:qD};function RU(e){return e in c4}function kU(e){typeof e.ease=="string"&&RU(e.ease)&&(e.ease=c4[e.ease])}const Yx=10;class DU extends l4{constructor(t){kU(t),e4(t),super(t),t.startTime!==void 0&&t.autoplay!==!1&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){const{motionValue:n,onUpdate:r,onComplete:i,element:o,...c}=this.options;if(!n)return;if(t!==void 0){n.set(t);return}const f=new vh({...c,autoplay:!1}),d=Math.max(Yx,gn.now()-this.startTime),h=Qr(0,Yx,d-Yx),p=f.sample(d).value,{name:y}=this.options;o&&y&&r4(o,y,p),n.setWithVelocity(f.sample(Math.max(0,d-h)).value,p,h),f.stop()}}const z_=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(kr.test(e)||e==="0")&&!e.startsWith("url("));function zU(e){const t=e[0];if(e.length===1)return!0;for(let n=0;n<e.length;n++)if(e[n]!==t)return!0}function LU(e,t,n,r){const i=e[0];if(i===null)return!1;if(t==="display"||t==="visibility")return!0;const o=e[e.length-1],c=z_(i,t),f=z_(o,t);return!c||!f?!1:zU(e)||(n==="spring"||o4(n))&&r}function O1(e){e.duration=0,e.type="keyframes"}const u4=new Set(["opacity","clipPath","filter","transform"]),$U=/^(?:oklch|oklab|lab|lch|color|color-mix|light-dark)\(/;function BU(e){for(let t=0;t<e.length;t++)if(typeof e[t]=="string"&&$U.test(e[t]))return!0;return!1}const qU=new Set(["color","backgroundColor","outlineColor","fill","stroke","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor"]),IU=MD(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));function UU(e){var y;const{motionValue:t,name:n,repeatDelay:r,repeatType:i,damping:o,type:c,keyframes:f}=e;if(!(((y=t==null?void 0:t.owner)==null?void 0:y.current)instanceof HTMLElement))return!1;const{onUpdate:h,transformTemplate:p}=t.owner.getProps();return IU()&&n&&(u4.has(n)||qU.has(n)&&BU(f))&&(n!=="transform"||!p)&&!h&&!r&&i!=="mirror"&&o!==0&&c!=="inertia"}const VU=40;class HU extends Lw{constructor({autoplay:t=!0,delay:n=0,type:r="keyframes",repeat:i=0,repeatDelay:o=0,repeatType:c="loop",keyframes:f,name:d,motionValue:h,element:p,...y}){var w;super(),this.stop=()=>{var S,b;this._animation&&(this._animation.stop(),(S=this.stopTimeline)==null||S.call(this)),(b=this.keyframeResolver)==null||b.cancel()},this.createdAt=gn.now();const x={autoplay:t,delay:n,type:r,repeat:i,repeatDelay:o,repeatType:c,name:d,motionValue:h,element:p,...y},j=(p==null?void 0:p.KeyframeResolver)||$w;this.keyframeResolver=new j(f,(S,b,A)=>this.onKeyframesResolved(S,b,x,!A),d,h,p),(w=this.keyframeResolver)==null||w.scheduleResolve()}onKeyframesResolved(t,n,r,i){var A,_;this.keyframeResolver=void 0;const{name:o,type:c,velocity:f,delay:d,isHandoff:h,onUpdate:p}=r;this.resolvedAt=gn.now();let y=!0;LU(t,o,c,f)||(y=!1,(Ei.instantAnimations||!d)&&(p==null||p(Pm(t,r,n))),t[0]=t[t.length-1],O1(r),r.repeat=0);const j={startTime:i?this.resolvedAt?this.resolvedAt-this.createdAt>VU?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:n,...r,keyframes:t},w=y&&!h&&UU(j),S=(_=(A=j.motionValue)==null?void 0:A.owner)==null?void 0:_.current;let b;if(w)try{b=new DU({...j,element:S})}catch{b=new vh(j)}else b=new vh(j);b.finished.then(()=>{this.notifyFinished()}).catch(xr),this.pendingTimeline&&(this.stopTimeline=b.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=b}get finished(){return this._animation?this.animation.finished:this._finished}then(t,n){return this.finished.finally(t).then(()=>{})}get animation(){var t;return this._animation||((t=this.keyframeResolver)==null||t.resume(),_U()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(t){this.animation.time=t}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(t){this.animation.speed=t}get startTime(){return this.animation.startTime}attachTimeline(t){return this._animation?this.stopTimeline=this.animation.attachTimeline(t):this.pendingTimeline=t,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){var t;this._animation&&this.animation.cancel(),(t=this.keyframeResolver)==null||t.cancel()}}function f4(e,t,n,r=0,i=1){const o=Array.from(e).sort((h,p)=>h.sortNodePosition(p)).indexOf(t),c=e.size,f=(c-1)*r;return typeof n=="function"?n(o,c):i===1?o*r:f-o*r}const L_=30,FU=e=>!isNaN(parseFloat(e));class GU{constructor(t,n={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=r=>{var o;const i=gn.now();if(this.updatedAt!==i&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(r),this.current!==this.prev&&((o=this.events.change)==null||o.notify(this.current),this.dependents))for(const c of this.dependents)c.dirty()},this.hasAnimated=!1,this.setCurrent(t),this.owner=n.owner}setCurrent(t){this.current=t,this.updatedAt=gn.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=FU(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new Ew);const r=this.events[t].add(n);return t==="change"?()=>{r(),ft.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t){this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t)}setWithVelocity(t,n,r){this.set(n),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-r}jump(t,n=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){var t;(t=this.events.change)==null||t.notify(this.current)}addDependent(t){this.dependents||(this.dependents=new Set),this.dependents.add(t)}removeDependent(t){this.dependents&&this.dependents.delete(t)}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const t=gn.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>L_)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,L_);return PD(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(n),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){var t,n;(t=this.dependents)==null||t.clear(),(n=this.events.destroy)==null||n.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function Io(e,t){return new GU(e,t)}function d4(e,t){if(e!=null&&e.inherit&&t){const{inherit:n,...r}=e;return{...t,...r}}return e}function Bw(e,t){const n=(e==null?void 0:e[t])??(e==null?void 0:e.default)??e;return n!==e?d4(n,e):n}const KU={type:"spring",stiffness:500,damping:25,restSpeed:10},YU=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),XU={type:"keyframes",duration:.8},WU={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},ZU=(e,{keyframes:t})=>t.length>2?XU:bl.has(e)?e.startsWith("scale")?YU(t[1]):KU:WU,QU=new Set(["when","delay","delayChildren","staggerChildren","staggerDirection","repeat","repeatType","repeatDelay","from","elapsed"]);function JU(e){for(const t in e)if(!QU.has(t))return!0;return!1}const qw=(e,t,n,r={},i,o)=>c=>{const f=Bw(r,e)||{},d=f.delay||r.delay||0;let{elapsed:h=0}=r;h=h-Xn(d);const p={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...f,delay:-h,onUpdate:x=>{t.set(x),f.onUpdate&&f.onUpdate(x)},onComplete:()=>{c(),f.onComplete&&f.onComplete()},name:e,motionValue:t,element:o?void 0:i};JU(f)||Object.assign(p,ZU(e,p)),p.duration&&(p.duration=Xn(p.duration)),p.repeatDelay&&(p.repeatDelay=Xn(p.repeatDelay)),p.from!==void 0&&(p.keyframes[0]=p.from);let y=!1;if((p.type===!1||p.duration===0&&!p.repeatDelay)&&(O1(p),p.delay===0&&(y=!0)),(Ei.instantAnimations||Ei.skipAnimations||i!=null&&i.shouldSkipAnimations||f.skipAnimations)&&(y=!0,O1(p),p.delay=0),p.allowFlatten=!f.type&&!f.ease,y&&!o&&t.get()!==void 0){const x=Pm(p.keyframes,f);if(x!==void 0){ft.update(()=>{p.onUpdate(x),p.onComplete()});return}}return f.isSync?new vh(p):new HU(p)},e9=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function t9(e){const t=e9.exec(e);if(!t)return[,];const[,n,r,i]=t;return[`--${n??r}`,i]}function h4(e,t,n=1){const[r,i]=t9(e);if(!r)return;const o=window.getComputedStyle(t).getPropertyValue(r);if(o){const c=o.trim();return TD(c)?parseFloat(c):c}return Pw(i)?h4(i,t,n+1):i}function $_(e){const t=[{},{}];return e==null||e.values.forEach((n,r)=>{t[0][r]=n.get(),t[1][r]=n.getVelocity()}),t}function Iw(e,t,n,r){if(typeof t=="function"){const[i,o]=$_(r);t=t(n!==void 0?n:e.custom,i,o)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){const[i,o]=$_(r);t=t(n!==void 0?n:e.custom,i,o)}return t}function gs(e,t,n){const r=e.getProps();return Iw(r,t,n!==void 0?n:r.custom,e)}const m4=new Set(["width","height","top","left","right","bottom",...vl]),_1=e=>Array.isArray(e);function n9(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,Io(n))}function r9(e){return _1(e)?e[e.length-1]||0:e}function a9(e,t){const n=gs(e,t);let{transitionEnd:r={},transition:i={},...o}=n||{};o={...o,...r};for(const c in o){const f=r9(o[c]);n9(e,c,f)}}const un=e=>!!(e&&e.getVelocity);function i9(e){return!!(un(e)&&e.add)}function T1(e,t){const n=e.getValue("willChange");if(i9(n))return n.add(t);if(!n&&Ei.WillChange){const r=new Ei.WillChange("auto");e.addValue("willChange",r),r.add(t)}}function Uw(e){return e.replace(/([A-Z])/g,t=>`-${t.toLowerCase()}`)}const s9="framerAppearId",p4="data-"+Uw(s9);function y4(e){return e.props[p4]}function o9({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,r}function x4(e,t,{delay:n=0,transitionOverride:r,type:i}={}){let{transition:o,transitionEnd:c,...f}=t;const d=e.getDefaultTransition();o=o?d4(o,d):d;const h=o==null?void 0:o.reduceMotion,p=o==null?void 0:o.skipAnimations;r&&(o=r);const y=[],x=i&&e.animationState&&e.animationState.getState()[i],j=o==null?void 0:o.path;j&&j.animateVisualElement(e,f,o,n,y);for(const w in f){const S=e.getValue(w,e.latestValues[w]??null),b=f[w];if(b===void 0||x&&o9(x,w))continue;const A={delay:n,...Bw(o||{},w)};p&&(A.skipAnimations=!0);const _=S.get();if(_!==void 0&&!S.isAnimating()&&!Array.isArray(b)&&b===_&&!A.velocity){ft.update(()=>S.set(b));continue}let O=!1;if(window.MotionHandoffAnimation){const E=y4(e);if(E){const M=window.MotionHandoffAnimation(E,w,ft);M!==null&&(A.startTime=M,O=!0)}}T1(e,w);const T=h??e.shouldReduceMotion;S.start(qw(w,S,b,T&&m4.has(w)?{type:!1}:A,e,O));const N=S.animation;N&&y.push(N)}if(c){const w=()=>ft.update(()=>{c&&a9(e,c)});y.length?Promise.all(y).then(w):w()}return y}function E1(e,t,n={}){var d;const r=gs(e,t,n.type==="exit"?(d=e.presenceContext)==null?void 0:d.custom:void 0);let{transition:i=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(i=n.transitionOverride);const o=r?()=>Promise.all(x4(e,r,n)):()=>Promise.resolve(),c=e.variantChildren&&e.variantChildren.size?(h=0)=>{const{delayChildren:p=0,staggerChildren:y,staggerDirection:x}=i;return l9(e,t,h,p,y,x,n)}:()=>Promise.resolve(),{when:f}=i;if(f){const[h,p]=f==="beforeChildren"?[o,c]:[c,o];return h().then(()=>p())}else return Promise.all([o(),c(n.delay)])}function l9(e,t,n=0,r=0,i=0,o=1,c){const f=[];for(const d of e.variantChildren)d.notify("AnimationStart",t),f.push(E1(d,t,{...c,delay:n+(typeof r=="function"?0:r)+f4(e.variantChildren,d,r,i,o)}).then(()=>d.notify("AnimationComplete",t)));return Promise.all(f)}function c9(e,t,n={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){const i=t.map(o=>E1(e,o,n));r=Promise.all(i)}else if(typeof t=="string")r=E1(e,t,n);else{const i=typeof t=="function"?gs(e,t,n.custom):t;r=Promise.all(x4(e,i,n))}return r.then(()=>{e.notify("AnimationComplete",t)})}const u9={test:e=>e==="auto",parse:e=>e},g4=e=>t=>t.test(e),v4=[gl,ye,Yr,Oa,zI,DI,u9],B_=e=>v4.find(g4(e));function f9(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||CD(e):!0}const d9=new Set(["brightness","contrast","saturate","opacity"]);function h9(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[r]=n.match(Rw)||[];if(!r)return e;const i=n.replace(r,"");let o=d9.has(t)?1:0;return r!==n&&(o*=100),t+"("+o+i+")"}const m9=/\b([a-z-]*)\(.*?\)/gu,C1={...kr,getAnimatableNone:e=>{const t=e.match(m9);return t?t.map(h9).join(" "):e}},M1={...kr,getAnimatableNone:e=>{const t=kr.parse(e);return kr.createTransformer(e)(t.map(r=>typeof r=="number"?0:typeof r=="object"?{...r,alpha:1}:r))}},q_={...gl,transform:Math.round},p9={rotate:Oa,pathRotation:Oa,rotateX:Oa,rotateY:Oa,rotateZ:Oa,scale:Ed,scaleX:Ed,scaleY:Ed,scaleZ:Ed,skew:Oa,skewX:Oa,skewY:Oa,distance:ye,translateX:ye,translateY:ye,translateZ:ye,x:ye,y:ye,z:ye,perspective:ye,transformPerspective:ye,opacity:au,originX:O_,originY:O_,originZ:ye},bh={borderWidth:ye,borderTopWidth:ye,borderRightWidth:ye,borderBottomWidth:ye,borderLeftWidth:ye,borderRadius:ye,borderTopLeftRadius:ye,borderTopRightRadius:ye,borderBottomRightRadius:ye,borderBottomLeftRadius:ye,width:ye,maxWidth:ye,height:ye,maxHeight:ye,top:ye,right:ye,bottom:ye,left:ye,inset:ye,insetBlock:ye,insetBlockStart:ye,insetBlockEnd:ye,insetInline:ye,insetInlineStart:ye,insetInlineEnd:ye,padding:ye,paddingTop:ye,paddingRight:ye,paddingBottom:ye,paddingLeft:ye,paddingBlock:ye,paddingBlockStart:ye,paddingBlockEnd:ye,paddingInline:ye,paddingInlineStart:ye,paddingInlineEnd:ye,margin:ye,marginTop:ye,marginRight:ye,marginBottom:ye,marginLeft:ye,marginBlock:ye,marginBlockStart:ye,marginBlockEnd:ye,marginInline:ye,marginInlineStart:ye,marginInlineEnd:ye,fontSize:ye,backgroundPositionX:ye,backgroundPositionY:ye,...p9,zIndex:q_,fillOpacity:au,strokeOpacity:au,numOctaves:q_},y9={...bh,color:It,backgroundColor:It,outlineColor:It,fill:It,stroke:It,borderColor:It,borderTopColor:It,borderRightColor:It,borderBottomColor:It,borderLeftColor:It,filter:C1,WebkitFilter:C1,mask:M1,WebkitMask:M1},b4=e=>y9[e],x9=new Set([C1,M1]);function j4(e,t){let n=b4(e);return x9.has(n)||(n=kr),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const g9=new Set(["auto","none","0"]);function v9(e,t,n){let r=0,i;for(;r<e.length&&!i;){const o=e[r];typeof o=="string"&&!g9.has(o)&&qo(o).values.length&&(i=e[r]),r++}if(i&&n)for(const o of t)e[o]=j4(n,i)}class b9 extends $w{constructor(t,n,r,i,o){super(t,n,r,i,o,!0)}readKeyframes(){const{unresolvedKeyframes:t,element:n,name:r}=this;if(!n||!n.current)return;super.readKeyframes();for(let p=0;p<t.length;p++){let y=t[p];if(typeof y=="string"&&(y=y.trim(),Pw(y))){const x=h4(y,n.current);x!==void 0&&(t[p]=x),p===t.length-1&&(this.finalKeyframe=y)}}if(this.resolveNoneKeyframes(),!m4.has(r)||t.length!==2)return;const[i,o]=t,c=B_(i),f=B_(o),d=A_(i),h=A_(o);if(d!==h&&Ai[r]){this.needsMeasurement=!0;return}if(c!==f)if(k_(c)&&k_(f))for(let p=0;p<t.length;p++){const y=t[p];typeof y=="string"&&(t[p]=parseFloat(y))}else Ai[r]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){const{unresolvedKeyframes:t,name:n}=this,r=[];for(let i=0;i<t.length;i++)(t[i]===null||f9(t[i]))&&r.push(i);r.length&&v9(t,r,n)}measureInitialState(){const{element:t,unresolvedKeyframes:n,name:r}=this;if(!t||!t.current)return;r==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=Ai[r](t.measureViewportBox(),window.getComputedStyle(t.current)),n[0]=this.measuredOrigin;const i=n[n.length-1];i!==void 0&&t.getValue(r,i).jump(i,!1)}measureEndState(){var f;const{element:t,name:n,unresolvedKeyframes:r}=this;if(!t||!t.current)return;const i=t.getValue(n);i&&i.jump(this.measuredOrigin,!1);const o=r.length-1,c=r[o];r[o]=Ai[n](t.measureViewportBox(),window.getComputedStyle(t.current)),c!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=c),(f=this.removedTransforms)!=null&&f.length&&this.removedTransforms.forEach(([d,h])=>{t.getValue(d).set(h)}),this.resolveNoneKeyframes()}}const Vw=["borderTopLeftRadius","borderTopRightRadius","borderBottomRightRadius","borderBottomLeftRadius"];function w4(e,t,n){if(e==null)return[];if(e instanceof EventTarget)return[e];if(typeof e=="string"){let r=document;const i=(n==null?void 0:n[e])??r.querySelectorAll(e);return i?Array.from(i):[]}return Array.from(e).filter(r=>r!=null)}const P1=(e,t)=>t&&typeof e=="number"?t.transform(e):e;function rh(e){return ED(e)&&"offsetHeight"in e&&!("ownerSVGElement"in e)}const{schedule:Hw}=VD(queueMicrotask,!1),Er={x:!1,y:!1};function S4(){return Er.x||Er.y}function j9(e){return e==="x"||e==="y"?Er[e]?null:(Er[e]=!0,()=>{Er[e]=!1}):Er.x||Er.y?null:(Er.x=Er.y=!0,()=>{Er.x=Er.y=!1})}function N4(e,t){const n=w4(e),r=new AbortController,i={passive:!0,...t,signal:r.signal};return[n,i,()=>r.abort()]}function w9(e){return!(e.pointerType==="touch"||S4())}function S9(e,t,n={}){const[r,i,o]=N4(e,n);return r.forEach(c=>{let f=!1,d=!1,h;const p=()=>{c.removeEventListener("pointerleave",w)},y=b=>{h&&(h(b),h=void 0),p()},x=b=>{f=!1,window.removeEventListener("pointerup",x),window.removeEventListener("pointercancel",x),d&&(d=!1,y(b))},j=()=>{f=!0,window.addEventListener("pointerup",x,i),window.addEventListener("pointercancel",x,i)},w=b=>{if(b.pointerType!=="touch"){if(f){d=!0;return}y(b)}},S=b=>{if(!w9(b))return;d=!1;const A=t(c,b);typeof A=="function"&&(h=A,c.addEventListener("pointerleave",w,i))};c.addEventListener("pointerenter",S,i),c.addEventListener("pointerdown",j,i)}),o}const A4=(e,t)=>t?e===t?!0:A4(e,t.parentElement):!1,Fw=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1,N9=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function A9(e){return N9.has(e.tagName)||e.isContentEditable===!0}const O9=new Set(["INPUT","SELECT","TEXTAREA"]);function _9(e){return O9.has(e.tagName)||e.isContentEditable===!0}const ah=new WeakSet;function I_(e){return t=>{t.key==="Enter"&&e(t)}}function Xx(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}const T9=(e,t)=>{const n=e.currentTarget;if(!n)return;const r=I_(()=>{if(ah.has(n))return;Xx(n,"down");const i=I_(()=>{Xx(n,"up")}),o=()=>Xx(n,"cancel");n.addEventListener("keyup",i,t),n.addEventListener("blur",o,t)});n.addEventListener("keydown",r,t),n.addEventListener("blur",()=>n.removeEventListener("keydown",r),t)};function U_(e){return Fw(e)&&!S4()}const V_=new WeakSet;function E9(e,t,n={}){const[r,i,o]=N4(e,n),c=f=>{const d=f.currentTarget;if(!U_(f)||V_.has(f))return;ah.add(d),n.stopPropagation&&V_.add(f);const h=t(d,f),p={...i,capture:!0},y=(w,S)=>{window.removeEventListener("pointerup",x,p),window.removeEventListener("pointercancel",j,p),ah.has(d)&&ah.delete(d),U_(w)&&typeof h=="function"&&h(w,{success:S})},x=w=>{y(w,d===window||d===document||n.useGlobalTarget||A4(d,w.target))},j=w=>{y(w,!1)};window.addEventListener("pointerup",x,p),window.addEventListener("pointercancel",j,p)};return r.forEach(f=>{(n.useGlobalTarget?window:f).addEventListener("pointerdown",c,i),rh(f)&&(f.addEventListener("focus",h=>T9(h,i)),!A9(f)&&!f.hasAttribute("tabindex")&&(f.tabIndex=0))}),o}function Gw(e){return ED(e)&&"ownerSVGElement"in e}const ih=new WeakMap;let wi;const O4=(e,t,n)=>(r,i)=>i&&i[0]?i[0][e+"Size"]:Gw(r)&&"getBBox"in r?r.getBBox()[t]:r[n],C9=O4("inline","width","offsetWidth"),M9=O4("block","height","offsetHeight");function P9({target:e,borderBoxSize:t}){var n;(n=ih.get(e))==null||n.forEach(r=>{r(e,{get width(){return C9(e,t)},get height(){return M9(e,t)}})})}function R9(e){e.forEach(P9)}function k9(){typeof ResizeObserver>"u"||(wi=new ResizeObserver(R9))}function D9(e,t){wi||k9();const n=w4(e);return n.forEach(r=>{let i=ih.get(r);i||(i=new Set,ih.set(r,i)),i.add(t),wi==null||wi.observe(r)}),()=>{n.forEach(r=>{const i=ih.get(r);i==null||i.delete(t),i!=null&&i.size||wi==null||wi.unobserve(r)})}}const sh=new Set;let _o;function z9(){_o=()=>{const e={get width(){return window.innerWidth},get height(){return window.innerHeight}};sh.forEach(t=>t(e))},window.addEventListener("resize",_o)}function L9(e){return sh.add(e),_o||z9(),()=>{sh.delete(e),!sh.size&&typeof _o=="function"&&(window.removeEventListener("resize",_o),_o=void 0)}}function H_(e,t){return typeof e=="function"?L9(e):D9(e,t)}function $9(e){return Gw(e)&&e.tagName==="svg"}const B9=[...v4,It,kr],q9=e=>B9.find(g4(e)),F_=()=>({translate:0,scale:1,origin:0,originPoint:0}),To=()=>({x:F_(),y:F_()}),G_=()=>({min:0,max:0}),Gt=()=>({x:G_(),y:G_()}),I9=new WeakMap;function Rm(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function iu(e){return typeof e=="string"||Array.isArray(e)}const Kw=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],Yw=["initial",...Kw];function km(e){return Rm(e.animate)||Yw.some(t=>iu(e[t]))}function _4(e){return!!(km(e)||e.variants)}function U9(e,t,n){for(const r in t){const i=t[r],o=n[r];if(un(i))e.addValue(r,i);else if(un(o))e.addValue(r,Io(i,{owner:e}));else if(o!==i)if(e.hasValue(r)){const c=e.getValue(r);c.liveStyle===!0?c.jump(i):c.hasAnimated||c.set(i)}else{const c=e.getStaticValue(r);e.addValue(r,Io(c!==void 0?c:i,{owner:e}))}}for(const r in n)t[r]===void 0&&e.removeValue(r);return t}const R1={current:null},T4={current:!1},V9=typeof window<"u";function H9(){if(T4.current=!0,!!V9)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>R1.current=e.matches;e.addEventListener("change",t),t()}else R1.current=!1}const K_=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];let jh={};function E4(e){jh=e}function F9(){return jh}class G9{scrapeMotionValuesFromProps(t,n,r){return{}}constructor({parent:t,props:n,presenceContext:r,reducedMotionConfig:i,skipAnimations:o,blockInitialAnimation:c,visualState:f},d={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.shouldSkipAnimations=!1,this.values=new Map,this.KeyframeResolver=$w,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.hasBeenMounted=!1,this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const j=gn.now();this.renderScheduledAt<j&&(this.renderScheduledAt=j,ft.render(this.render,!1,!0))};const{latestValues:h,renderState:p}=f;this.latestValues=h,this.baseTarget={...h},this.initialValues=n.initial?{...h}:{},this.renderState=p,this.parent=t,this.props=n,this.presenceContext=r,this.depth=t?t.depth+1:0,this.reducedMotionConfig=i,this.skipAnimationsConfig=o,this.options=d,this.blockInitialAnimation=!!c,this.isControllingVariants=km(n),this.isVariantNode=_4(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const{willChange:y,...x}=this.scrapeMotionValuesFromProps(n,{},this);for(const j in x){const w=x[j];h[j]!==void 0&&un(w)&&w.set(h[j])}}mount(t){var n,r;if(this.hasBeenMounted)for(const i in this.initialValues)(n=this.values.get(i))==null||n.jump(this.initialValues[i]),this.latestValues[i]=this.initialValues[i];this.current=t,I9.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((i,o)=>this.bindToMotionValue(o,i)),this.reducedMotionConfig==="never"?this.shouldReduceMotion=!1:this.reducedMotionConfig==="always"?this.shouldReduceMotion=!0:(T4.current||H9(),this.shouldReduceMotion=R1.current),this.shouldSkipAnimations=this.skipAnimationsConfig??!1,(r=this.parent)==null||r.addChild(this),this.update(this.props,this.presenceContext),this.hasBeenMounted=!0}unmount(){var t;this.projection&&this.projection.unmount(),Ci(this.notifyUpdate),Ci(this.render),this.valueSubscriptions.forEach(n=>n()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),(t=this.parent)==null||t.removeChild(this);for(const n in this.events)this.events[n].clear();for(const n in this.features){const r=this.features[n];r&&(r.unmount(),r.isMounted=!1)}this.current=null}addChild(t){this.children.add(t),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(t)}removeChild(t){this.children.delete(t),this.enteringChildren&&this.enteringChildren.delete(t)}bindToMotionValue(t,n){if(this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)(),n.accelerate&&u4.has(t)&&this.current instanceof HTMLElement){const{factory:c,keyframes:f,times:d,ease:h,duration:p}=n.accelerate,y=new l4({element:this.current,name:t,keyframes:f,times:d,ease:h,duration:Xn(p)}),x=c(y);this.valueSubscriptions.set(t,()=>{x(),y.cancel()});return}const r=bl.has(t);r&&this.onBindTransform&&this.onBindTransform();const i=n.on("change",c=>{this.latestValues[t]=c,this.props.onUpdate&&ft.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let o;typeof window<"u"&&window.MotionCheckAppearSync&&(o=window.MotionCheckAppearSync(this,t,n)),this.valueSubscriptions.set(t,()=>{i(),o&&o()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in jh){const n=jh[t];if(!n)continue;const{isEnabled:r,Feature:i}=n;if(!this.features[t]&&i&&r(this.props)&&(this.features[t]=new i(this)),this.features[t]){const o=this.features[t];o.isMounted?o.update():(o.mount(),o.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):Gt()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let r=0;r<K_.length;r++){const i=K_[r];this.propEventSubscriptions[i]&&(this.propEventSubscriptions[i](),delete this.propEventSubscriptions[i]);const o="on"+i,c=t[o];c&&(this.propEventSubscriptions[i]=this.on(i,c))}this.prevMotionValues=U9(this,this.scrapeMotionValuesFromProps(t,this.prevProps||{},this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(t){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(t),()=>n.variantChildren.delete(t)}addValue(t,n){const r=this.values.get(t);n!==r&&(r&&this.removeValue(t),this.bindToMotionValue(t,n),this.values.set(t,n),this.latestValues[t]=n.get())}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let r=this.values.get(t);return r===void 0&&n!==void 0&&(r=Io(n===null?void 0:n,{owner:this}),this.addValue(t,r)),r}readValue(t,n){let r=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options);return r!=null&&(typeof r=="string"&&(TD(r)||CD(r))?r=parseFloat(r):!q9(r)&&kr.test(n)&&(r=j4(t,n)),this.setBaseTarget(t,un(r)?r.get():r)),un(r)?r.get():r}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){var o;const{initial:n}=this.props;let r;if(typeof n=="string"||typeof n=="object"){const c=Iw(this.props,n,(o=this.presenceContext)==null?void 0:o.custom);c&&(r=c[t])}if(n&&r!==void 0)return r;const i=this.getBaseTargetFromProps(this.props,t);return i!==void 0&&!un(i)?i:this.initialValues[t]!==void 0&&r===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new Ew),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}scheduleRenderMicrotask(){Hw.render(this.render)}}class C4 extends G9{constructor(){super(...arguments),this.KeyframeResolver=b9}sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){const r=t.style;return r?r[n]:void 0}removeValueFromRenderState(t,{vars:n,style:r}){delete n[t],delete r[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;un(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}class Ri{constructor(t){this.isMounted=!1,this.node=t}update(){}}function M4({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function K9({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function Y9(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}function Wx(e){return e===void 0||e===1}function k1({scale:e,scaleX:t,scaleY:n}){return!Wx(e)||!Wx(t)||!Wx(n)}function ss(e){return k1(e)||P4(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function P4(e){return Y_(e.x)||Y_(e.y)}function Y_(e){return e&&e!=="0%"}function wh(e,t,n){const r=e-n,i=t*r;return n+i}function X_(e,t,n,r,i){return i!==void 0&&(e=wh(e,i,r)),wh(e,n,r)+t}function D1(e,t=0,n=1,r,i){e.min=X_(e.min,t,n,r,i),e.max=X_(e.max,t,n,r,i)}function R4(e,{x:t,y:n}){D1(e.x,t.translate,t.scale,t.originPoint),D1(e.y,n.translate,n.scale,n.originPoint)}const W_=.999999999999,Z_=1.0000000000001;function X9(e,t,n,r=!1){var f;const i=n.length;if(!i)return;t.x=t.y=1;let o,c;for(let d=0;d<i;d++){o=n[d],c=o.projectionDelta;const{visualElement:h}=o.options;h&&h.props.style&&h.props.style.display==="contents"||(r&&o.options.layoutScroll&&o.scroll&&o!==o.root&&(Gr(e.x,-o.scroll.offset.x),Gr(e.y,-o.scroll.offset.y)),c&&(t.x*=c.x.scale,t.y*=c.y.scale,R4(e,c)),r&&ss(o.latestValues)&&oh(e,o.latestValues,(f=o.layout)==null?void 0:f.layoutBox))}t.x<Z_&&t.x>W_&&(t.x=1),t.y<Z_&&t.y>W_&&(t.y=1)}function Gr(e,t){e.min+=t,e.max+=t}function Q_(e,t,n,r,i=.5){const o=ut(e.min,e.max,i);D1(e,t,n,o,r)}function J_(e,t){return typeof e=="string"?parseFloat(e)/100*(t.max-t.min):e}function oh(e,t,n){const r=n??e;Q_(e.x,J_(t.x,r.x),t.scaleX,t.scale,t.originX),Q_(e.y,J_(t.y,r.y),t.scaleY,t.scale,t.originY)}function k4(e,t){return M4(Y9(e.getBoundingClientRect(),t))}function W9(e,t,n){const r=k4(e,n),{scroll:i}=t;return i&&(Gr(r.x,i.offset.x),Gr(r.y,i.offset.y)),r}const Z9={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},Q9=vl.length;function J9(e,t,n){let r="",i=!0;for(let c=0;c<Q9;c++){const f=vl[c],d=e[f];if(d===void 0)continue;let h=!0;if(typeof d=="number")h=d===(f.startsWith("scale")?1:0);else{const p=parseFloat(d);h=f.startsWith("scale")?p===1:p===0}if(!h||n){const p=P1(d,bh[f]);if(!h){i=!1;const y=Z9[f]||f;r+=`${y}(${p}) `}n&&(t[f]=p)}}const o=e.pathRotation;return o&&(i=!1,r+=`rotate(${P1(o,bh.pathRotation)}) `),r=r.trim(),n?r=n(t,i?"":r):i&&(r="none"),r}function Xw(e,t,n){const{style:r,vars:i,transformOrigin:o}=e;let c=!1,f=!1;for(const d in t){const h=t[d];if(bl.has(d)){c=!0;continue}else if(FD(d)){i[d]=h;continue}else{const p=P1(h,bh[d]);d.startsWith("origin")?(f=!0,o[d]=p):r[d]=p}}if(t.transform||(c||n?r.transform=J9(t,e.transform,n):r.transform&&(r.transform="none")),f){const{originX:d="50%",originY:h="50%",originZ:p=0}=o;r.transformOrigin=`${d} ${h} ${p}`}}function D4(e,{style:t,vars:n},r,i){const o=e.style;let c;for(c in t)o[c]=t[c];i==null||i.applyProjectionStyles(o,r);for(c in n)o.setProperty(c,n[c])}function eT(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const Oc={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(ye.test(e))e=parseFloat(e);else return e;const n=eT(e,t.target.x),r=eT(e,t.target.y);return`${n}% ${r}%`}},eV={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,i=kr.parse(e);if(i.length>5)return r;const o=kr.createTransformer(e),c=typeof i[0]!="number"?1:0,f=n.x.scale*t.x,d=n.y.scale*t.y;i[0+c]/=f,i[1+c]/=d;const h=ut(f,d,.5);return typeof i[2+c]=="number"&&(i[2+c]/=h),typeof i[3+c]=="number"&&(i[3+c]/=h),o(i)}},z1={borderRadius:{...Oc,applyTo:[...Vw]},borderTopLeftRadius:Oc,borderTopRightRadius:Oc,borderBottomLeftRadius:Oc,borderBottomRightRadius:Oc,boxShadow:eV};function z4(e,{layout:t,layoutId:n}){return bl.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!z1[e]||e==="opacity")}function Ww(e,t,n){var c;const r=e.style,i=t==null?void 0:t.style,o={};if(!r)return o;for(const f in r)(un(r[f])||i&&un(i[f])||z4(f,e)||((c=n==null?void 0:n.getValue(f))==null?void 0:c.liveStyle)!==void 0)&&(o[f]=r[f]);return o}function tV(e){return window.getComputedStyle(e)}class nV extends C4{constructor(){super(...arguments),this.type="html",this.renderInstance=D4}readValueFromInstance(t,n){var r;if(bl.has(n))return(r=this.projection)!=null&&r.isProjecting?j1(n):wU(t,n);{const i=tV(t),o=(FD(n)?i.getPropertyValue(n):i[n])||0;return typeof o=="string"?o.trim():o}}measureInstanceViewportBox(t,{transformPagePoint:n}){return k4(t,n)}build(t,n,r){Xw(t,n,r.transformTemplate)}scrapeMotionValuesFromProps(t,n,r){return Ww(t,n,r)}}const rV={offset:"stroke-dashoffset",array:"stroke-dasharray"},aV={offset:"strokeDashoffset",array:"strokeDasharray"};function iV(e,t,n=1,r=0,i=!0){e.pathLength=1;const o=i?rV:aV;e[o.offset]=`${-r}`,e[o.array]=`${t} ${n}`}const sV=["offsetDistance","offsetPath","offsetRotate","offsetAnchor"];function L4(e,{attrX:t,attrY:n,attrScale:r,pathLength:i,pathSpacing:o=1,pathOffset:c=0,...f},d,h,p){if(Xw(e,f,h),d){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:y,style:x}=e;y.transform&&(x.transform=y.transform,delete y.transform),(x.transform||y.transformOrigin)&&(x.transformOrigin=y.transformOrigin??"50% 50%",delete y.transformOrigin),x.transform&&(x.transformBox=(p==null?void 0:p.transformBox)??"fill-box",delete y.transformBox);for(const j of sV)y[j]!==void 0&&(x[j]=y[j],delete y[j]);t!==void 0&&(y.x=t),n!==void 0&&(y.y=n),r!==void 0&&(y.scale=r),i!==void 0&&iV(y,i,o,c,!1)}const $4=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]),B4=e=>typeof e=="string"&&e.toLowerCase()==="svg";function oV(e,t,n,r){D4(e,t,void 0,r);for(const i in t.attrs)e.setAttribute($4.has(i)?i:Uw(i),t.attrs[i])}function q4(e,t,n){const r=Ww(e,t,n);for(const i in e)if(un(e[i])||un(t[i])){const o=vl.indexOf(i)!==-1?"attr"+i.charAt(0).toUpperCase()+i.substring(1):i;r[o]=e[i]}return r}class lV extends C4{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=Gt}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(bl.has(n)){const r=b4(n);return r&&r.default||0}return n=$4.has(n)?n:Uw(n),t.getAttribute(n)}scrapeMotionValuesFromProps(t,n,r){return q4(t,n,r)}build(t,n,r){L4(t,n,this.isSVGTag,r.transformTemplate,r.style)}renderInstance(t,n,r,i){oV(t,n,r,i)}mount(t){this.isSVGTag=B4(t.tagName),super.mount(t)}}const cV=Yw.length;function I4(e){if(!e)return;if(!e.isControllingVariants){const n=e.parent?I4(e.parent)||{}:{};return e.props.initial!==void 0&&(n.initial=e.props.initial),n}const t={};for(let n=0;n<cV;n++){const r=Yw[n],i=e.props[r];(iu(i)||i===!1)&&(t[r]=i)}return t}function U4(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let r=0;r<n;r++)if(t[r]!==e[r])return!1;return!0}const uV=[...Kw].reverse(),fV=Kw.length;function dV(e){return t=>Promise.all(t.map(({animation:n,options:r})=>c9(e,n,r)))}function hV(e){let t=dV(e),n=tT(),r=!0,i=!1;const o=h=>(p,y)=>{var j;const x=gs(e,y,h==="exit"?(j=e.presenceContext)==null?void 0:j.custom:void 0);if(x){const{transition:w,transitionEnd:S,...b}=x;p={...p,...b,...S}}return p};function c(h){t=h(e)}function f(h){const{props:p}=e,y=I4(e.parent)||{},x=[],j=new Set;let w={},S=1/0;for(let A=0;A<fV;A++){const _=uV[A],O=n[_],T=p[_]!==void 0?p[_]:y[_],N=iu(T),E=_===h?O.isActive:null;E===!1&&(S=A);let M=T===y[_]&&T!==p[_]&&N;if(M&&(r||i)&&e.manuallyAnimateOnMount&&(M=!1),O.protectedKeys={...w},!O.isActive&&E===null||!T&&!O.prevProp||Rm(T)||typeof T=="boolean")continue;if(_==="exit"&&O.isActive&&E!==!0){O.prevResolvedValues&&(w={...w,...O.prevResolvedValues});continue}const D=mV(O.prevProp,T);let R=D||_===h&&O.isActive&&!M&&N||A>S&&N,B=!1;const q=Array.isArray(T)?T:[T];let z=q.reduce(o(_),{});E===!1&&(z={});const{prevResolvedValues:H={}}=O,X={...H,...z},Y=Q=>{R=!0,j.has(Q)&&(B=!0,j.delete(Q)),O.needsAnimating[Q]=!0;const ie=e.getValue(Q);ie&&(ie.liveStyle=!1)};for(const Q in X){const ie=z[Q],le=H[Q];if(w.hasOwnProperty(Q))continue;let L=!1;_1(ie)&&_1(le)?L=!U4(ie,le)||D:L=ie!==le,L?ie!=null?Y(Q):j.add(Q):ie!==void 0&&j.has(Q)?Y(Q):O.protectedKeys[Q]=!0}O.prevProp=T,O.prevResolvedValues=z,O.isActive&&(w={...w,...z}),(r||i)&&e.blockInitialAnimation&&(R=!1);const $=M&&D;R&&(!$||B)&&x.push(...q.map(Q=>{const ie={type:_};if(typeof Q=="string"&&(r||i)&&!$&&e.manuallyAnimateOnMount&&e.parent){const{parent:le}=e,L=gs(le,Q);if(le.enteringChildren&&L){const{delayChildren:F}=L.transition||{};ie.delay=f4(le.enteringChildren,e,F)}}return{animation:Q,options:ie}}))}if(j.size){const A={};if(typeof p.initial!="boolean"){const _=gs(e,Array.isArray(p.initial)?p.initial[0]:p.initial);_&&_.transition&&(A.transition=_.transition)}j.forEach(_=>{const O=e.getBaseTarget(_),T=e.getValue(_);T&&(T.liveStyle=!0),A[_]=O??null}),x.push({animation:A})}let b=!!x.length;return r&&(p.initial===!1||p.initial===p.animate)&&!e.manuallyAnimateOnMount&&(b=!1),r=!1,i=!1,b?t(x):Promise.resolve()}function d(h,p){var x;if(n[h].isActive===p)return Promise.resolve();(x=e.variantChildren)==null||x.forEach(j=>{var w;return(w=j.animationState)==null?void 0:w.setActive(h,p)}),n[h].isActive=p;const y=f(h);for(const j in n)n[j].protectedKeys={};return y}return{animateChanges:f,setActive:d,setAnimateFunction:c,getState:()=>n,reset:()=>{n=tT(),i=!0}}}function mV(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!U4(t,e):!1}function ns(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function tT(){return{animate:ns(!0),whileInView:ns(),whileHover:ns(),whileTap:ns(),whileDrag:ns(),whileFocus:ns(),exit:ns()}}function L1(e,t){e.min=t.min,e.max=t.max}function _r(e,t){L1(e.x,t.x),L1(e.y,t.y)}function nT(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}const V4=1e-4,pV=1-V4,yV=1+V4,H4=.01,xV=0-H4,gV=0+H4;function vn(e){return e.max-e.min}function vV(e,t,n){return Math.abs(e-t)<=n}function rT(e,t,n,r=.5){e.origin=r,e.originPoint=ut(t.min,t.max,e.origin),e.scale=vn(n)/vn(t),e.translate=ut(n.min,n.max,e.origin)-e.originPoint,(e.scale>=pV&&e.scale<=yV||isNaN(e.scale))&&(e.scale=1),(e.translate>=xV&&e.translate<=gV||isNaN(e.translate))&&(e.translate=0)}function Kc(e,t,n,r){rT(e.x,t.x,n.x,r?r.originX:void 0),rT(e.y,t.y,n.y,r?r.originY:void 0)}function aT(e,t,n,r=0){const i=r?ut(n.min,n.max,r):n.min;e.min=i+t.min,e.max=e.min+vn(t)}function bV(e,t,n,r){aT(e.x,t.x,n.x,r==null?void 0:r.x),aT(e.y,t.y,n.y,r==null?void 0:r.y)}function iT(e,t,n,r=0){const i=r?ut(n.min,n.max,r):n.min;e.min=t.min-i,e.max=e.min+vn(t)}function Sh(e,t,n,r){iT(e.x,t.x,n.x,r==null?void 0:r.x),iT(e.y,t.y,n.y,r==null?void 0:r.y)}function sT(e,t,n,r,i){return e-=t,e=wh(e,1/n,r),i!==void 0&&(e=wh(e,1/i,r)),e}function jV(e,t=0,n=1,r=.5,i,o=e,c=e){if(Yr.test(t)&&(t=parseFloat(t),t=ut(c.min,c.max,t/100)-c.min),typeof t!="number")return;let f=ut(o.min,o.max,r);e===o&&(f-=t),e.min=sT(e.min,t,n,f,i),e.max=sT(e.max,t,n,f,i)}function oT(e,t,[n,r,i],o,c){jV(e,t[n],t[r],t[i],t.scale,o,c)}const wV=["x","scaleX","originX"],SV=["y","scaleY","originY"];function lT(e,t,n,r){oT(e.x,t,wV,n?n.x:void 0,r?r.x:void 0),oT(e.y,t,SV,n?n.y:void 0,r?r.y:void 0)}function cT(e){return e.translate===0&&e.scale===1}function F4(e){return cT(e.x)&&cT(e.y)}function uT(e,t){return e.min===t.min&&e.max===t.max}function NV(e,t){return uT(e.x,t.x)&&uT(e.y,t.y)}function fT(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function G4(e,t){return fT(e.x,t.x)&&fT(e.y,t.y)}function dT(e){return vn(e.x)/vn(e.y)}function hT(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}function Fr(e){return[e("x"),e("y")]}function AV(e,t,n){let r="";const i=e.x.translate/t.x,o=e.y.translate/t.y,c=(n==null?void 0:n.z)||0;if((i||o||c)&&(r=`translate3d(${i}px, ${o}px, ${c}px) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:h,rotate:p,pathRotation:y,rotateX:x,rotateY:j,skewX:w,skewY:S}=n;h&&(r=`perspective(${h}px) ${r}`),p&&(r+=`rotate(${p}deg) `),y&&(r+=`rotate(${y}deg) `),x&&(r+=`rotateX(${x}deg) `),j&&(r+=`rotateY(${j}deg) `),w&&(r+=`skewX(${w}deg) `),S&&(r+=`skewY(${S}deg) `)}const f=e.x.scale*t.x,d=e.y.scale*t.y;return(f!==1||d!==1)&&(r+=`scale(${f}, ${d})`),r||"none"}const OV=Vw.length,mT=e=>typeof e=="string"?parseFloat(e):e,pT=e=>typeof e=="number"||ye.test(e);function _V(e,t,n,r,i,o){i?(e.opacity=ut(0,n.opacity??1,TV(r)),e.opacityExit=ut(t.opacity??1,0,EV(r))):o&&(e.opacity=ut(t.opacity??1,n.opacity??1,r));for(let c=0;c<OV;c++){const f=Vw[c];let d=yT(t,f),h=yT(n,f);if(d===void 0&&h===void 0)continue;d||(d=0),h||(h=0),d===0||h===0||pT(d)===pT(h)?(e[f]=Math.max(ut(mT(d),mT(h),r),0),(Yr.test(h)||Yr.test(d))&&(e[f]+="%")):e[f]=h}(t.rotate||n.rotate)&&(e.rotate=ut(t.rotate||0,n.rotate||0,r))}function yT(e,t){return e[t]!==void 0?e[t]:e.borderRadius}const TV=K4(0,.5,BD),EV=K4(.5,.95,xr);function K4(e,t,n){return r=>r<e?0:r>t?1:n(ru(e,t,r))}function CV(e,t,n){const r=un(e)?e:Io(e);return r.start(qw("",r,t,n)),r.animation}function su(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n,r)}const MV=(e,t)=>e.depth-t.depth;class PV{constructor(){this.children=[],this.isDirty=!1}add(t){_w(this.children,t),this.isDirty=!0}remove(t){ph(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(MV),this.isDirty=!1,this.children.forEach(t)}}function RV(e,t){const n=gn.now(),r=({timestamp:i})=>{const o=i-n;o>=t&&(Ci(r),e(o-t))};return ft.setup(r,!0),()=>Ci(r)}function lh(e){return un(e)?e.get():e}class kV{constructor(){this.members=[]}add(t){_w(this.members,t);for(let n=this.members.length-1;n>=0;n--){const r=this.members[n];if(r===t||r===this.lead||r===this.prevLead)continue;const i=r.instance;(!i||i.isConnected===!1)&&!r.snapshot&&(ph(this.members,r),r.unmount())}t.scheduleRender()}remove(t){if(ph(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){var n;for(let r=this.members.indexOf(t)-1;r>=0;r--){const i=this.members[r];if(i.isPresent!==!1&&((n=i.instance)==null?void 0:n.isConnected)!==!1)return this.promote(i),!0}return!1}promote(t,n){var i;const r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.updateSnapshot(),t.scheduleRender();const{layoutDependency:o}=r.options,{layoutDependency:c}=t.options;(o===void 0||o!==c)&&(t.resumeFrom=r,n&&(r.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),(i=t.root)!=null&&i.isUpdating&&(t.isLayoutDirty=!0)),t.options.crossfade===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{var n,r,i,o,c;(r=(n=t.options).onExitComplete)==null||r.call(n),(c=(i=t.resumingFrom)==null?void 0:(o=i.options).onExitComplete)==null||c.call(o)})}scheduleRender(){this.members.forEach(t=>t.instance&&t.scheduleRender(!1))}removeLeadSnapshot(){var t;(t=this.lead)!=null&&t.snapshot&&(this.lead.snapshot=void 0)}}const ch={hasAnimatedSinceResize:!0,hasEverUpdated:!1},Zx=["","X","Y","Z"],DV=1e3;let zV=0;function Qx(e,t,n,r){const{latestValues:i}=t;i[e]&&(n[e]=i[e],t.setStaticValue(e,0),r&&(r[e]=0))}function Y4(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=y4(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:i,layoutId:o}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",ft,!(i||o))}const{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&Y4(r)}function X4({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return class{constructor(c={},f=t==null?void 0:t()){this.id=zV++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.layoutVersion=0,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(BV),this.nodes.forEach(FV),this.nodes.forEach(GV),this.nodes.forEach(qV)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=c,this.root=f?f.root||f:this,this.path=f?[...f.path,f]:[],this.parent=f,this.depth=f?f.depth+1:0;for(let d=0;d<this.path.length;d++)this.path[d].shouldResetTransform=!0;this.root===this&&(this.nodes=new PV)}addEventListener(c,f){return this.eventHandlers.has(c)||this.eventHandlers.set(c,new Ew),this.eventHandlers.get(c).add(f)}notifyListeners(c,...f){const d=this.eventHandlers.get(c);d&&d.notify(...f)}hasListeners(c){return this.eventHandlers.has(c)}mount(c){if(this.instance)return;this.isSVG=Gw(c)&&!$9(c),this.instance=c;const{layoutId:f,layout:d,visualElement:h}=this.options;if(h&&!h.current&&h.mount(c),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.root.hasTreeAnimated&&(d||f)&&(this.isLayoutDirty=!0),e){let p,y=0;const x=()=>this.root.updateBlockedByResize=!1;ft.read(()=>{y=window.innerWidth}),e(c,()=>{const j=window.innerWidth;j!==y&&(y=j,this.root.updateBlockedByResize=!0,p&&p(),p=RV(x,250),ch.hasAnimatedSinceResize&&(ch.hasAnimatedSinceResize=!1,this.nodes.forEach(vT)))})}f&&this.root.registerSharedNode(f,this),this.options.animate!==!1&&h&&(f||d)&&this.addEventListener("didUpdate",({delta:p,hasLayoutChanged:y,hasRelativeLayoutChanged:x,layout:j})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const w=this.options.transition||h.getDefaultTransition()||ZV,{onLayoutAnimationStart:S,onLayoutAnimationComplete:b}=h.getProps(),A=!this.targetLayout||!G4(this.targetLayout,j),_=!y&&x;if(this.options.layoutRoot||this.resumeFrom||_||y&&(A||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const O={...Bw(w,"layout"),onPlay:S,onComplete:b};(h.shouldReduceMotion||this.options.layoutRoot)&&(O.delay=0,O.type=!1),this.startAnimation(O),this.setAnimationOrigin(p,_,O.path)}else y||vT(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=j})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const c=this.getStack();c&&c.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),Ci(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(KV),this.animationId++)}getTransformTemplate(){const{visualElement:c}=this.options;return c&&c.getProps().transformTemplate}willUpdate(c=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&Y4(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let p=0;p<this.path.length;p++){const y=this.path[p];y.shouldResetTransform=!0,(typeof y.latestValues.x=="string"||typeof y.latestValues.y=="string")&&(y.isLayoutDirty=!0),y.updateScroll("snapshot"),y.options.layoutRoot&&y.willUpdate(!1)}const{layoutId:f,layout:d}=this.options;if(f===void 0&&!d)return;const h=this.getTransformTemplate();this.prevTransformTemplateValue=h?h(this.latestValues,""):void 0,this.updateSnapshot(),c&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){const d=this.updateBlockedByResize;this.unblockUpdate(),this.updateBlockedByResize=!1,this.clearAllSnapshots(),d&&this.nodes.forEach(UV),this.nodes.forEach(xT);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(gT);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(VV),this.nodes.forEach(HV),this.nodes.forEach(LV),this.nodes.forEach($V)):this.nodes.forEach(gT),this.clearAllSnapshots();const f=gn.now();cn.delta=Qr(0,1e3/60,f-cn.timestamp),cn.timestamp=f,cn.isProcessing=!0,Vx.update.process(cn),Vx.preRender.process(cn),Vx.render.process(cn),cn.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,Hw.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(IV),this.sharedNodes.forEach(YV)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,ft.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){ft.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!vn(this.snapshot.measuredBox.x)&&!vn(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let d=0;d<this.path.length;d++)this.path[d].updateScroll();const c=this.layout;this.layout=this.measure(!1),this.layoutVersion++,this.layoutCorrected||(this.layoutCorrected=Gt()),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:f}=this.options;f&&f.notify("LayoutMeasure",this.layout.layoutBox,c?c.layoutBox:void 0)}updateScroll(c="measure"){let f=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===c&&(f=!1),f&&this.instance){const d=r(this.instance);this.scroll={animationId:this.root.animationId,phase:c,isRoot:d,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:d}}}resetTransform(){if(!i)return;const c=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,f=this.projectionDelta&&!F4(this.projectionDelta),d=this.getTransformTemplate(),h=d?d(this.latestValues,""):void 0,p=h!==this.prevTransformTemplateValue;c&&this.instance&&(f||ss(this.latestValues)||p)&&(i(this.instance,h),this.shouldResetTransform=!1,this.scheduleRender())}measure(c=!0){const f=this.measurePageBox();let d=this.removeElementScroll(f);return c&&(d=this.removeTransform(d)),QV(d),{animationId:this.root.animationId,measuredBox:f,layoutBox:d,latestValues:{},source:this.id}}measurePageBox(){var h;const{visualElement:c}=this.options;if(!c)return Gt();const f=c.measureViewportBox();if(!(((h=this.scroll)==null?void 0:h.wasRoot)||this.path.some(JV))){const{scroll:p}=this.root;p&&(Gr(f.x,p.offset.x),Gr(f.y,p.offset.y))}return f}removeElementScroll(c){var d;const f=Gt();if(_r(f,c),(d=this.scroll)!=null&&d.wasRoot)return f;for(let h=0;h<this.path.length;h++){const p=this.path[h],{scroll:y,options:x}=p;p!==this.root&&y&&x.layoutScroll&&(y.wasRoot&&_r(f,c),Gr(f.x,y.offset.x),Gr(f.y,y.offset.y))}return f}applyTransform(c,f=!1,d){var p,y;const h=d||Gt();_r(h,c);for(let x=0;x<this.path.length;x++){const j=this.path[x];!f&&j.options.layoutScroll&&j.scroll&&j!==j.root&&(Gr(h.x,-j.scroll.offset.x),Gr(h.y,-j.scroll.offset.y)),ss(j.latestValues)&&oh(h,j.latestValues,(p=j.layout)==null?void 0:p.layoutBox)}return ss(this.latestValues)&&oh(h,this.latestValues,(y=this.layout)==null?void 0:y.layoutBox),h}removeTransform(c){var d;const f=Gt();_r(f,c);for(let h=0;h<this.path.length;h++){const p=this.path[h];if(!ss(p.latestValues))continue;let y;p.instance&&(k1(p.latestValues)&&p.updateSnapshot(),y=Gt(),_r(y,p.measurePageBox())),lT(f,p.latestValues,(d=p.snapshot)==null?void 0:d.layoutBox,y)}return ss(this.latestValues)&&lT(f,this.latestValues),f}setTargetDelta(c){this.targetDelta=c,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(c){this.options={...this.options,...c,crossfade:c.crossfade!==void 0?c.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==cn.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(c=!1){var j;const f=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=f.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=f.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=f.isSharedProjectionDirty);const d=!!this.resumingFrom||this!==f;if(!(c||d&&this.isSharedProjectionDirty||this.isProjectionDirty||(j=this.parent)!=null&&j.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:p,layoutId:y}=this.options;if(!this.layout||!(p||y))return;this.resolvedRelativeTargetAt=cn.timestamp;const x=this.getClosestProjectingParent();x&&this.linkedParentVersion!==x.layoutVersion&&!x.options.layoutRoot&&this.removeRelativeTarget(),!this.targetDelta&&!this.relativeTarget&&(this.options.layoutAnchor!==!1&&x&&x.layout?this.createRelativeTarget(x,this.layout.layoutBox,x.layout.layoutBox):this.removeRelativeTarget()),!(!this.relativeTarget&&!this.targetDelta)&&(this.target||(this.target=Gt(),this.targetWithTransforms=Gt()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),bV(this.target,this.relativeTarget,this.relativeParent.target,this.options.layoutAnchor||void 0)):this.targetDelta?(this.resumingFrom?this.applyTransform(this.layout.layoutBox,!1,this.target):_r(this.target,this.layout.layoutBox),R4(this.target,this.targetDelta)):_r(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget&&(this.attemptToResolveRelativeTarget=!1,this.options.layoutAnchor!==!1&&x&&!!x.resumingFrom==!!this.resumingFrom&&!x.options.layoutScroll&&x.target&&this.animationProgress!==1?this.createRelativeTarget(x,this.target,x.target):this.relativeParent=this.relativeTarget=void 0))}getClosestProjectingParent(){if(!(!this.parent||k1(this.parent.latestValues)||P4(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}createRelativeTarget(c,f,d){this.relativeParent=c,this.linkedParentVersion=c.layoutVersion,this.forceRelativeParentToResolveTarget(),this.relativeTarget=Gt(),this.relativeTargetOrigin=Gt(),Sh(this.relativeTargetOrigin,f,d,this.options.layoutAnchor||void 0),_r(this.relativeTarget,this.relativeTargetOrigin)}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0}calcProjection(){var w;const c=this.getLead(),f=!!this.resumingFrom||this!==c;let d=!0;if((this.isProjectionDirty||(w=this.parent)!=null&&w.isProjectionDirty)&&(d=!1),f&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(d=!1),this.resolvedRelativeTargetAt===cn.timestamp&&(d=!1),d)return;const{layout:h,layoutId:p}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(h||p))return;_r(this.layoutCorrected,this.layout.layoutBox);const y=this.treeScale.x,x=this.treeScale.y;X9(this.layoutCorrected,this.treeScale,this.path,f),c.layout&&!c.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(c.target=c.layout.layoutBox,c.targetWithTransforms=Gt());const{target:j}=c;if(!j){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(nT(this.prevProjectionDelta.x,this.projectionDelta.x),nT(this.prevProjectionDelta.y,this.projectionDelta.y)),Kc(this.projectionDelta,this.layoutCorrected,j,this.latestValues),(this.treeScale.x!==y||this.treeScale.y!==x||!hT(this.projectionDelta.x,this.prevProjectionDelta.x)||!hT(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",j))}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(c=!0){var f;if((f=this.options.visualElement)==null||f.scheduleRender(),c){const d=this.getStack();d&&d.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=To(),this.projectionDelta=To(),this.projectionDeltaWithTransform=To()}setAnimationOrigin(c,f=!1,d){const h=this.snapshot,p=h?h.latestValues:{},y={...this.latestValues},x=To();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!f;const j=Gt(),w=h?h.source:void 0,S=this.layout?this.layout.source:void 0,b=w!==S,A=this.getStack(),_=!A||A.members.length<=1,O=!!(b&&!_&&this.options.crossfade===!0&&!this.path.some(WV));this.animationProgress=0;let T;const N=d==null?void 0:d.interpolateProjection(c);this.mixTargetDelta=E=>{const M=E/1e3,D=N==null?void 0:N(M);D?(x.x.translate=D.x,x.x.scale=ut(c.x.scale,1,M),x.x.origin=c.x.origin,x.x.originPoint=c.x.originPoint,x.y.translate=D.y,x.y.scale=ut(c.y.scale,1,M),x.y.origin=c.y.origin,x.y.originPoint=c.y.originPoint):(bT(x.x,c.x,M),bT(x.y,c.y,M)),this.setTargetDelta(x),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(Sh(j,this.layout.layoutBox,this.relativeParent.layout.layoutBox,this.options.layoutAnchor||void 0),XV(this.relativeTarget,this.relativeTargetOrigin,j,M),T&&NV(this.relativeTarget,T)&&(this.isProjectionDirty=!1),T||(T=Gt()),_r(T,this.relativeTarget)),b&&(this.animationValues=y,_V(y,p,this.latestValues,M,O,_)),D&&D.rotate!==void 0&&(this.animationValues||(this.animationValues=y),this.animationValues.pathRotation=D.rotate),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=M},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(c){var f,d,h;this.notifyListeners("animationStart"),(f=this.currentAnimation)==null||f.stop(),(h=(d=this.resumingFrom)==null?void 0:d.currentAnimation)==null||h.stop(),this.pendingAnimation&&(Ci(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=ft.update(()=>{ch.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=Io(0)),this.motionValue.jump(0,!1),this.currentAnimation=CV(this.motionValue,[0,1e3],{...c,velocity:0,isSync:!0,onUpdate:p=>{this.mixTargetDelta(p),c.onUpdate&&c.onUpdate(p)},onComplete:()=>{c.onComplete&&c.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const c=this.getStack();c&&c.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(DV),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const c=this.getLead();let{targetWithTransforms:f,target:d,layout:h,latestValues:p}=c;if(!(!f||!d||!h)){if(this!==c&&this.layout&&h&&W4(this.options.animationType,this.layout.layoutBox,h.layoutBox)){d=this.target||Gt();const y=vn(this.layout.layoutBox.x);d.x.min=c.target.x.min,d.x.max=d.x.min+y;const x=vn(this.layout.layoutBox.y);d.y.min=c.target.y.min,d.y.max=d.y.min+x}_r(f,d),oh(f,p),Kc(this.projectionDeltaWithTransform,this.layoutCorrected,f,p)}}registerSharedNode(c,f){this.sharedNodes.has(c)||this.sharedNodes.set(c,new kV),this.sharedNodes.get(c).add(f);const h=f.options.initialPromotionConfig;f.promote({transition:h?h.transition:void 0,preserveFollowOpacity:h&&h.shouldPreserveFollowOpacity?h.shouldPreserveFollowOpacity(f):void 0})}isLead(){const c=this.getStack();return c?c.lead===this:!0}getLead(){var f;const{layoutId:c}=this.options;return c?((f=this.getStack())==null?void 0:f.lead)||this:this}getPrevLead(){var f;const{layoutId:c}=this.options;return c?(f=this.getStack())==null?void 0:f.prevLead:void 0}getStack(){const{layoutId:c}=this.options;if(c)return this.root.sharedNodes.get(c)}promote({needsReset:c,transition:f,preserveFollowOpacity:d}={}){const h=this.getStack();h&&h.promote(this,d),c&&(this.projectionDelta=void 0,this.needsReset=!0),f&&this.setOptions({transition:f})}relegate(){const c=this.getStack();return c?c.relegate(this):!1}resetSkewAndRotation(){const{visualElement:c}=this.options;if(!c)return;let f=!1;const{latestValues:d}=c;if((d.z||d.rotate||d.rotateX||d.rotateY||d.rotateZ||d.skewX||d.skewY)&&(f=!0),!f)return;const h={};d.z&&Qx("z",c,h,this.animationValues);for(let p=0;p<Zx.length;p++)Qx(`rotate${Zx[p]}`,c,h,this.animationValues),Qx(`skew${Zx[p]}`,c,h,this.animationValues);c.render();for(const p in h)c.setStaticValue(p,h[p]),this.animationValues&&(this.animationValues[p]=h[p]);c.scheduleRender()}applyProjectionStyles(c,f){if(!this.instance||this.isSVG)return;if(!this.isVisible){c.visibility="hidden";return}const d=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,c.visibility="",c.opacity="",c.pointerEvents=lh(f==null?void 0:f.pointerEvents)||"",c.transform=d?d(this.latestValues,""):"none";return}const h=this.getLead();if(!this.projectionDelta||!this.layout||!h.target){this.options.layoutId&&(c.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,c.pointerEvents=lh(f==null?void 0:f.pointerEvents)||""),this.hasProjected&&!ss(this.latestValues)&&(c.transform=d?d({},""):"none",this.hasProjected=!1);return}c.visibility="";const p=h.animationValues||h.latestValues;this.applyTransformsToTarget();let y=AV(this.projectionDeltaWithTransform,this.treeScale,p);d&&(y=d(p,y)),c.transform=y;const{x,y:j}=this.projectionDelta;c.transformOrigin=`${x.origin*100}% ${j.origin*100}% 0`,h.animationValues?c.opacity=h===this?p.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:p.opacityExit:c.opacity=h===this?p.opacity!==void 0?p.opacity:"":p.opacityExit!==void 0?p.opacityExit:0;for(const w in z1){if(p[w]===void 0)continue;const{correct:S,applyTo:b,isCSSVariable:A}=z1[w],_=y==="none"?p[w]:S(p[w],h);if(b){const O=b.length;for(let T=0;T<O;T++)c[b[T]]=_}else A?this.options.visualElement.renderState.vars[w]=_:c[w]=_}this.options.layoutId&&(c.pointerEvents=h===this?lh(f==null?void 0:f.pointerEvents)||"":"none")}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(c=>{var f;return(f=c.currentAnimation)==null?void 0:f.stop()}),this.root.nodes.forEach(xT),this.root.sharedNodes.clear()}}}function LV(e){e.updateLayout()}function $V(e){var n;const t=((n=e.resumeFrom)==null?void 0:n.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners("didUpdate")){const{layoutBox:r,measuredBox:i}=e.layout,{animationType:o}=e.options,c=t.source!==e.layout.source;if(o==="size")Fr(y=>{const x=c?t.measuredBox[y]:t.layoutBox[y],j=vn(x);x.min=r[y].min,x.max=x.min+j});else if(o==="x"||o==="y"){const y=o==="x"?"y":"x";L1(c?t.measuredBox[y]:t.layoutBox[y],r[y])}else W4(o,t.layoutBox,r)&&Fr(y=>{const x=c?t.measuredBox[y]:t.layoutBox[y],j=vn(r[y]);x.max=x.min+j,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[y].max=e.relativeTarget[y].min+j)});const f=To();Kc(f,r,t.layoutBox);const d=To();c?Kc(d,e.applyTransform(i,!0),t.measuredBox):Kc(d,r,t.layoutBox);const h=!F4(f);let p=!1;if(!e.resumeFrom){const y=e.getClosestProjectingParent();if(y&&!y.resumeFrom){const{snapshot:x,layout:j}=y;if(x&&j){const w=e.options.layoutAnchor||void 0,S=Gt();Sh(S,t.layoutBox,x.layoutBox,w);const b=Gt();Sh(b,r,j.layoutBox,w),G4(S,b)||(p=!0),y.options.layoutRoot&&(e.relativeTarget=b,e.relativeTargetOrigin=S,e.relativeParent=y)}}}e.notifyListeners("didUpdate",{layout:r,snapshot:t,delta:d,layoutDelta:f,hasLayoutChanged:h,hasRelativeLayoutChanged:p})}else if(e.isLead()){const{onExitComplete:r}=e.options;r&&r()}e.options.transition=void 0}function BV(e){e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function qV(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function IV(e){e.clearSnapshot()}function xT(e){e.clearMeasurements()}function UV(e){e.isLayoutDirty=!0,e.updateLayout()}function gT(e){e.isLayoutDirty=!1}function VV(e){e.isAnimationBlocked&&e.layout&&!e.isLayoutDirty&&(e.snapshot=e.layout,e.isLayoutDirty=!0)}function HV(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function vT(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function FV(e){e.resolveTargetDelta()}function GV(e){e.calcProjection()}function KV(e){e.resetSkewAndRotation()}function YV(e){e.removeLeadSnapshot()}function bT(e,t,n){e.translate=ut(t.translate,0,n),e.scale=ut(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function jT(e,t,n,r){e.min=ut(t.min,n.min,r),e.max=ut(t.max,n.max,r)}function XV(e,t,n,r){jT(e.x,t.x,n.x,r),jT(e.y,t.y,n.y,r)}function WV(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const ZV={duration:.45,ease:[.4,0,.1,1]},wT=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),ST=wT("applewebkit/")&&!wT("chrome/")?Math.round:xr;function NT(e){e.min=ST(e.min),e.max=ST(e.max)}function QV(e){NT(e.x),NT(e.y)}function W4(e,t,n){return e==="position"||e==="preserve-aspect"&&!vV(dT(t),dT(n),.2)}function JV(e){var t;return e!==e.root&&((t=e.scroll)==null?void 0:t.wasRoot)}const e7=X4({attachResizeListener:(e,t)=>su(e,"resize",t),measureScroll:()=>{var e,t;return{x:document.documentElement.scrollLeft||((e=document.body)==null?void 0:e.scrollLeft)||0,y:document.documentElement.scrollTop||((t=document.body)==null?void 0:t.scrollTop)||0}},checkIsScrollRoot:()=>!0}),Jx={current:void 0},Z4=X4({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!Jx.current){const e=new e7({});e.mount(window),e.setOptions({layoutScroll:!0}),Jx.current=e}return Jx.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),Zw=P.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});function AT(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function t7(...e){return t=>{let n=!1;const r=e.map(i=>{const o=AT(i,t);return!n&&typeof o=="function"&&(n=!0),o});if(n)return()=>{for(let i=0;i<r.length;i++){const o=r[i];typeof o=="function"?o():AT(e[i],null)}}}}function n7(...e){return P.useCallback(t7(...e),e)}class r7 extends P.Component{getSnapshotBeforeUpdate(t){const n=this.props.childRef.current;if(rh(n)&&t.isPresent&&!this.props.isPresent&&this.props.pop!==!1){const r=n.offsetParent,i=rh(r)&&r.offsetWidth||0,o=rh(r)&&r.offsetHeight||0,c=getComputedStyle(n),f=this.props.sizeRef.current;f.height=parseFloat(c.height),f.width=parseFloat(c.width),f.top=n.offsetTop,f.left=n.offsetLeft,f.right=i-f.width-f.left,f.bottom=o-f.height-f.top,f.direction=c.direction}return null}componentDidUpdate(){}render(){return this.props.children}}function a7({children:e,isPresent:t,anchorX:n,anchorY:r,root:i,pop:o}){var x;const c=P.useId(),f=P.useRef(null),d=P.useRef({width:0,height:0,top:0,left:0,right:0,bottom:0,direction:"ltr"}),{nonce:h}=P.useContext(Zw),p=((x=e.props)==null?void 0:x.ref)??(e==null?void 0:e.ref),y=n7(f,p);return P.useInsertionEffect(()=>{const{width:j,height:w,top:S,left:b,right:A,bottom:_,direction:O}=d.current;if(t||o===!1||!f.current||!j||!w)return;const T=O==="rtl",N=n==="left"?T?`right: ${A}`:`left: ${b}`:T?`left: ${b}`:`right: ${A}`,E=r==="bottom"?`bottom: ${_}`:`top: ${S}`;f.current.dataset.motionPopId=c;const M=document.createElement("style");h&&(M.nonce=h);const D=i??document.head;return D.appendChild(M),M.sheet&&M.sheet.insertRule(`
|
||
[data-motion-pop-id="${c}"] {
|
||
position: absolute !important;
|
||
width: ${j}px !important;
|
||
height: ${w}px !important;
|
||
${N}px !important;
|
||
${E}px !important;
|
||
}
|
||
`),()=>{var R;(R=f.current)==null||R.removeAttribute("data-motion-pop-id"),D.contains(M)&&D.removeChild(M)}},[t]),l.jsx(r7,{isPresent:t,childRef:f,sizeRef:d,pop:o,children:o===!1?e:P.cloneElement(e,{ref:y})})}const i7=({children:e,initial:t,isPresent:n,onExitComplete:r,custom:i,presenceAffectsLayout:o,mode:c,anchorX:f,anchorY:d,root:h})=>{const p=Aw(s7),y=P.useId(),x=P.useRef(n),j=P.useRef(r);Ow(()=>{x.current=n,j.current=r});let w=!0,S=P.useMemo(()=>(w=!1,{id:y,initial:t,isPresent:n,custom:i,onExitComplete:b=>{p.set(b,!0);for(const A of p.values())if(!A)return;r&&r()},register:b=>(p.set(b,!1),()=>{var A;p.delete(b),!x.current&&!p.size&&((A=j.current)==null||A.call(j))})}),[n,p,r]);return o&&w&&(S={...S}),P.useMemo(()=>{p.forEach((b,A)=>p.set(A,!1))},[n]),P.useEffect(()=>{!n&&!p.size&&r&&r()},[n]),e=l.jsx(a7,{pop:c==="popLayout",isPresent:n,anchorX:f,anchorY:d,root:h,children:e}),l.jsx(Mm.Provider,{value:S,children:e})};function s7(){return new Map}function Q4(e=!0){const t=P.useContext(Mm);if(t===null)return[!0,null];const{isPresent:n,onExitComplete:r,register:i}=t,o=P.useId();P.useEffect(()=>{if(e)return i(o)},[e]);const c=P.useCallback(()=>e&&r&&r(o),[o,r,e]);return!n&&r?[!1,c]:[!0]}const Cd=e=>e.key||"";function OT(e){const t=[];return P.Children.forEach(e,n=>{P.isValidElement(n)&&t.push(n)}),t}const ds=({children:e,custom:t,initial:n=!0,onExitComplete:r,presenceAffectsLayout:i=!0,mode:o="sync",propagate:c=!1,anchorX:f="left",anchorY:d="top",root:h})=>{const[p,y]=Q4(c),x=P.useMemo(()=>OT(e),[e]),j=c&&!p?[]:x.map(Cd),w=P.useRef(!0),S=P.useRef(x),b=Aw(()=>new Map),A=P.useRef(new Set),[_,O]=P.useState(x),[T,N]=P.useState(x);Ow(()=>{w.current=!1,S.current=x;for(let D=0;D<T.length;D++){const R=Cd(T[D]);j.includes(R)?(b.delete(R),A.current.delete(R)):b.get(R)!==!0&&b.set(R,!1)}},[T,j.length,j.join("-")]);const E=[];if(x!==_){let D=[...x];for(let R=0;R<T.length;R++){const B=T[R],q=Cd(B);j.includes(q)||(D.splice(R,0,B),E.push(B))}return o==="wait"&&E.length&&(D=E),N(OT(D)),O(x),null}const{forceRender:M}=P.useContext(Nw);return l.jsx(l.Fragment,{children:T.map(D=>{const R=Cd(D),B=c&&!p?!1:x===T||j.includes(R),q=()=>{if(A.current.has(R))return;if(b.has(R))A.current.add(R),b.set(R,!0);else return;let z=!0;b.forEach(H=>{H||(z=!1)}),z&&(M==null||M(),N(S.current),c&&(y==null||y()),r&&r())};return l.jsx(i7,{isPresent:B,initial:!w.current||n?void 0:!1,custom:t,presenceAffectsLayout:i,mode:o,root:h,onExitComplete:B?void 0:q,anchorX:f,anchorY:d,children:D},R)})})},J4=P.createContext({strict:!1}),_T={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]};let TT=!1;function o7(){if(TT)return;const e={};for(const t in _T)e[t]={isEnabled:n=>_T[t].some(r=>!!n[r])};E4(e),TT=!0}function ez(){return o7(),F9()}function l7(e){const t=ez();for(const n in e)t[n]={...t[n],...e[n]};E4(t)}const c7=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","propagate","ignoreStrict","viewport"]);function Nh(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||c7.has(e)}let tz=e=>!Nh(e);function u7(e){typeof e=="function"&&(tz=t=>t.startsWith("on")?!Nh(t):e(t))}try{u7(require("@emotion/is-prop-valid").default)}catch{}function f7(e,t,n){const r={};for(const i in e)i==="values"&&typeof e.values=="object"||un(e[i])||(tz(i)||n===!0&&Nh(i)||!t&&!Nh(i)||e.draggable&&i.startsWith("onDrag"))&&(r[i]=e[i]);return r}const Dm=P.createContext({});function d7(e,t){if(km(e)){const{initial:n,animate:r}=e;return{initial:n===!1||iu(n)?n:void 0,animate:iu(r)?r:void 0}}return e.inherit!==!1?t:{}}function h7(e){const{initial:t,animate:n}=d7(e,P.useContext(Dm));return P.useMemo(()=>({initial:t,animate:n}),[ET(t),ET(n)])}function ET(e){return Array.isArray(e)?e.join(" "):e}const Qw=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function nz(e,t,n){for(const r in t)!un(t[r])&&!z4(r,n)&&(e[r]=t[r])}function m7({transformTemplate:e},t){return P.useMemo(()=>{const n=Qw();return Xw(n,t,e),Object.assign({},n.vars,n.style)},[t])}function p7(e,t){const n=e.style||{},r={};return nz(r,n,e),Object.assign(r,m7(e,t)),r}function y7(e,t){const n={},r=p7(e,t);return e.drag&&e.dragListener!==!1&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=r,n}const rz=()=>({...Qw(),attrs:{}});function x7(e,t,n,r){const i=P.useMemo(()=>{const o=rz();return L4(o,t,B4(r),e.transformTemplate,e.style),{...o.attrs,style:{...o.style}}},[t]);if(e.style){const o={};nz(o,e.style,e),i.style={...o,...i.style}}return i}const g7=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function Jw(e){return typeof e!="string"||e.includes("-")?!1:!!(g7.indexOf(e)>-1||/[A-Z]/u.test(e))}function v7(e,t,n,{latestValues:r},i,o=!1,c){const d=(c??Jw(e)?x7:y7)(t,r,i,e),h=f7(t,typeof e=="string",o),p=e!==P.Fragment?{...h,...d,ref:n}:{},{children:y}=t,x=P.useMemo(()=>un(y)?y.get():y,[y]);return P.createElement(e,{...p,children:x})}function b7({scrapeMotionValuesFromProps:e,createRenderState:t},n,r,i){return{latestValues:j7(n,r,i,e),renderState:t()}}function j7(e,t,n,r){const i={},o=r(e,{});for(const x in o)i[x]=lh(o[x]);let{initial:c,animate:f}=e;const d=km(e),h=_4(e);t&&h&&!d&&e.inherit!==!1&&(c===void 0&&(c=t.initial),f===void 0&&(f=t.animate));let p=n?n.initial===!1:!1;p=p||c===!1;const y=p?f:c;if(y&&typeof y!="boolean"&&!Rm(y)){const x=Array.isArray(y)?y:[y];for(let j=0;j<x.length;j++){const w=Iw(e,x[j]);if(w){const{transitionEnd:S,transition:b,...A}=w;for(const _ in A){let O=A[_];if(Array.isArray(O)){const T=p?O.length-1:0;O=O[T]}O!==null&&(i[_]=O)}for(const _ in S)i[_]=S[_]}}}return i}const az=e=>(t,n)=>{const r=P.useContext(Dm),i=P.useContext(Mm),o=()=>b7(e,t,r,i);return n?o():Aw(o)},w7=az({scrapeMotionValuesFromProps:Ww,createRenderState:Qw}),S7=az({scrapeMotionValuesFromProps:q4,createRenderState:rz}),N7=Symbol.for("motionComponentSymbol");function A7(e,t,n){const r=P.useRef(n);P.useInsertionEffect(()=>{r.current=n});const i=P.useRef(null);return P.useCallback(o=>{var f;o&&((f=e.onMount)==null||f.call(e,o)),t&&(o?t.mount(o):t.unmount());const c=r.current;if(typeof c=="function")if(o){const d=c(o);typeof d=="function"&&(i.current=d)}else i.current?(i.current(),i.current=null):c(o);else c&&(c.current=o)},[t])}const iz=P.createContext({});function No(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function O7(e,t,n,r,i,o){var O,T;const{visualElement:c}=P.useContext(Dm),f=P.useContext(J4),d=P.useContext(Mm),h=P.useContext(Zw),p=h.reducedMotion,y=h.skipAnimations,x=P.useRef(null),j=P.useRef(!1);r=r||f.renderer,!x.current&&r&&(x.current=r(e,{visualState:t,parent:c,props:n,presenceContext:d,blockInitialAnimation:d?d.initial===!1:!1,reducedMotionConfig:p,skipAnimations:y,isSVG:o}),j.current&&x.current&&(x.current.manuallyAnimateOnMount=!0));const w=x.current,S=P.useContext(iz);w&&!w.projection&&i&&(w.type==="html"||w.type==="svg")&&_7(x.current,n,i,S);const b=P.useRef(!1);P.useInsertionEffect(()=>{w&&b.current&&w.update(n,d)});const A=n[p4],_=P.useRef(!!A&&typeof window<"u"&&!((O=window.MotionHandoffIsComplete)!=null&&O.call(window,A))&&((T=window.MotionHasOptimisedAnimation)==null?void 0:T.call(window,A)));return Ow(()=>{j.current=!0,w&&(b.current=!0,window.MotionIsMounted=!0,w.updateFeatures(),w.scheduleRenderMicrotask(),_.current&&w.animationState&&w.animationState.animateChanges())}),P.useEffect(()=>{w&&(!_.current&&w.animationState&&w.animationState.animateChanges(),_.current&&(queueMicrotask(()=>{var N;(N=window.MotionHandoffMarkAsComplete)==null||N.call(window,A)}),_.current=!1),w.enteringChildren=void 0)}),w}function _7(e,t,n,r){const{layoutId:i,layout:o,drag:c,dragConstraints:f,layoutScroll:d,layoutRoot:h,layoutAnchor:p,layoutCrossfade:y}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:sz(e.parent)),e.projection.setOptions({layoutId:i,layout:o,alwaysMeasureLayout:!!c||f&&No(f),visualElement:e,animationType:typeof o=="string"?o:"both",initialPromotionConfig:r,crossfade:y,layoutScroll:d,layoutRoot:h,layoutAnchor:p})}function sz(e){if(e)return e.options.allowProjection!==!1?e.projection:sz(e.parent)}function eg(e,{forwardMotionProps:t=!1,type:n}={},r,i){r&&l7(r);const o=n?n==="svg":Jw(e),c=o?S7:w7;function f(h,p){let y;const x={...P.useContext(Zw),...h,layoutId:T7(h)},{isStatic:j}=x,w=h7(h),S=c(h,j);if(!j&&typeof window<"u"){E7();const b=C7(x);y=b.MeasureLayout,w.visualElement=O7(e,S,x,i,b.ProjectionNode,o)}return l.jsxs(Dm.Provider,{value:w,children:[y&&w.visualElement?l.jsx(y,{visualElement:w.visualElement,...x}):null,v7(e,h,A7(S,w.visualElement,p),S,j,t,o)]})}f.displayName=`motion.${typeof e=="string"?e:`create(${e.displayName??e.name??""})`}`;const d=P.forwardRef(f);return d[N7]=e,d}function T7({layoutId:e}){const t=P.useContext(Nw).id;return t&&e!==void 0?t+"-"+e:e}function E7(e,t){P.useContext(J4).strict}function C7(e){const t=ez(),{drag:n,layout:r}=t;if(!n&&!r)return{};const i={...n,...r};return{MeasureLayout:n!=null&&n.isEnabled(e)||r!=null&&r.isEnabled(e)?i.MeasureLayout:void 0,ProjectionNode:i.ProjectionNode}}function M7(e,t){if(typeof Proxy>"u")return eg;const n=new Map,r=(o,c)=>eg(o,c,e,t),i=(o,c)=>r(o,c);return new Proxy(i,{get:(o,c)=>c==="create"?r:(n.has(c)||n.set(c,eg(c,void 0,e,t)),n.get(c))})}const P7=(e,t)=>t.isSVG??Jw(e)?new lV(t):new nV(t,{allowProjection:e!==P.Fragment});class R7 extends Ri{constructor(t){super(t),t.animationState||(t.animationState=hV(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();Rm(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){var t;this.node.animationState.reset(),(t=this.unmountControls)==null||t.call(this)}}let k7=0;class D7 extends Ri{constructor(){super(...arguments),this.id=k7++,this.isExitComplete=!1}update(){var o;if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n}=this.node.presenceContext,{isPresent:r}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===r)return;if(t&&r===!1){if(this.isExitComplete){const{initial:c,custom:f}=this.node.getProps();if(typeof c=="string"||typeof c=="object"&&c!==null&&!Array.isArray(c)){const d=gs(this.node,c,f);if(d){const{transition:h,transitionEnd:p,...y}=d;for(const x in y)(o=this.node.getValue(x))==null||o.jump(y[x])}}this.node.animationState.reset(),this.node.animationState.animateChanges()}else this.node.animationState.setActive("exit",!1);this.isExitComplete=!1;return}const i=this.node.animationState.setActive("exit",!t);n&&!t&&i.then(()=>{this.isExitComplete=!0,n(this.id)})}mount(){const{register:t,onExitComplete:n}=this.node.presenceContext||{};n&&n(this.id),t&&(this.unmount=t(this.id))}unmount(){}}const z7={animation:{Feature:R7},exit:{Feature:D7}};function Yu(e){return{point:{x:e.pageX,y:e.pageY}}}const L7=e=>t=>Fw(t)&&e(t,Yu(t));function Yc(e,t,n,r){return su(e,t,L7(n),r)}const oz=({current:e})=>e?e.ownerDocument.defaultView:null,CT=(e,t)=>Math.abs(e-t);function $7(e,t){const n=CT(e.x,t.x),r=CT(e.y,t.y);return Math.sqrt(n**2+r**2)}const MT=new Set(["auto","scroll"]);class lz{constructor(t,n,{transformPagePoint:r,contextWindow:i=window,dragSnapToOrigin:o=!1,distanceThreshold:c=3,element:f}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.lastRawMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.scrollPositions=new Map,this.removeScrollListeners=null,this.onElementScroll=w=>{this.handleScroll(w.target)},this.onWindowScroll=()=>{this.handleScroll(window)},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;this.lastRawMoveEventInfo&&(this.lastMoveEventInfo=Md(this.lastRawMoveEventInfo,this.transformPagePoint));const w=tg(this.lastMoveEventInfo,this.history),S=this.startEvent!==null,b=$7(w.offset,{x:0,y:0})>=this.distanceThreshold;if(!S&&!b)return;const{point:A}=w,{timestamp:_}=cn;this.history.push({...A,timestamp:_});const{onStart:O,onMove:T}=this.handlers;S||(O&&O(this.lastMoveEvent,w),this.startEvent=this.lastMoveEvent),T&&T(this.lastMoveEvent,w)},this.handlePointerMove=(w,S)=>{this.lastMoveEvent=w,this.lastRawMoveEventInfo=S,this.lastMoveEventInfo=Md(S,this.transformPagePoint),ft.update(this.updatePoint,!0)},this.handlePointerUp=(w,S)=>{this.end();const{onEnd:b,onSessionEnd:A,resumeAnimation:_}=this.handlers;if((this.dragSnapToOrigin||!this.startEvent)&&_&&_(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const O=tg(w.type==="pointercancel"?this.lastMoveEventInfo:Md(S,this.transformPagePoint),this.history);this.startEvent&&b&&b(w,O),A&&A(w,O)},!Fw(t))return;this.dragSnapToOrigin=o,this.handlers=n,this.transformPagePoint=r,this.distanceThreshold=c,this.contextWindow=i||window;const d=Yu(t),h=Md(d,this.transformPagePoint),{point:p}=h,{timestamp:y}=cn;this.history=[{...p,timestamp:y}];const{onSessionStart:x}=n;x&&x(t,tg(h,this.history));const j={passive:!0,capture:!0};this.removeListeners=Fu(Yc(this.contextWindow,"pointermove",this.handlePointerMove,j),Yc(this.contextWindow,"pointerup",this.handlePointerUp,j),Yc(this.contextWindow,"pointercancel",this.handlePointerUp,j)),f&&this.startScrollTracking(f)}startScrollTracking(t){let n=t.parentElement;for(;n;){const r=getComputedStyle(n);(MT.has(r.overflowX)||MT.has(r.overflowY))&&this.scrollPositions.set(n,{x:n.scrollLeft,y:n.scrollTop}),n=n.parentElement}this.scrollPositions.set(window,{x:window.scrollX,y:window.scrollY}),window.addEventListener("scroll",this.onElementScroll,{capture:!0}),window.addEventListener("scroll",this.onWindowScroll),this.removeScrollListeners=()=>{window.removeEventListener("scroll",this.onElementScroll,{capture:!0}),window.removeEventListener("scroll",this.onWindowScroll)}}handleScroll(t){const n=this.scrollPositions.get(t);if(!n)return;const r=t===window,i=r?{x:window.scrollX,y:window.scrollY}:{x:t.scrollLeft,y:t.scrollTop},o={x:i.x-n.x,y:i.y-n.y};o.x===0&&o.y===0||(r?this.lastMoveEventInfo&&(this.lastMoveEventInfo.point.x+=o.x,this.lastMoveEventInfo.point.y+=o.y):this.history.length>0&&(this.history[0].x-=o.x,this.history[0].y-=o.y),this.scrollPositions.set(t,i),ft.update(this.updatePoint,!0))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),this.removeScrollListeners&&this.removeScrollListeners(),this.scrollPositions.clear(),Ci(this.updatePoint)}}function Md(e,t){return t?{point:t(e.point)}:e}function PT(e,t){return{x:e.x-t.x,y:e.y-t.y}}function tg({point:e},t){return{point:e,delta:PT(e,cz(t)),offset:PT(e,B7(t)),velocity:q7(t,.1)}}function B7(e){return e[0]}function cz(e){return e[e.length-1]}function q7(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const i=cz(e);for(;n>=0&&(r=e[n],!(i.timestamp-r.timestamp>Xn(t)));)n--;if(!r)return{x:0,y:0};r===e[0]&&e.length>2&&i.timestamp-r.timestamp>Xn(t)*2&&(r=e[1]);const o=pr(i.timestamp-r.timestamp);if(o===0)return{x:0,y:0};const c={x:(i.x-r.x)/o,y:(i.y-r.y)/o};return c.x===1/0&&(c.x=0),c.y===1/0&&(c.y=0),c}function I7(e,{min:t,max:n},r){return t!==void 0&&e<t?e=r?ut(t,e,r.min):Math.max(e,t):n!==void 0&&e>n&&(e=r?ut(n,e,r.max):Math.min(e,n)),e}function RT(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function U7(e,{top:t,left:n,bottom:r,right:i}){return{x:RT(e.x,n,i),y:RT(e.y,t,r)}}function kT(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,r]=[r,n]),{min:n,max:r}}function V7(e,t){return{x:kT(e.x,t.x),y:kT(e.y,t.y)}}function H7(e,t){let n=.5;const r=vn(e),i=vn(t);return i>r?n=ru(t.min,t.max-r,e.min):r>i&&(n=ru(e.min,e.max-i,t.min)),Qr(0,1,n)}function F7(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const $1=.35;function G7(e=$1){return e===!1?e=0:e===!0&&(e=$1),{x:DT(e,"left","right"),y:DT(e,"top","bottom")}}function DT(e,t,n){return{min:zT(e,t),max:zT(e,n)}}function zT(e,t){return typeof e=="number"?e:e[t]||0}const K7=new WeakMap;class Y7{constructor(t){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=Gt(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=t}start(t,{snapToCursor:n=!1,distanceThreshold:r}={}){const{presenceContext:i}=this.visualElement;if(i&&i.isPresent===!1)return;const o=y=>{n&&this.snapToCursor(Yu(y).point),this.stopAnimation()},c=(y,x)=>{const{drag:j,dragPropagation:w,onDragStart:S}=this.getProps();if(j&&!w&&(this.openDragLock&&this.openDragLock(),this.openDragLock=j9(j),!this.openDragLock))return;this.latestPointerEvent=y,this.latestPanInfo=x,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),Fr(A=>{let _=this.getAxisMotionValue(A).get()||0;if(Yr.test(_)){const{projection:O}=this.visualElement;if(O&&O.layout){const T=O.layout.layoutBox[A];T&&(_=vn(T)*(parseFloat(_)/100))}}this.originPoint[A]=_}),S&&ft.update(()=>S(y,x),!1,!0),T1(this.visualElement,"transform");const{animationState:b}=this.visualElement;b&&b.setActive("whileDrag",!0)},f=(y,x)=>{this.latestPointerEvent=y,this.latestPanInfo=x;const{dragPropagation:j,dragDirectionLock:w,onDirectionLock:S,onDrag:b}=this.getProps();if(!j&&!this.openDragLock)return;const{offset:A}=x;if(w&&this.currentDirection===null){this.currentDirection=W7(A),this.currentDirection!==null&&S&&S(this.currentDirection);return}this.updateAxis("x",x.point,A),this.updateAxis("y",x.point,A),this.visualElement.render(),b&&ft.update(()=>b(y,x),!1,!0)},d=(y,x)=>{this.latestPointerEvent=y,this.latestPanInfo=x,this.stop(y,x),this.latestPointerEvent=null,this.latestPanInfo=null},h=()=>{const{dragSnapToOrigin:y}=this.getProps();(y||this.constraints)&&this.startAnimation({x:0,y:0})},{dragSnapToOrigin:p}=this.getProps();this.panSession=new lz(t,{onSessionStart:o,onStart:c,onMove:f,onSessionEnd:d,resumeAnimation:h},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:p,distanceThreshold:r,contextWindow:oz(this.visualElement),element:this.visualElement.current})}stop(t,n){const r=t||this.latestPointerEvent,i=n||this.latestPanInfo,o=this.isDragging;if(this.cancel(),!o||!i||!r)return;const{velocity:c}=i;this.startAnimation(c);const{onDragEnd:f}=this.getProps();f&&ft.postRender(()=>f(r,i))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.endPanSession();const{dragPropagation:r}=this.getProps();!r&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),n&&n.setActive("whileDrag",!1)}endPanSession(){this.panSession&&this.panSession.end(),this.panSession=void 0}updateAxis(t,n,r){const{drag:i}=this.getProps();if(!r||!Pd(t,i,this.currentDirection))return;const o=this.getAxisMotionValue(t);let c=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(c=I7(c,this.constraints[t],this.elastic[t])),o.set(c)}resolveConstraints(){var o;const{dragConstraints:t,dragElastic:n}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(o=this.visualElement.projection)==null?void 0:o.layout,i=this.constraints;t&&No(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&r?this.constraints=U7(r.layoutBox,t):this.constraints=!1,this.elastic=G7(n),i!==this.constraints&&!No(t)&&r&&this.constraints&&!this.hasMutatedConstraints&&Fr(c=>{this.constraints!==!1&&this.getAxisMotionValue(c)&&(this.constraints[c]=F7(r.layoutBox[c],this.constraints[c]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!No(t))return!1;const r=t.current,{projection:i}=this.visualElement;if(!i||!i.layout)return!1;i.root&&(i.root.scroll=void 0,i.root.updateScroll());const o=W9(r,i.root,this.visualElement.getTransformPagePoint());let c=V7(i.layout.layoutBox,o);if(n){const f=n(K9(c));this.hasMutatedConstraints=!!f,f&&(c=M4(f))}return c}startAnimation(t){const{drag:n,dragMomentum:r,dragElastic:i,dragTransition:o,dragSnapToOrigin:c,onDragTransitionEnd:f}=this.getProps(),d=this.constraints||{},h=Fr(p=>{if(!Pd(p,n,this.currentDirection))return;let y=d&&d[p]||{};(c===!0||c===p)&&(y={min:0,max:0});const x=i?200:1e6,j=i?40:1e7,w={type:"inertia",velocity:r?t[p]:0,bounceStiffness:x,bounceDamping:j,timeConstant:750,restDelta:1,restSpeed:10,...o,...y};return this.startAxisValueAnimation(p,w)});return Promise.all(h).then(f)}startAxisValueAnimation(t,n){const r=this.getAxisMotionValue(t);return T1(this.visualElement,t),r.start(qw(t,r,0,n,this.visualElement,!1))}stopAnimation(){Fr(t=>this.getAxisMotionValue(t).stop())}getAxisMotionValue(t){const n=`_drag${t.toUpperCase()}`,i=this.visualElement.getProps()[n];return i||this.visualElement.getValue(t,this.visualElement.latestValues[t]??0)}snapToCursor(t){Fr(n=>{const{drag:r}=this.getProps();if(!Pd(n,r,this.currentDirection))return;const{projection:i}=this.visualElement,o=this.getAxisMotionValue(n);if(i&&i.layout){const{min:c,max:f}=i.layout.layoutBox[n],d=o.get()||0;o.set(t[n]-ut(c,f,.5)+d)}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!No(n)||!r||!this.constraints)return;this.stopAnimation();const i={x:0,y:0};Fr(c=>{const f=this.getAxisMotionValue(c);if(f&&this.constraints!==!1){const d=f.get();i[c]=H7({min:d,max:d},this.constraints[c])}});const{transformTemplate:o}=this.visualElement.getProps();this.visualElement.current.style.transform=o?o({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.constraints=!1,this.resolveConstraints(),Fr(c=>{if(!Pd(c,t,null))return;const f=this.getAxisMotionValue(c),{min:d,max:h}=this.constraints[c];f.set(ut(d,h,i[c]))}),this.visualElement.render()}addListeners(){if(!this.visualElement.current)return;K7.set(this.visualElement,this);const t=this.visualElement.current,n=Yc(t,"pointerdown",h=>{const{drag:p,dragListener:y=!0}=this.getProps(),x=h.target,j=x!==t&&_9(x);p&&y&&!j&&this.start(h)});let r;const i=()=>{const{dragConstraints:h}=this.getProps();No(h)&&h.current&&(this.constraints=this.resolveRefConstraints(),r||(r=X7(t,h.current,()=>this.scalePositionWithinConstraints())))},{projection:o}=this.visualElement,c=o.addEventListener("measure",i);o&&!o.layout&&(o.root&&o.root.updateScroll(),o.updateLayout()),ft.read(i);const f=su(window,"resize",()=>this.scalePositionWithinConstraints()),d=o.addEventListener("didUpdate",(({delta:h,hasLayoutChanged:p})=>{this.isDragging&&p&&(Fr(y=>{const x=this.getAxisMotionValue(y);x&&(this.originPoint[y]+=h[y].translate,x.set(x.get()+h[y].translate))}),this.visualElement.render())}));return()=>{f(),n(),c(),d&&d(),r&&r()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:i=!1,dragConstraints:o=!1,dragElastic:c=$1,dragMomentum:f=!0}=t;return{...t,drag:n,dragDirectionLock:r,dragPropagation:i,dragConstraints:o,dragElastic:c,dragMomentum:f}}}function LT(e){let t=!0;return()=>{if(t){t=!1;return}e()}}function X7(e,t,n){const r=H_(e,LT(n)),i=H_(t,LT(n));return()=>{r(),i()}}function Pd(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function W7(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class Z7 extends Ri{constructor(t){super(t),this.removeGroupControls=xr,this.removeListeners=xr,this.controls=new Y7(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||xr}update(){const{dragControls:t}=this.node.getProps(),{dragControls:n}=this.node.prevProps||{};t!==n&&(this.removeGroupControls(),t&&(this.removeGroupControls=t.subscribe(this.controls)))}unmount(){this.removeGroupControls(),this.removeListeners(),this.controls.isDragging||this.controls.endPanSession()}}const ng=e=>(t,n)=>{e&&ft.update(()=>e(t,n),!1,!0)};class Q7 extends Ri{constructor(){super(...arguments),this.removePointerDownListener=xr}onPointerDown(t){this.session=new lz(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:oz(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:r,onPanEnd:i}=this.node.getProps();return{onSessionStart:ng(t),onStart:ng(n),onMove:ng(r),onEnd:(o,c)=>{delete this.session,i&&ft.postRender(()=>i(o,c))}}}mount(){this.removePointerDownListener=Yc(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}let rg=!1;class J7 extends P.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r,layoutId:i}=this.props,{projection:o}=t;o&&(n.group&&n.group.add(o),r&&r.register&&i&&r.register(o),rg&&o.root.didUpdate(),o.addEventListener("animationComplete",()=>{this.safeToRemove()}),o.setOptions({...o.options,layoutDependency:this.props.layoutDependency,onExitComplete:()=>this.safeToRemove()})),ch.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:r,drag:i,isPresent:o}=this.props,{projection:c}=r;return c&&(c.isPresent=o,t.layoutDependency!==n&&c.setOptions({...c.options,layoutDependency:n}),rg=!0,i||t.layoutDependency!==n||n===void 0||t.isPresent!==o?c.willUpdate():this.safeToRemove(),t.isPresent!==o&&(o?c.promote():c.relegate()||ft.postRender(()=>{const f=c.getStack();(!f||!f.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{visualElement:t,layoutAnchor:n}=this.props,{projection:r}=t;r&&(r.options.layoutAnchor=n,r.root.didUpdate(),Hw.postRender(()=>{!r.currentAnimation&&r.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:i}=t;rg=!0,i&&(i.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(i),r&&r.deregister&&r.deregister(i))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function uz(e){const[t,n]=Q4(),r=P.useContext(Nw);return l.jsx(J7,{...e,layoutGroup:r,switchLayoutGroup:P.useContext(iz),isPresent:t,safeToRemove:n})}const eH={pan:{Feature:Q7},drag:{Feature:Z7,ProjectionNode:Z4,MeasureLayout:uz}};function $T(e,t,n){const{props:r}=e;e.animationState&&r.whileHover&&e.animationState.setActive("whileHover",n==="Start");const i="onHover"+n,o=r[i];o&&ft.postRender(()=>o(t,Yu(t)))}class tH extends Ri{mount(){const{current:t}=this.node;t&&(this.unmount=S9(t,(n,r)=>($T(this.node,r,"Start"),i=>$T(this.node,i,"End"))))}unmount(){}}class nH extends Ri{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=Fu(su(this.node.current,"focus",()=>this.onFocus()),su(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function BT(e,t,n){const{props:r}=e;if(e.current instanceof HTMLButtonElement&&e.current.disabled)return;e.animationState&&r.whileTap&&e.animationState.setActive("whileTap",n==="Start");const i="onTap"+(n==="End"?"":n),o=r[i];o&&ft.postRender(()=>o(t,Yu(t)))}class rH extends Ri{mount(){const{current:t}=this.node;if(!t)return;const{globalTapTarget:n,propagate:r}=this.node.props;this.unmount=E9(t,(i,o)=>(BT(this.node,o,"Start"),(c,{success:f})=>BT(this.node,c,f?"End":"Cancel")),{useGlobalTarget:n,stopPropagation:(r==null?void 0:r.tap)===!1})}unmount(){}}const B1=new WeakMap,ag=new WeakMap,aH=e=>{const t=B1.get(e.target);t&&t(e)},iH=e=>{e.forEach(aH)};function sH({root:e,...t}){const n=e||document;ag.has(n)||ag.set(n,{});const r=ag.get(n),i=JSON.stringify(t);return r[i]||(r[i]=new IntersectionObserver(iH,{root:e,...t})),r[i]}function oH(e,t,n){const r=sH(t);return B1.set(e,n),r.observe(e),()=>{B1.delete(e),r.unobserve(e)}}const lH={some:0,all:1};class cH extends Ri{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){var d;(d=this.stopObserver)==null||d.call(this);const{viewport:t={}}=this.node.getProps(),{root:n,margin:r,amount:i="some",once:o}=t,c={root:n?n.current:void 0,rootMargin:r,threshold:typeof i=="number"?i:lH[i]},f=h=>{const{isIntersecting:p}=h;if(this.isInView===p||(this.isInView=p,o&&!p&&this.hasEnteredView))return;p&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",p);const{onViewportEnter:y,onViewportLeave:x}=this.node.getProps(),j=p?y:x;j&&j(h)};this.stopObserver=oH(this.node.current,c,f)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(uH(t,n))&&this.startObserver()}unmount(){var t;(t=this.stopObserver)==null||t.call(this),this.hasEnteredView=!1,this.isInView=!1}}function uH({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const fH={inView:{Feature:cH},tap:{Feature:rH},focus:{Feature:nH},hover:{Feature:tH}},dH={layout:{ProjectionNode:Z4,MeasureLayout:uz}},hH={...z7,...fH,...eH,...dH},Gn=M7(hH,P7),fz=_D(e=>({sidebarOpen:!0,toggleSidebar:()=>e(t=>({sidebarOpen:!t.sidebarOpen})),setSidebarOpen:t=>e({sidebarOpen:t})}));/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const mH=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),dz=(...e)=>e.filter((t,n,r)=>!!t&&t.trim()!==""&&r.indexOf(t)===n).join(" ").trim();/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/var pH={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"};/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const yH=P.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:i="",children:o,iconNode:c,...f},d)=>P.createElement("svg",{ref:d,...pH,width:t,height:t,stroke:e,strokeWidth:r?Number(n)*24/Number(t):n,className:dz("lucide",i),...f},[...c.map(([h,p])=>P.createElement(h,p)),...Array.isArray(o)?o:[o]]));/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const he=(e,t)=>{const n=P.forwardRef(({className:r,...i},o)=>P.createElement(yH,{ref:o,iconNode:t,className:dz(`lucide-${mH(e)}`,r),...i}));return n.displayName=`${e}`,n};/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const xH=he("Activity",[["path",{d:"M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2",key:"169zse"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const gH=he("ArrowDownRight",[["path",{d:"m7 7 10 10",key:"1fmybs"}],["path",{d:"M17 7v10H7",key:"6fjiku"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const vH=he("ArrowRightLeft",[["path",{d:"m16 3 4 4-4 4",key:"1x1c3m"}],["path",{d:"M20 7H4",key:"zbl0bi"}],["path",{d:"m8 21-4-4 4-4",key:"h9nckh"}],["path",{d:"M4 17h16",key:"g4d7ey"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const bH=he("ArrowRight",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const qT=he("ArrowUpRight",[["path",{d:"M7 7h10v10",key:"1tivn9"}],["path",{d:"M7 17 17 7",key:"1vkiza"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const q1=he("Bell",[["path",{d:"M6 8a6 6 0 0 1 12 0c0 7 3 9 3 9H3s3-2 3-9",key:"1qo2s2"}],["path",{d:"M10.3 21a1.94 1.94 0 0 0 3.4 0",key:"qgo35s"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Ah=he("BookOpen",[["path",{d:"M12 7v14",key:"1akyts"}],["path",{d:"M3 18a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h5a4 4 0 0 1 4 4 4 4 0 0 1 4-4h5a1 1 0 0 1 1 1v13a1 1 0 0 1-1 1h-6a3 3 0 0 0-3 3 3 3 0 0 0-3-3z",key:"ruj8y"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const IT=he("Brain",[["path",{d:"M12 5a3 3 0 1 0-5.997.125 4 4 0 0 0-2.526 5.77 4 4 0 0 0 .556 6.588A4 4 0 1 0 12 18Z",key:"l5xja"}],["path",{d:"M12 5a3 3 0 1 1 5.997.125 4 4 0 0 1 2.526 5.77 4 4 0 0 1-.556 6.588A4 4 0 1 1 12 18Z",key:"ep3f8r"}],["path",{d:"M15 13a4.5 4.5 0 0 1-3-4 4.5 4.5 0 0 1-3 4",key:"1p4c4q"}],["path",{d:"M17.599 6.5a3 3 0 0 0 .399-1.375",key:"tmeiqw"}],["path",{d:"M6.003 5.125A3 3 0 0 0 6.401 6.5",key:"105sqy"}],["path",{d:"M3.477 10.896a4 4 0 0 1 .585-.396",key:"ql3yin"}],["path",{d:"M19.938 10.5a4 4 0 0 1 .585.396",key:"1qfode"}],["path",{d:"M6 18a4 4 0 0 1-1.967-.516",key:"2e4loj"}],["path",{d:"M19.967 17.484A4 4 0 0 1 18 18",key:"159ez6"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const ou=he("Briefcase",[["path",{d:"M16 20V4a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2v16",key:"jecpp"}],["rect",{width:"20",height:"14",x:"2",y:"6",rx:"2",key:"i6l2r4"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const La=he("Building2",[["path",{d:"M6 22V4a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v18Z",key:"1b4qmf"}],["path",{d:"M6 12H4a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2h2",key:"i71pzd"}],["path",{d:"M18 9h2a2 2 0 0 1 2 2v9a2 2 0 0 1-2 2h-2",key:"10jefs"}],["path",{d:"M10 6h4",key:"1itunk"}],["path",{d:"M10 10h4",key:"tcdvrf"}],["path",{d:"M10 14h4",key:"kelpxr"}],["path",{d:"M10 18h4",key:"1ulq68"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const jH=he("Calculator",[["rect",{width:"16",height:"20",x:"4",y:"2",rx:"2",key:"1nb95v"}],["line",{x1:"8",x2:"16",y1:"6",y2:"6",key:"x4nwl0"}],["line",{x1:"16",x2:"16",y1:"14",y2:"18",key:"wjye3r"}],["path",{d:"M16 10h.01",key:"1m94wz"}],["path",{d:"M12 10h.01",key:"1nrarc"}],["path",{d:"M8 10h.01",key:"19clt8"}],["path",{d:"M12 14h.01",key:"1etili"}],["path",{d:"M8 14h.01",key:"6423bh"}],["path",{d:"M12 18h.01",key:"mhygvu"}],["path",{d:"M8 18h.01",key:"lrp35t"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const wH=he("Calendar",[["path",{d:"M8 2v4",key:"1cmpym"}],["path",{d:"M16 2v4",key:"4m81vk"}],["rect",{width:"18",height:"18",x:"3",y:"4",rx:"2",key:"1hopcy"}],["path",{d:"M3 10h18",key:"8toen8"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const uh=he("Camera",[["path",{d:"M14.5 4h-5L7 7H4a2 2 0 0 0-2 2v9a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2V9a2 2 0 0 0-2-2h-3l-2.5-3z",key:"1tc9qg"}],["circle",{cx:"12",cy:"13",r:"3",key:"1vg3eu"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const SH=he("ChartColumn",[["path",{d:"M3 3v16a2 2 0 0 0 2 2h16",key:"c24i48"}],["path",{d:"M18 17V9",key:"2bz60n"}],["path",{d:"M13 17V5",key:"1frdt8"}],["path",{d:"M8 17v-3",key:"17ska0"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const NH=he("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const eS=he("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const AH=he("ChevronLeft",[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const OH=he("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const zm=he("CircleAlert",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Dr=he("CircleCheckBig",[["path",{d:"M21.801 10A10 10 0 1 1 17 3.335",key:"yps3ct"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Xu=he("CircleCheck",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Oh=he("CircleX",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const vr=he("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const _H=he("Copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const hz=he("Cpu",[["rect",{width:"16",height:"16",x:"4",y:"4",rx:"2",key:"14l7u7"}],["rect",{width:"6",height:"6",x:"9",y:"9",rx:"1",key:"5aljv4"}],["path",{d:"M15 2v2",key:"13l42r"}],["path",{d:"M15 20v2",key:"15mkzm"}],["path",{d:"M2 15h2",key:"1gxd5l"}],["path",{d:"M2 9h2",key:"1bbxkp"}],["path",{d:"M20 15h2",key:"19e6y8"}],["path",{d:"M20 9h2",key:"19tzq7"}],["path",{d:"M9 2v2",key:"165o2o"}],["path",{d:"M9 20v2",key:"i2bqo8"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const TH=he("Crown",[["path",{d:"M11.562 3.266a.5.5 0 0 1 .876 0L15.39 8.87a1 1 0 0 0 1.516.294L21.183 5.5a.5.5 0 0 1 .798.519l-2.834 10.246a1 1 0 0 1-.956.734H5.81a1 1 0 0 1-.957-.734L2.02 6.02a.5.5 0 0 1 .798-.519l4.276 3.664a1 1 0 0 0 1.516-.294z",key:"1vdc57"}],["path",{d:"M5 21h14",key:"11awu3"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const mz=he("DollarSign",[["line",{x1:"12",x2:"12",y1:"2",y2:"22",key:"7eqyqh"}],["path",{d:"M17 5H9.5a3.5 3.5 0 0 0 0 7h5a3.5 3.5 0 0 1 0 7H6",key:"1b0p4s"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const UT=he("Download",[["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["polyline",{points:"7 10 12 15 17 10",key:"2ggqvy"}],["line",{x1:"12",x2:"12",y1:"15",y2:"3",key:"1vk2je"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Jr=he("Ellipsis",[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["circle",{cx:"19",cy:"12",r:"1",key:"1wjl8i"}],["circle",{cx:"5",cy:"12",r:"1",key:"1pcz8c"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const EH=he("ExternalLink",[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const CH=he("EyeOff",[["path",{d:"M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49",key:"ct8e1f"}],["path",{d:"M14.084 14.158a3 3 0 0 1-4.242-4.242",key:"151rxh"}],["path",{d:"M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143",key:"13bj9a"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const pz=he("Eye",[["path",{d:"M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0",key:"1nclc0"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const MH=he("Facebook",[["path",{d:"M18 2h-3a5 5 0 0 0-5 5v3H7v4h3v8h4v-8h3l1-4h-4V7a1 1 0 0 1 1-1h3z",key:"1jg4f8"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const VT=he("FileCheck",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"m9 15 2 2 4-4",key:"1grp1n"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Oi=he("FileText",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Wu=he("Filter",[["polygon",{points:"22 3 2 3 10 12.46 10 19 14 21 14 12.46 22 3",key:"1yg77f"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const PH=he("Gauge",[["path",{d:"m12 14 4-4",key:"9kzdfg"}],["path",{d:"M3.34 19a10 10 0 1 1 17.32 0",key:"19p75a"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const RH=he("GitBranch",[["line",{x1:"6",x2:"6",y1:"3",y2:"15",key:"17qcm7"}],["circle",{cx:"18",cy:"6",r:"3",key:"1h7g24"}],["circle",{cx:"6",cy:"18",r:"3",key:"fqmcym"}],["path",{d:"M18 9a9 9 0 0 1-9 9",key:"n2h4wq"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const yn=he("Globe",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const yz=he("Headphones",[["path",{d:"M3 14h3a2 2 0 0 1 2 2v3a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-7a9 9 0 0 1 18 0v7a2 2 0 0 1-2 2h-1a2 2 0 0 1-2-2v-3a2 2 0 0 1 2-2h3",key:"1xhozi"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const HT=he("Heart",[["path",{d:"M19 14c1.49-1.46 3-3.21 3-5.5A5.5 5.5 0 0 0 16.5 3c-1.76 0-3 .5-4.5 2-1.5-1.5-2.74-2-4.5-2A5.5 5.5 0 0 0 2 8.5c0 2.3 1.5 4.05 3 5.5l7 7Z",key:"c3ymky"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Rd=he("Inbox",[["polyline",{points:"22 12 16 12 14 15 10 15 8 12 2 12",key:"o97t9d"}],["path",{d:"M5.45 5.11 2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z",key:"oot6mr"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const kH=he("Instagram",[["rect",{width:"20",height:"20",x:"2",y:"2",rx:"5",ry:"5",key:"2e1cvw"}],["path",{d:"M16 11.37A4 4 0 1 1 12.63 8 4 4 0 0 1 16 11.37z",key:"9exkf1"}],["line",{x1:"17.5",x2:"17.51",y1:"6.5",y2:"6.5",key:"r4j83e"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const DH=he("KeyRound",[["path",{d:"M2.586 17.414A2 2 0 0 0 2 18.828V21a1 1 0 0 0 1 1h3a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h1a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h.172a2 2 0 0 0 1.414-.586l.814-.814a6.5 6.5 0 1 0-4-4z",key:"1s6t7t"}],["circle",{cx:"16.5",cy:"7.5",r:".5",fill:"currentColor",key:"w0ekpg"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const FT=he("Key",[["path",{d:"m15.5 7.5 2.3 2.3a1 1 0 0 0 1.4 0l2.1-2.1a1 1 0 0 0 0-1.4L19 4",key:"g0fldk"}],["path",{d:"m21 2-9.6 9.6",key:"1j0ho8"}],["circle",{cx:"7.5",cy:"15.5",r:"5.5",key:"yqb3hr"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const xz=he("LayoutDashboard",[["rect",{width:"7",height:"9",x:"3",y:"3",rx:"1",key:"10lvy0"}],["rect",{width:"7",height:"5",x:"14",y:"3",rx:"1",key:"16une8"}],["rect",{width:"7",height:"9",x:"14",y:"12",rx:"1",key:"1hutg5"}],["rect",{width:"7",height:"5",x:"3",y:"16",rx:"1",key:"ldoo1y"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const zH=he("Linkedin",[["path",{d:"M16 8a6 6 0 0 1 6 6v7h-4v-7a2 2 0 0 0-2-2 2 2 0 0 0-2 2v7h-4v-7a6 6 0 0 1 6-6z",key:"c2jq9f"}],["rect",{width:"4",height:"12",x:"2",y:"9",key:"mk3on5"}],["circle",{cx:"4",cy:"4",r:"2",key:"bt5ra8"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const gz=he("Lock",[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 10 0v4",key:"fwvmzm"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const vz=he("LogOut",[["path",{d:"M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4",key:"1uf3rs"}],["polyline",{points:"16 17 21 12 16 7",key:"1gabdz"}],["line",{x1:"21",x2:"9",y1:"12",y2:"12",key:"1uyos4"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const ig=he("MailOpen",[["path",{d:"M21.2 8.4c.5.38.8.97.8 1.6v10a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V10a2 2 0 0 1 .8-1.6l8-6a2 2 0 0 1 2.4 0l8 6Z",key:"1jhwl8"}],["path",{d:"m22 10-8.97 5.7a1.94 1.94 0 0 1-2.06 0L2 10",key:"1qfld7"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Sn=he("Mail",[["rect",{width:"20",height:"16",x:"2",y:"4",rx:"2",key:"18n3k1"}],["path",{d:"m22 7-8.97 5.7a1.94 1.94 0 0 1-2.06 0L2 7",key:"1ocrg3"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const GT=he("MapPin",[["path",{d:"M20 10c0 4.993-5.539 10.193-7.399 11.799a1 1 0 0 1-1.202 0C9.539 20.193 4 14.993 4 10a8 8 0 0 1 16 0",key:"1r0f0z"}],["circle",{cx:"12",cy:"10",r:"3",key:"ilqhr7"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const bz=he("Megaphone",[["path",{d:"m3 11 18-5v12L3 14v-3z",key:"n962bs"}],["path",{d:"M11.6 16.8a3 3 0 1 1-5.8-1.6",key:"1yl0tm"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const LH=he("Menu",[["line",{x1:"4",x2:"20",y1:"12",y2:"12",key:"1e0a9i"}],["line",{x1:"4",x2:"20",y1:"6",y2:"6",key:"1owob3"}],["line",{x1:"4",x2:"20",y1:"18",y2:"18",key:"yk5zj1"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const fh=he("MessageSquare",[["path",{d:"M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z",key:"1lielz"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const $H=he("Monitor",[["rect",{width:"20",height:"14",x:"2",y:"3",rx:"2",key:"48i651"}],["line",{x1:"8",x2:"16",y1:"21",y2:"21",key:"1svkeh"}],["line",{x1:"12",x2:"12",y1:"17",y2:"21",key:"vw1qmm"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const jz=he("Moon",[["path",{d:"M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z",key:"a7tn18"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const BH=he("Newspaper",[["path",{d:"M4 22h16a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2H8a2 2 0 0 0-2 2v16a2 2 0 0 1-2 2Zm0 0a2 2 0 0 1-2-2v-9c0-1.1.9-2 2-2h2",key:"7pis2x"}],["path",{d:"M18 14h-8",key:"sponae"}],["path",{d:"M15 18h-5",key:"95g1m2"}],["path",{d:"M10 6h8v4h-8V6Z",key:"smlsk5"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const qH=he("Package",[["path",{d:"M11 21.73a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73z",key:"1a0edw"}],["path",{d:"M12 22V12",key:"d0xqtd"}],["path",{d:"m3.3 7 7.703 4.734a2 2 0 0 0 1.994 0L20.7 7",key:"yx3hmr"}],["path",{d:"m7.5 4.27 9 5.15",key:"1c824w"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const KT=he("Pause",[["rect",{x:"14",y:"4",width:"4",height:"16",rx:"1",key:"zuxfzm"}],["rect",{x:"6",y:"4",width:"4",height:"16",rx:"1",key:"1okwgv"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const YT=he("Phone",[["path",{d:"M22 16.92v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6 19.79 19.79 0 0 1-3.07-8.67A2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72 12.84 12.84 0 0 0 .7 2.81 2 2 0 0 1-.45 2.11L8.09 9.91a16 16 0 0 0 6 6l1.27-1.27a2 2 0 0 1 2.11-.45 12.84 12.84 0 0 0 2.81.7A2 2 0 0 1 22 16.92z",key:"foiqr5"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const XT=he("Play",[["polygon",{points:"6 3 20 12 6 21 6 3",key:"1oa8hb"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Lr=he("Plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Ma=he("RefreshCw",[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const IH=he("Save",[["path",{d:"M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z",key:"1c8476"}],["path",{d:"M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7",key:"1ydtos"}],["path",{d:"M7 3v4a1 1 0 0 0 1 1h7",key:"t51u73"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const WT=he("Scale",[["path",{d:"m16 16 3-8 3 8c-.87.65-1.92 1-3 1s-2.13-.35-3-1Z",key:"7g6ntu"}],["path",{d:"m2 16 3-8 3 8c-.87.65-1.92 1-3 1s-2.13-.35-3-1Z",key:"ijws7r"}],["path",{d:"M7 21h10",key:"1b0cd5"}],["path",{d:"M12 3v18",key:"108xh3"}],["path",{d:"M3 7h2c2 0 5-1 7-2 2 1 5 2 7 2h2",key:"3gwbw2"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Ts=he("Search",[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const I1=he("Server",[["rect",{width:"20",height:"8",x:"2",y:"2",rx:"2",ry:"2",key:"ngkwjq"}],["rect",{width:"20",height:"8",x:"2",y:"14",rx:"2",ry:"2",key:"iecqi9"}],["line",{x1:"6",x2:"6.01",y1:"6",y2:"6",key:"16zg32"}],["line",{x1:"6",x2:"6.01",y1:"18",y2:"18",key:"nzw8ys"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const UH=he("Settings",[["path",{d:"M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z",key:"1qme2f"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Lm=he("Share2",[["circle",{cx:"18",cy:"5",r:"3",key:"gq8acd"}],["circle",{cx:"6",cy:"12",r:"3",key:"w7nqdw"}],["circle",{cx:"18",cy:"19",r:"3",key:"1xt0gg"}],["line",{x1:"8.59",x2:"15.42",y1:"13.51",y2:"17.49",key:"47mynk"}],["line",{x1:"15.41",x2:"8.59",y1:"6.51",y2:"10.49",key:"1n3mei"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Xr=he("Shield",[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const wz=he("Sun",[["circle",{cx:"12",cy:"12",r:"4",key:"4exip2"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"m4.93 4.93 1.41 1.41",key:"149t6j"}],["path",{d:"m17.66 17.66 1.41 1.41",key:"ptbguv"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"m6.34 17.66-1.41 1.41",key:"1m8zz5"}],["path",{d:"m19.07 4.93-1.41 1.41",key:"1shlcs"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Sz=he("Target",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["circle",{cx:"12",cy:"12",r:"6",key:"1vlfrh"}],["circle",{cx:"12",cy:"12",r:"2",key:"1c9p78"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Nz=he("TrendingDown",[["polyline",{points:"22 17 13.5 8.5 8.5 13.5 2 7",key:"1r2t7k"}],["polyline",{points:"16 17 22 17 22 11",key:"11uiuu"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const ea=he("TrendingUp",[["polyline",{points:"22 7 13.5 15.5 8.5 10.5 2 17",key:"126l90"}],["polyline",{points:"16 7 22 7 22 13",key:"kwv8wd"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Yt=he("TriangleAlert",[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const VH=he("Twitter",[["path",{d:"M22 4s-.7 2.1-2 3.4c1.6 10-9.4 17.3-18 11.6 2.2.1 4.4-.6 6-2C3 15.5.5 9.6 3 5c2.2 2.6 5.6 4.1 9 4-.9-4.2 4-6.6 7-3.8 1.1 0 3-1.2 3-1.2z",key:"pff0z6"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const ZT=he("UserPlus",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["line",{x1:"19",x2:"19",y1:"8",y2:"14",key:"1bvyxn"}],["line",{x1:"22",x2:"16",y1:"11",y2:"11",key:"1shjgl"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const U1=he("User",[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const Wn=he("Users",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["path",{d:"M16 3.13a4 4 0 0 1 0 7.75",key:"1da9ce"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const vs=he("Wallet",[["path",{d:"M19 7V4a1 1 0 0 0-1-1H5a2 2 0 0 0 0 4h15a1 1 0 0 1 1 1v4h-3a2 2 0 0 0 0 4h3a1 1 0 0 0 1-1v-2a1 1 0 0 0-1-1",key:"18etb6"}],["path",{d:"M3 5v14a2 2 0 0 0 2 2h15a1 1 0 0 0 1-1v-4",key:"xoc0q4"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const V1=he("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]);/**
|
||
* @license lucide-react v0.460.0 - ISC
|
||
*
|
||
* This source code is licensed under the ISC license.
|
||
* See the LICENSE file in the root directory of this source tree.
|
||
*/const $m=he("Zap",[["path",{d:"M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z",key:"1xq2db"}]]);function Az(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=Az(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function ze(){for(var e,t,n=0,r="",i=arguments.length;n<i;n++)(e=arguments[n])&&(t=Az(e))&&(r&&(r+=" "),r+=t);return r}const tS="-",HH=e=>{const t=GH(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:c=>{const f=c.split(tS);return f[0]===""&&f.length!==1&&f.shift(),Oz(f,t)||FH(c)},getConflictingClassGroupIds:(c,f)=>{const d=n[c]||[];return f&&r[c]?[...d,...r[c]]:d}}},Oz=(e,t)=>{var c;if(e.length===0)return t.classGroupId;const n=e[0],r=t.nextPart.get(n),i=r?Oz(e.slice(1),r):void 0;if(i)return i;if(t.validators.length===0)return;const o=e.join(tS);return(c=t.validators.find(({validator:f})=>f(o)))==null?void 0:c.classGroupId},QT=/^\[(.+)\]$/,FH=e=>{if(QT.test(e)){const t=QT.exec(e)[1],n=t==null?void 0:t.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}},GH=e=>{const{theme:t,prefix:n}=e,r={nextPart:new Map,validators:[]};return YH(Object.entries(e.classGroups),n).forEach(([o,c])=>{H1(c,r,o,t)}),r},H1=(e,t,n,r)=>{e.forEach(i=>{if(typeof i=="string"){const o=i===""?t:JT(t,i);o.classGroupId=n;return}if(typeof i=="function"){if(KH(i)){H1(i(r),t,n,r);return}t.validators.push({validator:i,classGroupId:n});return}Object.entries(i).forEach(([o,c])=>{H1(c,JT(t,o),n,r)})})},JT=(e,t)=>{let n=e;return t.split(tS).forEach(r=>{n.nextPart.has(r)||n.nextPart.set(r,{nextPart:new Map,validators:[]}),n=n.nextPart.get(r)}),n},KH=e=>e.isThemeGetter,YH=(e,t)=>t?e.map(([n,r])=>{const i=r.map(o=>typeof o=="string"?t+o:typeof o=="object"?Object.fromEntries(Object.entries(o).map(([c,f])=>[t+c,f])):o);return[n,i]}):e,XH=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=new Map,r=new Map;const i=(o,c)=>{n.set(o,c),t++,t>e&&(t=0,r=n,n=new Map)};return{get(o){let c=n.get(o);if(c!==void 0)return c;if((c=r.get(o))!==void 0)return i(o,c),c},set(o,c){n.has(o)?n.set(o,c):i(o,c)}}},_z="!",WH=e=>{const{separator:t,experimentalParseClassName:n}=e,r=t.length===1,i=t[0],o=t.length,c=f=>{const d=[];let h=0,p=0,y;for(let b=0;b<f.length;b++){let A=f[b];if(h===0){if(A===i&&(r||f.slice(b,b+o)===t)){d.push(f.slice(p,b)),p=b+o;continue}if(A==="/"){y=b;continue}}A==="["?h++:A==="]"&&h--}const x=d.length===0?f:f.substring(p),j=x.startsWith(_z),w=j?x.substring(1):x,S=y&&y>p?y-p:void 0;return{modifiers:d,hasImportantModifier:j,baseClassName:w,maybePostfixModifierPosition:S}};return n?f=>n({className:f,parseClassName:c}):c},ZH=e=>{if(e.length<=1)return e;const t=[];let n=[];return e.forEach(r=>{r[0]==="["?(t.push(...n.sort(),r),n=[]):n.push(r)}),t.push(...n.sort()),t},QH=e=>({cache:XH(e.cacheSize),parseClassName:WH(e),...HH(e)}),JH=/\s+/,eF=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:i}=t,o=[],c=e.trim().split(JH);let f="";for(let d=c.length-1;d>=0;d-=1){const h=c[d],{modifiers:p,hasImportantModifier:y,baseClassName:x,maybePostfixModifierPosition:j}=n(h);let w=!!j,S=r(w?x.substring(0,j):x);if(!S){if(!w){f=h+(f.length>0?" "+f:f);continue}if(S=r(x),!S){f=h+(f.length>0?" "+f:f);continue}w=!1}const b=ZH(p).join(":"),A=y?b+_z:b,_=A+S;if(o.includes(_))continue;o.push(_);const O=i(S,w);for(let T=0;T<O.length;++T){const N=O[T];o.push(A+N)}f=h+(f.length>0?" "+f:f)}return f};function tF(){let e=0,t,n,r="";for(;e<arguments.length;)(t=arguments[e++])&&(n=Tz(t))&&(r&&(r+=" "),r+=n);return r}const Tz=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=Tz(e[r]))&&(n&&(n+=" "),n+=t);return n};function nF(e,...t){let n,r,i,o=c;function c(d){const h=t.reduce((p,y)=>y(p),e());return n=QH(h),r=n.cache.get,i=n.cache.set,o=f,f(d)}function f(d){const h=r(d);if(h)return h;const p=eF(d,n);return i(d,p),p}return function(){return o(tF.apply(null,arguments))}}const bt=e=>{const t=n=>n[e]||[];return t.isThemeGetter=!0,t},Ez=/^\[(?:([a-z-]+):)?(.+)\]$/i,rF=/^\d+\/\d+$/,aF=new Set(["px","full","screen"]),iF=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,sF=/\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$/,oF=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,lF=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,cF=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Na=e=>ko(e)||aF.has(e)||rF.test(e),bi=e=>jl(e,"length",xF),ko=e=>!!e&&!Number.isNaN(Number(e)),sg=e=>jl(e,"number",ko),_c=e=>!!e&&Number.isInteger(Number(e)),uF=e=>e.endsWith("%")&&ko(e.slice(0,-1)),Be=e=>Ez.test(e),ji=e=>iF.test(e),fF=new Set(["length","size","percentage"]),dF=e=>jl(e,fF,Cz),hF=e=>jl(e,"position",Cz),mF=new Set(["image","url"]),pF=e=>jl(e,mF,vF),yF=e=>jl(e,"",gF),Tc=()=>!0,jl=(e,t,n)=>{const r=Ez.exec(e);return r?r[1]?typeof t=="string"?r[1]===t:t.has(r[1]):n(r[2]):!1},xF=e=>sF.test(e)&&!oF.test(e),Cz=()=>!1,gF=e=>lF.test(e),vF=e=>cF.test(e),bF=()=>{const e=bt("colors"),t=bt("spacing"),n=bt("blur"),r=bt("brightness"),i=bt("borderColor"),o=bt("borderRadius"),c=bt("borderSpacing"),f=bt("borderWidth"),d=bt("contrast"),h=bt("grayscale"),p=bt("hueRotate"),y=bt("invert"),x=bt("gap"),j=bt("gradientColorStops"),w=bt("gradientColorStopPositions"),S=bt("inset"),b=bt("margin"),A=bt("opacity"),_=bt("padding"),O=bt("saturate"),T=bt("scale"),N=bt("sepia"),E=bt("skew"),M=bt("space"),D=bt("translate"),R=()=>["auto","contain","none"],B=()=>["auto","hidden","clip","visible","scroll"],q=()=>["auto",Be,t],z=()=>[Be,t],H=()=>["",Na,bi],X=()=>["auto",ko,Be],Y=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],$=()=>["solid","dashed","dotted","double","none"],G=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],Q=()=>["start","end","center","between","around","evenly","stretch"],ie=()=>["","0",Be],le=()=>["auto","avoid","all","avoid-page","page","left","right","column"],L=()=>[ko,Be];return{cacheSize:500,separator:":",theme:{colors:[Tc],spacing:[Na,bi],blur:["none","",ji,Be],brightness:L(),borderColor:[e],borderRadius:["none","","full",ji,Be],borderSpacing:z(),borderWidth:H(),contrast:L(),grayscale:ie(),hueRotate:L(),invert:ie(),gap:z(),gradientColorStops:[e],gradientColorStopPositions:[uF,bi],inset:q(),margin:q(),opacity:L(),padding:z(),saturate:L(),scale:L(),sepia:ie(),skew:L(),space:z(),translate:z()},classGroups:{aspect:[{aspect:["auto","square","video",Be]}],container:["container"],columns:[{columns:[ji]}],"break-after":[{"break-after":le()}],"break-before":[{"break-before":le()}],"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"],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:[...Y(),Be]}],overflow:[{overflow:B()}],"overflow-x":[{"overflow-x":B()}],"overflow-y":[{"overflow-y":B()}],overscroll:[{overscroll:R()}],"overscroll-x":[{"overscroll-x":R()}],"overscroll-y":[{"overscroll-y":R()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[S]}],"inset-x":[{"inset-x":[S]}],"inset-y":[{"inset-y":[S]}],start:[{start:[S]}],end:[{end:[S]}],top:[{top:[S]}],right:[{right:[S]}],bottom:[{bottom:[S]}],left:[{left:[S]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",_c,Be]}],basis:[{basis:q()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",Be]}],grow:[{grow:ie()}],shrink:[{shrink:ie()}],order:[{order:["first","last","none",_c,Be]}],"grid-cols":[{"grid-cols":[Tc]}],"col-start-end":[{col:["auto",{span:["full",_c,Be]},Be]}],"col-start":[{"col-start":X()}],"col-end":[{"col-end":X()}],"grid-rows":[{"grid-rows":[Tc]}],"row-start-end":[{row:["auto",{span:[_c,Be]},Be]}],"row-start":[{"row-start":X()}],"row-end":[{"row-end":X()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",Be]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",Be]}],gap:[{gap:[x]}],"gap-x":[{"gap-x":[x]}],"gap-y":[{"gap-y":[x]}],"justify-content":[{justify:["normal",...Q()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...Q(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...Q(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[_]}],px:[{px:[_]}],py:[{py:[_]}],ps:[{ps:[_]}],pe:[{pe:[_]}],pt:[{pt:[_]}],pr:[{pr:[_]}],pb:[{pb:[_]}],pl:[{pl:[_]}],m:[{m:[b]}],mx:[{mx:[b]}],my:[{my:[b]}],ms:[{ms:[b]}],me:[{me:[b]}],mt:[{mt:[b]}],mr:[{mr:[b]}],mb:[{mb:[b]}],ml:[{ml:[b]}],"space-x":[{"space-x":[M]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[M]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",Be,t]}],"min-w":[{"min-w":[Be,t,"min","max","fit"]}],"max-w":[{"max-w":[Be,t,"none","full","min","max","fit","prose",{screen:[ji]},ji]}],h:[{h:[Be,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[Be,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[Be,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[Be,t,"auto","min","max","fit"]}],"font-size":[{text:["base",ji,bi]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",sg]}],"font-family":[{font:[Tc]}],"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:["tighter","tight","normal","wide","wider","widest",Be]}],"line-clamp":[{"line-clamp":["none",ko,sg]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Na,Be]}],"list-image":[{"list-image":["none",Be]}],"list-style-type":[{list:["none","disc","decimal",Be]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[A]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[A]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...$(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Na,bi]}],"underline-offset":[{"underline-offset":["auto",Na,Be]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:z()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",Be]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",Be]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[A]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...Y(),hF]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",dF]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},pF]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[w]}],"gradient-via-pos":[{via:[w]}],"gradient-to-pos":[{to:[w]}],"gradient-from":[{from:[j]}],"gradient-via":[{via:[j]}],"gradient-to":[{to:[j]}],rounded:[{rounded:[o]}],"rounded-s":[{"rounded-s":[o]}],"rounded-e":[{"rounded-e":[o]}],"rounded-t":[{"rounded-t":[o]}],"rounded-r":[{"rounded-r":[o]}],"rounded-b":[{"rounded-b":[o]}],"rounded-l":[{"rounded-l":[o]}],"rounded-ss":[{"rounded-ss":[o]}],"rounded-se":[{"rounded-se":[o]}],"rounded-ee":[{"rounded-ee":[o]}],"rounded-es":[{"rounded-es":[o]}],"rounded-tl":[{"rounded-tl":[o]}],"rounded-tr":[{"rounded-tr":[o]}],"rounded-br":[{"rounded-br":[o]}],"rounded-bl":[{"rounded-bl":[o]}],"border-w":[{border:[f]}],"border-w-x":[{"border-x":[f]}],"border-w-y":[{"border-y":[f]}],"border-w-s":[{"border-s":[f]}],"border-w-e":[{"border-e":[f]}],"border-w-t":[{"border-t":[f]}],"border-w-r":[{"border-r":[f]}],"border-w-b":[{"border-b":[f]}],"border-w-l":[{"border-l":[f]}],"border-opacity":[{"border-opacity":[A]}],"border-style":[{border:[...$(),"hidden"]}],"divide-x":[{"divide-x":[f]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[f]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[A]}],"divide-style":[{divide:$()}],"border-color":[{border:[i]}],"border-color-x":[{"border-x":[i]}],"border-color-y":[{"border-y":[i]}],"border-color-s":[{"border-s":[i]}],"border-color-e":[{"border-e":[i]}],"border-color-t":[{"border-t":[i]}],"border-color-r":[{"border-r":[i]}],"border-color-b":[{"border-b":[i]}],"border-color-l":[{"border-l":[i]}],"divide-color":[{divide:[i]}],"outline-style":[{outline:["",...$()]}],"outline-offset":[{"outline-offset":[Na,Be]}],"outline-w":[{outline:[Na,bi]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:H()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[A]}],"ring-offset-w":[{"ring-offset":[Na,bi]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",ji,yF]}],"shadow-color":[{shadow:[Tc]}],opacity:[{opacity:[A]}],"mix-blend":[{"mix-blend":[...G(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":G()}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[r]}],contrast:[{contrast:[d]}],"drop-shadow":[{"drop-shadow":["","none",ji,Be]}],grayscale:[{grayscale:[h]}],"hue-rotate":[{"hue-rotate":[p]}],invert:[{invert:[y]}],saturate:[{saturate:[O]}],sepia:[{sepia:[N]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[d]}],"backdrop-grayscale":[{"backdrop-grayscale":[h]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[p]}],"backdrop-invert":[{"backdrop-invert":[y]}],"backdrop-opacity":[{"backdrop-opacity":[A]}],"backdrop-saturate":[{"backdrop-saturate":[O]}],"backdrop-sepia":[{"backdrop-sepia":[N]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[c]}],"border-spacing-x":[{"border-spacing-x":[c]}],"border-spacing-y":[{"border-spacing-y":[c]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",Be]}],duration:[{duration:L()}],ease:[{ease:["linear","in","out","in-out",Be]}],delay:[{delay:L()}],animate:[{animate:["none","spin","ping","pulse","bounce",Be]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[T]}],"scale-x":[{"scale-x":[T]}],"scale-y":[{"scale-y":[T]}],rotate:[{rotate:[_c,Be]}],"translate-x":[{"translate-x":[D]}],"translate-y":[{"translate-y":[D]}],"skew-x":[{"skew-x":[E]}],"skew-y":[{"skew-y":[E]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",Be]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],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",Be]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":z()}],"scroll-mx":[{"scroll-mx":z()}],"scroll-my":[{"scroll-my":z()}],"scroll-ms":[{"scroll-ms":z()}],"scroll-me":[{"scroll-me":z()}],"scroll-mt":[{"scroll-mt":z()}],"scroll-mr":[{"scroll-mr":z()}],"scroll-mb":[{"scroll-mb":z()}],"scroll-ml":[{"scroll-ml":z()}],"scroll-p":[{"scroll-p":z()}],"scroll-px":[{"scroll-px":z()}],"scroll-py":[{"scroll-py":z()}],"scroll-ps":[{"scroll-ps":z()}],"scroll-pe":[{"scroll-pe":z()}],"scroll-pt":[{"scroll-pt":z()}],"scroll-pr":[{"scroll-pr":z()}],"scroll-pb":[{"scroll-pb":z()}],"scroll-pl":[{"scroll-pl":z()}],"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",Be]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[Na,bi,sg]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"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-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-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"],"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"]}}},jF=nF(bF);function tt(...e){return jF(ze(e))}function we(e,t="SEK"){return e==null||isNaN(e)?"-":new Intl.NumberFormat("sv-SE",{style:"currency",currency:t,maximumFractionDigits:0}).format(e)}function eE(e){return new Intl.NumberFormat("sv-SE").format(e)}function Rt(e){return new Intl.DateTimeFormat("sv-SE",{year:"numeric",month:"short",day:"numeric"}).format(new Date(e))}function Mz(e){const t=new Date,n=new Date(e),r=t.getTime()-n.getTime(),i=Math.floor(r/6e4),o=Math.floor(r/36e5),c=Math.floor(r/864e5);return i<1?"Just now":i<60?`${i}m ago`:o<24?`${o}h ago`:c<7?`${c}d ago`:Rt(e)}function wF(e){return e.split(" ").map(t=>t[0]).join("").toUpperCase().slice(0,2)}const SF=[{path:"/",label:"Briefing",icon:BH},{path:"/dashboard",label:"Dashboard",icon:xz},{path:"/mail",label:"Mail",icon:Sn},{path:"/quixzoom",label:"quiXzoom",icon:yn},{path:"/amos",label:"AMOS",icon:hz},{path:"/landvex",label:"Landvex",icon:TH},{path:"/finance",label:"Finance",icon:vs},{path:"/accounting",label:"Accounting",icon:jH},{path:"/crm",label:"CRM",icon:Wn},{path:"/sales",label:"Sales",icon:ea},{path:"/compliance",label:"Compliance",icon:Xr},{path:"/hr",label:"HR",icon:ou},{path:"/legal",label:"Legal",icon:Oi},{path:"/marketing",label:"Marketing",icon:bz},{path:"/social",label:"Social Media",icon:Lm},{path:"/support",label:"Support",icon:yz},{path:"/automation",label:"Automation",icon:$m}];function NF(){const{sidebarOpen:e,toggleSidebar:t}=fz(),{logout:n,isAuthenticated:r}=za(),i=Pn(),o=Pi(),c=()=>{n(),o("/login")};return l.jsxs(l.Fragment,{children:[l.jsx(ds,{children:e&&l.jsx(Gn.div,{initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:{duration:.15},className:"fixed inset-0 bg-black/20 z-40 lg:hidden",onClick:t})}),l.jsxs(Gn.aside,{initial:!1,animate:{width:e?240:72},transition:{duration:.2,ease:"easeOut"},className:tt("fixed left-0 top-0 h-full bg-sidebar z-50 flex flex-col","border-r border-border/60",e?"px-4":"px-3"),children:[l.jsxs("div",{className:"h-16 flex items-center justify-between shrink-0",children:[l.jsxs("div",{className:"flex items-center gap-2.5 overflow-hidden",children:[l.jsx("div",{className:"w-8 h-8 rounded-lg bg-primary flex items-center justify-center shrink-0",children:l.jsx("svg",{width:"16",height:"16",viewBox:"0 0 32 32",fill:"none",children:l.jsx("path",{d:"M10 22L16 10L22 22H10Z",stroke:"white",strokeWidth:"2.5",strokeLinejoin:"round"})})}),l.jsx(ds,{children:e&&l.jsx(Gn.span,{initial:{opacity:0,x:-8},animate:{opacity:1,x:0},exit:{opacity:0,x:-8},transition:{duration:.15},className:"text-sm font-semibold text-text-primary whitespace-nowrap",children:"AMOS"})})]}),l.jsx("button",{onClick:t,className:"hidden lg:flex w-7 h-7 items-center justify-center rounded-lg hover:bg-bg text-text-secondary transition-colors",children:e?l.jsx(AH,{size:14}):l.jsx(OH,{size:14})})]}),l.jsx("nav",{className:"flex-1 py-4 space-y-0.5 overflow-y-auto",children:SF.map(f=>{const d=i.pathname===f.path||f.path!=="/"&&i.pathname.startsWith(f.path),h=f.icon;return l.jsxs(AD,{to:f.path,onClick:()=>{window.innerWidth<1024&&t()},className:tt("flex items-center gap-3 h-10 rounded-xl px-3 transition-colors duration-150 relative","hover:bg-primary-light",d&&"bg-primary-light text-primary",!d&&"text-text-secondary"),children:[d&&l.jsx(Gn.div,{layoutId:"sidebar-active",className:"absolute left-0 top-1/2 -translate-y-1/2 w-0.5 h-5 bg-primary rounded-full",transition:{duration:.18,ease:"easeOut"}}),l.jsx(h,{size:18,strokeWidth:d?2:1.5}),l.jsx(ds,{children:e&&l.jsx(Gn.span,{initial:{opacity:0,x:-8},animate:{opacity:1,x:0},exit:{opacity:0,x:-8},transition:{duration:.15},className:tt("text-sm font-medium whitespace-nowrap",d?"text-primary":"text-text-secondary"),children:f.label})})]},f.path)})}),r&&l.jsx("div",{className:"py-4 border-t border-border/60",children:l.jsxs("button",{onClick:c,className:tt("flex items-center gap-3 h-10 rounded-xl px-3 transition-colors duration-150 w-full","hover:bg-danger-light text-text-secondary hover:text-danger"),children:[l.jsx(vz,{size:18,strokeWidth:1.5}),l.jsx(ds,{children:e&&l.jsx(Gn.span,{initial:{opacity:0,x:-8},animate:{opacity:1,x:0},exit:{opacity:0,x:-8},transition:{duration:.15},className:"text-sm font-medium whitespace-nowrap",children:"Logga ut"})})]})})]})]})}function AF(){const[e,t]=P.useState(!1);P.useEffect(()=>{const r=window.matchMedia("(prefers-color-scheme: dark)").matches,i=localStorage.getItem("amos-dark-mode"),o=i?i==="true":r;t(o),o?document.documentElement.classList.add("dark"):document.documentElement.classList.remove("dark")},[]);const n=()=>{const r=!e;t(r),localStorage.setItem("amos-dark-mode",String(r)),r?document.documentElement.classList.add("dark"):document.documentElement.classList.remove("dark")};return l.jsx("button",{onClick:n,className:tt("w-10 h-10 rounded-xl flex items-center justify-center transition-colors",e?"bg-primary/20 text-primary":"bg-bg text-text-secondary hover:text-text-primary"),"aria-label":"Toggle dark mode",children:e?l.jsx(jz,{size:18}):l.jsx(wz,{size:18})})}const OF=[{id:"landvex",name:"Landvex AB",org:"559141-7042"},{id:"landvex-inc",name:"Landvex Inc.",org:"83-4567891"},{id:"quixzoom",name:"quiXzoom",org:"-"},{id:"aamos",name:"AAMOS",org:"-"}],tE=[{id:"1",title:"Nytt avtal tecknat",description:"Acme Corp har signerat enterprise-avtalet",time:new Date(Date.now()-1e3*60*15).toISOString(),read:!1},{id:"2",title:"Faktura förfallen",description:"Faktura #INV-2024-0042 är 3 dagar försenad",time:new Date(Date.now()-1e3*60*60*2).toISOString(),read:!1},{id:"3",title:"Semester beviljad",description:"Din semesteransökan har godkänts av HR",time:new Date(Date.now()-1e3*60*60*5).toISOString(),read:!0}];function _F(){const{user:e,logout:t}=za(),n=Pi(),[r,i]=P.useState(!1),[o,c]=P.useState(!1),[f,d]=P.useState(!1),[h,p]=P.useState("landvex"),y=()=>{const j=new Date().getHours();return j<12?"Good morning":j<17?"Good afternoon":"Good evening"},x=tE.filter(j=>!j.read).length;return l.jsxs("header",{className:"h-14 lg:h-16 bg-surface border-b border-border/60 flex items-center justify-between px-4 lg:px-10 sticky top-0 z-30 lg:mt-0 mt-14",children:[l.jsx("div",{className:"flex items-center gap-4",children:l.jsxs("div",{children:[l.jsxs("h1",{className:"text-base font-semibold text-text-primary",children:[y(),e?`, ${e.name||"Erik Svensson"}`:", Erik Svensson"]}),l.jsx("p",{className:"text-xs text-text-secondary hidden sm:block",children:new Date().toLocaleDateString("sv-SE",{weekday:"long",year:"numeric",month:"long",day:"numeric"})})]})}),l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsxs("div",{className:"hidden md:flex items-center h-9 px-3.5 rounded-xl bg-bg border border-border/60 text-text-secondary",children:[l.jsx(Ts,{size:15}),l.jsx("span",{className:"ml-2 text-sm",children:"Search..."}),l.jsx("kbd",{className:"ml-6 px-1.5 py-0.5 text-[10px] font-medium bg-surface rounded border border-border",children:"⌘K"})]}),l.jsx("div",{className:"hidden sm:block",children:l.jsx(AF,{})}),l.jsxs("div",{className:"relative",children:[l.jsxs("button",{onClick:()=>{i(!r),c(!1)},className:"relative w-9 h-9 flex items-center justify-center rounded-xl hover:bg-bg text-text-secondary transition-colors",children:[l.jsx(q1,{size:17}),x>0&&l.jsx("span",{className:"absolute top-1.5 right-1.5 w-2 h-2 bg-danger rounded-full"})]}),l.jsx(ds,{children:r&&l.jsxs(l.Fragment,{children:[l.jsx("div",{className:"fixed inset-0 z-40",onClick:()=>i(!1)}),l.jsxs(Gn.div,{initial:{opacity:0,y:4,scale:.98},animate:{opacity:1,y:0,scale:1},exit:{opacity:0,y:4,scale:.98},transition:{duration:.15},className:"absolute right-0 top-full mt-2 w-80 bg-surface rounded-[18px] dropdown-shadow border border-border/60 z-50 overflow-hidden",children:[l.jsxs("div",{className:"px-4 py-3 border-b border-border/60 flex items-center justify-between",children:[l.jsx("span",{className:"text-sm font-semibold text-text-primary",children:"Notifications"}),l.jsx("span",{className:"text-xs text-primary font-medium cursor-pointer",children:"Mark all read"})]}),l.jsx("div",{className:"max-h-80 overflow-y-auto",children:tE.map(j=>l.jsx("div",{onClick:()=>{i(!1),j.title.includes("avtal")||j.title.includes("faktura")?n("/finance"):j.title.includes("semester")||j.title.includes("HR")?n("/hr"):j.title.includes("deal")?n("/sales"):n("/dashboard")},className:tt("px-4 py-3 hover:bg-bg/60 transition-colors cursor-pointer",!j.read&&"bg-primary-light/30"),children:l.jsxs("div",{className:"flex items-start gap-3",children:[l.jsx("div",{className:tt("w-2 h-2 rounded-full mt-1.5 shrink-0",j.read?"bg-transparent":"bg-primary")}),l.jsxs("div",{className:"flex-1 min-w-0",children:[l.jsx("p",{className:"text-sm font-medium text-text-primary",children:j.title}),l.jsx("p",{className:"text-xs text-text-secondary mt-0.5",children:j.description}),l.jsx("p",{className:"text-[11px] text-text-secondary/60 mt-1",children:Mz(j.time)})]})]})},j.id))})]})]})})]}),l.jsxs("div",{className:"relative",children:[l.jsxs("button",{onClick:()=>{c(!o),i(!1)},className:"flex items-center gap-2 pl-1 pr-2 h-9 rounded-xl hover:bg-bg transition-colors",children:[l.jsx("div",{className:"w-7 h-7 rounded-full bg-primary/10 text-primary flex items-center justify-center text-xs font-semibold",children:e?wF(e.name):"?"}),l.jsx(eS,{size:14,className:"text-text-secondary"})]}),l.jsx(ds,{children:o&&l.jsxs(l.Fragment,{children:[l.jsx("div",{className:"fixed inset-0 z-40",onClick:()=>c(!1)}),l.jsxs(Gn.div,{initial:{opacity:0,y:4,scale:.98},animate:{opacity:1,y:0,scale:1},exit:{opacity:0,y:4,scale:.98},transition:{duration:.15},className:"absolute right-0 top-full mt-2 w-56 bg-surface rounded-[18px] dropdown-shadow border border-border/60 z-50 overflow-hidden",children:[l.jsxs("div",{className:"px-4 py-3 border-b border-border/60",children:[l.jsx("p",{className:"text-sm font-semibold text-text-primary",children:(e==null?void 0:e.name)||"User"}),l.jsx("p",{className:"text-xs text-text-secondary",children:(e==null?void 0:e.email)||"user@amos.com"})]}),l.jsxs("div",{className:"py-1",children:[l.jsxs("button",{onClick:()=>{n("/profile"),c(!1)},className:"w-full flex items-center gap-3 px-4 py-2.5 text-sm text-text-secondary hover:bg-bg transition-colors",children:[l.jsx(U1,{size:15}),"Min Profil"]}),l.jsxs("button",{onClick:()=>{d(!0),c(!1)},className:"w-full flex items-center gap-3 px-4 py-2.5 text-sm text-text-secondary hover:bg-bg transition-colors",children:[l.jsx(La,{size:15}),"Byt Verksamhet"]}),l.jsxs("button",{onClick:()=>{n("/profile?tab=preferences"),c(!1)},className:"w-full flex items-center gap-3 px-4 py-2.5 text-sm text-text-secondary hover:bg-bg transition-colors",children:[l.jsx(UH,{size:15}),"Inställningar"]}),l.jsx("div",{className:"border-t border-border/60 mt-1 pt-1",children:l.jsxs("button",{onClick:()=>{t(),c(!1)},className:"w-full flex items-center gap-3 px-4 py-2.5 text-sm text-danger hover:bg-danger-light transition-colors",children:[l.jsx(vz,{size:15}),"Sign out"]})})]})]})]})})]})]}),l.jsx(ds,{children:f&&l.jsxs(l.Fragment,{children:[l.jsx(Gn.div,{initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},className:"fixed inset-0 bg-black/50 z-50",onClick:()=>d(!1)}),l.jsxs(Gn.div,{initial:{opacity:0,scale:.95},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.95},className:"fixed inset-x-4 top-20 bg-surface rounded-xl border border-border shadow-xl z-50 max-w-md mx-auto",children:[l.jsxs("div",{className:"p-4 border-b border-border/60 flex items-center justify-between",children:[l.jsx("h2",{className:"text-lg font-semibold",children:"Välj Verksamhet"}),l.jsx("button",{onClick:()=>d(!1),className:"p-2 hover:bg-surface-hover rounded-lg",children:l.jsx(V1,{size:20})})]}),l.jsx("div",{className:"p-2",children:OF.map(j=>l.jsxs("button",{onClick:()=>{p(j.id),d(!1),window.location.reload()},className:`w-full flex items-center gap-3 p-3 rounded-lg transition-colors ${h===j.id?"bg-accent/10 border border-accent/20":"hover:bg-surface-hover"}`,children:[l.jsx("div",{className:"w-10 h-10 rounded-lg bg-primary/10 flex items-center justify-center",children:l.jsx(La,{size:20,className:"text-primary"})}),l.jsxs("div",{className:"text-left",children:[l.jsx("p",{className:"font-medium",children:j.name}),l.jsx("p",{className:"text-sm text-text-secondary",children:j.org})]}),h===j.id&&l.jsx("div",{className:"ml-auto w-2 h-2 rounded-full bg-accent"})]},j.id))})]})]})})]})}const TF=[{path:"/",label:"Briefing",icon:xz},{path:"/dashboard",label:"Dashboard",icon:ea},{path:"/mail",label:"Mail",icon:Sn}],EF=[{path:"/amos",label:"AMOS",icon:$m},{path:"/quixzoom",label:"quiXzoom",icon:yn},{path:"/landvex",label:"Landvex",icon:La},{path:"/alva",label:"Alva",icon:PH}],CF=[{path:"/finance",label:"Finance",icon:vs},{path:"/accounting",label:"Accounting",icon:Ah},{path:"/crm",label:"CRM",icon:Wn},{path:"/social",label:"Social",icon:Lm},{path:"/compliance",label:"Compliance",icon:Xr}];function MF(){const[e,t]=P.useState(!1),[n,r]=P.useState(!1),i=Pn(),o=c=>i.pathname===c;return l.jsxs(l.Fragment,{children:[l.jsxs("div",{className:"fixed top-0 left-0 right-0 z-40 bg-bg border-b border-border-subtle px-4 py-3 flex items-center justify-between lg:hidden",children:[l.jsx(Ao,{to:"/",className:"text-lg font-bold text-text-primary tracking-wide",children:"AAMOS"}),l.jsx("button",{onClick:()=>t(!e),className:"p-2 rounded-lg bg-surface text-text-primary active:bg-surface-hover","aria-label":"Toggle menu",children:e?l.jsx(V1,{size:24}):l.jsx(LH,{size:24})})]}),e&&l.jsxs("div",{className:"fixed inset-0 z-[100] bg-bg lg:hidden flex flex-col",children:[l.jsxs("div",{className:"flex items-center justify-between px-4 py-3 border-b border-border-subtle bg-bg shrink-0",children:[l.jsx("span",{className:"text-lg font-bold text-text-primary",children:"Menu"}),l.jsx("button",{onClick:()=>t(!1),className:"p-2 rounded-lg bg-surface text-text-primary active:bg-surface-hover border border-border/40","aria-label":"Close menu",children:l.jsx(V1,{size:24})})]}),l.jsxs("div",{className:"p-4 space-y-1 overflow-y-auto flex-1",children:[TF.map(c=>{const f=c.icon;return l.jsxs(Ao,{to:c.path,onClick:()=>t(!1),className:tt("flex items-center gap-3 px-4 py-3 rounded-xl text-base font-medium transition-colors",o(c.path)?"bg-accent/10 text-accent":"text-text-secondary hover:bg-surface-hover"),children:[l.jsx(f,{size:22}),c.label]},c.path)}),l.jsxs("div",{className:"pt-2",children:[l.jsxs("button",{onClick:()=>r(!n),className:"flex items-center justify-between w-full px-4 py-3 rounded-xl text-base font-medium text-text-secondary hover:bg-surface-hover transition-colors",children:[l.jsxs("span",{className:"flex items-center gap-3",children:[l.jsx($m,{size:22}),"Products"]}),l.jsx(eS,{size:18,className:tt("transition-transform",n&&"rotate-180")})]}),n&&l.jsx("div",{className:"ml-4 space-y-1 mt-1",children:EF.map(c=>{const f=c.icon;return l.jsxs(Ao,{to:c.path,onClick:()=>t(!1),className:tt("flex items-center gap-3 px-4 py-2.5 rounded-xl text-sm font-medium transition-colors",o(c.path)?"bg-accent/10 text-accent":"text-text-secondary hover:bg-surface-hover"),children:[l.jsx(f,{size:18}),c.label]},c.path)})})]}),l.jsx("div",{className:"pt-2",children:CF.map(c=>{const f=c.icon;return l.jsxs(Ao,{to:c.path,onClick:()=>t(!1),className:tt("flex items-center gap-3 px-4 py-3 rounded-xl text-base font-medium transition-colors",o(c.path)?"bg-accent/10 text-accent":"text-text-secondary hover:bg-surface-hover"),children:[l.jsx(f,{size:22}),c.label]},c.path)})})]})]})]})}const Pz={light:()=>{typeof navigator<"u"&&navigator.vibrate&&navigator.vibrate(10)},medium:()=>{typeof navigator<"u"&&navigator.vibrate&&navigator.vibrate(20)},heavy:()=>{typeof navigator<"u"&&navigator.vibrate&&navigator.vibrate([30,50,30])},success:()=>{typeof navigator<"u"&&navigator.vibrate&&navigator.vibrate([10,30,10])},error:()=>{typeof navigator<"u"&&navigator.vibrate&&navigator.vibrate([50,30,50])},swipe:()=>{typeof navigator<"u"&&navigator.vibrate&&navigator.vibrate(15)}};function PF({children:e,onSwipeLeft:t,onSwipeRight:n,className:r}){const i=P.useRef(null),o=P.useRef(null),[c,f]=P.useState(!1),d=50,h=P.useCallback(x=>{o.current=null,i.current={x:x.targetTouches[0].clientX,y:x.targetTouches[0].clientY},f(!0)},[]),p=P.useCallback(x=>{o.current={x:x.targetTouches[0].clientX,y:x.targetTouches[0].clientY}},[]),y=P.useCallback(()=>{if(f(!1),!i.current||!o.current)return;const x=i.current.x-o.current.x,j=i.current.y-o.current.y;Math.abs(x)>Math.abs(j)&&Math.abs(x)>d&&(Pz.swipe(),x>0?t==null||t():n==null||n()),i.current=null,o.current=null},[t,n]);return l.jsx("div",{className:tt("touch-pan-y",c&&"select-none",r),onTouchStart:h,onTouchMove:p,onTouchEnd:y,children:e})}function RF({onRefresh:e,children:t,className:n}){const[r,i]=P.useState(!1),[o,c]=P.useState(0),[f,d]=P.useState(!1),h=P.useRef(0),p=P.useRef(null),y=100,x=80,j=P.useCallback(b=>{p.current&&p.current.scrollTop===0&&(h.current=b.targetTouches[0].clientY,i(!0))},[]),w=P.useCallback(b=>{if(!r)return;const _=b.targetTouches[0].clientY-h.current;if(_>0){const O=1+_/y*.5,T=Math.min(_/O,y);c(T)}},[r]),S=P.useCallback(async()=>{if(r){if(o>=x&&!f){d(!0);try{await e()}finally{d(!1)}}i(!1),c(0)}},[r,o,f,e]);return l.jsxs("div",{ref:p,className:tt("relative overflow-y-auto",n),onTouchStart:j,onTouchMove:w,onTouchEnd:S,children:[l.jsx("div",{className:"absolute top-0 left-0 right-0 flex items-center justify-center transition-transform",style:{transform:`translateY(${o-60}px)`,opacity:r?1:0},children:l.jsxs("div",{className:"flex flex-col items-center gap-2",children:[l.jsx(Ma,{size:24,className:tt("text-primary transition-transform",f&&"animate-spin",!f&&o>=x&&"rotate-180")}),l.jsx("span",{className:"text-xs text-text-secondary",children:f?"Refreshing...":o>=x?"Release to refresh":"Pull to refresh"})]})}),l.jsx("div",{style:{transform:r?`translateY(${o}px)`:"translateY(0)",transition:r?"none":"transform 0.3s ease-out"},children:t})]})}function kF({children:e}){const t=Pi(),n=P.useRef(0),r=P.useRef(0),i=P.useRef(null),o=P.useCallback(c=>{const f=Date.now();f-n.current<300?(r.current+=1,r.current===2&&(Pz.medium(),t("/dashboard"),r.current=0)):r.current=1,n.current=f,i.current&&clearTimeout(i.current),i.current=setTimeout(()=>{r.current=0},500)},[t]);return l.jsx("div",{onTouchEnd:o,children:e})}const kd=["/","/dashboard","/crm","/finance","/amos","/quixzoom","/landvex","/compliance","/accounting"];function DF(){const{sidebarOpen:e}=fz(),t=Pn(),n=Pi(),r=kd.indexOf(t.pathname),i=()=>{r<kd.length-1&&n(kd[r+1])},o=()=>{r>0&&n(kd[r-1])},c=async()=>{window.location.reload()};return l.jsxs("div",{className:"min-h-screen bg-bg",children:[l.jsx("div",{className:"hidden lg:block",children:l.jsx(NF,{})}),l.jsx("div",{className:"lg:hidden",children:l.jsx(MF,{})}),l.jsxs("div",{className:tt("transition-all duration-200 ease-out",e?"lg:ml-[240px]":"lg:ml-[72px]"),children:[l.jsx(_F,{}),l.jsx("main",{className:"p-4 lg:p-10",children:l.jsx(kF,{children:l.jsx(PF,{onSwipeLeft:i,onSwipeRight:o,children:l.jsx(RF,{onRefresh:c,children:l.jsx(Tq,{})})})})})]})]})}const Do=P.forwardRef(({label:e,error:t,icon:n,className:r,...i},o)=>l.jsxs("div",{className:"w-full",children:[e&&l.jsx("label",{className:"block text-sm font-medium text-text-primary mb-1.5",children:e}),l.jsxs("div",{className:"relative",children:[n&&l.jsx("div",{className:"absolute left-3.5 top-1/2 -translate-y-1/2 text-text-secondary",children:n}),l.jsx("input",{ref:o,className:tt("w-full h-11 rounded-[14px] border bg-surface text-text-primary text-sm","placeholder:text-text-secondary/50","focus:outline-none focus:ring-2 focus:ring-primary/20 focus:border-primary/30","transition-all duration-150",n?"pl-10 pr-4":"px-4",t&&"border-danger focus:ring-danger/20 focus:border-danger/30",r),...i})]}),t&&l.jsx("p",{className:"mt-1.5 text-xs text-danger",children:t})]}));Do.displayName="Input";function ht({children:e,variant:t="primary",size:n="md",loading:r=!1,icon:i,className:o,disabled:c,...f}){const d={primary:"bg-primary text-white hover:bg-primary-hover shadow-sm",secondary:"bg-surface text-text-primary border border-border hover:bg-white",ghost:"bg-transparent text-text-secondary hover:bg-primary-light hover:text-primary",danger:"bg-danger text-white hover:opacity-90"},h={sm:"h-8 px-3 text-xs",md:"h-10 px-4 text-sm",lg:"h-12 px-6 text-sm"};return l.jsxs("button",{className:tt("inline-flex items-center justify-center gap-2 rounded-[14px] font-medium transition-colors duration-150","focus:outline-none focus:ring-2 focus:ring-primary/20","disabled:opacity-50 disabled:cursor-not-allowed","active:scale-[0.98]",d[t],h[n],o),disabled:c||r,...f,children:[r?l.jsxs("svg",{className:"animate-spin h-4 w-4",viewBox:"0 0 24 24",children:[l.jsx("circle",{className:"opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor",strokeWidth:"4",fill:"none"}),l.jsx("path",{className:"opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4z"})]}):i,e]})}const zF="/api/v1";function LF(){var e;try{const t=localStorage.getItem("amos-auth");if(t){const n=JSON.parse(t);if((e=n.state)!=null&&e.token)return n.state.token}}catch{}return localStorage.getItem("amos_token")}async function Dd(e,t,n){const r=`${zF}${t}`,i={"Content-Type":"application/json"},o=LF();o&&(i.Authorization=`Bearer ${o}`);const c=await fetch(r,{method:e,headers:i,body:n?JSON.stringify(n):void 0});if(!c.ok){const f=await c.json().catch(()=>({}));throw c.status===503?new Error(f.error||"Integration not configured"):new Error(f.message||`HTTP ${c.status}`)}return c.json()}const Te={get:e=>Dd("GET",e),post:(e,t)=>Dd("POST",e,t),put:(e,t)=>Dd("PUT",e,t),delete:e=>Dd("DELETE",e)},nE={login:(e,t)=>Te.post("/auth/login",{email:e,password:t}),me:()=>Te.get("/auth/me")},og={customers:()=>Te.get("/crm/customers"),leads:()=>Te.get("/crm/leads"),pipeline:()=>Te.get("/crm/pipeline"),createCustomer:e=>Te.post("/crm/customers",e),updateCustomer:(e,t)=>Te.put(`/crm/customers/${e}`,t),deleteCustomer:e=>Te.delete(`/crm/customers/${e}`)},zd={deals:()=>Te.get("/sales/deals"),products:()=>Te.get("/sales/products"),mrr:()=>Te.get("/sales/mrr"),arr:()=>Te.get("/sales/arr"),createDeal:e=>Te.post("/sales/deals",e),updateDeal:(e,t)=>Te.put(`/sales/deals/${e}`,t)},vo={balance:()=>Te.get("/finance/balance?period="),income:()=>Te.get("/finance/income?period="),moms:()=>Te.get("/finance/moms?period="),accounts:()=>Te.get("/finance/accounts"),invoices:()=>Te.get("/finance/invoices"),cashflow:()=>Te.get("/finance/cashflow")},rE={engines:()=>Te.get("/amos/engines"),engineDetails:e=>Te.get(`/amos/engines/${e}`),restartEngine:e=>Te.post(`/amos/engines/${e}/restart`),engineLogs:e=>Te.get(`/amos/engines/${e}/logs`)},Ld={zoomers:()=>Te.get("/quixzoom/zoomers"),zoomer:e=>Te.get(`/quixzoom/zoomers/${e}`),fieldData:()=>Te.get("/quixzoom/field-data"),payouts:()=>Te.get("/quixzoom/payouts"),payoutStats:()=>Te.get("/quixzoom/payouts/stats"),insights:()=>Te.get("/quixzoom/insights")},$d={entities:()=>Te.get("/landvex/entities"),entity:e=>Te.get(`/landvex/entities/${e}`),documents:()=>Te.get("/landvex/documents"),compliance:()=>Te.get("/landvex/compliance"),ownership:()=>Te.get("/landvex/ownership")},Bd={ledger:()=>Te.get("/accounting/ledger"),accounts:()=>Te.get("/accounting/accounts"),vismaStatus:()=>Te.get("/accounting/visma/status"),syncVisma:()=>Te.post("/accounting/visma/sync")},Ec={iso:()=>Te.get("/compliance/iso"),gdpr:()=>Te.get("/compliance/gdpr"),risks:()=>Te.get("/compliance/risks"),legalCases:()=>Te.get("/compliance/legal-cases"),policies:()=>Te.get("/compliance/policies")},aE={employees:()=>Te.get("/hr/employees"),leaves:()=>Te.get("/hr/leaves"),createEmployee:e=>Te.post("/hr/employees",e),createLeave:e=>Te.post("/hr/leaves",e)};function $F(){const e=Pi(),{login:t}=za(),[n,r]=P.useState(""),[i,o]=P.useState(""),[c,f]=P.useState(!1),[d,h]=P.useState(""),[p,y]=P.useState(!1),x=async j=>{var w;j.preventDefault(),h(""),y(!0);try{const S=await nE.login(n,i);if(!S.ok){h("Invalid credentials");return}localStorage.setItem("amos_token",S.token);const b=await nE.me();t(S.token,{id:b.user.sub,email:b.user.email,name:"Erik Svensson",role:((w=b.user.roles)==null?void 0:w[0])||"user"}),e("/")}catch(S){h(S instanceof Error?S.message:"Login failed")}finally{y(!1)}};return l.jsx("div",{className:"min-h-screen bg-bg flex items-center justify-center p-4",children:l.jsxs(Gn.div,{initial:{opacity:0,y:16},animate:{opacity:1,y:0},transition:{duration:.3,ease:"easeOut"},className:"w-full max-w-[400px]",children:[l.jsx("div",{className:"flex items-center justify-center mb-10",children:l.jsx("div",{className:"w-12 h-12 rounded-xl bg-primary flex items-center justify-center",children:l.jsx("svg",{width:"24",height:"24",viewBox:"0 0 32 32",fill:"none",children:l.jsx("path",{d:"M10 22L16 10L22 22H10Z",stroke:"white",strokeWidth:"2.5",strokeLinejoin:"round"})})})}),l.jsxs("div",{className:"text-center mb-8",children:[l.jsx("h1",{className:"text-2xl font-semibold text-text-primary",children:"Welcome back"}),l.jsx("p",{className:"text-sm text-text-secondary mt-1.5",children:"Sign in to your AMOS account"})]}),l.jsxs("form",{onSubmit:x,className:"space-y-4",children:[l.jsx(Do,{label:"Email",type:"email",placeholder:"you@company.com",value:n,onChange:j=>r(j.target.value),icon:l.jsx(Sn,{size:16}),required:!0}),l.jsxs("div",{className:"relative",children:[l.jsx(Do,{label:"Password",type:c?"text":"password",placeholder:"Enter your password",value:i,onChange:j=>o(j.target.value),icon:l.jsx(gz,{size:16}),required:!0}),l.jsx("button",{type:"button",onClick:()=>f(!c),className:"absolute right-3.5 top-[38px] text-text-secondary hover:text-text-primary transition-colors",children:c?l.jsx(CH,{size:16}):l.jsx(pz,{size:16})})]}),d&&l.jsx(Gn.p,{initial:{opacity:0,y:-4},animate:{opacity:1,y:0},className:"text-sm text-danger",children:d}),l.jsx(ht,{type:"submit",size:"lg",loading:p,className:"w-full",children:"Sign in"})]})]})})}function ee({children:e,className:t,hover:n=!1,padding:r="lg"}){const i={sm:"p-4",md:"p-5",lg:"p-6 md:p-8"};return l.jsx(Gn.div,{initial:{opacity:0,y:8},animate:{opacity:1,y:0},transition:{duration:.18,ease:"easeOut"},className:tt("bg-surface rounded-[20px] card-shadow",i[r],n&&"transition-shadow duration-200 hover:shadow-hover cursor-pointer",t),children:e})}function Ie({title:e,subtitle:t,action:n,className:r}){return l.jsxs("div",{className:tt("flex items-start justify-between mb-6",r),children:[l.jsxs("div",{children:[l.jsx("h3",{className:"text-base font-semibold text-text-primary",children:e}),t&&l.jsx("p",{className:"text-sm text-text-secondary mt-0.5",children:t})]}),n&&l.jsx("div",{children:n})]})}function BF(){var j,w;const[e,t]=P.useState(!0),[n,r]=P.useState(""),[i,o]=P.useState(null),[c,f]=P.useState(null),{token:d}=za();if(P.useEffect(()=>{async function S(){t(!0),r("");try{const[b,A]=await Promise.all([fetch("/api/v1/unified/dashboard",{headers:{Authorization:`Bearer ${d}`}}),fetch("/api/v1/social/stats",{headers:{Authorization:`Bearer ${d}`}})]),_=await b.json(),O=await A.json();_.ok?o(_.dashboard):r(_.error||"Failed to load dashboard"),O.ok&&f(O.stats)}catch{r("Failed to load dashboard")}finally{t(!1)}}d&&S()},[d]),e)return l.jsx("div",{className:"p-4 space-y-4",children:l.jsxs("div",{className:"animate-pulse space-y-4",children:[l.jsx("div",{className:"h-8 bg-surface rounded w-1/3"}),l.jsxs("div",{className:"grid grid-cols-2 gap-3",children:[l.jsx("div",{className:"h-24 bg-surface rounded"}),l.jsx("div",{className:"h-24 bg-surface rounded"}),l.jsx("div",{className:"h-24 bg-surface rounded"}),l.jsx("div",{className:"h-24 bg-surface rounded"})]})]})});if(n)return l.jsx("div",{className:"flex items-center justify-center h-64",children:l.jsxs("div",{className:"text-center",children:[l.jsx(Yt,{size:48,className:"mx-auto text-danger mb-4"}),l.jsx("p",{className:"text-danger",children:n})]})});if(!i)return null;const{crm:h,finance:p,mail:y,team:x}=i;return l.jsxs("div",{className:"p-4 space-y-6",children:[l.jsx("h1",{className:"text-2xl font-bold",children:"Översikt"}),l.jsxs("section",{children:[l.jsxs("h2",{className:"text-sm font-medium text-text-secondary mb-3 flex items-center gap-2",children:[l.jsx(vs,{size:16}),"Ekonomi"]}),l.jsxs("div",{className:"grid grid-cols-2 gap-3",children:[l.jsx(ee,{className:"overflow-hidden",children:l.jsxs("div",{className:"p-3",children:[l.jsx("p",{className:"text-xs text-text-secondary mb-1",children:"Omsättning H1 2026"}),l.jsx("p",{className:"text-lg font-bold",children:we((p==null?void 0:p.revenue)||0)})]})}),l.jsx(ee,{className:"overflow-hidden",children:l.jsxs("div",{className:"p-3",children:[l.jsx("p",{className:"text-xs text-text-secondary mb-1",children:"MOMS att betala"}),l.jsx("p",{className:"text-lg font-bold",children:we((p==null?void 0:p.moms)||0)})]})})]})]}),l.jsxs("section",{children:[l.jsxs("h2",{className:"text-sm font-medium text-text-secondary mb-3 flex items-center gap-2",children:[l.jsx(Wn,{size:16}),"CRM"]}),l.jsxs("div",{className:"grid grid-cols-2 gap-3",children:[l.jsx(ee,{className:"overflow-hidden",children:l.jsxs("div",{className:"p-3",children:[l.jsx("p",{className:"text-xs text-text-secondary mb-1",children:"Kunder"}),l.jsx("p",{className:"text-lg font-bold",children:((j=h==null?void 0:h.customers)==null?void 0:j.length)||0})]})}),l.jsx(ee,{className:"overflow-hidden",children:l.jsxs("div",{className:"p-3",children:[l.jsx("p",{className:"text-xs text-text-secondary mb-1",children:"Pipeline"}),l.jsx("p",{className:"text-lg font-bold",children:we((h==null?void 0:h.total_pipeline)||0)})]})})]}),((w=h==null?void 0:h.deals)==null?void 0:w.length)>0&&l.jsx("div",{className:"mt-3 space-y-2",children:h.deals.map(S=>l.jsx(ee,{className:"overflow-hidden",children:l.jsxs("div",{className:"p-3 flex items-center justify-between",children:[l.jsxs("div",{children:[l.jsx("p",{className:"font-medium text-sm",children:S.name}),l.jsx("p",{className:"text-xs text-text-secondary",children:S.stage})]}),l.jsxs("div",{className:"text-right",children:[l.jsx("p",{className:"font-bold text-sm",children:we(S.value)}),l.jsx("span",{className:`text-xs px-2 py-0.5 rounded-full ${S.status==="won"?"bg-success/10 text-success":S.status==="open"?"bg-accent/10 text-accent":"bg-text-tertiary/10 text-text-tertiary"}`,children:S.status==="won"?"Vunnen":S.stage==="proposal"?"Offert":S.stage==="negotiation"?"Förhandling":S.stage})]})]})},S.id))})]}),l.jsxs("section",{children:[l.jsxs("h2",{className:"text-sm font-medium text-text-secondary mb-3 flex items-center gap-2",children:[l.jsx(Sn,{size:16}),"E-post"]}),l.jsx(ee,{className:"overflow-hidden",children:l.jsx("div",{className:"p-3 flex items-center justify-between",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-full bg-accent/10 flex items-center justify-center",children:l.jsx(Sn,{size:20,className:"text-accent"})}),l.jsxs("div",{children:[l.jsxs("p",{className:"font-medium",children:[(y==null?void 0:y.total_messages)||0," meddelanden"]}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Alla inkorgar"})]})]})})})]}),l.jsxs("section",{children:[l.jsxs("h2",{className:"text-sm font-medium text-text-secondary mb-3 flex items-center gap-2",children:[l.jsx(La,{size:16}),"Team"]}),l.jsx("div",{className:"space-y-2",children:x==null?void 0:x.map((S,b)=>{var A;return l.jsx(ee,{className:"overflow-hidden",children:l.jsxs("div",{className:"p-3 flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-full bg-primary/10 flex items-center justify-center",children:l.jsx("span",{className:"font-bold text-primary text-sm",children:(A=S.name)==null?void 0:A.split(" ").map(_=>_[0]).join("")})}),l.jsxs("div",{children:[l.jsx("p",{className:"font-medium text-sm",children:S.name}),l.jsx("p",{className:"text-xs text-text-secondary",children:S.position})]}),l.jsx("span",{className:`ml-auto text-xs px-2 py-0.5 rounded-full ${S.status==="active"?"bg-success/10 text-success":"bg-text-tertiary/10 text-text-tertiary"}`,children:S.status==="active"?"Aktiv":"Inaktiv"})]})},b)})})]}),l.jsxs("section",{children:[l.jsxs("h2",{className:"text-sm font-medium text-text-secondary mb-3 flex items-center gap-2",children:[l.jsx(Lm,{size:16}),"Sociala Medier"]}),l.jsxs("div",{className:"grid grid-cols-2 gap-3",children:[l.jsx(ee,{className:"overflow-hidden",children:l.jsxs("div",{className:"p-3",children:[l.jsx("p",{className:"text-xs text-text-secondary mb-1",children:"Konton"}),l.jsx("p",{className:"text-lg font-bold",children:(c==null?void 0:c.accounts)||0})]})}),l.jsx(ee,{className:"overflow-hidden",children:l.jsxs("div",{className:"p-3",children:[l.jsx("p",{className:"text-xs text-text-secondary mb-1",children:"Följare"}),l.jsx("p",{className:"text-lg font-bold",children:((c==null?void 0:c.total_followers)||0).toLocaleString()})]})})]}),(!c||c.accounts===0)&&l.jsx(ee,{className:"overflow-hidden mt-3",children:l.jsxs("div",{className:"p-4 text-center",children:[l.jsx(yn,{size:32,className:"mx-auto text-text-tertiary mb-2"}),l.jsx("p",{className:"text-sm text-text-secondary",children:"Inga konton kopplade än"}),l.jsx("p",{className:"text-xs text-text-tertiary mt-1",children:"Gå till Social Media för att lägga till"})]})})]})]})}const qF={getRealBriefing:()=>Te.get("/briefing/real")};function Se({children:e,variant:t="default",size:n="sm",className:r}){const i={default:"bg-bg text-text-secondary",success:"bg-success-light text-success",warning:"bg-warning-light text-warning",danger:"bg-danger-light text-danger",primary:"bg-primary-light text-primary"},o={sm:"px-2 py-0.5 text-[11px]",md:"px-2.5 py-1 text-xs"};return l.jsx("span",{className:tt("inline-flex items-center rounded-full font-medium",i[t],o[n],r),children:e})}function qd({title:e,value:t,subtitle:n,icon:r,trend:i,trendValue:o,variant:c="default"}){const f={default:"bg-surface border-border",success:"bg-success/5 border-success/20",warning:"bg-warning/5 border-warning/20",danger:"bg-danger/5 border-danger/20"};return l.jsxs("div",{className:`p-4 rounded-xl border ${f[c]}`,children:[l.jsxs("div",{className:"flex items-start justify-between",children:[l.jsxs("div",{className:"space-y-1",children:[l.jsx("p",{className:"text-sm text-text-secondary",children:e}),l.jsx("p",{className:"text-2xl font-semibold",children:t}),n&&l.jsx("p",{className:"text-xs text-text-tertiary",children:n})]}),r&&l.jsx("div",{className:"text-text-secondary",children:r})]}),i&&l.jsxs("div",{className:"flex items-center gap-1 mt-2",children:[i==="up"&&l.jsx(ea,{size:14,className:"text-success"}),i==="down"&&l.jsx(Nz,{size:14,className:"text-danger"}),i==="neutral"&&l.jsx(zm,{size:14,className:"text-text-secondary"}),l.jsx("span",{className:`text-xs ${i==="up"?"text-success":i==="down"?"text-danger":"text-text-secondary"}`,children:o})]})]})}function IF({alert:e}){const t={info:{icon:l.jsx(zm,{size:16}),color:"text-primary bg-primary/5 border-primary/20"},warning:{icon:l.jsx(Yt,{size:16}),color:"text-warning bg-warning/5 border-warning/20"},critical:{icon:l.jsx(Yt,{size:16}),color:"text-danger bg-danger/5 border-danger/20"}},n=t[e.level]||t.info;return l.jsx("div",{className:`p-3 rounded-lg border ${n.color}`,children:l.jsxs("div",{className:"flex items-start gap-2",children:[n.icon,l.jsxs("div",{className:"flex-1 min-w-0",children:[l.jsx("p",{className:"text-sm font-medium",children:e.title}),l.jsx("p",{className:"text-xs opacity-80 mt-0.5",children:e.description})]}),l.jsx(Se,{variant:"default",className:"text-xs",children:e.source})]})})}function UF({action:e}){const t={10:"bg-danger text-white",9:"bg-danger/80 text-white",8:"bg-warning text-white",7:"bg-warning/80 text-white",6:"bg-primary text-white",5:"bg-primary/80 text-white"};return l.jsx("div",{className:"p-3 rounded-lg border border-border bg-surface hover:bg-surface-hover transition-colors cursor-pointer group",children:l.jsxs("div",{className:"flex items-start gap-3",children:[l.jsx("div",{className:`w-6 h-6 rounded-full flex items-center justify-center text-xs font-medium shrink-0 ${t[e.priority]||"bg-text-secondary text-white"}`,children:e.priority}),l.jsxs("div",{className:"flex-1 min-w-0",children:[l.jsx("p",{className:"text-sm font-medium group-hover:text-primary transition-colors",children:e.title}),l.jsx("p",{className:"text-xs text-text-secondary mt-0.5",children:e.description}),l.jsxs("div",{className:"flex items-center gap-3 mt-2",children:[l.jsxs("span",{className:"text-xs text-text-tertiary flex items-center gap-1",children:[l.jsx(vr,{size:12}),e.time_estimate]}),l.jsx("span",{className:"text-xs text-text-tertiary",children:e.impact})]})]}),l.jsx(bH,{size:16,className:"text-text-tertiary group-hover:text-primary transition-colors shrink-0"})]})})}function VF({task:e}){const t={critical:"danger",high:"warning",medium:"default",low:"success"};return l.jsxs("div",{className:"flex items-center gap-3 p-2 rounded-lg hover:bg-surface-hover transition-colors",children:[l.jsx("div",{className:"w-2 h-2 rounded-full bg-warning shrink-0"}),l.jsxs("div",{className:"flex-1 min-w-0",children:[l.jsx("p",{className:"text-sm truncate",children:e.title}),l.jsxs("div",{className:"flex items-center gap-2 mt-0.5",children:[l.jsx(Se,{variant:t[e.priority],className:"text-xs",children:e.priority}),l.jsx("span",{className:"text-xs text-text-tertiary",children:e.category})]})]}),l.jsxs("span",{className:"text-xs text-text-tertiary shrink-0",children:[e.days_open,"d"]})]})}function HF({deal:e}){return l.jsxs("div",{className:"flex items-center gap-3 p-2 rounded-lg hover:bg-surface-hover transition-colors",children:[l.jsx("div",{className:"w-8 h-8 rounded-lg bg-primary/10 flex items-center justify-center shrink-0",children:l.jsx(ou,{size:16,className:"text-primary"})}),l.jsxs("div",{className:"flex-1 min-w-0",children:[l.jsx("p",{className:"text-sm font-medium truncate",children:e.name}),l.jsx("p",{className:"text-xs text-text-secondary",children:e.customer})]}),l.jsxs("div",{className:"text-right shrink-0",children:[l.jsx("p",{className:"text-sm font-medium",children:we(e.value)}),l.jsxs("p",{className:"text-xs text-text-tertiary",children:[e.probability,"%"]})]})]})}function ke({className:e}){return l.jsx("div",{className:tt("animate-pulse rounded-[14px] bg-text-secondary/8",e)})}function FF(){var j;const[e,t]=P.useState(null),[n,r]=P.useState(!0),[i,o]=P.useState("");if(P.useEffect(()=>{async function w(){try{r(!0);const b=await qF.getRealBriefing();t(b)}catch(b){o(b instanceof Error?b.message:"Failed to load briefing")}finally{r(!1)}}w();const S=setInterval(w,3e5);return()=>clearInterval(S)},[]),n)return l.jsxs("div",{className:"space-y-6",children:[l.jsx("div",{className:"grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-4",children:Array.from({length:4}).map((w,S)=>l.jsx(ke,{className:"h-[120px]"},S))}),l.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-3 gap-6",children:[l.jsx(ke,{className:"h-[400px] lg:col-span-2"}),l.jsx(ke,{className:"h-[400px]"})]})]});if(i)return l.jsx("div",{className:"flex items-center justify-center h-64",children:l.jsxs("div",{className:"text-center",children:[l.jsx(Yt,{size:48,className:"text-danger mx-auto mb-4"}),l.jsx("p",{className:"text-danger font-medium",children:i}),l.jsx("button",{onClick:()=>window.location.reload(),className:"mt-4 px-4 py-2 bg-primary text-white rounded-lg hover:bg-primary-hover transition-colors",children:"Försök igen"})]})});if(!e)return null;const{company_health:c,my_tasks:f,my_deals:d,team_overview:h,financial_status:p,alerts:y,actions:x}=e;return l.jsxs("div",{className:"space-y-6",children:[l.jsxs("div",{className:"flex items-center justify-between",children:[l.jsxs("div",{children:[l.jsx("h1",{className:"text-2xl font-bold",children:"Dagsöversikt"}),l.jsxs("p",{className:"text-text-secondary",children:[e.user.name," • ",new Date(e.generated_at).toLocaleDateString("sv-SE",{weekday:"long",year:"numeric",month:"long",day:"numeric"})]})]}),l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx("div",{className:`w-2 h-2 rounded-full ${c.status==="healthy"?"bg-success":c.status==="warning"?"bg-warning":"bg-danger"}`}),l.jsx("span",{className:"text-sm text-text-secondary capitalize",children:c.status})]})]}),l.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-4",children:[l.jsx(qd,{title:"Cash Position",value:we(c.cash_position),subtitle:"Eget kapital",icon:l.jsx(mz,{size:20}),trend:c.profit_margin>0?"up":"down",trendValue:`${eE(c.profit_margin)}% marginal`,variant:c.cash_position>1e6?"success":c.cash_position>5e5?"warning":"danger"}),l.jsx(qd,{title:"Pipeline",value:we(c.total_pipeline),subtitle:`${c.active_deals} aktiva deals`,icon:l.jsx(ou,{size:20}),trend:"up",trendValue:"+12% vs förra månaden"}),l.jsx(qd,{title:"Team",value:`${h.active_now}/${h.total_members}`,subtitle:`${h.on_leave} på leave`,icon:l.jsx(Wn,{size:20}),trend:h.on_leave>0?"neutral":"up",trendValue:h.on_leave>0?`${h.on_leave} borta idag`:"Alla närvarande"}),l.jsx(qd,{title:"Mina Tasks",value:f.length,subtitle:`${f.filter(w=>w.priority==="critical").length} kritiska`,icon:l.jsx(Sz,{size:20}),variant:f.filter(w=>w.priority==="critical").length>0?"danger":f.filter(w=>w.priority==="high").length>0?"warning":"success"})]}),y.length>0&&l.jsxs("div",{className:"space-y-2",children:[l.jsxs("h2",{className:"text-lg font-semibold flex items-center gap-2",children:[l.jsx(Yt,{size:20,className:"text-warning"}),"Varningar"]}),l.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-3",children:y.map((w,S)=>l.jsx(IF,{alert:w},S))})]}),l.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-3 gap-6",children:[l.jsxs("div",{className:"lg:col-span-2 space-y-6",children:[x.length>0&&l.jsxs(ee,{children:[l.jsx(Ie,{title:"Rekommenderade Åtgärder",subtitle:"Prioriterade baserat på din roll och aktuell data"}),l.jsx("div",{className:"p-4 space-y-3",children:x.map((w,S)=>l.jsx(UF,{action:w},S))})]}),l.jsxs(ee,{children:[l.jsx(Ie,{title:"Mina Uppgifter",subtitle:`${f.length} öppna uppgifter`}),l.jsx("div",{className:"p-4 space-y-1",children:f.length===0?l.jsxs("div",{className:"text-center py-8 text-text-secondary",children:[l.jsx(Xu,{size:48,className:"mx-auto mb-2 text-success"}),l.jsx("p",{children:"Alla uppgifter är klara!"})]}):f.map(w=>l.jsx(VF,{task:w},w.id))})]}),d.length>0&&l.jsxs(ee,{children:[l.jsx(Ie,{title:"Mina Deals",subtitle:`${d.length} aktiva förhandlingar`}),l.jsx("div",{className:"p-4 space-y-1",children:d.map(w=>l.jsx(HF,{deal:w},w.id))})]})]}),l.jsxs("div",{className:"space-y-6",children:[l.jsxs(ee,{children:[l.jsx(Ie,{title:"Teamöversikt",subtitle:`${h.total_members} medlemmar`}),l.jsxs("div",{className:"p-4",children:[l.jsxs("div",{className:"grid grid-cols-3 gap-2 mb-4",children:[l.jsxs("div",{className:"text-center p-2 bg-success/5 rounded-lg",children:[l.jsx("p",{className:"text-2xl font-semibold text-success",children:h.active_now}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Aktiva"})]}),l.jsxs("div",{className:"text-center p-2 bg-warning/5 rounded-lg",children:[l.jsx("p",{className:"text-2xl font-semibold text-warning",children:h.on_leave}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Borta"})]}),l.jsxs("div",{className:"text-center p-2 bg-primary/5 rounded-lg",children:[l.jsx("p",{className:"text-2xl font-semibold text-primary",children:h.open_tickets}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Tickets"})]})]}),l.jsx("div",{className:"space-y-2",children:h.members.slice(0,5).map((w,S)=>l.jsxs("div",{className:"flex items-center gap-2 p-2 rounded-lg hover:bg-surface-hover transition-colors",children:[l.jsx("div",{className:"w-8 h-8 rounded-full bg-primary/10 flex items-center justify-center text-xs font-medium text-primary",children:w.name.split(" ").map(b=>b[0]).join("")}),l.jsxs("div",{className:"flex-1 min-w-0",children:[l.jsx("p",{className:"text-sm font-medium truncate",children:w.name}),l.jsx("p",{className:"text-xs text-text-secondary",children:w.role})]}),w.open_tasks>0&&l.jsx(Se,{variant:"warning",className:"text-xs",children:w.open_tasks})]},S))})]})]}),l.jsxs(ee,{children:[l.jsx(Ie,{title:"Finansiell Status",subtitle:"Från ledger i realtid"}),l.jsxs("div",{className:"p-4 space-y-3",children:[l.jsxs("div",{className:"flex justify-between items-center",children:[l.jsx("span",{className:"text-sm text-text-secondary",children:"Tillgångar"}),l.jsx("span",{className:"text-sm font-medium",children:we(p.total_assets)})]}),l.jsxs("div",{className:"flex justify-between items-center",children:[l.jsx("span",{className:"text-sm text-text-secondary",children:"Skulder"}),l.jsx("span",{className:"text-sm font-medium",children:we(p.total_liabilities)})]}),l.jsxs("div",{className:"flex justify-between items-center",children:[l.jsx("span",{className:"text-sm text-text-secondary",children:"Eget Kapital"}),l.jsx("span",{className:"text-sm font-medium text-success",children:we(p.equity)})]}),p.runway_months>0&&l.jsxs("div",{className:"flex justify-between items-center",children:[l.jsx("span",{className:"text-sm text-text-secondary",children:"Runway"}),l.jsxs("span",{className:"text-sm font-medium",children:[eE(p.runway_months)," mån"]})]}),l.jsxs("div",{className:"pt-2 border-t border-border",children:[l.jsx("p",{className:"text-xs text-text-tertiary mb-2",children:"Top Konton"}),(j=p.top_accounts)==null?void 0:j.slice(0,3).map((w,S)=>l.jsxs("div",{className:"flex justify-between items-center py-1",children:[l.jsx("span",{className:"text-xs text-text-secondary",children:w.name}),l.jsx("span",{className:"text-xs font-medium",children:we(w.amount)})]},S))]})]})]})]})]})]})}function GF(){return l.jsx(FF,{})}function KF(){const{user:e}=za(),[t]=iI(),[n,r]=P.useState(null),[i,o]=P.useState(!0),[c,f]=P.useState(!1),[d,h]=P.useState(t.get("tab")||"general");P.useEffect(()=>{o(!0),fetch("/api/v1/users/me",{headers:{Authorization:`Bearer ${localStorage.getItem("token")}`}}).then(x=>x.json()).then(x=>{var j,w,S,b,A,_,O,T,N,E,M,D,R;r({id:((j=x.user)==null?void 0:j.id)||(e==null?void 0:e.id)||"",name:((w=x.user)==null?void 0:w.name)||(e==null?void 0:e.name)||"",email:((S=x.user)==null?void 0:S.email)||(e==null?void 0:e.email)||"",phone:((b=x.user)==null?void 0:b.phone)||"",role:((A=x.user)==null?void 0:A.role)||(e==null?void 0:e.role)||"user",department:((_=x.user)==null?void 0:_.department)||"",timezone:((O=x.user)==null?void 0:O.timezone)||"Europe/Stockholm",language:((T=x.user)==null?void 0:T.language)||"sv",notifications:((N=x.user)==null?void 0:N.notifications)||{email:!0,push:!0,sms:!1},theme:((E=x.user)==null?void 0:E.theme)||"light",twoFactorEnabled:((M=x.user)==null?void 0:M.twoFactorEnabled)||!1,lastLogin:((D=x.user)==null?void 0:D.lastLogin)||new Date().toISOString(),createdAt:((R=x.user)==null?void 0:R.createdAt)||new Date().toISOString()}),o(!1)}).catch(()=>{r({id:(e==null?void 0:e.id)||"",name:(e==null?void 0:e.name)||"",email:(e==null?void 0:e.email)||"",phone:"",role:(e==null?void 0:e.role)||"user",department:"",timezone:"Europe/Stockholm",language:"sv",notifications:{email:!0,push:!0,sms:!1},theme:"light",twoFactorEnabled:!1,lastLogin:new Date().toISOString(),createdAt:new Date().toISOString()}),o(!1)})},[e]);const p=async()=>{f(!0),await new Promise(x=>setTimeout(x,1e3)),f(!1)};if(i)return l.jsxs("div",{className:"space-y-6",children:[l.jsx(ke,{className:"h-[200px]"}),l.jsx(ke,{className:"h-[400px]"})]});if(!n)return null;const y=[{id:"general",label:"Allmänt",icon:U1},{id:"security",label:"Säkerhet",icon:Xr},{id:"notifications",label:"Notifikationer",icon:q1},{id:"preferences",label:"Inställningar",icon:yn}];return l.jsxs("div",{className:"space-y-6",children:[l.jsxs("div",{className:"flex items-center justify-between",children:[l.jsxs("div",{children:[l.jsx("h1",{className:"text-2xl font-bold",children:"Min Profil"}),l.jsx("p",{className:"text-text-secondary",children:"Hantera dina kontoinställningar"})]}),l.jsx(ht,{onClick:p,disabled:c,icon:c?void 0:l.jsx(IH,{size:16}),children:c?"Sparar...":"Spara ändringar"})]}),l.jsxs(ee,{className:"relative overflow-hidden",children:[l.jsx("div",{className:"h-32 bg-gradient-to-r from-primary to-primary-hover"}),l.jsxs("div",{className:"px-6 pb-6",children:[l.jsx("div",{className:"relative -mt-16 mb-4",children:l.jsxs("div",{className:"w-32 h-32 rounded-2xl bg-surface border-4 border-bg flex items-center justify-center text-4xl font-bold text-primary relative",children:[n.avatar?l.jsx("img",{src:n.avatar,alt:n.name,className:"w-full h-full rounded-2xl object-cover"}):n.name.split(" ").map(x=>x[0]).join(""),l.jsx("button",{className:"absolute bottom-0 right-0 w-8 h-8 bg-primary text-white rounded-full flex items-center justify-center hover:bg-primary-hover transition-colors",children:l.jsx(uh,{size:14})})]})}),l.jsxs("div",{className:"flex items-start justify-between",children:[l.jsxs("div",{children:[l.jsx("h2",{className:"text-xl font-semibold",children:n.name}),l.jsx("p",{className:"text-text-secondary",children:n.email}),l.jsxs("div",{className:"flex items-center gap-2 mt-2",children:[l.jsx(Se,{variant:"primary",children:n.role}),l.jsx(Se,{variant:"default",children:n.department})]})]}),l.jsxs("div",{className:"text-right text-sm text-text-secondary",children:[l.jsxs("p",{children:["Senaste inloggning: ",Rt(n.lastLogin)]}),l.jsxs("p",{children:["Medlem sedan: ",Rt(n.createdAt)]})]})]})]})]}),l.jsx("div",{className:"flex items-center gap-1 bg-bg rounded-xl p-1 overflow-x-auto",children:y.map(x=>l.jsxs("button",{onClick:()=>h(x.id),className:`px-4 py-2 text-sm font-medium rounded-lg transition-colors whitespace-nowrap flex items-center gap-2 ${d===x.id?"bg-surface text-text-primary shadow-sm":"text-text-secondary hover:text-text-primary"}`,children:[l.jsx(x.icon,{size:16}),x.label]},x.id))}),d==="general"&&l.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-6",children:[l.jsxs(ee,{children:[l.jsx(Ie,{title:"Personlig information",subtitle:"Uppdatera dina kontouppgifter"}),l.jsxs("div",{className:"p-4 space-y-4",children:[l.jsxs("div",{children:[l.jsx("label",{className:"block text-sm font-medium mb-1",children:"Fullständigt namn"}),l.jsxs("div",{className:"relative",children:[l.jsx(U1,{size:16,className:"absolute left-3 top-1/2 -translate-y-1/2 text-text-secondary"}),l.jsx("input",{type:"text",value:n.name,onChange:x=>r({...n,name:x.target.value}),className:"w-full h-10 pl-9 pr-4 rounded-[14px] border bg-surface text-sm"})]})]}),l.jsxs("div",{children:[l.jsx("label",{className:"block text-sm font-medium mb-1",children:"E-post"}),l.jsxs("div",{className:"relative",children:[l.jsx(Sn,{size:16,className:"absolute left-3 top-1/2 -translate-y-1/2 text-text-secondary"}),l.jsx("input",{type:"email",value:n.email,onChange:x=>r({...n,email:x.target.value}),className:"w-full h-10 pl-9 pr-4 rounded-[14px] border bg-surface text-sm"})]})]}),l.jsxs("div",{children:[l.jsx("label",{className:"block text-sm font-medium mb-1",children:"Telefon"}),l.jsxs("div",{className:"relative",children:[l.jsx(YT,{size:16,className:"absolute left-3 top-1/2 -translate-y-1/2 text-text-secondary"}),l.jsx("input",{type:"tel",value:n.phone||"",onChange:x=>r({...n,phone:x.target.value}),className:"w-full h-10 pl-9 pr-4 rounded-[14px] border bg-surface text-sm"})]})]}),l.jsxs("div",{children:[l.jsx("label",{className:"block text-sm font-medium mb-1",children:"Avdelning"}),l.jsxs("div",{className:"relative",children:[l.jsx(La,{size:16,className:"absolute left-3 top-1/2 -translate-y-1/2 text-text-secondary"}),l.jsx("input",{type:"text",value:n.department||"",onChange:x=>r({...n,department:x.target.value}),className:"w-full h-10 pl-9 pr-4 rounded-[14px] border bg-surface text-sm"})]})]})]})]}),l.jsxs(ee,{children:[l.jsx(Ie,{title:"Kontoinformation",subtitle:"Dina kontodetaljer"}),l.jsxs("div",{className:"p-4 space-y-4",children:[l.jsxs("div",{className:"flex items-center justify-between py-3 border-b border-border",children:[l.jsxs("div",{children:[l.jsx("p",{className:"text-sm font-medium",children:"Användar-ID"}),l.jsx("p",{className:"text-xs text-text-secondary",children:n.id})]}),l.jsx(Se,{variant:"default",children:"Aktiv"})]}),l.jsxs("div",{className:"flex items-center justify-between py-3 border-b border-border",children:[l.jsxs("div",{children:[l.jsx("p",{className:"text-sm font-medium",children:"Roll"}),l.jsx("p",{className:"text-xs text-text-secondary",children:n.role})]}),l.jsx(Xr,{size:16,className:"text-primary"})]}),l.jsxs("div",{className:"flex items-center justify-between py-3 border-b border-border",children:[l.jsxs("div",{children:[l.jsx("p",{className:"text-sm font-medium",children:"Tidszon"}),l.jsx("p",{className:"text-xs text-text-secondary",children:n.timezone})]}),l.jsx(yn,{size:16,className:"text-text-secondary"})]}),l.jsxs("div",{className:"flex items-center justify-between py-3",children:[l.jsxs("div",{children:[l.jsx("p",{className:"text-sm font-medium",children:"Språk"}),l.jsx("p",{className:"text-xs text-text-secondary",children:n.language==="sv"?"Svenska":n.language})]}),l.jsx(yn,{size:16,className:"text-text-secondary"})]})]})]})]}),d==="security"&&l.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-6",children:[l.jsxs(ee,{children:[l.jsx(Ie,{title:"Lösenord",subtitle:"Uppdatera ditt lösenord"}),l.jsxs("div",{className:"p-4 space-y-4",children:[l.jsxs("div",{children:[l.jsx("label",{className:"block text-sm font-medium mb-1",children:"Nuvarande lösenord"}),l.jsxs("div",{className:"relative",children:[l.jsx(FT,{size:16,className:"absolute left-3 top-1/2 -translate-y-1/2 text-text-secondary"}),l.jsx("input",{type:"password",placeholder:"••••••••",className:"w-full h-10 pl-9 pr-4 rounded-[14px] border bg-surface text-sm"})]})]}),l.jsxs("div",{children:[l.jsx("label",{className:"block text-sm font-medium mb-1",children:"Nytt lösenord"}),l.jsx("input",{type:"password",placeholder:"Minst 8 tecken",className:"w-full h-10 px-4 rounded-[14px] border bg-surface text-sm"})]}),l.jsxs("div",{children:[l.jsx("label",{className:"block text-sm font-medium mb-1",children:"Bekräfta nytt lösenord"}),l.jsx("input",{type:"password",placeholder:"Upprepa lösenord",className:"w-full h-10 px-4 rounded-[14px] border bg-surface text-sm"})]}),l.jsxs(ht,{variant:"secondary",className:"w-full",children:[l.jsx(FT,{size:16,className:"mr-2"}),"Ändra lösenord"]})]})]}),l.jsxs(ee,{children:[l.jsx(Ie,{title:"Tvåfaktorsautentisering",subtitle:"Öka säkerheten på ditt konto"}),l.jsxs("div",{className:"p-4",children:[l.jsxs("div",{className:"flex items-center justify-between mb-4",children:[l.jsxs("div",{children:[l.jsx("p",{className:"text-sm font-medium",children:"2FA-status"}),l.jsx("p",{className:"text-xs text-text-secondary",children:n.twoFactorEnabled?"Aktiverad":"Ej aktiverad"})]}),l.jsx(Se,{variant:n.twoFactorEnabled?"success":"default",children:n.twoFactorEnabled?"Aktiv":"Inaktiv"})]}),!n.twoFactorEnabled&&l.jsxs(ht,{className:"w-full",children:[l.jsx(Xr,{size:16,className:"mr-2"}),"Aktivera 2FA"]})]})]})]}),d==="notifications"&&l.jsxs(ee,{children:[l.jsx(Ie,{title:"Notifikationsinställningar",subtitle:"Hantera hur du får notifieringar"}),l.jsx("div",{className:"p-4 space-y-4",children:[{key:"email",label:"E-postnotifikationer",description:"Få uppdateringar via e-post",icon:Sn},{key:"push",label:"Push-notifikationer",description:"Få notifikationer i webbläsaren",icon:q1},{key:"sms",label:"SMS-notifikationer",description:"Få viktiga uppdateringar via SMS",icon:YT}].map(x=>l.jsxs("div",{className:"flex items-center justify-between py-3 border-b border-border last:border-0",children:[l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary/10 flex items-center justify-center text-primary",children:l.jsx(x.icon,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-sm font-medium",children:x.label}),l.jsx("p",{className:"text-xs text-text-secondary",children:x.description})]})]}),l.jsxs("label",{className:"relative inline-flex items-center cursor-pointer",children:[l.jsx("input",{type:"checkbox",checked:n.notifications[x.key],onChange:j=>r({...n,notifications:{...n.notifications,[x.key]:j.target.checked}}),className:"sr-only peer"}),l.jsx("div",{className:"w-11 h-6 bg-border peer-focus:outline-none rounded-full peer peer-checked:after:translate-x-full peer-checked:after:border-white after:content-[''] after:absolute after:top-[2px] after:left-[2px] after:bg-white after:border-gray-300 after:border after:rounded-full after:h-5 after:w-5 after:transition-all peer-checked:bg-primary"})]})]},x.key))})]}),d==="preferences"&&l.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-6",children:[l.jsxs(ee,{children:[l.jsx(Ie,{title:"Utseende",subtitle:"Anpassa hur BOC ser ut"}),l.jsx("div",{className:"p-4 space-y-4",children:l.jsxs("div",{children:[l.jsx("label",{className:"block text-sm font-medium mb-2",children:"Tema"}),l.jsx("div",{className:"grid grid-cols-3 gap-3",children:[{id:"light",label:"Ljust",icon:wz},{id:"dark",label:"Mörkt",icon:jz},{id:"system",label:"System",icon:$H}].map(x=>l.jsxs("button",{onClick:()=>r({...n,theme:x.id}),className:`p-3 rounded-xl border text-center transition-colors ${n.theme===x.id?"border-primary bg-primary/5 text-primary":"border-border hover:border-primary/30"}`,children:[l.jsx(x.icon,{size:20,className:"mx-auto mb-1"}),l.jsx("span",{className:"text-xs",children:x.label})]},x.id))})]})})]}),l.jsxs(ee,{children:[l.jsx(Ie,{title:"Regionala inställningar",subtitle:"Språk och tidszon"}),l.jsxs("div",{className:"p-4 space-y-4",children:[l.jsxs("div",{children:[l.jsx("label",{className:"block text-sm font-medium mb-1",children:"Språk"}),l.jsxs("select",{value:n.language,onChange:x=>r({...n,language:x.target.value}),className:"w-full h-10 px-4 rounded-[14px] border bg-surface text-sm",children:[l.jsx("option",{value:"sv",children:"Svenska"}),l.jsx("option",{value:"en",children:"English"}),l.jsx("option",{value:"no",children:"Norsk"}),l.jsx("option",{value:"da",children:"Dansk"}),l.jsx("option",{value:"fi",children:"Suomi"})]})]}),l.jsxs("div",{children:[l.jsx("label",{className:"block text-sm font-medium mb-1",children:"Tidszon"}),l.jsxs("select",{value:n.timezone,onChange:x=>r({...n,timezone:x.target.value}),className:"w-full h-10 px-4 rounded-[14px] border bg-surface text-sm",children:[l.jsx("option",{value:"Europe/Stockholm",children:"Stockholm (CET)"}),l.jsx("option",{value:"Europe/Oslo",children:"Oslo (CET)"}),l.jsx("option",{value:"Europe/Copenhagen",children:"Köpenhamn (CET)"}),l.jsx("option",{value:"Europe/Helsinki",children:"Helsingfors (EET)"}),l.jsx("option",{value:"UTC",children:"UTC"})]})]})]})]})]})]})}function $a({children:e,className:t}){return l.jsx("div",{className:"w-full overflow-x-auto",children:l.jsx("table",{className:tt("w-full",t),children:e})})}function Ba({children:e,className:t}){return l.jsx("thead",{className:tt("border-b border-border",t),children:e})}function qa({children:e,className:t}){return l.jsx("tbody",{className:t,children:e})}function Nt({children:e,className:t}){return l.jsx("tr",{className:tt("border-b border-border/50 transition-colors hover:bg-bg/50",t),children:e})}function be({children:e,className:t,align:n="left",colSpan:r}){const i={left:"text-left",center:"text-center",right:"text-right"};return l.jsx("th",{colSpan:r,className:tt("py-3 px-4 text-xs font-medium text-text-secondary uppercase tracking-wider",i[n],t),children:e})}function ge({children:e,className:t,align:n="left",colSpan:r}){const i={left:"text-left",center:"text-center",right:"text-right"};return l.jsx("td",{colSpan:r,className:tt("py-3.5 px-4 text-sm text-text-primary",i[n],t),children:e})}function iE({icon:e,title:t,description:n,action:r,className:i}){return l.jsxs("div",{className:tt("flex flex-col items-center justify-center py-16 text-center",i),children:[e&&l.jsx("div",{className:"mb-4 text-text-secondary/40",children:e}),l.jsx("h3",{className:"text-sm font-medium text-text-primary",children:t}),n&&l.jsx("p",{className:"mt-1 text-sm text-text-secondary max-w-sm",children:n}),r&&l.jsx("div",{className:"mt-4",children:r})]})}function Rz({children:e,className:t,onClick:n}){return l.jsx("div",{onClick:n,className:tt("bg-surface rounded-2xl p-4 card-shadow border border-border/40",n&&"active:scale-[0.98] transition-transform cursor-pointer",t),children:e})}function lg({label:e,value:t,className:n}){return l.jsxs("div",{className:tt("flex justify-between items-center py-2",n),children:[l.jsx("span",{className:"text-sm text-text-secondary",children:e}),l.jsx("span",{className:"text-sm font-medium text-text-primary",children:t})]})}function kz({children:e,variant:t="default",className:n}){const r={default:"bg-bg text-text-secondary",success:"bg-success-light text-success",warning:"bg-warning-light text-warning",danger:"bg-danger-light text-danger",info:"bg-primary-light text-primary"};return l.jsx("span",{className:tt("text-xs font-medium px-2.5 py-1 rounded-full",r[t],n),children:e})}const YF=["Customers","Leads","Pipeline"];function XF(){const[e,t]=P.useState("Customers"),[n,r]=P.useState(""),[i,o]=P.useState(!0),[c,f]=P.useState(""),[d,h]=P.useState([]),[p,y]=P.useState(0),[x,j]=P.useState([]),[w,S]=P.useState([]);P.useEffect(()=>{async function O(){o(!0),f("");try{const[T,N,E]=await Promise.all([og.customers(),og.leads(),og.pipeline()]);h(T.customers),y(T.total),j(N.leads);const M=E;S(M.stages||M.pipeline||[])}catch(T){f(T instanceof Error?T.message:"Failed to load CRM data")}finally{o(!1)}}O()},[]);const b=d.filter(O=>O.name.toLowerCase().includes(n.toLowerCase())||(O.company||"").toLowerCase().includes(n.toLowerCase())),A=x.filter(O=>O.name.toLowerCase().includes(n.toLowerCase())||(O.company||"").toLowerCase().includes(n.toLowerCase())),_=w.reduce((O,T)=>O+(T.value||0),0);return i?l.jsxs("div",{className:"space-y-8",children:[l.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-3 gap-5",children:[l.jsx(ke,{className:"h-[80px]"}),l.jsx(ke,{className:"h-[80px]"}),l.jsx(ke,{className:"h-[80px]"})]}),l.jsx(ke,{className:"h-[400px]"})]}):c?l.jsx("div",{className:"flex items-center justify-center h-64",children:l.jsx("p",{className:"text-danger",children:c})}):l.jsxs("div",{className:"space-y-8",children:[l.jsxs("div",{className:"flex flex-col sm:flex-row sm:items-center justify-between gap-4",children:[l.jsxs("div",{children:[l.jsx("h1",{className:"text-xl font-semibold text-text-primary",children:"CRM"}),l.jsx("p",{className:"text-sm text-text-secondary mt-0.5",children:"Manage customers, leads, and pipeline"})]}),l.jsx(ht,{icon:l.jsx(Lr,{size:16}),children:"Add Contact"})]}),l.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-3 gap-5",children:[l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary-light flex items-center justify-center text-primary",children:l.jsx(Wn,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:p}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Total Customers"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-success-light flex items-center justify-center text-success",children:l.jsx(Sn,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:x.length}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Active Leads"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-warning-light flex items-center justify-center text-warning",children:l.jsx(La,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:new Intl.NumberFormat("sv-SE",{style:"currency",currency:"SEK",maximumFractionDigits:0}).format(_)}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Pipeline Value"})]})]})})]}),l.jsxs("div",{className:"flex flex-col sm:flex-row items-start sm:items-center justify-between gap-4",children:[l.jsx("div",{className:"flex items-center gap-1 bg-bg rounded-xl p-1",children:YF.map(O=>l.jsx("button",{onClick:()=>t(O),className:`px-4 py-2 text-sm font-medium rounded-lg transition-colors ${e===O?"bg-surface text-text-primary shadow-sm":"text-text-secondary hover:text-text-primary"}`,children:O},O))}),l.jsxs("div",{className:"flex items-center gap-2 w-full sm:w-auto",children:[l.jsxs("div",{className:"relative flex-1 sm:flex-initial",children:[l.jsx(Ts,{size:15,className:"absolute left-3 top-1/2 -translate-y-1/2 text-text-secondary"}),l.jsx("input",{type:"text",placeholder:"Search...",value:n,onChange:O=>r(O.target.value),className:"w-full sm:w-64 h-10 pl-9 pr-4 rounded-[14px] border bg-surface text-sm text-text-primary placeholder:text-text-secondary/50 focus:outline-none focus:ring-2 focus:ring-primary/20 focus:border-primary/30"})]}),l.jsx(ht,{variant:"secondary",size:"sm",icon:l.jsx(Wu,{size:14}),children:"Filter"})]})]}),e==="Customers"&&l.jsxs(ee,{children:[l.jsx("div",{className:"hidden md:block",children:l.jsxs($a,{children:[l.jsx(Ba,{children:l.jsxs(Nt,{children:[l.jsx(be,{children:"Customer"}),l.jsx(be,{children:"Company"}),l.jsx(be,{children:"Status"}),l.jsx(be,{children:"Phone"}),l.jsx(be,{children:"Created"}),l.jsx(be,{align:"right"})]})}),l.jsx(qa,{children:b.map(O=>l.jsxs(Nt,{children:[l.jsx(ge,{children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-8 h-8 rounded-lg bg-primary/10 text-primary flex items-center justify-center text-xs font-semibold",children:O.name.charAt(0)}),l.jsxs("div",{children:[l.jsx("p",{className:"font-medium text-text-primary",children:O.name}),l.jsx("p",{className:"text-xs text-text-secondary",children:O.email})]})]})}),l.jsx(ge,{children:O.company||"—"}),l.jsx(ge,{children:l.jsx(Se,{variant:O.status==="active"?"success":O.status==="lead"?"primary":"default",children:O.status})}),l.jsx(ge,{children:O.phone||"—"}),l.jsx(ge,{children:Rt(O.created_at)}),l.jsx(ge,{align:"right",children:l.jsx("button",{className:"w-8 h-8 flex items-center justify-center rounded-lg hover:bg-bg text-text-secondary",children:l.jsx(Jr,{size:16})})})]},O.id))})]})}),l.jsx("div",{className:"md:hidden p-4 space-y-3",children:b.map(O=>l.jsx(Rz,{children:l.jsxs("div",{className:"flex items-start gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary/10 text-primary flex items-center justify-center text-sm font-semibold shrink-0",children:O.name.charAt(0)}),l.jsxs("div",{className:"flex-1 min-w-0",children:[l.jsx("div",{className:"font-medium text-text-primary",children:O.name}),l.jsx("div",{className:"text-sm text-text-secondary",children:O.email}),O.company&&l.jsx("div",{className:"text-sm text-text-secondary mt-1",children:O.company}),l.jsxs("div",{className:"flex items-center gap-2 mt-2",children:[l.jsx(kz,{variant:O.status==="active"?"success":O.status==="lead"?"info":"default",children:O.status}),l.jsx("span",{className:"text-xs text-text-secondary",children:Rt(O.created_at)})]})]})]})},O.id))}),b.length===0&&l.jsx(iE,{icon:l.jsx(Wn,{size:32}),title:"No customers found",description:"Try adjusting your search or filters"})]}),e==="Leads"&&l.jsxs(ee,{children:[l.jsxs($a,{children:[l.jsx(Ba,{children:l.jsxs(Nt,{children:[l.jsx(be,{children:"Lead"}),l.jsx(be,{children:"Company"}),l.jsx(be,{children:"Source"}),l.jsx(be,{children:"Status"}),l.jsx(be,{children:"Created"}),l.jsx(be,{align:"right"})]})}),l.jsx(qa,{children:A.map(O=>l.jsxs(Nt,{children:[l.jsx(ge,{children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-8 h-8 rounded-lg bg-primary/10 text-primary flex items-center justify-center text-xs font-semibold",children:O.name.charAt(0)}),l.jsxs("div",{children:[l.jsx("p",{className:"font-medium text-text-primary",children:O.name}),l.jsx("p",{className:"text-xs text-text-secondary",children:O.email})]})]})}),l.jsx(ge,{children:O.company||"—"}),l.jsx(ge,{children:O.source||"—"}),l.jsx(ge,{children:l.jsx(Se,{variant:O.status==="qualified"?"success":O.status==="contacted"?"primary":O.status==="lost"?"danger":"default",children:O.status})}),l.jsx(ge,{children:Rt(O.created_at)}),l.jsx(ge,{align:"right",children:l.jsx("button",{className:"w-8 h-8 flex items-center justify-center rounded-lg hover:bg-bg text-text-secondary",children:l.jsx(Jr,{size:16})})})]},O.id))})]}),A.length===0&&l.jsx(iE,{icon:l.jsx(Sn,{size:32}),title:"No leads found",description:"Try adjusting your search or filters"})]}),e==="Pipeline"&&l.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-5",children:[w.length===0&&l.jsx("div",{className:"col-span-full text-center text-text-secondary py-12",children:"No pipeline stages found"}),w.map(O=>l.jsxs(ee,{hover:!0,children:[l.jsxs("div",{className:"flex items-center justify-between mb-4",children:[l.jsx("h3",{className:"text-sm font-semibold text-text-primary",children:O.name}),l.jsxs(Se,{variant:"default",children:[O.deals," deals"]})]}),l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:O.value>0?new Intl.NumberFormat("sv-SE",{style:"currency",currency:"SEK",maximumFractionDigits:0}).format(O.value):"—"}),l.jsx("div",{className:"mt-4 h-1.5 bg-bg rounded-full overflow-hidden",children:l.jsx("div",{className:"h-full bg-primary rounded-full transition-all",style:{width:`${_>0?O.value/_*100:0}%`}})})]},O.id))]})]})}var cg,sE;function Rn(){if(sE)return cg;sE=1;var e=Array.isArray;return cg=e,cg}var ug,oE;function Dz(){if(oE)return ug;oE=1;var e=typeof Od=="object"&&Od&&Od.Object===Object&&Od;return ug=e,ug}var fg,lE;function ra(){if(lE)return fg;lE=1;var e=Dz(),t=typeof self=="object"&&self&&self.Object===Object&&self,n=e||t||Function("return this")();return fg=n,fg}var dg,cE;function Zu(){if(cE)return dg;cE=1;var e=ra(),t=e.Symbol;return dg=t,dg}var hg,uE;function WF(){if(uE)return hg;uE=1;var e=Zu(),t=Object.prototype,n=t.hasOwnProperty,r=t.toString,i=e?e.toStringTag:void 0;function o(c){var f=n.call(c,i),d=c[i];try{c[i]=void 0;var h=!0}catch{}var p=r.call(c);return h&&(f?c[i]=d:delete c[i]),p}return hg=o,hg}var mg,fE;function ZF(){if(fE)return mg;fE=1;var e=Object.prototype,t=e.toString;function n(r){return t.call(r)}return mg=n,mg}var pg,dE;function Ha(){if(dE)return pg;dE=1;var e=Zu(),t=WF(),n=ZF(),r="[object Null]",i="[object Undefined]",o=e?e.toStringTag:void 0;function c(f){return f==null?f===void 0?i:r:o&&o in Object(f)?t(f):n(f)}return pg=c,pg}var yg,hE;function Fa(){if(hE)return yg;hE=1;function e(t){return t!=null&&typeof t=="object"}return yg=e,yg}var xg,mE;function wl(){if(mE)return xg;mE=1;var e=Ha(),t=Fa(),n="[object Symbol]";function r(i){return typeof i=="symbol"||t(i)&&e(i)==n}return xg=r,xg}var gg,pE;function nS(){if(pE)return gg;pE=1;var e=Rn(),t=wl(),n=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,r=/^\w*$/;function i(o,c){if(e(o))return!1;var f=typeof o;return f=="number"||f=="symbol"||f=="boolean"||o==null||t(o)?!0:r.test(o)||!n.test(o)||c!=null&&o in Object(c)}return gg=i,gg}var vg,yE;function ki(){if(yE)return vg;yE=1;function e(t){var n=typeof t;return t!=null&&(n=="object"||n=="function")}return vg=e,vg}var bg,xE;function rS(){if(xE)return bg;xE=1;var e=Ha(),t=ki(),n="[object AsyncFunction]",r="[object Function]",i="[object GeneratorFunction]",o="[object Proxy]";function c(f){if(!t(f))return!1;var d=e(f);return d==r||d==i||d==n||d==o}return bg=c,bg}var jg,gE;function QF(){if(gE)return jg;gE=1;var e=ra(),t=e["__core-js_shared__"];return jg=t,jg}var wg,vE;function JF(){if(vE)return wg;vE=1;var e=QF(),t=(function(){var r=/[^.]+$/.exec(e&&e.keys&&e.keys.IE_PROTO||"");return r?"Symbol(src)_1."+r:""})();function n(r){return!!t&&t in r}return wg=n,wg}var Sg,bE;function zz(){if(bE)return Sg;bE=1;var e=Function.prototype,t=e.toString;function n(r){if(r!=null){try{return t.call(r)}catch{}try{return r+""}catch{}}return""}return Sg=n,Sg}var Ng,jE;function eG(){if(jE)return Ng;jE=1;var e=rS(),t=JF(),n=ki(),r=zz(),i=/[\\^$.*+?()[\]{}|]/g,o=/^\[object .+?Constructor\]$/,c=Function.prototype,f=Object.prototype,d=c.toString,h=f.hasOwnProperty,p=RegExp("^"+d.call(h).replace(i,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function y(x){if(!n(x)||t(x))return!1;var j=e(x)?p:o;return j.test(r(x))}return Ng=y,Ng}var Ag,wE;function tG(){if(wE)return Ag;wE=1;function e(t,n){return t==null?void 0:t[n]}return Ag=e,Ag}var Og,SE;function Es(){if(SE)return Og;SE=1;var e=eG(),t=tG();function n(r,i){var o=t(r,i);return e(o)?o:void 0}return Og=n,Og}var _g,NE;function Bm(){if(NE)return _g;NE=1;var e=Es(),t=e(Object,"create");return _g=t,_g}var Tg,AE;function nG(){if(AE)return Tg;AE=1;var e=Bm();function t(){this.__data__=e?e(null):{},this.size=0}return Tg=t,Tg}var Eg,OE;function rG(){if(OE)return Eg;OE=1;function e(t){var n=this.has(t)&&delete this.__data__[t];return this.size-=n?1:0,n}return Eg=e,Eg}var Cg,_E;function aG(){if(_E)return Cg;_E=1;var e=Bm(),t="__lodash_hash_undefined__",n=Object.prototype,r=n.hasOwnProperty;function i(o){var c=this.__data__;if(e){var f=c[o];return f===t?void 0:f}return r.call(c,o)?c[o]:void 0}return Cg=i,Cg}var Mg,TE;function iG(){if(TE)return Mg;TE=1;var e=Bm(),t=Object.prototype,n=t.hasOwnProperty;function r(i){var o=this.__data__;return e?o[i]!==void 0:n.call(o,i)}return Mg=r,Mg}var Pg,EE;function sG(){if(EE)return Pg;EE=1;var e=Bm(),t="__lodash_hash_undefined__";function n(r,i){var o=this.__data__;return this.size+=this.has(r)?0:1,o[r]=e&&i===void 0?t:i,this}return Pg=n,Pg}var Rg,CE;function oG(){if(CE)return Rg;CE=1;var e=nG(),t=rG(),n=aG(),r=iG(),i=sG();function o(c){var f=-1,d=c==null?0:c.length;for(this.clear();++f<d;){var h=c[f];this.set(h[0],h[1])}}return o.prototype.clear=e,o.prototype.delete=t,o.prototype.get=n,o.prototype.has=r,o.prototype.set=i,Rg=o,Rg}var kg,ME;function lG(){if(ME)return kg;ME=1;function e(){this.__data__=[],this.size=0}return kg=e,kg}var Dg,PE;function aS(){if(PE)return Dg;PE=1;function e(t,n){return t===n||t!==t&&n!==n}return Dg=e,Dg}var zg,RE;function qm(){if(RE)return zg;RE=1;var e=aS();function t(n,r){for(var i=n.length;i--;)if(e(n[i][0],r))return i;return-1}return zg=t,zg}var Lg,kE;function cG(){if(kE)return Lg;kE=1;var e=qm(),t=Array.prototype,n=t.splice;function r(i){var o=this.__data__,c=e(o,i);if(c<0)return!1;var f=o.length-1;return c==f?o.pop():n.call(o,c,1),--this.size,!0}return Lg=r,Lg}var $g,DE;function uG(){if(DE)return $g;DE=1;var e=qm();function t(n){var r=this.__data__,i=e(r,n);return i<0?void 0:r[i][1]}return $g=t,$g}var Bg,zE;function fG(){if(zE)return Bg;zE=1;var e=qm();function t(n){return e(this.__data__,n)>-1}return Bg=t,Bg}var qg,LE;function dG(){if(LE)return qg;LE=1;var e=qm();function t(n,r){var i=this.__data__,o=e(i,n);return o<0?(++this.size,i.push([n,r])):i[o][1]=r,this}return qg=t,qg}var Ig,$E;function Im(){if($E)return Ig;$E=1;var e=lG(),t=cG(),n=uG(),r=fG(),i=dG();function o(c){var f=-1,d=c==null?0:c.length;for(this.clear();++f<d;){var h=c[f];this.set(h[0],h[1])}}return o.prototype.clear=e,o.prototype.delete=t,o.prototype.get=n,o.prototype.has=r,o.prototype.set=i,Ig=o,Ig}var Ug,BE;function iS(){if(BE)return Ug;BE=1;var e=Es(),t=ra(),n=e(t,"Map");return Ug=n,Ug}var Vg,qE;function hG(){if(qE)return Vg;qE=1;var e=oG(),t=Im(),n=iS();function r(){this.size=0,this.__data__={hash:new e,map:new(n||t),string:new e}}return Vg=r,Vg}var Hg,IE;function mG(){if(IE)return Hg;IE=1;function e(t){var n=typeof t;return n=="string"||n=="number"||n=="symbol"||n=="boolean"?t!=="__proto__":t===null}return Hg=e,Hg}var Fg,UE;function Um(){if(UE)return Fg;UE=1;var e=mG();function t(n,r){var i=n.__data__;return e(r)?i[typeof r=="string"?"string":"hash"]:i.map}return Fg=t,Fg}var Gg,VE;function pG(){if(VE)return Gg;VE=1;var e=Um();function t(n){var r=e(this,n).delete(n);return this.size-=r?1:0,r}return Gg=t,Gg}var Kg,HE;function yG(){if(HE)return Kg;HE=1;var e=Um();function t(n){return e(this,n).get(n)}return Kg=t,Kg}var Yg,FE;function xG(){if(FE)return Yg;FE=1;var e=Um();function t(n){return e(this,n).has(n)}return Yg=t,Yg}var Xg,GE;function gG(){if(GE)return Xg;GE=1;var e=Um();function t(n,r){var i=e(this,n),o=i.size;return i.set(n,r),this.size+=i.size==o?0:1,this}return Xg=t,Xg}var Wg,KE;function sS(){if(KE)return Wg;KE=1;var e=hG(),t=pG(),n=yG(),r=xG(),i=gG();function o(c){var f=-1,d=c==null?0:c.length;for(this.clear();++f<d;){var h=c[f];this.set(h[0],h[1])}}return o.prototype.clear=e,o.prototype.delete=t,o.prototype.get=n,o.prototype.has=r,o.prototype.set=i,Wg=o,Wg}var Zg,YE;function Lz(){if(YE)return Zg;YE=1;var e=sS(),t="Expected a function";function n(r,i){if(typeof r!="function"||i!=null&&typeof i!="function")throw new TypeError(t);var o=function(){var c=arguments,f=i?i.apply(this,c):c[0],d=o.cache;if(d.has(f))return d.get(f);var h=r.apply(this,c);return o.cache=d.set(f,h)||d,h};return o.cache=new(n.Cache||e),o}return n.Cache=e,Zg=n,Zg}var Qg,XE;function vG(){if(XE)return Qg;XE=1;var e=Lz(),t=500;function n(r){var i=e(r,function(c){return o.size===t&&o.clear(),c}),o=i.cache;return i}return Qg=n,Qg}var Jg,WE;function bG(){if(WE)return Jg;WE=1;var e=vG(),t=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,n=/\\(\\)?/g,r=e(function(i){var o=[];return i.charCodeAt(0)===46&&o.push(""),i.replace(t,function(c,f,d,h){o.push(d?h.replace(n,"$1"):f||c)}),o});return Jg=r,Jg}var ev,ZE;function oS(){if(ZE)return ev;ZE=1;function e(t,n){for(var r=-1,i=t==null?0:t.length,o=Array(i);++r<i;)o[r]=n(t[r],r,t);return o}return ev=e,ev}var tv,QE;function jG(){if(QE)return tv;QE=1;var e=Zu(),t=oS(),n=Rn(),r=wl(),i=e?e.prototype:void 0,o=i?i.toString:void 0;function c(f){if(typeof f=="string")return f;if(n(f))return t(f,c)+"";if(r(f))return o?o.call(f):"";var d=f+"";return d=="0"&&1/f==-1/0?"-0":d}return tv=c,tv}var nv,JE;function $z(){if(JE)return nv;JE=1;var e=jG();function t(n){return n==null?"":e(n)}return nv=t,nv}var rv,eC;function Bz(){if(eC)return rv;eC=1;var e=Rn(),t=nS(),n=bG(),r=$z();function i(o,c){return e(o)?o:t(o,c)?[o]:n(r(o))}return rv=i,rv}var av,tC;function Vm(){if(tC)return av;tC=1;var e=wl();function t(n){if(typeof n=="string"||e(n))return n;var r=n+"";return r=="0"&&1/n==-1/0?"-0":r}return av=t,av}var iv,nC;function lS(){if(nC)return iv;nC=1;var e=Bz(),t=Vm();function n(r,i){i=e(i,r);for(var o=0,c=i.length;r!=null&&o<c;)r=r[t(i[o++])];return o&&o==c?r:void 0}return iv=n,iv}var sv,rC;function qz(){if(rC)return sv;rC=1;var e=lS();function t(n,r,i){var o=n==null?void 0:e(n,r);return o===void 0?i:o}return sv=t,sv}var wG=qz();const Zn=at(wG);var ov,aC;function SG(){if(aC)return ov;aC=1;function e(t){return t==null}return ov=e,ov}var NG=SG();const Re=at(NG);var lv,iC;function AG(){if(iC)return lv;iC=1;var e=Ha(),t=Rn(),n=Fa(),r="[object String]";function i(o){return typeof o=="string"||!t(o)&&n(o)&&e(o)==r}return lv=i,lv}var OG=AG();const ws=at(OG);var _G=rS();const Ce=at(_G);var TG=ki();const Sl=at(TG);var cv={exports:{}},Je={};/**
|
||
* @license React
|
||
* react-is.production.min.js
|
||
*
|
||
* Copyright (c) Facebook, Inc. and its affiliates.
|
||
*
|
||
* This source code is licensed under the MIT license found in the
|
||
* LICENSE file in the root directory of this source tree.
|
||
*/var sC;function EG(){if(sC)return Je;sC=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),o=Symbol.for("react.provider"),c=Symbol.for("react.context"),f=Symbol.for("react.server_context"),d=Symbol.for("react.forward_ref"),h=Symbol.for("react.suspense"),p=Symbol.for("react.suspense_list"),y=Symbol.for("react.memo"),x=Symbol.for("react.lazy"),j=Symbol.for("react.offscreen"),w;w=Symbol.for("react.module.reference");function S(b){if(typeof b=="object"&&b!==null){var A=b.$$typeof;switch(A){case e:switch(b=b.type,b){case n:case i:case r:case h:case p:return b;default:switch(b=b&&b.$$typeof,b){case f:case c:case d:case x:case y:case o:return b;default:return A}}case t:return A}}}return Je.ContextConsumer=c,Je.ContextProvider=o,Je.Element=e,Je.ForwardRef=d,Je.Fragment=n,Je.Lazy=x,Je.Memo=y,Je.Portal=t,Je.Profiler=i,Je.StrictMode=r,Je.Suspense=h,Je.SuspenseList=p,Je.isAsyncMode=function(){return!1},Je.isConcurrentMode=function(){return!1},Je.isContextConsumer=function(b){return S(b)===c},Je.isContextProvider=function(b){return S(b)===o},Je.isElement=function(b){return typeof b=="object"&&b!==null&&b.$$typeof===e},Je.isForwardRef=function(b){return S(b)===d},Je.isFragment=function(b){return S(b)===n},Je.isLazy=function(b){return S(b)===x},Je.isMemo=function(b){return S(b)===y},Je.isPortal=function(b){return S(b)===t},Je.isProfiler=function(b){return S(b)===i},Je.isStrictMode=function(b){return S(b)===r},Je.isSuspense=function(b){return S(b)===h},Je.isSuspenseList=function(b){return S(b)===p},Je.isValidElementType=function(b){return typeof b=="string"||typeof b=="function"||b===n||b===i||b===r||b===h||b===p||b===j||typeof b=="object"&&b!==null&&(b.$$typeof===x||b.$$typeof===y||b.$$typeof===o||b.$$typeof===c||b.$$typeof===d||b.$$typeof===w||b.getModuleId!==void 0)},Je.typeOf=S,Je}var oC;function CG(){return oC||(oC=1,cv.exports=EG()),cv.exports}var MG=CG(),uv,lC;function Iz(){if(lC)return uv;lC=1;var e=Ha(),t=Fa(),n="[object Number]";function r(i){return typeof i=="number"||t(i)&&e(i)==n}return uv=r,uv}var fv,cC;function PG(){if(cC)return fv;cC=1;var e=Iz();function t(n){return e(n)&&n!=+n}return fv=t,fv}var RG=PG();const Qu=at(RG);var kG=Iz();const DG=at(kG);var bn=function(t){return t===0?0:t>0?1:-1},hs=function(t){return ws(t)&&t.indexOf("%")===t.length-1},de=function(t){return DG(t)&&!Qu(t)},zG=function(t){return Re(t)},Xt=function(t){return de(t)||ws(t)},LG=0,Nl=function(t){var n=++LG;return"".concat(t||"").concat(n)},jn=function(t,n){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;if(!de(t)&&!ws(t))return r;var o;if(hs(t)){var c=t.indexOf("%");o=n*parseFloat(t.slice(0,c))/100}else o=+t;return Qu(o)&&(o=r),i&&o>n&&(o=n),o},Ni=function(t){if(!t)return null;var n=Object.keys(t);return n&&n.length?t[n[0]]:null},$G=function(t){if(!Array.isArray(t))return!1;for(var n=t.length,r={},i=0;i<n;i++)if(!r[t[i]])r[t[i]]=!0;else return!0;return!1},Kn=function(t,n){return de(t)&&de(n)?function(r){return t+r*(n-t)}:function(){return n}};function _h(e,t,n){return!e||!e.length?null:e.find(function(r){return r&&(typeof t=="function"?t(r):Zn(r,t))===n})}var BG=function(t,n){return de(t)&&de(n)?t-n:ws(t)&&ws(n)?t.localeCompare(n):t instanceof Date&&n instanceof Date?t.getTime()-n.getTime():String(t).localeCompare(String(n))};function zo(e,t){for(var n in e)if({}.hasOwnProperty.call(e,n)&&(!{}.hasOwnProperty.call(t,n)||e[n]!==t[n]))return!1;for(var r in t)if({}.hasOwnProperty.call(t,r)&&!{}.hasOwnProperty.call(e,r))return!1;return!0}function F1(e){"@babel/helpers - typeof";return F1=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},F1(e)}var qG=["viewBox","children"],IG=["aria-activedescendant","aria-atomic","aria-autocomplete","aria-busy","aria-checked","aria-colcount","aria-colindex","aria-colspan","aria-controls","aria-current","aria-describedby","aria-details","aria-disabled","aria-errormessage","aria-expanded","aria-flowto","aria-haspopup","aria-hidden","aria-invalid","aria-keyshortcuts","aria-label","aria-labelledby","aria-level","aria-live","aria-modal","aria-multiline","aria-multiselectable","aria-orientation","aria-owns","aria-placeholder","aria-posinset","aria-pressed","aria-readonly","aria-relevant","aria-required","aria-roledescription","aria-rowcount","aria-rowindex","aria-rowspan","aria-selected","aria-setsize","aria-sort","aria-valuemax","aria-valuemin","aria-valuenow","aria-valuetext","className","color","height","id","lang","max","media","method","min","name","style","target","width","role","tabIndex","accentHeight","accumulate","additive","alignmentBaseline","allowReorder","alphabetic","amplitude","arabicForm","ascent","attributeName","attributeType","autoReverse","azimuth","baseFrequency","baselineShift","baseProfile","bbox","begin","bias","by","calcMode","capHeight","clip","clipPath","clipPathUnits","clipRule","colorInterpolation","colorInterpolationFilters","colorProfile","colorRendering","contentScriptType","contentStyleType","cursor","cx","cy","d","decelerate","descent","diffuseConstant","direction","display","divisor","dominantBaseline","dur","dx","dy","edgeMode","elevation","enableBackground","end","exponent","externalResourcesRequired","fill","fillOpacity","fillRule","filter","filterRes","filterUnits","floodColor","floodOpacity","focusable","fontFamily","fontSize","fontSizeAdjust","fontStretch","fontStyle","fontVariant","fontWeight","format","from","fx","fy","g1","g2","glyphName","glyphOrientationHorizontal","glyphOrientationVertical","glyphRef","gradientTransform","gradientUnits","hanging","horizAdvX","horizOriginX","href","ideographic","imageRendering","in2","in","intercept","k1","k2","k3","k4","k","kernelMatrix","kernelUnitLength","kerning","keyPoints","keySplines","keyTimes","lengthAdjust","letterSpacing","lightingColor","limitingConeAngle","local","markerEnd","markerHeight","markerMid","markerStart","markerUnits","markerWidth","mask","maskContentUnits","maskUnits","mathematical","mode","numOctaves","offset","opacity","operator","order","orient","orientation","origin","overflow","overlinePosition","overlineThickness","paintOrder","panose1","pathLength","patternContentUnits","patternTransform","patternUnits","pointerEvents","pointsAtX","pointsAtY","pointsAtZ","preserveAlpha","preserveAspectRatio","primitiveUnits","r","radius","refX","refY","renderingIntent","repeatCount","repeatDur","requiredExtensions","requiredFeatures","restart","result","rotate","rx","ry","seed","shapeRendering","slope","spacing","specularConstant","specularExponent","speed","spreadMethod","startOffset","stdDeviation","stemh","stemv","stitchTiles","stopColor","stopOpacity","strikethroughPosition","strikethroughThickness","string","stroke","strokeDasharray","strokeDashoffset","strokeLinecap","strokeLinejoin","strokeMiterlimit","strokeOpacity","strokeWidth","surfaceScale","systemLanguage","tableValues","targetX","targetY","textAnchor","textDecoration","textLength","textRendering","to","transform","u1","u2","underlinePosition","underlineThickness","unicode","unicodeBidi","unicodeRange","unitsPerEm","vAlphabetic","values","vectorEffect","version","vertAdvY","vertOriginX","vertOriginY","vHanging","vIdeographic","viewTarget","visibility","vMathematical","widths","wordSpacing","writingMode","x1","x2","x","xChannelSelector","xHeight","xlinkActuate","xlinkArcrole","xlinkHref","xlinkRole","xlinkShow","xlinkTitle","xlinkType","xmlBase","xmlLang","xmlns","xmlnsXlink","xmlSpace","y1","y2","y","yChannelSelector","z","zoomAndPan","ref","key","angle"],uC=["points","pathLength"],dv={svg:qG,polygon:uC,polyline:uC},cS=["dangerouslySetInnerHTML","onCopy","onCopyCapture","onCut","onCutCapture","onPaste","onPasteCapture","onCompositionEnd","onCompositionEndCapture","onCompositionStart","onCompositionStartCapture","onCompositionUpdate","onCompositionUpdateCapture","onFocus","onFocusCapture","onBlur","onBlurCapture","onChange","onChangeCapture","onBeforeInput","onBeforeInputCapture","onInput","onInputCapture","onReset","onResetCapture","onSubmit","onSubmitCapture","onInvalid","onInvalidCapture","onLoad","onLoadCapture","onError","onErrorCapture","onKeyDown","onKeyDownCapture","onKeyPress","onKeyPressCapture","onKeyUp","onKeyUpCapture","onAbort","onAbortCapture","onCanPlay","onCanPlayCapture","onCanPlayThrough","onCanPlayThroughCapture","onDurationChange","onDurationChangeCapture","onEmptied","onEmptiedCapture","onEncrypted","onEncryptedCapture","onEnded","onEndedCapture","onLoadedData","onLoadedDataCapture","onLoadedMetadata","onLoadedMetadataCapture","onLoadStart","onLoadStartCapture","onPause","onPauseCapture","onPlay","onPlayCapture","onPlaying","onPlayingCapture","onProgress","onProgressCapture","onRateChange","onRateChangeCapture","onSeeked","onSeekedCapture","onSeeking","onSeekingCapture","onStalled","onStalledCapture","onSuspend","onSuspendCapture","onTimeUpdate","onTimeUpdateCapture","onVolumeChange","onVolumeChangeCapture","onWaiting","onWaitingCapture","onAuxClick","onAuxClickCapture","onClick","onClickCapture","onContextMenu","onContextMenuCapture","onDoubleClick","onDoubleClickCapture","onDrag","onDragCapture","onDragEnd","onDragEndCapture","onDragEnter","onDragEnterCapture","onDragExit","onDragExitCapture","onDragLeave","onDragLeaveCapture","onDragOver","onDragOverCapture","onDragStart","onDragStartCapture","onDrop","onDropCapture","onMouseDown","onMouseDownCapture","onMouseEnter","onMouseLeave","onMouseMove","onMouseMoveCapture","onMouseOut","onMouseOutCapture","onMouseOver","onMouseOverCapture","onMouseUp","onMouseUpCapture","onSelect","onSelectCapture","onTouchCancel","onTouchCancelCapture","onTouchEnd","onTouchEndCapture","onTouchMove","onTouchMoveCapture","onTouchStart","onTouchStartCapture","onPointerDown","onPointerDownCapture","onPointerMove","onPointerMoveCapture","onPointerUp","onPointerUpCapture","onPointerCancel","onPointerCancelCapture","onPointerEnter","onPointerEnterCapture","onPointerLeave","onPointerLeaveCapture","onPointerOver","onPointerOverCapture","onPointerOut","onPointerOutCapture","onGotPointerCapture","onGotPointerCaptureCapture","onLostPointerCapture","onLostPointerCaptureCapture","onScroll","onScrollCapture","onWheel","onWheelCapture","onAnimationStart","onAnimationStartCapture","onAnimationEnd","onAnimationEndCapture","onAnimationIteration","onAnimationIterationCapture","onTransitionEnd","onTransitionEndCapture"],Th=function(t,n){if(!t||typeof t=="function"||typeof t=="boolean")return null;var r=t;if(P.isValidElement(t)&&(r=t.props),!Sl(r))return null;var i={};return Object.keys(r).forEach(function(o){cS.includes(o)&&(i[o]=n||function(c){return r[o](r,c)})}),i},UG=function(t,n,r){return function(i){return t(n,r,i),null}},Ss=function(t,n,r){if(!Sl(t)||F1(t)!=="object")return null;var i=null;return Object.keys(t).forEach(function(o){var c=t[o];cS.includes(o)&&typeof c=="function"&&(i||(i={}),i[o]=UG(c,n,r))}),i},VG=["children"],HG=["children"];function fC(e,t){if(e==null)return{};var n=FG(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function FG(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function G1(e){"@babel/helpers - typeof";return G1=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},G1(e)}var dC={click:"onClick",mousedown:"onMouseDown",mouseup:"onMouseUp",mouseover:"onMouseOver",mousemove:"onMouseMove",mouseout:"onMouseOut",mouseenter:"onMouseEnter",mouseleave:"onMouseLeave",touchcancel:"onTouchCancel",touchend:"onTouchEnd",touchmove:"onTouchMove",touchstart:"onTouchStart",contextmenu:"onContextMenu",dblclick:"onDoubleClick"},Pa=function(t){return typeof t=="string"?t:t?t.displayName||t.name||"Component":""},hC=null,hv=null,uS=function e(t){if(t===hC&&Array.isArray(hv))return hv;var n=[];return P.Children.forEach(t,function(r){Re(r)||(MG.isFragment(r)?n=n.concat(e(r.props.children)):n.push(r))}),hv=n,hC=t,n};function Qn(e,t){var n=[],r=[];return Array.isArray(t)?r=t.map(function(i){return Pa(i)}):r=[Pa(t)],uS(e).forEach(function(i){var o=Zn(i,"type.displayName")||Zn(i,"type.name");r.indexOf(o)!==-1&&n.push(i)}),n}function Fn(e,t){var n=Qn(e,t);return n&&n[0]}var mC=function(t){if(!t||!t.props)return!1;var n=t.props,r=n.width,i=n.height;return!(!de(r)||r<=0||!de(i)||i<=0)},GG=["a","altGlyph","altGlyphDef","altGlyphItem","animate","animateColor","animateMotion","animateTransform","circle","clipPath","color-profile","cursor","defs","desc","ellipse","feBlend","feColormatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","filter","font","font-face","font-face-format","font-face-name","font-face-url","foreignObject","g","glyph","glyphRef","hkern","image","line","lineGradient","marker","mask","metadata","missing-glyph","mpath","path","pattern","polygon","polyline","radialGradient","rect","script","set","stop","style","svg","switch","symbol","text","textPath","title","tref","tspan","use","view","vkern"],KG=function(t){return t&&t.type&&ws(t.type)&&GG.indexOf(t.type)>=0},YG=function(t){return t&&G1(t)==="object"&&"clipDot"in t},XG=function(t,n,r,i){var o,c=(o=dv==null?void 0:dv[i])!==null&&o!==void 0?o:[];return n.startsWith("data-")||!Ce(t)&&(i&&c.includes(n)||IG.includes(n))||r&&cS.includes(n)},Ne=function(t,n,r){if(!t||typeof t=="function"||typeof t=="boolean")return null;var i=t;if(P.isValidElement(t)&&(i=t.props),!Sl(i))return null;var o={};return Object.keys(i).forEach(function(c){var f;XG((f=i)===null||f===void 0?void 0:f[c],c,n,r)&&(o[c]=i[c])}),o},K1=function e(t,n){if(t===n)return!0;var r=P.Children.count(t);if(r!==P.Children.count(n))return!1;if(r===0)return!0;if(r===1)return pC(Array.isArray(t)?t[0]:t,Array.isArray(n)?n[0]:n);for(var i=0;i<r;i++){var o=t[i],c=n[i];if(Array.isArray(o)||Array.isArray(c)){if(!e(o,c))return!1}else if(!pC(o,c))return!1}return!0},pC=function(t,n){if(Re(t)&&Re(n))return!0;if(!Re(t)&&!Re(n)){var r=t.props||{},i=r.children,o=fC(r,VG),c=n.props||{},f=c.children,d=fC(c,HG);return i&&f?zo(o,d)&&K1(i,f):!i&&!f?zo(o,d):!1}return!1},yC=function(t,n){var r=[],i={};return uS(t).forEach(function(o,c){if(KG(o))r.push(o);else if(o){var f=Pa(o.type),d=n[f]||{},h=d.handler,p=d.once;if(h&&(!p||!i[f])){var y=h(o,f,c);r.push(y),i[f]=!0}}}),r},WG=function(t){var n=t&&t.type;return n&&dC[n]?dC[n]:null},ZG=function(t,n){return uS(n).indexOf(t)},QG=["children","width","height","viewBox","className","style","title","desc"];function Y1(){return Y1=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Y1.apply(this,arguments)}function JG(e,t){if(e==null)return{};var n=eK(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function eK(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function X1(e){var t=e.children,n=e.width,r=e.height,i=e.viewBox,o=e.className,c=e.style,f=e.title,d=e.desc,h=JG(e,QG),p=i||{width:n,height:r,x:0,y:0},y=ze("recharts-surface",o);return U.createElement("svg",Y1({},Ne(h,!0,"svg"),{className:y,width:n,height:r,style:c,viewBox:"".concat(p.x," ").concat(p.y," ").concat(p.width," ").concat(p.height)}),U.createElement("title",null,f),U.createElement("desc",null,d),t)}var tK=["children","className"];function W1(){return W1=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},W1.apply(this,arguments)}function nK(e,t){if(e==null)return{};var n=rK(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function rK(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var Xe=U.forwardRef(function(e,t){var n=e.children,r=e.className,i=nK(e,tK),o=ze("recharts-layer",r);return U.createElement("g",W1({className:o},Ne(i,!0),{ref:t}),n)}),zr=function(t,n){for(var r=arguments.length,i=new Array(r>2?r-2:0),o=2;o<r;o++)i[o-2]=arguments[o]},mv,xC;function aK(){if(xC)return mv;xC=1;function e(t,n,r){var i=-1,o=t.length;n<0&&(n=-n>o?0:o+n),r=r>o?o:r,r<0&&(r+=o),o=n>r?0:r-n>>>0,n>>>=0;for(var c=Array(o);++i<o;)c[i]=t[i+n];return c}return mv=e,mv}var pv,gC;function iK(){if(gC)return pv;gC=1;var e=aK();function t(n,r,i){var o=n.length;return i=i===void 0?o:i,!r&&i>=o?n:e(n,r,i)}return pv=t,pv}var yv,vC;function Uz(){if(vC)return yv;vC=1;var e="\\ud800-\\udfff",t="\\u0300-\\u036f",n="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",i=t+n+r,o="\\ufe0e\\ufe0f",c="\\u200d",f=RegExp("["+c+e+i+o+"]");function d(h){return f.test(h)}return yv=d,yv}var xv,bC;function sK(){if(bC)return xv;bC=1;function e(t){return t.split("")}return xv=e,xv}var gv,jC;function oK(){if(jC)return gv;jC=1;var e="\\ud800-\\udfff",t="\\u0300-\\u036f",n="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",i=t+n+r,o="\\ufe0e\\ufe0f",c="["+e+"]",f="["+i+"]",d="\\ud83c[\\udffb-\\udfff]",h="(?:"+f+"|"+d+")",p="[^"+e+"]",y="(?:\\ud83c[\\udde6-\\uddff]){2}",x="[\\ud800-\\udbff][\\udc00-\\udfff]",j="\\u200d",w=h+"?",S="["+o+"]?",b="(?:"+j+"(?:"+[p,y,x].join("|")+")"+S+w+")*",A=S+w+b,_="(?:"+[p+f+"?",f,y,x,c].join("|")+")",O=RegExp(d+"(?="+d+")|"+_+A,"g");function T(N){return N.match(O)||[]}return gv=T,gv}var vv,wC;function lK(){if(wC)return vv;wC=1;var e=sK(),t=Uz(),n=oK();function r(i){return t(i)?n(i):e(i)}return vv=r,vv}var bv,SC;function cK(){if(SC)return bv;SC=1;var e=iK(),t=Uz(),n=lK(),r=$z();function i(o){return function(c){c=r(c);var f=t(c)?n(c):void 0,d=f?f[0]:c.charAt(0),h=f?e(f,1).join(""):c.slice(1);return d[o]()+h}}return bv=i,bv}var jv,NC;function uK(){if(NC)return jv;NC=1;var e=cK(),t=e("toUpperCase");return jv=t,jv}var fK=uK();const Hm=at(fK);function pt(e){return function(){return e}}const Vz=Math.cos,Eh=Math.sin,Br=Math.sqrt,Ch=Math.PI,Fm=2*Ch,Z1=Math.PI,Q1=2*Z1,os=1e-6,dK=Q1-os;function Hz(e){this._+=e[0];for(let t=1,n=e.length;t<n;++t)this._+=arguments[t]+e[t]}function hK(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return Hz;const n=10**t;return function(r){this._+=r[0];for(let i=1,o=r.length;i<o;++i)this._+=Math.round(arguments[i]*n)/n+r[i]}}class mK{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=t==null?Hz:hK(t)}moveTo(t,n){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(t,n){this._append`L${this._x1=+t},${this._y1=+n}`}quadraticCurveTo(t,n,r,i){this._append`Q${+t},${+n},${this._x1=+r},${this._y1=+i}`}bezierCurveTo(t,n,r,i,o,c){this._append`C${+t},${+n},${+r},${+i},${this._x1=+o},${this._y1=+c}`}arcTo(t,n,r,i,o){if(t=+t,n=+n,r=+r,i=+i,o=+o,o<0)throw new Error(`negative radius: ${o}`);let c=this._x1,f=this._y1,d=r-t,h=i-n,p=c-t,y=f-n,x=p*p+y*y;if(this._x1===null)this._append`M${this._x1=t},${this._y1=n}`;else if(x>os)if(!(Math.abs(y*d-h*p)>os)||!o)this._append`L${this._x1=t},${this._y1=n}`;else{let j=r-c,w=i-f,S=d*d+h*h,b=j*j+w*w,A=Math.sqrt(S),_=Math.sqrt(x),O=o*Math.tan((Z1-Math.acos((S+x-b)/(2*A*_)))/2),T=O/_,N=O/A;Math.abs(T-1)>os&&this._append`L${t+T*p},${n+T*y}`,this._append`A${o},${o},0,0,${+(y*j>p*w)},${this._x1=t+N*d},${this._y1=n+N*h}`}}arc(t,n,r,i,o,c){if(t=+t,n=+n,r=+r,c=!!c,r<0)throw new Error(`negative radius: ${r}`);let f=r*Math.cos(i),d=r*Math.sin(i),h=t+f,p=n+d,y=1^c,x=c?i-o:o-i;this._x1===null?this._append`M${h},${p}`:(Math.abs(this._x1-h)>os||Math.abs(this._y1-p)>os)&&this._append`L${h},${p}`,r&&(x<0&&(x=x%Q1+Q1),x>dK?this._append`A${r},${r},0,1,${y},${t-f},${n-d}A${r},${r},0,1,${y},${this._x1=h},${this._y1=p}`:x>os&&this._append`A${r},${r},0,${+(x>=Z1)},${y},${this._x1=t+r*Math.cos(o)},${this._y1=n+r*Math.sin(o)}`)}rect(t,n,r,i){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}h${r=+r}v${+i}h${-r}Z`}toString(){return this._}}function fS(e){let t=3;return e.digits=function(n){if(!arguments.length)return t;if(n==null)t=null;else{const r=Math.floor(n);if(!(r>=0))throw new RangeError(`invalid digits: ${n}`);t=r}return e},()=>new mK(t)}function dS(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function Fz(e){this._context=e}Fz.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t);break}}};function Gm(e){return new Fz(e)}function Gz(e){return e[0]}function Kz(e){return e[1]}function Yz(e,t){var n=pt(!0),r=null,i=Gm,o=null,c=fS(f);e=typeof e=="function"?e:e===void 0?Gz:pt(e),t=typeof t=="function"?t:t===void 0?Kz:pt(t);function f(d){var h,p=(d=dS(d)).length,y,x=!1,j;for(r==null&&(o=i(j=c())),h=0;h<=p;++h)!(h<p&&n(y=d[h],h,d))===x&&((x=!x)?o.lineStart():o.lineEnd()),x&&o.point(+e(y,h,d),+t(y,h,d));if(j)return o=null,j+""||null}return f.x=function(d){return arguments.length?(e=typeof d=="function"?d:pt(+d),f):e},f.y=function(d){return arguments.length?(t=typeof d=="function"?d:pt(+d),f):t},f.defined=function(d){return arguments.length?(n=typeof d=="function"?d:pt(!!d),f):n},f.curve=function(d){return arguments.length?(i=d,r!=null&&(o=i(r)),f):i},f.context=function(d){return arguments.length?(d==null?r=o=null:o=i(r=d),f):r},f}function Id(e,t,n){var r=null,i=pt(!0),o=null,c=Gm,f=null,d=fS(h);e=typeof e=="function"?e:e===void 0?Gz:pt(+e),t=typeof t=="function"?t:pt(t===void 0?0:+t),n=typeof n=="function"?n:n===void 0?Kz:pt(+n);function h(y){var x,j,w,S=(y=dS(y)).length,b,A=!1,_,O=new Array(S),T=new Array(S);for(o==null&&(f=c(_=d())),x=0;x<=S;++x){if(!(x<S&&i(b=y[x],x,y))===A)if(A=!A)j=x,f.areaStart(),f.lineStart();else{for(f.lineEnd(),f.lineStart(),w=x-1;w>=j;--w)f.point(O[w],T[w]);f.lineEnd(),f.areaEnd()}A&&(O[x]=+e(b,x,y),T[x]=+t(b,x,y),f.point(r?+r(b,x,y):O[x],n?+n(b,x,y):T[x]))}if(_)return f=null,_+""||null}function p(){return Yz().defined(i).curve(c).context(o)}return h.x=function(y){return arguments.length?(e=typeof y=="function"?y:pt(+y),r=null,h):e},h.x0=function(y){return arguments.length?(e=typeof y=="function"?y:pt(+y),h):e},h.x1=function(y){return arguments.length?(r=y==null?null:typeof y=="function"?y:pt(+y),h):r},h.y=function(y){return arguments.length?(t=typeof y=="function"?y:pt(+y),n=null,h):t},h.y0=function(y){return arguments.length?(t=typeof y=="function"?y:pt(+y),h):t},h.y1=function(y){return arguments.length?(n=y==null?null:typeof y=="function"?y:pt(+y),h):n},h.lineX0=h.lineY0=function(){return p().x(e).y(t)},h.lineY1=function(){return p().x(e).y(n)},h.lineX1=function(){return p().x(r).y(t)},h.defined=function(y){return arguments.length?(i=typeof y=="function"?y:pt(!!y),h):i},h.curve=function(y){return arguments.length?(c=y,o!=null&&(f=c(o)),h):c},h.context=function(y){return arguments.length?(y==null?o=f=null:f=c(o=y),h):o},h}class Xz{constructor(t,n){this._context=t,this._x=n}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line}point(t,n){switch(t=+t,n=+n,this._point){case 0:{this._point=1,this._line?this._context.lineTo(t,n):this._context.moveTo(t,n);break}case 1:this._point=2;default:{this._x?this._context.bezierCurveTo(this._x0=(this._x0+t)/2,this._y0,this._x0,n,t,n):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+n)/2,t,this._y0,t,n);break}}this._x0=t,this._y0=n}}function pK(e){return new Xz(e,!0)}function yK(e){return new Xz(e,!1)}const hS={draw(e,t){const n=Br(t/Ch);e.moveTo(n,0),e.arc(0,0,n,0,Fm)}},xK={draw(e,t){const n=Br(t/5)/2;e.moveTo(-3*n,-n),e.lineTo(-n,-n),e.lineTo(-n,-3*n),e.lineTo(n,-3*n),e.lineTo(n,-n),e.lineTo(3*n,-n),e.lineTo(3*n,n),e.lineTo(n,n),e.lineTo(n,3*n),e.lineTo(-n,3*n),e.lineTo(-n,n),e.lineTo(-3*n,n),e.closePath()}},Wz=Br(1/3),gK=Wz*2,vK={draw(e,t){const n=Br(t/gK),r=n*Wz;e.moveTo(0,-n),e.lineTo(r,0),e.lineTo(0,n),e.lineTo(-r,0),e.closePath()}},bK={draw(e,t){const n=Br(t),r=-n/2;e.rect(r,r,n,n)}},jK=.8908130915292852,Zz=Eh(Ch/10)/Eh(7*Ch/10),wK=Eh(Fm/10)*Zz,SK=-Vz(Fm/10)*Zz,NK={draw(e,t){const n=Br(t*jK),r=wK*n,i=SK*n;e.moveTo(0,-n),e.lineTo(r,i);for(let o=1;o<5;++o){const c=Fm*o/5,f=Vz(c),d=Eh(c);e.lineTo(d*n,-f*n),e.lineTo(f*r-d*i,d*r+f*i)}e.closePath()}},wv=Br(3),AK={draw(e,t){const n=-Br(t/(wv*3));e.moveTo(0,n*2),e.lineTo(-wv*n,-n),e.lineTo(wv*n,-n),e.closePath()}},ur=-.5,fr=Br(3)/2,J1=1/Br(12),OK=(J1/2+1)*3,_K={draw(e,t){const n=Br(t/OK),r=n/2,i=n*J1,o=r,c=n*J1+n,f=-o,d=c;e.moveTo(r,i),e.lineTo(o,c),e.lineTo(f,d),e.lineTo(ur*r-fr*i,fr*r+ur*i),e.lineTo(ur*o-fr*c,fr*o+ur*c),e.lineTo(ur*f-fr*d,fr*f+ur*d),e.lineTo(ur*r+fr*i,ur*i-fr*r),e.lineTo(ur*o+fr*c,ur*c-fr*o),e.lineTo(ur*f+fr*d,ur*d-fr*f),e.closePath()}};function TK(e,t){let n=null,r=fS(i);e=typeof e=="function"?e:pt(e||hS),t=typeof t=="function"?t:pt(t===void 0?64:+t);function i(){let o;if(n||(n=o=r()),e.apply(this,arguments).draw(n,+t.apply(this,arguments)),o)return n=null,o+""||null}return i.type=function(o){return arguments.length?(e=typeof o=="function"?o:pt(o),i):e},i.size=function(o){return arguments.length?(t=typeof o=="function"?o:pt(+o),i):t},i.context=function(o){return arguments.length?(n=o??null,i):n},i}function Mh(){}function Ph(e,t,n){e._context.bezierCurveTo((2*e._x0+e._x1)/3,(2*e._y0+e._y1)/3,(e._x0+2*e._x1)/3,(e._y0+2*e._y1)/3,(e._x0+4*e._x1+t)/6,(e._y0+4*e._y1+n)/6)}function Qz(e){this._context=e}Qz.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:Ph(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:Ph(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function EK(e){return new Qz(e)}function Jz(e){this._context=e}Jz.prototype={areaStart:Mh,areaEnd:Mh,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x2,this._y2),this._context.closePath();break}case 2:{this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break}case 3:{this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4);break}}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x2=e,this._y2=t;break;case 1:this._point=2,this._x3=e,this._y3=t;break;case 2:this._point=3,this._x4=e,this._y4=t,this._context.moveTo((this._x0+4*this._x1+e)/6,(this._y0+4*this._y1+t)/6);break;default:Ph(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function CK(e){return new Jz(e)}function e5(e){this._context=e}e5.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var n=(this._x0+4*this._x1+e)/6,r=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(n,r):this._context.moveTo(n,r);break;case 3:this._point=4;default:Ph(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function MK(e){return new e5(e)}function t5(e){this._context=e}t5.prototype={areaStart:Mh,areaEnd:Mh,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(e,t){e=+e,t=+t,this._point?this._context.lineTo(e,t):(this._point=1,this._context.moveTo(e,t))}};function PK(e){return new t5(e)}function AC(e){return e<0?-1:1}function OC(e,t,n){var r=e._x1-e._x0,i=t-e._x1,o=(e._y1-e._y0)/(r||i<0&&-0),c=(n-e._y1)/(i||r<0&&-0),f=(o*i+c*r)/(r+i);return(AC(o)+AC(c))*Math.min(Math.abs(o),Math.abs(c),.5*Math.abs(f))||0}function _C(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function Sv(e,t,n){var r=e._x0,i=e._y0,o=e._x1,c=e._y1,f=(o-r)/3;e._context.bezierCurveTo(r+f,i+f*t,o-f,c-f*n,o,c)}function Rh(e){this._context=e}Rh.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:Sv(this,this._t0,_C(this,this._t0));break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){var n=NaN;if(e=+e,t=+t,!(e===this._x1&&t===this._y1)){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,Sv(this,_C(this,n=OC(this,e,t)),n);break;default:Sv(this,this._t0,n=OC(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=n}}};function n5(e){this._context=new r5(e)}(n5.prototype=Object.create(Rh.prototype)).point=function(e,t){Rh.prototype.point.call(this,t,e)};function r5(e){this._context=e}r5.prototype={moveTo:function(e,t){this._context.moveTo(t,e)},closePath:function(){this._context.closePath()},lineTo:function(e,t){this._context.lineTo(t,e)},bezierCurveTo:function(e,t,n,r,i,o){this._context.bezierCurveTo(t,e,r,n,o,i)}};function RK(e){return new Rh(e)}function kK(e){return new n5(e)}function a5(e){this._context=e}a5.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var e=this._x,t=this._y,n=e.length;if(n)if(this._line?this._context.lineTo(e[0],t[0]):this._context.moveTo(e[0],t[0]),n===2)this._context.lineTo(e[1],t[1]);else for(var r=TC(e),i=TC(t),o=0,c=1;c<n;++o,++c)this._context.bezierCurveTo(r[0][o],i[0][o],r[1][o],i[1][o],e[c],t[c]);(this._line||this._line!==0&&n===1)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(e,t){this._x.push(+e),this._y.push(+t)}};function TC(e){var t,n=e.length-1,r,i=new Array(n),o=new Array(n),c=new Array(n);for(i[0]=0,o[0]=2,c[0]=e[0]+2*e[1],t=1;t<n-1;++t)i[t]=1,o[t]=4,c[t]=4*e[t]+2*e[t+1];for(i[n-1]=2,o[n-1]=7,c[n-1]=8*e[n-1]+e[n],t=1;t<n;++t)r=i[t]/o[t-1],o[t]-=r,c[t]-=r*c[t-1];for(i[n-1]=c[n-1]/o[n-1],t=n-2;t>=0;--t)i[t]=(c[t]-i[t+1])/o[t];for(o[n-1]=(e[n]+i[n-1])/2,t=0;t<n-1;++t)o[t]=2*e[t+1]-i[t+1];return[i,o]}function DK(e){return new a5(e)}function Km(e,t){this._context=e,this._t=t}Km.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0<this._t&&this._t<1&&this._point===2&&this._context.lineTo(this._x,this._y),(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line>=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:{if(this._t<=0)this._context.lineTo(this._x,t),this._context.lineTo(e,t);else{var n=this._x*(1-this._t)+e*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,t)}break}}this._x=e,this._y=t}};function zK(e){return new Km(e,.5)}function LK(e){return new Km(e,0)}function $K(e){return new Km(e,1)}function Uo(e,t){if((c=e.length)>1)for(var n=1,r,i,o=e[t[0]],c,f=o.length;n<c;++n)for(i=o,o=e[t[n]],r=0;r<f;++r)o[r][1]+=o[r][0]=isNaN(i[r][1])?i[r][0]:i[r][1]}function ej(e){for(var t=e.length,n=new Array(t);--t>=0;)n[t]=t;return n}function BK(e,t){return e[t]}function qK(e){const t=[];return t.key=e,t}function IK(){var e=pt([]),t=ej,n=Uo,r=BK;function i(o){var c=Array.from(e.apply(this,arguments),qK),f,d=c.length,h=-1,p;for(const y of o)for(f=0,++h;f<d;++f)(c[f][h]=[0,+r(y,c[f].key,h,o)]).data=y;for(f=0,p=dS(t(c));f<d;++f)c[p[f]].index=f;return n(c,p),c}return i.keys=function(o){return arguments.length?(e=typeof o=="function"?o:pt(Array.from(o)),i):e},i.value=function(o){return arguments.length?(r=typeof o=="function"?o:pt(+o),i):r},i.order=function(o){return arguments.length?(t=o==null?ej:typeof o=="function"?o:pt(Array.from(o)),i):t},i.offset=function(o){return arguments.length?(n=o??Uo,i):n},i}function UK(e,t){if((r=e.length)>0){for(var n,r,i=0,o=e[0].length,c;i<o;++i){for(c=n=0;n<r;++n)c+=e[n][i][1]||0;if(c)for(n=0;n<r;++n)e[n][i][1]/=c}Uo(e,t)}}function VK(e,t){if((i=e.length)>0){for(var n=0,r=e[t[0]],i,o=r.length;n<o;++n){for(var c=0,f=0;c<i;++c)f+=e[c][n][1]||0;r[n][1]+=r[n][0]=-f/2}Uo(e,t)}}function HK(e,t){if(!(!((c=e.length)>0)||!((o=(i=e[t[0]]).length)>0))){for(var n=0,r=1,i,o,c;r<o;++r){for(var f=0,d=0,h=0;f<c;++f){for(var p=e[t[f]],y=p[r][1]||0,x=p[r-1][1]||0,j=(y-x)/2,w=0;w<f;++w){var S=e[t[w]],b=S[r][1]||0,A=S[r-1][1]||0;j+=b-A}d+=y,h+=j*y}i[r-1][1]+=i[r-1][0]=n,d&&(n-=h/d)}i[r-1][1]+=i[r-1][0]=n,Uo(e,t)}}function lu(e){"@babel/helpers - typeof";return lu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},lu(e)}var FK=["type","size","sizeType"];function tj(){return tj=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},tj.apply(this,arguments)}function EC(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function CC(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?EC(Object(n),!0).forEach(function(r){GK(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):EC(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function GK(e,t,n){return t=KK(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function KK(e){var t=YK(e,"string");return lu(t)=="symbol"?t:t+""}function YK(e,t){if(lu(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(lu(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function XK(e,t){if(e==null)return{};var n=WK(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function WK(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var i5={symbolCircle:hS,symbolCross:xK,symbolDiamond:vK,symbolSquare:bK,symbolStar:NK,symbolTriangle:AK,symbolWye:_K},ZK=Math.PI/180,QK=function(t){var n="symbol".concat(Hm(t));return i5[n]||hS},JK=function(t,n,r){if(n==="area")return t;switch(r){case"cross":return 5*t*t/9;case"diamond":return .5*t*t/Math.sqrt(3);case"square":return t*t;case"star":{var i=18*ZK;return 1.25*t*t*(Math.tan(i)-Math.tan(i*2)*Math.pow(Math.tan(i),2))}case"triangle":return Math.sqrt(3)*t*t/4;case"wye":return(21-10*Math.sqrt(3))*t*t/8;default:return Math.PI*t*t/4}},eY=function(t,n){i5["symbol".concat(Hm(t))]=n},mS=function(t){var n=t.type,r=n===void 0?"circle":n,i=t.size,o=i===void 0?64:i,c=t.sizeType,f=c===void 0?"area":c,d=XK(t,FK),h=CC(CC({},d),{},{type:r,size:o,sizeType:f}),p=function(){var b=QK(r),A=TK().type(b).size(JK(o,f,r));return A()},y=h.className,x=h.cx,j=h.cy,w=Ne(h,!0);return x===+x&&j===+j&&o===+o?U.createElement("path",tj({},w,{className:ze("recharts-symbols",y),transform:"translate(".concat(x,", ").concat(j,")"),d:p()})):null};mS.registerSymbol=eY;function Vo(e){"@babel/helpers - typeof";return Vo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Vo(e)}function nj(){return nj=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},nj.apply(this,arguments)}function MC(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function tY(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?MC(Object(n),!0).forEach(function(r){cu(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):MC(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function nY(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function rY(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,o5(r.key),r)}}function aY(e,t,n){return t&&rY(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function iY(e,t,n){return t=kh(t),sY(e,s5()?Reflect.construct(t,n||[],kh(e).constructor):t.apply(e,n))}function sY(e,t){if(t&&(Vo(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return oY(e)}function oY(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function s5(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(s5=function(){return!!e})()}function kh(e){return kh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},kh(e)}function lY(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&rj(e,t)}function rj(e,t){return rj=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},rj(e,t)}function cu(e,t,n){return t=o5(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function o5(e){var t=cY(e,"string");return Vo(t)=="symbol"?t:t+""}function cY(e,t){if(Vo(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Vo(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var dr=32,pS=(function(e){function t(){return nY(this,t),iY(this,t,arguments)}return lY(t,e),aY(t,[{key:"renderIcon",value:function(r){var i=this.props.inactiveColor,o=dr/2,c=dr/6,f=dr/3,d=r.inactive?i:r.color;if(r.type==="plainline")return U.createElement("line",{strokeWidth:4,fill:"none",stroke:d,strokeDasharray:r.payload.strokeDasharray,x1:0,y1:o,x2:dr,y2:o,className:"recharts-legend-icon"});if(r.type==="line")return U.createElement("path",{strokeWidth:4,fill:"none",stroke:d,d:"M0,".concat(o,"h").concat(f,`
|
||
A`).concat(c,",").concat(c,",0,1,1,").concat(2*f,",").concat(o,`
|
||
H`).concat(dr,"M").concat(2*f,",").concat(o,`
|
||
A`).concat(c,",").concat(c,",0,1,1,").concat(f,",").concat(o),className:"recharts-legend-icon"});if(r.type==="rect")return U.createElement("path",{stroke:"none",fill:d,d:"M0,".concat(dr/8,"h").concat(dr,"v").concat(dr*3/4,"h").concat(-dr,"z"),className:"recharts-legend-icon"});if(U.isValidElement(r.legendIcon)){var h=tY({},r);return delete h.legendIcon,U.cloneElement(r.legendIcon,h)}return U.createElement(mS,{fill:d,cx:o,cy:o,size:dr,sizeType:"diameter",type:r.type})}},{key:"renderItems",value:function(){var r=this,i=this.props,o=i.payload,c=i.iconSize,f=i.layout,d=i.formatter,h=i.inactiveColor,p={x:0,y:0,width:dr,height:dr},y={display:f==="horizontal"?"inline-block":"block",marginRight:10},x={display:"inline-block",verticalAlign:"middle",marginRight:4};return o.map(function(j,w){var S=j.formatter||d,b=ze(cu(cu({"recharts-legend-item":!0},"legend-item-".concat(w),!0),"inactive",j.inactive));if(j.type==="none")return null;var A=Ce(j.value)?null:j.value;zr(!Ce(j.value),`The name property is also required when using a function for the dataKey of a chart's cartesian components. Ex: <Bar name="Name of my Data"/>`);var _=j.inactive?h:j.color;return U.createElement("li",nj({className:b,style:y,key:"legend-item-".concat(w)},Ss(r.props,j,w)),U.createElement(X1,{width:c,height:c,viewBox:p,style:x},r.renderIcon(j)),U.createElement("span",{className:"recharts-legend-item-text",style:{color:_}},S?S(A,j,w):A))})}},{key:"render",value:function(){var r=this.props,i=r.payload,o=r.layout,c=r.align;if(!i||!i.length)return null;var f={padding:0,margin:0,textAlign:o==="horizontal"?c:"left"};return U.createElement("ul",{className:"recharts-default-legend",style:f},this.renderItems())}}])})(P.PureComponent);cu(pS,"displayName","Legend");cu(pS,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"middle",inactiveColor:"#ccc"});var Nv,PC;function uY(){if(PC)return Nv;PC=1;var e=Im();function t(){this.__data__=new e,this.size=0}return Nv=t,Nv}var Av,RC;function fY(){if(RC)return Av;RC=1;function e(t){var n=this.__data__,r=n.delete(t);return this.size=n.size,r}return Av=e,Av}var Ov,kC;function dY(){if(kC)return Ov;kC=1;function e(t){return this.__data__.get(t)}return Ov=e,Ov}var _v,DC;function hY(){if(DC)return _v;DC=1;function e(t){return this.__data__.has(t)}return _v=e,_v}var Tv,zC;function mY(){if(zC)return Tv;zC=1;var e=Im(),t=iS(),n=sS(),r=200;function i(o,c){var f=this.__data__;if(f instanceof e){var d=f.__data__;if(!t||d.length<r-1)return d.push([o,c]),this.size=++f.size,this;f=this.__data__=new n(d)}return f.set(o,c),this.size=f.size,this}return Tv=i,Tv}var Ev,LC;function l5(){if(LC)return Ev;LC=1;var e=Im(),t=uY(),n=fY(),r=dY(),i=hY(),o=mY();function c(f){var d=this.__data__=new e(f);this.size=d.size}return c.prototype.clear=t,c.prototype.delete=n,c.prototype.get=r,c.prototype.has=i,c.prototype.set=o,Ev=c,Ev}var Cv,$C;function pY(){if($C)return Cv;$C=1;var e="__lodash_hash_undefined__";function t(n){return this.__data__.set(n,e),this}return Cv=t,Cv}var Mv,BC;function yY(){if(BC)return Mv;BC=1;function e(t){return this.__data__.has(t)}return Mv=e,Mv}var Pv,qC;function c5(){if(qC)return Pv;qC=1;var e=sS(),t=pY(),n=yY();function r(i){var o=-1,c=i==null?0:i.length;for(this.__data__=new e;++o<c;)this.add(i[o])}return r.prototype.add=r.prototype.push=t,r.prototype.has=n,Pv=r,Pv}var Rv,IC;function u5(){if(IC)return Rv;IC=1;function e(t,n){for(var r=-1,i=t==null?0:t.length;++r<i;)if(n(t[r],r,t))return!0;return!1}return Rv=e,Rv}var kv,UC;function f5(){if(UC)return kv;UC=1;function e(t,n){return t.has(n)}return kv=e,kv}var Dv,VC;function d5(){if(VC)return Dv;VC=1;var e=c5(),t=u5(),n=f5(),r=1,i=2;function o(c,f,d,h,p,y){var x=d&r,j=c.length,w=f.length;if(j!=w&&!(x&&w>j))return!1;var S=y.get(c),b=y.get(f);if(S&&b)return S==f&&b==c;var A=-1,_=!0,O=d&i?new e:void 0;for(y.set(c,f),y.set(f,c);++A<j;){var T=c[A],N=f[A];if(h)var E=x?h(N,T,A,f,c,y):h(T,N,A,c,f,y);if(E!==void 0){if(E)continue;_=!1;break}if(O){if(!t(f,function(M,D){if(!n(O,D)&&(T===M||p(T,M,d,h,y)))return O.push(D)})){_=!1;break}}else if(!(T===N||p(T,N,d,h,y))){_=!1;break}}return y.delete(c),y.delete(f),_}return Dv=o,Dv}var zv,HC;function xY(){if(HC)return zv;HC=1;var e=ra(),t=e.Uint8Array;return zv=t,zv}var Lv,FC;function gY(){if(FC)return Lv;FC=1;function e(t){var n=-1,r=Array(t.size);return t.forEach(function(i,o){r[++n]=[o,i]}),r}return Lv=e,Lv}var $v,GC;function yS(){if(GC)return $v;GC=1;function e(t){var n=-1,r=Array(t.size);return t.forEach(function(i){r[++n]=i}),r}return $v=e,$v}var Bv,KC;function vY(){if(KC)return Bv;KC=1;var e=Zu(),t=xY(),n=aS(),r=d5(),i=gY(),o=yS(),c=1,f=2,d="[object Boolean]",h="[object Date]",p="[object Error]",y="[object Map]",x="[object Number]",j="[object RegExp]",w="[object Set]",S="[object String]",b="[object Symbol]",A="[object ArrayBuffer]",_="[object DataView]",O=e?e.prototype:void 0,T=O?O.valueOf:void 0;function N(E,M,D,R,B,q,z){switch(D){case _:if(E.byteLength!=M.byteLength||E.byteOffset!=M.byteOffset)return!1;E=E.buffer,M=M.buffer;case A:return!(E.byteLength!=M.byteLength||!q(new t(E),new t(M)));case d:case h:case x:return n(+E,+M);case p:return E.name==M.name&&E.message==M.message;case j:case S:return E==M+"";case y:var H=i;case w:var X=R&c;if(H||(H=o),E.size!=M.size&&!X)return!1;var Y=z.get(E);if(Y)return Y==M;R|=f,z.set(E,M);var $=r(H(E),H(M),R,B,q,z);return z.delete(E),$;case b:if(T)return T.call(E)==T.call(M)}return!1}return Bv=N,Bv}var qv,YC;function h5(){if(YC)return qv;YC=1;function e(t,n){for(var r=-1,i=n.length,o=t.length;++r<i;)t[o+r]=n[r];return t}return qv=e,qv}var Iv,XC;function bY(){if(XC)return Iv;XC=1;var e=h5(),t=Rn();function n(r,i,o){var c=i(r);return t(r)?c:e(c,o(r))}return Iv=n,Iv}var Uv,WC;function jY(){if(WC)return Uv;WC=1;function e(t,n){for(var r=-1,i=t==null?0:t.length,o=0,c=[];++r<i;){var f=t[r];n(f,r,t)&&(c[o++]=f)}return c}return Uv=e,Uv}var Vv,ZC;function wY(){if(ZC)return Vv;ZC=1;function e(){return[]}return Vv=e,Vv}var Hv,QC;function SY(){if(QC)return Hv;QC=1;var e=jY(),t=wY(),n=Object.prototype,r=n.propertyIsEnumerable,i=Object.getOwnPropertySymbols,o=i?function(c){return c==null?[]:(c=Object(c),e(i(c),function(f){return r.call(c,f)}))}:t;return Hv=o,Hv}var Fv,JC;function NY(){if(JC)return Fv;JC=1;function e(t,n){for(var r=-1,i=Array(t);++r<t;)i[r]=n(r);return i}return Fv=e,Fv}var Gv,eM;function AY(){if(eM)return Gv;eM=1;var e=Ha(),t=Fa(),n="[object Arguments]";function r(i){return t(i)&&e(i)==n}return Gv=r,Gv}var Kv,tM;function xS(){if(tM)return Kv;tM=1;var e=AY(),t=Fa(),n=Object.prototype,r=n.hasOwnProperty,i=n.propertyIsEnumerable,o=e((function(){return arguments})())?e:function(c){return t(c)&&r.call(c,"callee")&&!i.call(c,"callee")};return Kv=o,Kv}var Uc={exports:{}},Yv,nM;function OY(){if(nM)return Yv;nM=1;function e(){return!1}return Yv=e,Yv}Uc.exports;var rM;function m5(){return rM||(rM=1,(function(e,t){var n=ra(),r=OY(),i=t&&!t.nodeType&&t,o=i&&!0&&e&&!e.nodeType&&e,c=o&&o.exports===i,f=c?n.Buffer:void 0,d=f?f.isBuffer:void 0,h=d||r;e.exports=h})(Uc,Uc.exports)),Uc.exports}var Xv,aM;function gS(){if(aM)return Xv;aM=1;var e=9007199254740991,t=/^(?:0|[1-9]\d*)$/;function n(r,i){var o=typeof r;return i=i??e,!!i&&(o=="number"||o!="symbol"&&t.test(r))&&r>-1&&r%1==0&&r<i}return Xv=n,Xv}var Wv,iM;function vS(){if(iM)return Wv;iM=1;var e=9007199254740991;function t(n){return typeof n=="number"&&n>-1&&n%1==0&&n<=e}return Wv=t,Wv}var Zv,sM;function _Y(){if(sM)return Zv;sM=1;var e=Ha(),t=vS(),n=Fa(),r="[object Arguments]",i="[object Array]",o="[object Boolean]",c="[object Date]",f="[object Error]",d="[object Function]",h="[object Map]",p="[object Number]",y="[object Object]",x="[object RegExp]",j="[object Set]",w="[object String]",S="[object WeakMap]",b="[object ArrayBuffer]",A="[object DataView]",_="[object Float32Array]",O="[object Float64Array]",T="[object Int8Array]",N="[object Int16Array]",E="[object Int32Array]",M="[object Uint8Array]",D="[object Uint8ClampedArray]",R="[object Uint16Array]",B="[object Uint32Array]",q={};q[_]=q[O]=q[T]=q[N]=q[E]=q[M]=q[D]=q[R]=q[B]=!0,q[r]=q[i]=q[b]=q[o]=q[A]=q[c]=q[f]=q[d]=q[h]=q[p]=q[y]=q[x]=q[j]=q[w]=q[S]=!1;function z(H){return n(H)&&t(H.length)&&!!q[e(H)]}return Zv=z,Zv}var Qv,oM;function p5(){if(oM)return Qv;oM=1;function e(t){return function(n){return t(n)}}return Qv=e,Qv}var Vc={exports:{}};Vc.exports;var lM;function TY(){return lM||(lM=1,(function(e,t){var n=Dz(),r=t&&!t.nodeType&&t,i=r&&!0&&e&&!e.nodeType&&e,o=i&&i.exports===r,c=o&&n.process,f=(function(){try{var d=i&&i.require&&i.require("util").types;return d||c&&c.binding&&c.binding("util")}catch{}})();e.exports=f})(Vc,Vc.exports)),Vc.exports}var Jv,cM;function y5(){if(cM)return Jv;cM=1;var e=_Y(),t=p5(),n=TY(),r=n&&n.isTypedArray,i=r?t(r):e;return Jv=i,Jv}var eb,uM;function EY(){if(uM)return eb;uM=1;var e=NY(),t=xS(),n=Rn(),r=m5(),i=gS(),o=y5(),c=Object.prototype,f=c.hasOwnProperty;function d(h,p){var y=n(h),x=!y&&t(h),j=!y&&!x&&r(h),w=!y&&!x&&!j&&o(h),S=y||x||j||w,b=S?e(h.length,String):[],A=b.length;for(var _ in h)(p||f.call(h,_))&&!(S&&(_=="length"||j&&(_=="offset"||_=="parent")||w&&(_=="buffer"||_=="byteLength"||_=="byteOffset")||i(_,A)))&&b.push(_);return b}return eb=d,eb}var tb,fM;function CY(){if(fM)return tb;fM=1;var e=Object.prototype;function t(n){var r=n&&n.constructor,i=typeof r=="function"&&r.prototype||e;return n===i}return tb=t,tb}var nb,dM;function x5(){if(dM)return nb;dM=1;function e(t,n){return function(r){return t(n(r))}}return nb=e,nb}var rb,hM;function MY(){if(hM)return rb;hM=1;var e=x5(),t=e(Object.keys,Object);return rb=t,rb}var ab,mM;function PY(){if(mM)return ab;mM=1;var e=CY(),t=MY(),n=Object.prototype,r=n.hasOwnProperty;function i(o){if(!e(o))return t(o);var c=[];for(var f in Object(o))r.call(o,f)&&f!="constructor"&&c.push(f);return c}return ab=i,ab}var ib,pM;function Ju(){if(pM)return ib;pM=1;var e=rS(),t=vS();function n(r){return r!=null&&t(r.length)&&!e(r)}return ib=n,ib}var sb,yM;function Ym(){if(yM)return sb;yM=1;var e=EY(),t=PY(),n=Ju();function r(i){return n(i)?e(i):t(i)}return sb=r,sb}var ob,xM;function RY(){if(xM)return ob;xM=1;var e=bY(),t=SY(),n=Ym();function r(i){return e(i,n,t)}return ob=r,ob}var lb,gM;function kY(){if(gM)return lb;gM=1;var e=RY(),t=1,n=Object.prototype,r=n.hasOwnProperty;function i(o,c,f,d,h,p){var y=f&t,x=e(o),j=x.length,w=e(c),S=w.length;if(j!=S&&!y)return!1;for(var b=j;b--;){var A=x[b];if(!(y?A in c:r.call(c,A)))return!1}var _=p.get(o),O=p.get(c);if(_&&O)return _==c&&O==o;var T=!0;p.set(o,c),p.set(c,o);for(var N=y;++b<j;){A=x[b];var E=o[A],M=c[A];if(d)var D=y?d(M,E,A,c,o,p):d(E,M,A,o,c,p);if(!(D===void 0?E===M||h(E,M,f,d,p):D)){T=!1;break}N||(N=A=="constructor")}if(T&&!N){var R=o.constructor,B=c.constructor;R!=B&&"constructor"in o&&"constructor"in c&&!(typeof R=="function"&&R instanceof R&&typeof B=="function"&&B instanceof B)&&(T=!1)}return p.delete(o),p.delete(c),T}return lb=i,lb}var cb,vM;function DY(){if(vM)return cb;vM=1;var e=Es(),t=ra(),n=e(t,"DataView");return cb=n,cb}var ub,bM;function zY(){if(bM)return ub;bM=1;var e=Es(),t=ra(),n=e(t,"Promise");return ub=n,ub}var fb,jM;function g5(){if(jM)return fb;jM=1;var e=Es(),t=ra(),n=e(t,"Set");return fb=n,fb}var db,wM;function LY(){if(wM)return db;wM=1;var e=Es(),t=ra(),n=e(t,"WeakMap");return db=n,db}var hb,SM;function $Y(){if(SM)return hb;SM=1;var e=DY(),t=iS(),n=zY(),r=g5(),i=LY(),o=Ha(),c=zz(),f="[object Map]",d="[object Object]",h="[object Promise]",p="[object Set]",y="[object WeakMap]",x="[object DataView]",j=c(e),w=c(t),S=c(n),b=c(r),A=c(i),_=o;return(e&&_(new e(new ArrayBuffer(1)))!=x||t&&_(new t)!=f||n&&_(n.resolve())!=h||r&&_(new r)!=p||i&&_(new i)!=y)&&(_=function(O){var T=o(O),N=T==d?O.constructor:void 0,E=N?c(N):"";if(E)switch(E){case j:return x;case w:return f;case S:return h;case b:return p;case A:return y}return T}),hb=_,hb}var mb,NM;function BY(){if(NM)return mb;NM=1;var e=l5(),t=d5(),n=vY(),r=kY(),i=$Y(),o=Rn(),c=m5(),f=y5(),d=1,h="[object Arguments]",p="[object Array]",y="[object Object]",x=Object.prototype,j=x.hasOwnProperty;function w(S,b,A,_,O,T){var N=o(S),E=o(b),M=N?p:i(S),D=E?p:i(b);M=M==h?y:M,D=D==h?y:D;var R=M==y,B=D==y,q=M==D;if(q&&c(S)){if(!c(b))return!1;N=!0,R=!1}if(q&&!R)return T||(T=new e),N||f(S)?t(S,b,A,_,O,T):n(S,b,M,A,_,O,T);if(!(A&d)){var z=R&&j.call(S,"__wrapped__"),H=B&&j.call(b,"__wrapped__");if(z||H){var X=z?S.value():S,Y=H?b.value():b;return T||(T=new e),O(X,Y,A,_,T)}}return q?(T||(T=new e),r(S,b,A,_,O,T)):!1}return mb=w,mb}var pb,AM;function bS(){if(AM)return pb;AM=1;var e=BY(),t=Fa();function n(r,i,o,c,f){return r===i?!0:r==null||i==null||!t(r)&&!t(i)?r!==r&&i!==i:e(r,i,o,c,n,f)}return pb=n,pb}var yb,OM;function qY(){if(OM)return yb;OM=1;var e=l5(),t=bS(),n=1,r=2;function i(o,c,f,d){var h=f.length,p=h,y=!d;if(o==null)return!p;for(o=Object(o);h--;){var x=f[h];if(y&&x[2]?x[1]!==o[x[0]]:!(x[0]in o))return!1}for(;++h<p;){x=f[h];var j=x[0],w=o[j],S=x[1];if(y&&x[2]){if(w===void 0&&!(j in o))return!1}else{var b=new e;if(d)var A=d(w,S,j,o,c,b);if(!(A===void 0?t(S,w,n|r,d,b):A))return!1}}return!0}return yb=i,yb}var xb,_M;function v5(){if(_M)return xb;_M=1;var e=ki();function t(n){return n===n&&!e(n)}return xb=t,xb}var gb,TM;function IY(){if(TM)return gb;TM=1;var e=v5(),t=Ym();function n(r){for(var i=t(r),o=i.length;o--;){var c=i[o],f=r[c];i[o]=[c,f,e(f)]}return i}return gb=n,gb}var vb,EM;function b5(){if(EM)return vb;EM=1;function e(t,n){return function(r){return r==null?!1:r[t]===n&&(n!==void 0||t in Object(r))}}return vb=e,vb}var bb,CM;function UY(){if(CM)return bb;CM=1;var e=qY(),t=IY(),n=b5();function r(i){var o=t(i);return o.length==1&&o[0][2]?n(o[0][0],o[0][1]):function(c){return c===i||e(c,i,o)}}return bb=r,bb}var jb,MM;function VY(){if(MM)return jb;MM=1;function e(t,n){return t!=null&&n in Object(t)}return jb=e,jb}var wb,PM;function HY(){if(PM)return wb;PM=1;var e=Bz(),t=xS(),n=Rn(),r=gS(),i=vS(),o=Vm();function c(f,d,h){d=e(d,f);for(var p=-1,y=d.length,x=!1;++p<y;){var j=o(d[p]);if(!(x=f!=null&&h(f,j)))break;f=f[j]}return x||++p!=y?x:(y=f==null?0:f.length,!!y&&i(y)&&r(j,y)&&(n(f)||t(f)))}return wb=c,wb}var Sb,RM;function FY(){if(RM)return Sb;RM=1;var e=VY(),t=HY();function n(r,i){return r!=null&&t(r,i,e)}return Sb=n,Sb}var Nb,kM;function GY(){if(kM)return Nb;kM=1;var e=bS(),t=qz(),n=FY(),r=nS(),i=v5(),o=b5(),c=Vm(),f=1,d=2;function h(p,y){return r(p)&&i(y)?o(c(p),y):function(x){var j=t(x,p);return j===void 0&&j===y?n(x,p):e(y,j,f|d)}}return Nb=h,Nb}var Ab,DM;function Al(){if(DM)return Ab;DM=1;function e(t){return t}return Ab=e,Ab}var Ob,zM;function KY(){if(zM)return Ob;zM=1;function e(t){return function(n){return n==null?void 0:n[t]}}return Ob=e,Ob}var _b,LM;function YY(){if(LM)return _b;LM=1;var e=lS();function t(n){return function(r){return e(r,n)}}return _b=t,_b}var Tb,$M;function XY(){if($M)return Tb;$M=1;var e=KY(),t=YY(),n=nS(),r=Vm();function i(o){return n(o)?e(r(o)):t(o)}return Tb=i,Tb}var Eb,BM;function aa(){if(BM)return Eb;BM=1;var e=UY(),t=GY(),n=Al(),r=Rn(),i=XY();function o(c){return typeof c=="function"?c:c==null?n:typeof c=="object"?r(c)?t(c[0],c[1]):e(c):i(c)}return Eb=o,Eb}var Cb,qM;function j5(){if(qM)return Cb;qM=1;function e(t,n,r,i){for(var o=t.length,c=r+(i?1:-1);i?c--:++c<o;)if(n(t[c],c,t))return c;return-1}return Cb=e,Cb}var Mb,IM;function WY(){if(IM)return Mb;IM=1;function e(t){return t!==t}return Mb=e,Mb}var Pb,UM;function ZY(){if(UM)return Pb;UM=1;function e(t,n,r){for(var i=r-1,o=t.length;++i<o;)if(t[i]===n)return i;return-1}return Pb=e,Pb}var Rb,VM;function QY(){if(VM)return Rb;VM=1;var e=j5(),t=WY(),n=ZY();function r(i,o,c){return o===o?n(i,o,c):e(i,t,c)}return Rb=r,Rb}var kb,HM;function JY(){if(HM)return kb;HM=1;var e=QY();function t(n,r){var i=n==null?0:n.length;return!!i&&e(n,r,0)>-1}return kb=t,kb}var Db,FM;function eX(){if(FM)return Db;FM=1;function e(t,n,r){for(var i=-1,o=t==null?0:t.length;++i<o;)if(r(n,t[i]))return!0;return!1}return Db=e,Db}var zb,GM;function tX(){if(GM)return zb;GM=1;function e(){}return zb=e,zb}var Lb,KM;function nX(){if(KM)return Lb;KM=1;var e=g5(),t=tX(),n=yS(),r=1/0,i=e&&1/n(new e([,-0]))[1]==r?function(o){return new e(o)}:t;return Lb=i,Lb}var $b,YM;function rX(){if(YM)return $b;YM=1;var e=c5(),t=JY(),n=eX(),r=f5(),i=nX(),o=yS(),c=200;function f(d,h,p){var y=-1,x=t,j=d.length,w=!0,S=[],b=S;if(p)w=!1,x=n;else if(j>=c){var A=h?null:i(d);if(A)return o(A);w=!1,x=r,b=new e}else b=h?[]:S;e:for(;++y<j;){var _=d[y],O=h?h(_):_;if(_=p||_!==0?_:0,w&&O===O){for(var T=b.length;T--;)if(b[T]===O)continue e;h&&b.push(O),S.push(_)}else x(b,O,p)||(b!==S&&b.push(O),S.push(_))}return S}return $b=f,$b}var Bb,XM;function aX(){if(XM)return Bb;XM=1;var e=aa(),t=rX();function n(r,i){return r&&r.length?t(r,e(i,2)):[]}return Bb=n,Bb}var iX=aX();const WM=at(iX);function w5(e,t,n){return t===!0?WM(e,n):Ce(t)?WM(e,t):e}function Ho(e){"@babel/helpers - typeof";return Ho=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ho(e)}var sX=["ref"];function ZM(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Aa(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?ZM(Object(n),!0).forEach(function(r){Xm(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ZM(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function oX(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function QM(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,N5(r.key),r)}}function lX(e,t,n){return t&&QM(e.prototype,t),n&&QM(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function cX(e,t,n){return t=Dh(t),uX(e,S5()?Reflect.construct(t,n||[],Dh(e).constructor):t.apply(e,n))}function uX(e,t){if(t&&(Ho(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return fX(e)}function fX(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function S5(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(S5=function(){return!!e})()}function Dh(e){return Dh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Dh(e)}function dX(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&aj(e,t)}function aj(e,t){return aj=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},aj(e,t)}function Xm(e,t,n){return t=N5(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function N5(e){var t=hX(e,"string");return Ho(t)=="symbol"?t:t+""}function hX(e,t){if(Ho(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Ho(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function mX(e,t){if(e==null)return{};var n=pX(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function pX(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function yX(e){return e.value}function xX(e,t){if(U.isValidElement(e))return U.cloneElement(e,t);if(typeof e=="function")return U.createElement(e,t);t.ref;var n=mX(t,sX);return U.createElement(pS,n)}var JM=1,Lo=(function(e){function t(){var n;oX(this,t);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return n=cX(this,t,[].concat(i)),Xm(n,"lastBoundingBox",{width:-1,height:-1}),n}return dX(t,e),lX(t,[{key:"componentDidMount",value:function(){this.updateBBox()}},{key:"componentDidUpdate",value:function(){this.updateBBox()}},{key:"getBBox",value:function(){if(this.wrapperNode&&this.wrapperNode.getBoundingClientRect){var r=this.wrapperNode.getBoundingClientRect();return r.height=this.wrapperNode.offsetHeight,r.width=this.wrapperNode.offsetWidth,r}return null}},{key:"updateBBox",value:function(){var r=this.props.onBBoxUpdate,i=this.getBBox();i?(Math.abs(i.width-this.lastBoundingBox.width)>JM||Math.abs(i.height-this.lastBoundingBox.height)>JM)&&(this.lastBoundingBox.width=i.width,this.lastBoundingBox.height=i.height,r&&r(i)):(this.lastBoundingBox.width!==-1||this.lastBoundingBox.height!==-1)&&(this.lastBoundingBox.width=-1,this.lastBoundingBox.height=-1,r&&r(null))}},{key:"getBBoxSnapshot",value:function(){return this.lastBoundingBox.width>=0&&this.lastBoundingBox.height>=0?Aa({},this.lastBoundingBox):{width:0,height:0}}},{key:"getDefaultPosition",value:function(r){var i=this.props,o=i.layout,c=i.align,f=i.verticalAlign,d=i.margin,h=i.chartWidth,p=i.chartHeight,y,x;if(!r||(r.left===void 0||r.left===null)&&(r.right===void 0||r.right===null))if(c==="center"&&o==="vertical"){var j=this.getBBoxSnapshot();y={left:((h||0)-j.width)/2}}else y=c==="right"?{right:d&&d.right||0}:{left:d&&d.left||0};if(!r||(r.top===void 0||r.top===null)&&(r.bottom===void 0||r.bottom===null))if(f==="middle"){var w=this.getBBoxSnapshot();x={top:((p||0)-w.height)/2}}else x=f==="bottom"?{bottom:d&&d.bottom||0}:{top:d&&d.top||0};return Aa(Aa({},y),x)}},{key:"render",value:function(){var r=this,i=this.props,o=i.content,c=i.width,f=i.height,d=i.wrapperStyle,h=i.payloadUniqBy,p=i.payload,y=Aa(Aa({position:"absolute",width:c||"auto",height:f||"auto"},this.getDefaultPosition(d)),d);return U.createElement("div",{className:"recharts-legend-wrapper",style:y,ref:function(j){r.wrapperNode=j}},xX(o,Aa(Aa({},this.props),{},{payload:w5(p,h,yX)})))}}],[{key:"getWithHeight",value:function(r,i){var o=Aa(Aa({},this.defaultProps),r.props),c=o.layout;return c==="vertical"&&de(r.props.height)?{height:r.props.height}:c==="horizontal"?{width:r.props.width||i}:null}}])})(P.PureComponent);Xm(Lo,"displayName","Legend");Xm(Lo,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"bottom"});var qb,eP;function gX(){if(eP)return qb;eP=1;var e=Zu(),t=xS(),n=Rn(),r=e?e.isConcatSpreadable:void 0;function i(o){return n(o)||t(o)||!!(r&&o&&o[r])}return qb=i,qb}var Ib,tP;function A5(){if(tP)return Ib;tP=1;var e=h5(),t=gX();function n(r,i,o,c,f){var d=-1,h=r.length;for(o||(o=t),f||(f=[]);++d<h;){var p=r[d];i>0&&o(p)?i>1?n(p,i-1,o,c,f):e(f,p):c||(f[f.length]=p)}return f}return Ib=n,Ib}var Ub,nP;function vX(){if(nP)return Ub;nP=1;function e(t){return function(n,r,i){for(var o=-1,c=Object(n),f=i(n),d=f.length;d--;){var h=f[t?d:++o];if(r(c[h],h,c)===!1)break}return n}}return Ub=e,Ub}var Vb,rP;function bX(){if(rP)return Vb;rP=1;var e=vX(),t=e();return Vb=t,Vb}var Hb,aP;function O5(){if(aP)return Hb;aP=1;var e=bX(),t=Ym();function n(r,i){return r&&e(r,i,t)}return Hb=n,Hb}var Fb,iP;function jX(){if(iP)return Fb;iP=1;var e=Ju();function t(n,r){return function(i,o){if(i==null)return i;if(!e(i))return n(i,o);for(var c=i.length,f=r?c:-1,d=Object(i);(r?f--:++f<c)&&o(d[f],f,d)!==!1;);return i}}return Fb=t,Fb}var Gb,sP;function jS(){if(sP)return Gb;sP=1;var e=O5(),t=jX(),n=t(e);return Gb=n,Gb}var Kb,oP;function _5(){if(oP)return Kb;oP=1;var e=jS(),t=Ju();function n(r,i){var o=-1,c=t(r)?Array(r.length):[];return e(r,function(f,d,h){c[++o]=i(f,d,h)}),c}return Kb=n,Kb}var Yb,lP;function wX(){if(lP)return Yb;lP=1;function e(t,n){var r=t.length;for(t.sort(n);r--;)t[r]=t[r].value;return t}return Yb=e,Yb}var Xb,cP;function SX(){if(cP)return Xb;cP=1;var e=wl();function t(n,r){if(n!==r){var i=n!==void 0,o=n===null,c=n===n,f=e(n),d=r!==void 0,h=r===null,p=r===r,y=e(r);if(!h&&!y&&!f&&n>r||f&&d&&p&&!h&&!y||o&&d&&p||!i&&p||!c)return 1;if(!o&&!f&&!y&&n<r||y&&i&&c&&!o&&!f||h&&i&&c||!d&&c||!p)return-1}return 0}return Xb=t,Xb}var Wb,uP;function NX(){if(uP)return Wb;uP=1;var e=SX();function t(n,r,i){for(var o=-1,c=n.criteria,f=r.criteria,d=c.length,h=i.length;++o<d;){var p=e(c[o],f[o]);if(p){if(o>=h)return p;var y=i[o];return p*(y=="desc"?-1:1)}}return n.index-r.index}return Wb=t,Wb}var Zb,fP;function AX(){if(fP)return Zb;fP=1;var e=oS(),t=lS(),n=aa(),r=_5(),i=wX(),o=p5(),c=NX(),f=Al(),d=Rn();function h(p,y,x){y.length?y=e(y,function(S){return d(S)?function(b){return t(b,S.length===1?S[0]:S)}:S}):y=[f];var j=-1;y=e(y,o(n));var w=r(p,function(S,b,A){var _=e(y,function(O){return O(S)});return{criteria:_,index:++j,value:S}});return i(w,function(S,b){return c(S,b,x)})}return Zb=h,Zb}var Qb,dP;function OX(){if(dP)return Qb;dP=1;function e(t,n,r){switch(r.length){case 0:return t.call(n);case 1:return t.call(n,r[0]);case 2:return t.call(n,r[0],r[1]);case 3:return t.call(n,r[0],r[1],r[2])}return t.apply(n,r)}return Qb=e,Qb}var Jb,hP;function _X(){if(hP)return Jb;hP=1;var e=OX(),t=Math.max;function n(r,i,o){return i=t(i===void 0?r.length-1:i,0),function(){for(var c=arguments,f=-1,d=t(c.length-i,0),h=Array(d);++f<d;)h[f]=c[i+f];f=-1;for(var p=Array(i+1);++f<i;)p[f]=c[f];return p[i]=o(h),e(r,this,p)}}return Jb=n,Jb}var e0,mP;function TX(){if(mP)return e0;mP=1;function e(t){return function(){return t}}return e0=e,e0}var t0,pP;function T5(){if(pP)return t0;pP=1;var e=Es(),t=(function(){try{var n=e(Object,"defineProperty");return n({},"",{}),n}catch{}})();return t0=t,t0}var n0,yP;function EX(){if(yP)return n0;yP=1;var e=TX(),t=T5(),n=Al(),r=t?function(i,o){return t(i,"toString",{configurable:!0,enumerable:!1,value:e(o),writable:!0})}:n;return n0=r,n0}var r0,xP;function CX(){if(xP)return r0;xP=1;var e=800,t=16,n=Date.now;function r(i){var o=0,c=0;return function(){var f=n(),d=t-(f-c);if(c=f,d>0){if(++o>=e)return arguments[0]}else o=0;return i.apply(void 0,arguments)}}return r0=r,r0}var a0,gP;function MX(){if(gP)return a0;gP=1;var e=EX(),t=CX(),n=t(e);return a0=n,a0}var i0,vP;function PX(){if(vP)return i0;vP=1;var e=Al(),t=_X(),n=MX();function r(i,o){return n(t(i,o,e),i+"")}return i0=r,i0}var s0,bP;function Wm(){if(bP)return s0;bP=1;var e=aS(),t=Ju(),n=gS(),r=ki();function i(o,c,f){if(!r(f))return!1;var d=typeof c;return(d=="number"?t(f)&&n(c,f.length):d=="string"&&c in f)?e(f[c],o):!1}return s0=i,s0}var o0,jP;function RX(){if(jP)return o0;jP=1;var e=A5(),t=AX(),n=PX(),r=Wm(),i=n(function(o,c){if(o==null)return[];var f=c.length;return f>1&&r(o,c[0],c[1])?c=[]:f>2&&r(c[0],c[1],c[2])&&(c=[c[0]]),t(o,e(c,1),[])});return o0=i,o0}var kX=RX();const wS=at(kX);function uu(e){"@babel/helpers - typeof";return uu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},uu(e)}function ij(){return ij=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ij.apply(this,arguments)}function DX(e,t){return BX(e)||$X(e,t)||LX(e,t)||zX()}function zX(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function LX(e,t){if(e){if(typeof e=="string")return wP(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return wP(e,t)}}function wP(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function $X(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,c,f=[],d=!0,h=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(d=(r=o.call(n)).done)&&(f.push(r.value),f.length!==t);d=!0);}catch(p){h=!0,i=p}finally{try{if(!d&&n.return!=null&&(c=n.return(),Object(c)!==c))return}finally{if(h)throw i}}return f}}function BX(e){if(Array.isArray(e))return e}function SP(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function l0(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?SP(Object(n),!0).forEach(function(r){qX(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):SP(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function qX(e,t,n){return t=IX(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function IX(e){var t=UX(e,"string");return uu(t)=="symbol"?t:t+""}function UX(e,t){if(uu(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(uu(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function VX(e){return Array.isArray(e)&&Xt(e[0])&&Xt(e[1])?e.join(" ~ "):e}var HX=function(t){var n=t.separator,r=n===void 0?" : ":n,i=t.contentStyle,o=i===void 0?{}:i,c=t.itemStyle,f=c===void 0?{}:c,d=t.labelStyle,h=d===void 0?{}:d,p=t.payload,y=t.formatter,x=t.itemSorter,j=t.wrapperClassName,w=t.labelClassName,S=t.label,b=t.labelFormatter,A=t.accessibilityLayer,_=A===void 0?!1:A,O=function(){if(p&&p.length){var z={padding:0,margin:0},H=(x?wS(p,x):p).map(function(X,Y){if(X.type==="none")return null;var $=l0({display:"block",paddingTop:4,paddingBottom:4,color:X.color||"#000"},f),G=X.formatter||y||VX,Q=X.value,ie=X.name,le=Q,L=ie;if(G&&le!=null&&L!=null){var F=G(Q,ie,X,Y,p);if(Array.isArray(F)){var ae=DX(F,2);le=ae[0],L=ae[1]}else le=F}return U.createElement("li",{className:"recharts-tooltip-item",key:"tooltip-item-".concat(Y),style:$},Xt(L)?U.createElement("span",{className:"recharts-tooltip-item-name"},L):null,Xt(L)?U.createElement("span",{className:"recharts-tooltip-item-separator"},r):null,U.createElement("span",{className:"recharts-tooltip-item-value"},le),U.createElement("span",{className:"recharts-tooltip-item-unit"},X.unit||""))});return U.createElement("ul",{className:"recharts-tooltip-item-list",style:z},H)}return null},T=l0({margin:0,padding:10,backgroundColor:"#fff",border:"1px solid #ccc",whiteSpace:"nowrap"},o),N=l0({margin:0},h),E=!Re(S),M=E?S:"",D=ze("recharts-default-tooltip",j),R=ze("recharts-tooltip-label",w);E&&b&&p!==void 0&&p!==null&&(M=b(S,p));var B=_?{role:"status","aria-live":"assertive"}:{};return U.createElement("div",ij({className:D,style:T},B),U.createElement("p",{className:R,style:N},U.isValidElement(M)?M:"".concat(M)),O())};function fu(e){"@babel/helpers - typeof";return fu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},fu(e)}function Ud(e,t,n){return t=FX(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function FX(e){var t=GX(e,"string");return fu(t)=="symbol"?t:t+""}function GX(e,t){if(fu(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(fu(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Cc="recharts-tooltip-wrapper",KX={visibility:"hidden"};function YX(e){var t=e.coordinate,n=e.translateX,r=e.translateY;return ze(Cc,Ud(Ud(Ud(Ud({},"".concat(Cc,"-right"),de(n)&&t&&de(t.x)&&n>=t.x),"".concat(Cc,"-left"),de(n)&&t&&de(t.x)&&n<t.x),"".concat(Cc,"-bottom"),de(r)&&t&&de(t.y)&&r>=t.y),"".concat(Cc,"-top"),de(r)&&t&&de(t.y)&&r<t.y))}function NP(e){var t=e.allowEscapeViewBox,n=e.coordinate,r=e.key,i=e.offsetTopLeft,o=e.position,c=e.reverseDirection,f=e.tooltipDimension,d=e.viewBox,h=e.viewBoxDimension;if(o&&de(o[r]))return o[r];var p=n[r]-f-i,y=n[r]+i;if(t[r])return c[r]?p:y;if(c[r]){var x=p,j=d[r];return x<j?Math.max(y,d[r]):Math.max(p,d[r])}var w=y+f,S=d[r]+h;return w>S?Math.max(p,d[r]):Math.max(y,d[r])}function XX(e){var t=e.translateX,n=e.translateY,r=e.useTranslate3d;return{transform:r?"translate3d(".concat(t,"px, ").concat(n,"px, 0)"):"translate(".concat(t,"px, ").concat(n,"px)")}}function WX(e){var t=e.allowEscapeViewBox,n=e.coordinate,r=e.offsetTopLeft,i=e.position,o=e.reverseDirection,c=e.tooltipBox,f=e.useTranslate3d,d=e.viewBox,h,p,y;return c.height>0&&c.width>0&&n?(p=NP({allowEscapeViewBox:t,coordinate:n,key:"x",offsetTopLeft:r,position:i,reverseDirection:o,tooltipDimension:c.width,viewBox:d,viewBoxDimension:d.width}),y=NP({allowEscapeViewBox:t,coordinate:n,key:"y",offsetTopLeft:r,position:i,reverseDirection:o,tooltipDimension:c.height,viewBox:d,viewBoxDimension:d.height}),h=XX({translateX:p,translateY:y,useTranslate3d:f})):h=KX,{cssProperties:h,cssClasses:YX({translateX:p,translateY:y,coordinate:n})}}function Fo(e){"@babel/helpers - typeof";return Fo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Fo(e)}function AP(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function OP(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?AP(Object(n),!0).forEach(function(r){oj(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):AP(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function ZX(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function QX(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,C5(r.key),r)}}function JX(e,t,n){return t&&QX(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function eW(e,t,n){return t=zh(t),tW(e,E5()?Reflect.construct(t,n||[],zh(e).constructor):t.apply(e,n))}function tW(e,t){if(t&&(Fo(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return nW(e)}function nW(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function E5(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(E5=function(){return!!e})()}function zh(e){return zh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},zh(e)}function rW(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&sj(e,t)}function sj(e,t){return sj=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},sj(e,t)}function oj(e,t,n){return t=C5(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function C5(e){var t=aW(e,"string");return Fo(t)=="symbol"?t:t+""}function aW(e,t){if(Fo(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Fo(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var _P=1,iW=(function(e){function t(){var n;ZX(this,t);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return n=eW(this,t,[].concat(i)),oj(n,"state",{dismissed:!1,dismissedAtCoordinate:{x:0,y:0},lastBoundingBox:{width:-1,height:-1}}),oj(n,"handleKeyDown",function(c){if(c.key==="Escape"){var f,d,h,p;n.setState({dismissed:!0,dismissedAtCoordinate:{x:(f=(d=n.props.coordinate)===null||d===void 0?void 0:d.x)!==null&&f!==void 0?f:0,y:(h=(p=n.props.coordinate)===null||p===void 0?void 0:p.y)!==null&&h!==void 0?h:0}})}}),n}return rW(t,e),JX(t,[{key:"updateBBox",value:function(){if(this.wrapperNode&&this.wrapperNode.getBoundingClientRect){var r=this.wrapperNode.getBoundingClientRect();(Math.abs(r.width-this.state.lastBoundingBox.width)>_P||Math.abs(r.height-this.state.lastBoundingBox.height)>_P)&&this.setState({lastBoundingBox:{width:r.width,height:r.height}})}else(this.state.lastBoundingBox.width!==-1||this.state.lastBoundingBox.height!==-1)&&this.setState({lastBoundingBox:{width:-1,height:-1}})}},{key:"componentDidMount",value:function(){document.addEventListener("keydown",this.handleKeyDown),this.updateBBox()}},{key:"componentWillUnmount",value:function(){document.removeEventListener("keydown",this.handleKeyDown)}},{key:"componentDidUpdate",value:function(){var r,i;this.props.active&&this.updateBBox(),this.state.dismissed&&(((r=this.props.coordinate)===null||r===void 0?void 0:r.x)!==this.state.dismissedAtCoordinate.x||((i=this.props.coordinate)===null||i===void 0?void 0:i.y)!==this.state.dismissedAtCoordinate.y)&&(this.state.dismissed=!1)}},{key:"render",value:function(){var r=this,i=this.props,o=i.active,c=i.allowEscapeViewBox,f=i.animationDuration,d=i.animationEasing,h=i.children,p=i.coordinate,y=i.hasPayload,x=i.isAnimationActive,j=i.offset,w=i.position,S=i.reverseDirection,b=i.useTranslate3d,A=i.viewBox,_=i.wrapperStyle,O=WX({allowEscapeViewBox:c,coordinate:p,offsetTopLeft:j,position:w,reverseDirection:S,tooltipBox:this.state.lastBoundingBox,useTranslate3d:b,viewBox:A}),T=O.cssClasses,N=O.cssProperties,E=OP(OP({transition:x&&o?"transform ".concat(f,"ms ").concat(d):void 0},N),{},{pointerEvents:"none",visibility:!this.state.dismissed&&o&&y?"visible":"hidden",position:"absolute",top:0,left:0},_);return U.createElement("div",{tabIndex:-1,className:T,style:E,ref:function(D){r.wrapperNode=D}},h)}}])})(P.PureComponent),sW=function(){return!(typeof window<"u"&&window.document&&window.document.createElement&&window.setTimeout)},Cs={isSsr:sW()};function Go(e){"@babel/helpers - typeof";return Go=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Go(e)}function TP(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function EP(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?TP(Object(n),!0).forEach(function(r){SS(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):TP(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function oW(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function lW(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,P5(r.key),r)}}function cW(e,t,n){return t&&lW(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function uW(e,t,n){return t=Lh(t),fW(e,M5()?Reflect.construct(t,n||[],Lh(e).constructor):t.apply(e,n))}function fW(e,t){if(t&&(Go(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return dW(e)}function dW(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function M5(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(M5=function(){return!!e})()}function Lh(e){return Lh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Lh(e)}function hW(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&lj(e,t)}function lj(e,t){return lj=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},lj(e,t)}function SS(e,t,n){return t=P5(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function P5(e){var t=mW(e,"string");return Go(t)=="symbol"?t:t+""}function mW(e,t){if(Go(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Go(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function pW(e){return e.dataKey}function yW(e,t){return U.isValidElement(e)?U.cloneElement(e,t):typeof e=="function"?U.createElement(e,t):U.createElement(HX,t)}var hr=(function(e){function t(){return oW(this,t),uW(this,t,arguments)}return hW(t,e),cW(t,[{key:"render",value:function(){var r=this,i=this.props,o=i.active,c=i.allowEscapeViewBox,f=i.animationDuration,d=i.animationEasing,h=i.content,p=i.coordinate,y=i.filterNull,x=i.isAnimationActive,j=i.offset,w=i.payload,S=i.payloadUniqBy,b=i.position,A=i.reverseDirection,_=i.useTranslate3d,O=i.viewBox,T=i.wrapperStyle,N=w??[];y&&N.length&&(N=w5(w.filter(function(M){return M.value!=null&&(M.hide!==!0||r.props.includeHidden)}),S,pW));var E=N.length>0;return U.createElement(iW,{allowEscapeViewBox:c,animationDuration:f,animationEasing:d,isAnimationActive:x,active:o,coordinate:p,hasPayload:E,offset:j,position:b,reverseDirection:A,useTranslate3d:_,viewBox:O,wrapperStyle:T},yW(h,EP(EP({},this.props),{},{payload:N})))}}])})(P.PureComponent);SS(hr,"displayName","Tooltip");SS(hr,"defaultProps",{accessibilityLayer:!1,allowEscapeViewBox:{x:!1,y:!1},animationDuration:400,animationEasing:"ease",contentStyle:{},coordinate:{x:0,y:0},cursor:!0,cursorStyle:{},filterNull:!0,isAnimationActive:!Cs.isSsr,itemStyle:{},labelStyle:{},offset:10,reverseDirection:{x:!1,y:!1},separator:" : ",trigger:"hover",useTranslate3d:!1,viewBox:{x:0,y:0,height:0,width:0},wrapperStyle:{}});var c0,CP;function xW(){if(CP)return c0;CP=1;var e=ra(),t=function(){return e.Date.now()};return c0=t,c0}var u0,MP;function gW(){if(MP)return u0;MP=1;var e=/\s/;function t(n){for(var r=n.length;r--&&e.test(n.charAt(r)););return r}return u0=t,u0}var f0,PP;function vW(){if(PP)return f0;PP=1;var e=gW(),t=/^\s+/;function n(r){return r&&r.slice(0,e(r)+1).replace(t,"")}return f0=n,f0}var d0,RP;function R5(){if(RP)return d0;RP=1;var e=vW(),t=ki(),n=wl(),r=NaN,i=/^[-+]0x[0-9a-f]+$/i,o=/^0b[01]+$/i,c=/^0o[0-7]+$/i,f=parseInt;function d(h){if(typeof h=="number")return h;if(n(h))return r;if(t(h)){var p=typeof h.valueOf=="function"?h.valueOf():h;h=t(p)?p+"":p}if(typeof h!="string")return h===0?h:+h;h=e(h);var y=o.test(h);return y||c.test(h)?f(h.slice(2),y?2:8):i.test(h)?r:+h}return d0=d,d0}var h0,kP;function bW(){if(kP)return h0;kP=1;var e=ki(),t=xW(),n=R5(),r="Expected a function",i=Math.max,o=Math.min;function c(f,d,h){var p,y,x,j,w,S,b=0,A=!1,_=!1,O=!0;if(typeof f!="function")throw new TypeError(r);d=n(d)||0,e(h)&&(A=!!h.leading,_="maxWait"in h,x=_?i(n(h.maxWait)||0,d):x,O="trailing"in h?!!h.trailing:O);function T(H){var X=p,Y=y;return p=y=void 0,b=H,j=f.apply(Y,X),j}function N(H){return b=H,w=setTimeout(D,d),A?T(H):j}function E(H){var X=H-S,Y=H-b,$=d-X;return _?o($,x-Y):$}function M(H){var X=H-S,Y=H-b;return S===void 0||X>=d||X<0||_&&Y>=x}function D(){var H=t();if(M(H))return R(H);w=setTimeout(D,E(H))}function R(H){return w=void 0,O&&p?T(H):(p=y=void 0,j)}function B(){w!==void 0&&clearTimeout(w),b=0,p=S=y=w=void 0}function q(){return w===void 0?j:R(t())}function z(){var H=t(),X=M(H);if(p=arguments,y=this,S=H,X){if(w===void 0)return N(S);if(_)return clearTimeout(w),w=setTimeout(D,d),T(S)}return w===void 0&&(w=setTimeout(D,d)),j}return z.cancel=B,z.flush=q,z}return h0=c,h0}var m0,DP;function jW(){if(DP)return m0;DP=1;var e=bW(),t=ki(),n="Expected a function";function r(i,o,c){var f=!0,d=!0;if(typeof i!="function")throw new TypeError(n);return t(c)&&(f="leading"in c?!!c.leading:f,d="trailing"in c?!!c.trailing:d),e(i,o,{leading:f,maxWait:o,trailing:d})}return m0=r,m0}var wW=jW();const k5=at(wW);function du(e){"@babel/helpers - typeof";return du=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},du(e)}function zP(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Vd(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?zP(Object(n),!0).forEach(function(r){SW(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):zP(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function SW(e,t,n){return t=NW(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function NW(e){var t=AW(e,"string");return du(t)=="symbol"?t:t+""}function AW(e,t){if(du(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(du(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function OW(e,t){return CW(e)||EW(e,t)||TW(e,t)||_W()}function _W(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function TW(e,t){if(e){if(typeof e=="string")return LP(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return LP(e,t)}}function LP(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function EW(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,c,f=[],d=!0,h=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(d=(r=o.call(n)).done)&&(f.push(r.value),f.length!==t);d=!0);}catch(p){h=!0,i=p}finally{try{if(!d&&n.return!=null&&(c=n.return(),Object(c)!==c))return}finally{if(h)throw i}}return f}}function CW(e){if(Array.isArray(e))return e}var cj=P.forwardRef(function(e,t){var n=e.aspect,r=e.initialDimension,i=r===void 0?{width:-1,height:-1}:r,o=e.width,c=o===void 0?"100%":o,f=e.height,d=f===void 0?"100%":f,h=e.minWidth,p=h===void 0?0:h,y=e.minHeight,x=e.maxHeight,j=e.children,w=e.debounce,S=w===void 0?0:w,b=e.id,A=e.className,_=e.onResize,O=e.style,T=O===void 0?{}:O,N=P.useRef(null),E=P.useRef();E.current=_,P.useImperativeHandle(t,function(){return Object.defineProperty(N.current,"current",{get:function(){return console.warn("The usage of ref.current.current is deprecated and will no longer be supported."),N.current},configurable:!0})});var M=P.useState({containerWidth:i.width,containerHeight:i.height}),D=OW(M,2),R=D[0],B=D[1],q=P.useCallback(function(H,X){B(function(Y){var $=Math.round(H),G=Math.round(X);return Y.containerWidth===$&&Y.containerHeight===G?Y:{containerWidth:$,containerHeight:G}})},[]);P.useEffect(function(){var H=function(ie){var le,L=ie[0].contentRect,F=L.width,ae=L.height;q(F,ae),(le=E.current)===null||le===void 0||le.call(E,F,ae)};S>0&&(H=k5(H,S,{trailing:!0,leading:!1}));var X=new ResizeObserver(H),Y=N.current.getBoundingClientRect(),$=Y.width,G=Y.height;return q($,G),X.observe(N.current),function(){X.disconnect()}},[q,S]);var z=P.useMemo(function(){var H=R.containerWidth,X=R.containerHeight;if(H<0||X<0)return null;zr(hs(c)||hs(d),`The width(%s) and height(%s) are both fixed numbers,
|
||
maybe you don't need to use a ResponsiveContainer.`,c,d),zr(!n||n>0,"The aspect(%s) must be greater than zero.",n);var Y=hs(c)?H:c,$=hs(d)?X:d;n&&n>0&&(Y?$=Y/n:$&&(Y=$*n),x&&$>x&&($=x)),zr(Y>0||$>0,`The width(%s) and height(%s) of chart should be greater than 0,
|
||
please check the style of container, or the props width(%s) and height(%s),
|
||
or add a minWidth(%s) or minHeight(%s) or use aspect(%s) to control the
|
||
height and width.`,Y,$,c,d,p,y,n);var G=!Array.isArray(j)&&Pa(j.type).endsWith("Chart");return U.Children.map(j,function(Q){return U.isValidElement(Q)?P.cloneElement(Q,Vd({width:Y,height:$},G?{style:Vd({height:"100%",width:"100%",maxHeight:$,maxWidth:Y},Q.props.style)}:{})):Q})},[n,j,d,x,y,p,R,c]);return U.createElement("div",{id:b?"".concat(b):void 0,className:ze("recharts-responsive-container",A),style:Vd(Vd({},T),{},{width:c,height:d,minWidth:p,minHeight:y,maxHeight:x}),ref:N},z)}),Zm=function(t){return null};Zm.displayName="Cell";function hu(e){"@babel/helpers - typeof";return hu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},hu(e)}function $P(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function uj(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?$P(Object(n),!0).forEach(function(r){MW(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):$P(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function MW(e,t,n){return t=PW(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function PW(e){var t=RW(e,"string");return hu(t)=="symbol"?t:t+""}function RW(e,t){if(hu(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(hu(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var bo={widthCache:{},cacheCount:0},kW=2e3,DW={position:"absolute",top:"-20000px",left:0,padding:0,margin:0,border:"none",whiteSpace:"pre"},BP="recharts_measurement_span";function zW(e){var t=uj({},e);return Object.keys(t).forEach(function(n){t[n]||delete t[n]}),t}var Xc=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(t==null||Cs.isSsr)return{width:0,height:0};var r=zW(n),i=JSON.stringify({text:t,copyStyle:r});if(bo.widthCache[i])return bo.widthCache[i];try{var o=document.getElementById(BP);o||(o=document.createElement("span"),o.setAttribute("id",BP),o.setAttribute("aria-hidden","true"),document.body.appendChild(o));var c=uj(uj({},DW),r);Object.assign(o.style,c),o.textContent="".concat(t);var f=o.getBoundingClientRect(),d={width:f.width,height:f.height};return bo.widthCache[i]=d,++bo.cacheCount>kW&&(bo.cacheCount=0,bo.widthCache={}),d}catch{return{width:0,height:0}}},LW=function(t){return{top:t.top+window.scrollY-document.documentElement.clientTop,left:t.left+window.scrollX-document.documentElement.clientLeft}};function mu(e){"@babel/helpers - typeof";return mu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},mu(e)}function $h(e,t){return IW(e)||qW(e,t)||BW(e,t)||$W()}function $W(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function BW(e,t){if(e){if(typeof e=="string")return qP(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return qP(e,t)}}function qP(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function qW(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,c,f=[],d=!0,h=!1;try{if(o=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;d=!1}else for(;!(d=(r=o.call(n)).done)&&(f.push(r.value),f.length!==t);d=!0);}catch(p){h=!0,i=p}finally{try{if(!d&&n.return!=null&&(c=n.return(),Object(c)!==c))return}finally{if(h)throw i}}return f}}function IW(e){if(Array.isArray(e))return e}function UW(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function IP(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,HW(r.key),r)}}function VW(e,t,n){return t&&IP(e.prototype,t),n&&IP(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function HW(e){var t=FW(e,"string");return mu(t)=="symbol"?t:t+""}function FW(e,t){if(mu(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(mu(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var UP=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([*/])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,VP=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([+-])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,GW=/^px|cm|vh|vw|em|rem|%|mm|in|pt|pc|ex|ch|vmin|vmax|Q$/,KW=/(-?\d+(?:\.\d+)?)([a-zA-Z%]+)?/,D5={cm:96/2.54,mm:96/25.4,pt:96/72,pc:96/6,in:96,Q:96/(2.54*40),px:1},YW=Object.keys(D5),Eo="NaN";function XW(e,t){return e*D5[t]}var Hd=(function(){function e(t,n){UW(this,e),this.num=t,this.unit=n,this.num=t,this.unit=n,Number.isNaN(t)&&(this.unit=""),n!==""&&!GW.test(n)&&(this.num=NaN,this.unit=""),YW.includes(n)&&(this.num=XW(t,n),this.unit="px")}return VW(e,[{key:"add",value:function(n){return this.unit!==n.unit?new e(NaN,""):new e(this.num+n.num,this.unit)}},{key:"subtract",value:function(n){return this.unit!==n.unit?new e(NaN,""):new e(this.num-n.num,this.unit)}},{key:"multiply",value:function(n){return this.unit!==""&&n.unit!==""&&this.unit!==n.unit?new e(NaN,""):new e(this.num*n.num,this.unit||n.unit)}},{key:"divide",value:function(n){return this.unit!==""&&n.unit!==""&&this.unit!==n.unit?new e(NaN,""):new e(this.num/n.num,this.unit||n.unit)}},{key:"toString",value:function(){return"".concat(this.num).concat(this.unit)}},{key:"isNaN",value:function(){return Number.isNaN(this.num)}}],[{key:"parse",value:function(n){var r,i=(r=KW.exec(n))!==null&&r!==void 0?r:[],o=$h(i,3),c=o[1],f=o[2];return new e(parseFloat(c),f??"")}}])})();function z5(e){if(e.includes(Eo))return Eo;for(var t=e;t.includes("*")||t.includes("/");){var n,r=(n=UP.exec(t))!==null&&n!==void 0?n:[],i=$h(r,4),o=i[1],c=i[2],f=i[3],d=Hd.parse(o??""),h=Hd.parse(f??""),p=c==="*"?d.multiply(h):d.divide(h);if(p.isNaN())return Eo;t=t.replace(UP,p.toString())}for(;t.includes("+")||/.-\d+(?:\.\d+)?/.test(t);){var y,x=(y=VP.exec(t))!==null&&y!==void 0?y:[],j=$h(x,4),w=j[1],S=j[2],b=j[3],A=Hd.parse(w??""),_=Hd.parse(b??""),O=S==="+"?A.add(_):A.subtract(_);if(O.isNaN())return Eo;t=t.replace(VP,O.toString())}return t}var HP=/\(([^()]*)\)/;function WW(e){for(var t=e;t.includes("(");){var n=HP.exec(t),r=$h(n,2),i=r[1];t=t.replace(HP,z5(i))}return t}function ZW(e){var t=e.replace(/\s+/g,"");return t=WW(t),t=z5(t),t}function QW(e){try{return ZW(e)}catch{return Eo}}function p0(e){var t=QW(e.slice(5,-1));return t===Eo?"":t}var JW=["x","y","lineHeight","capHeight","scaleToFit","textAnchor","verticalAnchor","fill"],eZ=["dx","dy","angle","className","breakAll"];function fj(){return fj=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},fj.apply(this,arguments)}function FP(e,t){if(e==null)return{};var n=tZ(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function tZ(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function GP(e,t){return iZ(e)||aZ(e,t)||rZ(e,t)||nZ()}function nZ(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function rZ(e,t){if(e){if(typeof e=="string")return KP(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return KP(e,t)}}function KP(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function aZ(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,c,f=[],d=!0,h=!1;try{if(o=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;d=!1}else for(;!(d=(r=o.call(n)).done)&&(f.push(r.value),f.length!==t);d=!0);}catch(p){h=!0,i=p}finally{try{if(!d&&n.return!=null&&(c=n.return(),Object(c)!==c))return}finally{if(h)throw i}}return f}}function iZ(e){if(Array.isArray(e))return e}var L5=/[ \f\n\r\t\v\u2028\u2029]+/,$5=function(t){var n=t.children,r=t.breakAll,i=t.style;try{var o=[];Re(n)||(r?o=n.toString().split(""):o=n.toString().split(L5));var c=o.map(function(d){return{word:d,width:Xc(d,i).width}}),f=r?0:Xc(" ",i).width;return{wordsWithComputedWidth:c,spaceWidth:f}}catch{return null}},sZ=function(t,n,r,i,o){var c=t.maxLines,f=t.children,d=t.style,h=t.breakAll,p=de(c),y=f,x=function(){var Y=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];return Y.reduce(function($,G){var Q=G.word,ie=G.width,le=$[$.length-1];if(le&&(i==null||o||le.width+ie+r<Number(i)))le.words.push(Q),le.width+=ie+r;else{var L={words:[Q],width:ie};$.push(L)}return $},[])},j=x(n),w=function(Y){return Y.reduce(function($,G){return $.width>G.width?$:G})};if(!p)return j;for(var S="…",b=function(Y){var $=y.slice(0,Y),G=$5({breakAll:h,style:d,children:$+S}).wordsWithComputedWidth,Q=x(G),ie=Q.length>c||w(Q).width>Number(i);return[ie,Q]},A=0,_=y.length-1,O=0,T;A<=_&&O<=y.length-1;){var N=Math.floor((A+_)/2),E=N-1,M=b(E),D=GP(M,2),R=D[0],B=D[1],q=b(N),z=GP(q,1),H=z[0];if(!R&&!H&&(A=N+1),R&&H&&(_=N-1),!R&&H){T=B;break}O++}return T||j},YP=function(t){var n=Re(t)?[]:t.toString().split(L5);return[{words:n}]},oZ=function(t){var n=t.width,r=t.scaleToFit,i=t.children,o=t.style,c=t.breakAll,f=t.maxLines;if((n||r)&&!Cs.isSsr){var d,h,p=$5({breakAll:c,children:i,style:o});if(p){var y=p.wordsWithComputedWidth,x=p.spaceWidth;d=y,h=x}else return YP(i);return sZ({breakAll:c,children:i,maxLines:f,style:o},d,h,n,r)}return YP(i)},XP="#808080",Ns=function(t){var n=t.x,r=n===void 0?0:n,i=t.y,o=i===void 0?0:i,c=t.lineHeight,f=c===void 0?"1em":c,d=t.capHeight,h=d===void 0?"0.71em":d,p=t.scaleToFit,y=p===void 0?!1:p,x=t.textAnchor,j=x===void 0?"start":x,w=t.verticalAnchor,S=w===void 0?"end":w,b=t.fill,A=b===void 0?XP:b,_=FP(t,JW),O=P.useMemo(function(){return oZ({breakAll:_.breakAll,children:_.children,maxLines:_.maxLines,scaleToFit:y,style:_.style,width:_.width})},[_.breakAll,_.children,_.maxLines,y,_.style,_.width]),T=_.dx,N=_.dy,E=_.angle,M=_.className,D=_.breakAll,R=FP(_,eZ);if(!Xt(r)||!Xt(o))return null;var B=r+(de(T)?T:0),q=o+(de(N)?N:0),z;switch(S){case"start":z=p0("calc(".concat(h,")"));break;case"middle":z=p0("calc(".concat((O.length-1)/2," * -").concat(f," + (").concat(h," / 2))"));break;default:z=p0("calc(".concat(O.length-1," * -").concat(f,")"));break}var H=[];if(y){var X=O[0].width,Y=_.width;H.push("scale(".concat((de(Y)?Y/X:1)/X,")"))}return E&&H.push("rotate(".concat(E,", ").concat(B,", ").concat(q,")")),H.length&&(R.transform=H.join(" ")),U.createElement("text",fj({},Ne(R,!0),{x:B,y:q,className:ze("recharts-text",M),textAnchor:j,fill:A.includes("url")?XP:A}),O.map(function($,G){var Q=$.words.join(D?"":" ");return U.createElement("tspan",{x:B,dy:G===0?z:f,key:"".concat(Q,"-").concat(G)},Q)}))};function Ti(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function lZ(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function NS(e){let t,n,r;e.length!==2?(t=Ti,n=(f,d)=>Ti(e(f),d),r=(f,d)=>e(f)-d):(t=e===Ti||e===lZ?e:cZ,n=e,r=e);function i(f,d,h=0,p=f.length){if(h<p){if(t(d,d)!==0)return p;do{const y=h+p>>>1;n(f[y],d)<0?h=y+1:p=y}while(h<p)}return h}function o(f,d,h=0,p=f.length){if(h<p){if(t(d,d)!==0)return p;do{const y=h+p>>>1;n(f[y],d)<=0?h=y+1:p=y}while(h<p)}return h}function c(f,d,h=0,p=f.length){const y=i(f,d,h,p-1);return y>h&&r(f[y-1],d)>-r(f[y],d)?y-1:y}return{left:i,center:c,right:o}}function cZ(){return 0}function B5(e){return e===null?NaN:+e}function*uZ(e,t){for(let n of e)n!=null&&(n=+n)>=n&&(yield n)}const fZ=NS(Ti),ef=fZ.right;NS(B5).center;class WP extends Map{constructor(t,n=mZ){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:n}}),t!=null)for(const[r,i]of t)this.set(r,i)}get(t){return super.get(ZP(this,t))}has(t){return super.has(ZP(this,t))}set(t,n){return super.set(dZ(this,t),n)}delete(t){return super.delete(hZ(this,t))}}function ZP({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):n}function dZ({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):(e.set(r,n),n)}function hZ({_intern:e,_key:t},n){const r=t(n);return e.has(r)&&(n=e.get(r),e.delete(r)),n}function mZ(e){return e!==null&&typeof e=="object"?e.valueOf():e}function pZ(e=Ti){if(e===Ti)return q5;if(typeof e!="function")throw new TypeError("compare is not a function");return(t,n)=>{const r=e(t,n);return r||r===0?r:(e(n,n)===0)-(e(t,t)===0)}}function q5(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(e<t?-1:e>t?1:0)}const yZ=Math.sqrt(50),xZ=Math.sqrt(10),gZ=Math.sqrt(2);function Bh(e,t,n){const r=(t-e)/Math.max(0,n),i=Math.floor(Math.log10(r)),o=r/Math.pow(10,i),c=o>=yZ?10:o>=xZ?5:o>=gZ?2:1;let f,d,h;return i<0?(h=Math.pow(10,-i)/c,f=Math.round(e*h),d=Math.round(t*h),f/h<e&&++f,d/h>t&&--d,h=-h):(h=Math.pow(10,i)*c,f=Math.round(e/h),d=Math.round(t/h),f*h<e&&++f,d*h>t&&--d),d<f&&.5<=n&&n<2?Bh(e,t,n*2):[f,d,h]}function dj(e,t,n){if(t=+t,e=+e,n=+n,!(n>0))return[];if(e===t)return[e];const r=t<e,[i,o,c]=r?Bh(t,e,n):Bh(e,t,n);if(!(o>=i))return[];const f=o-i+1,d=new Array(f);if(r)if(c<0)for(let h=0;h<f;++h)d[h]=(o-h)/-c;else for(let h=0;h<f;++h)d[h]=(o-h)*c;else if(c<0)for(let h=0;h<f;++h)d[h]=(i+h)/-c;else for(let h=0;h<f;++h)d[h]=(i+h)*c;return d}function hj(e,t,n){return t=+t,e=+e,n=+n,Bh(e,t,n)[2]}function mj(e,t,n){t=+t,e=+e,n=+n;const r=t<e,i=r?hj(t,e,n):hj(e,t,n);return(r?-1:1)*(i<0?1/-i:i)}function QP(e,t){let n;for(const r of e)r!=null&&(n<r||n===void 0&&r>=r)&&(n=r);return n}function JP(e,t){let n;for(const r of e)r!=null&&(n>r||n===void 0&&r>=r)&&(n=r);return n}function I5(e,t,n=0,r=1/0,i){if(t=Math.floor(t),n=Math.floor(Math.max(0,n)),r=Math.floor(Math.min(e.length-1,r)),!(n<=t&&t<=r))return e;for(i=i===void 0?q5:pZ(i);r>n;){if(r-n>600){const d=r-n+1,h=t-n+1,p=Math.log(d),y=.5*Math.exp(2*p/3),x=.5*Math.sqrt(p*y*(d-y)/d)*(h-d/2<0?-1:1),j=Math.max(n,Math.floor(t-h*y/d+x)),w=Math.min(r,Math.floor(t+(d-h)*y/d+x));I5(e,t,j,w,i)}const o=e[t];let c=n,f=r;for(Mc(e,n,t),i(e[r],o)>0&&Mc(e,n,r);c<f;){for(Mc(e,c,f),++c,--f;i(e[c],o)<0;)++c;for(;i(e[f],o)>0;)--f}i(e[n],o)===0?Mc(e,n,f):(++f,Mc(e,f,r)),f<=t&&(n=f+1),t<=f&&(r=f-1)}return e}function Mc(e,t,n){const r=e[t];e[t]=e[n],e[n]=r}function vZ(e,t,n){if(e=Float64Array.from(uZ(e)),!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return JP(e);if(t>=1)return QP(e);var r,i=(r-1)*t,o=Math.floor(i),c=QP(I5(e,o).subarray(0,o+1)),f=JP(e.subarray(o+1));return c+(f-c)*(i-o)}}function bZ(e,t,n=B5){if(!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return+n(e[0],0,e);if(t>=1)return+n(e[r-1],r-1,e);var r,i=(r-1)*t,o=Math.floor(i),c=+n(e[o],o,e),f=+n(e[o+1],o+1,e);return c+(f-c)*(i-o)}}function jZ(e,t,n){e=+e,t=+t,n=(i=arguments.length)<2?(t=e,e=0,1):i<3?1:+n;for(var r=-1,i=Math.max(0,Math.ceil((t-e)/n))|0,o=new Array(i);++r<i;)o[r]=e+r*n;return o}function jr(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}function Ga(e,t){switch(arguments.length){case 0:break;case 1:{typeof e=="function"?this.interpolator(e):this.range(e);break}default:{this.domain(e),typeof t=="function"?this.interpolator(t):this.range(t);break}}return this}const pj=Symbol("implicit");function AS(){var e=new WP,t=[],n=[],r=pj;function i(o){let c=e.get(o);if(c===void 0){if(r!==pj)return r;e.set(o,c=t.push(o)-1)}return n[c%n.length]}return i.domain=function(o){if(!arguments.length)return t.slice();t=[],e=new WP;for(const c of o)e.has(c)||e.set(c,t.push(c)-1);return i},i.range=function(o){return arguments.length?(n=Array.from(o),i):n.slice()},i.unknown=function(o){return arguments.length?(r=o,i):r},i.copy=function(){return AS(t,n).unknown(r)},jr.apply(i,arguments),i}function pu(){var e=AS().unknown(void 0),t=e.domain,n=e.range,r=0,i=1,o,c,f=!1,d=0,h=0,p=.5;delete e.unknown;function y(){var x=t().length,j=i<r,w=j?i:r,S=j?r:i;o=(S-w)/Math.max(1,x-d+h*2),f&&(o=Math.floor(o)),w+=(S-w-o*(x-d))*p,c=o*(1-d),f&&(w=Math.round(w),c=Math.round(c));var b=jZ(x).map(function(A){return w+o*A});return n(j?b.reverse():b)}return e.domain=function(x){return arguments.length?(t(x),y()):t()},e.range=function(x){return arguments.length?([r,i]=x,r=+r,i=+i,y()):[r,i]},e.rangeRound=function(x){return[r,i]=x,r=+r,i=+i,f=!0,y()},e.bandwidth=function(){return c},e.step=function(){return o},e.round=function(x){return arguments.length?(f=!!x,y()):f},e.padding=function(x){return arguments.length?(d=Math.min(1,h=+x),y()):d},e.paddingInner=function(x){return arguments.length?(d=Math.min(1,x),y()):d},e.paddingOuter=function(x){return arguments.length?(h=+x,y()):h},e.align=function(x){return arguments.length?(p=Math.max(0,Math.min(1,x)),y()):p},e.copy=function(){return pu(t(),[r,i]).round(f).paddingInner(d).paddingOuter(h).align(p)},jr.apply(y(),arguments)}function U5(e){var t=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,delete e.paddingOuter,e.copy=function(){return U5(t())},e}function Wc(){return U5(pu.apply(null,arguments).paddingInner(1))}function OS(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function V5(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function tf(){}var yu=.7,qh=1/yu,$o="\\s*([+-]?\\d+)\\s*",xu="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Wr="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",wZ=/^#([0-9a-f]{3,8})$/,SZ=new RegExp(`^rgb\\(${$o},${$o},${$o}\\)$`),NZ=new RegExp(`^rgb\\(${Wr},${Wr},${Wr}\\)$`),AZ=new RegExp(`^rgba\\(${$o},${$o},${$o},${xu}\\)$`),OZ=new RegExp(`^rgba\\(${Wr},${Wr},${Wr},${xu}\\)$`),_Z=new RegExp(`^hsl\\(${xu},${Wr},${Wr}\\)$`),TZ=new RegExp(`^hsla\\(${xu},${Wr},${Wr},${xu}\\)$`),eR={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};OS(tf,gu,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:tR,formatHex:tR,formatHex8:EZ,formatHsl:CZ,formatRgb:nR,toString:nR});function tR(){return this.rgb().formatHex()}function EZ(){return this.rgb().formatHex8()}function CZ(){return H5(this).formatHsl()}function nR(){return this.rgb().formatRgb()}function gu(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=wZ.exec(e))?(n=t[1].length,t=parseInt(t[1],16),n===6?rR(t):n===3?new Mn(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?Fd(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?Fd(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=SZ.exec(e))?new Mn(t[1],t[2],t[3],1):(t=NZ.exec(e))?new Mn(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=AZ.exec(e))?Fd(t[1],t[2],t[3],t[4]):(t=OZ.exec(e))?Fd(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=_Z.exec(e))?sR(t[1],t[2]/100,t[3]/100,1):(t=TZ.exec(e))?sR(t[1],t[2]/100,t[3]/100,t[4]):eR.hasOwnProperty(e)?rR(eR[e]):e==="transparent"?new Mn(NaN,NaN,NaN,0):null}function rR(e){return new Mn(e>>16&255,e>>8&255,e&255,1)}function Fd(e,t,n,r){return r<=0&&(e=t=n=NaN),new Mn(e,t,n,r)}function MZ(e){return e instanceof tf||(e=gu(e)),e?(e=e.rgb(),new Mn(e.r,e.g,e.b,e.opacity)):new Mn}function yj(e,t,n,r){return arguments.length===1?MZ(e):new Mn(e,t,n,r??1)}function Mn(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}OS(Mn,yj,V5(tf,{brighter(e){return e=e==null?qh:Math.pow(qh,e),new Mn(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?yu:Math.pow(yu,e),new Mn(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new Mn(bs(this.r),bs(this.g),bs(this.b),Ih(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:aR,formatHex:aR,formatHex8:PZ,formatRgb:iR,toString:iR}));function aR(){return`#${ms(this.r)}${ms(this.g)}${ms(this.b)}`}function PZ(){return`#${ms(this.r)}${ms(this.g)}${ms(this.b)}${ms((isNaN(this.opacity)?1:this.opacity)*255)}`}function iR(){const e=Ih(this.opacity);return`${e===1?"rgb(":"rgba("}${bs(this.r)}, ${bs(this.g)}, ${bs(this.b)}${e===1?")":`, ${e})`}`}function Ih(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function bs(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function ms(e){return e=bs(e),(e<16?"0":"")+e.toString(16)}function sR(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new Pr(e,t,n,r)}function H5(e){if(e instanceof Pr)return new Pr(e.h,e.s,e.l,e.opacity);if(e instanceof tf||(e=gu(e)),!e)return new Pr;if(e instanceof Pr)return e;e=e.rgb();var t=e.r/255,n=e.g/255,r=e.b/255,i=Math.min(t,n,r),o=Math.max(t,n,r),c=NaN,f=o-i,d=(o+i)/2;return f?(t===o?c=(n-r)/f+(n<r)*6:n===o?c=(r-t)/f+2:c=(t-n)/f+4,f/=d<.5?o+i:2-o-i,c*=60):f=d>0&&d<1?0:c,new Pr(c,f,d,e.opacity)}function RZ(e,t,n,r){return arguments.length===1?H5(e):new Pr(e,t,n,r??1)}function Pr(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}OS(Pr,RZ,V5(tf,{brighter(e){return e=e==null?qh:Math.pow(qh,e),new Pr(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?yu:Math.pow(yu,e),new Pr(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,i=2*n-r;return new Mn(y0(e>=240?e-240:e+120,i,r),y0(e,i,r),y0(e<120?e+240:e-120,i,r),this.opacity)},clamp(){return new Pr(oR(this.h),Gd(this.s),Gd(this.l),Ih(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=Ih(this.opacity);return`${e===1?"hsl(":"hsla("}${oR(this.h)}, ${Gd(this.s)*100}%, ${Gd(this.l)*100}%${e===1?")":`, ${e})`}`}}));function oR(e){return e=(e||0)%360,e<0?e+360:e}function Gd(e){return Math.max(0,Math.min(1,e||0))}function y0(e,t,n){return(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)*255}const _S=e=>()=>e;function kZ(e,t){return function(n){return e+n*t}}function DZ(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}function zZ(e){return(e=+e)==1?F5:function(t,n){return n-t?DZ(t,n,e):_S(isNaN(t)?n:t)}}function F5(e,t){var n=t-e;return n?kZ(e,n):_S(isNaN(e)?t:e)}const lR=(function e(t){var n=zZ(t);function r(i,o){var c=n((i=yj(i)).r,(o=yj(o)).r),f=n(i.g,o.g),d=n(i.b,o.b),h=F5(i.opacity,o.opacity);return function(p){return i.r=c(p),i.g=f(p),i.b=d(p),i.opacity=h(p),i+""}}return r.gamma=e,r})(1);function LZ(e,t){t||(t=[]);var n=e?Math.min(t.length,e.length):0,r=t.slice(),i;return function(o){for(i=0;i<n;++i)r[i]=e[i]*(1-o)+t[i]*o;return r}}function $Z(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function BZ(e,t){var n=t?t.length:0,r=e?Math.min(n,e.length):0,i=new Array(r),o=new Array(n),c;for(c=0;c<r;++c)i[c]=Ol(e[c],t[c]);for(;c<n;++c)o[c]=t[c];return function(f){for(c=0;c<r;++c)o[c]=i[c](f);return o}}function qZ(e,t){var n=new Date;return e=+e,t=+t,function(r){return n.setTime(e*(1-r)+t*r),n}}function Uh(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}function IZ(e,t){var n={},r={},i;(e===null||typeof e!="object")&&(e={}),(t===null||typeof t!="object")&&(t={});for(i in t)i in e?n[i]=Ol(e[i],t[i]):r[i]=t[i];return function(o){for(i in n)r[i]=n[i](o);return r}}var xj=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,x0=new RegExp(xj.source,"g");function UZ(e){return function(){return e}}function VZ(e){return function(t){return e(t)+""}}function HZ(e,t){var n=xj.lastIndex=x0.lastIndex=0,r,i,o,c=-1,f=[],d=[];for(e=e+"",t=t+"";(r=xj.exec(e))&&(i=x0.exec(t));)(o=i.index)>n&&(o=t.slice(n,o),f[c]?f[c]+=o:f[++c]=o),(r=r[0])===(i=i[0])?f[c]?f[c]+=i:f[++c]=i:(f[++c]=null,d.push({i:c,x:Uh(r,i)})),n=x0.lastIndex;return n<t.length&&(o=t.slice(n),f[c]?f[c]+=o:f[++c]=o),f.length<2?d[0]?VZ(d[0].x):UZ(t):(t=d.length,function(h){for(var p=0,y;p<t;++p)f[(y=d[p]).i]=y.x(h);return f.join("")})}function Ol(e,t){var n=typeof t,r;return t==null||n==="boolean"?_S(t):(n==="number"?Uh:n==="string"?(r=gu(t))?(t=r,lR):HZ:t instanceof gu?lR:t instanceof Date?qZ:$Z(t)?LZ:Array.isArray(t)?BZ:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?IZ:Uh)(e,t)}function TS(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}function FZ(e,t){t===void 0&&(t=e,e=Ol);for(var n=0,r=t.length-1,i=t[0],o=new Array(r<0?0:r);n<r;)o[n]=e(i,i=t[++n]);return function(c){var f=Math.max(0,Math.min(r-1,Math.floor(c*=r)));return o[f](c-f)}}function GZ(e){return function(){return e}}function Vh(e){return+e}var cR=[0,1];function wn(e){return e}function gj(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:GZ(isNaN(t)?NaN:.5)}function KZ(e,t){var n;return e>t&&(n=e,e=t,t=n),function(r){return Math.max(e,Math.min(t,r))}}function YZ(e,t,n){var r=e[0],i=e[1],o=t[0],c=t[1];return i<r?(r=gj(i,r),o=n(c,o)):(r=gj(r,i),o=n(o,c)),function(f){return o(r(f))}}function XZ(e,t,n){var r=Math.min(e.length,t.length)-1,i=new Array(r),o=new Array(r),c=-1;for(e[r]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++c<r;)i[c]=gj(e[c],e[c+1]),o[c]=n(t[c],t[c+1]);return function(f){var d=ef(e,f,1,r)-1;return o[d](i[d](f))}}function nf(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function Qm(){var e=cR,t=cR,n=Ol,r,i,o,c=wn,f,d,h;function p(){var x=Math.min(e.length,t.length);return c!==wn&&(c=KZ(e[0],e[x-1])),f=x>2?XZ:YZ,d=h=null,y}function y(x){return x==null||isNaN(x=+x)?o:(d||(d=f(e.map(r),t,n)))(r(c(x)))}return y.invert=function(x){return c(i((h||(h=f(t,e.map(r),Uh)))(x)))},y.domain=function(x){return arguments.length?(e=Array.from(x,Vh),p()):e.slice()},y.range=function(x){return arguments.length?(t=Array.from(x),p()):t.slice()},y.rangeRound=function(x){return t=Array.from(x),n=TS,p()},y.clamp=function(x){return arguments.length?(c=x?!0:wn,p()):c!==wn},y.interpolate=function(x){return arguments.length?(n=x,p()):n},y.unknown=function(x){return arguments.length?(o=x,y):o},function(x,j){return r=x,i=j,p()}}function ES(){return Qm()(wn,wn)}function WZ(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function Hh(e,t){if(!isFinite(e)||e===0)return null;var n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"),r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]}function Ko(e){return e=Hh(Math.abs(e)),e?e[1]:NaN}function ZZ(e,t){return function(n,r){for(var i=n.length,o=[],c=0,f=e[0],d=0;i>0&&f>0&&(d+f+1>r&&(f=Math.max(1,r-d)),o.push(n.substring(i-=f,i+f)),!((d+=f+1)>r));)f=e[c=(c+1)%e.length];return o.reverse().join(t)}}function QZ(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var JZ=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function vu(e){if(!(t=JZ.exec(e)))throw new Error("invalid format: "+e);var t;return new CS({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}vu.prototype=CS.prototype;function CS(e){this.fill=e.fill===void 0?" ":e.fill+"",this.align=e.align===void 0?">":e.align+"",this.sign=e.sign===void 0?"-":e.sign+"",this.symbol=e.symbol===void 0?"":e.symbol+"",this.zero=!!e.zero,this.width=e.width===void 0?void 0:+e.width,this.comma=!!e.comma,this.precision=e.precision===void 0?void 0:+e.precision,this.trim=!!e.trim,this.type=e.type===void 0?"":e.type+""}CS.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(this.width===void 0?"":Math.max(1,this.width|0))+(this.comma?",":"")+(this.precision===void 0?"":"."+Math.max(0,this.precision|0))+(this.trim?"~":"")+this.type};function eQ(e){e:for(var t=e.length,n=1,r=-1,i;n<t;++n)switch(e[n]){case".":r=i=n;break;case"0":r===0&&(r=n),i=n;break;default:if(!+e[n])break e;r>0&&(r=0);break}return r>0?e.slice(0,r)+e.slice(i+1):e}var Fh;function tQ(e,t){var n=Hh(e,t);if(!n)return Fh=void 0,e.toPrecision(t);var r=n[0],i=n[1],o=i-(Fh=Math.max(-8,Math.min(8,Math.floor(i/3)))*3)+1,c=r.length;return o===c?r:o>c?r+new Array(o-c+1).join("0"):o>0?r.slice(0,o)+"."+r.slice(o):"0."+new Array(1-o).join("0")+Hh(e,Math.max(0,t+o-1))[0]}function uR(e,t){var n=Hh(e,t);if(!n)return e+"";var r=n[0],i=n[1];return i<0?"0."+new Array(-i).join("0")+r:r.length>i+1?r.slice(0,i+1)+"."+r.slice(i+1):r+new Array(i-r.length+2).join("0")}const fR={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:WZ,e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>uR(e*100,t),r:uR,s:tQ,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function dR(e){return e}var hR=Array.prototype.map,mR=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function nQ(e){var t=e.grouping===void 0||e.thousands===void 0?dR:ZZ(hR.call(e.grouping,Number),e.thousands+""),n=e.currency===void 0?"":e.currency[0]+"",r=e.currency===void 0?"":e.currency[1]+"",i=e.decimal===void 0?".":e.decimal+"",o=e.numerals===void 0?dR:QZ(hR.call(e.numerals,String)),c=e.percent===void 0?"%":e.percent+"",f=e.minus===void 0?"−":e.minus+"",d=e.nan===void 0?"NaN":e.nan+"";function h(y,x){y=vu(y);var j=y.fill,w=y.align,S=y.sign,b=y.symbol,A=y.zero,_=y.width,O=y.comma,T=y.precision,N=y.trim,E=y.type;E==="n"?(O=!0,E="g"):fR[E]||(T===void 0&&(T=12),N=!0,E="g"),(A||j==="0"&&w==="=")&&(A=!0,j="0",w="=");var M=(x&&x.prefix!==void 0?x.prefix:"")+(b==="$"?n:b==="#"&&/[boxX]/.test(E)?"0"+E.toLowerCase():""),D=(b==="$"?r:/[%p]/.test(E)?c:"")+(x&&x.suffix!==void 0?x.suffix:""),R=fR[E],B=/[defgprs%]/.test(E);T=T===void 0?6:/[gprs]/.test(E)?Math.max(1,Math.min(21,T)):Math.max(0,Math.min(20,T));function q(z){var H=M,X=D,Y,$,G;if(E==="c")X=R(z)+X,z="";else{z=+z;var Q=z<0||1/z<0;if(z=isNaN(z)?d:R(Math.abs(z),T),N&&(z=eQ(z)),Q&&+z==0&&S!=="+"&&(Q=!1),H=(Q?S==="("?S:f:S==="-"||S==="("?"":S)+H,X=(E==="s"&&!isNaN(z)&&Fh!==void 0?mR[8+Fh/3]:"")+X+(Q&&S==="("?")":""),B){for(Y=-1,$=z.length;++Y<$;)if(G=z.charCodeAt(Y),48>G||G>57){X=(G===46?i+z.slice(Y+1):z.slice(Y))+X,z=z.slice(0,Y);break}}}O&&!A&&(z=t(z,1/0));var ie=H.length+z.length+X.length,le=ie<_?new Array(_-ie+1).join(j):"";switch(O&&A&&(z=t(le+z,le.length?_-X.length:1/0),le=""),w){case"<":z=H+z+X+le;break;case"=":z=H+le+z+X;break;case"^":z=le.slice(0,ie=le.length>>1)+H+z+X+le.slice(ie);break;default:z=le+H+z+X;break}return o(z)}return q.toString=function(){return y+""},q}function p(y,x){var j=Math.max(-8,Math.min(8,Math.floor(Ko(x)/3)))*3,w=Math.pow(10,-j),S=h((y=vu(y),y.type="f",y),{suffix:mR[8+j/3]});return function(b){return S(w*b)}}return{format:h,formatPrefix:p}}var Kd,MS,G5;rQ({thousands:",",grouping:[3],currency:["$",""]});function rQ(e){return Kd=nQ(e),MS=Kd.format,G5=Kd.formatPrefix,Kd}function aQ(e){return Math.max(0,-Ko(Math.abs(e)))}function iQ(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(Ko(t)/3)))*3-Ko(Math.abs(e)))}function sQ(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,Ko(t)-Ko(e))+1}function K5(e,t,n,r){var i=mj(e,t,n),o;switch(r=vu(r??",f"),r.type){case"s":{var c=Math.max(Math.abs(e),Math.abs(t));return r.precision==null&&!isNaN(o=iQ(i,c))&&(r.precision=o),G5(r,c)}case"":case"e":case"g":case"p":case"r":{r.precision==null&&!isNaN(o=sQ(i,Math.max(Math.abs(e),Math.abs(t))))&&(r.precision=o-(r.type==="e"));break}case"f":case"%":{r.precision==null&&!isNaN(o=aQ(i))&&(r.precision=o-(r.type==="%")*2);break}}return MS(r)}function Di(e){var t=e.domain;return e.ticks=function(n){var r=t();return dj(r[0],r[r.length-1],n??10)},e.tickFormat=function(n,r){var i=t();return K5(i[0],i[i.length-1],n??10,r)},e.nice=function(n){n==null&&(n=10);var r=t(),i=0,o=r.length-1,c=r[i],f=r[o],d,h,p=10;for(f<c&&(h=c,c=f,f=h,h=i,i=o,o=h);p-- >0;){if(h=hj(c,f,n),h===d)return r[i]=c,r[o]=f,t(r);if(h>0)c=Math.floor(c/h)*h,f=Math.ceil(f/h)*h;else if(h<0)c=Math.ceil(c*h)/h,f=Math.floor(f*h)/h;else break;d=h}return e},e}function Gh(){var e=ES();return e.copy=function(){return nf(e,Gh())},jr.apply(e,arguments),Di(e)}function Y5(e){var t;function n(r){return r==null||isNaN(r=+r)?t:r}return n.invert=n,n.domain=n.range=function(r){return arguments.length?(e=Array.from(r,Vh),n):e.slice()},n.unknown=function(r){return arguments.length?(t=r,n):t},n.copy=function(){return Y5(e).unknown(t)},e=arguments.length?Array.from(e,Vh):[0,1],Di(n)}function X5(e,t){e=e.slice();var n=0,r=e.length-1,i=e[n],o=e[r],c;return o<i&&(c=n,n=r,r=c,c=i,i=o,o=c),e[n]=t.floor(i),e[r]=t.ceil(o),e}function pR(e){return Math.log(e)}function yR(e){return Math.exp(e)}function oQ(e){return-Math.log(-e)}function lQ(e){return-Math.exp(-e)}function cQ(e){return isFinite(e)?+("1e"+e):e<0?0:e}function uQ(e){return e===10?cQ:e===Math.E?Math.exp:t=>Math.pow(e,t)}function fQ(e){return e===Math.E?Math.log:e===10&&Math.log10||e===2&&Math.log2||(e=Math.log(e),t=>Math.log(t)/e)}function xR(e){return(t,n)=>-e(-t,n)}function PS(e){const t=e(pR,yR),n=t.domain;let r=10,i,o;function c(){return i=fQ(r),o=uQ(r),n()[0]<0?(i=xR(i),o=xR(o),e(oQ,lQ)):e(pR,yR),t}return t.base=function(f){return arguments.length?(r=+f,c()):r},t.domain=function(f){return arguments.length?(n(f),c()):n()},t.ticks=f=>{const d=n();let h=d[0],p=d[d.length-1];const y=p<h;y&&([h,p]=[p,h]);let x=i(h),j=i(p),w,S;const b=f==null?10:+f;let A=[];if(!(r%1)&&j-x<b){if(x=Math.floor(x),j=Math.ceil(j),h>0){for(;x<=j;++x)for(w=1;w<r;++w)if(S=x<0?w/o(-x):w*o(x),!(S<h)){if(S>p)break;A.push(S)}}else for(;x<=j;++x)for(w=r-1;w>=1;--w)if(S=x>0?w/o(-x):w*o(x),!(S<h)){if(S>p)break;A.push(S)}A.length*2<b&&(A=dj(h,p,b))}else A=dj(x,j,Math.min(j-x,b)).map(o);return y?A.reverse():A},t.tickFormat=(f,d)=>{if(f==null&&(f=10),d==null&&(d=r===10?"s":","),typeof d!="function"&&(!(r%1)&&(d=vu(d)).precision==null&&(d.trim=!0),d=MS(d)),f===1/0)return d;const h=Math.max(1,r*f/t.ticks().length);return p=>{let y=p/o(Math.round(i(p)));return y*r<r-.5&&(y*=r),y<=h?d(p):""}},t.nice=()=>n(X5(n(),{floor:f=>o(Math.floor(i(f))),ceil:f=>o(Math.ceil(i(f)))})),t}function W5(){const e=PS(Qm()).domain([1,10]);return e.copy=()=>nf(e,W5()).base(e.base()),jr.apply(e,arguments),e}function gR(e){return function(t){return Math.sign(t)*Math.log1p(Math.abs(t/e))}}function vR(e){return function(t){return Math.sign(t)*Math.expm1(Math.abs(t))*e}}function RS(e){var t=1,n=e(gR(t),vR(t));return n.constant=function(r){return arguments.length?e(gR(t=+r),vR(t)):t},Di(n)}function Z5(){var e=RS(Qm());return e.copy=function(){return nf(e,Z5()).constant(e.constant())},jr.apply(e,arguments)}function bR(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function dQ(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function hQ(e){return e<0?-e*e:e*e}function kS(e){var t=e(wn,wn),n=1;function r(){return n===1?e(wn,wn):n===.5?e(dQ,hQ):e(bR(n),bR(1/n))}return t.exponent=function(i){return arguments.length?(n=+i,r()):n},Di(t)}function DS(){var e=kS(Qm());return e.copy=function(){return nf(e,DS()).exponent(e.exponent())},jr.apply(e,arguments),e}function mQ(){return DS.apply(null,arguments).exponent(.5)}function jR(e){return Math.sign(e)*e*e}function pQ(e){return Math.sign(e)*Math.sqrt(Math.abs(e))}function Q5(){var e=ES(),t=[0,1],n=!1,r;function i(o){var c=pQ(e(o));return isNaN(c)?r:n?Math.round(c):c}return i.invert=function(o){return e.invert(jR(o))},i.domain=function(o){return arguments.length?(e.domain(o),i):e.domain()},i.range=function(o){return arguments.length?(e.range((t=Array.from(o,Vh)).map(jR)),i):t.slice()},i.rangeRound=function(o){return i.range(o).round(!0)},i.round=function(o){return arguments.length?(n=!!o,i):n},i.clamp=function(o){return arguments.length?(e.clamp(o),i):e.clamp()},i.unknown=function(o){return arguments.length?(r=o,i):r},i.copy=function(){return Q5(e.domain(),t).round(n).clamp(e.clamp()).unknown(r)},jr.apply(i,arguments),Di(i)}function J5(){var e=[],t=[],n=[],r;function i(){var c=0,f=Math.max(1,t.length);for(n=new Array(f-1);++c<f;)n[c-1]=bZ(e,c/f);return o}function o(c){return c==null||isNaN(c=+c)?r:t[ef(n,c)]}return o.invertExtent=function(c){var f=t.indexOf(c);return f<0?[NaN,NaN]:[f>0?n[f-1]:e[0],f<n.length?n[f]:e[e.length-1]]},o.domain=function(c){if(!arguments.length)return e.slice();e=[];for(let f of c)f!=null&&!isNaN(f=+f)&&e.push(f);return e.sort(Ti),i()},o.range=function(c){return arguments.length?(t=Array.from(c),i()):t.slice()},o.unknown=function(c){return arguments.length?(r=c,o):r},o.quantiles=function(){return n.slice()},o.copy=function(){return J5().domain(e).range(t).unknown(r)},jr.apply(o,arguments)}function eL(){var e=0,t=1,n=1,r=[.5],i=[0,1],o;function c(d){return d!=null&&d<=d?i[ef(r,d,0,n)]:o}function f(){var d=-1;for(r=new Array(n);++d<n;)r[d]=((d+1)*t-(d-n)*e)/(n+1);return c}return c.domain=function(d){return arguments.length?([e,t]=d,e=+e,t=+t,f()):[e,t]},c.range=function(d){return arguments.length?(n=(i=Array.from(d)).length-1,f()):i.slice()},c.invertExtent=function(d){var h=i.indexOf(d);return h<0?[NaN,NaN]:h<1?[e,r[0]]:h>=n?[r[n-1],t]:[r[h-1],r[h]]},c.unknown=function(d){return arguments.length&&(o=d),c},c.thresholds=function(){return r.slice()},c.copy=function(){return eL().domain([e,t]).range(i).unknown(o)},jr.apply(Di(c),arguments)}function tL(){var e=[.5],t=[0,1],n,r=1;function i(o){return o!=null&&o<=o?t[ef(e,o,0,r)]:n}return i.domain=function(o){return arguments.length?(e=Array.from(o),r=Math.min(e.length,t.length-1),i):e.slice()},i.range=function(o){return arguments.length?(t=Array.from(o),r=Math.min(e.length,t.length-1),i):t.slice()},i.invertExtent=function(o){var c=t.indexOf(o);return[e[c-1],e[c]]},i.unknown=function(o){return arguments.length?(n=o,i):n},i.copy=function(){return tL().domain(e).range(t).unknown(n)},jr.apply(i,arguments)}const g0=new Date,v0=new Date;function Wt(e,t,n,r){function i(o){return e(o=arguments.length===0?new Date:new Date(+o)),o}return i.floor=o=>(e(o=new Date(+o)),o),i.ceil=o=>(e(o=new Date(o-1)),t(o,1),e(o),o),i.round=o=>{const c=i(o),f=i.ceil(o);return o-c<f-o?c:f},i.offset=(o,c)=>(t(o=new Date(+o),c==null?1:Math.floor(c)),o),i.range=(o,c,f)=>{const d=[];if(o=i.ceil(o),f=f==null?1:Math.floor(f),!(o<c)||!(f>0))return d;let h;do d.push(h=new Date(+o)),t(o,f),e(o);while(h<o&&o<c);return d},i.filter=o=>Wt(c=>{if(c>=c)for(;e(c),!o(c);)c.setTime(c-1)},(c,f)=>{if(c>=c)if(f<0)for(;++f<=0;)for(;t(c,-1),!o(c););else for(;--f>=0;)for(;t(c,1),!o(c););}),n&&(i.count=(o,c)=>(g0.setTime(+o),v0.setTime(+c),e(g0),e(v0),Math.floor(n(g0,v0))),i.every=o=>(o=Math.floor(o),!isFinite(o)||!(o>0)?null:o>1?i.filter(r?c=>r(c)%o===0:c=>i.count(0,c)%o===0):i)),i}const Kh=Wt(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);Kh.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?Wt(t=>{t.setTime(Math.floor(t/e)*e)},(t,n)=>{t.setTime(+t+n*e)},(t,n)=>(n-t)/e):Kh);Kh.range;const Ta=1e3,yr=Ta*60,Ea=yr*60,Ia=Ea*24,zS=Ia*7,wR=Ia*30,b0=Ia*365,ps=Wt(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*Ta)},(e,t)=>(t-e)/Ta,e=>e.getUTCSeconds());ps.range;const LS=Wt(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Ta)},(e,t)=>{e.setTime(+e+t*yr)},(e,t)=>(t-e)/yr,e=>e.getMinutes());LS.range;const $S=Wt(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*yr)},(e,t)=>(t-e)/yr,e=>e.getUTCMinutes());$S.range;const BS=Wt(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Ta-e.getMinutes()*yr)},(e,t)=>{e.setTime(+e+t*Ea)},(e,t)=>(t-e)/Ea,e=>e.getHours());BS.range;const qS=Wt(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*Ea)},(e,t)=>(t-e)/Ea,e=>e.getUTCHours());qS.range;const rf=Wt(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*yr)/Ia,e=>e.getDate()-1);rf.range;const Jm=Wt(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/Ia,e=>e.getUTCDate()-1);Jm.range;const nL=Wt(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/Ia,e=>Math.floor(e/Ia));nL.range;function Ms(e){return Wt(t=>{t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},(t,n)=>{t.setDate(t.getDate()+n*7)},(t,n)=>(n-t-(n.getTimezoneOffset()-t.getTimezoneOffset())*yr)/zS)}const ep=Ms(0),Yh=Ms(1),yQ=Ms(2),xQ=Ms(3),Yo=Ms(4),gQ=Ms(5),vQ=Ms(6);ep.range;Yh.range;yQ.range;xQ.range;Yo.range;gQ.range;vQ.range;function Ps(e){return Wt(t=>{t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCDate(t.getUTCDate()+n*7)},(t,n)=>(n-t)/zS)}const tp=Ps(0),Xh=Ps(1),bQ=Ps(2),jQ=Ps(3),Xo=Ps(4),wQ=Ps(5),SQ=Ps(6);tp.range;Xh.range;bQ.range;jQ.range;Xo.range;wQ.range;SQ.range;const IS=Wt(e=>{e.setDate(1),e.setHours(0,0,0,0)},(e,t)=>{e.setMonth(e.getMonth()+t)},(e,t)=>t.getMonth()-e.getMonth()+(t.getFullYear()-e.getFullYear())*12,e=>e.getMonth());IS.range;const US=Wt(e=>{e.setUTCDate(1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCMonth(e.getUTCMonth()+t)},(e,t)=>t.getUTCMonth()-e.getUTCMonth()+(t.getUTCFullYear()-e.getUTCFullYear())*12,e=>e.getUTCMonth());US.range;const Ua=Wt(e=>{e.setMonth(0,1),e.setHours(0,0,0,0)},(e,t)=>{e.setFullYear(e.getFullYear()+t)},(e,t)=>t.getFullYear()-e.getFullYear(),e=>e.getFullYear());Ua.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Wt(t=>{t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},(t,n)=>{t.setFullYear(t.getFullYear()+n*e)});Ua.range;const Va=Wt(e=>{e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCFullYear(e.getUTCFullYear()+t)},(e,t)=>t.getUTCFullYear()-e.getUTCFullYear(),e=>e.getUTCFullYear());Va.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Wt(t=>{t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCFullYear(t.getUTCFullYear()+n*e)});Va.range;function rL(e,t,n,r,i,o){const c=[[ps,1,Ta],[ps,5,5*Ta],[ps,15,15*Ta],[ps,30,30*Ta],[o,1,yr],[o,5,5*yr],[o,15,15*yr],[o,30,30*yr],[i,1,Ea],[i,3,3*Ea],[i,6,6*Ea],[i,12,12*Ea],[r,1,Ia],[r,2,2*Ia],[n,1,zS],[t,1,wR],[t,3,3*wR],[e,1,b0]];function f(h,p,y){const x=p<h;x&&([h,p]=[p,h]);const j=y&&typeof y.range=="function"?y:d(h,p,y),w=j?j.range(h,+p+1):[];return x?w.reverse():w}function d(h,p,y){const x=Math.abs(p-h)/y,j=NS(([,,b])=>b).right(c,x);if(j===c.length)return e.every(mj(h/b0,p/b0,y));if(j===0)return Kh.every(Math.max(mj(h,p,y),1));const[w,S]=c[x/c[j-1][2]<c[j][2]/x?j-1:j];return w.every(S)}return[f,d]}const[NQ,AQ]=rL(Va,US,tp,nL,qS,$S),[OQ,_Q]=rL(Ua,IS,ep,rf,BS,LS);function j0(e){if(0<=e.y&&e.y<100){var t=new Date(-1,e.m,e.d,e.H,e.M,e.S,e.L);return t.setFullYear(e.y),t}return new Date(e.y,e.m,e.d,e.H,e.M,e.S,e.L)}function w0(e){if(0<=e.y&&e.y<100){var t=new Date(Date.UTC(-1,e.m,e.d,e.H,e.M,e.S,e.L));return t.setUTCFullYear(e.y),t}return new Date(Date.UTC(e.y,e.m,e.d,e.H,e.M,e.S,e.L))}function Pc(e,t,n){return{y:e,m:t,d:n,H:0,M:0,S:0,L:0}}function TQ(e){var t=e.dateTime,n=e.date,r=e.time,i=e.periods,o=e.days,c=e.shortDays,f=e.months,d=e.shortMonths,h=Rc(i),p=kc(i),y=Rc(o),x=kc(o),j=Rc(c),w=kc(c),S=Rc(f),b=kc(f),A=Rc(d),_=kc(d),O={a:G,A:Q,b:ie,B:le,c:null,d:TR,e:TR,f:ZQ,g:oJ,G:cJ,H:YQ,I:XQ,j:WQ,L:aL,m:QQ,M:JQ,p:L,q:F,Q:MR,s:PR,S:eJ,u:tJ,U:nJ,V:rJ,w:aJ,W:iJ,x:null,X:null,y:sJ,Y:lJ,Z:uJ,"%":CR},T={a:ae,A:fe,b:xe,B:Ae,c:null,d:ER,e:ER,f:mJ,g:NJ,G:OJ,H:fJ,I:dJ,j:hJ,L:sL,m:pJ,M:yJ,p:qe,q:Qe,Q:MR,s:PR,S:xJ,u:gJ,U:vJ,V:bJ,w:jJ,W:wJ,x:null,X:null,y:SJ,Y:AJ,Z:_J,"%":CR},N={a:B,A:q,b:z,B:H,c:X,d:OR,e:OR,f:HQ,g:AR,G:NR,H:_R,I:_R,j:qQ,L:VQ,m:BQ,M:IQ,p:R,q:$Q,Q:GQ,s:KQ,S:UQ,u:RQ,U:kQ,V:DQ,w:PQ,W:zQ,x:Y,X:$,y:AR,Y:NR,Z:LQ,"%":FQ};O.x=E(n,O),O.X=E(r,O),O.c=E(t,O),T.x=E(n,T),T.X=E(r,T),T.c=E(t,T);function E(ue,Ee){return function(Me){var ce=[],xt=-1,Le=0,_t=ue.length,Tt,fn,wr;for(Me instanceof Date||(Me=new Date(+Me));++xt<_t;)ue.charCodeAt(xt)===37&&(ce.push(ue.slice(Le,xt)),(fn=SR[Tt=ue.charAt(++xt)])!=null?Tt=ue.charAt(++xt):fn=Tt==="e"?" ":"0",(wr=Ee[Tt])&&(Tt=wr(Me,fn)),ce.push(Tt),Le=xt+1);return ce.push(ue.slice(Le,xt)),ce.join("")}}function M(ue,Ee){return function(Me){var ce=Pc(1900,void 0,1),xt=D(ce,ue,Me+="",0),Le,_t;if(xt!=Me.length)return null;if("Q"in ce)return new Date(ce.Q);if("s"in ce)return new Date(ce.s*1e3+("L"in ce?ce.L:0));if(Ee&&!("Z"in ce)&&(ce.Z=0),"p"in ce&&(ce.H=ce.H%12+ce.p*12),ce.m===void 0&&(ce.m="q"in ce?ce.q:0),"V"in ce){if(ce.V<1||ce.V>53)return null;"w"in ce||(ce.w=1),"Z"in ce?(Le=w0(Pc(ce.y,0,1)),_t=Le.getUTCDay(),Le=_t>4||_t===0?Xh.ceil(Le):Xh(Le),Le=Jm.offset(Le,(ce.V-1)*7),ce.y=Le.getUTCFullYear(),ce.m=Le.getUTCMonth(),ce.d=Le.getUTCDate()+(ce.w+6)%7):(Le=j0(Pc(ce.y,0,1)),_t=Le.getDay(),Le=_t>4||_t===0?Yh.ceil(Le):Yh(Le),Le=rf.offset(Le,(ce.V-1)*7),ce.y=Le.getFullYear(),ce.m=Le.getMonth(),ce.d=Le.getDate()+(ce.w+6)%7)}else("W"in ce||"U"in ce)&&("w"in ce||(ce.w="u"in ce?ce.u%7:"W"in ce?1:0),_t="Z"in ce?w0(Pc(ce.y,0,1)).getUTCDay():j0(Pc(ce.y,0,1)).getDay(),ce.m=0,ce.d="W"in ce?(ce.w+6)%7+ce.W*7-(_t+5)%7:ce.w+ce.U*7-(_t+6)%7);return"Z"in ce?(ce.H+=ce.Z/100|0,ce.M+=ce.Z%100,w0(ce)):j0(ce)}}function D(ue,Ee,Me,ce){for(var xt=0,Le=Ee.length,_t=Me.length,Tt,fn;xt<Le;){if(ce>=_t)return-1;if(Tt=Ee.charCodeAt(xt++),Tt===37){if(Tt=Ee.charAt(xt++),fn=N[Tt in SR?Ee.charAt(xt++):Tt],!fn||(ce=fn(ue,Me,ce))<0)return-1}else if(Tt!=Me.charCodeAt(ce++))return-1}return ce}function R(ue,Ee,Me){var ce=h.exec(Ee.slice(Me));return ce?(ue.p=p.get(ce[0].toLowerCase()),Me+ce[0].length):-1}function B(ue,Ee,Me){var ce=j.exec(Ee.slice(Me));return ce?(ue.w=w.get(ce[0].toLowerCase()),Me+ce[0].length):-1}function q(ue,Ee,Me){var ce=y.exec(Ee.slice(Me));return ce?(ue.w=x.get(ce[0].toLowerCase()),Me+ce[0].length):-1}function z(ue,Ee,Me){var ce=A.exec(Ee.slice(Me));return ce?(ue.m=_.get(ce[0].toLowerCase()),Me+ce[0].length):-1}function H(ue,Ee,Me){var ce=S.exec(Ee.slice(Me));return ce?(ue.m=b.get(ce[0].toLowerCase()),Me+ce[0].length):-1}function X(ue,Ee,Me){return D(ue,t,Ee,Me)}function Y(ue,Ee,Me){return D(ue,n,Ee,Me)}function $(ue,Ee,Me){return D(ue,r,Ee,Me)}function G(ue){return c[ue.getDay()]}function Q(ue){return o[ue.getDay()]}function ie(ue){return d[ue.getMonth()]}function le(ue){return f[ue.getMonth()]}function L(ue){return i[+(ue.getHours()>=12)]}function F(ue){return 1+~~(ue.getMonth()/3)}function ae(ue){return c[ue.getUTCDay()]}function fe(ue){return o[ue.getUTCDay()]}function xe(ue){return d[ue.getUTCMonth()]}function Ae(ue){return f[ue.getUTCMonth()]}function qe(ue){return i[+(ue.getUTCHours()>=12)]}function Qe(ue){return 1+~~(ue.getUTCMonth()/3)}return{format:function(ue){var Ee=E(ue+="",O);return Ee.toString=function(){return ue},Ee},parse:function(ue){var Ee=M(ue+="",!1);return Ee.toString=function(){return ue},Ee},utcFormat:function(ue){var Ee=E(ue+="",T);return Ee.toString=function(){return ue},Ee},utcParse:function(ue){var Ee=M(ue+="",!0);return Ee.toString=function(){return ue},Ee}}}var SR={"-":"",_:" ",0:"0"},tn=/^\s*\d+/,EQ=/^%/,CQ=/[\\^$*+?|[\]().{}]/g;function We(e,t,n){var r=e<0?"-":"",i=(r?-e:e)+"",o=i.length;return r+(o<n?new Array(n-o+1).join(t)+i:i)}function MQ(e){return e.replace(CQ,"\\$&")}function Rc(e){return new RegExp("^(?:"+e.map(MQ).join("|")+")","i")}function kc(e){return new Map(e.map((t,n)=>[t.toLowerCase(),n]))}function PQ(e,t,n){var r=tn.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function RQ(e,t,n){var r=tn.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function kQ(e,t,n){var r=tn.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function DQ(e,t,n){var r=tn.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function zQ(e,t,n){var r=tn.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function NR(e,t,n){var r=tn.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function AR(e,t,n){var r=tn.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function LQ(e,t,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(n,n+6));return r?(e.Z=r[1]?0:-(r[2]+(r[3]||"00")),n+r[0].length):-1}function $Q(e,t,n){var r=tn.exec(t.slice(n,n+1));return r?(e.q=r[0]*3-3,n+r[0].length):-1}function BQ(e,t,n){var r=tn.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function OR(e,t,n){var r=tn.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function qQ(e,t,n){var r=tn.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function _R(e,t,n){var r=tn.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function IQ(e,t,n){var r=tn.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function UQ(e,t,n){var r=tn.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function VQ(e,t,n){var r=tn.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function HQ(e,t,n){var r=tn.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function FQ(e,t,n){var r=EQ.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function GQ(e,t,n){var r=tn.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function KQ(e,t,n){var r=tn.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function TR(e,t){return We(e.getDate(),t,2)}function YQ(e,t){return We(e.getHours(),t,2)}function XQ(e,t){return We(e.getHours()%12||12,t,2)}function WQ(e,t){return We(1+rf.count(Ua(e),e),t,3)}function aL(e,t){return We(e.getMilliseconds(),t,3)}function ZQ(e,t){return aL(e,t)+"000"}function QQ(e,t){return We(e.getMonth()+1,t,2)}function JQ(e,t){return We(e.getMinutes(),t,2)}function eJ(e,t){return We(e.getSeconds(),t,2)}function tJ(e){var t=e.getDay();return t===0?7:t}function nJ(e,t){return We(ep.count(Ua(e)-1,e),t,2)}function iL(e){var t=e.getDay();return t>=4||t===0?Yo(e):Yo.ceil(e)}function rJ(e,t){return e=iL(e),We(Yo.count(Ua(e),e)+(Ua(e).getDay()===4),t,2)}function aJ(e){return e.getDay()}function iJ(e,t){return We(Yh.count(Ua(e)-1,e),t,2)}function sJ(e,t){return We(e.getFullYear()%100,t,2)}function oJ(e,t){return e=iL(e),We(e.getFullYear()%100,t,2)}function lJ(e,t){return We(e.getFullYear()%1e4,t,4)}function cJ(e,t){var n=e.getDay();return e=n>=4||n===0?Yo(e):Yo.ceil(e),We(e.getFullYear()%1e4,t,4)}function uJ(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+We(t/60|0,"0",2)+We(t%60,"0",2)}function ER(e,t){return We(e.getUTCDate(),t,2)}function fJ(e,t){return We(e.getUTCHours(),t,2)}function dJ(e,t){return We(e.getUTCHours()%12||12,t,2)}function hJ(e,t){return We(1+Jm.count(Va(e),e),t,3)}function sL(e,t){return We(e.getUTCMilliseconds(),t,3)}function mJ(e,t){return sL(e,t)+"000"}function pJ(e,t){return We(e.getUTCMonth()+1,t,2)}function yJ(e,t){return We(e.getUTCMinutes(),t,2)}function xJ(e,t){return We(e.getUTCSeconds(),t,2)}function gJ(e){var t=e.getUTCDay();return t===0?7:t}function vJ(e,t){return We(tp.count(Va(e)-1,e),t,2)}function oL(e){var t=e.getUTCDay();return t>=4||t===0?Xo(e):Xo.ceil(e)}function bJ(e,t){return e=oL(e),We(Xo.count(Va(e),e)+(Va(e).getUTCDay()===4),t,2)}function jJ(e){return e.getUTCDay()}function wJ(e,t){return We(Xh.count(Va(e)-1,e),t,2)}function SJ(e,t){return We(e.getUTCFullYear()%100,t,2)}function NJ(e,t){return e=oL(e),We(e.getUTCFullYear()%100,t,2)}function AJ(e,t){return We(e.getUTCFullYear()%1e4,t,4)}function OJ(e,t){var n=e.getUTCDay();return e=n>=4||n===0?Xo(e):Xo.ceil(e),We(e.getUTCFullYear()%1e4,t,4)}function _J(){return"+0000"}function CR(){return"%"}function MR(e){return+e}function PR(e){return Math.floor(+e/1e3)}var jo,lL,cL;TJ({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function TJ(e){return jo=TQ(e),lL=jo.format,jo.parse,cL=jo.utcFormat,jo.utcParse,jo}function EJ(e){return new Date(e)}function CJ(e){return e instanceof Date?+e:+new Date(+e)}function VS(e,t,n,r,i,o,c,f,d,h){var p=ES(),y=p.invert,x=p.domain,j=h(".%L"),w=h(":%S"),S=h("%I:%M"),b=h("%I %p"),A=h("%a %d"),_=h("%b %d"),O=h("%B"),T=h("%Y");function N(E){return(d(E)<E?j:f(E)<E?w:c(E)<E?S:o(E)<E?b:r(E)<E?i(E)<E?A:_:n(E)<E?O:T)(E)}return p.invert=function(E){return new Date(y(E))},p.domain=function(E){return arguments.length?x(Array.from(E,CJ)):x().map(EJ)},p.ticks=function(E){var M=x();return e(M[0],M[M.length-1],E??10)},p.tickFormat=function(E,M){return M==null?N:h(M)},p.nice=function(E){var M=x();return(!E||typeof E.range!="function")&&(E=t(M[0],M[M.length-1],E??10)),E?x(X5(M,E)):p},p.copy=function(){return nf(p,VS(e,t,n,r,i,o,c,f,d,h))},p}function MJ(){return jr.apply(VS(OQ,_Q,Ua,IS,ep,rf,BS,LS,ps,lL).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function PJ(){return jr.apply(VS(NQ,AQ,Va,US,tp,Jm,qS,$S,ps,cL).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function np(){var e=0,t=1,n,r,i,o,c=wn,f=!1,d;function h(y){return y==null||isNaN(y=+y)?d:c(i===0?.5:(y=(o(y)-n)*i,f?Math.max(0,Math.min(1,y)):y))}h.domain=function(y){return arguments.length?([e,t]=y,n=o(e=+e),r=o(t=+t),i=n===r?0:1/(r-n),h):[e,t]},h.clamp=function(y){return arguments.length?(f=!!y,h):f},h.interpolator=function(y){return arguments.length?(c=y,h):c};function p(y){return function(x){var j,w;return arguments.length?([j,w]=x,c=y(j,w),h):[c(0),c(1)]}}return h.range=p(Ol),h.rangeRound=p(TS),h.unknown=function(y){return arguments.length?(d=y,h):d},function(y){return o=y,n=y(e),r=y(t),i=n===r?0:1/(r-n),h}}function zi(e,t){return t.domain(e.domain()).interpolator(e.interpolator()).clamp(e.clamp()).unknown(e.unknown())}function uL(){var e=Di(np()(wn));return e.copy=function(){return zi(e,uL())},Ga.apply(e,arguments)}function fL(){var e=PS(np()).domain([1,10]);return e.copy=function(){return zi(e,fL()).base(e.base())},Ga.apply(e,arguments)}function dL(){var e=RS(np());return e.copy=function(){return zi(e,dL()).constant(e.constant())},Ga.apply(e,arguments)}function HS(){var e=kS(np());return e.copy=function(){return zi(e,HS()).exponent(e.exponent())},Ga.apply(e,arguments)}function RJ(){return HS.apply(null,arguments).exponent(.5)}function hL(){var e=[],t=wn;function n(r){if(r!=null&&!isNaN(r=+r))return t((ef(e,r,1)-1)/(e.length-1))}return n.domain=function(r){if(!arguments.length)return e.slice();e=[];for(let i of r)i!=null&&!isNaN(i=+i)&&e.push(i);return e.sort(Ti),n},n.interpolator=function(r){return arguments.length?(t=r,n):t},n.range=function(){return e.map((r,i)=>t(i/(e.length-1)))},n.quantiles=function(r){return Array.from({length:r+1},(i,o)=>vZ(e,o/r))},n.copy=function(){return hL(t).domain(e)},Ga.apply(n,arguments)}function rp(){var e=0,t=.5,n=1,r=1,i,o,c,f,d,h=wn,p,y=!1,x;function j(S){return isNaN(S=+S)?x:(S=.5+((S=+p(S))-o)*(r*S<r*o?f:d),h(y?Math.max(0,Math.min(1,S)):S))}j.domain=function(S){return arguments.length?([e,t,n]=S,i=p(e=+e),o=p(t=+t),c=p(n=+n),f=i===o?0:.5/(o-i),d=o===c?0:.5/(c-o),r=o<i?-1:1,j):[e,t,n]},j.clamp=function(S){return arguments.length?(y=!!S,j):y},j.interpolator=function(S){return arguments.length?(h=S,j):h};function w(S){return function(b){var A,_,O;return arguments.length?([A,_,O]=b,h=FZ(S,[A,_,O]),j):[h(0),h(.5),h(1)]}}return j.range=w(Ol),j.rangeRound=w(TS),j.unknown=function(S){return arguments.length?(x=S,j):x},function(S){return p=S,i=S(e),o=S(t),c=S(n),f=i===o?0:.5/(o-i),d=o===c?0:.5/(c-o),r=o<i?-1:1,j}}function mL(){var e=Di(rp()(wn));return e.copy=function(){return zi(e,mL())},Ga.apply(e,arguments)}function pL(){var e=PS(rp()).domain([.1,1,10]);return e.copy=function(){return zi(e,pL()).base(e.base())},Ga.apply(e,arguments)}function yL(){var e=RS(rp());return e.copy=function(){return zi(e,yL()).constant(e.constant())},Ga.apply(e,arguments)}function FS(){var e=kS(rp());return e.copy=function(){return zi(e,FS()).exponent(e.exponent())},Ga.apply(e,arguments)}function kJ(){return FS.apply(null,arguments).exponent(.5)}const RR=Object.freeze(Object.defineProperty({__proto__:null,scaleBand:pu,scaleDiverging:mL,scaleDivergingLog:pL,scaleDivergingPow:FS,scaleDivergingSqrt:kJ,scaleDivergingSymlog:yL,scaleIdentity:Y5,scaleImplicit:pj,scaleLinear:Gh,scaleLog:W5,scaleOrdinal:AS,scalePoint:Wc,scalePow:DS,scaleQuantile:J5,scaleQuantize:eL,scaleRadial:Q5,scaleSequential:uL,scaleSequentialLog:fL,scaleSequentialPow:HS,scaleSequentialQuantile:hL,scaleSequentialSqrt:RJ,scaleSequentialSymlog:dL,scaleSqrt:mQ,scaleSymlog:Z5,scaleThreshold:tL,scaleTime:MJ,scaleUtc:PJ,tickFormat:K5},Symbol.toStringTag,{value:"Module"}));var S0,kR;function ap(){if(kR)return S0;kR=1;var e=wl();function t(n,r,i){for(var o=-1,c=n.length;++o<c;){var f=n[o],d=r(f);if(d!=null&&(h===void 0?d===d&&!e(d):i(d,h)))var h=d,p=f}return p}return S0=t,S0}var N0,DR;function xL(){if(DR)return N0;DR=1;function e(t,n){return t>n}return N0=e,N0}var A0,zR;function DJ(){if(zR)return A0;zR=1;var e=ap(),t=xL(),n=Al();function r(i){return i&&i.length?e(i,n,t):void 0}return A0=r,A0}var zJ=DJ();const ip=at(zJ);var O0,LR;function gL(){if(LR)return O0;LR=1;function e(t,n){return t<n}return O0=e,O0}var _0,$R;function LJ(){if($R)return _0;$R=1;var e=ap(),t=gL(),n=Al();function r(i){return i&&i.length?e(i,n,t):void 0}return _0=r,_0}var $J=LJ();const sp=at($J);var T0,BR;function BJ(){if(BR)return T0;BR=1;var e=oS(),t=aa(),n=_5(),r=Rn();function i(o,c){var f=r(o)?e:n;return f(o,t(c,3))}return T0=i,T0}var E0,qR;function qJ(){if(qR)return E0;qR=1;var e=A5(),t=BJ();function n(r,i){return e(t(r,i),1)}return E0=n,E0}var IJ=qJ();const UJ=at(IJ);var C0,IR;function VJ(){if(IR)return C0;IR=1;var e=bS();function t(n,r){return e(n,r)}return C0=t,C0}var HJ=VJ();const af=at(HJ);var _l=1e9,FJ={precision:20,rounding:4,toExpNeg:-7,toExpPos:21,LN10:"2.302585092994045684017991454684364207601101488628772976033327900967572609677352480235997205089598298341967784042286"},KS,At=!0,br="[DecimalError] ",js=br+"Invalid argument: ",GS=br+"Exponent out of range: ",Tl=Math.floor,ls=Math.pow,GJ=/^(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,Yn,Jt=1e7,jt=7,vL=9007199254740991,Wh=Tl(vL/jt),me={};me.absoluteValue=me.abs=function(){var e=new this.constructor(this);return e.s&&(e.s=1),e};me.comparedTo=me.cmp=function(e){var t,n,r,i,o=this;if(e=new o.constructor(e),o.s!==e.s)return o.s||-e.s;if(o.e!==e.e)return o.e>e.e^o.s<0?1:-1;for(r=o.d.length,i=e.d.length,t=0,n=r<i?r:i;t<n;++t)if(o.d[t]!==e.d[t])return o.d[t]>e.d[t]^o.s<0?1:-1;return r===i?0:r>i^o.s<0?1:-1};me.decimalPlaces=me.dp=function(){var e=this,t=e.d.length-1,n=(t-e.e)*jt;if(t=e.d[t],t)for(;t%10==0;t/=10)n--;return n<0?0:n};me.dividedBy=me.div=function(e){return Ra(this,new this.constructor(e))};me.dividedToIntegerBy=me.idiv=function(e){var t=this,n=t.constructor;return dt(Ra(t,new n(e),0,1),n.precision)};me.equals=me.eq=function(e){return!this.cmp(e)};me.exponent=function(){return Ut(this)};me.greaterThan=me.gt=function(e){return this.cmp(e)>0};me.greaterThanOrEqualTo=me.gte=function(e){return this.cmp(e)>=0};me.isInteger=me.isint=function(){return this.e>this.d.length-2};me.isNegative=me.isneg=function(){return this.s<0};me.isPositive=me.ispos=function(){return this.s>0};me.isZero=function(){return this.s===0};me.lessThan=me.lt=function(e){return this.cmp(e)<0};me.lessThanOrEqualTo=me.lte=function(e){return this.cmp(e)<1};me.logarithm=me.log=function(e){var t,n=this,r=n.constructor,i=r.precision,o=i+5;if(e===void 0)e=new r(10);else if(e=new r(e),e.s<1||e.eq(Yn))throw Error(br+"NaN");if(n.s<1)throw Error(br+(n.s?"NaN":"-Infinity"));return n.eq(Yn)?new r(0):(At=!1,t=Ra(bu(n,o),bu(e,o),o),At=!0,dt(t,i))};me.minus=me.sub=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?wL(t,e):bL(t,(e.s=-e.s,e))};me.modulo=me.mod=function(e){var t,n=this,r=n.constructor,i=r.precision;if(e=new r(e),!e.s)throw Error(br+"NaN");return n.s?(At=!1,t=Ra(n,e,0,1).times(e),At=!0,n.minus(t)):dt(new r(n),i)};me.naturalExponential=me.exp=function(){return jL(this)};me.naturalLogarithm=me.ln=function(){return bu(this)};me.negated=me.neg=function(){var e=new this.constructor(this);return e.s=-e.s||0,e};me.plus=me.add=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?bL(t,e):wL(t,(e.s=-e.s,e))};me.precision=me.sd=function(e){var t,n,r,i=this;if(e!==void 0&&e!==!!e&&e!==1&&e!==0)throw Error(js+e);if(t=Ut(i)+1,r=i.d.length-1,n=r*jt+1,r=i.d[r],r){for(;r%10==0;r/=10)n--;for(r=i.d[0];r>=10;r/=10)n++}return e&&t>n?t:n};me.squareRoot=me.sqrt=function(){var e,t,n,r,i,o,c,f=this,d=f.constructor;if(f.s<1){if(!f.s)return new d(0);throw Error(br+"NaN")}for(e=Ut(f),At=!1,i=Math.sqrt(+f),i==0||i==1/0?(t=Kr(f.d),(t.length+e)%2==0&&(t+="0"),i=Math.sqrt(t),e=Tl((e+1)/2)-(e<0||e%2),i==1/0?t="5e"+e:(t=i.toExponential(),t=t.slice(0,t.indexOf("e")+1)+e),r=new d(t)):r=new d(i.toString()),n=d.precision,i=c=n+3;;)if(o=r,r=o.plus(Ra(f,o,c+2)).times(.5),Kr(o.d).slice(0,c)===(t=Kr(r.d)).slice(0,c)){if(t=t.slice(c-3,c+1),i==c&&t=="4999"){if(dt(o,n+1,0),o.times(o).eq(f)){r=o;break}}else if(t!="9999")break;c+=4}return At=!0,dt(r,n)};me.times=me.mul=function(e){var t,n,r,i,o,c,f,d,h,p=this,y=p.constructor,x=p.d,j=(e=new y(e)).d;if(!p.s||!e.s)return new y(0);for(e.s*=p.s,n=p.e+e.e,d=x.length,h=j.length,d<h&&(o=x,x=j,j=o,c=d,d=h,h=c),o=[],c=d+h,r=c;r--;)o.push(0);for(r=h;--r>=0;){for(t=0,i=d+r;i>r;)f=o[i]+j[r]*x[i-r-1]+t,o[i--]=f%Jt|0,t=f/Jt|0;o[i]=(o[i]+t)%Jt|0}for(;!o[--c];)o.pop();return t?++n:o.shift(),e.d=o,e.e=n,At?dt(e,y.precision):e};me.toDecimalPlaces=me.todp=function(e,t){var n=this,r=n.constructor;return n=new r(n),e===void 0?n:(ta(e,0,_l),t===void 0?t=r.rounding:ta(t,0,8),dt(n,e+Ut(n)+1,t))};me.toExponential=function(e,t){var n,r=this,i=r.constructor;return e===void 0?n=As(r,!0):(ta(e,0,_l),t===void 0?t=i.rounding:ta(t,0,8),r=dt(new i(r),e+1,t),n=As(r,!0,e+1)),n};me.toFixed=function(e,t){var n,r,i=this,o=i.constructor;return e===void 0?As(i):(ta(e,0,_l),t===void 0?t=o.rounding:ta(t,0,8),r=dt(new o(i),e+Ut(i)+1,t),n=As(r.abs(),!1,e+Ut(r)+1),i.isneg()&&!i.isZero()?"-"+n:n)};me.toInteger=me.toint=function(){var e=this,t=e.constructor;return dt(new t(e),Ut(e)+1,t.rounding)};me.toNumber=function(){return+this};me.toPower=me.pow=function(e){var t,n,r,i,o,c,f=this,d=f.constructor,h=12,p=+(e=new d(e));if(!e.s)return new d(Yn);if(f=new d(f),!f.s){if(e.s<1)throw Error(br+"Infinity");return f}if(f.eq(Yn))return f;if(r=d.precision,e.eq(Yn))return dt(f,r);if(t=e.e,n=e.d.length-1,c=t>=n,o=f.s,c){if((n=p<0?-p:p)<=vL){for(i=new d(Yn),t=Math.ceil(r/jt+4),At=!1;n%2&&(i=i.times(f),VR(i.d,t)),n=Tl(n/2),n!==0;)f=f.times(f),VR(f.d,t);return At=!0,e.s<0?new d(Yn).div(i):dt(i,r)}}else if(o<0)throw Error(br+"NaN");return o=o<0&&e.d[Math.max(t,n)]&1?-1:1,f.s=1,At=!1,i=e.times(bu(f,r+h)),At=!0,i=jL(i),i.s=o,i};me.toPrecision=function(e,t){var n,r,i=this,o=i.constructor;return e===void 0?(n=Ut(i),r=As(i,n<=o.toExpNeg||n>=o.toExpPos)):(ta(e,1,_l),t===void 0?t=o.rounding:ta(t,0,8),i=dt(new o(i),e,t),n=Ut(i),r=As(i,e<=n||n<=o.toExpNeg,e)),r};me.toSignificantDigits=me.tosd=function(e,t){var n=this,r=n.constructor;return e===void 0?(e=r.precision,t=r.rounding):(ta(e,1,_l),t===void 0?t=r.rounding:ta(t,0,8)),dt(new r(n),e,t)};me.toString=me.valueOf=me.val=me.toJSON=me[Symbol.for("nodejs.util.inspect.custom")]=function(){var e=this,t=Ut(e),n=e.constructor;return As(e,t<=n.toExpNeg||t>=n.toExpPos)};function bL(e,t){var n,r,i,o,c,f,d,h,p=e.constructor,y=p.precision;if(!e.s||!t.s)return t.s||(t=new p(e)),At?dt(t,y):t;if(d=e.d,h=t.d,c=e.e,i=t.e,d=d.slice(),o=c-i,o){for(o<0?(r=d,o=-o,f=h.length):(r=h,i=c,f=d.length),c=Math.ceil(y/jt),f=c>f?c+1:f+1,o>f&&(o=f,r.length=1),r.reverse();o--;)r.push(0);r.reverse()}for(f=d.length,o=h.length,f-o<0&&(o=f,r=h,h=d,d=r),n=0;o;)n=(d[--o]=d[o]+h[o]+n)/Jt|0,d[o]%=Jt;for(n&&(d.unshift(n),++i),f=d.length;d[--f]==0;)d.pop();return t.d=d,t.e=i,At?dt(t,y):t}function ta(e,t,n){if(e!==~~e||e<t||e>n)throw Error(js+e)}function Kr(e){var t,n,r,i=e.length-1,o="",c=e[0];if(i>0){for(o+=c,t=1;t<i;t++)r=e[t]+"",n=jt-r.length,n&&(o+=Si(n)),o+=r;c=e[t],r=c+"",n=jt-r.length,n&&(o+=Si(n))}else if(c===0)return"0";for(;c%10===0;)c/=10;return o+c}var Ra=(function(){function e(r,i){var o,c=0,f=r.length;for(r=r.slice();f--;)o=r[f]*i+c,r[f]=o%Jt|0,c=o/Jt|0;return c&&r.unshift(c),r}function t(r,i,o,c){var f,d;if(o!=c)d=o>c?1:-1;else for(f=d=0;f<o;f++)if(r[f]!=i[f]){d=r[f]>i[f]?1:-1;break}return d}function n(r,i,o){for(var c=0;o--;)r[o]-=c,c=r[o]<i[o]?1:0,r[o]=c*Jt+r[o]-i[o];for(;!r[0]&&r.length>1;)r.shift()}return function(r,i,o,c){var f,d,h,p,y,x,j,w,S,b,A,_,O,T,N,E,M,D,R=r.constructor,B=r.s==i.s?1:-1,q=r.d,z=i.d;if(!r.s)return new R(r);if(!i.s)throw Error(br+"Division by zero");for(d=r.e-i.e,M=z.length,N=q.length,j=new R(B),w=j.d=[],h=0;z[h]==(q[h]||0);)++h;if(z[h]>(q[h]||0)&&--d,o==null?_=o=R.precision:c?_=o+(Ut(r)-Ut(i))+1:_=o,_<0)return new R(0);if(_=_/jt+2|0,h=0,M==1)for(p=0,z=z[0],_++;(h<N||p)&&_--;h++)O=p*Jt+(q[h]||0),w[h]=O/z|0,p=O%z|0;else{for(p=Jt/(z[0]+1)|0,p>1&&(z=e(z,p),q=e(q,p),M=z.length,N=q.length),T=M,S=q.slice(0,M),b=S.length;b<M;)S[b++]=0;D=z.slice(),D.unshift(0),E=z[0],z[1]>=Jt/2&&++E;do p=0,f=t(z,S,M,b),f<0?(A=S[0],M!=b&&(A=A*Jt+(S[1]||0)),p=A/E|0,p>1?(p>=Jt&&(p=Jt-1),y=e(z,p),x=y.length,b=S.length,f=t(y,S,x,b),f==1&&(p--,n(y,M<x?D:z,x))):(p==0&&(f=p=1),y=z.slice()),x=y.length,x<b&&y.unshift(0),n(S,y,b),f==-1&&(b=S.length,f=t(z,S,M,b),f<1&&(p++,n(S,M<b?D:z,b))),b=S.length):f===0&&(p++,S=[0]),w[h++]=p,f&&S[0]?S[b++]=q[T]||0:(S=[q[T]],b=1);while((T++<N||S[0]!==void 0)&&_--)}return w[0]||w.shift(),j.e=d,dt(j,c?o+Ut(j)+1:o)}})();function jL(e,t){var n,r,i,o,c,f,d=0,h=0,p=e.constructor,y=p.precision;if(Ut(e)>16)throw Error(GS+Ut(e));if(!e.s)return new p(Yn);for(At=!1,f=y,c=new p(.03125);e.abs().gte(.1);)e=e.times(c),h+=5;for(r=Math.log(ls(2,h))/Math.LN10*2+5|0,f+=r,n=i=o=new p(Yn),p.precision=f;;){if(i=dt(i.times(e),f),n=n.times(++d),c=o.plus(Ra(i,n,f)),Kr(c.d).slice(0,f)===Kr(o.d).slice(0,f)){for(;h--;)o=dt(o.times(o),f);return p.precision=y,t==null?(At=!0,dt(o,y)):o}o=c}}function Ut(e){for(var t=e.e*jt,n=e.d[0];n>=10;n/=10)t++;return t}function M0(e,t,n){if(t>e.LN10.sd())throw At=!0,n&&(e.precision=n),Error(br+"LN10 precision limit exceeded");return dt(new e(e.LN10),t)}function Si(e){for(var t="";e--;)t+="0";return t}function bu(e,t){var n,r,i,o,c,f,d,h,p,y=1,x=10,j=e,w=j.d,S=j.constructor,b=S.precision;if(j.s<1)throw Error(br+(j.s?"NaN":"-Infinity"));if(j.eq(Yn))return new S(0);if(t==null?(At=!1,h=b):h=t,j.eq(10))return t==null&&(At=!0),M0(S,h);if(h+=x,S.precision=h,n=Kr(w),r=n.charAt(0),o=Ut(j),Math.abs(o)<15e14){for(;r<7&&r!=1||r==1&&n.charAt(1)>3;)j=j.times(e),n=Kr(j.d),r=n.charAt(0),y++;o=Ut(j),r>1?(j=new S("0."+n),o++):j=new S(r+"."+n.slice(1))}else return d=M0(S,h+2,b).times(o+""),j=bu(new S(r+"."+n.slice(1)),h-x).plus(d),S.precision=b,t==null?(At=!0,dt(j,b)):j;for(f=c=j=Ra(j.minus(Yn),j.plus(Yn),h),p=dt(j.times(j),h),i=3;;){if(c=dt(c.times(p),h),d=f.plus(Ra(c,new S(i),h)),Kr(d.d).slice(0,h)===Kr(f.d).slice(0,h))return f=f.times(2),o!==0&&(f=f.plus(M0(S,h+2,b).times(o+""))),f=Ra(f,new S(y),h),S.precision=b,t==null?(At=!0,dt(f,b)):f;f=d,i+=2}}function UR(e,t){var n,r,i;for((n=t.indexOf("."))>-1&&(t=t.replace(".","")),(r=t.search(/e/i))>0?(n<0&&(n=r),n+=+t.slice(r+1),t=t.substring(0,r)):n<0&&(n=t.length),r=0;t.charCodeAt(r)===48;)++r;for(i=t.length;t.charCodeAt(i-1)===48;)--i;if(t=t.slice(r,i),t){if(i-=r,n=n-r-1,e.e=Tl(n/jt),e.d=[],r=(n+1)%jt,n<0&&(r+=jt),r<i){for(r&&e.d.push(+t.slice(0,r)),i-=jt;r<i;)e.d.push(+t.slice(r,r+=jt));t=t.slice(r),r=jt-t.length}else r-=i;for(;r--;)t+="0";if(e.d.push(+t),At&&(e.e>Wh||e.e<-Wh))throw Error(GS+n)}else e.s=0,e.e=0,e.d=[0];return e}function dt(e,t,n){var r,i,o,c,f,d,h,p,y=e.d;for(c=1,o=y[0];o>=10;o/=10)c++;if(r=t-c,r<0)r+=jt,i=t,h=y[p=0];else{if(p=Math.ceil((r+1)/jt),o=y.length,p>=o)return e;for(h=o=y[p],c=1;o>=10;o/=10)c++;r%=jt,i=r-jt+c}if(n!==void 0&&(o=ls(10,c-i-1),f=h/o%10|0,d=t<0||y[p+1]!==void 0||h%o,d=n<4?(f||d)&&(n==0||n==(e.s<0?3:2)):f>5||f==5&&(n==4||d||n==6&&(r>0?i>0?h/ls(10,c-i):0:y[p-1])%10&1||n==(e.s<0?8:7))),t<1||!y[0])return d?(o=Ut(e),y.length=1,t=t-o-1,y[0]=ls(10,(jt-t%jt)%jt),e.e=Tl(-t/jt)||0):(y.length=1,y[0]=e.e=e.s=0),e;if(r==0?(y.length=p,o=1,p--):(y.length=p+1,o=ls(10,jt-r),y[p]=i>0?(h/ls(10,c-i)%ls(10,i)|0)*o:0),d)for(;;)if(p==0){(y[0]+=o)==Jt&&(y[0]=1,++e.e);break}else{if(y[p]+=o,y[p]!=Jt)break;y[p--]=0,o=1}for(r=y.length;y[--r]===0;)y.pop();if(At&&(e.e>Wh||e.e<-Wh))throw Error(GS+Ut(e));return e}function wL(e,t){var n,r,i,o,c,f,d,h,p,y,x=e.constructor,j=x.precision;if(!e.s||!t.s)return t.s?t.s=-t.s:t=new x(e),At?dt(t,j):t;if(d=e.d,y=t.d,r=t.e,h=e.e,d=d.slice(),c=h-r,c){for(p=c<0,p?(n=d,c=-c,f=y.length):(n=y,r=h,f=d.length),i=Math.max(Math.ceil(j/jt),f)+2,c>i&&(c=i,n.length=1),n.reverse(),i=c;i--;)n.push(0);n.reverse()}else{for(i=d.length,f=y.length,p=i<f,p&&(f=i),i=0;i<f;i++)if(d[i]!=y[i]){p=d[i]<y[i];break}c=0}for(p&&(n=d,d=y,y=n,t.s=-t.s),f=d.length,i=y.length-f;i>0;--i)d[f++]=0;for(i=y.length;i>c;){if(d[--i]<y[i]){for(o=i;o&&d[--o]===0;)d[o]=Jt-1;--d[o],d[i]+=Jt}d[i]-=y[i]}for(;d[--f]===0;)d.pop();for(;d[0]===0;d.shift())--r;return d[0]?(t.d=d,t.e=r,At?dt(t,j):t):new x(0)}function As(e,t,n){var r,i=Ut(e),o=Kr(e.d),c=o.length;return t?(n&&(r=n-c)>0?o=o.charAt(0)+"."+o.slice(1)+Si(r):c>1&&(o=o.charAt(0)+"."+o.slice(1)),o=o+(i<0?"e":"e+")+i):i<0?(o="0."+Si(-i-1)+o,n&&(r=n-c)>0&&(o+=Si(r))):i>=c?(o+=Si(i+1-c),n&&(r=n-i-1)>0&&(o=o+"."+Si(r))):((r=i+1)<c&&(o=o.slice(0,r)+"."+o.slice(r)),n&&(r=n-c)>0&&(i+1===c&&(o+="."),o+=Si(r))),e.s<0?"-"+o:o}function VR(e,t){if(e.length>t)return e.length=t,!0}function SL(e){var t,n,r;function i(o){var c=this;if(!(c instanceof i))return new i(o);if(c.constructor=i,o instanceof i){c.s=o.s,c.e=o.e,c.d=(o=o.d)?o.slice():o;return}if(typeof o=="number"){if(o*0!==0)throw Error(js+o);if(o>0)c.s=1;else if(o<0)o=-o,c.s=-1;else{c.s=0,c.e=0,c.d=[0];return}if(o===~~o&&o<1e7){c.e=0,c.d=[o];return}return UR(c,o.toString())}else if(typeof o!="string")throw Error(js+o);if(o.charCodeAt(0)===45?(o=o.slice(1),c.s=-1):c.s=1,GJ.test(o))UR(c,o);else throw Error(js+o)}if(i.prototype=me,i.ROUND_UP=0,i.ROUND_DOWN=1,i.ROUND_CEIL=2,i.ROUND_FLOOR=3,i.ROUND_HALF_UP=4,i.ROUND_HALF_DOWN=5,i.ROUND_HALF_EVEN=6,i.ROUND_HALF_CEIL=7,i.ROUND_HALF_FLOOR=8,i.clone=SL,i.config=i.set=KJ,e===void 0&&(e={}),e)for(r=["precision","rounding","toExpNeg","toExpPos","LN10"],t=0;t<r.length;)e.hasOwnProperty(n=r[t++])||(e[n]=this[n]);return i.config(e),i}function KJ(e){if(!e||typeof e!="object")throw Error(br+"Object expected");var t,n,r,i=["precision",1,_l,"rounding",0,8,"toExpNeg",-1/0,0,"toExpPos",0,1/0];for(t=0;t<i.length;t+=3)if((r=e[n=i[t]])!==void 0)if(Tl(r)===r&&r>=i[t+1]&&r<=i[t+2])this[n]=r;else throw Error(js+n+": "+r);if((r=e[n="LN10"])!==void 0)if(r==Math.LN10)this[n]=new this(r);else throw Error(js+n+": "+r);return this}var KS=SL(FJ);Yn=new KS(1);const lt=KS;function YJ(e){return QJ(e)||ZJ(e)||WJ(e)||XJ()}function XJ(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function WJ(e,t){if(e){if(typeof e=="string")return vj(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return vj(e,t)}}function ZJ(e){if(typeof Symbol<"u"&&Symbol.iterator in Object(e))return Array.from(e)}function QJ(e){if(Array.isArray(e))return vj(e)}function vj(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var JJ=function(t){return t},NL={},AL=function(t){return t===NL},HR=function(t){return function n(){return arguments.length===0||arguments.length===1&&AL(arguments.length<=0?void 0:arguments[0])?n:t.apply(void 0,arguments)}},eee=function e(t,n){return t===1?n:HR(function(){for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];var c=i.filter(function(f){return f!==NL}).length;return c>=t?n.apply(void 0,i):e(t-c,HR(function(){for(var f=arguments.length,d=new Array(f),h=0;h<f;h++)d[h]=arguments[h];var p=i.map(function(y){return AL(y)?d.shift():y});return n.apply(void 0,YJ(p).concat(d))}))})},op=function(t){return eee(t.length,t)},bj=function(t,n){for(var r=[],i=t;i<n;++i)r[i-t]=i;return r},tee=op(function(e,t){return Array.isArray(t)?t.map(e):Object.keys(t).map(function(n){return t[n]}).map(e)}),nee=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];if(!n.length)return JJ;var i=n.reverse(),o=i[0],c=i.slice(1);return function(){return c.reduce(function(f,d){return d(f)},o.apply(void 0,arguments))}},jj=function(t){return Array.isArray(t)?t.reverse():t.split("").reverse.join("")},OL=function(t){var n=null,r=null;return function(){for(var i=arguments.length,o=new Array(i),c=0;c<i;c++)o[c]=arguments[c];return n&&o.every(function(f,d){return f===n[d]})||(n=o,r=t.apply(void 0,o)),r}};function ree(e){var t;return e===0?t=1:t=Math.floor(new lt(e).abs().log(10).toNumber())+1,t}function aee(e,t,n){for(var r=new lt(e),i=0,o=[];r.lt(t)&&i<1e5;)o.push(r.toNumber()),r=r.add(n),i++;return o}var iee=op(function(e,t,n){var r=+e,i=+t;return r+n*(i-r)}),see=op(function(e,t,n){var r=t-+e;return r=r||1/0,(n-e)/r}),oee=op(function(e,t,n){var r=t-+e;return r=r||1/0,Math.max(0,Math.min(1,(n-e)/r))});const lp={rangeStep:aee,getDigitCount:ree,interpolateNumber:iee,uninterpolateNumber:see,uninterpolateTruncation:oee};function wj(e){return uee(e)||cee(e)||_L(e)||lee()}function lee(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function cee(e){if(typeof Symbol<"u"&&Symbol.iterator in Object(e))return Array.from(e)}function uee(e){if(Array.isArray(e))return Sj(e)}function ju(e,t){return hee(e)||dee(e,t)||_L(e,t)||fee()}function fee(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function _L(e,t){if(e){if(typeof e=="string")return Sj(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Sj(e,t)}}function Sj(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function dee(e,t){if(!(typeof Symbol>"u"||!(Symbol.iterator in Object(e)))){var n=[],r=!0,i=!1,o=void 0;try{for(var c=e[Symbol.iterator](),f;!(r=(f=c.next()).done)&&(n.push(f.value),!(t&&n.length===t));r=!0);}catch(d){i=!0,o=d}finally{try{!r&&c.return!=null&&c.return()}finally{if(i)throw o}}return n}}function hee(e){if(Array.isArray(e))return e}function TL(e){var t=ju(e,2),n=t[0],r=t[1],i=n,o=r;return n>r&&(i=r,o=n),[i,o]}function EL(e,t,n){if(e.lte(0))return new lt(0);var r=lp.getDigitCount(e.toNumber()),i=new lt(10).pow(r),o=e.div(i),c=r!==1?.05:.1,f=new lt(Math.ceil(o.div(c).toNumber())).add(n).mul(c),d=f.mul(i);return t?d:new lt(Math.ceil(d))}function mee(e,t,n){var r=1,i=new lt(e);if(!i.isint()&&n){var o=Math.abs(e);o<1?(r=new lt(10).pow(lp.getDigitCount(e)-1),i=new lt(Math.floor(i.div(r).toNumber())).mul(r)):o>1&&(i=new lt(Math.floor(e)))}else e===0?i=new lt(Math.floor((t-1)/2)):n||(i=new lt(Math.floor(e)));var c=Math.floor((t-1)/2),f=nee(tee(function(d){return i.add(new lt(d-c).mul(r)).toNumber()}),bj);return f(0,t)}function CL(e,t,n,r){var i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:0;if(!Number.isFinite((t-e)/(n-1)))return{step:new lt(0),tickMin:new lt(0),tickMax:new lt(0)};var o=EL(new lt(t).sub(e).div(n-1),r,i),c;e<=0&&t>=0?c=new lt(0):(c=new lt(e).add(t).div(2),c=c.sub(new lt(c).mod(o)));var f=Math.ceil(c.sub(e).div(o).toNumber()),d=Math.ceil(new lt(t).sub(c).div(o).toNumber()),h=f+d+1;return h>n?CL(e,t,n,r,i+1):(h<n&&(d=t>0?d+(n-h):d,f=t>0?f:f+(n-h)),{step:o,tickMin:c.sub(new lt(f).mul(o)),tickMax:c.add(new lt(d).mul(o))})}function pee(e){var t=ju(e,2),n=t[0],r=t[1],i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:6,o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,c=Math.max(i,2),f=TL([n,r]),d=ju(f,2),h=d[0],p=d[1];if(h===-1/0||p===1/0){var y=p===1/0?[h].concat(wj(bj(0,i-1).map(function(){return 1/0}))):[].concat(wj(bj(0,i-1).map(function(){return-1/0})),[p]);return n>r?jj(y):y}if(h===p)return mee(h,i,o);var x=CL(h,p,c,o),j=x.step,w=x.tickMin,S=x.tickMax,b=lp.rangeStep(w,S.add(new lt(.1).mul(j)),j);return n>r?jj(b):b}function yee(e,t){var n=ju(e,2),r=n[0],i=n[1],o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,c=TL([r,i]),f=ju(c,2),d=f[0],h=f[1];if(d===-1/0||h===1/0)return[r,i];if(d===h)return[d];var p=Math.max(t,2),y=EL(new lt(h).sub(d).div(p-1),o,0),x=[].concat(wj(lp.rangeStep(new lt(d),new lt(h).sub(new lt(.99).mul(y)),y)),[h]);return r>i?jj(x):x}var xee=OL(pee),gee=OL(yee),vee="Invariant failed";function Os(e,t){throw new Error(vee)}var bee=["offset","layout","width","dataKey","data","dataPointFormatter","xAxis","yAxis"];function Wo(e){"@babel/helpers - typeof";return Wo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Wo(e)}function Zh(){return Zh=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Zh.apply(this,arguments)}function jee(e,t){return Aee(e)||Nee(e,t)||See(e,t)||wee()}function wee(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function See(e,t){if(e){if(typeof e=="string")return FR(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return FR(e,t)}}function FR(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Nee(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,c,f=[],d=!0,h=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(d=(r=o.call(n)).done)&&(f.push(r.value),f.length!==t);d=!0);}catch(p){h=!0,i=p}finally{try{if(!d&&n.return!=null&&(c=n.return(),Object(c)!==c))return}finally{if(h)throw i}}return f}}function Aee(e){if(Array.isArray(e))return e}function Oee(e,t){if(e==null)return{};var n=_ee(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function _ee(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function Tee(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Eee(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,RL(r.key),r)}}function Cee(e,t,n){return t&&Eee(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Mee(e,t,n){return t=Qh(t),Pee(e,ML()?Reflect.construct(t,n||[],Qh(e).constructor):t.apply(e,n))}function Pee(e,t){if(t&&(Wo(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Ree(e)}function Ree(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function ML(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(ML=function(){return!!e})()}function Qh(e){return Qh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Qh(e)}function kee(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Nj(e,t)}function Nj(e,t){return Nj=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},Nj(e,t)}function PL(e,t,n){return t=RL(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function RL(e){var t=Dee(e,"string");return Wo(t)=="symbol"?t:t+""}function Dee(e,t){if(Wo(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Wo(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var sf=(function(e){function t(){return Tee(this,t),Mee(this,t,arguments)}return kee(t,e),Cee(t,[{key:"render",value:function(){var r=this.props,i=r.offset,o=r.layout,c=r.width,f=r.dataKey,d=r.data,h=r.dataPointFormatter,p=r.xAxis,y=r.yAxis,x=Oee(r,bee),j=Ne(x,!1);this.props.direction==="x"&&p.type!=="number"&&Os();var w=d.map(function(S){var b=h(S,f),A=b.x,_=b.y,O=b.value,T=b.errorVal;if(!T)return null;var N=[],E,M;if(Array.isArray(T)){var D=jee(T,2);E=D[0],M=D[1]}else E=M=T;if(o==="vertical"){var R=p.scale,B=_+i,q=B+c,z=B-c,H=R(O-E),X=R(O+M);N.push({x1:X,y1:q,x2:X,y2:z}),N.push({x1:H,y1:B,x2:X,y2:B}),N.push({x1:H,y1:q,x2:H,y2:z})}else if(o==="horizontal"){var Y=y.scale,$=A+i,G=$-c,Q=$+c,ie=Y(O-E),le=Y(O+M);N.push({x1:G,y1:le,x2:Q,y2:le}),N.push({x1:$,y1:ie,x2:$,y2:le}),N.push({x1:G,y1:ie,x2:Q,y2:ie})}return U.createElement(Xe,Zh({className:"recharts-errorBar",key:"bar-".concat(N.map(function(L){return"".concat(L.x1,"-").concat(L.x2,"-").concat(L.y1,"-").concat(L.y2)}))},j),N.map(function(L){return U.createElement("line",Zh({},L,{key:"line-".concat(L.x1,"-").concat(L.x2,"-").concat(L.y1,"-").concat(L.y2)}))}))});return U.createElement(Xe,{className:"recharts-errorBars"},w)}}])})(U.Component);PL(sf,"defaultProps",{stroke:"black",strokeWidth:1.5,width:5,offset:0,layout:"horizontal"});PL(sf,"displayName","ErrorBar");function wu(e){"@babel/helpers - typeof";return wu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},wu(e)}function GR(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function rs(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?GR(Object(n),!0).forEach(function(r){zee(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):GR(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function zee(e,t,n){return t=Lee(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Lee(e){var t=$ee(e,"string");return wu(t)=="symbol"?t:t+""}function $ee(e,t){if(wu(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(wu(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var kL=function(t){var n=t.children,r=t.formattedGraphicalItems,i=t.legendWidth,o=t.legendContent,c=Fn(n,Lo);if(!c)return null;var f=Lo.defaultProps,d=f!==void 0?rs(rs({},f),c.props):{},h;return c.props&&c.props.payload?h=c.props&&c.props.payload:o==="children"?h=(r||[]).reduce(function(p,y){var x=y.item,j=y.props,w=j.sectors||j.data||[];return p.concat(w.map(function(S){return{type:c.props.iconType||x.props.legendType,value:S.name,color:S.fill,payload:S}}))},[]):h=(r||[]).map(function(p){var y=p.item,x=y.type.defaultProps,j=x!==void 0?rs(rs({},x),y.props):{},w=j.dataKey,S=j.name,b=j.legendType,A=j.hide;return{inactive:A,dataKey:w,type:d.iconType||b||"square",color:YS(y),value:S||w,payload:j}}),rs(rs(rs({},d),Lo.getWithHeight(c,i)),{},{payload:h,item:c})};function Su(e){"@babel/helpers - typeof";return Su=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Su(e)}function KR(e){return Uee(e)||Iee(e)||qee(e)||Bee()}function Bee(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function qee(e,t){if(e){if(typeof e=="string")return Aj(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Aj(e,t)}}function Iee(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Uee(e){if(Array.isArray(e))return Aj(e)}function Aj(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function YR(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Pt(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?YR(Object(n),!0).forEach(function(r){Bo(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):YR(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Bo(e,t,n){return t=Vee(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Vee(e){var t=Hee(e,"string");return Su(t)=="symbol"?t:t+""}function Hee(e,t){if(Su(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Su(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Kt(e,t,n){return Re(e)||Re(t)?n:Xt(t)?Zn(e,t,n):Ce(t)?t(e):n}function Zc(e,t,n,r){var i=UJ(e,function(f){return Kt(f,t)});if(n==="number"){var o=i.filter(function(f){return de(f)||parseFloat(f)});return o.length?[sp(o),ip(o)]:[1/0,-1/0]}var c=r?i.filter(function(f){return!Re(f)}):i;return c.map(function(f){return Xt(f)||f instanceof Date?f:""})}var Fee=function(t){var n,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],i=arguments.length>2?arguments[2]:void 0,o=arguments.length>3?arguments[3]:void 0,c=-1,f=(n=r==null?void 0:r.length)!==null&&n!==void 0?n:0;if(f<=1)return 0;if(o&&o.axisType==="angleAxis"&&Math.abs(Math.abs(o.range[1]-o.range[0])-360)<=1e-6)for(var d=o.range,h=0;h<f;h++){var p=h>0?i[h-1].coordinate:i[f-1].coordinate,y=i[h].coordinate,x=h>=f-1?i[0].coordinate:i[h+1].coordinate,j=void 0;if(bn(y-p)!==bn(x-y)){var w=[];if(bn(x-y)===bn(d[1]-d[0])){j=x;var S=y+d[1]-d[0];w[0]=Math.min(S,(S+p)/2),w[1]=Math.max(S,(S+p)/2)}else{j=p;var b=x+d[1]-d[0];w[0]=Math.min(y,(b+y)/2),w[1]=Math.max(y,(b+y)/2)}var A=[Math.min(y,(j+y)/2),Math.max(y,(j+y)/2)];if(t>A[0]&&t<=A[1]||t>=w[0]&&t<=w[1]){c=i[h].index;break}}else{var _=Math.min(p,x),O=Math.max(p,x);if(t>(_+y)/2&&t<=(O+y)/2){c=i[h].index;break}}}else for(var T=0;T<f;T++)if(T===0&&t<=(r[T].coordinate+r[T+1].coordinate)/2||T>0&&T<f-1&&t>(r[T].coordinate+r[T-1].coordinate)/2&&t<=(r[T].coordinate+r[T+1].coordinate)/2||T===f-1&&t>(r[T].coordinate+r[T-1].coordinate)/2){c=r[T].index;break}return c},YS=function(t){var n,r=t,i=r.type.displayName,o=(n=t.type)!==null&&n!==void 0&&n.defaultProps?Pt(Pt({},t.type.defaultProps),t.props):t.props,c=o.stroke,f=o.fill,d;switch(i){case"Line":d=c;break;case"Area":case"Radar":d=c&&c!=="none"?c:f;break;default:d=f;break}return d},Gee=function(t){var n=t.barSize,r=t.totalSize,i=t.stackGroups,o=i===void 0?{}:i;if(!o)return{};for(var c={},f=Object.keys(o),d=0,h=f.length;d<h;d++)for(var p=o[f[d]].stackGroups,y=Object.keys(p),x=0,j=y.length;x<j;x++){var w=p[y[x]],S=w.items,b=w.cateAxisId,A=S.filter(function(M){return Pa(M.type).indexOf("Bar")>=0});if(A&&A.length){var _=A[0].type.defaultProps,O=_!==void 0?Pt(Pt({},_),A[0].props):A[0].props,T=O.barSize,N=O[b];c[N]||(c[N]=[]);var E=Re(T)?n:T;c[N].push({item:A[0],stackList:A.slice(1),barSize:Re(E)?void 0:jn(E,r,0)})}}return c},Kee=function(t){var n=t.barGap,r=t.barCategoryGap,i=t.bandSize,o=t.sizeList,c=o===void 0?[]:o,f=t.maxBarSize,d=c.length;if(d<1)return null;var h=jn(n,i,0,!0),p,y=[];if(c[0].barSize===+c[0].barSize){var x=!1,j=i/d,w=c.reduce(function(T,N){return T+N.barSize||0},0);w+=(d-1)*h,w>=i&&(w-=(d-1)*h,h=0),w>=i&&j>0&&(x=!0,j*=.9,w=d*j);var S=(i-w)/2>>0,b={offset:S-h,size:0};p=c.reduce(function(T,N){var E={item:N.item,position:{offset:b.offset+b.size+h,size:x?j:N.barSize}},M=[].concat(KR(T),[E]);return b=M[M.length-1].position,N.stackList&&N.stackList.length&&N.stackList.forEach(function(D){M.push({item:D,position:b})}),M},y)}else{var A=jn(r,i,0,!0);i-2*A-(d-1)*h<=0&&(h=0);var _=(i-2*A-(d-1)*h)/d;_>1&&(_>>=0);var O=f===+f?Math.min(_,f):_;p=c.reduce(function(T,N,E){var M=[].concat(KR(T),[{item:N.item,position:{offset:A+(_+h)*E+(_-O)/2,size:O}}]);return N.stackList&&N.stackList.length&&N.stackList.forEach(function(D){M.push({item:D,position:M[M.length-1].position})}),M},y)}return p},Yee=function(t,n,r,i){var o=r.children,c=r.width,f=r.margin,d=c-(f.left||0)-(f.right||0),h=kL({children:o,legendWidth:d});if(h){var p=i||{},y=p.width,x=p.height,j=h.align,w=h.verticalAlign,S=h.layout;if((S==="vertical"||S==="horizontal"&&w==="middle")&&j!=="center"&&de(t[j]))return Pt(Pt({},t),{},Bo({},j,t[j]+(y||0)));if((S==="horizontal"||S==="vertical"&&j==="center")&&w!=="middle"&&de(t[w]))return Pt(Pt({},t),{},Bo({},w,t[w]+(x||0)))}return t},Xee=function(t,n,r){return Re(n)?!0:t==="horizontal"?n==="yAxis":t==="vertical"||r==="x"?n==="xAxis":r==="y"?n==="yAxis":!0},DL=function(t,n,r,i,o){var c=n.props.children,f=Qn(c,sf).filter(function(h){return Xee(i,o,h.props.direction)});if(f&&f.length){var d=f.map(function(h){return h.props.dataKey});return t.reduce(function(h,p){var y=Kt(p,r);if(Re(y))return h;var x=Array.isArray(y)?[sp(y),ip(y)]:[y,y],j=d.reduce(function(w,S){var b=Kt(p,S,0),A=x[0]-Math.abs(Array.isArray(b)?b[0]:b),_=x[1]+Math.abs(Array.isArray(b)?b[1]:b);return[Math.min(A,w[0]),Math.max(_,w[1])]},[1/0,-1/0]);return[Math.min(j[0],h[0]),Math.max(j[1],h[1])]},[1/0,-1/0])}return null},Wee=function(t,n,r,i,o){var c=n.map(function(f){return DL(t,f,r,o,i)}).filter(function(f){return!Re(f)});return c&&c.length?c.reduce(function(f,d){return[Math.min(f[0],d[0]),Math.max(f[1],d[1])]},[1/0,-1/0]):null},zL=function(t,n,r,i,o){var c=n.map(function(d){var h=d.props.dataKey;return r==="number"&&h&&DL(t,d,h,i)||Zc(t,h,r,o)});if(r==="number")return c.reduce(function(d,h){return[Math.min(d[0],h[0]),Math.max(d[1],h[1])]},[1/0,-1/0]);var f={};return c.reduce(function(d,h){for(var p=0,y=h.length;p<y;p++)f[h[p]]||(f[h[p]]=!0,d.push(h[p]));return d},[])},LL=function(t,n){return t==="horizontal"&&n==="xAxis"||t==="vertical"&&n==="yAxis"||t==="centric"&&n==="angleAxis"||t==="radial"&&n==="radiusAxis"},$L=function(t,n,r,i){if(i)return t.map(function(d){return d.coordinate});var o,c,f=t.map(function(d){return d.coordinate===n&&(o=!0),d.coordinate===r&&(c=!0),d.coordinate});return o||f.push(n),c||f.push(r),f},Ca=function(t,n,r){if(!t)return null;var i=t.scale,o=t.duplicateDomain,c=t.type,f=t.range,d=t.realScaleType==="scaleBand"?i.bandwidth()/2:2,h=(n||r)&&c==="category"&&i.bandwidth?i.bandwidth()/d:0;if(h=t.axisType==="angleAxis"&&(f==null?void 0:f.length)>=2?bn(f[0]-f[1])*2*h:h,n&&(t.ticks||t.niceTicks)){var p=(t.ticks||t.niceTicks).map(function(y){var x=o?o.indexOf(y):y;return{coordinate:i(x)+h,value:y,offset:h}});return p.filter(function(y){return!Qu(y.coordinate)})}return t.isCategorical&&t.categoricalDomain?t.categoricalDomain.map(function(y,x){return{coordinate:i(y)+h,value:y,index:x,offset:h}}):i.ticks&&!r?i.ticks(t.tickCount).map(function(y){return{coordinate:i(y)+h,value:y,offset:h}}):i.domain().map(function(y,x){return{coordinate:i(y)+h,value:o?o[y]:y,index:x,offset:h}})},P0=new WeakMap,Yd=function(t,n){if(typeof n!="function")return t;P0.has(t)||P0.set(t,new WeakMap);var r=P0.get(t);if(r.has(n))return r.get(n);var i=function(){t.apply(void 0,arguments),n.apply(void 0,arguments)};return r.set(n,i),i},BL=function(t,n,r){var i=t.scale,o=t.type,c=t.layout,f=t.axisType;if(i==="auto")return c==="radial"&&f==="radiusAxis"?{scale:pu(),realScaleType:"band"}:c==="radial"&&f==="angleAxis"?{scale:Gh(),realScaleType:"linear"}:o==="category"&&n&&(n.indexOf("LineChart")>=0||n.indexOf("AreaChart")>=0||n.indexOf("ComposedChart")>=0&&!r)?{scale:Wc(),realScaleType:"point"}:o==="category"?{scale:pu(),realScaleType:"band"}:{scale:Gh(),realScaleType:"linear"};if(ws(i)){var d="scale".concat(Hm(i));return{scale:(RR[d]||Wc)(),realScaleType:RR[d]?d:"point"}}return Ce(i)?{scale:i}:{scale:Wc(),realScaleType:"point"}},XR=1e-4,qL=function(t){var n=t.domain();if(!(!n||n.length<=2)){var r=n.length,i=t.range(),o=Math.min(i[0],i[1])-XR,c=Math.max(i[0],i[1])+XR,f=t(n[0]),d=t(n[r-1]);(f<o||f>c||d<o||d>c)&&t.domain([n[0],n[r-1]])}},Zee=function(t,n){if(!t)return null;for(var r=0,i=t.length;r<i;r++)if(t[r].item===n)return t[r].position;return null},Qee=function(t,n){if(!n||n.length!==2||!de(n[0])||!de(n[1]))return t;var r=Math.min(n[0],n[1]),i=Math.max(n[0],n[1]),o=[t[0],t[1]];return(!de(t[0])||t[0]<r)&&(o[0]=r),(!de(t[1])||t[1]>i)&&(o[1]=i),o[0]>i&&(o[0]=i),o[1]<r&&(o[1]=r),o},Jee=function(t){var n=t.length;if(!(n<=0))for(var r=0,i=t[0].length;r<i;++r)for(var o=0,c=0,f=0;f<n;++f){var d=Qu(t[f][r][1])?t[f][r][0]:t[f][r][1];d>=0?(t[f][r][0]=o,t[f][r][1]=o+d,o=t[f][r][1]):(t[f][r][0]=c,t[f][r][1]=c+d,c=t[f][r][1])}},ete=function(t){var n=t.length;if(!(n<=0))for(var r=0,i=t[0].length;r<i;++r)for(var o=0,c=0;c<n;++c){var f=Qu(t[c][r][1])?t[c][r][0]:t[c][r][1];f>=0?(t[c][r][0]=o,t[c][r][1]=o+f,o=t[c][r][1]):(t[c][r][0]=0,t[c][r][1]=0)}},tte={sign:Jee,expand:UK,none:Uo,silhouette:VK,wiggle:HK,positive:ete},nte=function(t,n,r){var i=n.map(function(f){return f.props.dataKey}),o=tte[r],c=IK().keys(i).value(function(f,d){return+Kt(f,d,0)}).order(ej).offset(o);return c(t)},rte=function(t,n,r,i,o,c){if(!t)return null;var f=c?n.reverse():n,d={},h=f.reduce(function(y,x){var j,w=(j=x.type)!==null&&j!==void 0&&j.defaultProps?Pt(Pt({},x.type.defaultProps),x.props):x.props,S=w.stackId,b=w.hide;if(b)return y;var A=w[r],_=y[A]||{hasStack:!1,stackGroups:{}};if(Xt(S)){var O=_.stackGroups[S]||{numericAxisId:r,cateAxisId:i,items:[]};O.items.push(x),_.hasStack=!0,_.stackGroups[S]=O}else _.stackGroups[Nl("_stackId_")]={numericAxisId:r,cateAxisId:i,items:[x]};return Pt(Pt({},y),{},Bo({},A,_))},d),p={};return Object.keys(h).reduce(function(y,x){var j=h[x];if(j.hasStack){var w={};j.stackGroups=Object.keys(j.stackGroups).reduce(function(S,b){var A=j.stackGroups[b];return Pt(Pt({},S),{},Bo({},b,{numericAxisId:r,cateAxisId:i,items:A.items,stackedData:nte(t,A.items,o)}))},w)}return Pt(Pt({},y),{},Bo({},x,j))},p)},IL=function(t,n){var r=n.realScaleType,i=n.type,o=n.tickCount,c=n.originalDomain,f=n.allowDecimals,d=r||n.scale;if(d!=="auto"&&d!=="linear")return null;if(o&&i==="number"&&c&&(c[0]==="auto"||c[1]==="auto")){var h=t.domain();if(!h.length)return null;var p=xee(h,o,f);return t.domain([sp(p),ip(p)]),{niceTicks:p}}if(o&&i==="number"){var y=t.domain(),x=gee(y,o,f);return{niceTicks:x}}return null};function WR(e){var t=e.axis,n=e.ticks,r=e.bandSize,i=e.entry,o=e.index,c=e.dataKey;if(t.type==="category"){if(!t.allowDuplicatedCategory&&t.dataKey&&!Re(i[t.dataKey])){var f=_h(n,"value",i[t.dataKey]);if(f)return f.coordinate+r/2}return n[o]?n[o].coordinate+r/2:null}var d=Kt(i,Re(c)?t.dataKey:c);return Re(d)?null:t.scale(d)}var ZR=function(t){var n=t.axis,r=t.ticks,i=t.offset,o=t.bandSize,c=t.entry,f=t.index;if(n.type==="category")return r[f]?r[f].coordinate+i:null;var d=Kt(c,n.dataKey,n.domain[f]);return Re(d)?null:n.scale(d)-o/2+i},ate=function(t){var n=t.numericAxis,r=n.scale.domain();if(n.type==="number"){var i=Math.min(r[0],r[1]),o=Math.max(r[0],r[1]);return i<=0&&o>=0?0:o<0?o:i}return r[0]},ite=function(t,n){var r,i=(r=t.type)!==null&&r!==void 0&&r.defaultProps?Pt(Pt({},t.type.defaultProps),t.props):t.props,o=i.stackId;if(Xt(o)){var c=n[o];if(c){var f=c.items.indexOf(t);return f>=0?c.stackedData[f]:null}}return null},ste=function(t){return t.reduce(function(n,r){return[sp(r.concat([n[0]]).filter(de)),ip(r.concat([n[1]]).filter(de))]},[1/0,-1/0])},UL=function(t,n,r){return Object.keys(t).reduce(function(i,o){var c=t[o],f=c.stackedData,d=f.reduce(function(h,p){var y=ste(p.slice(n,r+1));return[Math.min(h[0],y[0]),Math.max(h[1],y[1])]},[1/0,-1/0]);return[Math.min(d[0],i[0]),Math.max(d[1],i[1])]},[1/0,-1/0]).map(function(i){return i===1/0||i===-1/0?0:i})},QR=/^dataMin[\s]*-[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,JR=/^dataMax[\s]*\+[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,Oj=function(t,n,r){if(Ce(t))return t(n,r);if(!Array.isArray(t))return n;var i=[];if(de(t[0]))i[0]=r?t[0]:Math.min(t[0],n[0]);else if(QR.test(t[0])){var o=+QR.exec(t[0])[1];i[0]=n[0]-o}else Ce(t[0])?i[0]=t[0](n[0]):i[0]=n[0];if(de(t[1]))i[1]=r?t[1]:Math.max(t[1],n[1]);else if(JR.test(t[1])){var c=+JR.exec(t[1])[1];i[1]=n[1]+c}else Ce(t[1])?i[1]=t[1](n[1]):i[1]=n[1];return i},Jh=function(t,n,r){if(t&&t.scale&&t.scale.bandwidth){var i=t.scale.bandwidth();if(!r||i>0)return i}if(t&&n&&n.length>=2){for(var o=wS(n,function(y){return y.coordinate}),c=1/0,f=1,d=o.length;f<d;f++){var h=o[f],p=o[f-1];c=Math.min((h.coordinate||0)-(p.coordinate||0),c)}return c===1/0?0:c}return r?void 0:0},ek=function(t,n,r){return!t||!t.length||af(t,Zn(r,"type.defaultProps.domain"))?n:t},VL=function(t,n){var r=t.type.defaultProps?Pt(Pt({},t.type.defaultProps),t.props):t.props,i=r.dataKey,o=r.name,c=r.unit,f=r.formatter,d=r.tooltipType,h=r.chartType,p=r.hide;return Pt(Pt({},Ne(t,!1)),{},{dataKey:i,unit:c,formatter:f,name:o||i,color:YS(t),value:Kt(n,i),type:d,payload:n,chartType:h,hide:p})};function Nu(e){"@babel/helpers - typeof";return Nu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Nu(e)}function tk(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function _a(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?tk(Object(n),!0).forEach(function(r){HL(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):tk(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function HL(e,t,n){return t=ote(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ote(e){var t=lte(e,"string");return Nu(t)=="symbol"?t:t+""}function lte(e,t){if(Nu(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Nu(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function cte(e,t){return hte(e)||dte(e,t)||fte(e,t)||ute()}function ute(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function fte(e,t){if(e){if(typeof e=="string")return nk(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return nk(e,t)}}function nk(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function dte(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,c,f=[],d=!0,h=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(d=(r=o.call(n)).done)&&(f.push(r.value),f.length!==t);d=!0);}catch(p){h=!0,i=p}finally{try{if(!d&&n.return!=null&&(c=n.return(),Object(c)!==c))return}finally{if(h)throw i}}return f}}function hte(e){if(Array.isArray(e))return e}var em=Math.PI/180,mte=function(t){return t*180/Math.PI},yt=function(t,n,r,i){return{x:t+Math.cos(-em*i)*r,y:n+Math.sin(-em*i)*r}},FL=function(t,n){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{top:0,right:0,bottom:0,left:0};return Math.min(Math.abs(t-(r.left||0)-(r.right||0)),Math.abs(n-(r.top||0)-(r.bottom||0)))/2},pte=function(t,n,r,i,o){var c=t.width,f=t.height,d=t.startAngle,h=t.endAngle,p=jn(t.cx,c,c/2),y=jn(t.cy,f,f/2),x=FL(c,f,r),j=jn(t.innerRadius,x,0),w=jn(t.outerRadius,x,x*.8),S=Object.keys(n);return S.reduce(function(b,A){var _=n[A],O=_.domain,T=_.reversed,N;if(Re(_.range))i==="angleAxis"?N=[d,h]:i==="radiusAxis"&&(N=[j,w]),T&&(N=[N[1],N[0]]);else{N=_.range;var E=N,M=cte(E,2);d=M[0],h=M[1]}var D=BL(_,o),R=D.realScaleType,B=D.scale;B.domain(O).range(N),qL(B);var q=IL(B,_a(_a({},_),{},{realScaleType:R})),z=_a(_a(_a({},_),q),{},{range:N,radius:w,realScaleType:R,scale:B,cx:p,cy:y,innerRadius:j,outerRadius:w,startAngle:d,endAngle:h});return _a(_a({},b),{},HL({},A,z))},{})},yte=function(t,n){var r=t.x,i=t.y,o=n.x,c=n.y;return Math.sqrt(Math.pow(r-o,2)+Math.pow(i-c,2))},xte=function(t,n){var r=t.x,i=t.y,o=n.cx,c=n.cy,f=yte({x:r,y:i},{x:o,y:c});if(f<=0)return{radius:f};var d=(r-o)/f,h=Math.acos(d);return i>c&&(h=2*Math.PI-h),{radius:f,angle:mte(h),angleInRadian:h}},gte=function(t){var n=t.startAngle,r=t.endAngle,i=Math.floor(n/360),o=Math.floor(r/360),c=Math.min(i,o);return{startAngle:n-c*360,endAngle:r-c*360}},vte=function(t,n){var r=n.startAngle,i=n.endAngle,o=Math.floor(r/360),c=Math.floor(i/360),f=Math.min(o,c);return t+f*360},rk=function(t,n){var r=t.x,i=t.y,o=xte({x:r,y:i},n),c=o.radius,f=o.angle,d=n.innerRadius,h=n.outerRadius;if(c<d||c>h)return!1;if(c===0)return!0;var p=gte(n),y=p.startAngle,x=p.endAngle,j=f,w;if(y<=x){for(;j>x;)j-=360;for(;j<y;)j+=360;w=j>=y&&j<=x}else{for(;j>y;)j-=360;for(;j<x;)j+=360;w=j>=x&&j<=y}return w?_a(_a({},n),{},{radius:c,angle:vte(j,n)}):null},GL=function(t){return!P.isValidElement(t)&&!Ce(t)&&typeof t!="boolean"?t.className:""};function Au(e){"@babel/helpers - typeof";return Au=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Au(e)}var bte=["offset"];function jte(e){return Ate(e)||Nte(e)||Ste(e)||wte()}function wte(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Ste(e,t){if(e){if(typeof e=="string")return _j(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return _j(e,t)}}function Nte(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Ate(e){if(Array.isArray(e))return _j(e)}function _j(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Ote(e,t){if(e==null)return{};var n=_te(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function _te(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function ak(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Ft(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?ak(Object(n),!0).forEach(function(r){Tte(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ak(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Tte(e,t,n){return t=Ete(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ete(e){var t=Cte(e,"string");return Au(t)=="symbol"?t:t+""}function Cte(e,t){if(Au(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Au(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Ou(){return Ou=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ou.apply(this,arguments)}var Mte=function(t){var n=t.value,r=t.formatter,i=Re(t.children)?n:t.children;return Ce(r)?r(i):i},Pte=function(t,n){var r=bn(n-t),i=Math.min(Math.abs(n-t),360);return r*i},Rte=function(t,n,r){var i=t.position,o=t.viewBox,c=t.offset,f=t.className,d=o,h=d.cx,p=d.cy,y=d.innerRadius,x=d.outerRadius,j=d.startAngle,w=d.endAngle,S=d.clockWise,b=(y+x)/2,A=Pte(j,w),_=A>=0?1:-1,O,T;i==="insideStart"?(O=j+_*c,T=S):i==="insideEnd"?(O=w-_*c,T=!S):i==="end"&&(O=w+_*c,T=S),T=A<=0?T:!T;var N=yt(h,p,b,O),E=yt(h,p,b,O+(T?1:-1)*359),M="M".concat(N.x,",").concat(N.y,`
|
||
A`).concat(b,",").concat(b,",0,1,").concat(T?0:1,`,
|
||
`).concat(E.x,",").concat(E.y),D=Re(t.id)?Nl("recharts-radial-line-"):t.id;return U.createElement("text",Ou({},r,{dominantBaseline:"central",className:ze("recharts-radial-bar-label",f)}),U.createElement("defs",null,U.createElement("path",{id:D,d:M})),U.createElement("textPath",{xlinkHref:"#".concat(D)},n))},kte=function(t){var n=t.viewBox,r=t.offset,i=t.position,o=n,c=o.cx,f=o.cy,d=o.innerRadius,h=o.outerRadius,p=o.startAngle,y=o.endAngle,x=(p+y)/2;if(i==="outside"){var j=yt(c,f,h+r,x),w=j.x,S=j.y;return{x:w,y:S,textAnchor:w>=c?"start":"end",verticalAnchor:"middle"}}if(i==="center")return{x:c,y:f,textAnchor:"middle",verticalAnchor:"middle"};if(i==="centerTop")return{x:c,y:f,textAnchor:"middle",verticalAnchor:"start"};if(i==="centerBottom")return{x:c,y:f,textAnchor:"middle",verticalAnchor:"end"};var b=(d+h)/2,A=yt(c,f,b,x),_=A.x,O=A.y;return{x:_,y:O,textAnchor:"middle",verticalAnchor:"middle"}},Dte=function(t){var n=t.viewBox,r=t.parentViewBox,i=t.offset,o=t.position,c=n,f=c.x,d=c.y,h=c.width,p=c.height,y=p>=0?1:-1,x=y*i,j=y>0?"end":"start",w=y>0?"start":"end",S=h>=0?1:-1,b=S*i,A=S>0?"end":"start",_=S>0?"start":"end";if(o==="top"){var O={x:f+h/2,y:d-y*i,textAnchor:"middle",verticalAnchor:j};return Ft(Ft({},O),r?{height:Math.max(d-r.y,0),width:h}:{})}if(o==="bottom"){var T={x:f+h/2,y:d+p+x,textAnchor:"middle",verticalAnchor:w};return Ft(Ft({},T),r?{height:Math.max(r.y+r.height-(d+p),0),width:h}:{})}if(o==="left"){var N={x:f-b,y:d+p/2,textAnchor:A,verticalAnchor:"middle"};return Ft(Ft({},N),r?{width:Math.max(N.x-r.x,0),height:p}:{})}if(o==="right"){var E={x:f+h+b,y:d+p/2,textAnchor:_,verticalAnchor:"middle"};return Ft(Ft({},E),r?{width:Math.max(r.x+r.width-E.x,0),height:p}:{})}var M=r?{width:h,height:p}:{};return o==="insideLeft"?Ft({x:f+b,y:d+p/2,textAnchor:_,verticalAnchor:"middle"},M):o==="insideRight"?Ft({x:f+h-b,y:d+p/2,textAnchor:A,verticalAnchor:"middle"},M):o==="insideTop"?Ft({x:f+h/2,y:d+x,textAnchor:"middle",verticalAnchor:w},M):o==="insideBottom"?Ft({x:f+h/2,y:d+p-x,textAnchor:"middle",verticalAnchor:j},M):o==="insideTopLeft"?Ft({x:f+b,y:d+x,textAnchor:_,verticalAnchor:w},M):o==="insideTopRight"?Ft({x:f+h-b,y:d+x,textAnchor:A,verticalAnchor:w},M):o==="insideBottomLeft"?Ft({x:f+b,y:d+p-x,textAnchor:_,verticalAnchor:j},M):o==="insideBottomRight"?Ft({x:f+h-b,y:d+p-x,textAnchor:A,verticalAnchor:j},M):Sl(o)&&(de(o.x)||hs(o.x))&&(de(o.y)||hs(o.y))?Ft({x:f+jn(o.x,h),y:d+jn(o.y,p),textAnchor:"end",verticalAnchor:"end"},M):Ft({x:f+h/2,y:d+p/2,textAnchor:"middle",verticalAnchor:"middle"},M)},zte=function(t){return"cx"in t&&de(t.cx)};function en(e){var t=e.offset,n=t===void 0?5:t,r=Ote(e,bte),i=Ft({offset:n},r),o=i.viewBox,c=i.position,f=i.value,d=i.children,h=i.content,p=i.className,y=p===void 0?"":p,x=i.textBreakAll;if(!o||Re(f)&&Re(d)&&!P.isValidElement(h)&&!Ce(h))return null;if(P.isValidElement(h))return P.cloneElement(h,i);var j;if(Ce(h)){if(j=P.createElement(h,i),P.isValidElement(j))return j}else j=Mte(i);var w=zte(o),S=Ne(i,!0);if(w&&(c==="insideStart"||c==="insideEnd"||c==="end"))return Rte(i,j,S);var b=w?kte(i):Dte(i);return U.createElement(Ns,Ou({className:ze("recharts-label",y)},S,b,{breakAll:x}),j)}en.displayName="Label";var KL=function(t){var n=t.cx,r=t.cy,i=t.angle,o=t.startAngle,c=t.endAngle,f=t.r,d=t.radius,h=t.innerRadius,p=t.outerRadius,y=t.x,x=t.y,j=t.top,w=t.left,S=t.width,b=t.height,A=t.clockWise,_=t.labelViewBox;if(_)return _;if(de(S)&&de(b)){if(de(y)&&de(x))return{x:y,y:x,width:S,height:b};if(de(j)&&de(w))return{x:j,y:w,width:S,height:b}}return de(y)&&de(x)?{x:y,y:x,width:0,height:0}:de(n)&&de(r)?{cx:n,cy:r,startAngle:o||i||0,endAngle:c||i||0,innerRadius:h||0,outerRadius:p||d||f||0,clockWise:A}:t.viewBox?t.viewBox:{}},Lte=function(t,n){return t?t===!0?U.createElement(en,{key:"label-implicit",viewBox:n}):Xt(t)?U.createElement(en,{key:"label-implicit",viewBox:n,value:t}):P.isValidElement(t)?t.type===en?P.cloneElement(t,{key:"label-implicit",viewBox:n}):U.createElement(en,{key:"label-implicit",content:t,viewBox:n}):Ce(t)?U.createElement(en,{key:"label-implicit",content:t,viewBox:n}):Sl(t)?U.createElement(en,Ou({viewBox:n},t,{key:"label-implicit"})):null:null},$te=function(t,n){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;if(!t||!t.children&&r&&!t.label)return null;var i=t.children,o=KL(t),c=Qn(i,en).map(function(d,h){return P.cloneElement(d,{viewBox:n||o,key:"label-".concat(h)})});if(!r)return c;var f=Lte(t.label,n||o);return[f].concat(jte(c))};en.parseViewBox=KL;en.renderCallByParent=$te;var R0,ik;function Bte(){if(ik)return R0;ik=1;function e(t){var n=t==null?0:t.length;return n?t[n-1]:void 0}return R0=e,R0}var qte=Bte();const Ite=at(qte);function _u(e){"@babel/helpers - typeof";return _u=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},_u(e)}var Ute=["valueAccessor"],Vte=["data","dataKey","clockWise","id","textBreakAll"];function Hte(e){return Yte(e)||Kte(e)||Gte(e)||Fte()}function Fte(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Gte(e,t){if(e){if(typeof e=="string")return Tj(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Tj(e,t)}}function Kte(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Yte(e){if(Array.isArray(e))return Tj(e)}function Tj(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function tm(){return tm=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},tm.apply(this,arguments)}function sk(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function ok(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?sk(Object(n),!0).forEach(function(r){Xte(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):sk(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Xte(e,t,n){return t=Wte(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Wte(e){var t=Zte(e,"string");return _u(t)=="symbol"?t:t+""}function Zte(e,t){if(_u(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(_u(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function lk(e,t){if(e==null)return{};var n=Qte(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Qte(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var Jte=function(t){return Array.isArray(t.value)?Ite(t.value):t.value};function ka(e){var t=e.valueAccessor,n=t===void 0?Jte:t,r=lk(e,Ute),i=r.data,o=r.dataKey,c=r.clockWise,f=r.id,d=r.textBreakAll,h=lk(r,Vte);return!i||!i.length?null:U.createElement(Xe,{className:"recharts-label-list"},i.map(function(p,y){var x=Re(o)?n(p,y):Kt(p&&p.payload,o),j=Re(f)?{}:{id:"".concat(f,"-").concat(y)};return U.createElement(en,tm({},Ne(p,!0),h,j,{parentViewBox:p.parentViewBox,value:x,textBreakAll:d,viewBox:en.parseViewBox(Re(c)?p:ok(ok({},p),{},{clockWise:c})),key:"label-".concat(y),index:y}))}))}ka.displayName="LabelList";function ene(e,t){return e?e===!0?U.createElement(ka,{key:"labelList-implicit",data:t}):U.isValidElement(e)||Ce(e)?U.createElement(ka,{key:"labelList-implicit",data:t,content:e}):Sl(e)?U.createElement(ka,tm({data:t},e,{key:"labelList-implicit"})):null:null}function tne(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;if(!e||!e.children&&n&&!e.label)return null;var r=e.children,i=Qn(r,ka).map(function(c,f){return P.cloneElement(c,{data:t,key:"labelList-".concat(f)})});if(!n)return i;var o=ene(e.label,t);return[o].concat(Hte(i))}ka.renderCallByParent=tne;function Tu(e){"@babel/helpers - typeof";return Tu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Tu(e)}function Ej(){return Ej=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ej.apply(this,arguments)}function ck(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function uk(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?ck(Object(n),!0).forEach(function(r){nne(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ck(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function nne(e,t,n){return t=rne(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function rne(e){var t=ane(e,"string");return Tu(t)=="symbol"?t:t+""}function ane(e,t){if(Tu(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Tu(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var ine=function(t,n){var r=bn(n-t),i=Math.min(Math.abs(n-t),359.999);return r*i},Xd=function(t){var n=t.cx,r=t.cy,i=t.radius,o=t.angle,c=t.sign,f=t.isExternal,d=t.cornerRadius,h=t.cornerIsExternal,p=d*(f?1:-1)+i,y=Math.asin(d/p)/em,x=h?o:o+c*y,j=yt(n,r,p,x),w=yt(n,r,i,x),S=h?o-c*y:o,b=yt(n,r,p*Math.cos(y*em),S);return{center:j,circleTangency:w,lineTangency:b,theta:y}},YL=function(t){var n=t.cx,r=t.cy,i=t.innerRadius,o=t.outerRadius,c=t.startAngle,f=t.endAngle,d=ine(c,f),h=c+d,p=yt(n,r,o,c),y=yt(n,r,o,h),x="M ".concat(p.x,",").concat(p.y,`
|
||
A `).concat(o,",").concat(o,`,0,
|
||
`).concat(+(Math.abs(d)>180),",").concat(+(c>h),`,
|
||
`).concat(y.x,",").concat(y.y,`
|
||
`);if(i>0){var j=yt(n,r,i,c),w=yt(n,r,i,h);x+="L ".concat(w.x,",").concat(w.y,`
|
||
A `).concat(i,",").concat(i,`,0,
|
||
`).concat(+(Math.abs(d)>180),",").concat(+(c<=h),`,
|
||
`).concat(j.x,",").concat(j.y," Z")}else x+="L ".concat(n,",").concat(r," Z");return x},sne=function(t){var n=t.cx,r=t.cy,i=t.innerRadius,o=t.outerRadius,c=t.cornerRadius,f=t.forceCornerRadius,d=t.cornerIsExternal,h=t.startAngle,p=t.endAngle,y=bn(p-h),x=Xd({cx:n,cy:r,radius:o,angle:h,sign:y,cornerRadius:c,cornerIsExternal:d}),j=x.circleTangency,w=x.lineTangency,S=x.theta,b=Xd({cx:n,cy:r,radius:o,angle:p,sign:-y,cornerRadius:c,cornerIsExternal:d}),A=b.circleTangency,_=b.lineTangency,O=b.theta,T=d?Math.abs(h-p):Math.abs(h-p)-S-O;if(T<0)return f?"M ".concat(w.x,",").concat(w.y,`
|
||
a`).concat(c,",").concat(c,",0,0,1,").concat(c*2,`,0
|
||
a`).concat(c,",").concat(c,",0,0,1,").concat(-c*2,`,0
|
||
`):YL({cx:n,cy:r,innerRadius:i,outerRadius:o,startAngle:h,endAngle:p});var N="M ".concat(w.x,",").concat(w.y,`
|
||
A`).concat(c,",").concat(c,",0,0,").concat(+(y<0),",").concat(j.x,",").concat(j.y,`
|
||
A`).concat(o,",").concat(o,",0,").concat(+(T>180),",").concat(+(y<0),",").concat(A.x,",").concat(A.y,`
|
||
A`).concat(c,",").concat(c,",0,0,").concat(+(y<0),",").concat(_.x,",").concat(_.y,`
|
||
`);if(i>0){var E=Xd({cx:n,cy:r,radius:i,angle:h,sign:y,isExternal:!0,cornerRadius:c,cornerIsExternal:d}),M=E.circleTangency,D=E.lineTangency,R=E.theta,B=Xd({cx:n,cy:r,radius:i,angle:p,sign:-y,isExternal:!0,cornerRadius:c,cornerIsExternal:d}),q=B.circleTangency,z=B.lineTangency,H=B.theta,X=d?Math.abs(h-p):Math.abs(h-p)-R-H;if(X<0&&c===0)return"".concat(N,"L").concat(n,",").concat(r,"Z");N+="L".concat(z.x,",").concat(z.y,`
|
||
A`).concat(c,",").concat(c,",0,0,").concat(+(y<0),",").concat(q.x,",").concat(q.y,`
|
||
A`).concat(i,",").concat(i,",0,").concat(+(X>180),",").concat(+(y>0),",").concat(M.x,",").concat(M.y,`
|
||
A`).concat(c,",").concat(c,",0,0,").concat(+(y<0),",").concat(D.x,",").concat(D.y,"Z")}else N+="L".concat(n,",").concat(r,"Z");return N},one={cx:0,cy:0,innerRadius:0,outerRadius:0,startAngle:0,endAngle:0,cornerRadius:0,forceCornerRadius:!1,cornerIsExternal:!1},XL=function(t){var n=uk(uk({},one),t),r=n.cx,i=n.cy,o=n.innerRadius,c=n.outerRadius,f=n.cornerRadius,d=n.forceCornerRadius,h=n.cornerIsExternal,p=n.startAngle,y=n.endAngle,x=n.className;if(c<o||p===y)return null;var j=ze("recharts-sector",x),w=c-o,S=jn(f,w,0,!0),b;return S>0&&Math.abs(p-y)<360?b=sne({cx:r,cy:i,innerRadius:o,outerRadius:c,cornerRadius:Math.min(S,w/2),forceCornerRadius:d,cornerIsExternal:h,startAngle:p,endAngle:y}):b=YL({cx:r,cy:i,innerRadius:o,outerRadius:c,startAngle:p,endAngle:y}),U.createElement("path",Ej({},Ne(n,!0),{className:j,d:b,role:"img"}))};function Eu(e){"@babel/helpers - typeof";return Eu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Eu(e)}function Cj(){return Cj=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Cj.apply(this,arguments)}function fk(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function dk(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?fk(Object(n),!0).forEach(function(r){lne(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):fk(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function lne(e,t,n){return t=cne(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function cne(e){var t=une(e,"string");return Eu(t)=="symbol"?t:t+""}function une(e,t){if(Eu(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Eu(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var hk={curveBasisClosed:CK,curveBasisOpen:MK,curveBasis:EK,curveBumpX:pK,curveBumpY:yK,curveLinearClosed:PK,curveLinear:Gm,curveMonotoneX:RK,curveMonotoneY:kK,curveNatural:DK,curveStep:zK,curveStepAfter:$K,curveStepBefore:LK},Wd=function(t){return t.x===+t.x&&t.y===+t.y},Dc=function(t){return t.x},zc=function(t){return t.y},fne=function(t,n){if(Ce(t))return t;var r="curve".concat(Hm(t));return(r==="curveMonotone"||r==="curveBump")&&n?hk["".concat(r).concat(n==="vertical"?"Y":"X")]:hk[r]||Gm},dne=function(t){var n=t.type,r=n===void 0?"linear":n,i=t.points,o=i===void 0?[]:i,c=t.baseLine,f=t.layout,d=t.connectNulls,h=d===void 0?!1:d,p=fne(r,f),y=h?o.filter(function(S){return Wd(S)}):o,x;if(Array.isArray(c)){var j=h?c.filter(function(S){return Wd(S)}):c,w=y.map(function(S,b){return dk(dk({},S),{},{base:j[b]})});return f==="vertical"?x=Id().y(zc).x1(Dc).x0(function(S){return S.base.x}):x=Id().x(Dc).y1(zc).y0(function(S){return S.base.y}),x.defined(Wd).curve(p),x(w)}return f==="vertical"&&de(c)?x=Id().y(zc).x1(Dc).x0(c):de(c)?x=Id().x(Dc).y1(zc).y0(c):x=Yz().x(Dc).y(zc),x.defined(Wd).curve(p),x(y)},nm=function(t){var n=t.className,r=t.points,i=t.path,o=t.pathRef;if((!r||!r.length)&&!i)return null;var c=r&&r.length?dne(t):i;return P.createElement("path",Cj({},Ne(t,!1),Th(t),{className:ze("recharts-curve",n),d:c,ref:o}))},k0={exports:{}},D0,mk;function hne(){if(mk)return D0;mk=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return D0=e,D0}var z0,pk;function mne(){if(pk)return z0;pk=1;var e=hne();function t(){}function n(){}return n.resetWarningCache=t,z0=function(){function r(c,f,d,h,p,y){if(y!==e){var x=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw x.name="Invariant Violation",x}}r.isRequired=r;function i(){return r}var o={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:i,element:r,elementType:r,instanceOf:i,node:r,objectOf:i,oneOf:i,oneOfType:i,shape:i,exact:i,checkPropTypes:n,resetWarningCache:t};return o.PropTypes=o,o},z0}var yk;function pne(){return yk||(yk=1,k0.exports=mne()()),k0.exports}var yne=pne();const et=at(yne),{getOwnPropertyNames:xne,getOwnPropertySymbols:gne}=Object,{hasOwnProperty:vne}=Object.prototype;function L0(e,t){return function(r,i,o){return e(r,i,o)&&t(r,i,o)}}function Zd(e){return function(n,r,i){if(!n||!r||typeof n!="object"||typeof r!="object")return e(n,r,i);const{cache:o}=i,c=o.get(n),f=o.get(r);if(c&&f)return c===r&&f===n;o.set(n,r),o.set(r,n);const d=e(n,r,i);return o.delete(n),o.delete(r),d}}function bne(e){return e!=null?e[Symbol.toStringTag]:void 0}function xk(e){return xne(e).concat(gne(e))}const jne=Object.hasOwn||((e,t)=>vne.call(e,t));function Rs(e,t){return e===t||!e&&!t&&e!==e&&t!==t}const wne="__v",Sne="__o",Nne="_owner",{getOwnPropertyDescriptor:gk,keys:vk}=Object;function Ane(e,t){return e.byteLength===t.byteLength&&rm(new Uint8Array(e),new Uint8Array(t))}function One(e,t,n){let r=e.length;if(t.length!==r)return!1;for(;r-- >0;)if(!n.equals(e[r],t[r],r,r,e,t,n))return!1;return!0}function _ne(e,t){return e.byteLength===t.byteLength&&rm(new Uint8Array(e.buffer,e.byteOffset,e.byteLength),new Uint8Array(t.buffer,t.byteOffset,t.byteLength))}function Tne(e,t){return Rs(e.getTime(),t.getTime())}function Ene(e,t){return e.name===t.name&&e.message===t.message&&e.cause===t.cause&&e.stack===t.stack}function Cne(e,t){return e===t}function bk(e,t,n){const r=e.size;if(r!==t.size)return!1;if(!r)return!0;const i=new Array(r),o=e.entries();let c,f,d=0;for(;(c=o.next())&&!c.done;){const h=t.entries();let p=!1,y=0;for(;(f=h.next())&&!f.done;){if(i[y]){y++;continue}const x=c.value,j=f.value;if(n.equals(x[0],j[0],d,y,e,t,n)&&n.equals(x[1],j[1],x[0],j[0],e,t,n)){p=i[y]=!0;break}y++}if(!p)return!1;d++}return!0}const Mne=Rs;function Pne(e,t,n){const r=vk(e);let i=r.length;if(vk(t).length!==i)return!1;for(;i-- >0;)if(!WL(e,t,n,r[i]))return!1;return!0}function Lc(e,t,n){const r=xk(e);let i=r.length;if(xk(t).length!==i)return!1;let o,c,f;for(;i-- >0;)if(o=r[i],!WL(e,t,n,o)||(c=gk(e,o),f=gk(t,o),(c||f)&&(!c||!f||c.configurable!==f.configurable||c.enumerable!==f.enumerable||c.writable!==f.writable)))return!1;return!0}function Rne(e,t){return Rs(e.valueOf(),t.valueOf())}function kne(e,t){return e.source===t.source&&e.flags===t.flags}function jk(e,t,n){const r=e.size;if(r!==t.size)return!1;if(!r)return!0;const i=new Array(r),o=e.values();let c,f;for(;(c=o.next())&&!c.done;){const d=t.values();let h=!1,p=0;for(;(f=d.next())&&!f.done;){if(!i[p]&&n.equals(c.value,f.value,c.value,f.value,e,t,n)){h=i[p]=!0;break}p++}if(!h)return!1}return!0}function rm(e,t){let n=e.byteLength;if(t.byteLength!==n||e.byteOffset!==t.byteOffset)return!1;for(;n-- >0;)if(e[n]!==t[n])return!1;return!0}function Dne(e,t){return e.hostname===t.hostname&&e.pathname===t.pathname&&e.protocol===t.protocol&&e.port===t.port&&e.hash===t.hash&&e.username===t.username&&e.password===t.password}function WL(e,t,n,r){return(r===Nne||r===Sne||r===wne)&&(e.$$typeof||t.$$typeof)?!0:jne(t,r)&&n.equals(e[r],t[r],r,r,e,t,n)}const zne="[object ArrayBuffer]",Lne="[object Arguments]",$ne="[object Boolean]",Bne="[object DataView]",qne="[object Date]",Ine="[object Error]",Une="[object Map]",Vne="[object Number]",Hne="[object Object]",Fne="[object RegExp]",Gne="[object Set]",Kne="[object String]",Yne={"[object Int8Array]":!0,"[object Uint8Array]":!0,"[object Uint8ClampedArray]":!0,"[object Int16Array]":!0,"[object Uint16Array]":!0,"[object Int32Array]":!0,"[object Uint32Array]":!0,"[object Float16Array]":!0,"[object Float32Array]":!0,"[object Float64Array]":!0,"[object BigInt64Array]":!0,"[object BigUint64Array]":!0},Xne="[object URL]",Wne=Object.prototype.toString;function Zne({areArrayBuffersEqual:e,areArraysEqual:t,areDataViewsEqual:n,areDatesEqual:r,areErrorsEqual:i,areFunctionsEqual:o,areMapsEqual:c,areNumbersEqual:f,areObjectsEqual:d,arePrimitiveWrappersEqual:h,areRegExpsEqual:p,areSetsEqual:y,areTypedArraysEqual:x,areUrlsEqual:j,unknownTagComparators:w}){return function(b,A,_){if(b===A)return!0;if(b==null||A==null)return!1;const O=typeof b;if(O!==typeof A)return!1;if(O!=="object")return O==="number"?f(b,A,_):O==="function"?o(b,A,_):!1;const T=b.constructor;if(T!==A.constructor)return!1;if(T===Object)return d(b,A,_);if(Array.isArray(b))return t(b,A,_);if(T===Date)return r(b,A,_);if(T===RegExp)return p(b,A,_);if(T===Map)return c(b,A,_);if(T===Set)return y(b,A,_);const N=Wne.call(b);if(N===qne)return r(b,A,_);if(N===Fne)return p(b,A,_);if(N===Une)return c(b,A,_);if(N===Gne)return y(b,A,_);if(N===Hne)return typeof b.then!="function"&&typeof A.then!="function"&&d(b,A,_);if(N===Xne)return j(b,A,_);if(N===Ine)return i(b,A,_);if(N===Lne)return d(b,A,_);if(Yne[N])return x(b,A,_);if(N===zne)return e(b,A,_);if(N===Bne)return n(b,A,_);if(N===$ne||N===Vne||N===Kne)return h(b,A,_);if(w){let E=w[N];if(!E){const M=bne(b);M&&(E=w[M])}if(E)return E(b,A,_)}return!1}}function Qne({circular:e,createCustomConfig:t,strict:n}){let r={areArrayBuffersEqual:Ane,areArraysEqual:n?Lc:One,areDataViewsEqual:_ne,areDatesEqual:Tne,areErrorsEqual:Ene,areFunctionsEqual:Cne,areMapsEqual:n?L0(bk,Lc):bk,areNumbersEqual:Mne,areObjectsEqual:n?Lc:Pne,arePrimitiveWrappersEqual:Rne,areRegExpsEqual:kne,areSetsEqual:n?L0(jk,Lc):jk,areTypedArraysEqual:n?L0(rm,Lc):rm,areUrlsEqual:Dne,unknownTagComparators:void 0};if(t&&(r=Object.assign({},r,t(r))),e){const i=Zd(r.areArraysEqual),o=Zd(r.areMapsEqual),c=Zd(r.areObjectsEqual),f=Zd(r.areSetsEqual);r=Object.assign({},r,{areArraysEqual:i,areMapsEqual:o,areObjectsEqual:c,areSetsEqual:f})}return r}function Jne(e){return function(t,n,r,i,o,c,f){return e(t,n,f)}}function ere({circular:e,comparator:t,createState:n,equals:r,strict:i}){if(n)return function(f,d){const{cache:h=e?new WeakMap:void 0,meta:p}=n();return t(f,d,{cache:h,equals:r,meta:p,strict:i})};if(e)return function(f,d){return t(f,d,{cache:new WeakMap,equals:r,meta:void 0,strict:i})};const o={cache:void 0,equals:r,meta:void 0,strict:i};return function(f,d){return t(f,d,o)}}const tre=Li();Li({strict:!0});Li({circular:!0});Li({circular:!0,strict:!0});Li({createInternalComparator:()=>Rs});Li({strict:!0,createInternalComparator:()=>Rs});Li({circular:!0,createInternalComparator:()=>Rs});Li({circular:!0,createInternalComparator:()=>Rs,strict:!0});function Li(e={}){const{circular:t=!1,createInternalComparator:n,createState:r,strict:i=!1}=e,o=Qne(e),c=Zne(o),f=n?n(c):Jne(c);return ere({circular:t,comparator:c,createState:r,equals:f,strict:i})}function nre(e){typeof requestAnimationFrame<"u"&&requestAnimationFrame(e)}function wk(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n=-1,r=function i(o){n<0&&(n=o),o-n>t?(e(o),n=-1):nre(i)};requestAnimationFrame(r)}function Mj(e){"@babel/helpers - typeof";return Mj=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Mj(e)}function rre(e){return ore(e)||sre(e)||ire(e)||are()}function are(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function ire(e,t){if(e){if(typeof e=="string")return Sk(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Sk(e,t)}}function Sk(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function sre(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function ore(e){if(Array.isArray(e))return e}function lre(){var e={},t=function(){return null},n=!1,r=function i(o){if(!n){if(Array.isArray(o)){if(!o.length)return;var c=o,f=rre(c),d=f[0],h=f.slice(1);if(typeof d=="number"){wk(i.bind(null,h),d);return}i(d),wk(i.bind(null,h));return}Mj(o)==="object"&&(e=o,t(e)),typeof o=="function"&&o()}};return{stop:function(){n=!0},start:function(o){n=!1,r(o)},subscribe:function(o){return t=o,function(){t=function(){return null}}}}}function Cu(e){"@babel/helpers - typeof";return Cu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Cu(e)}function Nk(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Ak(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Nk(Object(n),!0).forEach(function(r){ZL(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Nk(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function ZL(e,t,n){return t=cre(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function cre(e){var t=ure(e,"string");return Cu(t)==="symbol"?t:String(t)}function ure(e,t){if(Cu(e)!=="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Cu(r)!=="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var fre=function(t,n){return[Object.keys(t),Object.keys(n)].reduce(function(r,i){return r.filter(function(o){return i.includes(o)})})},dre=function(t){return t},hre=function(t){return t.replace(/([A-Z])/g,function(n){return"-".concat(n.toLowerCase())})},Qc=function(t,n){return Object.keys(n).reduce(function(r,i){return Ak(Ak({},r),{},ZL({},i,t(i,n[i])))},{})},Ok=function(t,n,r){return t.map(function(i){return"".concat(hre(i)," ").concat(n,"ms ").concat(r)}).join(",")};function mre(e,t){return xre(e)||yre(e,t)||QL(e,t)||pre()}function pre(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function yre(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,c,f=[],d=!0,h=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(d=(r=o.call(n)).done)&&(f.push(r.value),f.length!==t);d=!0);}catch(p){h=!0,i=p}finally{try{if(!d&&n.return!=null&&(c=n.return(),Object(c)!==c))return}finally{if(h)throw i}}return f}}function xre(e){if(Array.isArray(e))return e}function gre(e){return jre(e)||bre(e)||QL(e)||vre()}function vre(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function QL(e,t){if(e){if(typeof e=="string")return Pj(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Pj(e,t)}}function bre(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function jre(e){if(Array.isArray(e))return Pj(e)}function Pj(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var am=1e-4,JL=function(t,n){return[0,3*t,3*n-6*t,3*t-3*n+1]},e6=function(t,n){return t.map(function(r,i){return r*Math.pow(n,i)}).reduce(function(r,i){return r+i})},_k=function(t,n){return function(r){var i=JL(t,n);return e6(i,r)}},wre=function(t,n){return function(r){var i=JL(t,n),o=[].concat(gre(i.map(function(c,f){return c*f}).slice(1)),[0]);return e6(o,r)}},Tk=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var i=n[0],o=n[1],c=n[2],f=n[3];if(n.length===1)switch(n[0]){case"linear":i=0,o=0,c=1,f=1;break;case"ease":i=.25,o=.1,c=.25,f=1;break;case"ease-in":i=.42,o=0,c=1,f=1;break;case"ease-out":i=.42,o=0,c=.58,f=1;break;case"ease-in-out":i=0,o=0,c=.58,f=1;break;default:{var d=n[0].split("(");if(d[0]==="cubic-bezier"&&d[1].split(")")[0].split(",").length===4){var h=d[1].split(")")[0].split(",").map(function(b){return parseFloat(b)}),p=mre(h,4);i=p[0],o=p[1],c=p[2],f=p[3]}}}var y=_k(i,c),x=_k(o,f),j=wre(i,c),w=function(A){return A>1?1:A<0?0:A},S=function(A){for(var _=A>1?1:A,O=_,T=0;T<8;++T){var N=y(O)-_,E=j(O);if(Math.abs(N-_)<am||E<am)return x(O);O=w(O-N/E)}return x(O)};return S.isStepper=!1,S},Sre=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=t.stiff,r=n===void 0?100:n,i=t.damping,o=i===void 0?8:i,c=t.dt,f=c===void 0?17:c,d=function(p,y,x){var j=-(p-y)*r,w=x*o,S=x+(j-w)*f/1e3,b=x*f/1e3+p;return Math.abs(b-y)<am&&Math.abs(S)<am?[y,0]:[b,S]};return d.isStepper=!0,d.dt=f,d},Nre=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var i=n[0];if(typeof i=="string")switch(i){case"ease":case"ease-in-out":case"ease-out":case"ease-in":case"linear":return Tk(i);case"spring":return Sre();default:if(i.split("(")[0]==="cubic-bezier")return Tk(i)}return typeof i=="function"?i:null};function Mu(e){"@babel/helpers - typeof";return Mu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Mu(e)}function Ek(e){return _re(e)||Ore(e)||t6(e)||Are()}function Are(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Ore(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function _re(e){if(Array.isArray(e))return kj(e)}function Ck(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function ln(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Ck(Object(n),!0).forEach(function(r){Rj(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ck(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Rj(e,t,n){return t=Tre(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Tre(e){var t=Ere(e,"string");return Mu(t)==="symbol"?t:String(t)}function Ere(e,t){if(Mu(e)!=="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Mu(r)!=="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Cre(e,t){return Rre(e)||Pre(e,t)||t6(e,t)||Mre()}function Mre(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function t6(e,t){if(e){if(typeof e=="string")return kj(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return kj(e,t)}}function kj(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Pre(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,c,f=[],d=!0,h=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(d=(r=o.call(n)).done)&&(f.push(r.value),f.length!==t);d=!0);}catch(p){h=!0,i=p}finally{try{if(!d&&n.return!=null&&(c=n.return(),Object(c)!==c))return}finally{if(h)throw i}}return f}}function Rre(e){if(Array.isArray(e))return e}var im=function(t,n,r){return t+(n-t)*r},Dj=function(t){var n=t.from,r=t.to;return n!==r},kre=function e(t,n,r){var i=Qc(function(o,c){if(Dj(c)){var f=t(c.from,c.to,c.velocity),d=Cre(f,2),h=d[0],p=d[1];return ln(ln({},c),{},{from:h,velocity:p})}return c},n);return r<1?Qc(function(o,c){return Dj(c)?ln(ln({},c),{},{velocity:im(c.velocity,i[o].velocity,r),from:im(c.from,i[o].from,r)}):c},n):e(t,i,r-1)};const Dre=(function(e,t,n,r,i){var o=fre(e,t),c=o.reduce(function(b,A){return ln(ln({},b),{},Rj({},A,[e[A],t[A]]))},{}),f=o.reduce(function(b,A){return ln(ln({},b),{},Rj({},A,{from:e[A],velocity:0,to:t[A]}))},{}),d=-1,h,p,y=function(){return null},x=function(){return Qc(function(A,_){return _.from},f)},j=function(){return!Object.values(f).filter(Dj).length},w=function(A){h||(h=A);var _=A-h,O=_/n.dt;f=kre(n,f,O),i(ln(ln(ln({},e),t),x())),h=A,j()||(d=requestAnimationFrame(y))},S=function(A){p||(p=A);var _=(A-p)/r,O=Qc(function(N,E){return im.apply(void 0,Ek(E).concat([n(_)]))},c);if(i(ln(ln(ln({},e),t),O)),_<1)d=requestAnimationFrame(y);else{var T=Qc(function(N,E){return im.apply(void 0,Ek(E).concat([n(1)]))},c);i(ln(ln(ln({},e),t),T))}};return y=n.isStepper?w:S,function(){return requestAnimationFrame(y),function(){cancelAnimationFrame(d)}}});function Zo(e){"@babel/helpers - typeof";return Zo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Zo(e)}var zre=["children","begin","duration","attributeName","easing","isActive","steps","from","to","canBegin","onAnimationEnd","shouldReAnimate","onAnimationReStart"];function Lre(e,t){if(e==null)return{};var n=$re(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function $re(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o<r.length;o++)i=r[o],!(t.indexOf(i)>=0)&&(n[i]=e[i]);return n}function $0(e){return Ure(e)||Ire(e)||qre(e)||Bre()}function Bre(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function qre(e,t){if(e){if(typeof e=="string")return zj(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return zj(e,t)}}function Ire(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Ure(e){if(Array.isArray(e))return zj(e)}function zj(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Mk(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Tr(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Mk(Object(n),!0).forEach(function(r){Hc(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Mk(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Hc(e,t,n){return t=n6(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Vre(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Hre(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,n6(r.key),r)}}function Fre(e,t,n){return t&&Hre(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function n6(e){var t=Gre(e,"string");return Zo(t)==="symbol"?t:String(t)}function Gre(e,t){if(Zo(e)!=="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Zo(r)!=="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Kre(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Lj(e,t)}function Lj(e,t){return Lj=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},Lj(e,t)}function Yre(e){var t=Xre();return function(){var r=sm(e),i;if(t){var o=sm(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return $j(this,i)}}function $j(e,t){if(t&&(Zo(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Bj(e)}function Bj(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Xre(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function sm(e){return sm=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},sm(e)}var na=(function(e){Kre(n,e);var t=Yre(n);function n(r,i){var o;Vre(this,n),o=t.call(this,r,i);var c=o.props,f=c.isActive,d=c.attributeName,h=c.from,p=c.to,y=c.steps,x=c.children,j=c.duration;if(o.handleStyleChange=o.handleStyleChange.bind(Bj(o)),o.changeStyle=o.changeStyle.bind(Bj(o)),!f||j<=0)return o.state={style:{}},typeof x=="function"&&(o.state={style:p}),$j(o);if(y&&y.length)o.state={style:y[0].style};else if(h){if(typeof x=="function")return o.state={style:h},$j(o);o.state={style:d?Hc({},d,h):h}}else o.state={style:{}};return o}return Fre(n,[{key:"componentDidMount",value:function(){var i=this.props,o=i.isActive,c=i.canBegin;this.mounted=!0,!(!o||!c)&&this.runAnimation(this.props)}},{key:"componentDidUpdate",value:function(i){var o=this.props,c=o.isActive,f=o.canBegin,d=o.attributeName,h=o.shouldReAnimate,p=o.to,y=o.from,x=this.state.style;if(f){if(!c){var j={style:d?Hc({},d,p):p};this.state&&x&&(d&&x[d]!==p||!d&&x!==p)&&this.setState(j);return}if(!(tre(i.to,p)&&i.canBegin&&i.isActive)){var w=!i.canBegin||!i.isActive;this.manager&&this.manager.stop(),this.stopJSAnimation&&this.stopJSAnimation();var S=w||h?y:i.to;if(this.state&&x){var b={style:d?Hc({},d,S):S};(d&&x[d]!==S||!d&&x!==S)&&this.setState(b)}this.runAnimation(Tr(Tr({},this.props),{},{from:S,begin:0}))}}}},{key:"componentWillUnmount",value:function(){this.mounted=!1;var i=this.props.onAnimationEnd;this.unSubscribe&&this.unSubscribe(),this.manager&&(this.manager.stop(),this.manager=null),this.stopJSAnimation&&this.stopJSAnimation(),i&&i()}},{key:"handleStyleChange",value:function(i){this.changeStyle(i)}},{key:"changeStyle",value:function(i){this.mounted&&this.setState({style:i})}},{key:"runJSAnimation",value:function(i){var o=this,c=i.from,f=i.to,d=i.duration,h=i.easing,p=i.begin,y=i.onAnimationEnd,x=i.onAnimationStart,j=Dre(c,f,Nre(h),d,this.changeStyle),w=function(){o.stopJSAnimation=j()};this.manager.start([x,p,w,d,y])}},{key:"runStepAnimation",value:function(i){var o=this,c=i.steps,f=i.begin,d=i.onAnimationStart,h=c[0],p=h.style,y=h.duration,x=y===void 0?0:y,j=function(S,b,A){if(A===0)return S;var _=b.duration,O=b.easing,T=O===void 0?"ease":O,N=b.style,E=b.properties,M=b.onAnimationEnd,D=A>0?c[A-1]:b,R=E||Object.keys(N);if(typeof T=="function"||T==="spring")return[].concat($0(S),[o.runJSAnimation.bind(o,{from:D.style,to:N,duration:_,easing:T}),_]);var B=Ok(R,_,T),q=Tr(Tr(Tr({},D.style),N),{},{transition:B});return[].concat($0(S),[q,_,M]).filter(dre)};return this.manager.start([d].concat($0(c.reduce(j,[p,Math.max(x,f)])),[i.onAnimationEnd]))}},{key:"runAnimation",value:function(i){this.manager||(this.manager=lre());var o=i.begin,c=i.duration,f=i.attributeName,d=i.to,h=i.easing,p=i.onAnimationStart,y=i.onAnimationEnd,x=i.steps,j=i.children,w=this.manager;if(this.unSubscribe=w.subscribe(this.handleStyleChange),typeof h=="function"||typeof j=="function"||h==="spring"){this.runJSAnimation(i);return}if(x.length>1){this.runStepAnimation(i);return}var S=f?Hc({},f,d):d,b=Ok(Object.keys(S),c,h);w.start([p,o,Tr(Tr({},S),{},{transition:b}),c,y])}},{key:"render",value:function(){var i=this.props,o=i.children;i.begin;var c=i.duration;i.attributeName,i.easing;var f=i.isActive;i.steps,i.from,i.to,i.canBegin,i.onAnimationEnd,i.shouldReAnimate,i.onAnimationReStart;var d=Lre(i,zre),h=P.Children.count(o),p=this.state.style;if(typeof o=="function")return o(p);if(!f||h===0||c<=0)return o;var y=function(j){var w=j.props,S=w.style,b=S===void 0?{}:S,A=w.className,_=P.cloneElement(j,Tr(Tr({},d),{},{style:Tr(Tr({},b),p),className:A}));return _};return h===1?y(P.Children.only(o)):U.createElement("div",null,P.Children.map(o,function(x){return y(x)}))}}]),n})(P.PureComponent);na.displayName="Animate";na.defaultProps={begin:0,duration:1e3,from:"",to:"",attributeName:"",easing:"ease",isActive:!0,canBegin:!0,steps:[],onAnimationEnd:function(){},onAnimationStart:function(){}};na.propTypes={from:et.oneOfType([et.object,et.string]),to:et.oneOfType([et.object,et.string]),attributeName:et.string,duration:et.number,begin:et.number,easing:et.oneOfType([et.string,et.func]),steps:et.arrayOf(et.shape({duration:et.number.isRequired,style:et.object.isRequired,easing:et.oneOfType([et.oneOf(["ease","ease-in","ease-out","ease-in-out","linear"]),et.func]),properties:et.arrayOf("string"),onAnimationEnd:et.func})),children:et.oneOfType([et.node,et.func]),isActive:et.bool,canBegin:et.bool,onAnimationEnd:et.func,shouldReAnimate:et.bool,onAnimationStart:et.func,onAnimationReStart:et.func};function Pu(e){"@babel/helpers - typeof";return Pu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Pu(e)}function om(){return om=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},om.apply(this,arguments)}function Wre(e,t){return eae(e)||Jre(e,t)||Qre(e,t)||Zre()}function Zre(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Qre(e,t){if(e){if(typeof e=="string")return Pk(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Pk(e,t)}}function Pk(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Jre(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,c,f=[],d=!0,h=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(d=(r=o.call(n)).done)&&(f.push(r.value),f.length!==t);d=!0);}catch(p){h=!0,i=p}finally{try{if(!d&&n.return!=null&&(c=n.return(),Object(c)!==c))return}finally{if(h)throw i}}return f}}function eae(e){if(Array.isArray(e))return e}function Rk(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function kk(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Rk(Object(n),!0).forEach(function(r){tae(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Rk(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function tae(e,t,n){return t=nae(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function nae(e){var t=rae(e,"string");return Pu(t)=="symbol"?t:t+""}function rae(e,t){if(Pu(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Pu(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Dk=function(t,n,r,i,o){var c=Math.min(Math.abs(r)/2,Math.abs(i)/2),f=i>=0?1:-1,d=r>=0?1:-1,h=i>=0&&r>=0||i<0&&r<0?1:0,p;if(c>0&&o instanceof Array){for(var y=[0,0,0,0],x=0,j=4;x<j;x++)y[x]=o[x]>c?c:o[x];p="M".concat(t,",").concat(n+f*y[0]),y[0]>0&&(p+="A ".concat(y[0],",").concat(y[0],",0,0,").concat(h,",").concat(t+d*y[0],",").concat(n)),p+="L ".concat(t+r-d*y[1],",").concat(n),y[1]>0&&(p+="A ".concat(y[1],",").concat(y[1],",0,0,").concat(h,`,
|
||
`).concat(t+r,",").concat(n+f*y[1])),p+="L ".concat(t+r,",").concat(n+i-f*y[2]),y[2]>0&&(p+="A ".concat(y[2],",").concat(y[2],",0,0,").concat(h,`,
|
||
`).concat(t+r-d*y[2],",").concat(n+i)),p+="L ".concat(t+d*y[3],",").concat(n+i),y[3]>0&&(p+="A ".concat(y[3],",").concat(y[3],",0,0,").concat(h,`,
|
||
`).concat(t,",").concat(n+i-f*y[3])),p+="Z"}else if(c>0&&o===+o&&o>0){var w=Math.min(c,o);p="M ".concat(t,",").concat(n+f*w,`
|
||
A `).concat(w,",").concat(w,",0,0,").concat(h,",").concat(t+d*w,",").concat(n,`
|
||
L `).concat(t+r-d*w,",").concat(n,`
|
||
A `).concat(w,",").concat(w,",0,0,").concat(h,",").concat(t+r,",").concat(n+f*w,`
|
||
L `).concat(t+r,",").concat(n+i-f*w,`
|
||
A `).concat(w,",").concat(w,",0,0,").concat(h,",").concat(t+r-d*w,",").concat(n+i,`
|
||
L `).concat(t+d*w,",").concat(n+i,`
|
||
A `).concat(w,",").concat(w,",0,0,").concat(h,",").concat(t,",").concat(n+i-f*w," Z")}else p="M ".concat(t,",").concat(n," h ").concat(r," v ").concat(i," h ").concat(-r," Z");return p},aae=function(t,n){if(!t||!n)return!1;var r=t.x,i=t.y,o=n.x,c=n.y,f=n.width,d=n.height;if(Math.abs(f)>0&&Math.abs(d)>0){var h=Math.min(o,o+f),p=Math.max(o,o+f),y=Math.min(c,c+d),x=Math.max(c,c+d);return r>=h&&r<=p&&i>=y&&i<=x}return!1},iae={x:0,y:0,width:0,height:0,radius:0,isAnimationActive:!1,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},XS=function(t){var n=kk(kk({},iae),t),r=P.useRef(),i=P.useState(-1),o=Wre(i,2),c=o[0],f=o[1];P.useEffect(function(){if(r.current&&r.current.getTotalLength)try{var T=r.current.getTotalLength();T&&f(T)}catch{}},[]);var d=n.x,h=n.y,p=n.width,y=n.height,x=n.radius,j=n.className,w=n.animationEasing,S=n.animationDuration,b=n.animationBegin,A=n.isAnimationActive,_=n.isUpdateAnimationActive;if(d!==+d||h!==+h||p!==+p||y!==+y||p===0||y===0)return null;var O=ze("recharts-rectangle",j);return _?U.createElement(na,{canBegin:c>0,from:{width:p,height:y,x:d,y:h},to:{width:p,height:y,x:d,y:h},duration:S,animationEasing:w,isActive:_},function(T){var N=T.width,E=T.height,M=T.x,D=T.y;return U.createElement(na,{canBegin:c>0,from:"0px ".concat(c===-1?1:c,"px"),to:"".concat(c,"px 0px"),attributeName:"strokeDasharray",begin:b,duration:S,isActive:A,easing:w},U.createElement("path",om({},Ne(n,!0),{className:O,d:Dk(M,D,N,E,x),ref:r})))}):U.createElement("path",om({},Ne(n,!0),{className:O,d:Dk(d,h,p,y,x)}))},sae=["points","className","baseLinePoints","connectNulls"];function Co(){return Co=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Co.apply(this,arguments)}function oae(e,t){if(e==null)return{};var n=lae(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function lae(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function zk(e){return dae(e)||fae(e)||uae(e)||cae()}function cae(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function uae(e,t){if(e){if(typeof e=="string")return qj(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return qj(e,t)}}function fae(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function dae(e){if(Array.isArray(e))return qj(e)}function qj(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var Lk=function(t){return t&&t.x===+t.x&&t.y===+t.y},hae=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],n=[[]];return t.forEach(function(r){Lk(r)?n[n.length-1].push(r):n[n.length-1].length>0&&n.push([])}),Lk(t[0])&&n[n.length-1].push(t[0]),n[n.length-1].length<=0&&(n=n.slice(0,-1)),n},Jc=function(t,n){var r=hae(t);n&&(r=[r.reduce(function(o,c){return[].concat(zk(o),zk(c))},[])]);var i=r.map(function(o){return o.reduce(function(c,f,d){return"".concat(c).concat(d===0?"M":"L").concat(f.x,",").concat(f.y)},"")}).join("");return r.length===1?"".concat(i,"Z"):i},mae=function(t,n,r){var i=Jc(t,r);return"".concat(i.slice(-1)==="Z"?i.slice(0,-1):i,"L").concat(Jc(n.reverse(),r).slice(1))},pae=function(t){var n=t.points,r=t.className,i=t.baseLinePoints,o=t.connectNulls,c=oae(t,sae);if(!n||!n.length)return null;var f=ze("recharts-polygon",r);if(i&&i.length){var d=c.stroke&&c.stroke!=="none",h=mae(n,i,o);return U.createElement("g",{className:f},U.createElement("path",Co({},Ne(c,!0),{fill:h.slice(-1)==="Z"?c.fill:"none",stroke:"none",d:h})),d?U.createElement("path",Co({},Ne(c,!0),{fill:"none",d:Jc(n,o)})):null,d?U.createElement("path",Co({},Ne(c,!0),{fill:"none",d:Jc(i,o)})):null)}var p=Jc(n,o);return U.createElement("path",Co({},Ne(c,!0),{fill:p.slice(-1)==="Z"?c.fill:"none",className:f,d:p}))};function Ij(){return Ij=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ij.apply(this,arguments)}var cp=function(t){var n=t.cx,r=t.cy,i=t.r,o=t.className,c=ze("recharts-dot",o);return n===+n&&r===+r&&i===+i?P.createElement("circle",Ij({},Ne(t,!1),Th(t),{className:c,cx:n,cy:r,r:i})):null};function Ru(e){"@babel/helpers - typeof";return Ru=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ru(e)}var yae=["x","y","top","left","width","height","className"];function Uj(){return Uj=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Uj.apply(this,arguments)}function $k(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function xae(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?$k(Object(n),!0).forEach(function(r){gae(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):$k(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function gae(e,t,n){return t=vae(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function vae(e){var t=bae(e,"string");return Ru(t)=="symbol"?t:t+""}function bae(e,t){if(Ru(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Ru(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function jae(e,t){if(e==null)return{};var n=wae(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function wae(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var Sae=function(t,n,r,i,o,c){return"M".concat(t,",").concat(o,"v").concat(i,"M").concat(c,",").concat(n,"h").concat(r)},Nae=function(t){var n=t.x,r=n===void 0?0:n,i=t.y,o=i===void 0?0:i,c=t.top,f=c===void 0?0:c,d=t.left,h=d===void 0?0:d,p=t.width,y=p===void 0?0:p,x=t.height,j=x===void 0?0:x,w=t.className,S=jae(t,yae),b=xae({x:r,y:o,top:f,left:h,width:y,height:j},S);return!de(r)||!de(o)||!de(y)||!de(j)||!de(f)||!de(h)?null:U.createElement("path",Uj({},Ne(b,!0),{className:ze("recharts-cross",w),d:Sae(r,o,y,j,f,h)}))},B0,Bk;function Aae(){if(Bk)return B0;Bk=1;var e=ap(),t=xL(),n=aa();function r(i,o){return i&&i.length?e(i,n(o,2),t):void 0}return B0=r,B0}var Oae=Aae();const _ae=at(Oae);var q0,qk;function Tae(){if(qk)return q0;qk=1;var e=ap(),t=aa(),n=gL();function r(i,o){return i&&i.length?e(i,t(o,2),n):void 0}return q0=r,q0}var Eae=Tae();const Cae=at(Eae);var Mae=["cx","cy","angle","ticks","axisLine"],Pae=["ticks","tick","angle","tickFormatter","stroke"];function Qo(e){"@babel/helpers - typeof";return Qo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Qo(e)}function eu(){return eu=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},eu.apply(this,arguments)}function Ik(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function as(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Ik(Object(n),!0).forEach(function(r){up(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ik(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Uk(e,t){if(e==null)return{};var n=Rae(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Rae(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function kae(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Vk(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,a6(r.key),r)}}function Dae(e,t,n){return t&&Vk(e.prototype,t),n&&Vk(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function zae(e,t,n){return t=lm(t),Lae(e,r6()?Reflect.construct(t,n||[],lm(e).constructor):t.apply(e,n))}function Lae(e,t){if(t&&(Qo(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return $ae(e)}function $ae(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function r6(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(r6=function(){return!!e})()}function lm(e){return lm=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},lm(e)}function Bae(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Vj(e,t)}function Vj(e,t){return Vj=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},Vj(e,t)}function up(e,t,n){return t=a6(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function a6(e){var t=qae(e,"string");return Qo(t)=="symbol"?t:t+""}function qae(e,t){if(Qo(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Qo(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var fp=(function(e){function t(){return kae(this,t),zae(this,t,arguments)}return Bae(t,e),Dae(t,[{key:"getTickValueCoord",value:function(r){var i=r.coordinate,o=this.props,c=o.angle,f=o.cx,d=o.cy;return yt(f,d,i,c)}},{key:"getTickTextAnchor",value:function(){var r=this.props.orientation,i;switch(r){case"left":i="end";break;case"right":i="start";break;default:i="middle";break}return i}},{key:"getViewBox",value:function(){var r=this.props,i=r.cx,o=r.cy,c=r.angle,f=r.ticks,d=_ae(f,function(p){return p.coordinate||0}),h=Cae(f,function(p){return p.coordinate||0});return{cx:i,cy:o,startAngle:c,endAngle:c,innerRadius:h.coordinate||0,outerRadius:d.coordinate||0}}},{key:"renderAxisLine",value:function(){var r=this.props,i=r.cx,o=r.cy,c=r.angle,f=r.ticks,d=r.axisLine,h=Uk(r,Mae),p=f.reduce(function(w,S){return[Math.min(w[0],S.coordinate),Math.max(w[1],S.coordinate)]},[1/0,-1/0]),y=yt(i,o,p[0],c),x=yt(i,o,p[1],c),j=as(as(as({},Ne(h,!1)),{},{fill:"none"},Ne(d,!1)),{},{x1:y.x,y1:y.y,x2:x.x,y2:x.y});return U.createElement("line",eu({className:"recharts-polar-radius-axis-line"},j))}},{key:"renderTicks",value:function(){var r=this,i=this.props,o=i.ticks,c=i.tick,f=i.angle,d=i.tickFormatter,h=i.stroke,p=Uk(i,Pae),y=this.getTickTextAnchor(),x=Ne(p,!1),j=Ne(c,!1),w=o.map(function(S,b){var A=r.getTickValueCoord(S),_=as(as(as(as({textAnchor:y,transform:"rotate(".concat(90-f,", ").concat(A.x,", ").concat(A.y,")")},x),{},{stroke:"none",fill:h},j),{},{index:b},A),{},{payload:S});return U.createElement(Xe,eu({className:ze("recharts-polar-radius-axis-tick",GL(c)),key:"tick-".concat(S.coordinate)},Ss(r.props,S,b)),t.renderTickItem(c,_,d?d(S.value,b):S.value))});return U.createElement(Xe,{className:"recharts-polar-radius-axis-ticks"},w)}},{key:"render",value:function(){var r=this.props,i=r.ticks,o=r.axisLine,c=r.tick;return!i||!i.length?null:U.createElement(Xe,{className:ze("recharts-polar-radius-axis",this.props.className)},o&&this.renderAxisLine(),c&&this.renderTicks(),en.renderCallByParent(this.props,this.getViewBox()))}}],[{key:"renderTickItem",value:function(r,i,o){var c;return U.isValidElement(r)?c=U.cloneElement(r,i):Ce(r)?c=r(i):c=U.createElement(Ns,eu({},i,{className:"recharts-polar-radius-axis-tick-value"}),o),c}}])})(P.PureComponent);up(fp,"displayName","PolarRadiusAxis");up(fp,"axisType","radiusAxis");up(fp,"defaultProps",{type:"number",radiusAxisId:0,cx:0,cy:0,angle:0,orientation:"right",stroke:"#ccc",axisLine:!0,tick:!0,tickCount:5,allowDataOverflow:!1,scale:"auto",allowDuplicatedCategory:!0});function Jo(e){"@babel/helpers - typeof";return Jo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Jo(e)}function cs(){return cs=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},cs.apply(this,arguments)}function Hk(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function is(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Hk(Object(n),!0).forEach(function(r){dp(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Hk(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Iae(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Fk(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,s6(r.key),r)}}function Uae(e,t,n){return t&&Fk(e.prototype,t),n&&Fk(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Vae(e,t,n){return t=cm(t),Hae(e,i6()?Reflect.construct(t,n||[],cm(e).constructor):t.apply(e,n))}function Hae(e,t){if(t&&(Jo(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Fae(e)}function Fae(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function i6(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(i6=function(){return!!e})()}function cm(e){return cm=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},cm(e)}function Gae(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Hj(e,t)}function Hj(e,t){return Hj=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},Hj(e,t)}function dp(e,t,n){return t=s6(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function s6(e){var t=Kae(e,"string");return Jo(t)=="symbol"?t:t+""}function Kae(e,t){if(Jo(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Jo(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Yae=Math.PI/180,Gk=1e-5,hp=(function(e){function t(){return Iae(this,t),Vae(this,t,arguments)}return Gae(t,e),Uae(t,[{key:"getTickLineCoord",value:function(r){var i=this.props,o=i.cx,c=i.cy,f=i.radius,d=i.orientation,h=i.tickSize,p=h||8,y=yt(o,c,f,r.coordinate),x=yt(o,c,f+(d==="inner"?-1:1)*p,r.coordinate);return{x1:y.x,y1:y.y,x2:x.x,y2:x.y}}},{key:"getTickTextAnchor",value:function(r){var i=this.props.orientation,o=Math.cos(-r.coordinate*Yae),c;return o>Gk?c=i==="outer"?"start":"end":o<-Gk?c=i==="outer"?"end":"start":c="middle",c}},{key:"renderAxisLine",value:function(){var r=this.props,i=r.cx,o=r.cy,c=r.radius,f=r.axisLine,d=r.axisLineType,h=is(is({},Ne(this.props,!1)),{},{fill:"none"},Ne(f,!1));if(d==="circle")return U.createElement(cp,cs({className:"recharts-polar-angle-axis-line"},h,{cx:i,cy:o,r:c}));var p=this.props.ticks,y=p.map(function(x){return yt(i,o,c,x.coordinate)});return U.createElement(pae,cs({className:"recharts-polar-angle-axis-line"},h,{points:y}))}},{key:"renderTicks",value:function(){var r=this,i=this.props,o=i.ticks,c=i.tick,f=i.tickLine,d=i.tickFormatter,h=i.stroke,p=Ne(this.props,!1),y=Ne(c,!1),x=is(is({},p),{},{fill:"none"},Ne(f,!1)),j=o.map(function(w,S){var b=r.getTickLineCoord(w),A=r.getTickTextAnchor(w),_=is(is(is({textAnchor:A},p),{},{stroke:"none",fill:h},y),{},{index:S,payload:w,x:b.x2,y:b.y2});return U.createElement(Xe,cs({className:ze("recharts-polar-angle-axis-tick",GL(c)),key:"tick-".concat(w.coordinate)},Ss(r.props,w,S)),f&&U.createElement("line",cs({className:"recharts-polar-angle-axis-tick-line"},x,b)),c&&t.renderTickItem(c,_,d?d(w.value,S):w.value))});return U.createElement(Xe,{className:"recharts-polar-angle-axis-ticks"},j)}},{key:"render",value:function(){var r=this.props,i=r.ticks,o=r.radius,c=r.axisLine;return o<=0||!i||!i.length?null:U.createElement(Xe,{className:ze("recharts-polar-angle-axis",this.props.className)},c&&this.renderAxisLine(),this.renderTicks())}}],[{key:"renderTickItem",value:function(r,i,o){var c;return U.isValidElement(r)?c=U.cloneElement(r,i):Ce(r)?c=r(i):c=U.createElement(Ns,cs({},i,{className:"recharts-polar-angle-axis-tick-value"}),o),c}}])})(P.PureComponent);dp(hp,"displayName","PolarAngleAxis");dp(hp,"axisType","angleAxis");dp(hp,"defaultProps",{type:"category",angleAxisId:0,scale:"auto",cx:0,cy:0,orientation:"outer",axisLine:!0,tickLine:!0,tickSize:8,tick:!0,hide:!1,allowDuplicatedCategory:!0});var I0,Kk;function Xae(){if(Kk)return I0;Kk=1;var e=x5(),t=e(Object.getPrototypeOf,Object);return I0=t,I0}var U0,Yk;function Wae(){if(Yk)return U0;Yk=1;var e=Ha(),t=Xae(),n=Fa(),r="[object Object]",i=Function.prototype,o=Object.prototype,c=i.toString,f=o.hasOwnProperty,d=c.call(Object);function h(p){if(!n(p)||e(p)!=r)return!1;var y=t(p);if(y===null)return!0;var x=f.call(y,"constructor")&&y.constructor;return typeof x=="function"&&x instanceof x&&c.call(x)==d}return U0=h,U0}var Zae=Wae();const Qae=at(Zae);var V0,Xk;function Jae(){if(Xk)return V0;Xk=1;var e=Ha(),t=Fa(),n="[object Boolean]";function r(i){return i===!0||i===!1||t(i)&&e(i)==n}return V0=r,V0}var eie=Jae();const tie=at(eie);function ku(e){"@babel/helpers - typeof";return ku=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ku(e)}function um(){return um=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},um.apply(this,arguments)}function nie(e,t){return sie(e)||iie(e,t)||aie(e,t)||rie()}function rie(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function aie(e,t){if(e){if(typeof e=="string")return Wk(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Wk(e,t)}}function Wk(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function iie(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,c,f=[],d=!0,h=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(d=(r=o.call(n)).done)&&(f.push(r.value),f.length!==t);d=!0);}catch(p){h=!0,i=p}finally{try{if(!d&&n.return!=null&&(c=n.return(),Object(c)!==c))return}finally{if(h)throw i}}return f}}function sie(e){if(Array.isArray(e))return e}function Zk(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Qk(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Zk(Object(n),!0).forEach(function(r){oie(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Zk(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function oie(e,t,n){return t=lie(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function lie(e){var t=cie(e,"string");return ku(t)=="symbol"?t:t+""}function cie(e,t){if(ku(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(ku(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Jk=function(t,n,r,i,o){var c=r-i,f;return f="M ".concat(t,",").concat(n),f+="L ".concat(t+r,",").concat(n),f+="L ".concat(t+r-c/2,",").concat(n+o),f+="L ".concat(t+r-c/2-i,",").concat(n+o),f+="L ".concat(t,",").concat(n," Z"),f},uie={x:0,y:0,upperWidth:0,lowerWidth:0,height:0,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},fie=function(t){var n=Qk(Qk({},uie),t),r=P.useRef(),i=P.useState(-1),o=nie(i,2),c=o[0],f=o[1];P.useEffect(function(){if(r.current&&r.current.getTotalLength)try{var O=r.current.getTotalLength();O&&f(O)}catch{}},[]);var d=n.x,h=n.y,p=n.upperWidth,y=n.lowerWidth,x=n.height,j=n.className,w=n.animationEasing,S=n.animationDuration,b=n.animationBegin,A=n.isUpdateAnimationActive;if(d!==+d||h!==+h||p!==+p||y!==+y||x!==+x||p===0&&y===0||x===0)return null;var _=ze("recharts-trapezoid",j);return A?U.createElement(na,{canBegin:c>0,from:{upperWidth:0,lowerWidth:0,height:x,x:d,y:h},to:{upperWidth:p,lowerWidth:y,height:x,x:d,y:h},duration:S,animationEasing:w,isActive:A},function(O){var T=O.upperWidth,N=O.lowerWidth,E=O.height,M=O.x,D=O.y;return U.createElement(na,{canBegin:c>0,from:"0px ".concat(c===-1?1:c,"px"),to:"".concat(c,"px 0px"),attributeName:"strokeDasharray",begin:b,duration:S,easing:w},U.createElement("path",um({},Ne(n,!0),{className:_,d:Jk(M,D,T,N,E),ref:r})))}):U.createElement("g",null,U.createElement("path",um({},Ne(n,!0),{className:_,d:Jk(d,h,p,y,x)})))},die=["option","shapeType","propTransformer","activeClassName","isActive"];function Du(e){"@babel/helpers - typeof";return Du=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Du(e)}function hie(e,t){if(e==null)return{};var n=mie(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function mie(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function e3(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function fm(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?e3(Object(n),!0).forEach(function(r){pie(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):e3(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function pie(e,t,n){return t=yie(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function yie(e){var t=xie(e,"string");return Du(t)=="symbol"?t:t+""}function xie(e,t){if(Du(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Du(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function gie(e,t){return fm(fm({},t),e)}function vie(e,t){return e==="symbols"}function t3(e){var t=e.shapeType,n=e.elementProps;switch(t){case"rectangle":return U.createElement(XS,n);case"trapezoid":return U.createElement(fie,n);case"sector":return U.createElement(XL,n);case"symbols":if(vie(t))return U.createElement(mS,n);break;default:return null}}function bie(e){return P.isValidElement(e)?e.props:e}function o6(e){var t=e.option,n=e.shapeType,r=e.propTransformer,i=r===void 0?gie:r,o=e.activeClassName,c=o===void 0?"recharts-active-shape":o,f=e.isActive,d=hie(e,die),h;if(P.isValidElement(t))h=P.cloneElement(t,fm(fm({},d),bie(t)));else if(Ce(t))h=t(d);else if(Qae(t)&&!tie(t)){var p=i(t,d);h=U.createElement(t3,{shapeType:n,elementProps:p})}else{var y=d;h=U.createElement(t3,{shapeType:n,elementProps:y})}return f?U.createElement(Xe,{className:c},h):h}function mp(e,t){return t!=null&&"trapezoids"in e.props}function pp(e,t){return t!=null&&"sectors"in e.props}function zu(e,t){return t!=null&&"points"in e.props}function jie(e,t){var n,r,i=e.x===(t==null||(n=t.labelViewBox)===null||n===void 0?void 0:n.x)||e.x===t.x,o=e.y===(t==null||(r=t.labelViewBox)===null||r===void 0?void 0:r.y)||e.y===t.y;return i&&o}function wie(e,t){var n=e.endAngle===t.endAngle,r=e.startAngle===t.startAngle;return n&&r}function Sie(e,t){var n=e.x===t.x,r=e.y===t.y,i=e.z===t.z;return n&&r&&i}function Nie(e,t){var n;return mp(e,t)?n=jie:pp(e,t)?n=wie:zu(e,t)&&(n=Sie),n}function Aie(e,t){var n;return mp(e,t)?n="trapezoids":pp(e,t)?n="sectors":zu(e,t)&&(n="points"),n}function Oie(e,t){if(mp(e,t)){var n;return(n=t.tooltipPayload)===null||n===void 0||(n=n[0])===null||n===void 0||(n=n.payload)===null||n===void 0?void 0:n.payload}if(pp(e,t)){var r;return(r=t.tooltipPayload)===null||r===void 0||(r=r[0])===null||r===void 0||(r=r.payload)===null||r===void 0?void 0:r.payload}return zu(e,t)?t.payload:{}}function _ie(e){var t=e.activeTooltipItem,n=e.graphicalItem,r=e.itemData,i=Aie(n,t),o=Oie(n,t),c=r.filter(function(d,h){var p=af(o,d),y=n.props[i].filter(function(w){var S=Nie(n,t);return S(w,t)}),x=n.props[i].indexOf(y[y.length-1]),j=h===x;return p&&j}),f=r.indexOf(c[c.length-1]);return f}var dh;function el(e){"@babel/helpers - typeof";return el=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},el(e)}function Mo(){return Mo=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Mo.apply(this,arguments)}function n3(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function mt(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?n3(Object(n),!0).forEach(function(r){mr(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):n3(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Tie(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r3(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,c6(r.key),r)}}function Eie(e,t,n){return t&&r3(e.prototype,t),n&&r3(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Cie(e,t,n){return t=dm(t),Mie(e,l6()?Reflect.construct(t,n||[],dm(e).constructor):t.apply(e,n))}function Mie(e,t){if(t&&(el(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Pie(e)}function Pie(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function l6(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(l6=function(){return!!e})()}function dm(e){return dm=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},dm(e)}function Rie(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Fj(e,t)}function Fj(e,t){return Fj=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},Fj(e,t)}function mr(e,t,n){return t=c6(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function c6(e){var t=kie(e,"string");return el(t)=="symbol"?t:t+""}function kie(e,t){if(el(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(el(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Ka=(function(e){function t(n){var r;return Tie(this,t),r=Cie(this,t,[n]),mr(r,"pieRef",null),mr(r,"sectorRefs",[]),mr(r,"id",Nl("recharts-pie-")),mr(r,"handleAnimationEnd",function(){var i=r.props.onAnimationEnd;r.setState({isAnimationFinished:!0}),Ce(i)&&i()}),mr(r,"handleAnimationStart",function(){var i=r.props.onAnimationStart;r.setState({isAnimationFinished:!1}),Ce(i)&&i()}),r.state={isAnimationFinished:!n.isAnimationActive,prevIsAnimationActive:n.isAnimationActive,prevAnimationId:n.animationId,sectorToFocus:0},r}return Rie(t,e),Eie(t,[{key:"isActiveIndex",value:function(r){var i=this.props.activeIndex;return Array.isArray(i)?i.indexOf(r)!==-1:r===i}},{key:"hasActiveIndex",value:function(){var r=this.props.activeIndex;return Array.isArray(r)?r.length!==0:r||r===0}},{key:"renderLabels",value:function(r){var i=this.props.isAnimationActive;if(i&&!this.state.isAnimationFinished)return null;var o=this.props,c=o.label,f=o.labelLine,d=o.dataKey,h=o.valueKey,p=Ne(this.props,!1),y=Ne(c,!1),x=Ne(f,!1),j=c&&c.offsetRadius||20,w=r.map(function(S,b){var A=(S.startAngle+S.endAngle)/2,_=yt(S.cx,S.cy,S.outerRadius+j,A),O=mt(mt(mt(mt({},p),S),{},{stroke:"none"},y),{},{index:b,textAnchor:t.getTextAnchor(_.x,S.cx)},_),T=mt(mt(mt(mt({},p),S),{},{fill:"none",stroke:S.fill},x),{},{index:b,points:[yt(S.cx,S.cy,S.outerRadius,A),_]}),N=d;return Re(d)&&Re(h)?N="value":Re(d)&&(N=h),U.createElement(Xe,{key:"label-".concat(S.startAngle,"-").concat(S.endAngle,"-").concat(S.midAngle,"-").concat(b)},f&&t.renderLabelLineItem(f,T,"line"),t.renderLabelItem(c,O,Kt(S,N)))});return U.createElement(Xe,{className:"recharts-pie-labels"},w)}},{key:"renderSectorsStatically",value:function(r){var i=this,o=this.props,c=o.activeShape,f=o.blendStroke,d=o.inactiveShape;return r.map(function(h,p){if((h==null?void 0:h.startAngle)===0&&(h==null?void 0:h.endAngle)===0&&r.length!==1)return null;var y=i.isActiveIndex(p),x=d&&i.hasActiveIndex()?d:null,j=y?c:x,w=mt(mt({},h),{},{stroke:f?h.fill:h.stroke,tabIndex:-1});return U.createElement(Xe,Mo({ref:function(b){b&&!i.sectorRefs.includes(b)&&i.sectorRefs.push(b)},tabIndex:-1,className:"recharts-pie-sector"},Ss(i.props,h,p),{key:"sector-".concat(h==null?void 0:h.startAngle,"-").concat(h==null?void 0:h.endAngle,"-").concat(h.midAngle,"-").concat(p)}),U.createElement(o6,Mo({option:j,isActive:y,shapeType:"sector"},w)))})}},{key:"renderSectorsWithAnimation",value:function(){var r=this,i=this.props,o=i.sectors,c=i.isAnimationActive,f=i.animationBegin,d=i.animationDuration,h=i.animationEasing,p=i.animationId,y=this.state,x=y.prevSectors,j=y.prevIsAnimationActive;return U.createElement(na,{begin:f,duration:d,isActive:c,easing:h,from:{t:0},to:{t:1},key:"pie-".concat(p,"-").concat(j),onAnimationStart:this.handleAnimationStart,onAnimationEnd:this.handleAnimationEnd},function(w){var S=w.t,b=[],A=o&&o[0],_=A.startAngle;return o.forEach(function(O,T){var N=x&&x[T],E=T>0?Zn(O,"paddingAngle",0):0;if(N){var M=Kn(N.endAngle-N.startAngle,O.endAngle-O.startAngle),D=mt(mt({},O),{},{startAngle:_+E,endAngle:_+M(S)+E});b.push(D),_=D.endAngle}else{var R=O.endAngle,B=O.startAngle,q=Kn(0,R-B),z=q(S),H=mt(mt({},O),{},{startAngle:_+E,endAngle:_+z+E});b.push(H),_=H.endAngle}}),U.createElement(Xe,null,r.renderSectorsStatically(b))})}},{key:"attachKeyboardHandlers",value:function(r){var i=this;r.onkeydown=function(o){if(!o.altKey)switch(o.key){case"ArrowLeft":{var c=++i.state.sectorToFocus%i.sectorRefs.length;i.sectorRefs[c].focus(),i.setState({sectorToFocus:c});break}case"ArrowRight":{var f=--i.state.sectorToFocus<0?i.sectorRefs.length-1:i.state.sectorToFocus%i.sectorRefs.length;i.sectorRefs[f].focus(),i.setState({sectorToFocus:f});break}case"Escape":{i.sectorRefs[i.state.sectorToFocus].blur(),i.setState({sectorToFocus:0});break}}}}},{key:"renderSectors",value:function(){var r=this.props,i=r.sectors,o=r.isAnimationActive,c=this.state.prevSectors;return o&&i&&i.length&&(!c||!af(c,i))?this.renderSectorsWithAnimation():this.renderSectorsStatically(i)}},{key:"componentDidMount",value:function(){this.pieRef&&this.attachKeyboardHandlers(this.pieRef)}},{key:"render",value:function(){var r=this,i=this.props,o=i.hide,c=i.sectors,f=i.className,d=i.label,h=i.cx,p=i.cy,y=i.innerRadius,x=i.outerRadius,j=i.isAnimationActive,w=this.state.isAnimationFinished;if(o||!c||!c.length||!de(h)||!de(p)||!de(y)||!de(x))return null;var S=ze("recharts-pie",f);return U.createElement(Xe,{tabIndex:this.props.rootTabIndex,className:S,ref:function(A){r.pieRef=A}},this.renderSectors(),d&&this.renderLabels(c),en.renderCallByParent(this.props,null,!1),(!j||w)&&ka.renderCallByParent(this.props,c,!1))}}],[{key:"getDerivedStateFromProps",value:function(r,i){return i.prevIsAnimationActive!==r.isAnimationActive?{prevIsAnimationActive:r.isAnimationActive,prevAnimationId:r.animationId,curSectors:r.sectors,prevSectors:[],isAnimationFinished:!0}:r.isAnimationActive&&r.animationId!==i.prevAnimationId?{prevAnimationId:r.animationId,curSectors:r.sectors,prevSectors:i.curSectors,isAnimationFinished:!0}:r.sectors!==i.curSectors?{curSectors:r.sectors,isAnimationFinished:!0}:null}},{key:"getTextAnchor",value:function(r,i){return r>i?"start":r<i?"end":"middle"}},{key:"renderLabelLineItem",value:function(r,i,o){if(U.isValidElement(r))return U.cloneElement(r,i);if(Ce(r))return r(i);var c=ze("recharts-pie-label-line",typeof r!="boolean"?r.className:"");return U.createElement(nm,Mo({},i,{key:o,type:"linear",className:c}))}},{key:"renderLabelItem",value:function(r,i,o){if(U.isValidElement(r))return U.cloneElement(r,i);var c=o;if(Ce(r)&&(c=r(i),U.isValidElement(c)))return c;var f=ze("recharts-pie-label-text",typeof r!="boolean"&&!Ce(r)?r.className:"");return U.createElement(Ns,Mo({},i,{alignmentBaseline:"middle",className:f}),c)}}])})(P.PureComponent);dh=Ka;mr(Ka,"displayName","Pie");mr(Ka,"defaultProps",{stroke:"#fff",fill:"#808080",legendType:"rect",cx:"50%",cy:"50%",startAngle:0,endAngle:360,innerRadius:0,outerRadius:"80%",paddingAngle:0,labelLine:!0,hide:!1,minAngle:0,isAnimationActive:!Cs.isSsr,animationBegin:400,animationDuration:1500,animationEasing:"ease",nameKey:"name",blendStroke:!1,rootTabIndex:0});mr(Ka,"parseDeltaAngle",function(e,t){var n=bn(t-e),r=Math.min(Math.abs(t-e),360);return n*r});mr(Ka,"getRealPieData",function(e){var t=e.data,n=e.children,r=Ne(e,!1),i=Qn(n,Zm);return t&&t.length?t.map(function(o,c){return mt(mt(mt({payload:o},r),o),i&&i[c]&&i[c].props)}):i&&i.length?i.map(function(o){return mt(mt({},r),o.props)}):[]});mr(Ka,"parseCoordinateOfPie",function(e,t){var n=t.top,r=t.left,i=t.width,o=t.height,c=FL(i,o),f=r+jn(e.cx,i,i/2),d=n+jn(e.cy,o,o/2),h=jn(e.innerRadius,c,0),p=jn(e.outerRadius,c,c*.8),y=e.maxRadius||Math.sqrt(i*i+o*o)/2;return{cx:f,cy:d,innerRadius:h,outerRadius:p,maxRadius:y}});mr(Ka,"getComposedData",function(e){var t=e.item,n=e.offset,r=t.type.defaultProps!==void 0?mt(mt({},t.type.defaultProps),t.props):t.props,i=dh.getRealPieData(r);if(!i||!i.length)return null;var o=r.cornerRadius,c=r.startAngle,f=r.endAngle,d=r.paddingAngle,h=r.dataKey,p=r.nameKey,y=r.valueKey,x=r.tooltipType,j=Math.abs(r.minAngle),w=dh.parseCoordinateOfPie(r,n),S=dh.parseDeltaAngle(c,f),b=Math.abs(S),A=h;Re(h)&&Re(y)?(zr(!1,`Use "dataKey" to specify the value of pie,
|
||
the props "valueKey" will be deprecated in 1.1.0`),A="value"):Re(h)&&(zr(!1,`Use "dataKey" to specify the value of pie,
|
||
the props "valueKey" will be deprecated in 1.1.0`),A=y);var _=i.filter(function(D){return Kt(D,A,0)!==0}).length,O=(b>=360?_:_-1)*d,T=b-_*j-O,N=i.reduce(function(D,R){var B=Kt(R,A,0);return D+(de(B)?B:0)},0),E;if(N>0){var M;E=i.map(function(D,R){var B=Kt(D,A,0),q=Kt(D,p,R),z=(de(B)?B:0)/N,H;R?H=M.endAngle+bn(S)*d*(B!==0?1:0):H=c;var X=H+bn(S)*((B!==0?j:0)+z*T),Y=(H+X)/2,$=(w.innerRadius+w.outerRadius)/2,G=[{name:q,value:B,payload:D,dataKey:A,type:x}],Q=yt(w.cx,w.cy,$,Y);return M=mt(mt(mt({percent:z,cornerRadius:o,name:q,tooltipPayload:G,midAngle:Y,middleRadius:$,tooltipPosition:Q},D),w),{},{value:Kt(D,A),startAngle:H,endAngle:X,payload:D,paddingAngle:bn(S)*d}),M})}return mt(mt({},w),{},{sectors:E,data:i})});var H0,a3;function Die(){if(a3)return H0;a3=1;var e=Math.ceil,t=Math.max;function n(r,i,o,c){for(var f=-1,d=t(e((i-r)/(o||1)),0),h=Array(d);d--;)h[c?d:++f]=r,r+=o;return h}return H0=n,H0}var F0,i3;function u6(){if(i3)return F0;i3=1;var e=R5(),t=1/0,n=17976931348623157e292;function r(i){if(!i)return i===0?i:0;if(i=e(i),i===t||i===-t){var o=i<0?-1:1;return o*n}return i===i?i:0}return F0=r,F0}var G0,s3;function zie(){if(s3)return G0;s3=1;var e=Die(),t=Wm(),n=u6();function r(i){return function(o,c,f){return f&&typeof f!="number"&&t(o,c,f)&&(c=f=void 0),o=n(o),c===void 0?(c=o,o=0):c=n(c),f=f===void 0?o<c?1:-1:n(f),e(o,c,f,i)}}return G0=r,G0}var K0,o3;function Lie(){if(o3)return K0;o3=1;var e=zie(),t=e();return K0=t,K0}var $ie=Lie();const hm=at($ie);function Lu(e){"@babel/helpers - typeof";return Lu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Lu(e)}function l3(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function c3(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?l3(Object(n),!0).forEach(function(r){f6(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l3(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function f6(e,t,n){return t=Bie(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Bie(e){var t=qie(e,"string");return Lu(t)=="symbol"?t:t+""}function qie(e,t){if(Lu(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Lu(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Iie=["Webkit","Moz","O","ms"],Uie=function(t,n){var r=t.replace(/(\w)/,function(o){return o.toUpperCase()}),i=Iie.reduce(function(o,c){return c3(c3({},o),{},f6({},c+r,n))},{});return i[t]=n,i};function tl(e){"@babel/helpers - typeof";return tl=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},tl(e)}function mm(){return mm=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},mm.apply(this,arguments)}function u3(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Y0(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?u3(Object(n),!0).forEach(function(r){Hn(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):u3(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Vie(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function f3(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,h6(r.key),r)}}function Hie(e,t,n){return t&&f3(e.prototype,t),n&&f3(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Fie(e,t,n){return t=pm(t),Gie(e,d6()?Reflect.construct(t,n||[],pm(e).constructor):t.apply(e,n))}function Gie(e,t){if(t&&(tl(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Kie(e)}function Kie(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function d6(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(d6=function(){return!!e})()}function pm(e){return pm=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},pm(e)}function Yie(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Gj(e,t)}function Gj(e,t){return Gj=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},Gj(e,t)}function Hn(e,t,n){return t=h6(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function h6(e){var t=Xie(e,"string");return tl(t)=="symbol"?t:t+""}function Xie(e,t){if(tl(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(tl(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Wie=function(t){var n=t.data,r=t.startIndex,i=t.endIndex,o=t.x,c=t.width,f=t.travellerWidth;if(!n||!n.length)return{};var d=n.length,h=Wc().domain(hm(0,d)).range([o,o+c-f]),p=h.domain().map(function(y){return h(y)});return{isTextActive:!1,isSlideMoving:!1,isTravellerMoving:!1,isTravellerFocused:!1,startX:h(r),endX:h(i),scale:h,scaleValues:p}},d3=function(t){return t.changedTouches&&!!t.changedTouches.length},nl=(function(e){function t(n){var r;return Vie(this,t),r=Fie(this,t,[n]),Hn(r,"handleDrag",function(i){r.leaveTimer&&(clearTimeout(r.leaveTimer),r.leaveTimer=null),r.state.isTravellerMoving?r.handleTravellerMove(i):r.state.isSlideMoving&&r.handleSlideDrag(i)}),Hn(r,"handleTouchMove",function(i){i.changedTouches!=null&&i.changedTouches.length>0&&r.handleDrag(i.changedTouches[0])}),Hn(r,"handleDragEnd",function(){r.setState({isTravellerMoving:!1,isSlideMoving:!1},function(){var i=r.props,o=i.endIndex,c=i.onDragEnd,f=i.startIndex;c==null||c({endIndex:o,startIndex:f})}),r.detachDragEndListener()}),Hn(r,"handleLeaveWrapper",function(){(r.state.isTravellerMoving||r.state.isSlideMoving)&&(r.leaveTimer=window.setTimeout(r.handleDragEnd,r.props.leaveTimeOut))}),Hn(r,"handleEnterSlideOrTraveller",function(){r.setState({isTextActive:!0})}),Hn(r,"handleLeaveSlideOrTraveller",function(){r.setState({isTextActive:!1})}),Hn(r,"handleSlideDragStart",function(i){var o=d3(i)?i.changedTouches[0]:i;r.setState({isTravellerMoving:!1,isSlideMoving:!0,slideMoveStartX:o.pageX}),r.attachDragEndListener()}),r.travellerDragStartHandlers={startX:r.handleTravellerDragStart.bind(r,"startX"),endX:r.handleTravellerDragStart.bind(r,"endX")},r.state={},r}return Yie(t,e),Hie(t,[{key:"componentWillUnmount",value:function(){this.leaveTimer&&(clearTimeout(this.leaveTimer),this.leaveTimer=null),this.detachDragEndListener()}},{key:"getIndex",value:function(r){var i=r.startX,o=r.endX,c=this.state.scaleValues,f=this.props,d=f.gap,h=f.data,p=h.length-1,y=Math.min(i,o),x=Math.max(i,o),j=t.getIndexInRange(c,y),w=t.getIndexInRange(c,x);return{startIndex:j-j%d,endIndex:w===p?p:w-w%d}}},{key:"getTextOfTick",value:function(r){var i=this.props,o=i.data,c=i.tickFormatter,f=i.dataKey,d=Kt(o[r],f,r);return Ce(c)?c(d,r):d}},{key:"attachDragEndListener",value:function(){window.addEventListener("mouseup",this.handleDragEnd,!0),window.addEventListener("touchend",this.handleDragEnd,!0),window.addEventListener("mousemove",this.handleDrag,!0)}},{key:"detachDragEndListener",value:function(){window.removeEventListener("mouseup",this.handleDragEnd,!0),window.removeEventListener("touchend",this.handleDragEnd,!0),window.removeEventListener("mousemove",this.handleDrag,!0)}},{key:"handleSlideDrag",value:function(r){var i=this.state,o=i.slideMoveStartX,c=i.startX,f=i.endX,d=this.props,h=d.x,p=d.width,y=d.travellerWidth,x=d.startIndex,j=d.endIndex,w=d.onChange,S=r.pageX-o;S>0?S=Math.min(S,h+p-y-f,h+p-y-c):S<0&&(S=Math.max(S,h-c,h-f));var b=this.getIndex({startX:c+S,endX:f+S});(b.startIndex!==x||b.endIndex!==j)&&w&&w(b),this.setState({startX:c+S,endX:f+S,slideMoveStartX:r.pageX})}},{key:"handleTravellerDragStart",value:function(r,i){var o=d3(i)?i.changedTouches[0]:i;this.setState({isSlideMoving:!1,isTravellerMoving:!0,movingTravellerId:r,brushMoveStartX:o.pageX}),this.attachDragEndListener()}},{key:"handleTravellerMove",value:function(r){var i=this.state,o=i.brushMoveStartX,c=i.movingTravellerId,f=i.endX,d=i.startX,h=this.state[c],p=this.props,y=p.x,x=p.width,j=p.travellerWidth,w=p.onChange,S=p.gap,b=p.data,A={startX:this.state.startX,endX:this.state.endX},_=r.pageX-o;_>0?_=Math.min(_,y+x-j-h):_<0&&(_=Math.max(_,y-h)),A[c]=h+_;var O=this.getIndex(A),T=O.startIndex,N=O.endIndex,E=function(){var D=b.length-1;return c==="startX"&&(f>d?T%S===0:N%S===0)||f<d&&N===D||c==="endX"&&(f>d?N%S===0:T%S===0)||f>d&&N===D};this.setState(Hn(Hn({},c,h+_),"brushMoveStartX",r.pageX),function(){w&&E()&&w(O)})}},{key:"handleTravellerMoveKeyboard",value:function(r,i){var o=this,c=this.state,f=c.scaleValues,d=c.startX,h=c.endX,p=this.state[i],y=f.indexOf(p);if(y!==-1){var x=y+r;if(!(x===-1||x>=f.length)){var j=f[x];i==="startX"&&j>=h||i==="endX"&&j<=d||this.setState(Hn({},i,j),function(){o.props.onChange(o.getIndex({startX:o.state.startX,endX:o.state.endX}))})}}}},{key:"renderBackground",value:function(){var r=this.props,i=r.x,o=r.y,c=r.width,f=r.height,d=r.fill,h=r.stroke;return U.createElement("rect",{stroke:h,fill:d,x:i,y:o,width:c,height:f})}},{key:"renderPanorama",value:function(){var r=this.props,i=r.x,o=r.y,c=r.width,f=r.height,d=r.data,h=r.children,p=r.padding,y=P.Children.only(h);return y?U.cloneElement(y,{x:i,y:o,width:c,height:f,margin:p,compact:!0,data:d}):null}},{key:"renderTravellerLayer",value:function(r,i){var o,c,f=this,d=this.props,h=d.y,p=d.travellerWidth,y=d.height,x=d.traveller,j=d.ariaLabel,w=d.data,S=d.startIndex,b=d.endIndex,A=Math.max(r,this.props.x),_=Y0(Y0({},Ne(this.props,!1)),{},{x:A,y:h,width:p,height:y}),O=j||"Min value: ".concat((o=w[S])===null||o===void 0?void 0:o.name,", Max value: ").concat((c=w[b])===null||c===void 0?void 0:c.name);return U.createElement(Xe,{tabIndex:0,role:"slider","aria-label":O,"aria-valuenow":r,className:"recharts-brush-traveller",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.travellerDragStartHandlers[i],onTouchStart:this.travellerDragStartHandlers[i],onKeyDown:function(N){["ArrowLeft","ArrowRight"].includes(N.key)&&(N.preventDefault(),N.stopPropagation(),f.handleTravellerMoveKeyboard(N.key==="ArrowRight"?1:-1,i))},onFocus:function(){f.setState({isTravellerFocused:!0})},onBlur:function(){f.setState({isTravellerFocused:!1})},style:{cursor:"col-resize"}},t.renderTraveller(x,_))}},{key:"renderSlide",value:function(r,i){var o=this.props,c=o.y,f=o.height,d=o.stroke,h=o.travellerWidth,p=Math.min(r,i)+h,y=Math.max(Math.abs(i-r)-h,0);return U.createElement("rect",{className:"recharts-brush-slide",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.handleSlideDragStart,onTouchStart:this.handleSlideDragStart,style:{cursor:"move"},stroke:"none",fill:d,fillOpacity:.2,x:p,y:c,width:y,height:f})}},{key:"renderText",value:function(){var r=this.props,i=r.startIndex,o=r.endIndex,c=r.y,f=r.height,d=r.travellerWidth,h=r.stroke,p=this.state,y=p.startX,x=p.endX,j=5,w={pointerEvents:"none",fill:h};return U.createElement(Xe,{className:"recharts-brush-texts"},U.createElement(Ns,mm({textAnchor:"end",verticalAnchor:"middle",x:Math.min(y,x)-j,y:c+f/2},w),this.getTextOfTick(i)),U.createElement(Ns,mm({textAnchor:"start",verticalAnchor:"middle",x:Math.max(y,x)+d+j,y:c+f/2},w),this.getTextOfTick(o)))}},{key:"render",value:function(){var r=this.props,i=r.data,o=r.className,c=r.children,f=r.x,d=r.y,h=r.width,p=r.height,y=r.alwaysShowText,x=this.state,j=x.startX,w=x.endX,S=x.isTextActive,b=x.isSlideMoving,A=x.isTravellerMoving,_=x.isTravellerFocused;if(!i||!i.length||!de(f)||!de(d)||!de(h)||!de(p)||h<=0||p<=0)return null;var O=ze("recharts-brush",o),T=U.Children.count(c)===1,N=Uie("userSelect","none");return U.createElement(Xe,{className:O,onMouseLeave:this.handleLeaveWrapper,onTouchMove:this.handleTouchMove,style:N},this.renderBackground(),T&&this.renderPanorama(),this.renderSlide(j,w),this.renderTravellerLayer(j,"startX"),this.renderTravellerLayer(w,"endX"),(S||b||A||_||y)&&this.renderText())}}],[{key:"renderDefaultTraveller",value:function(r){var i=r.x,o=r.y,c=r.width,f=r.height,d=r.stroke,h=Math.floor(o+f/2)-1;return U.createElement(U.Fragment,null,U.createElement("rect",{x:i,y:o,width:c,height:f,fill:d,stroke:"none"}),U.createElement("line",{x1:i+1,y1:h,x2:i+c-1,y2:h,fill:"none",stroke:"#fff"}),U.createElement("line",{x1:i+1,y1:h+2,x2:i+c-1,y2:h+2,fill:"none",stroke:"#fff"}))}},{key:"renderTraveller",value:function(r,i){var o;return U.isValidElement(r)?o=U.cloneElement(r,i):Ce(r)?o=r(i):o=t.renderDefaultTraveller(i),o}},{key:"getDerivedStateFromProps",value:function(r,i){var o=r.data,c=r.width,f=r.x,d=r.travellerWidth,h=r.updateId,p=r.startIndex,y=r.endIndex;if(o!==i.prevData||h!==i.prevUpdateId)return Y0({prevData:o,prevTravellerWidth:d,prevUpdateId:h,prevX:f,prevWidth:c},o&&o.length?Wie({data:o,width:c,x:f,travellerWidth:d,startIndex:p,endIndex:y}):{scale:null,scaleValues:null});if(i.scale&&(c!==i.prevWidth||f!==i.prevX||d!==i.prevTravellerWidth)){i.scale.range([f,f+c-d]);var x=i.scale.domain().map(function(j){return i.scale(j)});return{prevData:o,prevTravellerWidth:d,prevUpdateId:h,prevX:f,prevWidth:c,startX:i.scale(r.startIndex),endX:i.scale(r.endIndex),scaleValues:x}}return null}},{key:"getIndexInRange",value:function(r,i){for(var o=r.length,c=0,f=o-1;f-c>1;){var d=Math.floor((c+f)/2);r[d]>i?f=d:c=d}return i>=r[f]?f:c}}])})(P.PureComponent);Hn(nl,"displayName","Brush");Hn(nl,"defaultProps",{height:40,travellerWidth:5,gap:1,fill:"#fff",stroke:"#666",padding:{top:1,right:1,bottom:1,left:1},leaveTimeOut:1e3,alwaysShowText:!1});var X0,h3;function Zie(){if(h3)return X0;h3=1;var e=jS();function t(n,r){var i;return e(n,function(o,c,f){return i=r(o,c,f),!i}),!!i}return X0=t,X0}var W0,m3;function Qie(){if(m3)return W0;m3=1;var e=u5(),t=aa(),n=Zie(),r=Rn(),i=Wm();function o(c,f,d){var h=r(c)?e:n;return d&&i(c,f,d)&&(f=void 0),h(c,t(f,3))}return W0=o,W0}var Jie=Qie();const ese=at(Jie);var Zr=function(t,n){var r=t.alwaysShow,i=t.ifOverflow;return r&&(i="extendDomain"),i===n},Z0,p3;function tse(){if(p3)return Z0;p3=1;var e=T5();function t(n,r,i){r=="__proto__"&&e?e(n,r,{configurable:!0,enumerable:!0,value:i,writable:!0}):n[r]=i}return Z0=t,Z0}var Q0,y3;function nse(){if(y3)return Q0;y3=1;var e=tse(),t=O5(),n=aa();function r(i,o){var c={};return o=n(o,3),t(i,function(f,d,h){e(c,d,o(f,d,h))}),c}return Q0=r,Q0}var rse=nse();const ase=at(rse);var J0,x3;function ise(){if(x3)return J0;x3=1;function e(t,n){for(var r=-1,i=t==null?0:t.length;++r<i;)if(!n(t[r],r,t))return!1;return!0}return J0=e,J0}var e1,g3;function sse(){if(g3)return e1;g3=1;var e=jS();function t(n,r){var i=!0;return e(n,function(o,c,f){return i=!!r(o,c,f),i}),i}return e1=t,e1}var t1,v3;function ose(){if(v3)return t1;v3=1;var e=ise(),t=sse(),n=aa(),r=Rn(),i=Wm();function o(c,f,d){var h=r(c)?e:t;return d&&i(c,f,d)&&(f=void 0),h(c,n(f,3))}return t1=o,t1}var lse=ose();const m6=at(lse);var cse=["x","y"];function $u(e){"@babel/helpers - typeof";return $u=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},$u(e)}function Kj(){return Kj=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Kj.apply(this,arguments)}function b3(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function $c(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?b3(Object(n),!0).forEach(function(r){use(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):b3(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function use(e,t,n){return t=fse(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function fse(e){var t=dse(e,"string");return $u(t)=="symbol"?t:t+""}function dse(e,t){if($u(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if($u(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function hse(e,t){if(e==null)return{};var n=mse(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function mse(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function pse(e,t){var n=e.x,r=e.y,i=hse(e,cse),o="".concat(n),c=parseInt(o,10),f="".concat(r),d=parseInt(f,10),h="".concat(t.height||i.height),p=parseInt(h,10),y="".concat(t.width||i.width),x=parseInt(y,10);return $c($c($c($c($c({},t),i),c?{x:c}:{}),d?{y:d}:{}),{},{height:p,width:x,name:t.name,radius:t.radius})}function j3(e){return U.createElement(o6,Kj({shapeType:"rectangle",propTransformer:pse,activeClassName:"recharts-active-bar"},e))}var yse=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return function(r,i){if(typeof t=="number")return t;var o=de(r)||zG(r);return o?t(r,i):(o||Os(),n)}},xse=["value","background"],p6;function rl(e){"@babel/helpers - typeof";return rl=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},rl(e)}function gse(e,t){if(e==null)return{};var n=vse(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function vse(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function ym(){return ym=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ym.apply(this,arguments)}function w3(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function qt(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?w3(Object(n),!0).forEach(function(r){_i(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):w3(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function bse(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function S3(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,x6(r.key),r)}}function jse(e,t,n){return t&&S3(e.prototype,t),n&&S3(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function wse(e,t,n){return t=xm(t),Sse(e,y6()?Reflect.construct(t,n||[],xm(e).constructor):t.apply(e,n))}function Sse(e,t){if(t&&(rl(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Nse(e)}function Nse(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function y6(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(y6=function(){return!!e})()}function xm(e){return xm=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},xm(e)}function Ase(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Yj(e,t)}function Yj(e,t){return Yj=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},Yj(e,t)}function _i(e,t,n){return t=x6(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function x6(e){var t=Ose(e,"string");return rl(t)=="symbol"?t:t+""}function Ose(e,t){if(rl(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(rl(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Mi=(function(e){function t(){var n;bse(this,t);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return n=wse(this,t,[].concat(i)),_i(n,"state",{isAnimationFinished:!1}),_i(n,"id",Nl("recharts-bar-")),_i(n,"handleAnimationEnd",function(){var c=n.props.onAnimationEnd;n.setState({isAnimationFinished:!0}),c&&c()}),_i(n,"handleAnimationStart",function(){var c=n.props.onAnimationStart;n.setState({isAnimationFinished:!1}),c&&c()}),n}return Ase(t,e),jse(t,[{key:"renderRectanglesStatically",value:function(r){var i=this,o=this.props,c=o.shape,f=o.dataKey,d=o.activeIndex,h=o.activeBar,p=Ne(this.props,!1);return r&&r.map(function(y,x){var j=x===d,w=j?h:c,S=qt(qt(qt({},p),y),{},{isActive:j,option:w,index:x,dataKey:f,onAnimationStart:i.handleAnimationStart,onAnimationEnd:i.handleAnimationEnd});return U.createElement(Xe,ym({className:"recharts-bar-rectangle"},Ss(i.props,y,x),{key:"rectangle-".concat(y==null?void 0:y.x,"-").concat(y==null?void 0:y.y,"-").concat(y==null?void 0:y.value,"-").concat(x)}),U.createElement(j3,S))})}},{key:"renderRectanglesWithAnimation",value:function(){var r=this,i=this.props,o=i.data,c=i.layout,f=i.isAnimationActive,d=i.animationBegin,h=i.animationDuration,p=i.animationEasing,y=i.animationId,x=this.state.prevData;return U.createElement(na,{begin:d,duration:h,isActive:f,easing:p,from:{t:0},to:{t:1},key:"bar-".concat(y),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(j){var w=j.t,S=o.map(function(b,A){var _=x&&x[A];if(_){var O=Kn(_.x,b.x),T=Kn(_.y,b.y),N=Kn(_.width,b.width),E=Kn(_.height,b.height);return qt(qt({},b),{},{x:O(w),y:T(w),width:N(w),height:E(w)})}if(c==="horizontal"){var M=Kn(0,b.height),D=M(w);return qt(qt({},b),{},{y:b.y+b.height-D,height:D})}var R=Kn(0,b.width),B=R(w);return qt(qt({},b),{},{width:B})});return U.createElement(Xe,null,r.renderRectanglesStatically(S))})}},{key:"renderRectangles",value:function(){var r=this.props,i=r.data,o=r.isAnimationActive,c=this.state.prevData;return o&&i&&i.length&&(!c||!af(c,i))?this.renderRectanglesWithAnimation():this.renderRectanglesStatically(i)}},{key:"renderBackground",value:function(){var r=this,i=this.props,o=i.data,c=i.dataKey,f=i.activeIndex,d=Ne(this.props.background,!1);return o.map(function(h,p){h.value;var y=h.background,x=gse(h,xse);if(!y)return null;var j=qt(qt(qt(qt(qt({},x),{},{fill:"#eee"},y),d),Ss(r.props,h,p)),{},{onAnimationStart:r.handleAnimationStart,onAnimationEnd:r.handleAnimationEnd,dataKey:c,index:p,className:"recharts-bar-background-rectangle"});return U.createElement(j3,ym({key:"background-bar-".concat(p),option:r.props.background,isActive:p===f},j))})}},{key:"renderErrorBar",value:function(r,i){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var o=this.props,c=o.data,f=o.xAxis,d=o.yAxis,h=o.layout,p=o.children,y=Qn(p,sf);if(!y)return null;var x=h==="vertical"?c[0].height/2:c[0].width/2,j=function(b,A){var _=Array.isArray(b.value)?b.value[1]:b.value;return{x:b.x,y:b.y,value:_,errorVal:Kt(b,A)}},w={clipPath:r?"url(#clipPath-".concat(i,")"):null};return U.createElement(Xe,w,y.map(function(S){return U.cloneElement(S,{key:"error-bar-".concat(i,"-").concat(S.props.dataKey),data:c,xAxis:f,yAxis:d,layout:h,offset:x,dataPointFormatter:j})}))}},{key:"render",value:function(){var r=this.props,i=r.hide,o=r.data,c=r.className,f=r.xAxis,d=r.yAxis,h=r.left,p=r.top,y=r.width,x=r.height,j=r.isAnimationActive,w=r.background,S=r.id;if(i||!o||!o.length)return null;var b=this.state.isAnimationFinished,A=ze("recharts-bar",c),_=f&&f.allowDataOverflow,O=d&&d.allowDataOverflow,T=_||O,N=Re(S)?this.id:S;return U.createElement(Xe,{className:A},_||O?U.createElement("defs",null,U.createElement("clipPath",{id:"clipPath-".concat(N)},U.createElement("rect",{x:_?h:h-y/2,y:O?p:p-x/2,width:_?y:y*2,height:O?x:x*2}))):null,U.createElement(Xe,{className:"recharts-bar-rectangles",clipPath:T?"url(#clipPath-".concat(N,")"):null},w?this.renderBackground():null,this.renderRectangles()),this.renderErrorBar(T,N),(!j||b)&&ka.renderCallByParent(this.props,o))}}],[{key:"getDerivedStateFromProps",value:function(r,i){return r.animationId!==i.prevAnimationId?{prevAnimationId:r.animationId,curData:r.data,prevData:i.curData}:r.data!==i.curData?{curData:r.data}:null}}])})(P.PureComponent);p6=Mi;_i(Mi,"displayName","Bar");_i(Mi,"defaultProps",{xAxisId:0,yAxisId:0,legendType:"rect",minPointSize:0,hide:!1,data:[],layout:"vertical",activeBar:!1,isAnimationActive:!Cs.isSsr,animationBegin:0,animationDuration:400,animationEasing:"ease"});_i(Mi,"getComposedData",function(e){var t=e.props,n=e.item,r=e.barPosition,i=e.bandSize,o=e.xAxis,c=e.yAxis,f=e.xAxisTicks,d=e.yAxisTicks,h=e.stackedData,p=e.dataStartIndex,y=e.displayedData,x=e.offset,j=Zee(r,n);if(!j)return null;var w=t.layout,S=n.type.defaultProps,b=S!==void 0?qt(qt({},S),n.props):n.props,A=b.dataKey,_=b.children,O=b.minPointSize,T=w==="horizontal"?c:o,N=h?T.scale.domain():null,E=ate({numericAxis:T}),M=Qn(_,Zm),D=y.map(function(R,B){var q,z,H,X,Y,$;h?q=Qee(h[p+B],N):(q=Kt(R,A),Array.isArray(q)||(q=[E,q]));var G=yse(O,p6.defaultProps.minPointSize)(q[1],B);if(w==="horizontal"){var Q,ie=[c.scale(q[0]),c.scale(q[1])],le=ie[0],L=ie[1];z=ZR({axis:o,ticks:f,bandSize:i,offset:j.offset,entry:R,index:B}),H=(Q=L??le)!==null&&Q!==void 0?Q:void 0,X=j.size;var F=le-L;if(Y=Number.isNaN(F)?0:F,$={x:z,y:c.y,width:X,height:c.height},Math.abs(G)>0&&Math.abs(Y)<Math.abs(G)){var ae=bn(Y||G)*(Math.abs(G)-Math.abs(Y));H-=ae,Y+=ae}}else{var fe=[o.scale(q[0]),o.scale(q[1])],xe=fe[0],Ae=fe[1];if(z=xe,H=ZR({axis:c,ticks:d,bandSize:i,offset:j.offset,entry:R,index:B}),X=Ae-xe,Y=j.size,$={x:o.x,y:H,width:o.width,height:Y},Math.abs(G)>0&&Math.abs(X)<Math.abs(G)){var qe=bn(X||G)*(Math.abs(G)-Math.abs(X));X+=qe}}return qt(qt(qt({},R),{},{x:z,y:H,width:X,height:Y,value:h?q:q[1],payload:R,background:$},M&&M[B]&&M[B].props),{},{tooltipPayload:[VL(n,R)],tooltipPosition:{x:z+X/2,y:H+Y/2}})});return qt({data:D,layout:w},x)});function Bu(e){"@babel/helpers - typeof";return Bu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Bu(e)}function _se(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function N3(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,g6(r.key),r)}}function Tse(e,t,n){return t&&N3(e.prototype,t),n&&N3(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function A3(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Cr(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?A3(Object(n),!0).forEach(function(r){yp(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):A3(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function yp(e,t,n){return t=g6(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function g6(e){var t=Ese(e,"string");return Bu(t)=="symbol"?t:t+""}function Ese(e,t){if(Bu(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Bu(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var v6=function(t,n,r,i,o){var c=t.width,f=t.height,d=t.layout,h=t.children,p=Object.keys(n),y={left:r.left,leftMirror:r.left,right:c-r.right,rightMirror:c-r.right,top:r.top,topMirror:r.top,bottom:f-r.bottom,bottomMirror:f-r.bottom},x=!!Fn(h,Mi);return p.reduce(function(j,w){var S=n[w],b=S.orientation,A=S.domain,_=S.padding,O=_===void 0?{}:_,T=S.mirror,N=S.reversed,E="".concat(b).concat(T?"Mirror":""),M,D,R,B,q;if(S.type==="number"&&(S.padding==="gap"||S.padding==="no-gap")){var z=A[1]-A[0],H=1/0,X=S.categoricalDomain.sort(BG);if(X.forEach(function(fe,xe){xe>0&&(H=Math.min((fe||0)-(X[xe-1]||0),H))}),Number.isFinite(H)){var Y=H/z,$=S.layout==="vertical"?r.height:r.width;if(S.padding==="gap"&&(M=Y*$/2),S.padding==="no-gap"){var G=jn(t.barCategoryGap,Y*$),Q=Y*$/2;M=Q-G-(Q-G)/$*G}}}i==="xAxis"?D=[r.left+(O.left||0)+(M||0),r.left+r.width-(O.right||0)-(M||0)]:i==="yAxis"?D=d==="horizontal"?[r.top+r.height-(O.bottom||0),r.top+(O.top||0)]:[r.top+(O.top||0)+(M||0),r.top+r.height-(O.bottom||0)-(M||0)]:D=S.range,N&&(D=[D[1],D[0]]);var ie=BL(S,o,x),le=ie.scale,L=ie.realScaleType;le.domain(A).range(D),qL(le);var F=IL(le,Cr(Cr({},S),{},{realScaleType:L}));i==="xAxis"?(q=b==="top"&&!T||b==="bottom"&&T,R=r.left,B=y[E]-q*S.height):i==="yAxis"&&(q=b==="left"&&!T||b==="right"&&T,R=y[E]-q*S.width,B=r.top);var ae=Cr(Cr(Cr({},S),F),{},{realScaleType:L,x:R,y:B,scale:le,width:i==="xAxis"?r.width:S.width,height:i==="yAxis"?r.height:S.height});return ae.bandSize=Jh(ae,F),!S.hide&&i==="xAxis"?y[E]+=(q?-1:1)*ae.height:S.hide||(y[E]+=(q?-1:1)*ae.width),Cr(Cr({},j),{},yp({},w,ae))},{})},b6=function(t,n){var r=t.x,i=t.y,o=n.x,c=n.y;return{x:Math.min(r,o),y:Math.min(i,c),width:Math.abs(o-r),height:Math.abs(c-i)}},Cse=function(t){var n=t.x1,r=t.y1,i=t.x2,o=t.y2;return b6({x:n,y:r},{x:i,y:o})},j6=(function(){function e(t){_se(this,e),this.scale=t}return Tse(e,[{key:"domain",get:function(){return this.scale.domain}},{key:"range",get:function(){return this.scale.range}},{key:"rangeMin",get:function(){return this.range()[0]}},{key:"rangeMax",get:function(){return this.range()[1]}},{key:"bandwidth",get:function(){return this.scale.bandwidth}},{key:"apply",value:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=r.bandAware,o=r.position;if(n!==void 0){if(o)switch(o){case"start":return this.scale(n);case"middle":{var c=this.bandwidth?this.bandwidth()/2:0;return this.scale(n)+c}case"end":{var f=this.bandwidth?this.bandwidth():0;return this.scale(n)+f}default:return this.scale(n)}if(i){var d=this.bandwidth?this.bandwidth()/2:0;return this.scale(n)+d}return this.scale(n)}}},{key:"isInRange",value:function(n){var r=this.range(),i=r[0],o=r[r.length-1];return i<=o?n>=i&&n<=o:n>=o&&n<=i}}],[{key:"create",value:function(n){return new e(n)}}])})();yp(j6,"EPS",1e-4);var WS=function(t){var n=Object.keys(t).reduce(function(r,i){return Cr(Cr({},r),{},yp({},i,j6.create(t[i])))},{});return Cr(Cr({},n),{},{apply:function(i){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},c=o.bandAware,f=o.position;return ase(i,function(d,h){return n[h].apply(d,{bandAware:c,position:f})})},isInRange:function(i){return m6(i,function(o,c){return n[c].isInRange(o)})}})};function Mse(e){return(e%180+180)%180}var Pse=function(t){var n=t.width,r=t.height,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,o=Mse(i),c=o*Math.PI/180,f=Math.atan(r/n),d=c>f&&c<Math.PI-f?r/Math.sin(c):n/Math.cos(c);return Math.abs(d)},n1,O3;function Rse(){if(O3)return n1;O3=1;var e=aa(),t=Ju(),n=Ym();function r(i){return function(o,c,f){var d=Object(o);if(!t(o)){var h=e(c,3);o=n(o),c=function(y){return h(d[y],y,d)}}var p=i(o,c,f);return p>-1?d[h?o[p]:p]:void 0}}return n1=r,n1}var r1,_3;function kse(){if(_3)return r1;_3=1;var e=u6();function t(n){var r=e(n),i=r%1;return r===r?i?r-i:r:0}return r1=t,r1}var a1,T3;function Dse(){if(T3)return a1;T3=1;var e=j5(),t=aa(),n=kse(),r=Math.max;function i(o,c,f){var d=o==null?0:o.length;if(!d)return-1;var h=f==null?0:n(f);return h<0&&(h=r(d+h,0)),e(o,t(c,3),h)}return a1=i,a1}var i1,E3;function zse(){if(E3)return i1;E3=1;var e=Rse(),t=Dse(),n=e(t);return i1=n,i1}var Lse=zse();const $se=at(Lse);var Bse=Lz();const qse=at(Bse);var Ise=qse(function(e){return{x:e.left,y:e.top,width:e.width,height:e.height}},function(e){return["l",e.left,"t",e.top,"w",e.width,"h",e.height].join("")}),ZS=P.createContext(void 0),QS=P.createContext(void 0),w6=P.createContext(void 0),S6=P.createContext({}),N6=P.createContext(void 0),A6=P.createContext(0),O6=P.createContext(0),C3=function(t){var n=t.state,r=n.xAxisMap,i=n.yAxisMap,o=n.offset,c=t.clipPathId,f=t.children,d=t.width,h=t.height,p=Ise(o);return U.createElement(ZS.Provider,{value:r},U.createElement(QS.Provider,{value:i},U.createElement(S6.Provider,{value:o},U.createElement(w6.Provider,{value:p},U.createElement(N6.Provider,{value:c},U.createElement(A6.Provider,{value:h},U.createElement(O6.Provider,{value:d},f)))))))},Use=function(){return P.useContext(N6)},_6=function(t){var n=P.useContext(ZS);n==null&&Os();var r=n[t];return r==null&&Os(),r},Vse=function(){var t=P.useContext(ZS);return Ni(t)},Hse=function(){var t=P.useContext(QS),n=$se(t,function(r){return m6(r.domain,Number.isFinite)});return n||Ni(t)},T6=function(t){var n=P.useContext(QS);n==null&&Os();var r=n[t];return r==null&&Os(),r},Fse=function(){var t=P.useContext(w6);return t},Gse=function(){return P.useContext(S6)},JS=function(){return P.useContext(O6)},eN=function(){return P.useContext(A6)};function al(e){"@babel/helpers - typeof";return al=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},al(e)}function Kse(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Yse(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,C6(r.key),r)}}function Xse(e,t,n){return t&&Yse(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Wse(e,t,n){return t=gm(t),Zse(e,E6()?Reflect.construct(t,n||[],gm(e).constructor):t.apply(e,n))}function Zse(e,t){if(t&&(al(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Qse(e)}function Qse(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function E6(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(E6=function(){return!!e})()}function gm(e){return gm=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},gm(e)}function Jse(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Xj(e,t)}function Xj(e,t){return Xj=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},Xj(e,t)}function M3(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function P3(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?M3(Object(n),!0).forEach(function(r){tN(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):M3(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function tN(e,t,n){return t=C6(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function C6(e){var t=eoe(e,"string");return al(t)=="symbol"?t:t+""}function eoe(e,t){if(al(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(al(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function toe(e,t){return ioe(e)||aoe(e,t)||roe(e,t)||noe()}function noe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function roe(e,t){if(e){if(typeof e=="string")return R3(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return R3(e,t)}}function R3(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function aoe(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,c,f=[],d=!0,h=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(d=(r=o.call(n)).done)&&(f.push(r.value),f.length!==t);d=!0);}catch(p){h=!0,i=p}finally{try{if(!d&&n.return!=null&&(c=n.return(),Object(c)!==c))return}finally{if(h)throw i}}return f}}function ioe(e){if(Array.isArray(e))return e}function Wj(){return Wj=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Wj.apply(this,arguments)}var soe=function(t,n){var r;return U.isValidElement(t)?r=U.cloneElement(t,n):Ce(t)?r=t(n):r=U.createElement("line",Wj({},n,{className:"recharts-reference-line-line"})),r},ooe=function(t,n,r,i,o,c,f,d,h){var p=o.x,y=o.y,x=o.width,j=o.height;if(r){var w=h.y,S=t.y.apply(w,{position:c});if(Zr(h,"discard")&&!t.y.isInRange(S))return null;var b=[{x:p+x,y:S},{x:p,y:S}];return d==="left"?b.reverse():b}if(n){var A=h.x,_=t.x.apply(A,{position:c});if(Zr(h,"discard")&&!t.x.isInRange(_))return null;var O=[{x:_,y:y+j},{x:_,y}];return f==="top"?O.reverse():O}if(i){var T=h.segment,N=T.map(function(E){return t.apply(E,{position:c})});return Zr(h,"discard")&&ese(N,function(E){return!t.isInRange(E)})?null:N}return null};function loe(e){var t=e.x,n=e.y,r=e.segment,i=e.xAxisId,o=e.yAxisId,c=e.shape,f=e.className,d=e.alwaysShow,h=Use(),p=_6(i),y=T6(o),x=Fse();if(!h||!x)return null;zr(d===void 0,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.');var j=WS({x:p.scale,y:y.scale}),w=Xt(t),S=Xt(n),b=r&&r.length===2,A=ooe(j,w,S,b,x,e.position,p.orientation,y.orientation,e);if(!A)return null;var _=toe(A,2),O=_[0],T=O.x,N=O.y,E=_[1],M=E.x,D=E.y,R=Zr(e,"hidden")?"url(#".concat(h,")"):void 0,B=P3(P3({clipPath:R},Ne(e,!0)),{},{x1:T,y1:N,x2:M,y2:D});return U.createElement(Xe,{className:ze("recharts-reference-line",f)},soe(c,B),en.renderCallByParent(e,Cse({x1:T,y1:N,x2:M,y2:D})))}var nN=(function(e){function t(){return Kse(this,t),Wse(this,t,arguments)}return Jse(t,e),Xse(t,[{key:"render",value:function(){return U.createElement(loe,this.props)}}])})(U.Component);tN(nN,"displayName","ReferenceLine");tN(nN,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,fill:"none",stroke:"#ccc",fillOpacity:1,strokeWidth:1,position:"middle"});function Zj(){return Zj=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Zj.apply(this,arguments)}function il(e){"@babel/helpers - typeof";return il=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},il(e)}function k3(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function D3(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?k3(Object(n),!0).forEach(function(r){xp(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):k3(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function coe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function uoe(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,P6(r.key),r)}}function foe(e,t,n){return t&&uoe(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function doe(e,t,n){return t=vm(t),hoe(e,M6()?Reflect.construct(t,n||[],vm(e).constructor):t.apply(e,n))}function hoe(e,t){if(t&&(il(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return moe(e)}function moe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function M6(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(M6=function(){return!!e})()}function vm(e){return vm=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},vm(e)}function poe(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Qj(e,t)}function Qj(e,t){return Qj=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},Qj(e,t)}function xp(e,t,n){return t=P6(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function P6(e){var t=yoe(e,"string");return il(t)=="symbol"?t:t+""}function yoe(e,t){if(il(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(il(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var xoe=function(t){var n=t.x,r=t.y,i=t.xAxis,o=t.yAxis,c=WS({x:i.scale,y:o.scale}),f=c.apply({x:n,y:r},{bandAware:!0});return Zr(t,"discard")&&!c.isInRange(f)?null:f},gp=(function(e){function t(){return coe(this,t),doe(this,t,arguments)}return poe(t,e),foe(t,[{key:"render",value:function(){var r=this.props,i=r.x,o=r.y,c=r.r,f=r.alwaysShow,d=r.clipPathId,h=Xt(i),p=Xt(o);if(zr(f===void 0,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.'),!h||!p)return null;var y=xoe(this.props);if(!y)return null;var x=y.x,j=y.y,w=this.props,S=w.shape,b=w.className,A=Zr(this.props,"hidden")?"url(#".concat(d,")"):void 0,_=D3(D3({clipPath:A},Ne(this.props,!0)),{},{cx:x,cy:j});return U.createElement(Xe,{className:ze("recharts-reference-dot",b)},t.renderDot(S,_),en.renderCallByParent(this.props,{x:x-c,y:j-c,width:2*c,height:2*c}))}}])})(U.Component);xp(gp,"displayName","ReferenceDot");xp(gp,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,r:10,fill:"#fff",stroke:"#ccc",fillOpacity:1,strokeWidth:1});xp(gp,"renderDot",function(e,t){var n;return U.isValidElement(e)?n=U.cloneElement(e,t):Ce(e)?n=e(t):n=U.createElement(cp,Zj({},t,{cx:t.cx,cy:t.cy,className:"recharts-reference-dot-dot"})),n});function Jj(){return Jj=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Jj.apply(this,arguments)}function sl(e){"@babel/helpers - typeof";return sl=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},sl(e)}function z3(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function L3(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?z3(Object(n),!0).forEach(function(r){vp(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):z3(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function goe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function voe(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,k6(r.key),r)}}function boe(e,t,n){return t&&voe(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function joe(e,t,n){return t=bm(t),woe(e,R6()?Reflect.construct(t,n||[],bm(e).constructor):t.apply(e,n))}function woe(e,t){if(t&&(sl(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Soe(e)}function Soe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function R6(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(R6=function(){return!!e})()}function bm(e){return bm=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},bm(e)}function Noe(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&ew(e,t)}function ew(e,t){return ew=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},ew(e,t)}function vp(e,t,n){return t=k6(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function k6(e){var t=Aoe(e,"string");return sl(t)=="symbol"?t:t+""}function Aoe(e,t){if(sl(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(sl(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Ooe=function(t,n,r,i,o){var c=o.x1,f=o.x2,d=o.y1,h=o.y2,p=o.xAxis,y=o.yAxis;if(!p||!y)return null;var x=WS({x:p.scale,y:y.scale}),j={x:t?x.x.apply(c,{position:"start"}):x.x.rangeMin,y:r?x.y.apply(d,{position:"start"}):x.y.rangeMin},w={x:n?x.x.apply(f,{position:"end"}):x.x.rangeMax,y:i?x.y.apply(h,{position:"end"}):x.y.rangeMax};return Zr(o,"discard")&&(!x.isInRange(j)||!x.isInRange(w))?null:b6(j,w)},bp=(function(e){function t(){return goe(this,t),joe(this,t,arguments)}return Noe(t,e),boe(t,[{key:"render",value:function(){var r=this.props,i=r.x1,o=r.x2,c=r.y1,f=r.y2,d=r.className,h=r.alwaysShow,p=r.clipPathId;zr(h===void 0,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.');var y=Xt(i),x=Xt(o),j=Xt(c),w=Xt(f),S=this.props.shape;if(!y&&!x&&!j&&!w&&!S)return null;var b=Ooe(y,x,j,w,this.props);if(!b&&!S)return null;var A=Zr(this.props,"hidden")?"url(#".concat(p,")"):void 0;return U.createElement(Xe,{className:ze("recharts-reference-area",d)},t.renderRect(S,L3(L3({clipPath:A},Ne(this.props,!0)),b)),en.renderCallByParent(this.props,b))}}])})(U.Component);vp(bp,"displayName","ReferenceArea");vp(bp,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,r:10,fill:"#ccc",fillOpacity:.5,stroke:"none",strokeWidth:1});vp(bp,"renderRect",function(e,t){var n;return U.isValidElement(e)?n=U.cloneElement(e,t):Ce(e)?n=e(t):n=U.createElement(XS,Jj({},t,{className:"recharts-reference-area-rect"})),n});function D6(e,t,n){if(t<1)return[];if(t===1&&n===void 0)return e;for(var r=[],i=0;i<e.length;i+=t)r.push(e[i]);return r}function _oe(e,t,n){var r={width:e.width+t.width,height:e.height+t.height};return Pse(r,n)}function Toe(e,t,n){var r=n==="width",i=e.x,o=e.y,c=e.width,f=e.height;return t===1?{start:r?i:o,end:r?i+c:o+f}:{start:r?i+c:o+f,end:r?i:o}}function jm(e,t,n,r,i){if(e*t<e*r||e*t>e*i)return!1;var o=n();return e*(t-e*o/2-r)>=0&&e*(t+e*o/2-i)<=0}function Eoe(e,t){return D6(e,t+1)}function Coe(e,t,n,r,i){for(var o=(r||[]).slice(),c=t.start,f=t.end,d=0,h=1,p=c,y=function(){var w=r==null?void 0:r[d];if(w===void 0)return{v:D6(r,h)};var S=d,b,A=function(){return b===void 0&&(b=n(w,S)),b},_=w.coordinate,O=d===0||jm(e,_,A,p,f);O||(d=0,p=c,h+=1),O&&(p=_+e*(A()/2+i),d+=h)},x;h<=o.length;)if(x=y(),x)return x.v;return[]}function qu(e){"@babel/helpers - typeof";return qu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},qu(e)}function $3(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function mn(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?$3(Object(n),!0).forEach(function(r){Moe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):$3(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Moe(e,t,n){return t=Poe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Poe(e){var t=Roe(e,"string");return qu(t)=="symbol"?t:t+""}function Roe(e,t){if(qu(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(qu(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function koe(e,t,n,r,i){for(var o=(r||[]).slice(),c=o.length,f=t.start,d=t.end,h=function(x){var j=o[x],w,S=function(){return w===void 0&&(w=n(j,x)),w};if(x===c-1){var b=e*(j.coordinate+e*S()/2-d);o[x]=j=mn(mn({},j),{},{tickCoord:b>0?j.coordinate-b*e:j.coordinate})}else o[x]=j=mn(mn({},j),{},{tickCoord:j.coordinate});var A=jm(e,j.tickCoord,S,f,d);A&&(d=j.tickCoord-e*(S()/2+i),o[x]=mn(mn({},j),{},{isShow:!0}))},p=c-1;p>=0;p--)h(p);return o}function Doe(e,t,n,r,i,o){var c=(r||[]).slice(),f=c.length,d=t.start,h=t.end;if(o){var p=r[f-1],y=n(p,f-1),x=e*(p.coordinate+e*y/2-h);c[f-1]=p=mn(mn({},p),{},{tickCoord:x>0?p.coordinate-x*e:p.coordinate});var j=jm(e,p.tickCoord,function(){return y},d,h);j&&(h=p.tickCoord-e*(y/2+i),c[f-1]=mn(mn({},p),{},{isShow:!0}))}for(var w=o?f-1:f,S=function(_){var O=c[_],T,N=function(){return T===void 0&&(T=n(O,_)),T};if(_===0){var E=e*(O.coordinate-e*N()/2-d);c[_]=O=mn(mn({},O),{},{tickCoord:E<0?O.coordinate-E*e:O.coordinate})}else c[_]=O=mn(mn({},O),{},{tickCoord:O.coordinate});var M=jm(e,O.tickCoord,N,d,h);M&&(d=O.tickCoord+e*(N()/2+i),c[_]=mn(mn({},O),{},{isShow:!0}))},b=0;b<w;b++)S(b);return c}function rN(e,t,n){var r=e.tick,i=e.ticks,o=e.viewBox,c=e.minTickGap,f=e.orientation,d=e.interval,h=e.tickFormatter,p=e.unit,y=e.angle;if(!i||!i.length||!r)return[];if(de(d)||Cs.isSsr)return Eoe(i,typeof d=="number"&&de(d)?d:0);var x=[],j=f==="top"||f==="bottom"?"width":"height",w=p&&j==="width"?Xc(p,{fontSize:t,letterSpacing:n}):{width:0,height:0},S=function(O,T){var N=Ce(h)?h(O.value,T):O.value;return j==="width"?_oe(Xc(N,{fontSize:t,letterSpacing:n}),w,y):Xc(N,{fontSize:t,letterSpacing:n})[j]},b=i.length>=2?bn(i[1].coordinate-i[0].coordinate):1,A=Toe(o,b,j);return d==="equidistantPreserveStart"?Coe(b,A,S,i,c):(d==="preserveStart"||d==="preserveStartEnd"?x=Doe(b,A,S,i,c,d==="preserveStartEnd"):x=koe(b,A,S,i,c),x.filter(function(_){return _.isShow}))}var zoe=["viewBox"],Loe=["viewBox"],$oe=["ticks"];function ol(e){"@babel/helpers - typeof";return ol=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ol(e)}function Po(){return Po=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Po.apply(this,arguments)}function B3(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Ht(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?B3(Object(n),!0).forEach(function(r){aN(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):B3(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function s1(e,t){if(e==null)return{};var n=Boe(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Boe(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function qoe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function q3(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,L6(r.key),r)}}function Ioe(e,t,n){return t&&q3(e.prototype,t),n&&q3(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Uoe(e,t,n){return t=wm(t),Voe(e,z6()?Reflect.construct(t,n||[],wm(e).constructor):t.apply(e,n))}function Voe(e,t){if(t&&(ol(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Hoe(e)}function Hoe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function z6(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(z6=function(){return!!e})()}function wm(e){return wm=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},wm(e)}function Foe(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&tw(e,t)}function tw(e,t){return tw=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},tw(e,t)}function aN(e,t,n){return t=L6(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function L6(e){var t=Goe(e,"string");return ol(t)=="symbol"?t:t+""}function Goe(e,t){if(ol(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(ol(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var El=(function(e){function t(n){var r;return qoe(this,t),r=Uoe(this,t,[n]),r.state={fontSize:"",letterSpacing:""},r}return Foe(t,e),Ioe(t,[{key:"shouldComponentUpdate",value:function(r,i){var o=r.viewBox,c=s1(r,zoe),f=this.props,d=f.viewBox,h=s1(f,Loe);return!zo(o,d)||!zo(c,h)||!zo(i,this.state)}},{key:"componentDidMount",value:function(){var r=this.layerReference;if(r){var i=r.getElementsByClassName("recharts-cartesian-axis-tick-value")[0];i&&this.setState({fontSize:window.getComputedStyle(i).fontSize,letterSpacing:window.getComputedStyle(i).letterSpacing})}}},{key:"getTickLineCoord",value:function(r){var i=this.props,o=i.x,c=i.y,f=i.width,d=i.height,h=i.orientation,p=i.tickSize,y=i.mirror,x=i.tickMargin,j,w,S,b,A,_,O=y?-1:1,T=r.tickSize||p,N=de(r.tickCoord)?r.tickCoord:r.coordinate;switch(h){case"top":j=w=r.coordinate,b=c+ +!y*d,S=b-O*T,_=S-O*x,A=N;break;case"left":S=b=r.coordinate,w=o+ +!y*f,j=w-O*T,A=j-O*x,_=N;break;case"right":S=b=r.coordinate,w=o+ +y*f,j=w+O*T,A=j+O*x,_=N;break;default:j=w=r.coordinate,b=c+ +y*d,S=b+O*T,_=S+O*x,A=N;break}return{line:{x1:j,y1:S,x2:w,y2:b},tick:{x:A,y:_}}}},{key:"getTickTextAnchor",value:function(){var r=this.props,i=r.orientation,o=r.mirror,c;switch(i){case"left":c=o?"start":"end";break;case"right":c=o?"end":"start";break;default:c="middle";break}return c}},{key:"getTickVerticalAnchor",value:function(){var r=this.props,i=r.orientation,o=r.mirror,c="end";switch(i){case"left":case"right":c="middle";break;case"top":c=o?"start":"end";break;default:c=o?"end":"start";break}return c}},{key:"renderAxisLine",value:function(){var r=this.props,i=r.x,o=r.y,c=r.width,f=r.height,d=r.orientation,h=r.mirror,p=r.axisLine,y=Ht(Ht(Ht({},Ne(this.props,!1)),Ne(p,!1)),{},{fill:"none"});if(d==="top"||d==="bottom"){var x=+(d==="top"&&!h||d==="bottom"&&h);y=Ht(Ht({},y),{},{x1:i,y1:o+x*f,x2:i+c,y2:o+x*f})}else{var j=+(d==="left"&&!h||d==="right"&&h);y=Ht(Ht({},y),{},{x1:i+j*c,y1:o,x2:i+j*c,y2:o+f})}return U.createElement("line",Po({},y,{className:ze("recharts-cartesian-axis-line",Zn(p,"className"))}))}},{key:"renderTicks",value:function(r,i,o){var c=this,f=this.props,d=f.tickLine,h=f.stroke,p=f.tick,y=f.tickFormatter,x=f.unit,j=rN(Ht(Ht({},this.props),{},{ticks:r}),i,o),w=this.getTickTextAnchor(),S=this.getTickVerticalAnchor(),b=Ne(this.props,!1),A=Ne(p,!1),_=Ht(Ht({},b),{},{fill:"none"},Ne(d,!1)),O=j.map(function(T,N){var E=c.getTickLineCoord(T),M=E.line,D=E.tick,R=Ht(Ht(Ht(Ht({textAnchor:w,verticalAnchor:S},b),{},{stroke:"none",fill:h},A),D),{},{index:N,payload:T,visibleTicksCount:j.length,tickFormatter:y});return U.createElement(Xe,Po({className:"recharts-cartesian-axis-tick",key:"tick-".concat(T.value,"-").concat(T.coordinate,"-").concat(T.tickCoord)},Ss(c.props,T,N)),d&&U.createElement("line",Po({},_,M,{className:ze("recharts-cartesian-axis-tick-line",Zn(d,"className"))})),p&&t.renderTickItem(p,R,"".concat(Ce(y)?y(T.value,N):T.value).concat(x||"")))});return U.createElement("g",{className:"recharts-cartesian-axis-ticks"},O)}},{key:"render",value:function(){var r=this,i=this.props,o=i.axisLine,c=i.width,f=i.height,d=i.ticksGenerator,h=i.className,p=i.hide;if(p)return null;var y=this.props,x=y.ticks,j=s1(y,$oe),w=x;return Ce(d)&&(w=x&&x.length>0?d(this.props):d(j)),c<=0||f<=0||!w||!w.length?null:U.createElement(Xe,{className:ze("recharts-cartesian-axis",h),ref:function(b){r.layerReference=b}},o&&this.renderAxisLine(),this.renderTicks(w,this.state.fontSize,this.state.letterSpacing),en.renderCallByParent(this.props))}}],[{key:"renderTickItem",value:function(r,i,o){var c,f=ze(i.className,"recharts-cartesian-axis-tick-value");return U.isValidElement(r)?c=U.cloneElement(r,Ht(Ht({},i),{},{className:f})):Ce(r)?c=r(Ht(Ht({},i),{},{className:f})):c=U.createElement(Ns,Po({},i,{className:"recharts-cartesian-axis-tick-value"}),o),c}}])})(P.Component);aN(El,"displayName","CartesianAxis");aN(El,"defaultProps",{x:0,y:0,width:0,height:0,viewBox:{x:0,y:0,width:0,height:0},orientation:"bottom",ticks:[],stroke:"#666",tickLine:!0,axisLine:!0,tick:!0,mirror:!1,minTickGap:5,tickSize:6,tickMargin:2,interval:"preserveEnd"});var Koe=["x1","y1","x2","y2","key"],Yoe=["offset"];function _s(e){"@babel/helpers - typeof";return _s=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},_s(e)}function I3(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function pn(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?I3(Object(n),!0).forEach(function(r){Xoe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):I3(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Xoe(e,t,n){return t=Woe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Woe(e){var t=Zoe(e,"string");return _s(t)=="symbol"?t:t+""}function Zoe(e,t){if(_s(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(_s(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function ys(){return ys=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ys.apply(this,arguments)}function U3(e,t){if(e==null)return{};var n=Qoe(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Qoe(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var Joe=function(t){var n=t.fill;if(!n||n==="none")return null;var r=t.fillOpacity,i=t.x,o=t.y,c=t.width,f=t.height,d=t.ry;return U.createElement("rect",{x:i,y:o,ry:d,width:c,height:f,stroke:"none",fill:n,fillOpacity:r,className:"recharts-cartesian-grid-bg"})};function $6(e,t){var n;if(U.isValidElement(e))n=U.cloneElement(e,t);else if(Ce(e))n=e(t);else{var r=t.x1,i=t.y1,o=t.x2,c=t.y2,f=t.key,d=U3(t,Koe),h=Ne(d,!1);h.offset;var p=U3(h,Yoe);n=U.createElement("line",ys({},p,{x1:r,y1:i,x2:o,y2:c,fill:"none",key:f}))}return n}function ele(e){var t=e.x,n=e.width,r=e.horizontal,i=r===void 0?!0:r,o=e.horizontalPoints;if(!i||!o||!o.length)return null;var c=o.map(function(f,d){var h=pn(pn({},e),{},{x1:t,y1:f,x2:t+n,y2:f,key:"line-".concat(d),index:d});return $6(i,h)});return U.createElement("g",{className:"recharts-cartesian-grid-horizontal"},c)}function tle(e){var t=e.y,n=e.height,r=e.vertical,i=r===void 0?!0:r,o=e.verticalPoints;if(!i||!o||!o.length)return null;var c=o.map(function(f,d){var h=pn(pn({},e),{},{x1:f,y1:t,x2:f,y2:t+n,key:"line-".concat(d),index:d});return $6(i,h)});return U.createElement("g",{className:"recharts-cartesian-grid-vertical"},c)}function nle(e){var t=e.horizontalFill,n=e.fillOpacity,r=e.x,i=e.y,o=e.width,c=e.height,f=e.horizontalPoints,d=e.horizontal,h=d===void 0?!0:d;if(!h||!t||!t.length)return null;var p=f.map(function(x){return Math.round(x+i-i)}).sort(function(x,j){return x-j});i!==p[0]&&p.unshift(0);var y=p.map(function(x,j){var w=!p[j+1],S=w?i+c-x:p[j+1]-x;if(S<=0)return null;var b=j%t.length;return U.createElement("rect",{key:"react-".concat(j),y:x,x:r,height:S,width:o,stroke:"none",fill:t[b],fillOpacity:n,className:"recharts-cartesian-grid-bg"})});return U.createElement("g",{className:"recharts-cartesian-gridstripes-horizontal"},y)}function rle(e){var t=e.vertical,n=t===void 0?!0:t,r=e.verticalFill,i=e.fillOpacity,o=e.x,c=e.y,f=e.width,d=e.height,h=e.verticalPoints;if(!n||!r||!r.length)return null;var p=h.map(function(x){return Math.round(x+o-o)}).sort(function(x,j){return x-j});o!==p[0]&&p.unshift(0);var y=p.map(function(x,j){var w=!p[j+1],S=w?o+f-x:p[j+1]-x;if(S<=0)return null;var b=j%r.length;return U.createElement("rect",{key:"react-".concat(j),x,y:c,width:S,height:d,stroke:"none",fill:r[b],fillOpacity:i,className:"recharts-cartesian-grid-bg"})});return U.createElement("g",{className:"recharts-cartesian-gridstripes-vertical"},y)}var ale=function(t,n){var r=t.xAxis,i=t.width,o=t.height,c=t.offset;return $L(rN(pn(pn(pn({},El.defaultProps),r),{},{ticks:Ca(r,!0),viewBox:{x:0,y:0,width:i,height:o}})),c.left,c.left+c.width,n)},ile=function(t,n){var r=t.yAxis,i=t.width,o=t.height,c=t.offset;return $L(rN(pn(pn(pn({},El.defaultProps),r),{},{ticks:Ca(r,!0),viewBox:{x:0,y:0,width:i,height:o}})),c.top,c.top+c.height,n)},wo={horizontal:!0,vertical:!0,stroke:"#ccc",fill:"none",verticalFill:[],horizontalFill:[]};function nw(e){var t,n,r,i,o,c,f=JS(),d=eN(),h=Gse(),p=pn(pn({},e),{},{stroke:(t=e.stroke)!==null&&t!==void 0?t:wo.stroke,fill:(n=e.fill)!==null&&n!==void 0?n:wo.fill,horizontal:(r=e.horizontal)!==null&&r!==void 0?r:wo.horizontal,horizontalFill:(i=e.horizontalFill)!==null&&i!==void 0?i:wo.horizontalFill,vertical:(o=e.vertical)!==null&&o!==void 0?o:wo.vertical,verticalFill:(c=e.verticalFill)!==null&&c!==void 0?c:wo.verticalFill,x:de(e.x)?e.x:h.left,y:de(e.y)?e.y:h.top,width:de(e.width)?e.width:h.width,height:de(e.height)?e.height:h.height}),y=p.x,x=p.y,j=p.width,w=p.height,S=p.syncWithTicks,b=p.horizontalValues,A=p.verticalValues,_=Vse(),O=Hse();if(!de(j)||j<=0||!de(w)||w<=0||!de(y)||y!==+y||!de(x)||x!==+x)return null;var T=p.verticalCoordinatesGenerator||ale,N=p.horizontalCoordinatesGenerator||ile,E=p.horizontalPoints,M=p.verticalPoints;if((!E||!E.length)&&Ce(N)){var D=b&&b.length,R=N({yAxis:O?pn(pn({},O),{},{ticks:D?b:O.ticks}):void 0,width:f,height:d,offset:h},D?!0:S);zr(Array.isArray(R),"horizontalCoordinatesGenerator should return Array but instead it returned [".concat(_s(R),"]")),Array.isArray(R)&&(E=R)}if((!M||!M.length)&&Ce(T)){var B=A&&A.length,q=T({xAxis:_?pn(pn({},_),{},{ticks:B?A:_.ticks}):void 0,width:f,height:d,offset:h},B?!0:S);zr(Array.isArray(q),"verticalCoordinatesGenerator should return Array but instead it returned [".concat(_s(q),"]")),Array.isArray(q)&&(M=q)}return U.createElement("g",{className:"recharts-cartesian-grid"},U.createElement(Joe,{fill:p.fill,fillOpacity:p.fillOpacity,x:p.x,y:p.y,width:p.width,height:p.height,ry:p.ry}),U.createElement(ele,ys({},p,{offset:h,horizontalPoints:E,xAxis:_,yAxis:O})),U.createElement(tle,ys({},p,{offset:h,verticalPoints:M,xAxis:_,yAxis:O})),U.createElement(nle,ys({},p,{horizontalPoints:E})),U.createElement(rle,ys({},p,{verticalPoints:M})))}nw.displayName="CartesianGrid";var sle=["type","layout","connectNulls","ref"],ole=["key"];function ll(e){"@babel/helpers - typeof";return ll=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ll(e)}function V3(e,t){if(e==null)return{};var n=lle(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function lle(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function tu(){return tu=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},tu.apply(this,arguments)}function H3(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Vn(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?H3(Object(n),!0).forEach(function(r){Mr(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):H3(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function So(e){return dle(e)||fle(e)||ule(e)||cle()}function cle(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function ule(e,t){if(e){if(typeof e=="string")return rw(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return rw(e,t)}}function fle(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function dle(e){if(Array.isArray(e))return rw(e)}function rw(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function hle(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function F3(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,q6(r.key),r)}}function mle(e,t,n){return t&&F3(e.prototype,t),n&&F3(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function ple(e,t,n){return t=Sm(t),yle(e,B6()?Reflect.construct(t,n||[],Sm(e).constructor):t.apply(e,n))}function yle(e,t){if(t&&(ll(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return xle(e)}function xle(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function B6(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(B6=function(){return!!e})()}function Sm(e){return Sm=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Sm(e)}function gle(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&aw(e,t)}function aw(e,t){return aw=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},aw(e,t)}function Mr(e,t,n){return t=q6(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function q6(e){var t=vle(e,"string");return ll(t)=="symbol"?t:t+""}function vle(e,t){if(ll(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(ll(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var of=(function(e){function t(){var n;hle(this,t);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return n=ple(this,t,[].concat(i)),Mr(n,"state",{isAnimationFinished:!0,totalLength:0}),Mr(n,"generateSimpleStrokeDasharray",function(c,f){return"".concat(f,"px ").concat(c-f,"px")}),Mr(n,"getStrokeDasharray",function(c,f,d){var h=d.reduce(function(A,_){return A+_});if(!h)return n.generateSimpleStrokeDasharray(f,c);for(var p=Math.floor(c/h),y=c%h,x=f-c,j=[],w=0,S=0;w<d.length;S+=d[w],++w)if(S+d[w]>y){j=[].concat(So(d.slice(0,w)),[y-S]);break}var b=j.length%2===0?[0,x]:[x];return[].concat(So(t.repeat(d,p)),So(j),b).map(function(A){return"".concat(A,"px")}).join(", ")}),Mr(n,"id",Nl("recharts-line-")),Mr(n,"pathRef",function(c){n.mainCurve=c}),Mr(n,"handleAnimationEnd",function(){n.setState({isAnimationFinished:!0}),n.props.onAnimationEnd&&n.props.onAnimationEnd()}),Mr(n,"handleAnimationStart",function(){n.setState({isAnimationFinished:!1}),n.props.onAnimationStart&&n.props.onAnimationStart()}),n}return gle(t,e),mle(t,[{key:"componentDidMount",value:function(){if(this.props.isAnimationActive){var r=this.getTotalLength();this.setState({totalLength:r})}}},{key:"componentDidUpdate",value:function(){if(this.props.isAnimationActive){var r=this.getTotalLength();r!==this.state.totalLength&&this.setState({totalLength:r})}}},{key:"getTotalLength",value:function(){var r=this.mainCurve;try{return r&&r.getTotalLength&&r.getTotalLength()||0}catch{return 0}}},{key:"renderErrorBar",value:function(r,i){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var o=this.props,c=o.points,f=o.xAxis,d=o.yAxis,h=o.layout,p=o.children,y=Qn(p,sf);if(!y)return null;var x=function(S,b){return{x:S.x,y:S.y,value:S.value,errorVal:Kt(S.payload,b)}},j={clipPath:r?"url(#clipPath-".concat(i,")"):null};return U.createElement(Xe,j,y.map(function(w){return U.cloneElement(w,{key:"bar-".concat(w.props.dataKey),data:c,xAxis:f,yAxis:d,layout:h,dataPointFormatter:x})}))}},{key:"renderDots",value:function(r,i,o){var c=this.props.isAnimationActive;if(c&&!this.state.isAnimationFinished)return null;var f=this.props,d=f.dot,h=f.points,p=f.dataKey,y=Ne(this.props,!1),x=Ne(d,!0),j=h.map(function(S,b){var A=Vn(Vn(Vn({key:"dot-".concat(b),r:3},y),x),{},{index:b,cx:S.x,cy:S.y,value:S.value,dataKey:p,payload:S.payload,points:h});return t.renderDotItem(d,A)}),w={clipPath:r?"url(#clipPath-".concat(i?"":"dots-").concat(o,")"):null};return U.createElement(Xe,tu({className:"recharts-line-dots",key:"dots"},w),j)}},{key:"renderCurveStatically",value:function(r,i,o,c){var f=this.props,d=f.type,h=f.layout,p=f.connectNulls;f.ref;var y=V3(f,sle),x=Vn(Vn(Vn({},Ne(y,!0)),{},{fill:"none",className:"recharts-line-curve",clipPath:i?"url(#clipPath-".concat(o,")"):null,points:r},c),{},{type:d,layout:h,connectNulls:p});return U.createElement(nm,tu({},x,{pathRef:this.pathRef}))}},{key:"renderCurveWithAnimation",value:function(r,i){var o=this,c=this.props,f=c.points,d=c.strokeDasharray,h=c.isAnimationActive,p=c.animationBegin,y=c.animationDuration,x=c.animationEasing,j=c.animationId,w=c.animateNewValues,S=c.width,b=c.height,A=this.state,_=A.prevPoints,O=A.totalLength;return U.createElement(na,{begin:p,duration:y,isActive:h,easing:x,from:{t:0},to:{t:1},key:"line-".concat(j),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(T){var N=T.t;if(_){var E=_.length/f.length,M=f.map(function(z,H){var X=Math.floor(H*E);if(_[X]){var Y=_[X],$=Kn(Y.x,z.x),G=Kn(Y.y,z.y);return Vn(Vn({},z),{},{x:$(N),y:G(N)})}if(w){var Q=Kn(S*2,z.x),ie=Kn(b/2,z.y);return Vn(Vn({},z),{},{x:Q(N),y:ie(N)})}return Vn(Vn({},z),{},{x:z.x,y:z.y})});return o.renderCurveStatically(M,r,i)}var D=Kn(0,O),R=D(N),B;if(d){var q="".concat(d).split(/[,\s]+/gim).map(function(z){return parseFloat(z)});B=o.getStrokeDasharray(R,O,q)}else B=o.generateSimpleStrokeDasharray(O,R);return o.renderCurveStatically(f,r,i,{strokeDasharray:B})})}},{key:"renderCurve",value:function(r,i){var o=this.props,c=o.points,f=o.isAnimationActive,d=this.state,h=d.prevPoints,p=d.totalLength;return f&&c&&c.length&&(!h&&p>0||!af(h,c))?this.renderCurveWithAnimation(r,i):this.renderCurveStatically(c,r,i)}},{key:"render",value:function(){var r,i=this.props,o=i.hide,c=i.dot,f=i.points,d=i.className,h=i.xAxis,p=i.yAxis,y=i.top,x=i.left,j=i.width,w=i.height,S=i.isAnimationActive,b=i.id;if(o||!f||!f.length)return null;var A=this.state.isAnimationFinished,_=f.length===1,O=ze("recharts-line",d),T=h&&h.allowDataOverflow,N=p&&p.allowDataOverflow,E=T||N,M=Re(b)?this.id:b,D=(r=Ne(c,!1))!==null&&r!==void 0?r:{r:3,strokeWidth:2},R=D.r,B=R===void 0?3:R,q=D.strokeWidth,z=q===void 0?2:q,H=YG(c)?c:{},X=H.clipDot,Y=X===void 0?!0:X,$=B*2+z;return U.createElement(Xe,{className:O},T||N?U.createElement("defs",null,U.createElement("clipPath",{id:"clipPath-".concat(M)},U.createElement("rect",{x:T?x:x-j/2,y:N?y:y-w/2,width:T?j:j*2,height:N?w:w*2})),!Y&&U.createElement("clipPath",{id:"clipPath-dots-".concat(M)},U.createElement("rect",{x:x-$/2,y:y-$/2,width:j+$,height:w+$}))):null,!_&&this.renderCurve(E,M),this.renderErrorBar(E,M),(_||c)&&this.renderDots(E,Y,M),(!S||A)&&ka.renderCallByParent(this.props,f))}}],[{key:"getDerivedStateFromProps",value:function(r,i){return r.animationId!==i.prevAnimationId?{prevAnimationId:r.animationId,curPoints:r.points,prevPoints:i.curPoints}:r.points!==i.curPoints?{curPoints:r.points}:null}},{key:"repeat",value:function(r,i){for(var o=r.length%2!==0?[].concat(So(r),[0]):r,c=[],f=0;f<i;++f)c=[].concat(So(c),So(o));return c}},{key:"renderDotItem",value:function(r,i){var o;if(U.isValidElement(r))o=U.cloneElement(r,i);else if(Ce(r))o=r(i);else{var c=i.key,f=V3(i,ole),d=ze("recharts-line-dot",typeof r!="boolean"?r.className:"");o=U.createElement(cp,tu({key:c},f,{className:d}))}return o}}])})(P.PureComponent);Mr(of,"displayName","Line");Mr(of,"defaultProps",{xAxisId:0,yAxisId:0,connectNulls:!1,activeDot:!0,dot:!0,legendType:"line",stroke:"#3182bd",strokeWidth:1,fill:"#fff",points:[],isAnimationActive:!Cs.isSsr,animateNewValues:!0,animationBegin:0,animationDuration:1500,animationEasing:"ease",hide:!1,label:!1});Mr(of,"getComposedData",function(e){var t=e.props,n=e.xAxis,r=e.yAxis,i=e.xAxisTicks,o=e.yAxisTicks,c=e.dataKey,f=e.bandSize,d=e.displayedData,h=e.offset,p=t.layout,y=d.map(function(x,j){var w=Kt(x,c);return p==="horizontal"?{x:WR({axis:n,ticks:i,bandSize:f,entry:x,index:j}),y:Re(w)?null:r.scale(w),value:w,payload:x}:{x:Re(w)?null:n.scale(w),y:WR({axis:r,ticks:o,bandSize:f,entry:x,index:j}),value:w,payload:x}});return Vn({points:y,layout:p},h)});function cl(e){"@babel/helpers - typeof";return cl=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},cl(e)}function ble(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function jle(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,V6(r.key),r)}}function wle(e,t,n){return t&&jle(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Sle(e,t,n){return t=Nm(t),Nle(e,I6()?Reflect.construct(t,n||[],Nm(e).constructor):t.apply(e,n))}function Nle(e,t){if(t&&(cl(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Ale(e)}function Ale(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function I6(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(I6=function(){return!!e})()}function Nm(e){return Nm=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Nm(e)}function Ole(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&iw(e,t)}function iw(e,t){return iw=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},iw(e,t)}function U6(e,t,n){return t=V6(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function V6(e){var t=_le(e,"string");return cl(t)=="symbol"?t:t+""}function _le(e,t){if(cl(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(cl(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function sw(){return sw=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},sw.apply(this,arguments)}function Tle(e){var t=e.xAxisId,n=JS(),r=eN(),i=_6(t);return i==null?null:P.createElement(El,sw({},i,{className:ze("recharts-".concat(i.axisType," ").concat(i.axisType),i.className),viewBox:{x:0,y:0,width:n,height:r},ticksGenerator:function(c){return Ca(c,!0)}}))}var ul=(function(e){function t(){return ble(this,t),Sle(this,t,arguments)}return Ole(t,e),wle(t,[{key:"render",value:function(){return P.createElement(Tle,this.props)}}])})(P.Component);U6(ul,"displayName","XAxis");U6(ul,"defaultProps",{allowDecimals:!0,hide:!1,orientation:"bottom",width:0,height:30,mirror:!1,xAxisId:0,tickCount:5,type:"category",padding:{left:0,right:0},allowDataOverflow:!1,scale:"auto",reversed:!1,allowDuplicatedCategory:!0});function fl(e){"@babel/helpers - typeof";return fl=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},fl(e)}function Ele(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Cle(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,G6(r.key),r)}}function Mle(e,t,n){return t&&Cle(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Ple(e,t,n){return t=Am(t),Rle(e,H6()?Reflect.construct(t,n||[],Am(e).constructor):t.apply(e,n))}function Rle(e,t){if(t&&(fl(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return kle(e)}function kle(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function H6(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(H6=function(){return!!e})()}function Am(e){return Am=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Am(e)}function Dle(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&ow(e,t)}function ow(e,t){return ow=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},ow(e,t)}function F6(e,t,n){return t=G6(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function G6(e){var t=zle(e,"string");return fl(t)=="symbol"?t:t+""}function zle(e,t){if(fl(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(fl(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function lw(){return lw=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},lw.apply(this,arguments)}var Lle=function(t){var n=t.yAxisId,r=JS(),i=eN(),o=T6(n);return o==null?null:P.createElement(El,lw({},o,{className:ze("recharts-".concat(o.axisType," ").concat(o.axisType),o.className),viewBox:{x:0,y:0,width:r,height:i},ticksGenerator:function(f){return Ca(f,!0)}}))},dl=(function(e){function t(){return Ele(this,t),Ple(this,t,arguments)}return Dle(t,e),Mle(t,[{key:"render",value:function(){return P.createElement(Lle,this.props)}}])})(P.Component);F6(dl,"displayName","YAxis");F6(dl,"defaultProps",{allowDuplicatedCategory:!0,allowDecimals:!0,hide:!1,orientation:"left",width:60,height:0,mirror:!1,yAxisId:0,tickCount:5,type:"number",padding:{top:0,bottom:0},allowDataOverflow:!1,scale:"auto",reversed:!1});function G3(e){return Ile(e)||qle(e)||Ble(e)||$le()}function $le(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Ble(e,t){if(e){if(typeof e=="string")return cw(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return cw(e,t)}}function qle(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Ile(e){if(Array.isArray(e))return cw(e)}function cw(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var uw=function(t,n,r,i,o){var c=Qn(t,nN),f=Qn(t,gp),d=[].concat(G3(c),G3(f)),h=Qn(t,bp),p="".concat(i,"Id"),y=i[0],x=n;if(d.length&&(x=d.reduce(function(S,b){if(b.props[p]===r&&Zr(b.props,"extendDomain")&&de(b.props[y])){var A=b.props[y];return[Math.min(S[0],A),Math.max(S[1],A)]}return S},x)),h.length){var j="".concat(y,"1"),w="".concat(y,"2");x=h.reduce(function(S,b){if(b.props[p]===r&&Zr(b.props,"extendDomain")&&de(b.props[j])&&de(b.props[w])){var A=b.props[j],_=b.props[w];return[Math.min(S[0],A,_),Math.max(S[1],A,_)]}return S},x)}return o&&o.length&&(x=o.reduce(function(S,b){return de(b)?[Math.min(S[0],b),Math.max(S[1],b)]:S},x)),x},o1={exports:{}},K3;function Ule(){return K3||(K3=1,(function(e){var t=Object.prototype.hasOwnProperty,n="~";function r(){}Object.create&&(r.prototype=Object.create(null),new r().__proto__||(n=!1));function i(d,h,p){this.fn=d,this.context=h,this.once=p||!1}function o(d,h,p,y,x){if(typeof p!="function")throw new TypeError("The listener must be a function");var j=new i(p,y||d,x),w=n?n+h:h;return d._events[w]?d._events[w].fn?d._events[w]=[d._events[w],j]:d._events[w].push(j):(d._events[w]=j,d._eventsCount++),d}function c(d,h){--d._eventsCount===0?d._events=new r:delete d._events[h]}function f(){this._events=new r,this._eventsCount=0}f.prototype.eventNames=function(){var h=[],p,y;if(this._eventsCount===0)return h;for(y in p=this._events)t.call(p,y)&&h.push(n?y.slice(1):y);return Object.getOwnPropertySymbols?h.concat(Object.getOwnPropertySymbols(p)):h},f.prototype.listeners=function(h){var p=n?n+h:h,y=this._events[p];if(!y)return[];if(y.fn)return[y.fn];for(var x=0,j=y.length,w=new Array(j);x<j;x++)w[x]=y[x].fn;return w},f.prototype.listenerCount=function(h){var p=n?n+h:h,y=this._events[p];return y?y.fn?1:y.length:0},f.prototype.emit=function(h,p,y,x,j,w){var S=n?n+h:h;if(!this._events[S])return!1;var b=this._events[S],A=arguments.length,_,O;if(b.fn){switch(b.once&&this.removeListener(h,b.fn,void 0,!0),A){case 1:return b.fn.call(b.context),!0;case 2:return b.fn.call(b.context,p),!0;case 3:return b.fn.call(b.context,p,y),!0;case 4:return b.fn.call(b.context,p,y,x),!0;case 5:return b.fn.call(b.context,p,y,x,j),!0;case 6:return b.fn.call(b.context,p,y,x,j,w),!0}for(O=1,_=new Array(A-1);O<A;O++)_[O-1]=arguments[O];b.fn.apply(b.context,_)}else{var T=b.length,N;for(O=0;O<T;O++)switch(b[O].once&&this.removeListener(h,b[O].fn,void 0,!0),A){case 1:b[O].fn.call(b[O].context);break;case 2:b[O].fn.call(b[O].context,p);break;case 3:b[O].fn.call(b[O].context,p,y);break;case 4:b[O].fn.call(b[O].context,p,y,x);break;default:if(!_)for(N=1,_=new Array(A-1);N<A;N++)_[N-1]=arguments[N];b[O].fn.apply(b[O].context,_)}}return!0},f.prototype.on=function(h,p,y){return o(this,h,p,y,!1)},f.prototype.once=function(h,p,y){return o(this,h,p,y,!0)},f.prototype.removeListener=function(h,p,y,x){var j=n?n+h:h;if(!this._events[j])return this;if(!p)return c(this,j),this;var w=this._events[j];if(w.fn)w.fn===p&&(!x||w.once)&&(!y||w.context===y)&&c(this,j);else{for(var S=0,b=[],A=w.length;S<A;S++)(w[S].fn!==p||x&&!w[S].once||y&&w[S].context!==y)&&b.push(w[S]);b.length?this._events[j]=b.length===1?b[0]:b:c(this,j)}return this},f.prototype.removeAllListeners=function(h){var p;return h?(p=n?n+h:h,this._events[p]&&c(this,p)):(this._events=new r,this._eventsCount=0),this},f.prototype.off=f.prototype.removeListener,f.prototype.addListener=f.prototype.on,f.prefixed=n,f.EventEmitter=f,e.exports=f})(o1)),o1.exports}var Vle=Ule();const Hle=at(Vle);var l1=new Hle,c1="recharts.syncMouseEvents";function Iu(e){"@babel/helpers - typeof";return Iu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Iu(e)}function Fle(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Gle(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,K6(r.key),r)}}function Kle(e,t,n){return t&&Gle(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function u1(e,t,n){return t=K6(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function K6(e){var t=Yle(e,"string");return Iu(t)=="symbol"?t:t+""}function Yle(e,t){if(Iu(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Iu(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Xle=(function(){function e(){Fle(this,e),u1(this,"activeIndex",0),u1(this,"coordinateList",[]),u1(this,"layout","horizontal")}return Kle(e,[{key:"setDetails",value:function(n){var r,i=n.coordinateList,o=i===void 0?null:i,c=n.container,f=c===void 0?null:c,d=n.layout,h=d===void 0?null:d,p=n.offset,y=p===void 0?null:p,x=n.mouseHandlerCallback,j=x===void 0?null:x;this.coordinateList=(r=o??this.coordinateList)!==null&&r!==void 0?r:[],this.container=f??this.container,this.layout=h??this.layout,this.offset=y??this.offset,this.mouseHandlerCallback=j??this.mouseHandlerCallback,this.activeIndex=Math.min(Math.max(this.activeIndex,0),this.coordinateList.length-1)}},{key:"focus",value:function(){this.spoofMouse()}},{key:"keyboardEvent",value:function(n){if(this.coordinateList.length!==0)switch(n.key){case"ArrowRight":{if(this.layout!=="horizontal")return;this.activeIndex=Math.min(this.activeIndex+1,this.coordinateList.length-1),this.spoofMouse();break}case"ArrowLeft":{if(this.layout!=="horizontal")return;this.activeIndex=Math.max(this.activeIndex-1,0),this.spoofMouse();break}}}},{key:"setIndex",value:function(n){this.activeIndex=n}},{key:"spoofMouse",value:function(){var n,r;if(this.layout==="horizontal"&&this.coordinateList.length!==0){var i=this.container.getBoundingClientRect(),o=i.x,c=i.y,f=i.height,d=this.coordinateList[this.activeIndex].coordinate,h=((n=window)===null||n===void 0?void 0:n.scrollX)||0,p=((r=window)===null||r===void 0?void 0:r.scrollY)||0,y=o+d+h,x=c+this.offset.top+f/2+p;this.mouseHandlerCallback({pageX:y,pageY:x})}}}])})();function Wle(e,t,n){if(n==="number"&&t===!0&&Array.isArray(e)){var r=e==null?void 0:e[0],i=e==null?void 0:e[1];if(r&&i&&de(r)&&de(i))return!0}return!1}function Zle(e,t,n,r){var i=r/2;return{stroke:"none",fill:"#ccc",x:e==="horizontal"?t.x-i:n.left+.5,y:e==="horizontal"?n.top+.5:t.y-i,width:e==="horizontal"?r:n.width-1,height:e==="horizontal"?n.height-1:r}}function Y6(e){var t=e.cx,n=e.cy,r=e.radius,i=e.startAngle,o=e.endAngle,c=yt(t,n,r,i),f=yt(t,n,r,o);return{points:[c,f],cx:t,cy:n,radius:r,startAngle:i,endAngle:o}}function Qle(e,t,n){var r,i,o,c;if(e==="horizontal")r=t.x,o=r,i=n.top,c=n.top+n.height;else if(e==="vertical")i=t.y,c=i,r=n.left,o=n.left+n.width;else if(t.cx!=null&&t.cy!=null)if(e==="centric"){var f=t.cx,d=t.cy,h=t.innerRadius,p=t.outerRadius,y=t.angle,x=yt(f,d,h,y),j=yt(f,d,p,y);r=x.x,i=x.y,o=j.x,c=j.y}else return Y6(t);return[{x:r,y:i},{x:o,y:c}]}function Uu(e){"@babel/helpers - typeof";return Uu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Uu(e)}function Y3(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Qd(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Y3(Object(n),!0).forEach(function(r){Jle(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Y3(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Jle(e,t,n){return t=ece(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ece(e){var t=tce(e,"string");return Uu(t)=="symbol"?t:t+""}function tce(e,t){if(Uu(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Uu(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function nce(e){var t,n,r=e.element,i=e.tooltipEventType,o=e.isActive,c=e.activeCoordinate,f=e.activePayload,d=e.offset,h=e.activeTooltipIndex,p=e.tooltipAxisBandSize,y=e.layout,x=e.chartName,j=(t=r.props.cursor)!==null&&t!==void 0?t:(n=r.type.defaultProps)===null||n===void 0?void 0:n.cursor;if(!r||!j||!o||!c||x!=="ScatterChart"&&i!=="axis")return null;var w,S=nm;if(x==="ScatterChart")w=c,S=Nae;else if(x==="BarChart")w=Zle(y,c,d,p),S=XS;else if(y==="radial"){var b=Y6(c),A=b.cx,_=b.cy,O=b.radius,T=b.startAngle,N=b.endAngle;w={cx:A,cy:_,startAngle:T,endAngle:N,innerRadius:O,outerRadius:O},S=XL}else w={points:Qle(y,c,d)},S=nm;var E=Qd(Qd(Qd(Qd({stroke:"#ccc",pointerEvents:"none"},d),w),Ne(j,!1)),{},{payload:f,payloadIndex:h,className:ze("recharts-tooltip-cursor",j.className)});return P.isValidElement(j)?P.cloneElement(j,E):P.createElement(S,E)}var rce=["item"],ace=["children","className","width","height","style","compact","title","desc"];function hl(e){"@babel/helpers - typeof";return hl=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},hl(e)}function Ro(){return Ro=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ro.apply(this,arguments)}function X3(e,t){return oce(e)||sce(e,t)||W6(e,t)||ice()}function ice(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function sce(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,c,f=[],d=!0,h=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(d=(r=o.call(n)).done)&&(f.push(r.value),f.length!==t);d=!0);}catch(p){h=!0,i=p}finally{try{if(!d&&n.return!=null&&(c=n.return(),Object(c)!==c))return}finally{if(h)throw i}}return f}}function oce(e){if(Array.isArray(e))return e}function W3(e,t){if(e==null)return{};var n=lce(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function lce(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function cce(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function uce(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,Z6(r.key),r)}}function fce(e,t,n){return t&&uce(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function dce(e,t,n){return t=Om(t),hce(e,X6()?Reflect.construct(t,n||[],Om(e).constructor):t.apply(e,n))}function hce(e,t){if(t&&(hl(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return mce(e)}function mce(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function X6(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(X6=function(){return!!e})()}function Om(e){return Om=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Om(e)}function pce(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&fw(e,t)}function fw(e,t){return fw=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},fw(e,t)}function ml(e){return gce(e)||xce(e)||W6(e)||yce()}function yce(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function W6(e,t){if(e){if(typeof e=="string")return dw(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return dw(e,t)}}function xce(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function gce(e){if(Array.isArray(e))return dw(e)}function dw(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Z3(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function re(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Z3(Object(n),!0).forEach(function(r){_e(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Z3(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function _e(e,t,n){return t=Z6(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Z6(e){var t=vce(e,"string");return hl(t)=="symbol"?t:t+""}function vce(e,t){if(hl(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(hl(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var bce={xAxis:["bottom","top"],yAxis:["left","right"]},jce={width:"100%",height:"100%"},Q6={x:0,y:0};function Jd(e){return e}var wce=function(t,n){return n==="horizontal"?t.x:n==="vertical"?t.y:n==="centric"?t.angle:t.radius},Sce=function(t,n,r,i){var o=n.find(function(p){return p&&p.index===r});if(o){if(t==="horizontal")return{x:o.coordinate,y:i.y};if(t==="vertical")return{x:i.x,y:o.coordinate};if(t==="centric"){var c=o.coordinate,f=i.radius;return re(re(re({},i),yt(i.cx,i.cy,f,c)),{},{angle:c,radius:f})}var d=o.coordinate,h=i.angle;return re(re(re({},i),yt(i.cx,i.cy,d,h)),{},{angle:h,radius:d})}return Q6},jp=function(t,n){var r=n.graphicalItems,i=n.dataStartIndex,o=n.dataEndIndex,c=(r??[]).reduce(function(f,d){var h=d.props.data;return h&&h.length?[].concat(ml(f),ml(h)):f},[]);return c.length>0?c:t&&t.length&&de(i)&&de(o)?t.slice(i,o+1):[]};function J6(e){return e==="number"?[0,"auto"]:void 0}var hw=function(t,n,r,i){var o=t.graphicalItems,c=t.tooltipAxis,f=jp(n,t);return r<0||!o||!o.length||r>=f.length?null:o.reduce(function(d,h){var p,y=(p=h.props.data)!==null&&p!==void 0?p:n;y&&t.dataStartIndex+t.dataEndIndex!==0&&t.dataEndIndex-t.dataStartIndex>=r&&(y=y.slice(t.dataStartIndex,t.dataEndIndex+1));var x;if(c.dataKey&&!c.allowDuplicatedCategory){var j=y===void 0?f:y;x=_h(j,c.dataKey,i)}else x=y&&y[r]||f[r];return x?[].concat(ml(d),[VL(h,x)]):d},[])},Q3=function(t,n,r,i){var o=i||{x:t.chartX,y:t.chartY},c=wce(o,r),f=t.orderedTooltipTicks,d=t.tooltipAxis,h=t.tooltipTicks,p=Fee(c,f,h,d);if(p>=0&&h){var y=h[p]&&h[p].value,x=hw(t,n,p,y),j=Sce(r,f,p,o);return{activeTooltipIndex:p,activeLabel:y,activePayload:x,activeCoordinate:j}}return null},Nce=function(t,n){var r=n.axes,i=n.graphicalItems,o=n.axisType,c=n.axisIdKey,f=n.stackGroups,d=n.dataStartIndex,h=n.dataEndIndex,p=t.layout,y=t.children,x=t.stackOffset,j=LL(p,o);return r.reduce(function(w,S){var b,A=S.type.defaultProps!==void 0?re(re({},S.type.defaultProps),S.props):S.props,_=A.type,O=A.dataKey,T=A.allowDataOverflow,N=A.allowDuplicatedCategory,E=A.scale,M=A.ticks,D=A.includeHidden,R=A[c];if(w[R])return w;var B=jp(t.data,{graphicalItems:i.filter(function(F){var ae,fe=c in F.props?F.props[c]:(ae=F.type.defaultProps)===null||ae===void 0?void 0:ae[c];return fe===R}),dataStartIndex:d,dataEndIndex:h}),q=B.length,z,H,X;Wle(A.domain,T,_)&&(z=Oj(A.domain,null,T),j&&(_==="number"||E!=="auto")&&(X=Zc(B,O,"category")));var Y=J6(_);if(!z||z.length===0){var $,G=($=A.domain)!==null&&$!==void 0?$:Y;if(O){if(z=Zc(B,O,_),_==="category"&&j){var Q=$G(z);N&&Q?(H=z,z=hm(0,q)):N||(z=ek(G,z,S).reduce(function(F,ae){return F.indexOf(ae)>=0?F:[].concat(ml(F),[ae])},[]))}else if(_==="category")N?z=z.filter(function(F){return F!==""&&!Re(F)}):z=ek(G,z,S).reduce(function(F,ae){return F.indexOf(ae)>=0||ae===""||Re(ae)?F:[].concat(ml(F),[ae])},[]);else if(_==="number"){var ie=Wee(B,i.filter(function(F){var ae,fe,xe=c in F.props?F.props[c]:(ae=F.type.defaultProps)===null||ae===void 0?void 0:ae[c],Ae="hide"in F.props?F.props.hide:(fe=F.type.defaultProps)===null||fe===void 0?void 0:fe.hide;return xe===R&&(D||!Ae)}),O,o,p);ie&&(z=ie)}j&&(_==="number"||E!=="auto")&&(X=Zc(B,O,"category"))}else j?z=hm(0,q):f&&f[R]&&f[R].hasStack&&_==="number"?z=x==="expand"?[0,1]:UL(f[R].stackGroups,d,h):z=zL(B,i.filter(function(F){var ae=c in F.props?F.props[c]:F.type.defaultProps[c],fe="hide"in F.props?F.props.hide:F.type.defaultProps.hide;return ae===R&&(D||!fe)}),_,p,!0);if(_==="number")z=uw(y,z,R,o,M),G&&(z=Oj(G,z,T));else if(_==="category"&&G){var le=G,L=z.every(function(F){return le.indexOf(F)>=0});L&&(z=le)}}return re(re({},w),{},_e({},R,re(re({},A),{},{axisType:o,domain:z,categoricalDomain:X,duplicateDomain:H,originalDomain:(b=A.domain)!==null&&b!==void 0?b:Y,isCategorical:j,layout:p})))},{})},Ace=function(t,n){var r=n.graphicalItems,i=n.Axis,o=n.axisType,c=n.axisIdKey,f=n.stackGroups,d=n.dataStartIndex,h=n.dataEndIndex,p=t.layout,y=t.children,x=jp(t.data,{graphicalItems:r,dataStartIndex:d,dataEndIndex:h}),j=x.length,w=LL(p,o),S=-1;return r.reduce(function(b,A){var _=A.type.defaultProps!==void 0?re(re({},A.type.defaultProps),A.props):A.props,O=_[c],T=J6("number");if(!b[O]){S++;var N;return w?N=hm(0,j):f&&f[O]&&f[O].hasStack?(N=UL(f[O].stackGroups,d,h),N=uw(y,N,O,o)):(N=Oj(T,zL(x,r.filter(function(E){var M,D,R=c in E.props?E.props[c]:(M=E.type.defaultProps)===null||M===void 0?void 0:M[c],B="hide"in E.props?E.props.hide:(D=E.type.defaultProps)===null||D===void 0?void 0:D.hide;return R===O&&!B}),"number",p),i.defaultProps.allowDataOverflow),N=uw(y,N,O,o)),re(re({},b),{},_e({},O,re(re({axisType:o},i.defaultProps),{},{hide:!0,orientation:Zn(bce,"".concat(o,".").concat(S%2),null),domain:N,originalDomain:T,isCategorical:w,layout:p})))}return b},{})},Oce=function(t,n){var r=n.axisType,i=r===void 0?"xAxis":r,o=n.AxisComp,c=n.graphicalItems,f=n.stackGroups,d=n.dataStartIndex,h=n.dataEndIndex,p=t.children,y="".concat(i,"Id"),x=Qn(p,o),j={};return x&&x.length?j=Nce(t,{axes:x,graphicalItems:c,axisType:i,axisIdKey:y,stackGroups:f,dataStartIndex:d,dataEndIndex:h}):c&&c.length&&(j=Ace(t,{Axis:o,graphicalItems:c,axisType:i,axisIdKey:y,stackGroups:f,dataStartIndex:d,dataEndIndex:h})),j},_ce=function(t){var n=Ni(t),r=Ca(n,!1,!0);return{tooltipTicks:r,orderedTooltipTicks:wS(r,function(i){return i.coordinate}),tooltipAxis:n,tooltipAxisBandSize:Jh(n,r)}},J3=function(t){var n=t.children,r=t.defaultShowTooltip,i=Fn(n,nl),o=0,c=0;return t.data&&t.data.length!==0&&(c=t.data.length-1),i&&i.props&&(i.props.startIndex>=0&&(o=i.props.startIndex),i.props.endIndex>=0&&(c=i.props.endIndex)),{chartX:0,chartY:0,dataStartIndex:o,dataEndIndex:c,activeTooltipIndex:-1,isTooltipActive:!!r}},Tce=function(t){return!t||!t.length?!1:t.some(function(n){var r=Pa(n&&n.type);return r&&r.indexOf("Bar")>=0})},eD=function(t){return t==="horizontal"?{numericAxisName:"yAxis",cateAxisName:"xAxis"}:t==="vertical"?{numericAxisName:"xAxis",cateAxisName:"yAxis"}:t==="centric"?{numericAxisName:"radiusAxis",cateAxisName:"angleAxis"}:{numericAxisName:"angleAxis",cateAxisName:"radiusAxis"}},Ece=function(t,n){var r=t.props,i=t.graphicalItems,o=t.xAxisMap,c=o===void 0?{}:o,f=t.yAxisMap,d=f===void 0?{}:f,h=r.width,p=r.height,y=r.children,x=r.margin||{},j=Fn(y,nl),w=Fn(y,Lo),S=Object.keys(d).reduce(function(N,E){var M=d[E],D=M.orientation;return!M.mirror&&!M.hide?re(re({},N),{},_e({},D,N[D]+M.width)):N},{left:x.left||0,right:x.right||0}),b=Object.keys(c).reduce(function(N,E){var M=c[E],D=M.orientation;return!M.mirror&&!M.hide?re(re({},N),{},_e({},D,Zn(N,"".concat(D))+M.height)):N},{top:x.top||0,bottom:x.bottom||0}),A=re(re({},b),S),_=A.bottom;j&&(A.bottom+=j.props.height||nl.defaultProps.height),w&&n&&(A=Yee(A,i,r,n));var O=h-A.left-A.right,T=p-A.top-A.bottom;return re(re({brushBottom:_},A),{},{width:Math.max(O,0),height:Math.max(T,0)})},Cce=function(t,n){if(n==="xAxis")return t[n].width;if(n==="yAxis")return t[n].height},iN=function(t){var n=t.chartName,r=t.GraphicalChild,i=t.defaultTooltipEventType,o=i===void 0?"axis":i,c=t.validateTooltipEventTypes,f=c===void 0?["axis"]:c,d=t.axisComponents,h=t.legendContent,p=t.formatAxisMap,y=t.defaultProps,x=function(A,_){var O=_.graphicalItems,T=_.stackGroups,N=_.offset,E=_.updateId,M=_.dataStartIndex,D=_.dataEndIndex,R=A.barSize,B=A.layout,q=A.barGap,z=A.barCategoryGap,H=A.maxBarSize,X=eD(B),Y=X.numericAxisName,$=X.cateAxisName,G=Tce(O),Q=[];return O.forEach(function(ie,le){var L=jp(A.data,{graphicalItems:[ie],dataStartIndex:M,dataEndIndex:D}),F=ie.type.defaultProps!==void 0?re(re({},ie.type.defaultProps),ie.props):ie.props,ae=F.dataKey,fe=F.maxBarSize,xe=F["".concat(Y,"Id")],Ae=F["".concat($,"Id")],qe={},Qe=d.reduce(function(Sr,ia){var Cl=_["".concat(ia.axisType,"Map")],dn=F["".concat(ia.axisType,"Id")];Cl&&Cl[dn]||ia.axisType==="zAxis"||Os();var lf=Cl[dn];return re(re({},Sr),{},_e(_e({},ia.axisType,lf),"".concat(ia.axisType,"Ticks"),Ca(lf)))},qe),ue=Qe[$],Ee=Qe["".concat($,"Ticks")],Me=T&&T[xe]&&T[xe].hasStack&&ite(ie,T[xe].stackGroups),ce=Pa(ie.type).indexOf("Bar")>=0,xt=Jh(ue,Ee),Le=[],_t=G&&Gee({barSize:R,stackGroups:T,totalSize:Cce(Qe,$)});if(ce){var Tt,fn,wr=Re(fe)?H:fe,qr=(Tt=(fn=Jh(ue,Ee,!0))!==null&&fn!==void 0?fn:wr)!==null&&Tt!==void 0?Tt:0;Le=Kee({barGap:q,barCategoryGap:z,bandSize:qr!==xt?qr:xt,sizeList:_t[Ae],maxBarSize:wr}),qr!==xt&&(Le=Le.map(function(Sr){return re(re({},Sr),{},{position:re(re({},Sr.position),{},{offset:Sr.position.offset-qr/2})})}))}var Ya=ie&&ie.type&&ie.type.getComposedData;Ya&&Q.push({props:re(re({},Ya(re(re({},Qe),{},{displayedData:L,props:A,dataKey:ae,item:ie,bandSize:xt,barPosition:Le,offset:N,stackedData:Me,layout:B,dataStartIndex:M,dataEndIndex:D}))),{},_e(_e(_e({key:ie.key||"item-".concat(le)},Y,Qe[Y]),$,Qe[$]),"animationId",E)),childIndex:ZG(ie,A.children),item:ie})}),Q},j=function(A,_){var O=A.props,T=A.dataStartIndex,N=A.dataEndIndex,E=A.updateId;if(!mC({props:O}))return null;var M=O.children,D=O.layout,R=O.stackOffset,B=O.data,q=O.reverseStackOrder,z=eD(D),H=z.numericAxisName,X=z.cateAxisName,Y=Qn(M,r),$=rte(B,Y,"".concat(H,"Id"),"".concat(X,"Id"),R,q),G=d.reduce(function(F,ae){var fe="".concat(ae.axisType,"Map");return re(re({},F),{},_e({},fe,Oce(O,re(re({},ae),{},{graphicalItems:Y,stackGroups:ae.axisType===H&&$,dataStartIndex:T,dataEndIndex:N}))))},{}),Q=Ece(re(re({},G),{},{props:O,graphicalItems:Y}),_==null?void 0:_.legendBBox);Object.keys(G).forEach(function(F){G[F]=p(O,G[F],Q,F.replace("Map",""),n)});var ie=G["".concat(X,"Map")],le=_ce(ie),L=x(O,re(re({},G),{},{dataStartIndex:T,dataEndIndex:N,updateId:E,graphicalItems:Y,stackGroups:$,offset:Q}));return re(re({formattedGraphicalItems:L,graphicalItems:Y,offset:Q,stackGroups:$},le),G)},w=(function(b){function A(_){var O,T,N;return cce(this,A),N=dce(this,A,[_]),_e(N,"eventEmitterSymbol",Symbol("rechartsEventEmitter")),_e(N,"accessibilityManager",new Xle),_e(N,"handleLegendBBoxUpdate",function(E){if(E){var M=N.state,D=M.dataStartIndex,R=M.dataEndIndex,B=M.updateId;N.setState(re({legendBBox:E},j({props:N.props,dataStartIndex:D,dataEndIndex:R,updateId:B},re(re({},N.state),{},{legendBBox:E}))))}}),_e(N,"handleReceiveSyncEvent",function(E,M,D){if(N.props.syncId===E){if(D===N.eventEmitterSymbol&&typeof N.props.syncMethod!="function")return;N.applySyncEvent(M)}}),_e(N,"handleBrushChange",function(E){var M=E.startIndex,D=E.endIndex;if(M!==N.state.dataStartIndex||D!==N.state.dataEndIndex){var R=N.state.updateId;N.setState(function(){return re({dataStartIndex:M,dataEndIndex:D},j({props:N.props,dataStartIndex:M,dataEndIndex:D,updateId:R},N.state))}),N.triggerSyncEvent({dataStartIndex:M,dataEndIndex:D})}}),_e(N,"handleMouseEnter",function(E){var M=N.getMouseInfo(E);if(M){var D=re(re({},M),{},{isTooltipActive:!0});N.setState(D),N.triggerSyncEvent(D);var R=N.props.onMouseEnter;Ce(R)&&R(D,E)}}),_e(N,"triggeredAfterMouseMove",function(E){var M=N.getMouseInfo(E),D=M?re(re({},M),{},{isTooltipActive:!0}):{isTooltipActive:!1};N.setState(D),N.triggerSyncEvent(D);var R=N.props.onMouseMove;Ce(R)&&R(D,E)}),_e(N,"handleItemMouseEnter",function(E){N.setState(function(){return{isTooltipActive:!0,activeItem:E,activePayload:E.tooltipPayload,activeCoordinate:E.tooltipPosition||{x:E.cx,y:E.cy}}})}),_e(N,"handleItemMouseLeave",function(){N.setState(function(){return{isTooltipActive:!1}})}),_e(N,"handleMouseMove",function(E){E.persist(),N.throttleTriggeredAfterMouseMove(E)}),_e(N,"handleMouseLeave",function(E){N.throttleTriggeredAfterMouseMove.cancel();var M={isTooltipActive:!1};N.setState(M),N.triggerSyncEvent(M);var D=N.props.onMouseLeave;Ce(D)&&D(M,E)}),_e(N,"handleOuterEvent",function(E){var M=WG(E),D=Zn(N.props,"".concat(M));if(M&&Ce(D)){var R,B;/.*touch.*/i.test(M)?B=N.getMouseInfo(E.changedTouches[0]):B=N.getMouseInfo(E),D((R=B)!==null&&R!==void 0?R:{},E)}}),_e(N,"handleClick",function(E){var M=N.getMouseInfo(E);if(M){var D=re(re({},M),{},{isTooltipActive:!0});N.setState(D),N.triggerSyncEvent(D);var R=N.props.onClick;Ce(R)&&R(D,E)}}),_e(N,"handleMouseDown",function(E){var M=N.props.onMouseDown;if(Ce(M)){var D=N.getMouseInfo(E);M(D,E)}}),_e(N,"handleMouseUp",function(E){var M=N.props.onMouseUp;if(Ce(M)){var D=N.getMouseInfo(E);M(D,E)}}),_e(N,"handleTouchMove",function(E){E.changedTouches!=null&&E.changedTouches.length>0&&N.throttleTriggeredAfterMouseMove(E.changedTouches[0])}),_e(N,"handleTouchStart",function(E){E.changedTouches!=null&&E.changedTouches.length>0&&N.handleMouseDown(E.changedTouches[0])}),_e(N,"handleTouchEnd",function(E){E.changedTouches!=null&&E.changedTouches.length>0&&N.handleMouseUp(E.changedTouches[0])}),_e(N,"handleDoubleClick",function(E){var M=N.props.onDoubleClick;if(Ce(M)){var D=N.getMouseInfo(E);M(D,E)}}),_e(N,"handleContextMenu",function(E){var M=N.props.onContextMenu;if(Ce(M)){var D=N.getMouseInfo(E);M(D,E)}}),_e(N,"triggerSyncEvent",function(E){N.props.syncId!==void 0&&l1.emit(c1,N.props.syncId,E,N.eventEmitterSymbol)}),_e(N,"applySyncEvent",function(E){var M=N.props,D=M.layout,R=M.syncMethod,B=N.state.updateId,q=E.dataStartIndex,z=E.dataEndIndex;if(E.dataStartIndex!==void 0||E.dataEndIndex!==void 0)N.setState(re({dataStartIndex:q,dataEndIndex:z},j({props:N.props,dataStartIndex:q,dataEndIndex:z,updateId:B},N.state)));else if(E.activeTooltipIndex!==void 0){var H=E.chartX,X=E.chartY,Y=E.activeTooltipIndex,$=N.state,G=$.offset,Q=$.tooltipTicks;if(!G)return;if(typeof R=="function")Y=R(Q,E);else if(R==="value"){Y=-1;for(var ie=0;ie<Q.length;ie++)if(Q[ie].value===E.activeLabel){Y=ie;break}}var le=re(re({},G),{},{x:G.left,y:G.top}),L=Math.min(H,le.x+le.width),F=Math.min(X,le.y+le.height),ae=Q[Y]&&Q[Y].value,fe=hw(N.state,N.props.data,Y),xe=Q[Y]?{x:D==="horizontal"?Q[Y].coordinate:L,y:D==="horizontal"?F:Q[Y].coordinate}:Q6;N.setState(re(re({},E),{},{activeLabel:ae,activeCoordinate:xe,activePayload:fe,activeTooltipIndex:Y}))}else N.setState(E)}),_e(N,"renderCursor",function(E){var M,D=N.state,R=D.isTooltipActive,B=D.activeCoordinate,q=D.activePayload,z=D.offset,H=D.activeTooltipIndex,X=D.tooltipAxisBandSize,Y=N.getTooltipEventType(),$=(M=E.props.active)!==null&&M!==void 0?M:R,G=N.props.layout,Q=E.key||"_recharts-cursor";return U.createElement(nce,{key:Q,activeCoordinate:B,activePayload:q,activeTooltipIndex:H,chartName:n,element:E,isActive:$,layout:G,offset:z,tooltipAxisBandSize:X,tooltipEventType:Y})}),_e(N,"renderPolarAxis",function(E,M,D){var R=Zn(E,"type.axisType"),B=Zn(N.state,"".concat(R,"Map")),q=E.type.defaultProps,z=q!==void 0?re(re({},q),E.props):E.props,H=B&&B[z["".concat(R,"Id")]];return P.cloneElement(E,re(re({},H),{},{className:ze(R,H.className),key:E.key||"".concat(M,"-").concat(D),ticks:Ca(H,!0)}))}),_e(N,"renderPolarGrid",function(E){var M=E.props,D=M.radialLines,R=M.polarAngles,B=M.polarRadius,q=N.state,z=q.radiusAxisMap,H=q.angleAxisMap,X=Ni(z),Y=Ni(H),$=Y.cx,G=Y.cy,Q=Y.innerRadius,ie=Y.outerRadius;return P.cloneElement(E,{polarAngles:Array.isArray(R)?R:Ca(Y,!0).map(function(le){return le.coordinate}),polarRadius:Array.isArray(B)?B:Ca(X,!0).map(function(le){return le.coordinate}),cx:$,cy:G,innerRadius:Q,outerRadius:ie,key:E.key||"polar-grid",radialLines:D})}),_e(N,"renderLegend",function(){var E=N.state.formattedGraphicalItems,M=N.props,D=M.children,R=M.width,B=M.height,q=N.props.margin||{},z=R-(q.left||0)-(q.right||0),H=kL({children:D,formattedGraphicalItems:E,legendWidth:z,legendContent:h});if(!H)return null;var X=H.item,Y=W3(H,rce);return P.cloneElement(X,re(re({},Y),{},{chartWidth:R,chartHeight:B,margin:q,onBBoxUpdate:N.handleLegendBBoxUpdate}))}),_e(N,"renderTooltip",function(){var E,M=N.props,D=M.children,R=M.accessibilityLayer,B=Fn(D,hr);if(!B)return null;var q=N.state,z=q.isTooltipActive,H=q.activeCoordinate,X=q.activePayload,Y=q.activeLabel,$=q.offset,G=(E=B.props.active)!==null&&E!==void 0?E:z;return P.cloneElement(B,{viewBox:re(re({},$),{},{x:$.left,y:$.top}),active:G,label:Y,payload:G?X:[],coordinate:H,accessibilityLayer:R})}),_e(N,"renderBrush",function(E){var M=N.props,D=M.margin,R=M.data,B=N.state,q=B.offset,z=B.dataStartIndex,H=B.dataEndIndex,X=B.updateId;return P.cloneElement(E,{key:E.key||"_recharts-brush",onChange:Yd(N.handleBrushChange,E.props.onChange),data:R,x:de(E.props.x)?E.props.x:q.left,y:de(E.props.y)?E.props.y:q.top+q.height+q.brushBottom-(D.bottom||0),width:de(E.props.width)?E.props.width:q.width,startIndex:z,endIndex:H,updateId:"brush-".concat(X)})}),_e(N,"renderReferenceElement",function(E,M,D){if(!E)return null;var R=N,B=R.clipPathId,q=N.state,z=q.xAxisMap,H=q.yAxisMap,X=q.offset,Y=E.type.defaultProps||{},$=E.props,G=$.xAxisId,Q=G===void 0?Y.xAxisId:G,ie=$.yAxisId,le=ie===void 0?Y.yAxisId:ie;return P.cloneElement(E,{key:E.key||"".concat(M,"-").concat(D),xAxis:z[Q],yAxis:H[le],viewBox:{x:X.left,y:X.top,width:X.width,height:X.height},clipPathId:B})}),_e(N,"renderActivePoints",function(E){var M=E.item,D=E.activePoint,R=E.basePoint,B=E.childIndex,q=E.isRange,z=[],H=M.props.key,X=M.item.type.defaultProps!==void 0?re(re({},M.item.type.defaultProps),M.item.props):M.item.props,Y=X.activeDot,$=X.dataKey,G=re(re({index:B,dataKey:$,cx:D.x,cy:D.y,r:4,fill:YS(M.item),strokeWidth:2,stroke:"#fff",payload:D.payload,value:D.value},Ne(Y,!1)),Th(Y));return z.push(A.renderActiveDot(Y,G,"".concat(H,"-activePoint-").concat(B))),R?z.push(A.renderActiveDot(Y,re(re({},G),{},{cx:R.x,cy:R.y}),"".concat(H,"-basePoint-").concat(B))):q&&z.push(null),z}),_e(N,"renderGraphicChild",function(E,M,D){var R=N.filterFormatItem(E,M,D);if(!R)return null;var B=N.getTooltipEventType(),q=N.state,z=q.isTooltipActive,H=q.tooltipAxis,X=q.activeTooltipIndex,Y=q.activeLabel,$=N.props.children,G=Fn($,hr),Q=R.props,ie=Q.points,le=Q.isRange,L=Q.baseLine,F=R.item.type.defaultProps!==void 0?re(re({},R.item.type.defaultProps),R.item.props):R.item.props,ae=F.activeDot,fe=F.hide,xe=F.activeBar,Ae=F.activeShape,qe=!!(!fe&&z&&G&&(ae||xe||Ae)),Qe={};B!=="axis"&&G&&G.props.trigger==="click"?Qe={onClick:Yd(N.handleItemMouseEnter,E.props.onClick)}:B!=="axis"&&(Qe={onMouseLeave:Yd(N.handleItemMouseLeave,E.props.onMouseLeave),onMouseEnter:Yd(N.handleItemMouseEnter,E.props.onMouseEnter)});var ue=P.cloneElement(E,re(re({},R.props),Qe));function Ee(ia){return typeof H.dataKey=="function"?H.dataKey(ia.payload):null}if(qe)if(X>=0){var Me,ce;if(H.dataKey&&!H.allowDuplicatedCategory){var xt=typeof H.dataKey=="function"?Ee:"payload.".concat(H.dataKey.toString());Me=_h(ie,xt,Y),ce=le&&L&&_h(L,xt,Y)}else Me=ie==null?void 0:ie[X],ce=le&&L&&L[X];if(Ae||xe){var Le=E.props.activeIndex!==void 0?E.props.activeIndex:X;return[P.cloneElement(E,re(re(re({},R.props),Qe),{},{activeIndex:Le})),null,null]}if(!Re(Me))return[ue].concat(ml(N.renderActivePoints({item:R,activePoint:Me,basePoint:ce,childIndex:X,isRange:le})))}else{var _t,Tt=(_t=N.getItemByXY(N.state.activeCoordinate))!==null&&_t!==void 0?_t:{graphicalItem:ue},fn=Tt.graphicalItem,wr=fn.item,qr=wr===void 0?E:wr,Ya=fn.childIndex,Sr=re(re(re({},R.props),Qe),{},{activeIndex:Ya});return[P.cloneElement(qr,Sr),null,null]}return le?[ue,null,null]:[ue,null]}),_e(N,"renderCustomized",function(E,M,D){return P.cloneElement(E,re(re({key:"recharts-customized-".concat(D)},N.props),N.state))}),_e(N,"renderMap",{CartesianGrid:{handler:Jd,once:!0},ReferenceArea:{handler:N.renderReferenceElement},ReferenceLine:{handler:Jd},ReferenceDot:{handler:N.renderReferenceElement},XAxis:{handler:Jd},YAxis:{handler:Jd},Brush:{handler:N.renderBrush,once:!0},Bar:{handler:N.renderGraphicChild},Line:{handler:N.renderGraphicChild},Area:{handler:N.renderGraphicChild},Radar:{handler:N.renderGraphicChild},RadialBar:{handler:N.renderGraphicChild},Scatter:{handler:N.renderGraphicChild},Pie:{handler:N.renderGraphicChild},Funnel:{handler:N.renderGraphicChild},Tooltip:{handler:N.renderCursor,once:!0},PolarGrid:{handler:N.renderPolarGrid,once:!0},PolarAngleAxis:{handler:N.renderPolarAxis},PolarRadiusAxis:{handler:N.renderPolarAxis},Customized:{handler:N.renderCustomized}}),N.clipPathId="".concat((O=_.id)!==null&&O!==void 0?O:Nl("recharts"),"-clip"),N.throttleTriggeredAfterMouseMove=k5(N.triggeredAfterMouseMove,(T=_.throttleDelay)!==null&&T!==void 0?T:1e3/60),N.state={},N}return pce(A,b),fce(A,[{key:"componentDidMount",value:function(){var O,T;this.addListener(),this.accessibilityManager.setDetails({container:this.container,offset:{left:(O=this.props.margin.left)!==null&&O!==void 0?O:0,top:(T=this.props.margin.top)!==null&&T!==void 0?T:0},coordinateList:this.state.tooltipTicks,mouseHandlerCallback:this.triggeredAfterMouseMove,layout:this.props.layout}),this.displayDefaultTooltip()}},{key:"displayDefaultTooltip",value:function(){var O=this.props,T=O.children,N=O.data,E=O.height,M=O.layout,D=Fn(T,hr);if(D){var R=D.props.defaultIndex;if(!(typeof R!="number"||R<0||R>this.state.tooltipTicks.length-1)){var B=this.state.tooltipTicks[R]&&this.state.tooltipTicks[R].value,q=hw(this.state,N,R,B),z=this.state.tooltipTicks[R].coordinate,H=(this.state.offset.top+E)/2,X=M==="horizontal",Y=X?{x:z,y:H}:{y:z,x:H},$=this.state.formattedGraphicalItems.find(function(Q){var ie=Q.item;return ie.type.name==="Scatter"});$&&(Y=re(re({},Y),$.props.points[R].tooltipPosition),q=$.props.points[R].tooltipPayload);var G={activeTooltipIndex:R,isTooltipActive:!0,activeLabel:B,activePayload:q,activeCoordinate:Y};this.setState(G),this.renderCursor(D),this.accessibilityManager.setIndex(R)}}}},{key:"getSnapshotBeforeUpdate",value:function(O,T){if(!this.props.accessibilityLayer)return null;if(this.state.tooltipTicks!==T.tooltipTicks&&this.accessibilityManager.setDetails({coordinateList:this.state.tooltipTicks}),this.props.layout!==O.layout&&this.accessibilityManager.setDetails({layout:this.props.layout}),this.props.margin!==O.margin){var N,E;this.accessibilityManager.setDetails({offset:{left:(N=this.props.margin.left)!==null&&N!==void 0?N:0,top:(E=this.props.margin.top)!==null&&E!==void 0?E:0}})}return null}},{key:"componentDidUpdate",value:function(O){K1([Fn(O.children,hr)],[Fn(this.props.children,hr)])||this.displayDefaultTooltip()}},{key:"componentWillUnmount",value:function(){this.removeListener(),this.throttleTriggeredAfterMouseMove.cancel()}},{key:"getTooltipEventType",value:function(){var O=Fn(this.props.children,hr);if(O&&typeof O.props.shared=="boolean"){var T=O.props.shared?"axis":"item";return f.indexOf(T)>=0?T:o}return o}},{key:"getMouseInfo",value:function(O){if(!this.container)return null;var T=this.container,N=T.getBoundingClientRect(),E=LW(N),M={chartX:Math.round(O.pageX-E.left),chartY:Math.round(O.pageY-E.top)},D=N.width/T.offsetWidth||1,R=this.inRange(M.chartX,M.chartY,D);if(!R)return null;var B=this.state,q=B.xAxisMap,z=B.yAxisMap,H=this.getTooltipEventType(),X=Q3(this.state,this.props.data,this.props.layout,R);if(H!=="axis"&&q&&z){var Y=Ni(q).scale,$=Ni(z).scale,G=Y&&Y.invert?Y.invert(M.chartX):null,Q=$&&$.invert?$.invert(M.chartY):null;return re(re({},M),{},{xValue:G,yValue:Q},X)}return X?re(re({},M),X):null}},{key:"inRange",value:function(O,T){var N=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,E=this.props.layout,M=O/N,D=T/N;if(E==="horizontal"||E==="vertical"){var R=this.state.offset,B=M>=R.left&&M<=R.left+R.width&&D>=R.top&&D<=R.top+R.height;return B?{x:M,y:D}:null}var q=this.state,z=q.angleAxisMap,H=q.radiusAxisMap;if(z&&H){var X=Ni(z);return rk({x:M,y:D},X)}return null}},{key:"parseEventsOfWrapper",value:function(){var O=this.props.children,T=this.getTooltipEventType(),N=Fn(O,hr),E={};N&&T==="axis"&&(N.props.trigger==="click"?E={onClick:this.handleClick}:E={onMouseEnter:this.handleMouseEnter,onDoubleClick:this.handleDoubleClick,onMouseMove:this.handleMouseMove,onMouseLeave:this.handleMouseLeave,onTouchMove:this.handleTouchMove,onTouchStart:this.handleTouchStart,onTouchEnd:this.handleTouchEnd,onContextMenu:this.handleContextMenu});var M=Th(this.props,this.handleOuterEvent);return re(re({},M),E)}},{key:"addListener",value:function(){l1.on(c1,this.handleReceiveSyncEvent)}},{key:"removeListener",value:function(){l1.removeListener(c1,this.handleReceiveSyncEvent)}},{key:"filterFormatItem",value:function(O,T,N){for(var E=this.state.formattedGraphicalItems,M=0,D=E.length;M<D;M++){var R=E[M];if(R.item===O||R.props.key===O.key||T===Pa(R.item.type)&&N===R.childIndex)return R}return null}},{key:"renderClipPath",value:function(){var O=this.clipPathId,T=this.state.offset,N=T.left,E=T.top,M=T.height,D=T.width;return U.createElement("defs",null,U.createElement("clipPath",{id:O},U.createElement("rect",{x:N,y:E,height:M,width:D})))}},{key:"getXScales",value:function(){var O=this.state.xAxisMap;return O?Object.entries(O).reduce(function(T,N){var E=X3(N,2),M=E[0],D=E[1];return re(re({},T),{},_e({},M,D.scale))},{}):null}},{key:"getYScales",value:function(){var O=this.state.yAxisMap;return O?Object.entries(O).reduce(function(T,N){var E=X3(N,2),M=E[0],D=E[1];return re(re({},T),{},_e({},M,D.scale))},{}):null}},{key:"getXScaleByAxisId",value:function(O){var T;return(T=this.state.xAxisMap)===null||T===void 0||(T=T[O])===null||T===void 0?void 0:T.scale}},{key:"getYScaleByAxisId",value:function(O){var T;return(T=this.state.yAxisMap)===null||T===void 0||(T=T[O])===null||T===void 0?void 0:T.scale}},{key:"getItemByXY",value:function(O){var T=this.state,N=T.formattedGraphicalItems,E=T.activeItem;if(N&&N.length)for(var M=0,D=N.length;M<D;M++){var R=N[M],B=R.props,q=R.item,z=q.type.defaultProps!==void 0?re(re({},q.type.defaultProps),q.props):q.props,H=Pa(q.type);if(H==="Bar"){var X=(B.data||[]).find(function(Q){return aae(O,Q)});if(X)return{graphicalItem:R,payload:X}}else if(H==="RadialBar"){var Y=(B.data||[]).find(function(Q){return rk(O,Q)});if(Y)return{graphicalItem:R,payload:Y}}else if(mp(R,E)||pp(R,E)||zu(R,E)){var $=_ie({graphicalItem:R,activeTooltipItem:E,itemData:z.data}),G=z.activeIndex===void 0?$:z.activeIndex;return{graphicalItem:re(re({},R),{},{childIndex:G}),payload:zu(R,E)?z.data[$]:R.props.data[$]}}}return null}},{key:"render",value:function(){var O=this;if(!mC(this))return null;var T=this.props,N=T.children,E=T.className,M=T.width,D=T.height,R=T.style,B=T.compact,q=T.title,z=T.desc,H=W3(T,ace),X=Ne(H,!1);if(B)return U.createElement(C3,{state:this.state,width:this.props.width,height:this.props.height,clipPathId:this.clipPathId},U.createElement(X1,Ro({},X,{width:M,height:D,title:q,desc:z}),this.renderClipPath(),yC(N,this.renderMap)));if(this.props.accessibilityLayer){var Y,$;X.tabIndex=(Y=this.props.tabIndex)!==null&&Y!==void 0?Y:0,X.role=($=this.props.role)!==null&&$!==void 0?$:"application",X.onKeyDown=function(Q){O.accessibilityManager.keyboardEvent(Q)},X.onFocus=function(){O.accessibilityManager.focus()}}var G=this.parseEventsOfWrapper();return U.createElement(C3,{state:this.state,width:this.props.width,height:this.props.height,clipPathId:this.clipPathId},U.createElement("div",Ro({className:ze("recharts-wrapper",E),style:re({position:"relative",cursor:"default",width:M,height:D},R)},G,{ref:function(ie){O.container=ie}}),U.createElement(X1,Ro({},X,{width:M,height:D,title:q,desc:z,style:jce}),this.renderClipPath(),yC(N,this.renderMap)),this.renderLegend(),this.renderTooltip()))}}])})(P.Component);_e(w,"displayName",n),_e(w,"defaultProps",re({layout:"horizontal",stackOffset:"none",barCategoryGap:"10%",barGap:4,margin:{top:5,right:5,bottom:5,left:5},reverseStackOrder:!1,syncMethod:"index"},y)),_e(w,"getDerivedStateFromProps",function(b,A){var _=b.dataKey,O=b.data,T=b.children,N=b.width,E=b.height,M=b.layout,D=b.stackOffset,R=b.margin,B=A.dataStartIndex,q=A.dataEndIndex;if(A.updateId===void 0){var z=J3(b);return re(re(re({},z),{},{updateId:0},j(re(re({props:b},z),{},{updateId:0}),A)),{},{prevDataKey:_,prevData:O,prevWidth:N,prevHeight:E,prevLayout:M,prevStackOffset:D,prevMargin:R,prevChildren:T})}if(_!==A.prevDataKey||O!==A.prevData||N!==A.prevWidth||E!==A.prevHeight||M!==A.prevLayout||D!==A.prevStackOffset||!zo(R,A.prevMargin)){var H=J3(b),X={chartX:A.chartX,chartY:A.chartY,isTooltipActive:A.isTooltipActive},Y=re(re({},Q3(A,O,M)),{},{updateId:A.updateId+1}),$=re(re(re({},H),X),Y);return re(re(re({},$),j(re({props:b},$),A)),{},{prevDataKey:_,prevData:O,prevWidth:N,prevHeight:E,prevLayout:M,prevStackOffset:D,prevMargin:R,prevChildren:T})}if(!K1(T,A.prevChildren)){var G,Q,ie,le,L=Fn(T,nl),F=L&&(G=(Q=L.props)===null||Q===void 0?void 0:Q.startIndex)!==null&&G!==void 0?G:B,ae=L&&(ie=(le=L.props)===null||le===void 0?void 0:le.endIndex)!==null&&ie!==void 0?ie:q,fe=F!==B||ae!==q,xe=!Re(O),Ae=xe&&!fe?A.updateId:A.updateId+1;return re(re({updateId:Ae},j(re(re({props:b},A),{},{updateId:Ae,dataStartIndex:F,dataEndIndex:ae}),A)),{},{prevChildren:T,dataStartIndex:F,dataEndIndex:ae})}return null}),_e(w,"renderActiveDot",function(b,A,_){var O;return P.isValidElement(b)?O=P.cloneElement(b,A):Ce(b)?O=b(A):O=U.createElement(cp,A),U.createElement(Xe,{className:"recharts-active-dot",key:_},O)});var S=P.forwardRef(function(A,_){return U.createElement(w,Ro({},A,{ref:_}))});return S.displayName=w.displayName,S},Mce=iN({chartName:"LineChart",GraphicalChild:of,axisComponents:[{axisType:"xAxis",AxisComp:ul},{axisType:"yAxis",AxisComp:dl}],formatAxisMap:v6}),Pce=iN({chartName:"BarChart",GraphicalChild:Mi,defaultTooltipEventType:"axis",validateTooltipEventTypes:["axis","item"],axisComponents:[{axisType:"xAxis",AxisComp:ul},{axisType:"yAxis",AxisComp:dl}],formatAxisMap:v6}),Rce=iN({chartName:"PieChart",GraphicalChild:Ka,validateTooltipEventTypes:["item"],defaultTooltipEventType:"item",legendContent:"children",axisComponents:[{axisType:"angleAxis",AxisComp:hp},{axisType:"radiusAxis",AxisComp:fp}],formatAxisMap:pte,defaultProps:{layout:"centric",startAngle:0,endAngle:360,cx:"50%",cy:"50%",innerRadius:0,outerRadius:"80%"}});const kce=["Deals","Products","MRR","ARR"];function Dce(){const[e,t]=P.useState("Deals"),[n,r]=P.useState(""),[i,o]=P.useState(!0),[c,f]=P.useState(""),[d,h]=P.useState([]),[p,y]=P.useState([]),[x,j]=P.useState([]),[w,S]=P.useState([]),[b,A]=P.useState(0);P.useEffect(()=>{async function N(){o(!0),f("");try{const[E,M,D,R]=await Promise.all([zd.deals(),zd.products(),zd.mrr(),zd.arr()]);h(E.deals||[]),y(M.products||[]),A(D.mrr||0),j([]);const q=R;S([])}catch(E){f(E instanceof Error?E.message:"Failed to load sales data")}finally{o(!1)}}N()},[]);const _=d.reduce((N,E)=>N+(E.value||0),0),O=d.filter(N=>N.stage==="Closed Won").reduce((N,E)=>N+(E.value||0),0),T=p.filter(N=>N.active).length;return i?l.jsxs("div",{className:"space-y-8",children:[l.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-3 gap-5",children:[l.jsx(ke,{className:"h-[80px]"}),l.jsx(ke,{className:"h-[80px]"}),l.jsx(ke,{className:"h-[80px]"})]}),l.jsx(ke,{className:"h-[400px]"})]}):c?l.jsx("div",{className:"flex items-center justify-center h-64",children:l.jsx("p",{className:"text-danger",children:c})}):l.jsxs("div",{className:"space-y-8",children:[l.jsxs("div",{className:"flex flex-col sm:flex-row sm:items-center justify-between gap-4",children:[l.jsxs("div",{children:[l.jsx("h1",{className:"text-xl font-semibold text-text-primary",children:"Sales"}),l.jsx("p",{className:"text-sm text-text-secondary mt-0.5",children:"Deals, products, and revenue metrics"})]}),l.jsx(ht,{icon:l.jsx(Lr,{size:16}),children:"New Deal"})]}),l.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-3 gap-5",children:[l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary-light flex items-center justify-center text-primary",children:l.jsx(mz,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:we(_)}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Total Pipeline"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-success-light flex items-center justify-center text-success",children:l.jsx(ea,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:we(O)}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Closed Won"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-warning-light flex items-center justify-center text-warning",children:l.jsx(qH,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:T}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Active Products"})]})]})})]}),l.jsxs("div",{className:"flex flex-col sm:flex-row items-start sm:items-center justify-between gap-4",children:[l.jsx("div",{className:"flex items-center gap-1 bg-bg rounded-xl p-1",children:kce.map(N=>l.jsx("button",{onClick:()=>t(N),className:`px-4 py-2 text-sm font-medium rounded-lg transition-colors ${e===N?"bg-surface text-text-primary shadow-sm":"text-text-secondary hover:text-text-primary"}`,children:N},N))}),l.jsxs("div",{className:"flex items-center gap-2 w-full sm:w-auto",children:[l.jsxs("div",{className:"relative flex-1 sm:flex-initial",children:[l.jsx(Ts,{size:15,className:"absolute left-3 top-1/2 -translate-y-1/2 text-text-secondary"}),l.jsx("input",{type:"text",placeholder:"Search...",value:n,onChange:N=>r(N.target.value),className:"w-full sm:w-64 h-10 pl-9 pr-4 rounded-[14px] border bg-surface text-sm text-text-primary placeholder:text-text-secondary/50 focus:outline-none focus:ring-2 focus:ring-primary/20 focus:border-primary/30"})]}),l.jsx(ht,{variant:"secondary",size:"sm",icon:l.jsx(Wu,{size:14}),children:"Filter"})]})]}),e==="Deals"&&l.jsx(ee,{children:l.jsxs($a,{children:[l.jsx(Ba,{children:l.jsxs(Nt,{children:[l.jsx(be,{children:"Deal"}),l.jsx(be,{children:"Company"}),l.jsx(be,{align:"right",children:"Value"}),l.jsx(be,{children:"Stage"}),l.jsx(be,{align:"right",children:"Probability"}),l.jsx(be,{children:"Owner"}),l.jsx(be,{align:"right"})]})}),l.jsxs(qa,{children:[d.length===0&&l.jsx(Nt,{children:l.jsx(ge,{colSpan:7,className:"text-center text-text-secondary py-8",children:"No deals found"})}),d.map(N=>l.jsxs(Nt,{children:[l.jsx(ge,{children:l.jsx("span",{className:"font-medium",children:N.name})}),l.jsx(ge,{children:N.company}),l.jsx(ge,{align:"right",children:we(N.value)}),l.jsx(ge,{children:l.jsx(Se,{variant:N.stage==="Closed Won"?"success":N.stage==="Negotiation"?"primary":"default",children:N.stage})}),l.jsxs(ge,{align:"right",children:[N.probability,"%"]}),l.jsx(ge,{children:N.owner}),l.jsx(ge,{align:"right",children:l.jsx("button",{className:"w-8 h-8 flex items-center justify-center rounded-lg hover:bg-bg text-text-secondary",children:l.jsx(Jr,{size:16})})})]},N.id))]})]})}),e==="Products"&&l.jsx(ee,{children:l.jsxs($a,{children:[l.jsx(Ba,{children:l.jsxs(Nt,{children:[l.jsx(be,{children:"Product"}),l.jsx(be,{children:"SKU"}),l.jsx(be,{align:"right",children:"Price"}),l.jsx(be,{children:"Type"}),l.jsx(be,{children:"Status"}),l.jsx(be,{align:"right"})]})}),l.jsxs(qa,{children:[p.length===0&&l.jsx(Nt,{children:l.jsx(ge,{colSpan:6,className:"text-center text-text-secondary py-8",children:"No products found"})}),p.map(N=>l.jsxs(Nt,{children:[l.jsx(ge,{children:l.jsx("span",{className:"font-medium",children:N.name})}),l.jsx(ge,{children:l.jsx("code",{className:"text-xs bg-bg px-2 py-0.5 rounded-md",children:N.sku})}),l.jsx(ge,{align:"right",children:we(N.price)}),l.jsx(ge,{children:l.jsx(Se,{variant:N.recurring?"primary":"default",children:N.recurring?"Recurring":"One-time"})}),l.jsx(ge,{children:l.jsx(Se,{variant:N.active?"success":"danger",children:N.active?"Active":"Inactive"})}),l.jsx(ge,{align:"right",children:l.jsx("button",{className:"w-8 h-8 flex items-center justify-center rounded-lg hover:bg-bg text-text-secondary",children:l.jsx(Jr,{size:16})})})]},N.id))]})]})}),e==="MRR"&&l.jsxs(ee,{children:[l.jsx(Ie,{title:"Monthly Recurring Revenue",subtitle:`Current MRR: ${we(b)}`}),x.length>0?l.jsx("div",{className:"h-[320px]",children:l.jsx(cj,{width:"100%",height:"100%",children:l.jsxs(Pce,{data:x,margin:{top:5,right:5,left:-10,bottom:0},children:[l.jsx(nw,{strokeDasharray:"3 3",stroke:"rgba(0,0,0,0.04)",vertical:!1}),l.jsx(ul,{dataKey:"month",axisLine:!1,tickLine:!1,tick:{fontSize:11,fill:"#9CA3AF"},dy:8}),l.jsx(dl,{axisLine:!1,tickLine:!1,tick:{fontSize:11,fill:"#9CA3AF"},tickFormatter:N=>`${(N/1e3).toFixed(0)}k`,dx:-5}),l.jsx(hr,{content:({active:N,payload:E,label:M})=>!N||!(E!=null&&E.length)?null:l.jsxs("div",{className:"bg-surface rounded-xl dropdown-shadow border border-border/60 px-4 py-3",children:[l.jsx("p",{className:"text-xs font-medium text-text-secondary mb-2",children:M}),E.map((D,R)=>l.jsxs("div",{className:"flex items-center gap-2 text-sm",children:[l.jsx("div",{className:"w-2 h-2 rounded-full",style:{backgroundColor:D.color}}),l.jsxs("span",{className:"text-text-secondary",children:[D.name,":"]}),l.jsx("span",{className:"font-semibold text-text-primary",children:we(Number(D.value))})]},R))]})}),l.jsx(Mi,{dataKey:"mrr",fill:"#2563EB",radius:[4,4,0,0]}),l.jsx(Mi,{dataKey:"arr",fill:"#16A34A",radius:[4,4,0,0]})]})})}):l.jsx("div",{className:"h-[200px] flex items-center justify-center text-text-secondary",children:"No MRR history data available"})]}),e==="ARR"&&l.jsxs(ee,{children:[l.jsx(Ie,{title:"Annual Recurring Revenue",subtitle:"ARR growth by quarter"}),w.length>0?l.jsx("div",{className:"h-[320px]",children:l.jsx(cj,{width:"100%",height:"100%",children:l.jsxs(Mce,{data:w,margin:{top:5,right:5,left:-10,bottom:0},children:[l.jsx(nw,{strokeDasharray:"3 3",stroke:"rgba(0,0,0,0.04)",vertical:!1}),l.jsx(ul,{dataKey:"quarter",axisLine:!1,tickLine:!1,tick:{fontSize:11,fill:"#9CA3AF"},dy:8}),l.jsx(dl,{axisLine:!1,tickLine:!1,tick:{fontSize:11,fill:"#9CA3AF"},tickFormatter:N=>`${(N/1e3).toFixed(0)}k`,dx:-5}),l.jsx(hr,{content:({active:N,payload:E,label:M})=>!N||!(E!=null&&E.length)?null:l.jsxs("div",{className:"bg-surface rounded-xl dropdown-shadow border border-border/60 px-4 py-3",children:[l.jsx("p",{className:"text-xs font-medium text-text-secondary mb-1",children:M}),l.jsx("p",{className:"text-sm font-semibold text-text-primary",children:we(Number(E[0].value))})]})}),l.jsx(of,{type:"monotone",dataKey:"arr",stroke:"#2563EB",strokeWidth:2,dot:{r:4,strokeWidth:0,fill:"#2563EB"},activeDot:{r:6}})]})})}):l.jsx("div",{className:"h-[200px] flex items-center justify-center text-text-secondary",children:"No ARR history data available"})]})]})}const zce=["Balance","Income","MOMS","Accounts","Invoices","Cashflow"],tD=["#2563EB","#16A34A","#D97706","#DC2626","#9CA3AF"];function Lce(){var M,D;const[e,t]=P.useState("Balance"),[n,r]=P.useState(""),[i,o]=P.useState(!0),[c,f]=P.useState(""),[d,h]=P.useState(null),[p,y]=P.useState(null),[x,j]=P.useState(null),[w,S]=P.useState([]),[b,A]=P.useState([]),[_,O]=P.useState(null);P.useEffect(()=>{async function R(){var B,q;o(!0),f("");try{const[z,H,X,Y,$,G]=await Promise.all([vo.balance(),vo.income(),vo.moms(),vo.accounts(),vo.invoices(),vo.cashflow()]);h(z.report||z),y(H.report||H),j(X.report||X),S(((B=Y.report)==null?void 0:B.accounts)||Y.accounts||[]),A(((q=$.report)==null?void 0:q.invoices)||$.invoices||[]),O(G.report||G)}catch(z){f(z instanceof Error?z.message:"Failed to load finance data")}finally{o(!1)}}R()},[]);const T=w.filter(R=>R.name.toLowerCase().includes(n.toLowerCase())||R.id.toLowerCase().includes(n.toLowerCase())),N=b.filter(R=>R.customer.toLowerCase().includes(n.toLowerCase())||R.id.toLowerCase().includes(n.toLowerCase())),E=(p==null?void 0:p.expenses.map((R,B)=>({name:R.name||R.account,value:R.amount??R.balance??0,color:tD[B%tD.length]})))||[];return i?l.jsxs("div",{className:"space-y-8",children:[l.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-3 gap-5",children:[l.jsx(ke,{className:"h-[80px]"}),l.jsx(ke,{className:"h-[80px]"}),l.jsx(ke,{className:"h-[80px]"})]}),l.jsx(ke,{className:"h-[400px]"})]}):c?l.jsx("div",{className:"flex items-center justify-center h-64",children:l.jsx("p",{className:"text-danger",children:c})}):l.jsxs("div",{className:"space-y-8",children:[l.jsxs("div",{className:"flex flex-col sm:flex-row sm:items-center justify-between gap-4",children:[l.jsxs("div",{children:[l.jsx("h1",{className:"text-xl font-semibold text-text-primary",children:"Finance"}),l.jsx("p",{className:"text-sm text-text-secondary mt-0.5",children:"Financial reports and accounting"})]}),l.jsx(ht,{icon:l.jsx(Lr,{size:16}),children:"New Invoice"})]}),l.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-3 gap-5",children:[l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary-light flex items-center justify-center text-primary",children:l.jsx(vs,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:we((d==null?void 0:d.total_assets)||0)}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Total Assets"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-success-light flex items-center justify-center text-success",children:l.jsx(ea,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:we((p==null?void 0:p.total_revenue)||0)}),l.jsx("p",{className:"text-xs text-text-secondary",children:"YTD Revenue"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-warning-light flex items-center justify-center text-warning",children:l.jsx(Nz,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:we((p==null?void 0:p.total_expense)||(p==null?void 0:p.total_expenses)||0)}),l.jsx("p",{className:"text-xs text-text-secondary",children:"YTD Expenses"})]})]})})]}),l.jsxs("div",{className:"flex flex-col sm:flex-row items-start sm:items-center justify-between gap-4",children:[l.jsx("div",{className:"flex items-center gap-1 bg-bg rounded-xl p-1 overflow-x-auto max-w-full",children:zce.map(R=>l.jsx("button",{onClick:()=>t(R),className:`px-4 py-2 text-sm font-medium rounded-lg transition-colors whitespace-nowrap ${e===R?"bg-surface text-text-primary shadow-sm":"text-text-secondary hover:text-text-primary"}`,children:R},R))}),l.jsxs("div",{className:"flex items-center gap-2 w-full sm:w-auto",children:[l.jsxs("div",{className:"relative flex-1 sm:flex-initial",children:[l.jsx(Ts,{size:15,className:"absolute left-3 top-1/2 -translate-y-1/2 text-text-secondary"}),l.jsx("input",{type:"text",placeholder:"Search...",value:n,onChange:R=>r(R.target.value),className:"w-full sm:w-64 h-10 pl-9 pr-4 rounded-[14px] border bg-surface text-sm text-text-primary placeholder:text-text-secondary/50 focus:outline-none focus:ring-2 focus:ring-primary/20 focus:border-primary/30"})]}),l.jsx(ht,{variant:"secondary",size:"sm",icon:l.jsx(Wu,{size:14}),children:"Filter"})]})]}),e==="Balance"&&l.jsxs("div",{className:"space-y-6",children:[l.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-5",children:[l.jsxs(ee,{children:[l.jsxs("div",{className:"flex items-center justify-between mb-3",children:[l.jsx("span",{className:"text-sm text-text-secondary",children:"Assets"}),l.jsx(qT,{size:14,className:"text-success"})]}),l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:we((d==null?void 0:d.total_assets)||0)})]}),l.jsxs(ee,{children:[l.jsxs("div",{className:"flex items-center justify-between mb-3",children:[l.jsx("span",{className:"text-sm text-text-secondary",children:"Liabilities"}),l.jsx(gH,{size:14,className:"text-danger"})]}),l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:we((d==null?void 0:d.total_liabilities)||0)})]}),l.jsxs(ee,{children:[l.jsxs("div",{className:"flex items-center justify-between mb-3",children:[l.jsx("span",{className:"text-sm text-text-secondary",children:"Equity"}),l.jsx(qT,{size:14,className:"text-success"})]}),l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:we((d==null?void 0:d.total_equity)||0)})]})]}),l.jsxs(ee,{children:[l.jsx(Ie,{title:"Balance Sheet",subtitle:`Period: ${(d==null?void 0:d.period)||""}`}),l.jsxs("div",{className:"space-y-6",children:[l.jsxs("div",{children:[l.jsx("h4",{className:"text-sm font-semibold text-text-primary mb-3",children:"Assets"}),l.jsxs("div",{className:"space-y-2",children:[d==null?void 0:d.assets.map((R,B)=>l.jsxs("div",{className:"flex items-center justify-between py-2 border-b border-border/40 last:border-0",children:[l.jsx("div",{children:l.jsx("p",{className:"text-sm text-text-primary",children:R.name||R.account})}),l.jsx("p",{className:"text-sm font-medium text-text-primary",children:we(R.amount??R.balance??0)})]},B)),(!(d!=null&&d.assets)||d.assets.length===0)&&l.jsx("p",{className:"text-text-secondary text-sm",children:"No asset accounts"})]})]}),l.jsxs("div",{children:[l.jsx("h4",{className:"text-sm font-semibold text-text-primary mb-3",children:"Liabilities"}),l.jsxs("div",{className:"space-y-2",children:[d==null?void 0:d.liabilities.map((R,B)=>l.jsxs("div",{className:"flex items-center justify-between py-2 border-b border-border/40 last:border-0",children:[l.jsx("div",{children:l.jsx("p",{className:"text-sm text-text-primary",children:R.name||R.account})}),l.jsx("p",{className:"text-sm font-medium text-text-primary",children:we(R.amount??R.balance??0)})]},B)),(!(d!=null&&d.liabilities)||d.liabilities.length===0)&&l.jsx("p",{className:"text-text-secondary text-sm",children:"No liability accounts"})]})]}),l.jsxs("div",{children:[l.jsx("h4",{className:"text-sm font-semibold text-text-primary mb-3",children:"Equity"}),l.jsxs("div",{className:"space-y-2",children:[(M=d==null?void 0:d.equity)==null?void 0:M.map((R,B)=>l.jsxs("div",{className:"flex items-center justify-between py-2 border-b border-border/40 last:border-0",children:[l.jsx("div",{children:l.jsx("p",{className:"text-sm text-text-primary",children:R.name||R.account})}),l.jsx("p",{className:"text-sm font-medium text-text-primary",children:we(R.amount??R.balance??0)})]},B)),(!(d!=null&&d.equity)||((D=d.equity)==null?void 0:D.length)===0)&&l.jsx("p",{className:"text-text-secondary text-sm",children:"No equity accounts"})]})]})]})]})]}),e==="Income"&&l.jsx("div",{className:"space-y-6",children:l.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-3 gap-5",children:[l.jsxs(ee,{className:"lg:col-span-2",children:[l.jsx(Ie,{title:"Income Statement",subtitle:`Period: ${(p==null?void 0:p.period)||""}`}),l.jsxs("div",{className:"space-y-4",children:[l.jsxs("div",{className:"grid grid-cols-3 gap-4",children:[l.jsxs("div",{className:"p-4 bg-bg rounded-xl",children:[l.jsx("p",{className:"text-xs text-text-secondary mb-1",children:"Revenue"}),l.jsx("p",{className:"text-lg font-semibold text-text-primary",children:we((p==null?void 0:p.total_revenue)||0)})]}),l.jsxs("div",{className:"p-4 bg-bg rounded-xl",children:[l.jsx("p",{className:"text-xs text-text-secondary mb-1",children:"Expenses"}),l.jsx("p",{className:"text-lg font-semibold text-text-primary",children:we((p==null?void 0:p.total_expense)||(p==null?void 0:p.total_expenses)||0)})]}),l.jsxs("div",{className:"p-4 bg-bg rounded-xl",children:[l.jsx("p",{className:"text-xs text-text-secondary mb-1",children:"Net Income"}),l.jsx("p",{className:"text-lg font-semibold text-success",children:we((p==null?void 0:p.net_income)||0)})]})]}),l.jsxs("div",{className:"space-y-2",children:[l.jsx("h4",{className:"text-sm font-semibold text-text-primary",children:"Revenue Accounts"}),p==null?void 0:p.revenue.map((R,B)=>l.jsxs("div",{className:"flex items-center justify-between py-2 border-b border-border/40 last:border-0",children:[l.jsx("p",{className:"text-sm text-text-primary",children:R.name||R.account}),l.jsx("p",{className:"text-sm font-medium text-text-primary",children:we(R.amount??R.balance??0)})]},B))]}),l.jsxs("div",{className:"space-y-2",children:[l.jsx("h4",{className:"text-sm font-semibold text-text-primary",children:"Expense Accounts"}),p==null?void 0:p.expenses.map((R,B)=>l.jsxs("div",{className:"flex items-center justify-between py-2 border-b border-border/40 last:border-0",children:[l.jsx("p",{className:"text-sm text-text-primary",children:R.name||R.account}),l.jsx("p",{className:"text-sm font-medium text-text-primary",children:we(R.amount??R.balance??0)})]},B))]})]})]}),l.jsxs(ee,{children:[l.jsx(Ie,{title:"Expense Breakdown",subtitle:"By category"}),E.length>0?l.jsxs(l.Fragment,{children:[l.jsx("div",{className:"h-[220px]",children:l.jsx(cj,{width:"100%",height:"100%",children:l.jsxs(Rce,{children:[l.jsx(Ka,{data:E,cx:"50%",cy:"50%",innerRadius:60,outerRadius:90,paddingAngle:4,dataKey:"value",children:E.map((R,B)=>l.jsx(Zm,{fill:R.color},`cell-${B}`))}),l.jsx(hr,{content:({active:R,payload:B})=>{if(!R||!(B!=null&&B.length))return null;const q=B[0].payload;return l.jsxs("div",{className:"bg-surface rounded-xl dropdown-shadow border border-border/60 px-3 py-2",children:[l.jsx("p",{className:"text-sm font-medium text-text-primary",children:q.name}),l.jsx("p",{className:"text-xs text-text-secondary",children:we(q.value)})]})}})]})})}),l.jsx("div",{className:"space-y-2 mt-2",children:E.map(R=>l.jsxs("div",{className:"flex items-center justify-between text-sm",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx("div",{className:"w-2.5 h-2.5 rounded-full",style:{backgroundColor:R.color}}),l.jsx("span",{className:"text-text-secondary",children:R.name})]}),l.jsx("span",{className:"font-medium text-text-primary",children:we(R.value)})]},R.name))})]}):l.jsx("div",{className:"h-[200px] flex items-center justify-center text-text-secondary",children:"No expense data"})]})]})}),e==="MOMS"&&l.jsxs(ee,{children:[l.jsx(Ie,{title:"MOMS Report",subtitle:`Period: ${(x==null?void 0:x.period)||""}`}),l.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-5 mb-6",children:[l.jsxs("div",{className:"p-4 bg-bg rounded-xl",children:[l.jsx("p",{className:"text-xs text-text-secondary mb-1",children:"MOMS In (Input VAT)"}),l.jsx("p",{className:"text-lg font-semibold text-text-primary",children:we((x==null?void 0:x.moms_in)||0)})]}),l.jsxs("div",{className:"p-4 bg-bg rounded-xl",children:[l.jsx("p",{className:"text-xs text-text-secondary mb-1",children:"MOMS Ut (Output VAT)"}),l.jsx("p",{className:"text-lg font-semibold text-text-primary",children:we((x==null?void 0:x.moms_ut)||0)})]}),l.jsxs("div",{className:"p-4 bg-bg rounded-xl",children:[l.jsx("p",{className:"text-xs text-text-secondary mb-1",children:"MOMS att betala"}),l.jsx("p",{className:"text-lg font-semibold text-success",children:we((x==null?void 0:x.moms_att_betala)||0)})]})]})]}),e==="Accounts"&&l.jsxs(ee,{children:[l.jsx(Ie,{title:"Chart of Accounts",subtitle:"General ledger accounts"}),l.jsxs($a,{children:[l.jsx(Ba,{children:l.jsxs(Nt,{children:[l.jsx(be,{children:"Account"}),l.jsx(be,{children:"Number"}),l.jsx(be,{children:"Type"}),l.jsx(be,{align:"right",children:"Balance"}),l.jsx(be,{align:"right"})]})}),l.jsxs(qa,{children:[T.map(R=>l.jsxs(Nt,{children:[l.jsx(ge,{children:l.jsx("span",{className:"font-medium",children:R.name})}),l.jsx(ge,{children:l.jsx("code",{className:"text-xs bg-bg px-2 py-0.5 rounded-md",children:R.id})}),l.jsx(ge,{children:l.jsx(Se,{variant:R.type==="asset"?"success":R.type==="equity"?"primary":"warning",children:R.type})}),l.jsx(ge,{align:"right",children:we(R.balance)}),l.jsx(ge,{align:"right",children:l.jsx("button",{className:"w-8 h-8 flex items-center justify-center rounded-lg hover:bg-bg text-text-secondary",children:l.jsx(Jr,{size:16})})})]},R.id)),T.length===0&&l.jsx(Nt,{children:l.jsx(ge,{colSpan:5,className:"text-center text-text-secondary py-8",children:"No accounts found"})})]})]})]}),e==="Invoices"&&l.jsxs(ee,{children:[l.jsx(Ie,{title:"Invoices",subtitle:"All invoices"}),l.jsxs($a,{children:[l.jsx(Ba,{children:l.jsxs(Nt,{children:[l.jsx(be,{children:"Number"}),l.jsx(be,{children:"Customer"}),l.jsx(be,{align:"right",children:"Amount"}),l.jsx(be,{children:"Status"}),l.jsx(be,{children:"Due Date"}),l.jsx(be,{align:"right"})]})}),l.jsxs(qa,{children:[N.map(R=>l.jsxs(Nt,{children:[l.jsx(ge,{children:l.jsx("span",{className:"font-medium",children:R.id})}),l.jsx(ge,{children:R.customer}),l.jsx(ge,{align:"right",children:we(R.amount)}),l.jsx(ge,{children:l.jsx(Se,{variant:R.status==="paid"?"success":R.status==="overdue"?"danger":R.status==="sent"||R.status==="pending"?"primary":"default",children:R.status})}),l.jsx(ge,{children:Rt(R.due_date)}),l.jsx(ge,{align:"right",children:l.jsx("button",{className:"w-8 h-8 flex items-center justify-center rounded-lg hover:bg-bg text-text-secondary",children:l.jsx(Jr,{size:16})})})]},R.id)),N.length===0&&l.jsx(Nt,{children:l.jsx(ge,{colSpan:6,className:"text-center text-text-secondary py-8",children:"No invoices found"})})]})]})]}),e==="Cashflow"&&l.jsxs(ee,{children:[l.jsx(Ie,{title:"Cash Flow",subtitle:`Period: ${(_==null?void 0:_.period)||""}`}),l.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-5 mb-6",children:[l.jsxs("div",{className:"p-4 bg-bg rounded-xl",children:[l.jsx("p",{className:"text-xs text-text-secondary mb-1",children:"Inflow"}),l.jsx("p",{className:"text-lg font-semibold text-success",children:we((_==null?void 0:_.inflow)||0)})]}),l.jsxs("div",{className:"p-4 bg-bg rounded-xl",children:[l.jsx("p",{className:"text-xs text-text-secondary mb-1",children:"Outflow"}),l.jsx("p",{className:"text-lg font-semibold text-danger",children:we((_==null?void 0:_.outflow)||0)})]}),l.jsxs("div",{className:"p-4 bg-bg rounded-xl",children:[l.jsx("p",{className:"text-xs text-text-secondary mb-1",children:"Net"}),l.jsx("p",{className:"text-lg font-semibold text-text-primary",children:we((_==null?void 0:_.net)||0)})]})]})]})]})}const $ce=["Employees","Leaves"],Bce={Sales:"primary",Engineering:"success",Finance:"warning",HR:"primary",Legal:"default"};function qce(){const[e,t]=P.useState("Employees"),[n,r]=P.useState(""),[i,o]=P.useState(!0),[c,f]=P.useState(""),[d,h]=P.useState([]),[p,y]=P.useState([]);P.useEffect(()=>{async function A(){o(!0),f("");try{const[_,O]=await Promise.all([aE.employees(),aE.leaves()]);h(_.employees||[]),y(O.leaves||[])}catch(_){f(_ instanceof Error?_.message:"Failed to load HR data")}finally{o(!1)}}A()},[]);const x=d.filter(A=>A.status==="active").length,j=d.filter(A=>A.status==="on_leave").length,w=p.filter(A=>A.status==="pending").length,S=d.filter(A=>(A.name||`${A.first_name} ${A.last_name}`).toLowerCase().includes(n.toLowerCase())||A.department.toLowerCase().includes(n.toLowerCase())||(A.role||A.position).toLowerCase().includes(n.toLowerCase())),b=p.filter(A=>A.employeeName.toLowerCase().includes(n.toLowerCase())||A.type.toLowerCase().includes(n.toLowerCase()));return i?l.jsxs("div",{className:"space-y-8",children:[l.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-3 gap-5",children:[l.jsx(ke,{className:"h-[80px]"}),l.jsx(ke,{className:"h-[80px]"}),l.jsx(ke,{className:"h-[80px]"})]}),l.jsx(ke,{className:"h-[400px]"})]}):c?l.jsx("div",{className:"flex items-center justify-center h-64",children:l.jsx("p",{className:"text-danger",children:c})}):l.jsxs("div",{className:"space-y-8",children:[l.jsxs("div",{className:"flex flex-col sm:flex-row sm:items-center justify-between gap-4",children:[l.jsxs("div",{children:[l.jsx("h1",{className:"text-xl font-semibold text-text-primary",children:"HR"}),l.jsx("p",{className:"text-sm text-text-secondary mt-0.5",children:"Employees and leave management"})]}),l.jsx(ht,{icon:l.jsx(Lr,{size:16}),children:"Add Employee"})]}),l.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-3 gap-5",children:[l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary-light flex items-center justify-center text-primary",children:l.jsx(Wn,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:x}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Active Employees"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-warning-light flex items-center justify-center text-warning",children:l.jsx(vr,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:j}),l.jsx("p",{className:"text-xs text-text-secondary",children:"On Leave"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-success-light flex items-center justify-center text-success",children:l.jsx(wH,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:w}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Pending Requests"})]})]})})]}),l.jsxs("div",{className:"flex flex-col sm:flex-row items-start sm:items-center justify-between gap-4",children:[l.jsx("div",{className:"flex items-center gap-1 bg-bg rounded-xl p-1",children:$ce.map(A=>l.jsx("button",{onClick:()=>t(A),className:`px-4 py-2 text-sm font-medium rounded-lg transition-colors ${e===A?"bg-surface text-text-primary shadow-sm":"text-text-secondary hover:text-text-primary"}`,children:A},A))}),l.jsxs("div",{className:"flex items-center gap-2 w-full sm:w-auto",children:[l.jsxs("div",{className:"relative flex-1 sm:flex-initial",children:[l.jsx(Ts,{size:15,className:"absolute left-3 top-1/2 -translate-y-1/2 text-text-secondary"}),l.jsx("input",{type:"text",placeholder:"Search...",value:n,onChange:A=>r(A.target.value),className:"w-full sm:w-64 h-10 pl-9 pr-4 rounded-[14px] border bg-surface text-sm text-text-primary placeholder:text-text-secondary/50 focus:outline-none focus:ring-2 focus:ring-primary/20 focus:border-primary/30"})]}),l.jsx(ht,{variant:"secondary",size:"sm",icon:l.jsx(Wu,{size:14}),children:"Filter"})]})]}),e==="Employees"&&l.jsx(ee,{children:l.jsxs($a,{children:[l.jsx(Ba,{children:l.jsxs(Nt,{children:[l.jsx(be,{children:"Employee"}),l.jsx(be,{children:"Department"}),l.jsx(be,{children:"Role"}),l.jsx(be,{children:"Status"}),l.jsx(be,{children:"Start Date"}),l.jsx(be,{align:"right"})]})}),l.jsxs(qa,{children:[S.map(A=>{const _=A.name||`${A.first_name} ${A.last_name}`,O=A.role||A.position,T=A.startDate||A.start_date;return l.jsxs(Nt,{children:[l.jsx(ge,{children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-8 h-8 rounded-lg bg-primary/10 text-primary flex items-center justify-center text-xs font-semibold",children:_.split(" ").map(N=>N[0]).join("")}),l.jsxs("div",{children:[l.jsx("p",{className:"font-medium text-text-primary",children:_}),l.jsx("p",{className:"text-xs text-text-secondary",children:A.email})]})]})}),l.jsx(ge,{children:l.jsx(Se,{variant:Bce[A.department]||"default",children:A.department})}),l.jsx(ge,{children:O}),l.jsx(ge,{children:l.jsx(Se,{variant:A.status==="active"?"success":A.status==="on_leave"?"warning":"danger",children:A.status.replace("_"," ")})}),l.jsx(ge,{children:Rt(T||"")}),l.jsx(ge,{align:"right",children:l.jsx("button",{className:"w-8 h-8 flex items-center justify-center rounded-lg hover:bg-bg text-text-secondary",children:l.jsx(Jr,{size:16})})})]},A.id)}),S.length===0&&l.jsx(Nt,{children:l.jsx(ge,{colSpan:6,className:"text-center text-text-secondary py-8",children:"No employees found"})})]})]})}),e==="Leaves"&&l.jsx(ee,{children:l.jsxs($a,{children:[l.jsx(Ba,{children:l.jsxs(Nt,{children:[l.jsx(be,{children:"Employee"}),l.jsx(be,{children:"Type"}),l.jsx(be,{children:"Period"}),l.jsx(be,{align:"right",children:"Days"}),l.jsx(be,{children:"Status"}),l.jsx(be,{align:"right"})]})}),l.jsxs(qa,{children:[b.map(A=>l.jsxs(Nt,{children:[l.jsx(ge,{children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-8 h-8 rounded-lg bg-primary/10 text-primary flex items-center justify-center text-xs font-semibold",children:A.employeeName.split(" ").map(_=>_[0]).join("")}),l.jsx("span",{className:"font-medium text-text-primary",children:A.employeeName})]})}),l.jsx(ge,{children:l.jsx(Se,{variant:A.type==="vacation"?"primary":A.type==="sick"?"warning":"default",children:A.type})}),l.jsx(ge,{children:l.jsxs("span",{className:"text-sm text-text-primary",children:[Rt(A.startDate)," — ",Rt(A.endDate)]})}),l.jsx(ge,{align:"right",children:l.jsx("span",{className:"font-medium",children:A.days})}),l.jsx(ge,{children:l.jsx(Se,{variant:A.status==="approved"?"success":A.status==="pending"?"warning":"danger",children:A.status})}),l.jsx(ge,{align:"right",children:l.jsx("button",{className:"w-8 h-8 flex items-center justify-center rounded-lg hover:bg-bg text-text-secondary",children:l.jsx(Jr,{size:16})})})]},A.id)),b.length===0&&l.jsx(Nt,{children:l.jsx(ge,{colSpan:6,className:"text-center text-text-secondary py-8",children:"No leave requests found"})})]})]})})]})}const nD={draft:{variant:"default",icon:vr},pending_signature:{variant:"warning",icon:vr},active:{variant:"success",icon:Xu},expired:{variant:"danger",icon:Yt},terminated:{variant:"default",icon:Yt},disputed:{variant:"danger",icon:Yt}},Ice={aamos:"primary",quixzoom:"success",legal:"warning",hr:"default"};function rD(){const[e,t]=P.useState("contracts"),[n,r]=P.useState(""),[i,o]=P.useState(!0),[c,f]=P.useState(""),[d,h]=P.useState([]),[p,y]=P.useState([]),[x,j]=P.useState([]),[w,S]=P.useState(null),[b,A]=P.useState(!1);P.useEffect(()=>{async function N(){o(!0),f("");try{const[E,M,D]=await Promise.all([fetch("/api/v1/legal/contracts").then(R=>R.json()),fetch("/api/v1/legal/templates").then(R=>R.json()),fetch("/api/v1/legal/product-links").then(R=>R.json())]);h(E.contracts||[]),y(M.templates||[]),j(D.links||[])}catch(E){f(E instanceof Error?E.message:"Failed to load legal data")}finally{o(!1)}}N()},[]);const _=d.filter(N=>N.name.toLowerCase().includes(n.toLowerCase())||N.counterparty.toLowerCase().includes(n.toLowerCase())||N.template_type.toLowerCase().includes(n.toLowerCase())),O=p.filter(N=>N.name.toLowerCase().includes(n.toLowerCase())||N.description.toLowerCase().includes(n.toLowerCase())||N.category.toLowerCase().includes(n.toLowerCase()));if(i)return l.jsxs("div",{className:"space-y-8",children:[l.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-4 gap-5",children:[l.jsx(ke,{className:"h-[80px]"}),l.jsx(ke,{className:"h-[80px]"}),l.jsx(ke,{className:"h-[80px]"}),l.jsx(ke,{className:"h-[80px]"})]}),l.jsx(ke,{className:"h-[400px]"})]});if(c)return l.jsx("div",{className:"flex items-center justify-center h-64",children:l.jsx("p",{className:"text-danger",children:c})});const T=[{id:"contracts",label:"Avtal",icon:Oi},{id:"templates",label:"Mallar",icon:_H},{id:"products",label:"Produktkopplingar",icon:ou}];return l.jsxs("div",{className:"space-y-8",children:[l.jsxs("div",{className:"flex flex-col sm:flex-row sm:items-center justify-between gap-4",children:[l.jsxs("div",{children:[l.jsx("h1",{className:"text-xl font-semibold text-text-primary",children:"Legal"}),l.jsx("p",{className:"text-sm text-text-secondary mt-0.5",children:"Avtal, mallar och produktkopplingar"})]}),l.jsx(ht,{icon:l.jsx(Lr,{size:16}),children:"Nytt avtal"})]}),l.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-4 gap-5",children:[l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary/10 text-primary flex items-center justify-center",children:l.jsx(Oi,{size:20})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold",children:d.length}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Totalt avtal"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-success/10 text-success flex items-center justify-center",children:l.jsx(Xu,{size:20})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold",children:d.filter(N=>N.status==="active").length}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Aktiva"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-warning/10 text-warning flex items-center justify-center",children:l.jsx(vr,{size:20})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold",children:d.filter(N=>N.status==="pending_signature").length}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Väntar signering"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-danger/10 text-danger flex items-center justify-center",children:l.jsx(Yt,{size:20})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold",children:d.filter(N=>N.status==="expired"||N.status==="terminated").length}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Utgångna"})]})]})})]}),l.jsx("div",{className:"flex items-center gap-1 bg-bg rounded-xl p-1 overflow-x-auto",children:T.map(N=>l.jsxs("button",{onClick:()=>t(N.id),className:`px-4 py-2 text-sm font-medium rounded-lg transition-colors whitespace-nowrap flex items-center gap-2 ${e===N.id?"bg-surface text-text-primary shadow-sm":"text-text-secondary hover:text-text-primary"}`,children:[l.jsx(N.icon,{size:16}),N.label]},N.id))}),l.jsxs("div",{className:"relative",children:[l.jsx(Ts,{size:16,className:"absolute left-3 top-1/2 -translate-y-1/2 text-text-secondary"}),l.jsx("input",{type:"text",placeholder:"Sök avtal, mallar eller produkter...",value:n,onChange:N=>r(N.target.value),className:"w-full h-10 pl-9 pr-4 rounded-[14px] border bg-surface text-sm"})]}),e==="contracts"&&l.jsx(ee,{children:l.jsx("div",{className:"overflow-x-auto",children:l.jsxs("table",{className:"w-full",children:[l.jsx("thead",{children:l.jsxs("tr",{className:"border-b border-border",children:[l.jsx("th",{className:"text-left text-xs font-medium text-text-secondary uppercase tracking-wider px-4 py-3",children:"Avtal"}),l.jsx("th",{className:"text-left text-xs font-medium text-text-secondary uppercase tracking-wider px-4 py-3",children:"Motpart"}),l.jsx("th",{className:"text-left text-xs font-medium text-text-secondary uppercase tracking-wider px-4 py-3",children:"Typ"}),l.jsx("th",{className:"text-left text-xs font-medium text-text-secondary uppercase tracking-wider px-4 py-3",children:"Status"}),l.jsx("th",{className:"text-left text-xs font-medium text-text-secondary uppercase tracking-wider px-4 py-3",children:"Värde"}),l.jsx("th",{className:"text-left text-xs font-medium text-text-secondary uppercase tracking-wider px-4 py-3",children:"Period"}),l.jsx("th",{className:"text-right text-xs font-medium text-text-secondary uppercase tracking-wider px-4 py-3"})]})}),l.jsxs("tbody",{className:"divide-y divide-border",children:[_.map(N=>{const E=nD[N.status]||nD.draft;return l.jsxs("tr",{className:"hover:bg-bg transition-colors",children:[l.jsx("td",{className:"px-4 py-3",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-8 h-8 rounded-lg bg-primary/10 text-primary flex items-center justify-center",children:l.jsx(Oi,{size:14})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-sm font-medium text-text-primary",children:N.name}),l.jsx("p",{className:"text-xs text-text-secondary",children:N.template_type})]})]})}),l.jsxs("td",{className:"px-4 py-3",children:[l.jsx("p",{className:"text-sm text-text-primary",children:N.counterparty}),N.counterparty_org&&l.jsx("p",{className:"text-xs text-text-secondary",children:N.counterparty_org})]}),l.jsx("td",{className:"px-4 py-3",children:l.jsx(Se,{variant:"default",className:"text-xs",children:N.template_type})}),l.jsx("td",{className:"px-4 py-3",children:l.jsxs(Se,{variant:E.variant,className:"text-xs flex items-center gap-1",children:[l.jsx(E.icon,{size:12}),N.status]})}),l.jsx("td",{className:"px-4 py-3",children:N.value?l.jsxs("p",{className:"text-sm font-medium",children:[we(N.value)," ",N.currency]}):l.jsx("p",{className:"text-sm text-text-secondary",children:"—"})}),l.jsx("td",{className:"px-4 py-3",children:l.jsxs("p",{className:"text-sm text-text-secondary",children:[N.start_date?Rt(N.start_date):"—",N.end_date&&` → ${Rt(N.end_date)}`]})}),l.jsx("td",{className:"px-4 py-3 text-right",children:l.jsxs("div",{className:"flex items-center justify-end gap-1",children:[l.jsx("button",{className:"w-8 h-8 flex items-center justify-center rounded-lg hover:bg-bg text-text-secondary",children:l.jsx(pz,{size:14})}),l.jsx("button",{className:"w-8 h-8 flex items-center justify-center rounded-lg hover:bg-bg text-text-secondary",children:l.jsx(UT,{size:14})}),l.jsx("button",{className:"w-8 h-8 flex items-center justify-center rounded-lg hover:bg-bg text-text-secondary",children:l.jsx(Jr,{size:14})})]})})]},N.id)}),_.length===0&&l.jsx("tr",{children:l.jsx("td",{colSpan:7,className:"text-center text-text-secondary py-8",children:"Inga avtal hittades"})})]})]})})}),e==="templates"&&l.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-6",children:[O.map(N=>l.jsx("div",{className:"cursor-pointer hover:border-primary transition-colors",onClick:()=>{S(N),A(!0)},children:l.jsx(ee,{children:l.jsxs("div",{className:"p-4",children:[l.jsxs("div",{className:"flex items-start justify-between mb-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary/10 text-primary flex items-center justify-center",children:l.jsx(Oi,{size:20})}),l.jsx(Se,{variant:Ice[N.category],className:"text-xs",children:N.category})]}),l.jsx("h3",{className:"font-semibold text-text-primary mb-1",children:N.name}),l.jsx("p",{className:"text-sm text-text-secondary mb-3",children:N.description}),l.jsxs("div",{className:"flex items-center gap-2 text-xs text-text-tertiary",children:[l.jsx(yn,{size:12}),N.jurisdiction,l.jsx("span",{className:"mx-1",children:"•"}),l.jsx(Xr,{size:12}),"v",N.version,l.jsx("span",{className:"mx-1",children:"•"}),N.sections.length," sektioner"]})]})})},N.id)),O.length===0&&l.jsx("div",{className:"col-span-full text-center text-text-secondary py-8",children:"Inga mallar hittades"})]}),e==="products"&&l.jsx("div",{className:"space-y-6",children:x.map(N=>l.jsx(ee,{children:l.jsxs("div",{className:"p-4",children:[l.jsxs("div",{className:"flex items-center gap-3 mb-4",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary/10 text-primary flex items-center justify-center",children:l.jsx(ou,{size:20})}),l.jsxs("div",{children:[l.jsx("h3",{className:"font-semibold text-text-primary",children:N.product_name}),l.jsx("p",{className:"text-sm text-text-secondary",children:N.product_type})]})]}),l.jsxs("div",{className:"space-y-3",children:[l.jsxs("div",{children:[l.jsx("p",{className:"text-xs font-medium text-text-secondary uppercase mb-2",children:"Krävs"}),l.jsx("div",{className:"flex flex-wrap gap-2",children:N.required_contracts.map(E=>l.jsx(Se,{variant:"primary",className:"text-xs",children:E},E))})]}),N.optional_contracts.length>0&&l.jsxs("div",{children:[l.jsx("p",{className:"text-xs font-medium text-text-secondary uppercase mb-2",children:"Valbart"}),l.jsx("div",{className:"flex flex-wrap gap-2",children:N.optional_contracts.map(E=>l.jsx(Se,{variant:"default",className:"text-xs",children:E},E))})]})]})]})},N.product_id))}),b&&w&&l.jsx("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/50 p-4",children:l.jsx("div",{className:"w-full max-w-3xl max-h-[90vh] overflow-y-auto",children:l.jsx(ee,{children:l.jsxs("div",{className:"p-6",children:[l.jsxs("div",{className:"flex items-start justify-between mb-6",children:[l.jsxs("div",{children:[l.jsx("h2",{className:"text-xl font-semibold",children:w.name}),l.jsx("p",{className:"text-text-secondary",children:w.description})]}),l.jsx("button",{onClick:()=>A(!1),className:"w-8 h-8 flex items-center justify-center rounded-lg hover:bg-bg text-text-secondary",children:"✕"})]}),l.jsxs("div",{className:"grid grid-cols-2 gap-4 mb-6",children:[l.jsxs("div",{className:"p-3 bg-surface rounded-lg",children:[l.jsx("p",{className:"text-xs text-text-secondary",children:"Kategori"}),l.jsx("p",{className:"font-medium",children:w.category})]}),l.jsxs("div",{className:"p-3 bg-surface rounded-lg",children:[l.jsx("p",{className:"text-xs text-text-secondary",children:"Jurisdiktion"}),l.jsx("p",{className:"font-medium",children:w.jurisdiction})]}),l.jsxs("div",{className:"p-3 bg-surface rounded-lg",children:[l.jsx("p",{className:"text-xs text-text-secondary",children:"Språk"}),l.jsx("p",{className:"font-medium",children:w.language})]}),l.jsxs("div",{className:"p-3 bg-surface rounded-lg",children:[l.jsx("p",{className:"text-xs text-text-secondary",children:"Version"}),l.jsx("p",{className:"font-medium",children:w.version})]})]}),l.jsx("h3",{className:"font-semibold mb-3",children:"Avtalssektioner"}),l.jsx("div",{className:"space-y-2 mb-6",children:w.sections.map(N=>l.jsxs("div",{className:"p-3 bg-surface rounded-lg",children:[l.jsxs("div",{className:"flex items-center gap-2 mb-1",children:[l.jsxs("span",{className:"text-xs text-text-tertiary",children:[N.order,"."]}),l.jsx("p",{className:"font-medium text-sm",children:N.title}),N.required&&l.jsx(Se,{variant:"danger",className:"text-xs",children:"Krävs"})]}),l.jsx("p",{className:"text-sm text-text-secondary",children:N.content}),N.variables&&N.variables.length>0&&l.jsx("div",{className:"flex flex-wrap gap-1 mt-2",children:N.variables.map(E=>l.jsx("code",{className:"text-xs bg-primary/10 text-primary px-2 py-0.5 rounded",children:"{{"+E+"}}"},E))})]},N.id))}),l.jsx("h3",{className:"font-semibold mb-3",children:"Standardvillkor"}),l.jsxs("div",{className:"grid grid-cols-2 gap-3 mb-6",children:[l.jsxs("div",{className:"p-3 bg-surface rounded-lg",children:[l.jsx("p",{className:"text-xs text-text-secondary",children:"Betalningsvillkor"}),l.jsx("p",{className:"text-sm",children:w.default_terms.payment_terms})]}),l.jsxs("div",{className:"p-3 bg-surface rounded-lg",children:[l.jsx("p",{className:"text-xs text-text-secondary",children:"Valuta"}),l.jsx("p",{className:"text-sm",children:w.default_terms.currency})]}),l.jsxs("div",{className:"p-3 bg-surface rounded-lg",children:[l.jsx("p",{className:"text-xs text-text-secondary",children:"Avtalsperiod"}),l.jsx("p",{className:"text-sm",children:w.default_terms.contract_period})]}),l.jsxs("div",{className:"p-3 bg-surface rounded-lg",children:[l.jsx("p",{className:"text-xs text-text-secondary",children:"Uppsägningstid"}),l.jsx("p",{className:"text-sm",children:w.default_terms.notice_period})]}),l.jsxs("div",{className:"p-3 bg-surface rounded-lg",children:[l.jsx("p",{className:"text-xs text-text-secondary",children:"Auto-förnyelse"}),l.jsx("p",{className:"text-sm",children:w.default_terms.auto_renewal?"Ja":"Nej"})]}),l.jsxs("div",{className:"p-3 bg-surface rounded-lg",children:[l.jsx("p",{className:"text-xs text-text-secondary",children:"SLA"}),l.jsx("p",{className:"text-sm",children:w.default_terms.sla_enabled?`${w.default_terms.sla_uptime}% uptime`:"Ej aktiverat"})]})]}),l.jsxs("div",{className:"flex gap-3",children:[l.jsxs(ht,{className:"flex-1",children:[l.jsx(Lr,{size:16,className:"mr-2"}),"Skapa avtal från mall"]}),l.jsxs(ht,{variant:"secondary",children:[l.jsx(UT,{size:16,className:"mr-2"}),"Förhandsgranska"]})]})]})})})})]})}const Uce=[{id:"1",name:"Q4 Product Launch",status:"active",channel:"Email",reach:12500,engagement:8.2,conversions:340},{id:"2",name:"Holiday Special",status:"scheduled",channel:"Social",reach:0,engagement:0,conversions:0},{id:"3",name:"Customer Retention",status:"active",channel:"Email",reach:8400,engagement:12.5,conversions:520},{id:"4",name:"Partner Webinar",status:"completed",channel:"Webinar",reach:3200,engagement:45,conversions:180}];function Vce(){return l.jsxs("div",{className:"space-y-8",children:[l.jsxs("div",{className:"flex flex-col sm:flex-row sm:items-center justify-between gap-4",children:[l.jsxs("div",{children:[l.jsx("h1",{className:"text-xl font-semibold text-text-primary",children:"Marketing"}),l.jsx("p",{className:"text-sm text-text-secondary mt-0.5",children:"Campaigns and marketing metrics"})]}),l.jsx(ht,{icon:l.jsx(Lr,{size:16}),children:"New Campaign"})]}),l.jsxs("div",{className:"grid grid-cols-2 lg:grid-cols-4 gap-5",children:[l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary-light flex items-center justify-center text-primary",children:l.jsx(bz,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:"4"}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Campaigns"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-success-light flex items-center justify-center text-success",children:l.jsx(Wn,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:"24.1K"}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Total Reach"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-warning-light flex items-center justify-center text-warning",children:l.jsx(Sz,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:"10.4%"}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Avg. Engagement"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary-light flex items-center justify-center text-primary",children:l.jsx(ea,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:"1,040"}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Conversions"})]})]})})]}),l.jsxs(ee,{children:[l.jsx(Ie,{title:"Campaigns",subtitle:"Active and recent marketing campaigns"}),l.jsx("div",{className:"space-y-4",children:Uce.map(e=>l.jsxs("div",{className:"flex items-center justify-between p-4 rounded-xl bg-bg/50 hover:bg-bg transition-colors",children:[l.jsxs("div",{className:"flex items-center gap-4",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary-light flex items-center justify-center text-primary",children:e.channel==="Email"?l.jsx(Sn,{size:18}):l.jsx(SH,{size:18})}),l.jsxs("div",{children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx("span",{className:"font-medium text-text-primary",children:e.name}),l.jsx(Se,{variant:e.status==="active"?"success":e.status==="scheduled"?"primary":"default",size:"sm",children:e.status})]}),l.jsx("p",{className:"text-xs text-text-secondary mt-0.5",children:e.channel})]})]}),l.jsxs("div",{className:"flex items-center gap-8 text-right",children:[l.jsxs("div",{children:[l.jsx("p",{className:"text-sm font-medium text-text-primary",children:e.reach>0?e.reach.toLocaleString():"—"}),l.jsx("p",{className:"text-[11px] text-text-secondary",children:"Reach"})]}),l.jsxs("div",{children:[l.jsx("p",{className:"text-sm font-medium text-text-primary",children:e.engagement>0?`${e.engagement}%`:"—"}),l.jsx("p",{className:"text-[11px] text-text-secondary",children:"Engagement"})]}),l.jsxs("div",{children:[l.jsx("p",{className:"text-sm font-medium text-text-primary",children:e.conversions>0?e.conversions.toLocaleString():"—"}),l.jsx("p",{className:"text-[11px] text-text-secondary",children:"Conversions"})]})]})]},e.id))})]})]})}const Bc=[{id:"SUP-2024-001",subject:"Login issues after password reset",customer:"Acme Corp",priority:"high",status:"open",assigned:"Johan Berg",created:new Date(Date.now()-1e3*60*30).toISOString()},{id:"SUP-2024-002",subject:"API rate limit questions",customer:"Nordic Solutions",priority:"medium",status:"in_progress",assigned:"Johan Berg",created:new Date(Date.now()-1e3*60*120).toISOString()},{id:"SUP-2024-003",subject:"Feature request: bulk export",customer:"TechStart AB",priority:"low",status:"open",assigned:"Unassigned",created:new Date(Date.now()-1e3*60*60*4).toISOString()},{id:"SUP-2024-004",subject:"Billing discrepancy on invoice #89",customer:"Global Industries",priority:"high",status:"in_progress",assigned:"Elena Rossi",created:new Date(Date.now()-1e3*60*60*6).toISOString()},{id:"SUP-2024-005",subject:"Integration documentation outdated",customer:"ScandiTech",priority:"medium",status:"resolved",assigned:"Johan Berg",created:new Date(Date.now()-1e3*60*60*24).toISOString()},{id:"SUP-2024-006",subject:"Mobile app crash on iOS",customer:"MegaCorp",priority:"high",status:"open",assigned:"Unassigned",created:new Date(Date.now()-1e3*60*60*2).toISOString()}],Hce=["All","Open","In Progress","Resolved"];function Fce(){const[e,t]=P.useState("All"),[n,r]=P.useState(""),i=Bc.filter(d=>d.status==="open").length,o=Bc.filter(d=>d.status==="in_progress").length,c=Bc.filter(d=>d.status==="resolved").length,f=Bc.filter(d=>{const h=d.subject.toLowerCase().includes(n.toLowerCase())||d.customer.toLowerCase().includes(n.toLowerCase())||d.id.toLowerCase().includes(n.toLowerCase()),p=e==="All"||d.status===e.toLowerCase().replace(" ","_");return h&&p});return l.jsxs("div",{className:"space-y-8",children:[l.jsxs("div",{className:"flex flex-col sm:flex-row sm:items-center justify-between gap-4",children:[l.jsxs("div",{children:[l.jsx("h1",{className:"text-xl font-semibold text-text-primary",children:"Support"}),l.jsx("p",{className:"text-sm text-text-secondary mt-0.5",children:"Customer support tickets"})]}),l.jsx(ht,{icon:l.jsx(Lr,{size:16}),children:"New Ticket"})]}),l.jsxs("div",{className:"grid grid-cols-2 lg:grid-cols-4 gap-5",children:[l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary-light flex items-center justify-center text-primary",children:l.jsx(yz,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:Bc.length}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Total Tickets"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-warning-light flex items-center justify-center text-warning",children:l.jsx(zm,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:i}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Open"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary-light flex items-center justify-center text-primary",children:l.jsx(vr,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:o}),l.jsx("p",{className:"text-xs text-text-secondary",children:"In Progress"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-success-light flex items-center justify-center text-success",children:l.jsx(Xu,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:c}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Resolved"})]})]})})]}),l.jsxs("div",{className:"flex flex-col sm:flex-row items-start sm:items-center justify-between gap-4",children:[l.jsx("div",{className:"flex items-center gap-1 bg-bg rounded-xl p-1",children:Hce.map(d=>l.jsx("button",{onClick:()=>t(d),className:`px-4 py-2 text-sm font-medium rounded-lg transition-colors ${e===d?"bg-surface text-text-primary shadow-sm":"text-text-secondary hover:text-text-primary"}`,children:d},d))}),l.jsxs("div",{className:"flex items-center gap-2 w-full sm:w-auto",children:[l.jsxs("div",{className:"relative flex-1 sm:flex-initial",children:[l.jsx(Ts,{size:15,className:"absolute left-3 top-1/2 -translate-y-1/2 text-text-secondary"}),l.jsx("input",{type:"text",placeholder:"Search tickets...",value:n,onChange:d=>r(d.target.value),className:"w-full sm:w-64 h-10 pl-9 pr-4 rounded-[14px] border bg-surface text-sm text-text-primary placeholder:text-text-secondary/50 focus:outline-none focus:ring-2 focus:ring-primary/20 focus:border-primary/30"})]}),l.jsx(ht,{variant:"secondary",size:"sm",icon:l.jsx(Wu,{size:14}),children:"Filter"})]})]}),l.jsx(ee,{children:l.jsxs($a,{children:[l.jsx(Ba,{children:l.jsxs(Nt,{children:[l.jsx(be,{children:"Ticket"}),l.jsx(be,{children:"Subject"}),l.jsx(be,{children:"Customer"}),l.jsx(be,{children:"Priority"}),l.jsx(be,{children:"Status"}),l.jsx(be,{children:"Assigned"}),l.jsx(be,{children:"Created"}),l.jsx(be,{align:"right"})]})}),l.jsx(qa,{children:f.map(d=>l.jsxs(Nt,{children:[l.jsx(ge,{children:l.jsx("span",{className:"font-medium text-sm",children:d.id})}),l.jsx(ge,{children:l.jsx("span",{className:"text-sm text-text-primary",children:d.subject})}),l.jsx(ge,{children:d.customer}),l.jsx(ge,{children:l.jsx(Se,{variant:d.priority==="high"?"danger":d.priority==="medium"?"warning":"default",size:"sm",children:d.priority})}),l.jsx(ge,{children:l.jsx(Se,{variant:d.status==="resolved"?"success":d.status==="in_progress"?"primary":"warning",size:"sm",children:d.status.replace("_"," ")})}),l.jsx(ge,{children:d.assigned}),l.jsx(ge,{children:l.jsx("span",{className:"text-xs text-text-secondary",children:Mz(d.created)})}),l.jsx(ge,{align:"right",children:l.jsx("button",{className:"w-8 h-8 flex items-center justify-center rounded-lg hover:bg-bg text-text-secondary",children:l.jsx(Jr,{size:16})})})]},d.id))})]})})]})}const qc=[{id:"1",name:"New Lead Notification",description:"Send Slack notification when a new lead is created",status:"active",trigger:"Lead Created",actions:["Send Email","Slack Message"],lastRun:"2 min ago",runs:1240},{id:"2",name:"Invoice Reminder",description:"Send reminder 3 days before invoice due date",status:"active",trigger:"Schedule",actions:["Send Email"],lastRun:"1 hour ago",runs:856},{id:"3",name:"Customer Onboarding",description:"Welcome email series for new customers",status:"active",trigger:"Customer Created",actions:["Send Email","Create Task","Add to CRM"],lastRun:"15 min ago",runs:342},{id:"4",name:"Deal Stage Alert",description:"Notify sales team when deal reaches negotiation",status:"paused",trigger:"Deal Updated",actions:["Send Email","Slack Message"],lastRun:"3 days ago",runs:89},{id:"5",name:"Employee Offboarding",description:"Automated offboarding checklist",status:"active",trigger:"Employee Terminated",actions:["Create Task","Send Email","Update HR"],lastRun:"1 week ago",runs:12}],Gce={"Send Email":l.jsx(Sn,{size:12}),"Slack Message":l.jsx(fh,{size:12}),"Create Task":l.jsx(Oi,{size:12}),"Add to CRM":l.jsx(ZT,{size:12}),"Update HR":l.jsx(ZT,{size:12})};function Kce(){const e=qc.filter(n=>n.status==="active").length,t=qc.reduce((n,r)=>n+r.runs,0);return l.jsxs("div",{className:"space-y-8",children:[l.jsxs("div",{className:"flex flex-col sm:flex-row sm:items-center justify-between gap-4",children:[l.jsxs("div",{children:[l.jsx("h1",{className:"text-xl font-semibold text-text-primary",children:"Automation"}),l.jsx("p",{className:"text-sm text-text-secondary mt-0.5",children:"Workflows and automated tasks"})]}),l.jsx(ht,{icon:l.jsx(Lr,{size:16}),children:"New Workflow"})]}),l.jsxs("div",{className:"grid grid-cols-2 lg:grid-cols-4 gap-5",children:[l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary-light flex items-center justify-center text-primary",children:l.jsx($m,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:qc.length}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Workflows"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-success-light flex items-center justify-center text-success",children:l.jsx(XT,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:e}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Active"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-warning-light flex items-center justify-center text-warning",children:l.jsx(KT,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:qc.length-e}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Paused"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary-light flex items-center justify-center text-primary",children:l.jsx(Xu,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:t.toLocaleString()}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Total Runs"})]})]})})]}),l.jsxs(ee,{children:[l.jsx(Ie,{title:"Workflows",subtitle:"Automated processes and triggers"}),l.jsx("div",{className:"space-y-3",children:qc.map(n=>l.jsxs("div",{className:"flex items-center justify-between p-4 rounded-xl bg-bg/50 hover:bg-bg transition-colors",children:[l.jsxs("div",{className:"flex items-center gap-4",children:[l.jsx("div",{className:`w-10 h-10 rounded-xl flex items-center justify-center ${n.status==="active"?"bg-success-light text-success":"bg-warning-light text-warning"}`,children:n.status==="active"?l.jsx(XT,{size:18}):l.jsx(KT,{size:18})}),l.jsxs("div",{children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx("span",{className:"font-medium text-text-primary",children:n.name}),l.jsx(Se,{variant:n.status==="active"?"success":"warning",size:"sm",children:n.status})]}),l.jsx("p",{className:"text-xs text-text-secondary mt-0.5",children:n.description}),l.jsxs("div",{className:"flex items-center gap-3 mt-2",children:[l.jsxs("div",{className:"flex items-center gap-1.5",children:[l.jsx(RH,{size:12,className:"text-text-secondary/60"}),l.jsx("span",{className:"text-[11px] text-text-secondary",children:n.trigger})]}),l.jsx("div",{className:"flex items-center gap-1",children:n.actions.map((r,i)=>l.jsxs("span",{className:"inline-flex items-center gap-1 px-1.5 py-0.5 bg-bg rounded text-[10px] text-text-secondary",children:[Gce[r],r]},i))})]})]})]}),l.jsxs("div",{className:"flex items-center gap-6 text-right",children:[l.jsxs("div",{children:[l.jsx("p",{className:"text-sm font-medium text-text-primary",children:n.runs.toLocaleString()}),l.jsx("p",{className:"text-[11px] text-text-secondary",children:"runs"})]}),l.jsxs("div",{children:[l.jsx("p",{className:"text-sm font-medium text-text-primary",children:n.lastRun}),l.jsx("p",{className:"text-[11px] text-text-secondary",children:"last run"})]}),l.jsx("div",{className:"flex items-center",children:l.jsx("div",{className:"w-9 h-5 rounded-full bg-success/20 relative cursor-pointer",children:l.jsx("div",{className:"absolute right-0.5 top-0.5 w-4 h-4 rounded-full bg-success"})})})]})]},n.id))})]})]})}function Yce(){const[e,t]=P.useState([]),[n,r]=P.useState(null),[i,o]=P.useState(!0),[c,f]=P.useState(""),[d,h]=P.useState(null);P.useEffect(()=>{p()},[]);async function p(){o(!0),f("");try{const w=await rE.engines();t(w.engines||[]),r(w.summary||null)}catch(w){f(w instanceof Error?w.message:"Failed to load engines")}finally{o(!1)}}async function y(w){h(w);try{await rE.restartEngine(w),setTimeout(p,2e3)}catch(S){console.error("Restart failed:",S)}finally{h(null)}}function x(w){switch(w){case"healthy":return"success";case"warning":return"warning";case"critical":return"danger";case"maintenance":return"default";default:return"default"}}function j(w){switch(w){case"healthy":return l.jsx(Dr,{size:16,className:"text-success"});case"warning":return l.jsx(Yt,{size:16,className:"text-warning"});case"critical":return l.jsx(Oh,{size:16,className:"text-danger"});case"maintenance":return l.jsx(vr,{size:16,className:"text-text-secondary"});default:return l.jsx(xH,{size:16,className:"text-text-secondary"})}}if(i)return l.jsxs("div",{className:"space-y-8",children:[l.jsx(ke,{className:"h-[80px]"}),l.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-5",children:Array.from({length:6}).map((w,S)=>l.jsx(ke,{className:"h-[200px]"},S))})]});if(c){const w=c.includes("authorization")||c.includes("unauthorized")||c.includes("missing authorization");return l.jsx("div",{className:"flex items-center justify-center h-64",children:l.jsx("div",{className:"text-center max-w-md px-4",children:w?l.jsxs(l.Fragment,{children:[l.jsx(I1,{size:48,className:"mx-auto text-warning mb-4"}),l.jsx("h3",{className:"text-lg font-medium text-text-primary mb-2",children:"Authentication required"}),l.jsx("p",{className:"text-text-secondary mb-4",children:"Please log in to access AMOS Control Panel"}),l.jsx("button",{onClick:()=>window.location.href="/login",className:"px-4 py-2 bg-primary text-white rounded-lg hover:bg-primary-hover flex items-center gap-2 mx-auto",children:"Log in"})]}):l.jsxs(l.Fragment,{children:[l.jsx(Yt,{size:48,className:"text-danger mx-auto mb-4"}),l.jsx("p",{className:"text-danger font-medium",children:c}),l.jsx(ht,{onClick:p,className:"mt-4",icon:l.jsx(Ma,{size:16}),children:"Retry"})]})})})}return l.jsxs("div",{className:"space-y-8",children:[l.jsxs("div",{className:"flex flex-col sm:flex-row sm:items-center justify-between gap-4",children:[l.jsxs("div",{children:[l.jsx("h1",{className:"text-xl font-semibold text-text-primary",children:"AMOS Control Panel"}),l.jsx("p",{className:"text-sm text-text-secondary mt-0.5",children:"Monitor and control all AMOS engines"})]}),l.jsx(ht,{onClick:p,icon:l.jsx(Ma,{size:16}),children:"Refresh"})]}),n&&l.jsxs("div",{className:"grid grid-cols-2 sm:grid-cols-4 gap-5",children:[l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary-light flex items-center justify-center text-primary",children:l.jsx(I1,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:n.total}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Total Engines"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-success-light flex items-center justify-center text-success",children:l.jsx(Dr,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:n.healthy}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Healthy"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-warning-light flex items-center justify-center text-warning",children:l.jsx(Yt,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:n.warning}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Warning"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-danger-light flex items-center justify-center text-danger",children:l.jsx(Oh,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:n.critical+n.maintenance}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Critical/Maintenance"})]})]})})]}),l.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-5",children:e.map(w=>l.jsx(ee,{className:"relative",children:l.jsxs("div",{className:"p-5 space-y-4",children:[l.jsxs("div",{className:"flex items-start justify-between",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[j(w.health),l.jsxs("div",{children:[l.jsx("h3",{className:"text-sm font-semibold text-text-primary",children:w.name}),l.jsx("p",{className:"text-xs text-text-secondary",children:w.version})]})]}),l.jsx(Se,{variant:x(w.health),children:w.health})]}),l.jsxs("div",{className:"grid grid-cols-2 gap-3",children:[l.jsxs("div",{className:"p-2 bg-bg rounded-lg",children:[l.jsx("p",{className:"text-xs text-text-secondary",children:"Requests (24h)"}),l.jsx("p",{className:"text-sm font-medium text-text-primary",children:w.requests_24h.toLocaleString()})]}),l.jsxs("div",{className:"p-2 bg-bg rounded-lg",children:[l.jsx("p",{className:"text-xs text-text-secondary",children:"Latency"}),l.jsxs("p",{className:"text-sm font-medium text-text-primary",children:[w.latency_ms.toFixed(1)," ms"]})]}),l.jsxs("div",{className:"p-2 bg-bg rounded-lg",children:[l.jsx("p",{className:"text-xs text-text-secondary",children:"Error Rate"}),l.jsxs("p",{className:"text-sm font-medium text-text-primary",children:[(w.error_rate*100).toFixed(1),"%"]})]}),l.jsxs("div",{className:"p-2 bg-bg rounded-lg",children:[l.jsx("p",{className:"text-xs text-text-secondary",children:"Uptime"}),l.jsx("p",{className:"text-sm font-medium text-text-primary",children:w.uptime})]})]}),w.models&&w.models.length>0&&l.jsxs("div",{className:"space-y-2",children:[l.jsx("p",{className:"text-xs font-medium text-text-secondary uppercase",children:"Models"}),w.models.map(S=>l.jsxs("div",{className:"flex items-center justify-between text-sm",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx(hz,{size:14,className:"text-text-secondary"}),l.jsx("span",{className:"text-text-primary",children:S.name})]}),l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsxs("span",{className:"text-xs text-text-secondary",children:[(S.accuracy*100).toFixed(0),"%"]}),l.jsx(Se,{variant:S.status==="active"?"success":"warning",size:"sm",children:S.status})]})]},S.id))]}),l.jsx("div",{className:"pt-2 border-t border-border/40",children:l.jsx(ht,{variant:"secondary",size:"sm",className:"w-full",icon:l.jsx(Ma,{size:14}),disabled:d===w.id,onClick:()=>y(w.id),children:d===w.id?"Restarting...":"Restart Engine"})})]})},w.id))})]})}function Xce(){var A,_;const[e,t]=P.useState("zoomers"),[n,r]=P.useState([]),[i,o]=P.useState([]),[c,f]=P.useState([]),[d,h]=P.useState(null),[p,y]=P.useState(!0),[x,j]=P.useState(""),w=[{key:"zoomers",label:"Zoomers",icon:Wn},{key:"field-data",label:"Field Data",icon:uh},{key:"payouts",label:"Payouts",icon:vs},{key:"insights",label:"Insights",icon:IT}];P.useEffect(()=>{S()},[]);async function S(){y(!0),j("");try{const[O,T,N,E]=await Promise.all([Ld.zoomers(),Ld.fieldData(),Ld.payouts(),Ld.insights()]);r(O.zoomers||[]),o(T.fieldData||[]),f(N.payouts||[]),h(E.insights||null)}catch(O){const T=O instanceof Error?O.message:"Failed to load data";T.includes("not configured"),j(T)}finally{y(!1)}}function b(O){switch(O){case"active":case"completed":case"processed":return"success";case"pending":case"processing":return"warning";case"inactive":case"failed":return"danger";default:return"default"}}if(p)return l.jsxs("div",{className:"space-y-8",children:[l.jsx(ke,{className:"h-[80px]"}),l.jsx(ke,{className:"h-[400px]"})]});if(x){const O=x.includes("not configured");return l.jsx("div",{className:"flex items-center justify-center h-64",children:l.jsx("div",{className:"text-center max-w-md",children:O?l.jsxs(l.Fragment,{children:[l.jsx(yn,{size:48,className:"mx-auto text-text-tertiary mb-4"}),l.jsx("h3",{className:"text-lg font-medium text-text-primary mb-2",children:"quiXzoom not configured"}),l.jsx("p",{className:"text-text-secondary mb-4",children:x}),l.jsx("p",{className:"text-sm text-text-tertiary",children:"Contact your administrator to set up quiXzoom integration."})]}):l.jsx("p",{className:"text-danger",children:x})})})}return l.jsxs("div",{className:"space-y-8",children:[l.jsx("div",{className:"flex flex-col sm:flex-row sm:items-center justify-between gap-4",children:l.jsxs("div",{children:[l.jsx("h1",{className:"text-xl font-semibold text-text-primary",children:"quiXzoom"}),l.jsx("p",{className:"text-sm text-text-secondary mt-0.5",children:"Field intelligence network and zoomer management"})]})}),l.jsx("div",{className:"flex items-center gap-1 bg-bg rounded-xl p-1 overflow-x-auto max-w-full",children:w.map(O=>l.jsxs("button",{onClick:()=>t(O.key),className:`px-4 py-2 text-sm font-medium rounded-lg transition-colors whitespace-nowrap flex items-center gap-2 ${e===O.key?"bg-surface text-text-primary shadow-sm":"text-text-secondary hover:text-text-primary"}`,children:[l.jsx(O.icon,{size:16}),O.label]},O.key))}),e==="zoomers"&&l.jsxs("div",{className:"space-y-6",children:[l.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-3 gap-5",children:[l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary-light flex items-center justify-center text-primary",children:l.jsx(Wn,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:n.length}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Total Zoomers"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-success-light flex items-center justify-center text-success",children:l.jsx(Dr,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:n.filter(O=>O.status==="active").length}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Active"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-warning-light flex items-center justify-center text-warning",children:l.jsx(vs,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:we(n.reduce((O,T)=>O+T.earnings,0))}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Total Earnings"})]})]})})]}),l.jsxs(ee,{children:[l.jsx(Ie,{title:"Zoomers",subtitle:"All field intelligence agents"}),l.jsx("div",{className:"overflow-x-auto",children:l.jsxs("table",{className:"w-full",children:[l.jsx("thead",{className:"border-b border-border",children:l.jsxs("tr",{children:[l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Name"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Location"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Status"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-right",children:"Tasks"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-right",children:"Rating"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-right",children:"Earnings"})]})}),l.jsx("tbody",{children:n.map(O=>l.jsxs("tr",{className:"border-b border-border/50",children:[l.jsx("td",{className:"py-3.5 px-4",children:l.jsxs("div",{children:[l.jsx("p",{className:"text-sm font-medium text-text-primary",children:O.name}),l.jsx("p",{className:"text-xs text-text-secondary",children:O.email})]})}),l.jsx("td",{className:"py-3.5 px-4",children:l.jsxs("div",{className:"flex items-center gap-1 text-sm text-text-primary",children:[l.jsx(GT,{size:14,className:"text-text-secondary"}),O.city,", ",O.country]})}),l.jsx("td",{className:"py-3.5 px-4",children:l.jsx(Se,{variant:b(O.status),children:O.status})}),l.jsxs("td",{className:"py-3.5 px-4 text-right text-sm text-text-primary",children:[O.completed_tasks,"/",O.total_tasks]}),l.jsxs("td",{className:"py-3.5 px-4 text-right text-sm text-text-primary",children:[O.rating.toFixed(1)," ★"]}),l.jsx("td",{className:"py-3.5 px-4 text-right text-sm font-medium text-text-primary",children:we(O.earnings)})]},O.id))})]})})]})]}),e==="field-data"&&l.jsxs("div",{className:"space-y-6",children:[l.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-3 gap-5",children:[l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary-light flex items-center justify-center text-primary",children:l.jsx(uh,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:i.length}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Total Observations"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-success-light flex items-center justify-center text-success",children:l.jsx(Dr,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:i.filter(O=>O.status==="processed").length}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Processed"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-warning-light flex items-center justify-center text-warning",children:l.jsx(vr,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:i.filter(O=>O.status==="pending").length}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Pending"})]})]})})]}),l.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-5",children:i.map(O=>l.jsx(ee,{children:l.jsxs("div",{className:"p-5 space-y-3",children:[l.jsxs("div",{className:"flex items-start justify-between",children:[l.jsxs("div",{children:[l.jsx("p",{className:"text-sm font-medium text-text-primary",children:O.type}),l.jsx("p",{className:"text-xs text-text-secondary",children:O.zoomer_name})]}),l.jsx(Se,{variant:b(O.status),children:O.status})]}),l.jsxs("div",{className:"flex items-center gap-1 text-xs text-text-secondary",children:[l.jsx(GT,{size:14}),O.location.address,", ",O.location.city]}),O.ai_result&&l.jsxs("div",{className:"p-3 bg-bg rounded-lg space-y-2",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx(IT,{size:14,className:"text-primary"}),l.jsxs("span",{className:"text-xs font-medium text-text-primary",children:["AI Analysis (",O.ai_result.engine,")"]})]}),l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx("div",{className:"flex-1 h-2 bg-surface-2 rounded-full",children:l.jsx("div",{className:"h-2 bg-primary rounded-full",style:{width:`${O.ai_result.confidence*100}%`}})}),l.jsxs("span",{className:"text-xs text-text-secondary",children:[(O.ai_result.confidence*100).toFixed(0),"%"]})]}),O.ai_result.detections.map((T,N)=>l.jsxs("div",{className:"flex items-center justify-between text-xs",children:[l.jsx("span",{className:"text-text-secondary",children:T.label}),l.jsxs("span",{className:"text-text-primary",children:[(T.confidence*100).toFixed(0),"%"]})]},N))]}),l.jsx("p",{className:"text-xs text-text-secondary",children:Rt(O.created_at)})]})},O.id))})]}),e==="payouts"&&l.jsxs("div",{className:"space-y-6",children:[l.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-3 gap-5",children:[l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary-light flex items-center justify-center text-primary",children:l.jsx(vs,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:c.length}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Total Payouts"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-success-light flex items-center justify-center text-success",children:l.jsx(Dr,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:c.filter(O=>O.status==="completed").length}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Completed"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-warning-light flex items-center justify-center text-warning",children:l.jsx(ea,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:we(c.reduce((O,T)=>O+T.amount,0))}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Total Amount"})]})]})})]}),l.jsxs(ee,{children:[l.jsx(Ie,{title:"Payouts",subtitle:"All zoomer payments"}),l.jsx("div",{className:"overflow-x-auto",children:l.jsxs("table",{className:"w-full",children:[l.jsx("thead",{className:"border-b border-border",children:l.jsxs("tr",{children:[l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Zoomer"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Period"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Status"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Method"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-right",children:"Amount"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-right",children:"Net"})]})}),l.jsx("tbody",{children:c.map(O=>l.jsxs("tr",{className:"border-b border-border/50",children:[l.jsx("td",{className:"py-3.5 px-4 text-sm text-text-primary",children:O.zoomer_name}),l.jsx("td",{className:"py-3.5 px-4 text-sm text-text-primary",children:O.period}),l.jsx("td",{className:"py-3.5 px-4",children:l.jsx(Se,{variant:b(O.status),children:O.status})}),l.jsx("td",{className:"py-3.5 px-4 text-sm text-text-primary",children:O.method}),l.jsxs("td",{className:"py-3.5 px-4 text-right text-sm text-text-primary",children:[we(O.amount)," ",O.currency]}),l.jsx("td",{className:"py-3.5 px-4 text-right text-sm font-medium text-success",children:we(O.net_amount)})]},O.id))})]})})]})]}),e==="insights"&&d&&l.jsxs("div",{className:"space-y-6",children:[l.jsxs("div",{className:"grid grid-cols-2 sm:grid-cols-4 gap-5",children:[l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary-light flex items-center justify-center text-primary",children:l.jsx(uh,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:(A=d.total_observations)==null?void 0:A.toLocaleString()}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Observations"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-success-light flex items-center justify-center text-success",children:l.jsx(Wn,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:d.active_zoomers}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Active Zoomers"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-warning-light flex items-center justify-center text-warning",children:l.jsx(yn,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:d.cities_covered}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Cities"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary-light flex items-center justify-center text-primary",children:l.jsx(yn,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:d.countries_covered}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Countries"})]})]})})]}),l.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-5",children:[d.urban_sanitation_index&&l.jsxs(ee,{children:[l.jsx(Ie,{title:"Urban Sanitation Index",subtitle:`Score: ${d.urban_sanitation_index.score}/10`}),l.jsxs("div",{className:"p-5 space-y-3",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx("div",{className:"flex-1 h-3 bg-surface-2 rounded-full",children:l.jsx("div",{className:"h-3 bg-primary rounded-full",style:{width:`${d.urban_sanitation_index.score/10*100}%`}})}),l.jsx("span",{className:"text-sm font-medium text-text-primary",children:d.urban_sanitation_index.score})]}),l.jsx("div",{className:"space-y-2",children:(_=d.urban_sanitation_index.cities)==null?void 0:_.map((O,T)=>l.jsxs("div",{className:"flex items-center justify-between text-sm",children:[l.jsx("span",{className:"text-text-secondary",children:O.city}),l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx("div",{className:"w-24 h-2 bg-surface-2 rounded-full",children:l.jsx("div",{className:"h-2 bg-primary rounded-full",style:{width:`${O.score/10*100}%`}})}),l.jsx("span",{className:"text-text-primary",children:O.score})]})]},T))})]})]}),d.reality_gap_index&&l.jsxs(ee,{children:[l.jsx(Ie,{title:"Reality Gap Index",subtitle:`Score: ${d.reality_gap_index.score}/10`}),l.jsxs("div",{className:"p-5 space-y-3",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx("div",{className:"flex-1 h-3 bg-surface-2 rounded-full",children:l.jsx("div",{className:"h-3 bg-danger rounded-full",style:{width:`${d.reality_gap_index.score/10*100}%`}})}),l.jsx("span",{className:"text-sm font-medium text-text-primary",children:d.reality_gap_index.score})]}),l.jsxs("p",{className:"text-xs text-text-secondary",children:["Trend: ",d.reality_gap_index.trend]})]})]}),d.reality_contradiction_score&&l.jsxs(ee,{children:[l.jsx(Ie,{title:"Reality Contradiction Score",subtitle:`Score: ${d.reality_contradiction_score.score}/10`}),l.jsxs("div",{className:"p-5 space-y-3",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx("div",{className:"flex-1 h-3 bg-surface-2 rounded-full",children:l.jsx("div",{className:"h-3 bg-warning rounded-full",style:{width:`${d.reality_contradiction_score.score/10*100}%`}})}),l.jsx("span",{className:"text-sm font-medium text-text-primary",children:d.reality_contradiction_score.score})]}),l.jsxs("p",{className:"text-xs text-text-secondary",children:["Trend: ",d.reality_contradiction_score.trend]})]})]}),d.implementation_gap_score&&l.jsxs(ee,{children:[l.jsx(Ie,{title:"Implementation Gap Score",subtitle:`Score: ${d.implementation_gap_score.score}/10`}),l.jsxs("div",{className:"p-5 space-y-3",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx("div",{className:"flex-1 h-3 bg-surface-2 rounded-full",children:l.jsx("div",{className:"h-3 bg-success rounded-full",style:{width:`${d.implementation_gap_score.score/10*100}%`}})}),l.jsx("span",{className:"text-sm font-medium text-text-primary",children:d.implementation_gap_score.score})]}),l.jsxs("p",{className:"text-xs text-text-secondary",children:["Trend: ",d.implementation_gap_score.trend]})]})]})]})]})]})}function Wce(){var T;const[e,t]=P.useState("entities"),[n,r]=P.useState([]),[i,o]=P.useState([]),[c,f]=P.useState([]),[d,h]=P.useState(null),[p,y]=P.useState(null),[x,j]=P.useState(!0),[w,S]=P.useState(""),b=[{key:"entities",label:"Entities",icon:La},{key:"ownership",label:"Ownership",icon:ea},{key:"documents",label:"Documents",icon:Oi},{key:"compliance",label:"Compliance",icon:Xr}];P.useEffect(()=>{A()},[]);async function A(){j(!0),S("");try{const[N,E,M,D]=await Promise.all([$d.entities(),$d.documents(),$d.compliance(),$d.ownership()]);r(N.entities||[]),o(E.documents||[]),f(M.compliance_items||[]),h(M.summary||null),y(D.ownership||null)}catch(N){S(N instanceof Error?N.message:"Failed to load data")}finally{j(!1)}}function _(N){switch(N){case"active":case"completed":case"signed":return"success";case"pending":case"in_progress":case"draft":return"warning";case"inactive":case"failed":return"danger";default:return"default"}}function O(N){switch(N){case"completed":return l.jsx(Dr,{size:16,className:"text-success"});case"in_progress":return l.jsx(vr,{size:16,className:"text-warning"});case"pending":return l.jsx(Yt,{size:16,className:"text-danger"});default:return l.jsx(Oh,{size:16,className:"text-text-secondary"})}}return x?l.jsxs("div",{className:"space-y-8",children:[l.jsx(ke,{className:"h-[80px]"}),l.jsx(ke,{className:"h-[400px]"})]}):w?l.jsx("div",{className:"flex items-center justify-center h-64",children:l.jsx("p",{className:"text-danger",children:w})}):l.jsxs("div",{className:"space-y-8",children:[l.jsx("div",{className:"flex flex-col sm:flex-row sm:items-center justify-between gap-4",children:l.jsxs("div",{children:[l.jsx("h1",{className:"text-xl font-semibold text-text-primary",children:"Landvex Control"}),l.jsx("p",{className:"text-sm text-text-secondary mt-0.5",children:"Corporate structure, ownership & compliance"})]})}),l.jsx("div",{className:"flex items-center gap-1 bg-bg rounded-xl p-1 overflow-x-auto max-w-full",children:b.map(N=>l.jsxs("button",{onClick:()=>t(N.key),className:`px-4 py-2 text-sm font-medium rounded-lg transition-colors whitespace-nowrap flex items-center gap-2 ${e===N.key?"bg-surface text-text-primary shadow-sm":"text-text-secondary hover:text-text-primary"}`,children:[l.jsx(N.icon,{size:16}),N.label]},N.key))}),e==="entities"&&l.jsxs("div",{className:"space-y-6",children:[l.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-3 gap-5",children:[l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary-light flex items-center justify-center text-primary",children:l.jsx(La,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:n.length}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Entities"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-success-light flex items-center justify-center text-success",children:l.jsx(yn,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:new Set(n.map(N=>N.country)).size}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Countries"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-warning-light flex items-center justify-center text-warning",children:l.jsx(Wn,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:n.reduce((N,E)=>N+E.employees,0)}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Total Employees"})]})]})})]}),l.jsx("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-5",children:n.map(N=>l.jsx(ee,{children:l.jsxs("div",{className:"p-5 space-y-4",children:[l.jsxs("div",{className:"flex items-start justify-between",children:[l.jsxs("div",{children:[l.jsx("h3",{className:"text-base font-semibold text-text-primary",children:N.name}),l.jsxs("p",{className:"text-xs text-text-secondary",children:[N.org_number," • ",N.city,", ",N.country]})]}),l.jsx(Se,{variant:_(N.status),children:N.status})]}),l.jsxs("div",{className:"grid grid-cols-2 gap-3 text-sm",children:[l.jsxs("div",{children:[l.jsx("p",{className:"text-xs text-text-secondary",children:"Type"}),l.jsx("p",{className:"text-text-primary",children:N.type})]}),l.jsxs("div",{children:[l.jsx("p",{className:"text-xs text-text-secondary",children:"CEO"}),l.jsx("p",{className:"text-text-primary",children:N.ceo})]}),l.jsxs("div",{children:[l.jsx("p",{className:"text-xs text-text-secondary",children:"Founded"}),l.jsx("p",{className:"text-text-primary",children:Rt(N.founded_at)})]}),l.jsxs("div",{children:[l.jsx("p",{className:"text-xs text-text-secondary",children:"Employees"}),l.jsx("p",{className:"text-text-primary",children:N.employees})]})]}),l.jsxs("div",{children:[l.jsx("p",{className:"text-xs font-medium text-text-secondary uppercase mb-2",children:"Board"}),l.jsx("div",{className:"space-y-2",children:N.board_members.map(E=>l.jsxs("div",{className:"flex items-center justify-between text-sm",children:[l.jsxs("div",{children:[l.jsx("p",{className:"text-text-primary",children:E.name}),l.jsx("p",{className:"text-xs text-text-secondary",children:E.role})]}),l.jsx("span",{className:"text-xs text-text-secondary",children:E.since})]},E.id))})]}),l.jsxs("div",{className:"flex items-center gap-2 pt-2 border-t border-border/40",children:[l.jsx(Xr,{size:14,className:N.compliance_status==="compliant"?"text-success":"text-warning"}),l.jsxs("span",{className:"text-xs text-text-secondary",children:["Compliance: ",N.compliance_status]})]})]})},N.id))})]}),e==="ownership"&&p&&l.jsx("div",{className:"space-y-6",children:l.jsxs(ee,{children:[l.jsx(Ie,{title:"Ownership Structure",subtitle:"Ultimate Beneficial Owner"}),l.jsxs("div",{className:"p-5",children:[p.ultimate_beneficial_owner&&l.jsxs("div",{className:"flex items-center gap-4 p-4 bg-bg rounded-xl mb-6",children:[l.jsx("div",{className:"w-12 h-12 rounded-full bg-primary/10 flex items-center justify-center text-primary text-lg font-semibold",children:p.ultimate_beneficial_owner.name.charAt(0)}),l.jsxs("div",{children:[l.jsx("p",{className:"text-lg font-semibold text-text-primary",children:p.ultimate_beneficial_owner.name}),l.jsxs("p",{className:"text-sm text-text-secondary",children:[p.ultimate_beneficial_owner.ownership,"% ownership •"," ",p.ultimate_beneficial_owner.nationality]})]})]}),l.jsx("div",{className:"space-y-3",children:(T=p.entities)==null?void 0:T.map((N,E)=>l.jsxs("div",{className:"flex items-center gap-4",children:[l.jsx("div",{className:"w-8 h-8 rounded-lg bg-primary/10 flex items-center justify-center text-primary text-xs font-medium",children:N.jurisdiction}),l.jsxs("div",{className:"flex-1",children:[l.jsx("p",{className:"text-sm font-medium text-text-primary",children:N.name}),l.jsxs("p",{className:"text-xs text-text-secondary",children:[N.type," • ",N.jurisdiction]})]}),l.jsxs("div",{className:"text-right",children:[l.jsxs("p",{className:"text-sm font-medium text-text-primary",children:[N.ownership,"%"]}),l.jsx("p",{className:"text-xs text-text-secondary",children:N.owner})]})]},E))})]})]})}),e==="documents"&&l.jsx("div",{className:"space-y-6",children:l.jsxs(ee,{children:[l.jsx(Ie,{title:"Documents",subtitle:"Corporate documents & agreements"}),l.jsx("div",{className:"overflow-x-auto",children:l.jsxs("table",{className:"w-full",children:[l.jsx("thead",{className:"border-b border-border",children:l.jsxs("tr",{children:[l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Title"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Type"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Status"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Signed By"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-right",children:"Date"})]})}),l.jsx("tbody",{children:i.map(N=>{var E;return l.jsxs("tr",{className:"border-b border-border/50",children:[l.jsx("td",{className:"py-3.5 px-4",children:l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx(Oi,{size:16,className:"text-text-secondary"}),l.jsx("span",{className:"text-sm text-text-primary",children:N.title})]})}),l.jsx("td",{className:"py-3.5 px-4 text-sm text-text-secondary",children:N.type}),l.jsx("td",{className:"py-3.5 px-4",children:l.jsx(Se,{variant:_(N.status),children:N.status})}),l.jsx("td",{className:"py-3.5 px-4 text-sm text-text-secondary",children:((E=N.signed_by)==null?void 0:E.join(", "))||"-"}),l.jsx("td",{className:"py-3.5 px-4 text-right text-sm text-text-secondary",children:Rt(N.created_at)})]},N.id)})})]})})]})}),e==="compliance"&&l.jsxs("div",{className:"space-y-6",children:[d&&l.jsxs("div",{className:"grid grid-cols-2 sm:grid-cols-4 gap-5",children:[l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary-light flex items-center justify-center text-primary",children:l.jsx(Xr,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:d.total}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Total Items"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-success-light flex items-center justify-center text-success",children:l.jsx(Dr,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:d.completed}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Completed"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-warning-light flex items-center justify-center text-warning",children:l.jsx(vr,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:d.in_progress}),l.jsx("p",{className:"text-xs text-text-secondary",children:"In Progress"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-danger-light flex items-center justify-center text-danger",children:l.jsx(Yt,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:d.overdue}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Overdue"})]})]})})]}),l.jsxs(ee,{children:[l.jsx(Ie,{title:"Compliance Items",subtitle:"Regulatory requirements & deadlines"}),l.jsx("div",{className:"overflow-x-auto",children:l.jsxs("table",{className:"w-full",children:[l.jsx("thead",{className:"border-b border-border",children:l.jsxs("tr",{children:[l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Item"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Type"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Status"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Due Date"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Responsible"})]})}),l.jsx("tbody",{children:c.map(N=>l.jsxs("tr",{className:"border-b border-border/50",children:[l.jsx("td",{className:"py-3.5 px-4",children:l.jsxs("div",{className:"flex items-center gap-2",children:[O(N.status),l.jsx("span",{className:"text-sm text-text-primary",children:N.title})]})}),l.jsx("td",{className:"py-3.5 px-4 text-sm text-text-secondary",children:N.type}),l.jsx("td",{className:"py-3.5 px-4",children:l.jsx(Se,{variant:_(N.status),children:N.status})}),l.jsx("td",{className:"py-3.5 px-4 text-sm text-text-primary",children:Rt(N.due_date)}),l.jsx("td",{className:"py-3.5 px-4 text-sm text-text-secondary",children:N.responsible})]},N.id))})]})})]})]})]})}function Zce(){const[e,t]=P.useState("iso"),[n,r]=P.useState([]),[i,o]=P.useState([]),[c,f]=P.useState([]),[d,h]=P.useState([]),[p,y]=P.useState([]),[x,j]=P.useState(!0),[w,S]=P.useState(""),b=[{key:"iso",label:"ISO Certifications",icon:VT},{key:"gdpr",label:"GDPR / Privacy",icon:gz},{key:"risks",label:"Risk Register",icon:Yt},{key:"legal",label:"Legal Cases",icon:WT},{key:"policies",label:"Policies",icon:Ah}];P.useEffect(()=>{A()},[]);async function A(){j(!0),S("");try{const[T,N,E,M,D]=await Promise.all([Ec.iso(),Ec.gdpr(),Ec.risks(),Ec.legalCases(),Ec.policies()]);r(T.certifications||[]),o(N.records||[]),f(E.risks||[]),h(M.cases||[]),y(D.policies||[])}catch(T){S(T instanceof Error?T.message:"Failed to load compliance data")}finally{j(!1)}}function _(T){switch(T){case"active":case"completed":case"signed":case"mitigated":return"success";case"in_progress":case"pending":case"draft":return"warning";case"critical":case"failed":case"high":return"danger";default:return"default"}}function O(T){return T>=15?"text-danger":T>=10?"text-warning":"text-success"}return x?l.jsxs("div",{className:"space-y-8",children:[l.jsx(ke,{className:"h-[80px]"}),l.jsx(ke,{className:"h-[400px]"})]}):w?l.jsx("div",{className:"flex items-center justify-center h-64",children:l.jsx("p",{className:"text-danger",children:w})}):l.jsxs("div",{className:"space-y-8",children:[l.jsx("div",{className:"flex flex-col sm:flex-row sm:items-center justify-between gap-4",children:l.jsxs("div",{children:[l.jsx("h1",{className:"text-xl font-semibold text-text-primary",children:"Compliance & Legal"}),l.jsx("p",{className:"text-sm text-text-secondary mt-0.5",children:"ISO, GDPR, risk management, legal cases & policies"})]})}),l.jsx("div",{className:"flex items-center gap-1 bg-bg rounded-xl p-1 overflow-x-auto max-w-full",children:b.map(T=>l.jsxs("button",{onClick:()=>t(T.key),className:`px-4 py-2 text-sm font-medium rounded-lg transition-colors whitespace-nowrap flex items-center gap-2 ${e===T.key?"bg-surface text-text-primary shadow-sm":"text-text-secondary hover:text-text-primary"}`,children:[l.jsx(T.icon,{size:16}),T.label]},T.key))}),e==="iso"&&l.jsxs("div",{className:"space-y-6",children:[l.jsxs("div",{className:"grid grid-cols-2 sm:grid-cols-4 gap-5",children:[l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary-light flex items-center justify-center text-primary",children:l.jsx(VT,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:n.length}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Total"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-success-light flex items-center justify-center text-success",children:l.jsx(Dr,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:n.filter(T=>T.status==="active").length}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Active"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-warning-light flex items-center justify-center text-warning",children:l.jsx(vr,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:n.filter(T=>T.status==="in_progress").length}),l.jsx("p",{className:"text-xs text-text-secondary",children:"In Progress"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-danger-light flex items-center justify-center text-danger",children:l.jsx(Yt,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:n.reduce((T,N)=>T+N.major_findings,0)}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Major Findings"})]})]})})]}),l.jsx("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-5",children:n.map(T=>l.jsx(ee,{children:l.jsxs("div",{className:"p-5 space-y-4",children:[l.jsxs("div",{className:"flex items-start justify-between",children:[l.jsxs("div",{children:[l.jsx("h3",{className:"text-sm font-semibold text-text-primary",children:T.standard}),l.jsx("p",{className:"text-xs text-text-secondary",children:T.name})]}),l.jsx(Se,{variant:_(T.status),children:T.status})]}),l.jsxs("div",{className:"grid grid-cols-2 gap-3 text-sm",children:[l.jsxs("div",{children:[l.jsx("p",{className:"text-xs text-text-secondary",children:"Issuer"}),l.jsx("p",{className:"text-text-primary",children:T.issuer})]}),l.jsxs("div",{children:[l.jsx("p",{className:"text-xs text-text-secondary",children:"Auditor"}),l.jsx("p",{className:"text-text-primary",children:T.auditor})]}),l.jsxs("div",{children:[l.jsx("p",{className:"text-xs text-text-secondary",children:"Issued"}),l.jsx("p",{className:"text-text-primary",children:T.issued_at?Rt(T.issued_at):"N/A"})]}),l.jsxs("div",{children:[l.jsx("p",{className:"text-xs text-text-secondary",children:"Expires"}),l.jsx("p",{className:"text-text-primary",children:T.expires_at?Rt(T.expires_at):"N/A"})]})]}),l.jsxs("div",{className:"p-3 bg-bg rounded-lg",children:[l.jsx("p",{className:"text-xs text-text-secondary mb-1",children:"Scope"}),l.jsx("p",{className:"text-sm text-text-primary",children:T.scope})]}),T.findings>0&&l.jsxs("div",{className:"flex items-center gap-4 text-sm",children:[l.jsxs("span",{className:"text-text-secondary",children:["Findings: ",T.findings]}),T.major_findings>0&&l.jsxs("span",{className:"text-danger",children:["Major: ",T.major_findings]})]})]})},T.id))})]}),e==="gdpr"&&l.jsx("div",{className:"space-y-6",children:i.map(T=>l.jsx(ee,{children:l.jsxs("div",{className:"p-5 space-y-4",children:[l.jsxs("div",{className:"flex items-start justify-between",children:[l.jsx("h3",{className:"text-sm font-semibold text-text-primary",children:T.purpose}),l.jsx(Se,{variant:T.impact_assessment?"success":"warning",children:T.impact_assessment?"DPIA Done":"No DPIA"})]}),l.jsxs("div",{className:"grid grid-cols-2 gap-3 text-sm",children:[l.jsxs("div",{children:[l.jsx("p",{className:"text-xs text-text-secondary",children:"Legal Basis"}),l.jsx("p",{className:"text-text-primary",children:T.legal_basis})]}),l.jsxs("div",{children:[l.jsx("p",{className:"text-xs text-text-secondary",children:"Retention"}),l.jsx("p",{className:"text-text-primary",children:T.retention})]})]}),l.jsxs("div",{children:[l.jsx("p",{className:"text-xs text-text-secondary mb-2",children:"Data Types"}),l.jsx("div",{className:"flex flex-wrap gap-2",children:T.data_types.map((N,E)=>l.jsx(Se,{variant:"default",size:"sm",children:N},E))})]}),l.jsxs("div",{children:[l.jsx("p",{className:"text-xs text-text-secondary mb-2",children:"Processors"}),l.jsx("div",{className:"flex flex-wrap gap-2",children:T.processors.map((N,E)=>l.jsx(Se,{variant:"default",size:"sm",children:N},E))})]}),l.jsxs("div",{className:"flex items-center gap-4 text-sm",children:[l.jsxs("span",{className:T.dpa_exists?"text-success":"text-danger",children:["DPA: ",T.dpa_exists?"✓":"✗"]}),l.jsxs("span",{className:T.cross_border?"text-warning":"text-text-secondary",children:["Cross-border: ",T.cross_border?"Yes":"No"]})]})]})},T.id))}),e==="risks"&&l.jsxs("div",{className:"space-y-6",children:[l.jsxs("div",{className:"grid grid-cols-2 sm:grid-cols-4 gap-5",children:[l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary-light flex items-center justify-center text-primary",children:l.jsx(Yt,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:c.length}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Total Risks"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-danger-light flex items-center justify-center text-danger",children:l.jsx(ea,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:c.filter(T=>T.status==="active").length}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Active"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-success-light flex items-center justify-center text-success",children:l.jsx(Dr,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:c.filter(T=>T.status==="mitigated").length}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Mitigated"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-warning-light flex items-center justify-center text-warning",children:l.jsx(vr,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:c.filter(T=>T.status==="monitored").length}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Monitored"})]})]})})]}),l.jsxs(ee,{children:[l.jsx(Ie,{title:"Risk Register",subtitle:"Identified risks and mitigations"}),l.jsx("div",{className:"overflow-x-auto",children:l.jsxs("table",{className:"w-full",children:[l.jsx("thead",{className:"border-b border-border",children:l.jsxs("tr",{children:[l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Risk"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Category"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-center",children:"P"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-center",children:"I"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-center",children:"Score"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Status"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Owner"})]})}),l.jsx("tbody",{children:c.map(T=>l.jsxs("tr",{className:"border-b border-border/50",children:[l.jsx("td",{className:"py-3.5 px-4",children:l.jsxs("div",{children:[l.jsx("p",{className:"text-sm text-text-primary",children:T.description}),l.jsx("p",{className:"text-xs text-text-secondary",children:T.mitigation})]})}),l.jsx("td",{className:"py-3.5 px-4 text-sm text-text-secondary",children:T.category}),l.jsx("td",{className:"py-3.5 px-4 text-center text-sm text-text-primary",children:T.probability}),l.jsx("td",{className:"py-3.5 px-4 text-center text-sm text-text-primary",children:T.impact}),l.jsx("td",{className:"py-3.5 px-4 text-center",children:l.jsx("span",{className:`text-sm font-semibold ${O(T.score)}`,children:T.score})}),l.jsx("td",{className:"py-3.5 px-4",children:l.jsx(Se,{variant:_(T.status),children:T.status})}),l.jsx("td",{className:"py-3.5 px-4 text-sm text-text-primary",children:T.owner})]},T.id))})]})})]})]}),e==="legal"&&l.jsxs("div",{className:"space-y-6",children:[l.jsxs("div",{className:"grid grid-cols-2 sm:grid-cols-3 gap-5",children:[l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary-light flex items-center justify-center text-primary",children:l.jsx(WT,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:d.length}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Total Cases"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-danger-light flex items-center justify-center text-danger",children:l.jsx(Yt,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:d.filter(T=>T.status==="active").length}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Active"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-warning-light flex items-center justify-center text-warning",children:l.jsx(ea,{size:18})}),l.jsxs("div",{children:[l.jsxs("p",{className:"text-2xl font-semibold text-text-primary",children:[d.reduce((T,N)=>T+N.value,0).toLocaleString()," SEK"]}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Total Exposure"})]})]})})]}),l.jsx("div",{className:"space-y-4",children:d.map(T=>l.jsx(ee,{children:l.jsxs("div",{className:"p-5 space-y-3",children:[l.jsxs("div",{className:"flex items-start justify-between",children:[l.jsxs("div",{children:[l.jsx("h3",{className:"text-sm font-semibold text-text-primary",children:T.title}),l.jsx("p",{className:"text-xs text-text-secondary",children:T.opposing_party})]}),l.jsx(Se,{variant:_(T.status),children:T.status})]}),l.jsx("p",{className:"text-sm text-text-secondary",children:T.description}),l.jsxs("div",{className:"flex items-center gap-4 text-sm",children:[l.jsxs("span",{className:"text-text-secondary",children:["Type: ",T.type]}),l.jsxs("span",{className:"text-text-secondary",children:["Lawyer: ",T.lawyer]}),l.jsxs("span",{className:"text-text-secondary",children:["Opened: ",Rt(T.opened_at)]})]}),T.value>0&&l.jsxs("p",{className:"text-sm font-medium text-danger",children:["Exposure: ",T.value.toLocaleString()," ",T.currency]})]})},T.id))})]}),e==="policies"&&l.jsx("div",{className:"space-y-6",children:l.jsxs(ee,{children:[l.jsx(Ie,{title:"Policies",subtitle:"Corporate policies and procedures"}),l.jsx("div",{className:"overflow-x-auto",children:l.jsxs("table",{className:"w-full",children:[l.jsx("thead",{className:"border-b border-border",children:l.jsxs("tr",{children:[l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Policy"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Category"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Version"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Status"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Approved"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-right",children:"Review"})]})}),l.jsx("tbody",{children:p.map(T=>l.jsxs("tr",{className:"border-b border-border/50",children:[l.jsx("td",{className:"py-3.5 px-4",children:l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx(Ah,{size:16,className:"text-text-secondary"}),l.jsx("span",{className:"text-sm text-text-primary",children:T.title})]})}),l.jsx("td",{className:"py-3.5 px-4 text-sm text-text-secondary",children:T.category}),l.jsx("td",{className:"py-3.5 px-4 text-sm text-text-primary",children:T.version}),l.jsx("td",{className:"py-3.5 px-4",children:l.jsx(Se,{variant:_(T.status),children:T.status})}),l.jsx("td",{className:"py-3.5 px-4 text-sm text-text-secondary",children:T.approved_by||"Not approved"}),l.jsx("td",{className:"py-3.5 px-4 text-right text-sm text-text-primary",children:Rt(T.review_date)})]},T.id))})]})})]})})]})}function Qce(){const[e,t]=P.useState("ledger"),[n,r]=P.useState([]),[i,o]=P.useState([]),[c,f]=P.useState(null),[d,h]=P.useState(!0),[p,y]=P.useState(!1),[x,j]=P.useState("");P.useEffect(()=>{w()},[]);async function w(){h(!0),j("");try{const[_,O,T]=await Promise.all([Bd.ledger(),Bd.accounts(),Bd.vismaStatus()]);r(_.entries||[]),o(O.accounts||[]),f(T.visma||null)}catch(_){j(_ instanceof Error?_.message:"Failed to load data")}finally{h(!1)}}async function S(){y(!0);try{await Bd.syncVisma(),await w()}catch(_){console.error("Sync failed:",_)}finally{y(!1)}}if(d)return l.jsxs("div",{className:"space-y-8",children:[l.jsx(ke,{className:"h-[80px]"}),l.jsx(ke,{className:"h-[400px]"})]});if(x)return l.jsx("div",{className:"flex items-center justify-center h-64",children:l.jsx("p",{className:"text-danger",children:x})});const b=n.filter(_=>!_.synced).length,A=i.reduce((_,O)=>_+O.balance,0);return l.jsxs("div",{className:"space-y-8",children:[l.jsxs("div",{className:"flex flex-col sm:flex-row sm:items-center justify-between gap-4",children:[l.jsxs("div",{children:[l.jsx("h1",{className:"text-xl font-semibold text-text-primary",children:"Accounting"}),l.jsx("p",{className:"text-sm text-text-secondary mt-0.5",children:"Double-entry bookkeeping"})]}),l.jsxs("div",{className:"flex items-center gap-3",children:[(c==null?void 0:c.configured)&&l.jsxs(Se,{variant:c.authenticated?"success":"warning",children:[l.jsx(La,{size:14,className:"mr-1"}),c.authenticated?"Visma Authenticated":"Visma Not Connected"]}),(c==null?void 0:c.configured)&&(c==null?void 0:c.authenticated)&&l.jsx(ht,{onClick:S,disabled:p,icon:l.jsx(Ma,{size:16,className:p?"animate-spin":""}),children:p?"Syncing...":"Sync to Visma"})]})]}),l.jsxs("div",{className:"grid grid-cols-2 sm:grid-cols-4 gap-5",children:[l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary-light flex items-center justify-center text-primary",children:l.jsx(Ah,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:n.length}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Entries"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-success-light flex items-center justify-center text-success",children:l.jsx(Dr,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:n.filter(_=>_.synced).length}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Synced"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-warning-light flex items-center justify-center text-warning",children:l.jsx(Yt,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:b}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Pending Sync"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary-light flex items-center justify-center text-primary",children:l.jsx(vH,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:we(A)}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Net Balance"})]})]})})]}),l.jsx("div",{className:"flex items-center gap-1 bg-bg rounded-xl p-1 overflow-x-auto max-w-full",children:[{key:"ledger",label:"Ledger"},{key:"accounts",label:"Chart of Accounts"}].map(_=>l.jsx("button",{onClick:()=>t(_.key),className:`px-4 py-2 text-sm font-medium rounded-lg transition-colors whitespace-nowrap ${e===_.key?"bg-surface text-text-primary shadow-sm":"text-text-secondary hover:text-text-primary"}`,children:_.label},_.key))}),e==="ledger"&&l.jsxs(ee,{children:[l.jsx(Ie,{title:"General Ledger",subtitle:`${n.length} entries — ${b} pending sync`}),l.jsx("div",{className:"hidden md:block overflow-x-auto",children:l.jsxs("table",{className:"w-full",children:[l.jsx("thead",{className:"border-b border-border",children:l.jsxs("tr",{children:[l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Date"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Voucher"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Description"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-left",children:"Account"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-right",children:"Debit"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-right",children:"Credit"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-center",children:"Source"}),l.jsx("th",{className:"py-3 px-4 text-xs font-medium text-text-secondary uppercase text-center",children:"Sync"})]})}),l.jsx("tbody",{children:n.map(_=>l.jsxs("tr",{className:"border-b border-border/50",children:[l.jsx("td",{className:"py-3.5 px-4 text-sm text-text-primary",children:_.date}),l.jsx("td",{className:"py-3.5 px-4 text-sm text-text-secondary",children:_.voucher_no}),l.jsx("td",{className:"py-3.5 px-4 text-sm text-text-primary",children:_.description}),l.jsx("td",{className:"py-3.5 px-4",children:l.jsxs("div",{children:[l.jsx("p",{className:"text-sm text-text-primary",children:_.account}),l.jsx("p",{className:"text-xs text-text-secondary",children:_.account_name})]})}),l.jsx("td",{className:"py-3.5 px-4 text-right text-sm text-text-primary",children:_.debit>0?we(_.debit):"-"}),l.jsx("td",{className:"py-3.5 px-4 text-right text-sm text-text-primary",children:_.credit>0?we(_.credit):"-"}),l.jsx("td",{className:"py-3.5 px-4 text-center",children:l.jsx(Se,{variant:"default",size:"sm",children:_.source})}),l.jsx("td",{className:"py-3.5 px-4 text-center",children:_.synced?l.jsx(Dr,{size:16,className:"text-success mx-auto"}):l.jsx(Oh,{size:16,className:"text-danger mx-auto"})})]},_.id))})]})}),l.jsx("div",{className:"md:hidden p-4 space-y-3",children:n.map(_=>l.jsxs(Rz,{children:[l.jsxs("div",{className:"flex justify-between items-start mb-2",children:[l.jsxs("div",{children:[l.jsx("div",{className:"font-medium text-text-primary",children:_.description}),l.jsxs("div",{className:"text-sm text-text-secondary",children:[_.account," — ",_.account_name]})]}),l.jsx(kz,{variant:_.synced?"success":"danger",children:_.synced?"Synced":"Pending"})]}),l.jsx(lg,{label:"Date",value:_.date}),l.jsx(lg,{label:"Voucher",value:_.voucher_no}),l.jsx(lg,{label:"Source",value:l.jsx(Se,{variant:"default",size:"sm",children:_.source})}),l.jsxs("div",{className:"flex justify-between items-center py-2 border-t border-border/40 mt-2",children:[l.jsx("span",{className:"text-sm text-text-secondary",children:"Debit"}),l.jsx("span",{className:"text-sm font-medium text-text-primary",children:_.debit>0?we(_.debit):"-"})]}),l.jsxs("div",{className:"flex justify-between items-center py-2",children:[l.jsx("span",{className:"text-sm text-text-secondary",children:"Credit"}),l.jsx("span",{className:"text-sm font-medium text-text-primary",children:_.credit>0?we(_.credit):"-"})]})]},_.id))})]}),e==="accounts"&&l.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-5",children:["asset","liability","equity","revenue","expense"].map(_=>{const O=i.filter(T=>T.type===_);return O.length===0?null:l.jsxs(ee,{children:[l.jsx(Ie,{title:_.charAt(0).toUpperCase()+_.slice(1)+"s",subtitle:`${O.length} accounts`}),l.jsx("div",{className:"p-5 space-y-3",children:O.map(T=>l.jsxs("div",{className:"flex items-center justify-between",children:[l.jsx("div",{children:l.jsxs("p",{className:"text-sm text-text-primary",children:[T.code," — ",T.name]})}),l.jsx("p",{className:`text-sm font-medium ${T.balance>=0?"text-text-primary":"text-danger"}`,children:we(T.balance)})]},T.code))})]},_)})})]})}function Jce(){const[e,t]=P.useState([]),[n,r]=P.useState(!0),[i,o]=P.useState(""),[c,f]=P.useState(null),[d,h]=P.useState(0),[p,y]=P.useState([]),[x,j]=P.useState("all"),[w,S]=P.useState(!1),{token:b}=za(),{user:A}=za(),_=async()=>{try{if(!b)return;const M={Authorization:`Bearer ${b}`},D=await fetch("/api/v1/mail/mailboxes",{headers:M});if(D.ok){const R=await D.json();if(R.ok&&R.mailboxes){const B=(A==null?void 0:A.email)||"",q=(A==null?void 0:A.role)||"";let z;B.includes("erik")||q==="ceo"?z=R.mailboxes.filter(H=>H.startsWith("erik@")||H==="info@landvex.com"||H==="invoice@landvex.com"||H==="hello@quixzoom.com"||H==="finance@quixzoom.com"||H==="cfo@aamos.systems"||H.startsWith("recovery@")||H.startsWith("social@")):B.includes("johan")||q==="cto"?z=R.mailboxes.filter(H=>H.startsWith("johan@")||H==="cto@aamos.systems"||H==="info@aamos.systems"||H==="dev@hypbit.com"||H.startsWith("recovery@")||H.startsWith("social@")):z=R.mailboxes,y(z)}}}catch(M){console.error("Failed to fetch mailboxes:",M)}},O=async()=>{r(!0),o("");try{if(!b){o("Please log in to access mail"),t([]),h(0);return}const M={Authorization:`Bearer ${b}`},[D,R]=await Promise.all([fetch("/api/v1/mail/inbox?limit=50",{headers:M}),fetch("/api/v1/mail/unread-count",{headers:M})]),B=await D.json();if(D.status===503){o(B.error||"Mail integration not configured"),t([]),h(0);return}if(!D.ok){if(D.status===401){o("Please log in to access mail"),t([]),h(0);return}throw new Error(B.error||"Failed to fetch inbox")}if(B.ok&&t(B.messages||[]),R.ok){const q=await R.json();q.ok&&h(q.count||0)}}catch(M){o(M instanceof Error?M.message:"Failed to load mail")}finally{r(!1)}};P.useEffect(()=>{_(),O()},[]);const T=async M=>{try{if(!b)return;const D={Authorization:`Bearer ${b}`};await fetch(`/api/v1/mail/message/${M}/read`,{method:"POST",headers:D}),t(R=>R.map(B=>B.uid===M?{...B,read:!0}:B)),h(R=>Math.max(0,R-1))}catch(D){console.error("Failed to mark as read:",D)}},N=M=>{f(M),M.read||T(M.uid)},E=x==="all"?e:e.filter(M=>M.to.some(D=>D.includes(x)));if(n)return l.jsxs("div",{className:"space-y-4",children:[l.jsx(ke,{className:"h-12"}),Array.from({length:5}).map((M,D)=>l.jsx(ke,{className:"h-20"},D))]});if(i){const M=i.includes("not configured")||i.includes("IMAP"),D=i.includes("log in")||i.includes("authorization")||i.includes("missing authorization");return l.jsx("div",{className:"flex items-center justify-center h-64",children:l.jsx("div",{className:"text-center max-w-md px-4",children:M?l.jsxs(l.Fragment,{children:[l.jsx(ig,{size:48,className:"mx-auto text-text-tertiary mb-4"}),l.jsx("h3",{className:"text-lg font-medium text-text-primary mb-2",children:"Mail not configured"}),l.jsx("p",{className:"text-text-secondary mb-4",children:i}),l.jsx("p",{className:"text-sm text-text-tertiary",children:"Contact your administrator to set up IMAP integration."})]}):D?l.jsxs(l.Fragment,{children:[l.jsx(Rd,{size:48,className:"mx-auto text-warning mb-4"}),l.jsx("h3",{className:"text-lg font-medium text-text-primary mb-2",children:"Authentication required"}),l.jsx("p",{className:"text-text-secondary mb-4",children:i}),l.jsx("button",{onClick:()=>window.location.href="/login",className:"px-4 py-2 bg-primary text-white rounded-lg hover:bg-primary-hover flex items-center gap-2 mx-auto",children:"Log in"})]}):l.jsxs(l.Fragment,{children:[l.jsx(Rd,{size:48,className:"mx-auto text-danger mb-4"}),l.jsx("p",{className:"text-danger mb-4",children:i}),l.jsxs("button",{onClick:O,className:"px-4 py-2 bg-primary text-white rounded-lg hover:bg-primary-hover flex items-center gap-2 mx-auto",children:[l.jsx(Ma,{size:16}),"Retry"]})]})})})}return c?l.jsxs("div",{className:"space-y-4",children:[l.jsx("div",{className:"flex items-center gap-2",children:l.jsx("button",{onClick:()=>f(null),className:"p-2 hover:bg-surface rounded-lg",children:"← Back"})}),l.jsx(ee,{children:l.jsxs("div",{className:"p-4 space-y-4",children:[l.jsxs("div",{className:"flex items-start justify-between",children:[l.jsxs("div",{children:[l.jsx("h2",{className:"text-lg font-semibold",children:c.subject}),l.jsxs("p",{className:"text-sm text-text-secondary",children:["From: ",c.from]}),l.jsxs("p",{className:"text-sm text-text-secondary",children:["To: ",c.to.join(", ")]}),l.jsx("p",{className:"text-sm text-text-secondary",children:Rt(c.date)})]}),!c.read&&l.jsx(Se,{variant:"primary",children:"New"})]}),l.jsx("div",{className:"border-t border-border-subtle pt-4",children:l.jsx("p",{className:"text-text-primary whitespace-pre-wrap",children:c.body})})]})})]}):l.jsxs("div",{className:"space-y-4",children:[l.jsxs("div",{className:"relative",children:[l.jsxs("button",{onClick:()=>S(!w),className:"w-full flex items-center justify-between p-3 bg-surface rounded-lg border border-border hover:border-border-hover transition-colors",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx(Sn,{size:18,className:"text-text-secondary"}),l.jsx("span",{className:"font-medium",children:x==="all"?"All Mailboxes":x})]}),l.jsx(eS,{size:18,className:`text-text-secondary transition-transform ${w?"rotate-180":""}`})]}),w&&l.jsxs("div",{className:"absolute top-full left-0 right-0 mt-1 bg-surface border border-border rounded-lg shadow-lg z-50 max-h-64 overflow-y-auto",children:[l.jsx("button",{onClick:()=>{j("all"),S(!1)},className:`w-full text-left px-3 py-2 hover:bg-surface-hover transition-colors ${x==="all"?"bg-accent/10 text-accent":""}`,children:l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx(Rd,{size:16}),l.jsx("span",{children:"All Mailboxes"}),l.jsx(Se,{variant:"default",className:"ml-auto",children:e.length})]})}),p.map(M=>l.jsx("button",{onClick:()=>{j(M),S(!1)},className:`w-full text-left px-3 py-2 hover:bg-surface-hover transition-colors ${x===M?"bg-accent/10 text-accent":""}`,children:l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx(Sn,{size:16}),l.jsx("span",{className:"text-sm",children:M})]})},M))]})]}),l.jsxs("div",{className:"flex items-center justify-between",children:[l.jsxs("div",{className:"flex items-center gap-4",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx(Rd,{size:18,className:"text-text-secondary"}),l.jsxs("span",{className:"text-sm text-text-secondary",children:[E.length," messages"]})]}),d>0&&l.jsxs(Se,{variant:"primary",children:[d," unread"]})]}),l.jsx("button",{onClick:O,className:"p-2 hover:bg-surface rounded-lg transition-colors",title:"Refresh",children:l.jsx(Ma,{size:18,className:"text-text-secondary"})})]}),l.jsx("div",{className:"space-y-2",children:E.length===0?l.jsxs("div",{className:"text-center py-12",children:[l.jsx(ig,{size:48,className:"mx-auto text-text-tertiary mb-4"}),l.jsx("p",{className:"text-text-secondary",children:"No messages"})]}):E.map(M=>l.jsx("button",{onClick:()=>N(M),className:`w-full text-left p-4 rounded-lg border transition-colors hover:bg-surface-hover ${M.read?"bg-surface border-border-subtle":"bg-surface border-border hover:border-border-hover"}`,children:l.jsxs("div",{className:"flex items-start gap-3",children:[l.jsx("div",{className:"mt-1",children:M.read?l.jsx(ig,{size:18,className:"text-text-tertiary"}):l.jsx(Sn,{size:18,className:"text-accent"})}),l.jsxs("div",{className:"flex-1 min-w-0",children:[l.jsxs("div",{className:"flex items-center gap-2 mb-1",children:[!M.read&&l.jsx(Se,{variant:"primary",className:"shrink-0",children:"New"}),l.jsx("span",{className:`font-medium truncate ${M.read?"text-text-secondary":"text-text-primary"}`,children:M.from}),l.jsx("span",{className:"text-text-tertiary text-sm shrink-0",children:Rt(M.date)})]}),l.jsx("p",{className:`font-medium truncate ${M.read?"text-text-secondary":"text-text-primary"}`,children:M.subject}),l.jsx("p",{className:"text-sm text-text-tertiary truncate",children:M.preview}),M.attachments>0&&l.jsx("div",{className:"flex items-center gap-1 mt-1",children:l.jsxs("span",{className:"text-xs text-text-tertiary",children:[M.attachments," attachment",M.attachments>1?"s":""]})})]})]})},M.uid))})]})}function eue(){const[e,t]=P.useState({email:"erik@aamos.systems",password:"",server:"mail.aamos.systems",port:993,useTLS:!0}),[n,r]=P.useState(!1),[i,o]=P.useState(!1),[c,f]=P.useState("idle"),[d,h]=P.useState(""),p=async()=>{r(!0),f("idle");try{(await fetch("/api/v1/mail/config",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)})).ok?(f("success"),h("Mail configuration saved successfully")):(f("error"),h("Failed to save configuration"))}catch{f("error"),h("Network error")}finally{r(!1)}},y=async()=>{o(!0),f("idle");try{const j=await(await fetch("/api/v1/mail/test",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)})).json();j.ok?(f("success"),h(`Connection successful! ${j.messageCount||0} unread messages.`)):(f("error"),h(j.error||"Connection failed"))}catch{f("error"),h("Network error")}finally{o(!1)}};return l.jsxs("div",{className:"max-w-2xl mx-auto space-y-6",children:[l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx(Sn,{size:24,className:"text-primary"}),l.jsxs("div",{children:[l.jsx("h1",{className:"text-2xl font-bold",children:"Mail Settings"}),l.jsx("p",{className:"text-text-secondary",children:"Connect your IMAP inbox"})]})]}),c!=="idle"&&l.jsxs("div",{className:`p-4 rounded-xl flex items-center gap-3 ${c==="success"?"bg-success-light text-success":"bg-danger-light text-danger"}`,children:[c==="success"?l.jsx(NH,{size:20}):l.jsx(zm,{size:20}),l.jsx("p",{children:d})]}),l.jsxs(ee,{children:[l.jsx(Ie,{title:"IMAP Configuration",subtitle:"Enter your mail credentials"}),l.jsxs("div",{className:"p-6 space-y-4",children:[l.jsxs("div",{children:[l.jsx("label",{className:"block text-sm font-medium mb-2",children:"Email Address"}),l.jsxs("select",{className:"w-full h-10 px-3 rounded-xl border border-border bg-surface text-text-primary",value:e.email,onChange:x=>t({...e,email:x.target.value}),children:[l.jsx("option",{value:"erik@aamos.systems",children:"erik@aamos.systems"}),l.jsx("option",{value:"erik@landvex.com",children:"erik@landvex.com"}),l.jsx("option",{value:"erik@wavult.com",children:"erik@wavult.com"}),l.jsx("option",{value:"erik@hypbit.com",children:"erik@hypbit.com"})]})]}),l.jsxs("div",{children:[l.jsx("label",{className:"block text-sm font-medium mb-2",children:"Password"}),l.jsx(Do,{type:"password",placeholder:"Enter your mail password",value:e.password,onChange:x=>t({...e,password:x.target.value})}),l.jsx("p",{className:"text-xs text-text-secondary mt-1",children:"Don't remember your password? Contact your admin to reset it."})]}),l.jsxs("div",{className:"grid grid-cols-2 gap-4",children:[l.jsxs("div",{children:[l.jsx("label",{className:"block text-sm font-medium mb-2",children:"Server"}),l.jsxs("div",{className:"relative",children:[l.jsx(I1,{size:16,className:"absolute left-3 top-1/2 -translate-y-1/2 text-text-tertiary"}),l.jsx(Do,{className:"pl-10",value:e.server,onChange:x=>t({...e,server:x.target.value})})]})]}),l.jsxs("div",{children:[l.jsx("label",{className:"block text-sm font-medium mb-2",children:"Port"}),l.jsx(Do,{type:"number",value:e.port,onChange:x=>t({...e,port:parseInt(x.target.value)||993})})]})]}),l.jsxs("div",{className:"flex items-center gap-3 p-4 bg-bg rounded-xl",children:[l.jsx(Xr,{size:20,className:"text-primary"}),l.jsxs("div",{className:"flex-1",children:[l.jsx("p",{className:"text-sm font-medium",children:"Use TLS/SSL"}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Encrypt connection to mail server"})]}),l.jsx("button",{onClick:()=>t({...e,useTLS:!e.useTLS}),className:`w-12 h-7 rounded-full transition-colors ${e.useTLS?"bg-primary":"bg-text-tertiary"}`,children:l.jsx("div",{className:`w-5 h-5 rounded-full bg-white transition-transform ${e.useTLS?"translate-x-6":"translate-x-1"}`})})]})]})]}),l.jsxs(ee,{children:[l.jsx(Ie,{title:"Forgot Password?",subtitle:"Reset your mail password"}),l.jsx("div",{className:"p-6",children:l.jsxs("div",{className:"flex items-start gap-4",children:[l.jsx(DH,{size:24,className:"text-warning shrink-0"}),l.jsxs("div",{children:[l.jsx("p",{className:"text-sm text-text-secondary mb-3",children:"If you've forgotten your mail password, you can reset it through the Mailu admin panel or contact your system administrator."}),l.jsx("a",{href:"https://mail.aamos.systems/admin",target:"_blank",rel:"noopener noreferrer",className:"text-primary hover:underline text-sm",children:"Open Mailu Admin →"})]})]})})]}),l.jsxs("div",{className:"flex gap-4",children:[l.jsx(ht,{onClick:y,disabled:i||!e.email||!e.password,variant:"secondary",className:"flex-1",children:i?"Testing...":"Test Connection"}),l.jsx(ht,{onClick:p,disabled:n||!e.email||!e.password,className:"flex-1",children:n?"Saving...":"Save Configuration"})]})]})}const aD={instagram:l.jsx(kH,{size:20}),twitter:l.jsx(VH,{size:20}),facebook:l.jsx(MH,{size:20}),linkedin:l.jsx(zH,{size:20}),tiktok:l.jsx(yn,{size:20})},iD={instagram:"bg-gradient-to-br from-purple-500 to-pink-500",twitter:"bg-blue-500",facebook:"bg-blue-600",linkedin:"bg-blue-700",tiktok:"bg-black"};function tue(){var j,w,S;const[e,t]=P.useState([]),[n,r]=P.useState([]),[i,o]=P.useState(null),[c,f]=P.useState(!0),[d,h]=P.useState(""),[p,y]=P.useState("accounts");P.useEffect(()=>{x()},[]);async function x(){f(!0),h("");try{const A=await(await fetch("/api/v1/social/accounts")).json();A.ok&&t(A.accounts||[]);const O=await(await fetch("/api/v1/social/stats")).json();O.ok&&o(O.stats);const N=await(await fetch("/api/v1/social/posts")).json();N.ok&&r(N.posts||[])}catch(b){h(b instanceof Error?b.message:"Failed to load data")}finally{f(!1)}}return c?l.jsxs("div",{className:"space-y-8",children:[l.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-4 gap-5",children:[l.jsx(ke,{className:"h-[80px]"}),l.jsx(ke,{className:"h-[80px]"}),l.jsx(ke,{className:"h-[80px]"}),l.jsx(ke,{className:"h-[80px]"})]}),l.jsx(ke,{className:"h-[400px]"})]}):d?l.jsx("div",{className:"flex items-center justify-center h-64",children:l.jsx("p",{className:"text-danger",children:d})}):l.jsxs("div",{className:"space-y-8",children:[l.jsxs("div",{className:"flex flex-col sm:flex-row sm:items-center justify-between gap-4",children:[l.jsxs("div",{children:[l.jsx("h1",{className:"text-xl font-semibold text-text-primary",children:"Social Media"}),l.jsx("p",{className:"text-sm text-text-secondary mt-0.5",children:"Hantera alla sociala media-konton"})]}),l.jsx(ht,{icon:l.jsx(Lr,{size:16}),children:"Add Account"})]}),l.jsxs("div",{className:"grid grid-cols-2 sm:grid-cols-4 gap-5",children:[l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-primary-light flex items-center justify-center text-primary",children:l.jsx(Wn,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:((j=i==null?void 0:i.total_followers)==null?void 0:j.toLocaleString())||"0"}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Total Followers"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-success-light flex items-center justify-center text-success",children:l.jsx(fh,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:((w=i==null?void 0:i.total_posts)==null?void 0:w.toLocaleString())||"0"}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Total Posts"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-warning-light flex items-center justify-center text-warning",children:l.jsx(HT,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:((S=i==null?void 0:i.total_engagement)==null?void 0:S.toLocaleString())||"0"}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Engagement"})]})]})}),l.jsx(ee,{padding:"md",children:l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:"w-10 h-10 rounded-xl bg-info-light flex items-center justify-center text-info",children:l.jsx(yn,{size:18})}),l.jsxs("div",{children:[l.jsx("p",{className:"text-2xl font-semibold text-text-primary",children:(i==null?void 0:i.accounts)||0}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Accounts"})]})]})})]}),l.jsx("div",{className:"flex items-center gap-1 bg-bg rounded-xl p-1 overflow-x-auto max-w-full",children:["accounts","posts","analytics"].map(b=>l.jsx("button",{onClick:()=>y(b),className:`px-4 py-2 text-sm font-medium rounded-lg transition-colors whitespace-nowrap ${p===b?"bg-surface text-text-primary shadow-sm":"text-text-secondary hover:text-text-primary"}`,children:b.charAt(0).toUpperCase()+b.slice(1)},b))}),p==="accounts"&&l.jsx("div",{className:"space-y-4",children:e.length===0?l.jsxs(ee,{className:"p-8 text-center",children:[l.jsx(yn,{size:48,className:"mx-auto text-text-tertiary mb-4"}),l.jsx("h3",{className:"text-lg font-medium text-text-primary mb-2",children:"Inga konton kopplade"}),l.jsx("p",{className:"text-sm text-text-secondary mb-4",children:"Lägg till dina sociala media-konton för att se statistik och hantera inlägg"}),l.jsx(ht,{icon:l.jsx(Lr,{size:16}),children:"Add First Account"})]}):l.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-5",children:e.map(b=>l.jsxs(ee,{className:"relative",children:[l.jsxs("div",{className:"flex items-start justify-between mb-4",children:[l.jsxs("div",{className:"flex items-center gap-3",children:[l.jsx("div",{className:`w-12 h-12 rounded-xl ${iD[b.platform]||"bg-gray-500"} flex items-center justify-center text-white`,children:aD[b.platform]||l.jsx(yn,{size:20})}),l.jsxs("div",{children:[l.jsx("h3",{className:"font-medium text-text-primary",children:b.display_name||b.account_name}),l.jsxs("p",{className:"text-xs text-text-secondary",children:["@",b.account_name]})]})]}),l.jsx(Se,{variant:b.is_connected?"success":"default",children:b.is_connected?"Connected":"Disconnected"})]}),l.jsxs("div",{className:"grid grid-cols-3 gap-4 mb-4",children:[l.jsxs("div",{className:"text-center",children:[l.jsx("p",{className:"text-lg font-semibold text-text-primary",children:b.followers.toLocaleString()}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Followers"})]}),l.jsxs("div",{className:"text-center",children:[l.jsx("p",{className:"text-lg font-semibold text-text-primary",children:b.following.toLocaleString()}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Following"})]}),l.jsxs("div",{className:"text-center",children:[l.jsx("p",{className:"text-lg font-semibold text-text-primary",children:b.posts.toLocaleString()}),l.jsx("p",{className:"text-xs text-text-secondary",children:"Posts"})]})]}),l.jsxs("div",{className:"flex items-center justify-between",children:[l.jsxs("span",{className:"text-xs text-text-tertiary",children:["Last synced: ",b.last_synced?new Date(b.last_synced).toLocaleDateString():"Never"]}),l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx("button",{className:"w-8 h-8 flex items-center justify-center rounded-lg hover:bg-bg text-text-secondary",onClick:()=>window.open(b.profile_url,"_blank"),children:l.jsx(EH,{size:16})}),l.jsx("button",{className:"w-8 h-8 flex items-center justify-center rounded-lg hover:bg-bg text-text-secondary",children:l.jsx(Ma,{size:16})})]})]})]},b.id))})}),p==="posts"&&l.jsx("div",{className:"space-y-4",children:n.length===0?l.jsxs(ee,{className:"p-8 text-center",children:[l.jsx(fh,{size:48,className:"mx-auto text-text-tertiary mb-4"}),l.jsx("h3",{className:"text-lg font-medium text-text-primary mb-2",children:"Inga inlägg än"}),l.jsx("p",{className:"text-sm text-text-secondary",children:"Inlägg visas här när du har kopplat konton"})]}):l.jsx("div",{className:"space-y-4",children:n.map(b=>l.jsx(ee,{children:l.jsxs("div",{className:"flex items-start gap-4",children:[l.jsx("div",{className:`w-10 h-10 rounded-lg ${iD[b.platform]||"bg-gray-500"} flex items-center justify-center text-white flex-shrink-0`,children:aD[b.platform]||l.jsx(yn,{size:16})}),l.jsxs("div",{className:"flex-1 min-w-0",children:[l.jsx("p",{className:"text-sm text-text-primary mb-2",children:b.content}),b.media_url&&l.jsx("img",{src:b.media_url,alt:"Post media",className:"rounded-lg max-h-48 object-cover mb-3"}),l.jsxs("div",{className:"flex items-center gap-4 text-xs text-text-secondary",children:[l.jsxs("span",{className:"flex items-center gap-1",children:[l.jsx(HT,{size:14}),b.likes]}),l.jsxs("span",{className:"flex items-center gap-1",children:[l.jsx(fh,{size:14}),b.comments]}),l.jsxs("span",{className:"flex items-center gap-1",children:[l.jsx(Lm,{size:14}),b.shares]}),l.jsxs("span",{children:[b.reach.toLocaleString()," reach"]}),l.jsx("span",{children:"•"}),l.jsx("span",{children:new Date(b.posted_at).toLocaleDateString()})]})]})]})},b.id))})}),p==="analytics"&&l.jsxs(ee,{className:"p-8 text-center",children:[l.jsx(Ma,{size:48,className:"mx-auto text-text-tertiary mb-4"}),l.jsx("h3",{className:"text-lg font-medium text-text-primary mb-2",children:"Analytics kommer snart"}),l.jsx("p",{className:"text-sm text-text-secondary",children:"Detaljerad analys av dina sociala media-kanaler"})]})]})}function nue({children:e}){const{isAuthenticated:t}=za();return t?l.jsx(l.Fragment,{children:e}):l.jsx(bw,{to:"/login",replace:!0})}function rue({children:e}){const{isAuthenticated:t}=za();return t?l.jsx(bw,{to:"/",replace:!0}):l.jsx(l.Fragment,{children:e})}function aue(){return l.jsxs(Cq,{children:[l.jsx(St,{path:"/login",element:l.jsx(rue,{children:l.jsx($F,{})})}),l.jsxs(St,{element:l.jsx(nue,{children:l.jsx(DF,{})}),children:[l.jsx(St,{path:"/",element:l.jsx(GF,{})}),l.jsx(St,{path:"/dashboard",element:l.jsx(BF,{})}),l.jsx(St,{path:"/crm",element:l.jsx(XF,{})}),l.jsx(St,{path:"/sales",element:l.jsx(Dce,{})}),l.jsx(St,{path:"/finance",element:l.jsx(Lce,{})}),l.jsx(St,{path:"/hr",element:l.jsx(qce,{})}),l.jsx(St,{path:"/legal",element:l.jsx(rD,{})}),l.jsx(St,{path:"/marketing",element:l.jsx(Vce,{})}),l.jsx(St,{path:"/support",element:l.jsx(Fce,{})}),l.jsx(St,{path:"/automation",element:l.jsx(Kce,{})}),l.jsx(St,{path:"/amos",element:l.jsx(Yce,{})}),l.jsx(St,{path:"/quixzoom",element:l.jsx(Xce,{})}),l.jsx(St,{path:"/landvex",element:l.jsx(Wce,{})}),l.jsx(St,{path:"/compliance",element:l.jsx(Zce,{})}),l.jsx(St,{path:"/accounting",element:l.jsx(Qce,{})}),l.jsx(St,{path:"/mail",element:l.jsx(Jce,{})}),l.jsx(St,{path:"/mail/settings",element:l.jsx(eue,{})}),l.jsx(St,{path:"/social",element:l.jsx(tue,{})}),l.jsx(St,{path:"/legal",element:l.jsx(rD,{})}),l.jsx(St,{path:"/profile",element:l.jsx(KF,{})})]}),l.jsx(St,{path:"*",element:l.jsx(bw,{to:"/",replace:!0})})]})}"serviceWorker"in navigator&&navigator.serviceWorker.getRegistrations().then(e=>{for(const t of e)t.unregister()});TB.createRoot(document.getElementById("root")).render(l.jsx(P.StrictMode,{children:l.jsx(tI,{children:l.jsx(aue,{})})}));
|