var x1=e=>{throw TypeError(e)};var xm=(e,t,n)=>t.has(e)||x1("Cannot "+n);var T=(e,t,n)=>(xm(e,t,"read from private field"),n?n.call(e):t.get(e)),re=(e,t,n)=>t.has(e)?x1("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),X=(e,t,n,r)=>(xm(e,t,"write to private field"),r?r.call(e,n):t.set(e,n),n),he=(e,t,n)=>(xm(e,t,"access private method"),n);var sf=(e,t,n,r)=>({set _(a){X(e,t,a,n)},get _(){return T(e,t,r)}});(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const a of document.querySelectorAll('link[rel="modulepreload"]'))r(a);new MutationObserver(a=>{for(const i of a)if(i.type==="childList")for(const o of i.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&r(o)}).observe(document,{childList:!0,subtree:!0});function n(a){const i={};return a.integrity&&(i.integrity=a.integrity),a.referrerPolicy&&(i.referrerPolicy=a.referrerPolicy),a.crossOrigin==="use-credentials"?i.credentials="include":a.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function r(a){if(a.ep)return;a.ep=!0;const i=n(a);fetch(a.href,i)}})();var uf=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function qe(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var BA={exports:{}},Qh={};/**
 * @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 UR=Symbol.for("react.transitional.element"),qR=Symbol.for("react.fragment");function IA(e,t,n){var r=null;if(n!==void 0&&(r=""+n),t.key!==void 0&&(r=""+t.key),"key"in t){n={};for(var a in t)a!=="key"&&(n[a]=t[a])}else n=t;return t=n.ref,{$$typeof:UR,type:e,key:r,ref:t!==void 0?t:null,props:n}}Qh.Fragment=qR;Qh.jsx=IA;Qh.jsxs=IA;BA.exports=Qh;var c=BA.exports,UA={exports:{}},ue={};/**
 * @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 F0=Symbol.for("react.transitional.element"),HR=Symbol.for("react.portal"),FR=Symbol.for("react.fragment"),GR=Symbol.for("react.strict_mode"),KR=Symbol.for("react.profiler"),YR=Symbol.for("react.consumer"),VR=Symbol.for("react.context"),XR=Symbol.for("react.forward_ref"),QR=Symbol.for("react.suspense"),WR=Symbol.for("react.memo"),qA=Symbol.for("react.lazy"),ZR=Symbol.for("react.activity"),S1=Symbol.iterator;function JR(e){return e===null||typeof e!="object"?null:(e=S1&&e[S1]||e["@@iterator"],typeof e=="function"?e:null)}var HA={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},FA=Object.assign,GA={};function ss(e,t,n){this.props=e,this.context=t,this.refs=GA,this.updater=n||HA}ss.prototype.isReactComponent={};ss.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")};ss.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function KA(){}KA.prototype=ss.prototype;function G0(e,t,n){this.props=e,this.context=t,this.refs=GA,this.updater=n||HA}var K0=G0.prototype=new KA;K0.constructor=G0;FA(K0,ss.prototype);K0.isPureReactComponent=!0;var w1=Array.isArray;function Gy(){}var et={H:null,A:null,T:null,S:null},YA=Object.prototype.hasOwnProperty;function Y0(e,t,n){var r=n.ref;return{$$typeof:F0,type:e,key:t,ref:r!==void 0?r:null,props:n}}function eP(e,t){return Y0(e.type,t,e.props)}function V0(e){return typeof e=="object"&&e!==null&&e.$$typeof===F0}function tP(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(n){return t[n]})}var j1=/\/+/g;function Sm(e,t){return typeof e=="object"&&e!==null&&e.key!=null?tP(""+e.key):t.toString(36)}function nP(e){switch(e.status){case"fulfilled":return e.value;case"rejected":throw e.reason;default:switch(typeof e.status=="string"?e.then(Gy,Gy):(e.status="pending",e.then(function(t){e.status==="pending"&&(e.status="fulfilled",e.value=t)},function(t){e.status==="pending"&&(e.status="rejected",e.reason=t)})),e.status){case"fulfilled":return e.value;case"rejected":throw e.reason}}throw e}function Mo(e,t,n,r,a){var i=typeof e;(i==="undefined"||i==="boolean")&&(e=null);var o=!1;if(e===null)o=!0;else switch(i){case"bigint":case"string":case"number":o=!0;break;case"object":switch(e.$$typeof){case F0:case HR:o=!0;break;case qA:return o=e._init,Mo(o(e._payload),t,n,r,a)}}if(o)return a=a(e),o=r===""?"."+Sm(e,0):r,w1(a)?(n="",o!=null&&(n=o.replace(j1,"$&/")+"/"),Mo(a,t,n,"",function(u){return u})):a!=null&&(V0(a)&&(a=eP(a,n+(a.key==null||e&&e.key===a.key?"":(""+a.key).replace(j1,"$&/")+"/")+o)),t.push(a)),1;o=0;var l=r===""?".":r+":";if(w1(e))for(var s=0;s<e.length;s++)r=e[s],i=l+Sm(r,s),o+=Mo(r,t,n,i,a);else if(s=JR(e),typeof s=="function")for(e=s.call(e),s=0;!(r=e.next()).done;)r=r.value,i=l+Sm(r,s++),o+=Mo(r,t,n,i,a);else if(i==="object"){if(typeof e.then=="function")return Mo(nP(e),t,n,r,a);throw t=String(e),Error("Objects are not valid as a React child (found: "+(t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t)+"). If you meant to render a collection of children, use an array instead.")}return o}function cf(e,t,n){if(e==null)return e;var r=[],a=0;return Mo(e,r,"","",function(i){return t.call(n,i,a++)}),r}function rP(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(n){(e._status===0||e._status===-1)&&(e._status=1,e._result=n)},function(n){(e._status===0||e._status===-1)&&(e._status=2,e._result=n)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var O1=typeof reportError=="function"?reportError:function(e){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var t=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof e=="object"&&e!==null&&typeof e.message=="string"?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",e);return}console.error(e)},aP={map:cf,forEach:function(e,t,n){cf(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return cf(e,function(){t++}),t},toArray:function(e){return cf(e,function(t){return t})||[]},only:function(e){if(!V0(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};ue.Activity=ZR;ue.Children=aP;ue.Component=ss;ue.Fragment=FR;ue.Profiler=KR;ue.PureComponent=G0;ue.StrictMode=GR;ue.Suspense=QR;ue.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=et;ue.__COMPILER_RUNTIME={__proto__:null,c:function(e){return et.H.useMemoCache(e)}};ue.cache=function(e){return function(){return e.apply(null,arguments)}};ue.cacheSignal=function(){return null};ue.cloneElement=function(e,t,n){if(e==null)throw Error("The argument must be a React element, but you passed "+e+".");var r=FA({},e.props),a=e.key;if(t!=null)for(i in t.key!==void 0&&(a=""+t.key),t)!YA.call(t,i)||i==="key"||i==="__self"||i==="__source"||i==="ref"&&t.ref===void 0||(r[i]=t[i]);var i=arguments.length-2;if(i===1)r.children=n;else if(1<i){for(var o=Array(i),l=0;l<i;l++)o[l]=arguments[l+2];r.children=o}return Y0(e.type,a,r)};ue.createContext=function(e){return e={$$typeof:VR,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null},e.Provider=e,e.Consumer={$$typeof:YR,_context:e},e};ue.createElement=function(e,t,n){var r,a={},i=null;if(t!=null)for(r in t.key!==void 0&&(i=""+t.key),t)YA.call(t,r)&&r!=="key"&&r!=="__self"&&r!=="__source"&&(a[r]=t[r]);var o=arguments.length-2;if(o===1)a.children=n;else if(1<o){for(var l=Array(o),s=0;s<o;s++)l[s]=arguments[s+2];a.children=l}if(e&&e.defaultProps)for(r in o=e.defaultProps,o)a[r]===void 0&&(a[r]=o[r]);return Y0(e,i,a)};ue.createRef=function(){return{current:null}};ue.forwardRef=function(e){return{$$typeof:XR,render:e}};ue.isValidElement=V0;ue.lazy=function(e){return{$$typeof:qA,_payload:{_status:-1,_result:e},_init:rP}};ue.memo=function(e,t){return{$$typeof:WR,type:e,compare:t===void 0?null:t}};ue.startTransition=function(e){var t=et.T,n={};et.T=n;try{var r=e(),a=et.S;a!==null&&a(n,r),typeof r=="object"&&r!==null&&typeof r.then=="function"&&r.then(Gy,O1)}catch(i){O1(i)}finally{t!==null&&n.types!==null&&(t.types=n.types),et.T=t}};ue.unstable_useCacheRefresh=function(){return et.H.useCacheRefresh()};ue.use=function(e){return et.H.use(e)};ue.useActionState=function(e,t,n){return et.H.useActionState(e,t,n)};ue.useCallback=function(e,t){return et.H.useCallback(e,t)};ue.useContext=function(e){return et.H.useContext(e)};ue.useDebugValue=function(){};ue.useDeferredValue=function(e,t){return et.H.useDeferredValue(e,t)};ue.useEffect=function(e,t){return et.H.useEffect(e,t)};ue.useEffectEvent=function(e){return et.H.useEffectEvent(e)};ue.useId=function(){return et.H.useId()};ue.useImperativeHandle=function(e,t,n){return et.H.useImperativeHandle(e,t,n)};ue.useInsertionEffect=function(e,t){return et.H.useInsertionEffect(e,t)};ue.useLayoutEffect=function(e,t){return et.H.useLayoutEffect(e,t)};ue.useMemo=function(e,t){return et.H.useMemo(e,t)};ue.useOptimistic=function(e,t){return et.H.useOptimistic(e,t)};ue.useReducer=function(e,t,n){return et.H.useReducer(e,t,n)};ue.useRef=function(e){return et.H.useRef(e)};ue.useState=function(e){return et.H.useState(e)};ue.useSyncExternalStore=function(e,t,n){return et.H.useSyncExternalStore(e,t,n)};ue.useTransition=function(){return et.H.useTransition()};ue.version="19.2.7";UA.exports=ue;var O=UA.exports;const $=qe(O);var VA={exports:{}},Wh={},XA={exports:{}},QA={};/**
 * @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.
 */(function(e){function t(M,L){var z=M.length;M.push(L);e:for(;0<z;){var F=z-1>>>1,K=M[F];if(0<a(K,L))M[F]=L,M[z]=K,z=F;else break e}}function n(M){return M.length===0?null:M[0]}function r(M){if(M.length===0)return null;var L=M[0],z=M.pop();if(z!==L){M[0]=z;e:for(var F=0,K=M.length,G=K>>>1;F<G;){var Y=2*(F+1)-1,J=M[Y],me=Y+1,Le=M[me];if(0>a(J,z))me<K&&0>a(Le,J)?(M[F]=Le,M[me]=z,F=me):(M[F]=J,M[Y]=z,F=Y);else if(me<K&&0>a(Le,z))M[F]=Le,M[me]=z,F=me;else break e}}return L}function a(M,L){var z=M.sortIndex-L.sortIndex;return z!==0?z:M.id-L.id}if(e.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var i=performance;e.unstable_now=function(){return i.now()}}else{var o=Date,l=o.now();e.unstable_now=function(){return o.now()-l}}var s=[],u=[],d=1,f=null,h=3,p=!1,b=!1,v=!1,x=!1,m=typeof setTimeout=="function"?setTimeout:null,y=typeof clearTimeout=="function"?clearTimeout:null,g=typeof setImmediate<"u"?setImmediate:null;function S(M){for(var L=n(u);L!==null;){if(L.callback===null)r(u);else if(L.startTime<=M)r(u),L.sortIndex=L.expirationTime,t(s,L);else break;L=n(u)}}function w(M){if(v=!1,S(M),!b)if(n(s)!==null)b=!0,j||(j=!0,R());else{var L=n(u);L!==null&&C(w,L.startTime-M)}}var j=!1,A=-1,E=5,_=-1;function N(){return x?!0:!(e.unstable_now()-_<E)}function D(){if(x=!1,j){var M=e.unstable_now();_=M;var L=!0;try{e:{b=!1,v&&(v=!1,y(A),A=-1),p=!0;var z=h;try{t:{for(S(M),f=n(s);f!==null&&!(f.expirationTime>M&&N());){var F=f.callback;if(typeof F=="function"){f.callback=null,h=f.priorityLevel;var K=F(f.expirationTime<=M);if(M=e.unstable_now(),typeof K=="function"){f.callback=K,S(M),L=!0;break t}f===n(s)&&r(s),S(M)}else r(s);f=n(s)}if(f!==null)L=!0;else{var G=n(u);G!==null&&C(w,G.startTime-M),L=!1}}break e}finally{f=null,h=z,p=!1}L=void 0}}finally{L?R():j=!1}}}var R;if(typeof g=="function")R=function(){g(D)};else if(typeof MessageChannel<"u"){var B=new MessageChannel,k=B.port2;B.port1.onmessage=D,R=function(){k.postMessage(null)}}else R=function(){m(D,0)};function C(M,L){A=m(function(){M(e.unstable_now())},L)}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(M){M.callback=null},e.unstable_forceFrameRate=function(M){0>M||125<M?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):E=0<M?Math.floor(1e3/M):5},e.unstable_getCurrentPriorityLevel=function(){return h},e.unstable_next=function(M){switch(h){case 1:case 2:case 3:var L=3;break;default:L=h}var z=h;h=L;try{return M()}finally{h=z}},e.unstable_requestPaint=function(){x=!0},e.unstable_runWithPriority=function(M,L){switch(M){case 1:case 2:case 3:case 4:case 5:break;default:M=3}var z=h;h=M;try{return L()}finally{h=z}},e.unstable_scheduleCallback=function(M,L,z){var F=e.unstable_now();switch(typeof z=="object"&&z!==null?(z=z.delay,z=typeof z=="number"&&0<z?F+z:F):z=F,M){case 1:var K=-1;break;case 2:K=250;break;case 5:K=1073741823;break;case 4:K=1e4;break;default:K=5e3}return K=z+K,M={id:d++,callback:L,priorityLevel:M,startTime:z,expirationTime:K,sortIndex:-1},z>F?(M.sortIndex=z,t(u,M),n(s)===null&&M===n(u)&&(v?(y(A),A=-1):v=!0,C(w,z-F))):(M.sortIndex=K,t(s,M),b||p||(b=!0,j||(j=!0,R()))),M},e.unstable_shouldYield=N,e.unstable_wrapCallback=function(M){var L=h;return function(){var z=h;h=L;try{return M.apply(this,arguments)}finally{h=z}}}})(QA);XA.exports=QA;var iP=XA.exports,WA={exports:{}},nn={};/**
 * @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 oP=O;function ZA(e){var t="https://react.dev/errors/"+e;if(1<arguments.length){t+="?args[]="+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n])}return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function Sa(){}var Zt={d:{f:Sa,r:function(){throw Error(ZA(522))},D:Sa,C:Sa,L:Sa,m:Sa,X:Sa,S:Sa,M:Sa},p:0,findDOMNode:null},lP=Symbol.for("react.portal");function sP(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:lP,key:r==null?null:""+r,children:e,containerInfo:t,implementation:n}}var su=oP.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function Zh(e,t){if(e==="font")return"";if(typeof t=="string")return t==="use-credentials"?t:""}nn.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=Zt;nn.createPortal=function(e,t){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)throw Error(ZA(299));return sP(e,t,null,n)};nn.flushSync=function(e){var t=su.T,n=Zt.p;try{if(su.T=null,Zt.p=2,e)return e()}finally{su.T=t,Zt.p=n,Zt.d.f()}};nn.preconnect=function(e,t){typeof e=="string"&&(t?(t=t.crossOrigin,t=typeof t=="string"?t==="use-credentials"?t:"":void 0):t=null,Zt.d.C(e,t))};nn.prefetchDNS=function(e){typeof e=="string"&&Zt.d.D(e)};nn.preinit=function(e,t){if(typeof e=="string"&&t&&typeof t.as=="string"){var n=t.as,r=Zh(n,t.crossOrigin),a=typeof t.integrity=="string"?t.integrity:void 0,i=typeof t.fetchPriority=="string"?t.fetchPriority:void 0;n==="style"?Zt.d.S(e,typeof t.precedence=="string"?t.precedence:void 0,{crossOrigin:r,integrity:a,fetchPriority:i}):n==="script"&&Zt.d.X(e,{crossOrigin:r,integrity:a,fetchPriority:i,nonce:typeof t.nonce=="string"?t.nonce:void 0})}};nn.preinitModule=function(e,t){if(typeof e=="string")if(typeof t=="object"&&t!==null){if(t.as==null||t.as==="script"){var n=Zh(t.as,t.crossOrigin);Zt.d.M(e,{crossOrigin:n,integrity:typeof t.integrity=="string"?t.integrity:void 0,nonce:typeof t.nonce=="string"?t.nonce:void 0})}}else t==null&&Zt.d.M(e)};nn.preload=function(e,t){if(typeof e=="string"&&typeof t=="object"&&t!==null&&typeof t.as=="string"){var n=t.as,r=Zh(n,t.crossOrigin);Zt.d.L(e,n,{crossOrigin:r,integrity:typeof t.integrity=="string"?t.integrity:void 0,nonce:typeof t.nonce=="string"?t.nonce:void 0,type:typeof t.type=="string"?t.type:void 0,fetchPriority:typeof t.fetchPriority=="string"?t.fetchPriority:void 0,referrerPolicy:typeof t.referrerPolicy=="string"?t.referrerPolicy:void 0,imageSrcSet:typeof t.imageSrcSet=="string"?t.imageSrcSet:void 0,imageSizes:typeof t.imageSizes=="string"?t.imageSizes:void 0,media:typeof t.media=="string"?t.media:void 0})}};nn.preloadModule=function(e,t){if(typeof e=="string")if(t){var n=Zh(t.as,t.crossOrigin);Zt.d.m(e,{as:typeof t.as=="string"&&t.as!=="script"?t.as:void 0,crossOrigin:n,integrity:typeof t.integrity=="string"?t.integrity:void 0})}else Zt.d.m(e)};nn.requestFormReset=function(e){Zt.d.r(e)};nn.unstable_batchedUpdates=function(e,t){return e(t)};nn.useFormState=function(e,t,n){return su.H.useFormState(e,t,n)};nn.useFormStatus=function(){return su.H.useHostTransitionStatus()};nn.version="19.2.7";function JA(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(JA)}catch(e){console.error(e)}}JA(),WA.exports=nn;var uP=WA.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 At=iP,eE=O,cP=uP;function U(e){var t="https://react.dev/errors/"+e;if(1<arguments.length){t+="?args[]="+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n])}return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function tE(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function Pc(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,t.flags&4098&&(n=t.return),e=t.return;while(e)}return t.tag===3?n:null}function nE(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function rE(e){if(e.tag===31){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function A1(e){if(Pc(e)!==e)throw Error(U(188))}function fP(e){var t=e.alternate;if(!t){if(t=Pc(e),t===null)throw Error(U(188));return t!==e?null:e}for(var n=e,r=t;;){var a=n.return;if(a===null)break;var i=a.alternate;if(i===null){if(r=a.return,r!==null){n=r;continue}break}if(a.child===i.child){for(i=a.child;i;){if(i===n)return A1(a),e;if(i===r)return A1(a),t;i=i.sibling}throw Error(U(188))}if(n.return!==r.return)n=a,r=i;else{for(var o=!1,l=a.child;l;){if(l===n){o=!0,n=a,r=i;break}if(l===r){o=!0,r=a,n=i;break}l=l.sibling}if(!o){for(l=i.child;l;){if(l===n){o=!0,n=i,r=a;break}if(l===r){o=!0,r=i,n=a;break}l=l.sibling}if(!o)throw Error(U(189))}}if(n.alternate!==r)throw Error(U(190))}if(n.tag!==3)throw Error(U(188));return n.stateNode.current===n?e:t}function aE(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=aE(e),t!==null)return t;e=e.sibling}return null}var nt=Object.assign,dP=Symbol.for("react.element"),ff=Symbol.for("react.transitional.element"),tu=Symbol.for("react.portal"),ko=Symbol.for("react.fragment"),iE=Symbol.for("react.strict_mode"),Ky=Symbol.for("react.profiler"),oE=Symbol.for("react.consumer"),Vr=Symbol.for("react.context"),X0=Symbol.for("react.forward_ref"),Yy=Symbol.for("react.suspense"),Vy=Symbol.for("react.suspense_list"),Q0=Symbol.for("react.memo"),ja=Symbol.for("react.lazy"),Xy=Symbol.for("react.activity"),hP=Symbol.for("react.memo_cache_sentinel"),E1=Symbol.iterator;function Ds(e){return e===null||typeof e!="object"?null:(e=E1&&e[E1]||e["@@iterator"],typeof e=="function"?e:null)}var pP=Symbol.for("react.client.reference");function Qy(e){if(e==null)return null;if(typeof e=="function")return e.$$typeof===pP?null:e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case ko:return"Fragment";case Ky:return"Profiler";case iE:return"StrictMode";case Yy:return"Suspense";case Vy:return"SuspenseList";case Xy:return"Activity"}if(typeof e=="object")switch(e.$$typeof){case tu:return"Portal";case Vr:return e.displayName||"Context";case oE:return(e._context.displayName||"Context")+".Consumer";case X0:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case Q0:return t=e.displayName||null,t!==null?t:Qy(e.type)||"Memo";case ja:t=e._payload,e=e._init;try{return Qy(e(t))}catch{}}return null}var nu=Array.isArray,ie=eE.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Ne=cP.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Fi={pending:!1,data:null,method:null,action:null},Wy=[],Do=-1;function Tr(e){return{current:e}}function Rt(e){0>Do||(e.current=Wy[Do],Wy[Do]=null,Do--)}function Ye(e,t){Do++,Wy[Do]=e.current,e.current=t}var Or=Tr(null),Tu=Tr(null),Ka=Tr(null),hd=Tr(null);function pd(e,t){switch(Ye(Ka,t),Ye(Tu,e),Ye(Or,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?RS(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=RS(t),e=ET(t,e);else switch(e){case"svg":e=1;break;case"math":e=2;break;default:e=0}}Rt(Or),Ye(Or,e)}function jl(){Rt(Or),Rt(Tu),Rt(Ka)}function Zy(e){e.memoizedState!==null&&Ye(hd,e);var t=Or.current,n=ET(t,e.type);t!==n&&(Ye(Tu,e),Ye(Or,n))}function md(e){Tu.current===e&&(Rt(Or),Rt(Tu)),hd.current===e&&(Rt(hd),Bu._currentValue=Fi)}var wm,_1;function Si(e){if(wm===void 0)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);wm=t&&t[1]||"",_1=-1<n.stack.indexOf(`
    at`)?" (<anonymous>)":-1<n.stack.indexOf("@")?"@unknown:0:0":""}return`
`+wm+e+_1}var jm=!1;function Om(e,t){if(!e||jm)return"";jm=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var r={DetermineComponentFrameRoot:function(){try{if(t){var f=function(){throw Error()};if(Object.defineProperty(f.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(f,[])}catch(p){var h=p}Reflect.construct(e,[],f)}else{try{f.call()}catch(p){h=p}e.call(f.prototype)}}else{try{throw Error()}catch(p){h=p}(f=e())&&typeof f.catch=="function"&&f.catch(function(){})}}catch(p){if(p&&h&&typeof p.stack=="string")return[p.stack,h.stack]}return[null,null]}};r.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var a=Object.getOwnPropertyDescriptor(r.DetermineComponentFrameRoot,"name");a&&a.configurable&&Object.defineProperty(r.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var i=r.DetermineComponentFrameRoot(),o=i[0],l=i[1];if(o&&l){var s=o.split(`
`),u=l.split(`
`);for(a=r=0;r<s.length&&!s[r].includes("DetermineComponentFrameRoot");)r++;for(;a<u.length&&!u[a].includes("DetermineComponentFrameRoot");)a++;if(r===s.length||a===u.length)for(r=s.length-1,a=u.length-1;1<=r&&0<=a&&s[r]!==u[a];)a--;for(;1<=r&&0<=a;r--,a--)if(s[r]!==u[a]){if(r!==1||a!==1)do if(r--,a--,0>a||s[r]!==u[a]){var d=`
`+s[r].replace(" at new "," at ");return e.displayName&&d.includes("<anonymous>")&&(d=d.replace("<anonymous>",e.displayName)),d}while(1<=r&&0<=a);break}}}finally{jm=!1,Error.prepareStackTrace=n}return(n=e?e.displayName||e.name:"")?Si(n):""}function mP(e,t){switch(e.tag){case 26:case 27:case 5:return Si(e.type);case 16:return Si("Lazy");case 13:return e.child!==t&&t!==null?Si("Suspense Fallback"):Si("Suspense");case 19:return Si("SuspenseList");case 0:case 15:return Om(e.type,!1);case 11:return Om(e.type.render,!1);case 1:return Om(e.type,!0);case 31:return Si("Activity");default:return""}}function T1(e){try{var t="",n=null;do t+=mP(e,n),n=e,e=e.return;while(e);return t}catch(r){return`
Error generating stack: `+r.message+`
`+r.stack}}var Jy=Object.prototype.hasOwnProperty,W0=At.unstable_scheduleCallback,Am=At.unstable_cancelCallback,yP=At.unstable_shouldYield,vP=At.unstable_requestPaint,Tn=At.unstable_now,gP=At.unstable_getCurrentPriorityLevel,lE=At.unstable_ImmediatePriority,sE=At.unstable_UserBlockingPriority,yd=At.unstable_NormalPriority,bP=At.unstable_LowPriority,uE=At.unstable_IdlePriority,xP=At.log,SP=At.unstable_setDisableYieldValue,$c=null,Nn=null;function Ia(e){if(typeof xP=="function"&&SP(e),Nn&&typeof Nn.setStrictMode=="function")try{Nn.setStrictMode($c,e)}catch{}}var Cn=Math.clz32?Math.clz32:OP,wP=Math.log,jP=Math.LN2;function OP(e){return e>>>=0,e===0?32:31-(wP(e)/jP|0)|0}var df=256,hf=262144,pf=4194304;function wi(e){var t=e&42;if(t!==0)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function Jh(e,t,n){var r=e.pendingLanes;if(r===0)return 0;var a=0,i=e.suspendedLanes,o=e.pingedLanes;e=e.warmLanes;var l=r&134217727;return l!==0?(r=l&~i,r!==0?a=wi(r):(o&=l,o!==0?a=wi(o):n||(n=l&~e,n!==0&&(a=wi(n))))):(l=r&~i,l!==0?a=wi(l):o!==0?a=wi(o):n||(n=r&~e,n!==0&&(a=wi(n)))),a===0?0:t!==0&&t!==a&&!(t&i)&&(i=a&-a,n=t&-t,i>=n||i===32&&(n&4194048)!==0)?t:a}function kc(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function AP(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function cE(){var e=pf;return pf<<=1,!(pf&62914560)&&(pf=4194304),e}function Em(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function Dc(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function EP(e,t,n,r,a,i){var o=e.pendingLanes;e.pendingLanes=n,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=n,e.entangledLanes&=n,e.errorRecoveryDisabledLanes&=n,e.shellSuspendCounter=0;var l=e.entanglements,s=e.expirationTimes,u=e.hiddenUpdates;for(n=o&~n;0<n;){var d=31-Cn(n),f=1<<d;l[d]=0,s[d]=-1;var h=u[d];if(h!==null)for(u[d]=null,d=0;d<h.length;d++){var p=h[d];p!==null&&(p.lane&=-536870913)}n&=~f}r!==0&&fE(e,r,0),i!==0&&a===0&&e.tag!==0&&(e.suspendedLanes|=i&~(o&~t))}function fE(e,t,n){e.pendingLanes|=t,e.suspendedLanes&=~t;var r=31-Cn(t);e.entangledLanes|=t,e.entanglements[r]=e.entanglements[r]|1073741824|n&261930}function dE(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-Cn(n),a=1<<r;a&t|e[r]&t&&(e[r]|=t),n&=~a}}function hE(e,t){var n=t&-t;return n=n&42?1:Z0(n),n&(e.suspendedLanes|t)?0:n}function Z0(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function J0(e){return e&=-e,2<e?8<e?e&134217727?32:268435456:8:2}function pE(){var e=Ne.p;return e!==0?e:(e=window.event,e===void 0?32:LT(e.type))}function N1(e,t){var n=Ne.p;try{return Ne.p=e,t()}finally{Ne.p=n}}var si=Math.random().toString(36).slice(2),zt="__reactFiber$"+si,mn="__reactProps$"+si,us="__reactContainer$"+si,ev="__reactEvents$"+si,_P="__reactListeners$"+si,TP="__reactHandles$"+si,C1="__reactResources$"+si,Lc="__reactMarker$"+si;function eb(e){delete e[zt],delete e[mn],delete e[ev],delete e[_P],delete e[TP]}function Lo(e){var t=e[zt];if(t)return t;for(var n=e.parentNode;n;){if(t=n[us]||n[zt]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=LS(e);e!==null;){if(n=e[zt])return n;e=LS(e)}return t}e=n,n=e.parentNode}return null}function cs(e){if(e=e[zt]||e[us]){var t=e.tag;if(t===5||t===6||t===13||t===31||t===26||t===27||t===3)return e}return null}function ru(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(U(33))}function Jo(e){var t=e[C1];return t||(t=e[C1]={hoistableStyles:new Map,hoistableScripts:new Map}),t}function Ct(e){e[Lc]=!0}var mE=new Set,yE={};function fo(e,t){Ol(e,t),Ol(e+"Capture",t)}function Ol(e,t){for(yE[e]=t,e=0;e<t.length;e++)mE.add(t[e])}var NP=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]*$"),M1={},R1={};function CP(e){return Jy.call(R1,e)?!0:Jy.call(M1,e)?!1:NP.test(e)?R1[e]=!0:(M1[e]=!0,!1)}function Ff(e,t,n){if(CP(t))if(n===null)e.removeAttribute(t);else{switch(typeof n){case"undefined":case"function":case"symbol":e.removeAttribute(t);return;case"boolean":var r=t.toLowerCase().slice(0,5);if(r!=="data-"&&r!=="aria-"){e.removeAttribute(t);return}}e.setAttribute(t,""+n)}}function mf(e,t,n){if(n===null)e.removeAttribute(t);else{switch(typeof n){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(t);return}e.setAttribute(t,""+n)}}function $r(e,t,n,r){if(r===null)e.removeAttribute(n);else{switch(typeof r){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(n);return}e.setAttributeNS(t,n,""+r)}}function Un(e){switch(typeof e){case"bigint":case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function vE(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function MP(e,t,n){var r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t);if(!e.hasOwnProperty(t)&&typeof r<"u"&&typeof r.get=="function"&&typeof r.set=="function"){var a=r.get,i=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return a.call(this)},set:function(o){n=""+o,i.call(this,o)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return n},setValue:function(o){n=""+o},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function tv(e){if(!e._valueTracker){var t=vE(e)?"checked":"value";e._valueTracker=MP(e,t,""+e[t])}}function gE(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=vE(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function vd(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}var RP=/[\n"\\]/g;function Fn(e){return e.replace(RP,function(t){return"\\"+t.charCodeAt(0).toString(16)+" "})}function nv(e,t,n,r,a,i,o,l){e.name="",o!=null&&typeof o!="function"&&typeof o!="symbol"&&typeof o!="boolean"?e.type=o:e.removeAttribute("type"),t!=null?o==="number"?(t===0&&e.value===""||e.value!=t)&&(e.value=""+Un(t)):e.value!==""+Un(t)&&(e.value=""+Un(t)):o!=="submit"&&o!=="reset"||e.removeAttribute("value"),t!=null?rv(e,o,Un(t)):n!=null?rv(e,o,Un(n)):r!=null&&e.removeAttribute("value"),a==null&&i!=null&&(e.defaultChecked=!!i),a!=null&&(e.checked=a&&typeof a!="function"&&typeof a!="symbol"),l!=null&&typeof l!="function"&&typeof l!="symbol"&&typeof l!="boolean"?e.name=""+Un(l):e.removeAttribute("name")}function bE(e,t,n,r,a,i,o,l){if(i!=null&&typeof i!="function"&&typeof i!="symbol"&&typeof i!="boolean"&&(e.type=i),t!=null||n!=null){if(!(i!=="submit"&&i!=="reset"||t!=null)){tv(e);return}n=n!=null?""+Un(n):"",t=t!=null?""+Un(t):n,l||t===e.value||(e.value=t),e.defaultValue=t}r=r??a,r=typeof r!="function"&&typeof r!="symbol"&&!!r,e.checked=l?e.checked:!!r,e.defaultChecked=!!r,o!=null&&typeof o!="function"&&typeof o!="symbol"&&typeof o!="boolean"&&(e.name=o),tv(e)}function rv(e,t,n){t==="number"&&vd(e.ownerDocument)===e||e.defaultValue===""+n||(e.defaultValue=""+n)}function el(e,t,n,r){if(e=e.options,t){t={};for(var a=0;a<n.length;a++)t["$"+n[a]]=!0;for(n=0;n<e.length;n++)a=t.hasOwnProperty("$"+e[n].value),e[n].selected!==a&&(e[n].selected=a),a&&r&&(e[n].defaultSelected=!0)}else{for(n=""+Un(n),t=null,a=0;a<e.length;a++){if(e[a].value===n){e[a].selected=!0,r&&(e[a].defaultSelected=!0);return}t!==null||e[a].disabled||(t=e[a])}t!==null&&(t.selected=!0)}}function xE(e,t,n){if(t!=null&&(t=""+Un(t),t!==e.value&&(e.value=t),n==null)){e.defaultValue!==t&&(e.defaultValue=t);return}e.defaultValue=n!=null?""+Un(n):""}function SE(e,t,n,r){if(t==null){if(r!=null){if(n!=null)throw Error(U(92));if(nu(r)){if(1<r.length)throw Error(U(93));r=r[0]}n=r}n==null&&(n=""),t=n}n=Un(t),e.defaultValue=n,r=e.textContent,r===n&&r!==""&&r!==null&&(e.value=r),tv(e)}function Al(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var PP=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 P1(e,t,n){var r=t.indexOf("--")===0;n==null||typeof n=="boolean"||n===""?r?e.setProperty(t,""):t==="float"?e.cssFloat="":e[t]="":r?e.setProperty(t,n):typeof n!="number"||n===0||PP.has(t)?t==="float"?e.cssFloat=n:e[t]=(""+n).trim():e[t]=n+"px"}function wE(e,t,n){if(t!=null&&typeof t!="object")throw Error(U(62));if(e=e.style,n!=null){for(var r in n)!n.hasOwnProperty(r)||t!=null&&t.hasOwnProperty(r)||(r.indexOf("--")===0?e.setProperty(r,""):r==="float"?e.cssFloat="":e[r]="");for(var a in t)r=t[a],t.hasOwnProperty(a)&&n[a]!==r&&P1(e,a,r)}else for(var i in t)t.hasOwnProperty(i)&&P1(e,i,t[i])}function tb(e){if(e.indexOf("-")===-1)return!1;switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var $P=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"]]),kP=/^[\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 Gf(e){return kP.test(""+e)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":e}function Xr(){}var av=null;function nb(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var zo=null,tl=null;function $1(e){var t=cs(e);if(t&&(e=t.stateNode)){var n=e[mn]||null;e:switch(e=t.stateNode,t.type){case"input":if(nv(e,n.value,n.defaultValue,n.defaultValue,n.checked,n.defaultChecked,n.type,n.name),t=n.name,n.type==="radio"&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll('input[name="'+Fn(""+t)+'"][type="radio"]'),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var a=r[mn]||null;if(!a)throw Error(U(90));nv(r,a.value,a.defaultValue,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name)}}for(t=0;t<n.length;t++)r=n[t],r.form===e.form&&gE(r)}break e;case"textarea":xE(e,n.value,n.defaultValue);break e;case"select":t=n.value,t!=null&&el(e,!!n.multiple,t,!1)}}}var _m=!1;function jE(e,t,n){if(_m)return e(t,n);_m=!0;try{var r=e(t);return r}finally{if(_m=!1,(zo!==null||tl!==null)&&(fp(),zo&&(t=zo,e=tl,tl=zo=null,$1(t),e)))for(t=0;t<e.length;t++)$1(e[t])}}function Nu(e,t){var n=e.stateNode;if(n===null)return null;var r=n[mn]||null;if(r===null)return null;n=r[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(r=!r.disabled)||(e=e.type,r=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!r;break e;default:e=!1}if(e)return null;if(n&&typeof n!="function")throw Error(U(231,t,typeof n));return n}var oa=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),iv=!1;if(oa)try{var Ls={};Object.defineProperty(Ls,"passive",{get:function(){iv=!0}}),window.addEventListener("test",Ls,Ls),window.removeEventListener("test",Ls,Ls)}catch{iv=!1}var Ua=null,rb=null,Kf=null;function OE(){if(Kf)return Kf;var e,t=rb,n=t.length,r,a="value"in Ua?Ua.value:Ua.textContent,i=a.length;for(e=0;e<n&&t[e]===a[e];e++);var o=n-e;for(r=1;r<=o&&t[n-r]===a[i-r];r++);return Kf=a.slice(e,1<r?1-r:void 0)}function Yf(e){var t=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function yf(){return!0}function k1(){return!1}function yn(e){function t(n,r,a,i,o){this._reactName=n,this._targetInst=a,this.type=r,this.nativeEvent=i,this.target=o,this.currentTarget=null;for(var l in e)e.hasOwnProperty(l)&&(n=e[l],this[l]=n?n(i):i[l]);return this.isDefaultPrevented=(i.defaultPrevented!=null?i.defaultPrevented:i.returnValue===!1)?yf:k1,this.isPropagationStopped=k1,this}return nt(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var n=this.nativeEvent;n&&(n.preventDefault?n.preventDefault():typeof n.returnValue!="unknown"&&(n.returnValue=!1),this.isDefaultPrevented=yf)},stopPropagation:function(){var n=this.nativeEvent;n&&(n.stopPropagation?n.stopPropagation():typeof n.cancelBubble!="unknown"&&(n.cancelBubble=!0),this.isPropagationStopped=yf)},persist:function(){},isPersistent:yf}),t}var ho={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},ep=yn(ho),zc=nt({},ho,{view:0,detail:0}),DP=yn(zc),Tm,Nm,zs,tp=nt({},zc,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:ab,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==zs&&(zs&&e.type==="mousemove"?(Tm=e.screenX-zs.screenX,Nm=e.screenY-zs.screenY):Nm=Tm=0,zs=e),Tm)},movementY:function(e){return"movementY"in e?e.movementY:Nm}}),D1=yn(tp),LP=nt({},tp,{dataTransfer:0}),zP=yn(LP),BP=nt({},zc,{relatedTarget:0}),Cm=yn(BP),IP=nt({},ho,{animationName:0,elapsedTime:0,pseudoElement:0}),UP=yn(IP),qP=nt({},ho,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),HP=yn(qP),FP=nt({},ho,{data:0}),L1=yn(FP),GP={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},KP={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"},YP={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function VP(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=YP[e])?!!t[e]:!1}function ab(){return VP}var XP=nt({},zc,{key:function(e){if(e.key){var t=GP[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=Yf(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?KP[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:ab,charCode:function(e){return e.type==="keypress"?Yf(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?Yf(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),QP=yn(XP),WP=nt({},tp,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),z1=yn(WP),ZP=nt({},zc,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:ab}),JP=yn(ZP),e4=nt({},ho,{propertyName:0,elapsedTime:0,pseudoElement:0}),t4=yn(e4),n4=nt({},tp,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),r4=yn(n4),a4=nt({},ho,{newState:0,oldState:0}),i4=yn(a4),o4=[9,13,27,32],ib=oa&&"CompositionEvent"in window,uu=null;oa&&"documentMode"in document&&(uu=document.documentMode);var l4=oa&&"TextEvent"in window&&!uu,AE=oa&&(!ib||uu&&8<uu&&11>=uu),B1=" ",I1=!1;function EE(e,t){switch(e){case"keyup":return o4.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function _E(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Bo=!1;function s4(e,t){switch(e){case"compositionend":return _E(t);case"keypress":return t.which!==32?null:(I1=!0,B1);case"textInput":return e=t.data,e===B1&&I1?null:e;default:return null}}function u4(e,t){if(Bo)return e==="compositionend"||!ib&&EE(e,t)?(e=OE(),Kf=rb=Ua=null,Bo=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return AE&&t.locale!=="ko"?null:t.data;default:return null}}var c4={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 U1(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!c4[e.type]:t==="textarea"}function TE(e,t,n,r){zo?tl?tl.push(r):tl=[r]:zo=r,t=kd(t,"onChange"),0<t.length&&(n=new ep("onChange","change",null,n,r),e.push({event:n,listeners:t}))}var cu=null,Cu=null;function f4(e){jT(e,0)}function np(e){var t=ru(e);if(gE(t))return e}function q1(e,t){if(e==="change")return t}var NE=!1;if(oa){var Mm;if(oa){var Rm="oninput"in document;if(!Rm){var H1=document.createElement("div");H1.setAttribute("oninput","return;"),Rm=typeof H1.oninput=="function"}Mm=Rm}else Mm=!1;NE=Mm&&(!document.documentMode||9<document.documentMode)}function F1(){cu&&(cu.detachEvent("onpropertychange",CE),Cu=cu=null)}function CE(e){if(e.propertyName==="value"&&np(Cu)){var t=[];TE(t,Cu,e,nb(e)),jE(f4,t)}}function d4(e,t,n){e==="focusin"?(F1(),cu=t,Cu=n,cu.attachEvent("onpropertychange",CE)):e==="focusout"&&F1()}function h4(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return np(Cu)}function p4(e,t){if(e==="click")return np(t)}function m4(e,t){if(e==="input"||e==="change")return np(t)}function y4(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var Pn=typeof Object.is=="function"?Object.is:y4;function Mu(e,t){if(Pn(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var a=n[r];if(!Jy.call(t,a)||!Pn(e[a],t[a]))return!1}return!0}function G1(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function K1(e,t){var n=G1(e);e=0;for(var r;n;){if(n.nodeType===3){if(r=e+n.textContent.length,e<=t&&r>=t)return{node:n,offset:t-e};e=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=G1(n)}}function ME(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?ME(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function RE(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=vd(e.document);t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=vd(e.document)}return t}function ob(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}var v4=oa&&"documentMode"in document&&11>=document.documentMode,Io=null,ov=null,fu=null,lv=!1;function Y1(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;lv||Io==null||Io!==vd(r)||(r=Io,"selectionStart"in r&&ob(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),fu&&Mu(fu,r)||(fu=r,r=kd(ov,"onSelect"),0<r.length&&(t=new ep("onSelect","select",null,t,n),e.push({event:t,listeners:r}),t.target=Io)))}function vi(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var Uo={animationend:vi("Animation","AnimationEnd"),animationiteration:vi("Animation","AnimationIteration"),animationstart:vi("Animation","AnimationStart"),transitionrun:vi("Transition","TransitionRun"),transitionstart:vi("Transition","TransitionStart"),transitioncancel:vi("Transition","TransitionCancel"),transitionend:vi("Transition","TransitionEnd")},Pm={},PE={};oa&&(PE=document.createElement("div").style,"AnimationEvent"in window||(delete Uo.animationend.animation,delete Uo.animationiteration.animation,delete Uo.animationstart.animation),"TransitionEvent"in window||delete Uo.transitionend.transition);function po(e){if(Pm[e])return Pm[e];if(!Uo[e])return e;var t=Uo[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in PE)return Pm[e]=t[n];return e}var $E=po("animationend"),kE=po("animationiteration"),DE=po("animationstart"),g4=po("transitionrun"),b4=po("transitionstart"),x4=po("transitioncancel"),LE=po("transitionend"),zE=new Map,sv="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(" ");sv.push("scrollEnd");function hr(e,t){zE.set(e,t),fo(t,[e])}var gd=typeof reportError=="function"?reportError:function(e){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var t=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof e=="object"&&e!==null&&typeof e.message=="string"?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",e);return}console.error(e)},In=[],qo=0,lb=0;function rp(){for(var e=qo,t=lb=qo=0;t<e;){var n=In[t];In[t++]=null;var r=In[t];In[t++]=null;var a=In[t];In[t++]=null;var i=In[t];if(In[t++]=null,r!==null&&a!==null){var o=r.pending;o===null?a.next=a:(a.next=o.next,o.next=a),r.pending=a}i!==0&&BE(n,a,i)}}function ap(e,t,n,r){In[qo++]=e,In[qo++]=t,In[qo++]=n,In[qo++]=r,lb|=r,e.lanes|=r,e=e.alternate,e!==null&&(e.lanes|=r)}function sb(e,t,n,r){return ap(e,t,n,r),bd(e)}function mo(e,t){return ap(e,null,null,t),bd(e)}function BE(e,t,n){e.lanes|=n;var r=e.alternate;r!==null&&(r.lanes|=n);for(var a=!1,i=e.return;i!==null;)i.childLanes|=n,r=i.alternate,r!==null&&(r.childLanes|=n),i.tag===22&&(e=i.stateNode,e===null||e._visibility&1||(a=!0)),e=i,i=i.return;return e.tag===3?(i=e.stateNode,a&&t!==null&&(a=31-Cn(n),e=i.hiddenUpdates,r=e[a],r===null?e[a]=[t]:r.push(t),t.lane=n|536870912),i):null}function bd(e){if(50<xu)throw xu=0,Nv=null,Error(U(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}var Ho={};function S4(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function An(e,t,n,r){return new S4(e,t,n,r)}function ub(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Jr(e,t){var n=e.alternate;return n===null?(n=An(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&65011712,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n.refCleanup=e.refCleanup,n}function IE(e,t){e.flags&=65011714;var n=e.alternate;return n===null?(e.childLanes=0,e.lanes=t,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=n.childLanes,e.lanes=n.lanes,e.child=n.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=n.memoizedProps,e.memoizedState=n.memoizedState,e.updateQueue=n.updateQueue,e.type=n.type,t=n.dependencies,e.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function Vf(e,t,n,r,a,i){var o=0;if(r=e,typeof e=="function")ub(e)&&(o=1);else if(typeof e=="string")o=E$(e,n,Or.current)?26:e==="html"||e==="head"||e==="body"?27:5;else e:switch(e){case Xy:return e=An(31,n,t,a),e.elementType=Xy,e.lanes=i,e;case ko:return Gi(n.children,a,i,t);case iE:o=8,a|=24;break;case Ky:return e=An(12,n,t,a|2),e.elementType=Ky,e.lanes=i,e;case Yy:return e=An(13,n,t,a),e.elementType=Yy,e.lanes=i,e;case Vy:return e=An(19,n,t,a),e.elementType=Vy,e.lanes=i,e;default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Vr:o=10;break e;case oE:o=9;break e;case X0:o=11;break e;case Q0:o=14;break e;case ja:o=16,r=null;break e}o=29,n=Error(U(130,e===null?"null":typeof e,"")),r=null}return t=An(o,n,t,a),t.elementType=e,t.type=r,t.lanes=i,t}function Gi(e,t,n,r){return e=An(7,e,r,t),e.lanes=n,e}function $m(e,t,n){return e=An(6,e,null,t),e.lanes=n,e}function UE(e){var t=An(18,null,null,0);return t.stateNode=e,t}function km(e,t,n){return t=An(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var V1=new WeakMap;function Gn(e,t){if(typeof e=="object"&&e!==null){var n=V1.get(e);return n!==void 0?n:(t={value:e,source:t,stack:T1(t)},V1.set(e,t),t)}return{value:e,source:t,stack:T1(t)}}var Fo=[],Go=0,xd=null,Ru=0,qn=[],Hn=0,ai=null,xr=1,Sr="";function qr(e,t){Fo[Go++]=Ru,Fo[Go++]=xd,xd=e,Ru=t}function qE(e,t,n){qn[Hn++]=xr,qn[Hn++]=Sr,qn[Hn++]=ai,ai=e;var r=xr;e=Sr;var a=32-Cn(r)-1;r&=~(1<<a),n+=1;var i=32-Cn(t)+a;if(30<i){var o=a-a%5;i=(r&(1<<o)-1).toString(32),r>>=o,a-=o,xr=1<<32-Cn(t)+a|n<<a|r,Sr=i+e}else xr=1<<i|n<<a|r,Sr=e}function cb(e){e.return!==null&&(qr(e,1),qE(e,1,0))}function fb(e){for(;e===xd;)xd=Fo[--Go],Fo[Go]=null,Ru=Fo[--Go],Fo[Go]=null;for(;e===ai;)ai=qn[--Hn],qn[Hn]=null,Sr=qn[--Hn],qn[Hn]=null,xr=qn[--Hn],qn[Hn]=null}function HE(e,t){qn[Hn++]=xr,qn[Hn++]=Sr,qn[Hn++]=ai,xr=t.id,Sr=t.overflow,ai=e}var Bt=null,Je=null,Ae=!1,Ya=null,Kn=!1,uv=Error(U(519));function ii(e){var t=Error(U(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw Pu(Gn(t,e)),uv}function X1(e){var t=e.stateNode,n=e.type,r=e.memoizedProps;switch(t[zt]=e,t[mn]=r,n){case"dialog":xe("cancel",t),xe("close",t);break;case"iframe":case"object":case"embed":xe("load",t);break;case"video":case"audio":for(n=0;n<Lu.length;n++)xe(Lu[n],t);break;case"source":xe("error",t);break;case"img":case"image":case"link":xe("error",t),xe("load",t);break;case"details":xe("toggle",t);break;case"input":xe("invalid",t),bE(t,r.value,r.defaultValue,r.checked,r.defaultChecked,r.type,r.name,!0);break;case"select":xe("invalid",t);break;case"textarea":xe("invalid",t),SE(t,r.value,r.defaultValue,r.children)}n=r.children,typeof n!="string"&&typeof n!="number"&&typeof n!="bigint"||t.textContent===""+n||r.suppressHydrationWarning===!0||AT(t.textContent,n)?(r.popover!=null&&(xe("beforetoggle",t),xe("toggle",t)),r.onScroll!=null&&xe("scroll",t),r.onScrollEnd!=null&&xe("scrollend",t),r.onClick!=null&&(t.onclick=Xr),t=!0):t=!1,t||ii(e,!0)}function Q1(e){for(Bt=e.return;Bt;)switch(Bt.tag){case 5:case 31:case 13:Kn=!1;return;case 27:case 3:Kn=!0;return;default:Bt=Bt.return}}function Ao(e){if(e!==Bt)return!1;if(!Ae)return Q1(e),Ae=!0,!1;var t=e.tag,n;if((n=t!==3&&t!==27)&&((n=t===5)&&(n=e.type,n=!(n!=="form"&&n!=="button")||$v(e.type,e.memoizedProps)),n=!n),n&&Je&&ii(e),Q1(e),t===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(U(317));Je=DS(e)}else if(t===31){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(U(317));Je=DS(e)}else t===27?(t=Je,ui(e.type)?(e=zv,zv=null,Je=e):Je=t):Je=Bt?Qn(e.stateNode.nextSibling):null;return!0}function Zi(){Je=Bt=null,Ae=!1}function Dm(){var e=Ya;return e!==null&&(fn===null?fn=e:fn.push.apply(fn,e),Ya=null),e}function Pu(e){Ya===null?Ya=[e]:Ya.push(e)}var cv=Tr(null),yo=null,Qr=null;function _a(e,t,n){Ye(cv,t._currentValue),t._currentValue=n}function ea(e){e._currentValue=cv.current,Rt(cv)}function fv(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,r!==null&&(r.childLanes|=t)):r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t),e===n)break;e=e.return}}function dv(e,t,n,r){var a=e.child;for(a!==null&&(a.return=e);a!==null;){var i=a.dependencies;if(i!==null){var o=a.child;i=i.firstContext;e:for(;i!==null;){var l=i;i=a;for(var s=0;s<t.length;s++)if(l.context===t[s]){i.lanes|=n,l=i.alternate,l!==null&&(l.lanes|=n),fv(i.return,n,e),r||(o=null);break e}i=l.next}}else if(a.tag===18){if(o=a.return,o===null)throw Error(U(341));o.lanes|=n,i=o.alternate,i!==null&&(i.lanes|=n),fv(o,n,e),o=null}else o=a.child;if(o!==null)o.return=a;else for(o=a;o!==null;){if(o===e){o=null;break}if(a=o.sibling,a!==null){a.return=o.return,o=a;break}o=o.return}a=o}}function fs(e,t,n,r){e=null;for(var a=t,i=!1;a!==null;){if(!i){if(a.flags&524288)i=!0;else if(a.flags&262144)break}if(a.tag===10){var o=a.alternate;if(o===null)throw Error(U(387));if(o=o.memoizedProps,o!==null){var l=a.type;Pn(a.pendingProps.value,o.value)||(e!==null?e.push(l):e=[l])}}else if(a===hd.current){if(o=a.alternate,o===null)throw Error(U(387));o.memoizedState.memoizedState!==a.memoizedState.memoizedState&&(e!==null?e.push(Bu):e=[Bu])}a=a.return}e!==null&&dv(t,e,n,r),t.flags|=262144}function Sd(e){for(e=e.firstContext;e!==null;){if(!Pn(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function Ji(e){yo=e,Qr=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function Ut(e){return FE(yo,e)}function vf(e,t){return yo===null&&Ji(e),FE(e,t)}function FE(e,t){var n=t._currentValue;if(t={context:t,memoizedValue:n,next:null},Qr===null){if(e===null)throw Error(U(308));Qr=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else Qr=Qr.next=t;return n}var w4=typeof AbortController<"u"?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(n,r){e.push(r)}};this.abort=function(){t.aborted=!0,e.forEach(function(n){return n()})}},j4=At.unstable_scheduleCallback,O4=At.unstable_NormalPriority,yt={$$typeof:Vr,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function db(){return{controller:new w4,data:new Map,refCount:0}}function Bc(e){e.refCount--,e.refCount===0&&j4(O4,function(){e.controller.abort()})}var du=null,hv=0,El=0,nl=null;function A4(e,t){if(du===null){var n=du=[];hv=0,El=Lb(),nl={status:"pending",value:void 0,then:function(r){n.push(r)}}}return hv++,t.then(W1,W1),t}function W1(){if(--hv===0&&du!==null){nl!==null&&(nl.status="fulfilled");var e=du;du=null,El=0,nl=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function E4(e,t){var n=[],r={status:"pending",value:null,reason:null,then:function(a){n.push(a)}};return e.then(function(){r.status="fulfilled",r.value=t;for(var a=0;a<n.length;a++)(0,n[a])(t)},function(a){for(r.status="rejected",r.reason=a,a=0;a<n.length;a++)(0,n[a])(void 0)}),r}var Z1=ie.S;ie.S=function(e,t){aT=Tn(),typeof t=="object"&&t!==null&&typeof t.then=="function"&&A4(e,t),Z1!==null&&Z1(e,t)};var Ki=Tr(null);function hb(){var e=Ki.current;return e!==null?e:Fe.pooledCache}function Xf(e,t){t===null?Ye(Ki,Ki.current):Ye(Ki,t.pool)}function GE(){var e=hb();return e===null?null:{parent:yt._currentValue,pool:e}}var ds=Error(U(460)),pb=Error(U(474)),ip=Error(U(542)),wd={then:function(){}};function J1(e){return e=e.status,e==="fulfilled"||e==="rejected"}function KE(e,t,n){switch(n=e[n],n===void 0?e.push(t):n!==t&&(t.then(Xr,Xr),t=n),t.status){case"fulfilled":return t.value;case"rejected":throw e=t.reason,tS(e),e;default:if(typeof t.status=="string")t.then(Xr,Xr);else{if(e=Fe,e!==null&&100<e.shellSuspendCounter)throw Error(U(482));e=t,e.status="pending",e.then(function(r){if(t.status==="pending"){var a=t;a.status="fulfilled",a.value=r}},function(r){if(t.status==="pending"){var a=t;a.status="rejected",a.reason=r}})}switch(t.status){case"fulfilled":return t.value;case"rejected":throw e=t.reason,tS(e),e}throw Yi=t,ds}}function ji(e){try{var t=e._init;return t(e._payload)}catch(n){throw n!==null&&typeof n=="object"&&typeof n.then=="function"?(Yi=n,ds):n}}var Yi=null;function eS(){if(Yi===null)throw Error(U(459));var e=Yi;return Yi=null,e}function tS(e){if(e===ds||e===ip)throw Error(U(483))}var rl=null,$u=0;function gf(e){var t=$u;return $u+=1,rl===null&&(rl=[]),KE(rl,e,t)}function Bs(e,t){t=t.props.ref,e.ref=t!==void 0?t:null}function bf(e,t){throw t.$$typeof===dP?Error(U(525)):(e=Object.prototype.toString.call(t),Error(U(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e)))}function YE(e){function t(m,y){if(e){var g=m.deletions;g===null?(m.deletions=[y],m.flags|=16):g.push(y)}}function n(m,y){if(!e)return null;for(;y!==null;)t(m,y),y=y.sibling;return null}function r(m){for(var y=new Map;m!==null;)m.key!==null?y.set(m.key,m):y.set(m.index,m),m=m.sibling;return y}function a(m,y){return m=Jr(m,y),m.index=0,m.sibling=null,m}function i(m,y,g){return m.index=g,e?(g=m.alternate,g!==null?(g=g.index,g<y?(m.flags|=67108866,y):g):(m.flags|=67108866,y)):(m.flags|=1048576,y)}function o(m){return e&&m.alternate===null&&(m.flags|=67108866),m}function l(m,y,g,S){return y===null||y.tag!==6?(y=$m(g,m.mode,S),y.return=m,y):(y=a(y,g),y.return=m,y)}function s(m,y,g,S){var w=g.type;return w===ko?d(m,y,g.props.children,S,g.key):y!==null&&(y.elementType===w||typeof w=="object"&&w!==null&&w.$$typeof===ja&&ji(w)===y.type)?(y=a(y,g.props),Bs(y,g),y.return=m,y):(y=Vf(g.type,g.key,g.props,null,m.mode,S),Bs(y,g),y.return=m,y)}function u(m,y,g,S){return y===null||y.tag!==4||y.stateNode.containerInfo!==g.containerInfo||y.stateNode.implementation!==g.implementation?(y=km(g,m.mode,S),y.return=m,y):(y=a(y,g.children||[]),y.return=m,y)}function d(m,y,g,S,w){return y===null||y.tag!==7?(y=Gi(g,m.mode,S,w),y.return=m,y):(y=a(y,g),y.return=m,y)}function f(m,y,g){if(typeof y=="string"&&y!==""||typeof y=="number"||typeof y=="bigint")return y=$m(""+y,m.mode,g),y.return=m,y;if(typeof y=="object"&&y!==null){switch(y.$$typeof){case ff:return g=Vf(y.type,y.key,y.props,null,m.mode,g),Bs(g,y),g.return=m,g;case tu:return y=km(y,m.mode,g),y.return=m,y;case ja:return y=ji(y),f(m,y,g)}if(nu(y)||Ds(y))return y=Gi(y,m.mode,g,null),y.return=m,y;if(typeof y.then=="function")return f(m,gf(y),g);if(y.$$typeof===Vr)return f(m,vf(m,y),g);bf(m,y)}return null}function h(m,y,g,S){var w=y!==null?y.key:null;if(typeof g=="string"&&g!==""||typeof g=="number"||typeof g=="bigint")return w!==null?null:l(m,y,""+g,S);if(typeof g=="object"&&g!==null){switch(g.$$typeof){case ff:return g.key===w?s(m,y,g,S):null;case tu:return g.key===w?u(m,y,g,S):null;case ja:return g=ji(g),h(m,y,g,S)}if(nu(g)||Ds(g))return w!==null?null:d(m,y,g,S,null);if(typeof g.then=="function")return h(m,y,gf(g),S);if(g.$$typeof===Vr)return h(m,y,vf(m,g),S);bf(m,g)}return null}function p(m,y,g,S,w){if(typeof S=="string"&&S!==""||typeof S=="number"||typeof S=="bigint")return m=m.get(g)||null,l(y,m,""+S,w);if(typeof S=="object"&&S!==null){switch(S.$$typeof){case ff:return m=m.get(S.key===null?g:S.key)||null,s(y,m,S,w);case tu:return m=m.get(S.key===null?g:S.key)||null,u(y,m,S,w);case ja:return S=ji(S),p(m,y,g,S,w)}if(nu(S)||Ds(S))return m=m.get(g)||null,d(y,m,S,w,null);if(typeof S.then=="function")return p(m,y,g,gf(S),w);if(S.$$typeof===Vr)return p(m,y,g,vf(y,S),w);bf(y,S)}return null}function b(m,y,g,S){for(var w=null,j=null,A=y,E=y=0,_=null;A!==null&&E<g.length;E++){A.index>E?(_=A,A=null):_=A.sibling;var N=h(m,A,g[E],S);if(N===null){A===null&&(A=_);break}e&&A&&N.alternate===null&&t(m,A),y=i(N,y,E),j===null?w=N:j.sibling=N,j=N,A=_}if(E===g.length)return n(m,A),Ae&&qr(m,E),w;if(A===null){for(;E<g.length;E++)A=f(m,g[E],S),A!==null&&(y=i(A,y,E),j===null?w=A:j.sibling=A,j=A);return Ae&&qr(m,E),w}for(A=r(A);E<g.length;E++)_=p(A,m,E,g[E],S),_!==null&&(e&&_.alternate!==null&&A.delete(_.key===null?E:_.key),y=i(_,y,E),j===null?w=_:j.sibling=_,j=_);return e&&A.forEach(function(D){return t(m,D)}),Ae&&qr(m,E),w}function v(m,y,g,S){if(g==null)throw Error(U(151));for(var w=null,j=null,A=y,E=y=0,_=null,N=g.next();A!==null&&!N.done;E++,N=g.next()){A.index>E?(_=A,A=null):_=A.sibling;var D=h(m,A,N.value,S);if(D===null){A===null&&(A=_);break}e&&A&&D.alternate===null&&t(m,A),y=i(D,y,E),j===null?w=D:j.sibling=D,j=D,A=_}if(N.done)return n(m,A),Ae&&qr(m,E),w;if(A===null){for(;!N.done;E++,N=g.next())N=f(m,N.value,S),N!==null&&(y=i(N,y,E),j===null?w=N:j.sibling=N,j=N);return Ae&&qr(m,E),w}for(A=r(A);!N.done;E++,N=g.next())N=p(A,m,E,N.value,S),N!==null&&(e&&N.alternate!==null&&A.delete(N.key===null?E:N.key),y=i(N,y,E),j===null?w=N:j.sibling=N,j=N);return e&&A.forEach(function(R){return t(m,R)}),Ae&&qr(m,E),w}function x(m,y,g,S){if(typeof g=="object"&&g!==null&&g.type===ko&&g.key===null&&(g=g.props.children),typeof g=="object"&&g!==null){switch(g.$$typeof){case ff:e:{for(var w=g.key;y!==null;){if(y.key===w){if(w=g.type,w===ko){if(y.tag===7){n(m,y.sibling),S=a(y,g.props.children),S.return=m,m=S;break e}}else if(y.elementType===w||typeof w=="object"&&w!==null&&w.$$typeof===ja&&ji(w)===y.type){n(m,y.sibling),S=a(y,g.props),Bs(S,g),S.return=m,m=S;break e}n(m,y);break}else t(m,y);y=y.sibling}g.type===ko?(S=Gi(g.props.children,m.mode,S,g.key),S.return=m,m=S):(S=Vf(g.type,g.key,g.props,null,m.mode,S),Bs(S,g),S.return=m,m=S)}return o(m);case tu:e:{for(w=g.key;y!==null;){if(y.key===w)if(y.tag===4&&y.stateNode.containerInfo===g.containerInfo&&y.stateNode.implementation===g.implementation){n(m,y.sibling),S=a(y,g.children||[]),S.return=m,m=S;break e}else{n(m,y);break}else t(m,y);y=y.sibling}S=km(g,m.mode,S),S.return=m,m=S}return o(m);case ja:return g=ji(g),x(m,y,g,S)}if(nu(g))return b(m,y,g,S);if(Ds(g)){if(w=Ds(g),typeof w!="function")throw Error(U(150));return g=w.call(g),v(m,y,g,S)}if(typeof g.then=="function")return x(m,y,gf(g),S);if(g.$$typeof===Vr)return x(m,y,vf(m,g),S);bf(m,g)}return typeof g=="string"&&g!==""||typeof g=="number"||typeof g=="bigint"?(g=""+g,y!==null&&y.tag===6?(n(m,y.sibling),S=a(y,g),S.return=m,m=S):(n(m,y),S=$m(g,m.mode,S),S.return=m,m=S),o(m)):n(m,y)}return function(m,y,g,S){try{$u=0;var w=x(m,y,g,S);return rl=null,w}catch(A){if(A===ds||A===ip)throw A;var j=An(29,A,null,m.mode);return j.lanes=S,j.return=m,j}finally{}}}var eo=YE(!0),VE=YE(!1),Oa=!1;function mb(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function pv(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function Va(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function Xa(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,Te&2){var a=r.pending;return a===null?t.next=t:(t.next=a.next,a.next=t),r.pending=t,t=bd(e),BE(e,null,n),t}return ap(e,r,t,n),bd(e)}function hu(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,(n&4194048)!==0)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,dE(e,n)}}function Lm(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var a=null,i=null;if(n=n.firstBaseUpdate,n!==null){do{var o={lane:n.lane,tag:n.tag,payload:n.payload,callback:null,next:null};i===null?a=i=o:i=i.next=o,n=n.next}while(n!==null);i===null?a=i=t:i=i.next=t}else a=i=t;n={baseState:r.baseState,firstBaseUpdate:a,lastBaseUpdate:i,shared:r.shared,callbacks:r.callbacks},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}var mv=!1;function pu(){if(mv){var e=nl;if(e!==null)throw e}}function mu(e,t,n,r){mv=!1;var a=e.updateQueue;Oa=!1;var i=a.firstBaseUpdate,o=a.lastBaseUpdate,l=a.shared.pending;if(l!==null){a.shared.pending=null;var s=l,u=s.next;s.next=null,o===null?i=u:o.next=u,o=s;var d=e.alternate;d!==null&&(d=d.updateQueue,l=d.lastBaseUpdate,l!==o&&(l===null?d.firstBaseUpdate=u:l.next=u,d.lastBaseUpdate=s))}if(i!==null){var f=a.baseState;o=0,d=u=s=null,l=i;do{var h=l.lane&-536870913,p=h!==l.lane;if(p?(we&h)===h:(r&h)===h){h!==0&&h===El&&(mv=!0),d!==null&&(d=d.next={lane:0,tag:l.tag,payload:l.payload,callback:null,next:null});e:{var b=e,v=l;h=t;var x=n;switch(v.tag){case 1:if(b=v.payload,typeof b=="function"){f=b.call(x,f,h);break e}f=b;break e;case 3:b.flags=b.flags&-65537|128;case 0:if(b=v.payload,h=typeof b=="function"?b.call(x,f,h):b,h==null)break e;f=nt({},f,h);break e;case 2:Oa=!0}}h=l.callback,h!==null&&(e.flags|=64,p&&(e.flags|=8192),p=a.callbacks,p===null?a.callbacks=[h]:p.push(h))}else p={lane:h,tag:l.tag,payload:l.payload,callback:l.callback,next:null},d===null?(u=d=p,s=f):d=d.next=p,o|=h;if(l=l.next,l===null){if(l=a.shared.pending,l===null)break;p=l,l=p.next,p.next=null,a.lastBaseUpdate=p,a.shared.pending=null}}while(!0);d===null&&(s=f),a.baseState=s,a.firstBaseUpdate=u,a.lastBaseUpdate=d,i===null&&(a.shared.lanes=0),li|=o,e.lanes=o,e.memoizedState=f}}function XE(e,t){if(typeof e!="function")throw Error(U(191,e));e.call(t)}function QE(e,t){var n=e.callbacks;if(n!==null)for(e.callbacks=null,e=0;e<n.length;e++)XE(n[e],t)}var _l=Tr(null),jd=Tr(0);function nS(e,t){e=ca,Ye(jd,e),Ye(_l,t),ca=e|t.baseLanes}function yv(){Ye(jd,ca),Ye(_l,_l.current)}function yb(){ca=jd.current,Rt(_l),Rt(jd)}var $n=Tr(null),Xn=null;function Ta(e){var t=e.alternate;Ye(ct,ct.current&1),Ye($n,e),Xn===null&&(t===null||_l.current!==null||t.memoizedState!==null)&&(Xn=e)}function vv(e){Ye(ct,ct.current),Ye($n,e),Xn===null&&(Xn=e)}function WE(e){e.tag===22?(Ye(ct,ct.current),Ye($n,e),Xn===null&&(Xn=e)):Na()}function Na(){Ye(ct,ct.current),Ye($n,$n.current)}function On(e){Rt($n),Xn===e&&(Xn=null),Rt(ct)}var ct=Tr(0);function Od(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||Dv(n)||Lv(n)))return t}else if(t.tag===19&&(t.memoizedProps.revealOrder==="forwards"||t.memoizedProps.revealOrder==="backwards"||t.memoizedProps.revealOrder==="unstable_legacy-backwards"||t.memoizedProps.revealOrder==="together")){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var la=0,de=null,Ue=null,pt=null,Ad=!1,al=!1,to=!1,Ed=0,ku=0,il=null,_4=0;function ot(){throw Error(U(321))}function vb(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!Pn(e[n],t[n]))return!1;return!0}function gb(e,t,n,r,a,i){return la=i,de=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,ie.H=e===null||e.memoizedState===null?T_:Nb,to=!1,i=n(r,a),to=!1,al&&(i=JE(t,n,r,a)),ZE(e),i}function ZE(e){ie.H=Du;var t=Ue!==null&&Ue.next!==null;if(la=0,pt=Ue=de=null,Ad=!1,ku=0,il=null,t)throw Error(U(300));e===null||vt||(e=e.dependencies,e!==null&&Sd(e)&&(vt=!0))}function JE(e,t,n,r){de=e;var a=0;do{if(al&&(il=null),ku=0,al=!1,25<=a)throw Error(U(301));if(a+=1,pt=Ue=null,e.updateQueue!=null){var i=e.updateQueue;i.lastEffect=null,i.events=null,i.stores=null,i.memoCache!=null&&(i.memoCache.index=0)}ie.H=N_,i=t(n,r)}while(al);return i}function T4(){var e=ie.H,t=e.useState()[0];return t=typeof t.then=="function"?Ic(t):t,e=e.useState()[0],(Ue!==null?Ue.memoizedState:null)!==e&&(de.flags|=1024),t}function bb(){var e=Ed!==0;return Ed=0,e}function xb(e,t,n){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~n}function Sb(e){if(Ad){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}Ad=!1}la=0,pt=Ue=de=null,al=!1,ku=Ed=0,il=null}function Qt(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return pt===null?de.memoizedState=pt=e:pt=pt.next=e,pt}function ft(){if(Ue===null){var e=de.alternate;e=e!==null?e.memoizedState:null}else e=Ue.next;var t=pt===null?de.memoizedState:pt.next;if(t!==null)pt=t,Ue=e;else{if(e===null)throw de.alternate===null?Error(U(467)):Error(U(310));Ue=e,e={memoizedState:Ue.memoizedState,baseState:Ue.baseState,baseQueue:Ue.baseQueue,queue:Ue.queue,next:null},pt===null?de.memoizedState=pt=e:pt=pt.next=e}return pt}function op(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Ic(e){var t=ku;return ku+=1,il===null&&(il=[]),e=KE(il,e,t),t=de,(pt===null?t.memoizedState:pt.next)===null&&(t=t.alternate,ie.H=t===null||t.memoizedState===null?T_:Nb),e}function lp(e){if(e!==null&&typeof e=="object"){if(typeof e.then=="function")return Ic(e);if(e.$$typeof===Vr)return Ut(e)}throw Error(U(438,String(e)))}function wb(e){var t=null,n=de.updateQueue;if(n!==null&&(t=n.memoCache),t==null){var r=de.alternate;r!==null&&(r=r.updateQueue,r!==null&&(r=r.memoCache,r!=null&&(t={data:r.data.map(function(a){return a.slice()}),index:0})))}if(t==null&&(t={data:[],index:0}),n===null&&(n=op(),de.updateQueue=n),n.memoCache=t,n=t.data[t.index],n===void 0)for(n=t.data[t.index]=Array(e),r=0;r<e;r++)n[r]=hP;return t.index++,n}function sa(e,t){return typeof t=="function"?t(e):t}function Qf(e){var t=ft();return jb(t,Ue,e)}function jb(e,t,n){var r=e.queue;if(r===null)throw Error(U(311));r.lastRenderedReducer=n;var a=e.baseQueue,i=r.pending;if(i!==null){if(a!==null){var o=a.next;a.next=i.next,i.next=o}t.baseQueue=a=i,r.pending=null}if(i=e.baseState,a===null)e.memoizedState=i;else{t=a.next;var l=o=null,s=null,u=t,d=!1;do{var f=u.lane&-536870913;if(f!==u.lane?(we&f)===f:(la&f)===f){var h=u.revertLane;if(h===0)s!==null&&(s=s.next={lane:0,revertLane:0,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),f===El&&(d=!0);else if((la&h)===h){u=u.next,h===El&&(d=!0);continue}else f={lane:0,revertLane:u.revertLane,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},s===null?(l=s=f,o=i):s=s.next=f,de.lanes|=h,li|=h;f=u.action,to&&n(i,f),i=u.hasEagerState?u.eagerState:n(i,f)}else h={lane:f,revertLane:u.revertLane,gesture:u.gesture,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},s===null?(l=s=h,o=i):s=s.next=h,de.lanes|=f,li|=f;u=u.next}while(u!==null&&u!==t);if(s===null?o=i:s.next=l,!Pn(i,e.memoizedState)&&(vt=!0,d&&(n=nl,n!==null)))throw n;e.memoizedState=i,e.baseState=o,e.baseQueue=s,r.lastRenderedState=i}return a===null&&(r.lanes=0),[e.memoizedState,r.dispatch]}function zm(e){var t=ft(),n=t.queue;if(n===null)throw Error(U(311));n.lastRenderedReducer=e;var r=n.dispatch,a=n.pending,i=t.memoizedState;if(a!==null){n.pending=null;var o=a=a.next;do i=e(i,o.action),o=o.next;while(o!==a);Pn(i,t.memoizedState)||(vt=!0),t.memoizedState=i,t.baseQueue===null&&(t.baseState=i),n.lastRenderedState=i}return[i,r]}function e_(e,t,n){var r=de,a=ft(),i=Ae;if(i){if(n===void 0)throw Error(U(407));n=n()}else n=t();var o=!Pn((Ue||a).memoizedState,n);if(o&&(a.memoizedState=n,vt=!0),a=a.queue,Ob(r_.bind(null,r,a,e),[e]),a.getSnapshot!==t||o||pt!==null&&pt.memoizedState.tag&1){if(r.flags|=2048,Tl(9,{destroy:void 0},n_.bind(null,r,a,n,t),null),Fe===null)throw Error(U(349));i||la&127||t_(r,t,n)}return n}function t_(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=de.updateQueue,t===null?(t=op(),de.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function n_(e,t,n,r){t.value=n,t.getSnapshot=r,a_(t)&&i_(e)}function r_(e,t,n){return n(function(){a_(t)&&i_(e)})}function a_(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!Pn(e,n)}catch{return!0}}function i_(e){var t=mo(e,2);t!==null&&hn(t,e,2)}function gv(e){var t=Qt();if(typeof e=="function"){var n=e;if(e=n(),to){Ia(!0);try{n()}finally{Ia(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:sa,lastRenderedState:e},t}function o_(e,t,n,r){return e.baseState=n,jb(e,Ue,typeof r=="function"?r:sa)}function N4(e,t,n,r,a){if(up(e))throw Error(U(485));if(e=t.action,e!==null){var i={payload:a,action:e,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(o){i.listeners.push(o)}};ie.T!==null?n(!0):i.isTransition=!1,r(i),n=t.pending,n===null?(i.next=t.pending=i,l_(t,i)):(i.next=n.next,t.pending=n.next=i)}}function l_(e,t){var n=t.action,r=t.payload,a=e.state;if(t.isTransition){var i=ie.T,o={};ie.T=o;try{var l=n(a,r),s=ie.S;s!==null&&s(o,l),rS(e,t,l)}catch(u){bv(e,t,u)}finally{i!==null&&o.types!==null&&(i.types=o.types),ie.T=i}}else try{i=n(a,r),rS(e,t,i)}catch(u){bv(e,t,u)}}function rS(e,t,n){n!==null&&typeof n=="object"&&typeof n.then=="function"?n.then(function(r){aS(e,t,r)},function(r){return bv(e,t,r)}):aS(e,t,n)}function aS(e,t,n){t.status="fulfilled",t.value=n,s_(t),e.state=n,t=e.pending,t!==null&&(n=t.next,n===t?e.pending=null:(n=n.next,t.next=n,l_(e,n)))}function bv(e,t,n){var r=e.pending;if(e.pending=null,r!==null){r=r.next;do t.status="rejected",t.reason=n,s_(t),t=t.next;while(t!==r)}e.action=null}function s_(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function u_(e,t){return t}function iS(e,t){if(Ae){var n=Fe.formState;if(n!==null){e:{var r=de;if(Ae){if(Je){t:{for(var a=Je,i=Kn;a.nodeType!==8;){if(!i){a=null;break t}if(a=Qn(a.nextSibling),a===null){a=null;break t}}i=a.data,a=i==="F!"||i==="F"?a:null}if(a){Je=Qn(a.nextSibling),r=a.data==="F!";break e}}ii(r)}r=!1}r&&(t=n[0])}}return n=Qt(),n.memoizedState=n.baseState=t,r={pending:null,lanes:0,dispatch:null,lastRenderedReducer:u_,lastRenderedState:t},n.queue=r,n=A_.bind(null,de,r),r.dispatch=n,r=gv(!1),i=Tb.bind(null,de,!1,r.queue),r=Qt(),a={state:t,dispatch:null,action:e,pending:null},r.queue=a,n=N4.bind(null,de,a,i,n),a.dispatch=n,r.memoizedState=e,[t,n,!1]}function oS(e){var t=ft();return c_(t,Ue,e)}function c_(e,t,n){if(t=jb(e,t,u_)[0],e=Qf(sa)[0],typeof t=="object"&&t!==null&&typeof t.then=="function")try{var r=Ic(t)}catch(o){throw o===ds?ip:o}else r=t;t=ft();var a=t.queue,i=a.dispatch;return n!==t.memoizedState&&(de.flags|=2048,Tl(9,{destroy:void 0},C4.bind(null,a,n),null)),[r,i,e]}function C4(e,t){e.action=t}function lS(e){var t=ft(),n=Ue;if(n!==null)return c_(t,n,e);ft(),t=t.memoizedState,n=ft();var r=n.queue.dispatch;return n.memoizedState=e,[t,r,!1]}function Tl(e,t,n,r){return e={tag:e,create:n,deps:r,inst:t,next:null},t=de.updateQueue,t===null&&(t=op(),de.updateQueue=t),n=t.lastEffect,n===null?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e),e}function f_(){return ft().memoizedState}function Wf(e,t,n,r){var a=Qt();de.flags|=e,a.memoizedState=Tl(1|t,{destroy:void 0},n,r===void 0?null:r)}function sp(e,t,n,r){var a=ft();r=r===void 0?null:r;var i=a.memoizedState.inst;Ue!==null&&r!==null&&vb(r,Ue.memoizedState.deps)?a.memoizedState=Tl(t,i,n,r):(de.flags|=e,a.memoizedState=Tl(1|t,i,n,r))}function sS(e,t){Wf(8390656,8,e,t)}function Ob(e,t){sp(2048,8,e,t)}function M4(e){de.flags|=4;var t=de.updateQueue;if(t===null)t=op(),de.updateQueue=t,t.events=[e];else{var n=t.events;n===null?t.events=[e]:n.push(e)}}function d_(e){var t=ft().memoizedState;return M4({ref:t,nextImpl:e}),function(){if(Te&2)throw Error(U(440));return t.impl.apply(void 0,arguments)}}function h_(e,t){return sp(4,2,e,t)}function p_(e,t){return sp(4,4,e,t)}function m_(e,t){if(typeof t=="function"){e=e();var n=t(e);return function(){typeof n=="function"?n():t(null)}}if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function y_(e,t,n){n=n!=null?n.concat([e]):null,sp(4,4,m_.bind(null,t,e),n)}function Ab(){}function v_(e,t){var n=ft();t=t===void 0?null:t;var r=n.memoizedState;return t!==null&&vb(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function g_(e,t){var n=ft();t=t===void 0?null:t;var r=n.memoizedState;if(t!==null&&vb(t,r[1]))return r[0];if(r=e(),to){Ia(!0);try{e()}finally{Ia(!1)}}return n.memoizedState=[r,t],r}function Eb(e,t,n){return n===void 0||la&1073741824&&!(we&261930)?e.memoizedState=t:(e.memoizedState=n,e=oT(),de.lanes|=e,li|=e,n)}function b_(e,t,n,r){return Pn(n,t)?n:_l.current!==null?(e=Eb(e,n,r),Pn(e,t)||(vt=!0),e):!(la&42)||la&1073741824&&!(we&261930)?(vt=!0,e.memoizedState=n):(e=oT(),de.lanes|=e,li|=e,t)}function x_(e,t,n,r,a){var i=Ne.p;Ne.p=i!==0&&8>i?i:8;var o=ie.T,l={};ie.T=l,Tb(e,!1,t,n);try{var s=a(),u=ie.S;if(u!==null&&u(l,s),s!==null&&typeof s=="object"&&typeof s.then=="function"){var d=E4(s,r);yu(e,t,d,Mn(e))}else yu(e,t,r,Mn(e))}catch(f){yu(e,t,{then:function(){},status:"rejected",reason:f},Mn())}finally{Ne.p=i,o!==null&&l.types!==null&&(o.types=l.types),ie.T=o}}function R4(){}function xv(e,t,n,r){if(e.tag!==5)throw Error(U(476));var a=S_(e).queue;x_(e,a,t,Fi,n===null?R4:function(){return w_(e),n(r)})}function S_(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:Fi,baseState:Fi,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:sa,lastRenderedState:Fi},next:null};var n={};return t.next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:sa,lastRenderedState:n},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function w_(e){var t=S_(e);t.next===null&&(t=e.alternate.memoizedState),yu(e,t.next.queue,{},Mn())}function _b(){return Ut(Bu)}function j_(){return ft().memoizedState}function O_(){return ft().memoizedState}function P4(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var n=Mn();e=Va(n);var r=Xa(t,e,n);r!==null&&(hn(r,t,n),hu(r,t,n)),t={cache:db()},e.payload=t;return}t=t.return}}function $4(e,t,n){var r=Mn();n={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},up(e)?E_(t,n):(n=sb(e,t,n,r),n!==null&&(hn(n,e,r),__(n,t,r)))}function A_(e,t,n){var r=Mn();yu(e,t,n,r)}function yu(e,t,n,r){var a={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(up(e))E_(t,a);else{var i=e.alternate;if(e.lanes===0&&(i===null||i.lanes===0)&&(i=t.lastRenderedReducer,i!==null))try{var o=t.lastRenderedState,l=i(o,n);if(a.hasEagerState=!0,a.eagerState=l,Pn(l,o))return ap(e,t,a,0),Fe===null&&rp(),!1}catch{}finally{}if(n=sb(e,t,a,r),n!==null)return hn(n,e,r),__(n,t,r),!0}return!1}function Tb(e,t,n,r){if(r={lane:2,revertLane:Lb(),gesture:null,action:r,hasEagerState:!1,eagerState:null,next:null},up(e)){if(t)throw Error(U(479))}else t=sb(e,n,r,2),t!==null&&hn(t,e,2)}function up(e){var t=e.alternate;return e===de||t!==null&&t===de}function E_(e,t){al=Ad=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function __(e,t,n){if(n&4194048){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,dE(e,n)}}var Du={readContext:Ut,use:lp,useCallback:ot,useContext:ot,useEffect:ot,useImperativeHandle:ot,useLayoutEffect:ot,useInsertionEffect:ot,useMemo:ot,useReducer:ot,useRef:ot,useState:ot,useDebugValue:ot,useDeferredValue:ot,useTransition:ot,useSyncExternalStore:ot,useId:ot,useHostTransitionStatus:ot,useFormState:ot,useActionState:ot,useOptimistic:ot,useMemoCache:ot,useCacheRefresh:ot};Du.useEffectEvent=ot;var T_={readContext:Ut,use:lp,useCallback:function(e,t){return Qt().memoizedState=[e,t===void 0?null:t],e},useContext:Ut,useEffect:sS,useImperativeHandle:function(e,t,n){n=n!=null?n.concat([e]):null,Wf(4194308,4,m_.bind(null,t,e),n)},useLayoutEffect:function(e,t){return Wf(4194308,4,e,t)},useInsertionEffect:function(e,t){Wf(4,2,e,t)},useMemo:function(e,t){var n=Qt();t=t===void 0?null:t;var r=e();if(to){Ia(!0);try{e()}finally{Ia(!1)}}return n.memoizedState=[r,t],r},useReducer:function(e,t,n){var r=Qt();if(n!==void 0){var a=n(t);if(to){Ia(!0);try{n(t)}finally{Ia(!1)}}}else a=t;return r.memoizedState=r.baseState=a,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:a},r.queue=e,e=e.dispatch=$4.bind(null,de,e),[r.memoizedState,e]},useRef:function(e){var t=Qt();return e={current:e},t.memoizedState=e},useState:function(e){e=gv(e);var t=e.queue,n=A_.bind(null,de,t);return t.dispatch=n,[e.memoizedState,n]},useDebugValue:Ab,useDeferredValue:function(e,t){var n=Qt();return Eb(n,e,t)},useTransition:function(){var e=gv(!1);return e=x_.bind(null,de,e.queue,!0,!1),Qt().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,n){var r=de,a=Qt();if(Ae){if(n===void 0)throw Error(U(407));n=n()}else{if(n=t(),Fe===null)throw Error(U(349));we&127||t_(r,t,n)}a.memoizedState=n;var i={value:n,getSnapshot:t};return a.queue=i,sS(r_.bind(null,r,i,e),[e]),r.flags|=2048,Tl(9,{destroy:void 0},n_.bind(null,r,i,n,t),null),n},useId:function(){var e=Qt(),t=Fe.identifierPrefix;if(Ae){var n=Sr,r=xr;n=(r&~(1<<32-Cn(r)-1)).toString(32)+n,t="_"+t+"R_"+n,n=Ed++,0<n&&(t+="H"+n.toString(32)),t+="_"}else n=_4++,t="_"+t+"r_"+n.toString(32)+"_";return e.memoizedState=t},useHostTransitionStatus:_b,useFormState:iS,useActionState:iS,useOptimistic:function(e){var t=Qt();t.memoizedState=t.baseState=e;var n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=n,t=Tb.bind(null,de,!0,n),n.dispatch=t,[e,t]},useMemoCache:wb,useCacheRefresh:function(){return Qt().memoizedState=P4.bind(null,de)},useEffectEvent:function(e){var t=Qt(),n={impl:e};return t.memoizedState=n,function(){if(Te&2)throw Error(U(440));return n.impl.apply(void 0,arguments)}}},Nb={readContext:Ut,use:lp,useCallback:v_,useContext:Ut,useEffect:Ob,useImperativeHandle:y_,useInsertionEffect:h_,useLayoutEffect:p_,useMemo:g_,useReducer:Qf,useRef:f_,useState:function(){return Qf(sa)},useDebugValue:Ab,useDeferredValue:function(e,t){var n=ft();return b_(n,Ue.memoizedState,e,t)},useTransition:function(){var e=Qf(sa)[0],t=ft().memoizedState;return[typeof e=="boolean"?e:Ic(e),t]},useSyncExternalStore:e_,useId:j_,useHostTransitionStatus:_b,useFormState:oS,useActionState:oS,useOptimistic:function(e,t){var n=ft();return o_(n,Ue,e,t)},useMemoCache:wb,useCacheRefresh:O_};Nb.useEffectEvent=d_;var N_={readContext:Ut,use:lp,useCallback:v_,useContext:Ut,useEffect:Ob,useImperativeHandle:y_,useInsertionEffect:h_,useLayoutEffect:p_,useMemo:g_,useReducer:zm,useRef:f_,useState:function(){return zm(sa)},useDebugValue:Ab,useDeferredValue:function(e,t){var n=ft();return Ue===null?Eb(n,e,t):b_(n,Ue.memoizedState,e,t)},useTransition:function(){var e=zm(sa)[0],t=ft().memoizedState;return[typeof e=="boolean"?e:Ic(e),t]},useSyncExternalStore:e_,useId:j_,useHostTransitionStatus:_b,useFormState:lS,useActionState:lS,useOptimistic:function(e,t){var n=ft();return Ue!==null?o_(n,Ue,e,t):(n.baseState=e,[e,n.queue.dispatch])},useMemoCache:wb,useCacheRefresh:O_};N_.useEffectEvent=d_;function Bm(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:nt({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var Sv={enqueueSetState:function(e,t,n){e=e._reactInternals;var r=Mn(),a=Va(r);a.payload=t,n!=null&&(a.callback=n),t=Xa(e,a,r),t!==null&&(hn(t,e,r),hu(t,e,r))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=Mn(),a=Va(r);a.tag=1,a.payload=t,n!=null&&(a.callback=n),t=Xa(e,a,r),t!==null&&(hn(t,e,r),hu(t,e,r))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=Mn(),r=Va(n);r.tag=2,t!=null&&(r.callback=t),t=Xa(e,r,n),t!==null&&(hn(t,e,n),hu(t,e,n))}};function uS(e,t,n,r,a,i,o){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(r,i,o):t.prototype&&t.prototype.isPureReactComponent?!Mu(n,r)||!Mu(a,i):!0}function cS(e,t,n,r){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(n,r),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&Sv.enqueueReplaceState(t,t.state,null)}function no(e,t){var n=t;if("ref"in t){n={};for(var r in t)r!=="ref"&&(n[r]=t[r])}if(e=e.defaultProps){n===t&&(n=nt({},n));for(var a in e)n[a]===void 0&&(n[a]=e[a])}return n}function C_(e){gd(e)}function M_(e){console.error(e)}function R_(e){gd(e)}function _d(e,t){try{var n=e.onUncaughtError;n(t.value,{componentStack:t.stack})}catch(r){setTimeout(function(){throw r})}}function fS(e,t,n){try{var r=e.onCaughtError;r(n.value,{componentStack:n.stack,errorBoundary:t.tag===1?t.stateNode:null})}catch(a){setTimeout(function(){throw a})}}function wv(e,t,n){return n=Va(n),n.tag=3,n.payload={element:null},n.callback=function(){_d(e,t)},n}function P_(e){return e=Va(e),e.tag=3,e}function $_(e,t,n,r){var a=n.type.getDerivedStateFromError;if(typeof a=="function"){var i=r.value;e.payload=function(){return a(i)},e.callback=function(){fS(t,n,r)}}var o=n.stateNode;o!==null&&typeof o.componentDidCatch=="function"&&(e.callback=function(){fS(t,n,r),typeof a!="function"&&(Qa===null?Qa=new Set([this]):Qa.add(this));var l=r.stack;this.componentDidCatch(r.value,{componentStack:l!==null?l:""})})}function k4(e,t,n,r,a){if(n.flags|=32768,r!==null&&typeof r=="object"&&typeof r.then=="function"){if(t=n.alternate,t!==null&&fs(t,n,a,!0),n=$n.current,n!==null){switch(n.tag){case 31:case 13:return Xn===null?Rd():n.alternate===null&&ut===0&&(ut=3),n.flags&=-257,n.flags|=65536,n.lanes=a,r===wd?n.flags|=16384:(t=n.updateQueue,t===null?n.updateQueue=new Set([r]):t.add(r),Qm(e,r,a)),!1;case 22:return n.flags|=65536,r===wd?n.flags|=16384:(t=n.updateQueue,t===null?(t={transitions:null,markerInstances:null,retryQueue:new Set([r])},n.updateQueue=t):(n=t.retryQueue,n===null?t.retryQueue=new Set([r]):n.add(r)),Qm(e,r,a)),!1}throw Error(U(435,n.tag))}return Qm(e,r,a),Rd(),!1}if(Ae)return t=$n.current,t!==null?(!(t.flags&65536)&&(t.flags|=256),t.flags|=65536,t.lanes=a,r!==uv&&(e=Error(U(422),{cause:r}),Pu(Gn(e,n)))):(r!==uv&&(t=Error(U(423),{cause:r}),Pu(Gn(t,n))),e=e.current.alternate,e.flags|=65536,a&=-a,e.lanes|=a,r=Gn(r,n),a=wv(e.stateNode,r,a),Lm(e,a),ut!==4&&(ut=2)),!1;var i=Error(U(520),{cause:r});if(i=Gn(i,n),bu===null?bu=[i]:bu.push(i),ut!==4&&(ut=2),t===null)return!0;r=Gn(r,n),n=t;do{switch(n.tag){case 3:return n.flags|=65536,e=a&-a,n.lanes|=e,e=wv(n.stateNode,r,e),Lm(n,e),!1;case 1:if(t=n.type,i=n.stateNode,(n.flags&128)===0&&(typeof t.getDerivedStateFromError=="function"||i!==null&&typeof i.componentDidCatch=="function"&&(Qa===null||!Qa.has(i))))return n.flags|=65536,a&=-a,n.lanes|=a,a=P_(a),$_(a,e,n,r),Lm(n,a),!1}n=n.return}while(n!==null);return!1}var Cb=Error(U(461)),vt=!1;function Lt(e,t,n,r){t.child=e===null?VE(t,null,n,r):eo(t,e.child,n,r)}function dS(e,t,n,r,a){n=n.render;var i=t.ref;if("ref"in r){var o={};for(var l in r)l!=="ref"&&(o[l]=r[l])}else o=r;return Ji(t),r=gb(e,t,n,o,i,a),l=bb(),e!==null&&!vt?(xb(e,t,a),ua(e,t,a)):(Ae&&l&&cb(t),t.flags|=1,Lt(e,t,r,a),t.child)}function hS(e,t,n,r,a){if(e===null){var i=n.type;return typeof i=="function"&&!ub(i)&&i.defaultProps===void 0&&n.compare===null?(t.tag=15,t.type=i,k_(e,t,i,r,a)):(e=Vf(n.type,null,r,t,t.mode,a),e.ref=t.ref,e.return=t,t.child=e)}if(i=e.child,!Mb(e,a)){var o=i.memoizedProps;if(n=n.compare,n=n!==null?n:Mu,n(o,r)&&e.ref===t.ref)return ua(e,t,a)}return t.flags|=1,e=Jr(i,r),e.ref=t.ref,e.return=t,t.child=e}function k_(e,t,n,r,a){if(e!==null){var i=e.memoizedProps;if(Mu(i,r)&&e.ref===t.ref)if(vt=!1,t.pendingProps=r=i,Mb(e,a))e.flags&131072&&(vt=!0);else return t.lanes=e.lanes,ua(e,t,a)}return jv(e,t,n,r,a)}function D_(e,t,n,r){var a=r.children,i=e!==null?e.memoizedState:null;if(e===null&&t.stateNode===null&&(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),r.mode==="hidden"){if(t.flags&128){if(i=i!==null?i.baseLanes|n:n,e!==null){for(r=t.child=e.child,a=0;r!==null;)a=a|r.lanes|r.childLanes,r=r.sibling;r=a&~i}else r=0,t.child=null;return pS(e,t,i,n,r)}if(n&536870912)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&Xf(t,i!==null?i.cachePool:null),i!==null?nS(t,i):yv(),WE(t);else return r=t.lanes=536870912,pS(e,t,i!==null?i.baseLanes|n:n,n,r)}else i!==null?(Xf(t,i.cachePool),nS(t,i),Na(),t.memoizedState=null):(e!==null&&Xf(t,null),yv(),Na());return Lt(e,t,a,n),t.child}function au(e,t){return e!==null&&e.tag===22||t.stateNode!==null||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function pS(e,t,n,r,a){var i=hb();return i=i===null?null:{parent:yt._currentValue,pool:i},t.memoizedState={baseLanes:n,cachePool:i},e!==null&&Xf(t,null),yv(),WE(t),e!==null&&fs(e,t,r,!0),t.childLanes=a,null}function Zf(e,t){return t=Td({mode:t.mode,children:t.children},e.mode),t.ref=e.ref,e.child=t,t.return=e,t}function mS(e,t,n){return eo(t,e.child,null,n),e=Zf(t,t.pendingProps),e.flags|=2,On(t),t.memoizedState=null,e}function D4(e,t,n){var r=t.pendingProps,a=(t.flags&128)!==0;if(t.flags&=-129,e===null){if(Ae){if(r.mode==="hidden")return e=Zf(t,r),t.lanes=536870912,au(null,e);if(vv(t),(e=Je)?(e=TT(e,Kn),e=e!==null&&e.data==="&"?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:ai!==null?{id:xr,overflow:Sr}:null,retryLane:536870912,hydrationErrors:null},n=UE(e),n.return=t,t.child=n,Bt=t,Je=null)):e=null,e===null)throw ii(t);return t.lanes=536870912,null}return Zf(t,r)}var i=e.memoizedState;if(i!==null){var o=i.dehydrated;if(vv(t),a)if(t.flags&256)t.flags&=-257,t=mS(e,t,n);else if(t.memoizedState!==null)t.child=e.child,t.flags|=128,t=null;else throw Error(U(558));else if(vt||fs(e,t,n,!1),a=(n&e.childLanes)!==0,vt||a){if(r=Fe,r!==null&&(o=hE(r,n),o!==0&&o!==i.retryLane))throw i.retryLane=o,mo(e,o),hn(r,e,o),Cb;Rd(),t=mS(e,t,n)}else e=i.treeContext,Je=Qn(o.nextSibling),Bt=t,Ae=!0,Ya=null,Kn=!1,e!==null&&HE(t,e),t=Zf(t,r),t.flags|=4096;return t}return e=Jr(e.child,{mode:r.mode,children:r.children}),e.ref=t.ref,t.child=e,e.return=t,e}function Jf(e,t){var n=t.ref;if(n===null)e!==null&&e.ref!==null&&(t.flags|=4194816);else{if(typeof n!="function"&&typeof n!="object")throw Error(U(284));(e===null||e.ref!==n)&&(t.flags|=4194816)}}function jv(e,t,n,r,a){return Ji(t),n=gb(e,t,n,r,void 0,a),r=bb(),e!==null&&!vt?(xb(e,t,a),ua(e,t,a)):(Ae&&r&&cb(t),t.flags|=1,Lt(e,t,n,a),t.child)}function yS(e,t,n,r,a,i){return Ji(t),t.updateQueue=null,n=JE(t,r,n,a),ZE(e),r=bb(),e!==null&&!vt?(xb(e,t,i),ua(e,t,i)):(Ae&&r&&cb(t),t.flags|=1,Lt(e,t,n,i),t.child)}function vS(e,t,n,r,a){if(Ji(t),t.stateNode===null){var i=Ho,o=n.contextType;typeof o=="object"&&o!==null&&(i=Ut(o)),i=new n(r,i),t.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,i.updater=Sv,t.stateNode=i,i._reactInternals=t,i=t.stateNode,i.props=r,i.state=t.memoizedState,i.refs={},mb(t),o=n.contextType,i.context=typeof o=="object"&&o!==null?Ut(o):Ho,i.state=t.memoizedState,o=n.getDerivedStateFromProps,typeof o=="function"&&(Bm(t,n,o,r),i.state=t.memoizedState),typeof n.getDerivedStateFromProps=="function"||typeof i.getSnapshotBeforeUpdate=="function"||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(o=i.state,typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount(),o!==i.state&&Sv.enqueueReplaceState(i,i.state,null),mu(t,r,i,a),pu(),i.state=t.memoizedState),typeof i.componentDidMount=="function"&&(t.flags|=4194308),r=!0}else if(e===null){i=t.stateNode;var l=t.memoizedProps,s=no(n,l);i.props=s;var u=i.context,d=n.contextType;o=Ho,typeof d=="object"&&d!==null&&(o=Ut(d));var f=n.getDerivedStateFromProps;d=typeof f=="function"||typeof i.getSnapshotBeforeUpdate=="function",l=t.pendingProps!==l,d||typeof i.UNSAFE_componentWillReceiveProps!="function"&&typeof i.componentWillReceiveProps!="function"||(l||u!==o)&&cS(t,i,r,o),Oa=!1;var h=t.memoizedState;i.state=h,mu(t,r,i,a),pu(),u=t.memoizedState,l||h!==u||Oa?(typeof f=="function"&&(Bm(t,n,f,r),u=t.memoizedState),(s=Oa||uS(t,n,s,r,h,u,o))?(d||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount()),typeof i.componentDidMount=="function"&&(t.flags|=4194308)):(typeof i.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=u),i.props=r,i.state=u,i.context=o,r=s):(typeof i.componentDidMount=="function"&&(t.flags|=4194308),r=!1)}else{i=t.stateNode,pv(e,t),o=t.memoizedProps,d=no(n,o),i.props=d,f=t.pendingProps,h=i.context,u=n.contextType,s=Ho,typeof u=="object"&&u!==null&&(s=Ut(u)),l=n.getDerivedStateFromProps,(u=typeof l=="function"||typeof i.getSnapshotBeforeUpdate=="function")||typeof i.UNSAFE_componentWillReceiveProps!="function"&&typeof i.componentWillReceiveProps!="function"||(o!==f||h!==s)&&cS(t,i,r,s),Oa=!1,h=t.memoizedState,i.state=h,mu(t,r,i,a),pu();var p=t.memoizedState;o!==f||h!==p||Oa||e!==null&&e.dependencies!==null&&Sd(e.dependencies)?(typeof l=="function"&&(Bm(t,n,l,r),p=t.memoizedState),(d=Oa||uS(t,n,d,r,h,p,s)||e!==null&&e.dependencies!==null&&Sd(e.dependencies))?(u||typeof i.UNSAFE_componentWillUpdate!="function"&&typeof i.componentWillUpdate!="function"||(typeof i.componentWillUpdate=="function"&&i.componentWillUpdate(r,p,s),typeof i.UNSAFE_componentWillUpdate=="function"&&i.UNSAFE_componentWillUpdate(r,p,s)),typeof i.componentDidUpdate=="function"&&(t.flags|=4),typeof i.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof i.componentDidUpdate!="function"||o===e.memoizedProps&&h===e.memoizedState||(t.flags|=4),typeof i.getSnapshotBeforeUpdate!="function"||o===e.memoizedProps&&h===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=p),i.props=r,i.state=p,i.context=s,r=d):(typeof i.componentDidUpdate!="function"||o===e.memoizedProps&&h===e.memoizedState||(t.flags|=4),typeof i.getSnapshotBeforeUpdate!="function"||o===e.memoizedProps&&h===e.memoizedState||(t.flags|=1024),r=!1)}return i=r,Jf(e,t),r=(t.flags&128)!==0,i||r?(i=t.stateNode,n=r&&typeof n.getDerivedStateFromError!="function"?null:i.render(),t.flags|=1,e!==null&&r?(t.child=eo(t,e.child,null,a),t.child=eo(t,null,n,a)):Lt(e,t,n,a),t.memoizedState=i.state,e=t.child):e=ua(e,t,a),e}function gS(e,t,n,r){return Zi(),t.flags|=256,Lt(e,t,n,r),t.child}var Im={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function Um(e){return{baseLanes:e,cachePool:GE()}}function qm(e,t,n){return e=e!==null?e.childLanes&~n:0,t&&(e|=_n),e}function L_(e,t,n){var r=t.pendingProps,a=!1,i=(t.flags&128)!==0,o;if((o=i)||(o=e!==null&&e.memoizedState===null?!1:(ct.current&2)!==0),o&&(a=!0,t.flags&=-129),o=(t.flags&32)!==0,t.flags&=-33,e===null){if(Ae){if(a?Ta(t):Na(),(e=Je)?(e=TT(e,Kn),e=e!==null&&e.data!=="&"?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:ai!==null?{id:xr,overflow:Sr}:null,retryLane:536870912,hydrationErrors:null},n=UE(e),n.return=t,t.child=n,Bt=t,Je=null)):e=null,e===null)throw ii(t);return Lv(e)?t.lanes=32:t.lanes=536870912,null}var l=r.children;return r=r.fallback,a?(Na(),a=t.mode,l=Td({mode:"hidden",children:l},a),r=Gi(r,a,n,null),l.return=t,r.return=t,l.sibling=r,t.child=l,r=t.child,r.memoizedState=Um(n),r.childLanes=qm(e,o,n),t.memoizedState=Im,au(null,r)):(Ta(t),Ov(t,l))}var s=e.memoizedState;if(s!==null&&(l=s.dehydrated,l!==null)){if(i)t.flags&256?(Ta(t),t.flags&=-257,t=Hm(e,t,n)):t.memoizedState!==null?(Na(),t.child=e.child,t.flags|=128,t=null):(Na(),l=r.fallback,a=t.mode,r=Td({mode:"visible",children:r.children},a),l=Gi(l,a,n,null),l.flags|=2,r.return=t,l.return=t,r.sibling=l,t.child=r,eo(t,e.child,null,n),r=t.child,r.memoizedState=Um(n),r.childLanes=qm(e,o,n),t.memoizedState=Im,t=au(null,r));else if(Ta(t),Lv(l)){if(o=l.nextSibling&&l.nextSibling.dataset,o)var u=o.dgst;o=u,r=Error(U(419)),r.stack="",r.digest=o,Pu({value:r,source:null,stack:null}),t=Hm(e,t,n)}else if(vt||fs(e,t,n,!1),o=(n&e.childLanes)!==0,vt||o){if(o=Fe,o!==null&&(r=hE(o,n),r!==0&&r!==s.retryLane))throw s.retryLane=r,mo(e,r),hn(o,e,r),Cb;Dv(l)||Rd(),t=Hm(e,t,n)}else Dv(l)?(t.flags|=192,t.child=e.child,t=null):(e=s.treeContext,Je=Qn(l.nextSibling),Bt=t,Ae=!0,Ya=null,Kn=!1,e!==null&&HE(t,e),t=Ov(t,r.children),t.flags|=4096);return t}return a?(Na(),l=r.fallback,a=t.mode,s=e.child,u=s.sibling,r=Jr(s,{mode:"hidden",children:r.children}),r.subtreeFlags=s.subtreeFlags&65011712,u!==null?l=Jr(u,l):(l=Gi(l,a,n,null),l.flags|=2),l.return=t,r.return=t,r.sibling=l,t.child=r,au(null,r),r=t.child,l=e.child.memoizedState,l===null?l=Um(n):(a=l.cachePool,a!==null?(s=yt._currentValue,a=a.parent!==s?{parent:s,pool:s}:a):a=GE(),l={baseLanes:l.baseLanes|n,cachePool:a}),r.memoizedState=l,r.childLanes=qm(e,o,n),t.memoizedState=Im,au(e.child,r)):(Ta(t),n=e.child,e=n.sibling,n=Jr(n,{mode:"visible",children:r.children}),n.return=t,n.sibling=null,e!==null&&(o=t.deletions,o===null?(t.deletions=[e],t.flags|=16):o.push(e)),t.child=n,t.memoizedState=null,n)}function Ov(e,t){return t=Td({mode:"visible",children:t},e.mode),t.return=e,e.child=t}function Td(e,t){return e=An(22,e,null,t),e.lanes=0,e}function Hm(e,t,n){return eo(t,e.child,null,n),e=Ov(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function bS(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),fv(e.return,t,n)}function Fm(e,t,n,r,a,i){var o=e.memoizedState;o===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:a,treeForkCount:i}:(o.isBackwards=t,o.rendering=null,o.renderingStartTime=0,o.last=r,o.tail=n,o.tailMode=a,o.treeForkCount=i)}function z_(e,t,n){var r=t.pendingProps,a=r.revealOrder,i=r.tail;r=r.children;var o=ct.current,l=(o&2)!==0;if(l?(o=o&1|2,t.flags|=128):o&=1,Ye(ct,o),Lt(e,t,r,n),r=Ae?Ru:0,!l&&e!==null&&e.flags&128)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&bS(e,n,t);else if(e.tag===19)bS(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}switch(a){case"forwards":for(n=t.child,a=null;n!==null;)e=n.alternate,e!==null&&Od(e)===null&&(a=n),n=n.sibling;n=a,n===null?(a=t.child,t.child=null):(a=n.sibling,n.sibling=null),Fm(t,!1,a,n,i,r);break;case"backwards":case"unstable_legacy-backwards":for(n=null,a=t.child,t.child=null;a!==null;){if(e=a.alternate,e!==null&&Od(e)===null){t.child=a;break}e=a.sibling,a.sibling=n,n=a,a=e}Fm(t,!0,n,null,i,r);break;case"together":Fm(t,!1,null,null,void 0,r);break;default:t.memoizedState=null}return t.child}function ua(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),li|=t.lanes,!(n&t.childLanes))if(e!==null){if(fs(e,t,n,!1),(n&t.childLanes)===0)return null}else return null;if(e!==null&&t.child!==e.child)throw Error(U(153));if(t.child!==null){for(e=t.child,n=Jr(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=Jr(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function Mb(e,t){return e.lanes&t?!0:(e=e.dependencies,!!(e!==null&&Sd(e)))}function L4(e,t,n){switch(t.tag){case 3:pd(t,t.stateNode.containerInfo),_a(t,yt,e.memoizedState.cache),Zi();break;case 27:case 5:Zy(t);break;case 4:pd(t,t.stateNode.containerInfo);break;case 10:_a(t,t.type,t.memoizedProps.value);break;case 31:if(t.memoizedState!==null)return t.flags|=128,vv(t),null;break;case 13:var r=t.memoizedState;if(r!==null)return r.dehydrated!==null?(Ta(t),t.flags|=128,null):n&t.child.childLanes?L_(e,t,n):(Ta(t),e=ua(e,t,n),e!==null?e.sibling:null);Ta(t);break;case 19:var a=(e.flags&128)!==0;if(r=(n&t.childLanes)!==0,r||(fs(e,t,n,!1),r=(n&t.childLanes)!==0),a){if(r)return z_(e,t,n);t.flags|=128}if(a=t.memoizedState,a!==null&&(a.rendering=null,a.tail=null,a.lastEffect=null),Ye(ct,ct.current),r)break;return null;case 22:return t.lanes=0,D_(e,t,n,t.pendingProps);case 24:_a(t,yt,e.memoizedState.cache)}return ua(e,t,n)}function B_(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps)vt=!0;else{if(!Mb(e,n)&&!(t.flags&128))return vt=!1,L4(e,t,n);vt=!!(e.flags&131072)}else vt=!1,Ae&&t.flags&1048576&&qE(t,Ru,t.index);switch(t.lanes=0,t.tag){case 16:e:{var r=t.pendingProps;if(e=ji(t.elementType),t.type=e,typeof e=="function")ub(e)?(r=no(e,r),t.tag=1,t=vS(null,t,e,r,n)):(t.tag=0,t=jv(null,t,e,r,n));else{if(e!=null){var a=e.$$typeof;if(a===X0){t.tag=11,t=dS(null,t,e,r,n);break e}else if(a===Q0){t.tag=14,t=hS(null,t,e,r,n);break e}}throw t=Qy(e)||e,Error(U(306,t,""))}}return t;case 0:return jv(e,t,t.type,t.pendingProps,n);case 1:return r=t.type,a=no(r,t.pendingProps),vS(e,t,r,a,n);case 3:e:{if(pd(t,t.stateNode.containerInfo),e===null)throw Error(U(387));r=t.pendingProps;var i=t.memoizedState;a=i.element,pv(e,t),mu(t,r,null,n);var o=t.memoizedState;if(r=o.cache,_a(t,yt,r),r!==i.cache&&dv(t,[yt],n,!0),pu(),r=o.element,i.isDehydrated)if(i={element:r,isDehydrated:!1,cache:o.cache},t.updateQueue.baseState=i,t.memoizedState=i,t.flags&256){t=gS(e,t,r,n);break e}else if(r!==a){a=Gn(Error(U(424)),t),Pu(a),t=gS(e,t,r,n);break e}else{switch(e=t.stateNode.containerInfo,e.nodeType){case 9:e=e.body;break;default:e=e.nodeName==="HTML"?e.ownerDocument.body:e}for(Je=Qn(e.firstChild),Bt=t,Ae=!0,Ya=null,Kn=!0,n=VE(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling}else{if(Zi(),r===a){t=ua(e,t,n);break e}Lt(e,t,r,n)}t=t.child}return t;case 26:return Jf(e,t),e===null?(n=BS(t.type,null,t.pendingProps,null))?t.memoizedState=n:Ae||(n=t.type,e=t.pendingProps,r=Dd(Ka.current).createElement(n),r[zt]=t,r[mn]=e,qt(r,n,e),Ct(r),t.stateNode=r):t.memoizedState=BS(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return Zy(t),e===null&&Ae&&(r=t.stateNode=NT(t.type,t.pendingProps,Ka.current),Bt=t,Kn=!0,a=Je,ui(t.type)?(zv=a,Je=Qn(r.firstChild)):Je=a),Lt(e,t,t.pendingProps.children,n),Jf(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&Ae&&((a=r=Je)&&(r=h$(r,t.type,t.pendingProps,Kn),r!==null?(t.stateNode=r,Bt=t,Je=Qn(r.firstChild),Kn=!1,a=!0):a=!1),a||ii(t)),Zy(t),a=t.type,i=t.pendingProps,o=e!==null?e.memoizedProps:null,r=i.children,$v(a,i)?r=null:o!==null&&$v(a,o)&&(t.flags|=32),t.memoizedState!==null&&(a=gb(e,t,T4,null,null,n),Bu._currentValue=a),Jf(e,t),Lt(e,t,r,n),t.child;case 6:return e===null&&Ae&&((e=n=Je)&&(n=p$(n,t.pendingProps,Kn),n!==null?(t.stateNode=n,Bt=t,Je=null,e=!0):e=!1),e||ii(t)),null;case 13:return L_(e,t,n);case 4:return pd(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=eo(t,null,r,n):Lt(e,t,r,n),t.child;case 11:return dS(e,t,t.type,t.pendingProps,n);case 7:return Lt(e,t,t.pendingProps,n),t.child;case 8:return Lt(e,t,t.pendingProps.children,n),t.child;case 12:return Lt(e,t,t.pendingProps.children,n),t.child;case 10:return r=t.pendingProps,_a(t,t.type,r.value),Lt(e,t,r.children,n),t.child;case 9:return a=t.type._context,r=t.pendingProps.children,Ji(t),a=Ut(a),r=r(a),t.flags|=1,Lt(e,t,r,n),t.child;case 14:return hS(e,t,t.type,t.pendingProps,n);case 15:return k_(e,t,t.type,t.pendingProps,n);case 19:return z_(e,t,n);case 31:return D4(e,t,n);case 22:return D_(e,t,n,t.pendingProps);case 24:return Ji(t),r=Ut(yt),e===null?(a=hb(),a===null&&(a=Fe,i=db(),a.pooledCache=i,i.refCount++,i!==null&&(a.pooledCacheLanes|=n),a=i),t.memoizedState={parent:r,cache:a},mb(t),_a(t,yt,a)):(e.lanes&n&&(pv(e,t),mu(t,null,null,n),pu()),a=e.memoizedState,i=t.memoizedState,a.parent!==r?(a={parent:r,cache:r},t.memoizedState=a,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=a),_a(t,yt,r)):(r=i.cache,_a(t,yt,r),r!==a.cache&&dv(t,[yt],n,!0))),Lt(e,t,t.pendingProps.children,n),t.child;case 29:throw t.pendingProps}throw Error(U(156,t.tag))}function kr(e){e.flags|=4}function Gm(e,t,n,r,a){if((t=(e.mode&32)!==0)&&(t=!1),t){if(e.flags|=16777216,(a&335544128)===a)if(e.stateNode.complete)e.flags|=8192;else if(uT())e.flags|=8192;else throw Yi=wd,pb}else e.flags&=-16777217}function xS(e,t){if(t.type!=="stylesheet"||t.state.loading&4)e.flags&=-16777217;else if(e.flags|=16777216,!RT(t))if(uT())e.flags|=8192;else throw Yi=wd,pb}function xf(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag!==22?cE():536870912,e.lanes|=t,Nl|=t)}function Is(e,t){if(!Ae)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function Qe(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var a=e.child;a!==null;)n|=a.lanes|a.childLanes,r|=a.subtreeFlags&65011712,r|=a.flags&65011712,a.return=e,a=a.sibling;else for(a=e.child;a!==null;)n|=a.lanes|a.childLanes,r|=a.subtreeFlags,r|=a.flags,a.return=e,a=a.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function z4(e,t,n){var r=t.pendingProps;switch(fb(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Qe(t),null;case 1:return Qe(t),null;case 3:return n=t.stateNode,r=null,e!==null&&(r=e.memoizedState.cache),t.memoizedState.cache!==r&&(t.flags|=2048),ea(yt),jl(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),(e===null||e.child===null)&&(Ao(t)?kr(t):e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Dm())),Qe(t),null;case 26:var a=t.type,i=t.memoizedState;return e===null?(kr(t),i!==null?(Qe(t),xS(t,i)):(Qe(t),Gm(t,a,null,r,n))):i?i!==e.memoizedState?(kr(t),Qe(t),xS(t,i)):(Qe(t),t.flags&=-16777217):(e=e.memoizedProps,e!==r&&kr(t),Qe(t),Gm(t,a,e,r,n)),null;case 27:if(md(t),n=Ka.current,a=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&kr(t);else{if(!r){if(t.stateNode===null)throw Error(U(166));return Qe(t),null}e=Or.current,Ao(t)?X1(t):(e=NT(a,r,n),t.stateNode=e,kr(t))}return Qe(t),null;case 5:if(md(t),a=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&kr(t);else{if(!r){if(t.stateNode===null)throw Error(U(166));return Qe(t),null}if(i=Or.current,Ao(t))X1(t);else{var o=Dd(Ka.current);switch(i){case 1:i=o.createElementNS("http://www.w3.org/2000/svg",a);break;case 2:i=o.createElementNS("http://www.w3.org/1998/Math/MathML",a);break;default:switch(a){case"svg":i=o.createElementNS("http://www.w3.org/2000/svg",a);break;case"math":i=o.createElementNS("http://www.w3.org/1998/Math/MathML",a);break;case"script":i=o.createElement("div"),i.innerHTML="<script><\/script>",i=i.removeChild(i.firstChild);break;case"select":i=typeof r.is=="string"?o.createElement("select",{is:r.is}):o.createElement("select"),r.multiple?i.multiple=!0:r.size&&(i.size=r.size);break;default:i=typeof r.is=="string"?o.createElement(a,{is:r.is}):o.createElement(a)}}i[zt]=t,i[mn]=r;e:for(o=t.child;o!==null;){if(o.tag===5||o.tag===6)i.appendChild(o.stateNode);else if(o.tag!==4&&o.tag!==27&&o.child!==null){o.child.return=o,o=o.child;continue}if(o===t)break e;for(;o.sibling===null;){if(o.return===null||o.return===t)break e;o=o.return}o.sibling.return=o.return,o=o.sibling}t.stateNode=i;e:switch(qt(i,a,r),a){case"button":case"input":case"select":case"textarea":r=!!r.autoFocus;break e;case"img":r=!0;break e;default:r=!1}r&&kr(t)}}return Qe(t),Gm(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,n),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==r&&kr(t);else{if(typeof r!="string"&&t.stateNode===null)throw Error(U(166));if(e=Ka.current,Ao(t)){if(e=t.stateNode,n=t.memoizedProps,r=null,a=Bt,a!==null)switch(a.tag){case 27:case 5:r=a.memoizedProps}e[zt]=t,e=!!(e.nodeValue===n||r!==null&&r.suppressHydrationWarning===!0||AT(e.nodeValue,n)),e||ii(t,!0)}else e=Dd(e).createTextNode(r),e[zt]=t,t.stateNode=e}return Qe(t),null;case 31:if(n=t.memoizedState,e===null||e.memoizedState!==null){if(r=Ao(t),n!==null){if(e===null){if(!r)throw Error(U(318));if(e=t.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(U(557));e[zt]=t}else Zi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Qe(t),e=!1}else n=Dm(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=n),e=!0;if(!e)return t.flags&256?(On(t),t):(On(t),null);if(t.flags&128)throw Error(U(558))}return Qe(t),null;case 13:if(r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(a=Ao(t),r!==null&&r.dehydrated!==null){if(e===null){if(!a)throw Error(U(318));if(a=t.memoizedState,a=a!==null?a.dehydrated:null,!a)throw Error(U(317));a[zt]=t}else Zi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Qe(t),a=!1}else a=Dm(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=a),a=!0;if(!a)return t.flags&256?(On(t),t):(On(t),null)}return On(t),t.flags&128?(t.lanes=n,t):(n=r!==null,e=e!==null&&e.memoizedState!==null,n&&(r=t.child,a=null,r.alternate!==null&&r.alternate.memoizedState!==null&&r.alternate.memoizedState.cachePool!==null&&(a=r.alternate.memoizedState.cachePool.pool),i=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(i=r.memoizedState.cachePool.pool),i!==a&&(r.flags|=2048)),n!==e&&n&&(t.child.flags|=8192),xf(t,t.updateQueue),Qe(t),null);case 4:return jl(),e===null&&zb(t.stateNode.containerInfo),Qe(t),null;case 10:return ea(t.type),Qe(t),null;case 19:if(Rt(ct),r=t.memoizedState,r===null)return Qe(t),null;if(a=(t.flags&128)!==0,i=r.rendering,i===null)if(a)Is(r,!1);else{if(ut!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(i=Od(e),i!==null){for(t.flags|=128,Is(r,!1),e=i.updateQueue,t.updateQueue=e,xf(t,e),t.subtreeFlags=0,e=n,n=t.child;n!==null;)IE(n,e),n=n.sibling;return Ye(ct,ct.current&1|2),Ae&&qr(t,r.treeForkCount),t.child}e=e.sibling}r.tail!==null&&Tn()>Cd&&(t.flags|=128,a=!0,Is(r,!1),t.lanes=4194304)}else{if(!a)if(e=Od(i),e!==null){if(t.flags|=128,a=!0,e=e.updateQueue,t.updateQueue=e,xf(t,e),Is(r,!0),r.tail===null&&r.tailMode==="hidden"&&!i.alternate&&!Ae)return Qe(t),null}else 2*Tn()-r.renderingStartTime>Cd&&n!==536870912&&(t.flags|=128,a=!0,Is(r,!1),t.lanes=4194304);r.isBackwards?(i.sibling=t.child,t.child=i):(e=r.last,e!==null?e.sibling=i:t.child=i,r.last=i)}return r.tail!==null?(e=r.tail,r.rendering=e,r.tail=e.sibling,r.renderingStartTime=Tn(),e.sibling=null,n=ct.current,Ye(ct,a?n&1|2:n&1),Ae&&qr(t,r.treeForkCount),e):(Qe(t),null);case 22:case 23:return On(t),yb(),r=t.memoizedState!==null,e!==null?e.memoizedState!==null!==r&&(t.flags|=8192):r&&(t.flags|=8192),r?n&536870912&&!(t.flags&128)&&(Qe(t),t.subtreeFlags&6&&(t.flags|=8192)):Qe(t),n=t.updateQueue,n!==null&&xf(t,n.retryQueue),n=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),r=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(r=t.memoizedState.cachePool.pool),r!==n&&(t.flags|=2048),e!==null&&Rt(Ki),null;case 24:return n=null,e!==null&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),ea(yt),Qe(t),null;case 25:return null;case 30:return null}throw Error(U(156,t.tag))}function B4(e,t){switch(fb(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return ea(yt),jl(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return md(t),null;case 31:if(t.memoizedState!==null){if(On(t),t.alternate===null)throw Error(U(340));Zi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(On(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(U(340));Zi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return Rt(ct),null;case 4:return jl(),null;case 10:return ea(t.type),null;case 22:case 23:return On(t),yb(),e!==null&&Rt(Ki),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return ea(yt),null;case 25:return null;default:return null}}function I_(e,t){switch(fb(t),t.tag){case 3:ea(yt),jl();break;case 26:case 27:case 5:md(t);break;case 4:jl();break;case 31:t.memoizedState!==null&&On(t);break;case 13:On(t);break;case 19:Rt(ct);break;case 10:ea(t.type);break;case 22:case 23:On(t),yb(),e!==null&&Rt(Ki);break;case 24:ea(yt)}}function Uc(e,t){try{var n=t.updateQueue,r=n!==null?n.lastEffect:null;if(r!==null){var a=r.next;n=a;do{if((n.tag&e)===e){r=void 0;var i=n.create,o=n.inst;r=i(),o.destroy=r}n=n.next}while(n!==a)}}catch(l){$e(t,t.return,l)}}function oi(e,t,n){try{var r=t.updateQueue,a=r!==null?r.lastEffect:null;if(a!==null){var i=a.next;r=i;do{if((r.tag&e)===e){var o=r.inst,l=o.destroy;if(l!==void 0){o.destroy=void 0,a=t;var s=n,u=l;try{u()}catch(d){$e(a,s,d)}}}r=r.next}while(r!==i)}}catch(d){$e(t,t.return,d)}}function U_(e){var t=e.updateQueue;if(t!==null){var n=e.stateNode;try{QE(t,n)}catch(r){$e(e,e.return,r)}}}function q_(e,t,n){n.props=no(e.type,e.memoizedProps),n.state=e.memoizedState;try{n.componentWillUnmount()}catch(r){$e(e,t,r)}}function vu(e,t){try{var n=e.ref;if(n!==null){switch(e.tag){case 26:case 27:case 5:var r=e.stateNode;break;case 30:r=e.stateNode;break;default:r=e.stateNode}typeof n=="function"?e.refCleanup=n(r):n.current=r}}catch(a){$e(e,t,a)}}function wr(e,t){var n=e.ref,r=e.refCleanup;if(n!==null)if(typeof r=="function")try{r()}catch(a){$e(e,t,a)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof n=="function")try{n(null)}catch(a){$e(e,t,a)}else n.current=null}function H_(e){var t=e.type,n=e.memoizedProps,r=e.stateNode;try{e:switch(t){case"button":case"input":case"select":case"textarea":n.autoFocus&&r.focus();break e;case"img":n.src?r.src=n.src:n.srcSet&&(r.srcset=n.srcSet)}}catch(a){$e(e,e.return,a)}}function Km(e,t,n){try{var r=e.stateNode;l$(r,e.type,n,t),r[mn]=t}catch(a){$e(e,e.return,a)}}function F_(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&ui(e.type)||e.tag===4}function Ym(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||F_(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&ui(e.type)||e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Av(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?(n.nodeType===9?n.body:n.nodeName==="HTML"?n.ownerDocument.body:n).insertBefore(e,t):(t=n.nodeType===9?n.body:n.nodeName==="HTML"?n.ownerDocument.body:n,t.appendChild(e),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=Xr));else if(r!==4&&(r===27&&ui(e.type)&&(n=e.stateNode,t=null),e=e.child,e!==null))for(Av(e,t,n),e=e.sibling;e!==null;)Av(e,t,n),e=e.sibling}function Nd(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(r===27&&ui(e.type)&&(n=e.stateNode),e=e.child,e!==null))for(Nd(e,t,n),e=e.sibling;e!==null;)Nd(e,t,n),e=e.sibling}function G_(e){var t=e.stateNode,n=e.memoizedProps;try{for(var r=e.type,a=t.attributes;a.length;)t.removeAttributeNode(a[0]);qt(t,r,n),t[zt]=e,t[mn]=n}catch(i){$e(e,e.return,i)}}var Yr=!1,mt=!1,Vm=!1,SS=typeof WeakSet=="function"?WeakSet:Set,Nt=null;function I4(e,t){if(e=e.containerInfo,Rv=Id,e=RE(e),ob(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var a=r.anchorOffset,i=r.focusNode;r=r.focusOffset;try{n.nodeType,i.nodeType}catch{n=null;break e}var o=0,l=-1,s=-1,u=0,d=0,f=e,h=null;t:for(;;){for(var p;f!==n||a!==0&&f.nodeType!==3||(l=o+a),f!==i||r!==0&&f.nodeType!==3||(s=o+r),f.nodeType===3&&(o+=f.nodeValue.length),(p=f.firstChild)!==null;)h=f,f=p;for(;;){if(f===e)break t;if(h===n&&++u===a&&(l=o),h===i&&++d===r&&(s=o),(p=f.nextSibling)!==null)break;f=h,h=f.parentNode}f=p}n=l===-1||s===-1?null:{start:l,end:s}}else n=null}n=n||{start:0,end:0}}else n=null;for(Pv={focusedElem:e,selectionRange:n},Id=!1,Nt=t;Nt!==null;)if(t=Nt,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,Nt=e;else for(;Nt!==null;){switch(t=Nt,i=t.alternate,e=t.flags,t.tag){case 0:if(e&4&&(e=t.updateQueue,e=e!==null?e.events:null,e!==null))for(n=0;n<e.length;n++)a=e[n],a.ref.impl=a.nextImpl;break;case 11:case 15:break;case 1:if(e&1024&&i!==null){e=void 0,n=t,a=i.memoizedProps,i=i.memoizedState,r=n.stateNode;try{var b=no(n.type,a);e=r.getSnapshotBeforeUpdate(b,i),r.__reactInternalSnapshotBeforeUpdate=e}catch(v){$e(n,n.return,v)}}break;case 3:if(e&1024){if(e=t.stateNode.containerInfo,n=e.nodeType,n===9)kv(e);else if(n===1)switch(e.nodeName){case"HEAD":case"HTML":case"BODY":kv(e);break;default:e.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if(e&1024)throw Error(U(163))}if(e=t.sibling,e!==null){e.return=t.return,Nt=e;break}Nt=t.return}}function K_(e,t,n){var r=n.flags;switch(n.tag){case 0:case 11:case 15:Lr(e,n),r&4&&Uc(5,n);break;case 1:if(Lr(e,n),r&4)if(e=n.stateNode,t===null)try{e.componentDidMount()}catch(o){$e(n,n.return,o)}else{var a=no(n.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(a,t,e.__reactInternalSnapshotBeforeUpdate)}catch(o){$e(n,n.return,o)}}r&64&&U_(n),r&512&&vu(n,n.return);break;case 3:if(Lr(e,n),r&64&&(e=n.updateQueue,e!==null)){if(t=null,n.child!==null)switch(n.child.tag){case 27:case 5:t=n.child.stateNode;break;case 1:t=n.child.stateNode}try{QE(e,t)}catch(o){$e(n,n.return,o)}}break;case 27:t===null&&r&4&&G_(n);case 26:case 5:Lr(e,n),t===null&&r&4&&H_(n),r&512&&vu(n,n.return);break;case 12:Lr(e,n);break;case 31:Lr(e,n),r&4&&X_(e,n);break;case 13:Lr(e,n),r&4&&Q_(e,n),r&64&&(e=n.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(n=X4.bind(null,n),m$(e,n))));break;case 22:if(r=n.memoizedState!==null||Yr,!r){t=t!==null&&t.memoizedState!==null||mt,a=Yr;var i=mt;Yr=r,(mt=t)&&!i?Br(e,n,(n.subtreeFlags&8772)!==0):Lr(e,n),Yr=a,mt=i}break;case 30:break;default:Lr(e,n)}}function Y_(e){var t=e.alternate;t!==null&&(e.alternate=null,Y_(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&eb(t)),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}var rt=null,cn=!1;function Dr(e,t,n){for(n=n.child;n!==null;)V_(e,t,n),n=n.sibling}function V_(e,t,n){if(Nn&&typeof Nn.onCommitFiberUnmount=="function")try{Nn.onCommitFiberUnmount($c,n)}catch{}switch(n.tag){case 26:mt||wr(n,t),Dr(e,t,n),n.memoizedState?n.memoizedState.count--:n.stateNode&&(n=n.stateNode,n.parentNode.removeChild(n));break;case 27:mt||wr(n,t);var r=rt,a=cn;ui(n.type)&&(rt=n.stateNode,cn=!1),Dr(e,t,n),Su(n.stateNode),rt=r,cn=a;break;case 5:mt||wr(n,t);case 6:if(r=rt,a=cn,rt=null,Dr(e,t,n),rt=r,cn=a,rt!==null)if(cn)try{(rt.nodeType===9?rt.body:rt.nodeName==="HTML"?rt.ownerDocument.body:rt).removeChild(n.stateNode)}catch(i){$e(n,t,i)}else try{rt.removeChild(n.stateNode)}catch(i){$e(n,t,i)}break;case 18:rt!==null&&(cn?(e=rt,$S(e.nodeType===9?e.body:e.nodeName==="HTML"?e.ownerDocument.body:e,n.stateNode),Pl(e)):$S(rt,n.stateNode));break;case 4:r=rt,a=cn,rt=n.stateNode.containerInfo,cn=!0,Dr(e,t,n),rt=r,cn=a;break;case 0:case 11:case 14:case 15:oi(2,n,t),mt||oi(4,n,t),Dr(e,t,n);break;case 1:mt||(wr(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"&&q_(n,t,r)),Dr(e,t,n);break;case 21:Dr(e,t,n);break;case 22:mt=(r=mt)||n.memoizedState!==null,Dr(e,t,n),mt=r;break;default:Dr(e,t,n)}}function X_(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{Pl(e)}catch(n){$e(t,t.return,n)}}}function Q_(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Pl(e)}catch(n){$e(t,t.return,n)}}function U4(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new SS),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new SS),t;default:throw Error(U(435,e.tag))}}function Sf(e,t){var n=U4(e);t.forEach(function(r){if(!n.has(r)){n.add(r);var a=Q4.bind(null,e,r);r.then(a,a)}})}function on(e,t){var n=t.deletions;if(n!==null)for(var r=0;r<n.length;r++){var a=n[r],i=e,o=t,l=o;e:for(;l!==null;){switch(l.tag){case 27:if(ui(l.type)){rt=l.stateNode,cn=!1;break e}break;case 5:rt=l.stateNode,cn=!1;break e;case 3:case 4:rt=l.stateNode.containerInfo,cn=!0;break e}l=l.return}if(rt===null)throw Error(U(160));V_(i,o,a),rt=null,cn=!1,i=a.alternate,i!==null&&(i.return=null),a.return=null}if(t.subtreeFlags&13886)for(t=t.child;t!==null;)W_(t,e),t=t.sibling}var lr=null;function W_(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:on(t,e),ln(e),r&4&&(oi(3,e,e.return),Uc(3,e),oi(5,e,e.return));break;case 1:on(t,e),ln(e),r&512&&(mt||n===null||wr(n,n.return)),r&64&&Yr&&(e=e.updateQueue,e!==null&&(r=e.callbacks,r!==null&&(n=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=n===null?r:n.concat(r))));break;case 26:var a=lr;if(on(t,e),ln(e),r&512&&(mt||n===null||wr(n,n.return)),r&4){var i=n!==null?n.memoizedState:null;if(r=e.memoizedState,n===null)if(r===null)if(e.stateNode===null){e:{r=e.type,n=e.memoizedProps,a=a.ownerDocument||a;t:switch(r){case"title":i=a.getElementsByTagName("title")[0],(!i||i[Lc]||i[zt]||i.namespaceURI==="http://www.w3.org/2000/svg"||i.hasAttribute("itemprop"))&&(i=a.createElement(r),a.head.insertBefore(i,a.querySelector("head > title"))),qt(i,r,n),i[zt]=e,Ct(i),r=i;break e;case"link":var o=US("link","href",a).get(r+(n.href||""));if(o){for(var l=0;l<o.length;l++)if(i=o[l],i.getAttribute("href")===(n.href==null||n.href===""?null:n.href)&&i.getAttribute("rel")===(n.rel==null?null:n.rel)&&i.getAttribute("title")===(n.title==null?null:n.title)&&i.getAttribute("crossorigin")===(n.crossOrigin==null?null:n.crossOrigin)){o.splice(l,1);break t}}i=a.createElement(r),qt(i,r,n),a.head.appendChild(i);break;case"meta":if(o=US("meta","content",a).get(r+(n.content||""))){for(l=0;l<o.length;l++)if(i=o[l],i.getAttribute("content")===(n.content==null?null:""+n.content)&&i.getAttribute("name")===(n.name==null?null:n.name)&&i.getAttribute("property")===(n.property==null?null:n.property)&&i.getAttribute("http-equiv")===(n.httpEquiv==null?null:n.httpEquiv)&&i.getAttribute("charset")===(n.charSet==null?null:n.charSet)){o.splice(l,1);break t}}i=a.createElement(r),qt(i,r,n),a.head.appendChild(i);break;default:throw Error(U(468,r))}i[zt]=e,Ct(i),r=i}e.stateNode=r}else qS(a,e.type,e.stateNode);else e.stateNode=IS(a,r,e.memoizedProps);else i!==r?(i===null?n.stateNode!==null&&(n=n.stateNode,n.parentNode.removeChild(n)):i.count--,r===null?qS(a,e.type,e.stateNode):IS(a,r,e.memoizedProps)):r===null&&e.stateNode!==null&&Km(e,e.memoizedProps,n.memoizedProps)}break;case 27:on(t,e),ln(e),r&512&&(mt||n===null||wr(n,n.return)),n!==null&&r&4&&Km(e,e.memoizedProps,n.memoizedProps);break;case 5:if(on(t,e),ln(e),r&512&&(mt||n===null||wr(n,n.return)),e.flags&32){a=e.stateNode;try{Al(a,"")}catch(b){$e(e,e.return,b)}}r&4&&e.stateNode!=null&&(a=e.memoizedProps,Km(e,a,n!==null?n.memoizedProps:a)),r&1024&&(Vm=!0);break;case 6:if(on(t,e),ln(e),r&4){if(e.stateNode===null)throw Error(U(162));r=e.memoizedProps,n=e.stateNode;try{n.nodeValue=r}catch(b){$e(e,e.return,b)}}break;case 3:if(nd=null,a=lr,lr=Ld(t.containerInfo),on(t,e),lr=a,ln(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{Pl(t.containerInfo)}catch(b){$e(e,e.return,b)}Vm&&(Vm=!1,Z_(e));break;case 4:r=lr,lr=Ld(e.stateNode.containerInfo),on(t,e),ln(e),lr=r;break;case 12:on(t,e),ln(e);break;case 31:on(t,e),ln(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,Sf(e,r)));break;case 13:on(t,e),ln(e),e.child.flags&8192&&e.memoizedState!==null!=(n!==null&&n.memoizedState!==null)&&(cp=Tn()),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,Sf(e,r)));break;case 22:a=e.memoizedState!==null;var s=n!==null&&n.memoizedState!==null,u=Yr,d=mt;if(Yr=u||a,mt=d||s,on(t,e),mt=d,Yr=u,ln(e),r&8192)e:for(t=e.stateNode,t._visibility=a?t._visibility&-2:t._visibility|1,a&&(n===null||s||Yr||mt||Oi(e)),n=null,t=e;;){if(t.tag===5||t.tag===26){if(n===null){s=n=t;try{if(i=s.stateNode,a)o=i.style,typeof o.setProperty=="function"?o.setProperty("display","none","important"):o.display="none";else{l=s.stateNode;var f=s.memoizedProps.style,h=f!=null&&f.hasOwnProperty("display")?f.display:null;l.style.display=h==null||typeof h=="boolean"?"":(""+h).trim()}}catch(b){$e(s,s.return,b)}}}else if(t.tag===6){if(n===null){s=t;try{s.stateNode.nodeValue=a?"":s.memoizedProps}catch(b){$e(s,s.return,b)}}}else if(t.tag===18){if(n===null){s=t;try{var p=s.stateNode;a?kS(p,!0):kS(s.stateNode,!1)}catch(b){$e(s,s.return,b)}}}else if((t.tag!==22&&t.tag!==23||t.memoizedState===null||t===e)&&t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break e;for(;t.sibling===null;){if(t.return===null||t.return===e)break e;n===t&&(n=null),t=t.return}n===t&&(n=null),t.sibling.return=t.return,t=t.sibling}r&4&&(r=e.updateQueue,r!==null&&(n=r.retryQueue,n!==null&&(r.retryQueue=null,Sf(e,n))));break;case 19:on(t,e),ln(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,Sf(e,r)));break;case 30:break;case 21:break;default:on(t,e),ln(e)}}function ln(e){var t=e.flags;if(t&2){try{for(var n,r=e.return;r!==null;){if(F_(r)){n=r;break}r=r.return}if(n==null)throw Error(U(160));switch(n.tag){case 27:var a=n.stateNode,i=Ym(e);Nd(e,i,a);break;case 5:var o=n.stateNode;n.flags&32&&(Al(o,""),n.flags&=-33);var l=Ym(e);Nd(e,l,o);break;case 3:case 4:var s=n.stateNode.containerInfo,u=Ym(e);Av(e,u,s);break;default:throw Error(U(161))}}catch(d){$e(e,e.return,d)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function Z_(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;Z_(t),t.tag===5&&t.flags&1024&&t.stateNode.reset(),e=e.sibling}}function Lr(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)K_(e,t.alternate,t),t=t.sibling}function Oi(e){for(e=e.child;e!==null;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:oi(4,t,t.return),Oi(t);break;case 1:wr(t,t.return);var n=t.stateNode;typeof n.componentWillUnmount=="function"&&q_(t,t.return,n),Oi(t);break;case 27:Su(t.stateNode);case 26:case 5:wr(t,t.return),Oi(t);break;case 22:t.memoizedState===null&&Oi(t);break;case 30:Oi(t);break;default:Oi(t)}e=e.sibling}}function Br(e,t,n){for(n=n&&(t.subtreeFlags&8772)!==0,t=t.child;t!==null;){var r=t.alternate,a=e,i=t,o=i.flags;switch(i.tag){case 0:case 11:case 15:Br(a,i,n),Uc(4,i);break;case 1:if(Br(a,i,n),r=i,a=r.stateNode,typeof a.componentDidMount=="function")try{a.componentDidMount()}catch(u){$e(r,r.return,u)}if(r=i,a=r.updateQueue,a!==null){var l=r.stateNode;try{var s=a.shared.hiddenCallbacks;if(s!==null)for(a.shared.hiddenCallbacks=null,a=0;a<s.length;a++)XE(s[a],l)}catch(u){$e(r,r.return,u)}}n&&o&64&&U_(i),vu(i,i.return);break;case 27:G_(i);case 26:case 5:Br(a,i,n),n&&r===null&&o&4&&H_(i),vu(i,i.return);break;case 12:Br(a,i,n);break;case 31:Br(a,i,n),n&&o&4&&X_(a,i);break;case 13:Br(a,i,n),n&&o&4&&Q_(a,i);break;case 22:i.memoizedState===null&&Br(a,i,n),vu(i,i.return);break;case 30:break;default:Br(a,i,n)}t=t.sibling}}function Rb(e,t){var n=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),e=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(e=t.memoizedState.cachePool.pool),e!==n&&(e!=null&&e.refCount++,n!=null&&Bc(n))}function Pb(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&Bc(e))}function ar(e,t,n,r){if(t.subtreeFlags&10256)for(t=t.child;t!==null;)J_(e,t,n,r),t=t.sibling}function J_(e,t,n,r){var a=t.flags;switch(t.tag){case 0:case 11:case 15:ar(e,t,n,r),a&2048&&Uc(9,t);break;case 1:ar(e,t,n,r);break;case 3:ar(e,t,n,r),a&2048&&(e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&Bc(e)));break;case 12:if(a&2048){ar(e,t,n,r),e=t.stateNode;try{var i=t.memoizedProps,o=i.id,l=i.onPostCommit;typeof l=="function"&&l(o,t.alternate===null?"mount":"update",e.passiveEffectDuration,-0)}catch(s){$e(t,t.return,s)}}else ar(e,t,n,r);break;case 31:ar(e,t,n,r);break;case 13:ar(e,t,n,r);break;case 23:break;case 22:i=t.stateNode,o=t.alternate,t.memoizedState!==null?i._visibility&2?ar(e,t,n,r):gu(e,t):i._visibility&2?ar(e,t,n,r):(i._visibility|=2,Ro(e,t,n,r,(t.subtreeFlags&10256)!==0||!1)),a&2048&&Rb(o,t);break;case 24:ar(e,t,n,r),a&2048&&Pb(t.alternate,t);break;default:ar(e,t,n,r)}}function Ro(e,t,n,r,a){for(a=a&&((t.subtreeFlags&10256)!==0||!1),t=t.child;t!==null;){var i=e,o=t,l=n,s=r,u=o.flags;switch(o.tag){case 0:case 11:case 15:Ro(i,o,l,s,a),Uc(8,o);break;case 23:break;case 22:var d=o.stateNode;o.memoizedState!==null?d._visibility&2?Ro(i,o,l,s,a):gu(i,o):(d._visibility|=2,Ro(i,o,l,s,a)),a&&u&2048&&Rb(o.alternate,o);break;case 24:Ro(i,o,l,s,a),a&&u&2048&&Pb(o.alternate,o);break;default:Ro(i,o,l,s,a)}t=t.sibling}}function gu(e,t){if(t.subtreeFlags&10256)for(t=t.child;t!==null;){var n=e,r=t,a=r.flags;switch(r.tag){case 22:gu(n,r),a&2048&&Rb(r.alternate,r);break;case 24:gu(n,r),a&2048&&Pb(r.alternate,r);break;default:gu(n,r)}t=t.sibling}}var iu=8192;function Eo(e,t,n){if(e.subtreeFlags&iu)for(e=e.child;e!==null;)eT(e,t,n),e=e.sibling}function eT(e,t,n){switch(e.tag){case 26:Eo(e,t,n),e.flags&iu&&e.memoizedState!==null&&_$(n,lr,e.memoizedState,e.memoizedProps);break;case 5:Eo(e,t,n);break;case 3:case 4:var r=lr;lr=Ld(e.stateNode.containerInfo),Eo(e,t,n),lr=r;break;case 22:e.memoizedState===null&&(r=e.alternate,r!==null&&r.memoizedState!==null?(r=iu,iu=16777216,Eo(e,t,n),iu=r):Eo(e,t,n));break;default:Eo(e,t,n)}}function tT(e){var t=e.alternate;if(t!==null&&(e=t.child,e!==null)){t.child=null;do t=e.sibling,e.sibling=null,e=t;while(e!==null)}}function Us(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];Nt=r,rT(r,e)}tT(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)nT(e),e=e.sibling}function nT(e){switch(e.tag){case 0:case 11:case 15:Us(e),e.flags&2048&&oi(9,e,e.return);break;case 3:Us(e);break;case 12:Us(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,ed(e)):Us(e);break;default:Us(e)}}function ed(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];Nt=r,rT(r,e)}tT(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:oi(8,t,t.return),ed(t);break;case 22:n=t.stateNode,n._visibility&2&&(n._visibility&=-3,ed(t));break;default:ed(t)}e=e.sibling}}function rT(e,t){for(;Nt!==null;){var n=Nt;switch(n.tag){case 0:case 11:case 15:oi(8,n,t);break;case 23:case 22:if(n.memoizedState!==null&&n.memoizedState.cachePool!==null){var r=n.memoizedState.cachePool.pool;r!=null&&r.refCount++}break;case 24:Bc(n.memoizedState.cache)}if(r=n.child,r!==null)r.return=n,Nt=r;else e:for(n=e;Nt!==null;){r=Nt;var a=r.sibling,i=r.return;if(Y_(r),r===n){Nt=null;break e}if(a!==null){a.return=i,Nt=a;break e}Nt=i}}}var q4={getCacheForType:function(e){var t=Ut(yt),n=t.data.get(e);return n===void 0&&(n=e(),t.data.set(e,n)),n},cacheSignal:function(){return Ut(yt).controller.signal}},H4=typeof WeakMap=="function"?WeakMap:Map,Te=0,Fe=null,Se=null,we=0,Pe=0,xn=null,qa=!1,hs=!1,$b=!1,ca=0,ut=0,li=0,Vi=0,kb=0,_n=0,Nl=0,bu=null,fn=null,Ev=!1,cp=0,aT=0,Cd=1/0,Md=null,Qa=null,jt=0,Wa=null,Cl=null,ta=0,_v=0,Tv=null,iT=null,xu=0,Nv=null;function Mn(){return Te&2&&we!==0?we&-we:ie.T!==null?Lb():pE()}function oT(){if(_n===0)if(!(we&536870912)||Ae){var e=hf;hf<<=1,!(hf&3932160)&&(hf=262144),_n=e}else _n=536870912;return e=$n.current,e!==null&&(e.flags|=32),_n}function hn(e,t,n){(e===Fe&&(Pe===2||Pe===9)||e.cancelPendingCommit!==null)&&(Ml(e,0),Ha(e,we,_n,!1)),Dc(e,n),(!(Te&2)||e!==Fe)&&(e===Fe&&(!(Te&2)&&(Vi|=n),ut===4&&Ha(e,we,_n,!1)),Nr(e))}function lT(e,t,n){if(Te&6)throw Error(U(327));var r=!n&&(t&127)===0&&(t&e.expiredLanes)===0||kc(e,t),a=r?K4(e,t):Xm(e,t,!0),i=r;do{if(a===0){hs&&!r&&Ha(e,t,0,!1);break}else{if(n=e.current.alternate,i&&!F4(n)){a=Xm(e,t,!1),i=!1;continue}if(a===2){if(i=t,e.errorRecoveryDisabledLanes&i)var o=0;else o=e.pendingLanes&-536870913,o=o!==0?o:o&536870912?536870912:0;if(o!==0){t=o;e:{var l=e;a=bu;var s=l.current.memoizedState.isDehydrated;if(s&&(Ml(l,o).flags|=256),o=Xm(l,o,!1),o!==2){if($b&&!s){l.errorRecoveryDisabledLanes|=i,Vi|=i,a=4;break e}i=fn,fn=a,i!==null&&(fn===null?fn=i:fn.push.apply(fn,i))}a=o}if(i=!1,a!==2)continue}}if(a===1){Ml(e,0),Ha(e,t,0,!0);break}e:{switch(r=e,i=a,i){case 0:case 1:throw Error(U(345));case 4:if((t&4194048)!==t)break;case 6:Ha(r,t,_n,!qa);break e;case 2:fn=null;break;case 3:case 5:break;default:throw Error(U(329))}if((t&62914560)===t&&(a=cp+300-Tn(),10<a)){if(Ha(r,t,_n,!qa),Jh(r,0,!0)!==0)break e;ta=t,r.timeoutHandle=_T(wS.bind(null,r,n,fn,Md,Ev,t,_n,Vi,Nl,qa,i,"Throttled",-0,0),a);break e}wS(r,n,fn,Md,Ev,t,_n,Vi,Nl,qa,i,null,-0,0)}}break}while(!0);Nr(e)}function wS(e,t,n,r,a,i,o,l,s,u,d,f,h,p){if(e.timeoutHandle=-1,f=t.subtreeFlags,f&8192||(f&16785408)===16785408){f={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:Xr},eT(t,i,f);var b=(i&62914560)===i?cp-Tn():(i&4194048)===i?aT-Tn():0;if(b=T$(f,b),b!==null){ta=i,e.cancelPendingCommit=b(OS.bind(null,e,t,i,n,r,a,o,l,s,d,f,null,h,p)),Ha(e,i,o,!u);return}}OS(e,t,i,n,r,a,o,l,s)}function F4(e){for(var t=e;;){var n=t.tag;if((n===0||n===11||n===15)&&t.flags&16384&&(n=t.updateQueue,n!==null&&(n=n.stores,n!==null)))for(var r=0;r<n.length;r++){var a=n[r],i=a.getSnapshot;a=a.value;try{if(!Pn(i(),a))return!1}catch{return!1}}if(n=t.child,t.subtreeFlags&16384&&n!==null)n.return=t,t=n;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function Ha(e,t,n,r){t&=~kb,t&=~Vi,e.suspendedLanes|=t,e.pingedLanes&=~t,r&&(e.warmLanes|=t),r=e.expirationTimes;for(var a=t;0<a;){var i=31-Cn(a),o=1<<i;r[i]=-1,a&=~o}n!==0&&fE(e,n,t)}function fp(){return Te&6?!0:(qc(0),!1)}function Db(){if(Se!==null){if(Pe===0)var e=Se.return;else e=Se,Qr=yo=null,Sb(e),rl=null,$u=0,e=Se;for(;e!==null;)I_(e.alternate,e),e=e.return;Se=null}}function Ml(e,t){var n=e.timeoutHandle;n!==-1&&(e.timeoutHandle=-1,c$(n)),n=e.cancelPendingCommit,n!==null&&(e.cancelPendingCommit=null,n()),ta=0,Db(),Fe=e,Se=n=Jr(e.current,null),we=t,Pe=0,xn=null,qa=!1,hs=kc(e,t),$b=!1,Nl=_n=kb=Vi=li=ut=0,fn=bu=null,Ev=!1,t&8&&(t|=t&32);var r=e.entangledLanes;if(r!==0)for(e=e.entanglements,r&=t;0<r;){var a=31-Cn(r),i=1<<a;t|=e[a],r&=~i}return ca=t,rp(),n}function sT(e,t){de=null,ie.H=Du,t===ds||t===ip?(t=eS(),Pe=3):t===pb?(t=eS(),Pe=4):Pe=t===Cb?8:t!==null&&typeof t=="object"&&typeof t.then=="function"?6:1,xn=t,Se===null&&(ut=1,_d(e,Gn(t,e.current)))}function uT(){var e=$n.current;return e===null?!0:(we&4194048)===we?Xn===null:(we&62914560)===we||we&536870912?e===Xn:!1}function cT(){var e=ie.H;return ie.H=Du,e===null?Du:e}function fT(){var e=ie.A;return ie.A=q4,e}function Rd(){ut=4,qa||(we&4194048)!==we&&$n.current!==null||(hs=!0),!(li&134217727)&&!(Vi&134217727)||Fe===null||Ha(Fe,we,_n,!1)}function Xm(e,t,n){var r=Te;Te|=2;var a=cT(),i=fT();(Fe!==e||we!==t)&&(Md=null,Ml(e,t)),t=!1;var o=ut;e:do try{if(Pe!==0&&Se!==null){var l=Se,s=xn;switch(Pe){case 8:Db(),o=6;break e;case 3:case 2:case 9:case 6:$n.current===null&&(t=!0);var u=Pe;if(Pe=0,xn=null,Ko(e,l,s,u),n&&hs){o=0;break e}break;default:u=Pe,Pe=0,xn=null,Ko(e,l,s,u)}}G4(),o=ut;break}catch(d){sT(e,d)}while(!0);return t&&e.shellSuspendCounter++,Qr=yo=null,Te=r,ie.H=a,ie.A=i,Se===null&&(Fe=null,we=0,rp()),o}function G4(){for(;Se!==null;)dT(Se)}function K4(e,t){var n=Te;Te|=2;var r=cT(),a=fT();Fe!==e||we!==t?(Md=null,Cd=Tn()+500,Ml(e,t)):hs=kc(e,t);e:do try{if(Pe!==0&&Se!==null){t=Se;var i=xn;t:switch(Pe){case 1:Pe=0,xn=null,Ko(e,t,i,1);break;case 2:case 9:if(J1(i)){Pe=0,xn=null,jS(t);break}t=function(){Pe!==2&&Pe!==9||Fe!==e||(Pe=7),Nr(e)},i.then(t,t);break e;case 3:Pe=7;break e;case 4:Pe=5;break e;case 7:J1(i)?(Pe=0,xn=null,jS(t)):(Pe=0,xn=null,Ko(e,t,i,7));break;case 5:var o=null;switch(Se.tag){case 26:o=Se.memoizedState;case 5:case 27:var l=Se;if(o?RT(o):l.stateNode.complete){Pe=0,xn=null;var s=l.sibling;if(s!==null)Se=s;else{var u=l.return;u!==null?(Se=u,dp(u)):Se=null}break t}}Pe=0,xn=null,Ko(e,t,i,5);break;case 6:Pe=0,xn=null,Ko(e,t,i,6);break;case 8:Db(),ut=6;break e;default:throw Error(U(462))}}Y4();break}catch(d){sT(e,d)}while(!0);return Qr=yo=null,ie.H=r,ie.A=a,Te=n,Se!==null?0:(Fe=null,we=0,rp(),ut)}function Y4(){for(;Se!==null&&!yP();)dT(Se)}function dT(e){var t=B_(e.alternate,e,ca);e.memoizedProps=e.pendingProps,t===null?dp(e):Se=t}function jS(e){var t=e,n=t.alternate;switch(t.tag){case 15:case 0:t=yS(n,t,t.pendingProps,t.type,void 0,we);break;case 11:t=yS(n,t,t.pendingProps,t.type.render,t.ref,we);break;case 5:Sb(t);default:I_(n,t),t=Se=IE(t,ca),t=B_(n,t,ca)}e.memoizedProps=e.pendingProps,t===null?dp(e):Se=t}function Ko(e,t,n,r){Qr=yo=null,Sb(t),rl=null,$u=0;var a=t.return;try{if(k4(e,a,t,n,we)){ut=1,_d(e,Gn(n,e.current)),Se=null;return}}catch(i){if(a!==null)throw Se=a,i;ut=1,_d(e,Gn(n,e.current)),Se=null;return}t.flags&32768?(Ae||r===1?e=!0:hs||we&536870912?e=!1:(qa=e=!0,(r===2||r===9||r===3||r===6)&&(r=$n.current,r!==null&&r.tag===13&&(r.flags|=16384))),hT(t,e)):dp(t)}function dp(e){var t=e;do{if(t.flags&32768){hT(t,qa);return}e=t.return;var n=z4(t.alternate,t,ca);if(n!==null){Se=n;return}if(t=t.sibling,t!==null){Se=t;return}Se=t=e}while(t!==null);ut===0&&(ut=5)}function hT(e,t){do{var n=B4(e.alternate,e);if(n!==null){n.flags&=32767,Se=n;return}if(n=e.return,n!==null&&(n.flags|=32768,n.subtreeFlags=0,n.deletions=null),!t&&(e=e.sibling,e!==null)){Se=e;return}Se=e=n}while(e!==null);ut=6,Se=null}function OS(e,t,n,r,a,i,o,l,s){e.cancelPendingCommit=null;do hp();while(jt!==0);if(Te&6)throw Error(U(327));if(t!==null){if(t===e.current)throw Error(U(177));if(i=t.lanes|t.childLanes,i|=lb,EP(e,n,i,o,l,s),e===Fe&&(Se=Fe=null,we=0),Cl=t,Wa=e,ta=n,_v=i,Tv=a,iT=r,t.subtreeFlags&10256||t.flags&10256?(e.callbackNode=null,e.callbackPriority=0,W4(yd,function(){return gT(),null})):(e.callbackNode=null,e.callbackPriority=0),r=(t.flags&13878)!==0,t.subtreeFlags&13878||r){r=ie.T,ie.T=null,a=Ne.p,Ne.p=2,o=Te,Te|=4;try{I4(e,t,n)}finally{Te=o,Ne.p=a,ie.T=r}}jt=1,pT(),mT(),yT()}}function pT(){if(jt===1){jt=0;var e=Wa,t=Cl,n=(t.flags&13878)!==0;if(t.subtreeFlags&13878||n){n=ie.T,ie.T=null;var r=Ne.p;Ne.p=2;var a=Te;Te|=4;try{W_(t,e);var i=Pv,o=RE(e.containerInfo),l=i.focusedElem,s=i.selectionRange;if(o!==l&&l&&l.ownerDocument&&ME(l.ownerDocument.documentElement,l)){if(s!==null&&ob(l)){var u=s.start,d=s.end;if(d===void 0&&(d=u),"selectionStart"in l)l.selectionStart=u,l.selectionEnd=Math.min(d,l.value.length);else{var f=l.ownerDocument||document,h=f&&f.defaultView||window;if(h.getSelection){var p=h.getSelection(),b=l.textContent.length,v=Math.min(s.start,b),x=s.end===void 0?v:Math.min(s.end,b);!p.extend&&v>x&&(o=x,x=v,v=o);var m=K1(l,v),y=K1(l,x);if(m&&y&&(p.rangeCount!==1||p.anchorNode!==m.node||p.anchorOffset!==m.offset||p.focusNode!==y.node||p.focusOffset!==y.offset)){var g=f.createRange();g.setStart(m.node,m.offset),p.removeAllRanges(),v>x?(p.addRange(g),p.extend(y.node,y.offset)):(g.setEnd(y.node,y.offset),p.addRange(g))}}}}for(f=[],p=l;p=p.parentNode;)p.nodeType===1&&f.push({element:p,left:p.scrollLeft,top:p.scrollTop});for(typeof l.focus=="function"&&l.focus(),l=0;l<f.length;l++){var S=f[l];S.element.scrollLeft=S.left,S.element.scrollTop=S.top}}Id=!!Rv,Pv=Rv=null}finally{Te=a,Ne.p=r,ie.T=n}}e.current=t,jt=2}}function mT(){if(jt===2){jt=0;var e=Wa,t=Cl,n=(t.flags&8772)!==0;if(t.subtreeFlags&8772||n){n=ie.T,ie.T=null;var r=Ne.p;Ne.p=2;var a=Te;Te|=4;try{K_(e,t.alternate,t)}finally{Te=a,Ne.p=r,ie.T=n}}jt=3}}function yT(){if(jt===4||jt===3){jt=0,vP();var e=Wa,t=Cl,n=ta,r=iT;t.subtreeFlags&10256||t.flags&10256?jt=5:(jt=0,Cl=Wa=null,vT(e,e.pendingLanes));var a=e.pendingLanes;if(a===0&&(Qa=null),J0(n),t=t.stateNode,Nn&&typeof Nn.onCommitFiberRoot=="function")try{Nn.onCommitFiberRoot($c,t,void 0,(t.current.flags&128)===128)}catch{}if(r!==null){t=ie.T,a=Ne.p,Ne.p=2,ie.T=null;try{for(var i=e.onRecoverableError,o=0;o<r.length;o++){var l=r[o];i(l.value,{componentStack:l.stack})}}finally{ie.T=t,Ne.p=a}}ta&3&&hp(),Nr(e),a=e.pendingLanes,n&261930&&a&42?e===Nv?xu++:(xu=0,Nv=e):xu=0,qc(0)}}function vT(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,Bc(t)))}function hp(){return pT(),mT(),yT(),gT()}function gT(){if(jt!==5)return!1;var e=Wa,t=_v;_v=0;var n=J0(ta),r=ie.T,a=Ne.p;try{Ne.p=32>n?32:n,ie.T=null,n=Tv,Tv=null;var i=Wa,o=ta;if(jt=0,Cl=Wa=null,ta=0,Te&6)throw Error(U(331));var l=Te;if(Te|=4,nT(i.current),J_(i,i.current,o,n),Te=l,qc(0,!1),Nn&&typeof Nn.onPostCommitFiberRoot=="function")try{Nn.onPostCommitFiberRoot($c,i)}catch{}return!0}finally{Ne.p=a,ie.T=r,vT(e,t)}}function AS(e,t,n){t=Gn(n,t),t=wv(e.stateNode,t,2),e=Xa(e,t,2),e!==null&&(Dc(e,2),Nr(e))}function $e(e,t,n){if(e.tag===3)AS(e,e,n);else for(;t!==null;){if(t.tag===3){AS(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof r.componentDidCatch=="function"&&(Qa===null||!Qa.has(r))){e=Gn(n,e),n=P_(2),r=Xa(t,n,2),r!==null&&($_(n,r,t,e),Dc(r,2),Nr(r));break}}t=t.return}}function Qm(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new H4;var a=new Set;r.set(t,a)}else a=r.get(t),a===void 0&&(a=new Set,r.set(t,a));a.has(n)||($b=!0,a.add(n),e=V4.bind(null,e,t,n),t.then(e,e))}function V4(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),e.pingedLanes|=e.suspendedLanes&n,e.warmLanes&=~n,Fe===e&&(we&n)===n&&(ut===4||ut===3&&(we&62914560)===we&&300>Tn()-cp?!(Te&2)&&Ml(e,0):kb|=n,Nl===we&&(Nl=0)),Nr(e)}function bT(e,t){t===0&&(t=cE()),e=mo(e,t),e!==null&&(Dc(e,t),Nr(e))}function X4(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),bT(e,n)}function Q4(e,t){var n=0;switch(e.tag){case 31:case 13:var r=e.stateNode,a=e.memoizedState;a!==null&&(n=a.retryLane);break;case 19:r=e.stateNode;break;case 22:r=e.stateNode._retryCache;break;default:throw Error(U(314))}r!==null&&r.delete(t),bT(e,n)}function W4(e,t){return W0(e,t)}var Pd=null,Po=null,Cv=!1,$d=!1,Wm=!1,Fa=0;function Nr(e){e!==Po&&e.next===null&&(Po===null?Pd=Po=e:Po=Po.next=e),$d=!0,Cv||(Cv=!0,J4())}function qc(e,t){if(!Wm&&$d){Wm=!0;do for(var n=!1,r=Pd;r!==null;){if(e!==0){var a=r.pendingLanes;if(a===0)var i=0;else{var o=r.suspendedLanes,l=r.pingedLanes;i=(1<<31-Cn(42|e)+1)-1,i&=a&~(o&~l),i=i&201326741?i&201326741|1:i?i|2:0}i!==0&&(n=!0,ES(r,i))}else i=we,i=Jh(r,r===Fe?i:0,r.cancelPendingCommit!==null||r.timeoutHandle!==-1),!(i&3)||kc(r,i)||(n=!0,ES(r,i));r=r.next}while(n);Wm=!1}}function Z4(){xT()}function xT(){$d=Cv=!1;var e=0;Fa!==0&&u$()&&(e=Fa);for(var t=Tn(),n=null,r=Pd;r!==null;){var a=r.next,i=ST(r,t);i===0?(r.next=null,n===null?Pd=a:n.next=a,a===null&&(Po=n)):(n=r,(e!==0||i&3)&&($d=!0)),r=a}jt!==0&&jt!==5||qc(e),Fa!==0&&(Fa=0)}function ST(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,a=e.expirationTimes,i=e.pendingLanes&-62914561;0<i;){var o=31-Cn(i),l=1<<o,s=a[o];s===-1?(!(l&n)||l&r)&&(a[o]=AP(l,t)):s<=t&&(e.expiredLanes|=l),i&=~l}if(t=Fe,n=we,n=Jh(e,e===t?n:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r=e.callbackNode,n===0||e===t&&(Pe===2||Pe===9)||e.cancelPendingCommit!==null)return r!==null&&r!==null&&Am(r),e.callbackNode=null,e.callbackPriority=0;if(!(n&3)||kc(e,n)){if(t=n&-n,t===e.callbackPriority)return t;switch(r!==null&&Am(r),J0(n)){case 2:case 8:n=sE;break;case 32:n=yd;break;case 268435456:n=uE;break;default:n=yd}return r=wT.bind(null,e),n=W0(n,r),e.callbackPriority=t,e.callbackNode=n,t}return r!==null&&r!==null&&Am(r),e.callbackPriority=2,e.callbackNode=null,2}function wT(e,t){if(jt!==0&&jt!==5)return e.callbackNode=null,e.callbackPriority=0,null;var n=e.callbackNode;if(hp()&&e.callbackNode!==n)return null;var r=we;return r=Jh(e,e===Fe?r:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r===0?null:(lT(e,r,t),ST(e,Tn()),e.callbackNode!=null&&e.callbackNode===n?wT.bind(null,e):null)}function ES(e,t){if(hp())return null;lT(e,t,!0)}function J4(){f$(function(){Te&6?W0(lE,Z4):xT()})}function Lb(){if(Fa===0){var e=El;e===0&&(e=df,df<<=1,!(df&261888)&&(df=256)),Fa=e}return Fa}function _S(e){return e==null||typeof e=="symbol"||typeof e=="boolean"?null:typeof e=="function"?e:Gf(""+e)}function TS(e,t){var n=t.ownerDocument.createElement("input");return n.name=t.name,n.value=t.value,e.id&&n.setAttribute("form",e.id),t.parentNode.insertBefore(n,t),e=new FormData(e),n.parentNode.removeChild(n),e}function e$(e,t,n,r,a){if(t==="submit"&&n&&n.stateNode===a){var i=_S((a[mn]||null).action),o=r.submitter;o&&(t=(t=o[mn]||null)?_S(t.formAction):o.getAttribute("formAction"),t!==null&&(i=t,o=null));var l=new ep("action","action",null,r,a);e.push({event:l,listeners:[{instance:null,listener:function(){if(r.defaultPrevented){if(Fa!==0){var s=o?TS(a,o):new FormData(a);xv(n,{pending:!0,data:s,method:a.method,action:i},null,s)}}else typeof i=="function"&&(l.preventDefault(),s=o?TS(a,o):new FormData(a),xv(n,{pending:!0,data:s,method:a.method,action:i},i,s))},currentTarget:a}]})}}for(var Zm=0;Zm<sv.length;Zm++){var Jm=sv[Zm],t$=Jm.toLowerCase(),n$=Jm[0].toUpperCase()+Jm.slice(1);hr(t$,"on"+n$)}hr($E,"onAnimationEnd");hr(kE,"onAnimationIteration");hr(DE,"onAnimationStart");hr("dblclick","onDoubleClick");hr("focusin","onFocus");hr("focusout","onBlur");hr(g4,"onTransitionRun");hr(b4,"onTransitionStart");hr(x4,"onTransitionCancel");hr(LE,"onTransitionEnd");Ol("onMouseEnter",["mouseout","mouseover"]);Ol("onMouseLeave",["mouseout","mouseover"]);Ol("onPointerEnter",["pointerout","pointerover"]);Ol("onPointerLeave",["pointerout","pointerover"]);fo("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));fo("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));fo("onBeforeInput",["compositionend","keypress","textInput","paste"]);fo("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));fo("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));fo("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Lu="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(" "),r$=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(Lu));function jT(e,t){t=(t&4)!==0;for(var n=0;n<e.length;n++){var r=e[n],a=r.event;r=r.listeners;e:{var i=void 0;if(t)for(var o=r.length-1;0<=o;o--){var l=r[o],s=l.instance,u=l.currentTarget;if(l=l.listener,s!==i&&a.isPropagationStopped())break e;i=l,a.currentTarget=u;try{i(a)}catch(d){gd(d)}a.currentTarget=null,i=s}else for(o=0;o<r.length;o++){if(l=r[o],s=l.instance,u=l.currentTarget,l=l.listener,s!==i&&a.isPropagationStopped())break e;i=l,a.currentTarget=u;try{i(a)}catch(d){gd(d)}a.currentTarget=null,i=s}}}}function xe(e,t){var n=t[ev];n===void 0&&(n=t[ev]=new Set);var r=e+"__bubble";n.has(r)||(OT(t,e,2,!1),n.add(r))}function ey(e,t,n){var r=0;t&&(r|=4),OT(n,e,r,t)}var wf="_reactListening"+Math.random().toString(36).slice(2);function zb(e){if(!e[wf]){e[wf]=!0,mE.forEach(function(n){n!=="selectionchange"&&(r$.has(n)||ey(n,!1,e),ey(n,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[wf]||(t[wf]=!0,ey("selectionchange",!1,t))}}function OT(e,t,n,r){switch(LT(t)){case 2:var a=M$;break;case 8:a=R$;break;default:a=qb}n=a.bind(null,t,n,e),a=void 0,!iv||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(a=!0),r?a!==void 0?e.addEventListener(t,n,{capture:!0,passive:a}):e.addEventListener(t,n,!0):a!==void 0?e.addEventListener(t,n,{passive:a}):e.addEventListener(t,n,!1)}function ty(e,t,n,r,a){var i=r;if(!(t&1)&&!(t&2)&&r!==null)e:for(;;){if(r===null)return;var o=r.tag;if(o===3||o===4){var l=r.stateNode.containerInfo;if(l===a)break;if(o===4)for(o=r.return;o!==null;){var s=o.tag;if((s===3||s===4)&&o.stateNode.containerInfo===a)return;o=o.return}for(;l!==null;){if(o=Lo(l),o===null)return;if(s=o.tag,s===5||s===6||s===26||s===27){r=i=o;continue e}l=l.parentNode}}r=r.return}jE(function(){var u=i,d=nb(n),f=[];e:{var h=zE.get(e);if(h!==void 0){var p=ep,b=e;switch(e){case"keypress":if(Yf(n)===0)break e;case"keydown":case"keyup":p=QP;break;case"focusin":b="focus",p=Cm;break;case"focusout":b="blur",p=Cm;break;case"beforeblur":case"afterblur":p=Cm;break;case"click":if(n.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":p=D1;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":p=zP;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":p=JP;break;case $E:case kE:case DE:p=UP;break;case LE:p=t4;break;case"scroll":case"scrollend":p=DP;break;case"wheel":p=r4;break;case"copy":case"cut":case"paste":p=HP;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":p=z1;break;case"toggle":case"beforetoggle":p=i4}var v=(t&4)!==0,x=!v&&(e==="scroll"||e==="scrollend"),m=v?h!==null?h+"Capture":null:h;v=[];for(var y=u,g;y!==null;){var S=y;if(g=S.stateNode,S=S.tag,S!==5&&S!==26&&S!==27||g===null||m===null||(S=Nu(y,m),S!=null&&v.push(zu(y,S,g))),x)break;y=y.return}0<v.length&&(h=new p(h,b,null,n,d),f.push({event:h,listeners:v}))}}if(!(t&7)){e:{if(h=e==="mouseover"||e==="pointerover",p=e==="mouseout"||e==="pointerout",h&&n!==av&&(b=n.relatedTarget||n.fromElement)&&(Lo(b)||b[us]))break e;if((p||h)&&(h=d.window===d?d:(h=d.ownerDocument)?h.defaultView||h.parentWindow:window,p?(b=n.relatedTarget||n.toElement,p=u,b=b?Lo(b):null,b!==null&&(x=Pc(b),v=b.tag,b!==x||v!==5&&v!==27&&v!==6)&&(b=null)):(p=null,b=u),p!==b)){if(v=D1,S="onMouseLeave",m="onMouseEnter",y="mouse",(e==="pointerout"||e==="pointerover")&&(v=z1,S="onPointerLeave",m="onPointerEnter",y="pointer"),x=p==null?h:ru(p),g=b==null?h:ru(b),h=new v(S,y+"leave",p,n,d),h.target=x,h.relatedTarget=g,S=null,Lo(d)===u&&(v=new v(m,y+"enter",b,n,d),v.target=g,v.relatedTarget=x,S=v),x=S,p&&b)t:{for(v=a$,m=p,y=b,g=0,S=m;S;S=v(S))g++;S=0;for(var w=y;w;w=v(w))S++;for(;0<g-S;)m=v(m),g--;for(;0<S-g;)y=v(y),S--;for(;g--;){if(m===y||y!==null&&m===y.alternate){v=m;break t}m=v(m),y=v(y)}v=null}else v=null;p!==null&&NS(f,h,p,v,!1),b!==null&&x!==null&&NS(f,x,b,v,!0)}}e:{if(h=u?ru(u):window,p=h.nodeName&&h.nodeName.toLowerCase(),p==="select"||p==="input"&&h.type==="file")var j=q1;else if(U1(h))if(NE)j=m4;else{j=h4;var A=d4}else p=h.nodeName,!p||p.toLowerCase()!=="input"||h.type!=="checkbox"&&h.type!=="radio"?u&&tb(u.elementType)&&(j=q1):j=p4;if(j&&(j=j(e,u))){TE(f,j,n,d);break e}A&&A(e,h,u),e==="focusout"&&u&&h.type==="number"&&u.memoizedProps.value!=null&&rv(h,"number",h.value)}switch(A=u?ru(u):window,e){case"focusin":(U1(A)||A.contentEditable==="true")&&(Io=A,ov=u,fu=null);break;case"focusout":fu=ov=Io=null;break;case"mousedown":lv=!0;break;case"contextmenu":case"mouseup":case"dragend":lv=!1,Y1(f,n,d);break;case"selectionchange":if(v4)break;case"keydown":case"keyup":Y1(f,n,d)}var E;if(ib)e:{switch(e){case"compositionstart":var _="onCompositionStart";break e;case"compositionend":_="onCompositionEnd";break e;case"compositionupdate":_="onCompositionUpdate";break e}_=void 0}else Bo?EE(e,n)&&(_="onCompositionEnd"):e==="keydown"&&n.keyCode===229&&(_="onCompositionStart");_&&(AE&&n.locale!=="ko"&&(Bo||_!=="onCompositionStart"?_==="onCompositionEnd"&&Bo&&(E=OE()):(Ua=d,rb="value"in Ua?Ua.value:Ua.textContent,Bo=!0)),A=kd(u,_),0<A.length&&(_=new L1(_,e,null,n,d),f.push({event:_,listeners:A}),E?_.data=E:(E=_E(n),E!==null&&(_.data=E)))),(E=l4?s4(e,n):u4(e,n))&&(_=kd(u,"onBeforeInput"),0<_.length&&(A=new L1("onBeforeInput","beforeinput",null,n,d),f.push({event:A,listeners:_}),A.data=E)),e$(f,e,u,n,d)}jT(f,t)})}function zu(e,t,n){return{instance:e,listener:t,currentTarget:n}}function kd(e,t){for(var n=t+"Capture",r=[];e!==null;){var a=e,i=a.stateNode;if(a=a.tag,a!==5&&a!==26&&a!==27||i===null||(a=Nu(e,n),a!=null&&r.unshift(zu(e,a,i)),a=Nu(e,t),a!=null&&r.push(zu(e,a,i))),e.tag===3)return r;e=e.return}return[]}function a$(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function NS(e,t,n,r,a){for(var i=t._reactName,o=[];n!==null&&n!==r;){var l=n,s=l.alternate,u=l.stateNode;if(l=l.tag,s!==null&&s===r)break;l!==5&&l!==26&&l!==27||u===null||(s=u,a?(u=Nu(n,i),u!=null&&o.unshift(zu(n,u,s))):a||(u=Nu(n,i),u!=null&&o.push(zu(n,u,s)))),n=n.return}o.length!==0&&e.push({event:t,listeners:o})}var i$=/\r\n?/g,o$=/\u0000|\uFFFD/g;function CS(e){return(typeof e=="string"?e:""+e).replace(i$,`
`).replace(o$,"")}function AT(e,t){return t=CS(t),CS(e)===t}function Be(e,t,n,r,a,i){switch(n){case"children":typeof r=="string"?t==="body"||t==="textarea"&&r===""||Al(e,r):(typeof r=="number"||typeof r=="bigint")&&t!=="body"&&Al(e,""+r);break;case"className":mf(e,"class",r);break;case"tabIndex":mf(e,"tabindex",r);break;case"dir":case"role":case"viewBox":case"width":case"height":mf(e,n,r);break;case"style":wE(e,r,i);break;case"data":if(t!=="object"){mf(e,"data",r);break}case"src":case"href":if(r===""&&(t!=="a"||n!=="href")){e.removeAttribute(n);break}if(r==null||typeof r=="function"||typeof r=="symbol"||typeof r=="boolean"){e.removeAttribute(n);break}r=Gf(""+r),e.setAttribute(n,r);break;case"action":case"formAction":if(typeof r=="function"){e.setAttribute(n,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof i=="function"&&(n==="formAction"?(t!=="input"&&Be(e,t,"name",a.name,a,null),Be(e,t,"formEncType",a.formEncType,a,null),Be(e,t,"formMethod",a.formMethod,a,null),Be(e,t,"formTarget",a.formTarget,a,null)):(Be(e,t,"encType",a.encType,a,null),Be(e,t,"method",a.method,a,null),Be(e,t,"target",a.target,a,null)));if(r==null||typeof r=="symbol"||typeof r=="boolean"){e.removeAttribute(n);break}r=Gf(""+r),e.setAttribute(n,r);break;case"onClick":r!=null&&(e.onclick=Xr);break;case"onScroll":r!=null&&xe("scroll",e);break;case"onScrollEnd":r!=null&&xe("scrollend",e);break;case"dangerouslySetInnerHTML":if(r!=null){if(typeof r!="object"||!("__html"in r))throw Error(U(61));if(n=r.__html,n!=null){if(a.children!=null)throw Error(U(60));e.innerHTML=n}}break;case"multiple":e.multiple=r&&typeof r!="function"&&typeof r!="symbol";break;case"muted":e.muted=r&&typeof r!="function"&&typeof r!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(r==null||typeof r=="function"||typeof r=="boolean"||typeof r=="symbol"){e.removeAttribute("xlink:href");break}n=Gf(""+r),e.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",n);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":r!=null&&typeof r!="function"&&typeof r!="symbol"?e.setAttribute(n,""+r):e.removeAttribute(n);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":r&&typeof r!="function"&&typeof r!="symbol"?e.setAttribute(n,""):e.removeAttribute(n);break;case"capture":case"download":r===!0?e.setAttribute(n,""):r!==!1&&r!=null&&typeof r!="function"&&typeof r!="symbol"?e.setAttribute(n,r):e.removeAttribute(n);break;case"cols":case"rows":case"size":case"span":r!=null&&typeof r!="function"&&typeof r!="symbol"&&!isNaN(r)&&1<=r?e.setAttribute(n,r):e.removeAttribute(n);break;case"rowSpan":case"start":r==null||typeof r=="function"||typeof r=="symbol"||isNaN(r)?e.removeAttribute(n):e.setAttribute(n,r);break;case"popover":xe("beforetoggle",e),xe("toggle",e),Ff(e,"popover",r);break;case"xlinkActuate":$r(e,"http://www.w3.org/1999/xlink","xlink:actuate",r);break;case"xlinkArcrole":$r(e,"http://www.w3.org/1999/xlink","xlink:arcrole",r);break;case"xlinkRole":$r(e,"http://www.w3.org/1999/xlink","xlink:role",r);break;case"xlinkShow":$r(e,"http://www.w3.org/1999/xlink","xlink:show",r);break;case"xlinkTitle":$r(e,"http://www.w3.org/1999/xlink","xlink:title",r);break;case"xlinkType":$r(e,"http://www.w3.org/1999/xlink","xlink:type",r);break;case"xmlBase":$r(e,"http://www.w3.org/XML/1998/namespace","xml:base",r);break;case"xmlLang":$r(e,"http://www.w3.org/XML/1998/namespace","xml:lang",r);break;case"xmlSpace":$r(e,"http://www.w3.org/XML/1998/namespace","xml:space",r);break;case"is":Ff(e,"is",r);break;case"innerText":case"textContent":break;default:(!(2<n.length)||n[0]!=="o"&&n[0]!=="O"||n[1]!=="n"&&n[1]!=="N")&&(n=$P.get(n)||n,Ff(e,n,r))}}function Mv(e,t,n,r,a,i){switch(n){case"style":wE(e,r,i);break;case"dangerouslySetInnerHTML":if(r!=null){if(typeof r!="object"||!("__html"in r))throw Error(U(61));if(n=r.__html,n!=null){if(a.children!=null)throw Error(U(60));e.innerHTML=n}}break;case"children":typeof r=="string"?Al(e,r):(typeof r=="number"||typeof r=="bigint")&&Al(e,""+r);break;case"onScroll":r!=null&&xe("scroll",e);break;case"onScrollEnd":r!=null&&xe("scrollend",e);break;case"onClick":r!=null&&(e.onclick=Xr);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!yE.hasOwnProperty(n))e:{if(n[0]==="o"&&n[1]==="n"&&(a=n.endsWith("Capture"),t=n.slice(2,a?n.length-7:void 0),i=e[mn]||null,i=i!=null?i[n]:null,typeof i=="function"&&e.removeEventListener(t,i,a),typeof r=="function")){typeof i!="function"&&i!==null&&(n in e?e[n]=null:e.hasAttribute(n)&&e.removeAttribute(n)),e.addEventListener(t,r,a);break e}n in e?e[n]=r:r===!0?e.setAttribute(n,""):Ff(e,n,r)}}}function qt(e,t,n){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":xe("error",e),xe("load",e);var r=!1,a=!1,i;for(i in n)if(n.hasOwnProperty(i)){var o=n[i];if(o!=null)switch(i){case"src":r=!0;break;case"srcSet":a=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(U(137,t));default:Be(e,t,i,o,n,null)}}a&&Be(e,t,"srcSet",n.srcSet,n,null),r&&Be(e,t,"src",n.src,n,null);return;case"input":xe("invalid",e);var l=i=o=a=null,s=null,u=null;for(r in n)if(n.hasOwnProperty(r)){var d=n[r];if(d!=null)switch(r){case"name":a=d;break;case"type":o=d;break;case"checked":s=d;break;case"defaultChecked":u=d;break;case"value":i=d;break;case"defaultValue":l=d;break;case"children":case"dangerouslySetInnerHTML":if(d!=null)throw Error(U(137,t));break;default:Be(e,t,r,d,n,null)}}bE(e,i,l,s,u,o,a,!1);return;case"select":xe("invalid",e),r=o=i=null;for(a in n)if(n.hasOwnProperty(a)&&(l=n[a],l!=null))switch(a){case"value":i=l;break;case"defaultValue":o=l;break;case"multiple":r=l;default:Be(e,t,a,l,n,null)}t=i,n=o,e.multiple=!!r,t!=null?el(e,!!r,t,!1):n!=null&&el(e,!!r,n,!0);return;case"textarea":xe("invalid",e),i=a=r=null;for(o in n)if(n.hasOwnProperty(o)&&(l=n[o],l!=null))switch(o){case"value":r=l;break;case"defaultValue":a=l;break;case"children":i=l;break;case"dangerouslySetInnerHTML":if(l!=null)throw Error(U(91));break;default:Be(e,t,o,l,n,null)}SE(e,r,a,i);return;case"option":for(s in n)if(n.hasOwnProperty(s)&&(r=n[s],r!=null))switch(s){case"selected":e.selected=r&&typeof r!="function"&&typeof r!="symbol";break;default:Be(e,t,s,r,n,null)}return;case"dialog":xe("beforetoggle",e),xe("toggle",e),xe("cancel",e),xe("close",e);break;case"iframe":case"object":xe("load",e);break;case"video":case"audio":for(r=0;r<Lu.length;r++)xe(Lu[r],e);break;case"image":xe("error",e),xe("load",e);break;case"details":xe("toggle",e);break;case"embed":case"source":case"link":xe("error",e),xe("load",e);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(u in n)if(n.hasOwnProperty(u)&&(r=n[u],r!=null))switch(u){case"children":case"dangerouslySetInnerHTML":throw Error(U(137,t));default:Be(e,t,u,r,n,null)}return;default:if(tb(t)){for(d in n)n.hasOwnProperty(d)&&(r=n[d],r!==void 0&&Mv(e,t,d,r,n,void 0));return}}for(l in n)n.hasOwnProperty(l)&&(r=n[l],r!=null&&Be(e,t,l,r,n,null))}function l$(e,t,n,r){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var a=null,i=null,o=null,l=null,s=null,u=null,d=null;for(p in n){var f=n[p];if(n.hasOwnProperty(p)&&f!=null)switch(p){case"checked":break;case"value":break;case"defaultValue":s=f;default:r.hasOwnProperty(p)||Be(e,t,p,null,r,f)}}for(var h in r){var p=r[h];if(f=n[h],r.hasOwnProperty(h)&&(p!=null||f!=null))switch(h){case"type":i=p;break;case"name":a=p;break;case"checked":u=p;break;case"defaultChecked":d=p;break;case"value":o=p;break;case"defaultValue":l=p;break;case"children":case"dangerouslySetInnerHTML":if(p!=null)throw Error(U(137,t));break;default:p!==f&&Be(e,t,h,p,r,f)}}nv(e,o,l,s,u,d,i,a);return;case"select":p=o=l=h=null;for(i in n)if(s=n[i],n.hasOwnProperty(i)&&s!=null)switch(i){case"value":break;case"multiple":p=s;default:r.hasOwnProperty(i)||Be(e,t,i,null,r,s)}for(a in r)if(i=r[a],s=n[a],r.hasOwnProperty(a)&&(i!=null||s!=null))switch(a){case"value":h=i;break;case"defaultValue":l=i;break;case"multiple":o=i;default:i!==s&&Be(e,t,a,i,r,s)}t=l,n=o,r=p,h!=null?el(e,!!n,h,!1):!!r!=!!n&&(t!=null?el(e,!!n,t,!0):el(e,!!n,n?[]:"",!1));return;case"textarea":p=h=null;for(l in n)if(a=n[l],n.hasOwnProperty(l)&&a!=null&&!r.hasOwnProperty(l))switch(l){case"value":break;case"children":break;default:Be(e,t,l,null,r,a)}for(o in r)if(a=r[o],i=n[o],r.hasOwnProperty(o)&&(a!=null||i!=null))switch(o){case"value":h=a;break;case"defaultValue":p=a;break;case"children":break;case"dangerouslySetInnerHTML":if(a!=null)throw Error(U(91));break;default:a!==i&&Be(e,t,o,a,r,i)}xE(e,h,p);return;case"option":for(var b in n)if(h=n[b],n.hasOwnProperty(b)&&h!=null&&!r.hasOwnProperty(b))switch(b){case"selected":e.selected=!1;break;default:Be(e,t,b,null,r,h)}for(s in r)if(h=r[s],p=n[s],r.hasOwnProperty(s)&&h!==p&&(h!=null||p!=null))switch(s){case"selected":e.selected=h&&typeof h!="function"&&typeof h!="symbol";break;default:Be(e,t,s,h,r,p)}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 v in n)h=n[v],n.hasOwnProperty(v)&&h!=null&&!r.hasOwnProperty(v)&&Be(e,t,v,null,r,h);for(u in r)if(h=r[u],p=n[u],r.hasOwnProperty(u)&&h!==p&&(h!=null||p!=null))switch(u){case"children":case"dangerouslySetInnerHTML":if(h!=null)throw Error(U(137,t));break;default:Be(e,t,u,h,r,p)}return;default:if(tb(t)){for(var x in n)h=n[x],n.hasOwnProperty(x)&&h!==void 0&&!r.hasOwnProperty(x)&&Mv(e,t,x,void 0,r,h);for(d in r)h=r[d],p=n[d],!r.hasOwnProperty(d)||h===p||h===void 0&&p===void 0||Mv(e,t,d,h,r,p);return}}for(var m in n)h=n[m],n.hasOwnProperty(m)&&h!=null&&!r.hasOwnProperty(m)&&Be(e,t,m,null,r,h);for(f in r)h=r[f],p=n[f],!r.hasOwnProperty(f)||h===p||h==null&&p==null||Be(e,t,f,h,r,p)}function MS(e){switch(e){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function s$(){if(typeof performance.getEntriesByType=="function"){for(var e=0,t=0,n=performance.getEntriesByType("resource"),r=0;r<n.length;r++){var a=n[r],i=a.transferSize,o=a.initiatorType,l=a.duration;if(i&&l&&MS(o)){for(o=0,l=a.responseEnd,r+=1;r<n.length;r++){var s=n[r],u=s.startTime;if(u>l)break;var d=s.transferSize,f=s.initiatorType;d&&MS(f)&&(s=s.responseEnd,o+=d*(s<l?1:(l-u)/(s-u)))}if(--r,t+=8*(i+o)/(a.duration/1e3),e++,10<e)break}}if(0<e)return t/e/1e6}return navigator.connection&&(e=navigator.connection.downlink,typeof e=="number")?e:5}var Rv=null,Pv=null;function Dd(e){return e.nodeType===9?e:e.ownerDocument}function RS(e){switch(e){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function ET(e,t){if(e===0)switch(t){case"svg":return 1;case"math":return 2;default:return 0}return e===1&&t==="foreignObject"?0:e}function $v(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.children=="bigint"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var ny=null;function u$(){var e=window.event;return e&&e.type==="popstate"?e===ny?!1:(ny=e,!0):(ny=null,!1)}var _T=typeof setTimeout=="function"?setTimeout:void 0,c$=typeof clearTimeout=="function"?clearTimeout:void 0,PS=typeof Promise=="function"?Promise:void 0,f$=typeof queueMicrotask=="function"?queueMicrotask:typeof PS<"u"?function(e){return PS.resolve(null).then(e).catch(d$)}:_T;function d$(e){setTimeout(function(){throw e})}function ui(e){return e==="head"}function $S(e,t){var n=t,r=0;do{var a=n.nextSibling;if(e.removeChild(n),a&&a.nodeType===8)if(n=a.data,n==="/$"||n==="/&"){if(r===0){e.removeChild(a),Pl(t);return}r--}else if(n==="$"||n==="$?"||n==="$~"||n==="$!"||n==="&")r++;else if(n==="html")Su(e.ownerDocument.documentElement);else if(n==="head"){n=e.ownerDocument.head,Su(n);for(var i=n.firstChild;i;){var o=i.nextSibling,l=i.nodeName;i[Lc]||l==="SCRIPT"||l==="STYLE"||l==="LINK"&&i.rel.toLowerCase()==="stylesheet"||n.removeChild(i),i=o}}else n==="body"&&Su(e.ownerDocument.body);n=a}while(n);Pl(t)}function kS(e,t){var n=e;e=0;do{var r=n.nextSibling;if(n.nodeType===1?t?(n._stashedDisplay=n.style.display,n.style.display="none"):(n.style.display=n._stashedDisplay||"",n.getAttribute("style")===""&&n.removeAttribute("style")):n.nodeType===3&&(t?(n._stashedText=n.nodeValue,n.nodeValue=""):n.nodeValue=n._stashedText||""),r&&r.nodeType===8)if(n=r.data,n==="/$"){if(e===0)break;e--}else n!=="$"&&n!=="$?"&&n!=="$~"&&n!=="$!"||e++;n=r}while(n)}function kv(e){var t=e.firstChild;for(t&&t.nodeType===10&&(t=t.nextSibling);t;){var n=t;switch(t=t.nextSibling,n.nodeName){case"HTML":case"HEAD":case"BODY":kv(n),eb(n);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(n.rel.toLowerCase()==="stylesheet")continue}e.removeChild(n)}}function h$(e,t,n,r){for(;e.nodeType===1;){var a=n;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!r&&(e.nodeName!=="INPUT"||e.type!=="hidden"))break}else if(r){if(!e[Lc])switch(t){case"meta":if(!e.hasAttribute("itemprop"))break;return e;case"link":if(i=e.getAttribute("rel"),i==="stylesheet"&&e.hasAttribute("data-precedence"))break;if(i!==a.rel||e.getAttribute("href")!==(a.href==null||a.href===""?null:a.href)||e.getAttribute("crossorigin")!==(a.crossOrigin==null?null:a.crossOrigin)||e.getAttribute("title")!==(a.title==null?null:a.title))break;return e;case"style":if(e.hasAttribute("data-precedence"))break;return e;case"script":if(i=e.getAttribute("src"),(i!==(a.src==null?null:a.src)||e.getAttribute("type")!==(a.type==null?null:a.type)||e.getAttribute("crossorigin")!==(a.crossOrigin==null?null:a.crossOrigin))&&i&&e.hasAttribute("async")&&!e.hasAttribute("itemprop"))break;return e;default:return e}}else if(t==="input"&&e.type==="hidden"){var i=a.name==null?null:""+a.name;if(a.type==="hidden"&&e.getAttribute("name")===i)return e}else return e;if(e=Qn(e.nextSibling),e===null)break}return null}function p$(e,t,n){if(t==="")return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!n||(e=Qn(e.nextSibling),e===null))return null;return e}function TT(e,t){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!t||(e=Qn(e.nextSibling),e===null))return null;return e}function Dv(e){return e.data==="$?"||e.data==="$~"}function Lv(e){return e.data==="$!"||e.data==="$?"&&e.ownerDocument.readyState!=="loading"}function m$(e,t){var n=e.ownerDocument;if(e.data==="$~")e._reactRetry=t;else if(e.data!=="$?"||n.readyState!=="loading")t();else{var r=function(){t(),n.removeEventListener("DOMContentLoaded",r)};n.addEventListener("DOMContentLoaded",r),e._reactRetry=r}}function Qn(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t==="$"||t==="$!"||t==="$?"||t==="$~"||t==="&"||t==="F!"||t==="F")break;if(t==="/$"||t==="/&")return null}}return e}var zv=null;function DS(e){e=e.nextSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="/$"||n==="/&"){if(t===0)return Qn(e.nextSibling);t--}else n!=="$"&&n!=="$!"&&n!=="$?"&&n!=="$~"&&n!=="&"||t++}e=e.nextSibling}return null}function LS(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="$"||n==="$!"||n==="$?"||n==="$~"||n==="&"){if(t===0)return e;t--}else n!=="/$"&&n!=="/&"||t++}e=e.previousSibling}return null}function NT(e,t,n){switch(t=Dd(n),e){case"html":if(e=t.documentElement,!e)throw Error(U(452));return e;case"head":if(e=t.head,!e)throw Error(U(453));return e;case"body":if(e=t.body,!e)throw Error(U(454));return e;default:throw Error(U(451))}}function Su(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);eb(e)}var Zn=new Map,zS=new Set;function Ld(e){return typeof e.getRootNode=="function"?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var ya=Ne.d;Ne.d={f:y$,r:v$,D:g$,C:b$,L:x$,m:S$,X:j$,S:w$,M:O$};function y$(){var e=ya.f(),t=fp();return e||t}function v$(e){var t=cs(e);t!==null&&t.tag===5&&t.type==="form"?w_(t):ya.r(e)}var ps=typeof document>"u"?null:document;function CT(e,t,n){var r=ps;if(r&&typeof t=="string"&&t){var a=Fn(t);a='link[rel="'+e+'"][href="'+a+'"]',typeof n=="string"&&(a+='[crossorigin="'+n+'"]'),zS.has(a)||(zS.add(a),e={rel:e,crossOrigin:n,href:t},r.querySelector(a)===null&&(t=r.createElement("link"),qt(t,"link",e),Ct(t),r.head.appendChild(t)))}}function g$(e){ya.D(e),CT("dns-prefetch",e,null)}function b$(e,t){ya.C(e,t),CT("preconnect",e,t)}function x$(e,t,n){ya.L(e,t,n);var r=ps;if(r&&e&&t){var a='link[rel="preload"][as="'+Fn(t)+'"]';t==="image"&&n&&n.imageSrcSet?(a+='[imagesrcset="'+Fn(n.imageSrcSet)+'"]',typeof n.imageSizes=="string"&&(a+='[imagesizes="'+Fn(n.imageSizes)+'"]')):a+='[href="'+Fn(e)+'"]';var i=a;switch(t){case"style":i=Rl(e);break;case"script":i=ms(e)}Zn.has(i)||(e=nt({rel:"preload",href:t==="image"&&n&&n.imageSrcSet?void 0:e,as:t},n),Zn.set(i,e),r.querySelector(a)!==null||t==="style"&&r.querySelector(Hc(i))||t==="script"&&r.querySelector(Fc(i))||(t=r.createElement("link"),qt(t,"link",e),Ct(t),r.head.appendChild(t)))}}function S$(e,t){ya.m(e,t);var n=ps;if(n&&e){var r=t&&typeof t.as=="string"?t.as:"script",a='link[rel="modulepreload"][as="'+Fn(r)+'"][href="'+Fn(e)+'"]',i=a;switch(r){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":i=ms(e)}if(!Zn.has(i)&&(e=nt({rel:"modulepreload",href:e},t),Zn.set(i,e),n.querySelector(a)===null)){switch(r){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(n.querySelector(Fc(i)))return}r=n.createElement("link"),qt(r,"link",e),Ct(r),n.head.appendChild(r)}}}function w$(e,t,n){ya.S(e,t,n);var r=ps;if(r&&e){var a=Jo(r).hoistableStyles,i=Rl(e);t=t||"default";var o=a.get(i);if(!o){var l={loading:0,preload:null};if(o=r.querySelector(Hc(i)))l.loading=5;else{e=nt({rel:"stylesheet",href:e,"data-precedence":t},n),(n=Zn.get(i))&&Bb(e,n);var s=o=r.createElement("link");Ct(s),qt(s,"link",e),s._p=new Promise(function(u,d){s.onload=u,s.onerror=d}),s.addEventListener("load",function(){l.loading|=1}),s.addEventListener("error",function(){l.loading|=2}),l.loading|=4,td(o,t,r)}o={type:"stylesheet",instance:o,count:1,state:l},a.set(i,o)}}}function j$(e,t){ya.X(e,t);var n=ps;if(n&&e){var r=Jo(n).hoistableScripts,a=ms(e),i=r.get(a);i||(i=n.querySelector(Fc(a)),i||(e=nt({src:e,async:!0},t),(t=Zn.get(a))&&Ib(e,t),i=n.createElement("script"),Ct(i),qt(i,"link",e),n.head.appendChild(i)),i={type:"script",instance:i,count:1,state:null},r.set(a,i))}}function O$(e,t){ya.M(e,t);var n=ps;if(n&&e){var r=Jo(n).hoistableScripts,a=ms(e),i=r.get(a);i||(i=n.querySelector(Fc(a)),i||(e=nt({src:e,async:!0,type:"module"},t),(t=Zn.get(a))&&Ib(e,t),i=n.createElement("script"),Ct(i),qt(i,"link",e),n.head.appendChild(i)),i={type:"script",instance:i,count:1,state:null},r.set(a,i))}}function BS(e,t,n,r){var a=(a=Ka.current)?Ld(a):null;if(!a)throw Error(U(446));switch(e){case"meta":case"title":return null;case"style":return typeof n.precedence=="string"&&typeof n.href=="string"?(t=Rl(n.href),n=Jo(a).hoistableStyles,r=n.get(t),r||(r={type:"style",instance:null,count:0,state:null},n.set(t,r)),r):{type:"void",instance:null,count:0,state:null};case"link":if(n.rel==="stylesheet"&&typeof n.href=="string"&&typeof n.precedence=="string"){e=Rl(n.href);var i=Jo(a).hoistableStyles,o=i.get(e);if(o||(a=a.ownerDocument||a,o={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},i.set(e,o),(i=a.querySelector(Hc(e)))&&!i._p&&(o.instance=i,o.state.loading=5),Zn.has(e)||(n={rel:"preload",as:"style",href:n.href,crossOrigin:n.crossOrigin,integrity:n.integrity,media:n.media,hrefLang:n.hrefLang,referrerPolicy:n.referrerPolicy},Zn.set(e,n),i||A$(a,e,n,o.state))),t&&r===null)throw Error(U(528,""));return o}if(t&&r!==null)throw Error(U(529,""));return null;case"script":return t=n.async,n=n.src,typeof n=="string"&&t&&typeof t!="function"&&typeof t!="symbol"?(t=ms(n),n=Jo(a).hoistableScripts,r=n.get(t),r||(r={type:"script",instance:null,count:0,state:null},n.set(t,r)),r):{type:"void",instance:null,count:0,state:null};default:throw Error(U(444,e))}}function Rl(e){return'href="'+Fn(e)+'"'}function Hc(e){return'link[rel="stylesheet"]['+e+"]"}function MT(e){return nt({},e,{"data-precedence":e.precedence,precedence:null})}function A$(e,t,n,r){e.querySelector('link[rel="preload"][as="style"]['+t+"]")?r.loading=1:(t=e.createElement("link"),r.preload=t,t.addEventListener("load",function(){return r.loading|=1}),t.addEventListener("error",function(){return r.loading|=2}),qt(t,"link",n),Ct(t),e.head.appendChild(t))}function ms(e){return'[src="'+Fn(e)+'"]'}function Fc(e){return"script[async]"+e}function IS(e,t,n){if(t.count++,t.instance===null)switch(t.type){case"style":var r=e.querySelector('style[data-href~="'+Fn(n.href)+'"]');if(r)return t.instance=r,Ct(r),r;var a=nt({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return r=(e.ownerDocument||e).createElement("style"),Ct(r),qt(r,"style",a),td(r,n.precedence,e),t.instance=r;case"stylesheet":a=Rl(n.href);var i=e.querySelector(Hc(a));if(i)return t.state.loading|=4,t.instance=i,Ct(i),i;r=MT(n),(a=Zn.get(a))&&Bb(r,a),i=(e.ownerDocument||e).createElement("link"),Ct(i);var o=i;return o._p=new Promise(function(l,s){o.onload=l,o.onerror=s}),qt(i,"link",r),t.state.loading|=4,td(i,n.precedence,e),t.instance=i;case"script":return i=ms(n.src),(a=e.querySelector(Fc(i)))?(t.instance=a,Ct(a),a):(r=n,(a=Zn.get(i))&&(r=nt({},n),Ib(r,a)),e=e.ownerDocument||e,a=e.createElement("script"),Ct(a),qt(a,"link",r),e.head.appendChild(a),t.instance=a);case"void":return null;default:throw Error(U(443,t.type))}else t.type==="stylesheet"&&!(t.state.loading&4)&&(r=t.instance,t.state.loading|=4,td(r,n.precedence,e));return t.instance}function td(e,t,n){for(var r=n.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),a=r.length?r[r.length-1]:null,i=a,o=0;o<r.length;o++){var l=r[o];if(l.dataset.precedence===t)i=l;else if(i!==a)break}i?i.parentNode.insertBefore(e,i.nextSibling):(t=n.nodeType===9?n.head:n,t.insertBefore(e,t.firstChild))}function Bb(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.title==null&&(e.title=t.title)}function Ib(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.integrity==null&&(e.integrity=t.integrity)}var nd=null;function US(e,t,n){if(nd===null){var r=new Map,a=nd=new Map;a.set(n,r)}else a=nd,r=a.get(n),r||(r=new Map,a.set(n,r));if(r.has(e))return r;for(r.set(e,null),n=n.getElementsByTagName(e),a=0;a<n.length;a++){var i=n[a];if(!(i[Lc]||i[zt]||e==="link"&&i.getAttribute("rel")==="stylesheet")&&i.namespaceURI!=="http://www.w3.org/2000/svg"){var o=i.getAttribute(t)||"";o=e+o;var l=r.get(o);l?l.push(i):r.set(o,[i])}}return r}function qS(e,t,n){e=e.ownerDocument||e,e.head.insertBefore(n,t==="title"?e.querySelector("head > title"):null)}function E$(e,t,n){if(n===1||t.itemProp!=null)return!1;switch(e){case"meta":case"title":return!0;case"style":if(typeof t.precedence!="string"||typeof t.href!="string"||t.href==="")break;return!0;case"link":if(typeof t.rel!="string"||typeof t.href!="string"||t.href===""||t.onLoad||t.onError)break;switch(t.rel){case"stylesheet":return e=t.disabled,typeof t.precedence=="string"&&e==null;default:return!0}case"script":if(t.async&&typeof t.async!="function"&&typeof t.async!="symbol"&&!t.onLoad&&!t.onError&&t.src&&typeof t.src=="string")return!0}return!1}function RT(e){return!(e.type==="stylesheet"&&!(e.state.loading&3))}function _$(e,t,n,r){if(n.type==="stylesheet"&&(typeof r.media!="string"||matchMedia(r.media).matches!==!1)&&!(n.state.loading&4)){if(n.instance===null){var a=Rl(r.href),i=t.querySelector(Hc(a));if(i){t=i._p,t!==null&&typeof t=="object"&&typeof t.then=="function"&&(e.count++,e=zd.bind(e),t.then(e,e)),n.state.loading|=4,n.instance=i,Ct(i);return}i=t.ownerDocument||t,r=MT(r),(a=Zn.get(a))&&Bb(r,a),i=i.createElement("link"),Ct(i);var o=i;o._p=new Promise(function(l,s){o.onload=l,o.onerror=s}),qt(i,"link",r),n.instance=i}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(n,t),(t=n.state.preload)&&!(n.state.loading&3)&&(e.count++,n=zd.bind(e),t.addEventListener("load",n),t.addEventListener("error",n))}}var ry=0;function T$(e,t){return e.stylesheets&&e.count===0&&rd(e,e.stylesheets),0<e.count||0<e.imgCount?function(n){var r=setTimeout(function(){if(e.stylesheets&&rd(e,e.stylesheets),e.unsuspend){var i=e.unsuspend;e.unsuspend=null,i()}},6e4+t);0<e.imgBytes&&ry===0&&(ry=62500*s$());var a=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&rd(e,e.stylesheets),e.unsuspend)){var i=e.unsuspend;e.unsuspend=null,i()}},(e.imgBytes>ry?50:800)+t);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(r),clearTimeout(a)}}:null}function zd(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)rd(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var Bd=null;function rd(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,Bd=new Map,t.forEach(N$,e),Bd=null,zd.call(e))}function N$(e,t){if(!(t.state.loading&4)){var n=Bd.get(e);if(n)var r=n.get(null);else{n=new Map,Bd.set(e,n);for(var a=e.querySelectorAll("link[data-precedence],style[data-precedence]"),i=0;i<a.length;i++){var o=a[i];(o.nodeName==="LINK"||o.getAttribute("media")!=="not all")&&(n.set(o.dataset.precedence,o),r=o)}r&&n.set(null,r)}a=t.instance,o=a.getAttribute("data-precedence"),i=n.get(o)||r,i===r&&n.set(null,a),n.set(o,a),this.count++,r=zd.bind(this),a.addEventListener("load",r),a.addEventListener("error",r),i?i.parentNode.insertBefore(a,i.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(a,e.firstChild)),t.state.loading|=4}}var Bu={$$typeof:Vr,Provider:null,Consumer:null,_currentValue:Fi,_currentValue2:Fi,_threadCount:0};function C$(e,t,n,r,a,i,o,l,s){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=Em(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Em(0),this.hiddenUpdates=Em(null),this.identifierPrefix=r,this.onUncaughtError=a,this.onCaughtError=i,this.onRecoverableError=o,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=s,this.incompleteTransitions=new Map}function PT(e,t,n,r,a,i,o,l,s,u,d,f){return e=new C$(e,t,n,o,s,u,d,f,l),t=1,i===!0&&(t|=24),i=An(3,null,null,t),e.current=i,i.stateNode=e,t=db(),t.refCount++,e.pooledCache=t,t.refCount++,i.memoizedState={element:r,isDehydrated:n,cache:t},mb(i),e}function $T(e){return e?(e=Ho,e):Ho}function kT(e,t,n,r,a,i){a=$T(a),r.context===null?r.context=a:r.pendingContext=a,r=Va(t),r.payload={element:n},i=i===void 0?null:i,i!==null&&(r.callback=i),n=Xa(e,r,t),n!==null&&(hn(n,e,t),hu(n,e,t))}function HS(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function Ub(e,t){HS(e,t),(e=e.alternate)&&HS(e,t)}function DT(e){if(e.tag===13||e.tag===31){var t=mo(e,67108864);t!==null&&hn(t,e,67108864),Ub(e,67108864)}}function FS(e){if(e.tag===13||e.tag===31){var t=Mn();t=Z0(t);var n=mo(e,t);n!==null&&hn(n,e,t),Ub(e,t)}}var Id=!0;function M$(e,t,n,r){var a=ie.T;ie.T=null;var i=Ne.p;try{Ne.p=2,qb(e,t,n,r)}finally{Ne.p=i,ie.T=a}}function R$(e,t,n,r){var a=ie.T;ie.T=null;var i=Ne.p;try{Ne.p=8,qb(e,t,n,r)}finally{Ne.p=i,ie.T=a}}function qb(e,t,n,r){if(Id){var a=Bv(r);if(a===null)ty(e,t,r,Ud,n),GS(e,r);else if($$(a,e,t,n,r))r.stopPropagation();else if(GS(e,r),t&4&&-1<P$.indexOf(e)){for(;a!==null;){var i=cs(a);if(i!==null)switch(i.tag){case 3:if(i=i.stateNode,i.current.memoizedState.isDehydrated){var o=wi(i.pendingLanes);if(o!==0){var l=i;for(l.pendingLanes|=2,l.entangledLanes|=2;o;){var s=1<<31-Cn(o);l.entanglements[1]|=s,o&=~s}Nr(i),!(Te&6)&&(Cd=Tn()+500,qc(0))}}break;case 31:case 13:l=mo(i,2),l!==null&&hn(l,i,2),fp(),Ub(i,2)}if(i=Bv(r),i===null&&ty(e,t,r,Ud,n),i===a)break;a=i}a!==null&&r.stopPropagation()}else ty(e,t,r,null,n)}}function Bv(e){return e=nb(e),Hb(e)}var Ud=null;function Hb(e){if(Ud=null,e=Lo(e),e!==null){var t=Pc(e);if(t===null)e=null;else{var n=t.tag;if(n===13){if(e=nE(t),e!==null)return e;e=null}else if(n===31){if(e=rE(t),e!==null)return e;e=null}else if(n===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return Ud=e,null}function LT(e){switch(e){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(gP()){case lE:return 2;case sE:return 8;case yd:case bP:return 32;case uE:return 268435456;default:return 32}default:return 32}}var Iv=!1,Za=null,Ja=null,ei=null,Iu=new Map,Uu=new Map,Ca=[],P$="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 GS(e,t){switch(e){case"focusin":case"focusout":Za=null;break;case"dragenter":case"dragleave":Ja=null;break;case"mouseover":case"mouseout":ei=null;break;case"pointerover":case"pointerout":Iu.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":Uu.delete(t.pointerId)}}function qs(e,t,n,r,a,i){return e===null||e.nativeEvent!==i?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:i,targetContainers:[a]},t!==null&&(t=cs(t),t!==null&&DT(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,a!==null&&t.indexOf(a)===-1&&t.push(a),e)}function $$(e,t,n,r,a){switch(t){case"focusin":return Za=qs(Za,e,t,n,r,a),!0;case"dragenter":return Ja=qs(Ja,e,t,n,r,a),!0;case"mouseover":return ei=qs(ei,e,t,n,r,a),!0;case"pointerover":var i=a.pointerId;return Iu.set(i,qs(Iu.get(i)||null,e,t,n,r,a)),!0;case"gotpointercapture":return i=a.pointerId,Uu.set(i,qs(Uu.get(i)||null,e,t,n,r,a)),!0}return!1}function zT(e){var t=Lo(e.target);if(t!==null){var n=Pc(t);if(n!==null){if(t=n.tag,t===13){if(t=nE(n),t!==null){e.blockedOn=t,N1(e.priority,function(){FS(n)});return}}else if(t===31){if(t=rE(n),t!==null){e.blockedOn=t,N1(e.priority,function(){FS(n)});return}}else if(t===3&&n.stateNode.current.memoizedState.isDehydrated){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function ad(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=Bv(e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);av=r,n.target.dispatchEvent(r),av=null}else return t=cs(n),t!==null&&DT(t),e.blockedOn=n,!1;t.shift()}return!0}function KS(e,t,n){ad(e)&&n.delete(t)}function k$(){Iv=!1,Za!==null&&ad(Za)&&(Za=null),Ja!==null&&ad(Ja)&&(Ja=null),ei!==null&&ad(ei)&&(ei=null),Iu.forEach(KS),Uu.forEach(KS)}function jf(e,t){e.blockedOn===t&&(e.blockedOn=null,Iv||(Iv=!0,At.unstable_scheduleCallback(At.unstable_NormalPriority,k$)))}var Of=null;function YS(e){Of!==e&&(Of=e,At.unstable_scheduleCallback(At.unstable_NormalPriority,function(){Of===e&&(Of=null);for(var t=0;t<e.length;t+=3){var n=e[t],r=e[t+1],a=e[t+2];if(typeof r!="function"){if(Hb(r||n)===null)continue;break}var i=cs(n);i!==null&&(e.splice(t,3),t-=3,xv(i,{pending:!0,data:a,method:n.method,action:r},r,a))}}))}function Pl(e){function t(s){return jf(s,e)}Za!==null&&jf(Za,e),Ja!==null&&jf(Ja,e),ei!==null&&jf(ei,e),Iu.forEach(t),Uu.forEach(t);for(var n=0;n<Ca.length;n++){var r=Ca[n];r.blockedOn===e&&(r.blockedOn=null)}for(;0<Ca.length&&(n=Ca[0],n.blockedOn===null);)zT(n),n.blockedOn===null&&Ca.shift();if(n=(e.ownerDocument||e).$$reactFormReplay,n!=null)for(r=0;r<n.length;r+=3){var a=n[r],i=n[r+1],o=a[mn]||null;if(typeof i=="function")o||YS(n);else if(o){var l=null;if(i&&i.hasAttribute("formAction")){if(a=i,o=i[mn]||null)l=o.formAction;else if(Hb(a)!==null)continue}else l=o.action;typeof l=="function"?n[r+1]=l:(n.splice(r,3),r-=3),YS(n)}}}function BT(){function e(i){i.canIntercept&&i.info==="react-transition"&&i.intercept({handler:function(){return new Promise(function(o){return a=o})},focusReset:"manual",scroll:"manual"})}function t(){a!==null&&(a(),a=null),r||setTimeout(n,20)}function n(){if(!r&&!navigation.transition){var i=navigation.currentEntry;i&&i.url!=null&&navigation.navigate(i.url,{state:i.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var r=!1,a=null;return navigation.addEventListener("navigate",e),navigation.addEventListener("navigatesuccess",t),navigation.addEventListener("navigateerror",t),setTimeout(n,100),function(){r=!0,navigation.removeEventListener("navigate",e),navigation.removeEventListener("navigatesuccess",t),navigation.removeEventListener("navigateerror",t),a!==null&&(a(),a=null)}}}function Fb(e){this._internalRoot=e}pp.prototype.render=Fb.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(U(409));var n=t.current,r=Mn();kT(n,r,e,t,null,null)};pp.prototype.unmount=Fb.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;kT(e.current,2,null,e,null,null),fp(),t[us]=null}};function pp(e){this._internalRoot=e}pp.prototype.unstable_scheduleHydration=function(e){if(e){var t=pE();e={blockedOn:null,target:e,priority:t};for(var n=0;n<Ca.length&&t!==0&&t<Ca[n].priority;n++);Ca.splice(n,0,e),n===0&&zT(e)}};var VS=eE.version;if(VS!=="19.2.7")throw Error(U(527,VS,"19.2.7"));Ne.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(U(188)):(e=Object.keys(e).join(","),Error(U(268,e)));return e=fP(t),e=e!==null?aE(e):null,e=e===null?null:e.stateNode,e};var D$={bundleType:0,version:"19.2.7",rendererPackageName:"react-dom",currentDispatcherRef:ie,reconcilerVersion:"19.2.7"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Af=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Af.isDisabled&&Af.supportsFiber)try{$c=Af.inject(D$),Nn=Af}catch{}}Wh.createRoot=function(e,t){if(!tE(e))throw Error(U(299));var n=!1,r="",a=C_,i=M_,o=R_;return t!=null&&(t.unstable_strictMode===!0&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onUncaughtError!==void 0&&(a=t.onUncaughtError),t.onCaughtError!==void 0&&(i=t.onCaughtError),t.onRecoverableError!==void 0&&(o=t.onRecoverableError)),t=PT(e,1,!1,null,null,n,r,null,a,i,o,BT),e[us]=t.current,zb(e),new Fb(t)};Wh.hydrateRoot=function(e,t,n){if(!tE(e))throw Error(U(299));var r=!1,a="",i=C_,o=M_,l=R_,s=null;return n!=null&&(n.unstable_strictMode===!0&&(r=!0),n.identifierPrefix!==void 0&&(a=n.identifierPrefix),n.onUncaughtError!==void 0&&(i=n.onUncaughtError),n.onCaughtError!==void 0&&(o=n.onCaughtError),n.onRecoverableError!==void 0&&(l=n.onRecoverableError),n.formState!==void 0&&(s=n.formState)),t=PT(e,1,!0,t,n??null,r,a,s,i,o,l,BT),t.context=$T(null),n=t.current,r=Mn(),r=Z0(r),a=Va(r),a.callback=null,Xa(n,a,r),n=r,t.current.lanes=n,Dc(t,n),Nr(t),e[us]=t.current,zb(e),new pp(t)};Wh.version="19.2.7";function IT(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(IT)}catch(e){console.error(e)}}IT(),VA.exports=Wh;var L$=VA.exports;/**
 * react-router v7.17.0
 *
 * 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 XS="popstate";function QS(e){return typeof e=="object"&&e!=null&&"pathname"in e&&"search"in e&&"hash"in e&&"state"in e&&"key"in e}function z$(e={}){function t(r,a){var u;let i=(u=a.state)==null?void 0:u.masked,{pathname:o,search:l,hash:s}=i||r.location;return Uv("",{pathname:o,search:l,hash:s},a.state&&a.state.usr||null,a.state&&a.state.key||"default",i?{pathname:r.location.pathname,search:r.location.search,hash:r.location.hash}:void 0)}function n(r,a){return typeof a=="string"?a:qu(a)}return I$(t,n,null,e)}function it(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function dr(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function B$(){return Math.random().toString(36).substring(2,10)}function WS(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 Uv(e,t,n=null,r,a){return{pathname:typeof e=="string"?e:e.pathname,search:"",hash:"",...typeof t=="string"?ys(t):t,state:n,key:t&&t.key||r||B$(),mask:a}}function qu({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 ys(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 I$(e,t,n,r={}){let{window:a=document.defaultView,v5Compat:i=!1}=r,o=a.history,l="POP",s=null,u=d();u==null&&(u=0,o.replaceState({...o.state,idx:u},""));function d(){return(o.state||{idx:null}).idx}function f(){l="POP";let x=d(),m=x==null?null:x-u;u=x,s&&s({action:l,location:v.location,delta:m})}function h(x,m){l="PUSH";let y=QS(x)?x:Uv(v.location,x,m);u=d()+1;let g=WS(y,u),S=v.createHref(y.mask||y);try{o.pushState(g,"",S)}catch(w){if(w instanceof DOMException&&w.name==="DataCloneError")throw w;a.location.assign(S)}i&&s&&s({action:l,location:v.location,delta:1})}function p(x,m){l="REPLACE";let y=QS(x)?x:Uv(v.location,x,m);u=d();let g=WS(y,u),S=v.createHref(y.mask||y);o.replaceState(g,"",S),i&&s&&s({action:l,location:v.location,delta:0})}function b(x){return U$(a,x)}let v={get action(){return l},get location(){return e(a,o)},listen(x){if(s)throw new Error("A history only accepts one active listener");return a.addEventListener(XS,f),s=x,()=>{a.removeEventListener(XS,f),s=null}},createHref(x){return t(a,x)},createURL:b,encodeLocation(x){let m=b(x);return{pathname:m.pathname,search:m.search,hash:m.hash}},push:h,replace:p,go(x){return o.go(x)}};return v}function U$(e,t,n=!1){let r="http://localhost";e&&(r=e.location.origin!=="null"?e.location.origin:e.location.href),it(r,"No window.location.(origin|href) available to create URL");let a=typeof t=="string"?t:qu(t);return a=a.replace(/ $/,"%20"),!n&&a.startsWith("//")&&(a=r+a),new URL(a,r)}function UT(e,t,n="/"){return q$(e,t,n,!1)}function q$(e,t,n,r,a){let i=typeof t=="string"?ys(t):t,o=fa(i.pathname||"/",n);if(o==null)return null;let l=H$(e),s=null,u=tk(o);for(let d=0;s==null&&d<l.length;++d)s=J$(l[d],u,r);return s}function H$(e){let t=qT(e);return F$(t),t}function qT(e,t=[],n=[],r="",a=!1){let i=(o,l,s=a,u)=>{let d={relativePath:u===void 0?o.path||"":u,caseSensitive:o.caseSensitive===!0,childrenIndex:l,route:o};if(d.relativePath.startsWith("/")){if(!d.relativePath.startsWith(r)&&s)return;it(d.relativePath.startsWith(r),`Absolute route path "${d.relativePath}" nested under path "${r}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),d.relativePath=d.relativePath.slice(r.length)}let f=fr([r,d.relativePath]),h=n.concat(d);o.children&&o.children.length>0&&(it(o.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${f}".`),qT(o.children,t,h,f,s)),!(o.path==null&&!o.index)&&t.push({path:f,score:W$(f,o.index),routesMeta:h})};return e.forEach((o,l)=>{var s;if(o.path===""||!((s=o.path)!=null&&s.includes("?")))i(o,l);else for(let u of HT(o.path))i(o,l,!0,u)}),t}function HT(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,a=n.endsWith("?"),i=n.replace(/\?$/,"");if(r.length===0)return a?[i,""]:[i];let o=HT(r.join("/")),l=[];return l.push(...o.map(s=>s===""?i:[i,s].join("/"))),a&&l.push(...o),l.map(s=>e.startsWith("/")&&s===""?"/":s)}function F$(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:Z$(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}var G$=/^:[\w-]+$/,K$=3,Y$=2,V$=1,X$=10,Q$=-2,ZS=e=>e==="*";function W$(e,t){let n=e.split("/"),r=n.length;return n.some(ZS)&&(r+=Q$),t&&(r+=Y$),n.filter(a=>!ZS(a)).reduce((a,i)=>a+(G$.test(i)?K$:i===""?V$:X$),r)}function Z$(e,t){return e.length===t.length&&e.slice(0,-1).every((r,a)=>r===t[a])?e[e.length-1]-t[t.length-1]:0}function J$(e,t,n=!1){let{routesMeta:r}=e,a={},i="/",o=[];for(let l=0;l<r.length;++l){let s=r[l],u=l===r.length-1,d=i==="/"?t:t.slice(i.length)||"/",f=qd({path:s.relativePath,caseSensitive:s.caseSensitive,end:u},d),h=s.route;if(!f&&u&&n&&!r[r.length-1].route.index&&(f=qd({path:s.relativePath,caseSensitive:s.caseSensitive,end:!1},d)),!f)return null;Object.assign(a,f.params),o.push({params:a,pathname:fr([i,f.pathname]),pathnameBase:ik(fr([i,f.pathnameBase])),route:h}),f.pathnameBase!=="/"&&(i=fr([i,f.pathnameBase]))}return o}function qd(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=ek(e.path,e.caseSensitive,e.end),a=t.match(n);if(!a)return null;let i=a[0],o=i.replace(/(.)\/+$/,"$1"),l=a.slice(1);return{params:r.reduce((u,{paramName:d,isOptional:f},h)=>{if(d==="*"){let b=l[h]||"";o=i.slice(0,i.length-b.length).replace(/(.)\/+$/,"$1")}const p=l[h];return f&&!p?u[d]=void 0:u[d]=(p||"").replace(/%2F/g,"/"),u},{}),pathname:i,pathnameBase:o,pattern:e}}function ek(e,t=!1,n=!0){dr(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=[],a="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(o,l,s,u,d)=>{if(r.push({paramName:l,isOptional:s!=null}),s){let f=d.charAt(u+o.length);return f&&f!=="/"?"/([^\\/]*)":"(?:/([^\\/]*))?"}return"/([^\\/]+)"}).replace(/\/([\w-]+)\?(\/|$)/g,"(/$1)?$2");return e.endsWith("*")?(r.push({paramName:"*"}),a+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?a+="\\/*$":e!==""&&e!=="/"&&(a+="(?:(?=\\/|$))"),[new RegExp(a,t?void 0:"i"),r]}function tk(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return dr(!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 fa(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)||"/"}var nk=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i;function rk(e,t="/"){let{pathname:n,search:r="",hash:a=""}=typeof e=="string"?ys(e):e,i;return n?(n=FT(n),n.startsWith("/")?i=JS(n.substring(1),"/"):i=JS(n,t)):i=t,{pathname:i,search:ok(r),hash:lk(a)}}function JS(e,t){let n=Hd(t).split("/");return e.split("/").forEach(a=>{a===".."?n.length>1&&n.pop():a!=="."&&n.push(a)}),n.length>1?n.join("/"):"/"}function ay(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 ak(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function Gb(e){let t=ak(e);return t.map((n,r)=>r===t.length-1?n.pathname:n.pathnameBase)}function mp(e,t,n,r=!1){let a;typeof e=="string"?a=ys(e):(a={...e},it(!a.pathname||!a.pathname.includes("?"),ay("?","pathname","search",a)),it(!a.pathname||!a.pathname.includes("#"),ay("#","pathname","hash",a)),it(!a.search||!a.search.includes("#"),ay("#","search","hash",a)));let i=e===""||a.pathname==="",o=i?"/":a.pathname,l;if(o==null)l=n;else{let f=t.length-1;if(!r&&o.startsWith("..")){let h=o.split("/");for(;h[0]==="..";)h.shift(),f-=1;a.pathname=h.join("/")}l=f>=0?t[f]:"/"}let s=rk(a,l),u=o&&o!=="/"&&o.endsWith("/"),d=(i||o===".")&&n.endsWith("/");return!s.pathname.endsWith("/")&&(u||d)&&(s.pathname+="/"),s}var FT=e=>e.replace(/\/\/+/g,"/"),fr=e=>FT(e.join("/")),Hd=e=>e.replace(/\/+$/,""),ik=e=>Hd(e).replace(/^\/*/,"/"),ok=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,lk=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e,sk=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 uk(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}function ck(e){let t=e.map(n=>n.route.path).filter(Boolean);return fr(t)||"/"}var GT=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function KT(e,t){let n=e;if(typeof n!="string"||!nk.test(n))return{absoluteURL:void 0,isExternal:!1,to:n};let r=n,a=!1;if(GT)try{let i=new URL(window.location.href),o=n.startsWith("//")?new URL(i.protocol+n):new URL(n),l=fa(o.pathname,t);o.origin===i.origin&&l!=null?n=l+o.search+o.hash:a=!0}catch{dr(!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:a,to:n}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");var YT=["POST","PUT","PATCH","DELETE"];new Set(YT);var fk=["GET",...YT];new Set(fk);var vs=O.createContext(null);vs.displayName="DataRouter";var yp=O.createContext(null);yp.displayName="DataRouterState";var VT=O.createContext(!1);function dk(){return O.useContext(VT)}var XT=O.createContext({isTransitioning:!1});XT.displayName="ViewTransition";var hk=O.createContext(new Map);hk.displayName="Fetchers";var pk=O.createContext(null);pk.displayName="Await";var kn=O.createContext(null);kn.displayName="Navigation";var Gc=O.createContext(null);Gc.displayName="Location";var pr=O.createContext({outlet:null,matches:[],isDataRoute:!1});pr.displayName="Route";var Kb=O.createContext(null);Kb.displayName="RouteError";var QT="REACT_ROUTER_ERROR",mk="REDIRECT",yk="ROUTE_ERROR_RESPONSE";function vk(e){if(e.startsWith(`${QT}:${mk}:{`))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 gk(e){if(e.startsWith(`${QT}:${yk}:{`))try{let t=JSON.parse(e.slice(40));if(typeof t=="object"&&t&&typeof t.status=="number"&&typeof t.statusText=="string")return new sk(t.status,t.statusText,t.data)}catch{}}function bk(e,{relative:t}={}){it(gs(),"useHref() may be used only in the context of a <Router> component.");let{basename:n,navigator:r}=O.useContext(kn),{hash:a,pathname:i,search:o}=Kc(e,{relative:t}),l=i;return n!=="/"&&(l=i==="/"?n:fr([n,i])),r.createHref({pathname:l,search:o,hash:a})}function gs(){return O.useContext(Gc)!=null}function Cr(){return it(gs(),"useLocation() may be used only in the context of a <Router> component."),O.useContext(Gc).location}var WT="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function ZT(e){O.useContext(kn).static||O.useLayoutEffect(e)}function vp(){let{isDataRoute:e}=O.useContext(pr);return e?$k():xk()}function xk(){it(gs(),"useNavigate() may be used only in the context of a <Router> component.");let e=O.useContext(vs),{basename:t,navigator:n}=O.useContext(kn),{matches:r}=O.useContext(pr),{pathname:a}=Cr(),i=JSON.stringify(Gb(r)),o=O.useRef(!1);return ZT(()=>{o.current=!0}),O.useCallback((s,u={})=>{if(dr(o.current,WT),!o.current)return;if(typeof s=="number"){n.go(s);return}let d=mp(s,JSON.parse(i),a,u.relative==="path");e==null&&t!=="/"&&(d.pathname=d.pathname==="/"?t:fr([t,d.pathname])),(u.replace?n.replace:n.push)(d,u.state,u)},[t,n,i,a,e])}var Sk=O.createContext(null);function wk(e){let t=O.useContext(pr).outlet;return O.useMemo(()=>t&&O.createElement(Sk.Provider,{value:e},t),[t,e])}function Kc(e,{relative:t}={}){let{matches:n}=O.useContext(pr),{pathname:r}=Cr(),a=JSON.stringify(Gb(n));return O.useMemo(()=>mp(e,JSON.parse(a),r,t==="path"),[e,a,r,t])}function jk(e,t){return JT(e,t)}function JT(e,t,n){var x;it(gs(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:r}=O.useContext(kn),{matches:a}=O.useContext(pr),i=a[a.length-1],o=i?i.params:{},l=i?i.pathname:"/",s=i?i.pathnameBase:"/",u=i&&i.route;{let m=u&&u.path||"";tN(l,!u||m.endsWith("*")||m.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${l}" (under <Route path="${m}">) 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="${m}"> to <Route path="${m==="/"?"*":`${m}/*`}">.`)}let d=Cr(),f;if(t){let m=typeof t=="string"?ys(t):t;it(s==="/"||((x=m.pathname)==null?void 0:x.startsWith(s)),`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 "${s}" but pathname "${m.pathname}" was given in the \`location\` prop.`),f=m}else f=d;let h=f.pathname||"/",p=h;if(s!=="/"){let m=s.replace(/^\//,"").split("/");p="/"+h.replace(/^\//,"").split("/").slice(m.length).join("/")}let b=n&&n.state.matches.length?n.state.matches.map(m=>Object.assign(m,{route:n.manifest[m.route.id]||m.route})):UT(e,{pathname:p});dr(u||b!=null,`No routes matched location "${f.pathname}${f.search}${f.hash}" `),dr(b==null||b[b.length-1].route.element!==void 0||b[b.length-1].route.Component!==void 0||b[b.length-1].route.lazy!==void 0,`Matched leaf route at location "${f.pathname}${f.search}${f.hash}" does not have an element or Component. This means it will render an <Outlet /> with a null value by default resulting in an "empty" page.`);let v=Tk(b&&b.map(m=>Object.assign({},m,{params:Object.assign({},o,m.params),pathname:fr([s,r.encodeLocation?r.encodeLocation(m.pathname.replace(/%/g,"%25").replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:m.pathname]),pathnameBase:m.pathnameBase==="/"?s:fr([s,r.encodeLocation?r.encodeLocation(m.pathnameBase.replace(/%/g,"%25").replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:m.pathnameBase])})),a,n);return t&&v?O.createElement(Gc.Provider,{value:{location:{pathname:"/",search:"",hash:"",state:null,key:"default",mask:void 0,...f},navigationType:"POP"}},v):v}function Ok(){let e=Pk(),t=uk(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)",a={padding:"0.5rem",backgroundColor:r},i={padding:"2px 4px",backgroundColor:r},o=null;return console.error("Error handled by React Router default ErrorBoundary:",e),o=O.createElement(O.Fragment,null,O.createElement("p",null,"💿 Hey developer 👋"),O.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",O.createElement("code",{style:i},"ErrorBoundary")," or"," ",O.createElement("code",{style:i},"errorElement")," prop on your route.")),O.createElement(O.Fragment,null,O.createElement("h2",null,"Unexpected Application Error!"),O.createElement("h3",{style:{fontStyle:"italic"}},t),n?O.createElement("pre",{style:a},n):null,o)}var Ak=O.createElement(Ok,null),eN=class extends O.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=gk(e.digest);n&&(e=n)}let t=e!==void 0?O.createElement(pr.Provider,{value:this.props.routeContext},O.createElement(Kb.Provider,{value:e,children:this.props.component})):this.props.children;return this.context?O.createElement(Ek,{error:e},t):t}};eN.contextType=VT;var iy=new WeakMap;function Ek({children:e,error:t}){let{basename:n}=O.useContext(kn);if(typeof t=="object"&&t&&"digest"in t&&typeof t.digest=="string"){let r=vk(t.digest);if(r){let a=iy.get(t);if(a)throw a;let i=KT(r.location,n);if(GT&&!iy.get(t))if(i.isExternal||r.reloadDocument)window.location.href=i.absoluteURL||i.to;else{const o=Promise.resolve().then(()=>window.__reactRouterDataRouter.navigate(i.to,{replace:r.replace}));throw iy.set(t,o),o}return O.createElement("meta",{httpEquiv:"refresh",content:`0;url=${i.absoluteURL||i.to}`})}}return e}function _k({routeContext:e,match:t,children:n}){let r=O.useContext(vs);return r&&r.static&&r.staticContext&&(t.route.errorElement||t.route.ErrorBoundary)&&(r.staticContext._deepestRenderedBoundaryId=t.route.id),O.createElement(pr.Provider,{value:e},n)}function Tk(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 a=e,i=r==null?void 0:r.errors;if(i!=null){let d=a.findIndex(f=>f.route.id&&(i==null?void 0:i[f.route.id])!==void 0);it(d>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(i).join(",")}`),a=a.slice(0,Math.min(a.length,d+1))}let o=!1,l=-1;if(n&&r){o=r.renderFallback;for(let d=0;d<a.length;d++){let f=a[d];if((f.route.HydrateFallback||f.route.hydrateFallbackElement)&&(l=d),f.route.id){let{loaderData:h,errors:p}=r,b=f.route.loader&&!h.hasOwnProperty(f.route.id)&&(!p||p[f.route.id]===void 0);if(f.route.lazy||b){n.isStatic&&(o=!0),l>=0?a=a.slice(0,l+1):a=[a[0]];break}}}}let s=n==null?void 0:n.onError,u=r&&s?(d,f)=>{var h,p;s(d,{location:r.location,params:((p=(h=r.matches)==null?void 0:h[0])==null?void 0:p.params)??{},pattern:ck(r.matches),errorInfo:f})}:void 0;return a.reduceRight((d,f,h)=>{let p,b=!1,v=null,x=null;r&&(p=i&&f.route.id?i[f.route.id]:void 0,v=f.route.errorElement||Ak,o&&(l<0&&h===0?(tN("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),b=!0,x=null):l===h&&(b=!0,x=f.route.hydrateFallbackElement||null)));let m=t.concat(a.slice(0,h+1)),y=()=>{let g;return p?g=v:b?g=x:f.route.Component?g=O.createElement(f.route.Component,null):f.route.element?g=f.route.element:g=d,O.createElement(_k,{match:f,routeContext:{outlet:d,matches:m,isDataRoute:r!=null},children:g})};return r&&(f.route.ErrorBoundary||f.route.errorElement||h===0)?O.createElement(eN,{location:r.location,revalidation:r.revalidation,component:v,error:p,children:y(),routeContext:{outlet:null,matches:m,isDataRoute:!0},onError:u}):y()},null)}function Yb(e){return`${e} must be used within a data router.  See https://reactrouter.com/en/main/routers/picking-a-router.`}function Nk(e){let t=O.useContext(vs);return it(t,Yb(e)),t}function Ck(e){let t=O.useContext(yp);return it(t,Yb(e)),t}function Mk(e){let t=O.useContext(pr);return it(t,Yb(e)),t}function Vb(e){let t=Mk(e),n=t.matches[t.matches.length-1];return it(n.route.id,`${e} can only be used on routes that contain a unique "id"`),n.route.id}function Rk(){return Vb("useRouteId")}function Pk(){var r;let e=O.useContext(Kb),t=Ck("useRouteError"),n=Vb("useRouteError");return e!==void 0?e:(r=t.errors)==null?void 0:r[n]}function $k(){let{router:e}=Nk("useNavigate"),t=Vb("useNavigate"),n=O.useRef(!1);return ZT(()=>{n.current=!0}),O.useCallback(async(a,i={})=>{dr(n.current,WT),n.current&&(typeof a=="number"?await e.navigate(a):await e.navigate(a,{fromRouteId:t,...i}))},[e,t])}var ew={};function tN(e,t,n){!t&&!ew[e]&&(ew[e]=!0,dr(!1,n))}O.memo(kk);function kk({routes:e,manifest:t,future:n,state:r,isStatic:a,onError:i}){return JT(e,void 0,{manifest:t,state:r,isStatic:a,onError:i})}function nN({to:e,replace:t,state:n,relative:r}){it(gs(),"<Navigate> may be used only in the context of a <Router> component.");let{static:a}=O.useContext(kn);dr(!a,"<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:i}=O.useContext(pr),{pathname:o}=Cr(),l=vp(),s=mp(e,Gb(i),o,r==="path"),u=JSON.stringify(s);return O.useEffect(()=>{l(JSON.parse(u),{replace:t,state:n,relative:r})},[l,u,r,t,n]),null}function Dk(e){return wk(e.context)}function Ee(e){it(!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 Lk({basename:e="/",children:t=null,location:n,navigationType:r="POP",navigator:a,static:i=!1,useTransitions:o}){it(!gs(),"You cannot render a <Router> inside another <Router>. You should never have more than one in your app.");let l=e.replace(/^\/*/,"/"),s=O.useMemo(()=>({basename:l,navigator:a,static:i,useTransitions:o,future:{}}),[l,a,i,o]);typeof n=="string"&&(n=ys(n));let{pathname:u="/",search:d="",hash:f="",state:h=null,key:p="default",mask:b}=n,v=O.useMemo(()=>{let x=fa(u,l);return x==null?null:{location:{pathname:x,search:d,hash:f,state:h,key:p,mask:b},navigationType:r}},[l,u,d,f,h,p,r,b]);return dr(v!=null,`<Router basename="${l}"> is not able to match the URL "${u}${d}${f}" because it does not start with the basename, so the <Router> won't render anything.`),v==null?null:O.createElement(kn.Provider,{value:s},O.createElement(Gc.Provider,{children:t,value:v}))}function zk({children:e,location:t}){return jk(qv(e),t)}function qv(e,t=[]){let n=[];return O.Children.forEach(e,(r,a)=>{if(!O.isValidElement(r))return;let i=[...t,a];if(r.type===O.Fragment){n.push.apply(n,qv(r.props.children,i));return}it(r.type===Ee,`[${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>`),it(!r.props.index||!r.props.children,"An index route cannot have child routes.");let o={id:r.props.id||i.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&&(o.children=qv(r.props.children,i)),n.push(o)}),n}var id="get",od="application/x-www-form-urlencoded";function gp(e){return typeof HTMLElement<"u"&&e instanceof HTMLElement}function Bk(e){return gp(e)&&e.tagName.toLowerCase()==="button"}function Ik(e){return gp(e)&&e.tagName.toLowerCase()==="form"}function Uk(e){return gp(e)&&e.tagName.toLowerCase()==="input"}function qk(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function Hk(e,t){return e.button===0&&(!t||t==="_self")&&!qk(e)}var Ef=null;function Fk(){if(Ef===null)try{new FormData(document.createElement("form"),0),Ef=!1}catch{Ef=!0}return Ef}var Gk=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function oy(e){return e!=null&&!Gk.has(e)?(dr(!1,`"${e}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${od}"`),null):e}function Kk(e,t){let n,r,a,i,o;if(Ik(e)){let l=e.getAttribute("action");r=l?fa(l,t):null,n=e.getAttribute("method")||id,a=oy(e.getAttribute("enctype"))||od,i=new FormData(e)}else if(Bk(e)||Uk(e)&&(e.type==="submit"||e.type==="image")){let l=e.form;if(l==null)throw new Error('Cannot submit a <button> or <input type="submit"> without a <form>');let s=e.getAttribute("formaction")||l.getAttribute("action");if(r=s?fa(s,t):null,n=e.getAttribute("formmethod")||l.getAttribute("method")||id,a=oy(e.getAttribute("formenctype"))||oy(l.getAttribute("enctype"))||od,i=new FormData(l,e),!Fk()){let{name:u,type:d,value:f}=e;if(d==="image"){let h=u?`${u}.`:"";i.append(`${h}x`,"0"),i.append(`${h}y`,"0")}else u&&i.append(u,f)}}else{if(gp(e))throw new Error('Cannot submit element that is not <form>, <button>, or <input type="submit|image">');n=id,r=null,a=od,o=e}return i&&a==="text/plain"&&(o=i,i=void 0),{action:r,method:n.toLowerCase(),encType:a,formData:i,body:o}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");function Xb(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function rN(e,t,n,r){let a=typeof e=="string"?new URL(e,typeof window>"u"?"server://singlefetch/":window.location.origin):e;return n?a.pathname.endsWith("/")?a.pathname=`${a.pathname}_.${r}`:a.pathname=`${a.pathname}.${r}`:a.pathname==="/"?a.pathname=`_root.${r}`:t&&fa(a.pathname,t)==="/"?a.pathname=`${Hd(t)}/_root.${r}`:a.pathname=`${Hd(a.pathname)}.${r}`,a}async function Yk(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 Vk(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 Xk(e,t,n){let r=await Promise.all(e.map(async a=>{let i=t.routes[a.route.id];if(i){let o=await Yk(i,n);return o.links?o.links():[]}return[]}));return Jk(r.flat(1).filter(Vk).filter(a=>a.rel==="stylesheet"||a.rel==="preload").map(a=>a.rel==="stylesheet"?{...a,rel:"prefetch",as:"style"}:{...a,rel:"prefetch"}))}function tw(e,t,n,r,a,i){let o=(s,u)=>n[u]?s.route.id!==n[u].route.id:!0,l=(s,u)=>{var d;return n[u].pathname!==s.pathname||((d=n[u].route.path)==null?void 0:d.endsWith("*"))&&n[u].params["*"]!==s.params["*"]};return i==="assets"?t.filter((s,u)=>o(s,u)||l(s,u)):i==="data"?t.filter((s,u)=>{var f;let d=r.routes[s.route.id];if(!d||!d.hasLoader)return!1;if(o(s,u)||l(s,u))return!0;if(s.route.shouldRevalidate){let h=s.route.shouldRevalidate({currentUrl:new URL(a.pathname+a.search+a.hash,window.origin),currentParams:((f=n[0])==null?void 0:f.params)||{},nextUrl:new URL(e,window.origin),nextParams:s.params,defaultShouldRevalidate:!0});if(typeof h=="boolean")return h}return!0}):[]}function Qk(e,t,{includeHydrateFallback:n}={}){return Wk(e.map(r=>{let a=t.routes[r.route.id];if(!a)return[];let i=[a.module];return a.clientActionModule&&(i=i.concat(a.clientActionModule)),a.clientLoaderModule&&(i=i.concat(a.clientLoaderModule)),n&&a.hydrateFallbackModule&&(i=i.concat(a.hydrateFallbackModule)),a.imports&&(i=i.concat(a.imports)),i}).flat(1))}function Wk(e){return[...new Set(e)]}function Zk(e){let t={},n=Object.keys(e).sort();for(let r of n)t[r]=e[r];return t}function Jk(e,t){let n=new Set;return new Set(t),e.reduce((r,a)=>{let i=JSON.stringify(Zk(a));return n.has(i)||(n.add(i),r.push({key:i,link:a})),r},[])}function Qb(){let e=O.useContext(vs);return Xb(e,"You must render this element inside a <DataRouterContext.Provider> element"),e}function eD(){let e=O.useContext(yp);return Xb(e,"You must render this element inside a <DataRouterStateContext.Provider> element"),e}var Wb=O.createContext(void 0);Wb.displayName="FrameworkContext";function Zb(){let e=O.useContext(Wb);return Xb(e,"You must render this element inside a <HydratedRouter> element"),e}function tD(e,t){let n=O.useContext(Wb),[r,a]=O.useState(!1),[i,o]=O.useState(!1),{onFocus:l,onBlur:s,onMouseEnter:u,onMouseLeave:d,onTouchStart:f}=t,h=O.useRef(null);O.useEffect(()=>{if(e==="render"&&o(!0),e==="viewport"){let v=m=>{m.forEach(y=>{o(y.isIntersecting)})},x=new IntersectionObserver(v,{threshold:.5});return h.current&&x.observe(h.current),()=>{x.disconnect()}}},[e]),O.useEffect(()=>{if(r){let v=setTimeout(()=>{o(!0)},100);return()=>{clearTimeout(v)}}},[r]);let p=()=>{a(!0)},b=()=>{a(!1),o(!1)};return n?e!=="intent"?[i,h,{}]:[i,h,{onFocus:Hs(l,p),onBlur:Hs(s,b),onMouseEnter:Hs(u,p),onMouseLeave:Hs(d,b),onTouchStart:Hs(f,p)}]:[!1,h,{}]}function Hs(e,t){return n=>{e&&e(n),n.defaultPrevented||t(n)}}function nD({page:e,...t}){let n=dk(),{router:r}=Qb(),a=O.useMemo(()=>UT(r.routes,e,r.basename),[r.routes,e,r.basename]);return a?n?O.createElement(aD,{page:e,matches:a,...t}):O.createElement(iD,{page:e,matches:a,...t}):null}function rD(e){let{manifest:t,routeModules:n}=Zb(),[r,a]=O.useState([]);return O.useEffect(()=>{let i=!1;return Xk(e,t,n).then(o=>{i||a(o)}),()=>{i=!0}},[e,t,n]),r}function aD({page:e,matches:t,...n}){let r=Cr(),{future:a}=Zb(),{basename:i}=Qb(),o=O.useMemo(()=>{if(e===r.pathname+r.search+r.hash)return[];let l=rN(e,i,a.v8_trailingSlashAwareDataRequests,"rsc"),s=!1,u=[];for(let d of t)typeof d.route.shouldRevalidate=="function"?s=!0:u.push(d.route.id);return s&&u.length>0&&l.searchParams.set("_routes",u.join(",")),[l.pathname+l.search]},[i,a.v8_trailingSlashAwareDataRequests,e,r,t]);return O.createElement(O.Fragment,null,o.map(l=>O.createElement("link",{key:l,rel:"prefetch",as:"fetch",href:l,...n})))}function iD({page:e,matches:t,...n}){let r=Cr(),{future:a,manifest:i,routeModules:o}=Zb(),{basename:l}=Qb(),{loaderData:s,matches:u}=eD(),d=O.useMemo(()=>tw(e,t,u,i,r,"data"),[e,t,u,i,r]),f=O.useMemo(()=>tw(e,t,u,i,r,"assets"),[e,t,u,i,r]),h=O.useMemo(()=>{if(e===r.pathname+r.search+r.hash)return[];let v=new Set,x=!1;if(t.forEach(y=>{var S;let g=i.routes[y.route.id];!g||!g.hasLoader||(!d.some(w=>w.route.id===y.route.id)&&y.route.id in s&&((S=o[y.route.id])!=null&&S.shouldRevalidate)||g.hasClientLoader?x=!0:v.add(y.route.id))}),v.size===0)return[];let m=rN(e,l,a.v8_trailingSlashAwareDataRequests,"data");return x&&v.size>0&&m.searchParams.set("_routes",t.filter(y=>v.has(y.route.id)).map(y=>y.route.id).join(",")),[m.pathname+m.search]},[l,a.v8_trailingSlashAwareDataRequests,s,r,i,d,t,e,o]),p=O.useMemo(()=>Qk(f,i),[f,i]),b=rD(f);return O.createElement(O.Fragment,null,h.map(v=>O.createElement("link",{key:v,rel:"prefetch",as:"fetch",href:v,...n})),p.map(v=>O.createElement("link",{key:v,rel:"modulepreload",href:v,...n})),b.map(({key:v,link:x})=>O.createElement("link",{key:v,nonce:n.nonce,...x,crossOrigin:x.crossOrigin??n.crossOrigin})))}function oD(...e){return t=>{e.forEach(n=>{typeof n=="function"?n(t):n!=null&&(n.current=t)})}}var lD=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";try{lD&&(window.__reactRouterVersion="7.17.0")}catch{}function sD({basename:e,children:t,useTransitions:n,window:r}){let a=O.useRef();a.current==null&&(a.current=z$({window:r,v5Compat:!0}));let i=a.current,[o,l]=O.useState({action:i.action,location:i.location}),s=O.useCallback(u=>{n===!1?l(u):O.startTransition(()=>l(u))},[n]);return O.useLayoutEffect(()=>i.listen(s),[i,s]),O.createElement(Lk,{basename:e,children:t,location:o.location,navigationType:o.action,navigator:i,useTransitions:n})}var aN=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Jb=O.forwardRef(function({onClick:t,discover:n="render",prefetch:r="none",relative:a,reloadDocument:i,replace:o,mask:l,state:s,target:u,to:d,preventScrollReset:f,viewTransition:h,defaultShouldRevalidate:p,...b},v){let{basename:x,navigator:m,useTransitions:y}=O.useContext(kn),g=typeof d=="string"&&aN.test(d),S=KT(d,x);d=S.to;let w=bk(d,{relative:a}),j=Cr(),A=null;if(l){let C=mp(l,[],j.mask?j.mask.pathname:"/",!0);x!=="/"&&(C.pathname=C.pathname==="/"?x:fr([x,C.pathname])),A=m.createHref(C)}let[E,_,N]=tD(r,b),D=fD(d,{replace:o,mask:l,state:s,target:u,preventScrollReset:f,relative:a,viewTransition:h,defaultShouldRevalidate:p,useTransitions:y});function R(C){t&&t(C),C.defaultPrevented||D(C)}let B=!(S.isExternal||i),k=O.createElement("a",{...b,...N,href:(B?A:void 0)||S.absoluteURL||w,onClick:B?R:t,ref:oD(v,_),target:u,"data-discover":!g&&n==="render"?"true":void 0});return E&&!g?O.createElement(O.Fragment,null,k,O.createElement(nD,{page:w})):k});Jb.displayName="Link";var Hv=O.forwardRef(function({"aria-current":t="page",caseSensitive:n=!1,className:r="",end:a=!1,style:i,to:o,viewTransition:l,children:s,...u},d){let f=Kc(o,{relative:u.relative}),h=Cr(),p=O.useContext(yp),{navigator:b,basename:v}=O.useContext(kn),x=p!=null&&yD(f)&&l===!0,m=b.encodeLocation?b.encodeLocation(f).pathname:f.pathname,y=h.pathname,g=p&&p.navigation&&p.navigation.location?p.navigation.location.pathname:null;n||(y=y.toLowerCase(),g=g?g.toLowerCase():null,m=m.toLowerCase()),g&&v&&(g=fa(g,v)||g);const S=m!=="/"&&m.endsWith("/")?m.length-1:m.length;let w=y===m||!a&&y.startsWith(m)&&y.charAt(S)==="/",j=g!=null&&(g===m||!a&&g.startsWith(m)&&g.charAt(m.length)==="/"),A={isActive:w,isPending:j,isTransitioning:x},E=w?t:void 0,_;typeof r=="function"?_=r(A):_=[r,w?"active":null,j?"pending":null,x?"transitioning":null].filter(Boolean).join(" ");let N=typeof i=="function"?i(A):i;return O.createElement(Jb,{...u,"aria-current":E,className:_,ref:d,style:N,to:o,viewTransition:l},typeof s=="function"?s(A):s)});Hv.displayName="NavLink";var uD=O.forwardRef(({discover:e="render",fetcherKey:t,navigate:n,reloadDocument:r,replace:a,state:i,method:o=id,action:l,onSubmit:s,relative:u,preventScrollReset:d,viewTransition:f,defaultShouldRevalidate:h,...p},b)=>{let{useTransitions:v}=O.useContext(kn),x=pD(),m=mD(l,{relative:u}),y=o.toLowerCase()==="get"?"get":"post",g=typeof l=="string"&&aN.test(l),S=w=>{if(s&&s(w),w.defaultPrevented)return;w.preventDefault();let j=w.nativeEvent.submitter,A=(j==null?void 0:j.getAttribute("formmethod"))||o,E=()=>x(j||w.currentTarget,{fetcherKey:t,method:A,navigate:n,replace:a,state:i,relative:u,preventScrollReset:d,viewTransition:f,defaultShouldRevalidate:h});v&&n!==!1?O.startTransition(()=>E()):E()};return O.createElement("form",{ref:b,method:y,action:m,onSubmit:r?s:S,...p,"data-discover":!g&&e==="render"?"true":void 0})});uD.displayName="Form";function cD(e){return`${e} must be used within a data router.  See https://reactrouter.com/en/main/routers/picking-a-router.`}function iN(e){let t=O.useContext(vs);return it(t,cD(e)),t}function fD(e,{target:t,replace:n,mask:r,state:a,preventScrollReset:i,relative:o,viewTransition:l,defaultShouldRevalidate:s,useTransitions:u}={}){let d=vp(),f=Cr(),h=Kc(e,{relative:o});return O.useCallback(p=>{if(Hk(p,t)){p.preventDefault();let b=n!==void 0?n:qu(f)===qu(h),v=()=>d(e,{replace:b,mask:r,state:a,preventScrollReset:i,relative:o,viewTransition:l,defaultShouldRevalidate:s});u?O.startTransition(()=>v()):v()}},[f,d,h,n,r,a,t,e,i,o,l,s,u])}var dD=0,hD=()=>`__${String(++dD)}__`;function pD(){let{router:e}=iN("useSubmit"),{basename:t}=O.useContext(kn),n=Rk(),r=e.fetch,a=e.navigate;return O.useCallback(async(i,o={})=>{let{action:l,method:s,encType:u,formData:d,body:f}=Kk(i,t);if(o.navigate===!1){let h=o.fetcherKey||hD();await r(h,n,o.action||l,{defaultShouldRevalidate:o.defaultShouldRevalidate,preventScrollReset:o.preventScrollReset,formData:d,body:f,formMethod:o.method||s,formEncType:o.encType||u,flushSync:o.flushSync})}else await a(o.action||l,{defaultShouldRevalidate:o.defaultShouldRevalidate,preventScrollReset:o.preventScrollReset,formData:d,body:f,formMethod:o.method||s,formEncType:o.encType||u,replace:o.replace,state:o.state,fromRouteId:n,flushSync:o.flushSync,viewTransition:o.viewTransition})},[r,a,t,n])}function mD(e,{relative:t}={}){let{basename:n}=O.useContext(kn),r=O.useContext(pr);it(r,"useFormAction must be used inside a RouteContext");let[a]=r.matches.slice(-1),i={...Kc(e||".",{relative:t})},o=Cr();if(e==null){i.search=o.search;let l=new URLSearchParams(i.search),s=l.getAll("index");if(s.some(d=>d==="")){l.delete("index"),s.filter(f=>f).forEach(f=>l.append("index",f));let d=l.toString();i.search=d?`?${d}`:""}}return(!e||e===".")&&a.route.index&&(i.search=i.search?i.search.replace(/^\?/,"?index&"):"?index"),n!=="/"&&(i.pathname=i.pathname==="/"?n:fr([n,i.pathname])),qu(i)}function yD(e,{relative:t}={}){let n=O.useContext(XT);it(n!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`.  Did you accidentally import `RouterProvider` from `react-router`?");let{basename:r}=iN("useViewTransitionState"),a=Kc(e,{relative:t});if(!n.isTransitioning)return!1;let i=fa(n.currentLocation.pathname,r)||n.currentLocation.pathname,o=fa(n.nextLocation.pathname,r)||n.nextLocation.pathname;return qd(a.pathname,o)!=null||qd(a.pathname,i)!=null}var bs=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},ki,Ma,cl,TA,vD=(TA=class extends bs{constructor(){super();re(this,ki);re(this,Ma);re(this,cl);X(this,cl,t=>{if(typeof window<"u"&&window.addEventListener){const n=()=>t();return window.addEventListener("visibilitychange",n,!1),()=>{window.removeEventListener("visibilitychange",n)}}})}onSubscribe(){T(this,Ma)||this.setEventListener(T(this,cl))}onUnsubscribe(){var t;this.hasListeners()||((t=T(this,Ma))==null||t.call(this),X(this,Ma,void 0))}setEventListener(t){var n;X(this,cl,t),(n=T(this,Ma))==null||n.call(this),X(this,Ma,t(r=>{typeof r=="boolean"?this.setFocused(r):this.onFocus()}))}setFocused(t){T(this,ki)!==t&&(X(this,ki,t),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach(n=>{n(t)})}isFocused(){var t;return typeof T(this,ki)=="boolean"?T(this,ki):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},ki=new WeakMap,Ma=new WeakMap,cl=new WeakMap,TA),ex=new vD,gD={setTimeout:(e,t)=>setTimeout(e,t),clearTimeout:e=>clearTimeout(e),setInterval:(e,t)=>setInterval(e,t),clearInterval:e=>clearInterval(e)},Ra,H0,NA,bD=(NA=class{constructor(){re(this,Ra,gD);re(this,H0,!1)}setTimeoutProvider(e){X(this,Ra,e)}setTimeout(e,t){return T(this,Ra).setTimeout(e,t)}clearTimeout(e){T(this,Ra).clearTimeout(e)}setInterval(e,t){return T(this,Ra).setInterval(e,t)}clearInterval(e){T(this,Ra).clearInterval(e)}},Ra=new WeakMap,H0=new WeakMap,NA),Ni=new bD;function xD(e){setTimeout(e,0)}var SD=typeof window>"u"||"Deno"in globalThis;function Wt(){}function wD(e,t){return typeof e=="function"?e(t):e}function Fv(e){return typeof e=="number"&&e>=0&&e!==1/0}function oN(e,t){return Math.max(e+(t||0)-Date.now(),0)}function ti(e,t){return typeof e=="function"?e(t):e}function jn(e,t){return typeof e=="function"?e(t):e}function nw(e,t){const{type:n="all",exact:r,fetchStatus:a,predicate:i,queryKey:o,stale:l}=e;if(o){if(r){if(t.queryHash!==tx(o,t.options))return!1}else if(!Hu(t.queryKey,o))return!1}if(n!=="all"){const s=t.isActive();if(n==="active"&&!s||n==="inactive"&&s)return!1}return!(typeof l=="boolean"&&t.isStale()!==l||a&&a!==t.state.fetchStatus||i&&!i(t))}function rw(e,t){const{exact:n,status:r,predicate:a,mutationKey:i}=e;if(i){if(!t.options.mutationKey)return!1;if(n){if(ro(t.options.mutationKey)!==ro(i))return!1}else if(!Hu(t.options.mutationKey,i))return!1}return!(r&&t.state.status!==r||a&&!a(t))}function tx(e,t){return((t==null?void 0:t.queryKeyHashFn)||ro)(e)}function ro(e){return JSON.stringify(e,(t,n)=>Gv(n)?Object.keys(n).sort().reduce((r,a)=>(r[a]=n[a],r),{}):n)}function Hu(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?Object.keys(t).every(n=>Hu(e[n],t[n])):!1}var jD=Object.prototype.hasOwnProperty;function lN(e,t,n=0){if(e===t)return e;if(n>500)return t;const r=aw(e)&&aw(t);if(!r&&!(Gv(e)&&Gv(t)))return t;const i=(r?e:Object.keys(e)).length,o=r?t:Object.keys(t),l=o.length,s=r?new Array(l):{};let u=0;for(let d=0;d<l;d++){const f=r?d:o[d],h=e[f],p=t[f];if(h===p){s[f]=h,(r?d<i:jD.call(e,f))&&u++;continue}if(h===null||p===null||typeof h!="object"||typeof p!="object"){s[f]=p;continue}const b=lN(h,p,n+1);s[f]=b,b===h&&u++}return i===l&&u===i?e:s}function Fd(e,t){if(!t||Object.keys(e).length!==Object.keys(t).length)return!1;for(const n in e)if(e[n]!==t[n])return!1;return!0}function aw(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function Gv(e){if(!iw(e))return!1;const t=e.constructor;if(t===void 0)return!0;const n=t.prototype;return!(!iw(n)||!n.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function iw(e){return Object.prototype.toString.call(e)==="[object Object]"}function OD(e){return new Promise(t=>{Ni.setTimeout(t,e)})}function Kv(e,t,n){return typeof n.structuralSharing=="function"?n.structuralSharing(e,t):n.structuralSharing!==!1?lN(e,t):t}function AD(e,t,n=0){const r=[...e,t];return n&&r.length>n?r.slice(1):r}function ED(e,t,n=0){const r=[t,...e];return n&&r.length>n?r.slice(0,-1):r}var nx=Symbol();function sN(e,t){return!e.queryFn&&(t!=null&&t.initialPromise)?()=>t.initialPromise:!e.queryFn||e.queryFn===nx?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}function rx(e,t){return typeof e=="function"?e(...t):!!e}function _D(e,t,n){let r=!1,a;return Object.defineProperty(e,"signal",{enumerable:!0,get:()=>(a??(a=t()),r||(r=!0,a.aborted?n():a.addEventListener("abort",n,{once:!0})),a)}),e}var Fu=(()=>{let e=()=>SD;return{isServer(){return e()},setIsServer(t){e=t}}})();function Yv(){let e,t;const n=new Promise((a,i)=>{e=a,t=i});n.status="pending",n.catch(()=>{});function r(a){Object.assign(n,a),delete n.resolve,delete n.reject}return n.resolve=a=>{r({status:"fulfilled",value:a}),e(a)},n.reject=a=>{r({status:"rejected",reason:a}),t(a)},n}var TD=xD;function ND(){let e=[],t=0,n=l=>{l()},r=l=>{l()},a=TD;const i=l=>{t?e.push(l):a(()=>{n(l)})},o=()=>{const l=e;e=[],l.length&&a(()=>{r(()=>{l.forEach(s=>{n(s)})})})};return{batch:l=>{let s;t++;try{s=l()}finally{t--,t||o()}return s},batchCalls:l=>(...s)=>{i(()=>{l(...s)})},schedule:i,setNotifyFunction:l=>{n=l},setBatchNotifyFunction:l=>{r=l},setScheduler:l=>{a=l}}}var wt=ND(),fl,Pa,dl,CA,CD=(CA=class extends bs{constructor(){super();re(this,fl,!0);re(this,Pa);re(this,dl);X(this,dl,t=>{if(typeof window<"u"&&window.addEventListener){const n=()=>t(!0),r=()=>t(!1);return window.addEventListener("online",n,!1),window.addEventListener("offline",r,!1),()=>{window.removeEventListener("online",n),window.removeEventListener("offline",r)}}})}onSubscribe(){T(this,Pa)||this.setEventListener(T(this,dl))}onUnsubscribe(){var t;this.hasListeners()||((t=T(this,Pa))==null||t.call(this),X(this,Pa,void 0))}setEventListener(t){var n;X(this,dl,t),(n=T(this,Pa))==null||n.call(this),X(this,Pa,t(this.setOnline.bind(this)))}setOnline(t){T(this,fl)!==t&&(X(this,fl,t),this.listeners.forEach(r=>{r(t)}))}isOnline(){return T(this,fl)}},fl=new WeakMap,Pa=new WeakMap,dl=new WeakMap,CA),Gd=new CD;function MD(e){return Math.min(1e3*2**e,3e4)}function uN(e){return(e??"online")==="online"?Gd.isOnline():!0}var Vv=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function cN(e){let t=!1,n=0,r;const a=Yv(),i=()=>a.status!=="pending",o=v=>{var x;if(!i()){const m=new Vv(v);h(m),(x=e.onCancel)==null||x.call(e,m)}},l=()=>{t=!0},s=()=>{t=!1},u=()=>ex.isFocused()&&(e.networkMode==="always"||Gd.isOnline())&&e.canRun(),d=()=>uN(e.networkMode)&&e.canRun(),f=v=>{i()||(r==null||r(),a.resolve(v))},h=v=>{i()||(r==null||r(),a.reject(v))},p=()=>new Promise(v=>{var x;r=m=>{(i()||u())&&v(m)},(x=e.onPause)==null||x.call(e)}).then(()=>{var v;r=void 0,i()||(v=e.onContinue)==null||v.call(e)}),b=()=>{if(i())return;let v;const x=n===0?e.initialPromise:void 0;try{v=x??e.fn()}catch(m){v=Promise.reject(m)}Promise.resolve(v).then(f).catch(m=>{var j;if(i())return;const y=e.retry??(Fu.isServer()?0:3),g=e.retryDelay??MD,S=typeof g=="function"?g(n,m):g,w=y===!0||typeof y=="number"&&n<y||typeof y=="function"&&y(n,m);if(t||!w){h(m);return}n++,(j=e.onFail)==null||j.call(e,n,m),OD(S).then(()=>u()?void 0:p()).then(()=>{t?h(m):b()})})};return{promise:a,status:()=>a.status,cancel:o,continue:()=>(r==null||r(),a),cancelRetry:l,continueRetry:s,canStart:d,start:()=>(d()?b():p().then(b),a)}}var Di,MA,fN=(MA=class{constructor(){re(this,Di)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),Fv(this.gcTime)&&X(this,Di,Ni.setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(Fu.isServer()?1/0:5*60*1e3))}clearGcTimeout(){T(this,Di)!==void 0&&(Ni.clearTimeout(T(this,Di)),X(this,Di,void 0))}},Di=new WeakMap,MA);function RD(e){return{onFetch:(t,n)=>{var d,f,h,p,b;const r=t.options,a=(h=(f=(d=t.fetchOptions)==null?void 0:d.meta)==null?void 0:f.fetchMore)==null?void 0:h.direction,i=((p=t.state.data)==null?void 0:p.pages)||[],o=((b=t.state.data)==null?void 0:b.pageParams)||[];let l={pages:[],pageParams:[]},s=0;const u=async()=>{let v=!1;const x=g=>{_D(g,()=>t.signal,()=>v=!0)},m=sN(t.options,t.fetchOptions),y=async(g,S,w)=>{if(v)return Promise.reject(t.signal.reason);if(S==null&&g.pages.length)return Promise.resolve(g);const A=(()=>{const D={client:t.client,queryKey:t.queryKey,pageParam:S,direction:w?"backward":"forward",meta:t.options.meta};return x(D),D})(),E=await m(A),{maxPages:_}=t.options,N=w?ED:AD;return{pages:N(g.pages,E,_),pageParams:N(g.pageParams,S,_)}};if(a&&i.length){const g=a==="backward",S=g?PD:ow,w={pages:i,pageParams:o},j=S(r,w);l=await y(w,j,g)}else{const g=e??i.length;do{const S=s===0?o[0]??r.initialPageParam:ow(r,l);if(s>0&&S==null)break;l=await y(l,S),s++}while(s<g)}return l};t.options.persister?t.fetchFn=()=>{var v,x;return(x=(v=t.options).persister)==null?void 0:x.call(v,u,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},n)}:t.fetchFn=u}}}function ow(e,{pages:t,pageParams:n}){const r=t.length-1;return t.length>0?e.getNextPageParam(t[r],t,n[r],n):void 0}function PD(e,{pages:t,pageParams:n}){var r;return t.length>0?(r=e.getPreviousPageParam)==null?void 0:r.call(e,t[0],t,n[0],n):void 0}var hl,Li,pl,Bn,zi,_t,Tc,Bi,wn,dN,Ir,RA,$D=(RA=class extends fN{constructor(t){super();re(this,wn);re(this,hl);re(this,Li);re(this,pl);re(this,Bn);re(this,zi);re(this,_t);re(this,Tc);re(this,Bi);X(this,Bi,!1),X(this,Tc,t.defaultOptions),this.setOptions(t.options),this.observers=[],X(this,zi,t.client),X(this,Bn,T(this,zi).getQueryCache()),this.queryKey=t.queryKey,this.queryHash=t.queryHash,X(this,Li,sw(this.options)),this.state=t.state??T(this,Li),this.scheduleGc()}get meta(){return this.options.meta}get queryType(){return T(this,hl)}get promise(){var t;return(t=T(this,_t))==null?void 0:t.promise}setOptions(t){if(this.options={...T(this,Tc),...t},t!=null&&t._type&&X(this,hl,t._type),this.updateGcTime(this.options.gcTime),this.state&&this.state.data===void 0){const n=sw(this.options);n.data!==void 0&&(this.setState(lw(n.data,n.dataUpdatedAt)),X(this,Li,n))}}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&T(this,Bn).remove(this)}setData(t,n){const r=Kv(this.state.data,t,this.options);return he(this,wn,Ir).call(this,{data:r,type:"success",dataUpdatedAt:n==null?void 0:n.updatedAt,manual:n==null?void 0:n.manual}),r}setState(t){he(this,wn,Ir).call(this,{type:"setState",state:t})}cancel(t){var r,a;const n=(r=T(this,_t))==null?void 0:r.promise;return(a=T(this,_t))==null||a.cancel(t),n?n.then(Wt).catch(Wt):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}get resetState(){return T(this,Li)}reset(){this.destroy(),this.setState(this.resetState)}isActive(){return this.observers.some(t=>jn(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===nx||!this.isFetched()}isFetched(){return this.state.dataUpdateCount+this.state.errorUpdateCount>0}isStatic(){return this.getObserversCount()>0?this.observers.some(t=>ti(t.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(t=>t.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(t=0){return this.state.data===void 0?!0:t==="static"?!1:this.state.isInvalidated?!0:!oN(this.state.dataUpdatedAt,t)}onFocus(){var n;const t=this.observers.find(r=>r.shouldFetchOnWindowFocus());t==null||t.refetch({cancelRefetch:!1}),(n=T(this,_t))==null||n.continue()}onOnline(){var n;const t=this.observers.find(r=>r.shouldFetchOnReconnect());t==null||t.refetch({cancelRefetch:!1}),(n=T(this,_t))==null||n.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),T(this,Bn).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(n=>n!==t),this.observers.length||(T(this,_t)&&(T(this,Bi)||he(this,wn,dN).call(this)?T(this,_t).cancel({revert:!0}):T(this,_t).cancelRetry()),this.scheduleGc()),T(this,Bn).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||he(this,wn,Ir).call(this,{type:"invalidate"})}async fetch(t,n){var u,d,f,h,p,b,v,x,m,y,g;if(this.state.fetchStatus!=="idle"&&((u=T(this,_t))==null?void 0:u.status())!=="rejected"){if(this.state.data!==void 0&&(n!=null&&n.cancelRefetch))this.cancel({silent:!0});else if(T(this,_t))return T(this,_t).continueRetry(),T(this,_t).promise}if(t&&this.setOptions(t),!this.options.queryFn){const S=this.observers.find(w=>w.options.queryFn);S&&this.setOptions(S.options)}const r=new AbortController,a=S=>{Object.defineProperty(S,"signal",{enumerable:!0,get:()=>(X(this,Bi,!0),r.signal)})},i=()=>{const S=sN(this.options,n),j=(()=>{const A={client:T(this,zi),queryKey:this.queryKey,meta:this.meta};return a(A),A})();return X(this,Bi,!1),this.options.persister?this.options.persister(S,j,this):S(j)},l=(()=>{const S={fetchOptions:n,options:this.options,queryKey:this.queryKey,client:T(this,zi),state:this.state,fetchFn:i};return a(S),S})(),s=T(this,hl)==="infinite"?RD(this.options.pages):this.options.behavior;s==null||s.onFetch(l,this),X(this,pl,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((d=l.fetchOptions)==null?void 0:d.meta))&&he(this,wn,Ir).call(this,{type:"fetch",meta:(f=l.fetchOptions)==null?void 0:f.meta}),X(this,_t,cN({initialPromise:n==null?void 0:n.initialPromise,fn:l.fetchFn,onCancel:S=>{S instanceof Vv&&S.revert&&this.setState({...T(this,pl),fetchStatus:"idle"}),r.abort()},onFail:(S,w)=>{he(this,wn,Ir).call(this,{type:"failed",failureCount:S,error:w})},onPause:()=>{he(this,wn,Ir).call(this,{type:"pause"})},onContinue:()=>{he(this,wn,Ir).call(this,{type:"continue"})},retry:l.options.retry,retryDelay:l.options.retryDelay,networkMode:l.options.networkMode,canRun:()=>!0}));try{const S=await T(this,_t).start();if(S===void 0)throw new Error(`${this.queryHash} data is undefined`);return this.setData(S),(p=(h=T(this,Bn).config).onSuccess)==null||p.call(h,S,this),(v=(b=T(this,Bn).config).onSettled)==null||v.call(b,S,this.state.error,this),S}catch(S){if(S instanceof Vv){if(S.silent)return T(this,_t).promise;if(S.revert){if(this.state.data===void 0)throw S;return this.state.data}}throw he(this,wn,Ir).call(this,{type:"error",error:S}),(m=(x=T(this,Bn).config).onError)==null||m.call(x,S,this),(g=(y=T(this,Bn).config).onSettled)==null||g.call(y,this.state.data,S,this),S}finally{this.scheduleGc()}}},hl=new WeakMap,Li=new WeakMap,pl=new WeakMap,Bn=new WeakMap,zi=new WeakMap,_t=new WeakMap,Tc=new WeakMap,Bi=new WeakMap,wn=new WeakSet,dN=function(){return this.state.fetchStatus==="paused"&&this.state.status==="pending"},Ir=function(t){const n=r=>{switch(t.type){case"failed":return{...r,fetchFailureCount:t.failureCount,fetchFailureReason:t.error};case"pause":return{...r,fetchStatus:"paused"};case"continue":return{...r,fetchStatus:"fetching"};case"fetch":return{...r,...hN(r.data,this.options),fetchMeta:t.meta??null};case"success":const a={...r,...lw(t.data,t.dataUpdatedAt),dataUpdateCount:r.dataUpdateCount+1,...!t.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};return X(this,pl,t.manual?a:void 0),a;case"error":const i=t.error;return{...r,error:i,errorUpdateCount:r.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:r.fetchFailureCount+1,fetchFailureReason:i,fetchStatus:"idle",status:"error",isInvalidated:!0};case"invalidate":return{...r,isInvalidated:!0};case"setState":return{...r,...t.state}}};this.state=n(this.state),wt.batch(()=>{this.observers.forEach(r=>{r.onQueryUpdate()}),T(this,Bn).notify({query:this,type:"updated",action:t})})},RA);function hN(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:uN(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function lw(e,t){return{data:e,dataUpdatedAt:t??Date.now(),error:null,isInvalidated:!1,status:"success"}}function sw(e){const t=typeof e.initialData=="function"?e.initialData():e.initialData,n=t!==void 0,r=n?typeof e.initialDataUpdatedAt=="function"?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:n?r??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:n?"success":"pending",fetchStatus:"idle"}}var sn,Oe,Nc,Xt,Ii,ml,Hr,$a,Cc,yl,vl,Ui,qi,ka,gl,Me,ou,Xv,Qv,Wv,Zv,Jv,eg,tg,pN,PA,kD=(PA=class extends bs{constructor(t,n){super();re(this,Me);re(this,sn);re(this,Oe);re(this,Nc);re(this,Xt);re(this,Ii);re(this,ml);re(this,Hr);re(this,$a);re(this,Cc);re(this,yl);re(this,vl);re(this,Ui);re(this,qi);re(this,ka);re(this,gl,new Set);this.options=n,X(this,sn,t),X(this,$a,null),X(this,Hr,Yv()),this.bindMethods(),this.setOptions(n)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(T(this,Oe).addObserver(this),uw(T(this,Oe),this.options)?he(this,Me,ou).call(this):this.updateResult(),he(this,Me,Zv).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return ng(T(this,Oe),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return ng(T(this,Oe),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,he(this,Me,Jv).call(this),he(this,Me,eg).call(this),T(this,Oe).removeObserver(this)}setOptions(t){const n=this.options,r=T(this,Oe);if(this.options=T(this,sn).defaultQueryOptions(t),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof jn(this.options.enabled,T(this,Oe))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");he(this,Me,tg).call(this),T(this,Oe).setOptions(this.options),n._defaulted&&!Fd(this.options,n)&&T(this,sn).getQueryCache().notify({type:"observerOptionsUpdated",query:T(this,Oe),observer:this});const a=this.hasListeners();a&&cw(T(this,Oe),r,this.options,n)&&he(this,Me,ou).call(this),this.updateResult(),a&&(T(this,Oe)!==r||jn(this.options.enabled,T(this,Oe))!==jn(n.enabled,T(this,Oe))||ti(this.options.staleTime,T(this,Oe))!==ti(n.staleTime,T(this,Oe)))&&he(this,Me,Xv).call(this);const i=he(this,Me,Qv).call(this);a&&(T(this,Oe)!==r||jn(this.options.enabled,T(this,Oe))!==jn(n.enabled,T(this,Oe))||i!==T(this,ka))&&he(this,Me,Wv).call(this,i)}getOptimisticResult(t){const n=T(this,sn).getQueryCache().build(T(this,sn),t),r=this.createResult(n,t);return LD(this,r)&&(X(this,Xt,r),X(this,ml,this.options),X(this,Ii,T(this,Oe).state)),r}getCurrentResult(){return T(this,Xt)}trackResult(t,n){return new Proxy(t,{get:(r,a)=>(this.trackProp(a),n==null||n(a),a==="promise"&&(this.trackProp("data"),!this.options.experimental_prefetchInRender&&T(this,Hr).status==="pending"&&T(this,Hr).reject(new Error("experimental_prefetchInRender feature flag is not enabled"))),Reflect.get(r,a))})}trackProp(t){T(this,gl).add(t)}getCurrentQuery(){return T(this,Oe)}refetch({...t}={}){return this.fetch({...t})}fetchOptimistic(t){const n=T(this,sn).defaultQueryOptions(t),r=T(this,sn).getQueryCache().build(T(this,sn),n);return r.fetch().then(()=>this.createResult(r,n))}fetch(t){return he(this,Me,ou).call(this,{...t,cancelRefetch:t.cancelRefetch??!0}).then(()=>(this.updateResult(),T(this,Xt)))}createResult(t,n){var _;const r=T(this,Oe),a=this.options,i=T(this,Xt),o=T(this,Ii),l=T(this,ml),u=t!==r?t.state:T(this,Nc),{state:d}=t;let f={...d},h=!1,p;if(n._optimisticResults){const N=this.hasListeners(),D=!N&&uw(t,n),R=N&&cw(t,r,n,a);(D||R)&&(f={...f,...hN(d.data,t.options)}),n._optimisticResults==="isRestoring"&&(f.fetchStatus="idle")}let{error:b,errorUpdatedAt:v,status:x}=f;p=f.data;let m=!1;if(n.placeholderData!==void 0&&p===void 0&&x==="pending"){let N;i!=null&&i.isPlaceholderData&&n.placeholderData===(l==null?void 0:l.placeholderData)?(N=i.data,m=!0):N=typeof n.placeholderData=="function"?n.placeholderData((_=T(this,vl))==null?void 0:_.state.data,T(this,vl)):n.placeholderData,N!==void 0&&(x="success",p=Kv(i==null?void 0:i.data,N,n),h=!0)}if(n.select&&p!==void 0&&!m)if(i&&p===(o==null?void 0:o.data)&&n.select===T(this,Cc))p=T(this,yl);else try{X(this,Cc,n.select),p=n.select(p),p=Kv(i==null?void 0:i.data,p,n),X(this,yl,p),X(this,$a,null)}catch(N){X(this,$a,N)}T(this,$a)&&(b=T(this,$a),p=T(this,yl),v=Date.now(),x="error");const y=f.fetchStatus==="fetching",g=x==="pending",S=x==="error",w=g&&y,j=p!==void 0,E={status:x,fetchStatus:f.fetchStatus,isPending:g,isSuccess:x==="success",isError:S,isInitialLoading:w,isLoading:w,data:p,dataUpdatedAt:f.dataUpdatedAt,error:b,errorUpdatedAt:v,failureCount:f.fetchFailureCount,failureReason:f.fetchFailureReason,errorUpdateCount:f.errorUpdateCount,isFetched:t.isFetched(),isFetchedAfterMount:f.dataUpdateCount>u.dataUpdateCount||f.errorUpdateCount>u.errorUpdateCount,isFetching:y,isRefetching:y&&!g,isLoadingError:S&&!j,isPaused:f.fetchStatus==="paused",isPlaceholderData:h,isRefetchError:S&&j,isStale:ax(t,n),refetch:this.refetch,promise:T(this,Hr),isEnabled:jn(n.enabled,t)!==!1};if(this.options.experimental_prefetchInRender){const N=E.data!==void 0,D=E.status==="error"&&!N,R=C=>{D?C.reject(E.error):N&&C.resolve(E.data)},B=()=>{const C=X(this,Hr,E.promise=Yv());R(C)},k=T(this,Hr);switch(k.status){case"pending":t.queryHash===r.queryHash&&R(k);break;case"fulfilled":(D||E.data!==k.value)&&B();break;case"rejected":(!D||E.error!==k.reason)&&B();break}}return E}updateResult(){const t=T(this,Xt),n=this.createResult(T(this,Oe),this.options);if(X(this,Ii,T(this,Oe).state),X(this,ml,this.options),T(this,Ii).data!==void 0&&X(this,vl,T(this,Oe)),Fd(n,t))return;X(this,Xt,n);const r=()=>{if(!t)return!0;const{notifyOnChangeProps:a}=this.options,i=typeof a=="function"?a():a;if(i==="all"||!i&&!T(this,gl).size)return!0;const o=new Set(i??T(this,gl));return this.options.throwOnError&&o.add("error"),Object.keys(T(this,Xt)).some(l=>{const s=l;return T(this,Xt)[s]!==t[s]&&o.has(s)})};he(this,Me,pN).call(this,{listeners:r()})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&he(this,Me,Zv).call(this)}},sn=new WeakMap,Oe=new WeakMap,Nc=new WeakMap,Xt=new WeakMap,Ii=new WeakMap,ml=new WeakMap,Hr=new WeakMap,$a=new WeakMap,Cc=new WeakMap,yl=new WeakMap,vl=new WeakMap,Ui=new WeakMap,qi=new WeakMap,ka=new WeakMap,gl=new WeakMap,Me=new WeakSet,ou=function(t){he(this,Me,tg).call(this);let n=T(this,Oe).fetch(this.options,t);return t!=null&&t.throwOnError||(n=n.catch(Wt)),n},Xv=function(){he(this,Me,Jv).call(this);const t=ti(this.options.staleTime,T(this,Oe));if(Fu.isServer()||T(this,Xt).isStale||!Fv(t))return;const r=oN(T(this,Xt).dataUpdatedAt,t)+1;X(this,Ui,Ni.setTimeout(()=>{T(this,Xt).isStale||this.updateResult()},r))},Qv=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(T(this,Oe)):this.options.refetchInterval)??!1},Wv=function(t){he(this,Me,eg).call(this),X(this,ka,t),!(Fu.isServer()||jn(this.options.enabled,T(this,Oe))===!1||!Fv(T(this,ka))||T(this,ka)===0)&&X(this,qi,Ni.setInterval(()=>{(this.options.refetchIntervalInBackground||ex.isFocused())&&he(this,Me,ou).call(this)},T(this,ka)))},Zv=function(){he(this,Me,Xv).call(this),he(this,Me,Wv).call(this,he(this,Me,Qv).call(this))},Jv=function(){T(this,Ui)!==void 0&&(Ni.clearTimeout(T(this,Ui)),X(this,Ui,void 0))},eg=function(){T(this,qi)!==void 0&&(Ni.clearInterval(T(this,qi)),X(this,qi,void 0))},tg=function(){const t=T(this,sn).getQueryCache().build(T(this,sn),this.options);if(t===T(this,Oe))return;const n=T(this,Oe);X(this,Oe,t),X(this,Nc,t.state),this.hasListeners()&&(n==null||n.removeObserver(this),t.addObserver(this))},pN=function(t){wt.batch(()=>{t.listeners&&this.listeners.forEach(n=>{n(T(this,Xt))}),T(this,sn).getQueryCache().notify({query:T(this,Oe),type:"observerResultsUpdated"})})},PA);function DD(e,t){return jn(t.enabled,e)!==!1&&e.state.data===void 0&&!(e.state.status==="error"&&jn(t.retryOnMount,e)===!1)}function uw(e,t){return DD(e,t)||e.state.data!==void 0&&ng(e,t,t.refetchOnMount)}function ng(e,t,n){if(jn(t.enabled,e)!==!1&&ti(t.staleTime,e)!=="static"){const r=typeof n=="function"?n(e):n;return r==="always"||r!==!1&&ax(e,t)}return!1}function cw(e,t,n,r){return(e!==t||jn(r.enabled,e)===!1)&&(!n.suspense||e.state.status!=="error")&&ax(e,n)}function ax(e,t){return jn(t.enabled,e)!==!1&&e.isStaleByTime(ti(t.staleTime,e))}function LD(e,t){return!Fd(e.getCurrentResult(),t)}var Mc,vr,Ft,Hi,gr,wa,$A,zD=($A=class extends fN{constructor(t){super();re(this,gr);re(this,Mc);re(this,vr);re(this,Ft);re(this,Hi);X(this,Mc,t.client),this.mutationId=t.mutationId,X(this,Ft,t.mutationCache),X(this,vr,[]),this.state=t.state||mN(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){T(this,vr).includes(t)||(T(this,vr).push(t),this.clearGcTimeout(),T(this,Ft).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){X(this,vr,T(this,vr).filter(n=>n!==t)),this.scheduleGc(),T(this,Ft).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){T(this,vr).length||(this.state.status==="pending"?this.scheduleGc():T(this,Ft).remove(this))}continue(){var t;return((t=T(this,Hi))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var o,l,s,u,d,f,h,p,b,v,x,m,y,g,S,w,j,A;const n=()=>{he(this,gr,wa).call(this,{type:"continue"})},r={client:T(this,Mc),meta:this.options.meta,mutationKey:this.options.mutationKey};X(this,Hi,cN({fn:()=>this.options.mutationFn?this.options.mutationFn(t,r):Promise.reject(new Error("No mutationFn found")),onFail:(E,_)=>{he(this,gr,wa).call(this,{type:"failed",failureCount:E,error:_})},onPause:()=>{he(this,gr,wa).call(this,{type:"pause"})},onContinue:n,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>T(this,Ft).canRun(this)}));const a=this.state.status==="pending",i=!T(this,Hi).canStart();try{if(a)n();else{he(this,gr,wa).call(this,{type:"pending",variables:t,isPaused:i}),T(this,Ft).config.onMutate&&await T(this,Ft).config.onMutate(t,this,r);const _=await((l=(o=this.options).onMutate)==null?void 0:l.call(o,t,r));_!==this.state.context&&he(this,gr,wa).call(this,{type:"pending",context:_,variables:t,isPaused:i})}const E=await T(this,Hi).start();return await((u=(s=T(this,Ft).config).onSuccess)==null?void 0:u.call(s,E,t,this.state.context,this,r)),await((f=(d=this.options).onSuccess)==null?void 0:f.call(d,E,t,this.state.context,r)),await((p=(h=T(this,Ft).config).onSettled)==null?void 0:p.call(h,E,null,this.state.variables,this.state.context,this,r)),await((v=(b=this.options).onSettled)==null?void 0:v.call(b,E,null,t,this.state.context,r)),he(this,gr,wa).call(this,{type:"success",data:E}),E}catch(E){try{await((m=(x=T(this,Ft).config).onError)==null?void 0:m.call(x,E,t,this.state.context,this,r))}catch(_){Promise.reject(_)}try{await((g=(y=this.options).onError)==null?void 0:g.call(y,E,t,this.state.context,r))}catch(_){Promise.reject(_)}try{await((w=(S=T(this,Ft).config).onSettled)==null?void 0:w.call(S,void 0,E,this.state.variables,this.state.context,this,r))}catch(_){Promise.reject(_)}try{await((A=(j=this.options).onSettled)==null?void 0:A.call(j,void 0,E,t,this.state.context,r))}catch(_){Promise.reject(_)}throw he(this,gr,wa).call(this,{type:"error",error:E}),E}finally{T(this,Ft).runNext(this)}}},Mc=new WeakMap,vr=new WeakMap,Ft=new WeakMap,Hi=new WeakMap,gr=new WeakSet,wa=function(t){const n=r=>{switch(t.type){case"failed":return{...r,failureCount:t.failureCount,failureReason:t.error};case"pause":return{...r,isPaused:!0};case"continue":return{...r,isPaused:!1};case"pending":return{...r,context:t.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:t.isPaused,status:"pending",variables:t.variables,submittedAt:Date.now()};case"success":return{...r,data:t.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...r,data:void 0,error:t.error,failureCount:r.failureCount+1,failureReason:t.error,isPaused:!1,status:"error"}}};this.state=n(this.state),wt.batch(()=>{T(this,vr).forEach(r=>{r.onMutationUpdate(t)}),T(this,Ft).notify({mutation:this,type:"updated",action:t})})},$A);function mN(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var Fr,or,Rc,kA,BD=(kA=class extends bs{constructor(t={}){super();re(this,Fr);re(this,or);re(this,Rc);this.config=t,X(this,Fr,new Set),X(this,or,new Map),X(this,Rc,0)}build(t,n,r){const a=new zD({client:t,mutationCache:this,mutationId:++sf(this,Rc)._,options:t.defaultMutationOptions(n),state:r});return this.add(a),a}add(t){T(this,Fr).add(t);const n=_f(t);if(typeof n=="string"){const r=T(this,or).get(n);r?r.push(t):T(this,or).set(n,[t])}this.notify({type:"added",mutation:t})}remove(t){if(T(this,Fr).delete(t)){const n=_f(t);if(typeof n=="string"){const r=T(this,or).get(n);if(r)if(r.length>1){const a=r.indexOf(t);a!==-1&&r.splice(a,1)}else r[0]===t&&T(this,or).delete(n)}}this.notify({type:"removed",mutation:t})}canRun(t){const n=_f(t);if(typeof n=="string"){const r=T(this,or).get(n),a=r==null?void 0:r.find(i=>i.state.status==="pending");return!a||a===t}else return!0}runNext(t){var r;const n=_f(t);if(typeof n=="string"){const a=(r=T(this,or).get(n))==null?void 0:r.find(i=>i!==t&&i.state.isPaused);return(a==null?void 0:a.continue())??Promise.resolve()}else return Promise.resolve()}clear(){wt.batch(()=>{T(this,Fr).forEach(t=>{this.notify({type:"removed",mutation:t})}),T(this,Fr).clear(),T(this,or).clear()})}getAll(){return Array.from(T(this,Fr))}find(t){const n={exact:!0,...t};return this.getAll().find(r=>rw(n,r))}findAll(t={}){return this.getAll().filter(n=>rw(t,n))}notify(t){wt.batch(()=>{this.listeners.forEach(n=>{n(t)})})}resumePausedMutations(){const t=this.getAll().filter(n=>n.state.isPaused);return wt.batch(()=>Promise.all(t.map(n=>n.continue().catch(Wt))))}},Fr=new WeakMap,or=new WeakMap,Rc=new WeakMap,kA);function _f(e){var t;return(t=e.options.scope)==null?void 0:t.id}var Gr,Da,un,Kr,ia,ld,rg,DA,ID=(DA=class extends bs{constructor(n,r){super();re(this,ia);re(this,Gr);re(this,Da);re(this,un);re(this,Kr);X(this,Gr,n),this.setOptions(r),this.bindMethods(),he(this,ia,ld).call(this)}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(n){var a;const r=this.options;this.options=T(this,Gr).defaultMutationOptions(n),Fd(this.options,r)||T(this,Gr).getMutationCache().notify({type:"observerOptionsUpdated",mutation:T(this,un),observer:this}),r!=null&&r.mutationKey&&this.options.mutationKey&&ro(r.mutationKey)!==ro(this.options.mutationKey)?this.reset():((a=T(this,un))==null?void 0:a.state.status)==="pending"&&T(this,un).setOptions(this.options)}onUnsubscribe(){var n;this.hasListeners()||(n=T(this,un))==null||n.removeObserver(this)}onMutationUpdate(n){he(this,ia,ld).call(this),he(this,ia,rg).call(this,n)}getCurrentResult(){return T(this,Da)}reset(){var n;(n=T(this,un))==null||n.removeObserver(this),X(this,un,void 0),he(this,ia,ld).call(this),he(this,ia,rg).call(this)}mutate(n,r){var a;return X(this,Kr,r),(a=T(this,un))==null||a.removeObserver(this),X(this,un,T(this,Gr).getMutationCache().build(T(this,Gr),this.options)),T(this,un).addObserver(this),T(this,un).execute(n)}},Gr=new WeakMap,Da=new WeakMap,un=new WeakMap,Kr=new WeakMap,ia=new WeakSet,ld=function(){var r;const n=((r=T(this,un))==null?void 0:r.state)??mN();X(this,Da,{...n,isPending:n.status==="pending",isSuccess:n.status==="success",isError:n.status==="error",isIdle:n.status==="idle",mutate:this.mutate,reset:this.reset})},rg=function(n){wt.batch(()=>{var r,a,i,o,l,s,u,d;if(T(this,Kr)&&this.hasListeners()){const f=T(this,Da).variables,h=T(this,Da).context,p={client:T(this,Gr),meta:this.options.meta,mutationKey:this.options.mutationKey};if((n==null?void 0:n.type)==="success"){try{(a=(r=T(this,Kr)).onSuccess)==null||a.call(r,n.data,f,h,p)}catch(b){Promise.reject(b)}try{(o=(i=T(this,Kr)).onSettled)==null||o.call(i,n.data,null,f,h,p)}catch(b){Promise.reject(b)}}else if((n==null?void 0:n.type)==="error"){try{(s=(l=T(this,Kr)).onError)==null||s.call(l,n.error,f,h,p)}catch(b){Promise.reject(b)}try{(d=(u=T(this,Kr)).onSettled)==null||d.call(u,void 0,n.error,f,h,p)}catch(b){Promise.reject(b)}}}this.listeners.forEach(f=>{f(T(this,Da))})})},DA),br,LA,UD=(LA=class extends bs{constructor(t={}){super();re(this,br);this.config=t,X(this,br,new Map)}build(t,n,r){const a=n.queryKey,i=n.queryHash??tx(a,n);let o=this.get(i);return o||(o=new $D({client:t,queryKey:a,queryHash:i,options:t.defaultQueryOptions(n),state:r,defaultOptions:t.getQueryDefaults(a)}),this.add(o)),o}add(t){T(this,br).has(t.queryHash)||(T(this,br).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const n=T(this,br).get(t.queryHash);n&&(t.destroy(),n===t&&T(this,br).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){wt.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return T(this,br).get(t)}getAll(){return[...T(this,br).values()]}find(t){const n={exact:!0,...t};return this.getAll().find(r=>nw(n,r))}findAll(t={}){const n=this.getAll();return Object.keys(t).length>0?n.filter(r=>nw(t,r)):n}notify(t){wt.batch(()=>{this.listeners.forEach(n=>{n(t)})})}onFocus(){wt.batch(()=>{this.getAll().forEach(t=>{t.onFocus()})})}onOnline(){wt.batch(()=>{this.getAll().forEach(t=>{t.onOnline()})})}},br=new WeakMap,LA),lt,La,za,bl,xl,Ba,Sl,wl,zA,qD=(zA=class{constructor(e={}){re(this,lt);re(this,La);re(this,za);re(this,bl);re(this,xl);re(this,Ba);re(this,Sl);re(this,wl);X(this,lt,e.queryCache||new UD),X(this,La,e.mutationCache||new BD),X(this,za,e.defaultOptions||{}),X(this,bl,new Map),X(this,xl,new Map),X(this,Ba,0)}mount(){sf(this,Ba)._++,T(this,Ba)===1&&(X(this,Sl,ex.subscribe(async e=>{e&&(await this.resumePausedMutations(),T(this,lt).onFocus())})),X(this,wl,Gd.subscribe(async e=>{e&&(await this.resumePausedMutations(),T(this,lt).onOnline())})))}unmount(){var e,t;sf(this,Ba)._--,T(this,Ba)===0&&((e=T(this,Sl))==null||e.call(this),X(this,Sl,void 0),(t=T(this,wl))==null||t.call(this),X(this,wl,void 0))}isFetching(e){return T(this,lt).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return T(this,La).findAll({...e,status:"pending"}).length}getQueryData(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=T(this,lt).get(t.queryHash))==null?void 0:n.state.data}ensureQueryData(e){const t=this.defaultQueryOptions(e),n=T(this,lt).build(this,t),r=n.state.data;return r===void 0?this.fetchQuery(e):(e.revalidateIfStale&&n.isStaleByTime(ti(t.staleTime,n))&&this.prefetchQuery(t),Promise.resolve(r))}getQueriesData(e){return T(this,lt).findAll(e).map(({queryKey:t,state:n})=>{const r=n.data;return[t,r]})}setQueryData(e,t,n){const r=this.defaultQueryOptions({queryKey:e}),a=T(this,lt).get(r.queryHash),i=a==null?void 0:a.state.data,o=wD(t,i);if(o!==void 0)return T(this,lt).build(this,r).setData(o,{...n,manual:!0})}setQueriesData(e,t,n){return wt.batch(()=>T(this,lt).findAll(e).map(({queryKey:r})=>[r,this.setQueryData(r,t,n)]))}getQueryState(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=T(this,lt).get(t.queryHash))==null?void 0:n.state}removeQueries(e){const t=T(this,lt);wt.batch(()=>{t.findAll(e).forEach(n=>{t.remove(n)})})}resetQueries(e,t){const n=T(this,lt);return wt.batch(()=>(n.findAll(e).forEach(r=>{r.reset()}),this.refetchQueries({type:"active",...e},t)))}cancelQueries(e,t={}){const n={revert:!0,...t},r=wt.batch(()=>T(this,lt).findAll(e).map(a=>a.cancel(n)));return Promise.all(r).then(Wt).catch(Wt)}invalidateQueries(e,t={}){return wt.batch(()=>(T(this,lt).findAll(e).forEach(n=>{n.invalidate()}),(e==null?void 0:e.refetchType)==="none"?Promise.resolve():this.refetchQueries({...e,type:(e==null?void 0:e.refetchType)??(e==null?void 0:e.type)??"active"},t)))}refetchQueries(e,t={}){const n={...t,cancelRefetch:t.cancelRefetch??!0},r=wt.batch(()=>T(this,lt).findAll(e).filter(a=>!a.isDisabled()&&!a.isStatic()).map(a=>{let i=a.fetch(void 0,n);return n.throwOnError||(i=i.catch(Wt)),a.state.fetchStatus==="paused"?Promise.resolve():i}));return Promise.all(r).then(Wt)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const n=T(this,lt).build(this,t);return n.isStaleByTime(ti(t.staleTime,n))?n.fetch(t):Promise.resolve(n.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(Wt).catch(Wt)}fetchInfiniteQuery(e){return e._type="infinite",this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(Wt).catch(Wt)}ensureInfiniteQueryData(e){return e._type="infinite",this.ensureQueryData(e)}resumePausedMutations(){return Gd.isOnline()?T(this,La).resumePausedMutations():Promise.resolve()}getQueryCache(){return T(this,lt)}getMutationCache(){return T(this,La)}getDefaultOptions(){return T(this,za)}setDefaultOptions(e){X(this,za,e)}setQueryDefaults(e,t){T(this,bl).set(ro(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...T(this,bl).values()],n={};return t.forEach(r=>{Hu(e,r.queryKey)&&Object.assign(n,r.defaultOptions)}),n}setMutationDefaults(e,t){T(this,xl).set(ro(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...T(this,xl).values()],n={};return t.forEach(r=>{Hu(e,r.mutationKey)&&Object.assign(n,r.defaultOptions)}),n}defaultQueryOptions(e){if(e._defaulted)return e;const t={...T(this,za).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=tx(t.queryKey,t)),t.refetchOnReconnect===void 0&&(t.refetchOnReconnect=t.networkMode!=="always"),t.throwOnError===void 0&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode="offlineFirst"),t.queryFn===nx&&(t.enabled=!1),t}defaultMutationOptions(e){return e!=null&&e._defaulted?e:{...T(this,za).mutations,...(e==null?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){T(this,lt).clear(),T(this,La).clear()}},lt=new WeakMap,La=new WeakMap,za=new WeakMap,bl=new WeakMap,xl=new WeakMap,Ba=new WeakMap,Sl=new WeakMap,wl=new WeakMap,zA),yN=O.createContext(void 0),rn=e=>{const t=O.useContext(yN);if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},HD=({client:e,children:t})=>(O.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),c.jsx(yN.Provider,{value:e,children:t})),vN=O.createContext(!1),FD=()=>O.useContext(vN);vN.Provider;function GD(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}var KD=O.createContext(GD()),YD=()=>O.useContext(KD),VD=(e,t,n)=>{const r=n!=null&&n.state.error&&typeof e.throwOnError=="function"?rx(e.throwOnError,[n.state.error,n]):e.throwOnError;(e.suspense||e.experimental_prefetchInRender||r)&&(t.isReset()||(e.retryOnMount=!1))},XD=e=>{O.useEffect(()=>{e.clearReset()},[e])},QD=({result:e,errorResetBoundary:t,throwOnError:n,query:r,suspense:a})=>e.isError&&!t.isReset()&&!e.isFetching&&r&&(a&&e.data===void 0||rx(n,[e.error,r])),WD=e=>{if(e.suspense){const n=a=>a==="static"?a:Math.max(a??1e3,1e3),r=e.staleTime;e.staleTime=typeof r=="function"?(...a)=>n(r(...a)):n(r),typeof e.gcTime=="number"&&(e.gcTime=Math.max(e.gcTime,1e3))}},ZD=(e,t)=>e.isLoading&&e.isFetching&&!t,JD=(e,t)=>(e==null?void 0:e.suspense)&&t.isPending,fw=(e,t,n)=>t.fetchOptimistic(e).catch(()=>{n.clearReset()});function e5(e,t,n){var p,b,v,x;const r=FD(),a=YD(),i=rn(),o=i.defaultQueryOptions(e);(b=(p=i.getDefaultOptions().queries)==null?void 0:p._experimental_beforeQuery)==null||b.call(p,o);const l=i.getQueryCache().get(o.queryHash),s=e.subscribed!==!1;o._optimisticResults=r?"isRestoring":s?"optimistic":void 0,WD(o),VD(o,a,l),XD(a);const u=!i.getQueryCache().get(o.queryHash),[d]=O.useState(()=>new t(i,o)),f=d.getOptimisticResult(o),h=!r&&s;if(O.useSyncExternalStore(O.useCallback(m=>{const y=h?d.subscribe(wt.batchCalls(m)):Wt;return d.updateResult(),y},[d,h]),()=>d.getCurrentResult(),()=>d.getCurrentResult()),O.useEffect(()=>{d.setOptions(o)},[o,d]),JD(o,f))throw fw(o,d,a);if(QD({result:f,errorResetBoundary:a,throwOnError:o.throwOnError,query:l,suspense:o.suspense}))throw f.error;if((x=(v=i.getDefaultOptions().queries)==null?void 0:v._experimental_afterQuery)==null||x.call(v,o,f),o.experimental_prefetchInRender&&!Fu.isServer()&&ZD(f,r)){const m=u?fw(o,d,a):l==null?void 0:l.promise;m==null||m.catch(Wt).finally(()=>{d.updateResult()})}return o.notifyOnChangeProps?f:d.trackResult(f)}function Vt(e,t){return e5(e,kD)}function tt(e,t){const n=rn(),[r]=O.useState(()=>new ID(n,e));O.useEffect(()=>{r.setOptions(e)},[r,e]);const a=O.useSyncExternalStore(O.useCallback(o=>r.subscribe(wt.batchCalls(o)),[r]),()=>r.getCurrentResult(),()=>r.getCurrentResult()),i=O.useCallback((o,l)=>{r.mutate(o,l).catch(Wt)},[r]);if(a.error&&rx(r.options.throwOnError,[a.error]))throw a.error;return{...a,mutate:i,mutateAsync:a.mutate}}/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const t5=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),gN=(...e)=>e.filter((t,n,r)=>!!t&&r.indexOf(t)===n).join(" ");/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */var n5={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.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const r5=O.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:a="",children:i,iconNode:o,...l},s)=>O.createElement("svg",{ref:s,...n5,width:t,height:t,stroke:e,strokeWidth:r?Number(n)*24/Number(t):n,className:gN("lucide",a),...l},[...o.map(([u,d])=>O.createElement(u,d)),...Array.isArray(i)?i:[i]]));/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const ee=(e,t)=>{const n=O.forwardRef(({className:r,...a},i)=>O.createElement(r5,{ref:i,iconNode:t,className:gN(`lucide-${t5(e)}`,r),...a}));return n.displayName=`${e}`,n};/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const a5=ee("BarChart3",[["path",{d:"M3 3v18h18",key:"1s2lah"}],["path",{d:"M18 17V9",key:"2bz60n"}],["path",{d:"M13 17V5",key:"1frdt8"}],["path",{d:"M8 17v-3",key:"17ska0"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const bN=ee("Battery",[["rect",{width:"16",height:"10",x:"2",y:"7",rx:"2",ry:"2",key:"1w10f2"}],["line",{x1:"22",x2:"22",y1:"11",y2:"13",key:"4dh1rd"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const xN=ee("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.400.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=ee("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.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const i5=ee("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.400.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=ee("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.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const o5=ee("CalendarDays",[["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"}],["path",{d:"M8 14h.01",key:"6423bh"}],["path",{d:"M12 14h.01",key:"1etili"}],["path",{d:"M16 14h.01",key:"1gbofw"}],["path",{d:"M8 18h.01",key:"lrp35t"}],["path",{d:"M12 18h.01",key:"mhygvu"}],["path",{d:"M16 18h.01",key:"kzsmim"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const l5=ee("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const s5=ee("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.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const ix=ee("CircleCheckBig",[["path",{d:"M22 11.08V12a10 10 0 1 1-5.93-9.14",key:"g774vq"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const u5=ee("CircleCheck",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const c5=ee("CircleMinus",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M8 12h8",key:"1wcyev"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const f5=ee("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.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const d5=ee("ClipboardList",[["rect",{width:"8",height:"4",x:"8",y:"2",rx:"1",ry:"1",key:"tgr4d6"}],["path",{d:"M16 4h2a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h2",key:"116196"}],["path",{d:"M12 11h4",key:"1jrz19"}],["path",{d:"M12 16h4",key:"n85exb"}],["path",{d:"M8 11h.01",key:"1dfujw"}],["path",{d:"M8 16h.01",key:"18s6g9"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const h5=ee("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const p5=ee("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.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const $l=ee("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.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const m5=ee("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.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const y5=ee("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.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const v5=ee("EyeOff",[["path",{d:"M9.88 9.88a3 3 0 1 0 4.24 4.24",key:"1jxqfv"}],["path",{d:"M10.73 5.08A10.43 10.43 0 0 1 12 5c7 0 10 7 10 7a13.16 13.16 0 0 1-1.67 2.68",key:"9wicm4"}],["path",{d:"M6.61 6.61A13.526 13.526 0 0 0 2 12s3 7 10 7a9.74 9.74 0 0 0 5.39-1.61",key:"1jreej"}],["line",{x1:"2",x2:"22",y1:"2",y2:"22",key:"a6p6uj"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const g5=ee("Eye",[["path",{d:"M2 12s3-7 10-7 10 7 10 7-3 7-10 7-10-7-10-7Z",key:"rwhkz3"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const b5=ee("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.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const x5=ee("FolderTree",[["path",{d:"M20 10a1 1 0 0 0 1-1V6a1 1 0 0 0-1-1h-2.5a1 1 0 0 1-.8-.4l-.9-1.2A1 1 0 0 0 15 3h-2a1 1 0 0 0-1 1v5a1 1 0 0 0 1 1Z",key:"hod4my"}],["path",{d:"M20 21a1 1 0 0 0 1-1v-3a1 1 0 0 0-1-1h-2.9a1 1 0 0 1-.88-.55l-.42-.85a1 1 0 0 0-.92-.6H13a1 1 0 0 0-1 1v5a1 1 0 0 0 1 1Z",key:"w4yl2u"}],["path",{d:"M3 5a2 2 0 0 0 2 2h3",key:"f2jnh7"}],["path",{d:"M3 3v13a2 2 0 0 0 2 2h3",key:"k8epm1"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const jN=ee("KeyRound",[["path",{d:"M2 18v3c0 .6.4 1 1 1h4v-3h3v-3h2l1.4-1.4a6.5 6.5 0 1 0-4-4Z",key:"167ctg"}],["circle",{cx:"16.5",cy:"7.5",r:".5",fill:"currentColor",key:"w0ekpg"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const S5=ee("Layers",[["path",{d:"m12.83 2.18a2 2 0 0 0-1.66 0L2.6 6.08a1 1 0 0 0 0 1.83l8.58 3.91a2 2 0 0 0 1.66 0l8.58-3.9a1 1 0 0 0 0-1.83Z",key:"8b97xw"}],["path",{d:"m22 17.65-9.17 4.16a2 2 0 0 1-1.66 0L2 17.65",key:"dd6zsq"}],["path",{d:"m22 12.65-9.17 4.16a2 2 0 0 1-1.66 0L2 12.65",key:"ep9fru"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const w5=ee("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.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const j5=ee("Link2Off",[["path",{d:"M9 17H7A5 5 0 0 1 7 7",key:"10o201"}],["path",{d:"M15 7h2a5 5 0 0 1 4 8",key:"1d3206"}],["line",{x1:"8",x2:"12",y1:"12",y2:"12",key:"rvw6j4"}],["line",{x1:"2",x2:"22",y1:"2",y2:"22",key:"a6p6uj"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const ON=ee("Link2",[["path",{d:"M9 17H7A5 5 0 0 1 7 7h2",key:"8i5ue5"}],["path",{d:"M15 7h2a5 5 0 1 1 0 10h-2",key:"1b9ql8"}],["line",{x1:"8",x2:"16",y1:"12",y2:"12",key:"1jonct"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const O5=ee("ListOrdered",[["line",{x1:"10",x2:"21",y1:"6",y2:"6",key:"76qw6h"}],["line",{x1:"10",x2:"21",y1:"12",y2:"12",key:"16nom4"}],["line",{x1:"10",x2:"21",y1:"18",y2:"18",key:"u3jurt"}],["path",{d:"M4 6h1v4",key:"cnovpq"}],["path",{d:"M4 10h2",key:"16xx2s"}],["path",{d:"M6 18H4c0-1 2-2 2-3s-1-1.5-2-1",key:"m9a95d"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const A5=ee("ListTree",[["path",{d:"M21 12h-8",key:"1bmf0i"}],["path",{d:"M21 6H8",key:"1pqkrb"}],["path",{d:"M21 18h-8",key:"1tm79t"}],["path",{d:"M3 6v4c0 1.1.9 2 2 2h3",key:"1ywdgy"}],["path",{d:"M3 10v6c0 1.1.9 2 2 2h3",key:"2wc746"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const E5=ee("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.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const _5=ee("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.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const T5=ee("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.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const N5=ee("MapPin",[["path",{d:"M20 10c0 6-8 12-8 12s-8-6-8-12a8 8 0 0 1 16 0Z",key:"2oe9fu"}],["circle",{cx:"12",cy:"10",r:"3",key:"ilqhr7"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const C5=ee("Network",[["rect",{x:"16",y:"16",width:"6",height:"6",rx:"1",key:"4q2zg0"}],["rect",{x:"2",y:"16",width:"6",height:"6",rx:"1",key:"8cvhb9"}],["rect",{x:"9",y:"2",width:"6",height:"6",rx:"1",key:"1egb70"}],["path",{d:"M5 16v-3a1 1 0 0 1 1-1h12a1 1 0 0 1 1 1v3",key:"1jsf9p"}],["path",{d:"M12 12V8",key:"2874zd"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const M5=ee("NotebookPen",[["path",{d:"M13.4 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-7.4",key:"re6nr2"}],["path",{d:"M2 6h4",key:"aawbzj"}],["path",{d:"M2 10h4",key:"l0bgd4"}],["path",{d:"M2 14h4",key:"1gsvsf"}],["path",{d:"M2 18h4",key:"1bu2t1"}],["path",{d:"M21.378 5.626a1 1 0 1 0-3.004-3.004l-5.01 5.012a2 2 0 0 0-.506.854l-.837 2.87a.5.5 0 0 0 .62.62l2.87-.837a2 2 0 0 0 .854-.506z",key:"pqwjuv"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const R5=ee("Package",[["path",{d:"m7.5 4.27 9 5.15",key:"1c824w"}],["path",{d:"M21 8a2 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.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16Z",key:"hh9hay"}],["path",{d:"m3.3 7 8.7 5 8.7-5",key:"g66t2b"}],["path",{d:"M12 22V12",key:"d0xqtd"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const P5=ee("PlugZap",[["path",{d:"M6.3 20.3a2.4 2.4 0 0 0 3.4 0L12 18l-6-6-2.3 2.3a2.4 2.4 0 0 0 0 3.4Z",key:"goz73y"}],["path",{d:"m2 22 3-3",key:"19mgm9"}],["path",{d:"M7.5 13.5 10 11",key:"7xgeeb"}],["path",{d:"M10.5 16.5 13 14",key:"10btkg"}],["path",{d:"m18 3-4 4h6l-4 4",key:"16psg9"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const xs=ee("Plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const $5=ee("QrCode",[["rect",{width:"5",height:"5",x:"3",y:"3",rx:"1",key:"1tu5fj"}],["rect",{width:"5",height:"5",x:"16",y:"3",rx:"1",key:"1v8r4q"}],["rect",{width:"5",height:"5",x:"3",y:"16",rx:"1",key:"1x03jg"}],["path",{d:"M21 16h-3a2 2 0 0 0-2 2v3",key:"177gqh"}],["path",{d:"M21 21v.01",key:"ents32"}],["path",{d:"M12 7v3a2 2 0 0 1-2 2H7",key:"8crl2c"}],["path",{d:"M3 12h.01",key:"nlz23k"}],["path",{d:"M12 3h.01",key:"n36tog"}],["path",{d:"M12 16v.01",key:"133mhm"}],["path",{d:"M16 12h1",key:"1slzba"}],["path",{d:"M21 12v.01",key:"1lwtk9"}],["path",{d:"M12 21v-1",key:"1880an"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const Yc=ee("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.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const k5=ee("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.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const D5=ee("ScrollText",[["path",{d:"M15 12h-5",key:"r7krc0"}],["path",{d:"M15 8h-5",key:"1khuty"}],["path",{d:"M19 17V5a2 2 0 0 0-2-2H4",key:"zz82l3"}],["path",{d:"M8 21h12a2 2 0 0 0 2-2v-1a1 1 0 0 0-1-1H11a1 1 0 0 0-1 1v1a2 2 0 1 1-4 0V5a2 2 0 1 0-4 0v2a1 1 0 0 0 1 1h3",key:"1ph1d7"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const ag=ee("Send",[["path",{d:"m22 2-7 20-4-9-9-4Z",key:"1q3vgg"}],["path",{d:"M22 2 11 13",key:"nzbqef"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const L5=ee("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.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const z5=ee("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.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const AN=ee("ShieldCheck",[["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"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const B5=ee("SlidersVertical",[["line",{x1:"4",x2:"4",y1:"21",y2:"14",key:"1p332r"}],["line",{x1:"4",x2:"4",y1:"10",y2:"3",key:"gb41h5"}],["line",{x1:"12",x2:"12",y1:"21",y2:"12",key:"hf2csr"}],["line",{x1:"12",x2:"12",y1:"8",y2:"3",key:"1kfi7u"}],["line",{x1:"20",x2:"20",y1:"21",y2:"16",key:"1lhrwl"}],["line",{x1:"20",x2:"20",y1:"12",y2:"3",key:"16vvfq"}],["line",{x1:"2",x2:"6",y1:"14",y2:"14",key:"1uebub"}],["line",{x1:"10",x2:"14",y1:"8",y2:"8",key:"1yglbp"}],["line",{x1:"18",x2:"22",y1:"16",y2:"16",key:"1jxqpz"}]]);/**
 * @license lucide-react v0.400.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=ee("Smartphone",[["rect",{width:"14",height:"20",x:"5",y:"2",rx:"2",ry:"2",key:"1yt0o3"}],["path",{d:"M12 18h.01",key:"mhygvu"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const EN=ee("Sparkles",[["path",{d:"M9.937 15.5A2 2 0 0 0 8.5 14.063l-6.135-1.582a.5.5 0 0 1 0-.962L8.5 9.936A2 2 0 0 0 9.937 8.5l1.582-6.135a.5.5 0 0 1 .963 0L14.063 8.5A2 2 0 0 0 15.5 9.937l6.135 1.581a.5.5 0 0 1 0 .964L15.5 14.063a2 2 0 0 0-1.437 1.437l-1.582 6.135a.5.5 0 0 1-.963 0z",key:"4pj2yx"}],["path",{d:"M20 3v4",key:"1olli1"}],["path",{d:"M22 5h-4",key:"1gvqau"}],["path",{d:"M4 17v2",key:"vumght"}],["path",{d:"M5 18H3",key:"zchphs"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const Vc=ee("SquarePen",[["path",{d:"M12 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7",key:"1m0v6g"}],["path",{d:"M18.375 2.625a1 1 0 0 1 3 3l-9.013 9.014a2 2 0 0 1-.853.505l-2.873.84a.5.5 0 0 1-.62-.62l.84-2.873a2 2 0 0 1 .506-.852z",key:"ohrbg2"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const I5=ee("Star",[["polygon",{points:"12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2",key:"8f66p6"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const og=ee("Store",[["path",{d:"m2 7 4.41-4.41A2 2 0 0 1 7.83 2h8.34a2 2 0 0 1 1.42.59L22 7",key:"ztvudi"}],["path",{d:"M4 12v8a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-8",key:"1b2hhj"}],["path",{d:"M15 22v-4a2 2 0 0 0-2-2h-2a2 2 0 0 0-2 2v4",key:"2ebpfo"}],["path",{d:"M2 7h20",key:"1fcdvo"}],["path",{d:"M22 7v3a2 2 0 0 1-2 2a2.7 2.7 0 0 1-1.59-.63.7.7 0 0 0-.82 0A2.7 2.7 0 0 1 16 12a2.7 2.7 0 0 1-1.59-.63.7.7 0 0 0-.82 0A2.7 2.7 0 0 1 12 12a2.7 2.7 0 0 1-1.59-.63.7.7 0 0 0-.82 0A2.7 2.7 0 0 1 8 12a2.7 2.7 0 0 1-1.59-.63.7.7 0 0 0-.82 0A2.7 2.7 0 0 1 4 12a2 2 0 0 1-2-2V7",key:"6c3vgh"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const U5=ee("Tag",[["path",{d:"M12.586 2.586A2 2 0 0 0 11.172 2H4a2 2 0 0 0-2 2v7.172a2 2 0 0 0 .586 1.414l8.704 8.704a2.426 2.426 0 0 0 3.42 0l6.58-6.58a2.426 2.426 0 0 0 0-3.42z",key:"vktsd0"}],["circle",{cx:"7.5",cy:"7.5",r:".5",fill:"currentColor",key:"kqv944"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const q5=ee("ThumbsDown",[["path",{d:"M17 14V2",key:"8ymqnk"}],["path",{d:"M9 18.12 10 14H4.17a2 2 0 0 1-1.92-2.56l2.33-8A2 2 0 0 1 6.5 2H20a2 2 0 0 1 2 2v8a2 2 0 0 1-2 2h-2.76a2 2 0 0 0-1.79 1.11L12 22a3.13 3.13 0 0 1-3-3.88Z",key:"m61m77"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const H5=ee("ThumbsUp",[["path",{d:"M7 10v12",key:"1qc93n"}],["path",{d:"M15 5.88 14 10h5.83a2 2 0 0 1 1.92 2.56l-2.33 8A2 2 0 0 1 17.5 22H4a2 2 0 0 1-2-2v-8a2 2 0 0 1 2-2h2.76a2 2 0 0 0 1.79-1.11L12 2a3.13 3.13 0 0 1 3 3.88Z",key:"emmmcr"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const vo=ee("Trash2",[["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6",key:"4alrt4"}],["path",{d:"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2",key:"v07s0e"}],["line",{x1:"10",x2:"10",y1:"11",y2:"17",key:"1uufr5"}],["line",{x1:"14",x2:"14",y1:"11",y2:"17",key:"xtxkd"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const kl=ee("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.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const F5=ee("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.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const G5=ee("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.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const _N=ee("WifiOff",[["path",{d:"M12 20h.01",key:"zekei9"}],["path",{d:"M8.5 16.429a5 5 0 0 1 7 0",key:"1bycff"}],["path",{d:"M5 12.859a10 10 0 0 1 5.17-2.69",key:"1dl1wf"}],["path",{d:"M19 12.859a10 10 0 0 0-2.007-1.523",key:"4k23kn"}],["path",{d:"M2 8.82a15 15 0 0 1 4.177-2.643",key:"1grhjp"}],["path",{d:"M22 8.82a15 15 0 0 0-11.288-3.764",key:"z3jwby"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const TN=ee("Wifi",[["path",{d:"M12 20h.01",key:"zekei9"}],["path",{d:"M2 8.82a15 15 0 0 1 20 0",key:"dnpr2z"}],["path",{d:"M5 12.859a10 10 0 0 1 14 0",key:"1x1e6c"}],["path",{d:"M8.5 16.429a5 5 0 0 1 7 0",key:"1bycff"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const Ss=ee("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]);/**
 * @license lucide-react v0.400.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const lg=ee("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"}]]),K5=[{to:"/dashboard",icon:w5,label:"대시보드"},{to:"/stores",icon:og,label:"매장 관리"},{to:"/templates",icon:b5,label:"ESL 템플릿"},{to:"/pos-cvt",icon:Yc,label:"POS 가격변환"},{to:"/tag-binding",icon:ON,label:"태그 바인딩"},{to:"/update-queue",icon:O5,label:"업데이트 큐"},{to:"/alarms",icon:xN,label:"알람 관리"},{to:"/hcore",icon:$l,label:"HCore 장치"},{to:"/works",icon:d5,label:"작업 이력"},{to:"/firmware",icon:lg,label:"펌웨어"},{to:"/products",icon:R5,label:"상품/가격"},{to:"/users",icon:G5,label:"사용자"},{to:"/tenants",icon:wN,label:"테넌트 관리"},{to:"/audit",icon:D5,label:"감사 로그"},{to:"/settings",icon:z5,label:"시스템 설정"},{to:"/ai",icon:SN,label:"AI 분석"},{to:"/ai-techniques",icon:EN,label:"AI 기법 설정"},{to:"/ai-platform",icon:$l,label:"AI 플랫폼 설정"},{to:"/worklogs",icon:M5,label:"업무일지"},{to:"/schedules",icon:o5,label:"일정 관리"},{to:"/messages",icon:T5,label:"쪽지"},{to:"/work-stats",icon:a5,label:"업무 통계"},{to:"/mobile-app",icon:ig,label:"모바일 앱 설치"}],Y5=[{to:"/system/roles",icon:AN,label:"권한 관리"},{to:"/system/role-menus",icon:jN,label:"역할-메뉴 권한"},{to:"/system/menus",icon:A5,label:"메뉴 관리"},{to:"/system/codes",icon:C5,label:"공통코드 관리"},{to:"/system/depts",icon:x5,label:"부서 관리"},{to:"/system/companies",icon:i5,label:"거래처 관리"}];function V5(){const e=(localStorage.getItem("esn_role")||"")==="ADMIN";return c.jsxs("aside",{className:"w-56 bg-panel flex flex-col border-r border-edge flex-shrink-0",children:[c.jsxs("div",{className:"h-14 flex items-center px-4 border-b border-edge",children:[c.jsx("span",{className:"text-brand font-bold text-sm tracking-wide",children:"ESN"}),c.jsx("span",{className:"ml-2 text-xs text-gray-400",children:"ESL 통합 관리"})]}),c.jsxs("nav",{className:"flex-1 overflow-y-auto py-3",children:[K5.map(({to:t,icon:n,label:r})=>c.jsxs(Hv,{to:t,className:({isActive:a})=>`flex items-center gap-3 px-4 py-2.5 text-sm transition-colors ${a?"bg-brand/15 text-brand border-r-2 border-brand":"text-gray-400 hover:text-white hover:bg-edge/50"}`,children:[c.jsx(n,{size:16}),r]},t)),e&&c.jsxs(c.Fragment,{children:[c.jsx("div",{className:"mt-3 px-4 pt-3 pb-1 border-t border-edge text-[10px] font-semibold tracking-wide text-gray-500 uppercase",children:"시스템관리 (권한)"}),Y5.map(({to:t,icon:n,label:r})=>c.jsxs(Hv,{to:t,className:({isActive:a})=>`flex items-center gap-3 px-4 py-2.5 text-sm transition-colors ${a?"bg-brand/15 text-brand border-r-2 border-brand":"text-gray-400 hover:text-white hover:bg-edge/50"}`,children:[c.jsx(n,{size:16}),r]},t))]})]}),c.jsx("div",{className:"p-4 border-t border-edge text-xs text-gray-500",children:"zioinfo-esn v1.0"})]})}function X5(){const e=vp(),t=localStorage.getItem("esn_user")||"admin",n=localStorage.getItem("esn_role")||"ADMIN",r=localStorage.getItem("esn_tenant")||"ALL";function a(){localStorage.removeItem("esn_token"),localStorage.removeItem("esn_role"),localStorage.removeItem("esn_user"),localStorage.removeItem("esn_tenant"),e("/login")}return c.jsxs("header",{className:"h-14 bg-panel border-b border-edge flex items-center px-6 gap-4 flex-shrink-0",children:[c.jsx("div",{className:"flex-1"}),c.jsxs("span",{className:"text-xs text-gray-400",children:["테넌트: ",c.jsx("span",{className:"text-brand",children:r})]}),c.jsx("span",{className:"text-xs text-gray-400",children:"|"}),c.jsxs(Jb,{to:"/mypage",className:"flex items-center gap-2 text-sm text-gray-300 hover:text-brand transition-colors",title:"마이페이지",children:[c.jsx(F5,{size:14}),c.jsx("span",{children:t}),c.jsx("span",{className:"text-xs text-brand bg-brand/10 px-2 py-0.5 rounded",children:n})]}),c.jsxs("button",{onClick:a,className:"flex items-center gap-1.5 text-gray-400 hover:text-white text-sm",children:[c.jsx(_5,{size:14}),"로그아웃"]})]})}function NN(e,t){return function(){return e.apply(t,arguments)}}const{toString:Q5}=Object.prototype,{getPrototypeOf:Dl}=Object,{iterator:Xc,toStringTag:CN}=Symbol,Kd=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),Gu=(e,t)=>{let n=e;const r=[];for(;n!=null&&n!==Object.prototype;){if(r.indexOf(n)!==-1)return!1;if(r.push(n),Kd(n,t))return!0;n=Dl(n)}return!1},W5=(e,t)=>e!=null&&Gu(e,t)?e[t]:void 0,ox=(e=>t=>{const n=Q5.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),mr=e=>(e=e.toLowerCase(),t=>ox(t)===e),bp=e=>t=>typeof t===e,{isArray:ao}=Array,Ll=bp("undefined");function ws(e){return e!==null&&!Ll(e)&&e.constructor!==null&&!Ll(e.constructor)&&pn(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const MN=mr("ArrayBuffer");function Z5(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&MN(e.buffer),t}const J5=bp("string"),pn=bp("function"),RN=bp("number"),js=e=>e!==null&&typeof e=="object",e6=e=>e===!0||e===!1,sd=e=>{if(!js(e))return!1;const t=Dl(e);return(t===null||t===Object.prototype||Dl(t)===null)&&!Gu(e,CN)&&!Gu(e,Xc)},t6=e=>{if(!js(e)||ws(e))return!1;try{return Object.keys(e).length===0&&Object.getPrototypeOf(e)===Object.prototype}catch{return!1}},n6=mr("Date"),r6=mr("File"),a6=e=>!!(e&&typeof e.uri<"u"),i6=e=>e&&typeof e.getParts<"u",o6=mr("Blob"),l6=mr("FileList"),s6=e=>js(e)&&pn(e.pipe);function u6(){return typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{}}const dw=u6(),hw=typeof dw.FormData<"u"?dw.FormData:void 0,c6=e=>{if(!e)return!1;if(hw&&e instanceof hw)return!0;const t=Dl(e);if(!t||t===Object.prototype||!pn(e.append))return!1;const n=ox(e);return n==="formdata"||n==="object"&&pn(e.toString)&&e.toString()==="[object FormData]"},f6=mr("URLSearchParams"),[d6,h6,p6,m6]=["ReadableStream","Request","Response","Headers"].map(mr),y6=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Qc(e,t,{allOwnKeys:n=!1}={}){if(e===null||typeof e>"u")return;let r,a;if(typeof e!="object"&&(e=[e]),ao(e))for(r=0,a=e.length;r<a;r++)t.call(null,e[r],r,e);else{if(ws(e))return;const i=n?Object.getOwnPropertyNames(e):Object.keys(e),o=i.length;let l;for(r=0;r<o;r++)l=i[r],t.call(null,e[l],l,e)}}function PN(e,t){if(ws(e))return null;t=t.toLowerCase();const n=Object.keys(e);let r=n.length,a;for(;r-- >0;)if(a=n[r],t===a.toLowerCase())return a;return null}const Ci=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,$N=e=>!Ll(e)&&e!==Ci;function sg(...e){const{caseless:t,skipUndefined:n}=$N(this)&&this||{},r={},a=(i,o)=>{if(o==="__proto__"||o==="constructor"||o==="prototype")return;const l=t&&typeof o=="string"&&PN(r,o)||o,s=Kd(r,l)?r[l]:void 0;sd(s)&&sd(i)?r[l]=sg(s,i):sd(i)?r[l]=sg({},i):ao(i)?r[l]=i.slice():(!n||!Ll(i))&&(r[l]=i)};for(let i=0,o=e.length;i<o;i++){const l=e[i];if(!l||ws(l)||(Qc(l,a),typeof l!="object"||ao(l)))continue;const s=Object.getOwnPropertySymbols(l);for(let u=0;u<s.length;u++){const d=s[u];T6.call(l,d)&&a(l[d],d)}}return r}const v6=(e,t,n,{allOwnKeys:r}={})=>(Qc(t,(a,i)=>{n&&pn(a)?Object.defineProperty(e,i,{__proto__:null,value:NN(a,n),writable:!0,enumerable:!0,configurable:!0}):Object.defineProperty(e,i,{__proto__:null,value:a,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:r}),e),g6=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),b6=(e,t,n,r)=>{e.prototype=Object.create(t.prototype,r),Object.defineProperty(e.prototype,"constructor",{__proto__:null,value:e,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(e,"super",{__proto__:null,value:t.prototype}),n&&Object.assign(e.prototype,n)},x6=(e,t,n,r)=>{let a,i,o;const l={};if(t=t||{},e==null)return t;do{for(a=Object.getOwnPropertyNames(e),i=a.length;i-- >0;)o=a[i],(!r||r(o,e,t))&&!l[o]&&(t[o]=e[o],l[o]=!0);e=n!==!1&&Dl(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},S6=(e,t,n)=>{e=String(e),(n===void 0||n>e.length)&&(n=e.length),n-=t.length;const r=e.indexOf(t,n);return r!==-1&&r===n},w6=e=>{if(!e)return null;if(ao(e))return e;let t=e.length;if(!RN(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},j6=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&Dl(Uint8Array)),O6=(e,t)=>{const r=(e&&e[Xc]).call(e);let a;for(;(a=r.next())&&!a.done;){const i=a.value;t.call(e,i[0],i[1])}},A6=(e,t)=>{let n;const r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},E6=mr("HTMLFormElement"),_6=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,a){return r.toUpperCase()+a}),{propertyIsEnumerable:T6}=Object.prototype,N6=mr("RegExp"),kN=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};Qc(n,(a,i)=>{let o;(o=t(a,i,e))!==!1&&(r[i]=o||a)}),Object.defineProperties(e,r)},C6=e=>{kN(e,(t,n)=>{if(pn(e)&&["arguments","caller","callee"].includes(n))return!1;const r=e[n];if(pn(r)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},M6=(e,t)=>{const n={},r=a=>{a.forEach(i=>{n[i]=!0})};return ao(e)?r(e):r(String(e).split(t)),n},R6=()=>{},P6=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function $6(e){return!!(e&&pn(e.append)&&e[CN]==="FormData"&&e[Xc])}const k6=e=>{const t=new WeakSet,n=r=>{if(js(r)){if(t.has(r))return;if(ws(r))return r;if(!("toJSON"in r)){t.add(r);const a=ao(r)?[]:{};return Qc(r,(i,o)=>{const l=n(i);!Ll(l)&&(a[o]=l)}),t.delete(r),a}}return r};return n(e)},D6=mr("AsyncFunction"),L6=e=>e&&(js(e)||pn(e))&&pn(e.then)&&pn(e.catch),DN=((e,t)=>e?setImmediate:t?((n,r)=>(Ci.addEventListener("message",({source:a,data:i})=>{a===Ci&&i===n&&r.length&&r.shift()()},!1),a=>{r.push(a),Ci.postMessage(n,"*")}))(`axios@${Math.random()}`,[]):n=>setTimeout(n))(typeof setImmediate=="function",pn(Ci.postMessage)),z6=typeof queueMicrotask<"u"?queueMicrotask.bind(Ci):typeof process<"u"&&process.nextTick||DN,LN=e=>e!=null&&pn(e[Xc]),B6=e=>e!=null&&Gu(e,Xc)&&LN(e),P={isArray:ao,isArrayBuffer:MN,isBuffer:ws,isFormData:c6,isArrayBufferView:Z5,isString:J5,isNumber:RN,isBoolean:e6,isObject:js,isPlainObject:sd,isEmptyObject:t6,isReadableStream:d6,isRequest:h6,isResponse:p6,isHeaders:m6,isUndefined:Ll,isDate:n6,isFile:r6,isReactNativeBlob:a6,isReactNative:i6,isBlob:o6,isRegExp:N6,isFunction:pn,isStream:s6,isURLSearchParams:f6,isTypedArray:j6,isFileList:l6,forEach:Qc,merge:sg,extend:v6,trim:y6,stripBOM:g6,inherits:b6,toFlatObject:x6,kindOf:ox,kindOfTest:mr,endsWith:S6,toArray:w6,forEachEntry:O6,matchAll:A6,isHTMLForm:E6,hasOwnProperty:Kd,hasOwnProp:Kd,hasOwnInPrototypeChain:Gu,getSafeProp:W5,reduceDescriptors:kN,freezeMethods:C6,toObjectSet:M6,toCamelCase:_6,noop:R6,toFiniteNumber:P6,findKey:PN,global:Ci,isContextDefined:$N,isSpecCompliantForm:$6,toJSONObject:k6,isAsyncFn:D6,isThenable:L6,setImmediate:DN,asap:z6,isIterable:LN,isSafeIterable:B6},I6=P.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),U6=e=>{const t={};let n,r,a;return e&&e.split(`
`).forEach(function(o){a=o.indexOf(":"),n=o.substring(0,a).trim().toLowerCase(),r=o.substring(a+1).trim(),!(!n||t[n]&&I6[n])&&(n==="set-cookie"?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)}),t};function q6(e){let t=0,n=e.length;for(;t<n;){const r=e.charCodeAt(t);if(r!==9&&r!==32)break;t+=1}for(;n>t;){const r=e.charCodeAt(n-1);if(r!==9&&r!==32)break;n-=1}return t===0&&n===e.length?e:e.slice(t,n)}const H6=new RegExp("[\\u0000-\\u0008\\u000a-\\u001f\\u007f]+","g"),F6=new RegExp("[^\\u0009\\u0020-\\u007e\\u0080-\\u00ff]+","g");function lx(e,t){return P.isArray(e)?e.map(n=>lx(n,t)):q6(String(e).replace(t,""))}const G6=e=>lx(e,H6),K6=e=>lx(e,F6);function zN(e){const t=Object.create(null);return P.forEach(e.toJSON(),(n,r)=>{t[r]=K6(n)}),t}const pw=Symbol("internals");function Fs(e){return e&&String(e).trim().toLowerCase()}function ud(e){return e===!1||e==null?e:P.isArray(e)?e.map(ud):G6(String(e))}function Y6(e){const t=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=n.exec(e);)t[r[1]]=r[2];return t}const V6=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function ly(e,t,n,r,a){if(P.isFunction(r))return r.call(this,t,n);if(a&&(t=n),!!P.isString(t)){if(P.isString(r))return t.indexOf(r)!==-1;if(P.isRegExp(r))return r.test(t)}}function X6(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,n,r)=>n.toUpperCase()+r)}function Q6(e,t){const n=P.toCamelCase(" "+t);["get","set","has"].forEach(r=>{Object.defineProperty(e,r+n,{__proto__:null,value:function(a,i,o){return this[r].call(this,t,a,i,o)},configurable:!0})})}let Yt=class{constructor(t){t&&this.set(t)}set(t,n,r){const a=this;function i(l,s,u){const d=Fs(s);if(!d)return;const f=P.findKey(a,d);(!f||a[f]===void 0||u===!0||u===void 0&&a[f]!==!1)&&(a[f||s]=ud(l))}const o=(l,s)=>P.forEach(l,(u,d)=>i(u,d,s));if(P.isPlainObject(t)||t instanceof this.constructor)o(t,n);else if(P.isString(t)&&(t=t.trim())&&!V6(t))o(U6(t),n);else if(P.isObject(t)&&P.isSafeIterable(t)){let l=Object.create(null),s,u;for(const d of t){if(!P.isArray(d))throw new TypeError("Object iterator must return a key-value pair");u=d[0],P.hasOwnProp(l,u)?(s=l[u],l[u]=P.isArray(s)?[...s,d[1]]:[s,d[1]]):l[u]=d[1]}o(l,n)}else t!=null&&i(n,t,r);return this}get(t,n){if(t=Fs(t),t){const r=P.findKey(this,t);if(r){const a=this[r];if(!n)return a;if(n===!0)return Y6(a);if(P.isFunction(n))return n.call(this,a,r);if(P.isRegExp(n))return n.exec(a);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,n){if(t=Fs(t),t){const r=P.findKey(this,t);return!!(r&&this[r]!==void 0&&(!n||ly(this,this[r],r,n)))}return!1}delete(t,n){const r=this;let a=!1;function i(o){if(o=Fs(o),o){const l=P.findKey(r,o);l&&(!n||ly(r,r[l],l,n))&&(delete r[l],a=!0)}}return P.isArray(t)?t.forEach(i):i(t),a}clear(t){const n=Object.keys(this);let r=n.length,a=!1;for(;r--;){const i=n[r];(!t||ly(this,this[i],i,t,!0))&&(delete this[i],a=!0)}return a}normalize(t){const n=this,r={};return P.forEach(this,(a,i)=>{const o=P.findKey(r,i);if(o){n[o]=ud(a),delete n[i];return}const l=t?X6(i):String(i).trim();l!==i&&delete n[i],n[l]=ud(a),r[l]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const n=Object.create(null);return P.forEach(this,(r,a)=>{r!=null&&r!==!1&&(n[a]=t&&P.isArray(r)?r.join(", "):r)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,n])=>t+": "+n).join(`
`)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...n){const r=new this(t);return n.forEach(a=>r.set(a)),r}static accessor(t){const r=(this[pw]=this[pw]={accessors:{}}).accessors,a=this.prototype;function i(o){const l=Fs(o);r[l]||(Q6(a,o),r[l]=!0)}return P.isArray(t)?t.forEach(i):i(t),this}};Yt.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);P.reduceDescriptors(Yt.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(r){this[n]=r}}});P.freezeMethods(Yt);const W6="[REDACTED ****]";function Z6(e){if(P.hasOwnProp(e,"toJSON"))return!0;let t=Object.getPrototypeOf(e);for(;t&&t!==Object.prototype;){if(P.hasOwnProp(t,"toJSON"))return!0;t=Object.getPrototypeOf(t)}return!1}function J6(e,t){const n=new Set(t.map(i=>String(i).toLowerCase())),r=[],a=i=>{if(i===null||typeof i!="object"||P.isBuffer(i))return i;if(r.indexOf(i)!==-1)return;i instanceof Yt&&(i=i.toJSON()),r.push(i);let o;if(P.isArray(i))o=[],i.forEach((l,s)=>{const u=a(l);P.isUndefined(u)||(o[s]=u)});else{if(!P.isPlainObject(i)&&Z6(i))return r.pop(),i;o=Object.create(null);for(const[l,s]of Object.entries(i)){const u=n.has(l.toLowerCase())?W6:a(s);P.isUndefined(u)||(o[l]=u)}}return r.pop(),o};return a(e)}let W=class BN extends Error{static from(t,n,r,a,i,o){const l=new BN(t.message,n||t.code,r,a,i);return l.cause=t,l.name=t.name,t.status!=null&&l.status==null&&(l.status=t.status),o&&Object.assign(l,o),l}constructor(t,n,r,a,i){super(t),Object.defineProperty(this,"message",{__proto__:null,value:t,enumerable:!0,writable:!0,configurable:!0}),this.name="AxiosError",this.isAxiosError=!0,n&&(this.code=n),r&&(this.config=r),a&&(this.request=a),i&&(this.response=i,this.status=i.status)}toJSON(){const t=this.config,n=t&&P.hasOwnProp(t,"redact")?t.redact:void 0,r=P.isArray(n)&&n.length>0?J6(t,n):P.toJSONObject(t);return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:r,code:this.code,status:this.status}}};W.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE";W.ERR_BAD_OPTION="ERR_BAD_OPTION";W.ECONNABORTED="ECONNABORTED";W.ETIMEDOUT="ETIMEDOUT";W.ECONNREFUSED="ECONNREFUSED";W.ERR_NETWORK="ERR_NETWORK";W.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS";W.ERR_DEPRECATED="ERR_DEPRECATED";W.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE";W.ERR_BAD_REQUEST="ERR_BAD_REQUEST";W.ERR_CANCELED="ERR_CANCELED";W.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT";W.ERR_INVALID_URL="ERR_INVALID_URL";W.ERR_FORM_DATA_DEPTH_EXCEEDED="ERR_FORM_DATA_DEPTH_EXCEEDED";const eL=null,IN=100;function ug(e){return P.isPlainObject(e)||P.isArray(e)}function UN(e){return P.endsWith(e,"[]")?e.slice(0,-2):e}function sy(e,t,n){return e?e.concat(t).map(function(a,i){return a=UN(a),!n&&i?"["+a+"]":a}).join(n?".":""):t}function tL(e){return P.isArray(e)&&!e.some(ug)}const nL=P.toFlatObject(P,{},null,function(t){return/^is[A-Z]/.test(t)});function xp(e,t,n){if(!P.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=P.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(y,g){return!P.isUndefined(g[y])});const r=n.metaTokens,a=n.visitor||b,i=n.dots,o=n.indexes,l=n.Blob||typeof Blob<"u"&&Blob,s=n.maxDepth===void 0?IN:n.maxDepth,u=l&&P.isSpecCompliantForm(t),d=[];if(!P.isFunction(a))throw new TypeError("visitor must be a function");function f(m){if(m===null)return"";if(P.isDate(m))return m.toISOString();if(P.isBoolean(m))return m.toString();if(!u&&P.isBlob(m))throw new W("Blob is not supported. Use a Buffer instead.");return P.isArrayBuffer(m)||P.isTypedArray(m)?u&&typeof Blob=="function"?new Blob([m]):Buffer.from(m):m}function h(m){if(m>s)throw new W("Object is too deeply nested ("+m+" levels). Max depth: "+s,W.ERR_FORM_DATA_DEPTH_EXCEEDED)}function p(m,y){if(s===1/0)return JSON.stringify(m);const g=[];return JSON.stringify(m,function(w,j){if(!P.isObject(j))return j;for(;g.length&&g[g.length-1]!==this;)g.pop();return g.push(j),h(y+g.length-1),j})}function b(m,y,g){let S=m;if(P.isReactNative(t)&&P.isReactNativeBlob(m))return t.append(sy(g,y,i),f(m)),!1;if(m&&!g&&typeof m=="object"){if(P.endsWith(y,"{}"))y=r?y:y.slice(0,-2),m=p(m,1);else if(P.isArray(m)&&tL(m)||(P.isFileList(m)||P.endsWith(y,"[]"))&&(S=P.toArray(m)))return y=UN(y),S.forEach(function(j,A){!(P.isUndefined(j)||j===null)&&t.append(o===!0?sy([y],A,i):o===null?y:y+"[]",f(j))}),!1}return ug(m)?!0:(t.append(sy(g,y,i),f(m)),!1)}const v=Object.assign(nL,{defaultVisitor:b,convertValue:f,isVisitable:ug});function x(m,y,g=0){if(!P.isUndefined(m)){if(h(g),d.indexOf(m)!==-1)throw new Error("Circular reference detected in "+y.join("."));d.push(m),P.forEach(m,function(w,j){(!(P.isUndefined(w)||w===null)&&a.call(t,w,P.isString(j)?j.trim():j,y,v))===!0&&x(w,y?y.concat(j):[j],g+1)}),d.pop()}}if(!P.isObject(e))throw new TypeError("data must be an object");return x(e),t}function mw(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"};return encodeURIComponent(e).replace(/[!'()~]|%20/g,function(r){return t[r]})}function sx(e,t){this._pairs=[],e&&xp(e,this,t)}const qN=sx.prototype;qN.append=function(t,n){this._pairs.push([t,n])};qN.toString=function(t){const n=t?function(r){return t.call(this,r,mw)}:mw;return this._pairs.map(function(a){return n(a[0])+"="+n(a[1])},"").join("&")};function rL(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function HN(e,t,n){if(!t)return e;const r=P.isFunction(n)?{serialize:n}:n,a=P.getSafeProp(r,"encode")||rL,i=P.getSafeProp(r,"serialize");let o;if(i?o=i(t,r):o=P.isURLSearchParams(t)?t.toString():new sx(t,r).toString(a),o){const l=e.indexOf("#");l!==-1&&(e=e.slice(0,l)),e+=(e.indexOf("?")===-1?"?":"&")+o}return e}class yw{constructor(){this.handlers=[]}use(t,n,r){return this.handlers.push({fulfilled:t,rejected:n,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){P.forEach(this.handlers,function(r){r!==null&&t(r)})}}const ux={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0,advertiseZstdAcceptEncoding:!1,validateStatusUndefinedResolves:!0},aL=typeof URLSearchParams<"u"?URLSearchParams:sx,iL=typeof FormData<"u"?FormData:null,oL=typeof Blob<"u"?Blob:null,lL={isBrowser:!0,classes:{URLSearchParams:aL,FormData:iL,Blob:oL},protocols:["http","https","file","blob","url","data"]},cx=typeof window<"u"&&typeof document<"u",cg=typeof navigator=="object"&&navigator||void 0,sL=cx&&(!cg||["ReactNative","NativeScript","NS"].indexOf(cg.product)<0),uL=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",cL=cx&&window.location.href||"http://localhost",fL=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:cx,hasStandardBrowserEnv:sL,hasStandardBrowserWebWorkerEnv:uL,navigator:cg,origin:cL},Symbol.toStringTag,{value:"Module"})),It={...fL,...lL};function dL(e,t){return xp(e,new It.classes.URLSearchParams,{visitor:function(n,r,a,i){return It.isNode&&P.isBuffer(n)?(this.append(r,n.toString("base64")),!1):i.defaultVisitor.apply(this,arguments)},...t})}const vw=IN;function FN(e){if(e>vw)throw new W("FormData field is too deeply nested ("+e+" levels). Max depth: "+vw,W.ERR_FORM_DATA_DEPTH_EXCEEDED)}function hL(e){const t=[],n=/\w+|\[(\w*)]/g;let r;for(;(r=n.exec(e))!==null;)FN(t.length),t.push(r[0]==="[]"?"":r[1]||r[0]);return t}function pL(e){const t={},n=Object.keys(e);let r;const a=n.length;let i;for(r=0;r<a;r++)i=n[r],t[i]=e[i];return t}function GN(e){function t(n,r,a,i){FN(i);let o=n[i++];if(o==="__proto__")return!0;const l=Number.isFinite(+o),s=i>=n.length;return o=!o&&P.isArray(a)?a.length:o,s?(P.hasOwnProp(a,o)?a[o]=P.isArray(a[o])?a[o].concat(r):[a[o],r]:a[o]=r,!l):((!P.hasOwnProp(a,o)||!P.isObject(a[o]))&&(a[o]=[]),t(n,r,a[o],i)&&P.isArray(a[o])&&(a[o]=pL(a[o])),!l)}if(P.isFormData(e)&&P.isFunction(e.entries)){const n={};return P.forEachEntry(e,(r,a)=>{t(hL(r),a,n,0)}),n}return null}const _o=(e,t)=>e!=null&&P.hasOwnProp(e,t)?e[t]:void 0;function mL(e,t,n){if(P.isString(e))try{return(t||JSON.parse)(e),P.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(n||JSON.stringify)(e)}const Wc={transitional:ux,adapter:["xhr","http","fetch"],transformRequest:[function(t,n){const r=n.getContentType()||"",a=r.indexOf("application/json")>-1,i=P.isObject(t);if(i&&P.isHTMLForm(t)&&(t=new FormData(t)),P.isFormData(t))return a?JSON.stringify(GN(t)):t;if(P.isArrayBuffer(t)||P.isBuffer(t)||P.isStream(t)||P.isFile(t)||P.isBlob(t)||P.isReadableStream(t))return t;if(P.isArrayBufferView(t))return t.buffer;if(P.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let l;if(i){const s=_o(this,"formSerializer");if(r.indexOf("application/x-www-form-urlencoded")>-1)return dL(t,s).toString();if((l=P.isFileList(t))||r.indexOf("multipart/form-data")>-1){const u=_o(this,"env"),d=u&&u.FormData;return xp(l?{"files[]":t}:t,d&&new d,s)}}return i||a?(n.setContentType("application/json",!1),mL(t)):t}],transformResponse:[function(t){const n=_o(this,"transitional")||Wc.transitional,r=n&&n.forcedJSONParsing,a=_o(this,"responseType"),i=a==="json";if(P.isResponse(t)||P.isReadableStream(t))return t;if(t&&P.isString(t)&&(r&&!a||i)){const l=!(n&&n.silentJSONParsing)&&i;try{return JSON.parse(t,_o(this,"parseReviver"))}catch(s){if(l)throw s.name==="SyntaxError"?W.from(s,W.ERR_BAD_RESPONSE,this,null,_o(this,"response")):s}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:It.classes.FormData,Blob:It.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};P.forEach(["delete","get","head","post","put","patch","query"],e=>{Wc.headers[e]={}});function uy(e,t){const n=this||Wc,r=t||n,a=Yt.from(r.headers);let i=r.data;return P.forEach(e,function(l){i=l.call(n,i,a.normalize(),t?t.status:void 0)}),a.normalize(),i}function KN(e){return!!(e&&e.__CANCEL__)}let Zc=class extends W{constructor(t,n,r){super(t??"canceled",W.ERR_CANCELED,n,r),this.name="CanceledError",this.__CANCEL__=!0}};function YN(e,t,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new W("Request failed with status code "+n.status,n.status>=400&&n.status<500?W.ERR_BAD_REQUEST:W.ERR_BAD_RESPONSE,n.config,n.request,n))}function yL(e){const t=/^([-+\w]{1,25}):(?:\/\/)?/.exec(e);return t&&t[1]||""}function vL(e,t){e=e||10;const n=new Array(e),r=new Array(e);let a=0,i=0,o;return t=t!==void 0?t:1e3,function(s){const u=Date.now(),d=r[i];o||(o=u),n[a]=s,r[a]=u;let f=i,h=0;for(;f!==a;)h+=n[f++],f=f%e;if(a=(a+1)%e,a===i&&(i=(i+1)%e),u-o<t)return;const p=d&&u-d;return p?Math.round(h*1e3/p):void 0}}function gL(e,t){let n=0,r=1e3/t,a,i;const o=(u,d=Date.now())=>{n=d,a=null,i&&(clearTimeout(i),i=null),e(...u)};return[(...u)=>{const d=Date.now(),f=d-n;f>=r?o(u,d):(a=u,i||(i=setTimeout(()=>{i=null,o(a)},r-f)))},()=>a&&o(a)]}const Yd=(e,t,n=3)=>{let r=0;const a=vL(50,250);return gL(i=>{if(!i||typeof i.loaded!="number")return;const o=i.loaded,l=i.lengthComputable?i.total:void 0,s=l!=null?Math.min(o,l):o,u=Math.max(0,s-r),d=a(u);r=Math.max(r,s);const f={loaded:s,total:l,progress:l?s/l:void 0,bytes:u,rate:d||void 0,estimated:d&&l?(l-s)/d:void 0,event:i,lengthComputable:l!=null,[t?"download":"upload"]:!0};e(f)},n)},gw=(e,t)=>{const n=e!=null;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},bw=e=>(...t)=>P.asap(()=>e(...t)),bL=It.hasStandardBrowserEnv?((e,t)=>n=>(n=new URL(n,It.origin),e.protocol===n.protocol&&e.host===n.host&&(t||e.port===n.port)))(new URL(It.origin),It.navigator&&/(msie|trident)/i.test(It.navigator.userAgent)):()=>!0,xL=It.hasStandardBrowserEnv?{write(e,t,n,r,a,i,o){if(typeof document>"u")return;const l=[`${e}=${encodeURIComponent(t)}`];P.isNumber(n)&&l.push(`expires=${new Date(n).toUTCString()}`),P.isString(r)&&l.push(`path=${r}`),P.isString(a)&&l.push(`domain=${a}`),i===!0&&l.push("secure"),P.isString(o)&&l.push(`SameSite=${o}`),document.cookie=l.join("; ")},read(e){if(typeof document>"u")return null;const t=document.cookie.split(";");for(let n=0;n<t.length;n++){const r=t[n].replace(/^\s+/,""),a=r.indexOf("=");if(a!==-1&&r.slice(0,a)===e)return decodeURIComponent(r.slice(a+1))}return null},remove(e){this.write(e,"",Date.now()-864e5,"/")}}:{write(){},read(){return null},remove(){}};function SL(e){return typeof e!="string"?!1:/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function wL(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}const jL=/^https?:(?!\/\/)/i,OL=/[\t\n\r]/g;function AL(e){let t=0;for(;t<e.length&&e.charCodeAt(t)<=32;)t++;return e.slice(t)}function EL(e){return AL(e).replace(OL,"")}function xw(e,t){if(typeof e=="string"&&jL.test(EL(e)))throw new W('Invalid URL: missing "//" after protocol',W.ERR_INVALID_URL,t)}function VN(e,t,n,r){xw(t,r);let a=!SL(t);return e&&(a||n===!1)?(xw(e,r),wL(e,t)):t}const Sw=e=>e instanceof Yt?{...e}:e;function io(e,t){t=t||{};const n=Object.create(null);Object.defineProperty(n,"hasOwnProperty",{__proto__:null,value:Object.prototype.hasOwnProperty,enumerable:!1,writable:!0,configurable:!0});function r(d,f,h,p){return P.isPlainObject(d)&&P.isPlainObject(f)?P.merge.call({caseless:p},d,f):P.isPlainObject(f)?P.merge({},f):P.isArray(f)?f.slice():f}function a(d,f,h,p){if(P.isUndefined(f)){if(!P.isUndefined(d))return r(void 0,d,h,p)}else return r(d,f,h,p)}function i(d,f){if(!P.isUndefined(f))return r(void 0,f)}function o(d,f){if(P.isUndefined(f)){if(!P.isUndefined(d))return r(void 0,d)}else return r(void 0,f)}function l(d){const f=P.hasOwnProp(t,"transitional")?t.transitional:void 0;if(!P.isUndefined(f))if(P.isPlainObject(f)){if(P.hasOwnProp(f,d))return f[d]}else return;const h=P.hasOwnProp(e,"transitional")?e.transitional:void 0;if(P.isPlainObject(h)&&P.hasOwnProp(h,d))return h[d]}function s(d,f,h){if(P.hasOwnProp(t,h))return r(d,f);if(P.hasOwnProp(e,h))return r(void 0,d)}const u={url:i,method:i,data:i,baseURL:o,transformRequest:o,transformResponse:o,paramsSerializer:o,timeout:o,timeoutMessage:o,withCredentials:o,withXSRFToken:o,adapter:o,responseType:o,xsrfCookieName:o,xsrfHeaderName:o,onUploadProgress:o,onDownloadProgress:o,decompress:o,maxContentLength:o,maxBodyLength:o,beforeRedirect:o,transport:o,httpAgent:o,httpsAgent:o,cancelToken:o,socketPath:o,allowedSocketPaths:o,responseEncoding:o,validateStatus:s,headers:(d,f,h)=>a(Sw(d),Sw(f),h,!0)};return P.forEach(Object.keys({...e,...t}),function(f){if(f==="__proto__"||f==="constructor"||f==="prototype")return;const h=P.hasOwnProp(u,f)?u[f]:a,p=P.hasOwnProp(e,f)?e[f]:void 0,b=P.hasOwnProp(t,f)?t[f]:void 0,v=h(p,b,f);P.isUndefined(v)&&h!==s||(n[f]=v)}),P.hasOwnProp(t,"validateStatus")&&P.isUndefined(t.validateStatus)&&l("validateStatusUndefinedResolves")===!1&&(P.hasOwnProp(e,"validateStatus")?n.validateStatus=r(void 0,e.validateStatus):delete n.validateStatus),n}const _L=["content-type","content-length"];function TL(e,t,n){if(n!=="content-only"){e.set(t);return}Object.entries(t).forEach(([r,a])=>{_L.includes(r.toLowerCase())&&e.set(r,a)})}const NL=e=>encodeURIComponent(e).replace(/%([0-9A-F]{2})/gi,(t,n)=>String.fromCharCode(parseInt(n,16)));function XN(e){const t=io({},e),n=h=>P.hasOwnProp(t,h)?t[h]:void 0,r=n("data");let a=n("withXSRFToken");const i=n("xsrfHeaderName"),o=n("xsrfCookieName");let l=n("headers");const s=n("auth"),u=n("baseURL"),d=n("allowAbsoluteUrls"),f=n("url");if(t.headers=l=Yt.from(l),t.url=HN(VN(u,f,d,t),n("params"),n("paramsSerializer")),s){const h=P.getSafeProp(s,"username")||"",p=P.getSafeProp(s,"password")||"";l.set("Authorization","Basic "+btoa(h+":"+(p?NL(p):"")))}if(P.isFormData(r)&&(It.hasStandardBrowserEnv||It.hasStandardBrowserWebWorkerEnv||P.isReactNative(r)?l.setContentType(void 0):P.isFunction(r.getHeaders)&&TL(l,r.getHeaders(),n("formDataHeaderPolicy"))),It.hasStandardBrowserEnv&&(P.isFunction(a)&&(a=a(t)),a===!0||a==null&&bL(t.url))){const p=i&&o&&xL.read(o);p&&l.set(i,p)}return t}const CL=typeof XMLHttpRequest<"u",ML=CL&&function(e){return new Promise(function(n,r){const a=XN(e);let i=a.data;const o=Yt.from(a.headers).normalize();let{responseType:l,onUploadProgress:s,onDownloadProgress:u}=a,d,f,h,p,b;function v(){p&&p(),b&&b(),a.cancelToken&&a.cancelToken.unsubscribe(d),a.signal&&a.signal.removeEventListener("abort",d)}let x=new XMLHttpRequest;x.open(a.method.toUpperCase(),a.url,!0),x.timeout=a.timeout;function m(){if(!x)return;const g=Yt.from("getAllResponseHeaders"in x&&x.getAllResponseHeaders()),w={data:!l||l==="text"||l==="json"?x.responseText:x.response,status:x.status,statusText:x.statusText,headers:g,config:e,request:x};YN(function(A){n(A),v()},function(A){r(A),v()},w),x=null}"onloadend"in x?x.onloadend=m:x.onreadystatechange=function(){!x||x.readyState!==4||x.status===0&&!(x.responseURL&&x.responseURL.startsWith("file:"))||setTimeout(m)},x.onabort=function(){x&&(r(new W("Request aborted",W.ECONNABORTED,e,x)),v(),x=null)},x.onerror=function(S){const w=S&&S.message?S.message:"Network Error",j=new W(w,W.ERR_NETWORK,e,x);j.event=S||null,r(j),v(),x=null},x.ontimeout=function(){let S=a.timeout?"timeout of "+a.timeout+"ms exceeded":"timeout exceeded";const w=a.transitional||ux;a.timeoutErrorMessage&&(S=a.timeoutErrorMessage),r(new W(S,w.clarifyTimeoutError?W.ETIMEDOUT:W.ECONNABORTED,e,x)),v(),x=null},i===void 0&&o.setContentType(null),"setRequestHeader"in x&&P.forEach(zN(o),function(S,w){x.setRequestHeader(w,S)}),P.isUndefined(a.withCredentials)||(x.withCredentials=!!a.withCredentials),l&&l!=="json"&&(x.responseType=a.responseType),u&&([h,b]=Yd(u,!0),x.addEventListener("progress",h)),s&&x.upload&&([f,p]=Yd(s),x.upload.addEventListener("progress",f),x.upload.addEventListener("loadend",p)),(a.cancelToken||a.signal)&&(d=g=>{x&&(r(!g||g.type?new Zc(null,e,x):g),x.abort(),v(),x=null)},a.cancelToken&&a.cancelToken.subscribe(d),a.signal&&(a.signal.aborted?d():a.signal.addEventListener("abort",d)));const y=yL(a.url);if(y&&!It.protocols.includes(y)){r(new W("Unsupported protocol "+y+":",W.ERR_BAD_REQUEST,e));return}x.send(i||null)})},RL=(e,t)=>{if(e=e?e.filter(Boolean):[],!t&&!e.length)return;const n=new AbortController;let r=!1;const a=function(s){if(!r){r=!0,o();const u=s instanceof Error?s:this.reason;n.abort(u instanceof W?u:new Zc(u instanceof Error?u.message:u))}};let i=t&&setTimeout(()=>{i=null,a(new W(`timeout of ${t}ms exceeded`,W.ETIMEDOUT))},t);const o=()=>{e&&(i&&clearTimeout(i),i=null,e.forEach(s=>{s.unsubscribe?s.unsubscribe(a):s.removeEventListener("abort",a)}),e=null)};e.forEach(s=>s.addEventListener("abort",a));const{signal:l}=n;return l.unsubscribe=()=>P.asap(o),l},PL=function*(e,t){let n=e.byteLength;if(n<t){yield e;return}let r=0,a;for(;r<n;)a=r+t,yield e.slice(r,a),r=a},$L=async function*(e,t){for await(const n of kL(e))yield*PL(n,t)},kL=async function*(e){if(e[Symbol.asyncIterator]){yield*e;return}const t=e.getReader();try{for(;;){const{done:n,value:r}=await t.read();if(n)break;yield r}}finally{await t.cancel()}},ww=(e,t,n,r)=>{const a=$L(e,t);let i=0,o,l=s=>{o||(o=!0,r&&r(s))};return new ReadableStream({async pull(s){try{const{done:u,value:d}=await a.next();if(u){l(),s.close();return}let f=d.byteLength;if(n){let h=i+=f;n(h)}s.enqueue(new Uint8Array(d))}catch(u){throw l(u),u}},cancel(s){return l(s),a.return()}},{highWaterMark:2})},Vd=e=>e>=48&&e<=57||e>=65&&e<=70||e>=97&&e<=102,DL=(e,t,n)=>t+2<n&&Vd(e.charCodeAt(t+1))&&Vd(e.charCodeAt(t+2));function LL(e){if(!e||typeof e!="string"||!e.startsWith("data:"))return 0;const t=e.indexOf(",");if(t<0)return 0;const n=e.slice(5,t),r=e.slice(t+1);if(/;base64/i.test(n)){let o=r.length;const l=r.length;for(let p=0;p<l;p++)if(r.charCodeAt(p)===37&&p+2<l){const b=r.charCodeAt(p+1),v=r.charCodeAt(p+2);Vd(b)&&Vd(v)&&(o-=2,p+=2)}let s=0,u=l-1;const d=p=>p>=2&&r.charCodeAt(p-2)===37&&r.charCodeAt(p-1)===51&&(r.charCodeAt(p)===68||r.charCodeAt(p)===100);u>=0&&(r.charCodeAt(u)===61?(s++,u--):d(u)&&(s++,u-=3)),s===1&&u>=0&&(r.charCodeAt(u)===61||d(u))&&s++;const h=Math.floor(o/4)*3-(s||0);return h>0?h:0}let i=0;for(let o=0,l=r.length;o<l;o++){const s=r.charCodeAt(o);if(s===37&&DL(r,o,l))i+=1,o+=2;else if(s<128)i+=1;else if(s<2048)i+=2;else if(s>=55296&&s<=56319&&o+1<l){const u=r.charCodeAt(o+1);u>=56320&&u<=57343?(i+=4,o++):i+=3}else i+=3}return i}const fx="1.18.0",jw=64*1024,{isFunction:Tf}=P,zL=e=>encodeURIComponent(e).replace(/%([0-9A-F]{2})/gi,(t,n)=>String.fromCharCode(parseInt(n,16))),Ow=e=>{if(!P.isString(e))return e;try{return decodeURIComponent(e)}catch{return e}},Aw=(e,...t)=>{try{return!!e(...t)}catch{return!1}},BL=e=>{const t=e.indexOf("://");let n=e;return t!==-1&&(n=n.slice(t+3)),n.includes("@")||n.includes(":")},IL=e=>{const t=P.global!==void 0&&P.global!==null?P.global:globalThis,{ReadableStream:n,TextEncoder:r}=t;e=P.merge.call({skipUndefined:!0},{Request:t.Request,Response:t.Response},e);const{fetch:a,Request:i,Response:o}=e,l=a?Tf(a):typeof fetch=="function",s=Tf(i),u=Tf(o);if(!l)return!1;const d=l&&Tf(n),f=l&&(typeof r=="function"?(m=>y=>m.encode(y))(new r):async m=>new Uint8Array(await new i(m).arrayBuffer())),h=s&&d&&Aw(()=>{let m=!1;const y=new i(It.origin,{body:new n,method:"POST",get duplex(){return m=!0,"half"}}),g=y.headers.has("Content-Type");return y.body!=null&&y.body.cancel(),m&&!g}),p=u&&d&&Aw(()=>P.isReadableStream(new o("").body)),b={stream:p&&(m=>m.body)};l&&["text","arrayBuffer","blob","formData","stream"].forEach(m=>{!b[m]&&(b[m]=(y,g)=>{let S=y&&y[m];if(S)return S.call(y);throw new W(`Response type '${m}' is not supported`,W.ERR_NOT_SUPPORT,g)})});const v=async m=>{if(m==null)return 0;if(P.isBlob(m))return m.size;if(P.isSpecCompliantForm(m))return(await new i(It.origin,{method:"POST",body:m}).arrayBuffer()).byteLength;if(P.isArrayBufferView(m)||P.isArrayBuffer(m))return m.byteLength;if(P.isURLSearchParams(m)&&(m=m+""),P.isString(m))return(await f(m)).byteLength},x=async(m,y)=>{const g=P.toFiniteNumber(m.getContentLength());return g??v(y)};return async m=>{let{url:y,method:g,data:S,signal:w,cancelToken:j,timeout:A,onDownloadProgress:E,onUploadProgress:_,responseType:N,headers:D,withCredentials:R="same-origin",fetchOptions:B,maxContentLength:k,maxBodyLength:C}=XN(m);const M=P.isNumber(k)&&k>-1,L=P.isNumber(C)&&C>-1,z=ce=>P.hasOwnProp(m,ce)?m[ce]:void 0;let F=a||fetch;N=N?(N+"").toLowerCase():"text";let K=RL([w,j&&j.toAbortSignal()],A),G=null;const Y=K&&K.unsubscribe&&(()=>{K.unsubscribe()});let J,me=null;const Le=()=>new W("Request body larger than maxBodyLength limit",W.ERR_BAD_REQUEST,m,G);try{let ce;const $t=z("auth");if($t){const te=P.getSafeProp($t,"username")||"",ze=P.getSafeProp($t,"password")||"";ce={username:te,password:ze}}if(BL(y)){const te=new URL(y,It.origin);if(!ce&&(te.username||te.password)){const ze=Ow(te.username),kt=Ow(te.password);ce={username:ze,password:kt}}(te.username||te.password)&&(te.username="",te.password="",y=te.href)}if(ce&&(D.delete("authorization"),D.set("Authorization","Basic "+btoa(zL((ce.username||"")+":"+(ce.password||""))))),M&&typeof y=="string"&&y.startsWith("data:")&&LL(y)>k)throw new W("maxContentLength size of "+k+" exceeded",W.ERR_BAD_RESPONSE,m,G);if(L&&g!=="get"&&g!=="head"){const te=await v(S);if(typeof te=="number"&&isFinite(te)&&(J=te,te>C))throw Le()}const bt=L&&(P.isReadableStream(S)||P.isStream(S)),Q=(te,ze,kt)=>ww(te,jw,an=>{if(L&&an>C)throw me=Le();ze&&ze(an)},kt);if(h&&g!=="get"&&g!=="head"&&(_||bt)){if(J=J??await x(D,S),J!==0||bt){let te=new i(y,{method:"POST",body:S,duplex:"half"}),ze;if(P.isFormData(S)&&(ze=te.headers.get("content-type"))&&D.setContentType(ze),te.body){const[kt,an]=_&&gw(J,Yd(bw(_)))||[];S=Q(te.body,kt,an)}}}else if(bt&&!s&&d&&g!=="get"&&g!=="head")S=Q(S);else if(bt&&s&&!h&&g!=="get"&&g!=="head")throw new W("Stream request bodies are not supported by the current fetch implementation",W.ERR_NOT_SUPPORT,m,G);P.isString(R)||(R=R?"include":"omit");const le=s&&"credentials"in i.prototype;if(P.isFormData(S)){const te=D.getContentType();te&&/^multipart\/form-data/i.test(te)&&!/boundary=/i.test(te)&&D.delete("content-type")}D.set("User-Agent","axios/"+fx,!1);const fe={...B,signal:K,method:g.toUpperCase(),headers:zN(D.normalize()),body:S,duplex:"half",credentials:le?R:void 0};G=s&&new i(y,fe);let q=await(s?F(G,B):F(y,fe));const Xe=Yt.from(q.headers);if(M){const te=P.toFiniteNumber(Xe.getContentLength());if(te!=null&&te>k)throw new W("maxContentLength size of "+k+" exceeded",W.ERR_BAD_RESPONSE,m,G)}const be=p&&(N==="stream"||N==="response");if(p&&q.body&&(E||M||be&&Y)){const te={};["status","statusText","headers"].forEach(gn=>{te[gn]=q[gn]});const ze=P.toFiniteNumber(Xe.getContentLength()),[kt,an]=E&&gw(ze,Yd(bw(E),!0))||[];let yi=0;const Pr=gn=>{if(M&&(yi=gn,yi>k))throw new W("maxContentLength size of "+k+" exceeded",W.ERR_BAD_RESPONSE,m,G);kt&&kt(gn)};q=new o(ww(q.body,jw,Pr,()=>{an&&an(),Y&&Y()}),te)}N=N||"text";let Re=await b[P.findKey(b,N)||"text"](q,m);if(M&&!p&&!be){let te;if(Re!=null&&(typeof Re.byteLength=="number"?te=Re.byteLength:typeof Re.size=="number"?te=Re.size:typeof Re=="string"&&(te=typeof r=="function"?new r().encode(Re).byteLength:Re.length)),typeof te=="number"&&te>k)throw new W("maxContentLength size of "+k+" exceeded",W.ERR_BAD_RESPONSE,m,G)}return!be&&Y&&Y(),await new Promise((te,ze)=>{YN(te,ze,{data:Re,headers:Yt.from(q.headers),status:q.status,statusText:q.statusText,config:m,request:G})})}catch(ce){if(Y&&Y(),K&&K.aborted&&K.reason instanceof W){const $t=K.reason;throw $t.config=m,G&&($t.request=G),ce!==$t&&($t.cause=ce),$t}throw me?(G&&!me.request&&(me.request=G),me):ce instanceof W?(G&&!ce.request&&(ce.request=G),ce):ce&&ce.name==="TypeError"&&/Load failed|fetch/i.test(ce.message)?Object.assign(new W("Network Error",W.ERR_NETWORK,m,G,ce&&ce.response),{cause:ce.cause||ce}):W.from(ce,ce&&ce.code,m,G,ce&&ce.response)}}},UL=new Map,QN=e=>{let t=e&&e.env||{};const{fetch:n,Request:r,Response:a}=t,i=[r,a,n];let o=i.length,l=o,s,u,d=UL;for(;l--;)s=i[l],u=d.get(s),u===void 0&&d.set(s,u=l?new Map:IL(t)),d=u;return u};QN();const dx={http:eL,xhr:ML,fetch:{get:QN}};P.forEach(dx,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{__proto__:null,value:t})}catch{}Object.defineProperty(e,"adapterName",{__proto__:null,value:t})}});const Ew=e=>`- ${e}`,qL=e=>P.isFunction(e)||e===null||e===!1;function HL(e,t){e=P.isArray(e)?e:[e];const{length:n}=e;let r,a;const i={};for(let o=0;o<n;o++){r=e[o];let l;if(a=r,!qL(r)&&(a=dx[(l=String(r)).toLowerCase()],a===void 0))throw new W(`Unknown adapter '${l}'`);if(a&&(P.isFunction(a)||(a=a.get(t))))break;i[l||"#"+o]=a}if(!a){const o=Object.entries(i).map(([s,u])=>`adapter ${s} `+(u===!1?"is not supported by the environment":"is not available in the build"));let l=n?o.length>1?`since :
`+o.map(Ew).join(`
`):" "+Ew(o[0]):"as no adapter specified";throw new W("There is no suitable adapter to dispatch the request "+l,"ERR_NOT_SUPPORT")}return a}const WN={getAdapter:HL,adapters:dx};function cy(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Zc(null,e)}function _w(e){return cy(e),e.headers=Yt.from(e.headers),e.data=uy.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),WN.getAdapter(e.adapter||Wc.adapter,e)(e).then(function(r){cy(e),e.response=r;try{r.data=uy.call(e,e.transformResponse,r)}finally{delete e.response}return r.headers=Yt.from(r.headers),r},function(r){if(!KN(r)&&(cy(e),r&&r.response)){e.response=r.response;try{r.response.data=uy.call(e,e.transformResponse,r.response)}finally{delete e.response}r.response.headers=Yt.from(r.response.headers)}return Promise.reject(r)})}const Sp={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{Sp[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});const Tw={};Sp.transitional=function(t,n,r){function a(i,o){return"[Axios v"+fx+"] Transitional option '"+i+"'"+o+(r?". "+r:"")}return(i,o,l)=>{if(t===!1)throw new W(a(o," has been removed"+(n?" in "+n:"")),W.ERR_DEPRECATED);return n&&!Tw[o]&&(Tw[o]=!0,console.warn(a(o," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(i,o,l):!0}};Sp.spelling=function(t){return(n,r)=>(console.warn(`${r} is likely a misspelling of ${t}`),!0)};function FL(e,t,n){if(typeof e!="object")throw new W("options must be an object",W.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let a=r.length;for(;a-- >0;){const i=r[a],o=Object.prototype.hasOwnProperty.call(t,i)?t[i]:void 0;if(o){const l=e[i],s=l===void 0||o(l,i,e);if(s!==!0)throw new W("option "+i+" must be "+s,W.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new W("Unknown option "+i,W.ERR_BAD_OPTION)}}const cd={assertOptions:FL,validators:Sp},Ht=cd.validators;let Xi=class{constructor(t){this.defaults=t||{},this.interceptors={request:new yw,response:new yw}}async request(t,n){try{return await this._request(t,n)}catch(r){if(r instanceof Error){let a={};Error.captureStackTrace?Error.captureStackTrace(a):a=new Error;const i=(()=>{if(!a.stack)return"";const o=a.stack.indexOf(`
`);return o===-1?"":a.stack.slice(o+1)})();try{if(!r.stack)r.stack=i;else if(i){const o=i.indexOf(`
`),l=o===-1?-1:i.indexOf(`
`,o+1),s=l===-1?"":i.slice(l+1);String(r.stack).endsWith(s)||(r.stack+=`
`+i)}}catch{}}throw r}}_request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=io(this.defaults,n);const{transitional:r,paramsSerializer:a,headers:i}=n;r!==void 0&&cd.assertOptions(r,{silentJSONParsing:Ht.transitional(Ht.boolean),forcedJSONParsing:Ht.transitional(Ht.boolean),clarifyTimeoutError:Ht.transitional(Ht.boolean),legacyInterceptorReqResOrdering:Ht.transitional(Ht.boolean),advertiseZstdAcceptEncoding:Ht.transitional(Ht.boolean),validateStatusUndefinedResolves:Ht.transitional(Ht.boolean)},!1),a!=null&&(P.isFunction(a)?n.paramsSerializer={serialize:a}:cd.assertOptions(a,{encode:Ht.function,serialize:Ht.function},!0)),n.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?n.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:n.allowAbsoluteUrls=!0),cd.assertOptions(n,{baseUrl:Ht.spelling("baseURL"),withXsrfToken:Ht.spelling("withXSRFToken")},!0),n.method=(n.method||this.defaults.method||"get").toLowerCase();let o=i&&P.merge(i.common,i[n.method]);i&&P.forEach(["delete","get","head","post","put","patch","query","common"],b=>{delete i[b]}),n.headers=Yt.concat(o,i);const l=[];let s=!0;this.interceptors.request.forEach(function(v){if(typeof v.runWhen=="function"&&v.runWhen(n)===!1)return;s=s&&v.synchronous;const x=n.transitional||ux;x&&x.legacyInterceptorReqResOrdering?l.unshift(v.fulfilled,v.rejected):l.push(v.fulfilled,v.rejected)});const u=[];this.interceptors.response.forEach(function(v){u.push(v.fulfilled,v.rejected)});let d,f=0,h;if(!s){const b=[_w.bind(this),void 0];for(b.unshift(...l),b.push(...u),h=b.length,d=Promise.resolve(n);f<h;)d=d.then(b[f++],b[f++]);return d}h=l.length;let p=n;for(;f<h;){const b=l[f++],v=l[f++];try{p=b(p)}catch(x){v.call(this,x);break}}try{d=_w.call(this,p)}catch(b){return Promise.reject(b)}for(f=0,h=u.length;f<h;)d=d.then(u[f++],u[f++]);return d}getUri(t){t=io(this.defaults,t);const n=VN(t.baseURL,t.url,t.allowAbsoluteUrls,t);return HN(n,t.params,t.paramsSerializer)}};P.forEach(["delete","get","head","options"],function(t){Xi.prototype[t]=function(n,r){return this.request(io(r||{},{method:t,url:n,data:r&&P.hasOwnProp(r,"data")?r.data:void 0}))}});P.forEach(["post","put","patch","query"],function(t){function n(r){return function(i,o,l){return this.request(io(l||{},{method:t,headers:r?{"Content-Type":"multipart/form-data"}:{},url:i,data:o}))}}Xi.prototype[t]=n(),t!=="query"&&(Xi.prototype[t+"Form"]=n(!0))});let GL=class ZN{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let n;this.promise=new Promise(function(i){n=i});const r=this;this.promise.then(a=>{if(!r._listeners)return;let i=r._listeners.length;for(;i-- >0;)r._listeners[i](a);r._listeners=null}),this.promise.then=a=>{let i;const o=new Promise(l=>{r.subscribe(l),i=l}).then(a);return o.cancel=function(){r.unsubscribe(i)},o},t(function(i,o,l){r.reason||(r.reason=new Zc(i,o,l),n(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const n=this._listeners.indexOf(t);n!==-1&&this._listeners.splice(n,1)}toAbortSignal(){const t=new AbortController,n=r=>{t.abort(r)};return this.subscribe(n),t.signal.unsubscribe=()=>this.unsubscribe(n),t.signal}static source(){let t;return{token:new ZN(function(a){t=a}),cancel:t}}};function KL(e){return function(n){return e.apply(null,n)}}function YL(e){return P.isObject(e)&&e.isAxiosError===!0}const fg={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries(fg).forEach(([e,t])=>{fg[t]=e});function JN(e){const t=new Xi(e),n=NN(Xi.prototype.request,t);return P.extend(n,Xi.prototype,t,{allOwnKeys:!0}),P.extend(n,t,null,{allOwnKeys:!0}),n.create=function(a){return JN(io(e,a))},n}const dt=JN(Wc);dt.Axios=Xi;dt.CanceledError=Zc;dt.CancelToken=GL;dt.isCancel=KN;dt.VERSION=fx;dt.toFormData=xp;dt.AxiosError=W;dt.Cancel=dt.CanceledError;dt.all=function(t){return Promise.all(t)};dt.spread=KL;dt.isAxiosError=YL;dt.mergeConfig=io;dt.AxiosHeaders=Yt;dt.formToJSON=e=>GN(P.isHTMLForm(e)?new FormData(e):e);dt.getAdapter=WN.getAdapter;dt.HttpStatusCode=fg;dt.default=dt;const{Axios:Gfe,AxiosError:Kfe,CanceledError:Yfe,isCancel:Vfe,CancelToken:Xfe,VERSION:Qfe,all:Wfe,Cancel:Zfe,isAxiosError:Jfe,spread:ede,toFormData:tde,AxiosHeaders:nde,HttpStatusCode:rde,formToJSON:ade,getAdapter:ide,mergeConfig:ode,create:lde}=dt,H=dt.create({baseURL:""});H.interceptors.request.use(e=>{const t=localStorage.getItem("esn_token");return t&&(e.headers.Authorization=`Bearer ${t}`),e});H.interceptors.response.use(e=>e,e=>{var t;return((t=e.response)==null?void 0:t.status)===401&&(localStorage.removeItem("esn_token"),location.pathname!=="/login"&&(location.href="/login")),Promise.reject(e)});const je=e=>e.then(t=>{var n;return(n=t.data)==null?void 0:n.data}),VL=(e,t)=>H.post("/api/auth/login",{username:e,password:t}),eC=()=>H.get("/api/auth/me"),XL=()=>H.post("/api/auth/otp/setup"),QL=e=>H.post("/api/auth/otp/confirm",{code:e}),WL=()=>H.post("/api/auth/otp/disable"),ZL=(e,t)=>H.post("/api/auth/change-password",{currentPassword:e,newPassword:t}),JL=e=>je(H.post(`/api/users/${e}/otp-reset`)),ez=e=>je(H.post("/api/auth/signup",e)),tz=(e,t)=>je(H.post("/api/auth/find-id",{name:e,email:t})),nz=(e,t,n)=>H.post("/api/auth/reset-password",{username:e,name:t,email:n}),rz=e=>je(H.get(`/api/dashboard${e?`?tenantCode=${e}`:""}`)),az=()=>je(H.get("/api/tenants")),iz=e=>je(H.post("/api/tenants",e)),oz=(e,t)=>je(H.put(`/api/tenants/${e}`,t)),lz=e=>H.delete(`/api/tenants/${e}`),sz=e=>je(H.get("/api/stores",{params:e})),uz=e=>je(H.post("/api/stores",e)),cz=(e,t)=>je(H.put(`/api/stores/${e}`,t)),fz=e=>H.delete(`/api/stores/${e}`),dz=e=>je(H.get("/api/templates",{params:e})),hz=e=>je(H.post("/api/templates",e)),pz=(e,t)=>je(H.put(`/api/templates/${e}`,t)),mz=e=>H.delete(`/api/templates/${e}`),yz=e=>je(H.get("/api/pos-cvt",{params:e})),vz=e=>je(H.put(`/api/pos-cvt/${e}/process`)),gz=e=>je(H.put(`/api/pos-cvt/${e}/ignore`)),bz=e=>je(H.get("/api/alarms",{params:e})),xz=(e,t)=>je(H.put(`/api/alarms/${e}/resolve`,{resolution:t})),Sz=e=>H.delete(`/api/alarms/${e}`),wz=e=>je(H.get("/api/hcore",{params:e})),jz=(e,t)=>je(H.put(`/api/hcore/${e}/status`,{status:t})),Oz=e=>je(H.get("/api/works",{params:e})),Az=e=>je(H.get("/api/firmware",{params:e})),Ez=e=>je(H.post("/api/firmware",e)),_z=e=>H.delete(`/api/firmware/${e}`),Tz=e=>je(H.get("/api/users",{params:e})),Nz=e=>je(H.post("/api/users",e)),Cz=(e,t)=>je(H.put(`/api/users/${e}`,t)),Mz=e=>H.delete(`/api/users/${e}`),Rz=e=>je(H.get("/api/products",{params:e})),Pz=e=>je(H.post("/api/products",e)),$z=(e,t)=>je(H.put(`/api/products/${e}`,t)),kz=e=>H.delete(`/api/products/${e}`),Dz=e=>je(H.get("/api/admin/audit",{params:e})),Lz=e=>je(H.get("/api/admin/settings",{params:{}})),zz=(e,t)=>je(H.put(`/api/admin/settings/${encodeURIComponent(e)}`,{value:t})),Bz=e=>je(H.post("/api/ai/analyze-alarm",e)),Iz=e=>je(H.post("/api/ai/classify-pos",e)),Uz=e=>je(H.get("/api/ai/rag/toggles",{params:{tenantCode:e}})),qz=(e,t,n)=>je(H.put(`/api/ai/rag/toggles/${e}`,{value:t,tenantCode:n},n?{headers:{"X-Tenant-Code":n}}:void 0));function Hz(){const e=localStorage.getItem("esn_token");return O.useEffect(()=>{e&&eC().then(t=>{var r;const n=((r=t.data)==null?void 0:r.data)||{};n.role&&localStorage.setItem("esn_role",n.role),n.username&&localStorage.setItem("esn_user",n.username),n.tenant&&localStorage.setItem("esn_tenant",n.tenant)}).catch(()=>{})},[e]),e?c.jsxs("div",{className:"flex h-screen bg-ink",children:[c.jsx(V5,{}),c.jsxs("div",{className:"flex-1 flex flex-col overflow-hidden",children:[c.jsx(X5,{}),c.jsx("main",{className:"flex-1 overflow-auto p-6",children:c.jsx(Dk,{})})]})]}):c.jsx(nN,{to:"/login",replace:!0})}const Fz=(e,t)=>H.post("/api/auth/verify",{verifyToken:e,code:t}),Gz=(e,t)=>H.post("/api/auth/verify-otp",{verifyToken:e,code:t}),Kz=e=>H.post("/api/messages",e),Yz=e=>H.get("/api/messages/sent",{params:e}),Vz=e=>H.get(`/api/messages/sent/${e}`),Xz=e=>H.get("/api/messages/received",{params:e}),Qz=e=>H.get(`/api/messages/received/${e}`),Wz=e=>H.get("/api/schedules",{params:e}),Zz=e=>H.post("/api/schedules",e),Jz=e=>H.get(`/api/schedules/${e}`),e8=e=>H.delete(`/api/schedules/${e}`),t8=e=>H.get("/api/worklogs",{params:e}),n8=e=>H.get("/api/worklogs/dashboard/progress",{params:e}),r8=e=>H.post("/api/worklogs",e),a8=e=>H.get(`/api/worklogs/${e}`),i8=e=>H.delete(`/api/worklogs/${e}`),o8=(e,t)=>H.post(`/api/worklogs/${e}/comments`,{cmtContent:t}),l8=e=>H.get("/api/stats/personal-work",{params:e}),s8=e=>H.get("/api/stats/company-work",{params:e});function u8(){const e=vp(),[t,n]=O.useState(""),[r,a]=O.useState(""),[i,o]=O.useState(""),[l,s]=O.useState(!1),[u,d]=O.useState("login"),[f,h]=O.useState(""),[p,b]=O.useState("EMAIL"),[v,x]=O.useState(""),[m,y]=O.useState(""),[g,S]=O.useState(""),[w,j]=O.useState(""),[A,E]=O.useState(null),_=p==="OTP"||p==="OTP_SETUP",N=p==="OTP_SETUP";function D(C){localStorage.setItem("esn_token",C),localStorage.setItem("esn_user",t),e("/dashboard")}async function R(C){var M;C.preventDefault(),s(!0),o("");try{const z=(M=(await VL(t,r)).data)==null?void 0:M.data;if((z==null?void 0:z.twofa)==="true")h(z.verifyToken),b(z.verifyMethod||"EMAIL"),x(z.maskedEmail||""),y(z.qrImage||""),S(z.secret||""),j(""),d("verify");else{if(!(z!=null&&z.token))throw new Error("토큰 없음");D(z.token)}}catch{o("아이디/비밀번호가 올바르지 않거나 계정이 잠겼습니다.")}finally{s(!1)}}async function B(C){var M,L;C.preventDefault(),s(!0),o("");try{const F=(L=(M=(_?await Gz(f,w):await Fz(f,w)).data)==null?void 0:M.data)==null?void 0:L.token;if(!F)throw new Error("토큰 없음");D(F)}catch{o("인증 코드가 올바르지 않거나 만료되었습니다.")}finally{s(!1)}}function k(){d("login"),j(""),o(""),y(""),S("")}return c.jsxs("div",{className:"min-h-screen bg-ink flex items-center justify-center",children:[c.jsxs("div",{className:"w-full max-w-sm",children:[c.jsxs("div",{className:"text-center mb-8",children:[c.jsx("h1",{className:"text-2xl font-bold text-brand",children:"GUARDiA ESN"}),c.jsx("p",{className:"text-sm text-gray-400 mt-1",children:u==="login"?"ESL 통합 관리 플랫폼":"2차 인증"})]}),u==="login"?c.jsxs("form",{onSubmit:R,className:"bg-card border border-edge rounded-lg p-6 space-y-4",children:[c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"아이디"}),c.jsx("input",{value:t,onChange:C=>n(C.target.value),placeholder:"admin",className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white placeholder-gray-600 focus:border-brand focus:outline-none"})]}),c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"비밀번호"}),c.jsx("input",{type:"password",value:r,onChange:C=>a(C.target.value),placeholder:"••••••••",className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white placeholder-gray-600 focus:border-brand focus:outline-none"})]}),i&&c.jsx("p",{className:"text-red-400 text-xs",children:i}),c.jsx("button",{type:"submit",disabled:l,className:"w-full bg-brand hover:bg-brand2 text-white py-2 rounded text-sm font-medium transition-colors disabled:opacity-50",children:l?"로그인 중...":"로그인"}),c.jsxs("div",{className:"flex items-center justify-center gap-3 pt-1 text-xs text-gray-400",children:[c.jsx("button",{type:"button",onClick:()=>E("signup"),className:"hover:text-brand transition-colors",children:"회원가입"}),c.jsx("span",{className:"text-edge",children:"|"}),c.jsx("button",{type:"button",onClick:()=>E("findId"),className:"hover:text-brand transition-colors",children:"아이디 찾기"}),c.jsx("span",{className:"text-edge",children:"|"}),c.jsx("button",{type:"button",onClick:()=>E("resetPw"),className:"hover:text-brand transition-colors",children:"비밀번호 재설정"})]})]}):c.jsxs("form",{onSubmit:B,className:"bg-card border border-edge rounded-lg p-6 space-y-4",children:[_?N?c.jsxs(c.Fragment,{children:[c.jsx("p",{className:"text-xs text-gray-400",children:"최초 로그인입니다. 아래 QR을 Authenticator 앱(Google·Microsoft)으로 스캔해 등록한 뒤 6자리 코드를 입력하세요."}),m&&c.jsx("div",{className:"flex justify-center",children:c.jsx("img",{src:m,alt:"OTP QR",width:176,height:176,style:{background:"#fff",padding:8,borderRadius:8}})}),g&&c.jsxs("div",{children:[c.jsx("div",{className:"text-[11px] text-gray-500 mb-1",children:"QR 스캔이 안 되면 수동 입력 키"}),c.jsx("code",{className:"block text-xs text-accent bg-panel border border-edge rounded px-2 py-1.5 break-all select-all",children:g})]})]}):c.jsx("p",{className:"text-xs text-gray-400",children:"Authenticator 앱에 표시된 6자리 코드를 입력하세요."}):c.jsx("p",{className:"text-xs text-gray-400",children:v?`${v} 로 발송된 인증코드를 입력하세요.`:"발송된 인증코드를 입력하세요."}),c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"인증코드 6자리"}),c.jsx("input",{inputMode:"numeric",autoComplete:"one-time-code",maxLength:6,value:w,onChange:C=>j(C.target.value.replace(/\D/g,"").slice(0,6)),placeholder:"000000",autoFocus:!0,className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white text-center tracking-[0.4em] placeholder-gray-600 focus:border-brand focus:outline-none"})]}),i&&c.jsx("p",{className:"text-red-400 text-xs",children:i}),c.jsx("button",{type:"submit",disabled:l||w.length!==6,className:"w-full bg-brand hover:bg-brand2 text-white py-2 rounded text-sm font-medium transition-colors disabled:opacity-50",children:l?"인증 중...":N?"등록하고 로그인":"인증하고 로그인"}),c.jsx("button",{type:"button",onClick:k,className:"w-full border border-edge text-gray-400 hover:text-white py-2 rounded text-sm transition-colors",children:"뒤로"})]})]}),A&&c.jsx(c8,{mode:A,onClose:()=>E(null)})]})}function c8({mode:e,onClose:t}){const[n,r]=O.useState(!1),[a,i]=O.useState(""),[o,l]=O.useState(""),[s,u]=O.useState({username:"",password:"",name:"",email:"",phone:"",tenantCode:""}),[d,f]=O.useState({name:"",email:""}),[h,p]=O.useState({username:"",name:"",email:""}),b=e==="signup"?"회원가입":e==="findId"?"아이디 찾기":"비밀번호 재설정";async function v(m){var y,g;m.preventDefault(),r(!0),i(""),l("");try{if(e==="signup"){const S=await ez(s);i(`가입 신청이 접수되었습니다 (아이디: ${S.username}, 상태: 승인 대기).`)}else if(e==="findId"){const S=await tz(d.name,d.email);i(S.found?`회원님의 아이디: ${S.maskedUsername}`:"일치하는 계정 없음")}else await nz(h.username,h.name,h.email),i("임시 비밀번호를 이메일로 발송했습니다.")}catch(S){l(((g=(y=S==null?void 0:S.response)==null?void 0:y.data)==null?void 0:g.message)||"요청 처리 중 오류가 발생했습니다.")}finally{r(!1)}}const x="w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white placeholder-gray-600 focus:border-brand focus:outline-none";return c.jsx("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/60 p-4",onClick:t,children:c.jsxs("div",{className:"w-full max-w-sm bg-card border border-edge rounded-lg p-6",onClick:m=>m.stopPropagation(),children:[c.jsxs("div",{className:"flex items-center justify-between mb-4",children:[c.jsx("h2",{className:"text-sm font-bold text-brand",children:b}),c.jsx("button",{type:"button",onClick:t,className:"text-gray-500 hover:text-white text-sm",children:"✕"})]}),c.jsxs("form",{onSubmit:v,className:"space-y-3",children:[e==="signup"&&c.jsxs(c.Fragment,{children:[c.jsx("input",{className:x,placeholder:"아이디",value:s.username,onChange:m=>u({...s,username:m.target.value})}),c.jsx("input",{className:x,type:"password",placeholder:"비밀번호",value:s.password,onChange:m=>u({...s,password:m.target.value})}),c.jsx("input",{className:x,placeholder:"이름",value:s.name,onChange:m=>u({...s,name:m.target.value})}),c.jsx("input",{className:x,type:"email",placeholder:"이메일",value:s.email,onChange:m=>u({...s,email:m.target.value})}),c.jsx("input",{className:x,placeholder:"연락처",value:s.phone,onChange:m=>u({...s,phone:m.target.value})}),c.jsx("input",{className:x,placeholder:"기관 코드 (선택)",value:s.tenantCode,onChange:m=>u({...s,tenantCode:m.target.value})})]}),e==="findId"&&c.jsxs(c.Fragment,{children:[c.jsx("input",{className:x,placeholder:"이름",value:d.name,onChange:m=>f({...d,name:m.target.value})}),c.jsx("input",{className:x,type:"email",placeholder:"이메일",value:d.email,onChange:m=>f({...d,email:m.target.value})})]}),e==="resetPw"&&c.jsxs(c.Fragment,{children:[c.jsx("input",{className:x,placeholder:"아이디",value:h.username,onChange:m=>p({...h,username:m.target.value})}),c.jsx("input",{className:x,placeholder:"이름",value:h.name,onChange:m=>p({...h,name:m.target.value})}),c.jsx("input",{className:x,type:"email",placeholder:"이메일",value:h.email,onChange:m=>p({...h,email:m.target.value})})]}),a&&c.jsx("p",{className:"text-green-400 text-xs",children:a}),o&&c.jsx("p",{className:"text-red-400 text-xs",children:o}),c.jsx("button",{type:"submit",disabled:n,className:"w-full bg-brand hover:bg-brand2 text-white py-2 rounded text-sm font-medium transition-colors disabled:opacity-50",children:n?"처리 중...":b})]})]})})}function tC(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var a=e.length;for(t=0;t<a;t++)e[t]&&(n=tC(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function ve(){for(var e,t,n=0,r="",a=arguments.length;n<a;n++)(e=arguments[n])&&(t=tC(e))&&(r&&(r+=" "),r+=t);return r}var f8=Array.isArray,vn=f8,d8=typeof uf=="object"&&uf&&uf.Object===Object&&uf,nC=d8,h8=nC,p8=typeof self=="object"&&self&&self.Object===Object&&self,m8=h8||p8||Function("return this")(),Mr=m8,y8=Mr,v8=y8.Symbol,Jc=v8,Nw=Jc,rC=Object.prototype,g8=rC.hasOwnProperty,b8=rC.toString,Gs=Nw?Nw.toStringTag:void 0;function x8(e){var t=g8.call(e,Gs),n=e[Gs];try{e[Gs]=void 0;var r=!0}catch{}var a=b8.call(e);return r&&(t?e[Gs]=n:delete e[Gs]),a}var S8=x8,w8=Object.prototype,j8=w8.toString;function O8(e){return j8.call(e)}var A8=O8,Cw=Jc,E8=S8,_8=A8,T8="[object Null]",N8="[object Undefined]",Mw=Cw?Cw.toStringTag:void 0;function C8(e){return e==null?e===void 0?N8:T8:Mw&&Mw in Object(e)?E8(e):_8(e)}var va=C8;function M8(e){return e!=null&&typeof e=="object"}var ga=M8,R8=va,P8=ga,$8="[object Symbol]";function k8(e){return typeof e=="symbol"||P8(e)&&R8(e)==$8}var Os=k8,D8=vn,L8=Os,z8=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,B8=/^\w*$/;function I8(e,t){if(D8(e))return!1;var n=typeof e;return n=="number"||n=="symbol"||n=="boolean"||e==null||L8(e)?!0:B8.test(e)||!z8.test(e)||t!=null&&e in Object(t)}var hx=I8;function U8(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var ci=U8;const As=qe(ci);var q8=va,H8=ci,F8="[object AsyncFunction]",G8="[object Function]",K8="[object GeneratorFunction]",Y8="[object Proxy]";function V8(e){if(!H8(e))return!1;var t=q8(e);return t==G8||t==K8||t==F8||t==Y8}var px=V8;const se=qe(px);var X8=Mr,Q8=X8["__core-js_shared__"],W8=Q8,fy=W8,Rw=function(){var e=/[^.]+$/.exec(fy&&fy.keys&&fy.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function Z8(e){return!!Rw&&Rw in e}var J8=Z8,eB=Function.prototype,tB=eB.toString;function nB(e){if(e!=null){try{return tB.call(e)}catch{}try{return e+""}catch{}}return""}var aC=nB,rB=px,aB=J8,iB=ci,oB=aC,lB=/[\\^$.*+?()[\]{}|]/g,sB=/^\[object .+?Constructor\]$/,uB=Function.prototype,cB=Object.prototype,fB=uB.toString,dB=cB.hasOwnProperty,hB=RegExp("^"+fB.call(dB).replace(lB,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function pB(e){if(!iB(e)||aB(e))return!1;var t=rB(e)?hB:sB;return t.test(oB(e))}var mB=pB;function yB(e,t){return e==null?void 0:e[t]}var vB=yB,gB=mB,bB=vB;function xB(e,t){var n=bB(e,t);return gB(n)?n:void 0}var go=xB,SB=go,wB=SB(Object,"create"),wp=wB,Pw=wp;function jB(){this.__data__=Pw?Pw(null):{},this.size=0}var OB=jB;function AB(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var EB=AB,_B=wp,TB="__lodash_hash_undefined__",NB=Object.prototype,CB=NB.hasOwnProperty;function MB(e){var t=this.__data__;if(_B){var n=t[e];return n===TB?void 0:n}return CB.call(t,e)?t[e]:void 0}var RB=MB,PB=wp,$B=Object.prototype,kB=$B.hasOwnProperty;function DB(e){var t=this.__data__;return PB?t[e]!==void 0:kB.call(t,e)}var LB=DB,zB=wp,BB="__lodash_hash_undefined__";function IB(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=zB&&t===void 0?BB:t,this}var UB=IB,qB=OB,HB=EB,FB=RB,GB=LB,KB=UB;function Es(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}Es.prototype.clear=qB;Es.prototype.delete=HB;Es.prototype.get=FB;Es.prototype.has=GB;Es.prototype.set=KB;var YB=Es;function VB(){this.__data__=[],this.size=0}var XB=VB;function QB(e,t){return e===t||e!==e&&t!==t}var mx=QB,WB=mx;function ZB(e,t){for(var n=e.length;n--;)if(WB(e[n][0],t))return n;return-1}var jp=ZB,JB=jp,eI=Array.prototype,tI=eI.splice;function nI(e){var t=this.__data__,n=JB(t,e);if(n<0)return!1;var r=t.length-1;return n==r?t.pop():tI.call(t,n,1),--this.size,!0}var rI=nI,aI=jp;function iI(e){var t=this.__data__,n=aI(t,e);return n<0?void 0:t[n][1]}var oI=iI,lI=jp;function sI(e){return lI(this.__data__,e)>-1}var uI=sI,cI=jp;function fI(e,t){var n=this.__data__,r=cI(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}var dI=fI,hI=XB,pI=rI,mI=oI,yI=uI,vI=dI;function _s(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}_s.prototype.clear=hI;_s.prototype.delete=pI;_s.prototype.get=mI;_s.prototype.has=yI;_s.prototype.set=vI;var Op=_s,gI=go,bI=Mr,xI=gI(bI,"Map"),yx=xI,$w=YB,SI=Op,wI=yx;function jI(){this.size=0,this.__data__={hash:new $w,map:new(wI||SI),string:new $w}}var OI=jI;function AI(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}var EI=AI,_I=EI;function TI(e,t){var n=e.__data__;return _I(t)?n[typeof t=="string"?"string":"hash"]:n.map}var Ap=TI,NI=Ap;function CI(e){var t=NI(this,e).delete(e);return this.size-=t?1:0,t}var MI=CI,RI=Ap;function PI(e){return RI(this,e).get(e)}var $I=PI,kI=Ap;function DI(e){return kI(this,e).has(e)}var LI=DI,zI=Ap;function BI(e,t){var n=zI(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this}var II=BI,UI=OI,qI=MI,HI=$I,FI=LI,GI=II;function Ts(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}Ts.prototype.clear=UI;Ts.prototype.delete=qI;Ts.prototype.get=HI;Ts.prototype.has=FI;Ts.prototype.set=GI;var vx=Ts,iC=vx,KI="Expected a function";function gx(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(KI);var n=function(){var r=arguments,a=t?t.apply(this,r):r[0],i=n.cache;if(i.has(a))return i.get(a);var o=e.apply(this,r);return n.cache=i.set(a,o)||i,o};return n.cache=new(gx.Cache||iC),n}gx.Cache=iC;var oC=gx;const YI=qe(oC);var VI=oC,XI=500;function QI(e){var t=VI(e,function(r){return n.size===XI&&n.clear(),r}),n=t.cache;return t}var WI=QI,ZI=WI,JI=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,eU=/\\(\\)?/g,tU=ZI(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(JI,function(n,r,a,i){t.push(a?i.replace(eU,"$1"):r||n)}),t}),nU=tU;function rU(e,t){for(var n=-1,r=e==null?0:e.length,a=Array(r);++n<r;)a[n]=t(e[n],n,e);return a}var bx=rU,kw=Jc,aU=bx,iU=vn,oU=Os,Dw=kw?kw.prototype:void 0,Lw=Dw?Dw.toString:void 0;function lC(e){if(typeof e=="string")return e;if(iU(e))return aU(e,lC)+"";if(oU(e))return Lw?Lw.call(e):"";var t=e+"";return t=="0"&&1/e==-1/0?"-0":t}var lU=lC,sU=lU;function uU(e){return e==null?"":sU(e)}var sC=uU,cU=vn,fU=hx,dU=nU,hU=sC;function pU(e,t){return cU(e)?e:fU(e,t)?[e]:dU(hU(e))}var uC=pU,mU=Os;function yU(e){if(typeof e=="string"||mU(e))return e;var t=e+"";return t=="0"&&1/e==-1/0?"-0":t}var Ep=yU,vU=uC,gU=Ep;function bU(e,t){t=vU(t,e);for(var n=0,r=t.length;e!=null&&n<r;)e=e[gU(t[n++])];return n&&n==r?e:void 0}var xx=bU,xU=xx;function SU(e,t,n){var r=e==null?void 0:xU(e,t);return r===void 0?n:r}var cC=SU;const Rn=qe(cC);function wU(e){return e==null}var jU=wU;const ge=qe(jU);var OU=va,AU=vn,EU=ga,_U="[object String]";function TU(e){return typeof e=="string"||!AU(e)&&EU(e)&&OU(e)==_U}var NU=TU;const oo=qe(NU);var fC={exports:{}},De={};/**
 * @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 Sx=Symbol.for("react.element"),wx=Symbol.for("react.portal"),_p=Symbol.for("react.fragment"),Tp=Symbol.for("react.strict_mode"),Np=Symbol.for("react.profiler"),Cp=Symbol.for("react.provider"),Mp=Symbol.for("react.context"),CU=Symbol.for("react.server_context"),Rp=Symbol.for("react.forward_ref"),Pp=Symbol.for("react.suspense"),$p=Symbol.for("react.suspense_list"),kp=Symbol.for("react.memo"),Dp=Symbol.for("react.lazy"),MU=Symbol.for("react.offscreen"),dC;dC=Symbol.for("react.module.reference");function tr(e){if(typeof e=="object"&&e!==null){var t=e.$$typeof;switch(t){case Sx:switch(e=e.type,e){case _p:case Np:case Tp:case Pp:case $p:return e;default:switch(e=e&&e.$$typeof,e){case CU:case Mp:case Rp:case Dp:case kp:case Cp:return e;default:return t}}case wx:return t}}}De.ContextConsumer=Mp;De.ContextProvider=Cp;De.Element=Sx;De.ForwardRef=Rp;De.Fragment=_p;De.Lazy=Dp;De.Memo=kp;De.Portal=wx;De.Profiler=Np;De.StrictMode=Tp;De.Suspense=Pp;De.SuspenseList=$p;De.isAsyncMode=function(){return!1};De.isConcurrentMode=function(){return!1};De.isContextConsumer=function(e){return tr(e)===Mp};De.isContextProvider=function(e){return tr(e)===Cp};De.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===Sx};De.isForwardRef=function(e){return tr(e)===Rp};De.isFragment=function(e){return tr(e)===_p};De.isLazy=function(e){return tr(e)===Dp};De.isMemo=function(e){return tr(e)===kp};De.isPortal=function(e){return tr(e)===wx};De.isProfiler=function(e){return tr(e)===Np};De.isStrictMode=function(e){return tr(e)===Tp};De.isSuspense=function(e){return tr(e)===Pp};De.isSuspenseList=function(e){return tr(e)===$p};De.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===_p||e===Np||e===Tp||e===Pp||e===$p||e===MU||typeof e=="object"&&e!==null&&(e.$$typeof===Dp||e.$$typeof===kp||e.$$typeof===Cp||e.$$typeof===Mp||e.$$typeof===Rp||e.$$typeof===dC||e.getModuleId!==void 0)};De.typeOf=tr;fC.exports=De;var RU=fC.exports,PU=va,$U=ga,kU="[object Number]";function DU(e){return typeof e=="number"||$U(e)&&PU(e)==kU}var hC=DU;const LU=qe(hC);var zU=hC;function BU(e){return zU(e)&&e!=+e}var IU=BU;const ef=qe(IU);var Jt=function(t){return t===0?0:t>0?1:-1},Mi=function(t){return oo(t)&&t.indexOf("%")===t.length-1},V=function(t){return LU(t)&&!ef(t)},UU=function(t){return ge(t)},Ot=function(t){return V(t)||oo(t)},qU=0,tf=function(t){var n=++qU;return"".concat(t||"").concat(n)},en=function(t,n){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,a=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;if(!V(t)&&!oo(t))return r;var i;if(Mi(t)){var o=t.indexOf("%");i=n*parseFloat(t.slice(0,o))/100}else i=+t;return ef(i)&&(i=r),a&&i>n&&(i=n),i},$o=function(t){if(!t)return null;var n=Object.keys(t);return n&&n.length?t[n[0]]:null},HU=function(t){if(!Array.isArray(t))return!1;for(var n=t.length,r={},a=0;a<n;a++)if(!r[t[a]])r[t[a]]=!0;else return!0;return!1},Aa=function(t,n){return V(t)&&V(n)?function(r){return t+r*(n-t)}:function(){return n}};function dg(e,t,n){return!e||!e.length?null:e.find(function(r){return r&&(typeof t=="function"?t(r):Rn(r,t))===n})}var FU=function(t,n){return V(t)&&V(n)?t-n:oo(t)&&oo(n)?t.localeCompare(n):t instanceof Date&&n instanceof Date?t.getTime()-n.getTime():String(t).localeCompare(String(n))};function ol(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 hg(e){"@babel/helpers - typeof";return hg=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},hg(e)}var GU=["viewBox","children"],KU=["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"],zw=["points","pathLength"],dy={svg:GU,polygon:zw,polyline:zw},jx=["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"],Xd=function(t,n){if(!t||typeof t=="function"||typeof t=="boolean")return null;var r=t;if(O.isValidElement(t)&&(r=t.props),!As(r))return null;var a={};return Object.keys(r).forEach(function(i){jx.includes(i)&&(a[i]=n||function(o){return r[i](r,o)})}),a},YU=function(t,n,r){return function(a){return t(n,r,a),null}},lo=function(t,n,r){if(!As(t)||hg(t)!=="object")return null;var a=null;return Object.keys(t).forEach(function(i){var o=t[i];jx.includes(i)&&typeof o=="function"&&(a||(a={}),a[i]=YU(o,n,r))}),a},VU=["children"],XU=["children"];function Bw(e,t){if(e==null)return{};var n=QU(e,t),r,a;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(a=0;a<i.length;a++)r=i[a],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function QU(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 Iw={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"},na=function(t){return typeof t=="string"?t:t?t.displayName||t.name||"Component":""},Uw=null,hy=null,Ox=function e(t){if(t===Uw&&Array.isArray(hy))return hy;var n=[];return O.Children.forEach(t,function(r){ge(r)||(RU.isFragment(r)?n=n.concat(e(r.props.children)):n.push(r))}),hy=n,Uw=t,n};function Wn(e,t){var n=[],r=[];return Array.isArray(t)?r=t.map(function(a){return na(a)}):r=[na(t)],Ox(e).forEach(function(a){var i=Rn(a,"type.displayName")||Rn(a,"type.name");r.indexOf(i)!==-1&&n.push(a)}),n}function Sn(e,t){var n=Wn(e,t);return n&&n[0]}var qw=function(t){if(!t||!t.props)return!1;var n=t.props,r=n.width,a=n.height;return!(!V(r)||r<=0||!V(a)||a<=0)},WU=["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"],ZU=function(t){return t&&t.type&&oo(t.type)&&WU.indexOf(t.type)>=0},JU=function(t,n,r,a){var i,o=(i=dy==null?void 0:dy[a])!==null&&i!==void 0?i:[];return n.startsWith("data-")||!se(t)&&(a&&o.includes(n)||KU.includes(n))||r&&jx.includes(n)},oe=function(t,n,r){if(!t||typeof t=="function"||typeof t=="boolean")return null;var a=t;if(O.isValidElement(t)&&(a=t.props),!As(a))return null;var i={};return Object.keys(a).forEach(function(o){var l;JU((l=a)===null||l===void 0?void 0:l[o],o,n,r)&&(i[o]=a[o])}),i},pg=function e(t,n){if(t===n)return!0;var r=O.Children.count(t);if(r!==O.Children.count(n))return!1;if(r===0)return!0;if(r===1)return Hw(Array.isArray(t)?t[0]:t,Array.isArray(n)?n[0]:n);for(var a=0;a<r;a++){var i=t[a],o=n[a];if(Array.isArray(i)||Array.isArray(o)){if(!e(i,o))return!1}else if(!Hw(i,o))return!1}return!0},Hw=function(t,n){if(ge(t)&&ge(n))return!0;if(!ge(t)&&!ge(n)){var r=t.props||{},a=r.children,i=Bw(r,VU),o=n.props||{},l=o.children,s=Bw(o,XU);return a&&l?ol(i,s)&&pg(a,l):!a&&!l?ol(i,s):!1}return!1},Fw=function(t,n){var r=[],a={};return Ox(t).forEach(function(i,o){if(ZU(i))r.push(i);else if(i){var l=na(i.type),s=n[l]||{},u=s.handler,d=s.once;if(u&&(!d||!a[l])){var f=u(i,l,o);r.push(f),a[l]=!0}}}),r},e7=function(t){var n=t&&t.type;return n&&Iw[n]?Iw[n]:null},t7=function(t,n){return Ox(n).indexOf(t)},n7=["children","width","height","viewBox","className","style","title","desc"];function mg(){return mg=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},mg.apply(this,arguments)}function r7(e,t){if(e==null)return{};var n=a7(e,t),r,a;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(a=0;a<i.length;a++)r=i[a],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function a7(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 yg(e){var t=e.children,n=e.width,r=e.height,a=e.viewBox,i=e.className,o=e.style,l=e.title,s=e.desc,u=r7(e,n7),d=a||{width:n,height:r,x:0,y:0},f=ve("recharts-surface",i);return $.createElement("svg",mg({},oe(u,!0,"svg"),{className:f,width:n,height:r,style:o,viewBox:"".concat(d.x," ").concat(d.y," ").concat(d.width," ").concat(d.height)}),$.createElement("title",null,l),$.createElement("desc",null,s),t)}var i7=["children","className"];function vg(){return vg=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},vg.apply(this,arguments)}function o7(e,t){if(e==null)return{};var n=l7(e,t),r,a;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(a=0;a<i.length;a++)r=i[a],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function l7(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 ke=$.forwardRef(function(e,t){var n=e.children,r=e.className,a=o7(e,i7),i=ve("recharts-layer",r);return $.createElement("g",vg({className:i},oe(a,!0),{ref:t}),n)}),ra=function(t,n){for(var r=arguments.length,a=new Array(r>2?r-2:0),i=2;i<r;i++)a[i-2]=arguments[i]};function s7(e,t,n){var r=-1,a=e.length;t<0&&(t=-t>a?0:a+t),n=n>a?a:n,n<0&&(n+=a),a=t>n?0:n-t>>>0,t>>>=0;for(var i=Array(a);++r<a;)i[r]=e[r+t];return i}var u7=s7,c7=u7;function f7(e,t,n){var r=e.length;return n=n===void 0?r:n,!t&&n>=r?e:c7(e,t,n)}var d7=f7,h7="\\ud800-\\udfff",p7="\\u0300-\\u036f",m7="\\ufe20-\\ufe2f",y7="\\u20d0-\\u20ff",v7=p7+m7+y7,g7="\\ufe0e\\ufe0f",b7="\\u200d",x7=RegExp("["+b7+h7+v7+g7+"]");function S7(e){return x7.test(e)}var pC=S7;function w7(e){return e.split("")}var j7=w7,mC="\\ud800-\\udfff",O7="\\u0300-\\u036f",A7="\\ufe20-\\ufe2f",E7="\\u20d0-\\u20ff",_7=O7+A7+E7,T7="\\ufe0e\\ufe0f",N7="["+mC+"]",gg="["+_7+"]",bg="\\ud83c[\\udffb-\\udfff]",C7="(?:"+gg+"|"+bg+")",yC="[^"+mC+"]",vC="(?:\\ud83c[\\udde6-\\uddff]){2}",gC="[\\ud800-\\udbff][\\udc00-\\udfff]",M7="\\u200d",bC=C7+"?",xC="["+T7+"]?",R7="(?:"+M7+"(?:"+[yC,vC,gC].join("|")+")"+xC+bC+")*",P7=xC+bC+R7,$7="(?:"+[yC+gg+"?",gg,vC,gC,N7].join("|")+")",k7=RegExp(bg+"(?="+bg+")|"+$7+P7,"g");function D7(e){return e.match(k7)||[]}var L7=D7,z7=j7,B7=pC,I7=L7;function U7(e){return B7(e)?I7(e):z7(e)}var q7=U7,H7=d7,F7=pC,G7=q7,K7=sC;function Y7(e){return function(t){t=K7(t);var n=F7(t)?G7(t):void 0,r=n?n[0]:t.charAt(0),a=n?H7(n,1).join(""):t.slice(1);return r[e]()+a}}var V7=Y7,X7=V7,Q7=X7("toUpperCase"),W7=Q7;const Lp=qe(W7);function Ke(e){return function(){return e}}const SC=Math.cos,Qd=Math.sin,yr=Math.sqrt,Wd=Math.PI,zp=2*Wd,xg=Math.PI,Sg=2*xg,Ai=1e-6,Z7=Sg-Ai;function wC(e){this._+=e[0];for(let t=1,n=e.length;t<n;++t)this._+=arguments[t]+e[t]}function J7(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return wC;const n=10**t;return function(r){this._+=r[0];for(let a=1,i=r.length;a<i;++a)this._+=Math.round(arguments[a]*n)/n+r[a]}}class e9{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=t==null?wC:J7(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,a){this._append`Q${+t},${+n},${this._x1=+r},${this._y1=+a}`}bezierCurveTo(t,n,r,a,i,o){this._append`C${+t},${+n},${+r},${+a},${this._x1=+i},${this._y1=+o}`}arcTo(t,n,r,a,i){if(t=+t,n=+n,r=+r,a=+a,i=+i,i<0)throw new Error(`negative radius: ${i}`);let o=this._x1,l=this._y1,s=r-t,u=a-n,d=o-t,f=l-n,h=d*d+f*f;if(this._x1===null)this._append`M${this._x1=t},${this._y1=n}`;else if(h>Ai)if(!(Math.abs(f*s-u*d)>Ai)||!i)this._append`L${this._x1=t},${this._y1=n}`;else{let p=r-o,b=a-l,v=s*s+u*u,x=p*p+b*b,m=Math.sqrt(v),y=Math.sqrt(h),g=i*Math.tan((xg-Math.acos((v+h-x)/(2*m*y)))/2),S=g/y,w=g/m;Math.abs(S-1)>Ai&&this._append`L${t+S*d},${n+S*f}`,this._append`A${i},${i},0,0,${+(f*p>d*b)},${this._x1=t+w*s},${this._y1=n+w*u}`}}arc(t,n,r,a,i,o){if(t=+t,n=+n,r=+r,o=!!o,r<0)throw new Error(`negative radius: ${r}`);let l=r*Math.cos(a),s=r*Math.sin(a),u=t+l,d=n+s,f=1^o,h=o?a-i:i-a;this._x1===null?this._append`M${u},${d}`:(Math.abs(this._x1-u)>Ai||Math.abs(this._y1-d)>Ai)&&this._append`L${u},${d}`,r&&(h<0&&(h=h%Sg+Sg),h>Z7?this._append`A${r},${r},0,1,${f},${t-l},${n-s}A${r},${r},0,1,${f},${this._x1=u},${this._y1=d}`:h>Ai&&this._append`A${r},${r},0,${+(h>=xg)},${f},${this._x1=t+r*Math.cos(i)},${this._y1=n+r*Math.sin(i)}`)}rect(t,n,r,a){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}h${r=+r}v${+a}h${-r}Z`}toString(){return this._}}function Ax(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 e9(t)}function Ex(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function jC(e){this._context=e}jC.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 Bp(e){return new jC(e)}function OC(e){return e[0]}function AC(e){return e[1]}function EC(e,t){var n=Ke(!0),r=null,a=Bp,i=null,o=Ax(l);e=typeof e=="function"?e:e===void 0?OC:Ke(e),t=typeof t=="function"?t:t===void 0?AC:Ke(t);function l(s){var u,d=(s=Ex(s)).length,f,h=!1,p;for(r==null&&(i=a(p=o())),u=0;u<=d;++u)!(u<d&&n(f=s[u],u,s))===h&&((h=!h)?i.lineStart():i.lineEnd()),h&&i.point(+e(f,u,s),+t(f,u,s));if(p)return i=null,p+""||null}return l.x=function(s){return arguments.length?(e=typeof s=="function"?s:Ke(+s),l):e},l.y=function(s){return arguments.length?(t=typeof s=="function"?s:Ke(+s),l):t},l.defined=function(s){return arguments.length?(n=typeof s=="function"?s:Ke(!!s),l):n},l.curve=function(s){return arguments.length?(a=s,r!=null&&(i=a(r)),l):a},l.context=function(s){return arguments.length?(s==null?r=i=null:i=a(r=s),l):r},l}function Nf(e,t,n){var r=null,a=Ke(!0),i=null,o=Bp,l=null,s=Ax(u);e=typeof e=="function"?e:e===void 0?OC:Ke(+e),t=typeof t=="function"?t:Ke(t===void 0?0:+t),n=typeof n=="function"?n:n===void 0?AC:Ke(+n);function u(f){var h,p,b,v=(f=Ex(f)).length,x,m=!1,y,g=new Array(v),S=new Array(v);for(i==null&&(l=o(y=s())),h=0;h<=v;++h){if(!(h<v&&a(x=f[h],h,f))===m)if(m=!m)p=h,l.areaStart(),l.lineStart();else{for(l.lineEnd(),l.lineStart(),b=h-1;b>=p;--b)l.point(g[b],S[b]);l.lineEnd(),l.areaEnd()}m&&(g[h]=+e(x,h,f),S[h]=+t(x,h,f),l.point(r?+r(x,h,f):g[h],n?+n(x,h,f):S[h]))}if(y)return l=null,y+""||null}function d(){return EC().defined(a).curve(o).context(i)}return u.x=function(f){return arguments.length?(e=typeof f=="function"?f:Ke(+f),r=null,u):e},u.x0=function(f){return arguments.length?(e=typeof f=="function"?f:Ke(+f),u):e},u.x1=function(f){return arguments.length?(r=f==null?null:typeof f=="function"?f:Ke(+f),u):r},u.y=function(f){return arguments.length?(t=typeof f=="function"?f:Ke(+f),n=null,u):t},u.y0=function(f){return arguments.length?(t=typeof f=="function"?f:Ke(+f),u):t},u.y1=function(f){return arguments.length?(n=f==null?null:typeof f=="function"?f:Ke(+f),u):n},u.lineX0=u.lineY0=function(){return d().x(e).y(t)},u.lineY1=function(){return d().x(e).y(n)},u.lineX1=function(){return d().x(r).y(t)},u.defined=function(f){return arguments.length?(a=typeof f=="function"?f:Ke(!!f),u):a},u.curve=function(f){return arguments.length?(o=f,i!=null&&(l=o(i)),u):o},u.context=function(f){return arguments.length?(f==null?i=l=null:l=o(i=f),u):i},u}class _C{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 t9(e){return new _C(e,!0)}function n9(e){return new _C(e,!1)}const _x={draw(e,t){const n=yr(t/Wd);e.moveTo(n,0),e.arc(0,0,n,0,zp)}},r9={draw(e,t){const n=yr(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()}},TC=yr(1/3),a9=TC*2,i9={draw(e,t){const n=yr(t/a9),r=n*TC;e.moveTo(0,-n),e.lineTo(r,0),e.lineTo(0,n),e.lineTo(-r,0),e.closePath()}},o9={draw(e,t){const n=yr(t),r=-n/2;e.rect(r,r,n,n)}},l9=.8908130915292852,NC=Qd(Wd/10)/Qd(7*Wd/10),s9=Qd(zp/10)*NC,u9=-SC(zp/10)*NC,c9={draw(e,t){const n=yr(t*l9),r=s9*n,a=u9*n;e.moveTo(0,-n),e.lineTo(r,a);for(let i=1;i<5;++i){const o=zp*i/5,l=SC(o),s=Qd(o);e.lineTo(s*n,-l*n),e.lineTo(l*r-s*a,s*r+l*a)}e.closePath()}},py=yr(3),f9={draw(e,t){const n=-yr(t/(py*3));e.moveTo(0,n*2),e.lineTo(-py*n,-n),e.lineTo(py*n,-n),e.closePath()}},Dn=-.5,Ln=yr(3)/2,wg=1/yr(12),d9=(wg/2+1)*3,h9={draw(e,t){const n=yr(t/d9),r=n/2,a=n*wg,i=r,o=n*wg+n,l=-i,s=o;e.moveTo(r,a),e.lineTo(i,o),e.lineTo(l,s),e.lineTo(Dn*r-Ln*a,Ln*r+Dn*a),e.lineTo(Dn*i-Ln*o,Ln*i+Dn*o),e.lineTo(Dn*l-Ln*s,Ln*l+Dn*s),e.lineTo(Dn*r+Ln*a,Dn*a-Ln*r),e.lineTo(Dn*i+Ln*o,Dn*o-Ln*i),e.lineTo(Dn*l+Ln*s,Dn*s-Ln*l),e.closePath()}};function p9(e,t){let n=null,r=Ax(a);e=typeof e=="function"?e:Ke(e||_x),t=typeof t=="function"?t:Ke(t===void 0?64:+t);function a(){let i;if(n||(n=i=r()),e.apply(this,arguments).draw(n,+t.apply(this,arguments)),i)return n=null,i+""||null}return a.type=function(i){return arguments.length?(e=typeof i=="function"?i:Ke(i),a):e},a.size=function(i){return arguments.length?(t=typeof i=="function"?i:Ke(+i),a):t},a.context=function(i){return arguments.length?(n=i??null,a):n},a}function Zd(){}function Jd(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 CC(e){this._context=e}CC.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:Jd(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:Jd(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function m9(e){return new CC(e)}function MC(e){this._context=e}MC.prototype={areaStart:Zd,areaEnd:Zd,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:Jd(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function y9(e){return new MC(e)}function RC(e){this._context=e}RC.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:Jd(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function v9(e){return new RC(e)}function PC(e){this._context=e}PC.prototype={areaStart:Zd,areaEnd:Zd,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 g9(e){return new PC(e)}function Gw(e){return e<0?-1:1}function Kw(e,t,n){var r=e._x1-e._x0,a=t-e._x1,i=(e._y1-e._y0)/(r||a<0&&-0),o=(n-e._y1)/(a||r<0&&-0),l=(i*a+o*r)/(r+a);return(Gw(i)+Gw(o))*Math.min(Math.abs(i),Math.abs(o),.5*Math.abs(l))||0}function Yw(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function my(e,t,n){var r=e._x0,a=e._y0,i=e._x1,o=e._y1,l=(i-r)/3;e._context.bezierCurveTo(r+l,a+l*t,i-l,o-l*n,i,o)}function eh(e){this._context=e}eh.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:my(this,this._t0,Yw(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,my(this,Yw(this,n=Kw(this,e,t)),n);break;default:my(this,this._t0,n=Kw(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=n}}};function $C(e){this._context=new kC(e)}($C.prototype=Object.create(eh.prototype)).point=function(e,t){eh.prototype.point.call(this,t,e)};function kC(e){this._context=e}kC.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,a,i){this._context.bezierCurveTo(t,e,r,n,i,a)}};function b9(e){return new eh(e)}function x9(e){return new $C(e)}function DC(e){this._context=e}DC.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=Vw(e),a=Vw(t),i=0,o=1;o<n;++i,++o)this._context.bezierCurveTo(r[0][i],a[0][i],r[1][i],a[1][i],e[o],t[o]);(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 Vw(e){var t,n=e.length-1,r,a=new Array(n),i=new Array(n),o=new Array(n);for(a[0]=0,i[0]=2,o[0]=e[0]+2*e[1],t=1;t<n-1;++t)a[t]=1,i[t]=4,o[t]=4*e[t]+2*e[t+1];for(a[n-1]=2,i[n-1]=7,o[n-1]=8*e[n-1]+e[n],t=1;t<n;++t)r=a[t]/i[t-1],i[t]-=r,o[t]-=r*o[t-1];for(a[n-1]=o[n-1]/i[n-1],t=n-2;t>=0;--t)a[t]=(o[t]-a[t+1])/i[t];for(i[n-1]=(e[n]+a[n-1])/2,t=0;t<n-1;++t)i[t]=2*e[t+1]-a[t+1];return[a,i]}function S9(e){return new DC(e)}function Ip(e,t){this._context=e,this._t=t}Ip.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 w9(e){return new Ip(e,.5)}function j9(e){return new Ip(e,0)}function O9(e){return new Ip(e,1)}function zl(e,t){if((o=e.length)>1)for(var n=1,r,a,i=e[t[0]],o,l=i.length;n<o;++n)for(a=i,i=e[t[n]],r=0;r<l;++r)i[r][1]+=i[r][0]=isNaN(a[r][1])?a[r][0]:a[r][1]}function jg(e){for(var t=e.length,n=new Array(t);--t>=0;)n[t]=t;return n}function A9(e,t){return e[t]}function E9(e){const t=[];return t.key=e,t}function _9(){var e=Ke([]),t=jg,n=zl,r=A9;function a(i){var o=Array.from(e.apply(this,arguments),E9),l,s=o.length,u=-1,d;for(const f of i)for(l=0,++u;l<s;++l)(o[l][u]=[0,+r(f,o[l].key,u,i)]).data=f;for(l=0,d=Ex(t(o));l<s;++l)o[d[l]].index=l;return n(o,d),o}return a.keys=function(i){return arguments.length?(e=typeof i=="function"?i:Ke(Array.from(i)),a):e},a.value=function(i){return arguments.length?(r=typeof i=="function"?i:Ke(+i),a):r},a.order=function(i){return arguments.length?(t=i==null?jg:typeof i=="function"?i:Ke(Array.from(i)),a):t},a.offset=function(i){return arguments.length?(n=i??zl,a):n},a}function T9(e,t){if((r=e.length)>0){for(var n,r,a=0,i=e[0].length,o;a<i;++a){for(o=n=0;n<r;++n)o+=e[n][a][1]||0;if(o)for(n=0;n<r;++n)e[n][a][1]/=o}zl(e,t)}}function N9(e,t){if((a=e.length)>0){for(var n=0,r=e[t[0]],a,i=r.length;n<i;++n){for(var o=0,l=0;o<a;++o)l+=e[o][n][1]||0;r[n][1]+=r[n][0]=-l/2}zl(e,t)}}function C9(e,t){if(!(!((o=e.length)>0)||!((i=(a=e[t[0]]).length)>0))){for(var n=0,r=1,a,i,o;r<i;++r){for(var l=0,s=0,u=0;l<o;++l){for(var d=e[t[l]],f=d[r][1]||0,h=d[r-1][1]||0,p=(f-h)/2,b=0;b<l;++b){var v=e[t[b]],x=v[r][1]||0,m=v[r-1][1]||0;p+=x-m}s+=f,u+=p*f}a[r-1][1]+=a[r-1][0]=n,s&&(n-=u/s)}a[r-1][1]+=a[r-1][0]=n,zl(e,t)}}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)}var M9=["type","size","sizeType"];function Og(){return Og=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},Og.apply(this,arguments)}function Xw(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function Qw(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Xw(Object(n),!0).forEach(function(r){R9(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Xw(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function R9(e,t,n){return t=P9(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function P9(e){var t=$9(e,"string");return Ku(t)=="symbol"?t:t+""}function $9(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)}function k9(e,t){if(e==null)return{};var n=D9(e,t),r,a;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(a=0;a<i.length;a++)r=i[a],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function D9(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 LC={symbolCircle:_x,symbolCross:r9,symbolDiamond:i9,symbolSquare:o9,symbolStar:c9,symbolTriangle:f9,symbolWye:h9},L9=Math.PI/180,z9=function(t){var n="symbol".concat(Lp(t));return LC[n]||_x},B9=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 a=18*L9;return 1.25*t*t*(Math.tan(a)-Math.tan(a*2)*Math.pow(Math.tan(a),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}},I9=function(t,n){LC["symbol".concat(Lp(t))]=n},Tx=function(t){var n=t.type,r=n===void 0?"circle":n,a=t.size,i=a===void 0?64:a,o=t.sizeType,l=o===void 0?"area":o,s=k9(t,M9),u=Qw(Qw({},s),{},{type:r,size:i,sizeType:l}),d=function(){var x=z9(r),m=p9().type(x).size(B9(i,l,r));return m()},f=u.className,h=u.cx,p=u.cy,b=oe(u,!0);return h===+h&&p===+p&&i===+i?$.createElement("path",Og({},b,{className:ve("recharts-symbols",f),transform:"translate(".concat(h,", ").concat(p,")"),d:d()})):null};Tx.registerSymbol=I9;function Bl(e){"@babel/helpers - typeof";return Bl=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},Bl(e)}function Ag(){return Ag=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},Ag.apply(this,arguments)}function Ww(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function U9(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Ww(Object(n),!0).forEach(function(r){Yu(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ww(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function q9(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function H9(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,BC(r.key),r)}}function F9(e,t,n){return t&&H9(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function G9(e,t,n){return t=th(t),K9(e,zC()?Reflect.construct(t,n||[],th(e).constructor):t.apply(e,n))}function K9(e,t){if(t&&(Bl(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Y9(e)}function Y9(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function zC(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(zC=function(){return!!e})()}function th(e){return th=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},th(e)}function V9(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&&Eg(e,t)}function Eg(e,t){return Eg=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,a){return r.__proto__=a,r},Eg(e,t)}function Yu(e,t,n){return t=BC(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function BC(e){var t=X9(e,"string");return Bl(t)=="symbol"?t:t+""}function X9(e,t){if(Bl(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Bl(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var zn=32,Nx=function(e){function t(){return q9(this,t),G9(this,t,arguments)}return V9(t,e),F9(t,[{key:"renderIcon",value:function(r){var a=this.props.inactiveColor,i=zn/2,o=zn/6,l=zn/3,s=r.inactive?a:r.color;if(r.type==="plainline")return $.createElement("line",{strokeWidth:4,fill:"none",stroke:s,strokeDasharray:r.payload.strokeDasharray,x1:0,y1:i,x2:zn,y2:i,className:"recharts-legend-icon"});if(r.type==="line")return $.createElement("path",{strokeWidth:4,fill:"none",stroke:s,d:"M0,".concat(i,"h").concat(l,`
            A`).concat(o,",").concat(o,",0,1,1,").concat(2*l,",").concat(i,`
            H`).concat(zn,"M").concat(2*l,",").concat(i,`
            A`).concat(o,",").concat(o,",0,1,1,").concat(l,",").concat(i),className:"recharts-legend-icon"});if(r.type==="rect")return $.createElement("path",{stroke:"none",fill:s,d:"M0,".concat(zn/8,"h").concat(zn,"v").concat(zn*3/4,"h").concat(-zn,"z"),className:"recharts-legend-icon"});if($.isValidElement(r.legendIcon)){var u=U9({},r);return delete u.legendIcon,$.cloneElement(r.legendIcon,u)}return $.createElement(Tx,{fill:s,cx:i,cy:i,size:zn,sizeType:"diameter",type:r.type})}},{key:"renderItems",value:function(){var r=this,a=this.props,i=a.payload,o=a.iconSize,l=a.layout,s=a.formatter,u=a.inactiveColor,d={x:0,y:0,width:zn,height:zn},f={display:l==="horizontal"?"inline-block":"block",marginRight:10},h={display:"inline-block",verticalAlign:"middle",marginRight:4};return i.map(function(p,b){var v=p.formatter||s,x=ve(Yu(Yu({"recharts-legend-item":!0},"legend-item-".concat(b),!0),"inactive",p.inactive));if(p.type==="none")return null;var m=se(p.value)?null:p.value;ra(!se(p.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 y=p.inactive?u:p.color;return $.createElement("li",Ag({className:x,style:f,key:"legend-item-".concat(b)},lo(r.props,p,b)),$.createElement(yg,{width:o,height:o,viewBox:d,style:h},r.renderIcon(p)),$.createElement("span",{className:"recharts-legend-item-text",style:{color:y}},v?v(m,p,b):m))})}},{key:"render",value:function(){var r=this.props,a=r.payload,i=r.layout,o=r.align;if(!a||!a.length)return null;var l={padding:0,margin:0,textAlign:i==="horizontal"?o:"left"};return $.createElement("ul",{className:"recharts-default-legend",style:l},this.renderItems())}}])}(O.PureComponent);Yu(Nx,"displayName","Legend");Yu(Nx,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"middle",inactiveColor:"#ccc"});var Q9=Op;function W9(){this.__data__=new Q9,this.size=0}var Z9=W9;function J9(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}var eq=J9;function tq(e){return this.__data__.get(e)}var nq=tq;function rq(e){return this.__data__.has(e)}var aq=rq,iq=Op,oq=yx,lq=vx,sq=200;function uq(e,t){var n=this.__data__;if(n instanceof iq){var r=n.__data__;if(!oq||r.length<sq-1)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new lq(r)}return n.set(e,t),this.size=n.size,this}var cq=uq,fq=Op,dq=Z9,hq=eq,pq=nq,mq=aq,yq=cq;function Ns(e){var t=this.__data__=new fq(e);this.size=t.size}Ns.prototype.clear=dq;Ns.prototype.delete=hq;Ns.prototype.get=pq;Ns.prototype.has=mq;Ns.prototype.set=yq;var IC=Ns,vq="__lodash_hash_undefined__";function gq(e){return this.__data__.set(e,vq),this}var bq=gq;function xq(e){return this.__data__.has(e)}var Sq=xq,wq=vx,jq=bq,Oq=Sq;function nh(e){var t=-1,n=e==null?0:e.length;for(this.__data__=new wq;++t<n;)this.add(e[t])}nh.prototype.add=nh.prototype.push=jq;nh.prototype.has=Oq;var UC=nh;function Aq(e,t){for(var n=-1,r=e==null?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}var qC=Aq;function Eq(e,t){return e.has(t)}var HC=Eq,_q=UC,Tq=qC,Nq=HC,Cq=1,Mq=2;function Rq(e,t,n,r,a,i){var o=n&Cq,l=e.length,s=t.length;if(l!=s&&!(o&&s>l))return!1;var u=i.get(e),d=i.get(t);if(u&&d)return u==t&&d==e;var f=-1,h=!0,p=n&Mq?new _q:void 0;for(i.set(e,t),i.set(t,e);++f<l;){var b=e[f],v=t[f];if(r)var x=o?r(v,b,f,t,e,i):r(b,v,f,e,t,i);if(x!==void 0){if(x)continue;h=!1;break}if(p){if(!Tq(t,function(m,y){if(!Nq(p,y)&&(b===m||a(b,m,n,r,i)))return p.push(y)})){h=!1;break}}else if(!(b===v||a(b,v,n,r,i))){h=!1;break}}return i.delete(e),i.delete(t),h}var FC=Rq,Pq=Mr,$q=Pq.Uint8Array,kq=$q;function Dq(e){var t=-1,n=Array(e.size);return e.forEach(function(r,a){n[++t]=[a,r]}),n}var Lq=Dq;function zq(e){var t=-1,n=Array(e.size);return e.forEach(function(r){n[++t]=r}),n}var Cx=zq,Zw=Jc,Jw=kq,Bq=mx,Iq=FC,Uq=Lq,qq=Cx,Hq=1,Fq=2,Gq="[object Boolean]",Kq="[object Date]",Yq="[object Error]",Vq="[object Map]",Xq="[object Number]",Qq="[object RegExp]",Wq="[object Set]",Zq="[object String]",Jq="[object Symbol]",eH="[object ArrayBuffer]",tH="[object DataView]",ej=Zw?Zw.prototype:void 0,yy=ej?ej.valueOf:void 0;function nH(e,t,n,r,a,i,o){switch(n){case tH:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case eH:return!(e.byteLength!=t.byteLength||!i(new Jw(e),new Jw(t)));case Gq:case Kq:case Xq:return Bq(+e,+t);case Yq:return e.name==t.name&&e.message==t.message;case Qq:case Zq:return e==t+"";case Vq:var l=Uq;case Wq:var s=r&Hq;if(l||(l=qq),e.size!=t.size&&!s)return!1;var u=o.get(e);if(u)return u==t;r|=Fq,o.set(e,t);var d=Iq(l(e),l(t),r,a,i,o);return o.delete(e),d;case Jq:if(yy)return yy.call(e)==yy.call(t)}return!1}var rH=nH;function aH(e,t){for(var n=-1,r=t.length,a=e.length;++n<r;)e[a+n]=t[n];return e}var GC=aH,iH=GC,oH=vn;function lH(e,t,n){var r=t(e);return oH(e)?r:iH(r,n(e))}var sH=lH;function uH(e,t){for(var n=-1,r=e==null?0:e.length,a=0,i=[];++n<r;){var o=e[n];t(o,n,e)&&(i[a++]=o)}return i}var cH=uH;function fH(){return[]}var dH=fH,hH=cH,pH=dH,mH=Object.prototype,yH=mH.propertyIsEnumerable,tj=Object.getOwnPropertySymbols,vH=tj?function(e){return e==null?[]:(e=Object(e),hH(tj(e),function(t){return yH.call(e,t)}))}:pH,gH=vH;function bH(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}var xH=bH,SH=va,wH=ga,jH="[object Arguments]";function OH(e){return wH(e)&&SH(e)==jH}var AH=OH,nj=AH,EH=ga,KC=Object.prototype,_H=KC.hasOwnProperty,TH=KC.propertyIsEnumerable,NH=nj(function(){return arguments}())?nj:function(e){return EH(e)&&_H.call(e,"callee")&&!TH.call(e,"callee")},Mx=NH,rh={exports:{}};function CH(){return!1}var MH=CH;rh.exports;(function(e,t){var n=Mr,r=MH,a=t&&!t.nodeType&&t,i=a&&!0&&e&&!e.nodeType&&e,o=i&&i.exports===a,l=o?n.Buffer:void 0,s=l?l.isBuffer:void 0,u=s||r;e.exports=u})(rh,rh.exports);var YC=rh.exports,RH=9007199254740991,PH=/^(?:0|[1-9]\d*)$/;function $H(e,t){var n=typeof e;return t=t??RH,!!t&&(n=="number"||n!="symbol"&&PH.test(e))&&e>-1&&e%1==0&&e<t}var Rx=$H,kH=9007199254740991;function DH(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=kH}var Px=DH,LH=va,zH=Px,BH=ga,IH="[object Arguments]",UH="[object Array]",qH="[object Boolean]",HH="[object Date]",FH="[object Error]",GH="[object Function]",KH="[object Map]",YH="[object Number]",VH="[object Object]",XH="[object RegExp]",QH="[object Set]",WH="[object String]",ZH="[object WeakMap]",JH="[object ArrayBuffer]",eF="[object DataView]",tF="[object Float32Array]",nF="[object Float64Array]",rF="[object Int8Array]",aF="[object Int16Array]",iF="[object Int32Array]",oF="[object Uint8Array]",lF="[object Uint8ClampedArray]",sF="[object Uint16Array]",uF="[object Uint32Array]",We={};We[tF]=We[nF]=We[rF]=We[aF]=We[iF]=We[oF]=We[lF]=We[sF]=We[uF]=!0;We[IH]=We[UH]=We[JH]=We[qH]=We[eF]=We[HH]=We[FH]=We[GH]=We[KH]=We[YH]=We[VH]=We[XH]=We[QH]=We[WH]=We[ZH]=!1;function cF(e){return BH(e)&&zH(e.length)&&!!We[LH(e)]}var fF=cF;function dF(e){return function(t){return e(t)}}var VC=dF,ah={exports:{}};ah.exports;(function(e,t){var n=nC,r=t&&!t.nodeType&&t,a=r&&!0&&e&&!e.nodeType&&e,i=a&&a.exports===r,o=i&&n.process,l=function(){try{var s=a&&a.require&&a.require("util").types;return s||o&&o.binding&&o.binding("util")}catch{}}();e.exports=l})(ah,ah.exports);var hF=ah.exports,pF=fF,mF=VC,rj=hF,aj=rj&&rj.isTypedArray,yF=aj?mF(aj):pF,XC=yF,vF=xH,gF=Mx,bF=vn,xF=YC,SF=Rx,wF=XC,jF=Object.prototype,OF=jF.hasOwnProperty;function AF(e,t){var n=bF(e),r=!n&&gF(e),a=!n&&!r&&xF(e),i=!n&&!r&&!a&&wF(e),o=n||r||a||i,l=o?vF(e.length,String):[],s=l.length;for(var u in e)(t||OF.call(e,u))&&!(o&&(u=="length"||a&&(u=="offset"||u=="parent")||i&&(u=="buffer"||u=="byteLength"||u=="byteOffset")||SF(u,s)))&&l.push(u);return l}var EF=AF,_F=Object.prototype;function TF(e){var t=e&&e.constructor,n=typeof t=="function"&&t.prototype||_F;return e===n}var NF=TF;function CF(e,t){return function(n){return e(t(n))}}var QC=CF,MF=QC,RF=MF(Object.keys,Object),PF=RF,$F=NF,kF=PF,DF=Object.prototype,LF=DF.hasOwnProperty;function zF(e){if(!$F(e))return kF(e);var t=[];for(var n in Object(e))LF.call(e,n)&&n!="constructor"&&t.push(n);return t}var BF=zF,IF=px,UF=Px;function qF(e){return e!=null&&UF(e.length)&&!IF(e)}var Up=qF,HF=EF,FF=BF,GF=Up;function KF(e){return GF(e)?HF(e):FF(e)}var $x=KF,YF=sH,VF=gH,XF=$x;function QF(e){return YF(e,XF,VF)}var WF=QF,ij=WF,ZF=1,JF=Object.prototype,eG=JF.hasOwnProperty;function tG(e,t,n,r,a,i){var o=n&ZF,l=ij(e),s=l.length,u=ij(t),d=u.length;if(s!=d&&!o)return!1;for(var f=s;f--;){var h=l[f];if(!(o?h in t:eG.call(t,h)))return!1}var p=i.get(e),b=i.get(t);if(p&&b)return p==t&&b==e;var v=!0;i.set(e,t),i.set(t,e);for(var x=o;++f<s;){h=l[f];var m=e[h],y=t[h];if(r)var g=o?r(y,m,h,t,e,i):r(m,y,h,e,t,i);if(!(g===void 0?m===y||a(m,y,n,r,i):g)){v=!1;break}x||(x=h=="constructor")}if(v&&!x){var S=e.constructor,w=t.constructor;S!=w&&"constructor"in e&&"constructor"in t&&!(typeof S=="function"&&S instanceof S&&typeof w=="function"&&w instanceof w)&&(v=!1)}return i.delete(e),i.delete(t),v}var nG=tG,rG=go,aG=Mr,iG=rG(aG,"DataView"),oG=iG,lG=go,sG=Mr,uG=lG(sG,"Promise"),cG=uG,fG=go,dG=Mr,hG=fG(dG,"Set"),WC=hG,pG=go,mG=Mr,yG=pG(mG,"WeakMap"),vG=yG,_g=oG,Tg=yx,Ng=cG,Cg=WC,Mg=vG,ZC=va,Cs=aC,oj="[object Map]",gG="[object Object]",lj="[object Promise]",sj="[object Set]",uj="[object WeakMap]",cj="[object DataView]",bG=Cs(_g),xG=Cs(Tg),SG=Cs(Ng),wG=Cs(Cg),jG=Cs(Mg),Ei=ZC;(_g&&Ei(new _g(new ArrayBuffer(1)))!=cj||Tg&&Ei(new Tg)!=oj||Ng&&Ei(Ng.resolve())!=lj||Cg&&Ei(new Cg)!=sj||Mg&&Ei(new Mg)!=uj)&&(Ei=function(e){var t=ZC(e),n=t==gG?e.constructor:void 0,r=n?Cs(n):"";if(r)switch(r){case bG:return cj;case xG:return oj;case SG:return lj;case wG:return sj;case jG:return uj}return t});var OG=Ei,vy=IC,AG=FC,EG=rH,_G=nG,fj=OG,dj=vn,hj=YC,TG=XC,NG=1,pj="[object Arguments]",mj="[object Array]",Cf="[object Object]",CG=Object.prototype,yj=CG.hasOwnProperty;function MG(e,t,n,r,a,i){var o=dj(e),l=dj(t),s=o?mj:fj(e),u=l?mj:fj(t);s=s==pj?Cf:s,u=u==pj?Cf:u;var d=s==Cf,f=u==Cf,h=s==u;if(h&&hj(e)){if(!hj(t))return!1;o=!0,d=!1}if(h&&!d)return i||(i=new vy),o||TG(e)?AG(e,t,n,r,a,i):EG(e,t,s,n,r,a,i);if(!(n&NG)){var p=d&&yj.call(e,"__wrapped__"),b=f&&yj.call(t,"__wrapped__");if(p||b){var v=p?e.value():e,x=b?t.value():t;return i||(i=new vy),a(v,x,n,r,i)}}return h?(i||(i=new vy),_G(e,t,n,r,a,i)):!1}var RG=MG,PG=RG,vj=ga;function JC(e,t,n,r,a){return e===t?!0:e==null||t==null||!vj(e)&&!vj(t)?e!==e&&t!==t:PG(e,t,n,r,JC,a)}var kx=JC,$G=IC,kG=kx,DG=1,LG=2;function zG(e,t,n,r){var a=n.length,i=a,o=!r;if(e==null)return!i;for(e=Object(e);a--;){var l=n[a];if(o&&l[2]?l[1]!==e[l[0]]:!(l[0]in e))return!1}for(;++a<i;){l=n[a];var s=l[0],u=e[s],d=l[1];if(o&&l[2]){if(u===void 0&&!(s in e))return!1}else{var f=new $G;if(r)var h=r(u,d,s,e,t,f);if(!(h===void 0?kG(d,u,DG|LG,r,f):h))return!1}}return!0}var BG=zG,IG=ci;function UG(e){return e===e&&!IG(e)}var eM=UG,qG=eM,HG=$x;function FG(e){for(var t=HG(e),n=t.length;n--;){var r=t[n],a=e[r];t[n]=[r,a,qG(a)]}return t}var GG=FG;function KG(e,t){return function(n){return n==null?!1:n[e]===t&&(t!==void 0||e in Object(n))}}var tM=KG,YG=BG,VG=GG,XG=tM;function QG(e){var t=VG(e);return t.length==1&&t[0][2]?XG(t[0][0],t[0][1]):function(n){return n===e||YG(n,e,t)}}var WG=QG;function ZG(e,t){return e!=null&&t in Object(e)}var JG=ZG,eK=uC,tK=Mx,nK=vn,rK=Rx,aK=Px,iK=Ep;function oK(e,t,n){t=eK(t,e);for(var r=-1,a=t.length,i=!1;++r<a;){var o=iK(t[r]);if(!(i=e!=null&&n(e,o)))break;e=e[o]}return i||++r!=a?i:(a=e==null?0:e.length,!!a&&aK(a)&&rK(o,a)&&(nK(e)||tK(e)))}var lK=oK,sK=JG,uK=lK;function cK(e,t){return e!=null&&uK(e,t,sK)}var fK=cK,dK=kx,hK=cC,pK=fK,mK=hx,yK=eM,vK=tM,gK=Ep,bK=1,xK=2;function SK(e,t){return mK(e)&&yK(t)?vK(gK(e),t):function(n){var r=hK(n,e);return r===void 0&&r===t?pK(n,e):dK(t,r,bK|xK)}}var wK=SK;function jK(e){return e}var Ms=jK;function OK(e){return function(t){return t==null?void 0:t[e]}}var AK=OK,EK=xx;function _K(e){return function(t){return EK(t,e)}}var TK=_K,NK=AK,CK=TK,MK=hx,RK=Ep;function PK(e){return MK(e)?NK(RK(e)):CK(e)}var $K=PK,kK=WG,DK=wK,LK=Ms,zK=vn,BK=$K;function IK(e){return typeof e=="function"?e:e==null?LK:typeof e=="object"?zK(e)?DK(e[0],e[1]):kK(e):BK(e)}var fi=IK;function UK(e,t,n,r){for(var a=e.length,i=n+(r?1:-1);r?i--:++i<a;)if(t(e[i],i,e))return i;return-1}var qK=UK;function HK(e){return e!==e}var FK=HK;function GK(e,t,n){for(var r=n-1,a=e.length;++r<a;)if(e[r]===t)return r;return-1}var KK=GK,YK=qK,VK=FK,XK=KK;function QK(e,t,n){return t===t?XK(e,t,n):YK(e,VK,n)}var WK=QK,ZK=WK;function JK(e,t){var n=e==null?0:e.length;return!!n&&ZK(e,t,0)>-1}var eY=JK;function tY(e,t,n){for(var r=-1,a=e==null?0:e.length;++r<a;)if(n(t,e[r]))return!0;return!1}var nY=tY;function rY(){}var aY=rY,gy=WC,iY=aY,oY=Cx,lY=1/0,sY=gy&&1/oY(new gy([,-0]))[1]==lY?function(e){return new gy(e)}:iY,uY=sY,cY=UC,fY=eY,dY=nY,hY=HC,pY=uY,mY=Cx,yY=200;function vY(e,t,n){var r=-1,a=fY,i=e.length,o=!0,l=[],s=l;if(n)o=!1,a=dY;else if(i>=yY){var u=t?null:pY(e);if(u)return mY(u);o=!1,a=hY,s=new cY}else s=t?[]:l;e:for(;++r<i;){var d=e[r],f=t?t(d):d;if(d=n||d!==0?d:0,o&&f===f){for(var h=s.length;h--;)if(s[h]===f)continue e;t&&s.push(f),l.push(d)}else a(s,f,n)||(s!==l&&s.push(f),l.push(d))}return l}var gY=vY,bY=fi,xY=gY;function SY(e,t){return e&&e.length?xY(e,bY(t)):[]}var wY=SY;const gj=qe(wY);function nM(e,t,n){return t===!0?gj(e,n):se(t)?gj(e,t):e}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)}var jY=["ref"];function bj(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function zr(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?bj(Object(n),!0).forEach(function(r){qp(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bj(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function OY(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function xj(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,aM(r.key),r)}}function AY(e,t,n){return t&&xj(e.prototype,t),n&&xj(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function EY(e,t,n){return t=ih(t),_Y(e,rM()?Reflect.construct(t,n||[],ih(e).constructor):t.apply(e,n))}function _Y(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 TY(e)}function TY(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function rM(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(rM=function(){return!!e})()}function ih(e){return ih=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},ih(e)}function NY(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&&Rg(e,t)}function Rg(e,t){return Rg=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,a){return r.__proto__=a,r},Rg(e,t)}function qp(e,t,n){return t=aM(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function aM(e){var t=CY(e,"string");return Il(t)=="symbol"?t:t+""}function CY(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)}function MY(e,t){if(e==null)return{};var n=RY(e,t),r,a;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(a=0;a<i.length;a++)r=i[a],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function RY(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 PY(e){return e.value}function $Y(e,t){if($.isValidElement(e))return $.cloneElement(e,t);if(typeof e=="function")return $.createElement(e,t);t.ref;var n=MY(t,jY);return $.createElement(Nx,n)}var Sj=1,ll=function(e){function t(){var n;OY(this,t);for(var r=arguments.length,a=new Array(r),i=0;i<r;i++)a[i]=arguments[i];return n=EY(this,t,[].concat(a)),qp(n,"lastBoundingBox",{width:-1,height:-1}),n}return NY(t,e),AY(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,a=this.getBBox();a?(Math.abs(a.width-this.lastBoundingBox.width)>Sj||Math.abs(a.height-this.lastBoundingBox.height)>Sj)&&(this.lastBoundingBox.width=a.width,this.lastBoundingBox.height=a.height,r&&r(a)):(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?zr({},this.lastBoundingBox):{width:0,height:0}}},{key:"getDefaultPosition",value:function(r){var a=this.props,i=a.layout,o=a.align,l=a.verticalAlign,s=a.margin,u=a.chartWidth,d=a.chartHeight,f,h;if(!r||(r.left===void 0||r.left===null)&&(r.right===void 0||r.right===null))if(o==="center"&&i==="vertical"){var p=this.getBBoxSnapshot();f={left:((u||0)-p.width)/2}}else f=o==="right"?{right:s&&s.right||0}:{left:s&&s.left||0};if(!r||(r.top===void 0||r.top===null)&&(r.bottom===void 0||r.bottom===null))if(l==="middle"){var b=this.getBBoxSnapshot();h={top:((d||0)-b.height)/2}}else h=l==="bottom"?{bottom:s&&s.bottom||0}:{top:s&&s.top||0};return zr(zr({},f),h)}},{key:"render",value:function(){var r=this,a=this.props,i=a.content,o=a.width,l=a.height,s=a.wrapperStyle,u=a.payloadUniqBy,d=a.payload,f=zr(zr({position:"absolute",width:o||"auto",height:l||"auto"},this.getDefaultPosition(s)),s);return $.createElement("div",{className:"recharts-legend-wrapper",style:f,ref:function(p){r.wrapperNode=p}},$Y(i,zr(zr({},this.props),{},{payload:nM(d,u,PY)})))}}],[{key:"getWithHeight",value:function(r,a){var i=zr(zr({},this.defaultProps),r.props),o=i.layout;return o==="vertical"&&V(r.props.height)?{height:r.props.height}:o==="horizontal"?{width:r.props.width||a}:null}}])}(O.PureComponent);qp(ll,"displayName","Legend");qp(ll,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"bottom"});var wj=Jc,kY=Mx,DY=vn,jj=wj?wj.isConcatSpreadable:void 0;function LY(e){return DY(e)||kY(e)||!!(jj&&e&&e[jj])}var zY=LY,BY=GC,IY=zY;function iM(e,t,n,r,a){var i=-1,o=e.length;for(n||(n=IY),a||(a=[]);++i<o;){var l=e[i];t>0&&n(l)?t>1?iM(l,t-1,n,r,a):BY(a,l):r||(a[a.length]=l)}return a}var oM=iM;function UY(e){return function(t,n,r){for(var a=-1,i=Object(t),o=r(t),l=o.length;l--;){var s=o[e?l:++a];if(n(i[s],s,i)===!1)break}return t}}var qY=UY,HY=qY,FY=HY(),GY=FY,KY=GY,YY=$x;function VY(e,t){return e&&KY(e,t,YY)}var lM=VY,XY=Up;function QY(e,t){return function(n,r){if(n==null)return n;if(!XY(n))return e(n,r);for(var a=n.length,i=t?a:-1,o=Object(n);(t?i--:++i<a)&&r(o[i],i,o)!==!1;);return n}}var WY=QY,ZY=lM,JY=WY,eV=JY(ZY),Dx=eV,tV=Dx,nV=Up;function rV(e,t){var n=-1,r=nV(e)?Array(e.length):[];return tV(e,function(a,i,o){r[++n]=t(a,i,o)}),r}var sM=rV;function aV(e,t){var n=e.length;for(e.sort(t);n--;)e[n]=e[n].value;return e}var iV=aV,Oj=Os;function oV(e,t){if(e!==t){var n=e!==void 0,r=e===null,a=e===e,i=Oj(e),o=t!==void 0,l=t===null,s=t===t,u=Oj(t);if(!l&&!u&&!i&&e>t||i&&o&&s&&!l&&!u||r&&o&&s||!n&&s||!a)return 1;if(!r&&!i&&!u&&e<t||u&&n&&a&&!r&&!i||l&&n&&a||!o&&a||!s)return-1}return 0}var lV=oV,sV=lV;function uV(e,t,n){for(var r=-1,a=e.criteria,i=t.criteria,o=a.length,l=n.length;++r<o;){var s=sV(a[r],i[r]);if(s){if(r>=l)return s;var u=n[r];return s*(u=="desc"?-1:1)}}return e.index-t.index}var cV=uV,by=bx,fV=xx,dV=fi,hV=sM,pV=iV,mV=VC,yV=cV,vV=Ms,gV=vn;function bV(e,t,n){t.length?t=by(t,function(i){return gV(i)?function(o){return fV(o,i.length===1?i[0]:i)}:i}):t=[vV];var r=-1;t=by(t,mV(dV));var a=hV(e,function(i,o,l){var s=by(t,function(u){return u(i)});return{criteria:s,index:++r,value:i}});return pV(a,function(i,o){return yV(i,o,n)})}var xV=bV;function SV(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}var wV=SV,jV=wV,Aj=Math.max;function OV(e,t,n){return t=Aj(t===void 0?e.length-1:t,0),function(){for(var r=arguments,a=-1,i=Aj(r.length-t,0),o=Array(i);++a<i;)o[a]=r[t+a];a=-1;for(var l=Array(t+1);++a<t;)l[a]=r[a];return l[t]=n(o),jV(e,this,l)}}var AV=OV;function EV(e){return function(){return e}}var _V=EV,TV=go,NV=function(){try{var e=TV(Object,"defineProperty");return e({},"",{}),e}catch{}}(),uM=NV,CV=_V,Ej=uM,MV=Ms,RV=Ej?function(e,t){return Ej(e,"toString",{configurable:!0,enumerable:!1,value:CV(t),writable:!0})}:MV,PV=RV,$V=800,kV=16,DV=Date.now;function LV(e){var t=0,n=0;return function(){var r=DV(),a=kV-(r-n);if(n=r,a>0){if(++t>=$V)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}var zV=LV,BV=PV,IV=zV,UV=IV(BV),qV=UV,HV=Ms,FV=AV,GV=qV;function KV(e,t){return GV(FV(e,t,HV),e+"")}var YV=KV,VV=mx,XV=Up,QV=Rx,WV=ci;function ZV(e,t,n){if(!WV(n))return!1;var r=typeof t;return(r=="number"?XV(n)&&QV(t,n.length):r=="string"&&t in n)?VV(n[t],e):!1}var Hp=ZV,JV=oM,eX=xV,tX=YV,_j=Hp,nX=tX(function(e,t){if(e==null)return[];var n=t.length;return n>1&&_j(e,t[0],t[1])?t=[]:n>2&&_j(t[0],t[1],t[2])&&(t=[t[0]]),eX(e,JV(t,1),[])}),rX=nX;const Lx=qe(rX);function Vu(e){"@babel/helpers - typeof";return Vu=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},Vu(e)}function Pg(){return Pg=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},Pg.apply(this,arguments)}function aX(e,t){return sX(e)||lX(e,t)||oX(e,t)||iX()}function iX(){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 oX(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 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 lX(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,a,i,o,l=[],s=!0,u=!1;try{if(i=(n=n.call(e)).next,t!==0)for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(d){u=!0,a=d}finally{try{if(!s&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(u)throw a}}return l}}function sX(e){if(Array.isArray(e))return e}function Nj(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function xy(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Nj(Object(n),!0).forEach(function(r){uX(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Nj(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function uX(e,t,n){return t=cX(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function cX(e){var t=fX(e,"string");return Vu(t)=="symbol"?t:t+""}function fX(e,t){if(Vu(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Vu(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function dX(e){return Array.isArray(e)&&Ot(e[0])&&Ot(e[1])?e.join(" ~ "):e}var hX=function(t){var n=t.separator,r=n===void 0?" : ":n,a=t.contentStyle,i=a===void 0?{}:a,o=t.itemStyle,l=o===void 0?{}:o,s=t.labelStyle,u=s===void 0?{}:s,d=t.payload,f=t.formatter,h=t.itemSorter,p=t.wrapperClassName,b=t.labelClassName,v=t.label,x=t.labelFormatter,m=t.accessibilityLayer,y=m===void 0?!1:m,g=function(){if(d&&d.length){var R={padding:0,margin:0},B=(h?Lx(d,h):d).map(function(k,C){if(k.type==="none")return null;var M=xy({display:"block",paddingTop:4,paddingBottom:4,color:k.color||"#000"},l),L=k.formatter||f||dX,z=k.value,F=k.name,K=z,G=F;if(L&&K!=null&&G!=null){var Y=L(z,F,k,C,d);if(Array.isArray(Y)){var J=aX(Y,2);K=J[0],G=J[1]}else K=Y}return $.createElement("li",{className:"recharts-tooltip-item",key:"tooltip-item-".concat(C),style:M},Ot(G)?$.createElement("span",{className:"recharts-tooltip-item-name"},G):null,Ot(G)?$.createElement("span",{className:"recharts-tooltip-item-separator"},r):null,$.createElement("span",{className:"recharts-tooltip-item-value"},K),$.createElement("span",{className:"recharts-tooltip-item-unit"},k.unit||""))});return $.createElement("ul",{className:"recharts-tooltip-item-list",style:R},B)}return null},S=xy({margin:0,padding:10,backgroundColor:"#fff",border:"1px solid #ccc",whiteSpace:"nowrap"},i),w=xy({margin:0},u),j=!ge(v),A=j?v:"",E=ve("recharts-default-tooltip",p),_=ve("recharts-tooltip-label",b);j&&x&&d!==void 0&&d!==null&&(A=x(v,d));var N=y?{role:"status","aria-live":"assertive"}:{};return $.createElement("div",Pg({className:E,style:S},N),$.createElement("p",{className:_,style:w},$.isValidElement(A)?A:"".concat(A)),g())};function Xu(e){"@babel/helpers - typeof";return Xu=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},Xu(e)}function Mf(e,t,n){return t=pX(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function pX(e){var t=mX(e,"string");return Xu(t)=="symbol"?t:t+""}function mX(e,t){if(Xu(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Xu(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Ks="recharts-tooltip-wrapper",yX={visibility:"hidden"};function vX(e){var t=e.coordinate,n=e.translateX,r=e.translateY;return ve(Ks,Mf(Mf(Mf(Mf({},"".concat(Ks,"-right"),V(n)&&t&&V(t.x)&&n>=t.x),"".concat(Ks,"-left"),V(n)&&t&&V(t.x)&&n<t.x),"".concat(Ks,"-bottom"),V(r)&&t&&V(t.y)&&r>=t.y),"".concat(Ks,"-top"),V(r)&&t&&V(t.y)&&r<t.y))}function Cj(e){var t=e.allowEscapeViewBox,n=e.coordinate,r=e.key,a=e.offsetTopLeft,i=e.position,o=e.reverseDirection,l=e.tooltipDimension,s=e.viewBox,u=e.viewBoxDimension;if(i&&V(i[r]))return i[r];var d=n[r]-l-a,f=n[r]+a;if(t[r])return o[r]?d:f;if(o[r]){var h=d,p=s[r];return h<p?Math.max(f,s[r]):Math.max(d,s[r])}var b=f+l,v=s[r]+u;return b>v?Math.max(d,s[r]):Math.max(f,s[r])}function gX(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 bX(e){var t=e.allowEscapeViewBox,n=e.coordinate,r=e.offsetTopLeft,a=e.position,i=e.reverseDirection,o=e.tooltipBox,l=e.useTranslate3d,s=e.viewBox,u,d,f;return o.height>0&&o.width>0&&n?(d=Cj({allowEscapeViewBox:t,coordinate:n,key:"x",offsetTopLeft:r,position:a,reverseDirection:i,tooltipDimension:o.width,viewBox:s,viewBoxDimension:s.width}),f=Cj({allowEscapeViewBox:t,coordinate:n,key:"y",offsetTopLeft:r,position:a,reverseDirection:i,tooltipDimension:o.height,viewBox:s,viewBoxDimension:s.height}),u=gX({translateX:d,translateY:f,useTranslate3d:l})):u=yX,{cssProperties:u,cssClasses:vX({translateX:d,translateY:f,coordinate:n})}}function Ul(e){"@babel/helpers - typeof";return Ul=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},Ul(e)}function Mj(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function Rj(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Mj(Object(n),!0).forEach(function(r){kg(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Mj(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function xX(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function SX(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,fM(r.key),r)}}function wX(e,t,n){return t&&SX(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function jX(e,t,n){return t=oh(t),OX(e,cM()?Reflect.construct(t,n||[],oh(e).constructor):t.apply(e,n))}function OX(e,t){if(t&&(Ul(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return AX(e)}function AX(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function cM(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(cM=function(){return!!e})()}function oh(e){return oh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},oh(e)}function EX(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&&$g(e,t)}function $g(e,t){return $g=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,a){return r.__proto__=a,r},$g(e,t)}function kg(e,t,n){return t=fM(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function fM(e){var t=_X(e,"string");return Ul(t)=="symbol"?t:t+""}function _X(e,t){if(Ul(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Ul(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Pj=1,TX=function(e){function t(){var n;xX(this,t);for(var r=arguments.length,a=new Array(r),i=0;i<r;i++)a[i]=arguments[i];return n=jX(this,t,[].concat(a)),kg(n,"state",{dismissed:!1,dismissedAtCoordinate:{x:0,y:0},lastBoundingBox:{width:-1,height:-1}}),kg(n,"handleKeyDown",function(o){if(o.key==="Escape"){var l,s,u,d;n.setState({dismissed:!0,dismissedAtCoordinate:{x:(l=(s=n.props.coordinate)===null||s===void 0?void 0:s.x)!==null&&l!==void 0?l:0,y:(u=(d=n.props.coordinate)===null||d===void 0?void 0:d.y)!==null&&u!==void 0?u:0}})}}),n}return EX(t,e),wX(t,[{key:"updateBBox",value:function(){if(this.wrapperNode&&this.wrapperNode.getBoundingClientRect){var r=this.wrapperNode.getBoundingClientRect();(Math.abs(r.width-this.state.lastBoundingBox.width)>Pj||Math.abs(r.height-this.state.lastBoundingBox.height)>Pj)&&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,a;this.props.active&&this.updateBBox(),this.state.dismissed&&(((r=this.props.coordinate)===null||r===void 0?void 0:r.x)!==this.state.dismissedAtCoordinate.x||((a=this.props.coordinate)===null||a===void 0?void 0:a.y)!==this.state.dismissedAtCoordinate.y)&&(this.state.dismissed=!1)}},{key:"render",value:function(){var r=this,a=this.props,i=a.active,o=a.allowEscapeViewBox,l=a.animationDuration,s=a.animationEasing,u=a.children,d=a.coordinate,f=a.hasPayload,h=a.isAnimationActive,p=a.offset,b=a.position,v=a.reverseDirection,x=a.useTranslate3d,m=a.viewBox,y=a.wrapperStyle,g=bX({allowEscapeViewBox:o,coordinate:d,offsetTopLeft:p,position:b,reverseDirection:v,tooltipBox:this.state.lastBoundingBox,useTranslate3d:x,viewBox:m}),S=g.cssClasses,w=g.cssProperties,j=Rj(Rj({transition:h&&i?"transform ".concat(l,"ms ").concat(s):void 0},w),{},{pointerEvents:"none",visibility:!this.state.dismissed&&i&&f?"visible":"hidden",position:"absolute",top:0,left:0},y);return $.createElement("div",{tabIndex:-1,className:S,style:j,ref:function(E){r.wrapperNode=E}},u)}}])}(O.PureComponent),NX=function(){return!(typeof window<"u"&&window.document&&window.document.createElement&&window.setTimeout)},Rs={isSsr:NX()};function ql(e){"@babel/helpers - typeof";return ql=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},ql(e)}function $j(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function kj(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?$j(Object(n),!0).forEach(function(r){zx(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):$j(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function CX(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function MX(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,hM(r.key),r)}}function RX(e,t,n){return t&&MX(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function PX(e,t,n){return t=lh(t),$X(e,dM()?Reflect.construct(t,n||[],lh(e).constructor):t.apply(e,n))}function $X(e,t){if(t&&(ql(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return kX(e)}function kX(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function dM(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(dM=function(){return!!e})()}function lh(e){return lh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},lh(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&&Dg(e,t)}function Dg(e,t){return Dg=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,a){return r.__proto__=a,r},Dg(e,t)}function zx(e,t,n){return t=hM(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function hM(e){var t=LX(e,"string");return ql(t)=="symbol"?t:t+""}function LX(e,t){if(ql(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(ql(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function zX(e){return e.dataKey}function BX(e,t){return $.isValidElement(e)?$.cloneElement(e,t):typeof e=="function"?$.createElement(e,t):$.createElement(hX,t)}var sr=function(e){function t(){return CX(this,t),PX(this,t,arguments)}return DX(t,e),RX(t,[{key:"render",value:function(){var r=this,a=this.props,i=a.active,o=a.allowEscapeViewBox,l=a.animationDuration,s=a.animationEasing,u=a.content,d=a.coordinate,f=a.filterNull,h=a.isAnimationActive,p=a.offset,b=a.payload,v=a.payloadUniqBy,x=a.position,m=a.reverseDirection,y=a.useTranslate3d,g=a.viewBox,S=a.wrapperStyle,w=b??[];f&&w.length&&(w=nM(b.filter(function(A){return A.value!=null&&(A.hide!==!0||r.props.includeHidden)}),v,zX));var j=w.length>0;return $.createElement(TX,{allowEscapeViewBox:o,animationDuration:l,animationEasing:s,isAnimationActive:h,active:i,coordinate:d,hasPayload:j,offset:p,position:x,reverseDirection:m,useTranslate3d:y,viewBox:g,wrapperStyle:S},BX(u,kj(kj({},this.props),{},{payload:w})))}}])}(O.PureComponent);zx(sr,"displayName","Tooltip");zx(sr,"defaultProps",{accessibilityLayer:!1,allowEscapeViewBox:{x:!1,y:!1},animationDuration:400,animationEasing:"ease",contentStyle:{},coordinate:{x:0,y:0},cursor:!0,cursorStyle:{},filterNull:!0,isAnimationActive:!Rs.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 IX=Mr,UX=function(){return IX.Date.now()},qX=UX,HX=/\s/;function FX(e){for(var t=e.length;t--&&HX.test(e.charAt(t)););return t}var GX=FX,KX=GX,YX=/^\s+/;function VX(e){return e&&e.slice(0,KX(e)+1).replace(YX,"")}var XX=VX,QX=XX,Dj=ci,WX=Os,Lj=NaN,ZX=/^[-+]0x[0-9a-f]+$/i,JX=/^0b[01]+$/i,eQ=/^0o[0-7]+$/i,tQ=parseInt;function nQ(e){if(typeof e=="number")return e;if(WX(e))return Lj;if(Dj(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=Dj(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=QX(e);var n=JX.test(e);return n||eQ.test(e)?tQ(e.slice(2),n?2:8):ZX.test(e)?Lj:+e}var pM=nQ,rQ=ci,Sy=qX,zj=pM,aQ="Expected a function",iQ=Math.max,oQ=Math.min;function lQ(e,t,n){var r,a,i,o,l,s,u=0,d=!1,f=!1,h=!0;if(typeof e!="function")throw new TypeError(aQ);t=zj(t)||0,rQ(n)&&(d=!!n.leading,f="maxWait"in n,i=f?iQ(zj(n.maxWait)||0,t):i,h="trailing"in n?!!n.trailing:h);function p(j){var A=r,E=a;return r=a=void 0,u=j,o=e.apply(E,A),o}function b(j){return u=j,l=setTimeout(m,t),d?p(j):o}function v(j){var A=j-s,E=j-u,_=t-A;return f?oQ(_,i-E):_}function x(j){var A=j-s,E=j-u;return s===void 0||A>=t||A<0||f&&E>=i}function m(){var j=Sy();if(x(j))return y(j);l=setTimeout(m,v(j))}function y(j){return l=void 0,h&&r?p(j):(r=a=void 0,o)}function g(){l!==void 0&&clearTimeout(l),u=0,r=s=a=l=void 0}function S(){return l===void 0?o:y(Sy())}function w(){var j=Sy(),A=x(j);if(r=arguments,a=this,s=j,A){if(l===void 0)return b(s);if(f)return clearTimeout(l),l=setTimeout(m,t),p(s)}return l===void 0&&(l=setTimeout(m,t)),o}return w.cancel=g,w.flush=S,w}var sQ=lQ,uQ=sQ,cQ=ci,fQ="Expected a function";function dQ(e,t,n){var r=!0,a=!0;if(typeof e!="function")throw new TypeError(fQ);return cQ(n)&&(r="leading"in n?!!n.leading:r,a="trailing"in n?!!n.trailing:a),uQ(e,t,{leading:r,maxWait:t,trailing:a})}var hQ=dQ;const mM=qe(hQ);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 Bj(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function Rf(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Bj(Object(n),!0).forEach(function(r){pQ(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Bj(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function pQ(e,t,n){return t=mQ(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function mQ(e){var t=yQ(e,"string");return Qu(t)=="symbol"?t:t+""}function yQ(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 vQ(e,t){return SQ(e)||xQ(e,t)||bQ(e,t)||gQ()}function gQ(){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 bQ(e,t){if(e){if(typeof e=="string")return Ij(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 Ij(e,t)}}function Ij(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 xQ(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,a,i,o,l=[],s=!0,u=!1;try{if(i=(n=n.call(e)).next,t!==0)for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(d){u=!0,a=d}finally{try{if(!s&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(u)throw a}}return l}}function SQ(e){if(Array.isArray(e))return e}var Uj=O.forwardRef(function(e,t){var n=e.aspect,r=e.initialDimension,a=r===void 0?{width:-1,height:-1}:r,i=e.width,o=i===void 0?"100%":i,l=e.height,s=l===void 0?"100%":l,u=e.minWidth,d=u===void 0?0:u,f=e.minHeight,h=e.maxHeight,p=e.children,b=e.debounce,v=b===void 0?0:b,x=e.id,m=e.className,y=e.onResize,g=e.style,S=g===void 0?{}:g,w=O.useRef(null),j=O.useRef();j.current=y,O.useImperativeHandle(t,function(){return Object.defineProperty(w.current,"current",{get:function(){return console.warn("The usage of ref.current.current is deprecated and will no longer be supported."),w.current},configurable:!0})});var A=O.useState({containerWidth:a.width,containerHeight:a.height}),E=vQ(A,2),_=E[0],N=E[1],D=O.useCallback(function(B,k){N(function(C){var M=Math.round(B),L=Math.round(k);return C.containerWidth===M&&C.containerHeight===L?C:{containerWidth:M,containerHeight:L}})},[]);O.useEffect(function(){var B=function(F){var K,G=F[0].contentRect,Y=G.width,J=G.height;D(Y,J),(K=j.current)===null||K===void 0||K.call(j,Y,J)};v>0&&(B=mM(B,v,{trailing:!0,leading:!1}));var k=new ResizeObserver(B),C=w.current.getBoundingClientRect(),M=C.width,L=C.height;return D(M,L),k.observe(w.current),function(){k.disconnect()}},[D,v]);var R=O.useMemo(function(){var B=_.containerWidth,k=_.containerHeight;if(B<0||k<0)return null;ra(Mi(o)||Mi(s),`The width(%s) and height(%s) are both fixed numbers,
       maybe you don't need to use a ResponsiveContainer.`,o,s),ra(!n||n>0,"The aspect(%s) must be greater than zero.",n);var C=Mi(o)?B:o,M=Mi(s)?k:s;n&&n>0&&(C?M=C/n:M&&(C=M*n),h&&M>h&&(M=h)),ra(C>0||M>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.`,C,M,o,s,d,f,n);var L=!Array.isArray(p)&&na(p.type).endsWith("Chart");return $.Children.map(p,function(z){return $.isValidElement(z)?O.cloneElement(z,Rf({width:C,height:M},L?{style:Rf({height:"100%",width:"100%",maxHeight:M,maxWidth:C},z.props.style)}:{})):z})},[n,p,s,h,f,d,_,o]);return $.createElement("div",{id:x?"".concat(x):void 0,className:ve("recharts-responsive-container",m),style:Rf(Rf({},S),{},{width:o,height:s,minWidth:d,minHeight:f,maxHeight:h}),ref:w},R)}),Fp=function(t){return null};Fp.displayName="Cell";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 qj(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function Lg(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?qj(Object(n),!0).forEach(function(r){wQ(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):qj(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function wQ(e,t,n){return t=jQ(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function jQ(e){var t=OQ(e,"string");return Wu(t)=="symbol"?t:t+""}function OQ(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 To={widthCache:{},cacheCount:0},AQ=2e3,EQ={position:"absolute",top:"-20000px",left:0,padding:0,margin:0,border:"none",whiteSpace:"pre"},Hj="recharts_measurement_span";function _Q(e){var t=Lg({},e);return Object.keys(t).forEach(function(n){t[n]||delete t[n]}),t}var wu=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(t==null||Rs.isSsr)return{width:0,height:0};var r=_Q(n),a=JSON.stringify({text:t,copyStyle:r});if(To.widthCache[a])return To.widthCache[a];try{var i=document.getElementById(Hj);i||(i=document.createElement("span"),i.setAttribute("id",Hj),i.setAttribute("aria-hidden","true"),document.body.appendChild(i));var o=Lg(Lg({},EQ),r);Object.assign(i.style,o),i.textContent="".concat(t);var l=i.getBoundingClientRect(),s={width:l.width,height:l.height};return To.widthCache[a]=s,++To.cacheCount>AQ&&(To.cacheCount=0,To.widthCache={}),s}catch{return{width:0,height:0}}},TQ=function(t){return{top:t.top+window.scrollY-document.documentElement.clientTop,left:t.left+window.scrollX-document.documentElement.clientLeft}};function Zu(e){"@babel/helpers - typeof";return Zu=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},Zu(e)}function sh(e,t){return RQ(e)||MQ(e,t)||CQ(e,t)||NQ()}function NQ(){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 CQ(e,t){if(e){if(typeof e=="string")return Fj(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 Fj(e,t)}}function Fj(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 MQ(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,a,i,o,l=[],s=!0,u=!1;try{if(i=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(d){u=!0,a=d}finally{try{if(!s&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(u)throw a}}return l}}function RQ(e){if(Array.isArray(e))return e}function PQ(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Gj(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,kQ(r.key),r)}}function $Q(e,t,n){return t&&Gj(e.prototype,t),n&&Gj(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function kQ(e){var t=DQ(e,"string");return Zu(t)=="symbol"?t:t+""}function DQ(e,t){if(Zu(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Zu(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Kj=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([*/])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,Yj=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([+-])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,LQ=/^px|cm|vh|vw|em|rem|%|mm|in|pt|pc|ex|ch|vmin|vmax|Q$/,zQ=/(-?\d+(?:\.\d+)?)([a-zA-Z%]+)?/,yM={cm:96/2.54,mm:96/25.4,pt:96/72,pc:96/6,in:96,Q:96/(2.54*40),px:1},BQ=Object.keys(yM),Yo="NaN";function IQ(e,t){return e*yM[t]}var Pf=function(){function e(t,n){PQ(this,e),this.num=t,this.unit=n,this.num=t,this.unit=n,Number.isNaN(t)&&(this.unit=""),n!==""&&!LQ.test(n)&&(this.num=NaN,this.unit=""),BQ.includes(n)&&(this.num=IQ(t,n),this.unit="px")}return $Q(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,a=(r=zQ.exec(n))!==null&&r!==void 0?r:[],i=sh(a,3),o=i[1],l=i[2];return new e(parseFloat(o),l??"")}}])}();function vM(e){if(e.includes(Yo))return Yo;for(var t=e;t.includes("*")||t.includes("/");){var n,r=(n=Kj.exec(t))!==null&&n!==void 0?n:[],a=sh(r,4),i=a[1],o=a[2],l=a[3],s=Pf.parse(i??""),u=Pf.parse(l??""),d=o==="*"?s.multiply(u):s.divide(u);if(d.isNaN())return Yo;t=t.replace(Kj,d.toString())}for(;t.includes("+")||/.-\d+(?:\.\d+)?/.test(t);){var f,h=(f=Yj.exec(t))!==null&&f!==void 0?f:[],p=sh(h,4),b=p[1],v=p[2],x=p[3],m=Pf.parse(b??""),y=Pf.parse(x??""),g=v==="+"?m.add(y):m.subtract(y);if(g.isNaN())return Yo;t=t.replace(Yj,g.toString())}return t}var Vj=/\(([^()]*)\)/;function UQ(e){for(var t=e;t.includes("(");){var n=Vj.exec(t),r=sh(n,2),a=r[1];t=t.replace(Vj,vM(a))}return t}function qQ(e){var t=e.replace(/\s+/g,"");return t=UQ(t),t=vM(t),t}function HQ(e){try{return qQ(e)}catch{return Yo}}function wy(e){var t=HQ(e.slice(5,-1));return t===Yo?"":t}var FQ=["x","y","lineHeight","capHeight","scaleToFit","textAnchor","verticalAnchor","fill"],GQ=["dx","dy","angle","className","breakAll"];function zg(){return zg=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},zg.apply(this,arguments)}function Xj(e,t){if(e==null)return{};var n=KQ(e,t),r,a;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(a=0;a<i.length;a++)r=i[a],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function KQ(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 Qj(e,t){return QQ(e)||XQ(e,t)||VQ(e,t)||YQ()}function YQ(){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 VQ(e,t){if(e){if(typeof e=="string")return Wj(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 Wj(e,t)}}function Wj(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 XQ(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,a,i,o,l=[],s=!0,u=!1;try{if(i=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(d){u=!0,a=d}finally{try{if(!s&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(u)throw a}}return l}}function QQ(e){if(Array.isArray(e))return e}var gM=/[ \f\n\r\t\v\u2028\u2029]+/,bM=function(t){var n=t.children,r=t.breakAll,a=t.style;try{var i=[];ge(n)||(r?i=n.toString().split(""):i=n.toString().split(gM));var o=i.map(function(s){return{word:s,width:wu(s,a).width}}),l=r?0:wu(" ",a).width;return{wordsWithComputedWidth:o,spaceWidth:l}}catch{return null}},WQ=function(t,n,r,a,i){var o=t.maxLines,l=t.children,s=t.style,u=t.breakAll,d=V(o),f=l,h=function(){var C=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];return C.reduce(function(M,L){var z=L.word,F=L.width,K=M[M.length-1];if(K&&(a==null||i||K.width+F+r<Number(a)))K.words.push(z),K.width+=F+r;else{var G={words:[z],width:F};M.push(G)}return M},[])},p=h(n),b=function(C){return C.reduce(function(M,L){return M.width>L.width?M:L})};if(!d)return p;for(var v="…",x=function(C){var M=f.slice(0,C),L=bM({breakAll:u,style:s,children:M+v}).wordsWithComputedWidth,z=h(L),F=z.length>o||b(z).width>Number(a);return[F,z]},m=0,y=f.length-1,g=0,S;m<=y&&g<=f.length-1;){var w=Math.floor((m+y)/2),j=w-1,A=x(j),E=Qj(A,2),_=E[0],N=E[1],D=x(w),R=Qj(D,1),B=R[0];if(!_&&!B&&(m=w+1),_&&B&&(y=w-1),!_&&B){S=N;break}g++}return S||p},Zj=function(t){var n=ge(t)?[]:t.toString().split(gM);return[{words:n}]},ZQ=function(t){var n=t.width,r=t.scaleToFit,a=t.children,i=t.style,o=t.breakAll,l=t.maxLines;if((n||r)&&!Rs.isSsr){var s,u,d=bM({breakAll:o,children:a,style:i});if(d){var f=d.wordsWithComputedWidth,h=d.spaceWidth;s=f,u=h}else return Zj(a);return WQ({breakAll:o,children:a,maxLines:l,style:i},s,u,n,r)}return Zj(a)},Jj="#808080",so=function(t){var n=t.x,r=n===void 0?0:n,a=t.y,i=a===void 0?0:a,o=t.lineHeight,l=o===void 0?"1em":o,s=t.capHeight,u=s===void 0?"0.71em":s,d=t.scaleToFit,f=d===void 0?!1:d,h=t.textAnchor,p=h===void 0?"start":h,b=t.verticalAnchor,v=b===void 0?"end":b,x=t.fill,m=x===void 0?Jj:x,y=Xj(t,FQ),g=O.useMemo(function(){return ZQ({breakAll:y.breakAll,children:y.children,maxLines:y.maxLines,scaleToFit:f,style:y.style,width:y.width})},[y.breakAll,y.children,y.maxLines,f,y.style,y.width]),S=y.dx,w=y.dy,j=y.angle,A=y.className,E=y.breakAll,_=Xj(y,GQ);if(!Ot(r)||!Ot(i))return null;var N=r+(V(S)?S:0),D=i+(V(w)?w:0),R;switch(v){case"start":R=wy("calc(".concat(u,")"));break;case"middle":R=wy("calc(".concat((g.length-1)/2," * -").concat(l," + (").concat(u," / 2))"));break;default:R=wy("calc(".concat(g.length-1," * -").concat(l,")"));break}var B=[];if(f){var k=g[0].width,C=y.width;B.push("scale(".concat((V(C)?C/k:1)/k,")"))}return j&&B.push("rotate(".concat(j,", ").concat(N,", ").concat(D,")")),B.length&&(_.transform=B.join(" ")),$.createElement("text",zg({},oe(_,!0),{x:N,y:D,className:ve("recharts-text",A),textAnchor:p,fill:m.includes("url")?Jj:m}),g.map(function(M,L){var z=M.words.join(E?"":" ");return $.createElement("tspan",{x:N,dy:L===0?R:l,key:"".concat(z,"-").concat(L)},z)}))};function ni(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function JQ(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function Bx(e){let t,n,r;e.length!==2?(t=ni,n=(l,s)=>ni(e(l),s),r=(l,s)=>e(l)-s):(t=e===ni||e===JQ?e:eW,n=e,r=e);function a(l,s,u=0,d=l.length){if(u<d){if(t(s,s)!==0)return d;do{const f=u+d>>>1;n(l[f],s)<0?u=f+1:d=f}while(u<d)}return u}function i(l,s,u=0,d=l.length){if(u<d){if(t(s,s)!==0)return d;do{const f=u+d>>>1;n(l[f],s)<=0?u=f+1:d=f}while(u<d)}return u}function o(l,s,u=0,d=l.length){const f=a(l,s,u,d-1);return f>u&&r(l[f-1],s)>-r(l[f],s)?f-1:f}return{left:a,center:o,right:i}}function eW(){return 0}function xM(e){return e===null?NaN:+e}function*tW(e,t){for(let n of e)n!=null&&(n=+n)>=n&&(yield n)}const nW=Bx(ni),nf=nW.right;Bx(xM).center;class e2 extends Map{constructor(t,n=iW){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:n}}),t!=null)for(const[r,a]of t)this.set(r,a)}get(t){return super.get(t2(this,t))}has(t){return super.has(t2(this,t))}set(t,n){return super.set(rW(this,t),n)}delete(t){return super.delete(aW(this,t))}}function t2({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):n}function rW({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):(e.set(r,n),n)}function aW({_intern:e,_key:t},n){const r=t(n);return e.has(r)&&(n=e.get(r),e.delete(r)),n}function iW(e){return e!==null&&typeof e=="object"?e.valueOf():e}function oW(e=ni){if(e===ni)return SM;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 SM(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(e<t?-1:e>t?1:0)}const lW=Math.sqrt(50),sW=Math.sqrt(10),uW=Math.sqrt(2);function uh(e,t,n){const r=(t-e)/Math.max(0,n),a=Math.floor(Math.log10(r)),i=r/Math.pow(10,a),o=i>=lW?10:i>=sW?5:i>=uW?2:1;let l,s,u;return a<0?(u=Math.pow(10,-a)/o,l=Math.round(e*u),s=Math.round(t*u),l/u<e&&++l,s/u>t&&--s,u=-u):(u=Math.pow(10,a)*o,l=Math.round(e/u),s=Math.round(t/u),l*u<e&&++l,s*u>t&&--s),s<l&&.5<=n&&n<2?uh(e,t,n*2):[l,s,u]}function Bg(e,t,n){if(t=+t,e=+e,n=+n,!(n>0))return[];if(e===t)return[e];const r=t<e,[a,i,o]=r?uh(t,e,n):uh(e,t,n);if(!(i>=a))return[];const l=i-a+1,s=new Array(l);if(r)if(o<0)for(let u=0;u<l;++u)s[u]=(i-u)/-o;else for(let u=0;u<l;++u)s[u]=(i-u)*o;else if(o<0)for(let u=0;u<l;++u)s[u]=(a+u)/-o;else for(let u=0;u<l;++u)s[u]=(a+u)*o;return s}function Ig(e,t,n){return t=+t,e=+e,n=+n,uh(e,t,n)[2]}function Ug(e,t,n){t=+t,e=+e,n=+n;const r=t<e,a=r?Ig(t,e,n):Ig(e,t,n);return(r?-1:1)*(a<0?1/-a:a)}function n2(e,t){let n;for(const r of e)r!=null&&(n<r||n===void 0&&r>=r)&&(n=r);return n}function r2(e,t){let n;for(const r of e)r!=null&&(n>r||n===void 0&&r>=r)&&(n=r);return n}function wM(e,t,n=0,r=1/0,a){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(a=a===void 0?SM:oW(a);r>n;){if(r-n>600){const s=r-n+1,u=t-n+1,d=Math.log(s),f=.5*Math.exp(2*d/3),h=.5*Math.sqrt(d*f*(s-f)/s)*(u-s/2<0?-1:1),p=Math.max(n,Math.floor(t-u*f/s+h)),b=Math.min(r,Math.floor(t+(s-u)*f/s+h));wM(e,t,p,b,a)}const i=e[t];let o=n,l=r;for(Ys(e,n,t),a(e[r],i)>0&&Ys(e,n,r);o<l;){for(Ys(e,o,l),++o,--l;a(e[o],i)<0;)++o;for(;a(e[l],i)>0;)--l}a(e[n],i)===0?Ys(e,n,l):(++l,Ys(e,l,r)),l<=t&&(n=l+1),t<=l&&(r=l-1)}return e}function Ys(e,t,n){const r=e[t];e[t]=e[n],e[n]=r}function cW(e,t,n){if(e=Float64Array.from(tW(e)),!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return r2(e);if(t>=1)return n2(e);var r,a=(r-1)*t,i=Math.floor(a),o=n2(wM(e,i).subarray(0,i+1)),l=r2(e.subarray(i+1));return o+(l-o)*(a-i)}}function fW(e,t,n=xM){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,a=(r-1)*t,i=Math.floor(a),o=+n(e[i],i,e),l=+n(e[i+1],i+1,e);return o+(l-o)*(a-i)}}function dW(e,t,n){e=+e,t=+t,n=(a=arguments.length)<2?(t=e,e=0,1):a<3?1:+n;for(var r=-1,a=Math.max(0,Math.ceil((t-e)/n))|0,i=new Array(a);++r<a;)i[r]=e+r*n;return i}function nr(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}function ba(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 qg=Symbol("implicit");function Ix(){var e=new e2,t=[],n=[],r=qg;function a(i){let o=e.get(i);if(o===void 0){if(r!==qg)return r;e.set(i,o=t.push(i)-1)}return n[o%n.length]}return a.domain=function(i){if(!arguments.length)return t.slice();t=[],e=new e2;for(const o of i)e.has(o)||e.set(o,t.push(o)-1);return a},a.range=function(i){return arguments.length?(n=Array.from(i),a):n.slice()},a.unknown=function(i){return arguments.length?(r=i,a):r},a.copy=function(){return Ix(t,n).unknown(r)},nr.apply(a,arguments),a}function Ju(){var e=Ix().unknown(void 0),t=e.domain,n=e.range,r=0,a=1,i,o,l=!1,s=0,u=0,d=.5;delete e.unknown;function f(){var h=t().length,p=a<r,b=p?a:r,v=p?r:a;i=(v-b)/Math.max(1,h-s+u*2),l&&(i=Math.floor(i)),b+=(v-b-i*(h-s))*d,o=i*(1-s),l&&(b=Math.round(b),o=Math.round(o));var x=dW(h).map(function(m){return b+i*m});return n(p?x.reverse():x)}return e.domain=function(h){return arguments.length?(t(h),f()):t()},e.range=function(h){return arguments.length?([r,a]=h,r=+r,a=+a,f()):[r,a]},e.rangeRound=function(h){return[r,a]=h,r=+r,a=+a,l=!0,f()},e.bandwidth=function(){return o},e.step=function(){return i},e.round=function(h){return arguments.length?(l=!!h,f()):l},e.padding=function(h){return arguments.length?(s=Math.min(1,u=+h),f()):s},e.paddingInner=function(h){return arguments.length?(s=Math.min(1,h),f()):s},e.paddingOuter=function(h){return arguments.length?(u=+h,f()):u},e.align=function(h){return arguments.length?(d=Math.max(0,Math.min(1,h)),f()):d},e.copy=function(){return Ju(t(),[r,a]).round(l).paddingInner(s).paddingOuter(u).align(d)},nr.apply(f(),arguments)}function jM(e){var t=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,delete e.paddingOuter,e.copy=function(){return jM(t())},e}function ju(){return jM(Ju.apply(null,arguments).paddingInner(1))}function Ux(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function OM(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function rf(){}var ec=.7,ch=1/ec,sl="\\s*([+-]?\\d+)\\s*",tc="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Ar="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",hW=/^#([0-9a-f]{3,8})$/,pW=new RegExp(`^rgb\\(${sl},${sl},${sl}\\)$`),mW=new RegExp(`^rgb\\(${Ar},${Ar},${Ar}\\)$`),yW=new RegExp(`^rgba\\(${sl},${sl},${sl},${tc}\\)$`),vW=new RegExp(`^rgba\\(${Ar},${Ar},${Ar},${tc}\\)$`),gW=new RegExp(`^hsl\\(${tc},${Ar},${Ar}\\)$`),bW=new RegExp(`^hsla\\(${tc},${Ar},${Ar},${tc}\\)$`),a2={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};Ux(rf,nc,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:i2,formatHex:i2,formatHex8:xW,formatHsl:SW,formatRgb:o2,toString:o2});function i2(){return this.rgb().formatHex()}function xW(){return this.rgb().formatHex8()}function SW(){return AM(this).formatHsl()}function o2(){return this.rgb().formatRgb()}function nc(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=hW.exec(e))?(n=t[1].length,t=parseInt(t[1],16),n===6?l2(t):n===3?new dn(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?$f(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?$f(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=pW.exec(e))?new dn(t[1],t[2],t[3],1):(t=mW.exec(e))?new dn(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=yW.exec(e))?$f(t[1],t[2],t[3],t[4]):(t=vW.exec(e))?$f(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=gW.exec(e))?c2(t[1],t[2]/100,t[3]/100,1):(t=bW.exec(e))?c2(t[1],t[2]/100,t[3]/100,t[4]):a2.hasOwnProperty(e)?l2(a2[e]):e==="transparent"?new dn(NaN,NaN,NaN,0):null}function l2(e){return new dn(e>>16&255,e>>8&255,e&255,1)}function $f(e,t,n,r){return r<=0&&(e=t=n=NaN),new dn(e,t,n,r)}function wW(e){return e instanceof rf||(e=nc(e)),e?(e=e.rgb(),new dn(e.r,e.g,e.b,e.opacity)):new dn}function Hg(e,t,n,r){return arguments.length===1?wW(e):new dn(e,t,n,r??1)}function dn(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}Ux(dn,Hg,OM(rf,{brighter(e){return e=e==null?ch:Math.pow(ch,e),new dn(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?ec:Math.pow(ec,e),new dn(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new dn(Qi(this.r),Qi(this.g),Qi(this.b),fh(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:s2,formatHex:s2,formatHex8:jW,formatRgb:u2,toString:u2}));function s2(){return`#${Ri(this.r)}${Ri(this.g)}${Ri(this.b)}`}function jW(){return`#${Ri(this.r)}${Ri(this.g)}${Ri(this.b)}${Ri((isNaN(this.opacity)?1:this.opacity)*255)}`}function u2(){const e=fh(this.opacity);return`${e===1?"rgb(":"rgba("}${Qi(this.r)}, ${Qi(this.g)}, ${Qi(this.b)}${e===1?")":`, ${e})`}`}function fh(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Qi(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Ri(e){return e=Qi(e),(e<16?"0":"")+e.toString(16)}function c2(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new cr(e,t,n,r)}function AM(e){if(e instanceof cr)return new cr(e.h,e.s,e.l,e.opacity);if(e instanceof rf||(e=nc(e)),!e)return new cr;if(e instanceof cr)return e;e=e.rgb();var t=e.r/255,n=e.g/255,r=e.b/255,a=Math.min(t,n,r),i=Math.max(t,n,r),o=NaN,l=i-a,s=(i+a)/2;return l?(t===i?o=(n-r)/l+(n<r)*6:n===i?o=(r-t)/l+2:o=(t-n)/l+4,l/=s<.5?i+a:2-i-a,o*=60):l=s>0&&s<1?0:o,new cr(o,l,s,e.opacity)}function OW(e,t,n,r){return arguments.length===1?AM(e):new cr(e,t,n,r??1)}function cr(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}Ux(cr,OW,OM(rf,{brighter(e){return e=e==null?ch:Math.pow(ch,e),new cr(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?ec:Math.pow(ec,e),new cr(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,a=2*n-r;return new dn(jy(e>=240?e-240:e+120,a,r),jy(e,a,r),jy(e<120?e+240:e-120,a,r),this.opacity)},clamp(){return new cr(f2(this.h),kf(this.s),kf(this.l),fh(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=fh(this.opacity);return`${e===1?"hsl(":"hsla("}${f2(this.h)}, ${kf(this.s)*100}%, ${kf(this.l)*100}%${e===1?")":`, ${e})`}`}}));function f2(e){return e=(e||0)%360,e<0?e+360:e}function kf(e){return Math.max(0,Math.min(1,e||0))}function jy(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 qx=e=>()=>e;function AW(e,t){return function(n){return e+n*t}}function EW(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 _W(e){return(e=+e)==1?EM:function(t,n){return n-t?EW(t,n,e):qx(isNaN(t)?n:t)}}function EM(e,t){var n=t-e;return n?AW(e,n):qx(isNaN(e)?t:e)}const d2=function e(t){var n=_W(t);function r(a,i){var o=n((a=Hg(a)).r,(i=Hg(i)).r),l=n(a.g,i.g),s=n(a.b,i.b),u=EM(a.opacity,i.opacity);return function(d){return a.r=o(d),a.g=l(d),a.b=s(d),a.opacity=u(d),a+""}}return r.gamma=e,r}(1);function TW(e,t){t||(t=[]);var n=e?Math.min(t.length,e.length):0,r=t.slice(),a;return function(i){for(a=0;a<n;++a)r[a]=e[a]*(1-i)+t[a]*i;return r}}function NW(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function CW(e,t){var n=t?t.length:0,r=e?Math.min(n,e.length):0,a=new Array(r),i=new Array(n),o;for(o=0;o<r;++o)a[o]=Ps(e[o],t[o]);for(;o<n;++o)i[o]=t[o];return function(l){for(o=0;o<r;++o)i[o]=a[o](l);return i}}function MW(e,t){var n=new Date;return e=+e,t=+t,function(r){return n.setTime(e*(1-r)+t*r),n}}function dh(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}function RW(e,t){var n={},r={},a;(e===null||typeof e!="object")&&(e={}),(t===null||typeof t!="object")&&(t={});for(a in t)a in e?n[a]=Ps(e[a],t[a]):r[a]=t[a];return function(i){for(a in n)r[a]=n[a](i);return r}}var Fg=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Oy=new RegExp(Fg.source,"g");function PW(e){return function(){return e}}function $W(e){return function(t){return e(t)+""}}function kW(e,t){var n=Fg.lastIndex=Oy.lastIndex=0,r,a,i,o=-1,l=[],s=[];for(e=e+"",t=t+"";(r=Fg.exec(e))&&(a=Oy.exec(t));)(i=a.index)>n&&(i=t.slice(n,i),l[o]?l[o]+=i:l[++o]=i),(r=r[0])===(a=a[0])?l[o]?l[o]+=a:l[++o]=a:(l[++o]=null,s.push({i:o,x:dh(r,a)})),n=Oy.lastIndex;return n<t.length&&(i=t.slice(n),l[o]?l[o]+=i:l[++o]=i),l.length<2?s[0]?$W(s[0].x):PW(t):(t=s.length,function(u){for(var d=0,f;d<t;++d)l[(f=s[d]).i]=f.x(u);return l.join("")})}function Ps(e,t){var n=typeof t,r;return t==null||n==="boolean"?qx(t):(n==="number"?dh:n==="string"?(r=nc(t))?(t=r,d2):kW:t instanceof nc?d2:t instanceof Date?MW:NW(t)?TW:Array.isArray(t)?CW:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?RW:dh)(e,t)}function Hx(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}function DW(e,t){t===void 0&&(t=e,e=Ps);for(var n=0,r=t.length-1,a=t[0],i=new Array(r<0?0:r);n<r;)i[n]=e(a,a=t[++n]);return function(o){var l=Math.max(0,Math.min(r-1,Math.floor(o*=r)));return i[l](o-l)}}function LW(e){return function(){return e}}function hh(e){return+e}var h2=[0,1];function tn(e){return e}function Gg(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:LW(isNaN(t)?NaN:.5)}function zW(e,t){var n;return e>t&&(n=e,e=t,t=n),function(r){return Math.max(e,Math.min(t,r))}}function BW(e,t,n){var r=e[0],a=e[1],i=t[0],o=t[1];return a<r?(r=Gg(a,r),i=n(o,i)):(r=Gg(r,a),i=n(i,o)),function(l){return i(r(l))}}function IW(e,t,n){var r=Math.min(e.length,t.length)-1,a=new Array(r),i=new Array(r),o=-1;for(e[r]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++o<r;)a[o]=Gg(e[o],e[o+1]),i[o]=n(t[o],t[o+1]);return function(l){var s=nf(e,l,1,r)-1;return i[s](a[s](l))}}function af(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function Gp(){var e=h2,t=h2,n=Ps,r,a,i,o=tn,l,s,u;function d(){var h=Math.min(e.length,t.length);return o!==tn&&(o=zW(e[0],e[h-1])),l=h>2?IW:BW,s=u=null,f}function f(h){return h==null||isNaN(h=+h)?i:(s||(s=l(e.map(r),t,n)))(r(o(h)))}return f.invert=function(h){return o(a((u||(u=l(t,e.map(r),dh)))(h)))},f.domain=function(h){return arguments.length?(e=Array.from(h,hh),d()):e.slice()},f.range=function(h){return arguments.length?(t=Array.from(h),d()):t.slice()},f.rangeRound=function(h){return t=Array.from(h),n=Hx,d()},f.clamp=function(h){return arguments.length?(o=h?!0:tn,d()):o!==tn},f.interpolate=function(h){return arguments.length?(n=h,d()):n},f.unknown=function(h){return arguments.length?(i=h,f):i},function(h,p){return r=h,a=p,d()}}function Fx(){return Gp()(tn,tn)}function UW(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function ph(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 Hl(e){return e=ph(Math.abs(e)),e?e[1]:NaN}function qW(e,t){return function(n,r){for(var a=n.length,i=[],o=0,l=e[0],s=0;a>0&&l>0&&(s+l+1>r&&(l=Math.max(1,r-s)),i.push(n.substring(a-=l,a+l)),!((s+=l+1)>r));)l=e[o=(o+1)%e.length];return i.reverse().join(t)}}function HW(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var FW=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function rc(e){if(!(t=FW.exec(e)))throw new Error("invalid format: "+e);var t;return new Gx({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]})}rc.prototype=Gx.prototype;function Gx(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+""}Gx.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 GW(e){e:for(var t=e.length,n=1,r=-1,a;n<t;++n)switch(e[n]){case".":r=a=n;break;case"0":r===0&&(r=n),a=n;break;default:if(!+e[n])break e;r>0&&(r=0);break}return r>0?e.slice(0,r)+e.slice(a+1):e}var mh;function KW(e,t){var n=ph(e,t);if(!n)return mh=void 0,e.toPrecision(t);var r=n[0],a=n[1],i=a-(mh=Math.max(-8,Math.min(8,Math.floor(a/3)))*3)+1,o=r.length;return i===o?r:i>o?r+new Array(i-o+1).join("0"):i>0?r.slice(0,i)+"."+r.slice(i):"0."+new Array(1-i).join("0")+ph(e,Math.max(0,t+i-1))[0]}function p2(e,t){var n=ph(e,t);if(!n)return e+"";var r=n[0],a=n[1];return a<0?"0."+new Array(-a).join("0")+r:r.length>a+1?r.slice(0,a+1)+"."+r.slice(a+1):r+new Array(a-r.length+2).join("0")}const m2={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:UW,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)=>p2(e*100,t),r:p2,s:KW,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function y2(e){return e}var v2=Array.prototype.map,g2=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function YW(e){var t=e.grouping===void 0||e.thousands===void 0?y2:qW(v2.call(e.grouping,Number),e.thousands+""),n=e.currency===void 0?"":e.currency[0]+"",r=e.currency===void 0?"":e.currency[1]+"",a=e.decimal===void 0?".":e.decimal+"",i=e.numerals===void 0?y2:HW(v2.call(e.numerals,String)),o=e.percent===void 0?"%":e.percent+"",l=e.minus===void 0?"−":e.minus+"",s=e.nan===void 0?"NaN":e.nan+"";function u(f,h){f=rc(f);var p=f.fill,b=f.align,v=f.sign,x=f.symbol,m=f.zero,y=f.width,g=f.comma,S=f.precision,w=f.trim,j=f.type;j==="n"?(g=!0,j="g"):m2[j]||(S===void 0&&(S=12),w=!0,j="g"),(m||p==="0"&&b==="=")&&(m=!0,p="0",b="=");var A=(h&&h.prefix!==void 0?h.prefix:"")+(x==="$"?n:x==="#"&&/[boxX]/.test(j)?"0"+j.toLowerCase():""),E=(x==="$"?r:/[%p]/.test(j)?o:"")+(h&&h.suffix!==void 0?h.suffix:""),_=m2[j],N=/[defgprs%]/.test(j);S=S===void 0?6:/[gprs]/.test(j)?Math.max(1,Math.min(21,S)):Math.max(0,Math.min(20,S));function D(R){var B=A,k=E,C,M,L;if(j==="c")k=_(R)+k,R="";else{R=+R;var z=R<0||1/R<0;if(R=isNaN(R)?s:_(Math.abs(R),S),w&&(R=GW(R)),z&&+R==0&&v!=="+"&&(z=!1),B=(z?v==="("?v:l:v==="-"||v==="("?"":v)+B,k=(j==="s"&&!isNaN(R)&&mh!==void 0?g2[8+mh/3]:"")+k+(z&&v==="("?")":""),N){for(C=-1,M=R.length;++C<M;)if(L=R.charCodeAt(C),48>L||L>57){k=(L===46?a+R.slice(C+1):R.slice(C))+k,R=R.slice(0,C);break}}}g&&!m&&(R=t(R,1/0));var F=B.length+R.length+k.length,K=F<y?new Array(y-F+1).join(p):"";switch(g&&m&&(R=t(K+R,K.length?y-k.length:1/0),K=""),b){case"<":R=B+R+k+K;break;case"=":R=B+K+R+k;break;case"^":R=K.slice(0,F=K.length>>1)+B+R+k+K.slice(F);break;default:R=K+B+R+k;break}return i(R)}return D.toString=function(){return f+""},D}function d(f,h){var p=Math.max(-8,Math.min(8,Math.floor(Hl(h)/3)))*3,b=Math.pow(10,-p),v=u((f=rc(f),f.type="f",f),{suffix:g2[8+p/3]});return function(x){return v(b*x)}}return{format:u,formatPrefix:d}}var Df,Kx,_M;VW({thousands:",",grouping:[3],currency:["$",""]});function VW(e){return Df=YW(e),Kx=Df.format,_M=Df.formatPrefix,Df}function XW(e){return Math.max(0,-Hl(Math.abs(e)))}function QW(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(Hl(t)/3)))*3-Hl(Math.abs(e)))}function WW(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,Hl(t)-Hl(e))+1}function TM(e,t,n,r){var a=Ug(e,t,n),i;switch(r=rc(r??",f"),r.type){case"s":{var o=Math.max(Math.abs(e),Math.abs(t));return r.precision==null&&!isNaN(i=QW(a,o))&&(r.precision=i),_M(r,o)}case"":case"e":case"g":case"p":case"r":{r.precision==null&&!isNaN(i=WW(a,Math.max(Math.abs(e),Math.abs(t))))&&(r.precision=i-(r.type==="e"));break}case"f":case"%":{r.precision==null&&!isNaN(i=XW(a))&&(r.precision=i-(r.type==="%")*2);break}}return Kx(r)}function di(e){var t=e.domain;return e.ticks=function(n){var r=t();return Bg(r[0],r[r.length-1],n??10)},e.tickFormat=function(n,r){var a=t();return TM(a[0],a[a.length-1],n??10,r)},e.nice=function(n){n==null&&(n=10);var r=t(),a=0,i=r.length-1,o=r[a],l=r[i],s,u,d=10;for(l<o&&(u=o,o=l,l=u,u=a,a=i,i=u);d-- >0;){if(u=Ig(o,l,n),u===s)return r[a]=o,r[i]=l,t(r);if(u>0)o=Math.floor(o/u)*u,l=Math.ceil(l/u)*u;else if(u<0)o=Math.ceil(o*u)/u,l=Math.floor(l*u)/u;else break;s=u}return e},e}function yh(){var e=Fx();return e.copy=function(){return af(e,yh())},nr.apply(e,arguments),di(e)}function NM(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,hh),n):e.slice()},n.unknown=function(r){return arguments.length?(t=r,n):t},n.copy=function(){return NM(e).unknown(t)},e=arguments.length?Array.from(e,hh):[0,1],di(n)}function CM(e,t){e=e.slice();var n=0,r=e.length-1,a=e[n],i=e[r],o;return i<a&&(o=n,n=r,r=o,o=a,a=i,i=o),e[n]=t.floor(a),e[r]=t.ceil(i),e}function b2(e){return Math.log(e)}function x2(e){return Math.exp(e)}function ZW(e){return-Math.log(-e)}function JW(e){return-Math.exp(-e)}function eZ(e){return isFinite(e)?+("1e"+e):e<0?0:e}function tZ(e){return e===10?eZ:e===Math.E?Math.exp:t=>Math.pow(e,t)}function nZ(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 S2(e){return(t,n)=>-e(-t,n)}function Yx(e){const t=e(b2,x2),n=t.domain;let r=10,a,i;function o(){return a=nZ(r),i=tZ(r),n()[0]<0?(a=S2(a),i=S2(i),e(ZW,JW)):e(b2,x2),t}return t.base=function(l){return arguments.length?(r=+l,o()):r},t.domain=function(l){return arguments.length?(n(l),o()):n()},t.ticks=l=>{const s=n();let u=s[0],d=s[s.length-1];const f=d<u;f&&([u,d]=[d,u]);let h=a(u),p=a(d),b,v;const x=l==null?10:+l;let m=[];if(!(r%1)&&p-h<x){if(h=Math.floor(h),p=Math.ceil(p),u>0){for(;h<=p;++h)for(b=1;b<r;++b)if(v=h<0?b/i(-h):b*i(h),!(v<u)){if(v>d)break;m.push(v)}}else for(;h<=p;++h)for(b=r-1;b>=1;--b)if(v=h>0?b/i(-h):b*i(h),!(v<u)){if(v>d)break;m.push(v)}m.length*2<x&&(m=Bg(u,d,x))}else m=Bg(h,p,Math.min(p-h,x)).map(i);return f?m.reverse():m},t.tickFormat=(l,s)=>{if(l==null&&(l=10),s==null&&(s=r===10?"s":","),typeof s!="function"&&(!(r%1)&&(s=rc(s)).precision==null&&(s.trim=!0),s=Kx(s)),l===1/0)return s;const u=Math.max(1,r*l/t.ticks().length);return d=>{let f=d/i(Math.round(a(d)));return f*r<r-.5&&(f*=r),f<=u?s(d):""}},t.nice=()=>n(CM(n(),{floor:l=>i(Math.floor(a(l))),ceil:l=>i(Math.ceil(a(l)))})),t}function MM(){const e=Yx(Gp()).domain([1,10]);return e.copy=()=>af(e,MM()).base(e.base()),nr.apply(e,arguments),e}function w2(e){return function(t){return Math.sign(t)*Math.log1p(Math.abs(t/e))}}function j2(e){return function(t){return Math.sign(t)*Math.expm1(Math.abs(t))*e}}function Vx(e){var t=1,n=e(w2(t),j2(t));return n.constant=function(r){return arguments.length?e(w2(t=+r),j2(t)):t},di(n)}function RM(){var e=Vx(Gp());return e.copy=function(){return af(e,RM()).constant(e.constant())},nr.apply(e,arguments)}function O2(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function rZ(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function aZ(e){return e<0?-e*e:e*e}function Xx(e){var t=e(tn,tn),n=1;function r(){return n===1?e(tn,tn):n===.5?e(rZ,aZ):e(O2(n),O2(1/n))}return t.exponent=function(a){return arguments.length?(n=+a,r()):n},di(t)}function Qx(){var e=Xx(Gp());return e.copy=function(){return af(e,Qx()).exponent(e.exponent())},nr.apply(e,arguments),e}function iZ(){return Qx.apply(null,arguments).exponent(.5)}function A2(e){return Math.sign(e)*e*e}function oZ(e){return Math.sign(e)*Math.sqrt(Math.abs(e))}function PM(){var e=Fx(),t=[0,1],n=!1,r;function a(i){var o=oZ(e(i));return isNaN(o)?r:n?Math.round(o):o}return a.invert=function(i){return e.invert(A2(i))},a.domain=function(i){return arguments.length?(e.domain(i),a):e.domain()},a.range=function(i){return arguments.length?(e.range((t=Array.from(i,hh)).map(A2)),a):t.slice()},a.rangeRound=function(i){return a.range(i).round(!0)},a.round=function(i){return arguments.length?(n=!!i,a):n},a.clamp=function(i){return arguments.length?(e.clamp(i),a):e.clamp()},a.unknown=function(i){return arguments.length?(r=i,a):r},a.copy=function(){return PM(e.domain(),t).round(n).clamp(e.clamp()).unknown(r)},nr.apply(a,arguments),di(a)}function $M(){var e=[],t=[],n=[],r;function a(){var o=0,l=Math.max(1,t.length);for(n=new Array(l-1);++o<l;)n[o-1]=fW(e,o/l);return i}function i(o){return o==null||isNaN(o=+o)?r:t[nf(n,o)]}return i.invertExtent=function(o){var l=t.indexOf(o);return l<0?[NaN,NaN]:[l>0?n[l-1]:e[0],l<n.length?n[l]:e[e.length-1]]},i.domain=function(o){if(!arguments.length)return e.slice();e=[];for(let l of o)l!=null&&!isNaN(l=+l)&&e.push(l);return e.sort(ni),a()},i.range=function(o){return arguments.length?(t=Array.from(o),a()):t.slice()},i.unknown=function(o){return arguments.length?(r=o,i):r},i.quantiles=function(){return n.slice()},i.copy=function(){return $M().domain(e).range(t).unknown(r)},nr.apply(i,arguments)}function kM(){var e=0,t=1,n=1,r=[.5],a=[0,1],i;function o(s){return s!=null&&s<=s?a[nf(r,s,0,n)]:i}function l(){var s=-1;for(r=new Array(n);++s<n;)r[s]=((s+1)*t-(s-n)*e)/(n+1);return o}return o.domain=function(s){return arguments.length?([e,t]=s,e=+e,t=+t,l()):[e,t]},o.range=function(s){return arguments.length?(n=(a=Array.from(s)).length-1,l()):a.slice()},o.invertExtent=function(s){var u=a.indexOf(s);return u<0?[NaN,NaN]:u<1?[e,r[0]]:u>=n?[r[n-1],t]:[r[u-1],r[u]]},o.unknown=function(s){return arguments.length&&(i=s),o},o.thresholds=function(){return r.slice()},o.copy=function(){return kM().domain([e,t]).range(a).unknown(i)},nr.apply(di(o),arguments)}function DM(){var e=[.5],t=[0,1],n,r=1;function a(i){return i!=null&&i<=i?t[nf(e,i,0,r)]:n}return a.domain=function(i){return arguments.length?(e=Array.from(i),r=Math.min(e.length,t.length-1),a):e.slice()},a.range=function(i){return arguments.length?(t=Array.from(i),r=Math.min(e.length,t.length-1),a):t.slice()},a.invertExtent=function(i){var o=t.indexOf(i);return[e[o-1],e[o]]},a.unknown=function(i){return arguments.length?(n=i,a):n},a.copy=function(){return DM().domain(e).range(t).unknown(n)},nr.apply(a,arguments)}const Ay=new Date,Ey=new Date;function Et(e,t,n,r){function a(i){return e(i=arguments.length===0?new Date:new Date(+i)),i}return a.floor=i=>(e(i=new Date(+i)),i),a.ceil=i=>(e(i=new Date(i-1)),t(i,1),e(i),i),a.round=i=>{const o=a(i),l=a.ceil(i);return i-o<l-i?o:l},a.offset=(i,o)=>(t(i=new Date(+i),o==null?1:Math.floor(o)),i),a.range=(i,o,l)=>{const s=[];if(i=a.ceil(i),l=l==null?1:Math.floor(l),!(i<o)||!(l>0))return s;let u;do s.push(u=new Date(+i)),t(i,l),e(i);while(u<i&&i<o);return s},a.filter=i=>Et(o=>{if(o>=o)for(;e(o),!i(o);)o.setTime(o-1)},(o,l)=>{if(o>=o)if(l<0)for(;++l<=0;)for(;t(o,-1),!i(o););else for(;--l>=0;)for(;t(o,1),!i(o););}),n&&(a.count=(i,o)=>(Ay.setTime(+i),Ey.setTime(+o),e(Ay),e(Ey),Math.floor(n(Ay,Ey))),a.every=i=>(i=Math.floor(i),!isFinite(i)||!(i>0)?null:i>1?a.filter(r?o=>r(o)%i===0:o=>a.count(0,o)%i===0):a)),a}const vh=Et(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);vh.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?Et(t=>{t.setTime(Math.floor(t/e)*e)},(t,n)=>{t.setTime(+t+n*e)},(t,n)=>(n-t)/e):vh);vh.range;const Wr=1e3,Vn=Wr*60,Zr=Vn*60,da=Zr*24,Wx=da*7,E2=da*30,_y=da*365,Pi=Et(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*Wr)},(e,t)=>(t-e)/Wr,e=>e.getUTCSeconds());Pi.range;const Zx=Et(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Wr)},(e,t)=>{e.setTime(+e+t*Vn)},(e,t)=>(t-e)/Vn,e=>e.getMinutes());Zx.range;const Jx=Et(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*Vn)},(e,t)=>(t-e)/Vn,e=>e.getUTCMinutes());Jx.range;const e1=Et(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Wr-e.getMinutes()*Vn)},(e,t)=>{e.setTime(+e+t*Zr)},(e,t)=>(t-e)/Zr,e=>e.getHours());e1.range;const t1=Et(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*Zr)},(e,t)=>(t-e)/Zr,e=>e.getUTCHours());t1.range;const of=Et(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Vn)/da,e=>e.getDate()-1);of.range;const Kp=Et(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/da,e=>e.getUTCDate()-1);Kp.range;const LM=Et(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/da,e=>Math.floor(e/da));LM.range;function bo(e){return Et(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())*Vn)/Wx)}const Yp=bo(0),gh=bo(1),lZ=bo(2),sZ=bo(3),Fl=bo(4),uZ=bo(5),cZ=bo(6);Yp.range;gh.range;lZ.range;sZ.range;Fl.range;uZ.range;cZ.range;function xo(e){return Et(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)/Wx)}const Vp=xo(0),bh=xo(1),fZ=xo(2),dZ=xo(3),Gl=xo(4),hZ=xo(5),pZ=xo(6);Vp.range;bh.range;fZ.range;dZ.range;Gl.range;hZ.range;pZ.range;const n1=Et(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());n1.range;const r1=Et(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());r1.range;const ha=Et(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());ha.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Et(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)});ha.range;const pa=Et(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());pa.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Et(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)});pa.range;function zM(e,t,n,r,a,i){const o=[[Pi,1,Wr],[Pi,5,5*Wr],[Pi,15,15*Wr],[Pi,30,30*Wr],[i,1,Vn],[i,5,5*Vn],[i,15,15*Vn],[i,30,30*Vn],[a,1,Zr],[a,3,3*Zr],[a,6,6*Zr],[a,12,12*Zr],[r,1,da],[r,2,2*da],[n,1,Wx],[t,1,E2],[t,3,3*E2],[e,1,_y]];function l(u,d,f){const h=d<u;h&&([u,d]=[d,u]);const p=f&&typeof f.range=="function"?f:s(u,d,f),b=p?p.range(u,+d+1):[];return h?b.reverse():b}function s(u,d,f){const h=Math.abs(d-u)/f,p=Bx(([,,x])=>x).right(o,h);if(p===o.length)return e.every(Ug(u/_y,d/_y,f));if(p===0)return vh.every(Math.max(Ug(u,d,f),1));const[b,v]=o[h/o[p-1][2]<o[p][2]/h?p-1:p];return b.every(v)}return[l,s]}const[mZ,yZ]=zM(pa,r1,Vp,LM,t1,Jx),[vZ,gZ]=zM(ha,n1,Yp,of,e1,Zx);function Ty(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 Ny(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 Vs(e,t,n){return{y:e,m:t,d:n,H:0,M:0,S:0,L:0}}function bZ(e){var t=e.dateTime,n=e.date,r=e.time,a=e.periods,i=e.days,o=e.shortDays,l=e.months,s=e.shortMonths,u=Xs(a),d=Qs(a),f=Xs(i),h=Qs(i),p=Xs(o),b=Qs(o),v=Xs(l),x=Qs(l),m=Xs(s),y=Qs(s),g={a:L,A:z,b:F,B:K,c:null,d:R2,e:R2,f:qZ,g:ZZ,G:eJ,H:BZ,I:IZ,j:UZ,L:BM,m:HZ,M:FZ,p:G,q:Y,Q:k2,s:D2,S:GZ,u:KZ,U:YZ,V:VZ,w:XZ,W:QZ,x:null,X:null,y:WZ,Y:JZ,Z:tJ,"%":$2},S={a:J,A:me,b:Le,B:ce,c:null,d:P2,e:P2,f:iJ,g:mJ,G:vJ,H:nJ,I:rJ,j:aJ,L:UM,m:oJ,M:lJ,p:$t,q:bt,Q:k2,s:D2,S:sJ,u:uJ,U:cJ,V:fJ,w:dJ,W:hJ,x:null,X:null,y:pJ,Y:yJ,Z:gJ,"%":$2},w={a:N,A:D,b:R,B,c:k,d:C2,e:C2,f:kZ,g:N2,G:T2,H:M2,I:M2,j:MZ,L:$Z,m:CZ,M:RZ,p:_,q:NZ,Q:LZ,s:zZ,S:PZ,u:OZ,U:AZ,V:EZ,w:jZ,W:_Z,x:C,X:M,y:N2,Y:T2,Z:TZ,"%":DZ};g.x=j(n,g),g.X=j(r,g),g.c=j(t,g),S.x=j(n,S),S.X=j(r,S),S.c=j(t,S);function j(Q,le){return function(fe){var q=[],Xe=-1,be=0,Re=Q.length,te,ze,kt;for(fe instanceof Date||(fe=new Date(+fe));++Xe<Re;)Q.charCodeAt(Xe)===37&&(q.push(Q.slice(be,Xe)),(ze=_2[te=Q.charAt(++Xe)])!=null?te=Q.charAt(++Xe):ze=te==="e"?" ":"0",(kt=le[te])&&(te=kt(fe,ze)),q.push(te),be=Xe+1);return q.push(Q.slice(be,Xe)),q.join("")}}function A(Q,le){return function(fe){var q=Vs(1900,void 0,1),Xe=E(q,Q,fe+="",0),be,Re;if(Xe!=fe.length)return null;if("Q"in q)return new Date(q.Q);if("s"in q)return new Date(q.s*1e3+("L"in q?q.L:0));if(le&&!("Z"in q)&&(q.Z=0),"p"in q&&(q.H=q.H%12+q.p*12),q.m===void 0&&(q.m="q"in q?q.q:0),"V"in q){if(q.V<1||q.V>53)return null;"w"in q||(q.w=1),"Z"in q?(be=Ny(Vs(q.y,0,1)),Re=be.getUTCDay(),be=Re>4||Re===0?bh.ceil(be):bh(be),be=Kp.offset(be,(q.V-1)*7),q.y=be.getUTCFullYear(),q.m=be.getUTCMonth(),q.d=be.getUTCDate()+(q.w+6)%7):(be=Ty(Vs(q.y,0,1)),Re=be.getDay(),be=Re>4||Re===0?gh.ceil(be):gh(be),be=of.offset(be,(q.V-1)*7),q.y=be.getFullYear(),q.m=be.getMonth(),q.d=be.getDate()+(q.w+6)%7)}else("W"in q||"U"in q)&&("w"in q||(q.w="u"in q?q.u%7:"W"in q?1:0),Re="Z"in q?Ny(Vs(q.y,0,1)).getUTCDay():Ty(Vs(q.y,0,1)).getDay(),q.m=0,q.d="W"in q?(q.w+6)%7+q.W*7-(Re+5)%7:q.w+q.U*7-(Re+6)%7);return"Z"in q?(q.H+=q.Z/100|0,q.M+=q.Z%100,Ny(q)):Ty(q)}}function E(Q,le,fe,q){for(var Xe=0,be=le.length,Re=fe.length,te,ze;Xe<be;){if(q>=Re)return-1;if(te=le.charCodeAt(Xe++),te===37){if(te=le.charAt(Xe++),ze=w[te in _2?le.charAt(Xe++):te],!ze||(q=ze(Q,fe,q))<0)return-1}else if(te!=fe.charCodeAt(q++))return-1}return q}function _(Q,le,fe){var q=u.exec(le.slice(fe));return q?(Q.p=d.get(q[0].toLowerCase()),fe+q[0].length):-1}function N(Q,le,fe){var q=p.exec(le.slice(fe));return q?(Q.w=b.get(q[0].toLowerCase()),fe+q[0].length):-1}function D(Q,le,fe){var q=f.exec(le.slice(fe));return q?(Q.w=h.get(q[0].toLowerCase()),fe+q[0].length):-1}function R(Q,le,fe){var q=m.exec(le.slice(fe));return q?(Q.m=y.get(q[0].toLowerCase()),fe+q[0].length):-1}function B(Q,le,fe){var q=v.exec(le.slice(fe));return q?(Q.m=x.get(q[0].toLowerCase()),fe+q[0].length):-1}function k(Q,le,fe){return E(Q,t,le,fe)}function C(Q,le,fe){return E(Q,n,le,fe)}function M(Q,le,fe){return E(Q,r,le,fe)}function L(Q){return o[Q.getDay()]}function z(Q){return i[Q.getDay()]}function F(Q){return s[Q.getMonth()]}function K(Q){return l[Q.getMonth()]}function G(Q){return a[+(Q.getHours()>=12)]}function Y(Q){return 1+~~(Q.getMonth()/3)}function J(Q){return o[Q.getUTCDay()]}function me(Q){return i[Q.getUTCDay()]}function Le(Q){return s[Q.getUTCMonth()]}function ce(Q){return l[Q.getUTCMonth()]}function $t(Q){return a[+(Q.getUTCHours()>=12)]}function bt(Q){return 1+~~(Q.getUTCMonth()/3)}return{format:function(Q){var le=j(Q+="",g);return le.toString=function(){return Q},le},parse:function(Q){var le=A(Q+="",!1);return le.toString=function(){return Q},le},utcFormat:function(Q){var le=j(Q+="",S);return le.toString=function(){return Q},le},utcParse:function(Q){var le=A(Q+="",!0);return le.toString=function(){return Q},le}}}var _2={"-":"",_:" ",0:"0"},Pt=/^\s*\d+/,xZ=/^%/,SZ=/[\\^$*+?|[\]().{}]/g;function _e(e,t,n){var r=e<0?"-":"",a=(r?-e:e)+"",i=a.length;return r+(i<n?new Array(n-i+1).join(t)+a:a)}function wZ(e){return e.replace(SZ,"\\$&")}function Xs(e){return new RegExp("^(?:"+e.map(wZ).join("|")+")","i")}function Qs(e){return new Map(e.map((t,n)=>[t.toLowerCase(),n]))}function jZ(e,t,n){var r=Pt.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function OZ(e,t,n){var r=Pt.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function AZ(e,t,n){var r=Pt.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function EZ(e,t,n){var r=Pt.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function _Z(e,t,n){var r=Pt.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function T2(e,t,n){var r=Pt.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function N2(e,t,n){var r=Pt.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function TZ(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 NZ(e,t,n){var r=Pt.exec(t.slice(n,n+1));return r?(e.q=r[0]*3-3,n+r[0].length):-1}function CZ(e,t,n){var r=Pt.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function C2(e,t,n){var r=Pt.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function MZ(e,t,n){var r=Pt.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function M2(e,t,n){var r=Pt.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function RZ(e,t,n){var r=Pt.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function PZ(e,t,n){var r=Pt.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function $Z(e,t,n){var r=Pt.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function kZ(e,t,n){var r=Pt.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function DZ(e,t,n){var r=xZ.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function LZ(e,t,n){var r=Pt.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function zZ(e,t,n){var r=Pt.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function R2(e,t){return _e(e.getDate(),t,2)}function BZ(e,t){return _e(e.getHours(),t,2)}function IZ(e,t){return _e(e.getHours()%12||12,t,2)}function UZ(e,t){return _e(1+of.count(ha(e),e),t,3)}function BM(e,t){return _e(e.getMilliseconds(),t,3)}function qZ(e,t){return BM(e,t)+"000"}function HZ(e,t){return _e(e.getMonth()+1,t,2)}function FZ(e,t){return _e(e.getMinutes(),t,2)}function GZ(e,t){return _e(e.getSeconds(),t,2)}function KZ(e){var t=e.getDay();return t===0?7:t}function YZ(e,t){return _e(Yp.count(ha(e)-1,e),t,2)}function IM(e){var t=e.getDay();return t>=4||t===0?Fl(e):Fl.ceil(e)}function VZ(e,t){return e=IM(e),_e(Fl.count(ha(e),e)+(ha(e).getDay()===4),t,2)}function XZ(e){return e.getDay()}function QZ(e,t){return _e(gh.count(ha(e)-1,e),t,2)}function WZ(e,t){return _e(e.getFullYear()%100,t,2)}function ZZ(e,t){return e=IM(e),_e(e.getFullYear()%100,t,2)}function JZ(e,t){return _e(e.getFullYear()%1e4,t,4)}function eJ(e,t){var n=e.getDay();return e=n>=4||n===0?Fl(e):Fl.ceil(e),_e(e.getFullYear()%1e4,t,4)}function tJ(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+_e(t/60|0,"0",2)+_e(t%60,"0",2)}function P2(e,t){return _e(e.getUTCDate(),t,2)}function nJ(e,t){return _e(e.getUTCHours(),t,2)}function rJ(e,t){return _e(e.getUTCHours()%12||12,t,2)}function aJ(e,t){return _e(1+Kp.count(pa(e),e),t,3)}function UM(e,t){return _e(e.getUTCMilliseconds(),t,3)}function iJ(e,t){return UM(e,t)+"000"}function oJ(e,t){return _e(e.getUTCMonth()+1,t,2)}function lJ(e,t){return _e(e.getUTCMinutes(),t,2)}function sJ(e,t){return _e(e.getUTCSeconds(),t,2)}function uJ(e){var t=e.getUTCDay();return t===0?7:t}function cJ(e,t){return _e(Vp.count(pa(e)-1,e),t,2)}function qM(e){var t=e.getUTCDay();return t>=4||t===0?Gl(e):Gl.ceil(e)}function fJ(e,t){return e=qM(e),_e(Gl.count(pa(e),e)+(pa(e).getUTCDay()===4),t,2)}function dJ(e){return e.getUTCDay()}function hJ(e,t){return _e(bh.count(pa(e)-1,e),t,2)}function pJ(e,t){return _e(e.getUTCFullYear()%100,t,2)}function mJ(e,t){return e=qM(e),_e(e.getUTCFullYear()%100,t,2)}function yJ(e,t){return _e(e.getUTCFullYear()%1e4,t,4)}function vJ(e,t){var n=e.getUTCDay();return e=n>=4||n===0?Gl(e):Gl.ceil(e),_e(e.getUTCFullYear()%1e4,t,4)}function gJ(){return"+0000"}function $2(){return"%"}function k2(e){return+e}function D2(e){return Math.floor(+e/1e3)}var No,HM,FM;bJ({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 bJ(e){return No=bZ(e),HM=No.format,No.parse,FM=No.utcFormat,No.utcParse,No}function xJ(e){return new Date(e)}function SJ(e){return e instanceof Date?+e:+new Date(+e)}function a1(e,t,n,r,a,i,o,l,s,u){var d=Fx(),f=d.invert,h=d.domain,p=u(".%L"),b=u(":%S"),v=u("%I:%M"),x=u("%I %p"),m=u("%a %d"),y=u("%b %d"),g=u("%B"),S=u("%Y");function w(j){return(s(j)<j?p:l(j)<j?b:o(j)<j?v:i(j)<j?x:r(j)<j?a(j)<j?m:y:n(j)<j?g:S)(j)}return d.invert=function(j){return new Date(f(j))},d.domain=function(j){return arguments.length?h(Array.from(j,SJ)):h().map(xJ)},d.ticks=function(j){var A=h();return e(A[0],A[A.length-1],j??10)},d.tickFormat=function(j,A){return A==null?w:u(A)},d.nice=function(j){var A=h();return(!j||typeof j.range!="function")&&(j=t(A[0],A[A.length-1],j??10)),j?h(CM(A,j)):d},d.copy=function(){return af(d,a1(e,t,n,r,a,i,o,l,s,u))},d}function wJ(){return nr.apply(a1(vZ,gZ,ha,n1,Yp,of,e1,Zx,Pi,HM).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function jJ(){return nr.apply(a1(mZ,yZ,pa,r1,Vp,Kp,t1,Jx,Pi,FM).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function Xp(){var e=0,t=1,n,r,a,i,o=tn,l=!1,s;function u(f){return f==null||isNaN(f=+f)?s:o(a===0?.5:(f=(i(f)-n)*a,l?Math.max(0,Math.min(1,f)):f))}u.domain=function(f){return arguments.length?([e,t]=f,n=i(e=+e),r=i(t=+t),a=n===r?0:1/(r-n),u):[e,t]},u.clamp=function(f){return arguments.length?(l=!!f,u):l},u.interpolator=function(f){return arguments.length?(o=f,u):o};function d(f){return function(h){var p,b;return arguments.length?([p,b]=h,o=f(p,b),u):[o(0),o(1)]}}return u.range=d(Ps),u.rangeRound=d(Hx),u.unknown=function(f){return arguments.length?(s=f,u):s},function(f){return i=f,n=f(e),r=f(t),a=n===r?0:1/(r-n),u}}function hi(e,t){return t.domain(e.domain()).interpolator(e.interpolator()).clamp(e.clamp()).unknown(e.unknown())}function GM(){var e=di(Xp()(tn));return e.copy=function(){return hi(e,GM())},ba.apply(e,arguments)}function KM(){var e=Yx(Xp()).domain([1,10]);return e.copy=function(){return hi(e,KM()).base(e.base())},ba.apply(e,arguments)}function YM(){var e=Vx(Xp());return e.copy=function(){return hi(e,YM()).constant(e.constant())},ba.apply(e,arguments)}function i1(){var e=Xx(Xp());return e.copy=function(){return hi(e,i1()).exponent(e.exponent())},ba.apply(e,arguments)}function OJ(){return i1.apply(null,arguments).exponent(.5)}function VM(){var e=[],t=tn;function n(r){if(r!=null&&!isNaN(r=+r))return t((nf(e,r,1)-1)/(e.length-1))}return n.domain=function(r){if(!arguments.length)return e.slice();e=[];for(let a of r)a!=null&&!isNaN(a=+a)&&e.push(a);return e.sort(ni),n},n.interpolator=function(r){return arguments.length?(t=r,n):t},n.range=function(){return e.map((r,a)=>t(a/(e.length-1)))},n.quantiles=function(r){return Array.from({length:r+1},(a,i)=>cW(e,i/r))},n.copy=function(){return VM(t).domain(e)},ba.apply(n,arguments)}function Qp(){var e=0,t=.5,n=1,r=1,a,i,o,l,s,u=tn,d,f=!1,h;function p(v){return isNaN(v=+v)?h:(v=.5+((v=+d(v))-i)*(r*v<r*i?l:s),u(f?Math.max(0,Math.min(1,v)):v))}p.domain=function(v){return arguments.length?([e,t,n]=v,a=d(e=+e),i=d(t=+t),o=d(n=+n),l=a===i?0:.5/(i-a),s=i===o?0:.5/(o-i),r=i<a?-1:1,p):[e,t,n]},p.clamp=function(v){return arguments.length?(f=!!v,p):f},p.interpolator=function(v){return arguments.length?(u=v,p):u};function b(v){return function(x){var m,y,g;return arguments.length?([m,y,g]=x,u=DW(v,[m,y,g]),p):[u(0),u(.5),u(1)]}}return p.range=b(Ps),p.rangeRound=b(Hx),p.unknown=function(v){return arguments.length?(h=v,p):h},function(v){return d=v,a=v(e),i=v(t),o=v(n),l=a===i?0:.5/(i-a),s=i===o?0:.5/(o-i),r=i<a?-1:1,p}}function XM(){var e=di(Qp()(tn));return e.copy=function(){return hi(e,XM())},ba.apply(e,arguments)}function QM(){var e=Yx(Qp()).domain([.1,1,10]);return e.copy=function(){return hi(e,QM()).base(e.base())},ba.apply(e,arguments)}function WM(){var e=Vx(Qp());return e.copy=function(){return hi(e,WM()).constant(e.constant())},ba.apply(e,arguments)}function o1(){var e=Xx(Qp());return e.copy=function(){return hi(e,o1()).exponent(e.exponent())},ba.apply(e,arguments)}function AJ(){return o1.apply(null,arguments).exponent(.5)}const L2=Object.freeze(Object.defineProperty({__proto__:null,scaleBand:Ju,scaleDiverging:XM,scaleDivergingLog:QM,scaleDivergingPow:o1,scaleDivergingSqrt:AJ,scaleDivergingSymlog:WM,scaleIdentity:NM,scaleImplicit:qg,scaleLinear:yh,scaleLog:MM,scaleOrdinal:Ix,scalePoint:ju,scalePow:Qx,scaleQuantile:$M,scaleQuantize:kM,scaleRadial:PM,scaleSequential:GM,scaleSequentialLog:KM,scaleSequentialPow:i1,scaleSequentialQuantile:VM,scaleSequentialSqrt:OJ,scaleSequentialSymlog:YM,scaleSqrt:iZ,scaleSymlog:RM,scaleThreshold:DM,scaleTime:wJ,scaleUtc:jJ,tickFormat:TM},Symbol.toStringTag,{value:"Module"}));var EJ=Os;function _J(e,t,n){for(var r=-1,a=e.length;++r<a;){var i=e[r],o=t(i);if(o!=null&&(l===void 0?o===o&&!EJ(o):n(o,l)))var l=o,s=i}return s}var Wp=_J;function TJ(e,t){return e>t}var ZM=TJ,NJ=Wp,CJ=ZM,MJ=Ms;function RJ(e){return e&&e.length?NJ(e,MJ,CJ):void 0}var PJ=RJ;const Zp=qe(PJ);function $J(e,t){return e<t}var JM=$J,kJ=Wp,DJ=JM,LJ=Ms;function zJ(e){return e&&e.length?kJ(e,LJ,DJ):void 0}var BJ=zJ;const Jp=qe(BJ);var IJ=bx,UJ=fi,qJ=sM,HJ=vn;function FJ(e,t){var n=HJ(e)?IJ:qJ;return n(e,UJ(t))}var GJ=FJ,KJ=oM,YJ=GJ;function VJ(e,t){return KJ(YJ(e,t),1)}var XJ=VJ;const QJ=qe(XJ);var WJ=kx;function ZJ(e,t){return WJ(e,t)}var JJ=ZJ;const em=qe(JJ);var $s=1e9,eee={precision:20,rounding:4,toExpNeg:-7,toExpPos:21,LN10:"2.302585092994045684017991454684364207601101488628772976033327900967572609677352480235997205089598298341967784042286"},s1,at=!0,Jn="[DecimalError] ",Wi=Jn+"Invalid argument: ",l1=Jn+"Exponent out of range: ",ks=Math.floor,_i=Math.pow,tee=/^(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,En,Tt=1e7,Ze=7,e3=9007199254740991,xh=ks(e3/Ze),Z={};Z.absoluteValue=Z.abs=function(){var e=new this.constructor(this);return e.s&&(e.s=1),e};Z.comparedTo=Z.cmp=function(e){var t,n,r,a,i=this;if(e=new i.constructor(e),i.s!==e.s)return i.s||-e.s;if(i.e!==e.e)return i.e>e.e^i.s<0?1:-1;for(r=i.d.length,a=e.d.length,t=0,n=r<a?r:a;t<n;++t)if(i.d[t]!==e.d[t])return i.d[t]>e.d[t]^i.s<0?1:-1;return r===a?0:r>a^i.s<0?1:-1};Z.decimalPlaces=Z.dp=function(){var e=this,t=e.d.length-1,n=(t-e.e)*Ze;if(t=e.d[t],t)for(;t%10==0;t/=10)n--;return n<0?0:n};Z.dividedBy=Z.div=function(e){return aa(this,new this.constructor(e))};Z.dividedToIntegerBy=Z.idiv=function(e){var t=this,n=t.constructor;return He(aa(t,new n(e),0,1),n.precision)};Z.equals=Z.eq=function(e){return!this.cmp(e)};Z.exponent=function(){return gt(this)};Z.greaterThan=Z.gt=function(e){return this.cmp(e)>0};Z.greaterThanOrEqualTo=Z.gte=function(e){return this.cmp(e)>=0};Z.isInteger=Z.isint=function(){return this.e>this.d.length-2};Z.isNegative=Z.isneg=function(){return this.s<0};Z.isPositive=Z.ispos=function(){return this.s>0};Z.isZero=function(){return this.s===0};Z.lessThan=Z.lt=function(e){return this.cmp(e)<0};Z.lessThanOrEqualTo=Z.lte=function(e){return this.cmp(e)<1};Z.logarithm=Z.log=function(e){var t,n=this,r=n.constructor,a=r.precision,i=a+5;if(e===void 0)e=new r(10);else if(e=new r(e),e.s<1||e.eq(En))throw Error(Jn+"NaN");if(n.s<1)throw Error(Jn+(n.s?"NaN":"-Infinity"));return n.eq(En)?new r(0):(at=!1,t=aa(ac(n,i),ac(e,i),i),at=!0,He(t,a))};Z.minus=Z.sub=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?r3(t,e):t3(t,(e.s=-e.s,e))};Z.modulo=Z.mod=function(e){var t,n=this,r=n.constructor,a=r.precision;if(e=new r(e),!e.s)throw Error(Jn+"NaN");return n.s?(at=!1,t=aa(n,e,0,1).times(e),at=!0,n.minus(t)):He(new r(n),a)};Z.naturalExponential=Z.exp=function(){return n3(this)};Z.naturalLogarithm=Z.ln=function(){return ac(this)};Z.negated=Z.neg=function(){var e=new this.constructor(this);return e.s=-e.s||0,e};Z.plus=Z.add=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?t3(t,e):r3(t,(e.s=-e.s,e))};Z.precision=Z.sd=function(e){var t,n,r,a=this;if(e!==void 0&&e!==!!e&&e!==1&&e!==0)throw Error(Wi+e);if(t=gt(a)+1,r=a.d.length-1,n=r*Ze+1,r=a.d[r],r){for(;r%10==0;r/=10)n--;for(r=a.d[0];r>=10;r/=10)n++}return e&&t>n?t:n};Z.squareRoot=Z.sqrt=function(){var e,t,n,r,a,i,o,l=this,s=l.constructor;if(l.s<1){if(!l.s)return new s(0);throw Error(Jn+"NaN")}for(e=gt(l),at=!1,a=Math.sqrt(+l),a==0||a==1/0?(t=jr(l.d),(t.length+e)%2==0&&(t+="0"),a=Math.sqrt(t),e=ks((e+1)/2)-(e<0||e%2),a==1/0?t="5e"+e:(t=a.toExponential(),t=t.slice(0,t.indexOf("e")+1)+e),r=new s(t)):r=new s(a.toString()),n=s.precision,a=o=n+3;;)if(i=r,r=i.plus(aa(l,i,o+2)).times(.5),jr(i.d).slice(0,o)===(t=jr(r.d)).slice(0,o)){if(t=t.slice(o-3,o+1),a==o&&t=="4999"){if(He(i,n+1,0),i.times(i).eq(l)){r=i;break}}else if(t!="9999")break;o+=4}return at=!0,He(r,n)};Z.times=Z.mul=function(e){var t,n,r,a,i,o,l,s,u,d=this,f=d.constructor,h=d.d,p=(e=new f(e)).d;if(!d.s||!e.s)return new f(0);for(e.s*=d.s,n=d.e+e.e,s=h.length,u=p.length,s<u&&(i=h,h=p,p=i,o=s,s=u,u=o),i=[],o=s+u,r=o;r--;)i.push(0);for(r=u;--r>=0;){for(t=0,a=s+r;a>r;)l=i[a]+p[r]*h[a-r-1]+t,i[a--]=l%Tt|0,t=l/Tt|0;i[a]=(i[a]+t)%Tt|0}for(;!i[--o];)i.pop();return t?++n:i.shift(),e.d=i,e.e=n,at?He(e,f.precision):e};Z.toDecimalPlaces=Z.todp=function(e,t){var n=this,r=n.constructor;return n=new r(n),e===void 0?n:(_r(e,0,$s),t===void 0?t=r.rounding:_r(t,0,8),He(n,e+gt(n)+1,t))};Z.toExponential=function(e,t){var n,r=this,a=r.constructor;return e===void 0?n=uo(r,!0):(_r(e,0,$s),t===void 0?t=a.rounding:_r(t,0,8),r=He(new a(r),e+1,t),n=uo(r,!0,e+1)),n};Z.toFixed=function(e,t){var n,r,a=this,i=a.constructor;return e===void 0?uo(a):(_r(e,0,$s),t===void 0?t=i.rounding:_r(t,0,8),r=He(new i(a),e+gt(a)+1,t),n=uo(r.abs(),!1,e+gt(r)+1),a.isneg()&&!a.isZero()?"-"+n:n)};Z.toInteger=Z.toint=function(){var e=this,t=e.constructor;return He(new t(e),gt(e)+1,t.rounding)};Z.toNumber=function(){return+this};Z.toPower=Z.pow=function(e){var t,n,r,a,i,o,l=this,s=l.constructor,u=12,d=+(e=new s(e));if(!e.s)return new s(En);if(l=new s(l),!l.s){if(e.s<1)throw Error(Jn+"Infinity");return l}if(l.eq(En))return l;if(r=s.precision,e.eq(En))return He(l,r);if(t=e.e,n=e.d.length-1,o=t>=n,i=l.s,o){if((n=d<0?-d:d)<=e3){for(a=new s(En),t=Math.ceil(r/Ze+4),at=!1;n%2&&(a=a.times(l),B2(a.d,t)),n=ks(n/2),n!==0;)l=l.times(l),B2(l.d,t);return at=!0,e.s<0?new s(En).div(a):He(a,r)}}else if(i<0)throw Error(Jn+"NaN");return i=i<0&&e.d[Math.max(t,n)]&1?-1:1,l.s=1,at=!1,a=e.times(ac(l,r+u)),at=!0,a=n3(a),a.s=i,a};Z.toPrecision=function(e,t){var n,r,a=this,i=a.constructor;return e===void 0?(n=gt(a),r=uo(a,n<=i.toExpNeg||n>=i.toExpPos)):(_r(e,1,$s),t===void 0?t=i.rounding:_r(t,0,8),a=He(new i(a),e,t),n=gt(a),r=uo(a,e<=n||n<=i.toExpNeg,e)),r};Z.toSignificantDigits=Z.tosd=function(e,t){var n=this,r=n.constructor;return e===void 0?(e=r.precision,t=r.rounding):(_r(e,1,$s),t===void 0?t=r.rounding:_r(t,0,8)),He(new r(n),e,t)};Z.toString=Z.valueOf=Z.val=Z.toJSON=Z[Symbol.for("nodejs.util.inspect.custom")]=function(){var e=this,t=gt(e),n=e.constructor;return uo(e,t<=n.toExpNeg||t>=n.toExpPos)};function t3(e,t){var n,r,a,i,o,l,s,u,d=e.constructor,f=d.precision;if(!e.s||!t.s)return t.s||(t=new d(e)),at?He(t,f):t;if(s=e.d,u=t.d,o=e.e,a=t.e,s=s.slice(),i=o-a,i){for(i<0?(r=s,i=-i,l=u.length):(r=u,a=o,l=s.length),o=Math.ceil(f/Ze),l=o>l?o+1:l+1,i>l&&(i=l,r.length=1),r.reverse();i--;)r.push(0);r.reverse()}for(l=s.length,i=u.length,l-i<0&&(i=l,r=u,u=s,s=r),n=0;i;)n=(s[--i]=s[i]+u[i]+n)/Tt|0,s[i]%=Tt;for(n&&(s.unshift(n),++a),l=s.length;s[--l]==0;)s.pop();return t.d=s,t.e=a,at?He(t,f):t}function _r(e,t,n){if(e!==~~e||e<t||e>n)throw Error(Wi+e)}function jr(e){var t,n,r,a=e.length-1,i="",o=e[0];if(a>0){for(i+=o,t=1;t<a;t++)r=e[t]+"",n=Ze-r.length,n&&(i+=Ea(n)),i+=r;o=e[t],r=o+"",n=Ze-r.length,n&&(i+=Ea(n))}else if(o===0)return"0";for(;o%10===0;)o/=10;return i+o}var aa=function(){function e(r,a){var i,o=0,l=r.length;for(r=r.slice();l--;)i=r[l]*a+o,r[l]=i%Tt|0,o=i/Tt|0;return o&&r.unshift(o),r}function t(r,a,i,o){var l,s;if(i!=o)s=i>o?1:-1;else for(l=s=0;l<i;l++)if(r[l]!=a[l]){s=r[l]>a[l]?1:-1;break}return s}function n(r,a,i){for(var o=0;i--;)r[i]-=o,o=r[i]<a[i]?1:0,r[i]=o*Tt+r[i]-a[i];for(;!r[0]&&r.length>1;)r.shift()}return function(r,a,i,o){var l,s,u,d,f,h,p,b,v,x,m,y,g,S,w,j,A,E,_=r.constructor,N=r.s==a.s?1:-1,D=r.d,R=a.d;if(!r.s)return new _(r);if(!a.s)throw Error(Jn+"Division by zero");for(s=r.e-a.e,A=R.length,w=D.length,p=new _(N),b=p.d=[],u=0;R[u]==(D[u]||0);)++u;if(R[u]>(D[u]||0)&&--s,i==null?y=i=_.precision:o?y=i+(gt(r)-gt(a))+1:y=i,y<0)return new _(0);if(y=y/Ze+2|0,u=0,A==1)for(d=0,R=R[0],y++;(u<w||d)&&y--;u++)g=d*Tt+(D[u]||0),b[u]=g/R|0,d=g%R|0;else{for(d=Tt/(R[0]+1)|0,d>1&&(R=e(R,d),D=e(D,d),A=R.length,w=D.length),S=A,v=D.slice(0,A),x=v.length;x<A;)v[x++]=0;E=R.slice(),E.unshift(0),j=R[0],R[1]>=Tt/2&&++j;do d=0,l=t(R,v,A,x),l<0?(m=v[0],A!=x&&(m=m*Tt+(v[1]||0)),d=m/j|0,d>1?(d>=Tt&&(d=Tt-1),f=e(R,d),h=f.length,x=v.length,l=t(f,v,h,x),l==1&&(d--,n(f,A<h?E:R,h))):(d==0&&(l=d=1),f=R.slice()),h=f.length,h<x&&f.unshift(0),n(v,f,x),l==-1&&(x=v.length,l=t(R,v,A,x),l<1&&(d++,n(v,A<x?E:R,x))),x=v.length):l===0&&(d++,v=[0]),b[u++]=d,l&&v[0]?v[x++]=D[S]||0:(v=[D[S]],x=1);while((S++<w||v[0]!==void 0)&&y--)}return b[0]||b.shift(),p.e=s,He(p,o?i+gt(p)+1:i)}}();function n3(e,t){var n,r,a,i,o,l,s=0,u=0,d=e.constructor,f=d.precision;if(gt(e)>16)throw Error(l1+gt(e));if(!e.s)return new d(En);for(at=!1,l=f,o=new d(.03125);e.abs().gte(.1);)e=e.times(o),u+=5;for(r=Math.log(_i(2,u))/Math.LN10*2+5|0,l+=r,n=a=i=new d(En),d.precision=l;;){if(a=He(a.times(e),l),n=n.times(++s),o=i.plus(aa(a,n,l)),jr(o.d).slice(0,l)===jr(i.d).slice(0,l)){for(;u--;)i=He(i.times(i),l);return d.precision=f,t==null?(at=!0,He(i,f)):i}i=o}}function gt(e){for(var t=e.e*Ze,n=e.d[0];n>=10;n/=10)t++;return t}function Cy(e,t,n){if(t>e.LN10.sd())throw at=!0,n&&(e.precision=n),Error(Jn+"LN10 precision limit exceeded");return He(new e(e.LN10),t)}function Ea(e){for(var t="";e--;)t+="0";return t}function ac(e,t){var n,r,a,i,o,l,s,u,d,f=1,h=10,p=e,b=p.d,v=p.constructor,x=v.precision;if(p.s<1)throw Error(Jn+(p.s?"NaN":"-Infinity"));if(p.eq(En))return new v(0);if(t==null?(at=!1,u=x):u=t,p.eq(10))return t==null&&(at=!0),Cy(v,u);if(u+=h,v.precision=u,n=jr(b),r=n.charAt(0),i=gt(p),Math.abs(i)<15e14){for(;r<7&&r!=1||r==1&&n.charAt(1)>3;)p=p.times(e),n=jr(p.d),r=n.charAt(0),f++;i=gt(p),r>1?(p=new v("0."+n),i++):p=new v(r+"."+n.slice(1))}else return s=Cy(v,u+2,x).times(i+""),p=ac(new v(r+"."+n.slice(1)),u-h).plus(s),v.precision=x,t==null?(at=!0,He(p,x)):p;for(l=o=p=aa(p.minus(En),p.plus(En),u),d=He(p.times(p),u),a=3;;){if(o=He(o.times(d),u),s=l.plus(aa(o,new v(a),u)),jr(s.d).slice(0,u)===jr(l.d).slice(0,u))return l=l.times(2),i!==0&&(l=l.plus(Cy(v,u+2,x).times(i+""))),l=aa(l,new v(f),u),v.precision=x,t==null?(at=!0,He(l,x)):l;l=s,a+=2}}function z2(e,t){var n,r,a;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(a=t.length;t.charCodeAt(a-1)===48;)--a;if(t=t.slice(r,a),t){if(a-=r,n=n-r-1,e.e=ks(n/Ze),e.d=[],r=(n+1)%Ze,n<0&&(r+=Ze),r<a){for(r&&e.d.push(+t.slice(0,r)),a-=Ze;r<a;)e.d.push(+t.slice(r,r+=Ze));t=t.slice(r),r=Ze-t.length}else r-=a;for(;r--;)t+="0";if(e.d.push(+t),at&&(e.e>xh||e.e<-xh))throw Error(l1+n)}else e.s=0,e.e=0,e.d=[0];return e}function He(e,t,n){var r,a,i,o,l,s,u,d,f=e.d;for(o=1,i=f[0];i>=10;i/=10)o++;if(r=t-o,r<0)r+=Ze,a=t,u=f[d=0];else{if(d=Math.ceil((r+1)/Ze),i=f.length,d>=i)return e;for(u=i=f[d],o=1;i>=10;i/=10)o++;r%=Ze,a=r-Ze+o}if(n!==void 0&&(i=_i(10,o-a-1),l=u/i%10|0,s=t<0||f[d+1]!==void 0||u%i,s=n<4?(l||s)&&(n==0||n==(e.s<0?3:2)):l>5||l==5&&(n==4||s||n==6&&(r>0?a>0?u/_i(10,o-a):0:f[d-1])%10&1||n==(e.s<0?8:7))),t<1||!f[0])return s?(i=gt(e),f.length=1,t=t-i-1,f[0]=_i(10,(Ze-t%Ze)%Ze),e.e=ks(-t/Ze)||0):(f.length=1,f[0]=e.e=e.s=0),e;if(r==0?(f.length=d,i=1,d--):(f.length=d+1,i=_i(10,Ze-r),f[d]=a>0?(u/_i(10,o-a)%_i(10,a)|0)*i:0),s)for(;;)if(d==0){(f[0]+=i)==Tt&&(f[0]=1,++e.e);break}else{if(f[d]+=i,f[d]!=Tt)break;f[d--]=0,i=1}for(r=f.length;f[--r]===0;)f.pop();if(at&&(e.e>xh||e.e<-xh))throw Error(l1+gt(e));return e}function r3(e,t){var n,r,a,i,o,l,s,u,d,f,h=e.constructor,p=h.precision;if(!e.s||!t.s)return t.s?t.s=-t.s:t=new h(e),at?He(t,p):t;if(s=e.d,f=t.d,r=t.e,u=e.e,s=s.slice(),o=u-r,o){for(d=o<0,d?(n=s,o=-o,l=f.length):(n=f,r=u,l=s.length),a=Math.max(Math.ceil(p/Ze),l)+2,o>a&&(o=a,n.length=1),n.reverse(),a=o;a--;)n.push(0);n.reverse()}else{for(a=s.length,l=f.length,d=a<l,d&&(l=a),a=0;a<l;a++)if(s[a]!=f[a]){d=s[a]<f[a];break}o=0}for(d&&(n=s,s=f,f=n,t.s=-t.s),l=s.length,a=f.length-l;a>0;--a)s[l++]=0;for(a=f.length;a>o;){if(s[--a]<f[a]){for(i=a;i&&s[--i]===0;)s[i]=Tt-1;--s[i],s[a]+=Tt}s[a]-=f[a]}for(;s[--l]===0;)s.pop();for(;s[0]===0;s.shift())--r;return s[0]?(t.d=s,t.e=r,at?He(t,p):t):new h(0)}function uo(e,t,n){var r,a=gt(e),i=jr(e.d),o=i.length;return t?(n&&(r=n-o)>0?i=i.charAt(0)+"."+i.slice(1)+Ea(r):o>1&&(i=i.charAt(0)+"."+i.slice(1)),i=i+(a<0?"e":"e+")+a):a<0?(i="0."+Ea(-a-1)+i,n&&(r=n-o)>0&&(i+=Ea(r))):a>=o?(i+=Ea(a+1-o),n&&(r=n-a-1)>0&&(i=i+"."+Ea(r))):((r=a+1)<o&&(i=i.slice(0,r)+"."+i.slice(r)),n&&(r=n-o)>0&&(a+1===o&&(i+="."),i+=Ea(r))),e.s<0?"-"+i:i}function B2(e,t){if(e.length>t)return e.length=t,!0}function a3(e){var t,n,r;function a(i){var o=this;if(!(o instanceof a))return new a(i);if(o.constructor=a,i instanceof a){o.s=i.s,o.e=i.e,o.d=(i=i.d)?i.slice():i;return}if(typeof i=="number"){if(i*0!==0)throw Error(Wi+i);if(i>0)o.s=1;else if(i<0)i=-i,o.s=-1;else{o.s=0,o.e=0,o.d=[0];return}if(i===~~i&&i<1e7){o.e=0,o.d=[i];return}return z2(o,i.toString())}else if(typeof i!="string")throw Error(Wi+i);if(i.charCodeAt(0)===45?(i=i.slice(1),o.s=-1):o.s=1,tee.test(i))z2(o,i);else throw Error(Wi+i)}if(a.prototype=Z,a.ROUND_UP=0,a.ROUND_DOWN=1,a.ROUND_CEIL=2,a.ROUND_FLOOR=3,a.ROUND_HALF_UP=4,a.ROUND_HALF_DOWN=5,a.ROUND_HALF_EVEN=6,a.ROUND_HALF_CEIL=7,a.ROUND_HALF_FLOOR=8,a.clone=a3,a.config=a.set=nee,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 a.config(e),a}function nee(e){if(!e||typeof e!="object")throw Error(Jn+"Object expected");var t,n,r,a=["precision",1,$s,"rounding",0,8,"toExpNeg",-1/0,0,"toExpPos",0,1/0];for(t=0;t<a.length;t+=3)if((r=e[n=a[t]])!==void 0)if(ks(r)===r&&r>=a[t+1]&&r<=a[t+2])this[n]=r;else throw Error(Wi+n+": "+r);if((r=e[n="LN10"])!==void 0)if(r==Math.LN10)this[n]=new this(r);else throw Error(Wi+n+": "+r);return this}var s1=a3(eee);En=new s1(1);const Ie=s1;function ree(e){return lee(e)||oee(e)||iee(e)||aee()}function aee(){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 iee(e,t){if(e){if(typeof e=="string")return Kg(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 Kg(e,t)}}function oee(e){if(typeof Symbol<"u"&&Symbol.iterator in Object(e))return Array.from(e)}function lee(e){if(Array.isArray(e))return Kg(e)}function Kg(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 see=function(t){return t},i3={},o3=function(t){return t===i3},I2=function(t){return function n(){return arguments.length===0||arguments.length===1&&o3(arguments.length<=0?void 0:arguments[0])?n:t.apply(void 0,arguments)}},uee=function e(t,n){return t===1?n:I2(function(){for(var r=arguments.length,a=new Array(r),i=0;i<r;i++)a[i]=arguments[i];var o=a.filter(function(l){return l!==i3}).length;return o>=t?n.apply(void 0,a):e(t-o,I2(function(){for(var l=arguments.length,s=new Array(l),u=0;u<l;u++)s[u]=arguments[u];var d=a.map(function(f){return o3(f)?s.shift():f});return n.apply(void 0,ree(d).concat(s))}))})},tm=function(t){return uee(t.length,t)},Yg=function(t,n){for(var r=[],a=t;a<n;++a)r[a-t]=a;return r},cee=tm(function(e,t){return Array.isArray(t)?t.map(e):Object.keys(t).map(function(n){return t[n]}).map(e)}),fee=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];if(!n.length)return see;var a=n.reverse(),i=a[0],o=a.slice(1);return function(){return o.reduce(function(l,s){return s(l)},i.apply(void 0,arguments))}},Vg=function(t){return Array.isArray(t)?t.reverse():t.split("").reverse.join("")},l3=function(t){var n=null,r=null;return function(){for(var a=arguments.length,i=new Array(a),o=0;o<a;o++)i[o]=arguments[o];return n&&i.every(function(l,s){return l===n[s]})||(n=i,r=t.apply(void 0,i)),r}};function dee(e){var t;return e===0?t=1:t=Math.floor(new Ie(e).abs().log(10).toNumber())+1,t}function hee(e,t,n){for(var r=new Ie(e),a=0,i=[];r.lt(t)&&a<1e5;)i.push(r.toNumber()),r=r.add(n),a++;return i}var pee=tm(function(e,t,n){var r=+e,a=+t;return r+n*(a-r)}),mee=tm(function(e,t,n){var r=t-+e;return r=r||1/0,(n-e)/r}),yee=tm(function(e,t,n){var r=t-+e;return r=r||1/0,Math.max(0,Math.min(1,(n-e)/r))});const nm={rangeStep:hee,getDigitCount:dee,interpolateNumber:pee,uninterpolateNumber:mee,uninterpolateTruncation:yee};function Xg(e){return bee(e)||gee(e)||s3(e)||vee()}function vee(){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 gee(e){if(typeof Symbol<"u"&&Symbol.iterator in Object(e))return Array.from(e)}function bee(e){if(Array.isArray(e))return Qg(e)}function ic(e,t){return wee(e)||See(e,t)||s3(e,t)||xee()}function xee(){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 s3(e,t){if(e){if(typeof e=="string")return Qg(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 Qg(e,t)}}function Qg(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 See(e,t){if(!(typeof Symbol>"u"||!(Symbol.iterator in Object(e)))){var n=[],r=!0,a=!1,i=void 0;try{for(var o=e[Symbol.iterator](),l;!(r=(l=o.next()).done)&&(n.push(l.value),!(t&&n.length===t));r=!0);}catch(s){a=!0,i=s}finally{try{!r&&o.return!=null&&o.return()}finally{if(a)throw i}}return n}}function wee(e){if(Array.isArray(e))return e}function u3(e){var t=ic(e,2),n=t[0],r=t[1],a=n,i=r;return n>r&&(a=r,i=n),[a,i]}function c3(e,t,n){if(e.lte(0))return new Ie(0);var r=nm.getDigitCount(e.toNumber()),a=new Ie(10).pow(r),i=e.div(a),o=r!==1?.05:.1,l=new Ie(Math.ceil(i.div(o).toNumber())).add(n).mul(o),s=l.mul(a);return t?s:new Ie(Math.ceil(s))}function jee(e,t,n){var r=1,a=new Ie(e);if(!a.isint()&&n){var i=Math.abs(e);i<1?(r=new Ie(10).pow(nm.getDigitCount(e)-1),a=new Ie(Math.floor(a.div(r).toNumber())).mul(r)):i>1&&(a=new Ie(Math.floor(e)))}else e===0?a=new Ie(Math.floor((t-1)/2)):n||(a=new Ie(Math.floor(e)));var o=Math.floor((t-1)/2),l=fee(cee(function(s){return a.add(new Ie(s-o).mul(r)).toNumber()}),Yg);return l(0,t)}function f3(e,t,n,r){var a=arguments.length>4&&arguments[4]!==void 0?arguments[4]:0;if(!Number.isFinite((t-e)/(n-1)))return{step:new Ie(0),tickMin:new Ie(0),tickMax:new Ie(0)};var i=c3(new Ie(t).sub(e).div(n-1),r,a),o;e<=0&&t>=0?o=new Ie(0):(o=new Ie(e).add(t).div(2),o=o.sub(new Ie(o).mod(i)));var l=Math.ceil(o.sub(e).div(i).toNumber()),s=Math.ceil(new Ie(t).sub(o).div(i).toNumber()),u=l+s+1;return u>n?f3(e,t,n,r,a+1):(u<n&&(s=t>0?s+(n-u):s,l=t>0?l:l+(n-u)),{step:i,tickMin:o.sub(new Ie(l).mul(i)),tickMax:o.add(new Ie(s).mul(i))})}function Oee(e){var t=ic(e,2),n=t[0],r=t[1],a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:6,i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,o=Math.max(a,2),l=u3([n,r]),s=ic(l,2),u=s[0],d=s[1];if(u===-1/0||d===1/0){var f=d===1/0?[u].concat(Xg(Yg(0,a-1).map(function(){return 1/0}))):[].concat(Xg(Yg(0,a-1).map(function(){return-1/0})),[d]);return n>r?Vg(f):f}if(u===d)return jee(u,a,i);var h=f3(u,d,o,i),p=h.step,b=h.tickMin,v=h.tickMax,x=nm.rangeStep(b,v.add(new Ie(.1).mul(p)),p);return n>r?Vg(x):x}function Aee(e,t){var n=ic(e,2),r=n[0],a=n[1],i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,o=u3([r,a]),l=ic(o,2),s=l[0],u=l[1];if(s===-1/0||u===1/0)return[r,a];if(s===u)return[s];var d=Math.max(t,2),f=c3(new Ie(u).sub(s).div(d-1),i,0),h=[].concat(Xg(nm.rangeStep(new Ie(s),new Ie(u).sub(new Ie(.99).mul(f)),f)),[u]);return r>a?Vg(h):h}var Eee=l3(Oee),_ee=l3(Aee),Tee="Invariant failed";function co(e,t){throw new Error(Tee)}var Nee=["offset","layout","width","dataKey","data","dataPointFormatter","xAxis","yAxis"];function Kl(e){"@babel/helpers - typeof";return Kl=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},Kl(e)}function Sh(){return Sh=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},Sh.apply(this,arguments)}function Cee(e,t){return $ee(e)||Pee(e,t)||Ree(e,t)||Mee()}function Mee(){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 Ree(e,t){if(e){if(typeof e=="string")return U2(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 U2(e,t)}}function U2(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 Pee(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,a,i,o,l=[],s=!0,u=!1;try{if(i=(n=n.call(e)).next,t!==0)for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(d){u=!0,a=d}finally{try{if(!s&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(u)throw a}}return l}}function $ee(e){if(Array.isArray(e))return e}function kee(e,t){if(e==null)return{};var n=Dee(e,t),r,a;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(a=0;a<i.length;a++)r=i[a],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Dee(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 Lee(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function zee(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,p3(r.key),r)}}function Bee(e,t,n){return t&&zee(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Iee(e,t,n){return t=wh(t),Uee(e,d3()?Reflect.construct(t,n||[],wh(e).constructor):t.apply(e,n))}function Uee(e,t){if(t&&(Kl(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return qee(e)}function qee(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function d3(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(d3=function(){return!!e})()}function wh(e){return wh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},wh(e)}function Hee(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&&Wg(e,t)}function Wg(e,t){return Wg=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,a){return r.__proto__=a,r},Wg(e,t)}function h3(e,t,n){return t=p3(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function p3(e){var t=Fee(e,"string");return Kl(t)=="symbol"?t:t+""}function Fee(e,t){if(Kl(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Kl(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var rm=function(e){function t(){return Lee(this,t),Iee(this,t,arguments)}return Hee(t,e),Bee(t,[{key:"render",value:function(){var r=this.props,a=r.offset,i=r.layout,o=r.width,l=r.dataKey,s=r.data,u=r.dataPointFormatter,d=r.xAxis,f=r.yAxis,h=kee(r,Nee),p=oe(h,!1);this.props.direction==="x"&&d.type!=="number"&&co();var b=s.map(function(v){var x=u(v,l),m=x.x,y=x.y,g=x.value,S=x.errorVal;if(!S)return null;var w=[],j,A;if(Array.isArray(S)){var E=Cee(S,2);j=E[0],A=E[1]}else j=A=S;if(i==="vertical"){var _=d.scale,N=y+a,D=N+o,R=N-o,B=_(g-j),k=_(g+A);w.push({x1:k,y1:D,x2:k,y2:R}),w.push({x1:B,y1:N,x2:k,y2:N}),w.push({x1:B,y1:D,x2:B,y2:R})}else if(i==="horizontal"){var C=f.scale,M=m+a,L=M-o,z=M+o,F=C(g-j),K=C(g+A);w.push({x1:L,y1:K,x2:z,y2:K}),w.push({x1:M,y1:F,x2:M,y2:K}),w.push({x1:L,y1:F,x2:z,y2:F})}return $.createElement(ke,Sh({className:"recharts-errorBar",key:"bar-".concat(w.map(function(G){return"".concat(G.x1,"-").concat(G.x2,"-").concat(G.y1,"-").concat(G.y2)}))},p),w.map(function(G){return $.createElement("line",Sh({},G,{key:"line-".concat(G.x1,"-").concat(G.x2,"-").concat(G.y1,"-").concat(G.y2)}))}))});return $.createElement(ke,{className:"recharts-errorBars"},b)}}])}($.Component);h3(rm,"defaultProps",{stroke:"black",strokeWidth:1.5,width:5,offset:0,layout:"horizontal"});h3(rm,"displayName","ErrorBar");function oc(e){"@babel/helpers - typeof";return oc=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},oc(e)}function q2(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function gi(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?q2(Object(n),!0).forEach(function(r){Gee(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):q2(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Gee(e,t,n){return t=Kee(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Kee(e){var t=Yee(e,"string");return oc(t)=="symbol"?t:t+""}function Yee(e,t){if(oc(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(oc(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var m3=function(t){var n=t.children,r=t.formattedGraphicalItems,a=t.legendWidth,i=t.legendContent,o=Sn(n,ll);if(!o)return null;var l=ll.defaultProps,s=l!==void 0?gi(gi({},l),o.props):{},u;return o.props&&o.props.payload?u=o.props&&o.props.payload:i==="children"?u=(r||[]).reduce(function(d,f){var h=f.item,p=f.props,b=p.sectors||p.data||[];return d.concat(b.map(function(v){return{type:o.props.iconType||h.props.legendType,value:v.name,color:v.fill,payload:v}}))},[]):u=(r||[]).map(function(d){var f=d.item,h=f.type.defaultProps,p=h!==void 0?gi(gi({},h),f.props):{},b=p.dataKey,v=p.name,x=p.legendType,m=p.hide;return{inactive:m,dataKey:b,type:s.iconType||x||"square",color:u1(f),value:v||b,payload:p}}),gi(gi(gi({},s),ll.getWithHeight(o,a)),{},{payload:u,item:o})};function lc(e){"@babel/helpers - typeof";return lc=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},lc(e)}function H2(e){return Wee(e)||Qee(e)||Xee(e)||Vee()}function Vee(){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 Xee(e,t){if(e){if(typeof e=="string")return Zg(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 Zg(e,t)}}function Qee(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Wee(e){if(Array.isArray(e))return Zg(e)}function Zg(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 F2(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function st(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?F2(Object(n),!0).forEach(function(r){ul(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):F2(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function ul(e,t,n){return t=Zee(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Zee(e){var t=Jee(e,"string");return lc(t)=="symbol"?t:t+""}function Jee(e,t){if(lc(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(lc(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 ge(e)||ge(t)?n:Ot(t)?Rn(e,t,n):se(t)?t(e):n}function Ou(e,t,n,r){var a=QJ(e,function(l){return Kt(l,t)});if(n==="number"){var i=a.filter(function(l){return V(l)||parseFloat(l)});return i.length?[Jp(i),Zp(i)]:[1/0,-1/0]}var o=r?a.filter(function(l){return!ge(l)}):a;return o.map(function(l){return Ot(l)||l instanceof Date?l:""})}var ete=function(t){var n,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],a=arguments.length>2?arguments[2]:void 0,i=arguments.length>3?arguments[3]:void 0,o=-1,l=(n=r==null?void 0:r.length)!==null&&n!==void 0?n:0;if(l<=1)return 0;if(i&&i.axisType==="angleAxis"&&Math.abs(Math.abs(i.range[1]-i.range[0])-360)<=1e-6)for(var s=i.range,u=0;u<l;u++){var d=u>0?a[u-1].coordinate:a[l-1].coordinate,f=a[u].coordinate,h=u>=l-1?a[0].coordinate:a[u+1].coordinate,p=void 0;if(Jt(f-d)!==Jt(h-f)){var b=[];if(Jt(h-f)===Jt(s[1]-s[0])){p=h;var v=f+s[1]-s[0];b[0]=Math.min(v,(v+d)/2),b[1]=Math.max(v,(v+d)/2)}else{p=d;var x=h+s[1]-s[0];b[0]=Math.min(f,(x+f)/2),b[1]=Math.max(f,(x+f)/2)}var m=[Math.min(f,(p+f)/2),Math.max(f,(p+f)/2)];if(t>m[0]&&t<=m[1]||t>=b[0]&&t<=b[1]){o=a[u].index;break}}else{var y=Math.min(d,h),g=Math.max(d,h);if(t>(y+f)/2&&t<=(g+f)/2){o=a[u].index;break}}}else for(var S=0;S<l;S++)if(S===0&&t<=(r[S].coordinate+r[S+1].coordinate)/2||S>0&&S<l-1&&t>(r[S].coordinate+r[S-1].coordinate)/2&&t<=(r[S].coordinate+r[S+1].coordinate)/2||S===l-1&&t>(r[S].coordinate+r[S-1].coordinate)/2){o=r[S].index;break}return o},u1=function(t){var n,r=t,a=r.type.displayName,i=(n=t.type)!==null&&n!==void 0&&n.defaultProps?st(st({},t.type.defaultProps),t.props):t.props,o=i.stroke,l=i.fill,s;switch(a){case"Line":s=o;break;case"Area":case"Radar":s=o&&o!=="none"?o:l;break;default:s=l;break}return s},tte=function(t){var n=t.barSize,r=t.totalSize,a=t.stackGroups,i=a===void 0?{}:a;if(!i)return{};for(var o={},l=Object.keys(i),s=0,u=l.length;s<u;s++)for(var d=i[l[s]].stackGroups,f=Object.keys(d),h=0,p=f.length;h<p;h++){var b=d[f[h]],v=b.items,x=b.cateAxisId,m=v.filter(function(A){return na(A.type).indexOf("Bar")>=0});if(m&&m.length){var y=m[0].type.defaultProps,g=y!==void 0?st(st({},y),m[0].props):m[0].props,S=g.barSize,w=g[x];o[w]||(o[w]=[]);var j=ge(S)?n:S;o[w].push({item:m[0],stackList:m.slice(1),barSize:ge(j)?void 0:en(j,r,0)})}}return o},nte=function(t){var n=t.barGap,r=t.barCategoryGap,a=t.bandSize,i=t.sizeList,o=i===void 0?[]:i,l=t.maxBarSize,s=o.length;if(s<1)return null;var u=en(n,a,0,!0),d,f=[];if(o[0].barSize===+o[0].barSize){var h=!1,p=a/s,b=o.reduce(function(S,w){return S+w.barSize||0},0);b+=(s-1)*u,b>=a&&(b-=(s-1)*u,u=0),b>=a&&p>0&&(h=!0,p*=.9,b=s*p);var v=(a-b)/2>>0,x={offset:v-u,size:0};d=o.reduce(function(S,w){var j={item:w.item,position:{offset:x.offset+x.size+u,size:h?p:w.barSize}},A=[].concat(H2(S),[j]);return x=A[A.length-1].position,w.stackList&&w.stackList.length&&w.stackList.forEach(function(E){A.push({item:E,position:x})}),A},f)}else{var m=en(r,a,0,!0);a-2*m-(s-1)*u<=0&&(u=0);var y=(a-2*m-(s-1)*u)/s;y>1&&(y>>=0);var g=l===+l?Math.min(y,l):y;d=o.reduce(function(S,w,j){var A=[].concat(H2(S),[{item:w.item,position:{offset:m+(y+u)*j+(y-g)/2,size:g}}]);return w.stackList&&w.stackList.length&&w.stackList.forEach(function(E){A.push({item:E,position:A[A.length-1].position})}),A},f)}return d},rte=function(t,n,r,a){var i=r.children,o=r.width,l=r.margin,s=o-(l.left||0)-(l.right||0),u=m3({children:i,legendWidth:s});if(u){var d=a||{},f=d.width,h=d.height,p=u.align,b=u.verticalAlign,v=u.layout;if((v==="vertical"||v==="horizontal"&&b==="middle")&&p!=="center"&&V(t[p]))return st(st({},t),{},ul({},p,t[p]+(f||0)));if((v==="horizontal"||v==="vertical"&&p==="center")&&b!=="middle"&&V(t[b]))return st(st({},t),{},ul({},b,t[b]+(h||0)))}return t},ate=function(t,n,r){return ge(n)?!0:t==="horizontal"?n==="yAxis":t==="vertical"||r==="x"?n==="xAxis":r==="y"?n==="yAxis":!0},y3=function(t,n,r,a,i){var o=n.props.children,l=Wn(o,rm).filter(function(u){return ate(a,i,u.props.direction)});if(l&&l.length){var s=l.map(function(u){return u.props.dataKey});return t.reduce(function(u,d){var f=Kt(d,r);if(ge(f))return u;var h=Array.isArray(f)?[Jp(f),Zp(f)]:[f,f],p=s.reduce(function(b,v){var x=Kt(d,v,0),m=h[0]-Math.abs(Array.isArray(x)?x[0]:x),y=h[1]+Math.abs(Array.isArray(x)?x[1]:x);return[Math.min(m,b[0]),Math.max(y,b[1])]},[1/0,-1/0]);return[Math.min(p[0],u[0]),Math.max(p[1],u[1])]},[1/0,-1/0])}return null},ite=function(t,n,r,a,i){var o=n.map(function(l){return y3(t,l,r,i,a)}).filter(function(l){return!ge(l)});return o&&o.length?o.reduce(function(l,s){return[Math.min(l[0],s[0]),Math.max(l[1],s[1])]},[1/0,-1/0]):null},v3=function(t,n,r,a,i){var o=n.map(function(s){var u=s.props.dataKey;return r==="number"&&u&&y3(t,s,u,a)||Ou(t,u,r,i)});if(r==="number")return o.reduce(function(s,u){return[Math.min(s[0],u[0]),Math.max(s[1],u[1])]},[1/0,-1/0]);var l={};return o.reduce(function(s,u){for(var d=0,f=u.length;d<f;d++)l[u[d]]||(l[u[d]]=!0,s.push(u[d]));return s},[])},g3=function(t,n){return t==="horizontal"&&n==="xAxis"||t==="vertical"&&n==="yAxis"||t==="centric"&&n==="angleAxis"||t==="radial"&&n==="radiusAxis"},$i=function(t,n,r){if(!t)return null;var a=t.scale,i=t.duplicateDomain,o=t.type,l=t.range,s=t.realScaleType==="scaleBand"?a.bandwidth()/2:2,u=(n||r)&&o==="category"&&a.bandwidth?a.bandwidth()/s:0;if(u=t.axisType==="angleAxis"&&(l==null?void 0:l.length)>=2?Jt(l[0]-l[1])*2*u:u,n&&(t.ticks||t.niceTicks)){var d=(t.ticks||t.niceTicks).map(function(f){var h=i?i.indexOf(f):f;return{coordinate:a(h)+u,value:f,offset:u}});return d.filter(function(f){return!ef(f.coordinate)})}return t.isCategorical&&t.categoricalDomain?t.categoricalDomain.map(function(f,h){return{coordinate:a(f)+u,value:f,index:h,offset:u}}):a.ticks&&!r?a.ticks(t.tickCount).map(function(f){return{coordinate:a(f)+u,value:f,offset:u}}):a.domain().map(function(f,h){return{coordinate:a(f)+u,value:i?i[f]:f,index:h,offset:u}})},My=new WeakMap,Lf=function(t,n){if(typeof n!="function")return t;My.has(t)||My.set(t,new WeakMap);var r=My.get(t);if(r.has(n))return r.get(n);var a=function(){t.apply(void 0,arguments),n.apply(void 0,arguments)};return r.set(n,a),a},b3=function(t,n,r){var a=t.scale,i=t.type,o=t.layout,l=t.axisType;if(a==="auto")return o==="radial"&&l==="radiusAxis"?{scale:Ju(),realScaleType:"band"}:o==="radial"&&l==="angleAxis"?{scale:yh(),realScaleType:"linear"}:i==="category"&&n&&(n.indexOf("LineChart")>=0||n.indexOf("AreaChart")>=0||n.indexOf("ComposedChart")>=0&&!r)?{scale:ju(),realScaleType:"point"}:i==="category"?{scale:Ju(),realScaleType:"band"}:{scale:yh(),realScaleType:"linear"};if(oo(a)){var s="scale".concat(Lp(a));return{scale:(L2[s]||ju)(),realScaleType:L2[s]?s:"point"}}return se(a)?{scale:a}:{scale:ju(),realScaleType:"point"}},G2=1e-4,x3=function(t){var n=t.domain();if(!(!n||n.length<=2)){var r=n.length,a=t.range(),i=Math.min(a[0],a[1])-G2,o=Math.max(a[0],a[1])+G2,l=t(n[0]),s=t(n[r-1]);(l<i||l>o||s<i||s>o)&&t.domain([n[0],n[r-1]])}},ote=function(t,n){if(!t)return null;for(var r=0,a=t.length;r<a;r++)if(t[r].item===n)return t[r].position;return null},lte=function(t,n){if(!n||n.length!==2||!V(n[0])||!V(n[1]))return t;var r=Math.min(n[0],n[1]),a=Math.max(n[0],n[1]),i=[t[0],t[1]];return(!V(t[0])||t[0]<r)&&(i[0]=r),(!V(t[1])||t[1]>a)&&(i[1]=a),i[0]>a&&(i[0]=a),i[1]<r&&(i[1]=r),i},ste=function(t){var n=t.length;if(!(n<=0))for(var r=0,a=t[0].length;r<a;++r)for(var i=0,o=0,l=0;l<n;++l){var s=ef(t[l][r][1])?t[l][r][0]:t[l][r][1];s>=0?(t[l][r][0]=i,t[l][r][1]=i+s,i=t[l][r][1]):(t[l][r][0]=o,t[l][r][1]=o+s,o=t[l][r][1])}},ute=function(t){var n=t.length;if(!(n<=0))for(var r=0,a=t[0].length;r<a;++r)for(var i=0,o=0;o<n;++o){var l=ef(t[o][r][1])?t[o][r][0]:t[o][r][1];l>=0?(t[o][r][0]=i,t[o][r][1]=i+l,i=t[o][r][1]):(t[o][r][0]=0,t[o][r][1]=0)}},cte={sign:ste,expand:T9,none:zl,silhouette:N9,wiggle:C9,positive:ute},fte=function(t,n,r){var a=n.map(function(l){return l.props.dataKey}),i=cte[r],o=_9().keys(a).value(function(l,s){return+Kt(l,s,0)}).order(jg).offset(i);return o(t)},dte=function(t,n,r,a,i,o){if(!t)return null;var l=o?n.reverse():n,s={},u=l.reduce(function(f,h){var p,b=(p=h.type)!==null&&p!==void 0&&p.defaultProps?st(st({},h.type.defaultProps),h.props):h.props,v=b.stackId,x=b.hide;if(x)return f;var m=b[r],y=f[m]||{hasStack:!1,stackGroups:{}};if(Ot(v)){var g=y.stackGroups[v]||{numericAxisId:r,cateAxisId:a,items:[]};g.items.push(h),y.hasStack=!0,y.stackGroups[v]=g}else y.stackGroups[tf("_stackId_")]={numericAxisId:r,cateAxisId:a,items:[h]};return st(st({},f),{},ul({},m,y))},s),d={};return Object.keys(u).reduce(function(f,h){var p=u[h];if(p.hasStack){var b={};p.stackGroups=Object.keys(p.stackGroups).reduce(function(v,x){var m=p.stackGroups[x];return st(st({},v),{},ul({},x,{numericAxisId:r,cateAxisId:a,items:m.items,stackedData:fte(t,m.items,i)}))},b)}return st(st({},f),{},ul({},h,p))},d)},S3=function(t,n){var r=n.realScaleType,a=n.type,i=n.tickCount,o=n.originalDomain,l=n.allowDecimals,s=r||n.scale;if(s!=="auto"&&s!=="linear")return null;if(i&&a==="number"&&o&&(o[0]==="auto"||o[1]==="auto")){var u=t.domain();if(!u.length)return null;var d=Eee(u,i,l);return t.domain([Jp(d),Zp(d)]),{niceTicks:d}}if(i&&a==="number"){var f=t.domain(),h=_ee(f,i,l);return{niceTicks:h}}return null},K2=function(t){var n=t.axis,r=t.ticks,a=t.offset,i=t.bandSize,o=t.entry,l=t.index;if(n.type==="category")return r[l]?r[l].coordinate+a:null;var s=Kt(o,n.dataKey,n.domain[l]);return ge(s)?null:n.scale(s)-i/2+a},hte=function(t){var n=t.numericAxis,r=n.scale.domain();if(n.type==="number"){var a=Math.min(r[0],r[1]),i=Math.max(r[0],r[1]);return a<=0&&i>=0?0:i<0?i:a}return r[0]},pte=function(t,n){var r,a=(r=t.type)!==null&&r!==void 0&&r.defaultProps?st(st({},t.type.defaultProps),t.props):t.props,i=a.stackId;if(Ot(i)){var o=n[i];if(o){var l=o.items.indexOf(t);return l>=0?o.stackedData[l]:null}}return null},mte=function(t){return t.reduce(function(n,r){return[Jp(r.concat([n[0]]).filter(V)),Zp(r.concat([n[1]]).filter(V))]},[1/0,-1/0])},w3=function(t,n,r){return Object.keys(t).reduce(function(a,i){var o=t[i],l=o.stackedData,s=l.reduce(function(u,d){var f=mte(d.slice(n,r+1));return[Math.min(u[0],f[0]),Math.max(u[1],f[1])]},[1/0,-1/0]);return[Math.min(s[0],a[0]),Math.max(s[1],a[1])]},[1/0,-1/0]).map(function(a){return a===1/0||a===-1/0?0:a})},Y2=/^dataMin[\s]*-[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,V2=/^dataMax[\s]*\+[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,Jg=function(t,n,r){if(se(t))return t(n,r);if(!Array.isArray(t))return n;var a=[];if(V(t[0]))a[0]=r?t[0]:Math.min(t[0],n[0]);else if(Y2.test(t[0])){var i=+Y2.exec(t[0])[1];a[0]=n[0]-i}else se(t[0])?a[0]=t[0](n[0]):a[0]=n[0];if(V(t[1]))a[1]=r?t[1]:Math.max(t[1],n[1]);else if(V2.test(t[1])){var o=+V2.exec(t[1])[1];a[1]=n[1]+o}else se(t[1])?a[1]=t[1](n[1]):a[1]=n[1];return a},jh=function(t,n,r){if(t&&t.scale&&t.scale.bandwidth){var a=t.scale.bandwidth();if(!r||a>0)return a}if(t&&n&&n.length>=2){for(var i=Lx(n,function(f){return f.coordinate}),o=1/0,l=1,s=i.length;l<s;l++){var u=i[l],d=i[l-1];o=Math.min((u.coordinate||0)-(d.coordinate||0),o)}return o===1/0?0:o}return r?void 0:0},X2=function(t,n,r){return!t||!t.length||em(t,Rn(r,"type.defaultProps.domain"))?n:t},j3=function(t,n){var r=t.type.defaultProps?st(st({},t.type.defaultProps),t.props):t.props,a=r.dataKey,i=r.name,o=r.unit,l=r.formatter,s=r.tooltipType,u=r.chartType,d=r.hide;return st(st({},oe(t,!1)),{},{dataKey:a,unit:o,formatter:l,name:i||a,color:u1(t),value:Kt(n,a),type:s,payload:n,chartType:u,hide:d})};function sc(e){"@babel/helpers - typeof";return sc=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},sc(e)}function Q2(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function Ur(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Q2(Object(n),!0).forEach(function(r){O3(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Q2(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function O3(e,t,n){return t=yte(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function yte(e){var t=vte(e,"string");return sc(t)=="symbol"?t:t+""}function vte(e,t){if(sc(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(sc(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function gte(e,t){return wte(e)||Ste(e,t)||xte(e,t)||bte()}function bte(){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 xte(e,t){if(e){if(typeof e=="string")return W2(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 W2(e,t)}}function W2(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 Ste(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,a,i,o,l=[],s=!0,u=!1;try{if(i=(n=n.call(e)).next,t!==0)for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(d){u=!0,a=d}finally{try{if(!s&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(u)throw a}}return l}}function wte(e){if(Array.isArray(e))return e}var Oh=Math.PI/180,jte=function(t){return t*180/Math.PI},Ve=function(t,n,r,a){return{x:t+Math.cos(-Oh*a)*r,y:n+Math.sin(-Oh*a)*r}},A3=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},Ote=function(t,n,r,a,i){var o=t.width,l=t.height,s=t.startAngle,u=t.endAngle,d=en(t.cx,o,o/2),f=en(t.cy,l,l/2),h=A3(o,l,r),p=en(t.innerRadius,h,0),b=en(t.outerRadius,h,h*.8),v=Object.keys(n);return v.reduce(function(x,m){var y=n[m],g=y.domain,S=y.reversed,w;if(ge(y.range))a==="angleAxis"?w=[s,u]:a==="radiusAxis"&&(w=[p,b]),S&&(w=[w[1],w[0]]);else{w=y.range;var j=w,A=gte(j,2);s=A[0],u=A[1]}var E=b3(y,i),_=E.realScaleType,N=E.scale;N.domain(g).range(w),x3(N);var D=S3(N,Ur(Ur({},y),{},{realScaleType:_})),R=Ur(Ur(Ur({},y),D),{},{range:w,radius:b,realScaleType:_,scale:N,cx:d,cy:f,innerRadius:p,outerRadius:b,startAngle:s,endAngle:u});return Ur(Ur({},x),{},O3({},m,R))},{})},Ate=function(t,n){var r=t.x,a=t.y,i=n.x,o=n.y;return Math.sqrt(Math.pow(r-i,2)+Math.pow(a-o,2))},Ete=function(t,n){var r=t.x,a=t.y,i=n.cx,o=n.cy,l=Ate({x:r,y:a},{x:i,y:o});if(l<=0)return{radius:l};var s=(r-i)/l,u=Math.acos(s);return a>o&&(u=2*Math.PI-u),{radius:l,angle:jte(u),angleInRadian:u}},_te=function(t){var n=t.startAngle,r=t.endAngle,a=Math.floor(n/360),i=Math.floor(r/360),o=Math.min(a,i);return{startAngle:n-o*360,endAngle:r-o*360}},Tte=function(t,n){var r=n.startAngle,a=n.endAngle,i=Math.floor(r/360),o=Math.floor(a/360),l=Math.min(i,o);return t+l*360},Z2=function(t,n){var r=t.x,a=t.y,i=Ete({x:r,y:a},n),o=i.radius,l=i.angle,s=n.innerRadius,u=n.outerRadius;if(o<s||o>u)return!1;if(o===0)return!0;var d=_te(n),f=d.startAngle,h=d.endAngle,p=l,b;if(f<=h){for(;p>h;)p-=360;for(;p<f;)p+=360;b=p>=f&&p<=h}else{for(;p>f;)p-=360;for(;p<h;)p+=360;b=p>=h&&p<=f}return b?Ur(Ur({},n),{},{radius:o,angle:Tte(p,n)}):null},E3=function(t){return!O.isValidElement(t)&&!se(t)&&typeof t!="boolean"?t.className:""};function uc(e){"@babel/helpers - typeof";return uc=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},uc(e)}var Nte=["offset"];function Cte(e){return $te(e)||Pte(e)||Rte(e)||Mte()}function Mte(){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 Rte(e,t){if(e){if(typeof e=="string")return e0(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 e0(e,t)}}function Pte(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function $te(e){if(Array.isArray(e))return e0(e)}function e0(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 kte(e,t){if(e==null)return{};var n=Dte(e,t),r,a;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(a=0;a<i.length;a++)r=i[a],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Dte(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 J2(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function St(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?J2(Object(n),!0).forEach(function(r){Lte(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):J2(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Lte(e,t,n){return t=zte(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function zte(e){var t=Bte(e,"string");return uc(t)=="symbol"?t:t+""}function Bte(e,t){if(uc(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(uc(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function cc(){return cc=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},cc.apply(this,arguments)}var Ite=function(t){var n=t.value,r=t.formatter,a=ge(t.children)?n:t.children;return se(r)?r(a):a},Ute=function(t,n){var r=Jt(n-t),a=Math.min(Math.abs(n-t),360);return r*a},qte=function(t,n,r){var a=t.position,i=t.viewBox,o=t.offset,l=t.className,s=i,u=s.cx,d=s.cy,f=s.innerRadius,h=s.outerRadius,p=s.startAngle,b=s.endAngle,v=s.clockWise,x=(f+h)/2,m=Ute(p,b),y=m>=0?1:-1,g,S;a==="insideStart"?(g=p+y*o,S=v):a==="insideEnd"?(g=b-y*o,S=!v):a==="end"&&(g=b+y*o,S=v),S=m<=0?S:!S;var w=Ve(u,d,x,g),j=Ve(u,d,x,g+(S?1:-1)*359),A="M".concat(w.x,",").concat(w.y,`
    A`).concat(x,",").concat(x,",0,1,").concat(S?0:1,`,
    `).concat(j.x,",").concat(j.y),E=ge(t.id)?tf("recharts-radial-line-"):t.id;return $.createElement("text",cc({},r,{dominantBaseline:"central",className:ve("recharts-radial-bar-label",l)}),$.createElement("defs",null,$.createElement("path",{id:E,d:A})),$.createElement("textPath",{xlinkHref:"#".concat(E)},n))},Hte=function(t){var n=t.viewBox,r=t.offset,a=t.position,i=n,o=i.cx,l=i.cy,s=i.innerRadius,u=i.outerRadius,d=i.startAngle,f=i.endAngle,h=(d+f)/2;if(a==="outside"){var p=Ve(o,l,u+r,h),b=p.x,v=p.y;return{x:b,y:v,textAnchor:b>=o?"start":"end",verticalAnchor:"middle"}}if(a==="center")return{x:o,y:l,textAnchor:"middle",verticalAnchor:"middle"};if(a==="centerTop")return{x:o,y:l,textAnchor:"middle",verticalAnchor:"start"};if(a==="centerBottom")return{x:o,y:l,textAnchor:"middle",verticalAnchor:"end"};var x=(s+u)/2,m=Ve(o,l,x,h),y=m.x,g=m.y;return{x:y,y:g,textAnchor:"middle",verticalAnchor:"middle"}},Fte=function(t){var n=t.viewBox,r=t.parentViewBox,a=t.offset,i=t.position,o=n,l=o.x,s=o.y,u=o.width,d=o.height,f=d>=0?1:-1,h=f*a,p=f>0?"end":"start",b=f>0?"start":"end",v=u>=0?1:-1,x=v*a,m=v>0?"end":"start",y=v>0?"start":"end";if(i==="top"){var g={x:l+u/2,y:s-f*a,textAnchor:"middle",verticalAnchor:p};return St(St({},g),r?{height:Math.max(s-r.y,0),width:u}:{})}if(i==="bottom"){var S={x:l+u/2,y:s+d+h,textAnchor:"middle",verticalAnchor:b};return St(St({},S),r?{height:Math.max(r.y+r.height-(s+d),0),width:u}:{})}if(i==="left"){var w={x:l-x,y:s+d/2,textAnchor:m,verticalAnchor:"middle"};return St(St({},w),r?{width:Math.max(w.x-r.x,0),height:d}:{})}if(i==="right"){var j={x:l+u+x,y:s+d/2,textAnchor:y,verticalAnchor:"middle"};return St(St({},j),r?{width:Math.max(r.x+r.width-j.x,0),height:d}:{})}var A=r?{width:u,height:d}:{};return i==="insideLeft"?St({x:l+x,y:s+d/2,textAnchor:y,verticalAnchor:"middle"},A):i==="insideRight"?St({x:l+u-x,y:s+d/2,textAnchor:m,verticalAnchor:"middle"},A):i==="insideTop"?St({x:l+u/2,y:s+h,textAnchor:"middle",verticalAnchor:b},A):i==="insideBottom"?St({x:l+u/2,y:s+d-h,textAnchor:"middle",verticalAnchor:p},A):i==="insideTopLeft"?St({x:l+x,y:s+h,textAnchor:y,verticalAnchor:b},A):i==="insideTopRight"?St({x:l+u-x,y:s+h,textAnchor:m,verticalAnchor:b},A):i==="insideBottomLeft"?St({x:l+x,y:s+d-h,textAnchor:y,verticalAnchor:p},A):i==="insideBottomRight"?St({x:l+u-x,y:s+d-h,textAnchor:m,verticalAnchor:p},A):As(i)&&(V(i.x)||Mi(i.x))&&(V(i.y)||Mi(i.y))?St({x:l+en(i.x,u),y:s+en(i.y,d),textAnchor:"end",verticalAnchor:"end"},A):St({x:l+u/2,y:s+d/2,textAnchor:"middle",verticalAnchor:"middle"},A)},Gte=function(t){return"cx"in t&&V(t.cx)};function Mt(e){var t=e.offset,n=t===void 0?5:t,r=kte(e,Nte),a=St({offset:n},r),i=a.viewBox,o=a.position,l=a.value,s=a.children,u=a.content,d=a.className,f=d===void 0?"":d,h=a.textBreakAll;if(!i||ge(l)&&ge(s)&&!O.isValidElement(u)&&!se(u))return null;if(O.isValidElement(u))return O.cloneElement(u,a);var p;if(se(u)){if(p=O.createElement(u,a),O.isValidElement(p))return p}else p=Ite(a);var b=Gte(i),v=oe(a,!0);if(b&&(o==="insideStart"||o==="insideEnd"||o==="end"))return qte(a,p,v);var x=b?Hte(a):Fte(a);return $.createElement(so,cc({className:ve("recharts-label",f)},v,x,{breakAll:h}),p)}Mt.displayName="Label";var _3=function(t){var n=t.cx,r=t.cy,a=t.angle,i=t.startAngle,o=t.endAngle,l=t.r,s=t.radius,u=t.innerRadius,d=t.outerRadius,f=t.x,h=t.y,p=t.top,b=t.left,v=t.width,x=t.height,m=t.clockWise,y=t.labelViewBox;if(y)return y;if(V(v)&&V(x)){if(V(f)&&V(h))return{x:f,y:h,width:v,height:x};if(V(p)&&V(b))return{x:p,y:b,width:v,height:x}}return V(f)&&V(h)?{x:f,y:h,width:0,height:0}:V(n)&&V(r)?{cx:n,cy:r,startAngle:i||a||0,endAngle:o||a||0,innerRadius:u||0,outerRadius:d||s||l||0,clockWise:m}:t.viewBox?t.viewBox:{}},Kte=function(t,n){return t?t===!0?$.createElement(Mt,{key:"label-implicit",viewBox:n}):Ot(t)?$.createElement(Mt,{key:"label-implicit",viewBox:n,value:t}):O.isValidElement(t)?t.type===Mt?O.cloneElement(t,{key:"label-implicit",viewBox:n}):$.createElement(Mt,{key:"label-implicit",content:t,viewBox:n}):se(t)?$.createElement(Mt,{key:"label-implicit",content:t,viewBox:n}):As(t)?$.createElement(Mt,cc({viewBox:n},t,{key:"label-implicit"})):null:null},Yte=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 a=t.children,i=_3(t),o=Wn(a,Mt).map(function(s,u){return O.cloneElement(s,{viewBox:n||i,key:"label-".concat(u)})});if(!r)return o;var l=Kte(t.label,n||i);return[l].concat(Cte(o))};Mt.parseViewBox=_3;Mt.renderCallByParent=Yte;function Vte(e){var t=e==null?0:e.length;return t?e[t-1]:void 0}var Xte=Vte;const Qte=qe(Xte);function fc(e){"@babel/helpers - typeof";return fc=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},fc(e)}var Wte=["valueAccessor"],Zte=["data","dataKey","clockWise","id","textBreakAll"];function Jte(e){return rne(e)||nne(e)||tne(e)||ene()}function ene(){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 tne(e,t){if(e){if(typeof e=="string")return t0(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 t0(e,t)}}function nne(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function rne(e){if(Array.isArray(e))return t0(e)}function t0(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 Ah(){return Ah=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},Ah.apply(this,arguments)}function eO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function tO(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?eO(Object(n),!0).forEach(function(r){ane(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):eO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function ane(e,t,n){return t=ine(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ine(e){var t=one(e,"string");return fc(t)=="symbol"?t:t+""}function one(e,t){if(fc(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(fc(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function nO(e,t){if(e==null)return{};var n=lne(e,t),r,a;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(a=0;a<i.length;a++)r=i[a],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function lne(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 sne=function(t){return Array.isArray(t.value)?Qte(t.value):t.value};function ri(e){var t=e.valueAccessor,n=t===void 0?sne:t,r=nO(e,Wte),a=r.data,i=r.dataKey,o=r.clockWise,l=r.id,s=r.textBreakAll,u=nO(r,Zte);return!a||!a.length?null:$.createElement(ke,{className:"recharts-label-list"},a.map(function(d,f){var h=ge(i)?n(d,f):Kt(d&&d.payload,i),p=ge(l)?{}:{id:"".concat(l,"-").concat(f)};return $.createElement(Mt,Ah({},oe(d,!0),u,p,{parentViewBox:d.parentViewBox,value:h,textBreakAll:s,viewBox:Mt.parseViewBox(ge(o)?d:tO(tO({},d),{},{clockWise:o})),key:"label-".concat(f),index:f}))}))}ri.displayName="LabelList";function une(e,t){return e?e===!0?$.createElement(ri,{key:"labelList-implicit",data:t}):$.isValidElement(e)||se(e)?$.createElement(ri,{key:"labelList-implicit",data:t,content:e}):As(e)?$.createElement(ri,Ah({data:t},e,{key:"labelList-implicit"})):null:null}function cne(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,a=Wn(r,ri).map(function(o,l){return O.cloneElement(o,{data:t,key:"labelList-".concat(l)})});if(!n)return a;var i=une(e.label,t);return[i].concat(Jte(a))}ri.renderCallByParent=cne;function dc(e){"@babel/helpers - typeof";return dc=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},dc(e)}function n0(){return n0=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},n0.apply(this,arguments)}function rO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function aO(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?rO(Object(n),!0).forEach(function(r){fne(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):rO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function fne(e,t,n){return t=dne(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function dne(e){var t=hne(e,"string");return dc(t)=="symbol"?t:t+""}function hne(e,t){if(dc(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(dc(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var pne=function(t,n){var r=Jt(n-t),a=Math.min(Math.abs(n-t),359.999);return r*a},zf=function(t){var n=t.cx,r=t.cy,a=t.radius,i=t.angle,o=t.sign,l=t.isExternal,s=t.cornerRadius,u=t.cornerIsExternal,d=s*(l?1:-1)+a,f=Math.asin(s/d)/Oh,h=u?i:i+o*f,p=Ve(n,r,d,h),b=Ve(n,r,a,h),v=u?i-o*f:i,x=Ve(n,r,d*Math.cos(f*Oh),v);return{center:p,circleTangency:b,lineTangency:x,theta:f}},T3=function(t){var n=t.cx,r=t.cy,a=t.innerRadius,i=t.outerRadius,o=t.startAngle,l=t.endAngle,s=pne(o,l),u=o+s,d=Ve(n,r,i,o),f=Ve(n,r,i,u),h="M ".concat(d.x,",").concat(d.y,`
    A `).concat(i,",").concat(i,`,0,
    `).concat(+(Math.abs(s)>180),",").concat(+(o>u),`,
    `).concat(f.x,",").concat(f.y,`
  `);if(a>0){var p=Ve(n,r,a,o),b=Ve(n,r,a,u);h+="L ".concat(b.x,",").concat(b.y,`
            A `).concat(a,",").concat(a,`,0,
            `).concat(+(Math.abs(s)>180),",").concat(+(o<=u),`,
            `).concat(p.x,",").concat(p.y," Z")}else h+="L ".concat(n,",").concat(r," Z");return h},mne=function(t){var n=t.cx,r=t.cy,a=t.innerRadius,i=t.outerRadius,o=t.cornerRadius,l=t.forceCornerRadius,s=t.cornerIsExternal,u=t.startAngle,d=t.endAngle,f=Jt(d-u),h=zf({cx:n,cy:r,radius:i,angle:u,sign:f,cornerRadius:o,cornerIsExternal:s}),p=h.circleTangency,b=h.lineTangency,v=h.theta,x=zf({cx:n,cy:r,radius:i,angle:d,sign:-f,cornerRadius:o,cornerIsExternal:s}),m=x.circleTangency,y=x.lineTangency,g=x.theta,S=s?Math.abs(u-d):Math.abs(u-d)-v-g;if(S<0)return l?"M ".concat(b.x,",").concat(b.y,`
        a`).concat(o,",").concat(o,",0,0,1,").concat(o*2,`,0
        a`).concat(o,",").concat(o,",0,0,1,").concat(-o*2,`,0
      `):T3({cx:n,cy:r,innerRadius:a,outerRadius:i,startAngle:u,endAngle:d});var w="M ".concat(b.x,",").concat(b.y,`
    A`).concat(o,",").concat(o,",0,0,").concat(+(f<0),",").concat(p.x,",").concat(p.y,`
    A`).concat(i,",").concat(i,",0,").concat(+(S>180),",").concat(+(f<0),",").concat(m.x,",").concat(m.y,`
    A`).concat(o,",").concat(o,",0,0,").concat(+(f<0),",").concat(y.x,",").concat(y.y,`
  `);if(a>0){var j=zf({cx:n,cy:r,radius:a,angle:u,sign:f,isExternal:!0,cornerRadius:o,cornerIsExternal:s}),A=j.circleTangency,E=j.lineTangency,_=j.theta,N=zf({cx:n,cy:r,radius:a,angle:d,sign:-f,isExternal:!0,cornerRadius:o,cornerIsExternal:s}),D=N.circleTangency,R=N.lineTangency,B=N.theta,k=s?Math.abs(u-d):Math.abs(u-d)-_-B;if(k<0&&o===0)return"".concat(w,"L").concat(n,",").concat(r,"Z");w+="L".concat(R.x,",").concat(R.y,`
      A`).concat(o,",").concat(o,",0,0,").concat(+(f<0),",").concat(D.x,",").concat(D.y,`
      A`).concat(a,",").concat(a,",0,").concat(+(k>180),",").concat(+(f>0),",").concat(A.x,",").concat(A.y,`
      A`).concat(o,",").concat(o,",0,0,").concat(+(f<0),",").concat(E.x,",").concat(E.y,"Z")}else w+="L".concat(n,",").concat(r,"Z");return w},yne={cx:0,cy:0,innerRadius:0,outerRadius:0,startAngle:0,endAngle:0,cornerRadius:0,forceCornerRadius:!1,cornerIsExternal:!1},N3=function(t){var n=aO(aO({},yne),t),r=n.cx,a=n.cy,i=n.innerRadius,o=n.outerRadius,l=n.cornerRadius,s=n.forceCornerRadius,u=n.cornerIsExternal,d=n.startAngle,f=n.endAngle,h=n.className;if(o<i||d===f)return null;var p=ve("recharts-sector",h),b=o-i,v=en(l,b,0,!0),x;return v>0&&Math.abs(d-f)<360?x=mne({cx:r,cy:a,innerRadius:i,outerRadius:o,cornerRadius:Math.min(v,b/2),forceCornerRadius:s,cornerIsExternal:u,startAngle:d,endAngle:f}):x=T3({cx:r,cy:a,innerRadius:i,outerRadius:o,startAngle:d,endAngle:f}),$.createElement("path",n0({},oe(n,!0),{className:p,d:x,role:"img"}))};function hc(e){"@babel/helpers - typeof";return hc=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},hc(e)}function r0(){return r0=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},r0.apply(this,arguments)}function iO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function oO(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?iO(Object(n),!0).forEach(function(r){vne(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):iO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function vne(e,t,n){return t=gne(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function gne(e){var t=bne(e,"string");return hc(t)=="symbol"?t:t+""}function bne(e,t){if(hc(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(hc(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var lO={curveBasisClosed:y9,curveBasisOpen:v9,curveBasis:m9,curveBumpX:t9,curveBumpY:n9,curveLinearClosed:g9,curveLinear:Bp,curveMonotoneX:b9,curveMonotoneY:x9,curveNatural:S9,curveStep:w9,curveStepAfter:O9,curveStepBefore:j9},Bf=function(t){return t.x===+t.x&&t.y===+t.y},Ws=function(t){return t.x},Zs=function(t){return t.y},xne=function(t,n){if(se(t))return t;var r="curve".concat(Lp(t));return(r==="curveMonotone"||r==="curveBump")&&n?lO["".concat(r).concat(n==="vertical"?"Y":"X")]:lO[r]||Bp},Sne=function(t){var n=t.type,r=n===void 0?"linear":n,a=t.points,i=a===void 0?[]:a,o=t.baseLine,l=t.layout,s=t.connectNulls,u=s===void 0?!1:s,d=xne(r,l),f=u?i.filter(function(v){return Bf(v)}):i,h;if(Array.isArray(o)){var p=u?o.filter(function(v){return Bf(v)}):o,b=f.map(function(v,x){return oO(oO({},v),{},{base:p[x]})});return l==="vertical"?h=Nf().y(Zs).x1(Ws).x0(function(v){return v.base.x}):h=Nf().x(Ws).y1(Zs).y0(function(v){return v.base.y}),h.defined(Bf).curve(d),h(b)}return l==="vertical"&&V(o)?h=Nf().y(Zs).x1(Ws).x0(o):V(o)?h=Nf().x(Ws).y1(Zs).y0(o):h=EC().x(Ws).y(Zs),h.defined(Bf).curve(d),h(f)},a0=function(t){var n=t.className,r=t.points,a=t.path,i=t.pathRef;if((!r||!r.length)&&!a)return null;var o=r&&r.length?Sne(t):a;return O.createElement("path",r0({},oe(t,!1),Xd(t),{className:ve("recharts-curve",n),d:o,ref:i}))},C3={exports:{}},wne="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",jne=wne,One=jne;function M3(){}function R3(){}R3.resetWarningCache=M3;var Ane=function(){function e(r,a,i,o,l,s){if(s!==One){var u=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 u.name="Invariant Violation",u}}e.isRequired=e;function t(){return e}var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:R3,resetWarningCache:M3};return n.PropTypes=n,n};C3.exports=Ane();var Ene=C3.exports;const Ce=qe(Ene),{getOwnPropertyNames:_ne,getOwnPropertySymbols:Tne}=Object,{hasOwnProperty:Nne}=Object.prototype;function Ry(e,t){return function(r,a,i){return e(r,a,i)&&t(r,a,i)}}function If(e){return function(n,r,a){if(!n||!r||typeof n!="object"||typeof r!="object")return e(n,r,a);const{cache:i}=a,o=i.get(n),l=i.get(r);if(o&&l)return o===r&&l===n;i.set(n,r),i.set(r,n);const s=e(n,r,a);return i.delete(n),i.delete(r),s}}function Cne(e){return e!=null?e[Symbol.toStringTag]:void 0}function sO(e){return _ne(e).concat(Tne(e))}const Mne=Object.hasOwn||((e,t)=>Nne.call(e,t));function So(e,t){return e===t||!e&&!t&&e!==e&&t!==t}const Rne="__v",Pne="__o",$ne="_owner",{getOwnPropertyDescriptor:uO,keys:cO}=Object;function kne(e,t){return e.byteLength===t.byteLength&&Eh(new Uint8Array(e),new Uint8Array(t))}function Dne(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 Lne(e,t){return e.byteLength===t.byteLength&&Eh(new Uint8Array(e.buffer,e.byteOffset,e.byteLength),new Uint8Array(t.buffer,t.byteOffset,t.byteLength))}function zne(e,t){return So(e.getTime(),t.getTime())}function Bne(e,t){return e.name===t.name&&e.message===t.message&&e.cause===t.cause&&e.stack===t.stack}function Ine(e,t){return e===t}function fO(e,t,n){const r=e.size;if(r!==t.size)return!1;if(!r)return!0;const a=new Array(r),i=e.entries();let o,l,s=0;for(;(o=i.next())&&!o.done;){const u=t.entries();let d=!1,f=0;for(;(l=u.next())&&!l.done;){if(a[f]){f++;continue}const h=o.value,p=l.value;if(n.equals(h[0],p[0],s,f,e,t,n)&&n.equals(h[1],p[1],h[0],p[0],e,t,n)){d=a[f]=!0;break}f++}if(!d)return!1;s++}return!0}const Une=So;function qne(e,t,n){const r=cO(e);let a=r.length;if(cO(t).length!==a)return!1;for(;a-- >0;)if(!P3(e,t,n,r[a]))return!1;return!0}function Js(e,t,n){const r=sO(e);let a=r.length;if(sO(t).length!==a)return!1;let i,o,l;for(;a-- >0;)if(i=r[a],!P3(e,t,n,i)||(o=uO(e,i),l=uO(t,i),(o||l)&&(!o||!l||o.configurable!==l.configurable||o.enumerable!==l.enumerable||o.writable!==l.writable)))return!1;return!0}function Hne(e,t){return So(e.valueOf(),t.valueOf())}function Fne(e,t){return e.source===t.source&&e.flags===t.flags}function dO(e,t,n){const r=e.size;if(r!==t.size)return!1;if(!r)return!0;const a=new Array(r),i=e.values();let o,l;for(;(o=i.next())&&!o.done;){const s=t.values();let u=!1,d=0;for(;(l=s.next())&&!l.done;){if(!a[d]&&n.equals(o.value,l.value,o.value,l.value,e,t,n)){u=a[d]=!0;break}d++}if(!u)return!1}return!0}function Eh(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 Gne(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 P3(e,t,n,r){return(r===$ne||r===Pne||r===Rne)&&(e.$$typeof||t.$$typeof)?!0:Mne(t,r)&&n.equals(e[r],t[r],r,r,e,t,n)}const Kne="[object ArrayBuffer]",Yne="[object Arguments]",Vne="[object Boolean]",Xne="[object DataView]",Qne="[object Date]",Wne="[object Error]",Zne="[object Map]",Jne="[object Number]",ere="[object Object]",tre="[object RegExp]",nre="[object Set]",rre="[object String]",are={"[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},ire="[object URL]",ore=Object.prototype.toString;function lre({areArrayBuffersEqual:e,areArraysEqual:t,areDataViewsEqual:n,areDatesEqual:r,areErrorsEqual:a,areFunctionsEqual:i,areMapsEqual:o,areNumbersEqual:l,areObjectsEqual:s,arePrimitiveWrappersEqual:u,areRegExpsEqual:d,areSetsEqual:f,areTypedArraysEqual:h,areUrlsEqual:p,unknownTagComparators:b}){return function(x,m,y){if(x===m)return!0;if(x==null||m==null)return!1;const g=typeof x;if(g!==typeof m)return!1;if(g!=="object")return g==="number"?l(x,m,y):g==="function"?i(x,m,y):!1;const S=x.constructor;if(S!==m.constructor)return!1;if(S===Object)return s(x,m,y);if(Array.isArray(x))return t(x,m,y);if(S===Date)return r(x,m,y);if(S===RegExp)return d(x,m,y);if(S===Map)return o(x,m,y);if(S===Set)return f(x,m,y);const w=ore.call(x);if(w===Qne)return r(x,m,y);if(w===tre)return d(x,m,y);if(w===Zne)return o(x,m,y);if(w===nre)return f(x,m,y);if(w===ere)return typeof x.then!="function"&&typeof m.then!="function"&&s(x,m,y);if(w===ire)return p(x,m,y);if(w===Wne)return a(x,m,y);if(w===Yne)return s(x,m,y);if(are[w])return h(x,m,y);if(w===Kne)return e(x,m,y);if(w===Xne)return n(x,m,y);if(w===Vne||w===Jne||w===rre)return u(x,m,y);if(b){let j=b[w];if(!j){const A=Cne(x);A&&(j=b[A])}if(j)return j(x,m,y)}return!1}}function sre({circular:e,createCustomConfig:t,strict:n}){let r={areArrayBuffersEqual:kne,areArraysEqual:n?Js:Dne,areDataViewsEqual:Lne,areDatesEqual:zne,areErrorsEqual:Bne,areFunctionsEqual:Ine,areMapsEqual:n?Ry(fO,Js):fO,areNumbersEqual:Une,areObjectsEqual:n?Js:qne,arePrimitiveWrappersEqual:Hne,areRegExpsEqual:Fne,areSetsEqual:n?Ry(dO,Js):dO,areTypedArraysEqual:n?Ry(Eh,Js):Eh,areUrlsEqual:Gne,unknownTagComparators:void 0};if(t&&(r=Object.assign({},r,t(r))),e){const a=If(r.areArraysEqual),i=If(r.areMapsEqual),o=If(r.areObjectsEqual),l=If(r.areSetsEqual);r=Object.assign({},r,{areArraysEqual:a,areMapsEqual:i,areObjectsEqual:o,areSetsEqual:l})}return r}function ure(e){return function(t,n,r,a,i,o,l){return e(t,n,l)}}function cre({circular:e,comparator:t,createState:n,equals:r,strict:a}){if(n)return function(l,s){const{cache:u=e?new WeakMap:void 0,meta:d}=n();return t(l,s,{cache:u,equals:r,meta:d,strict:a})};if(e)return function(l,s){return t(l,s,{cache:new WeakMap,equals:r,meta:void 0,strict:a})};const i={cache:void 0,equals:r,meta:void 0,strict:a};return function(l,s){return t(l,s,i)}}const fre=pi();pi({strict:!0});pi({circular:!0});pi({circular:!0,strict:!0});pi({createInternalComparator:()=>So});pi({strict:!0,createInternalComparator:()=>So});pi({circular:!0,createInternalComparator:()=>So});pi({circular:!0,createInternalComparator:()=>So,strict:!0});function pi(e={}){const{circular:t=!1,createInternalComparator:n,createState:r,strict:a=!1}=e,i=sre(e),o=lre(i),l=n?n(o):ure(o);return cre({circular:t,comparator:o,createState:r,equals:l,strict:a})}function dre(e){typeof requestAnimationFrame<"u"&&requestAnimationFrame(e)}function hO(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n=-1,r=function a(i){n<0&&(n=i),i-n>t?(e(i),n=-1):dre(a)};requestAnimationFrame(r)}function i0(e){"@babel/helpers - typeof";return i0=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},i0(e)}function hre(e){return vre(e)||yre(e)||mre(e)||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 mre(e,t){if(e){if(typeof e=="string")return pO(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 pO(e,t)}}function pO(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 yre(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function vre(e){if(Array.isArray(e))return e}function gre(){var e={},t=function(){return null},n=!1,r=function a(i){if(!n){if(Array.isArray(i)){if(!i.length)return;var o=i,l=hre(o),s=l[0],u=l.slice(1);if(typeof s=="number"){hO(a.bind(null,u),s);return}a(s),hO(a.bind(null,u));return}i0(i)==="object"&&(e=i,t(e)),typeof i=="function"&&i()}};return{stop:function(){n=!0},start:function(i){n=!1,r(i)},subscribe:function(i){return t=i,function(){t=function(){return null}}}}}function pc(e){"@babel/helpers - typeof";return pc=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},pc(e)}function mO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function yO(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?mO(Object(n),!0).forEach(function(r){$3(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):mO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function $3(e,t,n){return t=bre(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function bre(e){var t=xre(e,"string");return pc(t)==="symbol"?t:String(t)}function xre(e,t){if(pc(e)!=="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(pc(r)!=="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Sre=function(t,n){return[Object.keys(t),Object.keys(n)].reduce(function(r,a){return r.filter(function(i){return a.includes(i)})})},wre=function(t){return t},jre=function(t){return t.replace(/([A-Z])/g,function(n){return"-".concat(n.toLowerCase())})},Au=function(t,n){return Object.keys(n).reduce(function(r,a){return yO(yO({},r),{},$3({},a,t(a,n[a])))},{})},vO=function(t,n,r){return t.map(function(a){return"".concat(jre(a)," ").concat(n,"ms ").concat(r)}).join(",")};function Ore(e,t){return _re(e)||Ere(e,t)||k3(e,t)||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 Ere(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,a,i,o,l=[],s=!0,u=!1;try{if(i=(n=n.call(e)).next,t!==0)for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(d){u=!0,a=d}finally{try{if(!s&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(u)throw a}}return l}}function _re(e){if(Array.isArray(e))return e}function Tre(e){return Mre(e)||Cre(e)||k3(e)||Nre()}function Nre(){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 k3(e,t){if(e){if(typeof e=="string")return o0(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 o0(e,t)}}function Cre(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Mre(e){if(Array.isArray(e))return o0(e)}function o0(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 _h=1e-4,D3=function(t,n){return[0,3*t,3*n-6*t,3*t-3*n+1]},L3=function(t,n){return t.map(function(r,a){return r*Math.pow(n,a)}).reduce(function(r,a){return r+a})},gO=function(t,n){return function(r){var a=D3(t,n);return L3(a,r)}},Rre=function(t,n){return function(r){var a=D3(t,n),i=[].concat(Tre(a.map(function(o,l){return o*l}).slice(1)),[0]);return L3(i,r)}},bO=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var a=n[0],i=n[1],o=n[2],l=n[3];if(n.length===1)switch(n[0]){case"linear":a=0,i=0,o=1,l=1;break;case"ease":a=.25,i=.1,o=.25,l=1;break;case"ease-in":a=.42,i=0,o=1,l=1;break;case"ease-out":a=.42,i=0,o=.58,l=1;break;case"ease-in-out":a=0,i=0,o=.58,l=1;break;default:{var s=n[0].split("(");if(s[0]==="cubic-bezier"&&s[1].split(")")[0].split(",").length===4){var u=s[1].split(")")[0].split(",").map(function(x){return parseFloat(x)}),d=Ore(u,4);a=d[0],i=d[1],o=d[2],l=d[3]}}}var f=gO(a,o),h=gO(i,l),p=Rre(a,o),b=function(m){return m>1?1:m<0?0:m},v=function(m){for(var y=m>1?1:m,g=y,S=0;S<8;++S){var w=f(g)-y,j=p(g);if(Math.abs(w-y)<_h||j<_h)return h(g);g=b(g-w/j)}return h(g)};return v.isStepper=!1,v},Pre=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=t.stiff,r=n===void 0?100:n,a=t.damping,i=a===void 0?8:a,o=t.dt,l=o===void 0?17:o,s=function(d,f,h){var p=-(d-f)*r,b=h*i,v=h+(p-b)*l/1e3,x=h*l/1e3+d;return Math.abs(x-f)<_h&&Math.abs(v)<_h?[f,0]:[x,v]};return s.isStepper=!0,s.dt=l,s},$re=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var a=n[0];if(typeof a=="string")switch(a){case"ease":case"ease-in-out":case"ease-out":case"ease-in":case"linear":return bO(a);case"spring":return Pre();default:if(a.split("(")[0]==="cubic-bezier")return bO(a)}return typeof a=="function"?a:null};function mc(e){"@babel/helpers - typeof";return mc=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},mc(e)}function xO(e){return Lre(e)||Dre(e)||z3(e)||kre()}function kre(){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 Dre(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Lre(e){if(Array.isArray(e))return s0(e)}function SO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function Dt(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?SO(Object(n),!0).forEach(function(r){l0(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):SO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function l0(e,t,n){return t=zre(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function zre(e){var t=Bre(e,"string");return mc(t)==="symbol"?t:String(t)}function Bre(e,t){if(mc(e)!=="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(mc(r)!=="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Ire(e,t){return Hre(e)||qre(e,t)||z3(e,t)||Ure()}function Ure(){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 z3(e,t){if(e){if(typeof e=="string")return s0(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 s0(e,t)}}function s0(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 qre(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,a,i,o,l=[],s=!0,u=!1;try{if(i=(n=n.call(e)).next,t!==0)for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(d){u=!0,a=d}finally{try{if(!s&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(u)throw a}}return l}}function Hre(e){if(Array.isArray(e))return e}var Th=function(t,n,r){return t+(n-t)*r},u0=function(t){var n=t.from,r=t.to;return n!==r},Fre=function e(t,n,r){var a=Au(function(i,o){if(u0(o)){var l=t(o.from,o.to,o.velocity),s=Ire(l,2),u=s[0],d=s[1];return Dt(Dt({},o),{},{from:u,velocity:d})}return o},n);return r<1?Au(function(i,o){return u0(o)?Dt(Dt({},o),{},{velocity:Th(o.velocity,a[i].velocity,r),from:Th(o.from,a[i].from,r)}):o},n):e(t,a,r-1)};const Gre=function(e,t,n,r,a){var i=Sre(e,t),o=i.reduce(function(x,m){return Dt(Dt({},x),{},l0({},m,[e[m],t[m]]))},{}),l=i.reduce(function(x,m){return Dt(Dt({},x),{},l0({},m,{from:e[m],velocity:0,to:t[m]}))},{}),s=-1,u,d,f=function(){return null},h=function(){return Au(function(m,y){return y.from},l)},p=function(){return!Object.values(l).filter(u0).length},b=function(m){u||(u=m);var y=m-u,g=y/n.dt;l=Fre(n,l,g),a(Dt(Dt(Dt({},e),t),h())),u=m,p()||(s=requestAnimationFrame(f))},v=function(m){d||(d=m);var y=(m-d)/r,g=Au(function(w,j){return Th.apply(void 0,xO(j).concat([n(y)]))},o);if(a(Dt(Dt(Dt({},e),t),g)),y<1)s=requestAnimationFrame(f);else{var S=Au(function(w,j){return Th.apply(void 0,xO(j).concat([n(1)]))},o);a(Dt(Dt(Dt({},e),t),S))}};return f=n.isStepper?b:v,function(){return requestAnimationFrame(f),function(){cancelAnimationFrame(s)}}};function Yl(e){"@babel/helpers - typeof";return Yl=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},Yl(e)}var Kre=["children","begin","duration","attributeName","easing","isActive","steps","from","to","canBegin","onAnimationEnd","shouldReAnimate","onAnimationReStart"];function Yre(e,t){if(e==null)return{};var n=Vre(e,t),r,a;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(a=0;a<i.length;a++)r=i[a],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Vre(e,t){if(e==null)return{};var n={},r=Object.keys(e),a,i;for(i=0;i<r.length;i++)a=r[i],!(t.indexOf(a)>=0)&&(n[a]=e[a]);return n}function Py(e){return Zre(e)||Wre(e)||Qre(e)||Xre()}function Xre(){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 c0(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 c0(e,t)}}function Wre(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Zre(e){if(Array.isArray(e))return c0(e)}function c0(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 wO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function ir(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?wO(Object(n),!0).forEach(function(r){lu(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):wO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function lu(e,t,n){return t=B3(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Jre(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function eae(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,B3(r.key),r)}}function tae(e,t,n){return t&&eae(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function B3(e){var t=nae(e,"string");return Yl(t)==="symbol"?t:String(t)}function nae(e,t){if(Yl(e)!=="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Yl(r)!=="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function rae(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&&f0(e,t)}function f0(e,t){return f0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,a){return r.__proto__=a,r},f0(e,t)}function aae(e){var t=iae();return function(){var r=Nh(e),a;if(t){var i=Nh(this).constructor;a=Reflect.construct(r,arguments,i)}else a=r.apply(this,arguments);return d0(this,a)}}function d0(e,t){if(t&&(Yl(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return h0(e)}function h0(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function iae(){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 Nh(e){return Nh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Nh(e)}var ma=function(e){rae(n,e);var t=aae(n);function n(r,a){var i;Jre(this,n),i=t.call(this,r,a);var o=i.props,l=o.isActive,s=o.attributeName,u=o.from,d=o.to,f=o.steps,h=o.children,p=o.duration;if(i.handleStyleChange=i.handleStyleChange.bind(h0(i)),i.changeStyle=i.changeStyle.bind(h0(i)),!l||p<=0)return i.state={style:{}},typeof h=="function"&&(i.state={style:d}),d0(i);if(f&&f.length)i.state={style:f[0].style};else if(u){if(typeof h=="function")return i.state={style:u},d0(i);i.state={style:s?lu({},s,u):u}}else i.state={style:{}};return i}return tae(n,[{key:"componentDidMount",value:function(){var a=this.props,i=a.isActive,o=a.canBegin;this.mounted=!0,!(!i||!o)&&this.runAnimation(this.props)}},{key:"componentDidUpdate",value:function(a){var i=this.props,o=i.isActive,l=i.canBegin,s=i.attributeName,u=i.shouldReAnimate,d=i.to,f=i.from,h=this.state.style;if(l){if(!o){var p={style:s?lu({},s,d):d};this.state&&h&&(s&&h[s]!==d||!s&&h!==d)&&this.setState(p);return}if(!(fre(a.to,d)&&a.canBegin&&a.isActive)){var b=!a.canBegin||!a.isActive;this.manager&&this.manager.stop(),this.stopJSAnimation&&this.stopJSAnimation();var v=b||u?f:a.to;if(this.state&&h){var x={style:s?lu({},s,v):v};(s&&h[s]!==v||!s&&h!==v)&&this.setState(x)}this.runAnimation(ir(ir({},this.props),{},{from:v,begin:0}))}}}},{key:"componentWillUnmount",value:function(){this.mounted=!1;var a=this.props.onAnimationEnd;this.unSubscribe&&this.unSubscribe(),this.manager&&(this.manager.stop(),this.manager=null),this.stopJSAnimation&&this.stopJSAnimation(),a&&a()}},{key:"handleStyleChange",value:function(a){this.changeStyle(a)}},{key:"changeStyle",value:function(a){this.mounted&&this.setState({style:a})}},{key:"runJSAnimation",value:function(a){var i=this,o=a.from,l=a.to,s=a.duration,u=a.easing,d=a.begin,f=a.onAnimationEnd,h=a.onAnimationStart,p=Gre(o,l,$re(u),s,this.changeStyle),b=function(){i.stopJSAnimation=p()};this.manager.start([h,d,b,s,f])}},{key:"runStepAnimation",value:function(a){var i=this,o=a.steps,l=a.begin,s=a.onAnimationStart,u=o[0],d=u.style,f=u.duration,h=f===void 0?0:f,p=function(v,x,m){if(m===0)return v;var y=x.duration,g=x.easing,S=g===void 0?"ease":g,w=x.style,j=x.properties,A=x.onAnimationEnd,E=m>0?o[m-1]:x,_=j||Object.keys(w);if(typeof S=="function"||S==="spring")return[].concat(Py(v),[i.runJSAnimation.bind(i,{from:E.style,to:w,duration:y,easing:S}),y]);var N=vO(_,y,S),D=ir(ir(ir({},E.style),w),{},{transition:N});return[].concat(Py(v),[D,y,A]).filter(wre)};return this.manager.start([s].concat(Py(o.reduce(p,[d,Math.max(h,l)])),[a.onAnimationEnd]))}},{key:"runAnimation",value:function(a){this.manager||(this.manager=gre());var i=a.begin,o=a.duration,l=a.attributeName,s=a.to,u=a.easing,d=a.onAnimationStart,f=a.onAnimationEnd,h=a.steps,p=a.children,b=this.manager;if(this.unSubscribe=b.subscribe(this.handleStyleChange),typeof u=="function"||typeof p=="function"||u==="spring"){this.runJSAnimation(a);return}if(h.length>1){this.runStepAnimation(a);return}var v=l?lu({},l,s):s,x=vO(Object.keys(v),o,u);b.start([d,i,ir(ir({},v),{},{transition:x}),o,f])}},{key:"render",value:function(){var a=this.props,i=a.children;a.begin;var o=a.duration;a.attributeName,a.easing;var l=a.isActive;a.steps,a.from,a.to,a.canBegin,a.onAnimationEnd,a.shouldReAnimate,a.onAnimationReStart;var s=Yre(a,Kre),u=O.Children.count(i),d=this.state.style;if(typeof i=="function")return i(d);if(!l||u===0||o<=0)return i;var f=function(p){var b=p.props,v=b.style,x=v===void 0?{}:v,m=b.className,y=O.cloneElement(p,ir(ir({},s),{},{style:ir(ir({},x),d),className:m}));return y};return u===1?f(O.Children.only(i)):$.createElement("div",null,O.Children.map(i,function(h){return f(h)}))}}]),n}(O.PureComponent);ma.displayName="Animate";ma.defaultProps={begin:0,duration:1e3,from:"",to:"",attributeName:"",easing:"ease",isActive:!0,canBegin:!0,steps:[],onAnimationEnd:function(){},onAnimationStart:function(){}};ma.propTypes={from:Ce.oneOfType([Ce.object,Ce.string]),to:Ce.oneOfType([Ce.object,Ce.string]),attributeName:Ce.string,duration:Ce.number,begin:Ce.number,easing:Ce.oneOfType([Ce.string,Ce.func]),steps:Ce.arrayOf(Ce.shape({duration:Ce.number.isRequired,style:Ce.object.isRequired,easing:Ce.oneOfType([Ce.oneOf(["ease","ease-in","ease-out","ease-in-out","linear"]),Ce.func]),properties:Ce.arrayOf("string"),onAnimationEnd:Ce.func})),children:Ce.oneOfType([Ce.node,Ce.func]),isActive:Ce.bool,canBegin:Ce.bool,onAnimationEnd:Ce.func,shouldReAnimate:Ce.bool,onAnimationStart:Ce.func,onAnimationReStart:Ce.func};function yc(e){"@babel/helpers - typeof";return yc=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},yc(e)}function Ch(){return Ch=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},Ch.apply(this,arguments)}function oae(e,t){return cae(e)||uae(e,t)||sae(e,t)||lae()}function lae(){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 sae(e,t){if(e){if(typeof e=="string")return jO(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 jO(e,t)}}function jO(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 uae(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,a,i,o,l=[],s=!0,u=!1;try{if(i=(n=n.call(e)).next,t!==0)for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(d){u=!0,a=d}finally{try{if(!s&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(u)throw a}}return l}}function cae(e){if(Array.isArray(e))return e}function OO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function AO(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?OO(Object(n),!0).forEach(function(r){fae(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):OO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function fae(e,t,n){return t=dae(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function dae(e){var t=hae(e,"string");return yc(t)=="symbol"?t:t+""}function hae(e,t){if(yc(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(yc(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var EO=function(t,n,r,a,i){var o=Math.min(Math.abs(r)/2,Math.abs(a)/2),l=a>=0?1:-1,s=r>=0?1:-1,u=a>=0&&r>=0||a<0&&r<0?1:0,d;if(o>0&&i instanceof Array){for(var f=[0,0,0,0],h=0,p=4;h<p;h++)f[h]=i[h]>o?o:i[h];d="M".concat(t,",").concat(n+l*f[0]),f[0]>0&&(d+="A ".concat(f[0],",").concat(f[0],",0,0,").concat(u,",").concat(t+s*f[0],",").concat(n)),d+="L ".concat(t+r-s*f[1],",").concat(n),f[1]>0&&(d+="A ".concat(f[1],",").concat(f[1],",0,0,").concat(u,`,
        `).concat(t+r,",").concat(n+l*f[1])),d+="L ".concat(t+r,",").concat(n+a-l*f[2]),f[2]>0&&(d+="A ".concat(f[2],",").concat(f[2],",0,0,").concat(u,`,
        `).concat(t+r-s*f[2],",").concat(n+a)),d+="L ".concat(t+s*f[3],",").concat(n+a),f[3]>0&&(d+="A ".concat(f[3],",").concat(f[3],",0,0,").concat(u,`,
        `).concat(t,",").concat(n+a-l*f[3])),d+="Z"}else if(o>0&&i===+i&&i>0){var b=Math.min(o,i);d="M ".concat(t,",").concat(n+l*b,`
            A `).concat(b,",").concat(b,",0,0,").concat(u,",").concat(t+s*b,",").concat(n,`
            L `).concat(t+r-s*b,",").concat(n,`
            A `).concat(b,",").concat(b,",0,0,").concat(u,",").concat(t+r,",").concat(n+l*b,`
            L `).concat(t+r,",").concat(n+a-l*b,`
            A `).concat(b,",").concat(b,",0,0,").concat(u,",").concat(t+r-s*b,",").concat(n+a,`
            L `).concat(t+s*b,",").concat(n+a,`
            A `).concat(b,",").concat(b,",0,0,").concat(u,",").concat(t,",").concat(n+a-l*b," Z")}else d="M ".concat(t,",").concat(n," h ").concat(r," v ").concat(a," h ").concat(-r," Z");return d},pae=function(t,n){if(!t||!n)return!1;var r=t.x,a=t.y,i=n.x,o=n.y,l=n.width,s=n.height;if(Math.abs(l)>0&&Math.abs(s)>0){var u=Math.min(i,i+l),d=Math.max(i,i+l),f=Math.min(o,o+s),h=Math.max(o,o+s);return r>=u&&r<=d&&a>=f&&a<=h}return!1},mae={x:0,y:0,width:0,height:0,radius:0,isAnimationActive:!1,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},c1=function(t){var n=AO(AO({},mae),t),r=O.useRef(),a=O.useState(-1),i=oae(a,2),o=i[0],l=i[1];O.useEffect(function(){if(r.current&&r.current.getTotalLength)try{var S=r.current.getTotalLength();S&&l(S)}catch{}},[]);var s=n.x,u=n.y,d=n.width,f=n.height,h=n.radius,p=n.className,b=n.animationEasing,v=n.animationDuration,x=n.animationBegin,m=n.isAnimationActive,y=n.isUpdateAnimationActive;if(s!==+s||u!==+u||d!==+d||f!==+f||d===0||f===0)return null;var g=ve("recharts-rectangle",p);return y?$.createElement(ma,{canBegin:o>0,from:{width:d,height:f,x:s,y:u},to:{width:d,height:f,x:s,y:u},duration:v,animationEasing:b,isActive:y},function(S){var w=S.width,j=S.height,A=S.x,E=S.y;return $.createElement(ma,{canBegin:o>0,from:"0px ".concat(o===-1?1:o,"px"),to:"".concat(o,"px 0px"),attributeName:"strokeDasharray",begin:x,duration:v,isActive:m,easing:b},$.createElement("path",Ch({},oe(n,!0),{className:g,d:EO(A,E,w,j,h),ref:r})))}):$.createElement("path",Ch({},oe(n,!0),{className:g,d:EO(s,u,d,f,h)}))},yae=["points","className","baseLinePoints","connectNulls"];function Vo(){return Vo=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},Vo.apply(this,arguments)}function vae(e,t){if(e==null)return{};var n=gae(e,t),r,a;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(a=0;a<i.length;a++)r=i[a],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function gae(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 _O(e){return wae(e)||Sae(e)||xae(e)||bae()}function bae(){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 xae(e,t){if(e){if(typeof e=="string")return p0(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 p0(e,t)}}function Sae(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function wae(e){if(Array.isArray(e))return p0(e)}function p0(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 TO=function(t){return t&&t.x===+t.x&&t.y===+t.y},jae=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],n=[[]];return t.forEach(function(r){TO(r)?n[n.length-1].push(r):n[n.length-1].length>0&&n.push([])}),TO(t[0])&&n[n.length-1].push(t[0]),n[n.length-1].length<=0&&(n=n.slice(0,-1)),n},Eu=function(t,n){var r=jae(t);n&&(r=[r.reduce(function(i,o){return[].concat(_O(i),_O(o))},[])]);var a=r.map(function(i){return i.reduce(function(o,l,s){return"".concat(o).concat(s===0?"M":"L").concat(l.x,",").concat(l.y)},"")}).join("");return r.length===1?"".concat(a,"Z"):a},Oae=function(t,n,r){var a=Eu(t,r);return"".concat(a.slice(-1)==="Z"?a.slice(0,-1):a,"L").concat(Eu(n.reverse(),r).slice(1))},Aae=function(t){var n=t.points,r=t.className,a=t.baseLinePoints,i=t.connectNulls,o=vae(t,yae);if(!n||!n.length)return null;var l=ve("recharts-polygon",r);if(a&&a.length){var s=o.stroke&&o.stroke!=="none",u=Oae(n,a,i);return $.createElement("g",{className:l},$.createElement("path",Vo({},oe(o,!0),{fill:u.slice(-1)==="Z"?o.fill:"none",stroke:"none",d:u})),s?$.createElement("path",Vo({},oe(o,!0),{fill:"none",d:Eu(n,i)})):null,s?$.createElement("path",Vo({},oe(o,!0),{fill:"none",d:Eu(a,i)})):null)}var d=Eu(n,i);return $.createElement("path",Vo({},oe(o,!0),{fill:d.slice(-1)==="Z"?o.fill:"none",className:l,d}))};function m0(){return m0=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},m0.apply(this,arguments)}var f1=function(t){var n=t.cx,r=t.cy,a=t.r,i=t.className,o=ve("recharts-dot",i);return n===+n&&r===+r&&a===+a?O.createElement("circle",m0({},oe(t,!1),Xd(t),{className:o,cx:n,cy:r,r:a})):null};function vc(e){"@babel/helpers - typeof";return vc=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},vc(e)}var Eae=["x","y","top","left","width","height","className"];function y0(){return y0=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},y0.apply(this,arguments)}function NO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function _ae(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?NO(Object(n),!0).forEach(function(r){Tae(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):NO(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=Cae(e,"string");return vc(t)=="symbol"?t:t+""}function Cae(e,t){if(vc(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(vc(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Mae(e,t){if(e==null)return{};var n=Rae(e,t),r,a;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(a=0;a<i.length;a++)r=i[a],!(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}var Pae=function(t,n,r,a,i,o){return"M".concat(t,",").concat(i,"v").concat(a,"M").concat(o,",").concat(n,"h").concat(r)},$ae=function(t){var n=t.x,r=n===void 0?0:n,a=t.y,i=a===void 0?0:a,o=t.top,l=o===void 0?0:o,s=t.left,u=s===void 0?0:s,d=t.width,f=d===void 0?0:d,h=t.height,p=h===void 0?0:h,b=t.className,v=Mae(t,Eae),x=_ae({x:r,y:i,top:l,left:u,width:f,height:p},v);return!V(r)||!V(i)||!V(f)||!V(p)||!V(l)||!V(u)?null:$.createElement("path",y0({},oe(x,!0),{className:ve("recharts-cross",b),d:Pae(r,i,f,p,l,u)}))},kae=Wp,Dae=ZM,Lae=fi;function zae(e,t){return e&&e.length?kae(e,Lae(t),Dae):void 0}var Bae=zae;const Iae=qe(Bae);var Uae=Wp,qae=fi,Hae=JM;function Fae(e,t){return e&&e.length?Uae(e,qae(t),Hae):void 0}var Gae=Fae;const Kae=qe(Gae);var Yae=["cx","cy","angle","ticks","axisLine"],Vae=["ticks","tick","angle","tickFormatter","stroke"];function Vl(e){"@babel/helpers - typeof";return Vl=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},Vl(e)}function _u(){return _u=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},_u.apply(this,arguments)}function CO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function bi(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?CO(Object(n),!0).forEach(function(r){am(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):CO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function MO(e,t){if(e==null)return{};var n=Xae(e,t),r,a;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(a=0;a<i.length;a++)r=i[a],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Xae(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 Qae(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function RO(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,U3(r.key),r)}}function Wae(e,t,n){return t&&RO(e.prototype,t),n&&RO(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Zae(e,t,n){return t=Mh(t),Jae(e,I3()?Reflect.construct(t,n||[],Mh(e).constructor):t.apply(e,n))}function Jae(e,t){if(t&&(Vl(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return eie(e)}function eie(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function I3(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(I3=function(){return!!e})()}function Mh(e){return Mh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Mh(e)}function tie(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&&v0(e,t)}function v0(e,t){return v0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,a){return r.__proto__=a,r},v0(e,t)}function am(e,t,n){return t=U3(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function U3(e){var t=nie(e,"string");return Vl(t)=="symbol"?t:t+""}function nie(e,t){if(Vl(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Vl(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var im=function(e){function t(){return Qae(this,t),Zae(this,t,arguments)}return tie(t,e),Wae(t,[{key:"getTickValueCoord",value:function(r){var a=r.coordinate,i=this.props,o=i.angle,l=i.cx,s=i.cy;return Ve(l,s,a,o)}},{key:"getTickTextAnchor",value:function(){var r=this.props.orientation,a;switch(r){case"left":a="end";break;case"right":a="start";break;default:a="middle";break}return a}},{key:"getViewBox",value:function(){var r=this.props,a=r.cx,i=r.cy,o=r.angle,l=r.ticks,s=Iae(l,function(d){return d.coordinate||0}),u=Kae(l,function(d){return d.coordinate||0});return{cx:a,cy:i,startAngle:o,endAngle:o,innerRadius:u.coordinate||0,outerRadius:s.coordinate||0}}},{key:"renderAxisLine",value:function(){var r=this.props,a=r.cx,i=r.cy,o=r.angle,l=r.ticks,s=r.axisLine,u=MO(r,Yae),d=l.reduce(function(b,v){return[Math.min(b[0],v.coordinate),Math.max(b[1],v.coordinate)]},[1/0,-1/0]),f=Ve(a,i,d[0],o),h=Ve(a,i,d[1],o),p=bi(bi(bi({},oe(u,!1)),{},{fill:"none"},oe(s,!1)),{},{x1:f.x,y1:f.y,x2:h.x,y2:h.y});return $.createElement("line",_u({className:"recharts-polar-radius-axis-line"},p))}},{key:"renderTicks",value:function(){var r=this,a=this.props,i=a.ticks,o=a.tick,l=a.angle,s=a.tickFormatter,u=a.stroke,d=MO(a,Vae),f=this.getTickTextAnchor(),h=oe(d,!1),p=oe(o,!1),b=i.map(function(v,x){var m=r.getTickValueCoord(v),y=bi(bi(bi(bi({textAnchor:f,transform:"rotate(".concat(90-l,", ").concat(m.x,", ").concat(m.y,")")},h),{},{stroke:"none",fill:u},p),{},{index:x},m),{},{payload:v});return $.createElement(ke,_u({className:ve("recharts-polar-radius-axis-tick",E3(o)),key:"tick-".concat(v.coordinate)},lo(r.props,v,x)),t.renderTickItem(o,y,s?s(v.value,x):v.value))});return $.createElement(ke,{className:"recharts-polar-radius-axis-ticks"},b)}},{key:"render",value:function(){var r=this.props,a=r.ticks,i=r.axisLine,o=r.tick;return!a||!a.length?null:$.createElement(ke,{className:ve("recharts-polar-radius-axis",this.props.className)},i&&this.renderAxisLine(),o&&this.renderTicks(),Mt.renderCallByParent(this.props,this.getViewBox()))}}],[{key:"renderTickItem",value:function(r,a,i){var o;return $.isValidElement(r)?o=$.cloneElement(r,a):se(r)?o=r(a):o=$.createElement(so,_u({},a,{className:"recharts-polar-radius-axis-tick-value"}),i),o}}])}(O.PureComponent);am(im,"displayName","PolarRadiusAxis");am(im,"axisType","radiusAxis");am(im,"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 Xl(e){"@babel/helpers - typeof";return Xl=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},Xl(e)}function Ti(){return Ti=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},Ti.apply(this,arguments)}function PO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function xi(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?PO(Object(n),!0).forEach(function(r){om(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):PO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function rie(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function $O(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,H3(r.key),r)}}function aie(e,t,n){return t&&$O(e.prototype,t),n&&$O(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function iie(e,t,n){return t=Rh(t),oie(e,q3()?Reflect.construct(t,n||[],Rh(e).constructor):t.apply(e,n))}function oie(e,t){if(t&&(Xl(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return lie(e)}function lie(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function q3(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(q3=function(){return!!e})()}function Rh(e){return Rh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Rh(e)}function sie(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&&g0(e,t)}function g0(e,t){return g0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,a){return r.__proto__=a,r},g0(e,t)}function om(e,t,n){return t=H3(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function H3(e){var t=uie(e,"string");return Xl(t)=="symbol"?t:t+""}function uie(e,t){if(Xl(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Xl(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var cie=Math.PI/180,kO=1e-5,lm=function(e){function t(){return rie(this,t),iie(this,t,arguments)}return sie(t,e),aie(t,[{key:"getTickLineCoord",value:function(r){var a=this.props,i=a.cx,o=a.cy,l=a.radius,s=a.orientation,u=a.tickSize,d=u||8,f=Ve(i,o,l,r.coordinate),h=Ve(i,o,l+(s==="inner"?-1:1)*d,r.coordinate);return{x1:f.x,y1:f.y,x2:h.x,y2:h.y}}},{key:"getTickTextAnchor",value:function(r){var a=this.props.orientation,i=Math.cos(-r.coordinate*cie),o;return i>kO?o=a==="outer"?"start":"end":i<-kO?o=a==="outer"?"end":"start":o="middle",o}},{key:"renderAxisLine",value:function(){var r=this.props,a=r.cx,i=r.cy,o=r.radius,l=r.axisLine,s=r.axisLineType,u=xi(xi({},oe(this.props,!1)),{},{fill:"none"},oe(l,!1));if(s==="circle")return $.createElement(f1,Ti({className:"recharts-polar-angle-axis-line"},u,{cx:a,cy:i,r:o}));var d=this.props.ticks,f=d.map(function(h){return Ve(a,i,o,h.coordinate)});return $.createElement(Aae,Ti({className:"recharts-polar-angle-axis-line"},u,{points:f}))}},{key:"renderTicks",value:function(){var r=this,a=this.props,i=a.ticks,o=a.tick,l=a.tickLine,s=a.tickFormatter,u=a.stroke,d=oe(this.props,!1),f=oe(o,!1),h=xi(xi({},d),{},{fill:"none"},oe(l,!1)),p=i.map(function(b,v){var x=r.getTickLineCoord(b),m=r.getTickTextAnchor(b),y=xi(xi(xi({textAnchor:m},d),{},{stroke:"none",fill:u},f),{},{index:v,payload:b,x:x.x2,y:x.y2});return $.createElement(ke,Ti({className:ve("recharts-polar-angle-axis-tick",E3(o)),key:"tick-".concat(b.coordinate)},lo(r.props,b,v)),l&&$.createElement("line",Ti({className:"recharts-polar-angle-axis-tick-line"},h,x)),o&&t.renderTickItem(o,y,s?s(b.value,v):b.value))});return $.createElement(ke,{className:"recharts-polar-angle-axis-ticks"},p)}},{key:"render",value:function(){var r=this.props,a=r.ticks,i=r.radius,o=r.axisLine;return i<=0||!a||!a.length?null:$.createElement(ke,{className:ve("recharts-polar-angle-axis",this.props.className)},o&&this.renderAxisLine(),this.renderTicks())}}],[{key:"renderTickItem",value:function(r,a,i){var o;return $.isValidElement(r)?o=$.cloneElement(r,a):se(r)?o=r(a):o=$.createElement(so,Ti({},a,{className:"recharts-polar-angle-axis-tick-value"}),i),o}}])}(O.PureComponent);om(lm,"displayName","PolarAngleAxis");om(lm,"axisType","angleAxis");om(lm,"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 fie=QC,die=fie(Object.getPrototypeOf,Object),hie=die,pie=va,mie=hie,yie=ga,vie="[object Object]",gie=Function.prototype,bie=Object.prototype,F3=gie.toString,xie=bie.hasOwnProperty,Sie=F3.call(Object);function wie(e){if(!yie(e)||pie(e)!=vie)return!1;var t=mie(e);if(t===null)return!0;var n=xie.call(t,"constructor")&&t.constructor;return typeof n=="function"&&n instanceof n&&F3.call(n)==Sie}var jie=wie;const Oie=qe(jie);var Aie=va,Eie=ga,_ie="[object Boolean]";function Tie(e){return e===!0||e===!1||Eie(e)&&Aie(e)==_ie}var Nie=Tie;const Cie=qe(Nie);function gc(e){"@babel/helpers - typeof";return gc=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},gc(e)}function Ph(){return Ph=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},Ph.apply(this,arguments)}function Mie(e,t){return kie(e)||$ie(e,t)||Pie(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 Pie(e,t){if(e){if(typeof e=="string")return DO(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 DO(e,t)}}function DO(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 $ie(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,a,i,o,l=[],s=!0,u=!1;try{if(i=(n=n.call(e)).next,t!==0)for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(d){u=!0,a=d}finally{try{if(!s&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(u)throw a}}return l}}function kie(e){if(Array.isArray(e))return e}function LO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function zO(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?LO(Object(n),!0).forEach(function(r){Die(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):LO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Die(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=zie(e,"string");return gc(t)=="symbol"?t:t+""}function zie(e,t){if(gc(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(gc(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var BO=function(t,n,r,a,i){var o=r-a,l;return l="M ".concat(t,",").concat(n),l+="L ".concat(t+r,",").concat(n),l+="L ".concat(t+r-o/2,",").concat(n+i),l+="L ".concat(t+r-o/2-a,",").concat(n+i),l+="L ".concat(t,",").concat(n," Z"),l},Bie={x:0,y:0,upperWidth:0,lowerWidth:0,height:0,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},Iie=function(t){var n=zO(zO({},Bie),t),r=O.useRef(),a=O.useState(-1),i=Mie(a,2),o=i[0],l=i[1];O.useEffect(function(){if(r.current&&r.current.getTotalLength)try{var g=r.current.getTotalLength();g&&l(g)}catch{}},[]);var s=n.x,u=n.y,d=n.upperWidth,f=n.lowerWidth,h=n.height,p=n.className,b=n.animationEasing,v=n.animationDuration,x=n.animationBegin,m=n.isUpdateAnimationActive;if(s!==+s||u!==+u||d!==+d||f!==+f||h!==+h||d===0&&f===0||h===0)return null;var y=ve("recharts-trapezoid",p);return m?$.createElement(ma,{canBegin:o>0,from:{upperWidth:0,lowerWidth:0,height:h,x:s,y:u},to:{upperWidth:d,lowerWidth:f,height:h,x:s,y:u},duration:v,animationEasing:b,isActive:m},function(g){var S=g.upperWidth,w=g.lowerWidth,j=g.height,A=g.x,E=g.y;return $.createElement(ma,{canBegin:o>0,from:"0px ".concat(o===-1?1:o,"px"),to:"".concat(o,"px 0px"),attributeName:"strokeDasharray",begin:x,duration:v,easing:b},$.createElement("path",Ph({},oe(n,!0),{className:y,d:BO(A,E,S,w,j),ref:r})))}):$.createElement("g",null,$.createElement("path",Ph({},oe(n,!0),{className:y,d:BO(s,u,d,f,h)})))},Uie=["option","shapeType","propTransformer","activeClassName","isActive"];function bc(e){"@babel/helpers - typeof";return bc=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},bc(e)}function qie(e,t){if(e==null)return{};var n=Hie(e,t),r,a;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(a=0;a<i.length;a++)r=i[a],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Hie(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 IO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function $h(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?IO(Object(n),!0).forEach(function(r){Fie(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):IO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Fie(e,t,n){return t=Gie(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Gie(e){var t=Kie(e,"string");return bc(t)=="symbol"?t:t+""}function Kie(e,t){if(bc(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(bc(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Yie(e,t){return $h($h({},t),e)}function Vie(e,t){return e==="symbols"}function UO(e){var t=e.shapeType,n=e.elementProps;switch(t){case"rectangle":return $.createElement(c1,n);case"trapezoid":return $.createElement(Iie,n);case"sector":return $.createElement(N3,n);case"symbols":if(Vie(t))return $.createElement(Tx,n);break;default:return null}}function Xie(e){return O.isValidElement(e)?e.props:e}function G3(e){var t=e.option,n=e.shapeType,r=e.propTransformer,a=r===void 0?Yie:r,i=e.activeClassName,o=i===void 0?"recharts-active-shape":i,l=e.isActive,s=qie(e,Uie),u;if(O.isValidElement(t))u=O.cloneElement(t,$h($h({},s),Xie(t)));else if(se(t))u=t(s);else if(Oie(t)&&!Cie(t)){var d=a(t,s);u=$.createElement(UO,{shapeType:n,elementProps:d})}else{var f=s;u=$.createElement(UO,{shapeType:n,elementProps:f})}return l?$.createElement(ke,{className:o},u):u}function sm(e,t){return t!=null&&"trapezoids"in e.props}function um(e,t){return t!=null&&"sectors"in e.props}function xc(e,t){return t!=null&&"points"in e.props}function Qie(e,t){var n,r,a=e.x===(t==null||(n=t.labelViewBox)===null||n===void 0?void 0:n.x)||e.x===t.x,i=e.y===(t==null||(r=t.labelViewBox)===null||r===void 0?void 0:r.y)||e.y===t.y;return a&&i}function Wie(e,t){var n=e.endAngle===t.endAngle,r=e.startAngle===t.startAngle;return n&&r}function Zie(e,t){var n=e.x===t.x,r=e.y===t.y,a=e.z===t.z;return n&&r&&a}function Jie(e,t){var n;return sm(e,t)?n=Qie:um(e,t)?n=Wie:xc(e,t)&&(n=Zie),n}function eoe(e,t){var n;return sm(e,t)?n="trapezoids":um(e,t)?n="sectors":xc(e,t)&&(n="points"),n}function toe(e,t){if(sm(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(um(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 xc(e,t)?t.payload:{}}function noe(e){var t=e.activeTooltipItem,n=e.graphicalItem,r=e.itemData,a=eoe(n,t),i=toe(n,t),o=r.filter(function(s,u){var d=em(i,s),f=n.props[a].filter(function(b){var v=Jie(n,t);return v(b,t)}),h=n.props[a].indexOf(f[f.length-1]),p=u===h;return d&&p}),l=r.indexOf(o[o.length-1]);return l}var fd;function Ql(e){"@babel/helpers - typeof";return Ql=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},Ql(e)}function Xo(){return Xo=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},Xo.apply(this,arguments)}function qO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function Ge(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?qO(Object(n),!0).forEach(function(r){Yn(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):qO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function roe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function HO(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,Y3(r.key),r)}}function aoe(e,t,n){return t&&HO(e.prototype,t),n&&HO(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function ioe(e,t,n){return t=kh(t),ooe(e,K3()?Reflect.construct(t,n||[],kh(e).constructor):t.apply(e,n))}function ooe(e,t){if(t&&(Ql(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return loe(e)}function loe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function K3(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(K3=function(){return!!e})()}function kh(e){return kh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},kh(e)}function soe(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&&b0(e,t)}function b0(e,t){return b0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,a){return r.__proto__=a,r},b0(e,t)}function Yn(e,t,n){return t=Y3(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Y3(e){var t=uoe(e,"string");return Ql(t)=="symbol"?t:t+""}function uoe(e,t){if(Ql(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Ql(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var xa=function(e){function t(n){var r;return roe(this,t),r=ioe(this,t,[n]),Yn(r,"pieRef",null),Yn(r,"sectorRefs",[]),Yn(r,"id",tf("recharts-pie-")),Yn(r,"handleAnimationEnd",function(){var a=r.props.onAnimationEnd;r.setState({isAnimationFinished:!0}),se(a)&&a()}),Yn(r,"handleAnimationStart",function(){var a=r.props.onAnimationStart;r.setState({isAnimationFinished:!1}),se(a)&&a()}),r.state={isAnimationFinished:!n.isAnimationActive,prevIsAnimationActive:n.isAnimationActive,prevAnimationId:n.animationId,sectorToFocus:0},r}return soe(t,e),aoe(t,[{key:"isActiveIndex",value:function(r){var a=this.props.activeIndex;return Array.isArray(a)?a.indexOf(r)!==-1:r===a}},{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 a=this.props.isAnimationActive;if(a&&!this.state.isAnimationFinished)return null;var i=this.props,o=i.label,l=i.labelLine,s=i.dataKey,u=i.valueKey,d=oe(this.props,!1),f=oe(o,!1),h=oe(l,!1),p=o&&o.offsetRadius||20,b=r.map(function(v,x){var m=(v.startAngle+v.endAngle)/2,y=Ve(v.cx,v.cy,v.outerRadius+p,m),g=Ge(Ge(Ge(Ge({},d),v),{},{stroke:"none"},f),{},{index:x,textAnchor:t.getTextAnchor(y.x,v.cx)},y),S=Ge(Ge(Ge(Ge({},d),v),{},{fill:"none",stroke:v.fill},h),{},{index:x,points:[Ve(v.cx,v.cy,v.outerRadius,m),y]}),w=s;return ge(s)&&ge(u)?w="value":ge(s)&&(w=u),$.createElement(ke,{key:"label-".concat(v.startAngle,"-").concat(v.endAngle,"-").concat(v.midAngle,"-").concat(x)},l&&t.renderLabelLineItem(l,S,"line"),t.renderLabelItem(o,g,Kt(v,w)))});return $.createElement(ke,{className:"recharts-pie-labels"},b)}},{key:"renderSectorsStatically",value:function(r){var a=this,i=this.props,o=i.activeShape,l=i.blendStroke,s=i.inactiveShape;return r.map(function(u,d){if((u==null?void 0:u.startAngle)===0&&(u==null?void 0:u.endAngle)===0&&r.length!==1)return null;var f=a.isActiveIndex(d),h=s&&a.hasActiveIndex()?s:null,p=f?o:h,b=Ge(Ge({},u),{},{stroke:l?u.fill:u.stroke,tabIndex:-1});return $.createElement(ke,Xo({ref:function(x){x&&!a.sectorRefs.includes(x)&&a.sectorRefs.push(x)},tabIndex:-1,className:"recharts-pie-sector"},lo(a.props,u,d),{key:"sector-".concat(u==null?void 0:u.startAngle,"-").concat(u==null?void 0:u.endAngle,"-").concat(u.midAngle,"-").concat(d)}),$.createElement(G3,Xo({option:p,isActive:f,shapeType:"sector"},b)))})}},{key:"renderSectorsWithAnimation",value:function(){var r=this,a=this.props,i=a.sectors,o=a.isAnimationActive,l=a.animationBegin,s=a.animationDuration,u=a.animationEasing,d=a.animationId,f=this.state,h=f.prevSectors,p=f.prevIsAnimationActive;return $.createElement(ma,{begin:l,duration:s,isActive:o,easing:u,from:{t:0},to:{t:1},key:"pie-".concat(d,"-").concat(p),onAnimationStart:this.handleAnimationStart,onAnimationEnd:this.handleAnimationEnd},function(b){var v=b.t,x=[],m=i&&i[0],y=m.startAngle;return i.forEach(function(g,S){var w=h&&h[S],j=S>0?Rn(g,"paddingAngle",0):0;if(w){var A=Aa(w.endAngle-w.startAngle,g.endAngle-g.startAngle),E=Ge(Ge({},g),{},{startAngle:y+j,endAngle:y+A(v)+j});x.push(E),y=E.endAngle}else{var _=g.endAngle,N=g.startAngle,D=Aa(0,_-N),R=D(v),B=Ge(Ge({},g),{},{startAngle:y+j,endAngle:y+R+j});x.push(B),y=B.endAngle}}),$.createElement(ke,null,r.renderSectorsStatically(x))})}},{key:"attachKeyboardHandlers",value:function(r){var a=this;r.onkeydown=function(i){if(!i.altKey)switch(i.key){case"ArrowLeft":{var o=++a.state.sectorToFocus%a.sectorRefs.length;a.sectorRefs[o].focus(),a.setState({sectorToFocus:o});break}case"ArrowRight":{var l=--a.state.sectorToFocus<0?a.sectorRefs.length-1:a.state.sectorToFocus%a.sectorRefs.length;a.sectorRefs[l].focus(),a.setState({sectorToFocus:l});break}case"Escape":{a.sectorRefs[a.state.sectorToFocus].blur(),a.setState({sectorToFocus:0});break}}}}},{key:"renderSectors",value:function(){var r=this.props,a=r.sectors,i=r.isAnimationActive,o=this.state.prevSectors;return i&&a&&a.length&&(!o||!em(o,a))?this.renderSectorsWithAnimation():this.renderSectorsStatically(a)}},{key:"componentDidMount",value:function(){this.pieRef&&this.attachKeyboardHandlers(this.pieRef)}},{key:"render",value:function(){var r=this,a=this.props,i=a.hide,o=a.sectors,l=a.className,s=a.label,u=a.cx,d=a.cy,f=a.innerRadius,h=a.outerRadius,p=a.isAnimationActive,b=this.state.isAnimationFinished;if(i||!o||!o.length||!V(u)||!V(d)||!V(f)||!V(h))return null;var v=ve("recharts-pie",l);return $.createElement(ke,{tabIndex:this.props.rootTabIndex,className:v,ref:function(m){r.pieRef=m}},this.renderSectors(),s&&this.renderLabels(o),Mt.renderCallByParent(this.props,null,!1),(!p||b)&&ri.renderCallByParent(this.props,o,!1))}}],[{key:"getDerivedStateFromProps",value:function(r,a){return a.prevIsAnimationActive!==r.isAnimationActive?{prevIsAnimationActive:r.isAnimationActive,prevAnimationId:r.animationId,curSectors:r.sectors,prevSectors:[],isAnimationFinished:!0}:r.isAnimationActive&&r.animationId!==a.prevAnimationId?{prevAnimationId:r.animationId,curSectors:r.sectors,prevSectors:a.curSectors,isAnimationFinished:!0}:r.sectors!==a.curSectors?{curSectors:r.sectors,isAnimationFinished:!0}:null}},{key:"getTextAnchor",value:function(r,a){return r>a?"start":r<a?"end":"middle"}},{key:"renderLabelLineItem",value:function(r,a,i){if($.isValidElement(r))return $.cloneElement(r,a);if(se(r))return r(a);var o=ve("recharts-pie-label-line",typeof r!="boolean"?r.className:"");return $.createElement(a0,Xo({},a,{key:i,type:"linear",className:o}))}},{key:"renderLabelItem",value:function(r,a,i){if($.isValidElement(r))return $.cloneElement(r,a);var o=i;if(se(r)&&(o=r(a),$.isValidElement(o)))return o;var l=ve("recharts-pie-label-text",typeof r!="boolean"&&!se(r)?r.className:"");return $.createElement(so,Xo({},a,{alignmentBaseline:"middle",className:l}),o)}}])}(O.PureComponent);fd=xa;Yn(xa,"displayName","Pie");Yn(xa,"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:!Rs.isSsr,animationBegin:400,animationDuration:1500,animationEasing:"ease",nameKey:"name",blendStroke:!1,rootTabIndex:0});Yn(xa,"parseDeltaAngle",function(e,t){var n=Jt(t-e),r=Math.min(Math.abs(t-e),360);return n*r});Yn(xa,"getRealPieData",function(e){var t=e.data,n=e.children,r=oe(e,!1),a=Wn(n,Fp);return t&&t.length?t.map(function(i,o){return Ge(Ge(Ge({payload:i},r),i),a&&a[o]&&a[o].props)}):a&&a.length?a.map(function(i){return Ge(Ge({},r),i.props)}):[]});Yn(xa,"parseCoordinateOfPie",function(e,t){var n=t.top,r=t.left,a=t.width,i=t.height,o=A3(a,i),l=r+en(e.cx,a,a/2),s=n+en(e.cy,i,i/2),u=en(e.innerRadius,o,0),d=en(e.outerRadius,o,o*.8),f=e.maxRadius||Math.sqrt(a*a+i*i)/2;return{cx:l,cy:s,innerRadius:u,outerRadius:d,maxRadius:f}});Yn(xa,"getComposedData",function(e){var t=e.item,n=e.offset,r=t.type.defaultProps!==void 0?Ge(Ge({},t.type.defaultProps),t.props):t.props,a=fd.getRealPieData(r);if(!a||!a.length)return null;var i=r.cornerRadius,o=r.startAngle,l=r.endAngle,s=r.paddingAngle,u=r.dataKey,d=r.nameKey,f=r.valueKey,h=r.tooltipType,p=Math.abs(r.minAngle),b=fd.parseCoordinateOfPie(r,n),v=fd.parseDeltaAngle(o,l),x=Math.abs(v),m=u;ge(u)&&ge(f)?(ra(!1,`Use "dataKey" to specify the value of pie,
      the props "valueKey" will be deprecated in 1.1.0`),m="value"):ge(u)&&(ra(!1,`Use "dataKey" to specify the value of pie,
      the props "valueKey" will be deprecated in 1.1.0`),m=f);var y=a.filter(function(E){return Kt(E,m,0)!==0}).length,g=(x>=360?y:y-1)*s,S=x-y*p-g,w=a.reduce(function(E,_){var N=Kt(_,m,0);return E+(V(N)?N:0)},0),j;if(w>0){var A;j=a.map(function(E,_){var N=Kt(E,m,0),D=Kt(E,d,_),R=(V(N)?N:0)/w,B;_?B=A.endAngle+Jt(v)*s*(N!==0?1:0):B=o;var k=B+Jt(v)*((N!==0?p:0)+R*S),C=(B+k)/2,M=(b.innerRadius+b.outerRadius)/2,L=[{name:D,value:N,payload:E,dataKey:m,type:h}],z=Ve(b.cx,b.cy,M,C);return A=Ge(Ge(Ge({percent:R,cornerRadius:i,name:D,tooltipPayload:L,midAngle:C,middleRadius:M,tooltipPosition:z},E),b),{},{value:Kt(E,m),startAngle:B,endAngle:k,payload:E,paddingAngle:Jt(v)*s}),A})}return Ge(Ge({},b),{},{sectors:j,data:a})});var coe=Math.ceil,foe=Math.max;function doe(e,t,n,r){for(var a=-1,i=foe(coe((t-e)/(n||1)),0),o=Array(i);i--;)o[r?i:++a]=e,e+=n;return o}var hoe=doe,poe=pM,FO=1/0,moe=17976931348623157e292;function yoe(e){if(!e)return e===0?e:0;if(e=poe(e),e===FO||e===-FO){var t=e<0?-1:1;return t*moe}return e===e?e:0}var voe=yoe,goe=hoe,boe=Hp,$y=voe;function xoe(e){return function(t,n,r){return r&&typeof r!="number"&&boe(t,n,r)&&(n=r=void 0),t=$y(t),n===void 0?(n=t,t=0):n=$y(n),r=r===void 0?t<n?1:-1:$y(r),goe(t,n,r,e)}}var Soe=xoe,woe=Soe,joe=woe(),Ooe=joe;const Dh=qe(Ooe);function Sc(e){"@babel/helpers - typeof";return Sc=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},Sc(e)}function GO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function KO(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?GO(Object(n),!0).forEach(function(r){V3(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):GO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function V3(e,t,n){return t=Aoe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Aoe(e){var t=Eoe(e,"string");return Sc(t)=="symbol"?t:t+""}function Eoe(e,t){if(Sc(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Sc(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var _oe=["Webkit","Moz","O","ms"],Toe=function(t,n){var r=t.replace(/(\w)/,function(i){return i.toUpperCase()}),a=_oe.reduce(function(i,o){return KO(KO({},i),{},V3({},o+r,n))},{});return a[t]=n,a};function Wl(e){"@babel/helpers - typeof";return Wl=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},Wl(e)}function Lh(){return Lh=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},Lh.apply(this,arguments)}function YO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function ky(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?YO(Object(n),!0).forEach(function(r){bn(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):YO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Noe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function VO(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,Q3(r.key),r)}}function Coe(e,t,n){return t&&VO(e.prototype,t),n&&VO(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Moe(e,t,n){return t=zh(t),Roe(e,X3()?Reflect.construct(t,n||[],zh(e).constructor):t.apply(e,n))}function Roe(e,t){if(t&&(Wl(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Poe(e)}function Poe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function X3(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(X3=function(){return!!e})()}function zh(e){return zh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},zh(e)}function $oe(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&&x0(e,t)}function x0(e,t){return x0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,a){return r.__proto__=a,r},x0(e,t)}function bn(e,t,n){return t=Q3(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Q3(e){var t=koe(e,"string");return Wl(t)=="symbol"?t:t+""}function koe(e,t){if(Wl(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Wl(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Doe=function(t){var n=t.data,r=t.startIndex,a=t.endIndex,i=t.x,o=t.width,l=t.travellerWidth;if(!n||!n.length)return{};var s=n.length,u=ju().domain(Dh(0,s)).range([i,i+o-l]),d=u.domain().map(function(f){return u(f)});return{isTextActive:!1,isSlideMoving:!1,isTravellerMoving:!1,isTravellerFocused:!1,startX:u(r),endX:u(a),scale:u,scaleValues:d}},XO=function(t){return t.changedTouches&&!!t.changedTouches.length},Zl=function(e){function t(n){var r;return Noe(this,t),r=Moe(this,t,[n]),bn(r,"handleDrag",function(a){r.leaveTimer&&(clearTimeout(r.leaveTimer),r.leaveTimer=null),r.state.isTravellerMoving?r.handleTravellerMove(a):r.state.isSlideMoving&&r.handleSlideDrag(a)}),bn(r,"handleTouchMove",function(a){a.changedTouches!=null&&a.changedTouches.length>0&&r.handleDrag(a.changedTouches[0])}),bn(r,"handleDragEnd",function(){r.setState({isTravellerMoving:!1,isSlideMoving:!1},function(){var a=r.props,i=a.endIndex,o=a.onDragEnd,l=a.startIndex;o==null||o({endIndex:i,startIndex:l})}),r.detachDragEndListener()}),bn(r,"handleLeaveWrapper",function(){(r.state.isTravellerMoving||r.state.isSlideMoving)&&(r.leaveTimer=window.setTimeout(r.handleDragEnd,r.props.leaveTimeOut))}),bn(r,"handleEnterSlideOrTraveller",function(){r.setState({isTextActive:!0})}),bn(r,"handleLeaveSlideOrTraveller",function(){r.setState({isTextActive:!1})}),bn(r,"handleSlideDragStart",function(a){var i=XO(a)?a.changedTouches[0]:a;r.setState({isTravellerMoving:!1,isSlideMoving:!0,slideMoveStartX:i.pageX}),r.attachDragEndListener()}),r.travellerDragStartHandlers={startX:r.handleTravellerDragStart.bind(r,"startX"),endX:r.handleTravellerDragStart.bind(r,"endX")},r.state={},r}return $oe(t,e),Coe(t,[{key:"componentWillUnmount",value:function(){this.leaveTimer&&(clearTimeout(this.leaveTimer),this.leaveTimer=null),this.detachDragEndListener()}},{key:"getIndex",value:function(r){var a=r.startX,i=r.endX,o=this.state.scaleValues,l=this.props,s=l.gap,u=l.data,d=u.length-1,f=Math.min(a,i),h=Math.max(a,i),p=t.getIndexInRange(o,f),b=t.getIndexInRange(o,h);return{startIndex:p-p%s,endIndex:b===d?d:b-b%s}}},{key:"getTextOfTick",value:function(r){var a=this.props,i=a.data,o=a.tickFormatter,l=a.dataKey,s=Kt(i[r],l,r);return se(o)?o(s,r):s}},{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 a=this.state,i=a.slideMoveStartX,o=a.startX,l=a.endX,s=this.props,u=s.x,d=s.width,f=s.travellerWidth,h=s.startIndex,p=s.endIndex,b=s.onChange,v=r.pageX-i;v>0?v=Math.min(v,u+d-f-l,u+d-f-o):v<0&&(v=Math.max(v,u-o,u-l));var x=this.getIndex({startX:o+v,endX:l+v});(x.startIndex!==h||x.endIndex!==p)&&b&&b(x),this.setState({startX:o+v,endX:l+v,slideMoveStartX:r.pageX})}},{key:"handleTravellerDragStart",value:function(r,a){var i=XO(a)?a.changedTouches[0]:a;this.setState({isSlideMoving:!1,isTravellerMoving:!0,movingTravellerId:r,brushMoveStartX:i.pageX}),this.attachDragEndListener()}},{key:"handleTravellerMove",value:function(r){var a=this.state,i=a.brushMoveStartX,o=a.movingTravellerId,l=a.endX,s=a.startX,u=this.state[o],d=this.props,f=d.x,h=d.width,p=d.travellerWidth,b=d.onChange,v=d.gap,x=d.data,m={startX:this.state.startX,endX:this.state.endX},y=r.pageX-i;y>0?y=Math.min(y,f+h-p-u):y<0&&(y=Math.max(y,f-u)),m[o]=u+y;var g=this.getIndex(m),S=g.startIndex,w=g.endIndex,j=function(){var E=x.length-1;return o==="startX"&&(l>s?S%v===0:w%v===0)||l<s&&w===E||o==="endX"&&(l>s?w%v===0:S%v===0)||l>s&&w===E};this.setState(bn(bn({},o,u+y),"brushMoveStartX",r.pageX),function(){b&&j()&&b(g)})}},{key:"handleTravellerMoveKeyboard",value:function(r,a){var i=this,o=this.state,l=o.scaleValues,s=o.startX,u=o.endX,d=this.state[a],f=l.indexOf(d);if(f!==-1){var h=f+r;if(!(h===-1||h>=l.length)){var p=l[h];a==="startX"&&p>=u||a==="endX"&&p<=s||this.setState(bn({},a,p),function(){i.props.onChange(i.getIndex({startX:i.state.startX,endX:i.state.endX}))})}}}},{key:"renderBackground",value:function(){var r=this.props,a=r.x,i=r.y,o=r.width,l=r.height,s=r.fill,u=r.stroke;return $.createElement("rect",{stroke:u,fill:s,x:a,y:i,width:o,height:l})}},{key:"renderPanorama",value:function(){var r=this.props,a=r.x,i=r.y,o=r.width,l=r.height,s=r.data,u=r.children,d=r.padding,f=O.Children.only(u);return f?$.cloneElement(f,{x:a,y:i,width:o,height:l,margin:d,compact:!0,data:s}):null}},{key:"renderTravellerLayer",value:function(r,a){var i,o,l=this,s=this.props,u=s.y,d=s.travellerWidth,f=s.height,h=s.traveller,p=s.ariaLabel,b=s.data,v=s.startIndex,x=s.endIndex,m=Math.max(r,this.props.x),y=ky(ky({},oe(this.props,!1)),{},{x:m,y:u,width:d,height:f}),g=p||"Min value: ".concat((i=b[v])===null||i===void 0?void 0:i.name,", Max value: ").concat((o=b[x])===null||o===void 0?void 0:o.name);return $.createElement(ke,{tabIndex:0,role:"slider","aria-label":g,"aria-valuenow":r,className:"recharts-brush-traveller",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.travellerDragStartHandlers[a],onTouchStart:this.travellerDragStartHandlers[a],onKeyDown:function(w){["ArrowLeft","ArrowRight"].includes(w.key)&&(w.preventDefault(),w.stopPropagation(),l.handleTravellerMoveKeyboard(w.key==="ArrowRight"?1:-1,a))},onFocus:function(){l.setState({isTravellerFocused:!0})},onBlur:function(){l.setState({isTravellerFocused:!1})},style:{cursor:"col-resize"}},t.renderTraveller(h,y))}},{key:"renderSlide",value:function(r,a){var i=this.props,o=i.y,l=i.height,s=i.stroke,u=i.travellerWidth,d=Math.min(r,a)+u,f=Math.max(Math.abs(a-r)-u,0);return $.createElement("rect",{className:"recharts-brush-slide",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.handleSlideDragStart,onTouchStart:this.handleSlideDragStart,style:{cursor:"move"},stroke:"none",fill:s,fillOpacity:.2,x:d,y:o,width:f,height:l})}},{key:"renderText",value:function(){var r=this.props,a=r.startIndex,i=r.endIndex,o=r.y,l=r.height,s=r.travellerWidth,u=r.stroke,d=this.state,f=d.startX,h=d.endX,p=5,b={pointerEvents:"none",fill:u};return $.createElement(ke,{className:"recharts-brush-texts"},$.createElement(so,Lh({textAnchor:"end",verticalAnchor:"middle",x:Math.min(f,h)-p,y:o+l/2},b),this.getTextOfTick(a)),$.createElement(so,Lh({textAnchor:"start",verticalAnchor:"middle",x:Math.max(f,h)+s+p,y:o+l/2},b),this.getTextOfTick(i)))}},{key:"render",value:function(){var r=this.props,a=r.data,i=r.className,o=r.children,l=r.x,s=r.y,u=r.width,d=r.height,f=r.alwaysShowText,h=this.state,p=h.startX,b=h.endX,v=h.isTextActive,x=h.isSlideMoving,m=h.isTravellerMoving,y=h.isTravellerFocused;if(!a||!a.length||!V(l)||!V(s)||!V(u)||!V(d)||u<=0||d<=0)return null;var g=ve("recharts-brush",i),S=$.Children.count(o)===1,w=Toe("userSelect","none");return $.createElement(ke,{className:g,onMouseLeave:this.handleLeaveWrapper,onTouchMove:this.handleTouchMove,style:w},this.renderBackground(),S&&this.renderPanorama(),this.renderSlide(p,b),this.renderTravellerLayer(p,"startX"),this.renderTravellerLayer(b,"endX"),(v||x||m||y||f)&&this.renderText())}}],[{key:"renderDefaultTraveller",value:function(r){var a=r.x,i=r.y,o=r.width,l=r.height,s=r.stroke,u=Math.floor(i+l/2)-1;return $.createElement($.Fragment,null,$.createElement("rect",{x:a,y:i,width:o,height:l,fill:s,stroke:"none"}),$.createElement("line",{x1:a+1,y1:u,x2:a+o-1,y2:u,fill:"none",stroke:"#fff"}),$.createElement("line",{x1:a+1,y1:u+2,x2:a+o-1,y2:u+2,fill:"none",stroke:"#fff"}))}},{key:"renderTraveller",value:function(r,a){var i;return $.isValidElement(r)?i=$.cloneElement(r,a):se(r)?i=r(a):i=t.renderDefaultTraveller(a),i}},{key:"getDerivedStateFromProps",value:function(r,a){var i=r.data,o=r.width,l=r.x,s=r.travellerWidth,u=r.updateId,d=r.startIndex,f=r.endIndex;if(i!==a.prevData||u!==a.prevUpdateId)return ky({prevData:i,prevTravellerWidth:s,prevUpdateId:u,prevX:l,prevWidth:o},i&&i.length?Doe({data:i,width:o,x:l,travellerWidth:s,startIndex:d,endIndex:f}):{scale:null,scaleValues:null});if(a.scale&&(o!==a.prevWidth||l!==a.prevX||s!==a.prevTravellerWidth)){a.scale.range([l,l+o-s]);var h=a.scale.domain().map(function(p){return a.scale(p)});return{prevData:i,prevTravellerWidth:s,prevUpdateId:u,prevX:l,prevWidth:o,startX:a.scale(r.startIndex),endX:a.scale(r.endIndex),scaleValues:h}}return null}},{key:"getIndexInRange",value:function(r,a){for(var i=r.length,o=0,l=i-1;l-o>1;){var s=Math.floor((o+l)/2);r[s]>a?l=s:o=s}return a>=r[l]?l:o}}])}(O.PureComponent);bn(Zl,"displayName","Brush");bn(Zl,"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 Loe=Dx;function zoe(e,t){var n;return Loe(e,function(r,a,i){return n=t(r,a,i),!n}),!!n}var Boe=zoe,Ioe=qC,Uoe=fi,qoe=Boe,Hoe=vn,Foe=Hp;function Goe(e,t,n){var r=Hoe(e)?Ioe:qoe;return n&&Foe(e,t,n)&&(t=void 0),r(e,Uoe(t))}var Koe=Goe;const Yoe=qe(Koe);var Er=function(t,n){var r=t.alwaysShow,a=t.ifOverflow;return r&&(a="extendDomain"),a===n},QO=uM;function Voe(e,t,n){t=="__proto__"&&QO?QO(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}var Xoe=Voe,Qoe=Xoe,Woe=lM,Zoe=fi;function Joe(e,t){var n={};return t=Zoe(t),Woe(e,function(r,a,i){Qoe(n,a,t(r,a,i))}),n}var ele=Joe;const tle=qe(ele);function nle(e,t){for(var n=-1,r=e==null?0:e.length;++n<r;)if(!t(e[n],n,e))return!1;return!0}var rle=nle,ale=Dx;function ile(e,t){var n=!0;return ale(e,function(r,a,i){return n=!!t(r,a,i),n}),n}var ole=ile,lle=rle,sle=ole,ule=fi,cle=vn,fle=Hp;function dle(e,t,n){var r=cle(e)?lle:sle;return n&&fle(e,t,n)&&(t=void 0),r(e,ule(t))}var hle=dle;const ple=qe(hle);var mle=["x","y"];function wc(e){"@babel/helpers - typeof";return wc=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},wc(e)}function S0(){return S0=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},S0.apply(this,arguments)}function WO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function eu(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?WO(Object(n),!0).forEach(function(r){yle(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):WO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function yle(e,t,n){return t=vle(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function vle(e){var t=gle(e,"string");return wc(t)=="symbol"?t:t+""}function gle(e,t){if(wc(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(wc(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function ble(e,t){if(e==null)return{};var n=xle(e,t),r,a;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(a=0;a<i.length;a++)r=i[a],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function xle(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 Sle(e,t){var n=e.x,r=e.y,a=ble(e,mle),i="".concat(n),o=parseInt(i,10),l="".concat(r),s=parseInt(l,10),u="".concat(t.height||a.height),d=parseInt(u,10),f="".concat(t.width||a.width),h=parseInt(f,10);return eu(eu(eu(eu(eu({},t),a),o?{x:o}:{}),s?{y:s}:{}),{},{height:d,width:h,name:t.name,radius:t.radius})}function ZO(e){return $.createElement(G3,S0({shapeType:"rectangle",propTransformer:Sle,activeClassName:"recharts-active-bar"},e))}var wle=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return function(r,a){if(typeof t=="number")return t;var i=V(r)||UU(r);return i?t(r,a):(i||co(),n)}},jle=["value","background"],W3;function Jl(e){"@babel/helpers - typeof";return Jl=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},Jl(e)}function Ole(e,t){if(e==null)return{};var n=Ale(e,t),r,a;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(a=0;a<i.length;a++)r=i[a],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Ale(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 Bh(){return Bh=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},Bh.apply(this,arguments)}function JO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).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?JO(Object(n),!0).forEach(function(r){Ga(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):JO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Ele(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function eA(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,J3(r.key),r)}}function _le(e,t,n){return t&&eA(e.prototype,t),n&&eA(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Tle(e,t,n){return t=Ih(t),Nle(e,Z3()?Reflect.construct(t,n||[],Ih(e).constructor):t.apply(e,n))}function Nle(e,t){if(t&&(Jl(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Cle(e)}function Cle(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Z3(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(Z3=function(){return!!e})()}function Ih(e){return Ih=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Ih(e)}function Mle(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&&w0(e,t)}function w0(e,t){return w0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,a){return r.__proto__=a,r},w0(e,t)}function Ga(e,t,n){return t=J3(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function J3(e){var t=Rle(e,"string");return Jl(t)=="symbol"?t:t+""}function Rle(e,t){if(Jl(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Jl(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var wo=function(e){function t(){var n;Ele(this,t);for(var r=arguments.length,a=new Array(r),i=0;i<r;i++)a[i]=arguments[i];return n=Tle(this,t,[].concat(a)),Ga(n,"state",{isAnimationFinished:!1}),Ga(n,"id",tf("recharts-bar-")),Ga(n,"handleAnimationEnd",function(){var o=n.props.onAnimationEnd;n.setState({isAnimationFinished:!0}),o&&o()}),Ga(n,"handleAnimationStart",function(){var o=n.props.onAnimationStart;n.setState({isAnimationFinished:!1}),o&&o()}),n}return Mle(t,e),_le(t,[{key:"renderRectanglesStatically",value:function(r){var a=this,i=this.props,o=i.shape,l=i.dataKey,s=i.activeIndex,u=i.activeBar,d=oe(this.props,!1);return r&&r.map(function(f,h){var p=h===s,b=p?u:o,v=ht(ht(ht({},d),f),{},{isActive:p,option:b,index:h,dataKey:l,onAnimationStart:a.handleAnimationStart,onAnimationEnd:a.handleAnimationEnd});return $.createElement(ke,Bh({className:"recharts-bar-rectangle"},lo(a.props,f,h),{key:"rectangle-".concat(f==null?void 0:f.x,"-").concat(f==null?void 0:f.y,"-").concat(f==null?void 0:f.value,"-").concat(h)}),$.createElement(ZO,v))})}},{key:"renderRectanglesWithAnimation",value:function(){var r=this,a=this.props,i=a.data,o=a.layout,l=a.isAnimationActive,s=a.animationBegin,u=a.animationDuration,d=a.animationEasing,f=a.animationId,h=this.state.prevData;return $.createElement(ma,{begin:s,duration:u,isActive:l,easing:d,from:{t:0},to:{t:1},key:"bar-".concat(f),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(p){var b=p.t,v=i.map(function(x,m){var y=h&&h[m];if(y){var g=Aa(y.x,x.x),S=Aa(y.y,x.y),w=Aa(y.width,x.width),j=Aa(y.height,x.height);return ht(ht({},x),{},{x:g(b),y:S(b),width:w(b),height:j(b)})}if(o==="horizontal"){var A=Aa(0,x.height),E=A(b);return ht(ht({},x),{},{y:x.y+x.height-E,height:E})}var _=Aa(0,x.width),N=_(b);return ht(ht({},x),{},{width:N})});return $.createElement(ke,null,r.renderRectanglesStatically(v))})}},{key:"renderRectangles",value:function(){var r=this.props,a=r.data,i=r.isAnimationActive,o=this.state.prevData;return i&&a&&a.length&&(!o||!em(o,a))?this.renderRectanglesWithAnimation():this.renderRectanglesStatically(a)}},{key:"renderBackground",value:function(){var r=this,a=this.props,i=a.data,o=a.dataKey,l=a.activeIndex,s=oe(this.props.background,!1);return i.map(function(u,d){u.value;var f=u.background,h=Ole(u,jle);if(!f)return null;var p=ht(ht(ht(ht(ht({},h),{},{fill:"#eee"},f),s),lo(r.props,u,d)),{},{onAnimationStart:r.handleAnimationStart,onAnimationEnd:r.handleAnimationEnd,dataKey:o,index:d,className:"recharts-bar-background-rectangle"});return $.createElement(ZO,Bh({key:"background-bar-".concat(d),option:r.props.background,isActive:d===l},p))})}},{key:"renderErrorBar",value:function(r,a){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var i=this.props,o=i.data,l=i.xAxis,s=i.yAxis,u=i.layout,d=i.children,f=Wn(d,rm);if(!f)return null;var h=u==="vertical"?o[0].height/2:o[0].width/2,p=function(x,m){var y=Array.isArray(x.value)?x.value[1]:x.value;return{x:x.x,y:x.y,value:y,errorVal:Kt(x,m)}},b={clipPath:r?"url(#clipPath-".concat(a,")"):null};return $.createElement(ke,b,f.map(function(v){return $.cloneElement(v,{key:"error-bar-".concat(a,"-").concat(v.props.dataKey),data:o,xAxis:l,yAxis:s,layout:u,offset:h,dataPointFormatter:p})}))}},{key:"render",value:function(){var r=this.props,a=r.hide,i=r.data,o=r.className,l=r.xAxis,s=r.yAxis,u=r.left,d=r.top,f=r.width,h=r.height,p=r.isAnimationActive,b=r.background,v=r.id;if(a||!i||!i.length)return null;var x=this.state.isAnimationFinished,m=ve("recharts-bar",o),y=l&&l.allowDataOverflow,g=s&&s.allowDataOverflow,S=y||g,w=ge(v)?this.id:v;return $.createElement(ke,{className:m},y||g?$.createElement("defs",null,$.createElement("clipPath",{id:"clipPath-".concat(w)},$.createElement("rect",{x:y?u:u-f/2,y:g?d:d-h/2,width:y?f:f*2,height:g?h:h*2}))):null,$.createElement(ke,{className:"recharts-bar-rectangles",clipPath:S?"url(#clipPath-".concat(w,")"):null},b?this.renderBackground():null,this.renderRectangles()),this.renderErrorBar(S,w),(!p||x)&&ri.renderCallByParent(this.props,i))}}],[{key:"getDerivedStateFromProps",value:function(r,a){return r.animationId!==a.prevAnimationId?{prevAnimationId:r.animationId,curData:r.data,prevData:a.curData}:r.data!==a.curData?{curData:r.data}:null}}])}(O.PureComponent);W3=wo;Ga(wo,"displayName","Bar");Ga(wo,"defaultProps",{xAxisId:0,yAxisId:0,legendType:"rect",minPointSize:0,hide:!1,data:[],layout:"vertical",activeBar:!1,isAnimationActive:!Rs.isSsr,animationBegin:0,animationDuration:400,animationEasing:"ease"});Ga(wo,"getComposedData",function(e){var t=e.props,n=e.item,r=e.barPosition,a=e.bandSize,i=e.xAxis,o=e.yAxis,l=e.xAxisTicks,s=e.yAxisTicks,u=e.stackedData,d=e.dataStartIndex,f=e.displayedData,h=e.offset,p=ote(r,n);if(!p)return null;var b=t.layout,v=n.type.defaultProps,x=v!==void 0?ht(ht({},v),n.props):n.props,m=x.dataKey,y=x.children,g=x.minPointSize,S=b==="horizontal"?o:i,w=u?S.scale.domain():null,j=hte({numericAxis:S}),A=Wn(y,Fp),E=f.map(function(_,N){var D,R,B,k,C,M;u?D=lte(u[d+N],w):(D=Kt(_,m),Array.isArray(D)||(D=[j,D]));var L=wle(g,W3.defaultProps.minPointSize)(D[1],N);if(b==="horizontal"){var z,F=[o.scale(D[0]),o.scale(D[1])],K=F[0],G=F[1];R=K2({axis:i,ticks:l,bandSize:a,offset:p.offset,entry:_,index:N}),B=(z=G??K)!==null&&z!==void 0?z:void 0,k=p.size;var Y=K-G;if(C=Number.isNaN(Y)?0:Y,M={x:R,y:o.y,width:k,height:o.height},Math.abs(L)>0&&Math.abs(C)<Math.abs(L)){var J=Jt(C||L)*(Math.abs(L)-Math.abs(C));B-=J,C+=J}}else{var me=[i.scale(D[0]),i.scale(D[1])],Le=me[0],ce=me[1];if(R=Le,B=K2({axis:o,ticks:s,bandSize:a,offset:p.offset,entry:_,index:N}),k=ce-Le,C=p.size,M={x:i.x,y:B,width:i.width,height:C},Math.abs(L)>0&&Math.abs(k)<Math.abs(L)){var $t=Jt(k||L)*(Math.abs(L)-Math.abs(k));k+=$t}}return ht(ht(ht({},_),{},{x:R,y:B,width:k,height:C,value:u?D:D[1],payload:_,background:M},A&&A[N]&&A[N].props),{},{tooltipPayload:[j3(n,_)],tooltipPosition:{x:R+k/2,y:B+C/2}})});return ht({data:E,layout:b},h)});function jc(e){"@babel/helpers - typeof";return jc=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},jc(e)}function Ple(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function tA(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,eR(r.key),r)}}function $le(e,t,n){return t&&tA(e.prototype,t),n&&tA(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function nA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function ur(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?nA(Object(n),!0).forEach(function(r){cm(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):nA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function cm(e,t,n){return t=eR(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function eR(e){var t=kle(e,"string");return jc(t)=="symbol"?t:t+""}function kle(e,t){if(jc(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(jc(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Dle=function(t,n,r,a,i){var o=t.width,l=t.height,s=t.layout,u=t.children,d=Object.keys(n),f={left:r.left,leftMirror:r.left,right:o-r.right,rightMirror:o-r.right,top:r.top,topMirror:r.top,bottom:l-r.bottom,bottomMirror:l-r.bottom},h=!!Sn(u,wo);return d.reduce(function(p,b){var v=n[b],x=v.orientation,m=v.domain,y=v.padding,g=y===void 0?{}:y,S=v.mirror,w=v.reversed,j="".concat(x).concat(S?"Mirror":""),A,E,_,N,D;if(v.type==="number"&&(v.padding==="gap"||v.padding==="no-gap")){var R=m[1]-m[0],B=1/0,k=v.categoricalDomain.sort(FU);if(k.forEach(function(me,Le){Le>0&&(B=Math.min((me||0)-(k[Le-1]||0),B))}),Number.isFinite(B)){var C=B/R,M=v.layout==="vertical"?r.height:r.width;if(v.padding==="gap"&&(A=C*M/2),v.padding==="no-gap"){var L=en(t.barCategoryGap,C*M),z=C*M/2;A=z-L-(z-L)/M*L}}}a==="xAxis"?E=[r.left+(g.left||0)+(A||0),r.left+r.width-(g.right||0)-(A||0)]:a==="yAxis"?E=s==="horizontal"?[r.top+r.height-(g.bottom||0),r.top+(g.top||0)]:[r.top+(g.top||0)+(A||0),r.top+r.height-(g.bottom||0)-(A||0)]:E=v.range,w&&(E=[E[1],E[0]]);var F=b3(v,i,h),K=F.scale,G=F.realScaleType;K.domain(m).range(E),x3(K);var Y=S3(K,ur(ur({},v),{},{realScaleType:G}));a==="xAxis"?(D=x==="top"&&!S||x==="bottom"&&S,_=r.left,N=f[j]-D*v.height):a==="yAxis"&&(D=x==="left"&&!S||x==="right"&&S,_=f[j]-D*v.width,N=r.top);var J=ur(ur(ur({},v),Y),{},{realScaleType:G,x:_,y:N,scale:K,width:a==="xAxis"?r.width:v.width,height:a==="yAxis"?r.height:v.height});return J.bandSize=jh(J,Y),!v.hide&&a==="xAxis"?f[j]+=(D?-1:1)*J.height:v.hide||(f[j]+=(D?-1:1)*J.width),ur(ur({},p),{},cm({},b,J))},{})},tR=function(t,n){var r=t.x,a=t.y,i=n.x,o=n.y;return{x:Math.min(r,i),y:Math.min(a,o),width:Math.abs(i-r),height:Math.abs(o-a)}},Lle=function(t){var n=t.x1,r=t.y1,a=t.x2,i=t.y2;return tR({x:n,y:r},{x:a,y:i})},nR=function(){function e(t){Ple(this,e),this.scale=t}return $le(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]:{},a=r.bandAware,i=r.position;if(n!==void 0){if(i)switch(i){case"start":return this.scale(n);case"middle":{var o=this.bandwidth?this.bandwidth()/2:0;return this.scale(n)+o}case"end":{var l=this.bandwidth?this.bandwidth():0;return this.scale(n)+l}default:return this.scale(n)}if(a){var s=this.bandwidth?this.bandwidth()/2:0;return this.scale(n)+s}return this.scale(n)}}},{key:"isInRange",value:function(n){var r=this.range(),a=r[0],i=r[r.length-1];return a<=i?n>=a&&n<=i:n>=i&&n<=a}}],[{key:"create",value:function(n){return new e(n)}}])}();cm(nR,"EPS",1e-4);var d1=function(t){var n=Object.keys(t).reduce(function(r,a){return ur(ur({},r),{},cm({},a,nR.create(t[a])))},{});return ur(ur({},n),{},{apply:function(a){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},o=i.bandAware,l=i.position;return tle(a,function(s,u){return n[u].apply(s,{bandAware:o,position:l})})},isInRange:function(a){return ple(a,function(i,o){return n[o].isInRange(i)})}})};function zle(e){return(e%180+180)%180}var Ble=function(t){var n=t.width,r=t.height,a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,i=zle(a),o=i*Math.PI/180,l=Math.atan(r/n),s=o>l&&o<Math.PI-l?r/Math.sin(o):n/Math.cos(o);return Math.abs(s)},Ile=YI(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("")}),rR=O.createContext(void 0),aR=O.createContext(void 0),iR=O.createContext(void 0),Ule=O.createContext({}),oR=O.createContext(void 0),lR=O.createContext(0),sR=O.createContext(0),rA=function(t){var n=t.state,r=n.xAxisMap,a=n.yAxisMap,i=n.offset,o=t.clipPathId,l=t.children,s=t.width,u=t.height,d=Ile(i);return $.createElement(rR.Provider,{value:r},$.createElement(aR.Provider,{value:a},$.createElement(Ule.Provider,{value:i},$.createElement(iR.Provider,{value:d},$.createElement(oR.Provider,{value:o},$.createElement(lR.Provider,{value:u},$.createElement(sR.Provider,{value:s},l)))))))},qle=function(){return O.useContext(oR)},uR=function(t){var n=O.useContext(rR);n==null&&co();var r=n[t];return r==null&&co(),r},cR=function(t){var n=O.useContext(aR);n==null&&co();var r=n[t];return r==null&&co(),r},Hle=function(){var t=O.useContext(iR);return t},fR=function(){return O.useContext(sR)},dR=function(){return O.useContext(lR)};function es(e){"@babel/helpers - typeof";return es=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},es(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,pR(r.key),r)}}function Kle(e,t,n){return t&&Gle(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Yle(e,t,n){return t=Uh(t),Vle(e,hR()?Reflect.construct(t,n||[],Uh(e).constructor):t.apply(e,n))}function Vle(e,t){if(t&&(es(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 hR(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(hR=function(){return!!e})()}function Uh(e){return Uh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Uh(e)}function Qle(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&&j0(e,t)}function j0(e,t){return j0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,a){return r.__proto__=a,r},j0(e,t)}function aA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function iA(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?aA(Object(n),!0).forEach(function(r){h1(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):aA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function h1(e,t,n){return t=pR(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function pR(e){var t=Wle(e,"string");return es(t)=="symbol"?t:t+""}function Wle(e,t){if(es(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(es(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function Zle(e,t){return nse(e)||tse(e,t)||ese(e,t)||Jle()}function Jle(){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 ese(e,t){if(e){if(typeof e=="string")return oA(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 oA(e,t)}}function oA(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 tse(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,a,i,o,l=[],s=!0,u=!1;try{if(i=(n=n.call(e)).next,t!==0)for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(d){u=!0,a=d}finally{try{if(!s&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(u)throw a}}return l}}function nse(e){if(Array.isArray(e))return e}function O0(){return O0=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},O0.apply(this,arguments)}var rse=function(t,n){var r;return $.isValidElement(t)?r=$.cloneElement(t,n):se(t)?r=t(n):r=$.createElement("line",O0({},n,{className:"recharts-reference-line-line"})),r},ase=function(t,n,r,a,i,o,l,s,u){var d=i.x,f=i.y,h=i.width,p=i.height;if(r){var b=u.y,v=t.y.apply(b,{position:o});if(Er(u,"discard")&&!t.y.isInRange(v))return null;var x=[{x:d+h,y:v},{x:d,y:v}];return s==="left"?x.reverse():x}if(n){var m=u.x,y=t.x.apply(m,{position:o});if(Er(u,"discard")&&!t.x.isInRange(y))return null;var g=[{x:y,y:f+p},{x:y,y:f}];return l==="top"?g.reverse():g}if(a){var S=u.segment,w=S.map(function(j){return t.apply(j,{position:o})});return Er(u,"discard")&&Yoe(w,function(j){return!t.isInRange(j)})?null:w}return null};function ise(e){var t=e.x,n=e.y,r=e.segment,a=e.xAxisId,i=e.yAxisId,o=e.shape,l=e.className,s=e.alwaysShow,u=qle(),d=uR(a),f=cR(i),h=Hle();if(!u||!h)return null;ra(s===void 0,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.');var p=d1({x:d.scale,y:f.scale}),b=Ot(t),v=Ot(n),x=r&&r.length===2,m=ase(p,b,v,x,h,e.position,d.orientation,f.orientation,e);if(!m)return null;var y=Zle(m,2),g=y[0],S=g.x,w=g.y,j=y[1],A=j.x,E=j.y,_=Er(e,"hidden")?"url(#".concat(u,")"):void 0,N=iA(iA({clipPath:_},oe(e,!0)),{},{x1:S,y1:w,x2:A,y2:E});return $.createElement(ke,{className:ve("recharts-reference-line",l)},rse(o,N),Mt.renderCallByParent(e,Lle({x1:S,y1:w,x2:A,y2:E})))}var p1=function(e){function t(){return Fle(this,t),Yle(this,t,arguments)}return Qle(t,e),Kle(t,[{key:"render",value:function(){return $.createElement(ise,this.props)}}])}($.Component);h1(p1,"displayName","ReferenceLine");h1(p1,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,fill:"none",stroke:"#ccc",fillOpacity:1,strokeWidth:1,position:"middle"});function A0(){return A0=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},A0.apply(this,arguments)}function ts(e){"@babel/helpers - typeof";return ts=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},ts(e)}function lA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function sA(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?lA(Object(n),!0).forEach(function(r){fm(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):lA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function ose(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function lse(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,yR(r.key),r)}}function sse(e,t,n){return t&&lse(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function use(e,t,n){return t=qh(t),cse(e,mR()?Reflect.construct(t,n||[],qh(e).constructor):t.apply(e,n))}function cse(e,t){if(t&&(ts(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return fse(e)}function fse(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function mR(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(mR=function(){return!!e})()}function qh(e){return qh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},qh(e)}function dse(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&&E0(e,t)}function E0(e,t){return E0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,a){return r.__proto__=a,r},E0(e,t)}function fm(e,t,n){return t=yR(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function yR(e){var t=hse(e,"string");return ts(t)=="symbol"?t:t+""}function hse(e,t){if(ts(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(ts(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var pse=function(t){var n=t.x,r=t.y,a=t.xAxis,i=t.yAxis,o=d1({x:a.scale,y:i.scale}),l=o.apply({x:n,y:r},{bandAware:!0});return Er(t,"discard")&&!o.isInRange(l)?null:l},dm=function(e){function t(){return ose(this,t),use(this,t,arguments)}return dse(t,e),sse(t,[{key:"render",value:function(){var r=this.props,a=r.x,i=r.y,o=r.r,l=r.alwaysShow,s=r.clipPathId,u=Ot(a),d=Ot(i);if(ra(l===void 0,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.'),!u||!d)return null;var f=pse(this.props);if(!f)return null;var h=f.x,p=f.y,b=this.props,v=b.shape,x=b.className,m=Er(this.props,"hidden")?"url(#".concat(s,")"):void 0,y=sA(sA({clipPath:m},oe(this.props,!0)),{},{cx:h,cy:p});return $.createElement(ke,{className:ve("recharts-reference-dot",x)},t.renderDot(v,y),Mt.renderCallByParent(this.props,{x:h-o,y:p-o,width:2*o,height:2*o}))}}])}($.Component);fm(dm,"displayName","ReferenceDot");fm(dm,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,r:10,fill:"#fff",stroke:"#ccc",fillOpacity:1,strokeWidth:1});fm(dm,"renderDot",function(e,t){var n;return $.isValidElement(e)?n=$.cloneElement(e,t):se(e)?n=e(t):n=$.createElement(f1,A0({},t,{cx:t.cx,cy:t.cy,className:"recharts-reference-dot-dot"})),n});function _0(){return _0=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},_0.apply(this,arguments)}function ns(e){"@babel/helpers - typeof";return ns=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},ns(e)}function uA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function cA(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?uA(Object(n),!0).forEach(function(r){hm(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):uA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function mse(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,gR(r.key),r)}}function vse(e,t,n){return t&&yse(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function gse(e,t,n){return t=Hh(t),bse(e,vR()?Reflect.construct(t,n||[],Hh(e).constructor):t.apply(e,n))}function bse(e,t){if(t&&(ns(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return xse(e)}function xse(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function vR(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(vR=function(){return!!e})()}function Hh(e){return Hh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Hh(e)}function Sse(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&&T0(e,t)}function T0(e,t){return T0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,a){return r.__proto__=a,r},T0(e,t)}function hm(e,t,n){return t=gR(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function gR(e){var t=wse(e,"string");return ns(t)=="symbol"?t:t+""}function wse(e,t){if(ns(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(ns(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var jse=function(t,n,r,a,i){var o=i.x1,l=i.x2,s=i.y1,u=i.y2,d=i.xAxis,f=i.yAxis;if(!d||!f)return null;var h=d1({x:d.scale,y:f.scale}),p={x:t?h.x.apply(o,{position:"start"}):h.x.rangeMin,y:r?h.y.apply(s,{position:"start"}):h.y.rangeMin},b={x:n?h.x.apply(l,{position:"end"}):h.x.rangeMax,y:a?h.y.apply(u,{position:"end"}):h.y.rangeMax};return Er(i,"discard")&&(!h.isInRange(p)||!h.isInRange(b))?null:tR(p,b)},pm=function(e){function t(){return mse(this,t),gse(this,t,arguments)}return Sse(t,e),vse(t,[{key:"render",value:function(){var r=this.props,a=r.x1,i=r.x2,o=r.y1,l=r.y2,s=r.className,u=r.alwaysShow,d=r.clipPathId;ra(u===void 0,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.');var f=Ot(a),h=Ot(i),p=Ot(o),b=Ot(l),v=this.props.shape;if(!f&&!h&&!p&&!b&&!v)return null;var x=jse(f,h,p,b,this.props);if(!x&&!v)return null;var m=Er(this.props,"hidden")?"url(#".concat(d,")"):void 0;return $.createElement(ke,{className:ve("recharts-reference-area",s)},t.renderRect(v,cA(cA({clipPath:m},oe(this.props,!0)),x)),Mt.renderCallByParent(this.props,x))}}])}($.Component);hm(pm,"displayName","ReferenceArea");hm(pm,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,r:10,fill:"#ccc",fillOpacity:.5,stroke:"none",strokeWidth:1});hm(pm,"renderRect",function(e,t){var n;return $.isValidElement(e)?n=$.cloneElement(e,t):se(e)?n=e(t):n=$.createElement(c1,_0({},t,{className:"recharts-reference-area-rect"})),n});function bR(e,t,n){if(t<1)return[];if(t===1&&n===void 0)return e;for(var r=[],a=0;a<e.length;a+=t)r.push(e[a]);return r}function Ose(e,t,n){var r={width:e.width+t.width,height:e.height+t.height};return Ble(r,n)}function Ase(e,t,n){var r=n==="width",a=e.x,i=e.y,o=e.width,l=e.height;return t===1?{start:r?a:i,end:r?a+o:i+l}:{start:r?a+o:i+l,end:r?a:i}}function Fh(e,t,n,r,a){if(e*t<e*r||e*t>e*a)return!1;var i=n();return e*(t-e*i/2-r)>=0&&e*(t+e*i/2-a)<=0}function Ese(e,t){return bR(e,t+1)}function _se(e,t,n,r,a){for(var i=(r||[]).slice(),o=t.start,l=t.end,s=0,u=1,d=o,f=function(){var b=r==null?void 0:r[s];if(b===void 0)return{v:bR(r,u)};var v=s,x,m=function(){return x===void 0&&(x=n(b,v)),x},y=b.coordinate,g=s===0||Fh(e,y,m,d,l);g||(s=0,d=o,u+=1),g&&(d=y+e*(m()/2+a),s+=u)},h;u<=i.length;)if(h=f(),h)return h.v;return[]}function Oc(e){"@babel/helpers - typeof";return Oc=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},Oc(e)}function fA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function Gt(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?fA(Object(n),!0).forEach(function(r){Tse(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):fA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Tse(e,t,n){return t=Nse(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Nse(e){var t=Cse(e,"string");return Oc(t)=="symbol"?t:t+""}function Cse(e,t){if(Oc(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Oc(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Mse(e,t,n,r,a){for(var i=(r||[]).slice(),o=i.length,l=t.start,s=t.end,u=function(h){var p=i[h],b,v=function(){return b===void 0&&(b=n(p,h)),b};if(h===o-1){var x=e*(p.coordinate+e*v()/2-s);i[h]=p=Gt(Gt({},p),{},{tickCoord:x>0?p.coordinate-x*e:p.coordinate})}else i[h]=p=Gt(Gt({},p),{},{tickCoord:p.coordinate});var m=Fh(e,p.tickCoord,v,l,s);m&&(s=p.tickCoord-e*(v()/2+a),i[h]=Gt(Gt({},p),{},{isShow:!0}))},d=o-1;d>=0;d--)u(d);return i}function Rse(e,t,n,r,a,i){var o=(r||[]).slice(),l=o.length,s=t.start,u=t.end;if(i){var d=r[l-1],f=n(d,l-1),h=e*(d.coordinate+e*f/2-u);o[l-1]=d=Gt(Gt({},d),{},{tickCoord:h>0?d.coordinate-h*e:d.coordinate});var p=Fh(e,d.tickCoord,function(){return f},s,u);p&&(u=d.tickCoord-e*(f/2+a),o[l-1]=Gt(Gt({},d),{},{isShow:!0}))}for(var b=i?l-1:l,v=function(y){var g=o[y],S,w=function(){return S===void 0&&(S=n(g,y)),S};if(y===0){var j=e*(g.coordinate-e*w()/2-s);o[y]=g=Gt(Gt({},g),{},{tickCoord:j<0?g.coordinate-j*e:g.coordinate})}else o[y]=g=Gt(Gt({},g),{},{tickCoord:g.coordinate});var A=Fh(e,g.tickCoord,w,s,u);A&&(s=g.tickCoord+e*(w()/2+a),o[y]=Gt(Gt({},g),{},{isShow:!0}))},x=0;x<b;x++)v(x);return o}function Pse(e,t,n){var r=e.tick,a=e.ticks,i=e.viewBox,o=e.minTickGap,l=e.orientation,s=e.interval,u=e.tickFormatter,d=e.unit,f=e.angle;if(!a||!a.length||!r)return[];if(V(s)||Rs.isSsr)return Ese(a,typeof s=="number"&&V(s)?s:0);var h=[],p=l==="top"||l==="bottom"?"width":"height",b=d&&p==="width"?wu(d,{fontSize:t,letterSpacing:n}):{width:0,height:0},v=function(g,S){var w=se(u)?u(g.value,S):g.value;return p==="width"?Ose(wu(w,{fontSize:t,letterSpacing:n}),b,f):wu(w,{fontSize:t,letterSpacing:n})[p]},x=a.length>=2?Jt(a[1].coordinate-a[0].coordinate):1,m=Ase(i,x,p);return s==="equidistantPreserveStart"?_se(x,m,v,a,o):(s==="preserveStart"||s==="preserveStartEnd"?h=Rse(x,m,v,a,o,s==="preserveStartEnd"):h=Mse(x,m,v,a,o),h.filter(function(y){return y.isShow}))}var $se=["viewBox"],kse=["viewBox"],Dse=["ticks"];function rs(e){"@babel/helpers - typeof";return rs=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},rs(e)}function Qo(){return Qo=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},Qo.apply(this,arguments)}function dA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function xt(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?dA(Object(n),!0).forEach(function(r){m1(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):dA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Dy(e,t){if(e==null)return{};var n=Lse(e,t),r,a;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(a=0;a<i.length;a++)r=i[a],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Lse(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 zse(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function hA(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,SR(r.key),r)}}function Bse(e,t,n){return t&&hA(e.prototype,t),n&&hA(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Ise(e,t,n){return t=Gh(t),Use(e,xR()?Reflect.construct(t,n||[],Gh(e).constructor):t.apply(e,n))}function Use(e,t){if(t&&(rs(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 xR(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(xR=function(){return!!e})()}function Gh(e){return Gh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Gh(e)}function Hse(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&&N0(e,t)}function N0(e,t){return N0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,a){return r.__proto__=a,r},N0(e,t)}function m1(e,t,n){return t=SR(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function SR(e){var t=Fse(e,"string");return rs(t)=="symbol"?t:t+""}function Fse(e,t){if(rs(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(rs(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var mm=function(e){function t(n){var r;return zse(this,t),r=Ise(this,t,[n]),r.state={fontSize:"",letterSpacing:""},r}return Hse(t,e),Bse(t,[{key:"shouldComponentUpdate",value:function(r,a){var i=r.viewBox,o=Dy(r,$se),l=this.props,s=l.viewBox,u=Dy(l,kse);return!ol(i,s)||!ol(o,u)||!ol(a,this.state)}},{key:"componentDidMount",value:function(){var r=this.layerReference;if(r){var a=r.getElementsByClassName("recharts-cartesian-axis-tick-value")[0];a&&this.setState({fontSize:window.getComputedStyle(a).fontSize,letterSpacing:window.getComputedStyle(a).letterSpacing})}}},{key:"getTickLineCoord",value:function(r){var a=this.props,i=a.x,o=a.y,l=a.width,s=a.height,u=a.orientation,d=a.tickSize,f=a.mirror,h=a.tickMargin,p,b,v,x,m,y,g=f?-1:1,S=r.tickSize||d,w=V(r.tickCoord)?r.tickCoord:r.coordinate;switch(u){case"top":p=b=r.coordinate,x=o+ +!f*s,v=x-g*S,y=v-g*h,m=w;break;case"left":v=x=r.coordinate,b=i+ +!f*l,p=b-g*S,m=p-g*h,y=w;break;case"right":v=x=r.coordinate,b=i+ +f*l,p=b+g*S,m=p+g*h,y=w;break;default:p=b=r.coordinate,x=o+ +f*s,v=x+g*S,y=v+g*h,m=w;break}return{line:{x1:p,y1:v,x2:b,y2:x},tick:{x:m,y}}}},{key:"getTickTextAnchor",value:function(){var r=this.props,a=r.orientation,i=r.mirror,o;switch(a){case"left":o=i?"start":"end";break;case"right":o=i?"end":"start";break;default:o="middle";break}return o}},{key:"getTickVerticalAnchor",value:function(){var r=this.props,a=r.orientation,i=r.mirror,o="end";switch(a){case"left":case"right":o="middle";break;case"top":o=i?"start":"end";break;default:o=i?"end":"start";break}return o}},{key:"renderAxisLine",value:function(){var r=this.props,a=r.x,i=r.y,o=r.width,l=r.height,s=r.orientation,u=r.mirror,d=r.axisLine,f=xt(xt(xt({},oe(this.props,!1)),oe(d,!1)),{},{fill:"none"});if(s==="top"||s==="bottom"){var h=+(s==="top"&&!u||s==="bottom"&&u);f=xt(xt({},f),{},{x1:a,y1:i+h*l,x2:a+o,y2:i+h*l})}else{var p=+(s==="left"&&!u||s==="right"&&u);f=xt(xt({},f),{},{x1:a+p*o,y1:i,x2:a+p*o,y2:i+l})}return $.createElement("line",Qo({},f,{className:ve("recharts-cartesian-axis-line",Rn(d,"className"))}))}},{key:"renderTicks",value:function(r,a,i){var o=this,l=this.props,s=l.tickLine,u=l.stroke,d=l.tick,f=l.tickFormatter,h=l.unit,p=Pse(xt(xt({},this.props),{},{ticks:r}),a,i),b=this.getTickTextAnchor(),v=this.getTickVerticalAnchor(),x=oe(this.props,!1),m=oe(d,!1),y=xt(xt({},x),{},{fill:"none"},oe(s,!1)),g=p.map(function(S,w){var j=o.getTickLineCoord(S),A=j.line,E=j.tick,_=xt(xt(xt(xt({textAnchor:b,verticalAnchor:v},x),{},{stroke:"none",fill:u},m),E),{},{index:w,payload:S,visibleTicksCount:p.length,tickFormatter:f});return $.createElement(ke,Qo({className:"recharts-cartesian-axis-tick",key:"tick-".concat(S.value,"-").concat(S.coordinate,"-").concat(S.tickCoord)},lo(o.props,S,w)),s&&$.createElement("line",Qo({},y,A,{className:ve("recharts-cartesian-axis-tick-line",Rn(s,"className"))})),d&&t.renderTickItem(d,_,"".concat(se(f)?f(S.value,w):S.value).concat(h||"")))});return $.createElement("g",{className:"recharts-cartesian-axis-ticks"},g)}},{key:"render",value:function(){var r=this,a=this.props,i=a.axisLine,o=a.width,l=a.height,s=a.ticksGenerator,u=a.className,d=a.hide;if(d)return null;var f=this.props,h=f.ticks,p=Dy(f,Dse),b=h;return se(s)&&(b=h&&h.length>0?s(this.props):s(p)),o<=0||l<=0||!b||!b.length?null:$.createElement(ke,{className:ve("recharts-cartesian-axis",u),ref:function(x){r.layerReference=x}},i&&this.renderAxisLine(),this.renderTicks(b,this.state.fontSize,this.state.letterSpacing),Mt.renderCallByParent(this.props))}}],[{key:"renderTickItem",value:function(r,a,i){var o,l=ve(a.className,"recharts-cartesian-axis-tick-value");return $.isValidElement(r)?o=$.cloneElement(r,xt(xt({},a),{},{className:l})):se(r)?o=r(xt(xt({},a),{},{className:l})):o=$.createElement(so,Qo({},a,{className:"recharts-cartesian-axis-tick-value"}),i),o}}])}(O.Component);m1(mm,"displayName","CartesianAxis");m1(mm,"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"});function as(e){"@babel/helpers - typeof";return as=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},as(e)}function Gse(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Kse(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,OR(r.key),r)}}function Yse(e,t,n){return t&&Kse(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Vse(e,t,n){return t=Kh(t),Xse(e,wR()?Reflect.construct(t,n||[],Kh(e).constructor):t.apply(e,n))}function Xse(e,t){if(t&&(as(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 wR(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(wR=function(){return!!e})()}function Kh(e){return Kh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Kh(e)}function Wse(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&&C0(e,t)}function C0(e,t){return C0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,a){return r.__proto__=a,r},C0(e,t)}function jR(e,t,n){return t=OR(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function OR(e){var t=Zse(e,"string");return as(t)=="symbol"?t:t+""}function Zse(e,t){if(as(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(as(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function M0(){return M0=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},M0.apply(this,arguments)}function Jse(e){var t=e.xAxisId,n=fR(),r=dR(),a=uR(t);return a==null?null:O.createElement(mm,M0({},a,{className:ve("recharts-".concat(a.axisType," ").concat(a.axisType),a.className),viewBox:{x:0,y:0,width:n,height:r},ticksGenerator:function(o){return $i(o,!0)}}))}var ym=function(e){function t(){return Gse(this,t),Vse(this,t,arguments)}return Wse(t,e),Yse(t,[{key:"render",value:function(){return O.createElement(Jse,this.props)}}])}(O.Component);jR(ym,"displayName","XAxis");jR(ym,"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 is(e){"@babel/helpers - typeof";return is=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},is(e)}function eue(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function tue(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,_R(r.key),r)}}function nue(e,t,n){return t&&tue(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function rue(e,t,n){return t=Yh(t),aue(e,AR()?Reflect.construct(t,n||[],Yh(e).constructor):t.apply(e,n))}function aue(e,t){if(t&&(is(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return iue(e)}function iue(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function AR(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(AR=function(){return!!e})()}function Yh(e){return Yh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Yh(e)}function oue(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&&R0(e,t)}function R0(e,t){return R0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,a){return r.__proto__=a,r},R0(e,t)}function ER(e,t,n){return t=_R(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function _R(e){var t=lue(e,"string");return is(t)=="symbol"?t:t+""}function lue(e,t){if(is(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(is(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function P0(){return P0=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},P0.apply(this,arguments)}var sue=function(t){var n=t.yAxisId,r=fR(),a=dR(),i=cR(n);return i==null?null:O.createElement(mm,P0({},i,{className:ve("recharts-".concat(i.axisType," ").concat(i.axisType),i.className),viewBox:{x:0,y:0,width:r,height:a},ticksGenerator:function(l){return $i(l,!0)}}))},vm=function(e){function t(){return eue(this,t),rue(this,t,arguments)}return oue(t,e),nue(t,[{key:"render",value:function(){return O.createElement(sue,this.props)}}])}(O.Component);ER(vm,"displayName","YAxis");ER(vm,"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 pA(e){return due(e)||fue(e)||cue(e)||uue()}function uue(){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 cue(e,t){if(e){if(typeof e=="string")return $0(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 $0(e,t)}}function fue(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function due(e){if(Array.isArray(e))return $0(e)}function $0(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 k0=function(t,n,r,a,i){var o=Wn(t,p1),l=Wn(t,dm),s=[].concat(pA(o),pA(l)),u=Wn(t,pm),d="".concat(a,"Id"),f=a[0],h=n;if(s.length&&(h=s.reduce(function(v,x){if(x.props[d]===r&&Er(x.props,"extendDomain")&&V(x.props[f])){var m=x.props[f];return[Math.min(v[0],m),Math.max(v[1],m)]}return v},h)),u.length){var p="".concat(f,"1"),b="".concat(f,"2");h=u.reduce(function(v,x){if(x.props[d]===r&&Er(x.props,"extendDomain")&&V(x.props[p])&&V(x.props[b])){var m=x.props[p],y=x.props[b];return[Math.min(v[0],m,y),Math.max(v[1],m,y)]}return v},h)}return i&&i.length&&(h=i.reduce(function(v,x){return V(x)?[Math.min(v[0],x),Math.max(v[1],x)]:v},h)),h},TR={exports:{}};(function(e){var t=Object.prototype.hasOwnProperty,n="~";function r(){}Object.create&&(r.prototype=Object.create(null),new r().__proto__||(n=!1));function a(s,u,d){this.fn=s,this.context=u,this.once=d||!1}function i(s,u,d,f,h){if(typeof d!="function")throw new TypeError("The listener must be a function");var p=new a(d,f||s,h),b=n?n+u:u;return s._events[b]?s._events[b].fn?s._events[b]=[s._events[b],p]:s._events[b].push(p):(s._events[b]=p,s._eventsCount++),s}function o(s,u){--s._eventsCount===0?s._events=new r:delete s._events[u]}function l(){this._events=new r,this._eventsCount=0}l.prototype.eventNames=function(){var u=[],d,f;if(this._eventsCount===0)return u;for(f in d=this._events)t.call(d,f)&&u.push(n?f.slice(1):f);return Object.getOwnPropertySymbols?u.concat(Object.getOwnPropertySymbols(d)):u},l.prototype.listeners=function(u){var d=n?n+u:u,f=this._events[d];if(!f)return[];if(f.fn)return[f.fn];for(var h=0,p=f.length,b=new Array(p);h<p;h++)b[h]=f[h].fn;return b},l.prototype.listenerCount=function(u){var d=n?n+u:u,f=this._events[d];return f?f.fn?1:f.length:0},l.prototype.emit=function(u,d,f,h,p,b){var v=n?n+u:u;if(!this._events[v])return!1;var x=this._events[v],m=arguments.length,y,g;if(x.fn){switch(x.once&&this.removeListener(u,x.fn,void 0,!0),m){case 1:return x.fn.call(x.context),!0;case 2:return x.fn.call(x.context,d),!0;case 3:return x.fn.call(x.context,d,f),!0;case 4:return x.fn.call(x.context,d,f,h),!0;case 5:return x.fn.call(x.context,d,f,h,p),!0;case 6:return x.fn.call(x.context,d,f,h,p,b),!0}for(g=1,y=new Array(m-1);g<m;g++)y[g-1]=arguments[g];x.fn.apply(x.context,y)}else{var S=x.length,w;for(g=0;g<S;g++)switch(x[g].once&&this.removeListener(u,x[g].fn,void 0,!0),m){case 1:x[g].fn.call(x[g].context);break;case 2:x[g].fn.call(x[g].context,d);break;case 3:x[g].fn.call(x[g].context,d,f);break;case 4:x[g].fn.call(x[g].context,d,f,h);break;default:if(!y)for(w=1,y=new Array(m-1);w<m;w++)y[w-1]=arguments[w];x[g].fn.apply(x[g].context,y)}}return!0},l.prototype.on=function(u,d,f){return i(this,u,d,f,!1)},l.prototype.once=function(u,d,f){return i(this,u,d,f,!0)},l.prototype.removeListener=function(u,d,f,h){var p=n?n+u:u;if(!this._events[p])return this;if(!d)return o(this,p),this;var b=this._events[p];if(b.fn)b.fn===d&&(!h||b.once)&&(!f||b.context===f)&&o(this,p);else{for(var v=0,x=[],m=b.length;v<m;v++)(b[v].fn!==d||h&&!b[v].once||f&&b[v].context!==f)&&x.push(b[v]);x.length?this._events[p]=x.length===1?x[0]:x:o(this,p)}return this},l.prototype.removeAllListeners=function(u){var d;return u?(d=n?n+u:u,this._events[d]&&o(this,d)):(this._events=new r,this._eventsCount=0),this},l.prototype.off=l.prototype.removeListener,l.prototype.addListener=l.prototype.on,l.prefixed=n,l.EventEmitter=l,e.exports=l})(TR);var hue=TR.exports;const pue=qe(hue);var Ly=new pue,zy="recharts.syncMouseEvents";function Ac(e){"@babel/helpers - typeof";return Ac=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},Ac(e)}function mue(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function yue(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,NR(r.key),r)}}function vue(e,t,n){return t&&yue(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function By(e,t,n){return t=NR(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function NR(e){var t=gue(e,"string");return Ac(t)=="symbol"?t:t+""}function gue(e,t){if(Ac(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Ac(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var bue=function(){function e(){mue(this,e),By(this,"activeIndex",0),By(this,"coordinateList",[]),By(this,"layout","horizontal")}return vue(e,[{key:"setDetails",value:function(n){var r,a=n.coordinateList,i=a===void 0?null:a,o=n.container,l=o===void 0?null:o,s=n.layout,u=s===void 0?null:s,d=n.offset,f=d===void 0?null:d,h=n.mouseHandlerCallback,p=h===void 0?null:h;this.coordinateList=(r=i??this.coordinateList)!==null&&r!==void 0?r:[],this.container=l??this.container,this.layout=u??this.layout,this.offset=f??this.offset,this.mouseHandlerCallback=p??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 a=this.container.getBoundingClientRect(),i=a.x,o=a.y,l=a.height,s=this.coordinateList[this.activeIndex].coordinate,u=((n=window)===null||n===void 0?void 0:n.scrollX)||0,d=((r=window)===null||r===void 0?void 0:r.scrollY)||0,f=i+s+u,h=o+this.offset.top+l/2+d;this.mouseHandlerCallback({pageX:f,pageY:h})}}}])}();function xue(e,t,n){if(n==="number"&&t===!0&&Array.isArray(e)){var r=e==null?void 0:e[0],a=e==null?void 0:e[1];if(r&&a&&V(r)&&V(a))return!0}return!1}function Sue(e,t,n,r){var a=r/2;return{stroke:"none",fill:"#ccc",x:e==="horizontal"?t.x-a:n.left+.5,y:e==="horizontal"?n.top+.5:t.y-a,width:e==="horizontal"?r:n.width-1,height:e==="horizontal"?n.height-1:r}}function CR(e){var t=e.cx,n=e.cy,r=e.radius,a=e.startAngle,i=e.endAngle,o=Ve(t,n,r,a),l=Ve(t,n,r,i);return{points:[o,l],cx:t,cy:n,radius:r,startAngle:a,endAngle:i}}function wue(e,t,n){var r,a,i,o;if(e==="horizontal")r=t.x,i=r,a=n.top,o=n.top+n.height;else if(e==="vertical")a=t.y,o=a,r=n.left,i=n.left+n.width;else if(t.cx!=null&&t.cy!=null)if(e==="centric"){var l=t.cx,s=t.cy,u=t.innerRadius,d=t.outerRadius,f=t.angle,h=Ve(l,s,u,f),p=Ve(l,s,d,f);r=h.x,a=h.y,i=p.x,o=p.y}else return CR(t);return[{x:r,y:a},{x:i,y:o}]}function Ec(e){"@babel/helpers - typeof";return Ec=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},Ec(e)}function mA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function Uf(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?mA(Object(n),!0).forEach(function(r){jue(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):mA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function jue(e,t,n){return t=Oue(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Oue(e){var t=Aue(e,"string");return Ec(t)=="symbol"?t:t+""}function Aue(e,t){if(Ec(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Ec(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Eue(e){var t,n,r=e.element,a=e.tooltipEventType,i=e.isActive,o=e.activeCoordinate,l=e.activePayload,s=e.offset,u=e.activeTooltipIndex,d=e.tooltipAxisBandSize,f=e.layout,h=e.chartName,p=(t=r.props.cursor)!==null&&t!==void 0?t:(n=r.type.defaultProps)===null||n===void 0?void 0:n.cursor;if(!r||!p||!i||!o||h!=="ScatterChart"&&a!=="axis")return null;var b,v=a0;if(h==="ScatterChart")b=o,v=$ae;else if(h==="BarChart")b=Sue(f,o,s,d),v=c1;else if(f==="radial"){var x=CR(o),m=x.cx,y=x.cy,g=x.radius,S=x.startAngle,w=x.endAngle;b={cx:m,cy:y,startAngle:S,endAngle:w,innerRadius:g,outerRadius:g},v=N3}else b={points:wue(f,o,s)},v=a0;var j=Uf(Uf(Uf(Uf({stroke:"#ccc",pointerEvents:"none"},s),b),oe(p,!1)),{},{payload:l,payloadIndex:u,className:ve("recharts-tooltip-cursor",p.className)});return O.isValidElement(p)?O.cloneElement(p,j):O.createElement(v,j)}var _ue=["item"],Tue=["children","className","width","height","style","compact","title","desc"];function os(e){"@babel/helpers - typeof";return os=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},os(e)}function Wo(){return Wo=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},Wo.apply(this,arguments)}function yA(e,t){return Mue(e)||Cue(e,t)||RR(e,t)||Nue()}function Nue(){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 Cue(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,a,i,o,l=[],s=!0,u=!1;try{if(i=(n=n.call(e)).next,t!==0)for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(d){u=!0,a=d}finally{try{if(!s&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(u)throw a}}return l}}function Mue(e){if(Array.isArray(e))return e}function vA(e,t){if(e==null)return{};var n=Rue(e,t),r,a;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(a=0;a<i.length;a++)r=i[a],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Rue(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 Pue(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function $ue(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,PR(r.key),r)}}function kue(e,t,n){return t&&$ue(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Due(e,t,n){return t=Vh(t),Lue(e,MR()?Reflect.construct(t,n||[],Vh(e).constructor):t.apply(e,n))}function Lue(e,t){if(t&&(os(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return zue(e)}function zue(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function MR(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(MR=function(){return!!e})()}function Vh(e){return Vh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Vh(e)}function Bue(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&&D0(e,t)}function D0(e,t){return D0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,a){return r.__proto__=a,r},D0(e,t)}function ls(e){return que(e)||Uue(e)||RR(e)||Iue()}function Iue(){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 RR(e,t){if(e){if(typeof e=="string")return L0(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 L0(e,t)}}function Uue(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function que(e){if(Array.isArray(e))return L0(e)}function L0(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 gA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,r)}return n}function I(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?gA(Object(n),!0).forEach(function(r){ae(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):gA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function ae(e,t,n){return t=PR(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function PR(e){var t=Hue(e,"string");return os(t)=="symbol"?t:t+""}function Hue(e,t){if(os(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(os(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Fue={xAxis:["bottom","top"],yAxis:["left","right"]},Gue={width:"100%",height:"100%"},$R={x:0,y:0};function qf(e){return e}var Kue=function(t,n){return n==="horizontal"?t.x:n==="vertical"?t.y:n==="centric"?t.angle:t.radius},Yue=function(t,n,r,a){var i=n.find(function(d){return d&&d.index===r});if(i){if(t==="horizontal")return{x:i.coordinate,y:a.y};if(t==="vertical")return{x:a.x,y:i.coordinate};if(t==="centric"){var o=i.coordinate,l=a.radius;return I(I(I({},a),Ve(a.cx,a.cy,l,o)),{},{angle:o,radius:l})}var s=i.coordinate,u=a.angle;return I(I(I({},a),Ve(a.cx,a.cy,s,u)),{},{angle:u,radius:s})}return $R},gm=function(t,n){var r=n.graphicalItems,a=n.dataStartIndex,i=n.dataEndIndex,o=(r??[]).reduce(function(l,s){var u=s.props.data;return u&&u.length?[].concat(ls(l),ls(u)):l},[]);return o.length>0?o:t&&t.length&&V(a)&&V(i)?t.slice(a,i+1):[]};function kR(e){return e==="number"?[0,"auto"]:void 0}var z0=function(t,n,r,a){var i=t.graphicalItems,o=t.tooltipAxis,l=gm(n,t);return r<0||!i||!i.length||r>=l.length?null:i.reduce(function(s,u){var d,f=(d=u.props.data)!==null&&d!==void 0?d:n;f&&t.dataStartIndex+t.dataEndIndex!==0&&t.dataEndIndex-t.dataStartIndex>=r&&(f=f.slice(t.dataStartIndex,t.dataEndIndex+1));var h;if(o.dataKey&&!o.allowDuplicatedCategory){var p=f===void 0?l:f;h=dg(p,o.dataKey,a)}else h=f&&f[r]||l[r];return h?[].concat(ls(s),[j3(u,h)]):s},[])},bA=function(t,n,r,a){var i=a||{x:t.chartX,y:t.chartY},o=Kue(i,r),l=t.orderedTooltipTicks,s=t.tooltipAxis,u=t.tooltipTicks,d=ete(o,l,u,s);if(d>=0&&u){var f=u[d]&&u[d].value,h=z0(t,n,d,f),p=Yue(r,l,d,i);return{activeTooltipIndex:d,activeLabel:f,activePayload:h,activeCoordinate:p}}return null},Vue=function(t,n){var r=n.axes,a=n.graphicalItems,i=n.axisType,o=n.axisIdKey,l=n.stackGroups,s=n.dataStartIndex,u=n.dataEndIndex,d=t.layout,f=t.children,h=t.stackOffset,p=g3(d,i);return r.reduce(function(b,v){var x,m=v.type.defaultProps!==void 0?I(I({},v.type.defaultProps),v.props):v.props,y=m.type,g=m.dataKey,S=m.allowDataOverflow,w=m.allowDuplicatedCategory,j=m.scale,A=m.ticks,E=m.includeHidden,_=m[o];if(b[_])return b;var N=gm(t.data,{graphicalItems:a.filter(function(Y){var J,me=o in Y.props?Y.props[o]:(J=Y.type.defaultProps)===null||J===void 0?void 0:J[o];return me===_}),dataStartIndex:s,dataEndIndex:u}),D=N.length,R,B,k;xue(m.domain,S,y)&&(R=Jg(m.domain,null,S),p&&(y==="number"||j!=="auto")&&(k=Ou(N,g,"category")));var C=kR(y);if(!R||R.length===0){var M,L=(M=m.domain)!==null&&M!==void 0?M:C;if(g){if(R=Ou(N,g,y),y==="category"&&p){var z=HU(R);w&&z?(B=R,R=Dh(0,D)):w||(R=X2(L,R,v).reduce(function(Y,J){return Y.indexOf(J)>=0?Y:[].concat(ls(Y),[J])},[]))}else if(y==="category")w?R=R.filter(function(Y){return Y!==""&&!ge(Y)}):R=X2(L,R,v).reduce(function(Y,J){return Y.indexOf(J)>=0||J===""||ge(J)?Y:[].concat(ls(Y),[J])},[]);else if(y==="number"){var F=ite(N,a.filter(function(Y){var J,me,Le=o in Y.props?Y.props[o]:(J=Y.type.defaultProps)===null||J===void 0?void 0:J[o],ce="hide"in Y.props?Y.props.hide:(me=Y.type.defaultProps)===null||me===void 0?void 0:me.hide;return Le===_&&(E||!ce)}),g,i,d);F&&(R=F)}p&&(y==="number"||j!=="auto")&&(k=Ou(N,g,"category"))}else p?R=Dh(0,D):l&&l[_]&&l[_].hasStack&&y==="number"?R=h==="expand"?[0,1]:w3(l[_].stackGroups,s,u):R=v3(N,a.filter(function(Y){var J=o in Y.props?Y.props[o]:Y.type.defaultProps[o],me="hide"in Y.props?Y.props.hide:Y.type.defaultProps.hide;return J===_&&(E||!me)}),y,d,!0);if(y==="number")R=k0(f,R,_,i,A),L&&(R=Jg(L,R,S));else if(y==="category"&&L){var K=L,G=R.every(function(Y){return K.indexOf(Y)>=0});G&&(R=K)}}return I(I({},b),{},ae({},_,I(I({},m),{},{axisType:i,domain:R,categoricalDomain:k,duplicateDomain:B,originalDomain:(x=m.domain)!==null&&x!==void 0?x:C,isCategorical:p,layout:d})))},{})},Xue=function(t,n){var r=n.graphicalItems,a=n.Axis,i=n.axisType,o=n.axisIdKey,l=n.stackGroups,s=n.dataStartIndex,u=n.dataEndIndex,d=t.layout,f=t.children,h=gm(t.data,{graphicalItems:r,dataStartIndex:s,dataEndIndex:u}),p=h.length,b=g3(d,i),v=-1;return r.reduce(function(x,m){var y=m.type.defaultProps!==void 0?I(I({},m.type.defaultProps),m.props):m.props,g=y[o],S=kR("number");if(!x[g]){v++;var w;return b?w=Dh(0,p):l&&l[g]&&l[g].hasStack?(w=w3(l[g].stackGroups,s,u),w=k0(f,w,g,i)):(w=Jg(S,v3(h,r.filter(function(j){var A,E,_=o in j.props?j.props[o]:(A=j.type.defaultProps)===null||A===void 0?void 0:A[o],N="hide"in j.props?j.props.hide:(E=j.type.defaultProps)===null||E===void 0?void 0:E.hide;return _===g&&!N}),"number",d),a.defaultProps.allowDataOverflow),w=k0(f,w,g,i)),I(I({},x),{},ae({},g,I(I({axisType:i},a.defaultProps),{},{hide:!0,orientation:Rn(Fue,"".concat(i,".").concat(v%2),null),domain:w,originalDomain:S,isCategorical:b,layout:d})))}return x},{})},Que=function(t,n){var r=n.axisType,a=r===void 0?"xAxis":r,i=n.AxisComp,o=n.graphicalItems,l=n.stackGroups,s=n.dataStartIndex,u=n.dataEndIndex,d=t.children,f="".concat(a,"Id"),h=Wn(d,i),p={};return h&&h.length?p=Vue(t,{axes:h,graphicalItems:o,axisType:a,axisIdKey:f,stackGroups:l,dataStartIndex:s,dataEndIndex:u}):o&&o.length&&(p=Xue(t,{Axis:i,graphicalItems:o,axisType:a,axisIdKey:f,stackGroups:l,dataStartIndex:s,dataEndIndex:u})),p},Wue=function(t){var n=$o(t),r=$i(n,!1,!0);return{tooltipTicks:r,orderedTooltipTicks:Lx(r,function(a){return a.coordinate}),tooltipAxis:n,tooltipAxisBandSize:jh(n,r)}},xA=function(t){var n=t.children,r=t.defaultShowTooltip,a=Sn(n,Zl),i=0,o=0;return t.data&&t.data.length!==0&&(o=t.data.length-1),a&&a.props&&(a.props.startIndex>=0&&(i=a.props.startIndex),a.props.endIndex>=0&&(o=a.props.endIndex)),{chartX:0,chartY:0,dataStartIndex:i,dataEndIndex:o,activeTooltipIndex:-1,isTooltipActive:!!r}},Zue=function(t){return!t||!t.length?!1:t.some(function(n){var r=na(n&&n.type);return r&&r.indexOf("Bar")>=0})},SA=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"}},Jue=function(t,n){var r=t.props,a=t.graphicalItems,i=t.xAxisMap,o=i===void 0?{}:i,l=t.yAxisMap,s=l===void 0?{}:l,u=r.width,d=r.height,f=r.children,h=r.margin||{},p=Sn(f,Zl),b=Sn(f,ll),v=Object.keys(s).reduce(function(w,j){var A=s[j],E=A.orientation;return!A.mirror&&!A.hide?I(I({},w),{},ae({},E,w[E]+A.width)):w},{left:h.left||0,right:h.right||0}),x=Object.keys(o).reduce(function(w,j){var A=o[j],E=A.orientation;return!A.mirror&&!A.hide?I(I({},w),{},ae({},E,Rn(w,"".concat(E))+A.height)):w},{top:h.top||0,bottom:h.bottom||0}),m=I(I({},x),v),y=m.bottom;p&&(m.bottom+=p.props.height||Zl.defaultProps.height),b&&n&&(m=rte(m,a,r,n));var g=u-m.left-m.right,S=d-m.top-m.bottom;return I(I({brushBottom:y},m),{},{width:Math.max(g,0),height:Math.max(S,0)})},ece=function(t,n){if(n==="xAxis")return t[n].width;if(n==="yAxis")return t[n].height},DR=function(t){var n=t.chartName,r=t.GraphicalChild,a=t.defaultTooltipEventType,i=a===void 0?"axis":a,o=t.validateTooltipEventTypes,l=o===void 0?["axis"]:o,s=t.axisComponents,u=t.legendContent,d=t.formatAxisMap,f=t.defaultProps,h=function(m,y){var g=y.graphicalItems,S=y.stackGroups,w=y.offset,j=y.updateId,A=y.dataStartIndex,E=y.dataEndIndex,_=m.barSize,N=m.layout,D=m.barGap,R=m.barCategoryGap,B=m.maxBarSize,k=SA(N),C=k.numericAxisName,M=k.cateAxisName,L=Zue(g),z=[];return g.forEach(function(F,K){var G=gm(m.data,{graphicalItems:[F],dataStartIndex:A,dataEndIndex:E}),Y=F.type.defaultProps!==void 0?I(I({},F.type.defaultProps),F.props):F.props,J=Y.dataKey,me=Y.maxBarSize,Le=Y["".concat(C,"Id")],ce=Y["".concat(M,"Id")],$t={},bt=s.reduce(function(Pr,gn){var bm=y["".concat(gn.axisType,"Map")],g1=Y["".concat(gn.axisType,"Id")];bm&&bm[g1]||gn.axisType==="zAxis"||co();var b1=bm[g1];return I(I({},Pr),{},ae(ae({},gn.axisType,b1),"".concat(gn.axisType,"Ticks"),$i(b1)))},$t),Q=bt[M],le=bt["".concat(M,"Ticks")],fe=S&&S[Le]&&S[Le].hasStack&&pte(F,S[Le].stackGroups),q=na(F.type).indexOf("Bar")>=0,Xe=jh(Q,le),be=[],Re=L&&tte({barSize:_,stackGroups:S,totalSize:ece(bt,M)});if(q){var te,ze,kt=ge(me)?B:me,an=(te=(ze=jh(Q,le,!0))!==null&&ze!==void 0?ze:kt)!==null&&te!==void 0?te:0;be=nte({barGap:D,barCategoryGap:R,bandSize:an!==Xe?an:Xe,sizeList:Re[ce],maxBarSize:kt}),an!==Xe&&(be=be.map(function(Pr){return I(I({},Pr),{},{position:I(I({},Pr.position),{},{offset:Pr.position.offset-an/2})})}))}var yi=F&&F.type&&F.type.getComposedData;yi&&z.push({props:I(I({},yi(I(I({},bt),{},{displayedData:G,props:m,dataKey:J,item:F,bandSize:Xe,barPosition:be,offset:w,stackedData:fe,layout:N,dataStartIndex:A,dataEndIndex:E}))),{},ae(ae(ae({key:F.key||"item-".concat(K)},C,bt[C]),M,bt[M]),"animationId",j)),childIndex:t7(F,m.children),item:F})}),z},p=function(m,y){var g=m.props,S=m.dataStartIndex,w=m.dataEndIndex,j=m.updateId;if(!qw({props:g}))return null;var A=g.children,E=g.layout,_=g.stackOffset,N=g.data,D=g.reverseStackOrder,R=SA(E),B=R.numericAxisName,k=R.cateAxisName,C=Wn(A,r),M=dte(N,C,"".concat(B,"Id"),"".concat(k,"Id"),_,D),L=s.reduce(function(Y,J){var me="".concat(J.axisType,"Map");return I(I({},Y),{},ae({},me,Que(g,I(I({},J),{},{graphicalItems:C,stackGroups:J.axisType===B&&M,dataStartIndex:S,dataEndIndex:w}))))},{}),z=Jue(I(I({},L),{},{props:g,graphicalItems:C}),y==null?void 0:y.legendBBox);Object.keys(L).forEach(function(Y){L[Y]=d(g,L[Y],z,Y.replace("Map",""),n)});var F=L["".concat(k,"Map")],K=Wue(F),G=h(g,I(I({},L),{},{dataStartIndex:S,dataEndIndex:w,updateId:j,graphicalItems:C,stackGroups:M,offset:z}));return I(I({formattedGraphicalItems:G,graphicalItems:C,offset:z,stackGroups:M},K),L)},b=function(x){function m(y){var g,S,w;return Pue(this,m),w=Due(this,m,[y]),ae(w,"eventEmitterSymbol",Symbol("rechartsEventEmitter")),ae(w,"accessibilityManager",new bue),ae(w,"handleLegendBBoxUpdate",function(j){if(j){var A=w.state,E=A.dataStartIndex,_=A.dataEndIndex,N=A.updateId;w.setState(I({legendBBox:j},p({props:w.props,dataStartIndex:E,dataEndIndex:_,updateId:N},I(I({},w.state),{},{legendBBox:j}))))}}),ae(w,"handleReceiveSyncEvent",function(j,A,E){if(w.props.syncId===j){if(E===w.eventEmitterSymbol&&typeof w.props.syncMethod!="function")return;w.applySyncEvent(A)}}),ae(w,"handleBrushChange",function(j){var A=j.startIndex,E=j.endIndex;if(A!==w.state.dataStartIndex||E!==w.state.dataEndIndex){var _=w.state.updateId;w.setState(function(){return I({dataStartIndex:A,dataEndIndex:E},p({props:w.props,dataStartIndex:A,dataEndIndex:E,updateId:_},w.state))}),w.triggerSyncEvent({dataStartIndex:A,dataEndIndex:E})}}),ae(w,"handleMouseEnter",function(j){var A=w.getMouseInfo(j);if(A){var E=I(I({},A),{},{isTooltipActive:!0});w.setState(E),w.triggerSyncEvent(E);var _=w.props.onMouseEnter;se(_)&&_(E,j)}}),ae(w,"triggeredAfterMouseMove",function(j){var A=w.getMouseInfo(j),E=A?I(I({},A),{},{isTooltipActive:!0}):{isTooltipActive:!1};w.setState(E),w.triggerSyncEvent(E);var _=w.props.onMouseMove;se(_)&&_(E,j)}),ae(w,"handleItemMouseEnter",function(j){w.setState(function(){return{isTooltipActive:!0,activeItem:j,activePayload:j.tooltipPayload,activeCoordinate:j.tooltipPosition||{x:j.cx,y:j.cy}}})}),ae(w,"handleItemMouseLeave",function(){w.setState(function(){return{isTooltipActive:!1}})}),ae(w,"handleMouseMove",function(j){j.persist(),w.throttleTriggeredAfterMouseMove(j)}),ae(w,"handleMouseLeave",function(j){w.throttleTriggeredAfterMouseMove.cancel();var A={isTooltipActive:!1};w.setState(A),w.triggerSyncEvent(A);var E=w.props.onMouseLeave;se(E)&&E(A,j)}),ae(w,"handleOuterEvent",function(j){var A=e7(j),E=Rn(w.props,"".concat(A));if(A&&se(E)){var _,N;/.*touch.*/i.test(A)?N=w.getMouseInfo(j.changedTouches[0]):N=w.getMouseInfo(j),E((_=N)!==null&&_!==void 0?_:{},j)}}),ae(w,"handleClick",function(j){var A=w.getMouseInfo(j);if(A){var E=I(I({},A),{},{isTooltipActive:!0});w.setState(E),w.triggerSyncEvent(E);var _=w.props.onClick;se(_)&&_(E,j)}}),ae(w,"handleMouseDown",function(j){var A=w.props.onMouseDown;if(se(A)){var E=w.getMouseInfo(j);A(E,j)}}),ae(w,"handleMouseUp",function(j){var A=w.props.onMouseUp;if(se(A)){var E=w.getMouseInfo(j);A(E,j)}}),ae(w,"handleTouchMove",function(j){j.changedTouches!=null&&j.changedTouches.length>0&&w.throttleTriggeredAfterMouseMove(j.changedTouches[0])}),ae(w,"handleTouchStart",function(j){j.changedTouches!=null&&j.changedTouches.length>0&&w.handleMouseDown(j.changedTouches[0])}),ae(w,"handleTouchEnd",function(j){j.changedTouches!=null&&j.changedTouches.length>0&&w.handleMouseUp(j.changedTouches[0])}),ae(w,"handleDoubleClick",function(j){var A=w.props.onDoubleClick;if(se(A)){var E=w.getMouseInfo(j);A(E,j)}}),ae(w,"handleContextMenu",function(j){var A=w.props.onContextMenu;if(se(A)){var E=w.getMouseInfo(j);A(E,j)}}),ae(w,"triggerSyncEvent",function(j){w.props.syncId!==void 0&&Ly.emit(zy,w.props.syncId,j,w.eventEmitterSymbol)}),ae(w,"applySyncEvent",function(j){var A=w.props,E=A.layout,_=A.syncMethod,N=w.state.updateId,D=j.dataStartIndex,R=j.dataEndIndex;if(j.dataStartIndex!==void 0||j.dataEndIndex!==void 0)w.setState(I({dataStartIndex:D,dataEndIndex:R},p({props:w.props,dataStartIndex:D,dataEndIndex:R,updateId:N},w.state)));else if(j.activeTooltipIndex!==void 0){var B=j.chartX,k=j.chartY,C=j.activeTooltipIndex,M=w.state,L=M.offset,z=M.tooltipTicks;if(!L)return;if(typeof _=="function")C=_(z,j);else if(_==="value"){C=-1;for(var F=0;F<z.length;F++)if(z[F].value===j.activeLabel){C=F;break}}var K=I(I({},L),{},{x:L.left,y:L.top}),G=Math.min(B,K.x+K.width),Y=Math.min(k,K.y+K.height),J=z[C]&&z[C].value,me=z0(w.state,w.props.data,C),Le=z[C]?{x:E==="horizontal"?z[C].coordinate:G,y:E==="horizontal"?Y:z[C].coordinate}:$R;w.setState(I(I({},j),{},{activeLabel:J,activeCoordinate:Le,activePayload:me,activeTooltipIndex:C}))}else w.setState(j)}),ae(w,"renderCursor",function(j){var A,E=w.state,_=E.isTooltipActive,N=E.activeCoordinate,D=E.activePayload,R=E.offset,B=E.activeTooltipIndex,k=E.tooltipAxisBandSize,C=w.getTooltipEventType(),M=(A=j.props.active)!==null&&A!==void 0?A:_,L=w.props.layout,z=j.key||"_recharts-cursor";return $.createElement(Eue,{key:z,activeCoordinate:N,activePayload:D,activeTooltipIndex:B,chartName:n,element:j,isActive:M,layout:L,offset:R,tooltipAxisBandSize:k,tooltipEventType:C})}),ae(w,"renderPolarAxis",function(j,A,E){var _=Rn(j,"type.axisType"),N=Rn(w.state,"".concat(_,"Map")),D=j.type.defaultProps,R=D!==void 0?I(I({},D),j.props):j.props,B=N&&N[R["".concat(_,"Id")]];return O.cloneElement(j,I(I({},B),{},{className:ve(_,B.className),key:j.key||"".concat(A,"-").concat(E),ticks:$i(B,!0)}))}),ae(w,"renderPolarGrid",function(j){var A=j.props,E=A.radialLines,_=A.polarAngles,N=A.polarRadius,D=w.state,R=D.radiusAxisMap,B=D.angleAxisMap,k=$o(R),C=$o(B),M=C.cx,L=C.cy,z=C.innerRadius,F=C.outerRadius;return O.cloneElement(j,{polarAngles:Array.isArray(_)?_:$i(C,!0).map(function(K){return K.coordinate}),polarRadius:Array.isArray(N)?N:$i(k,!0).map(function(K){return K.coordinate}),cx:M,cy:L,innerRadius:z,outerRadius:F,key:j.key||"polar-grid",radialLines:E})}),ae(w,"renderLegend",function(){var j=w.state.formattedGraphicalItems,A=w.props,E=A.children,_=A.width,N=A.height,D=w.props.margin||{},R=_-(D.left||0)-(D.right||0),B=m3({children:E,formattedGraphicalItems:j,legendWidth:R,legendContent:u});if(!B)return null;var k=B.item,C=vA(B,_ue);return O.cloneElement(k,I(I({},C),{},{chartWidth:_,chartHeight:N,margin:D,onBBoxUpdate:w.handleLegendBBoxUpdate}))}),ae(w,"renderTooltip",function(){var j,A=w.props,E=A.children,_=A.accessibilityLayer,N=Sn(E,sr);if(!N)return null;var D=w.state,R=D.isTooltipActive,B=D.activeCoordinate,k=D.activePayload,C=D.activeLabel,M=D.offset,L=(j=N.props.active)!==null&&j!==void 0?j:R;return O.cloneElement(N,{viewBox:I(I({},M),{},{x:M.left,y:M.top}),active:L,label:C,payload:L?k:[],coordinate:B,accessibilityLayer:_})}),ae(w,"renderBrush",function(j){var A=w.props,E=A.margin,_=A.data,N=w.state,D=N.offset,R=N.dataStartIndex,B=N.dataEndIndex,k=N.updateId;return O.cloneElement(j,{key:j.key||"_recharts-brush",onChange:Lf(w.handleBrushChange,j.props.onChange),data:_,x:V(j.props.x)?j.props.x:D.left,y:V(j.props.y)?j.props.y:D.top+D.height+D.brushBottom-(E.bottom||0),width:V(j.props.width)?j.props.width:D.width,startIndex:R,endIndex:B,updateId:"brush-".concat(k)})}),ae(w,"renderReferenceElement",function(j,A,E){if(!j)return null;var _=w,N=_.clipPathId,D=w.state,R=D.xAxisMap,B=D.yAxisMap,k=D.offset,C=j.type.defaultProps||{},M=j.props,L=M.xAxisId,z=L===void 0?C.xAxisId:L,F=M.yAxisId,K=F===void 0?C.yAxisId:F;return O.cloneElement(j,{key:j.key||"".concat(A,"-").concat(E),xAxis:R[z],yAxis:B[K],viewBox:{x:k.left,y:k.top,width:k.width,height:k.height},clipPathId:N})}),ae(w,"renderActivePoints",function(j){var A=j.item,E=j.activePoint,_=j.basePoint,N=j.childIndex,D=j.isRange,R=[],B=A.props.key,k=A.item.type.defaultProps!==void 0?I(I({},A.item.type.defaultProps),A.item.props):A.item.props,C=k.activeDot,M=k.dataKey,L=I(I({index:N,dataKey:M,cx:E.x,cy:E.y,r:4,fill:u1(A.item),strokeWidth:2,stroke:"#fff",payload:E.payload,value:E.value},oe(C,!1)),Xd(C));return R.push(m.renderActiveDot(C,L,"".concat(B,"-activePoint-").concat(N))),_?R.push(m.renderActiveDot(C,I(I({},L),{},{cx:_.x,cy:_.y}),"".concat(B,"-basePoint-").concat(N))):D&&R.push(null),R}),ae(w,"renderGraphicChild",function(j,A,E){var _=w.filterFormatItem(j,A,E);if(!_)return null;var N=w.getTooltipEventType(),D=w.state,R=D.isTooltipActive,B=D.tooltipAxis,k=D.activeTooltipIndex,C=D.activeLabel,M=w.props.children,L=Sn(M,sr),z=_.props,F=z.points,K=z.isRange,G=z.baseLine,Y=_.item.type.defaultProps!==void 0?I(I({},_.item.type.defaultProps),_.item.props):_.item.props,J=Y.activeDot,me=Y.hide,Le=Y.activeBar,ce=Y.activeShape,$t=!!(!me&&R&&L&&(J||Le||ce)),bt={};N!=="axis"&&L&&L.props.trigger==="click"?bt={onClick:Lf(w.handleItemMouseEnter,j.props.onClick)}:N!=="axis"&&(bt={onMouseLeave:Lf(w.handleItemMouseLeave,j.props.onMouseLeave),onMouseEnter:Lf(w.handleItemMouseEnter,j.props.onMouseEnter)});var Q=O.cloneElement(j,I(I({},_.props),bt));function le(gn){return typeof B.dataKey=="function"?B.dataKey(gn.payload):null}if($t)if(k>=0){var fe,q;if(B.dataKey&&!B.allowDuplicatedCategory){var Xe=typeof B.dataKey=="function"?le:"payload.".concat(B.dataKey.toString());fe=dg(F,Xe,C),q=K&&G&&dg(G,Xe,C)}else fe=F==null?void 0:F[k],q=K&&G&&G[k];if(ce||Le){var be=j.props.activeIndex!==void 0?j.props.activeIndex:k;return[O.cloneElement(j,I(I(I({},_.props),bt),{},{activeIndex:be})),null,null]}if(!ge(fe))return[Q].concat(ls(w.renderActivePoints({item:_,activePoint:fe,basePoint:q,childIndex:k,isRange:K})))}else{var Re,te=(Re=w.getItemByXY(w.state.activeCoordinate))!==null&&Re!==void 0?Re:{graphicalItem:Q},ze=te.graphicalItem,kt=ze.item,an=kt===void 0?j:kt,yi=ze.childIndex,Pr=I(I(I({},_.props),bt),{},{activeIndex:yi});return[O.cloneElement(an,Pr),null,null]}return K?[Q,null,null]:[Q,null]}),ae(w,"renderCustomized",function(j,A,E){return O.cloneElement(j,I(I({key:"recharts-customized-".concat(E)},w.props),w.state))}),ae(w,"renderMap",{CartesianGrid:{handler:qf,once:!0},ReferenceArea:{handler:w.renderReferenceElement},ReferenceLine:{handler:qf},ReferenceDot:{handler:w.renderReferenceElement},XAxis:{handler:qf},YAxis:{handler:qf},Brush:{handler:w.renderBrush,once:!0},Bar:{handler:w.renderGraphicChild},Line:{handler:w.renderGraphicChild},Area:{handler:w.renderGraphicChild},Radar:{handler:w.renderGraphicChild},RadialBar:{handler:w.renderGraphicChild},Scatter:{handler:w.renderGraphicChild},Pie:{handler:w.renderGraphicChild},Funnel:{handler:w.renderGraphicChild},Tooltip:{handler:w.renderCursor,once:!0},PolarGrid:{handler:w.renderPolarGrid,once:!0},PolarAngleAxis:{handler:w.renderPolarAxis},PolarRadiusAxis:{handler:w.renderPolarAxis},Customized:{handler:w.renderCustomized}}),w.clipPathId="".concat((g=y.id)!==null&&g!==void 0?g:tf("recharts"),"-clip"),w.throttleTriggeredAfterMouseMove=mM(w.triggeredAfterMouseMove,(S=y.throttleDelay)!==null&&S!==void 0?S:1e3/60),w.state={},w}return Bue(m,x),kue(m,[{key:"componentDidMount",value:function(){var g,S;this.addListener(),this.accessibilityManager.setDetails({container:this.container,offset:{left:(g=this.props.margin.left)!==null&&g!==void 0?g:0,top:(S=this.props.margin.top)!==null&&S!==void 0?S:0},coordinateList:this.state.tooltipTicks,mouseHandlerCallback:this.triggeredAfterMouseMove,layout:this.props.layout}),this.displayDefaultTooltip()}},{key:"displayDefaultTooltip",value:function(){var g=this.props,S=g.children,w=g.data,j=g.height,A=g.layout,E=Sn(S,sr);if(E){var _=E.props.defaultIndex;if(!(typeof _!="number"||_<0||_>this.state.tooltipTicks.length-1)){var N=this.state.tooltipTicks[_]&&this.state.tooltipTicks[_].value,D=z0(this.state,w,_,N),R=this.state.tooltipTicks[_].coordinate,B=(this.state.offset.top+j)/2,k=A==="horizontal",C=k?{x:R,y:B}:{y:R,x:B},M=this.state.formattedGraphicalItems.find(function(z){var F=z.item;return F.type.name==="Scatter"});M&&(C=I(I({},C),M.props.points[_].tooltipPosition),D=M.props.points[_].tooltipPayload);var L={activeTooltipIndex:_,isTooltipActive:!0,activeLabel:N,activePayload:D,activeCoordinate:C};this.setState(L),this.renderCursor(E),this.accessibilityManager.setIndex(_)}}}},{key:"getSnapshotBeforeUpdate",value:function(g,S){if(!this.props.accessibilityLayer)return null;if(this.state.tooltipTicks!==S.tooltipTicks&&this.accessibilityManager.setDetails({coordinateList:this.state.tooltipTicks}),this.props.layout!==g.layout&&this.accessibilityManager.setDetails({layout:this.props.layout}),this.props.margin!==g.margin){var w,j;this.accessibilityManager.setDetails({offset:{left:(w=this.props.margin.left)!==null&&w!==void 0?w:0,top:(j=this.props.margin.top)!==null&&j!==void 0?j:0}})}return null}},{key:"componentDidUpdate",value:function(g){pg([Sn(g.children,sr)],[Sn(this.props.children,sr)])||this.displayDefaultTooltip()}},{key:"componentWillUnmount",value:function(){this.removeListener(),this.throttleTriggeredAfterMouseMove.cancel()}},{key:"getTooltipEventType",value:function(){var g=Sn(this.props.children,sr);if(g&&typeof g.props.shared=="boolean"){var S=g.props.shared?"axis":"item";return l.indexOf(S)>=0?S:i}return i}},{key:"getMouseInfo",value:function(g){if(!this.container)return null;var S=this.container,w=S.getBoundingClientRect(),j=TQ(w),A={chartX:Math.round(g.pageX-j.left),chartY:Math.round(g.pageY-j.top)},E=w.width/S.offsetWidth||1,_=this.inRange(A.chartX,A.chartY,E);if(!_)return null;var N=this.state,D=N.xAxisMap,R=N.yAxisMap,B=this.getTooltipEventType(),k=bA(this.state,this.props.data,this.props.layout,_);if(B!=="axis"&&D&&R){var C=$o(D).scale,M=$o(R).scale,L=C&&C.invert?C.invert(A.chartX):null,z=M&&M.invert?M.invert(A.chartY):null;return I(I({},A),{},{xValue:L,yValue:z},k)}return k?I(I({},A),k):null}},{key:"inRange",value:function(g,S){var w=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,j=this.props.layout,A=g/w,E=S/w;if(j==="horizontal"||j==="vertical"){var _=this.state.offset,N=A>=_.left&&A<=_.left+_.width&&E>=_.top&&E<=_.top+_.height;return N?{x:A,y:E}:null}var D=this.state,R=D.angleAxisMap,B=D.radiusAxisMap;if(R&&B){var k=$o(R);return Z2({x:A,y:E},k)}return null}},{key:"parseEventsOfWrapper",value:function(){var g=this.props.children,S=this.getTooltipEventType(),w=Sn(g,sr),j={};w&&S==="axis"&&(w.props.trigger==="click"?j={onClick:this.handleClick}:j={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 A=Xd(this.props,this.handleOuterEvent);return I(I({},A),j)}},{key:"addListener",value:function(){Ly.on(zy,this.handleReceiveSyncEvent)}},{key:"removeListener",value:function(){Ly.removeListener(zy,this.handleReceiveSyncEvent)}},{key:"filterFormatItem",value:function(g,S,w){for(var j=this.state.formattedGraphicalItems,A=0,E=j.length;A<E;A++){var _=j[A];if(_.item===g||_.props.key===g.key||S===na(_.item.type)&&w===_.childIndex)return _}return null}},{key:"renderClipPath",value:function(){var g=this.clipPathId,S=this.state.offset,w=S.left,j=S.top,A=S.height,E=S.width;return $.createElement("defs",null,$.createElement("clipPath",{id:g},$.createElement("rect",{x:w,y:j,height:A,width:E})))}},{key:"getXScales",value:function(){var g=this.state.xAxisMap;return g?Object.entries(g).reduce(function(S,w){var j=yA(w,2),A=j[0],E=j[1];return I(I({},S),{},ae({},A,E.scale))},{}):null}},{key:"getYScales",value:function(){var g=this.state.yAxisMap;return g?Object.entries(g).reduce(function(S,w){var j=yA(w,2),A=j[0],E=j[1];return I(I({},S),{},ae({},A,E.scale))},{}):null}},{key:"getXScaleByAxisId",value:function(g){var S;return(S=this.state.xAxisMap)===null||S===void 0||(S=S[g])===null||S===void 0?void 0:S.scale}},{key:"getYScaleByAxisId",value:function(g){var S;return(S=this.state.yAxisMap)===null||S===void 0||(S=S[g])===null||S===void 0?void 0:S.scale}},{key:"getItemByXY",value:function(g){var S=this.state,w=S.formattedGraphicalItems,j=S.activeItem;if(w&&w.length)for(var A=0,E=w.length;A<E;A++){var _=w[A],N=_.props,D=_.item,R=D.type.defaultProps!==void 0?I(I({},D.type.defaultProps),D.props):D.props,B=na(D.type);if(B==="Bar"){var k=(N.data||[]).find(function(z){return pae(g,z)});if(k)return{graphicalItem:_,payload:k}}else if(B==="RadialBar"){var C=(N.data||[]).find(function(z){return Z2(g,z)});if(C)return{graphicalItem:_,payload:C}}else if(sm(_,j)||um(_,j)||xc(_,j)){var M=noe({graphicalItem:_,activeTooltipItem:j,itemData:R.data}),L=R.activeIndex===void 0?M:R.activeIndex;return{graphicalItem:I(I({},_),{},{childIndex:L}),payload:xc(_,j)?R.data[M]:_.props.data[M]}}}return null}},{key:"render",value:function(){var g=this;if(!qw(this))return null;var S=this.props,w=S.children,j=S.className,A=S.width,E=S.height,_=S.style,N=S.compact,D=S.title,R=S.desc,B=vA(S,Tue),k=oe(B,!1);if(N)return $.createElement(rA,{state:this.state,width:this.props.width,height:this.props.height,clipPathId:this.clipPathId},$.createElement(yg,Wo({},k,{width:A,height:E,title:D,desc:R}),this.renderClipPath(),Fw(w,this.renderMap)));if(this.props.accessibilityLayer){var C,M;k.tabIndex=(C=this.props.tabIndex)!==null&&C!==void 0?C:0,k.role=(M=this.props.role)!==null&&M!==void 0?M:"application",k.onKeyDown=function(z){g.accessibilityManager.keyboardEvent(z)},k.onFocus=function(){g.accessibilityManager.focus()}}var L=this.parseEventsOfWrapper();return $.createElement(rA,{state:this.state,width:this.props.width,height:this.props.height,clipPathId:this.clipPathId},$.createElement("div",Wo({className:ve("recharts-wrapper",j),style:I({position:"relative",cursor:"default",width:A,height:E},_)},L,{ref:function(F){g.container=F}}),$.createElement(yg,Wo({},k,{width:A,height:E,title:D,desc:R,style:Gue}),this.renderClipPath(),Fw(w,this.renderMap)),this.renderLegend(),this.renderTooltip()))}}])}(O.Component);ae(b,"displayName",n),ae(b,"defaultProps",I({layout:"horizontal",stackOffset:"none",barCategoryGap:"10%",barGap:4,margin:{top:5,right:5,bottom:5,left:5},reverseStackOrder:!1,syncMethod:"index"},f)),ae(b,"getDerivedStateFromProps",function(x,m){var y=x.dataKey,g=x.data,S=x.children,w=x.width,j=x.height,A=x.layout,E=x.stackOffset,_=x.margin,N=m.dataStartIndex,D=m.dataEndIndex;if(m.updateId===void 0){var R=xA(x);return I(I(I({},R),{},{updateId:0},p(I(I({props:x},R),{},{updateId:0}),m)),{},{prevDataKey:y,prevData:g,prevWidth:w,prevHeight:j,prevLayout:A,prevStackOffset:E,prevMargin:_,prevChildren:S})}if(y!==m.prevDataKey||g!==m.prevData||w!==m.prevWidth||j!==m.prevHeight||A!==m.prevLayout||E!==m.prevStackOffset||!ol(_,m.prevMargin)){var B=xA(x),k={chartX:m.chartX,chartY:m.chartY,isTooltipActive:m.isTooltipActive},C=I(I({},bA(m,g,A)),{},{updateId:m.updateId+1}),M=I(I(I({},B),k),C);return I(I(I({},M),p(I({props:x},M),m)),{},{prevDataKey:y,prevData:g,prevWidth:w,prevHeight:j,prevLayout:A,prevStackOffset:E,prevMargin:_,prevChildren:S})}if(!pg(S,m.prevChildren)){var L,z,F,K,G=Sn(S,Zl),Y=G&&(L=(z=G.props)===null||z===void 0?void 0:z.startIndex)!==null&&L!==void 0?L:N,J=G&&(F=(K=G.props)===null||K===void 0?void 0:K.endIndex)!==null&&F!==void 0?F:D,me=Y!==N||J!==D,Le=!ge(g),ce=Le&&!me?m.updateId:m.updateId+1;return I(I({updateId:ce},p(I(I({props:x},m),{},{updateId:ce,dataStartIndex:Y,dataEndIndex:J}),m)),{},{prevChildren:S,dataStartIndex:Y,dataEndIndex:J})}return null}),ae(b,"renderActiveDot",function(x,m,y){var g;return O.isValidElement(x)?g=O.cloneElement(x,m):se(x)?g=x(m):g=$.createElement(f1,m),$.createElement(ke,{className:"recharts-active-dot",key:y},g)});var v=O.forwardRef(function(m,y){return $.createElement(b,Wo({},m,{ref:y}))});return v.displayName=b.displayName,v},tce=DR({chartName:"BarChart",GraphicalChild:wo,defaultTooltipEventType:"axis",validateTooltipEventTypes:["axis","item"],axisComponents:[{axisType:"xAxis",AxisComp:ym},{axisType:"yAxis",AxisComp:vm}],formatAxisMap:Dle}),nce=DR({chartName:"PieChart",GraphicalChild:xa,validateTooltipEventTypes:["item"],defaultTooltipEventType:"item",legendContent:"children",axisComponents:[{axisType:"angleAxis",AxisComp:lm},{axisType:"radiusAxis",AxisComp:im}],formatAxisMap:Ote,defaultProps:{layout:"centric",startAngle:0,endAngle:360,cx:"50%",cy:"50%",innerRadius:0,outerRadius:"80%"}});function Co({title:e,value:t,icon:n,color:r="brand",sub:a}){const i={brand:"text-brand  bg-brand/10",green:"text-green-400  bg-green-400/10",red:"text-red-400    bg-red-400/10",orange:"text-orange-400 bg-orange-400/10",yellow:"text-yellow-400 bg-yellow-400/10",accent:"text-accent  bg-accent/10"},o=i[r]||i.brand;return c.jsxs("div",{className:"bg-card border border-edge rounded-lg p-4 flex items-center gap-4",children:[c.jsx("div",{className:`p-3 rounded-lg ${o}`,children:c.jsx(n,{size:20})}),c.jsxs("div",{children:[c.jsx("p",{className:"text-xs text-gray-400",children:e}),c.jsx("p",{className:`text-2xl font-bold ${o.split(" ")[0]}`,children:t}),a&&c.jsx("p",{className:"text-xs text-gray-500",children:a})]})]})}const wA=["#00a0c8","#3ddc97","#f59e0b","#ef4444"];function rce(){const e=localStorage.getItem("esn_tenant")||void 0,{data:t,isLoading:n}=Vt({queryKey:["dashboard",e],queryFn:()=>rz(e),refetchInterval:3e4});if(n)return c.jsx("div",{className:"text-gray-400 p-8",children:"로딩 중..."});if(!t)return c.jsx("div",{className:"text-red-400 p-8",children:"데이터를 가져올 수 없습니다."});const r=[{name:"ONLINE",value:t.onlineDevices||0},{name:"OFFLINE",value:t.offlineDevices||0}],a=[{name:"오늘 작업",value:t.totalWorkToday||0},{name:"완료",value:t.completedWorkToday||0},{name:"POS 대기",value:t.pendingPosCvt||0},{name:"POS 처리",value:t.processedPosCvtToday||0}];return c.jsxs("div",{className:"space-y-6",children:[c.jsx("h1",{className:"text-xl font-semibold text-white",children:"대시보드"}),c.jsxs("div",{className:"grid grid-cols-2 md:grid-cols-3 lg:grid-cols-6 gap-4",children:[c.jsx(Co,{title:"전체 매장",value:t.totalStores||0,icon:og,color:"brand"}),c.jsx(Co,{title:"운영 매장",value:t.activeStores||0,icon:og,color:"green"}),c.jsx(Co,{title:"미해결 알람",value:t.unresolvedAlarms||0,icon:xN,color:"red"}),c.jsx(Co,{title:"긴급 알람",value:t.criticalAlarms||0,icon:kl,color:"red"}),c.jsx(Co,{title:"온라인 장치",value:t.onlineDevices||0,icon:$l,color:"green"}),c.jsx(Co,{title:"POS 대기",value:t.pendingPosCvt||0,icon:Yc,color:"yellow"})]}),c.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-4",children:[c.jsxs("div",{className:"bg-card border border-edge rounded-lg p-4",children:[c.jsx("h2",{className:"text-sm font-medium text-gray-300 mb-4",children:"장치 상태 현황"}),c.jsx(Uj,{width:"100%",height:200,children:c.jsxs(nce,{children:[c.jsx(xa,{data:r,cx:"50%",cy:"50%",outerRadius:70,dataKey:"value",label:({name:i,value:o})=>`${i}: ${o}`,children:r.map((i,o)=>c.jsx(Fp,{fill:wA[o%wA.length]},o))}),c.jsx(sr,{contentStyle:{background:"#1a2234",border:"1px solid #26304a",color:"#fff"}})]})})]}),c.jsxs("div",{className:"bg-card border border-edge rounded-lg p-4",children:[c.jsx("h2",{className:"text-sm font-medium text-gray-300 mb-4",children:"오늘의 작업/POS 현황"}),c.jsx(Uj,{width:"100%",height:200,children:c.jsxs(tce,{data:a,children:[c.jsx(ym,{dataKey:"name",tick:{fill:"#9ca3af",fontSize:11}}),c.jsx(vm,{tick:{fill:"#9ca3af",fontSize:11}}),c.jsx(sr,{contentStyle:{background:"#1a2234",border:"1px solid #26304a",color:"#fff"}}),c.jsx(wo,{dataKey:"value",fill:"#00a0c8",radius:[3,3,0,0]})]})})]})]}),c.jsxs("div",{className:"grid grid-cols-2 md:grid-cols-4 gap-4",children:[c.jsxs("div",{className:"bg-card border border-edge rounded-lg p-4",children:[c.jsx("p",{className:"text-xs text-gray-400",children:"오늘 작업"}),c.jsx("p",{className:"text-2xl font-bold text-brand",children:t.totalWorkToday||0}),c.jsxs("p",{className:"text-xs text-gray-500",children:["완료: ",t.completedWorkToday||0]})]}),c.jsxs("div",{className:"bg-card border border-edge rounded-lg p-4",children:[c.jsx("p",{className:"text-xs text-gray-400",children:"전체 알람"}),c.jsx("p",{className:"text-2xl font-bold text-yellow-400",children:t.totalAlarms||0}),c.jsxs("p",{className:"text-xs text-gray-500",children:["미해결: ",t.unresolvedAlarms||0]})]}),c.jsxs("div",{className:"bg-card border border-edge rounded-lg p-4",children:[c.jsx("p",{className:"text-xs text-gray-400",children:"전체 장치"}),c.jsx("p",{className:"text-2xl font-bold text-accent",children:t.totalDevices||0}),c.jsxs("p",{className:"text-xs text-gray-500",children:["오프라인: ",t.offlineDevices||0]})]}),c.jsxs("div",{className:"bg-card border border-edge rounded-lg p-4",children:[c.jsx("p",{className:"text-xs text-gray-400",children:"POS 처리(오늘)"}),c.jsx("p",{className:"text-2xl font-bold text-green-400",children:t.processedPosCvtToday||0}),c.jsxs("p",{className:"text-xs text-gray-500",children:["대기: ",t.pendingPosCvt||0]})]})]})]})}function ace(){const e=rn(),[t,n]=O.useState(null),[r,a]=O.useState(""),{data:i=[],isLoading:o}=Vt({queryKey:["stores",r],queryFn:()=>sz({keyword:r||void 0})}),l=tt({mutationFn:u=>u.id?cz(u.id,u):uz(u),onSuccess:()=>{e.invalidateQueries({queryKey:["stores"]}),n(null)}}),s=tt({mutationFn:fz,onSuccess:()=>e.invalidateQueries({queryKey:["stores"]})});return o?c.jsx("div",{className:"text-gray-400 p-8",children:"로딩 중..."}):c.jsxs("div",{className:"space-y-4",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("h1",{className:"text-xl font-semibold text-white",children:"매장 관리"}),c.jsxs("div",{className:"flex gap-2",children:[c.jsx("input",{value:r,onChange:u=>a(u.target.value),placeholder:"매장명·코드 검색",className:"bg-panel border border-edge rounded px-3 py-1.5 text-sm text-gray-300 w-48"}),c.jsxs("button",{onClick:()=>n({}),className:"flex items-center gap-1.5 bg-brand hover:bg-brand2 text-white px-3 py-1.5 rounded text-sm",children:[c.jsx(xs,{size:14})," 매장 추가"]})]})]}),c.jsx("div",{className:"bg-card border border-edge rounded-lg overflow-hidden",children:c.jsxs("table",{className:"w-full text-sm",children:[c.jsx("thead",{className:"bg-panel border-b border-edge",children:c.jsx("tr",{children:["테넌트","코드","매장명","주소","담당자","상태","액션"].map(u=>c.jsx("th",{className:"px-4 py-3 text-left text-xs text-gray-400 font-medium",children:u},u))})}),c.jsxs("tbody",{children:[i.map(u=>c.jsxs("tr",{className:"border-b border-edge hover:bg-edge/30",children:[c.jsx("td",{className:"px-4 py-3 text-brand text-xs",children:u.tenantCode}),c.jsx("td",{className:"px-4 py-3 text-gray-300 font-mono text-xs",children:u.storeCode}),c.jsx("td",{className:"px-4 py-3 text-white",children:u.storeName}),c.jsx("td",{className:"px-4 py-3 text-gray-400 text-xs truncate max-w-xs",children:u.address}),c.jsx("td",{className:"px-4 py-3 text-gray-400",children:u.managerName}),c.jsx("td",{className:"px-4 py-3",children:c.jsx("span",{className:`px-2 py-0.5 rounded text-xs ${u.active?"bg-green-500/20 text-green-400":"bg-gray-500/20 text-gray-400"}`,children:u.active?"운영":"중지"})}),c.jsx("td",{className:"px-4 py-3",children:c.jsxs("div",{className:"flex gap-2",children:[c.jsx("button",{onClick:()=>n(u),className:"text-brand hover:text-blue-300",children:c.jsx(Vc,{size:14})}),c.jsx("button",{onClick:()=>{confirm("삭제?")&&s.mutate(u.id)},className:"text-red-400 hover:text-red-300",children:c.jsx(vo,{size:14})})]})})]},u.id)),i.length===0&&c.jsx("tr",{children:c.jsx("td",{colSpan:7,className:"px-4 py-8 text-center text-gray-500",children:"매장이 없습니다"})})]})]})}),t&&c.jsx("div",{className:"fixed inset-0 bg-black/60 flex items-center justify-center z-50",children:c.jsxs("div",{className:"bg-card border border-edge rounded-lg p-6 w-full max-w-md",children:[c.jsxs("div",{className:"flex justify-between mb-4",children:[c.jsx("h2",{className:"font-semibold",children:t.id?"매장 수정":"매장 추가"}),c.jsx("button",{onClick:()=>n(null),children:c.jsx(Ss,{size:16})})]}),c.jsx(ice,{initial:t,onSave:u=>l.mutate(u)})]})})]})}function ice({initial:e,onSave:t}){const[n,r]=O.useState({tenantCode:e.tenantCode||"",storeCode:e.storeCode||"",storeName:e.storeName||"",address:e.address||"",phone:e.phone||"",managerName:e.managerName||"",active:e.active!==!1,id:e.id}),a=i=>o=>r(l=>({...l,[i]:o.target.value}));return c.jsxs("form",{onSubmit:i=>{i.preventDefault(),t(n)},className:"space-y-3",children:[[{label:"테넌트",key:"tenantCode",type:"select",opts:["TENANT_A","TENANT_B","EMART","ZIOINFO"]},{label:"매장코드",key:"storeCode"},{label:"매장명",key:"storeName"},{label:"주소",key:"address"},{label:"전화",key:"phone"},{label:"담당자",key:"managerName"}].map(({label:i,key:o,type:l,opts:s})=>c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:i}),l==="select"?c.jsx("select",{value:n[o],onChange:a(o),className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white",children:(s||[]).map(u=>c.jsx("option",{value:u,children:u},u))}):c.jsx("input",{value:n[o],onChange:a(o),className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white"})]},o)),c.jsx("button",{type:"submit",className:"w-full bg-brand hover:bg-brand2 text-white py-2 rounded text-sm",children:"저장"})]})}function oce(){const e=rn(),[t,n]=O.useState(null),{data:r=[],isLoading:a}=Vt({queryKey:["templates"],queryFn:()=>dz()}),i=tt({mutationFn:l=>l.id?pz(l.id,l):hz(l),onSuccess:()=>{e.invalidateQueries({queryKey:["templates"]}),n(null)}}),o=tt({mutationFn:mz,onSuccess:()=>e.invalidateQueries({queryKey:["templates"]})});return a?c.jsx("div",{className:"text-gray-400 p-8",children:"로딩 중..."}):c.jsxs("div",{className:"space-y-4",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("h1",{className:"text-xl font-semibold text-white",children:"ESL 템플릿"}),c.jsxs("button",{onClick:()=>n({}),className:"flex items-center gap-1.5 bg-brand hover:bg-brand2 text-white px-3 py-1.5 rounded text-sm",children:[c.jsx(xs,{size:14})," 템플릿 추가"]})]}),c.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-4",children:[r.map(l=>c.jsxs("div",{className:"bg-card border border-edge rounded-lg p-4",children:[c.jsxs("div",{className:"flex justify-between items-start mb-2",children:[c.jsxs("div",{children:[c.jsx("p",{className:"text-sm font-medium text-white",children:l.templateName}),c.jsxs("p",{className:"text-xs text-brand mt-0.5",children:[l.tenantCode," · ",l.templateType]})]}),c.jsxs("div",{className:"flex gap-2",children:[c.jsx("button",{onClick:()=>n(l),className:"text-brand hover:text-blue-300",children:c.jsx(Vc,{size:14})}),c.jsx("button",{onClick:()=>{confirm("삭제?")&&o.mutate(l.id)},className:"text-red-400 hover:text-red-300",children:c.jsx(vo,{size:14})})]})]}),c.jsx("div",{className:"bg-panel border border-edge rounded p-3 flex items-center justify-center",style:{height:Math.min((l.height||76)/2+40,120)},children:c.jsxs("div",{className:"text-center",children:[c.jsxs("p",{className:"text-xs text-gray-400",children:[l.width,"×",l.height,"px"]}),c.jsx("p",{className:"text-xs text-gray-500 mt-1",children:l.description})]})}),c.jsxs("p",{className:"text-xs text-gray-500 mt-2",children:["코드: ",l.templateCode]})]},l.id)),r.length===0&&c.jsx("div",{className:"col-span-3 text-center text-gray-500 py-8",children:"템플릿이 없습니다"})]}),t&&c.jsx("div",{className:"fixed inset-0 bg-black/60 flex items-center justify-center z-50",children:c.jsxs("div",{className:"bg-card border border-edge rounded-lg p-6 w-full max-w-md",children:[c.jsxs("div",{className:"flex justify-between mb-4",children:[c.jsx("h2",{className:"font-semibold",children:t.id?"템플릿 수정":"템플릿 추가"}),c.jsx("button",{onClick:()=>n(null),children:c.jsx(Ss,{size:16})})]}),c.jsx(lce,{initial:t,onSave:l=>i.mutate(l)})]})})]})}function lce({initial:e,onSave:t}){const n=!!e.id,[r,a]=O.useState({tenantCode:e.tenantCode||"EMART",templateCode:e.templateCode||"",templateName:e.templateName||"",templateType:e.templateType||"PRICE",width:e.width??250,height:e.height??122,description:e.description||"",layoutJson:e.layoutJson||"",active:e.active!==!1,id:e.id}),i=l=>s=>a(u=>({...u,[l]:s.target.value})),o=l=>{l.preventDefault(),t({...r,width:r.width===""?null:Number(r.width),height:r.height===""?null:Number(r.height),active:r.active===!0||r.active==="true"})};return c.jsxs("form",{onSubmit:o,className:"space-y-3",children:[c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"테넌트"}),c.jsx("select",{value:r.tenantCode,onChange:i("tenantCode"),className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white",children:["TENANT_A","TENANT_B","EMART","ZIOINFO"].map(l=>c.jsx("option",{value:l,children:l},l))})]}),c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"템플릿 코드"}),c.jsx("input",{value:r.templateCode,onChange:i("templateCode"),disabled:n,required:!0,placeholder:"예: EM-PRICE-STD",className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white disabled:opacity-50"})]}),c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"템플릿명"}),c.jsx("input",{value:r.templateName,onChange:i("templateName"),required:!0,className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white"})]}),c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"유형"}),c.jsx("select",{value:r.templateType,onChange:i("templateType"),className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white",children:["PRICE","INFO","PROMO","CUSTOM"].map(l=>c.jsx("option",{value:l,children:l},l))})]}),c.jsx("div",{className:"grid grid-cols-2 gap-3",children:[{label:"너비(px)",key:"width"},{label:"높이(px)",key:"height"}].map(({label:l,key:s})=>c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:l}),c.jsx("input",{type:"number",value:r[s],onChange:i(s),className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white"})]},s))}),c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"설명"}),c.jsx("input",{value:r.description,onChange:i("description"),className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white"})]}),c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"레이아웃 JSON (선택)"}),c.jsx("textarea",{value:r.layoutJson,onChange:i("layoutJson"),rows:2,placeholder:'{"fields":[...]}',className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white font-mono"})]}),c.jsx("button",{type:"submit",className:"w-full bg-brand hover:bg-brand2 text-white py-2 rounded text-sm",children:"저장"})]})}function sce(){const e=rn(),[t,n]=O.useState("PENDING"),[r,a]=O.useState(""),{data:i=[],isLoading:o}=Vt({queryKey:["pos-cvt",t,r],queryFn:()=>yz({status:t||void 0,keyword:r||void 0})}),l=tt({mutationFn:vz,onSuccess:()=>e.invalidateQueries({queryKey:["pos-cvt"]})}),s=tt({mutationFn:gz,onSuccess:()=>e.invalidateQueries({queryKey:["pos-cvt"]})});return o?c.jsx("div",{className:"text-gray-400 p-8",children:"로딩 중..."}):c.jsxs("div",{className:"space-y-4",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("h1",{className:"text-xl font-semibold text-white",children:"POS 가격 변환"}),c.jsxs("div",{className:"flex gap-2",children:[c.jsx("input",{value:r,onChange:u=>a(u.target.value),placeholder:"상품코드·상품명 검색",className:"bg-panel border border-edge rounded px-3 py-1.5 text-sm text-gray-300 w-48"}),c.jsx("select",{value:t,onChange:u=>n(u.target.value),className:"bg-panel border border-edge rounded px-3 py-1.5 text-sm text-gray-300",children:["","PENDING","PROCESSED","ERROR","IGNORED"].map(u=>c.jsx("option",{value:u,children:u||"전체"},u))})]})]}),c.jsx("div",{className:"bg-card border border-edge rounded-lg overflow-hidden",children:c.jsxs("table",{className:"w-full text-sm",children:[c.jsx("thead",{className:"bg-panel border-b border-edge",children:c.jsx("tr",{children:["테넌트","매장","상품코드","상품명","정가","판매가","상태","수신일시","액션"].map(u=>c.jsx("th",{className:"px-3 py-3 text-left text-xs text-gray-400 font-medium",children:u},u))})}),c.jsxs("tbody",{children:[i.map(u=>{var d,f;return c.jsxs("tr",{className:"border-b border-edge hover:bg-edge/30",children:[c.jsx("td",{className:"px-3 py-3 text-brand text-xs",children:u.tenantCode}),c.jsx("td",{className:"px-3 py-3 text-gray-300 text-xs",children:u.storeName||"-"}),c.jsx("td",{className:"px-3 py-3 text-gray-300 font-mono text-xs",children:u.productCode}),c.jsx("td",{className:"px-3 py-3 text-white text-xs",children:u.productName}),c.jsx("td",{className:"px-3 py-3 text-gray-300 text-xs",children:(d=u.price)==null?void 0:d.toLocaleString()}),c.jsx("td",{className:"px-3 py-3 text-accent text-xs",children:(f=u.salePrice)==null?void 0:f.toLocaleString()}),c.jsx("td",{className:"px-3 py-3",children:c.jsx("span",{className:`px-2 py-0.5 rounded text-xs ${u.status==="PROCESSED"?"bg-green-500/20 text-green-400":u.status==="PENDING"?"bg-yellow-500/20 text-yellow-400":u.status==="ERROR"?"bg-red-500/20 text-red-400":"bg-gray-500/20 text-gray-400"}`,children:u.status})}),c.jsx("td",{className:"px-3 py-3 text-gray-500 text-xs",children:u.createdAt?new Date(u.createdAt).toLocaleString("ko-KR"):"-"}),c.jsx("td",{className:"px-3 py-3",children:u.status==="PENDING"&&c.jsxs("div",{className:"flex gap-2",children:[c.jsx("button",{onClick:()=>l.mutate(u.id),title:"처리",className:"text-green-400 hover:text-green-300",children:c.jsx(ix,{size:14})}),c.jsx("button",{onClick:()=>s.mutate(u.id),title:"무시",className:"text-gray-400 hover:text-gray-300",children:c.jsx(c5,{size:14})})]})})]},u.id)}),i.length===0&&c.jsx("tr",{children:c.jsx("td",{colSpan:9,className:"px-4 py-8 text-center text-gray-500",children:"데이터가 없습니다"})})]})]})})]})}function uce({severity:e}){const t={CRITICAL:"bg-red-500/20    text-red-400    border border-red-500/40",HIGH:"bg-orange-500/20 text-orange-400 border border-orange-500/40",MEDIUM:"bg-yellow-500/20 text-yellow-400 border border-yellow-500/40",LOW:"bg-gray-500/20   text-gray-400   border border-gray-500/40"},n=t[e]||t.LOW;return c.jsx("span",{className:`px-2 py-0.5 rounded text-xs font-medium ${n}`,children:e})}function cce(){const e=rn(),[t,n]=O.useState(""),[r,a]=O.useState("OPEN"),{data:i=[],isLoading:o}=Vt({queryKey:["alarms",t,r],queryFn:()=>bz({severity:t||void 0,status:r||void 0})}),l=tt({mutationFn:({id:u,resolution:d})=>xz(u,d),onSuccess:()=>e.invalidateQueries({queryKey:["alarms"]})}),s=tt({mutationFn:Sz,onSuccess:()=>e.invalidateQueries({queryKey:["alarms"]})});return o?c.jsx("div",{className:"text-gray-400 p-8",children:"로딩 중..."}):c.jsxs("div",{className:"space-y-4",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("h1",{className:"text-xl font-semibold text-white",children:"알람 관리"}),c.jsxs("div",{className:"flex gap-2",children:[c.jsxs("select",{value:t,onChange:u=>n(u.target.value),className:"bg-panel border border-edge rounded px-3 py-1.5 text-sm text-gray-300",children:[c.jsx("option",{value:"",children:"전체 심각도"}),["CRITICAL","HIGH","MEDIUM","LOW"].map(u=>c.jsx("option",{value:u,children:u},u))]}),c.jsxs("select",{value:r,onChange:u=>a(u.target.value),className:"bg-panel border border-edge rounded px-3 py-1.5 text-sm text-gray-300",children:[c.jsx("option",{value:"",children:"전체 상태"}),["OPEN","ACKNOWLEDGED","RESOLVED"].map(u=>c.jsx("option",{value:u,children:u},u))]})]})]}),c.jsx("div",{className:"bg-card border border-edge rounded-lg overflow-hidden",children:c.jsxs("table",{className:"w-full text-sm",children:[c.jsx("thead",{className:"bg-panel border-b border-edge",children:c.jsx("tr",{children:["매장","유형","심각도","메시지","상태","발생일시","액션"].map(u=>c.jsx("th",{className:"px-4 py-3 text-left text-xs text-gray-400 font-medium",children:u},u))})}),c.jsxs("tbody",{children:[i.map(u=>c.jsxs("tr",{className:"border-b border-edge hover:bg-edge/30 transition-colors",children:[c.jsx("td",{className:"px-4 py-3 text-gray-300",children:u.storeName||"-"}),c.jsx("td",{className:"px-4 py-3 text-gray-300",children:u.alarmType}),c.jsx("td",{className:"px-4 py-3",children:c.jsx(uce,{severity:u.severity})}),c.jsx("td",{className:"px-4 py-3 text-gray-400 max-w-xs truncate",children:u.message}),c.jsx("td",{className:"px-4 py-3",children:c.jsx("span",{className:`px-2 py-0.5 rounded text-xs ${u.status==="RESOLVED"?"bg-green-500/20 text-green-400":u.status==="OPEN"?"bg-red-500/20 text-red-400":"bg-yellow-500/20 text-yellow-400"}`,children:u.status})}),c.jsx("td",{className:"px-4 py-3 text-gray-500 text-xs",children:u.createdAt?new Date(u.createdAt).toLocaleString("ko-KR"):"-"}),c.jsx("td",{className:"px-4 py-3",children:c.jsxs("div",{className:"flex gap-2",children:[u.status!=="RESOLVED"&&c.jsx("button",{onClick:()=>l.mutate({id:u.id,resolution:"운영자 확인 후 해결"}),className:"text-green-400 hover:text-green-300",title:"해결 처리",children:c.jsx(ix,{size:14})}),c.jsx("button",{onClick:()=>{confirm("삭제?")&&s.mutate(u.id)},className:"text-red-400 hover:text-red-300",children:c.jsx(vo,{size:14})})]})})]},u.id)),i.length===0&&c.jsx("tr",{children:c.jsx("td",{colSpan:7,className:"px-4 py-8 text-center text-gray-500",children:"알람이 없습니다"})})]})]})})]})}const fce={ONLINE:c.jsx(TN,{size:14,className:"text-green-400"}),OFFLINE:c.jsx(_N,{size:14,className:"text-red-400"}),ERROR:c.jsx(kl,{size:14,className:"text-orange-400"}),UPDATING:c.jsx($l,{size:14,className:"text-yellow-400"})},dce={ONLINE:"border-green-500/30 bg-green-500/5",OFFLINE:"border-red-500/30 bg-red-500/5",ERROR:"border-orange-500/30 bg-orange-500/5",UPDATING:"border-yellow-500/30 bg-yellow-500/5"};function hce(){const e=rn(),[t,n]=$.useState(""),[r,a]=$.useState(""),{data:i=[],isLoading:o}=Vt({queryKey:["hcore",t,r],queryFn:()=>wz({deviceType:t||void 0,status:r||void 0}),refetchInterval:15e3}),l=tt({mutationFn:({id:s,status:u})=>jz(s,u),onSuccess:()=>e.invalidateQueries({queryKey:["hcore"]})});return o?c.jsx("div",{className:"text-gray-400 p-8",children:"로딩 중..."}):c.jsxs("div",{className:"space-y-4",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("h1",{className:"text-xl font-semibold text-white",children:"HCore 장치 현황"}),c.jsxs("div",{className:"flex gap-2",children:[c.jsxs("select",{value:t,onChange:s=>n(s.target.value),className:"bg-panel border border-edge rounded px-3 py-1.5 text-sm text-gray-300",children:[c.jsx("option",{value:"",children:"전체 유형"}),["GATEWAY","HUB","ESL_DEVICE"].map(s=>c.jsx("option",{value:s,children:s},s))]}),c.jsxs("select",{value:r,onChange:s=>a(s.target.value),className:"bg-panel border border-edge rounded px-3 py-1.5 text-sm text-gray-300",children:[c.jsx("option",{value:"",children:"전체 상태"}),["ONLINE","OFFLINE","ERROR","UPDATING"].map(s=>c.jsx("option",{value:s,children:s},s))]})]})]}),c.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 xl:grid-cols-4 gap-3",children:[i.map(s=>c.jsxs("div",{className:`border rounded-lg p-4 ${dce[s.status]||"border-edge bg-card"}`,children:[c.jsxs("div",{className:"flex items-center justify-between mb-2",children:[c.jsxs("div",{className:"flex items-center gap-2",children:[fce[s.status],c.jsx("span",{className:"text-xs font-mono text-gray-300",children:s.deviceId})]}),c.jsx("span",{className:"text-xs text-brand",children:s.deviceType})]}),c.jsx("p",{className:"text-xs text-gray-400",children:s.storeName||"미배정"}),c.jsxs("p",{className:"text-xs text-gray-500 mt-1",children:["FW: ",s.firmwareVersion||"-"]}),s.ipAddress&&c.jsx("p",{className:"text-xs text-gray-600 font-mono",children:s.ipAddress}),s.batteryLevel!=null&&c.jsxs("div",{className:"flex items-center gap-1 mt-2",children:[c.jsx(bN,{size:12,className:s.batteryLevel<20?"text-red-400":"text-gray-400"}),c.jsxs("span",{className:`text-xs ${s.batteryLevel<20?"text-red-400":"text-gray-400"}`,children:[s.batteryLevel,"%"]})]}),s.status==="OFFLINE"&&c.jsx("button",{onClick:()=>l.mutate({id:s.id,status:"ONLINE"}),className:"mt-2 text-xs text-brand hover:underline",children:"온라인으로 변경"})]},s.id)),i.length===0&&c.jsx("div",{className:"col-span-4 text-center text-gray-500 py-8",children:"장치가 없습니다"})]})]})}const pce={SCHEDULED:"bg-blue-500/20 text-blue-400",IN_PROGRESS:"bg-yellow-500/20 text-yellow-400",COMPLETED:"bg-green-500/20 text-green-400",CANCELLED:"bg-gray-500/20 text-gray-400"};function mce(){const{data:e=[],isLoading:t}=Vt({queryKey:["works"],queryFn:()=>Oz()});return t?c.jsx("div",{className:"text-gray-400 p-8",children:"로딩 중..."}):c.jsxs("div",{className:"space-y-4",children:[c.jsx("h1",{className:"text-xl font-semibold text-white",children:"작업 이력"}),c.jsx("div",{className:"bg-card border border-edge rounded-lg overflow-hidden",children:c.jsxs("table",{className:"w-full text-sm",children:[c.jsx("thead",{className:"bg-panel border-b border-edge",children:c.jsx("tr",{children:["테넌트","매장","작업유형","작업내용","담당자","상태","시작일시","완료일시"].map(n=>c.jsx("th",{className:"px-4 py-3 text-left text-xs text-gray-400 font-medium",children:n},n))})}),c.jsxs("tbody",{children:[e.map(n=>c.jsxs("tr",{className:"border-b border-edge hover:bg-edge/30",children:[c.jsx("td",{className:"px-4 py-3 text-brand text-xs",children:n.tenantCode}),c.jsx("td",{className:"px-4 py-3 text-gray-300",children:n.storeName||"-"}),c.jsx("td",{className:"px-4 py-3 text-gray-300 text-xs",children:n.workType}),c.jsx("td",{className:"px-4 py-3 text-gray-400 text-xs max-w-xs truncate",children:n.workContent}),c.jsx("td",{className:"px-4 py-3 text-gray-300",children:n.workerName}),c.jsx("td",{className:"px-4 py-3",children:c.jsx("span",{className:`px-2 py-0.5 rounded text-xs ${pce[n.status]||"bg-gray-500/20 text-gray-400"}`,children:n.status})}),c.jsx("td",{className:"px-4 py-3 text-gray-500 text-xs",children:n.startedAt?new Date(n.startedAt).toLocaleString("ko-KR"):"-"}),c.jsx("td",{className:"px-4 py-3 text-gray-500 text-xs",children:n.completedAt?new Date(n.completedAt).toLocaleString("ko-KR"):"-"})]},n.id)),e.length===0&&c.jsx("tr",{children:c.jsx("td",{colSpan:8,className:"px-4 py-8 text-center text-gray-500",children:"작업 이력이 없습니다"})})]})]})})]})}function yce(){const e=rn(),[t,n]=O.useState(null),{data:r=[],isLoading:a}=Vt({queryKey:["firmware"],queryFn:()=>Az()}),i=tt({mutationFn:l=>Ez(l),onSuccess:()=>{e.invalidateQueries({queryKey:["firmware"]}),n(null)}}),o=tt({mutationFn:_z,onSuccess:()=>e.invalidateQueries({queryKey:["firmware"]})});return a?c.jsx("div",{className:"text-gray-400 p-8",children:"로딩 중..."}):c.jsxs("div",{className:"space-y-4",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("h1",{className:"text-xl font-semibold text-white",children:"펌웨어 관리"}),c.jsxs("button",{onClick:()=>n({}),className:"flex items-center gap-1.5 bg-brand hover:bg-brand2 text-white px-3 py-1.5 rounded text-sm",children:[c.jsx(xs,{size:14})," 펌웨어 등록"]})]}),c.jsx("div",{className:"bg-card border border-edge rounded-lg overflow-hidden",children:c.jsxs("table",{className:"w-full text-sm",children:[c.jsx("thead",{className:"bg-panel border-b border-edge",children:c.jsx("tr",{children:["버전","테넌트","장치유형","파일명","크기","체크섬","최신","등록일","액션"].map(l=>c.jsx("th",{className:"px-4 py-3 text-left text-xs text-gray-400 font-medium",children:l},l))})}),c.jsxs("tbody",{children:[r.map(l=>c.jsxs("tr",{className:"border-b border-edge hover:bg-edge/30",children:[c.jsx("td",{className:"px-4 py-3 text-brand font-mono text-xs",children:l.firmwareVersion}),c.jsx("td",{className:"px-4 py-3 text-gray-400 text-xs",children:l.tenantCode}),c.jsx("td",{className:"px-4 py-3 text-gray-300 text-xs",children:l.deviceType}),c.jsx("td",{className:"px-4 py-3 text-gray-300 text-xs",children:l.fileName}),c.jsx("td",{className:"px-4 py-3 text-gray-400 text-xs",children:l.fileSize?`${(l.fileSize/1024).toFixed(1)}KB`:"-"}),c.jsx("td",{className:"px-4 py-3 text-gray-500 text-xs font-mono truncate max-w-[80px]",children:l.checksum?l.checksum.substring(0,8)+"...":"-"}),c.jsx("td",{className:"px-4 py-3",children:l.latest&&c.jsx(I5,{size:14,className:"text-yellow-400",fill:"currentColor"})}),c.jsx("td",{className:"px-4 py-3 text-gray-500 text-xs",children:l.createdAt?new Date(l.createdAt).toLocaleDateString("ko-KR"):"-"}),c.jsx("td",{className:"px-4 py-3",children:c.jsx("button",{onClick:()=>{confirm("삭제?")&&o.mutate(l.id)},className:"text-red-400 hover:text-red-300",children:c.jsx(vo,{size:14})})})]},l.id)),r.length===0&&c.jsx("tr",{children:c.jsx("td",{colSpan:9,className:"px-4 py-8 text-center text-gray-500",children:"펌웨어가 없습니다"})})]})]})}),t&&c.jsx("div",{className:"fixed inset-0 bg-black/60 flex items-center justify-center z-50",children:c.jsxs("div",{className:"bg-card border border-edge rounded-lg p-6 w-full max-w-md",children:[c.jsxs("div",{className:"flex justify-between mb-4",children:[c.jsx("h2",{className:"font-semibold",children:"펌웨어 등록"}),c.jsx("button",{onClick:()=>n(null),children:c.jsx(Ss,{size:16})})]}),c.jsx(vce,{onSave:l=>i.mutate(l)})]})})]})}function vce({onSave:e}){const[t,n]=O.useState({tenantCode:"EMART",firmwareVersion:"",deviceType:"ESL_DEVICE",fileName:"",filePath:"",fileSize:"",checksum:"",description:"",latest:!0}),r=i=>o=>n(l=>({...l,[i]:o.target.value})),a=i=>{i.preventDefault(),e({...t,fileSize:t.fileSize===""?null:Number(t.fileSize),latest:t.latest===!0||t.latest==="true"})};return c.jsxs("form",{onSubmit:a,className:"space-y-3",children:[c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"테넌트"}),c.jsx("select",{value:t.tenantCode,onChange:r("tenantCode"),className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white",children:["TENANT_A","TENANT_B","EMART","ZIOINFO"].map(i=>c.jsx("option",{value:i,children:i},i))})]}),c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"장치 유형"}),c.jsx("select",{value:t.deviceType,onChange:r("deviceType"),className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white",children:["GATEWAY","HUB","ESL_DEVICE"].map(i=>c.jsx("option",{value:i,children:i},i))})]}),[{label:"펌웨어 버전",key:"firmwareVersion",ph:"예: v1.2.3",required:!0},{label:"파일명",key:"fileName",ph:"firmware_v1.2.3.bin"},{label:"파일 경로",key:"filePath",ph:"/opt/esn/firmware/..."},{label:"파일 크기(byte)",key:"fileSize",type:"number"},{label:"체크섬(SHA256)",key:"checksum"}].map(({label:i,key:o,ph:l,type:s,required:u})=>c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:i}),c.jsx("input",{type:s||"text",value:t[o],onChange:r(o),placeholder:l,required:u,className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white"})]},o)),c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"설명"}),c.jsx("textarea",{value:t.description,onChange:r("description"),rows:2,className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white"})]}),c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"최신 버전 지정"}),c.jsxs("select",{value:String(t.latest),onChange:r("latest"),className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white",children:[c.jsx("option",{value:"true",children:"최신으로 지정"}),c.jsx("option",{value:"false",children:"일반"})]})]}),c.jsx("button",{type:"submit",className:"w-full bg-brand hover:bg-brand2 text-white py-2 rounded text-sm",children:"등록"})]})}function gce(){const e=rn(),[t,n]=O.useState(null),{data:r=[],isLoading:a}=Vt({queryKey:["users"],queryFn:()=>Tz()}),i=tt({mutationFn:s=>s.id?Cz(s.id,s):Nz(s),onSuccess:()=>{e.invalidateQueries({queryKey:["users"]}),n(null)}}),o=tt({mutationFn:Mz,onSuccess:()=>e.invalidateQueries({queryKey:["users"]})}),l=tt({mutationFn:JL,onSuccess:()=>e.invalidateQueries({queryKey:["users"]})});return a?c.jsx("div",{className:"text-gray-400 p-8",children:"로딩 중..."}):c.jsxs("div",{className:"space-y-4",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("h1",{className:"text-xl font-semibold text-white",children:"사용자 관리"}),c.jsxs("button",{onClick:()=>n({}),className:"flex items-center gap-1.5 bg-brand hover:bg-brand2 text-white px-3 py-1.5 rounded text-sm",children:[c.jsx(xs,{size:14})," 사용자 추가"]})]}),c.jsx("div",{className:"bg-card border border-edge rounded-lg overflow-hidden",children:c.jsxs("table",{className:"w-full text-sm",children:[c.jsx("thead",{className:"bg-panel border-b border-edge",children:c.jsx("tr",{children:["아이디","테넌트","역할","이메일","전화","상태","마지막 로그인","액션"].map(s=>c.jsx("th",{className:"px-4 py-3 text-left text-xs text-gray-400 font-medium",children:s},s))})}),c.jsxs("tbody",{children:[r.map(s=>c.jsxs("tr",{className:"border-b border-edge hover:bg-edge/30",children:[c.jsx("td",{className:"px-4 py-3 text-white font-medium",children:s.username}),c.jsx("td",{className:"px-4 py-3 text-brand text-xs",children:s.tenantCode||"SUPER"}),c.jsx("td",{className:"px-4 py-3",children:c.jsx("span",{className:`px-2 py-0.5 rounded text-xs ${s.role==="ADMIN"?"bg-red-500/20 text-red-400":s.role==="MANAGER"?"bg-brand/20 text-brand":"bg-gray-500/20 text-gray-400"}`,children:s.role})}),c.jsx("td",{className:"px-4 py-3 text-gray-400 text-xs",children:s.email||"-"}),c.jsx("td",{className:"px-4 py-3 text-gray-400 text-xs",children:s.phone||"-"}),c.jsx("td",{className:"px-4 py-3",children:c.jsx("span",{className:`px-2 py-0.5 rounded text-xs ${s.active?"bg-green-500/20 text-green-400":"bg-gray-500/20 text-gray-400"}`,children:s.active?"활성":"비활성"})}),c.jsx("td",{className:"px-4 py-3 text-gray-500 text-xs",children:s.lastLoginAt?new Date(s.lastLoginAt).toLocaleString("ko-KR"):"-"}),c.jsx("td",{className:"px-4 py-3",children:c.jsxs("div",{className:"flex gap-2",children:[c.jsx("button",{onClick:()=>n(s),title:"수정",className:"text-brand hover:text-blue-300",children:c.jsx(Vc,{size:14})}),c.jsx("button",{onClick:()=>{confirm(`'${s.username}' 사용자의 OTP를 초기화하시겠습니까?
초기화하면 다음 로그인 시 재등록해야 합니다.`)&&l.mutate(s.id)},title:"OTP 초기화",className:"text-gray-400 hover:text-brand",children:c.jsx(Yc,{size:14})}),c.jsx("button",{onClick:()=>{confirm("삭제?")&&o.mutate(s.id)},title:"삭제",className:"text-red-400 hover:text-red-300",children:c.jsx(vo,{size:14})})]})})]},s.id)),r.length===0&&c.jsx("tr",{children:c.jsx("td",{colSpan:8,className:"px-4 py-8 text-center text-gray-500",children:"사용자가 없습니다"})})]})]})}),t&&c.jsx("div",{className:"fixed inset-0 bg-black/60 flex items-center justify-center z-50",children:c.jsxs("div",{className:"bg-card border border-edge rounded-lg p-6 w-full max-w-md",children:[c.jsxs("div",{className:"flex justify-between mb-4",children:[c.jsx("h2",{className:"font-semibold",children:t.id?"사용자 수정":"사용자 추가"}),c.jsx("button",{onClick:()=>n(null),children:c.jsx(Ss,{size:16})})]}),c.jsx(bce,{initial:t,onSave:s=>i.mutate(s)})]})})]})}function bce({initial:e,onSave:t}){const n=!!e.id,[r,a]=O.useState({username:e.username||"",role:e.role||"USER",tenantCode:e.tenantCode||"",email:e.email||"",phone:e.phone||"",password:"",active:e.active!==!1,id:e.id}),i=l=>s=>a(u=>({...u,[l]:s.target.value})),o=l=>{l.preventDefault();const s={username:r.username,role:r.role,tenantCode:r.tenantCode||null,email:r.email||null,phone:r.phone||null,active:r.active===!0||r.active==="true",id:r.id};!n&&r.password&&(s.password=r.password),t(s)};return c.jsxs("form",{onSubmit:o,className:"space-y-3",children:[c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"아이디"}),c.jsx("input",{value:r.username,onChange:i("username"),disabled:n,required:!0,className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white disabled:opacity-50"})]}),!n&&c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"초기 비밀번호 (미입력 시 changeme123)"}),c.jsx("input",{type:"password",value:r.password,onChange:i("password"),autoComplete:"new-password",className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white"})]}),c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"역할"}),c.jsx("select",{value:r.role,onChange:i("role"),className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white",children:["ADMIN","MANAGER","USER"].map(l=>c.jsx("option",{value:l,children:l},l))})]}),c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"테넌트 (SUPER는 비움)"}),c.jsxs("select",{value:r.tenantCode,onChange:i("tenantCode"),className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white",children:[c.jsx("option",{value:"",children:"(SUPER / 전체)"}),["TENANT_A","TENANT_B","EMART","ZIOINFO"].map(l=>c.jsx("option",{value:l,children:l},l))]})]}),[{label:"이메일",key:"email",type:"email"},{label:"전화",key:"phone"}].map(({label:l,key:s,type:u})=>c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:l}),c.jsx("input",{type:u||"text",value:r[s],onChange:i(s),className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white"})]},s)),c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"상태"}),c.jsxs("select",{value:String(r.active),onChange:i("active"),className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white",children:[c.jsx("option",{value:"true",children:"활성"}),c.jsx("option",{value:"false",children:"비활성"})]})]}),c.jsx("button",{type:"submit",className:"w-full bg-brand hover:bg-brand2 text-white py-2 rounded text-sm",children:"저장"})]})}function xce(){const e=rn(),[t,n]=O.useState(""),[r,a]=O.useState(null),{data:i=[],isLoading:o}=Vt({queryKey:["products",t],queryFn:()=>Rz({keyword:t||void 0})}),l=tt({mutationFn:u=>u.id?$z(u.id,u):Pz(u),onSuccess:()=>{e.invalidateQueries({queryKey:["products"]}),a(null)}}),s=tt({mutationFn:kz,onSuccess:()=>e.invalidateQueries({queryKey:["products"]})});return o?c.jsx("div",{className:"text-gray-400 p-8",children:"로딩 중..."}):c.jsxs("div",{className:"space-y-4",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("h1",{className:"text-xl font-semibold text-white",children:"상품/가격 관리"}),c.jsxs("div",{className:"flex gap-2",children:[c.jsx("input",{value:t,onChange:u=>n(u.target.value),placeholder:"상품명·코드 검색",className:"bg-panel border border-edge rounded px-3 py-1.5 text-sm text-gray-300 w-48"}),c.jsxs("button",{onClick:()=>a({}),className:"flex items-center gap-1.5 bg-brand hover:bg-brand2 text-white px-3 py-1.5 rounded text-sm",children:[c.jsx(xs,{size:14})," 상품 추가"]})]})]}),c.jsx("div",{className:"bg-card border border-edge rounded-lg overflow-hidden",children:c.jsxs("table",{className:"w-full text-sm",children:[c.jsx("thead",{className:"bg-panel border-b border-edge",children:c.jsx("tr",{children:["테넌트","매장","상품코드","상품명","카테고리","정가","판매가","화폐","상태","액션"].map(u=>c.jsx("th",{className:"px-3 py-3 text-left text-xs text-gray-400 font-medium",children:u},u))})}),c.jsxs("tbody",{children:[i.map(u=>{var d,f;return c.jsxs("tr",{className:"border-b border-edge hover:bg-edge/30",children:[c.jsx("td",{className:"px-3 py-3 text-brand text-xs",children:u.tenantCode}),c.jsx("td",{className:"px-3 py-3 text-gray-400 text-xs",children:u.storeName||"-"}),c.jsx("td",{className:"px-3 py-3 text-gray-300 font-mono text-xs",children:u.productCode}),c.jsx("td",{className:"px-3 py-3 text-white",children:u.productName}),c.jsx("td",{className:"px-3 py-3 text-gray-400 text-xs",children:u.category}),c.jsx("td",{className:"px-3 py-3 text-gray-300 text-xs",children:(d=u.price)==null?void 0:d.toLocaleString()}),c.jsx("td",{className:"px-3 py-3 text-accent text-xs font-medium",children:(f=u.salePrice)==null?void 0:f.toLocaleString()}),c.jsx("td",{className:"px-3 py-3 text-gray-500 text-xs",children:u.currency}),c.jsx("td",{className:"px-3 py-3",children:c.jsx("span",{className:`px-2 py-0.5 rounded text-xs ${u.active?"bg-green-500/20 text-green-400":"bg-gray-500/20 text-gray-400"}`,children:u.active?"활성":"비활성"})}),c.jsx("td",{className:"px-3 py-3",children:c.jsxs("div",{className:"flex gap-2",children:[c.jsx("button",{onClick:()=>a(u),className:"text-brand hover:text-blue-300",children:c.jsx(Vc,{size:14})}),c.jsx("button",{onClick:()=>{confirm("삭제?")&&s.mutate(u.id)},className:"text-red-400 hover:text-red-300",children:c.jsx(vo,{size:14})})]})})]},u.id)}),i.length===0&&c.jsx("tr",{children:c.jsx("td",{colSpan:10,className:"px-4 py-8 text-center text-gray-500",children:"상품이 없습니다"})})]})]})}),r&&c.jsx("div",{className:"fixed inset-0 bg-black/60 flex items-center justify-center z-50",children:c.jsxs("div",{className:"bg-card border border-edge rounded-lg p-6 w-full max-w-md",children:[c.jsxs("div",{className:"flex justify-between mb-4",children:[c.jsx("h2",{className:"font-semibold",children:r.id?"상품 수정 / 가격 변경":"상품 추가"}),c.jsx("button",{onClick:()=>a(null),children:c.jsx(Ss,{size:16})})]}),c.jsx(Sce,{initial:r,onSave:u=>l.mutate(u)})]})})]})}function Sce({initial:e,onSave:t}){const[n,r]=O.useState({tenantCode:e.tenantCode||"EMART",storeId:e.storeId??"",productCode:e.productCode||"",productName:e.productName||"",category:e.category||"",price:e.price??"",salePrice:e.salePrice??"",currency:e.currency||"KRW",active:e.active!==!1,id:e.id}),a=o=>l=>r(s=>({...s,[o]:l.target.value})),i=o=>{o.preventDefault(),t({...n,storeId:n.storeId===""?null:Number(n.storeId),price:n.price===""?null:Number(n.price),salePrice:n.salePrice===""?null:Number(n.salePrice),active:n.active===!0||n.active==="true"})};return c.jsxs("form",{onSubmit:i,className:"space-y-3",children:[c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"테넌트"}),c.jsx("select",{value:n.tenantCode,onChange:a("tenantCode"),className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white",children:["TENANT_A","TENANT_B","EMART","ZIOINFO"].map(o=>c.jsx("option",{value:o,children:o},o))})]}),[{label:"매장 ID",key:"storeId",type:"number",ph:"예: 1"},{label:"상품코드",key:"productCode"},{label:"상품명",key:"productName"},{label:"카테고리",key:"category"},{label:"정가",key:"price",type:"number"},{label:"판매가",key:"salePrice",type:"number"}].map(({label:o,key:l,type:s,ph:u})=>c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:o}),c.jsx("input",{type:s||"text",value:n[l],onChange:a(l),placeholder:u,className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white"})]},l)),c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"화폐"}),c.jsx("select",{value:n.currency,onChange:a("currency"),className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white",children:["KRW","USD","EUR"].map(o=>c.jsx("option",{value:o,children:o},o))})]}),c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"상태"}),c.jsxs("select",{value:String(n.active),onChange:a("active"),className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white",children:[c.jsx("option",{value:"true",children:"활성"}),c.jsx("option",{value:"false",children:"비활성"})]})]}),c.jsx("button",{type:"submit",className:"w-full bg-brand hover:bg-brand2 text-white py-2 rounded text-sm",children:"저장"})]})}function wce(){const e=rn(),[t,n]=O.useState(null),{data:r=[],isLoading:a}=Vt({queryKey:["tenants"],queryFn:()=>az()}),i=tt({mutationFn:s=>s.id?oz(s.id,s):iz(s),onSuccess:()=>{e.invalidateQueries({queryKey:["tenants"]}),n(null)}}),o=tt({mutationFn:lz,onSuccess:()=>e.invalidateQueries({queryKey:["tenants"]})});return a?c.jsx("div",{className:"text-gray-400 p-8",children:"로딩 중..."}):localStorage.getItem("esn_role")!=="ADMIN"?c.jsx("div",{className:"text-center py-16",children:c.jsx("p",{className:"text-gray-400",children:"관리자 전용 메뉴입니다."})}):c.jsxs("div",{className:"space-y-4",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("h1",{className:"text-xl font-semibold text-white",children:"테넌트 관리"}),c.jsxs("button",{onClick:()=>n({}),className:"flex items-center gap-1.5 bg-brand hover:bg-brand2 text-white px-3 py-1.5 rounded text-sm",children:[c.jsx(xs,{size:14})," 테넌트 추가"]})]}),c.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-4 gap-4",children:[r.map(s=>c.jsxs("div",{className:"bg-card border border-edge rounded-lg p-4",children:[c.jsxs("div",{className:"flex items-center justify-between mb-3",children:[c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsx(wN,{size:18,className:"text-brand"}),c.jsx("span",{className:"font-bold text-brand",children:s.tenantCode})]}),c.jsxs("div",{className:"flex gap-2",children:[c.jsx("button",{onClick:()=>n(s),className:"text-brand hover:text-blue-300",children:c.jsx(Vc,{size:14})}),c.jsx("button",{onClick:()=>{confirm("삭제?")&&o.mutate(s.id)},className:"text-red-400 hover:text-red-300",children:c.jsx(vo,{size:14})})]})]}),c.jsx("p",{className:"text-sm text-white",children:s.tenantName}),c.jsx("p",{className:"text-xs text-gray-400 mt-1",children:s.description}),c.jsx("div",{className:"mt-3",children:c.jsx("span",{className:`px-2 py-0.5 rounded text-xs ${s.active?"bg-green-500/20 text-green-400":"bg-gray-500/20 text-gray-400"}`,children:s.active?"운영중":"비활성"})})]},s.id)),r.length===0&&c.jsx("div",{className:"col-span-full text-center text-gray-500 py-12",children:"테넌트가 없습니다"})]}),t&&c.jsx("div",{className:"fixed inset-0 bg-black/60 flex items-center justify-center z-50",children:c.jsxs("div",{className:"bg-card border border-edge rounded-lg p-6 w-full max-w-md",children:[c.jsxs("div",{className:"flex justify-between mb-4",children:[c.jsx("h2",{className:"font-semibold",children:t.id?"테넌트 수정":"테넌트 추가"}),c.jsx("button",{onClick:()=>n(null),children:c.jsx(Ss,{size:16})})]}),c.jsx(jce,{initial:t,onSave:s=>i.mutate(s)})]})})]})}function jce({initial:e,onSave:t}){const n=!!e.id,[r,a]=O.useState({tenantCode:e.tenantCode||"",tenantName:e.tenantName||"",description:e.description||"",active:e.active!==!1,id:e.id}),i=l=>s=>a(u=>({...u,[l]:s.target.value})),o=l=>{l.preventDefault(),t({...r,active:r.active===!0||r.active==="true"})};return c.jsxs("form",{onSubmit:o,className:"space-y-3",children:[c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"테넌트 코드"}),c.jsx("input",{value:r.tenantCode,onChange:i("tenantCode"),disabled:n,required:!0,placeholder:"예: EMART",className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white disabled:opacity-50"})]}),c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"테넌트명"}),c.jsx("input",{value:r.tenantName,onChange:i("tenantName"),required:!0,className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white"})]}),c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"설명"}),c.jsx("textarea",{value:r.description,onChange:i("description"),rows:2,className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white"})]}),c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"상태"}),c.jsxs("select",{value:String(r.active),onChange:i("active"),className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-white",children:[c.jsx("option",{value:"true",children:"운영중"}),c.jsx("option",{value:"false",children:"비활성"})]})]}),c.jsx("button",{type:"submit",className:"w-full bg-brand hover:bg-brand2 text-white py-2 rounded text-sm",children:"저장"})]})}const Oce=()=>H.get("/api/admin/ai-config").then(e=>{var t;return(t=e.data)==null?void 0:t.data}),Ace=e=>H.put("/api/admin/ai-config",e).then(t=>{var n;return(n=t.data)==null?void 0:n.data}),Ece=()=>H.post("/api/admin/ai-config/test",{}).then(e=>{var t;return(t=e.data)==null?void 0:t.data}),_ce=e=>H.post("/api/ai/feedback",e).then(t=>{var n;return(n=t.data)==null?void 0:n.data});function jA({feature:e,question:t,answer:n,answerId:r,tenantCode:a}){const[i,o]=O.useState(null),[l,s]=O.useState(""),[u,d]=O.useState(!1),[f,h]=O.useState(!1),p=async(m,y)=>{h(!0);try{await _ce({feature:e,question:t,answer:n,verdict:m,correction:y,answerId:r,tenantCode:a}),d(!0)}catch{d(!0)}finally{h(!1)}},b=()=>{o("up"),p("up")},v=()=>{o("down")},x=()=>p("down",l.trim()||void 0);return u?c.jsx("div",{className:"mt-2 text-[11px] text-emerald-300",children:"피드백 감사합니다. 학습에 반영됩니다."}):c.jsxs("div",{className:"mt-3 flex flex-col gap-2",children:[c.jsxs("div",{className:"flex items-center gap-2 text-[11px] text-slate-500",children:[c.jsx("span",{children:"이 답변이 도움이 되었나요?"}),c.jsx("button",{onClick:b,disabled:f,className:`p-1.5 rounded border ${i==="up"?"bg-emerald-500/15 border-emerald-500/40 text-emerald-300":"border-edge text-slate-400 hover:border-emerald-500/50"}`,"aria-label":"도움됨",children:c.jsx(H5,{size:13})}),c.jsx("button",{onClick:v,disabled:f,className:`p-1.5 rounded border ${i==="down"?"bg-rose-500/15 border-rose-500/40 text-rose-300":"border-edge text-slate-400 hover:border-rose-500/50"}`,"aria-label":"도움안됨",children:c.jsx(q5,{size:13})})]}),i==="down"&&c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsx("input",{value:l,onChange:m=>s(m.target.value),placeholder:"올바른 답/개선 의견(선택)",className:"flex-1 bg-ink border border-edge rounded px-2 py-1 text-xs text-slate-300 placeholder-slate-600"}),c.jsxs("button",{onClick:x,disabled:f,className:"flex items-center gap-1 px-2 py-1 rounded bg-brand/20 text-brand border border-brand/40 text-xs disabled:opacity-40",children:[c.jsx(ag,{size:12})," 전송"]})]})]})}function Tce(){const[e,t]=O.useState(""),[n,r]=O.useState(""),[a,i]=O.useState(""),[o,l]=O.useState(""),s=tt({mutationFn:Bz,onSuccess:d=>r(d.analysis||JSON.stringify(d)),onError:()=>r("Ollama 응답 실패 — 서비스를 확인해주세요.")}),u=tt({mutationFn:Iz,onSuccess:d=>l(d.category||JSON.stringify(d)),onError:()=>l("Ollama 응답 실패 — 서비스를 확인해주세요.")});return c.jsxs("div",{className:"space-y-6",children:[c.jsxs("h1",{className:"text-xl font-semibold text-white flex items-center gap-2",children:[c.jsx(SN,{size:20,className:"text-brand"})," AI 분석"]}),c.jsxs("div",{className:"bg-card border border-edge rounded-lg p-5",children:[c.jsxs("h2",{className:"text-sm font-medium text-white mb-3 flex items-center gap-2",children:[c.jsx(kl,{size:16,className:"text-yellow-400"})," 알람 원인 분석"]}),c.jsx("textarea",{value:e,onChange:d=>t(d.target.value),rows:4,placeholder:`알람 메시지를 입력하세요
예: ESL-001 배터리 부족 경고 — Store: A매장 구미, Device: ESL-A123`,className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-gray-300 placeholder-gray-600 resize-none mb-3"}),c.jsxs("button",{onClick:()=>s.mutate({message:e}),disabled:!e.trim()||s.isPending,className:"flex items-center gap-2 px-4 py-2 bg-brand/20 text-brand border border-brand/40 rounded hover:bg-brand/30 disabled:opacity-40 text-sm",children:[c.jsx(lg,{size:14}),s.isPending?"분석 중...":"Ollama 분석"]}),n&&c.jsxs("div",{className:"mt-4 bg-panel border border-edge rounded p-4",children:[c.jsx("div",{className:"text-sm text-gray-300 whitespace-pre-wrap",children:n}),c.jsx(jA,{feature:"alarm-analysis",question:e,answer:n})]})]}),c.jsxs("div",{className:"bg-card border border-edge rounded-lg p-5",children:[c.jsxs("h2",{className:"text-sm font-medium text-white mb-3 flex items-center gap-2",children:[c.jsx(U5,{size:16,className:"text-accent"})," POS 데이터 자동 분류"]}),c.jsx("textarea",{value:a,onChange:d=>i(d.target.value),rows:4,placeholder:`POS 데이터를 입력하세요
예: 상품코드=P001, 상품명=과자, 가격=1500, 판매수량=100, 점포=이마트 광명점`,className:"w-full bg-panel border border-edge rounded px-3 py-2 text-sm text-gray-300 placeholder-gray-600 resize-none mb-3"}),c.jsxs("button",{onClick:()=>u.mutate({data:a}),disabled:!a.trim()||u.isPending,className:"flex items-center gap-2 px-4 py-2 bg-accent/20 text-accent border border-accent/40 rounded hover:bg-accent/30 disabled:opacity-40 text-sm",children:[c.jsx(lg,{size:14}),u.isPending?"분류 중...":"Ollama 분류"]}),o&&c.jsxs("div",{className:"mt-4 bg-panel border border-edge rounded p-4",children:[c.jsx("div",{className:"text-sm text-gray-300 whitespace-pre-wrap",children:o}),c.jsx(jA,{feature:"pos-classify",question:a,answer:o})]})]})]})}const OA=["LGINNOTEK","LGIT","EMART","ZIOINFO"],Nce=[{key:"rag.enabled",label:"RAG 경유 사용",desc:"끄면 기존 Ollama/룰 경로로 동작"},{key:"rag.rerank",label:"리랭킹 (rerank)",desc:"검색 결과 재정렬 — 품질↑·비용↑",heavy:!0},{key:"rag.graphrag",label:"GraphRAG (의존성 추적)",desc:"허브→단말 연쇄 원인 추적 — 무거움",heavy:!0},{key:"rag.tool_use",label:"에이전틱 tool-use (/agent)",desc:"다단계 진단 루프 — 무거움",heavy:!0},{key:"rag.structured",label:"구조화 출력 (/structured)",desc:"결정론 JSON — POS 분류 권장 on"},{key:"rag.stream",label:"토큰 스트리밍 (SSE)",desc:"긴 답변 점진 표시 — 동시 스트림 제한",heavy:!0}];function Cce(){const e=rn(),[t,n]=O.useState(OA[3]),[r,a]=O.useState({}),{data:i,isLoading:o}=Vt({queryKey:["rag-toggles",t],queryFn:()=>Uz(t)}),l=tt({mutationFn:({key:u,value:d})=>qz(u,d,t),onSuccess:()=>e.invalidateQueries({queryKey:["rag-toggles",t]})});if(o)return c.jsx("div",{className:"text-gray-400 p-8",children:"로딩 중..."});const s=i||{};return c.jsxs("div",{className:"space-y-6",children:[c.jsxs("h1",{className:"text-xl font-semibold text-white flex items-center gap-2",children:[c.jsx(EN,{size:20,className:"text-brand"})," AI 기법 설정 (중앙 guardia-rag)"]}),c.jsx("p",{className:"text-xs text-gray-500",children:"테넌트별로 격리되어 저장됩니다. 무거운 기법(리랭킹·GraphRAG·tool-use·스트리밍)은 서버 RAM 보호를 위해 기본 OFF입니다. 변경은 MANAGER 이상 권한이 필요합니다."}),c.jsxs("div",{className:"bg-card border border-edge rounded-lg p-5 flex flex-wrap items-center gap-4",children:[c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsx(L5,{size:16,className:"text-accent"}),c.jsx("span",{className:"text-sm text-gray-300",children:"테넌트"}),c.jsx("select",{value:t,onChange:u=>{n(u.target.value),a({})},className:"bg-panel border border-edge rounded px-3 py-1.5 text-sm text-gray-100",children:OA.map(u=>c.jsx("option",{value:u,children:u},u))})]}),c.jsxs("div",{className:"flex items-center gap-2 text-sm",children:[c.jsx("span",{className:"text-gray-400",children:"중앙 RAG:"}),s.ragAvailable?c.jsx("span",{className:"px-2 py-0.5 rounded bg-green-500/20 text-green-300 text-xs",children:"가용"}):c.jsx("span",{className:"px-2 py-0.5 rounded bg-amber-500/20 text-amber-300 text-xs",children:"미가용 (degraded 폴백)"})]})]}),c.jsxs("div",{className:"bg-card border border-edge rounded-lg p-5 space-y-3",children:[c.jsxs("h2",{className:"text-sm font-medium text-white flex items-center gap-2 mb-2",children:[c.jsx(S5,{size:16,className:"text-brand"})," 기법 On/Off"]}),Nce.map(u=>{const d=!!s[Mce(u.key)];return c.jsxs("div",{className:"flex items-center justify-between border-b border-edge/60 pb-3",children:[c.jsxs("div",{children:[c.jsxs("div",{className:"text-sm text-gray-200 flex items-center gap-2",children:[u.label,u.heavy&&c.jsx("span",{className:"px-1.5 py-0.5 rounded bg-amber-500/20 text-amber-300 text-[10px]",children:"무거움"})]}),c.jsx("div",{className:"text-xs text-gray-500",children:u.desc})]}),c.jsx("button",{onClick:()=>l.mutate({key:u.key,value:!d}),disabled:l.isPending,className:`relative w-11 h-6 rounded-full transition ${d?"bg-brand":"bg-edge"}`,children:c.jsx("span",{className:`absolute top-0.5 left-0.5 w-5 h-5 rounded-full bg-white transition ${d?"translate-x-5":""}`})})]},u.key)})]}),c.jsxs("div",{className:"bg-card border border-edge rounded-lg p-5 space-y-4",children:[c.jsxs("h2",{className:"text-sm font-medium text-white flex items-center gap-2 mb-2",children:[c.jsx(B5,{size:16,className:"text-accent"})," 파라미터"]}),c.jsx(Xh,{label:"검색 모드 (retrieval_mode)",hint:"vector | hybrid | graph (GraphRAG on 이면 graph 강제)",children:c.jsxs("select",{value:r["rag.retrieval_mode"]??s.retrievalMode??"vector",onChange:u=>a(d=>({...d,"rag.retrieval_mode":u.target.value})),className:"bg-panel border border-edge rounded px-3 py-1.5 text-sm text-gray-100",children:[c.jsx("option",{value:"vector",children:"vector"}),c.jsx("option",{value:"hybrid",children:"hybrid (BM25+벡터)"}),c.jsx("option",{value:"graph",children:"graph (GraphRAG)"})]})}),c.jsx(AA,{label:"top_k (검색 문서 수)",k:"rag.top_k",cur:s.topK,min:1,max:20,draft:r,setDraft:a}),c.jsx(AA,{label:"에이전트 최대 스텝 (agent_max_steps)",k:"rag.agent_max_steps",cur:s.agentMaxSteps,min:1,max:8,draft:r,setDraft:a}),c.jsx(EA,{label:"temperature",k:"rag.temperature",cur:s.temperature,draft:r,setDraft:a}),c.jsx(EA,{label:"신뢰도 임계 (faithfulness_threshold)",k:"rag.faithfulness_threshold",cur:s.faithfulnessThreshold,draft:r,setDraft:a}),c.jsx(Xh,{label:"생성 모델 (generation_model)",hint:"소형 모델 권장 (예: llama3.2:1b)",children:c.jsx("input",{value:r["rag.generation_model"]??s.generationModel??"",onChange:u=>a(d=>({...d,"rag.generation_model":u.target.value})),className:"bg-panel border border-edge rounded px-3 py-1.5 text-sm text-gray-100 w-48"})}),c.jsxs("div",{className:"pt-2 flex flex-wrap gap-2",children:[Object.keys(r).map(u=>c.jsxs("button",{onClick:()=>l.mutate({key:u,value:r[u]}),disabled:l.isPending,className:"text-xs px-3 py-1.5 rounded bg-brand/80 text-white hover:bg-brand",children:["저장: ",u.replace("rag.","")]},u)),Object.keys(r).length>0&&c.jsx("button",{onClick:()=>a({}),className:"text-xs px-3 py-1.5 rounded bg-edge/60 text-gray-300 hover:bg-edge",children:"변경 취소"})]})]})]})}function Mce(e){return{"rag.enabled":"ragEnabled","rag.rerank":"rerank","rag.graphrag":"graphrag","rag.tool_use":"toolUse","rag.structured":"structured","rag.stream":"stream"}[e]||e}function Xh({label:e,hint:t,children:n}){return c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{children:[c.jsx("div",{className:"text-sm text-gray-200",children:e}),t&&c.jsx("div",{className:"text-xs text-gray-500",children:t})]}),n]})}function AA({label:e,k:t,cur:n,min:r,max:a,draft:i,setDraft:o}){return c.jsx(Xh,{label:e,hint:`범위 ${r}~${a}`,children:c.jsx("input",{type:"number",min:r,max:a,value:i[t]??n??r,onChange:l=>o(s=>({...s,[t]:l.target.value})),className:"bg-panel border border-edge rounded px-3 py-1.5 text-sm text-gray-100 w-24"})})}function EA({label:e,k:t,cur:n,draft:r,setDraft:a}){return c.jsx(Xh,{label:e,hint:"0.0 ~ 1.0",children:c.jsx("input",{type:"number",step:"0.1",min:0,max:1,value:r[t]??n??0,onChange:i=>a(o=>({...o,[t]:i.target.value})),className:"bg-panel border border-edge rounded px-3 py-1.5 text-sm text-gray-100 w-24"})})}const Rce=[{id:"ollama",label:"Ollama (기본)",hint:"온프레미스 · llama3.2:1b"},{id:"qwen3",label:"Qwen3",hint:"온프레미스 · qwen3:1.7b"},{id:"deepseek",label:"DeepSeek",hint:"온프레미스 · deepseek-r1:1.5b"},{id:"glm",label:"GLM",hint:"온프레미스 · glm4:9b",ramWarn:!0},{id:"claude",label:"Claude (외부)",hint:"api.anthropic.com · 키 필요"}],LR=["claude-sonnet-4-6","claude-haiku-4-5","claude-opus-4-8"],dd="claude-sonnet-4-6",Iy=e=>LR.includes(e)?e:dd;function Uy(e){var n,r,a;const t=((r=(n=e==null?void 0:e.response)==null?void 0:n.data)==null?void 0:r.message)||"";return((a=e==null?void 0:e.response)==null?void 0:a.status)===403?"권한이 없습니다 (AI 설정은 ADMIN 전용).":t.includes("ERR-AI-400")?t.replace(/^ERR-AI-400:\s*/,""):"AI 설정을 처리하지 못했습니다."}function Pce(){const[e,t]=O.useState("ollama"),[n,r]=O.useState(dd),[a,i]=O.useState(!1),[o,l]=O.useState(""),[s,u]=O.useState(!0),[d,f]=O.useState(!1),[h,p]=O.useState(!1),[b,v]=O.useState(!1),[x,m]=O.useState(""),[y,g]=O.useState(!1),[S,w]=O.useState(null),j=()=>{f(!0),Oce().then(C=>{t(C.provider),r(Iy(C.claudeModel??dd)),i(!!C.claudeKeySet),l(C.ollamaTextModel??""),u(!!C.aiEnabled),m("")}).catch(C=>m(Uy(C))).finally(()=>f(!1))};O.useEffect(()=>{j()},[]);const A=()=>{v(!1),w(null)},E=async()=>{p(!0),v(!1);try{const C=await Ace({provider:e,claudeModel:n});t(C.provider),r(Iy(C.claudeModel??dd)),i(!!C.claudeKeySet),l(C.ollamaTextModel??""),u(!!C.aiEnabled),v(!0),m("")}catch(C){m(Uy(C))}finally{p(!1)}},_=async()=>{g(!0),w(null);try{w(await Ece())}catch(C){w({ok:!1,degraded:!1,message:Uy(C)})}finally{g(!1)}},N=e==="claude",D=e==="glm",R=N&&!a,B=!N&&!s,k=S?S.degraded?"text-amber-300":S.ok?"text-emerald-300":"text-rose-300":"";return c.jsxs("div",{children:[c.jsxs("div",{className:"flex items-center justify-between mb-6",children:[c.jsxs("div",{children:[c.jsxs("h1",{className:"text-xl font-bold flex items-center gap-2 text-white",children:[c.jsx($l,{size:20,className:"text-brand"})," AI 플랫폼 설정"]}),c.jsx("p",{className:"text-sm text-slate-400 mt-1",children:"알람 원인분석·POS 분류 등 텍스트 생성에 사용할 LLM 제공자와 모델을 선택합니다."})]}),c.jsx("button",{onClick:j,disabled:d,className:"px-3 py-1.5 rounded-lg bg-card border border-edge text-sm disabled:opacity-40",children:"새로고침"})]}),x&&c.jsx("div",{className:"bg-rose-500/10 border border-rose-500/40 text-rose-300 text-sm rounded-lg px-4 py-2.5 mb-4",children:x}),(R||B)&&c.jsx("div",{className:"bg-amber-500/10 border border-amber-500/40 text-amber-300 text-sm rounded-lg px-4 py-2.5 mb-4",children:R?"Claude API 키가 설정되지 않아 Ollama(온프레미스)로 폴백 동작합니다. 서버 환경변수 ANTHROPIC_API_KEY 설정 후 사용하세요.":"AI 기능이 비활성 상태입니다. 모든 AI 결과는 규칙 기반(degraded)으로 동작합니다."}),c.jsxs("div",{className:"grid gap-5 md:grid-cols-2",children:[c.jsxs("section",{className:"bg-card border border-edge rounded-xl p-5",children:[c.jsxs("h2",{className:"text-sm font-semibold mb-4 flex items-center gap-2 text-white",children:[c.jsx($l,{size:16,className:"text-brand"})," 제공자 & 모델"]}),c.jsx("div",{className:"grid grid-cols-2 gap-2 mb-4",children:Rce.map(C=>c.jsxs("button",{onClick:()=>{t(C.id),A()},className:`text-left px-3 py-2.5 rounded-lg border text-sm transition-colors ${e===C.id?"bg-brand/15 border-brand text-brand":"bg-ink border-edge text-slate-300 hover:border-brand/50"}`,children:[c.jsxs("div",{className:"font-semibold flex items-center gap-1",children:[C.label,C.ramWarn&&c.jsx(kl,{size:12,className:"text-amber-400"})]}),c.jsx("div",{className:"text-[11px] text-slate-500 mt-0.5",children:C.hint})]},C.id))}),D&&c.jsxs("div",{className:"mb-4 bg-amber-500/10 border border-amber-500/40 text-amber-300 text-xs rounded-lg px-3 py-2 flex items-start gap-2",children:[c.jsx(kl,{size:13,className:"mt-0.5 shrink-0"}),c.jsx("span",{children:"GLM(glm4:9b)은 약 5.5GB 로드가 필요합니다. 서버 RAM 여유가 부족하면 콜드로드에 실패하며 소형 모델/폴백으로 동작합니다. RAM 증설 후 사용을 권장합니다."})]}),!N&&c.jsxs("div",{className:"mb-4",children:[c.jsx("label",{className:"block text-xs text-slate-500 mb-1",children:"Ollama 텍스트 모델"}),c.jsx("div",{className:"px-3 py-2 rounded-lg bg-ink border border-edge text-sm font-mono text-slate-300",children:o||"llama3.2:1b"}),c.jsx("p",{className:"text-[11px] text-slate-500 mt-1",children:"온프레미스 소형 모델 — 서버 RAM 제약으로 고정. 외부 호출 없음."})]}),N&&c.jsxs(c.Fragment,{children:[c.jsxs("div",{className:"mb-4",children:[c.jsx("label",{className:"block text-xs text-slate-500 mb-1",children:"Claude 모델"}),c.jsx("select",{value:n,onChange:C=>{r(Iy(C.target.value)),A()},className:"w-full px-3 py-2 rounded-lg bg-ink border border-edge text-sm text-slate-200 focus:border-brand outline-none",children:LR.map(C=>c.jsx("option",{value:C,children:C},C))})]}),c.jsxs("div",{className:"mb-4",children:[c.jsxs("label",{className:"block text-xs text-slate-500 mb-1 flex items-center gap-1",children:[c.jsx(jN,{size:13})," API 키"]}),c.jsx("span",{className:`inline-block px-3 py-1 rounded-lg text-xs font-semibold ${a?"bg-emerald-500/15 text-emerald-300 border border-emerald-500/40":"bg-rose-500/15 text-rose-300 border border-rose-500/40"}`,children:a?"설정됨":"미설정"}),c.jsx("p",{className:"text-[11px] text-slate-500 mt-1.5",children:"키는 서버 환경변수(ANTHROPIC_API_KEY)로만 주입되며 화면·응답·로그에 노출되지 않습니다."})]})]}),c.jsxs("div",{className:"flex items-center gap-3",children:[c.jsxs("button",{onClick:E,disabled:h||d,className:"flex items-center gap-1.5 px-4 py-2 rounded-lg bg-brand text-ink text-sm font-semibold disabled:opacity-40",children:[c.jsx(k5,{size:15})," ",h?"저장 중…":"저장"]}),b&&c.jsx("span",{className:"text-emerald-300 text-xs",children:"저장됨"})]})]}),c.jsxs("section",{className:"bg-card border border-edge rounded-xl p-5",children:[c.jsxs("h2",{className:"text-sm font-semibold mb-2 flex items-center gap-2 text-white",children:[c.jsx(P5,{size:16,className:"text-brand"})," 연결 테스트"]}),c.jsx("p",{className:"text-sm text-slate-400 mb-4",children:"저장된 설정 기준으로 선택한 제공자에 짧은 ping 을 보내 연결을 확인합니다(요약 결과만)."}),c.jsxs("div",{className:"flex items-center gap-3",children:[c.jsx("button",{onClick:_,disabled:y,className:"px-4 py-2 rounded-lg bg-card border border-edge text-sm disabled:opacity-40 hover:border-brand/50",children:y?"테스트 중…":"테스트 실행"}),S&&c.jsx("span",{className:`text-sm ${k}`,role:"status","aria-live":"polite",children:S.message})]}),c.jsx("p",{className:"text-[11px] text-slate-500 mt-3",children:"먼저 변경 사항을 저장한 뒤 테스트하세요. Claude 실패 시 Ollama 로 자동 폴백합니다."})]})]})]})}const $ce={ACTIVE:"text-green-400 bg-green-500/10 border-green-500/30",UNBOUND:"text-gray-400 bg-gray-500/10 border-gray-500/30",ERROR:"text-red-400 bg-red-500/10 border-red-500/30"},kce=e=>e==="ONLINE"?c.jsx(TN,{size:13,className:"text-green-400"}):c.jsx(_N,{size:13,className:"text-red-400"});function Dce(){const e=rn(),[t,n]=O.useState(""),[r,a]=O.useState(""),[i,o]=O.useState(""),[l,s]=O.useState(!1),[u,d]=O.useState({tenantCode:"",storeId:"",deviceId:"",productCode:"",locationCode:"",templateCode:"EM-PRICE-STD"}),{data:f=[],isLoading:h}=Vt({queryKey:["tag-binding",t,r,i],queryFn:()=>H.get("/api/tag-binding",{params:{tenantCode:t||void 0,storeId:r||void 0,keyword:i||void 0,bindStatus:"ACTIVE"}}).then(v=>v.data.data),refetchInterval:2e4}),p=tt({mutationFn:v=>H.post("/api/tag-binding",{...v,storeId:Number(v.storeId)}),onSuccess:()=>{e.invalidateQueries({queryKey:["tag-binding"]}),s(!1)}}),b=tt({mutationFn:v=>H.put(`/api/tag-binding/${v}/unbind`),onSuccess:()=>e.invalidateQueries({queryKey:["tag-binding"]})});return h?c.jsx("div",{className:"text-gray-400 p-8",children:"로딩 중..."}):c.jsxs("div",{className:"space-y-4",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("h1",{className:"text-xl font-semibold text-white",children:"태그 바인딩 관리"}),c.jsxs("button",{onClick:()=>s(v=>!v),className:"flex items-center gap-2 px-3 py-1.5 bg-brand text-white rounded text-sm",children:[c.jsx(ON,{size:14})," 바인딩 추가"]})]}),l&&c.jsxs("div",{className:"bg-panel border border-edge rounded-lg p-4 space-y-3",children:[c.jsx("h2",{className:"text-sm font-medium text-white",children:"e-paper 태그 → 상품 바인딩"}),c.jsx("div",{className:"grid grid-cols-3 gap-3",children:[{key:"tenantCode",label:"테넌트",ph:"EMART"},{key:"storeId",label:"매장ID",ph:"1"},{key:"deviceId",label:"태그 Device ID",ph:"ESL-EM-001-0001"},{key:"productCode",label:"상품코드",ph:"P-001"},{key:"locationCode",label:"선반 위치코드",ph:"A01-03"},{key:"templateCode",label:"템플릿",ph:"EM-PRICE-STD"}].map(({key:v,label:x,ph:m})=>c.jsxs("div",{children:[c.jsx("label",{className:"text-xs text-gray-400 mb-1 block",children:x}),c.jsx("input",{value:u[v],onChange:y=>d(g=>({...g,[v]:y.target.value})),placeholder:m,className:"w-full bg-edge border border-gray-600 rounded px-2 py-1.5 text-sm text-white"})]},v))}),c.jsxs("div",{className:"flex gap-2",children:[c.jsx("button",{onClick:()=>p.mutate(u),className:"px-3 py-1.5 bg-brand text-white rounded text-sm",children:"바인딩 저장"}),c.jsx("button",{onClick:()=>s(!1),className:"px-3 py-1.5 bg-edge text-gray-300 rounded text-sm",children:"취소"})]})]}),c.jsx("div",{className:"flex gap-3",children:[{val:t,set:n,ph:"테넌트 필터"},{val:i,set:o,ph:"태그ID / 상품코드 / 위치 검색"}].map(({val:v,set:x,ph:m},y)=>c.jsx("input",{value:v,onChange:g=>x(g.target.value),placeholder:m,className:"bg-panel border border-edge rounded px-3 py-1.5 text-sm text-gray-300 w-64"},y))}),c.jsxs("div",{className:"grid grid-cols-1 gap-3",children:[f.map(v=>c.jsxs("div",{className:`bg-panel border rounded-lg p-4 flex items-center justify-between
              ${v.deviceStatus==="ONLINE"?"border-green-500/20":"border-red-500/20"}`,children:[c.jsxs("div",{className:"flex items-center gap-4",children:[c.jsxs("div",{className:"flex flex-col items-center gap-1 w-16",children:[kce(v.deviceStatus),v.batteryLevel!==null&&c.jsxs("div",{className:"flex items-center gap-1 text-xs text-gray-400",children:[c.jsx(bN,{size:11}),c.jsxs("span",{className:v.batteryLevel<20?"text-red-400":"",children:[v.batteryLevel,"%"]})]})]}),c.jsxs("div",{children:[c.jsx("div",{className:"text-xs font-mono text-brand",children:v.deviceId}),c.jsxs("div",{className:"flex items-center gap-2 mt-1",children:[c.jsx(N5,{size:11,className:"text-gray-500"}),c.jsx("span",{className:"text-xs text-gray-400",children:v.locationCode||"위치 미지정"}),c.jsx("span",{className:"text-xs text-gray-600",children:"|"}),c.jsx("span",{className:"text-xs text-gray-300",children:v.storeName})]})]}),c.jsxs("div",{className:"ml-4 pl-4 border-l border-edge",children:[c.jsx("div",{className:"text-sm text-white",children:v.productName||v.productCode}),c.jsxs("div",{className:"text-xs text-gray-400 mt-0.5",children:["현재가: ",c.jsx("span",{className:"text-brand font-mono",children:v.lastPrice?v.lastPrice.toLocaleString()+"원":"미전송"}),v.lastUpdatedAt&&c.jsxs("span",{className:"ml-2 text-gray-600",children:["갱신: ",new Date(v.lastUpdatedAt).toLocaleString()]})]}),c.jsxs("div",{className:"text-xs text-gray-500 mt-0.5",children:["템플릿: ",v.templateCode]})]})]}),c.jsxs("div",{className:"flex items-center gap-3",children:[c.jsx("span",{className:`text-xs px-2 py-0.5 rounded border ${$ce[v.bindStatus]||""}`,children:v.bindStatus}),c.jsx("button",{onClick:()=>{confirm(`태그 ${v.deviceId} 언바인딩하겠습니까?`)&&b.mutate(v.id)},className:"p-1.5 rounded bg-edge text-gray-400 hover:text-red-400",title:"언바인딩",children:c.jsx(j5,{size:14})})]})]},v.id)),f.length===0&&c.jsx("div",{className:"text-center text-gray-500 py-12",children:'바인딩된 태그가 없습니다. 우측 상단 "바인딩 추가"를 클릭하세요.'})]})]})}const qy={PENDING:{icon:c.jsx(h5,{size:13}),color:"text-yellow-400 bg-yellow-500/10 border-yellow-500/30",label:"대기"},SENDING:{icon:c.jsx(ag,{size:13}),color:"text-blue-400 bg-blue-500/10 border-blue-500/30",label:"전송중"},SENT:{icon:c.jsx(ag,{size:13}),color:"text-cyan-400 bg-cyan-500/10 border-cyan-500/30",label:"전송됨"},CONFIRMED:{icon:c.jsx(ix,{size:13}),color:"text-green-400 bg-green-500/10 border-green-500/30",label:"확인됨"},FAILED:{icon:c.jsx(f5,{size:13}),color:"text-red-400 bg-red-500/10 border-red-500/30",label:"실패"},CANCELLED:{icon:c.jsx(s5,{size:13}),color:"text-gray-400 bg-gray-500/10 border-gray-500/30",label:"취소됨"}};function Lce(){const e=rn(),[t,n]=O.useState(""),[r,a]=O.useState(""),{data:i=[],isLoading:o,refetch:l}=Vt({queryKey:["update-queue",t,r],queryFn:()=>H.get("/api/update-queue",{params:{tenantCode:t||void 0,status:r||void 0}}).then(h=>h.data.data),refetchInterval:5e3}),s=tt({mutationFn:h=>H.put(`/api/update-queue/${h}/cancel`),onSuccess:()=>e.invalidateQueries({queryKey:["update-queue"]})}),u=i.filter(h=>h.status==="PENDING").length,d=i.filter(h=>h.status==="FAILED").length,f=i.filter(h=>h.status==="CONFIRMED").length;return o?c.jsx("div",{className:"text-gray-400 p-8",children:"로딩 중..."}):c.jsxs("div",{className:"space-y-4",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("h1",{className:"text-xl font-semibold text-white",children:"e-paper 가격 업데이트 큐"}),c.jsxs("button",{onClick:()=>l(),className:"flex items-center gap-1.5 px-3 py-1.5 bg-edge text-gray-300 rounded text-sm",children:[c.jsx(Yc,{size:13})," 새로고침"]})]}),c.jsx("div",{className:"grid grid-cols-3 gap-3",children:[{label:"대기중",count:u,color:"text-yellow-400",bg:"bg-yellow-500/5 border-yellow-500/20"},{label:"실패",count:d,color:"text-red-400",bg:"bg-red-500/5 border-red-500/20"},{label:"완료",count:f,color:"text-green-400",bg:"bg-green-500/5 border-green-500/20"}].map(({label:h,count:p,color:b,bg:v})=>c.jsxs("div",{className:`border rounded-lg p-3 ${v}`,children:[c.jsx("div",{className:`text-2xl font-bold font-mono ${b}`,children:p}),c.jsx("div",{className:"text-xs text-gray-400 mt-0.5",children:h})]},h))}),c.jsxs("div",{className:"flex gap-3",children:[c.jsx("input",{value:t,onChange:h=>n(h.target.value),placeholder:"테넌트 필터",className:"bg-panel border border-edge rounded px-3 py-1.5 text-sm text-gray-300 w-40"}),c.jsxs("select",{value:r,onChange:h=>a(h.target.value),className:"bg-panel border border-edge rounded px-3 py-1.5 text-sm text-gray-300",children:[c.jsx("option",{value:"",children:"전체 상태"}),Object.entries(qy).map(([h,p])=>c.jsx("option",{value:h,children:p.label},h))]})]}),c.jsxs("div",{className:"overflow-x-auto",children:[c.jsxs("table",{className:"w-full text-sm",children:[c.jsx("thead",{children:c.jsxs("tr",{className:"border-b border-edge text-xs text-gray-500",children:[c.jsx("th",{className:"text-left py-2 px-3",children:"#"}),c.jsx("th",{className:"text-left py-2 px-3",children:"태그 ID"}),c.jsx("th",{className:"text-left py-2 px-3",children:"위치"}),c.jsx("th",{className:"text-left py-2 px-3",children:"상품"}),c.jsx("th",{className:"text-right py-2 px-3",children:"가격"}),c.jsx("th",{className:"text-center py-2 px-3",children:"우선순위"}),c.jsx("th",{className:"text-center py-2 px-3",children:"상태"}),c.jsx("th",{className:"text-center py-2 px-3",children:"재시도"}),c.jsx("th",{className:"text-left py-2 px-3",children:"등록 시각"}),c.jsx("th",{className:"text-center py-2 px-3",children:"액션"})]})}),c.jsx("tbody",{children:i.map(h=>{var b;const p=qy[h.status]||qy.PENDING;return c.jsxs("tr",{className:"border-b border-edge/50 hover:bg-edge/30",children:[c.jsx("td",{className:"py-2 px-3 text-gray-500 font-mono text-xs",children:h.id}),c.jsx("td",{className:"py-2 px-3 text-brand font-mono text-xs",children:h.deviceId}),c.jsx("td",{className:"py-2 px-3 text-gray-300 text-xs",children:h.locationCode||"-"}),c.jsx("td",{className:"py-2 px-3 text-white text-xs",children:h.productName||h.productCode}),c.jsxs("td",{className:"py-2 px-3 text-right font-mono text-xs",children:[(b=h.newPrice)==null?void 0:b.toLocaleString(),"원",h.newSalePrice&&h.newSalePrice!==h.newPrice&&c.jsxs("span",{className:"ml-1 text-red-400",children:["→ ",h.newSalePrice.toLocaleString(),"원"]})]}),c.jsx("td",{className:"py-2 px-3 text-center",children:c.jsxs("span",{className:`text-xs font-mono ${h.priority<=2?"text-red-400":"text-gray-400"}`,children:["P",h.priority]})}),c.jsx("td",{className:"py-2 px-3 text-center",children:c.jsxs("span",{className:`inline-flex items-center gap-1 text-xs px-2 py-0.5 rounded border ${p.color}`,children:[p.icon," ",p.label]})}),c.jsxs("td",{className:"py-2 px-3 text-center text-xs text-gray-400",children:[h.retryCount,"/",h.maxRetry]}),c.jsx("td",{className:"py-2 px-3 text-xs text-gray-500",children:new Date(h.createdAt).toLocaleString()}),c.jsx("td",{className:"py-2 px-3 text-center",children:["PENDING","FAILED"].includes(h.status)&&c.jsx("button",{onClick:()=>s.mutate(h.id),className:"text-xs text-gray-500 hover:text-red-400 px-2 py-0.5 rounded bg-edge",children:"취소"})})]},h.id)})})]}),i.length===0&&c.jsx("div",{className:"text-center text-gray-500 py-12",children:"업데이트 큐가 비어있습니다."})]})]})}const zce={FIRMWARE_DEPLOY:"bg-purple-500/20 text-purple-300",FIRMWARE_UPDATE:"bg-purple-500/20 text-purple-300",FIRMWARE_DELETE:"bg-red-500/20 text-red-400",POS_PRICE_CHANGE:"bg-amber-500/20 text-amber-300",USER_CREATE:"bg-green-500/20 text-green-400",USER_UPDATE:"bg-blue-500/20 text-blue-400",USER_DELETE:"bg-red-500/20 text-red-400",USER_PASSWORD_RESET:"bg-blue-500/20 text-blue-400",USER_ACTIVE_TOGGLE:"bg-blue-500/20 text-blue-400",TENANT_CREATE:"bg-green-500/20 text-green-400",TENANT_UPDATE:"bg-blue-500/20 text-blue-400",TENANT_DELETE:"bg-red-500/20 text-red-400",SETTING_CHANGE:"bg-cyan-500/20 text-cyan-300"},Bce=["","FIRMWARE_DEPLOY","FIRMWARE_UPDATE","FIRMWARE_DELETE","POS_PRICE_CHANGE","USER_CREATE","USER_UPDATE","USER_DELETE","USER_PASSWORD_RESET","USER_ACTIVE_TOGGLE","TENANT_CREATE","TENANT_UPDATE","TENANT_DELETE","SETTING_CHANGE"];function Ice(){const[e,t]=O.useState(""),[n,r]=O.useState(""),[a,i]=O.useState(""),[o,l]=O.useState(""),[s,u]=O.useState(""),[d,f]=O.useState({limit:200}),{data:h=[],isLoading:p,refetch:b,isFetching:v}=Vt({queryKey:["audit",d],queryFn:()=>Dz(d)}),x=()=>{const y={limit:200};e&&(y.action=e),n.trim()&&(y.username=n.trim()),a.trim()&&(y.tenantCode=a.trim()),o&&(y.from=o+":00"),s&&(y.to=s+":59"),f(y)},m=()=>{t(""),r(""),i(""),l(""),u(""),f({limit:200})};return c.jsxs("div",{className:"space-y-4",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("h1",{className:"text-xl font-semibold text-white",children:"감사 로그"}),c.jsx("button",{onClick:()=>b(),className:"text-xs px-3 py-1.5 rounded bg-edge/60 text-gray-300 hover:bg-edge",children:v?"조회 중...":"새로고침"})]}),c.jsxs("div",{className:"bg-card border border-edge rounded-lg p-4 grid grid-cols-1 md:grid-cols-6 gap-3 items-end",children:[c.jsxs("div",{className:"flex flex-col gap-1",children:[c.jsx("label",{className:"text-xs text-gray-500",children:"액션"}),c.jsx("select",{value:e,onChange:y=>t(y.target.value),className:"bg-panel border border-edge rounded px-2 py-1.5 text-sm text-gray-200",children:Bce.map(y=>c.jsx("option",{value:y,children:y||"전체"},y))})]}),c.jsxs("div",{className:"flex flex-col gap-1",children:[c.jsx("label",{className:"text-xs text-gray-500",children:"수행자"}),c.jsx("input",{value:n,onChange:y=>r(y.target.value),placeholder:"username",className:"bg-panel border border-edge rounded px-2 py-1.5 text-sm text-gray-200"})]}),c.jsxs("div",{className:"flex flex-col gap-1",children:[c.jsx("label",{className:"text-xs text-gray-500",children:"테넌트"}),c.jsx("input",{value:a,onChange:y=>i(y.target.value),placeholder:"EMART",className:"bg-panel border border-edge rounded px-2 py-1.5 text-sm text-gray-200"})]}),c.jsxs("div",{className:"flex flex-col gap-1",children:[c.jsx("label",{className:"text-xs text-gray-500",children:"시작 일시"}),c.jsx("input",{type:"datetime-local",value:o,onChange:y=>l(y.target.value),className:"bg-panel border border-edge rounded px-2 py-1.5 text-sm text-gray-200"})]}),c.jsxs("div",{className:"flex flex-col gap-1",children:[c.jsx("label",{className:"text-xs text-gray-500",children:"종료 일시"}),c.jsx("input",{type:"datetime-local",value:s,onChange:y=>u(y.target.value),className:"bg-panel border border-edge rounded px-2 py-1.5 text-sm text-gray-200"})]}),c.jsxs("div",{className:"flex gap-2",children:[c.jsx("button",{onClick:x,className:"flex-1 px-3 py-1.5 rounded bg-brand/80 text-white text-sm hover:bg-brand",children:"조회"}),c.jsx("button",{onClick:m,className:"px-3 py-1.5 rounded bg-edge/60 text-gray-300 text-sm hover:bg-edge",children:"초기화"})]})]}),p?c.jsx("div",{className:"text-gray-400 p-8",children:"로딩 중..."}):c.jsx("div",{className:"bg-card border border-edge rounded-lg overflow-hidden",children:c.jsxs("table",{className:"w-full text-sm",children:[c.jsx("thead",{className:"bg-panel border-b border-edge",children:c.jsx("tr",{children:["일시","수행자","테넌트","액션","리소스","대상","상세","IP","결과"].map(y=>c.jsx("th",{className:"px-4 py-3 text-left text-xs text-gray-400 font-medium",children:y},y))})}),c.jsxs("tbody",{children:[h.map(y=>c.jsxs("tr",{className:"border-b border-edge hover:bg-edge/30",children:[c.jsx("td",{className:"px-4 py-3 text-gray-500 text-xs whitespace-nowrap",children:y.createdAt?new Date(y.createdAt).toLocaleString("ko-KR"):"-"}),c.jsx("td",{className:"px-4 py-3 text-gray-300",children:y.username||"-"}),c.jsx("td",{className:"px-4 py-3 text-brand text-xs",children:y.tenantCode||"-"}),c.jsx("td",{className:"px-4 py-3",children:c.jsx("span",{className:`px-2 py-0.5 rounded text-xs ${zce[y.action]||"bg-gray-500/20 text-gray-400"}`,children:y.action})}),c.jsx("td",{className:"px-4 py-3 text-gray-400 text-xs",children:y.resource||"-"}),c.jsx("td",{className:"px-4 py-3 text-gray-400 text-xs",children:y.resourceId||"-"}),c.jsx("td",{className:"px-4 py-3 text-gray-400 text-xs max-w-xs truncate",title:y.detail,children:y.detail||"-"}),c.jsx("td",{className:"px-4 py-3 text-gray-500 text-xs",children:y.ipAddress||"-"}),c.jsx("td",{className:"px-4 py-3",children:c.jsx("span",{className:`px-2 py-0.5 rounded text-xs ${y.success===!1?"bg-red-500/20 text-red-400":"bg-green-500/20 text-green-400"}`,children:y.success===!1?"실패":"성공"})})]},y.id)),h.length===0&&c.jsx("tr",{children:c.jsx("td",{colSpan:9,className:"px-4 py-8 text-center text-gray-500",children:"감사 로그가 없습니다"})})]})]})})]})}const Uce={GENERAL:"bg-gray-500/20 text-gray-300",ESL:"bg-purple-500/20 text-purple-300",ALARM:"bg-amber-500/20 text-amber-300",AI:"bg-cyan-500/20 text-cyan-300"};function qce(){const e=rn(),[t,n]=O.useState({}),{data:r=[],isLoading:a}=Vt({queryKey:["settings"],queryFn:()=>Lz()}),i=tt({mutationFn:({key:o,value:l})=>zz(o,l),onSuccess:(o,l)=>{e.invalidateQueries({queryKey:["settings"]}),n(s=>{const u={...s};return delete u[l.key],u})}});return a?c.jsx("div",{className:"text-gray-400 p-8",children:"로딩 중..."}):c.jsxs("div",{className:"space-y-4",children:[c.jsx("h1",{className:"text-xl font-semibold text-white",children:"시스템 설정"}),c.jsx("p",{className:"text-xs text-gray-500",children:"운영 설정 변경은 감사 로그에 기록됩니다. (변경은 ADMIN 권한 필요)"}),c.jsx("div",{className:"bg-card border border-edge rounded-lg overflow-hidden",children:c.jsxs("table",{className:"w-full text-sm",children:[c.jsx("thead",{className:"bg-panel border-b border-edge",children:c.jsx("tr",{children:["분류","설정 키","값","설명","수정 일시",""].map(o=>c.jsx("th",{className:"px-4 py-3 text-left text-xs text-gray-400 font-medium",children:o},o))})}),c.jsxs("tbody",{children:[r.map(o=>{const l=o.settingKey in t;return c.jsxs("tr",{className:"border-b border-edge hover:bg-edge/30",children:[c.jsx("td",{className:"px-4 py-3",children:c.jsx("span",{className:`px-2 py-0.5 rounded text-xs ${Uce[o.category]||"bg-gray-500/20 text-gray-400"}`,children:o.category})}),c.jsx("td",{className:"px-4 py-3 text-gray-200 font-mono text-xs",children:o.settingKey}),c.jsx("td",{className:"px-4 py-3",children:l?c.jsx("input",{value:t[o.settingKey],onChange:s=>n(u=>({...u,[o.settingKey]:s.target.value})),className:"bg-panel border border-brand/60 rounded px-2 py-1 text-sm text-gray-100 w-48"}):c.jsx("span",{className:"text-gray-300",children:o.settingValue})}),c.jsx("td",{className:"px-4 py-3 text-gray-500 text-xs max-w-xs",children:o.description||"-"}),c.jsx("td",{className:"px-4 py-3 text-gray-500 text-xs",children:o.updatedAt?new Date(o.updatedAt).toLocaleString("ko-KR"):"-"}),c.jsx("td",{className:"px-4 py-3 text-right",children:l?c.jsxs("div",{className:"flex gap-2 justify-end",children:[c.jsx("button",{onClick:()=>i.mutate({key:o.settingKey,value:t[o.settingKey]}),disabled:i.isPending,className:"text-xs px-3 py-1 rounded bg-brand/80 text-white hover:bg-brand",children:"저장"}),c.jsx("button",{onClick:()=>n(s=>{const u={...s};return delete u[o.settingKey],u}),className:"text-xs px-3 py-1 rounded bg-edge/60 text-gray-300 hover:bg-edge",children:"취소"})]}):c.jsx("button",{onClick:()=>n(s=>({...s,[o.settingKey]:o.settingValue??""})),className:"text-xs px-3 py-1 rounded bg-edge/60 text-gray-300 hover:bg-edge",children:"수정"})})]},o.settingKey)}),r.length===0&&c.jsx("tr",{children:c.jsx("td",{colSpan:6,className:"px-4 py-8 text-center text-gray-500",children:"설정이 없습니다"})})]})]})})]})}const Hce="https://itsm.zioinfo.co.kr";function Fce(){const[e,t]=O.useState(null),[n,r]=O.useState(!0),[a,i]=O.useState(""),[o,l]=O.useState(!1),s=()=>{r(!0),i(""),fetch(`${Hce}/api/app/public-latest`).then(d=>d.json()).then(d=>t(d)).catch(()=>i("버전 정보를 불러올 수 없습니다. (중앙 앱 저장소 연결 실패)")).finally(()=>r(!1))};O.useEffect(()=>{s()},[]);const u=async()=>{if(e!=null&&e.landing_url)try{await navigator.clipboard.writeText(e.landing_url),l(!0),setTimeout(()=>l(!1),2e3)}catch{}};return c.jsxs("div",{children:[c.jsxs("div",{className:"flex items-center justify-between mb-6",children:[c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsx(ig,{className:"text-brand",size:22}),c.jsx("h1",{className:"text-xl font-bold",children:"GUARDiA 통합 메신저 앱 설치"})]}),c.jsxs("button",{onClick:s,className:"flex items-center gap-1.5 px-3 py-2 rounded-lg bg-card border border-edge text-sm text-slate-300 hover:text-brand",children:[c.jsx(Yc,{size:15})," 새로고침"]})]}),c.jsxs("p",{className:"text-sm text-slate-400 mb-6",children:["QR 코드를 스캔하면 ",c.jsx("span",{className:"text-brand font-semibold",children:"GUARDiA Messenger"})," 앱 설치 페이지로 이동합니다. 앱스토어 설치가 필요 없으며, 앱 업로드·버전 관리는 GUARDiA Manager에서 일원화되어 있습니다."]}),n&&c.jsx("div",{className:"text-slate-400 text-sm",children:"불러오는 중…"}),a&&c.jsx("div",{className:"bg-card border border-edge rounded-xl p-6 text-rose-400 text-sm",children:a}),!n&&!a&&e&&!e.has_version&&c.jsxs("div",{className:"bg-card border border-edge rounded-xl p-8 text-center text-slate-400",children:[c.jsx(ig,{size:36,className:"mx-auto mb-3 text-slate-600"}),"아직 등록된 앱 버전이 없습니다.",c.jsx("br",{}),c.jsx("span",{className:"text-xs",children:"GUARDiA Manager에서 APK를 업로드하면 여기에 QR이 표시됩니다."})]}),!n&&!a&&(e==null?void 0:e.has_version)&&c.jsxs("div",{className:"bg-card border border-edge rounded-xl p-6 grid md:grid-cols-[200px_1fr] gap-6 items-start",children:[c.jsx("div",{className:"bg-white rounded-xl p-3 flex items-center justify-center",children:c.jsx("img",{src:e.qr_url,alt:"앱 설치 QR",className:"w-44 h-44"})}),c.jsxs("div",{children:[c.jsxs("div",{className:"flex items-center gap-2 mb-1",children:[c.jsx("span",{className:"text-lg font-bold",children:e.app_name||"GUARDiA Messenger"}),c.jsxs("span",{className:"px-2 py-0.5 rounded-md bg-brand2 text-white text-xs font-semibold",children:["v",e.version]})]}),c.jsxs("div",{className:"text-xs text-slate-400 mb-4",children:[e.platform," · ",e.file_size_mb?`${e.file_size_mb}MB`:"",e.download_count!=null&&` · 다운로드 ${e.download_count}회`]}),e.release_notes&&c.jsxs("div",{className:"mb-4",children:[c.jsx("div",{className:"text-[11px] font-semibold text-slate-500 uppercase tracking-wider mb-1",children:"변경점"}),c.jsx("div",{className:"text-sm text-slate-300 whitespace-pre-line bg-ink border border-edge rounded-lg p-3 max-h-32 overflow-auto",children:e.release_notes})]}),c.jsxs("div",{className:"flex flex-wrap gap-2",children:[c.jsxs("a",{href:e.landing_url,target:"_blank",rel:"noreferrer",className:"flex items-center gap-1.5 px-3 py-2 rounded-lg bg-brand text-ink text-sm font-semibold",children:[c.jsx(y5,{size:15})," 설치 페이지 열기"]}),c.jsxs("a",{href:e.download_url,target:"_blank",rel:"noreferrer",className:"flex items-center gap-1.5 px-3 py-2 rounded-lg bg-card border border-edge text-sm text-slate-300 hover:text-brand",children:[c.jsx(m5,{size:15})," APK 직접 다운로드"]}),c.jsxs("button",{onClick:u,className:"flex items-center gap-1.5 px-3 py-2 rounded-lg bg-card border border-edge text-sm text-slate-300 hover:text-brand",children:[o?c.jsx(l5,{size:15,className:"text-accent"}):c.jsx(p5,{size:15}),o?"복사됨":"다운로드 링크 복사"]})]}),c.jsx("div",{className:"mt-4 text-[12px] text-slate-500 leading-relaxed",children:'📱 Android: APK 다운로드 후 설정 → 보안 → "알 수 없는 소스" 허용 → 설치. 앱스토어 등록이 필요 없습니다.'})]})]})]})}const Hy=8;function Hf(e,t){var n,r,a;return((n=e==null?void 0:e.response)==null?void 0:n.status)===403?"권한이 없습니다.":((a=(r=e==null?void 0:e.response)==null?void 0:r.data)==null?void 0:a.message)||t}function Gce(){const[e,t]=O.useState(""),[n,r]=O.useState(null),[a,i]=O.useState("idle"),[o,l]=O.useState(""),[s,u]=O.useState(""),[d,f]=O.useState(""),[h,p]=O.useState(!1),[b,v]=O.useState(null),[x,m]=O.useState(""),[y,g]=O.useState(""),[S,w]=O.useState(""),[j,A]=O.useState(!1),[E,_]=O.useState(!1),[N,D]=O.useState(null),R=()=>eC().then(G=>{var J;const Y=((J=G.data)==null?void 0:J.data)||{};t(Y.username||localStorage.getItem("esn_user")||""),typeof Y.otpEnabled=="boolean"?r(Y.otpEnabled):typeof Y.verifyMethod=="string"&&r(Y.verifyMethod==="OTP")}).catch(()=>{});O.useEffect(()=>{R()},[]);const B=async()=>{var G;v(null),p(!0);try{const J=((G=(await XL()).data)==null?void 0:G.data)||{};l(J.qrImage||""),u(J.secret||""),f(""),i("setup")}catch(Y){v({ok:!1,text:Hf(Y,"OTP 등록을 시작하지 못했습니다.")})}finally{p(!1)}},k=async()=>{v(null),p(!0);try{await QL(d),u(""),l(""),f(""),i("done"),r(!0),v({ok:!0,text:"2차 인증이 활성화되었습니다."})}catch(G){v({ok:!1,text:Hf(G,"코드가 일치하지 않거나 만료되었습니다.")})}finally{p(!1)}},C=()=>{i("idle"),u(""),l(""),f(""),v(null)},M=async()=>{if(window.confirm("Authenticator 2차 인증을 해제하시겠습니까?")){v(null),p(!0);try{await WL(),i("idle"),u(""),l(""),r(!1),v({ok:!0,text:"2차 인증이 해제되었습니다."})}catch(G){v({ok:!1,text:Hf(G,"OTP 해제에 실패했습니다.")})}finally{p(!1)}}},L=async()=>{if(D(null),!x){D({ok:!1,text:"현재 비밀번호를 입력하세요."});return}if(y.length<Hy){D({ok:!1,text:`새 비밀번호는 최소 ${Hy}자 이상이어야 합니다.`});return}if(y!==S){D({ok:!1,text:"새 비밀번호가 일치하지 않습니다."});return}if(y===x){D({ok:!1,text:"새 비밀번호는 현재 비밀번호와 달라야 합니다."});return}_(!0);try{await ZL(x,y),m(""),g(""),w(""),D({ok:!0,text:"비밀번호가 변경되었습니다."})}catch(G){D({ok:!1,text:Hf(G,"비밀번호 변경에 실패했습니다.")})}finally{_(!1)}},z="w-full px-3 py-2 rounded bg-panel border border-edge text-sm text-white focus:border-brand outline-none",F=z+" tracking-[0.4em] text-center text-lg",K=({m:G})=>G?c.jsxs("div",{className:`flex items-center gap-2 text-sm rounded px-3 py-2 mb-3 border ${G.ok?"bg-accent/10 border-accent/40 text-accent":"bg-red-500/10 border-red-500/40 text-red-300"}`,children:[G.ok?c.jsx(u5,{size:16}):c.jsx(kl,{size:16}),G.text]}):null;return c.jsxs("div",{className:"max-w-2xl",children:[c.jsx("h1",{className:"text-xl font-bold text-white mb-1",children:"마이페이지"}),c.jsx("p",{className:"text-sm text-gray-400 mb-6",children:e&&c.jsxs(c.Fragment,{children:["계정: ",c.jsx("span",{className:"text-gray-200",children:e})]})}),c.jsxs("section",{className:"bg-card border border-edge rounded-lg p-5 mb-6",children:[c.jsxs("div",{className:"flex items-center gap-2 mb-1",children:[c.jsx(AN,{size:18,className:"text-brand"}),c.jsx("h2",{className:"font-semibold text-white",children:"2차 인증 — Authenticator(OTP)"})]}),c.jsxs("p",{className:"text-xs text-gray-400 mb-4",children:["Google·Microsoft Authenticator 앱으로 6자리 코드를 사용하는 2차 인증을 설정합니다.",n!==null&&c.jsxs("span",{className:"ml-2",children:["현재 상태:"," ",c.jsx("span",{className:n?"text-accent":"text-gray-300",children:n?"OTP 사용 중":"미설정"})]})]}),c.jsx(K,{m:b}),a==="idle"&&c.jsxs("div",{className:"flex flex-wrap gap-2",children:[c.jsxs("button",{onClick:B,disabled:h,className:"flex items-center gap-1.5 px-3 py-2 rounded bg-brand hover:bg-brand2 text-white text-sm font-semibold transition-colors disabled:opacity-60",children:[c.jsx($5,{size:16})," ",h?"발급 중…":n?"OTP 재설정 시작":"OTP 등록 시작"]}),n&&c.jsx("button",{onClick:M,disabled:h,className:"px-3 py-2 rounded border border-red-500/50 text-red-300 text-sm hover:bg-red-500/10 disabled:opacity-60",children:"Authenticator 해제"})]}),a==="setup"&&c.jsxs("div",{children:[c.jsxs("ol",{className:"list-decimal list-inside text-sm text-gray-300 leading-7 mb-3",children:[c.jsx("li",{children:"Authenticator 앱에서 아래 QR을 스캔하세요."}),c.jsx("li",{children:"스캔이 안 되면 수동 키를 직접 입력하세요."}),c.jsx("li",{children:"앱에 표시된 6자리 코드를 입력해 확인하세요."})]}),o&&c.jsx("div",{className:"flex justify-center mb-3",children:c.jsx("img",{src:o,alt:"OTP QR",width:200,height:200,style:{background:"#fff",padding:8,borderRadius:8}})}),s&&c.jsxs("div",{className:"mb-4",children:[c.jsx("div",{className:"text-[11px] text-gray-500 mb-1",children:"수동 입력 키"}),c.jsx("code",{className:"block text-xs text-accent bg-panel border border-edge rounded px-2 py-1.5 break-all select-all",children:s})]}),c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"앱에 표시된 6자리 코드"}),c.jsx("input",{value:d,onChange:G=>f(G.target.value.replace(/\D/g,"").slice(0,6)),inputMode:"numeric",autoComplete:"one-time-code",maxLength:6,placeholder:"000000",className:F+" mb-3"}),c.jsxs("div",{className:"flex gap-2",children:[c.jsx("button",{onClick:k,disabled:h||d.length!==6,className:"px-4 py-2 rounded bg-brand hover:bg-brand2 text-white text-sm font-semibold transition-colors disabled:opacity-60",children:h?"확인 중…":"코드 확인 · 활성화"}),c.jsx("button",{onClick:C,disabled:h,className:"px-4 py-2 rounded border border-edge text-sm text-gray-300 hover:text-white",children:"취소"})]})]}),a==="done"&&c.jsx("div",{className:"flex flex-wrap gap-2",children:c.jsx("button",{onClick:M,disabled:h,className:"px-3 py-2 rounded border border-red-500/50 text-red-300 text-sm hover:bg-red-500/10 disabled:opacity-60",children:"Authenticator 해제"})})]}),c.jsxs("section",{className:"bg-card border border-edge rounded-lg p-5",children:[c.jsxs("div",{className:"flex items-center gap-2 mb-4",children:[c.jsx(E5,{size:18,className:"text-brand"}),c.jsx("h2",{className:"font-semibold text-white",children:"비밀번호 변경"})]}),c.jsx(K,{m:N}),c.jsxs("div",{className:"space-y-3",children:[c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"현재 비밀번호"}),c.jsx("input",{type:j?"text":"password",value:x,autoComplete:"current-password",onChange:G=>m(G.target.value),className:z})]}),c.jsxs("div",{children:[c.jsxs("label",{className:"block text-xs text-gray-400 mb-1",children:["새 비밀번호 (최소 ",Hy,"자)"]}),c.jsx("input",{type:j?"text":"password",value:y,autoComplete:"new-password",onChange:G=>g(G.target.value),className:z})]}),c.jsxs("div",{children:[c.jsx("label",{className:"block text-xs text-gray-400 mb-1",children:"새 비밀번호 확인"}),c.jsx("input",{type:j?"text":"password",value:S,autoComplete:"new-password",onChange:G=>w(G.target.value),className:z})]}),c.jsxs("label",{className:"flex items-center gap-1.5 text-xs text-gray-400 cursor-pointer select-none",children:[c.jsx("button",{type:"button",onClick:()=>A(!j),className:"text-gray-400 hover:text-brand",children:j?c.jsx(v5,{size:15}):c.jsx(g5,{size:15})}),"비밀번호 표시"]}),c.jsx("button",{onClick:L,disabled:E,className:"px-4 py-2 rounded bg-brand hover:bg-brand2 text-white text-sm font-semibold transition-colors disabled:opacity-60",children:E?"변경 중…":"비밀번호 변경"})]})]})]})}const y1={background:"var(--uiws-surface)",border:"1px solid var(--uiws-border)",borderRadius:12,boxShadow:"var(--uiws-shadow)"};function Rr({title:e,subtitle:t,actions:n}){return c.jsxs("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"flex-end",marginBottom:20},children:[c.jsxs("div",{children:[c.jsx("h1",{style:{fontSize:22,fontWeight:700,color:"var(--uiws-text)"},children:e}),t&&c.jsx("div",{style:{fontSize:13,color:"var(--uiws-text-muted)",marginTop:4},children:t})]}),c.jsx("div",{style:{display:"flex",gap:8},children:n})]})}function _c({children:e,style:t}){return c.jsx("div",{style:{...y1,padding:18,...t},children:e})}function ne({children:e,onClick:t,variant:n="primary",type:r="button",disabled:a}){const i={primary:{background:"var(--uiws-primary)",color:"var(--uiws-primary-contrast)",border:"none"},ghost:{background:"transparent",color:"var(--uiws-text-muted)",border:"1px solid var(--uiws-border)"},danger:{background:"var(--uiws-danger)",color:"#fff",border:"none"}};return c.jsx("button",{type:r,onClick:t,disabled:a,style:{padding:"9px 16px",borderRadius:8,fontSize:13,fontWeight:600,cursor:a?"not-allowed":"pointer",opacity:a?.5:1,...i[n]},children:e})}function pe({value:e,onChange:t,placeholder:n,type:r="text",style:a}){return c.jsx("input",{type:r,value:e,placeholder:n,onChange:i=>t(i.target.value),style:{padding:"9px 12px",borderRadius:8,fontSize:13,background:"var(--uiws-input-bg)",border:"1px solid var(--uiws-border)",color:"var(--uiws-text)",...a}})}function ye({label:e,children:t}){return c.jsxs("label",{style:{display:"block",marginBottom:12},children:[c.jsx("div",{style:{fontSize:12,color:"var(--uiws-text-muted)",marginBottom:6},children:e}),t]})}function mi({children:e}){return c.jsx(_c,{style:{display:"flex",gap:10,alignItems:"center",flexWrap:"wrap",marginBottom:16},children:e})}function jo({columns:e,rows:t,rowKey:n,onRowClick:r,empty:a="데이터가 없습니다."}){return c.jsx("div",{style:{...y1,overflow:"hidden"},children:c.jsxs("table",{style:{width:"100%",borderCollapse:"collapse",fontSize:13,color:"var(--uiws-text)"},children:[c.jsx("thead",{children:c.jsx("tr",{style:{background:"var(--uiws-surface-2)"},children:e.map(i=>c.jsx("th",{style:{textAlign:i.align??"left",padding:"11px 14px",color:"var(--uiws-text-muted)",fontWeight:600,fontSize:12,borderBottom:"1px solid var(--uiws-border)",width:i.width},children:i.header},i.key))})}),c.jsx("tbody",{children:t.length===0?c.jsx("tr",{children:c.jsx("td",{colSpan:e.length,style:{padding:28,textAlign:"center",color:"var(--uiws-text-faint)"},children:a})}):t.map(i=>c.jsx("tr",{onClick:()=>r==null?void 0:r(i),style:{cursor:r?"pointer":"default",borderBottom:"1px solid var(--uiws-border)"},onMouseEnter:o=>o.currentTarget.style.background="var(--uiws-row-hover)",onMouseLeave:o=>o.currentTarget.style.background="transparent",children:e.map(o=>c.jsx("td",{style:{padding:"11px 14px",textAlign:o.align??"left"},children:o.render?o.render(i):String(i[o.key]??"")},o.key))},n(i)))})]})})}function lf({page:e,totalPages:t,onChange:n}){return t<=1?null:c.jsxs("div",{style:{display:"flex",gap:6,justifyContent:"center",marginTop:16},children:[c.jsx(ne,{variant:"ghost",disabled:e<=0,onClick:()=>n(e-1),children:"이전"}),c.jsxs("span",{style:{alignSelf:"center",fontSize:13,color:"var(--uiws-text-muted)"},children:[e+1," / ",t]}),c.jsx(ne,{variant:"ghost",disabled:e>=t-1,onClick:()=>n(e+1),children:"다음"})]})}function Oo({yn:e,yes:t="읽음",no:n="안읽음"}){const r=e==="Y";return c.jsx("span",{style:{fontSize:11,fontWeight:600,padding:"2px 9px",borderRadius:999,color:r?"var(--uiws-success)":"var(--uiws-text-muted)",background:r?"rgba(46,204,113,0.12)":"var(--uiws-surface-2)",border:"1px solid var(--uiws-border)"},children:r?t:n})}function rr({title:e,onClose:t,children:n,footer:r}){return c.jsx("div",{onClick:t,style:{position:"fixed",inset:0,background:"rgba(0,0,0,0.5)",display:"flex",justifyContent:"center",alignItems:"center",zIndex:1e3},children:c.jsxs("div",{onClick:a=>a.stopPropagation(),style:{...y1,width:"min(560px, 92vw)",maxHeight:"88vh",overflow:"auto",padding:22},children:[c.jsxs("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center",marginBottom:16},children:[c.jsx("h2",{style:{fontSize:17,fontWeight:700,color:"var(--uiws-text)"},children:e}),c.jsx("button",{onClick:t,style:{background:"none",border:"none",color:"var(--uiws-text-muted)",fontSize:20,cursor:"pointer"},children:"×"})]}),c.jsx("div",{children:n}),r&&c.jsx("div",{style:{display:"flex",gap:8,justifyContent:"flex-end",marginTop:18},children:r})]})})}function er({label:e="불러오는 중..."}){return c.jsx("div",{style:{padding:28,textAlign:"center",color:"var(--uiws-text-faint)",fontSize:13},children:e})}const _A={ONGOING:"진행중",DONE:"종료"};function Kce(){const[e,t]=O.useState([]),[n,r]=O.useState(0),[a,i]=O.useState(0),[o,l]=O.useState([]),[s,u]=O.useState(""),[d,f]=O.useState(""),[h,p]=O.useState(!1),[b,v]=O.useState(!1),[x,m]=O.useState(null),y=async()=>{p(!0);try{const j=(await t8({page:n,size:20,progressCd:s||void 0})).data.data;t(j.content??[]),i(j.totalPages??0);const A=await n8({});l(A.data.data??[])}finally{p(!1)}};O.useEffect(()=>{y()},[n,s]);const g=[{key:"workDate",header:"근무일자",width:120},{key:"title",header:"제목"},{key:"writerNm",header:"작성자",width:120},{key:"progressCd",header:"진행",width:90,render:w=>_A[w.progressCd]??w.progressCd},{key:"commentCount",header:"댓글",width:70,align:"center"}],S=async w=>{const j=await a8(w.worklogId);m(j.data.data)};return c.jsxs("div",{className:"uiws-scope",children:[c.jsx(Rr,{title:"업무일지",subtitle:"UIWS 이식 · 업무일지 작성/조회/진행관리",actions:c.jsx(ne,{onClick:()=>v(!0),children:"+ 업무일지 작성"})}),c.jsx("div",{style:{display:"flex",gap:10,marginBottom:16,flexWrap:"wrap"},children:o.map(w=>c.jsxs("div",{onClick:()=>{u(s===w.progressCd?"":w.progressCd),r(0)},style:{cursor:"pointer",padding:"12px 18px",borderRadius:10,minWidth:130,background:"var(--uiws-surface)",border:`1px solid ${s===w.progressCd?"var(--uiws-primary)":"var(--uiws-border)"}`},children:[c.jsx("div",{style:{fontSize:12,color:"var(--uiws-text-muted)"},children:w.progressNm}),c.jsx("div",{style:{fontSize:24,fontWeight:700,color:"var(--uiws-primary)"},children:w.count})]},w.progressCd))}),c.jsxs(mi,{children:[c.jsx(pe,{value:d,onChange:f,placeholder:"제목 검색",style:{minWidth:220}}),c.jsx(ne,{variant:"ghost",onClick:()=>{r(0),y()},children:"검색"}),s&&c.jsxs(ne,{variant:"ghost",onClick:()=>u(""),children:["필터 해제: ",_A[s]??s]})]}),h?c.jsx(er,{}):c.jsxs(c.Fragment,{children:[c.jsx(jo,{columns:g,rows:e,rowKey:w=>w.worklogId,onRowClick:S,empty:"업무일지가 없습니다."}),c.jsx(lf,{page:n,totalPages:a,onChange:r})]}),b&&c.jsx(Yce,{onClose:()=>v(!1),onSaved:()=>{v(!1),y()}}),x&&c.jsx(Vce,{detail:x,onClose:()=>m(null),onChanged:()=>{m(null),y()}})]})}function Yce({onClose:e,onSaved:t}){const[n,r]=O.useState(""),[a,i]=O.useState(localStorage.getItem("esn_user")||"admin"),[o,l]=O.useState(new Date().toISOString().slice(0,10)),[s,u]=O.useState("NORMAL"),[d,f]=O.useState(""),h=async()=>{var p,b;f("");try{await r8({title:n,writerId:a,workDate:o,workStatusCd:s,progressCd:"ONGOING",details:[]}),t()}catch(v){f(((b=(p=v==null?void 0:v.response)==null?void 0:p.data)==null?void 0:b.message)||"저장 실패")}};return c.jsxs(rr,{title:"업무일지 작성",onClose:e,footer:c.jsxs(c.Fragment,{children:[c.jsx(ne,{variant:"ghost",onClick:e,children:"취소"}),c.jsx(ne,{onClick:h,children:"저장"})]}),children:[c.jsx(ye,{label:"제목",children:c.jsx(pe,{value:n,onChange:r,style:{width:"100%"}})}),c.jsx(ye,{label:"작성자 ID",children:c.jsx(pe,{value:a,onChange:i,style:{width:"100%"}})}),c.jsx(ye,{label:"근무일자",children:c.jsx(pe,{type:"date",value:o,onChange:l,style:{width:"100%"}})}),c.jsx(ye,{label:"근무상태 코드",children:c.jsx(pe,{value:s,onChange:u,style:{width:"100%"}})}),d&&c.jsx("div",{style:{color:"var(--uiws-danger)",fontSize:13},children:d})]})}function Vce({detail:e,onClose:t,onChanged:n}){var u;const[r,a]=O.useState(""),[i,o]=O.useState(""),l=async()=>{await i8(e.worklogId),n()},s=async()=>{var d,f;o("");try{await o8(e.worklogId,r),a(""),n()}catch(h){o(((f=(d=h==null?void 0:h.response)==null?void 0:d.data)==null?void 0:f.message)||"댓글 등록 실패")}};return c.jsxs(rr,{title:e.title,onClose:t,footer:c.jsxs(c.Fragment,{children:[c.jsx(ne,{variant:"danger",onClick:l,children:"삭제"}),c.jsx(ne,{variant:"ghost",onClick:t,children:"닫기"})]}),children:[c.jsxs("div",{style:{fontSize:13,color:"var(--uiws-text-muted)",marginBottom:12},children:[e.writerNm," · ",e.workDate," · ",e.progressCd]}),c.jsxs("div",{style:{fontSize:12,color:"var(--uiws-text-muted)",marginBottom:6},children:["시간대별 상세 ",((u=e.details)==null?void 0:u.length)??0,"건"]}),c.jsxs("div",{style:{marginTop:14},children:[c.jsx("div",{style:{fontSize:12,color:"var(--uiws-text-muted)",marginBottom:8},children:"댓글"}),(e.comments??[]).map(d=>c.jsxs("div",{style:{padding:"8px 10px",borderRadius:8,background:"var(--uiws-surface-2)",marginBottom:6,fontSize:13},children:[c.jsx("b",{children:d.writerNm})," · ",c.jsx("span",{style:{color:"var(--uiws-text-muted)"},children:d.createdAt}),c.jsx("br",{}),d.cmtContent]},d.cmtId)),c.jsxs("div",{style:{display:"flex",gap:8,marginTop:8},children:[c.jsx(pe,{value:r,onChange:a,placeholder:"댓글 입력(관리자/매니저)",style:{flex:1}}),c.jsx(ne,{onClick:s,children:"등록"})]}),i&&c.jsx("div",{style:{color:"var(--uiws-danger)",fontSize:12,marginTop:6},children:i})]})]})}const Xce=["일","월","화","수","목","금","토"];function Qce(){const[e,t]=O.useState(new Date),[n,r]=O.useState("PERSONAL"),[a,i]=O.useState([]),[o,l]=O.useState(!1),[s,u]=O.useState(null),[d,f]=O.useState(null),h=`${e.getFullYear()}-${String(e.getMonth()+1).padStart(2,"0")}`,p=async()=>{l(!0);try{const S=await Wz({type:n,view:"month",baseDate:`${h}-01`});i(S.data.data??[])}finally{l(!1)}};O.useEffect(()=>{p()},[h,n]);const v=new Date(e.getFullYear(),e.getMonth(),1).getDay(),x=new Date(e.getFullYear(),e.getMonth()+1,0).getDate(),m=[...Array(v).fill(null),...Array.from({length:x},(S,w)=>w+1)],y=S=>{const w=`${h}-${String(S).padStart(2,"0")}`;return a.filter(j=>(j.startDt??"").slice(0,10)<=w&&w<=(j.endDt??"").slice(0,10))},g=S=>t(new Date(e.getFullYear(),e.getMonth()+S,1));return c.jsxs("div",{className:"uiws-scope",children:[c.jsx(Rr,{title:"일정",subtitle:"UIWS 이식 · 개인/부서 일정 달력",actions:c.jsx(ne,{onClick:()=>u(`${h}-01`),children:"+ 일정 등록"})}),c.jsxs(_c,{style:{display:"flex",gap:10,alignItems:"center",marginBottom:16},children:[c.jsx(ne,{variant:"ghost",onClick:()=>g(-1),children:"‹ 이전"}),c.jsx("div",{style:{fontWeight:700,minWidth:130,textAlign:"center",color:"var(--uiws-text)"},children:h}),c.jsx(ne,{variant:"ghost",onClick:()=>g(1),children:"다음 ›"}),c.jsx("div",{style:{flex:1}}),c.jsx(ne,{variant:n==="PERSONAL"?"primary":"ghost",onClick:()=>r("PERSONAL"),children:"개인"}),c.jsx(ne,{variant:n==="DEPT"?"primary":"ghost",onClick:()=>r("DEPT"),children:"부서"})]}),o?c.jsx(er,{}):c.jsx("div",{style:{background:"var(--uiws-surface)",border:"1px solid var(--uiws-border)",borderRadius:12,overflow:"hidden"},children:c.jsxs("div",{style:{display:"grid",gridTemplateColumns:"repeat(7,1fr)"},children:[Xce.map((S,w)=>c.jsx("div",{style:{padding:"10px 0",textAlign:"center",fontSize:12,fontWeight:600,color:w===0?"var(--uiws-danger)":"var(--uiws-text-muted)",borderBottom:"1px solid var(--uiws-border)"},children:S},S)),m.map((S,w)=>c.jsxs("div",{onClick:()=>S&&u(`${h}-${String(S).padStart(2,"0")}`),style:{minHeight:96,padding:6,borderRight:"1px solid var(--uiws-border)",borderBottom:"1px solid var(--uiws-border)",cursor:S?"pointer":"default"},children:[S&&c.jsx("div",{style:{fontSize:12,color:"var(--uiws-text-muted)",marginBottom:4},children:S}),S&&y(S).slice(0,3).map(j=>c.jsx("div",{onClick:A=>{A.stopPropagation(),Jz(j.scheduleId).then(E=>f(E.data.data))},style:{fontSize:11,padding:"2px 6px",borderRadius:6,marginBottom:3,background:"var(--uiws-primary-soft)",color:"var(--uiws-primary)",overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis"},children:j.title},j.scheduleId))]},w))]})}),s&&c.jsx(Wce,{date:s,type:n,onClose:()=>u(null),onSaved:()=>{u(null),p()}}),d&&c.jsx(Zce,{detail:d,onClose:()=>f(null),onDeleted:()=>{f(null),p()}})]})}function Wce({date:e,type:t,onClose:n,onSaved:r}){const[a,i]=O.useState(""),[o,l]=O.useState(`${e}T09:00:00`),[s,u]=O.useState(`${e}T18:00:00`),[d,f]=O.useState(""),[h,p]=O.useState(""),b=async()=>{var v,x;p("");try{await Zz({scheType:t,title:a,startDt:o,endDt:s,content:d,attachmentIds:[]}),r()}catch(m){p(((x=(v=m==null?void 0:m.response)==null?void 0:v.data)==null?void 0:x.message)||"저장 실패")}};return c.jsxs(rr,{title:"일정 등록",onClose:n,footer:c.jsxs(c.Fragment,{children:[c.jsx(ne,{variant:"ghost",onClick:n,children:"취소"}),c.jsx(ne,{onClick:b,children:"저장"})]}),children:[c.jsx(ye,{label:"제목",children:c.jsx(pe,{value:a,onChange:i,style:{width:"100%"}})}),c.jsx(ye,{label:"시작(yyyy-MM-ddTHH:mm:ss)",children:c.jsx(pe,{value:o,onChange:l,style:{width:"100%"}})}),c.jsx(ye,{label:"종료",children:c.jsx(pe,{value:s,onChange:u,style:{width:"100%"}})}),c.jsx(ye,{label:"내용",children:c.jsx(pe,{value:d,onChange:f,style:{width:"100%"}})}),h&&c.jsx("div",{style:{color:"var(--uiws-danger)",fontSize:13},children:h})]})}function Zce({detail:e,onClose:t,onDeleted:n}){const r=async()=>{await e8(e.scheduleId),n()};return c.jsxs(rr,{title:e.title,onClose:t,footer:c.jsxs(c.Fragment,{children:[c.jsx(ne,{variant:"danger",onClick:r,children:"삭제"}),c.jsx(ne,{variant:"ghost",onClick:t,children:"닫기"})]}),children:[c.jsxs("div",{style:{fontSize:13,color:"var(--uiws-text-muted)",marginBottom:8},children:[e.scheType," · ",e.startDt," ~ ",e.endDt]}),c.jsx("div",{style:{fontSize:14,color:"var(--uiws-text)"},children:e.content||"내용 없음"})]})}function Jce(){const[e,t]=O.useState("received"),[n,r]=O.useState([]),[a,i]=O.useState(0),[o,l]=O.useState(0),[s,u]=O.useState(""),[d,f]=O.useState(!1),[h,p]=O.useState(!1),[b,v]=O.useState(null),x=async()=>{f(!0);try{const j=(await(e==="received"?Xz:Yz)({page:a,size:20,titleKeyword:s||void 0})).data.data;r(j.content??[]),l(j.totalPages??0)}finally{f(!1)}};O.useEffect(()=>{x()},[e,a]);const m=[{key:"title",header:"제목"},{key:"senderNm",header:"보낸사람",width:130},{key:"sentAt",header:"받은시각",width:170},{key:"readYn",header:"상태",width:90,render:S=>c.jsx(Oo,{yn:S.readYn})}],y=[{key:"title",header:"제목"},{key:"receiverSummary",header:"받는사람",width:160},{key:"open",header:"개봉",width:100,align:"center",render:S=>`${S.openCount}/${S.totalCount}`},{key:"sentAt",header:"보낸시각",width:170}],g=async S=>{const w=e==="received"?await Qz(S.messageId):await Vz(S.messageId);v({...w.data.data,_tab:e}),e==="received"&&x()};return c.jsxs("div",{className:"uiws-scope",children:[c.jsx(Rr,{title:"쪽지",subtitle:"UIWS 이식 · 사내 쪽지 송수신",actions:c.jsx(ne,{onClick:()=>p(!0),children:"+ 쪽지 보내기"})}),c.jsxs(mi,{children:[c.jsx(ne,{variant:e==="received"?"primary":"ghost",onClick:()=>{t("received"),i(0)},children:"받은쪽지함"}),c.jsx(ne,{variant:e==="sent"?"primary":"ghost",onClick:()=>{t("sent"),i(0)},children:"보낸쪽지함"}),c.jsx("div",{style:{flex:1}}),c.jsx(pe,{value:s,onChange:u,placeholder:"제목 검색",style:{minWidth:200}}),c.jsx(ne,{variant:"ghost",onClick:()=>{i(0),x()},children:"검색"})]}),d?c.jsx(er,{}):c.jsxs(c.Fragment,{children:[c.jsx(jo,{columns:e==="received"?m:y,rows:n,rowKey:S=>S.messageId,onRowClick:g,empty:"쪽지가 없습니다."}),c.jsx(lf,{page:a,totalPages:o,onChange:i})]}),h&&c.jsx(efe,{onClose:()=>p(!1),onSent:()=>{p(!1),x()}}),b&&c.jsx(tfe,{detail:b,onClose:()=>v(null)})]})}function efe({onClose:e,onSent:t}){const[n,r]=O.useState(""),[a,i]=O.useState(""),[o,l]=O.useState(""),[s,u]=O.useState(""),d=async()=>{var f,h;u("");try{await Kz({title:a,content:o,receivers:[{receiverId:n,rcvType:"RECV"}]}),t()}catch(p){u(((h=(f=p==null?void 0:p.response)==null?void 0:f.data)==null?void 0:h.message)||"전송 실패")}};return c.jsxs(rr,{title:"쪽지 보내기",onClose:e,footer:c.jsxs(c.Fragment,{children:[c.jsx(ne,{variant:"ghost",onClick:e,children:"취소"}),c.jsx(ne,{onClick:d,children:"보내기"})]}),children:[c.jsx(ye,{label:"받는사람 ID",children:c.jsx(pe,{value:n,onChange:r,style:{width:"100%"}})}),c.jsx(ye,{label:"제목",children:c.jsx(pe,{value:a,onChange:i,style:{width:"100%"}})}),c.jsx(ye,{label:"내용",children:c.jsx(pe,{value:o,onChange:l,style:{width:"100%"}})}),s&&c.jsx("div",{style:{color:"var(--uiws-danger)",fontSize:13},children:s})]})}function tfe({detail:e,onClose:t}){return c.jsxs(rr,{title:e.title,onClose:t,footer:c.jsx(ne,{variant:"ghost",onClick:t,children:"닫기"}),children:[c.jsxs("div",{style:{fontSize:13,color:"var(--uiws-text-muted)",marginBottom:10},children:[e._tab==="received"?`보낸사람: ${e.senderNm}`:`개봉 ${e.openCount}/${e.totalCount}`," · ",e.sentAt]}),c.jsx("div",{style:{fontSize:14,color:"var(--uiws-text)",whiteSpace:"pre-wrap"},children:e.content}),e._tab==="sent"&&e.receivers&&c.jsxs("div",{style:{marginTop:14},children:[c.jsx("div",{style:{fontSize:12,color:"var(--uiws-text-muted)",marginBottom:6},children:"수신자 개봉현황"}),e.receivers.map((n,r)=>c.jsxs("div",{style:{display:"flex",justifyContent:"space-between",fontSize:13,padding:"4px 0"},children:[c.jsxs("span",{children:[n.receiverNm," (",n.rcvType,")"]}),c.jsx(Oo,{yn:n.readYn})]},r))]})]})}function nfe(){const[e,t]=O.useState("personal"),[n,r]=O.useState(null),[a,i]=O.useState(!1),o=new Date().toISOString().slice(0,10),l=new Date(Date.now()-6*864e5).toISOString().slice(0,10),[s,u]=O.useState(l),[d,f]=O.useState(o),h=async()=>{i(!0);try{const v=await(e==="personal"?l8:s8)({fromDate:s,toDate:d});r(v.data.data)}finally{i(!1)}};O.useEffect(()=>{h()},[e]);const p=n?[...n.fixedColumns,...n.dynamicColumns]:[];return c.jsxs("div",{className:"uiws-scope",children:[c.jsx(Rr,{title:"업무통계",subtitle:"UIWS 이식 · 근무현황 동적 피벗"}),c.jsxs(mi,{children:[c.jsx(ne,{variant:e==="personal"?"primary":"ghost",onClick:()=>t("personal"),children:"개인별 근무현황"}),c.jsx(ne,{variant:e==="company"?"primary":"ghost",onClick:()=>t("company"),children:"업체별 근무현황"}),c.jsx("div",{style:{flex:1}}),c.jsx(pe,{type:"date",value:s,onChange:u}),c.jsx("span",{style:{color:"var(--uiws-text-muted)"},children:"~"}),c.jsx(pe,{type:"date",value:d,onChange:f}),c.jsx(ne,{variant:"ghost",onClick:h,children:"조회"})]}),a?c.jsx(er,{}):!n||n.rows.length===0?c.jsx("div",{style:{padding:28,textAlign:"center",color:"var(--uiws-text-faint)"},children:"집계 데이터가 없습니다."}):c.jsx("div",{style:{background:"var(--uiws-surface)",border:"1px solid var(--uiws-border)",borderRadius:12,overflow:"auto"},children:c.jsxs("table",{style:{width:"100%",borderCollapse:"collapse",fontSize:13,color:"var(--uiws-text)"},children:[c.jsx("thead",{children:c.jsx("tr",{style:{background:"var(--uiws-surface-2)"},children:p.map(b=>c.jsx("th",{style:{padding:"11px 14px",textAlign:"left",fontSize:12,fontWeight:600,color:"var(--uiws-text-muted)",borderBottom:"1px solid var(--uiws-border)",whiteSpace:"nowrap"},children:b.label},b.key))})}),c.jsx("tbody",{children:n.rows.map((b,v)=>c.jsx("tr",{style:{borderBottom:"1px solid var(--uiws-border)"},children:p.map(x=>c.jsx("td",{style:{padding:"10px 14px"},children:String(b[x.key]??"")},x.key))},v))})]})})]})}const v1=e=>e&&e.size>0?Math.ceil(e.total/e.size):0,rfe=(e,t=0,n=20)=>H.get("/api/system/roles",{params:{keyword:e||void 0,page:t,size:n}}),afe=e=>H.post("/api/system/roles",e),ife=(e,t)=>H.put(`/api/system/roles/${encodeURIComponent(e)}`,t),ofe=e=>H.delete("/api/system/roles",{data:{ids:e}}),lfe=(e=0,t=100)=>H.get("/api/system/role-menus",{params:{page:e,size:t}}),sfe=e=>H.get(`/api/system/roles/${encodeURIComponent(e)}/menus`),ufe=(e,t)=>H.put(`/api/system/roles/${encodeURIComponent(e)}/menus`,{menus:t}),cfe=(e,t=0,n=20)=>H.get("/api/system/codes",{params:{keyword:e||void 0,page:t,size:n}}),zR=e=>H.get(`/api/system/codes/${encodeURIComponent(e)}`),ffe=e=>H.post("/api/system/codes",e),BR=(e,t)=>H.put(`/api/system/codes/${encodeURIComponent(e)}`,t),dfe=e=>H.delete(`/api/system/codes/${encodeURIComponent(e)}`),hfe=(e=0,t=100)=>H.get("/api/system/menus",{params:{page:e,size:t}}),pfe=e=>H.post("/api/system/menus",e),mfe=(e,t)=>H.put(`/api/system/menus/${encodeURIComponent(e)}`,t),yfe=e=>H.delete("/api/system/menus",{data:{ids:e}}),vfe=(e,t=0,n=100)=>H.get("/api/system/depts",{params:{keyword:void 0,page:t,size:n}}),gfe=e=>H.post("/api/system/depts",e),bfe=(e,t)=>H.put(`/api/system/depts/${encodeURIComponent(e)}`,t),xfe=e=>H.delete(`/api/system/depts/${encodeURIComponent(e)}`),Sfe=(e,t=0,n=20)=>H.get("/api/system/companies",{params:{keyword:e||void 0,page:t,size:n}}),wfe=e=>H.post("/api/system/companies",e),jfe=(e,t)=>H.put(`/api/system/companies/${encodeURIComponent(e)}`,t),Ofe=e=>H.delete("/api/system/companies",{data:{ids:e}});function B0(e){var t,n,r,a;return((t=e==null?void 0:e.response)==null?void 0:t.status)===403?"권한이 없습니다 (관리자 전용).":((n=e==null?void 0:e.response)==null?void 0:n.status)===409?"이미 존재하는 권한ID입니다.":((a=(r=e==null?void 0:e.response)==null?void 0:r.data)==null?void 0:a.message)||"요청을 처리하지 못했습니다. 잠시 후 다시 시도하세요."}function Afe(){const[e,t]=O.useState([]),[n,r]=O.useState(0),[a,i]=O.useState(0),[o,l]=O.useState(""),[s,u]=O.useState(!1),[d,f]=O.useState(""),[h,p]=O.useState(new Set),[b,v]=O.useState(null),[x,m]=O.useState(!1),y=async(A=o,E=n)=>{u(!0),f("");try{const N=(await rfe(A||void 0,E)).data.data;t((N==null?void 0:N.content)??[]),i(v1(N)),p(new Set)}catch(_){f(B0(_))}finally{u(!1)}};O.useEffect(()=>{y(o,n)},[n]);const g=()=>{n===0?y(o,0):r(0)},S=A=>p(E=>{const _=new Set(E);return _.has(A)?_.delete(A):_.add(A),_}),w=async()=>{if(h.size!==0&&window.confirm(`선택한 권한 ${h.size}건을 삭제하시겠습니까?`))try{await ofe([...h]),await y()}catch(A){f(B0(A))}},j=[{key:"sel",header:"",width:44,align:"center",render:A=>c.jsx("input",{type:"checkbox",checked:h.has(A.roleId),onClick:E=>E.stopPropagation(),onChange:()=>S(A.roleId)})},{key:"roleId",header:"권한ID",width:180},{key:"roleNm",header:"권한명"},{key:"roleDesc",header:"설명"},{key:"useYn",header:"사용",width:80,align:"center",render:A=>c.jsx(Oo,{yn:A.useYn,yes:"사용",no:"미사용"})}];return c.jsxs("div",{className:"uiws-scope",children:[c.jsx(Rr,{title:"권한 관리",subtitle:"시스템관리(권한) · 역할(Role) 등록/수정/삭제 — RBAC",actions:c.jsxs(c.Fragment,{children:[c.jsx(ne,{variant:"danger",onClick:w,disabled:h.size===0,children:"선택 삭제"}),c.jsx(ne,{onClick:()=>{v(null),m(!0)},children:"+ 권한 등록"})]})}),d&&c.jsx("div",{style:{color:"var(--uiws-danger)",fontSize:13,marginBottom:12},children:d}),c.jsxs(mi,{children:[c.jsx(pe,{value:o,onChange:l,placeholder:"권한ID/권한명 검색",style:{minWidth:240}}),c.jsx(ne,{variant:"ghost",onClick:g,children:"검색"})]}),s?c.jsx(er,{}):c.jsxs(c.Fragment,{children:[c.jsx(jo,{columns:j,rows:e,rowKey:A=>A.roleId,onRowClick:A=>{v(A),m(!0)},empty:"등록된 권한이 없습니다."}),c.jsx(lf,{page:n,totalPages:a,onChange:r})]}),x&&c.jsx(Efe,{role:b,onClose:()=>m(!1),onSaved:()=>{m(!1),y()}})]})}function Efe({role:e,onClose:t,onSaved:n}){const r=!!e,[a,i]=O.useState((e==null?void 0:e.roleId)??""),[o,l]=O.useState((e==null?void 0:e.roleNm)??""),[s,u]=O.useState((e==null?void 0:e.roleDesc)??""),[d,f]=O.useState((e==null?void 0:e.useYn)??"Y"),[h,p]=O.useState(""),b=async()=>{if(p(""),!o.trim()){p("권한명은 필수입니다.");return}if(!r&&!a.trim()){p("권한ID는 필수입니다.");return}try{const v={roleId:a,roleNm:o,roleDesc:s,useYn:d};r?await ife(a,v):await afe(v),n()}catch(v){p(B0(v))}};return c.jsxs(rr,{title:r?"권한 수정":"권한 등록",onClose:t,footer:c.jsxs(c.Fragment,{children:[c.jsx(ne,{variant:"ghost",onClick:t,children:"취소"}),c.jsx(ne,{onClick:b,children:"저장"})]}),children:[c.jsx(ye,{label:"권한ID",children:c.jsx(pe,{value:a,onChange:i,style:{width:"100%",opacity:r?.6:1}})}),c.jsx(ye,{label:"권한명",children:c.jsx(pe,{value:o,onChange:l,style:{width:"100%"}})}),c.jsx(ye,{label:"설명",children:c.jsx(pe,{value:s,onChange:u,style:{width:"100%"}})}),c.jsx(ye,{label:"사용 여부",children:c.jsxs("select",{value:d,onChange:v=>f(v.target.value),style:{width:"100%",padding:"9px 12px",borderRadius:8,fontSize:13,background:"var(--uiws-input-bg)",border:"1px solid var(--uiws-border)",color:"var(--uiws-text)"},children:[c.jsx("option",{value:"Y",children:"사용"}),c.jsx("option",{value:"N",children:"미사용"})]})}),h&&c.jsx("div",{style:{color:"var(--uiws-danger)",fontSize:13},children:h})]})}function Fy(e){var t,n,r;return((t=e==null?void 0:e.response)==null?void 0:t.status)===403?"권한이 없습니다 (관리자 전용).":((r=(n=e==null?void 0:e.response)==null?void 0:n.data)==null?void 0:r.message)||"요청을 처리하지 못했습니다."}function _fe(){const[e,t]=O.useState([]),[n,r]=O.useState(""),[a,i]=O.useState([]),[o,l]=O.useState(!1),[s,u]=O.useState(!1),[d,f]=O.useState(!1),[h,p]=O.useState(""),[b,v]=O.useState("");O.useEffect(()=>{l(!0),lfe().then(g=>{var w;const S=((w=g.data.data)==null?void 0:w.content)??[];t(S),S.length>0&&r(S[0].roleId)}).catch(g=>v(Fy(g))).finally(()=>l(!1))},[]),O.useEffect(()=>{n&&(u(!0),p(""),v(""),sfe(n).then(g=>i(g.data.data??[])).catch(g=>v(Fy(g))).finally(()=>u(!1)))},[n]);const x=(g,S)=>i(w=>w.map(j=>{if(j.menuId!==g)return j;const A=j[S]==="Y"?"N":"Y";return S==="writeYn"&&A==="Y"?{...j,writeYn:"Y",readYn:"Y"}:S==="readYn"&&A==="N"?{...j,readYn:"N",writeYn:"N"}:{...j,[S]:A}})),m=(g,S)=>i(w=>w.map(j=>S&&g==="writeYn"?{...j,writeYn:"Y",readYn:"Y"}:!S&&g==="readYn"?{...j,readYn:"N",writeYn:"N"}:{...j,[g]:S?"Y":"N"})),y=async()=>{f(!0),p(""),v("");try{await ufe(n,a),p("메뉴 권한 매핑이 저장되었습니다.")}catch(g){v(Fy(g))}finally{f(!1)}};return c.jsxs("div",{className:"uiws-scope",children:[c.jsx(Rr,{title:"역할-메뉴 권한",subtitle:"시스템관리(권한) · 역할별 메뉴 접근(읽기/쓰기) 매핑 — RBAC 핵심",actions:c.jsx(ne,{onClick:y,disabled:d||!n,children:d?"저장 중...":"매핑 저장"})}),b&&c.jsx("div",{style:{color:"var(--uiws-danger)",fontSize:13,marginBottom:12},children:b}),h&&c.jsx("div",{style:{color:"var(--uiws-success)",fontSize:13,marginBottom:12},children:h}),c.jsxs("div",{style:{display:"grid",gridTemplateColumns:"260px 1fr",gap:16,alignItems:"start"},children:[c.jsxs(_c,{style:{padding:0},children:[c.jsx("div",{style:{padding:"12px 16px",fontSize:12,fontWeight:600,color:"var(--uiws-text-muted)",borderBottom:"1px solid var(--uiws-border)"},children:"역할 목록"}),o?c.jsx(er,{}):c.jsxs("div",{children:[e.length===0&&c.jsx("div",{style:{padding:20,fontSize:13,color:"var(--uiws-text-faint)"},children:"역할이 없습니다."}),e.map(g=>c.jsxs("div",{onClick:()=>r(g.roleId),style:{padding:"11px 16px",cursor:"pointer",fontSize:13,borderLeft:`3px solid ${n===g.roleId?"var(--uiws-primary)":"transparent"}`,background:n===g.roleId?"var(--uiws-primary-soft)":"transparent",color:n===g.roleId?"var(--uiws-primary)":"var(--uiws-text)"},children:[c.jsx("div",{style:{fontWeight:600},children:g.roleNm}),c.jsx("div",{style:{fontSize:11,color:"var(--uiws-text-muted)"},children:g.roleId})]},g.roleId))]})]}),c.jsx(_c,{style:{padding:0,overflow:"hidden"},children:s?c.jsx(er,{}):c.jsxs("table",{style:{width:"100%",borderCollapse:"collapse",fontSize:13,color:"var(--uiws-text)"},children:[c.jsx("thead",{children:c.jsxs("tr",{style:{background:"var(--uiws-surface-2)"},children:[c.jsx("th",{style:{textAlign:"left",padding:"11px 14px",color:"var(--uiws-text-muted)",fontWeight:600,fontSize:12,borderBottom:"1px solid var(--uiws-border)"},children:"메뉴"}),c.jsxs("th",{style:{width:120,padding:"8px 14px",color:"var(--uiws-text-muted)",fontSize:12,borderBottom:"1px solid var(--uiws-border)"},children:["읽기",c.jsx("br",{}),c.jsxs("label",{style:{fontWeight:400,fontSize:11},children:[c.jsx("input",{type:"checkbox",onChange:g=>m("readYn",g.target.checked)})," 전체"]})]}),c.jsxs("th",{style:{width:120,padding:"8px 14px",color:"var(--uiws-text-muted)",fontSize:12,borderBottom:"1px solid var(--uiws-border)"},children:["쓰기",c.jsx("br",{}),c.jsxs("label",{style:{fontWeight:400,fontSize:11},children:[c.jsx("input",{type:"checkbox",onChange:g=>m("writeYn",g.target.checked)})," 전체"]})]})]})}),c.jsx("tbody",{children:a.length===0?c.jsx("tr",{children:c.jsx("td",{colSpan:3,style:{padding:28,textAlign:"center",color:"var(--uiws-text-faint)"},children:"매핑 가능한 메뉴가 없습니다."})}):a.map(g=>c.jsxs("tr",{style:{borderBottom:"1px solid var(--uiws-border)"},children:[c.jsxs("td",{style:{padding:"11px 14px"},children:[g.menuNm," ",c.jsxs("span",{style:{color:"var(--uiws-text-muted)",fontSize:12},children:["(",g.menuId,")"]})]}),c.jsx("td",{style:{padding:"11px 14px",textAlign:"center"},children:c.jsx("input",{type:"checkbox",checked:g.readYn==="Y",onChange:()=>x(g.menuId,"readYn")})}),c.jsx("td",{style:{padding:"11px 14px",textAlign:"center"},children:c.jsx("input",{type:"checkbox",checked:g.writeYn==="Y",onChange:()=>x(g.menuId,"writeYn")})})]},g.menuId))})]})})]})]})}function Zo(e){var t,n,r,a;return((t=e==null?void 0:e.response)==null?void 0:t.status)===403?"권한이 없습니다 (관리자 전용).":((n=e==null?void 0:e.response)==null?void 0:n.status)===409?"이미 존재하는 코드그룹입니다.":((a=(r=e==null?void 0:e.response)==null?void 0:r.data)==null?void 0:a.message)||"요청을 처리하지 못했습니다."}const Tfe={width:"100%",padding:"9px 12px",borderRadius:8,fontSize:13,background:"var(--uiws-input-bg)",border:"1px solid var(--uiws-border)",color:"var(--uiws-text)"};function Nfe(){const[e,t]=O.useState([]),[n,r]=O.useState(0),[a,i]=O.useState(0),[o,l]=O.useState(""),[s,u]=O.useState(null),[d,f]=O.useState(""),[h,p]=O.useState(!1),[b,v]=O.useState(!1),[x,m]=O.useState(""),[y,g]=O.useState({open:!1,edit:null}),[S,w]=O.useState({open:!1,edit:null}),j=async(k=d,C=n)=>{p(!0),m("");try{const L=(await cfe(k||void 0,C)).data.data,z=(L==null?void 0:L.content)??[];t(z),i(v1(L)),(!o||!z.some(F=>F.grpCd===o))&&z.length>0?l(z[0].grpCd):z.length===0&&(l(""),u(null))}catch(M){m(Zo(M))}finally{p(!1)}};O.useEffect(()=>{j(d,n)},[n]);const A=async(k=o)=>{if(!k){u(null);return}v(!0);try{const C=await zR(k);u(C.data.data)}catch(C){m(Zo(C))}finally{v(!1)}};O.useEffect(()=>{A()},[o]);const E=()=>{n===0?j(d,0):r(0)},_=async k=>{if(window.confirm(`코드그룹 '${k}' 와 하위 코드를 삭제하시겠습니까?`))try{await dfe(k),o===k&&(l(""),u(null)),await j()}catch(C){m(Zo(C))}},N=async k=>{if(!s)return;const C={grpCd:s.grpCd,grpNm:s.grpNm,useYn:s.useYn,values:k.map(M=>({grpCd:s.grpCd,codeVal:M.codeVal,codeNm:M.codeNm,sortOrd:M.sortOrd??0,useYn:M.useYn}))};await BR(s.grpCd,C),await A(s.grpCd)},D=async k=>{if(s&&window.confirm(`코드 '${k.codeNm}' 를 삭제하시겠습니까?`))try{await N((s.values??[]).filter(C=>C.codeVal!==k.codeVal))}catch(C){m(Zo(C))}},R=async(k,C)=>{if(!s)return;const M=s.values??[];let L;if(C)L=M.map(z=>z.codeVal===C.codeVal?k:z);else{if(M.some(z=>z.codeVal===k.codeVal))throw{response:{status:409}};L=[...M,k]}await N(L)},B=[{key:"codeVal",header:"코드값",width:150},{key:"codeNm",header:"코드명"},{key:"sortOrd",header:"정렬",width:70,align:"center"},{key:"useYn",header:"사용",width:80,align:"center",render:k=>c.jsx(Oo,{yn:k.useYn,yes:"사용",no:"미사용"})},{key:"act",header:"",width:60,align:"center",render:k=>c.jsx(ne,{variant:"ghost",onClick:()=>D(k),children:"삭제"})}];return c.jsxs("div",{className:"uiws-scope",children:[c.jsx(Rr,{title:"공통코드 관리",subtitle:"시스템관리(권한) · 코드그룹/코드값 CRUD",actions:c.jsx(ne,{onClick:()=>g({open:!0,edit:null}),children:"+ 코드그룹 등록"})}),x&&c.jsx("div",{style:{color:"var(--uiws-danger)",fontSize:13,marginBottom:12},children:x}),c.jsxs(mi,{children:[c.jsx(pe,{value:d,onChange:f,placeholder:"코드그룹 검색",style:{minWidth:220}}),c.jsx(ne,{variant:"ghost",onClick:E,children:"검색"})]}),c.jsxs("div",{style:{display:"grid",gridTemplateColumns:"300px 1fr",gap:16,alignItems:"start"},children:[c.jsxs("div",{children:[c.jsxs(_c,{style:{padding:0},children:[c.jsx("div",{style:{padding:"12px 16px",fontSize:12,fontWeight:600,color:"var(--uiws-text-muted)",borderBottom:"1px solid var(--uiws-border)"},children:"코드그룹"}),h?c.jsx(er,{}):c.jsxs("div",{children:[e.length===0&&c.jsx("div",{style:{padding:20,fontSize:13,color:"var(--uiws-text-faint)"},children:"코드그룹이 없습니다."}),e.map(k=>c.jsxs("div",{onClick:()=>l(k.grpCd),style:{padding:"11px 16px",cursor:"pointer",fontSize:13,display:"flex",justifyContent:"space-between",alignItems:"center",borderLeft:`3px solid ${o===k.grpCd?"var(--uiws-primary)":"transparent"}`,background:o===k.grpCd?"var(--uiws-primary-soft)":"transparent"},children:[c.jsxs("div",{children:[c.jsx("div",{style:{fontWeight:600,color:o===k.grpCd?"var(--uiws-primary)":"var(--uiws-text)"},children:k.grpNm}),c.jsx("div",{style:{fontSize:11,color:"var(--uiws-text-muted)"},children:k.grpCd})]}),c.jsxs("div",{style:{display:"flex",gap:6},onClick:C=>C.stopPropagation(),children:[c.jsx(ne,{variant:"ghost",onClick:()=>g({open:!0,edit:k}),children:"수정"}),c.jsx(ne,{variant:"ghost",onClick:()=>_(k.grpCd),children:"삭제"})]})]},k.grpCd))]})]}),c.jsx(lf,{page:n,totalPages:a,onChange:r})]}),c.jsxs("div",{children:[c.jsxs("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center",marginBottom:12},children:[c.jsxs("div",{style:{fontSize:14,fontWeight:600,color:"var(--uiws-text)"},children:["코드값 ",o&&c.jsxs("span",{style:{color:"var(--uiws-text-muted)",fontWeight:400},children:["(",o,")"]})]}),c.jsx(ne,{onClick:()=>w({open:!0,edit:null}),disabled:!s,children:"+ 코드값 등록"})]}),b?c.jsx(er,{}):c.jsx(jo,{columns:B,rows:(s==null?void 0:s.values)??[],rowKey:k=>`${k.grpCd}:${k.codeVal}`,onRowClick:k=>w({open:!0,edit:k}),empty:o?"코드값이 없습니다.":"코드그룹을 선택하세요."})]})]}),y.open&&c.jsx(Cfe,{grp:y.edit,onClose:()=>g({open:!1,edit:null}),onSaved:()=>{g({open:!1,edit:null}),j(d)}}),S.open&&s&&c.jsx(Mfe,{grpCd:s.grpCd,code:S.edit,onClose:()=>w({open:!1,edit:null}),onSave:R,onSaved:()=>w({open:!1,edit:null})})]})}function IR({value:e,onChange:t}){return c.jsxs("select",{value:e,onChange:n=>t(n.target.value),style:Tfe,children:[c.jsx("option",{value:"Y",children:"사용"}),c.jsx("option",{value:"N",children:"미사용"})]})}function Cfe({grp:e,onClose:t,onSaved:n}){const r=!!e,[a,i]=O.useState((e==null?void 0:e.grpCd)??""),[o,l]=O.useState((e==null?void 0:e.grpNm)??""),[s,u]=O.useState((e==null?void 0:e.useYn)??"Y"),[d,f]=O.useState(""),h=async()=>{if(f(""),!r&&!a.trim()){f("그룹코드는 필수입니다.");return}if(!o.trim()){f("그룹명은 필수입니다.");return}try{if(r){const b=(await zR(a)).data.data;await BR(a,{grpCd:a,grpNm:o,useYn:s,values:b.values??[]})}else await ffe({grpCd:a,grpNm:o,useYn:s,values:[]});n()}catch(p){f(Zo(p))}};return c.jsxs(rr,{title:r?"코드그룹 수정":"코드그룹 등록",onClose:t,footer:c.jsxs(c.Fragment,{children:[c.jsx(ne,{variant:"ghost",onClick:t,children:"취소"}),c.jsx(ne,{onClick:h,children:"저장"})]}),children:[c.jsx(ye,{label:"그룹코드",children:c.jsx(pe,{value:a,onChange:i,style:{width:"100%",opacity:r?.6:1}})}),c.jsx(ye,{label:"그룹명",children:c.jsx(pe,{value:o,onChange:l,style:{width:"100%"}})}),c.jsx(ye,{label:"사용 여부",children:c.jsx(IR,{value:s,onChange:u})}),d&&c.jsx("div",{style:{color:"var(--uiws-danger)",fontSize:13},children:d})]})}function Mfe({grpCd:e,code:t,onClose:n,onSave:r,onSaved:a}){const i=!!t,[o,l]=O.useState((t==null?void 0:t.codeVal)??""),[s,u]=O.useState((t==null?void 0:t.codeNm)??""),[d,f]=O.useState(String((t==null?void 0:t.sortOrd)??0)),[h,p]=O.useState((t==null?void 0:t.useYn)??"Y"),[b,v]=O.useState(""),x=async()=>{var m;if(v(""),!i&&!o.trim()){v("코드값은 필수입니다.");return}if(!s.trim()){v("코드명은 필수입니다.");return}try{await r({grpCd:e,codeVal:o,codeNm:s,sortOrd:Number(d)||0,useYn:h},t),a()}catch(y){((m=y==null?void 0:y.response)==null?void 0:m.status)===409?v("이미 존재하는 코드값입니다."):v(Zo(y))}};return c.jsxs(rr,{title:i?"코드값 수정":"코드값 등록",onClose:n,footer:c.jsxs(c.Fragment,{children:[c.jsx(ne,{variant:"ghost",onClick:n,children:"취소"}),c.jsx(ne,{onClick:x,children:"저장"})]}),children:[c.jsx(ye,{label:"그룹코드",children:c.jsx(pe,{value:e,onChange:()=>{},style:{width:"100%",opacity:.6}})}),c.jsx(ye,{label:"코드값",children:c.jsx(pe,{value:o,onChange:l,style:{width:"100%",opacity:i?.6:1}})}),c.jsx(ye,{label:"코드명",children:c.jsx(pe,{value:s,onChange:u,style:{width:"100%"}})}),c.jsx(ye,{label:"정렬순서",children:c.jsx(pe,{type:"number",value:d,onChange:f,style:{width:"100%"}})}),c.jsx(ye,{label:"사용 여부",children:c.jsx(IR,{value:h,onChange:p})}),b&&c.jsx("div",{style:{color:"var(--uiws-danger)",fontSize:13},children:b})]})}function I0(e){var t,n,r,a;return((t=e==null?void 0:e.response)==null?void 0:t.status)===403?"권한이 없습니다 (관리자 전용).":((n=e==null?void 0:e.response)==null?void 0:n.status)===409?"이미 존재하는 메뉴ID입니다.":((a=(r=e==null?void 0:e.response)==null?void 0:r.data)==null?void 0:a.message)||"요청을 처리하지 못했습니다."}function Rfe(){const[e,t]=O.useState([]),[n,r]=O.useState(""),[a,i]=O.useState(!1),[o,l]=O.useState(""),[s,u]=O.useState({open:!1,edit:null}),d=async()=>{var b;i(!0),l("");try{const v=await hfe();t(((b=v.data.data)==null?void 0:b.content)??[])}catch(v){l(I0(v))}finally{i(!1)}};O.useEffect(()=>{d()},[]);const f=O.useMemo(()=>{const b=n.trim().toLowerCase(),v=e.filter(g=>!g.parentMenuId).sort((g,S)=>(g.sortOrd??0)-(S.sortOrd??0)),x=[];for(const g of v)x.push({menu:g,depth:0}),e.filter(S=>S.parentMenuId===g.menuId).sort((S,w)=>(S.sortOrd??0)-(w.sortOrd??0)).forEach(S=>x.push({menu:S,depth:1}));const m=new Set(x.map(g=>g.menu.menuId));e.filter(g=>!m.has(g.menuId)).forEach(g=>x.push({menu:g,depth:0}));let y=x.map(g=>({...g.menu,_depth:g.depth}));return b&&(y=y.filter(g=>(g.menuNm??"").toLowerCase().includes(b)||(g.menuId??"").toLowerCase().includes(b))),y},[e,n]),h=async b=>{if(window.confirm(`메뉴 '${b.menuNm}' 를 삭제하시겠습니까?`))try{await yfe([b.menuId]),await d()}catch(v){l(I0(v))}},p=[{key:"menuNm",header:"메뉴명",render:b=>c.jsxs("span",{style:{paddingLeft:b._depth*22},children:[b._depth>0&&c.jsx("span",{style:{color:"var(--uiws-text-faint)"},children:"└ "}),b.menuNm," ",c.jsxs("span",{style:{color:"var(--uiws-text-muted)",fontSize:12},children:["(",b.menuId,")"]})]})},{key:"menuUrl",header:"URL",width:220,render:b=>b.menuUrl??"-"},{key:"programId",header:"프로그램",width:140,render:b=>b.programId??"-"},{key:"sortOrd",header:"정렬",width:70,align:"center"},{key:"useYn",header:"사용",width:80,align:"center",render:b=>c.jsx(Oo,{yn:b.useYn,yes:"사용",no:"미사용"})},{key:"act",header:"",width:60,align:"center",render:b=>c.jsx(ne,{variant:"ghost",onClick:()=>h(b),children:"삭제"})}];return c.jsxs("div",{className:"uiws-scope",children:[c.jsx(Rr,{title:"메뉴 관리",subtitle:"시스템관리(권한) · 메뉴 트리(2-depth) 등록/수정/삭제",actions:c.jsx(ne,{onClick:()=>u({open:!0,edit:null}),children:"+ 메뉴 등록"})}),o&&c.jsx("div",{style:{color:"var(--uiws-danger)",fontSize:13,marginBottom:12},children:o}),c.jsxs(mi,{children:[c.jsx(pe,{value:n,onChange:r,placeholder:"메뉴명 검색",style:{minWidth:220}}),c.jsx(ne,{variant:"ghost",onClick:()=>r(n),children:"검색"})]}),a?c.jsx(er,{}):c.jsx(jo,{columns:p,rows:f,rowKey:b=>b.menuId,onRowClick:b=>u({open:!0,edit:b}),empty:"등록된 메뉴가 없습니다."}),s.open&&c.jsx(Pfe,{menu:s.edit,parents:e.filter(b=>!b.parentMenuId),onClose:()=>u({open:!1,edit:null}),onSaved:()=>{u({open:!1,edit:null}),d()}})]})}function Pfe({menu:e,parents:t,onClose:n,onSaved:r}){const a=!!e,[i,o]=O.useState((e==null?void 0:e.menuId)??""),[l,s]=O.useState((e==null?void 0:e.menuNm)??""),[u,d]=O.useState((e==null?void 0:e.parentMenuId)??""),[f,h]=O.useState((e==null?void 0:e.programId)??""),[p,b]=O.useState((e==null?void 0:e.menuUrl)??""),[v,x]=O.useState(String((e==null?void 0:e.sortOrd)??0)),[m,y]=O.useState((e==null?void 0:e.useYn)??"Y"),[g,S]=O.useState(""),w=async()=>{if(S(""),!a&&!i.trim()){S("메뉴ID는 필수입니다.");return}if(!l.trim()){S("메뉴명은 필수입니다.");return}try{const A={menuId:i,menuNm:l,parentMenuId:u||null,programId:f||null,menuUrl:p||null,sortOrd:Number(v)||0,useYn:m};a?await mfe(i,A):await pfe(A),r()}catch(A){S(I0(A))}},j={width:"100%",padding:"9px 12px",borderRadius:8,fontSize:13,background:"var(--uiws-input-bg)",border:"1px solid var(--uiws-border)",color:"var(--uiws-text)"};return c.jsxs(rr,{title:a?"메뉴 수정":"메뉴 등록",onClose:n,footer:c.jsxs(c.Fragment,{children:[c.jsx(ne,{variant:"ghost",onClick:n,children:"취소"}),c.jsx(ne,{onClick:w,children:"저장"})]}),children:[c.jsx(ye,{label:"메뉴ID",children:c.jsx(pe,{value:i,onChange:o,style:{width:"100%",opacity:a?.6:1}})}),c.jsx(ye,{label:"메뉴명",children:c.jsx(pe,{value:l,onChange:s,style:{width:"100%"}})}),c.jsx(ye,{label:"상위 메뉴",children:c.jsxs("select",{value:u,onChange:A=>d(A.target.value),style:j,children:[c.jsx("option",{value:"",children:"(최상위)"}),t.filter(A=>A.menuId!==i).map(A=>c.jsxs("option",{value:A.menuId,children:[A.menuNm," (",A.menuId,")"]},A.menuId))]})}),c.jsx(ye,{label:"프로그램ID",children:c.jsx(pe,{value:f,onChange:h,style:{width:"100%"}})}),c.jsx(ye,{label:"메뉴 URL",children:c.jsx(pe,{value:p,onChange:b,style:{width:"100%"}})}),c.jsx(ye,{label:"정렬순서",children:c.jsx(pe,{type:"number",value:v,onChange:x,style:{width:"100%"}})}),c.jsx(ye,{label:"사용 여부",children:c.jsxs("select",{value:m,onChange:A=>y(A.target.value),style:j,children:[c.jsx("option",{value:"Y",children:"사용"}),c.jsx("option",{value:"N",children:"미사용"})]})}),g&&c.jsx("div",{style:{color:"var(--uiws-danger)",fontSize:13},children:g})]})}function U0(e){var t,n,r,a;return((t=e==null?void 0:e.response)==null?void 0:t.status)===403?"권한이 없습니다 (관리자 전용).":((n=e==null?void 0:e.response)==null?void 0:n.status)===409?"이미 존재하는 부서ID입니다.":((a=(r=e==null?void 0:e.response)==null?void 0:r.data)==null?void 0:a.message)||"요청을 처리하지 못했습니다."}function $fe(){const[e,t]=O.useState([]),[n,r]=O.useState(""),[a,i]=O.useState(!1),[o,l]=O.useState(""),[s,u]=O.useState({open:!1,edit:null}),d=async()=>{var b;i(!0),l("");try{const v=await vfe();t(((b=v.data.data)==null?void 0:b.content)??[])}catch(v){l(U0(v))}finally{i(!1)}};O.useEffect(()=>{d()},[]);const f=O.useMemo(()=>{const b=n.trim().toLowerCase(),v=e.filter(y=>!y.parentDeptId).sort((y,g)=>(y.sortOrd??0)-(g.sortOrd??0)),x=[];for(const y of v)x.push({...y,_depth:0}),e.filter(g=>g.parentDeptId===y.deptId).sort((g,S)=>(g.sortOrd??0)-(S.sortOrd??0)).forEach(g=>x.push({...g,_depth:1}));const m=new Set(x.map(y=>y.deptId));return e.filter(y=>!m.has(y.deptId)).forEach(y=>x.push({...y,_depth:0})),b?x.filter(y=>(y.deptNm??"").toLowerCase().includes(b)||(y.deptId??"").toLowerCase().includes(b)):x},[e,n]),h=async b=>{if(window.confirm(`부서 '${b.deptNm}' 를 삭제하시겠습니까?`))try{await xfe(b.deptId),await d()}catch(v){l(U0(v))}},p=[{key:"deptNm",header:"부서명",render:b=>c.jsxs("span",{style:{paddingLeft:b._depth*22},children:[b._depth>0&&c.jsx("span",{style:{color:"var(--uiws-text-faint)"},children:"└ "}),b.deptNm," ",c.jsxs("span",{style:{color:"var(--uiws-text-muted)",fontSize:12},children:["(",b.deptId,")"]})]})},{key:"sortOrd",header:"정렬",width:70,align:"center"},{key:"useYn",header:"사용",width:80,align:"center",render:b=>c.jsx(Oo,{yn:b.useYn,yes:"사용",no:"미사용"})},{key:"act",header:"",width:60,align:"center",render:b=>c.jsx(ne,{variant:"ghost",onClick:()=>h(b),children:"삭제"})}];return c.jsxs("div",{className:"uiws-scope",children:[c.jsx(Rr,{title:"부서 관리",subtitle:"시스템관리(권한) · 부서 트리(2-depth) 등록/수정/삭제",actions:c.jsx(ne,{onClick:()=>u({open:!0,edit:null}),children:"+ 부서 등록"})}),o&&c.jsx("div",{style:{color:"var(--uiws-danger)",fontSize:13,marginBottom:12},children:o}),c.jsxs(mi,{children:[c.jsx(pe,{value:n,onChange:r,placeholder:"부서명 검색",style:{minWidth:220}}),c.jsx(ne,{variant:"ghost",onClick:()=>r(n),children:"검색"})]}),a?c.jsx(er,{}):c.jsx(jo,{columns:p,rows:f,rowKey:b=>b.deptId,onRowClick:b=>u({open:!0,edit:b}),empty:"등록된 부서가 없습니다."}),s.open&&c.jsx(kfe,{dept:s.edit,parents:e.filter(b=>!b.parentDeptId),onClose:()=>u({open:!1,edit:null}),onSaved:()=>{u({open:!1,edit:null}),d()}})]})}function kfe({dept:e,parents:t,onClose:n,onSaved:r}){const a=!!e,[i,o]=O.useState((e==null?void 0:e.deptId)??""),[l,s]=O.useState((e==null?void 0:e.deptNm)??""),[u,d]=O.useState((e==null?void 0:e.parentDeptId)??""),[f,h]=O.useState(String((e==null?void 0:e.sortOrd)??0)),[p,b]=O.useState((e==null?void 0:e.useYn)??"Y"),[v,x]=O.useState(""),m={width:"100%",padding:"9px 12px",borderRadius:8,fontSize:13,background:"var(--uiws-input-bg)",border:"1px solid var(--uiws-border)",color:"var(--uiws-text)"},y=async()=>{if(x(""),!a&&!i.trim()){x("부서ID는 필수입니다.");return}if(!l.trim()){x("부서명은 필수입니다.");return}try{const g={deptId:i,deptNm:l,parentDeptId:u||null,sortOrd:Number(f)||0,useYn:p};a?await bfe(i,g):await gfe(g),r()}catch(g){x(U0(g))}};return c.jsxs(rr,{title:a?"부서 수정":"부서 등록",onClose:n,footer:c.jsxs(c.Fragment,{children:[c.jsx(ne,{variant:"ghost",onClick:n,children:"취소"}),c.jsx(ne,{onClick:y,children:"저장"})]}),children:[c.jsx(ye,{label:"부서ID",children:c.jsx(pe,{value:i,onChange:o,style:{width:"100%",opacity:a?.6:1}})}),c.jsx(ye,{label:"부서명",children:c.jsx(pe,{value:l,onChange:s,style:{width:"100%"}})}),c.jsx(ye,{label:"상위 부서",children:c.jsxs("select",{value:u,onChange:g=>d(g.target.value),style:m,children:[c.jsx("option",{value:"",children:"(최상위)"}),t.filter(g=>g.deptId!==i).map(g=>c.jsxs("option",{value:g.deptId,children:[g.deptNm," (",g.deptId,")"]},g.deptId))]})}),c.jsx(ye,{label:"정렬순서",children:c.jsx(pe,{type:"number",value:f,onChange:h,style:{width:"100%"}})}),c.jsx(ye,{label:"사용 여부",children:c.jsxs("select",{value:p,onChange:g=>b(g.target.value),style:m,children:[c.jsx("option",{value:"Y",children:"사용"}),c.jsx("option",{value:"N",children:"미사용"})]})}),v&&c.jsx("div",{style:{color:"var(--uiws-danger)",fontSize:13},children:v})]})}function q0(e){var t,n,r,a;return((t=e==null?void 0:e.response)==null?void 0:t.status)===403?"권한이 없습니다 (관리자 전용).":((n=e==null?void 0:e.response)==null?void 0:n.status)===409?"이미 존재하는 거래처ID입니다.":((a=(r=e==null?void 0:e.response)==null?void 0:r.data)==null?void 0:a.message)||"요청을 처리하지 못했습니다."}function Dfe(){const[e,t]=O.useState([]),[n,r]=O.useState(0),[a,i]=O.useState(0),[o,l]=O.useState(""),[s,u]=O.useState(!1),[d,f]=O.useState(""),[h,p]=O.useState({open:!1,edit:null}),b=async(y=o,g=n)=>{u(!0),f("");try{const w=(await Sfe(y||void 0,g)).data.data;t((w==null?void 0:w.content)??[]),i(v1(w))}catch(S){f(q0(S))}finally{u(!1)}};O.useEffect(()=>{b(o,n)},[n]);const v=()=>{n===0?b(o,0):r(0)},x=async y=>{if(window.confirm(`거래처 '${y.companyNm}' 를 삭제하시겠습니까?`))try{await Ofe([y.companyId]),await b()}catch(g){f(q0(g))}},m=[{key:"companyId",header:"거래처ID",width:180},{key:"companyNm",header:"거래처명"},{key:"bizNo",header:"사업자번호",width:180,render:y=>y.bizNo??"-"},{key:"useYn",header:"사용",width:80,align:"center",render:y=>c.jsx(Oo,{yn:y.useYn,yes:"사용",no:"미사용"})},{key:"act",header:"",width:60,align:"center",render:y=>c.jsx(ne,{variant:"ghost",onClick:()=>x(y),children:"삭제"})}];return c.jsxs("div",{className:"uiws-scope",children:[c.jsx(Rr,{title:"거래처 관리",subtitle:"시스템관리(권한) · 거래처(근무처) 등록/수정/삭제",actions:c.jsx(ne,{onClick:()=>p({open:!0,edit:null}),children:"+ 거래처 등록"})}),d&&c.jsx("div",{style:{color:"var(--uiws-danger)",fontSize:13,marginBottom:12},children:d}),c.jsxs(mi,{children:[c.jsx(pe,{value:o,onChange:l,placeholder:"거래처명 검색",style:{minWidth:220}}),c.jsx(ne,{variant:"ghost",onClick:v,children:"검색"})]}),s?c.jsx(er,{}):c.jsxs(c.Fragment,{children:[c.jsx(jo,{columns:m,rows:e,rowKey:y=>y.companyId,onRowClick:y=>p({open:!0,edit:y}),empty:"등록된 거래처가 없습니다."}),c.jsx(lf,{page:n,totalPages:a,onChange:r})]}),h.open&&c.jsx(Lfe,{company:h.edit,onClose:()=>p({open:!1,edit:null}),onSaved:()=>{p({open:!1,edit:null}),b()}})]})}function Lfe({company:e,onClose:t,onSaved:n}){const r=!!e,[a,i]=O.useState((e==null?void 0:e.companyId)??""),[o,l]=O.useState((e==null?void 0:e.companyNm)??""),[s,u]=O.useState((e==null?void 0:e.bizNo)??""),[d,f]=O.useState((e==null?void 0:e.useYn)??"Y"),[h,p]=O.useState(""),b=async()=>{if(p(""),!r&&!a.trim()){p("거래처ID는 필수입니다.");return}if(!o.trim()){p("거래처명은 필수입니다.");return}try{const v={companyId:a,companyNm:o,bizNo:s||null,useYn:d};r?await jfe(a,v):await wfe(v),n()}catch(v){p(q0(v))}};return c.jsxs(rr,{title:r?"거래처 수정":"거래처 등록",onClose:t,footer:c.jsxs(c.Fragment,{children:[c.jsx(ne,{variant:"ghost",onClick:t,children:"취소"}),c.jsx(ne,{onClick:b,children:"저장"})]}),children:[c.jsx(ye,{label:"거래처ID",children:c.jsx(pe,{value:a,onChange:i,style:{width:"100%",opacity:r?.6:1}})}),c.jsx(ye,{label:"거래처명",children:c.jsx(pe,{value:o,onChange:l,style:{width:"100%"}})}),c.jsx(ye,{label:"사업자번호",children:c.jsx(pe,{value:s,onChange:u,style:{width:"100%"}})}),c.jsx(ye,{label:"사용 여부",children:c.jsxs("select",{value:d,onChange:v=>f(v.target.value),style:{width:"100%",padding:"9px 12px",borderRadius:8,fontSize:13,background:"var(--uiws-input-bg)",border:"1px solid var(--uiws-border)",color:"var(--uiws-text)"},children:[c.jsx("option",{value:"Y",children:"사용"}),c.jsx("option",{value:"N",children:"미사용"})]})}),h&&c.jsx("div",{style:{color:"var(--uiws-danger)",fontSize:13},children:h})]})}const zfe=new qD;function Bfe(){return c.jsx(HD,{client:zfe,children:c.jsx(sD,{children:c.jsxs(zk,{children:[c.jsx(Ee,{path:"/login",element:c.jsx(u8,{})}),c.jsxs(Ee,{element:c.jsx(Hz,{}),children:[c.jsx(Ee,{path:"/dashboard",element:c.jsx(rce,{})}),c.jsx(Ee,{path:"/mypage",element:c.jsx(Gce,{})}),c.jsx(Ee,{path:"/stores",element:c.jsx(ace,{})}),c.jsx(Ee,{path:"/templates",element:c.jsx(oce,{})}),c.jsx(Ee,{path:"/pos-cvt",element:c.jsx(sce,{})}),c.jsx(Ee,{path:"/tag-binding",element:c.jsx(Dce,{})}),c.jsx(Ee,{path:"/update-queue",element:c.jsx(Lce,{})}),c.jsx(Ee,{path:"/alarms",element:c.jsx(cce,{})}),c.jsx(Ee,{path:"/hcore",element:c.jsx(hce,{})}),c.jsx(Ee,{path:"/works",element:c.jsx(mce,{})}),c.jsx(Ee,{path:"/firmware",element:c.jsx(yce,{})}),c.jsx(Ee,{path:"/products",element:c.jsx(xce,{})}),c.jsx(Ee,{path:"/users",element:c.jsx(gce,{})}),c.jsx(Ee,{path:"/tenants",element:c.jsx(wce,{})}),c.jsx(Ee,{path:"/audit",element:c.jsx(Ice,{})}),c.jsx(Ee,{path:"/settings",element:c.jsx(qce,{})}),c.jsx(Ee,{path:"/ai",element:c.jsx(Tce,{})}),c.jsx(Ee,{path:"/ai-techniques",element:c.jsx(Cce,{})}),c.jsx(Ee,{path:"/ai-platform",element:c.jsx(Pce,{})}),c.jsx(Ee,{path:"/worklogs",element:c.jsx(Kce,{})}),c.jsx(Ee,{path:"/schedules",element:c.jsx(Qce,{})}),c.jsx(Ee,{path:"/messages",element:c.jsx(Jce,{})}),c.jsx(Ee,{path:"/work-stats",element:c.jsx(nfe,{})}),c.jsx(Ee,{path:"/system/roles",element:c.jsx(Afe,{})}),c.jsx(Ee,{path:"/system/role-menus",element:c.jsx(_fe,{})}),c.jsx(Ee,{path:"/system/codes",element:c.jsx(Nfe,{})}),c.jsx(Ee,{path:"/system/menus",element:c.jsx(Rfe,{})}),c.jsx(Ee,{path:"/system/depts",element:c.jsx($fe,{})}),c.jsx(Ee,{path:"/system/companies",element:c.jsx(Dfe,{})}),c.jsx(Ee,{path:"/mobile-app",element:c.jsx(Fce,{})})]}),c.jsx(Ee,{path:"*",element:c.jsx(nN,{to:"/dashboard",replace:!0})})]})})})}L$.createRoot(document.getElementById("root")).render(c.jsx(O.StrictMode,{children:c.jsx(Bfe,{})}));
