From c959a45e9b8de4392389995fdd9eddc20ceaf96b Mon Sep 17 00:00:00 2001 From: Lucas Fads Date: Sun, 26 Nov 2023 15:03:32 -0300 Subject: [PATCH] Updates --- assets/index-DcwmwTUo.js | 134 ++++++++++++++++++++++++++++++++++++++ assets/index-G1C7AyTH.css | 1 + index.html | 13 ++++ vite.svg | 1 + 4 files changed, 149 insertions(+) create mode 100644 assets/index-DcwmwTUo.js create mode 100644 assets/index-G1C7AyTH.css create mode 100644 index.html create mode 100644 vite.svg diff --git a/assets/index-DcwmwTUo.js b/assets/index-DcwmwTUo.js new file mode 100644 index 0000000..4a8e534 --- /dev/null +++ b/assets/index-DcwmwTUo.js @@ -0,0 +1,134 @@ +function J_(e,t){for(var r=0;rn[i]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))n(i);new MutationObserver(i=>{for(const o of i)if(o.type==="childList")for(const a of o.addedNodes)a.tagName==="LINK"&&a.rel==="modulepreload"&&n(a)}).observe(document,{childList:!0,subtree:!0});function r(i){const o={};return i.integrity&&(o.integrity=i.integrity),i.referrerPolicy&&(o.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?o.credentials="include":i.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function n(i){if(i.ep)return;i.ep=!0;const o=r(i);fetch(i.href,o)}})();var Tu=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function ve(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Tb={exports:{}},Hs={},Cb={exports:{}},re={};/** + * @license React + * react.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 su=Symbol.for("react.element"),eP=Symbol.for("react.portal"),tP=Symbol.for("react.fragment"),rP=Symbol.for("react.strict_mode"),nP=Symbol.for("react.profiler"),iP=Symbol.for("react.provider"),oP=Symbol.for("react.context"),aP=Symbol.for("react.forward_ref"),uP=Symbol.for("react.suspense"),lP=Symbol.for("react.memo"),sP=Symbol.for("react.lazy"),wy=Symbol.iterator;function cP(e){return e===null||typeof e!="object"?null:(e=wy&&e[wy]||e["@@iterator"],typeof e=="function"?e:null)}var jb={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},Mb=Object.assign,Ib={};function io(e,t,r){this.props=e,this.context=t,this.refs=Ib,this.updater=r||jb}io.prototype.isReactComponent={};io.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("setState(...): 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")};io.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function Nb(){}Nb.prototype=io.prototype;function yh(e,t,r){this.props=e,this.context=t,this.refs=Ib,this.updater=r||jb}var mh=yh.prototype=new Nb;mh.constructor=yh;Mb(mh,io.prototype);mh.isPureReactComponent=!0;var xy=Array.isArray,Db=Object.prototype.hasOwnProperty,gh={current:null},Rb={key:!0,ref:!0,__self:!0,__source:!0};function Lb(e,t,r){var n,i={},o=null,a=null;if(t!=null)for(n in t.ref!==void 0&&(a=t.ref),t.key!==void 0&&(o=""+t.key),t)Db.call(t,n)&&!Rb.hasOwnProperty(n)&&(i[n]=t[n]);var u=arguments.length-2;if(u===1)i.children=r;else if(1>>1,H=C[X];if(0>>1;Xi($e,F))Zei(gt,$e)?(C[X]=gt,C[Ze]=F,X=Ze):(C[X]=$e,C[Pe]=F,X=Pe);else if(Zei(gt,F))C[X]=gt,C[Ze]=F,X=Ze;else break e}}return I}function i(C,I){var F=C.sortIndex-I.sortIndex;return F!==0?F:C.id-I.id}if(typeof performance=="object"&&typeof performance.now=="function"){var o=performance;e.unstable_now=function(){return o.now()}}else{var a=Date,u=a.now();e.unstable_now=function(){return a.now()-u}}var l=[],s=[],f=1,c=null,d=3,p=!1,h=!1,v=!1,g=typeof setTimeout=="function"?setTimeout:null,m=typeof clearTimeout=="function"?clearTimeout:null,y=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function b(C){for(var I=r(s);I!==null;){if(I.callback===null)n(s);else if(I.startTime<=C)n(s),I.sortIndex=I.expirationTime,t(l,I);else break;I=r(s)}}function S(C){if(v=!1,b(C),!h)if(r(l)!==null)h=!0,B(w);else{var I=r(s);I!==null&&R(S,I.startTime-C)}}function w(C,I){h=!1,v&&(v=!1,m(_),_=-1),p=!0;var F=d;try{for(b(I),c=r(l);c!==null&&(!(c.expirationTime>I)||C&&!A());){var X=c.callback;if(typeof X=="function"){c.callback=null,d=c.priorityLevel;var H=X(c.expirationTime<=I);I=e.unstable_now(),typeof H=="function"?c.callback=H:c===r(l)&&n(l),b(I)}else n(l);c=r(l)}if(c!==null)var ee=!0;else{var Pe=r(s);Pe!==null&&R(S,Pe.startTime-I),ee=!1}return ee}finally{c=null,d=F,p=!1}}var x=!1,O=null,_=-1,P=5,E=-1;function A(){return!(e.unstable_now()-EC||125X?(C.sortIndex=F,t(s,C),r(l)===null&&C===r(s)&&(v?(m(_),_=-1):v=!0,R(S,F-X))):(C.sortIndex=H,t(l,C),h||p||(h=!0,B(w))),C},e.unstable_shouldYield=A,e.unstable_wrapCallback=function(C){var I=d;return function(){var F=d;d=I;try{return C.apply(this,arguments)}finally{d=F}}}})(Ub);Fb.exports=Ub;var SP=Fb.exports;/** + * @license React + * react-dom.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 Wb=T,Et=SP;function z(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,r=1;r"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),nd=Object.prototype.hasOwnProperty,OP=/^[: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]*$/,Oy={},_y={};function _P(e){return nd.call(_y,e)?!0:nd.call(Oy,e)?!1:OP.test(e)?_y[e]=!0:(Oy[e]=!0,!1)}function PP(e,t,r,n){if(r!==null&&r.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return n?!1:r!==null?!r.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function AP(e,t,r,n){if(t===null||typeof t>"u"||PP(e,t,r,n))return!0;if(n)return!1;if(r!==null)switch(r.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function ct(e,t,r,n,i,o,a){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=n,this.attributeNamespace=i,this.mustUseProperty=r,this.propertyName=e,this.type=t,this.sanitizeURL=o,this.removeEmptyString=a}var Qe={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Qe[e]=new ct(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Qe[t]=new ct(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Qe[e]=new ct(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Qe[e]=new ct(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){Qe[e]=new ct(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Qe[e]=new ct(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Qe[e]=new ct(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Qe[e]=new ct(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Qe[e]=new ct(e,5,!1,e.toLowerCase(),null,!1,!1)});var wh=/[\-:]([a-z])/g;function xh(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(wh,xh);Qe[t]=new ct(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(wh,xh);Qe[t]=new ct(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(wh,xh);Qe[t]=new ct(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Qe[e]=new ct(e,1,!1,e.toLowerCase(),null,!1,!1)});Qe.xlinkHref=new ct("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Qe[e]=new ct(e,1,!1,e.toLowerCase(),null,!0,!0)});function Sh(e,t,r,n){var i=Qe.hasOwnProperty(t)?Qe[t]:null;(i!==null?i.type!==0:n||!(2u||i[a]!==o[u]){var l=` +`+i[a].replace(" at new "," at ");return e.displayName&&l.includes("")&&(l=l.replace("",e.displayName)),l}while(1<=a&&0<=u);break}}}finally{Zc=!1,Error.prepareStackTrace=r}return(e=e?e.displayName||e.name:"")?zo(e):""}function EP(e){switch(e.tag){case 5:return zo(e.type);case 16:return zo("Lazy");case 13:return zo("Suspense");case 19:return zo("SuspenseList");case 0:case 2:case 15:return e=Jc(e.type,!1),e;case 11:return e=Jc(e.type.render,!1),e;case 1:return e=Jc(e.type,!0),e;default:return""}}function ud(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case si:return"Fragment";case li:return"Portal";case id:return"Profiler";case Oh:return"StrictMode";case od:return"Suspense";case ad:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Vb:return(e.displayName||"Context")+".Consumer";case Kb:return(e._context.displayName||"Context")+".Provider";case _h:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case Ph:return t=e.displayName||null,t!==null?t:ud(e.type)||"Memo";case Gr:t=e._payload,e=e._init;try{return ud(e(t))}catch{}}return null}function $P(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return ud(t);case 8:return t===Oh?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function vn(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function qb(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function kP(e){var t=qb(e)?"checked":"value",r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),n=""+e[t];if(!e.hasOwnProperty(t)&&typeof r<"u"&&typeof r.get=="function"&&typeof r.set=="function"){var i=r.get,o=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(a){n=""+a,o.call(this,a)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return n},setValue:function(a){n=""+a},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Mu(e){e._valueTracker||(e._valueTracker=kP(e))}function Xb(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var r=t.getValue(),n="";return e&&(n=qb(e)?e.checked?"true":"false":e.value),e=n,e!==r?(t.setValue(e),!0):!1}function Sl(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}}function ld(e,t){var r=t.checked;return _e({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:r??e._wrapperState.initialChecked})}function Ay(e,t){var r=t.defaultValue==null?"":t.defaultValue,n=t.checked!=null?t.checked:t.defaultChecked;r=vn(t.value!=null?t.value:r),e._wrapperState={initialChecked:n,initialValue:r,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function Yb(e,t){t=t.checked,t!=null&&Sh(e,"checked",t,!1)}function sd(e,t){Yb(e,t);var r=vn(t.value),n=t.type;if(r!=null)n==="number"?(r===0&&e.value===""||e.value!=r)&&(e.value=""+r):e.value!==""+r&&(e.value=""+r);else if(n==="submit"||n==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?cd(e,t.type,r):t.hasOwnProperty("defaultValue")&&cd(e,t.type,vn(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function Ey(e,t,r){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var n=t.type;if(!(n!=="submit"&&n!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,r||t===e.value||(e.value=t),e.defaultValue=t}r=e.name,r!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,r!==""&&(e.name=r)}function cd(e,t,r){(t!=="number"||Sl(e.ownerDocument)!==e)&&(r==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+r&&(e.defaultValue=""+r))}var Fo=Array.isArray;function Oi(e,t,r,n){if(e=e.options,t){t={};for(var i=0;i"+t.valueOf().toString()+"",t=Iu.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function la(e,t){if(t){var r=e.firstChild;if(r&&r===e.lastChild&&r.nodeType===3){r.nodeValue=t;return}}e.textContent=t}var Vo={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},TP=["Webkit","ms","Moz","O"];Object.keys(Vo).forEach(function(e){TP.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Vo[t]=Vo[e]})});function ew(e,t,r){return t==null||typeof t=="boolean"||t===""?"":r||typeof t!="number"||t===0||Vo.hasOwnProperty(e)&&Vo[e]?(""+t).trim():t+"px"}function tw(e,t){e=e.style;for(var r in t)if(t.hasOwnProperty(r)){var n=r.indexOf("--")===0,i=ew(r,t[r],n);r==="float"&&(r="cssFloat"),n?e.setProperty(r,i):e[r]=i}}var CP=_e({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function pd(e,t){if(t){if(CP[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(z(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(z(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(z(61))}if(t.style!=null&&typeof t.style!="object")throw Error(z(62))}}function hd(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";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 vd=null;function Ah(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var yd=null,_i=null,Pi=null;function Ty(e){if(e=du(e)){if(typeof yd!="function")throw Error(z(280));var t=e.stateNode;t&&(t=Xs(t),yd(e.stateNode,e.type,t))}}function rw(e){_i?Pi?Pi.push(e):Pi=[e]:_i=e}function nw(){if(_i){var e=_i,t=Pi;if(Pi=_i=null,Ty(e),t)for(e=0;e>>=0,e===0?32:31-(UP(e)/WP|0)|0}var Nu=64,Du=4194304;function Uo(e){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: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 e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function Al(e,t){var r=e.pendingLanes;if(r===0)return 0;var n=0,i=e.suspendedLanes,o=e.pingedLanes,a=r&268435455;if(a!==0){var u=a&~i;u!==0?n=Uo(u):(o&=a,o!==0&&(n=Uo(o)))}else a=r&~i,a!==0?n=Uo(a):o!==0&&(n=Uo(o));if(n===0)return 0;if(t!==0&&t!==n&&!(t&i)&&(i=n&-n,o=t&-t,i>=o||i===16&&(o&4194240)!==0))return t;if(n&4&&(n|=r&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=n;0r;r++)t.push(e);return t}function cu(e,t,r){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-nr(t),e[t]=r}function GP(e,t){var r=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var n=e.eventTimes;for(e=e.expirationTimes;0=qo),By=" ",zy=!1;function Ow(e,t){switch(e){case"keyup":return xA.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function _w(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var ci=!1;function OA(e,t){switch(e){case"compositionend":return _w(t);case"keypress":return t.which!==32?null:(zy=!0,By);case"textInput":return e=t.data,e===By&&zy?null:e;default:return null}}function _A(e,t){if(ci)return e==="compositionend"||!Ih&&Ow(e,t)?(e=xw(),cl=Ch=Zr=null,ci=!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)return{node:r,offset:t-e};e=n}e:{for(;r;){if(r.nextSibling){r=r.nextSibling;break e}r=r.parentNode}r=void 0}r=Hy(r)}}function $w(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?$w(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function kw(){for(var e=window,t=Sl();t instanceof e.HTMLIFrameElement;){try{var r=typeof t.contentWindow.location.href=="string"}catch{r=!1}if(r)e=t.contentWindow;else break;t=Sl(e.document)}return t}function Nh(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")}function MA(e){var t=kw(),r=e.focusedElem,n=e.selectionRange;if(t!==r&&r&&r.ownerDocument&&$w(r.ownerDocument.documentElement,r)){if(n!==null&&Nh(r)){if(t=n.start,e=n.end,e===void 0&&(e=t),"selectionStart"in r)r.selectionStart=t,r.selectionEnd=Math.min(e,r.value.length);else if(e=(t=r.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var i=r.textContent.length,o=Math.min(n.start,i);n=n.end===void 0?o:Math.min(n.end,i),!e.extend&&o>n&&(i=n,n=o,o=i),i=Ky(r,o);var a=Ky(r,n);i&&a&&(e.rangeCount!==1||e.anchorNode!==i.node||e.anchorOffset!==i.offset||e.focusNode!==a.node||e.focusOffset!==a.offset)&&(t=t.createRange(),t.setStart(i.node,i.offset),e.removeAllRanges(),o>n?(e.addRange(t),e.extend(a.node,a.offset)):(t.setEnd(a.node,a.offset),e.addRange(t)))}}for(t=[],e=r;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof r.focus=="function"&&r.focus(),r=0;r=document.documentMode,fi=null,Sd=null,Yo=null,Od=!1;function Vy(e,t,r){var n=r.window===r?r.document:r.nodeType===9?r:r.ownerDocument;Od||fi==null||fi!==Sl(n)||(n=fi,"selectionStart"in n&&Nh(n)?n={start:n.selectionStart,end:n.selectionEnd}:(n=(n.ownerDocument&&n.ownerDocument.defaultView||window).getSelection(),n={anchorNode:n.anchorNode,anchorOffset:n.anchorOffset,focusNode:n.focusNode,focusOffset:n.focusOffset}),Yo&&ha(Yo,n)||(Yo=n,n=kl(Sd,"onSelect"),0hi||(e.current=kd[hi],kd[hi]=null,hi--)}function he(e,t){hi++,kd[hi]=e.current,e.current=t}var yn={},it=gn(yn),ht=gn(!1),Gn=yn;function Mi(e,t){var r=e.type.contextTypes;if(!r)return yn;var n=e.stateNode;if(n&&n.__reactInternalMemoizedUnmaskedChildContext===t)return n.__reactInternalMemoizedMaskedChildContext;var i={},o;for(o in r)i[o]=t[o];return n&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=i),i}function vt(e){return e=e.childContextTypes,e!=null}function Cl(){be(ht),be(it)}function Jy(e,t,r){if(it.current!==yn)throw Error(z(168));he(it,t),he(ht,r)}function Lw(e,t,r){var n=e.stateNode;if(t=t.childContextTypes,typeof n.getChildContext!="function")return r;n=n.getChildContext();for(var i in n)if(!(i in t))throw Error(z(108,$P(e)||"Unknown",i));return _e({},r,n)}function jl(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||yn,Gn=it.current,he(it,e),he(ht,ht.current),!0}function em(e,t,r){var n=e.stateNode;if(!n)throw Error(z(169));r?(e=Lw(e,t,Gn),n.__reactInternalMemoizedMergedChildContext=e,be(ht),be(it),he(it,e)):be(ht),he(ht,r)}var wr=null,Ys=!1,hf=!1;function Bw(e){wr===null?wr=[e]:wr.push(e)}function KA(e){Ys=!0,Bw(e)}function bn(){if(!hf&&wr!==null){hf=!0;var e=0,t=le;try{var r=wr;for(le=1;e>=a,i-=a,xr=1<<32-nr(t)+i|r<_?(P=O,O=null):P=O.sibling;var E=d(m,O,b[_],S);if(E===null){O===null&&(O=P);break}e&&O&&E.alternate===null&&t(m,O),y=o(E,y,_),x===null?w=E:x.sibling=E,x=E,O=P}if(_===b.length)return r(m,O),we&&Tn(m,_),w;if(O===null){for(;__?(P=O,O=null):P=O.sibling;var A=d(m,O,E.value,S);if(A===null){O===null&&(O=P);break}e&&O&&A.alternate===null&&t(m,O),y=o(A,y,_),x===null?w=A:x.sibling=A,x=A,O=P}if(E.done)return r(m,O),we&&Tn(m,_),w;if(O===null){for(;!E.done;_++,E=b.next())E=c(m,E.value,S),E!==null&&(y=o(E,y,_),x===null?w=E:x.sibling=E,x=E);return we&&Tn(m,_),w}for(O=n(m,O);!E.done;_++,E=b.next())E=p(O,m,_,E.value,S),E!==null&&(e&&E.alternate!==null&&O.delete(E.key===null?_:E.key),y=o(E,y,_),x===null?w=E:x.sibling=E,x=E);return e&&O.forEach(function(k){return t(m,k)}),we&&Tn(m,_),w}function g(m,y,b,S){if(typeof b=="object"&&b!==null&&b.type===si&&b.key===null&&(b=b.props.children),typeof b=="object"&&b!==null){switch(b.$$typeof){case ju:e:{for(var w=b.key,x=y;x!==null;){if(x.key===w){if(w=b.type,w===si){if(x.tag===7){r(m,x.sibling),y=i(x,b.props.children),y.return=m,m=y;break e}}else if(x.elementType===w||typeof w=="object"&&w!==null&&w.$$typeof===Gr&&um(w)===x.type){r(m,x.sibling),y=i(x,b.props),y.ref=Eo(m,x,b),y.return=m,m=y;break e}r(m,x);break}else t(m,x);x=x.sibling}b.type===si?(y=Wn(b.props.children,m.mode,S,b.key),y.return=m,m=y):(S=gl(b.type,b.key,b.props,null,m.mode,S),S.ref=Eo(m,y,b),S.return=m,m=S)}return a(m);case li:e:{for(x=b.key;y!==null;){if(y.key===x)if(y.tag===4&&y.stateNode.containerInfo===b.containerInfo&&y.stateNode.implementation===b.implementation){r(m,y.sibling),y=i(y,b.children||[]),y.return=m,m=y;break e}else{r(m,y);break}else t(m,y);y=y.sibling}y=Sf(b,m.mode,S),y.return=m,m=y}return a(m);case Gr:return x=b._init,g(m,y,x(b._payload),S)}if(Fo(b))return h(m,y,b,S);if(So(b))return v(m,y,b,S);Wu(m,b)}return typeof b=="string"&&b!==""||typeof b=="number"?(b=""+b,y!==null&&y.tag===6?(r(m,y.sibling),y=i(y,b),y.return=m,m=y):(r(m,y),y=xf(b,m.mode,S),y.return=m,m=y),a(m)):r(m,y)}return g}var Ni=Gw(!0),qw=Gw(!1),pu={},hr=gn(pu),ga=gn(pu),ba=gn(pu);function Rn(e){if(e===pu)throw Error(z(174));return e}function Hh(e,t){switch(he(ba,t),he(ga,e),he(hr,pu),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:dd(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=dd(t,e)}be(hr),he(hr,t)}function Di(){be(hr),be(ga),be(ba)}function Xw(e){Rn(ba.current);var t=Rn(hr.current),r=dd(t,e.type);t!==r&&(he(ga,e),he(hr,r))}function Kh(e){ga.current===e&&(be(hr),be(ga))}var Se=gn(0);function Ll(e){for(var t=e;t!==null;){if(t.tag===13){var r=t.memoizedState;if(r!==null&&(r=r.dehydrated,r===null||r.data==="$?"||r.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){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 vf=[];function Vh(){for(var e=0;er?r:4,e(!0);var n=yf.transition;yf.transition={};try{e(!1),t()}finally{le=r,yf.transition=n}}function fx(){return Ht().memoizedState}function XA(e,t,r){var n=sn(e);if(r={lane:n,action:r,hasEagerState:!1,eagerState:null,next:null},dx(e))px(t,r);else if(r=Ww(e,t,r,n),r!==null){var i=lt();ir(r,e,n,i),hx(r,t,n)}}function YA(e,t,r){var n=sn(e),i={lane:n,action:r,hasEagerState:!1,eagerState:null,next:null};if(dx(e))px(t,i);else{var o=e.alternate;if(e.lanes===0&&(o===null||o.lanes===0)&&(o=t.lastRenderedReducer,o!==null))try{var a=t.lastRenderedState,u=o(a,r);if(i.hasEagerState=!0,i.eagerState=u,or(u,a)){var l=t.interleaved;l===null?(i.next=i,Uh(t)):(i.next=l.next,l.next=i),t.interleaved=i;return}}catch{}finally{}r=Ww(e,t,i,n),r!==null&&(i=lt(),ir(r,e,n,i),hx(r,t,n))}}function dx(e){var t=e.alternate;return e===Oe||t!==null&&t===Oe}function px(e,t){Qo=Bl=!0;var r=e.pending;r===null?t.next=t:(t.next=r.next,r.next=t),e.pending=t}function hx(e,t,r){if(r&4194240){var n=t.lanes;n&=e.pendingLanes,r|=n,t.lanes=r,$h(e,r)}}var zl={readContext:Wt,useCallback:Je,useContext:Je,useEffect:Je,useImperativeHandle:Je,useInsertionEffect:Je,useLayoutEffect:Je,useMemo:Je,useReducer:Je,useRef:Je,useState:Je,useDebugValue:Je,useDeferredValue:Je,useTransition:Je,useMutableSource:Je,useSyncExternalStore:Je,useId:Je,unstable_isNewReconciler:!1},QA={readContext:Wt,useCallback:function(e,t){return cr().memoizedState=[e,t===void 0?null:t],e},useContext:Wt,useEffect:sm,useImperativeHandle:function(e,t,r){return r=r!=null?r.concat([e]):null,hl(4194308,4,ax.bind(null,t,e),r)},useLayoutEffect:function(e,t){return hl(4194308,4,e,t)},useInsertionEffect:function(e,t){return hl(4,2,e,t)},useMemo:function(e,t){var r=cr();return t=t===void 0?null:t,e=e(),r.memoizedState=[e,t],e},useReducer:function(e,t,r){var n=cr();return t=r!==void 0?r(t):t,n.memoizedState=n.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},n.queue=e,e=e.dispatch=XA.bind(null,Oe,e),[n.memoizedState,e]},useRef:function(e){var t=cr();return e={current:e},t.memoizedState=e},useState:lm,useDebugValue:Qh,useDeferredValue:function(e){return cr().memoizedState=e},useTransition:function(){var e=lm(!1),t=e[0];return e=qA.bind(null,e[1]),cr().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,r){var n=Oe,i=cr();if(we){if(r===void 0)throw Error(z(407));r=r()}else{if(r=t(),He===null)throw Error(z(349));Xn&30||Zw(n,t,r)}i.memoizedState=r;var o={value:r,getSnapshot:t};return i.queue=o,sm(ex.bind(null,n,o,e),[e]),n.flags|=2048,Sa(9,Jw.bind(null,n,o,r,t),void 0,null),r},useId:function(){var e=cr(),t=He.identifierPrefix;if(we){var r=Sr,n=xr;r=(n&~(1<<32-nr(n)-1)).toString(32)+r,t=":"+t+"R"+r,r=wa++,0<\/script>",e=e.removeChild(e.firstChild)):typeof n.is=="string"?e=a.createElement(r,{is:n.is}):(e=a.createElement(r),r==="select"&&(a=e,n.multiple?a.multiple=!0:n.size&&(a.size=n.size))):e=a.createElementNS(e,r),e[fr]=t,e[ma]=n,Ox(e,t,!1,!1),t.stateNode=e;e:{switch(a=hd(r,n),r){case"dialog":ye("cancel",e),ye("close",e),i=n;break;case"iframe":case"object":case"embed":ye("load",e),i=n;break;case"video":case"audio":for(i=0;iLi&&(t.flags|=128,n=!0,$o(o,!1),t.lanes=4194304)}else{if(!n)if(e=Ll(a),e!==null){if(t.flags|=128,n=!0,r=e.updateQueue,r!==null&&(t.updateQueue=r,t.flags|=4),$o(o,!0),o.tail===null&&o.tailMode==="hidden"&&!a.alternate&&!we)return et(t),null}else 2*Te()-o.renderingStartTime>Li&&r!==1073741824&&(t.flags|=128,n=!0,$o(o,!1),t.lanes=4194304);o.isBackwards?(a.sibling=t.child,t.child=a):(r=o.last,r!==null?r.sibling=a:t.child=a,o.last=a)}return o.tail!==null?(t=o.tail,o.rendering=t,o.tail=t.sibling,o.renderingStartTime=Te(),t.sibling=null,r=Se.current,he(Se,n?r&1|2:r&1),t):(et(t),null);case 22:case 23:return nv(),n=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==n&&(t.flags|=8192),n&&t.mode&1?Ot&1073741824&&(et(t),t.subtreeFlags&6&&(t.flags|=8192)):et(t),null;case 24:return null;case 25:return null}throw Error(z(156,t.tag))}function oE(e,t){switch(Rh(t),t.tag){case 1:return vt(t.type)&&Cl(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Di(),be(ht),be(it),Vh(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return Kh(t),null;case 13:if(be(Se),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(z(340));Ii()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return be(Se),null;case 4:return Di(),null;case 10:return Fh(t.type._context),null;case 22:case 23:return nv(),null;case 24:return null;default:return null}}var Ku=!1,rt=!1,aE=typeof WeakSet=="function"?WeakSet:Set,K=null;function gi(e,t){var r=e.ref;if(r!==null)if(typeof r=="function")try{r(null)}catch(n){Ee(e,t,n)}else r.current=null}function Fd(e,t,r){try{r()}catch(n){Ee(e,t,n)}}var gm=!1;function uE(e,t){if(_d=El,e=kw(),Nh(e)){if("selectionStart"in e)var r={start:e.selectionStart,end:e.selectionEnd};else e:{r=(r=e.ownerDocument)&&r.defaultView||window;var n=r.getSelection&&r.getSelection();if(n&&n.rangeCount!==0){r=n.anchorNode;var i=n.anchorOffset,o=n.focusNode;n=n.focusOffset;try{r.nodeType,o.nodeType}catch{r=null;break e}var a=0,u=-1,l=-1,s=0,f=0,c=e,d=null;t:for(;;){for(var p;c!==r||i!==0&&c.nodeType!==3||(u=a+i),c!==o||n!==0&&c.nodeType!==3||(l=a+n),c.nodeType===3&&(a+=c.nodeValue.length),(p=c.firstChild)!==null;)d=c,c=p;for(;;){if(c===e)break t;if(d===r&&++s===i&&(u=a),d===o&&++f===n&&(l=a),(p=c.nextSibling)!==null)break;c=d,d=c.parentNode}c=p}r=u===-1||l===-1?null:{start:u,end:l}}else r=null}r=r||{start:0,end:0}}else r=null;for(Pd={focusedElem:e,selectionRange:r},El=!1,K=t;K!==null;)if(t=K,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,K=e;else for(;K!==null;){t=K;try{var h=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(h!==null){var v=h.memoizedProps,g=h.memoizedState,m=t.stateNode,y=m.getSnapshotBeforeUpdate(t.elementType===t.type?v:Xt(t.type,v),g);m.__reactInternalSnapshotBeforeUpdate=y}break;case 3:var b=t.stateNode.containerInfo;b.nodeType===1?b.textContent="":b.nodeType===9&&b.documentElement&&b.removeChild(b.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(z(163))}}catch(S){Ee(t,t.return,S)}if(e=t.sibling,e!==null){e.return=t.return,K=e;break}K=t.return}return h=gm,gm=!1,h}function Zo(e,t,r){var n=t.updateQueue;if(n=n!==null?n.lastEffect:null,n!==null){var i=n=n.next;do{if((i.tag&e)===e){var o=i.destroy;i.destroy=void 0,o!==void 0&&Fd(t,r,o)}i=i.next}while(i!==n)}}function Js(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var r=t=t.next;do{if((r.tag&e)===e){var n=r.create;r.destroy=n()}r=r.next}while(r!==t)}}function Ud(e){var t=e.ref;if(t!==null){var r=e.stateNode;switch(e.tag){case 5:e=r;break;default:e=r}typeof t=="function"?t(e):t.current=e}}function Ax(e){var t=e.alternate;t!==null&&(e.alternate=null,Ax(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[fr],delete t[ma],delete t[$d],delete t[WA],delete t[HA])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function Ex(e){return e.tag===5||e.tag===3||e.tag===4}function bm(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Ex(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.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 Wd(e,t,r){var n=e.tag;if(n===5||n===6)e=e.stateNode,t?r.nodeType===8?r.parentNode.insertBefore(e,t):r.insertBefore(e,t):(r.nodeType===8?(t=r.parentNode,t.insertBefore(e,r)):(t=r,t.appendChild(e)),r=r._reactRootContainer,r!=null||t.onclick!==null||(t.onclick=Tl));else if(n!==4&&(e=e.child,e!==null))for(Wd(e,t,r),e=e.sibling;e!==null;)Wd(e,t,r),e=e.sibling}function Hd(e,t,r){var n=e.tag;if(n===5||n===6)e=e.stateNode,t?r.insertBefore(e,t):r.appendChild(e);else if(n!==4&&(e=e.child,e!==null))for(Hd(e,t,r),e=e.sibling;e!==null;)Hd(e,t,r),e=e.sibling}var qe=null,Yt=!1;function Ur(e,t,r){for(r=r.child;r!==null;)$x(e,t,r),r=r.sibling}function $x(e,t,r){if(pr&&typeof pr.onCommitFiberUnmount=="function")try{pr.onCommitFiberUnmount(Ks,r)}catch{}switch(r.tag){case 5:rt||gi(r,t);case 6:var n=qe,i=Yt;qe=null,Ur(e,t,r),qe=n,Yt=i,qe!==null&&(Yt?(e=qe,r=r.stateNode,e.nodeType===8?e.parentNode.removeChild(r):e.removeChild(r)):qe.removeChild(r.stateNode));break;case 18:qe!==null&&(Yt?(e=qe,r=r.stateNode,e.nodeType===8?pf(e.parentNode,r):e.nodeType===1&&pf(e,r),da(e)):pf(qe,r.stateNode));break;case 4:n=qe,i=Yt,qe=r.stateNode.containerInfo,Yt=!0,Ur(e,t,r),qe=n,Yt=i;break;case 0:case 11:case 14:case 15:if(!rt&&(n=r.updateQueue,n!==null&&(n=n.lastEffect,n!==null))){i=n=n.next;do{var o=i,a=o.destroy;o=o.tag,a!==void 0&&(o&2||o&4)&&Fd(r,t,a),i=i.next}while(i!==n)}Ur(e,t,r);break;case 1:if(!rt&&(gi(r,t),n=r.stateNode,typeof n.componentWillUnmount=="function"))try{n.props=r.memoizedProps,n.state=r.memoizedState,n.componentWillUnmount()}catch(u){Ee(r,t,u)}Ur(e,t,r);break;case 21:Ur(e,t,r);break;case 22:r.mode&1?(rt=(n=rt)||r.memoizedState!==null,Ur(e,t,r),rt=n):Ur(e,t,r);break;default:Ur(e,t,r)}}function wm(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var r=e.stateNode;r===null&&(r=e.stateNode=new aE),t.forEach(function(n){var i=yE.bind(null,e,n);r.has(n)||(r.add(n),n.then(i,i))})}}function Gt(e,t){var r=t.deletions;if(r!==null)for(var n=0;ni&&(i=a),n&=~o}if(n=i,n=Te()-n,n=(120>n?120:480>n?480:1080>n?1080:1920>n?1920:3e3>n?3e3:4320>n?4320:1960*sE(n/1960))-n,10e?16:e,Jr===null)var n=!1;else{if(e=Jr,Jr=null,Wl=0,ae&6)throw Error(z(331));var i=ae;for(ae|=4,K=e.current;K!==null;){var o=K,a=o.child;if(K.flags&16){var u=o.deletions;if(u!==null){for(var l=0;lTe()-tv?Un(e,0):ev|=r),yt(e,t)}function Dx(e,t){t===0&&(e.mode&1?(t=Du,Du<<=1,!(Du&130023424)&&(Du=4194304)):t=1);var r=lt();e=jr(e,t),e!==null&&(cu(e,t,r),yt(e,r))}function vE(e){var t=e.memoizedState,r=0;t!==null&&(r=t.retryLane),Dx(e,r)}function yE(e,t){var r=0;switch(e.tag){case 13:var n=e.stateNode,i=e.memoizedState;i!==null&&(r=i.retryLane);break;case 19:n=e.stateNode;break;default:throw Error(z(314))}n!==null&&n.delete(t),Dx(e,r)}var Rx;Rx=function(e,t,r){if(e!==null)if(e.memoizedProps!==t.pendingProps||ht.current)dt=!0;else{if(!(e.lanes&r)&&!(t.flags&128))return dt=!1,nE(e,t,r);dt=!!(e.flags&131072)}else dt=!1,we&&t.flags&1048576&&zw(t,Il,t.index);switch(t.lanes=0,t.tag){case 2:var n=t.type;vl(e,t),e=t.pendingProps;var i=Mi(t,it.current);Ei(t,r),i=qh(null,t,n,e,i,r);var o=Xh();return t.flags|=1,typeof i=="object"&&i!==null&&typeof i.render=="function"&&i.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,vt(n)?(o=!0,jl(t)):o=!1,t.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,Wh(t),i.updater=Qs,t.stateNode=i,i._reactInternals=t,Id(t,n,e,r),t=Rd(null,t,n,!0,o,r)):(t.tag=0,we&&o&&Dh(t),at(null,t,i,r),t=t.child),t;case 16:n=t.elementType;e:{switch(vl(e,t),e=t.pendingProps,i=n._init,n=i(n._payload),t.type=n,i=t.tag=gE(n),e=Xt(n,e),i){case 0:t=Dd(null,t,n,e,r);break e;case 1:t=vm(null,t,n,e,r);break e;case 11:t=pm(null,t,n,e,r);break e;case 14:t=hm(null,t,n,Xt(n.type,e),r);break e}throw Error(z(306,n,""))}return t;case 0:return n=t.type,i=t.pendingProps,i=t.elementType===n?i:Xt(n,i),Dd(e,t,n,i,r);case 1:return n=t.type,i=t.pendingProps,i=t.elementType===n?i:Xt(n,i),vm(e,t,n,i,r);case 3:e:{if(wx(t),e===null)throw Error(z(387));n=t.pendingProps,o=t.memoizedState,i=o.element,Hw(e,t),Rl(t,n,null,r);var a=t.memoizedState;if(n=a.element,o.isDehydrated)if(o={element:n,isDehydrated:!1,cache:a.cache,pendingSuspenseBoundaries:a.pendingSuspenseBoundaries,transitions:a.transitions},t.updateQueue.baseState=o,t.memoizedState=o,t.flags&256){i=Ri(Error(z(423)),t),t=ym(e,t,n,r,i);break e}else if(n!==i){i=Ri(Error(z(424)),t),t=ym(e,t,n,r,i);break e}else for(Pt=an(t.stateNode.containerInfo.firstChild),At=t,we=!0,Jt=null,r=qw(t,null,n,r),t.child=r;r;)r.flags=r.flags&-3|4096,r=r.sibling;else{if(Ii(),n===i){t=Mr(e,t,r);break e}at(e,t,n,r)}t=t.child}return t;case 5:return Xw(t),e===null&&Cd(t),n=t.type,i=t.pendingProps,o=e!==null?e.memoizedProps:null,a=i.children,Ad(n,i)?a=null:o!==null&&Ad(n,o)&&(t.flags|=32),bx(e,t),at(e,t,a,r),t.child;case 6:return e===null&&Cd(t),null;case 13:return xx(e,t,r);case 4:return Hh(t,t.stateNode.containerInfo),n=t.pendingProps,e===null?t.child=Ni(t,null,n,r):at(e,t,n,r),t.child;case 11:return n=t.type,i=t.pendingProps,i=t.elementType===n?i:Xt(n,i),pm(e,t,n,i,r);case 7:return at(e,t,t.pendingProps,r),t.child;case 8:return at(e,t,t.pendingProps.children,r),t.child;case 12:return at(e,t,t.pendingProps.children,r),t.child;case 10:e:{if(n=t.type._context,i=t.pendingProps,o=t.memoizedProps,a=i.value,he(Nl,n._currentValue),n._currentValue=a,o!==null)if(or(o.value,a)){if(o.children===i.children&&!ht.current){t=Mr(e,t,r);break e}}else for(o=t.child,o!==null&&(o.return=t);o!==null;){var u=o.dependencies;if(u!==null){a=o.child;for(var l=u.firstContext;l!==null;){if(l.context===n){if(o.tag===1){l=Ar(-1,r&-r),l.tag=2;var s=o.updateQueue;if(s!==null){s=s.shared;var f=s.pending;f===null?l.next=l:(l.next=f.next,f.next=l),s.pending=l}}o.lanes|=r,l=o.alternate,l!==null&&(l.lanes|=r),jd(o.return,r,t),u.lanes|=r;break}l=l.next}}else if(o.tag===10)a=o.type===t.type?null:o.child;else if(o.tag===18){if(a=o.return,a===null)throw Error(z(341));a.lanes|=r,u=a.alternate,u!==null&&(u.lanes|=r),jd(a,r,t),a=o.sibling}else a=o.child;if(a!==null)a.return=o;else for(a=o;a!==null;){if(a===t){a=null;break}if(o=a.sibling,o!==null){o.return=a.return,a=o;break}a=a.return}o=a}at(e,t,i.children,r),t=t.child}return t;case 9:return i=t.type,n=t.pendingProps.children,Ei(t,r),i=Wt(i),n=n(i),t.flags|=1,at(e,t,n,r),t.child;case 14:return n=t.type,i=Xt(n,t.pendingProps),i=Xt(n.type,i),hm(e,t,n,i,r);case 15:return mx(e,t,t.type,t.pendingProps,r);case 17:return n=t.type,i=t.pendingProps,i=t.elementType===n?i:Xt(n,i),vl(e,t),t.tag=1,vt(n)?(e=!0,jl(t)):e=!1,Ei(t,r),Vw(t,n,i),Id(t,n,i,r),Rd(null,t,n,!0,e,r);case 19:return Sx(e,t,r);case 22:return gx(e,t,r)}throw Error(z(156,t.tag))};function Lx(e,t){return cw(e,t)}function mE(e,t,r,n){this.tag=e,this.key=r,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=n,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Lt(e,t,r,n){return new mE(e,t,r,n)}function ov(e){return e=e.prototype,!(!e||!e.isReactComponent)}function gE(e){if(typeof e=="function")return ov(e)?1:0;if(e!=null){if(e=e.$$typeof,e===_h)return 11;if(e===Ph)return 14}return 2}function cn(e,t){var r=e.alternate;return r===null?(r=Lt(e.tag,t,e.key,e.mode),r.elementType=e.elementType,r.type=e.type,r.stateNode=e.stateNode,r.alternate=e,e.alternate=r):(r.pendingProps=t,r.type=e.type,r.flags=0,r.subtreeFlags=0,r.deletions=null),r.flags=e.flags&14680064,r.childLanes=e.childLanes,r.lanes=e.lanes,r.child=e.child,r.memoizedProps=e.memoizedProps,r.memoizedState=e.memoizedState,r.updateQueue=e.updateQueue,t=e.dependencies,r.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},r.sibling=e.sibling,r.index=e.index,r.ref=e.ref,r}function gl(e,t,r,n,i,o){var a=2;if(n=e,typeof e=="function")ov(e)&&(a=1);else if(typeof e=="string")a=5;else e:switch(e){case si:return Wn(r.children,i,o,t);case Oh:a=8,i|=8;break;case id:return e=Lt(12,r,t,i|2),e.elementType=id,e.lanes=o,e;case od:return e=Lt(13,r,t,i),e.elementType=od,e.lanes=o,e;case ad:return e=Lt(19,r,t,i),e.elementType=ad,e.lanes=o,e;case Gb:return tc(r,i,o,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Kb:a=10;break e;case Vb:a=9;break e;case _h:a=11;break e;case Ph:a=14;break e;case Gr:a=16,n=null;break e}throw Error(z(130,e==null?e:typeof e,""))}return t=Lt(a,r,t,i),t.elementType=e,t.type=n,t.lanes=o,t}function Wn(e,t,r,n){return e=Lt(7,e,n,t),e.lanes=r,e}function tc(e,t,r,n){return e=Lt(22,e,n,t),e.elementType=Gb,e.lanes=r,e.stateNode={isHidden:!1},e}function xf(e,t,r){return e=Lt(6,e,null,t),e.lanes=r,e}function Sf(e,t,r){return t=Lt(4,e.children!==null?e.children:[],e.key,t),t.lanes=r,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function bE(e,t,r,n,i){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=tf(0),this.expirationTimes=tf(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=tf(0),this.identifierPrefix=n,this.onRecoverableError=i,this.mutableSourceEagerHydrationData=null}function av(e,t,r,n,i,o,a,u,l){return e=new bE(e,t,r,u,l),t===1?(t=1,o===!0&&(t|=8)):t=0,o=Lt(3,null,null,t),e.current=o,o.stateNode=e,o.memoizedState={element:n,isDehydrated:r,cache:null,transitions:null,pendingSuspenseBoundaries:null},Wh(o),e}function wE(e,t,r){var n=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(Ux)}catch(e){console.error(e)}}Ux(),zb.exports=kt;var PE=zb.exports,$m=PE;rd.createRoot=$m.createRoot,rd.hydrateRoot=$m.hydrateRoot;/** + * @remix-run/router v1.12.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 + */function _a(){return _a=Object.assign?Object.assign.bind():function(e){for(var t=1;t"u")throw new Error(t)}function cv(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function EE(){return Math.random().toString(36).substr(2,8)}function Tm(e,t){return{usr:e.state,key:e.key,idx:t}}function Xd(e,t,r,n){return r===void 0&&(r=null),_a({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?uo(t):t,{state:r,key:t&&t.key||n||EE()})}function Vl(e){let{pathname:t="/",search:r="",hash:n=""}=e;return r&&r!=="?"&&(t+=r.charAt(0)==="?"?r:"?"+r),n&&n!=="#"&&(t+=n.charAt(0)==="#"?n:"#"+n),t}function uo(e){let t={};if(e){let r=e.indexOf("#");r>=0&&(t.hash=e.substr(r),e=e.substr(0,r));let n=e.indexOf("?");n>=0&&(t.search=e.substr(n),e=e.substr(0,n)),e&&(t.pathname=e)}return t}function $E(e,t,r,n){n===void 0&&(n={});let{window:i=document.defaultView,v5Compat:o=!1}=n,a=i.history,u=en.Pop,l=null,s=f();s==null&&(s=0,a.replaceState(_a({},a.state,{idx:s}),""));function f(){return(a.state||{idx:null}).idx}function c(){u=en.Pop;let g=f(),m=g==null?null:g-s;s=g,l&&l({action:u,location:v.location,delta:m})}function d(g,m){u=en.Push;let y=Xd(v.location,g,m);r&&r(y,g),s=f()+1;let b=Tm(y,s),S=v.createHref(y);try{a.pushState(b,"",S)}catch(w){if(w instanceof DOMException&&w.name==="DataCloneError")throw w;i.location.assign(S)}o&&l&&l({action:u,location:v.location,delta:1})}function p(g,m){u=en.Replace;let y=Xd(v.location,g,m);r&&r(y,g),s=f();let b=Tm(y,s),S=v.createHref(y);a.replaceState(b,"",S),o&&l&&l({action:u,location:v.location,delta:0})}function h(g){let m=i.location.origin!=="null"?i.location.origin:i.location.href,y=typeof g=="string"?g:Vl(g);return Me(m,"No window.location.(origin|href) available to create URL for href: "+y),new URL(y,m)}let v={get action(){return u},get location(){return e(i,a)},listen(g){if(l)throw new Error("A history only accepts one active listener");return i.addEventListener(km,c),l=g,()=>{i.removeEventListener(km,c),l=null}},createHref(g){return t(i,g)},createURL:h,encodeLocation(g){let m=h(g);return{pathname:m.pathname,search:m.search,hash:m.hash}},push:d,replace:p,go(g){return a.go(g)}};return v}var Cm;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(Cm||(Cm={}));function kE(e,t,r){r===void 0&&(r="/");let n=typeof t=="string"?uo(t):t,i=fv(n.pathname||"/",r);if(i==null)return null;let o=Wx(e);TE(o);let a=null;for(let u=0;a==null&&u{let l={relativePath:u===void 0?o.path||"":u,caseSensitive:o.caseSensitive===!0,childrenIndex:a,route:o};l.relativePath.startsWith("/")&&(Me(l.relativePath.startsWith(n),'Absolute route path "'+l.relativePath+'" nested under path '+('"'+n+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),l.relativePath=l.relativePath.slice(n.length));let s=fn([n,l.relativePath]),f=r.concat(l);o.children&&o.children.length>0&&(Me(o.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+s+'".')),Wx(o.children,t,f,s)),!(o.path==null&&!o.index)&&t.push({path:s,score:RE(s,o.index),routesMeta:f})};return e.forEach((o,a)=>{var u;if(o.path===""||!((u=o.path)!=null&&u.includes("?")))i(o,a);else for(let l of Hx(o.path))i(o,a,l)}),t}function Hx(e){let t=e.split("/");if(t.length===0)return[];let[r,...n]=t,i=r.endsWith("?"),o=r.replace(/\?$/,"");if(n.length===0)return i?[o,""]:[o];let a=Hx(n.join("/")),u=[];return u.push(...a.map(l=>l===""?o:[o,l].join("/"))),i&&u.push(...a),u.map(l=>e.startsWith("/")&&l===""?"/":l)}function TE(e){e.sort((t,r)=>t.score!==r.score?r.score-t.score:LE(t.routesMeta.map(n=>n.childrenIndex),r.routesMeta.map(n=>n.childrenIndex)))}const CE=/^:\w+$/,jE=3,ME=2,IE=1,NE=10,DE=-2,jm=e=>e==="*";function RE(e,t){let r=e.split("/"),n=r.length;return r.some(jm)&&(n+=DE),t&&(n+=ME),r.filter(i=>!jm(i)).reduce((i,o)=>i+(CE.test(o)?jE:o===""?IE:NE),n)}function LE(e,t){return e.length===t.length&&e.slice(0,-1).every((n,i)=>n===t[i])?e[e.length-1]-t[t.length-1]:0}function BE(e,t){let{routesMeta:r}=e,n={},i="/",o=[];for(let a=0;a{let{paramName:d,isOptional:p}=f;if(d==="*"){let v=u[c]||"";a=o.slice(0,o.length-v.length).replace(/(.)\/+$/,"$1")}const h=u[c];return p&&!h?s[d]=void 0:s[d]=WE(h||"",d),s},{}),pathname:o,pathnameBase:a,pattern:e}}function FE(e,t,r){t===void 0&&(t=!1),r===void 0&&(r=!0),cv(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 n=[],i="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:(\w+)(\?)?/g,(a,u,l)=>(n.push({paramName:u,isOptional:l!=null}),l?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(n.push({paramName:"*"}),i+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):r?i+="\\/*$":e!==""&&e!=="/"&&(i+="(?:(?=\\/|$))"),[new RegExp(i,t?void 0:"i"),n]}function UE(e){try{return decodeURI(e)}catch(t){return cv(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+t+").")),e}}function WE(e,t){try{return decodeURIComponent(e)}catch(r){return cv(!1,'The value for the URL param "'+t+'" will not be decoded because'+(' the string "'+e+'" is a malformed URL segment. This is probably')+(" due to a bad percent encoding ("+r+").")),e}}function fv(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let r=t.endsWith("/")?t.length-1:t.length,n=e.charAt(r);return n&&n!=="/"?null:e.slice(r)||"/"}function HE(e,t){t===void 0&&(t="/");let{pathname:r,search:n="",hash:i=""}=typeof e=="string"?uo(e):e;return{pathname:r?r.startsWith("/")?r:KE(r,t):t,search:GE(n),hash:qE(i)}}function KE(e,t){let r=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(i=>{i===".."?r.length>1&&r.pop():i!=="."&&r.push(i)}),r.length>1?r.join("/"):"/"}function Of(e,t,r,n){return"Cannot include a '"+e+"' character in a manually specified "+("`to."+t+"` field ["+JSON.stringify(n)+"]. Please separate it out to the ")+("`to."+r+"` field. Alternatively you may provide the full path as ")+'a string in and the router will parse it for you.'}function Kx(e){return e.filter((t,r)=>r===0||t.route.path&&t.route.path.length>0)}function Vx(e,t,r,n){n===void 0&&(n=!1);let i;typeof e=="string"?i=uo(e):(i=_a({},e),Me(!i.pathname||!i.pathname.includes("?"),Of("?","pathname","search",i)),Me(!i.pathname||!i.pathname.includes("#"),Of("#","pathname","hash",i)),Me(!i.search||!i.search.includes("#"),Of("#","search","hash",i)));let o=e===""||i.pathname==="",a=o?"/":i.pathname,u;if(a==null)u=r;else if(n){let c=t[t.length-1].replace(/^\//,"").split("/");if(a.startsWith("..")){let d=a.split("/");for(;d[0]==="..";)d.shift(),c.pop();i.pathname=d.join("/")}u="/"+c.join("/")}else{let c=t.length-1;if(a.startsWith("..")){let d=a.split("/");for(;d[0]==="..";)d.shift(),c-=1;i.pathname=d.join("/")}u=c>=0?t[c]:"/"}let l=HE(i,u),s=a&&a!=="/"&&a.endsWith("/"),f=(o||a===".")&&r.endsWith("/");return!l.pathname.endsWith("/")&&(s||f)&&(l.pathname+="/"),l}const fn=e=>e.join("/").replace(/\/\/+/g,"/"),VE=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),GE=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,qE=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function XE(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const Gx=["post","put","patch","delete"];new Set(Gx);const YE=["get",...Gx];new Set(YE);/** + * React Router v6.19.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 + */function Gl(){return Gl=Object.assign?Object.assign.bind():function(e){for(var t=1;tl.pathnameBase)),a=T.useRef(!1);return Xx(()=>{a.current=!0}),T.useCallback(function(l,s){if(s===void 0&&(s={}),!a.current)return;if(typeof l=="number"){r.go(l);return}let f=Vx(l,JSON.parse(o),i,s.relative==="path");e==null&&t!=="/"&&(f.pathname=f.pathname==="/"?t:fn([t,f.pathname])),(s.replace?r.replace:r.push)(f,s.state,s)},[t,r,o,i,e])}function Yx(){let{matches:e}=T.useContext(wn),t=e[e.length-1];return t?t.params:{}}function Qx(e,t){let{relative:r}=t===void 0?{}:t,{matches:n}=T.useContext(wn),{pathname:i}=uc(),o=JSON.stringify(Kx(n).map((a,u)=>u===n.length-1?a.pathname:a.pathnameBase));return T.useMemo(()=>Vx(e,JSON.parse(o),i,r==="path"),[e,o,i,r])}function t$(e,t){return r$(e,t)}function r$(e,t,r){hu()||Me(!1);let{navigator:n}=T.useContext(lo),{matches:i}=T.useContext(wn),o=i[i.length-1],a=o?o.params:{};o&&o.pathname;let u=o?o.pathnameBase:"/";o&&o.route;let l=uc(),s;if(t){var f;let v=typeof t=="string"?uo(t):t;u==="/"||(f=v.pathname)!=null&&f.startsWith(u)||Me(!1),s=v}else s=l;let c=s.pathname||"/",d=u==="/"?c:c.slice(u.length)||"/",p=kE(e,{pathname:d}),h=u$(p&&p.map(v=>Object.assign({},v,{params:Object.assign({},a,v.params),pathname:fn([u,n.encodeLocation?n.encodeLocation(v.pathname).pathname:v.pathname]),pathnameBase:v.pathnameBase==="/"?u:fn([u,n.encodeLocation?n.encodeLocation(v.pathnameBase).pathname:v.pathnameBase])})),i,r);return t&&h?T.createElement(ac.Provider,{value:{location:Gl({pathname:"/",search:"",hash:"",state:null,key:"default"},s),navigationType:en.Pop}},h):h}function n$(){let e=f$(),t=XE(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),r=e instanceof Error?e.stack:null,i={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"},o=null;return T.createElement(T.Fragment,null,T.createElement("h2",null,"Unexpected Application Error!"),T.createElement("h3",{style:{fontStyle:"italic"}},t),r?T.createElement("pre",{style:i},r):null,o)}const i$=T.createElement(n$,null);class o$ extends T.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,r){return r.location!==t.location||r.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error||r.error,location:r.location,revalidation:t.revalidation||r.revalidation}}componentDidCatch(t,r){console.error("React Router caught the following error during render",t,r)}render(){return this.state.error?T.createElement(wn.Provider,{value:this.props.routeContext},T.createElement(qx.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function a$(e){let{routeContext:t,match:r,children:n}=e,i=T.useContext(dv);return i&&i.static&&i.staticContext&&(r.route.errorElement||r.route.ErrorBoundary)&&(i.staticContext._deepestRenderedBoundaryId=r.route.id),T.createElement(wn.Provider,{value:t},n)}function u$(e,t,r){var n;if(t===void 0&&(t=[]),r===void 0&&(r=null),e==null){var i;if((i=r)!=null&&i.errors)e=r.matches;else return null}let o=e,a=(n=r)==null?void 0:n.errors;if(a!=null){let u=o.findIndex(l=>l.route.id&&(a==null?void 0:a[l.route.id]));u>=0||Me(!1),o=o.slice(0,Math.min(o.length,u+1))}return o.reduceRight((u,l,s)=>{let f=l.route.id?a==null?void 0:a[l.route.id]:null,c=null;r&&(c=l.route.errorElement||i$);let d=t.concat(o.slice(0,s+1)),p=()=>{let h;return f?h=c:l.route.Component?h=T.createElement(l.route.Component,null):l.route.element?h=l.route.element:h=u,T.createElement(a$,{match:l,routeContext:{outlet:u,matches:d,isDataRoute:r!=null},children:h})};return r&&(l.route.ErrorBoundary||l.route.errorElement||s===0)?T.createElement(o$,{location:r.location,revalidation:r.revalidation,component:c,error:f,children:p(),routeContext:{outlet:null,matches:d,isDataRoute:!0}}):p()},null)}var Zx=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(Zx||{}),ql=function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e}(ql||{});function l$(e){let t=T.useContext(dv);return t||Me(!1),t}function s$(e){let t=T.useContext(QE);return t||Me(!1),t}function c$(e){let t=T.useContext(wn);return t||Me(!1),t}function Jx(e){let t=c$(),r=t.matches[t.matches.length-1];return r.route.id||Me(!1),r.route.id}function f$(){var e;let t=T.useContext(qx),r=s$(ql.UseRouteError),n=Jx(ql.UseRouteError);return t||((e=r.errors)==null?void 0:e[n])}function d$(){let{router:e}=l$(Zx.UseNavigateStable),t=Jx(ql.UseNavigateStable),r=T.useRef(!1);return Xx(()=>{r.current=!0}),T.useCallback(function(i,o){o===void 0&&(o={}),r.current&&(typeof i=="number"?e.navigate(i):e.navigate(i,Gl({fromRouteId:t},o)))},[e,t])}function bl(e){Me(!1)}function p$(e){let{basename:t="/",children:r=null,location:n,navigationType:i=en.Pop,navigator:o,static:a=!1}=e;hu()&&Me(!1);let u=t.replace(/^\/*/,"/"),l=T.useMemo(()=>({basename:u,navigator:o,static:a}),[u,o,a]);typeof n=="string"&&(n=uo(n));let{pathname:s="/",search:f="",hash:c="",state:d=null,key:p="default"}=n,h=T.useMemo(()=>{let v=fv(s,u);return v==null?null:{location:{pathname:v,search:f,hash:c,state:d,key:p},navigationType:i}},[u,s,f,c,d,p,i]);return h==null?null:T.createElement(lo.Provider,{value:l},T.createElement(ac.Provider,{children:r,value:h}))}function h$(e){let{children:t,location:r}=e;return t$(Yd(t),r)}new Promise(()=>{});function Yd(e,t){t===void 0&&(t=[]);let r=[];return T.Children.forEach(e,(n,i)=>{if(!T.isValidElement(n))return;let o=[...t,i];if(n.type===T.Fragment){r.push.apply(r,Yd(n.props.children,o));return}n.type!==bl&&Me(!1),!n.props.index||!n.props.children||Me(!1);let a={id:n.props.id||o.join("-"),caseSensitive:n.props.caseSensitive,element:n.props.element,Component:n.props.Component,index:n.props.index,path:n.props.path,loader:n.props.loader,action:n.props.action,errorElement:n.props.errorElement,ErrorBoundary:n.props.ErrorBoundary,hasErrorBoundary:n.props.ErrorBoundary!=null||n.props.errorElement!=null,shouldRevalidate:n.props.shouldRevalidate,handle:n.props.handle,lazy:n.props.lazy};n.props.children&&(a.children=Yd(n.props.children,o)),r.push(a)}),r}/** + * React Router DOM v6.19.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 + */function Qd(){return Qd=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&(r[i]=e[i]);return r}function y$(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function m$(e,t){return e.button===0&&(!t||t==="_self")&&!y$(e)}const g$=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset","unstable_viewTransition"],b$="startTransition",Mm=vP[b$];function w$(e){let{basename:t,children:r,future:n,window:i}=e,o=T.useRef();o.current==null&&(o.current=AE({window:i,v5Compat:!0}));let a=o.current,[u,l]=T.useState({action:a.action,location:a.location}),{v7_startTransition:s}=n||{},f=T.useCallback(c=>{s&&Mm?Mm(()=>l(c)):l(c)},[l,s]);return T.useLayoutEffect(()=>a.listen(f),[a,f]),T.createElement(p$,{basename:t,children:r,location:u.location,navigationType:u.action,navigator:a})}const x$=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",S$=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,eS=T.forwardRef(function(t,r){let{onClick:n,relative:i,reloadDocument:o,replace:a,state:u,target:l,to:s,preventScrollReset:f,unstable_viewTransition:c}=t,d=v$(t,g$),{basename:p}=T.useContext(lo),h,v=!1;if(typeof s=="string"&&S$.test(s)&&(h=s,x$))try{let b=new URL(window.location.href),S=s.startsWith("//")?new URL(b.protocol+s):new URL(s),w=fv(S.pathname,p);S.origin===b.origin&&w!=null?s=w+S.search+S.hash:v=!0}catch{}let g=ZE(s,{relative:i}),m=O$(s,{replace:a,state:u,target:l,preventScrollReset:f,relative:i,unstable_viewTransition:c});function y(b){n&&n(b),b.defaultPrevented||m(b)}return T.createElement("a",Qd({},d,{href:h||g,onClick:v||o?n:y,ref:r,target:l}))});var Im;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(Im||(Im={}));var Nm;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(Nm||(Nm={}));function O$(e,t){let{target:r,replace:n,state:i,preventScrollReset:o,relative:a,unstable_viewTransition:u}=t===void 0?{}:t,l=JE(),s=uc(),f=Qx(e,{relative:a});return T.useCallback(c=>{if(m$(c,r)){c.preventDefault();let d=n!==void 0?n:Vl(s)===Vl(f);l(e,{replace:d,state:i,preventScrollReset:o,relative:a,unstable_viewTransition:u})}},[s,l,f,n,i,r,e,o,a,u])}const _$="_workouts_1sur4_1",P$={workouts:_$};let Zd;const pv=window.indexedDB.open("myDatabase",1);pv.onerror=function(e){console.log("Erro ao abrir o banco de dados",e)};pv.onsuccess=function(e){Zd=e.target.result};pv.onupgradeneeded=function(e){Zd=e.target.result,Zd.createObjectStore("workouts",{keyPath:"id"})};const dn=()=>new Promise((e,t)=>{const r=window.indexedDB.open("MyWorkoutsDatabase",1);r.onerror=n=>{console.error("Erro ao abrir o banco de dados IndexedDB",n),t(n.target.error)},r.onsuccess=n=>{console.log("Banco de dados IndexedDB aberto com sucesso"),e(n.target.result)},r.onupgradeneeded=n=>{const i=n.target.result;i.objectStoreNames.contains("workouts")||i.createObjectStore("workouts",{keyPath:"id"})}}),A$=e=>{const t={id:Date.now(),programs:[]},i=e.transaction(["workouts"],"readwrite").objectStore("workouts").add(t);i.onsuccess=function(){console.log("Workout adicionado ao banco de dados")},i.onerror=function(o){console.log("Erro ao adicionar workout ao banco de dados",o)}},E$=(e,t)=>{const i=e.transaction(["workouts"],"readwrite").objectStore("workouts").delete(t);i.onsuccess=function(){console.log("Workout removido ao banco de dados")},i.onerror=function(o){console.log("Erro ao remover workout ao banco de dados",o)}},tS=async e=>{const t=await dn();return new Promise((r,n)=>{const a=t.transaction(["workouts"],"readonly").objectStore("workouts").get(e);a.onsuccess=()=>r(a.result),a.onerror=()=>n(a.error)})},$$=async(e,t)=>{const i=(await dn()).transaction(["workouts"],"readwrite").objectStore("workouts"),o=i.get(e);o.onsuccess=()=>{const a=o.result;a&&(a.programs.push(t),i.put(a))},o.onerror=a=>{console.log("Erro ao buscar workout",a.target.error)}},k$=async(e,t)=>{const i=(await dn()).transaction(["workouts"],"readwrite").objectStore("workouts"),o=i.get(e);o.onsuccess=()=>{const a=o.result;if(a){const u=a.programs.filter(l=>l.id!==t);a.programs=u,i.put(a)}},o.onerror=a=>{console.log("Erro ao buscar workout",a.target.error)}},qu=async(e,t)=>{const n=(await dn()).transaction(["workouts"],"readwrite"),i=n.objectStore("workouts"),o=i.get(e);o.onsuccess=()=>{const a=o.result;if(a){const u=a.programs.findIndex(l=>l.id===t.id);u!==-1&&(a.programs[u]=t),i.put(a)}},o.onerror=a=>{console.log("Erro ao buscar workout",a.target.error)},n.oncomplete=()=>{console.log("Programa atualizado com sucesso no IndexedDB.")},n.onerror=a=>{console.log("Erro ao atualizar programa no IndexedDB",a.target.error)}},rS=e=>{const t=new Date(e),r=t.getUTCFullYear(),n=t.getUTCMonth()+1,i=t.getUTCDate(),o=n<10?"0"+n:n.toString(),a=i<10?"0"+i:i.toString();return r+"-"+o+"-"+a},_f=e=>new Promise((t,r)=>{const o=e.transaction(["workouts"],"readonly").objectStore("workouts").getAll();o.onsuccess=()=>t(o.result),o.onerror=()=>r(o.error)}),T$=()=>{const[e,t]=T.useState([]),[r,n]=T.useState(null),i=async()=>{try{const a=await dn();await A$(a);const u=await _f(a);t(u)}catch(a){console.error("Error adding workout",a),n(a)}},o=async a=>{try{const u=await dn();await E$(u,a);const l=await _f(u);t(l)}catch(u){console.error("Error removing workout",u),n(u)}};return T.useEffect(()=>{(async()=>{try{const u=await dn(),l=await _f(u);t(l)}catch(u){n(u)}})()},[]),r?G.jsx("div",{children:"Error loading workouts."}):!e||e.length===0?G.jsxs("div",{children:["No workout found. ",G.jsx("button",{onClick:i,children:"Add Workout"})]}):G.jsxs("div",{children:[G.jsx("button",{onClick:i,children:"Add Workout"}),G.jsx("div",{className:P$.workouts,children:e.slice(0).reverse().map(a=>G.jsxs("div",{children:[G.jsxs(eS,{to:`/workout/${a.id}`,children:["Workout started on ",rS(a.id)]}),G.jsx("button",{onClick:()=>o(a.id),children:"Remove"})]},a.id))})]})},C$="_programs_13s5v_1",j$={programs:C$},M$=async(e,t)=>new Promise((r,n)=>{const a=e.transaction(["workouts"],"readonly").objectStore("workouts").get(t);a.onsuccess=()=>r(a.result),a.onerror=()=>n(a.error)}),I$=({workoutId:e})=>{const[t,r]=T.useState([]),[n,i]=T.useState(null),o=()=>{const l={id:t.reduce((s,f)=>f.id>s?f.id:s,0)+1,exercises:[]};$$(e,l),r([...t,l])},a=u=>{const l=t.filter(s=>s.id!==u);k$(e,u),r(l)};return T.useEffect(()=>{(async()=>{try{const l=await dn(),s=await M$(l,e);s?r(s.programs):console.log("Workout not found")}catch(l){console.log("Error searching for programs",l),i(l)}})()},[]),n?G.jsx("div",{children:"Error loading programs."}):!t||t.length===0?G.jsxs("div",{children:["No program found. ",G.jsx("button",{onClick:o,children:"Add Program"})]}):G.jsxs("div",{children:[G.jsx("button",{onClick:o,children:"Add Program"}),G.jsx("div",{className:j$.programs,children:t.map(u=>G.jsxs("div",{children:[G.jsxs(eS,{to:`/workout/${e}/program/${u.id}`,children:["Program ",u.id]}),G.jsx("button",{onClick:()=>a(u.id),children:"Remove"})]},u.id))})]})},N$=()=>{const[e,t]=T.useState(),{workoutId:r}=Yx();return T.useEffect(()=>{(async()=>{const i=await tS(r);t(i)})()},[r]),e?G.jsxs("div",{children:[G.jsxs("h1",{children:["Workout started on ",rS(e.id)]}),G.jsx(I$,{workoutId:e.id})]}):G.jsx("div",{children:"Loading..."})};function nS(e){var t,r,n="";if(typeof e=="string"||typeof e=="number")n+=e;else if(typeof e=="object")if(Array.isArray(e))for(t=0;t-1}var IT=MT,NT=sc;function DT(e,t){var r=this.__data__,n=NT(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this}var RT=DT,LT=wT,BT=$T,zT=CT,FT=IT,UT=RT;function po(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t0?1:-1},Ln=function(t){return yu(t)&&t.indexOf("%")===t.length-1},U=function(t){return dj(t)&&!mu(t)},Be=function(t){return U(t)||yu(t)},yj=0,gu=function(t){var r=++yj;return"".concat(t||"").concat(r)},Bi=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;if(!U(t)&&!yu(t))return n;var o;if(Ln(t)){var a=t.indexOf("%");o=r*parseFloat(t.slice(0,a))/100}else o=+t;return mu(o)&&(o=n),i&&o>r&&(o=r),o},Hr=function(t){if(!t)return null;var r=Object.keys(t);return r&&r.length?t[r[0]]:null},mj=function(t){if(!Array.isArray(t))return!1;for(var r=t.length,n={},i=0;i=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function Oj(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,o;for(o=0;o=0)&&(r[i]=e[i]);return r}function tp(e){"@babel/helpers - typeof";return tp=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},tp(e)}var Gm={click:"onClick",mousedown:"onMouseDown",mouseup:"onMouseUp",mouseover:"onMouseOver",mousemove:"onMouseMove",mouseout:"onMouseOut",mouseenter:"onMouseEnter",mouseleave:"onMouseLeave",touchcancel:"onTouchCancel",touchend:"onTouchEnd",touchmove:"onTouchMove",touchstart:"onTouchStart"},Er=function(t){return typeof t=="string"?t:t?t.displayName||t.name||"Component":""},qm=null,Ef=null,Av=function e(t){if(t===qm&&Array.isArray(Ef))return Ef;var r=[];return T.Children.forEach(t,function(n){ie(n)||(Jd.isFragment(n)?r=r.concat(e(n.props.children)):r.push(n))}),Ef=r,qm=t,r};function Ut(e,t){var r=[],n=[];return Array.isArray(t)?n=t.map(function(i){return Er(i)}):n=[Er(t)],Av(e).forEach(function(i){var o=Ft(i,"type.displayName")||Ft(i,"type.name");n.indexOf(o)!==-1&&r.push(i)}),r}function Or(e,t){var r=Ut(e,t);return r&&r[0]}var Xm=function(t){if(!t||!t.props)return!1;var r=t.props,n=r.width,i=r.height;return!(!U(n)||n<=0||!U(i)||i<=0)},_j=["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"],Pj=function(t){return t&&t.type&&yu(t.type)&&_j.indexOf(t.type)>=0},Aj=function(t){return t&&tp(t)==="object"&&"cx"in t&&"cy"in t&&"r"in t},Ej=function(t,r,n,i){var o,a=(o=Af==null?void 0:Af[i])!==null&&o!==void 0?o:[];return!te(t)&&(i&&a.includes(r)||bj.includes(r))||n&&Pv.includes(r)},ne=function(t,r,n){if(!t||typeof t=="function"||typeof t=="boolean")return null;var i=t;if(T.isValidElement(t)&&(i=t.props),!co(i))return null;var o={};return Object.keys(i).forEach(function(a){var u;Ej((u=i)===null||u===void 0?void 0:u[a],a,r,n)&&(o[a]=i[a])}),o},vS=function e(t,r){if(t===r)return!0;var n=T.Children.count(t);if(n!==T.Children.count(r))return!1;if(n===0)return!0;if(n===1)return Ym(Array.isArray(t)?t[0]:t,Array.isArray(r)?r[0]:r);for(var i=0;i=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function jj(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,o;for(o=0;o=0)&&(r[i]=e[i]);return r}function np(e){var t=e.children,r=e.width,n=e.height,i=e.viewBox,o=e.className,a=e.style,u=e.title,l=e.desc,s=Cj(e,Tj),f=i||{width:r,height:n,x:0,y:0},c=se("recharts-surface",o);return $.createElement("svg",rp({},ne(s,!0,"svg"),{className:c,width:r,height:n,style:a,viewBox:"".concat(f.x," ").concat(f.y," ").concat(f.width," ").concat(f.height)}),$.createElement("title",null,u),$.createElement("desc",null,l),t)}var Mj=["children","className"];function ip(){return ip=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function Nj(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,o;for(o=0;o=0)&&(r[i]=e[i]);return r}var Ce=$.forwardRef(function(e,t){var r=e.children,n=e.className,i=Ij(e,Mj),o=se("recharts-layer",n);return $.createElement("g",ip({className:o},ne(i,!0),{ref:t}),r)}),Hn=function(t,r){for(var n=arguments.length,i=new Array(n>2?n-2:0),o=2;oi?0:i+t),r=r>i?i:r,r<0&&(r+=i),i=t>r?0:r-t>>>0,t>>>=0;for(var o=Array(i);++n=n?e:Lj(e,t,r)}var zj=Bj,Fj="\\ud800-\\udfff",Uj="\\u0300-\\u036f",Wj="\\ufe20-\\ufe2f",Hj="\\u20d0-\\u20ff",Kj=Uj+Wj+Hj,Vj="\\ufe0e\\ufe0f",Gj="\\u200d",qj=RegExp("["+Gj+Fj+Kj+Vj+"]");function Xj(e){return qj.test(e)}var yS=Xj;function Yj(e){return e.split("")}var Qj=Yj,mS="\\ud800-\\udfff",Zj="\\u0300-\\u036f",Jj="\\ufe20-\\ufe2f",e2="\\u20d0-\\u20ff",t2=Zj+Jj+e2,r2="\\ufe0e\\ufe0f",n2="["+mS+"]",op="["+t2+"]",ap="\\ud83c[\\udffb-\\udfff]",i2="(?:"+op+"|"+ap+")",gS="[^"+mS+"]",bS="(?:\\ud83c[\\udde6-\\uddff]){2}",wS="[\\ud800-\\udbff][\\udc00-\\udfff]",o2="\\u200d",xS=i2+"?",SS="["+r2+"]?",a2="(?:"+o2+"(?:"+[gS,bS,wS].join("|")+")"+SS+xS+")*",u2=SS+xS+a2,l2="(?:"+[gS+op+"?",op,bS,wS,n2].join("|")+")",s2=RegExp(ap+"(?="+ap+")|"+l2+u2,"g");function c2(e){return e.match(s2)||[]}var f2=c2,d2=Qj,p2=yS,h2=f2;function v2(e){return p2(e)?h2(e):d2(e)}var y2=v2,m2=zj,g2=yS,b2=y2,w2=sS;function x2(e){return function(t){t=w2(t);var r=g2(t)?b2(t):void 0,n=r?r[0]:t.charAt(0),i=r?m2(r,1).join(""):t.slice(1);return n[e]()+i}}var S2=x2,O2=S2,_2=O2("toUpperCase"),P2=_2;const Oc=ve(P2);function pe(e){return function(){return e}}const OS=Math.cos,Zl=Math.sin,ar=Math.sqrt,Jl=Math.PI,_c=2*Jl,up=Math.PI,lp=2*up,jn=1e-6,A2=lp-jn;function _S(e){this._+=e[0];for(let t=1,r=e.length;t=0))throw new Error(`invalid digits: ${e}`);if(t>15)return _S;const r=10**t;return function(n){this._+=n[0];for(let i=1,o=n.length;ijn)if(!(Math.abs(c*l-s*f)>jn)||!o)this._append`L${this._x1=t},${this._y1=r}`;else{let p=n-a,h=i-u,v=l*l+s*s,g=p*p+h*h,m=Math.sqrt(v),y=Math.sqrt(d),b=o*Math.tan((up-Math.acos((v+d-g)/(2*m*y)))/2),S=b/y,w=b/m;Math.abs(S-1)>jn&&this._append`L${t+S*f},${r+S*c}`,this._append`A${o},${o},0,0,${+(c*p>f*h)},${this._x1=t+w*l},${this._y1=r+w*s}`}}arc(t,r,n,i,o,a){if(t=+t,r=+r,n=+n,a=!!a,n<0)throw new Error(`negative radius: ${n}`);let u=n*Math.cos(i),l=n*Math.sin(i),s=t+u,f=r+l,c=1^a,d=a?i-o:o-i;this._x1===null?this._append`M${s},${f}`:(Math.abs(this._x1-s)>jn||Math.abs(this._y1-f)>jn)&&this._append`L${s},${f}`,n&&(d<0&&(d=d%lp+lp),d>A2?this._append`A${n},${n},0,1,${c},${t-u},${r-l}A${n},${n},0,1,${c},${this._x1=s},${this._y1=f}`:d>jn&&this._append`A${n},${n},0,${+(d>=up)},${c},${this._x1=t+n*Math.cos(o)},${this._y1=r+n*Math.sin(o)}`)}rect(t,r,n,i){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+r}h${n=+n}v${+i}h${-n}Z`}toString(){return this._}}function Ev(e){let t=3;return e.digits=function(r){if(!arguments.length)return t;if(r==null)t=null;else{const n=Math.floor(r);if(!(n>=0))throw new RangeError(`invalid digits: ${r}`);t=n}return e},()=>new $2(t)}function $v(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function PS(e){this._context=e}PS.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 Pc(e){return new PS(e)}function AS(e){return e[0]}function ES(e){return e[1]}function $S(e,t){var r=pe(!0),n=null,i=Pc,o=null,a=Ev(u);e=typeof e=="function"?e:e===void 0?AS:pe(e),t=typeof t=="function"?t:t===void 0?ES:pe(t);function u(l){var s,f=(l=$v(l)).length,c,d=!1,p;for(n==null&&(o=i(p=a())),s=0;s<=f;++s)!(s=p;--h)u.point(b[h],S[h]);u.lineEnd(),u.areaEnd()}m&&(b[d]=+e(g,d,c),S[d]=+t(g,d,c),u.point(n?+n(g,d,c):b[d],r?+r(g,d,c):S[d]))}if(y)return u=null,y+""||null}function f(){return $S().defined(i).curve(a).context(o)}return s.x=function(c){return arguments.length?(e=typeof c=="function"?c:pe(+c),n=null,s):e},s.x0=function(c){return arguments.length?(e=typeof c=="function"?c:pe(+c),s):e},s.x1=function(c){return arguments.length?(n=c==null?null:typeof c=="function"?c:pe(+c),s):n},s.y=function(c){return arguments.length?(t=typeof c=="function"?c:pe(+c),r=null,s):t},s.y0=function(c){return arguments.length?(t=typeof c=="function"?c:pe(+c),s):t},s.y1=function(c){return arguments.length?(r=c==null?null:typeof c=="function"?c:pe(+c),s):r},s.lineX0=s.lineY0=function(){return f().x(e).y(t)},s.lineY1=function(){return f().x(e).y(r)},s.lineX1=function(){return f().x(n).y(t)},s.defined=function(c){return arguments.length?(i=typeof c=="function"?c:pe(!!c),s):i},s.curve=function(c){return arguments.length?(a=c,o!=null&&(u=a(o)),s):a},s.context=function(c){return arguments.length?(c==null?o=u=null:u=a(o=c),s):o},s}class kS{constructor(t,r){this._context=t,this._x=r}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,r){switch(t=+t,r=+r,this._point){case 0:{this._point=1,this._line?this._context.lineTo(t,r):this._context.moveTo(t,r);break}case 1:this._point=2;default:{this._x?this._context.bezierCurveTo(this._x0=(this._x0+t)/2,this._y0,this._x0,r,t,r):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+r)/2,t,this._y0,t,r);break}}this._x0=t,this._y0=r}}function k2(e){return new kS(e,!0)}function T2(e){return new kS(e,!1)}const kv={draw(e,t){const r=ar(t/Jl);e.moveTo(r,0),e.arc(0,0,r,0,_c)}},C2={draw(e,t){const r=ar(t/5)/2;e.moveTo(-3*r,-r),e.lineTo(-r,-r),e.lineTo(-r,-3*r),e.lineTo(r,-3*r),e.lineTo(r,-r),e.lineTo(3*r,-r),e.lineTo(3*r,r),e.lineTo(r,r),e.lineTo(r,3*r),e.lineTo(-r,3*r),e.lineTo(-r,r),e.lineTo(-3*r,r),e.closePath()}},TS=ar(1/3),j2=TS*2,M2={draw(e,t){const r=ar(t/j2),n=r*TS;e.moveTo(0,-r),e.lineTo(n,0),e.lineTo(0,r),e.lineTo(-n,0),e.closePath()}},I2={draw(e,t){const r=ar(t),n=-r/2;e.rect(n,n,r,r)}},N2=.8908130915292852,CS=Zl(Jl/10)/Zl(7*Jl/10),D2=Zl(_c/10)*CS,R2=-OS(_c/10)*CS,L2={draw(e,t){const r=ar(t*N2),n=D2*r,i=R2*r;e.moveTo(0,-r),e.lineTo(n,i);for(let o=1;o<5;++o){const a=_c*o/5,u=OS(a),l=Zl(a);e.lineTo(l*r,-u*r),e.lineTo(u*n-l*i,l*n+u*i)}e.closePath()}},$f=ar(3),B2={draw(e,t){const r=-ar(t/($f*3));e.moveTo(0,r*2),e.lineTo(-$f*r,-r),e.lineTo($f*r,-r),e.closePath()}},jt=-.5,Mt=ar(3)/2,sp=1/ar(12),z2=(sp/2+1)*3,F2={draw(e,t){const r=ar(t/z2),n=r/2,i=r*sp,o=n,a=r*sp+r,u=-o,l=a;e.moveTo(n,i),e.lineTo(o,a),e.lineTo(u,l),e.lineTo(jt*n-Mt*i,Mt*n+jt*i),e.lineTo(jt*o-Mt*a,Mt*o+jt*a),e.lineTo(jt*u-Mt*l,Mt*u+jt*l),e.lineTo(jt*n+Mt*i,jt*i-Mt*n),e.lineTo(jt*o+Mt*a,jt*a-Mt*o),e.lineTo(jt*u+Mt*l,jt*l-Mt*u),e.closePath()}};function U2(e,t){let r=null,n=Ev(i);e=typeof e=="function"?e:pe(e||kv),t=typeof t=="function"?t:pe(t===void 0?64:+t);function i(){let o;if(r||(r=o=n()),e.apply(this,arguments).draw(r,+t.apply(this,arguments)),o)return r=null,o+""||null}return i.type=function(o){return arguments.length?(e=typeof o=="function"?o:pe(o),i):e},i.size=function(o){return arguments.length?(t=typeof o=="function"?o:pe(+o),i):t},i.context=function(o){return arguments.length?(r=o??null,i):r},i}function es(){}function ts(e,t,r){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+r)/6)}function jS(e){this._context=e}jS.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:ts(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:ts(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function W2(e){return new jS(e)}function MS(e){this._context=e}MS.prototype={areaStart:es,areaEnd:es,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:ts(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function H2(e){return new MS(e)}function IS(e){this._context=e}IS.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 r=(this._x0+4*this._x1+e)/6,n=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(r,n):this._context.moveTo(r,n);break;case 3:this._point=4;default:ts(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function K2(e){return new IS(e)}function NS(e){this._context=e}NS.prototype={areaStart:es,areaEnd:es,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 V2(e){return new NS(e)}function Zm(e){return e<0?-1:1}function Jm(e,t,r){var n=e._x1-e._x0,i=t-e._x1,o=(e._y1-e._y0)/(n||i<0&&-0),a=(r-e._y1)/(i||n<0&&-0),u=(o*i+a*n)/(n+i);return(Zm(o)+Zm(a))*Math.min(Math.abs(o),Math.abs(a),.5*Math.abs(u))||0}function eg(e,t){var r=e._x1-e._x0;return r?(3*(e._y1-e._y0)/r-t)/2:t}function kf(e,t,r){var n=e._x0,i=e._y0,o=e._x1,a=e._y1,u=(o-n)/3;e._context.bezierCurveTo(n+u,i+u*t,o-u,a-u*r,o,a)}function rs(e){this._context=e}rs.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:kf(this,this._t0,eg(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 r=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,kf(this,eg(this,r=Jm(this,e,t)),r);break;default:kf(this,this._t0,r=Jm(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=r}}};function DS(e){this._context=new RS(e)}(DS.prototype=Object.create(rs.prototype)).point=function(e,t){rs.prototype.point.call(this,t,e)};function RS(e){this._context=e}RS.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,r,n,i,o){this._context.bezierCurveTo(t,e,n,r,o,i)}};function G2(e){return new rs(e)}function q2(e){return new DS(e)}function LS(e){this._context=e}LS.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,r=e.length;if(r)if(this._line?this._context.lineTo(e[0],t[0]):this._context.moveTo(e[0],t[0]),r===2)this._context.lineTo(e[1],t[1]);else for(var n=tg(e),i=tg(t),o=0,a=1;a=0;--t)i[t]=(a[t]-i[t+1])/o[t];for(o[r-1]=(e[r]+i[r-1])/2,t=0;t=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 r=this._x*(1-this._t)+e*this._t;this._context.lineTo(r,this._y),this._context.lineTo(r,t)}break}}this._x=e,this._y=t}};function Y2(e){return new Ac(e,.5)}function Q2(e){return new Ac(e,0)}function Z2(e){return new Ac(e,1)}function zi(e,t){if((a=e.length)>1)for(var r=1,n,i,o=e[t[0]],a,u=o.length;r=0;)r[t]=t;return r}function J2(e,t){return e[t]}function eM(e){const t=[];return t.key=e,t}function tM(){var e=pe([]),t=cp,r=zi,n=J2;function i(o){var a=Array.from(e.apply(this,arguments),eM),u,l=a.length,s=-1,f;for(const c of o)for(u=0,++s;u0){for(var r,n,i=0,o=e[0].length,a;i0){for(var r=0,n=e[t[0]],i,o=n.length;r0)||!((o=(i=e[t[0]]).length)>0))){for(var r=0,n=1,i,o,a;n=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function cM(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,o;for(o=0;o=0)&&(r[i]=e[i]);return r}var BS={symbolCircle:kv,symbolCross:C2,symbolDiamond:M2,symbolSquare:I2,symbolStar:L2,symbolTriangle:B2,symbolWye:F2},fM=Math.PI/180,dM=function(t){var r="symbol".concat(Oc(t));return BS[r]||kv},pM=function(t,r,n){if(r==="area")return t;switch(n){case"cross":return 5*t*t/9;case"diamond":return .5*t*t/Math.sqrt(3);case"square":return t*t;case"star":{var i=18*fM;return 1.25*t*t*(Math.tan(i)-Math.tan(i*2)*Math.pow(Math.tan(i),2))}case"triangle":return Math.sqrt(3)*t*t/4;case"wye":return(21-10*Math.sqrt(3))*t*t/8;default:return Math.PI*t*t/4}},hM=function(t,r){BS["symbol".concat(Oc(t))]=r},Tv=function(t){var r=t.type,n=r===void 0?"circle":r,i=t.size,o=i===void 0?64:i,a=t.sizeType,u=a===void 0?"area":a,l=sM(t,oM),s=ng(ng({},l),{},{type:n,size:o,sizeType:u}),f=function(){var g=dM(n),m=U2().type(g).size(pM(o,u,n));return m()},c=s.className,d=s.cx,p=s.cy,h=ne(s,!0);return d===+d&&p===+p&&o===+o?$.createElement("path",fp({},h,{className:se("recharts-symbols",c),transform:"translate(".concat(d,", ").concat(p,")"),d:f()})):null};Tv.registerSymbol=hM;function Fi(e){"@babel/helpers - typeof";return Fi=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},Fi(e)}function dp(){return dp=Object.assign?Object.assign.bind():function(e){for(var t=1;t"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 ns(e){return ns=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},ns(e)}function Aa(e,t,r){return t=zS(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function zS(e){var t=OM(e,"string");return Fi(t)==="symbol"?t:String(t)}function OM(e,t){if(Fi(e)!=="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Fi(n)!=="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var It=32,Cv=function(e){gM(r,e);var t=bM(r);function r(){return yM(this,r),t.apply(this,arguments)}return mM(r,[{key:"renderIcon",value:function(i){var o=this.props.inactiveColor,a=It/2,u=It/6,l=It/3,s=i.inactive?o:i.color;if(i.type==="plainline")return $.createElement("line",{strokeWidth:4,fill:"none",stroke:s,strokeDasharray:i.payload.strokeDasharray,x1:0,y1:a,x2:It,y2:a,className:"recharts-legend-icon"});if(i.type==="line")return $.createElement("path",{strokeWidth:4,fill:"none",stroke:s,d:"M0,".concat(a,"h").concat(l,` + A`).concat(u,",").concat(u,",0,1,1,").concat(2*l,",").concat(a,` + H`).concat(It,"M").concat(2*l,",").concat(a,` + A`).concat(u,",").concat(u,",0,1,1,").concat(l,",").concat(a),className:"recharts-legend-icon"});if(i.type==="rect")return $.createElement("path",{stroke:"none",fill:s,d:"M0,".concat(It/8,"h").concat(It,"v").concat(It*3/4,"h").concat(-It,"z"),className:"recharts-legend-icon"});if($.isValidElement(i.legendIcon)){var f=vM({},i);return delete f.legendIcon,$.cloneElement(i.legendIcon,f)}return $.createElement(Tv,{fill:s,cx:a,cy:a,size:It,sizeType:"diameter",type:i.type})}},{key:"renderItems",value:function(){var i=this,o=this.props,a=o.payload,u=o.iconSize,l=o.layout,s=o.formatter,f=o.inactiveColor,c={x:0,y:0,width:It,height:It},d={display:l==="horizontal"?"inline-block":"block",marginRight:10},p={display:"inline-block",verticalAlign:"middle",marginRight:4};return a.map(function(h,v){var g,m=h.formatter||s,y=se((g={"recharts-legend-item":!0},Aa(g,"legend-item-".concat(v),!0),Aa(g,"inactive",h.inactive),g));if(h.type==="none")return null;var b=te(h.value)?null:h.value;Hn(!te(h.value),`The name property is also required when using a function for the dataKey of a chart's cartesian components. Ex: `);var S=h.inactive?f:h.color;return $.createElement("li",dp({className:y,style:d,key:"legend-item-".concat(v)},Ql(i.props,h,v)),$.createElement(np,{width:u,height:u,viewBox:c,style:p},i.renderIcon(h)),$.createElement("span",{className:"recharts-legend-item-text",style:{color:S}},m?m(b,h,v):b))})}},{key:"render",value:function(){var i=this.props,o=i.payload,a=i.layout,u=i.align;if(!o||!o.length)return null;var l={padding:0,margin:0,textAlign:a==="horizontal"?u:"left"};return $.createElement("ul",{className:"recharts-default-legend",style:l},this.renderItems())}}]),r}(T.PureComponent);Aa(Cv,"displayName","Legend");Aa(Cv,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"middle",inactiveColor:"#ccc"});var _M=cc;function PM(){this.__data__=new _M,this.size=0}var AM=PM;function EM(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}var $M=EM;function kM(e){return this.__data__.get(e)}var TM=kM;function CM(e){return this.__data__.has(e)}var jM=CM,MM=cc,IM=mv,NM=gv,DM=200;function RM(e,t){var r=this.__data__;if(r instanceof MM){var n=r.__data__;if(!IM||n.lengthu))return!1;var s=o.get(e),f=o.get(t);if(s&&f)return s==t&&f==e;var c=-1,d=!0,p=r&oI?new tI:void 0;for(o.set(e,t),o.set(t,e);++c-1&&e%1==0&&e-1&&e%1==0&&e<=sN}var Nv=cN,fN=Br,dN=Nv,pN=zr,hN="[object Arguments]",vN="[object Array]",yN="[object Boolean]",mN="[object Date]",gN="[object Error]",bN="[object Function]",wN="[object Map]",xN="[object Number]",SN="[object Object]",ON="[object RegExp]",_N="[object Set]",PN="[object String]",AN="[object WeakMap]",EN="[object ArrayBuffer]",$N="[object DataView]",kN="[object Float32Array]",TN="[object Float64Array]",CN="[object Int8Array]",jN="[object Int16Array]",MN="[object Int32Array]",IN="[object Uint8Array]",NN="[object Uint8ClampedArray]",DN="[object Uint16Array]",RN="[object Uint32Array]",me={};me[kN]=me[TN]=me[CN]=me[jN]=me[MN]=me[IN]=me[NN]=me[DN]=me[RN]=!0;me[hN]=me[vN]=me[EN]=me[yN]=me[$N]=me[mN]=me[gN]=me[bN]=me[wN]=me[xN]=me[SN]=me[ON]=me[_N]=me[PN]=me[AN]=!1;function LN(e){return pN(e)&&dN(e.length)&&!!me[fN(e)]}var BN=LN;function zN(e){return function(t){return e(t)}}var XS=zN,as={exports:{}};as.exports;(function(e,t){var r=iS,n=t&&!t.nodeType&&t,i=n&&!0&&e&&!e.nodeType&&e,o=i&&i.exports===n,a=o&&r.process,u=function(){try{var l=i&&i.require&&i.require("util").types;return l||a&&a.binding&&a.binding("util")}catch{}}();e.exports=u})(as,as.exports);var FN=as.exports,UN=BN,WN=XS,fg=FN,dg=fg&&fg.isTypedArray,HN=dg?WN(dg):UN,YS=HN,KN=qI,VN=Mv,GN=mt,qN=qS,XN=Iv,YN=YS,QN=Object.prototype,ZN=QN.hasOwnProperty;function JN(e,t){var r=GN(e),n=!r&&VN(e),i=!r&&!n&&qN(e),o=!r&&!n&&!i&&YN(e),a=r||n||i||o,u=a?KN(e.length,String):[],l=u.length;for(var s in e)(t||ZN.call(e,s))&&!(a&&(s=="length"||i&&(s=="offset"||s=="parent")||o&&(s=="buffer"||s=="byteLength"||s=="byteOffset")||XN(s,l)))&&u.push(s);return u}var eD=JN,tD=Object.prototype;function rD(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||tD;return e===r}var nD=rD;function iD(e,t){return function(r){return e(t(r))}}var QS=iD,oD=QS,aD=oD(Object.keys,Object),uD=aD,lD=nD,sD=uD,cD=Object.prototype,fD=cD.hasOwnProperty;function dD(e){if(!lD(e))return sD(e);var t=[];for(var r in Object(e))fD.call(e,r)&&r!="constructor"&&t.push(r);return t}var pD=dD,hD=vv,vD=Nv;function yD(e){return e!=null&&vD(e.length)&&!hD(e)}var bu=yD,mD=eD,gD=pD,bD=bu;function wD(e){return bD(e)?mD(e):gD(e)}var Ec=wD,xD=DI,SD=VI,OD=Ec;function _D(e){return xD(e,OD,SD)}var PD=_D,pg=PD,AD=1,ED=Object.prototype,$D=ED.hasOwnProperty;function kD(e,t,r,n,i,o){var a=r&AD,u=pg(e),l=u.length,s=pg(t),f=s.length;if(l!=f&&!a)return!1;for(var c=l;c--;){var d=u[c];if(!(a?d in t:$D.call(t,d)))return!1}var p=o.get(e),h=o.get(t);if(p&&h)return p==t&&h==e;var v=!0;o.set(e,t),o.set(t,e);for(var g=a;++c-1}var EL=AL;function $L(e,t,r){for(var n=-1,i=e==null?0:e.length;++n=WL){var s=t?null:FL(e);if(s)return UL(s);a=!1,i=zL,l=new RL}else l=t?[]:u;e:for(;++n"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 us(e){return us=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},us(e)}function $c(e,t,r){return t=aO(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function aO(e){var t=n3(e,"string");return Ui(t)==="symbol"?t:String(t)}function n3(e,t){if(Ui(e)!=="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Ui(n)!=="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function i3(e,t){if(e==null)return{};var r=o3(e,t),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function o3(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,o;for(o=0;o=0)&&(r[i]=e[i]);return r}function a3(e){return e.value}function u3(e,t){if($.isValidElement(e))return $.cloneElement(e,t);if(typeof e=="function")return $.createElement(e,t);t.ref;var r=i3(t,YL);return $.createElement(Cv,r)}var kg=1,Wi=function(e){JL(r,e);var t=e3(r);function r(){var n;QL(this,r);for(var i=arguments.length,o=new Array(i),a=0;akg||Math.abs(o.height-this.lastBoundingBox.height)>kg)&&(this.lastBoundingBox.width=o.width,this.lastBoundingBox.height=o.height,i&&i(o))}else(this.lastBoundingBox.width!==-1||this.lastBoundingBox.height!==-1)&&(this.lastBoundingBox.width=-1,this.lastBoundingBox.height=-1,i&&i(null))}},{key:"getBBoxSnapshot",value:function(){return this.lastBoundingBox.width>=0&&this.lastBoundingBox.height>=0?kn({},this.lastBoundingBox):{width:0,height:0}}},{key:"getDefaultPosition",value:function(i){var o=this.props,a=o.layout,u=o.align,l=o.verticalAlign,s=o.margin,f=o.chartWidth,c=o.chartHeight,d,p;if(!i||(i.left===void 0||i.left===null)&&(i.right===void 0||i.right===null))if(u==="center"&&a==="vertical"){var h=this.getBBoxSnapshot();d={left:((f||0)-h.width)/2}}else d=u==="right"?{right:s&&s.right||0}:{left:s&&s.left||0};if(!i||(i.top===void 0||i.top===null)&&(i.bottom===void 0||i.bottom===null))if(l==="middle"){var v=this.getBBoxSnapshot();p={top:((c||0)-v.height)/2}}else p=l==="bottom"?{bottom:s&&s.bottom||0}:{top:s&&s.top||0};return kn(kn({},d),p)}},{key:"render",value:function(){var i=this,o=this.props,a=o.content,u=o.width,l=o.height,s=o.wrapperStyle,f=o.payloadUniqBy,c=o.payload,d=kn(kn({position:"absolute",width:u||"auto",height:l||"auto"},this.getDefaultPosition(s)),s);return $.createElement("div",{className:"recharts-legend-wrapper",style:d,ref:function(h){i.wrapperNode=h}},u3(a,kn(kn({},this.props),{},{payload:iO(c,f,a3)})))}}],[{key:"getWithHeight",value:function(i,o){var a=i.props.layout;return a==="vertical"&&U(i.props.height)?{height:i.props.height}:a==="horizontal"?{width:i.props.width||o}:null}}]),r}(T.PureComponent);$c(Wi,"displayName","Legend");$c(Wi,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"bottom"});var Tg=vu,l3=Mv,s3=mt,Cg=Tg?Tg.isConcatSpreadable:void 0;function c3(e){return s3(e)||l3(e)||!!(Cg&&e&&e[Cg])}var f3=c3,d3=VS,p3=f3;function uO(e,t,r,n,i){var o=-1,a=e.length;for(r||(r=p3),i||(i=[]);++o0&&r(u)?t>1?uO(u,t-1,r,n,i):d3(i,u):n||(i[i.length]=u)}return i}var lO=uO;function h3(e){return function(t,r,n){for(var i=-1,o=Object(t),a=n(t),u=a.length;u--;){var l=a[e?u:++i];if(r(o[l],l,o)===!1)break}return t}}var v3=h3,y3=v3,m3=y3(),g3=m3,b3=g3,w3=Ec;function x3(e,t){return e&&b3(e,t,w3)}var sO=x3,S3=bu;function O3(e,t){return function(r,n){if(r==null)return r;if(!S3(r))return e(r,n);for(var i=r.length,o=t?i:-1,a=Object(r);(t?o--:++ot||o&&a&&l&&!u&&!s||n&&a&&l||!r&&l||!i)return 1;if(!n&&!o&&!s&&e=u)return l;var s=r[n];return l*(s=="desc"?-1:1)}}return e.index-t.index}var R3=D3,Mf=wv,L3=xv,B3=Sn,z3=cO,F3=j3,U3=XS,W3=R3,H3=mo,K3=mt;function V3(e,t,r){t.length?t=Mf(t,function(o){return K3(o)?function(a){return L3(a,o.length===1?o[0]:o)}:o}):t=[H3];var n=-1;t=Mf(t,U3(B3));var i=z3(e,function(o,a,u){var l=Mf(t,function(s){return s(o)});return{criteria:l,index:++n,value:o}});return F3(i,function(o,a){return W3(o,a,r)})}var G3=V3;function q3(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}var X3=q3,Y3=X3,Mg=Math.max;function Q3(e,t,r){return t=Mg(t===void 0?e.length-1:t,0),function(){for(var n=arguments,i=-1,o=Mg(n.length-t,0),a=Array(o);++i0){if(++t>=uB)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}var fB=cB,dB=aB,pB=fB,hB=pB(dB),vB=hB,yB=mo,mB=Z3,gB=vB;function bB(e,t){return gB(mB(e,t,yB),e+"")}var wB=bB,xB=yv,SB=bu,OB=Iv,_B=xn;function PB(e,t,r){if(!_B(r))return!1;var n=typeof t;return(n=="number"?SB(r)&&OB(t,r.length):n=="string"&&t in r)?xB(r[t],e):!1}var kc=PB,AB=lO,EB=G3,$B=wB,Ng=kc,kB=$B(function(e,t){if(e==null)return[];var r=t.length;return r>1&&Ng(e,t[0],t[1])?t=[]:r>2&&Ng(t[0],t[1],t[2])&&(t=[t[0]]),EB(e,AB(t,1),[])}),TB=kB;const Lv=ve(TB);function Ea(e){"@babel/helpers - typeof";return Ea=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},Ea(e)}function CB(e,t){return NB(e)||IB(e,t)||MB(e,t)||jB()}function jB(){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 MB(e,t){if(e){if(typeof e=="string")return Dg(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Dg(e,t)}}function Dg(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r0;)if(!r.equals(e[n],t[n],n,n,e,t,r))return!1;return!0}function YB(e,t){return go(e.getTime(),t.getTime())}function Ug(e,t,r){if(e.size!==t.size)return!1;for(var n={},i=e.entries(),o=0,a,u;(a=i.next())&&!a.done;){for(var l=t.entries(),s=!1,f=0;(u=l.next())&&!u.done;){var c=a.value,d=c[0],p=c[1],h=u.value,v=h[0],g=h[1];!s&&!n[f]&&(s=r.equals(d,v,o,f,e,t,r)&&r.equals(p,g,d,v,e,t,r))&&(n[f]=!0),f++}if(!s)return!1;o++}return!0}function QB(e,t,r){var n=Fg(e),i=n.length;if(Fg(t).length!==i)return!1;for(var o;i-- >0;)if(o=n[i],o===yO&&(e.$$typeof||t.$$typeof)&&e.$$typeof!==t.$$typeof||!vO(t,o)||!r.equals(e[o],t[o],o,o,e,t,r))return!1;return!0}function Co(e,t,r){var n=Bg(e),i=n.length;if(Bg(t).length!==i)return!1;for(var o,a,u;i-- >0;)if(o=n[i],o===yO&&(e.$$typeof||t.$$typeof)&&e.$$typeof!==t.$$typeof||!vO(t,o)||!r.equals(e[o],t[o],o,o,e,t,r)||(a=zg(e,o),u=zg(t,o),(a||u)&&(!a||!u||a.configurable!==u.configurable||a.enumerable!==u.enumerable||a.writable!==u.writable)))return!1;return!0}function ZB(e,t){return go(e.valueOf(),t.valueOf())}function JB(e,t){return e.source===t.source&&e.flags===t.flags}function Wg(e,t,r){if(e.size!==t.size)return!1;for(var n={},i=e.values(),o,a;(o=i.next())&&!o.done;){for(var u=t.values(),l=!1,s=0;(a=u.next())&&!a.done;)!l&&!n[s]&&(l=r.equals(o.value,a.value,o.value,a.value,e,t,r))&&(n[s]=!0),s++;if(!l)return!1}return!0}function ez(e,t){var r=e.length;if(t.length!==r)return!1;for(;r-- >0;)if(e[r]!==t[r])return!1;return!0}var tz="[object Arguments]",rz="[object Boolean]",nz="[object Date]",iz="[object Map]",oz="[object Number]",az="[object Object]",uz="[object RegExp]",lz="[object Set]",sz="[object String]",cz=Array.isArray,Hg=typeof ArrayBuffer=="function"&&ArrayBuffer.isView?ArrayBuffer.isView:null,Kg=Object.assign,fz=Object.prototype.toString.call.bind(Object.prototype.toString);function dz(e){var t=e.areArraysEqual,r=e.areDatesEqual,n=e.areMapsEqual,i=e.areObjectsEqual,o=e.arePrimitiveWrappersEqual,a=e.areRegExpsEqual,u=e.areSetsEqual,l=e.areTypedArraysEqual;return function(f,c,d){if(f===c)return!0;if(f==null||c==null||typeof f!="object"||typeof c!="object")return f!==f&&c!==c;var p=f.constructor;if(p!==c.constructor)return!1;if(p===Object)return i(f,c,d);if(cz(f))return t(f,c,d);if(Hg!=null&&Hg(f))return l(f,c,d);if(p===Date)return r(f,c,d);if(p===RegExp)return a(f,c,d);if(p===Map)return n(f,c,d);if(p===Set)return u(f,c,d);var h=fz(f);return h===nz?r(f,c,d):h===uz?a(f,c,d):h===iz?n(f,c,d):h===lz?u(f,c,d):h===az?typeof f.then!="function"&&typeof c.then!="function"&&i(f,c,d):h===tz?i(f,c,d):h===rz||h===oz||h===sz?o(f,c,d):!1}}function pz(e){var t=e.circular,r=e.createCustomConfig,n=e.strict,i={areArraysEqual:n?Co:XB,areDatesEqual:YB,areMapsEqual:n?Lg(Ug,Co):Ug,areObjectsEqual:n?Co:QB,arePrimitiveWrappersEqual:ZB,areRegExpsEqual:JB,areSetsEqual:n?Lg(Wg,Co):Wg,areTypedArraysEqual:n?Co:ez};if(r&&(i=Kg({},i,r(i))),t){var o=Qu(i.areArraysEqual),a=Qu(i.areMapsEqual),u=Qu(i.areObjectsEqual),l=Qu(i.areSetsEqual);i=Kg({},i,{areArraysEqual:o,areMapsEqual:a,areObjectsEqual:u,areSetsEqual:l})}return i}function hz(e){return function(t,r,n,i,o,a,u){return e(t,r,u)}}function vz(e){var t=e.circular,r=e.comparator,n=e.createState,i=e.equals,o=e.strict;if(n)return function(l,s){var f=n(),c=f.cache,d=c===void 0?t?new WeakMap:void 0:c,p=f.meta;return r(l,s,{cache:d,equals:i,meta:p,strict:o})};if(t)return function(l,s){return r(l,s,{cache:new WeakMap,equals:i,meta:void 0,strict:o})};var a={cache:void 0,equals:i,meta:void 0,strict:o};return function(l,s){return r(l,s,a)}}var yz=On();On({strict:!0});On({circular:!0});On({circular:!0,strict:!0});On({createInternalComparator:function(){return go}});On({strict:!0,createInternalComparator:function(){return go}});On({circular:!0,createInternalComparator:function(){return go}});On({circular:!0,createInternalComparator:function(){return go},strict:!0});function On(e){e===void 0&&(e={});var t=e.circular,r=t===void 0?!1:t,n=e.createInternalComparator,i=e.createState,o=e.strict,a=o===void 0?!1:o,u=pz(e),l=dz(u),s=n?n(l):hz(l);return vz({circular:r,comparator:l,createState:i,equals:s,strict:a})}function mz(e){typeof requestAnimationFrame<"u"&&requestAnimationFrame(e)}function Vg(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,r=-1,n=function i(o){r<0&&(r=o),o-r>t?(e(o),r=-1):mz(i)};requestAnimationFrame(n)}function wp(e){"@babel/helpers - typeof";return wp=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},wp(e)}function gz(e){return Sz(e)||xz(e)||wz(e)||bz()}function bz(){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 wz(e,t){if(e){if(typeof e=="string")return Gg(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Gg(e,t)}}function Gg(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);re.length)&&(t=e.length);for(var r=0,n=new Array(t);r1?1:m<0?0:m},v=function(m){for(var y=m>1?1:m,b=y,S=0;S<8;++S){var w=c(b)-y,x=p(b);if(Math.abs(w-y)0&&arguments[0]!==void 0?arguments[0]:{},r=t.stiff,n=r===void 0?100:r,i=t.damping,o=i===void 0?8:i,a=t.dt,u=a===void 0?17:a,l=function(f,c,d){var p=-(f-c)*n,h=d*o,v=d+(p-h)*u/1e3,g=d*u/1e3+f;return Math.abs(g-c)e.length)&&(t=e.length);for(var r=0,n=new Array(t);r=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function n4(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,o;for(o=0;o=0)&&(r[i]=e[i]);return r}function Nf(e){return u4(e)||a4(e)||o4(e)||i4()}function i4(){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 o4(e,t){if(e){if(typeof e=="string")return Pp(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Pp(e,t)}}function a4(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function u4(e){if(Array.isArray(e))return Pp(e)}function Pp(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r"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 fs(e){return fs=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},fs(e)}var Ir=function(e){f4(r,e);var t=d4(r);function r(n,i){var o;l4(this,r),o=t.call(this,n,i);var a=o.props,u=a.isActive,l=a.attributeName,s=a.from,f=a.to,c=a.steps,d=a.children,p=a.duration;if(o.handleStyleChange=o.handleStyleChange.bind($p(o)),o.changeStyle=o.changeStyle.bind($p(o)),!u||p<=0)return o.state={style:{}},typeof d=="function"&&(o.state={style:f}),Ep(o);if(c&&c.length)o.state={style:c[0].style};else if(s){if(typeof d=="function")return o.state={style:s},Ep(o);o.state={style:l?Ho({},l,s):s}}else o.state={style:{}};return o}return s4(r,[{key:"componentDidMount",value:function(){var i=this.props,o=i.isActive,a=i.canBegin;this.mounted=!0,!(!o||!a)&&this.runAnimation(this.props)}},{key:"componentDidUpdate",value:function(i){var o=this.props,a=o.isActive,u=o.canBegin,l=o.attributeName,s=o.shouldReAnimate,f=o.to,c=o.from,d=this.state.style;if(u){if(!a){var p={style:l?Ho({},l,f):f};this.state&&d&&(l&&d[l]!==f||!l&&d!==f)&&this.setState(p);return}if(!(yz(i.to,f)&&i.canBegin&&i.isActive)){var h=!i.canBegin||!i.isActive;this.manager&&this.manager.stop(),this.stopJSAnimation&&this.stopJSAnimation();var v=h||s?c:i.to;if(this.state&&d){var g={style:l?Ho({},l,v):v};(l&&[l]!==v||!l&&d!==v)&&this.setState(g)}this.runAnimation(qt(qt({},this.props),{},{from:v,begin:0}))}}}},{key:"componentWillUnmount",value:function(){this.mounted=!1;var i=this.props.onAnimationEnd;this.unSubscribe&&this.unSubscribe(),this.manager&&(this.manager.stop(),this.manager=null),this.stopJSAnimation&&this.stopJSAnimation(),i&&i()}},{key:"handleStyleChange",value:function(i){this.changeStyle(i)}},{key:"changeStyle",value:function(i){this.mounted&&this.setState({style:i})}},{key:"runJSAnimation",value:function(i){var o=this,a=i.from,u=i.to,l=i.duration,s=i.easing,f=i.begin,c=i.onAnimationEnd,d=i.onAnimationStart,p=e4(a,u,Wz(s),l,this.changeStyle),h=function(){o.stopJSAnimation=p()};this.manager.start([d,f,h,l,c])}},{key:"runStepAnimation",value:function(i){var o=this,a=i.steps,u=i.begin,l=i.onAnimationStart,s=a[0],f=s.style,c=s.duration,d=c===void 0?0:c,p=function(v,g,m){if(m===0)return v;var y=g.duration,b=g.easing,S=b===void 0?"ease":b,w=g.style,x=g.properties,O=g.onAnimationEnd,_=m>0?a[m-1]:g,P=x||Object.keys(w);if(typeof S=="function"||S==="spring")return[].concat(Nf(v),[o.runJSAnimation.bind(o,{from:_.style,to:w,duration:y,easing:S}),y]);var E=Xg(P,y,S),A=qt(qt(qt({},_.style),w),{},{transition:E});return[].concat(Nf(v),[A,y,O]).filter(Tz)};return this.manager.start([l].concat(Nf(a.reduce(p,[f,Math.max(d,u)])),[i.onAnimationEnd]))}},{key:"runAnimation",value:function(i){this.manager||(this.manager=Oz());var o=i.begin,a=i.duration,u=i.attributeName,l=i.to,s=i.easing,f=i.onAnimationStart,c=i.onAnimationEnd,d=i.steps,p=i.children,h=this.manager;if(this.unSubscribe=h.subscribe(this.handleStyleChange),typeof s=="function"||typeof p=="function"||s==="spring"){this.runJSAnimation(i);return}if(d.length>1){this.runStepAnimation(i);return}var v=u?Ho({},u,l):l,g=Xg(Object.keys(v),a,s);h.start([f,o,qt(qt({},v),{},{transition:g}),a,c])}},{key:"render",value:function(){var i=this.props,o=i.children;i.begin;var a=i.duration;i.attributeName,i.easing;var u=i.isActive;i.steps,i.from,i.to,i.canBegin,i.onAnimationEnd,i.shouldReAnimate,i.onAnimationReStart;var l=r4(i,t4),s=T.Children.count(o),f=Bv(this.state.style);if(typeof o=="function")return o(f);if(!u||s===0||a<=0)return o;var c=function(p){var h=p.props,v=h.style,g=v===void 0?{}:v,m=h.className,y=T.cloneElement(p,qt(qt({},l),{},{style:qt(qt({},g),f),className:m}));return y};return s===1?c(T.Children.only(o)):$.createElement("div",null,T.Children.map(o,function(d){return c(d)}))}}]),r}(T.PureComponent);Ir.displayName="Animate";Ir.defaultProps={begin:0,duration:1e3,from:"",to:"",attributeName:"",easing:"ease",isActive:!0,canBegin:!0,steps:[],onAnimationEnd:function(){},onAnimationStart:function(){}};Ir.propTypes={from:Q.oneOfType([Q.object,Q.string]),to:Q.oneOfType([Q.object,Q.string]),attributeName:Q.string,duration:Q.number,begin:Q.number,easing:Q.oneOfType([Q.string,Q.func]),steps:Q.arrayOf(Q.shape({duration:Q.number.isRequired,style:Q.object.isRequired,easing:Q.oneOfType([Q.oneOf(["ease","ease-in","ease-out","ease-in-out","linear"]),Q.func]),properties:Q.arrayOf("string"),onAnimationEnd:Q.func})),children:Q.oneOfType([Q.node,Q.func]),isActive:Q.bool,canBegin:Q.bool,onAnimationEnd:Q.func,shouldReAnimate:Q.bool,onAnimationStart:Q.func,onAnimationReStart:Q.func};Number.isFinite===void 0&&(Number.isFinite=function(e){return typeof e=="number"&&isFinite(e)});Q.object,Q.object,Q.object,Q.element;Q.object,Q.object,Q.object,Q.oneOfType([Q.array,Q.element]),Q.any;function Ta(e){"@babel/helpers - typeof";return Ta=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},Ta(e)}function Zu(e,t,r){return t=h4(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function h4(e){var t=v4(e,"string");return Ta(t)==="symbol"?t:String(t)}function v4(e,t){if(Ta(e)!=="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Ta(n)!=="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var jo="recharts-tooltip-wrapper",y4={visibility:"hidden"};function m4(e){var t,r=e.coordinate,n=e.translateX,i=e.translateY;return se(jo,(t={},Zu(t,"".concat(jo,"-right"),U(n)&&r&&U(r.x)&&n>=r.x),Zu(t,"".concat(jo,"-left"),U(n)&&r&&U(r.x)&&n=r.y),Zu(t,"".concat(jo,"-top"),U(i)&&r&&U(r.y)&&iv?Math.max(f,l[n]):Math.max(c,l[n])}function g4(e){var t=e.translateX,r=e.translateY,n=e.useTranslate3d;return Bv({transform:n?"translate3d(".concat(t,"px, ").concat(r,"px, 0)"):"translate(".concat(t,"px, ").concat(r,"px)")})}function b4(e){var t=e.allowEscapeViewBox,r=e.coordinate,n=e.offsetTopLeft,i=e.position,o=e.reverseDirection,a=e.tooltipBox,u=e.useTranslate3d,l=e.viewBox,s,f,c;return a.height>0&&a.width>0&&r?(f=r0({allowEscapeViewBox:t,coordinate:r,key:"x",offsetTopLeft:n,position:i,reverseDirection:o,tooltipDimension:a.width,viewBox:l,viewBoxDimension:l.width}),c=r0({allowEscapeViewBox:t,coordinate:r,key:"y",offsetTopLeft:n,position:i,reverseDirection:o,tooltipDimension:a.height,viewBox:l,viewBoxDimension:l.height}),s=g4({translateX:f,translateY:c,useTranslate3d:u})):s=y4,{cssProperties:s,cssClasses:m4({translateX:f,translateY:c,coordinate:r})}}function Vi(e){"@babel/helpers - typeof";return Vi=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},Vi(e)}function n0(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Df(e){for(var t=1;t"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 ds(e){return ds=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},ds(e)}function xl(e,t,r){return t=SO(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function SO(e){var t=A4(e,"string");return Vi(t)==="symbol"?t:String(t)}function A4(e,t){if(Vi(e)!=="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Vi(n)!=="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var o0=1,E4=function(e){S4(r,e);var t=O4(r);function r(){var n;w4(this,r);for(var i=arguments.length,o=new Array(i),a=0;ao0||Math.abs(i.height-this.lastBoundingBox.height)>o0)&&(this.lastBoundingBox.width=i.width,this.lastBoundingBox.height=i.height)}else(this.lastBoundingBox.width!==-1||this.lastBoundingBox.height!==-1)&&(this.lastBoundingBox.width=-1,this.lastBoundingBox.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 i,o;this.props.active&&this.updateBBox(),this.state.dismissed&&(((i=this.props.coordinate)===null||i===void 0?void 0:i.x)!==this.state.dismissedAtCoordinate.x||((o=this.props.coordinate)===null||o===void 0?void 0:o.y)!==this.state.dismissedAtCoordinate.y)&&(this.state.dismissed=!1)}},{key:"render",value:function(){var i=this,o=this.props,a=o.active,u=o.allowEscapeViewBox,l=o.animationDuration,s=o.animationEasing,f=o.children,c=o.coordinate,d=o.hasPayload,p=o.isAnimationActive,h=o.offset,v=o.position,g=o.reverseDirection,m=o.useTranslate3d,y=o.viewBox,b=o.wrapperStyle,S=b4({allowEscapeViewBox:u,coordinate:c,offsetTopLeft:h,position:v,reverseDirection:g,tooltipBox:{height:this.lastBoundingBox.height,width:this.lastBoundingBox.width},useTranslate3d:m,viewBox:y}),w=S.cssClasses,x=S.cssProperties,O=Df(Df(Df({},p&&a&&Bv({transition:"transform ".concat(l,"ms ").concat(s)})),x),{},{pointerEvents:"none",visibility:!this.state.dismissed&&a&&d?"visible":"hidden",position:"absolute",top:0,left:0},b);return $.createElement("div",{tabIndex:-1,role:"dialog",className:w,style:O,ref:function(P){i.wrapperNode=P}},f)}}]),r}(T.PureComponent),$4=function(){return!(typeof window<"u"&&window.document&&window.document.createElement&&window.setTimeout)},$r={isSsr:$4(),get:function(t){return $r[t]},set:function(t,r){if(typeof t=="string")$r[t]=r;else{var n=Object.keys(t);n&&n.length&&n.forEach(function(i){$r[i]=t[i]})}}};function Gi(e){"@babel/helpers - typeof";return Gi=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},Gi(e)}function a0(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function u0(e){for(var t=1;t"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 ps(e){return ps=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},ps(e)}function zv(e,t,r){return t=OO(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function OO(e){var t=D4(e,"string");return Gi(t)==="symbol"?t:String(t)}function D4(e,t){if(Gi(e)!=="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Gi(n)!=="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function R4(e){return e.dataKey}function L4(e,t){return $.isValidElement(e)?$.cloneElement(e,t):typeof e=="function"?$.createElement(e,t):$.createElement(zB,t)}var Bn=function(e){C4(r,e);var t=j4(r);function r(){return k4(this,r),t.apply(this,arguments)}return T4(r,[{key:"render",value:function(){var i=this.props,o=i.active,a=i.allowEscapeViewBox,u=i.animationDuration,l=i.animationEasing,s=i.content,f=i.coordinate,c=i.filterNull,d=i.isAnimationActive,p=i.offset,h=i.payload,v=i.payloadUniqBy,g=i.position,m=i.reverseDirection,y=i.useTranslate3d,b=i.viewBox,S=i.wrapperStyle,w=h??[];c&&w.length&&(w=iO(h.filter(function(O){return O.value!=null}),v,R4));var x=w.length>0;return $.createElement(E4,{allowEscapeViewBox:a,animationDuration:u,animationEasing:l,isAnimationActive:d,active:o,coordinate:f,hasPayload:x,offset:p,position:g,reverseDirection:m,useTranslate3d:y,viewBox:b,wrapperStyle:S},L4(s,u0(u0({},this.props),{},{payload:w})))}}]),r}(T.PureComponent);zv(Bn,"displayName","Tooltip");zv(Bn,"defaultProps",{allowEscapeViewBox:{x:!1,y:!1},animationDuration:400,animationEasing:"ease",contentStyle:{},coordinate:{x:0,y:0},cursor:!0,cursorStyle:{},filterNull:!0,isAnimationActive:!$r.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 B4=gr,z4=function(){return B4.Date.now()},F4=z4,U4=/\s/;function W4(e){for(var t=e.length;t--&&U4.test(e.charAt(t)););return t}var H4=W4,K4=H4,V4=/^\s+/;function G4(e){return e&&e.slice(0,K4(e)+1).replace(V4,"")}var q4=G4,X4=q4,s0=xn,Y4=so,c0=NaN,Q4=/^[-+]0x[0-9a-f]+$/i,Z4=/^0b[01]+$/i,J4=/^0o[0-7]+$/i,e8=parseInt;function t8(e){if(typeof e=="number")return e;if(Y4(e))return c0;if(s0(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=s0(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=X4(e);var r=Z4.test(e);return r||J4.test(e)?e8(e.slice(2),r?2:8):Q4.test(e)?c0:+e}var _O=t8,r8=xn,Rf=F4,f0=_O,n8="Expected a function",i8=Math.max,o8=Math.min;function a8(e,t,r){var n,i,o,a,u,l,s=0,f=!1,c=!1,d=!0;if(typeof e!="function")throw new TypeError(n8);t=f0(t)||0,r8(r)&&(f=!!r.leading,c="maxWait"in r,o=c?i8(f0(r.maxWait)||0,t):o,d="trailing"in r?!!r.trailing:d);function p(x){var O=n,_=i;return n=i=void 0,s=x,a=e.apply(_,O),a}function h(x){return s=x,u=setTimeout(m,t),f?p(x):a}function v(x){var O=x-l,_=x-s,P=t-O;return c?o8(P,o-_):P}function g(x){var O=x-l,_=x-s;return l===void 0||O>=t||O<0||c&&_>=o}function m(){var x=Rf();if(g(x))return y(x);u=setTimeout(m,v(x))}function y(x){return u=void 0,d&&n?p(x):(n=i=void 0,a)}function b(){u!==void 0&&clearTimeout(u),s=0,n=l=i=u=void 0}function S(){return u===void 0?a:y(Rf())}function w(){var x=Rf(),O=g(x);if(n=arguments,i=this,l=x,O){if(u===void 0)return h(l);if(c)return clearTimeout(u),u=setTimeout(m,t),p(l)}return u===void 0&&(u=setTimeout(m,t)),a}return w.cancel=b,w.flush=S,w}var u8=a8,l8=u8,s8=xn,c8="Expected a function";function f8(e,t,r){var n=!0,i=!0;if(typeof e!="function")throw new TypeError(c8);return s8(r)&&(n="leading"in r?!!r.leading:n,i="trailing"in r?!!r.trailing:i),l8(e,t,{leading:n,maxWait:t,trailing:i})}var d8=f8;const PO=ve(d8);function Ca(e){"@babel/helpers - typeof";return Ca=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},Ca(e)}function d0(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Ju(e){for(var t=1;te.length)&&(t=e.length);for(var r=0,n=new Array(t);r0&&(j=PO(j,v,{trailing:!0,leading:!1}));var N=new ResizeObserver(j),D=w.current.getBoundingClientRect(),B=D.width,R=D.height;return A(B,R),N.observe(w.current),function(){N.disconnect()}},[A,v]);var k=T.useMemo(function(){var j=P.containerWidth,N=P.containerHeight;if(j<0||N<0)return null;Hn(Ln(a)||Ln(l),`The width(%s) and height(%s) are both fixed numbers, + maybe you don't need to use a ResponsiveContainer.`,a,l),Hn(!r||r>0,"The aspect(%s) must be greater than zero.",r);var D=Ln(a)?j:a,B=Ln(l)?N:l;r&&r>0&&(D?B=D/r:B&&(D=B*r),d&&B>d&&(B=d)),Hn(D>0||B>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.`,D,B,a,l,f,c,r);var R=!Array.isArray(p)&&Jd.isElement(p)&&Er(p.type).endsWith("Chart");return $.Children.map(p,function(C){return Jd.isElement(C)?T.cloneElement(C,Ju({width:D,height:B},R?{style:Ju({height:"100%",width:"100%",maxHeight:B,maxWidth:D},C.props.style)}:{})):C})},[r,p,l,d,c,f,P,a]);return $.createElement("div",{id:g?"".concat(g):void 0,className:se("recharts-responsive-container",m),style:Ju(Ju({},S),{},{width:a,height:l,minWidth:f,minHeight:c,maxHeight:d}),ref:w},k)}),AO=function(t){return null};AO.displayName="Cell";function ja(e){"@babel/helpers - typeof";return ja=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},ja(e)}function h0(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Cp(e){for(var t=1;t1&&arguments[1]!==void 0?arguments[1]:{};if(t==null||$r.isSsr)return{width:0,height:0};var n=E8(r),i=JSON.stringify({text:t,copyStyle:n});if(oi.widthCache[i])return oi.widthCache[i];try{var o=document.getElementById(v0);o||(o=document.createElement("span"),o.setAttribute("id",v0),o.setAttribute("aria-hidden","true"),document.body.appendChild(o));var a=Cp(Cp({},A8),n);Object.assign(o.style,a),o.textContent="".concat(t);var u=o.getBoundingClientRect(),l={width:u.width,height:u.height};return oi.widthCache[i]=l,++oi.cacheCount>P8&&(oi.cacheCount=0,oi.widthCache={}),l}catch{return{width:0,height:0}}},$8=function(t){return{top:t.top+window.scrollY-document.documentElement.clientTop,left:t.left+window.scrollX-document.documentElement.clientLeft}};function Ma(e){"@babel/helpers - typeof";return Ma=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},Ma(e)}function hs(e,t){return j8(e)||C8(e,t)||T8(e,t)||k8()}function k8(){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 T8(e,t){if(e){if(typeof e=="string")return y0(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return y0(e,t)}}function y0(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function V8(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,o;for(o=0;o=0)&&(r[i]=e[i]);return r}function S0(e,t){return Y8(e)||X8(e,t)||q8(e,t)||G8()}function G8(){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 q8(e,t){if(e){if(typeof e=="string")return O0(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return O0(e,t)}}function O0(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r0&&arguments[0]!==void 0?arguments[0]:[];return D.reduce(function(B,R){var C=R.word,I=R.width,F=B[B.length-1];if(F&&(i==null||o||F.width+I+nR.width?B:R})};if(!f)return p;for(var v="…",g=function(D){var B=c.slice(0,D),R=TO({breakAll:s,style:l,children:B+v}).wordsWithComputedWidth,C=d(R),I=C.length>a||h(C).width>Number(i);return[I,C]},m=0,y=c.length-1,b=0,S;m<=y&&b<=c.length-1;){var w=Math.floor((m+y)/2),x=w-1,O=g(x),_=S0(O,2),P=_[0],E=_[1],A=g(w),k=S0(A,1),j=k[0];if(!P&&!j&&(m=w+1),P&&j&&(y=w-1),!P&&j){S=E;break}b++}return S||p},_0=function(t){var r=ie(t)?[]:t.toString().split(kO);return[{words:r}]},Z8=function(t){var r=t.width,n=t.scaleToFit,i=t.children,o=t.style,a=t.breakAll,u=t.maxLines;if((r||n)&&!$r.isSsr){var l,s,f=TO({breakAll:a,children:i,style:o});if(f){var c=f.wordsWithComputedWidth,d=f.spaceWidth;l=c,s=d}else return _0(i);return Q8({breakAll:a,children:i,maxLines:u,style:o},l,s,r,n)}return _0(i)},P0="#808080",vs=function(t){var r=t.x,n=r===void 0?0:r,i=t.y,o=i===void 0?0:i,a=t.lineHeight,u=a===void 0?"1em":a,l=t.capHeight,s=l===void 0?"0.71em":l,f=t.scaleToFit,c=f===void 0?!1:f,d=t.textAnchor,p=d===void 0?"start":d,h=t.verticalAnchor,v=h===void 0?"end":h,g=t.fill,m=g===void 0?P0:g,y=x0(t,H8),b=T.useMemo(function(){return Z8({breakAll:y.breakAll,children:y.children,maxLines:y.maxLines,scaleToFit:c,style:y.style,width:y.width})},[y.breakAll,y.children,y.maxLines,c,y.style,y.width]),S=y.dx,w=y.dy,x=y.angle,O=y.className,_=y.breakAll,P=x0(y,K8);if(!Be(n)||!Be(o))return null;var E=n+(U(S)?S:0),A=o+(U(w)?w:0),k;switch(v){case"start":k=Lf("calc(".concat(s,")"));break;case"middle":k=Lf("calc(".concat((b.length-1)/2," * -").concat(u," + (").concat(s," / 2))"));break;default:k=Lf("calc(".concat(b.length-1," * -").concat(u,")"));break}var j=[];if(c){var N=b[0].width,D=y.width;j.push("scale(".concat((U(D)?D/N:1)/N,")"))}return x&&j.push("rotate(".concat(x,", ").concat(E,", ").concat(A,")")),j.length&&(P.transform=j.join(" ")),$.createElement("text",jp({},ne(P,!0),{x:E,y:A,className:se("recharts-text",O),textAnchor:p,fill:m.includes("url")?P0:m}),b.map(function(B,R){return $.createElement("tspan",{x:E,dy:R===0?k:u,key:R},B.words.join(_?"":" "))}))};function pn(e,t){return e==null||t==null?NaN:et?1:e>=t?0:NaN}function J8(e,t){return e==null||t==null?NaN:te?1:t>=e?0:NaN}function Fv(e){let t,r,n;e.length!==2?(t=pn,r=(u,l)=>pn(e(u),l),n=(u,l)=>e(u)-l):(t=e===pn||e===J8?e:eF,r=e,n=e);function i(u,l,s=0,f=u.length){if(s>>1;r(u[c],l)<0?s=c+1:f=c}while(s>>1;r(u[c],l)<=0?s=c+1:f=c}while(ss&&n(u[c-1],l)>-n(u[c],l)?c-1:c}return{left:i,center:a,right:o}}function eF(){return 0}function CO(e){return e===null?NaN:+e}function*tF(e,t){if(t===void 0)for(let r of e)r!=null&&(r=+r)>=r&&(yield r);else{let r=-1;for(let n of e)(n=t(n,++r,e))!=null&&(n=+n)>=n&&(yield n)}}const rF=Fv(pn),nF=rF.right;Fv(CO).center;const wu=nF;class A0 extends Map{constructor(t,r=aF){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:r}}),t!=null)for(const[n,i]of t)this.set(n,i)}get(t){return super.get(E0(this,t))}has(t){return super.has(E0(this,t))}set(t,r){return super.set(iF(this,t),r)}delete(t){return super.delete(oF(this,t))}}function E0({_intern:e,_key:t},r){const n=t(r);return e.has(n)?e.get(n):r}function iF({_intern:e,_key:t},r){const n=t(r);return e.has(n)?e.get(n):(e.set(n,r),r)}function oF({_intern:e,_key:t},r){const n=t(r);return e.has(n)&&(r=e.get(n),e.delete(n)),r}function aF(e){return e!==null&&typeof e=="object"?e.valueOf():e}function uF(e=pn){if(e===pn)return jO;if(typeof e!="function")throw new TypeError("compare is not a function");return(t,r)=>{const n=e(t,r);return n||n===0?n:(e(r,r)===0)-(e(t,t)===0)}}function jO(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(et?1:0)}const lF=Math.sqrt(50),sF=Math.sqrt(10),cF=Math.sqrt(2);function ys(e,t,r){const n=(t-e)/Math.max(0,r),i=Math.floor(Math.log10(n)),o=n/Math.pow(10,i),a=o>=lF?10:o>=sF?5:o>=cF?2:1;let u,l,s;return i<0?(s=Math.pow(10,-i)/a,u=Math.round(e*s),l=Math.round(t*s),u/st&&--l,s=-s):(s=Math.pow(10,i)*a,u=Math.round(e/s),l=Math.round(t/s),u*st&&--l),l0))return[];if(e===t)return[e];const n=t=i))return[];const u=o-i+1,l=new Array(u);if(n)if(a<0)for(let s=0;s=n)&&(r=n);else{let n=-1;for(let i of e)(i=t(i,++n,e))!=null&&(r=i)&&(r=i)}return r}function k0(e,t){let r;if(t===void 0)for(const n of e)n!=null&&(r>n||r===void 0&&n>=n)&&(r=n);else{let n=-1;for(let i of e)(i=t(i,++n,e))!=null&&(r>i||r===void 0&&i>=i)&&(r=i)}return r}function MO(e,t,r=0,n=1/0,i){if(t=Math.floor(t),r=Math.floor(Math.max(0,r)),n=Math.floor(Math.min(e.length-1,n)),!(r<=t&&t<=n))return e;for(i=i===void 0?jO:uF(i);n>r;){if(n-r>600){const l=n-r+1,s=t-r+1,f=Math.log(l),c=.5*Math.exp(2*f/3),d=.5*Math.sqrt(f*c*(l-c)/l)*(s-l/2<0?-1:1),p=Math.max(r,Math.floor(t-s*c/l+d)),h=Math.min(n,Math.floor(t+(l-s)*c/l+d));MO(e,t,p,h,i)}const o=e[t];let a=r,u=n;for(Mo(e,r,t),i(e[n],o)>0&&Mo(e,r,n);a0;)--u}i(e[r],o)===0?Mo(e,r,u):(++u,Mo(e,u,n)),u<=t&&(r=u+1),t<=u&&(n=u-1)}return e}function Mo(e,t,r){const n=e[t];e[t]=e[r],e[r]=n}function fF(e,t,r){if(e=Float64Array.from(tF(e,r)),!(!(n=e.length)||isNaN(t=+t))){if(t<=0||n<2)return k0(e);if(t>=1)return $0(e);var n,i=(n-1)*t,o=Math.floor(i),a=$0(MO(e,o).subarray(0,o+1)),u=k0(e.subarray(o+1));return a+(u-a)*(i-o)}}function dF(e,t,r=CO){if(!(!(n=e.length)||isNaN(t=+t))){if(t<=0||n<2)return+r(e[0],0,e);if(t>=1)return+r(e[n-1],n-1,e);var n,i=(n-1)*t,o=Math.floor(i),a=+r(e[o],o,e),u=+r(e[o+1],o+1,e);return a+(u-a)*(i-o)}}function pF(e,t,r){e=+e,t=+t,r=(i=arguments.length)<2?(t=e,e=0,1):i<3?1:+r;for(var n=-1,i=Math.max(0,Math.ceil((t-e)/r))|0,o=new Array(i);++n>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):r===8?tl(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):r===4?tl(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=vF.exec(e))?new pt(t[1],t[2],t[3],1):(t=yF.exec(e))?new pt(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=mF.exec(e))?tl(t[1],t[2],t[3],t[4]):(t=gF.exec(e))?tl(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=bF.exec(e))?D0(t[1],t[2]/100,t[3]/100,1):(t=wF.exec(e))?D0(t[1],t[2]/100,t[3]/100,t[4]):T0.hasOwnProperty(e)?M0(T0[e]):e==="transparent"?new pt(NaN,NaN,NaN,0):null}function M0(e){return new pt(e>>16&255,e>>8&255,e&255,1)}function tl(e,t,r,n){return n<=0&&(e=t=r=NaN),new pt(e,t,r,n)}function OF(e){return e instanceof xu||(e=Ra(e)),e?(e=e.rgb(),new pt(e.r,e.g,e.b,e.opacity)):new pt}function Rp(e,t,r,n){return arguments.length===1?OF(e):new pt(e,t,r,n??1)}function pt(e,t,r,n){this.r=+e,this.g=+t,this.b=+r,this.opacity=+n}Wv(pt,Rp,NO(xu,{brighter(e){return e=e==null?ms:Math.pow(ms,e),new pt(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?Na:Math.pow(Na,e),new pt(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new pt(Kn(this.r),Kn(this.g),Kn(this.b),gs(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:I0,formatHex:I0,formatHex8:_F,formatRgb:N0,toString:N0}));function I0(){return`#${zn(this.r)}${zn(this.g)}${zn(this.b)}`}function _F(){return`#${zn(this.r)}${zn(this.g)}${zn(this.b)}${zn((isNaN(this.opacity)?1:this.opacity)*255)}`}function N0(){const e=gs(this.opacity);return`${e===1?"rgb(":"rgba("}${Kn(this.r)}, ${Kn(this.g)}, ${Kn(this.b)}${e===1?")":`, ${e})`}`}function gs(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Kn(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function zn(e){return e=Kn(e),(e<16?"0":"")+e.toString(16)}function D0(e,t,r,n){return n<=0?e=t=r=NaN:r<=0||r>=1?e=t=NaN:t<=0&&(e=NaN),new tr(e,t,r,n)}function DO(e){if(e instanceof tr)return new tr(e.h,e.s,e.l,e.opacity);if(e instanceof xu||(e=Ra(e)),!e)return new tr;if(e instanceof tr)return e;e=e.rgb();var t=e.r/255,r=e.g/255,n=e.b/255,i=Math.min(t,r,n),o=Math.max(t,r,n),a=NaN,u=o-i,l=(o+i)/2;return u?(t===o?a=(r-n)/u+(r0&&l<1?0:a,new tr(a,u,l,e.opacity)}function PF(e,t,r,n){return arguments.length===1?DO(e):new tr(e,t,r,n??1)}function tr(e,t,r,n){this.h=+e,this.s=+t,this.l=+r,this.opacity=+n}Wv(tr,PF,NO(xu,{brighter(e){return e=e==null?ms:Math.pow(ms,e),new tr(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Na:Math.pow(Na,e),new tr(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,r=this.l,n=r+(r<.5?r:1-r)*t,i=2*r-n;return new pt(Bf(e>=240?e-240:e+120,i,n),Bf(e,i,n),Bf(e<120?e+240:e-120,i,n),this.opacity)},clamp(){return new tr(R0(this.h),rl(this.s),rl(this.l),gs(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=gs(this.opacity);return`${e===1?"hsl(":"hsla("}${R0(this.h)}, ${rl(this.s)*100}%, ${rl(this.l)*100}%${e===1?")":`, ${e})`}`}}));function R0(e){return e=(e||0)%360,e<0?e+360:e}function rl(e){return Math.max(0,Math.min(1,e||0))}function Bf(e,t,r){return(e<60?t+(r-t)*e/60:e<180?r:e<240?t+(r-t)*(240-e)/60:t)*255}const Hv=e=>()=>e;function AF(e,t){return function(r){return e+r*t}}function EF(e,t,r){return e=Math.pow(e,r),t=Math.pow(t,r)-e,r=1/r,function(n){return Math.pow(e+n*t,r)}}function $F(e){return(e=+e)==1?RO:function(t,r){return r-t?EF(t,r,e):Hv(isNaN(t)?r:t)}}function RO(e,t){var r=t-e;return r?AF(e,r):Hv(isNaN(e)?t:e)}const L0=function e(t){var r=$F(t);function n(i,o){var a=r((i=Rp(i)).r,(o=Rp(o)).r),u=r(i.g,o.g),l=r(i.b,o.b),s=RO(i.opacity,o.opacity);return function(f){return i.r=a(f),i.g=u(f),i.b=l(f),i.opacity=s(f),i+""}}return n.gamma=e,n}(1);function kF(e,t){t||(t=[]);var r=e?Math.min(t.length,e.length):0,n=t.slice(),i;return function(o){for(i=0;ir&&(o=t.slice(r,o),u[a]?u[a]+=o:u[++a]=o),(n=n[0])===(i=i[0])?u[a]?u[a]+=i:u[++a]=i:(u[++a]=null,l.push({i:a,x:bs(n,i)})),r=zf.lastIndex;return rt&&(r=e,e=t,t=r),function(n){return Math.max(e,Math.min(t,n))}}function zF(e,t,r){var n=e[0],i=e[1],o=t[0],a=t[1];return i2?FF:zF,l=s=null,c}function c(d){return d==null||isNaN(d=+d)?o:(l||(l=u(e.map(n),t,r)))(n(a(d)))}return c.invert=function(d){return a(i((s||(s=u(t,e.map(n),bs)))(d)))},c.domain=function(d){return arguments.length?(e=Array.from(d,ws),f()):e.slice()},c.range=function(d){return arguments.length?(t=Array.from(d),f()):t.slice()},c.rangeRound=function(d){return t=Array.from(d),r=Kv,f()},c.clamp=function(d){return arguments.length?(a=d?!0:ut,f()):a!==ut},c.interpolate=function(d){return arguments.length?(r=d,f()):r},c.unknown=function(d){return arguments.length?(o=d,c):o},function(d,p){return n=d,i=p,f()}}function Vv(){return Tc()(ut,ut)}function UF(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function xs(e,t){if((r=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var r,n=e.slice(0,r);return[n.length>1?n[0]+n.slice(2):n,+e.slice(r+1)]}function qi(e){return e=xs(Math.abs(e)),e?e[1]:NaN}function WF(e,t){return function(r,n){for(var i=r.length,o=[],a=0,u=e[0],l=0;i>0&&u>0&&(l+u+1>n&&(u=Math.max(1,n-l)),o.push(r.substring(i-=u,i+u)),!((l+=u+1)>n));)u=e[a=(a+1)%e.length];return o.reverse().join(t)}}function HF(e){return function(t){return t.replace(/[0-9]/g,function(r){return e[+r]})}}var KF=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function La(e){if(!(t=KF.exec(e)))throw new Error("invalid format: "+e);var t;return new Gv({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]})}La.prototype=Gv.prototype;function Gv(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+""}Gv.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 VF(e){e:for(var t=e.length,r=1,n=-1,i;r0&&(n=0);break}return n>0?e.slice(0,n)+e.slice(i+1):e}var LO;function GF(e,t){var r=xs(e,t);if(!r)return e+"";var n=r[0],i=r[1],o=i-(LO=Math.max(-8,Math.min(8,Math.floor(i/3)))*3)+1,a=n.length;return o===a?n:o>a?n+new Array(o-a+1).join("0"):o>0?n.slice(0,o)+"."+n.slice(o):"0."+new Array(1-o).join("0")+xs(e,Math.max(0,t+o-1))[0]}function z0(e,t){var r=xs(e,t);if(!r)return e+"";var n=r[0],i=r[1];return i<0?"0."+new Array(-i).join("0")+n:n.length>i+1?n.slice(0,i+1)+"."+n.slice(i+1):n+new Array(i-n.length+2).join("0")}const F0={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:UF,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)=>z0(e*100,t),r:z0,s:GF,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function U0(e){return e}var W0=Array.prototype.map,H0=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function qF(e){var t=e.grouping===void 0||e.thousands===void 0?U0:WF(W0.call(e.grouping,Number),e.thousands+""),r=e.currency===void 0?"":e.currency[0]+"",n=e.currency===void 0?"":e.currency[1]+"",i=e.decimal===void 0?".":e.decimal+"",o=e.numerals===void 0?U0:HF(W0.call(e.numerals,String)),a=e.percent===void 0?"%":e.percent+"",u=e.minus===void 0?"−":e.minus+"",l=e.nan===void 0?"NaN":e.nan+"";function s(c){c=La(c);var d=c.fill,p=c.align,h=c.sign,v=c.symbol,g=c.zero,m=c.width,y=c.comma,b=c.precision,S=c.trim,w=c.type;w==="n"?(y=!0,w="g"):F0[w]||(b===void 0&&(b=12),S=!0,w="g"),(g||d==="0"&&p==="=")&&(g=!0,d="0",p="=");var x=v==="$"?r:v==="#"&&/[boxX]/.test(w)?"0"+w.toLowerCase():"",O=v==="$"?n:/[%p]/.test(w)?a:"",_=F0[w],P=/[defgprs%]/.test(w);b=b===void 0?6:/[gprs]/.test(w)?Math.max(1,Math.min(21,b)):Math.max(0,Math.min(20,b));function E(A){var k=x,j=O,N,D,B;if(w==="c")j=_(A)+j,A="";else{A=+A;var R=A<0||1/A<0;if(A=isNaN(A)?l:_(Math.abs(A),b),S&&(A=VF(A)),R&&+A==0&&h!=="+"&&(R=!1),k=(R?h==="("?h:u:h==="-"||h==="("?"":h)+k,j=(w==="s"?H0[8+LO/3]:"")+j+(R&&h==="("?")":""),P){for(N=-1,D=A.length;++NB||B>57){j=(B===46?i+A.slice(N+1):A.slice(N))+j,A=A.slice(0,N);break}}}y&&!g&&(A=t(A,1/0));var C=k.length+A.length+j.length,I=C>1)+k+A+j+I.slice(C);break;default:A=I+k+A+j;break}return o(A)}return E.toString=function(){return c+""},E}function f(c,d){var p=s((c=La(c),c.type="f",c)),h=Math.max(-8,Math.min(8,Math.floor(qi(d)/3)))*3,v=Math.pow(10,-h),g=H0[8+h/3];return function(m){return p(v*m)+g}}return{format:s,formatPrefix:f}}var nl,qv,BO;XF({thousands:",",grouping:[3],currency:["$",""]});function XF(e){return nl=qF(e),qv=nl.format,BO=nl.formatPrefix,nl}function YF(e){return Math.max(0,-qi(Math.abs(e)))}function QF(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(qi(t)/3)))*3-qi(Math.abs(e)))}function ZF(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,qi(t)-qi(e))+1}function zO(e,t,r,n){var i=Np(e,t,r),o;switch(n=La(n??",f"),n.type){case"s":{var a=Math.max(Math.abs(e),Math.abs(t));return n.precision==null&&!isNaN(o=QF(i,a))&&(n.precision=o),BO(n,a)}case"":case"e":case"g":case"p":case"r":{n.precision==null&&!isNaN(o=ZF(i,Math.max(Math.abs(e),Math.abs(t))))&&(n.precision=o-(n.type==="e"));break}case"f":case"%":{n.precision==null&&!isNaN(o=YF(i))&&(n.precision=o-(n.type==="%")*2);break}}return qv(n)}function _n(e){var t=e.domain;return e.ticks=function(r){var n=t();return Mp(n[0],n[n.length-1],r??10)},e.tickFormat=function(r,n){var i=t();return zO(i[0],i[i.length-1],r??10,n)},e.nice=function(r){r==null&&(r=10);var n=t(),i=0,o=n.length-1,a=n[i],u=n[o],l,s,f=10;for(u0;){if(s=Ip(a,u,r),s===l)return n[i]=a,n[o]=u,t(n);if(s>0)a=Math.floor(a/s)*s,u=Math.ceil(u/s)*s;else if(s<0)a=Math.ceil(a*s)/s,u=Math.floor(u*s)/s;else break;l=s}return e},e}function Ss(){var e=Vv();return e.copy=function(){return Su(e,Ss())},Vt.apply(e,arguments),_n(e)}function FO(e){var t;function r(n){return n==null||isNaN(n=+n)?t:n}return r.invert=r,r.domain=r.range=function(n){return arguments.length?(e=Array.from(n,ws),r):e.slice()},r.unknown=function(n){return arguments.length?(t=n,r):t},r.copy=function(){return FO(e).unknown(t)},e=arguments.length?Array.from(e,ws):[0,1],_n(r)}function UO(e,t){e=e.slice();var r=0,n=e.length-1,i=e[r],o=e[n],a;return oMath.pow(e,t)}function n5(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 G0(e){return(t,r)=>-e(-t,r)}function Xv(e){const t=e(K0,V0),r=t.domain;let n=10,i,o;function a(){return i=n5(n),o=r5(n),r()[0]<0?(i=G0(i),o=G0(o),e(JF,e5)):e(K0,V0),t}return t.base=function(u){return arguments.length?(n=+u,a()):n},t.domain=function(u){return arguments.length?(r(u),a()):r()},t.ticks=u=>{const l=r();let s=l[0],f=l[l.length-1];const c=f0){for(;d<=p;++d)for(h=1;hf)break;m.push(v)}}else for(;d<=p;++d)for(h=n-1;h>=1;--h)if(v=d>0?h/o(-d):h*o(d),!(vf)break;m.push(v)}m.length*2{if(u==null&&(u=10),l==null&&(l=n===10?"s":","),typeof l!="function"&&(!(n%1)&&(l=La(l)).precision==null&&(l.trim=!0),l=qv(l)),u===1/0)return l;const s=Math.max(1,n*u/t.ticks().length);return f=>{let c=f/o(Math.round(i(f)));return c*nr(UO(r(),{floor:u=>o(Math.floor(i(u))),ceil:u=>o(Math.ceil(i(u)))})),t}function WO(){const e=Xv(Tc()).domain([1,10]);return e.copy=()=>Su(e,WO()).base(e.base()),Vt.apply(e,arguments),e}function q0(e){return function(t){return Math.sign(t)*Math.log1p(Math.abs(t/e))}}function X0(e){return function(t){return Math.sign(t)*Math.expm1(Math.abs(t))*e}}function Yv(e){var t=1,r=e(q0(t),X0(t));return r.constant=function(n){return arguments.length?e(q0(t=+n),X0(t)):t},_n(r)}function HO(){var e=Yv(Tc());return e.copy=function(){return Su(e,HO()).constant(e.constant())},Vt.apply(e,arguments)}function Y0(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function i5(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function o5(e){return e<0?-e*e:e*e}function Qv(e){var t=e(ut,ut),r=1;function n(){return r===1?e(ut,ut):r===.5?e(i5,o5):e(Y0(r),Y0(1/r))}return t.exponent=function(i){return arguments.length?(r=+i,n()):r},_n(t)}function Zv(){var e=Qv(Tc());return e.copy=function(){return Su(e,Zv()).exponent(e.exponent())},Vt.apply(e,arguments),e}function a5(){return Zv.apply(null,arguments).exponent(.5)}function Q0(e){return Math.sign(e)*e*e}function u5(e){return Math.sign(e)*Math.sqrt(Math.abs(e))}function KO(){var e=Vv(),t=[0,1],r=!1,n;function i(o){var a=u5(e(o));return isNaN(a)?n:r?Math.round(a):a}return i.invert=function(o){return e.invert(Q0(o))},i.domain=function(o){return arguments.length?(e.domain(o),i):e.domain()},i.range=function(o){return arguments.length?(e.range((t=Array.from(o,ws)).map(Q0)),i):t.slice()},i.rangeRound=function(o){return i.range(o).round(!0)},i.round=function(o){return arguments.length?(r=!!o,i):r},i.clamp=function(o){return arguments.length?(e.clamp(o),i):e.clamp()},i.unknown=function(o){return arguments.length?(n=o,i):n},i.copy=function(){return KO(e.domain(),t).round(r).clamp(e.clamp()).unknown(n)},Vt.apply(i,arguments),_n(i)}function VO(){var e=[],t=[],r=[],n;function i(){var a=0,u=Math.max(1,t.length);for(r=new Array(u-1);++a0?r[u-1]:e[0],u=r?[n[r-1],t]:[n[s-1],n[s]]},a.unknown=function(l){return arguments.length&&(o=l),a},a.thresholds=function(){return n.slice()},a.copy=function(){return GO().domain([e,t]).range(i).unknown(o)},Vt.apply(_n(a),arguments)}function qO(){var e=[.5],t=[0,1],r,n=1;function i(o){return o!=null&&o<=o?t[wu(e,o,0,n)]:r}return i.domain=function(o){return arguments.length?(e=Array.from(o),n=Math.min(e.length,t.length-1),i):e.slice()},i.range=function(o){return arguments.length?(t=Array.from(o),n=Math.min(e.length,t.length-1),i):t.slice()},i.invertExtent=function(o){var a=t.indexOf(o);return[e[a-1],e[a]]},i.unknown=function(o){return arguments.length?(r=o,i):r},i.copy=function(){return qO().domain(e).range(t).unknown(r)},Vt.apply(i,arguments)}const Ff=new Date,Uf=new Date;function ze(e,t,r,n){function i(o){return e(o=arguments.length===0?new Date:new Date(+o)),o}return i.floor=o=>(e(o=new Date(+o)),o),i.ceil=o=>(e(o=new Date(o-1)),t(o,1),e(o),o),i.round=o=>{const a=i(o),u=i.ceil(o);return o-a(t(o=new Date(+o),a==null?1:Math.floor(a)),o),i.range=(o,a,u)=>{const l=[];if(o=i.ceil(o),u=u==null?1:Math.floor(u),!(o0))return l;let s;do l.push(s=new Date(+o)),t(o,u),e(o);while(sze(a=>{if(a>=a)for(;e(a),!o(a);)a.setTime(a-1)},(a,u)=>{if(a>=a)if(u<0)for(;++u<=0;)for(;t(a,-1),!o(a););else for(;--u>=0;)for(;t(a,1),!o(a););}),r&&(i.count=(o,a)=>(Ff.setTime(+o),Uf.setTime(+a),e(Ff),e(Uf),Math.floor(r(Ff,Uf))),i.every=o=>(o=Math.floor(o),!isFinite(o)||!(o>0)?null:o>1?i.filter(n?a=>n(a)%o===0:a=>i.count(0,a)%o===0):i)),i}const Os=ze(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);Os.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?ze(t=>{t.setTime(Math.floor(t/e)*e)},(t,r)=>{t.setTime(+t+r*e)},(t,r)=>(r-t)/e):Os);Os.range;const _r=1e3,Bt=_r*60,Pr=Bt*60,Nr=Pr*24,Jv=Nr*7,Z0=Nr*30,Wf=Nr*365,Fn=ze(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*_r)},(e,t)=>(t-e)/_r,e=>e.getUTCSeconds());Fn.range;const ey=ze(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*_r)},(e,t)=>{e.setTime(+e+t*Bt)},(e,t)=>(t-e)/Bt,e=>e.getMinutes());ey.range;const ty=ze(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*Bt)},(e,t)=>(t-e)/Bt,e=>e.getUTCMinutes());ty.range;const ry=ze(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*_r-e.getMinutes()*Bt)},(e,t)=>{e.setTime(+e+t*Pr)},(e,t)=>(t-e)/Pr,e=>e.getHours());ry.range;const ny=ze(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*Pr)},(e,t)=>(t-e)/Pr,e=>e.getUTCHours());ny.range;const Ou=ze(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Bt)/Nr,e=>e.getDate()-1);Ou.range;const Cc=ze(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/Nr,e=>e.getUTCDate()-1);Cc.range;const XO=ze(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/Nr,e=>Math.floor(e/Nr));XO.range;function ri(e){return ze(t=>{t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},(t,r)=>{t.setDate(t.getDate()+r*7)},(t,r)=>(r-t-(r.getTimezoneOffset()-t.getTimezoneOffset())*Bt)/Jv)}const jc=ri(0),_s=ri(1),l5=ri(2),s5=ri(3),Xi=ri(4),c5=ri(5),f5=ri(6);jc.range;_s.range;l5.range;s5.range;Xi.range;c5.range;f5.range;function ni(e){return ze(t=>{t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},(t,r)=>{t.setUTCDate(t.getUTCDate()+r*7)},(t,r)=>(r-t)/Jv)}const Mc=ni(0),Ps=ni(1),d5=ni(2),p5=ni(3),Yi=ni(4),h5=ni(5),v5=ni(6);Mc.range;Ps.range;d5.range;p5.range;Yi.range;h5.range;v5.range;const iy=ze(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());iy.range;const oy=ze(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());oy.range;const Dr=ze(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());Dr.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:ze(t=>{t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},(t,r)=>{t.setFullYear(t.getFullYear()+r*e)});Dr.range;const Rr=ze(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());Rr.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:ze(t=>{t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,r)=>{t.setUTCFullYear(t.getUTCFullYear()+r*e)});Rr.range;function YO(e,t,r,n,i,o){const a=[[Fn,1,_r],[Fn,5,5*_r],[Fn,15,15*_r],[Fn,30,30*_r],[o,1,Bt],[o,5,5*Bt],[o,15,15*Bt],[o,30,30*Bt],[i,1,Pr],[i,3,3*Pr],[i,6,6*Pr],[i,12,12*Pr],[n,1,Nr],[n,2,2*Nr],[r,1,Jv],[t,1,Z0],[t,3,3*Z0],[e,1,Wf]];function u(s,f,c){const d=fg).right(a,d);if(p===a.length)return e.every(Np(s/Wf,f/Wf,c));if(p===0)return Os.every(Math.max(Np(s,f,c),1));const[h,v]=a[d/a[p-1][2]53)return null;"w"in L||(L.w=1),"Z"in L?(oe=Kf(Io(L.y,0,1)),ke=oe.getUTCDay(),oe=ke>4||ke===0?Ps.ceil(oe):Ps(oe),oe=Cc.offset(oe,(L.V-1)*7),L.y=oe.getUTCFullYear(),L.m=oe.getUTCMonth(),L.d=oe.getUTCDate()+(L.w+6)%7):(oe=Hf(Io(L.y,0,1)),ke=oe.getDay(),oe=ke>4||ke===0?_s.ceil(oe):_s(oe),oe=Ou.offset(oe,(L.V-1)*7),L.y=oe.getFullYear(),L.m=oe.getMonth(),L.d=oe.getDate()+(L.w+6)%7)}else("W"in L||"U"in L)&&("w"in L||(L.w="u"in L?L.u%7:"W"in L?1:0),ke="Z"in L?Kf(Io(L.y,0,1)).getUTCDay():Hf(Io(L.y,0,1)).getDay(),L.m=0,L.d="W"in L?(L.w+6)%7+L.W*7-(ke+5)%7:L.w+L.U*7-(ke+6)%7);return"Z"in L?(L.H+=L.Z/100|0,L.M+=L.Z%100,Kf(L)):Hf(L)}}function _(W,Y,Z,L){for(var Ae=0,oe=Y.length,ke=Z.length,Ne,wt;Ae=ke)return-1;if(Ne=Y.charCodeAt(Ae++),Ne===37){if(Ne=Y.charAt(Ae++),wt=w[Ne in J0?Y.charAt(Ae++):Ne],!wt||(L=wt(W,Z,L))<0)return-1}else if(Ne!=Z.charCodeAt(L++))return-1}return L}function P(W,Y,Z){var L=s.exec(Y.slice(Z));return L?(W.p=f.get(L[0].toLowerCase()),Z+L[0].length):-1}function E(W,Y,Z){var L=p.exec(Y.slice(Z));return L?(W.w=h.get(L[0].toLowerCase()),Z+L[0].length):-1}function A(W,Y,Z){var L=c.exec(Y.slice(Z));return L?(W.w=d.get(L[0].toLowerCase()),Z+L[0].length):-1}function k(W,Y,Z){var L=m.exec(Y.slice(Z));return L?(W.m=y.get(L[0].toLowerCase()),Z+L[0].length):-1}function j(W,Y,Z){var L=v.exec(Y.slice(Z));return L?(W.m=g.get(L[0].toLowerCase()),Z+L[0].length):-1}function N(W,Y,Z){return _(W,t,Y,Z)}function D(W,Y,Z){return _(W,r,Y,Z)}function B(W,Y,Z){return _(W,n,Y,Z)}function R(W){return a[W.getDay()]}function C(W){return o[W.getDay()]}function I(W){return l[W.getMonth()]}function F(W){return u[W.getMonth()]}function X(W){return i[+(W.getHours()>=12)]}function H(W){return 1+~~(W.getMonth()/3)}function ee(W){return a[W.getUTCDay()]}function Pe(W){return o[W.getUTCDay()]}function $e(W){return l[W.getUTCMonth()]}function Ze(W){return u[W.getUTCMonth()]}function gt(W){return i[+(W.getUTCHours()>=12)]}function bt(W){return 1+~~(W.getUTCMonth()/3)}return{format:function(W){var Y=x(W+="",b);return Y.toString=function(){return W},Y},parse:function(W){var Y=O(W+="",!1);return Y.toString=function(){return W},Y},utcFormat:function(W){var Y=x(W+="",S);return Y.toString=function(){return W},Y},utcParse:function(W){var Y=O(W+="",!0);return Y.toString=function(){return W},Y}}}var J0={"-":"",_:" ",0:"0"},Ve=/^\s*\d+/,x5=/^%/,S5=/[\\^$*+?|[\]().{}]/g;function ue(e,t,r){var n=e<0?"-":"",i=(n?-e:e)+"",o=i.length;return n+(o[t.toLowerCase(),r]))}function _5(e,t,r){var n=Ve.exec(t.slice(r,r+1));return n?(e.w=+n[0],r+n[0].length):-1}function P5(e,t,r){var n=Ve.exec(t.slice(r,r+1));return n?(e.u=+n[0],r+n[0].length):-1}function A5(e,t,r){var n=Ve.exec(t.slice(r,r+2));return n?(e.U=+n[0],r+n[0].length):-1}function E5(e,t,r){var n=Ve.exec(t.slice(r,r+2));return n?(e.V=+n[0],r+n[0].length):-1}function $5(e,t,r){var n=Ve.exec(t.slice(r,r+2));return n?(e.W=+n[0],r+n[0].length):-1}function e1(e,t,r){var n=Ve.exec(t.slice(r,r+4));return n?(e.y=+n[0],r+n[0].length):-1}function t1(e,t,r){var n=Ve.exec(t.slice(r,r+2));return n?(e.y=+n[0]+(+n[0]>68?1900:2e3),r+n[0].length):-1}function k5(e,t,r){var n=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(r,r+6));return n?(e.Z=n[1]?0:-(n[2]+(n[3]||"00")),r+n[0].length):-1}function T5(e,t,r){var n=Ve.exec(t.slice(r,r+1));return n?(e.q=n[0]*3-3,r+n[0].length):-1}function C5(e,t,r){var n=Ve.exec(t.slice(r,r+2));return n?(e.m=n[0]-1,r+n[0].length):-1}function r1(e,t,r){var n=Ve.exec(t.slice(r,r+2));return n?(e.d=+n[0],r+n[0].length):-1}function j5(e,t,r){var n=Ve.exec(t.slice(r,r+3));return n?(e.m=0,e.d=+n[0],r+n[0].length):-1}function n1(e,t,r){var n=Ve.exec(t.slice(r,r+2));return n?(e.H=+n[0],r+n[0].length):-1}function M5(e,t,r){var n=Ve.exec(t.slice(r,r+2));return n?(e.M=+n[0],r+n[0].length):-1}function I5(e,t,r){var n=Ve.exec(t.slice(r,r+2));return n?(e.S=+n[0],r+n[0].length):-1}function N5(e,t,r){var n=Ve.exec(t.slice(r,r+3));return n?(e.L=+n[0],r+n[0].length):-1}function D5(e,t,r){var n=Ve.exec(t.slice(r,r+6));return n?(e.L=Math.floor(n[0]/1e3),r+n[0].length):-1}function R5(e,t,r){var n=x5.exec(t.slice(r,r+1));return n?r+n[0].length:-1}function L5(e,t,r){var n=Ve.exec(t.slice(r));return n?(e.Q=+n[0],r+n[0].length):-1}function B5(e,t,r){var n=Ve.exec(t.slice(r));return n?(e.s=+n[0],r+n[0].length):-1}function i1(e,t){return ue(e.getDate(),t,2)}function z5(e,t){return ue(e.getHours(),t,2)}function F5(e,t){return ue(e.getHours()%12||12,t,2)}function U5(e,t){return ue(1+Ou.count(Dr(e),e),t,3)}function QO(e,t){return ue(e.getMilliseconds(),t,3)}function W5(e,t){return QO(e,t)+"000"}function H5(e,t){return ue(e.getMonth()+1,t,2)}function K5(e,t){return ue(e.getMinutes(),t,2)}function V5(e,t){return ue(e.getSeconds(),t,2)}function G5(e){var t=e.getDay();return t===0?7:t}function q5(e,t){return ue(jc.count(Dr(e)-1,e),t,2)}function ZO(e){var t=e.getDay();return t>=4||t===0?Xi(e):Xi.ceil(e)}function X5(e,t){return e=ZO(e),ue(Xi.count(Dr(e),e)+(Dr(e).getDay()===4),t,2)}function Y5(e){return e.getDay()}function Q5(e,t){return ue(_s.count(Dr(e)-1,e),t,2)}function Z5(e,t){return ue(e.getFullYear()%100,t,2)}function J5(e,t){return e=ZO(e),ue(e.getFullYear()%100,t,2)}function e6(e,t){return ue(e.getFullYear()%1e4,t,4)}function t6(e,t){var r=e.getDay();return e=r>=4||r===0?Xi(e):Xi.ceil(e),ue(e.getFullYear()%1e4,t,4)}function r6(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+ue(t/60|0,"0",2)+ue(t%60,"0",2)}function o1(e,t){return ue(e.getUTCDate(),t,2)}function n6(e,t){return ue(e.getUTCHours(),t,2)}function i6(e,t){return ue(e.getUTCHours()%12||12,t,2)}function o6(e,t){return ue(1+Cc.count(Rr(e),e),t,3)}function JO(e,t){return ue(e.getUTCMilliseconds(),t,3)}function a6(e,t){return JO(e,t)+"000"}function u6(e,t){return ue(e.getUTCMonth()+1,t,2)}function l6(e,t){return ue(e.getUTCMinutes(),t,2)}function s6(e,t){return ue(e.getUTCSeconds(),t,2)}function c6(e){var t=e.getUTCDay();return t===0?7:t}function f6(e,t){return ue(Mc.count(Rr(e)-1,e),t,2)}function e_(e){var t=e.getUTCDay();return t>=4||t===0?Yi(e):Yi.ceil(e)}function d6(e,t){return e=e_(e),ue(Yi.count(Rr(e),e)+(Rr(e).getUTCDay()===4),t,2)}function p6(e){return e.getUTCDay()}function h6(e,t){return ue(Ps.count(Rr(e)-1,e),t,2)}function v6(e,t){return ue(e.getUTCFullYear()%100,t,2)}function y6(e,t){return e=e_(e),ue(e.getUTCFullYear()%100,t,2)}function m6(e,t){return ue(e.getUTCFullYear()%1e4,t,4)}function g6(e,t){var r=e.getUTCDay();return e=r>=4||r===0?Yi(e):Yi.ceil(e),ue(e.getUTCFullYear()%1e4,t,4)}function b6(){return"+0000"}function a1(){return"%"}function u1(e){return+e}function l1(e){return Math.floor(+e/1e3)}var ai,t_,r_;w6({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 w6(e){return ai=w5(e),t_=ai.format,ai.parse,r_=ai.utcFormat,ai.utcParse,ai}function x6(e){return new Date(e)}function S6(e){return e instanceof Date?+e:+new Date(+e)}function ay(e,t,r,n,i,o,a,u,l,s){var f=Vv(),c=f.invert,d=f.domain,p=s(".%L"),h=s(":%S"),v=s("%I:%M"),g=s("%I %p"),m=s("%a %d"),y=s("%b %d"),b=s("%B"),S=s("%Y");function w(x){return(l(x)t(i/(e.length-1)))},r.quantiles=function(n){return Array.from({length:n+1},(i,o)=>fF(e,o/n))},r.copy=function(){return a_(t).domain(e)},Fr.apply(r,arguments)}function Nc(){var e=0,t=.5,r=1,n=1,i,o,a,u,l,s=ut,f,c=!1,d;function p(v){return isNaN(v=+v)?d:(v=.5+((v=+f(v))-o)*(n*vt}var T6=k6,C6=c_,j6=T6,M6=mo;function I6(e){return e&&e.length?C6(e,M6,j6):void 0}var N6=I6;const Dc=ve(N6);function D6(e,t){return ee.e^o.s<0?1:-1;for(n=o.d.length,i=e.d.length,t=0,r=ne.d[t]^o.s<0?1:-1;return n===i?0:n>i^o.s<0?1:-1};V.decimalPlaces=V.dp=function(){var e=this,t=e.d.length-1,r=(t-e.e)*ge;if(t=e.d[t],t)for(;t%10==0;t/=10)r--;return r<0?0:r};V.dividedBy=V.div=function(e){return kr(this,new this.constructor(e))};V.dividedToIntegerBy=V.idiv=function(e){var t=this,r=t.constructor;return de(kr(t,new r(e),0,1),r.precision)};V.equals=V.eq=function(e){return!this.cmp(e)};V.exponent=function(){return Ie(this)};V.greaterThan=V.gt=function(e){return this.cmp(e)>0};V.greaterThanOrEqualTo=V.gte=function(e){return this.cmp(e)>=0};V.isInteger=V.isint=function(){return this.e>this.d.length-2};V.isNegative=V.isneg=function(){return this.s<0};V.isPositive=V.ispos=function(){return this.s>0};V.isZero=function(){return this.s===0};V.lessThan=V.lt=function(e){return this.cmp(e)<0};V.lessThanOrEqualTo=V.lte=function(e){return this.cmp(e)<1};V.logarithm=V.log=function(e){var t,r=this,n=r.constructor,i=n.precision,o=i+5;if(e===void 0)e=new n(10);else if(e=new n(e),e.s<1||e.eq(_t))throw Error(Kt+"NaN");if(r.s<1)throw Error(Kt+(r.s?"NaN":"-Infinity"));return r.eq(_t)?new n(0):(xe=!1,t=kr(Ba(r,o),Ba(e,o),o),xe=!0,de(t,i))};V.minus=V.sub=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?h_(t,e):d_(t,(e.s=-e.s,e))};V.modulo=V.mod=function(e){var t,r=this,n=r.constructor,i=n.precision;if(e=new n(e),!e.s)throw Error(Kt+"NaN");return r.s?(xe=!1,t=kr(r,e,0,1).times(e),xe=!0,r.minus(t)):de(new n(r),i)};V.naturalExponential=V.exp=function(){return p_(this)};V.naturalLogarithm=V.ln=function(){return Ba(this)};V.negated=V.neg=function(){var e=new this.constructor(this);return e.s=-e.s||0,e};V.plus=V.add=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?d_(t,e):h_(t,(e.s=-e.s,e))};V.precision=V.sd=function(e){var t,r,n,i=this;if(e!==void 0&&e!==!!e&&e!==1&&e!==0)throw Error(Vn+e);if(t=Ie(i)+1,n=i.d.length-1,r=n*ge+1,n=i.d[n],n){for(;n%10==0;n/=10)r--;for(n=i.d[0];n>=10;n/=10)r++}return e&&t>r?t:r};V.squareRoot=V.sqrt=function(){var e,t,r,n,i,o,a,u=this,l=u.constructor;if(u.s<1){if(!u.s)return new l(0);throw Error(Kt+"NaN")}for(e=Ie(u),xe=!1,i=Math.sqrt(+u),i==0||i==1/0?(t=dr(u.d),(t.length+e)%2==0&&(t+="0"),i=Math.sqrt(t),e=xo((e+1)/2)-(e<0||e%2),i==1/0?t="5e"+e:(t=i.toExponential(),t=t.slice(0,t.indexOf("e")+1)+e),n=new l(t)):n=new l(i.toString()),r=l.precision,i=a=r+3;;)if(o=n,n=o.plus(kr(u,o,a+2)).times(.5),dr(o.d).slice(0,a)===(t=dr(n.d)).slice(0,a)){if(t=t.slice(a-3,a+1),i==a&&t=="4999"){if(de(o,r+1,0),o.times(o).eq(u)){n=o;break}}else if(t!="9999")break;a+=4}return xe=!0,de(n,r)};V.times=V.mul=function(e){var t,r,n,i,o,a,u,l,s,f=this,c=f.constructor,d=f.d,p=(e=new c(e)).d;if(!f.s||!e.s)return new c(0);for(e.s*=f.s,r=f.e+e.e,l=d.length,s=p.length,l=0;){for(t=0,i=l+n;i>n;)u=o[i]+p[n]*d[i-n-1]+t,o[i--]=u%Ue|0,t=u/Ue|0;o[i]=(o[i]+t)%Ue|0}for(;!o[--a];)o.pop();return t?++r:o.shift(),e.d=o,e.e=r,xe?de(e,c.precision):e};V.toDecimalPlaces=V.todp=function(e,t){var r=this,n=r.constructor;return r=new n(r),e===void 0?r:(mr(e,0,wo),t===void 0?t=n.rounding:mr(t,0,8),de(r,e+Ie(r)+1,t))};V.toExponential=function(e,t){var r,n=this,i=n.constructor;return e===void 0?r=Zn(n,!0):(mr(e,0,wo),t===void 0?t=i.rounding:mr(t,0,8),n=de(new i(n),e+1,t),r=Zn(n,!0,e+1)),r};V.toFixed=function(e,t){var r,n,i=this,o=i.constructor;return e===void 0?Zn(i):(mr(e,0,wo),t===void 0?t=o.rounding:mr(t,0,8),n=de(new o(i),e+Ie(i)+1,t),r=Zn(n.abs(),!1,e+Ie(n)+1),i.isneg()&&!i.isZero()?"-"+r:r)};V.toInteger=V.toint=function(){var e=this,t=e.constructor;return de(new t(e),Ie(e)+1,t.rounding)};V.toNumber=function(){return+this};V.toPower=V.pow=function(e){var t,r,n,i,o,a,u=this,l=u.constructor,s=12,f=+(e=new l(e));if(!e.s)return new l(_t);if(u=new l(u),!u.s){if(e.s<1)throw Error(Kt+"Infinity");return u}if(u.eq(_t))return u;if(n=l.precision,e.eq(_t))return de(u,n);if(t=e.e,r=e.d.length-1,a=t>=r,o=u.s,a){if((r=f<0?-f:f)<=f_){for(i=new l(_t),t=Math.ceil(n/ge+4),xe=!1;r%2&&(i=i.times(u),f1(i.d,t)),r=xo(r/2),r!==0;)u=u.times(u),f1(u.d,t);return xe=!0,e.s<0?new l(_t).div(i):de(i,n)}}else if(o<0)throw Error(Kt+"NaN");return o=o<0&&e.d[Math.max(t,r)]&1?-1:1,u.s=1,xe=!1,i=e.times(Ba(u,n+s)),xe=!0,i=p_(i),i.s=o,i};V.toPrecision=function(e,t){var r,n,i=this,o=i.constructor;return e===void 0?(r=Ie(i),n=Zn(i,r<=o.toExpNeg||r>=o.toExpPos)):(mr(e,1,wo),t===void 0?t=o.rounding:mr(t,0,8),i=de(new o(i),e,t),r=Ie(i),n=Zn(i,e<=r||r<=o.toExpNeg,e)),n};V.toSignificantDigits=V.tosd=function(e,t){var r=this,n=r.constructor;return e===void 0?(e=n.precision,t=n.rounding):(mr(e,1,wo),t===void 0?t=n.rounding:mr(t,0,8)),de(new n(r),e,t)};V.toString=V.valueOf=V.val=V.toJSON=V[Symbol.for("nodejs.util.inspect.custom")]=function(){var e=this,t=Ie(e),r=e.constructor;return Zn(e,t<=r.toExpNeg||t>=r.toExpPos)};function d_(e,t){var r,n,i,o,a,u,l,s,f=e.constructor,c=f.precision;if(!e.s||!t.s)return t.s||(t=new f(e)),xe?de(t,c):t;if(l=e.d,s=t.d,a=e.e,i=t.e,l=l.slice(),o=a-i,o){for(o<0?(n=l,o=-o,u=s.length):(n=s,i=a,u=l.length),a=Math.ceil(c/ge),u=a>u?a+1:u+1,o>u&&(o=u,n.length=1),n.reverse();o--;)n.push(0);n.reverse()}for(u=l.length,o=s.length,u-o<0&&(o=u,n=s,s=l,l=n),r=0;o;)r=(l[--o]=l[o]+s[o]+r)/Ue|0,l[o]%=Ue;for(r&&(l.unshift(r),++i),u=l.length;l[--u]==0;)l.pop();return t.d=l,t.e=i,xe?de(t,c):t}function mr(e,t,r){if(e!==~~e||er)throw Error(Vn+e)}function dr(e){var t,r,n,i=e.length-1,o="",a=e[0];if(i>0){for(o+=a,t=1;ta?1:-1;else for(u=l=0;ui[u]?1:-1;break}return l}function r(n,i,o){for(var a=0;o--;)n[o]-=a,a=n[o]1;)n.shift()}return function(n,i,o,a){var u,l,s,f,c,d,p,h,v,g,m,y,b,S,w,x,O,_,P=n.constructor,E=n.s==i.s?1:-1,A=n.d,k=i.d;if(!n.s)return new P(n);if(!i.s)throw Error(Kt+"Division by zero");for(l=n.e-i.e,O=k.length,w=A.length,p=new P(E),h=p.d=[],s=0;k[s]==(A[s]||0);)++s;if(k[s]>(A[s]||0)&&--l,o==null?y=o=P.precision:a?y=o+(Ie(n)-Ie(i))+1:y=o,y<0)return new P(0);if(y=y/ge+2|0,s=0,O==1)for(f=0,k=k[0],y++;(s1&&(k=e(k,f),A=e(A,f),O=k.length,w=A.length),S=O,v=A.slice(0,O),g=v.length;g=Ue/2&&++x;do f=0,u=t(k,v,O,g),u<0?(m=v[0],O!=g&&(m=m*Ue+(v[1]||0)),f=m/x|0,f>1?(f>=Ue&&(f=Ue-1),c=e(k,f),d=c.length,g=v.length,u=t(c,v,d,g),u==1&&(f--,r(c,O16)throw Error(sy+Ie(e));if(!e.s)return new f(_t);for(t==null?(xe=!1,u=c):u=t,a=new f(.03125);e.abs().gte(.1);)e=e.times(a),s+=5;for(n=Math.log(In(2,s))/Math.LN10*2+5|0,u+=n,r=i=o=new f(_t),f.precision=u;;){if(i=de(i.times(e),u),r=r.times(++l),a=o.plus(kr(i,r,u)),dr(a.d).slice(0,u)===dr(o.d).slice(0,u)){for(;s--;)o=de(o.times(o),u);return f.precision=c,t==null?(xe=!0,de(o,c)):o}o=a}}function Ie(e){for(var t=e.e*ge,r=e.d[0];r>=10;r/=10)t++;return t}function Vf(e,t,r){if(t>e.LN10.sd())throw xe=!0,r&&(e.precision=r),Error(Kt+"LN10 precision limit exceeded");return de(new e(e.LN10),t)}function Xr(e){for(var t="";e--;)t+="0";return t}function Ba(e,t){var r,n,i,o,a,u,l,s,f,c=1,d=10,p=e,h=p.d,v=p.constructor,g=v.precision;if(p.s<1)throw Error(Kt+(p.s?"NaN":"-Infinity"));if(p.eq(_t))return new v(0);if(t==null?(xe=!1,s=g):s=t,p.eq(10))return t==null&&(xe=!0),Vf(v,s);if(s+=d,v.precision=s,r=dr(h),n=r.charAt(0),o=Ie(p),Math.abs(o)<15e14){for(;n<7&&n!=1||n==1&&r.charAt(1)>3;)p=p.times(e),r=dr(p.d),n=r.charAt(0),c++;o=Ie(p),n>1?(p=new v("0."+r),o++):p=new v(n+"."+r.slice(1))}else return l=Vf(v,s+2,g).times(o+""),p=Ba(new v(n+"."+r.slice(1)),s-d).plus(l),v.precision=g,t==null?(xe=!0,de(p,g)):p;for(u=a=p=kr(p.minus(_t),p.plus(_t),s),f=de(p.times(p),s),i=3;;){if(a=de(a.times(f),s),l=u.plus(kr(a,new v(i),s)),dr(l.d).slice(0,s)===dr(u.d).slice(0,s))return u=u.times(2),o!==0&&(u=u.plus(Vf(v,s+2,g).times(o+""))),u=kr(u,new v(c),s),v.precision=g,t==null?(xe=!0,de(u,g)):u;u=l,i+=2}}function c1(e,t){var r,n,i;for((r=t.indexOf("."))>-1&&(t=t.replace(".","")),(n=t.search(/e/i))>0?(r<0&&(r=n),r+=+t.slice(n+1),t=t.substring(0,n)):r<0&&(r=t.length),n=0;t.charCodeAt(n)===48;)++n;for(i=t.length;t.charCodeAt(i-1)===48;)--i;if(t=t.slice(n,i),t){if(i-=n,r=r-n-1,e.e=xo(r/ge),e.d=[],n=(r+1)%ge,r<0&&(n+=ge),nAs||e.e<-As))throw Error(sy+r)}else e.s=0,e.e=0,e.d=[0];return e}function de(e,t,r){var n,i,o,a,u,l,s,f,c=e.d;for(a=1,o=c[0];o>=10;o/=10)a++;if(n=t-a,n<0)n+=ge,i=t,s=c[f=0];else{if(f=Math.ceil((n+1)/ge),o=c.length,f>=o)return e;for(s=o=c[f],a=1;o>=10;o/=10)a++;n%=ge,i=n-ge+a}if(r!==void 0&&(o=In(10,a-i-1),u=s/o%10|0,l=t<0||c[f+1]!==void 0||s%o,l=r<4?(u||l)&&(r==0||r==(e.s<0?3:2)):u>5||u==5&&(r==4||l||r==6&&(n>0?i>0?s/In(10,a-i):0:c[f-1])%10&1||r==(e.s<0?8:7))),t<1||!c[0])return l?(o=Ie(e),c.length=1,t=t-o-1,c[0]=In(10,(ge-t%ge)%ge),e.e=xo(-t/ge)||0):(c.length=1,c[0]=e.e=e.s=0),e;if(n==0?(c.length=f,o=1,f--):(c.length=f+1,o=In(10,ge-n),c[f]=i>0?(s/In(10,a-i)%In(10,i)|0)*o:0),l)for(;;)if(f==0){(c[0]+=o)==Ue&&(c[0]=1,++e.e);break}else{if(c[f]+=o,c[f]!=Ue)break;c[f--]=0,o=1}for(n=c.length;c[--n]===0;)c.pop();if(xe&&(e.e>As||e.e<-As))throw Error(sy+Ie(e));return e}function h_(e,t){var r,n,i,o,a,u,l,s,f,c,d=e.constructor,p=d.precision;if(!e.s||!t.s)return t.s?t.s=-t.s:t=new d(e),xe?de(t,p):t;if(l=e.d,c=t.d,n=t.e,s=e.e,l=l.slice(),a=s-n,a){for(f=a<0,f?(r=l,a=-a,u=c.length):(r=c,n=s,u=l.length),i=Math.max(Math.ceil(p/ge),u)+2,a>i&&(a=i,r.length=1),r.reverse(),i=a;i--;)r.push(0);r.reverse()}else{for(i=l.length,u=c.length,f=i0;--i)l[u++]=0;for(i=c.length;i>a;){if(l[--i]0?o=o.charAt(0)+"."+o.slice(1)+Xr(n):a>1&&(o=o.charAt(0)+"."+o.slice(1)),o=o+(i<0?"e":"e+")+i):i<0?(o="0."+Xr(-i-1)+o,r&&(n=r-a)>0&&(o+=Xr(n))):i>=a?(o+=Xr(i+1-a),r&&(n=r-i-1)>0&&(o=o+"."+Xr(n))):((n=i+1)0&&(i+1===a&&(o+="."),o+=Xr(n))),e.s<0?"-"+o:o}function f1(e,t){if(e.length>t)return e.length=t,!0}function v_(e){var t,r,n;function i(o){var a=this;if(!(a instanceof i))return new i(o);if(a.constructor=i,o instanceof i){a.s=o.s,a.e=o.e,a.d=(o=o.d)?o.slice():o;return}if(typeof o=="number"){if(o*0!==0)throw Error(Vn+o);if(o>0)a.s=1;else if(o<0)o=-o,a.s=-1;else{a.s=0,a.e=0,a.d=[0];return}if(o===~~o&&o<1e7){a.e=0,a.d=[o];return}return c1(a,o.toString())}else if(typeof o!="string")throw Error(Vn+o);if(o.charCodeAt(0)===45?(o=o.slice(1),a.s=-1):a.s=1,iU.test(o))c1(a,o);else throw Error(Vn+o)}if(i.prototype=V,i.ROUND_UP=0,i.ROUND_DOWN=1,i.ROUND_CEIL=2,i.ROUND_FLOOR=3,i.ROUND_HALF_UP=4,i.ROUND_HALF_DOWN=5,i.ROUND_HALF_EVEN=6,i.ROUND_HALF_CEIL=7,i.ROUND_HALF_FLOOR=8,i.clone=v_,i.config=i.set=oU,e===void 0&&(e={}),e)for(n=["precision","rounding","toExpNeg","toExpPos","LN10"],t=0;t=i[t+1]&&n<=i[t+2])this[r]=n;else throw Error(Vn+r+": "+n);if((n=e[r="LN10"])!==void 0)if(n==Math.LN10)this[r]=new this(n);else throw Error(Vn+r+": "+n);return this}var cy=v_(nU);_t=new cy(1);const fe=cy;function aU(e){return cU(e)||sU(e)||lU(e)||uU()}function uU(){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 lU(e,t){if(e){if(typeof e=="string")return zp(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return zp(e,t)}}function sU(e){if(typeof Symbol<"u"&&Symbol.iterator in Object(e))return Array.from(e)}function cU(e){if(Array.isArray(e))return zp(e)}function zp(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r=t?r.apply(void 0,i):e(t-a,d1(function(){for(var u=arguments.length,l=new Array(u),s=0;se.length)&&(t=e.length);for(var r=0,n=new Array(t);r"u"||!(Symbol.iterator in Object(e)))){var r=[],n=!0,i=!1,o=void 0;try{for(var a=e[Symbol.iterator](),u;!(n=(u=a.next()).done)&&(r.push(u.value),!(t&&r.length===t));n=!0);}catch(l){i=!0,o=l}finally{try{!n&&a.return!=null&&a.return()}finally{if(i)throw o}}return r}}function PU(e){if(Array.isArray(e))return e}function w_(e){var t=za(e,2),r=t[0],n=t[1],i=r,o=n;return r>n&&(i=n,o=r),[i,o]}function x_(e,t,r){if(e.lte(0))return new fe(0);var n=zc.getDigitCount(e.toNumber()),i=new fe(10).pow(n),o=e.div(i),a=n!==1?.05:.1,u=new fe(Math.ceil(o.div(a).toNumber())).add(r).mul(a),l=u.mul(i);return t?l:new fe(Math.ceil(l))}function AU(e,t,r){var n=1,i=new fe(e);if(!i.isint()&&r){var o=Math.abs(e);o<1?(n=new fe(10).pow(zc.getDigitCount(e)-1),i=new fe(Math.floor(i.div(n).toNumber())).mul(n)):o>1&&(i=new fe(Math.floor(e)))}else e===0?i=new fe(Math.floor((t-1)/2)):r||(i=new fe(Math.floor(e)));var a=Math.floor((t-1)/2),u=hU(pU(function(l){return i.add(new fe(l-a).mul(n)).toNumber()}),Fp);return u(0,t)}function S_(e,t,r,n){var i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:0;if(!Number.isFinite((t-e)/(r-1)))return{step:new fe(0),tickMin:new fe(0),tickMax:new fe(0)};var o=x_(new fe(t).sub(e).div(r-1),n,i),a;e<=0&&t>=0?a=new fe(0):(a=new fe(e).add(t).div(2),a=a.sub(new fe(a).mod(o)));var u=Math.ceil(a.sub(e).div(o).toNumber()),l=Math.ceil(new fe(t).sub(a).div(o).toNumber()),s=u+l+1;return s>r?S_(e,t,r,n,i+1):(s0?l+(r-s):l,u=t>0?u:u+(r-s)),{step:o,tickMin:a.sub(new fe(u).mul(o)),tickMax:a.add(new fe(l).mul(o))})}function EU(e){var t=za(e,2),r=t[0],n=t[1],i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:6,o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,a=Math.max(i,2),u=w_([r,n]),l=za(u,2),s=l[0],f=l[1];if(s===-1/0||f===1/0){var c=f===1/0?[s].concat(Wp(Fp(0,i-1).map(function(){return 1/0}))):[].concat(Wp(Fp(0,i-1).map(function(){return-1/0})),[f]);return r>n?Up(c):c}if(s===f)return AU(s,i,o);var d=S_(s,f,a,o),p=d.step,h=d.tickMin,v=d.tickMax,g=zc.rangeStep(h,v.add(new fe(.1).mul(p)),p);return r>n?Up(g):g}function $U(e,t){var r=za(e,2),n=r[0],i=r[1],o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,a=w_([n,i]),u=za(a,2),l=u[0],s=u[1];if(l===-1/0||s===1/0)return[n,i];if(l===s)return[l];var f=Math.max(t,2),c=x_(new fe(s).sub(l).div(f-1),o,0),d=[].concat(Wp(zc.rangeStep(new fe(l),new fe(s).sub(new fe(.99).mul(c)),c)),[s]);return n>i?Up(d):d}var kU=g_(EU),TU=g_($U),CU=["offset","layout","width","dataKey","data","dataPointFormatter","xAxis","yAxis"];function Es(){return Es=Object.assign?Object.assign.bind():function(e){for(var t=1;te.length)&&(t=e.length);for(var r=0,n=new Array(t);r=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function LU(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,o;for(o=0;o=0)&&(r[i]=e[i]);return r}function _u(e){var t=e.offset,r=e.layout,n=e.width,i=e.dataKey,o=e.data,a=e.dataPointFormatter,u=e.xAxis,l=e.yAxis,s=RU(e,CU),f=ne(s),c=o.map(function(d,p){var h=a(d,i),v=h.x,g=h.y,m=h.value,y=h.errorVal;if(!y)return null;var b=[],S,w;if(Array.isArray(y)){var x=jU(y,2);S=x[0],w=x[1]}else S=w=y;if(r==="vertical"){var O=u.scale,_=g+t,P=_+n,E=_-n,A=O(m-S),k=O(m+w);b.push({x1:k,y1:P,x2:k,y2:E}),b.push({x1:A,y1:_,x2:k,y2:_}),b.push({x1:A,y1:P,x2:A,y2:E})}else if(r==="horizontal"){var j=l.scale,N=v+t,D=N-n,B=N+n,R=j(m-S),C=j(m+w);b.push({x1:D,y1:C,x2:B,y2:C}),b.push({x1:N,y1:R,x2:N,y2:C}),b.push({x1:D,y1:R,x2:B,y2:R})}return $.createElement(Ce,Es({className:"recharts-errorBar",key:"bar-".concat(p)},f),b.map(function(I,F){return $.createElement("line",Es({},I,{key:"line-".concat(F)}))}))});return $.createElement(Ce,{className:"recharts-errorBars"},c)}_u.defaultProps={stroke:"black",strokeWidth:1.5,width:5,offset:0,layout:"horizontal"};_u.displayName="ErrorBar";function Fa(e){"@babel/helpers - typeof";return Fa=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},Fa(e)}function h1(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Gf(e){for(var t=1;te.length)&&(t=e.length);for(var r=0,n=new Array(t);r1&&arguments[1]!==void 0?arguments[1]:[],i=arguments.length>2?arguments[2]:void 0,o=arguments.length>3?arguments[3]:void 0,a=-1,u=(r=n==null?void 0:n.length)!==null&&r!==void 0?r:0;if(u<=1)return 0;if(o&&o.axisType==="angleAxis"&&Math.abs(Math.abs(o.range[1]-o.range[0])-360)<=1e-6)for(var l=o.range,s=0;s0?i[s-1].coordinate:i[u-1].coordinate,c=i[s].coordinate,d=s>=u-1?i[0].coordinate:i[s+1].coordinate,p=void 0;if(rr(c-f)!==rr(d-c)){var h=[];if(rr(d-c)===rr(l[1]-l[0])){p=d;var v=c+l[1]-l[0];h[0]=Math.min(v,(v+f)/2),h[1]=Math.max(v,(v+f)/2)}else{p=f;var g=d+l[1]-l[0];h[0]=Math.min(c,(g+c)/2),h[1]=Math.max(c,(g+c)/2)}var m=[Math.min(c,(p+c)/2),Math.max(c,(p+c)/2)];if(t>m[0]&&t<=m[1]||t>=h[0]&&t<=h[1]){a=i[s].index;break}}else{var y=Math.min(f,d),b=Math.max(f,d);if(t>(y+c)/2&&t<=(b+c)/2){a=i[s].index;break}}}else for(var S=0;S0&&S(n[S].coordinate+n[S-1].coordinate)/2&&t<=(n[S].coordinate+n[S+1].coordinate)/2||S===u-1&&t>(n[S].coordinate+n[S-1].coordinate)/2){a=n[S].index;break}return a},fy=function(t){var r=t,n=r.type.displayName,i=t.props,o=i.stroke,a=i.fill,u;switch(n){case"Line":u=o;break;case"Area":case"Radar":u=o&&o!=="none"?o:a;break;default:u=a;break}return u},XU=function(t){var r=t.barSize,n=t.stackGroups,i=n===void 0?{}:n;if(!i)return{};for(var o={},a=Object.keys(i),u=0,l=a.length;u=0});if(g&&g.length){var m=g[0].props.barSize,y=g[0].props[v];o[y]||(o[y]=[]),o[y].push({item:g[0],stackList:g.slice(1),barSize:ie(m)?r:m})}}return o},YU=function(t){var r=t.barGap,n=t.barCategoryGap,i=t.bandSize,o=t.sizeList,a=o===void 0?[]:o,u=t.maxBarSize,l=a.length;if(l<1)return null;var s=Bi(r,i,0,!0),f,c=[];if(a[0].barSize===+a[0].barSize){var d=!1,p=i/l,h=a.reduce(function(S,w){return S+w.barSize||0},0);h+=(l-1)*s,h>=i&&(h-=(l-1)*s,s=0),h>=i&&p>0&&(d=!0,p*=.9,h=l*p);var v=(i-h)/2>>0,g={offset:v-s,size:0};f=a.reduce(function(S,w){var x={item:w.item,position:{offset:g.offset+g.size+s,size:d?p:w.barSize}},O=[].concat(y1(S),[x]);return g=O[O.length-1].position,w.stackList&&w.stackList.length&&w.stackList.forEach(function(_){O.push({item:_,position:g})}),O},c)}else{var m=Bi(n,i,0,!0);i-2*m-(l-1)*s<=0&&(s=0);var y=(i-2*m-(l-1)*s)/l;y>1&&(y>>=0);var b=u===+u?Math.min(y,u):y;f=a.reduce(function(S,w,x){var O=[].concat(y1(S),[{item:w.item,position:{offset:m+(y+s)*x+(y-b)/2,size:b}}]);return w.stackList&&w.stackList.length&&w.stackList.forEach(function(_){O.push({item:_,position:O[O.length-1].position})}),O},c)}return f},QU=function(t,r,n,i){var o=n.children,a=n.width,u=n.margin,l=a-(u.left||0)-(u.right||0),s=O_({children:o,legendWidth:l});if(s){var f=i||{},c=f.width,d=f.height,p=s.align,h=s.verticalAlign,v=s.layout;if((v==="vertical"||v==="horizontal"&&h==="middle")&&p!=="center"&&U(t[p]))return Rt(Rt({},t),{},Ci({},p,t[p]+(c||0)));if((v==="horizontal"||v==="vertical"&&p==="center")&&h!=="middle"&&U(t[h]))return Rt(Rt({},t),{},Ci({},h,t[h]+(d||0)))}return t},ZU=function(t,r,n){return ie(r)?!0:t==="horizontal"?r==="yAxis":t==="vertical"||n==="x"?r==="xAxis":n==="y"?r==="yAxis":!0},__=function(t,r,n,i,o){var a=r.props.children,u=Ut(a,_u).filter(function(s){return ZU(i,o,s.props.direction)});if(u&&u.length){var l=u.map(function(s){return s.props.dataKey});return t.reduce(function(s,f){var c=$t(f,n,0),d=Array.isArray(c)?[Rc(c),Dc(c)]:[c,c],p=l.reduce(function(h,v){var g=$t(f,v,0),m=d[0]-Math.abs(Array.isArray(g)?g[0]:g),y=d[1]+Math.abs(Array.isArray(g)?g[1]:g);return[Math.min(m,h[0]),Math.max(y,h[1])]},[1/0,-1/0]);return[Math.min(p[0],s[0]),Math.max(p[1],s[1])]},[1/0,-1/0])}return null},JU=function(t,r,n,i,o){var a=r.map(function(u){return __(t,u,n,o,i)}).filter(function(u){return!ie(u)});return a&&a.length?a.reduce(function(u,l){return[Math.min(u[0],l[0]),Math.max(u[1],l[1])]},[1/0,-1/0]):null},P_=function(t,r,n,i,o){var a=r.map(function(l){var s=l.props.dataKey;return n==="number"&&s&&__(t,l,s,i)||ia(t,s,n,o)});if(n==="number")return a.reduce(function(l,s){return[Math.min(l[0],s[0]),Math.max(l[1],s[1])]},[1/0,-1/0]);var u={};return a.reduce(function(l,s){for(var f=0,c=s.length;f=2?rr(u[0]-u[1])*2*s:s,r&&(t.ticks||t.niceTicks)){var f=(t.ticks||t.niceTicks).map(function(c){var d=o?o.indexOf(c):c;return{coordinate:i(d)+s,value:c,offset:s}});return f.filter(function(c){return!mu(c.coordinate)})}return t.isCategorical&&t.categoricalDomain?t.categoricalDomain.map(function(c,d){return{coordinate:i(c)+s,value:c,index:d,offset:s}}):i.ticks&&!n?i.ticks(t.tickCount).map(function(c){return{coordinate:i(c)+s,value:c,offset:s}}):i.domain().map(function(c,d){return{coordinate:i(c)+s,value:o?o[c]:c,index:d,offset:s}})},qf=new WeakMap,il=function(t,r){if(typeof r!="function")return t;qf.has(t)||qf.set(t,new WeakMap);var n=qf.get(t);if(n.has(r))return n.get(r);var i=function(){t.apply(void 0,arguments),r.apply(void 0,arguments)};return n.set(r,i),i},eW=function(t,r,n){var i=t.scale,o=t.type,a=t.layout,u=t.axisType;if(i==="auto")return a==="radial"&&u==="radiusAxis"?{scale:Ia(),realScaleType:"band"}:a==="radial"&&u==="angleAxis"?{scale:Ss(),realScaleType:"linear"}:o==="category"&&r&&(r.indexOf("LineChart")>=0||r.indexOf("AreaChart")>=0||r.indexOf("ComposedChart")>=0&&!n)?{scale:na(),realScaleType:"point"}:o==="category"?{scale:Ia(),realScaleType:"band"}:{scale:Ss(),realScaleType:"linear"};if(yu(i)){var l="scale".concat(Oc(i));return{scale:(s1[l]||na)(),realScaleType:s1[l]?l:"point"}}return te(i)?{scale:i}:{scale:na(),realScaleType:"point"}},g1=1e-4,tW=function(t){var r=t.domain();if(!(!r||r.length<=2)){var n=r.length,i=t.range(),o=Math.min(i[0],i[1])-g1,a=Math.max(i[0],i[1])+g1,u=t(r[0]),l=t(r[n-1]);(ua||la)&&t.domain([r[0],r[n-1]])}},rW=function(t,r){if(!t)return null;for(var n=0,i=t.length;ni)&&(o[1]=i),o[0]>i&&(o[0]=i),o[1]=0?(t[u][n][0]=o,t[u][n][1]=o+l,o=t[u][n][1]):(t[u][n][0]=a,t[u][n][1]=a+l,a=t[u][n][1])}},oW=function(t){var r=t.length;if(!(r<=0))for(var n=0,i=t[0].length;n=0?(t[a][n][0]=o,t[a][n][1]=o+u,o=t[a][n][1]):(t[a][n][0]=0,t[a][n][1]=0)}},aW={sign:iW,expand:rM,none:zi,silhouette:nM,wiggle:iM,positive:oW},uW=function(t,r,n){var i=r.map(function(u){return u.props.dataKey}),o=aW[n],a=tM().keys(i).value(function(u,l){return+$t(u,l,0)}).order(cp).offset(o);return a(t)},lW=function(t,r,n,i,o,a){if(!t)return null;var u=a?r.reverse():r,l={},s=u.reduce(function(c,d){var p=d.props,h=p.stackId,v=p.hide;if(v)return c;var g=d.props[n],m=c[g]||{hasStack:!1,stackGroups:{}};if(Be(h)){var y=m.stackGroups[h]||{numericAxisId:n,cateAxisId:i,items:[]};y.items.push(d),m.hasStack=!0,m.stackGroups[h]=y}else m.stackGroups[gu("_stackId_")]={numericAxisId:n,cateAxisId:i,items:[d]};return Rt(Rt({},c),{},Ci({},g,m))},l),f={};return Object.keys(s).reduce(function(c,d){var p=s[d];if(p.hasStack){var h={};p.stackGroups=Object.keys(p.stackGroups).reduce(function(v,g){var m=p.stackGroups[g];return Rt(Rt({},v),{},Ci({},g,{numericAxisId:n,cateAxisId:i,items:m.items,stackedData:uW(t,m.items,o)}))},h)}return Rt(Rt({},c),{},Ci({},d,p))},f)},sW=function(t,r){var n=r.realScaleType,i=r.type,o=r.tickCount,a=r.originalDomain,u=r.allowDecimals,l=n||r.scale;if(l!=="auto"&&l!=="linear")return null;if(o&&i==="number"&&a&&(a[0]==="auto"||a[1]==="auto")){var s=t.domain();if(!s.length)return null;var f=kU(s,o,u);return t.domain([Rc(f),Dc(f)]),{niceTicks:f}}if(o&&i==="number"){var c=t.domain(),d=TU(c,o,u);return{niceTicks:d}}return null},b1=function(t){var r=t.axis,n=t.ticks,i=t.bandSize,o=t.entry,a=t.index,u=t.dataKey;if(r.type==="category"){if(!r.allowDuplicatedCategory&&r.dataKey&&!ie(o[r.dataKey])){var l=Xl(n,"value",o[r.dataKey]);if(l)return l.coordinate+i/2}return n[a]?n[a].coordinate+i/2:null}var s=$t(o,ie(u)?r.dataKey:u);return ie(s)?null:r.scale(s)},w1=function(t){var r=t.axis,n=t.ticks,i=t.offset,o=t.bandSize,a=t.entry,u=t.index;if(r.type==="category")return n[u]?n[u].coordinate+i:null;var l=$t(a,r.dataKey,r.domain[u]);return ie(l)?null:r.scale(l)-o/2+i},cW=function(t){var r=t.numericAxis,n=r.scale.domain();if(r.type==="number"){var i=Math.min(n[0],n[1]),o=Math.max(n[0],n[1]);return i<=0&&o>=0?0:o<0?o:i}return n[0]},fW=function(t,r){var n=t.props.stackId;if(Be(n)){var i=r[n];if(i){var o=i.items.indexOf(t);return o>=0?i.stackedData[o]:null}}return null},dW=function(t){return t.reduce(function(r,n){return[Rc(n.concat([r[0]]).filter(U)),Dc(n.concat([r[1]]).filter(U))]},[1/0,-1/0])},E_=function(t,r,n){return Object.keys(t).reduce(function(i,o){var a=t[o],u=a.stackedData,l=u.reduce(function(s,f){var c=dW(f.slice(r,n+1));return[Math.min(s[0],c[0]),Math.max(s[1],c[1])]},[1/0,-1/0]);return[Math.min(l[0],i[0]),Math.max(l[1],i[1])]},[1/0,-1/0]).map(function(i){return i===1/0||i===-1/0?0:i})},x1=/^dataMin[\s]*-[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,S1=/^dataMax[\s]*\+[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,Vp=function(t,r,n){if(te(t))return t(r,n);if(!Array.isArray(t))return r;var i=[];if(U(t[0]))i[0]=n?t[0]:Math.min(t[0],r[0]);else if(x1.test(t[0])){var o=+x1.exec(t[0])[1];i[0]=r[0]-o}else te(t[0])?i[0]=t[0](r[0]):i[0]=r[0];if(U(t[1]))i[1]=n?t[1]:Math.max(t[1],r[1]);else if(S1.test(t[1])){var a=+S1.exec(t[1])[1];i[1]=r[1]+a}else te(t[1])?i[1]=t[1](r[1]):i[1]=r[1];return i},$s=function(t,r,n){if(t&&t.scale&&t.scale.bandwidth){var i=t.scale.bandwidth();if(!n||i>0)return i}if(t&&r&&r.length>=2){for(var o=Lv(r,function(c){return c.coordinate}),a=1/0,u=1,l=o.length;ua&&(s=2*Math.PI-s),{radius:u,angle:yW(s),angleInRadian:s}},bW=function(t){var r=t.startAngle,n=t.endAngle,i=Math.floor(r/360),o=Math.floor(n/360),a=Math.min(i,o);return{startAngle:r-a*360,endAngle:n-a*360}},wW=function(t,r){var n=r.startAngle,i=r.endAngle,o=Math.floor(n/360),a=Math.floor(i/360),u=Math.min(o,a);return t+u*360},A1=function(t,r){var n=t.x,i=t.y,o=gW({x:n,y:i},r),a=o.radius,u=o.angle,l=r.innerRadius,s=r.outerRadius;if(as)return!1;if(a===0)return!0;var f=bW(r),c=f.startAngle,d=f.endAngle,p=u,h;if(c<=d){for(;p>d;)p-=360;for(;p=c&&p<=d}else{for(;p>c;)p-=360;for(;p=d&&p<=c}return h?P1(P1({},r),{},{radius:a,angle:wW(p,r)}):null};function Ha(e){"@babel/helpers - typeof";return Ha=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},Ha(e)}var xW=["offset"];function SW(e){return AW(e)||PW(e)||_W(e)||OW()}function OW(){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 _W(e,t){if(e){if(typeof e=="string")return Gp(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Gp(e,t)}}function PW(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function AW(e){if(Array.isArray(e))return Gp(e)}function Gp(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function $W(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,o;for(o=0;o=0)&&(r[i]=e[i]);return r}function E1(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function De(e){for(var t=1;t=0?1:-1,b,S;i==="insideStart"?(b=p+y*a,S=v):i==="insideEnd"?(b=h-y*a,S=!v):i==="end"&&(b=h+y*a,S=v),S=m<=0?S:!S;var w=Xe(s,f,g,b),x=Xe(s,f,g,b+(S?1:-1)*359),O="M".concat(w.x,",").concat(w.y,` + A`).concat(g,",").concat(g,",0,1,").concat(S?0:1,`, + `).concat(x.x,",").concat(x.y),_=ie(t.id)?gu("recharts-radial-line-"):t.id;return $.createElement("text",Ka({},n,{dominantBaseline:"central",className:se("recharts-radial-bar-label",u)}),$.createElement("defs",null,$.createElement("path",{id:_,d:O})),$.createElement("textPath",{xlinkHref:"#".concat(_)},r))},NW=function(t){var r=t.viewBox,n=t.offset,i=t.position,o=r,a=o.cx,u=o.cy,l=o.innerRadius,s=o.outerRadius,f=o.startAngle,c=o.endAngle,d=(f+c)/2;if(i==="outside"){var p=Xe(a,u,s+n,d),h=p.x,v=p.y;return{x:h,y:v,textAnchor:h>=a?"start":"end",verticalAnchor:"middle"}}if(i==="center")return{x:a,y:u,textAnchor:"middle",verticalAnchor:"middle"};if(i==="centerTop")return{x:a,y:u,textAnchor:"middle",verticalAnchor:"start"};if(i==="centerBottom")return{x:a,y:u,textAnchor:"middle",verticalAnchor:"end"};var g=(l+s)/2,m=Xe(a,u,g,d),y=m.x,b=m.y;return{x:y,y:b,textAnchor:"middle",verticalAnchor:"middle"}},DW=function(t){var r=t.viewBox,n=t.parentViewBox,i=t.offset,o=t.position,a=r,u=a.x,l=a.y,s=a.width,f=a.height,c=f>=0?1:-1,d=c*i,p=c>0?"end":"start",h=c>0?"start":"end",v=s>=0?1:-1,g=v*i,m=v>0?"end":"start",y=v>0?"start":"end";if(o==="top"){var b={x:u+s/2,y:l-c*i,textAnchor:"middle",verticalAnchor:p};return De(De({},b),n?{height:Math.max(l-n.y,0),width:s}:{})}if(o==="bottom"){var S={x:u+s/2,y:l+f+d,textAnchor:"middle",verticalAnchor:h};return De(De({},S),n?{height:Math.max(n.y+n.height-(l+f),0),width:s}:{})}if(o==="left"){var w={x:u-g,y:l+f/2,textAnchor:m,verticalAnchor:"middle"};return De(De({},w),n?{width:Math.max(w.x-n.x,0),height:f}:{})}if(o==="right"){var x={x:u+s+g,y:l+f/2,textAnchor:y,verticalAnchor:"middle"};return De(De({},x),n?{width:Math.max(n.x+n.width-x.x,0),height:f}:{})}var O=n?{width:s,height:f}:{};return o==="insideLeft"?De({x:u+g,y:l+f/2,textAnchor:y,verticalAnchor:"middle"},O):o==="insideRight"?De({x:u+s-g,y:l+f/2,textAnchor:m,verticalAnchor:"middle"},O):o==="insideTop"?De({x:u+s/2,y:l+d,textAnchor:"middle",verticalAnchor:h},O):o==="insideBottom"?De({x:u+s/2,y:l+f-d,textAnchor:"middle",verticalAnchor:p},O):o==="insideTopLeft"?De({x:u+g,y:l+d,textAnchor:y,verticalAnchor:h},O):o==="insideTopRight"?De({x:u+s-g,y:l+d,textAnchor:m,verticalAnchor:h},O):o==="insideBottomLeft"?De({x:u+g,y:l+f-d,textAnchor:y,verticalAnchor:p},O):o==="insideBottomRight"?De({x:u+s-g,y:l+f-d,textAnchor:m,verticalAnchor:p},O):co(o)&&(U(o.x)||Ln(o.x))&&(U(o.y)||Ln(o.y))?De({x:u+Bi(o.x,s),y:l+Bi(o.y,f),textAnchor:"end",verticalAnchor:"end"},O):De({x:u+s/2,y:l+f/2,textAnchor:"middle",verticalAnchor:"middle"},O)},RW=function(t){return"cx"in t&&U(t.cx)};function nt(e){var t=e.offset,r=t===void 0?5:t,n=EW(e,xW),i=De({offset:r},n),o=i.viewBox,a=i.position,u=i.value,l=i.children,s=i.content,f=i.className,c=f===void 0?"":f,d=i.textBreakAll;if(!o||ie(u)&&ie(l)&&!T.isValidElement(s)&&!te(s))return null;if(T.isValidElement(s))return T.cloneElement(s,i);var p;if(te(s)){if(p=T.createElement(s,i),T.isValidElement(p))return p}else p=jW(i);var h=RW(o),v=ne(i,!0);if(h&&(a==="insideStart"||a==="insideEnd"||a==="end"))return IW(i,p,v);var g=h?NW(i):DW(i);return $.createElement(vs,Ka({className:se("recharts-label",c)},v,g,{breakAll:d}),p)}nt.displayName="Label";var k_=function(t){var r=t.cx,n=t.cy,i=t.angle,o=t.startAngle,a=t.endAngle,u=t.r,l=t.radius,s=t.innerRadius,f=t.outerRadius,c=t.x,d=t.y,p=t.top,h=t.left,v=t.width,g=t.height,m=t.clockWise,y=t.labelViewBox;if(y)return y;if(U(v)&&U(g)){if(U(c)&&U(d))return{x:c,y:d,width:v,height:g};if(U(p)&&U(h))return{x:p,y:h,width:v,height:g}}return U(c)&&U(d)?{x:c,y:d,width:0,height:0}:U(r)&&U(n)?{cx:r,cy:n,startAngle:o||i||0,endAngle:a||i||0,innerRadius:s||0,outerRadius:f||l||u||0,clockWise:m}:t.viewBox?t.viewBox:{}},LW=function(t,r){return t?t===!0?$.createElement(nt,{key:"label-implicit",viewBox:r}):Be(t)?$.createElement(nt,{key:"label-implicit",viewBox:r,value:t}):T.isValidElement(t)?t.type===nt?T.cloneElement(t,{key:"label-implicit",viewBox:r}):$.createElement(nt,{key:"label-implicit",content:t,viewBox:r}):te(t)?$.createElement(nt,{key:"label-implicit",content:t,viewBox:r}):co(t)?$.createElement(nt,Ka({viewBox:r},t,{key:"label-implicit"})):null:null},BW=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;if(!t||!t.children&&n&&!t.label)return null;var i=t.children,o=k_(t),a=Ut(i,nt).map(function(l,s){return T.cloneElement(l,{viewBox:r||o,key:"label-".concat(s)})});if(!n)return a;var u=LW(t.label,r||o);return[u].concat(SW(a))};nt.parseViewBox=k_;nt.renderCallByParent=BW;function zW(e){var t=e==null?0:e.length;return t?e[t-1]:void 0}var FW=zW;const UW=ve(FW);function Va(e){"@babel/helpers - typeof";return Va=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},Va(e)}var WW=["valueAccessor"],HW=["data","dataKey","clockWise","id","textBreakAll"];function KW(e){return XW(e)||qW(e)||GW(e)||VW()}function VW(){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 GW(e,t){if(e){if(typeof e=="string")return qp(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return qp(e,t)}}function qW(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function XW(e){if(Array.isArray(e))return qp(e)}function qp(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function JW(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,o;for(o=0;o=0)&&(r[i]=e[i]);return r}var e9=function(t){return Array.isArray(t.value)?UW(t.value):t.value};function hn(e){var t=e.valueAccessor,r=t===void 0?e9:t,n=T1(e,WW),i=n.data,o=n.dataKey,a=n.clockWise,u=n.id,l=n.textBreakAll,s=T1(n,HW);return!i||!i.length?null:$.createElement(Ce,{className:"recharts-label-list"},i.map(function(f,c){var d=ie(o)?r(f,c):$t(f&&f.payload,o),p=ie(u)?{}:{id:"".concat(u,"-").concat(c)};return $.createElement(nt,Ts({},ne(f,!0),s,p,{parentViewBox:f.parentViewBox,value:d,textBreakAll:l,viewBox:nt.parseViewBox(ie(a)?f:k1(k1({},f),{},{clockWise:a})),key:"label-".concat(c),index:c}))}))}hn.displayName="LabelList";function t9(e,t){return e?e===!0?$.createElement(hn,{key:"labelList-implicit",data:t}):$.isValidElement(e)||te(e)?$.createElement(hn,{key:"labelList-implicit",data:t,content:e}):co(e)?$.createElement(hn,Ts({data:t},e,{key:"labelList-implicit"})):null:null}function r9(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;if(!e||!e.children&&r&&!e.label)return null;var n=e.children,i=Ut(n,hn).map(function(a,u){return T.cloneElement(a,{data:t,key:"labelList-".concat(u)})});if(!r)return i;var o=t9(e.label,t);return[o].concat(KW(i))}hn.renderCallByParent=r9;function Ga(e){"@babel/helpers - typeof";return Ga=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},Ga(e)}function Xp(){return Xp=Object.assign?Object.assign.bind():function(e){for(var t=1;t180),",").concat(+(a>s),`, + `).concat(c.x,",").concat(c.y,` + `);if(i>0){var p=Xe(r,n,i,a),h=Xe(r,n,i,s);d+="L ".concat(h.x,",").concat(h.y,` + A `).concat(i,",").concat(i,`,0, + `).concat(+(Math.abs(l)>180),",").concat(+(a<=s),`, + `).concat(p.x,",").concat(p.y," Z")}else d+="L ".concat(r,",").concat(n," Z");return d},u9=function(t){var r=t.cx,n=t.cy,i=t.innerRadius,o=t.outerRadius,a=t.cornerRadius,u=t.forceCornerRadius,l=t.cornerIsExternal,s=t.startAngle,f=t.endAngle,c=rr(f-s),d=ol({cx:r,cy:n,radius:o,angle:s,sign:c,cornerRadius:a,cornerIsExternal:l}),p=d.circleTangency,h=d.lineTangency,v=d.theta,g=ol({cx:r,cy:n,radius:o,angle:f,sign:-c,cornerRadius:a,cornerIsExternal:l}),m=g.circleTangency,y=g.lineTangency,b=g.theta,S=l?Math.abs(s-f):Math.abs(s-f)-v-b;if(S<0)return u?"M ".concat(h.x,",").concat(h.y,` + a`).concat(a,",").concat(a,",0,0,1,").concat(a*2,`,0 + a`).concat(a,",").concat(a,",0,0,1,").concat(-a*2,`,0 + `):T_({cx:r,cy:n,innerRadius:i,outerRadius:o,startAngle:s,endAngle:f});var w="M ".concat(h.x,",").concat(h.y,` + A`).concat(a,",").concat(a,",0,0,").concat(+(c<0),",").concat(p.x,",").concat(p.y,` + A`).concat(o,",").concat(o,",0,").concat(+(S>180),",").concat(+(c<0),",").concat(m.x,",").concat(m.y,` + A`).concat(a,",").concat(a,",0,0,").concat(+(c<0),",").concat(y.x,",").concat(y.y,` + `);if(i>0){var x=ol({cx:r,cy:n,radius:i,angle:s,sign:c,isExternal:!0,cornerRadius:a,cornerIsExternal:l}),O=x.circleTangency,_=x.lineTangency,P=x.theta,E=ol({cx:r,cy:n,radius:i,angle:f,sign:-c,isExternal:!0,cornerRadius:a,cornerIsExternal:l}),A=E.circleTangency,k=E.lineTangency,j=E.theta,N=l?Math.abs(s-f):Math.abs(s-f)-P-j;if(N<0&&a===0)return"".concat(w,"L").concat(r,",").concat(n,"Z");w+="L".concat(k.x,",").concat(k.y,` + A`).concat(a,",").concat(a,",0,0,").concat(+(c<0),",").concat(A.x,",").concat(A.y,` + A`).concat(i,",").concat(i,",0,").concat(+(N>180),",").concat(+(c>0),",").concat(O.x,",").concat(O.y,` + A`).concat(a,",").concat(a,",0,0,").concat(+(c<0),",").concat(_.x,",").concat(_.y,"Z")}else w+="L".concat(r,",").concat(n,"Z");return w},l9={cx:0,cy:0,innerRadius:0,outerRadius:0,startAngle:0,endAngle:0,cornerRadius:0,forceCornerRadius:!1,cornerIsExternal:!1},C_=function(t){var r=j1(j1({},l9),t),n=r.cx,i=r.cy,o=r.innerRadius,a=r.outerRadius,u=r.cornerRadius,l=r.forceCornerRadius,s=r.cornerIsExternal,f=r.startAngle,c=r.endAngle,d=r.className;if(a0&&Math.abs(f-c)<360?g=u9({cx:n,cy:i,innerRadius:o,outerRadius:a,cornerRadius:Math.min(v,h/2),forceCornerRadius:l,cornerIsExternal:s,startAngle:f,endAngle:c}):g=T_({cx:n,cy:i,innerRadius:o,outerRadius:a,startAngle:f,endAngle:c}),$.createElement("path",Xp({},ne(r,!0),{className:p,d:g,role:"img"}))};function qa(e){"@babel/helpers - typeof";return qa=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},qa(e)}function Yp(){return Yp=Object.assign?Object.assign.bind():function(e){for(var t=1;te.length)&&(t=e.length);for(var r=0,n=new Array(t);r=0?1:-1,l=n>=0?1:-1,s=i>=0&&n>=0||i<0&&n<0?1:0,f;if(a>0&&o instanceof Array){for(var c=[0,0,0,0],d=0,p=4;da?a:o[d];f="M".concat(t,",").concat(r+u*c[0]),c[0]>0&&(f+="A ".concat(c[0],",").concat(c[0],",0,0,").concat(s,",").concat(t+l*c[0],",").concat(r)),f+="L ".concat(t+n-l*c[1],",").concat(r),c[1]>0&&(f+="A ".concat(c[1],",").concat(c[1],",0,0,").concat(s,`, + `).concat(t+n,",").concat(r+u*c[1])),f+="L ".concat(t+n,",").concat(r+i-u*c[2]),c[2]>0&&(f+="A ".concat(c[2],",").concat(c[2],",0,0,").concat(s,`, + `).concat(t+n-l*c[2],",").concat(r+i)),f+="L ".concat(t+l*c[3],",").concat(r+i),c[3]>0&&(f+="A ".concat(c[3],",").concat(c[3],",0,0,").concat(s,`, + `).concat(t,",").concat(r+i-u*c[3])),f+="Z"}else if(a>0&&o===+o&&o>0){var h=Math.min(a,o);f="M ".concat(t,",").concat(r+u*h,` + A `).concat(h,",").concat(h,",0,0,").concat(s,",").concat(t+l*h,",").concat(r,` + L `).concat(t+n-l*h,",").concat(r,` + A `).concat(h,",").concat(h,",0,0,").concat(s,",").concat(t+n,",").concat(r+u*h,` + L `).concat(t+n,",").concat(r+i-u*h,` + A `).concat(h,",").concat(h,",0,0,").concat(s,",").concat(t+n-l*h,",").concat(r+i,` + L `).concat(t+l*h,",").concat(r+i,` + A `).concat(h,",").concat(h,",0,0,").concat(s,",").concat(t,",").concat(r+i-u*h," Z")}else f="M ".concat(t,",").concat(r," h ").concat(n," v ").concat(i," h ").concat(-n," Z");return f},S9=function(t,r){if(!t||!r)return!1;var n=t.x,i=t.y,o=r.x,a=r.y,u=r.width,l=r.height;if(Math.abs(u)>0&&Math.abs(l)>0){var s=Math.min(o,o+u),f=Math.max(o,o+u),c=Math.min(a,a+l),d=Math.max(a,a+l);return n>=s&&n<=f&&i>=c&&i<=d}return!1},O9={x:0,y:0,width:0,height:0,radius:0,isAnimationActive:!1,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},dy=function(t){var r=L1(L1({},O9),t),n=T.useRef(),i=T.useState(-1),o=h9(i,2),a=o[0],u=o[1];T.useEffect(function(){if(n.current&&n.current.getTotalLength)try{var S=n.current.getTotalLength();S&&u(S)}catch{}},[]);var l=r.x,s=r.y,f=r.width,c=r.height,d=r.radius,p=r.className,h=r.animationEasing,v=r.animationDuration,g=r.animationBegin,m=r.isAnimationActive,y=r.isUpdateAnimationActive;if(l!==+l||s!==+s||f!==+f||c!==+c||f===0||c===0)return null;var b=se("recharts-rectangle",p);return y?$.createElement(Ir,{canBegin:a>0,from:{width:f,height:c,x:l,y:s},to:{width:f,height:c,x:l,y:s},duration:v,animationEasing:h,isActive:y},function(S){var w=S.width,x=S.height,O=S.x,_=S.y;return $.createElement(Ir,{canBegin:a>0,from:"0px ".concat(a===-1?1:a,"px"),to:"".concat(a,"px 0px"),attributeName:"strokeDasharray",begin:g,duration:v,isActive:m,easing:h},$.createElement("path",Cs({},ne(r,!0),{className:b,d:B1(O,_,w,x,d),ref:n})))}):$.createElement("path",Cs({},ne(r,!0),{className:b,d:B1(l,s,f,c,d)}))};function Zp(){return Zp=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function T9(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,o;for(o=0;o=0)&&(r[i]=e[i]);return r}var C9=function(t,r,n,i,o,a){return"M".concat(t,",").concat(o,"v").concat(i,"M").concat(a,",").concat(r,"h").concat(n)},j9=function(t){var r=t.x,n=r===void 0?0:r,i=t.y,o=i===void 0?0:i,a=t.top,u=a===void 0?0:a,l=t.left,s=l===void 0?0:l,f=t.width,c=f===void 0?0:f,d=t.height,p=d===void 0?0:d,h=t.className,v=k9(t,_9),g=P9({x:n,y:o,top:u,left:s,width:c,height:p},v);return!U(n)||!U(o)||!U(c)||!U(p)||!U(u)||!U(s)?null:$.createElement("path",Jp({},ne(g,!0),{className:se("recharts-cross",h),d:C9(n,o,c,p,u,s)}))},M9=QS,I9=M9(Object.getPrototypeOf,Object),N9=I9,D9=Br,R9=N9,L9=zr,B9="[object Object]",z9=Function.prototype,F9=Object.prototype,j_=z9.toString,U9=F9.hasOwnProperty,W9=j_.call(Object);function H9(e){if(!L9(e)||D9(e)!=B9)return!1;var t=R9(e);if(t===null)return!0;var r=U9.call(t,"constructor")&&t.constructor;return typeof r=="function"&&r instanceof r&&j_.call(r)==W9}var K9=H9;const V9=ve(K9);var G9=Br,q9=zr,X9="[object Boolean]";function Y9(e){return e===!0||e===!1||q9(e)&&G9(e)==X9}var Q9=Y9;const Z9=ve(Q9);function Qa(e){"@babel/helpers - typeof";return Qa=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},Qa(e)}function js(){return js=Object.assign?Object.assign.bind():function(e){for(var t=1;te.length)&&(t=e.length);for(var r=0,n=new Array(t);r0,from:{upperWidth:0,lowerWidth:0,height:d,x:l,y:s},to:{upperWidth:f,lowerWidth:c,height:d,x:l,y:s},duration:v,animationEasing:h,isActive:m},function(b){var S=b.upperWidth,w=b.lowerWidth,x=b.height,O=b.x,_=b.y;return $.createElement(Ir,{canBegin:a>0,from:"0px ".concat(a===-1?1:a,"px"),to:"".concat(a,"px 0px"),attributeName:"strokeDasharray",begin:g,duration:v,easing:h},$.createElement("path",js({},ne(r,!0),{className:y,d:H1(O,_,S,w,x),ref:n})))}):$.createElement("g",null,$.createElement("path",js({},ne(r,!0),{className:y,d:H1(l,s,f,c,d)})))},sH=["option","shapeType","propTransformer","activeClassName","isActive"];function Za(e){"@babel/helpers - typeof";return Za=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},Za(e)}function cH(e,t){if(e==null)return{};var r=fH(e,t),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function fH(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,o;for(o=0;o=0)&&(r[i]=e[i]);return r}function K1(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Ms(e){for(var t=1;t"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 Ds(e){return Ds=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Ds(e)}function St(e,t,r){return t=N_(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function N_(e){var t=YH(e,"string");return Qi(t)==="symbol"?t:String(t)}function YH(e,t){if(Qi(e)!=="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Qi(n)!=="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var QH=function(t){var r=t.data,n=t.startIndex,i=t.endIndex,o=t.x,a=t.width,u=t.travellerWidth;if(!r||!r.length)return{};var l=r.length,s=na().domain(Is(0,l)).range([o,o+a-u]),f=s.domain().map(function(c){return s(c)});return{isTextActive:!1,isSlideMoving:!1,isTravellerMoving:!1,isTravellerFocused:!1,startX:s(n),endX:s(i),scale:s,scaleValues:f}},Z1=function(t){return t.changedTouches&&!!t.changedTouches.length},tu=function(e){VH(r,e);var t=GH(r);function r(n){var i;return HH(this,r),i=t.call(this,n),St(sr(i),"handleDrag",function(o){i.leaveTimer&&(clearTimeout(i.leaveTimer),i.leaveTimer=null),i.state.isTravellerMoving?i.handleTravellerMove(o):i.state.isSlideMoving&&i.handleSlideDrag(o)}),St(sr(i),"handleTouchMove",function(o){o.changedTouches!=null&&o.changedTouches.length>0&&i.handleDrag(o.changedTouches[0])}),St(sr(i),"handleDragEnd",function(){i.setState({isTravellerMoving:!1,isSlideMoving:!1},function(){var o=i.props,a=o.endIndex,u=o.onDragEnd,l=o.startIndex;u==null||u({endIndex:a,startIndex:l})}),i.detachDragEndListener()}),St(sr(i),"handleLeaveWrapper",function(){(i.state.isTravellerMoving||i.state.isSlideMoving)&&(i.leaveTimer=window.setTimeout(i.handleDragEnd,i.props.leaveTimeOut))}),St(sr(i),"handleEnterSlideOrTraveller",function(){i.setState({isTextActive:!0})}),St(sr(i),"handleLeaveSlideOrTraveller",function(){i.setState({isTextActive:!1})}),St(sr(i),"handleSlideDragStart",function(o){var a=Z1(o)?o.changedTouches[0]:o;i.setState({isTravellerMoving:!1,isSlideMoving:!0,slideMoveStartX:a.pageX}),i.attachDragEndListener()}),i.travellerDragStartHandlers={startX:i.handleTravellerDragStart.bind(sr(i),"startX"),endX:i.handleTravellerDragStart.bind(sr(i),"endX")},i.state={},i}return KH(r,[{key:"componentWillUnmount",value:function(){this.leaveTimer&&(clearTimeout(this.leaveTimer),this.leaveTimer=null),this.detachDragEndListener()}},{key:"getIndex",value:function(i){var o=i.startX,a=i.endX,u=this.state.scaleValues,l=this.props,s=l.gap,f=l.data,c=f.length-1,d=Math.min(o,a),p=Math.max(o,a),h=r.getIndexInRange(u,d),v=r.getIndexInRange(u,p);return{startIndex:h-h%s,endIndex:v===c?c:v-v%s}}},{key:"getTextOfTick",value:function(i){var o=this.props,a=o.data,u=o.tickFormatter,l=o.dataKey,s=$t(a[i],l,i);return te(u)?u(s,i):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(i){var o=this.state,a=o.slideMoveStartX,u=o.startX,l=o.endX,s=this.props,f=s.x,c=s.width,d=s.travellerWidth,p=s.startIndex,h=s.endIndex,v=s.onChange,g=i.pageX-a;g>0?g=Math.min(g,f+c-d-l,f+c-d-u):g<0&&(g=Math.max(g,f-u,f-l));var m=this.getIndex({startX:u+g,endX:l+g});(m.startIndex!==p||m.endIndex!==h)&&v&&v(m),this.setState({startX:u+g,endX:l+g,slideMoveStartX:i.pageX})}},{key:"handleTravellerDragStart",value:function(i,o){var a=Z1(o)?o.changedTouches[0]:o;this.setState({isSlideMoving:!1,isTravellerMoving:!0,movingTravellerId:i,brushMoveStartX:a.pageX}),this.attachDragEndListener()}},{key:"handleTravellerMove",value:function(i){var o,a=this.state,u=a.brushMoveStartX,l=a.movingTravellerId,s=a.endX,f=a.startX,c=this.state[l],d=this.props,p=d.x,h=d.width,v=d.travellerWidth,g=d.onChange,m=d.gap,y=d.data,b={startX:this.state.startX,endX:this.state.endX},S=i.pageX-u;S>0?S=Math.min(S,p+h-v-c):S<0&&(S=Math.max(S,p-c)),b[l]=c+S;var w=this.getIndex(b),x=w.startIndex,O=w.endIndex,_=function(){var E=y.length-1;return l==="startX"&&(s>f?x%m===0:O%m===0)||sf?O%m===0:x%m===0)||s>f&&O===E};this.setState((o={},St(o,l,c+S),St(o,"brushMoveStartX",i.pageX),o),function(){g&&_()&&g(w)})}},{key:"handleTravellerMoveKeyboard",value:function(i,o){var a=this,u=this.state,l=u.scaleValues,s=u.startX,f=u.endX,c=this.state[o],d=l.indexOf(c);if(d!==-1){var p=d+i;if(!(p===-1||p>=l.length)){var h=l[p];o==="startX"&&h>=f||o==="endX"&&h<=s||this.setState(St({},o,h),function(){a.props.onChange(a.getIndex({startX:a.state.startX,endX:a.state.endX}))})}}}},{key:"renderBackground",value:function(){var i=this.props,o=i.x,a=i.y,u=i.width,l=i.height,s=i.fill,f=i.stroke;return $.createElement("rect",{stroke:f,fill:s,x:o,y:a,width:u,height:l})}},{key:"renderPanorama",value:function(){var i=this.props,o=i.x,a=i.y,u=i.width,l=i.height,s=i.data,f=i.children,c=i.padding,d=T.Children.only(f);return d?$.cloneElement(d,{x:o,y:a,width:u,height:l,margin:c,compact:!0,data:s}):null}},{key:"renderTravellerLayer",value:function(i,o){var a=this,u=this.props,l=u.y,s=u.travellerWidth,f=u.height,c=u.traveller,d=Math.max(i,this.props.x),p=Yf(Yf({},ne(this.props)),{},{x:d,y:l,width:s,height:f});return $.createElement(Ce,{tabIndex:0,role:"slider",className:"recharts-brush-traveller",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.travellerDragStartHandlers[o],onTouchStart:this.travellerDragStartHandlers[o],onKeyDown:function(v){["ArrowLeft","ArrowRight"].includes(v.key)&&(v.preventDefault(),v.stopPropagation(),a.handleTravellerMoveKeyboard(v.key==="ArrowRight"?1:-1,o))},onFocus:function(){a.setState({isTravellerFocused:!0})},onBlur:function(){a.setState({isTravellerFocused:!1})},style:{cursor:"col-resize"}},r.renderTraveller(c,p))}},{key:"renderSlide",value:function(i,o){var a=this.props,u=a.y,l=a.height,s=a.stroke,f=a.travellerWidth,c=Math.min(i,o)+f,d=Math.max(Math.abs(o-i)-f,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:c,y:u,width:d,height:l})}},{key:"renderText",value:function(){var i=this.props,o=i.startIndex,a=i.endIndex,u=i.y,l=i.height,s=i.travellerWidth,f=i.stroke,c=this.state,d=c.startX,p=c.endX,h=5,v={pointerEvents:"none",fill:f};return $.createElement(Ce,{className:"recharts-brush-texts"},$.createElement(vs,Ns({textAnchor:"end",verticalAnchor:"middle",x:Math.min(d,p)-h,y:u+l/2},v),this.getTextOfTick(o)),$.createElement(vs,Ns({textAnchor:"start",verticalAnchor:"middle",x:Math.max(d,p)+s+h,y:u+l/2},v),this.getTextOfTick(a)))}},{key:"render",value:function(){var i=this.props,o=i.data,a=i.className,u=i.children,l=i.x,s=i.y,f=i.width,c=i.height,d=i.alwaysShowText,p=this.state,h=p.startX,v=p.endX,g=p.isTextActive,m=p.isSlideMoving,y=p.isTravellerMoving,b=p.isTravellerFocused;if(!o||!o.length||!U(l)||!U(s)||!U(f)||!U(c)||f<=0||c<=0)return null;var S=se("recharts-brush",a),w=$.Children.count(u)===1,x=WH("userSelect","none");return $.createElement(Ce,{className:S,onMouseLeave:this.handleLeaveWrapper,onTouchMove:this.handleTouchMove,style:x},this.renderBackground(),w&&this.renderPanorama(),this.renderSlide(h,v),this.renderTravellerLayer(h,"startX"),this.renderTravellerLayer(v,"endX"),(g||m||y||b||d)&&this.renderText())}}],[{key:"renderDefaultTraveller",value:function(i){var o=i.x,a=i.y,u=i.width,l=i.height,s=i.stroke,f=Math.floor(a+l/2)-1;return $.createElement($.Fragment,null,$.createElement("rect",{x:o,y:a,width:u,height:l,fill:s,stroke:"none"}),$.createElement("line",{x1:o+1,y1:f,x2:o+u-1,y2:f,fill:"none",stroke:"#fff"}),$.createElement("line",{x1:o+1,y1:f+2,x2:o+u-1,y2:f+2,fill:"none",stroke:"#fff"}))}},{key:"renderTraveller",value:function(i,o){var a;return $.isValidElement(i)?a=$.cloneElement(i,o):te(i)?a=i(o):a=r.renderDefaultTraveller(o),a}},{key:"getDerivedStateFromProps",value:function(i,o){var a=i.data,u=i.width,l=i.x,s=i.travellerWidth,f=i.updateId,c=i.startIndex,d=i.endIndex;if(a!==o.prevData||f!==o.prevUpdateId)return Yf({prevData:a,prevTravellerWidth:s,prevUpdateId:f,prevX:l,prevWidth:u},a&&a.length?QH({data:a,width:u,x:l,travellerWidth:s,startIndex:c,endIndex:d}):{scale:null,scaleValues:null});if(o.scale&&(u!==o.prevWidth||l!==o.prevX||s!==o.prevTravellerWidth)){o.scale.range([l,l+u-s]);var p=o.scale.domain().map(function(h){return o.scale(h)});return{prevData:a,prevTravellerWidth:s,prevUpdateId:f,prevX:l,prevWidth:u,startX:o.scale(i.startIndex),endX:o.scale(i.endIndex),scaleValues:p}}return null}},{key:"getIndexInRange",value:function(i,o){for(var a=i.length,u=0,l=a-1;l-u>1;){var s=Math.floor((u+l)/2);i[s]>o?l=s:u=s}return o>=i[l]?l:u}}]),r}(T.PureComponent);St(tu,"displayName","Brush");St(tu,"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 ZH=Rv;function JH(e,t){var r;return ZH(e,function(n,i,o){return r=t(n,i,o),!r}),!!r}var e7=JH,t7=WS,r7=Sn,n7=e7,i7=mt,o7=kc;function a7(e,t,r){var n=i7(e)?t7:n7;return r&&o7(e,t,r)&&(t=void 0),n(e,r7(t))}var u7=a7;const l7=ve(u7);var yr=function(t,r){var n=t.alwaysShow,i=t.ifOverflow;return n&&(i="extendDomain"),i===r},J1=fO;function s7(e,t,r){t=="__proto__"&&J1?J1(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}var c7=s7,f7=c7,d7=sO,p7=Sn;function h7(e,t){var r={};return t=p7(t),d7(e,function(n,i,o){f7(r,i,t(n,i,o))}),r}var v7=h7;const y7=ve(v7);function m7(e,t){for(var r=-1,n=e==null?0:e.length;++r=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function I7(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,o;for(o=0;o=0)&&(r[i]=e[i]);return r}function N7(e,t){var r=e.x,n=e.y,i=M7(e,k7),o="".concat(r),a=parseInt(o,10),u="".concat(n),l=parseInt(u,10),s="".concat(t.height||i.height),f=parseInt(s,10),c="".concat(t.width||i.width),d=parseInt(c,10);return Bo(Bo(Bo(Bo(Bo({},t),i),a?{x:a}:{}),l?{y:l}:{}),{},{height:f,width:d,name:t.name,radius:t.radius})}function tb(e){return $.createElement(gH,th({shapeType:"rectangle",propTransformer:N7,activeClassName:"recharts-active-bar"},e))}var D7=["value","background"];function Zi(e){"@babel/helpers - typeof";return Zi=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},Zi(e)}function R7(e,t){if(e==null)return{};var r=L7(e,t),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function L7(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,o;for(o=0;o=0)&&(r[i]=e[i]);return r}function Rs(){return Rs=Object.assign?Object.assign.bind():function(e){for(var t=1;t"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 Ls(e){return Ls=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Ls(e)}function tn(e,t,r){return t=R_(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function R_(e){var t=K7(e,"string");return Zi(t)==="symbol"?t:String(t)}function K7(e,t){if(Zi(e)!=="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Zi(n)!=="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Hc=function(e){F7(r,e);var t=U7(r);function r(){var n;B7(this,r);for(var i=arguments.length,o=new Array(i),a=0;a0&&Math.abs(N)0&&Math.abs(j)0&&(j=Math.min((Pe||0)-(N[$e-1]||0),j))});var D=j/k,B=v.layout==="vertical"?n.height:n.width;if(v.padding==="gap"&&(O=D*B/2),v.padding==="no-gap"){var R=Bi(t.barCategoryGap,D*B),C=D*B/2;O=C-R-(C-R)/B*R}}i==="xAxis"?_=[n.left+(b.left||0)+(O||0),n.left+n.width-(b.right||0)-(O||0)]:i==="yAxis"?_=l==="horizontal"?[n.top+n.height-(b.bottom||0),n.top+(b.top||0)]:[n.top+(b.top||0)+(O||0),n.top+n.height-(b.bottom||0)-(O||0)]:_=v.range,w&&(_=[_[1],_[0]]);var I=eW(v,o,d),F=I.scale,X=I.realScaleType;F.domain(m).range(_),tW(F);var H=sW(F,Qt(Qt({},v),{},{realScaleType:X}));i==="xAxis"?(A=g==="top"&&!S||g==="bottom"&&S,P=n.left,E=c[x]-A*v.height):i==="yAxis"&&(A=g==="left"&&!S||g==="right"&&S,P=c[x]-A*v.width,E=n.top);var ee=Qt(Qt(Qt({},v),H),{},{realScaleType:X,x:P,y:E,scale:F,width:i==="xAxis"?n.width:v.width,height:i==="yAxis"?n.height:v.height});return ee.bandSize=$s(ee,H),!v.hide&&i==="xAxis"?c[x]+=(A?-1:1)*ee.height:v.hide||(c[x]+=(A?-1:1)*ee.width),Qt(Qt({},p),{},Kc({},h,ee))},{})},B_=function(t,r){var n=t.x,i=t.y,o=r.x,a=r.y;return{x:Math.min(n,o),y:Math.min(i,a),width:Math.abs(o-n),height:Math.abs(a-i)}},Y7=function(t){var r=t.x1,n=t.y1,i=t.x2,o=t.y2;return B_({x:r,y:n},{x:i,y:o})},z_=function(){function e(t){V7(this,e),this.scale=t}return G7(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(r){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=n.bandAware,o=n.position;if(r!==void 0){if(o)switch(o){case"start":return this.scale(r);case"middle":{var a=this.bandwidth?this.bandwidth()/2:0;return this.scale(r)+a}case"end":{var u=this.bandwidth?this.bandwidth():0;return this.scale(r)+u}default:return this.scale(r)}if(i){var l=this.bandwidth?this.bandwidth()/2:0;return this.scale(r)+l}return this.scale(r)}}},{key:"isInRange",value:function(r){var n=this.range(),i=n[0],o=n[n.length-1];return i<=o?r>=i&&r<=o:r>=o&&r<=i}}],[{key:"create",value:function(r){return new e(r)}}]),e}();Kc(z_,"EPS",1e-4);var py=function(t){var r=Object.keys(t).reduce(function(n,i){return Qt(Qt({},n),{},Kc({},i,z_.create(t[i])))},{});return Qt(Qt({},r),{},{apply:function(i){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},a=o.bandAware,u=o.position;return y7(i,function(l,s){return r[s].apply(l,{bandAware:a,position:u})})},isInRange:function(i){return D_(i,function(o,a){return r[a].isInRange(o)})}})};function Q7(e){return(e%180+180)%180}var Z7=function(t){var r=t.width,n=t.height,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,o=Q7(i),a=o*Math.PI/180,u=Math.atan(n/r),l=a>u&&ae.length)&&(t=e.length);for(var r=0,n=new Array(t);re*i)return!1;var o=r();return e*(t-e*o/2-n)>=0&&e*(t+e*o/2-i)<=0}function bK(e,t){return F_(e,t+1)}function wK(e,t,r,n,i){for(var o=(n||[]).slice(),a=t.start,u=t.end,l=0,s=1,f=a,c=function(){var h=n==null?void 0:n[l];if(h===void 0)return{v:F_(n,s)};var v=l,g,m=function(){return g===void 0&&(g=r(h,v)),g},y=h.coordinate,b=l===0||Bs(e,y,m,f,u);b||(l=0,f=a,s+=1),b&&(f=y+e*(m()/2+i),l+=s)},d;s<=o.length;)if(d=c(),d)return d.v;return[]}function uu(e){"@babel/helpers - typeof";return uu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},uu(e)}function pb(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function tt(e){for(var t=1;t0?p.coordinate-g*e:p.coordinate})}else o[d]=p=tt(tt({},p),{},{tickCoord:p.coordinate});var m=Bs(e,p.tickCoord,v,u,l);m&&(l=p.tickCoord-e*(v()/2+i),o[d]=tt(tt({},p),{},{isShow:!0}))},f=a-1;f>=0;f--)s(f);return o}function PK(e,t,r,n,i,o){var a=(n||[]).slice(),u=a.length,l=t.start,s=t.end;if(o){var f=n[u-1],c=r(f,u-1),d=e*(f.coordinate+e*c/2-s);a[u-1]=f=tt(tt({},f),{},{tickCoord:d>0?f.coordinate-d*e:f.coordinate});var p=Bs(e,f.tickCoord,function(){return c},l,s);p&&(s=f.tickCoord-e*(c/2+i),a[u-1]=tt(tt({},f),{},{isShow:!0}))}for(var h=o?u-1:u,v=function(y){var b=a[y],S,w=function(){return S===void 0&&(S=r(b,y)),S};if(y===0){var x=e*(b.coordinate-e*w()/2-l);a[y]=b=tt(tt({},b),{},{tickCoord:x<0?b.coordinate-x*e:b.coordinate})}else a[y]=b=tt(tt({},b),{},{tickCoord:b.coordinate});var O=Bs(e,b.tickCoord,w,l,s);O&&(l=b.tickCoord+e*(w()/2+i),a[y]=tt(tt({},b),{},{isShow:!0}))},g=0;g=2?rr(i[1].coordinate-i[0].coordinate):1,m=gK(o,g,p);return l==="equidistantPreserveStart"?wK(g,m,v,i,a):(l==="preserveStart"||l==="preserveStartEnd"?d=PK(g,m,v,i,a,l==="preserveStartEnd"):d=_K(g,m,v,i,a),d.filter(function(y){return y.isShow}))}var AK=["viewBox"],EK=["viewBox"],$K=["ticks"];function Ji(e){"@babel/helpers - typeof";return Ji=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},Ji(e)}function xi(){return xi=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function kK(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,o;for(o=0;o=0)&&(r[i]=e[i]);return r}function TK(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function vb(e,t){for(var r=0;r"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 zs(e){return zs=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},zs(e)}function vy(e,t,r){return t=U_(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function U_(e){var t=RK(e,"string");return Ji(t)==="symbol"?t:String(t)}function RK(e,t){if(Ji(e)!=="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Ji(n)!=="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var oa=function(e){jK(r,e);var t=MK(r);function r(n){var i;return TK(this,r),i=t.call(this,n),i.state={fontSize:"",letterSpacing:""},i}return CK(r,[{key:"shouldComponentUpdate",value:function(i,o){var a=i.viewBox,u=Qf(i,AK),l=this.props,s=l.viewBox,f=Qf(l,EK);return!ki(a,s)||!ki(u,f)||!ki(o,this.state)}},{key:"componentDidMount",value:function(){var i=this.layerReference;if(i){var o=i.getElementsByClassName("recharts-cartesian-axis-tick-value")[0];o&&this.setState({fontSize:window.getComputedStyle(o).fontSize,letterSpacing:window.getComputedStyle(o).letterSpacing})}}},{key:"getTickLineCoord",value:function(i){var o=this.props,a=o.x,u=o.y,l=o.width,s=o.height,f=o.orientation,c=o.tickSize,d=o.mirror,p=o.tickMargin,h,v,g,m,y,b,S=d?-1:1,w=i.tickSize||c,x=U(i.tickCoord)?i.tickCoord:i.coordinate;switch(f){case"top":h=v=i.coordinate,m=u+ +!d*s,g=m-S*w,b=g-S*p,y=x;break;case"left":g=m=i.coordinate,v=a+ +!d*l,h=v-S*w,y=h-S*p,b=x;break;case"right":g=m=i.coordinate,v=a+ +d*l,h=v+S*w,y=h+S*p,b=x;break;default:h=v=i.coordinate,m=u+ +d*s,g=m+S*w,b=g+S*p,y=x;break}return{line:{x1:h,y1:g,x2:v,y2:m},tick:{x:y,y:b}}}},{key:"getTickTextAnchor",value:function(){var i=this.props,o=i.orientation,a=i.mirror,u;switch(o){case"left":u=a?"start":"end";break;case"right":u=a?"end":"start";break;default:u="middle";break}return u}},{key:"getTickVerticalAnchor",value:function(){var i=this.props,o=i.orientation,a=i.mirror,u="end";switch(o){case"left":case"right":u="middle";break;case"top":u=a?"start":"end";break;default:u=a?"end":"start";break}return u}},{key:"renderAxisLine",value:function(){var i=this.props,o=i.x,a=i.y,u=i.width,l=i.height,s=i.orientation,f=i.mirror,c=i.axisLine,d=ot(ot(ot({},ne(this.props)),ne(c)),{},{fill:"none"});if(s==="top"||s==="bottom"){var p=+(s==="top"&&!f||s==="bottom"&&f);d=ot(ot({},d),{},{x1:o,y1:a+p*l,x2:o+u,y2:a+p*l})}else{var h=+(s==="left"&&!f||s==="right"&&f);d=ot(ot({},d),{},{x1:o+h*u,y1:a,x2:o+h*u,y2:a+l})}return $.createElement("line",xi({},d,{className:se("recharts-cartesian-axis-line",Ft(c,"className"))}))}},{key:"renderTicks",value:function(i,o,a){var u=this,l=this.props,s=l.tickLine,f=l.stroke,c=l.tick,d=l.tickFormatter,p=l.unit,h=ah(ot(ot({},this.props),{},{ticks:i}),o,a),v=this.getTickTextAnchor(),g=this.getTickVerticalAnchor(),m=ne(this.props),y=ne(c),b=ot(ot({},m),{},{fill:"none"},ne(s)),S=h.map(function(w,x){var O=u.getTickLineCoord(w),_=O.line,P=O.tick,E=ot(ot(ot(ot({textAnchor:v,verticalAnchor:g},m),{},{stroke:"none",fill:f},y),P),{},{index:x,payload:w,visibleTicksCount:h.length,tickFormatter:d});return $.createElement(Ce,xi({className:"recharts-cartesian-axis-tick",key:"tick-".concat(x)},Ql(u.props,w,x)),s&&$.createElement("line",xi({},b,_,{className:se("recharts-cartesian-axis-tick-line",Ft(s,"className"))})),c&&r.renderTickItem(c,E,"".concat(te(d)?d(w.value,x):w.value).concat(p||"")))});return $.createElement("g",{className:"recharts-cartesian-axis-ticks"},S)}},{key:"render",value:function(){var i=this,o=this.props,a=o.axisLine,u=o.width,l=o.height,s=o.ticksGenerator,f=o.className,c=o.hide;if(c)return null;var d=this.props,p=d.ticks,h=Qf(d,$K),v=p;return te(s)&&(v=p&&p.length>0?s(this.props):s(h)),u<=0||l<=0||!v||!v.length?null:$.createElement(Ce,{className:se("recharts-cartesian-axis",f),ref:function(m){i.layerReference=m}},a&&this.renderAxisLine(),this.renderTicks(v,this.state.fontSize,this.state.letterSpacing),nt.renderCallByParent(this.props))}}],[{key:"renderTickItem",value:function(i,o,a){var u;return $.isValidElement(i)?u=$.cloneElement(i,o):te(i)?u=i(o):u=$.createElement(vs,xi({},o,{className:"recharts-cartesian-axis-tick-value"}),a),u}}]),r}(T.Component);vy(oa,"displayName","CartesianAxis");vy(oa,"defaultProps",{x:0,y:0,width:0,height:0,viewBox:{x:0,y:0,width:0,height:0},orientation:"bottom",ticks:[],stroke:"#666",tickLine:!0,axisLine:!0,tick:!0,mirror:!1,minTickGap:5,tickSize:6,tickMargin:2,interval:"preserveEnd"});var LK=["x1","y1","x2","y2","key"],BK=["offset"];function eo(e){"@babel/helpers - typeof";return eo=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},eo(e)}function lh(){return lh=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function zK(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,o;for(o=0;o=0)&&(r[i]=e[i]);return r}function mb(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Wr(e){for(var t=1;t"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 Fs(e){return Fs=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Fs(e)}function yy(e,t,r){return t=W_(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function W_(e){var t=qK(e,"string");return eo(t)==="symbol"?t:String(t)}function qK(e,t){if(eo(e)!=="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(eo(n)!=="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var my=function(e){WK(r,e);var t=HK(r);function r(){return FK(this,r),t.apply(this,arguments)}return UK(r,[{key:"renderHorizontal",value:function(i){var o=this,a=this.props,u=a.x,l=a.width,s=a.horizontal;if(!i||!i.length)return null;var f=i.map(function(c,d){var p=Wr(Wr({},o.props),{},{x1:u,y1:c,x2:u+l,y2:c,key:"line-".concat(d),index:d});return r.renderLineItem(s,p)});return $.createElement("g",{className:"recharts-cartesian-grid-horizontal"},f)}},{key:"renderVertical",value:function(i){var o=this,a=this.props,u=a.y,l=a.height,s=a.vertical;if(!i||!i.length)return null;var f=i.map(function(c,d){var p=Wr(Wr({},o.props),{},{x1:c,y1:u,x2:c,y2:u+l,key:"line-".concat(d),index:d});return r.renderLineItem(s,p)});return $.createElement("g",{className:"recharts-cartesian-grid-vertical"},f)}},{key:"renderVerticalStripes",value:function(i){var o=this.props.verticalFill;if(!o||!o.length)return null;var a=this.props,u=a.fillOpacity,l=a.x,s=a.y,f=a.width,c=a.height,d=i.map(function(h){return Math.round(h+l-l)}).sort(function(h,v){return h-v});l!==d[0]&&d.unshift(0);var p=d.map(function(h,v){var g=!d[v+1],m=g?l+f-h:d[v+1]-h;if(m<=0)return null;var y=v%o.length;return $.createElement("rect",{key:"react-".concat(v),x:h,y:s,width:m,height:c,stroke:"none",fill:o[y],fillOpacity:u,className:"recharts-cartesian-grid-bg"})});return $.createElement("g",{className:"recharts-cartesian-gridstripes-vertical"},p)}},{key:"renderHorizontalStripes",value:function(i){var o=this.props.horizontalFill;if(!o||!o.length)return null;var a=this.props,u=a.fillOpacity,l=a.x,s=a.y,f=a.width,c=a.height,d=i.map(function(h){return Math.round(h+s-s)}).sort(function(h,v){return h-v});s!==d[0]&&d.unshift(0);var p=d.map(function(h,v){var g=!d[v+1],m=g?s+c-h:d[v+1]-h;if(m<=0)return null;var y=v%o.length;return $.createElement("rect",{key:"react-".concat(v),y:h,x:l,height:m,width:f,stroke:"none",fill:o[y],fillOpacity:u,className:"recharts-cartesian-grid-bg"})});return $.createElement("g",{className:"recharts-cartesian-gridstripes-horizontal"},p)}},{key:"renderBackground",value:function(){var i=this.props.fill;if(!i||i==="none")return null;var o=this.props,a=o.fillOpacity,u=o.x,l=o.y,s=o.width,f=o.height;return $.createElement("rect",{x:u,y:l,width:s,height:f,stroke:"none",fill:i,fillOpacity:a,className:"recharts-cartesian-grid-bg"})}},{key:"render",value:function(){var i=this.props,o=i.x,a=i.y,u=i.width,l=i.height,s=i.horizontal,f=i.vertical,c=i.horizontalCoordinatesGenerator,d=i.verticalCoordinatesGenerator,p=i.xAxis,h=i.yAxis,v=i.offset,g=i.chartWidth,m=i.chartHeight,y=i.syncWithTicks,b=i.horizontalValues,S=i.verticalValues;if(!U(u)||u<=0||!U(l)||l<=0||!U(o)||o!==+o||!U(a)||a!==+a)return null;var w=this.props,x=w.horizontalPoints,O=w.verticalPoints;if((!x||!x.length)&&te(c)){var _=b&&b.length;x=c({yAxis:h?Wr(Wr({},h),{},{ticks:_?b:h.ticks}):void 0,width:g,height:m,offset:v},_?!0:y)}if((!O||!O.length)&&te(d)){var P=S&&S.length;O=d({xAxis:p?Wr(Wr({},p),{},{ticks:P?S:p.ticks}):void 0,width:g,height:m,offset:v},P?!0:y)}return $.createElement("g",{className:"recharts-cartesian-grid"},this.renderBackground(),s&&this.renderHorizontal(x),f&&this.renderVertical(O),s&&this.renderHorizontalStripes(x),f&&this.renderVerticalStripes(O))}}],[{key:"renderLineItem",value:function(i,o){var a;if($.isValidElement(i))a=$.cloneElement(i,o);else if(te(i))a=i(o);else{var u=o.x1,l=o.y1,s=o.x2,f=o.y2,c=o.key,d=yb(o,LK),p=ne(d);p.offset;var h=yb(p,BK);a=$.createElement("line",lh({},h,{x1:u,y1:l,x2:s,y2:f,fill:"none",key:c}))}return a}}]),r}(T.PureComponent);yy(my,"displayName","CartesianGrid");yy(my,"defaultProps",{horizontal:!0,vertical:!0,horizontalPoints:[],verticalPoints:[],stroke:"#ccc",fill:"none",verticalFill:[],horizontalFill:[]});var XK=["type","layout","connectNulls","ref"];function to(e){"@babel/helpers - typeof";return to=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},to(e)}function YK(e,t){if(e==null)return{};var r=QK(e,t),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function QK(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,o;for(o=0;o=0)&&(r[i]=e[i]);return r}function aa(){return aa=Object.assign?Object.assign.bind():function(e){for(var t=1;te.length)&&(t=e.length);for(var r=0,n=new Array(t);r"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 Us(e){return Us=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Us(e)}function Zt(e,t,r){return t=H_(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function H_(e){var t=lV(e,"string");return to(t)==="symbol"?t:String(t)}function lV(e,t){if(to(e)!=="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(to(n)!=="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Eu=function(e){iV(r,e);var t=oV(r);function r(){var n;rV(this,r);for(var i=arguments.length,o=new Array(i),a=0;ad){h=[].concat(ui(s.slice(0,v)),[d-g]);break}var m=h.length%2===0?[0,p]:[p];return[].concat(ui(r.repeat(s,c)),ui(h),m).map(function(y){return"".concat(y,"px")}).join(", ")}),Zt(Vr(n),"id",gu("recharts-line-")),Zt(Vr(n),"pathRef",function(u){n.mainCurve=u}),Zt(Vr(n),"handleAnimationEnd",function(){n.setState({isAnimationFinished:!0}),n.props.onAnimationEnd&&n.props.onAnimationEnd()}),Zt(Vr(n),"handleAnimationStart",function(){n.setState({isAnimationFinished:!1}),n.props.onAnimationStart&&n.props.onAnimationStart()}),n}return nV(r,[{key:"componentDidMount",value:function(){if(this.props.isAnimationActive){var i=this.getTotalLength();this.setState({totalLength:i})}}},{key:"componentDidUpdate",value:function(){if(this.props.isAnimationActive){var i=this.getTotalLength();i!==this.state.totalLength&&this.setState({totalLength:i})}}},{key:"getTotalLength",value:function(){var i=this.mainCurve;try{return i&&i.getTotalLength&&i.getTotalLength()||0}catch{return 0}}},{key:"renderErrorBar",value:function(i,o){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var a=this.props,u=a.points,l=a.xAxis,s=a.yAxis,f=a.layout,c=a.children,d=Ut(c,_u);if(!d)return null;var p=function(g,m){return{x:g.x,y:g.y,value:g.value,errorVal:$t(g.payload,m)}},h={clipPath:i?"url(#clipPath-".concat(o,")"):null};return $.createElement(Ce,h,d.map(function(v,g){return $.cloneElement(v,{key:"bar-".concat(g),data:u,xAxis:l,yAxis:s,layout:f,dataPointFormatter:p})}))}},{key:"renderDots",value:function(i,o,a){var u=this.props.isAnimationActive;if(u&&!this.state.isAnimationFinished)return null;var l=this.props,s=l.dot,f=l.points,c=l.dataKey,d=ne(this.props),p=ne(s,!0),h=f.map(function(g,m){var y=xt(xt(xt({key:"dot-".concat(m),r:3},d),p),{},{value:g.value,dataKey:c,cx:g.x,cy:g.y,index:m,payload:g.payload});return r.renderDotItem(s,y)}),v={clipPath:i?"url(#clipPath-".concat(o?"":"dots-").concat(a,")"):null};return $.createElement(Ce,aa({className:"recharts-line-dots",key:"dots"},v),h)}},{key:"renderCurveStatically",value:function(i,o,a,u){var l=this.props,s=l.type,f=l.layout,c=l.connectNulls;l.ref;var d=YK(l,XK),p=xt(xt(xt({},ne(d,!0)),{},{fill:"none",className:"recharts-line-curve",clipPath:o?"url(#clipPath-".concat(a,")"):null,points:i},u),{},{type:s,layout:f,connectNulls:c});return $.createElement(Qp,aa({},p,{pathRef:this.pathRef}))}},{key:"renderCurveWithAnimation",value:function(i,o){var a=this,u=this.props,l=u.points,s=u.strokeDasharray,f=u.isAnimationActive,c=u.animationBegin,d=u.animationDuration,p=u.animationEasing,h=u.animationId,v=u.animateNewValues,g=u.width,m=u.height,y=this.state,b=y.prevPoints,S=y.totalLength;return $.createElement(Ir,{begin:c,duration:d,isActive:f,easing:p,from:{t:0},to:{t:1},key:"line-".concat(h),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(w){var x=w.t;if(b){var O=b.length/l.length,_=l.map(function(j,N){var D=Math.floor(N*O);if(b[D]){var B=b[D],R=er(B.x,j.x),C=er(B.y,j.y);return xt(xt({},j),{},{x:R(x),y:C(x)})}if(v){var I=er(g*2,j.x),F=er(m/2,j.y);return xt(xt({},j),{},{x:I(x),y:F(x)})}return xt(xt({},j),{},{x:j.x,y:j.y})});return a.renderCurveStatically(_,i,o)}var P=er(0,S),E=P(x),A;if(s){var k="".concat(s).split(/[,\s]+/gim).map(function(j){return parseFloat(j)});A=a.getStrokeDasharray(E,S,k)}else A=a.generateSimpleStrokeDasharray(S,E);return a.renderCurveStatically(l,i,o,{strokeDasharray:A})})}},{key:"renderCurve",value:function(i,o){var a=this.props,u=a.points,l=a.isAnimationActive,s=this.state,f=s.prevPoints,c=s.totalLength;return l&&u&&u.length&&(!f&&c>0||!Lc(f,u))?this.renderCurveWithAnimation(i,o):this.renderCurveStatically(u,i,o)}},{key:"render",value:function(){var i,o=this.props,a=o.hide,u=o.dot,l=o.points,s=o.className,f=o.xAxis,c=o.yAxis,d=o.top,p=o.left,h=o.width,v=o.height,g=o.isAnimationActive,m=o.id;if(a||!l||!l.length)return null;var y=this.state.isAnimationFinished,b=l.length===1,S=se("recharts-line",s),w=f&&f.allowDataOverflow,x=c&&c.allowDataOverflow,O=w||x,_=ie(m)?this.id:m,P=(i=ne(u))!==null&&i!==void 0?i:{r:3,strokeWidth:2},E=P.r,A=E===void 0?3:E,k=P.strokeWidth,j=k===void 0?2:k,N=Aj(u)?u:{},D=N.clipDot,B=D===void 0?!0:D,R=A*2+j;return $.createElement(Ce,{className:S},w||x?$.createElement("defs",null,$.createElement("clipPath",{id:"clipPath-".concat(_)},$.createElement("rect",{x:w?p:p-h/2,y:x?d:d-v/2,width:w?h:h*2,height:x?v:v*2})),!B&&$.createElement("clipPath",{id:"clipPath-dots-".concat(_)},$.createElement("rect",{x:p-R/2,y:d-R/2,width:h+R,height:v+R}))):null,!b&&this.renderCurve(O,_),this.renderErrorBar(O,_),(b||u)&&this.renderDots(O,B,_),(!g||y)&&hn.renderCallByParent(this.props,l))}}],[{key:"getDerivedStateFromProps",value:function(i,o){return i.animationId!==o.prevAnimationId?{prevAnimationId:i.animationId,curPoints:i.points,prevPoints:o.curPoints}:i.points!==o.curPoints?{curPoints:i.points}:null}},{key:"repeat",value:function(i,o){for(var a=i.length%2!==0?[].concat(ui(i),[0]):i,u=[],l=0;l-1?i[o?t[a]:a]:void 0}}var pV=dV,hV=M_;function vV(e){var t=hV(e),r=t%1;return t===t?r?t-r:t:0}var yV=vV,mV=nO,gV=Sn,bV=yV,wV=Math.max;function xV(e,t,r){var n=e==null?0:e.length;if(!n)return-1;var i=r==null?0:bV(r);return i<0&&(i=wV(n+i,0)),mV(e,gV(t),i)}var SV=xV,OV=pV,_V=SV,PV=OV(_V),AV=PV;const EV=ve(AV);var $V="Invariant failed";function kV(e,t){if(!e)throw new Error($V)}function K_(e){var t=e.cx,r=e.cy,n=e.radius,i=e.startAngle,o=e.endAngle,a=Xe(t,r,n,i),u=Xe(t,r,n,o);return{points:[a,u],cx:t,cy:r,radius:n,startAngle:i,endAngle:o}}function xb(e){return MV(e)||jV(e)||CV(e)||TV()}function TV(){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 CV(e,t){if(e){if(typeof e=="string")return dh(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return dh(e,t)}}function jV(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function MV(e){if(Array.isArray(e))return dh(e)}function dh(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function qV(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,o;for(o=0;o=0)&&(r[i]=e[i]);return r}function XV(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Pb(e,t){for(var r=0;r"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 Ws(e){return Ws=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Ws(e)}function no(e){return nG(e)||rG(e)||q_(e)||tG()}function tG(){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 q_(e,t){if(e){if(typeof e=="string")return vh(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return vh(e,t)}}function rG(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function nG(e){if(Array.isArray(e))return vh(e)}function vh(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r0?a:t&&t.length&&U(i)&&U(o)?t.slice(i,o+1):[]};function Q_(e){return e==="number"?[0,"auto"]:void 0}var Z_=function(t,r,n,i){var o=t.graphicalItems,a=t.tooltipAxis,u=qc(r,t);return n<0||!o||!o.length||n>=u.length?null:o.reduce(function(l,s){var f,c=s.props.hide;if(c)return l;var d=(f=s.props.data)!==null&&f!==void 0?f:r;d&&t.dataStartIndex+t.dataEndIndex!==0&&(d=d.slice(t.dataStartIndex,t.dataEndIndex+1));var p;if(a.dataKey&&!a.allowDuplicatedCategory){var h=d===void 0?u:d;p=Xl(h,a.dataKey,i)}else p=d&&d[n]||u[n];return p?[].concat(no(l),[$_(s,p)]):l},[])},Eb=function(t,r,n,i){var o=i||{x:t.chartX,y:t.chartY},a=uG(o,n),u=t.orderedTooltipTicks,l=t.tooltipAxis,s=t.tooltipTicks,f=qU(a,u,s,l);if(f>=0&&s){var c=s[f]&&s[f].value,d=Z_(t,r,f,c),p=lG(n,u,f,o);return{activeTooltipIndex:f,activeLabel:c,activePayload:d,activeCoordinate:p}}return null},sG=function(t,r){var n=r.axes,i=r.graphicalItems,o=r.axisType,a=r.axisIdKey,u=r.stackGroups,l=r.dataStartIndex,s=r.dataEndIndex,f=t.layout,c=t.children,d=t.stackOffset,p=A_(f,o);return n.reduce(function(h,v){var g,m=v.props,y=m.type,b=m.dataKey,S=m.allowDataOverflow,w=m.allowDuplicatedCategory,x=m.scale,O=m.ticks,_=m.includeHidden,P=v.props[a];if(h[P])return h;var E=qc(t.data,{graphicalItems:i.filter(function(H){return H.props[a]===P}),dataStartIndex:l,dataEndIndex:s}),A=E.length,k,j,N;zV(v.props.domain,S,y)&&(k=Vp(v.props.domain,null,S),p&&(y==="number"||x!=="auto")&&(N=ia(E,b,"category")));var D=Q_(y);if(!k||k.length===0){var B,R=(B=v.props.domain)!==null&&B!==void 0?B:D;if(b){if(k=ia(E,b,y),y==="category"&&p){var C=mj(k);w&&C?(j=k,k=Is(0,A)):w||(k=O1(R,k,v).reduce(function(H,ee){return H.indexOf(ee)>=0?H:[].concat(no(H),[ee])},[]))}else if(y==="category")w?k=k.filter(function(H){return H!==""&&!ie(H)}):k=O1(R,k,v).reduce(function(H,ee){return H.indexOf(ee)>=0||ee===""||ie(ee)?H:[].concat(no(H),[ee])},[]);else if(y==="number"){var I=JU(E,i.filter(function(H){return H.props[a]===P&&(_||!H.props.hide)}),b,o,f);I&&(k=I)}p&&(y==="number"||x!=="auto")&&(N=ia(E,b,"category"))}else p?k=Is(0,A):u&&u[P]&&u[P].hasStack&&y==="number"?k=d==="expand"?[0,1]:E_(u[P].stackGroups,l,s):k=P_(E,i.filter(function(H){return H.props[a]===P&&(_||!H.props.hide)}),y,f,!0);if(y==="number")k=ph(c,k,P,o,O),R&&(k=Vp(R,k,S));else if(y==="category"&&R){var F=R,X=k.every(function(H){return F.indexOf(H)>=0});X&&(k=F)}}return M(M({},h),{},q({},P,M(M({},v.props),{},{axisType:o,domain:k,categoricalDomain:N,duplicateDomain:j,originalDomain:(g=v.props.domain)!==null&&g!==void 0?g:D,isCategorical:p,layout:f})))},{})},cG=function(t,r){var n=r.graphicalItems,i=r.Axis,o=r.axisType,a=r.axisIdKey,u=r.stackGroups,l=r.dataStartIndex,s=r.dataEndIndex,f=t.layout,c=t.children,d=qc(t.data,{graphicalItems:n,dataStartIndex:l,dataEndIndex:s}),p=d.length,h=A_(f,o),v=-1;return n.reduce(function(g,m){var y=m.props[a],b=Q_("number");if(!g[y]){v++;var S;return h?S=Is(0,p):u&&u[y]&&u[y].hasStack?(S=E_(u[y].stackGroups,l,s),S=ph(c,S,y,o)):(S=Vp(b,P_(d,n.filter(function(w){return w.props[a]===y&&!w.props.hide}),"number",f),i.defaultProps.allowDataOverflow),S=ph(c,S,y,o)),M(M({},g),{},q({},y,M(M({axisType:o},i.defaultProps),{},{hide:!0,orientation:Ft(oG,"".concat(o,".").concat(v%2),null),domain:S,originalDomain:b,isCategorical:h,layout:f})))}return g},{})},fG=function(t,r){var n=r.axisType,i=n===void 0?"xAxis":n,o=r.AxisComp,a=r.graphicalItems,u=r.stackGroups,l=r.dataStartIndex,s=r.dataEndIndex,f=t.children,c="".concat(i,"Id"),d=Ut(f,o),p={};return d&&d.length?p=sG(t,{axes:d,graphicalItems:a,axisType:i,axisIdKey:c,stackGroups:u,dataStartIndex:l,dataEndIndex:s}):a&&a.length&&(p=cG(t,{Axis:o,graphicalItems:a,axisType:i,axisIdKey:c,stackGroups:u,dataStartIndex:l,dataEndIndex:s})),p},dG=function(t){var r=Hr(t),n=Kr(r,!1,!0);return{tooltipTicks:n,orderedTooltipTicks:Lv(n,function(i){return i.coordinate}),tooltipAxis:r,tooltipAxisBandSize:$s(r,n)}},$b=function(t){var r,n,i=t.children,o=t.defaultShowTooltip,a=Or(i,tu),u=a&&a.props&&a.props.startIndex||0,l=(a==null||(r=a.props)===null||r===void 0?void 0:r.endIndex)!==void 0?a==null||(n=a.props)===null||n===void 0?void 0:n.endIndex:t.data&&t.data.length-1||0;return{chartX:0,chartY:0,dataStartIndex:u,dataEndIndex:l,activeTooltipIndex:-1,isTooltipActive:!!o}},pG=function(t){return!t||!t.length?!1:t.some(function(r){var n=Er(r&&r.type);return n&&n.indexOf("Bar")>=0})},kb=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"}},hG=function(t,r){var n=t.props,i=t.graphicalItems,o=t.xAxisMap,a=o===void 0?{}:o,u=t.yAxisMap,l=u===void 0?{}:u,s=n.width,f=n.height,c=n.children,d=n.margin||{},p=Or(c,tu),h=Or(c,Wi),v=Object.keys(l).reduce(function(w,x){var O=l[x],_=O.orientation;return!O.mirror&&!O.hide?M(M({},w),{},q({},_,w[_]+O.width)):w},{left:d.left||0,right:d.right||0}),g=Object.keys(a).reduce(function(w,x){var O=a[x],_=O.orientation;return!O.mirror&&!O.hide?M(M({},w),{},q({},_,Ft(w,"".concat(_))+O.height)):w},{top:d.top||0,bottom:d.bottom||0}),m=M(M({},g),v),y=m.bottom;p&&(m.bottom+=p.props.height||tu.defaultProps.height),h&&r&&(m=QU(m,i,n,r));var b=s-m.left-m.right,S=f-m.top-m.bottom;return M(M({brushBottom:y},m),{},{width:Math.max(b,0),height:Math.max(S,0)})},vG=function(t){var r,n=t.chartName,i=t.GraphicalChild,o=t.defaultTooltipEventType,a=o===void 0?"axis":o,u=t.validateTooltipEventTypes,l=u===void 0?["axis"]:u,s=t.axisComponents,f=t.legendContent,c=t.formatAxisMap,d=t.defaultProps,p=function(g,m){var y=m.graphicalItems,b=m.stackGroups,S=m.offset,w=m.updateId,x=m.dataStartIndex,O=m.dataEndIndex,_=g.barSize,P=g.layout,E=g.barGap,A=g.barCategoryGap,k=g.maxBarSize,j=kb(P),N=j.numericAxisName,D=j.cateAxisName,B=pG(y),R=B&&XU({barSize:_,stackGroups:b}),C=[];return y.forEach(function(I,F){var X=qc(g.data,{graphicalItems:[I],dataStartIndex:x,dataEndIndex:O}),H=I.props,ee=H.dataKey,Pe=H.maxBarSize,$e=I.props["".concat(N,"Id")],Ze=I.props["".concat(D,"Id")],gt={},bt=s.reduce(function(En,$n){var ku,Xc=m["".concat($n.axisType,"Map")],gy=I.props["".concat($n.axisType,"Id")];Xc&&Xc[gy]||$n.axisType==="zAxis"||kV(!1);var by=Xc[gy];return M(M({},En),{},(ku={},q(ku,$n.axisType,by),q(ku,"".concat($n.axisType,"Ticks"),Kr(by)),ku))},gt),W=bt[D],Y=bt["".concat(D,"Ticks")],Z=b&&b[$e]&&b[$e].hasStack&&fW(I,b[$e].stackGroups),L=Er(I.type).indexOf("Bar")>=0,Ae=$s(W,Y),oe=[];if(L){var ke,Ne,wt=ie(Pe)?k:Pe,ur=(ke=(Ne=$s(W,Y,!0))!==null&&Ne!==void 0?Ne:wt)!==null&&ke!==void 0?ke:0;oe=YU({barGap:E,barCategoryGap:A,bandSize:ur!==Ae?ur:Ae,sizeList:R[Ze],maxBarSize:wt}),ur!==Ae&&(oe=oe.map(function(En){return M(M({},En),{},{position:M(M({},En.position),{},{offset:En.position.offset-ur/2})})}))}var $u=I&&I.type&&I.type.getComposedData;if($u){var An;C.push({props:M(M({},$u(M(M({},bt),{},{displayedData:X,props:g,dataKey:ee,item:I,bandSize:Ae,barPosition:oe,offset:S,stackedData:Z,layout:P,dataStartIndex:x,dataEndIndex:O}))),{},(An={key:I.key||"item-".concat(F)},q(An,N,bt[N]),q(An,D,bt[D]),q(An,"animationId",w),An)),childIndex:kj(I,g.children),item:I})}}),C},h=function(g,m){var y=g.props,b=g.dataStartIndex,S=g.dataEndIndex,w=g.updateId;if(!Xm({props:y}))return null;var x=y.children,O=y.layout,_=y.stackOffset,P=y.data,E=y.reverseStackOrder,A=kb(O),k=A.numericAxisName,j=A.cateAxisName,N=Ut(x,i),D=lW(P,N,"".concat(k,"Id"),"".concat(j,"Id"),_,E),B=s.reduce(function(X,H){var ee="".concat(H.axisType,"Map");return M(M({},X),{},q({},ee,fG(y,M(M({},H),{},{graphicalItems:N,stackGroups:H.axisType===k&&D,dataStartIndex:b,dataEndIndex:S}))))},{}),R=hG(M(M({},B),{},{props:y,graphicalItems:N}),m==null?void 0:m.legendBBox);Object.keys(B).forEach(function(X){B[X]=c(y,B[X],R,X.replace("Map",""),n)});var C=B["".concat(j,"Map")],I=dG(C),F=p(y,M(M({},B),{},{dataStartIndex:b,dataEndIndex:S,updateId:w,graphicalItems:N,stackGroups:D,offset:R}));return M(M({formattedGraphicalItems:F,graphicalItems:N,offset:R,stackGroups:D},I),B)};return r=function(v){QV(m,v);var g=ZV(m);function m(y){var b,S,w;return XV(this,m),w=g.call(this,y),q(J(w),"eventEmitterSymbol",Symbol("rechartsEventEmitter")),q(J(w),"accessibilityManager",new BV),q(J(w),"handleLegendBBoxUpdate",function(x){if(x){var O=w.state,_=O.dataStartIndex,P=O.dataEndIndex,E=O.updateId;w.setState(M({legendBBox:x},h({props:w.props,dataStartIndex:_,dataEndIndex:P,updateId:E},M(M({},w.state),{},{legendBBox:x}))))}}),q(J(w),"handleReceiveSyncEvent",function(x,O,_){if(w.props.syncId===x){if(_===w.eventEmitterSymbol&&typeof w.props.syncMethod!="function")return;w.applySyncEvent(O)}}),q(J(w),"handleBrushChange",function(x){var O=x.startIndex,_=x.endIndex;if(O!==w.state.dataStartIndex||_!==w.state.dataEndIndex){var P=w.state.updateId;w.setState(function(){return M({dataStartIndex:O,dataEndIndex:_},h({props:w.props,dataStartIndex:O,dataEndIndex:_,updateId:P},w.state))}),w.triggerSyncEvent({dataStartIndex:O,dataEndIndex:_})}}),q(J(w),"handleMouseEnter",function(x){var O=w.getMouseInfo(x);if(O){var _=M(M({},O),{},{isTooltipActive:!0});w.setState(_),w.triggerSyncEvent(_);var P=w.props.onMouseEnter;te(P)&&P(_,x)}}),q(J(w),"triggeredAfterMouseMove",function(x){var O=w.getMouseInfo(x),_=O?M(M({},O),{},{isTooltipActive:!0}):{isTooltipActive:!1};w.setState(_),w.triggerSyncEvent(_);var P=w.props.onMouseMove;te(P)&&P(_,x)}),q(J(w),"handleItemMouseEnter",function(x){w.setState(function(){return{isTooltipActive:!0,activeItem:x,activePayload:x.tooltipPayload,activeCoordinate:x.tooltipPosition||{x:x.cx,y:x.cy}}})}),q(J(w),"handleItemMouseLeave",function(){w.setState(function(){return{isTooltipActive:!1}})}),q(J(w),"handleMouseMove",function(x){x.persist(),w.throttleTriggeredAfterMouseMove(x)}),q(J(w),"handleMouseLeave",function(x){var O={isTooltipActive:!1};w.setState(O),w.triggerSyncEvent(O);var _=w.props.onMouseLeave;te(_)&&_(O,x)}),q(J(w),"handleOuterEvent",function(x){var O=$j(x),_=Ft(w.props,"".concat(O));if(O&&te(_)){var P,E;/.*touch.*/i.test(O)?E=w.getMouseInfo(x.changedTouches[0]):E=w.getMouseInfo(x),_((P=E)!==null&&P!==void 0?P:{},x)}}),q(J(w),"handleClick",function(x){var O=w.getMouseInfo(x);if(O){var _=M(M({},O),{},{isTooltipActive:!0});w.setState(_),w.triggerSyncEvent(_);var P=w.props.onClick;te(P)&&P(_,x)}}),q(J(w),"handleMouseDown",function(x){var O=w.props.onMouseDown;if(te(O)){var _=w.getMouseInfo(x);O(_,x)}}),q(J(w),"handleMouseUp",function(x){var O=w.props.onMouseUp;if(te(O)){var _=w.getMouseInfo(x);O(_,x)}}),q(J(w),"handleTouchMove",function(x){x.changedTouches!=null&&x.changedTouches.length>0&&w.throttleTriggeredAfterMouseMove(x.changedTouches[0])}),q(J(w),"handleTouchStart",function(x){x.changedTouches!=null&&x.changedTouches.length>0&&w.handleMouseDown(x.changedTouches[0])}),q(J(w),"handleTouchEnd",function(x){x.changedTouches!=null&&x.changedTouches.length>0&&w.handleMouseUp(x.changedTouches[0])}),q(J(w),"triggerSyncEvent",function(x){w.props.syncId!==void 0&&Zf.emit(Jf,w.props.syncId,x,w.eventEmitterSymbol)}),q(J(w),"applySyncEvent",function(x){var O=w.props,_=O.layout,P=O.syncMethod,E=w.state.updateId,A=x.dataStartIndex,k=x.dataEndIndex;if(x.dataStartIndex!==void 0||x.dataEndIndex!==void 0)w.setState(M({dataStartIndex:A,dataEndIndex:k},h({props:w.props,dataStartIndex:A,dataEndIndex:k,updateId:E},w.state)));else if(x.activeTooltipIndex!==void 0){var j=x.chartX,N=x.chartY,D=x.activeTooltipIndex,B=w.state,R=B.offset,C=B.tooltipTicks;if(!R)return;if(typeof P=="function")D=P(C,x);else if(P==="value"){D=-1;for(var I=0;I=0){var Z,L;if(j.dataKey&&!j.allowDuplicatedCategory){var Ae=typeof j.dataKey=="function"?Y:"payload.".concat(j.dataKey.toString());Z=Xl(I,Ae,D),L=F&&X&&Xl(X,Ae,D)}else Z=I==null?void 0:I[N],L=F&&X&&X[N];if(Ze||$e){var oe=x.props.activeIndex!==void 0?x.props.activeIndex:N;return[T.cloneElement(x,M(M(M({},P.props),bt),{},{activeIndex:oe})),null,null]}if(!ie(Z))return[W].concat(no(w.renderActivePoints({item:P,activePoint:Z,basePoint:L,childIndex:N,isRange:F})))}else{var ke,Ne=(ke=w.getItemByXY(w.state.activeCoordinate))!==null&&ke!==void 0?ke:{graphicalItem:W},wt=Ne.graphicalItem,ur=wt.item,$u=ur===void 0?x:ur,An=wt.childIndex,En=M(M(M({},P.props),bt),{},{activeIndex:An});return[T.cloneElement($u,En),null,null]}return F?[W,null,null]:[W,null]}),q(J(w),"renderCustomized",function(x,O,_){return T.cloneElement(x,M(M({key:"recharts-customized-".concat(_)},w.props),w.state))}),q(J(w),"renderMap",{CartesianGrid:{handler:w.renderGrid,once:!0},ReferenceArea:{handler:w.renderReferenceElement},ReferenceLine:{handler:w.renderReferenceElement},ReferenceDot:{handler:w.renderReferenceElement},XAxis:{handler:w.renderXAxis},YAxis:{handler:w.renderYAxis},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((b=y.id)!==null&&b!==void 0?b:gu("recharts"),"-clip"),w.throttleTriggeredAfterMouseMove=PO(w.triggeredAfterMouseMove,(S=y.throttleDelay)!==null&&S!==void 0?S:1e3/60),w.state={},w}return YV(m,[{key:"componentDidMount",value:function(){var b,S;this.addListener(),this.accessibilityManager.setDetails({container:this.container,offset:{left:(b=this.props.margin.left)!==null&&b!==void 0?b:0,top:(S=this.props.margin.top)!==null&&S!==void 0?S:0},coordinateList:this.state.tooltipTicks,mouseHandlerCallback:this.triggeredAfterMouseMove,layout:this.props.layout})}},{key:"getSnapshotBeforeUpdate",value:function(b,S){if(!this.props.accessibilityLayer)return null;if(this.state.tooltipTicks!==S.tooltipTicks&&this.accessibilityManager.setDetails({coordinateList:this.state.tooltipTicks}),this.props.layout!==b.layout&&this.accessibilityManager.setDetails({layout:this.props.layout}),this.props.margin!==b.margin){var w,x;this.accessibilityManager.setDetails({offset:{left:(w=this.props.margin.left)!==null&&w!==void 0?w:0,top:(x=this.props.margin.top)!==null&&x!==void 0?x:0}})}return null}},{key:"componentDidUpdate",value:function(){}},{key:"componentWillUnmount",value:function(){this.removeListener(),this.throttleTriggeredAfterMouseMove.cancel()}},{key:"getTooltipEventType",value:function(){var b=Or(this.props.children,Bn);if(b&&b.props.shared){var S=b.props.shared?"axis":"item";return l.indexOf(S)>=0?S:a}return a}},{key:"getMouseInfo",value:function(b){if(!this.container)return null;var S=this.container,w=S.getBoundingClientRect(),x=$8(w),O={chartX:Math.round(b.pageX-x.left),chartY:Math.round(b.pageY-x.top)},_=w.width/S.offsetWidth||1,P=this.inRange(O.chartX,O.chartY,_);if(!P)return null;var E=this.state,A=E.xAxisMap,k=E.yAxisMap,j=this.getTooltipEventType();if(j!=="axis"&&A&&k){var N=Hr(A).scale,D=Hr(k).scale,B=N&&N.invert?N.invert(O.chartX):null,R=D&&D.invert?D.invert(O.chartY):null;return M(M({},O),{},{xValue:B,yValue:R})}var C=Eb(this.state,this.props.data,this.props.layout,P);return C?M(M({},O),C):null}},{key:"inRange",value:function(b,S){var w=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,x=this.props.layout,O=b/w,_=S/w;if(x==="horizontal"||x==="vertical"){var P=this.state.offset,E=O>=P.left&&O<=P.left+P.width&&_>=P.top&&_<=P.top+P.height;return E?{x:O,y:_}:null}var A=this.state,k=A.angleAxisMap,j=A.radiusAxisMap;if(k&&j){var N=Hr(k);return A1({x:O,y:_},N)}return null}},{key:"parseEventsOfWrapper",value:function(){var b=this.props.children,S=this.getTooltipEventType(),w=Or(b,Bn),x={};w&&S==="axis"&&(w.props.trigger==="click"?x={onClick:this.handleClick}:x={onMouseEnter:this.handleMouseEnter,onMouseMove:this.handleMouseMove,onMouseLeave:this.handleMouseLeave,onTouchMove:this.handleTouchMove,onTouchStart:this.handleTouchStart,onTouchEnd:this.handleTouchEnd});var O=Yl(this.props,this.handleOuterEvent);return M(M({},O),x)}},{key:"addListener",value:function(){Zf.on(Jf,this.handleReceiveSyncEvent)}},{key:"removeListener",value:function(){Zf.removeListener(Jf,this.handleReceiveSyncEvent)}},{key:"filterFormatItem",value:function(b,S,w){for(var x=this.state.formattedGraphicalItems,O=0,_=x.length;O<_;O++){var P=x[O];if(P.item===b||P.props.key===b.key||S===Er(P.item.type)&&w===P.childIndex)return P}return null}},{key:"renderAxis",value:function(b,S,w,x){var O=this.props,_=O.width,P=O.height;return $.createElement(oa,Si({},b,{className:se("recharts-".concat(b.axisType," ").concat(b.axisType),b.className),key:S.key||"".concat(w,"-").concat(x),viewBox:{x:0,y:0,width:_,height:P},ticksGenerator:this.axesTicksGenerator}))}},{key:"renderClipPath",value:function(){var b=this.clipPathId,S=this.state.offset,w=S.left,x=S.top,O=S.height,_=S.width;return $.createElement("defs",null,$.createElement("clipPath",{id:b},$.createElement("rect",{x:w,y:x,height:O,width:_})))}},{key:"getXScales",value:function(){var b=this.state.xAxisMap;return b?Object.entries(b).reduce(function(S,w){var x=Ob(w,2),O=x[0],_=x[1];return M(M({},S),{},q({},O,_.scale))},{}):null}},{key:"getYScales",value:function(){var b=this.state.yAxisMap;return b?Object.entries(b).reduce(function(S,w){var x=Ob(w,2),O=x[0],_=x[1];return M(M({},S),{},q({},O,_.scale))},{}):null}},{key:"getXScaleByAxisId",value:function(b){var S;return(S=this.state.xAxisMap)===null||S===void 0||(S=S[b])===null||S===void 0?void 0:S.scale}},{key:"getYScaleByAxisId",value:function(b){var S;return(S=this.state.yAxisMap)===null||S===void 0||(S=S[b])===null||S===void 0?void 0:S.scale}},{key:"getItemByXY",value:function(b){var S=this.state,w=S.formattedGraphicalItems,x=S.activeItem;if(w&&w.length)for(var O=0,_=w.length;O<_;O++){var P=w[O],E=P.props,A=P.item,k=Er(A.type);if(k==="Bar"){var j=(E.data||[]).find(function(R){return S9(b,R)});if(j)return{graphicalItem:P,payload:j}}else if(k==="RadialBar"){var N=(E.data||[]).find(function(R){return A1(b,R)});if(N)return{graphicalItem:P,payload:N}}else if(Uc(P)||Wc(P)||Ja(P)){var D=PH({graphicalItem:P,activeTooltipItem:x,itemData:A.props.data}),B=A.props.activeIndex===void 0?D:A.props.activeIndex;return{graphicalItem:M(M({},P),{},{childIndex:B}),payload:Ja(P)?A.props.data[D]:P.props.data[D]}}}return null}},{key:"render",value:function(){var b=this;if(!Xm(this))return null;var S=this.props,w=S.children,x=S.className,O=S.width,_=S.height,P=S.style,E=S.compact,A=S.title,k=S.desc,j=_b(S,HV),N=ne(j);if(E)return $.createElement(np,Si({},N,{width:O,height:_,title:A,desc:k}),this.renderClipPath(),Qm(w,this.renderMap));if(this.props.accessibilityLayer){var D,B;N.tabIndex=(D=this.props.tabIndex)!==null&&D!==void 0?D:0,N.role=(B=this.props.role)!==null&&B!==void 0?B:"img",N.onKeyDown=function(C){b.accessibilityManager.keyboardEvent(C)},N.onFocus=function(){b.accessibilityManager.focus()}}var R=this.parseEventsOfWrapper();return $.createElement("div",Si({className:se("recharts-wrapper",x),style:M({position:"relative",cursor:"default",width:O,height:_},P)},R,{ref:function(I){b.container=I},role:"region"}),$.createElement(np,Si({},N,{width:O,height:_,title:A,desc:k,style:aG}),this.renderClipPath(),Qm(w,this.renderMap)),this.renderLegend(),this.renderTooltip())}}]),m}(T.Component),q(r,"displayName",n),q(r,"defaultProps",M({layout:"horizontal",stackOffset:"none",barCategoryGap:"10%",barGap:4,margin:{top:5,right:5,bottom:5,left:5},reverseStackOrder:!1,syncMethod:"index"},d)),q(r,"getDerivedStateFromProps",function(v,g){var m=v.dataKey,y=v.data,b=v.children,S=v.width,w=v.height,x=v.layout,O=v.stackOffset,_=v.margin;if(g.updateId===void 0){var P=$b(v);return M(M(M({},P),{},{updateId:0},h(M(M({props:v},P),{},{updateId:0}),g)),{},{prevDataKey:m,prevData:y,prevWidth:S,prevHeight:w,prevLayout:x,prevStackOffset:O,prevMargin:_,prevChildren:b})}if(m!==g.prevDataKey||y!==g.prevData||S!==g.prevWidth||w!==g.prevHeight||x!==g.prevLayout||O!==g.prevStackOffset||!ki(_,g.prevMargin)){var E=$b(v),A={chartX:g.chartX,chartY:g.chartY,isTooltipActive:g.isTooltipActive},k=M(M({},Eb(g,y,x)),{},{updateId:g.updateId+1}),j=M(M(M({},E),A),k);return M(M(M({},j),h(M({props:v},j),g)),{},{prevDataKey:m,prevData:y,prevWidth:S,prevHeight:w,prevLayout:x,prevStackOffset:O,prevMargin:_,prevChildren:b})}if(!vS(b,g.prevChildren)){var N=!ie(y),D=N?g.updateId:g.updateId+1;return M(M({updateId:D},h(M(M({props:v},g),{},{updateId:D}),g)),{},{prevChildren:b})}return null}),q(r,"renderActiveDot",function(v,g){var m;return T.isValidElement(v)?m=T.cloneElement(v,g):te(v)?m=v(g):m=$.createElement(Fc,g),$.createElement(Ce,{className:"recharts-active-dot",key:g.key},m)}),r},yG=vG({chartName:"LineChart",GraphicalChild:Eu,axisComponents:[{axisType:"xAxis",AxisComp:Vc},{axisType:"yAxis",AxisComp:Gc}],formatAxisMap:X7});const mG=e=>{const{cx:t,cy:r,payload:n,onRemoveRecord:i,exerciseName:o}=e,a=()=>{n&&i(o,n.id)};return G.jsx(Fc,{cx:t,cy:r,r:8,fill:"red",onClick:a})},gG=({records:e,onRemoveRecord:t,exerciseName:r})=>G.jsx(x8,{width:"100%",height:200,children:G.jsxs(yG,{data:e,margin:{top:5,right:30,left:20,bottom:5},children:[G.jsx(my,{strokeDasharray:"3 3"}),G.jsx(Vc,{dataKey:"date"}),G.jsx(Gc,{}),G.jsx(Bn,{}),G.jsx(Wi,{}),G.jsx(Eu,{type:"monotone",dataKey:"maxLoad",stroke:"#8884d8",activeDot:G.jsx(mG,{onRemoveRecord:t,exerciseName:r})})]})}),bG="_exercise_151gh_1",wG="_exerciseInfo_151gh_10",td={exercise:bG,exerciseInfo:wG},xG=({exercise:e,onRemoveExercise:t,onAddRecord:r,onRemoveRecord:n})=>{const i=e.records.slice(-6).map(o=>({id:o.id,name:e.name,date:o.date.toLocaleDateString(),maxLoad:o.maxLoad}));return G.jsxs("div",{className:td.exercise,children:[G.jsxs("div",{className:td.exerciseInfo,children:[G.jsx("h2",{children:e.name}),G.jsxs("p",{children:["Reps: ",e.reps]}),G.jsx("button",{onClick:()=>t(e.name),children:"Remove Exercise"}),G.jsx("button",{onClick:()=>r(e.name),children:"Add Record"})]}),G.jsx("div",{className:td.exerciseRecords,children:G.jsx(gG,{records:i,onRemoveRecord:n,exerciseName:e.name})})]})},SG=({exercises:e,onRemoveExercise:t,onAddRecord:r,onRemoveRecord:n})=>G.jsx("div",{children:e.map((i,o)=>G.jsx(xG,{exercise:i,onRemoveExercise:t,onAddRecord:r,onRemoveRecord:n},o))}),OG=()=>{const{workoutId:e,programId:t}=Yx(),[r,n]=T.useState(),[i,o]=T.useState();T.useEffect(()=>{(async()=>{try{if(e!==void 0){const c=await tS(e);n(c);const d=c.programs.find(p=>p.id===parseInt(t,10));o(d)}}catch(c){console.error("Error searching for the program details",c)}})()},[e,t]);const a=async()=>{const f=prompt("Enter the name of the exercise:");if(!f){alert("The exercise name is required.");return}const c=prompt("Enter the number of reps:");if(!c){alert("Invalid number of reps.");return}const d={name:f,reps:c,records:[]},p=[...(i==null?void 0:i.exercises)||[],d];if((i==null?void 0:i.id)!==void 0){const h={...i,exercises:p};o(h),qu(parseInt(e,10),h)}},u=async f=>{const c=(i==null?void 0:i.exercises.filter(d=>d.name!==f))||[];if((i==null?void 0:i.id)!==void 0){const d={...i,exercises:c};o(d),qu(parseInt(e,10),d)}},l=f=>{const c=new Date,d=prompt("Enter the maximum load (kg):");let p=0;if(d&&(p=parseFloat(d)),isNaN(p)||p<=0){alert("Invalid maximum load.");return}const h={id:Date.now(),date:c,maxLoad:p},v=(i==null?void 0:i.exercises.map(g=>g.name===f?{...g,records:[...g.records,h]}:g))||[];if((i==null?void 0:i.id)!==void 0){const g={...i,exercises:v};o(g),qu(parseInt(e,10),g)}},s=(f,c)=>{const d=(i==null?void 0:i.exercises.map(p=>{if(p.name===f){const h=p.records.filter(v=>v.id!==c);return{...p,records:h}}return p}))||[];if((i==null?void 0:i.id)!==void 0){const p={...i,exercises:d};o(p),qu(parseInt(e,10),p)}};return i?G.jsxs("div",{children:[G.jsxs("h1",{children:["Program ",i.id]}),G.jsx("button",{onClick:a,children:"Add Exercise"}),G.jsx(SG,{exercises:i.exercises,onRemoveExercise:u,onAddRecord:l,onRemoveRecord:s})]}):G.jsx("div",{children:"Loading program details..."})};function _G(){return G.jsxs(h$,{children:[G.jsx(bl,{path:"/",element:G.jsx(T$,{})}),G.jsx(bl,{path:"/workout/:workoutId",element:G.jsx(N$,{})}),G.jsx(bl,{path:"/workout/:workoutId/program/:programId",element:G.jsx(OG,{})})]})}rd.createRoot(document.getElementById("root")).render(G.jsx($.StrictMode,{children:G.jsx(w$,{children:G.jsx(_G,{})})})); diff --git a/assets/index-G1C7AyTH.css b/assets/index-G1C7AyTH.css new file mode 100644 index 0000000..8f2133f --- /dev/null +++ b/assets/index-G1C7AyTH.css @@ -0,0 +1 @@ +#root{max-width:1280px;margin:0 auto;padding:2rem;text-align:center}.logo{height:6em;padding:1.5em;will-change:filter;transition:filter .3s}.logo:hover{filter:drop-shadow(0 0 2em #646cffaa)}.logo.react:hover{filter:drop-shadow(0 0 2em #61dafbaa)}@keyframes logo-spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}@media (prefers-reduced-motion: no-preference){a:nth-of-type(2) .logo{animation:logo-spin infinite 20s linear}}.card{padding:2em}.read-the-docs{color:#888}._workouts_1sur4_1{margin-top:32px;display:flex;flex-direction:column;align-items:center;gap:16px}._workouts_1sur4_1>div{opacity:.25;display:flex;align-items:center;gap:16px}._workouts_1sur4_1>div:first-of-type{opacity:1}._workouts_1sur4_1>div:first-of-type a{font-size:1.5rem}._programs_13s5v_1{margin-top:32px;display:flex;flex-direction:column;align-items:center;gap:16px}._programs_13s5v_1>div{display:flex;align-items:center;gap:16px;font-size:1.2rem}._exercise_151gh_1{border-top:1px solid rgba(100,108,255,.5);margin-top:16px;padding-top:16px;display:grid;grid-template-columns:1fr 2fr;gap:16px}._exerciseInfo_151gh_10 button:first-of-type{margin-right:16px}:root{font-family:Inter,system-ui,Avenir,Helvetica,Arial,sans-serif;line-height:1.5;font-weight:400;color-scheme:light dark;color:#ffffffde;background-color:#242424;font-synthesis:none;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}a{font-weight:500;color:#646cff;text-decoration:inherit}a:hover{color:#535bf2}body{margin:0;display:flex;place-items:center;min-width:320px;min-height:100vh}h1{font-size:3.2em;line-height:1.1}button{border-radius:8px;border:1px solid transparent;padding:.6em 1.2em;font-size:1em;font-weight:500;font-family:inherit;background-color:#1a1a1a;cursor:pointer;transition:border-color .25s}button:hover{border-color:#646cff}button:focus,button:focus-visible{outline:4px auto -webkit-focus-ring-color}@media (prefers-color-scheme: light){:root{color:#213547;background-color:#fff}a:hover{color:#747bff}button{background-color:#f9f9f9}} diff --git a/index.html b/index.html new file mode 100644 index 0000000..68cf2cf --- /dev/null +++ b/index.html @@ -0,0 +1,13 @@ + + + + + + Gym Compation + + + + +
+ + diff --git a/vite.svg b/vite.svg new file mode 100644 index 0000000..e7b8dfb --- /dev/null +++ b/vite.svg @@ -0,0 +1 @@ + \ No newline at end of file